feat: implement call with ret type
Opened this issue · 1 comments
funatsufumiya commented
Since I have not been able to keep up with Breaking Change, and not completed PR, I will just raise the diff.
0006ebe...funatsufumiya:spellua:feat_call_ret
With this change, we can specify return type, but this is limited for typical case, and not enough implementation.
driver.call(void, "hello")
driver.call(void, "print_add", 1, 2)
driver.call(void, "other_any_func", 1, "a", true)
let ret: float = driver.call(float, "add", 1, 2)
echo ret
Probably typedesc
will fit in this case, but I don't know how to properly handle typedesc
in macro. (This is reason why this diff is not complete PR.)
I would like to leave this diff as a suggestion only and leave it to you to decide how to handle it.
glassesneo commented
I'd appreciate your continuous contribution🙇♂️ I'll take a look at the diff and take into account.