[Boost-bugs] [Boost C++ Libraries] #12873: boost.heap calls non-existing constructor of iterator_adaptor

Subject: [Boost-bugs] [Boost C++ Libraries] #12873: boost.heap calls non-existing constructor of iterator_adaptor
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2017-02-26 20:23:02


#12873: boost.heap calls non-existing constructor of iterator_adaptor
-------------------------------------------------+-------------------------
 Reporter: Bart van Merrienboer | Owner:
  <bart.vanmerrienboer@…> | timblechmann
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: heap
  Version: Boost 1.63.0 | Severity: Problem
 Keywords: |
-------------------------------------------------+-------------------------
 boost.heap tries to call the constructor `boost::iterator_adaptor(0)`,
 which doesn't exist, in several places. For example in
 `boost/heap/detail/mutable_heap.hpp` (lines 225-243):

 {{{
         typedef boost::iterator_adaptor<ordered_iterator,
                                         const_list_iterator,
                                         value_type const,
                                         boost::forward_traversal_tag
> adaptor_type;

         typedef const_list_iterator iterator;
         typedef typename q_type::ordered_iterator_dispatcher
 ordered_iterator_dispatcher;

         friend class boost::iterator_core_access;

     public:
         ordered_iterator(void):
             adaptor_type(0), unvisited_nodes(indirect_cmp()), q_(NULL)
         {}

         ordered_iterator(const priority_queue_mutable_wrapper * q,
 indirect_cmp const & cmp):
             adaptor_type(0), unvisited_nodes(cmp), q_(q)
         {}
 }}}

 This will result in "no matching constructor" compilation errors when
 trying to construct e.g. an `ordered_iterator` for a `d_ary_heap` (see
 attached program).

 The same non-existing call is made on `detail/mutable_heap.hpp:193`,
 `detail/stable_heap.hpp:534`, and
 `detail/tree_iterator.hpp:214,218,231,340`

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/12873>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-26 20:26:30 UTC