groundwork for 0.9.0-alpha.1 (#3821)

* chore: bump version to `0.9.0-alpha.1`

* chore: delete unused `sqlx-bench` package

* chore: set `rust-version` to 1.85 for all crates

* fix: lots of new Clippy warnings

* fix: lots more Clippy warnings

* fix(cli): add `_sqlite` feature

* fix: lots, *lots* more Clippy warnings

* fix(core): warning in `tls_rustls`

* breaking: delete runtime+TLS combination features

* chore: don't re-export unstable `TransactionManager` trait

* chore: 0.9.0-alplha.1 CHANGELOG

* chore: increase MSRV further to 1.86

* fix: more clippy warnings
This commit is contained in:
Austin Bonander
2025-06-01 21:09:55 -07:00
committed by GitHub
parent bab1b022bd
commit 90797200ee
94 changed files with 213 additions and 1265 deletions

View File

@@ -186,7 +186,7 @@ impl<'a> DoHandshake<'a> {
}
}
impl<'a> WithSocket for DoHandshake<'a> {
impl WithSocket for DoHandshake<'_> {
type Output = Result<MySqlStream, Error>;
async fn with_socket<S: Socket>(self, socket: S) -> Self::Output {

View File

@@ -25,7 +25,7 @@ use futures_util::TryStreamExt;
use std::{borrow::Cow, pin::pin, sync::Arc};
impl MySqlConnection {
async fn prepare_statement<'c>(
async fn prepare_statement(
&mut self,
sql: &str,
) -> Result<(u32, MySqlStatementMetadata), Error> {
@@ -72,7 +72,7 @@ impl MySqlConnection {
Ok((id, metadata))
}
async fn get_or_prepare_statement<'c>(
async fn get_or_prepare_statement(
&mut self,
sql: &str,
) -> Result<(u32, MySqlStatementMetadata), Error> {

View File

@@ -45,7 +45,7 @@ impl MySqlBufMutExt for Vec<u8> {
#[test]
fn test_encodes_int_lenenc_u8() {
let mut buf = Vec::with_capacity(1024);
buf.put_uint_lenenc(0xFA as u64);
buf.put_uint_lenenc(0xFA_u64);
assert_eq!(&buf[..], b"\xFA");
}
@@ -53,7 +53,7 @@ fn test_encodes_int_lenenc_u8() {
#[test]
fn test_encodes_int_lenenc_u16() {
let mut buf = Vec::with_capacity(1024);
buf.put_uint_lenenc(std::u16::MAX as u64);
buf.put_uint_lenenc(u16::MAX as u64);
assert_eq!(&buf[..], b"\xFC\xFF\xFF");
}
@@ -61,7 +61,7 @@ fn test_encodes_int_lenenc_u16() {
#[test]
fn test_encodes_int_lenenc_u24() {
let mut buf = Vec::with_capacity(1024);
buf.put_uint_lenenc(0xFF_FF_FF as u64);
buf.put_uint_lenenc(0xFF_FF_FF_u64);
assert_eq!(&buf[..], b"\xFD\xFF\xFF\xFF");
}
@@ -69,7 +69,7 @@ fn test_encodes_int_lenenc_u24() {
#[test]
fn test_encodes_int_lenenc_u64() {
let mut buf = Vec::with_capacity(1024);
buf.put_uint_lenenc(std::u64::MAX);
buf.put_uint_lenenc(u64::MAX);
assert_eq!(&buf[..], b"\xFE\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF");
}
@@ -77,7 +77,7 @@ fn test_encodes_int_lenenc_u64() {
#[test]
fn test_encodes_int_lenenc_fb() {
let mut buf = Vec::with_capacity(1024);
buf.put_uint_lenenc(0xFB as u64);
buf.put_uint_lenenc(0xFB_u64);
assert_eq!(&buf[..], b"\xFC\xFB\x00");
}
@@ -85,7 +85,7 @@ fn test_encodes_int_lenenc_fb() {
#[test]
fn test_encodes_int_lenenc_fc() {
let mut buf = Vec::with_capacity(1024);
buf.put_uint_lenenc(0xFC as u64);
buf.put_uint_lenenc(0xFC_u64);
assert_eq!(&buf[..], b"\xFC\xFC\x00");
}
@@ -93,7 +93,7 @@ fn test_encodes_int_lenenc_fc() {
#[test]
fn test_encodes_int_lenenc_fd() {
let mut buf = Vec::with_capacity(1024);
buf.put_uint_lenenc(0xFD as u64);
buf.put_uint_lenenc(0xFD_u64);
assert_eq!(&buf[..], b"\xFC\xFD\x00");
}
@@ -101,7 +101,7 @@ fn test_encodes_int_lenenc_fd() {
#[test]
fn test_encodes_int_lenenc_fe() {
let mut buf = Vec::with_capacity(1024);
buf.put_uint_lenenc(0xFE as u64);
buf.put_uint_lenenc(0xFE_u64);
assert_eq!(&buf[..], b"\xFC\xFE\x00");
}
@@ -109,7 +109,7 @@ fn test_encodes_int_lenenc_fe() {
#[test]
fn test_encodes_int_lenenc_ff() {
let mut buf = Vec::with_capacity(1024);
buf.put_uint_lenenc(0xFF as u64);
buf.put_uint_lenenc(0xFF_u64);
assert_eq!(&buf[..], b"\xFC\xFF\x00");
}

View File

@@ -11,7 +11,7 @@ pub struct Execute<'q> {
pub arguments: &'q MySqlArguments,
}
impl<'q> ProtocolEncode<'_, Capabilities> for Execute<'q> {
impl ProtocolEncode<'_, Capabilities> for Execute<'_> {
fn encode_with(&self, buf: &mut Vec<u8>, _: Capabilities) -> Result<(), crate::Error> {
buf.push(0x17); // COM_STMT_EXECUTE
buf.extend(&self.statement.to_le_bytes());

View File

@@ -16,7 +16,7 @@ impl<T> Type<MySql> for Text<T> {
}
}
impl<'q, T> Encode<'q, MySql> for Text<T>
impl<T> Encode<'_, MySql> for Text<T>
where
T: Display,
{