compiler: fix deferred calls to exported functions

Previously using defer with an exported function generated an invalid function call due to differences between TinyGo's calling convention and the C calling convention.
This commit is contained in:
Jaden Weiss
2020-02-26 15:54:00 -05:00
committed by Ayke
parent 4dfc289ae5
commit 6896b0014b
3 changed files with 17 additions and 5 deletions
+1
View File
@@ -4,6 +4,7 @@ Thing.Print: foo arg: bar
...run as defer 3
...run closure deferred: 4
...run as defer 1
...exported defer
loop 3
loop 2
loop 1