aboutsummaryrefslogtreecommitdiff
path: root/gdb/python
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2012-12-14 17:47:40 +0000
committerTom Tromey <tromey@redhat.com>2012-12-14 17:47:40 +0000
commit1993b71979c5e9cb66b067abfcb003b5d5cdab03 (patch)
treec8b48b6de6e818a6875b2765e1f0e0c9b0391f86 /gdb/python
parent2dc3df72a7ffca9a893ae41db8c3788c0019d59c (diff)
downloadgdb-1993b71979c5e9cb66b067abfcb003b5d5cdab03.zip
gdb-1993b71979c5e9cb66b067abfcb003b5d5cdab03.tar.gz
gdb-1993b71979c5e9cb66b067abfcb003b5d5cdab03.tar.bz2
* c-exp.y (block, variable, name_not_typename, lex_one_token,
classify_name): Update. * c-valprint.c (c_val_print): Update. * f-exp.y (yylex): Update. * go-exp.y (package_name_p, classify_packaged_name) (classify_name): Update. * jv-exp.y (push_variable): Update. * m2-exp.y (variable): Update. * mi/mi-cmd-stack.c (list_args_or_locals): Update. * p-exp.y (block, variable, yylex): Update. * p-valprint.c (pascal_val_print): Update. * parse.c (write_dollar_variable): Update. * printcmd.c (address_info): Update. * python/py-symbol.c (gdbpy_lookup_symbol): Update. * symtab.c (lookup_symbol_aux, lookup_symbol_in_language) (lookup_symbol): Change type of 'is_a_field_of_this'. (check_field): Add 'is_a_field_of_this' argument. * symtab.h (struct field_of_this_result): New. (lookup_symbol, lookup_symbol_in_language): Update.
Diffstat (limited to 'gdb/python')
-rw-r--r--gdb/python/py-symbol.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gdb/python/py-symbol.c b/gdb/python/py-symbol.c
index 5cfd3ab..4f7ebee 100644
--- a/gdb/python/py-symbol.c
+++ b/gdb/python/py-symbol.c
@@ -354,7 +354,8 @@ sympy_dealloc (PyObject *obj)
PyObject *
gdbpy_lookup_symbol (PyObject *self, PyObject *args, PyObject *kw)
{
- int domain = VAR_DOMAIN, is_a_field_of_this = 0;
+ int domain = VAR_DOMAIN;
+ struct field_of_this_result is_a_field_of_this;
const char *name;
static char *keywords[] = { "name", "block", "domain", NULL };
struct symbol *symbol = NULL;
@@ -407,7 +408,7 @@ gdbpy_lookup_symbol (PyObject *self, PyObject *args, PyObject *kw)
}
PyTuple_SET_ITEM (ret_tuple, 0, sym_obj);
- bool_obj = is_a_field_of_this? Py_True : Py_False;
+ bool_obj = (is_a_field_of_this.type != NULL) ? Py_True : Py_False;
Py_INCREF (bool_obj);
PyTuple_SET_ITEM (ret_tuple, 1, bool_obj);