]> git.lizzy.rs Git - rust.git/commit
Resolve typedefs in HashMap gdb/lldb pretty-printers
authorortem <ortem00@gmail.com>
Fri, 20 Nov 2020 14:54:26 +0000 (17:54 +0300)
committerortem <ortem00@gmail.com>
Fri, 20 Nov 2020 14:54:57 +0000 (17:54 +0300)
commit905ed3bb6b1f1a8abb253192333bb3f5a08b61c8
tree322f26550bd716a21adcde069fe6259a43b42e70
parentae6aa22cf26fede2177abe4ff974030058885b7a
Resolve typedefs in HashMap gdb/lldb pretty-printers

`GetTypedefedType` (LLDB) and `strip_typedefs` (GDB) calls are needed to resolve key and value types completely.
Without these calls, debugger doesn't show the actual type.

* Before (without `GetTypedefedType`):
(lldb) frame variable hm[0]
(T) hm[0] = { ... }

* After (with `GetTypedefedType`):
(lldb) frame variable hm[0]
((i32, alloc::string::String)) hm[0] = { ... }
src/etc/gdb_providers.py
src/etc/lldb_providers.py