aaron.ballman added a comment.

In D130055#3683822 <https://reviews.llvm.org/D130055#3683822>, @jkorous wrote:

> In D130055#3683173 <https://reviews.llvm.org/D130055#3683173>, @aaron.ballman 
> wrote:
>
>> Are there circumstances where we cannot "simply" infer this from the 
>> constructor itself? (After instantiation) we know the class hierarchy, we 
>> know the data members, and we know the ctor init list/in-class initializers, 
>> so it seems like we should be able to recursively mark a constructor as yolo 
>> for the user rather than making them write it themselves.
>
> The init list can be in a different translation unit (TU) which means we 
> can't compute all properties just from the code in current TU. (Unless we 
> decide to pessimistically consider such unanalyzable constructors as 
> non-initializing.)

I was imagining that this analysis is most powerful when done as a cross-TU 
static analysis pass. However, having markings for when there's less context is 
definitely a benefit, so that's a great point.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D130055/new/

https://reviews.llvm.org/D130055

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to