diff options
author | Anders Carlsson <andersca@mac.com> | 2009-12-15 20:51:39 +0000 |
---|---|---|
committer | Anders Carlsson <andersca@mac.com> | 2009-12-15 20:51:39 +0000 |
commit | 0ece491d8f62ce67f047491a6703fac0d3bd4ff4 (patch) | |
tree | 44763d144371c81c8aaa37e6165fb18b919c1537 /lib/Sema/SemaStmt.cpp | |
parent | 4608459d918261275af147b4c22351469f7ebea1 (diff) |
ShouldDestroyTemporaries? I don't think so.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91450 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaStmt.cpp')
-rw-r--r-- | lib/Sema/SemaStmt.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/Sema/SemaStmt.cpp b/lib/Sema/SemaStmt.cpp index de67a5f1a7..acf3e3aad7 100644 --- a/lib/Sema/SemaStmt.cpp +++ b/lib/Sema/SemaStmt.cpp @@ -1053,7 +1053,7 @@ Sema::ActOnReturnStmt(SourceLocation ReturnLoc, ExprArg rex) { << RetValExp->getSourceRange(); } - RetValExp = MaybeCreateCXXExprWithTemporaries(RetValExp, true); + RetValExp = MaybeCreateCXXExprWithTemporaries(RetValExp); } return Owned(new (Context) ReturnStmt(ReturnLoc, RetValExp)); } @@ -1098,7 +1098,7 @@ Sema::ActOnReturnStmt(SourceLocation ReturnLoc, ExprArg rex) { // FIXME: Leaks RetValExp on error. if (PerformCopyInitialization(RetValExp, FnRetType, "returning", Elidable)){ // We should still clean up our temporaries, even when we're failing! - RetValExp = MaybeCreateCXXExprWithTemporaries(RetValExp, true); + RetValExp = MaybeCreateCXXExprWithTemporaries(RetValExp); return StmtError(); } @@ -1106,7 +1106,7 @@ Sema::ActOnReturnStmt(SourceLocation ReturnLoc, ExprArg rex) { } if (RetValExp) - RetValExp = MaybeCreateCXXExprWithTemporaries(RetValExp, true); + RetValExp = MaybeCreateCXXExprWithTemporaries(RetValExp); return Owned(new (Context) ReturnStmt(ReturnLoc, RetValExp)); } |