diff options
author | Anders Carlsson <andersca@mac.com> | 2011-04-14 00:40:03 +0000 |
---|---|---|
committer | Anders Carlsson <andersca@mac.com> | 2011-04-14 00:40:03 +0000 |
commit | 3e2193ce5feb2feb092e5ae615e85148e06e9fd2 (patch) | |
tree | 3e08e06ac3a9a0cf0c798a7f20970bf2a056bc7e /lib/Rewrite/RewriteObjC.cpp | |
parent | ddd7a3d6dc98c5c6e807910d255b738d8559a231 (diff) |
Add a flag to StringLiteral to keep track of whether the string is a pascal string or not.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129488 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Rewrite/RewriteObjC.cpp')
-rw-r--r-- | lib/Rewrite/RewriteObjC.cpp | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/lib/Rewrite/RewriteObjC.cpp b/lib/Rewrite/RewriteObjC.cpp index ff4c5e9152..6ab96effe3 100644 --- a/lib/Rewrite/RewriteObjC.cpp +++ b/lib/Rewrite/RewriteObjC.cpp @@ -2111,7 +2111,8 @@ Stmt *RewriteObjC::RewriteAtEncode(ObjCEncodeExpr *Exp) { std::string StrEncoding; Context->getObjCEncodingForType(Exp->getEncodedType(), StrEncoding); Expr *Replacement = StringLiteral::Create(*Context,StrEncoding.c_str(), - StrEncoding.length(), false,StrType, + StrEncoding.length(), + false, false, StrType, SourceLocation()); ReplaceStmt(Exp, Replacement); @@ -2130,7 +2131,8 @@ Stmt *RewriteObjC::RewriteAtSelector(ObjCSelectorExpr *Exp) { SelExprs.push_back(StringLiteral::Create(*Context, Exp->getSelector().getAsString().c_str(), Exp->getSelector().getAsString().size(), - false, argType, SourceLocation())); + false, false, argType, + SourceLocation())); CallExpr *SelExp = SynthesizeCallToFunctionDecl(SelGetUidFunctionDecl, &SelExprs[0], SelExprs.size()); ReplaceStmt(Exp, SelExp); @@ -2796,7 +2798,7 @@ Stmt *RewriteObjC::SynthMessageExpr(ObjCMessageExpr *Exp, ClsExprs.push_back(StringLiteral::Create(*Context, ClassDecl->getIdentifier()->getNameStart(), ClassDecl->getIdentifier()->getLength(), - false, argType, SourceLocation())); + false, false, argType, SourceLocation())); CallExpr *Cls = SynthesizeCallToFunctionDecl(GetMetaClassFunctionDecl, &ClsExprs[0], ClsExprs.size(), @@ -2875,8 +2877,8 @@ Stmt *RewriteObjC::SynthMessageExpr(ObjCMessageExpr *Exp, ClsExprs.push_back(StringLiteral::Create(*Context, clsName->getNameStart(), clsName->getLength(), - false, argType, - SourceLocation())); + false, false, + argType, SourceLocation())); CallExpr *Cls = SynthesizeCallToFunctionDecl(GetClassFunctionDecl, &ClsExprs[0], ClsExprs.size(), @@ -2907,7 +2909,7 @@ Stmt *RewriteObjC::SynthMessageExpr(ObjCMessageExpr *Exp, ClsExprs.push_back(StringLiteral::Create(*Context, ClassDecl->getIdentifier()->getNameStart(), ClassDecl->getIdentifier()->getLength(), - false, argType, SourceLocation())); + false, false, argType, SourceLocation())); CallExpr *Cls = SynthesizeCallToFunctionDecl(GetClassFunctionDecl, &ClsExprs[0], ClsExprs.size(), @@ -2989,7 +2991,7 @@ Stmt *RewriteObjC::SynthMessageExpr(ObjCMessageExpr *Exp, SelExprs.push_back(StringLiteral::Create(*Context, Exp->getSelector().getAsString().c_str(), Exp->getSelector().getAsString().size(), - false, argType, SourceLocation())); + false, false, argType, SourceLocation())); CallExpr *SelExp = SynthesizeCallToFunctionDecl(SelGetUidFunctionDecl, &SelExprs[0], SelExprs.size(), StartLoc, |