Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Resolve question_mark clippy lint in build script
warning: this `match` expression can be replaced with `?` --> serde/build.rs:111:17 | 111 | let rustc = match env::var_os("RUSTC") { | _________________^ 112 | | Some(rustc) => rustc, 113 | | None => return None, 114 | | }; | |_____^ help: try instead: `env::var_os("RUSTC")?` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark = note: `-W clippy::question-mark` implied by `-W clippy::all` = help: to override `-W clippy::all` add `#[allow(clippy::question_mark)]` warning: this `match` expression can be replaced with `?` --> serde/build.rs:131:16 | 131 | let next = match pieces.next() { | ________________^ 132 | | Some(next) => next, 133 | | None => return None, 134 | | }; | |_____^ help: try instead: `pieces.next()?` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#question_mark
- Loading branch information