This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/28201] gfortran ICE if argument list does not match generic interface



------- Comment #2 from pault at gcc dot gnu dot org  2006-07-07 18:46 -------
This fixes the fault and i presently regtesting:

Index: gcc/fortran/resolve.c
===================================================================
*** gcc/fortran/resolve.c       (revision 115245)
--- gcc/fortran/resolve.c       (working copy)
*************** resolve_generic_s (gfc_code * c)
*** 1500,1508 ****
    if (m == MATCH_ERROR)
      return FAILURE;

!   if (sym->ns->parent != NULL)
      {
!       gfc_find_symbol (sym->name, sym->ns->parent, 1, &sym);
        if (sym != NULL)
        {
          m = resolve_generic_s0 (c, sym);
--- 1500,1511 ----
    if (m == MATCH_ERROR)
      return FAILURE;

!   if (sym->ns->parent != NULL || sym->attr.use_assoc)
      {
!       if (sym->attr.use_assoc)
!       gfc_find_symbol (sym->name, sym->ns, 1, &sym);
!       else
!       gfc_find_symbol (sym->name, sym->ns->parent, 1, &sym);
        if (sym != NULL)
        {
          m = resolve_generic_s0 (c, sym);

If all is well, I will prepare a testsuite case and submit tomorrow.

Paul


-- 

pault at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |pault at gcc dot gnu dot org
                   |dot org                     |
             Status|NEW                         |ASSIGNED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28201


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]