kurtlawrence / papyrus

(Rust) repl
MIT License
439 stars 14 forks source link

Failure to build using current (1.59) nightly #106

Open jaskij opened 2 years ago

jaskij commented 2 years ago

Rust version:

$ rustup run nightly rustc --version
rustc 1.59.0-nightly (e2116acae 2021-12-05)

Build output):

$ cargo +nightly install papyrus
### many properly compiling packages ellided ###
   Compiling rustc-ap-rustc_span v722.0.0
error[E0635]: unknown feature `thread_local_const_init`
  --> /home/jaskij/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_span-722.0.0/src/lib.rs:23:12
   |
23 | #![feature(thread_local_const_init)]
   |            ^^^^^^^^^^^^^^^^^^^^^^^

For more information about this error, try `rustc --explain E0635`.
error: could not compile `rustc-ap-rustc_span` due to previous error
warning: build failed, waiting for other jobs to finish...
error: failed to compile `papyrus v0.17.2`, intermediate artifacts can be found at `/tmp/cargo-installDt6oKN`

Caused by:
  build failed

Crates.io link to failing crate and version: https://crates.io/crates/rustc-ap-rustc_span/722.0.0

AdamJSoftware commented 2 years ago

same issue when compiling racer

error[E0635]: unknown feature `thread_local_const_init`
  --> /home/adam/.cargo/registry/src/github.com-1ecc6299db9ec823/rustc-ap-rustc_span-722.0.0/src/lib.rs:23:12
   |
23 | #![feature(thread_local_const_init)]
   |            ^^^^^^^^^^^^^^^^^^^^^^^

For more information about this error, try `rustc --explain E0635`.
error: could not compile `rustc-ap-rustc_span` due to previous error
warning: build failed, waiting for other jobs to finish...
error: failed to compile `racer v2.1.48`, intermediate artifacts can be found at `/tmp/cargo-install8olDbb`

Caused by:
  build failed
AdamJSoftware commented 2 years ago

Looking at the racer-rust issues it seems that I just needed to use a different version of the nightly compiler. I can confirm this worked for me. Please look at https://github.com/racer-rust/racer/issues/1173 and see if that version of the nightly compiler fixes your issues

AtlasPilotPuppy commented 2 years ago

It appears that racer is still using an old nightly compiler this is what worked for me

rustup toolchain add nightly-2021-06-07

cargo +nightly-2021-06-07 install papyrus
matheusinacio7 commented 1 year ago

After trying with the above suggestion from @anantasty I'm getting:

error[E0635]: unknown feature `proc_macro_span_shrink`
  --> /home/heyset/.cargo/registry/src/github.com-1ecc6299db9ec823/proc-macro2-1.0.51/src/lib.rs:92:30
   |
92 |     feature(proc_macro_span, proc_macro_span_shrink)
   |                              ^^^^^^^^^^^^^^^^^^^^^^

error: aborting due to previous error

For more information about this error, try `rustc --explain E0635`.
error: could not compile `proc-macro2`

To learn more, run the command again with --verbose.
warning: build failed, waiting for other jobs to finish...
error[E0635]: unknown feature `proc_macro_span_shrink`
  --> /home/heyset/.cargo/registry/src/github.com-1ecc6299db9ec823/proc-macro2-1.0.51/src/lib.rs:92:30
   |
92 |     feature(proc_macro_span, proc_macro_span_shrink)
   |                              ^^^^^^^^^^^^^^^^^^^^^^

error: aborting due to previous error

For more information about this error, try `rustc --explain E0635`.
error: failed to compile `papyrus v0.17.2`, intermediate artifacts can be found at `/tmp/cargo-installcI1oxP`