Boost logo

Boost :

Subject: [boost] [graph] Compilation error with adjacency_list and C++11
From: Sebastien Loriot (GeometryFactory) (sloriot.ml_at_[hidden])
Date: 2016-05-09 06:28:31


Hello,

the program below does not compile at least with g++ 5.3.1
and clang++ 3.5.2-1 when using c++11 standard.

If I comment line #1 it compiles. If I change #2 to undirectedS it compiles.

Is there anything wrong in my code or is it a problem in boost's?

Thanks,

Sebastien.

#include <boost/graph/adjacency_list.hpp>

struct A
{
   A(){}
   A(const A& ){} // #1
   A& operator=(const A&){return *this;}
};

typedef boost::adjacency_list<boost::listS,
                               boost::vecS,
                               boost::directedS, //#2
                               A
> Graph;

int main()
{
   Graph g;
   boost::add_vertex(g);
   return 0;
}


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