Index: test/codegen/expect/js/src/varargs.js |
diff --git a/test/codegen/expect/js/src/varargs.js b/test/codegen/expect/js/src/varargs.js |
new file mode 100644 |
index 0000000000000000000000000000000000000000..3081572a9796a2b659e46bd316042de4c8b8e185 |
--- /dev/null |
+++ b/test/codegen/expect/js/src/varargs.js |
@@ -0,0 +1,23 @@ |
+dart_library.library('js/src/varargs', null, /* Imports */[ |
+ "dart/_runtime", |
+ 'dart/core' |
+], /* Lazy imports */[ |
+], function(exports, dart, core) { |
+ 'use strict'; |
+ let dartx = dart.dartx; |
+ class _Rest extends core.Object { |
+ _Rest() { |
+ } |
+ } |
+ dart.setSignature(_Rest, { |
+ constructors: () => ({_Rest: [_Rest, []]}) |
+ }); |
+ let rest = dart.const(new _Rest()); |
+ function spread(args) { |
+ dart.throw(new core.StateError('The spread function cannot be called, ' + 'it should be compiled away.')); |
+ } |
+ dart.fn(spread); |
+ // Exports: |
+ exports.rest = rest; |
+ exports.spread = spread; |
+}); |