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

Cannot bind to &::("CORE")::foo (Or bogus test?) #4560

Open
p6rt opened this issue Sep 20, 2015 · 4 comments
Open

Cannot bind to &::("CORE")::foo (Or bogus test?) #4560

p6rt opened this issue Sep 20, 2015 · 4 comments
Labels

Comments

@p6rt
Copy link

p6rt commented Sep 20, 2015

Migrated from rt.perl.org#126113 (status was 'open')

Searchable as RT126113$

@p6rt
Copy link
Author

p6rt commented Sep 20, 2015

From @FROGGS

t/spec/S02-names/pseudo.t expects that you can do​:

  use Test; plan 1;
  sub f3() { }
  &​::("CORE")​::none := &f3;
  ok &none =​:= &f3, 'works';

@p6rt
Copy link
Author

p6rt commented Sep 20, 2015

From @moritz

On 09/20/2015 09​:55 AM, Tobias Leich (via RT) wrote​:

# New Ticket Created by Tobias Leich
# Please include the string​: [perl #​126113]
# in the subject line of all future correspondence about this issue.
# <URL​: https://rt-archive.perl.org/perl6/Ticket/Display.html?id=126113 >

t/spec/S02-names/pseudo.t expects that you can do​:

use Test; plan 1;
sub f3\(\) \{ \}
&&#8203;::\("CORE"\)&#8203;::none := &f3;
ok &none =&#8203;:= &f3, 'works';

I'm pretty sure that test is incorrect.

Lexical scopes are read-only after compile time, and &​::CORE is a
lexical scope, after all.

@p6rt
Copy link
Author

p6rt commented Sep 20, 2015

The RT System itself - Status changed from 'new' to 'open'

@p6rt
Copy link
Author

p6rt commented May 21, 2016

From @smls

Yeah, the test (as well as the surrounding ones that do pass) seems fishy.

I also don't see the tested behavior described in S02. The only example code in S02 that shows binding to a `&` LHS is this​:

  my &func := sub { say "Hi" };

...which declares a new symbol in the current scope, rather than modifying an already closed scope.

(I'll abuse the `testneeded` tag again, to mean "Needs someone experienced with Roast to investigate and potentially fix/remove test.")

@p6rt p6rt added the at_larry label Jan 5, 2020
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

1 participant