https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102716
--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-10 branch has been updated by Harald Anlauf <anl...@gcc.gnu.org>: https://gcc.gnu.org/g:bec9e43e1611b62732bf29763c3e8bddea480f62 commit r10-10231-gbec9e43e1611b62732bf29763c3e8bddea480f62 Author: Harald Anlauf <anl...@gmx.de> Date: Thu Oct 14 20:18:14 2021 +0200 Fortran: fix order of checks for the SHAPE intrinsic gcc/fortran/ChangeLog: PR fortran/102716 * check.c (gfc_check_shape): Reorder checks so that invalid KIND arguments can be detected. gcc/testsuite/ChangeLog: PR fortran/102716 * gfortran.dg/shape_10.f90: New test. (cherry picked from commit 1b115daf62d94337b3d0b2962b0bbbf005a450e0)