Skip to content

TypeError: Cannot read property 'valueDeclaration' of undefined #46223

Closed
@huan

Description

@huan

Reproduce steps

$ git clone git@github.com:huan/clone-class.git
$ cd clone-class
$ git checkout f87276a443eb5d11e78d0ce21819b89ac16452d1
$ npm install
$ npx tsc --version
Version 4.4.3

$ npx tsc 
/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:92656
                throw e;
                ^

TypeError: Cannot read property 'valueDeclaration' of undefined
    at checkIndexConstraints (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:66778:47)
    at checkClassLikeDeclaration (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:67070:17)
    at checkClassDeclaration (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:66966:13)
    at checkSourceElementWorker (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:68323:28)
    at checkSourceElement (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:68165:17)
    at Object.forEach (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:132:30)
    at checkBlock (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:65555:20)
    at checkSourceElementWorker (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:68286:28)
    at checkSourceElement (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:68165:17)
    at checkFunctionOrMethodDeclaration (/Users/huan/git/huan/clone-class/node_modules/typescript/lib/tsc.js:65253:13)

Related Issue

Metadata

Metadata

Assignees

Labels

BugA bug in TypeScriptCrashFor flagging bugs which are compiler or service crashes or unclean exits, rather than bad outputFix AvailableA PR has been opened for this issue

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions