Skip to content
This repository has been archived by the owner on Dec 29, 2022. It is now read-only.

Commit

Permalink
Apply feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
Xanewok committed Mar 28, 2018
1 parent 2487377 commit 7761299
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,9 @@ impl<'de, T: Deserialize<'de>> Deserialize<'de> for Inferrable<T> {

impl<T> Inferrable<T> {
pub fn is_none(&self) -> bool {
if let &Inferrable::None = self {
return false;
} else {
return true;
match *self {
Inferrable::None => true,
_ => false,
}
}
}
Expand Down Expand Up @@ -214,11 +213,9 @@ impl Config {

/// Is this config incomplete, and needs additional values to be inferred?
pub fn needs_inference(&self) -> bool {
if self.build_bin.is_none() || self.build_lib.is_none() || self.target_dir.is_none() {
return true;
}

return true;
self.build_bin.is_none() ||
self.build_lib.is_none() ||
self.target_dir.is_none()
}

/// Tries to auto-detect certain option values if they were unspecified.
Expand Down

0 comments on commit 7761299

Please sign in to comment.