[PATCH] D33735: [DebugInfo] Add ThisOrSelf attribute for emission of FlagObjectPointer.

John McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jun 1 10:38:28 PDT 2017


rjmccall added a comment.

In https://reviews.llvm.org/D33735#770318, @aaron.ballman wrote:

> In https://reviews.llvm.org/D33735#770296, @ABataev wrote:
>
> > In https://reviews.llvm.org/D33735#770288, @aaron.ballman wrote:
> >
> > > Can you help me to understand what problem is being solved with this new attribute? Under what circumstances would the first argument be an `ImplicitParamDecl` but not an implicit this or self?
> >
> >
> > For captured regions an outlined function is created, where all parameters are ImplicitParamDecls. And the very first parameter is wrongly treated as 'this' argument of the member function.
>
>
> Ah, thank you! That makes sense to me, but it begs the question: why an attribute rather than a bit on ImplicitParamDecl?


I agree: it would make more sense for ImplicitParamDecl to store a Kind that would always be provided at construction.


https://reviews.llvm.org/D33735





More information about the cfe-commits mailing list