Expand documentation for Workspace::default_members field
authorSimon Sapin <simon.sapin@exyr.org>
Thu, 23 Nov 2017 15:51:36 +0000 (16:51 +0100)
committerSimon Sapin <simon.sapin@exyr.org>
Wed, 29 Nov 2017 09:59:19 +0000 (10:59 +0100)
src/cargo/core/workspace.rs

index d9307526ba882b39d23facb55d710ac2ca1dc5c7..3dc50a6f2b4b0f5eb407e7db3229e9903335636e 100644 (file)
@@ -46,7 +46,16 @@ pub struct Workspace<'cfg> {
     // set above.
     members: Vec<PathBuf>,
 
-    // The subset of `members` that are “default”.
+    // The subset of `members` that are used by the
+    // `build`, `check`, `test`, and `bench` subcommands
+    // when no package is selected with `--package` / `-p` and `--all`
+    // is not used.
+    //
+    // This is set by the `default-members` config
+    // in the `[workspace]` section.
+    // When unset, this is the same as `members` for virtual workspaces
+    // (`--all` is implied)
+    // or only the root package for non-virtual workspaces.
     default_members: Vec<PathBuf>,
 
     // True, if this is a temporary workspace created for the purposes of