Allow libcore to be built with MIR inlining

Inlining caused new lints to get emitted, so we silence those lints now that we actually can.
This commit is contained in:
oli 2020-12-30 02:09:29 +00:00
parent 0491e74dd9
commit f238148214

View file

@ -200,6 +200,7 @@ macro_rules! step_identical_methods {
}
#[inline]
#[allow(arithmetic_overflow)]
fn forward(start: Self, n: usize) -> Self {
// In debug builds, trigger a panic on overflow.
// This should optimize completely out in release builds.
@ -211,6 +212,7 @@ macro_rules! step_identical_methods {
}
#[inline]
#[allow(arithmetic_overflow)]
fn backward(start: Self, n: usize) -> Self {
// In debug builds, trigger a panic on overflow.
// This should optimize completely out in release builds.