Add a lint check for indirectbr with no successors.
[oota-llvm.git] / test / Other / lint.ll
index dee3d11d2fb5e0543313d493af385d0cd3eb54ba..fcef7ee2d57133779ee1f2134fc8265ed5bf6f2e 100644 (file)
@@ -161,5 +161,7 @@ declare i32 @nonstruct_callee() nounwind
 define void @struct_caller() nounwind {
 entry:
   call %struct bitcast (i32 ()* @foo to %struct ()*)()
-  ret void
+
+  ; CHECK: Undefined behavior: indirectbr with no destinations
+  indirectbr i8* null, []
 }