mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-26 13:03:31 +00:00
Update crates/expect/src/lib.rs
Co-authored-by: bjorn3 <bjorn3@users.noreply.github.com>
This commit is contained in:
parent
be265ece02
commit
d21dae738b
1 changed files with 4 additions and 2 deletions
|
@ -106,7 +106,7 @@ impl Runtime {
|
||||||
rt.help_printed = true;
|
rt.help_printed = true;
|
||||||
|
|
||||||
let help = if print_help { HELP } else { "" };
|
let help = if print_help { HELP } else { "" };
|
||||||
panic!(
|
println!(
|
||||||
"\n
|
"\n
|
||||||
error: expect test failed{}
|
error: expect test failed{}
|
||||||
--> {}:{}:{}
|
--> {}:{}:{}
|
||||||
|
@ -122,7 +122,9 @@ Actual:
|
||||||
----
|
----
|
||||||
",
|
",
|
||||||
updated, expect.file, expect.line, expect.column, help, expected, actual
|
updated, expect.file, expect.line, expect.column, help, expected, actual
|
||||||
)
|
);
|
||||||
|
// Use resume_unwind instead of panic!() to prevent a backtrace, which is unnecessary noise.
|
||||||
|
std::panic::resume_unwind(Box::new(()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue