]> Cypherpunks repositories - gostls13.git/commit
cmd/link: export specialized variants of runtime._type to debug_info
authorAlessandro Arzilli <alessandro.arzilli@gmail.com>
Sat, 18 Mar 2017 14:09:40 +0000 (15:09 +0100)
committerIan Lance Taylor <iant@golang.org>
Wed, 12 Apr 2017 13:25:45 +0000 (13:25 +0000)
commit073247f11fa0202e916820aa71044dcca11f4c7c
tree55bf51dc8ad1f9f8e4bcb6af26a9ee09f95eefc4
parente49627d355820684527ea7e50522087e1234fa16
cmd/link: export specialized variants of runtime._type to debug_info

The reflect package can be used to create new types at runtime, these
types will have runtime._type entries describing them but no entry in
debug_info (obviously).

A debugger that wanted to print the value of variables with such types
will have to read the runtime._type directly, however the
"specializations" of runtime._type (runtime.slicetype, runtime.maptype,
etc) are not exported to debug_info, besides runtime.interfacetype.

All those types (i.e. runtime.slicetype, runtime.maptype, etc) should
be exported to debug_info so that debuggers don't have to hard-code
their description.

Fixes #19602

Change-Id: I086d523a4421a4ed964e16bc3c2274319a98b45b
Reviewed-on: https://go-review.googlesource.com/38350
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
src/cmd/link/internal/ld/dwarf.go
src/cmd/link/internal/ld/dwarf_test.go [new file with mode: 0644]