diff options
author | Aleksey Kladov <[email protected]> | 2021-06-17 18:49:49 +0100 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2021-06-17 18:49:49 +0100 |
commit | 08c220ab2c4651f38d3029898706f2a996bf2c6b (patch) | |
tree | e65e8eeb44c21a0f1e378c0c32a565c3c09375bc /crates/test_utils/src | |
parent | ce926aebc4461e38535047958c0b6f72b7a0c0ea (diff) |
internal: add default to minicore
Diffstat (limited to 'crates/test_utils/src')
-rw-r--r-- | crates/test_utils/src/minicore.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/crates/test_utils/src/minicore.rs b/crates/test_utils/src/minicore.rs index e6d2301c7..4093a04bc 100644 --- a/crates/test_utils/src/minicore.rs +++ b/crates/test_utils/src/minicore.rs | |||
@@ -22,6 +22,7 @@ | |||
22 | //! result: | 22 | //! result: |
23 | //! iterator: option | 23 | //! iterator: option |
24 | //! iterators: iterator | 24 | //! iterators: iterator |
25 | //! default: sized | ||
25 | 26 | ||
26 | pub mod marker { | 27 | pub mod marker { |
27 | // region:sized | 28 | // region:sized |
@@ -37,6 +38,14 @@ pub mod marker { | |||
37 | // endregion:unsize | 38 | // endregion:unsize |
38 | } | 39 | } |
39 | 40 | ||
41 | // region:default | ||
42 | pub mod default { | ||
43 | pub trait Default: Sized { | ||
44 | fn default() -> Self; | ||
45 | } | ||
46 | } | ||
47 | // endregion:default | ||
48 | |||
40 | pub mod ops { | 49 | pub mod ops { |
41 | // region:coerce_unsized | 50 | // region:coerce_unsized |
42 | mod unsize { | 51 | mod unsize { |
@@ -309,6 +318,7 @@ pub mod iter { | |||
309 | pub mod prelude { | 318 | pub mod prelude { |
310 | pub mod v1 { | 319 | pub mod v1 { |
311 | pub use crate::{ | 320 | pub use crate::{ |
321 | default::Default, // :default | ||
312 | iter::{IntoIterator, Iterator}, // :iterator | 322 | iter::{IntoIterator, Iterator}, // :iterator |
313 | marker::Sized, // :sized | 323 | marker::Sized, // :sized |
314 | ops::{Fn, FnMut, FnOnce}, // :fn | 324 | ops::{Fn, FnMut, FnOnce}, // :fn |