Hi I want to use this __attribute__((naked)) for one of my functions in keil, but it generates a warning that says
main.c(6846): warning: #1207-D: unknown attribute "naked"
This is my function prototype
__attribute__((naked)) void myTestFunction(void) { }
what's going on? what should I do to enable the naked!?
for __CC_ARM, no it is not supported. use
__asm void myTestFunction(void)
make sure you look up what __attribute__((naked)) actually means as it appears as if you are creating a "C" function and the naked attribute only has meaning for routines consisting entirely of asm instructions.
ARMCLANG also supports __attribute__((naked))