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/54880] New: ICE in gfc_create_module_variable, at fortran/trans-decl.c:4013


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

             Bug #: 54880
           Summary: ICE in gfc_create_module_variable, at
                    fortran/trans-decl.c:4013
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: slayoo@staszic.waw.pl


Created attachment 28405
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28405
testcase to trigger the ICE

Running the attached testcase with the current Debian's gcc-snapshot gfortran I
get:

$ cat m1.f95 
module solver_2D_m
  use adv_m
  type :: solver_2D_t
    class(adv_t), pointer :: adv
    contains
  end type 
  contains
  subroutine solver_2D_solve(this)
    class(solver_2D_t) :: this
  end subroutine
end module


$ cat m2.f95 
module adv_m
  type, abstract :: adv_t
    contains
    procedure(op_2D_i), deferred :: op_2D
  end type
  abstract interface
    subroutine op_2D_i(this)
      import :: adv_t
      class(adv_t) :: this
    end subroutine
  end interface
end module


$ cat m12.f95 
#include "m1.f95"
#include "m2.f95"


$ cat m21.f95 
#include "m2.f95"
#include "m1.f95"
program m21
end


$ cat trigger.sh 
#!/bin/bash
/usr/lib/gcc-snapshot/bin/gfortran -cpp m21.f95
/usr/lib/gcc-snapshot/bin/gfortran -cpp m12.f95


$ ./trigger.sh 
m1.f95:10:0: internal compiler error: in gfc_create_module_variable, at
fortran/trans-decl.c:4013
   end subroutine
 ^
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-snapshot/README.Bugs> for instructions.


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