3#ifndef TETL_HARDWARE_STM32_INTERRUPT_HPP
4#define TETL_HARDWARE_STM32_INTERRUPT_HPP
39 static auto call(
vector_t const& callbacks,
isr_ids id)
noexcept ->
void { callbacks[
static_cast<size_t>(id)](); }
43 if (callbacks[
static_cast<size_t>(
id)] !=
nullptr) {
44 callbacks[
static_cast<size_t>(id)]();
isr_ids
Definition interrupt.hpp:28
@ max_id
Definition interrupt.hpp:32
@ hard_fault
Definition interrupt.hpp:30
@ sys_tick
Definition interrupt.hpp:31
@ nmi
Definition interrupt.hpp:29
array(T, U...) -> array< T, 1+sizeof...(U)>
One deduction guide is provided for array to provide an equivalent of experimental::make_array for co...
Definition interrupt.hpp:35
static auto call(vector_t const &callbacks, isr_ids id) noexcept -> void
Definition interrupt.hpp:39
void(*)() callback_t
Definition interrupt.hpp:36
etl::array< callback_t, static_cast< size_t >(isr_ids::max_id)> vector_t
Definition interrupt.hpp:37
static auto call_checked(vector_t const &callbacks, isr_ids id) noexcept -> void
Definition interrupt.hpp:41