Boost logo

Boost :

Subject: Re: [boost] compile time parser generator
From: Martin Bidlingmaier (Martin.Bidlingmaier_at_[hidden])
Date: 2012-01-07 15:36:03

> No realistic discussion of such a proposal can be undertaken
> with reference to/ comparison with boost.spirit which has been
> in usage for 10 years and has been continually updated, enhanced
> and maintained over that period. You should start out by taking
> a careful look at spirit and contrast your proposal with this
> mature library used for the same purpose.
> Robert Ramey

I know boost.spirit, but it doesn't solve the same problem: boost.spirit creates a parser for parsing at run time, whereas my 'library' creates a parser that parses string literals at compile time (it could parse a string at run time as well, but it's not meant for that).
For example, this is an excerpt from main.cpp:

constexpr const_string< char > cstr = "2 + 54 * 2 + 83";
constexpr addition a( cstr );//cstr is processed at compile time
static_assert( a.eval() == 193 , "");

Empfehlen Sie GMX DSL Ihren Freunden und Bekannten und wir
belohnen Sie mit bis zu 50,- Euro!

Boost list run by bdawes at, gregod at, cpdaniel at, john at