Skip to content

Emitter crashes for static property of class expression #9966

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ghost opened this issue Jul 26, 2016 · 0 comments
Closed

Emitter crashes for static property of class expression #9966

ghost opened this issue Jul 26, 2016 · 0 comments
Labels
Bug A bug in TypeScript Fixed A PR has been merged for this issue

Comments

@ghost
Copy link

ghost commented Jul 26, 2016

TypeScript Version: nightly

Code

(Requires --target es6)

(class {
    static x = 0;
});

Expected behavior: No crash

Actual behavior:

TypeError: Cannot read property 'id' of undefined
    at Object.getNodeId (tsc.js:13122:18)
    at getGeneratedNameForNode (tsc.js:30138:29)
    at emitClassLikeDeclarationForES6AndHigher (tsc.js:33691:37)
    at emitClassLikeDeclaration (tsc.js:33649:21)
    at emitClassExpression (tsc.js:33639:24)
    at emitJavaScriptWorker (tsc.js:35749:32)
    at emitNodeWithoutSourceMap (tsc.js:35557:21)
    at emitNodeWithSourceMap (tsc.js:35551:21)
    at emitNodeConsideringCommentsOption (tsc.js:35542:21)
    at emit (tsc.js:35525:17)
@ghost ghost added the Bug A bug in TypeScript label Jul 26, 2016
@ghost ghost added this to the TypeScript 2.0.1 milestone Jul 26, 2016
@ghost ghost self-assigned this Jul 26, 2016
@ghost ghost closed this as completed in #9969 Jul 27, 2016
@RyanCavanaugh RyanCavanaugh added the Fixed A PR has been merged for this issue label Aug 2, 2016
@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug A bug in TypeScript Fixed A PR has been merged for this issue
Projects
None yet
Development

No branches or pull requests

1 participant