[perl #75316] 1...1..0 keeps Rakudo on 100% CPU usage

2014-09-23 Thread Christian Bartolomaeus via RT
The test for this ticket (which now resides in S03-sequence/basic.t) was fudged for rakudo (todo 'mysterious'). AFAIU the code { 1 ... () } now throws an exception (just like shifting one element from an empty list does). Therefore I changed the test (and unfudged it): throws_like { 1 ... ()

[perl #99658] sequence operator '...' timeout

2014-09-24 Thread Christian Bartolomaeus via RT
Actually I don't think S03 says that '1,3,5 ... 8' should act as '1,3,5 ... *' As I understand it '1,3,5 ... 8' gives an infinite list with all even numbers. '1,3,5 ... *' also gives an infinite list with all even numbers -- but this one is lazy. So there is a difference in behaviour: When

[perl #76998] [BUG] capture variable does not parse for building a pair of the form :$a

2014-09-24 Thread Christian Bartolomaeus via RT
This now has a test in S05-capture/match-object.t (cmp. https://github.com/perl6/roast/commit/15cd5a89f8fcfac7d0a3ae13afbc2c790316c8ef) All credits to timotimo, who explained both test and procedure to close this ticket: http://perl6advent.wordpress.com/2013/12/17/day-17-of-a-new-contributor/

[perl #115726] sub infix: ( ){}; gives misleading error message about P5 diamond operator

2014-09-25 Thread Christian Bartolomaeus via RT
The test in S32-exceptions/misc.t passes and the test file is in 't/spectest.data'. If the ticket should not be set to resolved (if there is something else to do), please comment.

[perl #120739] @a[*]:kv / %a{*}:kv - $k, $v dies

2014-09-25 Thread Christian Bartolomaeus via RT
I added a test to S03-operators/subscript-adverbs.t with the following commit: https://github.com/perl6/roast/commit/7f16f13f8c9610d57a6efb3eca0e846edbb6ed07

[perl #109800] [BUG] Can't declare infix operators using 'my infix:sth' syntax in Rakudo

2014-09-25 Thread Christian Bartolomaeus via RT
The test in S06-operator-overloading/sub.t passes and the test file is in t/spectest.data. If the ticket should not be set to resolved (if there is something else to do), please comment.

[perl #116348] [BUG] infix:... shouldn't autothread because of a junction in the RHS in Rakudo

2014-09-25 Thread Christian Bartolomaeus via RT
I added a test to S03-sequence/misc.t with the following commit: https://github.com/perl6/roast/commit/7f16f13f8c9610d57a6efb3eca0e846edbb6ed07

[perl #122842] segfault with moar with specific PERL6LIB and running a specific test file

2014-09-25 Thread Christian Bartolomaeus via RT
I tried to narrow the problem down, but was not very successful. With the attached file trans.t I can reproduce the segfault: $ PERL6LIB=$(pwd)/lib:. ./perl6-m trans.t alive Segmentation fault If I remove some variable declarations or the last say in that file, the segfault goes away. Even

[perl #77158] [BUG] Doing .perl on an :(Array of Int) signature produces an internal error in Rakudo

2014-09-25 Thread Christian Bartolomaeus via RT
I moved the test from S02-types/77158.t to S06-signature/types.t (which is in 't/spectest.data'). The test passes on all rakudo backends.

[perl #76608] [BUG] Bogus redeclaration error when doing a declaration inside a $() in an interpolating string in Rakudo

2014-09-25 Thread Christian Bartolomaeus via RT
stmuk added a test for this recently: https://github.com/perl6/roast/commit/b4fc0fe9f11bb34e4442da7e1f945e8740d07c7c I moved the test from S02-names-var/76608.t to S02-literals/misc-interpolation.t (which is in 't/spectest.data'). The test passes on all rakudo backends.

[perl #77522] Rakudo allows unspace in /\ X/ but STD doesn't

2014-09-25 Thread Christian Bartolomaeus via RT
The test in S32-exceptions/misc.t passes and the test file is in 't/spectest.data'. If the ticket should not be set to resolved (if there is something else to do), please comment.

[perl #99732] [BUG] Rakudo doesn't like .++

2014-09-26 Thread Christian Bartolomaeus via RT
I added a test to S03-operators/autoincrement.t with the following commit: https://github.com/perl6/roast/commit/3164e55750 (I didn't test the staff with $_='' though, but only incremented $_=4 with .++ once.)

[perl #122849] A * as last element does not extend list for infix:Z (zip)

2014-09-26 Thread Christian Bartolomaeus via RT
There was already a ticket for this problem (#122230). Also the test in question was a duplicate of a test in S03-metaops/zip.t -- which is handled in ticket #122230. I removed the redundant test from S03-operators/misc.t and I'm closing this ticket.

[perl #85750] Test failures on OpenBSD

2014-09-28 Thread Christian Bartolomaeus via RT
Hi, again it's been a while. I installed a current Rakudo on OpenBSD 5.5 (amd64) and happily most of the test failures didn't occur anymore. On Moar I had a clean spectest. On Parrot I had only one failure. (Please note, that I had to install ICU (pkg_add icu4c). Without that package some of

[perl #122649] Unneeded rebuilds on rakudo-moar

2014-09-29 Thread Christian Bartolomaeus via RT
This happens for all backends. AFAIU the reason is that we have a target m-runner-default (in the case of Moar) in our Makefile. This target is a dependency for target all and is therefore called when executing make. But since there is no file m-runner-default this target is considered out of

[perl #85750] Test failures on OpenBSD

2014-09-29 Thread Christian Bartolomaeus via RT
Just for the records: Looking a bit closer I saw that the failing tests in S03-operators/arith.t and S32-num/power.t (reported on 2013-06-03) where identical. Both test whether 1**Inf equals 1. Interestingly I got exactly those test failures on a current version of NetBSD (6.1.4):

[perl #75370] Enum name as type constraint is unreasonably strict

2014-09-30 Thread Christian Bartolomaeus via RT
stmuk added a test for this recently: https://github.com/perl6/roast/commit/b4fc0fe9f11bb34e4442da7e1f945e8740d07c7c I moved the test from S02-names/75370.t to S12-enums/basic.t (which is in 't/spectest.data').

[perl #113680] lack of semicolon at the end of a use ... statement throws internal error

2014-09-30 Thread Christian Bartolomaeus via RT
I added a test to S32-exceptions/misc.t with the following commit: https://github.com/perl6/roast/commit/afc4d1ee8aaa5a5a62ff728f2acbaf68f12da26c (Maybe it's a bit too specific, since it checks the exact error message.)

[perl #120061] [BUG] Rakudo on the JVM says 'Scalar'

2014-10-01 Thread Christian Bartolomaeus via RT
Looks like this is now implemented: $ perl6-m -e 'say [1,2,3].combinations(2).perl' ([1, 2], [1, 3], [2, 3]).list $ perl6-p -e 'say [1,2,3].combinations(2).perl' ([1, 2], [1, 3], [2, 3]).list $ perl6-j -e 'say [1,2,3].combinations(2).perl' ([1, 2], [1, 3], [2, 3]).list There are tests in

[perl #65900] 'my ($a is readonly) = 5' should be allowed, but assigning to it afterward should be disallowed; '(my $a is readonly) = 5' should also be disallowed... in Rakudo

2014-10-01 Thread Christian Bartolomaeus via RT
Things have changed and infix:::= is used instead of a variable trait is readonly. The tests for this ticket are gone with this commit: https://github.com/perl6/roast/commit/253242f3dd7ece23c6390a80cdcdf78b561cc973 my $a is readonly = 5; say $a; ===SORRY!=== Error while compiling Can't use

[perl #93982] [BUG] Errors from typed variable declaration with missing initializers

2014-10-01 Thread Christian Bartolomaeus via RT
This works now (probably for quite a while already): my Str ($a) = (); (Str) I added a test to S02-types/type.t with this commit: https://github.com/perl6/roast/commit/b93b78792bcd5a0fef75bd2676ed1eac3e330562

[perl #111964] [BUG] LTA error message when passing an Int argument to base conversion in Rakudo

2014-10-02 Thread Christian Bartolomaeus via RT
The error message now hopefully is adequat: my $x=31; say :8($x) You have confused the number 31 with the textual representation 31; if you wanted to render the number in the given base, use $number.base($radix) in block unit at unknown file:1 There is a test for the correct exception type

[perl #122842] segfault with moar with specific PERL6LIB and running a specific test file

2014-10-02 Thread Christian Bartolomaeus via RT
This was fixed in MoarVM today (cmp. http://irclog.perlgeek.de/perl6/2014-10-02#i_9446636 and http://irclog.perlgeek.de/perl6/2014-10-02#i_9447562).

[perl #112584] Passing command line options to “perl6” causes the USAGE automatic generation to print an incorrect program name

2014-10-03 Thread Christian Bartolomaeus via RT
This works now and it looks like it has been fixed for quite a while. IMHO this was the same problem as that from RT #113078 ([BUG] $*PROGRAM_NAME erroneously reports the first argument to 'perl6', even when this argument isn't a program name in Rakudo). Since there is a test in

[perl #112970] [BUG] LTA, misleading error message when a typed array in a signature fails to bind in Rakudo

2014-10-05 Thread Christian Bartolomaeus via RT
The error message now mentions that 'Positional[Int]' is expected: sub f(Int @x) {}; f( [] ) Type check failed in binding @x; expected 'Positional[Int]' but got 'Array' in sub f at unknown file:1 in block unit at unknown file:1 A test was added to S14-roles/parameterized-type.t with the

[perl #111956] [BUG] LTA error message when quantifier follows nothing in Rakudo

2014-10-05 Thread Christian Bartolomaeus via RT
The error message with nom is now Quantifier quantifies nothing: / * / ===SORRY!=== Error while compiling unknown file Quantifier quantifies nothing at unknown file:1 -- / *⏏ / expecting any of: statement list prefix or term prefix or meta-prefix / a+ + /

[perl #114726] [BUG] Cannot bind $/

2014-10-06 Thread Christian Bartolomaeus via RT
This works now (probably for a while already) with rakudo. I added a test to S05-match/capturing-contexts.t with the following commit: https://github.com/perl6/roast/commit/5fe25b6de871608354e73b3e26cdd388d15e4e08 Please note that I test 'my $/ := 42' instead of '$/ := 42' (which also works

[perl #119293] Rakudo doesn't warn about Perl 5 $]

2014-10-06 Thread Christian Bartolomaeus via RT
Unfortunately the error message is only Unexpected closing bracket now: 13:00 bartolin r: say $] 13:00 +camelia rakudo-{parrot,moar} 65819d: OUTPUT«===SORRY!=== Error while compiling /tmp/tmpfile␤Unexpected closing bracket␤at /tmp/tmpfile:1␤-- say $⏏]

[perl #71800] [BUG] empty groups in regexes should throw Null pattern not allowed at errors

2014-10-06 Thread Christian Bartolomaeus via RT
Now all of these die with X::Syntax::Regex::NullRegex. There are tests in S32-exceptions/misc.t.

[perl #115132] [BUG] cannot assign boolean evaluation to non-container

2014-10-07 Thread Christian Bartolomaeus via RT
Hi, this works now (probably for a while, already). I added a test to S04-declarations/constant.t with the following commit: https://github.com/perl6/roast/commit/6cc8c38a1c Please note: If you smart match agains a regex you don't get a boolean value but either a Match object or Nil: (foo

[perl #116643] [BUG] Null PMC access when declaring operator with a backslash in Rakudo

2014-10-07 Thread Christian Bartolomaeus via RT
On Moar and on JVM all of those declarations run fine. On Parrot the errors are still the same. I added tests (fudged for Parrot) for two of the different declarations to S06-operator-overloading/sub.t with the following commit: https://github.com/perl6/roast/commit/dea36c4818

[perl #115294] [BUG] Null PMC access when using variable in interpolated block in double-quoted string in regex in Rakudo

2014-10-07 Thread Christian Bartolomaeus via RT
This looks good now: It doesn't die anymore, but returns foo bar. $ perl6-m -e '$_ = foo bar; say m/ { $_ } /' 「foo bar」 $ perl6-p -e '$_ = foo bar; say m/ { $_ } /' 「foo bar」 $ perl6-j -e '$_ = foo bar; say m/ { $_ } /' 「foo bar」 I added a test to S05-mass/rx.t with the following commit:

[perl #77616] ~ operator in regexp reverts capture order, but it should not

2014-10-08 Thread Christian Bartolomaeus via RT
Current behaviour: say so abc ~~ /a ~ (c) (b)/; say $0, $1 True 「b」 「c」 As I understand S05 the ~ operator basically rewrites the above regex to /a (b) (c)/ and only then matching and capturing happens. So the question seems to be, whether numbering of subpatterns should be done before the

[perl #115502] [BUG] 'try' at BEGIN time hangs in Rakudo

2014-10-08 Thread Christian Bartolomaeus via RT
This does no longer hang. $ perl6-m -e 'BEGIN { try 0 }; say alive' alive $ perl6-p -e 'BEGIN { try 0 }; say alive' alive $ perl6-j -e 'BEGIN { try 0 }; say alive' alive I added a test to S04-phasers/begin.t with the following commit: https://github.com/perl6/roast/commit/05bf75e3b6

[perl #77738] [bug] is rw on slurpy parameters

2014-10-08 Thread Christian Bartolomaeus via RT
This works now: sub incr1 (*@v is rw) { @v[0]++; @v[1]++; }; my ($a, $b) = (0, 0); incr1($a, $b); say incr1: $a, $b; incr1: 1, 1 sub incr2 (*@v is rw) { for @v { $_++} }; my ($a, $b) = (0, 0); incr2($a, $b); say incr2: $a, $b; incr2: 1, 1 sub incr3 (*@v is rw) { for @v - $x is rw { $x++

[perl #113964] [BUG] LTA error message when passing to a typed slurpy array parameter in Rakudo

2014-10-08 Thread Christian Bartolomaeus via RT
The error message looks adequate now: $ perl6 -e 'sub foo(Int *@ints) {}' ===SORRY!=== Error while compiling -e Slurpy positionals with type constraints are not supported. at -e:1 -- sub foo(Int *@ints⏏) {} expecting any of: formal parameter constraint But as it was

[perl #116096] [BUG] Set.new erroneously flattens arrays in Rakudo

2014-10-08 Thread Christian Bartolomaeus via RT
Arrays are no longer flattened by Set.new: say set(([1, 2], [3, 4])).perl set([1, 2],[3, 4]) I added a test to S02-types/set.t with the following commit: https://github.com/perl6/roast/commit/e8fd9ec55d

[perl #118387] [BUG] LEAVE doesn't trigger when an exception is thrown

2014-10-09 Thread Christian Bartolomaeus via RT
The described problem (no 'OK' is printed) persists on Parrot but works fine on Moar and JVM: $ perl6-p -e 'sub foo { LEAVE { say OK }; die died }; foo()' 2/dev/null $ perl6-m -e 'sub foo { LEAVE { say OK }; die died }; foo()' 2/dev/null OK $ perl6-j -e 'sub foo { LEAVE { say OK }; die died };

[perl #116695] [BUG] Wrong array length when Mu elements and delete interact in Rakudo

2014-10-09 Thread Christian Bartolomaeus via RT
Well, this bug is gone, then. I added a test to S32-array/delete.t with the following commit: https://github.com/perl6/roast/commit/f386c96536 I had (and have) some difficulties to find the references in the spec for the correct behaviour -- especially with regard to the following quotes from

[perl #116607] [BUG] LTA internal error when forgetting initialization assignment on backslash-variable declaration in Rakudo

2014-10-09 Thread Christian Bartolomaeus via RT
The error message matches that of STD now: $ perl6-m -e 'my \foo' ===SORRY!=== Error while compiling -e Term definition requires an initializer at -e:1 -- my \foo⏏EOL expecting any of: scoped declarator I added a test to S32-exceptions/misc.t with the following commit:

[perl #77616] ~ operator in regexp reverts capture order, but it should not

2014-10-09 Thread Christian Bartolomaeus via RT
Thanks for the feedback. I added a fudged test to S05-metachars/tilde.t with the following commit: https://github.com/perl6/roast/commit/f15d9aed26

[perl #117481] [BUG] duplicate keys in .gist in Match of regex which backtracked in Rakudo

2014-10-10 Thread Christian Bartolomaeus via RT
There is no longer a duplicate key in the .gist output: $ perl6-m -e say ('/foo/bar/baz/' ~~ m/^ $dirname=(.* '/'+)? $basename=(-[\/]+) '/'* $ /).gist 「/foo/bar/baz/」 dirname = 「/foo/bar/」 basename = 「baz」 I added a test to S02-names-vars/list_array_perl.t (couldn't find a better place) with

[perl #112988] excessive errors when foo.pl does not exist

2014-10-10 Thread Christian Bartolomaeus via RT
I added a test (using is_run) to S19-command-line/arguments.t with the following commit: https://github.com/perl6/roast/commit/3cee096456 S19-command-line/arguments.t is a new file in roast and as such not yet included in t/spectest.data in Rakudo. I'll leave the ticket open until that is

[perl #115390] Crash (abort or segfault) when using 'but' in a loop

2014-10-10 Thread Christian Bartolomaeus via RT
These error reports are difficult to assess from one or two years later. I'm inclined to say the bugs are fixed -- though there seems to exists another bug regarding the use of but in a for loop. But one at a time: $ perl6-m -e 'for 1..100 - $i { say $i; run true; 1; }' 1 [ ... output

[perl #116933] Glibc: double free or memory corruption crash running t/spec/S02-types/bool.t in Rakudo 2013.02.1-7-gb205e66

2014-10-11 Thread Christian Bartolomaeus via RT
Since the tests in S02-types/bool.t pass, the relevant problem seems to be the for loop with 0 but Bool::True. I don't see any crashes within the first 100 iterations, but on Parrot I get segfaults or crashes with around 262 iterations. On Moar and JVM there are no problems: $ perl6-m -e '(0

[perl #117043] [BUG] Null PMC access when declarator with multiple variables contain sigilless in Rakudo

2014-10-11 Thread Christian Bartolomaeus via RT
The assignment to a sigilless in a () no longer results in a Null PMC access error -- but the sigilless doesn't contain the correct value after assignment: $ perl6-m -e 'my ($x0, \x1) = (1, 2); say $x0; say x1' 1 (Any) $ perl6-m -e 'my (\x1) = 1; say x1' (Any) $ perl6-m -e 'my \x1 = 1; say x1'

[perl #112678] [BUG] 'div' for Ints truncates towards 0 when it should round down in Rakudo

2014-10-11 Thread Christian Bartolomaeus via RT
This works now: $ perl6-m -e 'say (-8) div 3' -3 I added a test to S03-operators/div.t with the following commit: https://github.com/perl6/roast/commit/d03302f512

[perl #111924] [BUG] Negative-index Failure over-eagerly triggers even for Whatever-y indexings in Rakudo

2014-10-11 Thread Christian Bartolomaeus via RT
The current error message is kind of funny and supports masak's assumption that * getting expanded as 0, and then the failure triggers (wrongly): $ perl6-m -e 'my @array; say @array[*-1]' Unsupported use of [-1] subscript to access from end of Array; in Perl 6 please use [*-1] (An exception of

[perl #114000] Re: IO stat exception when using :l

2014-10-13 Thread Christian Bartolomaeus via RT
Testing for a symlink with ~~:l on a non-existent file works now (returns False, but doesn't die). I added a test to S16-filehandles/filetest.t with the following commit: https://github.com/perl6/roast/commit/58ec1cfdbb

[perl #115248] [BUG] Cannot read lines from STDIN with current Parrot

2014-10-13 Thread Christian Bartolomaeus via RT
Looks like this issue has been handled and fixed in Parrot for some time: https://github.com/parrot/parrot/issues/860 and https://github.com/parrot/parrot/issues/861. Since the Parrot issues are closed I'm closing this ticket as well. (Hope that's okay, otherwise please reopen.)

[perl #74946] %h.delete() in right side of expression causes left side key missing

2014-10-13 Thread Christian Bartolomaeus via RT
This works now (using current syntax -- e.g. :delete): $ perl6-m -e 'my %h = a = b; %h{a} = %h{a} :delete; say %h.perl;' (a = b).hash I added a test to S32-hash/delete-adverb.t with the following commit: https://github.com/perl6/roast/commit/96c87780f7

[perl #77338] [BUG] Rakudo erroneously parses some optional-parameter question marks as twigils

2014-10-13 Thread Christian Bartolomaeus via RT
This looks good to me now: $ perl6-m -e 'sub foo(::T $?) {}; say alive' alive $ perl6-m -e 'role A[::T $?] {}; class B does A[] {}; say alive' alive The following dies, but that's okay (from the IRC log above: TimToady you can't put ? on a type constraint, which ::T is parsed as). $ perl6-m

[perl #77670] [BUG] .. no longer recognized as meaning the same as . in Rakudo

2014-10-13 Thread Christian Bartolomaeus via RT
As Matthew mentioned this works now. .. and . behave the same again: $ perl6-m -e 'say ( { 1 + 1 }, { 2 + 2 } )..().perl' (2, 4) $ perl6-m -e 'say ( { 1 + 1 }, { 2 + 2 } ).().perl' (2, 4) I added a test to S03-metaops/hyper.t with the following commit:

[perl #77668] [BUG] Can't call Callable objects in a list in parallel using the .() [or ()] form in Rakudo

2014-10-13 Thread Christian Bartolomaeus via RT
Now the first code snippet also seems to work: $ perl6-m -e 'sub infix:+-*/($a, $b) { ( { $a + $b }, { $a - $b }, { $a * $b }, { $a / $b } ).() }; say 5+-*/2;' 7 3 10 2.5 I added a test for that one to S03-metaops/hyper.t with the following commit:

[perl #77338] [BUG] Rakudo erroneously parses some optional-parameter question marks as twigils

2014-10-13 Thread Christian Bartolomaeus via RT
The tests are in S06-signature/optional.t and S14-roles/parameterized-basic.t, respectively. They were added with the following commit: https://github.com/perl6/roast/commit/2b3bee5223

[perl #80614] [Bug] chained array item assignment leaves one item undefined

2014-10-13 Thread Christian Bartolomaeus via RT
I tried to golf this (chained assignment and test failure) a bit and found the following: $ perl6-m -e 'my $x; $x = 1; my @a; my $y = @a[0] = 2; say @a[0]' 2 $ perl6-m -e 'my $x; ($x) = 1; my @a; my $y = @a[0] = 2; say @a[0]' (Any) The following looks weird as well: $ perl6-m -e 'my $y; my @a

[perl #78068] [BUG] REPL crashes when you use $* type variables.

2014-10-13 Thread Christian Bartolomaeus via RT
Possibly this is related to the issues in ticket #122914 (bindings and term definitions are forgotten in the REPL for subsequent lines).

[perl #83508] [BUG] Failed ()? captures should be Nil in Rakudo (nqp-rx)

2014-10-14 Thread Christian Bartolomaeus via RT
This works now (again): $ perl6-m -e 'x ~~ /(y)? (z)*/; say $0.defined; say $1.defined;' False True I added a test to S05-match/capturing-contexts.t with the following commit: https://github.com/perl6/roast/commit/ae245a65f6

[perl #92822] [BUG] - $a\ .\ chop bug

2014-10-14 Thread Christian Bartolomaeus via RT
On the note of Pepe Schwarz I'm closing this ticket. (The test is passing and it's in t/spectest.data.) $ perl6-m -e 'my $a = helloo; $a = $a\ .\ chop; say $a;' hello

[perl #111734] [BUG] Can't locally redefine True in Rakudo

2014-10-14 Thread Christian Bartolomaeus via RT
Great, redefinition of truth works as expected! I added a test to S04-declarations/constant.t with the following commit: https://github.com/perl6/roast/commit/c855d94be4

[perl #113988] [BUG] Null PMC access when doing .fmt on the return value from .reals

2014-10-14 Thread Christian Bartolomaeus via RT
Since this was all about .sprintf being called with only one argument but two directives (also cmp. #106594) and since the Null PMC access error is gone, this ticket could be closed IMHO. On the other hand the error from sprintf doesn't look very awesome in the given case: $ perl6-m -e

[perl #114456] [BUG] Invocation '()' after sub declaration doesn't parse in Rakudo (but does in STD)

2014-10-14 Thread Christian Bartolomaeus via RT
This works now: $ perl6-m -e 'say sub { 5 }()' 5 $ perl6-m -e 'sub ($t) { say $t }(arf)' arf I added tests to S02-lexical-conventions/sub-block-parsing.t with the following commit: https://github.com/perl6/roast/commit/09ff5366a3

[perl #115566] [BUG] Variables declared in quasi blocks don't work in Rakudo

2014-10-14 Thread Christian Bartolomaeus via RT
Just an update: Parrot no longer segfaults, but Moar does: $ perl6-m -e 'macro foo { quasi { my $a = OH HAI; say $a } }; foo' Segmentation fault $ perl6-p -e 'macro foo { quasi { my $a = OH HAI; say $a } }; foo' Cannot assign to an immutable value in any at -e:1 in block unit at -e:1 $

[perl #115842] [BUG] Comma can't be last in a compilation unit in Rakudo

2014-10-14 Thread Christian Bartolomaeus via RT
I added tests to S04-statements/terminator.t with the following commit: https://github.com/perl6/roast/commit/1c4c5355d9

[perl #116182] [BUG] 's;' wrongly parsed as subroutine call in Rakudo

2014-10-15 Thread Christian Bartolomaeus via RT
I added two tests (for parsing s; and m;) to S02-names-vars/names.t with the following commit: https://github.com/perl6/roast/commit/9cafef7ce7

[perl #117045] [BUG] Guillemet form of subscript parses as infix hyperop in Rakudo

2014-10-15 Thread Christian Bartolomaeus via RT
I agree with Mouq and after adding a test to S03-operators/misc.t with commit https://github.com/perl6/roast/commit/1e08ea21cc I'm now closing the ticket.

[perl #117097] [BUG] say $!.WHAT fails in CATCH block

2014-10-15 Thread Christian Bartolomaeus via RT
say $!.WHAT in CATCH block no longer dies, but it gives Nil. The exception is available in $_: $ perl6-m -e '{ die 42; CATCH { say $!.WHAT; say $_.perl } }' Nil X::AdHoc.new(payload = 42) 42 in block unit at -e:1 S04/Exception handlers says An exception handler is just a switch statement on

[perl #117465] [BUG] unspace after unspace causes error message which (erroneously) expects unspace in Rakudo

2014-10-15 Thread Christian Bartolomaeus via RT
As the tests in S02-lexical-conventions/unspace.t run fine, I'm closing this ticket.

[perl #117695] It is possible to alias ... by using the term syntactic category -- broken

2014-10-15 Thread Christian Bartolomaeus via RT
This now dies with Term definition requires an initializer: $ perl6-m -e 'my \term:a = 1;' ===SORRY!=== Error while compiling -e Term definition requires an initializer at -e:1 -- my \term⏏:a = 1; expecting any of: scoped declarator It works with STD: $ viv -c -e 'my \term:a =

[perl #117773] [BUG] KeyBag accepts non-UInt values in Rakudo

2014-10-15 Thread Christian Bartolomaeus via RT
This has changed. The former KeyBag is a BagHash now and the code snippet no longer generates a key a with a value b. Instead it generates a key of type Pair (a = b) with the corresponding value 1: $ perl6-m -e 'my $a = BagHash.new( (a=b) ); for $a.kv - $key, $val { say $key, isa ,

[perl #117915] [BUG] X metaoperator fails with bag keys

2014-10-15 Thread Christian Bartolomaeus via RT
This works now (on Moar, Parrot and JVM): $ perl6 -e 'my Bag $bag .= new: foo foo bar; for $bag.keys X $bag.keys - $a, $b { say $a, $b }' foofoo foobar barfoo barbar I added a test to S02-types/bag.t with the following commit: https://github.com/perl6/roast/commit/245c5988e7

[perl #117997] [BUG] STD warns about no-argument use of 'set' listop, Rakudo doesn't

2014-10-15 Thread Christian Bartolomaeus via RT
Rakudo (on Moar, Parrot and JVM) now gives the same error as STD: $ perl6 -e 'set;' ===SORRY!=== Error while compiling -e The 'set' listop may not be called without arguments (please use () or whitespace to clarify) at -e:1 -- set⏏; expecting any of: argument list $ perl6 -e

[perl #118029] Stash.new creates Hash, not a Stash

2014-10-15 Thread Christian Bartolomaeus via RT
I added tests to S02-types/declare.t and S02-types/stash.t with the following commit: https://github.com/perl6/roast/commit/658c9604e7 Since the latter file is not yet included in Rakudo's t/spectest.data I'll leave the ticket open until that is done.

[perl #117773] [BUG] KeyBag accepts non-UInt values in Rakudo

2014-10-15 Thread Christian Bartolomaeus via RT
I added a test for the first example to S02-types/baghash.t with the following commit: https://github.com/perl6/roast/commit/502f2ca59d After staring at it for a while I'm no longer convinced that the following should result in an empty BagHash: $ perl6-m -e 'my $a = BagHash.new( a=b ); say

[perl #117773] [BUG] KeyBag accepts non-UInt values in Rakudo

2014-10-15 Thread Christian Bartolomaeus via RT
FROGGS explained on #perl6 why the empty BagHash is correct: FROGGS bartolin: the bare a will result in a named argument, where the quoted a will construct a pair and pass that FROGGS bartolin: and methods (like .new in this case) happily eat named (optional by default) arguments, which is

[perl #118063] [BUG] comma (wrongly) required between parameter with default value and returns-arrow ('--') in Rakudo

2014-10-15 Thread Christian Bartolomaeus via RT
This works now without the comma: $ perl6-m -e 'sub a ( $a=1 -- Hash ) { say $a; my %h }; say a(2)' 2 ^^ empty string here ;-) I added a test to S06-signature/defaults.t with the following commit: https://github.com/perl6/roast/commit/4485db4547

[perl #118075] [BUG] $, in list interpreted as '$,' variable rather than bare sigil $ + comma

2014-10-15 Thread Christian Bartolomaeus via RT
This works now: $ perl6-m -e 'my ($a, $c); ($a, $ , $c) = 1..3; say $a; say $c' 1 3 Also, S02 was modified recently (https://github.com/perl6/specs/commit/aadf0589905c9d76488fd81f738201d12f6d9eeb) and the new version explicitly allows the use of ($a, $, $c) = 1..3; I added a test to

[perl #114696] [BUG] $_ variable disappears after Rakudo sees block in for @array - $variable {}

2014-10-16 Thread Christian Bartolomaeus via RT
Since this works as expected, I added a test to S04-declarations/implicit-parameter.t with the following commit: https://github.com/perl6/roast/commit/7192d95e4b and I'm closing this ticket.

[perl #118231] Importing the same thing twice shouldn't bomb

2014-10-16 Thread Christian Bartolomaeus via RT
Since it's now possible to import the same thing twice, I added a test to S11-modules/import.t with the following commit: https://github.com/perl6/roast/commit/02a309ec81 and I'm closing the ticket.

[perl #118067] [BUG] Null PMC access when calling .new on a subclass with a proto overriding the regular .new in Rakudo

2014-10-16 Thread Christian Bartolomaeus via RT
Just an update: There is no longer a Null PMC access error, but Rakudo complains about no matching signature: $ perl6-m -e 'class A is Any { proto method new($) {*} }; A.new(now)' Cannot call 'new'; none of these signatures match: in block unit at -e:1 $ perl6-p -e 'class A is Any { proto

[perl #118581] [BUG] Segfault for a signature match with a native type and an 'as' cast in Rakudo

2014-10-16 Thread Christian Bartolomaeus via RT
This no longer segfaults but gives False (on Moar, Parrot and JVM): $ perl6 -e 'say \(1) ~~ :(int $x as Str)' False Is that smart match supposed to return True? (For the tests it would be nice to check for the correct result and not only whether it lives_ok.)

[perl #119061] .push and .unshift do not do typechecks

2014-10-16 Thread Christian Bartolomaeus via RT
Since this works now I've added 3 tests to S09-typed-arrays/arrays.t with the following commit: https://github.com/perl6/roast/commit/ece637835e For the last example (my Int @a=foo bar;) there was already a test (written for ticket 114968). I'm closing this ticket now.

[perl #118875] [BUG] 'where' clause followed by (non-parenthesized) expression with '' in it doesn't parse in parameter list in Rakudo

2014-10-16 Thread Christian Bartolomaeus via RT
This parses now (on Moar, Parrot and JVM): $ perl6 -e 'sub ndr($r where ($r ||= 10) 0 1) { }; say alive' alive I added a test to S06-other/misc.t with the following commit: https://github.com/perl6/roast/commit/aeed867f01 and I'm closing the ticket.

[perl #75858] [BUG] Can't use a where clause on an attribute without surrounding name and where clause in parentheses in Rakudo

2014-10-16 Thread Christian Bartolomaeus via RT
All of the above parses now (on Moar, Parrot and JVM): $ perl6 -e 'class A { has ($.x where 1) }; say alive' alive $ perl6 -e 'class A { has $.x where 1 }; say alive' alive $ perl6-m -e 'class A { has $x where 1; }; say alive' alive $ perl6 -e 'class A { has Int $.color where 1|2; }; say

[perl #119215] [BUG] empty-list adverb on literal hash yields LTA, too-internal error message in Rakudo

2014-10-16 Thread Christian Bartolomaeus via RT
The error message is no longer too internal, but is it adequate enough? $ perl6-m -e '{}:' ## identical error with perl6-p ===SORRY!=== This type does not support positional operations $ perl6-j -e '{}:' ===SORRY!=== java.lang.RuntimeException: This type does not support positional

[perl #118755] [BUG] .grep 'is rw' but .first isn't in Rakudo

2014-10-16 Thread Christian Bartolomaeus via RT
This works now: $ perl6-m -e 'my @a = 1..10; @a.first(* %% 2).++; say @a' 1 3 3 4 5 6 7 8 9 10 I added a test for this (and for the example with grep) to S32-list/first.t and S32-list/grep.t, respectively, with the following commit: https://github.com/perl6/roast/commit/4295bfcfae

[perl #120232] [BUG] sprintf doesn't format %floats with many significant digits properly

2014-10-17 Thread Christian Bartolomaeus via RT
This works for Moar, Parrot and JVM: $ perl6 -e 'printf(%.50f, 1.115)' 1.115000 I added a test to S32-str/sprintf.t with the following commit: https://github.com/perl6/roast/commit/46ef5bf0e9. I'm closing the ticket.

[perl #120397] [BUG] Segfault (Moar, JVM) and Null PMC access (Parrot) when assigning to a variable declared in a subsignature in a variable declaration in Rakudo

2014-10-17 Thread Christian Bartolomaeus via RT
Status update: Right now this is no longer a Null PMC access error on Parrot but we get a segfault on Moar as well: $ perl6-m -e 'my $a ($b, $c); $b = 42;' Segmentation fault $ perl6-p -e 'my $a ($b, $c); $b = 42;' Cannot assign to an immutable value in block unit at -e:1 $ perl6-j -e 'my $a

[perl #120380] [BUG] Something is extremely slow with a look with string concat in Rakudo on the JVM

2014-10-17 Thread Christian Bartolomaeus via RT
To me it looks like the loop and the string concat are okay-ish (this is on a not too beefy machine (i3 3.33 GHz, 8 GiB RAM): $ perl6-m -e 'my $file = ; for ^2 {$file ~= $_;};' real0m0.500s user0m0.436s sys 0m0.060s $ perl6-p -e 'my $file = ; for ^2 {$file ~= $_;};' real

[perl #120529] [BUG] qx// and run() do not respect %*ENV change in rakudo-parrot

2014-10-17 Thread Christian Bartolomaeus via RT
This works fine with Moar and JVM, but is still an issue with Parrot: $ perl6-m -e '%*ENVENV_TEST=foo; say qx/env/ ~~ /ENV_TEST/' ## same result with perl6-j 「ENV_TEST」 $ perl6-p -e '%*ENVENV_TEST=foo; say qx/env/ ~~ /ENV_TEST/' Nil I added a test (fudged 'todo' for Parrot) to

[perl #120838] [BUG] LTA error message (on JVM) when passing something to named parameter :$b($c)

2014-10-17 Thread Christian Bartolomaeus via RT
Status update: It looks like STD's opinion on this has changed: $ viv -c -e 'sub a (:$b($c)) {say $c}; a(:bfoo)' ===SORRY!=== Subsignature not allowed after named parameter; please insert whitespace at (eval) line 1: -- sub a (:$b⏏($c)) {say $c}; a(:bfoo) Parse failed Rakudo's error

[perl #120919] [BUG] Private methods in roles don't bind 'self' correctly in Rakudo

2014-10-17 Thread Christian Bartolomaeus via RT
This works on Moar but fails on Parrot and JVM: $ perl6-m -e 'role A { method pub { self!priv }; method !priv () { say OH HAI } }; class C does A { }; C.new.pub;' OH HAI $ perl6-p -e 'role A { method pub { self!priv }; method !priv () { say OH HAI } }; class C does A { }; C.new.pub;' Cannot

[perl #120931] [BUG] Infinite recursion when calling a role method from within the role block in Rakudo

2014-10-17 Thread Christian Bartolomaeus via RT
This works now: $ perl6-m -e 'role R { method foo {}; R.foo }; say alive' alive $ perl6-p -e 'role R { method foo {}; R.foo }; say alive' alive $ perl6-j -e 'role R { method foo {}; R.foo }; say alive' alive I added a test to S14-roles/basic.t with the following commit:

[perl #121802] Lazy series failure on jvm - prime example from 2012 advent day 14

2014-10-17 Thread Christian Bartolomaeus via RT
The tests are now passing on JVM. I unfudged them with the following commit: https://github.com/perl6/roast/commit/741b08ee70

[perl #121722] for 42 {NEXT (state $val) = $_} # fails on MOAR

2014-10-17 Thread Christian Bartolomaeus via RT
Hmm, it looks like that was not all -- or there is a new problem. $ perl6-m -e 'for 42 {NEXT (state $val) = $_}; say alive' alive This does not fail any longer. But the tests in integration/advent2012-day15.t don't pass. I'd say the following command shows more: $ perl6-m -e 'for 42 {NEXT

[perl #121719] [BUG] -p busted on Moar in Rakudo

2014-10-20 Thread Christian Bartolomaeus via RT
This seems to work now: $ echo This is cool | ./perl6-m -p -e 's/cool/nice/' This is nice $ echo This is cool | ./perl6-p -p -e 's/cool/nice/' This is nice $ echo This is cool | ./perl6-j -p -e 's/cool/nice/' This is nice Since there is also a similiar test in

[perl #122313] [parrot] Failures in S06-routine-modifiers/lvalue-subroutines.t

2014-10-20 Thread Christian Bartolomaeus via RT
I tried to golf this down and got the following on Parrot (it runs on Moar and JVM): $ perl6-p -e 'Proxy.new( FETCH = sub ($var) { 42 } );' Segmentation fault The next three commands are okay: $ perl6-p -e 'Proxy.new( FETCH = sub ($) { 42 } ); say alive' alive $ perl6-p -e 'Proxy.new( FETCH =

[perl #122319] [BUG] S32-temporal/local.t tests are excluded on most systems

2014-10-20 Thread Christian Bartolomaeus via RT
AFAIU this was fixed with the following commit, which explicitly sets the timezone to America/New_York: https://github.com/perl6/roast/commit/04d38c8a3cc04519dfd213c6281186cbd67cce51 If that was not what you meant, please reopen the ticket.

[perl #121990] [NYI] Can't smartmatch a DateTime against a Date

2014-10-20 Thread Christian Bartolomaeus via RT
On Wed Jul 30 10:59:43 2014, duff wrote: On Fri May 30 08:20:25 2014, masak wrote: BenGoldberg Woodi, a Date is like today, or tommorroy, or June 4, 1977 BenGoldberg A DateTime is like Friday May 30, 2014 11:11 AM and 3.141592 seconds. masak Woodi: though not strictly necessary, Date is

[perl #121994] Array receives an empty itemized list

2014-10-20 Thread Christian Bartolomaeus via RT
This also works now on Moar: $ perl6-m -e 'my @a; @a.push: $(one,two,three.split(,)); say @a;' one two three There was a test added to S02-types/lazy-lists.t with the following commit: https://github.com/perl6/roast/commit/6538a38cfe5492fc65412440e56a46c3163fb6f9 I just fudged the test for

  1   2   3   4   5   6   7   >