aboutsummaryrefslogtreecommitdiff
path: root/gdb/python/py-block.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@efficios.com>2023-05-18 15:05:56 -0400
committerSimon Marchi <simon.marchi@efficios.com>2023-05-24 14:53:53 -0400
commit175ee55a229d9a02ae702f8818e2e022faae3132 (patch)
treebd8c484fc43fbaff56dbf971530fc86cf866962c /gdb/python/py-block.c
parentcbd9efbbc0414b71d47020958b5fbeff25504f15 (diff)
downloadbinutils-175ee55a229d9a02ae702f8818e2e022faae3132.zip
binutils-175ee55a229d9a02ae702f8818e2e022faae3132.tar.gz
binutils-175ee55a229d9a02ae702f8818e2e022faae3132.tar.bz2
gdbsupport: add support for references to checked_static_cast
Add a checked_static_cast overload that works with references. A bad dynamic cast with references throws std::bad_cast, it would be possible to implement the new overload based on that, but it seemed simpler to just piggy back off the existing function. I found some potential uses of this new overload in amd-dbgapi-target.c, update them to illustrate the use of the new overload. To build amd-dbgapi-target.c, on needs the amd-dbgapi library, which I don't expect many people to have. But I have it, and it builds fine here. I did test the new overload by making a purposely bad cast and it did catch it. Change-Id: Id6b6a7db09fe3b4aa43cddb60575ff5f46761e96 Reviewed-By: Lancelot SIX <lsix@lancelotsix.com> Reviewed-By: Andrew Burgess <aburgess@redhat.com>
Diffstat (limited to 'gdb/python/py-block.c')
0 files changed, 0 insertions, 0 deletions