From: Nadav Rotem Date: Mon, 8 Jul 2013 23:27:43 +0000 (+0000) Subject: Fix a bug in IRBuilder::ClearInsertionPoint. The IR Builder needs to reset both the... X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=7b934079c044311c56ebf3809c8c0047d88f825a;p=oota-llvm.git Fix a bug in IRBuilder::ClearInsertionPoint. The IR Builder needs to reset both the BB and the insert point inside the BB. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185883 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/IR/IRBuilder.h b/include/llvm/IR/IRBuilder.h index f11d3b4e0b2..cdf840f5415 100644 --- a/include/llvm/IR/IRBuilder.h +++ b/include/llvm/IR/IRBuilder.h @@ -71,6 +71,7 @@ public: /// inserted into a block. void ClearInsertionPoint() { BB = 0; + InsertPt = 0; } BasicBlock *GetInsertBlock() const { return BB; }