diff --git a/sqlx-postgres/src/connection/executor.rs b/sqlx-postgres/src/connection/executor.rs index 67ffa16ac..99ed24f14 100644 --- a/sqlx-postgres/src/connection/executor.rs +++ b/sqlx-postgres/src/connection/executor.rs @@ -65,7 +65,7 @@ async fn prepare( // indicates that the SQL query string is now successfully parsed and has semantic validity let _ = conn .stream - .recv_expect(MessageFormat::ParseComplete) + .recv_expect::<()>(MessageFormat::ParseComplete) .await?; let metadata = if let Some(metadata) = metadata { diff --git a/sqlx-postgres/src/copy.rs b/sqlx-postgres/src/copy.rs index f5a6ea857..8cc481251 100644 --- a/sqlx-postgres/src/copy.rs +++ b/sqlx-postgres/src/copy.rs @@ -281,7 +281,7 @@ impl> PgCopyIn { Some(Cow::Borrowed("57014")) => { // postgres abort received error code conn.stream - .recv_expect(MessageFormat::ReadyForQuery) + .recv_expect::<()>(MessageFormat::ReadyForQuery) .await?; Ok(()) } @@ -315,7 +315,7 @@ impl> PgCopyIn { }; conn.stream - .recv_expect(MessageFormat::ReadyForQuery) + .recv_expect::<()>(MessageFormat::ReadyForQuery) .await?; Ok(cc.rows_affected()) @@ -351,8 +351,8 @@ async fn pg_begin_copy_out<'c, C: DerefMut + Send + 'c>( MessageFormat::CopyData => r#yield!(msg.decode::>()?.0), MessageFormat::CopyDone => { let _ = msg.decode::()?; - conn.stream.recv_expect(MessageFormat::CommandComplete).await?; - conn.stream.recv_expect(MessageFormat::ReadyForQuery).await?; + conn.stream.recv_expect::<()>(MessageFormat::CommandComplete).await?; + conn.stream.recv_expect::<()>(MessageFormat::ReadyForQuery).await?; return Ok(()) }, _ => return Err(err_protocol!("unexpected message format during copy out: {:?}", msg.format))