Re: right-to-left pipelines

2002-12-12 Thread Luke Palmer
Date: Thu, 12 Dec 2002 02:19:18 -0500 From: Dan Sugalski [EMAIL PROTECTED] Since that may be either: $foo = bar($x, $y), foo() in which case it's in scalar context, or $foo = bar($x, $y, foo()) in which case it's in list context (sort of) The fun thing is that, potentially,

Re: REs as generators

2002-12-12 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Wed, 11 Dec 2002 17:24:54 -0800 From: Dave Storrs [EMAIL PROTECTED] Mail-Followup-To: [EMAIL PROTECTED] [EMAIL PROTECTED] Content-Disposition: inline X-SMTPD: qpsmtpd/0.20, http://develooper.com/code/qpsmtpd/ On Thu, Dec 12, 2002

Re: Everything is an object.

2002-12-12 Thread Luke Palmer
Date: Thu, 12 Dec 2002 10:11:00 -0800 From: Michael Lazzaro [EMAIL PROTECTED] On Wednesday, December 11, 2002, at 06:56 PM, Simon Cozens wrote: [EMAIL PROTECTED] (Michael Lazzaro) writes: Wel... yes and no. You can make the same argument for operators upon scalars, for example,

Re: REs as generators

2002-12-11 Thread Luke Palmer
Date: Wed, 11 Dec 2002 19:15:53 +1100 From: Damian Conway [EMAIL PROTECTED] I suspect Cstates may be a method only, so that would be either: my @foos = states $foos:; or: my @foos = $foos.states; Though, I suppose we might argue that Cstates is as fundamental to Perl

Re: Comparing Object Identity (was: Re: Stringification of references (Decision, Please?))

