aboutsummaryrefslogtreecommitdiff
path: root/gdb/symtab.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2013-03-20 18:35:22 +0000
committerTom Tromey <tromey@redhat.com>2013-03-20 18:35:22 +0000
commit24d6c2a0bb797940d1f6f16ce8be8c80b1eab4db (patch)
tree42cd80a9c77a045aac4d4682a264effba7e5a358 /gdb/symtab.c
parentf1e6e0721c5115e2e6c60359c9afbdfe927f0431 (diff)
downloadgdb-24d6c2a0bb797940d1f6f16ce8be8c80b1eab4db.zip
gdb-24d6c2a0bb797940d1f6f16ce8be8c80b1eab4db.tar.gz
gdb-24d6c2a0bb797940d1f6f16ce8be8c80b1eab4db.tar.bz2
* ax-gdb.c (gen_var_ref): Unconditionally call via computed ops,
if possible. * dwarf2read.c (read_func_scope): Remove old FIXME. * eval.c (evaluate_subexp_standard): Check SYMBOL_COMPUTED_OPS, not LOC_COMPUTED. * findvar.c (symbol_read_needs_frame, default_read_var_value): Unconditionally call via computed ops, if possible. * printcmd.c (address_info): Unconditionally call via computed ops, if possible. * stack.c (read_frame_arg): Unconditionally call via computed ops, if possible. * symtab.c (register_symbol_computed_impl): Sanity check 'ops'. * tracepoint.c (scope_info): Unconditionally call via computed ops, if possible.
Diffstat (limited to 'gdb/symtab.c')
-rw-r--r--gdb/symtab.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/gdb/symtab.c b/gdb/symtab.c
index a46cdb8..51e920e 100644
--- a/gdb/symtab.c
+++ b/gdb/symtab.c
@@ -5053,6 +5053,13 @@ register_symbol_computed_impl (enum address_class aclass,
symbol_impl[result].aclass = aclass;
symbol_impl[result].ops_computed = ops;
+ /* Sanity check OPS. */
+ gdb_assert (ops != NULL);
+ gdb_assert (ops->tracepoint_var_ref != NULL);
+ gdb_assert (ops->describe_location != NULL);
+ gdb_assert (ops->read_needs_frame != NULL);
+ gdb_assert (ops->read_variable != NULL);
+
return result;
}