diff options
| author | Emil Fresk <emil.fresk@gmail.com> | 2021-02-18 19:30:59 +0100 |
|---|---|---|
| committer | Emil Fresk <emil.fresk@gmail.com> | 2021-02-18 19:30:59 +0100 |
| commit | ebf2f058a4d2a1fcf118144b9893dc3038939bad (patch) | |
| tree | 11c7b828cc380737de36e6ab77edbd63bf42a72e /macros/src/codegen/util.rs | |
| parent | b57ef0bf9d836ad031e4a4f7930162003128dc74 (diff) | |
Now with new monotonic trait and crate
Diffstat (limited to 'macros/src/codegen/util.rs')
| -rw-r--r-- | macros/src/codegen/util.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/macros/src/codegen/util.rs b/macros/src/codegen/util.rs index 287ba40..7a12f23 100644 --- a/macros/src/codegen/util.rs +++ b/macros/src/codegen/util.rs @@ -239,6 +239,16 @@ pub fn tq_ident(name: &str) -> Ident { Ident::new(&format!("TQ_{}", name), Span::call_site()) } +/// Generates an identifier for monotonic timer storage +pub fn monotonic_ident(name: &str) -> Ident { + Ident::new(&format!("MONOTONIC_STORAGE_{}", name), Span::call_site()) +} + +/// Generates an identifier for monotonic timer storage +pub fn mangle_monotonic_type(name: &str) -> Ident { + Ident::new(&format!("MonotonicMangled{}", name), Span::call_site()) +} + /// The name to get better RT flag errors pub fn rt_err_ident() -> Ident { Ident::new( |
