aboutsummaryrefslogtreecommitdiff
path: root/cortex-m-rt/src
diff options
context:
space:
mode:
authorGravatar Jorge Aparicio <jorge@japaric.io> 2018-09-17 20:12:25 +0200
committerGravatar Jorge Aparicio <jorge@japaric.io> 2018-09-18 01:08:38 +0200
commitfb7368e658ed175a35cdf4a33a02b356aa139523 (patch)
tree782a280a996604ad2b73f247311110a6df225c77 /cortex-m-rt/src
parent98ce8a1f5d30e3c5c421c0e9c19c078cea7c0473 (diff)
downloadcortex-m-fb7368e658ed175a35cdf4a33a02b356aa139523.tar.gz
cortex-m-fb7368e658ed175a35cdf4a33a02b356aa139523.tar.zst
cortex-m-fb7368e658ed175a35cdf4a33a02b356aa139523.zip
implement `#[interrupt]`
Diffstat (limited to 'cortex-m-rt/src')
-rw-r--r--cortex-m-rt/src/lib.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/cortex-m-rt/src/lib.rs b/cortex-m-rt/src/lib.rs
index f3e58d0..7488cc9 100644
--- a/cortex-m-rt/src/lib.rs
+++ b/cortex-m-rt/src/lib.rs
@@ -394,6 +394,8 @@ extern crate r0;
use core::fmt;
use core::sync::atomic::{self, Ordering};
+#[cfg(feature = "device")]
+pub use macros::interrupt;
pub use macros::{entry, exception, pre_init};
#[export_name = "error: cortex-m-rt appears more than once in the dependency graph"]
@@ -674,7 +676,7 @@ pub static __EXCEPTIONS: [Vector; 14] = [
// If we are not targeting a specific device we bind all the potential device specific interrupts
// to the default handler
-#[cfg(all(not(feature = "device"), not(armv6m)))]
+#[cfg(all(any(not(feature = "device"), test), not(armv6m)))]
#[doc(hidden)]
#[link_section = ".vector_table.interrupts"]
#[no_mangle]