diff options
author | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-03-13 04:43:33 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-03-13 04:43:33 +0000 |
commit | f4390da0c537d637e6aa582f68c65bac13396196 (patch) | |
tree | 7fc3215fb12fb17da8347ab761ef8c7cebfafc36 /gcc/fortran/trans-decl.c | |
parent | 50e021a590c75eae2ad86d3874b29eedf63b9646 (diff) | |
download | gcc-f4390da0c537d637e6aa582f68c65bac13396196.zip gcc-f4390da0c537d637e6aa582f68c65bac13396196.tar.gz gcc-f4390da0c537d637e6aa582f68c65bac13396196.tar.bz2 |
compiler: add new debugging helper function debug_go_type()
Add a new debugging utility routine debug_go_type(), intended to
display the contents of a Type object in a way useful to debugging
a run of the compiler. Prior to this the only useful alternative
for debugging types was invoking the mangled_name() method, which
has problems (for example, won't work on interface types prior
to finalizing of methods).
This is a "deep" dump, meaning that all types reachable from the
type passed to debug_go_type() will be printed out. Example:
(gdb) print debug_go_type(t1)
T0 0x535f300 'net/http.Header' -> T1
T1 0x535d3d0 map ['string' -> string] T4
T2 0x5304bb0 'string' -> string
T3 0x331f900 string
T4 0x535d370 array [] 'string' -> string
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/166637
From-SVN: r269633
Diffstat (limited to 'gcc/fortran/trans-decl.c')
0 files changed, 0 insertions, 0 deletions