mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 04:44:57 +00:00
Report sysroot and rustc crate loading errors
This commit is contained in:
parent
e2ab0ff124
commit
d9c7d28e0d
11 changed files with 134 additions and 139 deletions
|
@ -24,8 +24,8 @@ fn load_cargo_with_overrides(file: &str, cfg_overrides: CfgOverrides) -> CrateGr
|
|||
let project_workspace = ProjectWorkspace::Cargo {
|
||||
cargo: cargo_workspace,
|
||||
build_scripts: WorkspaceBuildScripts::default(),
|
||||
sysroot: None,
|
||||
rustc: None,
|
||||
sysroot: Err(None),
|
||||
rustc: Err(None),
|
||||
rustc_cfg: Vec::new(),
|
||||
cfg_overrides,
|
||||
toolchain: None,
|
||||
|
@ -37,7 +37,7 @@ fn load_cargo_with_overrides(file: &str, cfg_overrides: CfgOverrides) -> CrateGr
|
|||
fn load_rust_project(file: &str) -> CrateGraph {
|
||||
let data = get_test_json_file(file);
|
||||
let project = rooted_project_json(data);
|
||||
let sysroot = Some(get_fake_sysroot());
|
||||
let sysroot = Ok(get_fake_sysroot());
|
||||
let project_workspace = ProjectWorkspace::Json { project, sysroot, rustc_cfg: Vec::new() };
|
||||
to_crate_graph(project_workspace)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue