Crossware

Table of Contents        Previous topic       Next topic       

ASSEMBLER DIRECTIVES->Other Assembler Directives->INCLUDE Include Another Source Code File

The INCLUDE directive will cause the cross-assembler to read the subsequent source code statements from the file which is specified in the operand.  The file specification, which can be up to 256 characters in length, should include the directory path unless the file is in the current directory or in the directory specified by the LIB environment variable.

For Windows 95 and Windows NT, the file specification can include spaces.  It this case, the file specification must be enclosed in quotes.

When the end of the included file is reached, assembly continues at the statement following the INCLUDE directive.  

The assembler generated line numbers start from 1 in the included file and recommence at their previous value when assembly of the included file has been completed. The line numbers therefore directly correspond with the line numbers of the files.

Included files can be nested but cannot be included recursively since then the file would already be open and could not be opened again.

If the NAM and END directives are present in an included file, they will be ignored although on the second pass a warning will be given.