- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The following code results in an internal compiler error. The code doesn't do anything meaningful, it's just a mimimal demonstrator for the problem. I am using v11.1.060 Update 5.
Interestingly, it goes away when I remove the ONLY: bType from the USE in the program.
regards,
Thomas
Interestingly, it goes away when I remove the ONLY: bType from the USE in the program.
regards,
Thomas
[fortran]MODULE MOD_A type aType integer :: dummy end type END MODULE MODULE MOD_B USE MOD_A TYPE bType CLASS (aType), ALLOCATABLE :: B END TYPE END MODULE program InternalError USE MOD_B, ONLY: bType implicit none end program
[/fortran]
Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks - escalated as issue DPD200152203.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In addition to above problem with the USE, I had experienced the same internal compiler error when using type-bound functions within a series ofextended types in our code when compiling a debug build.
It took me a while togenerate a minimal reproducer for the problem(I believe it's minimal, but not sure about that...).
I am not sure whether this is the same issue as above, but it seems to be somewhat different in the sense that it occurs even without USE at all.
I really hope that these issues aregoing to befixed soon. These problems (in addition to some of the other still open problems that I reported)prevent us from using type-bound procedures in our code, which we would love to do.
Best regards,
Thomas
Reproducer code:
see next post
It took me a while togenerate a minimal reproducer for the problem(I believe it's minimal, but not sure about that...).
I am not sure whether this is the same issue as above, but it seems to be somewhat different in the sense that it occurs even without USE at all.
I really hope that these issues aregoing to befixed soon. These problems (in addition to some of the other still open problems that I reported)prevent us from using type-bound procedures in our code, which we would love to do.
Best regards,
Thomas
Reproducer code:
see next post
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
[fortran]module ModuleA type :: TypeA contains procedure FuncA end type type, extends (TypeA) :: TypeAExt contains procedure FuncAExt end type type, extends (TypeAExt) :: TypeAExt2 contains procedure FuncAExt2 end type contains function FuncA(this) result(res) class (TypeA) :: this type (TypeAExt) :: res end function function FuncAExt(this) result(res) class (TypeAExt) :: this type (TypeAExt2) :: res end function function FuncAExt2(this) result(res) class (TypeAExt2) :: this type (TypeAExt2) :: res end function end module program YAF2003Prob implicit none ! Variables ! Body of YAF2003Prob end program YAF2003Prob [/fortran]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thomas,
Thanks for this latest example. It requires /debug to fail, and I think is one we have already fixed. I will verify that.
Thanks for this latest example. It requires /debug to fail, and I think is one we have already fixed. I will verify that.

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page