]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
Simplify C++ type-printing
authorTom Tromey <tromey@adacore.com>
Fri, 27 Oct 2023 16:58:00 +0000 (10:58 -0600)
committerTom Tromey <tromey@adacore.com>
Tue, 21 Nov 2023 21:52:05 +0000 (14:52 -0700)
commit3eac77a50024b49ee89436fa6f18c30ed64c3eeb
tree30639ba713680f73763b0dfee0449442c1a57847
parent5028c9e206efd6b92ecefe1afc9dcf5cd4ebb1a6
Simplify C++ type-printing

The C++ type-printing code had its own variant of the accessibility
enum.  This patch removes this and changes the code to use the new one
from gdbtypes.h.

This patch also changes the C++ code to recognize the default
accessibility of a class.  This makes ptype a bit more C++-like, and
lets us remove a chunk of questionable code.

Acked-By: Simon Marchi <simon.marchi@efficios.com>
Reviewed-by: Keith Seitz <keiths@redhat.com>
gdb/c-typeprint.c
gdb/testsuite/gdb.base/ptype-offsets.exp