TypeScript/tests/cases/conformance/es2020/bigintMissingES2019.ts
Nathan Shively-Sanders 5f46d42ad1
Error on missing BigInt in es2020 (#37899)
* Error on missing BigInt in ES2020 too.

Previously it was only on ESNext, but bigint ships in ES 2020.

There are no tests for this; passing `false` doesn't cause any tests to
fail at least.

* add tests
2020-04-13 08:30:59 -07:00

9 lines
216 B
TypeScript

// @target: es2019
// @lib: dom,es2019
declare function test<A, B extends A>(): void;
test<{t?: string}, object>();
test<{t?: string}, bigint>();
// no error when bigint is used even when ES2020 lib is not present