Skip to content

Commit ea22586

Browse files
committed
Revert emit and chagne to stash again
1 parent 5082f90 commit ea22586

File tree

1 file changed

+2
-2
lines changed
  • compiler/rustc_hir_analysis/src/hir_ty_lowering

1 file changed

+2
-2
lines changed

compiler/rustc_hir_analysis/src/hir_ty_lowering/lint.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
use rustc_ast::TraitObjectSyntax;
22
use rustc_errors::codes::*;
3-
use rustc_errors::{Diag, EmissionGuarantee, ErrorGuaranteed};
3+
use rustc_errors::{Diag, EmissionGuarantee, ErrorGuaranteed, StashKey};
44
use rustc_hir as hir;
55
use rustc_hir::def::{DefKind, Res};
66
use rustc_lint_defs::Applicability;
@@ -86,7 +86,7 @@ impl<'tcx> dyn HirTyLowerer<'tcx> + '_ {
8686
// Check if the impl trait that we are considering is an impl of a local trait.
8787
self.maybe_suggest_blanket_trait_impl(self_ty, &mut diag);
8888
self.maybe_suggest_assoc_ty_bound(self_ty, &mut diag);
89-
Some(diag.emit())
89+
diag.stash(self_ty.span, StashKey::TraitMissingMethod)
9090
} else {
9191
tcx.node_span_lint(BARE_TRAIT_OBJECTS, self_ty.hir_id, self_ty.span, |lint| {
9292
lint.primary_message("trait objects without an explicit `dyn` are deprecated");

0 commit comments

Comments
 (0)