@@ -936,6 +936,7 @@ impl Handler {
936936 self . emit_diag_at_span ( Diagnostic :: new ( Bug , msg) , span) ;
937937 }
938938
939+ #[ rustc_lint_diagnostics]
939940 pub fn span_note_without_error (
940941 & self ,
941942 span : impl Into < MultiSpan > ,
@@ -944,6 +945,7 @@ impl Handler {
944945 self . emit_diag_at_span ( Diagnostic :: new ( Note , msg) , span) ;
945946 }
946947
948+ #[ rustc_lint_diagnostics]
947949 pub fn span_note_diag (
948950 & self ,
949951 span : Span ,
@@ -955,19 +957,23 @@ impl Handler {
955957 }
956958
957959 // NOTE: intentionally doesn't raise an error so rustc_codegen_ssa only reports fatal errors in the main thread
960+ #[ rustc_lint_diagnostics]
958961 pub fn fatal ( & self , msg : impl Into < DiagnosticMessage > ) -> FatalError {
959962 self . inner . borrow_mut ( ) . fatal ( msg)
960963 }
961964
965+ #[ rustc_lint_diagnostics]
962966 pub fn err ( & self , msg : impl Into < DiagnosticMessage > ) -> ErrorGuaranteed {
963967 self . inner . borrow_mut ( ) . err ( msg)
964968 }
965969
970+ #[ rustc_lint_diagnostics]
966971 pub fn warn ( & self , msg : impl Into < DiagnosticMessage > ) {
967972 let mut db = DiagnosticBuilder :: new ( self , Warning ( None ) , msg) ;
968973 db. emit ( ) ;
969974 }
970975
976+ #[ rustc_lint_diagnostics]
971977 pub fn note_without_error ( & self , msg : impl Into < DiagnosticMessage > ) {
972978 DiagnosticBuilder :: new ( self , Note , msg) . emit ( ) ;
973979 }
0 commit comments