Format with rustfmt 0.7.0

This commit is contained in:
David Tolnay
2018-05-22 21:06:32 -07:00
parent ad62a6895c
commit 06dcbbbaba
5 changed files with 27 additions and 13 deletions
+4 -2
View File
@@ -310,7 +310,9 @@ fn check_transparent(cx: &Ctxt, cont: &mut Container, derive: Derive) {
for field in fields {
if allow_transparent(field, derive) {
if transparent_field.is_some() {
cx.error("#[serde(transparent)] requires struct to have at most one transparent field");
cx.error(
"#[serde(transparent)] requires struct to have at most one transparent field",
);
return;
}
transparent_field = Some(field);
@@ -326,7 +328,7 @@ fn check_transparent(cx: &Ctxt, cont: &mut Container, derive: Derive) {
Derive::Deserialize => {
cx.error("#[serde(transparent)] requires at least one field that is neither skipped nor has a default");
}
}
},
}
}