Skip to content
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

Read a negative address value from the stack after switching to rustc 1.85 #4446

Open
tomasol opened this issue Mar 6, 2025 · 1 comment
Labels

Comments

@tomasol
Copy link

tomasol commented Mar 6, 2025

Describe the Bug

I have a WASM project that is using prost-wkt-types. After switching rustc from 1.84 to 1.85 wasm-bindgen started failing with:

thread 'main' panicked at /build/wasm-bindgen-cli-0.2.100-vendor/wasm-bindgen-wasm-interpreter-0.2.100/src/lib.rs:245:21:
prost_wkt_types::pbstruct::_::_::__ctor::he32f530e01fca88f: Read a negative address value from the stack. Did we run out of memory?
stack backtrace:
   0: rust_begin_unwind
   1: core::panicking::panic_fmt
   2: wasm_bindgen_wasm_interpreter::Interpreter::call
   3: wasm_bindgen_wasm_interpreter::Interpreter::call
   4: wasm_bindgen_wasm_interpreter::Interpreter::call
   5: wasm_bindgen_wasm_interpreter::Interpreter::interpret_descriptor
   6: wasm_bindgen_cli_support::descriptors::execute
   7: wasm_bindgen_cli_support::Bindgen::generate_output
   8: wasm_bindgen_cli_support::Bindgen::generate
   9: wasm_bindgen::main
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

Steps to Reproduce

I have created a reproducer repo. The issue is visible as the GitHub Action result or locally as described in the readme.

Expected Behavior

It works with rustc 1.84

Actual Behavior

Fails with rustc 1.85

Additional Context

Not sure where the actual error comes from rustc, wasm-bindgen, or prost-wkt-types

@tomasol tomasol added the bug label Mar 6, 2025
@laskinner
Copy link

I'm having this issue as well in Leptos. App compiles and runs fine with 1.84, but 1.85 and above throw the same error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants