TypeScript/tests/cases/compiler/promiseDefinitionTest.ts
Nathan Shively-Sanders 91f4f3910d Test:Block-scoped definition of Promise works
Previously, a block-scoped definition of Promise like `class Promise<T>` in
a script would cause a crash
2017-06-08 13:46:48 -07:00

5 lines
77 B
TypeScript

// @target: es5
class Promise<T> {}
async function foo() {}
const x = foo();