>>>>> "SF" == Steve Fink <[EMAIL PROTECTED]> writes: SF> Handling the parser's state can be done in a backtracking DFA-like or a SF> direct NFA-like way. The NFA way is to keep track of all possible parse SF> states and advance each one in parallel based on the next token. The DFA SF> way is recursive descent, backing out of blind alleys and trying again, SF> keeping a single working hypothesis alive at a time. The DFA approach is SF> probably easier to undo user code in, because in the NFA case you have SF> to consider each token under the assumptions of all possible parses up SF> to that point. The NFA case has the advantage that you never have to SF> back up, so you can permanently forget about a token as soon as it SF> whizzes by. Can an NFA actually handle the interaction between the lexer and tokenizer? $foo = s;foo;bar;g; $foo = s#foo#bar#g; # change the world <chaim> -- Chaim Frenkel Nonlinear Knowledge, Inc. [EMAIL PROTECTED] +1-718-236-0183
- Re: Backtracking through the source Kurt D. Starsinic
- Re: Backtracking through the source Dan Sugalski
- Re: Backtracking through the source Nicholas Clark
- Re: Backtracking through the source Jarkko Hietaniemi
- Re: Backtracking through the source Tom Hughes
- Re: Backtracking through the source Simon Cozens
- Re: Backtracking through the source Tom Hughes
- Re: Backtracking through the source Simon Cozens
- Re: Backtracking through the source Tom Hughes
- Re: Backtracking through the sourc... Steve Fink
- Re: Backtracking through the s... Chaim Frenkel
- Re: Backtracking through the s... Steve Fink
- Re: Backtracking through the s... Dan Sugalski
- Re: Backtracking through the s... Dan Sugalski
- Re: Backtracking through the s... Simon Cozens
- Re: Backtracking through the s... David Grove
- Re: Backtracking through the s... Dan Sugalski
- Re: Backtracking through the s... Nicholas Clark
- Re: Backtracking through the s... Dan Sugalski
- Re: Backtracking through the s... Dan Sugalski
- Re: Backtracking through the s... Simon Cozens