2002-12-11 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Wed, 11 Dec 2002 19:21:35 -0500 From: John Siracusa [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.20, http://develooper.com/code/qpsmtpd/ On 12/11/02 6:16 PM, Damian Conway wrote: There's no need for special

Re: Comparing Object Identity (was: Re: Stringification of references (Decision, Please?))

2002-12-11 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm From: Dave Whipp [EMAIL PROTECTED] Date: Wed, 11 Dec 2002 14:54:18 -0800 Organization: Fast-Chip inc. X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4920.2300 X-MimeOLE: Produced By Microsoft

Re: REs as generators

2002-12-10 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Tue, 10 Dec 2002 21:07:34 -0500 From: Adam Turoff [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Content-Disposition: inline X-SMTPD: qpsmtpd/0.20, http://develooper.com/code/qpsmtpd/ On Tue, Dec 10, 2002 at 03:38:58PM -0800, Rich Morin

Re: REs as generators

2002-12-10 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Tue, 10 Dec 2002 15:38:58 -0800 From: Rich Morin [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.20, http://develooper.com/code/qpsmtpd/ On occasion, I have found it useful to cobble up a little language that allows me to generate a list of

Re: 'hashkey context/Str context' (was Re: purge: opposite of grep)

2002-12-09 Thread Luke Palmer
Date: Sun, 8 Dec 2002 21:52:33 -0800 From: Dave Storrs [EMAIL PROTECTED] On Sat, Dec 07, 2002 at 01:28:41PM +1100, Damian Conway wrote: Dave Whipp wrote: I notice everyone still want Int context for eval of the block: Pease don't forget about hashes. Is there such a thing as

Re: Usage of \[oxdb]

2002-12-09 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Mon, 9 Dec 2002 23:43:44 + Cc: [EMAIL PROTECTED] [EMAIL PROTECTED] Content-Disposition: inline From: Nicholas Clark [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.20, http://develooper.com/code/qpsmtpd/ On Sun, Dec 08, 2002 at

Re: Perl 6 and Set Theory

2002-12-08 Thread Luke Palmer
Date: Sun, 08 Dec 2002 19:10:30 +1100 From: Damian Conway [EMAIL PROTECTED] There are actually four types of junction: conjunction: all(@elements) disjunction: any(@elements) abjunction:one(@elements) injunction: none(@elements) Oh yeah... represent

Re: right-to-left pipelines

2002-12-08 Thread Luke Palmer
Date: Mon, 9 Dec 2002 06:00:40 +0100 From: =?iso-8859-1?Q?St=E9phane?= Payrard [EMAIL PROTECTED] Damian: so it's easy to build up more complex right-to-left pipelines, like: (@foo, @bar) := part [/foo/, /bar/], sort { $^b = $^a }

Re: Fw: right-to-left pipelines

2002-12-08 Thread Luke Palmer
Note: this is back on-list. From: Me [EMAIL PROTECTED] Date: Mon, 9 Dec 2002 01:27:55 -0600 [regarding - as a left-to-right pipe-like operator] Please do. As in, please point out on list that '-' is already established as a left-to-right flow/assignment operator so why not consider

Re: Quick translation wanted

2002-12-06 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Sender: [EMAIL PROTECTED] From: Simon Cozens [EMAIL PROTECTED] Date: 06 Dec 2002 14:54:43 + Organization: Bethnal Green is PEOPLE! X-Posted-By: 217.204.174.162 Is it clear how attributes accessors on objects are going to work

Re: Quick translation wanted

2002-12-06 Thread Luke Palmer
Date: Fri, 06 Dec 2002 11:15:20 -0800 From: Larry Wall [EMAIL PROTECTED] As for constructor syntax, I suppose we might make use of the $. notation like this: method new($.name, $.age) { return $class.bless; } Come to think of it, new is a class method, not an object

Re: String Literals, take 3

2002-12-06 Thread Luke Palmer
Date: Fri, 6 Dec 2002 10:16:20 -0700 (MST) From: John Williams [EMAIL PROTECTED] 2) requiring balanced delimiters to be escaped, PRO: it's consistent with non-balanced delimiter requirements CON: you already can; don't force it those who don't want it I'll say no, agreeing with the

Perl 6 and Set Theory

2002-12-06 Thread Luke Palmer
=head1 Perl 6 and Set Theory This document will introduce a new way of thinking about some Perl 6 constructs. In addition, it proposes some minor changes that would help this way of thinking be more consistent. These changes may make Perl 6 a better language in general, as a side effect. Even

For's parallel iteration (was Re: seperate() and/or Array.cull)

2002-12-05 Thread Luke Palmer
From: Brent Dax [EMAIL PROTECTED] Date: Thu, 5 Dec 2002 00:28:52 -0800 Michael G Schwern: # You can do it with a map without much trouble: # # my @indexes = map { /condition/ ? $i++ : () } @stuff; Unless I'm mistaken, that won't work, since $i only gets incremented on matches. I

Re: In defense of zero-indexed arrays.

2002-12-05 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Thu, 5 Dec 2002 02:45:39 -0800 From: Michael G Schwern [EMAIL PROTECTED] Content-Disposition: inline Sender: Michael G Schwern [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ I'm going to ask something

Re: String Literals, take 2

2002-12-04 Thread Luke Palmer
Date: Tue, 03 Dec 2002 18:39:27 -0500 From: James Mastros [EMAIL PROTECTED] Huh? In that case, somebody should tell Angel Faus; Numeric literals, take 3 says 0c777, and nobody disented. IIRC, in fact, nobody's descented to 0c777 since it was first suggested. Well, except Larry. I

Re: seperate() and/or Array.cull

2002-12-04 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Wed, 4 Dec 2002 18:26:17 -0800 From: Michael G Schwern [EMAIL PROTECTED] Content-Disposition: inline Sender: Michael G Schwern [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ (The post about 'purge'

Re: seperate() and/or Array.cull

2002-12-04 Thread Luke Palmer
Date: Wed, 4 Dec 2002 19:21:27 -0800 From: Michael G Schwern [EMAIL PROTECTED] On Wed, Dec 04, 2002 at 08:08:48PM -0700, Luke Palmer wrote: About your idea, though, I'm rather indifferent. However, a friend of mine once asked me if Perl had search or find operation, returning the Iindex

Re: hyper/vector operation operator

2002-11-27 Thread Luke Palmer
From: Ph. Marek [EMAIL PROTECTED] Date: Wed, 27 Nov 2002 09:10:19 +0100 So an usage could be @a = @b =+ @b; @a = @b =+ @b; @a = @b += @b; where the 2nd form would be the most intuitive (from reading this source). Hmm, that would leave us with @a =+= @b; which

Re: Unifying invocant and topic naming syntax

2002-11-20 Thread Luke Palmer
Date: Wed, 20 Nov 2002 12:11:52 -0800 (PST) From: Austin Hastings [EMAIL PROTECTED] --- Larry Wall [EMAIL PROTECTED] wrote: ... This might work now, presuming sub foo (;$_ = $=) (or whatever) is really a binding, and not an assignment. (That's another reason why //=

Re: String concatentation operator

2002-11-18 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Mon, 18 Nov 2002 18:59:58 -0500 From: matt diephouse [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ Damian Conway wrote: matt diephouse wrote: $junction = $x | $y | $z; foo($junction);

Re: Continuations elified

2002-11-18 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm X-Sent: 19 Nov 2002 02:51:54 GMT Date: Tue, 19 Nov 2002 13:51:56 +1100 From: Damian Conway [EMAIL PROTECTED] X-Accept-Language: en, en-us Cc: [EMAIL PROTECTED] [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/

Re: Continuations

2002-11-18 Thread Luke Palmer
Date: Tue, 19 Nov 2002 14:29:46 +1100 From: Damian Conway [EMAIL PROTECTED] Ken Fox lamented: Or the circumfix ... operator. Which is the problem here. This is like playing poker with God. I hear God prefers dice. What does the circumfix ... operator do? It's the ASCII

Re: String concatentation operator

2002-11-17 Thread Luke Palmer
Date: Mon, 18 Nov 2002 07:39:55 +1100 From: Damian Conway [EMAIL PROTECTED] It would be *vastly* better thought integrate junctive calls with the standard threading behaviour. Of course, there will be a pragma or something to instruct it to operate serially, yes? Luke

Re: Continuations

2002-11-17 Thread Luke Palmer
Date: Mon, 18 Nov 2002 09:28:59 +1100 From: Damian Conway [EMAIL PROTECTED] I've a couple of questions here: we still have implicit iteration: for fibs() { print Now $_ rabbits\n; } Really? What if fibs() is a coroutine that returns lists (Fibonacci lists, no less),

Re: on the current summary

2002-11-16 Thread Luke Palmer
From: david nicol [EMAIL PROTECTED] Date: 15 Nov 2002 18:56:35 -0600 I don't know if you haven't been paying attention, or you're summarizing what's happened. I'll assume the former. Forgive me if I've misunderstood you. 1: string cat is an old and reliable horsehide drum. I've been

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; it was

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); hopefully

More junctions

2002-11-13 Thread Luke Palmer
When junctions collapse, is that reflected back in the original junction, as it should be (QM-wise)? $foo = 1 | 2 | 4 print $foo; # Foo is now just one of (1, 2, 4); i.e. not a junction If so, what is perl going to do about the computationally expensive entanglement thingy? $x =

Re: Unifying invocant and topic naming syntax

2002-11-13 Thread Luke Palmer
Date: Wed, 13 Nov 2002 20:34:49 + From: Nicholas Clark [EMAIL PROTECTED] 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?

Re: More junctions

2002-11-13 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm From: Deborah Ariel Pickett [EMAIL PROTECTED] Date: Thu, 14 Nov 2002 09:05:16 +1100 (EST) Cc: [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ Luke wrote: When junctions collapse, is that reflected back in

Re: Superpositions and laziness

2002-11-08 Thread Luke Palmer
Date: Fri, 8 Nov 2002 15:04:16 + From: Nicholas Clark [EMAIL PROTECTED] And to people in the perl5 know, Memoize is the module that implements this, hence why people who know of how and what Memoize can do favour that name. Except that it's not necessarily obvious to everyone else?

Re: Superpositions and laziness

2002-11-07 Thread Luke Palmer
Date: Thu, 07 Nov 2002 20:48:50 +1100 From: Damian Conway [EMAIL PROTECTED] we could make it lazy thus: sub a_pure_func(Num $n) is lazy returns Num { return $n ** $n } which would cause any invocation of Ca_pure_func to cache its arguments (probably in a closure)

Re: Superpositions and laziness

2002-11-07 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm From: Luke Palmer [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Date: Thu, 7 Nov 2002 13:49:14 -0700 (MST) X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ Date: Thu, 07 Nov 2002 20:48:50 +1100 From: Damian Conway [EMAIL

Re: Primitive Vs Object types

2002-11-07 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Thu, 7 Nov 2002 17:19:28 -0500 From: Mark J. Reed [EMAIL PROTECTED] Content-Disposition: inline X-Julian-Day: 2452586.42675 X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ [Recipients list trimmed back to just the list

Re: Keyword arguments

2002-11-06 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm From: Piers Cawley [EMAIL PROTECTED] Date: Wed, 06 Nov 2002 12:44:39 + X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ So, I was, thinking about the way Common Lisp handles keyword arguments. It's possible to declare a

Re: String - Numeric conversion

2002-11-06 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Wed, 6 Nov 2002 14:53:37 -0800 From: Michael Lazzaro [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ If anyone knows the answer to these two questions, I'd appreciate it. 1) What do these do?

Continuations

2002-11-05 Thread Luke Palmer
I just need a little clarification about yield(). consider this sub: sub iterate(foo) { yield for foo; undef; } (Where yield defaults to the topic) Presumably. a = (1, 2, 3, 4, 5); while($_ = iterate a) { print } Will print 12345. Or is that:

Re: What is the order of evaluation for separate streams in a loop?

2002-11-04 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Mon, 4 Nov 2002 12:09:12 -0800 (PST) From: Austin Hastings [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ Something from [EMAIL PROTECTED] about the relative frequency made

Re: [RFC] Perl Operator List, TAKE 6

2002-11-02 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Sat, 2 Nov 2002 01:15:05 +0200 From: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ Michael Lazzaro writes: magical whitespace modifier: _ - When used at the

Re: UTF-8 and Unicode FAQ, demos

2002-11-02 Thread Luke Palmer
From: Markus Laire [EMAIL PROTECTED] Date: Sat, 02 Nov 2002 14:44:39 +0200 On 2 Nov 2002 at 0:06, Simon Cozens wrote: More and more conversations like this, (and how many have we seen here already?) about characters sets, encodings, mail quoting issues, in fact, anything other than Perl,

Re: UTF-8 and Unicode FAQ, demos

2002-10-31 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Thu, 31 Oct 2002 10:11:00 -0800 From: Michael Lazzaro [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ And if you really want to drool at all the neat glyphs that the wonderful, magical world of math

Re: [RFC] Perl6 Operator List, Take 5

2002-10-31 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Thu, 31 Oct 2002 14:45:16 -0800 From: Erik Steven Harrison [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] X-Sent-Mail: off Reply-To: [EMAIL PROTECTED] X-Sender-Ip: 152.18.50.63 Organization: Angelfire

Re: [RFC] Perl6 HyperOperator List

2002-10-31 Thread Luke Palmer
Oops. About that op thing, I was wrong. Though there is a case that does it: sub bar(); sub postfix:bar($x) returns IO::Handle; $x = length bar; If it's possible to have a distinct sub and an operator with the same name. If not, I believe the distinction is precisely the same as

Re: [RFC] Perl6 HyperOperator List

2002-10-31 Thread Luke Palmer
Date: Thu, 31 Oct 2002 15:16:17 -0800 (PST) From: Austin Hastings [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED], [EMAIL PROTECTED] --- Luke Palmer [EMAIL PROTECTED] wrote: --- Damian Conway [EMAIL PROTECTED] wrote: Austin Hastings wrote: traits = any

Re: [RFC] Perl6 HyperOperator List

2002-10-31 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Fri, 1 Nov 2002 03:08:37 + From: Andrew Wilson [EMAIL PROTECTED] Mail-Followup-To: [EMAIL PROTECTED] [EMAIL PROTECTED] Content-Disposition: inline X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ On Fri, Nov 01,

Re: [RFC] Perl6 HyperOperator List

2002-10-31 Thread Luke Palmer
Larry wrote: I don't much care whether they short-circuit or not. I could argue it either way. I think it'd be okay if they short-circuit. Anybody who uses an operator like ? expecting it to force a side effect on the second expression is nuts. And there's something (though not much) to

Re: Persistance of superpositions?

2002-10-30 Thread Luke Palmer
Date: Tue, 29 Oct 2002 15:57:56 -0800 (PST) From: Larry Wall [EMAIL PROTECTED] That's not a problem with builtins, but what about sub foo (); sub prefix:foo ($x); @a = [foo][1,2,3,4,5]; So how is this interpreted? Such syntactic ambiguity isn't nice. Should we go with the

Re: Iterators [was: worth adding collections to the core language?]

2002-10-30 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Cc: [EMAIL PROTECTED] [EMAIL PROTECTED] From: Piers Cawley [EMAIL PROTECTED] Date: Wed, 30 Oct 2002 18:59:15 + X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ Dave Storrs [EMAIL PROTECTED] writes: In the Re:

Re: perl6 operator precedence table

2002-10-30 Thread Luke Palmer
Date: Thu, 31 Oct 2002 13:02:44 +1300 (NZDT) From: Martin D Kealey [EMAIL PROTECTED] We don't in general have a let on the front of assignment statements; why should this type of assignment be any different? (Do we want a let keyword? Personally I don't think so, but what do others think?)

Re: Wh[ie]ther Infix Superposition ops

2002-10-29 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm From: Piers Cawley [EMAIL PROTECTED] Date: Tue, 29 Oct 2002 05:45:01 + X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ Whilst I don't wish to get Medieval on your collective donkey I must say that I'm really not sure of

Re: Wh[ie]ther Infix Superposition ops

2002-10-29 Thread Luke Palmer
Cc: [EMAIL PROTECTED] From: Piers Cawley [EMAIL PROTECTED] Date: Tue, 29 Oct 2002 09:36:12 + Luke Palmer [EMAIL PROTECTED] writes: Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm From: Piers Cawley [EMAIL PROTECTED] Date: Tue, 29 Oct 2002 05:45:01 + X-SMTPD: qpsmtpd

Re: Perl6 Operator List, Damian's take

2002-10-29 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Tue, 29 Oct 2002 21:37:32 + From: Aaron Crane [EMAIL PROTECTED] Content-Disposition: inline X-SMTPD: qpsmtpd/0.12, http://develooper.com/code/qpsmtpd/ Damian Conway writes: My personal favorite solution is to use square

Re: XOR vs. Hyper (was Re: Perl6 Operator List)

2002-10-27 Thread Luke Palmer
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm Date: Sat, 26 Oct 2002 23:01:31 -0700 From: Michael Lazzaro [EMAIL PROTECTED] X-Accept-Language: en,pdf Cc: Damian Conway [EMAIL PROTECTED], [EMAIL PROTECTED] [EMAIL PROTECTED] X-SMTPD: qpsmtpd/0.12-dev,

Re: Perl6 Operator List

2002-10-26 Thread Luke Palmer
Date: Sat, 26 Oct 2002 09:16:41 -0700 (PDT) From: Larry Wall [EMAIL PROTECTED] We're also missing the actual C operators that are guaranteed to return 0 or 1: $x ? $y # C's $x $y $x ?| $y # C's $x || $y $x ?! $y # C's, er, !!$x ^ !!$y And we need those... why? Wouldn't:

Re: Perl6 Operator List

2002-10-26 Thread Luke Palmer
You know, \ and friends as xor is appealing to me. There's no problem with \\ or \=, so that works. It's got nothing to do with references, but unary | has nothing to do with anything. Plus, it's parallel (er, perpendicular) to // as err, being logical and all. Just to clarify: \

Re: perl6 operator precedence table

2002-10-24 Thread Luke Palmer
From: Angel Faus [EMAIL PROTECTED] Date: Fri, 25 Oct 2002 00:54:09 +0200 All this ones fit more with the concept of mystical analogy hinted by =~ than with the plain similarity that one would expect from like True. Can't say I like, um, like. Oh, and =~ looks much more intimidating,

Re: perl6 operator precedence table

2002-10-23 Thread Luke Palmer
Date: Wed, 23 Oct 2002 11:14:33 -0700 (PDT) From: Larry Wall [EMAIL PROTECTED] On top of which, Damian has expressed an interest in ! for a superpositional xor. Which would behave how, exactly? Luke

Re: [OT] Power of Lisp macros?

2002-10-23 Thread Luke Palmer
Date: Wed, 23 Oct 2002 18:43:08 -0300 From: Adriano Nagelschmidt Rodrigues [EMAIL PROTECTED] Hi, Perl is my favorite language, and I'm eagerly following Perl 6 development. So I would like to ask this question here. Sorry if I'm being inconvenient... Do you think that Lisp macros make

Re: Character Properties

2002-10-21 Thread Luke Palmer
I didn't call the problem unreasonable, I was objecting to its characterization as an essential feature. It isn't. A useful thing, definitely, but there are a lot of those. It's hardly essential any more than, say, a hash that automagically maps to the current directory's files

Re: A concept for Exceptions

2002-10-15 Thread Luke Palmer
From: [EMAIL PROTECTED] [EMAIL PROTECTED] Date: Tue, 15 Oct 2002 14:33:28 -0400 I like the idea of this. The finer details, like returning what to do, could be more elegant. But the extensibility idea is golden. To change how certain exceptions behave, a block simply changes the methods

Re: Indeterminate math

2002-10-15 Thread Luke Palmer
Put another way, is there a significant difference between: eval { $foo = 1/0; print Bar; } if( $ =~ /^Illegal division by zero/ ) { ... oops ... } and try { $foo = 1/0; print Bar; } catch { when /^Illegal

Re: Private contracts?

2002-10-13 Thread Luke Palmer
Date: Sat, 12 Oct 2002 08:43:46 -0700 (PDT) From: Larry Wall [EMAIL PROTECTED] If we use | and as sugar for any() and all(), then their precedence should probably be the same as || and . Should they? I had in mind something just above comparisons. That way: if $x == 3 || $y ==

Re: perl6 operator precedence table

2002-10-13 Thread Luke Palmer
Date: Fri, 11 Oct 2002 12:16:00 -0700 (PDT) From: Larry Wall [EMAIL PROTECTED] I'm wondering whether the single ones could indicate parallel streams. We had the difficulty of specifying whether the Cfor loop should terminate on the shorter or the longer stream. We could say that |

Re: Private contracts?

2002-10-12 Thread Luke Palmer
sub f(int $a is constrained($a=1,must be positive), documented(an integer)) { ... } I now realize I'm a little fuzzy on the yada-yada-yada operator. What exactly is it... or what does it do? Is it a statement, an expression? Could you say

Re: RFC: [] as the solitary list constructor

2002-10-06 Thread Luke Palmer
Do parens still provide list context on the left side of an assignment? What do these two do: my $x = ARGS; my ($y) = ARGS; Parens just grouping suggests that C$x and C$y should be the same (which may well be good, as it's a subtle distinction which trips up many beginners in Perl

exegesis 5 question: matching negative, multi-byte strings

2002-10-01 Thread Luke Palmer
[Negative matching] a generic negative, multi-byte string matching mechanism. Any thoughts? Am I missing something already present or otherwise obvious? Maybe I'm misundertanding the question, but I think you want negative lookahead: Perl 5: /(.*)(?!union)/ Perl 6: /(.*) !before:

Re: Regex query

2002-09-23 Thread Luke Palmer
On 23 Sep 2002, Simon Cozens wrote: [EMAIL PROTECTED] (Luke Palmer) writes: Since we now have an explicit flattening operator (unary *), there's no need to differentiate between a real list and a reference to one. What context does push impute on its operands? If push

Re: Paren madness (was Re: Regex query)

2002-09-23 Thread Luke Palmer
On Mon, 23 Sep 2002, Jonathan Scott Duff wrote: On Mon, Sep 23, 2002 at 04:58:55PM -0400, Trey Harris wrote: for (1,(a,b,c),3 { ... } and for 1,(a,b,c),3 { ... } Now that I've ventured away from DWIMs and more into WIHDTEMs (What In Hell Does This Expression Mean), is the

Re: Regex query

2002-09-23 Thread Luke Palmer
On 24 Sep 2002, Simon Cozens wrote: [EMAIL PROTECTED] (Luke Palmer) writes: push @a: [1,2,3,4]; pushes an array ref onto @a. push @a: *[1,2,3,4]; pushes 1, 2, 3, and 4 onto @a (as it would without the * and []). Remind me which language this is supposed to be, again

Re: Passing arguments

2002-09-21 Thread Luke Palmer
On 21 Sep 2002, Smylers wrote: Larry Wall wrote: On 20 Sep 2002, Aaron Sherman wrote: : Does that mean that I can't : : for $x - $_ { : for $y - $z { : print $_, $z\n; : } : } : : And expect to get different

Re: Regex query

2002-09-21 Thread Luke Palmer
On 21 Sep 2002, Smylers wrote: Luke Palmer wrote: my v = $( func() ); Would provide scalar context. But then assign it to a list... In the course of reading that I developed a concern about memory usage when trying to find the size of arrays. As I understand it the Perl 5

Re: Regex query

2002-09-21 Thread Luke Palmer
On Sun, 22 Sep 2002, Markus Laire wrote: On Sat, Sep 21, 2002 at 11:36:49AM -0600, John Williams wrote: On Sat, 21 Sep 2002, Jonathan Scott Duff wrote: Anyway, (7) or (3+4) should yield a number, not a list, because otherwise every math expression will break. Why can't perl

Re: Regex query

2002-09-20 Thread Luke Palmer
I was just thinking that $((1,2,3)) is also the same as [1,2,3], and shorter than scalar(1,2,3). I wonder if you can't just use $(1, 2, 3) to the same effect. I think you can. I was under the impression that the C comma was dying, so that would have to make a list or err. Also, I

Re: Regex query

2002-09-20 Thread Luke Palmer
On Fri, 20 Sep 2002, Chip Salzenberg wrote: According to Luke Palmer: I think to get Perl5 behavioueaur :), you do this: my flatL = ( *(1a, 2a), *(1b, 2b) ); Geez, I hope not, because that would imply that in my v = ( func() ); that func is called in a scalar context

Re: hotplug regexes, other misc regex questions

2002-09-18 Thread Luke Palmer
On Wed, 18 Sep 2002, Josh Jore wrote: On Wed, 18 Sep 2002, Damian Conway wrote: Would it be correct for this to print 0? Would it be correct for this to print 2? my $n = 0; aargh =~ /a* { $n++ } aargh/; print $n; Yes. ;-) Wouldn't that print 2 if $n is lexical

Re: Blocks and semicolons

2002-09-12 Thread Luke Palmer
On Thu, 12 Sep 2002, Ken Fox wrote: Luke Palmer wrote: This requires infinite lookahead to parse. Nobody likes infinite lookahead grammars. Perl already needs infinite lookahead. Anyways, most people don't care whether a grammar is ambiguous or not -- if we did, natural human

Re: Blocks and semicolons

2002-09-12 Thread Luke Palmer
BTW, there are some parser generators that handle ambiguous grammars -- they either support backtracking, infinite lookahead, or simultaneously parse all possible derivations. In the case of the simultaneous parse, they can actually return multiple parse trees and let the code generator

Re: Blocks and semicolons

2002-09-11 Thread Luke Palmer
This is for everyone: EOA4 In Perl, this problem comes up most often when people say Why do I have to put a semicolon after do {} or eval {} when it looks like a complete statement? Well, in Perl 6, you don't, if the final curly is on a line by itself. That is, if you

Re: Blocks and semicolons

2002-09-11 Thread Luke Palmer
Luke Palmer wrote: [quote from A4] To me, this looks like it has answers to all these questions. Up to a point. Look at the discussion of given/when in the same Apocalypse. Here's some example code from A4: given $! { when Error::Overflow { ... } when Error

Re: Throwing lexicals

2002-09-09 Thread Luke Palmer
Going back to patterns, this gives us an added bonus. It not only explains the behavior of hypotheticals, but also of subexpression placeholders, which are created when the pattern returns: $self but lexicals(0=$self, 1= $self.{1}, 2= $self.{2}, etc...) That yields the side

Re: Throwing lexicals

2002-09-09 Thread Luke Palmer
On Mon, 9 Sep 2002, Andrew Wilson wrote: On Mon, Sep 09, 2002 at 02:14:25PM -0500, Me wrote: Hence the introduction of let: m/ { let $date := date } / which makes (a symbol table like entry for) $date available somewhere via the match object. Somewhere? where it appears in

Re: Suggestion for perl 6 regex syntax

2002-09-07 Thread Luke Palmer
On Fri, 6 Sep 2002, Mr. Nobody wrote: While Apocolypse 5 raises some good points about problems with the old regex syntax, its new syntax is actually worse than in perl 5. Most regexes, such as this one to match a C float /^([+-]?)(?=\d|\.\d)\d*(\.\d*)?([Ee]([+-]?\d+))?$/ would actually

Re: More A5/E5 questions

2002-09-06 Thread Luke Palmer
Answering to the best of my knowledge. On Sat, 7 Sep 2002, Jonathan Scott Duff wrote: Question #2: Why are we storing the hypothetical's sigil in the match object? I think it's to differentiate the different namespaces (scalar, array, hash) within the match object's hash. Personally, I

RE: First crack at Builtins.p6m

2002-09-05 Thread Luke Palmer
On 5 Sep 2002, Aaron Sherman wrote: On Thu, 2002-09-05 at 01:47, Brent Dax wrote: Aaron Sherman: The one thing I notice all over the place is: sub abs($num is int){ return $num=0 ?? $num :: -$num } Another thing I'm not sure on... how do you force numeric, but not integer

Re: User-defined character classes and repeat counts

2002-09-04 Thread Luke Palmer
Aaron Sherman wrote: So, for example here are some translations of existing operators: + ={.count 0} * ={1} *?={1}? 8 ={.count == 8}# No optimization possible! Could it be done this way?: c:=(.)* ( c == 8 ) Surely inefficient, but it works

Re: @array = %hash

2002-09-03 Thread Luke Palmer
Hmm... I think I'd rather see my $foo is Bag = array.as('Bag'); The idea being that one could treat hashes and arrays as syntactic vitamins meaning 'Dictionary' (to use the Smalltalk term) and 'OrderedCollection', but all Collections would implement an Cas method allowing conversion

RE: atomicness and \n

2002-09-03 Thread Luke Palmer
On Tue, 3 Sep 2002, Brent Dax wrote: Damian Conway: # Neither. You need: # # $roundor7 = rx /roundascii+[17]/ # # That is: the union of the two character classes. How can you be sure that roundascii is implemented as a character class, as opposed to (say) an alternation?

Re: Hypothetical synonyms

2002-08-29 Thread Luke Palmer
The ° character doesn't have any special meaning, that's why I choosed it in the above example. However, it also symbolizes a little capturing and as it isn't filled, it could really symbolize an uncapturing. Interesting idea. I'm not sure if I agree with it yet. However, I don't agree

Re: need help on perl scripts #1 newuser.pl

2002-08-28 Thread Luke Palmer
This is really the wrong place to be sending this. This is Perl 5 (or maybe even Perl 4, which I don't know) code, and this is a list for discussing the design of Perl 6. A good place to send this would probably be [EMAIL PROTECTED] Good Luck, Luke On Wed, 28 Aug 2002, frank crowley

Re: Hypothetical synonyms

2002-08-28 Thread Luke Palmer
On Thu, 29 Aug 2002, Steffen Mueller wrote: Nicholas Clark wrote: On Thu, Aug 29, 2002 at 12:00:55AM +0300, Markus Laire wrote: And I'm definitely going to try any future PerlGolf challenges also in perl6. Is it considered better if perl6 use more characters than perl5? (ie implying

Re: rule, rx and sub

2002-08-28 Thread Luke Palmer
Second, is there a prototype-way to specify the arguments to for (specifically, the first un-parentesized multidimensional array argument)? In other words, is that kind of signature expected to be used often enough to justify not forcing people to explicitly extend the grammar? If you're

Re: rule, rx and sub

2002-08-27 Thread Luke Palmer
On 27 Aug 2002, Piers Cawley wrote: Damian Conway [EMAIL PROTECTED] writes: Debbie Pickett asked: (Offtopic: can I say: $c = - $xyz { mumble } Yes. Though you need a semicolon at the end unless its the last statement in a block. Um... when did that rule come in? I thought a

Re: rule, rx and sub

2002-08-27 Thread Luke Palmer
On Tue, 27 Aug 2002, Sean O'Rourke wrote: On Tue, 27 Aug 2002, Luke Palmer wrote: On 27 Aug 2002, Piers Cawley wrote: Damian Conway [EMAIL PROTECTED] writes: Debbie Pickett asked: (Offtopic: can I say: $c = - $xyz { mumble } Yes. Though you need a semicolon

Re: rule, rx and sub

2002-08-26 Thread Luke Palmer
The only extra piece of syntactic sugar that Crx is giving us over Crule[*] is the ability to have arbitrary delimiters. Not quite arbitrary. Alphanumerics aren't allowed, nor are colon or parens. Aww, no alphanumerics anymore. That's too bad; it was so nice in poetry to be able to

Re: rule, rx and sub

2002-08-25 Thread Luke Palmer
Funny you should mention that. This brings up something that I was afraid to mention before, lest it be regarded as too weird. There isn't any strong syntactic reason for subs to be delimited with just braces either.[*] Sure, there's a historical Perl precedent, and I'd probably be forced

<    4   5   6   7   8   9   10   >