Implement 'trace' subcommand

Allows a user to execute `dlv trace [regexp]` and Delve will execute the
program and output information on functions matching [regexp].
This commit is contained in:
Derek Parker
2015-07-12 15:18:14 -05:00
parent c6ca18ff07
commit 3cee10d8bc
8 changed files with 117 additions and 11 deletions

View File

@ -272,6 +272,10 @@ func (d *Debugger) collectBreakpointInformation(state *api.DebuggerState) error
}
bpi.Variables[i] = api.ConvertVar(v)
}
vars, err := d.FunctionArguments(d.process.CurrentThread.Id)
if err == nil {
bpi.Arguments = vars
}
return nil
}
@ -370,7 +374,7 @@ func (d *Debugger) FunctionArguments(threadID int) ([]api.Variable, error) {
for _, v := range pv {
vars = append(vars, api.ConvertVar(v))
}
return vars, err
return vars, nil
}
func (d *Debugger) EvalVariableInThread(threadID int, symbol string) (*api.Variable, error) {