aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-01-10 21:42:24 +0000
committerChris Lattner <sabre@nondot.org>2004-01-10 21:42:24 +0000
commit91d7efbf4b786385e0d5d36259cb6a38e917eba8 (patch)
tree790ecd8248acbf554d1e8a85d84e499c6d479a50 /lib
parent9a0817971a71442d24a6aec0c5c66110176bdf95 (diff)
Hrm, another minor cleanup, which I missed before
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10753 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/VMCore/Function.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/VMCore/Function.cpp b/lib/VMCore/Function.cpp
index 4714d3b258..f98a7c7165 100644
--- a/lib/VMCore/Function.cpp
+++ b/lib/VMCore/Function.cpp
@@ -128,7 +128,7 @@ void Function::setName(const std::string &name, SymbolTable *ST) {
"Invalid symtab argument!");
if ((P = getParent()) && hasName()) P->getSymbolTable().remove(this);
Value::setName(name);
- if (P && getName() != "") P->getSymbolTable().insert(this);
+ if (P && hasName()) P->getSymbolTable().insert(this);
}
void Function::setParent(Module *parent) {