Re: How do I return more than one tag from production?

Eric Ludlam <[email protected]> Wed, 24 Feb 2016 21:10:38 -0500
Newsgroups gmane.emacs.semantic
Message-ID <[email protected]>
On 02/21/2016 11:17 AM, Gracjan Polak wrote:
> Do I understand correctly that EXPANDFULL has iteration logic inside?

Yes.  EXPANDFULL has built-in iteration so you just need to pass in a 
nonterminal that will find one tag, and it will do the repeating 
operation for you.

You will see a lot of EXPANDFULL examples that might find a list:

my_tag : PAREN_BLOCK
  	(EXPANDFULL $1 parse_list)
        ;

parse_list : OPEN_PAREN
		()
            | CLOSE_PAREN
		()
	   | parse_one_subtag
		( ... )
	   ;


All tags created from an EXPANDFULL will also have a special 
reparse-symbol associated with it so the incremental parser knows how to 
do the incremental parsing operation.

There is also plain EXPAND if you just want to call into the parser once 
without the overhead of tag handling.

Eric

------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140