News for hackers. Stuff that matters.
Re:Differences Between Perl 5 and Perl 6 by rihegher on Wednesday October 07, 2015 @11:20AM (#10346528)
this is a typo error actually: Now: my $len = $string.length;

http://doc.perl6.org/type/Str#method_length

EDIT: I don't see any contact section on their page to let them know

Re:Differences Between Perl 5 and Perl 6 by nemo on Wednesday October 07, 2015 @11:51AM (#10346714)
length is gone. See:

http://design.perl6.org/S29.html#Obsolete_Functions

"length()

This word is banned in Perl 6. You must specify units. In practice, this probably means you want Str.chars(), although it could be Str.bytes(), or even something else. See S32-setting-library/String for details."

Re:Differences Between Perl 5 and Perl 6 by rcthompson on Wednesday October 07, 2015 @12:49PM (#10347110)
That's an interesting design decision, and I suppose it solves the Python problem of "I want to operate on any iterable, except for strings which are technically iterables but I want to treat them as atomic elements."

(Incidentally, does Python 3 have a solution to this problem?)

Re:Differences Between Perl 5 and Perl 6 by ksherlock on Wednesday October 07, 2015 @11:48AM (#10346696)
method length

Perl 6 does not have a length function. See chars or elems.

Re:Differences Between Perl 5 and Perl 6 by rihegher on Wednesday October 07, 2015 @03:07PM (#10348242)
Sorry about that, I've jumped a bit too fast on that one