Skip to content

Constant validation is not cached #53561

Closed
@oli-obk

Description

@oli-obk

Constant validation is not part of the query that evaluates constants, because it would cause cycle errors in case a static directly or transitively contained a pointer back to itself.

One possible solution is to wrap another query around the const_eval query, not exposing the const_eval query to regular callers (similar to is_freeze_raw) and having a wrapper query around it that does the validation and thus also caches the validation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-const-evalArea: Constant evaluation, covers all const contexts (static, const fn, ...)A-incr-compArea: Incremental compilationWG-compiler-performanceWorking group: Compiler Performance

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions