home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.compilers      Compiler construction, theory, etc. (Mod      2,753 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 2,524 of 2,753   
   rockbrentwood@gmail.com to All   
   Yacc with multiple entry points.   
   09 Dec 19 16:13:06   
   
   There is a lot of saving and code-reuse possible if multiple entry points are   
   allowed in a parser generator. This can be done by a simple extension of the   
   LR process, but does complicate the issue of end-markers a little.   
      
   You'll see brief mention of it, by the way, here on page 199 of the Lex and   
   Yacc reference. https://books.google.com/books?id=vsHcnR4kXIAC&p   
   =PA199&lpg=PA199 authored by (... searching author page ...) Oh! The   
   moderator, John!   
      
   [I put the same trick on pp 163-164 of flex&bison.  Fiddle the lexer   
   so it sends the parser a fake token when it starts and use initial   
   rules with the fake token to select the real entry point.  That works   
   in plain yacc or bison.  -John]   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca