Use core::cmp in units kani verification
What changed, and why it matters
This is a tiny, non-security change in test-only code. It swaps one standard-library import for an equivalent core-library import so that a verification tool (Kani) can run in environments without the full standard library. There is no change to actual wallet or transaction logic, and no user-facing behavior changes.
No security action needed. Treat as a normal build/test hygiene improvement.
Security signals we found
No strong security signals were identified.
Evidence from the diff
In units/src/amount/verification.rs, use std::cmp; is replaced with use core::cmp;. The cmp module is identical in core and std; the change only affects whether the no-std-compatible core path is used. This file contains Kani formal-verification harnesses, not production code. The diff is one line and does not alter any runtime semantics.
Changed components
units/src/amount/verification.rs (Kani verification tests)Inspect captured patch +1 / −1
diff --git a/units/src/amount/verification.rs b/units/src/amount/verification.rs
index 1696f4e2..c4de6af1 100644
--- a/units/src/amount/verification.rs
+++ b/units/src/amount/verification.rs
@@ -2,7 +2,7 @@
//! Verification tests for the `amount` module.
-use std::cmp;
+use core::cmp;
use super::{Amount, SignedAmount};
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.