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 for class A{}; Any.HOW(A).WHAT.say #2827

Closed
p6rt opened this issue Jul 13, 2012 · 5 comments
Closed

LTA error message for class A{}; Any.HOW(A).WHAT.say #2827

p6rt opened this issue Jul 13, 2012 · 5 comments

Comments

@p6rt
Copy link

p6rt commented Jul 13, 2012

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

Searchable as RT114130$

@p6rt
Copy link
Author

p6rt commented Jul 13, 2012

From @bbkr

Method name get_how_p_p_p is leaking to user-lever error message along with some weird (my code is one-liner) line number 158519259.

$ perl6 -e 'class A{}; Any.HOW(A).WHAT.say'
use of uninitialized value of type Mu in string context in any <anon> at src/gen/BOOTSTRAP.pm​:104

use of uninitialized value of type Mu in string context in any <anon> at src/gen/BOOTSTRAP.pm​:104

===SORRY!===
error​:imcc​:The opcode 'get_how_p_p_p' (get_how<3>) was not found. Check the type and number of the arguments
  in file '(file unknown)' line 158519259

jnthn @​ 6​:46
Yeah, we should catch that bogus syntax rather earlier :)

@p6rt
Copy link
Author

p6rt commented Aug 5, 2012

From @jnthn

On Fri Jul 13 09​:52​:37 2012, pawel.pabian@​implix.com wrote​:

Method name get_how_p_p_p is leaking to user-lever error message along
with some weird (my code is one-liner) line number 158519259.

$ perl6 -e 'class A{}; Any.HOW(A).WHAT.say'
use of uninitialized value of type Mu in string context in any <anon>
at src/gen/BOOTSTRAP.pm​:104

use of uninitialized value of type Mu in string context in any <anon>
at src/gen/BOOTSTRAP.pm​:104

===SORRY!===
error​:imcc​:The opcode 'get_how_p_p_p' (get_how<3>) was not found.
Check the type and number of the arguments
in file '(file unknown)' line 158519259

jnthn @​ 6​:46
Yeah, we should catch that bogus syntax rather earlier :)

It's now more informative​:

class A{}; Any.HOW(A).WHAT.say
Cannot give arguments to HOW

I added the exception type X​::Syntax​::Argument​::MOPMacro, so should be
easy to add tests.

Tagging testneeded.

/jnthn

@p6rt
Copy link
Author

p6rt commented Aug 5, 2012

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

@p6rt
Copy link
Author

p6rt commented Nov 14, 2012

From @coke

On Sun Aug 05 10​:00​:23 2012, jnthn@​jnthn.net wrote​:

On Fri Jul 13 09​:52​:37 2012, pawel.pabian@​implix.com wrote​:

Method name get_how_p_p_p is leaking to user-lever error message along
with some weird (my code is one-liner) line number 158519259.

$ perl6 -e 'class A{}; Any.HOW(A).WHAT.say'
use of uninitialized value of type Mu in string context in any <anon>
at src/gen/BOOTSTRAP.pm​:104

use of uninitialized value of type Mu in string context in any <anon>
at src/gen/BOOTSTRAP.pm​:104

===SORRY!===
error​:imcc​:The opcode 'get_how_p_p_p' (get_how<3>) was not found.
Check the type and number of the arguments
in file '(file unknown)' line 158519259

jnthn @​ 6​:46
Yeah, we should catch that bogus syntax rather earlier :)

It's now more informative​:

class A{}; Any.HOW(A).WHAT.say
Cannot give arguments to HOW

I added the exception type X​::Syntax​::Argument​::MOPMacro, so should be
easy to add tests.

Tagging testneeded.

/jnthn

Added test to S12-introspection/meta-class.t

--
Will "Coke" Coleda

@p6rt
Copy link
Author

p6rt commented Nov 14, 2012

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

@p6rt p6rt closed this as completed Nov 14, 2012
@p6rt p6rt added the testneeded label Jan 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant