From: george.marrows@... (George Marrows) Date: 2004-08-04T23:21:30+09:00 Subject: Re: Ruby 2 parser/compiler > I was wondering if the Ruby 2 parser/compiler will be written in Ruby. > It could be possible to do so, using at the beginning Ruby 1.9 to run > it and when it is ready, it could compile itself and be run into the > Rite virtual machine. I read that the Perl 6 compiler will be written > in Perl, so why not the Ruby one ? ByteCodeRuby [1] partially uses this approach. The parser is Ruby 1.8.1's with the internal NODEs then made available to Ruby code using Ruth [2]. BCR's compiler is written in Ruby and compiles the NODE tree to its own bytecode format. The bytecode is then run by BCR's bytecode runner (written in C). The latest CVS code for BCR moves onto the next stage: rather than Ruby 1.8.1 running the compiler code, BCR can run it itself from saved bytecode files. It all gets a bit circular and difficult to describe, but it does work! [1] http://rubyforge.org/projects/bytecoderuby/. The project has been very sleepy recently, but I'm hoping to make a new release soon. [2] A (dead?) project of Robert Feldt's. Bundled with BCR.