Any one can help me,
I define a module to contain a list of functions. These function has one
arguments f_x which should be a function
MODULE MY_UTILITIES
IMPLICIT NONE
CONTAINS
REAL FUNCTION FooFunc1(f_x, a, b)
...
FooFunc1 = f_x(a-b)
END FUNCTION
REAL FUNCTION FooFunc2 (f_x, a, b)
...
FooFunc2 = FooFunc1 (f_x, a, b) ! error at this point
END FUNCTION
END MODULES
PROGRAM MY_PROGRAM
USE MY_UTILITIES
EXTERNAL G_X
REAL :: a, b
INTEGER :: errCode
...
errCode = FooFunc1(G_X, a,b)
END PROGRAM MY_PROGRAM
REAL FUNCTION G_X (...)
END FUNCTION
Ignoring other details of the functions. Eventhough I don't call the
FooFunc2 function inside main program, when I compile the program, an error
is popped up:
error 327 - In the INTERFACE to FooFunc1, the first dummy argument
(F_X) was of type REAL(KIND=1) FUNCTION, whereas the actual argument is of
type REAL(KIND=1)
NOTE: I use SilverFrost Plato IDE (Fortran 95 compiler).
Tuan.
George Mason Univ.
|