File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ use rustc_middle::ty::{self, Ty};
1616use rustc_session:: lint:: builtin:: UNUSED_ATTRIBUTES ;
1717use rustc_span:: symbol:: Symbol ;
1818use rustc_span:: symbol:: { kw, sym} ;
19- use rustc_span:: { BytePos , Span } ;
19+ use rustc_span:: { BytePos , Span , DUMMY_SP } ;
2020
2121use log:: debug;
2222
@@ -415,6 +415,12 @@ trait UnusedDelimLint {
415415 msg : & str ,
416416 keep_space : ( bool , bool ) ,
417417 ) {
418+ // FIXME(flip1995): Quick and dirty fix for #70814. This should be fixed in rustdoc
419+ // properly.
420+ if span == DUMMY_SP {
421+ return ;
422+ }
423+
418424 cx. struct_span_lint ( self . lint ( ) , span, |lint| {
419425 let span_msg = format ! ( "unnecessary {} around {}" , Self :: DELIM_STR , msg) ;
420426 let mut err = lint. build ( & span_msg) ;
You can’t perform that action at this time.
0 commit comments