@@ -152,6 +152,7 @@ pub const fn from_digit(num: u32, radix: u32) -> Option<char> {
152152pub struct EscapeUnicode ( escape:: EscapeIterInner < 10 > ) ;
153153
154154impl EscapeUnicode {
155+ #[ inline]
155156 fn new ( chr : char ) -> Self {
156157 let mut data = [ ascii:: Char :: Null ; 10 ] ;
157158 let range = escape:: escape_unicode_into ( & mut data, chr) ;
@@ -219,11 +220,13 @@ impl fmt::Display for EscapeUnicode {
219220pub struct EscapeDefault ( escape:: EscapeIterInner < 10 > ) ;
220221
221222impl EscapeDefault {
223+ #[ inline]
222224 fn printable ( chr : ascii:: Char ) -> Self {
223225 let data = [ chr] ;
224226 Self ( escape:: EscapeIterInner :: from_array ( data) )
225227 }
226228
229+ #[ inline]
227230 fn backslash ( chr : ascii:: Char ) -> Self {
228231 let data = [ ascii:: Char :: ReverseSolidus , chr] ;
229232 Self ( escape:: EscapeIterInner :: from_array ( data) )
@@ -308,6 +311,7 @@ impl EscapeDebug {
308311 Self ( EscapeDebugInner :: Char ( chr) )
309312 }
310313
314+ #[ inline]
311315 fn backslash ( chr : ascii:: Char ) -> Self {
312316 let data = [ ascii:: Char :: ReverseSolidus , chr] ;
313317 let iter = escape:: EscapeIterInner :: from_array ( data) ;
@@ -318,6 +322,7 @@ impl EscapeDebug {
318322 Self ( EscapeDebugInner :: Bytes ( esc. 0 ) )
319323 }
320324
325+ #[ inline]
321326 fn clear ( & mut self ) {
322327 let bytes = escape:: EscapeIterInner :: from_array ( [ ] ) ;
323328 self . 0 = EscapeDebugInner :: Bytes ( bytes) ;
@@ -386,6 +391,7 @@ pub struct ToLowercase(CaseMappingIter);
386391#[ stable( feature = "rust1" , since = "1.0.0" ) ]
387392impl Iterator for ToLowercase {
388393 type Item = char ;
394+ #[ inline]
389395 fn next ( & mut self ) -> Option < char > {
390396 self . 0 . next ( )
391397 }
@@ -396,6 +402,7 @@ impl Iterator for ToLowercase {
396402
397403#[ stable( feature = "case_mapping_double_ended" , since = "1.59.0" ) ]
398404impl DoubleEndedIterator for ToLowercase {
405+ #[ inline]
399406 fn next_back ( & mut self ) -> Option < char > {
400407 self . 0 . next_back ( )
401408 }
@@ -420,6 +427,7 @@ pub struct ToUppercase(CaseMappingIter);
420427#[ stable( feature = "rust1" , since = "1.0.0" ) ]
421428impl Iterator for ToUppercase {
422429 type Item = char ;
430+ #[ inline]
423431 fn next ( & mut self ) -> Option < char > {
424432 self . 0 . next ( )
425433 }
@@ -430,6 +438,7 @@ impl Iterator for ToUppercase {
430438
431439#[ stable( feature = "case_mapping_double_ended" , since = "1.59.0" ) ]
432440impl DoubleEndedIterator for ToUppercase {
441+ #[ inline]
433442 fn next_back ( & mut self ) -> Option < char > {
434443 self . 0 . next_back ( )
435444 }
@@ -534,13 +543,15 @@ impl fmt::Display for CaseMappingIter {
534543
535544#[ stable( feature = "char_struct_display" , since = "1.16.0" ) ]
536545impl fmt:: Display for ToLowercase {
546+ #[ inline]
537547 fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
538548 fmt:: Display :: fmt ( & self . 0 , f)
539549 }
540550}
541551
542552#[ stable( feature = "char_struct_display" , since = "1.16.0" ) ]
543553impl fmt:: Display for ToUppercase {
554+ #[ inline]
544555 fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
545556 fmt:: Display :: fmt ( & self . 0 , f)
546557 }
@@ -553,6 +564,7 @@ pub struct TryFromCharError(pub(crate) ());
553564
554565#[ stable( feature = "u8_from_char" , since = "1.59.0" ) ]
555566impl fmt:: Display for TryFromCharError {
567+ #[ inline]
556568 fn fmt ( & self , fmt : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
557569 "unicode code point out of range" . fmt ( fmt)
558570 }
0 commit comments