[cli-users] Cannot compile with g++ 6.3 (bug report + solution)

Dorier, Matthieu mdorier at anl.gov
Wed Jan 24 10:25:28 EST 2018


Hi,


I downloaded the cli 1.1.0 + dep archive but could not compile it on my Debian with g++ 6.3.

I got the following errors:


cli-1.1.0+dep/libcutl/cutl/compiler/traversal.hxx:76:13: error: ‘add’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
         add (typeid (type), *this);


This one can be solved by replacing the specified line with:


traverser_map<B>::add (typeid (type), *this);


And last error is the following:

cli-1.1.0+dep/cli/cli/traversal/elements.hxx:134:28: error: ‘iterate_and_dispatch’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
       iterate_and_dispatch (s.names_begin (), s.names_end (), d);

Which got solved by replacing the line with:

edge_dispatcher::iterate_and_dispatch (s.names_begin (), s.names_end (), d);

I also get a bunch of warning related to std::auto_ptr being deprecated. Those can be removed by using CXXFLAGS="-std=c++98".

Thanks,

Matthieu Dorier



More information about the cli-users mailing list