@@ -123,7 +123,7 @@ impl fmt::Display for Ascii {
123
123
124
124
impl fmt:: Display for Vec < Ascii > {
125
125
fn fmt ( & self , f : & mut fmt:: Formatter ) -> fmt:: Result {
126
- fmt:: Display :: fmt ( & self [ ] , f)
126
+ fmt:: Display :: fmt ( & self [ .. ] , f)
127
127
}
128
128
}
129
129
@@ -139,14 +139,14 @@ impl fmt::Debug for Ascii {
139
139
}
140
140
}
141
141
142
- // TODO : The following impls conflict with the generic impls in std.
143
- // impl fmt::Show for Vec<Ascii> {
142
+ // NOTE : The following impls conflict with the generic impls in std.
143
+ // impl fmt::Debug for Vec<Ascii> {
144
144
// fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
145
- // fmt::Show::fmt(&self[], f)
145
+ // fmt::Show::fmt(&self[.. ], f)
146
146
// }
147
147
// }
148
148
149
- // impl fmt::Show for [Ascii] {
149
+ // impl fmt::Debug for [Ascii] {
150
150
// fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
151
151
// fmt::Show::fmt(self.as_str(), f)
152
152
// }
@@ -340,8 +340,8 @@ mod tests {
340
340
assert_eq ! ( test. to_ascii( ) . unwrap( ) , b) ;
341
341
assert_eq ! ( "( ;" . to_ascii( ) . unwrap( ) , b) ;
342
342
let v = vec ! [ 40u8 , 32u8 , 59u8 ] ;
343
- assert_eq ! ( v. as_slice ( ) . to_ascii( ) . unwrap( ) , b) ;
344
- assert_eq ! ( "( ;" . to_string( ) . as_slice ( ) . to_ascii( ) . unwrap( ) , b) ;
343
+ assert_eq ! ( v. to_ascii( ) . unwrap( ) , b) ;
344
+ assert_eq ! ( "( ;" . to_string( ) . to_ascii( ) . unwrap( ) , b) ;
345
345
}
346
346
347
347
#[ test]
@@ -416,7 +416,7 @@ mod tests {
416
416
}
417
417
418
418
#[ test]
419
- fn fmt_show_ascii ( ) {
419
+ fn fmt_debug_ascii ( ) {
420
420
let c = Ascii { chr : b't' } ;
421
421
assert_eq ! ( format!( "{:?}" , c) , "'t'" . to_string( ) ) ;
422
422
}
0 commit comments