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
Local count too large #478
Comments
I got this problem too. |
Same here. Total guess but I think it would be some kind of recursion problem. self.task = Some(self.fetch_service.fetch(get_request, handler)); The code is quite explicit and partially copied from https://github.com/DenisKolodin/yew/blob/a6a73948331ae50a9b6a196c721f21b4a39b52d1/examples/dashboard/src/lib.rs Once the line is commented, every works fine/compiles. |
See #455, at the moment the fix is to compile with |
It seems it would be beneficial to add this to the README in the root of this repo or in a README in the example directory that require this to function. |
For me it prints this in the console in the brave browser:
After some inspector cluseuing I think the fault lies with this function in the http library: https://github.com/hyperium/http/blob/master/src/header/name.rs#L1061 It has a lot of heavy macro usage, and a big match statement. |
I ran it through: this:
I guess that with optimisation turned off it doesn't pre-calculate all the addition and makes wasm do it. |
Advantages: 1. Shorter code 2. More rusty and less macroy 3. It should work in wasm now untested and make yew users happier yewstack/yew#478
I have created a pull request with the http project that fixes this: hyperium/http#324 Until this all gets accepted and merged, you can use my temporary fork of yew in debug mode: https://github.com/matiu2/yew |
Advantages: 1. Shorter code 2. More rusty and less macroy 3. It should work in wasm now untested and make yew users happier yewstack/yew#478
Advantages: 1. Shorter code 2. More rusty and less macroy 3. It should work in wasm now untested and make yew users happier yewstack/yew#478
Advantages: 1. Shorter code 2. More rusty and less macroy 3. It should work in wasm now untested and make yew users happier yewstack/yew#478
This landed in http trunk now. I guess once they do a new stable release, it'll be fixed for everyone here too: hyperium/http#324 |
I can confirm this is working now since about 5 days ago, when http released https://github.com/hyperium/http/releases/tag/v0.1.18 To test, just run the dashboard example in non-release mode and download something through http. This issue can be closed. |
Great, thanks @matiu2! |
Description
bug-report
In the example "showcase" and a few others (like "dashboard") I can not get them to run. Others like the custom_components work fine
Expected Results
to be able to load the page....
Actual Results
Uncaught (in promise) CompileError: AsyncCompilation: Compiling wasm function "wasm-function[42950]" failed: local count too large @+11247460
Context (Environment)
Rust: rustc 1.35.0-nightly (26b4cb484 2019-03-09)
yew: v0.7.0
target:
cargo-web: cargo-web 0.6.23
browser if relevant
I get the error in both Chrome and Firefox Dev Edition.
Chrome: Version 72.0.3626.121 (Official Build) (64-bit) Linux
FF: 66.0b14 (64-bit) Linux
Any help or guidance appreciated!
Any further info I can provide to help with this let me know!
The text was updated successfully, but these errors were encountered: