remove FIXME after rust 1.47 comes out
This commit is contained in:
parent
1b7e350e80
commit
6c4bb30e95
@ -60,9 +60,7 @@ pub fn load(sysroot_src_dir: &AbsPath) -> Result<Sysroot> {
|
|||||||
let mut sysroot = Sysroot { crates: Arena::default() };
|
let mut sysroot = Sysroot { crates: Arena::default() };
|
||||||
|
|
||||||
for name in SYSROOT_CRATES.trim().lines() {
|
for name in SYSROOT_CRATES.trim().lines() {
|
||||||
// FIXME: first path when 1.47 comes out
|
let root = [format!("{}/src/lib.rs", name), format!("lib{}/lib.rs", name)]
|
||||||
// https://github.com/rust-lang/rust/pull/73265
|
|
||||||
let root = [format!("lib{}/lib.rs", name), format!("{}/src/lib.rs", name)]
|
|
||||||
.iter()
|
.iter()
|
||||||
.map(|it| sysroot_src_dir.join(it))
|
.map(|it| sysroot_src_dir.join(it))
|
||||||
.find(|it| it.exists());
|
.find(|it| it.exists());
|
||||||
@ -149,9 +147,6 @@ fn discover_sysroot_src_dir(current_dir: &AbsPath) -> Result<AbsPathBuf> {
|
|||||||
|
|
||||||
fn get_rust_src(sysroot_path: &AbsPath) -> Option<AbsPathBuf> {
|
fn get_rust_src(sysroot_path: &AbsPath) -> Option<AbsPathBuf> {
|
||||||
// Try the new path first since the old one still exists.
|
// Try the new path first since the old one still exists.
|
||||||
//
|
|
||||||
// FIXME: remove `src` when 1.47 comes out
|
|
||||||
// https://github.com/rust-lang/rust/pull/73265
|
|
||||||
let rust_src = sysroot_path.join("lib/rustlib/src/rust");
|
let rust_src = sysroot_path.join("lib/rustlib/src/rust");
|
||||||
log::debug!("Checking sysroot (looking for `library` and `src` dirs): {}", rust_src.display());
|
log::debug!("Checking sysroot (looking for `library` and `src` dirs): {}", rust_src.display());
|
||||||
["library", "src"].iter().map(|it| rust_src.join(it)).find(|it| it.exists())
|
["library", "src"].iter().map(|it| rust_src.join(it)).find(|it| it.exists())
|
||||||
|
Loading…
Reference in New Issue
Block a user