[PATCH 15/16] gdb: make cmd_list_element var an optional union
Tom Tromey
tom@tromey.com
Thu Jul 29 17:49:13 GMT 2021
>>>>> "Simon" == Simon Marchi <simon.marchi@polymtl.ca> writes:
>> There are other implementations of this method that don't check, though,
>> and I don't understand why.
Simon> Indeed, I filed this with gcc and was (rightfully) corrected:
Simon> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101659
Simon> What other implementations are you referring to?
struct _Optional_payload_base has:
constexpr _Tp&
_M_get() noexcept
{ return this->_M_payload._M_value; }
I don't know why this one doesn't check, but I suppose given the
resolution of that bug, it's probably fine.
Tom
More information about the Gdb-patches
mailing list