How to keep AST for feature access?
- by greenoldman
Consider such code (let's say it is C++)
Foo::Bar.get().X
How one should keep the AST for this -- as "tree" with root at left Foo(Bar(get(X)), or with root at right (((Foo)Bar)get)X? Or maybe as a flat structure (list)?
The first one seems more convenient when resolving names, the second when working with it as expression.
I set tag parsing but I am asking from semantic analysis POV really (there is no such tag).