mirror of
https://github.com/go-delve/delve.git
synced 2025-10-29 01:27:16 +08:00
service/dap: add throw reason to exception info (#2524)
We can get the throw reason by looking at the argument "s" in runtime.throw. This is not currently working in Go 1.16 or Go 1.17 (see golang/go#46425), but does work in Go 1.15 and Go 1.14
This commit is contained in:
@ -237,6 +237,12 @@ func (d *Debugger) checkGoVersion() error {
|
||||
return goversion.Compatible(producer)
|
||||
}
|
||||
|
||||
func (d *Debugger) TargetGoVersion() string {
|
||||
d.targetMutex.Lock()
|
||||
defer d.targetMutex.Unlock()
|
||||
return d.target.BinInfo().Producer()
|
||||
}
|
||||
|
||||
// Launch will start a process with the given args and working directory.
|
||||
func (d *Debugger) Launch(processArgs []string, wd string) (*proc.Target, error) {
|
||||
if err := verifyBinaryFormat(processArgs[0]); err != nil {
|
||||
|
||||
Reference in New Issue
Block a user