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

GH#1758: Only suggest a submethod if it's local #1791

Closed
wants to merge 1 commit into from
Closed

GH#1758: Only suggest a submethod if it's local #1791

wants to merge 1 commit into from

Conversation

vendethiel
Copy link
Contributor

This avoids us suggesting a submethod from a parent class, which would
always result into an error.

src/core/Exception.pm6 Outdated Show resolved Hide resolved
This avoids us suggesting a submethod from a parent class, which would
always result into an error.
@vendethiel
Copy link
Contributor Author

See also #1873.

throws-like q| class GH1758_2 { submethod x { };}; GH1758_2.new._ |,
X::Method::NotFound,
message => /"Did you mean 'x'"/,
'Ancestor submethods should not be typo-suggested';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And I'd suggest changing this description to something like 'Submethods at the same inheritance level should be suggested'

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please check this?

@JJ
Copy link
Collaborator

JJ commented May 3, 2020

Also, there are conflicts now. Can you please check?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants