proc/*: minor miscellaneous code cleanups (#2790)

* made Pid a method of Target instead of a method of Process
* changed argument of NewTarget to ProcessInternal, since that's the
  interface that backends have to implement
* removed warnings about ProcessInternal since there is no way for
  users of pkg/proc to access those methods anyway
* made RecordingManipulation an optional interface for backends, Target
  supplies its own dummy implementation when the backend doesn't
* inlined small interfaces that only existed to be inlined in
  proc.Process anyway
* removed unused function findExecutable in the Windows and no-native
  darwin backends
* removed (*EvalScope).EvalVariable, an old synonym for EvalExpression
This commit is contained in:
Alessandro Arzilli
2021-11-26 17:06:23 +01:00
committed by GitHub
parent 88dca53e5c
commit 01b01423ae
18 changed files with 124 additions and 141 deletions

View File

@ -435,7 +435,7 @@ func (dbp *nativeProcess) resume() error {
// stop stops all running threads and sets breakpoints
func (dbp *nativeProcess) stop(trapthread *nativeThread) (*nativeThread, error) {
if dbp.exited {
return nil, proc.ErrProcessExited{Pid: dbp.Pid()}
return nil, proc.ErrProcessExited{Pid: dbp.pid}
}
for _, th := range dbp.threads {
if !th.Stopped() {