[gdb/python] Eliminate GDB_PY_HANDLE_EXCEPTION

Result of:
...
$ search="GDB_PY_HANDLE_EXCEPTION ("
$ replace="return gdbpy_handle_gdb_exception (nullptr, "
$ sed -i \
    "s/$search/$replace/" \
    gdb/python/*.c
...

Also remove the now unused GDB_PY_HANDLE_EXCEPTION.

No functional changes.

Tested on x86_64-linux.

Approved-By: Tom Tromey <tom@tromey.com>
This commit is contained in:
Tom de Vries
2024-09-24 13:06:32 +02:00
parent 912bc231ab
commit 1ccb6f106a
23 changed files with 129 additions and 136 deletions

View File

@@ -443,7 +443,7 @@ bppy_delete_breakpoint (PyObject *self, PyObject *args)
}
catch (const gdb_exception &except)
{
GDB_PY_HANDLE_EXCEPTION (except);
return gdbpy_handle_gdb_exception (nullptr, except);
}
Py_RETURN_NONE;
@@ -640,7 +640,7 @@ bppy_get_commands (PyObject *self, void *closure)
}
catch (const gdb_exception &except)
{
GDB_PY_HANDLE_EXCEPTION (except);
return gdbpy_handle_gdb_exception (nullptr, except);
}
return host_string_to_python_string (stb.c_str ()).release ();