I have a C function which uses an enum
as parameter, like the example bellow:
typedef enum
{
AB,
CD
} A;
void f(A input)
{
// do something
}
int main(void)
{
// do something
f(-10);
// do something
}
Is there a warning that I can enable for assigning an enum variable with a value out of the range of the enum?