Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r50000 - in sandbox/itl: boost/itl libs/itl/test libs/itl_xt/test/meta_functors
From: afojgo_at_[hidden]
Date: 2008-11-28 17:53:47


Author: jofaber
Date: 2008-11-28 17:53:46 EST (Fri, 28 Nov 2008)
New Revision: 50000
URL: http://svn.boost.org/trac/boost/changeset/50000

Log:
Refactored: Adding Aggregate template parameter Combine for maps. Stable {msvc-9.0}
Text files modified:
   sandbox/itl/boost/itl/interval_base_map.hpp | 117 +++++++++++++++--------------
   sandbox/itl/boost/itl/interval_map.hpp | 107 +++++++++++++-------------
   sandbox/itl/boost/itl/interval_maps.hpp | 160 ++++++++++++++++++++--------------------
   sandbox/itl/boost/itl/map.hpp | 88 +++++++++++----------
   sandbox/itl/boost/itl/split_interval_map.hpp | 73 +++++++++---------
   sandbox/itl/libs/itl/test/test_interval_map_shared.hpp | 11 ++
   sandbox/itl/libs/itl_xt/test/meta_functors/meta_functors.cpp | 29 +++++++
   7 files changed, 316 insertions(+), 269 deletions(-)

Modified: sandbox/itl/boost/itl/interval_base_map.hpp
==============================================================================
--- sandbox/itl/boost/itl/interval_base_map.hpp (original)
+++ sandbox/itl/boost/itl/interval_base_map.hpp 2008-11-28 17:53:46 EST (Fri, 28 Nov 2008)
@@ -137,6 +137,7 @@
     class Traits = itl::neutron_absorber,
     template<class, template<class>class>class Interval = itl::interval,
     template<class>class Compare = std::less,
+ template<class>class Combine = itl::inplace_plus,
     template<class>class Alloc = std::allocator
>
 #ifdef USE_CONCEPTS
@@ -158,11 +159,11 @@
     typedef SubType sub_type;
 
     typedef interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>
+ Traits,Interval,Compare,Combine,Alloc>
                               type;
 
     typedef interval_base_map<SubType,DomainT,CodomainT,
- itl::neutron_absorber,Interval,Compare,Alloc>
+ itl::neutron_absorber,Interval,Compare,Combine,Alloc>
                               neutron_absorber_type;
 
     /// Domain type (type of the keys) of the map
@@ -184,6 +185,8 @@
 
     /// Comparison functor for domain values
     typedef Compare<DomainT> domain_compare;
+ /// Combine functor for codomain values
+ typedef Combine<DomainT> codomain_combine;
     /// Comparison functor for intervals which are keys as well
     typedef exclusive_less<interval_type> interval_compare;
 
@@ -196,7 +199,7 @@
 
     /// Container type for the implementation
     typedef itl::map<interval_type,codomain_type,Traits,
- exclusive_less,Alloc> ImplMapT;
+ exclusive_less,Combine,Alloc> ImplMapT;
 
     /// key type of the implementing container
     typedef typename ImplMapT::key_type key_type;
@@ -220,7 +223,7 @@
 
     /// The atomized type is elementbased map that is equivalent to the interval map
     typedef typename itl::map<DomainT,CodomainT,
- Traits,Compare,Alloc> atomized_type;
+ Traits,Compare,Combine,Alloc> atomized_type;
 //@}
 
 private:
@@ -723,14 +726,14 @@
         <
             class DomT, class CodomT,
             class Trts, template<class DomT,template<class>class Comp>class Interv,
- template<class>class Comp, template<class>class Allc
+ template<class>class Comp, template<class>class Combi, template<class>class Allc
>
         class IntervalMap
>
     void add_intersection
     (
         interval_base_map& intersection,
- const IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc>& sectant
+ const IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& sectant
     )const;
 
 //@}
@@ -925,12 +928,12 @@
 <
     class SubType, class DomainT, class CodomainT, class Traits,
     template<class, template<class>class>class Interval, template<class>class Compare,
- template<class>class Alloc
+ template<class>class Combine, template<class>class Alloc
>
 typename interval_base_map<SubType,DomainT,CodomainT,Traits,
- Interval,Compare,Alloc>::size_type
+ Interval,Compare,Combine,Alloc>::size_type
 interval_base_map<SubType,DomainT,CodomainT,Traits,
