- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
my code works ok with ifort 9.0.021.
I've just installed 9.0.031 and it no more works.
I've found what was going wrong, which can be illustrated with this little example :
program test
type t
real*8, allocatable :: d(:,:)
end type t
type(t) :: tab(2)
call alloc(tab)
contains
subroutine alloc(tab)
type(t), intent(out) :: tab(:)
end subroutine alloc
end program test
I get a segmentation fault.
If
type(t), intent(out) :: tab(:)
is changed to
type(t), intent(inout) :: tab(:)
or
type(t), intent(out) :: tab(2)
it works fine.
What's going on ?
Thanks.
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
With INTENT(OUT), the compiler is supposed to ensure that all of the allocatable components are deallocated. It is making a mistake apparently while doing so. I have passed this on to the developers. If you choose to file a support request, please reference T65004.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This bug has been fixed for a future update (late May at the earliest.)
![](/skins/images/C4F7392A5C68ACA60290C9576F107044/responsive_peak/images/icon_anonymous_message.png)
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