summaryrefslogtreecommitdiffstats
path: root/src/test/ui/keyword/keyword-self-as-type-param.rs
blob: 55c7ac128ffdecaa49b1d9f5d5b4b5843ab43008 (plain)
1
2
3
4
5
6
7
8
9
10
// Regression test of #36638.

struct Foo<Self>(Self);
//~^ ERROR unexpected keyword `Self` in generic parameters
//~| ERROR recursive type `Foo` has infinite size

trait Bar<Self> {}
//~^ ERROR unexpected keyword `Self` in generic parameters

fn main() {}