- Interval,Compare,Alloc>::cardinality()const
+ Interval,Compare,Combine,Alloc>::cardinality()const
 {
     using namespace boost::mpl;
     return if_<
@@ -945,12 +948,12 @@
 <
     class SubType, class DomainT, class CodomainT, class Traits,
     template<class, template<class>class>class Interval, template<class>class Compare,
- template<class>class Alloc
+ template<class>class Combine, template<class>class Alloc
>
 typename interval_base_map<SubType,DomainT,CodomainT,Traits,
- Interval,Compare,Alloc>::difference_type
+ Interval,Compare,Combine,Alloc>::difference_type
 interval_base_map<SubType,DomainT,CodomainT,Traits,
- Interval,Compare,Alloc>::length()const
+ Interval,Compare,Combine,Alloc>::length()const
 {
     difference_type length = neutron<difference_type>::value();
     const_FOR_IMPLMAP(it)
@@ -964,9 +967,9 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-bool interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>::contained_in(const interval_base_map& super)const
+bool interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::contained_in(const interval_base_map& super)const
 {
     // x2 should be larger than *this; so every element in this should be in x2
     const_FOR_IMPLMAP(it)
@@ -981,7 +984,7 @@
     class SubType,
     class DomainT, class CodomainT,
     class Traits, template<class, template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
     template
     <
@@ -989,19 +992,19 @@
         <
             class DomT, class CodomT,
             class Trts, template<class DomT,template<class>class Comp>class Interv,
- template<class>class Comp, template<class>class Allc
+ template<class>class Comp, template<class>class Combi, template<class>class Allc
>
         class IntervalMap
>
-void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::add_intersection
 (
     interval_base_map& intersection,
- const IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc>& sectant
+ const IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& sectant
 )const
 {
     typedef IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> sectant_type;
+ Traits,Interval,Compare,Combine,Alloc> sectant_type;
     if(sectant.empty())
         return;
     typename sectant_type::const_iterator common_lwb;
@@ -1016,11 +1019,11 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::add_intersection(interval_base_map& section,
- const typename interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ const typename interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
                     ::value_type& sectant)const
 {
     interval_type sectant_interval = sectant.KEY_VALUE;
@@ -1051,11 +1054,11 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::add_intersection(interval_base_map& section,
- const typename interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ const typename interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
                     ::interval_type& sectant_interval)const
 {
     if(sectant_interval.empty()) return;
@@ -1078,9 +1081,9 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::join()
 {
     iterator it=_map.begin();
@@ -1127,9 +1130,9 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-std::string interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>::as_string()const
+std::string interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::as_string()const
 {
     std::string res("");
     const_FOR_IMPLMAP(it) {
@@ -1147,9 +1150,9 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-CodomainT interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>::sum()const
+CodomainT interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::sum()const
 {
     CodomainT sum = CodomainT();
     const_FOR_IMPLMAP(it)
@@ -1161,9 +1164,9 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>::uniformBounds( typename interval<DomainT>::bound_types bt)
+void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::uniformBounds( typename interval<DomainT>::bound_types bt)
 {
     // I can do this only, because I am shure that the contents and the
     // ordering < on interval is invariant wrt. this transformation on bounds
@@ -1173,9 +1176,9 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>::closeLeftBounds()
+void interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::closeLeftBounds()
 {
     // I can do this only, because I am shure that the contents and the
     // ordering < on interval is invariant wrt. this transformation on bounds
@@ -1187,9 +1190,9 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-SubType& interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+SubType& interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::erase(const interval_type& x_itv)
 {
     if(x_itv.empty()) return *that();
@@ -1225,10 +1228,10 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
 SubType&
-interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::erase(const interval_base_map& erasure)
 {
     const_FORALL(typename interval_base_map, value_pair_, erasure)
@@ -1249,10 +1252,10 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-inline bool operator == (const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& lhs,
- const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& rhs)
+inline bool operator == (const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& lhs,
+ const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& rhs)
 {
     //MEMO PORT: This implemetation worked with stlport, sgi and gnu
     // implementations of the stl. But using MSVC-implementation
@@ -1265,13 +1268,13 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-inline bool is_protonic_equal(const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& lhs,
- const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& rhs)
+inline bool is_protonic_equal(const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& lhs,
+ const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& rhs)
 {
- interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc> lhs0 = lhs;
- interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc> rhs0 = rhs;
+ interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc> lhs0 = lhs;
+ interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc> rhs0 = rhs;
 
     lhs0.absorb_neutrons();
     rhs0.absorb_neutrons();
@@ -1286,10 +1289,10 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-inline bool operator < (const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& lhs,
- const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& rhs)
+inline bool operator < (const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& lhs,
+ const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& rhs)
 {
     return std::lexicographical_compare(
         lhs.begin(), lhs.end(), rhs.begin(), rhs.end(),
@@ -1300,10 +1303,10 @@
 template
 <
     class SubType,
- class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc
+ class DomainT, class CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-inline bool operator <= (const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& lhs,
- const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& rhs)
+inline bool operator <= (const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& lhs,
+ const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& rhs)
 {
     return lhs < rhs || lhs == rhs;
 }
@@ -1316,7 +1319,7 @@
     class SubType,
     class DomainT, class CodomainT,
     class Traits, template<class, template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
 interval_base_map<SubType,DomainT,CodomainT,
                   Traits,Interval,Compare,Alloc>&
@@ -1341,7 +1344,7 @@
     class SubType,
     class DomainT, class CodomainT,
     class Traits, template<class, template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
 interval_base_map<SubType,DomainT,CodomainT,
                   Traits,Interval,Compare,Alloc>&
@@ -1366,11 +1369,11 @@
 template<class CharType, class CharTraits,
     class SubType, class DomainT, class CodomainT, class Traits,
     template<class, template<class>class>class Interval, template<class>class Compare,
- template<class>class Alloc>
+ template<class>class Combine, template<class>class Alloc>
 std::basic_ostream<CharType, CharTraits>& operator <<
   (std::basic_ostream<CharType, CharTraits>& stream,
    const interval_base_map<SubType,DomainT,CodomainT,Traits,
- Interval,Compare,Alloc>& object)
+ Interval,Compare,Combine,Alloc>& object)
 {
     typedef interval_base_map<SubType,DomainT,CodomainT,Traits,
                               Interval,Compare,Alloc> IntervalMapT;

Modified: sandbox/itl/boost/itl/interval_map.hpp
==============================================================================
--- sandbox/itl/boost/itl/interval_map.hpp (original)
+++ sandbox/itl/boost/itl/interval_map.hpp 2008-11-28 17:53:46 EST (Fri, 28 Nov 2008)
@@ -109,20 +109,21 @@
     class Traits = itl::neutron_absorber,
     template<class, template<class>class>class Interval = itl::interval,
     template<class>class Compare = std::less,
+ template<class>class Combine = itl::inplace_plus,
     template<class>class Alloc = std::allocator
>
 class interval_map:
- public interval_base_map<interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>,
- DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ public interval_base_map<interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>,
+ DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
 {
 public:
     typedef Traits traits;
- typedef interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc> type;
+ typedef interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc> type;
     typedef type joint_type;
- typedef interval_base_map <interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>,
- DomainT,CodomainT,Traits,Interval,Compare,Alloc> base_type;
+ typedef interval_base_map <interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>,
+ DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc> base_type;
 
- typedef interval_map<DomainT,CodomainT,itl::neutron_absorber,Interval,Compare,Alloc>
+ typedef interval_map<DomainT,CodomainT,itl::neutron_absorber,Interval,Compare,Combine,Alloc>
             neutron_absorber_type;
 
     typedef Interval<DomainT,Compare> interval_type;
@@ -145,7 +146,7 @@
     template<class SubType>
     explicit interval_map
         (const interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& src)
+ Traits,Interval,Compare,Combine,Alloc>& src)
     { assign(src); }
 
     explicit interval_map(base_pair_type& base_pair): base_type()
@@ -158,16 +159,16 @@
     template<class SubType>
     interval_map& operator =
         (const interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& src)
+ Traits,Interval,Compare,Combine,Alloc>& src)
     { assign(src); return *this; }
 
     /// Assignment from a base interval_map.
     template<class SubType>
     void assign(const interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& src)
+ Traits,Interval,Compare,Combine,Alloc>& src)
     {
         typedef interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> base_map_type;
+ Traits,Interval,Compare,Combine,Alloc> base_map_type;
         this->clear();
         // Can be implemented via _map.insert: Interval joining not necessary.
         const_FORALL(typename base_map_type, it, src)
@@ -239,8 +240,8 @@
 } ;
 
 
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-bool interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+bool interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::contains_(const value_type& interv_value)const
 {
     interval_type interv = interv_value.KEY_VALUE;
@@ -254,8 +255,8 @@
 
 
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-bool interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+bool interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::joinable(const iterator& some, const iterator& next)const
 {
     // assert: next != end && some++ == next
@@ -264,9 +265,9 @@
 }
 
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>::iterator
- interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::iterator
+ interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::joint_insert(iterator& left_it, const iterator& right_it)
 {
     // both left and right are in the set and they are neighbours
@@ -294,8 +295,8 @@
 
 
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-bool interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+bool interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::join_left(iterator& it)
 {
     if(it == this->_map.begin())
@@ -316,8 +317,8 @@
 }
 
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-bool interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+bool interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::join_right(iterator& it)
 {
     if(it == this->_map.end())
@@ -338,9 +339,9 @@
 
 
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>::iterator
-interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::iterator
+interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::fill_join_left(const value_type& value)
 {
     //collision free insert is asserted
@@ -357,9 +358,9 @@
 }
 
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>::iterator
-interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::iterator
+interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::fill_join_both(const value_type& value)
 {
     //collision free insert is asserted
@@ -377,10 +378,10 @@
 
 //-----------------------------------------------------------------------------
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>::iterator
-interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::iterator
+interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::fill_gap_join_left(const value_type& value, const Combiner& combine)
 {
     //collision free insert is asserted
@@ -405,10 +406,10 @@
 }
 
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>::iterator
-interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+typename interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::iterator
+interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::fill_gap_join_both(const value_type& value, const Combiner& combine)
 {
     //collision free insert is asserted
@@ -436,9 +437,9 @@
 //-----------------------------------------------------------------------------
 // add<Combinator>(pair(interval,value)):
 //-----------------------------------------------------------------------------
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::add_(const value_type& x, const Combiner& combine)
 {
     const interval_type& x_itv = x.KEY_VALUE;
@@ -535,9 +536,9 @@
     }
 }
 
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::add_rest(const interval_type& x_itv, const CodomainT& x_val, iterator& it, iterator& end_it, const Combiner& combine)
 {
     iterator nxt_it = it; nxt_it++;
@@ -568,9 +569,9 @@
     add_rear(x_rest, x_val, it, combine);
 }
 
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::add_rear(const interval_type& x_rest, const CodomainT& x_val, iterator& it, const Combiner& combine)
 {
     interval_type cur_itv = (*it).KEY_VALUE ;
@@ -610,9 +611,9 @@
 //-----------------------------------------------------------------------------
 // subtract<Combinator>(pair(interval,value)):
 //-----------------------------------------------------------------------------
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::subtract_(const value_type& x, const Combiner& combine)
 {
     const interval_type& x_itv = x.KEY_VALUE;
@@ -679,9 +680,9 @@
 
 
 
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::subtract_rest(const interval_type& x_itv, const CodomainT& x_val, iterator& it, iterator& end_it, const Combiner& combine)
 {
     iterator nxt_it=it; nxt_it++;
@@ -751,8 +752,8 @@
 // insert(pair(interval,value)):
 //-----------------------------------------------------------------------------
 template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::insert_(const value_type& x)
 {
     const interval_type& x_itv = x.KEY_VALUE;
@@ -816,8 +817,8 @@
 
 
 template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::insert_rest(const interval_type& x_itv, const CodomainT& x_val,
                   iterator& it, iterator& end_it)
 {
@@ -844,8 +845,8 @@
 }
 
 template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::insert_rear(const interval_type& x_rest, const CodomainT& x_val,
                   iterator& it)
 {
@@ -874,8 +875,8 @@
 //-----------------------------------------------------------------------------
 // erase(pair(interval,value)):
 //-----------------------------------------------------------------------------
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::erase_(const value_type& x)
 {
     const interval_type& x_itv = x.KEY_VALUE;
@@ -933,8 +934,8 @@
 }
 
 
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::erase_rest(const interval_type& x_itv, const CodomainT& x_val,
                  iterator& it, iterator& end_it)
 {

Modified: sandbox/itl/boost/itl/interval_maps.hpp
==============================================================================
--- sandbox/itl/boost/itl/interval_maps.hpp (original)
+++ sandbox/itl/boost/itl/interval_maps.hpp 2008-11-28 17:53:46 EST (Fri, 28 Nov 2008)
@@ -17,7 +17,7 @@
 template
 <
     class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
 class interval_map;
 
@@ -29,25 +29,25 @@
 <
     class SubType, class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap
>
-interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 operator +=
 (
           interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& operand
+ Traits,Interval,Compare,Combine,Alloc>& operand
 )
 {
     typedef IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> operand_type;
+ Traits,Interval,Compare,Combine,Alloc> operand_type;
     const_FORALL(typename operand_type, elem_, operand)
         object.add(*elem_);
 
@@ -59,22 +59,22 @@
 <
     class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap
>
-IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 operator +=
 (
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const typename
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>::value_type& operand
+ Traits,Interval,Compare,Combine,Alloc>::value_type& operand
 )
 {
     return object.add(operand);
@@ -99,22 +99,22 @@
 <
     class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap
>
-IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 operator +=
 (
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const typename
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>::base_pair_type& operand
+ Traits,Interval,Compare,Combine,Alloc>::base_pair_type& operand
 )
 {
     return object.add(operand);
@@ -128,25 +128,25 @@
 <
     class SubType, class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap
>
-interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 operator -=
 (
           interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& operand
+ Traits,Interval,Compare,Combine,Alloc>& operand
 )
 {
     typedef IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> operand_type;
+ Traits,Interval,Compare,Combine,Alloc> operand_type;
     const_FORALL(typename operand_type, elem_, operand)
         object.subtract(*elem_);
 
@@ -170,22 +170,22 @@
 <
     class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap
>
-IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 operator -=
 (
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const typename
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>::value_type& operand
+ Traits,Interval,Compare,Combine,Alloc>::value_type& operand
 )
 {
     return object.subtract(operand);
@@ -196,22 +196,22 @@
 <
     class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap
>
-IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 operator -=
 (
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const typename
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>::base_pair_type& operand
+ Traits,Interval,Compare,Combine,Alloc>::base_pair_type& operand
 )
 {
     return object.subtract(operand);
@@ -225,7 +225,7 @@
 <
     class SubType, class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, template<class,template<class>class>class,
@@ -233,11 +233,11 @@
>
     class IntervalSet
>
-interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 operator -=
 (
           interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const IntervalSet<DomainT,Interval,Compare,Alloc>& erasure
 )
 {
@@ -253,22 +253,22 @@
 <
     class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap
>
-IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 operator -=
 (
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const typename
           IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>::interval_type& operand
+ Traits,Interval,Compare,Combine,Alloc>::interval_type& operand
 )
 {
     return object.erase(operand);
@@ -282,14 +282,14 @@
 <
     class SubType, class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     class OperandT
>
-interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 insert
 (
           interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const OperandT& operand
 )
 {
@@ -305,14 +305,14 @@
 <
     class SubType, class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     class OperandT
>
-interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 erase
 (
           interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const OperandT& operand
 )
 {
@@ -328,19 +328,19 @@
 <
     class SubType, class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     class SectanT
>
-interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>&
+interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>&
 operator *=
 (
           interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const SectanT& operand
 )
 {
     typedef interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> object_type;
+ Traits,Interval,Compare,Combine,Alloc> object_type;
     object_type intersection;
     object.add_intersection(intersection,operand);
     object.swap(intersection);
@@ -354,26 +354,26 @@
 <
     class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class LeftIntervalMap,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class RightIntervalMap
>
 bool is_element_equal
 (
     const LeftIntervalMap <DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& left,
+ Traits,Interval,Compare,Combine,Alloc>& left,
     const RightIntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& right
+ Traits,Interval,Compare,Combine,Alloc>& right
 )
 {
     return Interval_Set::is_element_equal(left, right);
@@ -389,11 +389,11 @@
 <
     class SubType, class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap
>
@@ -401,15 +401,15 @@
 bool is_disjoint
 (
           interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& operand
+ Traits,Interval,Compare,Combine,Alloc>& operand
 )
 {
     typedef interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> object_type;
+ Traits,Interval,Compare,Combine,Alloc> object_type;
     typedef IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> operand_type;
+ Traits,Interval,Compare,Combine,Alloc> operand_type;
     object_type intersection;
 
     if(operand.empty())
@@ -450,12 +450,12 @@
 bool is_disjoint
 (
           interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const IntervalSet<DomainT,Interval,Compare,Alloc>& operand
 )
 {
     typedef interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> object_type;
+ Traits,Interval,Compare,Combine,Alloc> object_type;
     typedef IntervalSet<DomainT,Interval,Compare,Alloc> operand_type;
     object_type intersection;
 
@@ -484,11 +484,11 @@
 <
     class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap,
     template
@@ -502,12 +502,12 @@
 bool is_disjoint
 (
     const IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& object,
+ Traits,Interval,Compare,Combine,Alloc>& object,
     const IntervalSet<DomainT,Interval,Compare,Alloc>& operand
 )
 {
     typedef IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> object_type;
+ Traits,Interval,Compare,Combine,Alloc> object_type;
     typedef IntervalSet<DomainT,Interval,Compare,Alloc> operand_type;
     object_type intersection;
 
@@ -535,11 +535,11 @@
 <
     class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap,
     template
@@ -554,7 +554,7 @@
 (
     const IntervalSet<DomainT,Interval,Compare,Alloc>& left,
     const IntervalMap<DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& right
+ Traits,Interval,Compare,Combine,Alloc>& right
 )
 {
         return is_disjoint(right, left);
@@ -567,18 +567,18 @@
 <
     class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc,
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc,
     template
     <
         class, class, class, template<class,template<class>class>class,
- template<class>class, template<class>class
+ template<class>class, template<class>class, template<class>class
>
     class IntervalMap
>
-typename IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc>::interval_type
-enclosure(const IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc>& object)
+typename IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::interval_type
+enclosure(const IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& object)
 {
- typedef IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Alloc> IntervalMapT;
+ typedef IntervalMap<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc> IntervalMapT;
     typedef typename IntervalMapT::interval_type interval_type;
     return
         object.empty() ? neutron<interval_type>::value()
@@ -590,12 +590,12 @@
 <
     class SubType, class DomainT, class CodomainT,
     class Traits, template<class,template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc
>
-typename interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>::interval_type
-enclosure(const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc>& object)
+typename interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>::interval_type
+enclosure(const interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>& object)
 {
- typedef interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Alloc> IntervalMapT;
+ typedef interval_base_map<SubType,DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc> IntervalMapT;
     typedef typename IntervalMapT::interval_type interval_type;
     return
         object.empty() ? neutron<interval_type>::value()

Modified: sandbox/itl/boost/itl/map.hpp
==============================================================================
--- sandbox/itl/boost/itl/map.hpp (original)
+++ sandbox/itl/boost/itl/map.hpp 2008-11-28 17:53:46 EST (Fri, 28 Nov 2008)
@@ -104,6 +104,7 @@
         typename DataT,
         class Traits = itl::neutron_absorber,
         template<class>class Compare = std::less,
+ template<class>class Combine = itl::inplace_plus,
         template<class>class Alloc = std::allocator
>
     class map: private std::map<KeyT, DataT, Compare<KeyT>,
@@ -130,6 +131,7 @@
         typedef DataT codomain_type;
         typedef std::pair<const KeyT, DataT> value_type;
         typedef Compare<KeyT> key_compare;
+ typedef Combine<DataT> data_combine;
         typedef typename base_type::value_compare value_compare;
 
     public:
@@ -313,60 +315,60 @@
 
     /** Standard equality, which is lexicographical equality of the sets
         as sequences, that are given by their Compare order. */
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
- inline bool operator == (const itl::map<KeyT,DataT,Traits,Compare,Alloc>& lhs,
- const itl::map<KeyT,DataT,Traits,Compare,Alloc>& rhs)
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ inline bool operator == (const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& lhs,
+ const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& rhs)
     {
         typedef std::map<KeyT,DataT,Compare<KeyT>,Alloc<KeyT> > base_type;
         return operator==((const base_type&)lhs, (const base_type&)rhs);
     }
 
     //JODO comment...
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
- inline bool is_element_equal(const itl::map<KeyT,DataT,Traits,Compare,Alloc>& lhs,
- const itl::map<KeyT,DataT,Traits,Compare,Alloc>& rhs)
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ inline bool is_element_equal(const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& lhs,
+ const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& rhs)
     {
         typedef std::map<KeyT,DataT,Compare<KeyT>,Alloc<KeyT> > base_type;
         return operator==((const base_type&)lhs, (const base_type&)rhs);
     }
 
     /** Protonic equality is equality on all elements that do not carry a neutron as content. */
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
- inline bool is_protonic_equal (const itl::map<KeyT,DataT,Traits,Compare,Alloc>& lhs,
- const itl::map<KeyT,DataT,Traits,Compare,Alloc>& rhs)
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ inline bool is_protonic_equal (const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& lhs,
+ const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& rhs)
     {
         //JODO: Efficient implementation.
         typedef std::map<KeyT,DataT,Compare<KeyT>,Alloc<KeyT> > base_type;
 
- itl::map<KeyT,DataT,Traits,Compare,Alloc> lhs0 = lhs;
- itl::map<KeyT,DataT,Traits,Compare,Alloc> rhs0 = rhs;
+ itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc> lhs0 = lhs;
+ itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc> rhs0 = rhs;
         lhs0.absorb_neutrons();
         rhs0.absorb_neutrons();
         return operator==((const base_type&)lhs0, (const base_type&)rhs0);
     }
 
     /** Strict weak less ordering which is given by the Compare order */
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
- inline bool operator < (const itl::map<KeyT,DataT,Traits,Compare,Alloc>& lhs,
- const itl::map<KeyT,DataT,Traits,Compare,Alloc>& rhs)
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ inline bool operator < (const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& lhs,
+ const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& rhs)
     {
         typedef std::map<KeyT,DataT,Compare<KeyT>,Alloc<KeyT> > base_type;
         return operator<((const base_type&)lhs, (const base_type&)rhs);
     }
 
     /** Partial ordering which is induced by Compare */
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
- inline bool operator <= (const itl::map<KeyT,DataT,Traits,Compare,Alloc>& lhs,
- const itl::map<KeyT,DataT,Traits,Compare,Alloc>& rhs)
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ inline bool operator <= (const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& lhs,
+ const itl::map<KeyT,DataT,Traits,Compare,Combine,Alloc>& rhs)
     {
         typedef std::map<KeyT,DataT,Compare<KeyT>,Alloc<KeyT> > base_type;
         return operator<=((const base_type&)lhs, (const base_type&)rhs);
     }
 
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
         template <template<class>class Combinator>
- typename map<KeyT,DataT,Traits,Compare,Alloc>::iterator
- map<KeyT,DataT,Traits,Compare,Alloc>::add(const value_type& val)
+ typename map<KeyT,DataT,Traits,Compare,Combine,Alloc>::iterator
+ map<KeyT,DataT,Traits,Compare,Combine,Alloc>::add(const value_type& val)
     {
         if(Traits::absorbs_neutrons && val.CONT_VALUE == DataT())
             return end();
@@ -398,9 +400,9 @@
         }
     }
 
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
- typename map<KeyT,DataT,Traits,Compare,Alloc>::size_type
- map<KeyT,DataT,Traits,Compare,Alloc>
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ typename map<KeyT,DataT,Traits,Compare,Combine,Alloc>::size_type
+ map<KeyT,DataT,Traits,Compare,Combine,Alloc>
         ::erase(const value_type& value_pair)
     {
         if(Traits::absorbs_neutrons && value_pair.CONT_VALUE == DataT())
@@ -418,9 +420,9 @@
     }
 
 
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
- typename map<KeyT,DataT,Traits,Compare,Alloc>::iterator
- map<KeyT,DataT,Traits,Compare,Alloc>::subtract(const value_type& val)
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ typename map<KeyT,DataT,Traits,Compare,Combine,Alloc>::iterator
+ map<KeyT,DataT,Traits,Compare,Combine,Alloc>::subtract(const value_type& val)
     {
         if(Traits::emits_neutrons)
             return add<inplace_minus>(val);
@@ -444,8 +446,8 @@
     }
 
 
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
- std::string map<KeyT,DataT,Traits,Compare,Alloc>::as_string()const
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ std::string map<KeyT,DataT,Traits,Compare,Combine,Alloc>::as_string()const
     {
         std::string repr;
         const_FORALL_THIS(it) {
@@ -460,9 +462,9 @@
         return repr;
     }
 
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
         template<class Predicate>
- map<KeyT,DataT,Traits,Compare,Alloc>& map<KeyT,DataT,Traits,Compare,Alloc>
+ map<KeyT,DataT,Traits,Compare,Combine,Alloc>& map<KeyT,DataT,Traits,Compare,Combine,Alloc>
         ::erase_if(const Predicate& pred)
     {
         iterator it = begin();
@@ -474,10 +476,10 @@
     }
 
 
- template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Alloc>
+ template <typename KeyT, typename DataT, class Traits, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
         template<class Predicate>
- map<KeyT,DataT,Traits,Compare,Alloc>& map<KeyT,DataT,Traits,Compare,Alloc>
- ::assign_if(const map<KeyT,DataT,Traits,Compare,Alloc>& src, const Predicate& pred)
+ map<KeyT,DataT,Traits,Compare,Combine,Alloc>& map<KeyT,DataT,Traits,Compare,Combine,Alloc>
+ ::assign_if(const map<KeyT,DataT,Traits,Compare,Combine,Alloc>& src, const Predicate& pred)
     {
         clear();
         const_iterator it = src.begin();
@@ -489,12 +491,12 @@
     }
     //-------------------------------------------------------------------------
     template <typename KeyT, typename DataT, class Traits,
- template<class>class Compare, template<class>class Alloc>
- map<KeyT,DataT,Traits,Compare,Alloc>&
- insert(map<KeyT,DataT,Traits,Compare,Alloc>& object,
- const map<KeyT,DataT,Traits,Compare,Alloc>& insertee)
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ map<KeyT,DataT,Traits,Compare,Combine,Alloc>&
+ insert(map<KeyT,DataT,Traits,Compare,Combine,Alloc>& object,
+ const map<KeyT,DataT,Traits,Compare,Combine,Alloc>& insertee)
     {
- typedef map<KeyT,DataT,Traits,Compare,Alloc> map_type;
+ typedef map<KeyT,DataT,Traits,Compare,Combine,Alloc> map_type;
 
         const_FORALL(typename map_type, elem_, insertee)
             object.insert(*elem_);
@@ -503,12 +505,12 @@
     }
 
     template <typename KeyT, typename DataT, class Traits,
- template<class>class Compare, template<class>class Alloc>
- map<KeyT,DataT,Traits,Compare,Alloc>&
- erase(map<KeyT,DataT,Traits,Compare,Alloc>& object,
- const map<KeyT,DataT,Traits,Compare,Alloc>& erasee)
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ map<KeyT,DataT,Traits,Compare,Combine,Alloc>&
+ erase(map<KeyT,DataT,Traits,Compare,Combine,Alloc>& object,
+ const map<KeyT,DataT,Traits,Compare,Combine,Alloc>& erasee)
     {
- typedef map<KeyT,DataT,Traits,Compare,Alloc> map_type;
+ typedef map<KeyT,DataT,Traits,Compare,Combine,Alloc> map_type;
 
         const_FORALL(typename map_type, elem_, erasee)
             object.erase(*elem_);

Modified: sandbox/itl/boost/itl/split_interval_map.hpp
==============================================================================
--- sandbox/itl/boost/itl/split_interval_map.hpp (original)
+++ sandbox/itl/boost/itl/split_interval_map.hpp 2008-11-28 17:53:46 EST (Fri, 28 Nov 2008)
@@ -131,20 +131,21 @@
         class Traits = itl::neutron_absorber,
         template<class, template<class>class>class Interval = itl::interval,
         template<class>class Compare = std::less,
+ template<class>class Combine = itl::inplace_plus,
         template<class>class Alloc = std::allocator
>
     class split_interval_map:
- public interval_base_map<split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>,
- DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ public interval_base_map<split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>,
+ DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     {
     public:
         typedef Traits traits;
- typedef split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc> type;
- typedef interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc> joint_type;
- typedef interval_base_map <split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>,
- DomainT,CodomainT,Traits,Interval,Compare,Alloc> base_type;
+ typedef split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc> type;
+ typedef interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc> joint_type;
+ typedef interval_base_map <split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>,
+ DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc> base_type;
 
- typedef split_interval_map<DomainT,CodomainT,itl::neutron_absorber,Interval,Compare,Alloc>
+ typedef split_interval_map<DomainT,CodomainT,itl::neutron_absorber,Interval,Compare,Combine,Alloc>
             neutron_absorber_type;
 
         typedef Interval<DomainT,Compare> interval_type;
@@ -172,16 +173,16 @@
         template<class SubType>
         split_interval_map& operator =
             (const interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& src)
+ Traits,Interval,Compare,Combine,Alloc>& src)
         { assign(src); return *this; }
 
         /// Assignment from a base interval_map.
         template<class SubType>
         void assign(const interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc>& src)
+ Traits,Interval,Compare,Combine,Alloc>& src)
         {
             typedef interval_base_map<SubType,DomainT,CodomainT,
- Traits,Interval,Compare,Alloc> base_map_type;
+ Traits,Interval,Compare,Combine,Alloc> base_map_type;
             this->clear();
             // Can be implemented via _map.insert: Interval joining not necessary.
             const_FORALL(typename base_map_type, it, src)
@@ -240,8 +241,8 @@
     } ;
 
 
- template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
- bool split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+ bool split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
         ::contains_(const value_type& interv_value)const
     {
         interval_type interv = interv_value.KEY_VALUE;
@@ -257,8 +258,8 @@
 
 
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::fill(const value_type& value)
 {
     //collision free insert is asserted
@@ -270,9 +271,9 @@
 }
 
 template <typename DomainT, typename CodomainT, class Traits,
- template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+ template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::fill_gap(const value_type& value, const Combiner& combine)
 {
     //collision free insert is asserted
@@ -294,9 +295,9 @@
 //-----------------------------------------------------------------------------
 // add<Combinator>(pair(interval,value)):
 //-----------------------------------------------------------------------------
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::add_(const value_type& x, const Combiner& combine)
 {
     const interval_type& x_itv = x.KEY_VALUE;
@@ -378,9 +379,9 @@
     }
 }
 
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::add_rest(const interval_type& x_itv, const CodomainT& x_val,
                iterator& it, iterator& end_it,
                const Combiner& combine)
@@ -408,9 +409,9 @@
     add_rear(x_rest, x_val, it, combine);
 }
 
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::add_rear(const interval_type& x_rest, const CodomainT& x_val, iterator& it,
                    const Combiner& combine)
 {
@@ -444,9 +445,9 @@
 //-----------------------------------------------------------------------------
 // subtract<Combinator>(pair(interval,value)):
 //-----------------------------------------------------------------------------
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::subtract_(const value_type& x, const Combiner& combine)
 {
     const interval_type& x_itv = x.KEY_VALUE;
@@ -503,9 +504,9 @@
 
 
 
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
     template<class Combiner>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::subtract_rest(const interval_type& x_itv, const CodomainT& x_val,
                     iterator& it, iterator& end_it,
                                         const Combiner& combine)
@@ -557,8 +558,8 @@
 // insert(pair(interval,value)):
 //-----------------------------------------------------------------------------
 template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::insert_(const value_type& x)
 {
     const interval_type& x_itv = x.KEY_VALUE;
@@ -614,8 +615,8 @@
 
 
 template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::insert_rest(const interval_type& x_itv, const CodomainT& x_val,
                   iterator& it, iterator& end_it)
 {
@@ -635,8 +636,8 @@
 }
 
 template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval,
- template<class>class Compare, template<class>class Alloc>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+ template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::insert_rear(const interval_type& x_rest, const CodomainT& x_val,
                   iterator& it)
 {
@@ -658,8 +659,8 @@
 //-----------------------------------------------------------------------------
 // erase(pair(interval,value)):
 //-----------------------------------------------------------------------------
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::erase_(const value_type& x)
 {
     const interval_type& x_itv = x.KEY_VALUE;
@@ -717,8 +718,8 @@
 }
 
 
-template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Alloc>
-void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Alloc>
+template <typename DomainT, typename CodomainT, class Traits, template<class, template<class>class>class Interval, template<class>class Compare, template<class>class Combine, template<class>class Alloc>
+void split_interval_map<DomainT,CodomainT,Traits,Interval,Compare,Combine,Alloc>
     ::erase_rest(const interval_type& x_itv, const CodomainT& x_val,
                  iterator& it, iterator& end_it)
 {

Modified: sandbox/itl/libs/itl/test/test_interval_map_shared.hpp
==============================================================================
--- sandbox/itl/libs/itl/test/test_interval_map_shared.hpp (original)
+++ sandbox/itl/libs/itl/test/test_interval_map_shared.hpp 2008-11-28 17:53:46 EST (Fri, 28 Nov 2008)
@@ -14,6 +14,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -161,6 +162,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -222,6 +224,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -275,6 +278,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -306,6 +310,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -355,6 +360,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -406,6 +412,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -448,6 +455,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -510,6 +518,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -621,6 +630,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>
@@ -736,6 +746,7 @@
                    class Traits = neutron_absorber,
                    template<class,template<class>class>class = interval,
                    template<class>class = std::less,
+ template<class>class = itl::inplace_plus,
                    template<class>class = std::allocator
>class IntervalMap,
           class T, class U>

Modified: sandbox/itl/libs/itl_xt/test/meta_functors/meta_functors.cpp
==============================================================================
--- sandbox/itl/libs/itl_xt/test/meta_functors/meta_functors.cpp (original)
+++ sandbox/itl/libs/itl_xt/test/meta_functors/meta_functors.cpp 2008-11-28 17:53:46 EST (Fri, 28 Nov 2008)
@@ -27,6 +27,7 @@
 +----------------------------------------------------------------------------*/
 
 #include <iostream>
+#include <set>
 #include <boost/mpl/apply.hpp>
 #include <boost/mpl/placeholders.hpp>
 
@@ -70,6 +71,32 @@
   }
 };
 
+template<class T1, class Compare = std::less<T1> >
+class PairSet1
+{
+public:
+ typedef std::set
+ <
+ std::pair<T1,T1>,
+ typename mpl::apply<Compare, std::pair<T1,T1> >::type
+ >
+ ImplSetT;
+
+ typedef std::set
+ <
+ T1,
+ typename mpl::apply<Compare, T1>::type
+ >
+ ElemSetT;
+ //
+ PairSet1(): _set()
+ {cout << "PairSet1 constructed" << endl;}
+
+private:
+ ElemSetT _set;
+};
+
+typedef PairSet1<int, std::less<_> > PairSet1_int;
 
 int main()
 {
@@ -81,6 +108,8 @@
         binator1<int, int, binary> bintor1; bintor1.speak();
         binator2<int, int, binary<_1,_2> > bintor2; bintor2.speak();
 
+ PairSet1_int ps1;
+
     return 0;
 }
 


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