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

Unified Diff: test/codegen/destructuring.dart

Issue 1677863002: Use default params when --destructure-named-params + fix renaming of reserved destructured params (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 4 years, 10 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 | « lib/src/js/template.dart ('k') | test/codegen/expect/closure.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/codegen/destructuring.dart
diff --git a/test/codegen/destructuring.dart b/test/codegen/destructuring.dart
new file mode 100644
index 0000000000000000000000000000000000000000..a0912437ed357d714d59eaf3e44dedda0ccb4567
--- /dev/null
+++ b/test/codegen/destructuring.dart
@@ -0,0 +1,20 @@
+f(int a, b, [c = 1]) {
+ f(a, b, c);
+}
+g(int a, b, {c : 1}) {
+ f(a, b, c);
+}
+
+invalid_names1(int let, function, arguments) {
+ f(let, function, arguments);
+}
+invalid_names2([int let, function = 1, arguments]) {
+ f(let, function, arguments);
+}
+invalid_names3({int let, function, arguments : 2}) {
+ f(let, function, arguments);
+}
+
+names_clashing_with_object_props({int constructor, valueOf, hasOwnProperty : 2}) {
+ f(constructor, valueOf, hasOwnProperty);
+}
« no previous file with comments | « lib/src/js/template.dart ('k') | test/codegen/expect/closure.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698