From 7cb46d754e431b7e5fd6607fe6f766cdb7c8a16d Mon Sep 17 00:00:00 2001 From: spernsteiner Date: Wed, 3 Apr 2024 14:27:41 -0700 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Andrei Homescu --- c2rust-analyze/src/analyze.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/c2rust-analyze/src/analyze.rs b/c2rust-analyze/src/analyze.rs index 8feceea1d8..d52d04cef2 100644 --- a/c2rust-analyze/src/analyze.rs +++ b/c2rust-analyze/src/analyze.rs @@ -1491,7 +1491,7 @@ fn run(tcx: TyCtxt) { ptrs.push(ptr); format!("{{{}}}", ptr) }); - if ptrs.len() == 0 { + if ptrs.is_empty() { continue; } // TODO: emit addr_of when it's nontrivial