aboutsummaryrefslogtreecommitdiff
path: root/lib/VMCore/BasicBlock.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/VMCore/BasicBlock.cpp')
-rw-r--r--lib/VMCore/BasicBlock.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/VMCore/BasicBlock.cpp b/lib/VMCore/BasicBlock.cpp
index afdd79e6aa..2e3b426e2b 100644
--- a/lib/VMCore/BasicBlock.cpp
+++ b/lib/VMCore/BasicBlock.cpp
@@ -62,7 +62,7 @@ template class SymbolTableListTraits<Instruction, BasicBlock, Function>;
BasicBlock::BasicBlock(const std::string &Name, Function *Parent,
BasicBlock *InsertBefore)
- : Value(Type::LabelTy, Value::BasicBlockVal, Name) {
+ : Value(Type::LabelTy, Value::BasicBlockVal) {
// Initialize the instlist...
InstList.setItemParent(this);
@@ -76,6 +76,8 @@ BasicBlock::BasicBlock(const std::string &Name, Function *Parent,
} else if (Parent) {
Parent->getBasicBlockList().push_back(this);
}
+
+ setName(Name);
}