|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r48999 - trunk/boost/graph
From: asutton_at_[hidden]
Date: 2008-09-29 08:27:04
Author: asutton
Date: 2008-09-29 08:27:03 EDT (Mon, 29 Sep 2008)
New Revision: 48999
URL: http://svn.boost.org/trac/boost/changeset/48999
Log:
Removed define and usage of MAXINT, replaced with numeric_limits max.
This was discussed on the boost list, but there's no ticket filed.
Text files modified:
trunk/boost/graph/sloan_ordering.hpp | 11 +++++------
1 files changed, 5 insertions(+), 6 deletions(-)
Modified: trunk/boost/graph/sloan_ordering.hpp
==============================================================================
--- trunk/boost/graph/sloan_ordering.hpp (original)
+++ trunk/boost/graph/sloan_ordering.hpp 2008-09-29 08:27:03 EDT (Mon, 29 Sep 2008)
@@ -14,19 +14,18 @@
#define WEIGHT1 1 //default weight for the distance in the Sloan algorithm
#define WEIGHT2 2 //default weight for the degree in the Sloan algorithm
-#define MAXINT 2147483647 //Maximum value for a 32bit integer
#include <boost/config.hpp>
#include <vector>
#include <queue>
+#include <algorithm>
+#include <limits>
#include <boost/pending/queue.hpp>
#include <boost/graph/graph_traits.hpp>
#include <boost/graph/breadth_first_search.hpp>
#include <boost/graph/properties.hpp>
#include <boost/pending/indirect_cmp.hpp>
#include <boost/property_map.hpp>
-#include <algorithm>
-#include <utility>
#include <boost/graph/visitors.hpp>
#include <boost/graph/adjacency_list.hpp>
#include <boost/graph/cuthill_mckee_ordering.hpp>
@@ -195,9 +194,9 @@
//end 3 & 4
- //step 5
- //Initializing w
- w_e = MAXINT;
+ // step 5
+ // Initializing w
+ w_e = std::numeric_limits<unsigned>::max();
//end 5
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk