File tree 1 file changed +5
-0
lines changed
compiler/rustc_expand/src
1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -1108,6 +1108,7 @@ impl<'a> ExtCtxt<'a> {
1108
1108
}
1109
1109
1110
1110
#[ rustc_lint_diagnostics]
1111
+ #[ track_caller]
1111
1112
pub fn struct_span_err < S : Into < MultiSpan > > (
1112
1113
& self ,
1113
1114
sp : S ,
@@ -1116,13 +1117,15 @@ impl<'a> ExtCtxt<'a> {
1116
1117
self . sess . parse_sess . span_diagnostic . struct_span_err ( sp, msg)
1117
1118
}
1118
1119
1120
+ #[ track_caller]
1119
1121
pub fn create_err (
1120
1122
& self ,
1121
1123
err : impl IntoDiagnostic < ' a > ,
1122
1124
) -> DiagnosticBuilder < ' a , ErrorGuaranteed > {
1123
1125
self . sess . create_err ( err)
1124
1126
}
1125
1127
1128
+ #[ track_caller]
1126
1129
pub fn emit_err ( & self , err : impl IntoDiagnostic < ' a > ) -> ErrorGuaranteed {
1127
1130
self . sess . emit_err ( err)
1128
1131
}
@@ -1133,10 +1136,12 @@ impl<'a> ExtCtxt<'a> {
1133
1136
/// Compilation will be stopped in the near future (at the end of
1134
1137
/// the macro expansion phase).
1135
1138
#[ rustc_lint_diagnostics]
1139
+ #[ track_caller]
1136
1140
pub fn span_err < S : Into < MultiSpan > > ( & self , sp : S , msg : impl Into < DiagnosticMessage > ) {
1137
1141
self . sess . parse_sess . span_diagnostic . span_err ( sp, msg) ;
1138
1142
}
1139
1143
#[ rustc_lint_diagnostics]
1144
+ #[ track_caller]
1140
1145
pub fn span_warn < S : Into < MultiSpan > > ( & self , sp : S , msg : impl Into < DiagnosticMessage > ) {
1141
1146
self . sess . parse_sess . span_diagnostic . span_warn ( sp, msg) ;
1142
1147
}
You can’t perform that action at this time.
0 commit comments