Skip to content

Accept using right associative parameters - #24766

Merged
som-snytt merged 5 commits into
scala:mainfrom
som-snytt:issue/24745-right-assoc-extension
Mar 4, 2026
Merged

Accept using right associative parameters#24766
som-snytt merged 5 commits into
scala:mainfrom
som-snytt:issue/24745-right-assoc-extension

Conversation

@som-snytt

Copy link
Copy Markdown
Contributor

Fixes #24745

The existing behavior is intended but unnecessarily restrictive.

@som-snytt

som-snytt commented Dec 16, 2025

Copy link
Copy Markdown
Contributor Author

This needs a tweak, as it "swaps" the implicit parameter, which is harmless but unintended. Edit: or maybe I'm misled by the way it's printed at typer.

@som-snytt
som-snytt marked this pull request as ready for review December 22, 2025 16:38
@Gedochao
Gedochao requested a review from sjrd January 13, 2026 10:11
@Gedochao

Gedochao commented Mar 3, 2026

Copy link
Copy Markdown
Contributor

Bump @sjrd

@sjrd sjrd left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM modulo the comment below.

Comment on lines +1191 to +1192
extParamss ++ mdef.paramss
def rightAssocParams =

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

There should be a blank line here. There are blank lines within rightAssocParams. Not having a blank line here suggests that paramss match ... does not belong to rightAssocParams.

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.

Also applied "less fewer braces" and "indented case".

@sjrd

sjrd commented Mar 4, 2026

Copy link
Copy Markdown
Member

To whoever is going to click the green button:
"CREATE A MERGE COMMIT" for this PR. Do NOT SQUASH.

@som-snytt
som-snytt force-pushed the issue/24745-right-assoc-extension branch from a37f089 to ac151e5 Compare March 4, 2026 12:00
@som-snytt
som-snytt enabled auto-merge March 4, 2026 12:10
@som-snytt
som-snytt merged commit 33a8b1d into scala:main Mar 4, 2026
66 of 67 checks passed
@som-snytt
som-snytt deleted the issue/24745-right-assoc-extension branch March 5, 2026 18:10
@WojciechMazur WojciechMazur added this to the 3.8.4 milestone Mar 31, 2026
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.

False "right-associative extension method cannot start with using clause" error

5 participants