develooper Front page | perl.perl6.users | Postings from September 2017

Re: Need append help

Thread Previous | Thread Next
From:
ToddAndMargo
Date:
September 29, 2017 19:37
Subject:
Re: Need append help
Message ID:
e6e07fc7-93fa-8eba-ff93-0cbf1bc503d0@zoho.com
On 09/29/2017 12:30 PM, Timo Paulssen wrote:
> On 09/29/2017 09:27 PM, ToddAndMargo wrote:
>> $ perl6 -e 'my $x="abc"; $x [R~]= "yyz"; say $x;'
>> Potential difficulties:
>>      Useless use of [R~]= in sink context
>>      at -e:1
>>      ------> my $x="abc"; $x ⏏[R~]= "yyz"; say $x;
>> yyzabc
> 
> This is the correct one. The warning about "useless use" here is a bug
> in rakudo. It's meant to warn for things like
> 
>      perl6 -e '1 + 2';
> 
> where you calculate something and do nothing with it. Here it just
> forgets to take into account that this is an assignment operation.
> 

Another bug.  Lucky me, again.   :'(

Thank you!

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About