This is the mail archive of the 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/33375] New: ICE (segfault) gfortran.dg/common_6.f90

With 4.3.0 20070910 [trunk revision 128322] I get a segmentation fault when
compiling gfortran.dg/common_6.f90; excerpt:

! PR 23765 : We used to incorrectly accept common blocks with no symbols
common          ! { dg-error "Syntax error" }
common y/d/     ! { dg-error "Syntax error" }

The crash happens in: resolve_common_blocks

  for (csym = common_root->n.common->head; csym; csym = csym->common_next)
      if (csym->ts.type == BT_DERIVED
          && !(csym->ts.derived->attr.sequence
               || csym->ts.derived->attr.is_bind_c))

When the error happens:
(gdb) p csym->ts
$9 = {type = 0, kind = 0, derived = 0x0, cl = 0x0, is_c_interop = 6,
  is_iso_c = 1, f90_type = BT_UNKNOWN}

I don't understand why "csym->ts.derived->attr" is evaluated as "csym->ts.type
!= BT_DERIVED". ???

           Summary: ICE (segfault) gfortran.dg/common_6.f90
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Keywords: ice-on-invalid-code
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: burnus at gcc dot gnu dot org

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