diff options
Diffstat (limited to 'include/llvm/IR/IRBuilder.h')
-rw-r--r-- | include/llvm/IR/IRBuilder.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/llvm/IR/IRBuilder.h b/include/llvm/IR/IRBuilder.h index cdf840f541..80a2ede4da 100644 --- a/include/llvm/IR/IRBuilder.h +++ b/include/llvm/IR/IRBuilder.h @@ -90,6 +90,7 @@ public: void SetInsertPoint(Instruction *I) { BB = I->getParent(); InsertPt = I; + assert(I != BB->end() && "Can't read debug loc from end()"); SetCurrentDebugLocation(I->getDebugLoc()); } |