
Wouldn't this be a perfect candidate for a layer adjacent to the bind layer in Boost.Phoenix3? It seems like it could be easily composable in the Boost.Phoenix world. Seems almost like it could transparently exist inside the bind layer using the _1_1 syntax, it could dynamically mutate itself as necessary (where _1 and _2 and so equals _1_1 and _1_2 and so forth), would reduce the need of let[] and lambda[] and other such constructs for multi-level complicated bind expression. Sorry for the possible top-post, on my phone, I have no clue where the quoted text will end up... On 9/3/10, Larry Evans <cppljevans@suddenlink.net> wrote:
On 09/03/10 13:21, Dave Abrahams wrote:
On Fri, Sep 3, 2010 at 2:03 PM, Larry Evans <cppljevans@suddenlink.net> wrote:
What it does do is make implementation of beta reduction easier
And why would a C++ programmer care about making the implementation of beta-reduction easier?
I thought that's essentially what mpl::apply<F,A> does. Let's see, from:
http://en.wikipedia.org/wiki/%CE%91_conversion#.CE.B1-conversion
there's:
Beta-reduction captures the idea of function application. Beta-reduction is defined in terms of substitution: the beta-reduction of ((λV.E) E′) is E[V := E′].
For example, assuming some encoding of 2, 7, *, we have the following β-reductions: ((λn.n*2) 7) → 7*2.
Since, as I mentioned, I had trouble understanding how apply worked, and the code seems pretty complicated, at least to me, I was hoping DeBruijn's method would offer simplifications.
OTOH, maybe I'm completely missing something.
-regards, Larry
_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost