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

Declaration 'module A is put_anything_here' doesn't throw a Big Fat Error #2297

Closed
p6rt opened this issue Dec 16, 2010 · 5 comments
Closed
Labels

Comments

@p6rt
Copy link

p6rt commented Dec 16, 2010

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

Searchable as RT80856$

@p6rt
Copy link
Author

p6rt commented Dec 16, 2010

From @masak

<masak> rakudo​: module A { our sub foo { say "A​::foo" } }; module B is
A { our sub foo { say "B​::foo"; nextsame } }; B​::foo
<p6eval> rakudo a95c1d​: OUTPUT«B​::foo␤Null PMC access in clone()␤ in
'B​::foo' [...]
<masak> rakudo​: module B is floozey {}; say "alive"
<p6eval> rakudo a95c1d​: OUTPUT«alive␤»
* masak submits rakudobug

The Null PMC access in question has been reported before. What I'd
like to report as an error here is the fact that an 'is' trait on the
module doesn't result in a (compile-time) error. See
<http://perl6advent.wordpress.com/2010/12/14/day-14-nextsame-and-its-cousins/#comment-542>
for when this would have helped to catch an error early.

@p6rt
Copy link
Author

p6rt commented Dec 23, 2010

From @kyleha

This is an automatically generated mail to inform you that tests are now available in S10-packages/basic.t

commit fef3dccf5d7492b427068fcdc979abcf528a3ceb
Author​: Kyle Hasselbacher <kyleha@​gmail.com>
Date​: Thu Dec 23 10​:39​:50 2010 -0600

  [S10-packages] Test for RT 80856

Inline Patch
diff --git a/S10-packages/basic.t b/S10-packages/basic.t
index aafc5c4..89286b1 100644
--- a/S10-packages/basic.t
+++ b/S10-packages/basic.t
@@ -4,7 +4,7 @@ use v6;
 
 use Test;
 
-plan 52;
+plan 53;
 
 my regex fairly_conclusive_platform_error {:i ^\N*<<Null?>>}
 
@@ -219,4 +219,8 @@ eval_lives_ok q' module MapTester { (1, 2, 3).map: { $_ } } ',
         'package Foo; is indicator for Perl 5 code';
 }
 
+#?rakudo todo 'RT 80856'
+eval_dies_ok 'module RT80856 is not_RT80856 {}',
+             'die if module "is" a nonexistent';
+
 # vim: ft=perl6

@p6rt
Copy link
Author

p6rt commented Dec 23, 2010

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

@p6rt
Copy link
Author

p6rt commented Jun 9, 2013

From @jnthn

On Thu Dec 16 00​:56​:30 2010, masak wrote​:

<masak> rakudo​: module A { our sub foo { say "A​::foo" } }; module B is
A { our sub foo { say "B​::foo"; nextsame } }; B​::foo
<p6eval> rakudo a95c1d​: OUTPUT«B​::foo␤Null PMC access in clone()␤
in
'B​::foo' [...]
<masak> rakudo​: module B is floozey {}; say "alive"
<p6eval> rakudo a95c1d​: OUTPUT«alive␤»
* masak submits rakudobug

The Null PMC access in question has been reported before. What I'd
like to report as an error here is the fact that an 'is' trait on the
module doesn't result in a (compile-time) error. See
<http://perl6advent.wordpress.com/2010/12/14/day-14-nextsame-and-its-
cousins/#comment-542>
for when this would have helped to catch an error early.

Now gives​:

===SORRY!===
'RT80856' cannot inherit from 'not_RT80856' because it is unknown.

And the test attached to this RT is already passing, so resolving.

/jnthn

@p6rt
Copy link
Author

p6rt commented Jun 9, 2013

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

@p6rt p6rt closed this as completed Jun 9, 2013
@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