Re: LALR (was Re: Working Group Proposal)

[email protected] (Nick Ing-Simmons)
Newsgroups perl.bootstrap
Message-ID <E13GuqN-0001QE-00@roam1>
Chip Salzenberg <[email protected]> writes:
>According to Dan Sugalski:
>> Might as well go all the way, then--separate out the lexer/parser,
>> the bit that turns the parsed syntax into an optree, the optimizer,
>> and the backend that actually executes perl. Which, thinking about
>> it, isn't that bad an idea [...]
>
>This isn't new.  It's pretty much pluggable right now in Perl 5 --
>just make an XS that does what toke.c and perly.y do, maybe create a
>hook for yyparse, and you're off.
>
>The fact that people haven't used this opportunity may tell us
>something.  Or maybe not.

As one of those well able to do the plugging, parsing and lexing what
scared me off was the black magic of the op "tree" - which is neither
a parse tree in traditional sense, nor threaded code as in FORTH but 
a weird hybrid.  My cache friendly data structures idea might result
in having a tree (for parse, symbols introspection) and threaded code
for execution.

-- 
Nick Ing-Simmons
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.