aboutsummaryrefslogtreecommitdiff
path: root/lib/VMCore/BasicBlock.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-08-24 03:41:39 +0000
committerChris Lattner <sabre@nondot.org>2003-08-24 03:41:39 +0000
commit4bd4aa5e3c41c0fc803e960252bb6fe75b804b1d (patch)
tree5050a69039e8225373b4807d03a2687f406f452c /lib/VMCore/BasicBlock.cpp
parentf3f062eb71d8725ef4e91f630c9c6481b2b0d569 (diff)
Allow specifying the name for the newly split basic block
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8097 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/BasicBlock.cpp')
-rw-r--r--lib/VMCore/BasicBlock.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/VMCore/BasicBlock.cpp b/lib/VMCore/BasicBlock.cpp
index d04e554616..ac97ed386e 100644
--- a/lib/VMCore/BasicBlock.cpp
+++ b/lib/VMCore/BasicBlock.cpp
@@ -217,12 +217,12 @@ void BasicBlock::removePredecessor(BasicBlock *Pred) {
// cause a degenerate basic block to be formed, having a terminator inside of
// the basic block).
//
-BasicBlock *BasicBlock::splitBasicBlock(iterator I) {
+BasicBlock *BasicBlock::splitBasicBlock(iterator I, const std::string &BBName) {
assert(getTerminator() && "Can't use splitBasicBlock on degenerate BB!");
assert(I != InstList.end() &&
"Trying to get me to create degenerate basic block!");
- BasicBlock *New = new BasicBlock("", getParent());
+ BasicBlock *New = new BasicBlock(BBName, getParent());
// Go from the end of the basic block through to the iterator pointer, moving
// to the new basic block...