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
typeof(console['log'](1),a);// Uncaught ReferenceError: a is not defined
The typeof expression is special because when checking a single Identifier node, there will not be an error thrown, even if the variable doesn't exist. This only applies on Identifier nodes, when joined in a sequence expression it will error. The fix is to make Control Flow Flattening not change typeof expressions.
The text was updated successfully, but these errors were encountered:
Describe the bug:
Control Flow Flattening breaks typeof expression
Config and Small code sample
Config:
Code:
Output:
The
typeof
expression is special because when checking a singleIdentifier
node, there will not be an error thrown, even if the variable doesn't exist. This only applies onIdentifier
nodes, when joined in a sequence expression it will error. The fix is to make Control Flow Flattening not changetypeof
expressions.The text was updated successfully, but these errors were encountered: