Go to the first, previous, next, last section, table of contents.


GLOBALS

Global name name defined at ... already defined...
Global name name at ... has different type...
Too many arguments passed to name at ...
Too few arguments passed to name at ...
Argument #n of name is ...

These messages all identify disagreements about the global procedure named name among different program units (usually including name itself).

These disagreements, if not diagnosed, could result in a compiler crash if the compiler attempted to inline a reference to name within a calling program unit that disagreed with the name program unit regarding whether the procedure is a subroutine or function, the type of the return value of the procedure (if it is a function), the number of arguments the procedure accepts, or the type of each argument.

Such disagreements should be fixed in the Fortran code itself. However, if that is not immediately practical, and the code has been working for some time, it is possible it will work when compiled by g77 with the `-fno-globals' option.

The `-fno-globals' option disables these diagnostics, and also disables all inlining of references to global procedures to avoid compiler crashes. The diagnostics are actually produced, but as warnings, unless the `-Wno-globals' option also is specified.

After using `-fno-globals' to work around these problems, it is wise to stop using that option and address them by fixing the Fortran code, because such problems, while they might not actually result in bugs on some systems, indicate that the code is not as portable as it could be. In particular, the code might appear to work on a particular system, but have bugs that affect the reliability of the data without exhibiting any other outward manifestations of the bugs.


Go to the first, previous, next, last section, table of contents.