During preprocessor expansion of a function-like macro, if the number of arguments is not acceptable for the macro or we fail to find the right parenthesis, we silently skip the expansion. This may be confusing to a user that is using a macro incorrectly (specially if the unexpanded stream of tokens is still valid Fortran). This change adds a diagnostic for these cases.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
This check would preclude defining some cases of a function with a Fortran generic interface and using a function-like macro to define or override another case.
If the preprocessor doesn't catch this condition, semantics or the linker will get it later.