Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

char array allocate bug?

dave_frank
Beginner
719 Views
Below was uncovered in current CLF topic, and
other compilers may have similiar difficulties..
The code appears to be legal F95+ for CVF6.6B

! --------------------
program test
character(15), allocatable :: a(:)
call my_sub(a)
write (*,*) loc(a) ! outputs 256 which is wrong?
write (*,*) a ! access violation

contains
subroutine my_sub(a)
character(*), allocatable :: a(:)
allocate ( a(3) )
a = 'Hello World' ! statement executed, no trap
end subroutine my_sub
end program
0 Kudos
5 Replies
Steven_L_Intel1
Employee
719 Views
I tried this in the Intel Visual Fortran compiler and it executes correctly. Look for it in December.

Steve
0 Kudos
dave_frank
Beginner
719 Views
Steve,
re: "look for this in December"

Meaning you confirm its a bug in CVF6.6B and to
look for a fix in CVF6.6C ?

BTW, when might we expect the "early november" briefing
you promised about upcoming release schedules?
0 Kudos
Steven_L_Intel1
Employee
719 Views
I did say Intel Visual Fortran and not CVF, didn't I? Thought I did... Yes, I can reproduce the bug in CVF 6.6B.

There will be a CVF 6.6C - I don't know if the fix is in that. Could be.

What was waiting for November was when I could point people to a copy of my slides from Intel Developer Forum. They were supposed to be available Nov. 3 but didn't get released until yesterday, it seems. I'll point to them in my IDF thread.

Steve
0 Kudos
dave_frank
Beginner
719 Views

Steve,
methinks you implied making detailed info about
the upcoming releases in recent CLF message.

<<<<<< clipped from your CLF message of 11/21 >>>

Those of you interested in the future Intel Fortran compilers should be
following the user community message boards referenced at the bottom of my
signature. There are two, one for the Intel Fortran Compiler for Windows
and CVF, and one for Intel Fortran Compiler for Linux. There's already some
discussion there. I will be able to offer some more details in early
November, and that's where I'll do it.
0 Kudos
Steven_L_Intel1
Employee
719 Views
Ah - I didn't say schedule details, did I? What I was referring to was my IDF presentation, which is now posted.

Steve
0 Kudos
Reply