summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/diagnostics/generic-constraint-left-hand-side.slang7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/diagnostics/generic-constraint-left-hand-side.slang b/tests/diagnostics/generic-constraint-left-hand-side.slang
new file mode 100644
index 000000000..61a5f6df3
--- /dev/null
+++ b/tests/diagnostics/generic-constraint-left-hand-side.slang
@@ -0,0 +1,7 @@
+//DIAGNOSTIC_TEST:SIMPLE(filecheck=CHECK):
+
+// Check that we can issue diagnostic on invalid left hand side of a type constraint.
+
+// CHECK: ([[# @LINE+1]]): error 30402
+void f<T>() where int : IInteger
+{} \ No newline at end of file