diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-06-29 03:34:41 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-06-29 03:34:41 +0800 |
| commit | ba15b7c06468cb6c52c8d2a53419fd83f9ebcb8b (patch) | |
| tree | cdaa1c71585d10dd73945cefe95f2c25f27924ed /src/deprecated.rs | |
| parent | ff70307869a547b13850d1eec3f72e8ca3bca265 (diff) | |
refactor: promote project to workspace with macros sub-crate
Diffstat (limited to 'src/deprecated.rs')
| -rw-r--r-- | src/deprecated.rs | 45 |
1 files changed, 0 insertions, 45 deletions
diff --git a/src/deprecated.rs b/src/deprecated.rs deleted file mode 100644 index b218969..0000000 --- a/src/deprecated.rs +++ /dev/null @@ -1,45 +0,0 @@ -#[macro_export] -macro_rules! tmpl_param { - ($template:ident, $($key:ident = $value:expr),* $(,)?) => {{ - $( - $template.insert_param(stringify!($key).to_string(), $value.to_string()); - )* - }}; -} - -#[macro_export] -macro_rules! tmpl { - ($template:ident, $($name:ident { - $($key:ident = $value:expr),* $(,)? - }),* $(,)?) => {{ - $( - let $name = $template.add_impl(stringify!($name).to_string()); - $( - $name.push({ - let mut params = std::collections::HashMap::new(); - params.insert(stringify!($key).to_string(), $value.to_string()); - params - }); - )* - )* - }}; - - // Old syntax - ($template:ident += { - $($name:ident { - $(($($key:ident = $value:expr),* $(,)?)),* - $(,)? - }),* - }) => {{ - $( - let $name = $template.add_impl(stringify!($name).to_string()); - $( - $name.push({ - let mut params = std::collections::HashMap::new(); - $(params.insert(stringify!($key).to_string(), $value.to_string());)* - params - }); - )* - )* - }}; -} |
