View previous topic :: View next topic |
Author |
Message |
desmith
Joined: 15 Aug 2006 Posts: 1
|
Posted: Tue Aug 15, 2006 9:54 am Post subject: Variable Address |
|
|
I am porting an old program and one feature that was used was a pointer function. This function returned the segment:offset of any variable passed to it.
I have not been able to find anything similar using the current FTN95 compiler.
Can anyone help point (no pun here) me in the right direction.
Thanks,
Ed |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 7927 Location: Salford, UK
|
Posted: Tue Aug 15, 2006 12:59 pm Post subject: Variable Address |
|
|
Ed
You can use the Salford intrinsic LOC(var) to give the address of var. From this you can calculate the segment and offset. |
|
Back to top |
|
|
Anonymous Guest
|
Posted: Tue Aug 15, 2006 3:58 pm Post subject: Variable Address |
|
|
Paul,
Thanks. I was sure there was something but I was unable to find in the help files. Probably just read over it and not realized it.
I will give it a try.
Once again, thanks.
Ed |
|
Back to top |
|
|
|