COIN-OR::LEMON - Graph Library

Changeset 1643:9285f3777553 in lemon-0.x for lemon


Ignore:
Timestamp:
08/18/05 15:33:49 (15 years ago)
Author:
Alpar Juttner
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2156
Message:
  • The number of gcc-4.0 warnings has significantly decreases.
  • Some code clean-up in gui
Location:
lemon
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • lemon/concept/graph.h

    r1631 r1643  
    405405        /// This constructor sets the iterator to the first edge of \c g.
    406406        ///@param g the graph
    407         EdgeIt(const StaticGraph& g) { }
     407        EdgeIt(const StaticGraph& g) { ignore_unused_variable_warning(g); }
    408408        /// Edge -> EdgeIt conversion
    409409
  • lemon/concept/path.h

    r1624 r1643  
    2525
    2626#include <lemon/invalid.h>
     27#include <lemon/concept_check.h>
    2728
    2829namespace lemon {
     
    5556      /// \param _g The graph in which the path is.
    5657      ///
    57       Path(const Graph &_g) {}
     58      Path(const Graph &_g) {
     59        ignore_unused_variable_warning(_g);
     60      }
    5861
    5962      /// Length of the path.
  • lemon/concept/undir_graph.h

    r1631 r1643  
    558558        /// This constructor sets the iterator to the first edge of \c g.
    559559        ///@param g the graph
    560         EdgeIt(const UndirGraph &g) { }
     560        EdgeIt(const UndirGraph &g) { ignore_unused_variable_warning(g); }
    561561        /// Edge -> EdgeIt conversion
    562562
     
    606606        ///@param n the node
    607607        ///@param g the graph
    608         OutEdgeIt(const UndirGraph& n, const Node& g) { }
     608        OutEdgeIt(const UndirGraph& n, const Node& g) {
     609          ignore_unused_variable_warning(n);
     610          ignore_unused_variable_warning(g);
     611        }
    609612        /// Edge -> OutEdgeIt conversion
    610613
     
    655658        ///@param n the node
    656659        ///@param g the graph
    657         InEdgeIt(const UndirGraph& g, const Node& n) { }
     660        InEdgeIt(const UndirGraph& g, const Node& n) {
     661          ignore_unused_variable_warning(n);
     662          ignore_unused_variable_warning(g);
     663        }
    658664        /// Edge -> InEdgeIt conversion
    659665
  • lemon/full_graph.h

    r1566 r1643  
    126126    protected:
    127127      int id;
    128       Node(int _id) { id = _id;}
     128      Node(int _id) : id(_id) {}
    129129    public:
    130130      Node() {}
    131       Node (Invalid) { id = -1; }
     131      Node (Invalid) : id(-1) {}
    132132      bool operator==(const Node node) const {return id == node.id;}
    133133      bool operator!=(const Node node) const {return id != node.id;}
     
    261261    Node source(Edge e) const {
    262262      /// \todo we may do it faster
    263       return ((int)sqrt((double)(1 + 8 * e.id)) + 1) / 2;
     263      return Node(((int)sqrt((double)(1 + 8 * e.id)) + 1) / 2);
    264264    }
    265265
    266266    Node target(Edge e) const {
    267267      int source = ((int)sqrt((double)(1 + 8 * e.id)) + 1) / 2;;
    268       return e.id - (source) * (source - 1) / 2;
     268      return Node(e.id - (source) * (source - 1) / 2);
    269269    }
    270270
Note: See TracChangeset for help on using the changeset viewer.