* symtab.c, dbxread.c, stabsread.c: Fix up ANSI-C isms. Fix
some formatting problems.
This commit is contained in:
parent
5ddf2a9e6c
commit
b303e1053f
3 changed files with 27 additions and 15 deletions
|
@ -1,7 +1,7 @@
|
||||||
Tue Sep 9 17:41:41 1997 Jeffrey A Law (law@cygnus.com)
|
Tue Sep 9 17:41:41 1997 Jeffrey A Law (law@cygnus.com)
|
||||||
|
|
||||||
* symtab.c (lookup_block_symbol): Add missing PARAMS for
|
* symtab.c, dbxread.c, stabsread.c: Fix up ANSI-C isms. Fix
|
||||||
function scoped prototype.
|
some formatting problems.
|
||||||
|
|
||||||
Mon Sep 8 16:45:51 1997 Stu Grossman <grossman@cygnus.com>
|
Mon Sep 8 16:45:51 1997 Stu Grossman <grossman@cygnus.com>
|
||||||
|
|
||||||
|
|
|
@ -773,7 +773,7 @@ struct cont_elem
|
||||||
int sym_idx;
|
int sym_idx;
|
||||||
int sym_end;
|
int sym_end;
|
||||||
int symnum;
|
int symnum;
|
||||||
int (*func) (struct objfile *, struct symbol *, char *);
|
int (*func) PARAMS ((struct objfile *, struct symbol *, char *));
|
||||||
/* other state dependancies include:
|
/* other state dependancies include:
|
||||||
(assumption is that these will not change since process_now FIXME!!)
|
(assumption is that these will not change since process_now FIXME!!)
|
||||||
stringtab_global
|
stringtab_global
|
||||||
|
@ -790,7 +790,7 @@ void
|
||||||
process_later (sym, p, f)
|
process_later (sym, p, f)
|
||||||
struct symbol * sym;
|
struct symbol * sym;
|
||||||
char * p;
|
char * p;
|
||||||
int (*f) (struct objfile *, struct symbol *, char *);
|
int (*f) PARAMS ((struct objfile *, struct symbol *, char *));
|
||||||
{
|
{
|
||||||
if (cont_count >= cont_limit - 1)
|
if (cont_count >= cont_limit - 1)
|
||||||
{
|
{
|
||||||
|
@ -822,7 +822,7 @@ process_now (objfile)
|
||||||
struct symbol *sym;
|
struct symbol *sym;
|
||||||
char *stabs;
|
char *stabs;
|
||||||
int err;
|
int err;
|
||||||
int (*func) (struct objfile *, struct symbol *, char *);
|
int (*func) PARAMS ((struct objfile *, struct symbol *, char *));
|
||||||
|
|
||||||
for (i=0; i<cont_count; i++)
|
for (i=0; i<cont_count; i++)
|
||||||
{
|
{
|
||||||
|
@ -2371,9 +2371,9 @@ process_one_symbol (type, desc, valu, name, section_offsets, objfile)
|
||||||
ahead and add it. Otherwise, just return sym. */
|
ahead and add it. Otherwise, just return sym. */
|
||||||
char *s;
|
char *s;
|
||||||
int refnum;
|
int refnum;
|
||||||
extern int symbol_reference_defined (char **);
|
extern int symbol_reference_defined PARAMS ((char **));
|
||||||
extern void ref_add (int, struct symbol *, char *, CORE_ADDR);
|
extern void ref_add PARAMS ((int, struct symbol *, char *, CORE_ADDR));
|
||||||
extern struct symbol * ref_search (int);
|
extern struct symbol * ref_search PARAMS ((int));
|
||||||
|
|
||||||
/* If defined, store away a pointer to the symbol;
|
/* If defined, store away a pointer to the symbol;
|
||||||
we'll use it later when we resolve references in
|
we'll use it later when we resolve references in
|
||||||
|
|
|
@ -1123,7 +1123,8 @@ resolve_symbol_reference (objfile, sym, p)
|
||||||
/* Get range symbol reference. eg. "#2),l(#3,#5)"
|
/* Get range symbol reference. eg. "#2),l(#3,#5)"
|
||||||
postpone resolve_reference until after we're done reading symbols. */
|
postpone resolve_reference until after we're done reading symbols. */
|
||||||
struct symbol *
|
struct symbol *
|
||||||
resolve_reference (char *p)
|
resolve_reference (p)
|
||||||
|
char *p;
|
||||||
{
|
{
|
||||||
char sym_refid[32];
|
char sym_refid[32];
|
||||||
struct symbol *sym = 0;
|
struct symbol *sym = 0;
|
||||||
|
@ -1169,7 +1170,12 @@ static void ref_init ()
|
||||||
Add pointers to reference definition symbols and/or their values as we
|
Add pointers to reference definition symbols and/or their values as we
|
||||||
find them, using their reference numbers as our index.
|
find them, using their reference numbers as our index.
|
||||||
These will be used later when we resolve references. */
|
These will be used later when we resolve references. */
|
||||||
void ref_add (int refnum, struct symbol *sym, char *stabs, CORE_ADDR value)
|
void
|
||||||
|
ref_add (refnum, sym, stabs, value)
|
||||||
|
int refnum;
|
||||||
|
struct symbol *sym;
|
||||||
|
char *stabs;
|
||||||
|
CORE_ADDR value;
|
||||||
{
|
{
|
||||||
if (ref_count == 0)
|
if (ref_count == 0)
|
||||||
ref_init ();
|
ref_init ();
|
||||||
|
@ -1186,7 +1192,9 @@ void ref_add (int refnum, struct symbol *sym, char *stabs, CORE_ADDR value)
|
||||||
This should be called before a new symbol table is read to clear out the
|
This should be called before a new symbol table is read to clear out the
|
||||||
previous symbol's reference information. */
|
previous symbol's reference information. */
|
||||||
/* FIXME! not used at the moment. */
|
/* FIXME! not used at the moment. */
|
||||||
static void ref_rmv (int refnum)
|
static void
|
||||||
|
ref_rmv (refnum)
|
||||||
|
int refnum;
|
||||||
{
|
{
|
||||||
if (ref_count < 0)
|
if (ref_count < 0)
|
||||||
error ("slots are empty\n");
|
error ("slots are empty\n");
|
||||||
|
@ -1200,7 +1208,8 @@ static void ref_rmv (int refnum)
|
||||||
|
|
||||||
/* Return defined sym for the reference "refnum" */
|
/* Return defined sym for the reference "refnum" */
|
||||||
struct symbol *
|
struct symbol *
|
||||||
ref_search (int refnum)
|
ref_search (refnum)
|
||||||
|
int refnum;
|
||||||
{
|
{
|
||||||
if (refnum < 0 || refnum > ref_count)
|
if (refnum < 0 || refnum > ref_count)
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -1209,7 +1218,8 @@ ref_search (int refnum)
|
||||||
|
|
||||||
/* Return value for the reference "refnum" */
|
/* Return value for the reference "refnum" */
|
||||||
CORE_ADDR
|
CORE_ADDR
|
||||||
ref_search_value (int refnum)
|
ref_search_value (refnum)
|
||||||
|
int refnum;
|
||||||
{
|
{
|
||||||
if (refnum < 0 || refnum > ref_count)
|
if (refnum < 0 || refnum > ref_count)
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -1221,7 +1231,8 @@ ref_search_value (int refnum)
|
||||||
Return the reference number. */
|
Return the reference number. */
|
||||||
|
|
||||||
static int
|
static int
|
||||||
process_reference (char **string)
|
process_reference (string)
|
||||||
|
char **string;
|
||||||
{
|
{
|
||||||
char *p;
|
char *p;
|
||||||
int refnum = 0;
|
int refnum = 0;
|
||||||
|
@ -1244,7 +1255,8 @@ process_reference (char **string)
|
||||||
definition for fast lookup when we "process_later",
|
definition for fast lookup when we "process_later",
|
||||||
and return the reference number. */
|
and return the reference number. */
|
||||||
int
|
int
|
||||||
symbol_reference_defined (char **string)
|
symbol_reference_defined (string)
|
||||||
|
char **string;
|
||||||
{
|
{
|
||||||
char *p = *string;
|
char *p = *string;
|
||||||
int refnum = 0;
|
int refnum = 0;
|
||||||
|
|
Loading…
Reference in a new issue