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

Array destructuring with gaps fails #350

Closed
tex0l opened this Issue Nov 8, 2016 · 1 comment

Comments

Projects
None yet
2 participants
@tex0l

tex0l commented Nov 8, 2016

Hi,
ESDoc seems to be unable to parse this line of code:

const [ , , size ] = process.argv

It gives the following error:

TypeError: Cannot read property 'name' of null
    at VariableDoc._name (/usr/local/lib/node_modules/esdoc/out/src/Doc/VariableDoc.js:70:71)
    at VariableDoc._apply (/usr/local/lib/node_modules/esdoc/out/src/Doc/AbstractDoc.js:86:21)
    at VariableDoc.AbstractDoc (/usr/local/lib/node_modules/esdoc/out/src/Doc/AbstractDoc.js:70:10)
    at new VariableDoc (/usr/local/lib/node_modules/esdoc/out/src/Doc/VariableDoc.js:39:77)
    at DocFactory._createDoc (/usr/local/lib/node_modules/esdoc/out/src/Factory/DocFactory.js:635:14)
    at DocFactory._traverseComments (/usr/local/lib/node_modules/esdoc/out/src/Factory/DocFactory.js:565:24)
    at DocFactory.push (/usr/local/lib/node_modules/esdoc/out/src/Factory/DocFactory.js:451:22)
    at Controller.<anonymous> (/usr/local/lib/node_modules/esdoc/out/src/ESDoc.js:443:19)
    at Controller.enter (/usr/local/lib/node_modules/esdoc/out/src/Util/ASTUtil.js:57:20)
    at Controller.__execute (/usr/local/lib/node_modules/esdoc/node_modules/estraverse/estraverse.js:397:31)
    at Controller.traverse (/usr/local/lib/node_modules/esdoc/node_modules/estraverse/estraverse.js:495:28)

Is this normal ?

@h13i32maru

This comment has been minimized.

Show comment
Hide comment
@h13i32maru

h13i32maru Dec 27, 2016

Member

Thanks reporting.

I fixed it. And release in next version
075c54b

Member

h13i32maru commented Dec 27, 2016

Thanks reporting.

I fixed it. And release in next version
075c54b

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment