Skip to content

fix(lint): visit property names in destructuring assignments - #1147

Merged
camc314 merged 1 commit into
mainfrom
fix/lint-visit-destructuring-property-names
Nov 29, 2026
Merged

camc314 merged 1 commit into
mainfrom
fix/lint-visit-destructuring-property-names

Conversation

@camc314

@camc314 camc314 commented Nov 29, 2026 •

Copy link
Copy Markdown
Contributor

Ports oxc-project/tsgolint#1396 to tsrs.

In pattern mode, the lint traversal visited only a PropertyAssignment's initializer and skipped its name. That meant no rule saw expressions inside a computed key of a destructuring assignment:

async function f() {
  let x: number;
  ({ [await 1]: x } = { 1: 0 }); // await-thenable missed this
}

ESTree keeps the key on the pattern's Property and visits it in expression context, before the value. visit_lint_nodes now visits the name the same way, ahead of the initializer, matching tsgolint e1015111. This refreshes the await-thenable baseline to that commit and adds the upstream case, which fails without the traversal change.

Copilot AI balanced review requested due to automatic review settings November 29, 2026 17:09

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing. Review the Copilot code review billing settings.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 29, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-29T17:24:58.694697Z e7d929c New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@camc314
camc314 enabled auto-merge November 29, 2026 17:16
@camc314
camc314 added this pull request to the merge queue Nov 29, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to a conflict with the base branch Nov 29, 2026
@camc314
camc314 force-pushed the fix/lint-visit-destructuring-property-names branch from 4f0afdc to e7d929c Compare November 29, 2026 17:23
@camc314
camc314 added this pull request to the merge queue Nov 29, 2026
@camc314
camc314 removed this pull request from the merge queue due to a manual request Nov 29, 2026
@camc314
camc314 added this pull request to the merge queue Nov 29, 2026
@codspeed

codspeed Bot commented Nov 29, 2026

Copy link
Copy Markdown
Contributor

Merging this PR will not alter performance

Warning

oxc-project has exceeded the Hobby plan limit of 5 active contributors. Upgrade your plan or apply to the open source program by December 8, 2026 to keep using CodSpeed.

1 warning

⚠️ 4 benchmarks are dominated by system calls

System calls cannot be simulated consistently and are left out of the measure. The reported value understates the real cost. Switch to the Walltime instrument to measure them.

Learn more about system calls

See affected benchmarks

✅ 8 untouched benchmarks
⏩ 8 skipped benchmarks1


Comparing fix/lint-visit-destructuring-property-names (e7d929c) with main (c854fdd)

Open in CodSpeed

Footnotes

  1. 8 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

Merged via the queue into main with commit 35164b6 Nov 29, 2026
76 checks passed
@camc314
camc314 deleted the fix/lint-visit-destructuring-property-names branch November 29, 2026 18:11
@github-actions

Copy link
Copy Markdown
Contributor

Performance change vs main

Workflow run · main c854fdd3582e → PR merge 453958c7fe5a (head e7d929c8cfed)

Clef gate: Clef estimated 22.9% default and single-threaded wall time, 10.8% peak RSS, 10.9% single-threaded instruction count impact probability.

Release builds in fast mode (TSRS_FAST=1) with Hyperfine 2 hardware counters. After warming each binary, alternating main/PR pairs measure wall time at both the fast preset's default checker count and with --singleThreaded, with ten pairs per configuration by default. Instructions come from the single-threaded runs; peak RSS comes from the default-count runs.
Incremental runs start with fresh build info before every invocation; check runs disable incremental compilation.

