Skip to content

Fix in erroneously being applied to this#3682

Merged
siegfriedpammer merged 1 commit intoicsharpcode:masterfrom
nikitalita:fix-in-this
Mar 20, 2026
Merged

Fix in erroneously being applied to this#3682
siegfriedpammer merged 1 commit intoicsharpcode:masterfrom
nikitalita:fix-in-this

Conversation

@nikitalita
Copy link
Copy Markdown
Contributor

@nikitalita nikitalita commented Mar 20, 2026

Problem

Fixes #3578

Solution

  • Fairly simple: in ChangeDirectionExpressionTo(), we just check if the parameter is a this expression and if the direction is in or ref readonly; if so, we don't change it.
  • At least one test covering the code changed

@siegfriedpammer siegfriedpammer merged commit 58c4cc9 into icsharpcode:master Mar 20, 2026
5 checks passed
@siegfriedpammer
Copy link
Copy Markdown
Member

Thank you for your contribution!

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.

in is erroneously applied to parameter when parameter is this

2 participants