(j3.2006) a question on allowing internal procedures as procedure targets
Jim Xia
jimxia at ca.ibm.com
Mon Nov 3 14:24:20 EST 2008
Is the following declaration legal?
function externFn ()
interface
integer function proc ()
end function
end interface
procedure(proc), pointer :: externFn
integer i
read *, i
externFn => f
contains
integer function f ()
f = i
end function
end function
If it is legal, how would the value of i be defined. Consider the
following user code
procedure(proc), pointer :: func
func => externFn()
print *, func() !<-- what would this function return
If the declaration is illegal, can anyone point out where the standard
states so.
Thanks
Jim Xia
RL Fortran Compiler Test
IBM Toronto Lab at 8200 Warden Ave, Markham, On, L6G 1C7
Phone (905) 413-3444 Tie-line 313-3444
email: jimxia at ca.ibm.com
D2/YF7/8200 /MKM
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://j3-fortran.org/pipermail/j3/attachments/20081103/f1c7e083/attachment-0001.html
More information about the J3
mailing list