Make sure the CastInst is valid before trying to create it
[oota-llvm.git] / test / Bitcode / invalid.test
index 0aab553bb61557d69b9ce0c549006f105c84fe3f..69104046df20256fa7cafdde5c1d1f3f0d75590c 100644 (file)
@@ -113,6 +113,11 @@ RUN:   FileCheck --check-prefix=ELEMENT-TYPE %s
 
 ELEMENT-TYPE: Invalid type
 
+RUN: not llvm-dis -disable-output %p/Inputs/invalid-cast.bc 2>&1 | \
+RUN:   FileCheck --check-prefix=INVALID-CAST %s
+
+INVALID-CAST: Invalid cast
+
 RUN: not llvm-dis -disable-output %p/Inputs/invalid-array-op-not-2nd-to-last.bc 2>&1 | \
 RUN:   FileCheck --check-prefix=ARRAY-NOT-2LAST %s