1 2006-01-02 Paul Hilfinger <hilfingr@nile.gnat.com>
3 * ada-exp.y (syntax definitions,write_var_or_type,write_name_assoc):
4 Change uses of "illegal" to "invalid".
6 2006-01-02 Paul N. Hilfinger <hilfinger@adacore.com>
8 * ada-exp.y: Considerable reorganization to move functionality
9 from ada-lex.l to here, where it is logically more appropriate.
10 The original reason, however, was to prevent premature name
11 lookups for selector names in record aggregates.
12 (BLOCKNAME, TYPENAME, OBJECT_RENAMING): Remove; lexer now returns
13 NAME for all of these.
14 (VAR): New artificial token to clarify precedence rules.
16 (empty_stoken): New symbol.
17 (%union): Remove ssym, voidval.
18 (%type): Remove <voidval> type declarations.
19 (syntax definitions): Add aggregates.
20 Remove distinction between NAME, TYPENAME, BLOCKNAME, OBJECT_RENAMING.
21 Rename some non-terminals to be closer to reference manual usage.
22 Tighten up expression syntax to disallow certain non-Ada
23 constructions such as X and then Y or else Z.
24 (ada_parse): Remove initialization of left_block_context.
25 (write_var_from_name): Remove.
26 (write_var_or_type): New function, containing previous code from
27 defunct write_var_from_name and name_lookup.
28 (block_lookup): New function, moved from ada-lex.l
29 (select_possible_type_sym): New function, factored out of
30 name_lookup, which used to be in ada-lex.l.
31 (find_primitive_type): Ditto.
32 (chop_selector): Ditto.
33 (write_ambiguous_var): New function, factored out of defunct
35 (write_selectors): New function.
36 (write_name_assoc): New function.
37 (write_exp_op_with_string): New function.
39 * ada-lex.l (processId): Change interface to return stoken.
40 (tempbuf, resize_tempbuf, tempbuf_size, tempbuf_len): Remove.
41 (block_lookup, name_lookup): Remove. Functionality moved to
43 (state IN_STRING): Remove.
44 (rules): Handle string escapes in processString.
46 Return all NAMEs, BLOCKNAMEs, OBJECT_RENAMINGs, TYPENAMEs in
47 yylval.sval (as simple strings).
48 All name look-ups now handled in ada-exp.y.
49 Introduce "::" (COLONCOLON) token and return as separate token.
50 (processId): Change return convention. Comment.
51 Leave leading "'" in place.
52 (processString): New function.
53 (find_dot_all): Add note to comment.
54 Fix problem that allowed match only at the end.
56 * ada-lang.c: Introduce aggregates.
57 (find_struct_field): Add new parameter to count fields skipped, and
58 allow other output parameters to be NULL.
59 (value_tag_from_contents_and_address, ada_value_struct_elt): Use
60 new find_struct_field.
61 (ada_index_struct_field, assign_aggregate, ada_is_array_type)
62 (num_visible_fields, ada_index_struct_field_1, ada_index_struct_field)
63 (num_component_specs, assign_component, assign_aggregate):
64 (aggregate_assign_from_choices,aggregate_assign_positional)
65 (aggregate_assign_others,add_component_interval):
67 (ada_evaluate_subexp): Declare.
68 Add aggregate-related operators.
69 (ada_forward_operator_length): Declare.
70 (resolve_subexp): Add cases for new aggregate operators and OP_NAME.
71 Consolidate Ada operators, using ada_forward_operator_length.
72 (ada_search_struct_field): Search in forward order.
73 (ADA_OPERATORS): Add new aggregate operators.
74 (ada_operator_length, ada_op_name, ada_forward_operator_length)
75 (ada_dump_subexp_body, ada_print_subexp): Handle new aggregate
76 operators and OP_NAME.
77 (ada_type_of_array): Use longest_to_int.
78 (value_assign_to_component): New function.
79 (ada_forward_operator_length, ada_op_name, ada_dump_subexp_body):
81 (ada_forward_operator_length, ada_dump_subexp_body):
84 * ada-lang.h (enum ada_operator): Add OP_AGGREGATE, OP_OTHERS,
85 OP_CHOICES, OP_DISCRETE_RANGE, OP_POSITIONAL.
87 2006-01-02 Paul N. Hilfinger <hilfinger@adacore.com>
89 * ada-lang.c (process_raise_exception_name): Remove extraneous
90 definition from unsubmitted code.
92 (is_lower_alphanum): New function.
93 (ada_decode): Add support for decoding protected object subprograms
94 and entries, and of entities declared inside protected object
96 Also add missing handling for__{DIGITS}+ suffixes.
97 Allow '$<digits>' as valid overloading suffix.
98 (is_name_suffix): Add handling for protected type entriy suffixes.
99 Also add support for protected type subprogram suffixes, but keep
100 it commented out for now, as there is an ambiguity between these
101 entities and other internally generated entities.
102 Allow '$<digits>' as valid overloading suffix.
103 (is_valid_name_for_wild_match): New function.
104 (wild_match): Add an exra level of verification of the entity name
105 before declaring it a match for the given pattern.
107 (ada_type_of_array, ada_evaluate_subexp): Use more proper
108 longest_to_int rather than cast.
110 (ada_evaluate_subexp): Use "invalid" rather than "illegal" in comment.
112 (ada_coerce_to_simple_array): Call check_size to make sure
113 that the object size is reasonable.
115 (ada_value_primitive_packed_val): Use correct location in target
116 buffer for extracting packed record fields that are themselves records.
118 (add_defn_to_vec): Do not try to replace a stub type by its full
119 type. Avoids a potential infinite loop.
121 (ada_lookup_symbol): Move return incorrectly placed return statement,
122 causing a loop that should be scanning all object files to only
125 (ada_tag_name_2): New function.
126 (ada_tag_name_1): If no 'tsd' field found in the dispatching table,
127 use alternative representation.
129 (ada_find_renaming_symbol): Strip the function name suffix when
130 computing the XR type name.
132 (ada_to_fixed_type): Try determining the tag only if we have the
134 (to_fixed_array_type): Add comments.
136 (ada_check_typedef): Replace expression checking whether the given
137 type is a stub or not by a "call" to TYPE_STUB. Clearer and more
140 * ada-lang.h (ADA_KNOWN_AUXILIARY_FUNCTION_NAME_PATTERNS): Allow
141 '$' in addition to '.' for runtime auxiliary function name suffixes.
142 See changes to ada_decode above.
144 (struct task_control_block): Add field called_task. (This change is
145 to keep synchronized with our local sources; it does not affect the
148 * ada-typeprint.c (ada_print_type): Use int_string for printing
149 modulus of modular type.
151 (print_range): Trivial editorial comment fix.
153 * ada-valprint.c (ada_emit_char): Use normal Ada syntax for
154 double quote in string.
156 2006-01-01 Joel Brobecker <brobecker@adacore.com>
158 * top.c: Add 2006 to list of copyright years in file header.
160 2006-01-01 Joel Brobecker <brobecker@adacore.com>
162 * top.c (print_gdb_version): Update copyright year to 2006.
164 2006-01-01 Roger Sayle <roger@eyesopen.com>
165 Elena Zannoni <ezannoni@redhat.com>
168 * xcoffread.c (xcoff_next_symbol_text): Check this_symtab_psymtab
169 for NULL before assigning this_symtab_psymtab->objfile to objfile.
170 (scan_xcoff_symtab): Initialize next_symbol_text_func.
171 (Committed by Jim Blandy)
173 For older changes see ChangeLog-2005.
179 version-control: never