Similar in spirit and implementation to how serde supports borrowed deserialization lifetimes. Like serde, it uses 'de as the lifetime of the trait (FromSql<'de>) and it adds all borrowed liftimes as lifetime bounds on 'de.
Also like serde all top level references automatically have their lifetimes borrowed, but container types carrying references must explicity be borrowed with the #[postgres(borrow)] annotation.
Similar in spirit and implementation to how
serde
supports borrowed deserialization lifetimes. Likeserde
, it uses'de
as the lifetime of the trait (FromSql<'de>
) and it adds all borrowed liftimes as lifetime bounds on'de
.Also like
serde
all top level references automatically have their lifetimes borrowed, but container types carrying references must explicity be borrowed with the#[postgres(borrow)]
annotation.Follows up on: https://github.com/sfackler/rust-postgres/pull/574