File tree 2 files changed +4
-1
lines changed
2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ use crate::mem::transmute;
58
58
#[ unstable( feature = "ascii_char" , issue = "110998" ) ]
59
59
#[ repr( u8 ) ]
60
60
pub enum AsciiChar {
61
- /// U+0000
61
+ /// U+0000 (The default variant)
62
62
#[ unstable( feature = "ascii_char_variants" , issue = "110998" ) ]
63
63
Null = 0 ,
64
64
/// U+0001
Original file line number Diff line number Diff line change 2
2
3
3
#![ stable( feature = "rust1" , since = "1.0.0" ) ]
4
4
5
+ use crate :: ascii:: Char as AsciiChar ;
6
+
5
7
/// A trait for giving a type a useful default value.
6
8
///
7
9
/// Sometimes, you want to fall back to some kind of default value, and
@@ -158,6 +160,7 @@ macro_rules! default_impl {
158
160
default_impl ! { ( ) , ( ) , "Returns the default value of `()`" }
159
161
default_impl ! { bool , false , "Returns the default value of `false`" }
160
162
default_impl ! { char , '\x00' , "Returns the default value of `\\ x00`" }
163
+ default_impl ! { AsciiChar , AsciiChar :: Null , "Returns the default value of `Null`" }
161
164
162
165
default_impl ! { usize , 0 , "Returns the default value of `0`" }
163
166
default_impl ! { u8 , 0 , "Returns the default value of `0`" }
You can’t perform that action at this time.
0 commit comments