+
Skip to content

Conversation

siketyan
Copy link
Member

@siketyan siketyan commented Jul 22, 2025

Summary

Fixes #6692

When the code fix of the rule noUnusedFunctionParameters tries to rename the declaration, it calls BatchMutation::<L>::rename_code_declaration. It may return false if the rename is not applicable (e.g. the new name is already declared in the scope). The issue was that the code fix returned an empty mutation. The caller should check if the returned value was true, and otherwise it should ignore the mutation result and just return None for the action result.

Test Plan

Added a snapshot test.

Docs

N/A

@siketyan siketyan requested review from a team July 22, 2025 13:02
@siketyan siketyan self-assigned this Jul 22, 2025
Copy link

changeset-bot bot commented Jul 22, 2025

🦋 Changeset detected

Latest commit: 2063464

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 13 packages
Name Type
@biomejs/biome Patch
@biomejs/cli-win32-x64 Patch
@biomejs/cli-win32-arm64 Patch
@biomejs/cli-darwin-x64 Patch
@biomejs/cli-darwin-arm64 Patch
@biomejs/cli-linux-x64 Patch
@biomejs/cli-linux-arm64 Patch
@biomejs/cli-linux-x64-musl Patch
@biomejs/cli-linux-arm64-musl Patch
@biomejs/wasm-web Patch
@biomejs/wasm-bundler Patch
@biomejs/wasm-nodejs Patch
@biomejs/backend-jsonrpc Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added A-Linter Area: linter L-JavaScript Language: JavaScript and super languages labels Jul 22, 2025
@github-actions github-actions bot added the A-Core Area: core label Jul 22, 2025
Copy link
Contributor

Parser conformance results on

js/262

Test result main count This PR count Difference
Total 50627 50627 0
Passed 49357 49357 0
Failed 1270 1270 0
Panics 0 0 0
Coverage 97.49% 97.49% 0.00%

jsx/babel

Test result main count This PR count Difference
Total 40 40 0
Passed 37 37 0
Failed 3 3 0
Panics 0 0 0
Coverage 92.50% 92.50% 0.00%

symbols/microsoft

Test result main count This PR count Difference
Total 6706 6706 0
Passed 2245 2245 0
Failed 4461 4461 0
Panics 0 0 0
Coverage 33.48% 33.48% 0.00%

ts/babel

Test result main count This PR count Difference
Total 822 822 0
Passed 731 731 0
Failed 91 91 0
Panics 0 0 0
Coverage 88.93% 88.93% 0.00%

ts/microsoft

Test result main count This PR count Difference
Total 18784 18784 0
Passed 14412 14412 0
Failed 4372 4372 0
Panics 0 0 0
Coverage 76.72% 76.72% 0.00%

Copy link

codspeed-hq bot commented Jul 22, 2025

CodSpeed Performance Report

Merging #6976 will not alter performance

Comparing fix/GH-6692 (2063464) with main (7c18d84)

Summary

✅ 115 untouched benchmarks

Copy link
Member

@ematipico ematipico left a comment

Choose a reason for hiding this comment

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

Good catch!

@siketyan siketyan merged commit 72ebadc into main Jul 22, 2025
30 checks passed
@siketyan siketyan deleted the fix/GH-6692 branch July 22, 2025 14:27
@github-actions github-actions bot mentioned this pull request Jul 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Core Area: core A-Linter Area: linter L-JavaScript Language: JavaScript and super languages

Projects

None yet

Development

Successfully merging this pull request may close these issues.

💅 Hang (infinite loop) while fixing JS file

2 participants

点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载