Boost logo

Boost :

Subject: [boost] [generic] status?
From: lcaminiti (lorcaminiti_at_[hidden])
Date: 2012-05-05 12:28:28


Hello all,

What's the status of Matt Calabrese's Boost.Generic library?

I was looking at the similarities between Boost.Generic and Boost.Contract
syntax, and I think the following syntax can be implemented to define
concepts, concepts_maps, axioms, etc

CONTRACT_CONCEPT(
    concept (Iterator) ( typename X ) extends( Semiregular<X> )
    (
        typename(MoveConstructible) reference, as typename X::reference ,
        typename(MoveConstructible) postinc_result ,
        requires HasDereference<postinc_result> ,

        (reference) operator(*)(deref) ( X& ) ,
        (reference) operator(*)(deref) ( X&& ) ,
        (X&) operator(++)(preinc) ( X& ) ,
        (postinc_result) operator(++)(postinc) ( X&, int )
    )
)

More examples here (auto concepts, concept maps, axioms, etc):
http://contractpp.svn.sourceforge.net/viewvc/contractpp/trunk/doc/html/contract__/grammar.html#contract__.grammar.possible_concept_definition_syntax

If there was real interest using this syntax to define concepts, either the
syntax could replace the on of Boost.Generic or Boost.Contract could provide
the syntax and then use Boost.Generic behind the scene to actually define
the concepts (same as Boost.Contract now does for Boost.Parameter).

What do you think?

Thanks.
--Lorenzo

--
View this message in context: http://boost.2283326.n4.nabble.com/boost-generic-status-tp4611363.html
Sent from the Boost - Dev mailing list archive at Nabble.com.

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk