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

Better error for definition followed by keyword #18752

Merged
merged 1 commit into from
Oct 24, 2023

Conversation

nicolasstucki
Copy link
Contributor

Fixes #18750

@nicolasstucki nicolasstucki marked this pull request as ready for review October 24, 2023 12:21
-- [E161] Naming Error: tests/neg/i18750.scala:11:0 --------------------------------------------------------------------
11 |object if; // error // error
|^
|<error> clashes with class <error> in tests/neg/i18750.scala; the two must be defined together
Copy link
Contributor Author

@nicolasstucki nicolasstucki Oct 24, 2023

Choose a reason for hiding this comment

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

Note: This secondary error only on the object happens in combination with some of these other failures. This will probably not happen often in practice.

Copy link
Member

@bishabosha bishabosha Oct 24, 2023

Choose a reason for hiding this comment

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

are you working more on this? (you disabled auto-merge)

@bishabosha
Copy link
Member

bishabosha commented Oct 24, 2023

I'm working on a fix to the formatting of error messages also reported in the issue #18750

edit: see #18753

@nicolasstucki nicolasstucki merged commit 64134b3 into scala:main Oct 24, 2023
18 checks passed
@nicolasstucki nicolasstucki deleted the fix-18750 branch October 24, 2023 13:52
@Kordyjan Kordyjan added this to the 3.4.0 milestone Dec 20, 2023
WojciechMazur added a commit that referenced this pull request Jun 23, 2024
…0736)

Backports #18752 to the LTS branch.

PR submitted by the release tooling.
[skip ci]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

poor examples in "pattern expected" explanation with val def, (also do as name causes the problem)
3 participants