- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I thought this had been fixed long time ago (for Intel v16), but the following testcase looks inconsistent:
program p
implicit none
integer, pointer :: x(:,:)
allocate (x(-3:3,4:0))
print *, "lbound =", lbound (x)
call sub1 (x)
call sub2 (x)
contains
subroutine sub1 (y)
integer, pointer :: y(:,:)
print *, "lbound =", lbound (y)
end
subroutine sub2 (y)
integer, pointer :: y(..)
print *, "lbound =", lbound (y)
end
end
With
Intel(R) Fortran Intel(R) 64 Compiler Classic for applications running on Intel(R) 64, Version 2021.3.0 Build 20210609_000000
I get:
lbound = -3 1
lbound = -3 1
lbound = -3 4
Why does assumed rank differ here for the second dimension (which has extent zero)?
Thanks,
Harald
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, this looks like a regression. It works as you expect with 19.1.4, but not with 2021.1.1 or 2021.4.0. I filed a bug, CMPLRIL0-34270. I'll let you know when it's fixed.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Fortran 2018, 16.9.109 LBOUND: careful reading of the paragraph on the result value would require for sub2 to print the same as sub1. Thus the handling of assumed-rank would need to be changed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, this looks like a regression. It works as you expect with 19.1.4, but not with 2021.1.1 or 2021.4.0. I filed a bug, CMPLRIL0-34270. I'll let you know when it's fixed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This issue you reported is fixed in the latest version of ifort, 2021.6.0. It's part of oneAPI HPC Toolkit 2022.2 that was recently released.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I can confirm that the issue is fixed.
Thanks,
Harald

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