This one (another unused variable warning, that seemingly doesn't understand the [[maybe_unused]] tag) is epic:
Code: Select all
In file included from /home/lucas/Projects/FreeOrion/freeorion/universe/../util/../universe/Universe.h:16:0,
from /home/lucas/Projects/FreeOrion/freeorion/universe/../util/AppInterface.h:5,
from /home/lucas/Projects/FreeOrion/freeorion/universe/Fleet.h:5,
from /home/lucas/Projects/FreeOrion/freeorion/universe/Pathfinder.cpp:14:
/home/lucas/Projects/FreeOrion/freeorion/universe/../util/../universe/ObjectMap.h: In instantiation of ‘std::vector<std::shared_ptr<const _Tp> > ObjectMap::find(const UniverseObjectVisitor&) const [with T = UniverseObject]’:
/home/lucas/Projects/FreeOrion/freeorion/universe/Pathfinder.cpp:650:51: required from ‘bool {anonymous}::GraphImpl::SystemPredicateFilter::operator()(const EdgeDescriptor&) const [with EdgeDescriptor = boost::detail::edge_desc_impl<boost::undirected_tag, long unsigned int>]’
/usr/local/include/boost/graph/filtered_graph.hpp:76:31: required from ‘bool boost::detail::out_edge_predicate<EdgePredicate, VertexPredicate, Graph>::operator()(const Edge&) const [with Edge = boost::detail::edge_desc_impl<boost::undirected_tag, long unsigned int>; EdgePredicate = {anonymous}::GraphImpl::SystemPredicateFilter; VertexPredicate = boost::keep_all; Graph = boost::filtered_graph<boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >, {anonymous}::GraphImpl::SystemPredicateFilter>]’
/usr/local/include/boost/iterator/filter_iterator.hpp:101:49: required from ‘void boost::iterators::filter_iterator<Predicate, Iterator>::satisfy_predicate() [with Predicate = boost::detail::out_edge_predicate<{anonymous}::GraphImpl::SystemPredicateFilter, boost::keep_all, boost::filtered_graph<boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >, {anonymous}::GraphImpl::SystemPredicateFilter> >; Iterator = boost::detail::out_edge_iter<__gnu_cxx::__normal_iterator<boost::detail::stored_edge_iter<long unsigned int, std::_List_iterator<boost::list_edge<long unsigned int, boost::property<boost::edge_weight_t, double> > >, boost::property<boost::edge_weight_t, double> >*, std::vector<boost::detail::stored_edge_iter<long unsigned int, std::_List_iterator<boost::list_edge<long unsigned int, boost::property<boost::edge_weight_t, double> > >, boost::property<boost::edge_weight_t, double> >, std::allocator<boost::detail::stored_edge_iter<long unsigned int, std::_List_iterator<boost::list_edge<long unsigned int, boost::property<boost::edge_weight_t, double> > >, boost::property<boost::edge_weight_t, double> > > > >, long unsigned int, boost::detail::edge_desc_impl<boost::undirected_tag, long unsigned int>, long int>]’
/usr/local/include/boost/iterator/filter_iterator.hpp:60:28: required from ‘boost::iterators::filter_iterator<Predicate, Iterator>::filter_iterator(Predicate, Iterator, Iterator) [with Predicate = boost::detail::out_edge_predicate<{anonymous}::GraphImpl::SystemPredicateFilter, boost::keep_all, boost::filtered_graph<boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >, {anonymous}::GraphImpl::SystemPredicateFilter> >; Iterator = boost::detail::out_edge_iter<__gnu_cxx::__normal_iterator<boost::detail::stored_edge_iter<long unsigned int, std::_List_iterator<boost::list_edge<long unsigned int, boost::property<boost::edge_weight_t, double> > >, boost::property<boost::edge_weight_t, double> >*, std::vector<boost::detail::stored_edge_iter<long unsigned int, std::_List_iterator<boost::list_edge<long unsigned int, boost::property<boost::edge_weight_t, double> > >, boost::property<boost::edge_weight_t, double> >, std::allocator<boost::detail::stored_edge_iter<long unsigned int, std::_List_iterator<boost::list_edge<long unsigned int, boost::property<boost::edge_weight_t, double> > >, boost::property<boost::edge_weight_t, double> > > > >, long unsigned int, boost::detail::edge_desc_impl<boost::undirected_tag, long unsigned int>, long int>]’
/usr/local/include/boost/graph/filtered_graph.hpp:357:27: required from ‘std::pair<typename boost::filtered_graph<Graph, EdgePredicate, VertexPredicate>::out_edge_iterator, typename boost::filtered_graph<Graph, EdgePredicate, VertexPredicate>::out_edge_iterator> boost::out_edges(typename boost::filtered_graph<Graph, EdgePredicate, VertexPredicate>::vertex_descriptor, const boost::filtered_graph<Graph, EdgePredicate, VertexPredicate>&) [with G = boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >; EP = {anonymous}::GraphImpl::SystemPredicateFilter; VP = boost::keep_all; typename boost::filtered_graph<Graph, EdgePredicate, VertexPredicate>::out_edge_iterator = boost::iterators::filter_iterator<boost::detail::out_edge_predicate<{anonymous}::GraphImpl::SystemPredicateFilter, boost::keep_all, boost::filtered_graph<boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >, {anonymous}::GraphImpl::SystemPredicateFilter> >, boost::detail::out_edge_iter<__gnu_cxx::__normal_iterator<boost::detail::stored_edge_iter<long unsigned int, std::_List_iterator<boost::list_edge<long unsigned int, boost::property<boost::edge_weight_t, double> > >, boost::property<boost::edge_weight_t, double> >*, std::vector<boost::detail::stored_edge_iter<long unsigned int, std::_List_iterator<boost::list_edge<long unsigned int, boost::property<boost::edge_weight_t, double> > >, boost::property<boost::edge_weight_t, double> >, std::allocator<boost::detail::stored_edge_iter<long unsigned int, std::_List_iterator<boost::list_edge<long unsigned int, boost::property<boost::edge_weight_t, double> > >, boost::property<boost::edge_weight_t, double> > > > >, long unsigned int, boost::detail::edge_desc_impl<boost::undirected_tag, long unsigned int>, long int> >; typename boost::filtered_graph<Graph, EdgePredicate, VertexPredicate>::vertex_descriptor = long unsigned int]’
/usr/local/include/boost/graph/breadth_first_search.hpp:80:46: [ skipping 2 instantiation contexts, use -ftemplate-backtrace-limit=0 to disable ]
/usr/local/include/boost/graph/dijkstra_shortest_paths.hpp:476:36: required from ‘void boost::dijkstra_shortest_paths(const VertexListGraph&, SourceInputIter, SourceInputIter, PredecessorMap, DistanceMap, WeightMap, IndexMap, Compare, Combine, DistInf, DistZero, DijkstraVisitor, ColorMap) [with VertexListGraph = boost::filtered_graph<boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >, {anonymous}::GraphImpl::SystemPredicateFilter>; SourceInputIter = long unsigned int*; DijkstraVisitor = boost::dijkstra_visitor<SystemPathing::PathFindingShortCircuitingVisitor>; PredecessorMap = int*; DistanceMap = double*; WeightMap = boost::adj_list_edge_property_map<boost::undirected_tag, double, const double&, long unsigned int, const boost::property<boost::edge_weight_t, double>, boost::edge_weight_t>; IndexMap = boost::vec_adj_list_vertex_id_map<boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, long unsigned int>; Compare = std::less<double>; Combine = std::plus<double>; DistInf = int; DistZero = int; ColorMap = boost::two_bit_color_map<boost::vec_adj_list_vertex_id_map<boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, long unsigned int> >]’
/usr/local/include/boost/graph/dijkstra_shortest_paths.hpp:423:28: required from ‘void boost::dijkstra_shortest_paths(const VertexListGraph&, SourceInputIter, SourceInputIter, PredecessorMap, DistanceMap, WeightMap, IndexMap, Compare, Combine, DistInf, DistZero, DijkstraVisitor, const boost::bgl_named_params<T, Tag, Base>&, typename boost::enable_if_c<boost::is_base_and_derived<boost::vertex_list_graph_tag, typename boost::graph_traits<Graph>::traversal_category>::value, boost::graph::detail::no_parameter>::type) [with VertexListGraph = boost::filtered_graph<boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >, {anonymous}::GraphImpl::SystemPredicateFilter>; SourceInputIter = long unsigned int*; DijkstraVisitor = boost::dijkstra_visitor<SystemPathing::PathFindingShortCircuitingVisitor>; PredecessorMap = int*; DistanceMap = double*; WeightMap = boost::adj_list_edge_property_map<boost::undirected_tag, double, const double&, long unsigned int, const boost::property<boost::edge_weight_t, double>, boost::edge_weight_t>; IndexMap = boost::vec_adj_list_vertex_id_map<boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, long unsigned int>; Compare = std::less<double>; Combine = std::plus<double>; DistInf = int; DistZero = int; T = char; Tag = boost::detail::unused_tag_type; Base = boost::no_property; typename boost::enable_if_c<boost::is_base_and_derived<boost::vertex_list_graph_tag, typename boost::graph_traits<Graph>::traversal_category>::value, boost::graph::detail::no_parameter>::type = boost::graph::detail::no_parameter]’
/usr/local/include/boost/graph/dijkstra_shortest_paths.hpp:515:28: required from ‘void boost::dijkstra_shortest_paths(const VertexListGraph&, SourceInputIter, SourceInputIter, PredecessorMap, DistanceMap, WeightMap, IndexMap, Compare, Combine, DistInf, DistZero, DijkstraVisitor) [with VertexListGraph = boost::filtered_graph<boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >, {anonymous}::GraphImpl::SystemPredicateFilter>; SourceInputIter = long unsigned int*; DijkstraVisitor = boost::dijkstra_visitor<SystemPathing::PathFindingShortCircuitingVisitor>; PredecessorMap = int*; DistanceMap = double*; WeightMap = boost::adj_list_edge_property_map<boost::undirected_tag, double, const double&, long unsigned int, const boost::property<boost::edge_weight_t, double>, boost::edge_weight_t>; IndexMap = boost::vec_adj_list_vertex_id_map<boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, long unsigned int>; Compare = std::less<double>; Combine = std::plus<double>; DistInf = int; DistZero = int]’
/usr/local/include/boost/graph/dijkstra_shortest_paths.hpp:535:28: required from ‘void boost::dijkstra_shortest_paths(const VertexListGraph&, typename boost::graph_traits<Graph>::vertex_descriptor, PredecessorMap, DistanceMap, WeightMap, IndexMap, Compare, Combine, DistInf, DistZero, DijkstraVisitor) [with VertexListGraph = boost::filtered_graph<boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >, {anonymous}::GraphImpl::SystemPredicateFilter>; DijkstraVisitor = boost::dijkstra_visitor<SystemPathing::PathFindingShortCircuitingVisitor>; PredecessorMap = int*; DistanceMap = double*; WeightMap = boost::adj_list_edge_property_map<boost::undirected_tag, double, const double&, long unsigned int, const boost::property<boost::edge_weight_t, double>, boost::edge_weight_t>; IndexMap = boost::vec_adj_list_vertex_id_map<boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, long unsigned int>; Compare = std::less<double>; Combine = std::plus<double>; DistInf = int; DistZero = int; typename boost::graph_traits<Graph>::vertex_descriptor = long unsigned int]’
/home/lucas/Projects/FreeOrion/freeorion/universe/Pathfinder.cpp:358:43: required from ‘std::pair<std::__cxx11::list<int>, double> SystemPathing::ShortestPathImpl(const Graph&, int, int, double, const boost::unordered::unordered_map<int, long unsigned int>&) [with Graph = boost::filtered_graph<boost::adjacency_list<boost::vecS, boost::vecS, boost::undirectedS, boost::property<SystemPathing::vertex_system_id_t, int, boost::property<boost::vertex_index_t, int> >, boost::property<boost::edge_weight_t, double> >, {anonymous}::GraphImpl::SystemPredicateFilter>]’
/home/lucas/Projects/FreeOrion/freeorion/universe/Pathfinder.cpp:1081:76: required from here
/home/lucas/Projects/FreeOrion/freeorion/universe/../util/../universe/ObjectMap.h:290:49: warning: unused variable ‘ignored_id’ [-Wunused-variable]
for ([[maybe_unused]] auto& [ignored_id, obj] : Map<mutableT>()) {
I struggle with C++ syntax (it's quite different from the little C++ I learnt during my degree 20 years ago), but this Boost library and the whole OO stuff was born in hell.