User Tools

Site Tools

Navigation:  Language Reference > 2 - Program Source Code Format > Program Format >====== MAP (declare PROCEDURE prototypes) ====== Previous pageReturn to chapter overviewNext page


MAP Contains the prototypes which declare the procedures and external source modules used in a PROGRAM, MEMBER module, or PROCEDURE.
prototypes Declare PROCEDUREs.
MODULE Declare a member source module that contains the definitions of the prototypes in the MODULE.

A MAP structure contains the prototypes which declare the PROCEDUREs and external source modules used in a PROGRAM, MEMBER module, or PROCEDURE which are not members of a CLASS structure.

A MAP declared in the PROGRAM source module declares prototypes of PROCEDUREs available for use throughout the program. A MAP in a MEMBER module declares prototypes of PROCEDUREs that are explicitly available in that MEMBER module. The same prototypes may be placed in multiple MEMBER modules to make them explicitly available in each. A MAP can also be included within a PROCEDURE declaration. All prototypes of PROCEDUREs declared in a local PROCEDURE MAP may only be referenced within the PROCEDURE itself.

A MAP structure is mandatory for any non-trivial Clarion program because the BUILTINS.CLW file is automatically included in your PROGRAM's MAP structure by the compiler. This file contains prototypes of most of the procedures in the Clarion internal library that are available as part of the Clarion language. This file is required because the compiler does not have these prototypes built into it (making it more efficient). Since the prototypes in the BUILTINS.CLW file use some constant EQUATEs that are defined in the EQUATES.CLW file, this file is also automatically included by the compiler in every Clarion program.


!One file contains:

PROGRAM              !Sample program in sample.cla

MAP                  !Begin map declaration

LoadIt PROCEDURE      !LoadIt procedure

END                  !End of map

!A separate file contains:

MEMBER('Sample')     !Declare MEMBER module

MAP                  !Begin MODULE local map declaration

ComputeIt PROCEDURE   ! compute it procedure

END                  !End of map



MAP                 ! PROCEDURE local map






Proc1 Procedure


 LOC:Var += 1


See Also:





PROCEDURE Prototypes

map_declare_procedure_prototypes_.htm.txt · Last modified: 2021/04/15 15:57 (external edit)