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

Null PMC access when sub accesses outermost-scoped variable whose declaration hasn't been 'executed' yet #1479

Closed
p6rt opened this issue Jan 24, 2010 · 5 comments
Labels

Comments

@p6rt
Copy link

p6rt commented Jan 24, 2010

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

Searchable as RT72328$

@p6rt
Copy link
Author

p6rt commented Jan 24, 2010

From @masak

This be Rakudo db84bc on Parrot r43174.

$ perl6 -e 'my $x; foo; sub foo { say $x }'
Use of uninitialized value

Fine. But now​:

$ perl6 -e 'foo; my $x; sub foo { say $x }'
Null PMC access in type()
[...]

In both programs, $x is clearly in scope when accessed, so this is not
one of the open "variable access before declaration" tickets. (Even
though it might have similar causes.) So I doubt that the latter of
the programs should be illegal. Even if it were, it shan't produce a
Null PMC access.

@p6rt
Copy link
Author

p6rt commented Mar 9, 2010

From @moritz

On Sun Jan 24 10​:10​:04 2010, masak wrote​:

This be Rakudo db84bc on Parrot r43174.

$ perl6 -e 'my $x; foo; sub foo { say $x }'
Use of uninitialized value

Fine. But now​:

$ perl6 -e 'foo; my $x; sub foo { say $x }'
Null PMC access in type()
[...]

$ ./perl6 -e 'foo; my $x; sub foo { say $x }'
Any()

looks good to me - taking for test coverage.

@p6rt
Copy link
Author

p6rt commented Mar 9, 2010

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

@p6rt
Copy link
Author

p6rt commented Mar 11, 2010

From @moritz

there's now a test in my.t

@p6rt
Copy link
Author

p6rt commented Mar 11, 2010

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

@p6rt p6rt closed this as completed Mar 11, 2010
@p6rt p6rt added the Bug 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