PART 3: Information on Changes Due to IO Grant Work

The IO grant work is at its wrap up. This note lists some of the last-minute changes to the plans delineated in earlier communications ([1], [2], [3]). Most of the listed items do not require any changes to users’ code.

  • We implemented IO::Path.sibling
  • The promised IO::Path.concat-with was instead added as the much shorter IO::Path.add. Due to large ecosystem usage, IO::Path.child was left as is for now. The secure version is already written and .child will be swapped to use it later on; possibly around 6.d time. This will allow more time for users to update to the .add routine, where the secureness isn’t needed.
  • &mkdir multi candidate that takes a list of directories has been removed. IO::Path.mkdir has been changed to return the invocant on success, to mirror the subroutine form’s behaviour
  • The changes to &symlink and &link affected IO::Path.symlink and IO::Path.link as well. The new order of arguments is $existing-thing.symlink: $the-new-thing-we're-creating (same for .link)
  • role IO was promised to be removed. Essentially it was, none of the types that did it do it anymore. However, the role was brought back, to be done by IO::Path and IO::Special. The role provides no methods, but when we’ll make our coercers type-check the results of the coercion, we’ll need IO::Path to be of type IO, or all of our shiny IO() coercers will explode. As IO::Special is meant to be a fake-IO::Path-lite, it does IO role as well.
  • Many of the IO routines were changed from taking Str arguments to taking IO() arguments (Str coerces to IO just fine, so no changes to code are needed on your part). When paths are given as IO::Paths, this avoids needless waste of cycles to convert the IO::Path to Str and then to IO::Path again. More importantly, since IO::Path.Str doesn’t consider $.CWD into account, this fixes all potential bugs where the IO::Path given as arg was created with $.CWD other than current $*CWD

Help and More Info

If you need help or more information, please join our IRC channel and ask there. You can also contact the person performing this work via Twitter @zoffix or by talking to user Zoffix in our dev IRC channel

Posted in Uncategorized | Comments Off on PART 3: Information on Changes Due to IO Grant Work

PART 2: Upgrade Information for Changes Due to IO Grant Work

We’re making more changes!

Do the core developers ever sleep? Nope! We keep making Perl 6 better 24/7!

Why?

Not more than 24 hours ago, you may have read Upgrade Information for Changes Due to IO Grant Work. All of that is still happening.

However, it turned out that I, (Zoffix), had an incomplete understanding of how changes in 6.d language will play along with 6.c stuff. My original assumption was we could remove or change existing methods, but that assumption was incorrect. Pretty much the only sane way to incompatibly change a method in an object in 6.d is to add a new method with a different name.

Since I rather us not have, e.g. .child and .child-but-secure, for the next decade, we have a bit of an in-flight course correction:

ORIGINAL PLAN was to minimize incompatibilities with existing 6.c language code; leave everything potentially-breaking for 6.d

NEW PLAN is to right away add everything that does NOT break 6.c-errata specification, into 6.c language; leave everything else for 6.d. Note that current 6.c-errata specification for IO is sparse (the reason IO grant is running in the first place), so there’s lots of wiggle room to make most of the changes in 6.c.

When?

I (Zoffix) still hope to cram all the changes into 2017.04 release. Whether that’s overly optimistic, given the time constraints… we’ll find out on April 17th. If anything doesn’t make it into 2017.04, all of it definitely will be in 2017.05.

What?

Along with the original list in first Upgrade Information Notice, the following changes may affect your code. I’m excluding any non-conflicting changes.

  • IO::Path.abspath is being made private. Use IO::Path.absolute instead; it provides the same functionality + lets you optionally provide a different CWD as well.
  • It was previously possible to use IO::Path.child to create unresolvable paths or paths that are not the children of the invocant’s path (e.g. .child: "../../"). This use now causes the method to fail instead, any time the path cannot be determined to be the child of the invocant. This means the path will be fully resolved and the method will fail if it can’t resolve it. For original functionality, use the newly-added .concat-with method
  • All IO routines now throw typed exception instead of X::AdHoc
  • We’re adding a generic version of IO::ArgFiles called IO::CatHandle (name still subject to bikeshedding) which is IO::Handle. The IO::ArgFiles class will be kept for compatibility, but it’ll be just an empty class that is IO::CatHandle. Note that this may modify what methods are available in IO::ArgFiles, however existing methods that aren’t horribly broken should not be affected.
  • This likely does not affect any code, but FYI IO::Path‘s methods lines, words, split, and comb previously captured most args and sent them all to IO::Handle.open. Now, only the arguments that make sense in read-only non-binary mode, namely :$chomp, :$enc, and $nl-in, will be forwarded. The rest will be ignored.

Potential changes:

  • Currently IO::Path.is-absolute on Windows returns True if the path starts with a [back]slash (without any drive letters). There’s some chance this is to be changed to return False instead. This is the only change in direct conflict with 6.c language specification, which is why the current behaviour might be kept unchanged, unless it’s deemed incorrect.

Changes for 6.d language:

  • IO::Handle and IO::Pipe‘s .slurp-rest method is being renamed to just .slurp, which will be added in 6.c language. In 6.d language, .slurp-rest will be deprecated, to be removed in later language versions.
  • IO::Path.chdir will be deprecated in 6.d language, to be removed in later language versions. It’s a misnomer, as it doesn’t change any dirs. It merely creates a new path. Its behaviour can be replaced with one or more of .new, .concat-with, .d, .r, .w, and .x methods. Note that this does NOT affect `&chdir` and `&*chdir` subroutines.
  • There’s some chance IO::Spec::* classes will be deprecated in 6.d, to be removed in a later language version, because they’re internal-ish. We’ll first have a trial run with the proposed changes implemented in a module (to be named FastIO). If the module offers a lot of benefits, there will be a discussion on how to make it the default implementation for core IO.

Help and More Info

If you need help or more information, please join our IRC channel and ask there. You can also contact the person performing this work via Twitter @zoffix or by talking to user Zoffix in our dev IRC channel

Posted in notices | Comments Off on PART 2: Upgrade Information for Changes Due to IO Grant Work

Upgrade Information for Changes Due to IO Grant Work

As previously notified, there are changes being made to IO routines. This notice is to provide details on changes that may affect currently-existing code.

When?

Barring unforeseen delays, the work affecting version 6.c language is planned to be included in 2017.04 Rakudo Compiler release (planned for release on April 17, 2017) on which next Rakudo Star release will be based.

Some or all of the work affecting 6.d language may also be included in that release and will be available if the user uses use v6.d.PREVIEW pragma. Any 6.d work that doesn’t make it into 2017.04 release, will be included in 2017.05 release.

If you use development commits of the compiler (e.g. rakudobrew), you will
receive this work as-it-happens.

Why?

If you only used documented features, the likelihood of you needing to change any of your code is low. The 6.c language changes due to IO Grant work affect either routines that are rarely used or undocumented routines that might have been used by users assuming they were part of the language.

What?

This notice describes only changes affecting existing code and only for 6.c language. It does NOT include any non-conflicting changes or changes slated for 6.d language. If you’re interested in the full list of changes, you can find it in the IO Grant Action Plan

The changes that may affect existing code are:

  • role IO together with its IO.umask method have been removed without any replacement
  • Methods .watch, .chmod, .IO, .e, .d, .f, .s, .l, .r, .w, .x, .modified, .accessed, .changed, and .mode have been removed from IO::Handle. You can call these on the path returned by IO::Handle.path method to obtain the same behaviour
  • :test parameter on &chdir, IO::Path.chdir, and &indir routines have been changed to issue a deprecation warning and will be removed in 6.d language. In addition, the default test performed by these routines has been changed to be only a test for whether the path is a directory. To upgrade your code for this change, simply use named parameters for the test. e.g replace chdir :test<r w x> … with chdir :r, :w, :x …
  • binary mode in IO::Handle.Supply is now controlled by whether the handle
    is in binary mode (e.g. opened with .open(:bin …)). The :bin argument to .Supply is now ignored.
  • In 2017.03 release, IO::Path.lines was made non-lazy (slurps the whole file). This has now been reverted. To ensure the filehandle gets closed, you need to exhaust the returned Seq (simply iterate through it; eager it explicitly or implicitly (e.g. by assigning to array); or call .sink on it)
  • The order of arguments to &link and &symlink has been reversed. It now follows $existing-thing, $thing-we-are-creating pattern adhered to by ln command line tool as well as &move, &copy and &rename routines
  • IO::Handle.lock no longer takes an Int:D argument, but a pair of named arguments instead. By default, it makes an exclusive, blocking lock. Use :shared named argument to make a shared lock instead and :non-blocking to make the method fail instead of waiting for lock.
  • IO::Path.new-from-absolute-path is now a private method. Use .IO coercer or IO::Path.new: $the-path instead
  • &homedir has been removed. Use $*HOME dynamic variable directly.
  • &tempdir has been removed. Use $*TMPDIR dynamic variable directly.
  • IO routines that used to throw will now fail instead.

Help and More Info

If you need help or more information, please join our IRC channel and ask there. You can also contact the person performing this work via Twitter @zoffix or by talking to user Zoffix in our dev IRC channel

Posted in notices | Comments Off on Upgrade Information for Changes Due to IO Grant Work

Upgrade Information for Lexical require

Upgrade Information for Lexical require

What’s Happening?

Rakudo Compiler release 2017.03 includes the final piece of lexical module loading work: lexical require. This work was first announced in December, in http://rakudo.org/2016/12/17/lexical-module-loading/

There are two changes that may impact your code:

  • require now imports symbols lexically. If you require inside a block, the symbols won’t be available outside of it.
  • Compile-time require installs a placeholder package symbol that remains available even if required item was not found.

Upgrade Information

Lexical Symbols

WRONG:

# WRONG:
try { require Foo; 1 } and ::('Foo').new;

The require above is inside a block and so its symbols won’t be available
outside of it and the look up will fail.

CHANGE TO:

(try require Foo) !=== Nil and ::('Foo').new;

Now the require installs the symbols into scope that’s lexically accessible
to the ::('Foo') look up.

Optional Loading

WRONG:

# WRONG:
try require Foo;
if ::('Foo') ~~ Failure {
    say "Failed to load Foo!";
}

This construct installs a package named Foo, which would be replaced by the
loaded Foo if it were found, but if it weren’t, the package will remain a
package, not a Failure, and so the above ~~ test will always be False.

