get the name of the node being constructed when in a rule
I have a simple question: how is it possible to get the name of the
node of the tree being in construction, when in a rule of the Tree
In fact, we could use getAST(), and then getType(), surely. But I
wonder if this doesn't take too much time:
what I would like to do is this:
I concatenate some elements, and, when I have single symbols
successively, I want to put them in an array. But it is not so simple
to know when an element is a single symbol: I need sometimes a great
lookahead (there are different types of symbols, and, if they are
suffixed, they aren't of type symbol any more, and so on)...
So, if I could know, AFTER having recognized that an element is a
single symbol, if the node is concatenation, I could do something!!..
Thanks for your help