Boost logo

Boost :

Subject: [boost] spoiled function declarations
From: Lorenzo Caminiti (lorcaminiti_at_[hidden])
Date: 2010-05-05 09:27:50

Hello all,

I have been looking to which Boost libraries provide an interface that
"spoils" usual C++ function declaration using macros. So far I found
that both Boost.ConceptCheck and Boost.Parameter replace usual C++
function declaration using macros (see sample code below).

Do you know of any other Boost library that "spoils" usual C++
function declaration?


    template<typename RanIter>
        (void)) // return type within macro instead that before function name
     stable_sort(RanIter,RanIter) {

Boost.Parameter (quite a bit more involved):

        (void), // 1. parenthesized return type
        depth_first_search, // 2. name of the function template
        tag, // 3. namespace of tag types
        (required (graph, *) ) // 4. one required parameter, and
        (optional // four optional parameters, with defaults
            (visitor, *, boost::dfs_visitor<>())
            (root_vertex, *, *vertices(graph).first)
            (index_map, *, get(boost::vertex_index,graph))
            (in_out(color_map), *,
                default_color_map(num_vertices(graph), index_map) )
        // ... body of function goes here...
        // use graph, visitor, index_map, and color_map

Thank you very much.


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