about summary refs log tree commit diff
path: root/library
diff options
context:
space:
mode:
authorStuart Cook <Zalathar@users.noreply.github.com>2025-08-11 12:21:10 +1000
committerGitHub <noreply@github.com>2025-08-11 12:21:10 +1000
commitfd7d7245594a1c819333cbc4f981ae51ee78930d (patch)
tree9890df5b645333b537b1428d0988b3573c71bf58 /library
parent44c9eceb26ecda788ee999c2ca9eb5945a11cc7b (diff)
parent74c3727b1fbb274d5b5f841302310461ac54ca5e (diff)
downloadrust-fd7d7245594a1c819333cbc4f981ae51ee78930d.tar.gz
rust-fd7d7245594a1c819333cbc4f981ae51ee78930d.zip
Rollup merge of #145228 - estebank:unnecessary-parens, r=joshtriplett
Remove unnecessary parentheses in `assert!`s
Diffstat (limited to 'library')
-rw-r--r--library/coretests/tests/tuple.rs2
-rw-r--r--library/std/tests/env.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/library/coretests/tests/tuple.rs b/library/coretests/tests/tuple.rs
index ea1e281425c..5d680d10472 100644
--- a/library/coretests/tests/tuple.rs
+++ b/library/coretests/tests/tuple.rs
@@ -37,7 +37,7 @@ fn test_partial_ord() {
     assert!(!((1.0f64, 2.0f64) <= (f64::NAN, 3.0)));
     assert!(!((1.0f64, 2.0f64) > (f64::NAN, 3.0)));
     assert!(!((1.0f64, 2.0f64) >= (f64::NAN, 3.0)));
-    assert!(((1.0f64, 2.0f64) < (2.0, f64::NAN)));
+    assert!((1.0f64, 2.0f64) < (2.0, f64::NAN));
     assert!(!((2.0f64, 2.0f64) < (2.0, f64::NAN)));
 }
 
diff --git a/library/std/tests/env.rs b/library/std/tests/env.rs
index e754cf8263b..b53fd69b707 100644
--- a/library/std/tests/env.rs
+++ b/library/std/tests/env.rs
@@ -16,7 +16,7 @@ fn test_self_exe_path() {
 
 #[test]
 fn test() {
-    assert!((!Path::new("test-path").is_absolute()));
+    assert!(!Path::new("test-path").is_absolute());
 
     #[cfg(not(target_env = "sgx"))]
     current_dir().unwrap();