Re: How to use flex/bison with an inverted flow of control?

Hans-Peter Diettrich <DrDiettrich@compuserve.de>
23 Dec 2005 18:02:41 -0500

          From comp.compilers

Related articles
How to use flex/bison with an inverted flow of control? bob_rossi@cox.net (Bob) (2005-12-19)
Re: How to use flex/bison with an inverted flow of control? dickey@saltmine.radix.net (Thomas Dickey) (2005-12-19)
Re: How to use flex/bison with an inverted flow of control? cfc@shell01.TheWorld.com (Chris F Clark) (2005-12-19)
Re: How to use flex/bison with an inverted flow of control? DrDiettrich@compuserve.de (Hans-Peter Diettrich) (2005-12-23)
Re: How to use flex/bison with an inverted flow of control? RLake@oxfam.org.uk (2005-12-24)
Re: How to use flex/bison with an inverted flow of control? clint@0lsen.net (Clint Olsen) (2005-12-30)
| List of all articles for this month |

From: Hans-Peter Diettrich <DrDiettrich@compuserve.de>
Newsgroups: comp.compilers
Date: 23 Dec 2005 18:02:41 -0500
Organization: Compilers Central
References: 05-12-049
Keywords: yacc
Posted-Date: 23 Dec 2005 18:02:41 EST

Bob wrote:


> Instead of bison asking for the tokens, I would like to give it one
> token at a time, and have it tell me when it's done. That way, I can
> give it data as it arrives to me. Are there any reliable open source
> projects out there that work like this?


You want a "reversed" parser logic, where the input module calls the
lexer, which in turn calls the parser...?
An interesting idea, but perhaps a bit away from the main stream
development.


The simplest solution were a separate parser/lexer thread, which is
suspended in the fetch of the next token, as long as no further input is
available.


DoDi


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.