Skip to content

bugfix: Fix issue with empty name throwing exceptions#25752

Merged
zielinsky merged 1 commit intoscala:mainfrom
tgodzik:fix-empty-name
Apr 10, 2026
Merged

bugfix: Fix issue with empty name throwing exceptions#25752
zielinsky merged 1 commit intoscala:mainfrom
tgodzik:fix-empty-name

Conversation

@tgodzik
Copy link
Copy Markdown
Contributor

@tgodzik tgodzik commented Apr 9, 2026

I could reproduce it in the presentation compiler module, it would sometimes break when rapidly writing code.

How much have you relied on LLM-based tools in this contribution?

None

How was the solution tested?

Manually working on the compiler.

Additional notes

@tgodzik tgodzik requested a review from zielinsky April 9, 2026 17:34
val nameString = name.toString
if nameString.isEmpty then false
else if completionMode.is(Mode.Member) then CompletionFuzzy.matchesSubCharacters(completionPos.query, name.toString)
else CompletionFuzzy.matches(completionPos.query, name.toString)
Copy link
Copy Markdown
Contributor

@som-snytt som-snytt Apr 9, 2026

Choose a reason for hiding this comment

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

did you intend nameString again? edit: in both places.
My style would be nameString.nonEmpty && { the rest } for some reason to be discussed at happy hour.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

fixed!

I could reproduce it in the presentation compiler module, it would sometimes break when rapidly writing code.
Copy link
Copy Markdown
Member

@zielinsky zielinsky left a comment

Choose a reason for hiding this comment

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

lgtm

@zielinsky zielinsky merged commit a0874f5 into scala:main Apr 10, 2026
106 of 107 checks passed
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.

3 participants