aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGObjCGNU.cpp
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2010-08-17 12:54:38 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2010-08-17 12:54:38 +0000
commit2f4eaef37476ae6891ede8ba215d0f6fd093629b (patch)
tree0b7d6c8f65b72c84bddeb847b25137ace553928b /lib/CodeGen/CGObjCGNU.cpp
parent572fc62b52b5b113cbaf528bd3ec00fcde19a46e (diff)
Convert all uses of StringLiteral::getStrData() to StringLiteral::getString()
and remove getStrData(). Patch by Peter Davies (with some tweaks). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111229 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGObjCGNU.cpp')
-rw-r--r--lib/CodeGen/CGObjCGNU.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/CGObjCGNU.cpp b/lib/CodeGen/CGObjCGNU.cpp
index fdee1dee13..d7960beb1d 100644
--- a/lib/CodeGen/CGObjCGNU.cpp
+++ b/lib/CodeGen/CGObjCGNU.cpp
@@ -449,7 +449,7 @@ llvm::Constant *CGObjCGNU::MakeGlobal(const llvm::ArrayType *Ty,
/// Generate an NSConstantString object.
llvm::Constant *CGObjCGNU::GenerateConstantString(const StringLiteral *SL) {
- std::string Str(SL->getStrData(), SL->getByteLength());
+ std::string Str = SL->getString().str();
// Look for an existing one
llvm::StringMap<llvm::Constant*>::iterator old = ObjCStrings.find(Str);