Welcome to yet another Perl 6 Weekly that is on time.

Living in interesting times

Jonathan Worthington has taken the GLR (Great List Refactor) from the drawing board into actual development. The current state of prototype implementation is now being carried over into a rakudo branch “glr” (which does not build yet, as this is written). As Larry Wall put it:

hopefully this will be the most disruptive change between now and Christmas 🙂

Please note that when this branch is merged, it will most likely break a significant part of the ecosystem in most likely unforeseen ways. On the other hand, after this upheaval, Rakudo Perl 6 will be much faster on single cores, but even more so on multiple core systems. A very early unoptimized benchmark shows that doing a race on a map only adds about 4% overhead on a single core system, whereas using 4 cores results in more than twice as fast execution of the given code. So, “fasten da seatbelz”, it may be a bumpy ride until we get there (within the next weeks).

Index dies, with/orwith/without lives

Last week, the Index type was introduced. This week, it is already gone again. Instead, we now have a more powerful set of features, called “with”. I guess examples speak better than words:

with "foo".index("f") -> $pos { # $pos is 0 and defined say $pos; # so this is executed }

Larry Wall explains it in the design documents. Please note that at the moment of this writing, automatic topicalization does not work yet for scoped with/orwith/without. It does however if you use the statement modifier version:

.say with "foo".index("f"); # 0␤ .say with "foo".index("o"); # 1␤ .say with "foo".index("x"); # nothing said

To facilitate using with to return from a subroutine, you can now also call the return method on anything to return from the surrounding subroutine. This allows you to say:

sub a(Int $x) { .return with 2 * $x } # a(42) returns 84

The Future Of p6doc

smls opened an issue about the Roadmap for our language/docs. If you care about Perl 6 documentation, you should read and/or comment!

Work on Javascript backend restarted

Pawel Murias has started working on the Javascript backend again. More power to him (and the people who would like to help him with that!).

Quote Of The Week

I’m so glad we’re getting rid of refcounting in Perl 6. This is horrible 🙂

Progress Reports and Blog Posts

Some nice blog posts again this week:

Notable code changes

Stefan Seifert added a code method to the CallFrame class, so that you can introspect any CallFrame’s Code object (even the ones that do not have a &?BLOCK or &?ROUTINE defined in their scope)

added a method to the CallFrame class, so that you can introspect any CallFrame’s Code object (even the ones that do not have a &?BLOCK or &?ROUTINE defined in their scope) Elizabeth Mattijsen implemented indices , as mentioned by Larry Wall . .say for "foooo".indices("oo"); # 1␤3␤ It also allows for overlap using a named parameter: .say for "foooo".indices("oo",:overlap); # 1␤2␤3␤

implemented , as mentioned by . Prompted by a discussion about $?FILE, Elizabeth Mattijsen made it impossible to create variables and constants with the ? twigil in userland. So, if you have code like: my $?FOO = 42; # not allowed anymore my constant $?BAR = "bar"; # not allowed anymore it will now be broken. You should never have been able to do that anyway. And since a dynamic constant is an oxymoron, this will also not work: my constant $*HUH = "not constant"; # was an NYI before

Recent Additions To The Ecosystem

Electron renamed from Atom::Electron, by Ahmad M. Zawawi

HTML::Restrict by Steve Mynott