Ooops, I did not set 'shouldVisitDeclSpecifiers= true'.
The code is working just fine now.
Thank you!
From: cdt-dev-bounces@xxxxxxxxxxx
[mailto:cdt-dev-bounces@xxxxxxxxxxx] On Behalf Of Schorn, Markus
Sent: Friday, April 24, 2009 3:59 AM
To: CDT General developers list.
Subject: RE: [cdt-dev] Looking for enumeration declarations
If you have set 'shouldVisitDeclSpecifiers= true', then this would
be unexpected behavior for
which you should file a bug.
Markus.
From:
cdt-dev-bounces@xxxxxxxxxxx [mailto:cdt-dev-bounces@xxxxxxxxxxx] On Behalf
Of David Glaser
Sent: Friday, April 24, 2009 3:55 AM
To: CDT General developers list.
Subject: [cdt-dev] Looking for enumeration declarations
Importance: Low
I have an interesting problem. I am using the
CPPASTVisitor (CDT 5.0.2) class to traverse an AST looking for enumeration
declarations.
The problem I have is that the “visit(IASTDeclSpecifier)” is not
called for enumeration declarations. However, the “visit(IASTEnumerator)”
method is called and I can retrieve the parent and it is a
CPPASTEnumerationSpecifier which indirectly implements IASTDeclSpecifier.
Is this a bug or expected behavior?
-David