|
Boost : |
From: David Abrahams (dave_at_[hidden])
Date: 2007-03-15 17:09:03
on Sat Mar 10 2007, Jens Müller <jens.mueller-AT-ira.uka.de> wrote:
> Thomas Witt schrieb:
>> Jens Müller wrote:
>>> From leda_graph.hpp:
>>>
>>> class out_edge_iterator
>>> : public iterator_facade<out_edge_iterator,
>>> leda::edge,
>>> bidirectional_traversal_tag,
>>> const leda::edge&,
>>> const leda::edge*>
>>>
>>> Can someone explain to me the parameter "const leda::edge*"?
>>
>> I can't explain it to you, but it looks suspiciously as if the author meant
>>
>> class out_edge_iterator
>> : public iterator_facade<
>> out_edge_iterator
>> , leda::edge const
>> , bidirectional_traversal_tag>
>
> If I make these change (for all n occurences of the above), my program
> using leda_graph.hpp still works fine ...
Then I'm betting you didn't have very complete tests for your original
iterator. Did you try running it through the appropriate concept
checks
boost::function_requires<
boost_concepts::BidirectionalIteratorConcept<out_edge_iterator> >();
for example?
-- Dave Abrahams Boost Consulting www.boost-consulting.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk