Jon Ericson writes:
Matthew Walton [EMAIL PROTECTED] writes:
James Mastros wrote:
Larry Wall wrote:
Well, yes, but sometimes the weights change over time, so it doesn't
hurt (much) to reevaluate occasionally. But in this case, I think I
still prefer to attach the exotic characters to
Luke Palmer skribis 2004-11-29 16:10 (-0700):
http://groups.google.com/groups?selm=20040420175551.GA16162%40wall.orgrnum=1clarify
It says that backticks won't be used at all in Perl 6. That's (the) one
key of the keyboard that we're leaving to user-definition.
It says that, but after
Juerd writes:
Luke Palmer skribis 2004-11-29 16:10 (-0700):
http://groups.google.com/groups?selm=20040420175551.GA16162%40wall.orgrnum=1clarify
It says that backticks won't be used at all in Perl 6. That's (the) one
key of the keyboard that we're leaving to user-definition.
Juerd writes:
Luke Palmer skribis 2004-11-29 16:10 (-0700):
It says that backticks won't be used at all in Perl 6.
It says that, but after saying Leaving aside the use of C`` as a
term And that use of backticks is what this subthread appears to
be about. As I interpret it,
Sean O'Rourke wrote:
I'm saying division is now defined such that when the numerator is
a hash(-ref), the result is the set of values associated with the
denominator. I've never tried to divide a hash or hashref by
something without it being a bug.
Right...in Perl 5.
In Perl 6, a hash in a
Since this horse came back to life, I'm going to give it a good thrashing, and
I've got goons to help me.
I've asked the Phoenix Perl Mongers for their take on the situation. I've posted
a _completely_ unbiased synopsis of the situation. Here are excerpts from the replies:
Tony's take:
Rename
On Fri, 16 Apr 2004 23:45:48 +0200, Juerd wrote:
Jonathan Scott Duff skribis 2004-04-16 15:51 (-0500):
Except that you've put things in this explanation that shouldn't be
there IMHO. The %varnamekey is a special case, but not of getting a
single item from a hash, rather it's a special case
Peter Haworth skribis 2004-04-20 14:56 (+0100):
I think %hashkey key key is best explained as %hash{ key key
key } with implicit curlies, not as an alternative to curlies.
In that case, why aren't you suggesting something more in line with that?
Here's what I'd like to see instead of your
Juerd writes:
Peter Haworth skribis 2004-04-20 14:56 (+0100):
I think %hashkey key key is best explained as %hash{ key key
key } with implicit curlies, not as an alternative to curlies.
In that case, why aren't you suggesting something more in line with that?
Here's what I'd like to
MiƩrcoles 14 Abril 2004 14:18, Juerd wrote:
I propose to use ` as a simple hash subscriptor, as an alternative
to {} and . It would only be useable for \w+ keys or perhaps
-?\w+. As with methods, a simple atomic (term exists only in
perlreftut, afaix, but I don't know another word to describe
Angel Faus skribis 2004-04-19 22:43 (+0200):
If we really need a ultra-huffman encoding for hash subscriptors, I
have always dreamt of being able to do:
%hash/key
$hashref/foo/bar/baz/quux
...
I'd hate to give up dividing slash. It's one of the few operators that I
sometimes type
[EMAIL PROTECTED] (Juerd) writes:
Angel Faus skribis 2004-04-19 22:43 (+0200):
If we really need a ultra-huffman encoding for hash subscriptors, I
have always dreamt of being able to do:
%hash/key
$hashref/foo/bar/baz/quux
...
I'd hate to give up dividing slash. It's one of the few
Sean O'Rourke skribis 2004-04-19 15:11 (-0700):
I'd hate to give up dividing slash. It's one of the few operators that I
sometimes type without whitespace. Simple because 1/10 is good enough
and 1 / 10 is very wide.
You can have both, though.
But not in a way that makes $foo/$bar divide
[EMAIL PROTECTED] (Juerd) writes:
Sean O'Rourke skribis 2004-04-19 15:11 (-0700):
I'd hate to give up dividing slash. It's one of the few operators that I
sometimes type without whitespace. Simple because 1/10 is good enough
and 1 / 10 is very wide.
You can have both, though.
But not in
On Mon, Apr 19, 2004 at 03:34:13PM -0700, Sean O'Rourke wrote:
in a '/' is a regex, anything otherwise is a hash slice.
I don't understand. Could you give some examples? Is this in the context
of bare /path/to/foo, even?
/foo/ # trailing slash -- so it's a regexp (m/foo/)
/foo\/bar/ #
Sean O'Rourke skribis 2004-04-19 15:34 (-0700):
I'm saying division is now defined such that when the numerator is
a hash(-ref), the result is the set of values associated with the
denominator. I've never tried to divide a hash or hashref by
something without it being a bug.
I understand
Juerd wrote:
Sean O'Rourke skribis 2004-04-15 8:55 (-0700):
I find that there are still plenty of contexts in which `` is nice and
security is irrelevant.
This is the second time in this thread that I read about security being
unimportant. I still don't know what to say about it, though I feel
John Williams skribis 2004-04-16 18:32 (-0600):
You didn't answer his question, which is less complicated?
Wasn't that a rhetociral question?
Juerd
In a message dated Fri, 16 Apr 2004, Juerd writes:
Except for the shocking number of closed-minded people on this list.
Stop it, stop it, STOP IT.
I'm not asking you to stop voicing your opinion about the discussion at
hand--that would be closed-minded, after all.
I'm asking you to stop
Folks, this discussion seems to be spinning. All the points, on both
sides, have been made and are being repeated with only slight
variation. We've all made our cases--why don't we drop the issue for
a while and let Larry ruminate? I think we can all agree that he will
give the idea a fair
Trey Harris skribis 2004-04-16 12:05 (-0700):
I'm asking you to stop interpreting disagreement as censorship, prejudice,
closed-mindedness, or whatever else. It's not.
I never did interpret disagreement as anything but disagreement, and
never said that I think everyone who disagrees is
Brent 'Dax' Royal-Gordon writes:
If the inside of a hash indexer consists entirely of \w characters, it
will be interpreted as the name of a hash key. If you want it to call a
subroutine instead, add a ~ stringifying operator to the beginning of
the call, or a pair of parentheses to the
Juerd wrote:
Brent 'Dax' Royal-Gordon skribis 2004-04-15 16:56 (-0700):
1. Allow %hashfoo to be typed as %hashfoo. There would be a
conflict with numeric less-than, but we can disambiguate with
whitespace if necessary. After all, we took the same solution with
curlies.
Curlies which, as
[EMAIL PROTECTED] (Juerd) writes:
I think it has to go because `pwd`, `hostname`, `wget -O - $url`
should not be easier than the purer Perl equivalents and because
``'s interpolation does more harm than good.
I have to disagree with you here. The Perl way is not always the Perl
way -- the
On Thu, Apr 15, 2004 at 12:27:12PM -0700, Scott Walters wrote:
* Rather than eliciting public comment on %hash`foo (and indeed %hashfoo)
the proposal is being rejected out of hand (incidentally, the mantra of the Java
community Process seems to be you don't need X, you've got Y, and it took
Brent 'Dax' Royal-Gordon skribis 2004-04-15 16:56 (-0700):
1. Allow %hashfoo to be typed as %hashfoo. There would be a
conflict with numeric less-than, but we can disambiguate with
whitespace if necessary. After all, we took the same solution with
curlies.
Curlies which, as said, I
Austin Hastings skribis 2004-04-15 19:37 (-0400):
I'm sure that if Juerd or someone were to write a PublicHash class,
they would cleverly reverse the access so that some collision-unlikely
path would get the methods.
I'm sure I have explained several times already why I think using the .
On 2004-04-15 at 19:39:25, Austin Hastings wrote:
Of course you used for buffers that were not powers of 2. Had they
been powers of 2, you would have used or ~. The fact that you
didn't use a power of 2 is pretty questionable. The dread Unix
wizards will no doubt have questions for you about
On 2004-04-16 at 00:25:51, Brent 'Dax' Royal-Gordon wrote:
Number of keystrokes isn't our only concern here. This is Perl, not
APL--we care about the size of the language and its intuitiveness too.
(Perhaps not much, but we do.)
In any case, Perl is far more typable than APL unless you have
On 2004-04-16 at 09:23:44, Mark J. Reed wrote:
On 2004-04-15 at 19:39:25, Austin Hastings wrote:
Of course you used for buffers that were not powers of 2. Had they
been powers of 2, you would have used or ~. The fact that you
didn't use a power of 2 is pretty questionable. The dread Unix
[EMAIL PROTECTED] (Mark J. Reed) writes:
The biggest use of modulus is in implementing hashes
Rather, one of the biggest uses. I don't have documentation to support
the claim that it is the biggest, and there are certainly others -
date arithmetic, astronomy etc.
I'll bet you the actual
On Apr 16, 2004, at 7:19 AM, Simon Cozens wrote:
I'll bet you the actual most *common* use of modulus is:
until ( my ($percent_done=done()) == 100 ) {
do_work();
print $percent_done,\n unless $percent_done % 10;
}
And I'll bet it's something like this:
for my $i
-Original Message-
From: Mark J. Reed [mailto:[EMAIL PROTECTED]
On 2004-04-15 at 19:39:25, Austin Hastings wrote:
Of course you used for buffers that were not powers of 2. Had they
been powers of 2, you would have used or ~. The fact that you
didn't use a power of 2 is pretty
-Original Message-
From: David Wheeler [mailto:[EMAIL PROTECTED]
On Apr 16, 2004, at 7:19 AM, Simon Cozens wrote:
I'll bet you the actual most *common* use of modulus is:
until ( my ($percent_done=done()) == 100 ) {
do_work();
print $percent_done,\n
On Fri, 2004-04-16 at 10:56, David Wheeler wrote:
On Apr 16, 2004, at 7:19 AM, Simon Cozens wrote:
I'll bet you the actual most *common* use of modulus is:
[...]
print $percent_done,\n unless $percent_done % 10;
And I'll bet it's something like this:
my $css_class = $i % 2 ?
On 2004-04-16 at 11:17:41, Austin Hastings wrote:
I'm totally willing to agree with you, Mark.
A) Do you code hashing algorithms so frequently that you need a special,
low-cost-of-access operator built in to the language to support it?
Nope. I'd be perfectly happy if the modulus operator
Mark J. Reed wrote:
Nope. I'd be perfectly happy if the modulus operator were spelled mod
instead of %, which has never struck me as particularly intuitive.
I always saw it as being a funny division sign. See the little slash in
there?
--
Brent Dax Royal-Gordon [EMAIL PROTECTED]
Perl and
-Original Message-
From: Mark J. Reed [mailto:[EMAIL PROTECTED]
Sent: Friday, 16 April, 2004 11:43 AM
To: [EMAIL PROTECTED]
Subject: Re: backticks
On 2004-04-16 at 11:17:41, Austin Hastings wrote:
I'm totally willing to agree with you, Mark.
A) Do you code hashing algorithms
On 2004-04-16 at 08:50:38, Brent 'Dax' Royal-Gordon wrote:
Mark J. Reed wrote:
Nope. I'd be perfectly happy if the modulus operator were spelled mod
instead of %, which has never struck me as particularly intuitive.
I always saw it as being a funny division sign. See the little slash in
On Apr 16, 2004, at 10:14 AM, Juerd wrote:
Even with the xx Inf? Why?
Oh, right, missed that. Sorry.
David
Juerd wrote:
Brent 'Dax' Royal-Gordon skribis 2004-04-16 0:25 (-0700):
I don't like %hash{'foo'} because it's ugly. I don't like %hashfoo
because it's ugly and adds syntax. I don't like %hash`foo because it's
ugly, adds syntax, and looks nothing like an indexing operator. (I'll
revisit this
Sean O'Rourke skribis 2004-04-15 8:55 (-0700):
[EMAIL PROTECTED] (Juerd) writes:
I think it has to go because `pwd`, `hostname`, `wget -O - $url`
should not be easier than the purer Perl equivalents and because
``'s interpolation does more harm than good.
I have to disagree with you here.
Brent 'Dax' Royal-Gordon skribis 2004-04-16 0:25 (-0700):
Number of keystrokes isn't our only concern here. This is Perl, not
APL--we care about the size of the language and its intuitiveness too.
(Perhaps not much, but we do.)
Not the only concern, but to me, it is as important as
David Wheeler skribis 2004-04-16 9:58 (-0700):
for @thingies, qw(blue yellow) xx Inf - $thingy, $class {
print qq[tr class=$classtd$thingy/td/tr\n;
}
I think that $class would be Cundef after the second record in
@thingies, unfortunately.
Even with the xx Inf? Why?
Juerd
Aaron Sherman skribis 2004-04-16 9:52 (-0400):
3. You proposed (late in the conversation) that both could co-exist, and
while that's true from a compiler point of view, it also leads to:
`stuff``stuff`stuff
Huh? No. That is a syntax error.
$a`a=$a`b~`a` # Try to tell your editor
David Wheeler skribis 2004-04-16 7:56 (-0700):
And I'll bet it's something like this:
for my $i (0..$#thingies) {
my $css_class = $i % 2 ? 'blue' : 'yellow';
print tr class=$css_classtd$thingies[$i]/td/tr\n;
}
Probably.
Can't we in Perl 6 just use something like this?
for
On Fri, Apr 16, 2004 at 10:44:47AM -0700, Brent 'Dax' Royal-Gordon wrote:
Regex aliases, threads, lexicals, junctions, and dwimmery make things a
*lot* easier to program. This syntactic sugar you're proposing doesn't.
But it *does* make an oft-used construct easier to type. That adds up
On Fri, Apr 16, 2004 at 07:12:44PM +0200, Juerd wrote:
Aaron Sherman skribis 2004-04-16 9:52 (-0400):
3. You proposed (late in the conversation) that both could co-exist, and
while that's true from a compiler point of view, it also leads to:
`stuff``stuff`stuff
Huh? No. That is a syntax
Larry Wall skribis 2004-04-16 11:50 (-0700):
On Fri, Apr 16, 2004 at 07:12:44PM +0200, Juerd wrote:
: Except for the shocking number of closed-minded people on this list.
You seem to be one of them. From my point of view, you've had your
ego plastered all over this proposal from the start,
Jonathan Scott Duff wrote:
On Fri, Apr 16, 2004 at 10:44:47AM -0700, Brent 'Dax' Royal-Gordon wrote:
Regex aliases, threads, lexicals, junctions, and dwimmery make things a
*lot* easier to program. This syntactic sugar you're proposing doesn't.
But it *does* make an oft-used construct easier
Brent 'Dax' Royal-Gordon skribis 2004-04-16 13:17 (-0700):
Clever definition of the colon operator, or creation of a
bareword-quoting operator, would allow you to use barewords anywhere
you wanted to.
Defining ` to be a bareword quoting operator would be only one step away
from what I
On Fri, 2004-04-16 at 12:35, Juerd wrote:
backticks encourage interpolation.
... and?
From the point of view of a Web developer who deals with (potentially)
hostile data, I see the problem (though the solution is smarter
tainting, not removing functionality). From the point of view of a
On Fri, Apr 16, 2004 at 01:17:10PM -0700, Brent 'Dax' Royal-Gordon wrote:
I don't claim that they won't be used often. I claim that the *best*
solution is to fix the syntax we already have, not add more. Failing
that, we should make sure that the syntax we add is as globally useful
as
On Fri, Apr 16, 2004 at 09:16:15PM +0200, Juerd wrote:
However, I could be guessing badly. It could be that someone who says
Perl 6 should not have a third syntax because there are already two
really has thought about it. We have many ways of saying foo() if not
$bar in Perl 5 and I use most
Jonathan Scott Duff skribis 2004-04-16 15:51 (-0500):
To get an item out of a hash, you can write %varname{key}.
You can also write %varnamekey if there aren't any spaces in
the key. Finally, if the key doesn't have any characters in it
except for letters, numbers and
On Fri, 16 Apr 2004, Juerd wrote:
Defining ` to be a bareword quoting operator would be only one step away
from what I suggested initially:
1. %hash`key
2. %array`5
3. :key`value
4. say `hello;
This would make it like now, but allowing only one bareword, and
only if it is simple
In a message dated Wed, 14 Apr 2004, David Storrs writes:
Actually, what I'd like to know is when it was decided that %hash{key}
meant %hash{key()}?? Was it in one of the Apocalypses?
Perhaps it wasn't spelled out, but the implication was certainly there.
Barewords are gone. Braces create a
Chris skribis 2004-04-14 17:07 (-0700):
Perhaps this is naive, but couldn't something like this be achieved in a
manner similar to how I just implemented it in Ruby? Surely Perl will have
similar capabilities to handle unknown methods.
As explained in [EMAIL PROTECTED], it's not a
question of
David Storrs skribis 2004-04-14 22:39 (-0700):
Very top row, one space right of the F12 key. Extremely awkward.
(This is a US keyboard on a Dell Inspiron 5100 laptop.)
That is inconvenient.
1) ` looks like it should be a bracketing operator
I think you means circumfix/balanced operator.
Aaron Sherman skribis 2004-04-14 16:40 (-0400):
From a source tree I work with (which I cannot divulge code from, but I
think statistics like this are fine):
$ find . -name \*.pl | wc -l
330
$ find . -name \*.pl -exec grep -hlE 'qx|`|`|readpipe' {} \; | wc -l
Aaron Sherman skribis 2004-04-15 14:29 (-0400):
On Wed, 2004-04-14 at 16:56, Juerd wrote:
How many of those backticks
Note, those weren't backticks, those were programs. There were 123
PROGRAMS that used backticks or equivalent syntax.
I said backticks, and I meant backticks. I'm not sure
Let me summerize my undestanding of this (if my bozo bit isn't already
irrevocably set):
* %hashfoo retains the features of P5 $hash{foo} but does nothing to counter the
damage of removal of barewords
* %hash`foo occupies an important nitch, trading features (slice, autovivication)
to optmize
On Thu, 2004-04-15 at 12:27, Scott Walters wrote:
Without commenting on the rest of the proposal, please allow me to clear
up one point:
* Rather than eliciting public comment on %hash`foo (and indeed %hashfoo)
the proposal is being rejected out of hand
This whole thread *is* public comment.
On Thu, Apr 15, 2004 at 12:27:12PM -0700, Scott Walters wrote:
Let me summerize my undestanding of this (if my bozo bit isn't already
irrevocably set):
* %hashfoo retains the features of P5 $hash{foo} but does nothing to
counter the damage of removal of barewords
Actually, %hashfoo will be like
It's you.
* My objection to the Java community process applies in _some_ _small_
part to the Perl community process. I present it as a negative ideal
with the implication that it should be avoided.
* My objection to it being rejected out of hand applies not to the Perl community
process
-Original Message-
From: Scott Walters [mailto:[EMAIL PROTECTED]
Sent: Thursday, 15 April, 2004 03:27 PM
To: [EMAIL PROTECTED] Juerd
Cc: [EMAIL PROTECTED]
Subject: Re: backticks
Let me summerize my undestanding of this (if my bozo bit isn't already
irrevocably set
On Thu, Apr 15, 2004 at 01:26:47PM -0700, Scott Walters wrote:
: So, my apologies to who anyone who feels unfairly or excessively criticized,
: except chromatic. There is no forgiveness for someone who seeks out irked people
: with the single goal of further irking them. Since chromatic is so
Scott * %hash`s is an example of a small thing that would be easy to implement
Scott in core but would be used constantly (if JavaScript is any indication,
Scott every few lines), giving a lot of bang for the buck
Not sure that JavaScript is relevant here, since the equivalent
syntax there, .,
If hypothetically we *are* going to have a simplfied constant-index hash
access syntax, is there any reason why we can't use a single quote (')
rather than backtick ('), akin to the Perl4-ish package separator,
ie %foo'bar rather than %foo`bar?
On the grounds that personally I hate the backtick
On 2004-04-15 at 16:49:28, Mark J. Reed wrote:
Not sure that JavaScript is relevant here, since the equivalent
syntax there, ., is the same as the method call syntax. But see my
proposal below.
Before the nit-pickers jump in, I was oversimplifying above. The
method call syntax in JavaScript
Mark J. Reed skribis 2004-04-15 16:49 (-0400):
If I might offer a modest counter-proposal - how about a fallback method
(the equivalent of Perl5's AUTOLOAD or Ruby's method_missing, however
that winds up being spelled in Perl6) that would return the value of the
key equal to the requested
Dave Mitchell skribis 2004-04-15 21:56 (+0100):
If hypothetically we *are* going to have a simplfied constant-index hash
access syntax, is there any reason why we can't use a single quote (')
rather than backtick ('), akin to the Perl4-ish package separator,
ie %foo'bar rather than %foo`bar?
On Thu, 2004-04-15 at 13:37, Larry Wall wrote:
Well, I, for one, think chromatic was right on the money.
No matter how right my thoughts might have been, my tone *was* rude and
that's not right. Apologies to Scott.
-- c
On Thu, Apr 15, 2004 at 11:45:27AM +0200, Juerd wrote:
David Storrs skribis 2004-04-14 22:39 (-0700):
Very top row, one space right of the F12 key. Extremely awkward.
(This is a US keyboard on a Dell Inspiron 5100 laptop.)
That is inconvenient.
Yup.
1) ` looks like it should be a
-Original Message-
From: Juerd [mailto:[EMAIL PROTECTED]
Sent: Thursday, 15 April, 2004 05:09 PM
To: Dave Mitchell
Cc: [EMAIL PROTECTED]
Subject: Re: backticks
Dave Mitchell skribis 2004-04-15 21:56 (+0100):
If hypothetically we *are* going to have a simplfied constant-index
Austin Hastings skribis 2004-04-15 18:09 (-0400):
If we're going to entertain alternatives, why not use % as the hash
subscriptor?
To borrow from another thread:
%foo%monday%food = 10;
%foo%monday%travel = 100;
%foo%tuesday%food = 10;
%foo%tuesday%travel = 150;
There is as far as I
-Original Message-
From: Matthijs van Duin [mailto:[EMAIL PROTECTED]
On Fri, Apr 16, 2004 at 12:14:08AM +0200, Juerd wrote:
%foo is a hash. When I see %foo%bar, it feels like that should be a hash
too. Besides that, $foo%bar looks funny and @[EMAIL PROTECTED] does so even more.
Austin Hastings skribis 2004-04-15 18:38 (-0400):
$foo % bar
% is 4 keys: space, shift, 5, space. Too much, IMHO.
Typability and readability are both VERY important.
Juerd
On Thu, Apr 15, 2004 at 06:38:34PM -0400, Austin Hastings wrote:
The use of % as a modulo operator is purely a legacy from 'C', where it was
a failure: in 'C', the only number you care about for modulus is some power
of 2, and you get those using bitwise-and anyway.
I disagree with this
-Original Message-
From: Juerd [mailto:[EMAIL PROTECTED]
Austin Hastings skribis 2004-04-15 18:38 (-0400):
$foo % bar
% is 4 keys: space, shift, 5, space. Too much, IMHO.
Typability and readability are both VERY important.
In that case, why not define a Class::Hash-like
Austin Hastings writes:
-Original Message-
From: Juerd [mailto:[EMAIL PROTECTED]
Austin Hastings skribis 2004-04-15 18:38 (-0400):
$foo % bar
% is 4 keys: space, shift, 5, space. Too much, IMHO.
Typability and readability are both VERY important.
In that case, why
-Original Message-
From: Luke Palmer [mailto:[EMAIL PROTECTED]
Austin Hastings writes:
From: Juerd [mailto:[EMAIL PROTECTED]
Austin Hastings skribis 2004-04-15 18:38 (-0400):
$foo % bar
% is 4 keys: space, shift, 5, space. Too much, IMHO.
Typability and
-Original Message-
From: Jonathan Scott Duff [mailto:[EMAIL PROTECTED]
On Thu, Apr 15, 2004 at 06:38:34PM -0400, Austin Hastings wrote:
The use of % as a modulo operator is purely a legacy from 'C',
where it was a failure: in 'C', the only number you care about
for modulus
Juerd wrote:
I think %hash`key makes sense. But I'd like to find out if more people
like this idea.
We already have two hash dereference syntaxes. That's arguably one too
many as it is. Let's fix the deficiencies in the syntax we have, rather
than adding even more syntax with even more
Austin Hastings writes:
If you think about it, what we really ought to do is train ourselves
to reverse the numbers row on our keyboards. If we're doing a good
job about avoiding magic numbers, then $ % ( ) are going
to be much more frequently used than 2 4 5 7 9 0, so why don't we
fix
On Wed, Apr 14, 2004 at 02:18:48PM +0200, Juerd wrote:
I propose to use ` as a simple hash subscriptor, as an alternative to {}
and . It would only be useable for \w+ keys or perhaps -?\w+. As
with methods, a simple atomic (term exists only in perlreftut, afaix,
but I don't know another word to
On Wed, Apr 14, 2004 at 12:07:18PM -0700, chromatic wrote:
On Wed, 2004-04-14 at 05:18, Juerd wrote:
I think %hash`key makes sense. But I'd like to find out if more people
like this idea.
How do you request a hash slice with backticks?
I think you wouldn't. For that the more verbose
chromatic skribis 2004-04-14 12:07 (-0700):
I think %hash`key makes sense. But I'd like to find out if more people
like this idea.
How do you request a hash slice with backticks?
You don't. There are %foofoo bar and %foo{'foo', 'bar'} already and
hash slices aren't used much at all.
The
On Wed, 2004-04-14 at 12:24, Juerd wrote:
chromatic skribis 2004-04-14 12:07 (-0700):
I think %hash`key makes sense. But I'd like to find out if more people
like this idea.
How do you request a hash slice with backticks?
You don't. There are %foofoo bar and %foo{'foo', 'bar'} already
On Wed, 14 Apr 2004, Juerd wrote:
I propose to use ` as a simple hash subscriptor, as an alternative to {}
and . It would only be useable for \w+ keys or perhaps -?\w+. As
with methods, a simple atomic (term exists only in perlreftut, afaix,
but I don't know another word to describe a simple
chromatic skribis 2004-04-14 12:32 (-0700):
That's exactly my objection to this idea. I think it goes too far to
make simple things simpler while making complex things impossible.
Absolutely false.
This is an addition to the already existing {}, which should stay.
%foo{ something } will still
John Williams skribis 2004-04-14 13:36 (-0600):
On Wed, 14 Apr 2004, Juerd wrote:
I propose to use ` as a simple hash subscriptor, as an alternative to {}
and . It would only be useable for \w+ keys or perhaps -?\w+.
As with methods, a simple atomic (term exists only in perlreftut,
afaix,
When I announced that I fixed a version of Perl6::Variables to do ,
crickets chirped. I dislike having to place a lot of matching quotes,
brackets, parenthesis, and braces in my code. You must stop and
visually inspect code to make sure it balances out and even then is a
common source of bug
Juerd wrote:
chromatic skribis 2004-04-14 12:32 (-0700):
That's exactly my objection to this idea. I think it goes too far to
make simple things simpler while making complex things impossible.
Absolutely false.
This is an addition to the already existing {}, which should stay.
%foo{
Scott Walters skribis 2004-04-14 13:12 (-0700):
Second, autovivication is impossible for the same reason. We can't tell
from parsing this lone expression whether baz should be converted to numbers
or strings automatically.
I want ` for hashes in the first place. Having it for arrays too would
On Wed, 2004-04-14 at 08:18, Juerd wrote:
Perl 5 has the qx// operator which does readpipe. I believe the function
for it was added later. (It doesn't handle a LIST as system does,
unfortunately.) qx// is also known as ``. Two backticks.
readpipe/qx/`` isn't used much. In all my @INC, only a
Matthew Walton skribis 2004-04-14 21:23 (+0100):
%foo$bar doesn't quite do the same as %foo{$bar}.
That's one method, really - being like {' '}, and really just
carrying on the very familiar idea of different kinds of quotes. Like '
and .
The thing works as if there is an implicit {}
Juerd == Juerd [EMAIL PROTECTED] writes:
Juerd readpipe/qx/`` isn't used much. In all my @INC, only a handful of uses
Juerd can be found. Most are in Debian's modules.
That's because they aren't particularly interesting in modules, but
in 10 line scripts, they show up quite frequently.
This
On Wed, Apr 14, 2004 at 01:56:35PM -0700, Randal L. Schwartz wrote:
That's because they aren't particularly interesting in modules, but
in 10 line scripts, they show up quite frequently.
This undermines the rest of your request.
No, actually, it doesn't. Juerd doesn't seem to like ``, but that
Randal L. Schwartz skribis 2004-04-14 13:56 (-0700):
Juerd == Juerd [EMAIL PROTECTED] writes:
Juerd readpipe/qx/`` isn't used much. In all my @INC, only a handful of uses
Juerd can be found. Most are in Debian's modules.
That's because they aren't particularly interesting in modules, but
in
1 - 100 of 111 matches
Mail list logo