Boost logo

Boost Users :

Subject: Re: [Boost-users] [Bind] How to create a functor which returns one of its arguments?
From: Roman Perepelitsa (roman.perepelitsa_at_[hidden])
Date: 2009-12-08 10:26:58


2009/12/8 Vadim Guchenko <nomail_at_[hidden]>

> Hello, All!
>
> Is there a simple way to create a functor that returns one of its arguments
> _1, _2, ...?
>

In Boost.Lambda _2 is a functor that returns its second argument and
constant(true) is a functor that always returns true. The same works with
Boost.Phoenix.

Roman Perepelitsa.



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