Skip to content

Commit a565ae8

Browse files
committed
Declare a per-query IS_EVAL_ALWAYS constant
1 parent 47611e1 commit a565ae8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

compiler/rustc_query_impl/src/plumbing.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -718,6 +718,8 @@ macro_rules! define_queries {
718718
data: PhantomData<&'tcx ()>
719719
}
720720

721+
pub(crate) const IS_EVAL_ALWAYS: bool = is_eval_always!([$($modifiers)*]);
722+
721723
const FLAGS: QueryFlags = QueryFlags {
722724
is_anon: is_anon!([$($modifiers)*]),
723725
is_depth_limit: depth_limit!([$($modifiers)*]),
@@ -984,7 +986,7 @@ macro_rules! define_queries {
984986
$(pub(crate) fn $name<'tcx>() -> DepKindVTable<'tcx> {
985987
use $crate::query_impl::$name::QueryType;
986988
$crate::plumbing::make_dep_kind_vtable_for_query::<QueryType<'tcx>, _, _>(
987-
is_eval_always!([$($modifiers)*]),
989+
$crate::query_impl::$name::IS_EVAL_ALWAYS,
988990
)
989991
})*
990992
}

0 commit comments

Comments
 (0)