From: Andreas Pokorny (andreas.pokorny_at_[hidden])
Date: 2006-08-06 13:27:20
For my thesis work I wrote a DSL framework based on fusion-2. It fulfills a
similar purpose like boost::xpressive's proto. Compared to proto, the framework
has a rule system, allowing the user define the language rules of a domain.
Is there any interest in a library like that?
Some additional information:
All operators defined by the framework verify the correctness of expressions
querying the domain rules the expression parameters belong to, using EnableIf.
Foreign types can be integrated into a domain by specifing adaptation rules.
The framework separates operators (or DSL functions) from language rules.
Consequently rules may
introduces this layer of indirection to achieve a consistent
definition of language rules.
Expressions have a varying set of attributes stored in a fusion-2 map, e.g.
the expressions domain is identified by an attribute inside that map. The
set of attributes is controlled by the domain rules. Apart from returning the
validity of expressions, rules also have to provide a result type. Hence the
rule code tends to grow complex, with an increasing amount of attributes.
The library lacks a proper documentation, and requires some interface changes
to simplify attribute update operations. Before working on that, I wanted to see
if there is interest at all.
I used the framework to implement a matrix library with a signle frontend and
multiple backends, that could be picked and combined on a by expression basis.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk