It would be nice having a compile-time option to initialize local scalar variables, to zero (.false. for logical, 0 for integer and 0.0 for real) and to NaN (for floating-point types).
g77 had -finit-local-zero, Intel has -zero, we could have -finit-local-zero and -finit-local-nan. -- Summary: Initialize local scalar variables Product: gcc Version: 4.2.0 Status: UNCONFIRMED Severity: enhancement Priority: P3 Component: fortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: fxcoudert at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26150