aboutsummaryrefslogtreecommitdiff
path: root/rtic-macros/src/codegen.rs
diff options
context:
space:
mode:
authorGravatar bors[bot] <26634292+bors[bot]@users.noreply.github.com> 2023-03-29 18:56:07 +0000
committerGravatar GitHub <noreply@github.com> 2023-03-29 18:56:07 +0000
commit31055fa64a6e178caa45f8a8e862ded6a68d3e55 (patch)
tree72c051f4d908ae6c4baf9b1a48678e64abfb39c2 /rtic-macros/src/codegen.rs
parent2a17a056d0a69f988393e12bf50a42658e291682 (diff)
parent323b847bf692a0054647536a6495f20373f6d9c7 (diff)
downloadrtic-31055fa64a6e178caa45f8a8e862ded6a68d3e55.tar.gz
rtic-31055fa64a6e178caa45f8a8e862ded6a68d3e55.tar.zst
rtic-31055fa64a6e178caa45f8a8e862ded6a68d3e55.zip
Merge #719
719: Adding a limit that async HALs can read and have as max prio r=AfoHT a=korken89 Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
Diffstat (limited to 'rtic-macros/src/codegen.rs')
-rw-r--r--rtic-macros/src/codegen.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/rtic-macros/src/codegen.rs b/rtic-macros/src/codegen.rs
index 48ee5e33..c04f2131 100644
--- a/rtic-macros/src/codegen.rs
+++ b/rtic-macros/src/codegen.rs
@@ -45,6 +45,7 @@ pub fn app(app: &App, analysis: &Analysis) -> TokenStream2 {
let device = &app.args.device;
let rt_err = util::rt_err_ident();
+ let async_limit = bindings::async_prio_limit(app, analysis);
quote!(
/// The RTIC application module
@@ -52,6 +53,8 @@ pub fn app(app: &App, analysis: &Analysis) -> TokenStream2 {
/// Always include the device crate which contains the vector table
use #device as #rt_err;
+ #(#async_limit)*
+
#(#user_imports)*
#(#user_code)*