v8/test/message/fail/param-function-redeclaration-as-let.out
Toon Verwaest c45850cd1e [parser] Declare variables through ExpressionScope
Use variable tracking from ExpressionScopes rather than the PatternRewriter and
PreParserExpression::variables_ to declare variables.

We only figure out that variables are non-simple parameters once we see the
first non-simple parameter. This still uses the pattern rewriter to make
variables non-simple (kLet instead of kVar).

Change-Id: I4a4ee4852d667c26806bb24896722cfea3e093f2
Reviewed-on: https://chromium-review.googlesource.com/c/1417630
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58954}
2019-01-21 11:37:32 +00:00

6 lines
142 B
Plaintext

*%(basename)s:6: SyntaxError: Identifier 'x' has already been declared
let x
^
SyntaxError: Identifier 'x' has already been declared