aboutsummaryrefslogtreecommitdiff
path: root/lib/AST/Expr.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2011-01-03 19:04:46 +0000
committerDouglas Gregor <dgregor@apple.com>2011-01-03 19:04:46 +0000
commitaa165f8458b51c546bebff947343e1a36f3594cb (patch)
tree40e3a24dccd756644c861834b7ff5a26980999aa /lib/AST/Expr.cpp
parente776f88430eb77ce8d58f2e6ec10da1383b71de8 (diff)
Refactor the tree transform's many loops over sets of expressions
(transforming each in turn) into calls into one central routine (TransformExprs) that transforms a list of expressions. This refactoring is preparatory work for pack expansions whose in an expression-list. No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@122761 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/Expr.cpp')
-rw-r--r--lib/AST/Expr.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/AST/Expr.cpp b/lib/AST/Expr.cpp
index d8bb0af018..3a71883419 100644
--- a/lib/AST/Expr.cpp
+++ b/lib/AST/Expr.cpp
@@ -2300,7 +2300,7 @@ ObjCMessageExpr::ObjCMessageExpr(QualType T,
SelectorLoc(SelLoc), LBracLoc(LBracLoc), RBracLoc(RBracLoc)
{
setReceiverPointer(Receiver);
- Stmt **MyArgs = getArgs();
+ Expr **MyArgs = getArgs();
for (unsigned I = 0; I != NumArgs; ++I) {
if (Args[I]->isTypeDependent())
ExprBits.TypeDependent = true;
@@ -2331,7 +2331,7 @@ ObjCMessageExpr::ObjCMessageExpr(QualType T,
SelectorLoc(SelLoc), LBracLoc(LBracLoc), RBracLoc(RBracLoc)
{
setReceiverPointer(Receiver);
- Stmt **MyArgs = getArgs();
+ Expr **MyArgs = getArgs();
for (unsigned I = 0; I != NumArgs; ++I) {
if (Args[I]->isTypeDependent())
ExprBits.TypeDependent = true;
@@ -2928,10 +2928,10 @@ Stmt::child_iterator ObjCProtocolExpr::child_end() {
Stmt::child_iterator ObjCMessageExpr::child_begin() {
if (getReceiverKind() == Instance)
return reinterpret_cast<Stmt **>(this + 1);
- return getArgs();
+ return reinterpret_cast<Stmt **>(getArgs());
}
Stmt::child_iterator ObjCMessageExpr::child_end() {
- return getArgs() + getNumArgs();
+ return reinterpret_cast<Stmt **>(getArgs() + getNumArgs());
}
// Blocks