mirror of
https://github.com/go-delve/delve.git
synced 2025-10-29 01:27:16 +08:00
proc: fix findCompileUnitForOffset when plugins are used
Splits the compileUnits slice between images so that we can search for an offset inside the debug info of a specific image file.
This commit is contained in:
@ -588,7 +588,7 @@ func newVariable(name string, addr uintptr, dwarfType godwarf.Type, bi *BinaryIn
|
||||
// b. anonymous struct types (they contain the '{' character)
|
||||
// c. Go internal struct types used to describe maps (they contain the '<'
|
||||
// character).
|
||||
cu := bi.findCompileUnitForOffset(dwarfType.Common().Offset)
|
||||
cu := bi.Images[dwarfType.Common().Index].findCompileUnitForOffset(dwarfType.Common().Offset)
|
||||
if cu != nil && cu.isgo {
|
||||
dwarfType = &godwarf.TypedefType{
|
||||
CommonType: *(dwarfType.Common()),
|
||||
|
||||
Reference in New Issue
Block a user