serde/test_suite/tests/compile-fail/remote/unknown_field.rs

17 lines
252 B
Rust
Raw Normal View History

2017-04-10 14:23:02 -05:00
#[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() {}