aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_project_model/src
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2019-12-14 18:16:48 +0000
committerGitHub <[email protected]>2019-12-14 18:16:48 +0000
commitd6223253b628b279f9ddae8f83f7173d01f6b32c (patch)
tree12f2ccc5c52c1c0b67932d3a35fe18668b8e5d62 /crates/ra_project_model/src
parent202ad1e2d9376565cb273cf085be600ed10e5a93 (diff)
parent2619950b3b405324ab1c1745876165c834b3b4b9 (diff)
Merge #2561
2561: Split generic and non-generic paths r=matklad a=matklad Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_project_model/src')
-rw-r--r--crates/ra_project_model/src/cargo_workspace.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/crates/ra_project_model/src/cargo_workspace.rs b/crates/ra_project_model/src/cargo_workspace.rs
index 4a0437da3..c862d3912 100644
--- a/crates/ra_project_model/src/cargo_workspace.rs
+++ b/crates/ra_project_model/src/cargo_workspace.rs
@@ -24,7 +24,7 @@ pub struct CargoWorkspace {
24 pub(crate) workspace_root: PathBuf, 24 pub(crate) workspace_root: PathBuf,
25} 25}
26 26
27#[derive(Deserialize, Clone, Debug, PartialEq, Eq, Default)] 27#[derive(Deserialize, Clone, Debug, PartialEq, Eq)]
28#[serde(rename_all = "camelCase", default)] 28#[serde(rename_all = "camelCase", default)]
29pub struct CargoFeatures { 29pub struct CargoFeatures {
30 /// Do not activate the `default` feature. 30 /// Do not activate the `default` feature.
@@ -38,6 +38,12 @@ pub struct CargoFeatures {
38 pub features: Vec<String>, 38 pub features: Vec<String>,
39} 39}
40 40
41impl Default for CargoFeatures {
42 fn default() -> Self {
43 CargoFeatures { no_default_features: false, all_features: true, features: Vec::new() }
44 }
45}
46
41#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)] 47#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)]
42pub struct Package(RawId); 48pub struct Package(RawId);
43impl_arena_id!(Package); 49impl_arena_id!(Package);