Ensure connect future is Send
This commit is contained in:
parent
680f7b8ecb
commit
427340d748
@ -661,7 +661,9 @@ async fn inet() {
|
|||||||
async fn check_send() {
|
async fn check_send() {
|
||||||
fn is_send<T: Send>(_: &T) {}
|
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");
|
let f = client.prepare("SELECT $1::TEXT");
|
||||||
is_send(&f);
|
is_send(&f);
|
||||||
|
Loading…
Reference in New Issue
Block a user