Duplicate variable declaration

This error occurs when you try to declare two variables with the same name. Rename the second variable, or remove its declaration to fix the error.

int x        ; OK, first declaration
int x        ; Error: duplicate declaration
x = 3        ; OK, no declaration
int y = 3    ; OK, other variable

See Also
Errors