]> granicus.if.org Git - clang/commitdiff
Clean up two comments
authorDouglas Gregor <dgregor@apple.com>
Fri, 20 May 2011 15:00:53 +0000 (15:00 +0000)
committerDouglas Gregor <dgregor@apple.com>
Fri, 20 May 2011 15:00:53 +0000 (15:00 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@131727 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Sema/Initialization.h
lib/Sema/SemaStmt.cpp

index e83e5c0ccfdaa55d65b3a071b552b544795ae0a9..b64a63fb69229d1f254c8469735c6b89381f5c65 100644 (file)
@@ -101,7 +101,8 @@ private:
       /// the temporary is being created.
       unsigned Location;
       
-      /// \brief Whether the 
+      /// \brief Whether the entity being initialized may end up using the
+      /// named return value optimization (NRVO).
       bool NRVO;
     } LocAndNRVO;
     
index 60fcb10d53610101f50c66f2a0a568ad9b3b2f48..536e86573b4fcccc458cbb21a824a1c3b7f37ebb 100644 (file)
@@ -1456,7 +1456,10 @@ Sema::ActOnBreakStmt(SourceLocation BreakLoc, Scope *CurScope) {
 /// \param E The expression being returned from the function or block, or
 /// being thrown.
 ///
-/// \param AllowFunctionParameter
+/// \param AllowFunctionParameter Whether we allow function parameters to
+/// be considered NRVO candidates. C++ prohibits this for NRVO itself, but
+/// we re-use this logic to determine whether we should try to move as part of
+/// a return or throw (which does allow function parameters).
 ///
 /// \returns The NRVO candidate variable, if the return statement may use the
 /// NRVO, or NULL if there is no such candidate.