[cfe-commits] r151259 - /cfe/trunk/lib/CodeGen/CGExprCXX.cpp

Douglas Gregor dgregor at apple.com
Thu Feb 23 09:07:43 PST 2012


Author: dgregor
Date: Thu Feb 23 11:07:43 2012
New Revision: 151259

URL: http://llvm.org/viewvc/llvm-project?rev=151259&view=rev
Log:
Replace a use of hasTrivialDefaultConstructor() with the appropriate
isTrivial() call.

Modified:
    cfe/trunk/lib/CodeGen/CGExprCXX.cpp

Modified: cfe/trunk/lib/CodeGen/CGExprCXX.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGExprCXX.cpp?rev=151259&r1=151258&r2=151259&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CGExprCXX.cpp (original)
+++ cfe/trunk/lib/CodeGen/CGExprCXX.cpp Thu Feb 23 11:07:43 2012
@@ -895,7 +895,7 @@
     if (const CXXConstructExpr *CCE = dyn_cast_or_null<CXXConstructExpr>(Init)){
       CXXConstructorDecl *Ctor = CCE->getConstructor();
       bool RequiresZeroInitialization = false;
-      if (Ctor->getParent()->hasTrivialDefaultConstructor()) {
+      if (Ctor->isTrivial()) {
         // If new expression did not specify value-initialization, then there
         // is no initialization.
         if (!CCE->requiresZeroInitialization() || Ctor->getParent()->isEmpty())





More information about the cfe-commits mailing list