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

bad \ quoting in operator names in error message #5580

Open
p6rt opened this issue Aug 15, 2016 · 2 comments
Open

bad \ quoting in operator names in error message #5580

p6rt opened this issue Aug 15, 2016 · 2 comments
Labels
Bug

Comments

@p6rt
Copy link

@p6rt p6rt commented Aug 15, 2016

Migrated from rt.perl.org#128949 (status was 'new')

Searchable as RT128949$

@p6rt

This comment has been minimized.

Copy link
Author

@p6rt p6rt commented Aug 15, 2016

From zefram@fysh.org

&prefix​:<+\\\\+>
===SORRY!=== Error while compiling​:
Undeclared routine​:
  prefix​:<+\\+> used at line 1. Did you mean 'prefix​:<++>', 'prefix​:<~>', 'prefix​:<temp>'?

Observe that what I input as <+\\\\+> has been echoed back in the error
message as <+\\+>. Those are not equivalent subscripts, so that error
message is erroneous.

Aside from simply applying the quoting rules to see what the subscripts
mean, one can see that they're different by inputting <+\\+> in the same
context for comparison​:

&prefix​:<+\\+>
===SORRY!=== Error while compiling​:
Undeclared routine​:
  prefix​:<+\+> used at line 1. Did you mean 'prefix​:<++>', 'prefix​:<+>', 'prefix​:<+^>'?

Note that it's echoed differently and gets a different list of suggested
typo resolutions. This time it's actually been echoed back correctly​:
<+\+> is equivalent to <+\\+>.

-zefram

@p6rt

This comment has been minimized.

Copy link
Author

@p6rt p6rt commented Nov 26, 2016

From @zoffixznet

The issue is the message shows literal name of the stuff inside the brackets. Same applies to having a > in it​:

$ perl6 -e '&prefix​:«+\\\>\+»'
===SORRY!=== Error while compiling -e
Undeclared routine​:
  prefix​:<+\\>+> used at line 1. Did you mean 'prefix​:<++>', 'prefix​:<~>', 'prefix​:<temp>'?

@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
Projects
None yet
1 participant
You can’t perform that action at this time.