- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
hi,
i've a code which use dynamic allocation inside a structure, something like:
type block
integer :: size_x,size_y
real(8), allocatable :: p(:,:)
end type block
type(block), allocatable :: blk(:)
it works when i compile using ifort. however when i tried to compile it on another of my university's server which uses ifc, it gives me an error 24, syntax error.
is this feature not supported in ifc, which is an older version of the compiler?
thank you!
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Exactly right. That feature is from the Fortran 2003 standard and ifc 7.x and earlier does not support it. You can use POINTER instead of ALLOCATABLE, but the semantics are subtlly different, especially if you assign one variable of type block to another.

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