diff --git a/src/libcore/num/mod.rs b/src/libcore/num/mod.rs index 605ab98219f91..b6b4a46e0b812 100644 --- a/src/libcore/num/mod.rs +++ b/src/libcore/num/mod.rs @@ -2001,6 +2001,9 @@ $EndFeature, " #[inline] #[rustc_inherit_overflow_checks] pub const fn abs(self) -> Self { + // Note that the #[inline] above means that the overflow + // semantics of the subtraction depend on the crate we're being + // inlined into. if self.is_negative() { -self } else {