Skip to content

Commit

Permalink
chore: better safety comment
Browse files Browse the repository at this point in the history
  • Loading branch information
Ddystopia committed Jan 27, 2025
1 parent aa6e9db commit 768a815
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rtic-macros/src/codegen/module.rs
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ pub fn codegen(ctxt: Context, app: &App, analysis: &Analysis) -> TokenStream2 {
#[allow(non_snake_case)]
#[doc(hidden)]
pub fn #internal_waker_ident() -> ::core::task::Waker {
// SAFETY: If `try_allocate` succeeds one must call `spawn`, which we do.
// SAFETY: #exec_name is a valid pointer to an executor.
unsafe {
let exec = rtic::export::executor::AsyncTaskExecutor::#from_ptr_n_args(#name, &#exec_name);
exec.waker(|| {
Expand Down

0 comments on commit 768a815

Please sign in to comment.