Opened 14 years ago

Closed 14 years ago

#2132 closed Bugs (fixed)

const-correctness bug in sparse_ordering.hpp

Reported by: Dave Abrahams Owned by: Jeremiah Willcock
Milestone: Boost 1.36.0 Component: graph
Version: Boost 1.35.0 Severity: Problem
Keywords: Cc:

Description

Did this code even get tested? Or am I on crack to think that it's wrong?

This patch fixes it for my particular test case.

  • sparse_ordering.hpp

     
    128128  //
    129129  template <class Graph, class Vertex, class ColorMap, class DegreeMap>
    130130  Vertex
    131   pseudo_peripheral_pair(Graph& G, const Vertex& u, int& ecc,
     131  pseudo_peripheral_pair(Graph const& G, const Vertex& u, int& ecc,
    132132                         ColorMap color, DegreeMap degree)
    133133  {
    134134    typedef typename property_traits<ColorMap>::value_type ColorValue;
     
    152152  // of the ordering generated by RCM.
    153153  //
    154154  template <class Graph, class Vertex, class Color, class Degree>
    155   Vertex find_starting_node(Graph& G, Vertex r, Color color, Degree degree)
     155  Vertex find_starting_node(Graph const& G, Vertex r, Color color, Degree degree)
    156156  {
    157157    Vertex x, y;
    158158    int eccen_r, eccen_x;

Change History (3)

comment:1 by Douglas Gregor, 14 years ago

Owner: changed from doug_gregor to Douglas Gregor

comment:2 by Jeremiah Willcock, 14 years ago

Owner: changed from Douglas Gregor to Jeremiah Willcock
Status: newassigned

comment:3 by Jeremiah Willcock, 14 years ago

Resolution: fixed
Status: assignedclosed

(In [50823]) Applied patch from #2132, closes #2132

Note: See TracTickets for help on using tickets.