Re: Allowing '-' in identifiers: what's the motivation?

2008-08-21 Thread Peter Scott
On Tue, 19 Aug 2008 23:59:50 +0200, Aristotle Pagaltzis wrote: > That said, I really *really* like the idea of embedded dashes > in identifiers (not least because underscores offend my amateur > typophile self), but the idea of being able to embed other > operator-ish symbols in identifiers leaves

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-20 Thread Larry Wall
On Tue, Aug 19, 2008 at 11:59:50PM +0200, Aristotle Pagaltzis wrote: : * Peter Scott <[EMAIL PROTECTED]> [2008-08-13 19:20]: : > If we allow operator symbols in identifiers then the world : > will divide into those people who look at Perl 6 programs : > only through syntax-highlighting editors and

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-19 Thread Aristotle Pagaltzis
* Peter Scott <[EMAIL PROTECTED]> [2008-08-13 19:20]: > If we allow operator symbols in identifiers then the world > will divide into those people who look at Perl 6 programs > only through syntax-highlighting editors and don't know what > all the fuss is about naming a variable $e*trade since it i

RE: Allowing '-' in identifiers: what's the motivation?

2008-08-13 Thread Peter Scott
On Tue, 12 Aug 2008 10:03:03 +0200, Michael Mangelsdorf wrote: > I also tried to say that as special characters (not 7-bit ASCII) > like for hyper ops have already been admitted, the question of just how > far ($foo&bar) this admission should (be allowed to) is just around > the corner. Completely

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-13 Thread Larry Wall
On Mon, Aug 11, 2008 at 11:34:03AM -0600, Tom Christiansen wrote: : >I'm still somewhat ambivalent about this, myself. My previous : >experience with hyphens in identifiers is chiefly in languages that : >don't generally have algebraic expressions, e.g. LISP, XML, so it will : >take some getting u

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread Bob Rogers
From: TSa <[EMAIL PROTECTED]> Date: Tue, 12 Aug 2008 09:25:27 +0200 . . . What's so different in $foo-bar versus $foo*bar, $foo+bar or $foo/bar? The latter might e.g. indicate path variables. FWIW, one sees "hyphen substitution" like this only very rarely in Common Lisp code, desp

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread Brandon S. Allbery KF8NH
On 2008 Aug 12, at 20:39, Austin Hastings wrote: Actually, I proposed some years ago allowing "separable verbs" -- function/method/operator names with spaces in them, that could in fact bracket or intersperse themselves with other parameters. This would be a way of writing "if ... elsif ..

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread Austin Hastings
Actually, I proposed some years ago allowing "separable verbs" -- function/method/operator names with spaces in them, that could in fact bracket or intersperse themselves with other parameters. This would be a way of writing "if ... elsif ... else ..." for example. I wonder if whitespace in id

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread Darren Duncan
Mark J. Reed wrote: On Tue, Aug 12, 2008 at 4:03 AM, Michael Mangelsdorf <[EMAIL PROTECTED]> wrote: relaxed identifiers could become what programmers actually expect. Relaxing the rules is fine, but I would like to state for the record that I'd rather not ever see whitespace allowed in identif

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread Mark J. Reed
On Tue, Aug 12, 2008 at 4:03 AM, Michael Mangelsdorf <[EMAIL PROTECTED]> wrote: > relaxed identifiers could become what programmers actually expect. Relaxing the rules is fine, but I would like to state for the record that I'd rather not ever see whitespace allowed in identifiers. That's an Apples

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread John M. Dlugosz
Nicholas Clark nick-at-ccl4.org |Perl 6| wrote: Also, in Perl 6, constants aren't going to be bare words, because unlike Perl 5, they're not going to be implemented as subroutines. So that's another "obvious" thing that actually isn't going to matter here. A C in Perl 6 can be declared with or

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread Nicholas Clark
On Mon, Aug 11, 2008 at 09:07:33AM -0400, Mark J. Reed wrote: > I'm still somewhat ambivalent about this, myself. My previous > experience with hyphens in identifiers is chiefly in languages that > don't generally have algebraic expressions, e.g. LISP, XML, so it will > take some getting used to i

