You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
let a = x // => Uncaught ReferenceError: x is not defined
a // Uncaught ReferenceError: a is not defined
let a // Uncaught SyntaxError: Identifier 'a' has already been declared
Example2:
let o = { x: 1 }
let a = o.keys() // => Uncaught TypeError: o.keys is not a function
a // Uncaught ReferenceError: a is not defined
let a = Object.keys(o) // Uncaught SyntaxError: Identifier 'a' has already been declared
How often does it reproduce? Is there a required condition?
Always
What is the expected behavior?
When there are errors during variable initialization, the variable (a) should be undefined
What do you see instead?
Either Uncaught ReferenceError: a is not defined or Uncaught SyntaxError: Identifier 'a' has already been declared, if trying to redefine a
Additional information
Also tested on node.js v16.9.1, same error
The text was updated successfully, but these errors were encountered:
Version
v17.3.0
Platform
Microsoft Windows NT 10.0.19042.0 x64
Subsystem
No response
What steps will reproduce the bug?
Example1:
Example2:
How often does it reproduce? Is there a required condition?
Always
What is the expected behavior?
When there are errors during variable initialization, the variable (a) should be undefined
What do you see instead?
Either Uncaught ReferenceError: a is not defined or Uncaught SyntaxError: Identifier 'a' has already been declared, if trying to redefine a
Additional information
Also tested on node.js v16.9.1, same error
The text was updated successfully, but these errors were encountered: