aboutsummaryrefslogtreecommitdiff
path: root/gdb/xcoffread.c
diff options
context:
space:
mode:
authorJohn Gilmore <gnu@cygnus>1992-05-01 09:14:43 +0000
committerJohn Gilmore <gnu@cygnus>1992-05-01 09:14:43 +0000
commitea1549b346e7014425e5ce74943ca3e2f81097e2 (patch)
treeb03d8035ff9c150cd363107d52060705d592da33 /gdb/xcoffread.c
parent5bdf762bb8861ca302b47a491660479513e9edde (diff)
downloadgdb-ea1549b346e7014425e5ce74943ca3e2f81097e2.zip
gdb-ea1549b346e7014425e5ce74943ca3e2f81097e2.tar.gz
gdb-ea1549b346e7014425e5ce74943ca3e2f81097e2.tar.bz2
* gdbtypes.c (make_{reference,pointer,function}_type): New
functions which handle overwriting of forward-referenced types for stabs file reading. (lookup_{reference,pointer,function}_type): These just call the make_*_type functions with a null storage alloc parameter. * gdbtypes.h (make_{reference,pointer,function}_type): Declare. * xcoffread.c (smash_to_pointer_type): Remove, no longer used. * buildsym.c (dbx_lookup_type): Zero result for (-1,-1) arg. (dbx_alloc_type): Make it easier to understand. No funct change. (define_symbol: 't'): Don't put the typedef name into the name of the struct, union, or enum. Bugfix. (read_type: '*', '&', 'f'): Add comments. Use make_XXX_type routines to properly handle overwriting preallocated types so that forward references will work. (read_enum_type): Force enum values to file scope, due to bug in Sun compiler output. FIXME, fix later. Remove unused header_file_prev_index mechanism. It was already obsolete in gdb-3.5. These comments appeared in 3.5: /* This code was used before I knew about the instance codes. My first hypothesis is that it is not necessary now that instance codes are handled. */ * dbxread.c (add_new_header_file): Remove header_file_prev_index. * buildsym.h: Remove it and prev_index that saves it. * buildsym.c (push_subfile, pop_subfile, start_symtab): Remove it. * solib.c (special_symbol_handling): When called from core files, must set up debug_addr. Don't print error messages, just return. * symmisc.c (print_symbol): Less ascii diarrhea for enums, please.
Diffstat (limited to 'gdb/xcoffread.c')
-rw-r--r--gdb/xcoffread.c46
1 files changed, 0 insertions, 46 deletions
diff --git a/gdb/xcoffread.c b/gdb/xcoffread.c
index 3413255..addb5cf 100644
--- a/gdb/xcoffread.c
+++ b/gdb/xcoffread.c
@@ -2333,52 +2333,6 @@ _initialize_xcoffread ()
add_symtab_fns(&aixcoff_sym_fns);
}
-
-/* In order to handle forward type references, we needed to have this old
- routine. Try printing the type of member `p' in the following structure
- in a dbx environment.
-
- struct s {
- ...
- struct s *p;
- };
-*/
-
-
-/* Smash TYPE to be a type of pointers to TO_TYPE.
- If TO_TYPE is not permanent and has no pointer-type yet,
- record TYPE as its pointer-type. */
-
-void
-smash_to_pointer_type (type, to_type)
- struct type *type, *to_type;
-{
-/* int type_permanent = (TYPE_FLAGS (type) & TYPE_FLAG_PERM); */
-
- bzero (type, sizeof (struct type));
- TYPE_TARGET_TYPE (type) = to_type;
- /* We assume the machine has only one representation for pointers! */
- TYPE_LENGTH (type) = sizeof (char *);
- TYPE_CODE (type) = TYPE_CODE_PTR;
-
-/* ??? TYPE_TARGET_TYPE and TYPE_MAIN_VARIANT are the same. You can't do
- this. It will break the target type!!!
- TYPE_MAIN_VARIANT (type) = type;
-
- if (type_permanent)
- TYPE_FLAGS (type) |= TYPE_FLAG_PERM;
-*/
-
- if (TYPE_POINTER_TYPE (to_type) == 0)
-#if 0
- && (!(TYPE_FLAGS (to_type) & TYPE_FLAG_PERM)
- || type_permanent))
-#endif /* 0 */
- {
- TYPE_POINTER_TYPE (to_type) = type;
- }
-}
-
#else /* IBM6000_HOST */
struct type *
builtin_type (ignore)