Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

infix:<,=> should have list precedence in the cases infix:<=> does in Rakudo #1915

Closed
p6rt opened this issue Jul 7, 2010 · 9 comments
Closed
Labels

Comments

@p6rt
Copy link

p6rt commented Jul 7, 2010

Migrated from rt.perl.org#76414 (status was 'resolved')

Searchable as RT76414$

@p6rt
Copy link
Author

p6rt commented Jul 7, 2010

From @masak

<tylercurtis> rakudo​: my @​foo; push(@​foo, 1, 2, 3); @​foo.perl.say
<p6eval> rakudo 894e79​: OUTPUT«[1, 2, 3]␤»
<tylercurtis> rakudo​: my @​foo; @​foo ,= 1, 2, 3; @​foo.perl.say
<p6eval> rakudo 894e79​: OUTPUT«[1]␤»
<tylercurtis> S03​: "@​foo ,= 1,2,3 # same as push(@​foo,1,2,3)"
<masak> well spotted.
* masak submits rakudobug
<masak> tylercurtis++

@p6rt
Copy link
Author

p6rt commented Jul 29, 2010

@coke - Status changed from 'new' to 'open'

@p6rt
Copy link
Author

p6rt commented Oct 21, 2011

From @coke

On Wed Jul 07 15​:35​:30 2010, masak wrote​:

<tylercurtis> rakudo​: my @​foo; push(@​foo, 1, 2, 3); @​foo.perl.say
<p6eval> rakudo 894e79​: OUTPUT«[1, 2, 3]␤»
<tylercurtis> rakudo​: my @​foo; @​foo ,= 1, 2, 3; @​foo.perl.say
<p6eval> rakudo 894e79​: OUTPUT«[1]␤»
<tylercurtis> S03​: "@​foo ,= 1,2,3 # same as push(@​foo,1,2,3)"
<masak> well spotted.
* masak submits rakudobug
<masak> tylercurtis++

This now fails with​:

20​:44 < [Coke]> rakudo​: my @​foo; @​foo ,= 1, 2, 3; @​foo.perl.say
20​:44 <+p6eval> rakudo 63326f​: OUTPUT«splice() not implemented in class 'Mu'␤
  in method reify at src/gen/CORE.setting​:3952␤ in method gimme
  at src/gen/CORE.setting​:4313␤ in method eager at
  src/gen/CORE.setting​:4288␤ in method STORE at
  src/gen/CORE.setting​:4707␤ in block <anon> at
  /tmp/NXMhYHJgd8​:1…

--
Will "Coke" Coleda

@p6rt
Copy link
Author

p6rt commented May 29, 2012

From @moritz

Back to the original state​:

09​:10 < moritz> rakudo​: my @​foo; @​foo ,= 1, 2, 3; @​foo.perl.say
09​:10 <+p6eval> rakudo 197e0b​: OUTPUT«Array.new(1)␤»

@p6rt
Copy link
Author

p6rt commented Nov 22, 2014

From @usev6

This now emits a warning about useless use of "," in sink context, but the result hasn't changed​:

$ perl6 -e 'my @​foo; @​foo ,= 1, 2, 3; @​foo.perl.say'
WARNINGS​:
Useless use of "," in expression ",= 1, 2, 3" in sink context (line 1)
Array.new(1)

I added a test (fudged "todo") to S03-operators/assign.t with commit Raku/roast@3e737ee253

1 similar comment
@p6rt
Copy link
Author

p6rt commented Nov 22, 2014

From @usev6

This now emits a warning about useless use of "," in sink context, but the result hasn't changed​:

$ perl6 -e 'my @​foo; @​foo ,= 1, 2, 3; @​foo.perl.say'
WARNINGS​:
Useless use of "," in expression ",= 1, 2, 3" in sink context (line 1)
Array.new(1)

I added a test (fudged "todo") to S03-operators/assign.t with commit Raku/roast@3e737ee253

@p6rt
Copy link
Author

p6rt commented Feb 8, 2015

From @Mouq

Fixed in Rakudo commit​:

commit 34669da476fb9cce4e55ffdc72e89d3dded83cf0
Author​: Mouq <alexmoquin@​gmail.com>
Date​: Sat Feb 7 20​:30​:40 2015 -0500

  Improve metaop​:<=>

  Dies in the case of fiddly/diffy operators, and now adjusts to the
  proper precedence depending on the operator

Behavior now​:

$ perl6 -e 'my @​foo; @​foo ,= 1, 2, 3; @​foo.perl.say'
Array.new(1, 2, 3)

Marking as resolved :)

On Sat Nov 22 02​:22​:41 2014, bartolin@​gmx.de wrote​:

This now emits a warning about useless use of "," in sink context, but
the result hasn't changed​:

$ perl6 -e 'my @​foo; @​foo ,= 1, 2, 3; @​foo.perl.say'
WARNINGS​:
Useless use of "," in expression ",= 1, 2, 3" in sink context (line 1)
Array.new(1)

I added a test (fudged "todo") to S03-operators/assign.t with commit
Raku/roast@3e737ee253

@p6rt
Copy link
Author

p6rt commented Feb 8, 2015

@Mouq - Status changed from 'open' to 'resolved'

@p6rt p6rt closed this as completed Feb 8, 2015
@p6rt p6rt added the Bug label Jan 5, 2020
lizmat added a commit to Raku/roast that referenced this issue Jan 12, 2020
I don't think we will ever follow S03 on that, as that implies too
much magic DWIM, and a big WAT!  Associated ticket:
  Raku/old-issue-tracker#1915
@lizmat
Copy link
Contributor

lizmat commented Jan 12, 2020

#1915 adapted test to match post-GLR behaviour

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants