if (PyObject_HasAttr (object, attr))
{
- gdbpy_ref ds_obj (PyObject_GetAttr (object, attr));
+ gdbpy_ref<> ds_obj (PyObject_GetAttr (object, attr));
if (ds_obj != NULL && gdbpy_is_string (ds_obj.get ()))
{
call_doc_function (PyObject *obj, PyObject *method, PyObject *arg)
{
gdb::unique_xmalloc_ptr<char> data;
- gdbpy_ref result (PyObject_CallMethodObjArgs (obj, method, arg, NULL));
+ gdbpy_ref<> result (PyObject_CallMethodObjArgs (obj, method, arg, NULL));
if (result == NULL)
return NULL;
gdb::unique_xmalloc_ptr<char> set_doc_string;
gdbpy_enter enter_py (get_current_arch (), current_language);
- gdbpy_ref set_doc_func (PyString_FromString ("get_set_string"));
+ gdbpy_ref<> set_doc_func (PyString_FromString ("get_set_string"));
if (set_doc_func == NULL)
{
gdb::unique_xmalloc_ptr<char> show_doc_string;
gdbpy_enter enter_py (get_current_arch (), current_language);
- gdbpy_ref show_doc_func (PyString_FromString ("get_show_string"));
+ gdbpy_ref<> show_doc_func (PyString_FromString ("get_show_string"));
if (show_doc_func == NULL)
{
if (PyObject_HasAttr (obj, show_doc_func.get ()))
{
- gdbpy_ref val_obj (PyString_FromString (value));
+ gdbpy_ref<> val_obj (PyString_FromString (value));
if (val_obj == NULL)
{
for (i = 0; i < size; ++i)
{
- gdbpy_ref item (PySequence_GetItem (enum_values, i));
+ gdbpy_ref<> item (PySequence_GetItem (enum_values, i));
if (item == NULL)
{