This is the mail archive of the
archer@sourceware.org
mailing list for the Archer project.
[python] register gdb.Field
- From: Tom Tromey <tromey at redhat dot com>
- To: Project Archer <archer at sourceware dot org>
- Date: Tue, 09 Dec 2008 12:34:58 -0700
- Subject: [python] register gdb.Field
- Reply-to: Tom Tromey <tromey at redhat dot com>
The "field" class was never registered with the gdb module.
Tom
2008-12-09 Tom Tromey <tromey@redhat.com>
* python/python-type.c (gdbpy_initialize_types): Add Field to gdb
module.
diff --git a/gdb/python/python-type.c b/gdb/python/python-type.c
index 409a71d..b2d3654 100644
--- a/gdb/python/python-type.c
+++ b/gdb/python/python-type.c
@@ -642,6 +642,9 @@ gdbpy_initialize_types (void)
Py_INCREF (&type_object_type);
PyModule_AddObject (gdb_module, "Type", (PyObject *) &type_object_type);
+
+ Py_INCREF (&field_object_type);
+ PyModule_AddObject (gdb_module, "Field", (PyObject *) &field_object_type);
}