diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-08-17 00:26:00 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-08-17 00:40:37 +0800 |
| commit | 1cd4a824b3bffbbdf391837288921d538438a751 (patch) | |
| tree | a8ea0cf092d7862d15018e434c0af9707a67db94 /docs/dev/pages/issues/t0_remove-pack-macros.md | |
| parent | 62d2f8637da3274fc22debb62b79f15e521d503e (diff) | |
docs: split 0.5.0 roadmap into individual issue pages
Diffstat (limited to 'docs/dev/pages/issues/t0_remove-pack-macros.md')
| -rw-r--r-- | docs/dev/pages/issues/t0_remove-pack-macros.md | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/docs/dev/pages/issues/t0_remove-pack-macros.md b/docs/dev/pages/issues/t0_remove-pack-macros.md new file mode 100644 index 0000000..517646a --- /dev/null +++ b/docs/dev/pages/issues/t0_remove-pack-macros.md @@ -0,0 +1,49 @@ +`<h1 align="center">[T0] Remove the pack! Family of Macros</h1> +<p align="center"> + Breaking: retire the entire <code>pack!</code> family in favor of the <code>Grouped</code> derive +</p> + +> [!NOTE] +> +> This is a **Breaking Change** planned for Mingling 0.5.0. + +## Background + +Since the very first version of Mingling, the `pack!` macro has been around. Its purpose has gradually narrowed from "creating a type and registering it to Mingling" to "creating a newtype that derives Grouped". In other words, the functionality of `pack!` is gradually being replaced by the `Grouped derive`. + +Furthermore, in 0.2.0, in order to accommodate `StructuralData derive`, Mingling introduced `pack_structural!` and `pack_err_structural!` variants all at once, which greatly increases the maintenance cost of the project. + +## Plan + +Remove the entire `pack!` family of macros (`pack!`, `pack_structural!`, `pack_err_structural!`) as a Breaking Change in 0.5.0. + +All future type creation will be done as follows: + +```rust +// Before +pack!(ResultNames = Vec<String>); + +// After +#[derive(Grouped)] +pub struct ResultNames { + names: Vec<String> +} +``` + +## Tasks + +- [ ] Identify all usages of `pack!` / `pack_structural!` / `pack_err_structural!` across the codebase, examples, and docs +- [ ] Migrate internal usages to `#[derive(Grouped)]` +- [ ] Remove the macro definitions and their re-exports +- [ ] Update the docs / helpdoc examples that reference `pack!` +- [ ] Update downstream feature docs (`structural_renderer` etc.) where `pack_structural!` was involved +- [ ] Verify all tests pass + +## 🕘 Progress + +- [ ] In Progress +- [ ] Complete + +<p align="center" style="font-size: 0.85em; color: gray;"> + Written by @Weicao-CatilGrass +</p> |
