diff options
| author | daxpedda <daxpedda@gmail.com> | 2021-04-10 17:45:55 +0200 |
|---|---|---|
| committer | daxpedda <daxpedda@gmail.com> | 2021-04-10 17:45:55 +0200 |
| commit | 8f4417faf24e18359a344945ff1072b54f354f77 (patch) | |
| tree | 42b414a52c23aed8658d98bb06f993ce61761aa5 | |
| parent | 43e6c656ba0f221caace290b8a8deace2abd89cd (diff) | |
| download | rust-8f4417faf24e18359a344945ff1072b54f354f77.tar.gz rust-8f4417faf24e18359a344945ff1072b54f354f77.zip | |
Fix rustfmt
| -rw-r--r-- | tests/ui/panic_in_result_fn_debug_assertions.rs | 21 |
1 files changed, 7 insertions, 14 deletions
diff --git a/tests/ui/panic_in_result_fn_debug_assertions.rs b/tests/ui/panic_in_result_fn_debug_assertions.rs index 1f8485b8cd8..c4fcd7e7094 100644 --- a/tests/ui/panic_in_result_fn_debug_assertions.rs +++ b/tests/ui/panic_in_result_fn_debug_assertions.rs @@ -6,41 +6,34 @@ struct A; impl A { - fn result_with_debug_assert_with_message(x: i32) -> Result<bool, String> - { + fn result_with_debug_assert_with_message(x: i32) -> Result<bool, String> { debug_assert!(x == 5, "wrong argument"); Ok(true) } - fn result_with_debug_assert_eq(x: i32) -> Result<bool, String> - { + fn result_with_debug_assert_eq(x: i32) -> Result<bool, String> { debug_assert_eq!(x, 5); Ok(true) } - fn result_with_debug_assert_ne(x: i32) -> Result<bool, String> - { + fn result_with_debug_assert_ne(x: i32) -> Result<bool, String> { debug_assert_ne!(x, 1); Ok(true) } - fn other_with_debug_assert_with_message(x: i32) - { + fn other_with_debug_assert_with_message(x: i32) { debug_assert!(x == 5, "wrong argument"); } - fn other_with_debug_assert_eq(x: i32) - { + fn other_with_debug_assert_eq(x: i32) { debug_assert_eq!(x, 5); } - fn other_with_debug_assert_ne(x: i32) - { + fn other_with_debug_assert_ne(x: i32) { debug_assert_ne!(x, 1); } - fn result_without_banned_functions() -> Result<bool, String> - { + fn result_without_banned_functions() -> Result<bool, String> { let debug_assert = "debug_assert!"; println!("No {}", debug_assert); Ok(true) |
