summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaStmt.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2009-12-18 17:31:58 +0000
committerDouglas Gregor <dgregor@apple.com>2009-12-18 17:31:58 +0000
commit4a2ce65dbf84df905d5269bc4f73ee4bdfcd5aa0 (patch)
treebd9829a5df56e19ec513b7578afd55e5abeb3837 /clang/lib/Sema/SemaStmt.cpp
parent28a133d6028df72e614ea1944302334b094339f3 (diff)
downloadbcm5719-llvm-4a2ce65dbf84df905d5269bc4f73ee4bdfcd5aa0.tar.gz
bcm5719-llvm-4a2ce65dbf84df905d5269bc4f73ee4bdfcd5aa0.zip
Try to de-bork DISABLE_SMART_POINTERS build
llvm-svn: 91696
Diffstat (limited to 'clang/lib/Sema/SemaStmt.cpp')
-rw-r--r--clang/lib/Sema/SemaStmt.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/clang/lib/Sema/SemaStmt.cpp b/clang/lib/Sema/SemaStmt.cpp
index e09243372eb..c2a3a3a8ca6 100644
--- a/clang/lib/Sema/SemaStmt.cpp
+++ b/clang/lib/Sema/SemaStmt.cpp
@@ -1126,17 +1126,17 @@ Sema::ActOnReturnStmt(SourceLocation ReturnLoc, ExprArg rex) {
// In C++ the return statement is handled via a copy initialization.
// the C version of which boils down to CheckSingleAssignmentConstraints.
- rex = PerformCopyInitialization(
- InitializedEntity::InitializeResult(ReturnLoc,
- FnRetTypeLoc),
- SourceLocation(),
- Owned(RetValExp));
- if (rex.isInvalid()) {
+ OwningExprResult Res = PerformCopyInitialization(
+ InitializedEntity::InitializeResult(ReturnLoc,
+ FnRetTypeLoc),
+ SourceLocation(),
+ Owned(RetValExp));
+ if (Res.isInvalid()) {
// FIXME: Cleanup temporaries here, anyway?
return StmtError();
}
- RetValExp = rex.takeAs<Expr>();
+ RetValExp = Res.takeAs<Expr>();
if (RetValExp)
CheckReturnStackAddr(RetValExp, FnRetType, ReturnLoc);
}
OpenPOWER on IntegriCloud