From 60b91db3df168532f9143f0cafb7b5166e1dc78b Mon Sep 17 00:00:00 2001 From: 魏曹先生 <1992414357@qq.com> Date: Sat, 16 May 2026 22:31:52 +0800 Subject: Accept paths for program name parameters in macros MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit All proc macros (`pack!`, `dispatcher!`, `#[chain]`, `#[program_setup]`, `#[dispatcher_clap]`, `#[derive(Groupped)]`) now parse program names as `syn::Path` instead of bare `Ident`, allowing use of paths like `crate::MyProgram` or `my_crate::MyProgram`. The default program name `ThisProgram` is no longer re-exported or required as an import — generated code references `crate::ThisProgram` directly. --- mling/src/cli/read.rs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'mling/src/cli/read.rs') diff --git a/mling/src/cli/read.rs b/mling/src/cli/read.rs index 3bd9fc2..e9cd6bb 100644 --- a/mling/src/cli/read.rs +++ b/mling/src/cli/read.rs @@ -7,10 +7,7 @@ use mingling::{ }; use serde::Serialize; -use crate::{ - ThisProgram, - project_solver::{BinaryItem, solve_current_dir}, -}; +use crate::project_solver::{BinaryItem, solve_current_dir}; dispatcher!("show-target-dir", ReadTargetDirCommand => ReadTargetDirEntry); dispatcher!("show-workspace-root", ReadWorkspaceRootCommand => ReadWorkspaceRootEntry); -- cgit