mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
26 lines
513 B
TypeScript
26 lines
513 B
TypeScript
//// [tests/cases/conformance/types/typeRelationships/typeInference/noInferRedeclaration.ts] ////
|
|
|
|
//// [a.ts]
|
|
export const f = <T>(x: T, y: NoInfer<T>) => x;
|
|
|
|
//// [b.ts]
|
|
import { f } from "./a";
|
|
|
|
type NoInfer<T> = T & number;
|
|
|
|
export const g = f;
|
|
|
|
|
|
//// [a.js]
|
|
export const f = (x, y) => x;
|
|
//// [b.js]
|
|
import { f } from "./a";
|
|
export const g = f;
|
|
|
|
|
|
//// [a.d.ts]
|
|
export declare const f: <T>(x: T, y: NoInfer<T>) => T;
|
|
//// [b.d.ts]
|
|
import { f } from "./a";
|
|
export declare const g: typeof f;
|