|Differentiating all IASTDeclSpecifier [message #1726264]
||Thu, 10 March 2016 19:35
| Nicolas Anquetil
Registered: May 2010
I want to use CDT to parse a C++ project
I successfully created the IASTTranslationUnit, but when visiting it
(and children), I see that many node are visited by
public int visit(IASTDeclSpecifier node)
Looking for examples, I found other projects that solve this issue by
doing a list of
if (astNode instanceof XXX)
This does not seem like very good OO programming practice
is there no other way to do it?
Some method or attribute to check that would tell me what I need to know?
Or some way to tell the nodes to call the visitor on their real type?
Powered by FUDForum
. Page generated in 0.01766 seconds