summaryrefslogtreecommitdiffstats
path: root/tests/ui/parser/mismatched-braces/missing-close-brace-in-trait.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/parser/mismatched-braces/missing-close-brace-in-trait.rs')
-rw-r--r--tests/ui/parser/mismatched-braces/missing-close-brace-in-trait.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/ui/parser/mismatched-braces/missing-close-brace-in-trait.rs b/tests/ui/parser/mismatched-braces/missing-close-brace-in-trait.rs
new file mode 100644
index 000000000..b6932deb5
--- /dev/null
+++ b/tests/ui/parser/mismatched-braces/missing-close-brace-in-trait.rs
@@ -0,0 +1,12 @@
+trait T {
+ fn foo(&self);
+
+pub(crate) struct Bar<T>();
+//~^ ERROR struct is not supported in `trait`s or `impl`s
+
+impl T for Bar<usize> {
+//~^ ERROR implementation is not supported in `trait`s or `impl`s
+fn foo(&self) {}
+}
+
+fn main() {} //~ ERROR this file contains an unclosed delimiter