diff options
-rw-r--r-- | gdb/ChangeLog | 21 | ||||
-rw-r--r-- | gdb/ada-lang.c | 2 | ||||
-rw-r--r-- | gdb/c-lang.c | 8 | ||||
-rw-r--r-- | gdb/f-lang.c | 2 | ||||
-rw-r--r-- | gdb/jv-lang.c | 2 | ||||
-rw-r--r-- | gdb/language.c | 35 | ||||
-rw-r--r-- | gdb/language.h | 10 | ||||
-rw-r--r-- | gdb/m2-lang.c | 2 | ||||
-rw-r--r-- | gdb/objc-lang.c | 2 | ||||
-rw-r--r-- | gdb/p-lang.c | 2 | ||||
-rw-r--r-- | gdb/scm-lang.c | 2 |
11 files changed, 28 insertions, 60 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index abf17fee072..8270427347f 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,24 @@ +2007-11-02 Ulrich Weigand <uweigand@de.ibm.com> + + * language.h (struct language_defn): Remove la_builtin_type_vector + and string_char_type members. + * language.c (language_string_char_type): No longer consult + la->string_char_type. + (language_lookup_primitive_type_by_name): No longer consult + current_language->la_builtin_type_vector. + + * language.c (unknown_language_defn, auto_language_defn, + local_language_defn): Adapt initializer. + * ada-lang.c (ada_language_defn): Likewise. + * c-lang.c (c_language_defn, cplus_language_defn, asm_language_defn, + minimal_language_defn): Likewise. + * f-lang.c (f_language_defn): Likewise. + * jv-lang.c (java_language_defn): Likewise. + * m2-lang.c (m2_language_defn): Likewise. + * objc-lang.c (objc_language_defn): Likewise. + * p-lang.c (pascal_language_defn): Likewise. + * scm-lang.c (scm_language_defn): Likewise. + 2007-11-02 Markus Deuling <deuling@de.ibm.com> * frame.c (frame_id_inner): Add gdbarch parameter. Replace diff --git a/gdb/ada-lang.c b/gdb/ada-lang.c index 53f32f27ca7..e7852c5b10e 100644 --- a/gdb/ada-lang.c +++ b/gdb/ada-lang.c @@ -10411,7 +10411,6 @@ static const struct exp_descriptor ada_exp_descriptor = { const struct language_defn ada_language_defn = { "ada", /* Language name */ language_ada, - NULL, range_check_off, type_check_off, case_sensitive_on, /* Yes, Ada is case-insensitive, but @@ -10437,7 +10436,6 @@ const struct language_defn ada_language_defn = { ada_op_print_tab, /* expression operators for printing */ 0, /* c-style arrays */ 1, /* String lower bound */ - NULL, ada_get_gdb_completer_word_break_characters, ada_language_arch_info, ada_print_array_index, diff --git a/gdb/c-lang.c b/gdb/c-lang.c index 9b4d1cd0868..cc952a8c79a 100644 --- a/gdb/c-lang.c +++ b/gdb/c-lang.c @@ -592,7 +592,6 @@ const struct language_defn c_language_defn = { "c", /* Language name */ language_c, - NULL, range_check_off, type_check_off, case_sensitive_on, @@ -617,7 +616,6 @@ const struct language_defn c_language_defn = c_op_print_tab, /* expression operators for printing */ 1, /* c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, c_language_arch_info, default_print_array_index, @@ -698,7 +696,6 @@ const struct language_defn cplus_language_defn = { "c++", /* Language name */ language_cplus, - NULL, range_check_off, type_check_off, case_sensitive_on, @@ -723,7 +720,6 @@ const struct language_defn cplus_language_defn = c_op_print_tab, /* expression operators for printing */ 1, /* c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, cplus_language_arch_info, default_print_array_index, @@ -735,7 +731,6 @@ const struct language_defn asm_language_defn = { "asm", /* Language name */ language_asm, - NULL, range_check_off, type_check_off, case_sensitive_on, @@ -760,7 +755,6 @@ const struct language_defn asm_language_defn = c_op_print_tab, /* expression operators for printing */ 1, /* c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, c_language_arch_info, /* FIXME: la_language_arch_info. */ default_print_array_index, @@ -777,7 +771,6 @@ const struct language_defn minimal_language_defn = { "minimal", /* Language name */ language_minimal, - NULL, range_check_off, type_check_off, case_sensitive_on, @@ -802,7 +795,6 @@ const struct language_defn minimal_language_defn = c_op_print_tab, /* expression operators for printing */ 1, /* c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, c_language_arch_info, default_print_array_index, diff --git a/gdb/f-lang.c b/gdb/f-lang.c index ad6835eba40..25fde404d6a 100644 --- a/gdb/f-lang.c +++ b/gdb/f-lang.c @@ -474,7 +474,6 @@ const struct language_defn f_language_defn = { "fortran", language_fortran, - NULL, range_check_on, type_check_on, case_sensitive_off, @@ -499,7 +498,6 @@ const struct language_defn f_language_defn = f_op_print_tab, /* expression operators for printing */ 0, /* arrays are first-class (not c-style) */ 1, /* String lower bound */ - NULL, default_word_break_characters, f_language_arch_info, default_print_array_index, diff --git a/gdb/jv-lang.c b/gdb/jv-lang.c index d28df029c01..a426d6175f3 100644 --- a/gdb/jv-lang.c +++ b/gdb/jv-lang.c @@ -1086,7 +1086,6 @@ const struct language_defn java_language_defn = { "java", /* Language name */ language_java, - NULL, range_check_off, type_check_off, case_sensitive_on, @@ -1111,7 +1110,6 @@ const struct language_defn java_language_defn = java_op_print_tab, /* expression operators for printing */ 0, /* not c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, c_language_arch_info, default_print_array_index, diff --git a/gdb/language.c b/gdb/language.c index d5c6a94b095..fe2939e31f3 100644 --- a/gdb/language.c +++ b/gdb/language.c @@ -1179,7 +1179,6 @@ const struct language_defn unknown_language_defn = { "unknown", language_unknown, - NULL, range_check_off, type_check_off, array_row_major, @@ -1204,7 +1203,6 @@ const struct language_defn unknown_language_defn = unk_op_print_tab, /* expression operators for printing */ 1, /* c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, unknown_language_arch_info, /* la_language_arch_info. */ default_print_array_index, @@ -1217,7 +1215,6 @@ const struct language_defn auto_language_defn = { "auto", language_auto, - NULL, range_check_off, type_check_off, array_row_major, @@ -1242,7 +1239,6 @@ const struct language_defn auto_language_defn = unk_op_print_tab, /* expression operators for printing */ 1, /* c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, unknown_language_arch_info, /* la_language_arch_info. */ default_print_array_index, @@ -1254,7 +1250,6 @@ const struct language_defn local_language_defn = { "local", language_auto, - NULL, range_check_off, type_check_off, case_sensitive_on, @@ -1279,7 +1274,6 @@ const struct language_defn local_language_defn = unk_op_print_tab, /* expression operators for printing */ 1, /* c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, unknown_language_arch_info, /* la_language_arch_info. */ default_print_array_index, @@ -1321,10 +1315,7 @@ language_string_char_type (const struct language_defn *la, { struct language_gdbarch *ld = gdbarch_data (gdbarch, language_gdbarch_data); - if (ld->arch_info[la->la_language].string_char_type != NULL) - return ld->arch_info[la->la_language].string_char_type; - else - return (*la->string_char_type); + return ld->arch_info[la->la_language].string_char_type; } struct type * @@ -1334,25 +1325,13 @@ language_lookup_primitive_type_by_name (const struct language_defn *la, { struct language_gdbarch *ld = gdbarch_data (gdbarch, language_gdbarch_data); - if (ld->arch_info[la->la_language].primitive_type_vector != NULL) - { - struct type *const *p; - for (p = ld->arch_info[la->la_language].primitive_type_vector; - (*p) != NULL; - p++) - { - if (strcmp (TYPE_NAME (*p), name) == 0) - return (*p); - } - } - else + struct type *const *p; + for (p = ld->arch_info[la->la_language].primitive_type_vector; + (*p) != NULL; + p++) { - struct type **const *p; - for (p = current_language->la_builtin_type_vector; *p != NULL; p++) - { - if (strcmp (TYPE_NAME (**p), name) == 0) - return (**p); - } + if (strcmp (TYPE_NAME (*p), name) == 0) + return (*p); } return (NULL); } diff --git a/gdb/language.h b/gdb/language.h index 3649b00d039..798c4d0592b 100644 --- a/gdb/language.h +++ b/gdb/language.h @@ -148,13 +148,6 @@ struct language_defn enum language la_language; - /* Its builtin types. This is a vector ended by a NULL pointer. These - types can be specified by name in parsing types in expressions, - regardless of whether the program being debugged actually defines - such a type. */ - - struct type **const *la_builtin_type_vector; - /* Default range checking */ enum range_check la_range_check; @@ -264,9 +257,6 @@ struct language_defn /* Index to use for extracting the first element of a string. */ char string_lower_bound; - /* Type of elements of strings. */ - struct type **string_char_type; - /* The list of characters forming word boundaries. */ char *(*la_word_break_characters) (void); diff --git a/gdb/m2-lang.c b/gdb/m2-lang.c index be7eaed1285..bac36324408 100644 --- a/gdb/m2-lang.c +++ b/gdb/m2-lang.c @@ -529,7 +529,6 @@ const struct language_defn m2_language_defn = { "modula-2", language_m2, - NULL, range_check_on, type_check_on, case_sensitive_on, @@ -554,7 +553,6 @@ const struct language_defn m2_language_defn = m2_op_print_tab, /* expression operators for printing */ 0, /* arrays are first-class (not c-style) */ 0, /* String lower bound */ - NULL, default_word_break_characters, m2_language_arch_info, default_print_array_index, diff --git a/gdb/objc-lang.c b/gdb/objc-lang.c index d1771d92e8b..83bc4ef7ec9 100644 --- a/gdb/objc-lang.c +++ b/gdb/objc-lang.c @@ -639,7 +639,6 @@ static const struct op_print objc_op_print_tab[] = const struct language_defn objc_language_defn = { "objective-c", /* Language name */ language_objc, - NULL, range_check_off, type_check_off, case_sensitive_on, @@ -664,7 +663,6 @@ const struct language_defn objc_language_defn = { objc_op_print_tab, /* Expression operators for printing */ 1, /* C-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, c_language_arch_info, default_print_array_index, diff --git a/gdb/p-lang.c b/gdb/p-lang.c index 4b187201bc9..7697279c6b9 100644 --- a/gdb/p-lang.c +++ b/gdb/p-lang.c @@ -546,7 +546,6 @@ const struct language_defn pascal_language_defn = { "pascal", /* Language name */ language_pascal, - NULL, range_check_on, type_check_on, case_sensitive_on, @@ -571,7 +570,6 @@ const struct language_defn pascal_language_defn = pascal_op_print_tab, /* expression operators for printing */ 1, /* c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, pascal_language_arch_info, default_print_array_index, diff --git a/gdb/scm-lang.c b/gdb/scm-lang.c index a8de4b03931..24dac04f2dc 100644 --- a/gdb/scm-lang.c +++ b/gdb/scm-lang.c @@ -238,7 +238,6 @@ const struct language_defn scm_language_defn = { "scheme", /* Language name */ language_scm, - NULL, range_check_off, type_check_off, case_sensitive_off, @@ -263,7 +262,6 @@ const struct language_defn scm_language_defn = NULL, /* expression operators for printing */ 1, /* c-style arrays */ 0, /* String lower bound */ - NULL, default_word_break_characters, c_language_arch_info, default_print_array_index, |