The patch below is based on a previous version by Steve. The present version fixes an additional copy&paste error. Needless to say that it (still!) regtests cleanly on x86_64-pc-linux-gnu. OK for master? As it appears safe, OK for backport to at least 10-branch? Thanks, Harald PR fortran/85796 - Floating point exception with implied do Catch invalid step=0 in implied do loop within data statements. gcc/fortran/ChangeLog: PR fortran/85796 * resolve.c (traverse_data_list): Fix copy&paste errors; catch step=0 in implied do loop. gcc/testsuite/ChangeLog: PR fortran/85796 * gfortran.dg/pr85796.f90: New test.