mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-04-29 12:57:55 +00:00
Include unknown attribute name in error message
This commit is contained in:
@@ -24,6 +24,6 @@ with-syn = []
|
||||
clippy = { version = "^0.*", optional = true }
|
||||
quote = "0.1"
|
||||
serde_codegen_internals = { version = "=0.8.9", default-features = false, path = "../serde_codegen_internals" }
|
||||
syn = { version = "0.7", features = ["aster", "visit"] }
|
||||
syn = { version = "0.7.1", features = ["aster", "visit"] }
|
||||
syntex = { version = "^0.44.0", optional = true }
|
||||
syntex_syntax = { version = "^0.44.0", optional = true }
|
||||
|
||||
@@ -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