Was this helpful?
INCLUDE--Include an External File
Valid in: EQUEL
Includes an external file in source code.
This statement has the following format:
## include [inlinefilename
The include statement provides a means to include external files in your program's source code (for example, variable declarations).
Filename must be a string constant that specifies the file to be included. If the file is a simple name (with an extension) it can be specified without quotes; however, if filename includes non-alphanumeric characters, the string constant must be quoted. Filename can be a system variable that specifies the location and name of the file to be included.
The file specified in an include statement can contain variable declarations and host code. Include files can contain include statements.
When the preprocessor encounters an include statement, it processes the include file and creates work files. Default filename extensions, both for the included file and work files, are host-language dependent. For more information, see the Embedded QUEL Companion Guide. The default extensions can be overridden with the -n and -o flags of the preprocessor command.
In addition to translating the include file, the preprocessor translates the ## include statement to the equivalent host language statement.
Include and include inline are processed differently. When the preprocessor encounters an include statement, it preprocesses the specified file separately, before including it. When the preprocessor encounters an include inline statement, it preprocesses the include file as if it were part of the original file. As a result, you can use include inline to complete partial statements.
Last modified date: 08/14/2024