diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-05-29 17:13:36 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-05-29 17:13:36 +0800 |
| commit | 6edaa76d67ab1ff211c7cc9cd179ffbefe93a04f (patch) | |
| tree | 02d5b5f68b3d443baccbfc0ed3fc7fa16a3dd9a4 /mingling_macros/src/chain.rs | |
| parent | 05826d67f1f9166a6620475ffdeaa488917befd8 (diff) | |
Rename error types with consistent naming convention
Diffstat (limited to 'mingling_macros/src/chain.rs')
| -rw-r--r-- | mingling_macros/src/chain.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/mingling_macros/src/chain.rs b/mingling_macros/src/chain.rs index 559468c..ac05480 100644 --- a/mingling_macros/src/chain.rs +++ b/mingling_macros/src/chain.rs @@ -95,7 +95,7 @@ fn generate_proc_fn( let body_stmts: &[syn::Stmt] = if is_unit_return && has_resources { let mut stmts = fn_body_stmts.to_vec(); stmts.push(syn::Stmt::Expr( - syn::parse_quote! { crate::EmptyResult::new(()).to_chain() }, + syn::parse_quote! { crate::ResultEmpty::new(()).to_chain() }, None, )); // Box::leak to get a &'static [syn::Stmt] @@ -106,7 +106,7 @@ fn generate_proc_fn( let wrapped_body = wrap_body_with_mut_resources(body_stmts, &mut_resources, program_type); - // When the function returns `()`, wrap the result with EmptyResult + // When the function returns `()`, wrap the result with ResultEmpty let call_or_wrapped = if is_unit_return { if has_resources { quote! { @@ -121,7 +121,7 @@ fn generate_proc_fn( }; quote! { #call - crate::EmptyResult::new(()).to_chain() + crate::ResultEmpty::new(()).to_chain() } } } else if has_resources { @@ -179,7 +179,7 @@ fn generate_original_fn( quote! { { #fn_body - crate::EmptyResult::new(()).to_chain() + crate::ResultEmpty::new(()).to_chain() } } } else { |
