Boost logo

Boost Users :

Subject: Re: [Boost-users] [lamda] smart self binding of a function object
From: Geoff Hilton (geoff.hilton_at_[hidden])
Date: 2010-05-11 16:40:01


On 11/05/2010 1:45 PM, alfC wrote:
>>> The question is: What should be the type of XXXX and YYYY?
>>
>> You'll have to make operator() a template:
>>
>> template<class T>
>> function<double(double)> operator()(const T& x_arg, double y_arg);
>>
>
> I was about to do that but then I though that doing so would open a
> can of uncontrolled overload.
> What if I want to restrict T to lambda expressions? what would be the
> best way to do it, enable_if? some special tag? (Do lambda expression
> have any special tag?)
>
> Thank you,
> Alfredo

What about forcing T to be or be derived from an expression template
base class?


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net