Project Mode Single-thread wall time Δ Single-thread instructions Δ Default wall time Δ Default peak RSS Δ
vscode check -0.1% -0.001% +0.5% +0.3%
vscode incremental -0.5% -0.001% -0.5% +0.1%
xstate-main check +0.7% 0.000% -1.4% -0.2%
xstate-main incremental +0.3% +0.001% -2.4% -0.1%
webpack check -1.0% +0.002% -0.4% +0.3%
webpack incremental -0.1% -0.001% -3.3% +0.1%
mui-docs check -0.4% +0.001% +0.9% +0.3%
mui-docs incremental -0.4% +0.001% 0.0% 0.0%
Compiler check -0.3% 0.000% -0.1% 0.0%
Compiler incremental +0.4% 0.000% -0.2% -0.7%
Compiler-Unions check -0.3% +0.001% -0.7% -0.4%
Compiler-Unions incremental +0.3% 0.000% -0.8% -0.1%
cal-diy check -0.1% +0.001% -0.5% 0.0%
cal-diy incremental +0.3% 0.000% +0.5% +0.1%
formbricks-web check -0.2% -0.001% +0.2% 0.0%
formbricks-web incremental 0.0% +0.001% +0.4% +0.1%
supabase-studio check +0.7% +0.001% -0.2% +0.1%
supabase-studio incremental +0.5% +0.001% +0.4% -0.1%
t3code-server check -0.2% +0.001% +1.4% -0.3%
t3code-server incremental -0.3% 0.000% -0.2% 0.0%
mikro-orm check 0.0% +0.004% +0.3% 0.0%
mikro-orm incremental +0.2% +0.003% -0.8% 0.0%
next-packages-next check +0.7% 0.000% +1.1% -0.3%
next-packages-next incremental -0.1% +0.001% -0.2% 0.0%
next-root check -0.5% 0.000% -0.9% -0.4%
next-root incremental -0.5% +0.002% +0.7% -0.4%
storybook check +0.1% 0.000% +0.6% +0.3%
storybook incremental +0.7% -0.004% -1.3% -0.1%
nuxt check -0.2% +0.002% -1.1% -0.2%
nuxt incremental +0.6% -0.001% -2.2% 0.0%
playwright check -0.2% +0.001% +0.5% -0.4%
playwright incremental +0.3% 0.000% +2.8% 0.0%
drizzle-orm check +0.8% -0.003% -4.4% -0.7%
drizzle-orm incremental +0.2% +0.002% -0.4% -0.1%
typeorm check +1.6% -0.001% -1.9% 0.0%
typeorm incremental -0.6% +0.001% +2.9% +0.2%
date-fns check -0.3% +0.001% +2.6% +0.7%
date-fns incremental -2.1% -0.018% -1.3% -0.6%
opencode-core check 0.0% +0.005% -0.1% -0.2%
opencode-core incremental -0.7% +0.003% -0.1% 0.0%
lobehub check -0.2% -0.003% -0.2% 0.0%
lobehub incremental -0.6% +0.010% -0.6% 0.0%
sentry check +0.1% -0.001% +0.3% 0.0%
sentry incremental +0.3% +0.002% -0.6% +0.1%

Negative means the PR used less; positive means it used more. Deltas are medians of paired PR/main ratios for wall time and instructions. Single-threaded runs reduce scheduling noise; shared CI machines can still add noise to wall time.

Measured medians (main → PR)
Project Mode Single-thread wall time (s) Single-thread instructions Default wall time (s) Default peak RSS (MiB)
vscode check 8.305 → 8.294 81,816,059,461 → 81,815,490,084.5 1.434 → 1.436 1803.7 → 1809.0
vscode incremental 8.544 → 8.502 84,217,897,495 → 84,217,371,587.5 1.647 → 1.635 2127.6 → 2128.8
xstate-main check 0.561 → 0.560 5,520,546,843.5 → 5,520,559,359 0.146 → 0.144 240.7 → 240.1
xstate-main incremental 0.520 → 0.521 5,679,434,043 → 5,679,456,878 0.157 → 0.155 242.1 → 241.9
webpack check 0.922 → 0.915 10,759,903,480.5 → 10,760,158,954 0.196 → 0.198 400.9 → 402.0
webpack incremental 0.945 → 0.945 10,980,279,176.5 → 10,980,198,194.5 0.253 → 0.247 398.3 → 398.8
mui-docs check 2.533 → 2.522 32,889,746,455 → 32,889,788,900.5 1.033 → 1.047 1195.6 → 1199.7
mui-docs incremental 2.491 → 2.484 34,221,552,358 → 34,221,409,879.5 1.084 → 1.091 1142.2 → 1142.3
Compiler check 0.141 → 0.139 1,745,225,972 → 1,745,218,566.5 0.063 → 0.064 77.2 → 77.2
Compiler incremental 0.142 → 0.141 1,759,524,616 → 1,759,525,238.5 0.066 → 0.065 78.8 → 78.2
Compiler-Unions check 0.195 → 0.193 3,014,340,999.5 → 3,014,350,024.5 0.092 → 0.091 80.6 → 80.3
Compiler-Unions incremental 0.198 → 0.198 3,026,960,055 → 3,026,963,882.5 0.094 → 0.094 83.7 → 83.7
cal-diy check 2.557 → 2.547 28,707,272,824.5 → 28,708,224,732 0.810 → 0.810 1337.1 → 1337.1
cal-diy incremental 2.756 → 2.768 30,307,888,493 → 30,307,482,826.5 1.047 → 1.051 1246.1 → 1247.1
formbricks-web check 3.356 → 3.343 36,892,707,810.5 → 36,891,879,917 0.849 → 0.852 1560.0 → 1559.6
formbricks-web incremental 3.544 → 3.542 39,473,903,786.5 → 39,474,641,042.5 1.083 → 1.086 1600.1 → 1600.9
supabase-studio check 3.857 → 3.876 40,539,163,923 → 40,539,189,171.5 0.977 → 0.978 1287.1 → 1288.2
supabase-studio incremental 3.956 → 3.972 43,469,998,764 → 43,470,688,650.5 1.080 → 1.076 1343.4 → 1342.6
t3code-server check 3.495 → 3.508 40,781,077,563 → 40,781,779,019 1.121 → 1.136 1301.3 → 1297.4
t3code-server incremental 3.681 → 3.670 41,289,155,326 → 41,290,289,197 1.434 → 1.442 1293.9 → 1294.0
mikro-orm check 3.973 → 3.966 44,047,037,230 → 44,048,464,732 0.825 → 0.827 1257.6 → 1257.0
mikro-orm incremental 4.044 → 4.035 44,355,605,022 → 44,357,133,062.5 0.953 → 0.950 1237.5 → 1236.8
next-packages-next check 1.437 → 1.443 17,277,977,448.5 → 17,277,826,020 0.359 → 0.364 554.9 → 553.3
next-packages-next incremental 1.525 → 1.522 17,588,796,702.5 → 17,589,028,943.5 0.450 → 0.448 555.1 → 555.2
next-root check 1.150 → 1.143 13,893,431,183.5 → 13,893,443,884.5 0.252 → 0.250 427.7 → 425.8
next-root incremental 1.222 → 1.218 14,350,194,794 → 14,350,309,388.5 0.312 → 0.312 468.1 → 466.4
storybook check 0.758 → 0.759 8,813,028,413 → 8,813,038,633 0.197 → 0.194 389.7 → 390.8
storybook incremental 0.796 → 0.797 9,132,438,165.5 → 9,132,328,024.5 0.238 → 0.235 369.3 → 368.9
nuxt check 0.812 → 0.811 8,428,729,041.5 → 8,428,876,358 0.209 → 0.210 385.5 → 384.7
nuxt incremental 0.921 → 0.923 8,824,968,551 → 8,824,893,662 0.261 → 0.250 384.7 → 384.7
playwright check 0.660 → 0.655 7,363,130,365.5 → 7,363,164,954.5 0.172 → 0.170 359.4 → 358.1
playwright incremental 0.679 → 0.683 7,539,507,927.5 → 7,539,470,550 0.184 → 0.186 337.6 → 337.5
drizzle-orm check 0.511 → 0.513 5,907,260,789.5 → 5,906,954,031.5 0.178 → 0.173 376.6 → 374.1
drizzle-orm incremental 0.522 → 0.522 6,075,974,308.5 → 6,076,116,456.5 0.175 → 0.173 340.3 → 339.9
typeorm check 0.573 → 0.579 6,344,424,814 → 6,344,309,832 0.135 → 0.131 224.7 → 224.7
typeorm incremental 0.639 → 0.636 6,728,479,719 → 6,728,541,977 0.171 → 0.172 229.7 → 230.2
date-fns check 0.272 → 0.271 3,297,380,607.5 → 3,297,319,320 0.082 → 0.083 149.9 → 151.0
date-fns incremental 0.308 → 0.302 3,530,835,902 → 3,529,730,955 0.100 → 0.098 161.6 → 160.7
opencode-core check 2.117 → 2.124 25,106,925,407 → 25,107,174,381.5 1.079 → 1.079 1185.0 → 1182.8
opencode-core incremental 2.309 → 2.299 25,468,097,603 → 25,468,729,578.5 1.173 → 1.170 1090.6 → 1090.8
lobehub check 16.834 → 16.789 185,342,622,771.5 → 185,332,814,947 5.602 → 5.593 4376.3 → 4378.2
lobehub incremental 16.804 → 16.711 188,890,598,140.5 → 188,912,977,795.5 6.811 → 6.772 4432.0 → 4430.1
sentry check 7.678 → 7.683 91,312,430,511 → 91,309,805,992.5 1.689 → 1.692 1753.7 → 1753.3
sentry incremental 8.493 → 8.523 93,269,141,836 → 93,271,038,974.5 2.237 → 2.224 1894.4 → 1896.9

tsrs-lint

Release tsrs-lint linting each project's source files with all 61 rules. After a warmup run of each binary, alternating main/PR pairs (10 per mode) measure wall time, CPU time and peak RSS with TSRS_FAST unset and with TSRS_FAST=1.

Project Mode Wall time Δ CPU time Δ Peak RSS Δ Diagnostics (main → PR)
webpack default -1.3% -0.2% 0.0% 35405, identical
webpack TSRS_FAST=1 -0.9% -0.3% 0.0% 35405, identical
drizzle-orm default -1.2% +0.4% 0.0% 7057, identical
drizzle-orm TSRS_FAST=1 -0.9% -1.9% +0.2% 7057, identical
xstate-main default +0.8% +1.1% -0.1% 6489, identical
xstate-main TSRS_FAST=1 +1.0% +0.5% -0.5% 6489, identical

Negative means the PR used less. Wall and CPU time deltas are medians of paired PR/main ratios; peak RSS compares medians.

Measured lint medians (main → PR)
Project Mode Wall time (s) CPU time (s) Peak RSS (MiB)
webpack default 0.357 → 0.355 1.824 → 1.828 454.7 → 454.5
webpack TSRS_FAST=1 0.356 → 0.355 1.825 → 1.821 454.8 → 454.7
drizzle-orm default 0.217 → 0.215 1.159 → 1.162 392.7 → 392.7
drizzle-orm TSRS_FAST=1 0.219 → 0.215 1.170 → 1.150 391.9 → 392.7
xstate-main default 0.306 → 0.308 1.345 → 1.366 336.8 → 336.6
xstate-main TSRS_FAST=1 0.309 → 0.313 1.363 → 1.366 337.6 → 335.9

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants