Compile problem with nested type

Compile problem with nested type

Here is the code in Test.f90

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

module type_definitions
type AA
integer :: idn
type(BB),pointer :: n
end type AA

type BB
integer :: id
type(AA),pointer :: m
end type BB

end module type_definitions

subroutine findx(kk)
use type_definitions
implicit none
type(AA) :: kk
end subroutine findx

program main
use type_definitions
implicit none
character*18 ar,md
open(1,file='../../../Data/Model.dat')
read(1,'(a18)')ar
read(1,'(a18)')md
close(1)
end program main

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

There is a type AA defined in type BB, and also the type BB exist in type AA,  problem occers with "fortcom: Fatal: There has been an internal compiler error (C0000005)" under VS2008+IFV11.1.038. I am really confused as I compiled it in IFV prompt with "ifort -o test test.f90", it works well.  This is a simply section from a robust scientific package, and I prefer debugging it step by step in VS2008, so what is the problem bewteen the different methods? Thanks for any comments in advance.

3 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

It compiles under VS2010 and XE 13.1.0.149.

Try turning off the diagnostics "Check routine interfaces"

Right, that's the point. Thanks a lot. The problem is fixed.

Leave a Comment

Please sign in to add a comment. Not a member? Join today