[ Obsolete | The ECLiPSe Built-In Predicates | Reference Manual | Alphabetic Index ]

nodbgcomp

Tells the compiler to generate code without debug instructions and not to retain the source variable names.

This built-in predicate is obsolete!

Description

Only predicates that have been compiled with debug instructions can be traced by the debugger. The generation of debug instruction is switched on by default, and can be switched off globally using nodbgcomp/0 or set_flag(debug_compile, off). This can be reversed using dbgcomp/0 or set_flag(debug_compile, on). This global setting can always be overruled on a file-by-file basis using pragma(debug) and pragma(nodebug) respectively.

Internals of predicates that have been compiled without debug instructions cannot be traced by the debugger (only entering and leaving such a predicate can be shown). On the other hand, this code uses less space and runs slightly faster than code with debug instructions. So it makes sense to compile well-tested predicates without debug instructions. Note however that predicates with debug instructions that are called by predicates without debug instructions are also invisible to the debugger.

Calling nodbgcomp/0 is equivalent to set_flag(debug_compile, off), set_flag(variable_names, off).

Modes and Determinism

Examples

Success:
      [eclipse]: nodbgcomp, [user], dbgcomp, [user].
       q :- writeln(hi).
       user compiled 36 bytes in 0.00 seconds
       p :- q.
       user compiled 32 bytes in 0.00 seconds
      yes.
      [eclipse]: trace.
      Debugger switched on - creep mode
      yes.
      [eclipse]: p.
        (1) 0  CALL   p (dbg)?- creep
      N (2) 1  CALL   q (dbg)?- creep
      hi
      N (2) 1  EXIT   q (dbg)?- creep     % call to writeln/1
        (1) 0  EXIT   p (dbg)?- creep     % invisible to the
      yes.                                % debugger.



See Also

pragma / 1, dbgcomp / 0, get_flag / 2, set_flag / 2, pragma / 1