Skip to content

Commit

Permalink
Move Equals constraint into an intersection type. (#2123)
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielRosenwasser authored Jan 25, 2024
1 parent c940a9f commit ff3115c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/typeTestHelpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export declare const exactType: <T, U>(
) => IfEquals<T, U>

export function expectExactType<T>(t: T) {
return <U extends Equals<T, U>>(u: U) => {}
return <U extends T>(u: U & Equals<T, U>) => {}
}

type EnsureUnknown<T> = IsUnknown<T, any, never>
Expand Down

0 comments on commit ff3115c

Please sign in to comment.