From 0798cce9e564774b663fd965aaf2ef7e5778cb3f Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Tue, 15 Jun 2021 23:07:25 +0300 Subject: internal: add result to minicore --- crates/test_utils/src/minicore.rs | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) (limited to 'crates/test_utils') diff --git a/crates/test_utils/src/minicore.rs b/crates/test_utils/src/minicore.rs index cb18c8796..5ff60178c 100644 --- a/crates/test_utils/src/minicore.rs +++ b/crates/test_utils/src/minicore.rs @@ -17,6 +17,7 @@ //! pin: //! future: pin //! option: +//! result: pub mod marker { // region:sized @@ -127,6 +128,17 @@ pub mod option { } // endregion:option +// region:result +pub mod result { + pub enum Result { + #[lang = "Ok"] + Ok(T), + #[lang = "Err"] + Err(E), + } +} +// endregion:result + // region:pin pub mod pin { #[lang = "pin"] @@ -167,8 +179,11 @@ pub mod task { pub mod prelude { pub mod v1 { - pub use crate::marker::Sized; // :sized - pub use crate::option::Option::{self, None, Some}; // :option + pub use crate::{ + marker::Sized, // :sized + option::Option::{self, None, Some}, // :option + result::Result::{self, Err, Ok}, // :result + }; } pub mod rust_2015 { -- cgit v1.2.3