RE: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread Michael Mangelsdorf
be. Apologies, Thom, for being imprecise and seemingly antagonizing. Kindly, Michael -Original Message- From: TSa [mailto:[EMAIL PROTECTED] Sent: Dienstag, 12. August 2008 09:25 To: perl6-language@perl.org Subject: Re: Allowing '-' in identifiers: what's the motiva

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-12 Thread TSa
HaloO, Michael Mangelsdorf wrote: Actually I can even imagine allowing almost all chars in the middle of identifiers. Is this a trend we should extrapolate into the lifetime scope of the Perl 6 language? How far are we in this process, given Unicode guillemets for hyper ops? Is this supposed

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Aristotle Pagaltzis
* Michael Mangelsdorf <[EMAIL PROTECTED]> [2008-08-11 20:25]: > Unicode guillemets for hyper ops? Unicode? I don’t know about your ISO-8859-1, but mine has guillemets. :-) Regards, -- Aristotle Pagaltzis //

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Darren Duncan
Mark J. Reed wrote: On Mon, Aug 11, 2008 at 1:34 PM, Tom Christiansen <[EMAIL PROTECTED]> wrote: People use nonadic functions (nonary operators? where non = 0, not 9) without parens, and get themselves into trouble for it. I believe the word you're looking for is '"nullary". Alternately, the

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Bob Rogers
From: Austin Hastings <[EMAIL PROTECTED]> Date: Mon, 11 Aug 2008 10:02:06 -0500 That sounds cool. Did you do it at the editor level, or at the keyboard level? =Austin In Emacs; see rgr-c-electric-dash-mode in [1], or other similar solutions in [2]. That way, I can turn it on for

RE: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Michael Mangelsdorf
inal Message- From: TSa (Thomas Sandlaß) [mailto:[EMAIL PROTECTED] Sent: Montag, 11. August 2008 19:55 To: perl6-language@perl.org Subject: Re: Allowing '-' in identifiers: what's the motivation? On Monday, 11. August 2008 05:35:03 John M. Dlugosz wrote: > E.g. see <http://

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Mark J. Reed
On Mon, Aug 11, 2008 at 1:34 PM, Tom Christiansen <[EMAIL PROTECTED]> wrote: > People use nonadic functions (nonary operators? where non = 0, not 9) > without parens, and get themselves into trouble for it. I believe the word you're looking for is '"nullary". Such expressions were covered in John

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread TSa (Thomas Sandlaß)
On Monday, 11. August 2008 05:35:03 John M. Dlugosz wrote: > E.g. see : > > sub bar { > return 100; > } > sub foo { 50;} > sub foo-bar { >return rand(50); >} > if (foo - bar != foo-bar) { >print "Haha!\n"; > } Actually I can even imagine

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Tom Christiansen
>I'm still somewhat ambivalent about this, myself. My previous >experience with hyphens in identifiers is chiefly in languages that >don't generally have algebraic expressions, e.g. LISP, XML, so it will >take some getting used to in Perl. But at least in Perl's case the >subtraction conflict is

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Austin Hastings
That sounds cool. Did you do it at the editor level, or at the keyboard level? =Austin Bob Rogers wrote: From: "Mark J. Reed" <[EMAIL PROTECTED]> Date: Mon, 11 Aug 2008 09:07:33 -0400 I'm still somewhat ambivalent about this, myself. My previous experience with hyphens in identif

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Bob Rogers
From: "Mark J. Reed" <[EMAIL PROTECTED]> Date: Mon, 11 Aug 2008 09:07:33 -0400 I'm still somewhat ambivalent about this, myself. My previous experience with hyphens in identifiers is chiefly in languages that don't generally have algebraic expressions, e.g. LISP, XML, so it will

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Mark J. Reed
I'm still somewhat ambivalent about this, myself. My previous experience with hyphens in identifiers is chiefly in languages that don't generally have algebraic expressions, e.g. LISP, XML, so it will take some getting used to in Perl. But at least in Perl's case the subtraction conflict is mitig

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-11 Thread Aristotle Pagaltzis
* John M. Dlugosz <[EMAIL PROTECTED]> [2008-08-11 06:25]: > I do agree that it may be better for multi-word identifiers > than camel case or underscores, as seen in many other languages > that the great unwashed masses have never heard of. XML and the stack of related technologies also do this (in

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-10 Thread John M. Dlugosz
Austin Hastings Austin_Hastings-at-Yahoo.com |Perl 6| wrote: At a minimum, there are more multi-word identifiers than there are statements involving subtraction. Further, '-' is basic, while all of [_A-Z] are not. Ergo, a multi-word-identifier is easier to type than a multi_word_identifier or

Re: Allowing '-' in identifiers: what's the motivation?

2008-08-10 Thread Austin Hastings
At a minimum, there are more multi-word identifiers than there are statements involving subtraction. Further, '-' is basic, while all of [_A-Z] are not. Ergo, a multi-word-identifier is easier to type than a multi_word_identifier or a multiWordIdentifier. The older I get, the more I like Cob

Allowing '-' in identifiers: what's the motivation?

2008-08-10 Thread John M. Dlugosz
E.g. see : sub bar { return 100; } sub foo { 50;} sub foo-bar { return rand(50); } if (foo - bar != foo-bar) { print "Haha!\n"; }