https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108957
--- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Mikael Morin <mik...@gcc.gnu.org>: https://gcc.gnu.org/g:e6dba708c8627080f4ca776590a191683b38336c commit r14-4021-ge6dba708c8627080f4ca776590a191683b38336c Author: Mikael Morin <mik...@gcc.gnu.org> Date: Fri Sep 15 13:40:08 2023 +0200 fortran: Remove reference count update [PR108957] Remove one reference count incrementation following the assignment of a symbol pointer to a local variable. Most symbol pointers are "weak" pointer and don't need any reference count update when they are assigned, and it is especially the case of local variables. This fixes a memory leak with the testcase from the PR (not included). PR fortran/108957 gcc/fortran/ChangeLog: * gfortran.h (gfc_symbol): Add comment documenting reference counting. * parse.cc (parse_interface): Remove reference count incrementation.