From cd749a9c07f1de2fb8affde90537efa4bc3e7c54 Mon Sep 17 00:00:00 2001 From: rdivacky Date: Wed, 14 Oct 2009 17:57:32 +0000 Subject: Update llvm to r84119. --- include/llvm/ValueSymbolTable.h | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'include/llvm/ValueSymbolTable.h') diff --git a/include/llvm/ValueSymbolTable.h b/include/llvm/ValueSymbolTable.h index 752dd2f..4f8ebe8 100644 --- a/include/llvm/ValueSymbolTable.h +++ b/include/llvm/ValueSymbolTable.h @@ -23,7 +23,9 @@ namespace llvm { class SymbolTableListTraits; class BasicBlock; class Function; + class NamedMDNode; class Module; + class StringRef; /// This class provides a symbol table of name/value pairs. It is essentially /// a std::map but has a controlled interface provided by @@ -37,6 +39,7 @@ class ValueSymbolTable { friend class SymbolTableListTraits; friend class SymbolTableListTraits; friend class SymbolTableListTraits; + friend class SymbolTableListTraits; /// @name Types /// @{ public: @@ -62,12 +65,11 @@ public: /// @{ public: - /// This method finds the value with the given \p name in the + /// This method finds the value with the given \p Name in the /// the symbol table. - /// @returns the value associated with the \p name + /// @returns the value associated with the \p Name /// @brief Lookup a named Value. - Value *lookup(const std::string &name) const; - Value *lookup(const char *NameBegin, const char *NameEnd) const; + Value *lookup(const StringRef &Name) const { return vmap.lookup(Name); } /// @returns true iff the symbol table is empty /// @brief Determine if the symbol table is empty @@ -110,7 +112,7 @@ private: /// createValueName - This method attempts to create a value name and insert /// it into the symbol table with the specified name. If it conflicts, it /// auto-renames the name and returns that instead. - ValueName *createValueName(const char *NameStart, unsigned NameLen, Value *V); + ValueName *createValueName(const StringRef &Name, Value *V); /// This method removes a value from the symbol table. It leaves the /// ValueName attached to the value, but it is no longer inserted in the -- cgit v1.1