LEODebugger

Includes:

Introduction

These are hooks and utility functions for a little command-line debugger that can be used to analyze your bytecode while it is running.

To activate it, set your LEOContext's PreInstructionProc to LEODebuggerPreInstructionProc.



Functions

LEODebuggerAddBreakpoint
LEODebuggerPreInstructionProc
LEODebuggerRemoveBreakpoint

LEODebuggerAddBreakpoint


void LEODebuggerAddBreakpoint(
    LEOInstruction *targetInstruction,
    struct LEOScript *inScript );  
Discussion

Set a breakpoint on the given instruction. This will cause execution to be interrupted and a debugger console to be shown that allows examining the current stack.

See Also


LEODebuggerPreInstructionProc


void LEODebuggerPreInstructionProc(
    struct LEOContext *inContext );  
Discussion

Use this function as the PreInstructionProc of your LEOContext to activate the debugger.


LEODebuggerRemoveBreakpoint


void LEODebuggerRemoveBreakpoint(
    LEOInstruction *targetInstruction );  
Discussion

Remove a breakpoint set using LEODebuggerAddBreakpoint().

See Also