sfackler / rust-postgres

Native PostgreSQL driver for the Rust programming language
Apache License 2.0
3.48k stars 443 forks source link

allow `BorrowToSql` for non-static `Box<dyn ToSql>` #1029

Closed laptou closed 1 year ago

laptou commented 1 year ago

This allows me to use tokio_postgres::binary_copy::BinaryCopyInWriter with boxed ToSql types that are created by borrowing data from somewhere else (and are therefore not 'static).

sfackler commented 1 year ago

Thanks!