CHANGE TO:

# Use return value to test whether loading succeeded:
(try require Foo) === Nil and say "Failed to load Foo!";

# Or use a run-time symbol lookup with require, to avoid compile-time
# package installation:
try require ::('Foo');
if ::('Foo') ~~ Failure {
    say "Failed to load Foo!";
}

In the first example above, we test the return value of try isn’t Nil, since
on successful loading it will be a Foo module, class, or package.

The second example uses a run-time symbol lookup in require and so it never needs
to install the package placeholder during the compile time. Therefore, the
::('Foo') ~~ test does work as intended.

Help and More Info

If you require help or more information, please join our chat channel
#perl6 on irc.freenode.net

Posted in notices | Comments Off on Upgrade Information for Lexical require

Advance Notice of Significant Changes

Advance Notice of Significant Changes

As part of the IO grant run by The Perl Foundation, we’re improving our IO-related methods and subroutines. We’ve identified several of the changes that will have moderate
impact on the users and may require you to update your code.

The exact changes to be made will be known by March 18th, 2017 and the
implementation will be part of the 2017.04 Rakudo compiler release on April,
15th, which will be followed by the 2017.04 Rakudo Star Perl 6 release.

Details

Why Are We Changing Stuff?

Our contract with the users is we don’t change anything that’s covered
by the Perl 6.c language version tests. This means most of the language
remains reliably stable, but IO features got short-changed on the love. The
tests for them are sparse—a big reason why the IO grant is running in the
first place—which gives core developers a lot of freedom to change them
and to improve them.

Despite that freedom, we realize broken code isn’t a nice thing, and will
attempt to reduce the impact of the changes, by providing backwards compatible
interface to support old API, where feasible. Where not, we will provide
information of the upcoming changes; this notice is a part of that effort.

What’s Changing?

The grant covers all of IO routines and methods (excluding sockets). All of the
final changes are yet to be deliberated and ratified and we’ll share the
details once they’re known.

Currently, it is speculated that link() routine will change the order
of arguments (no backwards compatible support will be provided) and seek()
routine will take seek reference as a named argument instead of an enum value
(backwards compatible support will be provided).

It’s very likely many more changes will be made. We’ll be using the code of
all the modules in the ecosystem to judge the potential impact of the change
and evaluate each change on a case-by-case basis.

Timeline

  • March 18, 2017: finalized information on the changes will be known to the
    Core Team. Upgrade instructions for users will follow shortly after.
  • April 15, 2017: all of the changes will be completed and 2017.04
    compiler release will be made. Rakudo Star Perl 6 distribution will
    be created from this release in the following week or two.

Help and More Info

