Phil et al.:
I think I can have an operational lexer/parser ready for general
experimentation in about two weeks or so. It will be a DLL you can
dynamically link to and/or a LIB file that you can statically link to in C
or C++ (depending on how you compile it). The goal is to provide a 100% Ruby
1.7 compatible, general-purpose syntax lexer-parser and an API for
traversing the generated AST, whatever your purpose is - interpreting, code
analysis, compiling to C code, compiling to byte code, etc. It will be C
compatible so you could theoretically call it from Ruby/DL for basic
parsing, obviating the need to code in C/C++ for those C-sick types who get
queasy at the mere sight of declared variables, asterisks, ampersands and
squiggley braces.
Not sure about how it will stack up to Ruth; I haven’t seen that. Got a
link? I couldn’t find it in RAA doing a brain-dead “CTRL-F” search for
"Ruth".
– Bob Calco
%% -----Original Message-----
%% From: Phil Tomson [mailto:ptkwt@shell1.aracnet.com]
%% Sent: Tuesday, September 17, 2002 2:33 AM
%% To: ruby-talk ML
%% Subject: Re: Why are parser tools rarely used in ruby?
%%
%%
%% In article 001301c25dea$5dfbaae0$d501a8c0@TECHNO,
···
%% Rich Kilmer rich@infoether.com wrote:
%% >Just to put in a little plug for a friend…Bob Calco is actively
%% >working on a c-parser for Ruby code based on Matz’s parse.y file that
%% >detaches the Ruby source parsing from the Runtime. Its going to build
%% >c-structures of the parsed AST and will be usable by Ruby programs (to
%% >parse Ruby) examples of which are the FreeRIDE IDE for fast source
%% >parsing. It will also be useful for other languages that want to parse
%% >Ruby (through C).
%% >
%%
%% So we’ll be able to get the AST for the currently running program? Any
%% schedule for the initial release? Does Bob need any help? I’m thinking
%% this might be useful for Cardinal.
%%
%% BTW: Is this similar to Ruth which I belive is also based on Matz’
%% parse.y file?
%%
%% Phil
%%