202
Pascal 4.0 User’s Guide
8
Type
shortreal
You can return a
shortreal
function value between Pascal and FORTRAN.
Pass it exactly as in the previous example, with the Pascal
shortreal
type
matching the FORTRAN
real
type (without
-xl
).
Routines as Parameters
If the passed procedure is a top-level procedure, write it as follows:
The commands to compile and
execute
RetReal.f
and
RetRealmain.p
hostname% f77 -c RetReal.f
RetReal.f
retreal:
hostname% pc RetReal.o RetRealmain.p -lpfc -lF77
hostname% a.out
2.0 3.0
The FORTRAN subroutine,
PassProc.f
subroutine PassProc ( r, s, prcdr )
real r, s
external prcdr
call prcdr ( r, s )
return
end
Содержание SunSoft Pascal 4.0
Страница 14: ...xiv Pascal 4 0 User s Guide ...
Страница 16: ...xvi Pascal 4 0 User s Guide ...
Страница 30: ...6 Pascal 4 0 User s Guide 1 ...
Страница 160: ...136 Pascal 4 0 User s Guide 6 ...
Страница 268: ...244 Pascal 4 0 User s Guide 11 ...
Страница 320: ...296 Pascal 4 0 User s Guide B ...
Страница 331: ...Index 307 ...
Страница 333: ......