Version française
Home     About     Download     Resources     Contact us    
Browse thread
Dypgen C++ grammar
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: skaller <skaller@u...>
Subject: Re: [Caml-list] Dypgen C++ grammar
On Mon, 2007-06-25 at 14:26 -0700, Taras Glek wrote:
> Hi Scott,
> Why write yet another incomplete C++ parser? You can already get a very 
> nice OCaml representation of a C++ program through olmar( 
> http://www.cs.ru.nl/~tews/olmar/ ).

Because last I looked, olmar doesn't work, and that's
because Elkhound and Elsa, on which they're based, don't work.
By that I mean, there are bugs. 

> If that doesn't suit your needs, why not point out the problems and 
> maybe work together to solve them? 

Elkhound and Elsa are both C++ programs, which creates 
portability issues, and the team maintaining them refused 
to cooperate with my requirements.

My system Felix consists of an Ocaml based compiler,
which generates C++ sources.

I actually have a *fork* of Elkhound built in to the
compile and run time system for generating parsers,
but this doesn't apply to parsing Felix sources:
I'm currently switching from Ocamlyacc to Dypgen as a
parser.

Frankly .. I want an embeddable Ocaml code: binding
to a C++ built executable is tricky (you'd need to
use some crud like XML as an interchange format),
and it isn't extensible.

Using Frontc/Cil, which is *also* part of Felix,
is much better -- I have already embedded part of
the C parsing capabilities directly into the Felix compiler.

The bottom line is that I want code written in Ocaml
because I'm sooooo sick of portability hassles.. :)

-- 
John Skaller <skaller at users dot sf dot net>
Felix, successor to C++: http://felix.sf.net