[ ECLiPSe Compiler Directive.|Group Index|
Full Index]
pragma(Option)
Enable or disable compiler options. Can only be used as a directive in
source files.
- +Option
- An atom.
Description
The pragma/1 directive allows to control various compiler options. The
effect of a pragma is local to a source file (unlike nodbgcomp/0).
Settings are in effect until the next pragma that overrides it or until
the end of the file.
Option Effect
---------------------------------------------------------------
debug debuggable code, no inline compilation
nodebug non-debuggable code, inline compilation done
skip set the skipped flag for all compiled predicates
noskip don't (default)
expand do inline compilation
noexpand don't
system set the type of all compiled predicates to built_in
The default for debug/nodebug and expand/noexpand depends on the global
flag debug_compile.
Fail Conditions
None.
Resatisfiable
No.
Exceptions
- (148)
- An unknown Option was given.
Examples
:- pragma(debug).
:- pragma(expand).
twice(X, Y) :- % this is compiled into debuggable
Y is 2*X. % code with expanded arithmetic
See Also
compile / 1, dbgcomp / 0, env / 0, get_flag / 2, get_flag / 3, nodbgcomp / 0, pred / 1, set_flag / 3, set_flag / 2, skipped / 1, unskipped / 1