[cfe-dev] libTooling Questions

Manuel Klimek klimek at google.com
Wed Aug 15 13:26:26 PDT 2012


On Mon, Aug 13, 2012 at 3:12 AM, Philip Craig <philipjcraig at gmail.com> wrote:
> On Mon, Aug 13, 2012 at 6:42 AM, Jens Weller <JensWeller at gmx.de> wrote:
>> Referring to the example:
>> http://clang.llvm.org/docs/RAVFrontendAction.html
>>
>> Lets say I add a nother visiting method, for methoddeclaration.
>> How to match in the invocation of the methodhandler, which class this one belongs to?
>> Do I get a fully qualified name (e.g. myclass::foo) or just foo.
>
> For the following code, only the second declaration of foo will have
> the 'A::' NestedNameSpecifier.

I'm not sure what you're referring to here...

Cheers,
/Manuel

>
> class A {
>   void foo();
> };
>
> void A::foo() {}
>
> But you can still get the class using CXXMethodDecl::getParent().
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev



More information about the cfe-dev mailing list