mirror of
https://github.com/pezkuwichain/serde.git
synced 2026-04-27 15:47:57 +00:00
readme: fix example code so it builds
Might be worthwhile to look at trying to automate testing the code in the README (perhaps by generating the README from some special tests).
This commit is contained in:
@@ -61,7 +61,7 @@ fn main() {
|
||||
|
||||
println!("{}", serialized);
|
||||
|
||||
let deserialized: Point = serde_json::from_str(&serialized_point).unwrap();
|
||||
let deserialized: Point = serde_json::from_str(&serialized).unwrap();
|
||||
|
||||
println!("{:?}", deserialized);
|
||||
}
|
||||
@@ -119,7 +119,7 @@ fn main() {
|
||||
|
||||
println!("{}", serialized);
|
||||
|
||||
let deserialized: Point = serde_json::from_str(&serialized_point).unwrap();
|
||||
let deserialized: Point = serde_json::from_str(&serialized).unwrap();
|
||||
|
||||
println!("{:?}", deserialized);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user