Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(35)

Unified Diff: test/cctest/test-parsing.cc

Issue 2654163008: [parser] Skipping inner funcs: add tests for variables called "arguments" (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-parsing.cc
diff --git a/test/cctest/test-parsing.cc b/test/cctest/test-parsing.cc
index 0229bb73db715884ce6cf9a22eea6f3c26591ce5..37b40e37ae3bb204d045b4531ff948c901cee7ad 100644
--- a/test/cctest/test-parsing.cc
+++ b/test/cctest/test-parsing.cc
@@ -9075,6 +9075,31 @@ TEST(PreParserScopeAnalysis) {
{"", "if (true) { var var1; var var1; var1 = 5; }"},
{"", "var var1; var var1; function f() { var1; }"},
{"", "var var1; var var1; function f() { var1 = 5; }"},
+
+ {"", "arguments;"},
+ {"", "arguments = 5;"},
+ {"", "function f() { arguments; }"},
+ {"", "function f() { arguments = 5; }"},
+
+ {"", "var arguments;"},
+ {"", "var arguments; arguments = 5;"},
+ {"", "if (true) { var arguments; }"},
+ {"", "if (true) { var arguments; arguments = 5; }"},
+ {"", "var arguments; function f() { arguments; }"},
+ {"", "var arguments; arguments = 5; function f() { arguments; }"},
+ {"", "var arguments; function f() { arguments = 5; }"},
+
+ {"", "let arguments;"},
+ {"", "let arguments; arguments = 5;"},
+ {"", "if (true) { let arguments; }"},
+ {"", "if (true) { let arguments; arguments = 5; }"},
+ {"", "let arguments; function f() { arguments; }"},
+ {"", "let arguments; arguments = 5; function f() { arguments; }"},
+ {"", "let arguments; function f() { arguments = 5; }"},
+
+ {"", "const arguments = 5;"},
+ {"", "if (true) { const arguments = 5; }"},
+ {"", "const arguments = 5; function f() { arguments; }"},
};
for (unsigned i = 0; i < arraysize(inners); ++i) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698