diff options
author | Sebastian Redl <sebastian.redl@getdesigned.at> | 2008-12-11 21:36:32 +0000 |
---|---|---|
committer | Sebastian Redl <sebastian.redl@getdesigned.at> | 2008-12-11 21:36:32 +0000 |
commit | 2f7ece7c77eb17e24e8f0f4e1b7fb01aa5111f96 (patch) | |
tree | db787703eed9de3896aec2c6b2d6e9444681b76a /lib/Parse/ParseStmt.cpp | |
parent | 01f2ffacc427de6bef08fe138e8cae82ba1b30a3 (diff) |
Convert selected expression parsers to use smart pointers.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@60900 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Parse/ParseStmt.cpp')
-rw-r--r-- | lib/Parse/ParseStmt.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Parse/ParseStmt.cpp b/lib/Parse/ParseStmt.cpp index 35306a1e16..318d768f02 100644 --- a/lib/Parse/ParseStmt.cpp +++ b/lib/Parse/ParseStmt.cpp @@ -107,7 +107,7 @@ Parser::ParseStatementOrDeclaration(bool OnlyStatement) { return StmtError(); } else { // expression[opt] ';' - OwningExprResult Expr(Actions, ParseExpression()); + OwningExprResult Expr(ParseExpression()); if (Expr.isInvalid()) { // If the expression is invalid, skip ahead to the next semicolon. Not // doing this opens us up to the possibility of infinite loops if @@ -226,7 +226,7 @@ Parser::OwningStmtResult Parser::ParseCaseStatement() { assert(Tok.is(tok::kw_case) && "Not a case stmt!"); SourceLocation CaseLoc = ConsumeToken(); // eat the 'case'. - OwningExprResult LHS(Actions, ParseConstantExpression()); + OwningExprResult LHS(ParseConstantExpression()); if (LHS.isInvalid()) { SkipUntil(tok::colon); return StmtError(); @@ -379,7 +379,7 @@ Parser::OwningStmtResult Parser::ParseCompoundStatementBody(bool isStmtExpr) { } else { // Otherwise this was a unary __extension__ marker. Parse the // subexpression and add the __extension__ unary op. - OwningExprResult Res(Actions, ParseCastExpression(false)); + OwningExprResult Res(ParseCastExpression(false)); if (Res.isInvalid()) { SkipUntil(tok::semi); @@ -940,7 +940,7 @@ Parser::OwningStmtResult Parser::ParseGotoStatement() { // GNU indirect goto extension. Diag(Tok, diag::ext_gnu_indirect_goto); SourceLocation StarLoc = ConsumeToken(); - OwningExprResult R(Actions, ParseExpression()); + OwningExprResult R(ParseExpression()); if (R.isInvalid()) { // Skip to the semicolon, but don't consume it. SkipUntil(tok::semi, false, true); return StmtError(); |