Skip to content

Commit 3c94914

Browse files
hosseind75hosseind88
authored and
hosseind88
committed
rebase with master
1 parent 7f07577 commit 3c94914

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/driver.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,9 @@ fn report_clippy_ice(info: &panic::PanicInfo<'_>, bug_report_url: &str) {
277277
// If backtraces are enabled, also print the query stack
278278
let backtrace = env::var_os("RUST_BACKTRACE").map_or(false, |x| &x != "0");
279279

280-
TyCtxt::try_print_query_stack(&handler, Some(2), Some(backtrace));
280+
let num_frames = if backtrace { None } else { Some(2) };
281+
282+
TyCtxt::try_print_query_stack(&handler, num_frames);
281283
}
282284

283285
fn toolchain_path(home: Option<String>, toolchain: Option<String>) -> Option<PathBuf> {

0 commit comments

Comments
 (0)