Boost logo

Boost :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2003-01-29 08:20:38


Jeremy,

suppose I got lazy and don't want my graph algorithm to be passed a graph
which does not have internal edge_weight property. What's the best way to
check? I can do

    get(edge_weight, g);

but that causes compile error in instantination deeps. What I'd like is
something like:

     BOOST_STATIC_ASSERT(has_property<edge_weight_t, G>::value);

Is it possible now? If not, is this a reasonable feature?

- Volodya


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