aboutsummaryrefslogtreecommitdiffstats
path: root/test/Assembler/invalid-mdsubrange-count-negative.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/Assembler/invalid-mdsubrange-count-negative.ll')
-rw-r--r--test/Assembler/invalid-mdsubrange-count-negative.ll7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/Assembler/invalid-mdsubrange-count-negative.ll b/test/Assembler/invalid-mdsubrange-count-negative.ll
new file mode 100644
index 0000000..92c0b4e
--- /dev/null
+++ b/test/Assembler/invalid-mdsubrange-count-negative.ll
@@ -0,0 +1,7 @@
+; RUN: not llvm-as < %s -disable-output 2>&1 | FileCheck %s
+
+; CHECK-NOT: error
+!0 = !MDSubrange(count: -1)
+
+; CHECK: <stdin>:[[@LINE+1]]:25: error: value for 'count' too small, limit is -1
+!0 = !MDSubrange(count: -2)