Analogous to #[serde(crate = "...")], it'd be great to have a #[postcard(crate = ...)] for #[derive(Schema)] to make it possible to re-export postcard derives from another crate without needing an additional direct dependency on postcard or postcard_schema.
Parsing could likely be handled similarly to https://github.com/jamesmunns/postcard/pull/154, although it'd be nice to support #[postcard(crate = postcard)] instead of requiring a string literal like #[postcard(crate = "postcard")] (IIRC, the reason serde uses string literals is for backwards-compatibility).
Analogous to
#[serde(crate = "...")]
, it'd be great to have a#[postcard(crate = ...)]
for#[derive(Schema)]
to make it possible to re-export postcard derives from another crate without needing an additional direct dependency onpostcard
orpostcard_schema
.This https://github.com/jamesmunns/postcard/blob/70111772ee231364daeac7cd11063352f19bc930/source/postcard-derive/src/schema.rs#L22-L24 would have to become something like
Parsing could likely be handled similarly to https://github.com/jamesmunns/postcard/pull/154, although it'd be nice to support
#[postcard(crate = postcard)]
instead of requiring a string literal like#[postcard(crate = "postcard")]
(IIRC, the reason serde uses string literals is for backwards-compatibility).