Skip to content

Commit d60b7e2

Browse files
hosseind75hosseind88
authored andcommitted
fix show we're just showing... message instead of the end of query stack message when RUST_BACKTRACE=0
1 parent d6d4388 commit d60b7e2

File tree

2 files changed

+22
-1
lines changed

2 files changed

+22
-1
lines changed

compiler/rustc_middle/src/ty/query/plumbing.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,11 @@ impl<'tcx> TyCtxt<'tcx> {
170170
}
171171
});
172172

173-
eprintln!("end of query stack");
173+
if num_frames != None {
174+
eprintln!("we're just showing a limited slice of the query stack");
175+
} else {
176+
eprintln!("end of query stack");
177+
}
174178
}
175179
}
176180

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
thread 'rustc' panicked at 'assertion failed: rows.iter().all(|r| r.len() == v.len())', compiler/rustc_mir_build/src/thir/pattern/_match.rs:LL:CC
2+
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
3+
4+
error: internal compiler error: unexpected panic
5+
6+
note: the compiler unexpectedly panicked. this is a bug.
7+
8+
note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md
9+
10+
note: rustc VERSION running on TARGET
11+
12+
note: compiler flags: FLAGS
13+
14+
query stack during panic:
15+
#0 [check_match] match-checking `main`
16+
#1 [analysis] running analysis passes on this crate
17+
we're just showing a limited slice of the query stack

0 commit comments

Comments
 (0)