Design Issues for Subprograms
What parameter-passing method or methods are used?
Are the types of the actual parameters checked against the types of the formal parameters?
Are local variables statically or dynamically allocated?
Can subprograms be passed as parameters?
Are types of parameters checked in calls to passed subprograms.
e.g.
TEST_FUN(A, B(SUM), C)
Should SUM be type checking?
How much “overhead” takes?
What is referencing environment?
Can subprogram definitions appear in other subprogram definition?
Can subprograms be overloaded?
Overloaded subprogram has the same name as another
subprogram in the same referencing environment.
Can subprograms be generic?
Generic subprogram’s computation can be done on data
of different types with different calls.
Should subprograms be separately or independently compiled? (Compilation)