New doc system done for core
[io.git] / libs / iovm / io / Debugger.io
blob1f89f858e9940631c3836004845881be18996be7
1 Debugger do(
2 /*doc Debugger description
3 To start debugging a coroutine, call
4 <pre>
5 Coroutine currentCoroutine setMessageDebugging(true)
6 </pre>
7 Then each message sent within that coroutine will cause the Debugger
8 vmWillSendMessage slot to be activated and the Debugger slots:
9 messageCoroutine, messageSelf, messageLocals, and message will be set with the
10 values related to the current message send. You can override vmWillSendMessage to
11 implement your own debugging mechanisms.
14 //doc Debugger start Starts the debugger.")
15 start := method(
16 loop(
17 self vmWillSendMessage(self message name)
18 messageCoroutine resume
22 //doc Debugger vmWillSendMessage Override this method to implement your own debugging mechanisms. Default behavior is to print every message sent.")
23 vmWillSendMessage := method(
24 writeln("Debugger vmWillSendMessage(", self message name, ")")
27 //doc Debugger debuggerCoroutine Returns the coroutine used for the debugger.")
28 debuggerCoroutine := coroFor(start)
29 yield