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

Building on nix #60397

Closed
ghost opened this issue Apr 30, 2019 · 1 comment
Closed

Building on nix #60397

ghost opened this issue Apr 30, 2019 · 1 comment
Labels
O-NixOS Operating system: NixOS, https://nixos.org/

Comments

@ghost
Copy link

ghost commented Apr 30, 2019

I am using this script to build rust using the mozilla rust overlay for nix.

https://github.com/brettgilio/guix-system/blob/master/manifests/nightly-rust-manifest.nix

This worked fine for awhile, however about a week or two ago it started failing with this error.

error[E0277]: the trait bound `std::borrow::Cow<'_, str>: std::convert::From<core::str::EscapeDefault<'_>>` is not satisfied
   --> /build/rls-1.31.7-vendor/rustc-ap-graphviz/lib.rs:551:44
    |
551 |                     (&*s).escape_default().into()
    |                                            ^^^^ the trait `std::convert::From<core::str::EscapeDefault<'_>>` is not implemented for `std::borrow::Cow<'_, str>`
    |
    = help: the following implementations were found:
              <std::borrow::Cow<'a, [T]> as std::convert::From<&'a [T]>>
              <std::borrow::Cow<'a, [T]> as std::convert::From<&'a std::vec::Vec<T>>>
              <std::borrow::Cow<'a, [T]> as std::convert::From<std::vec::Vec<T>>>
              <std::borrow::Cow<'a, std::ffi::CStr> as std::convert::From<&'a std::ffi::CStr>>
            and 11 others
    = note: required because of the requirements on the impl of `std::convert::Into<std::borrow::Cow<'_, str>>` for `core::str::EscapeDefault<'_>`

error: aborting due to previous error

For more information about this error, try `rustc --explain E0277`.
error: Could not compile `rustc-ap-graphviz`.
warning: build failed, waiting for other jobs to finish...
error: build failed
builder for '/nix/store/vfw5pdqckqm6024kmvqm65jvsc9mfkxy-rls-1.31.7.drv' failed with exit code 101
error: build of '/nix/store/94ir2l1ac2yfcfc1fph6w3x4ghp5rah6-rust-analysis-1.36.0-nightly-2019-04-29-00859e3e6.drv', '/nix/store/a77wjq236g9h01hbd63ij5d9khgqbm5v-rust-src-1.36.0-nightly-2019-04-29-00859e3e6.drv', '/nix/store/vfw5pdqckqm6024kmvqm65jvsc9mfkxy-rls-1.31.7.drv', '/nix/store/w8pqky54afqcz5kxx0j0zsq80jyv4950-rust-1.36.0-nightly-2019-04-29-00859e3e6.drv' failed

I thought maybe it was an upstream issue, but I am lost with how long this issue has been persisting. Any suggestions?

@tesuji
Copy link
Contributor

tesuji commented Apr 30, 2019

Current RLS version is 1.36.0. You should try to update it.
This is error because str::escape has been stabilized in #58051
(and bug fixed in https://github.com/rust-lang/rust/pull/58051/files#diff-5df012de31a1bde391411c75eaa4fbfeR540)

@jonas-schievink jonas-schievink added the O-NixOS Operating system: NixOS, https://nixos.org/ label Apr 30, 2019
@ghost ghost closed this as completed Apr 30, 2019
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O-NixOS Operating system: NixOS, https://nixos.org/
Projects
None yet
Development

No branches or pull requests

2 participants