Casey R. Tweten writes: > Leave length() the way it is now and, if one so desires, they may > override it on there own to use length for getting: Not that helpful a suggestion for beginners. They don't know how to override, or often even how to load a module. The point is not that there's already a way to do it, but that the existing way doesn't make sense. Scalar context makes sense in: if (@a) { ... } But you have to know the innards of context to understand why you do this to get the length of an array: $a = @b; All I'm doing is suggesting another way, one that makes more sense for beginners: $a = length @b; I think we're going to have to see prototypes extended to cope with functions like this, anyway. I'll mention this requirement in the next version of the RFC. Nat
- RFC 212 (v1) Make length(@array) work Perl6 RFC Librarian
- Re: RFC 212 (v1) Make length(@array) work Hildo Biersma
- Re: RFC 212 (v1) Make length(@array) work Bart Lateur
- Re: RFC 212 (v1) Make length(@array) work Nathan Torkington
- Re: RFC 212 (v1) Make length(@array) work Dave Storrs
- Re: RFC 212 (v1) Make length(@array) work Casey R. Tweten
- Re: RFC 212 (v1) Make length(@array) work Randal L. Schwartz
- Re: RFC 212 (v1) Make length(@array) work Nathan Torkington
- Re: RFC 212 (v1) Make length(@array) work Nathan Torkington
- Re: RFC 212 (v1) Make length(@array) work Casey R. Tweten
- Re: RFC 212 (v1) Make length(@array) ... Nathan Torkington
- Re: RFC 212 (v1) Make length(@ar... Nathan Wiger
- Re: RFC 212 (v1) Make length... Nathan Torkington
- Re: RFC 212 (v1) Make le... Tom Christiansen
- Re: RFC 212 (v1) Make length... Damian Conway
- Re: RFC 212 (v1) Make length(@ar... Casey R. Tweten
- Re: RFC 212 (v1) Make length... Nathan Torkington
- Re: RFC 212 (v1) Make le... Casey R. Tweten
- Re: RFC 212 (v1) Make le... Randal L. Schwartz
- Uninitialized value warn... Nathan Wiger
- Re: Uninitialized value ... Nathan Torkington