perl6-all@perl.org

2006-01-18 Thread Trey Harris
Excuse my ignorance of the finer points, but I thought the reason for bless's continued existence was so that the same sort of brilliant OO experimentation that Damian and others have done with pure Perl 5 can continue to be done in pure Perl 6 without having to hack p6opaque? Trey

Re: S05.pod

2006-04-17 Thread Trey Harris
In a message dated Mon, 17 Apr 2006, Sean Sieger writes: from There are no C or C modifiers (changes to the meta-characters replace them - see below). to There are no C or C modifiers (change to the meta-characters that replace them - see below). I don't think so There are no meta-char

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

2006-04-30 Thread Trey Harris
In a message dated Sun, 30 Apr 2006, [EMAIL PROTECTED] writes: The whitespace in the middle may include any of the comment forms above. -Because comments always count as whitespace, the dots in +Because comments always count as whitespace, the C<\.> in -$object.#{ foo }.say +$object\#{ f

Re: Containers

2006-07-11 Thread Trey Harris
In a message dated Tue, 11 Jul 2006, Aaron Sherman writes: But would it be reasonable to also provide a named-only parameter to each for that purpose? our List multi Container::each(Bool :$stop, Container [EMAIL PROTECTED]) So that: for each(:stop, =<>; 1..*) -> ($line, $lineno) { say "$line

Re: Containers

2006-07-11 Thread Trey Harris
In a message dated Tue, 11 Jul 2006, Aaron Sherman writes: On Tue, 2006-07-11 at 09:53 -0700, Trey Harris wrote: It sounds reasonable to me, but :stop reads badly. Maybe C<:strictly>? Maybe it's not a function of a flag to each, but a marking that certain lists should be

Re: S04 - forbidden coding-style

2006-07-21 Thread Trey Harris
In a message dated Fri, 21 Jul 2006, Ruud H.G. van Tol writes: Larry Wall schreef: Maybe we should just make statement modifiers uppercase and burn out everyone's eye sockets. :) Or maybe { }. while $x ; Actually, can't that be made to work already (already by the language spec, not

Re: Patch for S06 (and also S03)

2006-08-07 Thread Trey Harris
In a message dated Mon, 7 Aug 2006, Daniel Hulme writes: Sorry to patch the patch, but in -Other sigils binds only to the I argument with that name: +Other sigil binds only to the I argument with that name: the replacement makes no more sense than the original. "Other sigils bind" or "Any othe

Re: clarify: does "Dog is Mammal" load Mammal for you?

2006-08-22 Thread Trey Harris
In a message dated Mon, 21 Aug 2006, Jonathan Scott Duff writes: But, assuming for the moment that C autoloads C, does that mean that class Dog is Mammal-4.5 is valid? Yes, it must be valid. See http://dev.perl.org/perl6/doc/design/syn/S11.html#Versioning : So you can just say m

Re: clarify: does "Dog is Mammal" load Mammal for you?

2006-08-22 Thread Trey Harris
Oops, Luke Palmer alerted me to the fact that I screwed up in the below. In a message dated Tue, 22 Aug 2006, Trey Harris writes: My question is, if a program is running where two versions of Dog are loaded, say 1.3.4 and 2.1, and a file contains: use Dog-1.3.4-cpan:JRANDOM; class Poodle

Re: clarifying the spec for 'ref'

2006-08-25 Thread Trey Harris
In a message dated Fri, 25 Aug 2006, Daniel Hulme writes: If "changing that functionality beyond recognition" means changing its external behavior (as opposed to its internal behavior) so that it acts differently from what the superclass had promised to do, then no, it's not any weirder--but I

Re: clarifying the spec for 'ref'

2006-08-25 Thread Trey Harris
In a message dated Fri, 25 Aug 2006, Juerd writes: Trey Harris skribis 2006-08-25 13:26 (-0700): Explain to me how "nontraditional" DBC might work in an internally consistent way. Otherwise, this is hand-waving. :-) Perl *is* hand-waving. Yeah, but hand-waving on how it m

Re: clarifying the spec for 'ref'

2006-08-25 Thread Trey Harris
In a message dated Fri, 25 Aug 2006, Mark J. Reed writes: I think the justification for Luke's POV is the number of operations each class provides. But my perspective agrees with Juerd - subclasses can remove functionality as well as adding it, and I definitely view "constant" as an add-on modi

Re: clarifying the spec for 'ref'

2006-08-25 Thread Trey Harris
In a message dated Fri, 25 Aug 2006, jerry gay writes: perhaps trey meant "subclasses can add constraints as well as functionality" instead of "subclasses can remove functionality as well as adding it." just a guess. ~jerry Ok... same thing from a DBC perspective. Subclasses can add functiona

Re: clarifying the spec for 'ref'

2006-08-25 Thread Trey Harris
In a message dated Fri, 25 Aug 2006, Mark J. Reed writes: On 8/25/06, Trey Harris <[EMAIL PROTECTED]> wrote: > subclasses can remove functionality as well as adding it Can someone suggest some reading I can do to understand how that works? I can't wrap my head around the idea

Re: clarifying the spec for 'ref'

2006-08-25 Thread Trey Harris
In a message dated Fri, 25 Aug 2006, Mark J. Reed writes: OK, I admit I wasn't thinking about things from a DBC perspective, and misunderstood "DBC" to be a reference to some database module. I here am new and I didn't have context. My bad. But if we're talking design-by-contract, I don't see

Re: clarifying the spec for 'ref'

2006-08-25 Thread Trey Harris
In a message dated Fri, 25 Aug 2006, Juerd writes: Trey Harris skribis 2006-08-25 11:33 (-0700): Ok... same thing from a DBC perspective. Subclasses can add functionality (by AND'ing postconditions), or remove constraints (by OR'ing preconditions), but they can't tradi

Re: named arguments: What's the signature?

2006-08-29 Thread Trey Harris
In a message dated Tue, 29 Aug 2006, Mark Stosberg writes: Regarding The S06 description of named arguments: http://feather.perl6.nl/syn/S06.html#Named_arguments What I find missing here is documentation of the signature to use if you want to declare "I accept an arbitrary number of named argu

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_param } default{ self.query.param($rm_param) } }}(); This is eerily like Contextual::Return, which made me wonder if it's eve

