[svn:perl6-synopsis] r9126 - doc/trunk/design/syn

2006-05-06 Thread larry
Author: larry Date: Sat May 6 10:04:16 2006 New Revision: 9126 Modified: doc/trunk/design/syn/S02.pod Log: Simplified # to always be comment even where a quote delim is expected. Modified: doc/trunk/design/syn/S02.pod

Re: using the newer collection types - Interval

2006-05-06 Thread mAsterdam
Prompted by Darren Duncan's proposal on Relation type objects I looked at http://dev.perl.org/perl6/doc/design/syn/S06.html and wondered how Interval type objects would fit in. I couldn't imagine how. Now that isn't a surprise (not for lack of imagination but for lack of perl6 knowledge). I

Re: using the newer collection types - Interval

2006-05-06 Thread Darren Duncan
At 3:06 PM +0200 5/6/06, mAsterdam wrote: Prompted by Darren Duncan's proposal on Relation type objects I looked at http://dev.perl.org/perl6/doc/design/syn/S06.html and wondered how Interval type objects would fit in. I couldn't imagine how. Now that isn't a surprise (not for lack of

Re: using the newer collection types - Interval

2006-05-06 Thread Larry Wall
On Sat, May 06, 2006 at 01:41:41PM -0700, Darren Duncan wrote: : Some people may confuse it with a Range, but I don't think so since a : Range progresses in discrete increments, while an Interval would be : continuous. No, Range objects in Perl 6 are defined to be intervals unless used in a

Re: using the newer collection types - Interval

2006-05-06 Thread James Mastros
On Sat, May 06, 2006 at 01:41:41PM -0700, Darren Duncan wrote: Some people may confuse it with a Range, but I don't think so since a Range progresses in discrete increments, while an Interval would be continuous. A range listifies to a (potentially) finite list of discrete elements, but it

Re: using the newer collection types - Interval

2006-05-06 Thread Darren Duncan
At 2:03 PM -0700 5/6/06, Larry Wall wrote (in reply): No, Range objects in Perl 6 are defined to be intervals unless used in a context that implies discrete increments, such as counting in list context. But if you say $x ~~ 1.2 ..^ 3.4 it is exactly equivalent to 1.2 = $x 3.4 The

Re: using the newer collection types - Interval

2006-05-06 Thread mAsterdam
Darren Duncan wrote: mAsterdam wrote: Prompted by Darren Duncan's proposal on Relation type objects I looked at http://dev.perl.org/perl6/doc/design/syn/S06.html and wondered how Interval type objects would fit in. I couldn't imagine how. Now that isn't a surprise (not for lack of imagination

Re: using the newer collection types - Interval

2006-05-06 Thread mAsterdam
Darren Duncan wrote: At 2:03 PM -0700 5/6/06, Larry Wall wrote (in reply): No, Range objects in Perl 6 are defined to be intervals unless used in a context that implies discrete increments, such as counting in list context. But if you say $x ~~ 1.2 ..^ 3.4 it is exactly equivalent to

Re: using the newer collection types - Interval

2006-05-06 Thread Darren Duncan
At 12:45 AM +0200 5/7/06, mAsterdam wrote: Okay, thank you both for clarifying this. Conceptually in my mind, a Range is entirely appropriate to represent a mathematical interval, but I was mistaken about Range being more constrained than it actually is. So, there you go mAsterdam; Range is

Re: using the newer collection types - Interval

2006-05-06 Thread mAsterdam
Darren Duncan wrote: At 12:45 AM +0200 5/7/06, mAsterdam wrote: Okay, thank you both for clarifying this. Conceptually in my mind, a Range is entirely appropriate to represent a mathematical interval, but I was mistaken about Range being more constrained than it actually is. So, there you

Re: using the newer collection types - Interval

2006-05-06 Thread Darren Duncan
At 2:17 AM +0200 5/7/06, mAsterdam wrote: I hope (and think) you are right about that regarding implementing relations. Using them correctly is another story though. I don't think Date, Darwen Lorentzos lightly took the step of introducing 6NF in 2003. Aside, about RVA (relation valued

Re: using the newer collection types - Interval

2006-05-06 Thread Darren Duncan
At 6:06 PM -0700 5/6/06, Darren Duncan wrote: You can do it simply, kind of like this: class Point { has Real $x; has Real $y; }; subset Interval of Range where { all( .items ).does(Real) }; Er, you should read 'Real' as 'Num' (I originally meant Rational, which no longer exists in the

Re: using the newer collection types - Interval

2006-05-06 Thread Larry Wall
On Sat, May 06, 2006 at 06:15:34PM -0700, Darren Duncan wrote: : Er, you should read 'Real' as 'Num' (I originally meant Rational, : which no longer exists in the newest S06); Rational still exists in S02--we just don't automatically promote anything to it currently. (A pragma could change that

Re: using the newer collection types - Interval

2006-05-06 Thread mAsterdam
Darren Duncan wrote: At 2:17 AM +0200 5/7/06, mAsterdam wrote: I hope (and think) you are right about that regarding implementing relations. Using them correctly is another story though. I don't think Date, Darwen Lorentzos lightly took the step of introducing 6NF in 2003. Aside, about RVA