https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95502
--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Harald Anlauf <anl...@gcc.gnu.org>: https://gcc.gnu.org/g:72e3d92178b44a3722519ec68e72e307443bda70 commit r12-1540-g72e3d92178b44a3722519ec68e72e307443bda70 Author: Harald Anlauf <anl...@gmx.de> Date: Wed Jun 16 21:54:16 2021 +0200 Fortran - ICE in gfc_check_do_variable, at fortran/parse.c:4446 Avoid NULL pointer dereferences during error recovery. gcc/fortran/ChangeLog: PR fortran/95501 PR fortran/95502 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer dereference. * match.c (gfc_match_pointer_assignment): Likewise. * parse.c (gfc_check_do_variable): Avoid comparison with NULL symtree. gcc/testsuite/ChangeLog: PR fortran/95501 PR fortran/95502 * gfortran.dg/pr95502.f90: New test.