Skip to content

v1.0.90

Compare
Choose a tag to compare
@dtolnay dtolnay released this 03 Apr 16:47
· 1178 commits to master since this release
v1.0.90
0be7f36
  • Add an attribute #[serde(crate = "path::to::serde")] which replaces the use of extern crate serde in the generated code; this is intended for crates that invoke Serde derives from a macro and need to refer to serde through their own re-export rather than requiring callers to list Serde in Cargo.toml (#1499, thanks @sgrif)

    #[derive(Deserialize)]
    #[serde(crate = "__tw::codegen::serde")]
    struct S { ... }
    // expands to:
    impl<'de> __tw::codegen::serde::Deserialize<'de> for S {
        ...
    }