mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-06-09 19:01:01 +00:00
Include unknown attribute name in error message
This commit is contained in:
@@ -15,4 +15,4 @@ unstable-testing = ["clippy"]
|
||||
|
||||
[dependencies]
|
||||
clippy = { version = "^0.*", optional = true }
|
||||
syn = "0.7"
|
||||
syn = "0.7.1"
|
||||
|
||||
@@ -142,8 +142,8 @@ impl Item {
|
||||
}
|
||||
|
||||
_ => {
|
||||
// TODO include name of attr
|
||||
cx.error("unknown serde container attribute");
|
||||
cx.error(format!("unknown serde container attribute `{}`",
|
||||
meta_item.name()));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -208,8 +208,8 @@ impl Variant {
|
||||
}
|
||||
|
||||
_ => {
|
||||
// TODO include attribute
|
||||
cx.error("unknown serde variant attribute");
|
||||
cx.error(format!("unknown serde variant attribute `{}`",
|
||||
meta_item.name()));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -353,8 +353,8 @@ impl Field {
|
||||
}
|
||||
|
||||
_ => {
|
||||
// TODO include attribute
|
||||
cx.error("unknown serde field attribute");
|
||||
cx.error(format!("unknown serde field attribute `{}`",
|
||||
meta_item.name()));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user