Re: Iterating over complex structures

2005-12-23 Thread Brad Bowman
But in Perl 5 to navigate complex structures one needs ad-hoc solutions. I wonder if something is planned in Perl 6 as a means to do that through a syntactically convenient construct with ad-hoc-isms pluggable in in the form of suitable hooks (e.g. .on_node( { code; ... } ), etc.) that would

Re: Iterating over complex structures

2005-12-23 Thread Brad Bowman
Well, @Larry has been researching attribute grammars for a month or two now, which are an efficient (programmer-wise, not necessarily processor-wise) method for specifying computations over trees. The only syntax we've seen is that of Language::AttributeGrammar and TGE, whose roots come from

Iterating over complex structures

2005-12-22 Thread Michele Dondi
In Perl 5 Cfor is quite natural for iterating over lists and arrays. Cwhile is preferred for filehandles. With lazy evaluation this difference has been eliminated in Perl 6 so that while still TMTOWTDI (TAEMWTDI!) this kind of iterations will be more consistent. But in Perl 5 to navigate

Re: Iterating over complex structures

2005-12-22 Thread Luke Palmer
On 12/22/05, Michele Dondi Please do not ask me what I have in mind, for I'm not really sure. Well, @Larry has been researching attribute grammars for a month or two now, which are an efficient (programmer-wise, not necessarily processor-wise) method for specifying computations over trees. The