-
Notifications
You must be signed in to change notification settings - Fork 934
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Return missing in module #357
Comments
What's the contents of the "a.js" file? |
Simple add function which add two numbers and return output |
static int eval_buf(JSContext *ctx, const void *buf, int buf_len,
} using this eval_buf, for non_module it works and returns as expected but for module (.js using import statements) it doesn't returns anything |
function main() {
return 10;
}
main();
Where does the return exactly goes?
i was trying to get the result of return for this program
using jS_EVAL -> JS_EVAL_FUNCTION -> JS_STD_AWAIT
after these i get "undefined" in value.
Am i missing anything or its the default behaviour?
The text was updated successfully, but these errors were encountered: