- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
On the following list of a program, the compiler gave me a warning message:
Testquot.f90(6) : Warning: Invalid use of & in quoted string.
Why?
The attached testQuot.f90 would get the same warning for Tests 5 to 13, beside Test 3.
Wen
program testQuot
write(*,"('Test1')")
write(*,"('Test2')" &
&)
write(*,"('Test3') &
&" &
&)
write(*,"('Test4') &
&")
end program testQuot
Wen
Testquot.f90(6) : Warning: Invalid use of & in quoted string.
Why?
The attached testQuot.f90 would get the same warning for Tests 5 to 13, beside Test 3.
Wen
program testQuot
write(*,"('Test1')")
write(*,"('Test2')" &
&)
write(*,"('Test3') &
&" &
&)
write(*,"('Test4') &
&")
end program testQuot
Wen
Link Copied
7 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
At first glance, it would seem to be a bug. I'll pass this on to the developers.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I think this problem was accidentally inserted with IFC 9.1.024 and is now solved for compiler version 9.1.025, at least for me your posted code compiles successfully. What IFC version are you using?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Now that I try it, I agree - it compiles ok in 9.1.025.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I did use 9.1.024 because I was lazy to do the minor upgrade.
However, I just upgraded the compiler to 9.1.025, build 20060519Z, and it still gave me the same warning message when I use my procedure in compilation. Further tests reveal that it is fine if I use
ifort testquot.f90
but the warning messages appear when I run
ifort testquot.f90 /fpp
Wen
However, I just upgraded the compiler to 9.1.025, build 20060519Z, and it still gave me the same warning message when I use my procedure in compilation. Further tests reveal that it is fine if I use
ifort testquot.f90
but the warning messages appear when I run
ifort testquot.f90 /fpp
Wen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok, I see that too, and will notify the developers. Is this a real program or just a torture test for compilers you devised?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
By the way, I note that the program compiles and runs successfully, despite the warnings.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Steve,
The symptom appeared in one of my application programs and made me wrote a simplified code to see how it happened.
Yes, it is just an annoying warning without affecting the program run. And I could easily change the code to avoid such a warning.
Thank you.
Wen
The symptom appeared in one of my application programs and made me wrote a simplified code to see how it happened.
Yes, it is just an annoying warning without affecting the program run. And I could easily change the code to avoid such a warning.
Thank you.
Wen

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