Skip to content

Commit ea40e75

Browse files
committed
Declare a per-query IS_EVAL_ALWAYS constant
1 parent 5fdff78 commit ea40e75

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

compiler/rustc_query_impl/src/plumbing.rs

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

711+
pub(crate) const IS_EVAL_ALWAYS: bool = is_eval_always!([$($modifiers)*]);
712+
711713
const FLAGS: QueryFlags = QueryFlags {
712714
is_anon: is_anon!([$($modifiers)*]),
713715
is_depth_limit: depth_limit!([$($modifiers)*]),
@@ -974,7 +976,7 @@ macro_rules! define_queries {
974976
$(pub(crate) fn $name<'tcx>() -> DepKindVTable<'tcx> {
975977
use $crate::query_impl::$name::QueryType;
976978
$crate::plumbing::make_dep_kind_vtable_for_query::<QueryType<'tcx>, _, _>(
977-
is_eval_always!([$($modifiers)*]),
979+
$crate::query_impl::$name::IS_EVAL_ALWAYS,
978980
)
979981
})*
980982
}

0 commit comments

Comments
 (0)