TypeScript/tests/cases/compiler/errorMessageOnIntersectionsWithDiscriminants01.ts
Daniel Rosenwasser 6a244b9058 Added test.
2019-03-27 23:29:22 -07:00

11 lines
194 B
TypeScript

// @noEmit: true
export type Common = { test: true } | { test: false };
export type A = Common & { foo: 1 };
export type B = Common & { bar: 1 };
declare const a: A;
declare let b: B;
b = a;