I believe this occurs because sdcc partially understands K&R syntax so that recognition of the error is delayed until later in the front end. The delayed error reporting can cause grief in debugging but is otherwise unharmful.
Example:
void just_some_function(int some_param) // <=== forgot ; int a; void some_other_function(int some_param) { // <=== syntax error report on '{' // blabla }
sdcc is unable to determine there is an error until it's inside some_other_function(). It should be able to report an error at "int a;". This is an error under K&R because "a" does not match the name of any parameter given to just_some_function() and I think it goes undetected until later because an early pass understands K&R so the error is not caught until later steps.
A more competer description:
https://github.com/z88dk/z88dk/issues/38