but semantics (was Re: Naming the method form of s///)

2006-09-01 Thread Trey Harris
In a message dated Thu, 31 Aug 2006, Juerd writes: Hm. I don't know how "but" works exactly, but in the realm of syntactic sugar, this is appealing: $foo but s/foo/bar/ I like it. This should be easy to make work in theory, but for the problem with C's semantics which I'll get to in a mom

Re: but semantics (was Re: Naming the method form of s///)

2006-09-01 Thread Trey Harris
In a message dated Fri, 1 Sep 2006, Juerd writes: Trey Harris skribis 2006-09-01 0:17 (-0700): I think these semantics are Almost Right, but yet Entirely Wrong. The problem is that C reads to me as a *mutating* operator. That is, I would expect the above code snippet to give me a C<$z.y&

Re: Nested statement modifiers.

2006-09-01 Thread Trey Harris
In a message dated Fri, 1 Sep 2006, Paul Seamons writes: I'm not sure if I have seen this requested or discussed. This was definitively rejected by Larry in 2002: http://www.nntp.perl.org/group/perl.perl6.language/9343 He has not revisited the issue in the several times it has come up since.

Re: Nested statement modifiers.

2006-09-01 Thread Trey Harris
In a message dated Fri, 1 Sep 2006, jerry gay writes: On 9/1/06, Trey Harris <[EMAIL PROTECTED]> wrote: In a message dated Fri, 1 Sep 2006, Paul Seamons writes: > I'm not sure if I have seen this requested or discussed. This was definitively rejected by Larry

cperl-mode.el: twigils and opers

2006-09-03 Thread Trey Harris
This has been driving me mad, and an hour of hacking at cperl-mode.el has only convinced me that I don't know elisp well enough to solve the problem Variables with twigils whose name matches something else are getting recognized incorrectly. For example, $.x is getting interpreted as $.

Re: cperl-mode.el: twigils and opers

2006-09-04 Thread Trey Harris
In a message dated Mon, 4 Sep 2006, Steffen Schwigon writes: First you could try an older revision, I recommend r7845 or r10822 of pugs repository. No, neither of those work. To see what I'm talking about, just create a file containing: use v6-alpha; class Point { has $.x; has $.y;

Re: multi method dispatching of optional arguments (further refined)

2006-09-04 Thread Trey Harris
In a message dated Tue, 5 Sep 2006, Ph. Marek writes: I now had a look at http://dev.perl.org/perl6/doc/design/syn/S06.html but didn't find what I meant. Sorry if I'm just dumb and don't understand you (or S06); I'll try to explain what I mean. I don't think you're dumb; the Synopses just requ

C outside of C

2006-09-07 Thread Trey Harris
markstos++ pointed out the following behavior: use v6-alpha; { when 1 ~~ 0 { say "Surprise!" } } This code prints "Surprise!", because $_ is undef, which is false, just like 1 ~~ 0 is. I'd like to make the following suggestions for Synopsis clarification: 1. It will be a

Re: C outside of C

2006-09-07 Thread Trey Harris
In a message dated Thu, 7 Sep 2006, Mark Stosberg writes: To refine this point a bit, the spec is clear that 'when' is useful not just with 'given' but with "any block that sets $_". Thanks, I was not being terribly precice when I conflated when with given. Of course, CATCH is another case whe

Re: the CGI.pm in Perl 6

2006-09-10 Thread Trey Harris
In a message dated Sat, 9 Sep 2006, Mark Stosberg writes: I do share your sentiment that CGI.pm shouldn't be a clone of how P5 works. I'd like the HTML building methods to stay out, which wasn't even one of the differences you cared about yourself. I agree with the sentiment, but as a practical

Re: the CGI.pm in Perl 6

2006-09-10 Thread Trey Harris
In a message dated Sat, 9 Sep 2006, Mark Stosberg writes: I do share your sentiment that CGI.pm shouldn't be a clone of how P5 works. I'd like the HTML building methods to stay out, which wasn't even one of the differences you cared about yourself. I agree with the sentiment, but as a practical

Re: Trying to use Perl5 modules

2006-09-10 Thread Trey Harris
In a message dated Mon, 11 Sep 2006, Richard Hainsworth writes: I am trying to find out how to use (in perl6) perl5 modules that contain subroutines. Imports from Perl 5 modules don't currently work. You can workaround this using .can, see below. use perl5:Time::gmtime; my $gm = gmtime(); p

Re: renaming "grep" to "where"

2006-09-18 Thread Trey Harris
In a message dated Mon, 18 Sep 2006, Darren Duncan writes: Putting aside legacy issues for the moment, I suggest that it might be appropriate to rename the .grep list operator to .where, so we can say, for example: @filtered = @originals.where:{ .foo eq $bar }; Note that this can be writt

Re: any(@originals) ~~ { .foo eq $bar} (was Re: renaming "grep" to "where")

2006-09-19 Thread Trey Harris
In a message dated Tue, 19 Sep 2006, Markus Laire writes: On 9/19/06, Trey Harris <[EMAIL PROTECTED]> wrote: In a message dated Mon, 18 Sep 2006, Darren Duncan writes: > @filtered = @originals.where:{ .foo eq $bar }; Note that this can be written: @filtered = any(@originals)

call, call(), .call, and captures

2006-09-20 Thread Trey Harris
From S06: sub bar ($a,$b,$c,:$mice) { say $mice } sub foo (\$args) { say $args.perl; &bar.call($args); } The C<.call> method of C objects accepts a single C object, and calls it without introducing a C frame. And from S12: In addition to C, the special function C dispatches

Re: Capture sigil

2006-09-20 Thread Trey Harris
In a message dated Wed, 20 Sep 2006, Larry Wall writes: The obvious ASCII for ¢ would be c/ or C/ or c| or c| or maybe just |. I like ¢,but: c/$foo # ASCII of ¢$foo d/$foo # d() divided by $foo is rather confusing. (Same goes for |). So the Term Term exclusion makes me rather lean tow

Re: Capture sigil

2006-09-20 Thread Trey Harris
Oops, I hate typos that result in my writing exactly the opposite of what I meant: In a message dated Wed, 20 Sep 2006, Trey Harris writes: In a message dated Wed, 20 Sep 2006, Larry Wall writes: The obvious ASCII for ¢ would be c/ or C/ or c| or c| or maybe just |. I like ¢,but: c/$foo

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

2006-09-27 Thread Trey Harris
In a message dated Wed, 27 Sep 2006, Aaron Sherman writes: Any thoughts? I'm still thinking about the practical implications of this... but what immediately occurs to me: The point of multiple, as opposed to single, dispatch (well, one of the points, and the only point that matters when we'

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-29 Thread Trey Harris
In a message dated Thu, 28 Sep 2006, Jonathan Lang writes: while roles can be abstract, classes and packages should not be. Really? I think I need to let that sink in and percolate a bit. I'm rather fond of creating abstract superclasses to factor out common object-management code. I have m

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

2006-09-29 Thread Trey Harris
In a message dated Fri, 29 Sep 2006, Aaron Sherman writes: First the high-level point: I'm dropping the RFC, because, as TimToady pointed out on IRC, we're not quite far enough down the line to see the breadth or certainty of the need yet. Yes, but I don't think the conversation should stop.

Re: Abstract roles, classes and objects

2006-10-04 Thread Trey Harris
In a message dated Sun, 1 Oct 2006, Aaron Sherman writes: Trey Harris wrote: In a message dated Fri, 29 Sep 2006, Aaron Sherman writes: [snip] However, that's not to say that a class can't be abstract, just that a class that does an interface (a role with nothing but abstract meth

Re: "Don't tell me what I can't do!"

2006-10-04 Thread Trey Harris
In a message dated Wed, 4 Oct 2006, chromatic writes: The assumption I remember from the design meetings was always "No library designer has the knowledge or the right to tell me how fast or strict my program has to run." Whatever B&D you do in the privacy of your own modules is fine, but if it

Re: "Don't tell me what I can't do!"

2006-10-04 Thread Trey Harris
In a message dated Wed, 4 Oct 2006, jesse writes: On Wed, Oct 04, 2006 at 12:01:22PM -0700, chromatic wrote: The point is that the person writing the program decides which handcuffs or costumes all of the code has to wear, not the person writing the libraries. If you want to set a policy for you

Re: Abstract roles, classes and objects

2006-10-04 Thread Trey Harris
In a message dated Wed, 4 Oct 2006, Jonathan Lang writes: In Perl 6, the abstract SystemMonitor could be a role, and a concrete ScriptedMonitor could be a class that does SystemMonitor, but it's not at all clear to me what HardwareMonitor would be, since classes can't be abstract and roles can't

Re: "Don't tell me what I can't do!"

2006-10-08 Thread Trey Harris
In a message dated Wed, 4 Oct 2006, Smylers writes: Trey Harris writes: I remember not so many years ago when there were a lot of modules floating around that required you to do "no strict" of various flavors in order to use them. Really? How? I wrote imprecisely. Not to &qu

Re: Edge case: incongruent roles

2006-10-13 Thread Trey Harris
In a message dated Fri, 13 Oct 2006, Jonathan Lang writes: Since Baz does both Foo and Bar, you cannot use type-checking to resolve this dilemma. Why not? Why shouldn't this work: my Foo $obj1 = getBaz(); # object is a Baz $obj1.baz(); # Foo::baz is called my Bar $obj2 =

Re: how typish are roles

2006-10-25 Thread Trey Harris
In a message dated Wed, 25 Oct 2006, TSa writes: from the recent threads 'class interface of roles', 'set operations for roles' and 'signature subtyping and role merging' I wonder how typish roles actually are. Some seem to consider roles as lightweight particles that serve to compose classes.

Re: how typish are roles

2006-10-28 Thread Trey Harris
In a message dated Sat, 28 Oct 2006, chromatic writes: When you specify a type to constrain some operation, you specify that the target entity must perform that role. That statement is very concise and direct. If the fuzziness I observed about the identity of the basic building block of type w

where constraints as roles (was Re: how typish are roles)

2006-10-28 Thread Trey Harris
In a message dated Sat, 28 Oct 2006, Trey Harris writes: In a message dated Sat, 28 Oct 2006, chromatic writes: When you specify a type to constrain some operation, you specify that the target entity must perform that role. That statement is very concise and direct. If the fuzziness I

Re: Apoc 5 questions/comments

2002-06-07 Thread Trey Harris
In a message dated Fri, 7 Jun 2002, [EMAIL PROTECTED] writes: > The most serious objection to this was 'well, use modules for matching *ml" - > which simply points out that the current incarnation of perl6 regex doesn' > t handle a very large class of matching problems very well. I don't think th

Re: Apoc 5 questions/comments

2002-06-09 Thread Trey Harris
In a message dated Sun, 9 Jun 2002, Damian Conway writes: > Trey Harris wrote: > > rule parsetag :w { > > $tagname := > > %attrs := [ () = > > () > > ]* > >/? > > > > } On seco

Re: Perl 6, The Good Parts Version

2002-07-03 Thread Trey Harris
In a message dated Wed, 3 Jul 2002, Michael G Schwern writes: > Attributes > Transcending mere objects and classes, Perl 6 introduces adverbs. Attributes are adjectives, not adverbs. Aren't they? Trey

$RS paragraph mode going away?

2002-07-05 Thread Trey Harris
Did I hear somewhere that paragraph mode (i.e., C<$/ = ''>) is going away? I can't find it in my archives, so maybe it was one of my feverish Perl 6 dreams (of which I've had too many lately, after spending a few days in training with Damian ;-) but I think I heard it said by someone with authorit

Re: Perl6 grammar (take IV)

2002-07-06 Thread Trey Harris
In a message dated Sat, 6 Jul 2002, Sean O'Rourke writes: > - Implicit currying variables ($^a etc) are in. I thought I had read > somewhere they were gone in favor of closure args, but people seem > to be using them, and they're not hard to put in. My understanding is that they still exist

RE: hyper operators - appalling proposal

2002-07-15 Thread Trey Harris
In a message dated Mon, 15 Jul 2002, Brent Dax writes: > With explicit, you just get the result of Inf ** 2 (which presumably is > still Inf) in $bar. Perhaps neither is what you want, but at least it > doesn't take forever to run. Yes. This is my fear of hyperoperation being the default for no

Re: Light ideas

2002-08-02 Thread Trey Harris
In a message dated Fri, 2 Aug 2002, Miko O'Sullivan writes: > OK, would that notation ( @arr[] = $var ) be something that could be added > by a module, in the same way that operators and /* */ will be addable? I don't think we've seen too much about how Larry plans to do Perl-munging-Perl except

Re: 'while <> {' in Perl 6

2002-08-09 Thread Trey Harris
In a message dated Fri, 9 Aug 2002, Adam Lopresto writes: > I was wondering whether the Perl 'while (<>){' idiom will continue to be > supported in Perl 6? I seem to recall people posting example code the list > using it (although I can't dig any up), but it seems to me that if Perl 6's > lazy l

Re: A Perl 6 class question

2002-08-12 Thread Trey Harris
Another one... class Foo is Bar; method a { setup(); } 1; # EOF (Is the 1 still required? I think I heard Damian say it was going away.) The question is, is this valid, if Bar defines a sub/static method 'setup'? Is my instict right that 'sub' in a class is a 'class/static method' in the

Re: Just reading up on Pike...

2002-08-17 Thread Trey Harris
In a message dated Sat, 17 Aug 2002, [EMAIL PROTECTED] writes: > [$!] Typically contains an object with both string and integer > conversions. Whether convertability to both types is enough to satisfy a > superpositional type is an interesting question. I suspect it *is*. Then I'd assume that mul

attr sigils?

2002-08-21 Thread Trey Harris
I'm wondering about how the sigil-invariance rule interacts with attributes. class Foo { attr $bar; attr @bar; method baz { return @.bar[$.bar]; # sigils disambiguate } method frob ($self:) { return $self.bar[$self.bar]; # uh-oh } } Is this

Re: rule, rx and sub

2002-08-27 Thread Trey Harris
In a message dated Tue, 27 Aug 2002, Luke Palmer writes: > No, it's right. But it doesn't break that. In the grammar, C-like > languages include (something like): > > statement: expression ';' > statement: if expression block > > So an if _statement_ terminates itself. The } on a line

Re: Hypothetical synonyms

2002-08-27 Thread Trey Harris
In a message dated 27 Aug 2002, Uri Guttman writes: > m{^\s* $stuff := [ "(.*?)" | (\S+) ] }; Or, how about my ($fields) = /( '"')>|\S+)/; ? :-) Trey

