Skip to content

Commit

Permalink
Simplify.
Browse files Browse the repository at this point in the history
  • Loading branch information
frozenlib committed Jul 30, 2024
1 parent 130f2bc commit 384022a
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions parse-display/tests/from_str.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1251,10 +1251,8 @@ fn assert_from_str_err<T: FromStr + Debug>(s: &str) {
}

fn panic_on_release_mode() {
let mut is_debug = false;
debug_assert!({
is_debug = true;
false
});
assert!(is_debug);
#[cfg(not(debug_assertions))]
{
panic!("release mode");
}
}

0 comments on commit 384022a

Please sign in to comment.