Contents | Prev | Next | Index
Variables of a procedure type T may assume as their value a procedure P. The formal parameter lists of P and T must match. P must not be a generic standard procedure, nor must it be type-bound procedure, nor must it be nested in another procedure. If the language extensions are enabled via a compiler switch or directive, a variable of a procedure type may also assume as its value the constant NIL, which can be set in an assignment and can be used in relational expressions for the equal or unequal operators. A procedure type declaration may be preceded by a Java modifier directive for this compiler.
The standard procedure type PROC is defined as follows:
TYPE PROC = PROCEDURE();
procedure_type ::= procedure formal_type_list ::= procedure procedure ::= modifier PROCEDURE modifier ::= java_modifiers ::= <empty> formal_type_list ::= ( ) ::= ( ) : qualident ::= ( ft_section_list ) ::= ( ft_section_list ) : qualident ft_section_list ::= ft_section_list , ft_section ::= ft_section ft_section ::= VAR formal_type ::= formal_type formal_type ::= qualident ::= open_array qualident open_array ::= open_array ARRAY OF ::= ARRAY OF |
Contents | Prev | Next | Index
Canterbury Modula-2 for Java (Last documentation update
Feb 8, 2000)
Copyright © 1998 Mill Hill &
Canterbury Corporation, Ltd. All rights reserved
Please send any comments or corrections to
mhc@webcom.com