Re: Hypothetical synonyms

2002-08-28 Thread Trey Harris
In a message dated 27 Aug 2002, Uri Guttman writes: > > "LW" == Larry Wall <[EMAIL PROTECTED]> writes: > > LW> On 27 Aug 2002, Uri Guttman wrote: : and quoteline might even > LW> default to " for its delim which would make : that line: > LW> : > LW> : my ($fields) = /(|\S+)/; > > LW

Re: Hypothetical synonyms

2002-08-28 Thread Trey Harris
In a message dated 28 Aug 2002, Aaron Sherman writes: > Ok, just to be certain: > > $_ = "0"; > my $zilch = /0/ || 1; > > Is $zilch C<"0"> or 8? 8? How do you get 8? You'd get a result object which stringified was "0" and booleanfied was true. So here, you'd get a result object vag

Capturing alternations (was Re: Hypothetical synonyms)

2002-08-28 Thread Trey Harris
In a message dated Thu, 29 Aug 2002, Janek Schleicher writes: > Aaron Sherman wrote at Wed, 28 Aug 2002 00:34:15 +0200: > > > $stuff = (defined($1)?$1:$2) if /^\s*(?:"(.*?)"|(\S+))/; > > It gives me the idea of a missing feature: > > What really should be expressed is: > > my ($stuff) = /^\s*

