|
Proto : |
Subject: Re: [proto] [phoenix] not playing nice with other libs
From: Bart Janssens (bart.janssens_at_[hidden])
Date: 2011-05-04 07:39:09
On Wed, May 4, 2011 at 1:25 PM, Thomas Heller
<thom.heller_at_[hidden]> wrote:
> 2) Have some kind of completely variadic proto expression. Not by
> having variadic
> templates but by creating the list of children by some kind of cons list.
> This might requires a quite substantial change in proto, haven't fully
> investigated
> that option.
I needed something like this to implement a "group(expr1, ... , exprN)
function that would group several expressions into one. I also hit the
max arity limit with that solution, so I changed the syntax to "group
<< (expr1, ..., expr2)". Using the overloaded comma operator from
proto, this becomes a binary tree that can be as large as you want,
and can easily be converted to a list using flatten. Probably useless
for phoenix, but I thought I'd mention it anyhow :) I would also be
interested to go back to the group(...) syntax without needing to
modify the limits, so any progress on this would be great.
Cheers,
-- Bart
Proto list run by eric at boostpro.com