diff options
| author | Joshua Nelson <jyn514@gmail.com> | 2021-03-30 12:28:33 -0400 |
|---|---|---|
| committer | Joshua Nelson <jyn514@gmail.com> | 2021-03-30 12:28:33 -0400 |
| commit | 6f06b761b991f5c4b714c6935781114dce44637a (patch) | |
| tree | f74620ccf601d7ba911ab25721c50896f328c054 /compiler | |
| parent | 16156fb2787f745e57504197bd7fe38b69c6cbea (diff) | |
| download | rust-6f06b761b991f5c4b714c6935781114dce44637a.tar.gz rust-6f06b761b991f5c4b714c6935781114dce44637a.zip | |
Only look at blanket impls in `get_blanket_impls`
Diffstat (limited to 'compiler')
| -rw-r--r-- | compiler/rustc_middle/src/ty/trait_def.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/compiler/rustc_middle/src/ty/trait_def.rs b/compiler/rustc_middle/src/ty/trait_def.rs index ce17a724e25..33065bc3a7b 100644 --- a/compiler/rustc_middle/src/ty/trait_def.rs +++ b/compiler/rustc_middle/src/ty/trait_def.rs @@ -69,6 +69,12 @@ pub struct TraitImpls { non_blanket_impls: FxHashMap<fast_reject::SimplifiedType, Vec<DefId>>, } +impl TraitImpls { + pub fn blanket_impls(&self) -> &[DefId] { + self.blanket_impls.as_slice() + } +} + impl<'tcx> TraitDef { pub fn new( def_id: DefId, |
