0

I'm trying to compile in VS Code but error appears for this line of code:

void interrupt_handler_function(void) __attribute__ ((interrupt("FIQ"))); 

error:

error: x86 'interrupt' attribute only applies to functions that have only a pointer parameter optionally followed by an integer parameter

Compiler is: GCC 9.4.0 x86_64-linux-gnu

Am I missing something in the interrupt declaration? Any input is much appreciated!

Tried solution in this link: clang-check using arm as a target but did not work

8
  • 1
    Well, you don't have a pointer parameter ... Commented Nov 3, 2023 at 22:31
  • The other question is about trying to compile for ARM, not x86. Commented Nov 3, 2023 at 22:31
  • x86 compiler and ARM target - install correct toolchain Commented Nov 3, 2023 at 22:39
  • @0___________, I changed the compiler with the correct one, but the error still persits. Commented Nov 6, 2023 at 16:46
  • @500-InternalServerError, isn't it that interrupt hander functions should have no parameters? Why is it looking for a pointer parameter? Commented Nov 6, 2023 at 16:47

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.