xazax.hun added inline comments.

Comment at: include/clang/Analysis/CFG.h:153
+  ConstructionContext() = default;
+  ConstructionContext(CXXConstructExpr *Constructor, Stmt *Trigger)
Maybe I am getting this wrong, but I think in this case the members will be 
default initialized and will get indeterminate values.
See: http://en.cppreference.com/w/cpp/language/default_initialization
> Default initialization is performed in three situations:
> ..
> 3) when a base class or a non-static data member is not mentioned in a 
> constructor initializer list and that constructor is called.
> The effects of default initialization are:
> if T is a non-POD (until C++11) class type ...
> if T is an array type, every element of the array is default-initialized;
> otherwise, nothing is done: the objects with automatic storage duration (and 
> their subobjects) are initialized to indeterminate values. 

Comment at: lib/Analysis/CFG.cpp:4402
+          stmt = SE->getStmt();
+        else if (auto CE = BI->getAs<CFGConstructor>())
+          stmt = CE->getConstructor();
So this is one of the places where subclassing would help? Could you measure 
the compile time regression after making `CFGStmt`'s `isKind` more complex?


cfe-commits mailing list

Reply via email to