/* Forward procedure declarations */
-static void set_namestring (union dnttentry *sym, char **namep,
- struct objfile *objfile);
-
+/* Used in somread.c. */
void hpread_symfile_init (struct objfile *);
void do_pxdb (bfd *);
void hpread_symfile_finish (struct objfile *);
+static void set_namestring (union dnttentry *sym, char **namep,
+ struct objfile *objfile);
+
static union dnttentry *hpread_get_gntt (int, struct objfile *);
static union dnttentry *hpread_get_lntt (int index, struct objfile *objfile);
static CORE_ADDR hpread_get_location (sltpointer, struct objfile *);
-int hpread_has_name (enum dntt_entry_type kind);
+static int hpread_has_name (enum dntt_entry_type kind);
static void hpread_psymtab_to_symtab_1 (struct partial_symtab *);
-void hpread_psymtab_to_symtab (struct partial_symtab *);
+static void hpread_psymtab_to_symtab (struct partial_symtab *);
static struct symtab *hpread_expand_symtab
(struct objfile *, int, int, CORE_ADDR, int,
#include "gdb_string.h"
/* check for the existence of a file, given its full pathname */
-int
+static int
file_exists (char *filename)
{
if (filename)
NOTE: uses system function and string functions directly.
Return value: 1 if ok, 0 if not */
-int
+static int
hpread_call_pxdb (const char *file_name)
{
char *p;
by PXDB, and we have thus called PXDB to do this processing
and the file therefore needs to be re-loaded. Otherwise
return 0. */
-int
+static int
hpread_pxdb_needed (bfd *sym_bfd)
{
asection *pinfo_section, *debug_section, *header_section;
strlen (rtn_name),
rtn_dem_name,
strlen (rtn_dem_name),
- VAR_NAMESPACE,
+ VAR_DOMAIN,
LOC_BLOCK, /* "I am a routine" */
&objfile->global_psymbols,
(qPD[curr_pd].adrStart + /* Starting address of rtn */
strlen (rtn_name),
rtn_dem_name,
strlen (rtn_dem_name),
- VAR_NAMESPACE,
+ VAR_DOMAIN,
LOC_BLOCK, /* "I am a routine" */
&objfile->static_psymbols,
(qPD[curr_pd].adrStart + /* Starting address of rtn */
a file can result in a compiled object which does not have a module
entry for it, so in such cases we create a psymtab for the file. */
-int
+static int
hpread_quick_traverse (struct objfile *objfile, char *gntt_bits,
char *vt_bits, PXDB_header_ptr pxdb_header_p)
{
/* Get appropriate header, based on pxdb type.
Return value: 1 if ok, 0 if not */
-int
+static int
hpread_get_header (struct objfile *objfile, PXDB_header_ptr pxdb_header_p)
{
asection *pinfo_section, *debug_section, *header_section;
set_namestring (dn_bufp, &namestring, objfile);
if (dn_bufp->dfunc.global)
add_psymbol_to_list (namestring, strlen (namestring),
- VAR_NAMESPACE, LOC_BLOCK,
+ VAR_DOMAIN, LOC_BLOCK,
&objfile->global_psymbols, valu,
0, language_unknown, objfile);
else
add_psymbol_to_list (namestring, strlen (namestring),
- VAR_NAMESPACE, LOC_BLOCK,
+ VAR_DOMAIN, LOC_BLOCK,
&objfile->static_psymbols, valu,
0, language_unknown, objfile);
within_function = 1;
set_namestring (dn_bufp, &namestring, objfile);
if (dn_bufp->ddocfunc.global)
add_psymbol_to_list (namestring, strlen (namestring),
- VAR_NAMESPACE, LOC_BLOCK,
+ VAR_DOMAIN, LOC_BLOCK,
&objfile->global_psymbols, valu,
0, language_unknown, objfile);
else
add_psymbol_to_list (namestring, strlen (namestring),
- VAR_NAMESPACE, LOC_BLOCK,
+ VAR_DOMAIN, LOC_BLOCK,
&objfile->static_psymbols, valu,
0, language_unknown, objfile);
within_function = 1;
{
/* Variables, typedefs an the like. */
enum address_class storage;
- namespace_enum namespace;
+ domain_enum domain;
/* Don't add locals to the partial symbol table. */
if (within_function
|| dn_bufp->dblock.kind == DNTT_TYPE_DVAR))
continue;
- /* TAGDEFs go into the structure namespace. */
+ /* TAGDEFs go into the structure domain. */
if (dn_bufp->dblock.kind == DNTT_TYPE_TAGDEF)
- namespace = STRUCT_NAMESPACE;
+ domain = STRUCT_DOMAIN;
else
- namespace = VAR_NAMESPACE;
+ domain = VAR_DOMAIN;
/* What kind of "storage" does this use? */
if (dn_bufp->dblock.kind == DNTT_TYPE_SVAR)
if (dn_bufp->dsvar.global)
{
add_psymbol_to_list (namestring, strlen (namestring),
- namespace, storage,
+ domain, storage,
&objfile->global_psymbols,
valu,
0, language_unknown, objfile);
else
{
add_psymbol_to_list (namestring, strlen (namestring),
- namespace, storage,
+ domain, storage,
&objfile->static_psymbols,
valu,
0, language_unknown, objfile);
}
/* For TAGDEF's, the above code added the tagname to the
- struct namespace. This will cause tag "t" to be found
+ struct domain. This will cause tag "t" to be found
on a reference of the form "(struct t) x". But for
C++ classes, "t" will also be a typename, which we
want to find on a reference of the form "ptype t".
- Therefore, we also add "t" to the var namespace.
+ Therefore, we also add "t" to the var domain.
Do the same for enum's due to the way aCC generates
debug info for these (see more extended comment
in hp-symtab-read.c).
if (global)
{
add_psymbol_to_list (namestring, strlen (namestring),
- VAR_NAMESPACE, storage,
+ VAR_DOMAIN, storage,
&objfile->global_psymbols,
dn_bufp->dsvar.location,
0, language_unknown, objfile);
else
{
add_psymbol_to_list (namestring, strlen (namestring),
- VAR_NAMESPACE, storage,
+ VAR_DOMAIN, storage,
&objfile->static_psymbols,
dn_bufp->dsvar.location,
0, language_unknown, objfile);
}
if (dn_bufp->dconst.global)
add_psymbol_to_list (namestring, strlen (namestring),
- VAR_NAMESPACE, LOC_CONST,
+ VAR_DOMAIN, LOC_CONST,
&objfile->global_psymbols, 0,
0, language_unknown, objfile);
else
add_psymbol_to_list (namestring, strlen (namestring),
- VAR_NAMESPACE, LOC_CONST,
+ VAR_DOMAIN, LOC_CONST,
&objfile->static_psymbols, 0,
0, language_unknown, objfile);
continue;
/* Various small functions to get entries in the debug symbol sections. */
-union dnttentry *
+static union dnttentry *
hpread_get_lntt (int index, struct objfile *objfile)
{
return (union dnttentry *)
&(GNTT (objfile)[(index * sizeof (struct dntt_type_block))]);
}
-union sltentry *
+static union sltentry *
hpread_get_slt (int index, struct objfile *objfile)
{
return (union sltentry *) &(SLT (objfile)[index * sizeof (union sltentry)]);
* leave it here in case it proves useful later on. - RT).
*/
-int
+static int
hpread_has_name (enum dntt_entry_type kind)
{
switch (kind)
/* Read in all of the symbols for a given psymtab for real.
Be verbose about it if the user wants that. */
-void
+static void
hpread_psymtab_to_symtab (struct partial_symtab *pst)
{
/* Get out quick if given junk. */
DEPRECATED_SYMBOL_NAME (sym) = obsavestring (name, strlen (name),
&objfile->symbol_obstack);
SYMBOL_CLASS (sym) = LOC_CONST;
- SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+ SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
SYMBOL_VALUE (sym) = memp->dmember.value;
add_symbol_to_list (sym, symlist);
nsyms++;
SYMBOL_CLASS (sym) = LOC_REF_ARG;
else
SYMBOL_CLASS (sym) = LOC_ARG;
- SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+ SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
if (paramp->dfparam.copyparam)
{
SYMBOL_VALUE (sym) = paramp->dfparam.location;
SYMBOL_CLASS (sym) = LOC_REF_ARG;
else
SYMBOL_CLASS (sym) = LOC_ARG;
- SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+ SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
if (paramp->dfparam.copyparam)
{
SYMBOL_VALUE (sym) = paramp->dfparam.location;
* Called from hpread_process_one_debug_symbol()
* If "f" is not a member function, return NULL.
*/
-char *
+static char *
class_of (struct type *functype)
{
struct type *first_param_type;
memset (sym, 0, sizeof (struct symbol));
DEPRECATED_SYMBOL_NAME (sym) = obsavestring (name, strlen (name), &objfile->symbol_obstack);
SYMBOL_LANGUAGE (sym) = language_auto;
- SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+ SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
SYMBOL_LINE (sym) = 0;
SYMBOL_VALUE (sym) = 0;
SYMBOL_CLASS (sym) = LOC_TYPEDEF;
/* DNTT_TYPE_IMPORT is not handled */
case DNTT_TYPE_LABEL:
- SYMBOL_NAMESPACE (sym) = LABEL_NAMESPACE;
+ SYMBOL_DOMAIN (sym) = LABEL_DOMAIN;
break;
case DNTT_TYPE_FPARAM:
SYMBOL_CLASS (sym) = LOC_REF_ARG;
else
SYMBOL_CLASS (sym) = LOC_ARG;
- SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+ SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
if (dn_bufp->dfparam.copyparam)
{
SYMBOL_VALUE (sym) = dn_bufp->dfparam.location;
case DNTT_TYPE_TYPEDEF:
/* A typedef. We do want to process these, since a name is
- * added to the namespace for the typedef'ed name.
+ * added to the domain for the typedef'ed name.
*/
- SYMBOL_NAMESPACE (sym) = VAR_NAMESPACE;
+ SYMBOL_DOMAIN (sym) = VAR_DOMAIN;
SYMBOL_TYPE (sym) = hpread_type_lookup (dn_bufp->dtype.type, objfile);
if (dn_bufp->dtype.global)
add_symbol_to_list (sym, &global_symbols);
int global = dn_bufp->dtag.global;
/* Structure, union, enum, template, or class tag definition */
/* We do want to process these, since a name is
- * added to the namespace for the tag name (and if C++ class,
+ * added to the domain for the tag name (and if C++ class,
* for the typename also).
*/
- SYMBOL_NAMESPACE (sym) = STRUCT_NAMESPACE;
+ SYMBOL_DOMAIN (sym) = STRUCT_DOMAIN;
/* The tag contains in its "type" field a pointer to the
* DNTT_TYPE_STRUCT, DNTT_TYPE_UNION, DNTT_TYPE_ENUM,
memset (newsym, 0, sizeof (struct symbol));
DEPRECATED_SYMBOL_NAME (newsym) = name;
SYMBOL_LANGUAGE (newsym) = language_auto;
- SYMBOL_NAMESPACE (newsym) = VAR_NAMESPACE;
+ SYMBOL_DOMAIN (newsym) = VAR_DOMAIN;
SYMBOL_LINE (newsym) = 0;
SYMBOL_VALUE (newsym) = 0;
SYMBOL_CLASS (newsym) = LOC_TYPEDEF;