RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread Jonathan Lang
Trey Harris wrote: One thing that occurs to me: following this "contract" or "promise" analogy, what does C<...> mean in a role or class? Unless I've missed somewhere in the Synopses that explicates C<...> differently in this context, yada-yada-yada is just code that "complains bitterly (by call

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread Trey Harris
In a message dated Thu, 28 Sep 2006, Aaron Sherman writes: Jonathan Lang wrote: Aaron Sherman wrote: Jonathan Lang wrote: > Actually, it's a promise made by a package (not a class) to meet the > specification given by a role (which can, and in this case probably > does, reside in a separate fil

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread Aaron Sherman
Jonathan Lang wrote: Aaron Sherman wrote: Jonathan Lang wrote: > Actually, it's a promise made by a package (not a class) to meet the > specification given by a role (which can, and in this case probably > does, reside in a separate file - quite likely one heavily laced with > POD). That's a fi

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

2006-09-28 Thread larry
Author: larry Date: Thu Sep 28 18:53:32 2006 New Revision: 12485 Modified: doc/trunk/design/syn/S03.pod Log: Extirpated machine-dependent definition of bit complement, noticed by audreyt++. Modified: doc/trunk/design/syn/S03.pod ===

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread Jonathan Lang
Aaron Sherman wrote: Jonathan Lang wrote: > Actually, it's a promise made by a package (not a class) to meet the > specification given by a role (which can, and in this case probably > does, reside in a separate file - quite likely one heavily laced with > POD). That's a fine thing to want to do

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread Aaron Sherman
Jonathan Lang wrote: Aaron Sherman wrote: TSa wrote: > Miroslav Silovic wrote: >> package Foo does FooMultiPrototypes { >> ... >> } > > I like this idea because it makes roles the central bearer of type > information. Type information is secondary to the proposal, but I'll run with what you sai

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread Jonathan Lang
Aaron Sherman wrote: TSa wrote: > Miroslav Silovic wrote: >> package Foo does FooMultiPrototypes { >> ... >> } > > I like this idea because it makes roles the central bearer of type > information. Type information is secondary to the proposal, but I'll run with what you said. This (the example,

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread Aaron Sherman
TSa wrote: HaloO, Miroslav Silovic wrote: What bugs me is a possible duplication of functionality. I believe that declarative requirements should go on roles. And then packages could do them, like this: package Foo does FooMultiPrototypes { ... } I like this idea because it makes roles the

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread TSa
HaloO, Trey Harris wrote: I would hate for Perl 6 to start using C or C in the sort of ways that many languages abuse "Object" to get around the restrictions of their type systems. I think that, as a rule, any prototype encompassing all variants of a multi should not only specify types big e

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread TSa
HaloO, Miroslav Silovic wrote: What bugs me is a possible duplication of functionality. I believe that declarative requirements should go on roles. And then packages could do them, like this: package Foo does FooMultiPrototypes { ... } I like this idea because it makes roles the central bea

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-28 Thread Miroslav Silovic
Aaron Sherman wrote: I certainly hope not, as I agree with you! That's not the goal at all, and in fact if that were a side effect, I would not want this to be implemented. The idea of having types AT ALL for protos was something that I threw in because it seemed to make sense at the end. The re