Make the deadlock panic clearly refer to a deadlock#115668
Conversation
|
r? @jackh726 (rustbot has picked a reviewer for you, use r? to override) |
| if !found_cycle { | ||
| panic!("deadlock detected"); | ||
| } |
There was a problem hiding this comment.
| if !found_cycle { | |
| panic!("deadlock detected"); | |
| } | |
| assert!(found_cycle, "deadlock detected"); |
There was a problem hiding this comment.
I went with panic! for the cleaner error message here.
There was a problem hiding this comment.
https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=6546fb921d5da013fea2262e8ed17427
Assert seems to give the same message
There was a problem hiding this comment.
I probably confused it with the assert_eq! variants which does have the assertion failed prefix. I prefer the explicit if as the message doesn't directly describe the assertion condition anyway.
|
@bors r+ rollup |
|
☀️ Test successful - checks-actions |
|
Finished benchmarking commit (ffe131f): comparison URL. Overall result: no relevant changes - no action needed@rustbot label: -perf-regression Instruction countThis benchmark run did not return any relevant results for this metric. Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 629.717s -> 629.667s (-0.01%) |
No description provided.