@@ -645,7 +645,7 @@ pub trait PrintState<'a> {
645
645
ast:: LitKind :: Float ( ref f, t) => {
646
646
self . writer ( ) . word ( format ! ( "{}{}" , & f, t. ty_to_string( ) ) )
647
647
}
648
- ast:: LitKind :: FloatUnsuffixed ( ref f) => self . writer ( ) . word ( f. as_str ( ) . get ( ) ) ,
648
+ ast:: LitKind :: FloatUnsuffixed ( ref f) => self . writer ( ) . word ( f. as_str ( ) . to_string ( ) ) ,
649
649
ast:: LitKind :: Bool ( val) => {
650
650
if val { self . writer ( ) . word ( "true" ) } else { self . writer ( ) . word ( "false" ) }
651
651
}
@@ -731,7 +731,7 @@ pub trait PrintState<'a> {
731
731
if segment. ident . name == keywords:: DollarCrate . name ( ) {
732
732
self . print_dollar_crate ( segment. ident ) ?;
733
733
} else {
734
- self . writer ( ) . word ( segment. ident . as_str ( ) . get ( ) ) ?;
734
+ self . writer ( ) . word ( segment. ident . as_str ( ) . to_string ( ) ) ?;
735
735
}
736
736
}
737
737
}
@@ -749,7 +749,7 @@ pub trait PrintState<'a> {
749
749
}
750
750
self . maybe_print_comment ( attr. span . lo ( ) ) ?;
751
751
if attr. is_sugared_doc {
752
- self . writer ( ) . word ( attr. value_str ( ) . unwrap ( ) . as_str ( ) . get ( ) ) ?;
752
+ self . writer ( ) . word ( attr. value_str ( ) . unwrap ( ) . as_str ( ) . to_string ( ) ) ?;
753
753
self . writer ( ) . hardbreak ( )
754
754
} else {
755
755
match attr. style {
@@ -858,7 +858,7 @@ pub trait PrintState<'a> {
858
858
if !ast:: Ident :: with_empty_ctxt ( name) . is_path_segment_keyword ( ) {
859
859
self . writer ( ) . word ( "::" ) ?;
860
860
}
861
- self . writer ( ) . word ( name. as_str ( ) . get ( ) )
861
+ self . writer ( ) . word ( name. as_str ( ) . to_string ( ) )
862
862
}
863
863
}
864
864
@@ -1300,7 +1300,7 @@ impl<'a> State<'a> {
1300
1300
}
1301
1301
ast:: ItemKind :: GlobalAsm ( ref ga) => {
1302
1302
self . head ( visibility_qualified ( & item. vis , "global_asm!" ) ) ?;
1303
- self . s . word ( ga. asm . as_str ( ) . get ( ) ) ?;
1303
+ self . s . word ( ga. asm . as_str ( ) . to_string ( ) ) ?;
1304
1304
self . end ( ) ?;
1305
1305
}
1306
1306
ast:: ItemKind :: Ty ( ref ty, ref generics) => {
@@ -2437,7 +2437,7 @@ impl<'a> State<'a> {
2437
2437
if ident. is_raw_guess ( ) {
2438
2438
self . s . word ( format ! ( "r#{}" , ident) ) ?;
2439
2439
} else {
2440
- self . s . word ( ident. as_str ( ) . get ( ) ) ?;
2440
+ self . s . word ( ident. as_str ( ) . to_string ( ) ) ?;
2441
2441
}
2442
2442
self . ann . post ( self , AnnNode :: Ident ( & ident) )
2443
2443
}
@@ -2447,7 +2447,7 @@ impl<'a> State<'a> {
2447
2447
}
2448
2448
2449
2449
pub fn print_name ( & mut self , name : ast:: Name ) -> io:: Result < ( ) > {
2450
- self . s . word ( name. as_str ( ) . get ( ) ) ?;
2450
+ self . s . word ( name. as_str ( ) . to_string ( ) ) ?;
2451
2451
self . ann . post ( self , AnnNode :: Name ( & name) )
2452
2452
}
2453
2453
0 commit comments