summaryrefslogtreecommitdiff
path: root/test/bad_params.asm.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/bad_params.asm.js')
-rw-r--r--test/bad_params.asm.js30
1 files changed, 30 insertions, 0 deletions
diff --git a/test/bad_params.asm.js b/test/bad_params.asm.js
new file mode 100644
index 000000000..cc5e7ccf8
--- /dev/null
+++ b/test/bad_params.asm.js
@@ -0,0 +1,30 @@
+function asm(global, env, buffer) {
+ "use asm";
+
+ function missing(x, y) {
+ x = x | 0;
+ y = +y;
+ }
+
+ function extra(x, y) {
+ x = x | 0;
+ y = +y;
+ }
+
+ function mix(a) {
+ a = a | 0;
+ }
+
+ function ex() {
+ missing();
+ missing(1);
+ extra(1, +2, 3);
+ extra(1, +2, 3, 4);
+ mix();
+ mix(1);
+ mix(1, 2);
+ }
+
+ return { ex: ex };
+}
+