Skip to content

Commit

Permalink
Rollup merge of rust-lang#59835 - lzutao:nonzero-signed, r=Mark-Simul…
Browse files Browse the repository at this point in the history
…acrum

Re-export NonZero signed variant in std

Closes  rust-lang#59834 .
  • Loading branch information
Centril authored Apr 13, 2019
2 parents c89a3c9 + 404df31 commit 1d1693c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/libstd/num.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ pub use core::num::Wrapping;

#[stable(feature = "nonzero", since = "1.28.0")]
pub use core::num::{NonZeroU8, NonZeroU16, NonZeroU32, NonZeroU64, NonZeroU128, NonZeroUsize};
#[stable(feature = "signed_nonzero", since = "1.34.0")]
pub use core::num::{NonZeroI8, NonZeroI16, NonZeroI32, NonZeroI64, NonZeroI128, NonZeroIsize};

#[cfg(test)] use crate::fmt;
#[cfg(test)] use crate::ops::{Add, Sub, Mul, Div, Rem};
Expand Down
2 changes: 1 addition & 1 deletion src/test/ui/try-block/try-block-bad-type.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ LL | Err("")?;
|
= help: the following implementations were found:
<i32 as std::convert::From<bool>>
<i32 as std::convert::From<core::num::NonZeroI32>>
<i32 as std::convert::From<i16>>
<i32 as std::convert::From<i8>>
<i32 as std::convert::From<std::num::NonZeroI32>>
and 2 others
= note: required by `std::convert::From::from`

Expand Down

0 comments on commit 1d1693c

Please sign in to comment.