in reply to Re^5: Perl 6 - I hope it won't take a decade
in thread Perl 6 - I hope it won't take a decade

OK. What am I missing? All the PIR code I look at seems very similar to assembly language (with the possible exception that the jump instruction has been renamed goto ;-). Combine that with the fact the most descriptions (follow the link to PDF) pretty much state that "PIR is a slightly higher level language than PASM". I'm just curious, why isn't PGE written in (a possibly restricted version of) Perl6?
  • Comment on Re^6: Perl 6 - I hope it won't take a decade

Replies are listed 'Best First'.
Re^7: Perl 6 - I hope it won't take a decade
by dragonchild (Archbishop) on Jan 19, 2006 at 20:07 UTC
    PGE is the Perl Grammar Engine, but it's a Parrot distribution. It's meant to be usable in any language that runs on Parrot, not just Perl. In a way, it'll replace the pcre engine.

    My criteria for good software:
    1. Does it work?
    2. Can someone else come in, make a change, and be reasonably certain no bugs were introduced?
      Right. You'd use your Perl6 compiler (Pugs, for the sake of argument) to compile a P6 version of PGE down to PIR or PASM bytecode. Then you'd be able to use it with anything that runs under Parrot. Just like how CPAN6 libraries are supposed to be usable with Ruby-on-Parrot, Python-on-Parrot, etc.
Re^7: Perl 6 - I hope it won't take a decade
by chromatic (Archbishop) on Jan 19, 2006 at 19:38 UTC

    There's sort of a bootstrapping problem there.

      There's sort of a bootstrapping problem there.
      Que? Are you saying that there's been a review of the situation and for technical reasons it wouldn't be optimal? Or are you saying you don't understand how bootstrapping a compiler in general works? The hard work is already done, since you can use Pugs as your bootstrap compiler.

        Perhaps "the hard work" is done now but the C implementation of PGE predates pugs by several months. The PIR implementation of PGE was also started before pugs existed and substantial work was done before pugs was mature enough to even be an option. (I believe the PIR implementation first entered the parrot repository in April or May 2005, but much work had been done before then.)

        Besides using PIR for PGE is also a good case for "eating your own dog food" (IMHO) in that parrot was designed to do this stuff.

        But maybe you're right and a perl6 (pugs) implementation of PGE would be better (now). We could compile it down to PIR or PIL or Javascript or Haskell or whatever and use it many places. Maybe you should suggest it to pmichaud or if you really wanted to contribute to the community you could do the implementation yourself. Patches speak louder than words. :-)