Solved
CubeIDE incorrectly flags syntax error on static_assert at file scope
Split from CubeIDE incorrectly flags __attribute__((fallthrough)) as syntax error.
I've also noticed it doesn't like the use of static_assert at file scope:

Split from CubeIDE incorrectly flags __attribute__((fallthrough)) as syntax error.
I've also noticed it doesn't like the use of static_assert at file scope:

Hello
Thank you for bringing this issue to our attention.
A ticket has been escalated to dev team for further investigation.
Internal ticket number:209826
THX
Ghofrane
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.