* PyBytes_AS_STRING -> PyBytes_AsString
* PyBytes_GET_SIZE -> PyBytes_Size
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=23830
Approved-By: Tom Tromey <tom@tromey.com>
long length;
struct type *type;
- output = PyBytes_AS_STRING (string.get ());
- length = PyBytes_GET_SIZE (string.get ());
+ output = PyBytes_AsString (string.get ());
+ gdb_assert (output != nullptr);
+ length = PyBytes_Size (string.get ());
type = builtin_type (gdbarch)->builtin_char;
if (hint && !strcmp (hint, "string"))