Boost logo

Boost :

From: Gary Powell (Gary.Powell_at_[hidden])
Date: 2001-03-20 09:57:26

> >...or lvalue() and rvalue(). I like lvalue() better than var() du to my
> >hatrd of abbrevs.
> Those are even clearer. And they are specific terms defined in the C++
> standard, so in that sense are not abbreviations.
> --Beman
I think var() and constant() are clearer in meaning for a lambda expression.
var() makes a variable into a lambda expression, and constant() evaluates
the expression inside of () and makes a constant value out of it (constant
as in not re-evaluated within the lambda expression.)

 int foo(int);
 int v;
 for_each(a.begin(), a.end(),
                (var(v) += bind(foo, var(v)) - free1 + constant(20) ) );

 for_each(a.begin(), a.end(),
        (lvalue(v) += bind(foo, lvalue(v)) - free1 + rvalue(20) ) );

But if you still want rvalue and lvalue I'll discuss it with Jaakko. What I
want is a term that will be easily explained to a intermediate student of


Boost list run by bdawes at, gregod at, cpdaniel at, john at