mirror of
https://github.com/fluencelabs/assemblyscript
synced 2025-06-22 03:01:55 +00:00
Fix asc bundle with webpack 4, see #36; Function expression progress
This commit is contained in:
@ -5,11 +5,24 @@
|
||||
(elem (i32.const 0) $start~anonymous|0 $start~anonymous|0 $start~someName|2)
|
||||
(memory $0 1)
|
||||
(export "memory" (memory $0))
|
||||
(start $start~someName|2)
|
||||
(start $start)
|
||||
(func $start~anonymous|0 (; 0 ;) (type $ii) (param $0 i32) (result i32)
|
||||
(get_local $0)
|
||||
)
|
||||
(func $start~someName|2 (; 1 ;) (type $v)
|
||||
(nop)
|
||||
)
|
||||
(func $start (; 2 ;) (type $v)
|
||||
(drop
|
||||
(call $start~anonymous|0
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
(drop
|
||||
(call $start~anonymous|0
|
||||
(i32.const 2)
|
||||
)
|
||||
)
|
||||
(call $start~someName|2)
|
||||
)
|
||||
)
|
||||
|
@ -1,11 +1,11 @@
|
||||
var f1 = function(a: i32): i32 {
|
||||
return a;
|
||||
};
|
||||
f1;
|
||||
f1(1);
|
||||
var f2 = (a: i32): i32 => {
|
||||
return a;
|
||||
};
|
||||
f2;
|
||||
f2(2);
|
||||
var f3 = function someName(): void {
|
||||
};
|
||||
f3;
|
||||
f3();
|
||||
|
@ -24,13 +24,15 @@
|
||||
)
|
||||
(func $start (; 3 ;) (type $v)
|
||||
(drop
|
||||
(get_global $function-expression/f1)
|
||||
(call $start~anonymous|0
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
(drop
|
||||
(get_global $function-expression/f2)
|
||||
)
|
||||
(drop
|
||||
(get_global $function-expression/f3)
|
||||
(call $start~anonymous|1
|
||||
(i32.const 2)
|
||||
)
|
||||
)
|
||||
(call $start~someName|2)
|
||||
)
|
||||
)
|
||||
|
Reference in New Issue
Block a user