aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author魏曹先生 <1992414357@qq.com>2026-05-02 00:50:23 +0800
committer魏曹先生 <1992414357@qq.com>2026-05-02 00:50:23 +0800
commit604fb36f4251e494b3486009145401a3c1f7b326 (patch)
treea7e2ead8ad4a22baad598d42e5b48e722929f0f4
parent206a1207b25d1324b04a2eee61ac0f0d98961243 (diff)
Add nightly feature flag for Rust nightly-only functionality
-rw-r--r--ABOUT-NIGHTLY.md15
-rw-r--r--mingling/Cargo.toml1
-rw-r--r--mingling_core/Cargo.toml1
-rw-r--r--mingling_macros/Cargo.toml1
4 files changed, 18 insertions, 0 deletions
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 = []