Skip to content

Commit

Permalink
Fix build.rs script for breaking protoc-rust change
Browse files Browse the repository at this point in the history
..Default::default() causes a private attribute to be accessed, while
Customize::default() is clearer.

Signed-off-by: Boyd Johnson <bjohnson@bitwise.io>
  • Loading branch information
Boyd Johnson committed Oct 8, 2018
1 parent ca0e8e1 commit d002746
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 12 deletions.
4 changes: 1 addition & 3 deletions families/smallbank/smallbank_rust/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,7 @@ fn main() {
.map(|proto_file| proto_file.as_ref())
.collect::<Vec<&str>>(),
includes: &["../protos"],
customize: Customize {
..Default::default()
},
customize: Customize::default(),
}).expect("Error generating rust files from smallbank protos");

// Create mod.rs accordingly
Expand Down
4 changes: 1 addition & 3 deletions perf/smallbank_workload/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,7 @@ fn main() {
.map(|proto_file| proto_file.as_ref())
.collect::<Vec<&str>>(),
includes: &["../../families/smallbank/protos"],
customize: Customize {
..Default::default()
},
customize: Customize::default(),
}).expect("Error generating rust files from smallbank protos");

// Create mod.rs accordingly
Expand Down
4 changes: 1 addition & 3 deletions sdk/rust/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,7 @@ fn main() {
.map(|a| a.as_ref())
.collect::<Vec<&str>>(),
includes: &["src", "../../protos"],
customize: Customize {
..Default::default()
},
customize: Customize::default(),
}).expect("unable to run protoc");
}

Expand Down
4 changes: 1 addition & 3 deletions validator/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,7 @@ fn main() {
.map(|proto_file| proto_file.file_path.as_ref())
.collect::<Vec<&str>>(),
includes: &["src", PROTO_FILES_DIR],
customize: Customize {
..Default::default()
},
customize: Customize::default(),
}).expect("unable to run protoc");

let mod_file_name = format!("{}/mod.rs", &dest_path.to_str().unwrap());
Expand Down

0 comments on commit d002746

Please sign in to comment.