Next: Modules - Procedure Encapsulation
Up: Modules
Previous: Modules Interface Declaration Example
Placing interfaces in modules for visibility purposes has the following
problems,
- procedures may be inter-related and hence call one
another;
- the procedure interfaces need to be explicit to one
another;
- using the module means that each procedure would contain its
own interface declaration which is an error.
SUBROUTINE Sub1(A,B,C)
USE my_interfaces ! contains Sub1 stuff
...
The solution to this is to package the actual procedures
in the module; the interfaces become visible and
the above problems are solved.
These are now called module procedures and are encapsulated
into the module.
For more information, click here
Next: Modules - Procedure Encapsulation
Up: Modules
Previous: Modules Interface Declaration Example
©University of Liverpool, 1997
Wed May 28 23:37:18 BST 1997Not for commercial use.