|
Boost Users : |
From: Martin Mann (mmann_at_[hidden])
Date: 2008-08-07 06:23:03
Hi Dmitry,
thanks for your reply. Yes this might fix the problem. But than the
documentation of "add_edge" is missleading because it should hold for
vecS too.
Unfortunately I have to stick to vecS due to some other reasons like
automatic vertex indexing via properties etc. So I used the workaround
with first checking for the presence of the edge via "edge(..).second".
Thanks,
Martin
Dmitry Bufistov wrote:
> Hi Martin,
> I think everything is more or less correct here. Changing your graph
> representation to
> boost::adjacency_list<boost::setS, boost::vecS, boost::undirectedS>
> results in the behavior you expect.
>
> Regards,
> Dmitry
>
> Martin Mann wrote:
>>
>> Hi,
>>
>> I encountered the following problem :
>>
>> a successive call with equal parameters u, v, and g of
>>
>> ============================================================
>> std::pair<edge_descriptor, bool>
>> add_edge( vertex_descriptor u
>> , vertex_descriptor v
>> , adjacency_list& g )
>> ============================================================
>>
>> yields both times "RESULT.second == true".
>>
>> But the documentation states, that only in case it is NOT PRESENT it
>> should be true, which is obviously wrong for the second call.
>>
>
>> //! The definition of a the internal graph representation
>> typedef boost::adjacency_list< boost::vecS
>> , boost::vecS
>> , boost::undirectedS
>> , CoreGraph_NodeProperties
>> , CoreGraph_EdgeProperties
>> > CoreGraph;
>>
>> ============================================================
>
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net