Boost logo

Boost :

Subject: [boost] property_tree equal_range causes compiler error
From: 周宇前 (zhou_at_[hidden])
Date: 2009-11-27 13:06:53


add to boost/libs/property_tree/examples/debug_settings.cpp: line 55
    pt.equal_range("debug.level");
then compile:

~/boost/libs/property_tree/examples$ g++ -I../../../
debug_settings.cpp -o debug_settings
../../../boost/property_tree/detail/ptree_implementation.hpp: In
member function ‘std::pair<typename
boost::property_tree::basic_ptree<Key, Data,
KeyCompare>::assoc_iterator, typename
boost::property_tree::basic_ptree<Key, Data,
KeyCompare>::assoc_iterator> boost::property_tree::basic_ptree<Key,
Data, KeyCompare>::equal_range(const Key&) [with Key =
std::basic_string<char, std::char_traits<char>, std::allocator<char>
>, Data = std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, KeyCompare = std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >]’:
debug_settings.cpp:55: instantiated from here
../../../boost/property_tree/detail/ptree_implementation.hpp:449:
error: ‘class boost::multi_index::detail::bidir_node_iterator<boost::multi_index::detail::ordered_index_node<boost::multi_index::detail::index_node_base<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char>
>, boost::property_tree::basic_ptree<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::basic_string<char, std::char_traits<char>, std::allocator<char>
>, std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char>
>, boost::property_tree::basic_ptree<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::basic_string<char, std::char_traits<char>, std::allocator<char>
>, std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > > >’ has no member named ‘base’
../../../boost/property_tree/detail/ptree_implementation.hpp:449:
error: ‘class boost::multi_index::detail::bidir_node_iterator<boost::multi_index::detail::ordered_index_node<boost::multi_index::detail::index_node_base<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char>
>, boost::property_tree::basic_ptree<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::basic_string<char, std::char_traits<char>, std::allocator<char>
>, std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char>
>, boost::property_tree::basic_ptree<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::basic_string<char, std::char_traits<char>, std::allocator<char>
>, std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > > >’ has no member named ‘base’


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