Re: rule, rx and sub

2002-08-30 Thread Trey Harris
In a message dated Thu, 29 Aug 2002, Damian Conway writes: > And, of course, the C property would smart-match its value > against the corrresponding argument, so one could also code optimized > variants like: > > sub repeat is multi ($desc is valued(1), &body) { > body(1); >

Re: auto deserialization

2002-09-02 Thread Trey Harris
In a message dated 1 Sep 2002, Uri Guttman writes: > > "DW" == David Wheeler <[EMAIL PROTECTED]> writes: > > DW> On Sunday, September 1, 2002, at 05:30 AM, Damian Conway wrote: > >> Sure. But the right solution is to permanently eliminate the > >> sesquipedalian > >> name (so you don

Re: Hypothetical variables and scope

2002-09-02 Thread Trey Harris
In a message dated 2 Sep 2002, Aaron Sherman writes: > I'm working on a library of rules and subroutines for dealing with UNIX > system files. This is really just a mental exercise to help me grasp the > new pattern stuff from A5. > > I've hit a snag, though, on hypothetical variables. How would

RE: auto deserialization

2002-09-03 Thread Trey Harris
In a message dated Tue, 3 Sep 2002, Garrett Goebel writes: > Don't the following statements have identical meaning? > > my Date $date; > my Date $date = Date->new(); Not at all. The first declares that $date is a variable containing Date objects, the second does the same, plus instantiates a ne

RE: auto deserialization

2002-09-03 Thread Trey Harris
In a message dated Tue, 3 Sep 2002, Trey Harris writes: > > So what again is wrong with: > > > > my Date $date = 'June 25, 2002'; > > Nothing--if Date is tieable and implements a STORE method which > instantiates a new object. Well, now that I re-read my

Re: auto deserialization

2002-09-03 Thread Trey Harris
In a message dated Tue, 3 Sep 2002, [EMAIL PROTECTED] writes: > On Monday, September 2, 2002, at 03:44 AM, Damian Conway wrote: > > >> my Date $date .= new('Jun 25, 20002'); > > > > H. That's a very interesting idea. > > I like it. > > Looks pretty groovy to me too. It looks like the .= > o

sub/method refs (was Re: auto deserialization)

2002-09-03 Thread Trey Harris
In a message dated Tue, 3 Sep 2002, Buddha Buck writes: > I suspect that, if it makes sense to say > > $foo = &$date.method; > > then it would also make sense to say > > $date .= $foo; > > as well. Interesting, that first line $foo = &$date.method; I need a bit of a refresher here, as my searc

Re: Hypotheticals again

2002-09-04 Thread Trey Harris
In a message dated Wed, 4 Sep 2002, Jonathan Scott Duff writes: > The thread on hypotheticals has caused me to reread that section of A5 a > few times now and a couple of paragraphs bother me the more I read > them. I'll just quote the parts that bother me: > > ... If a regex sets a hypo

Re: Defaulting params (reprise)

2002-09-04 Thread Trey Harris
In a message dated Wed, 4 Sep 2002, Andrew Wilson writes: > On Wed, Sep 04, 2002 at 03:48:41PM -0500, Jonathan Scott Duff wrote: > > On Wed, Sep 04, 2002 at 04:43:25PM -0400, [EMAIL PROTECTED] wrote: > > > Only augment //= in subroutine declarations, //= would also work. > > > I love the //= oper

RE: First crack at Builtins.p6m

2002-09-05 Thread Trey Harris
In a message dated Thu, 5 Sep 2002, Luke Palmer writes: > Why would bitwise have anything but integer signatures. What does > 4.56 | 2.81 mean? Also, should perl lossily convert real to int, or give > an error if it can't? Seems to me that that's a decision that has to be made for each function

RE: First crack at Builtins.p6m

2002-09-05 Thread Trey Harris
(Sorry for responding to my own post, and on a tangential point at that, but...) In a message dated Thu, 5 Sep 2002, Trey Harris writes: > In a message dated Thu, 5 Sep 2002, Luke Palmer writes: > > Why would bitwise have anything but integer signatures. What does > > 4.56 | 2.

Re: Argument aliasing for subs

2002-09-08 Thread Trey Harris
In a message dated Sun, 8 Sep 2002, Steve Canfield writes: > Would it be accurate to say that "is" sets properties of variables, whereas > "but" sets properties of values? If so, what would this output: > > my $var is true; > $var=0; > if ($var) {print "true"} > else {print "false"} > > I

Paren madness (was Re: Regex query)

2002-09-23 Thread Trey Harris
I think this discussion has gotten out of hand, and I hope that Larry, Damian or Allison will grace us with a resolution soon. :-) May I suggest that we start with some DWIMmy examples and try to arrive at a mechanism that will make them all DWIM? Here are my opinions, feel free to shoot them do

Re: Paren madness (was Re: Regex query)

2002-09-23 Thread Trey Harris
In a message dated Mon, 23 Sep 2002, Luke Palmer writes: > Y'all have it backwards. > > [1,*[2,[3,4,5]],6] # [1,2,[3,4,5],6] > [1,*[2,*[3,4,5]],6] # [1,2,3,4,5,6] > > Flat flattens outwards, not inwards. Ah. *slaps head* of course. That makes much more sense

Re: Paren madness (was Re: Regex query)

2002-09-23 Thread Trey Harris
Replying to myself to clear a few things up... In a message dated Mon, 23 Sep 2002, Trey Harris writes: > 2. Scalar assignment. > > my $a;# 1. > $a = X; > > my $a;# 2. > $a = X; > > my $a;# 3. > ($a) = X; > >

Re: Regex query

2002-09-23 Thread Trey Harris
In a message dated 24 Sep 2002, Aaron Sherman writes: > Grrr... I want that to work, really I do, but since, as Larry has > pointed out, there's no functional difference between an array ref and > an array in Perl 6, they would be the same. This is because push is > almost certainly defined as: >

Re: Regex query

2002-09-23 Thread Trey Harris
In a message dated 24 Sep 2002, Aaron Sherman writes: > This is because push is > almost certainly defined as: > > sub push(@target, *@list) { ... } That should be sub push(@target is rw, *@list); but otherwise I think that's right. Now, implementation in Perl 6 (though I assume it's

Re: Regex query

2002-09-24 Thread Trey Harris
In a message dated Tue, 24 Sep 2002, Chip Salzenberg writes: > According to Trey Harris: > > According to Larry, > > $a = (1,2,3); > > is equivalent to > > $a = [1,2,3]; > > because they're both equivalent to > > $a = scalar(1,2,3) > > But

Re: Regex query

2002-09-24 Thread Trey Harris
In a message dated 24 Sep 2002, Aaron Sherman writes: > That doesn't really work. Because now you introduce the case where: > > $x = (1,2,3); > @y = (1,2,3); > $z = [1,2,3]; > push @a, $x, @y, $z, (1,2,3), [1,2,3]; > > Behaves in ways that will take hours to explain to newb

Re: Regex query

2002-09-24 Thread Trey Harris
In a message dated Tue, 24 Sep 2002, Jonathan Scott Duff writes: > On Tue, Sep 24, 2002 at 11:14:04AM -0400, Aaron Sherman wrote: > > Again, we're wading into the waters of over-simplification. Let's try: > > > > sub foo1(){ my @foo=(1,2,3); return @foo; } > > sub foo2(){ my $foo

Re: Paren madness (was Re: Regex query)

2002-09-24 Thread Trey Harris
In a message dated Tue, 24 Sep 2002, Mike Lambert writes: > Consider: > $a = (1); > and > ($a) = (1); Yes? They both do the same thing--set $a to 1. It looks like the bottom one is a list assigned to a list, but that might be optimized out, as it doesn't matter. > > 5. Assignment to arrays an

Re: Interfaces

2002-10-01 Thread Trey Harris
In a message dated Mon, 30 Sep 2002, Michael G Schwern writes: > On Mon, Sep 30, 2002 at 06:04:28PM -0700, David Whipp wrote: > > On a slightly different note, if we have interfaces then I'd really > > like to follow the Eiffel model: features such as renaming methods > > in the derived class may

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.

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: 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 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 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 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

Re: Private contracts?

2002-10-04 Thread Trey Harris
In a message dated Fri, 4 Oct 2002, [EMAIL PROTECTED] writes: > On Fri, Oct 04, 2002 at 09:13:45AM -0400, Chris Dutton wrote: > > > How exactly does one "weaken" a precondition? > > > > At least in Eiffel, if you redefine a method, you may not give it > > stringer preconditions than the original

Re: Private contracts?

2002-10-04 Thread Trey Harris
In a message dated Fri, 4 Oct 2002, [EMAIL PROTECTED] writes: > On Fri, Oct 04, 2002 at 06:26:31PM -0400, Trey Harris wrote: > > > But what does it mean to be "stronger"? How does Eiffel figure out if > > > a given precondition is "stronger" or "we

Re: Private contracts?

2002-10-05 Thread Trey Harris
In a message dated Sat, 5 Oct 2002, Allison Randal writes: > More useful: keep a site-wide or company-wide file of version aliases to > make sure everyone uses the same version, and to make upgrades to the > next version as simple as editing a single file. Ah, but the usual case is this: You dow

Re: RFC: [] as the solitary list constructor

2002-10-06 Thread Trey Harris
In a message dated Sun, 6 Oct 2002, Noah White writes: > > On Sunday, October 6, 2002, at 01:50 AM, Brent Dax wrote: > > > Parens don't construct lists EVER! They only group elements > > syntactically. One common use of parens is to surround a > > comma-separated list, but the *commas* are cre

Re: Private contracts?

2002-10-08 Thread Trey Harris
In a message dated Tue, 8 Oct 2002, Allison Randal writes: > Hmmm... I can see how it might be handy if C would just > grab the highest numbered "Acme::N..." module on the system. After a no strict 'versions'; please. :-) Trey

Re: Interfaces

2002-10-08 Thread Trey Harris
In a message dated Tue, 8 Oct 2002, Michael G Schwern writes: > On Sun, Oct 06, 2002 at 06:17:37PM -0400, Daniel B. Boorstein wrote: > > I think there may be some confusion here. In java, there's no special syntax > > to declare a method an optional part of the interface. All concrete classes > >

Re: Fw: perl6 operator precedence table

2002-10-09 Thread Trey Harris
In a message dated Wed, 9 Oct 2002, Larry Wall writes: > If only we had Unicode editors, we could just force everyone to use > the infinity symbol where they mean it. It seems a shame to make a > special case of the .. operator. Maybe we should ... to mean "and so > on forever": > > @a[0...;

Re: Fw: perl6 operator precedence table

2002-10-09 Thread Trey Harris
In a message dated Wed, 9 Oct 2002, Michael Lazzaro writes: > > Uh-oh: my life is gonna suck. I've spent days hunting obscure bugs > that were caused by a single mistyped character. Now I'll be spending > days hunting obscure bugs that were caused by a single *pixel*. > I've already been the

  1   2   3   >