From 29e0540722cd53c9a1031df08e3e8196fa39b725 Mon Sep 17 00:00:00 2001 From: lovasoa Date: Sat, 2 Nov 2024 17:03:44 +0100 Subject: [PATCH] Make `AnyTypeInfoKind` public --- CHANGELOG.md | 4 ++++ Cargo.lock | 14 +++++++------- Cargo.toml | 6 +++--- .../postgres/axum-social-with-tests/Cargo.toml | 2 +- sqlx-cli/Cargo.toml | 2 +- sqlx-core/Cargo.toml | 4 ++-- sqlx-core/src/any/mod.rs | 2 +- sqlx-core/src/any/type_info.rs | 5 +++-- sqlx-macros/Cargo.toml | 6 +++--- sqlx-rt/Cargo.toml | 2 +- 10 files changed, 26 insertions(+), 21 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 07dd486870..fcc0fec33b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## 0.6.31 + +- Make `AnyTypeInfoKind` public + ## 0.6.30 - Make the `Encrypt` enum public in the mssql driver diff --git a/Cargo.lock b/Cargo.lock index 033598760f..d74989086b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -660,9 +660,9 @@ checksum = "37b2a672a2cb129a2e41c10b1224bb368f9f37a2b16b612598138befd7b37eb5" [[package]] name = "cc" -version = "1.1.31" +version = "1.1.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2e7962b54006dcfcc61cb72735f4d89bb97061dd6a7ed882ec6b8ee53714c6f" +checksum = "67b9470d453346108f93a59222a9a1a5724db32d0a4727b7ab7ace4b4d822dc9" dependencies = [ "jobserver", "libc", @@ -3168,7 +3168,7 @@ dependencies = [ [[package]] name = "sqlx-cli" -version = "0.6.30" +version = "0.6.31" dependencies = [ "anyhow", "async-trait", @@ -3193,7 +3193,7 @@ dependencies = [ [[package]] name = "sqlx-core-oldapi" -version = "0.6.30" +version = "0.6.31" dependencies = [ "ahash 0.8.11", "atoi", @@ -3355,7 +3355,7 @@ dependencies = [ [[package]] name = "sqlx-macros-oldapi" -version = "0.6.30" +version = "0.6.31" dependencies = [ "dotenvy", "either", @@ -3375,7 +3375,7 @@ dependencies = [ [[package]] name = "sqlx-oldapi" -version = "0.6.30" +version = "0.6.31" dependencies = [ "anyhow", "async-std", @@ -3402,7 +3402,7 @@ dependencies = [ [[package]] name = "sqlx-rt-oldapi" -version = "0.6.30" +version = "0.6.31" dependencies = [ "async-native-tls", "async-std", diff --git a/Cargo.toml b/Cargo.toml index 63da511cad..cdd7cbda8c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -20,7 +20,7 @@ members = [ [package] name = "sqlx-oldapi" -version = "0.6.30" +version = "0.6.31" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/lovasoa/sqlx" @@ -125,8 +125,8 @@ bstr = ["sqlx-core/bstr"] git2 = ["sqlx-core/git2"] [dependencies] -sqlx-core = { package = "sqlx-core-oldapi", version = "0.6.30", path = "sqlx-core", default-features = false } -sqlx-macros = { package = "sqlx-macros-oldapi", version = "0.6.30", path = "sqlx-macros", default-features = false, optional = true } +sqlx-core = { package = "sqlx-core-oldapi", version = "0.6.31", path = "sqlx-core", default-features = false } +sqlx-macros = { package = "sqlx-macros-oldapi", version = "0.6.31", path = "sqlx-macros", default-features = false, optional = true } [dev-dependencies] anyhow = "1.0.52" diff --git a/examples/postgres/axum-social-with-tests/Cargo.toml b/examples/postgres/axum-social-with-tests/Cargo.toml index 945ce02cf3..6040ecc54c 100644 --- a/examples/postgres/axum-social-with-tests/Cargo.toml +++ b/examples/postgres/axum-social-with-tests/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" [dependencies] # Primary crates axum = { version = "0.5.13", features = ["macros"] } -sqlx = { package = "sqlx-oldapi", version = "0.6.30", path = "../../../", features = ["runtime-tokio-rustls", "postgres", "time", "uuid"] } +sqlx = { package = "sqlx-oldapi", version = "0.6.31", path = "../../../", features = ["runtime-tokio-rustls", "postgres", "time", "uuid"] } tokio = { version = "1.20.1", features = ["rt-multi-thread", "macros"] } # Important secondary crates diff --git a/sqlx-cli/Cargo.toml b/sqlx-cli/Cargo.toml index bdf1d1461c..385d708ed6 100644 --- a/sqlx-cli/Cargo.toml +++ b/sqlx-cli/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "sqlx-cli" -version = "0.6.30" +version = "0.6.31" description = "Command-line utility for SQLx, the Rust SQL toolkit." edition = "2021" readme = "README.md" diff --git a/sqlx-core/Cargo.toml b/sqlx-core/Cargo.toml index de1fdb621b..0fac30b433 100644 --- a/sqlx-core/Cargo.toml +++ b/sqlx-core/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "sqlx-core-oldapi" -version = "0.6.30" +version = "0.6.31" repository = "https://github.com/lovasoa/sqlx" description = "Core of SQLx, the rust SQL toolkit. Not intended to be used directly." license = "MIT OR Apache-2.0" @@ -101,7 +101,7 @@ offline = ["serde", "either/serde"] paste = "1.0.6" ahash = "0.8.3" atoi = "2.0.0" -sqlx-rt = { path = "../sqlx-rt", version = "0.6.30", package = "sqlx-rt-oldapi" } +sqlx-rt = { path = "../sqlx-rt", version = "0.6.31", package = "sqlx-rt-oldapi" } base64 = { version = "0.22", default-features = false, optional = true, features = ["std"] } bigdecimal_ = { version = "0.4.1", optional = true, package = "bigdecimal" } rust_decimal = { version = "1.19.0", optional = true } diff --git a/sqlx-core/src/any/mod.rs b/sqlx-core/src/any/mod.rs index bb07016051..385c1f9cf1 100644 --- a/sqlx-core/src/any/mod.rs +++ b/sqlx-core/src/any/mod.rs @@ -44,7 +44,7 @@ pub use query_result::AnyQueryResult; pub use row::AnyRow; pub use statement::AnyStatement; pub use transaction::AnyTransactionManager; -pub use type_info::AnyTypeInfo; +pub use type_info::{AnyTypeInfo, AnyTypeInfoKind}; pub use value::{AnyValue, AnyValueRef}; pub type AnyPool = crate::pool::Pool; diff --git a/sqlx-core/src/any/type_info.rs b/sqlx-core/src/any/type_info.rs index 3d3c914f16..6c2397d090 100644 --- a/sqlx-core/src/any/type_info.rs +++ b/sqlx-core/src/any/type_info.rs @@ -15,10 +15,11 @@ use crate::sqlite::SqliteTypeInfo; use crate::mssql::MssqlTypeInfo; #[derive(Debug, Clone, PartialEq)] -pub struct AnyTypeInfo(pub(crate) AnyTypeInfoKind); +pub struct AnyTypeInfo(AnyTypeInfoKind); #[derive(Debug, Clone, PartialEq)] -pub(crate) enum AnyTypeInfoKind { +#[non_exhaustive] +pub enum AnyTypeInfoKind { #[cfg(feature = "postgres")] Postgres(PgTypeInfo), diff --git a/sqlx-macros/Cargo.toml b/sqlx-macros/Cargo.toml index ee117a2eb8..350173161e 100644 --- a/sqlx-macros/Cargo.toml +++ b/sqlx-macros/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "sqlx-macros-oldapi" -version = "0.6.30" +version = "0.6.31" repository = "https://github.com/lovasoa/sqlx" description = "Macros for SQLx, the rust SQL toolkit. Not intended to be used directly." license = "MIT OR Apache-2.0" @@ -75,8 +75,8 @@ heck = { version = "0.5" } either = "1.6.1" once_cell = "1.9.0" proc-macro2 = { version = "1.0.36", default-features = false } -sqlx-core = { package = "sqlx-core-oldapi", version = "0.6.30", default-features = false, features = ["any"], path = "../sqlx-core" } -sqlx-rt = { version = "0.6.30", default-features = false, path = "../sqlx-rt", package = "sqlx-rt-oldapi" } +sqlx-core = { package = "sqlx-core-oldapi", version = "0.6.31", default-features = false, features = ["any"], path = "../sqlx-core" } +sqlx-rt = { version = "0.6.31", default-features = false, path = "../sqlx-rt", package = "sqlx-rt-oldapi" } serde = { version = "1.0.132", features = ["derive"], optional = true } serde_json = { version = "1.0.73", optional = true } sha2 = { version = "0.10.0", optional = true } diff --git a/sqlx-rt/Cargo.toml b/sqlx-rt/Cargo.toml index 5145c345a1..96ca130f69 100644 --- a/sqlx-rt/Cargo.toml +++ b/sqlx-rt/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "sqlx-rt-oldapi" -version = "0.6.30" +version = "0.6.31" repository = "https://github.com/launchbadge/sqlx" license = "MIT OR Apache-2.0" description = "Runtime abstraction used by SQLx, the Rust SQL toolkit. Not intended to be used directly."