TypeScript/tests/cases/compiler/unionTypeWithLeadingOperator.ts

12 lines
241 B
TypeScript
Raw Normal View History

// @declaration: true
2016-11-19 22:30:33 +01:00
type A = | string;
type B =
| { type: "INCREMENT" }
| { type: "DECREMENT" };
type C = [| 0 | 1, | "foo" | "bar"];
export type D =
/*leading0*/
| /*leading1*/ 1 /*trailing1*/
| /*leading2*/ 2 /*trailing2*/;