[perl #104980] natively typed attributes and BUILD methods don't mix

2017-09-21 Thread Christian Bartolomaeus via RT
On Thu, 21 Sep 2017 19:50:01 -0700, b...@abrij.org wrote: > > Current behavior (don't have a rakudo-j here): > > $ perl6-m -e 'class A { has str $.x; method BUILD(:$!x) { } }; say > A.new(:x).x' > foo > > If r-j now works too, we can move to TESTNEEDED. Yeah, looks good on rakudo-j, too: $

[perl #104980] natively typed attributes and BUILD methods don't mix

2017-09-21 Thread Brian S. Julin via RT
On Sun, 01 Mar 2015 12:29:14 -0800, barto...@gmx.de wrote: > As a status update: This currently fails with: > > $ perl6-m -e 'class A { has str $.x; method BUILD(:$!x) { } }; say > A.new(:x).x' > Cannot modify an immutable str > in method BUILD at -e:1 > in method BUILDALL at

[perl #129812] [OPTIMIZER] `is rw` candidates get called even if a non-rw argument is passed

2017-09-21 Thread Brian S. Julin via RT
On Sat, 05 Aug 2017 06:28:34 -0700, jan-olof.hen...@bredband.net wrote: > On Wed, 05 Oct 2016 14:23:57 -0700, c...@zoffix.com wrote: > > > > This code shows the bug: > > > > zoffix@leliana:~$ perl6 -e 'm: multi foo ($) {"right" }; multi > > foo ($ is rw) {"wrong"}; say foo "42"' > > wrong > > > >

Re: bash and pm6 question

2017-09-21 Thread Elizabeth Mattijsen
> On 22 Sep 2017, at 00:32, Bennett Todd wrote: > > With perl5, that could have been something like. "perl -Mmy -e ...", but I > don't have access to a perl6 at this instant to compare. There should be a > flag you can use to include a module into the.running

Re: bash and pm6 question

2017-09-21 Thread Bennett Todd
With perl5, that could have been something like. "perl -Mmy -e ...", but I don't have access to a perl6 at this instant to compare. There should be a flag you can use to include a module into the.running environment before evaluating the "-e" code. Using "use" within the "-e" string should

Re: bash and pm6 question

2017-09-21 Thread Todd Chester
On 09/21/2017 01:19 AM, Shlomi Fish wrote: Hi Todd, On Wed, 20 Sep 2017 23:22:41 -0700 ToddAndMargo wrote: Hi All, Can I call a pm6 directly from bash or do I need to call a pl6 that calls the pm6? why not use "perl6 -e"? Regards, Shlomi perl6 -e'use

Re: Your posting is a bit unfortunate

2017-09-21 Thread Joachim Durchholz
I'll respond privately to keep the noise of the list. Ask me to get cc'd. Regards, Jo

[perl #132140] Behaviour of bang-bang

2017-09-21 Thread via RT
# New Ticket Created by Philippe 'BooK' Bruhat # Please include the string: [perl #132140] # in the subject line of all future correspondence about this issue. # https://rt.perl.org/Ticket/Display.html?id=132140 > Experimenting with !! showed this: $ perl6 -v This is Rakudo version

Re: help with map and regexp

2017-09-21 Thread Brandon Allbery
On Thu, Sep 21, 2017 at 2:37 AM, Luca Ferrari wrote: > Out of cursiosity: what is the diffence between using "is copy" and "<->"? > Seems to me the map example can work with both. > <-> is the same as "is rw" and requires that the thing being bound be a mutable container,

Re: bash and pm6 question

2017-09-21 Thread Shlomi Fish
Hi Todd, On Wed, 20 Sep 2017 23:22:41 -0700 ToddAndMargo wrote: > Hi All, > > Can I call a pm6 directly from bash or do I > need to call a pl6 that calls the pm6? > why not use "perl6 -e"? Regards, Shlomi > > Many thanks, > -T > --

Re: help with map and regexp

2017-09-21 Thread Brent Laabs
You can also use a whatever star with the subst method to avoid the block entirely, and just chain method calls: my @fields = $line.split( ',' ).map: *.subst(/\'/, "", :g).subst(/^\"|\"$/, "", :g); On Wed, Sep 20, 2017 at 11:37 PM, Luca Ferrari wrote: > On Tue, Sep 19,

Re: help with map and regexp

2017-09-21 Thread Luca Ferrari
On Tue, Sep 19, 2017 at 2:43 PM, Timo Paulssen wrote: > perl6 -e '.perl.say for "hello, how, are, you".split(",").map: -> $_ > is copy { s:g/a//; s:g/^ \s|\s $/O/; $_ }' > "hello" > "Ohow" > "Ore" > "Oyou" Thanks. Out of cursiosity: what is the diffence

bash and pm6 question

2017-09-21 Thread ToddAndMargo
Hi All, Can I call a pm6 directly from bash or do I need to call a pl6 that calls the pm6? Many thanks, -T -- ~~ Computers are like air conditioners. They malfunction when you open windows ~~