diff options
Diffstat (limited to 'rtic-macros/src/codegen/async_dispatchers.rs')
-rw-r--r-- | rtic-macros/src/codegen/async_dispatchers.rs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/rtic-macros/src/codegen/async_dispatchers.rs b/rtic-macros/src/codegen/async_dispatchers.rs index 289a63b5..54db2b34 100644 --- a/rtic-macros/src/codegen/async_dispatchers.rs +++ b/rtic-macros/src/codegen/async_dispatchers.rs @@ -2,7 +2,7 @@ use crate::syntax::ast::App; use crate::{ analyze::Analysis, codegen::{ - bindings::{interrupt_entry, interrupt_exit}, + bindings::{async_entry, interrupt_entry, interrupt_exit, handler_config}, util, }, }; @@ -67,14 +67,17 @@ pub fn codegen(app: &App, analysis: &Analysis) -> TokenStream2 { let attribute = &interrupts.get(&level).expect("UNREACHABLE").1.attrs; let entry_stmts = interrupt_entry(app, analysis); let exit_stmts = interrupt_exit(app, analysis); - + let async_entry_stmts = async_entry(app, analysis, dispatcher_name.clone()); + let config = handler_config(app,analysis,dispatcher_name.clone()); items.push(quote!( #[allow(non_snake_case)] #[doc = #doc] #[no_mangle] #(#attribute)* + #(#config)* unsafe fn #dispatcher_name() { #(#entry_stmts)* + #(#async_entry_stmts)* /// The priority of this interrupt handler const PRIORITY: u8 = #level; |