mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-04-23 09:28:04 +00:00
Test unknown field in remote struct
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
#[macro_use]
|
||||
extern crate serde_derive;
|
||||
|
||||
mod remote {
|
||||
pub struct S {
|
||||
pub a: u8,
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize)]
|
||||
#[serde(remote = "remote::S")]
|
||||
struct S {
|
||||
b: u8, //~^^^ ERROR: no field `b` on type `&remote::S`
|
||||
}
|
||||
|
||||
fn main() {}
|
||||
Reference in New Issue
Block a user