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

Don't emit FURB120 when deleting default arg would change semantics #289

Merged
merged 1 commit into from
Sep 12, 2023

Conversation

dosisod
Copy link
Owner

@dosisod dosisod commented Sep 12, 2023

Closes #288.

Previously FURB120 would emit an error for any default arg it found, but in some cases following Refurb's advice would cause an error. The issue is that non-default positional args that follow default positional args cannot be removed, so Refurb should ignore these default values that are "trapped" behind a non-default one.

Closes #288.

Previously FURB120 would emit an error for any default arg it found, but in
some cases following Refurb's advice would cause an error. The issue is that
non-default positional args that follow default positional args cannot be
removed, so Refurb should ignore these default values that are "trapped" behind
a non-default one.
@dosisod dosisod merged commit 706b451 into master Sep 12, 2023
3 checks passed
@dosisod dosisod deleted the fix-issue-288 branch September 12, 2023 04:29
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.

[Bug]: FURB120 advises change that would be wrong
1 participant