Skip to content

Commit b077676

Browse files
committed
Resolve instances of Clippy's try_err lint in the Serde integration.
1 parent 6ff8cfc commit b077676

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/array_serde.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -276,17 +276,17 @@ where
276276

277277
let _v = match v {
278278
Some(v) => v,
279-
None => Err(de::Error::missing_field("v"))?,
279+
None => return Err(de::Error::missing_field("v")),
280280
};
281281

282282
let data = match data {
283283
Some(data) => data,
284-
None => Err(de::Error::missing_field("data"))?,
284+
None => return Err(de::Error::missing_field("data")),
285285
};
286286

287287
let dim = match dim {
288288
Some(dim) => dim,
289-
None => Err(de::Error::missing_field("dim"))?,
289+
None => return Err(de::Error::missing_field("dim")),
290290
};
291291

292292
if let Ok(array) = ArrayBase::from_shape_vec(dim, data) {

0 commit comments

Comments
 (0)