about summary refs log tree commit diff
path: root/compiler/rustc_query_system
diff options
context:
space:
mode:
authorMoulins <arthur.heuillard@orange.fr>2023-06-19 15:29:31 +0200
committerMoulins <arthur.heuillard@orange.fr>2023-07-21 03:31:45 +0200
commitcb8b1d1bc98bf4a8af38bfc751fa150af4571c10 (patch)
tree390b0e517b0f4c82a80966bab749ba70d756ef0d /compiler/rustc_query_system
parente2a7ba2771a70439cd546fdae676abe11dacf6f9 (diff)
downloadrust-cb8b1d1bc98bf4a8af38bfc751fa150af4571c10.tar.gz
rust-cb8b1d1bc98bf4a8af38bfc751fa150af4571c10.zip
add `naive_layout_of` query
Diffstat (limited to 'compiler/rustc_query_system')
-rw-r--r--compiler/rustc_query_system/src/query/job.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/rustc_query_system/src/query/job.rs b/compiler/rustc_query_system/src/query/job.rs
index d2140161f1d..a53d1fcc69e 100644
--- a/compiler/rustc_query_system/src/query/job.rs
+++ b/compiler/rustc_query_system/src/query/job.rs
@@ -176,7 +176,8 @@ impl QueryJobId {
         while let Some(id) = current_id {
             let info = query_map.get(&id).unwrap();
             // FIXME: This string comparison should probably not be done.
-            if format!("{:?}", info.query.dep_kind) == "layout_of" {
+            let query_name = format!("{:?}", info.query.dep_kind);
+            if query_name == "layout_of" || query_name == "naive_layout_of" {
                 depth += 1;
                 last_layout = Some((info.clone(), depth));
             }