Node:Include Declarations, Previous:Mode Declarations, Up:Declarations

Include Declarations

A declaration

:- include(Files).  ISO

where Files is a file name or a list of file names, instructs the processor to literally embed the Prolog clauses and directives in Files into the file being loaded. This means that the effect of the include directive is such as if the include directive itself was replaced by the text in the Files. Including some files is thus different from loading them in several respects:

SICStus Prolog uses the included file name (as opposed to the embedding file name) only in source-linked debugging and error reporting. Note that source-linked debugging information is not kept for included files compiled to .ql format; in such cases the debugger will show the include directive itself as the source information.