Boost logo

Boost-Commit :

From: franklin.jonathan_at_[hidden]
Date: 2008-05-14 18:44:46


Author: jfranklin
Date: 2008-05-14 18:44:46 EDT (Wed, 14 May 2008)
New Revision: 45373
URL: http://svn.boost.org/trac/boost/changeset/45373

Log:
Removed a broken concept check for the return type of DistFunT, and replaced it w/ a TODO comment.
Fixed the typedef for cluster_data. A problem w/ it was revealed when I switched tuple types to std::pair.

Fixed a compile problem w/ concept.hpp. Turns out msvc wasn't really doing anything with it.

Text files modified:
   sandbox/cluster/boost/algorithm/cluster/concept.hpp | 4 ++--
   sandbox/cluster/boost/algorithm/cluster/dbscan.hpp | 6 +++---
   2 files changed, 5 insertions(+), 5 deletions(-)

Modified: sandbox/cluster/boost/algorithm/cluster/concept.hpp
==============================================================================
--- sandbox/cluster/boost/algorithm/cluster/concept.hpp (original)
+++ sandbox/cluster/boost/algorithm/cluster/concept.hpp 2008-05-14 18:44:46 EDT (Wed, 14 May 2008)
@@ -22,11 +22,11 @@
     void constraints()
     {
       // Operation
- d(t, t);
+ (*pD)(t, t);
     }
   private:
     T t;
- DistanceFunT d;
+ DistanceFunT * pD;
   };
 
   // TODO: Add concepts here, then delete this comment.

Modified: sandbox/cluster/boost/algorithm/cluster/dbscan.hpp
==============================================================================
--- sandbox/cluster/boost/algorithm/cluster/dbscan.hpp (original)
+++ sandbox/cluster/boost/algorithm/cluster/dbscan.hpp 2008-05-14 18:44:46 EDT (Wed, 14 May 2008)
@@ -59,8 +59,8 @@
   function_requires<
     DistanceComparableConcept<typename NTupleIterT::value_type, DistFunT> >();
     //DistanceComparableConcept<int, DistFunT> >();
- function_requires<
- DistanceComparableConcept<DistanceT, DistFunT> >();
+ // TODO: Need to devise a concept check for the return type of DistFunT,
+ // such that it is compatible with the difference_type for 2 NTuples.
 
   // TODO: Rework the algorithm to NOT make this extra collection?
   typedef detail::node<NTupleIterT> node;
@@ -75,7 +75,7 @@
     tuples.push_back(node(it));
   }
 
- typedef cluster_data<std::vector<NTupleIterT> > cluster_data;
+ typedef cluster_data<ClusterT> cluster_data;
   cluster_data p;
 
   // TODO: We should try to make cluster_num go away.


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