File tree Expand file tree Collapse file tree 2 files changed +3
-5
lines changed Expand file tree Collapse file tree 2 files changed +3
-5
lines changed Original file line number Diff line number Diff line change 1- #![ deny( unsafe_code) ]
21#![ deny( warnings) ]
32#![ no_main]
43#![ no_std]
@@ -14,6 +13,6 @@ fn foo() -> ! {
1413}
1514
1615#[ exception]
17- fn DefaultHandler ( _irqn : i16 ) -> ! {
16+ unsafe fn DefaultHandler ( _irqn : i16 ) -> ! {
1817 loop { }
1918}
Original file line number Diff line number Diff line change 11//! How to override the hard fault exception handler and the default exception handler
22
3- #![ deny( unsafe_code) ]
43#![ deny( warnings) ]
54#![ no_main]
65#![ no_std]
@@ -18,12 +17,12 @@ fn main() -> ! {
1817}
1918
2019#[ exception]
21- fn DefaultHandler ( _irqn : i16 ) {
20+ unsafe fn DefaultHandler ( _irqn : i16 ) {
2221 asm:: bkpt ( ) ;
2322}
2423
2524#[ exception]
26- fn HardFault ( _ef : & ExceptionFrame ) -> ! {
25+ unsafe fn HardFault ( _ef : & ExceptionFrame ) -> ! {
2726 asm:: bkpt ( ) ;
2827
2928 loop { }
You can’t perform that action at this time.
0 commit comments