Tighten up checking of the validity of casts. (1) The IR parser would
[oota-llvm.git] / test / Assembler / invalid_cast.ll
diff --git a/test/Assembler/invalid_cast.ll b/test/Assembler/invalid_cast.ll
new file mode 100644 (file)
index 0000000..c5b082b
--- /dev/null
@@ -0,0 +1,6 @@
+; RUN: not llvm-as < %s |& grep {invalid cast opcode}
+
+define <3 x i8> @foo(<4 x i64> %x) {
+  %y = trunc <4 x i64> %x to <3 x i8>
+  ret <3 x i8> %y
+}