https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95502
--- Comment #5 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:cfe0a2ec26867b290eb84af00317e60f8b67455c commit r12-1542-gcfe0a2ec26867b290eb84af00317e60f8b67455c Author: Harald Anlauf <anl...@gmx.de> Date: Wed Jun 16 22:04:22 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.