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

How to get the address of a FORTRAN variable in Visual Studio.net

peledrg
Beginner
1,061 Views
A FORTRAN COMMON variable is being overwritten in a "C" program. How do I get the address of the FORTRAN variable so that I can track it in the "C" program in order to find out what writes over it?
Thanks,
Rachel
0 Kudos
2 Replies
Steven_L_Intel1
Employee
1,061 Views
That's a good question. I thought I could find a way to do it, but I couldn't. All I can suggest is that you add a line such as:

print *, loc(variablename)

to get the address.
0 Kudos
peledrg
Beginner
1,061 Views
Steve,
Thank you so much. This print statement worked for me. I am all set.
Rachel.
0 Kudos
Reply