Skip to content

Support eval and exec mode in wasm #1648

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

Merged
merged 1 commit into from
Jan 3, 2020

Conversation

yanganto
Copy link
Contributor

  • Expose pyEval, pyExec, pyExecSingle in wasm module

This PR also fix #1612

@yanganto
Copy link
Contributor Author

The behavior in the console list as following

>> rp.pyEval("1+1")
← 2
>> rp.pyExec("1+1")
← undefined
>> rp.pyExecSingle("1+1\n2+2")
2
4
← 4

Copy link
Member

@coolreader18 coolreader18 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great, just a few nitpicks and this is good to merge.

- Expose `pyEval`, `pyExec`, `pyExecSingle` in wasm module
@yanganto
Copy link
Contributor Author

yanganto commented Jan 3, 2020

Thanks for the review.

@coolreader18 coolreader18 merged commit 73f1b11 into RustPython:master Jan 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[WASM] pyEval does not return JsValue
2 participants