* c-exp.y: Fix problems with parsing "'foo.bar'::func". Some languages

allow symbols with dots.

	* gdbtypes.c (check_stub_method):  Cosmetic.  Use more descriptive
	names for parameters.

start-sanitize-java
	* jv-exp.y:  Parser now accepts primitive types.
	* (parse_number):  Use correct ifdef for scanf long double support.
	* jv-lang.c (java_array_type):  Initial cut at array support.
end-sanitize-java

	* language.c language.h (set_language):  Now returns previous language.

	* symtab.c (find_methods):  Make static.  Cosmetic changes, including
	indentation, and adding descriptive comments.  Move local variable defs
	into the block they are used in.
	* Don't call check_stub_method any more.  Use gdb_mangle_name to
	generate the full method name.  find_method doesn't need all the other
	goobldegook that check_stub_method does.
	* (gdb_mangle_name):  Use more descriptive names for parameters.  Fix
	comment.
start-sanitize-java
	* (lookup_partial_symbol lookup_block_symbol):  Check for java to
	ensure we can find mangled names.
end-sanitize-java
	* (decode_line_1):  Move local variable defs into the block they are
	used in.  (Improves code readability.)
This commit is contained in:
Stu Grossman
1998-06-10 23:29:59 +00:00
parent a27a2a8de4
commit f6d23b6f3b
7 changed files with 104 additions and 40 deletions

View File

@ -1238,13 +1238,13 @@ cfront_mangle_name(type, i, j)
the space required for them. */
void
check_stub_method (type, i, j)
check_stub_method (type, method_id, signature_id)
struct type *type;
int i;
int j;
int method_id;
int signature_id;
{
struct fn_field *f;
char *mangled_name = gdb_mangle_name (type, i, j);
char *mangled_name = gdb_mangle_name (type, method_id, signature_id);
char *demangled_name = cplus_demangle (mangled_name,
DMGL_PARAMS | DMGL_ANSI);
char *argtypetext, *p;
@ -1331,16 +1331,16 @@ check_stub_method (type, i, j)
free (demangled_name);
f = TYPE_FN_FIELDLIST1 (type, i);
f = TYPE_FN_FIELDLIST1 (type, method_id);
TYPE_FN_FIELD_PHYSNAME (f, j) = mangled_name;
TYPE_FN_FIELD_PHYSNAME (f, signature_id) = mangled_name;
/* Now update the old "stub" type into a real type. */
mtype = TYPE_FN_FIELD_TYPE (f, j);
mtype = TYPE_FN_FIELD_TYPE (f, signature_id);
TYPE_DOMAIN_TYPE (mtype) = type;
TYPE_ARG_TYPES (mtype) = argtypes;
TYPE_FLAGS (mtype) &= ~TYPE_FLAG_STUB;
TYPE_FN_FIELD_STUB (f, j) = 0;
TYPE_FN_FIELD_STUB (f, signature_id) = 0;
}
const struct cplus_struct_type cplus_struct_default;