]>
Commit | Line | Data |
---|---|---|
b2ebd268 JJ |
1 | 2008-01-08 Jakub Jelinek <jakub@redhat.com> |
2 | ||
3 | PR c++/33890 | |
4 | * semantics.c (finish_omp_for): Don't call | |
5 | fold_build_cleanup_point_expr if processing_template_decl. | |
6 | ||
a9fe2f76 PC |
7 | 2008-01-04 Paolo Carlini <pcarlini@suse.de> |
8 | Jakub Jelinek <jakub@redhat.com> | |
9 | ||
10 | PR c++/34611 | |
11 | * error.c (dump_template_argument): Deal with TREE_LIST. | |
12 | ||
1a7817e4 DG |
13 | 2008-01-01 Douglas Gregor <doug.gregor@gmail.com> |
14 | ||
15 | * parser.c (cp_parser_check_decl_spec): Don't warn about "long | |
16 | long" in C++0x mode; change the warning to note that "long long" | |
17 | is only unsupported in C++98 mode. | |
18 | ||
4c12c8ea JM |
19 | 2007-12-20 Jason Merrill <jason@redhat.com> |
20 | ||
21 | PR c++/34111 | |
22 | * call.c (standard_conversion): Derived-to-base is considered a | |
23 | standard conversion. | |
24 | ||
5259c813 JJ |
25 | 2007-12-19 Jakub Jelinek <jakub@redhat.com> |
26 | ||
27 | PR c++/34513 | |
28 | * parser.c (cp_parser_omp_parallel): For non-combined parallel | |
29 | call cp_parser_statement rather than | |
30 | cp_parser_already_scoped_statement. | |
31 | ||
82390eb6 JM |
32 | 2007-12-18 Jason Merrill <jason@redhat.com> |
33 | ||
34 | PR c++/34206 | |
35 | * pt.c (tsubst_aggr_type): Do nothing if the type already doesn't | |
36 | use template parms. | |
37 | (dependent_type_p_r): Handle the domain of an array. | |
38 | ||
a15c0b00 DG |
39 | 2007-12-18 Douglas Gregor <doug.gregor@gmail.com> |
40 | Jakub Jelinek <jakub@redhat.com> | |
41 | ||
42 | PR c++/32565 | |
43 | PR c++/33943 | |
44 | PR c++/33965 | |
45 | * pt.c (template_template_parm_bindings_ok_p): New; verifies | |
46 | bindings of template template parameters after all template | |
47 | arguments have been deduced. | |
48 | (coerce_template_parms): Don't complain when COMPLAIN doesn't | |
49 | include tf_error. | |
50 | (fn_type_unification): Use template_template_parm_bindings_ok_p. | |
51 | (unify): Deal with variadic, bound template template parameters. | |
52 | (get_class_bindings): Use template_template_parm_bindings_ok_p. | |
53 | ||
ac3b1156 JJ |
54 | 2007-12-18 Jakub Jelinek <jakub@redhat.com> |
55 | ||
56 | PR c++/34488 | |
57 | * decl.c (grokdeclarator): Reject friend sfk_constructor | |
58 | FUNCTION_TYPE. | |
59 | ||
8085ca15 JJ |
60 | 2007-12-17 Jakub Jelinek <jakub@redhat.com> |
61 | ||
62 | PR c/34506 | |
63 | * parser.c (cp_parser_omp_all_clauses): Accept optional comma | |
64 | in between clauses. | |
65 | ||
394d9fe7 AO |
66 | 2007-12-15 Alexandre Oliva <aoliva@redhat.com> |
67 | ||
68 | PR debug/7081 | |
69 | * cp-lang.c (cp_classify_record): New. | |
70 | (LANG_HOOKS_CLASSIFY_RECORD): Override. | |
71 | ||
61a861e6 JJ |
72 | 2007-12-11 Jakub Jelinek <jakub@redhat.com> |
73 | ||
5b767b9d JJ |
74 | PR c++/34238 |
75 | * decl2.c (cp_write_global_declarations): Revert 2007-11-22 change. | |
76 | ||
61a861e6 JJ |
77 | PR c++/34364 |
78 | * rtti.c (build_dynamic_cast): Call convert_from_reference even for | |
79 | dynamic_cast in a template. | |
80 | ||
0197270c SM |
81 | 2007-12-10 Simon Martin <simartin@users.sourceforge.net> |
82 | ||
83 | PR c++/34059 | |
84 | * typeck.c (build_class_member_access_expr): Compute MEMBER_SCOPE from | |
85 | MEMBER's BASELINK_ACCESS_BINFO instead of its BASELINK_BINFO. | |
86 | ||
214452b9 JJ |
87 | 2007-12-10 Jakub Jelinek <jakub@redhat.com> |
88 | ||
e7de2d6f JJ |
89 | PR c++/34395 |
90 | * error.c (dump_type_prefix, dump_type_suffix): Handle | |
91 | TYPE_PACK_EXPANSION. | |
92 | ||
214452b9 JJ |
93 | PR c++/34394 |
94 | * error.c (dump_expr): Handle ABS_EXPR. | |
95 | ||
23372b3f JJ |
96 | 2007-12-09 Jakub Jelinek <jakub@redhat.com> |
97 | ||
98 | PR c++/34178 | |
99 | PR c++/34340 | |
100 | * repo.c (repo_emit_p): Return 2 for DECL_INTEGRAL_CONSTANT_VAR_P | |
101 | in class scope rather than DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P. | |
102 | Return 2 also if DECL_EXPLICIT_INSTANTIATION. | |
103 | * decl2.c (import_export_decl): Don't make VAR_DECLs import_p when | |
104 | flag_use_repository and repo_emit_p returned 2. | |
105 | ||
28267cfc JJ |
106 | 2007-12-06 Jakub Jelinek <jakub@redhat.com> |
107 | ||
108 | PR c++/34336 | |
109 | * tree.c (stabilize_call, stabilize_init): Do nothing if | |
110 | processing_template_decl. | |
111 | ||
91929b4d JJ |
112 | 2007-12-05 Jakub Jelinek <jakub@redhat.com> |
113 | ||
114 | PR c++/34271 | |
115 | * semantics.c (finish_decltype_type): For SCOPE_REF issue an | |
116 | error instead of assertion failure. | |
117 | * parser.c (cp_parser_decltype): If closing paren is not found, | |
118 | return error_mark_node. | |
119 | ||
ba796308 DG |
120 | 2007-12-04 Douglas Gregor <doug.gregor@gmail.com> |
121 | ||
122 | PR c++/34101 | |
123 | * name-lookup.c (arg_assoc_template_arg): Recurse on argument | |
124 | packs. | |
125 | (arg_assoc_type): We don't need to handle TYPE_ARGUMENT_PACK here, | |
126 | since arg_assoc_template_arg will deal with them (better). | |
127 | ||
2f93f02c DG |
128 | 2007-12-04 Douglas Gregor <doug.gregor@gmail.com> |
129 | ||
130 | PR c++/33509 | |
131 | * pt.c (tsubst_exception_specification): Handle substitutions into | |
132 | member templates, where tsubst_pack_expansion returns a | |
133 | TYPE_PACK_EXPANSION. | |
134 | ||
db60ff18 DG |
135 | 2007-12-04 Douglas Gregor <doug.gregor@gmail.com> |
136 | ||
137 | PR c++/33091 | |
138 | * pt.c (unify_pack_expansion): If we didn't deduce any actual | |
139 | bindings for the template parameter pack, don't try to keep the | |
140 | empty deduced arguments. | |
141 | (unify): If a parameter is a template-id whose template argument | |
142 | list contains a pack expansion that is not at the end, then we | |
143 | cannot unify against that template-id. | |
144 | ||
0b93f014 PC |
145 | 2007-12-02 Paolo Carlini <pcarlini@suse.de> |
146 | ||
147 | PR c++/34061 | |
148 | * pt.c (current_template_args): Use error_operand_p. | |
149 | ||
06be4f56 PC |
150 | 2007-12-02 Paolo Carlini <pcarlini@suse.de> |
151 | ||
152 | PR c++/34273 | |
153 | * error.c (dump_decl): Handle TREE_BINFO. | |
154 | ||
867f133e OW |
155 | 2007-12-01 Ollie Wild <aaw@google.com> |
156 | ||
157 | PR c++/8171 | |
158 | * typeck.c (build_binary_op): Add conversion of pointers to function | |
159 | members appearing as operands to the equality operators. | |
160 | ||
89ab8ba0 JJ |
161 | 2007-11-30 Jakub Jelinek <jakub@redhat.com> |
162 | ||
163 | PR c++/34275 | |
164 | * error.c (dump_expr): Handle OBJ_TYPE_REF. | |
165 | ||
7a547b93 JJ |
166 | 2007-11-29 Jakub Jelinek <jakub@redhat.com> |
167 | ||
42924ed7 JJ |
168 | PR c++/34270 |
169 | * tree.c (lvalue_p_1) <case COND_EXPR>: Handle x ?: y | |
170 | in templates. | |
171 | * typeck.c (is_bitfield_expr_with_lowered_type) <case COND_EXPR>: | |
172 | Likewise. | |
173 | ||
7a547b93 JJ |
174 | PR c++/34267 |
175 | PR c++/34268 | |
176 | * parser.c (cp_parser_decltype): Don't call finish_id_expression | |
177 | on ~type. | |
178 | * semantics.c (finish_decltype_type): Issue error on types, TYPE_DECLs | |
179 | and ~type early. | |
180 | ||
ce41114b JJ |
181 | 2007-11-27 Jakub Jelinek <jakub@redhat.com> |
182 | ||
62cbbe84 JJ |
183 | PR tree-optimization/34181 |
184 | * method.c (use_thunk): Don't inline the call in the thunk. | |
185 | ||
ce41114b JJ |
186 | PR c++/34213 |
187 | * tree.c (decl_linkage): Static data members and static member | |
188 | functions in anonymous ns classes are lk_external. | |
189 | ||
182e0d71 AK |
190 | 2007-11-26 Andreas Krebbel <krebbel1@de.ibm.com> |
191 | ||
ce41114b | 192 | PR c++/34081 |
182e0d71 AK |
193 | * decl.c (start_preparsed_function): Pass |
194 | processing_template_decl for the new allocate_struct_function | |
195 | parameter. | |
196 | ||
87caf699 RG |
197 | 2007-11-25 Richard Guenther <rguenther@suse.de> |
198 | ||
42924ed7 | 199 | * decl.c (poplevel): Use BLOCK_CHAIN. |
87caf699 | 200 | |
a298680c OW |
201 | 2007-11-24 Ollie Wild <aaw@google.com> |
202 | ||
203 | * typeck.c (delta_from_ptrmemfunc): New function. | |
204 | (get_member_function_from_ptrfunc): Call delta_from_ptrmemfunc. | |
205 | (build_binary_op): Call delta_from_ptrmemfunc. | |
206 | ||
360f866c JJ |
207 | 2007-11-23 Jakub Jelinek <jakub@redhat.com> |
208 | ||
209 | PR c++/30293 | |
210 | PR c++/30294 | |
211 | * decl.c (cp_finish_decl): Disallow variable or field | |
212 | definitions if extern "Java" aggregates. | |
213 | (grokparms): Disallow parameters with extern "Java" | |
214 | aggregates. | |
215 | (check_function_type): Disallow function return values | |
216 | with extern "Java" aggregates. | |
217 | * init.c (build_new_1): Disallow placement new with | |
218 | extern "Java" aggregates. | |
219 | ||
6ca39fcb MM |
220 | 2007-11-23 Mark Mitchell <mark@codesourcery.com> |
221 | Manuel Lopez-Ibanez <manu@gcc.gnu.org> | |
222 | ||
223 | PR c++/5310 | |
224 | * call.c (convert_like_real): Build a zero constant when __null is | |
225 | converted to an integer type. | |
226 | ||
6d1f904c JJ |
227 | 2007-11-22 Jakub Jelinek <jakub@redhat.com> |
228 | ||
229 | PR c++/34094 | |
230 | * decl2.c (cp_write_global_declarations): Issue error about static | |
231 | data members in anonymous namespace which are declared and used, | |
232 | but not defined. | |
233 | ||
63d34078 JJ |
234 | 2007-11-20 Jakub Jelinek <jakub@redhat.com> |
235 | ||
542f8eb9 JJ |
236 | PR c++/34089 |
237 | * parser.c (cp_parser_class_head): Reject function template ids. | |
238 | ||
6da06848 JJ |
239 | PR c++/28879 |
240 | * tree.c (build_cplus_array_type_1): Don't pass any VLA types | |
241 | when processing_template_decl to build_array_type. | |
242 | ||
63d34078 JJ |
243 | PR c++/33962 |
244 | * pt.c (more_specialized_fn): Don't segfault if one or | |
245 | both argument list end with ellipsis. | |
246 | ||
be461b8f JJ |
247 | 2007-11-18 Jakub Jelinek <jakub@redhat.com> |
248 | ||
249 | PR c++/30988 | |
6c01f02b JJ |
250 | * semantics.c (finish_call_expr): Set |
251 | current_function_returns_abnormally if fn is noreturn FUNCTION_DECL | |
252 | or OVERLOAD with all noreturn functions. | |
be461b8f | 253 | |
823e5f7f JJ |
254 | 2007-11-16 Jakub Jelinek <jakub@redhat.com> |
255 | ||
256 | PR c++/34100 | |
257 | * pt.c (apply_late_template_attributes): Do nothing if decl's type is | |
258 | error_mark_node. | |
259 | ||
ffbf5813 JJ |
260 | 2007-11-13 Jakub Jelinek <jakub@redhat.com> |
261 | ||
046e4071 JJ |
262 | PR c++/34054 |
263 | PR c++/34056 | |
264 | PR c++/34057 | |
265 | PR c++/34058 | |
266 | PR c++/34060 | |
267 | * pt.c (find_parameter_packs_r): If ppd->set_packs_to_error, | |
268 | set to error_mark_node the outermost POINTER_TYPE to the pack if | |
269 | it is seen in a POINTER_TYPE. | |
270 | (push_template_decl_real): If check_for_bare_parameter_packs | |
271 | fails for function return type, set the return type to | |
272 | integer_type_node. If check_for_bare_parameter_packs failed | |
273 | for non-function, return error_mark_node. | |
274 | ||
ffbf5813 JJ |
275 | PR c++/29225 |
276 | * call.c (build_new_op): Call resolve_args before calling | |
277 | build_over_call. | |
278 | ||
f1e20710 TT |
279 | 2007-11-11 Tom Tromey <tromey@redhat.com> |
280 | ||
281 | PR c++/17577: | |
282 | * lex.c (handle_pragma_implementation): Use cpp_included_before. | |
283 | ||
b131ad7c MLI |
284 | 2007-11-12 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
285 | ||
286 | PR c++/8570 | |
287 | * pt.c (redeclare_class_template): Update error message. Use a | |
288 | note to show the previous declaration. | |
289 | (tsubst_friend_class): Use the location of the friend template as | |
290 | the input location before calling redeclare_class_template. | |
291 | ||
09b1ccd6 JJ |
292 | 2007-11-11 Jakub Jelinek <jakub@redhat.com> |
293 | ||
294 | PR c++/34068 | |
295 | * semantics.c (finish_pseudo_destructor_expr): Handle | |
296 | object == error_mark_node. | |
297 | ||
3d9b2eb6 JJ |
298 | 2007-11-10 Jakub Jelinek <jakub@redhat.com> |
299 | ||
300 | PR c++/32241 | |
301 | * pt.c (tsubst_copy_and_build) <case COMPONENT_REF>: If object_type | |
302 | is not scalar type, let finish_class_member_access_expr handle | |
303 | diagnostics. Pass BIT_NOT_EXPR argument to | |
304 | finish_pseudo_destructor_expr. Handle SCOPE_REF properly. | |
305 | ||
49b5e2f6 DG |
306 | 2007-11-09 Douglas Gregor <doug.gregor@gmail.com> |
307 | ||
308 | PR c++/33510 | |
309 | * decl.c (cp_complete_array_type): If any of the initializer | |
310 | elements are pack expansions, don't compute the array size yet. | |
311 | ||
c02cdc25 TT |
312 | 2007-11-08 Andrew Pinski <pinskia@gmail.com> |
313 | ||
314 | PR c++/30297: | |
315 | * tree.c (decl_linkage): Fields have no linkage. | |
316 | ||
8208d7dc DJ |
317 | 2007-11-08 Daniel Jacobowitz <dan@codesourcery.com> |
318 | ||
319 | * class.c (build_ctor_vtbl_group): Lay out the new type and decl. | |
320 | ||
e4fd5b87 DG |
321 | 2007-11-07 Douglas Gregor <doug.gregor@gmail.com> |
322 | ||
323 | PR c++/33045 | |
324 | PR c++/33837 | |
325 | PR c++/33838 | |
326 | * semantics.c (finish_decltype_type): See through INDIRECT_REFs. | |
327 | Be careful with ERROR_MARK_NODEs. | |
328 | * parser.c (cp_parser_check_access_in_redeclaration): Handle NULL | |
329 | argument. | |
330 | ||
2811f33d JJ |
331 | 2007-11-07 Jakub Jelinek <jakub@redhat.com> |
332 | ||
333 | PR c++/33501 | |
334 | * call.c (build_over_call): Don't check TREE_ADDRESSABLE | |
335 | on incomplete type. | |
336 | ||
9ae165a0 DG |
337 | 2007-11-06 Douglas Gregor <doug.gregor@gmail.com> |
338 | ||
339 | PR c++/33977 | |
340 | PR c++/33886 | |
341 | * tree.c (c_build_qualified_type): Define bridge to | |
342 | cp_build_qualified_type. | |
343 | ||
1ad8aeeb DG |
344 | 2007-11-06 Douglas Gregor <doug.gregor@gmail.com> |
345 | ||
346 | PR c++/31439 | |
347 | PR c++/32114 | |
348 | PR c++/32115 | |
349 | PR c++/32125 | |
350 | PR c++/32126 | |
351 | PR c++/32127 | |
352 | PR c++/32128 | |
353 | PR c++/32253 | |
354 | PR c++/32566 | |
355 | * typeck.c (check_return_expr): Pass address of retval to | |
356 | check_for_bare_parameter_packs. | |
357 | * class.c (build_base_field): Tolerate bases that have no layout | |
358 | due to errors. | |
359 | (end_of_base): Ditto. | |
360 | * tree.c (canonical_type_variant): Be careful with | |
361 | ERROR_MARK_NODE. | |
362 | * cp-tree.h (check_for_bare_parameter_packs): Now accepts a | |
363 | tree*. | |
364 | * pt.c (find_parameter_pack_data): Add set_packs_to_error field, | |
365 | which states whether parameter packs should be replaced with | |
366 | ERROR_MARK_NODE. | |
367 | (find_parameter_packs_r): Pass addresses to cp_walk_tree wherever | |
368 | possible. If set_packs_to_error is set true, replace the parameter | |
369 | pack with ERROR_MARK_NODE. Manage our own pointer sets. | |
370 | (uses_parameter_packs): Don't set parameter packs to | |
371 | ERROR_MARK_NODE. | |
372 | (check_for_bare_parameter_packs): Now takes a pointer to a tree, | |
373 | which may be modified (if it is a parameter pack). Instructs | |
374 | find_parameter_packs_r to replace parameter packs with | |
375 | ERROR_MARK_NODE (so that they won't cause errors later on). | |
376 | (process_template_parm): Pass pointer to | |
377 | check_for_bare_parameter_packs. | |
378 | (process_partial_specialization): Replace pack expansions before | |
379 | the end of the template argument list with ERROR_MARK_NODE. | |
380 | (push_template_decl_real): Pass pointer to | |
381 | check_for_bare_parameter_packs. Replace parameter packs not at the | |
382 | end of the template parameter list with ERROR_MARK_NODE. | |
383 | (convert_template_argument): Be more careful about using DECL_NAME | |
384 | on only declarations. | |
385 | (unify): Can't unify against ERROR_MARK_NODE. | |
386 | * semantics.c (finish_cond): Pass pointer to | |
387 | check_for_bare_parameter_packs. | |
388 | (finish_expr_stmt): Ditto. | |
389 | (finish_for_expr): Ditto. | |
390 | (finish_switch_cond): Pass pointer to | |
391 | check_for_bare_parameter_packs, and call it before we put the | |
392 | condition into the statement. | |
393 | (finish_mem_initializers): Pass pointer to | |
394 | check_for_bare_parameter_packs. | |
395 | (finish_member_declaration): Ditto. | |
396 | * parser.c (cp_parser_base_clause): Ditto. | |
397 | ||
239371f9 JJ |
398 | 2007-11-06 Jakub Jelinek <jakub@redhat.com> |
399 | ||
b0eb6a8f JJ |
400 | PR target/33168 |
401 | * decl.c (cp_finish_decl): Call make_rtl_for_nonlocal_decl already | |
402 | with the final TREE_READONLY flag in place. processing_template_decl | |
403 | is known to be 0 in this part of function. | |
404 | ||
239371f9 JJ |
405 | PR c++/33894 |
406 | * cp-tree.h: Update comment - TYPE_LANG_FLAG_0 is not | |
407 | OMP_ATOMIC_DEPENDENT_P in OMP_ATOMIC. | |
408 | * pt.c (tsubst_expr): Assert OMP_ATOMIC_DEPENDENT_P. | |
409 | * semantics.c (finish_omp_atomic): Revert most of the | |
410 | 2007-02-05 changes, just keep the new representation of | |
411 | OMP_ATOMIC_DEPENDENT_P OMP_ATOMIC. | |
412 | ||
565603f8 L |
413 | 2007-11-05 H.J. Lu <hongjiu.lu@intel.com> |
414 | ||
415 | PR c++/33871 | |
416 | * decl2.c (constrain_visibility): Clear DECL_ONE_ONLY if marked | |
417 | local. | |
418 | ||
86089be5 DG |
419 | 2007-11-05 Douglas Gregor <doug.gregor@gmail.com> |
420 | ||
421 | PR c++/33996 | |
422 | PR c++/33235 | |
423 | PR c++/33930 | |
424 | * typeck.c (merge_types): Don't lose rvalue references when | |
425 | merging types. | |
426 | * call.c (build_over_call): Don't elide move constructors just | |
427 | because the copy constructor is trivial (!). | |
428 | (compare_ics): If comparing cv-qualifiers fails, we can still order | |
429 | based on binding lvalues vs. rvalues. | |
430 | ||
2afad0f6 DG |
431 | 2007-11-05 Douglas Gregor <doug.gregor@gmail.com> |
432 | ||
433 | PR c++/33939 | |
434 | * pt.c (unify_pack_expansion): bring handling of function call | |
435 | arguments into line with type_unification_real. | |
436 | ||
278b63df MLI |
437 | 2007-11-05 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
438 | ||
439 | * typeck.c (build_binary_op): Use pedwarn instead of error for | |
440 | consistency. | |
441 | ||
1b021ff4 JJ |
442 | 2007-11-05 Jakub Jelinek <jakub@redhat.com> |
443 | ||
f370e66b JJ |
444 | PR c++/33836 |
445 | * parser.c (cp_parser_unary_expression): For &&label call | |
446 | cp_parser_non_integral_constant_expression and return error_mark_node | |
447 | if it returned true. | |
448 | ||
1b021ff4 JJ |
449 | PR c++/33969 |
450 | * decl.c (grokdeclarator): Don't call build_memfn_type if type | |
451 | is neither FUNCTION_TYPE nor METHOD_TYPE. | |
452 | ||
eba5fc70 JJ |
453 | 2007-11-02 Jakub Jelinek <jakub@redhat.com> |
454 | ||
455 | PR c++/33516 | |
456 | * parser.c (cp_parser_nested_name_specifier_opt): Use | |
457 | TYPE_MAIN_VARIANT (new_scope) as scope if new_scope is an incomplete | |
458 | typedef of currently open class. | |
459 | ||
10a6624a PC |
460 | 2007-11-02 Paolo Carlini <pcarlini@suse.de> |
461 | ||
462 | PR c++/33495 | |
463 | * error.c (dump_expr): Deal specially with statements. | |
464 | ||
ef3b7b17 JM |
465 | 2007-11-01 Jason Merrill <jason@redhat.com> |
466 | ||
467 | PR c++/30897 | |
468 | * pt.c (push_template_decl_real): Set DECL_CONTEXT on template | |
469 | template parms. | |
470 | (lookup_template_class): Use it to get the outer template args | |
471 | for instantiating one. | |
472 | ||
473 | PR c++/29236 | |
474 | * pt.c (reduce_template_parm_level): tsubst the parameters | |
475 | of a template template parm. | |
476 | ||
e1a18c68 DG |
477 | 2007-11-01 Douglas Gregor <doug.gregor@gmail.com> |
478 | ||
479 | PR c++/33955 | |
480 | * pt.c (find_parameter_packs_r): Handle TYPENAME_TYPE. | |
481 | ||
3a44f395 JJ |
482 | 2007-11-01 Jakub Jelinek <jakub@redhat.com> |
483 | ||
e426bd2c JJ |
484 | PR c++/32384 |
485 | * parser.c (cp_parser_postfix_dot_deref_expression): If | |
486 | POSTFIX_EXPRESSION is type dependent, try to parse it as pseudo dtor | |
487 | first and if that succeeds and type is SCALAR_TYPE_P, create | |
488 | PSEUDO_DTOR_EXPR. | |
489 | ||
3a44f395 JJ |
490 | PR c++/32260 |
491 | * rtti.c (enum_tinfo_kind): Fix TK_TYPE_INFO_TYPE comment. | |
492 | (typeid_ok_p): Use the same alias set for abi::__type_info_pseudo | |
493 | as for std::type_info. | |
494 | ||
066f956c PC |
495 | 2007-10-31 Paolo Carlini <pcarlini@suse.de> |
496 | ||
497 | PR c++/33494 | |
498 | * cxx-pretty-print.c (pp_cxx_typeid_expression, | |
499 | pp_cxx_delete_expression): Change to static linkage. | |
500 | * cxx-pretty-print.h: Adjust declarations. | |
501 | * error.c (dump_expr, case EXPR_PACK_EXPANSION, TYPEID_EXPR, | |
502 | MEMBER_REF, DOTSTAR_EXPR, DELETE_EXPR, VEC_DELETE_EXPR, | |
503 | MODOP_EXPR): Forward to pp_expression. | |
504 | ||
505 | * cxx-pretty-print.c (pp_cxx_expression, case NON_DEPENDENT_EXPR): | |
506 | Fix typo. | |
507 | ||
0e95aec1 CB |
508 | 2007-10-31 Christian Bruel <christian.bruel@st.com> |
509 | Mark Mitchell <mark@codesourcery.com> | |
510 | ||
511 | PR c++/19531 | |
ef3b7b17 | 512 | * typeck.c (check_return_expr): Don't set named_return_value_okay_p |
0e95aec1 CB |
513 | if retval is volatile. |
514 | ||
4c38e99e JJ |
515 | 2007-10-30 Jakub Jelinek <jakub@redhat.com> |
516 | ||
517 | PR c++/33616 | |
518 | * decl2.c (build_offset_ref_call_from_tree): Call | |
519 | build_non_dependent_expr on object prior to building ADDR_EXPR from it | |
520 | if FN is DOTSTAR_EXPR. | |
521 | ||
88b82314 DG |
522 | 2007-10-30 Douglas Gregor <doug.gregor@gmail.com> |
523 | ||
524 | PR c++/31993 | |
525 | PR c++/32252 | |
526 | * pt.c (find_parameter_packs_r): Fix typo in comment. | |
527 | (convert_template_argument): Look at the pattern of a pack | |
528 | expansion to determine what kind of entity we're converting. | |
529 | (coerce_template_parameter_pack): When we have coerced a non-type | |
530 | template parameter pack, substitute into the type of that pack. | |
531 | (tsubst_pack_expansion): When our substitution of a parameter pack | |
532 | is a "trivial" substitution of itself, just substitute into the | |
533 | pack expansion rather than actually expanding. | |
534 | ||
e7df0180 JJ |
535 | 2007-10-29 Jakub Jelinek <jakub@redhat.com> |
536 | ||
537 | PR c++/33841 | |
538 | * class.c (check_bitfield_decl): Don't set field's type to error_mark_node | |
539 | for non-integral type bitfields. Return true if bitfield is correct, false | |
540 | error has been diagnosed. | |
541 | (check_field_decls): If check_bitfield_decl returned false, call also | |
542 | check_field_decl. | |
543 | ||
8259e4f5 PC |
544 | 2007-10-28 Paolo Carlini <pcarlini@suse.de> |
545 | Mark Mitchell <mark@codesourcery.com> | |
546 | ||
547 | PR c++/30659 | |
548 | * pt.c (do_decl_instantiation): If the VAR_DECL is not a | |
549 | class member error out and return. | |
550 | ||
1e3eacc7 JJ |
551 | 2007-10-27 Jakub Jelinek <jakub@redhat.com> |
552 | ||
d5aa2cf0 JJ |
553 | * error.c (reinit_cxx_pp): Initialize cxx_pp->enclosing_scope |
554 | to current_function_decl rather than 0. | |
555 | ||
1e3eacc7 JJ |
556 | PR c++/33844 |
557 | * cxx-pretty-print.c (pp_cxx_pm_expression) <case MEMBER_REF>: Print | |
558 | ->* rather than .*. | |
559 | * error.c (dump_expr): Handle MEMBER_REF and DOTSTAR_EXPR. | |
560 | ||
d02dbde6 JM |
561 | 2007-10-27 Jason Merrill <jason@redhat.com> |
562 | ||
563 | PR c++/5247 | |
564 | * call.c (convert_default_arg): Detect recursion. | |
565 | ||
094a5fe2 JJ |
566 | 2007-10-27 Jakub Jelinek <jakub@redhat.com> |
567 | ||
568 | PR c++/33842 | |
569 | * cxx-pretty-print.h (pp_cxx_offsetof_expression): New prototype. | |
570 | * cxx-pretty-print.c (pp_cxx_primary_expression): Handle | |
571 | OFFSETOF_EXPR. | |
572 | (pp_cxx_offsetof_expression_1, pp_cxx_offsetof_expression): New | |
573 | functions. | |
574 | * error.c (dump_expr): Handle OFFSETOF_EXPR. | |
575 | ||
91a77d68 JM |
576 | 2007-10-26 Jason Merrill <jason@redhat.com> |
577 | ||
578 | PR c++/24791 | |
579 | * pt.c (get_template_info): New fn. | |
580 | (template_class_depth): Use it. | |
581 | (push_template_decl_real): Check that the template args of the | |
582 | definition match the args of the previous declaration. | |
583 | ||
07021f8c PC |
584 | 2007-10-26 Paolo Carlini <pcarlini@suse.de> |
585 | ||
586 | PR c++/31988 | |
587 | * decl2.c (coerce_new_type): Do not allow a default argument for | |
588 | the first parameter. | |
589 | ||
2b536806 DG |
590 | 2007-10-26 Douglas Gregor <doug.gregor@gmail.com> |
591 | ||
592 | PR c++/33839 | |
593 | * parser.c (cp_parser_decltype): Return ERROR_MARK_NODE if we | |
594 | don't see the leading '('. Only lookup names if we get an | |
595 | IDENTIFIER_NODE. | |
596 | ||
0f1e3321 JJ |
597 | 2007-10-26 Jakub Jelinek <jakub@redhat.com> |
598 | ||
599 | PR c++/33744 | |
600 | * parser.c (cp_parser_parenthesized_expression_list): Set | |
601 | greater_than_is_operator_p to true in between the parens. | |
602 | ||
9b70c6b0 PC |
603 | 2007-10-26 Paolo Carlini <pcarlini@suse.de> |
604 | ||
605 | PR c++/31747 | |
606 | * decl.c (grokdeclarator): In case of conflicting specifiers | |
607 | just return error_mark_node. | |
608 | ||
3459ca23 OW |
609 | 2007-10-26 Ollie Wild <aaw@google.com> |
610 | ||
611 | * expr.c (cxx_expand_expr): Removed. | |
612 | * cp-tree.h (exx_expand_expr): Removed. | |
613 | * cp-objcp-common.h (LANK_HOOKS_EXPAND_EXPR): Replace cxx_expand_expr | |
614 | with c_expand_expr. | |
615 | ||
6735e374 PC |
616 | 2007-10-25 Paolo Carlini <pcarlini@suse.de> |
617 | ||
618 | PR c++/33843 | |
619 | * cxx-pretty-print.c (pp_cxx_unqualified_id): Deal with BIT_NOT_EXPR. | |
620 | ||
6f4fd536 JM |
621 | 2007-10-23 Jason Merrill <jason@redhat.com> |
622 | ||
623 | PR c++/25950 (DR 391) | |
624 | * call.c (struct conversion): Remove check_copy_constructor_p. | |
625 | (reference_binding): Always bind a reference directly to a | |
626 | compatible class rvalue. Pass down LOOKUP_NO_TEMP_BIND during | |
627 | temporary creation. | |
628 | (check_constructor_callable): Remove. | |
629 | (convert_like_real): Don't call it. | |
630 | (initialize_reference): Don't call check_constructor_callable. | |
631 | (standard_conversion): Check LOOKUP_NO_CONVERSION instead of | |
632 | LOOKUP_CONSTRUCTOR_CALLABLE. Don't require a temporary for base | |
633 | conversions if LOOKUP_NO_TEMP_BIND. | |
634 | (implicit_conversion): Pass through LOOKUP_NO_TEMP_BIND. | |
635 | (build_user_type_conversion_1): Pass through LOOKUP_NO_TEMP_BIND for | |
636 | second conversion. | |
637 | * cp-tree.h (LOOKUP_CONSTRUCTOR_CALLABLE): Remove. | |
638 | ||
6e684eee JJ |
639 | 2007-10-22 Jakub Jelinek <jakub@redhat.com> |
640 | ||
641 | PR c++/33372 | |
642 | * semantics.c (finish_omp_clauses): Check !type_dependent_expression_p | |
643 | before checking if its type is integral. | |
644 | ||
5818c8e4 JM |
645 | 2007-10-22 Jason Merrill <jason@redhat.com> |
646 | ||
647 | PR c++/33620 | |
648 | * class.c (finish_struct_bits): Copy TYPE_ATTRIBUTES. | |
649 | * pt.c (apply_late_template_attributes): Splice out dependent | |
650 | attributes from DECL_ATTRIBUTES. | |
651 | ||
652 | * decl.c (cxx_maybe_build_cleanup): Use build_address. | |
653 | ||
c5409249 MLI |
654 | 2007-10-17 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
655 | ||
656 | * typeck.c (build_binary_op) : Use appropriate warning option | |
657 | instead of unnamed warning. | |
658 | ||
bf98d3b6 PC |
659 | 2007-10-16 Paolo Carlini <pcarlini@suse.de> |
660 | ||
661 | PR c++/31446 | |
662 | * pt.c (current_template_args): Do not change TREE_LIST elements | |
663 | with a TREE_VALUE of error_mark_node. | |
664 | ||
15896502 MM |
665 | 2007-10-16 Mark Mitchell <mark@codesourcery.com> |
666 | ||
667 | * typeck.c (cp_apply_type_quals_to_decl): Expand documentation. | |
668 | * decl.c (start_decl): Tidy. | |
669 | (start_decl_1): Call cp_apply_type_quals_to_decl after completing | |
670 | the type. | |
671 | (grokdeclarator): Clarify comment. | |
672 | ||
db160137 AP |
673 | 2007-10-14 Andrew Pinski <pinskia@gmail.com> |
674 | ||
675 | PR c++/30303 | |
676 | * decl.c (grokfndecl): Return NULL after the "definition of | |
677 | implicitly-declared" error happened. | |
678 | ||
a9a81e7d SM |
679 | 2007-10-12 Simon Martin <simartin@users.sourceforge.net> |
680 | ||
681 | PR c++/26698 | |
682 | * call.c (build_user_type_conversion_1): Do not consider conversion | |
683 | functions to convert a (possibly cv-qualified) object to the (possibly | |
684 | cv-qualified) same object type (or a reference to it), to a (possibly | |
685 | cv-qualified) base class of that type (or a reference to it). | |
686 | ||
f4205442 PC |
687 | 2007-10-12 Paolo Carlini <pcarlini@suse.de> |
688 | ||
689 | * pt.c (tsubst): Use template_parm_level_and_index. | |
690 | ||
3d3585eb JJ |
691 | 2007-10-12 Jakub Jelinek <jakub@redhat.com> |
692 | ||
693 | PR c++/32121 | |
694 | * parser.c (cp_parser_compound_statement): Handle label-declarations | |
695 | at the beginning of the compound statement. | |
696 | (cp_parser_block_declaration): Issue diagnostics about __label__ | |
697 | not at the beginning of a block. | |
698 | ||
c343d5a7 PC |
699 | 2007-10-11 Paolo Carlini <pcarlini@suse.de> |
700 | ||
701 | PR c++/33461 | |
702 | * pt.c (coerce_template_parameter_pack): Do not pass error_mark_node | |
703 | to convert_template_argument. | |
704 | (coerce_template_parms): Return error_mark_node after fixed-length | |
705 | error. | |
706 | (tsubst_decl): Check for error_mark_node the return value of the | |
707 | first tsubst in 'case VAR_DECL'. | |
708 | ||
6524147c OW |
709 | 2007-10-08 Ollie Wild <aaw@google.com> |
710 | ||
711 | * typeck2.c (digest_init): Call cplus_expand_constant after | |
712 | convert_for_initialization. | |
713 | * cp-objcp-common.h (LANG_HOOKS_EXPAND_CONSTANT): Removed. | |
714 | * expr.c (cplus_expand_constant): Updated function description. | |
715 | ||
42f02385 JM |
716 | 2007-10-04 Jason Merrill <jason@redhat.com> |
717 | ||
718 | PR c++/20416 | |
719 | * call.c (initialize_reference): Handle local static reference | |
720 | temps properly. | |
721 | ||
231d0665 JM |
722 | 2007-10-03 Jason Merrill <jason@redhat.com> |
723 | ||
65567efa JM |
724 | PR c++/32470 |
725 | * name-lookup.c (push_namespace_with_attrs): Fold back into... | |
726 | (push_namespace): Here. | |
727 | (handle_namespace_attrs): New fn for the attr code. | |
728 | (leave_scope): Don't pop_visibility. | |
729 | * name-lookup.h (struct cp_binding_level): Remove has_visibility. | |
730 | * parser.c (cp_parser_namespace_definition): Call | |
731 | handle_namespace_attrs and pop_visibility as appropriate. | |
732 | ||
231d0665 JM |
733 | PR c++/11756 |
734 | * mangle.c (write_type) [TYPEOF_TYPE]: Just sorry. | |
735 | ||
fea10e36 AO |
736 | 2007-10-03 Alexandre Oliva <aoliva@redhat.com> |
737 | ||
738 | * decl.c (duplicate_decls): Preserve linkage flags for mere | |
739 | redeclarations of gnu_inline definitions. | |
740 | ||
a24549d4 JM |
741 | 2007-10-03 Jason Merrill <jason@redhat.com> |
742 | ||
743 | PR c++/15764 | |
744 | * decl.c (wrap_cleanups_r): New fn. | |
745 | (wrap_temporary_cleanups): New fn. | |
746 | (initialize_local_var): Call it. | |
747 | ||
dc472c59 JM |
748 | 2007-09-29 Jason Merrill <jason@redhat.com> |
749 | ||
750 | PR c++/33094 | |
751 | * decl.c (make_rtl_for_nonlocal_decl): It's ok for a member | |
752 | constant to not have DECL_EXTERNAL if it's file-local. | |
753 | ||
6dcee2d6 OW |
754 | 2007-09-28 Ollie Wild <aaw@google.com> |
755 | ||
756 | Revert | |
757 | 2007-09-27 Ollie Wild <aaw@google.com> | |
758 | ||
759 | * typeck2.c (digest_init): Call cplus_expand_constant after | |
760 | convert_for_initialization. | |
761 | * cp-objcp-common.h (LANG_HOOKS_EXPAND_CONSTANT): Removed. | |
762 | * expr.c (cplus_expand_constant): Updated function description. | |
763 | ||
d9d9dbc0 JM |
764 | 2007-09-28 Jason Merrill <jason@redhat.com> |
765 | ||
766 | PR c++/10179 | |
767 | * class.c (layout_empty_base): Take rli parameter, update | |
768 | rli->record_align if empty base has user-specified alignment. | |
769 | (build_base_field): Pass rli to it. | |
770 | ||
930a1e63 PC |
771 | 2007-09-28 Paolo Carlini <pcarlini@suse.de> |
772 | ||
773 | PR c++/33213 | |
774 | * error.c (dump_decl): Deal with TYPE_PACK_EXPANSION. | |
775 | ||
31d40008 PC |
776 | 2007-09-28 Paolo Carlini <pcarlini@suse.de> |
777 | ||
778 | PR c++/33118 | |
779 | * error.c (dump_expr): Deal with ARGUMENT_PACK_SELECT. | |
780 | (dump_type): Use dump_template_argument for TYPE_ARGUMENT_PACK. | |
781 | (dump_parameters): Just call dump_type for argument packs too. | |
782 | ||
80d86013 JJ |
783 | 2007-09-28 Jakub Jelinek <jakub@redhat.com> |
784 | ||
785 | PR c++/31434 | |
786 | * tree.c (cp_build_qualified_type_real): Handle TYPE_PACK_EXPANSION | |
787 | qualification by creating qualified PACK_EXPANSION_PATTERN and | |
788 | then calling make_pack_expansion on it. | |
789 | ||
12487dd0 OW |
790 | 2007-09-27 Ollie Wild <aaw@google.com> |
791 | ||
792 | * typeck2.c (digest_init): Call cplus_expand_constant after | |
793 | convert_for_initialization. | |
794 | * cp-objcp-common.h (LANG_HOOKS_EXPAND_CONSTANT): Removed. | |
795 | * expr.c (cplus_expand_constant): Updated function description. | |
796 | ||
533007c1 JM |
797 | 2007-09-27 Jason Merrill <jason@redhat.com> |
798 | ||
d9d9dbc0 | 799 | PR c++/33571 |
533007c1 JM |
800 | * decl2.c (is_late_template_attribute): Don't crash on unknown |
801 | attribute. | |
802 | ||
62081704 PC |
803 | 2007-09-27 Paolo Carlini <pcarlini@suse.de> |
804 | ||
805 | PR c++/33493 | |
806 | * error.c (dump_expr): Deal with DELETE_EXPR and VEC_DELETE_EXPR. | |
807 | * cxx-pretty-print.c (pp_cxx_delete_expression): Add missing | |
808 | spaces in the formatting. | |
809 | * cxx-pretty-print.h (pp_cxx_delete_expression): Declare. | |
810 | ||
c94ed7a1 JJ |
811 | 2007-09-27 Jakub Jelinek <jakub@redhat.com> |
812 | ||
813 | * error.c (cxx_print_error_function): Add third argument, pass | |
814 | it over to lhd_print_error_function. | |
815 | (cp_print_error_function): If diagnostic->abstract_origin, print | |
816 | virtual backtrace. | |
817 | * cp-tree.h (struct diagnostic_info): New forward decl. | |
818 | (cxx_print_error_function): Add third argument. | |
819 | ||
dc3ca06f SM |
820 | 2007-09-25 Simon Martin <simartin@users.sourceforge.net> |
821 | ||
822 | PR c++/33207 | |
823 | * name-lookup.c (pushtag): Do not create an implicit typedef before | |
824 | the associated type declaration is known to be valid. | |
825 | ||
1bde0042 JJ |
826 | 2007-09-25 Jakub Jelinek <jakub@redhat.com> |
827 | ||
828 | * tree.c (cxx_printable_name): Compare FUNCTION_DECL uids | |
829 | rather than pointers. | |
830 | ||
18ff3013 DS |
831 | 2007-09-24 Danny Smith <dannysmith@user.sourceforge.net> |
832 | ||
833 | PR c++/14688 | |
834 | * search.c (check_final_overrider): Fail if | |
835 | targetm.comp_type_attributes returns 0. | |
836 | ||
7a20d689 JM |
837 | 2007-09-24 Jason Merrill <jason@redhat.com> |
838 | ||
839 | PR c++/33239 | |
840 | * pt.c (resolve_typename_type): Don't look things up in the original | |
841 | template if it would mean losing template arguments. | |
842 | ||
2dff8956 JJ |
843 | 2007-09-24 Jakub Jelinek <jakub@redhat.com> |
844 | ||
845 | PR c++/33506 | |
846 | * cp-tree.h (cxx_type_hash_eq): New prototype. | |
847 | * cp-objcp-common.h (LANG_HOOKS_TYPE_HASH_EQ): Redefine. | |
848 | * tree.c (cxx_type_hash_eq): New function. | |
849 | ||
c946ce8b DG |
850 | 2007-09-24 Douglas Gregor <doug.gregor@gmail.com> |
851 | ||
852 | PR c++/33185 | |
853 | * tree.c (cp_build_qualified_type_real): Build a canonical | |
854 | ARRAY_TYPE if the original ARRAY_TYPE was not a canonical type. | |
855 | ||
714f2304 DG |
856 | 2007-09-24 Douglas Gregor <doug.gregor@gmail.com> |
857 | ||
858 | PR c++/33112 | |
859 | PR c++/33185 | |
860 | * tree.c (cplus_array_compare): Compare pointers, not types. | |
861 | (build_cplus_array_type_1): Store new array type into the hash | |
862 | table before building the canonical type; build the canonical type | |
863 | correctly. | |
864 | (cp_build_qualified_type_real): Put all of the array types with | |
865 | cv-qualified element types into the C++ array hash table, built as | |
866 | variants of the unqualified versions. | |
867 | ||
823dd937 JM |
868 | 2007-09-23 Jason Merrill <jason@redhat.com> |
869 | ||
870 | PR c++/16370 | |
871 | * decl.c (grokdeclarator): Look through implicit TYPE_DECLs | |
872 | for deprecation warnings. | |
873 | ||
a7f6bc8c JM |
874 | 2007-09-22 Jason Merrill <jason@redhat.com> |
875 | ||
1a68a4e8 JM |
876 | PR c++/15269 |
877 | * call.c (build_over_call): Warn about deprecated virtuals. | |
878 | ||
a7f6bc8c JM |
879 | PR c++/19407 |
880 | * cp-tree.h (ATTR_IS_DEPENDENT): New macro. | |
881 | (MAYBE_TAGGED_TYPE_P): Remove. | |
882 | * pt.c (apply_late_template_attributes): Check ATTR_IS_DEPENDENT | |
883 | instead of calling is_late_template_attribute again. | |
884 | (tsubst_decl) [TYPE_DECL]: Just check if the name is the tag. | |
885 | (tsubst): A typedef is a TYPE_NAME != TYPE_MAIN_DECL. | |
886 | Don't crash on typedefs from non-template classes. | |
887 | * decl2.c (grokfield): Don't sorry about attrs on template parms. | |
888 | (is_late_template_attribute): All attributes applied to template | |
889 | parms or typename types are dependent. Static. | |
890 | (splice_template_attributes): Pass decl through. | |
891 | (save_template_attributes): Likewise. | |
892 | ||
b6efedac JJ |
893 | 2007-09-20 Jakub Jelinek <jakub@redhat.com> |
894 | ||
895 | PR c++/33496 | |
896 | * pt.c (tsubst_copy) <case SIZEOF_EXPR>: Handle error_mark_node | |
897 | returned from tsubst_pack_expansion. | |
898 | (tsubst_copy_and_build) <case SIZEOF_EXPR>: Likewise. | |
899 | (tsubst_copy_and_build) <case CONSTRUCTOR>: Likewise. | |
900 | ||
24f58e74 PC |
901 | 2007-09-20 Paolo Carlini <pcarlini@suse.de> |
902 | ||
903 | PR c++/33460 | |
904 | * semantics.c (finish_id_expression): Use consistently | |
905 | context_for_name_lookup. | |
906 | * decl.c (fixup_anonymous_aggr): Fix error message for | |
907 | anonymous struct (vs union). | |
908 | ||
56d0c6e3 JM |
909 | 2007-09-19 Jason Merrill <jason@redhat.com> |
910 | ||
911 | PR c++/7586 | |
912 | * pt.c (tsubst): Handle typedefs by looking for the specialization. | |
913 | (retrieve_specialization): Only tagged types use | |
914 | DECL_TEMPLATE_INSTANTIATIONS. | |
915 | (instantiate_class_template): Push nested classes too. | |
916 | (tsubst_decl) [TYPE_DECL]: Only check for canonical decl for | |
917 | tagged types. | |
918 | * cp-tree.h (MAYBE_TAGGED_TYPE_P): New macro. | |
919 | * init.c (is_aggr_type): Remove redundant tests. | |
920 | * class.c (push_nested_class): Use CLASS_TYPE_P. | |
921 | ||
b43d1bde PC |
922 | 2007-09-20 Paolo Carlini <pcarlini@suse.de> |
923 | ||
924 | PR c++/33459 | |
925 | * init.c (build_zero_init): If, recursively, build_zero_init | |
926 | returns a NULL_TREE, do not append it to the VEC of constructors. | |
927 | ||
5044ab0e JM |
928 | 2007-09-18 Jason Merrill <jason@redhat.com> |
929 | ||
930 | PR c++/17743 | |
931 | * pt.c (apply_late_template_attributes): Set processing_template_decl. | |
932 | (tsubst_decl) [TYPE_DECL]: Preserve naming typedef, pass | |
933 | ATTR_FLAG_TYPE_IN_PLACE. | |
934 | (tsubst): Do unqualified lookup to find typedefs from current class. | |
935 | [ARRAY_TYPE]: Propagate alignment info. | |
936 | * decl2.c (is_late_template_attribute): Only defer handling of | |
937 | attribute aligned if the expression is dependent. | |
938 | (save_template_attributes): If we're deferring any attributes, | |
939 | make this a naming typedef. | |
940 | ||
352d5090 PC |
941 | 2007-09-18 Paolo Carlini <pcarlini@suse.de> |
942 | ||
943 | PR c++/33462 (again) | |
944 | * cxx-pretty-print.c (pp_cxx_va_arg_expression): Print | |
945 | va_arg instead of __builtin_va_arg. | |
946 | ||
fdb8f418 PC |
947 | 2007-09-18 Paolo Carlini <pcarlini@suse.de> |
948 | ||
949 | PR c++/33462 | |
950 | * cxx-pretty-print.c (pp_cxx_va_arg_expression): Add. | |
951 | (pp_cxx_primary_expression): Use it. | |
952 | * cxx-pretty-print.h (pp_cxx_va_arg_expression): Declare. | |
953 | * error.c (dump_expr): Use it. | |
954 | ||
2d65b828 PC |
955 | 2007-09-18 Paolo Carlini <pcarlini@suse.de> |
956 | ||
957 | PR c++/33463 | |
958 | * cxx-pretty-print.c (pp_cxx_postfix_expression): Split | |
959 | out case TYPEID_EXPR to... | |
960 | (pp_cxx_typeid_expression): ... here; use pp_cxx_left_paren | |
961 | and pp_cxx_right_paren. | |
962 | * cxx-pretty-print.h (pp_cxx_typeid_expression): Declare. | |
963 | * error.c (dump_expr): Use it. | |
964 | ||
e74392f0 PC |
965 | 2007-09-18 Paolo Carlini <pcarlini@suse.de> |
966 | ||
967 | PR c++/33464 | |
968 | * cxx-pretty-print.c (pp_cxx_trait_expression): Add. | |
969 | (pp_cxx_primary_expression): Use it. | |
970 | * cxx-pretty-print.h (pp_cxx_trait_expression): Declare. | |
971 | * error.c (dump_expr): Use it. | |
972 | ||
57711cd1 PC |
973 | 2007-09-16 Paolo Carlini <pcarlini@suse.de> |
974 | ||
975 | PR c++/33124 | |
976 | * init.c (build_new): Remove warning for zero-element | |
977 | allocations. | |
978 | ||
0ee3f0a8 NS |
979 | 2007-09-16 Nathan Sidwell <nathan@codesourcery.com> |
980 | ||
0ee3f0a8 NS |
981 | PR c++/32756 |
982 | * call.c (maybe_handle_implicit_object): Set this_p, clear | |
983 | rvaluedness_matches_p. | |
984 | (compare_ics): Do not compare rvaluedness matching when one of the | |
985 | operands is an implicit object. | |
986 | ||
4f4141ff JM |
987 | 2007-09-14 Jason Merrill <jason@redhat.com> |
988 | ||
989 | PR c++/17743, c++/19163 | |
990 | * decl2.c (is_late_template_attribute): New fn. | |
991 | (splice_template_attributes, save_template_attributes): New fns. | |
992 | (cplus_decl_attributes): Call save_template_attributes. | |
993 | * pt.c (apply_late_template_attributes): New fn. | |
994 | (instantiate_class_template, tsubst_decl): Use it. | |
995 | * cp-tree.h: Declare is_late_template_attribute. | |
996 | ||
46c2514e TT |
997 | 2007-09-13 Tom Tromey <tromey@redhat.com> |
998 | ||
999 | * parser.c (cp_lexer_new_main): Don't use | |
1000 | c_lex_return_raw_strings. | |
1001 | (cp_lexer_get_preprocessor_token): Update. Add special case when | |
1002 | lexer is NULL. | |
1003 | ||
e89d6010 JH |
1004 | 2007-09-11 Jan Hubicka <jh@suse.cz> |
1005 | ||
1006 | * method.c (use_thunk): Use tree_rest_of_compilation | |
1007 | * cp-objecp-common.h (LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): Kill. | |
1008 | (LANG_HOOKS_CALLGRAPH_EMIT_ASSOCIATED_THUNKS): Define. | |
1009 | * cp-tree.h (expand_body): Kill. | |
1010 | (emit_associated_thunks): Declare. | |
1011 | * semantics.c (emit_associated_thunks): Export. | |
1012 | (expand_body): Kill. | |
1013 | ||
b2ec1738 DD |
1014 | 2007-09-09 David Daney <ddaney@avtrex.com> |
1015 | ||
1016 | PR c++/33324 | |
1017 | * init.c (build_new_1): Use POINTER_PLUS_EXPR instead of MINUS_EXPR | |
1018 | to calculate cookie_ptr. | |
1019 | ||
fd452cef JM |
1020 | 2007-09-08 Jason Merrill <jason@redhat.com> |
1021 | ||
1022 | PR c++/33342 | |
1023 | * pt.c (most_specialized_class): Set processing_template_decl | |
1024 | while tsubsting partial spec args. | |
1025 | ||
3fd40684 JM |
1026 | 2007-09-06 Jason Merrill <jason@redhat.com> |
1027 | ||
1028 | * decl2.c (get_guard): Copy visibility from the guarded variable. | |
1029 | ||
b2ea030b JH |
1030 | 2007-09-06 Jan Hubicka <jh@suse.cz> |
1031 | ||
1032 | * semantics.c (expand_body): Do not mark arguments of clones used. | |
1033 | ||
a125de0c PC |
1034 | 2007-09-06 Paolo Carlini <pcarlini@suse.de> |
1035 | ||
1036 | PR c++/32674 | |
1037 | * decl.c (cp_finish_decl): When processing_template_decl, | |
1038 | deal correctly with init as TREE_LIST. | |
1039 | ||
5ffeb913 TT |
1040 | 2007-09-06 Tom Tromey <tromey@redhat.com> |
1041 | ||
1042 | * decl.c (finish_function): Put return's location on line zero of | |
1043 | file. | |
1044 | ||
6f06d231 JM |
1045 | 2007-09-05 Jason Merrill <jason@redhat.com> |
1046 | ||
86ef5ebb JM |
1047 | PR c++/15745 |
1048 | * except.c (prepare_eh_type): Use type_decays_to. | |
1049 | ||
6f06d231 JM |
1050 | PR c++/15097 |
1051 | * init.c (build_delete): Use build_headof to get the address of the | |
1052 | complete object if we aren't using the deleting destructor. | |
1053 | * rtti.c (build_headof): No longer static. | |
1054 | * cp-tree.h: Declare it. | |
1055 | ||
62bedd31 JJ |
1056 | 2007-09-06 Jakub Jelinek <jakub@redhat.com> |
1057 | ||
1058 | * decl.c (duplicate_decls): Set TREE_NOTHROW on __builtin_XX | |
1059 | decl if a prototype for XX is provided with throw(). | |
1060 | ||
012c4da9 JJ |
1061 | PR c++/33289 |
1062 | * decl.c (builtin_function_1): Set DECL_ANTICIPATED also | |
1063 | on __*_chk non-__builtin_* decls. | |
1064 | ||
61fdc9d7 PC |
1065 | 2007-09-05 Paolo Carlini <pcarlini@suse.de> |
1066 | ||
1067 | PR c++/30302 | |
1068 | * semantics.c (finish_id_expression): Use context_for_name_lookup | |
1069 | insted of DECL_CONTEXT, to see through anonymous structs and unions. | |
1070 | * class.c (finish_struct_anon): Deal correctly with anonymous | |
1071 | structs (vs unions, as GNU extension) in error messages. | |
1072 | ||
33061862 JH |
1073 | 2007-09-05 Jan Hubicka <jh@suse.cz> |
1074 | ||
1075 | * cp/sematics.c (expand_body): Remove unnecesary import_export_decl | |
1076 | call, DECL_EXTERNAL checks and current_function_decl saving. | |
1077 | ||
03ba2e11 PC |
1078 | 2007-09-05 Paolo Carlini <pcarlini@suse.de> |
1079 | ||
1080 | PR c++/29731 (again) | |
1081 | * parser.c (cp_parser_primary_expression): Return error_mark_node | |
1082 | when a statement-expression is found in a template-argument list. | |
1083 | ||
ba6c89a9 JM |
1084 | 2007-09-04 Jason Merrill <jason@redhat.com> |
1085 | ||
6f06d231 JM |
1086 | * except.c (initialize_handler_parm): Use |
1087 | fold_build_cleanup_point_expr. | |
1088 | ||
9380ed84 JM |
1089 | PR c++/31419 |
1090 | * call.c (reference_binding): Don't look for user-defined conversions | |
1091 | to the same type. | |
1092 | ||
ba6c89a9 JM |
1093 | PR c++/31411 |
1094 | * except.c (initialize_handler_parm): Put a CLEANUP_POINT_EXPR inside | |
1095 | the MUST_NOT_THROW_EXPR. | |
1096 | ||
4c5bae34 RS |
1097 | 2007-09-04 Richard Sandiford <richard@codesourcery.com> |
1098 | ||
1099 | * decl.c (cp_finish_decl): Call determine_visibility before | |
1100 | make_rtl_for_nonlocal_decl. | |
1101 | ||
dc28490d JM |
1102 | 2007-09-04 Jason Merrill <jason@redhat.com> |
1103 | ||
1104 | PR c++/14032 | |
1105 | * pt.c (most_specialized_class): Substitute outer template | |
1106 | arguments into the arguments of a member template partial | |
1107 | specialization. | |
1108 | (strip_innermost_template_args): New fn. | |
1109 | ||
72c65674 DJ |
1110 | 2007-09-03 Daniel Jacobowitz <dan@codesourcery.com> |
1111 | ||
1112 | * Make-lang.in (g++spec.o): Remove SHLIB_MULTILIB. | |
1113 | ||
b1d5455a KG |
1114 | 2007-09-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1115 | ||
1116 | * call.c (name_as_c_string): Supply a TYPE for CONST_CAST. | |
1117 | * decl.c (cp_make_fname_decl): Likewise, | |
1118 | * parser.c (cp_parser_string_literal): Likewise, | |
1119 | * tree.c (pod_type_p, zero_init_p): Use CONST_CAST_TREE. | |
1120 | * typeck.c (cp_type_quals, cp_type_readonly, cp_has_mutable_p): | |
1121 | Likewise, | |
1122 | ||
8bcebc69 PC |
1123 | 2007-09-02 Paolo Carlini <pcarlini@suse.de> |
1124 | ||
1125 | PR c++/33208 | |
1126 | * typeck.c (build_unary_op): Fix error message for | |
1127 | Boolean expression as operand to operator--. | |
1128 | ||
75547801 KG |
1129 | 2007-09-01 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1130 | ||
1131 | * tree.c (pod_type_p, zero_init_p): Use strip_array_types. | |
1132 | * typeck.c (cp_type_quals, cp_type_readonly, cp_has_mutable_p): | |
1133 | Likewise. | |
1134 | ||
268127ce DG |
1135 | 2007-08-31 Douglas Gregor <doug.gregor@gmail.com> |
1136 | ||
1137 | PR c++/32597 | |
1138 | * init.c (build_default_init): Make extern. | |
1139 | * cp-tree.h (build_default_init): Declare here. | |
1140 | * pt.c (tsubst_expr): When the instantiation of the initializer of | |
1141 | a variable results in an empty list, default-initialize the | |
1142 | variable. | |
1143 | (tsubst_copy_and_build): When the instantiation of the initializer | |
1144 | in a new expression results in an empty initializer list, | |
1145 | default-initialize it. | |
1146 | ||
1ab28be5 DG |
1147 | 2007-08-31 Douglas Gregor <doug.gregor@gmail.com> |
1148 | ||
1149 | * mangle.c (write_type): Change mangling of rvalue reference from | |
1150 | `RR' to `O'. | |
1151 | ||
194ee011 JJ |
1152 | 2007-08-31 Jakub Jelinek <jakub@redhat.com> |
1153 | ||
1154 | * decl.c (duplicate_decls): Remove duplicated line. | |
1155 | ||
c8c00613 PC |
1156 | 2007-08-31 Paolo Carlini <pcarlini@suse.de> |
1157 | ||
1158 | PR c++/33210 | |
1159 | * cxx-pretty-print.c (pp_cxx_unqualified_id): Deal with | |
1160 | BOUND_TEMPLATE_TEMPLATE_PARM. | |
1161 | ||
5973c743 PC |
1162 | 2007-08-31 Paolo Carlini <pcarlini@suse.de> |
1163 | ||
1164 | PR c++/32113 | |
1165 | * search.c (lookup_member): Check the name argument for | |
1166 | error_mark_node. | |
1167 | ||
a53bf42c PC |
1168 | 2007-08-31 Paolo Carlini <pcarlini@suse.de> |
1169 | ||
1170 | PR c++/33212 | |
1171 | * parser.c (cp_parser_trait_expr): Check rerurn value of | |
1172 | cp_parser_type_id. | |
1173 | ||
6e03b280 OW |
1174 | 2007-08-30 Ollie Wild <aaw@google.com> |
1175 | ||
1176 | * cvt.c (cp_convert_to_pointer): Remove force parameter. Call | |
1177 | convert_ptrmem for pointer to member conversions. | |
1178 | (convert_to_pointer_force): Update cp_convert_to_pointer call. | |
1179 | (ocp_convert): Update cp_convert_to_pointer call. | |
1180 | * typeck.c (convert_ptrmem): Add conditional for null pointers to | |
1181 | members. | |
1182 | (build_static_cast_1): Check can_convert for conversions in either | |
1183 | direction. | |
1184 | (get_delta_difference_1): New function. | |
1185 | (get_delta_difference): Refactor to call get_delta_difference_1. | |
1186 | ||
f86bfcab JJ |
1187 | 2007-08-30 Jakub Jelinek <jakub@redhat.com> |
1188 | ||
1189 | * decl.c (start_preparsed_function): Set | |
1190 | DECL_DISREGARD_INLINE_LIMITS for GNU_INLINE_P functions. | |
1191 | ||
0a8fc247 PC |
1192 | 2007-08-28 Paolo Carlini <pcarlini@suse.de> |
1193 | ||
1194 | PR c++/33209 | |
1195 | * error.c (dump_expr): Deal with TEMPLATE_TYPE_PARM and | |
1196 | BOUND_TEMPLATE_TEMPLATE_PARM. | |
1197 | ||
92d0af97 JJ |
1198 | 2007-08-28 Jakub Jelinek <jakub@redhat.com> |
1199 | ||
1200 | PR c++/32596 | |
1201 | PR c++/32400 | |
1202 | * pt.c (check_explicit_specialization): Set DECL_INTERFACE_KNOWN | |
1203 | and DECL_NOT_REALLY_EXTERN if tmpl_func is not public. | |
1204 | ||
c206a697 JM |
1205 | 2007-08-27 Jason Merrill <jason@redhat.com> |
1206 | ||
c2acde1e JM |
1207 | PR c++/29000 |
1208 | * pt.c (build_non_dependent_expr, type_dependent_expression_p): | |
1209 | Look inside STMT_EXPR. | |
1210 | * semantics.c (stmt_expr_value_expr): New fn. | |
1211 | * cp-tree.h: Declare it. | |
1212 | ||
c206a697 JM |
1213 | PR c++/28558 |
1214 | * decl.c (groktypename): Ignore attributes applied to class type. | |
1215 | ||
c536a6a7 RG |
1216 | 2007-08-28 Richard Guenther <rguenther@suse.de> |
1217 | ||
1218 | * decl.c (duplicate_decls): Merge DECL_DISREGARD_INLINE_LIMITS. | |
1219 | ||
7368348c GDR |
1220 | 2007-08-28 Gabriel Dos Reis <gdr@integrable-solutions.net> |
1221 | ||
1222 | * error.c (dump_expr): Handle COMPLEX_CST. | |
1223 | * cxx-pretty-print.c (pp_cxx_primary_expression): Likewise. | |
1224 | (pp_cxx_expression): Likewise. | |
1225 | ||
3a47c4e4 AO |
1226 | 2007-08-27 Alexandre Oliva <aoliva@redhat.com> |
1227 | ||
1228 | * decl.c (GNU_INLINE_P): New. | |
1229 | (duplicate_decls): Handle gnu_inline. Merge attributes and | |
1230 | some flags in overriding definitions. | |
1231 | (redeclaration_error_message): Handle gnu_inline. | |
1232 | (start_preparsed_function): Likewise. | |
1233 | ||
58f9752a KG |
1234 | 2007-08-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1235 | ||
1236 | * call.c (sufficient_parms_p): Constify. | |
1237 | * class.c (same_signature_p): Likewise. | |
1238 | * cp-gimplify.c (is_invisiref_parm, | |
1239 | cxx_omp_privatize_by_reference): Likewise. | |
1240 | * cp-objcp-common.c (has_c_linkage): Likewise. | |
1241 | * cp-tree.h (NON_THUNK_FUNCTION_CHECK, THUNK_FUNCTION_CHECK, | |
1242 | sufficient_parms_p, same_signature_p, copy_fn_p, move_fn_p, | |
1243 | grok_ctor_properties, nothrow_libfn_p, skip_artificial_parms_for, | |
1244 | num_artificial_parms_for, comp_template_parms, | |
1245 | template_parameter_pack_p, any_dependent_template_arguments_p, | |
1246 | any_type_dependent_arguments_p, any_value_dependent_elements_p, | |
1247 | repo_export_class_p, cxx_omp_privatize_by_reference, pod_type_p, | |
1248 | zero_init_p, member_p, cp_lvalue_kind, | |
1249 | builtin_valid_in_constant_expr_p, decl_anon_ns_mem_p, | |
1250 | varargs_function_p, is_dummy_object, special_function_kind, | |
1251 | string_conv_p, type_unknown_p, comp_except_specs, compparms, | |
1252 | comp_cv_qualification, is_bitfield_expr_with_lowered_type, | |
1253 | unlowered_expr_type, ptr_reasonably_similar, cp_type_readonly, | |
1254 | cp_has_mutable_p, at_least_as_qualified_p, | |
1255 | invalid_nonstatic_memfn_p, lvalue_or_else, lvalue_p): Likewise. | |
1256 | * decl.c (copy_fn_p, move_fn_p, grok_ctor_properties): Likewise. | |
1257 | * except.c (nothrow_libfn_p): Likewise. | |
1258 | * method.c (skip_artificial_parms_for, num_artificial_parms_for): | |
1259 | Likewise. | |
1260 | * pt.c (comp_template_parms, template_parameter_pack_p, | |
1261 | any_type_dependent_arguments_p, any_value_dependent_elements_p, | |
1262 | any_dependent_template_arguments_p): Likewise. | |
1263 | * repo.c (repo_export_class_p): Likewise. | |
1264 | * semantics.c (anon_aggr_type_p): Likewise. | |
1265 | * tree.c (lvalue_p_1, real_lvalue_p, lvalue_p, | |
1266 | builtin_valid_in_constant_expr_p, decl_anon_ns_mem_p, | |
1267 | varargs_function_p, member_p, is_dummy_object, pod_type_p, | |
1268 | zero_init_p, special_function_p): Likewise. | |
1269 | * typeck.c (comp_array_types, type_unknown_p, comp_except_specs, | |
1270 | comp_array_types, at_least_as_qualified_p, comp_cv_qualification, | |
1271 | compparms, invalid_nonstatic_memfn_p, | |
1272 | is_bitfield_expr_with_lowered_type, unlowered_expr_type, | |
1273 | string_conv_p, ptr_reasonably_similar, cp_type_readonly, | |
1274 | cp_has_mutable_p, lvalue_or_else): Likewise. | |
1275 | ||
e2c3721c PB |
1276 | 2007-08-25 Paolo Bonzini <bonzini@gnu.org> |
1277 | ||
1278 | * decl.c (cp_tree_node_structure): Kill TINST_LEVEL case. | |
1279 | * cp-objcp-common.c (cp_tree_size): Ditto. | |
1280 | * tree.c (cp_walk_subtrees): Ditto | |
1281 | * cp-tree.def (TINST_LEVEL): Go away. | |
1282 | * cp-tree.h (struct tinst_level_s): Rename to struct tinst_level, | |
1283 | move together with other non-tree structs. | |
1284 | (enum cp_tree_node_structure_enum): Nuke TS_CP_TINST_LEVEL. | |
1285 | (union lang_tree_node): Eliminate tinst_level field. | |
1286 | (TINST_DECL, TINST_LOCATION, TINST_IN_SYSTEM_HEADER_P): Annihilate. | |
1287 | (current_instantiation, outermost_tinst_level): Return | |
1288 | a "struct tinst_level *". | |
1289 | ||
1290 | * error.c (print_instantiation_partial_context): Change second | |
1291 | parameter to a "struct tinst_level *". Replace accessor macros | |
1292 | with field access. | |
1293 | (print_instantiation_full_context): Likewise. | |
1294 | * lex.c (in_main_input_context): Likewise. | |
1295 | ||
1296 | * pt.c (struct pending_templates): New. | |
1297 | (pending_templates, last_pending_template): Use it as a type. | |
1298 | (current_tinst_level): Change typo to "struct tinst_level *" | |
1299 | (reopen_tinst_level): Accept "struct tinst_level *", return decl. | |
1300 | (add_pending_template): Construct a "struct pending_template". | |
1301 | Replace TINST_LEVEL accessor macros with field access. | |
1302 | (push_tinst_level): Likewise, using GGC_NEW instead of make_node. | |
1303 | (pop_tinst_level): Likewise. | |
1304 | (instantiate_pending_templates): Likewise. Factor common code used | |
1305 | when an instantiation has been done. | |
1306 | (outermost_tinst_level): Replace tree_last with loop. | |
1307 | (current_instantiation): Return a "struct tinst_level *". | |
1308 | ||
89bd2c03 OW |
1309 | 2007-08-24 Ollie Wild <aaw@google.com> |
1310 | ||
1311 | * name-lookup.c (add_decl_to_level): Remove addition to vtables chain. | |
1312 | * name-lookup.h (cp_binding_level): Remove vtables member. | |
1313 | ||
18177c7e RG |
1314 | 2007-08-24 Richard Guenther <rguenther@suse.de> |
1315 | ||
1316 | * tree.c (cp_cannot_inline_tree_fn): Remove. | |
1317 | * cp-tree.h (cp_cannot_inline_tree_fn): Likewise. | |
1318 | * cp-objcp-common.h (LANG_HOOKS_TREE_INLINING_CANNOT_INLINE_TREE_FN): | |
1319 | Remove define. | |
1320 | ||
c6f3d2f4 JJ |
1321 | 2007-08-24 Jakub Jelinek <jakub@redhat.com> |
1322 | ||
affb3cb2 JJ |
1323 | PR c++/32567 |
1324 | * typeck.c (build_unary_op) <case PREINCREMENT_EXPR>: Return | |
1325 | error_mark_node right away if build_expr_type_conversion | |
1326 | returned it. | |
1327 | ||
97dc8e5b JJ |
1328 | PR c++/32898 |
1329 | * name-lookup.c (set_decl_namespace): lookup_qualified_name failure | |
1330 | is error_mark_node rather than NULL_TREE. | |
1331 | * pt.c (check_explicit_specialization): Likewise. | |
1332 | ||
c6f3d2f4 JJ |
1333 | PR c++/31941 |
1334 | * error.c (resolve_virtual_fun_from_obj_type_ref): Handle | |
1335 | TARGET_VTABLE_USES_DESCRIPTORS targets properly. | |
1336 | ||
61172206 JM |
1337 | 2007-08-22 Jason Merrill <jason@redhat.com> |
1338 | ||
1339 | PR c++/29365 | |
1340 | * pt.c (outermost_tinst_level): New function. | |
1341 | * lex.c (in_main_input_context): New function. | |
f11b2351 | 1342 | * cp-tree.h: Declare it. |
61172206 JM |
1343 | * decl2.c (constrain_class_visibility): Use it to avoid warning |
1344 | about uses of the anonymous namespace in the main input file. | |
1345 | ||
af9fc1dd JJ |
1346 | 2007-08-21 Jakub Jelinek <jakub@redhat.com> |
1347 | ||
1348 | * init.c (build_new_1): Use get_target_expr instead of save_expr. | |
1349 | ||
43f14744 PS |
1350 | 2007-08-20 Pawel Sikora <pluto@pld-linux.org> |
1351 | ||
1352 | PR c++/7302 | |
1353 | * class.c (finish_struct_1): Warn when a class has virtual | |
1354 | functions and accessible non-virtual destructor. | |
1355 | ||
a489b1f0 RG |
1356 | 2007-08-20 Richard Guenther <rguenther@suse.de> |
1357 | ||
1358 | PR c++/22369 | |
1359 | PR c++/22451 | |
1360 | * call.c (build_new_method_call): Convert initializer to | |
1361 | the basetype. | |
1362 | * init.c (build_aggr_init): Do not fiddle with types. | |
1363 | (build_vec_delete_1): Use correct type for POINTER_PLUS_EXPR. | |
1364 | * except.c (build_throw): Do not drop qualifiers for the | |
1365 | pointer type. | |
1366 | * typeck.c (get_member_function_from_ptrfunc): Do not | |
1367 | fiddle with types, instead convert. | |
1368 | (build_ptrmemfunc1): Convert to the target type for | |
1369 | initialization. | |
1370 | (gfc_trans_allocate): Convert result to target type. | |
1371 | * cp-objcp-common.c (cxx_get_alias_set): Pointers to | |
1372 | pointer-to-member structures shall have alias set zero as well. | |
1373 | ||
50886bf1 RG |
1374 | 2007-08-20 Richard Guenther <rguenther@suse.de> |
1375 | ||
1376 | * cp-objcp-common.h (LANG_HOOKS_TREE_INLINING_AUTO_VAR_IN_FN_P): | |
1377 | Remove. | |
1378 | * cp-tree.h (cp_auto_var_in_fn_p): Remove. | |
1379 | (nonstatic_local_decl_p): Likewise. | |
1380 | * tree.c (cp_auto_var_in_fn_p): Remove. | |
1381 | * decl.c (nonstatic_local_decl_p): Remove. | |
1382 | ||
14588106 RG |
1383 | 2007-08-20 Richard Guenther <rguenther@suse.de> |
1384 | ||
1385 | * cp-objcp-common.h (LANG_HOOKS_TREE_INLINING_WALK_SUBTREES): | |
1386 | Remove define. | |
1387 | * tree.h (cp_walk_tree): New define to walk_tree_1 with | |
1388 | cp_walk_subtrees lh parameter. | |
1389 | (cp_walk_tree_without_duplicates): New define to | |
1390 | walk_tree_without_duplicates_1 with cp_walk_subtrees lh parameter. | |
1391 | * tree.c (count_trees): Call | |
1392 | cp_walk_tree_without_duplicates. | |
1393 | (verify_stmt_tree): Call cp_walk_tree. | |
1394 | (break_out_target_exprs): Likewise. | |
1395 | (WALK_SUBTREE): Likewise. | |
1396 | * cp-gimplify.c (cp_genericize): Likewise. | |
1397 | * cp-pt.c (find_parameter_packs_r): Likewise. | |
1398 | (uses_parameter_packs): Likewise. | |
1399 | (make_pack_expansion): Likewise. | |
1400 | (check_for_bare_parameter_packs): Likewise. | |
1401 | (for_each_template_parm): Likewise. | |
1402 | * decl.c (check_default_argument): Call | |
1403 | cp_walk_tree_without_duplicates. | |
1404 | * except.c (build_throw): Likewise. | |
1405 | * decl2.c (type_visibility): Likewise. | |
1406 | * semantics.c (expand_or_defer_fn): Likewise. | |
1407 | (finalize_nrv): Call cp_walk_tree. | |
1408 | ||
412bbe81 JJ |
1409 | 2007-08-20 Jakub Jelinek <jakub@redhat.com> |
1410 | ||
1411 | PR c++/33025 | |
1412 | * init.c (build_new_1): Rename placement_var variable to placement_expr. | |
1413 | Initialize it with save_expr rather than get_temp_regvar. | |
1414 | ||
8f4361eb AP |
1415 | 2007-08-17 Andrew Pinski <andrew_pinski@playstation.sony.com> |
1416 | ||
1417 | PR c++/28989 | |
1418 | * tree.c (lvalue_p_1 <case SAVE_EXPR>): SAVE_EXPRs are never | |
1419 | lvalues. | |
1420 | ||
44fd0e80 OW |
1421 | 2007-08-17 Ollie Wild <aaw@google.com> |
1422 | ||
1423 | PR c++/31749 | |
1424 | * name-lookup.c (do_nonmember_using_decl): Shift implicit type | |
1425 | declarations into appropriate slots for comparison. Fix type | |
1426 | comparison. | |
1427 | ||
2658bdae PC |
1428 | 2007-08-17 Paolo Carlini <pcarlini@suse.de> |
1429 | ||
1430 | PR c++/32112 | |
1431 | * error.c (dump_decl): Deal with UNBOUND_CLASS_TEMPLATE. | |
1432 | * cxx-pretty-print.c (pp_cxx_unqualified_id): Likewise. | |
1433 | ||
968fc32d PC |
1434 | 2007-08-17 Paolo Carlini <pcarlini@suse.de> |
1435 | ||
1436 | PR c++/32870 | |
1437 | * parser.c (cp_parser_class_head): Improve error message. | |
1438 | ||
75407da3 SP |
1439 | 2007-08-16 Seongbae Park <seongbae.park@gmail.com> |
1440 | ||
968fc32d PC |
1441 | * pt.c (instantiate_decl): Set input_location |
1442 | for the function end. | |
75407da3 | 1443 | |
ac7d7749 KG |
1444 | 2007-08-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1445 | ||
1446 | * cp-objcp-common.c (cxx_warn_unused_global_decl, cp_expr_size): | |
1447 | Constify. | |
1448 | * cp-tree.h (local_variable_p, nonstatic_local_decl_p, | |
1449 | class_tmpl_impl_spec_p, cp_auto_var_in_fn_p, cp_type_quals, | |
1450 | cxx_incomplete_type_diagnostic, cxx_incomplete_type_error, | |
1451 | cxx_warn_unused_global_decl, cp_expr_size): Likewise. | |
1452 | * decl.c (local_variable_p, nonstatic_local_decl_p): Likewise. | |
1453 | * tree.c (class_tmpl_impl_spec_p, cp_auto_var_in_fn_p): Likewise. | |
1454 | * typeck.c (cp_type_quals): Likewise. | |
1455 | * typeck2.c (cxx_incomplete_type_diagnostic, | |
1456 | cxx_incomplete_type_error): Likewise. | |
1457 | ||
684939ce PC |
1458 | 2007-08-16 Paolo Carlini <pcarlini@suse.de> |
1459 | ||
1460 | PR c++/31132 | |
1461 | * pt.c (tsubst_friend_function): When check_classfn | |
1462 | returns error_mark_node likewise return it. | |
1463 | ||
59fe9274 JJ |
1464 | 2007-08-15 Jakub Jelinek <jakub@redhat.com> |
1465 | ||
1466 | PR c++/32992 | |
1467 | * typeck.c (check_return_expr): Don't NRV optimize vars in | |
1468 | anonymous unions. | |
1469 | * decl.c (finish_function): Comment fix. | |
1470 | ||
ba75df2b PC |
1471 | 2007-08-15 Paolo Carlini <pcarlini@suse.de> |
1472 | ||
1473 | PR c++/33035 | |
1474 | * pt.c (push_template_decl_real): Depending on TYPE_P | |
1475 | use either TYPE_CONTEXT or DECL_CONTEXT. | |
1476 | ||
67f9922b MM |
1477 | 2007-08-14 Mark Mitchell <mark@codesourcery.com> |
1478 | ||
1479 | * semantics.c (finish_omp_clauses): Strip a NOP_EXPR if | |
1480 | constructors and destructors return this. | |
1481 | ||
f8c3b097 PC |
1482 | 2007-08-14 Paolo Carlini <pcarlini@suse.de> |
1483 | ||
1484 | PR c++/27211 | |
1485 | * decl2.c (check_classfn): Return error_mark_node in case of error; | |
1486 | in that case, do not call add_method. | |
1487 | * decl.c (start_decl): Deal with check_classfn returning | |
1488 | error_mark_node. | |
1489 | (grokfndecl): Likewise. | |
1490 | * pt.c (tsubst_friend_function): Likewise. | |
1491 | ||
9ef0c8d9 AP |
1492 | 2007-08-14 Andrew Pinski <pinskia@gmail.com> |
1493 | ||
1494 | PR c++/30428 | |
1495 | * typeck.c (build_binary_op): Disallow vector float types with | |
1496 | BIT_IOR_EXPR, BIT_AND_EXPR, and BIT_XOR_EXPR. | |
1497 | ||
4862826d ILT |
1498 | 2007-08-11 Ian Lance Taylor <iant@google.com> |
1499 | ||
1500 | * cp-objcp-common.c (cxx_get_alias_set): Change return type to | |
1501 | alias_set_type. | |
1502 | * cp/cp-tree.h (cxx_get_alias_set): Update declaration. | |
1503 | ||
19831e2b OW |
1504 | 2007-08-10 Ollie Wild <aaw@google.com> |
1505 | ||
1506 | * name-lookup.c (do_nonmember_using_decl): Print an error for ambiguous | |
1507 | type lookups. | |
1508 | (ambiguous_decl): Construct tree of ambiguous types. Remove extaneous | |
1509 | function parameter. | |
1510 | (unqualified_namespace_lookup): Fix ambiguous_decl call. | |
1511 | (lookup_using_namespace): Fix ambiguous_decl call. | |
1512 | (qualified_lookup_using_namespace): Fix ambiguous_decl call. | |
1513 | ||
68a57691 KG |
1514 | 2007-08-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1515 | ||
1516 | * call.c (name_as_c_string): Use CONST_CAST. | |
1517 | * decl.c (build_decl): Likewise. | |
1518 | * parser.c (cp_parser_string_literal): Likewise. | |
1519 | ||
2fbe0e5a PC |
1520 | 2007-08-10 Paolo Carlini <pcarlini@suse.de> |
1521 | ||
1522 | PR c++/17763 | |
1523 | * error.c (dump_expr): Consistently use the *_cxx_* | |
1524 | variants of the pretty-print functions. | |
1525 | ||
caba2081 PC |
1526 | 2007-08-10 Paolo Carlini <pcarlini@suse.de> |
1527 | ||
1528 | PR c++/22256 | |
1529 | * decl.c (check_special_function_return_type): Just error | |
1530 | on return type specified for conversion operator. | |
1531 | ||
d7705934 DB |
1532 | 2007-08-09 Daniel Berlin <dberlin@dberlin.org> |
1533 | ||
1534 | * typeck2.c (readonly_error): Handle general expressions. | |
1535 | * error.c (dump_expr): Handle POINTER_PLUS_EXPR | |
1536 | ||
af34b82f DH |
1537 | 2007-08-06 Dan Hipschman <dsh@google.com> |
1538 | ||
1539 | * method.c (use_thunk): Use DECL_NAME instead of DECL_RTL to | |
1540 | access function name. | |
1541 | ||
5958f5cb AM |
1542 | 2007-08-04 Alfred Minarik <a.minarik@aon.at> |
1543 | ||
1544 | PR pch/13676 | |
1545 | * lang-specs.h: Add .hp, .hxx, .hpp, .h, .HPP, .tcc as c++ header. | |
1546 | * g++spec.c (lang_specific_driver): Check them. | |
1547 | ||
ae95e46e PC |
1548 | 2007-08-06 Paolo Carlini <pcarlini@suse.de> |
1549 | ||
1550 | PR c++/19532 | |
13678df8 | 1551 | * pt.c (inline_needs_template_parms): Fix comment; change return type |
ae95e46e PC |
1552 | to bool. |
1553 | ||
9dfbac5b VR |
1554 | 2007-08-05 Volker Reichelt <v.reichelt@netcologne.de> |
1555 | ||
1556 | Revert: | |
1557 | 2007-03-26 Dirk Mueller <dmueller@suse.de> | |
1558 | ||
1559 | * parser.c (cp_parser_member_declaration): Pedwarn | |
1560 | about stray semicolons after member declarations. | |
f8ff69ea LM |
1561 | |
1562 | 2007-08-02 Lee Millward <lee.millward@gmail.com> | |
1563 | ||
1564 | PR c++/30849 | |
1565 | PR c++/30850 | |
1566 | PR c++/30851 | |
1567 | * parser.c (cp_parser_asm_definition): Detect and discard asm | |
1568 | statements with invalid inputs or outputs. | |
1569 | (cp_parser_asm_operand_list): Return error mark node if any | |
1570 | of the operands are invalid. Adjust documentation. | |
1571 | ||
e77f031d NC |
1572 | 2007-08-02 Nick Clifton <nickc@redhat.com> |
1573 | ||
1574 | * typeck.c: Change copyright header to refer to version 3 of the | |
1575 | GNU General Public License and to point readers at the COPYING3 | |
1576 | file and the FSF's license web page. | |
1577 | * optimize.c, lang-specs.h, init.c, class.c, repo.c, decl.c, | |
1578 | config-lang.in, cp-tree.def, call.c, decl.h, ptree.c, | |
1579 | Make-lang.in, method.c, rtti.c, cp-objcp-common.c, g++spec.c, | |
1580 | cp-objcp-common.h, except.c, error.c, operators.def, cvt.c, | |
1581 | tree.c, mangle.c, cp-tree.h, dump.c, search.c, friend.c, expr.c, | |
1582 | cp-gimplify.c, cxx-pretty-print.c, cp-lang.c, typeck2.c, pt.c, | |
1583 | cxx-pretty-print.h, semantics.c, name-lookup.c, lex.c, decl2.c, | |
1584 | name-lookup.h, parser.c: Likewise. | |
1585 | ||
59f89d34 KG |
1586 | 2007-08-01 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1587 | ||
1588 | PR middle-end/32668 | |
1589 | * call.c (magic_varargs_p): Honor the "type generic" attribute. | |
1590 | ||
a6d76a95 PC |
1591 | 2007-07-30 Paolo Carlini <pcarlini@suse.de> |
1592 | ||
1593 | PR c++/32108 | |
1594 | * semantics.c (finish_label_stmt): Reject the __label__ | |
1595 | extension outside function scopes. | |
1596 | ||
fa233e34 KG |
1597 | 2007-07-29 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1598 | ||
1599 | * parser.c (eof_token): Un-constify. | |
1600 | (cp_lexer_new_main, cp_lexer_new_from_tokens, VEC_alloc, | |
1601 | cp_lexer_consume_token, cp_lexer_purge_token): Remove spurious | |
1602 | casts. | |
1603 | ||
d732e98f KH |
1604 | 2007-07-28 Kazu Hirata <kazu@codesourcery.com> |
1605 | ||
1606 | * pt.c, tree.c, typeck2.c: Fix comment typos. | |
1607 | ||
d4d8c232 SM |
1608 | 2007-07-28 Simon Martin <simartin@users.sourceforge.net> |
1609 | Mark Mitchell <mark@codesourcery.com> | |
1610 | ||
1611 | PR c++/30917 | |
1612 | * name-lookup.c (lookup_name_real): Non namespace-scope bindings can be | |
1613 | hidden due to friend declarations in local classes. | |
1614 | ||
3ad6a8e1 DG |
1615 | 2007-07-27 Douglas Gregor <doug.gregor@gmail.com> |
1616 | ||
1617 | * typeck.c (structural_comptypes): Compare DECLTYPE_TYPE nodes. | |
1618 | * cp-tree.def (DECLTYPE_TYPE): New. | |
1619 | * error.c (dump_type): Dump DECLTYPE_TYPE nodes. | |
1620 | (dump_type_prefix): Ditto. | |
1621 | (dump_type_suffix): Ditto. | |
1622 | * tree.c (DECLTYPE_TYPE): Walk DECLTYPE_TYPE nodes. | |
1623 | * mangle.c (write_type): Handle DECLTYPE_TYPE. | |
1624 | * cp-tree.h (IS_AGGR_TYPE): DECLTYPE_TYPE nodes can be aggregate | |
1625 | types. | |
1626 | (DECLTYPE_TYPE_EXPR): New. | |
1627 | (DECLTYPE_TYPE_ID_EXPR_OR_MEMBER_ACCESS_P): New. | |
1628 | (finish_declared_type): Declare. | |
1629 | * cxx-pretty-print.c (pp_cxx_type_specifier_seq): Print | |
1630 | DECLTYPE_TYPE nodes. | |
1631 | (pp_cxx_type_id): Ditto. | |
1632 | * pt.c (for_each_template_parm_r): Walk DECLTYPE_TYPE children. | |
1633 | (tsubst): Substitute into a DECLTYPE_TYPE node. | |
1634 | (tsubst_copy): Ditto. | |
1635 | (unify): Cannot deduce anything from TYPEOF_TYPE or DECLTYPE_TYPE | |
1636 | nodes. | |
1637 | (dependent_type_p_r): DECLTYPE_TYPE types are always dependent. | |
1638 | * semantics.c (finish_typeof): TYPEOF_TYPE types need to use | |
1639 | structural equality (because we can't hash the expressions). | |
1640 | (finish_declared_type): New. | |
1641 | * lex.c (reswords): Add "decltype" keyword. | |
1642 | * parser.c cp_lexer_next_token_is_decl_specifier_keyword | |
1643 | (cp_parser_postfix_expression): Add member_access_only_p to | |
1644 | restrict postfix expression to member access expressions. | |
1645 | (cp_parser_unary_expression): Update call to | |
1646 | cp_parser_postfix_expression to reflect new parameter. | |
1647 | (cp_parser_declared_type): New. | |
1648 | (cp_parser_simple_type_specifier): Parse decltype types. | |
1649 | ||
83144bd6 MM |
1650 | 2007-07-27 Mark Mitchell <mark@codesourcery.com> |
1651 | ||
1652 | PR c++/32346 | |
1653 | * call.c (convert_for_arg_passing): Only widen bitfields to their | |
1654 | declared types if necessary. | |
1655 | ||
e5cfc29f KG |
1656 | 2007-07-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1657 | ||
1658 | * parser.c (cp_parser_string_literal, cp_parser_sizeof_operand): | |
1659 | Constify. | |
1660 | ||
741ac903 KG |
1661 | 2007-07-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1662 | ||
1663 | * decl.c (typename_hash, typename_compare): Constify. | |
1664 | * mangle.c (hash_type, compare_type): Likewise. | |
1665 | * pt.c (eq_local_specializations, hash_local_specialization): | |
1666 | Likewise. | |
1667 | * tree.c (cplus_array_hash, cplus_array_compare, list_hash_eq, | |
1668 | list_hash): Likewise. | |
1669 | * typeck2.c (pat_compare): Likewise. | |
1670 | ||
b21a6ea1 NS |
1671 | 2007-07-24 Nathan Sidwell <nathan@codesourcery.com> |
1672 | ||
1673 | * method.c (implicitly_declare_fn): Increase alignment if member | |
1674 | function pointer format requires it. | |
1675 | ||
aedfac0e PC |
1676 | 2007-07-24 Paolo Carlini <pcarlini@suse.de> |
1677 | ||
1678 | PR c++/29001 | |
1679 | * typeck.c (check_return_expr): Do not pass a null argument | |
1680 | to null_ptr_cst_p. | |
1681 | ||
1682 | 2007-07-24 Paolo Carlini <pcarlini@suse.de> | |
1683 | ||
1684 | PR c++/32561 | |
1685 | * decl.c (redeclaration_error_message): Call DECL_ANON_UNION_VAR_P | |
1686 | only on VAR_DECL. | |
1687 | ||
4195a767 NS |
1688 | 2007-07-22 Nathan Sidwell <nathan@codesourcery.com> |
1689 | ||
823c22f9 NS |
1690 | PR c++/32839 |
1691 | * typeck.c (convert_arguments): Only use default args if we have | |
1692 | a function decl. | |
1693 | ||
4195a767 NS |
1694 | PR c++/30818 |
1695 | * typeck.c (structural_comptypes): No need to check | |
1696 | resolve_typename_type return value here. | |
1697 | * cp-tree.h (TYPENAME_IS_RESOLVING_P): New. | |
1698 | * pt.c (resolve_typename_type): Follow typename typedefs. Return | |
1699 | original type rather than error_mark_node in case of failure. | |
1700 | * parser.c (cp_parser_nested_name_specifier_opt): Adjust | |
1701 | resolve_typename_type result check. | |
1702 | (cp_parser_direct_declarator, cp_parser_head, | |
1703 | cp_parser_constructor_declarator_p): Likewise. | |
1704 | ||
2fe5bb9b KH |
1705 | 2007-07-12 Kazu Hirata <kazu@codesourcery.com> |
1706 | ||
1707 | * pt.c (template_parms_variadic_p): Remove. | |
1708 | * cp-tree.h: Remove the prototype for template_parms_variadic_p. | |
1709 | ||
99c1f1ce JJ |
1710 | 2007-07-12 Jakub Jelinek <jakub@redhat.com> |
1711 | ||
1712 | PR c++/30854 | |
1713 | * error.c (dump_expr) <case AGGR_INIT_EXPR>: Pass true as last | |
1714 | argument to dump_aggr_init_expr_args instead of false. | |
1715 | ||
7313518b DG |
1716 | 2007-07-11 Douglas Gregor <doug.gregor@gmail.com> |
1717 | ||
1718 | * typeck.c (comptypes): When USE_CANONICAL_TYPES, use the | |
1719 | canonical types; otherwise, fall back to structural type | |
1720 | comparisons. If ENABLE_CHECKING and USE_CANONICAL_TYPES, give an | |
1721 | internal compiler error if the canonical types are wrong. | |
1722 | ||
b8ade407 PC |
1723 | 2007-07-11 Paolo Carlini <pcarlini@suse.de> |
1724 | ||
1725 | PR c++/32560 | |
1726 | * parser.c (cp_parser_make_indirect_declarator): When the | |
1727 | the code argument is ERROR_MARK return cp_error_declarator. | |
1728 | ||
837edd5f GK |
1729 | 2007-07-09 Geoffrey Keating <geoffk@apple.com> |
1730 | ||
1731 | PR 32617 | |
1732 | * decl.c (cxx_init_decl_processing): Don't set | |
1733 | force_align_functions_log. | |
1734 | (grokfndecl): Honour ptrmemfunc_vbit_in_pfn. | |
1735 | * typeck.c (cxx_alignof_expr): When alignof is used on a plain | |
1736 | FUNCTION_DECL, return its alignment. | |
1737 | ||
f967586f RG |
1738 | 2007-07-09 Richard Guenther <rguenther@suse.de> |
1739 | ||
1740 | * decl.c (start_preparsed_function): Do not promote return type. | |
1741 | ||
833be229 PC |
1742 | 2007-07-08 Paolo Carlini <pcarlini@suse.de> |
1743 | ||
1744 | PR c++/30535 | |
1745 | * pt.c (unify): Never pass error_mark_node to template_decl_level. | |
1746 | ||
acde59b4 MM |
1747 | 2007-07-07 Mark Mitchell <mark@codesourcery.com> |
1748 | ||
1749 | PR c++/32232 | |
1750 | * pt.c (resolve_overloaded_unification): Robustify. Return a | |
1751 | bool, not an int. | |
1752 | (type_unification_real): Adjust accordingly. | |
1753 | ||
b5119fa1 RG |
1754 | 2007-07-06 Richard Guenther <rguenther@suse.de> |
1755 | ||
1756 | * init.c (build_new_1): Use the correct pointer type. | |
1757 | * typeck2.c (build_m_component_ref): Likewise. | |
1758 | ||
32a11c08 MM |
1759 | 2007-07-05 Mark Mitchell <mark@codesourcery.com> |
1760 | ||
1761 | PR c++/32245 | |
1762 | * init.c (build_zero_init): Always build an initializer for | |
1763 | non-static storage. | |
1764 | * typeck2.c (build_functional_cast): Use build_zero_init. | |
1765 | ||
1766 | PR c++/32251 | |
1767 | * init.c (build_new_1): Always pass the allocation function to | |
1768 | build_op_delete_call. | |
1769 | * call.c (build_op_delete_call): Handle operator delete with a | |
1770 | variable-argument list. Do not issue an error when no matching | |
1771 | deallocation function is available for a new operator. | |
1772 | ||
1773 | PR c++/31992 | |
1774 | * cp-tree.h (any_value_dependent_elements_p): Declare it. | |
1775 | * decl.c (value_dependent_init_p): New function. | |
1776 | (cp_finish_decl): Use it. | |
1777 | * pt.c (value_dependent_expression_p): Use | |
1778 | any_value_dependent_elements_p. | |
1779 | * parser.c (cp_parser_primary_expression): Add comment about | |
1780 | treating dependent qualified names as integral | |
1781 | constant-expressions. | |
1782 | ||
8de08f4c DG |
1783 | 2007-07-04 Douglas Gregor <doug.gregor@gmail.com> |
1784 | ||
1785 | * decl.c (build_ptrmemfunc_type): Always use structural equality | |
1786 | tests when comparing pointer-to-member-function types, because the | |
1787 | handling of TYPE_GET_PTRMEMFUNC_TYPE currently defeats canonical | |
1788 | types. | |
1789 | ||
57ccb546 MM |
1790 | 2007-07-03 Mark Mitchell <mark@codesourcery.com> |
1791 | ||
1792 | * init.c (build_new): Tweak comment. | |
1793 | ||
39fb9d72 DB |
1794 | 2007-06-29 Dave Brolley <brolley@redhat.com> |
1795 | ||
1796 | PR c++/31743 | |
1797 | * parser.c (cp_parser_new_type_id): Don't reduce a named array | |
1798 | type to its base type and number of elements here. | |
1799 | * init.c (build_new): Call complete_type_or_else to ensure that the | |
1800 | type is complete and to issue a diagnostic if it is not. | |
1801 | (build_new_1): Don't call complete_type_or_else here. | |
1802 | ||
e656a465 RG |
1803 | 2007-07-03 Richard Guenther <rguenther@suse.de> |
1804 | ||
1805 | PR c++/32609 | |
1806 | * class.c (fixed_type_or_null): Re-lookup the hashtable slot | |
1807 | after recursing. | |
1808 | ||
2a7b8343 SB |
1809 | 2007-07-02 Simon Baldwin <simonb@google.com> |
1810 | ||
1811 | * parser.c (cp_parser_elaborated_type_specifier): Added a warning | |
1812 | for inner-style nested forward declarations that don't declare | |
1813 | anything useful. | |
1814 | ||
76dc15d4 JJ |
1815 | 2007-07-02 Jakub Jelinek <jakub@redhat.com> |
1816 | ||
1817 | PR c++/31748 | |
1818 | * semantics.c (finish_omp_clauses): Use %qD instead of %qE for | |
1819 | DECL_P in not a variable and appears more than once error messages. | |
1820 | ||
af92ab36 OW |
1821 | 2007-07-01 Ollie Wild <aaw@google.com> |
1822 | ||
1823 | * name-lookup.c (ambiguous_decl): Fix case when new->value is hidden. | |
1824 | (select_decl): Remove function. | |
1825 | (unqualified_namespace_lookup): Populate binding by calling | |
1826 | ambiguous_decl. Remove select_decl call. | |
1827 | (lookup_qualified_name): Remove select_decl call. | |
1828 | * decl.c (lookup_and_check_tag): Check for ambiguous references. | |
1829 | * parser.c (cp_parser_elaborated_type_specifier): Skip redundant error | |
1830 | generation when name lookup is ambiguous. | |
1831 | ||
bfa8d90b DG |
1832 | 2007-06-29 Douglas Gregor <doug.gregor@gmail.com> |
1833 | ||
1834 | PR c++/31724 | |
1835 | * init.c (build_new_1): Use structural equality on the copy of the | |
1836 | array type. | |
1837 | ||
ddbfd28d GK |
1838 | 2007-06-28 Geoffrey Keating <geoffk@apple.com> |
1839 | ||
1840 | * decl2.c (determine_visibility): Implement | |
1841 | flag_visibility_ms_compat effect on type info. | |
1842 | * decl.c (cxx_init_decl_processing): Implement | |
1843 | global effect of flag_visibility_ms_compat. | |
1844 | ||
32d49134 GK |
1845 | 2007-06-28 Geoffrey Keating <geoffk@apple.com> |
1846 | ||
e301e2c4 | 1847 | * decl2.c (start_objects): Mark constructor-running function |
32d49134 GK |
1848 | as artificial. |
1849 | ||
b46ce77f SM |
1850 | 2007-06-26 Simon Martin <simartin@users.sourceforge.net> |
1851 | ||
1852 | PR c++/32111 | |
1853 | * decl.c (grokdeclarator): Reset friendp for member functions declared | |
1854 | friend of their own class. | |
1855 | ||
3a687f8b MM |
1856 | 2007-06-23 Mark Mitchell <mark@codesourcery.com> |
1857 | ||
1858 | * decl2.c (determine_visibility): Don't look for dllexport here. | |
1859 | (determine_visibility_from_class): Tidy. | |
1860 | ||
736b8100 SB |
1861 | 2007-06-18 Simon Baldwin <simonb@google.com> |
1862 | ||
1863 | PR c++/31923 | |
1864 | * parser.c (cp_parser_single_declaration): Added check for storage | |
1865 | class other than sc_none in parsed declaration, and a flag to indicate | |
1866 | if the call is part of an explicit template specialization parse. | |
1867 | * (cp_parser_explicit_specialization): Specialization check flag added | |
1868 | to call to cp_parser_single_declaration(), set true. | |
1869 | * (cp_parser_template_declaration_after_export): Specialization check | |
1870 | flag added to call to cp_parser_single_declaration(), set false. | |
1871 | * pt.c (check_explicit_specialization): Added code to copy visiblity | |
1872 | and linkage from the templated function to the explicit specialization. | |
1873 | ||
5be014d5 AP |
1874 | 2007-06-15 Andrew Pinski <andrew_pinski@playstation.sony.com> |
1875 | ||
1876 | * typeck.c (build_binary_op): For templates build the | |
1877 | expression in pieces to avoid the assert in build2_stat. | |
1878 | (get_member_function_from_ptrfunc): | |
1879 | Change over to using POINTER_PLUS_EXPR and convert | |
1880 | the second operand to sizetype. | |
1881 | * typeck2.c (build_m_component_ref): Likewise. | |
1882 | * init.c (expand_virtual_init): Create a POINTER_PLUS_EXPR | |
1883 | instead of PLUS_EXPR for pointers. | |
1884 | (build_new_1): Likewise. | |
1885 | (build_vec_delete_1): Likewise. | |
1886 | (build_vec_delete): Likewise. | |
1887 | * class.c (build_base_path): Likewise. | |
1888 | (build_base_path): Likewise. | |
1889 | (convert_to_base_statically): Likewise. | |
1890 | (fixed_type_or_null): Handle POINTER_PLUS_EXPR. | |
1891 | (get_vtbl_decl_for_binfo): Handle POINTER_PLUS_EXPR | |
1892 | instead of PLUS_EXPR. | |
1893 | (dfs_accumulate_vtbl_inits): Create a POINTER_PLUS_EXPR | |
1894 | instead of PLUS_EXPR for pointers. | |
1895 | * call.c (build_special_member_call): Likewise. | |
1896 | * rtti.c (build_headof): Likewise. | |
1897 | Use sizetype instead of ptrdiff_type_node. | |
1898 | (tinfo_base_init): Create a POINTER_PLUS_EXPR | |
1899 | instead of PLUS_EXPR for pointers. | |
1900 | * except.c (expand_start_catch_block): Do a | |
1901 | NEGATIVE and then a POINTER_PLUS_EXPR instead | |
1902 | of a MINUS_EXPR. | |
1903 | * cp-gimplify.c (cxx_omp_clause_apply_fn): Convert | |
1904 | PLUS_EXPR on pointer types over to use | |
1905 | POINTER_PLUS_EXPR and remove the conversion | |
1906 | to the pointer types. | |
1907 | * method.c (thunk_adjust): Use POINTER_PLUS_EXPR for | |
1908 | adding to a pointer type. Use size_int instead of | |
1909 | ssize_int. Convert the index to sizetype before | |
1910 | adding it to the pointer. | |
1911 | ||
555551c2 MM |
1912 | 2007-06-15 Mark Mitchell <mark@codesourcery.com> |
1913 | ||
1914 | * cp-tree.h (DECL_VAR_MARKED_P): Remove. | |
1915 | (DECL_ANON_UNION_VAR_P): New macro. | |
1916 | * class.c (fixed_type_or_null): Tidy. Use a hash table, rather | |
1917 | than DECL_VAR_MARKED_P, to keep track of which variables we have | |
1918 | seen. | |
1919 | * decl.c (redeclaration_error_message): Complain about redeclaring | |
1920 | anonymous union members at namespace scope. | |
1921 | * decl2.c (build_anon_union_vars): Set DECL_ANON_UNION_VAR_P. | |
1922 | ||
7dbd86a5 GK |
1923 | 2007-06-14 Geoff Keating <geoffk@apple.com> |
1924 | ||
c96f0001 GK |
1925 | * decl2.c (determine_visibility): Ensure that functions with |
1926 | hidden types as parameters are hidden. | |
1927 | ||
7dbd86a5 GK |
1928 | PR 31093 |
1929 | * decl2.c (determine_visibility): Remove duplicate code for | |
1930 | handling type info. | |
1931 | ||
058dcc25 ILT |
1932 | 2007-06-12 Ian Lance Taylor <iant@google.com> |
1933 | ||
1934 | PR libstdc++/29286 | |
1935 | * init.c (avoid_placement_new_aliasing): New static function. | |
1936 | (build_new_1): Call it. | |
1937 | ||
b0464c88 RE |
1938 | 2007-06-11 Rafael Avila de Espindola <espindola@google.com> |
1939 | ||
1940 | * cp-objcp-common.h (LANG_HOOKS_SIGNED_TYPE): Remove. | |
1941 | (LANG_HOOKS_SIGNED_OR_UNSIGNED_TYPE): Remove. | |
1942 | ||
969c111d JJ |
1943 | 2007-06-08 Jakub Jelinek <jakub@redhat.com> |
1944 | ||
1945 | PR c++/32177 | |
1946 | * semantics.c (finish_omp_for): Call fold_build_cleanup_point_expr | |
1947 | on init, the non-decl cond operand and increment value. | |
1948 | ||
c1ae8be5 SM |
1949 | 2007-06-07 Simon Martin <simartin@users.sourceforge.net> |
1950 | ||
1951 | PR c++/30759 | |
1952 | * decl.c (check_initializer): Report an error when a brace enclosed | |
1953 | initializer is used for a non-aggregate type in C++98. | |
1954 | (redeclaration_error_message): Rewrote flag_cpp0x in terms of | |
1955 | cxx_dialect. | |
1956 | (grokdeclarator): Likewise. | |
1957 | (move_fn_p): Likewise. | |
1958 | * typeck.c (check_return_expr): Likewise. | |
1959 | * call.c (reference_binding): Likewise. | |
1960 | * error.c (cp_cpp_error): Likewise. | |
1961 | * pt.c (check_default_tmpl_args): Likewise. | |
1962 | (tsubst): Likewise. | |
1963 | * lex.c (init_reswords): Likewise. | |
1964 | * parser.c (p_parser_primary_expression): Likewise. | |
1965 | (TOKEN_PRECEDENCE): Likewise. | |
1966 | (cp_parser_init_declarator): Likewise. | |
1967 | (cp_parser_ptr_operator): Likewise. | |
1968 | (cp_parser_parameter_declaration): Likewise. | |
1969 | (cp_parser_enclosed_template_argument_list): Likewise. | |
1970 | (cp_parser_skip_to_end_of_template_parameter_list): Likewise. | |
1971 | (cp_parser_next_token_ends_template_argument_p): Likewise. | |
1972 | ||
b08f991d SB |
1973 | 2007-06-04 Simon Baldwin <simonb@google.com> |
1974 | ||
1975 | * decl.c (grokdeclarator): Readability change. Moved case labels | |
1976 | into direct switch statement scope. | |
1977 | ||
cab203bf PC |
1978 | 2007-06-04 Paolo Carlini <pcarlini@suse.de> |
1979 | ||
1980 | * call.c (convert_like_real): Remove pointless code. | |
1981 | ||
46a9e521 MM |
1982 | 2007-05-31 Mark Mitchell <mark@codesourcery.com> |
1983 | ||
1984 | * decl.c (get_atexit_fn_ptr_type): New function. | |
1985 | (get_atexit_node): Use it. | |
1986 | (start_cleanup_fn): Likewise. | |
1987 | (register_dtor_fn): Use the object's destructor, instead of a | |
1988 | separate cleanup function, where possible. | |
1989 | * cp-tree.h (CPTI_ATEXIT_FN_PTR_TYPE): New enumerator. | |
1990 | (atexit_fn_ptr_type_node): New macro. | |
1991 | * decl2.c (build_cleanup): Use build_address. | |
1992 | ||
2c751309 DB |
1993 | 2007-05-31 Daniel Berlin <dberlin@dberlin.org> |
1994 | ||
1995 | * typeck.c (build_binary_op): Include types in error. | |
1996 | ||
32735518 JJ |
1997 | 2007-05-31 Jakub Jelinek <jakub@redhat.com> |
1998 | ||
1999 | PR c++/31806 | |
2000 | * decl.c (cp_finish_decl): Also clear was_readonly if a static var | |
2001 | needs runtime initialization. | |
2002 | ||
10c1d4af PC |
2003 | 2007-05-31 Paolo Carlini <pcarlini@suse.de> |
2004 | ||
2005 | PR c++/32158 | |
2006 | * semantics.c (finish_trait_expr): Complete the types. | |
2007 | ||
8af2fec4 RY |
2008 | 2007-05-30 Russell Yanofsky <russ@yanofsky.org> |
2009 | Douglas Gregor <doug.gregor@gmail.com> | |
2010 | Pedro Lamarao <pedro.lamarao@mndfck.org> | |
2011 | Howard Hinnant <howard.hinnant@gmail.com> | |
2012 | ||
2013 | PR c++/7412 | |
2014 | PR c++/29939 | |
2015 | * typeck.c (comptypes): Don't consider rvalue and lvalue | |
2016 | reference types to be equivalent. | |
2017 | (check_return_expr): Move from certain lvalues when returning | |
2018 | them. | |
2019 | * decl.c (grokdeclarator): Implement reference collapsing. | |
2020 | (copy_fn_p): Don't consider constructors taking rvalue references | |
2021 | to be copy constructors. | |
2022 | (move_fn_p): New. | |
5be014d5 | 2023 | * call.c (conversion): New "rvaluedness_matches_p" member. |
8af2fec4 RY |
2024 | (convert_class_to_reference): Require reference type as first |
2025 | parameter instead of base type. | |
2026 | (reference_binding): Add logic to handle rvalue references. | |
2027 | (implicit_conversion): Update inaccurate comment. | |
2028 | (convert_like_real): Disable creation of temporaries that are | |
2029 | impossible to initialize for types with move constructors. | |
2030 | (build_over_call): Elide move constructors when possible. | |
2031 | (maybe_handle_implicit_object): Set "rvaluedness_matches_p". | |
2032 | (maybe_handle_ref_bind): Return conversion instead of type node. | |
2033 | (compare_ics): Add logic to use "rvaluedness_matches_p" values to | |
2034 | determine preferred conversion sequences. | |
2035 | * cp-tree.h (TYPE_REF_IS_RVALUE): New. | |
2036 | (LOOKUP_PREFER_RVALUE): New. | |
2037 | (DECL_MOVE_CONSTRUCTOR_P): New. | |
2038 | (struct cp_declarator): Add "reference" member for reference | |
2039 | types, with new "rvalue_ref" flag. | |
2040 | (cp_build_reference_type): Declare. | |
2041 | (move_fn_p): Declare. | |
2042 | * error.c (dump_type_prefix): Format rvalue reference types | |
2043 | correctly in error messages. | |
2044 | * except.c (build_throw): Move from certain lvalues when | |
2045 | throwing. | |
2046 | * mangle.c (write_type): Mangle rvalue references differently | |
2047 | than regular references. | |
2048 | * parser.c (make_reference_declarator): Add boolean parameter for | |
2049 | rvalue references. | |
2050 | (cp_parser_make_indirect_declarator): New. | |
2051 | (cp_parser_new_declarator_opt): Call | |
2052 | cp_parser_make_indirect_declarator. | |
2053 | (cp_parser_conversion_declarator_opt): Ditto. | |
2054 | (cp_parser_declarator): Ditto. | |
2055 | (cp_parser_ptr_operator): Parse "&&" tokens into rvalue reference | |
2056 | declarators. | |
2057 | * pt.c (tsubst): Implement reference collapsing. | |
2058 | (maybe_adjust_types_for_deduction): Implement special template | |
2059 | parameter deduction rule for rvalue references. | |
2060 | (type_unification_real): Update calls to | |
2061 | maybe_adjust_types_for_deduction. | |
2062 | (try_one_overload): Ditto. | |
2063 | (unify_pack_expansion): Ditto. | |
2064 | * tree.c (lvalue_p_1): Handle rvalue reference types. | |
2065 | (cp_build_reference_type): New. | |
2066 | ||
27edb548 JJ |
2067 | 2007-05-30 Jakub Jelinek <jakub@redhat.com> |
2068 | ||
2069 | PR c++/31809 | |
2070 | * decl.c (cp_finish_decl): Clear TREE_READONLY flag on TREE_STATIC | |
2071 | variables that need runtime initialization. | |
2072 | ||
a87db577 AP |
2073 | 2007-05-28 Andrew Pinski <Andrew_pinski@playstation.sony.com> |
2074 | ||
5be014d5 | 2075 | PR c++/31339 |
a87db577 AP |
2076 | * typeck.c (build_unary_op <case PREINCREMENT_EXPR, |
2077 | case POSTINCREMENT_EXPR, case PREDECREMENT_EXPR, | |
2078 | case POSTDECREMENT_EXPR>): Return the error_mark_node | |
2079 | if either the real or imaginary parts would an | |
2080 | error_mark_node. | |
2081 | ||
1094da91 SM |
2082 | 2007-05-25 Simon Martin <simartin@users.sourceforge.net> |
2083 | Manuel Lopez-Ibanez <manu@gcc.gnu.org> | |
2084 | ||
2085 | PR c++/31745 | |
2086 | * parser.c (cp_parser_skip_to_closing_brace): Return true if the next | |
2087 | token is a closing brace, false if there are no tokens left. | |
2088 | (cp_parser_namespace_alias_definition): Only consume the next token if | |
2089 | it is a closing brace. | |
2090 | ||
2091 | * parser.c (cp_parser_class_specifier): Likewise. | |
2092 | ||
eb89f88c L |
2093 | 2007-05-25 H.J. Lu <hongjiu.lu@intel.com> |
2094 | ||
2095 | * semantics.c (finish_member_declaration): Fix a typo in the | |
2096 | last checkin. | |
2097 | ||
b1d7b1c0 DG |
2098 | 2007-05-25 Douglas Gregor <doug.gregor@gmail.com> |
2099 | ||
2100 | PR c++/31431 | |
2101 | PR c++/31432 | |
2102 | PR c++/31434 | |
2103 | PR c++/31435 | |
2104 | PR c++/31437 | |
2105 | PR c++/31438 | |
2106 | PR c++/31442 | |
2107 | PR c++/31443 | |
2108 | PR c++/31444 | |
2109 | PR c++/31445 | |
2110 | * error.c (dump_type): Dump TYPE_ARGUMENT_PACK nodes. | |
2111 | * cp-tree.h (check_for_bare_parameter_packs): Returns bool. | |
2112 | * pt.c (check_for_bare_parameter_packs): Return bool indicated | |
2113 | whether everything was okay. Fix indentation. | |
2114 | (push_template_decl_real): Check for bare parameter packs in | |
2115 | function parameters; where errors occur, mark the parameter types | |
2116 | with ERROR_MARK_NODEs to avert ICEs. | |
2117 | (coerce_template_parameter_pack): New. | |
2118 | (coerce_template_parms): Moved parameter pack coercion into | |
2119 | coerce_template_parameter_pack, and permit it anywhere in the | |
2120 | template parameter list (not just at the end). Parameter and | |
2121 | argument indices can vary (somewhat) separately now, so add | |
2122 | PARM_IDX and ARG_IDX. | |
2123 | (fn_type_unification): Don't set an argument pack as incomplete if | |
2124 | no argument pack was deduced. | |
2125 | (type_unification_real): If a type parameter is a parameter pack | |
2126 | and has not otherwise been deduced, it will be deduced to an empty | |
2127 | parameter pack. | |
2128 | (more_specialized_fn): Use the actual lengths of the argument | |
2129 | lists when comparing against expansions. | |
2130 | * semantics.c (finish_member_declaration): If a field's type has | |
2131 | bare parameter packs, error and set its type to ERROR_MARK_NODE. | |
2132 | ||
5234b8f5 DS |
2133 | 2007-05-24 Danny Smith <dannysmith@users.sourceforge.net> |
2134 | ||
2135 | PR target/27067 | |
2136 | * mangle.c (mangle_decl): Call targetm.mangle_decl_assembler_name. | |
2137 | ||
8e89cbfe OW |
2138 | 2007-05-22 Ollie Wild <aaw@google.com> |
2139 | ||
2140 | * name-lookup.c (ambiguous_decl): Adds check for hidden types. | |
2141 | (unqualified_namespace_lookup): Adds check for hidden types. | |
2142 | ||
6936461f OW |
2143 | 2007-05-22 Ollie Wild <aaw@google.com> |
2144 | ||
2145 | * decl.c (duplicate_decls): Verify namespace names are unique. | |
2146 | ||
5c113154 MM |
2147 | 2007-05-21 Mark Mitchell <mark@codesourcery.com> |
2148 | ||
2149 | * decl.c (cxx_maybe_build_cleanup): Handle | |
2150 | __attribute__((cleanup)). | |
2151 | ||
7060db96 MLI |
2152 | 2007-05-19 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2153 | ||
2154 | * cvt.c (cp_convert_and_check): Don't check warnings if the | |
2155 | conversion failed. | |
2156 | ||
8d5b1b67 GK |
2157 | 2007-05-18 Geoffrey Keating <geoffk@apple.com> |
2158 | ||
2159 | * mangle.c (write_real_cst): Use 'unsigned long' for %lx. | |
2160 | ||
9c49a5e4 PC |
2161 | 2007-05-14 Paolo Carlini <pcarlini@suse.de> |
2162 | ||
2163 | PR c++/29928 | |
2164 | * rtti.c (get_tinfo_decl_dynamic, get_typeid): Try to complete the | |
2165 | type only if is a class type (5.2.8/4). | |
2166 | ||
ca5ba2a3 RAE |
2167 | 2007-05-14 Rafael Avila de Espindola <espindola@google.com> |
2168 | ||
2169 | * cp-objcp-common.h (LANG_HOOKS_UNSIGNED_TYPE): Remove. | |
2170 | * decl.c (grokdeclarator): Use unsigned_type_for instead of | |
2171 | c_common_unsigned_type. | |
2172 | ||
79bedddc SR |
2173 | 2007-05-11 Silvius Rus <rus@google.com> |
2174 | ||
2175 | * cp/typeck.c (build_indirect_ref): Add call to | |
2176 | strict_aliasing_warning. | |
2177 | (build_reinterpret_cast_1): Condition call to | |
2178 | strict_aliasing_warning. | |
2179 | ||
7be82279 JH |
2180 | 2007-05-11 Jan Hubicka <jh@suse.cz> |
2181 | ||
2182 | * semantics.c (expand_or_defer_fn): Do not call c_record_cdtor_fn. | |
2183 | * decl2.c (start_objects): ctors and dtors are no longer public. | |
2184 | (cp_write_global_declarations): Do not call c_build_cdtor_fns. | |
2185 | ||
ee72fa38 AP |
2186 | 2007-05-07 Andrew Pinski <andrew_pinski@playstation.sony.com> |
2187 | ||
2188 | * typeck.c (build_unary_op): Remove code that used to | |
2189 | handle non lvalue increments/decrements. | |
2190 | ||
841cc7da MS |
2191 | 2007-05-07 Mike Stump <mrs@apple.com> |
2192 | ||
2193 | * parser.c (check_empty_body): Add. | |
2194 | (cp_parser_iteration_statement): Add call to check_empty_body. | |
2195 | ||
a2aa65f0 GK |
2196 | 2007-05-05 Geoffrey Keating <geoffk@apple.com> |
2197 | ||
2198 | PR 31775 | |
2199 | * mangle.c (write_mangled_name): Mangle static variable names. | |
2200 | (write_unqualified_name): Use local-source-name for | |
2201 | namespace-scope static variables. | |
2202 | ||
820b51ae DM |
2203 | 2007-05-04 Dirk Mueller <dmueller@suse.de> |
2204 | ||
2205 | * cp-tree.h (DECL_MAIN_P): only if -ffreestanding is | |
2206 | not in effect. | |
2207 | ||
ba992967 SP |
2208 | 2007-05-02 Seongbae Park <seongbae.park@gmail.com> |
2209 | ||
2210 | PR c++/31663 | |
2211 | * decl2.c (constrain_class_visibility): | |
2212 | Use strip_pointer_or_array_types instead of strip_array_types. | |
2213 | ||
70ec16f7 AP |
2214 | 2007-04-28 Andrew Pinski <andrew_pinski@playstation.sony.com> |
2215 | ||
2216 | PR C++/30221 | |
2217 | * decl.c (reshape_init_r): Don't reshape the first element if it | |
2218 | is a pointer to member function. | |
2219 | ||
631ee856 SB |
2220 | 2007-04-27 Simon Baldwin <simonb@google.com> |
2221 | ||
2222 | * decl.c (grokparms): Changed message format from %qD to %qE. | |
2223 | ||
4af96f9f DG |
2224 | 2007-04-27 Douglas Gregor <doug.gregor@gmail.com> |
2225 | ||
2226 | * error.c (maybe_warn_variadic_templates): Variadic templates are | |
2227 | now in C++0x, so only warn about them in C++98 mode. | |
2228 | ||
d333b74f AP |
2229 | 2007-04-26 Andrew Pinski <andrew_pinski@playstation.sony.com> |
2230 | ||
2231 | PR C++/30016 | |
2232 | * typeck.c (build_reinterpret_cast_1): Only allow conversion to | |
2233 | integeral types from vectors types. | |
2234 | ||
6f719560 JJ |
2235 | 2007-04-26 Jakub Jelinek <jakub@redhat.com> |
2236 | ||
2237 | PR c++/31598 | |
2238 | * semantics.c (finish_omp_clauses): Don't create CP_OMP_CLAUSE_INFO | |
2239 | for type dependent OMP_CLAUSE_DECLs. | |
2240 | ||
b8063b29 MM |
2241 | 2007-04-24 Mark Mitchell <mark@codesourcery.com> |
2242 | ||
fb0b79e5 | 2243 | PR c++/31338 |
b8063b29 MM |
2244 | * cp-tree.h (ARITHMETIC_TYPE): Include COMPLEX_TYPE. |
2245 | * typeck.c (type_after_usual_arithmetic_conversions): Adjust, as | |
2246 | COMPLEX_TYPE is now an ARITHMETIC_TYPE. | |
2247 | * init.c (build_zero_init): Adjust, as | |
2248 | COMPLEX_TYPE is now a SCALAR_TYPE. | |
2249 | * typeck2.c (digest_init): Allow brace-enclosed initializers for | |
2250 | COMPLEX_TYPE, even though that is now a SCALAR_TYPE. | |
2251 | ||
b29441ec PC |
2252 | 2007-04-25 Paolo Carlini <pcarlini@suse.de> |
2253 | ||
2254 | * semantics.c (classtype_has_nothrow_copy_or_assign_p): Adjust | |
2255 | per N2255; rename as classtype_has_nothrow_assign_or_copy_p. | |
2256 | (trait_expr_value): Adjust. | |
2257 | ||
0d83bf5a SB |
2258 | 2007-04-23 Simon Baldwin <simonb@google.com> |
2259 | ||
2260 | * decl.c (grokparms): Added new error for duplicate function | |
2261 | parameters names in function prototypes, to match gcc behavior. | |
2262 | ||
09191b7e JH |
2263 | 2007-04-23 Jan Hubicka <jh@suse.cz> |
2264 | ||
2265 | * cp/decl2.c (finish_objects): Do not call target constructor/destructor | |
2266 | bits dirrectly. | |
2267 | ||
3d95caa4 AP |
2268 | 2007-04-21 Andrew Pinski <andrew_pinski@playstation.sony.com> |
2269 | ||
2270 | * cp-tree.h (lang_tree_node): Use GENERIC_NEXT | |
2271 | instead of checking GIMPLE_STMT_P in chain_next. | |
2272 | ||
431ed7a1 MM |
2273 | 2007-04-17 Mark Mitchell <mark@codesourcery.com> |
2274 | ||
2275 | PR c++/31513 | |
2276 | * call.c (convert_for_arg_passing): Convert bitfields to their | |
2277 | declared types. | |
2278 | ||
f01ec37d SM |
2279 | 2007-04-17 Simon Martin <simartin@users.sourceforge.net> |
2280 | ||
2281 | PR c++/31517 | |
2282 | * pt.c (value_dependent_expression_p): Handle MODOP_EXPRs. | |
2283 | ||
fe24078a SP |
2284 | 2007-04-16 Seongbae Park <seongbae.park@gmail.com> |
2285 | ||
2286 | PR c++/29365 | |
fe24078a SP |
2287 | * cp/decl2.c (constrain_class_visibility): |
2288 | Do not warn about the use of anonymous namespace in the main input file. | |
2289 | ||
cac4ddf0 MM |
2290 | 2007-04-15 Mark Mitchell <mark@codesourcery.com> |
2291 | ||
2292 | * cp-tree.h (current_template_parms): Fix typo in comment. | |
2293 | ||
a57a55de KH |
2294 | 2007-04-15 Kazu Hirata <kazu@codesourcery.com> |
2295 | ||
2296 | * cp-tree.h, error.c: Fix comment typos. | |
2297 | ||
44ba4c4e JM |
2298 | 2007-04-13 Jason Merrill <jason@redhat.com> |
2299 | ||
2300 | PR c++/31074 | |
2301 | * call.c (reference_binding): Add c_cast_p parm. If true, | |
2302 | add quals to TO as needed to make it reference-compatible. | |
2303 | ||
ffd34392 JH |
2304 | 2007-04-11 Jan Hubicka <jh@suse.cz> |
2305 | ||
2306 | * cp/class.c (convert_to_base_statically): Fold produced tree; verify | |
2307 | that we are not processing template_decl. | |
2308 | ||
a607b96e MM |
2309 | 2007-04-09 Mark Mitchell <mark@codesourcery.com> |
2310 | ||
2311 | PR c++/31449 | |
2312 | * class.c (build_base_path): Ensure that the converted pointer has | |
2313 | the same cv-qualification as the input. | |
2314 | ||
ea798d0f PC |
2315 | 2007-04-09 Paolo Carlini <pcarlini@suse.de> |
2316 | ||
2317 | * tree.c (cp_tree_equal): Deal with TRAIT_EXPR. | |
2318 | ||
cb9c159d SB |
2319 | 2007-04-08 Steven Bosscher <steven@gcc.gnu.org> |
2320 | ||
2321 | * cp-objcp-common.h (LANG_HOOKS_TREE_INLINING_ADD_PENDING_FN_DECLS): | |
2322 | Do not set it. | |
2323 | (LANG_HOOKS_TREE_INLINING_ANON_AGGR_TYPE_P): Do not set it. | |
2324 | * tree.c (cp_add_pending_fn_decls): Remove. | |
2325 | * cp-tree.h (cp_add_pending_fn_decls): Remove prototype. | |
2326 | ||
270c60bb DB |
2327 | 2007-04-07 Daniel Berlin <dberlin@dberlin.org> |
2328 | ||
2329 | Revert change removing staticp. | |
2330 | ||
1df918ac DB |
2331 | 2007-04-06 Daniel Berlin <dberlin@dberlin.org> |
2332 | ||
2333 | * cp-objcp-common.c (cxx_staticp): Remove. | |
2334 | * cp-objcp-common.h (LANG_HOOKS_STATICP): Remove. | |
2335 | * cp-tree.h (cxx_staticp): | |
2336 | ||
6acd8838 DS |
2337 | 2007-04-04 Danny Smith <dannysmith.users.sourceforge.net> |
2338 | ||
2339 | * class.c (check_for_override): Don't remove dllmport attribute | |
2340 | of virtual methods. | |
2341 | ||
df3473fa JJ |
2342 | 2007-04-03 Jakub Jelinek <jakub@redhat.com> |
2343 | ||
2344 | PR c++/30847 | |
2345 | * typeck.c (build_modify_expr): For COND_EXPR on LHS, if RHS has void | |
2346 | type issue error and return early. | |
2347 | ||
c3b7031d JM |
2348 | 2007-03-30 Jason Merrill <jason@redhat.com> |
2349 | ||
2350 | PR c++/31187 | |
2351 | * typeck.c (cp_type_readonly): New fn. | |
2352 | * cp-tree.h: Declare it. | |
2353 | * decl.c (start_decl): Set implicit DECL_THIS_STATIC here. | |
2354 | (cp_finish_decl): Not here. | |
2355 | ||
6be42dd4 RG |
2356 | 2007-03-31 Richard Guenther <rguenther@suse.de> |
2357 | ||
2358 | * optimize.c (maybe_clone_body): Replace splay-tree usage by | |
2359 | pointer-map. | |
2360 | ||
d393153e DG |
2361 | 2007-03-31 Douglas Gregor <doug.gregor@gmail.com> |
2362 | ||
2363 | PR c++/31138 | |
2364 | PR c++/31140 | |
2365 | PR c++/31141 | |
2366 | * parser.c (declarator_can_be_parameter_pack): New. | |
2367 | (cp_parser_template_parameter): Only parse the `...' if the | |
2368 | declarator can be a parameter pack. | |
2369 | (cp_parser_parameter_declaration): Ditto. Also, handle when TYPE | |
2370 | is NULL. | |
2371 | * pt.c (find_parameter_packs_r): Look into the bounds on integer | |
2372 | types (they could be used as array bounds). | |
2373 | (check_for_bare_parameter_packs): Deal with TEMPLATE_PARM_INDEX. | |
2374 | (tsubst_pack_expansion): Handle failure to expand parameter | |
2375 | packs. | |
2376 | ||
cb68ec50 PC |
2377 | 2007-03-30 Paolo Carlini <pcarlini@suse.de> |
2378 | ||
2379 | PR c++/26099 | |
2380 | * cp-tree.h (enum cp_trait_kind, struct tree_trait_expr, | |
2381 | TRAIT_EXPR_TYPE1, TRAIT_EXPR_TYPE2, TRAIT_EXPR_KIND): Add. | |
2382 | (enum cp_tree_node_structure_enum, union lang_tree_node): Update. | |
2383 | (CLASS_TYPE_NON_UNION_P): Add. | |
2384 | (struct lang_type_class): Add has_complex_dflt. | |
2385 | (TYPE_HAS_COMPLEX_DFLT, TYPE_HAS_TRIVIAL_DFLT): Add. | |
2386 | (locate_copy, locate_ctor, locate_dtor, finish_trait_expr): Declare. | |
2387 | * cp-tree.def: Add TRAIT_EXPR. | |
2388 | * cp-objcp-common.c (cp_tree_size): Add TRAIT_EXPR case. | |
2389 | * lex.c (struct resword): Add __has_nothrow_assign, | |
2390 | __has_nothrow_constructor, __has_nothrow_copy, __has_trivial_assign, | |
2391 | __has_trivial_constructor, __has_trivial_copy, | |
2392 | __has_trivial_destructor, __has_virtual_destructor, __is_abstract, | |
2393 | __is_base_of, __is_class, __is_convertible_to, __is_empty, __is_enum, | |
2394 | __is_pod, __is_polymorphic, __is_union. | |
2395 | * parser.c (cp_parser_primary_expression): Deal with the new RIDs. | |
2396 | (cp_parser_trait_expr): New. | |
2397 | * semantics.c (finish_trait_expr, trait_expr_value | |
2398 | classtype_has_nothrow_copy_or_assign_p): New. | |
2399 | * method.c (locate_copy, locate_ctor, locate_dtor): Do not define | |
2400 | as static. | |
2401 | * decl.c (cp_tree_node_structure): Add TRAIT_EXPR. | |
2402 | * class.c (check_bases, check_field_decl, check_bases_and_members): | |
2403 | Deal with TYPE_HAS_COMPLEX_DFLT (t) too. | |
2404 | * pt.c (uses_template_parms, tsubst_copy_and_build, | |
2405 | value_dependent_expression_p, type_dependent_expression_p): Deal with | |
2406 | TRAIT_EXPR. | |
2407 | * tree.c (cp_walk_subtrees): Deal with TRAIT_EXPR. | |
2408 | ||
2a42f4aa RG |
2409 | 2007-03-29 Richard Guenther <rguenther@suse.de> |
2410 | ||
2411 | * tree.c (cp_walk_subtrees): Do not set input_location. | |
2412 | ||
71aea5f2 SM |
2413 | 2007-03-28 Simon Martin <simartin@users.sourceforge.net> |
2414 | ||
2415 | PR c++/29077 | |
2416 | * decl.c (grokfndecl): Properly setup decl if it is a constructor or a | |
2417 | destructor. | |
2418 | ||
a2ca1ab2 DG |
2419 | 2007-03-28 Douglas Gregor <doug.gregor@gmail.com> |
2420 | ||
2421 | * parser.c (struct cp_parser): Update comment for | |
2422 | greater_than_is_operator_p. | |
2423 | (cp_parser_primary_expression): In C++0x mode, a cast operator can | |
2424 | be terminated with a `>>' token when !GREATER_THAN_IS_OPERATOR_P. | |
2425 | (TOKEN_PRECEDENCE): In C++0x mode, `>>' is treated like `>' when | |
2426 | !GREATER_THAN_IS_OPERATOR_P. | |
2427 | (cp_parser_binary_expression): When -Wc++0x-compat, warn about | |
2428 | `>>' operators that will become two `>' tokens in C++0x. | |
2429 | (cp_parser_parameter_declaration): Treat `>>' like `>' in C++0x | |
2430 | mode, allowing it to terminate default arguments. | |
2431 | (cp_parser_enclosed_template_argument_list): In C++0x mode, treat | |
2432 | `>>' like two consecutive `>' tokens. | |
2433 | (cp_parser_skip_to_end_of_template_parameter_list): Ditto. | |
2434 | (cp_parser_next_token_ends_template_argument_p): In C++0x, `>>' | |
2435 | ends a template argument. | |
2436 | ||
9b7dd5e8 DG |
2437 | 2007-03-28 Douglas Gregor <doug.gregor@gmail.com> |
2438 | ||
2439 | * decl.c (redeclaration_error_message): Complain when redeclaring | |
2440 | a friend function with default template arguments (C++0x mode only). | |
2441 | * cp-tree.h (check_default_tmpl_args): Declare. | |
2442 | * pt.c (check_default_tmpl_args): In C++0x mode, permit default | |
2443 | template arguments in function templates. Add support for checking | |
2444 | the default template arguments of friend templates. | |
2445 | (push_template_decl_real): Fix call to check_default_tmpl_args. | |
2446 | (type_unification_real): If a template parameter has not been | |
2447 | deduced but provides a default template argument, substitute into | |
2448 | that default template argument. | |
2449 | * parser.c (cp_parser_init_declarator): When declaring (but not | |
2450 | defining!) a function template in C++0x mode, check for default | |
2451 | template arguments. | |
2452 | ||
771026dd DG |
2453 | 2007-03-28 Douglas Gregor <doug.gregor@gmail.com> |
2454 | ||
2455 | PR c++/29993 | |
2456 | * decl.c (grokdeclarator): Deal with cv-qualified function type | |
2457 | typedefs in the same way for member and non-member functions. | |
2458 | ||
df12b78f DM |
2459 | 2007-03-26 Dirk Mueller <dmueller@suse.de> |
2460 | ||
2461 | * parser.c (cp_parser_member_declaration): Pedwarn | |
2462 | about stray semicolons after member declarations. | |
2463 | ||
912291ca PC |
2464 | 2007-03-26 Paolo Carlini <pcarlini@suse.de> |
2465 | ||
2466 | PR c++/30500 | |
2467 | * pt.c (instantiate_decl): Set in_system_header. | |
2468 | ||
8b84995a MM |
2469 | 2007-03-22 Mark Mitchell <mark@codesourcery.com> |
2470 | ||
03c17ccd MM |
2471 | * cp-tree.h (current_tempalte_parms): Improve documentation. |
2472 | * pt.c (current_template_args): Likewise. | |
2473 | ||
8b84995a MM |
2474 | PR c++/30863 |
2475 | * parser.c (cp_parser_parse_and_diagnose_invalid_type_name): Do | |
2476 | not consume tokens when failing. | |
2477 | ||
725d6b87 MM |
2478 | 2007-03-22 Jim Wilson <wilson@specifix.com> |
2479 | Mark Mitchell <mark@codesourcery.com> | |
2480 | ||
2481 | PR c++/31273 | |
2482 | * call.c (standard_conversion): Use type_decays_to. Keep FCODE | |
2483 | consistent with FROM. | |
2484 | ||
5a023baa GDR |
2485 | 2007-03-22 Gabriel Dos Reis <gdr@integrable-solutions.net> |
2486 | ||
2487 | * error.c (dump_expr): Handle dependent names that designate types. | |
2488 | * cxx-pretty-print.c (pp_cxx_unqualified_id): Handle TYPENAME_TYPE. | |
2489 | ||
a757b5c5 KH |
2490 | 2007-03-17 Kazu Hirata <kazu@codesourcery.com> |
2491 | ||
2492 | * cp-tree.def, parser.c, pt.c: Fix comment typos. | |
2493 | ||
07231d4f MLI |
2494 | 2007-03-16 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2495 | ||
2496 | * cvt.c (cp_convert_and_check) : Define. | |
2497 | * cp-tree.h (cp_convert_and_check): Declare. | |
2498 | * call.c (convert_conversion_warnings): Rename to | |
2499 | conversion_null_warnings. The warning for floating-point to | |
2500 | integer is handled by convert_and_check in convert_like_real. | |
2501 | (convert_like_real): convert_conversion_warnings was renamed as | |
2502 | conversion_null_warnings. | |
2503 | * typeck.c (build_binary_op): Use cp_convert_and_check to warn for | |
2504 | overflow and changes of value during conversion. | |
2505 | ||
2ce88bea MLI |
2506 | 2007-03-15 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2507 | ||
2508 | PR c++/30891 | |
2509 | * parser.c (cp_parser_statement): If 'namespace' is found, this | |
2510 | only can be a namespace alias definition, so parse it now. | |
2511 | (cp_parser_namespace_alias_definition): if we find an open brace | |
2512 | instead of '=', then this is actually a misplaced namespace | |
2513 | definition. | |
2514 | ||
9b439fe1 MLI |
2515 | 2007-03-15 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2516 | ||
2517 | PR c++/24924 | |
2518 | * decl.c (cxx_init_decl_processing): Move command-line options | |
2519 | processing to c-opts.c. | |
2520 | ||
30bcc028 DG |
2521 | 2007-03-15 Douglas Gregor <doug.gregor@gmail.com> |
2522 | ||
2523 | * ptree.c (cxx_print_type): Use formatting markup for integers | |
2524 | when printing template parameter index/level/orig level. | |
2525 | (cxx_print_xnode): Ditto. | |
2526 | * cp-tree.h (TEMPLATE_PARM_PARAMETER_PACK): Use TREE_LANG_FLAG_0. | |
2527 | (struct template_parm_index_s): Remove the PARAMETER_PACK member. | |
2528 | Make INDEX, LEVEL, and ORIG_LEVEL integers instead of | |
2529 | HOST_WIDE_INTs. | |
2530 | (struct saved_scope): Make X_PROCESSING_TEMPLATE_DECL an int, | |
2531 | rather than a HOST_WIDE_INT. | |
2532 | Turn X_PROCESSING_EXPLICIT_INSTANTIATION, SKIP_EVALUATION, and | |
2533 | NEED_POP_FUNCTION_CONTEXT into bool bitfields; reorder fields for | |
2534 | better bit-packing. | |
2535 | (struct language_function): Make RETURNS_VALUE, RETURNS_NULL, | |
2536 | RETURNS_ABNORMALLY, IN_FUNCTION_TRY_HANDLER, and | |
2537 | IN_BASE_INITIALIZER bool bitfields. | |
2538 | (struct cp_declarator): Make KIND a 4-bit field. Make | |
2539 | PARAMETER_PACK_P a bool bitfield just after KIND. | |
2540 | * pt.c (uses_parameter_packs): Destroy the pointer set. | |
2541 | (make_pack_expansion): Ditto. | |
2542 | (check_for_bare_parameter_packs): Ditto. | |
2543 | * name-lookup.c (push_to_top_level): Make need_pop a bool value. | |
2544 | ||
344bd5a8 AP |
2545 | 2007-03-14 Andrew Pinski <andrew_pinski@playstation.sony.com> |
2546 | ||
2547 | PR c++/31165 | |
2548 | * call.c (convert_default_arg): Instead of copying the node, | |
2549 | unshare it. | |
2550 | ||
1f7f19c4 DM |
2551 | 2007-03-15 Dirk Mueller <dmueller@suse.de> |
2552 | ||
2553 | PR c++/30860 | |
2554 | * call.c (convert_conversion_warnings): New.. | |
2555 | (convert_like_real): .. factored out from here. | |
2556 | (convert_conversion_warnings): Add warning about | |
2557 | false being converted to NULL in argument passing. | |
2558 | ||
62e00e94 DM |
2559 | 2007-03-14 Dirk Mueller <dmueller@suse.de> |
2560 | ||
2561 | * cp/semantics.c (c_finish_if_stmt): Call empty_if_body_warning. | |
2562 | (finish_do_body): Warn about empty body in do/while statement. | |
2563 | ||
286d12f9 MLI |
2564 | 2007-03-14 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2565 | ||
2566 | * class.c (warn_hidden): Add OPT_Woverloaded_virtual to warning. | |
2567 | ||
2e9cb75e MLI |
2568 | 2007-03-14 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2569 | ||
2570 | PR c/21438 | |
2571 | * typeck.c (build_binary_op): Call warn_for_div_zero instead of | |
2572 | warning. | |
2573 | ||
403d4851 AO |
2574 | 2007-03-13 Alexandre Oliva <aoliva@redhat.com> |
2575 | ||
2576 | * cp/repo.c (init_repo): Initialize random_seed saved options. | |
2577 | (finish_repo): Adjust. | |
2578 | ||
4844b167 MM |
2579 | 2007-03-13 Mark Mitchell <mark@codesourcery.com> |
2580 | ||
2581 | PR bootstrap/30899 | |
2582 | * Make-lang.in (doc/g++.1): Use $< to specify the location from | |
2583 | which to copy. | |
2584 | ||
50d50fc7 SP |
2585 | 2007-03-12 Seongbae Park <seongbae.park@gmail.com> |
2586 | ||
2587 | * decl.c (compute_array_index_type): New warning flag warn_vla. | |
2588 | ||
3026f2df MM |
2589 | 2007-03-12 Mark Mitchell <mark@codesourcery.com> |
2590 | ||
2591 | PR c++/30108 | |
2592 | * call.c (convert_default_arg): Copy non-constant arguments. | |
2593 | ||
3c38f0ff MM |
2594 | 2007-03-11 Mark Mitchell <mark@codesourcery.com> |
2595 | ||
2596 | PR c++/31038 | |
2597 | * parser.c (cp_parser_postfix_expression): Disallow compound | |
2598 | literals in constant expressions. | |
2599 | ||
2600 | PR c++/30328 | |
2601 | * semantics.c (finish_typeof): Use unlowered_expr_type. | |
2602 | ||
f9aa54d3 MM |
2603 | 2007-03-10 Mark Mitchell <mark@codesourcery.com> |
2604 | ||
2605 | PR c++/30274 | |
2606 | * cp-tree.h (unlowered_expr_type): New function. | |
2607 | * typeck.c (is_bitfield_expr_with_lowered_type): Handle | |
2608 | COMPOUND_EXPR, MODIFY_EXPR, and SAVE_EXPR. | |
2609 | (unlowered_expr_type): New function. | |
2610 | (build_unary_op): Disallow predecrements of bool bitfields. | |
2611 | * call.c (build_conditional_expr): Use unlowered_expr_type. | |
2612 | * pt.c (type_unification_real): Likewise. | |
2613 | ||
5d80a306 DG |
2614 | 2007-03-09 Douglas Gregor <doug.gregor@gmail.com> |
2615 | ||
2616 | PR c++/20599 | |
2617 | * typeck.c (check_return_expr): Check for bare parameter packs. | |
2618 | (comptypes): Compare template parameter packs and | |
2619 | type pack expansions. | |
2620 | * decl.c (grokdeclarator): Deal with the declaration of function | |
2621 | parameter packs. | |
2622 | (grokparms): Verify that the (optional) function parameter pack is | |
2623 | at the end of the parameter list. | |
2624 | (xref_basetypes): Handle pack expansions in the base class. | |
2625 | (cp_tree_node_structure): Handle ARGUMENT_PACK_SELECT. | |
2626 | * cp-tree.def (TYPE_ARGUMENT_PACK): New. | |
2627 | (NONTYPE_ARGUMENT_PACK): New. | |
2628 | (TYPE_PACK_EXPANSION): New. | |
2629 | (EXPR_PACK_EXPANSION): New. | |
2630 | (ARGUMENT_PACK_SELECT): New. | |
2631 | * cp-objcp-common.c (cp_tree_size): Compute size of | |
2632 | (NON)TYPE_ARGUMENT_PACK, (TYPE|EXPR)_PACK_EXPANSION, and | |
2633 | ARGUMENT_PACK_SELECT. | |
2634 | * error.c (dump_template_argument): Print template argument packs. | |
2635 | (dump_template_argument_list): Ditto. | |
2636 | (dump_template_parameter): Dump `...' for template type parameter | |
2637 | packs. | |
2638 | (dump_type): Dump TYPE_PACK_EXPANSION nodes. | |
2639 | (dump_parameters): Print function parameter packs. | |
2640 | (dump_template_parms): Print template argument packs. | |
2641 | (dump_expr): Dump EXPR_PACK_EXPANSION nodes. | |
2642 | (maybe_warn_variadic_templates): New. | |
2643 | * operators.def: Add ellipsis operator for EXPR_PACK_EXPANSION. | |
2644 | * tree.c (cp_walk_subtrees): Walk BASELINK, TYPE_ARGUMENT_PACK, | |
2645 | NONTYPE_ARGUMENT_PACK, TYPE_PACK_EXPANSION, EXPR_PACK_EXPANSION, | |
2646 | CAST_EXPR. | |
2647 | * mangle.c (write_type): Mangle TYPE_PACK_EXPANSION. | |
2648 | (write_template_arg): Write argument packs as separate arguments. | |
2649 | * cp-tree.h (struct template_parm_index_s): Add flag that | |
2650 | indicates that the template parameter is actually a parameter | |
2651 | pack. | |
2652 | (struct tree_argument_pack_select): New. | |
2653 | (enum cp_tree_node_structure_enum): Add TS_CP_ARGUMENT_PACK_SELECT. | |
2654 | (union lang_tree_node): Add argument_pack_select. | |
2655 | (FUNCTION_PARAMETER_PACK_P): New. | |
2656 | (PACK_EXPANSION_P): New. | |
2657 | (PACK_EXPANSION_PATTERN): New. | |
2658 | (SET_PACK_EXPANSION_PATTERN): New. | |
2659 | (PACK_EXPANSION_PARAMETER_PACKS): New. | |
2660 | (ARGUMENT_PACK_P): New. | |
2661 | (ARGUMENT_PACK_ARGS): New. | |
2662 | (SET_ARGUMENT_PACK_ARGS): New. | |
2663 | (ARGUMENT_PACK_INCOMPLETE_P): New. | |
2664 | (ARGUMENT_PACK_EXPLICIT_ARGS): New. | |
2665 | (TEMPLATE_PARM_PARAMETER_PACK): New. | |
2666 | (TEMPLATE_TYPE_PARAMETER_PACK): New. | |
2667 | (ARGUMENT_PACK_SELECT_FROM_PACK): New. | |
2668 | (ARGUMENT_PACK_SELECT_INDEX): New. | |
2669 | (ARGUMENT_PACK_SELECT_ARG): New. | |
2670 | (struct cp_declarator): Add parameter_pack_p flag. | |
2671 | (maybe_warn_variadic_templates): Declare. | |
2672 | (process_template_parm): Add bool parameter IS_PARAMETER_PACK, to | |
2673 | indicate a template parameter pack. | |
2674 | (uses_parameter_packs): Declare. | |
2675 | (template_parameter_pack_p): Declare. | |
2676 | (template_parms_variadic_p): Declare. | |
2677 | (make_pack_expansion): Declare. | |
2678 | (check_for_bare_parameter_packs): Declare. | |
2679 | * cxx-pretty-print.c (pp_cxx_unary_expression): Print | |
2680 | sizeof... expressions. | |
2681 | (pp_cxx_expression): Print pack expansions and non-type argument | |
2682 | packs. | |
2683 | (pp_cxx_exception_specification): Print pack expansions. | |
2684 | (pp_cxx_direct_declarator): Print ellipsis for parameter packs. | |
2685 | (pp_cxx_ctor_initializer): Print pack expansions. | |
2686 | (pp_cxx_type_id): Print pack expansions. | |
2687 | (pp_cxx_template_argument_list): Print argument packs. | |
2688 | (pp_cxx_template_parameter): Print ellipsis for template parameter | |
2689 | packs. | |
2690 | * pt.c (comp_template_parms): Compare template parameter packs. | |
2691 | (template_parameter_pack_p): New. | |
2692 | (template_parms_variadic_p): New. | |
2693 | (template_args_variadic_p): New. | |
2694 | (make_ith_pack_parameter_name): New. | |
2695 | (struct find_parameter_pack_data): New. | |
2696 | (find_parameter_packs_r): New. | |
2697 | (uses_parameter_packs): New. | |
2698 | (make_pack_expansion): New. | |
2699 | (check_for_bare_parameter_packs): New. | |
2700 | (expand_template_argument_pack): New. | |
2701 | (reduce_template_parm_level): Propagate parameter pack flag. | |
2702 | (process_template_parm): Add is_parameter_pack parameter to state | |
2703 | when the parameter is actually a parameter pack. Create template | |
2704 | parameter packs when is_parameter_pack is true. | |
2705 | (current_template_args): The argument for a template parameter | |
2706 | pack is an argument pack containing a single pack expansion. | |
2707 | (process_partial_specialization): When checking that non-type | |
2708 | argument expressions do not involve template parameters, loop over | |
2709 | the arguments in argument packs separately. | |
2710 | (push_template_decl_real): Check that the type of the declaration | |
2711 | does not have any bare parameter packs. Check that primary | |
2712 | templates have no more than one parameter pack, and that it comes | |
2713 | at the end of the template parameter list. | |
2714 | (convert_template_argument): Handle coercions for pack expansion | |
2715 | expressions by coercing the pattern then rebuilding the expansion. | |
2716 | (coerce_template_parms): When coercing the arguments for a | |
2717 | variadic template, pack "extra" arguments into an argument pack. | |
2718 | (coerce_template_template_parms): Cannot coerce between parameter | |
2719 | packs and non-pack parameters. | |
2720 | (template_args_equal): Compare PACK_EXPANSION_P expressions. | |
2721 | (comp_template_args): Expand all template arguments packs before | |
2722 | comparing template argument lists. | |
2723 | (mangle_class_name_for_template): Make argument packs as separate | |
2724 | template arguments. | |
2725 | (for_each_template_parm_r): No need to handle BASELINK. | |
2726 | (instantiate_class_template): Handle pack expansions in the base | |
2727 | class list. | |
2728 | (tsubst_pack_expansion): New. | |
2729 | (tsubst_template_args): Handle substitutions of argument packs and | |
2730 | pack expansion into template argument lists. | |
2731 | (tsubst_decl): Expand function parameter packs into separate | |
2732 | function parameters. | |
2733 | (tsubst_arg_types): Expand a type pack expansion into separate | |
2734 | argument types. | |
2735 | (tsubst_exception_specification): Handle pack expansions in | |
2736 | exception specifiers. | |
2737 | (tsubst): See through ARGUMENT_PACK_SELECT arguments when | |
2738 | replacing a template parameter with its argument. If we encounter | |
2739 | a substitution for an argument pack, just return the parameter | |
2740 | itself. | |
2741 | (tsubst_copy): sizeof(X...) returns the number of elements in | |
2742 | parameter pack X. See through ARGUMENT_PACK_SELECT when the | |
2743 | PARM_DECL is a parameter pack. | |
2744 | (tsubst_expr): Expression pack expansions and argument packs | |
2745 | cannot show up here; they will all be handled through function | |
2746 | calls, sizeof, and template argument lists. | |
2747 | (tsubst_copy_and_build): sizeof(X...) returns the number of | |
2748 | elements in parameter pack X. Handle pack expansions in TREE_LIST | |
2749 | and CONSTRUCTOR nodes. | |
2750 | (fn_type_unification): Handle "incomplete" explicit template | |
2751 | argument lists that specify some of the arguments for a template | |
2752 | parameter pack. | |
2753 | (type_unification_real): Unify arguments against pack expansions. | |
2754 | (template_parm_level_and_index): New, helper function. | |
2755 | (unify_pack_expansion): New. | |
2756 | (unify): Unify argument packs on an argument-by-argument basis, | |
2757 | handling variadic argument packs as well. | |
2758 | (more_specialized_fn): Handle unification of function parameter | |
2759 | packs. All things being equal, prefer non-variadic function | |
2760 | templates to variadic function templates. | |
2761 | (more_specialized_class): Prefer the variadic class template | |
2762 | partial specialization that binds fewer arguments to a parameter | |
2763 | pack. | |
2764 | (regenerate_decl_from_template): Expand function parameter packs | |
2765 | into separate parameters. | |
2766 | (instantiate_decl): Ditto. | |
2767 | (tsubst_initializer_list): Handle pack expansions for base-class | |
2768 | initializers. | |
2769 | (dependent_type_p_r): Determine dependent types in argument packs | |
2770 | and pack expansions. | |
2771 | (value_dependent_expression_p): Determine value-dependence of | |
2772 | non-type argument packs. | |
2773 | (dependent_template_arg_p): Handle argument packs. | |
2774 | * semantics.c (finish_cond): Check for bare parameter packs. | |
2775 | (finish_expr_stmt): Ditto. | |
2776 | (finish_for_expr): Ditto. | |
2777 | (finish_switch_cond): Ditto. | |
2778 | (finish_mem_initializers): Ditto. | |
2779 | * name-lookup.c (arg_assoc_type): Handle pack expansions and | |
2780 | argument packs. | |
2781 | * decl2.c (cp_build_parm_decl): Mark function parameter packs. | |
2782 | * parser.c (make_declarator): Declarator is not an expansion. | |
2783 | (make_pointer_declarator): Transfer parameter pack flag to outer | |
2784 | declarator. | |
2785 | (make_reference_declarator): Ditto. | |
2786 | (make_ptrmem_declarator): Ditto. | |
2787 | (make_call_declarator): Ditto. | |
2788 | (make_array_declarator): Ditto. | |
2789 | (cp_parser_postfix_expression): Allow pack expansion expressions | |
2790 | in the argument list for a call expression. | |
2791 | (cp_parser_parenthesized_expression_list): Add new parameter | |
2792 | ALLOW_EXPANSION_P. When true, parse the ellipsis to mean "expand | |
2793 | into separate arguments." | |
2794 | (cp_parser_new_placement): Allow pack expansion expressions. | |
2795 | (cp_parser_new_initializer): Ditto. | |
2796 | (cp_parser_mem_initializer_list): Allow ellipsis to create a | |
2797 | base-class initializer expansion. | |
2798 | (cp_parser_mem_initializer): Ditto. | |
2799 | (cp_parser_template_parameter_list): Keep track of whether the | |
2800 | template parameter is a template parameter pack. | |
2801 | (cp_parser_template_parameter): Parse the ellipsis to indicate a | |
2802 | template parameter pack. | |
2803 | (cp_parser_type_parameter): Ditto. | |
2804 | (cp_parser_template_argument_list): Parse the ellipsis to indicate | |
2805 | a pack expansion. | |
2806 | (cp_parser_direct_declarator): Parse the ellipsis to indicate that | |
2807 | this declarator is a parameter pack. | |
2808 | (cp_parser_parameter_declaration): The ellipsis does not end the | |
2809 | parameter declaration, because it might be a parameter pack. Parse | |
2810 | the ellipsis to indicate a parameter pack. | |
2811 | (cp_parser_initializer): Allow pack expansions. | |
2812 | (cp_parser_initializer_list): Allow ellipsis to create an | |
2813 | initializer expansion. | |
2814 | (cp_parser_base_clause): Allow ellipsis to create a base specifier | |
2815 | expansion. | |
2816 | (cp_parser_type_id_list): Allow ellipsis to create an exception | |
2817 | specifier expansion. | |
2818 | (cp_parser_attribute_list): Don't allow pack expansions. | |
2819 | (cp_parser_functional_cast): Allow pack expansions. | |
2820 | (cp_parser_sizeof_operand): Allow ellipsis following "sizeof" to | |
2821 | compute the length of a parameter pack. | |
2822 | (cp_parser_next_token_ends_template_argument_p): An ellipsis can | |
2823 | end a template argument. | |
2824 | * tree.c (cp_walk_subtrees): Walk BASELINK, TYPE_ARGUMENT_PACK, | |
2825 | NONTYPE_ARGUMENT_PACK, TYPE_PACK_EXPANSION, EXPR_PACK_EXPANSION, | |
2826 | CAST_EXPR. | |
2827 | ||
63a08740 DM |
2828 | 2007-03-09 Dirk Mueller <dmueller@suse.de> |
2829 | ||
2830 | * cp/call.c (build_new_op): Call warn_logical_operator. | |
2831 | ||
cc891727 VR |
2832 | 2007-03-08 Volker Reichelt <reichelt@netcologne.de> |
2833 | ||
1916c916 VR |
2834 | PR c++/30852 |
2835 | * semantics.c (finish_offsetof): Handle COMPOUND_EXPR. | |
2836 | ||
cc891727 VR |
2837 | PR c++/30534 |
2838 | * pt.c (any_template_arguments_need_structural_equality_p): | |
2839 | Robustify. | |
2840 | ||
ab53bae2 AO |
2841 | 2007-03-08 Alexandre Oliva <aoliva@redhat.com> |
2842 | ||
2843 | * decl.c (grokdeclarator): Disable warnings for anonymous | |
2844 | bitfields. | |
2845 | ||
fabb00fc VR |
2846 | 2007-03-05 Volker Reichelt <reichelt@netcologne.de> |
2847 | ||
2848 | * typeck2.c (readonly_error): Always emit a hard error. | |
2849 | Remove last argument. | |
2850 | * cp-tree.h (readonly_error): Adjust prototype. | |
2851 | * semantics.c (finish_asm_stmt): Adjust call to readonly_error. | |
2852 | * typeck.c (build_unary_op): Likewise. | |
2853 | (build_modify_expr): Likewise. | |
2854 | ||
2a2193e0 SM |
2855 | 2007-03-04 Simon Martin <simartin@users.sourceforge.net> |
2856 | ||
2857 | PR c++/30895 | |
2858 | * tree.c (cp_tree_equal): Properly handle COMPLEX_CST trees. | |
2859 | ||
4606b05c MLI |
2860 | 2007-03-03 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2861 | ||
2862 | PR c++/15787 | |
2863 | * parser.c (struct cp_parser): New IN_IF_STMT. | |
2864 | (cp_parser_statement_seq_opt): Handle an unexpected 'else', | |
2865 | returning if parsing the body of an 'if' statement or issuing an | |
2866 | error and continuing. | |
2867 | (cp_parser_selection_statement): Set IN_IF_STMT bit when parsing | |
2868 | body of 'if'. | |
2869 | (cp_parser_jump_statement): Mask new IN_IF_STMT bit. | |
2870 | ||
49fedf5a SM |
2871 | 2007-03-02 Simon Martin <simartin@users.sourceforge.net> |
2872 | ||
2873 | PR c++/28253 | |
2874 | * class.c (update_vtable_entry_for_fn): Properly handle invalid overriders | |
2875 | for thunks. | |
2876 | ||
f9dedbe3 GK |
2877 | 2007-03-02 Geoffrey Keating <geoffk@apple.com> |
2878 | ||
2879 | * g++spec.c (lang_specific_driver): Add -lstdc++ when compiling | |
2880 | Objective-C++. Don't exit early if -shared-libgcc needs to be | |
2881 | added. | |
2882 | ||
4e223867 MLI |
2883 | 2007-03-02 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2884 | ||
2885 | * typeck.c (common_base_type): Delete unused function. | |
2886 | ||
7fe3e184 BM |
2887 | 2007-03-01 Brooks Moses <brooks.moses@codesourcery.com> |
2888 | ||
2889 | * Make-lang.in: Add dummy lang.install-pdf target. | |
2890 | ||
41dc91a8 SB |
2891 | 2007-03-01 Simon Baldwin <simonb@google.com> |
2892 | ||
2893 | PR c++/23689 | |
2894 | * decl.c (check_tag_decl): Added new warning for typedef ignored | |
2895 | when it precedes an otherwise valid non-typedef declaration. | |
2896 | ||
94a0dd7b SL |
2897 | 2007-02-28 Sandra Loosemore <sandra@codesourcery.com> |
2898 | ||
2899 | * typeck.c (build_function_call): Store converted arguments | |
2900 | in a stack-allocated array instead of building a list. | |
2901 | (convert_arguments): Store arguments in the array passed in as an | |
2902 | argument, and return the actual number of arguments. | |
2903 | * call.c (build_call): Delete, and replace with... | |
2904 | (build_call_n, build_call_a): New. | |
2905 | (build_op_delete_call): Rewrite to avoid constructing argument lists. | |
2906 | (build_over_call): Store converted arguments in a stack-allocated | |
2907 | array instead of building a list. | |
2908 | (build_cxx_call): Pass arguments in an array instead of as a list. | |
2909 | (build_java_interface_fn_ref): Rewrite to avoid constructing | |
2910 | argument lists. | |
2911 | * tree.h: Update declarations to reflect above changes. | |
2912 | * method.c (use_thunk): Use a stack-allocated array to hold | |
2913 | the arguments instead of a list. | |
2914 | * rtti.c (throw_bad_cast): Update call to cxx_call. | |
2915 | (throw_bad_typeid): Likewise. | |
2916 | (build_dynamic_cast_1): Likewise. | |
2917 | * init.c (build_builtin_delete_call): Use build_call_n. | |
2918 | * decl.c (expand_static_init): Likewise. | |
2919 | * except.c (cp_protect_cleanup_actions): Likewise. | |
2920 | * cp-gimplify.c (genericize_eh_spec_block): Likewise. | |
2921 | (gimplify_must_not_throw_expr): Likewise. | |
2922 | (cxx_omp_apply_fn): Use build_call_a. | |
2923 | ||
57a4c089 MM |
2924 | 2007-02-26 Mark Mitchell <mark@codesourcery.com> |
2925 | ||
2926 | * semantics.c (expand_or_defer_fn): Call c_record_cdtor_fn. | |
2927 | * decl2.c (cp_write_gloabl_declarations): Call c_build_cdtor_fns. | |
2928 | ||
fc8600f9 MM |
2929 | 2007-02-25 Mark Mitchell <mark@codesourcery.com> |
2930 | ||
2931 | * cp-tree.h (static_ctors): Remove. | |
2932 | * cp-tree.h (static_dtors): Likewise. | |
2933 | * cp-objcp-common.c (decl_shadowed_for_var_lookup): Adjust for | |
2934 | refactoring of tree_map hierarchy. | |
2935 | (decl_shadowed_for_var_insert): Likewise. | |
2936 | * semantics.c (expand_body): Use c_expand_body. | |
2937 | (expand_or_defer_fn): Don't update static_ctors or static_dtors. | |
2938 | * decl2.c (static_ctors): Remove. | |
2939 | (static_dtors): Likewise. | |
2940 | (generate_ctor_or_dtor_function): Pass NULL_TREE to | |
2941 | objc_generate_static_init_call. Do not call static_[cd]tors. | |
2942 | (generate_ctor_and_dtor_functions_for_priority): Do not check for | |
2943 | static_[cd]tors. | |
2944 | (cp_write_global_declarations): Likewise. | |
2945 | ||
2ae2031e RG |
2946 | 2007-02-23 Richard Guenther <rguenther@suse.de> |
2947 | ||
2948 | * class.c (note_name_declared_in_class): Make declaration | |
2949 | changes meaning a pedwarn. | |
2950 | ||
a0ad3539 MM |
2951 | 2007-02-22 Michael Matz <matz@suse.de> |
2952 | ||
2953 | PR c++/29433 | |
2954 | * cp-tree.h (TFF_UNQUALIFIED_NAME): New formatting flag. | |
2955 | * error.c (dump_aggr_type, dump_simple_decl, dump_decl, | |
2956 | dump_function_decl): Guard emitting outer scopes by new flag. | |
2957 | * cp-lang.c (cxx_dwarf_name): New function. | |
2958 | (LANG_HOOKS_DWARF_NAME): Define to cxx_dwarf_name. | |
2959 | * pt.c (classtype_mangled_name, mangle_class_name_for_template): | |
2960 | Remove functions. | |
2961 | (push_template_decl_real, lookup_template_class): Remove calls | |
2962 | to above functions. | |
2963 | ||
c88b0c50 MM |
2964 | 2007-02-19 Mark Mitchell <mark@codesourcery.com> |
2965 | ||
2966 | * call.c (build_new_method_call): Ensure that explicit calls of | |
2967 | destructors have type "void". | |
2968 | ||
c116cd05 MLI |
2969 | 2007-02-19 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2970 | ||
2971 | * typeck.c (build_binary_op): Replace -Wstring-literal-comparison | |
2972 | and -Walways-true with -Waddress. | |
2973 | * cvt.c (convert_to_void): Replace unconditional warning with | |
2974 | -Waddress. | |
2975 | ||
b9704fc5 KH |
2976 | 2007-02-18 Kazu Hirata <kazu@codesourcery.com> |
2977 | ||
2978 | * decl.c, tree.c: Fix comment typos. | |
2979 | ||
76b9a2a1 AP |
2980 | 2007-02-15 Andrew Pinski <andrew_pinski@playstation.sony.com> |
2981 | ||
2982 | PR C++/30158 | |
2983 | * semantics.c (finish_stmt_expr_expr): Set TREE_TYPE of the | |
2984 | statement expression if we had an error mark node. | |
5be014d5 | 2985 | |
5039610b SL |
2986 | 2007-02-15 Sandra Loosemore <sandra@codesourcery.com> |
2987 | Brooks Moses <brooks.moses@codesourcery.com> | |
2988 | Lee Millward <lee.millward@codesourcery.com> | |
2989 | ||
2990 | * cp-tree.def (AGGR_INIT_EXPR): Adjust documentation. | |
2991 | Change class to tcc_vl_exp. | |
2992 | ||
2993 | * call.c (build_call): Use build_call_list instead | |
2994 | of build3. | |
2995 | (build_over_call): Likewise. | |
2996 | (build_new_method_call): Use build_min_non_dep_call_list | |
2997 | instead of build_min_non_dep. | |
2998 | ||
2999 | * error.c (dump_call_expr_args): New function. | |
3000 | (dump_aggr_init_expr_args): New function. | |
3001 | (dump_expr) <AGGR_INIT_EXPR, CALL_EXPR, INDIRECT_REF>: Use them. | |
3002 | Update to use new CALL_EXPR and AGGR_INIT_EXPR accessor macros. | |
3003 | ||
3004 | * cvt.c (convert_to_void): Use build_call_array instead | |
3005 | of build3; use new AGGR_INIT_EXPR accessor macros. | |
3006 | ||
3007 | * mangle.c (write_expression): Use TREE_OPERAND_LENGTH | |
3008 | instead of TREE_CODE_LENGTH. | |
3009 | ||
3010 | * dump.c (cp_dump_tree) <AGGR_INIT_EXPR>: Update to use new | |
3011 | AGGR_INIT_EXPR accessor macros. | |
3012 | ||
3013 | * cp-gimplify.c (cp_gimplify_init_expr): Use | |
3014 | AGGR_INIT_EXPR_SLOT to set the slot operand. | |
3015 | ||
3016 | * cp-tree.h (AGGR_INIT_EXPR_FN): New macro. | |
3017 | (AGGR_INIT_EXPR_SLOT): New macro. | |
3018 | (AGGR_INIT_EXPR_ARG): New macro. | |
3019 | (aggr_init_expr_nargs): New macro. | |
3020 | (AGGR_INIT_EXPR_ARGP): New macro. | |
3021 | (aggr_init_expr_arg_iterator): New. | |
3022 | (init_aggr_init_expr_arg_iterator): New. | |
3023 | (next_aggr_init_expr_arg): New. | |
3024 | (first_aggr_init_expr_arg): New. | |
3025 | (more_aggr_init_expr_args_p): New. | |
3026 | (FOR_EACH_AGGR_INIT_EXPR_ARG): New. | |
3027 | (stabilize_aggr_init): New declaration. | |
3028 | (build_min_non_dep_call_list): Likewise. | |
3029 | ||
3030 | * tree.c (process_aggr_init_operands): New function. | |
3031 | (build_aggr_init_array) New function. | |
3032 | (build_cplus_new): Update to use new CALL_EXPR and | |
3033 | AGGR_INIT_EXPR accessor macros. Replace use of build3 with | |
3034 | build_aggr_init_array. | |
3035 | (build_min_non_dep_call_list) New function. | |
3036 | (build_min_nt): Assert input code parameter is not a variable | |
3037 | length expression class. | |
3038 | (build_min, build_min_non_dep): Likewise. | |
3039 | (cp_tree_equal) <CALL_EXPR>: Iterate through the arguments | |
3040 | to check for equality instead of recursing. Handle tcc_vl_exp | |
3041 | tree code classes. | |
3042 | (stabilize_call): Update to only handle CALL_EXPRs, not | |
3043 | AGGR_INIT_EXPRs; use new CALL_EXPR accessor macros. | |
3044 | (stabilize_aggr_init): New function. | |
3045 | (stabilize_init): Use it. | |
3046 | ||
3047 | * cxx-pretty-print.c (pp_cxx_postfix_expression) | |
3048 | <AGGR_INIT_EXPR, CALL_EXPR>: Update to use new CALL_EXPR and | |
3049 | AGGR_INIT_EXPR accessor macros and argument iterators. | |
3050 | ||
3051 | * pt.c (tsubst_copy) <CALL_EXPR>: Replace build_nt with | |
3052 | build_vl_exp. Iterate through the operands, recursively | |
3053 | processing each one. | |
3054 | (tsubst_copy_and_build) <CALL_EXPR>: Update to use new | |
3055 | CALL_EXPR accessor macros. | |
3056 | (value_dependent_expression_p) <default>: Handle tcc_vl_exp | |
3057 | tree code classes. Use TREE_OPERAND_LENGTH instead of | |
3058 | TREE_CODE_LENGTH. | |
3059 | ||
3060 | * semantics.c (finish_call_expr): Use build_nt_call_list | |
3061 | instead of build_nt. | |
3062 | (simplify_aggr_init_expr): Update to use new AGGR_INIT_EXPR | |
3063 | accessor macros. Use build_call_array to construct the | |
3064 | CALL_EXPR node instead of build3 | |
3065 | ||
3066 | * decl2.c (build_offset_ref_call_from_tree): Use | |
3067 | build_nt_call_list and build_min_non_dep_call_list instead | |
3068 | of build_min_nt and build_min_non_dep. | |
3069 | ||
3070 | * parser.c (cp_parser_postfix_expression) <CPP_OPEN_PAREN>: | |
3071 | Use build_nt_call_list instead of build_min_nt. | |
3072 | ||
21493102 MLI |
3073 | 2007-02-15 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
3074 | ||
3075 | PR c++/28943 | |
3076 | * call.c (build_conditional_expr): Improve error message. | |
3077 | ||
20af23d3 DM |
3078 | 2007-02-13 Dirk Mueller <dmueller@suse.de> |
3079 | ||
3080 | * friend.c (do_friend): Annotate warning about friend | |
3081 | declarations in templates with OPT_Wnon_template_friend. | |
3082 | Convert informal message from warning() to inform(). | |
3083 | ||
8ea6dfae SM |
3084 | 2007-02-12 Simon Martin <simartin@users.sourceforge.net> |
3085 | Mark Mitchell <mark@codesourcery.com> | |
3086 | ||
3087 | PR c++/14622 | |
3088 | * pt.c (do_decl_instantiation): Detect type mismatches in explicit | |
3089 | instantiations for variables. | |
3090 | ||
27f33b15 MLI |
3091 | 2007-02-12 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
3092 | ||
3093 | PR middle-end/7651 | |
3094 | * cp-gimplify.c (gimplify_expr_stmt): Don't check extra_warnings. | |
3095 | Check warn_unused_value just once. | |
3096 | ||
ba139ba8 MM |
3097 | 2007-02-11 Mark Mitchell <mark@codesourcery.com> |
3098 | ||
3099 | PR c++/26988 | |
3100 | * pt.c (determine_specialization): Use skip_artificial_parms_for. | |
3101 | (fn_type_unificiation): Likewise. | |
3102 | (get_bindings): Likewise. | |
3103 | ||
3104 | o2007-02-06 Mark Mitchell <mark@codesourcery.com> | |
56fd65c7 MM |
3105 | |
3106 | PR target/29487 | |
3107 | * decl.c (finish_function): Use DECL_REPLACEABLE. | |
3108 | * tree.c (cp_cannot_inline_tree_fn): Likewise. | |
3109 | ||
097552fa GDR |
3110 | 2007-02-10 Gabriel Dos Reis <gdr@integrable-solutions.net> |
3111 | ||
3112 | * parser.c (cp_parser_primary_expression): Reformat overly long lines. | |
3113 | ||
8893239d RH |
3114 | 2007-02-10 Richard Henderson <rth@redhat.com>, Jakub Jelinek <jakub@redhat.com> |
3115 | ||
3116 | * decl.c (grokvardecl): Don't error if !have_tls. | |
3117 | (grokdeclarator): Likewise. | |
3118 | * parser.c (cp_parser_omp_threadprivate): Likewise. | |
3119 | ||
e02a048f JJ |
3120 | 2007-02-07 Jakub Jelinek <jakub@redhat.com> |
3121 | ||
3122 | PR c++/30703 | |
3123 | * cp-gimplify.c (cp_genericize_r): Don't dereference invisiref | |
3124 | parameters and result decls in omp clauses. | |
3125 | (cxx_omp_privatize_by_reference): Pass also invisiref PARM_DECLs | |
3126 | by reference. | |
3127 | ||
583c0b05 DM |
3128 | 2007-02-05 Dirk Mueller <dmueller@suse.de> |
3129 | ||
3130 | PR bootstrap/30510 | |
3131 | * parser.c (cp_parser_class_specifier): Always initialize bases. | |
3132 | ||
4fe70b31 PB |
3133 | 2007-02-05 Paolo Bonzini <bonzini@gnu.org> |
3134 | ||
3135 | * cp-tree.h (OMP_ATOMIC_CODE): Delete. | |
3136 | (OMP_ATOMIC_DEPENDENT_P): Rewrite. | |
3137 | * pt.c (tsubst_expr): Adjust for new format of dependent OMP_ATOMIC | |
3138 | expressions. | |
3139 | * semantics.c (finish_omp_atomic): Store a whole expression node | |
3140 | in operand 1, and integer_zero_node in operand 0, for dependent | |
3141 | OMP_ATOMIC. Rewrite to make flow easier to understand. | |
3142 | ||
b10fc6f5 GDR |
3143 | 2007-02-03 Gabriel Dos Reis <gdr@integrable-solutions.net> |
3144 | ||
3145 | * decl.c (grokdeclarator): Use OPT_Wreturn_type instead of 0. | |
3146 | ||
3b426391 KH |
3147 | 2007-02-04 Kazu Hirata <kazu@codesourcery.com> |
3148 | ||
3149 | * class.c, cp-tree.h, decl.c, decl2.c, g++spec.c, init.c, | |
3150 | parser.c, pt.c, tree.c, typeck.c: Follow spelling conventions. | |
3151 | ||
f1283f8f DG |
3152 | 2007-02-03 Douglas Gregor <doug.gregor@gmail.com> |
3153 | ||
3154 | * parser.c (cp_lexer_get_preprocessor_token): Attach the C++0x | |
3155 | keyword warning to -Wc++0x-compat. | |
3156 | ||
5e32a5cf GDR |
3157 | 2007-02-03 Gabriel Dos Reis <gdr@integrable-solutions.net> |
3158 | ||
3159 | * decl.c (grokdeclarator): Update documentation. | |
3160 | ||
3e66d096 JJ |
3161 | 2007-02-02 Jakub Jelinek <jakub@redhat.com> |
3162 | ||
3163 | PR c++/30536 | |
3164 | * decl.c (grokdeclarator): If __thread is used together with | |
3165 | a storage class other than extern and static, clear thread_p | |
3166 | after issuing diagnostics and fall through to checking the | |
3167 | storage class. | |
3168 | ||
5e203bf8 RS |
3169 | 2007-01-30 Roger Sayle <roger@eyesopen.com> |
3170 | ||
3171 | * error.c (dump_type_suffix): Avoid use of cp_build_binary_op when | |
3172 | calculating the size of an array (to avoid recursive errors). | |
3173 | ||
b9edb4b1 MLI |
3174 | 2007-01-30 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
3175 | ||
3176 | PR c++/24745 | |
3177 | * typeck.c (build_binary_op): Fix logic for warning. Move warning | |
3178 | to -Wpointer-arith. | |
3179 | * call.c (convert_like_real): Don't warn when converting to | |
3180 | boolean type. | |
3181 | ||
c616e51b MLI |
3182 | 2007-01-29 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
3183 | ||
3184 | * decl.c (pop_label): Replace warning with call to | |
3185 | warn_for_unused_label. | |
3186 | ||
5cf10afb AP |
3187 | 2007-01-28 Andrew Pinski <pinskia@gmail.com> |
3188 | ||
3189 | PR C++/28988 | |
3190 | * semantics.c (finish_pseudo_destructor_expr): Check the | |
3191 | destrutor name by calling check_dtor_name. | |
3192 | ||
54654d29 DG |
3193 | 2007-01-24 Douglas Gregor <dgregor@osl.iu.edu> |
3194 | ||
3195 | * lex.c (D_CPP0X): Rename. | |
3196 | (D_CXX0X): To this. | |
3197 | (reswords): D_CPP0X -> D_CXX0X. | |
3198 | (init_reswords): Ditto. | |
3199 | * parser.c (cp_lexer_get_preprocessor_token): Warn about the use | |
3200 | of C++0x keywords as identifiers. | |
3201 | ||
815951d8 SM |
3202 | 2007-01-23 Simon Martin <simartin@users.sourceforge.net> |
3203 | ||
3204 | PR c++/27492 | |
3205 | * decl.c (duplicate_decls): Don't reset DECL_INVALID_OVERRIDER_P for | |
3206 | function decls. | |
3207 | ||
a99e5cb4 ILT |
3208 | 2007-01-23 Ian Lance Taylor <iant@google.com> |
3209 | ||
3210 | * typeck.c (convert_for_assignment): Only warn about a = b = c | |
3211 | when converting to bool. | |
3212 | ||
dc569621 RS |
3213 | 2007-01-23 Roger Sayle <roger@eyesopen.com> |
3214 | ||
3215 | * call.c (null_ptr_cst_p): Replace use of TREE_CONSTANT_OVERFLOW with | |
3216 | TREE_OVERFLOW. | |
3217 | * typeck.c (ignore_overflows): Remove the remaining uses of | |
3218 | TREE_CONSTANT_OVERFLOW. | |
3219 | ||
77dbd49b JH |
3220 | 2007-01-20 Jan Hubicka <jh@suse.cz> |
3221 | ||
3222 | * decl2.c (start_objects, start_static_storage_duration_function): | |
3223 | Do not make the functions uninlinable. | |
3224 | ||
efb7e1e0 ILT |
3225 | 2007-01-17 Ian Lance Taylor <iant@google.com> |
3226 | ||
3227 | * class.c (add_method): Call VEC_reserve_exact rather than passing | |
3228 | a negative size to VEC_reserve. | |
3229 | ||
6f9f76e3 SM |
3230 | 2007-01-11 Simon Martin <simartin@users.sourceforge.net> |
3231 | ||
3232 | PR c++/29573 | |
3233 | * tree.c (cp_tree_equal): Properly handle MODOP_EXPR trees. | |
3234 | ||
50ef2c18 MM |
3235 | 2007-01-10 Mark Mitchell <mark@codesourcery.com> |
3236 | ||
3237 | PR c++/28999 | |
3238 | * decl.c (make_typename_type): If the qualified name is not a | |
3239 | type, issue an error. | |
3240 | * parser.c (cp_parser_elaborated_type_specifier): Fix comment | |
3241 | formatting. | |
3242 | ||
157600d0 GK |
3243 | 2007-01-08 Geoffrey Keating <geoffk@apple.com> |
3244 | ||
3245 | * rtti.c: Include target.h. | |
3246 | (emit_support_tinfos): If ! targetm.cxx.library_rtti_comdat (), | |
3247 | don't emit typeinfo for fundamental types as weak. | |
3248 | * Make-lang.in (cp/rtti.o): Update and correct dependencies. | |
3249 | ||
2ac7cbb5 RG |
3250 | 2007-01-08 Richard Guenther <rguenther@suse.de> |
3251 | ||
3252 | * cvt.c (cp_convert_to_pointer): Use build_int_cst_type. | |
3253 | ||
00c8e9f6 MS |
3254 | 2007-01-08 Mark Shinwell <shinwell@codesourcery.com> |
3255 | ||
3256 | * call.c (standard_conversion): Pass flag to | |
3257 | vector_types_convertible_p to disallow emission of note. | |
3258 | * typeck.c (convert_for_assignment): Pass flag to | |
3259 | vector_types_convertible_p to allow emission of note. | |
3260 | (ptr_reasonably_similar): Pass flag to vector_types_convertible_p | |
3261 | to disallow emission of note. | |
3262 | ||
16fd4d2d MLI |
3263 | 2007-01-07 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
3264 | ||
3265 | PR c++/28986 | |
3266 | * typeck.c (build_binary_op): Call overflow_warning if | |
3267 | TREE_OVERFLOW_P is true for the result and not for any of the | |
3268 | operands. | |
3269 | ||
fc40d49c LM |
3270 | 2007-01-06 Lee Millward <lee.millward@codesourcery.com> |
3271 | ||
3272 | PR c++/19439 | |
3273 | * class.c (add_method): Don't wait until template | |
3274 | instantiation time to complain about duplicate methods. | |
3275 | ||
59c0753d MLI |
3276 | 2007-01-05 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
3277 | ||
3278 | PR c/19978 | |
3279 | * semantics.c (finish_unary_op_expr): Warn only if result | |
3280 | overflowed and operands did not. | |
3281 | ||
b3c6d2ea ILT |
3282 | 2007-01-05 Ian Lance Taylor <iant@google.com> |
3283 | ||
3284 | * typeck.c (build_binary_op): Warn about comparing a non-weak | |
3285 | address to NULL. | |
3286 | ||
3d761c46 DG |
3287 | 2007-01-05 Douglas Gregor <doug.gregor@gmail.com> |
3288 | ||
3289 | * pt.c (tsubst): Propagate the need for structural equality checks | |
3290 | when reducing the level of template parameters. | |
3291 | ||
c3e188fc KH |
3292 | 2007-01-03 Kazu Hirata <kazu@codesourcery.com> |
3293 | ||
3294 | * pt.c: Fix a comment typo. | |
3295 | ||
2c405565 | 3296 | 2007-01-02 Ian Lance Taylor <iant@google.com> |
fbc8d2d3 ILT |
3297 | |
3298 | * semantics.c (maybe_convert_cond): Optionally warn when using an | |
3299 | assignment as a condition. | |
3300 | * typeck.c (convert_for_assignment): Optionally warn about | |
3301 | assigning the result of an assignment to a bool. | |
3302 | ||
410cf6e6 DG |
3303 | 2007-01-02 Douglas Gregor <doug.gregor@gmail.com> |
3304 | ||
3305 | * pt.c (canonical_template_parms): Correct typo in comment. | |
3306 | ||
06d40de8 DG |
3307 | 2007-01-02 Douglas Gregor <doug.gregor@gmail.com> |
3308 | ||
3309 | * typeck.c (structural_comptypes): Renamed from "comptypes". | |
3310 | (comptypes): Use canonical type information to perform fast type | |
3311 | comparison. When VERIFY_CANONICAL_TYPES, verify that the | |
3312 | canonical type comparison returns the same results as we would see | |
3313 | from the current, structural check. Support COMPARE_STRUCTURAL | |
3314 | when we need structural checks. | |
3315 | * decl.c (typename_compare): Fix comment. | |
3316 | (build_typename_type): TYPENAME_TYPE nodes require structural | |
3317 | equality checks, because they resolve different based on the | |
3318 | current class type. | |
3319 | (make_unbound_class_template): UNBOUND_CLASS_TEMPLATE nodes | |
3320 | require structural equality checks (for now). | |
3321 | (build_ptrmemfunc_type): Build the canonical pointer to member | |
3322 | function type. | |
3323 | (compute_array_index_type): Whenever we build a new index type | |
3324 | to represent the size of an array in a template, we need to mark | |
3325 | this index type as requiring structural equality. This goes for | |
3326 | arrays with value-dependent sizes with the current ABI, or all | |
3327 | arrays with ABI-1. | |
3328 | * tree.c (cplus_array_hash): New. | |
3329 | (struct cplus_array_info): New. | |
3330 | (cplus_array_compare): New. | |
3331 | (cplus_array_htab): New. | |
3332 | (build_cplus_array_type_1): Use a hash table to cache the array | |
3333 | types we build. Build the canonical array type for each array | |
3334 | type. | |
3335 | (cp_build_qualified_type_real): When building a cv-qualified array | |
3336 | type, use the hash table of array types and build canonical array | |
3337 | types as necessary. | |
3338 | (bind_template_template_parm): BOUND_TEMPLATE_TEMPLATE_PARM nodes | |
3339 | use structural equality (for now). | |
3340 | * cp-tree.h (COMPARE_STRUCTURAL): New. | |
3341 | * pt.c (canonical_template_parms): New. | |
3342 | (canonical_type_parameter): New. | |
3343 | (process_template_parm): Find the canonical type parameter. | |
3344 | (lookup_template_class): When we have named the primary template | |
3345 | type, set the canonical type for our template class to the primary | |
3346 | template type. If any of the template arguments need structural | |
3347 | equality checks, the template class needs structural equality | |
3348 | checks. | |
3349 | (tsubst): When reducing the level of a template template | |
3350 | parameter, we require structural equality tests for the resulting | |
3351 | parameter because its template parameters have not had their types | |
3352 | canonicalized. When reducing a template type parameter, find the | |
3353 | canonical reduced type parameter. | |
3354 | (any_template_arguments_need_structural_equality_p): New. | |
3355 |