Re: [proto] Restructuring noses in generator

2012-04-29 Thread Joel Falcou

On 04/29/2012 02:41 AM, Eric Niebler wrote:
And some_terminal is not in your domain? How does your generator get 
invoked? I guess I'm confused. Can you send a small repro? 


everything is in my domain, no problem ont his side, I'll try Mathias 
idea and report if anything breaks.

___
proto mailing list
proto@lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/proto


Re: [proto] Restructuring noses in generator

2012-04-28 Thread Mathias Gaunard

On 27/04/12 21:47, Joel Falcou wrote:

How can I use a custom generator to turn a specific node expression into
a different version of itself without triggering endless recursive call ?

My use cas is the following, i want to catch all function node looking
like

tag::function( some_terminal, grammar, ..., grammar )

with any nbr of grammar instances

into

tag::function( some_terminal, my_tuple_terminalgrammar, ..., grammar,
some_other_info )

basically makign n-ary function node into ternayr node with a specific
structures. Of course this new node should live in whatever domain
some_terminal is coming from.

My first attempt was using make_expr in my generator but it endlessly
looped at compile time.

Is there somethign I am missing ?


You could just make make_expr use the default_domain to avoid the recursion.
___
proto mailing list
proto@lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/proto


Re: [proto] Restructuring noses in generator

2012-04-28 Thread Eric Niebler
On 4/28/2012 3:38 AM, Mathias Gaunard wrote:
 On 27/04/12 21:47, Joel Falcou wrote:
 How can I use a custom generator to turn a specific node expression into
 a different version of itself without triggering endless recursive call ?

 My use cas is the following, i want to catch all function node looking
 like

 tag::function( some_terminal, grammar, ..., grammar )

 with any nbr of grammar instances

 into

 tag::function( some_terminal, my_tuple_terminalgrammar, ..., grammar,
 some_other_info )

 basically makign n-ary function node into ternayr node with a specific
 structures. Of course this new node should live in whatever domain
 some_terminal is coming from.
snip

And some_terminal is not in your domain? How does your generator get
invoked? I guess I'm confused. Can you send a small repro?

-- 
Eric Niebler
BoostPro Computing
http://www.boostpro.com
___
proto mailing list
proto@lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/proto