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

LTA error message when referring to nonexistent symbol in constant declaration #3405

Closed
p6rt opened this issue Jun 3, 2014 · 4 comments
Closed
Labels

Comments

@p6rt
Copy link

p6rt commented Jun 3, 2014

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

Searchable as RT122022$

@p6rt
Copy link
Author

p6rt commented Jun 3, 2014

From @masak

<masak> m​: month
<camelia> rakudo-moar d78b63​: OUTPUT«===SORRY!=== Error while
compiling /tmp/LaTRxwVvWt␤Undeclared routine​:␤ month used at line
1␤␤»
<masak> m​: constant m = month
<camelia> rakudo-moar d78b63​: OUTPUT«===SORRY!===␤Cannot invoke null object␤»
* masak submits LTA rakudobug
<masak> r​: constant m = month
<camelia> rakudo-moar d78b63​: OUTPUT«===SORRY!===␤Cannot invoke null object␤»
<camelia> ..rakudo-parrot d78b63​: OUTPUT«===SORRY!===␤Could not find
sub &month␤»
<camelia> ..rakudo-jvm d78b63​:
OUTPUT«===SORRY!===␤java.lang.NullPointerException␤»

Expected behavior​: Rakudo Parrot's above.

@p6rt
Copy link
Author

p6rt commented Oct 30, 2015

From @coke

On Tue Jun 03 02​:30​:32 2014, masak wrote​:

<masak> m​: month
<camelia> rakudo-moar d78b63​: OUTPUT«===SORRY!=== Error while
compiling /tmp/LaTRxwVvWt␤Undeclared routine​:␤ month used at line
1␤␤»
<masak> m​: constant m = month
<camelia> rakudo-moar d78b63​: OUTPUT«===SORRY!===␤Cannot invoke null
object␤»
* masak submits LTA rakudobug
<masak> r​: constant m = month
<camelia> rakudo-moar d78b63​: OUTPUT«===SORRY!===␤Cannot invoke null
object␤»
<camelia> ..rakudo-parrot d78b63​: OUTPUT«===SORRY!===␤Could not find
sub &month␤»
<camelia> ..rakudo-jvm d78b63​:
OUTPUT«===SORRY!===␤java.lang.NullPointerException␤»

Expected behavior​: Rakudo Parrot's above.

This is now better on the jvm than on moar, but is probably closable with tests (esp. if moar is updated to reference the the object in the error)

09​:49 < [Coke]> r​: constant m = month;
09​:49 <+camelia> rakudo-jvm ba7027​: OUTPUT«===SORRY!=== Error while compiling
  /tmp/tmpfile␤An exception occurred while evaluating a
  constant␤at /tmp/tmpfile​:1␤Exception details​:␤ ===SORRY!===
  Error while compiling ␤ Can not invoke object '&month'␤ at
  :␤»
09​:49 <+camelia> ..rakudo-moar ba7027​: OUTPUT«===SORRY!=== Error while
  compiling /tmp/tmpfile␤An exception occurred while evaluating
  a constant␤at /tmp/tmpfile​:1␤Exception details​:␤ ===SORRY!===
  Error while compiling ␤ Cannot invoke this object␤ at :␤»
--
Will "Coke" Coleda

@p6rt
Copy link
Author

p6rt commented Oct 30, 2015

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

@p6rt p6rt added the Bug label Jan 5, 2020
@usev6
Copy link

usev6 commented Feb 18, 2023

This has been fixed shortly before Christmas: #4902 (comment)

Current output:

$ ./rakudo-m -e 'constant m = month'
===SORRY!=== Error while compiling -e
Undeclared routine:
    month used at line 1

There is also a test for the exception type in roast's S32-exceptions/misc.t, added with Raku/roast@a4ace08538.

I'm closing this issue as resolved.

@usev6 usev6 closed this as completed Feb 18, 2023
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