Make feature suggestion more consistent.
This commit is contained in:
@@ -302,9 +302,7 @@ fn default_body_is_unstable(
|
||||
reason: reason_str,
|
||||
});
|
||||
|
||||
let inject_span = item_did
|
||||
.as_local()
|
||||
.and_then(|id| tcx.crate_level_attribute_injection_span(tcx.local_def_id_to_hir_id(id)));
|
||||
let inject_span = item_did.is_local().then(|| tcx.crate_level_attribute_injection_span());
|
||||
rustc_session::parse::add_feature_diagnostics_for_issue(
|
||||
&mut err,
|
||||
&tcx.sess,
|
||||
|
||||
Reference in New Issue
Block a user