Ensure connect future is Send

This commit is contained in:
Steven Fackler 2019-09-25 18:30:00 -07:00
parent 680f7b8ecb
commit 427340d748

View File

@ -661,7 +661,9 @@ async fn inet() {
async fn check_send() {
fn is_send<T: Send>(_: &T) {}
let mut client = connect("user=postgres").await;
let f = connect("user=postgres");
is_send(&f);
let mut client = f.await;
let f = client.prepare("SELECT $1::TEXT");
is_send(&f);