If you need help or more information, please join our IRC channel and ask there. You can also contact the person performing this work via Twitter @zoffix (Zoffix on IRC in #perl6-dev)

Posted in notices | Comments Off on Advance Notice of Significant Changes

Announce: Rakudo Star Release 2017.01

A useful and usable production distribution of Perl 6

On behalf of the Rakudo and Perl 6 development teams, I’m pleased to announce the January 2017 release of “Rakudo Star”, a useful and usable production distribution of Perl 6. The tarball for the January 2017 release is available from <http://rakudo.org/downloads/star/>.

Binaries for macOS and Windows (64 bit) are also available.

This is the sixth post-Christmas (production) release of Rakudo Star and implements Perl v6.c. It comes with support for the MoarVM backend (all module tests pass on supported platforms).

This is the first Rakudo Star release to include “zef” as module installer. “panda” is to be shortly replaced by “zef” and will be removed in the near future.

It’s hoped to produce quarterly Rakudo Star releases during 2017 with 2017.04 (April), 2017.07 (July) and 2017.10 (October) to follow.

Please note that this release of Rakudo Star is not fully functional with the JVM backend from the Rakudo compiler. Please use the MoarVM backend only.

In the Perl 6 world, we make a distinction between the language (“Perl 6”) and specific implementations of the language such as “Rakudo Perl”.

This Star release includes [release 2017.01] of the [Rakudo Perl 6 compiler], version 2017.01 of [MoarVM], plus various modules, documentation, and other resources collected from the Perl 6 community.

The Rakudo compiler changes since the last Rakudo Star release of 2016.11 are now listed in “2016.12.md” and “2017.01.md” under the “rakudo/docs/announce” directory of the source distribution.

Notable changes in modules shipped with Rakudo Star:

+ DBIish: Pg: TypeConverter post-merge cleanup
+ Linenoise: Remove dependency on Native::Resources
+ Pod-To-HTML: Bump version for #22 fix
+ Terminal-ANSIColor: Drop ‘nqp’ dependency
+ doc: Too many to list
+ json: Fix parsing of string literals with a leading combining character.
+ json\_fast: bump version since we now escape null bytes
+ panda: modified to warn of its removal in the short term
+ perl6-http-easy: Several pull requests merged
+ perl6-lwp-simple: Tweak tests to work with TAP::Harness
+ perl6-pod-to-bigpage: bump version
+ test-mock: Bump version.
+ zef: imported

There are some key features of Perl 6 that Rakudo Star does not yet handle appropriately, although they will appear in upcoming releases.
Some of the not-quite-there features include:

* advanced macros
* non-blocking I/O (in progress)
* some bits of Synopsis 9 and 11

There is an online resource at <http://perl6.org/compilers/features> that lists the known implemented and missing features of Rakudo’s backends and other Perl 6 implementations.

In many places we’ve tried to make Rakudo smart enough to inform the programmer that a given feature isn’t implemented, but there are many that we’ve missed. Bug reports about missing and broken features are welcomed at <rakudobug@perl.org>.

See <http://perl6.org/> for links to much more information about Perl 6, including documentation, example code, tutorials, presentations, reference materials, design documents, and other supporting resources. Some Perl 6 tutorials are available under the “docs” directory in the release tarball.

The development team thanks all of the contributors and sponsors for making Rakudo Star possible. If you would like to contribute, see <http://rakudo.org/how-to-help>, ask on the <perl6-compiler@perl.org> mailing list, or join us on IRC #perl6 on freenode.

Posted in Uncategorized | Comments Off on Announce: Rakudo Star Release 2017.01

Advance Notice: Lexical Module Loading Bug Fix

Please note that the NEXT (January 2017) release of the Rakudo Compiler will include a fix for a bug some may be relying on under the assumption of it being a feature. For details, please see the explanation below. If you have any further questions, please ask us on our irc.freenode.net/#perl6 IRC channel.

What

Perl 6 takes great care to avoid global state, i.e. whatever you do in your module, it should not affect other code. That’s why e.g. subroutine definitions are lexically (my) scoped by default. If you want others to see them, you need to explicitly make them our scoped or export them.

Classes are exported by default on the assumption that loading a module will not be of much use when you cannot access the classes it contains. This works as advertised with a small but important caveat. Those classes are not only visible in the computation unit that loads the module, but globally. This means that as soon as some code loads a module, those classes are immediately visible everywhere.

For example, given a module Foo:

unit class Foo;
use Bar;

And your own program:

use Foo;
my $foo = Foo.new; # works as expected
my $bar = Bar.new; # huh!? Where is Bar coming from?

Why

This doesn’t sound so bad (it at least saves you some typing), except for that it makes another feature of Perl 6 impossible to have: the ability to load multiple versions of a module at the same time in different parts of your program:

{
    use Baz:ver(v1);
    my $old-baz = Baz.new;
}
{
    use Baz:ver(v2);
    my $shiny-new-baz = Baz.new;
}

This will explode as on loading Baz:ver(v2), rakudo will complain about “Baz” already being defined.

What To Do

To fix this, we no longer register loaded classes globally but only in the scope which loaded them in the first place. Coming back to our first example, we would need to explicitly load Bar in the main program:

use Foo;
use Bar;
my $foo = Foo.new; # still works of course
my $bar = Bar.new; # now it's clear where Bar is coming from

So if you suddenly get an “Undeclared name: Bar” error message after upgrading to a newer Perl 6 compiler, you will most probably just need to add a: “use Bar;” to your code.

Posted in notices | Comments Off on Advance Notice: Lexical Module Loading Bug Fix

Announce: Rakudo Star Release 2016.11

On behalf of the Rakudo and Perl 6 development teams, I’m pleased to
announce the November 2016 release of “Rakudo Star”, a useful and usable
production distribution of Perl 6. The tarball for the November 2016 release
is available from http://rakudo.org/downloads/star/.

This is the fifth post-Christmas (production) release of Rakudo Star and
implements Perl v6.c. It comes with support for the MoarVM backend (all
module tests pass on supported platforms).

Please note that this release of Rakudo Star is not fully functional with
the JVM backend from the Rakudo compiler. Please use the MoarVM backend
only.

In the Perl 6 world, we make a distinction between the language (“Perl
6”) and specific implementations of the language such as “Rakudo Perl”.
This Star release includes release 2016.11 of the Rakudo Perl 6 compiler,
version 2016.11 of MoarVM, plus various modules, documentation, and
other resources collected from the Perl 6 community.

The changes in this release are outlined below:

New in 2016.11:

Fixes:
+ Various improvements to warning/error-reporting
+ Fixed assigning values to shaped arrays through iterators [839c762]
+ Fixed Str.Int not failing on numerics with combining characters [d540fc8]
+ [JVM] Fixed <a b c>.antipairs breakage [dd7b055]
+ defined routine now correctly authothreads with Junctions [189cb23]
+ Fixed poor randomness when .pick()ing on ranges with >32-bit numbers [34e515d]
+ Fixed infix:<x> silencing Failures [2dd0ddb]
+ Fixed edge case in is-approx that triggers DivByZero exception [f7770ed]
+ (Windows) Fixed returning of an error even when succeeding in mkdir [208a4c2]
+ (Windows) Fixed precomp unable to rename a newly compiled file [44a4c75]
+ (Test.pm) Fixed indent of multi-line diag() and test failure messages [43dbc96]
+ Fixed a callframe crash due to boxing of NULL filenames [200364a]
+ ∞ ≅ ∞ now gives True [4f3681b]
+ Fixed oversharing with grammars used by multiple threads [7a456ff]
+ Fixed incorrect calculations performed by acotan(num) [8e9fd0a]
+ Fixed incorrect calculations performed by asinh(num)/acosh(num) [a7e801f]
+ Fixed acosh return values for large negative numbers [5fe8cf7]
+ asinh(-∞) now returns -∞ instead of NaN [74d0e36]
+ atanh(1) now returns ∞ instead of throwing [906719c][66726e8]
+ Fixed missing close in IO::Path.slurp(:bin) [697a0ae]
+ :U QuantHashes now auto-vivify to their correct type and not Hash [79bb867]
+ Mix/MixHash.Bag/BagHash coersion now ignores negative weights [87bba04]
+ arity-0 infix:<Z> now returns a Seq instead of a List [3fdae43]
+ Fix augment of a nested package [87880ca]
+ Smartmatch with Regex variable now returns a Match instead of Bool [5ac593e]
+ Empty ()[0] now returns Nil instead of False [f50e39b]
+ Failed IO::Socket::Async connection no longer produces unexpected crash [f50e39b]
+ Quitting Supplies with no QUIT phasers no longer unexpectedly crash [f50e39b]
+ Fixed NativeCall issues on big endian machines [627a77e]
+ Fixed broken handling of $/ in some uses of `.match` [ba152bd]
+ Fixed Lock.protect not releasing the lock on control exceptions [48c2af6]
+ MoarVM now builds on any version of macOS [b4dfed2]
+ Fixed concurrency crashes due to garbage collection [6dc5074]
+ Fixed race condition in EmptyIterator [ed2631c]
+ Fixed hang with multi-threaded long-running NativeCall calls [f99d958]
+ Made my @a[10] = ^Inf work [aedb8e7]
+ Fixed [;]:delete [3b9c4c9]
+ Fixed incorrect handling of negative weights in ∪ operator [e10f767]
+ duckmap now preserves types of Iterables [43cb55f]
+ Fixed premature overflow to Inf with large Num literals [729d7e3]
+ Fixed race condition in NativeCall callsite used by multiple threads [49fd825]
+ Fixed instabilities in programs launching many threads at startup [0134132]
+ Fixed crash when reporting X::Composition::NotComposable or
X::Inheritance::Unsupported exceptions [a822bcf]
+ Fixed clock_gettime issue on macOS [ee8ae92]
+ Fixed SEGV in multi-threaded programs with strings-as-strands [395f369]
+ `regex` TOP Grammar rule will now backtrack if needed [4ccb2f3]
+ Fixed .rotate/.reverse on 1-dimmed arrays assigning to self [2d56751]
+ Fixed exponentiation involving zeros for Complex numbers [7f32243]
+ Fixed Label.gist [29db214][53d7b72]
+ Fixed certain edge cases of incorrect stringification of Rationals
with .Str, .perl, and .base [b5aa3c5]

Additions:
+ Added TWEAK submethod for object construction [fdc90a2][9409d68]
+ Added DateTime.hh-mm-ss [bf51eca]
+ Added parse-base routine [7e21a24]
+ is-approx with no explicit tolerances now uses more complex algorithm to
choose a tolerance to use (same as old is_approx) [82432a4]
+ on failure, is-approx now displays actual values received [b4fe680]
+ Added Iterator.skip-one to skip a single value [71a01e9]
+ Added Iterator.skip-at-least to skip several values [8d357af]
+ Re-imagined Str.match [b7201a8]:
+ the family of :nth is now lazy will return whatever can find
+ non-monotonically increasing :nth iterator values will now die
+ Str.match/subst/subst-mutate now have :as adverb [1b95636][c9a24d9][aaec517]
+ &infix: now works with Setty objects [d92e1ad]
+ :ov and :ex adverbs are now illegal in Str.subst [b90c741]
+ Made nextwith/samewith/nextsame/callwith to be real subroutines [70a367d]
+ Added CX::Emit and CX::Done control exceptions [07eeea8]
+ Setty.Mix/.MixHash coercers now use Int weights instead of Bool [7ba7eb4]
+ Implemented :kv,:p,:k,:v on 1-element multidim [;] [764cfcd]
+ .chrs can now also accepts codepoint numbers as Str [4ae3f23]
+ Added support for compilation of Rakudo on Solaris [a43b0c1]
+ IterationEnd.perl/gist/Str now returns text “IterationEnd” [59bb1b1]
+ Added X::Syntax::Number::InvalidCharacter exception [2faa55b]
+ .reverse/rotate on 1-dimmed arrays are now nodal [cd765e6]
+ .line and .file on core Code now references original source files [b068e3a]
+ .rethrow now works on unthrown exceptions [58a4826]
+ All Reals now accept `Whatever` as the second argument to .base() [c1d2599]
+ sub MAIN usage message shows possible Enum values if param is
named and is an Enum [a3be654]

Efficiency:
+ Made slip(@a) about 1.2x faster [37d0e46]
+ Made initialization of 2+dimmed array 10x to 16x faster [dfb58d4]
+ Str.match is now about 5% faster [4fc17df]
+ Str.match with :nth feature is now about 2x faster [41e2572]
+ my @a = Str.match(…) is now about 5% faster [e472420]
+ Str.comb(Regex) is now about 7x faster [1794328]
+ Simple Str.subst/subst-mutate is now about 30% faster [364e67b]
+ Match.Str|prematch|postmatch is now about 2x faster [e65d931]
+ Match.Bool is now about 1% faster (not much, but used a lot) [1fce095]
+ Made ~~ /foo/ faster: 2% for successful/6% for failed matches [05b65d0]
+ Made <foo bar baz> ~~ /foo/ about 2x faster [e4dc8b6]
+ Made %h ~~ /foo/ about 2x faster [33eeb32]
+ Frequent accesses of multiple adverbs (e.g. %h<a>:p:exists)
is now 2x faster [f22f894]
+ Made infix: faster: Str: 14x, type: 10x, Range: 3.5x,
Int|Seq|Hash: 1.5x, Array: 1.2x [bc7fcc6]
+ IO::Spec::Unix.canonpath is now 7x to 50x faster [f3f00fb]
+ Baggy.roll/pick is now about 10% faster [fc47bbf]
+ Made copying shaped arrays 10x to 20x faster [a1d8e93][0cf7b36][d27ecfa]
+ Made setting up a shaped array 2x as fast [f06e4c3]
+ Made creation of typed shaped arrays 15% faster [f5bf6c1]
+ Made 2d/3d array accesses about 7x as fast [d3a0907]
+ Made AT-POS on 1,2,3dim arrays about 20x faster [feb7bcb]
+ Made creating a shaped array about 50% faster [1293188][576f3a1]
+ Made .AT-POS on 3+ dimmed arrays 20% faster [1bb5aad]
+ Made over-indexed .AT-POS on 1,2,3 dimmed arrays about 10% faster [1bb5aad]
+ Made multi-dimmed ASSIGN-POS about 30% faster [5b2bdeb]
+ Made .ASSIGN-POS for 1,2,3dimmed arrays about 40x faster [050cf72]
+ Made n-dimmed .EXISTS-POS about 1.5x faster [006f008]
+ Made .EXISTS-POS for 1,2,3dimmed arrays about 10x faster [b1c41b7]
+ Made n-dimmed DELETE-POS about 1.3x faster [6ccecb1]
+ Made .DELETE-POS for 1,2,3dimmed arrays about 20x faster [55b9e90]
+ Made n-dimmed BIND-POS about 1.3x faster [2827edb]
+ Made .BIND-POS for 1,2,3dimmed arrays about 20x faster [9f94525]
+ Made @a[10].STORE at least as fast as @a.STORE [8064ff1]
+ Made .kv on shaped Arrays about 4x faster [e42b68e]
+ Made .pairs/.antipairs on shaped Arrays about 2.8x faster [0f2566a][f608a33]
+ Made List.kv about 30% faster [7a2baf4]
+ for loops on 1-dimmed arrays are now 3x faster [ed36e60]
+ .kv on 1-dimmed arrays is now 7x faster [608de26]
+ .pairs/.antipairs on 1-dimmed arrays is now 3x faster [b7d9537][1c425f9]
+ postcircumfix[;] on 2/3 dimmed arrays is now 9x faster [0b97362]
+ Assignment to [;] for 2/3 dimmed arrays is now 10x faster [ce85ba3]
+ [;]:exists for 2/3 dimmed arrays is now 7x faster [e3e3fef]
+ [;]:delete for 2/3 dimmed arrays is now 10x faster [3b9c4c9]
+ [;] := foo for 2/3 dimmed arrays is now 10x faster [eaf4132]
+ .iterator and .values on shaped arrays are now about 4x faster [736ab11]
+ Fixed optimization of shaped arrays that gives 10% gain on simple `for`
loops and likely will give larger gains on bigger programs [b7e632e]
+ Made starting MappyIterator faster, affecting all Hash/Map/Baggy iterator
methods. 2-elem Hash iteration is 1.6x faster [97fb6c2]
+ Made starting a grepper faster: .grep on with no adverbs on 2-element list
is now 20% faster [077c8f0]
+ Made Date/DateTime creation 20% faster [0e7f480]
+ Hashes now use 4 (32-bit) or 8 (64-bit) bytes less memory per stored item [395f369]
+ Rational.Str is now about 40% faster [b5aa3c5]
+ Rational.base is now about 30% faster [b5aa3c5]
+ Various streamlining of code that’s hard to measure the final impact of

Notable changes in modules shipped with Rakudo Star:

+ DBIish: Prepare tests for lexical module loading and do not rely on your dependencies to load modules
+ Pod-To-HTML: Bump version and use a separate element as anchor for “to top” links
+ Terminal-ANSIColor: Update Pod documentation and support 256-color and 24-bit RGB modes
+ doc: Large number of changes – too many to detail here
+ json_fast: Speed gains
+ panda: Explicitly use Panda::Project as we use it in class Panda
+ perl6-lwp-simple: Change to http.perl6.org since the main site is going https and add NO_NETWORK_TESTING

There are some key features of Perl 6 that Rakudo Star does not yet
handle appropriately, although they will appear in upcoming releases.
Some of the not-quite-there features include:

* advanced macros
* non-blocking I/O (in progress)
* some bits of Synopsis 9 and 11

There is an online resource at http://perl6.org/compilers/features
that lists the known implemented and missing features of Rakudo’s
backends and other Perl 6 implementations.

In many places we’ve tried to make Rakudo smart enough to inform the
programmer that a given feature isn’t implemented, but there are many
that we’ve missed. Bug reports about missing and broken features are
welcomed at rakudobug@perl.org.

See http://perl6.org/ for links to much more information about
Perl 6, including documentation, example code, tutorials, presentations,
reference materials, design documents, and other supporting resources.
Some Perl 6 tutorials are available under the “docs” directory in
the release tarball.

The development team thanks all of the contributors and sponsors for
making Rakudo Star possible. If you would like to contribute, see
http://rakudo.org/how-to-help, ask on the perl6-compiler@perl.org
mailing list, or join us on IRC #perl6 on freenode.

Posted in Uncategorized | Comments Off on Announce: Rakudo Star Release 2016.11

Announce: Rakudo Star Release 2016.10

On behalf of the Rakudo and Perl 6 development teams, I’m pleased to announce
the October 2016 release of “Rakudo Star”, a useful and usable production
distribution of Perl 6. The tarball for the October 2016 release is available
from http://rakudo.org/downloads/star/.

This is the fourth post-Christmas (production) release of Rakudo Star and
implements Perl v6.c. It comes with support for the MoarVM backend (all module
tests pass on supported platforms).

Please note that this release of Rakudo Star is not fully functional with the
JVM backend from the Rakudo compiler. Please use the MoarVM backend only.

In the Perl 6 world, we make a distinction between the language (“Perl 6”) and
specific implementations of the language such as “Rakudo Perl”. This Star
release includes release 2016.10 of the Rakudo Perl 6 compiler, version 2016.10
of MoarVM, plus various modules, documentation, and other resources collected
from the Perl 6 community.

Some of the new compiler features since the last Rakudo Star release include:

+ Test.pm now provides bail-out()
+ Implemented $?MODULE and ::?MODULE
+ Implemented CompUnit::Repository::Installation::installed
+ .min/.max can now be called on Hashes
+ .succ now increments additional 29 digit ranges, such as Thai digits
+ Coercions now work in return types
+ Added RAKUDO_EXCEPTIONS_HANDLER env var to control exceptions output
+ CompUnit::Repository::Installation now cleans up short-name folders when empty
+ All Unicode quotes can now be used as quoters inside qqww/qww
+ Added basic Unicode 9 support (NFG changes for latest TR#29 still to do))
+ IO::Handle.new now uses ‘utf8’ encoding by default
+ It’s now possible to refer to sigiless parameters inside where clauses
+ Made Complex.new() return 0+0i
+ Added shortname() method to CurriedRoleHOW

Compiler maintenance since the last Rakudo Star release includes:

+ zef and panda now correctly install on OpenBSD and FreeBSD
+ Numerous improvements to content of error messages and addition of new previously-undetected warnings
+ Race conditions and deadlocks fixed
+ Large number of Hash, Bag, Baggie BagHash etc. speedups
+ Numerous improvements in CUR, offering up to 10x faster module loading
+ Many permutations() and combinations() speedups
+ Distribution::Path now handles native libraries correctly
+ Junctions now work in .classify
+ Fixed a memory leak involving EVAL
+ Fixed tab-completion issues with non-identifiers in REPL
+ Made huge improvement to CUR::Filesystem.id performance
+ Many fixes and additions improving JVM backend support
+ Removed argument-taking Dateish candidates for is-leap-year, days-in-month, and day-of-week (were never part of the spec)
+ Cool.IO no longer accepts any arguments
+ Overflow check has been removed from infix:<**>(int, int)

Notable changes in modules shipped with Rakudo Star:

+ prove6 has been added and will be used by panda unless PROVE_COMMAND env var set
+ perl6-pod-to-bigpage: added as dependency for doc tests
+ DBIish: Add simple Str support for Postgres type 790 (money)
+ Linenoise: Remove dependency on Native::Resources
+ Pod-To-HTML: Add support for lang=”” attribute, ignore .precomp and other changes
+ doc: Many documentation additions and improvements (too many to list!)
+ json-fast: Don’t explode when using to-json on a Num
+ p6-native-resources: Mark this module as deprecated in the ecosystem
+ panda: support for prove6 and uninstallation of modules and much else
+ perl6-lwp-simple: Make SSL testing optional and more control over character encoding.
+ svg-plot: Background color option and bubble plot type added.
+ perl6intro.pdf has also been updated.

There are some key features of Perl 6 that Rakudo Star does not yet handle
appropriately, although they will appear in upcoming releases. Some of the
not-quite-there features include:

+ advanced macros
+ non-blocking I/O (in progress)
+ some bits of Synopsis 9 and 11
+ There is an online resource at http://perl6.org/compilers/features that lists
the known implemented and missing features of Rakudo’s backends and other Perl
6 implementations.

In many places we’ve tried to make Rakudo smart enough to inform the programmer
that a given feature isn’t implemented, but there are many that we’ve missed.
Bug reports about missing and broken features are welcomed at
rakudobug@perl.org.

See http://perl6.org/ for links to much more information about Perl 6,
including documentation, example code, tutorials, presentations, reference
materials, design documents, and other supporting resources. Some Perl 6
tutorials are available under the “docs” directory in the release tarball.

The development team thanks all of the contributors and sponsors for making
Rakudo Star possible. If you would like to contribute, see
http://rakudo.org/how-to-help, ask on the perl6-compiler@perl.org mailing list,
or join us on IRC #perl6 on freenode.

Posted in announce | Comments Off on Announce: Rakudo Star Release 2016.10

Announce: Rakudo Star Release 2016.07

On behalf of the Rakudo and Perl 6 development teams, I’m pleased to announce the July 2016 release of “Rakudo Star”, a useful and usable production distribution of Perl 6. The tarball for the July 2016 release is available from http://rakudo.org/downloads/star/.

This is the third post-Christmas (production) release of Rakudo Star and implements Perl v6.c. It comes with support for the MoarVM backend (all module tests pass on supported platforms).

Please note that this release of Rakudo Star is not fully functional with the JVM backend from the Rakudo compiler. Please use the MoarVM backend only.

In the Perl 6 world, we make a distinction between the language (“Perl 6”) and specific implementations of the language such as “Rakudo Perl”. This Star release includes release 2016.07 of the Rakudo Perl 6 compiler, version 2016.07 of MoarVM, plus various modules, documentation, and other resources collected from the Perl 6 community.

Some of the new compiler features since the last Rakudo Star release include:

  • Ability to use a custom debugger module
  • The “is-approx” sub from Test.pm6 now allows for relative/absolute tolerance
  • A fail in a custom BUILD will now be returned, rather than thrown
  • Introduce .Map coercer
  • Implement alternate ways to call subtest
  • Support for new leap-second at the end of 2016
  • The “is required” trait on Attributes can now take a Bool or a Str
  • IO::[Path,Handle] gained a .mode method which returns the POSIX file permissions
  • Distribution is now a role interface that enables encapsulating IO used for distribution installation
  • CompUnit::Repository::Installation now uses the new Distribution interface
  • Custom repository implementations now supported, including precompilation

Compiler maintenance since the last Rakudo Star release includes:

  • Basic object creation (using either .new or .bless) now up to 3x faster
  • All routines now have less overhead
  • The MMD cache accepts candidates with named parameters if it can. (This made adverbed slices about 18x as fast)
  • Sigificant optimizations for speed in many parts of the system (.map, gather/take etc.)
  • Many precompilation fixes (including EVAL and improved support of OS packaging)
  • Arrays with holes (e.g. from :delete) now correctly iterate/auto-vivify
  • An issue with reverse dependencies of installed modules was fixed
  • “is_approx” sub (note underscore) from Test.pm6 deprecated
  • Harden Mu.Str against moving GC
  • Simplify $USER/$GROUP initialization
  • Mu can now be the result of a Promise
  • samewith() now also works on non-multi’s
  • Many fixes in the area of pre-compilation and installing modules
  • count-only and bool-only now are optional methods in Iterators (only to be implemented if they can work without generating anything)
  • IO::ArgFiles.slurp / IO::ArgFiles.eof are fixed
  • REPL whitespace and error handling
  • CompUnit::Repository::Installation no longer considers bin/xxx and resources/bin/xxx the same content address
  • min/max on Failures throw instead of returning ±Inf
  • NativeCall’s is mangled trait no longer ignored for CPPStruct
  • Many Str, List and Array methods much faster
  • Map/Hash initializations are now 30% faster
  • make DESTDIR now correctly finds CompUnit::Repository::Staging
  • Output from Test.pm6’s diag() is no longer lost in non-verbose prove output when called at the start of the test file or during TODO tests
  • Improved error messages

Notable changes in modules shipped with Rakudo Star:

  • DBIish: v0.5.9 (with many Oracle/MySQL fixes) plus README.pod and mojibake fixes
  • NativeHelpers-Blob: v0.1.10
  • PSGI: v1.2.0 supports P6SGI 0.7Draft
  • Pod-To-HTML: v0.1.2 plus fixes
  • debugger-ui-commandline: README fixes
  • doc: many fixes to documentation content and HTML generation
  • panda: Avoid Rakudo internals deprecation warning and don’t require Build.pm to inherit Panda::Builder
  • perl6-file-which: CI fixes
  • perl6-http-easy: v1.1.0 (with more flexible P6SGI support) plus avoid errors in binary request
  • shell-command: Mention already implemented commands missing from README
  • perl6-lwp-simple: track github.com/perl6/perl6-lwp-simple as upstream (as panda does) which has a test fix needed since we don’t support https in R* and a test url had a new https redirect

perl6intro.pdf has also been updated.

There are some key features of Perl 6 that Rakudo Star does not yet handle appropriately, although they will appear in upcoming releases. Some of the not-quite-there features include:

  • advanced macros
  • non-blocking I/O (in progress)
  • some bits of Synopsis 9 and 11
  • There is an online resource at http://perl6.org/compilers/features that lists the known implemented and missing features of Rakudo’s backends and other Perl 6 implementations.

In many places we’ve tried to make Rakudo smart enough to inform the programmer that a given feature isn’t implemented, but there are many that we’ve missed. Bug reports about missing and broken features are welcomed at rakudobug@perl.org.

See http://perl6.org/ for links to much more information about Perl 6, including documentation, example code, tutorials, presentations, reference materials, design documents, and other supporting resources. Some Perl 6 tutorials are available under the “docs” directory in the release tarball.

The development team thanks all of the contributors and sponsors for making Rakudo Star possible. If you would like to contribute, see http://rakudo.org/how-to-help, ask on the perl6-compiler@perl.org mailing list, or join us on IRC #perl6 on freenode.

Posted in announce | Comments Off on Announce: Rakudo Star Release 2016.07