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

Unified Diff: test/mjsunit/regress/regress-2470.js

Issue 2638513002: Enable --harmony-trailing-commas (Closed)
Patch Set: put the harmony flag back into the harmony test 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 | « test/mjsunit/extra-commas.js ('k') | test/test262/test262.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/regress/regress-2470.js
diff --git a/test/mjsunit/regress/regress-2470.js b/test/mjsunit/regress/regress-2470.js
index 29a0b250acb2e10919e9a8de8b3b73c57ba3cd7d..cba1b06c3e14716cb542dd96d3a4138fbd7fc502 100644
--- a/test/mjsunit/regress/regress-2470.js
+++ b/test/mjsunit/regress/regress-2470.js
@@ -34,12 +34,14 @@ assertThrows('Function("});(function(){");', SyntaxError);
// Test whether block comments are handled correctly.
assertDoesNotThrow('Function("/*", "*/", "/**/");');
assertDoesNotThrow('Function("/*", "a", "*/", "/**/");');
-assertThrows('Function("a", "/*", "*/", "/**/");', SyntaxError);
+assertDoesNotThrow('Function("a", "/*", "*/", "/**/");');
+assertThrows('Function("a", "/*", "*/", "b", "/*", "*/", "/**/");', SyntaxError);
// Test whether line comments are handled correctly.
assertDoesNotThrow('Function("//", "//")');
assertDoesNotThrow('Function("//", "//", "//")');
-assertThrows('Function("a", "//", "//")', SyntaxError);
+assertDoesNotThrow('Function("a", "//", "//")');
+assertThrows('Function("a", "", "//", "//")', SyntaxError);
// Some embedders rely on the string representation of the resulting
// function in cases where no formal parameters are specified.
« no previous file with comments | « test/mjsunit/extra-commas.js ('k') | test/test262/test262.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698