Skip to content

fix(lint/no-unnecessary-type-arguments): treat interface heritage as a type context - #1158

Merged
camc314 merged 1 commit into
mainfrom
fix/lint-no-unnecessary-type-arguments-1407
Nov 30, 2026
Merged

camc314 merged 1 commit into
mainfrom
fix/lint-no-unnecessary-type-arguments-1407

Conversation

@camc314

@camc314 camc314 commented Nov 30, 2026

Copy link
Copy Markdown
Contributor

Ports oxc-project/tsgolint#1407 (0e3dd5f4), including its baseline update.

is_in_type_context treated an ExpressionWithTypeArguments as a type only when its direct parent was an interface, but its parent is the HeritageClause. Interface extends clauses fell through to the value path, so when a value of the same name was in scope, the type arguments were compared against the constructor's defaults. Interface heritage is now a type context, as in typescript-eslint.

interface Base<T = string> {
  value: T;
}
declare var Base: { new <T = number>(): { value: T } };
interface Child extends Base<number> {} // no longer reported
interface Child2 extends Base<string> {} // now reported

Copilot AI balanced review requested due to automatic review settings November 30, 2026 11:55

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.

@camc314
camc314 added this pull request to stack #1163 November 30, 2026 11:56
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 30, 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-30T13:00:39.396436Z dcfde86 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 stacked auto-merge November 30, 2026 12:00
@camc314
camc314 added this pull request to the merge queue Nov 30, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to invalid changes in the merge commit Nov 30, 2026
@camc314
camc314 added this pull request to the merge queue Nov 30, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to invalid changes in the merge commit Nov 30, 2026
@camc314
camc314 added this pull request to the merge queue Nov 30, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to invalid changes in the merge commit Nov 30, 2026
Base automatically changed from fix/lint-no-unnecessary-condition-1405 to main November 30, 2026 12:59
@camc314
camc314 force-pushed the fix/lint-no-unnecessary-type-arguments-1407 branch from 1507d31 to dcfde86 Compare November 30, 2026 12:59
@codspeed

codspeed Bot commented Nov 30, 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-no-unnecessary-type-arguments-1407 (dcfde86) with main (51f87a3)

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. ↩

@github-actions

Copy link
Copy Markdown
Contributor

Performance change vs main

Workflow run · main 51f87a34473b → PR merge 0d46f9a3d9e3 (head dcfde86816cb)

Clef gate: Clef estimated 20.2% default and single-threaded wall time, 13.9% peak RSS, 20.0% 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 failed — — —
vscode incremental failed — — —
xstate-main check failed — — —
xstate-main incremental failed — — —
webpack check failed — — —
webpack incremental failed — — —
mui-docs check -0.7% +0.002% -0.1% -0.2%
mui-docs incremental failed — — —
Compiler check failed — — —
Compiler incremental failed — — —
Compiler-Unions check failed — — —
Compiler-Unions incremental failed — — —
cal-diy check failed — — —
cal-diy incremental failed — — —
formbricks-web check failed — — —
formbricks-web incremental failed — — —
supabase-studio check failed — — —
supabase-studio incremental failed — — —
t3code-server check failed — — —
t3code-server incremental failed — — —
mikro-orm check failed — — —
mikro-orm incremental failed — — —
next-packages-next check failed — — —
next-packages-next incremental failed — — —
next-root check failed — — —
next-root incremental failed — — —
storybook check failed — — —
storybook incremental failed — — —
nuxt check failed — — —
nuxt incremental failed — — —
playwright check failed — — —
playwright incremental failed — — —
drizzle-orm check failed — — —
drizzle-orm incremental failed — — —
typeorm check failed — — —
typeorm incremental failed — — —
date-fns check failed — — —
date-fns incremental failed — — —
opencode-core check failed — — —
opencode-core incremental failed — — —
lobehub check failed — — —
lobehub incremental failed — — —
sentry check failed — — —
sentry incremental failed — — —

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.
Measurements missing or invalid on: vscode (check), vscode (incremental), xstate-main (check), xstate-main (incremental), webpack (check), webpack (incremental), mui-docs (incremental), Compiler (check), Compiler (incremental), Compiler-Unions (check), Compiler-Unions (incremental), cal-diy (check), cal-diy (incremental), formbricks-web (check), formbricks-web (incremental), supabase-studio (check), supabase-studio (incremental), t3code-server (check), t3code-server (incremental), mikro-orm (check), mikro-orm (incremental), next-packages-next (check), next-packages-next (incremental), next-root (check), next-root (incremental), storybook (check), storybook (incremental), nuxt (check), nuxt (incremental), playwright (check), playwright (incremental), drizzle-orm (check), drizzle-orm (incremental), typeorm (check), typeorm (incremental), date-fns (check), date-fns (incremental), opencode-core (check), opencode-core (incremental), lobehub (check), lobehub (incremental), sentry (check), sentry (incremental). See the workflow run for errors.

Measured medians (main → PR)
Project Mode Single-thread wall time (s) Single-thread instructions Default wall time (s) Default peak RSS (MiB)
mui-docs check 2.427 → 2.401 32,889,508,726.5 → 32,889,819,742 1.040 → 1.019 1182.8 → 1180.7

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.4% +0.7% -0.1% 35406, identical
webpack TSRS_FAST=1 +0.9% 0.0% 0.0% 35406, identical
drizzle-orm default +0.8% +0.1% -0.1% 7055, identical
drizzle-orm TSRS_FAST=1 +0.7% -0.5% -0.1% 7055, identical
xstate-main default -0.6% -0.1% -0.8% 6489, identical
xstate-main TSRS_FAST=1 -1.2% -0.7% -1.0% 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.361 → 0.365 1.864 → 1.886 455.1 → 454.9
webpack TSRS_FAST=1 0.360 → 0.362 1.869 → 1.867 455.1 → 455.0
drizzle-orm default 0.224 → 0.224 1.194 → 1.209 393.2 → 392.7
drizzle-orm TSRS_FAST=1 0.224 → 0.226 1.199 → 1.197 393.1 → 392.7
xstate-main default 0.317 → 0.318 1.396 → 1.394 338.0 → 335.4
xstate-main TSRS_FAST=1 0.318 → 0.315 1.404 → 1.387 338.7 → 335.4

@camc314
camc314 added this pull request to the merge queue Nov 30, 2026
Merged via the queue into main with commit 465bd15 Nov 30, 2026
34 of 77 checks passed
@camc314
camc314 deleted the fix/lint-no-unnecessary-type-arguments-1407 branch November 30, 2026 14:55
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