+Fri Mar 27 15:44:55 1992 John Gilmore (gnu at cygnus.com)
+
+ * buildsym.c (MAX_OF_C_TYPE, MIN_OF_C_TYPE): Unused, remove.
+ * copying.awk: Lint. Make stronger warning at top of copying.c.
+ * elfread.c (elf_symtab_read): Eliminate check of mainline.
+ * gdbtypes.c (smash_to_*): Remove FIXME comments.
+ (lookup_pointer_type): Add FIXME comment.
+ * main.c (set_history_size_command): Disallow negative size.
+ * partial-stab.h: Update copyright.
+ * rs6000-tdep.c (skip_trampoline_code): Better comments.
+
+Wed Mar 25 10:45:38 1992 John Gilmore (gnu at cygnus.com)
+
+ * main.c (set_history_size_command): Negative size is error.
+ (Reported by Peggy Fieland.)
+
Thu Mar 26 17:01:18 1992 Fred Fish (fnf@cygnus.com)
* coffread.c (coff_symfile_init): Update comment.
}
}
-#define MAX_OF_C_TYPE(t) ((1 << (sizeof (t)*8 - 1)) - 1)
-#define MIN_OF_C_TYPE(t) (-(1 << (sizeof (t)*8 - 1)))
-
static struct type *
read_range_type (pp, typenums, objfile)
char **pp;
/* Read ELF (Executable and Linking Format) object files for GDB.
- Copyright (C) 1991 Free Software Foundation, Inc.
+ Copyright 1991, 1992 Free Software Foundation, Inc.
Written by Fred Fish at Cygnus Support.
This file is part of GDB.
* *
* This file is still under construction. When it is complete, this *
* notice will be removed. Until then, direct any questions or changes *
- * to Fred Fish at Cygnus Support (fnf@cygint) *
+ * to Fred Fish at Cygnus Support (fnf@cygnus.com) *
* *
* FIXME Still needs support for shared libraries. *
* FIXME Still needs support for core files. *
&& (sym -> section != NULL))
{
symaddr = sym -> value;
- /* Relocate all non-absolute symbols by base address.
- FIXME: Can we eliminate the check for mainline now,
- since shouldn't addr be 0 in this case? */
- if (!mainline && (sym -> section != &bfd_abs_section))
+ /* Relocate all non-absolute symbols by base address. */
+ if (sym -> section != &bfd_abs_section)
{
symaddr += addr;
}
TYPE_TARGET_TYPE (ptype) = type;
TYPE_POINTER_TYPE (type) = ptype;
- /* We assume the machine has only one representation for pointers! */
+ /* FIXME, assume machine has only one representation for pointers! */
TYPE_LENGTH (ptype) = TARGET_PTR_BIT / TARGET_CHAR_BIT;
TYPE_CODE (ptype) = TYPE_CODE_PTR;
include the offset (that's the value of the MEMBER itself), but does
include the structure type into which it points (for some reason).
- FIXME: When "smashing" the type, we preserve the objfile that the
+ When "smashing" the type, we preserve the objfile that the
old type pointed to, since we aren't changing where the type is actually
- allocated. If the two types aren't associated with the same objfile,
- then we are in deep-s**t anyway... */
+ allocated. */
void
smash_to_member_type (type, domain, to_type)
/* Smash TYPE to be a type of method of DOMAIN with type TO_TYPE.
METHOD just means `function that gets an extra "this" argument'.
- FIXME: When "smashing" the type, we preserve the objfile that the
+ When "smashing" the type, we preserve the objfile that the
old type pointed to, since we aren't changing where the type is actually
- allocated. If the two types aren't associated with the same objfile,
- then we are in deep-s**t anyway... */
+ allocated. */
void
smash_to_method_type (type, domain, to_type, args)
p = comname;
while (*p)
{
- if (!(*p >= 'A' && *p <= 'Z')
- && !(*p >= 'a' && *p <= 'z')
- && !(*p >= '0' && *p <= '9')
- && *p != '-')
+ if (!isalnum(*p) && *p != '-')
error ("Junk in argument list: \"%s\"", p);
p++;
}
}
-#ifdef IBM6000
-
-lowercase (char *str)
-{
- while (*str) {
-
- /* isupper(), tolower() are function calls in AIX. */
- if ( *str >= 'A' && *str <= 'Z')
- *str = *str + 'a' - 'A';
- ++str;
- }
-}
-#endif
-
static void
define_command (comname, from_tty)
char *comname;
validate_comname (comname);
-#ifdef IBM6000
-
- /* If the rest of the commands will be case insensetive, this one
- should behave in the same manner. */
-
- lowercase (comname);
-#endif
-
/* Look it up, and verify that we got an exact match. */
c = lookup_cmd (&tem, cmdlist, "", -1, 1);
if (c && 0 != strcmp (comname, c->name))
tem = "Redefine command \"%s\"? ";
else
tem = "Really redefine built-in command \"%s\"? ";
- if (!query (tem, comname))
- error ("Command \"%s\" not redefined.", comname);
+ if (!query (tem, c->name))
+ error ("Command \"%s\" not redefined.", c->name);
}
+ comname = savestring (comname, strlen (comname));
+
+ /* If the rest of the commands will be case insensetive, this one
+ should behave in the same manner. */
+ for (tem = comname; *tem; tem++)
+ if (isupper(*tem)) *tem = tolower(*tem);
+
if (from_tty)
{
printf ("Type commands for definition of \"%s\".\n\
End with a line saying just \"end\".\n", comname);
fflush (stdout);
}
- comname = savestring (comname, strlen (comname));
cmds = read_command_lines ();
{
if (history_size == UINT_MAX)
unstifle_history ();
- else
+ else if (history_size >= 0)
stifle_history (history_size);
+ else
+ {
+ history_size = UINT_MAX;
+ error ("History size must be non-negative");
+ }
}
/* ARGSUSED */
/* Shared code to pre-read a stab (dbx-style), when building a psymtab.
- Copyright (C) 1986-1991 Free Software Foundation, Inc.
+ Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992 Free Software Foundation,
+ Inc.
This file is part of GDB.
-/* Indirect function calls use a piece of trampoline code do co context switching,
- i.e. to set the new TOC table. Skip such code if exists. */
+/* Indirect function calls use a piece of trampoline code to do context
+ switching, i.e. to set the new TOC table. Skip such code if we are on
+ its first instruction (as when we have single-stepped to here).
+ Result is desired PC to step until, or NULL if we are not in
+ trampoline code. */
skip_trampoline_code (pc)
int pc;