[llvm-commits] CVS: llvm/lib/VMCore/TypeSymbolTable.cpp
Chris Lattner
sabre at nondot.org
Tue Feb 6 21:29:51 PST 2007
Changes in directory llvm/lib/VMCore:
TypeSymbolTable.cpp updated: 1.6 -> 1.7
---
Log message:
TypeSymbolTable::rename is dead, remove it
---
Diffs of the changes: (+0 -18)
TypeSymbolTable.cpp | 18 ------------------
1 files changed, 18 deletions(-)
Index: llvm/lib/VMCore/TypeSymbolTable.cpp
diff -u llvm/lib/VMCore/TypeSymbolTable.cpp:1.6 llvm/lib/VMCore/TypeSymbolTable.cpp:1.7
--- llvm/lib/VMCore/TypeSymbolTable.cpp:1.6 Sat Jan 6 01:24:44 2007
+++ llvm/lib/VMCore/TypeSymbolTable.cpp Tue Feb 6 23:29:34 2007
@@ -122,24 +122,6 @@
return RemovedSymbol;
}
-/// rename - Given a value with a non-empty name, remove its existing entry
-/// from the symbol table and insert a new one for Name. This is equivalent to
-/// doing "remove(V), V->Name = Name, insert(V)", but is faster, and will not
-/// temporarily remove the symbol table plane if V is the last value in the
-/// symtab with that name (which could invalidate iterators to that plane).
-bool TypeSymbolTable::rename(Type *T, const std::string &name) {
- for (iterator TI = tmap.begin(), TE = tmap.end(); TI != TE; ++TI) {
- if (TI->second == T) {
- // Remove the old entry.
- tmap.erase(TI);
- // Add the new entry.
- this->insert(name,T);
- return true;
- }
- }
- return false;
-}
-
// This function is called when one of the types in the type plane are refined
void TypeSymbolTable::refineAbstractType(const DerivedType *OldType,
const Type *NewType) {
More information about the llvm-commits
mailing list