[PATCH] D47067: Update NRVO logic to support early return
Dávid Bolvanský via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri May 25 04:44:13 PDT 2018
xbolva00 added inline comments.
================
Comment at: lib/Sema/Scope.cpp:128
- if (getEntity())
- return;
-
- if (NRVO.getInt())
- getParent()->setNoNRVO();
- else if (NRVO.getPointer())
- getParent()->addNRVOCandidate(NRVO.getPointer());
+ if (getParent())
+ getParent()->setNRVOCandidate(Candidate);
----------------
auto * Parent = getParent();
if (Parent)
Parent>setNRVOCandidate(Candidate);
?
Repository:
rC Clang
https://reviews.llvm.org/D47067
More information about the cfe-commits
mailing list