Re: [perl #127682] [OSX] writing more than 8192 bytes to IO::Handle causes it to hang forever

2018-03-07 Thread Lloyd Fournier via RT
When I filed this ticket I kinda expected that somehow rakudo or libuv would handle this for me under the hood. But what Timo and Brandon say makes sense. The process is still running when you slurp-rest. slurp-rest neds EOF before it stops blocking. It will never get it because the writing process

Re: [perl #127682] [OSX] writing more than 8192 bytes to IO::Handle causes it to hang forever

2018-03-07 Thread Lloyd Fournier
When I filed this ticket I kinda expected that somehow rakudo or libuv would handle this for me under the hood. But what Timo and Brandon say makes sense. The process is still running when you slurp-rest. slurp-rest neds EOF before it stops blocking. It will never get it because the writing process

Re: Naming debate- what's the location for it?

2018-02-16 Thread Lloyd Fournier
I'm about to publish some blog posts with using Perl 6 to demonstrate some cryptographic primitives. I was thinking about calling it "rakudo" to at least intrigue people and make them google it. Couldn't we call the language rakudo and the implementation nqp-rakudo? (ie a rakudo implementation in

Re: [perl #132512] [REGRESSION] make in regex on uncomposed type results in Nil

2017-11-27 Thread Lloyd Fournier via RT
Changing uncomposed type objects to Nil for the specific case of .ast/.made is definitely incorrect IMO. It happens for the exact reason lizmat said in her commit: "Wish there was a better way to test for NQPMu though, as this will prevent type objects being properly propagated" Although it looks

Re: [perl #132512] [REGRESSION] make in regex on uncomposed type results in Nil

2017-11-27 Thread Lloyd Fournier
Changing uncomposed type objects to Nil for the specific case of .ast/.made is definitely incorrect IMO. It happens for the exact reason lizmat said in her commit: "Wish there was a better way to test for NQPMu though, as this will prevent type objects being properly propagated" Although it looks

Re: [perl #132512] [REGRESSION] make in regex on uncomposed type results in Nil

2017-11-27 Thread Lloyd Fournier
Good point. Here "No such method 'gist' for invocant of type 'Foo' in block at /tmp/aR11azfzlJ line 1" is the right one. This will give True/False indicating correct/incorrect: my $new_type := Metamodel::ClassHOW.new_type(:name); my $r = / . { $/.make($new_type) } /; my $m = "a" ~~ $r; note $m

Re: [perl #132512] [REGRESSION] make in regex on uncomposed type results in Nil

2017-11-27 Thread Lloyd Fournier via RT
Good point. Here "No such method 'gist' for invocant of type 'Foo' in block at /tmp/aR11azfzlJ line 1" is the right one. This will give True/False indicating correct/incorrect: my $new_type := Metamodel::ClassHOW.new_type(:name); my $r = / . { $/.make($new_type) } /; my $m = "a" ~~ $r; note $m

Re: [perl #127020] [PERF] pod parsing memory is never freed

2017-11-27 Thread Lloyd Fournier
Probably one of a number of things that would be easy if we made pod another language on the braid :) On Mon, Nov 27, 2017 at 11:59 AM Timo Paulssen via RT < perl6-bugs-follo...@perl.org> wrote: > a look at a profile makes me suspect the problem is having > pod_string_character match a single cha

Re: [perl #127020] [PERF] pod parsing memory is never freed

2017-11-27 Thread Lloyd Fournier via RT
Probably one of a number of things that would be easy if we made pod another language on the braid :) On Mon, Nov 27, 2017 at 11:59 AM Timo Paulssen via RT < perl6-bugs-follo...@perl.org> wrote: > a look at a profile makes me suspect the problem is having > pod_string_character match a single cha

Re: [perl #130982] [PERF] "for $a..$b -> $i { ... }" loops are sometimes much slower than c-style loops

2017-11-19 Thread Lloyd Fournier
probably close this RT. Seeing as the issue in the title has been addressed kinda :P LL On Sun, Nov 19, 2017 at 1:05 PM Daniel Green via RT < perl6-bugs-follo...@perl.org> wrote: > On Sun, 12 Mar 2017 07:27:37 -0700, allber...@gmail.com wrote: > > On Sun, Mar 12, 2017 at 12:48 AM,

Re: [perl #130982] [PERF] "for $a..$b -> $i { ... }" loops are sometimes much slower than c-style loops

2017-11-19 Thread Lloyd Fournier via RT
probably close this RT. Seeing as the issue in the title has been addressed kinda :P LL On Sun, Nov 19, 2017 at 1:05 PM Daniel Green via RT < perl6-bugs-follo...@perl.org> wrote: > On Sun, 12 Mar 2017 07:27:37 -0700, allber...@gmail.com wrote: > > On Sun, Mar 12, 2017 at 12:48 AM,

Re: [perl #132085] [REGRESSION] Possible regression after Match.(made|ast) changes

2017-09-13 Thread Lloyd Fournier via RT
I think we can close this. It's most likely an internals change because I call nqp::setparameterizer() directly. I'll figure out what the problem is eventually and if I can't fix it myself I'll open a more concise RT. Cheers LL On Thu, Sep 14, 2017 at 1:27 PM Aleks-Daniel Jakimenko-Aleksejev < p

Re: [perl #132085] [REGRESSION] Possible regression after Match.(made|ast) changes

2017-09-13 Thread Lloyd Fournier
I think we can close this. It's most likely an internals change because I call nqp::setparameterizer() directly. I'll figure out what the problem is eventually and if I can't fix it myself I'll open a more concise RT. Cheers LL On Thu, Sep 14, 2017 at 1:27 PM Aleks-Daniel Jakimenko-Aleksejev < p

Re: [perl #127858] [BUG] "Cannot invoke this object" error while importing an array constant

2017-07-26 Thread Lloyd Fournier
Fix reverted: https://github.com/rakudo/rakudo/commit/50d38a1f368f0addb601e857232642f3a8de3aa2 should be re-opened :) On Tue, Jul 25, 2017 at 11:45 PM Lloyd Fournier via RT < perl6-bugs-follo...@perl.org> wrote: > merged patch: https://github.com/rakudo/rakudo/pull/ >

Re: [perl #127858] [BUG] "Cannot invoke this object" error while importing an array constant

2017-07-26 Thread Lloyd Fournier via RT
Fix reverted: https://github.com/rakudo/rakudo/commit/50d38a1f368f0addb601e857232642f3a8de3aa2 should be re-opened :) On Tue, Jul 25, 2017 at 11:45 PM Lloyd Fournier via RT < perl6-bugs-follo...@perl.org> wrote: > merged patch: https://github.com/rakudo/rakudo/pull/ >

Re: [perl #131705] constant Regex: getlex: outer index out of range

2017-07-26 Thread Lloyd Fournier via RT
Fix reverted: https://github.com/rakudo/rakudo/commit/50d38a1f368f0addb601e857232642f3a8de3aa2 should be re-opened :) On Tue, Jul 25, 2017 at 11:42 PM Lloyd Fournier via RT < perl6-bugs-follo...@perl.org> wrote: > merged patch: https://github.com/rakudo/rakudo/pull/ >

Re: [perl #131705] constant Regex: getlex: outer index out of range

2017-07-26 Thread Lloyd Fournier
Fix reverted: https://github.com/rakudo/rakudo/commit/50d38a1f368f0addb601e857232642f3a8de3aa2 should be re-opened :) On Tue, Jul 25, 2017 at 11:42 PM Lloyd Fournier via RT < perl6-bugs-follo...@perl.org> wrote: > merged patch: https://github.com/rakudo/rakudo/pull/ >

Re: [perl #127858] [BUG] "Cannot invoke this object" error while importing an array constant

2017-07-25 Thread Lloyd Fournier via RT
merged patch: https://github.com/rakudo/rakudo/pull/ tests: https://github.com/perl6/roast/pull/291/files can be closed On Fri, Apr 8, 2016 at 7:16 PM grond...@yahoo.fr < perl6-bugs-follo...@perl.org> wrote: > # New Ticket Created by grond...@yahoo.fr > # Please include the string: [perl #1

Re: [perl #127858] [BUG] "Cannot invoke this object" error while importing an array constant

2017-07-25 Thread Lloyd Fournier
merged patch: https://github.com/rakudo/rakudo/pull/ tests: https://github.com/perl6/roast/pull/291/files can be closed On Fri, Apr 8, 2016 at 7:16 PM grond...@yahoo.fr < perl6-bugs-follo...@perl.org> wrote: > # New Ticket Created by grond...@yahoo.fr > # Please include the string: [perl #1

Re: [perl #131705] constant Regex: getlex: outer index out of range

2017-07-25 Thread Lloyd Fournier via RT
merged patch: https://github.com/rakudo/rakudo/pull/ tests: https://github.com/perl6/roast/pull/291/files can be closed On Wed, Jul 5, 2017 at 3:42 PM Lloyd Fournier wrote: > # New Ticket Created by Lloyd Fournier > # Please include the string: [perl #131705] > # in the subjec

Re: [perl #131705] constant Regex: getlex: outer index out of range

2017-07-25 Thread Lloyd Fournier
merged patch: https://github.com/rakudo/rakudo/pull/ tests: https://github.com/perl6/roast/pull/291/files can be closed On Wed, Jul 5, 2017 at 3:42 PM Lloyd Fournier wrote: > # New Ticket Created by Lloyd Fournier > # Please include the string: [perl #131705] > # in the subjec

Re: [perl #131781] :?smth should construct a truthy pair (say (:?foo))

2017-07-22 Thread Lloyd Fournier
2¢: ? doesn't imply truth it implies a question. The ? prefix asks an expression whether it's True or False. When used as a sigil like $?FILE it's asking the compiler about something. ‘:foo’ sets foo to True. ‘:!foo’ sets it to False. ‘:?foo’ looks like it's trying to ask something a question, but

Re: [perl #131781] :?smth should construct a truthy pair (say (:?foo))

2017-07-22 Thread Lloyd Fournier via RT
2¢: ? doesn't imply truth it implies a question. The ? prefix asks an expression whether it's True or False. When used as a sigil like $?FILE it's asking the compiler about something. ‘:foo’ sets foo to True. ‘:!foo’ sets it to False. ‘:?foo’ looks like it's trying to ask something a question, but

Re: [perl #131781] :?smth should construct a truthy pair (say (:?foo))

2017-07-22 Thread Lloyd Fournier via RT
Sorry for being think but what is say (:?foo); meant to do? The OP just says it should "work". On Sun, Jul 23, 2017 at 6:05 AM Aleks-Daniel Jakimenko-Aleksejev via RT < perl6-bugs-follo...@perl.org> wrote: > sub foo($bar!) { say $bar }; foo(42) > > On 2017-07-22 11:19:41, alex.jakime...@gmail.com

Re: [perl #131781] :?smth should construct a truthy pair (say (:?foo))

2017-07-22 Thread Lloyd Fournier
Sorry for being think but what is say (:?foo); meant to do? The OP just says it should "work". On Sun, Jul 23, 2017 at 6:05 AM Aleks-Daniel Jakimenko-Aleksejev via RT < perl6-bugs-follo...@perl.org> wrote: > sub foo($bar!) { say $bar }; foo(42) > > On 2017-07-22 11:19:41, alex.jakime...@gmail.com

Re: [perl #131774] [PERF] Simple, if artificial, string concatenation example hogs memory and time

2017-07-20 Thread Lloyd Fournier
I did an experiment a while ago and found that string concatenation in a loop was Ο(n²) in rakudo. I asked about it on irc and jnthn explained to me that this was expected because strings are immutable (and therefore wasn't worth RTing): https://irclog.perlgeek.de/perl6/2015-12-15#i_11720228 (some

Re: [perl #131774] [PERF] Simple, if artificial, string concatenation example hogs memory and time

2017-07-20 Thread Lloyd Fournier via RT
I did an experiment a while ago and found that string concatenation in a loop was Ο(n²) in rakudo. I asked about it on irc and jnthn explained to me that this was expected because strings are immutable (and therefore wasn't worth RTing): https://irclog.perlgeek.de/perl6/2015-12-15#i_11720228 (some

Re: Version of a Module

2017-07-04 Thread Lloyd Fournier
It is a bug. It's because of the way require is implemented at the moment is a little rough. The first one is asking for the .^ver of a stub package require has inserted. ::("Bailador").ver should work. LL On Wed, Jul 5, 2017 at 4:46 AM Martin Barth wrote: > Hi there, > > is this a bug? > > > p

Re: [perl #131681] default values in subsignitures don't work

2017-07-03 Thread Lloyd Fournier via RT
That makes sense. Thank you! On Mon, Jul 3, 2017 at 8:09 PM jn...@jnthn.net via RT < perl6-bugs-follo...@perl.org> wrote: > On Fri, 30 Jun 2017 06:41:35 -0700, lloyd.fo...@gmail.com wrote: > > sub foo( %h ( :$foo = "bar", :$baz) ) { > > %h; > > } > > > > note foo( { :baz } ); #-> {baz => Tru

Re: [perl #131681] default values in subsignitures don't work

2017-07-03 Thread Lloyd Fournier
That makes sense. Thank you! On Mon, Jul 3, 2017 at 8:09 PM jn...@jnthn.net via RT < perl6-bugs-follo...@perl.org> wrote: > On Fri, 30 Jun 2017 06:41:35 -0700, lloyd.fo...@gmail.com wrote: > > sub foo( %h ( :$foo = "bar", :$baz) ) { > > %h; > > } > > > > note foo( { :baz } ); #-> {baz => Tru

Re: not enough memory

2017-06-29 Thread Lloyd Fournier
I'm not sure if it's related but I've been getting a few weird memory related issues with HEAD and zef. e.g my travis build just segfaulted: https://travis-ci.org/spitsh/spitsh/builds/248242106#L1355 And a day or so ago I got: "MoarVM panic: Heap corruption detected: pointer 0x7f0fe9a16410 to pa

Re: Version of a Module

2017-06-27 Thread Lloyd Fournier
Hi Martin, AFAIK you can only do this with hacks atm. It's different if the module is installed or if you are in the source directory doing pelr6 -Ilib. I do this in my own module here: https://github.com/spitsh/spitsh/blob/master/lib/Spit/Util.pm6#L61 LL On Wed, Jun 28, 2017 at 7:14 AM Martin

Re: [perl #131584] [REGERSSION] EXPORTHOW SUPERSEDE/DECLARE Cannot invoke this object

2017-06-16 Thread Lloyd Fournier via RT
Ohh and now we have toast: https://toast.perl6.party/ Which shows maybe it was: 2017.05-394-g56e71d5 On Fri, Jun 16, 2017 at 10:13 PM Lloyd Fournier < perl6-bugs-follo...@perl.org> wrote: > # New Ticket Created by Lloyd Fournier > # Please include the string: [perl #131584

Re: [perl #131584] [REGERSSION] EXPORTHOW SUPERSEDE/DECLARE Cannot invoke this object

2017-06-16 Thread Lloyd Fournier
Ohh and now we have toast: https://toast.perl6.party/ Which shows maybe it was: 2017.05-394-g56e71d5 On Fri, Jun 16, 2017 at 10:13 PM Lloyd Fournier < perl6-bugs-follo...@perl.org> wrote: > # New Ticket Created by Lloyd Fournier > # Please include the string: [perl #131584

Re: [perl #131583] [BUG] Sort content of ^methods

2017-06-15 Thread Lloyd Fournier
Str.^methods.sort(*.name) Is easy enough once you know to do it :) I don't think we should specify a particular order for the returned methods and alphabetic sorting is kinda arbitrary. Why not sorted by class inheritance for example? On Fri, Jun 16, 2017 at 2:09 PM Gabor Szabo wrote: > # New T

Re: [perl #131583] [BUG] Sort content of ^methods

2017-06-15 Thread Lloyd Fournier via RT
Str.^methods.sort(*.name) Is easy enough once you know to do it :) I don't think we should specify a particular order for the returned methods and alphabetic sorting is kinda arbitrary. Why not sorted by class inheritance for example? On Fri, Jun 16, 2017 at 2:09 PM Gabor Szabo wrote: > # New T

Re: [perl #131528] [PRECOMP] Issues when sub itself instead of its "dispatcher" used in sub EXPORT

2017-06-08 Thread Lloyd Fournier via RT
I think this is just another example of the compile time closures problem since EXPORT runs at compile time in during the loading module's compilation. https://rt.perl.org/Public/Bug/Display.html?id=128636 For an example in my own code: https://github.com/spitsh/spitsh/blob/master/lib/Spit/Const

Re: [perl #131528] [PRECOMP] Issues when sub itself instead of its "dispatcher" used in sub EXPORT

2017-06-08 Thread Lloyd Fournier
I think this is just another example of the compile time closures problem since EXPORT runs at compile time in during the loading module's compilation. https://rt.perl.org/Public/Bug/Display.html?id=128636 For an example in my own code: https://github.com/spitsh/spitsh/blob/master/lib/Spit/Const

Re: ding!

2017-05-31 Thread Lloyd Fournier
perl6 -e 'say "\a"' Will print the alarm character which causes an annoying sound on my mac. Other than that, you'll have to investigate the module ecosystem or shell out to something. LL On Thu, Jun 1, 2017 at 1:24 PM ToddAndMargo wrote: > Hi All, > > Does Perl 6 have a build in "ding" sound

Re: slightly unexpected JSON roundtrip for arrays

2017-05-31 Thread Lloyd Fournier
It is the expected behaviour. The problem isn't what from-json is returning but what kind of assignment you're doing to the result. Here's a simple version: my @a = $[1,2,3]; say @a # [[1 2 3]] Since from-json doesn't know what it's returning, (a string, a hash, an array) it returns whatever it

Re: Absolute path to directory of the current perl program

2017-05-27 Thread Lloyd Fournier
After thinking about what Zoffix said, probably what you're meant to do is: $*PROGRAM.parent.absolute Which leaves the stringification (.absolute) until last. On Sun, May 28, 2017 at 4:04 PM Lloyd Fournier wrote: > FYI: > > 15:57 < llfourn> Zoffix: is there any plan

Re: Absolute path to directory of the current perl program

2017-05-27 Thread Lloyd Fournier
object either. > > Gabor > > > On Sat, May 27, 2017 at 6:48 PM, Lloyd Fournier > wrote: > > I'd use > > > > $*PROGRAM.absolute.IO.dirname > > > > I'm not sure why .absolute doesn't return an IO::Path object. Maybe > that's >

Re: Absolute path to directory of the current perl program

2017-05-27 Thread Lloyd Fournier
I'd use $*PROGRAM.absolute.IO.dirname I'm not sure why .absolute doesn't return an IO::Path object. Maybe that's being addressed as part of Zoffix++'s IO work. On Sat, May 27, 2017 at 10:07 PM Gabor Szabo wrote: > I came up with this: > > say $*PROGRAM-NAME.IO.absolute.IO.dirname; > > but I wo

Re: [perl #131324] Inheriting from lexical classes seems borked

2017-05-18 Thread Lloyd Fournier via RT
FWIW theoretically you get at any 'my' symbol in another module through the compunit interface by getting the CompUnit::Handle and using the '.unit' method to get the top lexpad of the loaded module. On Fri, May 19, 2017 at 8:20 AM Zoffix Znet via RT < perl6-bugs-follo...@perl.org> wrote: > To

Re: [perl #131324] Inheriting from lexical classes seems borked

2017-05-18 Thread Lloyd Fournier
FWIW theoretically you get at any 'my' symbol in another module through the compunit interface by getting the CompUnit::Handle and using the '.unit' method to get the top lexpad of the loaded module. On Fri, May 19, 2017 at 8:20 AM Zoffix Znet via RT < perl6-bugs-follo...@perl.org> wrote: > To

Re: Parse a string into a regex?

2017-05-12 Thread Lloyd Fournier
Patrick's answer of <$regex-interpolation> is the one I'd use. Although it checks a few possibly malicious things it doesn't catch everything: https://rt.perl.org/Public/Bug/Display.html?id=131079 On Fri, May 12, 2017 at 5:11 PM Andreas Mueller < andreas.muel...@biologie.uni-osnabrueck.de> wrote:

Re: [perl #131118] Junctions that can evaluate to True shouldn't blow up for items that won't

2017-04-08 Thread Lloyd Fournier
Thanks for doing that experiment. Not sure why the code breaks. But yeah on second thought it was a bad idea. If something accepts a Mu in its signature it should probably be given a Mu even with ~~. LL On Sat, Apr 8, 2017 at 12:58 PM Zoffix Znet via RT < perl6-bugs-follo...@perl.org> wrote: > O

Re: [perl #131118] Junctions that can evaluate to True shouldn't blow up for items that won't

2017-04-07 Thread Lloyd Fournier
The correct way to do this is any(5,"flarg") ~~ 5. ~~ is very tolerant. I think it's generally considered a bug anytime ~~ throws an exception because of invalid LHS. IMO any() junctions should propagate exceptions regardless of whether one of its other values succeeded. I tried to think of how I

Re: [perl #131106] [BUG] Code.ACCEPTS not raw enough

2017-04-06 Thread Lloyd Fournier
Tests were merged here: https://github.com/perl6/roast/commit/c0870cab72b75bfd66580b5248d9465edc4fea04 On Thu, Apr 6, 2017 at 6:18 PM Elizabeth Mattijsen via RT < perl6-bugs-follo...@perl.org> wrote: > Fixed with c0eb9bd10f , tests needed > > > On 6 Apr 2017, at 05:48, Lloy

Re: [perl #131092] [REGEX] Alternation fails matching the same token on either side

2017-04-05 Thread Lloyd Fournier
Ah woops. I thought I was testing it without grammar tracer as well. Thanks for clearing that up for me :) On Tue, Apr 4, 2017 at 10:27 PM Zoffix Znet via RT < perl6-bugs-follo...@perl.org> wrote: > On Sun, 02 Apr 2017 19:19:11 -0700, lloyd.fo...@gmail.com wrote: > > use Grammar::Tracer; > > gram

Re: Interactive terminal modules?

2017-03-28 Thread Lloyd Fournier
https://github.com/azawawi/perl6-ncurses https://github.com/kuerbis/Term-Choose-p6 Have you seen those? On Wed, Mar 29, 2017 at 1:28 PM Chris Ramsey wrote: > I've been googling a bunch but can't find diddly for creating ncurses > style interactive terminals in Perl 6. > > Sorry for such a vague

Re: Fwd: Re: Variables in modules

2017-03-15 Thread Lloyd Fournier
Since $?FILE in modules is being discussed I'll just leave this RT here: https://rt.perl.org/Public/Bug/Display.html?id=128442 On Thu, Mar 16, 2017 at 4:50 AM JuhiMarcel LangbroekTimmerman < mt195...@gmail.com> wrote: > In the perl doc of IO, IO::Path etc. The type is $?File.IO.WHAT to search >

Re: [perl #130982] [PERF] "for $a..$b -> $i { ... }" loops are sometimes much slower than c-style loops

2017-03-11 Thread Lloyd Fournier
If you think that discrepancy is impressive you're going to love this. I added a version to your example using native ints: https://gist.github.com/LLFourn/8c3e895e789fab957355ce23c9420133 bash-3.2$ perl6 native-int-perf.p6 perl6-loop: 84.8739988 c-loop: 67.65849241 (1.25 times faster) native-loop

Re: mocking Proc

2017-02-27 Thread Lloyd Fournier
Ah nice. Wrapping &shell makes more sense than augmenting Proc anyway. LL On Tue, Feb 28, 2017 at 4:22 AM Brian Duggan wrote: > On Monday, February 27, Brian Duggan wrote: > > I tried numerous variants with multis and signatures that match the > > existing signatures, but didn't have any succ

Re: mocking Proc

2017-02-27 Thread Lloyd Fournier
Hmm, You will have to use augment in this case I think: https://docs.perl6.org/syntax/augment Augment Proc with your own shell method and &shell should call it. On Tue, 28 Feb 2017 at 1:59 am, Brian Duggan wrote: > On Monday, February 27, Lloyd Fournier wrote: > > Do you

Re: mocking Proc

2017-02-27 Thread Lloyd Fournier
I was thinking just do: 'sub shell(...) is export { }'. And then 'use MyCrazyShell;' in module.pm. Do you mean without modifying module.pm? LL On Tue, Feb 28, 2017 at 1:46 AM Brian Duggan wrote: > On Monday, February 27, Lloyd Fournier wrote: > > I'd do th

Re: mocking Proc

2017-02-27 Thread Lloyd Fournier
I'd do the follwiing: 1. make a sub named shell to overwrite the existing one that calls .shell on Proc. 2. make a class that inherits from Proc: class MyProc is Proc { } 3. Look at https://github.com/rakudo/rakudo/blob/nom/src/core/Proc.pm and decide what methods you need to override to get the b

Re: Your thoughts on Padre?

2017-02-24 Thread Lloyd Fournier
I haven't heard much on Padre. I use emacs, which gets the job done for me. A fair bit of work has gone into making an atom mode that works. See: https://github.com/MadcapJake/language-perl6fe LL On Sat, Feb 25, 2017 at 9:46 AM ToddAndMargo wrote: http://padre.perlide.org/ Any good for Perl 6?

Re: [perl #130817] [BUG] shaped array attribute cannot be initialized from previously defined attributes

2017-02-19 Thread Lloyd Fournier
I expected this wouldn't work because the attribute definition is parsed at compile time when $!x and $!y aren't known. The error is definitely LTA. You can do what you want like this: class rect { has $.x; has $.y; has Array $.area .= new(:shape($!x,$!y)) } say rect.new(x => 3,y => 4).ar

Re: [perl #130787] [BUG] Array subsignatures confused by pair elements

2017-02-18 Thread Lloyd Fournier
I don't think this isn't a bug. This is just how signature binding works: my ($a,$b,$c) := [10,20,v => 30] Too few positionals passed; expected 3 arguments but got 2 in block at -e line 1 It makes sense to me because otherwise what would this mean? sub s(@($a,$b,:$c)) { } Pair elements

Re: [perl #130709] Issue with dynamic loading of module

2017-02-04 Thread Lloyd Fournier
looks similar to: https://rt.perl.org/Public/Bug/Display.html?id=130535 require seems to be pretty broken since the lexical module thing. Unfortunately our tests weren't good enough to pick this up ( I think it's because it's being required dynamically outside the mainline). LL On Sat, Feb 4, 20

Re: [perl #130535] Dynamic module loading by require in another modules has broken recently?

2017-01-11 Thread Lloyd Fournier
Confirmed. As you say, it's probably because require hasn't been updated to the new lexical importing design like "use" has. A few of the tests probably have to be re-written for require as well. LL On Wed, Jan 11, 2017 at 6:27 AM Asato Wakisaka wrote: # New Ticket Created by Asato Wakisaka # P

Re: [perl #130540] [BUG] || && and or cannot be "overloaded"

2017-01-11 Thread Lloyd Fournier
There is a &infix:<&&> which might be where some confusion comes from. I guess that's there for meta operators. For example: multi sub infix:<&&>("foo","bar") { "win" }; say "foo" && "bar" # bar say Z&& # win so it does kinda work actually just not as you might expect. LL On Thu, Jan 12, 2017

Re: Simple windows code example needed

2017-01-11 Thread Lloyd Fournier
Ah. If that's the case I have nothing useful to contribute :| LL On Thu, Jan 12, 2017 at 4:15 PM Brandon Allbery wrote: > > On Thu, Jan 12, 2017 at 12:11 AM, Lloyd Fournier > wrote: > > say "hello world"; > or on the command line: > perl6 -e 'sa

Re: modules in windows?

2017-01-11 Thread Lloyd Fournier
The module installers I know of are: https://github.com/ugexe/zef https://github.com/tadzik/panda They should be able to do what you need :) On Thu, Jan 12, 2017 at 1:50 PM ToddAndMargo wrote: > Hi All, > > In Windows, other than writing for it and having it crash, how > do I tell if I have a

Re: perl 6 equivalent of "use warnings"

2017-01-11 Thread Lloyd Fournier
Nope. Perl6 warns you without asking for it. LL On Thu, Jan 12, 2017 at 2:43 PM ToddAndMargo wrote: Hi All, Is there a perl 6 equivalent of perl 5's "use warnings"? Many thanks, -T

Re: Simple windows code example needed

2017-01-11 Thread Lloyd Fournier
say "hello world"; or on the command line: perl6 -e 'say "hello world"' There are no headers :) LL On Thu, Jan 12, 2017 at 2:28 PM ToddAndMargo wrote: Hi All, Please forgive me being a mooch here. Would some kind person please write me a simple Windows perl 6 script so that I can see the he

Re: Re-export symbols

2017-01-10 Thread Lloyd Fournier
Hey Fernando, This is not yet implemented in rakudo. I included a way of doing this in CompUnit::Util . I'm not sure when/if :EXPORT will be implemented (I actually don't think it's a good idea). I've just realised that there is another solut

Re: [perl #130520] [RFC] Deprecate `flatmap`

2017-01-10 Thread Lloyd Fournier
I took a look through my codebase to see where I have used flatmap. Every place I think I would prefer map({ }).flat on second look. so +1 LL On Fri, Jan 6, 2017 at 4:47 PM Sam S. wrote: > # New Ticket Created by Sam S. > # Please include the string: [perl #130520] > # in the subject line o

Re: [perl #130533] how to export alias to module function?

2017-01-10 Thread Lloyd Fournier
Looks like a bug to me. Seems to be it bugs out if you put "is export" on a constant decl where the RHS is a &sub. You could do this until it's fixed: sub foo is export { } BEGIN EXPORT::DEFAULT::{'&foo-alias'} = &foo; On Tue, Jan 10, 2017 at 1:21 AM Alexey Melezhik < perl6-bugs-follo...@perl.or

Re: [perl #130099] .defined doesn't work with junctions

2016-11-14 Thread Lloyd Fournier
Thanks! On Tue, Nov 15, 2016 at 1:28 AM Zoffix Znet via RT < perl6-bugs-follo...@perl.org> wrote: > Thanks for the report. > > Fixed in https://github.com/rakudo/rakudo/commit/189cb23e84 > Tests added in https://github.com/perl6/roast/commit/6b84580ecc > > > On Mon, 14 Nov 2016 04:37:49 -0800, ll

Re: [perl #130034] A andthen B orelse C leaks some internal Block

2016-11-09 Thread Lloyd Fournier
Thanks for the update. As viki hinted at, isn't this a bug in itself (andthen problems aside). Why does Empty as the first arg to orelse return a block? say (Empty orelse "foo") -> ;; $_ is raw { #`(Block|140421623865904) ... } Where as say (Any orelse "foo") returns the correct value. On Thu

Re: [perl #129946] [BUG][SEGV] Segfault in GC

2016-10-26 Thread Lloyd Fournier
Looks like you've hit another one like: https://rt.perl.org/Public/Bug/Display.html?id=128553 https://github.com/MoarVM/MoarVM/issues/412 On Mon, Oct 24, 2016 at 12:31 AM via RT wrote: > # New Ticket Created by > # Please include the string: [perl #129946] > # in the subject line of all future

Re: [perl #127033] [CONC] threads, dynamic variables lost sometimes

2016-10-12 Thread Lloyd Fournier
Tests: https://github.com/perl6/roast/commit/0705a6ea62a6f1cdaeb6cd46f3130d3728c4ce1b On Tue, Oct 11, 2016 at 9:26 PM Lloyd Fournier wrote: > looks like it's been fixed! \o/ > > I will put writing test for this on my TODO. > > > On Tue, Oct 11, 2016 at 5:00 AM Sam S. via

Re: [perl #127033] [CONC] threads, dynamic variables lost sometimes

2016-10-11 Thread Lloyd Fournier
looks like it's been fixed! \o/ I will put writing test for this on my TODO. On Tue, Oct 11, 2016 at 5:00 AM Sam S. via RT wrote: All the examples in this thread work fine for me, on 64bit Linux with current Rakudo. This is Rakudo version 2016.09-163-g92c0921 built on MoarVM version 2016.

Re: [perl #129776] [CUR][PERF] Extremely slow performance when running in directory with lots of modules

2016-10-01 Thread Lloyd Fournier
String concat takes On2 in rakudo I think. Using join in this kind of situation should be an improvement. (I'm commuting so can't test). On Sat, 1 Oct 2016 at 7:11 PM, Zoffix Znet wrote: > # New Ticket Created by Zoffix Znet > # Please include the string: [perl #129776] > # in the subject line

Re: [perl #129344] [BUG] "my" variable in a recursive subroutine leaks to callers scope

2016-09-24 Thread Lloyd Fournier
Reproduced. Looks like you shouldn't nest subs inside recursive functions atm :S. More golfed with just $level being used to demonstrate: sub process-list (@items, $level = 0) { multi sub process-item ($item) { ('=' x $level) ~ $item; } multi sub process-item (@array) {

Re: [perl #129346] [BUG] Whatever being called on where-blocked subroutine cannot handle the sigilless values correctly

2016-09-24 Thread Lloyd Fournier via RT
I think this is because .WHAT is a special case. It's not really a method which is what you need to make *.method work. *.WHAT will always return (Whatever) immediately. There is an odd what of working around this: perl6 -e 'sub foo(\a where *.&WHAT === Int ) { say "Hello"; }; foo(10); # works u

Re: [perl #129346] [BUG] Whatever being called on where-blocked subroutine cannot handle the sigilless values correctly

2016-09-24 Thread Lloyd Fournier
I think this is because .WHAT is a special case. It's not really a method which is what you need to make *.method work. *.WHAT will always return (Whatever) immediately. There is an odd what of working around this: perl6 -e 'sub foo(\a where *.&WHAT === Int ) { say "Hello"; }; foo(10); # works u

Re: [perl #128846] with statement modifier doesn't return writable values

2016-09-22 Thread Lloyd Fournier
20:21 < llfourn_> m: my $a = "foo"; ($a andthen $_) = "bar"; say $a 20:21 < camelia> rakudo-moar e9409c: OUTPUT«Cannot modify an immutable Str␤ in block at line 1␤␤» andthen also has the same behaviour. On Fri, Aug 5, 2016 at 4:53 PM Lloyd Fournier wrote:

Re: [perl #129263] [CONC] Outer dynamic variable not found in nested `start` block

2016-09-14 Thread Lloyd Fournier
Looks pretty similar to: https://rt.perl.org/Public/Bug/Display.html?id=127033 On Tue, Sep 13, 2016 at 11:13 PM Elizabeth Mattijsen wrote: > Feels to me some kind of loop would need to be made around line 33 in > src/core/stubs.pm, basically looping until we either find the dynamic > variable, o

Re: [perl #129220] [BUG] .list,.List, (Real,) inconsistencies

2016-09-07 Thread Lloyd Fournier
I Realised what's happening. Real is a role so calling .list on it puns it. so the phenomenon can be boiled down to: Real ~~ Real.^pun # False I'm not sure if it should be that way. I will accept notabug though :) On Thu, Sep 8, 2016 at 12:33 AM Lloyd Fournier wrote: > # New T

Re: [perl #129143] :DEFAULT tag in "use" directive prevents import from subsequent tags

2016-08-30 Thread Lloyd Fournier
You have to have a comma after each tag. I think it will work if you do (can't test atm). It's def LTA that there's no syntax error. Arg parsing for use statements is LTA in general I think. LL On Wed, 31 Aug 2016 at 9:29 AM, Brian S. Julin wrote: > # New Ticket Created by "Brian S. Julin" > #

Re: [perl #129096] [BUG] sub wrapped with mod_trait: when exported yield cryptic error message, works fine in same unit

2016-08-26 Thread Lloyd Fournier
This is another outer context lost with compile time closure bug. It's one of the most prolific bugs in rakudo :(. I've added this ticket to the list: https://rt.perl.org/Public/Bug/Display.html?id=125634 https://rt.perl.org/Public/Bug/Display.html?id=126818 https://rt.perl.org/Public/Bug/Display

Re: [perl #127569] [BUG] lexical packages leak into SETTING::

2016-08-24 Thread Lloyd Fournier
I was missing a ')' on the last one. Should be: ## 3 our scoped packages are not available for introspecting in CompUnit::Handle.globalish-package; # lib/Cool/Utils.pm class Cool::Utils {} class Foo { }; # main.pl my $cu = $*REPO.need(CompUnit::DependencySpecification.new(:short-name("Cool::Util

Re: [perl #128766] Useless use of $a in sink context is spurious

2016-08-03 Thread Lloyd Fournier
test: https://github.com/perl6/roast/commit/4fdee95e24998498641bc548cb4319cefd6d0a0f On Sat, Jul 30, 2016 at 5:36 AM Will Coleda via RT < bugs-comm...@bugs6.perl.org> wrote: > Re-opening, marking testneeded. > > -- > Will "Coke" Coleda >

Re: [perl #128770] 5334cb725 causes erroneous sink on ($_ with "foo")

2016-08-03 Thread Lloyd Fournier
Test: https://github.com/perl6/roast/commit/4fdee95e24998498641bc548cb4319cefd6d0a0f On Sat, Jul 30, 2016 at 4:55 AM Larry Wall via RT < bugs-comm...@bugs6.perl.org> wrote: > The logical ops andthen, notandthen, and orelse were not propagating > wantedness to their thunky args. > > Fixed in 7ba6d

Re: [perl #128749] [RT] Emails sent to perl6-bugs-follo...@perl.org do not replicate on RT ticket

2016-07-28 Thread Lloyd Fournier
It seems like someone has just done some cleaning of this spam queue because responses I sent to https://rt.perl.org/Public/Bug/Display.html?id=128553 a couple of weeks ago just came through. On Thu, Jul 28, 2016 at 12:03 AM Will Coleda via RT < perl6-bugs-follo...@perl.org> wrote: > On Wed Jul 2

Re: [perl #128553] multi method cache causes Base64 regression

2016-07-27 Thread Lloyd Fournier via RT
I've been getting segfaults in this area recently. The trace is a bit different but I guess it's related. It seems that flag_map in gc_mark is no longer allocated so I get segfault. (lldb) r There is a running process, kill it and restart?: [Y/n] y Process 75673 exited with status = 9 (0x0009)

Re: [perl #128553] multi method cache causes Base64 regression

2016-07-27 Thread Lloyd Fournier via RT
By flag_map I mean ctx->callsite->arg_flags: (lldb) p ctx->arg_flags (MVMCallsiteEntry *) $8 = 0x (lldb) p ctx->callsite->arg_flags (MVMCallsiteEntry *) $9 = 0x10a72533 "" On Mon, Jul 11, 2016 at 3:59 AM Lloyd Fournier wrote: > I've be

Re: [perl #127958] [BUG] :D smiley is not respected when assigning to Nil

2016-07-25 Thread Lloyd Fournier
Tests: https://github.com/perl6/roast/commit/fa9a6b05f665bef3b5b45cb35d4018b2a8368c31 On Mon, Jul 25, 2016 at 8:19 AM Brian S. Julin via RT < perl6-bugs-follo...@perl.org> wrote: > On Fri Jul 22 15:34:49 2016, b...@abrij.org wrote: > > > > rakudo PR #829 should fix this on moarvm. JVM and JS fix

Re: [perl #128636] [BUG][PRECOMP] is cached in a precompiled module results in error

2016-07-16 Thread Lloyd Fournier
Hi Zoffix, You reported the same bug in December :P https://rt.perl.org/Public/Bug/Display.html?id=126818 (although the error message has changed). This is the compile time outer context serialization bug. FYI I've kept a list of tickets that are examples of it: https://rt.perl.org/Public/Bug/D

Re: [perl #128342] > assertion doesn't work if is zero-width

2016-07-15 Thread Lloyd Fournier
Ok. Thanks for the explanation Zoffix++. I guess you have to be careful doing >. On Thu, Jul 14, 2016 at 10:59 PM Zoffix Znet via RT < perl6-bugs-follo...@perl.org> wrote: > Hi, > > Thanks for the report. > > This is by design, as tokens don't backtrack. works by flipping > the string and the AS

Re: [perl #128553] multi method cache causes Base64 regression

2016-07-10 Thread Lloyd Fournier
By flag_map I mean ctx->callsite->arg_flags: (lldb) p ctx->arg_flags (MVMCallsiteEntry *) $8 = 0x (lldb) p ctx->callsite->arg_flags (MVMCallsiteEntry *) $9 = 0x10a72533 "" On Mon, Jul 11, 2016 at 3:59 AM Lloyd Fournier wrote: > I've be

Re: [perl #128553] multi method cache causes Base64 regression

2016-07-10 Thread Lloyd Fournier
I've been getting segfaults in this area recently. The trace is a bit different but I guess it's related. It seems that flag_map in gc_mark is no longer allocated so I get segfault. (lldb) r There is a running process, kill it and restart?: [Y/n] y Process 75673 exited with status = 9 (0x0009)

Re: [perl #128516] [SEGV] $!attr.^compose causing segfault

2016-07-06 Thread Lloyd Fournier
Further information: if you put nqp::decont($!a).^compose it works. On Wed, Jul 6, 2016 at 4:26 AM Nicholas Clark wrote: > On Fri, Jul 01, 2016 at 10:36:25PM -0700, Lloyd Fournier wrote: > > > class Foo { has $.a = Metamodel::ClassHOW.new_type(name => "Bar"); metho

Re: [perl #128543] [BUG] Str.Int inconsistent about spaces on empty string

2016-07-05 Thread Lloyd Fournier
; use strict; say 1 + " "' Argument " " isn't numeric in addition (+) at -e line 1. 1 me bad. On Wed, Jul 6, 2016 at 2:22 AM Lloyd Fournier wrote: > I think this is to be consistent with p5. > perl -E 'say "" + 1' #-> 1 > > I'm no

Re: [perl #128543] [BUG] Str.Int inconsistent about spaces on empty string

2016-07-05 Thread Lloyd Fournier
I think this is to be consistent with p5. perl -E 'say "" + 1' #-> 1 I'm not really making an argument it should be this way. But that's probably the reason. On Wed, Jul 6, 2016 at 2:13 AM Zefram wrote: > # New Ticket Created by Zefram > # Please include the string: [perl #128543] > # in the

Re: [perl #128483] [BUG][PRECOMPILATION] Issues with CALLER invocations in a precompiled module with subs exported by a zef/panda installed module

2016-06-25 Thread Lloyd Fournier
I think this is another *compile-time closure loses it's outer ctx at runtime* bug. I was trying to keep track of them: https://rt.perl.org/Public/Bug/Display.html?id=125634 Your lovely module has a compile time closure here (EXPORT Is called at compile time): https://github.com/zoffixznet/perl6-

Re: [perl #128481] [BUG] *.split returns a BOOTArray

2016-06-25 Thread Lloyd Fournier
Test: https://github.com/perl6/roast/commit/0d86018d749317b859e36dad1e4520950fad0e9f On Sun, Jun 26, 2016 at 1:36 AM Lloyd Fournier wrote: > will write test tomorrow. > Thx liz. > > On Sun, Jun 26, 2016 at 1:35 AM Elizabeth Mattijsen via RT < > perl6-bugs-follo...@perl.org&

  1   2   >