From 604fb36f4251e494b3486009145401a3c1f7b326 Mon Sep 17 00:00:00 2001 From: 魏曹先生 <1992414357@qq.com> Date: Sat, 2 May 2026 00:50:23 +0800 Subject: Add nightly feature flag for Rust nightly-only functionality --- ABOUT-NIGHTLY.md | 15 +++++++++++++++ mingling/Cargo.toml | 1 + mingling_core/Cargo.toml | 1 + mingling_macros/Cargo.toml | 1 + 4 files changed, 18 insertions(+) create mode 100644 ABOUT-NIGHTLY.md diff --git a/ABOUT-NIGHTLY.md b/ABOUT-NIGHTLY.md new file mode 100644 index 0000000..f2d4ec7 --- /dev/null +++ b/ABOUT-NIGHTLY.md @@ -0,0 +1,15 @@ +# About Nightly Rust + +**Mingling** uses some features that are only available in the `nightly` toolchain. This requires you to enable the `nightly` feature: + +```toml +[dependencies] +mingling = { version = "...", features = ["nightly"] } +``` + +## Features + +> [!WARNING] +> The following features can only be used with the nightly toolchain, and are only guaranteed to compile, not to be stable or production-ready. +> +> If you need a stable development experience, please **do not use** the `nightly` feature! diff --git a/mingling/Cargo.toml b/mingling/Cargo.toml index e25c99c..12ea9cf 100644 --- a/mingling/Cargo.toml +++ b/mingling/Cargo.toml @@ -16,6 +16,7 @@ tokio = { version = "1", features = ["full"] } mingling = { path = ".", features = ["full"] } [features] +nightly = ["mingling_core/nightly", "mingling_macros/nightly"] debug = ["mingling_core/debug"] async = ["mingling_core/async", "mingling_macros/async"] diff --git a/mingling_core/Cargo.toml b/mingling_core/Cargo.toml index 83db3af..6392ce0 100644 --- a/mingling_core/Cargo.toml +++ b/mingling_core/Cargo.toml @@ -7,6 +7,7 @@ description = "Core of the mingling library" repository = "https://github.com/catilgrass/mingling" [features] +nightly = [] default = [] async = [] diff --git a/mingling_macros/Cargo.toml b/mingling_macros/Cargo.toml index 4863ab9..038ffd3 100644 --- a/mingling_macros/Cargo.toml +++ b/mingling_macros/Cargo.toml @@ -10,6 +10,7 @@ description = "Macros of the mingling library" proc-macro = true [features] +nightly = [] default = [] async = [] -- cgit