Skip to content

Commit

Permalink
Inline {min,max}_value even in debug builds
Browse files Browse the repository at this point in the history
  • Loading branch information
tesuji committed Oct 1, 2019
1 parent 22bc9e1 commit 3b49ab6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/libcore/num/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ Basic usage:
$EndFeature, "
```"),
#[stable(feature = "rust1", since = "1.0.0")]
#[inline]
#[inline(always)]
#[rustc_promotable]
pub const fn min_value() -> Self {
!0 ^ ((!0 as $UnsignedT) >> 1) as Self
Expand All @@ -271,7 +271,7 @@ Basic usage:
$EndFeature, "
```"),
#[stable(feature = "rust1", since = "1.0.0")]
#[inline]
#[inline(always)]
#[rustc_promotable]
pub const fn max_value() -> Self {
!Self::min_value()
Expand Down Expand Up @@ -2308,7 +2308,7 @@ Basic usage:
```"),
#[stable(feature = "rust1", since = "1.0.0")]
#[rustc_promotable]
#[inline]
#[inline(always)]
pub const fn min_value() -> Self { 0 }
}

Expand All @@ -2325,7 +2325,7 @@ stringify!($MaxV), ");", $EndFeature, "
```"),
#[stable(feature = "rust1", since = "1.0.0")]
#[rustc_promotable]
#[inline]
#[inline(always)]
pub const fn max_value() -> Self { !0 }
}

Expand Down

0 comments on commit 3b49ab6

Please sign in to comment.