Skip to content

Commit daf7e35

Browse files
committed
Fix rebase issues with existential types
1 parent 21136b8 commit daf7e35

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/librustc/hir/intravisit.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -511,7 +511,7 @@ pub fn walk_item<'v, V: Visitor<'v>>(visitor: &mut V, item: &'v Item) {
511511
ItemExistential(ExistTy {ref generics, ref bounds, impl_trait_fn}) => {
512512
visitor.visit_id(item.id);
513513
walk_generics(visitor, generics);
514-
walk_list!(visitor, visit_ty_param_bound, bounds);
514+
walk_list!(visitor, visit_param_bound, bounds);
515515
if let Some(impl_trait_fn) = impl_trait_fn {
516516
visitor.visit_def_mention(Def::Fn(impl_trait_fn))
517517
}

src/librustc/hir/lowering.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1165,7 +1165,7 @@ impl<'a> LoweringContext<'a> {
11651165
self.allocate_hir_id_counter(exist_ty_node_id, t);
11661166

11671167
let hir_bounds = self.with_hir_id_owner(exist_ty_node_id, |lctx| {
1168-
lctx.lower_bounds(bounds, itctx)
1168+
lctx.lower_param_bounds(bounds, itctx)
11691169
});
11701170

11711171
let (lifetimes, lifetime_defs) = self.lifetimes_from_impl_trait_bounds(

src/librustc/hir/print.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -662,7 +662,7 @@ impl<'a> State<'a> {
662662
self.word_space(":")?;
663663
let mut real_bounds = Vec::with_capacity(exist.bounds.len());
664664
for b in exist.bounds.iter() {
665-
if let TraitTyParamBound(ref ptr, hir::TraitBoundModifier::Maybe) = *b {
665+
if let GenericBound::Trait(ref ptr, hir::TraitBoundModifier::Maybe) = *b {
666666
self.s.space()?;
667667
self.word_space("for ?")?;
668668
self.print_trait_ref(&ptr.trait_ref)?;

0 commit comments

Comments
 (0)