Hi, folks.
I'm a MARPA newbie, so my apologies if I am asking a question which is too obvious.
I have a prototype parser for a DSL - my customer needs me to deliver an AST for it, where each node knows the line number (and perhaps even column number) at which that expression or construct began in the input stream.
I have pored over the copious MARPA documentation and commentary by users, but I haven't yet understood how I can do this.
I thought perhaps I could attach an event to every terminal, and have the event callback ask the parser where it is in the input stream? If so, I'm not even sure how to do that.
I would be grateful for any advice.
-stefan