about summary refs log tree commit diff
path: root/src/test/ui/parser/issue-33418.fixed
diff options
context:
space:
mode:
authorHoàng Đức Hiếu <hdhoang@hdhoang.space>2018-12-16 15:50:49 +0700
committerHoàng Đức Hiếu <code@hdhoang.space>2019-02-23 07:58:16 +0700
commit7cfddfb4e40584dc206cedef7c70b5fecb03d6a1 (patch)
tree0d00c94a1b9b80b6b24ad3380b07e42227623df5 /src/test/ui/parser/issue-33418.fixed
parent082c86175fcf72c355e6a889956fbea59e65bcdb (diff)
Improve parsing diagnostic for negative supertrait bounds
Diffstat (limited to 'src/test/ui/parser/issue-33418.fixed')
-rw-r--r--src/test/ui/parser/issue-33418.fixed14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/test/ui/parser/issue-33418.fixed b/src/test/ui/parser/issue-33418.fixed
new file mode 100644
index 00000000000..df11f2d855c
--- /dev/null
+++ b/src/test/ui/parser/issue-33418.fixed
@@ -0,0 +1,14 @@
+// run-rustfix
+
+trait Tr {} //~ ERROR negative trait bounds are not supported
+trait Tr2: SuperA {} //~ ERROR negative trait bounds are not supported
+trait Tr3: SuperB {} //~ ERROR negative trait bounds are not supported
+trait Tr4: SuperB + SuperD {}
+trait Tr5 {}
+
+trait SuperA {}
+trait SuperB {}
+trait SuperC {}
+trait SuperD {}
+
+fn main() {}