mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-28 14:36:34 +00:00
Add a new Value::getNameStr method, which is preferred over getName.
llvm-svn: 34310
This commit is contained in:
parent
2216148289
commit
fbd6928545
@ -87,7 +87,8 @@ public:
|
||||
|
||||
// All values can potentially be named...
|
||||
inline bool hasName() const { return Name != 0; }
|
||||
std::string getName() const;
|
||||
std::string getName() const { return getNameStr(); }
|
||||
std::string getNameStr() const;
|
||||
ValueName *getValueName() const { return Name; }
|
||||
|
||||
void setName(const std::string &name);
|
||||
|
@ -112,7 +112,7 @@ static bool getSymTab(Value *V, ValueSymbolTable *&ST) {
|
||||
return false;
|
||||
}
|
||||
|
||||
std::string Value::getName() const {
|
||||
std::string Value::getNameStr() const {
|
||||
if (Name == 0) return "";
|
||||
return std::string(Name->getKeyData(),
|
||||
Name->getKeyData()+Name->getKeyLength());
|
||||
|
Loading…
Reference in New Issue
Block a user