aboutsummaryrefslogtreecommitdiff
path: root/gdb/jit.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2023-03-13 09:31:13 -0600
committerTom Tromey <tom@tromey.com>2023-03-18 11:12:37 -0600
commit95751990e40d88986205ba3c0719b8afd3da0e7e (patch)
treec86d95b731283e22d64c857817a060a089f33b93 /gdb/jit.c
parent8a17bdd9ccc26a7a0a2a208a9b870512b2490324 (diff)
downloadgdb-95751990e40d88986205ba3c0719b8afd3da0e7e.zip
gdb-95751990e40d88986205ba3c0719b8afd3da0e7e.tar.gz
gdb-95751990e40d88986205ba3c0719b8afd3da0e7e.tar.bz2
Reuse existing builtin types
This changes a few spots to reuse the existing builting "void" type, rather than construct a new one. Reviewed-By: Simon Marchi <simon.marchi@efficios.com>
Diffstat (limited to 'gdb/jit.c')
-rw-r--r--gdb/jit.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/gdb/jit.c b/gdb/jit.c
index 52b6574..e276b34 100644
--- a/gdb/jit.c
+++ b/gdb/jit.c
@@ -571,10 +571,7 @@ finalize_symtab (struct gdb_symtab *stab, struct objfile *objfile)
{
struct block *new_block = new (&objfile->objfile_obstack) block;
struct symbol *block_name = new (&objfile->objfile_obstack) symbol;
- struct type *block_type = arch_type (objfile->arch (),
- TYPE_CODE_VOID,
- TARGET_CHAR_BIT,
- "void");
+ struct type *block_type = builtin_type (objfile->arch ())->builtin_void;
new_block->set_multidict
(mdict_create_linear (&objfile->objfile_obstack, NULL));