Open
Description
I have the following signature for my HardFault
handler:
#[exception(trampoline = false)]
#[naked]
unsafe fn HardFault() -> ! {
...
This triggers the compiler warning
warning: Rust ABI is unsupported in naked functions
note:#[warn(undefined_naked_function_abi)]
on by default
Which could be avoided by modifying the signature to be:
#[exception(trampoline = false)]
#[naked]
unsafe extern "C" fn HardFault() -> ! {
...
But this is not accepted by the macro:
HardFault
handler must have signatureunsafe fn() -> !
Is there any reason for the macro to not allow specifying the ABI?
Also, could someone point me as to why does the following not produce the same warning?
#[pre_init]
#[naked]
unsafe fn pre_init() {
...
Metadata
Metadata
Assignees
Labels
No labels