aboutsummaryrefslogtreecommitdiff
path: root/gdb/gdbtypes.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@adacore.com>2023-09-05 12:43:50 -0600
committerTom Tromey <tromey@adacore.com>2023-09-19 13:28:42 -0600
commitd559227272d72e554222361058163b9dc94de2f0 (patch)
treeeaa5cdab9bae387823ba7095460e42b010377234 /gdb/gdbtypes.c
parent8e032233a013cedc72c52b57a349c47522138594 (diff)
downloadgdb-d559227272d72e554222361058163b9dc94de2f0.zip
gdb-d559227272d72e554222361058163b9dc94de2f0.tar.gz
gdb-d559227272d72e554222361058163b9dc94de2f0.tar.bz2
Pass a type allocator to init_fixed_point_type
init_fixed_point_type currently takes an objfile and creates its own type allocator. However, for a later patch it is more convenient if this function accepts a type allocator. This patch makes this change.
Diffstat (limited to 'gdb/gdbtypes.c')
-rw-r--r--gdb/gdbtypes.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/gdbtypes.c b/gdb/gdbtypes.c
index c932210..667b4e3 100644
--- a/gdb/gdbtypes.c
+++ b/gdb/gdbtypes.c
@@ -3498,12 +3498,12 @@ init_pointer_type (type_allocator &alloc,
NAME is the type name. */
struct type *
-init_fixed_point_type (struct objfile *objfile,
+init_fixed_point_type (type_allocator &alloc,
int bit, int unsigned_p, const char *name)
{
struct type *t;
- t = type_allocator (objfile).new_type (TYPE_CODE_FIXED_POINT, bit, name);
+ t = alloc.new_type (TYPE_CODE_FIXED_POINT, bit, name);
if (unsigned_p)
t->set_is_unsigned (true);