[PATCH 0/5] Handle pointers and references correctly in DAP

Tom Tromey tromey@adacore.com
Tue Sep 5 19:47:00 GMT 2023


This series started off as a simple implementation of a no-op
pretty-printer to handle pointers and references in DAP.

However, this regressed a test, and I realized that the new
is-array-like and is-string-like code should be generalized to work
with any language.

This is done by associating a language with each type, which meant
touching every debug reader, plus a few minor preliminary cleanups.

Regression tested on x86-64 Fedora 36.

---
Tom Tromey (5):
      Pass a type allocator to init_fixed_point_type
      Regularize some DWARF type initialization
      Add is_array_like and to_array to language_defn
      Give a language to a type
      Handle pointers and references correctly in DAP

 gdb/ada-lang.c                   |  13 +++++
 gdb/coffread.c                   |   4 +-
 gdb/ctfread.c                    |  17 ++++---
 gdb/dwarf2/read.c                |  89 +++++++++++++++++----------------
 gdb/gdbtypes.c                   |  31 ++++++------
 gdb/gdbtypes.h                   |  37 ++++++++------
 gdb/language.h                   |  11 +++++
 gdb/mdebugread.c                 |   9 ++--
 gdb/python/lib/gdb/printing.py   |  16 ++++++
 gdb/python/py-type.c             |  13 ++---
 gdb/rust-lang.h                  |  10 ++++
 gdb/stabsread.c                  |  20 ++++----
 gdb/testsuite/gdb.dap/ptrref.cc  |  34 +++++++++++++
 gdb/testsuite/gdb.dap/ptrref.exp | 103 +++++++++++++++++++++++++++++++++++++++
 gdb/valarith.c                   |   6 +--
 15 files changed, 303 insertions(+), 110 deletions(-)
---
base-commit: a006bc9c37e95b4afaf85715cc54fe57b3300ccd
change-id: 20230905-dap-30821-pointers-6b62c5cb8a9f

Best regards,
-- 
Tom Tromey <tromey@adacore.com>



More information about the Gdb-patches mailing list