Re: Open Patch Status

2002-10-03 Thread Simon Glover
On Tue, 1 Oct 2002, Robert Spier wrote: > > http://www.parrotcode.org/openpatches > > There are a _lot_ of Pending patches. > > Within a few weeks, I hope to have an automated email nudging about > this weekly. > Here's a couple more that I just stumbled across - they've not been picked up aut

Re: Open Patch Status

2002-10-03 Thread Robert Spier
> Here's a couple more that I just stumbled across - they've not been > picked up automatically because they don't have [PATCH] in the header. > (16077) 'assign' opcode and unmorphing > (16098) First draft of PerlScalar PMC I've tagged them both as patches, so they'll show up in the list now. -R

Re: [xperl #x17733] Net::Telnet - Problem on HP-UX

2002-10-03 Thread Robert Spier
George (via RT) writes: ># New Ticket Created by George ># Please include the string: [perl #17733] ># in the subject line of all future correspondence about this issue. ># http://rt.perl.org/rt2/Ticket/Display.html?id=17733 > Grumble. This guy sent this to the wrong email address. I've boun

Re: [INFO] African Grey array speedup

2002-10-03 Thread Peter Gibbs
Leopold Toetsch wrote: > Please compare to intlist. new P0, . set I0, 1 set I1, 0 loop: set P0, I0 set P0[I1], I0 inc I0 inc I1 lt I0, 10, loop set I2, 0 loop_sc: set I3, P0[I2] inc I2 lt I2, I1, loop_sc end Time Array 13 minutes 18 seconds PerlArray 1

Re: [perl #17731] [PATCH] Integration of Lea like allocators

2002-10-03 Thread Andy Dougherty
On Thu, 3 Oct 2002, Leopold Toetsch wrote: > [1] a test looks for availability of mallinfo, and assumes then, that > the underlying libc uses ptmalloc (which is derived from Lea malloc > 2.6.4). For this case, no malloc.c is linked to parrot, saving ~80 KB. > (This test could be omitted, to use

Re: Self documenting comments for parrot

2002-10-03 Thread Dan Sugalski
At 11:59 PM -0400 10/2/02, Erik Lechak wrote: > By the way is this an RFC thing? Well, changes to POD as far as perl is concerned is probably a RFC thing, but I don't think I'd bother--I know Larry and Damian have some stuff up their sleeves for POD, heredocs, and suchlike things. > Should t

Re: [perl #17731] [PATCH] Integration of Lea like allocators

2002-10-03 Thread Leopold Toetsch
Andy Dougherty wrote: > Similarly, trying out perl5's malloc (the Kingsley malloc, very heavily > modified by Ilya Z to better match perl's typical allocation patterns, and > quite tunable) might be a good idea. Brr, ugly code, deeply nested with per5-ismen ;-) ... But good idea ... An hour l

Re: Self documenting comments for parrot

2002-10-03 Thread Erik Lechak
Thanks for the feedback, Pod it is! I will get back to work on the "getting started" guide. Thanks again, Erik

[perl #17733] Net::Telnet - Problem on HP-UX

2002-10-03 Thread via RT
# New Ticket Created by George # Please include the string: [perl #17733] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt2/Ticket/Display.html?id=17733 > Hello, The following script (with real $host,$user and $pwd) use Net::Telnet; $host='h'

[perl #17739] [PATCH] Tests for assign ops

2002-10-03 Thread via RT
# New Ticket Created by Simon Glover # Please include the string: [perl #17739] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt2/Ticket/Display.html?id=17739 > Patch below adds tests for assign_p_i, assign_p_n and assign_p_s. (There's no test f

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 04:47:26PM -0500, Garrett Goebel wrote: > > And if we make pre/post conditions and class invariants > > always enforced... > > no. > > post-conditions and invariants are always enforced, but pre-conditions are > different. Right, right. > A derived interface can loose

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 06:46:14PM -0400, Michael G Schwern wrote: > I see us already smashing too many things into the method signature as it > is. It will rapidly get messy if you have a method with a complex signature > and a handful of attributes and preconditions. I think I have my own coun

Re: Delegation syntax? (was: Re: Private contracts)

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 03:54:09PM -0700, Michael Lazzaro wrote: > I have no *good* syntax proposals for this, I don't think I've ever > seen the problem solved with syntax that I really ever liked. Class::Delegation? -- Michael G. Schwern <[EMAIL PROTECTED]>http://www.pobox

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 07:23:14PM -0400, Michael G Schwern wrote: >invar { .shoulders == .knees == .toes == 2 } This may explain why I can only count to 12 with my shoes off. As this is my 3rd reply to myself in the thread, I'll call it a night. :) -- Michael G. Schwern <[EMAIL PR

Re: Delegation syntax?

2002-10-03 Thread Michael Lazzaro
On Thursday, October 3, 2002, at 04:25 PM, Michael G Schwern wrote: > On Thu, Oct 03, 2002 at 03:54:09PM -0700, Michael Lazzaro wrote: >> I have no *good* syntax proposals for this, I don't think I've ever >> seen the problem solved with syntax that I really ever liked. > > Class::Dele

Re: Delegation syntax? (was: Re: Private contracts)

2002-10-03 Thread John Williams
On Thu, 3 Oct 2002, Michael Lazzaro wrote: > > 1) Delegation through inheritance: > (a.k.a. "mixin" classes, "hard delegation", "concrete interfaces", > etc., etc.) > > Example: I want to say that a class DataManager has the capabilities > of the interfaces DataStrategy and Cache

Re: Private contracts?

2002-10-03 Thread John Williams
On Thu, 3 Oct 2002, Allison Randal wrote: > On Thu, Oct 03, 2002 at 03:00:21PM -0400, Michael G Schwern wrote: > > On Thu, Oct 03, 2002 at 02:46:38PM -0400, Michael G Schwern wrote: > > > class ATV is Car, interface { > > > > Hmmm. That should probably be > > > > class ATV isa Car is i

Re: Private contracts?

2002-10-03 Thread John Williams
On Thu, 3 Oct 2002, Trey Harris wrote: > Incidentally, has there been any headway made on how you DO access > multiple classes with the same name, since Larry has (indirectly) promised > us that? I.e., I import two classes "LinkedList" and "BTree", both of > which define a "Node" class? Hopeful

Re: Private contracts?

2002-10-03 Thread Trey Harris
In a message dated Thu, 3 Oct 2002, John Williams writes: > On Thu, 3 Oct 2002, Trey Harris wrote: > > > Incidentally, has there been any headway made on how you DO access > > multiple classes with the same name, since Larry has (indirectly) promised > > us that? I.e., I import two classes "Link

Re: Delegation syntax?

2002-10-03 Thread Trey Harris
In a message dated Thu, 3 Oct 2002, Michael Lazzaro writes: > On Thursday, October 3, 2002, at 04:25 PM, Michael G Schwern wrote: > > Class::Delegation? > > Yeah, it's one of the best I've seen: it makes sense, does everything I > want, and is easy to explain even to newbies. The perl5 hash-bas

Re: Delegation syntax? (was: Re: Private contracts)

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 07:59:33PM -0600, John Williams wrote: > Reaction #2: Inheritance would automatically delegate all those > methods, so again, in what way does inheritance _not_ solve the problem? I don't think p6l is the right place to discuss the merits of delegation, let's just say it'

Re: Delegation syntax?

2002-10-03 Thread Michael G Schwern
On Fri, Oct 04, 2002 at 12:28:29AM -0400, Trey Harris wrote: > I think my point here is that there are clearly places where we need > stronger built-in support in Perl of some OO concepts. Delegation may not > be one of them--it's easy enough to graft on, and TMTOWTDI may be good > here. Delegat

Private contracts?

2002-10-03 Thread Michael G Schwern
I've been mucking about a bit more with this whole interface thing. So if we make method signatures only enforced on subclasses if the parent class or method has the interface property... except private methods, obviously. And if we make pre/post conditions and class invariants always enfor

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 02:46:38PM -0400, Michael G Schwern wrote: > class ATV is Car, interface { Hmmm. That should probably be class ATV isa Car is interface { -- Michael G. Schwern <[EMAIL PROTECTED]>http://www.pobox.com/~schwern/ Perl Quality Assurance <[EMAIL PROT

Re: Private contracts?

2002-10-03 Thread Mike Lambert
> I've been mucking about a bit more with this whole interface thing. > > So if we make method signatures only enforced on subclasses if the parent > class or method has the interface property... > > except private methods, obviously. > > And if we make pre/post conditions and class invariants

Re: Private contracts?

2002-10-03 Thread Allison Randal
On Thu, Oct 03, 2002 at 02:46:38PM -0400, Michael G Schwern wrote: > > attr _tilt is private; BTW, that's: attr $.tilt; Attributes are private by default. Allison

Re: Private contracts?

2002-10-03 Thread Allison Randal
On Thu, Oct 03, 2002 at 03:00:21PM -0400, Michael G Schwern wrote: > On Thu, Oct 03, 2002 at 02:46:38PM -0400, Michael G Schwern wrote: > > class ATV is Car, interface { > > Hmmm. That should probably be > > class ATV isa Car is interface { That's: class ATV is Car is interf

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 03:45:33PM -0500, Allison Randal wrote: > On Thu, Oct 03, 2002 at 03:00:21PM -0400, Michael G Schwern wrote: > > On Thu, Oct 03, 2002 at 02:46:38PM -0400, Michael G Schwern wrote: > > > class ATV is Car, interface { > > > > Hmmm. That should probably be > > > >

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 03:59:08PM -0400, Mike Lambert wrote: > With pre/post conditions, a subclass is allowed to weaken the > preconditions or strengthen the postconditions. How exactly does one "weaken" a precondition? -- Michael G. Schwern <[EMAIL PROTECTED]>http://www.pobox.com/~sc

Re: Private contracts?

2002-10-03 Thread Trey Harris
In a message dated Thu, 3 Oct 2002, Allison Randal writes: > However they're defined, they will be clearly marked internally as > properties, so there's little risk of confusing property attachment with > inheritance. except that they seem to share a single namespace, since both user-defined

Re: Private contracts?

2002-10-03 Thread Michael Lazzaro
> Makes sense, no? I like that quite a lot. One question I still have is the syntax of pre/post conditions, e.g: > method turn($direction, $how_sharp) { >pre { $how_sharp <= 20 } is private; >...implementation... > } This is obvious

Re: Private contracts?

2002-10-03 Thread Trey Harris
In a message dated Thu, 3 Oct 2002, Michael G Schwern writes: > On Thu, Oct 03, 2002 at 03:59:08PM -0400, Mike Lambert wrote: > > With pre/post conditions, a subclass is allowed to weaken the > > preconditions or strengthen the postconditions. > > How exactly does one "weaken" a precondition? Yo

Re: Private contracts?

2002-10-03 Thread Allison Randal
On Thu, Oct 03, 2002 at 05:14:22PM -0400, Michael G Schwern wrote: > On Thu, Oct 03, 2002 at 03:45:33PM -0500, Allison Randal wrote: > > On Thu, Oct 03, 2002 at 03:00:21PM -0400, Michael G Schwern wrote: > > > On Thu, Oct 03, 2002 at 02:46:38PM -0400, Michael G Schwern wrote: > > > > class ATV

RE: Private contracts?

2002-10-03 Thread Garrett Goebel
Michael G Schwern: > > I've been mucking about a bit more with this whole interface thing. > > So if we make method signatures only enforced on subclasses > if the parent class or method has the interface property... > > except private methods, obviously. > > And if we make pre/post condi

Re: Private contracts?

2002-10-03 Thread Trey Harris
In a message dated Thu, 3 Oct 2002, Allison Randal writes: > So far, classes are uppercase and properties are lowercase, but that's > convention, not law. Do runtime (value) properties and compile-time (variable) properties share the same namespace? That is, to go back to an earlier discussion,

RE: Private contracts?

2002-10-03 Thread Garrett Goebel
Garrett Goebel: > Michael G Schwern: > > But I don't want my subclasses to be constrained by that. > > It's just an implementation detail that I only wish to > > enforce upon ATV and not it's children. implementation details don't belong in interfaces

Re: Private contracts?

2002-10-03 Thread Paul Johnson
On Thu, Oct 03, 2002 at 02:29:57PM -0700, Michael Lazzaro wrote: > (As a lame aside, are we going to have a concept of "private" vs. > "protected" vs. "public", or just private/public? No protected. Even Stroustrup admits it was a mistake in D&E. -- Paul Johnson - [EMAIL PROTECTED] http://ww

Re: Private contracts?

2002-10-03 Thread Jonathan Scott Duff
On Thu, Oct 03, 2002 at 02:29:57PM -0700, Michael Lazzaro wrote: > One question I still have is the syntax of pre/post conditions, e.g: > > > method turn($direction, $how_sharp) { > > pre { $how_sharp <= 20 } is private; > > ...implementation... > >

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 04:54:13PM -0500, Garrett Goebel wrote: > Garrett Goebel: > > Michael G Schwern: > > > But I don't want my subclasses to be constrained by that. > > > It's just an implementation detail that I only wish to > > > enforce upon ATV and not it's children. > > implementation

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 05:23:08PM -0500, Jonathan Scott Duff wrote: > I don't know, but I think it's supposed to be like this: > > # part of the signature > method turn($dir,$ang) is pre { $ang <= 20 } { > ... > } > > # part of the implementation > method tur

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 02:29:57PM -0700, Michael Lazzaro wrote: > Do you think it's sufficiently clear to newbies that the pre { } is > associated with the "signature" of the turn() interface method, and not > just the _implementation_ of turn() in Vehicle? The rule would be pretty simple to t

Re: Private contracts?

2002-10-03 Thread Michael G Schwern
On Thu, Oct 03, 2002 at 05:30:49PM -0400, Trey Harris wrote: > In a message dated Thu, 3 Oct 2002, Michael G Schwern writes: > > > On Thu, Oct 03, 2002 at 03:59:08PM -0400, Mike Lambert wrote: > > > With pre/post conditions, a subclass is allowed to weaken the > > > preconditions or strengthen th

Delegation syntax? (was: Re: Private contracts)

2002-10-03 Thread Michael Lazzaro
On Thursday, October 3, 2002, at 03:18 PM, Paul Johnson wrote: >> (As a lame aside, are we going to have a concept of "private" vs. >> "protected" vs. "public", or just private/public? > > No protected. Even Stroustrup admits it was a mistake in D&E. Oh, thank God. I was hoping people would sa

RE: Private contracts?

2002-10-03 Thread Garrett Goebel
Michael G Schwern: > On Thu, Oct 03, 2002 at 05:30:49PM -0400, Trey Harris wrote: > > In a message dated Thu, 3 Oct 2002, Michael G Schwern writes: > > > > > On Thu, Oct 03, 2002 at 03:59:08PM -0400, Mike Lambert wrote: > > > > With pre/post conditions, a subclass is allowed to weaken the > > > >

Re: Private contracts?

2002-10-03 Thread Mike Lambert
Michael G Schwern wrote: > How exactly does one "weaken" a precondition? Say I define a mathematical mod() function in my parent number class. precondition: $a > 0, $b > 0, $b is int mod( $a, $b ) Then in my subclass, I want to make it work in a wider variety of contexts. I change the definiti

RE: Private contracts?

2002-10-03 Thread Trey Harris
In a message dated Thu, 3 Oct 2002, Garrett Goebel writes: > Michael G Schwern: > > On Thu, Oct 03, 2002 at 05:30:49PM -0400, Trey Harris wrote: > > > In a message dated Thu, 3 Oct 2002, Michael G Schwern writes: > > > > > > > On Thu, Oct 03, 2002 at 03:59:08PM -0400, Mike Lambert wrote: > > > >

Re: [perl #17739] [PATCH] Tests for assign ops

2002-10-03 Thread Leopold Toetsch
Simon Glover (via RT) wrote: > Patch below adds tests for assign_p_i, assign_p_n and assign_p_s. > (There's no test for assign_p_p because the scalar PMCs don't support > it yet). Nothing against the tests - it's always a good thing to have tests - but I'm confused: inline op set(inout PMC

Re: [perl #17739] [PATCH] Tests for assign ops

2002-10-03 Thread Peter Gibbs
Leopold Toetsch wrote: > Nothing against the tests - it's always a good thing to have tests - but > I'm confused: > > inline op set(inout PMC, in INT) { >$1->vtable->set_integer_native(interpreter, $1, $2); >goto NEXT(); > } > inline op assign(inout PMC, in INT) { >$1->vtable->set_in