summaryrefslogtreecommitdiffstats
path: root/gdb/mipsread.c
diff options
context:
space:
mode:
authorJohn Gilmore <gnu@cygnus>1991-09-19 22:39:39 +0000
committerJohn Gilmore <gnu@cygnus>1991-09-19 22:39:39 +0000
commite5fa3486b1f6c07fe76f9473abcbcc35f994994f (patch)
tree7858a2a9f1d2424abb1eff6c661c52270dbf47b5 /gdb/mipsread.c
parentb1c86ef190810e341c32b12aeadeec0f55bfc732 (diff)
downloadppe42-binutils-e5fa3486b1f6c07fe76f9473abcbcc35f994994f.tar.gz
ppe42-binutils-e5fa3486b1f6c07fe76f9473abcbcc35f994994f.zip
* mipsread.c (_initialize_mipsread): Avoid using
builtin_type_void at initialize time. (mipscoff_symfile_read): use it now.
Diffstat (limited to 'gdb/mipsread.c')
-rw-r--r--gdb/mipsread.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/gdb/mipsread.c b/gdb/mipsread.c
index 371c92419d..7083d3dc9d 100644
--- a/gdb/mipsread.c
+++ b/gdb/mipsread.c
@@ -249,6 +249,9 @@ mipscoff_symfile_read(sf, addr, mainline)
int symtab_offset;
int stringtab_offset;
+ /* Initialize a variable that we couldn't do at _initialize_ time. */
+ builtin_type_ptr = lookup_pointer_type (builtin_type_void);
+
/* WARNING WILL ROBINSON! ACCESSING BFD-PRIVATE DATA HERE! FIXME! */
desc = fileno ((FILE *)(abfd->iostream)); /* Raw file descriptor */
/* End of warning */
@@ -2789,10 +2792,13 @@ _initialize_mipsread ()
0, "floating_decimal");
/* Templates types */
- builtin_type_ptr = lookup_pointer_type (builtin_type_void);
builtin_type_struct = make_type(TYPE_CODE_STRUCT, 0, 0, 0);
builtin_type_union = make_type(TYPE_CODE_UNION, 0, 0, 0);
builtin_type_enum = make_type(TYPE_CODE_ENUM, 0, 0, 0);
builtin_type_range = make_type(TYPE_CODE_RANGE, 0, 0, 0);
builtin_type_set = make_type(TYPE_CODE_SET, 0, 0, 0);
+
+ /* We can't do this now because builtin_type_void may not
+ be set yet. Do it at symbol reading time. */
+ /* builtin_type_ptr = lookup_pointer_type (builtin_type_void); */
}
OpenPOWER on IntegriCloud