You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It may help to rewrite the html or stringify macros in an iterative fashion to avoid recursion limits.
Repro:
$ git clone git@github.com:dbkaplun/solve24-rs.git
$ cd solve24-rs/solve24-web
$ git checkout stringify-recursion-repro
$ npm install && npm run parcel:build
npm WARN bootstrap@4.0.0 requires a peer of jquery@1.9.1 - 3 but none is installed. You must install peer dependencies yourself.
npm WARN bootstrap@4.0.0 requires a peer of popper.js@^1.12.9 but none is installed. You must install peer dependencies yourself.
up to date in 6.078s
> solve24-rs@1.0.0 parcel:build /Users/dbkaplun/solve24-rs/solve24-web
> COMMAND=build npm run parcel
> solve24-rs@1.0.0 parcel /Users/dbkaplun/solve24-rs/solve24-web
>export OUT_DIR='../p' PUBLIC_URL='/solve24-rs/p'&& rm -rf $OUT_DIR&& parcel $COMMAND index.html --out-file=index.html --out-dir=$OUT_DIR --public-url=$PUBLIC_URL
⏳ Building Cargo.toml...
🚨 /Users/dbkaplun/solve24-rs/solve24-web/Cargo.toml: Compilation failed!
warning: debug builds on the wasm32-unknown-unknown are currently totally broken
forcing a release build
Compiling solve24-web v1.0.0 (file:///Users/dbkaplun/solve24-rs/solve24-web)
error: Could not compile `solve24-web`.
error: recursion limit reached while expanding the macro `stringify`
--> src/main.rs:133:30
|
133 | _ => html! {
| ______________________________^
134 ||<table class="table",>
135 ||<thead>
136 ||<th scope="col",>{"#"}</th>
... |
141 ||</table>
142 || },
||_________________________^
|
= help: consider adding a `#![recursion_limit="128"]` attribute to your crate
= note: this error originates in a macro outside of the current crate (in Nightly builds, run with -Z external-macro-backtrace for more info)
error: build failed
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! solve24-rs@1.0.0 parcel: `export OUT_DIR='../p' PUBLIC_URL='/solve24-rs/p'&& rm -rf $OUT_DIR&& parcel $COMMAND index.html --out-file=index.html --out-dir=$OUT_DIR --public-url=$PUBLIC_URL`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the solve24-rs@1.0.0 parcel script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/dbkaplun/.npm/_logs/2018-02-22T01_14_58_918Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! solve24-rs@1.0.0 parcel:build: `COMMAND=build npm run parcel`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the solve24-rs@1.0.0 parcel:build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/dbkaplun/.npm/_logs/2018-02-22T01_14_58_978Z-debug.log
The text was updated successfully, but these errors were encountered:
I think this will have to wait until Rust finally stabilizes procedural macros. (The js! macro from stdweb has exactly the same problem.) Fortunately having to add the #![recursion_limit="128"] is not really a big deal.
It may help to rewrite the
html
orstringify
macros in an iterative fashion to avoid recursion limits.Repro:
The text was updated successfully, but these errors were encountered: