Control Structures I: given

2002-11-14 Thread Timothy S. Nelson
Hi all. I missed out on the original RFC process; it was over before I even heard of perl6. Anyway, there's something I want to contribute to the Perl community. I've had an idea about control structures which I've never seen anywhere else, so I guess I'm the inventor :). I hope this

Control Structures III: flow modifiers

2002-11-14 Thread Timothy S. Nelson
These are mostly not my ideas (except activate); hopefully not too many of them have already been used. In the same list as "last", "next", and "redo", we should also have - deeper (works with nest -- cf. II: loop) - yield and resume (for co-routines) Also u

Control Structures II: loop

2002-11-14 Thread Timothy S. Nelson
Here's the next part to the Control Structures message I sent before. The next part is to apply the same idea to loop. Please note that this syntax conflicts with stuff already in Perl, but it's a bit clearer what I mean when I do it this way; the question is, do we scrap my i

String concatentation operator

2002-11-14 Thread Andy Wardley
Quoted from "Seven Deadly Sins of Introductory Programming Language Design" [1] by Linda McIver and Damian Conway: We have shown over one thousand novice programming students the C/C++ expression: "the quick brown fox" + "jumps over the lazy dog" and asked them what they believe

Re: String concatentation operator

2002-11-14 Thread Ken Fox
Andy Wardley wrote: Can we overload + in Perl 6 to work as both numeric addition and string concatenation ... Isn't there some nifty Unicode operator perl6 could enlist? ;) How about concatenating adjacent operands? ANSI C does this with string constants and it works very well. It would become

Re: String concatentation operator

2002-11-14 Thread Smylers
Andy Wardley wrote: > Quoted from "Seven Deadly Sins of Introductory Programming Language > Design" [1] by Linda McIver and Damian Conway: > > over one thousand novice programming students ...: > > "the quick brown fox" + "jumps over the lazy dog" > >... they believed that the + s

Re: Control Structures I: given

2002-11-14 Thread Jonathan Scott Duff
On Fri, Nov 15, 2002 at 07:05:26AM +1100, Timothy S. Nelson wrote: > -- > given ($this) { > when $that_happens { "Have a party" } > when $that_doesnt_happen { "Sing" } > all { > # Do something > } >

Re: Control Structures I: given

2002-11-14 Thread Luke Palmer
> Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm > Date: Fri, 15 Nov 2002 07:05:26 +1100 (EST) > From: "Timothy S. Nelson" <[EMAIL PROTECTED]> > Sender: [EMAIL PROTECTED] > X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ > > Hi all. I missed out on the original RFC process

Re: Control Structures II: loop

2002-11-14 Thread Luke Palmer
> Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm > Date: Fri, 15 Nov 2002 07:37:51 +1100 (EST) > From: "Timothy S. Nelson" <[EMAIL PROTECTED]> > Sender: [EMAIL PROTECTED] > X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ > > Here's the next part to the Control Structures me

fonts (was Re: perl6 operator precedence table)

2002-11-14 Thread Trey Harris
Sorry for the one-month-old response, but this message fell between the cracks and I was just reviewing all my old new mail In a message dated Sun, 20 Oct 2002, Me writes: > > Somebody fairly recently recommended some decent fixed-width > typefaces. > > I think it may have been MJD, but I can

Re: Control Structures III: flow modifiers

2002-11-14 Thread Luke Palmer
> Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm > Date: Fri, 15 Nov 2002 07:46:21 +1100 (EST) > From: "Timothy S. Nelson" <[EMAIL PROTECTED]> > Sender: [EMAIL PROTECTED] > X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ > > These are mostly not my ideas (except activate);

Re: String concatentation operator

2002-11-14 Thread Michael G Schwern
On Thu, Nov 14, 2002 at 12:19:47PM +, Andy Wardley wrote: > Can we overload + in Perl 6 to work as both numeric addition > and string concatenation, depending on the type of the operand > on the left? > > I realise the answer is "probably not", given the number/string > ambiguity of Perl varia

Re: String concatentation operator

2002-11-14 Thread Richard Proctor
On Thu 14 Nov, Michael G Schwern wrote: > On Thu, Nov 14, 2002 at 12:19:47PM +, Andy Wardley wrote: > > Can we overload + in Perl 6 to work as both numeric addition > > and string concatenation, depending on the type of the operand > > on the left? There have been times when I have wondered i

Re: String concatentation operator

2002-11-14 Thread Michael G Schwern
On Thu, Nov 14, 2002 at 09:10:07PM +, Richard Proctor wrote: > There have been times when I have wondered if string concatination could be > done without any operator at all. Simply the placement of two things > next to each other as in $foo $bar or $foo$bar would silently concatenate > them.

Re: String concatentation operator

2002-11-14 Thread Mark J. Reed
On 2002-11-14 at 16:47:15, Michael G Schwern wrote: > "string concatenation operator - please stop" > http://archive.develooper.com/perl6-language@;perl.org/msg06710.html BTW, the first link there - to the bikeshed story - is broken. This is the correct link: http://www.freebsd.org/doc/en_US.ISO88

Re: String concatentation operator

2002-11-14 Thread Ken Fox
Michael G Schwern wrote: Before this starts up again, I hereby sentence all potential repliers to first read: "string concatenation operator - please stop" http://archive.develooper.com/perl6-language@;perl.org/msg06710.html The bike shed thing is like Godwin's Law. Only I don't know which side

Re: String concatentation operator

2002-11-14 Thread Dan Sugalski
At 5:57 PM -0500 11/14/02, Ken Fox wrote: Michael G Schwern wrote: Before this starts up again, I hereby sentence all potential repliers to first read: "string concatenation operator - please stop" http://archive.develooper.com/perl6-language@;perl.org/msg06710.html The bike shed thing is like

RE: String concatentation operator

2002-11-14 Thread Garrett Goebel
From: Dan Sugalski [mailto:dan@;sidhe.org] > At 5:57 PM -0500 11/14/02, Ken Fox wrote: > > > >Wasn't one of the main problems with Jarkko's juxtaposition > >proposal that it would kill indirect objects? Have we chased > >our tail on this subject after the colon became required for > >indirect objec

Re: More junctions

2002-11-14 Thread Damian Conway
Luke Palmer asked: When junctions collapse, Sigh, not another one of those dreadful reality TV shows: When animals attack When drivers collide When junctions collapse Next we'll get: When mailing lists explode When threads perpetuate When Piers summarize When Larrys make puns ;-)

Re: Unifying invocant and topic naming syntax

2002-11-14 Thread Damian Conway
Micholas Clarke asked: If a subroutine explicitly needs access to its invocant's topic, what is so wrong with having an explicit read-write parameter in the argument list that the caller of the subroutine is expected to put $_ in? Absolutely nothing. And perfectly legal. You can even call that