summaryrefslogtreecommitdiff
path: root/plugins/pychrysalide/arch/operands/register.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/pychrysalide/arch/operands/register.c')
-rw-r--r--plugins/pychrysalide/arch/operands/register.c48
1 files changed, 5 insertions, 43 deletions
diff --git a/plugins/pychrysalide/arch/operands/register.c b/plugins/pychrysalide/arch/operands/register.c
index fcf838c..2a48a0f 100644
--- a/plugins/pychrysalide/arch/operands/register.c
+++ b/plugins/pychrysalide/arch/operands/register.c
@@ -67,9 +67,6 @@ static PyObject *py_register_operand__print(PyObject *, PyObject *);
/* Fournit le registre associé à l'opérande. */
static PyObject *py_register_operand_get_register(PyObject *, void *);
-/* Indique le type d'accès réalisé sur l'opérande. */
-static PyObject *py_register_operand_is_written(PyObject *, void *);
-
/* ---------------------------------------------------------------------------------- */
@@ -115,7 +112,7 @@ static PyObject *py_register_operand_new(PyTypeObject *type, PyObject *args, PyO
if (first_time)
{
- status = register_class_for_dynamic_pygobject(gtype, type, base);
+ status = register_class_for_dynamic_pygobject(gtype, type);
if (!status)
{
@@ -357,43 +354,6 @@ static PyObject *py_register_operand_get_register(PyObject *self, void *closure)
/******************************************************************************
* *
-* Paramètres : self = objet Python concerné par l'appel. *
-* closure = non utilisé ici. *
-* *
-* Description : Indique le type d'accès réalisé sur l'opérande. *
-* *
-* Retour : Type d'accès : True en cas d'écriture, False sinon. *
-* *
-* Remarques : - *
-* *
-******************************************************************************/
-
-static PyObject *py_register_operand_is_written(PyObject *self, void *closure)
-{
- PyObject *result; /* Résultat à retourner */
- GRegisterOperand *operand; /* Version GLib du type */
- bool status; /* Statut de la ligne */
-
-#define REGISTER_OPERAND_IS_WRITTEN_ATTRIB PYTHON_IS_DEF_FULL \
-( \
- written, py_register_operand, \
- "Kind of access for the register when its instruction is executed." \
-)
-
- operand = G_REGISTER_OPERAND(pygobject_get(self));
-
- status = g_register_operand_is_written(operand);
-
- result = status ? Py_True : Py_False;
- Py_INCREF(result);
-
- return result;
-
-}
-
-
-/******************************************************************************
-* *
* Paramètres : - *
* *
* Description : Fournit un accès à une définition de type à diffuser. *
@@ -414,7 +374,6 @@ PyTypeObject *get_python_register_operand_type(void)
static PyGetSetDef py_register_operand_getseters[] = {
REGISTER_OPERAND_REGISTER_ATTRIB,
- REGISTER_OPERAND_IS_WRITTEN_ATTRIB,
{ NULL }
};
@@ -468,7 +427,10 @@ bool ensure_python_register_operand_is_registered(void)
dict = PyModule_GetDict(module);
- if (!register_class_for_pygobject(dict, G_TYPE_REGISTER_OPERAND, type, get_python_arch_operand_type()))
+ if (!ensure_python_arch_operand_is_registered())
+ return false;
+
+ if (!register_class_for_pygobject(dict, G_TYPE_REGISTER_OPERAND, type))
return false;
}