chore: replace once_cell OnceCell/Lazy with std OnceLock/LazyLock (#3709)

This commit is contained in:
Paolo Barbolini
2025-06-18 01:38:02 +02:00
committed by GitHub
parent df47ffedd2
commit 764ae2f702
15 changed files with 44 additions and 41 deletions

View File

@@ -67,7 +67,6 @@ futures-intrusive = "0.5.0"
futures-util = { version = "0.3.19", default-features = false, features = ["alloc", "sink", "io"] }
log = { version = "0.4.18", default-features = false }
memchr = { version = "2.4.1", default-features = false }
once_cell = "1.9.0"
percent-encoding = "2.1.0"
regex = { version = "1.5.5", optional = true }
serde = { version = "1.0.132", features = ["derive", "rc"], optional = true }

View File

@@ -5,11 +5,11 @@ use crate::connection::Connection;
use crate::database::Database;
use crate::Error;
use futures_core::future::BoxFuture;
use once_cell::sync::OnceCell;
use std::fmt::{Debug, Formatter};
use std::sync::OnceLock;
use url::Url;
static DRIVERS: OnceCell<&'static [AnyDriver]> = OnceCell::new();
static DRIVERS: OnceLock<&'static [AnyDriver]> = OnceLock::new();
#[macro_export]
macro_rules! declare_driver_with_optional_migrate {