Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r56809 - sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta
From: erwann.rogard_at_[hidden]
Date: 2009-10-13 21:58:12


Author: e_r
Date: 2009-10-13 21:58:11 EDT (Tue, 13 Oct 2009)
New Revision: 56809
URL: http://svn.boost.org/trac/boost/changeset/56809

Log:
m
Text files modified:
   sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/bind_delegate.hpp | 23 ++++++++++++++++++-----
   sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/delegate.hpp | 2 +-
   sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/is_scalar_distribution.hpp | 2 --
   sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/random.hpp | 3 ++-
   4 files changed, 21 insertions(+), 9 deletions(-)

Modified: sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/bind_delegate.hpp
==============================================================================
--- sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/bind_delegate.hpp (original)
+++ sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/bind_delegate.hpp 2009-10-13 21:58:11 EDT (Tue, 13 Oct 2009)
@@ -28,11 +28,11 @@
     
         typedef signature<D> sig_;
         typedef delegate<D> deleg_;
- typedef function_traits<typename sig_::type> traits_;
- typedef typename traits_::result_type result_;
- typedef typename traits_::arg2_type arg2_;
+ typedef function_traits<typename sig_::type> traits_;
+ typedef typename traits_::result_type result_;
+ typedef typename traits_::arg2_type arg2_;
         typedef result_ sig2_( arg2_ );
- typedef function<sig2_> type;
+ typedef function<sig2_> type;
         
         template<template<typename> class F>
         static type make(const D& dist){
@@ -47,9 +47,22 @@
     };
 
 }// meta
+
+
+
+ template<template<typename> class F,typename D>
+ typename meta::bind_delegate<D>::type
+ make_bind_delegate(
+ const D& dist
+ )
+ {
+ typedef meta::bind_delegate<D> meta_;
+ return meta_::template make<F>(dist);
+ }
+
+
 }// distribution
 }// toolkit
-
 }// detail
 }// statistics
 }// boost

Modified: sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/delegate.hpp
==============================================================================
--- sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/delegate.hpp (original)
+++ sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/delegate.hpp 2009-10-13 21:58:11 EDT (Tue, 13 Oct 2009)
@@ -28,10 +28,10 @@
         static type make(){ return type(F<D>::instance); }
     };
 
+
 }// meta
 }// distribution
 }// toolkit
-
 }// detail
 }// statistics
 }// boost

Modified: sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/is_scalar_distribution.hpp
==============================================================================
--- sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/is_scalar_distribution.hpp (original)
+++ sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/is_scalar_distribution.hpp 2009-10-13 21:58:11 EDT (Tue, 13 Oct 2009)
@@ -14,7 +14,6 @@
 namespace detail{
 namespace distribution{
 namespace toolkit{
-
 namespace meta{
 
     template<typename D>
@@ -27,7 +26,6 @@
 }// meta
 }// distribution
 }// toolkit
-
 }// detail
 }// statistics
 }// boost

Modified: sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/random.hpp
==============================================================================
--- sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/random.hpp (original)
+++ sandbox/statistics/distribution_toolkit/boost/statistics/detail/distribution_toolkit/meta/random.hpp 2009-10-13 21:58:11 EDT (Tue, 13 Oct 2009)
@@ -40,7 +40,8 @@
         statistics::detail::distribution::toolkit::meta::random<D>
>::type
     make_random(const D& d){
- typedef statistics::detail::distribution::toolkit::meta::random<D> meta_;
+ typedef
+ statistics::detail::distribution::toolkit::meta::random<D> meta_;
         return meta_::make(d);
     }
 


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