diff --git a/src/cargo/core/workspace.rs b/src/cargo/core/workspace.rs index 0e538c698e1..3a2588e412c 100644 --- a/src/cargo/core/workspace.rs +++ b/src/cargo/core/workspace.rs @@ -244,25 +244,6 @@ impl<'gctx> Workspace<'gctx> { } } - pub fn new_virtual( - root_path: PathBuf, - current_manifest: PathBuf, - manifest: VirtualManifest, - gctx: &'gctx GlobalContext, - ) -> CargoResult> { - let mut ws = Workspace::new_default(current_manifest, gctx); - ws.root_manifest = Some(root_path.join("Cargo.toml")); - ws.target_dir = gctx.target_dir()?; - ws.packages - .packages - .insert(root_path, MaybePackage::Virtual(manifest)); - ws.find_members()?; - ws.set_resolve_behavior()?; - // TODO: validation does not work because it walks up the directory - // tree looking for the root which is a fake file that doesn't exist. - Ok(ws) - } - /// Creates a "temporary workspace" from one package which only contains /// that package. ///