Remove Value::getNameStr. It has been deprecated for a while and provides no additional value over getName().

llvm-svn: 144657
This commit is contained in:
Benjamin Kramer 2011-11-15 18:30:12 +00:00
parent 184e3ceea0
commit be6535b3dc
2 changed files with 0 additions and 15 deletions

View File

@ -117,19 +117,8 @@ public:
/// getName() - Return a constant reference to the value's name. This is cheap
/// and guaranteed to return the same reference as long as the value is not
/// modified.
///
/// This is currently guaranteed to return a StringRef for which data() points
/// to a valid null terminated string. The use of StringRef.data() is
/// deprecated here, however, and clients should not rely on it. If such
/// behavior is needed, clients should use expensive getNameStr(), or switch
/// to an interface that does not depend on null termination.
StringRef getName() const;
/// getNameStr() - Return the name of the specified value, *constructing a
/// string* to hold it. This is guaranteed to construct a string and is very
/// expensive, clients should use getName() unless necessary.
std::string getNameStr() const;
/// setName() - Change the name of the value, choosing a new unique name if
/// the provided name is taken.
///

View File

@ -156,10 +156,6 @@ StringRef Value::getName() const {
return Name->getKey();
}
std::string Value::getNameStr() const {
return getName().str();
}
void Value::setName(const Twine &NewName) {
// Fast path for common IRBuilder case of setName("") when there is no name.
if (NewName.isTriviallyEmpty() && !hasName())