File tree Expand file tree Collapse file tree 1 file changed +6
-9
lines changed
Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -1255,15 +1255,12 @@ impl LateLintPass for DropWithReprExtern {
12551255 codemap:: DUMMY_SP ) ;
12561256 let self_defn_span = ctx. tcx . map . def_id_span ( self_type_did,
12571257 codemap:: DUMMY_SP ) ;
1258- ctx. span_lint ( DROP_WITH_REPR_EXTERN ,
1259- drop_impl_span,
1260- "implementing Drop adds hidden state to types, \
1261- possibly conflicting with `#[repr(C)]`") ;
1262- // FIXME #19668: could be span_lint_note instead of manual guard.
1263- if ctx. current_level ( DROP_WITH_REPR_EXTERN ) != Level :: Allow {
1264- ctx. sess ( ) . span_note ( self_defn_span,
1265- "the `#[repr(C)]` attribute is attached here" ) ;
1266- }
1258+ ctx. span_lint_note ( DROP_WITH_REPR_EXTERN ,
1259+ drop_impl_span,
1260+ "implementing Drop adds hidden state to types, \
1261+ possibly conflicting with `#[repr(C)]`",
1262+ self_defn_span,
1263+ "the `#[repr(C)]` attribute is attached here" ) ;
12671264 }
12681265 }
12691266 _ => { }
You can’t perform that action at this time.
0 commit comments