aboutsummaryrefslogtreecommitdiff
path: root/lib/AST/StmtProfile.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2011-11-02 17:26:05 +0000
committerDouglas Gregor <dgregor@apple.com>2011-11-02 17:26:05 +0000
commit38738fcace68630bbbfe174c6a3698a4c94b3dc9 (patch)
treed27866705ab25217a50b1c2bcfd8cfdf73b12295 /lib/AST/StmtProfile.cpp
parentb09a33c14cd8bc15925b9d1ba52a789da6700704 (diff)
Use StringLiteral::getBytes(), not StringLiteral::getString(), when profiling the expression, so that it works for non-UTF8 strings.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143550 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/StmtProfile.cpp')
-rw-r--r--lib/AST/StmtProfile.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/AST/StmtProfile.cpp b/lib/AST/StmtProfile.cpp
index 93b2f65818..db97e59804 100644
--- a/lib/AST/StmtProfile.cpp
+++ b/lib/AST/StmtProfile.cpp
@@ -275,7 +275,7 @@ void StmtProfiler::VisitImaginaryLiteral(const ImaginaryLiteral *S) {
void StmtProfiler::VisitStringLiteral(const StringLiteral *S) {
VisitExpr(S);
- ID.AddString(S->getString());
+ ID.AddString(S->getBytes());
ID.AddInteger(S->getKind());
}