Repository navigation
Conversation
o-murphy
force-pushed
the
fix/ports/webassembly-mp_hal_get_interrupt_char
branch
from
June 26, 2026 09:10
1beac0f to
471e51d
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #19382 +/- ##
=======================================
Coverage 98.51% 98.51%
=======================================
Files 177 177
Lines 22927 22927
=======================================
Hits 22586 22586
Misses 341 341 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
o-murphy
force-pushed
the
fix/ports/webassembly-mp_hal_get_interrupt_char
branch
from
June 28, 2026 01:02
471e51d to
98a935a
Compare
Contributor
Author
|
The real-world project where it used https://github.com/ballistics-lab/micropython-bclibc/blob/c2f785cd626d57c192ab63469d737f7c8917629b/usermod/Makefile#L276 |
Contributor
|
Also ran into this and have a patch for it in https://github.com/micropython/micropython/pull/19427/commits so +1, would reduce the surface of my unholy PR. |
dpgeorge
reviewed
Jul 9, 2026
o-murphy
force-pushed
the
fix/ports/webassembly-mp_hal_get_interrupt_char
branch
from
July 9, 2026 15:08
98a935a to
c53df7e
Compare
Signed-off-by: o-murphy <[email protected]>
o-murphy
force-pushed
the
fix/ports/webassembly-mp_hal_get_interrupt_char
branch
from
July 9, 2026 15:10
c53df7e to
a5bac1b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adjust the
ccallABI formp_hal_get_interrupt_char()on the WebAssembly port.mp_hal_get_interrupt_chartakes no arguments (void), butlibrary.jswas passing an argument.calling it via Emscripten's
ccallwith a spurious["number"]`` argument typeand
["null"]argument value:Attempting to pass arguments to a no-arguments WebAssembly function, even with
ccall, is against the type signature of the function and may result in misbehaviour, or even an exception being thrown, depending on the Emscripten build configuration.See #19380 (the
mp_hal_get_interrupt_charABI part, as maintainer confirmed).Testing
Tested on
webassemblyport (standard variant) under Node.js:make test) passes.Generative AI
I used generative AI tools when creating this PR, but a human has checked the
code and is responsible for the code and the description above.