Skip to content

fix(structure): ignore unused type parameters in call signatures#659

Merged
mrazauskas merged 2 commits intomainfrom
handle-unused-type-parameters
Jan 19, 2026
Merged

fix(structure): ignore unused type parameters in call signatures#659
mrazauskas merged 2 commits intomainfrom
handle-unused-type-parameters

Conversation

@mrazauskas
Copy link
Member

@mrazauskas mrazauskas commented Jan 18, 2026

When comparing type structure, unused type parameters should be ignored. They do not contribute to the resulting type:

import { expect } from "tstyche";

type Alpha = <T>(a: string) => void;

expect<Alpha>().type.toBe<(a: string) => void>();
expect<Alpha>().type.toBe<<T>(a: string) => void>();

@mrazauskas mrazauskas changed the title fix(structure): handle unused type parameters fix(structure): ignore unused type parameters Jan 18, 2026
@codacy-production
Copy link

codacy-production bot commented Jan 18, 2026

Coverage summary from Codacy

See diff coverage on Codacy

Coverage variation Diff coverage
+0.03% (target: -1.00%) 90.91% (target: 85.00%)
Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (cfb4fad) 7249 7157 98.73%
Head commit (f531b00) 7235 (-14) 7145 (-12) 98.76% (+0.03%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#659) 11 10 90.91%

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

See your quality gate settings    Change summary preferences

@mrazauskas mrazauskas changed the title fix(structure): ignore unused type parameters fix(structure): ignore unused type parameters in call signatures Jan 19, 2026
@mrazauskas mrazauskas marked this pull request as ready for review January 19, 2026 17:52
@mrazauskas mrazauskas enabled auto-merge (squash) January 19, 2026 17:53
@mrazauskas mrazauskas merged commit 4508592 into main Jan 19, 2026
22 checks passed
@mrazauskas mrazauskas deleted the handle-unused-type-parameters branch January 19, 2026 18:08
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.

1 participant