sapling
sapling copied to clipboard
can't build with local rust version
I get this when compiling:
error[E0658]: use of unstable library feature 'nonzero_ops'
--> lib/repolock/src/lib.rs:147:41
|
147 | store_lock.1 = store_lock.1.checked_add(1).unwrap();
| ^^^^^^^^^^^
|
= note: see issue #84186 <https://github.com/rust-lang/rust/issues/84186> for more information
error[E0658]: use of unstable library feature 'nonzero_ops'
--> lib/repolock/src/lib.rs:167:35
|
167 | wc_lock.1 = wc_lock.1.checked_add(1).unwrap();
| ^^^^^^^^^^^
|
= note: see issue #84186 <https://github.com/rust-lang/rust/issues/84186> for more information
For more information about this error, try `rustc --explain E0658`.
error: could not compile `repolock` due to 2 previous errors
it looks like there's a missing rust-toolchain.toml to fix the rust version used in this project
Is your local rust toolchain old? Looks like that was stabilized in 1.64 which is somewhat recent but not that ridiculously so.
yeah, I fixed it doing a rustup update, but I have a PR adding a rust-toolchain.toml which should fix it for everyone (https://github.com/facebook/sapling/pull/259)