diff options
Diffstat (limited to 'gdb/gdbarch.c')
-rw-r--r-- | gdb/gdbarch.c | 22 |
1 files changed, 3 insertions, 19 deletions
diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c index 6d1bb0d..21ee840 100644 --- a/gdb/gdbarch.c +++ b/gdb/gdbarch.c @@ -5208,20 +5208,6 @@ alloc_gdbarch_data (struct gdbarch *gdbarch) gdbarch->data = GDBARCH_OBSTACK_CALLOC (gdbarch, gdbarch->nr_data, void *); } -/* Initialize the current value of the specified per-architecture - data-pointer. */ - -void -deprecated_set_gdbarch_data (struct gdbarch *gdbarch, - struct gdbarch_data *data, - void *pointer) -{ - gdb_assert (data->index < gdbarch->nr_data); - gdb_assert (gdbarch->data[data->index] == NULL); - gdb_assert (data->pre_init == NULL); - gdbarch->data[data->index] = pointer; -} - /* Return the current value of the specified per-architecture data-pointer. */ @@ -5251,11 +5237,9 @@ gdbarch_data (struct gdbarch *gdbarch, struct gdbarch_data *data) data->init_p = 1; } else - /* The architecture initialization hasn't completed - punt - - hope that the caller knows what they are doing. Once - deprecated_set_gdbarch_data has been initialized, this can be - changed to an internal error. */ - return NULL; + internal_error (__FILE__, __LINE__, + _("gdbarch post-init data field can only be used " + "after gdbarch is fully initialised")); gdb_assert (gdbarch->data[data->index] != NULL); } return gdbarch->data[data->index]; |