Archive for the ‘Parrot’ Category

Lateset Cardinal and Parrot News

Tuesday, September 12th, 2006

Well my thesis is finished so I’m able to spend more time working on Cardinal and Parrot.

This past week I wrote a PGE(Parrot Grammar Engine) grammar for C99.  At first thought this may sound funny.  A C parser for a dynamic language virtual machine?  Well almost all the dynamic languages being implemented on top of Parrot support C extensions.  Parrot itself has a both C extension interface and a C interface for embedding the Parrot virtual machine in other programs.

Language Extension builders often wish to make C function definitions and constants availible to the dynamic scripting language they are extending.  This is often accomplished with FFI(foriegn function interface) libraries.  Writing extension code, even with the help of FFI libraries often involves replicating information stored in C header files.  Having a C99 parser for Parrot helps to eliminate the manual process of replicating C constants and definitions in dynamic language extensions.  If eliminating replication isn’t possible, hopefully the process can be automated.

In the Cardinal realm, I was able to add support for Ruby BEGIN and END blocks to Cardinal today.  BEGIN blocks are code blocks that execute before the rest of the program begins.  END blocks execute after the program has finished but before the Ruby interpreter begins to shutdown.

Cardinal and Parrot are both in need of contributors.   Interested volunteers can contact me at tewky@yahoo.com.