Re: A suggestion for a new closure trait.

2006-08-30 Thread Jonathan Lang
Joe Gottman wrote: Since a FIRST block gets called at loop initialization time, it seems to me that it would be useful to have a block closure trait, RESUME, that gets called at the beginning of every loop iteration except the first. Thus, at the beginning of each loop iteration either FIRST or

Re: Implicit current-index variable, scoped inside for-loops

2006-08-30 Thread Carl Mäsak
Damian (), Ruud (), Damian (), Carl (): But it can hardly be blamed for clarity. That's a little unfair. can hardly be blamed - can easily be praised g Apologies to Carl if I misinterpreted. I read it as: can hardly be blamed for (having) clarity ;-) No, yours is the correct

Re: A suggestion for a new closure trait.

2006-08-30 Thread Sage La Torra
On 8/30/06, Jonathan Lang [EMAIL PROTECTED] wrote: Joe Gottman wrote: Since a FIRST block gets called at loop initialization time, it seems to me that it would be useful to have a block closure trait, RESUME, that gets called at the beginning of every loop iteration except the first. Thus,

Re: return Types: what are the enforcement details?

2006-08-30 Thread Yuval Kogman
On Tue, Aug 29, 2006 at 19:49:38 -0500, Mark Stosberg wrote: I'm interested in helping to write some tests for return types, but I'd like some clarifications about them first. Are they just declarations that help Perl optimize stuff, or they actually contracts? 'of' is the contractual form,

Re: Implicit current-index variable, scoped inside for-loops

2006-08-30 Thread Dr.Ruud
Damian Conway schreef: [for @array - $index, $value {...}] No. There's no such magic. I simply screwed up. I should have written: for @array.kv - $index, $value {...} :-( Ah, much clearer now. g -- Affijn, Ruud Gewoon is een tijger.

Re: multi subs with identical signatures: should be a warning ?

2006-08-30 Thread Markus Laire
Since nobody else has answered yet, I'll try to say something. I'll post this also to perl6-language so that those who know better can comment on this. On 8/28/06, Mark Stosberg [EMAIL PROTECTED] wrote: First, what's the recommended reference for learning how dispatching to the right 'multi'

Contextual::Return (was Re: could 'given' blocks have a return value?)

2006-08-30 Thread Trey Harris
In a message dated Tue, 29 Aug 2006, Mark Stosberg writes: my $rm = sub { given $rm_param { when Code { $rm_param(self) } when Hash { %rm_paramrun_mode } default{ self.query.param($rm_param) } }}(); This is eerily like Contextual::Return, which made me wonder if

derived class generators and introspection

2006-08-30 Thread Darren Duncan
All, This email is part of a brain dump from my thoughts over the last week while I was away from a computer. If anything doesn't make sense, I will clarify or expand it in the following days. I believe that Perl 6 already has basically all of the necessary parts built-in for implementing

Re: derived class generators and introspection

2006-08-30 Thread Nigel Hamilton
HI Darren, Generally I really like the idea of fixing the relational/OO mismatch problem by swallowing the relational model whole. :-) But I wonder if we are ready to say goodbye to the tyranny of disk seek? How will your proposed system use the disk? And if it does use the disk what

Re: could 'given' blocks have a return value?

2006-08-30 Thread Mark Stosberg
Agent Zhang wrote: According to S04, given {} is at statement level, so you can't use it directly as an expression. But Perl 6 always allow you to say my $foo = do given {...} As well as my $foo = do if foo {...} else {...} I confirmed this both work now with pugs! I think the

Re: derived class generators and introspection

2006-08-30 Thread Darren Duncan
On Wed, 30 Aug 2006, Nigel Hamilton wrote: HI Darren, Generally I really like the idea of fixing the relational/OO mismatch problem by swallowing the relational model whole. :-) But I wonder if we are ready to say goodbye to the tyranny of disk seek? How will your proposed

Re: derived class generators and introspection

2006-08-30 Thread Darren Duncan
At 5:31 AM +0100 8/31/06, Nigel Hamilton wrote: Rather, the proposal is focusing on what users of these data structures would / could see. The idea is that relational structures have the same ease of use and flexability that things like hashes or arrays or sequences or sets do now. They can of