about summary refs log tree commit diff
path: root/compiler/rustc_middle/src
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2022-07-19 13:30:44 +0200
committerGitHub <noreply@github.com>2022-07-19 13:30:44 +0200
commitbfefd587c081305ab81074fee1ff7fd26b058ef6 (patch)
tree3da347d4655a970ff0ece525cafe8bf9bba58e79 /compiler/rustc_middle/src
parent4603ac31b0655793a82f110f544dc1c6abc57bb7 (diff)
parent38ea23558eca629d668208e368dfa711b8229192 (diff)
downloadrust-bfefd587c081305ab81074fee1ff7fd26b058ef6.tar.gz
rust-bfefd587c081305ab81074fee1ff7fd26b058ef6.zip
Rollup merge of #98028 - aticu:master, r=estebank
Add E0790 as more specific variant of E0283

Fixes #81701

I think this should be good to go, there are only two things where I am somewhat unsure:
- Is there a better way to get the fully-qualified path for the suggestion? I tried `self.tcx.def_path_str`, but that didn't seem to always give a correct path for the context.
- Should all this be extracted into it's own method or is it fine where it is?

r? `@estebank`
Diffstat (limited to 'compiler/rustc_middle/src')
-rw-r--r--compiler/rustc_middle/src/ty/trait_def.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler/rustc_middle/src/ty/trait_def.rs b/compiler/rustc_middle/src/ty/trait_def.rs
index 826c16dda4a..541dace5cc2 100644
--- a/compiler/rustc_middle/src/ty/trait_def.rs
+++ b/compiler/rustc_middle/src/ty/trait_def.rs
@@ -74,6 +74,10 @@ impl TraitImpls {
     pub fn blanket_impls(&self) -> &[DefId] {
         self.blanket_impls.as_slice()
     }
+
+    pub fn non_blanket_impls(&self) -> &FxIndexMap<SimplifiedType, Vec<DefId>> {
+        &self.non_blanket_impls
+    }
 }
 
 impl<'tcx> TraitDef {