Single pump for both lua and mdb outputs
This commit is contained in:
15
debugger.lua
15
debugger.lua
@ -79,6 +79,16 @@ function debugger.on_state(state)
|
||||
debugger.state = state
|
||||
end
|
||||
|
||||
function debugger.on_break(file, line, reason)
|
||||
debugger.log(string.format("breakpoint hit: %s:%d", file, line))
|
||||
-- Temporary continue at unknown breaks
|
||||
if file=='?' and line==-1 then
|
||||
if debugger.debugrunner.caps.can_continue then
|
||||
debugger.debugrunner:continue()
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function debugger.run(target, name, r, view)
|
||||
if debugger.debugrunner then
|
||||
if debugger.state == "paused" then
|
||||
@ -101,10 +111,7 @@ function debugger.run(target, name, r, view)
|
||||
on_stderr = debugger.on_stderr,
|
||||
on_exit = debugger.on_exit,
|
||||
on_state = debugger.on_state,
|
||||
|
||||
on_break = function(file, line, reason)
|
||||
debugger.log(string.format("breakpoint hit: %s:%d", file, line))
|
||||
end,
|
||||
on_break = debugger.on_break,
|
||||
})
|
||||
-- And run
|
||||
debugger.debugrunner:run(target, name)
|
||||
|
||||
Reference in New Issue
Block a user