Re: RFC 196 (v1) More direct syntax for hashes

[email protected] (Bart Lateur) Fri, 08 Sep 2000 11:14:31 +0200
Newsgroups perl.perl6.language.data
Organization MediaMind
Message-ID <[email protected]>
On Thu, 7 Sep 2000 20:56:47 -0400, Michael G Schwern wrote:

>> C<reset %hash> should reset the hash iterator, instead of calling
>> C<keys> or C<values> as is currently the case.
>
>Sounds good, except the name.  reset() already does something.
>Currently, reset() is for clearing large swaths of global variables (a
>dubious feature) and for reseting ?pattern? searches.  Two weird
>features crammed into one keyword.  Shoving a third in doesn't seem
>pleasent.
>
>Either think up a better keyword, or remove those two crufty features.

I don't see the conflict.

Old:
	reset STRING
	reset
New:
	reset HASH

It's not as if you would want to use a hash as a string (containing the
starting characters of the global variables).

But, IMO: resetting global variables by generalization should go. This
is an idea even far worse than symbolic references. And, the reason for
its existence is obsolete because of the existence of block-scoped
lexical variables.

The bare reset might just as well stay.

-- 
	Bart.