Remove faulty support for wasm64-unknown-unknown#551
Merged
newpavlov merged 1 commit intorust-random:masterfrom Nov 29, 2024
Merged
Remove faulty support for wasm64-unknown-unknown#551newpavlov merged 1 commit intorust-random:masterfrom
wasm64-unknown-unknown#551newpavlov merged 1 commit intorust-random:masterfrom
Conversation
daxpedda
commented
Nov 29, 2024
| | `rdrand` | x86, x86-64 | `x86_64-*`, `i686-*` | [`RDRAND`] instruction | ||
| | `rndr` | AArch64 | `aarch64-*` | [`RNDR`] register | ||
| | `esp_idf` | ESP-IDF | `*‑espidf` | [`esp_fill_random`]. WARNING: can return low-quality entropy without proper hardware configuration! | ||
| | `wasm_js` | Web Browser, Node.js | `wasm32‑unknown‑unknown` | [`Crypto.getRandomValues`] if available, then [`crypto.randomFillSync`] if on Node.js (see [WebAssembly support]) |
Contributor
Author
There was a problem hiding this comment.
wasm-bindgen only supports wasm32-unknown-unknown (and now wasm32v1-none, see #541), it does not support Emscripten. Even though Emscriptens target is wasm32-unknown-emscripten, I'm not what else was being implied here.
Member
There was a problem hiding this comment.
wasm_js works only on target_os = "unknown" targets, so IIUC it can not be used with Emscripten.
Contributor
Author
There was a problem hiding this comment.
Yep. I was referring to the fact that it previously said wasm*-*-unknown, implying the target_os could be something else.
newpavlov
approved these changes
Nov 29, 2024
takumi-earth
pushed a commit
to earthlings-dev/getrandom
that referenced
this pull request
Jan 27, 2026
This removes the previously in rust-random#303 added support for `wasm64-unknown-unknown`. `wasm-bindgen` does in fact not support the Memory64 proposal. The reason it still compiled is that `wasm-bindgen` emits panicking stubs for any target it doesn't support. However, during runtime this would have failed.
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.
This removes the previously in #303 added support for
wasm64-unknown-unknown.wasm-bindgendoes in fact not support the Memory64 proposal. The reason it still compiled is thatwasm-bindgenemits panicking stubs for any target it doesn't support. However, during runtime this would have failed.