@@ -192,6 +192,7 @@ impl ToString for TokenStream {
192
192
/// with `Delimiter::None` delimiters and negative numeric literals.
193
193
#[ stable( feature = "proc_macro_lib" , since = "1.15.0" ) ]
194
194
impl fmt:: Display for TokenStream {
195
+ #[ allow( clippy:: recursive_format_impl) ] // clippy doesn't see the specialization
195
196
fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
196
197
f. write_str ( & self . to_string ( ) )
197
198
}
@@ -759,6 +760,7 @@ impl ToString for TokenTree {
759
760
/// with `Delimiter::None` delimiters and negative numeric literals.
760
761
#[ stable( feature = "proc_macro_lib2" , since = "1.29.0" ) ]
761
762
impl fmt:: Display for TokenTree {
763
+ #[ allow( clippy:: recursive_format_impl) ] // clippy doesn't see the specialization
762
764
fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
763
765
f. write_str ( & self . to_string ( ) )
764
766
}
@@ -889,6 +891,7 @@ impl ToString for Group {
889
891
/// with `Delimiter::None` delimiters.
890
892
#[ stable( feature = "proc_macro_lib2" , since = "1.29.0" ) ]
891
893
impl fmt:: Display for Group {
894
+ #[ allow( clippy:: recursive_format_impl) ] // clippy doesn't see the specialization
892
895
fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
893
896
f. write_str ( & self . to_string ( ) )
894
897
}
0 commit comments