C++ify xmethod_worker, get rid of VEC(xmethod_worker_ptr)
[external/binutils.git] / gdb / ChangeLog
1 2018-01-07  Simon Marchi  <simon.marchi@polymtl.ca>
2
3         * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
4         (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
5         <free_xmethod_worker_data>: Remove.
6         <get_matching_xmethod_workers>: Chance VEC to std::vector.
7         <get_xmethod_arg_types>: Remove.
8         <get_xmethod_result_type>: Remove.
9         <invoke_xmethod>: Remove.
10         * extension.c (new_xmethod_worker): Remove.
11         (clone_xmethod_worker): Remove.
12         (get_matching_xmethod_workers): Return void, pass std::vector by
13         pointer.
14         (get_xmethod_arg_types): Rename to...
15         (xmethod_worker::get_arg_types): ... this, and adjust.
16         (get_xmethod_result_type): Rename to...
17         (xmethod_worker::get_result_type): ... this, and adjust.
18         (invoke_xmethod): Remove.
19         (free_xmethod_worker): Remove.
20         (free_xmethod_worker_vec): Remove.
21         * extension.h (enum ext_lang_rc): Move here from
22         extension-priv.h.
23         (struct xmethod_worker): Add constructor and destructor.
24         <data>: Remove.
25         <value>: Remove.
26         <invoke, clone, do_get_result_type, do_get_arg_types>: New
27         virtual pure methods.
28         <get_arg_types, get_result_type>: New methods.
29         (xmethod_worker_ptr): Remove typedef.
30         (DEF_VEC_P (xmethod_worker_ptr)): Remove.
31         (xmethod_worker_vec): Remove typedef.
32         (xmethod_worker_up): New typedef.
33         (invoke_xmethod): Remove.
34         (clone_xmethod_worker): Remove.
35         (free_xmethod_worker): Remove.
36         (free_xmethod_worker_vec): Remove.
37         (get_xmethod_arg_types): Remove.
38         (get_xmethod_result_type): Remove.
39         * valops.c (find_method_list): Use std::vector, don't use
40         intermediate vector.
41         (value_find_oload_method_list): Use std::vector.
42         (find_overload_match): Use std::vector.
43         (find_oload_champ): Use std::vector.
44         * value.c (value_free): Use operator delete.
45         (value_of_xmethod): Rename to...
46         (value_from_xmethod): ... this.  Don't assign
47         xmethod_worker::value, take rvalue-reference.
48         (result_type_of_xmethod): Adjust.
49         (call_xmethod): Adjust.
50         * value.h: Include extension.h.
51         (struct xmethod_worker): Don't forward-declare.
52         (value_of_xmethod): Rename to...
53         (value_from_xmethod): ... this, take rvalue-reference.
54         * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
55         (struct python_xmethod_worker): ... this, add constructor and
56         destructor.
57         <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
58         (gdbpy_free_xmethod_worker_data): Rename to...
59         (python_xmethod_worker::~python_xmethod_worker): ... this and
60         adjust.
61         (gdbpy_clone_xmethod_worker_data): Rename to...
62         (python_xmethod_worker::clone): ... this and adjust.
63         (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
64         temporary vector.
65         (gdbpy_get_xmethod_arg_types): Rename to...
66         (python_xmethod_worker::do_get_arg_types): ... this and adjust.
67         (gdbpy_get_xmethod_result_type): Rename to...
68         (python_xmethod_worker::do_get_result_type): ... this and
69         adjust.
70         (gdbpy_invoke_xmethod): Rename to...
71         (python_xmethod_worker::invoke): ... this and adjust.
72         (new_python_xmethod_worker): Rename to...
73         (python_xmethod_worker::python_xmethod_worker): ... this and
74         adjust.
75         * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
76         Remove.
77         (gdbpy_free_xmethod_worker_data): Remove.
78         (gdbpy_get_matching_xmethod_workers): Use std::vector.
79         (gdbpy_get_xmethod_arg_types): Remove.
80         (gdbpy_get_xmethod_result_type): Remove.
81         (gdbpy_invoke_xmethod): Remove.
82         * python/python.c (python_extension_ops): Remove obsolete
83         callbacks.
84
85 2018-01-05  Pedro Alves  <palves@redhat.com>
86
87         PR gdb/18653
88         * common/signals-state-save-restore.c
89         (save_original_signals_state): New parameter 'quiet'.  Warn if we
90         find a custom handler preinstalled, instead of internal erroring.
91         But only warn if !quiet.
92         * common/signals-state-save-restore.h
93         (save_original_signals_state): New parameter 'quiet'.
94         * main.c (captured_main_1): Move save_original_signals_state call
95         after option handling, and pass QUIET.
96
97 2018-01-05  Pedro Alves  <palves@redhat.com>
98
99         * spu-tdep.c (spu_catch_start): Pass
100         symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
101
102 2018-01-05  Pedro Alves  <palves@redhat.com>
103
104         PR gdb/22670
105         * ada-lang.c (literal_symbol_name_matcher): New function.
106         (ada_get_symbol_name_matcher): Use it for
107         symbol_name_match_type::SEARCH_NAME.
108         * block.c (block_lookup_symbol): New parameter 'match_type'.  Pass
109         it down instead of assuming symbol_name_match_type::FULL.
110         * block.h (block_lookup_symbol): New parameter 'match_type'.
111         * c-valprint.c (print_unpacked_pointer): Use
112         lookup_symbol_search_name instead of lookup_symbol.
113         * compile/compile-object-load.c (get_out_value_type): Pass down
114         symbol_name_match_type::SEARCH_NAME.
115         * cp-namespace.c (cp_basic_lookup_symbol): Pass down
116         symbol_name_match_type::FULL.
117         * cp-support.c (cp_get_symbol_name_matcher): Handle
118         symbol_name_match_type::SEARCH_NAME.
119         * infrun.c (insert_exception_resume_breakpoint): Use
120         lookup_symbol_search_name.
121         * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
122         * psymtab.c (maintenance_check_psymtabs): Use
123         symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
124         * stack.c (print_frame_args): Use lookup_symbol_search_name and
125         SYMBOL_SEARCH_NAME.
126         * symtab.c (lookup_local_symbol): Don't demangle the lookup name
127         if symbol_name_match_type::SEARCH_NAME.
128         (lookup_symbol_in_language): Pass down
129         symbol_name_match_type::FULL.
130         (lookup_symbol_search_name): New.
131         (lookup_language_this): Pass down
132         symbol_name_match_type::SEARCH_NAME.
133         (lookup_symbol_aux, lookup_local_symbol): New parameter
134         'match_type'.  Pass it down.
135         * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
136         (lookup_symbol_search_name): New declaration.
137         (lookup_symbol_in_block): New 'match_type' parameter.
138
139 2018-01-05  Pedro Alves  <palves@redhat.com>
140
141         PR gdb/22670
142         * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
143         ada_lookup_symbol.
144         (ada_lookup_symbol): Reimplement in terms of
145         ada_lookup_symbol_list, bits factored out from
146         ada_lookup_encoded_symbol.
147
148 2018-01-05  Joel Brobecker  <brobecker@adacore.com>
149
150         * ada-exp.y (write_object_renaming): When subscripting an array
151         using a symbol as the index, pass the block in call to
152         ada_lookup_encoded_symbol when looking that symbol up.
153
154 2018-01-05  Jerome Guitton  <guitton@adacore.com>
155
156         * ada-lang.c (ada_array_length): Use ada_index_type instead of
157         TYPE_INDEX_TYPE.
158
159 2018-01-05  Joel Brobecker  <brobecker@adacore.com>
160
161         * ada-lang.c (ada_to_fixed_value_create): Add handling of
162         the case where VALUE_LVAL (val0) is not lval_memory.
163
164 2018-01-05  Xavier Roirand  <roirand@adacore.com>
165
166         * ada-valprint.c (print_optional_low_bound): Handle
167         character-indexed array printing like boolean-indexed array
168         printing.
169
170 2018-01-05  Joel Brobecker  <brobecker@adacore.com>
171
172         * NEWS: Create a new section for the next release branch.
173         Rename the section of the current branch, now that it has
174         been cut.
175
176 2018-01-05  Joel Brobecker  <brobecker@adacore.com>
177
178         GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
179         * version.in: Bump version to 8.1.50.DATE-git.
180
181 2018-01-03  Xavier Roirand  <roirand@adacore.com>
182
183         * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
184         Add field.
185         * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
186         Add field.
187         (default_exception_support_info) <catch_handlers_sym>: Add field.
188         (exception_support_info_fallback) <catch_handlers_sym>: Add field.
189         (ada_exception_name_addr_1): Add "catch handlers" handling.
190         (ada_exception_catchpoint_cond_string) <ex>: New parameter.
191         Update all callers.
192         (create_excep_cond_exprs) <ex>: Add parameter.
193         (re_set_exception): Update create_excep_cond_exprs call.
194         (print_it_exception, print_one_exception, print_mention_exception)
195         (print_recreate_exception): Add "catch handler" handling.
196         (allocate_location_catch_handlers, re_set_catch_handlers)
197         (check_status_catch_handlers, print_it_catch_handlers)
198         (print_one_catch_handlers, print_mention_catch_handlers)
199         (print_recreate_catch_handlers): New function.
200         (catch_handlers_breakpoint_ops): New variable.
201         (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
202         Add parameter.  Add "catch handler" handling.
203         (ada_exception_sym_name, ada_exception_breakpoint_ops):
204         Add "catch handler" handling.
205         (ada_exception_catchpoint_cond_string): Add "catch handler"
206         handling.
207         (create_ada_exception_catchpoint): Update create_excep_cond_exprs
208         call.
209         (catch_ada_handlers_command): New function.
210         (initialize_ada_catchpoint_ops): Initialize "catch handlers"
211         operations structure.
212         (_initialize_ada_language): Add "catch handlers" command entry.
213         * NEWS: Document "catch handlers" feature.
214
215 2018-01-02  Joel Brobecker  <brobecker@adacore.com>
216
217         * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
218         account when creating the array type of the slice.
219         (ada_value_slice): Likewise.
220
221 2018-01-02  Joel Brobecker  <brobecker@adacore.com>
222
223         * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
224         New enum value.
225         (create_array_type_with_stride): Add byte_stride_prop parameter.
226         * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
227         New parameter.  Update all callers in this file.
228         (array_type_has_dynamic_stride): New function.
229         (is_dynamic_type_internal, resolve_dynamic_array): Add handling
230         of arrays with dynamic byte strides.
231         * dwarf2read.c (read_array_type): Add support for dynamic
232         DW_AT_byte_stride attributes.
233
234 2018-01-02  Joel Brobecker  <brobecker@adacore.com>
235
236         * dwarf2read.c (read_unspecified_type): Treat
237         DW_TAG_enumeration_type DIEs from Ada units as stubs.
238
239 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
240
241         Update copyright year range in all GDB files.
242
243 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
244
245         * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
246         and gdb/testsuite/gdb.base/step-line.c.
247
248 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
249
250         * copyright.py (main): Dump the contents of
251         MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
252         even if BY_HAND is empty.
253
254 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
255
256         * top.c (print_gdb_version): Update Copyright year in version
257         message.
258
259 2018-01-01  Joel Brobecker  <brobecker@adacore.com>
260
261         * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
262
263 For older changes see ChangeLog-2017.
264 \f
265 Local Variables:
266 mode: change-log
267 left-margin: 8
268 fill-column: 74
269 version-control: never
270 coding: utf-8
271 End: