diff options
| author | Simon Sapin <simon.sapin@exyr.org> | 2018-03-26 11:17:31 +0200 |
|---|---|---|
| committer | Simon Sapin <simon.sapin@exyr.org> | 2018-03-26 23:36:04 +0200 |
| commit | 09008cc23ff6395c2c928f3690e07d7389d08ebc (patch) | |
| tree | 09a874f1eb8831a7c7949b98753464de8dfe6731 | |
| parent | e53a2a72743810e05f58c61c9d8a4c89b712ad2e (diff) | |
| download | rust-09008cc23ff6395c2c928f3690e07d7389d08ebc.tar.gz rust-09008cc23ff6395c2c928f3690e07d7389d08ebc.zip | |
Add TryFrom and TryInto to the prelude
| -rw-r--r-- | src/libcore/prelude/v1.rs | 3 | ||||
| -rw-r--r-- | src/libstd/prelude/v1.rs | 2 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/libcore/prelude/v1.rs b/src/libcore/prelude/v1.rs index d43496c387c..2c8e27abac9 100644 --- a/src/libcore/prelude/v1.rs +++ b/src/libcore/prelude/v1.rs @@ -39,6 +39,9 @@ pub use cmp::{PartialEq, PartialOrd, Eq, Ord}; #[stable(feature = "core_prelude", since = "1.4.0")] #[doc(no_inline)] pub use convert::{AsRef, AsMut, Into, From}; +#[stable(feature = "try_from", since = "1.26.0")] +#[doc(no_inline)] +pub use convert::{TryFrom, TryInto}; #[stable(feature = "core_prelude", since = "1.4.0")] #[doc(no_inline)] pub use default::Default; diff --git a/src/libstd/prelude/v1.rs b/src/libstd/prelude/v1.rs index feedd4e1abe..d5b7c68a3fa 100644 --- a/src/libstd/prelude/v1.rs +++ b/src/libstd/prelude/v1.rs @@ -35,6 +35,8 @@ #[doc(no_inline)] pub use cmp::{PartialEq, PartialOrd, Eq, Ord}; #[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use convert::{AsRef, AsMut, Into, From}; +#[stable(feature = "try_from", since = "1.26.0")] +#[doc(no_inline)] pub use convert::{TryFrom, TryInto}; #[stable(feature = "rust1", since = "1.0.0")] #[doc(no_inline)] pub use default::Default; #[stable(feature = "rust1", since = "1.0.0")] |
