DescriptionDefer CONST_LEGACY redeclaration errors until runtime in harmony mode
This fixes a corner-case in redeclaration handling, where the ES2015
early error case got mixed up with legacy const handling in the parser.
Redeclaration using ES2015 'let' and 'const' should be early errors,
but legacy 'const' redeclaration has historically been a runtime error,
and should stay that way until legacy 'const' is gone.
The fix here is uglier than it might be due to
https://code.google.com/p/v8/issues/detail?id=4577, which keeps us
from simplifying the mess of if/else-if in the current code.
BUG=v8:4576
LOG=n
Committed: https://crrev.com/6c6dd449c3e17f30905a34242ebe2f0c42a24958
Cr-Commit-Position: refs/heads/master@{#32429}
Patch Set 1 #
Messages
Total messages: 8 (3 generated)
|