On Mon, Sep 25, 2000 at 06:07:01AM -0700, Randal L. Schwartz wrote: > Bart> character it finds. Plus, in Perl 5, NO core function returns a hash. > Bart> None at all. > > It's not returning a hash. Precisely. There ain't no such thing as "hash context". It simply returns a list with an even number of elements. Now, when you put that into a hash, the Right Thing happens. And it isn't *that* slow; it uses a table, just like the ordinary way tr/a/b/ operates. That doesn't use a hash! Besides, you pay for what you get: if you want to use this, it'll do all the work for you at *perhaps* a slight speed expense. But it's sure faster than doing n different counts and assigns... -- "Contrariwise," continued Tweedledee, "if it was so, it might be, and if it were so, it would be; but as it isn't, it ain't. That's logic!" -- Lewis Carroll, "Through the Looking Glass"
- RFC 283 (v1) C<tr///> in array context should re... Perl6 RFC Librarian
- Re: RFC 283 (v1) C<tr///> in array context ... Bart Lateur
- RE: RFC 283 (v1) C<tr///> in array context ... Henrik Tougaard
- Re: RFC 283 (v1) C<tr///> in array cont... Bart Lateur
- Re: RFC 283 (v1) C<tr///> in array ... Randal L. Schwartz
- Re: RFC 283 (v1) C<tr///> in ar... Simon Cozens
- Re: RFC 283 (v1) C<tr///> in ar... Bart Lateur
- Re: RFC 283 (v1) C<tr///> ... Simon Cozens
- Re: RFC 283 (v1) C<tr///&... Bart Lateur
- Re: RFC 283 (v1) C<tr///> in array context ... Richard Proctor
- Re: RFC 283 (v1) C<tr///> in array cont... Simon Cozens
- Re: RFC 283 (v1) C<tr///> in array context ... Paris Sinclair
- Re: RFC 283 (v1) C<tr///> in array cont... Bennett Todd
- Re: RFC 283 (v1) C<tr///> in array context ... Russ Allbery
- Re: RFC 283 (v1) C<tr///> in array cont... Paris Sinclair
- Re: RFC 283 (v1) C<tr///> in array ... Russ Allbery