summaryrefslogtreecommitdiffstats
path: root/lib/Sema/SemaExprObjC.cpp
diff options
context:
space:
mode:
authorrdivacky <rdivacky@FreeBSD.org>2010-03-16 16:52:15 +0000
committerrdivacky <rdivacky@FreeBSD.org>2010-03-16 16:52:15 +0000
commit1033b7c1e32962948b01a25145829f17bc70a8de (patch)
tree52aebaff3a47b97dbac434530524c30967468412 /lib/Sema/SemaExprObjC.cpp
parent27c39af73c0d7d0b97e57b3a905040d4cefc9708 (diff)
downloadFreeBSD-src-1033b7c1e32962948b01a25145829f17bc70a8de.zip
FreeBSD-src-1033b7c1e32962948b01a25145829f17bc70a8de.tar.gz
Update clang to r98631.
Diffstat (limited to 'lib/Sema/SemaExprObjC.cpp')
-rw-r--r--lib/Sema/SemaExprObjC.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaExprObjC.cpp b/lib/Sema/SemaExprObjC.cpp
index c60455d..c98ba43 100644
--- a/lib/Sema/SemaExprObjC.cpp
+++ b/lib/Sema/SemaExprObjC.cpp
@@ -106,7 +106,7 @@ Expr *Sema::BuildObjCEncodeExpression(SourceLocation AtLoc,
// which is an array type.
StrTy = Context.CharTy;
// A C++ string literal has a const-qualified element type (C++ 2.13.4p1).
- if (getLangOptions().CPlusPlus)
+ if (getLangOptions().CPlusPlus || getLangOptions().ConstStrings)
StrTy.addConst();
StrTy = Context.getConstantArrayType(StrTy, llvm::APInt(32, Str.size()+1),
ArrayType::Normal, 0);
OpenPOWER on IntegriCloud