[bitc-dev] why the switch to c++?

Jonathan S. Shapiro shap at eros-os.com
Wed Feb 11 16:29:46 EST 2009


On Wed, Feb 11, 2009 at 4:13 PM, <"jan"rtm443x at gmail.com> wrote:

> Quick think:
> "A parser generator that can handle actions written in BitC"
> Or maybe a trivial c lex/yacc (or similar) front end which sucks in the
> new surface syntax and spits out the old which is then piped straight
> to the old compiler? It's a vile but quick hack, and pretty portable.


This misses the whole point, which is for the compiler to be entirely
written in bitc. We need a parser regardless of the surface syntax.

Or just write the new syntax lexer/parser by hand. Not a lot of fun but
> not too hard if it's a sensible syntax (ie. minimal lookahead).


It's currently single token lookahead, but its 174 productions at the moment
and about to grow. I'm not even going to *try* to maintain that by hand, and
attempting to do so would make validation harder.

shap
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.coyotos.org/pipermail/bitc-dev/attachments/20090211/56e78d89/attachment.html 


More information about the bitc-dev mailing list