1 // Regression test for issue #80233 2 // Tests that we don't ICE when processing auto traits 3 4 #![crate_type = "lib"] 5 pub trait Trait1 {} 6 7 pub trait Trait2 { 8 type Type2; 9 } 10 11 pub trait Trait3 { 12 type Type3; 13 } 14 15 impl Trait2 for Struct1 { 16 type Type2 = Struct1; 17 } 18 19 impl<I: Trait2> Trait2 for Vec<I> { 20 type Type2 = Vec<I::Type2>; 21 } 22 23 impl<T: Trait1> Trait3 for T { 24 type Type3 = Struct1; 25 } 26 27 impl<T: Trait3> Trait3 for Vec<T> { 28 type Type3 = Vec<T::Type3>; 29 } 30 31 pub struct Struct1 {} 32 33 // @has issue_80233_normalize_auto_trait/struct.Question.html 34 // @has - '//h3[@class="code-header in-band"]' 'impl<T> Send for Question<T>' 35 pub struct Question<T: Trait1> { 36 pub ins: <<Vec<T> as Trait3>::Type3 as Trait2>::Type2, 37 } 38