[Next] [Previous] [Up] [Top]

3 Using the Cecil Debugger

3.6 Evaluating expressions

If you are debugging a program that includes the Cecil evaluator (such as any program compiled with the full standard library), then any input that is not recognized as a debugger command is evaluated in the context of the current active stack frame. For example, if x is a list of HandlerTaskRec, you could find all the tasks of priority >2000 that are currently elements of x by doing the following:

debug> x.do(&(y){ if (y.priority > 2000, { y.print_line; }); })

If the result of evaluation is non-void, then the print_string message is sent to the result to compute a user-defined printable representation of the result.

Section 4 discusses the evaluator in more detail.