Skip to content

Commit 7902bf8

Browse files
committed
refactor: remove unused Workspace::new_virtual
It was designed for `-Zbuild-std`
1 parent da8138e commit 7902bf8

File tree

1 file changed

+0
-19
lines changed

1 file changed

+0
-19
lines changed

src/cargo/core/workspace.rs

-19
Original file line numberDiff line numberDiff line change
@@ -244,25 +244,6 @@ impl<'gctx> Workspace<'gctx> {
244244
}
245245
}
246246

247-
pub fn new_virtual(
248-
root_path: PathBuf,
249-
current_manifest: PathBuf,
250-
manifest: VirtualManifest,
251-
gctx: &'gctx GlobalContext,
252-
) -> CargoResult<Workspace<'gctx>> {
253-
let mut ws = Workspace::new_default(current_manifest, gctx);
254-
ws.root_manifest = Some(root_path.join("Cargo.toml"));
255-
ws.target_dir = gctx.target_dir()?;
256-
ws.packages
257-
.packages
258-
.insert(root_path, MaybePackage::Virtual(manifest));
259-
ws.find_members()?;
260-
ws.set_resolve_behavior()?;
261-
// TODO: validation does not work because it walks up the directory
262-
// tree looking for the root which is a fake file that doesn't exist.
263-
Ok(ws)
264-
}
265-
266247
/// Creates a "temporary workspace" from one package which only contains
267248
/// that package.
268249
///

0 commit comments

Comments
 (0)