$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
From: David Greene (greened_at_[hidden])
Date: 2006-01-11 12:32:28
Peter Dimov wrote:
> David Greene wrote:
> 
> 
>>Is it possible to bind template functions?  If so, what's the
>>syntax?  I'm having trouble with this test:
>>
>>#include <boost/lambda/bind.hpp>
>>#include <boost/numeric/interval.hpp>
>>
>>#include <vector>
>>#include <cassert>
>>
>>typedef boost::numeric::interval<int> range;
>>
> 
> 
> [...]
> 
> 
>>//    bind(&boost::numeric::in<range>, 5, _1));
> 
> 
> Try
> 
> bind( boost::numeric::in<range::base_type, range::traits_type>, 5, _1 )
> 
> in<> has two template parameters, T and Policies; the & needs to be absent 
> because Lambda has overloads for function references but not for function 
> pointers (the variation with & works with boost::bind, though.) 
Yes, that was the problem.  Thanks for the explanation.
                         -Dave