diff options
Diffstat (limited to 'src/test/ui/parser/assoc-type-in-type-arg.rs')
-rw-r--r-- | src/test/ui/parser/assoc-type-in-type-arg.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/test/ui/parser/assoc-type-in-type-arg.rs b/src/test/ui/parser/assoc-type-in-type-arg.rs new file mode 100644 index 000000000..000956ea2 --- /dev/null +++ b/src/test/ui/parser/assoc-type-in-type-arg.rs @@ -0,0 +1,11 @@ +trait Tr { + type TrSubtype; +} + +struct Bar<'a, Item: Tr, <Item as Tr>::TrSubtype: 'a> { + //~^ ERROR bounds on associated types do not belong here + item: Item, + item_sub: &'a <Item as Tr>::TrSubtype, +} + +fn main() {} |