Skip to content

Commit 580d13c

Browse files
authored
Error if the wrong architecture is being used
1 parent 90075ce commit 580d13c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/lib.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,12 @@
2727
pub mod interrupt;
2828
pub mod asm;
2929

30+
#[cfg(not(any(doc, target_arch = "avr")))]
31+
compile_error!(
32+
"Ensure that you are using an AVR target! You may need to change \
33+
directories or pass a --target flag to cargo."
34+
);
35+
3036
#[allow(unused_imports)]
3137
use generic::*;
3238
#[doc = r"Common register and bit access and modify traits"]

0 commit comments

Comments
 (0)