Issue metadata
Sign in to add a comment
|
Unhelpful error: "Cannot set property '1' of undefined" - please say what name it is that's undefined.
Reported by
richard....@unipart.com,
Sep 10 2017
|
||||||||||||||||||||||
Issue descriptionUserAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/60.0.3112.113 Chrome/60.0.3112.113 Safari/537.36 Steps to reproduce the problem: var test = [1,2,3]; test[1] = 2; var test2; test2[1] = 22; What is the expected behavior? The first pair of lines are correct; the second will fail. However, the error message is rather less clear than it could be. What went wrong? I get the error message: "Cannot set property '1' of undefined". That's not as helpful as it could be, because Chrome has already de-referenced the thing that's not defined. What would be far better is the error: "Cannot set property '1' of 'test2' which is undefined. In other words, what I want to know is "there is a problem with test2, caused by it being undefined", not "there is a problem with something undefined... now you go figure out what it was that wasn't defined". This doesn't just affect arrays. Did this work before? No Chrome version: 60.0.3112.113 Channel: n/a OS Version: Ubuntu Flash Version:
,
Sep 11 2017
Assuming this as feature request, changing the status to untriage, so that the issue would be addressed. Thank you.
,
Sep 14 2017
@kozy, maybe merge this to the v8 bug linked above?
,
Sep 21 2017
|
|||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||
Comment 1 by woxxom@gmail.com
, Sep 10 2017