From f96b25fdf2d7421cc16830a4ccac4ebb3e69cc5d Mon Sep 17 00:00:00 2001 From: Emil Fresk Date: Thu, 15 Oct 2020 18:50:17 +0200 Subject: Updated examples More work --- macros/src/codegen/util.rs | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'macros/src/codegen/util.rs') diff --git a/macros/src/codegen/util.rs b/macros/src/codegen/util.rs index f04ccb23..887ee3bd 100644 --- a/macros/src/codegen/util.rs +++ b/macros/src/codegen/util.rs @@ -106,6 +106,14 @@ pub fn late_resources_ident(init: &Ident) -> Ident { ) } +/// Mangle an ident +pub fn mangle_ident(ident: &Ident) -> Ident { + Ident::new( + &format!("__rtic_internal_{}", ident.to_string()), + Span::call_site(), + ) +} + fn link_section_index() -> usize { static INDEX: AtomicUsize = AtomicUsize::new(0); -- cgit v1.2.3