]>
Commit | Line | Data |
---|---|---|
ce75e1dd DE |
1 | 2008-11-06 David Edelsohn <edelsohn@gnu.org> |
2 | ||
3 | PR target/26397 | |
4 | * g++spec.c (LIBSTDCXX_STATIC): New. | |
5 | (lang_spec_driver): Use LIBSTDCXX_STATIC when not | |
6 | shared_libgcc. | |
7 | ||
8df7b2b6 FC |
8 | 2008-11-05 Fabien Chene <fabien.chene@gmail.com> |
9 | ||
10 | PR c++/35219 | |
11 | * cp-tree.h: Fix DECL_NONSTATIC_MEMBER_P to handle member template | |
12 | functions. | |
13 | ||
f7c0ffb4 RG |
14 | 2008-11-05 Richard Guenther <rguenther@suse.de> |
15 | ||
16 | PR middle-end/37742 | |
17 | * decl.c (start_preparsed_function): Use the correct type for | |
18 | building the RESULT_DECL. | |
19 | ||
0a3098bb JJ |
20 | 2008-10-31 Jakub Jelinek <jakub@redhat.com> |
21 | ||
4f48b9c1 JJ |
22 | PR c++/37967 |
23 | * decl.c (grokdeclarator): Diagnose auto function decl without | |
24 | late return type and late return type function decl where type | |
25 | is not auto. | |
26 | ||
0a3098bb JJ |
27 | PR c++/37965 |
28 | * decl.c (cp_finish_decl): Diagnose type_uses_auto type with | |
29 | no initializer. | |
30 | ||
cdd6a337 MLI |
31 | 2008-10-29 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
32 | ||
33 | PR 11492 | |
34 | * class.c (check_bitfield_decl): Rename min_precision to | |
35 | tree_int_cst_min_precision. | |
36 | * decl.c (finish_enum): Likewise. | |
37 | ||
d3f7b2c6 MLI |
38 | 2008-10-29 Manuel López-Ibáñez <manu@gcc.gnu.org> |
39 | ||
40 | PR c++/26997 | |
41 | * parser.c (cp_parser_token_starts_cast_expression): New. | |
42 | (cp_parser_cast_expression): Peek the next token to decide whether | |
43 | this could be a parenthesized constructor or is definitely an | |
44 | actual cast. | |
45 | ||
100d537d MLI |
46 | 2008-10-24 Manuel López-Ibáñez <manu@gcc.gnu.org> |
47 | ||
48 | PR c/7543 | |
49 | * typeck.c (build_x_binary_op): Update call to | |
50 | warn_about_parentheses. | |
51 | * parser.c (cp_parser_binary_expression): Add note about passing | |
52 | the correct code for unary expressions. | |
53 | ||
7134e605 JJ |
54 | 2008-10-24 Jakub Jelinek <jakub@redhat.com> |
55 | ||
56 | * Make-lang.in (check-c++-subtargets): New alias for | |
57 | check-g++-subtargets. | |
58 | (lang_checks_parallelized): Add check-g++. | |
59 | (check_g++_parallelize): New variable. | |
60 | ||
90e02569 RG |
61 | 2008-10-21 Richard Guenther <rguenther@suse.de> |
62 | ||
63 | * semantics.c (simplify_aggr_init_exprs_r): Remove. | |
64 | (expand_or_defer_fn): Do not walk the function body to | |
65 | simplify aggr_init_exprs. | |
66 | ||
98f2f3a2 MLI |
67 | 2008-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org> |
68 | ||
69 | PR c++/37004 | |
70 | * typeck.c (cp_common_type): New. The same as | |
71 | type_after_usual_arithmetic_conversions but without promotions. | |
72 | (type_after_usual_arithmetic_conversions): Do the promotions and | |
73 | call cp_common_type. | |
74 | (common_type): Make it behave like the C version of this | |
75 | function. Do not handle pointer types. | |
76 | (common_pointer_type): Move handling of pointer types from | |
77 | common_type to here. | |
78 | (cp_build_binary_op): Use common_pointer_type instead of | |
79 | common_type in call to pointer_diff. | |
80 | Use cp_common_type instead of common_type. | |
81 | * cp-tree.h (common_pointer_type): Declare. | |
82 | ||
d767aebf JJ |
83 | 2008-10-14 Jakub Jelinek <jakub@redhat.com> |
84 | ||
85 | PR c++/37819 | |
86 | * cp-gimplify.c (cp_genericize_r): Only fold_convert COND_EXPR | |
87 | arguments if they don't already have COND_EXPR's type. | |
88 | ||
b17c40be PC |
89 | 2008-10-14 Paolo Carlini <paolo.carlini@oracle.com> |
90 | ||
91 | PR c++/37650 | |
92 | * pt.c (push_template_decl_real): Check that current_template_parms | |
93 | is not null. | |
94 | (process_partial_specialization): Assert current_template_parms not | |
95 | null. | |
96 | ||
7f7aa9e1 DE |
97 | 2008-10-13 Doug Evans <dje@google.com> |
98 | ||
99 | * cp-tree.h (DECL_MAIN_P): Fix parentheses around expression. | |
100 | ||
bbdf5682 JJ |
101 | 2008-10-10 Jakub Jelinek <jakub@redhat.com> |
102 | ||
103 | PR c++/37146 | |
104 | * cp-gimplify.c (cp_genericize_r): Fix up bitfield operands of | |
105 | COND_EXPR. | |
106 | ||
2d188530 JJ |
107 | 2008-10-09 Jakub Jelinek <jakub@redhat.com> |
108 | ||
109 | PR c++/37568 | |
110 | * semantics.c (finalize_nrv_r): Clear DECL_INITIAL instead of | |
111 | setting it to error_mark_node. | |
112 | ||
3b14bb39 SE |
113 | 2008-10-07 Steve Ellcey <sje@cup.hp.com> |
114 | ||
115 | * decl.c (start_cleanup_fn): Declare as inline. | |
116 | ||
38179091 JM |
117 | 2008-10-06 Jason Merrill <jason@redhat.com> |
118 | ||
119 | PR c++/37376, other mangling issues | |
120 | * mangle.c (write_type): Update TYPE_PACK_EXPANSION mangling. | |
121 | (write_member_name): Break out from... | |
122 | (write_expression): ...here. Handle dependent COMPONENT_REF. | |
123 | (write_template_arg): Wrap an argument pack in 'I'/'E'. | |
124 | (write_builtin_type): Update char16/32_t mangling. | |
125 | (write_nested_name, write_prefix): Don't forget template args | |
126 | for typename types. | |
127 | * operators.def: Add ARROW_EXPR, update COMPONENT_REF and | |
128 | EXPR_PACK_EXPANSION. | |
129 | ||
c9f9eb5d AH |
130 | 2008-10-06 Aldy Hernandez <aldyh@redhat.com> |
131 | ||
132 | * typeck.c (build_x_indirect_ref): Add location argument. | |
133 | (cp_build_binary_op): Pass location to warn_for_div_by_zero. | |
134 | (cp_build_unary_op): Add location argument. | |
135 | (cp_build_modify_expr): Same. | |
136 | * class.c (build_base_path): Pass location to build_indirect_ref. | |
137 | * semantics.c (handle_omp_for_class_iterator): Pass elocus to | |
138 | build_modify_expr. | |
139 | ||
d19c0f4b DS |
140 | 2008-10-05 Dodji Seketeli <dodji@redhat.com> |
141 | ||
142 | PR c++/37410 | |
143 | * cp-gimplify.c (cp_gimplify_expr): For each USING_STMT | |
144 | make sure an IMPORTED_DECL node is added to the BLOCK_VARS list | |
145 | of the innermost containing BLOCK. | |
146 | ||
4d4e036d PC |
147 | 2008-10-03 Paolo Carlini <paolo.carlini@oracle.com> |
148 | ||
149 | PR c++/37719 | |
150 | * error.c (dump_function_decl): Save the exceptions in case of | |
151 | error about incompatible specifications in a specialization. | |
152 | ||
266b4890 AP |
153 | 2008-10-01 Andrew Pinski <andrew_pinski@playstation.sony.com> |
154 | ||
155 | * tree.c (lvalue_p_1): COMPOUND_LITERAL_EXPR is also an lvalue. | |
156 | ||
2d66eeeb L |
157 | 2008-09-30 H.J. Lu <hongjiu.lu@intel.com> |
158 | ||
159 | PR c++/37683 | |
160 | * parser.c (cp_parser_selection_statement): Fix uninitialized | |
161 | variable. | |
162 | ||
dcbdf612 SM |
163 | 2008-09-30 Simon Martin <simartin@users.sourceforge.net> |
164 | ||
165 | PR c++/37555 | |
166 | PR c++/37556 | |
167 | * decl.c (grokdeclarator): Set the type for typedefs to a | |
168 | nested-name-specifier to error_mark_node. | |
169 | ||
626c34b5 PB |
170 | 2008-09-30 Paolo Bonzini <bonzini@gnu.org> |
171 | ||
172 | * parser.c (cp_parser_selection_statement): Implement here the | |
173 | -Wempty-body warning for `if' and `else' statements. | |
174 | * semantics.c (finish_if_stmt): Do not call empty_body_warning. | |
175 | ||
79faac54 PC |
176 | 2008-09-25 Paolo Carlini <paolo.carlini@oracle.com> |
177 | ||
178 | PR c++/37649 | |
179 | * name-lookup.c (maybe_process_template_type_declaration): Check | |
180 | return value of push_template_decl_real for error_mark_node. | |
181 | ||
3ba09659 AH |
182 | 2008-09-24 Aldy Hernandez <aldyh@redhat.com> |
183 | ||
184 | * semantics.c (finish_fname): Pass location to fname_decl. | |
185 | ||
8569b2d0 JJ |
186 | 2008-09-23 Jakub Jelinek <jakub@redhat.com> |
187 | ||
188 | PR c++/37533 | |
189 | * semantics.c (finish_omp_for): If processing_template_decl, just build | |
190 | MODIFY_EXPR for init instead of calling cp_build_modify_expr. | |
191 | ||
ba47d38d AH |
192 | 2008-09-23 Aldy Hernandez <aldyh@redhat.com> |
193 | ||
194 | * typeck.c (build_array_ref): Pass location to cp_build_binary_op. | |
195 | (get_member_function_from_ptrfunc): Same. | |
196 | (build_x_binary_op): Same. | |
197 | (build_binary_op): Same. | |
198 | (cp_build_binary_op): New location argument. | |
199 | (pointer_diff): Pass location to cp_build_binary_op. | |
200 | (cp_truthvalue_conversion): Pass location to build_binary_op. | |
201 | (convert_ptrmem): Pass location to cp_build_binary_op. | |
202 | (cp_build_modify_expr): Same. | |
203 | (build_ptrmemfunc): Same. | |
204 | * init.c (expand_cleanup_for_base): Pass location to | |
205 | c_common_truthvalue_conversion. | |
206 | (build_new_1): Pass location to cp_build_binary_op. | |
207 | (build_vec_delete_1): Pass location to *build_binary_op, | |
208 | c_common_truthvalue_conversion. | |
209 | (build_vec_init): Same. | |
210 | (build_delete): Same. | |
211 | * decl.c (compute_array_index_type): Same. | |
212 | * call.c (build_new_op): Same. | |
213 | * rtti.c (build_dynamic_cast_1): Same. | |
214 | * cp-tree.h: Add argument to cp_build_binary_op. | |
215 | * semantics.c (handle_omp_for_class_iterator): Pass location to | |
216 | *build_binary_op, c_common_truthvalue_conversion. | |
217 | * decl2.c (get_guard_cond): Same. | |
218 | ||
c74147d2 RG |
219 | 2008-09-17 Richard Guenther <rguenther@suse.de> |
220 | ||
221 | PR c++/22374 | |
222 | * rtti.c (build_dynamic_cast_1): Convert the COND_EXPR | |
223 | result to the correct type. | |
224 | ||
52a764ac L |
225 | 2008-09-17 H.J. Lu <hongjiu.lu@intel.com> |
226 | ||
227 | PR c++/37450 | |
228 | * name-lookup.c (pushdecl_maybe_friend): Don't return the old | |
229 | parameter for duplicate. | |
230 | ||
118dde55 JM |
231 | 2008-09-17 Jason Merrill <jason@redhat.com> |
232 | ||
233 | PR c++/37588 | |
234 | * name-lookup.c (lookup_type_scope): Look through sk_function_parms. | |
235 | ||
8aff539b JJ |
236 | 2008-09-17 Jakub Jelinek <jakub@redhat.com> |
237 | ||
238 | PR c++/37552 | |
239 | * typeck.c (build_array_ref): Use protected_set_expr_location instead | |
240 | of SET_EXPR_LOCATION when ret might not be an expression. | |
241 | ||
0494626a JH |
242 | 2008-09-17 Jan Hubicka <jh@suse.cz> |
243 | ||
244 | PR c++/18071 | |
245 | * cp/decl.c (start_method): Set DECL_NO_INLINE_WARNING_P. | |
246 | ||
08222495 JJ |
247 | 2008-09-16 Jakub Jelinek <jakub@redhat.com> |
248 | ||
326a4d4e JJ |
249 | PR c++/37531 |
250 | * semantics.c (finish_compound_literal): Return error_mark_node if | |
251 | type is errorneous. | |
252 | ||
08222495 JJ |
253 | PR c++/37532 |
254 | * lex.c (init_reswords): Don't populate ridpointers for D_CONLY | |
255 | reserved words. | |
256 | ||
402b8cf6 AH |
257 | 2008-09-15 Aldy Hernandez <aldyh@redhat.com> |
258 | ||
259 | * decl.c (duplicate_decls): Call error_at. | |
260 | (grokfndecl): New location argument. Use location if available. | |
261 | (grokdeclarator): Pass declarator location to grokfndecl. | |
262 | * cp-tree.h (struct cp_declarator): Update comment for id_loc. | |
263 | * decl2.c (check_classfn): Use error_at. | |
264 | * parser.c (cp_parser_init_declarator): Set function_start_locus | |
265 | to brace location. | |
266 | (cp_parser_member_declaration): Set id_loc for function declarators. | |
267 | ||
29d7f409 JH |
268 | 2008-09-09 Jan Hubicka <jh@suse.cz> |
269 | ||
270 | PR middle-end/37500 | |
271 | * pt.c (tsubst_decl): Do not copy DECL_STRUCT_FUNCTION pointer. | |
272 | ||
701e903a JJ |
273 | 2008-09-09 Jakub Jelinek <jakub@redhat.com> |
274 | ||
275 | PR c++/37417 | |
276 | * tree.c (array_type_nelts_top): Add size_one_node instead of | |
277 | integer_one_node. | |
278 | ||
18802917 JM |
279 | 2008-09-09 Jason Merrill <jason@redhat.com> |
280 | ||
281 | PR c++/37439 | |
282 | * pt.c (tsubst_copy) [PARM_DECL]: Don't abort if the parm has | |
283 | DECL_CONTEXT set. | |
284 | ||
0f7a47dd JJ |
285 | 2008-09-09 Jakub Jelinek <jakub@redhat.com> |
286 | ||
287 | PR c++/37389 | |
288 | * decl.c (build_enumerator): Handle previous value's DECL_INITIAL | |
289 | being error_operand_p. Don't clear value if it was error_mark_node. | |
290 | ||
0c03f46f PB |
291 | 2008-09-09 Paolo Bonzini <bonzini@gnu.org> |
292 | ||
293 | * cp-objcp-common.h (LANG_HOOKS_EXPAND_DECL): Remove. | |
294 | * cp-tree.h: Don't mention DECL_ANON_UNION_ELEMS. | |
295 | * semantics.c (anon_aggr_type_p): Remove. | |
296 | ||
b344d949 JM |
297 | 2008-09-06 Jason Merrill <jason@redhat.com> |
298 | ||
299 | PR c++/37302 | |
300 | * parser.c (cp_parser_parameter_declaration_list): Process the | |
301 | PARM_DECLs as we go and push them. Return a TREE_LIST. | |
302 | (cp_parser_parameter_declaration_clause): Return a TREE_LIST. | |
303 | (cp_parser_direct_declarator): Create a binding level and | |
304 | suppress deprecated warnings in the parameter list. | |
305 | (make_call_declarator): PARMS is now a tree. | |
306 | * cp-tree.h (struct cp_declarator): Function parms are now a tree. | |
307 | * decl.h (enum deprecated_states, deprecated_state): Move here. | |
308 | * decl.c: From here. | |
309 | (type_is_deprecated): New fn. | |
310 | (grokparms): PARMLIST is a tree now. Warn about parms that | |
311 | use deprecated types. | |
312 | * mangle.c (write_expression): Handle PARM_DECL, CALL_EXPR and | |
313 | 0-operand cast. | |
314 | * pt.c (tsubst) [DECLTYPE_TYPE]: Set skip_evaluation. | |
315 | (tsubst_copy) [PARM_DECL]: Handle a PARM_DECL used outside of a | |
316 | function. | |
317 | * name-lookup.c (pushtag): Look through function parameter scopes. | |
318 | (pushdecl_maybe_friend): Don't set DECL_CONTEXT on a PARM_DECL | |
319 | when we're parsing a function declarator. | |
320 | ||
7aa4a1df DG |
321 | 2008-09-05 Douglas Gregor <doug.gregor@gmail.com> |
322 | ||
323 | PR c++/37342 | |
324 | * tree.c (cp_build_qualified_type_real): Deal with sharing of | |
325 | TYPE_LANG_SPECIFIC in the canonical types of pointer-to-method | |
326 | types. | |
327 | ||
e0c68ce9 ILT |
328 | 2008-09-04 Ian Lance Taylor <iant@google.com> |
329 | ||
330 | * parser.c (check_no_duplicate_clause): Change code parameter to | |
331 | enum omp_clause_code. | |
332 | ||
3368cdd3 JJ |
333 | 2008-09-03 Jakub Jelinek <jakub@redhat.com> |
334 | ||
3e03c959 JJ |
335 | PR c++/37348 |
336 | * decl.c (cp_finish_decl): Only set | |
337 | DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P if decl is VAR_DECL. | |
338 | ||
3368cdd3 JJ |
339 | PR c++/37189 |
340 | * cp-tree.h (defer_mark_used_calls, deferred_mark_used_calls): New | |
341 | extern decls. | |
342 | * decl2.c (mark_used): If defer_mark_used_calls, push decl into | |
343 | deferred_mark_used_calls vector and exit early. | |
344 | * decl.c (defer_mark_used_calls, deferred_mark_used_calls): New | |
345 | variables. | |
346 | (finish_function): Set defer_mark_used_calls for the duration of the | |
347 | function. Call mark_used on any queued decls. | |
348 | ||
4ad610c9 JM |
349 | 2008-09-02 Jason Merrill <jason@redhat.com> |
350 | ||
351 | PR c++/37208 | |
352 | * call.c (build_over_call): Make =delete work with SFINAE. | |
353 | * class.c (resolve_address_of_overloaded_function): Likewise. | |
354 | ||
355 | * cp-tree.h (struct lang_decl_flags): Rename threadprivate_p to | |
356 | threadprivate_or_deleted_p. | |
357 | (CP_DECL_THREADPRIVATE_P): Adjust. | |
358 | (DECL_DELETED_FN): Likewise. | |
359 | (SD_UNINITIALIZED, SD_INITIALIZED, SD_DEFAULTED): New macros. | |
360 | (SD_DELETED): New macro. | |
361 | * parser.c (cp_parser_init_declarator): Use them. | |
362 | * decl.c (start_decl): Use them. | |
363 | ||
364 | * decl2.c (mark_used): Give =deleted error even in sizeof. | |
365 | ||
366 | * typeck2.c (check_narrowing): Downgrade narrowing error to | |
367 | permerror. | |
368 | ||
a63068b6 AH |
369 | 2008-09-02 Aldy Hernandez <aldyh@redhat.com> |
370 | ||
371 | * typeck.c (build_array_ref): Use new location argument. | |
372 | * class.c (build_vtbl_ref_1): Pass location to build_array_ref. | |
373 | * call.c (build_new_op): Same. | |
374 | * decl2.c (grok_array_decl): Same. | |
375 | * cp-tree.h (build_array_ref): Add location argument to prototype. | |
376 | ||
6a3799eb AH |
377 | 2008-09-01 Aldy Hernandez <aldyh@redhat.com> |
378 | ||
379 | * typeck.c (build_x_indirect_ref): Add location argument. | |
380 | * class.c (build_base_path): Pass location to build_indirect_ref. | |
381 | * pt.c (tsubst_copy_and_build): Pass location to | |
382 | finish_label_address_expr. | |
383 | * parser.c (cp_parser_unary_expression): Same. | |
384 | ||
f57ca1ea JM |
385 | 2008-08-31 Jason Merrill <jason@redhat.com> |
386 | ||
387 | Implement late-specified return type using 'auto'. | |
388 | * cp-tree.h (struct cp_declarator): Add late_return_type field to | |
389 | function declarator. | |
390 | * parser.c (cp_parser_late_return_type_opt): New fn. | |
391 | (cp_parser_direct_declarator): Use it. | |
392 | (make_call_declarator): Put it in the declarator. | |
393 | * decl.c (grokdeclarator): Splice in late-specified return type. | |
394 | * pt.c (splice_late_return_type): New fn. | |
395 | ||
5779e713 MM |
396 | 2008-08-29 Michael Meissner <gnu@the-meissners.org> |
397 | ||
398 | * decl.c (builtin_function_1): Take a bool argument to decide | |
399 | whether to use pushdecl or pushdecl_top_level. | |
400 | (duplicate_decls): Copy function specific target and optimization | |
401 | options on duplicate declarations. | |
402 | (cxx_builtin_function): Update builtin_function_1 call. | |
403 | (cxx_builtin_function_ext_scope): New function, guarantee that the | |
404 | declaration is done at global scope. | |
405 | ||
406 | * cp-objcp-common.h (LANG_HOOKS_BUILTIN_FUNCTION_EXT_SCOPE): New | |
407 | macro, define builtin function hook for delayed machine specific | |
408 | builtins. | |
409 | ||
410 | * cp-tree.h (cxx_builtin_function_ext_scope): Add declaration. | |
411 | ||
0257eee5 JM |
412 | 2008-08-30 Jason Merrill <jason@redhat.com> |
413 | ||
414 | PR c++/37288 | |
415 | * pt.c (dependent_type_p): Don't abort on auto outside of a template. | |
416 | ||
86a09a9e JM |
417 | 2008-08-29 Jason Merrill <jason@redhat.com> |
418 | ||
419 | Implement C++0x 'auto' semantics. | |
420 | * decl.c (start_decl_1): Don't complain about auto being incomplete. | |
421 | (cp_finish_decl): Deduce auto. | |
422 | * init.c (build_new): Handle 'new auto'. | |
423 | * typeck2.c (cxx_incomplete_type_diagnostic): Give a different | |
424 | message for auto than for normal template type parms. | |
425 | * pt.c (type_dependent_expression_p): Handle { }. | |
426 | (make_auto): New function. | |
427 | (listify_autos): New function. | |
428 | (do_auto_deduction): New function. | |
429 | (is_auto): New function. | |
430 | (type_uses_auto): New function. | |
431 | * cp-tree.h: Declare them. | |
432 | * parser.c (cp_parser_decl_specifier_seq): In C++0x mode, don't | |
433 | treat auto as a declspec. | |
434 | (cp_parser_simple_type_specifier): It's a type-specifier. | |
435 | ||
3852d2be MM |
436 | 2008-08-29 Mark Mitchell <mark@codesourcery.com> |
437 | ||
438 | * mangle.c (write_type): Add target-specific manglings for | |
439 | non-fundamental types to the substitution table. | |
440 | gcc/testsuite/ | |
441 | ||
a64f5186 JJ |
442 | 2008-08-29 Jakub Jelinek <jakub@redhat.com> |
443 | ||
444 | PR fortran/29635 | |
445 | PR fortran/23057 | |
446 | * name-lookup.c (do_using_directive, cp_emit_debug_info_for_using): | |
447 | Adjust debug_hooks->imported_module_or_decl callers. | |
448 | ||
7299cb99 JH |
449 | 2008-08-29 Jan Hubicka <jh@suse.cz> |
450 | ||
451 | * cp-gimplify.c (cp_gimplify_expr): Add PRED_CONTINUE heuristic. | |
452 | ||
ffe79825 PC |
453 | 2008-08-28 Paolo Carlini <paolo.carlini@oracle.com> |
454 | ||
455 | PR c++/37260 | |
456 | * decl.c (reshape_init_r): Check init for error_mark_node. | |
457 | ||
d4033c81 MLI |
458 | 2008-08-27 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
459 | ||
460 | PR c++/17880 | |
461 | * semantics.c (maybe_convert_cond): Call verify_sequence_points. | |
462 | (finish_return_stmt): Likewise. | |
463 | (finish_switch_condition): Likewise. | |
464 | ||
b5fa2870 MLI |
465 | 2008-08-27 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
466 | ||
467 | * cp-tree.h: Fix #error directive. | |
468 | ||
adf2edec DG |
469 | 2008-08-26 Douglas Gregor <doug.gregor@gmail.com> |
470 | ||
471 | * typeck.c (type_after_usual_arithmetic_conversions): Don't do the | |
472 | usual arithmetic conversions on scoped enumeration types. | |
473 | (common_type): Ditto. | |
474 | (default_conversion): Don't perform integral promotions on scoped | |
475 | enumeration types. | |
476 | (build_array_ref): Scoped enumeration types can't be used as | |
477 | subscripts. | |
478 | * decl.c (start_enum): If building a C++0x scoped enumeration, | |
479 | enter its scope. If provided with an underlying type, check that | |
480 | underlying type and set up the enumeration type accordingly. | |
481 | (finish_enum): Only compute an underlying type if the underlying | |
482 | type isn't already fixed, and only convert the enumerator values | |
483 | now if we've just computed the underlying type. Finish the scope | |
484 | of C++0x scoped enumerations. | |
485 | (build_enumerator): For enumerations with a fixed underlying type, | |
486 | check the enumerator values when the enumerator is defined. | |
487 | (lookup_enumerator): New. | |
488 | * call.c (standard_conversion): Don't allow assignment from | |
489 | integers to scoped enumeration types, even with -fpermissive. | |
490 | Don't convert from scoped enumerations to bool or any arithmetic | |
491 | types. | |
492 | (build_conditional_expr): Don't per the usual arithmetic | |
493 | conversions for scoped enumeration types. | |
494 | (convert_like_real): Check complain to see if we should | |
495 | produce warnings. | |
496 | * error.c (class_key_or_enum_as_string): Print scoped enums. | |
497 | * cp-tree.h (MAYBE_CLASS_TYPE_P): Check CLASS_TYPE_P, not | |
498 | TYPE_LANG_FLAG_5. | |
499 | (INTEGRAL_OR_UNSCOPED_ENUMERATION_TYPE_P): New. | |
500 | (SCOPED_ENUM_P): New. | |
501 | (UNSCOPED_ENUM_P): New. | |
502 | (SET_SCOPED_ENUM_P): New. | |
503 | (ENUM_UNDERLYING_TYPE): New. | |
504 | * pt.c (lookup_template_class): Update the instantiation of enum | |
505 | types to deal with C++0x scoped enumerations and underlying | |
506 | types. | |
507 | * name-lookup.c (begin_scope): Deal with scoped enumeration | |
508 | scopes. | |
509 | (lookup_qualified_name): Deal with lookup into enumeration types. | |
510 | * name-lookup.h (enum scope_kind): Add sk_scoped_enum. | |
511 | * parser.c (cp_parser_class_or_namespace_name): Rename to... | |
512 | (cp_parser_qualifying_entity): ... this. Also, in C++0x mode, | |
513 | parse a type-name that can be an enumeration type. | |
514 | (cp_parser_nested_name_specifier_opt): Update with C++0x grammar. | |
515 | (cp_parser_elaborated_type_specifier): Parse the | |
516 | optional `struct' or `class' following enum (in C++0x). | |
517 | (cp_parser_enum_specifier): Parse C++0x scoped enumerations and | |
518 | enum-base clauses. | |
519 | ||
509c9d60 MLI |
520 | 2008-08-21 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
521 | ||
522 | * typeck.c: Update all calls to pedwarn. | |
523 | * decl.c: Likewise. | |
524 | * call.c: Likewise. | |
525 | * error.c: Likewise. | |
526 | * pt.c: Likewise. | |
527 | * name-lookup.c: Likewise. | |
528 | * parser.c: Likewise. | |
529 | ||
0e03ef47 MLI |
530 | 2008-08-20 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
531 | ||
532 | PR c++/35158 | |
533 | * parser.c (cp_parser_omp_for_loop): Handle parenthesized | |
534 | initializers. | |
535 | ||
1f5b3869 MLI |
536 | 2008-08-20 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
537 | ||
538 | * parser.c: Update all calls to inform. | |
539 | * typeck.c: Likewise. | |
540 | * init.c: Likewise. | |
541 | * class.c: Likewise. | |
542 | * call.c: Likewise. | |
543 | * method.c: Likewise. | |
544 | * friend.c: Likewise. | |
545 | * typeck2.c: Likewise. | |
546 | * pt.c: Likewise. | |
547 | * name-lookup.c: Likewise. | |
548 | * lex.c: Likewise. | |
549 | ||
e92cbe3a JJ |
550 | 2008-08-19 Jakub Jelinek <jakub@redhat.com> |
551 | ||
552 | PR debug/37156 | |
553 | * error.c (cp_print_error_function): Deal with recursive BLOCK trees. | |
554 | ||
1a87cf0c TB |
555 | 2008-08-18 Tomas Bily <tbily@suse.cz> |
556 | ||
557 | * tree.c (cp_tree_equal): Use CONVERT_EXPR_CODE_P. | |
558 | ||
cbe5f3b3 MLI |
559 | 2008-08-18 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
560 | ||
561 | * typeck.c: Update all callers of permerror. | |
562 | * init.c: Likewise. | |
563 | * class.c: Likewise. | |
564 | * decl.c: Likewise. | |
565 | * call.c: Likewise. | |
566 | * except.c: Likewise. | |
567 | * cvt.c: Likewise. | |
568 | * typeck2.c: Likewise. | |
569 | * pt.c: Likewise. | |
570 | * semantics.c: Likewise. | |
571 | * name-lookup.c: Likewise. | |
572 | * lex.c: Likewise. | |
573 | * decl2.c: Likewise. | |
574 | * parser.c: Likewise. | |
575 | ||
157b0647 PC |
576 | 2008-08-14 Paolo Carlini <paolo.carlini@oracle.com> |
577 | ||
578 | PR c++/34485 | |
579 | * pt.c (check_template_shadow): Change to return a bool. | |
580 | * name-lookup.c (push_class_level_binding): Early return if | |
581 | check_template_shadow returns false. | |
582 | * cp-tree.h (check_template_shadow): Adjust declaration. | |
583 | ||
0450a966 PC |
584 | 2008-08-14 Paolo Carlini <paolo.carlini@oracle.com> |
585 | ||
586 | PR c++/34600 | |
587 | * decl.c (grokdeclarator): In case of extern and initializer, return | |
588 | error_mark_node after the error. | |
589 | ||
4003301d MLI |
590 | 2008-08-13 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
591 | ||
592 | PR 30551 | |
593 | * decl.c (grokfndecl): Call check_main_parameters_type only if | |
594 | -Wmain. | |
595 | ||
905319d9 PC |
596 | 2008-08-12 Paolo Carlini <paolo.carlini@oracle.com> |
597 | ||
598 | PR c++/37087 | |
599 | * parser.c (cp_parser_class_head): Early return error_mark_node in | |
600 | case of global qualification of class name or qualified name that | |
601 | does not name a class. | |
602 | ||
b13e752f MLI |
603 | 2008-08-09 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
604 | ||
605 | PR c++/12242 | |
606 | * cvt.c (ocp_convert): Warn for out-of-range conversions to enum. | |
607 | ||
71205d17 MLI |
608 | 2008-08-09 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
609 | ||
610 | PR 36901 | |
611 | * cp-tree.h (struct diagnostic_context, struct diagnostic_info): | |
612 | Delete forward declarations. Check that toplev.h has not been | |
613 | included before this file. Include toplev.h and diagnostic.h. | |
614 | * error.c (cp_cpp_error): Use DK_PEDWARN. | |
615 | (cxx_incomplete_type_diagnostic): Update declaration. | |
616 | (cxx_incomplete_type_error): Use DK_ERROR. | |
617 | * typeck2.c (cxx_incomplete_type_diagnostic): Take a diagnostic_t | |
618 | as argument. Use emit_diagnostic. | |
619 | (cxx_incomplete_type_error): Use DK_ERROR. | |
620 | (add_exception_specifier): Use diagnostic_t instead of custom | |
621 | codes. | |
622 | * typeck.c (complete_type_or_else): Update call to | |
623 | cxx_incomplete_type_diagnostic. | |
624 | * init.c (build_delete): Likewise. | |
625 | * call.c (diagnostic_fn_t): Remove unused typedef. | |
626 | (build_temp): Pass a pointer to diagnostic_t. | |
627 | (convert_like_real): Use emit_diagnostic. | |
628 | (joust): Check return value of warning before giving informative | |
629 | note. | |
630 | * friend.c (do_friend): Check return value of warning | |
631 | before giving informative note. | |
632 | * parser.c (cp_parser_template_id): Likewise. | |
633 | ||
c73d5dd9 MLI |
634 | 2008-08-09 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
635 | ||
636 | PR 7651 | |
637 | * class.c (check_bases_and_members): Warn with -Wuninitialized | |
638 | instead of -Wextra. | |
639 | ||
76871f0f VR |
640 | 2008-08-08 Volker Reichelt <v.reichelt@netcologne.de> |
641 | ||
642 | PR c++/35985 | |
643 | * decl.c (xref_basetypes): Check base for MAYBE_CLASS_TYPE_P, | |
644 | and make sure it is not a union. | |
645 | ||
056dd1af L |
646 | 2008-08-07 H.J. Lu <hongjiu.lu@intel.com> |
647 | ||
648 | * semantics.c (finish_decltype_type): Initialize type. | |
649 | ||
ed85a1f6 | 650 | 2008-08-07 Douglas Gregor <doug.gregor@gmail.com> |
056dd1af | 651 | |
ed85a1f6 DG |
652 | * semantics.c (finish_decltype_type): Handle calls to function |
653 | pointers and references to functions properly. | |
056dd1af | 654 | |
865a3a42 DG |
655 | 2008-08-06 Douglas Gregor <doug.gregor@gmail.com> |
656 | ||
056dd1af L |
657 | PR c++/36460 |
658 | * parser.c (cp_parser_template_argument): Don't assume that '>>' | |
659 | following a type-id is an error when in C++0x mode. | |
660 | ||
7e99f74b MLI |
661 | 2008-08-06 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
662 | ||
663 | PR 26785 | |
664 | * decl.c (grokdeclarator): Use explicit location with permerror_at. | |
056dd1af | 665 | |
2d12797c MLI |
666 | 2008-08-06 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
667 | ||
668 | PR 8715 | |
669 | * typeck.c (cp_build_binary_op): Move code to c-common.c. | |
670 | ||
0f67bdf1 JM |
671 | 2008-08-05 Jason Merrill <jason@redhat.com> |
672 | ||
673 | PR c++/37016 | |
056dd1af | 674 | * decl.c (build_ptrmemfunc_type): Don't require structural |
0f67bdf1 JM |
675 | comparison of PMF types. |
676 | * tree.c (cp_build_qualified_type_real): Don't clear | |
677 | a valid TYPE_PTRMEMFUNC_TYPE. | |
056dd1af | 678 | * typeck.c (cp_build_unary_op): Still do build_ptrmemfunc in |
0f67bdf1 JM |
679 | templates. |
680 | ||
9b26c96e JM |
681 | 2008-08-04 Jason Merrill <jason@redhat.com> |
682 | ||
a53b09fa JM |
683 | PR c++/36963 |
684 | * typeck2.c (check_narrowing): Allow narrowing conversion | |
685 | from an explicit floating-point constant. | |
686 | ||
9b26c96e JM |
687 | PR c++/37006 |
688 | * pt.c (tsubst_decl): Leave DECL_INITIAL set on deleted | |
689 | instantiations. | |
690 | ||
771ce78e SB |
691 | 2008-08-04 Simon Baldwin <simonb@google.com> |
692 | ||
693 | PR c++/36999 | |
694 | * parser.c (cp_parser_elaborated_type_specifier): Warn only when | |
695 | the declaration's id is followed by a semicolon. | |
696 | ||
41b059f3 JJ |
697 | 2008-07-31 Jakub Jelinek <jakub@redhat.com> |
698 | ||
699 | PR c++/36405 | |
700 | * rtti.c (get_tinfo_decl_dynamic, get_typeid): Call | |
701 | complete_type_or_else even for UNKNOWN_TYPE to get diagnostics. | |
702 | ||
844ae01d JM |
703 | 2008-07-31 Jason Merrill <jason@redhat.com> |
704 | ||
10ee5386 JM |
705 | PR c++/36633 |
706 | * init.c (build_new_1): Don't convert pointer to the data type | |
707 | until we're actually going to treat it as that type. | |
708 | ||
844ae01d JM |
709 | PR c++/11309 |
710 | * tree.c (build_aggr_init_expr): Split out... | |
711 | (build_cplus_new): ...from here. | |
712 | (stabilize_init): Don't mess with AGGR_INIT_EXPR either. | |
056dd1af | 713 | * init.c (build_new_1): new T() means value-initialization, |
844ae01d JM |
714 | not default-initialization. |
715 | (build_vec_init): Likewise. | |
716 | (build_value_init_1): Use build_aggr_init_expr. | |
056dd1af | 717 | |
e44c800e DS |
718 | 2008-07-30 Dodji Seketeli <dseketel@redhat.com> |
719 | ||
720 | PR c++/36767 | |
721 | * decl2.c (fix_temporary_vars_context_r): New function. | |
722 | (one_static_initialization_or_destruction): Make sure temporary | |
723 | variables part of the initialiser have their DECL_CONTEXT() | |
724 | properly set. | |
725 | ||
6715192c MLI |
726 | 2008-07-30 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
727 | ||
728 | PR 34389 | |
729 | * typeck.c (build_binary_op): Encapsulate code into | |
730 | shorten_binary_op. | |
056dd1af | 731 | |
eb9c434c JJ |
732 | 2008-07-29 Jakub Jelinek <jakub@redhat.com> |
733 | ||
734 | PR c++/36852 | |
735 | * tree.c (cplus_array_hash, build_cplus_array_type_1): Hash on | |
736 | TYPE_UID instead of pointers. | |
737 | ||
99355518 JH |
738 | 2008-07-29 Jan Hubicka <jh@suse.cz> |
739 | ||
740 | * optimize.c (maybe_clone_body): Remove DECL_INLINE. | |
741 | * decl.c (duplicate_decls): Likewise. | |
742 | (grokfndecl): Likewise. | |
743 | (start_method): Likewise. | |
744 | * method.c (make_thunk, make_alias_for, implicitly_declare_fn): | |
745 | Likewise. | |
746 | * pt.c (register_specialization, regenerate_decl_from_template): | |
747 | Likewise. | |
748 | * decl2.c (grokfield): Likewise. | |
749 | ||
e27fb29c MLI |
750 | 2008-07-29 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
751 | ||
752 | PR 34985 | |
753 | * decl.c (duplicate_decls): Merge USED flags. | |
056dd1af | 754 | |
b71836b0 JM |
755 | 2008-07-27 Jason Merrill <jason@redhat.com> |
756 | ||
757 | PR c++/36943 | |
758 | * decl.c (reshape_init_r): Allow C++0x initializer lists. | |
759 | ||
726a989a RB |
760 | 2008-07-28 Richard Guenther <rguenther@suse.de> |
761 | ||
762 | Merge from gimple-tuples-branch. | |
763 | ||
764 | 2008-07-22 Aldy Hernandez <aldyh@redhat.com> | |
765 | ||
766 | * cp-gimplify.c (gimplify_if_stmt): Set location on newly created | |
767 | COND_EXPR. | |
768 | ||
769 | 2008-07-18 Jakub Jelinek <jakub@redhat.com> | |
770 | ||
771 | * decl.c (finish_function): Call gimple_body after cp_genericize. | |
772 | ||
773 | 2008-07-18 Aldy Hernandez <aldyh@redhat.com> | |
774 | ||
775 | * optimize.c: Include gimple.h instead of tree-gimple.h. | |
776 | * Make-lang.in (cp-gimplify.o): Depend on tree-iterator.h. | |
777 | * cp-gimplify.c: Rename tree-gimple.h to gimple.h. Include | |
778 | tree-iterator.h. | |
779 | ||
780 | 2008-07-16 Jakub Jelinek <jakub@redhat.com> | |
781 | ||
782 | * optimize.c (maybe_clone_body): Clear DECL_SAVED_TREE for the clone. | |
783 | ||
784 | 2008-07-14 Jakub Jelinek <jakub@redhat.com> | |
785 | ||
786 | * cp-gimplify.c (cp_gimplify_expr): Update comment. | |
787 | ||
788 | 2008-07-14 Aldy Hernandez <aldyh@redhat.com> | |
789 | ||
790 | * cp-tree.h (union lang_tree_node): Rename GENERIC_NEXT to | |
791 | TREE_CHAIN. | |
792 | * cp-gimplify.c (cxx_omp_clause_apply_fn): Rename | |
793 | GIMPLE_MODIFY_STMT to MODIFY_EXPR. | |
794 | (cxx_omp_clause_copy_ctor): Same. | |
795 | (cxx_omp_clause_assign_op): Same. | |
796 | ||
797 | 2008-05-28 Jakub Jelinek <jakub@redhat.com> | |
798 | ||
799 | * cp-gimplify.c (cp_gimplify_omp_for): Add pre_p argument. Tuplify. | |
800 | (cp_gimplify_expr): Adjust caller. | |
801 | ||
802 | 2008-05-11 Doug Kwan <dougkwan@google.com> | |
803 | ||
804 | * init.c (build_vec_delete): Add type conversion for argument | |
805 | 0 of POINTER_PLUS_EXPR. | |
806 | ||
807 | 2008-04-29 Doug Kwan <dougkwan@google.com> | |
808 | ||
056dd1af L |
809 | * decl2 (File): Include "gimple.h" |
810 | (cp_write_global_declarations): Use gimple_body instead of | |
811 | DECL_SAVED_TREE. | |
812 | * Make-lang.in (cp/decl2.o): Add $(GIMPLE_H) | |
726a989a RB |
813 | |
814 | 2008-04-10 Diego Novillo <dnovillo@google.com> | |
815 | ||
816 | http://gcc.gnu.org/ml/gcc-patches/2008-04/msg00913.html | |
817 | ||
818 | * optimize.c (maybe_clone_body): Re-enable call to | |
819 | clone_body. | |
820 | * cp-gimplify.c (cp_gimplify_omp_for): Mark disabled | |
821 | code with call to gimple_unreachable. | |
822 | (cp_genericize): Fix handling of clone bodies. | |
823 | ||
824 | 2008-04-04 Diego Novillo <dnovillo@google.com> | |
825 | ||
826 | http://gcc.gnu.org/ml/gcc-patches/2008-04/msg00413.html | |
827 | ||
828 | * optimize.c (maybe_clone_body): Re-enable. | |
829 | ||
830 | 2008-02-19 Diego Novillo <dnovillo@google.com> | |
831 | Oleg Ryjkov <olegr@google.com> | |
832 | ||
833 | http://gcc.gnu.org/ml/gcc-patches/2008-02/msg00804.html | |
834 | ||
835 | * cp-gimplify.c (gimplify_for_stmt): Change gimple_seq | |
836 | argument to gimple_seq *. Update all users. | |
837 | (gimplify_must_not_throw_expr): Likewise. | |
838 | ||
839 | 2008-02-04 Oleg Ryjkov <olegr@google.com> | |
840 | ||
841 | * except.c: Include gimple.h | |
842 | (cp_protect_cleanup_actions): Convert to tuples. | |
843 | * Make-lang.in (cp/except.o): Add dependency on gimple.h | |
844 | ||
845 | 2007-11-10 Aldy Hernandez <aldyh@redhat.com> | |
846 | ||
847 | * cp-gimplify.c (gimplify_cp_loop): Call tree_annotate_all_with_locus | |
848 | instead of annotating each block manually. | |
849 | ||
850 | 2007-10-30 Aldy Hernandez <aldyh@redhat.com> | |
851 | ||
852 | * cp-gimplify.c (gimplify_cp_loop): Tuplify. | |
853 | (gimplify_for_stmt): Same. | |
854 | (gimplify_switch_stmt): Same. | |
855 | (cp_gimplify_expr): [FOR_STMT]: Do not call gimplify_for_stmt. Return | |
856 | GS_OK. | |
857 | [WHILE_STMT]: Return GS_OK. | |
858 | [SWITCH_STMT]: Same. | |
859 | [CONTINUE_STMT]: Same. | |
860 | [BREAK_STMT]: Same. | |
861 | (cp_genericize): Set gimple_body() of cloned functions when needed. | |
862 | ||
863 | 2007-10-29 Aldy Hernandez <aldy@quesejoda.com> | |
864 | ||
865 | * cp-gimplify.c: Move build_gimple_eh_filter_tree here. | |
866 | (cp_gimplify_init_expr): Convert to tuples. | |
867 | (gimplify_must_not_throw_expr): Make function return a | |
868 | gimplify_status and convert to tuples. | |
869 | ||
870 | 2007-10-18 Aldy Hernandez <aldy@quesejoda.com> | |
871 | ||
872 | * cp-gimplify.c (genericize_try_block): Enable and do not call | |
873 | gimplify_stmt. | |
874 | (genericize_catch_block): Same. | |
875 | (genericize_eh_spec_block): Same. | |
876 | Rename gimple_build_eh_filter_tree to build_gimple_eh_filter_tree. | |
877 | (cp_gimplify_expr): Enable TRY_BLOCK, HANDLER, and EH_SPEC_BLOCK. | |
878 | ||
879 | 2007-10-16 Aldy Hernandez <aldy@quesejoda.com> | |
880 | ||
881 | * optimize.c (maybe_clone_body): Comment out call to clone_body. | |
882 | * decl.c (finish_function): Use gimple_body instead of | |
883 | DECL_SAVED_TREE. | |
884 | * cp-tree.h (cp_gimplify_expr): Last 2 arguments are sequences. | |
885 | * cp-gimplify.c (genericize_try_block): Comment out. | |
886 | (genericize_catch_block): Same. | |
887 | (genericize_eh_spec_block): Same. | |
888 | (gimplify_cp_loop): Comment out calls to gimplify_stmt. | |
889 | (gimplify_for_stmt): Comment out. | |
890 | (gimplify_switch_stmt): Comment out call to gimplify_stmt. | |
891 | (cp_gimplify_omp_for): Same. | |
892 | (gimplify_must_not_throw_expr): Argument pre_p is a sequence. | |
893 | Comment out call to gimplify_stmt and append_to_statement_list. | |
894 | Rename gimple_build_eh_filter_tree to build_gimple_eh_filter_tree. | |
895 | (cp_gimplify_init_expr): Arguments pre_p and post_p are sequences. | |
896 | (cp_gimplify_expr): Same. | |
897 | Comment out calls to genericize_*_block. Comment out call to | |
898 | gimplify_for_stmt. | |
899 | ||
ff60c668 L |
900 | 2008-07-27 H.J. Lu <hongjiu.lu@intel.com> |
901 | ||
902 | PR c++/36944 | |
903 | * class.c (type_has_user_provided_default_constructor): Handle | |
904 | default parameters. | |
905 | ||
448083e5 PC |
906 | 2008-07-27 Paolo Carlini <paolo.carlini@oracle.com> |
907 | ||
908 | * decl.c (push_library_fn): Add a parameter for the exceptions that | |
909 | the function may throw. | |
910 | (push_void_library_fn, push_throw_library_fn, expand_static_init): | |
911 | Adjust. | |
912 | (build_library_fn): Change to static. | |
913 | * cp-tree.h: Adjust declarations. | |
914 | * except.c (declare_nothrow_library_fn): New. | |
915 | (do_get_exception_ptr, do_begin_catch, do_free_exception, | |
916 | do_allocate_exception): Use the latter, adjust the declarations | |
917 | (ie, add empty exception-specification), consistently with the | |
918 | actual implementation in libsupc++. | |
919 | ||
4847609e JH |
920 | 2008-07-25 Jan Hubicka <jh@suse.cz> |
921 | ||
922 | * typeck.c (inline_conversion): Remove. | |
923 | (cp_build_function_call): Do not use inline_conversion. | |
924 | * decl.c (duplicate_decls): Do not insist on inline being declared | |
925 | early. | |
926 | (start_cleanup_fn): Do not assume that INLINE flags prevent function | |
927 | from being output. We now remove static functions always. | |
928 | (finish_function): Do return warning on all static functions. | |
929 | * call.c (build_over_call): Do not use inline_conversion. | |
930 | * cp-tree.h (possibly_inlined_p): Declare. | |
931 | (inline_conversion): Remove. | |
932 | * pt.c (instantiate_decl): Use possibly_inlined_p predicate. | |
933 | * decl2.c (cp_write_global_declarations): Likewise. | |
934 | (mark_used): Likewise. | |
935 | (possibly_inlined_p): New functions. | |
936 | ||
7ad8d488 JM |
937 | 2008-07-25 Jason Merrill <jason@redhat.com> |
938 | ||
939 | * class.c (type_has_user_provided_default_constructor): Handle | |
940 | templates. | |
941 | ||
7e8b322a JH |
942 | 2008-07-23 Jan Hubicka <jh@suse.cz> |
943 | ||
26f130aa | 944 | * decl.c (duplicate_decls): Update comment and unit-at-a-time. |
7e8b322a | 945 | (grogfndecl): Drop flag_inline_trees code. |
26f130aa JH |
946 | * pt.c (instantiate_decl): Drop flag_iline_trees code. |
947 | * lex.c (cxx_init): Do not set unit-at-a-time. | |
7e8b322a | 948 | |
b87d79e6 JM |
949 | 2008-07-23 Jason Merrill <jason@redhat.com> |
950 | ||
7ad8d488 JM |
951 | * mangle.c (write_unqualified_name): Avoid infinite recursion when |
952 | trying to mangle a decl with no name. | |
953 | ||
b87d79e6 JM |
954 | Implement defaulted/deleted functions as per N2346 |
955 | * cp-tree.h (struct lang_decl_flags): Add defaulted_p bitfield. | |
956 | (DECL_DELETED_FN): New macro. | |
957 | (DECL_DEFAULTED_FN): New macro. | |
958 | * class.c (user_provided_p): New fn. | |
959 | (defaultable_fn_p): New fn. | |
960 | (type_has_user_provided_constructor): New fn. | |
961 | (type_has_user_provided_default_constructor): New fn. | |
962 | (check_methods): A defaulted fn is still trivial. | |
963 | (check_bases_and_members): Likewise. | |
964 | * decl.c (grok_special_member_properties): Likewise. | |
965 | (duplicate_decls): Complain about redeclaring a function as deleted. | |
966 | (start_decl): initialized==2 means deleted. | |
967 | (cp_finish_decl): Handle deleted/defaulted semantics. | |
968 | * decl2.c (grokfield): Likewise. | |
969 | (mark_used): Check DECL_DEFAULTED_FN instead of DECL_ARTIFICIAL. | |
970 | Complain about using a deleted fn. | |
971 | * init.c (build_value_init_1): Use type_has_user_provided_constructor. | |
972 | (perform_member_init): Check for a user-provided default constructor | |
973 | even if TYPE_NEEDS_CONSTRUCTING. | |
974 | (build_new_1): Likewise. | |
975 | * call.c (build_over_call): Don't call mark_used twice. | |
976 | * method.c (implicitly_declare_fn): Set DECL_DEFAULTED_FN. | |
977 | * search.c (check_final_overrider): Check for deleted mismatch. | |
978 | * parser.c (cp_parser_init_declarator): Tell start_decl about =delete. | |
979 | (cp_parser_pure_specifier): Handle =default and =delete. | |
980 | ||
981 | * error.c (maybe_warn_cpp0x): Suggest -std=gnu++0x as well. | |
982 | ||
fcf73884 MLI |
983 | 2008-07-23 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
984 | ||
985 | PR 35058 | |
986 | * typeck.c: All calls to pedwarn changed. | |
987 | * decl.c: All calls to pedwarn changed. | |
988 | * call.c: All calls to pedwarn changed. | |
989 | * error.c: All calls to pedwarn changed. | |
990 | * typeck2.c: All calls to pedwarn changed. | |
991 | * pt.c: All calls to pedwarn changed. | |
992 | * name-lookup.c: All calls to pedwarn changed. | |
993 | * parser.c: All calls to pedwarn changed. | |
994 | ||
39a13be5 RW |
995 | 2008-07-21 Ralf Wildenhues <Ralf.Wildenhues@gmx.de> |
996 | ||
997 | * call.c: Fix comment typos. | |
998 | * class.c: Likewise. | |
999 | * cp-tree.h: Likewise. | |
1000 | * cxx-pretty-print.c: Likewise. | |
1001 | * decl.c: Likewise. | |
1002 | * init.c: Likewise. | |
1003 | * name-lookup.c: Likewise. | |
1004 | * operators.def: Likewise. | |
1005 | * parser.c: Likewise. | |
1006 | * pt.c: Likewise. | |
1007 | * tree.c: Likewise. | |
1008 | * typeck.c: Likewise. | |
1009 | ||
279086c3 PC |
1010 | 2008-07-21 Paolo Carlini <paolo.carlini@oracle.com> |
1011 | ||
1012 | PR c++/36871 | |
1013 | PR c++/36872 | |
1014 | * semantics.c (classtype_has_nothrow_assign_or_copy_p): Only check | |
1015 | copy constructors and copy assignment operators proper. | |
1016 | ||
719bb4e3 | 1017 | 2008-07-21 Rafael Ávila de Espíndola <espindola@google.com> |
aa14403d RAE |
1018 | |
1019 | * parser.c (cp_token): Remove in_system_header. | |
1020 | (eof_token): Remove in_system_header. | |
1021 | (cp_lexer_get_preprocessor_token): Don't set in_system_header. | |
1022 | (cp_lexer_set_source_position_from_token): Don't set in_system_header. | |
1023 | (cp_parser_member_declaration): Use in_system_header_at. | |
1024 | * pt.c (lookup_template_class): Don't set DECL_IN_SYSTEM_HEADER. | |
1025 | (pop_tinst_level): Don't set in_system_header. | |
1026 | (instantiate_class_template): Don't set in_system_header. | |
1027 | (instantiate_decl): Don't set in_system_header. | |
1028 | (instantiate_pending_templates): Don't set in_system_header. | |
1029 | ||
e24313f3 PC |
1030 | 2008-07-21 Paolo Carlini <paolo.carlini@oracle.com> |
1031 | ||
1032 | PR c++/36870 | |
1033 | * semantics.c (classtype_has_nothrow_assign_or_copy_p): Use | |
1034 | TYPE_NOTHROW_P, not TREE_NOTHROW. | |
1035 | (trait_expr_value): Likewise. | |
1036 | ||
6b3a665c DS |
1037 | 2008-07-18 Dodji Seketeli <dseketel@redhat.com> |
1038 | ||
1039 | PR c++/36407 | |
1040 | * call.c (convert_like_real): Don't take the error code path | |
1041 | when a rvalue or base conversion has the bad_p field set. | |
1042 | ||
c466b2cd KVH |
1043 | 2008-07-18 Kris Van Hees <kris.van.hees@oracle.com> |
1044 | ||
1045 | * rtti.c (emit_support_tinfos): Add char16_type_node and | |
1046 | char32_type_node. | |
1047 | * typeck2.c (digest_init): Support char16_t and char32_t. | |
1048 | ||
1049 | 2008-07-18 Kavih R. Ghazi <ghazi@caip.rutgers.edu> | |
be93747e KG |
1050 | |
1051 | * cvt.c (convert_to_void): Avoid C++ keywords. | |
1052 | * decl.c (walk_namespaces_r, wrapup_globals_for_namespace): | |
1053 | Likewise. | |
1054 | * friend.c (is_friend): Likewise. | |
1055 | * init.c (perform_member_init): Likewise. | |
1056 | * mangle.c (write_template_prefix, write_template_template_param): | |
1057 | Likewise. | |
1058 | * name-lookup.c (do_namespace_alias, do_using_directive, | |
1059 | parse_using_directive, ambiguous_decl, arg_assoc): Likewise. | |
1060 | * parser.c (cp_parser_template_id, cp_parser_namespace_definition, | |
1061 | cp_parser_objc_typename, cp_parser_objc_method_keyword_params): | |
1062 | Likewise. | |
1063 | * pt.c (is_specialization_of_friend, lookup_template_class, | |
1064 | push_tinst_level, instantiate_class_template, | |
1065 | tsubst_copy_and_build): Likewise. | |
1066 | * tree.c (add_stmt_to_compound): Likewise. | |
1067 | * typeck.c (finish_class_member_access_expr): Likewise. | |
1068 | ||
711b2998 JB |
1069 | 2008-07-17 Julian Brown <julian@codesourcery.com> |
1070 | Mark Mitchell <mark@codesourcery.com> | |
1071 | ||
1072 | * decl2.c (determine_visibility): Allow target to override | |
1073 | visibility of class data. | |
1074 | ||
afb86620 PC |
1075 | 2008-07-17 Paolo Carlini <paolo.carlini@oracle.com> |
1076 | ||
1077 | PR c++/36855 | |
1078 | * semantics.c (trait_expr_value): Update __has_trivial_destructor | |
1079 | semantics to the current WP (N2691). | |
1080 | ||
ecba6c56 DS |
1081 | 2008-07-16 Dodji Seketeli <dseketel@redhat.com> |
1082 | ||
1083 | PR c++/13699 | |
afb86620 | 1084 | * name-lookup.c (lookup_extern_c_fun_binding_in_all_ns): New function. |
ecba6c56 DS |
1085 | (pushdecl_maybe_friend): Check if a redeclaration of extern C function |
1086 | complies with exception specification constraints. | |
1087 | ||
7ce841d2 JM |
1088 | 2008-07-14 Jason Merrill <jason@redhat.com> |
1089 | ||
1090 | * lex.c (init_reswords): Always set D_OBJC. | |
1091 | ||
eea1139b ILT |
1092 | 2008-07-11 Tom Tromey <tromey@redhat.com> |
1093 | Ian Lance Taylor <iant@google.com> | |
1094 | ||
1095 | * lex.c (struct resword, reswords): Don't define. | |
1096 | (D_EXT, D_ASM, D_OBJC, D_CXX0X): Don't define. | |
1097 | (init_reswords): Clarify mask code. Use c_common_reswords rather | |
1098 | than reswords. | |
1099 | ||
94eeabbe DS |
1100 | 2008-07-11 Dodji Seketeli <dseketel@redhat.com> |
1101 | ||
1102 | PR c++/13101 | |
1103 | * decl.c (grokdeclarator): Warn about initializing variables | |
afb86620 PC |
1104 | of storage class 'extern' only after the type of the declarator |
1105 | has been properly computed. | |
94eeabbe | 1106 | |
760b18ad DS |
1107 | 2008-07-11 Dodji Seketeli <dseketel@redhat.com> |
1108 | ||
1109 | PR c++/31754 | |
c466b2cd | 1110 | * cp-tree.h (struct cp_decl_specifier_seq): Add a location field. It |
760b18ad | 1111 | carries the location of the primary type. |
c466b2cd | 1112 | * parser.c (cp_parser_check_type_definition): Update documentation. |
760b18ad DS |
1113 | (cp_parser_check_for_definition_in_return_type, |
1114 | cp_parser_check_for_invalid_template_id, | |
1115 | cp_parser_set_decl_spec_type, | |
1116 | cp_parser_check_for_definition_in_return_type, | |
1117 | cp_parser_diagnose_invalid_type_name, | |
1118 | cp_parser_new_expression, cp_parser_explicit_instantiation, | |
1119 | cp_parser_type_specifier, cp_parser_simple_type_specifier, | |
c466b2cd KVH |
1120 | cp_parser_omp_for_loop, cp_parser_pragma): Use location in error |
1121 | messages. | |
94eeabbe DS |
1122 | |
1123 | 2008-07-11 Dodji Seketeli <dseketel@redhat.com> | |
2b7a3abf DS |
1124 | |
1125 | PR c++/31754 | |
1126 | * pt.c, semantic.c: | |
1127 | * semantic.c (qualified_name_lookup_error, finish_id_expression): | |
c466b2cd | 1128 | Add a location_t parameter so that |
2b7a3abf | 1129 | error message can have a more accurate location. |
c466b2cd KVH |
1130 | * cp-tree.h: Updated prototype |
1131 | * pt.c (tsubst_qualified_id): Use location in error messages. | |
2b7a3abf DS |
1132 | * parser.c (cp_parser_postfix_expression, |
1133 | cp_parser_objc_statement, cp_parser_trait_expr, | |
1134 | cp_parser_token_is_class_key, | |
1135 | cp_parser_uncommitted_to_tentative_parse_p, | |
1136 | cp_parser_check_for_invalid_template_id, cp_parser_is_string_literal, | |
1137 | cp_parser_error, cp_parser_name_lookup_error, | |
1138 | cp_parser_simulate_error, cp_parser_check_decl_spec, | |
1139 | cp_parser_check_decl_spec, cp_parser_non_integral_constant_expression, | |
1140 | cp_parser_diagnose_invalid_type_name, | |
1141 | cp_parser_parse_and_diagnose_invalid_type_name, | |
1142 | cp_parser_require_pragma_eol, cp_parser_make_typename_type, | |
1143 | cp_parser_string_literal, cp_parser_primary_expression, | |
1144 | cp_parser_primary_expression, cp_parser_unqualified_id, | |
1145 | cp_parser_nested_name_specifier_opt, cp_parser_postfix_expression, | |
1146 | cp_parser_postfix_dot_deref_expression, cp_parser_new_expression, | |
1147 | cp_parser_direct_new_declarator, cp_parser_builtin_offsetof, | |
1148 | cp_parser_label_for_labeled_statement, cp_parser_statement_seq_opt, | |
1149 | cp_parser_jump_statement, cp_parser_block_declaration, | |
1150 | cp_parser_simple_declaration, cp_parser_decl_specifier_seq, | |
1151 | cp_parser_function_specifier_opt, cp_parser_decltype, | |
1152 | cp_parser_mem_initializer_list, cp_parser_mem_initializer, | |
1153 | cp_parser_mem_initializer_id, cp_parser_template_parameter, | |
c466b2cd KVH |
1154 | cp_parser_type_parameter, cp_parser_template_id, |
1155 | cp_parser_template_name, cp_parser_template_argument): Likewise. | |
2b7a3abf | 1156 | |
3d7c63cf PC |
1157 | 2008-07-09 Paolo Carlini <paolo.carlini@oracle.com> |
1158 | ||
1159 | PR c++/36760 | |
1160 | * pt.c (tsubst_function_type): Remove warning for type qualifiers | |
1161 | on function return type. | |
1162 | ||
af5216d3 PC |
1163 | 2008-07-09 Paolo Carlini <paolo.carlini@oracle.com> |
1164 | ||
1165 | PR c++/36760 | |
1166 | * pt.c (tsubst_function_type): Don't warn for type qualifiers | |
1167 | on function return type in case of system header. | |
1168 | ||
1ebc7e68 RA |
1169 | 2008-07-09 Raksit Ashok <raksit@google.com> |
1170 | ||
1171 | * parser.c (cp_parser_postfix_expression): New warning based on flag | |
1172 | warn_disallowed_functions. | |
1173 | ||
ff7437d0 SM |
1174 | 2008-07-08 Simon Martin <simartin@users.sourceforge.net> |
1175 | ||
1176 | PR c++/34963 | |
1177 | * decl.c (grokdeclarator): Reset storage_class and staticp for friend | |
1178 | functions declared with a storage class qualifier. | |
1179 | ||
1466cf1a RG |
1180 | 2008-07-03 Richard Guenther <rguenther@suse.de> |
1181 | ||
1182 | PR c++/36128 | |
1183 | * typeck.c (cp_build_function_call): Move code to verify | |
1184 | builtin function arguments ... | |
1185 | * call.c (build_cxx_call): ... here. | |
1186 | ||
09357846 JM |
1187 | 2008-07-02 Jason Merrill <jason@redhat.com> |
1188 | ||
6010fae7 JM |
1189 | * Make-lang.in (cp/typeck2.o): Add $(REAL_H) dependency. |
1190 | ||
09357846 JM |
1191 | Implement WG21 N2672, Initializer List proposed wording |
1192 | * cp-tree.h (enum cp_tree_index): Add CPTI_INIT_LIST_TYPE. | |
1193 | (struct lang_type_class): Add has_list_ctor bitfield. | |
1194 | (TYPE_HAS_LIST_CTOR): New macro. | |
1195 | (BRACE_ENCLOSED_INITIALIZER_P): Expect init_list_type_node. | |
1196 | (CONSTRUCTOR_IS_DIRECT_INIT): New macro. | |
1197 | (LOOKUP_NO_NARROWING): New macro. | |
1198 | (LOOKUP_NO_COPY_CTOR_CONVERSION): New macro. | |
1199 | * parser.c (cp_parse_braced_list): Split out from... | |
1200 | (cp_parser_initializer_clause): ...here. | |
056dd1af | 1201 | (cp_parser_postfix_expression): Build up CONSTRUCTOR for compound |
09357846 JM |
1202 | literal here. |
1203 | (cp_lexer_next_token_is_not_keyword): New fn. | |
1204 | (cp_parser_parenthesized_expression_list): Handle { }. | |
1205 | (cp_parser_new_expression, cp_parser_new_initializer): Likewise. | |
1206 | (cp_parser_assignment_expression, cp_parser_condition): Likewise. | |
1207 | (cp_parser_jump_statement, cp_parser_simple_declaration): Likewise. | |
1208 | (cp_parser_mem_initializer, cp_parser_init_declarator): Likewise. | |
1209 | (cp_parser_initializer, cp_parser_functional_cast): Likewise. | |
1210 | (cp_parser_omp_for_loop, cp_parser_cache_group): Likewise. | |
1211 | (cp_parser_save_member_function_body): Likewise. | |
1212 | * call.c (conversion_kind): Add ck_list, ck_aggr. | |
1213 | (struct conversion): Add check_narrowing bitfield, conversion list. | |
1214 | (build_list_conv): New fn. | |
1215 | (build_aggr_conv): New fn. | |
1216 | (implicit_conversion): Call them. | |
1217 | (standard_conversion): Set check_narrowing if appropriate. | |
1218 | (add_function_candidate): Handle LOOKUP_NO_COPY_CTOR_CONVERSION. | |
1219 | (build_user_type_conversion_1): When converting from an init list, | |
1220 | we allow additional conversions except when calling a copy ctor. | |
056dd1af | 1221 | (convert_like_real): Calling an explicit ctor for an init list is |
09357846 JM |
1222 | ill-formed. Handle ck_list and ck_addr. Check narrowing. |
1223 | (build_new_method_call): If CONSTRUCTOR_IS_DIRECT_INIT is set and | |
1224 | class doesn't have a list ctor, break the {} into a TREE_LIST. | |
1225 | (compare_ics): ck_list is better than other UDCs. | |
1226 | (set_up_extended_ref_temp): Split out from initialize_reference. | |
1227 | (is_std_init_list): New fn. | |
1228 | (is_list_ctor): New fn. | |
1229 | * decl.c (cxx_init_decl_processing): Create init_list_type_node. | |
1230 | (reshape_init_array_1): Pass it to build_constructor. | |
1231 | (reshape_init_class): Ditto. | |
1232 | (initialize_artificial_var): Pass the appropriate type. | |
1233 | (build_aggr_init_full_exprs): Split out from... | |
1234 | (check_initializer): ...here. Handle new semantics. | |
1235 | (build_init_list_var_init): New subroutine of check_initializer. | |
1236 | (grokdeclarator): Converting constructors can have more than one parm. | |
1237 | (grok_special_member_properties): Set TYPE_HAS_LIST_CTOR. | |
1238 | * init.c (expand_default_init): Only do digest_init for aggregates. | |
056dd1af | 1239 | * rtti.c (tinfo_base_init): Pass init_list_type_node to |
09357846 JM |
1240 | build_constructor_from_list. |
1241 | (generic_initializer, ptr_initializer): Ditto. | |
1242 | (ptm_initializer, class_initializer): Ditto. | |
1243 | (get_pseudo_ti_init): Ditto. | |
1244 | * error.c (dump_type): Handle init_list_type_node. | |
1245 | (maybe_warn_cpp0x): New fn. | |
1246 | (maybe_varn_variadic_templates): Call it. | |
1247 | * cvt.c (ocp_convert): Handle conversion from { }. | |
1248 | * tree.c (build_array_of_n_type): New fn. | |
1249 | * typeck2.c (store_init_value): Use init_list_type_node. | |
1250 | (digest_init): Likewise. | |
1251 | (check_narrowing): New fn. | |
056dd1af | 1252 | * semantics.c: (finish_compound_literal): Take CONSTRUCTOR instead |
09357846 JM |
1253 | of vector of constructor elts. Handle non-aggregate types. Make |
1254 | constant literals static. | |
1255 | * pt.c: (tsubst_copy_and_build): Adjust. | |
1256 | (unify): Handle { }. | |
1257 | * name-lookup.c (arg_assoc_type): Handle init_list_type_node. | |
94eeabbe | 1258 | |
f83c7f63 DJ |
1259 | 2008-07-01 Daniel Jacobowitz <dan@codesourcery.com> |
1260 | ||
1261 | * typeck.c (comp_ptr_ttypes_real): Use vector_targets_convertible_p. | |
1262 | (comp_ptr_ttypes_const): Likewise. | |
1263 | ||
298b7d2b AH |
1264 | 2008-07-01 Andrew Haley <aph@redhat.com> |
1265 | ||
1266 | * decl.c (finish_constructor_body): Don't set the return value of | |
1267 | the constructor if the constructor is that of a Java type. | |
1268 | ||
55b3fc29 JJ |
1269 | 2008-06-30 Jakub Jelinek <jakub@redhat.com> |
1270 | ||
1271 | PR c++/36662 | |
1272 | * decl2.c (is_late_template_attribute): If the first attribute | |
1273 | argument is IDENTIFIER_NODE, don't consider it when checking | |
1274 | if arguments are value or type dependent. | |
1275 | ||
1ffe7b6e PC |
1276 | 2008-06-29 Paolo Carlini <paolo.carlini@oracle.com> |
1277 | ||
1278 | PR c++/36655 | |
1279 | * pt.c (do_type_instantiation): In c++0x mode do not warn for | |
1280 | extern template. | |
1281 | ||
572e5ae3 KG |
1282 | 2008-06-29 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
1283 | ||
1284 | * Make-lang.in (cp-warn): Delete $(CXX_COMPAT_WARN). | |
1285 | ||
0ac69b47 JJ |
1286 | 2008-06-28 Jakub Jelinek <jakub@redhat.com> |
1287 | ||
1288 | PR c++/36364 | |
1289 | * repo.c (repo_emit_p): Put const static data members initialized | |
1290 | by const expr into *.rpo file, just return 2 if IDENTIFIER_REPO_CHOSEN | |
1291 | for it is 0. | |
1292 | ||
a7235bfb PC |
1293 | 2008-06-27 Paolo Carlini <paolo.carlini@oracle.com> |
1294 | ||
1295 | PR c++/36655 | |
1296 | * pt.c (do_decl_instantiation): In c++0x mode do not warn for | |
1297 | extern template. | |
1298 | ||
7b98a725 JW |
1299 | 2008-06-24 Jonathan Wakely <jwakely.gcc@gmail.com> |
1300 | ||
1301 | PR c++/23194 | |
1302 | * typeck.c (cp_build_function_call): Show example syntax in | |
1303 | diagnostic. | |
1304 | ||
37ec60ed JW |
1305 | 2008-06-21 Jonathan Wakely <jwakely.gcc@gmail.com> |
1306 | ||
1307 | * typeck.c (composite_pointer_type_r, cxx_sizeof_expr, | |
1308 | cxx_alignof_expr, check_template_keyword, cp_build_binary_op, | |
1309 | pointer_diff, cp_build_unary_op, build_x_compound_expr_from_list, | |
1310 | build_reinterpret_cast_1, cp_build_c_cast, check_return_expr): Change | |
1311 | pedwarn to permerror. | |
1312 | * init.c (perform_member_init, build_new_1, build_new): Likewise. | |
1313 | * decl.c (warn_extern_redeclared_static, duplicate_decls, | |
1314 | * identify_goto, check_previous_goto_1, check_goto, define_label, | |
1315 | check_tag_decl, start_decl, check_class_member_definition_namespace, | |
1316 | grokfndecl, grokdeclarator): Likewise. | |
1317 | * except.c (check_handlers): Likewise. | |
1318 | * typeck2.c (digest_init): Likewise. | |
1319 | * pt.c (check_specialization_namespace, | |
1320 | check_explicit_instantiation_namespace, | |
1321 | maybe_process_partial_specialization, check_explicit_specialization, | |
1322 | convert_template_argument, do_decl_instantiation, | |
1323 | do_type_instantiation, instantiate_decl): Likewise. | |
1324 | * semantics.c (finish_template_type_parm): Likewise. | |
1325 | * name-lookup.c (pushdecl_maybe_friend, | |
1326 | check_for_out_of_scope_variable): Likewise. | |
1327 | * decl2.c (finish_static_data_member_decl, build_anon_union_vars, | |
1328 | coerce_new_type): Likewise. | |
1329 | * parser.c (cp_parser_nested_name_specifier_opt, | |
1330 | cp_parser_mem_initializer, cp_parser_elaborated_type_specifier, | |
1331 | cp_parser_class_head, cp_parser_check_class_key): Likewise. | |
1332 | (cp_parser_parameter_declaration): Check flag_permissive instead of | |
1333 | flag_pedantic_errors. | |
1334 | * call.c (joust): Change pedwarn to warning. | |
1335 | * friend.c (make_friend_class): Likewise. | |
1336 | ||
ff2c88a5 JH |
1337 | 2008-06-16 Jan Hubicka <jh@suse.cz> |
1338 | ||
1339 | * method.c: Include cgraph.h. | |
1340 | (use_thunk): Use cgraph_add_new_function instead of calling backend | |
1341 | directly. | |
1342 | ||
1cbc62c0 RW |
1343 | 2008-06-15 Ralf Wildenhues <Ralf.Wildenhues@gmx.de> |
1344 | ||
1345 | * parser.c: Fix comment typo. | |
1346 | ||
a6d9bc9d SM |
1347 | 2008-06-14 Simon Martin <simartin@users.sourceforge.net> |
1348 | ||
1349 | PR c++/35320 | |
1350 | * decl2.c (grokbitfield): Receive the list of attributes, pass it to | |
1351 | grokdeclarator and apply it to the created declaration. | |
1352 | * cp-tree.h (grokbitfield): Update prototype. | |
1353 | * parser.c (cp_parser_member_declaration): Don't apply the attributes | |
1354 | since they are now applied in grokbitfield. Adjusted the call to | |
1355 | grokbitfield. | |
1356 | (cp_parser_objc_class_ivars): Likewise. | |
1357 | ||
4b8cb94c SM |
1358 | 2008-06-14 Simon Martin <simartin@users.sourceforge.net> |
1359 | ||
1360 | PR c++/35317 | |
1361 | * class.c (type_requires_array_cookie): Do not consider delete[] | |
1362 | operators with an ellipsis as second argument. | |
1363 | ||
9de0e916 JJ |
1364 | 2008-06-09 Jakub Jelinek <jakub@redhat.com> |
1365 | ||
1366 | PR c++/36408 | |
1367 | * semantics.c (stmt_expr_value_expr): Don't crash on empty | |
1368 | STATEMENT_LIST. | |
1369 | ||
c5285718 PC |
1370 | 2008-06-08 Paolo Carlini <paolo.carlini@oracle.com> |
1371 | ||
056dd1af L |
1372 | PR c++/35242 |
1373 | * pt.c (maybe_process_partial_specialization): Check the tree | |
c5285718 PC |
1374 | returned by push_template_decl for error_mark_node. |
1375 | * parser.c (cp_parser_class_head): Likewise, check the tree | |
056dd1af | 1376 | returned by the latter. |
c5285718 | 1377 | |
e3276457 PC |
1378 | 2008-06-07 Paolo Carlini <paolo.carlini@oracle.com> |
1379 | ||
056dd1af L |
1380 | PR c++/35327 |
1381 | * decl.c (grokdeclarator): In case of wrong return type return | |
e3276457 PC |
1382 | immediately error_mark_node. |
1383 | ||
a68ab351 JJ |
1384 | 2008-06-06 Jakub Jelinek <jakub@redhat.com> |
1385 | ||
1386 | * cp-tree.h (cxx_omp_finish_clause, cxx_omp_create_clause_info, | |
1387 | dependent_omp_for_p, begin_omp_task, finish_omp_task, | |
1388 | finish_omp_taskwait): New prototypes. | |
1389 | (cxx_omp_clause_default_ctor): Add outer argument. | |
1390 | (finish_omp_for): Add new clauses argument. | |
1391 | * cp-gimplify.c (cxx_omp_finish_clause): New function. | |
1392 | (cxx_omp_predetermined_sharing): Moved from semantics.c, rewritten. | |
1393 | (cxx_omp_clause_default_ctor): Add outer argument. | |
1394 | (cp_genericize_r): Walk OMP_CLAUSE_LASTPRIVATE_STMT. | |
1395 | * cp-objcp-common.h (LANG_HOOKS_OMP_FINISH_CLAUSE): Define. | |
1396 | * parser.c (cp_parser_omp_for_loop): Parse collapsed for loops. | |
1397 | Add par_clauses argument. If decl is present in parallel's | |
1398 | lastprivate clause, change that clause to shared and add | |
1399 | a lastprivate clause for decl to OMP_FOR_CLAUSES. | |
1400 | Fix wording of error messages. Adjust finish_omp_for caller. | |
1401 | Add clauses argument. Parse loops with random access iterators. | |
1402 | (cp_parser_omp_clause_collapse, cp_parser_omp_clause_untied): New | |
1403 | functions. | |
1404 | (cp_parser_omp_for, cp_parser_omp_parallel): Adjust | |
1405 | cp_parser_omp_for_loop callers. | |
1406 | (cp_parser_omp_for_cond, cp_parser_omp_for_incr): New helper | |
1407 | functions. | |
1408 | (cp_parser_omp_clause_name): Handle collapse and untied | |
1409 | clauses. | |
1410 | (cp_parser_omp_clause_schedule): Handle auto schedule. | |
1411 | (cp_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_COLLAPSE | |
1412 | and PRAGMA_OMP_CLAUSE_UNTIED. | |
1413 | (OMP_FOR_CLAUSE_MASK): Add PRAGMA_OMP_CLAUSE_COLLAPSE. | |
1414 | (OMP_TASK_CLAUSE_MASK): Define. | |
1415 | (cp_parser_omp_task, cp_parser_omp_taskwait): New functions. | |
1416 | (cp_parser_omp_construct): Handle PRAGMA_OMP_TASK. | |
1417 | (cp_parser_pragma): Handle PRAGMA_OMP_TASK and | |
1418 | PRAGMA_OMP_TASKWAIT. | |
1419 | * pt.c (tsubst_omp_clauses): Handle OMP_CLAUSE_COLLAPSE and | |
1420 | OMP_CLAUSE_UNTIED. Handle OMP_CLAUSE_LASTPRIVATE_STMT. | |
1421 | (tsubst_omp_for_iterator): New function. | |
1422 | (dependent_omp_for_p): New function. | |
1423 | (tsubst_expr) <case OMP_FOR>: Use it. Handle collapsed OMP_FOR | |
1424 | loops. Adjust finish_omp_for caller. Handle loops with random | |
1425 | access iterators. Adjust for OMP_FOR_{INIT,COND,INCR} changes. | |
1426 | (tsubst_expr): Handle OMP_TASK. | |
1427 | * semantics.c (cxx_omp_create_clause_info): New function. | |
1428 | (finish_omp_clauses): Call it. Handle OMP_CLAUSE_UNTIED and | |
1429 | OMP_CLAUSE_COLLAPSE. | |
1430 | (cxx_omp_predetermined_sharing): Removed. | |
1431 | * semantics.c (finish_omp_for): Allow pointer iterators. Use | |
1432 | handle_omp_for_class_iterator and dependent_omp_for_p. Handle | |
1433 | collapsed for loops. Adjust c_finish_omp_for caller. Add new | |
1434 | clauses argument. Fix check for type dependent cond or incr. | |
1435 | Set OMP_FOR_CLAUSES to clauses. Use cp_convert instead of | |
1436 | fold_convert to convert incr amount to difference_type. Only | |
1437 | fold if not in template. If decl is mentioned in lastprivate | |
1438 | clause, set OMP_CLAUSE_LASTPRIVATE_STMT. Handle loops with random | |
1439 | access iterators. Adjust for OMP_FOR_{INIT,COND,INCR} | |
1440 | changes. | |
1441 | (finish_omp_threadprivate): Allow static class members of the | |
1442 | current class. | |
1443 | (handle_omp_for_class_iterator, begin_omp_task, finish_omp_task, | |
1444 | finish_omp_taskwait): New functions. | |
1445 | ||
1446 | * parser.c (cp_parser_binary_expression): Add prec argument. | |
1447 | (cp_parser_assignment_expression): Adjust caller. | |
1448 | * cp-tree.h (outer_curly_brace_block): New prototype. | |
1449 | * decl.c (outer_curly_brace_block): No longer static. | |
1450 | ||
80d7287f PC |
1451 | 2008-06-02 Paolo Carlini <paolo.carlini@oracle.com> |
1452 | ||
056dd1af L |
1453 | PR c++/36404 |
1454 | * pt.c (push_template_decl_real): Consistently return error_mark_node | |
80d7287f PC |
1455 | on error. |
1456 | ||
5f9e56b3 TB |
1457 | 2008-06-02 Tomas Bily <tbily@suse.cz> |
1458 | ||
056dd1af L |
1459 | * typeck.c (is_bitfield_expr_with_lowered_type): Use CASE_CONVERT. |
1460 | (cp_build_unary_op): Likewise. | |
1461 | (cp_build_indirect_ref): Use CONVERT_EXPR_P. | |
1462 | (maybe_warn_about_returning_address_of_local): Likewise. | |
5f9e56b3 | 1463 | |
aecaad79 PC |
1464 | 2008-05-29 Paolo Carlini <paolo.carlini@oracle.com> |
1465 | ||
056dd1af L |
1466 | PR c++/35243 |
1467 | * pt.c (tsubst_initializer_list): Consistently check the tree | |
1468 | returned by tsubst_pack_expansion for error_mark_node. | |
aecaad79 | 1469 | |
a3299096 MM |
1470 | 2008-05-27 Michael Matz <matz@suse.de> |
1471 | ||
1472 | PR c++/27975 | |
1473 | * call.c (build_new_op): Make warning conditional on | |
1474 | OPT_Wenum_compare. | |
1475 | ||
bced8304 AO |
1476 | 2008-05-27 Alexandre Oliva <aoliva@redhat.com> |
1477 | ||
1478 | PR c++/35909 | |
1479 | * call.c (convert_like_real): Convert bitfield to desired type | |
1480 | before creating temporary. | |
1481 | ||
670637ee DF |
1482 | 2008-05-26 Daniel Franke <franke.daniel@gmail.com> |
1483 | ||
1484 | * Makefile.in: Adjusted dependencies on c-incpath.o. | |
1485 | ||
7a0112e7 JJ |
1486 | 2008-05-23 Jakub Jelinek <jakub@redhat.com> |
1487 | ||
c2898ec9 JJ |
1488 | PR c++/36237 |
1489 | * cp-gimplify.c (cxx_omp_clause_apply_fn): Call | |
1490 | fold_build_cleanup_point_expr on build_call_a results. | |
1491 | ||
7a0112e7 JJ |
1492 | PR c++/36308 |
1493 | * semantics.c (omp_clause_info_fndecl): New function. | |
1494 | (finish_omp_clauses): Use it. | |
1495 | ||
bac46fb6 JJ |
1496 | 2008-05-21 Jakub Jelinek <jakub@redhat.com> |
1497 | ||
1498 | PR c++/36023 | |
1499 | * cp-tree.h (check_array_initializer): New prototype. | |
1500 | * decl.c (check_array_initializer): New function. | |
1501 | (check_initializer): Call it. | |
1502 | * semantics.c (finish_compound_literal): Call it for ARRAY_TYPEs. | |
1503 | ||
dae4174e TT |
1504 | 2008-05-21 Tom Tromey <tromey@redhat.com> |
1505 | ||
1506 | * mangle.c (save_partially_mangled_name): Remove. | |
1507 | (restore_partially_mangled_name): Likewise. | |
1508 | (write_encoding): Update. | |
1509 | (write_unqualified_name): Likewise. | |
1510 | (start_mangling): Always use name_obstack. Remove 'ident_p' | |
1511 | argument. | |
1512 | (get_identifier_nocopy): Remove. | |
1513 | (finish_mangling_internal): Rename from finish_mangling. | |
1514 | (finish_mangling): New function. | |
1515 | (finish_mangling_get_identifier): Likewise. | |
1516 | (partially_mangled_name, partially_mangled_name_len): Remove. | |
1517 | (mangle_decl_string): Change return type. Update. | |
1518 | (mangle_decl, mangle_type_string, mangle_special_for_type, | |
1519 | mangle_ctor_vtbl_for_type, mangle_thunk, mangle_guard_variable, | |
1520 | mangle_ref_init_variable): Update. | |
1521 | ||
7d2f0ecd PC |
1522 | 2008-05-12 Paolo Carlini <paolo.carlini@oracle.com> |
1523 | ||
056dd1af L |
1524 | PR c++/35331 |
1525 | * semantics.c (begin_class_definition): Extend checks on the first | |
7d2f0ecd PC |
1526 | argument. |
1527 | ||
63a906f0 TB |
1528 | 2008-05-12 Tomas Bily <tbily@suse.cz> |
1529 | ||
056dd1af L |
1530 | * typeck2.c (digest_init): Use CONVERT_EXPR_P. |
1531 | * call.c (build_over_call): Likewise. | |
1532 | * error.c (dump_expr): Use CASE_CONVERT. | |
1533 | * class.c (fixed_type_or_null): Likewise. | |
63a906f0 | 1534 | |
8ffb4ce0 | 1535 | 2008-05-11 Volker Reichelt <v.reichelt@netcologne.de> |
becfd6e5 | 1536 | |
8ffb4ce0 VR |
1537 | * parser.c (cp_parser_omp_clause_reduction): Add missing "expected" |
1538 | in error message. | |
1539 | (cp_parser_omp_clause_schedule): Remove superfluous "expected" | |
1540 | in error message. | |
becfd6e5 | 1541 | |
8ffb4ce0 | 1542 | 2008-05-07 Kenneth Zadeck <zadeck@naturalbridge.com> |
becfd6e5 | 1543 | |
8ffb4ce0 VR |
1544 | * decl.c (duplicate_decls): Merge in DECL_PURE_P, TREE_READONLY, |
1545 | DECL_LOOPING_CONST_OR_PURE_P attributes. | |
1546 | * rtti.c (build_dynamic_cast_1): Rename DECL_IS_PURE to | |
1547 | DECL_PURE_P. | |
1548 | ||
1549 | 2008-05-02 Simon Baldwin <simonb@google.com> | |
e4d35515 SB |
1550 | |
1551 | PR bootstrap/36108 | |
1552 | * typeck.c (build_array_ref): Remove warn_array_subscript_range. | |
1553 | ||
8ffb4ce0 | 1554 | 2008-05-01 Simon Baldwin <simonb@google.com> |
ca873b0e SB |
1555 | |
1556 | * typeck.c (build_array_ref): Call warn_array_subscript_range. | |
1557 | ||
56b1a554 JJ |
1558 | 2008-04-30 Jakub Jelinek <jakub@redhat.com> |
1559 | ||
1560 | PR c++/35986 | |
1561 | * pt.c (more_specialized_fn): Stop the loop even if there are no | |
1562 | arguments before ellipsis. | |
1563 | ||
f2be060f JJ |
1564 | 2008-04-29 Jakub Jelinek <jakub@redhat.com> |
1565 | ||
58627576 JJ |
1566 | PR c++/35650 |
1567 | * parser.c (cp_parser_lookup_name): Look through single function | |
1568 | OVERLOAD. | |
1569 | ||
f2be060f JJ |
1570 | PR c++/35987 |
1571 | * typeck.c (cp_build_modify_expr) <case PREINCREMENT_EXPR>: Don't build | |
1572 | COMPOUND_EXPR if the second argument would be error_mark_node. | |
1573 | ||
bda37952 JM |
1574 | 2008-04-28 Jason Merrill <jason@redhat.com> |
1575 | Liu Guanwei <liu_gw@163.com> | |
1576 | ||
1577 | PR c++/57 | |
1578 | * parser.c (cp_parser_parameter_declaration): Handle < ambiguity | |
1579 | in default arguments. | |
1580 | ||
e3b5732b JH |
1581 | 2008-04-25 Jan Hubicka <jh@suse.cz> |
1582 | ||
1583 | * typeck.c (check_return_expr): Update. | |
1584 | * decl.c (start_preparsed_function): Update. | |
1585 | * method.c (use_thunk): Update. | |
1586 | ||
5dc11954 JJ |
1587 | 2008-04-24 Jakub Jelinek <jakub@redhat.com> |
1588 | ||
1589 | PR c++/35758 | |
1590 | * cp-tree.h (cp_reconstruct_complex_type): New prototype. | |
1591 | * cp-objcp-common.h (LANG_HOOKS_RECONSTRUCT_COMPLEX_TYPE): Define. | |
1592 | * decl2.c (is_late_template_attribute): Only make vector_size | |
1593 | late tmpl attribute if argument is type or value dependent. | |
1594 | (cp_reconstruct_complex_type): New function. | |
1595 | ||
83322951 RG |
1596 | 2008-04-24 Richard Guenther <rguenther@suse.de> |
1597 | ||
1598 | * typeck.c (cp_build_function_call): Call | |
1599 | check_builtin_function_arguments. | |
1600 | ||
51eed280 PB |
1601 | 2008-04-23 Paolo Bonzini <bonzini@gnu.org> |
1602 | ||
1603 | * typeck.c (get_member_function_from_ptrfunc): Don't set TREE_INVARIANT. | |
1604 | (build_ptrmemfunc1): Don't set TREE_INVARIANT. | |
1605 | * init.c (build_zero_init): Don't set TREE_INVARIANT. | |
1606 | * class.c (build_base_path): Don't set TREE_INVARIANT. | |
1607 | (build_vtbl_ref_1): Don't set TREE_INVARIANT. | |
1608 | (build_vtbl_initializer): Don't set TREE_INVARIANT. | |
1609 | * decl.c (build_enumerator): Don't set TREE_INVARIANT. | |
1610 | * rtti.c (tinfo_base_init): Don't set TREE_INVARIANT. | |
1611 | (generic_initializer): Don't set TREE_INVARIANT. | |
1612 | (ptr_initializer): Don't set TREE_INVARIANT. | |
1613 | (ptm_initializer): Don't set TREE_INVARIANT. | |
1614 | (class_initializer): Don't set TREE_INVARIANT. | |
1615 | * typeck2.c (process_init_constructor): Don't set TREE_INVARIANT. | |
1616 | * pt.c (push_inline_template_parms_recursive): Don't set TREE_INVARIANT. | |
1617 | (build_template_parm_index): Don't set TREE_INVARIANT. | |
1618 | (reduce_template_parm_level): Don't set TREE_INVARIANT. | |
1619 | (process_template_parm): Don't set TREE_INVARIANT. | |
1620 | ||
e76d7cc7 JM |
1621 | 2008-04-22 Jason Merrill <jason@redhat.com> |
1622 | ||
1623 | PR c++/35316 | |
1624 | * semantics.c (finish_decltype_type): Check DECL_BIT_FIELD_TYPE | |
1625 | to see if DECL_BIT_FIELD_TYPE should be used, not some other flag. | |
1626 | * typeck.c (is_bitfield_expr_with_lowered_type): Likewise. | |
1627 | ||
d7b5fa31 JJ |
1628 | 2008-04-22 Jakub Jelinek <jakub@redhat.com> |
1629 | ||
1630 | PR c++/35747 | |
1631 | * semantics.c (finish_stmt_expr): Call pop_stmt_list even if the stmt | |
1632 | expression is errorneous. | |
1633 | ||
ee34d21a JM |
1634 | 2008-04-21 Jason Merrill <jason@redhat.com> |
1635 | ||
d05739f8 JM |
1636 | PR c++/35325 |
1637 | * tree.c (cp_tree_equal): Handle FIXED_CST. | |
1638 | ||
ee34d21a | 1639 | PR c++/35678 |
056dd1af | 1640 | * pt.c (template_template_parm_bindings_ok_p): Set |
ee34d21a JM |
1641 | processing_template_decl while in this function. |
1642 | ||
b6baa67d KVH |
1643 | 2008-04-18 Kris Van Hees <kris.van.hees@oracle.com> |
1644 | ||
1645 | * cvt.c (type_promotes_to): Support char16_t and char32_t. | |
1646 | * decl.c (grokdeclarator): Disallow signed/unsigned/short/long on | |
1647 | char16_t and char32_t. | |
1648 | * lex.c (reswords): Add char16_t and char32_t (for c++0x). | |
1649 | * mangle.c (write_builtin_type): Mangle char16_t/char32_t as vendor | |
1650 | extended builtin type "u8char{16,32}_t". | |
1651 | * parser.c (cp_lexer_next_token_is_decl_specifier_keyword): Support | |
1652 | RID_CHAR{16,32}. | |
1653 | (cp_lexer_print_token): Support CPP_STRING{16,32}. | |
1654 | (cp_parser_is_string_literal): Idem. | |
1655 | (cp_parser_string_literal): Idem. | |
1656 | (cp_parser_primary_expression): Support CPP_CHAR{16,32} and | |
1657 | CPP_STRING{16,32}. | |
056dd1af | 1658 | (cp_parser_simple_type_specifier): Support RID_CHAR{16,32}. |
b6baa67d KVH |
1659 | * tree.c (char_type_p): Support char16_t and char32_t as char types. |
1660 | * typeck.c (string_conv_p): Support char16_t and char32_t. | |
1661 | ||
46225e26 JM |
1662 | 2008-04-17 Jason Merrill <jason@redhat.com> |
1663 | ||
1664 | PR c++/35773 | |
056dd1af | 1665 | * call.c (build_user_type_conversion_1): Represent second step of |
46225e26 JM |
1666 | copy-init with an rvalue conversion. |
1667 | (convert_like_real) [ck_user]: Don't implicitly add it here. | |
1668 | ||
b97d8153 JJ |
1669 | 2008-04-15 Jakub Jelinek <jakub@redhat.com> |
1670 | ||
1671 | PR c/35751 | |
1672 | * decl.c (layout_var_decl): If extern or static var has variable | |
1673 | size, set TREE_TYPE (decl) to error_mark_node. | |
1674 | ||
39e6670f DS |
1675 | 2008-04-16 Danny Smith <dannysmith@users.sourceforge.net> |
1676 | ||
056dd1af L |
1677 | PR target/35921 |
1678 | * optimize.c (maybe_clone_body): Copy DECL_DLLIMPORT_P flag | |
1679 | to clone. | |
39e6670f | 1680 | |
df794884 JM |
1681 | 2008-04-09 Jason Merrill <jason@redhat.com> |
1682 | ||
1683 | PR c++/35708 | |
056dd1af | 1684 | * semantics.c (finish_compound_literal): Return a TARGET_EXPR, |
df794884 JM |
1685 | not a pushed variable. |
1686 | ||
de21c145 VR |
1687 | 2008-04-09 Volker Reichelt <v.reichelt@netcologne.de> |
1688 | ||
bcac2b89 VR |
1689 | * call.c (build_op_delete_call): Fix quotation in warning message. |
1690 | * decl.c (grokdeclarator): Quote keyword in error message. | |
1691 | * pt.c (check_for_bare_parameter_packs): Fix quotation in error | |
1692 | message. | |
1693 | ||
8b4efb4e VR |
1694 | * parser.c (cp_parser_check_type_definition): Print error string |
1695 | directly rather than using "%s". | |
1696 | (cp_parser_postfix_expression): Fix quotation. | |
1697 | (cp_parser_decltype): Likewise. | |
1698 | (cp_parser_sizeof_operand): Fix quotation. Simplify. | |
1699 | ||
2a97bf74 VR |
1700 | * parser.c (cp_parser_non_integral_constant_expression): Build error |
1701 | message with CONCAT rather than using "%s". | |
1702 | (cp_parser_primary_expression): Fix quotation. | |
1703 | (cp_parser_postfix_expression): Likewise. | |
1704 | (cp_parser_postfix_dot_deref_expression): Likewise. | |
1705 | (cp_parser_unary_expression): Likewise. | |
1706 | (cp_parser_new_expression): Likewise. | |
1707 | (cp_parser_delete_expression): Likewise. | |
1708 | ||
3a483371 VR |
1709 | * parser.c (cp_parser_asm_specification_opt): Print CPP_CLOSE_PAREN |
1710 | as `)', not as `('. Fix quotation. | |
1711 | (cp_parser_consume_semicolon_at_end_of_statement): Fix quotation. | |
1712 | (cp_parser_primary_expression): Likewise. | |
1713 | (cp_parser_nested_name_specifier_opt): Likewise. | |
1714 | (cp_parser_postfix_expression): Likewise. | |
1715 | (cp_parser_postfix_open_square_expression): Likewise. | |
1716 | (cp_parser_parenthesized_expression_list): Likewise. | |
1717 | (cp_parser_pseudo_destructor_name): Likewise. | |
1718 | (cp_parser_new_expression): Likewise. | |
1719 | (cp_parser_direct_new_declarator): Likewise. | |
1720 | (cp_parser_delete_expression): Likewise. | |
1721 | (cp_parser_cast_expression): Likewise. | |
1722 | (cp_parser_question_colon_clause): Likewise. | |
1723 | (cp_parser_builtin_offsetof): Likewise. | |
1724 | (cp_parser_trait_expr): Likewise. | |
1725 | (cp_parser_label_for_labeled_statement): Likewise. | |
1726 | (cp_parser_compound_statement): Likewise. | |
1727 | (cp_parser_selection_statement): Likewise. | |
1728 | (cp_parser_condition): Likewise. | |
1729 | (cp_parser_iteration_statement): Likewise. | |
1730 | (cp_parser_already_scoped_statement): Likewise. | |
1731 | (cp_parser_simple_declaration): Likewise. | |
1732 | (cp_parser_linkage_specification): Likewise. | |
1733 | (cp_parser_static_assert): Likewise. | |
1734 | (cp_parser_decltype): Likewise. | |
1735 | (cp_parser_conversion_function_id): Likewise. | |
1736 | (cp_parser_operator_function_id): Likewise. | |
1737 | (cp_parser_operator): Likewise. | |
1738 | (cp_parser_type_parameter): Likewise. | |
1739 | (cp_parser_template_id): Likewise. | |
1740 | (cp_parser_explicit_instantiation): Likewise. | |
1741 | (cp_parser_explicit_specialization): Likewise. | |
1742 | (cp_parser_enum_specifier): Likewise. | |
1743 | (cp_parser_namespace_definition): Likewise. | |
1744 | (cp_parser_namespace_alias_definition): Likewise. | |
1745 | (cp_parser_using_declaration): Likewise. | |
1746 | (cp_parser_using_directive): Likewise. | |
1747 | (cp_parser_asm_definition): Likewise. | |
1748 | (cp_parser_direct_declarator): Likewise. | |
1749 | (cp_parser_ptr_operator): Likewise. | |
1750 | (cp_parser_parameter_declaration_clause): Likewise. | |
1751 | (cp_parser_initializer_clause): Likewise. | |
1752 | (cp_parser_class_specifier): Likewise. | |
1753 | (cp_parser_member_specification_opt): Likewise. | |
1754 | (cp_parser_member_declaration): Likewise. | |
1755 | (cp_parser_pure_specifier): Likewise. | |
1756 | (cp_parser_constant_initializer): Likewise. | |
1757 | (cp_parser_base_clause): Likewise. | |
1758 | (cp_parser_exception_specification_opt): Likewise. | |
1759 | (cp_parser_try_block): Likewise. | |
1760 | (cp_parser_function_try_block): Likewise. | |
1761 | (cp_parser_handler): Likewise. | |
1762 | (cp_parser_throw_expression): Likewise. | |
1763 | (cp_parser_asm_operand_list): Likewise. | |
1764 | (cp_parser_attributes_opt): Likewise. | |
1765 | (cp_parser_label_declaration): Likewise. | |
1766 | (cp_parser_constructor_declarator_p): Likewise. | |
1767 | (cp_parser_template_declaration_after_export): Likewise. | |
1768 | (cp_parser_single_declaration): Likewise. | |
1769 | (cp_parser_objc_message_expression): Likewise. | |
1770 | (cp_parser_objc_message_args): Likewise. | |
1771 | (cp_parser_objc_encode_expression): Likewise. | |
1772 | (cp_parser_objc_defs_expression): Likewise. | |
1773 | (cp_parser_objc_protocol_expression): Likewise. | |
1774 | (cp_parser_objc_selector_expression): Likewise. | |
1775 | (cp_parser_objc_protocol_refs_opt): Likewise. | |
1776 | (cp_parser_objc_typename): Likewise. | |
1777 | (cp_parser_objc_method_keyword_params): Likewise. | |
1778 | (cp_parser_objc_superclass_or_category): Likewise. | |
1779 | (cp_parser_objc_try_catch_finally_statement): Likewise. | |
1780 | (cp_parser_objc_synchronized_statement): Likewise. | |
1781 | (cp_parser_objc_throw_statement): Likewise. | |
1782 | (cp_parser_omp_var_list_no_open): Likewise. | |
1783 | (cp_parser_omp_clause_default): Likewise. | |
1784 | (cp_parser_omp_clause_if): Likewise. | |
1785 | (cp_parser_omp_clause_num_threads): Likewise. | |
1786 | (cp_parser_omp_clause_reduction): Likewise. | |
1787 | (cp_parser_omp_clause_schedule): Likewise. | |
1788 | (cp_parser_omp_critical): Likewise. | |
1789 | (cp_parser_omp_for_loop): Likewise. | |
1790 | (cp_parser_omp_sections_scope): Likewise. | |
1791 | ||
de21c145 VR |
1792 | * parser.c (cp_parser_template_parameter_list): Simplify. |
1793 | ||
e68c63e3 JW |
1794 | 2008-04-07 James E. Wilson <wilson@tuliptree.org> |
1795 | ||
1796 | * pt.c (tsubst_copy, case SIZEOF_EXPR): Initialize len. | |
1797 | ||
c2b58ba2 JM |
1798 | 2008-04-07 Jason Merrill <jason@redhat.com> |
1799 | ||
1800 | PR c++/35734 | |
056dd1af | 1801 | * class.c (type_has_user_nondefault_constructor): A template |
c2b58ba2 JM |
1802 | counts as a nondefault constructor. |
1803 | ||
e8924938 PB |
1804 | 2008-04-04 Paolo Bonzini <bonzini@gnu.org> |
1805 | ||
1806 | * decl.c (cxx_push_function_context): Delete. | |
1807 | (cxx_pop_function_context): Delete. | |
1808 | (start_preparsed_function): Merge cxx_push_function_context (!f->decl | |
1809 | code only). | |
1810 | * cp-objcp-common.h (LANG_HOOKS_FUNCTION_INIT, | |
1811 | LANG_HOOKS_FUNCTION_FINAL): Delete. | |
1812 | (LANG_HOOKS_FUNCTION_MISSING_NORETURN_OK_P): Rename to | |
1813 | LANG_HOOKS_MISSING_NORETURN_OK_P. | |
1814 | * cp-tree.h (cxx_push_function_context, cxx_pop_function_context): | |
1815 | Delete prototype. | |
1816 | * semantics.c (current_stmt_tree): Fix comment. | |
1817 | ||
60c4d135 JJ |
1818 | 2008-04-03 Jakub Jelinek <jakub@redhat.com> |
1819 | ||
1820 | PR c++/35741 | |
1821 | * semantics.c (finish_offsetof): Undo effect of convert_from_reference | |
1822 | before calling fold_offsetof. | |
1823 | ||
6cba282a TT |
1824 | 2008-04-03 Tom Tromey <tromey@redhat.com> |
1825 | ||
1826 | * Make-lang.in (c++_OBJS): New variable. | |
1827 | ||
9ff420f1 | 1828 | 2008-04-03 Paolo Bonzini <bonzini@gnu.org> |
056dd1af | 1829 | |
9ff420f1 PB |
1830 | * optimize.c (clone_body): New, from tree-inline.c. |
1831 | ||
d2784db4 PB |
1832 | 2008-04-03 Paolo Bonzini <bonzini@gnu.org> |
1833 | ||
056dd1af L |
1834 | * method.c (synthesize_method): Use {push,pop}_function_context. |
1835 | * name-lookup.c (push_to_top_level): Likewise. | |
1836 | * parser.c (cp_parser_late_parsing_for_member): Likewise. | |
d2784db4 | 1837 | |
adcc62c7 VR |
1838 | 2008-03-30 Volker Reichelt <v.reichelt@netcologne.de> |
1839 | ||
1840 | PR c++/35578 | |
1841 | * parser.c (cp_parser_decl_specifier_seq): Add location to error | |
1842 | message. | |
1843 | ||
e980df8e TT |
1844 | 2008-03-27 Tom Tromey <tromey@redhat.com> |
1845 | ||
1846 | * Make-lang.in: Revert automatic dependency patch. | |
1847 | ||
525521b6 DG |
1848 | 2008-03-27 Douglas Gregor <doug.gregor@gmail.com> |
1849 | ||
1850 | PR obj-c++/35704 | |
1851 | * typeck.c (build_x_compound_expr): Use cp_build_compound_expr. | |
1852 | (build_compound_expr): New, for compatibility with C | |
1853 | build_compound_expr. | |
1854 | (cp_build_compound_expr): Renamed from build_compound_expr. | |
1855 | (build_c_cast): New, for compatibility with C build_c_cast. | |
1856 | (cp_build_c_cast): Renamed from build_c_cast. | |
1857 | * init.c (build_vec_delete_1): Fix calls to build_compound_expr. | |
1858 | * decl.c (cxx_maybe_build_cleanup): Ditto. | |
1859 | * cp-tree.h (build_compound_expr): Add C-compatibile prototype. | |
1860 | (cp_build_compound_expr): Renamed from build_compound_expr. | |
1861 | (build_c_cast): Add C-compatible prototype. | |
1862 | (cp_build_c_cast): Renamed from build_c_cast. | |
1863 | * typeck2.c (build_functional_cast): Use cp_build_c_cast. | |
1864 | * parser.c (cp_parser_cast_expression): Fix call to build_c_cast. | |
1865 | ||
063cc99c DG |
1866 | 2008-03-27 Douglas Gregor <doug.gregor@gmail.com> |
1867 | ||
1868 | * pt.c (tsubst_copy) <case SIZEOF_EXPR>: Cope with | |
1869 | tsubst_pack_expansion returning a pack expansion, or a TREE_VEC | |
1870 | ending in a pack expansion, both of which can occur when | |
1871 | substituting into a nested template. | |
1872 | (tsubst_copy_and_build) <case SIZEOF_EXPR>: When we're | |
1873 | instantiating the sizeof...(X) form, make tsubst_copy do the work. | |
1874 | * parser.c (cp_parser_template_parameter): Deal with unnamed | |
1875 | non-type template parameter packs identified by pack expansions in | |
1876 | the parameter type. | |
1877 | ||
07874f1f JJ |
1878 | 2008-03-26 Jakub Jelinek <jakub@redhat.com> |
1879 | ||
ff2f1c5f JJ |
1880 | PR c++/35546 |
1881 | * pt.c (apply_late_template_attributes): Don't call tsubst on | |
1882 | first attribute argument if it is IDENTIFIER_NODE. | |
1883 | ||
07874f1f JJ |
1884 | PR c++/35332 |
1885 | * error.c (dump_expr): Pass {,UN}ORDERED_EXPR, UN{LT,LE,GT,GE,EQ}_EXPR | |
1886 | and LTGT_EXPR to pp_expression. | |
1887 | ||
a0a5f30f DG |
1888 | 2008-03-26 Douglas Gregor <doug.gregor@gmail.com> |
1889 | ||
056dd1af L |
1890 | * pt.c (coerce_template_template_parm): Moved the body of the loop |
1891 | of coerce_template_template_parms here, to make iteration over a | |
1892 | template argument pack simpler. | |
1893 | Also, allow matching of a template parameter pack in the template | |
1894 | template parameter to a template parameter in the template | |
1895 | template argument. | |
1896 | (coerce_template_template_parms): Deal with variadic template | |
1897 | template parameters. Use coerce_template_template_parm. | |
1898 | (unify): Make sure we coerce the template template argument's | |
1899 | template arguments to the template template parameter's template | |
1900 | parameters, not the other way around. | |
a0a5f30f | 1901 | |
2fe3178b TT |
1902 | 2008-03-25 Tom Tromey <tromey@redhat.com> |
1903 | ||
1904 | * Make-lang.in: Remove .o targets. | |
1905 | (cp/g++spec.o): Moved to cp/. Reduce to variable setting. | |
1906 | (GXX_OBJS): Update. | |
1907 | (c++_OBJS): New variable. | |
1908 | (CXX_TREE_H, CXX_PRETTY_PRINT_H): Remove. | |
1909 | ||
5ade1ed2 DG |
1910 | 2008-03-25 Douglas Gregor <doug.gregor@gmail.com> |
1911 | ||
056dd1af L |
1912 | * typeck.c (composite_pointer_type_r): Add SFINAE support. |
1913 | (composite_pointer_type): Ditto. | |
1914 | (common_type): Fix call to composite_pointer_type. | |
1915 | (cxx_sizeof_nowarn): New; used to be a macro. | |
1916 | (cxx_sizeof_expr): Add SFINAE support. | |
1917 | (cxx_alignof_expr): Ditto. | |
1918 | (decay_conversion): Fix calls for SFINAE support. | |
1919 | (rationalize_conditional_expr): Add SFINAE support. | |
1920 | (build_class_member_access_expr): Ditto. | |
1921 | (finish_class_member_access_expr): Ditto. | |
1922 | (build_x_indirect_ref): Ditto. | |
1923 | (build_indirect_ref): Original version renamed to | |
1924 | cp_build_indirect_ref; new version provides a bridge from | |
1925 | c-common. | |
1926 | (cp_build_indirect_ref): Was build_indirect_ref; added SFINAE | |
1927 | support. | |
1928 | (get_member_function_from_ptrfunc): Fix calls for SFINAE support. | |
1929 | (build_function_call): Original version renamed to | |
1930 | cp_build_function_call; new version provides a bridge from | |
1931 | c-common. | |
1932 | (cp_build_function_call): Was build_function_call; added SFINAE | |
1933 | support. | |
1934 | (convert_arguments): Add SFINAE support. | |
1935 | (build_x_binary_op): Ditto. | |
1936 | (build_binary_op): Original version renamed to cp_build_binary_op; | |
1937 | new version provides a bridge from c-common. | |
1938 | (cp_build_binary_op): Was build_binary_op; added SFINAE support. | |
1939 | (pointer_diff): Fix calls for SFINAE. | |
1940 | (build_x_unary_op): Add SFINAE support. | |
1941 | (condition_conversion): Fix calls for SFINAE. | |
1942 | (build_unary_op): Original version renamed to cp_build_unary_op; | |
1943 | new version provides a bridge from c-common. | |
1944 | (cp_build_unary_op): Was build_unary_op; added SFINAE support. | |
1945 | (unary_complex_lvalue): Fix calls for SFINAE. | |
1946 | (build_x_conditional_expr): Add SFINAE support. | |
1947 | (build_x_compound_expr_from_list): Fix calls for SFINAE. | |
1948 | (build_x_compound_expr): Add SFINAE support. | |
1949 | (convert_ptrmem): Fix calls for SFINAE. | |
1950 | (build_static_cast_1): Add SFINAE support. | |
1951 | (build_static_cast): Ditto. | |
1952 | (build_reinterpret_cast_1): Ditto. | |
1953 | (build_reinterpret_cast): Ditto. | |
1954 | (build_const_cast_1): Ditto. | |
1955 | (build_const_cast): Ditto. | |
1956 | (build_c_cast): Ditto. | |
1957 | (build_modify_expr): Original version renamed to | |
1958 | cp_build_modify_expr; new version provides a bridge from c-common. | |
1959 | (cp_build_modify_expr): Was build_modify_expr; added SFINAE | |
1960 | support. | |
1961 | (build_x_modify_expr): Add SFINAE support. | |
1962 | (build_ptrmemfunc): Fix calls for SFINAE. | |
1963 | (convert_for_assignment): Add SFINAE support. | |
1964 | (convert_for_initialization): Ditto. | |
1965 | (check_return_expr): Fix calls for SFINAE. | |
1966 | (lvalue_or_else): Add SFINAE support. | |
1967 | * init.c (perform_member_init): Fix calls for SFINAE. | |
1968 | (emit_mem_initializers): Ditto. | |
1969 | (expand_virtual_init): Ditto. | |
1970 | (expand_cleanup_for_base): Ditto. | |
1971 | (build_aggr_init): Add SFINAE support. | |
1972 | (expand_default_init): Ditto. | |
1973 | (expand_aggr_init_1): Fix calls for SFINAE. | |
1974 | (build_offset_ref): Ditto. | |
1975 | (build_new_1): Add SFINAE support. | |
1976 | (build_new): Ditto. | |
1977 | (build_vec_delete_1): Fix calls for SFINAE. | |
1978 | (get_temp_regvar): Ditto. | |
1979 | (build_vec_init): Add SFINAE support. | |
1980 | (build_dtor_call): Fix calls for SFINAE. | |
1981 | (build_delete): Ditto. | |
1982 | (push_base_cleanups): Ditto. | |
1983 | (build_vec_delete_1): Ditto. | |
1984 | * class.c (build_base_path): Fix calls for SFINAE. | |
1985 | (build_simple_base_path): Ditto. | |
1986 | (convert_to_base_statically): Ditto. | |
1987 | (build_vfn_ref): Ditto. | |
1988 | (resolve_address_of_overloaded_function): Ditto. | |
1989 | * decl.c (check_initializer): Fix calls for SFINAE. | |
1990 | (register_dtor_fn): Ditto. | |
1991 | (compute_array_index_type): Ditto. | |
1992 | (finish_enum): Ditto. | |
1993 | (start_preparsed_function): Ditto. | |
1994 | (cxx_maybe_build_cleanup): Ditto. | |
1995 | * call.c (convert_like): Add COMPLAIN argument. | |
1996 | (convert_like_with_context): Ditto. | |
1997 | (build_this): Fix calls for SFINAE. | |
1998 | (build_user_type_conversion): Ditto. | |
1999 | (resolve_args): Ditto. | |
2000 | (build_new_function_call): Add SFINAE support. | |
2001 | (build_operator_new_call): Fix calls for SFINAE. | |
2002 | (build_object_call): Add SFINAE support. | |
2003 | (build_conditional_expr): Ditto. | |
2004 | (build_new_op): Ditto. | |
2005 | (build_op_delete_call): Fix calls for SFINAE. | |
2006 | (build_temp): Ditto. | |
2007 | (convert_like_real): Add SFINAE support. | |
2008 | (build_x_va_arg): Fix calls for SFINAE. | |
2009 | (convert_default_arg): Ditto. | |
2010 | (build_over_call): Add SFINAE support. | |
2011 | (build_java_interface_fn_ref): Fix calls for SFINAE. | |
2012 | (build_special_member_call): Add SFINAE support. | |
2013 | (build_new_method_call): Ditto. | |
2014 | (perform_implicit_conversion): Ditto. | |
2015 | (perform_direct_initialization_if_possible): Ditto. | |
2016 | (initialize_reference): Fix calls for SFINAE. | |
2017 | * method.c (do_build_assign_ref): Fix calls for SFINAE. | |
2018 | * rtti.c (build_headof): Fix calls for SFINAE. | |
2019 | (get_tinfo_decl_dynamic): Ditto. | |
2020 | (get_typeid): Ditto. | |
2021 | (build_dynamic_cast_1): Add SFINAE support. | |
2022 | (build_dynamic_cast): Ditto. | |
2023 | (tinfo_base_init): Fix calls for SFINAE. | |
2024 | * except.c (do_get_exception_ptr): Fix calls for SFINAE. | |
2025 | (do_end_catch): Ditto. | |
2026 | (initialize_handler_parm): Ditto. | |
2027 | (expand_start_catch_block): Ditto. | |
2028 | (do_allocate_exception): Ditto. | |
2029 | (do_free_exception): Ditto. | |
2030 | (build_throw): Ditto. | |
2031 | * cvt.c (build_up_reference): Fix calls for SFINAE. | |
2032 | (convert_to_reference): Ditto. | |
2033 | (ocp_convert): Ditto. | |
2034 | (convert_to_void): Add SFINAE support. | |
2035 | * tree.c (build_dummy_object): Fix calls for SFINAE. | |
2036 | (stabilize_expr): Ditto. | |
2037 | * cp-tree.h (build_conditional_expr): Add tsubst_flags_t | |
2038 | parameter. | |
2039 | (build_new_method_call): Ditto. | |
2040 | (build_special_member_call): Ditto. | |
2041 | (build_new_op): Ditto. | |
2042 | (perform_implicit_conversion): Ditto. | |
2043 | (perform_direct_initialization_if_possible): Ditto. | |
2044 | (convert_to_void): Ditto. | |
2045 | (build_aggr_init): Ditto. | |
2046 | (build_new): Ditto. | |
2047 | (build_vec_init): Ditto. | |
2048 | (build_dynamic_cast): Ditto. | |
2049 | (finish_call_expr): Ditto | |
2050 | (cxx_sizeof_or_alignof_expr): Add COMPLAIN parameter. | |
2051 | (cxx_sizeof_nowarn): Remove macro; add function declaration. | |
2052 | (build_class_member_access_expr): Add tsubst_flags_t parameter. | |
2053 | (finish_class_member_access_expr): Ditto. | |
2054 | (build_x_indirect_ref): Ditto. | |
2055 | (cp_build_indirect_ref): New. | |
2056 | (cp_build_function_call): Add tsubst_flags_t parameter. | |
2057 | (build_x_unary_op): Ditto. | |
2058 | (cp_build_unary_op): New. | |
2059 | (build_x_conditional_expr): Add tsubst_flags_t parameter. | |
2060 | (build_x_compound_expr): Ditto. | |
2061 | (build_compound_expr): Ditto. | |
2062 | (build_static_cast): Ditto. | |
2063 | (build_reinterpret_cast): Ditto. | |
2064 | (build_const_cast): Ditto. | |
2065 | (build_c_cast): Ditto. | |
2066 | (build_x_modify_expr): Ditto. | |
2067 | (cp_build_modify_expr): New. | |
2068 | (convert_for_initialization): Add tsubst_flags_t parameter. | |
2069 | (cp_build_binary_op): Remove macro; add function declaration. | |
2070 | (invalid_nonstatic_memfn_p): Add tsubst_flags_t parameter. | |
2071 | (lvalue_or_else): Ditto. | |
2072 | (build_functional_cast): Ditto. | |
2073 | * typeck2.c (digest_init): Fix calls for SFINAE. | |
2074 | (process_init_constructor_array): Ditto. | |
2075 | (process_init_constructor_record): Ditto. | |
2076 | (build_x_arrow): Ditto. | |
2077 | (build_m_component_ref): Ditto. | |
2078 | (build_functional_cast): Add SFINAE support. | |
2079 | * pt.c (tsubst_copy_and_build): Add (more) SFINAE support. | |
2080 | * semantics.c (simplify_loop_decl_cond): Fix calls for SFINAE. | |
2081 | (finish_expr_stmt): Ditto. | |
2082 | (finish_for_expr): Ditto. | |
2083 | (finish_asm_stmt): Ditto. | |
2084 | (finish_non_static_data_member): Ditto. | |
2085 | (finish_qualified_id_expr): Ditto. | |
2086 | (finish_call_expr): Add SFINAE support. | |
2087 | (finish_increment_expr): Fix calls for SFINAE. | |
2088 | (finish_unary_op_expr): Ditto. | |
2089 | (simplify_aggr_init_expr): Ditto. | |
2090 | (finish_omp_clauses): Ditto. | |
2091 | (finish_omp_for): Ditto. | |
2092 | (finish_omp_barrier): Ditto. | |
2093 | (finish_omo_flush): Ditto. | |
2094 | * decl2.c (grok_array_decl): Fix calls or SFINAE. | |
2095 | (build_anon_union_vars): Ditto. | |
2096 | (get_guard_cond): Ditto. | |
2097 | (set_guard): Ditto. | |
2098 | (one_static_initialization_or_destruction): Ditto. | |
2099 | (do_static_initialization_or_destruction): Ditto. | |
2100 | (generate_ctor_or_dtor_function): Ditto. | |
2101 | (build_offset_ref_call_from_tree): Ditto. | |
2102 | * parser.c (cp_parser_postfix_expression): Fix calls for SFINAE. | |
2103 | (cp_parser_postfix_dot_deref_expression): Ditto. | |
2104 | (cp_parser_unary_expression): Ditto. | |
2105 | (cp_parser_new_expression): Ditto. | |
2106 | (cp_parser_cast_expression): Ditto. | |
2107 | (cp_parser_binary_expression): Ditto. | |
2108 | (cp_parser_question_colon_clause): Ditto. | |
2109 | (cp_parser_assignment_expression): Ditto. | |
2110 | (cp_parser_expression): Ditto. | |
2111 | (cp_parser_builtin_offsetof): Ditto. | |
2112 | (cp_parser_template_argument): Ditto. | |
2113 | (cp_parser_functional_cast): Ditto. | |
5ade1ed2 | 2114 | |
50c91950 TT |
2115 | 2008-03-24 Tom Tromey <tromey@redhat.com> |
2116 | ||
2117 | * lex.c (handle_pragma_interface): Don't copy the filename. | |
2118 | (handle_pragma_implementation): Copy filename using xstrdup. | |
2119 | ||
9e1e64ec PC |
2120 | 2008-03-21 Paolo Carlini <pcarlini@suse.de> |
2121 | ||
2122 | * cp-tree.h (IS_AGGR_TYPE): Rename to MAYBE_CLASS_TYPE_P. | |
2123 | (SET_IS_AGGR_TYPE): Rename to SET_CLASS_TYPE_P. | |
2124 | (IS_AGGR_TYPE_CODE): Rename to RECORD_OR_UNION_CODE_P. | |
2125 | (PROMOTES_TO_AGGR_TYPE): Remove. | |
2126 | (CLASS_TYPE_P, TYPE_NON_AGGREGATE_CLASS): Adjust. | |
2127 | * typeck.c (unary_complex_lvalue, build_modify_expr, | |
2128 | convert_for_initialization): Adjust. | |
2129 | * init.c (is_aggr_type): Remove. | |
2130 | (is_class_type): Add. | |
2131 | (build_offset_ref, build_new_1, build_vec_delete_1, build_vec_init, | |
2132 | build_delete): Adjust. | |
2133 | * lex.c (make_aggr_type): Remove. | |
2134 | (make_class_type): Add. | |
2135 | (cxx_make_type): Adjust. | |
2136 | * class.c (finish_struct_1, fixed_type_or_null, is_empty_class): | |
2137 | Adjust. | |
2138 | * decl.c (build_typename_type, make_typename_type, | |
2139 | make_unbound_class_template, cxx_init_decl_processing, | |
2140 | check_tag_decl, groktypename, start_decl_1, layout_var_decl, | |
2141 | check_initializer, cp_finish_decl, build_ptrmemfunc_type, grokparms, | |
2142 | grok_op_properties, xref_tag, check_function_type): Adjust. | |
2143 | * call.c (check_dtor_name, standard_conversion, implicit_conversion, | |
2144 | add_builtin_candidate, add_builtin_candidates, | |
2145 | build_user_type_conversion_1, convert_like_real, build_cxx_call, | |
2146 | is_subseq, compare_ics): Adjust. | |
2147 | * method.c (use_thunk): Adjust. | |
2148 | * rtti.c (build_dynamic_cast_1, create_pseudo_type_info, | |
2149 | create_tinfo_types): Adjust. | |
2150 | * cvt.c (cp_convert_to_pointer, convert_to_pointer_force, | |
2151 | build_up_reference, convert_to_reference, convert_from_reference, | |
2152 | ocp_convert, build_expr_type_conversion): Adjust. | |
2153 | * tree.c (bind_template_template_parm, error_type): Adjust. | |
2154 | * dump.c (cp_dump_tree): Adjust. | |
2155 | * search.c (lookup_member): Adjust. | |
2156 | * friend.c (make_friend_class, do_friend): Adjust. | |
2157 | * typeck2.c (store_init_value, process_init_constructor_array, | |
2158 | process_init_constructor_record, build_x_arrow, build_m_component_ref, | |
2159 | build_functional_cast): Adjust. | |
2160 | * pt.c (finish_member_template_decl, process_template_parm, | |
2161 | lookup_template_class, tsubst_function_type, tsubst, | |
2162 | tsubst_copy_and_build, get_template_base, bt_instantiate_type_proc): | |
2163 | Adjust. | |
2164 | * semantics.c (begin_class_definition, finish_base_specifier, | |
2165 | finish_typeof, cxx_omp_predetermined_sharing, finish_decltype_type): | |
2166 | Adjust. | |
2167 | * name-lookup.c (constructor_name_p, push_overloaded_decl, | |
2168 | do_class_using_decl, lookup_qualified_name, | |
2169 | maybe_process_template_type_declaration): Adjust. | |
2170 | * decl2.c (grok_array_decl, check_member_template, | |
2171 | constrain_class_visibility): Adjust. | |
2172 | * parser.c (cp_parser_class_name): Adjust. | |
2173 | ||
ac5dc795 PB |
2174 | 2008-03-18 Paolo Bonzini <bonzini@gnu.org> |
2175 | ||
056dd1af L |
2176 | * cp-lang.c (LANG_HOOKS_REDUCE_BIT_FIELD_OPERATIONS): Delete. |
2177 | ||
3d574e5b JM |
2178 | 2008-03-17 Jason Merrill <jason@redhat.com> |
2179 | ||
2180 | PR c++/35548 | |
2181 | * call.c (reference_binding): Check LOOKUP_NO_TEMP_BIND when binding | |
2182 | a temp directly to a reference as per DR391. | |
2183 | ||
70fef63a RG |
2184 | 2008-03-12 Richard Guenther <rguenther@suse.de> |
2185 | ||
2186 | PR c++/35469 | |
2187 | Revert: | |
2188 | 2008-02-04 Richard Guenther <rguenther@suse.de> | |
2189 | ||
056dd1af L |
2190 | PR java/35035 |
2191 | * decl.c (record_builtin_java_type): Make jboolean a | |
2192 | integer type again where its mode doesn't match that of bool. | |
70fef63a RG |
2193 | |
2194 | 2008-01-25 Richard Guenther <rguenther@suse.de> | |
2195 | ||
056dd1af L |
2196 | PR c++/33887 |
2197 | * decl.c (record_builtin_java_type): Make __java_boolean | |
2198 | a variant of bool. | |
2199 | * typeck.c (structural_comptypes): Move TYPE_FOR_JAVA check | |
2200 | after TYPE_MAIN_VARIANT check. | |
70fef63a | 2201 | |
85b20612 JJ |
2202 | 2008-03-10 Jakub Jelinek <jakub@redhat.com> |
2203 | ||
fde155a7 JJ |
2204 | PR c++/35328 |
2205 | * semantics.c (finish_omp_clauses): Look through NOP_EXPR even | |
2206 | if errorcount. | |
2207 | ||
85b20612 JJ |
2208 | PR c++/35337 |
2209 | * semantics.c (finish_omp_clauses): Use %qD instead of %qE for | |
2210 | DECL_P in not a variable and appears more than once error messages. | |
2211 | ||
96d84882 PB |
2212 | 2008-03-07 Paolo Bonzini <bonzini@gnu.org> |
2213 | ||
2214 | Revert: | |
2215 | ||
2216 | 2008-02-06 Douglas Gregor <doug.gregor@gmail.com> | |
2217 | ||
2218 | PR c++/35049 | |
2219 | PR c++/35096 | |
2220 | * typeck.c (structural_comptypes): Call cp_comptypes. | |
2221 | (comptypes): New; called from the C/C++ common bits to perform | |
2222 | strict checks. | |
2223 | (cp_comptypes): Renamed from comptypes, which is already used, | |
2224 | with a different signature, by the C++ front end. | |
2225 | (build_reinterpret_cast_1): Call cp_comptypes. | |
2226 | (ptr_reasonably_similar): Ditto. | |
2227 | * decl.c (decls_match): Ditto. | |
2228 | * cvt.c (convert_to_reference): Ditto. | |
2229 | * cp-tree.h (same_type_p): Ditto. | |
2230 | (same_or_base_type_p): Ditto. | |
2231 | (comptypes): Rename to cp_comptypes. | |
2232 | * pt.c (canonical_type_parameter): Call cp_comptypes. | |
2233 | ||
cf7bc668 PB |
2234 | 2008-03-07 Paolo Bonzini <bonzini@gnu.org> |
2235 | ||
2236 | * cp-objcp-common.c (cxx_types_compatible_p): Remove obsolete | |
2237 | test for equivalence between pointer and references. | |
2238 | ||
393eda6a MLI |
2239 | 2008-03-02 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2240 | ||
2241 | PR 24924 | |
2242 | * class.c (finish_struct_anon): Use permerror instead of pedwarn. | |
2243 | (check_field_decls): Likewise. | |
2244 | (note_name_declared_in_class): Likewise. | |
2245 | * call.c (build_new_op): Likewise. | |
2246 | (convert_like_real): Likewise. | |
2247 | (build_over_call): Likewise. | |
2248 | * lex.c (unqualified_fn_lookup_error): Likewise. | |
2249 | * parser.c (cp_parser_template_id): Likewise. | |
2250 | * cvt.c (warn_ref_binding): Likewise. | |
2251 | (convert_to_reference): Likewise. | |
2252 | (ocp_convert): Likewise. | |
2253 | (convert_to_void): Use error instead of pedwarn. | |
2254 | * error.c (cp_cpp_error): Use pedantic_warning_kind. | |
2255 | * decl.c (compute_array_index_type): Use constant_expression_error. | |
056dd1af | 2256 | |
4dbc8575 DG |
2257 | 2008-03-01 Douglas Gregor <doug.gregor@gmail.com> |
2258 | ||
2259 | * parser.c (cp_lexer_next_token_is_decl_specifier_keyword): Note | |
2260 | that auto is either a storage class or a simple type specifier, | |
2261 | depending on the dialect. | |
2262 | (cp_parser_decl_specifier_seq): Complain about `auto' as a storage | |
2263 | specifier in C++98 mode, error in C++0x mode (since we don't | |
2264 | support auto as a type specifier, yet). | |
2265 | (cp_parser_storage_class_specifier_opt): Don't treat `auto' as a | |
2266 | storage specifier in C++0x mode. | |
2267 | (cp_parser_simple_type_specifier): Parse `auto' as a | |
2268 | simple-type-specifier, but error because we don't support it yet. | |
2269 | ||
359be76e MLI |
2270 | 2008-02-29 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2271 | ||
2272 | * parser.c (cp_parser_nonclass_name): New. | |
2273 | (cp_parser_pseudo_destructor_name): Use it instead of | |
2274 | cp_parser_type_name. | |
2275 | (cp_parser_type_name): Move code to cp_parser_nonclass_name. | |
2276 | ||
966e8f4d TT |
2277 | 2008-02-29 Tom Tromey <tromey@redhat.com> |
2278 | ||
2279 | * parser.c (struct cp_token) <input_file_stack_index>: Remove. | |
2280 | (cp_lexer_get_preprocessor_token): Update. | |
2281 | (cp_lexer_set_source_position_from_token): Don't call | |
2282 | restore_input_file_stack. | |
2283 | * lex.c (cxx_init): Don't use push_srcloc or pop_srcloc. | |
2284 | ||
3b302421 RG |
2285 | 2008-02-28 Richard Guenther <rguenther@suse.de> |
2286 | ||
2287 | Revert: | |
2288 | 2008-02-26 Richard Guenther <rguenther@suse.de> | |
2289 | ||
2290 | * decl.c (duplicate_decls): Remove decl from global mapping | |
2291 | before ggc_freeing it. | |
2292 | ||
a15f0fd0 JJ |
2293 | 2008-02-27 Jakub Jelinek <jakub@redhat.com> |
2294 | ||
2295 | PR c++/35368 | |
2296 | * rtti.c: Include c-pragma.h. | |
2297 | (push_abi_namespace, pop_abi_namespace): New functions. | |
2298 | (build_dynamic_cast_1, tinfo_base_init, get_pseudo_ti_index, | |
2299 | create_tinfo_types, emit_support_tinfos): Use them. | |
2300 | * Make-lang.in (cp/rtti.o): Depend on $(C_PRAGMA_H). | |
2301 | ||
317c435f JM |
2302 | 2008-02-26 Jason Merrill <jason@redhat.com> |
2303 | ||
2304 | PR c++/35315 | |
2305 | * decl.c (grokdeclarator): Allow a typedef of an unnamed struct | |
2306 | to name the struct for linkage purposes even if it has attributes. | |
2307 | (start_decl): In that case, set ATTR_FLAG_TYPE_IN_PLACE. | |
2308 | ||
2d593c86 TT |
2309 | 2008-02-26 Tom Tromey <tromey@redhat.com> |
2310 | ||
2311 | * parser.c (eof_token): Remove old location code. | |
2312 | (check_empty_body): Remove test of USE_MAPPED_LOCATION. | |
2313 | * decl2.c (generate_ctor_or_dtor_function): Remove old location | |
2314 | code. | |
2315 | (cp_write_global_declarations): Likewise. | |
2316 | * lex.c (cxx_init): Remove old location code. | |
2317 | (handle_pragma_implementation): Remove test of | |
2318 | USE_MAPPED_LOCATION. | |
2319 | * pt.c (tsubst): Remove old location code. | |
2320 | * error.c (cp_print_error_function): Remove test of | |
2321 | USE_MAPPED_LOCATION. | |
2322 | * decl.c (pop_label): Remove old location code. | |
2323 | (finish_function): Likewise. | |
2324 | ||
4f01eeb4 MLI |
2325 | 2008-02-26 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2326 | ||
2327 | PR 26264 | |
2328 | * call.c (magic_varargs_p): Remove BUILT_IN_STDARG_START. | |
056dd1af | 2329 | |
bbd59cf4 RG |
2330 | 2008-02-26 Richard Guenther <rguenther@suse.de> |
2331 | ||
2332 | * decl.c (duplicate_decls): Remove decl from global mapping | |
2333 | before ggc_freeing it. | |
2334 | ||
50a70b6b PC |
2335 | 2008-02-26 Paolo Carlini <pcarlini@suse.de> |
2336 | ||
056dd1af L |
2337 | PR c++/35323 |
2338 | * name-lookup.c (arg_assoc_type): Handle FIXED_POINT_TYPE. | |
50a70b6b | 2339 | |
683d6ff9 | 2340 | 2008-02-26 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
056dd1af | 2341 | |
683d6ff9 MLI |
2342 | * typeck.c (build_class_member_access_expr): Add appropriate |
2343 | OPT_W* parameter to warning. | |
2344 | (build_reinterpret_cast_1): Likewise. | |
2345 | * name-lookup.c (push_overloaded_decl): Likewise. | |
056dd1af | 2346 | |
998ceda2 PC |
2347 | 2008-02-25 Paolo Carlini <pcarlini@suse.de> |
2348 | ||
056dd1af L |
2349 | PR c++/35333 |
2350 | * error.c (dump_expr): Handle CONJ_EXPR. | |
998ceda2 PC |
2351 | |
2352 | 2008-02-25 Paolo Carlini <pcarlini@suse.de> | |
2353 | ||
056dd1af L |
2354 | PR c++/35338 |
2355 | * error.c (dump_type): Handle FIXED_POINT_TYPE. | |
998ceda2 PC |
2356 | (dump_expr): Handle FIXED_CST. |
2357 | ||
4cfaec1c JM |
2358 | 2008-02-24 Jason Merrill <jason@redhat.com> |
2359 | ||
2360 | * parser.c (cp_parser_declaration): Handle "inline namespace". | |
2361 | (cp_parser_namespace_definition): Likewise. | |
2362 | ||
2363 | PR c++/33486 | |
056dd1af | 2364 | * name-lookup.c (arg_assoc_namespace): Look down into inline |
4cfaec1c JM |
2365 | namespaces, too. |
2366 | ||
86b7b98b MLI |
2367 | 2008-02-23 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2368 | ||
2369 | * typeck.c (check_for_casting_away_constness): Use 1 single | |
2370 | argument, the type of cast, to decide what diagnostics generate. | |
2371 | (build_static_cast_1): Remove unused code. Update call to | |
2372 | check_for_casting_away_constness. | |
2373 | (build_reinterpret_cast_1): Update call to | |
2374 | check_for_casting_away_constness. | |
2375 | (build_const_cast_1): Likewise. | |
056dd1af | 2376 | |
a84a98ca PC |
2377 | 2008-02-24 Paolo Carlini <pcarlini@suse.de> |
2378 | ||
2379 | * error.c (dump_expr): Don't deal directly with NEW_EXPR (and | |
2380 | VEC_NEW_EXPR), forward to pp_expression. | |
2381 | * cxx-pretty-print.c (pp_cxx_new_expression): Fix FIXME. | |
2382 | ||
bdd6df52 DS |
2383 | 2008-02-24 Danny Smith <dannysmith@users.sourceforge.net> |
2384 | ||
2385 | PR c++/34749 | |
2386 | * friend.c (do_friend): Call cplus_decl_attributes earlier. | |
2387 | ||
1eea53df AP |
2388 | 2008-02-22 Andrew Pinski <andrew_pinski@playstation.sony.com> |
2389 | ||
2390 | PR C++/34715 | |
2391 | * decl.c (duplicate_decls): Merge DECL_DISREGARD_INLINE_LIMITS for | |
2392 | template decls' function decl. | |
2393 | ||
54062fc0 PC |
2394 | 2008-02-22 Paolo Carlini <pcarlini@suse.de> |
2395 | ||
2396 | PR c++/35282 | |
2397 | Revert: | |
2398 | 2008-02-14 Paolo Carlini <pcarlini@suse.de> | |
2399 | ||
056dd1af L |
2400 | PR c++/28743 |
2401 | * pt.c (determine_specialization): In case of function templates, | |
54062fc0 PC |
2402 | when the type of DECL does not match FN there is no match. |
2403 | ||
ae311566 RW |
2404 | 2008-02-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de> |
2405 | ||
2406 | PR c/19999 | |
2407 | * typeck.c (build_binary_op): Warn about floating point | |
2408 | comparisons if FLOAT_TYPE_P, not only for REAL_TYPE. | |
2409 | ||
cc85b4c5 JM |
2410 | 2008-02-19 Jason Merrill <jason@redhat.com> |
2411 | ||
2412 | PR c++/34950 | |
2413 | * pt.c (resolve_overloaded_unification): Set processing_template_decl | |
2414 | while we look for possible bindings. | |
2415 | ||
dadb19e0 JJ |
2416 | 2008-02-19 Jakub Jelinek <jakub@redhat.com> |
2417 | ||
d2ee546f JJ |
2418 | PR c++/35028 |
2419 | * cp-gimplify.c (cxx_omp_clause_apply_fn): Handle vararg copy ctors. | |
2420 | ||
edb6000e JJ |
2421 | PR c++/34964 |
2422 | PR c++/35244 | |
2423 | * semantics.c (finish_omp_threadprivate): Do nothing for error_operand_p | |
2424 | vars. Afterwards ensure v is VAR_DECL. | |
2425 | ||
dadb19e0 JJ |
2426 | PR c++/35078 |
2427 | * parser.c (cp_parser_omp_for_loop): If DECL has REFERENCE_TYPE, don't | |
2428 | call cp_finish_decl. | |
2429 | * semantics.c (finish_omp_for): Fail if DECL doesn't have integral type | |
2430 | early. | |
2431 | ||
92fab505 DG |
2432 | 2008-02-15 Douglas Gregor <doug.gregor@gmail.com> |
2433 | ||
2434 | PR c++/35023 | |
2435 | PR c++/35024 | |
2436 | PR c++/35026 | |
2437 | * pt.c (finish_member_template_decl): If the type in a TYPE_DECL | |
2438 | is error_mark_node, return an error early. | |
2439 | (find_parameter_packs_r): Pass the pointer set along to recursive | |
2440 | calls of cp_walk_subtrees; don't try to manage the pointer set | |
2441 | ourselves. | |
2442 | (uses_parameter_packs): Pass the pointer set to cp_walk_tree. | |
2443 | (make_pack_expansion): Ditto. | |
2444 | (check_for_bare_parameter_packs): Ditto. Also, don't bother taking | |
2445 | a second pass through the tree with find_parameter_packs_r; that | |
2446 | second pass no longer does anything. | |
2447 | (push_template_decl_real): If we have an erroneous declaration, | |
2448 | set its type to error_mark_node before returning an error. | |
2449 | ||
625b6d91 DG |
2450 | 2008-02-14 Douglas Gregor <doug.gregor@gmail.com> |
2451 | ||
2452 | PR c++/34050 | |
2453 | * pt.c (tsubst_initializer_list): Deal with the use of | |
2454 | VOID_TYPE_NODE to indicate value-initialization of the bases. | |
2455 | ||
8c95264b MLI |
2456 | 2008-02-14 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
2457 | Jason Merrill <jason@redhat.com> | |
2458 | ||
2459 | PR c++/5645 | |
2460 | PR c++/11159 | |
2461 | * class.c (type_has_user_nondefault_constructor): New fn. | |
2462 | * cp-tree.h: Declare it. | |
2463 | * init.c (emit_mem_initializers): Use it for -W warning about | |
2464 | missing base initializer. | |
2465 | ||
4571259b PC |
2466 | 2008-02-14 Paolo Carlini <pcarlini@suse.de> |
2467 | ||
056dd1af L |
2468 | PR c++/28743 |
2469 | * pt.c (determine_specialization): In case of function templates, | |
4571259b PC |
2470 | when the type of DECL does not match FN there is no match. |
2471 | ||
5586014a JJ |
2472 | 2008-02-13 Jakub Jelinek <jakub@redhat.com> |
2473 | Manuel Lopez-Ibanez <manu@gcc.gnu.org> | |
2474 | ||
2475 | PR c++/35138 | |
2476 | * parser.c (cp_parser_pseudo_destructor_name): If next tokens | |
2477 | are not identifier :: ~, return before calling cp_parser_type_name. | |
2478 | ||
3387721b JM |
2479 | 2008-02-13 Jason Merrill <jason@redhat.com> |
2480 | ||
8d2eb304 | 2481 | PR c++/34962, c++/34937, c++/34939 |
056dd1af | 2482 | * decl2.c (is_late_template_attribute): Always defer attributes |
8d2eb304 JM |
2483 | vector_size and weak. |
2484 | ||
3387721b JM |
2485 | PR c++/34774 |
2486 | * pt.c (value_dependent_expression_p): Look into DECL_INITIAL | |
2487 | of enumerators, too. | |
2488 | ||
156d614f JM |
2489 | 2008-02-12 Jason Merrill <jason@redhat.com> |
2490 | ||
2491 | PR c++/34824 | |
317c435f | 2492 | * call.c (convert_like_real): Pass LOOKUP_NO_CONVERSION to build_temp |
156d614f JM |
2493 | if we're doing conversions to call a user-defined conversion function. |
2494 | ||
43854f72 SB |
2495 | 2008-02-12 Steven Bosscher <steven@gcc.gnu.org> |
2496 | ||
2497 | PR c++/29048 | |
2498 | * semantics.c (finish_qualified_id_expr): Avoid duplicate access | |
2499 | check here, too. | |
2500 | ||
a9de800a JJ |
2501 | 2008-02-12 Jakub Jelinek <jakub@redhat.com> |
2502 | ||
2503 | PR c++/34862 | |
2504 | * init.c (build_new_1): Don't create placement_expr before | |
2505 | constructing alloc_call. Verify that the pointer is passed by | |
2506 | value to operator new. | |
2507 | ||
02e52ae5 JM |
2508 | 2008-02-11 Jason Merrill <jason@redhat.com> |
2509 | ||
2510 | PR c++/35097 | |
2511 | * pt.c (tsubst): Don't look up a template typedef in an explicit | |
2512 | specialization. | |
2513 | ||
37d24376 DG |
2514 | 2008-02-11 Douglas Gregor <doug.gregor@gmail.com> |
2515 | ||
056dd1af L |
2516 | PR c++/35113 |
2517 | * tree.c (cp_build_qualified_type_real): When building a | |
2518 | cv-qualified array type, build it as a unique type with | |
2519 | build_cplus_array_type_1 and then adopt the unqualified type's | |
2520 | main variant. | |
2521 | ||
ba19e12f PC |
2522 | 2008-02-11 Paolo Carlini <pcarlini@suse.de> |
2523 | ||
2524 | PR c++/35077 | |
2525 | * decl.c (groktypename): Check grokdeclarator return. | |
2526 | ||
6c5613b0 JM |
2527 | 2008-02-10 Jason Merrill <jason@redhat.com> |
2528 | ||
2529 | PR c++/34094 | |
056dd1af | 2530 | * decl2.c (cp_write_global_declarations): Don't write out static |
6c5613b0 JM |
2531 | data members with DECL_IN_AGGR_P set. |
2532 | ||
7efc22ea JM |
2533 | 2008-02-08 Jason Merrill <jason@redhat.com> |
2534 | ||
2535 | PR c++/35116 | |
2536 | * tree.c (build_target_expr_with_type): Handle void initializer. | |
2537 | (bot_manip): Remap slot before recursing. | |
2538 | ||
72fb133f KG |
2539 | 2008-02-06 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
2540 | ||
2541 | PR other/35107 | |
2542 | * Make-lang.in (cc1plus-dummy, cc1plus): Add $(GMPLIBS). | |
2543 | ||
04941f76 AO |
2544 | 2008-02-06 Alexandre Oliva <aoliva@redhat.com> |
2545 | ||
2546 | PR c++/35056 | |
2547 | * tree.c: Include tree-flow.h. | |
2548 | (build_target_expr): Check type compatibility. | |
2549 | * Make-lang.in (cp/tree.o): Depend on $(TREE_FLOW_H). | |
2550 | * call.c (convert_like_real): Convert bitfield to expected type. | |
2551 | ||
f76e50b9 DG |
2552 | 2008-02-06 Douglas Gregor <doug.gregor@gmail.com> |
2553 | ||
2554 | PR c++/35049 | |
2555 | PR c++/35096 | |
2556 | * typeck.c (structural_comptypes): Call cp_comptypes. | |
2557 | (comptypes): New; called from the C/C++ common bits to perform | |
2558 | strict checks. | |
2559 | (cp_comptypes): Renamed from comptypes, which is already used, | |
2560 | with a different signature, by the C++ front end. | |
2561 | (build_reinterpret_cast_1): Call cp_comptypes. | |
2562 | (ptr_reasonably_similar): Ditto. | |
2563 | * decl.c (decls_match): Ditto. | |
2564 | * cvt.c (convert_to_reference): Ditto. | |
2565 | * cp-tree.h (same_type_p): Ditto. | |
2566 | (same_or_base_type_p): Ditto. | |
2567 | (comptypes): Rename to cp_comptypes. | |
2568 | * pt.c (canonical_type_parameter): Call cp_comptypes. | |
2569 | ||
6a279e92 JJ |
2570 | 2008-02-05 Jakub Jelinek <jakub@redhat.com> |
2571 | ||
2572 | PR c++/33553 | |
2573 | * pt.c (tsubst) <case INTEGER_TYPE>: Don't issue error if max is | |
2574 | value dependent expression. | |
2575 | ||
1db54f4e DG |
2576 | 2008-02-05 Douglas Gregor <doug.gregor@gmail.com> |
2577 | ||
2578 | PR c++/35074 | |
2579 | * decl2.c (save_template_attributes): When we're modifying the | |
2580 | TYPE_MAIN_VARIANT to add new attributes, be sure to also modify | |
2581 | all of the other variants to add those same attributes. Otherwise, | |
2582 | the main variant will be inconsistent with those other variants. | |
056dd1af | 2583 | |
70c7fe74 RG |
2584 | 2008-02-04 Richard Guenther <rguenther@suse.de> |
2585 | ||
2586 | PR java/35035 | |
2587 | * decl.c (record_builtin_java_type): Make jboolean a | |
2588 | integer type again where its mode doesn't match that of bool. | |
2589 | ||
0fcedd9c JM |
2590 | 2008-02-02 Jason Merrill <jason@redhat.com> |
2591 | Mark Mitchell <mark@codesourcery.com> | |
2592 | ||
2593 | PR c++/33916 | |
2594 | * init.c (build_value_init_1): New function. | |
2595 | (build_value_init): New function. | |
2596 | * typeck2.c (build_functional_cast): Call it. | |
2597 | * cp-gimplify.c (cp_gimplify_init_expr): Handle its output. | |
2598 | ||
056dd1af | 2599 | * cp-tree.h (TYPE_HAS_USER_CONSTRUCTOR): Rename from |
0fcedd9c JM |
2600 | TYPE_HAS_CONSTRUCTOR. |
2601 | * class.c (finish_struct_bits, maybe_warn_about_overly_private_class, | |
2602 | add_implicitly_declared_members): Adjust. | |
2603 | (check_field_decls): Adjust. Remove warnings about reference/const | |
2604 | in class without constructor. | |
2605 | (check_bases_and_members): Adjust. Give those warnings here instead. | |
2606 | * decl.c (fixup_anonymous_aggr): Adjust. | |
2607 | (check_initializer): Adjust, clarify logic slightly. | |
2608 | (grok_special_member_properties): Adjust, only set if user-provided. | |
2609 | * rtti.c (create_tinfo_types): Don't set. | |
2610 | * cvt.c (ocp_convert): Remove exception for vtable_entry_type et al. | |
2611 | Use same_type_ignoring_top_level_qualifiers_p. | |
2612 | * pt.c (check_explicit_specialization): Adjust. | |
2613 | (instantiate_class_template): Adjust. | |
2614 | ||
0451301c | 2615 | 2008-01-31 Douglas Gregor <doug.gregor@gmail.com> |
056dd1af | 2616 | Jakub Jelinek <jakub@redhat.com> |
0451301c | 2617 | |
056dd1af L |
2618 | PR c++/34935 |
2619 | PR c++/34936 | |
2620 | * typeck.c (structural_comptypes): Handle comparisons of | |
2621 | VOID_TYPE, BOOLEAN_TYPE, INTEGER_TYPE, FIXED_POINT_TYPE, and | |
2622 | REAL_TYPE nodes. | |
2623 | * mangle.c (write_builtin_type): Map down to the canonical type, | |
2624 | which will be one of the predefined type nodes. | |
0451301c | 2625 | |
bdba2263 MM |
2626 | 2008-01-29 Michael Meissner <michael.meissner@amd.com> |
2627 | ||
2628 | PR 35004 | |
2629 | * cp-tree.h (struct full_lang_decl): Make tree_code bitfield 16 | |
2630 | bits to allow for expansion of the number of middle end tree | |
2631 | codes. | |
2632 | ||
7b3e2d46 DG |
2633 | 2008-01-29 Douglas Gregor <doug.gregor@gmail.com> |
2634 | ||
2635 | PR c++/34055 | |
2636 | PR c++/34103 | |
2637 | PR c++/34219 | |
2638 | PR c++/34606 | |
2639 | PR c++/34753 | |
2640 | PR c++/34754 | |
2641 | PR c++/34755 | |
2642 | PR c++/34919 | |
2643 | PR c++/34961 | |
2644 | * typeck.c (check_return_expr): Tweak call to | |
2645 | check_for_bare_parameter_packs. | |
2646 | * class.c (add_method): Be careful with error_mark_nodes. | |
2647 | * cp-tree.h (check_for_bare_parameter_packs): Remove "*" from | |
2648 | signature. | |
2649 | * pt.c (struct find_parameter_pack_data): Remove | |
2650 | SET_PACKS_TO_ERROR. | |
2651 | (find_parameter_packs_r): Don't use SET_PACKS_TO_ERROR. | |
2652 | (uses_parameter_packs): Don't set SET_PACKS_TO_ERROR. | |
2653 | (make_pack_expansion): Ditto. | |
2654 | (check_for_bare_parameter_packs): Parameter is now a tree, not a | |
2655 | tree*. | |
2656 | (process_template_parm): Tweak call to | |
056dd1af | 2657 | check_for_bare_parameter_packs. |
7b3e2d46 DG |
2658 | (push_template_decl_real): Tweak calls to |
2659 | check_for_bare_parameter_packs. If bare parameter packs are found | |
2660 | in the list of exceptions, clear out that list after giving an | |
2661 | error. | |
2662 | * semantics.c (finish_cond): Tweak call to | |
2663 | check_for_bare_parameter_packs. | |
2664 | (finish_expr_stmt): Ditto. | |
2665 | (finish_for_expr): Ditto. | |
2666 | (finish_switch_cond): Ditto. | |
2667 | (finish_mem_initializers): Ditto. | |
2668 | (finish_member_declaration): Ditto. | |
2669 | (finish_static_assert): Check for bare parameter packs in the | |
2670 | condition. | |
2671 | * decl2.c (cplus_decl_attributes): Check for bare parameter packs in the | |
2672 | attributes of a declaration. | |
2673 | * parser.c (cp_parser_using_declaration): Tweak call to | |
2674 | check_for_bare_parameter_packs. | |
2675 | (cp_parser_base_clause): Ditto. | |
2676 | ||
dc555429 JM |
2677 | 2008-01-28 Jason Merrill <jason@redhat.com> |
2678 | ||
2679 | PR c++/35007 | |
2680 | * class.c (build_base_path): Fix !want_pointer case. | |
2681 | ||
7a0b47e3 JM |
2682 | 2008-01-27 Jason Merrill <jason@redhat.com> |
2683 | ||
2684 | PR c++/27177 | |
2685 | * class.c (build_base_path): Fix previous change. | |
2686 | ||
6f536f74 JJ |
2687 | 2008-01-26 Jakub Jelinek <jakub@redhat.com> |
2688 | ||
2689 | PR c++/34965 | |
2690 | * error.c (dump_expr): Handle TRUTH_AND_EXPR, TRUTH_OR_EXPR | |
2691 | and TRUTH_XOR_EXPR. | |
2692 | ||
2f35df8c RG |
2693 | 2008-01-26 Richard Guenther <rguenther@suse.de> |
2694 | ||
2695 | PR c++/34235 | |
2696 | * typeck.c (build_binary_op): Remove code to shorten compares. | |
2697 | ||
291de7fc RG |
2698 | 2008-01-25 Richard Guenther <rguenther@suse.de> |
2699 | ||
2700 | PR c++/33887 | |
2701 | * decl.c (record_builtin_java_type): Make __java_boolean | |
2702 | a variant of bool. | |
2703 | * typeck.c (structural_comptypes): Move TYPE_FOR_JAVA check | |
2704 | after TYPE_MAIN_VARIANT check. | |
2705 | ||
1d555e26 JM |
2706 | 2008-01-25 Jason Merrill <jason@redhat.com> |
2707 | ||
d79ca207 JM |
2708 | PR c++/27177 |
2709 | * class.c (build_base_path): Don't mess with virtual access if | |
2710 | skip_evaluation. | |
2711 | * call.c (standard_conversion): Don't check whether source type | |
2712 | is complete. | |
2713 | ||
1d555e26 JM |
2714 | * decl2.c (is_late_template_attribute): Don't defer attribute |
2715 | visibility just because the type is dependent. | |
2716 | ||
b6219f42 JM |
2717 | 2008-01-25 Jason Merrill <jason@redhat.com> |
2718 | Mark Mitchell <mark@codesourcery.com> | |
2719 | ||
2720 | PR c++/31780 | |
2721 | * call.c (standard_conversion): Allow conversion from integer/real | |
2722 | to complex. | |
2723 | (compare_ics): Such a conversion is worse than a normal arithmetic | |
2724 | conversion. | |
056dd1af | 2725 | |
57e2aff2 RG |
2726 | 2008-01-25 Richard Guenther <rguenther@suse.de> |
2727 | ||
2728 | PR c++/33887 | |
2729 | * cp-lang.c (LANG_HOOKS_REDUCE_BIT_FIELD_OPERATIONS): Define | |
2730 | to true. | |
2731 | ||
3fe82414 PC |
2732 | 2008-01-24 Paolo Carlini <pcarlini@suse.de> |
2733 | ||
056dd1af L |
2734 | PR c++/34603 |
2735 | * pt.c (push_template_decl_real): Return error_mark_node in case | |
3fe82414 PC |
2736 | of template definition of non-template. |
2737 | ||
160b8b80 JM |
2738 | 2008-01-24 Jason Merrill <jason@redhat.com> |
2739 | ||
2740 | PR c++/34913 | |
056dd1af | 2741 | * decl2.c (is_late_template_attribute): Defer any attribute with |
160b8b80 JM |
2742 | dependent args. Also defer type attributes if the type is dependent. |
2743 | ||
3fe82414 PC |
2744 | 2008-01-22 Jakub Jelinek <jakub@redhat.com> |
2745 | Alexandre Oliva <aoliva@redhat.com> | |
24030e4c JJ |
2746 | |
2747 | PR c++/33984 | |
2748 | * call.c (reference_binding): For bitfields use the declared bitfield | |
2749 | type. | |
2750 | (add_builtin_candidates): Likewise. | |
2751 | * class.c (layout_class_type): For bitfields copy over the | |
2752 | original type quals. | |
2753 | ||
7655e009 JM |
2754 | 2008-01-22 Jason Merrill <jason@redhat.com> |
2755 | ||
b2a7def5 | 2756 | PR c++/28560 |
056dd1af | 2757 | * decl.c (groktypename): Also ignore attributes on dependent |
b2a7def5 JM |
2758 | possibly-class types. |
2759 | ||
7655e009 | 2760 | PR c++/34912 |
056dd1af | 2761 | * friend.c (do_friend): Check for prior declaration of a friend |
7655e009 | 2762 | function of a local class. |
056dd1af | 2763 | * name-lookup.c (lookup_name_innermost_nonclass_level): |
7655e009 JM |
2764 | No longer static. |
2765 | * name-lookup.h: Declare it. | |
2766 | ||
255ef034 TT |
2767 | 2008-01-22 Tom Tromey <tromey@redhat.com> |
2768 | ||
2769 | PR c++/34829: | |
2770 | * init.c (build_new_1): Only disallow Java aggregates. | |
2771 | ||
e94384db JJ |
2772 | 2008-01-22 Jakub Jelinek <jakub@redhat.com> |
2773 | ||
61c3a446 JJ |
2774 | PR c++/34607 |
2775 | * semantics.c (finish_omp_for): Don't call c_finish_omp_for | |
2776 | if decl or init is error_mark_node. | |
2777 | ||
e94384db JJ |
2778 | PR c++/34918 |
2779 | * error.c (dump_expr): Handle VECTOR_CST. | |
2780 | ||
33b45227 JM |
2781 | 2008-01-21 Jason Merrill <jason@redhat.com> |
2782 | ||
29b0d1fd JM |
2783 | PR c++/33959 |
2784 | * pt.c (tsubst_aggr_type): Make sure our context is complete. | |
2785 | ||
2786 | PR c++/34573 | |
2787 | * pt.c (retrieve_local_specialization): Robustify. | |
2788 | (tsubst_pack_expansion, tsubst_decl): Remove redundant checks. | |
2789 | ||
2790 | PR c++/34846 | |
2791 | * pt.c (tsubst): Only call retrieve_local_specialization if the | |
2792 | original typedef was in a function template. | |
2793 | ||
33b45227 JM |
2794 | PR c++/34196 |
2795 | * decl.c (wrap_cleanups_r): Set TRY_CATCH_IS_CLEANUP. | |
2796 | ||
02dcf7ba RG |
2797 | 2008-01-21 Richard Guenther <rguenther@suse.de> |
2798 | ||
2799 | PR c++/34850 | |
2800 | * error.c (cp_print_error_function): Deal with recursive | |
2801 | BLOCK trees. | |
2802 | ||
b8ce93da PC |
2803 | 2008-01-20 Paolo Carlini <pcarlini@suse.de> |
2804 | ||
056dd1af L |
2805 | PR c++/34891 |
2806 | * error.c (dump_expr): Deal with VIEW_CONVERT_EXPR. | |
b8ce93da | 2807 | |
dbc21af5 PC |
2808 | 2008-01-20 Paolo Carlini <pcarlini@suse.de> |
2809 | ||
056dd1af | 2810 | PR c++/34776 |
dbc21af5 | 2811 | PR c++/34486 |
056dd1af | 2812 | * name-lookup.c (do_class_using_decl): Do not call constructor_name_p |
dbc21af5 PC |
2813 | on non-IS_AGGR_TYPE scope. |
2814 | (constructor_name_p): Assert IS_AGGR_TYPE. | |
2815 | ||
1ea193c2 ILT |
2816 | 2008-01-18 Ian Lance Taylor <iant@google.com> |
2817 | ||
2818 | PR c++/33407 | |
2819 | * decl.c (duplicate_decls): Copy DECL_IS_OPERATOR_NEW flag. | |
2820 | (grok_op_properties): For NEW_EXPR and VEC_NEW_EXPR set | |
2821 | DECL_IS_OPERATOR_NEW flag. | |
2822 | ||
be2b5483 RG |
2823 | 2008-01-16 Richard Guenther <rguenther@suse.de> |
2824 | ||
2825 | PR c++/33819 | |
2826 | * typeck.c (is_bitfield_expr_with_lowered_type): Recurse | |
2827 | for conversions to type variants. | |
2828 | ||
cde7bfee AT |
2829 | 2008-01-15 Andreas Tobler <a.tobler@schweiz.org> |
2830 | ||
2831 | * parser.c (cp_parser_template_parameter): Fix C90 issue with mixing | |
2832 | declaration and code. Update copyright year. | |
2833 | ||
ac90ae18 DG |
2834 | 2008-01-15 Douglas Gregor <doug.gregor@gmail.com> |
2835 | ||
2836 | PR c++/34399 | |
2837 | * friend.c (do_friend): Don't query TYPE_BEING_DEFINED unless we | |
2838 | know we have a class type. | |
2839 | ||
cdcae745 DG |
2840 | 2008-01-15 Douglas Gregor <doug.gregor@gmail.com> |
2841 | ||
2842 | PR c++/34751 | |
2843 | * pt.c (coerce_template_parameter_pack): When substituting into | |
2844 | the type of a non-type template parameter pack. use the | |
2845 | deduced/substituted arguments. | |
2846 | * parser.c (declarator_can_be_parameter_pack): A pointer-to-member | |
2847 | can be a parameter pack with the ellipsis following it. When we | |
2848 | have an erroneous declaration, allow it to be a parameter pack. | |
2849 | (cp_parser_template_parameter): Complain about default | |
2850 | arguments on non-type template parameter packs, and parse them | |
2851 | using the new cp_parser_default_argument. | |
2852 | (cp_parser_parameter_declaration): Complain about parameter packs | |
2853 | with default arguments. Move parsing of default arguments into a | |
2854 | new function, cp_parser_default_argument. | |
2855 | (cp_parser_default_argument): New; extracted from | |
2856 | cp_parser_parameter_declaration. | |
2857 | ||
4439d02f DG |
2858 | 2008-01-15 Douglas Gregor <doug.gregor@gmail.com> |
2859 | ||
2860 | PR c++/34051 | |
2861 | PR c++/34055 | |
2862 | PR c++/34102 | |
2863 | PR c++/34103 | |
2864 | * typeck.c (check_return_expr): If there are bare parameter packs | |
2865 | in the return value, set it to error_mark_node. | |
2866 | * tree.c (cp_walk_subtrees): Walk USING_DECL nodes. | |
2867 | * pt.c (find_parameter_packs_r): Look at the type of | |
2868 | IDENTIFIER_NODEs (e.g., for user-defined conversions). | |
2869 | (check_for_bare_parameter_packs): Flip the result: now returns | |
2870 | TRUE when there were bare parameter packs, FALSE otherwise. | |
2871 | (push_template_decl_real): Deal with flipped result of | |
2872 | check_for_bare_parameter_packs. | |
2873 | * semantics.c (finish_cond): If there are bare parameter packs in | |
2874 | the conditional, set it to error_mark_node. | |
2875 | (finish_expr_stmt): If there are bare parameter packs in the | |
2876 | expression, set it to error_mark_node. | |
2877 | (finish_for_expr): Ditto. | |
2878 | (finish_switch_cond): If there are bare parameter packs in | |
2879 | the conditional, set it to error_mark_node. | |
2880 | (finish_mem_initializers): If there are bare parameter packs in | |
2881 | the member initializer, set it to error_mark_node. | |
2882 | (finish_member_declaration): Check the attributes of the | |
2883 | declaration for bare parameter packs, and remove the attributes if | |
2884 | any have bare parameter packs. | |
2885 | * parser.c (cp_parser_using_declaration): Check the using | |
2886 | declaration for bare parameter packs. | |
2887 | (cp_parser_base_clause): If there are bare parameter packs in a | |
2888 | base specifier, don't add it to the chain. | |
2889 | ||
a022041e DG |
2890 | 2008-01-15 Douglas Gregor <doug.gregor@gmail.com> |
2891 | ||
056dd1af L |
2892 | PR c++/34314 |
2893 | * error.c (dump_simple_decl): Display ellipsis for template | |
2894 | non-type parameter packs. | |
2895 | (dump_decl): Display ellipsis for template type parameter packs. | |
2896 | (dump_template_decl): Display ellipsis for template template | |
2897 | parameter packs. | |
2898 | * pt.c (redeclare_class_template): When redeclaring a class | |
2899 | template, check for collisions between template parameters and | |
2900 | template parameter packs. | |
a022041e | 2901 | |
c095a4f8 DG |
2902 | 2008-01-15 Douglas Gregor <doug.gregor@gmail.com> |
2903 | ||
056dd1af L |
2904 | PR c++/33964 |
2905 | * pt.c (process_partial_specialization): Don't mark template | |
2906 | parameters that occur in non-deduced contexts. | |
2907 | (struct pair_fn_data): Add include_nondeduced_p. | |
2908 | (for_each_template_parm_r): Only visit non-deduced contexts if | |
2909 | include_nondeduced_p is set. | |
2910 | (for_each_template_parm): Added parameter include_nondeduced_p, | |
2911 | which states whether template parameters found in non-deduced | |
2912 | contexts should be visited. | |
2913 | (uses_template_parms): Visit all template parameters, even those | |
2914 | in non-deduced contexts. | |
c095a4f8 | 2915 | |
85d85234 DG |
2916 | 2008-01-15 Douglas Gregor <doug.gregor@gmail.com> |
2917 | ||
056dd1af L |
2918 | PR c++/34052 |
2919 | * pt.c (check_default_tmpl_args): Check for parameter packs that | |
2920 | aren't at the end of a primary template. | |
2921 | (push_template_decl_real): Remove check for parameter packs that | |
2922 | aren't at the end of a primary template; that now happens in | |
2923 | check_default_tmpl_args. | |
2924 | * semantics.c (finish_template_template_parm): Use | |
2925 | check_default_tmpl_args to check for errors in the template | |
2926 | parameter list. | |
2927 | ||
5db2e9ca DK |
2928 | 2008-01-12 Doug Kwan <dougkwan@google.com> |
2929 | ||
2930 | * decl.c: (grokdeclarator): Use OPT_Wignored_qualifiers | |
2931 | instead of OPT_Wreturn_type in warning due to ignored return type | |
2932 | qualifiers. | |
2933 | * pt.c: (tsubst_function_type): Use OPT_Wignored_qualifiers | |
2934 | instead of OPT_Wreturn_type in warning due to ignored return type | |
2935 | qualifiers. | |
2936 | ||
b2ebd268 JJ |
2937 | 2008-01-08 Jakub Jelinek <jakub@redhat.com> |
2938 | ||
2939 | PR c++/33890 | |
2940 | * semantics.c (finish_omp_for): Don't call | |
2941 | fold_build_cleanup_point_expr if processing_template_decl. | |
2942 | ||
a9fe2f76 PC |
2943 | 2008-01-04 Paolo Carlini <pcarlini@suse.de> |
2944 | Jakub Jelinek <jakub@redhat.com> | |
2945 | ||
2946 | PR c++/34611 | |
2947 | * error.c (dump_template_argument): Deal with TREE_LIST. | |
2948 | ||
1a7817e4 DG |
2949 | 2008-01-01 Douglas Gregor <doug.gregor@gmail.com> |
2950 | ||
056dd1af L |
2951 | * parser.c (cp_parser_check_decl_spec): Don't warn about "long |
2952 | long" in C++0x mode; change the warning to note that "long long" | |
2953 | is only unsupported in C++98 mode. | |
1a7817e4 | 2954 | |
4c12c8ea JM |
2955 | 2007-12-20 Jason Merrill <jason@redhat.com> |
2956 | ||
2957 | PR c++/34111 | |
2958 | * call.c (standard_conversion): Derived-to-base is considered a | |
2959 | standard conversion. | |
2960 | ||
5259c813 JJ |
2961 | 2007-12-19 Jakub Jelinek <jakub@redhat.com> |
2962 | ||
2963 | PR c++/34513 | |
2964 | * parser.c (cp_parser_omp_parallel): For non-combined parallel | |
2965 | call cp_parser_statement rather than | |
2966 | cp_parser_already_scoped_statement. | |
2967 | ||
82390eb6 JM |
2968 | 2007-12-18 Jason Merrill <jason@redhat.com> |
2969 | ||
2970 | PR c++/34206 | |
056dd1af | 2971 | * pt.c (tsubst_aggr_type): Do nothing if the type already doesn't |
82390eb6 JM |
2972 | use template parms. |
2973 | (dependent_type_p_r): Handle the domain of an array. | |
2974 | ||
a15c0b00 | 2975 | 2007-12-18 Douglas Gregor <doug.gregor@gmail.com> |
056dd1af L |
2976 | Jakub Jelinek <jakub@redhat.com> |
2977 | ||
a15c0b00 DG |
2978 | PR c++/32565 |
2979 | PR c++/33943 | |
2980 | PR c++/33965 | |
2981 | * pt.c (template_template_parm_bindings_ok_p): New; verifies | |
2982 | bindings of template template parameters after all template | |
2983 | arguments have been deduced. | |
2984 | (coerce_template_parms): Don't complain when COMPLAIN doesn't | |
2985 | include tf_error. | |
056dd1af L |
2986 | (fn_type_unification): Use template_template_parm_bindings_ok_p. |
2987 | (unify): Deal with variadic, bound template template parameters. | |
2988 | (get_class_bindings): Use template_template_parm_bindings_ok_p. | |
a15c0b00 | 2989 | |
ac3b1156 JJ |
2990 | 2007-12-18 Jakub Jelinek <jakub@redhat.com> |
2991 | ||
2992 | PR c++/34488 | |
2993 | * decl.c (grokdeclarator): Reject friend sfk_constructor | |
2994 | FUNCTION_TYPE. | |
2995 | ||
8085ca15 JJ |
2996 | 2007-12-17 Jakub Jelinek <jakub@redhat.com> |
2997 | ||
2998 | PR c/34506 | |
2999 | * parser.c (cp_parser_omp_all_clauses): Accept optional comma | |
3000 | in between clauses. | |
3001 | ||
394d9fe7 AO |
3002 | 2007-12-15 Alexandre Oliva <aoliva@redhat.com> |
3003 | ||
3004 | PR debug/7081 | |
3005 | * cp-lang.c (cp_classify_record): New. | |
3006 | (LANG_HOOKS_CLASSIFY_RECORD): Override. | |
3007 | ||
61a861e6 JJ |
3008 | 2007-12-11 Jakub Jelinek <jakub@redhat.com> |
3009 | ||
5b767b9d JJ |
3010 | PR c++/34238 |
3011 | * decl2.c (cp_write_global_declarations): Revert 2007-11-22 change. | |
3012 | ||
61a861e6 JJ |
3013 | PR c++/34364 |
3014 | * rtti.c (build_dynamic_cast): Call convert_from_reference even for | |
3015 | dynamic_cast in a template. | |
3016 | ||
0197270c SM |
3017 | 2007-12-10 Simon Martin <simartin@users.sourceforge.net> |
3018 | ||
3019 | PR c++/34059 | |
3020 | * typeck.c (build_class_member_access_expr): Compute MEMBER_SCOPE from | |
3021 | MEMBER's BASELINK_ACCESS_BINFO instead of its BASELINK_BINFO. | |
3022 | ||
214452b9 JJ |
3023 | 2007-12-10 Jakub Jelinek <jakub@redhat.com> |
3024 | ||
e7de2d6f JJ |
3025 | PR c++/34395 |
3026 | * error.c (dump_type_prefix, dump_type_suffix): Handle | |
3027 | TYPE_PACK_EXPANSION. | |
3028 | ||
214452b9 JJ |
3029 | PR c++/34394 |
3030 | * error.c (dump_expr): Handle ABS_EXPR. | |
3031 | ||
23372b3f JJ |
3032 | 2007-12-09 Jakub Jelinek <jakub@redhat.com> |
3033 | ||
3034 | PR c++/34178 | |
3035 | PR c++/34340 | |
3036 | * repo.c (repo_emit_p): Return 2 for DECL_INTEGRAL_CONSTANT_VAR_P | |
3037 | in class scope rather than DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P. | |
3038 | Return 2 also if DECL_EXPLICIT_INSTANTIATION. | |
3039 | * decl2.c (import_export_decl): Don't make VAR_DECLs import_p when | |
3040 | flag_use_repository and repo_emit_p returned 2. | |
3041 | ||
28267cfc JJ |
3042 | 2007-12-06 Jakub Jelinek <jakub@redhat.com> |
3043 | ||
3044 | PR c++/34336 | |
3045 | * tree.c (stabilize_call, stabilize_init): Do nothing if | |
3046 | processing_template_decl. | |
3047 | ||
91929b4d JJ |
3048 | 2007-12-05 Jakub Jelinek <jakub@redhat.com> |
3049 | ||
3050 | PR c++/34271 | |
3051 | * semantics.c (finish_decltype_type): For SCOPE_REF issue an | |
3052 | error instead of assertion failure. | |
3053 | * parser.c (cp_parser_decltype): If closing paren is not found, | |
3054 | return error_mark_node. | |
3055 | ||
ba796308 DG |
3056 | 2007-12-04 Douglas Gregor <doug.gregor@gmail.com> |
3057 | ||
056dd1af L |
3058 | PR c++/34101 |
3059 | * name-lookup.c (arg_assoc_template_arg): Recurse on argument | |
3060 | packs. | |
3061 | (arg_assoc_type): We don't need to handle TYPE_ARGUMENT_PACK here, | |
3062 | since arg_assoc_template_arg will deal with them (better). | |
ba796308 | 3063 | |
2f93f02c DG |
3064 | 2007-12-04 Douglas Gregor <doug.gregor@gmail.com> |
3065 | ||
056dd1af L |
3066 | PR c++/33509 |
3067 | * pt.c (tsubst_exception_specification): Handle substitutions into | |
3068 | member templates, where tsubst_pack_expansion returns a | |
3069 | TYPE_PACK_EXPANSION. | |
2f93f02c | 3070 | |
db60ff18 DG |
3071 | 2007-12-04 Douglas Gregor <doug.gregor@gmail.com> |
3072 | ||
056dd1af L |
3073 | PR c++/33091 |
3074 | * pt.c (unify_pack_expansion): If we didn't deduce any actual | |
3075 | bindings for the template parameter pack, don't try to keep the | |
3076 | empty deduced arguments. | |
3077 | (unify): If a parameter is a template-id whose template argument | |
3078 | list contains a pack expansion that is not at the end, then we | |
3079 | cannot unify against that template-id. | |
db60ff18 | 3080 | |
0b93f014 PC |
3081 | 2007-12-02 Paolo Carlini <pcarlini@suse.de> |
3082 | ||
056dd1af L |
3083 | PR c++/34061 |
3084 | * pt.c (current_template_args): Use error_operand_p. | |
0b93f014 | 3085 | |
06be4f56 PC |
3086 | 2007-12-02 Paolo Carlini <pcarlini@suse.de> |
3087 | ||
056dd1af L |
3088 | PR c++/34273 |
3089 | * error.c (dump_decl): Handle TREE_BINFO. | |
06be4f56 | 3090 | |
867f133e OW |
3091 | 2007-12-01 Ollie Wild <aaw@google.com> |
3092 | ||
3093 | PR c++/8171 | |
3094 | * typeck.c (build_binary_op): Add conversion of pointers to function | |
3095 | members appearing as operands to the equality operators. | |
3096 | ||
89ab8ba0 JJ |
3097 | 2007-11-30 Jakub Jelinek <jakub@redhat.com> |
3098 | ||
3099 | PR c++/34275 | |
3100 | * error.c (dump_expr): Handle OBJ_TYPE_REF. | |
3101 | ||
7a547b93 JJ |
3102 | 2007-11-29 Jakub Jelinek <jakub@redhat.com> |
3103 | ||
42924ed7 JJ |
3104 | PR c++/34270 |
3105 | * tree.c (lvalue_p_1) <case COND_EXPR>: Handle x ?: y | |
3106 | in templates. | |
3107 | * typeck.c (is_bitfield_expr_with_lowered_type) <case COND_EXPR>: | |
3108 | Likewise. | |
3109 | ||
7a547b93 JJ |
3110 | PR c++/34267 |
3111 | PR c++/34268 | |
3112 | * parser.c (cp_parser_decltype): Don't call finish_id_expression | |
3113 | on ~type. | |
3114 | * semantics.c (finish_decltype_type): Issue error on types, TYPE_DECLs | |
3115 | and ~type early. | |
3116 | ||
ce41114b JJ |
3117 | 2007-11-27 Jakub Jelinek <jakub@redhat.com> |
3118 | ||
62cbbe84 JJ |
3119 | PR tree-optimization/34181 |
3120 | * method.c (use_thunk): Don't inline the call in the thunk. | |
3121 | ||
ce41114b JJ |
3122 | PR c++/34213 |
3123 | * tree.c (decl_linkage): Static data members and static member | |
3124 | functions in anonymous ns classes are lk_external. | |
3125 | ||
182e0d71 AK |
3126 | 2007-11-26 Andreas Krebbel <krebbel1@de.ibm.com> |
3127 | ||
ce41114b | 3128 | PR c++/34081 |
056dd1af | 3129 | * decl.c (start_preparsed_function): Pass |
182e0d71 AK |
3130 | processing_template_decl for the new allocate_struct_function |
3131 | parameter. | |
3132 | ||
87caf699 RG |
3133 | 2007-11-25 Richard Guenther <rguenther@suse.de> |
3134 | ||
42924ed7 | 3135 | * decl.c (poplevel): Use BLOCK_CHAIN. |
87caf699 | 3136 | |
a298680c OW |
3137 | 2007-11-24 Ollie Wild <aaw@google.com> |
3138 | ||
3139 | * typeck.c (delta_from_ptrmemfunc): New function. | |
3140 | (get_member_function_from_ptrfunc): Call delta_from_ptrmemfunc. | |
3141 | (build_binary_op): Call delta_from_ptrmemfunc. | |
3142 | ||
360f866c JJ |
3143 | 2007-11-23 Jakub Jelinek <jakub@redhat.com> |
3144 | ||
3145 | PR c++/30293 | |
3146 | PR c++/30294 | |
3147 | * decl.c (cp_finish_decl): Disallow variable or field | |
3148 | definitions if extern "Java" aggregates. | |
3149 | (grokparms): Disallow parameters with extern "Java" | |
3150 | aggregates. | |
3151 | (check_function_type): Disallow function return values | |
3152 | with extern "Java" aggregates. | |
3153 | * init.c (build_new_1): Disallow placement new with | |
3154 | extern "Java" aggregates. | |
3155 | ||
6ca39fcb MM |
3156 | 2007-11-23 Mark Mitchell <mark@codesourcery.com> |
3157 | Manuel Lopez-Ibanez <manu@gcc.gnu.org> | |
056dd1af | 3158 | |
6ca39fcb MM |
3159 | PR c++/5310 |
3160 | * call.c (convert_like_real): Build a zero constant when __null is | |
3161 | converted to an integer type. | |
056dd1af | 3162 | |
6d1f904c JJ |
3163 | 2007-11-22 Jakub Jelinek <jakub@redhat.com> |
3164 | ||
3165 | PR c++/34094 | |
3166 | * decl2.c (cp_write_global_declarations): Issue error about static | |
3167 | data members in anonymous namespace which are declared and used, | |
3168 | but not defined. | |
3169 | ||
63d34078 JJ |
3170 | 2007-11-20 Jakub Jelinek <jakub@redhat.com> |
3171 | ||
542f8eb9 JJ |
3172 | PR c++/34089 |
3173 | * parser.c (cp_parser_class_head): Reject function template ids. | |
3174 | ||
6da06848 JJ |
3175 | PR c++/28879 |
3176 | * tree.c (build_cplus_array_type_1): Don't pass any VLA types | |
3177 | when processing_template_decl to build_array_type. | |
3178 | ||
63d34078 JJ |
3179 | PR c++/33962 |
3180 | * pt.c (more_specialized_fn): Don't segfault if one or | |
3181 | both argument list end with ellipsis. | |
3182 | ||
be461b8f JJ |
3183 | 2007-11-18 Jakub Jelinek <jakub@redhat.com> |
3184 | ||
3185 | PR c++/30988 | |
6c01f02b JJ |
3186 | * semantics.c (finish_call_expr): Set |
3187 | current_function_returns_abnormally if fn is noreturn FUNCTION_DECL | |
3188 | or OVERLOAD with all noreturn functions. | |
be461b8f | 3189 | |
823e5f7f JJ |
3190 | 2007-11-16 Jakub Jelinek <jakub@redhat.com> |
3191 | ||
3192 | PR c++/34100 | |
3193 | * pt.c (apply_late_template_attributes): Do nothing if decl's type is | |
3194 | error_mark_node. | |
3195 | ||
ffbf5813 JJ |
3196 | 2007-11-13 Jakub Jelinek <jakub@redhat.com> |
3197 | ||
046e4071 JJ |
3198 | PR c++/34054 |
3199 | PR c++/34056 | |
3200 | PR c++/34057 | |
3201 | PR c++/34058 | |
3202 | PR c++/34060 | |
3203 | * pt.c (find_parameter_packs_r): If ppd->set_packs_to_error, | |
3204 | set to error_mark_node the outermost POINTER_TYPE to the pack if | |
3205 | it is seen in a POINTER_TYPE. | |
3206 | (push_template_decl_real): If check_for_bare_parameter_packs | |
3207 | fails for function return type, set the return type to | |
3208 | integer_type_node. If check_for_bare_parameter_packs failed | |
3209 | for non-function, return error_mark_node. | |
3210 | ||
ffbf5813 JJ |
3211 | PR c++/29225 |
3212 | * call.c (build_new_op): Call resolve_args before calling | |
3213 | build_over_call. | |
3214 | ||
f1e20710 TT |
3215 | 2007-11-11 Tom Tromey <tromey@redhat.com> |
3216 | ||
3217 | PR c++/17577: | |
3218 | * lex.c (handle_pragma_implementation): Use cpp_included_before. | |
3219 | ||
b131ad7c MLI |
3220 | 2007-11-12 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
3221 | ||
3222 | PR c++/8570 | |
3223 | * pt.c (redeclare_class_template): Update error message. Use a | |
3224 | note to show the previous declaration. | |
3225 | (tsubst_friend_class): Use the location of the friend template as | |
3226 | the input location before calling redeclare_class_template. | |
3227 | ||
09b1ccd6 JJ |
3228 | 2007-11-11 Jakub Jelinek <jakub@redhat.com> |
3229 | ||
3230 | PR c++/34068 | |
3231 | * semantics.c (finish_pseudo_destructor_expr): Handle | |
3232 | object == error_mark_node. | |
3233 | ||
3d9b2eb6 JJ |
3234 | 2007-11-10 Jakub Jelinek <jakub@redhat.com> |
3235 | ||
3236 | PR c++/32241 | |
3237 | * pt.c (tsubst_copy_and_build) <case COMPONENT_REF>: If object_type | |
3238 | is not scalar type, let finish_class_member_access_expr handle | |
3239 | diagnostics. Pass BIT_NOT_EXPR argument to | |
3240 | finish_pseudo_destructor_expr. Handle SCOPE_REF properly. | |
3241 | ||
49b5e2f6 DG |
3242 | 2007-11-09 Douglas Gregor <doug.gregor@gmail.com> |
3243 | ||
3244 | PR c++/33510 | |
3245 | * decl.c (cp_complete_array_type): If any of the initializer | |
3246 | elements are pack expansions, don't compute the array size yet. | |
3247 | ||
c02cdc25 TT |
3248 | 2007-11-08 Andrew Pinski <pinskia@gmail.com> |
3249 | ||
3250 | PR c++/30297: | |
3251 | * tree.c (decl_linkage): Fields have no linkage. | |
3252 | ||
8208d7dc DJ |
3253 | 2007-11-08 Daniel Jacobowitz <dan@codesourcery.com> |
3254 | ||
3255 | * class.c (build_ctor_vtbl_group): Lay out the new type and decl. | |
3256 | ||
e4fd5b87 DG |
3257 | 2007-11-07 Douglas Gregor <doug.gregor@gmail.com> |
3258 | ||
3259 | PR c++/33045 | |
3260 | PR c++/33837 | |
3261 | PR c++/33838 | |
3262 | * semantics.c (finish_decltype_type): See through INDIRECT_REFs. | |
3263 | Be careful with ERROR_MARK_NODEs. | |
3264 | * parser.c (cp_parser_check_access_in_redeclaration): Handle NULL | |
3265 | argument. | |
3266 | ||
2811f33d JJ |
3267 | 2007-11-07 Jakub Jelinek <jakub@redhat.com> |
3268 | ||
3269 | PR c++/33501 | |
3270 | * call.c (build_over_call): Don't check TREE_ADDRESSABLE | |
3271 | on incomplete type. | |
3272 | ||
9ae165a0 DG |
3273 | 2007-11-06 Douglas Gregor <doug.gregor@gmail.com> |
3274 | ||
3275 | PR c++/33977 | |
3276 | PR c++/33886 | |
3277 | * tree.c (c_build_qualified_type): Define bridge to | |
3278 | cp_build_qualified_type. | |
3279 | ||
1ad8aeeb DG |
3280 | 2007-11-06 Douglas Gregor <doug.gregor@gmail.com> |
3281 | ||
3282 | PR c++/31439 | |
3283 | PR c++/32114 | |
3284 | PR c++/32115 | |
3285 | PR c++/32125 | |
3286 | PR c++/32126 | |
3287 | PR c++/32127 | |
3288 | PR c++/32128 | |
3289 | PR c++/32253 | |
3290 | PR c++/32566 | |
3291 | * typeck.c (check_return_expr): Pass address of retval to | |
3292 | check_for_bare_parameter_packs. | |
3293 | * class.c (build_base_field): Tolerate bases that have no layout | |
3294 | due to errors. | |
3295 | (end_of_base): Ditto. | |
3296 | * tree.c (canonical_type_variant): Be careful with | |
3297 | ERROR_MARK_NODE. | |
3298 | * cp-tree.h (check_for_bare_parameter_packs): Now accepts a | |
3299 | tree*. | |
3300 | * pt.c (find_parameter_pack_data): Add set_packs_to_error field, | |
3301 | which states whether parameter packs should be replaced with | |
3302 | ERROR_MARK_NODE. | |
3303 | (find_parameter_packs_r): Pass addresses to cp_walk_tree wherever | |
3304 | possible. If set_packs_to_error is set true, replace the parameter | |
3305 | pack with ERROR_MARK_NODE. Manage our own pointer sets. | |
3306 | (uses_parameter_packs): Don't set parameter packs to | |
3307 | ERROR_MARK_NODE. | |
3308 | (check_for_bare_parameter_packs): Now takes a pointer to a tree, | |
3309 | which may be modified (if it is a parameter pack). Instructs | |
3310 | find_parameter_packs_r to replace parameter packs with | |
3311 | ERROR_MARK_NODE (so that they won't cause errors later on). | |
3312 | (process_template_parm): Pass pointer to | |
3313 | check_for_bare_parameter_packs. | |
3314 | (process_partial_specialization): Replace pack expansions before | |
3315 | the end of the template argument list with ERROR_MARK_NODE. | |
3316 | (push_template_decl_real): Pass pointer to | |
3317 | check_for_bare_parameter_packs. Replace parameter packs not at the | |
3318 | end of the template parameter list with ERROR_MARK_NODE. | |
3319 | (convert_template_argument): Be more careful about using DECL_NAME | |
3320 | on only declarations. | |
3321 | (unify): Can't unify against ERROR_MARK_NODE. | |
3322 | * semantics.c (finish_cond): Pass pointer to | |
3323 | check_for_bare_parameter_packs. | |
3324 | (finish_expr_stmt): Ditto. | |
3325 | (finish_for_expr): Ditto. | |
3326 | (finish_switch_cond): Pass pointer to | |
3327 | check_for_bare_parameter_packs, and call it before we put the | |
3328 | condition into the statement. | |
3329 | (finish_mem_initializers): Pass pointer to | |
3330 | check_for_bare_parameter_packs. | |
3331 | (finish_member_declaration): Ditto. | |
3332 | * parser.c (cp_parser_base_clause): Ditto. | |
056dd1af | 3333 | |
239371f9 JJ |
3334 | 2007-11-06 Jakub Jelinek <jakub@redhat.com> |
3335 | ||
b0eb6a8f JJ |
3336 | PR target/33168 |
3337 | * decl.c (cp_finish_decl): Call make_rtl_for_nonlocal_decl already | |
3338 | with the final TREE_READONLY flag in place. processing_template_decl | |
3339 | is known to be 0 in this part of function. | |
3340 | ||
239371f9 JJ |
3341 | PR c++/33894 |
3342 | * cp-tree.h: Update comment - TYPE_LANG_FLAG_0 is not | |
3343 | OMP_ATOMIC_DEPENDENT_P in OMP_ATOMIC. | |
3344 | * pt.c (tsubst_expr): Assert OMP_ATOMIC_DEPENDENT_P. | |
3345 | * semantics.c (finish_omp_atomic): Revert most of the | |
3346 | 2007-02-05 changes, just keep the new representation of | |
3347 | OMP_ATOMIC_DEPENDENT_P OMP_ATOMIC. | |
3348 | ||
565603f8 L |
3349 | 2007-11-05 H.J. Lu <hongjiu.lu@intel.com> |
3350 | ||
3351 | PR c++/33871 | |
3352 | * decl2.c (constrain_visibility): Clear DECL_ONE_ONLY if marked | |
3353 | local. | |
3354 | ||
86089be5 DG |
3355 | 2007-11-05 Douglas Gregor <doug.gregor@gmail.com> |
3356 | ||
3357 | PR c++/33996 | |
3358 | PR c++/33235 | |
3359 | PR c++/33930 | |
3360 | * typeck.c (merge_types): Don't lose rvalue references when | |
3361 | merging types. | |
3362 | * call.c (build_over_call): Don't elide move constructors just | |
3363 | because the copy constructor is trivial (!). | |
3364 | (compare_ics): If comparing cv-qualifiers fails, we can still order | |
3365 | based on binding lvalues vs. rvalues. | |
3366 | ||
2afad0f6 DG |
3367 | 2007-11-05 Douglas Gregor <doug.gregor@gmail.com> |
3368 | ||
3369 | PR c++/33939 | |
3370 | * pt.c (unify_pack_expansion): bring handling of function call | |
056dd1af | 3371 | arguments into line with type_unification_real. |
2afad0f6 | 3372 | |
278b63df MLI |
3373 | 2007-11-05 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
3374 | ||
3375 | * typeck.c (build_binary_op): Use pedwarn instead of error for | |
3376 | consistency. | |
3377 | ||
1b021ff4 JJ |
3378 | 2007-11-05 Jakub Jelinek <jakub@redhat.com> |
3379 | ||
f370e66b JJ |
3380 | PR c++/33836 |
3381 | * parser.c (cp_parser_unary_expression): For &&label call | |
3382 | cp_parser_non_integral_constant_expression and return error_mark_node | |
3383 | if it returned true. | |
3384 | ||
1b021ff4 JJ |
3385 | PR c++/33969 |
3386 | * decl.c (grokdeclarator): Don't call build_memfn_type if type | |
3387 | is neither FUNCTION_TYPE nor METHOD_TYPE. | |
3388 | ||
eba5fc70 JJ |
3389 | 2007-11-02 Jakub Jelinek <jakub@redhat.com> |
3390 | ||
3391 | PR c++/33516 | |
3392 | * parser.c (cp_parser_nested_name_specifier_opt): Use | |
3393 | TYPE_MAIN_VARIANT (new_scope) as scope if new_scope is an incomplete | |
3394 | typedef of currently open class. | |
3395 | ||
10a6624a PC |
3396 | 2007-11-02 Paolo Carlini <pcarlini@suse.de> |
3397 | ||
3398 | PR c++/33495 | |
3399 | * error.c (dump_expr): Deal specially with statements. | |
3400 | ||
ef3b7b17 JM |
3401 | 2007-11-01 Jason Merrill <jason@redhat.com> |
3402 | ||
3403 | PR c++/30897 | |
3404 | * pt.c (push_template_decl_real): Set DECL_CONTEXT on template | |
3405 | template parms. | |
3406 | (lookup_template_class): Use it to get the outer template args | |
3407 | for instantiating one. | |
3408 | ||
3409 | PR c++/29236 | |
3410 | * pt.c (reduce_template_parm_level): tsubst the parameters | |
3411 | of a template template parm. | |
3412 | ||
e1a18c68 DG |
3413 | 2007-11-01 Douglas Gregor <doug.gregor@gmail.com> |
3414 | ||
3415 | PR c++/33955 | |
3416 | * pt.c (find_parameter_packs_r): Handle TYPENAME_TYPE. | |
3417 | ||
3a44f395 JJ |
3418 | 2007-11-01 Jakub Jelinek <jakub@redhat.com> |
3419 | ||
e426bd2c JJ |
3420 | PR c++/32384 |
3421 | * parser.c (cp_parser_postfix_dot_deref_expression): If | |
3422 | POSTFIX_EXPRESSION is type dependent, try to parse it as pseudo dtor | |
3423 | first and if that succeeds and type is SCALAR_TYPE_P, create | |
3424 | PSEUDO_DTOR_EXPR. | |
3425 | ||
3a44f395 JJ |
3426 | PR c++/32260 |
3427 | * rtti.c (enum_tinfo_kind): Fix TK_TYPE_INFO_TYPE comment. | |
3428 | (typeid_ok_p): Use the same alias set for abi::__type_info_pseudo | |
3429 | as for std::type_info. | |
3430 | ||
066f956c PC |
3431 | 2007-10-31 Paolo Carlini <pcarlini@suse.de> |
3432 | ||
3433 | PR c++/33494 | |
3434 | * cxx-pretty-print.c (pp_cxx_typeid_expression, | |
3435 | pp_cxx_delete_expression): Change to static linkage. | |
3436 | * cxx-pretty-print.h: Adjust declarations. | |
3437 | * error.c (dump_expr, case EXPR_PACK_EXPANSION, TYPEID_EXPR, | |
3438 | MEMBER_REF, DOTSTAR_EXPR, DELETE_EXPR, VEC_DELETE_EXPR, | |
3439 | MODOP_EXPR): Forward to pp_expression. | |
3440 | ||
3441 | * cxx-pretty-print.c (pp_cxx_expression, case NON_DEPENDENT_EXPR): | |
3442 | Fix typo. | |
3443 | ||
0e95aec1 | 3444 | 2007-10-31 Christian Bruel <christian.bruel@st.com> |
056dd1af | 3445 | Mark Mitchell <mark@codesourcery.com> |
0e95aec1 CB |
3446 | |
3447 | PR c++/19531 | |
ef3b7b17 | 3448 | * typeck.c (check_return_expr): Don't set named_return_value_okay_p |
056dd1af L |
3449 | if retval is volatile. |
3450 | ||
4c38e99e JJ |
3451 | 2007-10-30 Jakub Jelinek <jakub@redhat.com> |
3452 | ||
3453 | PR c++/33616 | |
3454 | * decl2.c (build_offset_ref_call_from_tree): Call | |
3455 | build_non_dependent_expr on object prior to building ADDR_EXPR from it | |
3456 | if FN is DOTSTAR_EXPR. | |
3457 | ||
88b82314 DG |
3458 | 2007-10-30 Douglas Gregor <doug.gregor@gmail.com> |
3459 | ||
3460 | PR c++/31993 | |
3461 | PR c++/32252 | |
3462 | * pt.c (find_parameter_packs_r): Fix typo in comment. | |
3463 | (convert_template_argument): Look at the pattern of a pack | |
3464 | expansion to determine what kind of entity we're converting. | |
3465 | (coerce_template_parameter_pack): When we have coerced a non-type | |
3466 | template parameter pack, substitute into the type of that pack. | |
3467 | (tsubst_pack_expansion): When our substitution of a parameter pack | |
3468 | is a "trivial" substitution of itself, just substitute into the | |
3469 | pack expansion rather than actually expanding. | |
3470 | ||
e7df0180 JJ |
3471 | 2007-10-29 Jakub Jelinek <jakub@redhat.com> |
3472 | ||
3473 | PR c++/33841 | |
3474 | * class.c (check_bitfield_decl): Don't set field's type to error_mark_node | |
3475 | for non-integral type bitfields. Return true if bitfield is correct, false | |
3476 | error has been diagnosed. | |
3477 | (check_field_decls): If check_bitfield_decl returned false, call also | |
3478 | check_field_decl. | |
3479 | ||
8259e4f5 PC |
3480 | 2007-10-28 Paolo Carlini <pcarlini@suse.de> |
3481 | Mark Mitchell <mark@codesourcery.com> | |
3482 | ||
3483 | PR c++/30659 | |
3484 | * pt.c (do_decl_instantiation): If the VAR_DECL is not a | |
3485 | class member error out and return. | |
3486 | ||
1e3eacc7 JJ |
3487 | 2007-10-27 Jakub Jelinek <jakub@redhat.com> |
3488 | ||
d5aa2cf0 JJ |
3489 | * error.c (reinit_cxx_pp): Initialize cxx_pp->enclosing_scope |
3490 | to current_function_decl rather than 0. | |
3491 | ||
1e3eacc7 JJ |
3492 | PR c++/33844 |
3493 | * cxx-pretty-print.c (pp_cxx_pm_expression) <case MEMBER_REF>: Print | |
3494 | ->* rather than .*. | |
3495 | * error.c (dump_expr): Handle MEMBER_REF and DOTSTAR_EXPR. | |
3496 | ||
d02dbde6 JM |
3497 | 2007-10-27 Jason Merrill <jason@redhat.com> |
3498 | ||
3499 | PR c++/5247 | |
3500 | * call.c (convert_default_arg): Detect recursion. | |
3501 | ||
094a5fe2 JJ |
3502 | 2007-10-27 Jakub Jelinek <jakub@redhat.com> |
3503 | ||
3504 | PR c++/33842 | |
3505 | * cxx-pretty-print.h (pp_cxx_offsetof_expression): New prototype. | |
3506 | * cxx-pretty-print.c (pp_cxx_primary_expression): Handle | |
3507 | OFFSETOF_EXPR. | |
3508 | (pp_cxx_offsetof_expression_1, pp_cxx_offsetof_expression): New | |
3509 | functions. | |
3510 | * error.c (dump_expr): Handle OFFSETOF_EXPR. | |
3511 | ||
91a77d68 JM |
3512 | 2007-10-26 Jason Merrill <jason@redhat.com> |
3513 | ||
3514 | PR c++/24791 | |
3515 | * pt.c (get_template_info): New fn. | |
3516 | (template_class_depth): Use it. | |
056dd1af | 3517 | (push_template_decl_real): Check that the template args of the |
91a77d68 JM |
3518 | definition match the args of the previous declaration. |
3519 | ||
07021f8c PC |
3520 | 2007-10-26 Paolo Carlini <pcarlini@suse.de> |
3521 | ||
3522 | PR c++/31988 | |
3523 | * decl2.c (coerce_new_type): Do not allow a default argument for | |
3524 | the first parameter. | |
3525 | ||
2b536806 DG |
3526 | 2007-10-26 Douglas Gregor <doug.gregor@gmail.com> |
3527 | ||
3528 | PR c++/33839 | |
3529 | * parser.c (cp_parser_decltype): Return ERROR_MARK_NODE if we | |
3530 | don't see the leading '('. Only lookup names if we get an | |
3531 | IDENTIFIER_NODE. | |
3532 | ||
0f1e3321 JJ |
3533 | 2007-10-26 Jakub Jelinek <jakub@redhat.com> |
3534 | ||
3535 | PR c++/33744 | |
3536 | * parser.c (cp_parser_parenthesized_expression_list): Set | |
3537 | greater_than_is_operator_p to true in between the parens. | |
3538 | ||
9b70c6b0 PC |
3539 | 2007-10-26 Paolo Carlini <pcarlini@suse.de> |
3540 | ||
3541 | PR c++/31747 | |
3542 | * decl.c (grokdeclarator): In case of conflicting specifiers | |
3543 | just return error_mark_node. | |
3544 | ||
3459ca23 OW |
3545 | 2007-10-26 Ollie Wild <aaw@google.com> |
3546 | ||
3547 | * expr.c (cxx_expand_expr): Removed. | |
3548 | * cp-tree.h (exx_expand_expr): Removed. | |
3549 | * cp-objcp-common.h (LANK_HOOKS_EXPAND_EXPR): Replace cxx_expand_expr | |
3550 | with c_expand_expr. | |
3551 | ||
6735e374 PC |
3552 | 2007-10-25 Paolo Carlini <pcarlini@suse.de> |
3553 | ||
3554 | PR c++/33843 | |
3555 | * cxx-pretty-print.c (pp_cxx_unqualified_id): Deal with BIT_NOT_EXPR. | |
3556 | ||
6f4fd536 JM |
3557 | 2007-10-23 Jason Merrill <jason@redhat.com> |
3558 | ||
3559 | PR c++/25950 (DR 391) | |
3560 | * call.c (struct conversion): Remove check_copy_constructor_p. | |
056dd1af L |
3561 | (reference_binding): Always bind a reference directly to a |
3562 | compatible class rvalue. Pass down LOOKUP_NO_TEMP_BIND during | |
6f4fd536 JM |
3563 | temporary creation. |
3564 | (check_constructor_callable): Remove. | |
3565 | (convert_like_real): Don't call it. | |
3566 | (initialize_reference): Don't call check_constructor_callable. | |
3567 | (standard_conversion): Check LOOKUP_NO_CONVERSION instead of | |
3568 | LOOKUP_CONSTRUCTOR_CALLABLE. Don't require a temporary for base | |
3569 | conversions if LOOKUP_NO_TEMP_BIND. | |
3570 | (implicit_conversion): Pass through LOOKUP_NO_TEMP_BIND. | |
3571 | (build_user_type_conversion_1): Pass through LOOKUP_NO_TEMP_BIND for | |
3572 | second conversion. | |
3573 | * cp-tree.h (LOOKUP_CONSTRUCTOR_CALLABLE): Remove. | |
3574 | ||
6e684eee JJ |
3575 | 2007-10-22 Jakub Jelinek <jakub@redhat.com> |
3576 | ||
3577 | PR c++/33372 | |
3578 | * semantics.c (finish_omp_clauses): Check !type_dependent_expression_p | |
3579 | before checking if its type is integral. | |
3580 | ||
5818c8e4 JM |
3581 | 2007-10-22 Jason Merrill <jason@redhat.com> |
3582 | ||
3583 | PR c++/33620 | |
3584 | * class.c (finish_struct_bits): Copy TYPE_ATTRIBUTES. | |
3585 | * pt.c (apply_late_template_attributes): Splice out dependent | |
3586 | attributes from DECL_ATTRIBUTES. | |
3587 | ||
3588 | * decl.c (cxx_maybe_build_cleanup): Use build_address. | |
3589 | ||
c5409249 MLI |
3590 | 2007-10-17 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
3591 | ||
3592 | * typeck.c (build_binary_op) : Use appropriate warning option | |
3593 | instead of unnamed warning. | |
3594 | ||
bf98d3b6 PC |
3595 | 2007-10-16 Paolo Carlini <pcarlini@suse.de> |
3596 | ||
3597 | PR c++/31446 | |
3598 | * pt.c (current_template_args): Do not change TREE_LIST elements | |
3599 | with a TREE_VALUE of error_mark_node. | |
3600 | ||
15896502 MM |
3601 | 2007-10-16 Mark Mitchell <mark@codesourcery.com> |
3602 | ||
3603 | * typeck.c (cp_apply_type_quals_to_decl): Expand documentation. | |
3604 | * decl.c (start_decl): Tidy. | |
3605 | (start_decl_1): Call cp_apply_type_quals_to_decl after completing | |
3606 | the type. | |
3607 | (grokdeclarator): Clarify comment. | |
3608 | ||
db160137 AP |
3609 | 2007-10-14 Andrew Pinski <pinskia@gmail.com> |
3610 | ||
3611 | PR c++/30303 | |
3612 | * decl.c (grokfndecl): Return NULL after the "definition of | |
3613 | implicitly-declared" error happened. | |
3614 | ||
a9a81e7d SM |
3615 | 2007-10-12 Simon Martin <simartin@users.sourceforge.net> |
3616 | ||
3617 | PR c++/26698 | |
3618 | * call.c (build_user_type_conversion_1): Do not consider conversion | |
3619 | functions to convert a (possibly cv-qualified) object to the (possibly | |
3620 | cv-qualified) same object type (or a reference to it), to a (possibly | |
3621 | cv-qualified) base class of that type (or a reference to it). | |
3622 | ||
f4205442 PC |
3623 | 2007-10-12 Paolo Carlini <pcarlini@suse.de> |
3624 | ||
3625 | * pt.c (tsubst): Use template_parm_level_and_index. | |
3626 | ||
3d3585eb JJ |
3627 | 2007-10-12 Jakub Jelinek <jakub@redhat.com> |
3628 | ||
3629 | PR c++/32121 | |
3630 | * parser.c (cp_parser_compound_statement): Handle label-declarations | |
3631 | at the beginning of the compound statement. | |
3632 | (cp_parser_block_declaration): Issue diagnostics about __label__ | |
3633 | not at the beginning of a block. | |
3634 | ||
c343d5a7 PC |
3635 | 2007-10-11 Paolo Carlini <pcarlini@suse.de> |
3636 | ||
3637 | PR c++/33461 | |
3638 | * pt.c (coerce_template_parameter_pack): Do not pass error_mark_node | |
3639 | to convert_template_argument. | |
3640 | (coerce_template_parms): Return error_mark_node after fixed-length | |
3641 | error. | |
3642 | (tsubst_decl): Check for error_mark_node the return value of the | |
3643 | first tsubst in 'case VAR_DECL'. | |
3644 | ||
6524147c OW |
3645 | 2007-10-08 Ollie Wild <aaw@google.com> |
3646 | ||
3647 | * typeck2.c (digest_init): Call cplus_expand_constant after | |
3648 | convert_for_initialization. | |
3649 | * cp-objcp-common.h (LANG_HOOKS_EXPAND_CONSTANT): Removed. | |
3650 | * expr.c (cplus_expand_constant): Updated function description. | |
3651 | ||
42f02385 JM |
3652 | 2007-10-04 Jason Merrill <jason@redhat.com> |
3653 | ||
3654 | PR c++/20416 | |
3655 | * call.c (initialize_reference): Handle local static reference | |
3656 | temps properly. | |
3657 | ||
231d0665 JM |
3658 | 2007-10-03 Jason Merrill <jason@redhat.com> |
3659 | ||
65567efa JM |
3660 | PR c++/32470 |
3661 | * name-lookup.c (push_namespace_with_attrs): Fold back into... | |
3662 | (push_namespace): Here. | |
3663 | (handle_namespace_attrs): New fn for the attr code. | |
3664 | (leave_scope): Don't pop_visibility. | |
3665 | * name-lookup.h (struct cp_binding_level): Remove has_visibility. | |
3666 | * parser.c (cp_parser_namespace_definition): Call | |
056dd1af | 3667 | handle_namespace_attrs and pop_visibility as appropriate. |
65567efa | 3668 | |
231d0665 JM |
3669 | PR c++/11756 |
3670 | * mangle.c (write_type) [TYPEOF_TYPE]: Just sorry. | |
3671 | ||
fea10e36 AO |
3672 | 2007-10-03 Alexandre Oliva <aoliva@redhat.com> |
3673 | ||
3674 | * decl.c (duplicate_decls): Preserve linkage flags for mere | |
3675 | redeclarations of gnu_inline definitions. | |
3676 | ||
a24549d4 JM |
3677 | 2007-10-03 Jason Merrill <jason@redhat.com> |
3678 | ||
3679 | PR c++/15764 | |
3680 | * decl.c (wrap_cleanups_r): New fn. | |
3681 | (wrap_temporary_cleanups): New fn. | |
3682 | (initialize_local_var): Call it. | |
3683 | ||
dc472c59 JM |
3684 | 2007-09-29 Jason Merrill <jason@redhat.com> |
3685 | ||
3686 | PR c++/33094 | |
056dd1af | 3687 | * decl.c (make_rtl_for_nonlocal_decl): It's ok for a member |
dc472c59 JM |
3688 | constant to not have DECL_EXTERNAL if it's file-local. |
3689 | ||
6dcee2d6 OW |
3690 | 2007-09-28 Ollie Wild <aaw@google.com> |
3691 | ||
3692 | Revert | |
3693 | 2007-09-27 Ollie Wild <aaw@google.com> | |
3694 | ||
3695 | * typeck2.c (digest_init): Call cplus_expand_constant after | |
3696 | convert_for_initialization. | |
3697 | * cp-objcp-common.h (LANG_HOOKS_EXPAND_CONSTANT): Removed. | |
3698 | * expr.c (cplus_expand_constant): Updated function description. | |
3699 | ||
d9d9dbc0 JM |
3700 | 2007-09-28 Jason Merrill <jason@redhat.com> |
3701 | ||
3702 | PR c++/10179 | |
3703 | * class.c (layout_empty_base): Take rli parameter, update | |
3704 | rli->record_align if empty base has user-specified alignment. | |
3705 | (build_base_field): Pass rli to it. | |
3706 | ||
930a1e63 PC |
3707 | 2007-09-28 Paolo Carlini <pcarlini@suse.de> |
3708 | ||
3709 | PR c++/33213 | |
3710 | * error.c (dump_decl): Deal with TYPE_PACK_EXPANSION. | |
3711 | ||
31d40008 PC |
3712 | 2007-09-28 Paolo Carlini <pcarlini@suse.de> |
3713 | ||
3714 | PR c++/33118 | |
3715 | * error.c (dump_expr): Deal with ARGUMENT_PACK_SELECT. | |
3716 | (dump_type): Use dump_template_argument for TYPE_ARGUMENT_PACK. | |
3717 | (dump_parameters): Just call dump_type for argument packs too. | |
3718 | ||
80d86013 JJ |
3719 | 2007-09-28 Jakub Jelinek <jakub@redhat.com> |
3720 | ||
3721 | PR c++/31434 | |
3722 | * tree.c (cp_build_qualified_type_real): Handle TYPE_PACK_EXPANSION | |
3723 | qualification by creating qualified PACK_EXPANSION_PATTERN and | |
3724 | then calling make_pack_expansion on it. | |
3725 | ||
12487dd0 OW |
3726 | 2007-09-27 Ollie Wild <aaw@google.com> |
3727 | ||
3728 | * typeck2.c (digest_init): Call cplus_expand_constant after | |
3729 | convert_for_initialization. | |
3730 | * cp-objcp-common.h (LANG_HOOKS_EXPAND_CONSTANT): Removed. | |
3731 | * expr.c (cplus_expand_constant): Updated function description. | |
3732 | ||
533007c1 JM |
3733 | 2007-09-27 Jason Merrill <jason@redhat.com> |
3734 | ||
d9d9dbc0 | 3735 | PR c++/33571 |
533007c1 JM |
3736 | * decl2.c (is_late_template_attribute): Don't crash on unknown |
3737 | attribute. | |
3738 | ||
62081704 PC |
3739 | 2007-09-27 Paolo Carlini <pcarlini@suse.de> |
3740 | ||
3741 | PR c++/33493 | |
3742 | * error.c (dump_expr): Deal with DELETE_EXPR and VEC_DELETE_EXPR. | |
3743 | * cxx-pretty-print.c (pp_cxx_delete_expression): Add missing | |
3744 | spaces in the formatting. | |
3745 | * cxx-pretty-print.h (pp_cxx_delete_expression): Declare. | |
3746 | ||
c94ed7a1 JJ |
3747 | 2007-09-27 Jakub Jelinek <jakub@redhat.com> |
3748 | ||
3749 | * error.c (cxx_print_error_function): Add third argument, pass | |
3750 | it over to lhd_print_error_function. | |
3751 | (cp_print_error_function): If diagnostic->abstract_origin, print | |
3752 | virtual backtrace. | |
3753 | * cp-tree.h (struct diagnostic_info): New forward decl. | |
3754 | (cxx_print_error_function): Add third argument. | |
3755 | ||
dc3ca06f SM |
3756 | 2007-09-25 Simon Martin <simartin@users.sourceforge.net> |
3757 | ||
3758 | PR c++/33207 | |
3759 | * name-lookup.c (pushtag): Do not create an implicit typedef before | |
3760 | the associated type declaration is known to be valid. | |
3761 | ||
1bde0042 JJ |
3762 | 2007-09-25 Jakub Jelinek <jakub@redhat.com> |
3763 | ||
3764 | * tree.c (cxx_printable_name): Compare FUNCTION_DECL uids | |
3765 | rather than pointers. | |
3766 | ||
18ff3013 DS |
3767 | 2007-09-24 Danny Smith <dannysmith@user.sourceforge.net> |
3768 | ||
3769 | PR c++/14688 | |
056dd1af | 3770 | * search.c (check_final_overrider): Fail if |
18ff3013 DS |
3771 | targetm.comp_type_attributes returns 0. |
3772 | ||
7a20d689 JM |
3773 | 2007-09-24 Jason Merrill <jason@redhat.com> |
3774 | ||
3775 | PR c++/33239 | |
3776 | * pt.c (resolve_typename_type): Don't look things up in the original | |
056dd1af | 3777 | template if it would mean losing template arguments. |
7a20d689 | 3778 | |
2dff8956 JJ |
3779 | 2007-09-24 Jakub Jelinek <jakub@redhat.com> |
3780 | ||
3781 | PR c++/33506 | |
3782 | * cp-tree.h (cxx_type_hash_eq): New prototype. | |
3783 | * cp-objcp-common.h (LANG_HOOKS_TYPE_HASH_EQ): Redefine. | |
3784 | * tree.c (cxx_type_hash_eq): New function. | |
3785 | ||
c946ce8b DG |
3786 | 2007-09-24 Douglas Gregor <doug.gregor@gmail.com> |
3787 | ||
056dd1af | 3788 | PR c++/33185 |
c946ce8b DG |
3789 | * tree.c (cp_build_qualified_type_real): Build a canonical |
3790 | ARRAY_TYPE if the original ARRAY_TYPE was not a canonical type. | |
056dd1af | 3791 | |
714f2304 DG |
3792 | 2007-09-24 Douglas Gregor <doug.gregor@gmail.com> |
3793 | ||
3794 | PR c++/33112 | |
056dd1af | 3795 | PR c++/33185 |
714f2304 DG |
3796 | * tree.c (cplus_array_compare): Compare pointers, not types. |
3797 | (build_cplus_array_type_1): Store new array type into the hash | |
3798 | table before building the canonical type; build the canonical type | |
3799 | correctly. | |
3800 | (cp_build_qualified_type_real): Put all of the array types with | |
056dd1af | 3801 | cv-qualified element types into the C++ array hash table, built as |
714f2304 | 3802 | variants of the unqualified versions. |
056dd1af | 3803 | |
823dd937 JM |
3804 | 2007-09-23 Jason Merrill <jason@redhat.com> |
3805 | ||
3806 | PR c++/16370 | |
3807 | * decl.c (grokdeclarator): Look through implicit TYPE_DECLs | |
3808 | for deprecation warnings. | |
3809 | ||
a7f6bc8c JM |
3810 | 2007-09-22 Jason Merrill <jason@redhat.com> |
3811 | ||
1a68a4e8 JM |
3812 | PR c++/15269 |
3813 | * call.c (build_over_call): Warn about deprecated virtuals. | |
3814 | ||
a7f6bc8c JM |
3815 | PR c++/19407 |
3816 | * cp-tree.h (ATTR_IS_DEPENDENT): New macro. | |
3817 | (MAYBE_TAGGED_TYPE_P): Remove. | |
3818 | * pt.c (apply_late_template_attributes): Check ATTR_IS_DEPENDENT | |
3819 | instead of calling is_late_template_attribute again. | |
3820 | (tsubst_decl) [TYPE_DECL]: Just check if the name is the tag. | |
3821 | (tsubst): A typedef is a TYPE_NAME != TYPE_MAIN_DECL. | |
3822 | Don't crash on typedefs from non-template classes. | |
3823 | * decl2.c (grokfield): Don't sorry about attrs on template parms. | |
3824 | (is_late_template_attribute): All attributes applied to template | |
3825 | parms or typename types are dependent. Static. | |
3826 | (splice_template_attributes): Pass decl through. | |
3827 | (save_template_attributes): Likewise. | |
3828 | ||
b6efedac JJ |
3829 | 2007-09-20 Jakub Jelinek <jakub@redhat.com> |
3830 | ||
3831 | PR c++/33496 | |
3832 | * pt.c (tsubst_copy) <case SIZEOF_EXPR>: Handle error_mark_node | |
3833 | returned from tsubst_pack_expansion. | |
3834 | (tsubst_copy_and_build) <case SIZEOF_EXPR>: Likewise. | |
3835 | (tsubst_copy_and_build) <case CONSTRUCTOR>: Likewise. | |
3836 | ||
24f58e74 PC |
3837 | 2007-09-20 Paolo Carlini <pcarlini@suse.de> |
3838 | ||
3839 | PR c++/33460 | |
3840 | * semantics.c (finish_id_expression): Use consistently | |
3841 | context_for_name_lookup. | |
3842 | * decl.c (fixup_anonymous_aggr): Fix error message for | |
3843 | anonymous struct (vs union). | |
3844 | ||
56d0c6e3 JM |
3845 | 2007-09-19 Jason Merrill <jason@redhat.com> |
3846 | ||
3847 | PR c++/7586 | |
3848 | * pt.c (tsubst): Handle typedefs by looking for the specialization. | |
056dd1af | 3849 | (retrieve_specialization): Only tagged types use |
56d0c6e3 JM |
3850 | DECL_TEMPLATE_INSTANTIATIONS. |
3851 | (instantiate_class_template): Push nested classes too. | |
3852 | (tsubst_decl) [TYPE_DECL]: Only check for canonical decl for | |
3853 | tagged types. | |
3854 | * cp-tree.h (MAYBE_TAGGED_TYPE_P): New macro. | |
3855 | * init.c (is_aggr_type): Remove redundant tests. | |
3856 | * class.c (push_nested_class): Use CLASS_TYPE_P. | |
3857 | ||
b43d1bde PC |
3858 | 2007-09-20 Paolo Carlini <pcarlini@suse.de> |
3859 | ||
3860 | PR c++/33459 | |
3861 | * init.c (build_zero_init): If, recursively, build_zero_init | |
3862 | returns a NULL_TREE, do not append it to the VEC of constructors. | |
3863 | ||
5044ab0e JM |
3864 | 2007-09-18 Jason Merrill <jason@redhat.com> |
3865 | ||
3866 | PR c++/17743 | |
3867 | * pt.c (apply_late_template_attributes): Set processing_template_decl. | |
3868 | (tsubst_decl) [TYPE_DECL]: Preserve naming typedef, pass | |
3869 | ATTR_FLAG_TYPE_IN_PLACE. | |
3870 | (tsubst): Do unqualified lookup to find typedefs from current class. | |
3871 | [ARRAY_TYPE]: Propagate alignment info. | |
3872 | * decl2.c (is_late_template_attribute): Only defer handling of | |
3873 | attribute aligned if the expression is dependent. | |
3874 | (save_template_attributes): If we're deferring any attributes, | |
3875 | make this a naming typedef. | |
3876 | ||
352d5090 PC |
3877 | 2007-09-18 Paolo Carlini <pcarlini@suse.de> |
3878 | ||
3879 | PR c++/33462 (again) | |
3880 | * cxx-pretty-print.c (pp_cxx_va_arg_expression): Print | |
3881 | va_arg instead of __builtin_va_arg. | |
3882 | ||
fdb8f418 PC |
3883 | 2007-09-18 Paolo Carlini <pcarlini@suse.de> |
3884 | ||
3885 | PR c++/33462 | |
3886 | * cxx-pretty-print.c (pp_cxx_va_arg_expression): Add. | |
3887 | (pp_cxx_primary_expression): Use it. | |
3888 | * cxx-pretty-print.h (pp_cxx_va_arg_expression): Declare. | |
3889 | * error.c (dump_expr): Use it. | |
3890 | ||
2d65b828 PC |
3891 | 2007-09-18 Paolo Carlini <pcarlini@suse.de> |
3892 | ||
3893 | PR c++/33463 | |
3894 | * cxx-pretty-print.c (pp_cxx_postfix_expression): Split | |
3895 | out case TYPEID_EXPR to... | |
3896 | (pp_cxx_typeid_expression): ... here; use pp_cxx_left_paren | |
3897 | and pp_cxx_right_paren. | |
3898 | * cxx-pretty-print.h (pp_cxx_typeid_expression): Declare. | |
3899 | * error.c (dump_expr): Use it. | |
3900 | ||
e74392f0 PC |
3901 | 2007-09-18 Paolo Carlini <pcarlini@suse.de> |
3902 | ||
3903 | PR c++/33464 | |
3904 | * cxx-pretty-print.c (pp_cxx_trait_expression): Add. | |
3905 | (pp_cxx_primary_expression): Use it. | |
3906 | * cxx-pretty-print.h (pp_cxx_trait_expression): Declare. | |
3907 | * error.c (dump_expr): Use it. | |
3908 | ||
57711cd1 PC |
3909 | 2007-09-16 Paolo Carlini <pcarlini@suse.de> |
3910 | ||
3911 | PR c++/33124 | |
3912 | * init.c (build_new): Remove warning for zero-element | |
3913 | allocations. | |
3914 | ||
0ee3f0a8 NS |
3915 | 2007-09-16 Nathan Sidwell <nathan@codesourcery.com> |
3916 | ||
0ee3f0a8 NS |
3917 | PR c++/32756 |
3918 | * call.c (maybe_handle_implicit_object): Set this_p, clear | |
3919 | rvaluedness_matches_p. | |
3920 | (compare_ics): Do not compare rvaluedness matching when one of the | |
3921 | operands is an implicit object. | |
3922 | ||
4f4141ff JM |
3923 | 2007-09-14 Jason Merrill <jason@redhat.com> |
3924 | ||
3925 | PR c++/17743, c++/19163 | |
3926 | * decl2.c (is_late_template_attribute): New fn. | |
3927 | (splice_template_attributes, save_template_attributes): New fns. | |
3928 | (cplus_decl_attributes): Call save_template_attributes. | |
3929 | * pt.c (apply_late_template_attributes): New fn. | |
3930 | (instantiate_class_template, tsubst_decl): Use it. | |
3931 | * cp-tree.h: Declare is_late_template_attribute. | |
3932 | ||
46c2514e TT |
3933 | 2007-09-13 Tom Tromey <tromey@redhat.com> |
3934 | ||
3935 | * parser.c (cp_lexer_new_main): Don't use | |
3936 | c_lex_return_raw_strings. | |
3937 | (cp_lexer_get_preprocessor_token): Update. Add special case when | |
3938 | lexer is NULL. | |
3939 | ||
e89d6010 JH |
3940 | 2007-09-11 Jan Hubicka <jh@suse.cz> |
3941 | ||
3942 | * method.c (use_thunk): Use tree_rest_of_compilation | |
3943 | * cp-objecp-common.h (LANG_HOOKS_CALLGRAPH_EXPAND_FUNCTION): Kill. | |
3944 | (LANG_HOOKS_CALLGRAPH_EMIT_ASSOCIATED_THUNKS): Define. | |
3945 | * cp-tree.h (expand_body): Kill. | |
3946 | (emit_associated_thunks): Declare. | |
3947 | * semantics.c (emit_associated_thunks): Export. | |
3948 | (expand_body): Kill. | |
3949 | ||
b2ec1738 DD |
3950 | 2007-09-09 David Daney <ddaney@avtrex.com> |
3951 | ||
3952 | PR c++/33324 | |
3953 | * init.c (build_new_1): Use POINTER_PLUS_EXPR instead of MINUS_EXPR | |
3954 | to calculate cookie_ptr. | |
3955 | ||
fd452cef JM |
3956 | 2007-09-08 Jason Merrill <jason@redhat.com> |
3957 | ||
3958 | PR c++/33342 | |
3959 | * pt.c (most_specialized_class): Set processing_template_decl | |
3960 | while tsubsting partial spec args. | |
3961 | ||
3fd40684 JM |
3962 | 2007-09-06 Jason Merrill <jason@redhat.com> |
3963 | ||
3964 | * decl2.c (get_guard): Copy visibility from the guarded variable. | |
3965 | ||
b2ea030b JH |
3966 | 2007-09-06 Jan Hubicka <jh@suse.cz> |
3967 | ||
3968 | * semantics.c (expand_body): Do not mark arguments of clones used. | |
3969 | ||
a125de0c PC |
3970 | 2007-09-06 Paolo Carlini <pcarlini@suse.de> |
3971 | ||
3972 | PR c++/32674 | |
3973 | * decl.c (cp_finish_decl): When processing_template_decl, | |
3974 | deal correctly with init as TREE_LIST. | |
3975 | ||
5ffeb913 TT |
3976 | 2007-09-06 Tom Tromey <tromey@redhat.com> |
3977 | ||
3978 | * decl.c (finish_function): Put return's location on line zero of | |
3979 | file. | |
3980 | ||
6f06d231 JM |
3981 | 2007-09-05 Jason Merrill <jason@redhat.com> |
3982 | ||
86ef5ebb JM |
3983 | PR c++/15745 |
3984 | * except.c (prepare_eh_type): Use type_decays_to. | |
3985 | ||
6f06d231 JM |
3986 | PR c++/15097 |
3987 | * init.c (build_delete): Use build_headof to get the address of the | |
3988 | complete object if we aren't using the deleting destructor. | |
3989 | * rtti.c (build_headof): No longer static. | |
3990 | * cp-tree.h: Declare it. | |
3991 | ||
62bedd31 JJ |
3992 | 2007-09-06 Jakub Jelinek <jakub@redhat.com> |
3993 | ||
3994 | * decl.c (duplicate_decls): Set TREE_NOTHROW on __builtin_XX | |
3995 | decl if a prototype for XX is provided with throw(). | |
3996 | ||
012c4da9 JJ |
3997 | PR c++/33289 |
3998 | * decl.c (builtin_function_1): Set DECL_ANTICIPATED also | |
3999 | on __*_chk non-__builtin_* decls. | |
4000 | ||
61fdc9d7 PC |
4001 | 2007-09-05 Paolo Carlini <pcarlini@suse.de> |
4002 | ||
4003 | PR c++/30302 | |
4004 | * semantics.c (finish_id_expression): Use context_for_name_lookup | |
4005 | insted of DECL_CONTEXT, to see through anonymous structs and unions. | |
4006 | * class.c (finish_struct_anon): Deal correctly with anonymous | |
4007 | structs (vs unions, as GNU extension) in error messages. | |
4008 | ||
33061862 JH |
4009 | 2007-09-05 Jan Hubicka <jh@suse.cz> |
4010 | ||
b97d8153 | 4011 | * sematics.c (expand_body): Remove unnecesary import_export_decl |
33061862 JH |
4012 | call, DECL_EXTERNAL checks and current_function_decl saving. |
4013 | ||
03ba2e11 PC |
4014 | 2007-09-05 Paolo Carlini <pcarlini@suse.de> |
4015 | ||
4016 | PR c++/29731 (again) | |
4017 | * parser.c (cp_parser_primary_expression): Return error_mark_node | |
4018 | when a statement-expression is found in a template-argument list. | |
4019 | ||
ba6c89a9 JM |
4020 | 2007-09-04 Jason Merrill <jason@redhat.com> |
4021 | ||
6f06d231 JM |
4022 | * except.c (initialize_handler_parm): Use |
4023 | fold_build_cleanup_point_expr. | |
4024 | ||
9380ed84 JM |
4025 | PR c++/31419 |
4026 | * call.c (reference_binding): Don't look for user-defined conversions | |
4027 | to the same type. | |
4028 | ||
ba6c89a9 JM |
4029 | PR c++/31411 |
4030 | * except.c (initialize_handler_parm): Put a CLEANUP_POINT_EXPR inside | |
4031 | the MUST_NOT_THROW_EXPR. | |
4032 | ||
4c5bae34 RS |
4033 | 2007-09-04 Richard Sandiford <richard@codesourcery.com> |
4034 | ||
4035 | * decl.c (cp_finish_decl): Call determine_visibility before | |
4036 | make_rtl_for_nonlocal_decl. | |
4037 | ||
dc28490d JM |
4038 | 2007-09-04 Jason Merrill <jason@redhat.com> |
4039 | ||
4040 | PR c++/14032 | |
4041 | * pt.c (most_specialized_class): Substitute outer template | |
4042 | arguments into the arguments of a member template partial | |
4043 | specialization. | |
4044 | (strip_innermost_template_args): New fn. | |
4045 | ||
72c65674 DJ |
4046 | 2007-09-03 Daniel Jacobowitz <dan@codesourcery.com> |
4047 | ||
4048 | * Make-lang.in (g++spec.o): Remove SHLIB_MULTILIB. | |
4049 | ||
b1d5455a KG |
4050 | 2007-09-03 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
4051 | ||
4052 | * call.c (name_as_c_string): Supply a TYPE for CONST_CAST. | |
4053 | * decl.c (cp_make_fname_decl): Likewise, | |
4054 | * parser.c (cp_parser_string_literal): Likewise, | |
4055 | * tree.c (pod_type_p, zero_init_p): Use CONST_CAST_TREE. | |
4056 | * typeck.c (cp_type_quals, cp_type_readonly, cp_has_mutable_p): | |
4057 | Likewise, | |
4058 | ||
8bcebc69 PC |
4059 | 2007-09-02 Paolo Carlini <pcarlini@suse.de> |
4060 | ||
4061 | PR c++/33208 | |
4062 | * typeck.c (build_unary_op): Fix error message for | |
4063 | Boolean expression as operand to operator--. | |
4064 | ||
75547801 KG |
4065 | 2007-09-01 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
4066 | ||
4067 | * tree.c (pod_type_p, zero_init_p): Use strip_array_types. | |
4068 | * typeck.c (cp_type_quals, cp_type_readonly, cp_has_mutable_p): | |
4069 | Likewise. | |
4070 | ||
268127ce DG |
4071 | 2007-08-31 Douglas Gregor <doug.gregor@gmail.com> |
4072 | ||
4073 | PR c++/32597 | |
4074 | * init.c (build_default_init): Make extern. | |
4075 | * cp-tree.h (build_default_init): Declare here. | |
4076 | * pt.c (tsubst_expr): When the instantiation of the initializer of | |
4077 | a variable results in an empty list, default-initialize the | |
4078 | variable. | |
4079 | (tsubst_copy_and_build): When the instantiation of the initializer | |
4080 | in a new expression results in an empty initializer list, | |
4081 | default-initialize it. | |
4082 | ||
1ab28be5 DG |
4083 | 2007-08-31 Douglas Gregor <doug.gregor@gmail.com> |
4084 | ||
4085 | * mangle.c (write_type): Change mangling of rvalue reference from | |
056dd1af | 4086 | `RR' to `O'. |
1ab28be5 | 4087 | |
194ee011 JJ |
4088 | 2007-08-31 Jakub Jelinek <jakub@redhat.com> |
4089 | ||
4090 | * decl.c (duplicate_decls): Remove duplicated line. | |
4091 | ||
c8c00613 PC |
4092 | 2007-08-31 Paolo Carlini <pcarlini@suse.de> |
4093 | ||
4094 | PR c++/33210 | |
4095 | * cxx-pretty-print.c (pp_cxx_unqualified_id): Deal with | |
4096 | BOUND_TEMPLATE_TEMPLATE_PARM. | |
4097 | ||
5973c743 PC |
4098 | 2007-08-31 Paolo Carlini <pcarlini@suse.de> |
4099 | ||
4100 | PR c++/32113 | |
4101 | * search.c (lookup_member): Check the name argument for | |
4102 | error_mark_node. | |
4103 | ||
a53bf42c PC |
4104 | 2007-08-31 Paolo Carlini <pcarlini@suse.de> |
4105 | ||
4106 | PR c++/33212 | |
4107 | * parser.c (cp_parser_trait_expr): Check rerurn value of | |
4108 | cp_parser_type_id. | |
4109 | ||
6e03b280 OW |
4110 | 2007-08-30 Ollie Wild <aaw@google.com> |
4111 | ||
4112 | * cvt.c (cp_convert_to_pointer): Remove force parameter. Call | |
4113 | convert_ptrmem for pointer to member conversions. | |
4114 | (convert_to_pointer_force): Update cp_convert_to_pointer call. | |
4115 | (ocp_convert): Update cp_convert_to_pointer call. | |
4116 | * typeck.c (convert_ptrmem): Add conditional for null pointers to | |
4117 | members. | |
4118 | (build_static_cast_1): Check can_convert for conversions in either | |
4119 | direction. | |
4120 | (get_delta_difference_1): New function. | |
4121 | (get_delta_difference): Refactor to call get_delta_difference_1. | |
4122 | ||
f86bfcab JJ |
4123 | 2007-08-30 Jakub Jelinek <jakub@redhat.com> |
4124 | ||
4125 | * decl.c (start_preparsed_function): Set | |
4126 | DECL_DISREGARD_INLINE_LIMITS for GNU_INLINE_P functions. | |
4127 | ||
0a8fc247 PC |
4128 | 2007-08-28 Paolo Carlini <pcarlini@suse.de> |
4129 | ||
4130 | PR c++/33209 | |
4131 | * error.c (dump_expr): Deal with TEMPLATE_TYPE_PARM and | |
4132 | BOUND_TEMPLATE_TEMPLATE_PARM. | |
4133 | ||
92d0af97 JJ |
4134 | 2007-08-28 Jakub Jelinek <jakub@redhat.com> |
4135 | ||
4136 | PR c++/32596 | |
4137 | PR c++/32400 | |
4138 | * pt.c (check_explicit_specialization): Set DECL_INTERFACE_KNOWN | |
4139 | and DECL_NOT_REALLY_EXTERN if tmpl_func is not public. | |
4140 | ||
c206a697 JM |
4141 | 2007-08-27 Jason Merrill <jason@redhat.com> |
4142 | ||
c2acde1e | 4143 | PR c++/29000 |
056dd1af | 4144 | * pt.c (build_non_dependent_expr, type_dependent_expression_p): |
c2acde1e JM |
4145 | Look inside STMT_EXPR. |
4146 | * semantics.c (stmt_expr_value_expr): New fn. | |
4147 | * cp-tree.h: Declare it. | |
4148 | ||
c206a697 JM |
4149 | PR c++/28558 |
4150 | * decl.c (groktypename): Ignore attributes applied to class type. | |
4151 | ||
c536a6a7 RG |
4152 | 2007-08-28 Richard Guenther <rguenther@suse.de> |
4153 | ||
4154 | * decl.c (duplicate_decls): Merge DECL_DISREGARD_INLINE_LIMITS. | |
4155 | ||
7368348c | 4156 | 2007-08-28 Gabriel Dos Reis <gdr@integrable-solutions.net> |
056dd1af | 4157 | |
7368348c GDR |
4158 | * error.c (dump_expr): Handle COMPLEX_CST. |
4159 | * cxx-pretty-print.c (pp_cxx_primary_expression): Likewise. | |
4160 | (pp_cxx_expression): Likewise. | |
4161 | ||
3a47c4e4 AO |
4162 | 2007-08-27 Alexandre Oliva <aoliva@redhat.com> |
4163 | ||
4164 | * decl.c (GNU_INLINE_P): New. | |
4165 | (duplicate_decls): Handle gnu_inline. Merge attributes and | |
4166 | some flags in overriding definitions. | |
4167 | (redeclaration_error_message): Handle gnu_inline. | |
4168 | (start_preparsed_function): Likewise. | |
4169 | ||
58f9752a KG |
4170 | 2007-08-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
4171 | ||
4172 | * call.c (sufficient_parms_p): Constify. | |
4173 | * class.c (same_signature_p): Likewise. | |
4174 | * cp-gimplify.c (is_invisiref_parm, | |
4175 | cxx_omp_privatize_by_reference): Likewise. | |
4176 | * cp-objcp-common.c (has_c_linkage): Likewise. | |
4177 | * cp-tree.h (NON_THUNK_FUNCTION_CHECK, THUNK_FUNCTION_CHECK, | |
4178 | sufficient_parms_p, same_signature_p, copy_fn_p, move_fn_p, | |
4179 | grok_ctor_properties, nothrow_libfn_p, skip_artificial_parms_for, | |
4180 | num_artificial_parms_for, comp_template_parms, | |
4181 | template_parameter_pack_p, any_dependent_template_arguments_p, | |
4182 | any_type_dependent_arguments_p, any_value_dependent_elements_p, | |
4183 | repo_export_class_p, cxx_omp_privatize_by_reference, pod_type_p, | |
4184 | zero_init_p, member_p, cp_lvalue_kind, | |
4185 | builtin_valid_in_constant_expr_p, decl_anon_ns_mem_p, | |
4186 | varargs_function_p, is_dummy_object, special_function_kind, | |
4187 | string_conv_p, type_unknown_p, comp_except_specs, compparms, | |
4188 | comp_cv_qualification, is_bitfield_expr_with_lowered_type, | |
4189 | unlowered_expr_type, ptr_reasonably_similar, cp_type_readonly, | |
4190 | cp_has_mutable_p, at_least_as_qualified_p, | |
4191 | invalid_nonstatic_memfn_p, lvalue_or_else, lvalue_p): Likewise. | |
4192 | * decl.c (copy_fn_p, move_fn_p, grok_ctor_properties): Likewise. | |
4193 | * except.c (nothrow_libfn_p): Likewise. | |
4194 | * method.c (skip_artificial_parms_for, num_artificial_parms_for): | |
4195 | Likewise. | |
4196 | * pt.c (comp_template_parms, template_parameter_pack_p, | |
4197 | any_type_dependent_arguments_p, any_value_dependent_elements_p, | |
4198 | any_dependent_template_arguments_p): Likewise. | |
4199 | * repo.c (repo_export_class_p): Likewise. | |
4200 | * semantics.c (anon_aggr_type_p): Likewise. | |
4201 | * tree.c (lvalue_p_1, real_lvalue_p, lvalue_p, | |
4202 | builtin_valid_in_constant_expr_p, decl_anon_ns_mem_p, | |
4203 | varargs_function_p, member_p, is_dummy_object, pod_type_p, | |
4204 | zero_init_p, special_function_p): Likewise. | |
4205 | * typeck.c (comp_array_types, type_unknown_p, comp_except_specs, | |
4206 | comp_array_types, at_least_as_qualified_p, comp_cv_qualification, | |
4207 | compparms, invalid_nonstatic_memfn_p, | |
4208 | is_bitfield_expr_with_lowered_type, unlowered_expr_type, | |
4209 | string_conv_p, ptr_reasonably_similar, cp_type_readonly, | |
4210 | cp_has_mutable_p, lvalue_or_else): Likewise. | |
4211 | ||
e2c3721c PB |
4212 | 2007-08-25 Paolo Bonzini <bonzini@gnu.org> |
4213 | ||
4214 | * decl.c (cp_tree_node_structure): Kill TINST_LEVEL case. | |
4215 | * cp-objcp-common.c (cp_tree_size): Ditto. | |
4216 | * tree.c (cp_walk_subtrees): Ditto | |
4217 | * cp-tree.def (TINST_LEVEL): Go away. | |
4218 | * cp-tree.h (struct tinst_level_s): Rename to struct tinst_level, | |
4219 | move together with other non-tree structs. | |
4220 | (enum cp_tree_node_structure_enum): Nuke TS_CP_TINST_LEVEL. | |
4221 | (union lang_tree_node): Eliminate tinst_level field. | |
4222 | (TINST_DECL, TINST_LOCATION, TINST_IN_SYSTEM_HEADER_P): Annihilate. | |
4223 | (current_instantiation, outermost_tinst_level): Return | |
4224 | a "struct tinst_level *". | |
4225 | ||
4226 | * error.c (print_instantiation_partial_context): Change second | |
4227 | parameter to a "struct tinst_level *". Replace accessor macros | |
4228 | with field access. | |
4229 | (print_instantiation_full_context): Likewise. | |
4230 | * lex.c (in_main_input_context): Likewise. | |
4231 | ||
4232 | * pt.c (struct pending_templates): New. | |
4233 | (pending_templates, last_pending_template): Use it as a type. | |
4234 | (current_tinst_level): Change typo to "struct tinst_level *" | |
4235 | (reopen_tinst_level): Accept "struct tinst_level *", return decl. | |
4236 | (add_pending_template): Construct a "struct pending_template". | |
4237 | Replace TINST_LEVEL accessor macros with field access. | |
4238 | (push_tinst_level): Likewise, using GGC_NEW instead of make_node. | |
4239 | (pop_tinst_level): Likewise. | |
4240 | (instantiate_pending_templates): Likewise. Factor common code used | |
4241 | when an instantiation has been done. | |
4242 | (outermost_tinst_level): Replace tree_last with loop. | |
4243 | (current_instantiation): Return a "struct tinst_level *". | |
4244 | ||
89bd2c03 OW |
4245 | 2007-08-24 Ollie Wild <aaw@google.com> |
4246 | ||
4247 | * name-lookup.c (add_decl_to_level): Remove addition to vtables chain. | |
4248 | * name-lookup.h (cp_binding_level): Remove vtables member. | |
4249 | ||
18177c7e RG |
4250 | 2007-08-24 Richard Guenther <rguenther@suse.de> |
4251 | ||
4252 | * tree.c (cp_cannot_inline_tree_fn): Remove. | |
4253 | * cp-tree.h (cp_cannot_inline_tree_fn): Likewise. | |
4254 | * cp-objcp-common.h (LANG_HOOKS_TREE_INLINING_CANNOT_INLINE_TREE_FN): | |
4255 | Remove define. | |
4256 | ||
c6f3d2f4 JJ |
4257 | 2007-08-24 Jakub Jelinek <jakub@redhat.com> |
4258 | ||
affb3cb2 JJ |
4259 | PR c++/32567 |
4260 | * typeck.c (build_unary_op) <case PREINCREMENT_EXPR>: Return | |
4261 | error_mark_node right away if build_expr_type_conversion | |
4262 | returned it. | |
4263 | ||
97dc8e5b JJ |
4264 | PR c++/32898 |
4265 | * name-lookup.c (set_decl_namespace): lookup_qualified_name failure | |
4266 | is error_mark_node rather than NULL_TREE. | |
4267 | * pt.c (check_explicit_specialization): Likewise. | |
4268 | ||
c6f3d2f4 JJ |
4269 | PR c++/31941 |
4270 | * error.c (resolve_virtual_fun_from_obj_type_ref): Handle | |
4271 | TARGET_VTABLE_USES_DESCRIPTORS targets properly. | |
4272 | ||
61172206 JM |
4273 | 2007-08-22 Jason Merrill <jason@redhat.com> |
4274 | ||
4275 | PR c++/29365 | |
4276 | * pt.c (outermost_tinst_level): New function. | |
4277 | * lex.c (in_main_input_context): New function. | |
f11b2351 | 4278 | * cp-tree.h: Declare it. |
61172206 JM |
4279 | * decl2.c (constrain_class_visibility): Use it to avoid warning |
4280 | about uses of the anonymous namespace in the main input file. | |
4281 | ||
af9fc1dd JJ |
4282 | 2007-08-21 Jakub Jelinek <jakub@redhat.com> |
4283 | ||
4284 | * init.c (build_new_1): Use get_target_expr instead of save_expr. | |
4285 | ||
43f14744 PS |
4286 | 2007-08-20 Pawel Sikora <pluto@pld-linux.org> |
4287 | ||
4288 | PR c++/7302 | |
4289 | * class.c (finish_struct_1): Warn when a class has virtual | |
4290 | functions and accessible non-virtual destructor. | |
4291 | ||
a489b1f0 RG |
4292 | 2007-08-20 Richard Guenther <rguenther@suse.de> |
4293 | ||
4294 | PR c++/22369 | |
4295 | PR c++/22451 | |
4296 | * call.c (build_new_method_call): Convert initializer to | |
4297 | the basetype. | |
4298 | * init.c (build_aggr_init): Do not fiddle with types. | |
4299 | (build_vec_delete_1): Use correct type for POINTER_PLUS_EXPR. | |
4300 | * except.c (build_throw): Do not drop qualifiers for the | |
4301 | pointer type. | |
4302 | * typeck.c (get_member_function_from_ptrfunc): Do not | |
4303 | fiddle with types, instead convert. | |
4304 | (build_ptrmemfunc1): Convert to the target type for | |
4305 | initialization. | |
4306 | (gfc_trans_allocate): Convert result to target type. | |
4307 | * cp-objcp-common.c (cxx_get_alias_set): Pointers to | |
4308 | pointer-to-member structures shall have alias set zero as well. | |
4309 | ||
50886bf1 RG |
4310 | 2007-08-20 Richard Guenther <rguenther@suse.de> |
4311 | ||
4312 | * cp-objcp-common.h (LANG_HOOKS_TREE_INLINING_AUTO_VAR_IN_FN_P): | |
4313 | Remove. | |
4314 | * cp-tree.h (cp_auto_var_in_fn_p): Remove. | |
4315 | (nonstatic_local_decl_p): Likewise. | |
4316 | * tree.c (cp_auto_var_in_fn_p): Remove. | |
4317 | * decl.c (nonstatic_local_decl_p): Remove. | |
4318 | ||
14588106 RG |
4319 | 2007-08-20 Richard Guenther <rguenther@suse.de> |
4320 | ||
4321 | * cp-objcp-common.h (LANG_HOOKS_TREE_INLINING_WALK_SUBTREES): | |
4322 | Remove define. | |
4323 | * tree.h (cp_walk_tree): New define to walk_tree_1 with | |
4324 | cp_walk_subtrees lh parameter. | |
4325 | (cp_walk_tree_without_duplicates): New define to | |
4326 | walk_tree_without_duplicates_1 with cp_walk_subtrees lh parameter. | |
4327 | * tree.c (count_trees): Call | |
4328 | cp_walk_tree_without_duplicates. | |
4329 | (verify_stmt_tree): Call cp_walk_tree. | |
4330 | (break_out_target_exprs): Likewise. | |
4331 | (WALK_SUBTREE): Likewise. | |
4332 | * cp-gimplify.c (cp_genericize): Likewise. | |
4333 | * cp-pt.c (find_parameter_packs_r): Likewise. | |
4334 | (uses_parameter_packs): Likewise. | |
4335 | (make_pack_expansion): Likewise. | |
4336 | (check_for_bare_parameter_packs): Likewise. | |
4337 | (for_each_template_parm): Likewise. | |
4338 | * decl.c (check_default_argument): Call | |
4339 | cp_walk_tree_without_duplicates. | |
4340 | * except.c (build_throw): Likewise. | |
4341 | * decl2.c (type_visibility): Likewise. | |
4342 | * semantics.c (expand_or_defer_fn): Likewise. | |
4343 | (finalize_nrv): Call cp_walk_tree. | |
4344 | ||
412bbe81 JJ |
4345 | 2007-08-20 Jakub Jelinek <jakub@redhat.com> |
4346 | ||
4347 | PR c++/33025 | |
4348 | * init.c (build_new_1): Rename placement_var variable to placement_expr. | |
4349 | Initialize it with save_expr rather than get_temp_regvar. | |
4350 | ||
8f4361eb AP |
4351 | 2007-08-17 Andrew Pinski <andrew_pinski@playstation.sony.com> |
4352 | ||
4353 | PR c++/28989 | |
4354 | * tree.c (lvalue_p_1 <case SAVE_EXPR>): SAVE_EXPRs are never | |
4355 | lvalues. | |
4356 | ||
44fd0e80 OW |
4357 | 2007-08-17 Ollie Wild <aaw@google.com> |
4358 | ||
4359 | PR c++/31749 | |
4360 | * name-lookup.c (do_nonmember_using_decl): Shift implicit type | |
4361 | declarations into appropriate slots for comparison. Fix type | |
4362 | comparison. | |
4363 | ||
2658bdae PC |
4364 | 2007-08-17 Paolo Carlini <pcarlini@suse.de> |
4365 | ||
4366 | PR c++/32112 | |
4367 | * error.c (dump_decl): Deal with UNBOUND_CLASS_TEMPLATE. | |
4368 | * cxx-pretty-print.c (pp_cxx_unqualified_id): Likewise. | |
4369 | ||
968fc32d PC |
4370 | 2007-08-17 Paolo Carlini <pcarlini@suse.de> |
4371 | ||
4372 | PR c++/32870 | |
4373 | * parser.c (cp_parser_class_head): Improve error message. | |
4374 | ||
75407da3 SP |
4375 | 2007-08-16 Seongbae Park <seongbae.park@gmail.com> |
4376 | ||
968fc32d PC |
4377 | * pt.c (instantiate_decl): Set input_location |
4378 | for the function end. | |
75407da3 | 4379 | |
ac7d7749 KG |
4380 | 2007-08-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
4381 | ||
4382 | * cp-objcp-common.c (cxx_warn_unused_global_decl, cp_expr_size): | |
4383 | Constify. | |
4384 | * cp-tree.h (local_variable_p, nonstatic_local_decl_p, | |
4385 | class_tmpl_impl_spec_p, cp_auto_var_in_fn_p, cp_type_quals, | |
4386 | cxx_incomplete_type_diagnostic, cxx_incomplete_type_error, | |
4387 | cxx_warn_unused_global_decl, cp_expr_size): Likewise. | |
4388 | * decl.c (local_variable_p, nonstatic_local_decl_p): Likewise. | |
4389 | * tree.c (class_tmpl_impl_spec_p, cp_auto_var_in_fn_p): Likewise. | |
4390 | * typeck.c (cp_type_quals): Likewise. | |
4391 | * typeck2.c (cxx_incomplete_type_diagnostic, | |
4392 | cxx_incomplete_type_error): Likewise. | |
4393 | ||
684939ce PC |
4394 | 2007-08-16 Paolo Carlini <pcarlini@suse.de> |
4395 | ||
4396 | PR c++/31132 | |
4397 | * pt.c (tsubst_friend_function): When check_classfn | |
4398 | returns error_mark_node likewise return it. | |
4399 | ||
59fe9274 JJ |
4400 | 2007-08-15 Jakub Jelinek <jakub@redhat.com> |
4401 | ||
4402 | PR c++/32992 | |
4403 | * typeck.c (check_return_expr): Don't NRV optimize vars in | |
4404 | anonymous unions. | |
4405 | * decl.c (finish_function): Comment fix. | |
4406 | ||
ba75df2b PC |
4407 | 2007-08-15 Paolo Carlini <pcarlini@suse.de> |
4408 | ||
4409 | PR c++/33035 | |
4410 | * pt.c (push_template_decl_real): Depending on TYPE_P | |
4411 | use either TYPE_CONTEXT or DECL_CONTEXT. | |
4412 | ||
67f9922b MM |
4413 | 2007-08-14 Mark Mitchell <mark@codesourcery.com> |
4414 | ||
4415 | * semantics.c (finish_omp_clauses): Strip a NOP_EXPR if | |
4416 | constructors and destructors return this. | |
4417 | ||
f8c3b097 PC |
4418 | 2007-08-14 Paolo Carlini <pcarlini@suse.de> |
4419 | ||
4420 | PR c++/27211 | |
4421 | * decl2.c (check_classfn): Return error_mark_node in case of error; | |
4422 | in that case, do not call add_method. | |
4423 | * decl.c (start_decl): Deal with check_classfn returning | |
4424 | error_mark_node. | |
4425 | (grokfndecl): Likewise. | |
4426 | * pt.c (tsubst_friend_function): Likewise. | |
4427 | ||
9ef0c8d9 AP |
4428 | 2007-08-14 Andrew Pinski <pinskia@gmail.com> |
4429 | ||
4430 | PR c++/30428 | |
4431 | * typeck.c (build_binary_op): Disallow vector float types with | |
4432 | BIT_IOR_EXPR, BIT_AND_EXPR, and BIT_XOR_EXPR. | |
4433 | ||
4862826d ILT |
4434 | 2007-08-11 Ian Lance Taylor <iant@google.com> |
4435 | ||
4436 | * cp-objcp-common.c (cxx_get_alias_set): Change return type to | |
4437 | alias_set_type. | |
b97d8153 | 4438 | * cp-tree.h (cxx_get_alias_set): Update declaration. |
4862826d | 4439 | |
19831e2b OW |
4440 | 2007-08-10 Ollie Wild <aaw@google.com> |
4441 | ||
4442 | * name-lookup.c (do_nonmember_using_decl): Print an error for ambiguous | |
4443 | type lookups. | |
4444 | (ambiguous_decl): Construct tree of ambiguous types. Remove extaneous | |
4445 | function parameter. | |
4446 | (unqualified_namespace_lookup): Fix ambiguous_decl call. | |
4447 | (lookup_using_namespace): Fix ambiguous_decl call. | |
4448 | (qualified_lookup_using_namespace): Fix ambiguous_decl call. | |
4449 | ||
68a57691 KG |
4450 | 2007-08-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
4451 | ||
4452 | * call.c (name_as_c_string): Use CONST_CAST. | |
4453 | * decl.c (build_decl): Likewise. | |
4454 | * parser.c (cp_parser_string_literal): Likewise. | |
4455 | ||
2fbe0e5a PC |
4456 | 2007-08-10 Paolo Carlini <pcarlini@suse.de> |
4457 | ||
4458 | PR c++/17763 | |
4459 | * error.c (dump_expr): Consistently use the *_cxx_* | |
4460 | variants of the pretty-print functions. | |
4461 | ||
caba2081 PC |
4462 | 2007-08-10 Paolo Carlini <pcarlini@suse.de> |
4463 | ||
4464 | PR c++/22256 | |
4465 | * decl.c (check_special_function_return_type): Just error | |
4466 | on return type specified for conversion operator. | |
4467 | ||
d7705934 DB |
4468 | 2007-08-09 Daniel Berlin <dberlin@dberlin.org> |
4469 | ||
4470 | * typeck2.c (readonly_error): Handle general expressions. | |
4471 | * error.c (dump_expr): Handle POINTER_PLUS_EXPR | |
4472 | ||
af34b82f DH |
4473 | 2007-08-06 Dan Hipschman <dsh@google.com> |
4474 | ||
4475 | * method.c (use_thunk): Use DECL_NAME instead of DECL_RTL to | |
4476 | access function name. | |
4477 | ||
5958f5cb AM |
4478 | 2007-08-04 Alfred Minarik <a.minarik@aon.at> |
4479 | ||
4480 | PR pch/13676 | |
4481 | * lang-specs.h: Add .hp, .hxx, .hpp, .h, .HPP, .tcc as c++ header. | |
4482 | * g++spec.c (lang_specific_driver): Check them. | |
4483 | ||
ae95e46e PC |
4484 | 2007-08-06 Paolo Carlini <pcarlini@suse.de> |
4485 | ||
4486 | PR c++/19532 | |
13678df8 | 4487 | * pt.c (inline_needs_template_parms): Fix comment; change return type |
ae95e46e PC |
4488 | to bool. |
4489 | ||
9dfbac5b VR |
4490 | 2007-08-05 Volker Reichelt <v.reichelt@netcologne.de> |
4491 | ||
4492 | Revert: | |
4493 | 2007-03-26 Dirk Mueller <dmueller@suse.de> | |
4494 | ||
4495 | * parser.c (cp_parser_member_declaration): Pedwarn | |
4496 | about stray semicolons after member declarations. | |
f8ff69ea LM |
4497 | |
4498 | 2007-08-02 Lee Millward <lee.millward@gmail.com> | |
4499 | ||
4500 | PR c++/30849 | |
4501 | PR c++/30850 | |
4502 | PR c++/30851 | |
4503 | * parser.c (cp_parser_asm_definition): Detect and discard asm | |
4504 | statements with invalid inputs or outputs. | |
056dd1af L |
4505 | (cp_parser_asm_operand_list): Return error mark node if any |
4506 | of the operands are invalid. Adjust documentation. | |
4507 | ||
e77f031d NC |
4508 | 2007-08-02 Nick Clifton <nickc@redhat.com> |
4509 | ||
4510 | * typeck.c: Change copyright header to refer to version 3 of the | |
4511 | GNU General Public License and to point readers at the COPYING3 | |
4512 | file and the FSF's license web page. | |
4513 | * optimize.c, lang-specs.h, init.c, class.c, repo.c, decl.c, | |
4514 | config-lang.in, cp-tree.def, call.c, decl.h, ptree.c, | |
4515 | Make-lang.in, method.c, rtti.c, cp-objcp-common.c, g++spec.c, | |
4516 | cp-objcp-common.h, except.c, error.c, operators.def, cvt.c, | |
4517 | tree.c, mangle.c, cp-tree.h, dump.c, search.c, friend.c, expr.c, | |
4518 | cp-gimplify.c, cxx-pretty-print.c, cp-lang.c, typeck2.c, pt.c, | |
4519 | cxx-pretty-print.h, semantics.c, name-lookup.c, lex.c, decl2.c, | |
4520 | name-lookup.h, parser.c: Likewise. | |
4521 | ||
59f89d34 KG |
4522 | 2007-08-01 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
4523 | ||
4524 | PR middle-end/32668 | |
4525 | * call.c (magic_varargs_p): Honor the "type generic" attribute. | |
4526 | ||
a6d76a95 PC |
4527 | 2007-07-30 Paolo Carlini <pcarlini@suse.de> |
4528 | ||
4529 | PR c++/32108 | |
4530 | * semantics.c (finish_label_stmt): Reject the __label__ | |
4531 | extension outside function scopes. | |
4532 | ||
fa233e34 KG |
4533 | 2007-07-29 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
4534 | ||
4535 | * parser.c (eof_token): Un-constify. | |
4536 | (cp_lexer_new_main, cp_lexer_new_from_tokens, VEC_alloc, | |
4537 | cp_lexer_consume_token, cp_lexer_purge_token): Remove spurious | |
4538 | casts. | |
4539 | ||
d732e98f KH |
4540 | 2007-07-28 Kazu Hirata <kazu@codesourcery.com> |
4541 | ||
4542 | * pt.c, tree.c, typeck2.c: Fix comment typos. | |
4543 | ||
d4d8c232 SM |
4544 | 2007-07-28 Simon Martin <simartin@users.sourceforge.net> |
4545 | Mark Mitchell <mark@codesourcery.com> | |
4546 | ||
4547 | PR c++/30917 | |
4548 | * name-lookup.c (lookup_name_real): Non namespace-scope bindings can be | |
4549 | hidden due to friend declarations in local classes. | |
4550 | ||
3ad6a8e1 DG |
4551 | 2007-07-27 Douglas Gregor <doug.gregor@gmail.com> |
4552 | ||
4553 | * typeck.c (structural_comptypes): Compare DECLTYPE_TYPE nodes. | |
4554 | * cp-tree.def (DECLTYPE_TYPE): New. | |
4555 | * error.c (dump_type): Dump DECLTYPE_TYPE nodes. | |
4556 | (dump_type_prefix): Ditto. | |
4557 | (dump_type_suffix): Ditto. | |
4558 | * tree.c (DECLTYPE_TYPE): Walk DECLTYPE_TYPE nodes. | |
4559 | * mangle.c (write_type): Handle DECLTYPE_TYPE. | |
4560 | * cp-tree.h (IS_AGGR_TYPE): DECLTYPE_TYPE nodes can be aggregate | |
4561 | types. | |
4562 | (DECLTYPE_TYPE_EXPR): New. | |
4563 | (DECLTYPE_TYPE_ID_EXPR_OR_MEMBER_ACCESS_P): New. | |
4564 | (finish_declared_type): Declare. | |
4565 | * cxx-pretty-print.c (pp_cxx_type_specifier_seq): Print | |
4566 | DECLTYPE_TYPE nodes. | |
4567 | (pp_cxx_type_id): Ditto. | |
4568 | * pt.c (for_each_template_parm_r): Walk DECLTYPE_TYPE children. | |
4569 | (tsubst): Substitute into a DECLTYPE_TYPE node. | |
4570 | (tsubst_copy): Ditto. | |
4571 | (unify): Cannot deduce anything from TYPEOF_TYPE or DECLTYPE_TYPE | |
4572 | nodes. | |
4573 | (dependent_type_p_r): DECLTYPE_TYPE types are always dependent. | |
4574 | * semantics.c (finish_typeof): TYPEOF_TYPE types need to use | |
4575 | structural equality (because we can't hash the expressions). | |
4576 | (finish_declared_type): New. | |
4577 | * lex.c (reswords): Add "decltype" keyword. | |
4578 | * parser.c cp_lexer_next_token_is_decl_specifier_keyword | |
4579 | (cp_parser_postfix_expression): Add member_access_only_p to | |
4580 | restrict postfix expression to member access expressions. | |
4581 | (cp_parser_unary_expression): Update call to | |
4582 | cp_parser_postfix_expression to reflect new parameter. | |
4583 | (cp_parser_declared_type): New. | |
4584 | (cp_parser_simple_type_specifier): Parse decltype types. | |
4585 | ||
83144bd6 MM |
4586 | 2007-07-27 Mark Mitchell <mark@codesourcery.com> |
4587 | ||
4588 | PR c++/32346 | |
4589 | * call.c (convert_for_arg_passing): Only widen bitfields to their | |
4590 | declared types if necessary. | |
4591 | ||
e5cfc29f KG |
4592 | 2007-07-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
4593 | ||
4594 | * parser.c (cp_parser_string_literal, cp_parser_sizeof_operand): | |
4595 | Constify. | |
4596 | ||
741ac903 KG |
4597 | 2007-07-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> |
4598 | ||
4599 | * decl.c (typename_hash, typename_compare): Constify. | |
4600 | * mangle.c (hash_type, compare_type): Likewise. | |
4601 | * pt.c (eq_local_specializations, hash_local_specialization): | |
4602 | Likewise. | |
4603 | * tree.c (cplus_array_hash, cplus_array_compare, list_hash_eq, | |
4604 | list_hash): Likewise. | |
4605 | * typeck2.c (pat_compare): Likewise. | |
4606 | ||
b21a6ea1 NS |
4607 | 2007-07-24 Nathan Sidwell <nathan@codesourcery.com> |
4608 | ||
4609 | * method.c (implicitly_declare_fn): Increase alignment if member | |
4610 | function pointer format requires it. | |
4611 | ||
aedfac0e PC |
4612 | 2007-07-24 Paolo Carlini <pcarlini@suse.de> |
4613 | ||
4614 | PR c++/29001 | |
4615 | * typeck.c (check_return_expr): Do not pass a null argument | |
4616 | to null_ptr_cst_p. | |
4617 | ||
4618 | 2007-07-24 Paolo Carlini <pcarlini@suse.de> | |
4619 | ||
4620 | PR c++/32561 | |
4621 | * decl.c (redeclaration_error_message): Call DECL_ANON_UNION_VAR_P | |
4622 | only on VAR_DECL. | |
4623 | ||
4195a767 NS |
4624 | 2007-07-22 Nathan Sidwell <nathan@codesourcery.com> |
4625 | ||
823c22f9 NS |
4626 | PR c++/32839 |
4627 | * typeck.c (convert_arguments): Only use default args if we have | |
4628 | a function decl. | |
4629 | ||
4195a767 NS |
4630 | PR c++/30818 |
4631 | * typeck.c (structural_comptypes): No need to check | |
4632 | resolve_typename_type return value here. | |
4633 | * cp-tree.h (TYPENAME_IS_RESOLVING_P): New. | |
4634 | * pt.c (resolve_typename_type): Follow typename typedefs. Return | |
4635 | original type rather than error_mark_node in case of failure. | |
4636 | * parser.c (cp_parser_nested_name_specifier_opt): Adjust | |
4637 | resolve_typename_type result check. | |
4638 | (cp_parser_direct_declarator, cp_parser_head, | |
4639 | cp_parser_constructor_declarator_p): Likewise. | |
4640 | ||
2fe5bb9b KH |
4641 | 2007-07-12 Kazu Hirata <kazu@codesourcery.com> |
4642 | ||
4643 | * pt.c (template_parms_variadic_p): Remove. | |
4644 | * cp-tree.h: Remove the prototype for template_parms_variadic_p. | |
4645 | ||
99c1f1ce JJ |
4646 | 2007-07-12 Jakub Jelinek <jakub@redhat.com> |
4647 | ||
4648 | PR c++/30854 | |
4649 | * error.c (dump_expr) <case AGGR_INIT_EXPR>: Pass true as last | |
4650 | argument to dump_aggr_init_expr_args instead of false. | |
4651 | ||
7313518b DG |
4652 | 2007-07-11 Douglas Gregor <doug.gregor@gmail.com> |
4653 | ||
4654 | * typeck.c (comptypes): When USE_CANONICAL_TYPES, use the | |
4655 | canonical types; otherwise, fall back to structural type | |
4656 | comparisons. If ENABLE_CHECKING and USE_CANONICAL_TYPES, give an | |
4657 | internal compiler error if the canonical types are wrong. | |
056dd1af | 4658 | |
b8ade407 PC |
4659 | 2007-07-11 Paolo Carlini <pcarlini@suse.de> |
4660 | ||
4661 | PR c++/32560 | |
4662 | * parser.c (cp_parser_make_indirect_declarator): When the | |
4663 | the code argument is ERROR_MARK return cp_error_declarator. | |
4664 | ||
837edd5f GK |
4665 | 2007-07-09 Geoffrey Keating <geoffk@apple.com> |
4666 | ||
4667 | PR 32617 | |
4668 | * decl.c (cxx_init_decl_processing): Don't set | |
4669 | force_align_functions_log. | |
4670 | (grokfndecl): Honour ptrmemfunc_vbit_in_pfn. | |
4671 | * typeck.c (cxx_alignof_expr): When alignof is used on a plain | |
4672 | FUNCTION_DECL, return its alignment. | |
4673 | ||
f967586f RG |
4674 | 2007-07-09 Richard Guenther <rguenther@suse.de> |
4675 | ||
4676 | * decl.c (start_preparsed_function): Do not promote return type. | |
4677 | ||
833be229 PC |
4678 | 2007-07-08 Paolo Carlini <pcarlini@suse.de> |
4679 | ||
4680 | PR c++/30535 | |
4681 | * pt.c (unify): Never pass error_mark_node to template_decl_level. | |
4682 | ||
acde59b4 MM |
4683 | 2007-07-07 Mark Mitchell <mark@codesourcery.com> |
4684 | ||
4685 | PR c++/32232 | |
4686 | * pt.c (resolve_overloaded_unification): Robustify. Return a | |
4687 | bool, not an int. | |
4688 | (type_unification_real): Adjust accordingly. | |
4689 | ||
b5119fa1 RG |
4690 | 2007-07-06 Richard Guenther <rguenther@suse.de> |
4691 | ||
4692 | * init.c (build_new_1): Use the correct pointer type. | |
4693 | * typeck2.c (build_m_component_ref): Likewise. | |
4694 | ||
32a11c08 MM |
4695 | 2007-07-05 Mark Mitchell <mark@codesourcery.com> |
4696 | ||
4697 | PR c++/32245 | |
4698 | * init.c (build_zero_init): Always build an initializer for | |
4699 | non-static storage. | |
4700 | * typeck2.c (build_functional_cast): Use build_zero_init. | |
4701 | ||
4702 | PR c++/32251 | |
4703 | * init.c (build_new_1): Always pass the allocation function to | |
4704 | build_op_delete_call. | |
4705 | * call.c (build_op_delete_call): Handle operator delete with a | |
4706 | variable-argument list. Do not issue an error when no matching | |
4707 | deallocation function is available for a new operator. | |
4708 | ||
4709 | PR c++/31992 | |
4710 | * cp-tree.h (any_value_dependent_elements_p): Declare it. | |
4711 | * decl.c (value_dependent_init_p): New function. | |
4712 | (cp_finish_decl): Use it. | |
4713 | * pt.c (value_dependent_expression_p): Use | |
4714 | any_value_dependent_elements_p. | |
4715 | * parser.c (cp_parser_primary_expression): Add comment about | |
4716 | treating dependent qualified names as integral | |
4717 | constant-expressions. | |
4718 | ||
8de08f4c DG |
4719 | 2007-07-04 Douglas Gregor <doug.gregor@gmail.com> |
4720 | ||
4721 | * decl.c (build_ptrmemfunc_type): Always use structural equality | |
4722 | tests when comparing pointer-to-member-function types, because the | |
4723 | handling of TYPE_GET_PTRMEMFUNC_TYPE currently defeats canonical | |
4724 | types. | |
056dd1af | 4725 | |
57ccb546 MM |
4726 | 2007-07-03 Mark Mitchell <mark@codesourcery.com> |
4727 | ||
4728 | * init.c (build_new): Tweak comment. | |
4729 | ||
39fb9d72 DB |
4730 | 2007-06-29 Dave Brolley <brolley@redhat.com> |
4731 | ||
4732 | PR c++/31743 | |
4733 | * parser.c (cp_parser_new_type_id): Don't reduce a named array | |
4734 | type to its base type and number of elements here. | |
4735 | * init.c (build_new): Call complete_type_or_else to ensure that the | |
4736 | type is complete and to issue a diagnostic if it is not. | |
4737 | (build_new_1): Don't call complete_type_or_else here. | |
4738 | ||
e656a465 RG |
4739 | 2007-07-03 Richard Guenther <rguenther@suse.de> |
4740 | ||
4741 | PR c++/32609 | |
4742 | * class.c (fixed_type_or_null): Re-lookup the hashtable slot | |
4743 | after recursing. | |
4744 | ||
2a7b8343 SB |
4745 | 2007-07-02 Simon Baldwin <simonb@google.com> |
4746 | ||
4747 | * parser.c (cp_parser_elaborated_type_specifier): Added a warning | |
4748 | for inner-style nested forward declarations that don't declare | |
4749 | anything useful. | |
4750 | ||
76dc15d4 JJ |
4751 | 2007-07-02 Jakub Jelinek <jakub@redhat.com> |
4752 | ||
4753 | PR c++/31748 | |
4754 | * semantics.c (finish_omp_clauses): Use %qD instead of %qE for | |
4755 | DECL_P in not a variable and appears more than once error messages. | |
4756 | ||
af92ab36 OW |
4757 | 2007-07-01 Ollie Wild <aaw@google.com> |
4758 | ||
4759 | * name-lookup.c (ambiguous_decl): Fix case when new->value is hidden. | |
4760 | (select_decl): Remove function. | |
4761 | (unqualified_namespace_lookup): Populate binding by calling | |
4762 | ambiguous_decl. Remove select_decl call. | |
4763 | (lookup_qualified_name): Remove select_decl call. | |
4764 | * decl.c (lookup_and_check_tag): Check for ambiguous references. | |
4765 | * parser.c (cp_parser_elaborated_type_specifier): Skip redundant error | |
4766 | generation when name lookup is ambiguous. | |
4767 | ||
bfa8d90b DG |
4768 | 2007-06-29 Douglas Gregor <doug.gregor@gmail.com> |
4769 | ||
4770 | PR c++/31724 | |
4771 | * init.c (build_new_1): Use structural equality on the copy of the | |
4772 | array type. | |
4773 | ||
ddbfd28d GK |
4774 | 2007-06-28 Geoffrey Keating <geoffk@apple.com> |
4775 | ||
4776 | * decl2.c (determine_visibility): Implement | |
4777 | flag_visibility_ms_compat effect on type info. | |
4778 | * decl.c (cxx_init_decl_processing): Implement | |
4779 | global effect of flag_visibility_ms_compat. | |
4780 | ||
32d49134 GK |
4781 | 2007-06-28 Geoffrey Keating <geoffk@apple.com> |
4782 | ||
e301e2c4 | 4783 | * decl2.c (start_objects): Mark constructor-running function |
32d49134 GK |
4784 | as artificial. |
4785 | ||
b46ce77f SM |
4786 | 2007-06-26 Simon Martin <simartin@users.sourceforge.net> |
4787 | ||
4788 | PR c++/32111 | |
4789 | * decl.c (grokdeclarator): Reset friendp for member functions declared | |
4790 | friend of their own class. | |
4791 | ||
3a687f8b MM |
4792 | 2007-06-23 Mark Mitchell <mark@codesourcery.com> |
4793 | ||
4794 | * decl2.c (determine_visibility): Don't look for dllexport here. | |
4795 | (determine_visibility_from_class): Tidy. | |
4796 | ||
736b8100 SB |
4797 | 2007-06-18 Simon Baldwin <simonb@google.com> |
4798 | ||
4799 | PR c++/31923 | |
4800 | * parser.c (cp_parser_single_declaration): Added check for storage | |
4801 | class other than sc_none in parsed declaration, and a flag to indicate | |
4802 | if the call is part of an explicit template specialization parse. | |
4803 | * (cp_parser_explicit_specialization): Specialization check flag added | |
4804 | to call to cp_parser_single_declaration(), set true. | |
4805 | * (cp_parser_template_declaration_after_export): Specialization check | |
4806 | flag added to call to cp_parser_single_declaration(), set false. | |
4807 | * pt.c (check_explicit_specialization): Added code to copy visiblity | |
4808 | and linkage from the templated function to the explicit specialization. | |
4809 | ||
5be014d5 AP |
4810 | 2007-06-15 Andrew Pinski <andrew_pinski@playstation.sony.com> |
4811 | ||
4812 | * typeck.c (build_binary_op): For templates build the | |
4813 | expression in pieces to avoid the assert in build2_stat. | |
4814 | (get_member_function_from_ptrfunc): | |
4815 | Change over to using POINTER_PLUS_EXPR and convert | |
4816 | the second operand to sizetype. | |
4817 | * typeck2.c (build_m_component_ref): Likewise. | |
4818 | * init.c (expand_virtual_init): Create a POINTER_PLUS_EXPR | |
4819 | instead of PLUS_EXPR for pointers. | |
4820 | (build_new_1): Likewise. | |
4821 | (build_vec_delete_1): Likewise. | |
4822 | (build_vec_delete): Likewise. | |
4823 | * class.c (build_base_path): Likewise. | |
4824 | (build_base_path): Likewise. | |
4825 | (convert_to_base_statically): Likewise. | |
4826 | (fixed_type_or_null): Handle POINTER_PLUS_EXPR. | |
4827 | (get_vtbl_decl_for_binfo): Handle POINTER_PLUS_EXPR | |
4828 | instead of PLUS_EXPR. | |
4829 | (dfs_accumulate_vtbl_inits): Create a POINTER_PLUS_EXPR | |
4830 | instead of PLUS_EXPR for pointers. | |
4831 | * call.c (build_special_member_call): Likewise. | |
4832 | * rtti.c (build_headof): Likewise. | |
4833 | Use sizetype instead of ptrdiff_type_node. | |
4834 | (tinfo_base_init): Create a POINTER_PLUS_EXPR | |
4835 | instead of PLUS_EXPR for pointers. | |
4836 | * except.c (expand_start_catch_block): Do a | |
4837 | NEGATIVE and then a POINTER_PLUS_EXPR instead | |
4838 | of a MINUS_EXPR. | |
4839 | * cp-gimplify.c (cxx_omp_clause_apply_fn): Convert | |
4840 | PLUS_EXPR on pointer types over to use | |
4841 | POINTER_PLUS_EXPR and remove the conversion | |
4842 | to the pointer types. | |
4843 | * method.c (thunk_adjust): Use POINTER_PLUS_EXPR for | |
4844 | adding to a pointer type. Use size_int instead of | |
4845 | ssize_int. Convert the index to sizetype before | |
4846 | adding it to the pointer. | |
4847 | ||
555551c2 MM |
4848 | 2007-06-15 Mark Mitchell <mark@codesourcery.com> |
4849 | ||
4850 | * cp-tree.h (DECL_VAR_MARKED_P): Remove. | |
4851 | (DECL_ANON_UNION_VAR_P): New macro. | |
4852 | * class.c (fixed_type_or_null): Tidy. Use a hash table, rather | |
4853 | than DECL_VAR_MARKED_P, to keep track of which variables we have | |
4854 | seen. | |
4855 | * decl.c (redeclaration_error_message): Complain about redeclaring | |
4856 | anonymous union members at namespace scope. | |
4857 | * decl2.c (build_anon_union_vars): Set DECL_ANON_UNION_VAR_P. | |
4858 | ||
7dbd86a5 GK |
4859 | 2007-06-14 Geoff Keating <geoffk@apple.com> |
4860 | ||
c96f0001 GK |
4861 | * decl2.c (determine_visibility): Ensure that functions with |
4862 | hidden types as parameters are hidden. | |
4863 | ||
7dbd86a5 GK |
4864 | PR 31093 |
4865 | * decl2.c (determine_visibility): Remove duplicate code for | |
4866 | handling type info. | |
4867 | ||
058dcc25 ILT |
4868 | 2007-06-12 Ian Lance Taylor <iant@google.com> |
4869 | ||
4870 | PR libstdc++/29286 | |
4871 | * init.c (avoid_placement_new_aliasing): New static function. | |
4872 | (build_new_1): Call it. | |
4873 | ||
719bb4e3 | 4874 | 2007-06-11 Rafael Ávila de Espíndola <espindola@google.com> |
b0464c88 RE |
4875 | |
4876 | * cp-objcp-common.h (LANG_HOOKS_SIGNED_TYPE): Remove. | |
4877 | (LANG_HOOKS_SIGNED_OR_UNSIGNED_TYPE): Remove. | |
4878 | ||
969c111d JJ |
4879 | 2007-06-08 Jakub Jelinek <jakub@redhat.com> |
4880 | ||
4881 | PR c++/32177 | |
4882 | * semantics.c (finish_omp_for): Call fold_build_cleanup_point_expr | |
4883 | on init, the non-decl cond operand and increment value. | |
4884 | ||
c1ae8be5 SM |
4885 | 2007-06-07 Simon Martin <simartin@users.sourceforge.net> |
4886 | ||
4887 | PR c++/30759 | |
4888 | * decl.c (check_initializer): Report an error when a brace enclosed | |
4889 | initializer is used for a non-aggregate type in C++98. | |
4890 | (redeclaration_error_message): Rewrote flag_cpp0x in terms of | |
4891 | cxx_dialect. | |
4892 | (grokdeclarator): Likewise. | |
4893 | (move_fn_p): Likewise. | |
4894 | * typeck.c (check_return_expr): Likewise. | |
4895 | * call.c (reference_binding): Likewise. | |
4896 | * error.c (cp_cpp_error): Likewise. | |
4897 | * pt.c (check_default_tmpl_args): Likewise. | |
4898 | (tsubst): Likewise. | |
4899 | * lex.c (init_reswords): Likewise. | |
4900 | * parser.c (p_parser_primary_expression): Likewise. | |
4901 | (TOKEN_PRECEDENCE): Likewise. | |
4902 | (cp_parser_init_declarator): Likewise. | |
4903 | (cp_parser_ptr_operator): Likewise. | |
4904 | (cp_parser_parameter_declaration): Likewise. | |
4905 | (cp_parser_enclosed_template_argument_list): Likewise. | |
4906 | (cp_parser_skip_to_end_of_template_parameter_list): Likewise. | |
4907 | (cp_parser_next_token_ends_template_argument_p): Likewise. | |
4908 | ||
b08f991d SB |
4909 | 2007-06-04 Simon Baldwin <simonb@google.com> |
4910 | ||
4911 | * decl.c (grokdeclarator): Readability change. Moved case labels | |
4912 | into direct switch statement scope. | |
4913 | ||
cab203bf PC |
4914 | 2007-06-04 Paolo Carlini <pcarlini@suse.de> |
4915 | ||
4916 | * call.c (convert_like_real): Remove pointless code. | |
4917 | ||
46a9e521 MM |
4918 | 2007-05-31 Mark Mitchell <mark@codesourcery.com> |
4919 | ||
4920 | * decl.c (get_atexit_fn_ptr_type): New function. | |
4921 | (get_atexit_node): Use it. | |
4922 | (start_cleanup_fn): Likewise. | |
4923 | (register_dtor_fn): Use the object's destructor, instead of a | |
4924 | separate cleanup function, where possible. | |
4925 | * cp-tree.h (CPTI_ATEXIT_FN_PTR_TYPE): New enumerator. | |
4926 | (atexit_fn_ptr_type_node): New macro. | |
4927 | * decl2.c (build_cleanup): Use build_address. | |
4928 | ||
2c751309 DB |
4929 | 2007-05-31 Daniel Berlin <dberlin@dberlin.org> |
4930 | ||
4931 | * typeck.c (build_binary_op): Include types in error. | |
4932 | ||
32735518 JJ |
4933 | 2007-05-31 Jakub Jelinek <jakub@redhat.com> |
4934 | ||
4935 | PR c++/31806 | |
4936 | * decl.c (cp_finish_decl): Also clear was_readonly if a static var | |
4937 | needs runtime initialization. | |
4938 | ||
10c1d4af PC |
4939 | 2007-05-31 Paolo Carlini <pcarlini@suse.de> |
4940 | ||
4941 | PR c++/32158 | |
4942 | * semantics.c (finish_trait_expr): Complete the types. | |
4943 | ||
8af2fec4 | 4944 | 2007-05-30 Russell Yanofsky <russ@yanofsky.org> |
056dd1af L |
4945 | Douglas Gregor <doug.gregor@gmail.com> |
4946 | Pedro Lamarao <pedro.lamarao@mndfck.org> | |
4947 | Howard Hinnant <howard.hinnant@gmail.com> | |
8af2fec4 RY |
4948 | |
4949 | PR c++/7412 | |
4950 | PR c++/29939 | |
4951 | * typeck.c (comptypes): Don't consider rvalue and lvalue | |
4952 | reference types to be equivalent. | |
4953 | (check_return_expr): Move from certain lvalues when returning | |
4954 | them. | |
4955 | * decl.c (grokdeclarator): Implement reference collapsing. | |
4956 | (copy_fn_p): Don't consider constructors taking rvalue references | |
4957 | to be copy constructors. | |
4958 | (move_fn_p): New. | |
5be014d5 | 4959 | * call.c (conversion): New "rvaluedness_matches_p" member. |
8af2fec4 RY |
4960 | (convert_class_to_reference): Require reference type as first |
4961 | parameter instead of base type. | |
4962 | (reference_binding): Add logic to handle rvalue references. | |
4963 | (implicit_conversion): Update inaccurate comment. | |
4964 | (convert_like_real): Disable creation of temporaries that are | |
4965 | impossible to initialize for types with move constructors. | |
4966 | (build_over_call): Elide move constructors when possible. | |
4967 | (maybe_handle_implicit_object): Set "rvaluedness_matches_p". | |
4968 | (maybe_handle_ref_bind): Return conversion instead of type node. | |
4969 | (compare_ics): Add logic to use "rvaluedness_matches_p" values to | |
4970 | determine preferred conversion sequences. | |
4971 | * cp-tree.h (TYPE_REF_IS_RVALUE): New. | |
4972 | (LOOKUP_PREFER_RVALUE): New. | |
4973 | (DECL_MOVE_CONSTRUCTOR_P): New. | |
4974 | (struct cp_declarator): Add "reference" member for reference | |
4975 | types, with new "rvalue_ref" flag. | |
4976 | (cp_build_reference_type): Declare. | |
4977 | (move_fn_p): Declare. | |
4978 | * error.c (dump_type_prefix): Format rvalue reference types | |
4979 | correctly in error messages. | |
4980 | * except.c (build_throw): Move from certain lvalues when | |
4981 | throwing. | |
4982 | * mangle.c (write_type): Mangle rvalue references differently | |
4983 | than regular references. | |
4984 | * parser.c (make_reference_declarator): Add boolean parameter for | |
4985 | rvalue references. | |
4986 | (cp_parser_make_indirect_declarator): New. | |
4987 | (cp_parser_new_declarator_opt): Call | |
056dd1af | 4988 | cp_parser_make_indirect_declarator. |
8af2fec4 RY |
4989 | (cp_parser_conversion_declarator_opt): Ditto. |
4990 | (cp_parser_declarator): Ditto. | |
4991 | (cp_parser_ptr_operator): Parse "&&" tokens into rvalue reference | |
4992 | declarators. | |
4993 | * pt.c (tsubst): Implement reference collapsing. | |
4994 | (maybe_adjust_types_for_deduction): Implement special template | |
4995 | parameter deduction rule for rvalue references. | |
4996 | (type_unification_real): Update calls to | |
4997 | maybe_adjust_types_for_deduction. | |
4998 | (try_one_overload): Ditto. | |
4999 | (unify_pack_expansion): Ditto. | |
5000 | * tree.c (lvalue_p_1): Handle rvalue reference types. | |
5001 | (cp_build_reference_type): New. | |
5002 | ||
27edb548 JJ |
5003 | 2007-05-30 Jakub Jelinek <jakub@redhat.com> |
5004 | ||
5005 | PR c++/31809 | |
5006 | * decl.c (cp_finish_decl): Clear TREE_READONLY flag on TREE_STATIC | |
5007 | variables that need runtime initialization. | |
5008 | ||
a87db577 AP |
5009 | 2007-05-28 Andrew Pinski <Andrew_pinski@playstation.sony.com> |
5010 | ||
5be014d5 | 5011 | PR c++/31339 |
a87db577 AP |
5012 | * typeck.c (build_unary_op <case PREINCREMENT_EXPR, |
5013 | case POSTINCREMENT_EXPR, case PREDECREMENT_EXPR, | |
5014 | case POSTDECREMENT_EXPR>): Return the error_mark_node | |
5015 | if either the real or imaginary parts would an | |
5016 | error_mark_node. | |
056dd1af | 5017 | |
1094da91 SM |
5018 | 2007-05-25 Simon Martin <simartin@users.sourceforge.net> |
5019 | Manuel Lopez-Ibanez <manu@gcc.gnu.org> | |
5020 | ||
5021 | PR c++/31745 | |
5022 | * parser.c (cp_parser_skip_to_closing_brace): Return true if the next | |
5023 | token is a closing brace, false if there are no tokens left. | |
5024 | (cp_parser_namespace_alias_definition): Only consume the next token if | |
5025 | it is a closing brace. | |
5026 | ||
5027 | * parser.c (cp_parser_class_specifier): Likewise. | |
5028 | ||
eb89f88c L |
5029 | 2007-05-25 H.J. Lu <hongjiu.lu@intel.com> |
5030 | ||
5031 | * semantics.c (finish_member_declaration): Fix a typo in the | |
5032 | last checkin. | |
5033 | ||
b1d7b1c0 DG |
5034 | 2007-05-25 Douglas Gregor <doug.gregor@gmail.com> |
5035 | ||
5036 | PR c++/31431 | |
5037 | PR c++/31432 | |
5038 | PR c++/31434 | |
5039 | PR c++/31435 | |
5040 | PR c++/31437 | |
5041 | PR c++/31438 | |
5042 | PR c++/31442 | |
5043 | PR c++/31443 | |
5044 | PR c++/31444 | |
5045 | PR c++/31445 | |
5046 | * error.c (dump_type): Dump TYPE_ARGUMENT_PACK nodes. | |
5047 | * cp-tree.h (check_for_bare_parameter_packs): Returns bool. | |
5048 | * pt.c (check_for_bare_parameter_packs): Return bool indicated | |
5049 | whether everything was okay. Fix indentation. | |
5050 | (push_template_decl_real): Check for bare parameter packs in | |
5051 | function parameters; where errors occur, mark the parameter types | |
5052 | with ERROR_MARK_NODEs to avert ICEs. | |
5053 | (coerce_template_parameter_pack): New. | |
5054 | (coerce_template_parms): Moved parameter pack coercion into | |
5055 | coerce_template_parameter_pack, and permit it anywhere in the | |
5056 | template parameter list (not just at the end). Parameter and | |
5057 | argument indices can vary (somewhat) separately now, so add | |
5058 | PARM_IDX and ARG_IDX. | |
5059 | (fn_type_unification): Don't set an argument pack as incomplete if | |
5060 | no argument pack was deduced. | |
5061 | (type_unification_real): If a type parameter is a parameter pack | |
5062 | and has not otherwise been deduced, it will be deduced to an empty | |
5063 | parameter pack. | |
5064 | (more_specialized_fn): Use the actual lengths of the argument | |
5065 | lists when comparing against expansions. | |
5066 | * semantics.c (finish_member_declaration): If a field's type has | |
5067 | bare parameter packs, error and set its type to ERROR_MARK_NODE. | |
5068 | ||
5234b8f5 DS |
5069 | 2007-05-24 Danny Smith <dannysmith@users.sourceforge.net> |
5070 | ||
5071 | PR target/27067 | |
5072 | * mangle.c (mangle_decl): Call targetm.mangle_decl_assembler_name. | |
5073 | ||
8e89cbfe OW |
5074 | 2007-05-22 Ollie Wild <aaw@google.com> |
5075 | ||
5076 | * name-lookup.c (ambiguous_decl): Adds check for hidden types. | |
5077 | (unqualified_namespace_lookup): Adds check for hidden types. | |
5078 | ||
6936461f OW |
5079 | 2007-05-22 Ollie Wild <aaw@google.com> |
5080 | ||
5081 | * decl.c (duplicate_decls): Verify namespace names are unique. | |
5082 | ||
5c113154 MM |
5083 | 2007-05-21 Mark Mitchell <mark@codesourcery.com> |
5084 | ||
5085 | * decl.c (cxx_maybe_build_cleanup): Handle | |
5086 | __attribute__((cleanup)). | |
5087 | ||
7060db96 MLI |
5088 | 2007-05-19 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
5089 | ||
5090 | * cvt.c (cp_convert_and_check): Don't check warnings if the | |
5091 | conversion failed. | |
5092 | ||
8d5b1b67 GK |
5093 | 2007-05-18 Geoffrey Keating <geoffk@apple.com> |
5094 | ||
5095 | * mangle.c (write_real_cst): Use 'unsigned long' for %lx. | |
5096 | ||
9c49a5e4 PC |
5097 | 2007-05-14 Paolo Carlini <pcarlini@suse.de> |
5098 | ||
5099 | PR c++/29928 | |
5100 | * rtti.c (get_tinfo_decl_dynamic, get_typeid): Try to complete the | |
5101 | type only if is a class type (5.2.8/4). | |
5102 | ||
719bb4e3 | 5103 | 2007-05-14 Rafael Ávila de Espíndola <espindola@google.com> |
ca5ba2a3 RAE |
5104 | |
5105 | * cp-objcp-common.h (LANG_HOOKS_UNSIGNED_TYPE): Remove. | |
5106 | * decl.c (grokdeclarator): Use unsigned_type_for instead of | |
5107 | c_common_unsigned_type. | |
5108 | ||
79bedddc SR |
5109 | 2007-05-11 Silvius Rus <rus@google.com> |
5110 | ||
b97d8153 | 5111 | * typeck.c (build_indirect_ref): Add call to |
79bedddc SR |
5112 | strict_aliasing_warning. |
5113 | (build_reinterpret_cast_1): Condition call to | |
056dd1af | 5114 | strict_aliasing_warning. |
79bedddc | 5115 | |
7be82279 JH |
5116 | 2007-05-11 Jan Hubicka <jh@suse.cz> |
5117 | ||
5118 | * semantics.c (expand_or_defer_fn): Do not call c_record_cdtor_fn. | |
5119 | * decl2.c (start_objects): ctors and dtors are no longer public. | |
5120 | (cp_write_global_declarations): Do not call c_build_cdtor_fns. | |
056dd1af | 5121 | |
ee72fa38 AP |
5122 | 2007-05-07 Andrew Pinski <andrew_pinski@playstation.sony.com> |
5123 | ||
5124 | * typeck.c (build_unary_op): Remove code that used to | |
5125 | handle non lvalue increments/decrements. | |
5126 | ||
841cc7da MS |
5127 | 2007-05-07 Mike Stump <mrs@apple.com> |
5128 | ||
5129 | * parser.c (check_empty_body): Add. | |
5130 | (cp_parser_iteration_statement): Add call to check_empty_body. | |
5131 | ||
a2aa65f0 GK |
5132 | 2007-05-05 Geoffrey Keating <geoffk@apple.com> |
5133 | ||
5134 | PR 31775 | |
5135 | * mangle.c (write_mangled_name): Mangle static variable names. | |
5136 | (write_unqualified_name): Use local-source-name for | |
5137 | namespace-scope static variables. | |
5138 | ||
820b51ae DM |
5139 | 2007-05-04 Dirk Mueller <dmueller@suse.de> |
5140 | ||
5141 | * cp-tree.h (DECL_MAIN_P): only if -ffreestanding is | |
5142 | not in effect. | |
5143 | ||
ba992967 SP |
5144 | 2007-05-02 Seongbae Park <seongbae.park@gmail.com> |
5145 | ||
5146 | PR c++/31663 | |
056dd1af | 5147 | * decl2.c (constrain_class_visibility): |
ba992967 SP |
5148 | Use strip_pointer_or_array_types instead of strip_array_types. |
5149 | ||
70ec16f7 AP |
5150 | 2007-04-28 Andrew Pinski <andrew_pinski@playstation.sony.com> |
5151 | ||
5152 | PR C++/30221 | |
5153 | * decl.c (reshape_init_r): Don't reshape the first element if it | |
5154 | is a pointer to member function. | |
5155 | ||
631ee856 SB |
5156 | 2007-04-27 Simon Baldwin <simonb@google.com> |
5157 | ||
5158 | * decl.c (grokparms): Changed message format from %qD to %qE. | |
5159 | ||
4af96f9f DG |
5160 | 2007-04-27 Douglas Gregor <doug.gregor@gmail.com> |
5161 | ||
5162 | * error.c (maybe_warn_variadic_templates): Variadic templates are | |
056dd1af L |
5163 | now in C++0x, so only warn about them in C++98 mode. |
5164 | ||
d333b74f AP |
5165 | 2007-04-26 Andrew Pinski <andrew_pinski@playstation.sony.com> |
5166 | ||
5167 | PR C++/30016 | |
5168 | * typeck.c (build_reinterpret_cast_1): Only allow conversion to | |
5169 | integeral types from vectors types. | |
5170 | ||
6f719560 JJ |
5171 | 2007-04-26 Jakub Jelinek <jakub@redhat.com> |
5172 | ||
5173 | PR c++/31598 | |
5174 | * semantics.c (finish_omp_clauses): Don't create CP_OMP_CLAUSE_INFO | |
5175 | for type dependent OMP_CLAUSE_DECLs. | |
5176 | ||
b8063b29 MM |
5177 | 2007-04-24 Mark Mitchell <mark@codesourcery.com> |
5178 | ||
fb0b79e5 | 5179 | PR c++/31338 |
b8063b29 MM |
5180 | * cp-tree.h (ARITHMETIC_TYPE): Include COMPLEX_TYPE. |
5181 | * typeck.c (type_after_usual_arithmetic_conversions): Adjust, as | |
5182 | COMPLEX_TYPE is now an ARITHMETIC_TYPE. | |
5183 | * init.c (build_zero_init): Adjust, as | |
5184 | COMPLEX_TYPE is now a SCALAR_TYPE. | |
5185 | * typeck2.c (digest_init): Allow brace-enclosed initializers for | |
5186 | COMPLEX_TYPE, even though that is now a SCALAR_TYPE. | |
5187 | ||
b29441ec PC |
5188 | 2007-04-25 Paolo Carlini <pcarlini@suse.de> |
5189 | ||
5190 | * semantics.c (classtype_has_nothrow_copy_or_assign_p): Adjust | |
5191 | per N2255; rename as classtype_has_nothrow_assign_or_copy_p. | |
5192 | (trait_expr_value): Adjust. | |
5193 | ||
0d83bf5a SB |
5194 | 2007-04-23 Simon Baldwin <simonb@google.com> |
5195 | ||
5196 | * decl.c (grokparms): Added new error for duplicate function | |
5197 | parameters names in function prototypes, to match gcc behavior. | |
5198 | ||
09191b7e JH |
5199 | 2007-04-23 Jan Hubicka <jh@suse.cz> |
5200 | ||
b97d8153 | 5201 | * decl2.c (finish_objects): Do not call target constructor/destructor |
09191b7e JH |
5202 | bits dirrectly. |
5203 | ||
3d95caa4 AP |
5204 | 2007-04-21 Andrew Pinski <andrew_pinski@playstation.sony.com> |
5205 | ||
5206 | * cp-tree.h (lang_tree_node): Use GENERIC_NEXT | |
5207 | instead of checking GIMPLE_STMT_P in chain_next. | |
5208 | ||
431ed7a1 MM |
5209 | 2007-04-17 Mark Mitchell <mark@codesourcery.com> |
5210 | ||
5211 | PR c++/31513 | |
5212 | * call.c (convert_for_arg_passing): Convert bitfields to their | |
5213 | declared types. | |
5214 | ||
f01ec37d SM |
5215 | 2007-04-17 Simon Martin <simartin@users.sourceforge.net> |
5216 | ||
5217 | PR c++/31517 | |
5218 | * pt.c (value_dependent_expression_p): Handle MODOP_EXPRs. | |
5219 | ||
fe24078a SP |
5220 | 2007-04-16 Seongbae Park <seongbae.park@gmail.com> |
5221 | ||
5222 | PR c++/29365 | |
b97d8153 | 5223 | * decl2.c (constrain_class_visibility): |
fe24078a SP |
5224 | Do not warn about the use of anonymous namespace in the main input file. |
5225 | ||
cac4ddf0 MM |
5226 | 2007-04-15 Mark Mitchell <mark@codesourcery.com> |
5227 | ||
5228 | * cp-tree.h (current_template_parms): Fix typo in comment. | |
5229 | ||
a57a55de KH |
5230 | 2007-04-15 Kazu Hirata <kazu@codesourcery.com> |
5231 | ||
5232 | * cp-tree.h, error.c: Fix comment typos. | |
5233 | ||
44ba4c4e JM |
5234 | 2007-04-13 Jason Merrill <jason@redhat.com> |
5235 | ||
5236 | PR c++/31074 | |
5237 | * call.c (reference_binding): Add c_cast_p parm. If true, | |
5238 | add quals to TO as needed to make it reference-compatible. | |
5239 | ||
ffd34392 JH |
5240 | 2007-04-11 Jan Hubicka <jh@suse.cz> |
5241 | ||
b97d8153 | 5242 | * class.c (convert_to_base_statically): Fold produced tree; verify |
ffd34392 JH |
5243 | that we are not processing template_decl. |
5244 | ||
a607b96e MM |
5245 | 2007-04-09 Mark Mitchell <mark@codesourcery.com> |
5246 | ||
5247 | PR c++/31449 | |
5248 | * class.c (build_base_path): Ensure that the converted pointer has | |
5249 | the same cv-qualification as the input. | |
5250 | ||
ea798d0f PC |
5251 | 2007-04-09 Paolo Carlini <pcarlini@suse.de> |
5252 | ||
5253 | * tree.c (cp_tree_equal): Deal with TRAIT_EXPR. | |
5254 | ||
cb9c159d SB |
5255 | 2007-04-08 Steven Bosscher <steven@gcc.gnu.org> |
5256 | ||
5257 | * cp-objcp-common.h (LANG_HOOKS_TREE_INLINING_ADD_PENDING_FN_DECLS): | |
5258 | Do not set it. | |
5259 | (LANG_HOOKS_TREE_INLINING_ANON_AGGR_TYPE_P): Do not set it. | |
5260 | * tree.c (cp_add_pending_fn_decls): Remove. | |
5261 | * cp-tree.h (cp_add_pending_fn_decls): Remove prototype. | |
5262 | ||
270c60bb DB |
5263 | 2007-04-07 Daniel Berlin <dberlin@dberlin.org> |
5264 | ||
5265 | Revert change removing staticp. | |
5266 | ||
1df918ac DB |
5267 | 2007-04-06 Daniel Berlin <dberlin@dberlin.org> |
5268 | ||
5269 | * cp-objcp-common.c (cxx_staticp): Remove. | |
5270 | * cp-objcp-common.h (LANG_HOOKS_STATICP): Remove. | |
056dd1af | 5271 | * cp-tree.h (cxx_staticp): |
1df918ac | 5272 | |
6acd8838 DS |
5273 | 2007-04-04 Danny Smith <dannysmith.users.sourceforge.net> |
5274 | ||
5275 | * class.c (check_for_override): Don't remove dllmport attribute | |
5276 | of virtual methods. | |
5277 | ||
df3473fa JJ |
5278 | 2007-04-03 Jakub Jelinek <jakub@redhat.com> |
5279 | ||
5280 | PR c++/30847 | |
5281 | * typeck.c (build_modify_expr): For COND_EXPR on LHS, if RHS has void | |
5282 | type issue error and return early. | |
5283 | ||
c3b7031d JM |
5284 | 2007-03-30 Jason Merrill <jason@redhat.com> |
5285 | ||
5286 | PR c++/31187 | |
5287 | * typeck.c (cp_type_readonly): New fn. | |
5288 | * cp-tree.h: Declare it. | |
5289 | * decl.c (start_decl): Set implicit DECL_THIS_STATIC here. | |
5290 | (cp_finish_decl): Not here. | |
5291 | ||
6be42dd4 RG |
5292 | 2007-03-31 Richard Guenther <rguenther@suse.de> |
5293 | ||
5294 | * optimize.c (maybe_clone_body): Replace splay-tree usage by | |
5295 | pointer-map. | |
5296 | ||
d393153e DG |
5297 | 2007-03-31 Douglas Gregor <doug.gregor@gmail.com> |
5298 | ||
5299 | PR c++/31138 | |
5300 | PR c++/31140 | |
5301 | PR c++/31141 | |
5302 | * parser.c (declarator_can_be_parameter_pack): New. | |
5303 | (cp_parser_template_parameter): Only parse the `...' if the | |
5304 | declarator can be a parameter pack. | |
5305 | (cp_parser_parameter_declaration): Ditto. Also, handle when TYPE | |
5306 | is NULL. | |
5307 | * pt.c (find_parameter_packs_r): Look into the bounds on integer | |
056dd1af | 5308 | types (they could be used as array bounds). |
d393153e DG |
5309 | (check_for_bare_parameter_packs): Deal with TEMPLATE_PARM_INDEX. |
5310 | (tsubst_pack_expansion): Handle failure to expand parameter | |
5311 | packs. | |
056dd1af | 5312 | |
cb68ec50 PC |
5313 | 2007-03-30 Paolo Carlini <pcarlini@suse.de> |
5314 | ||
5315 | PR c++/26099 | |
5316 | * cp-tree.h (enum cp_trait_kind, struct tree_trait_expr, | |
5317 | TRAIT_EXPR_TYPE1, TRAIT_EXPR_TYPE2, TRAIT_EXPR_KIND): Add. | |
5318 | (enum cp_tree_node_structure_enum, union lang_tree_node): Update. | |
5319 | (CLASS_TYPE_NON_UNION_P): Add. | |
5320 | (struct lang_type_class): Add has_complex_dflt. | |
5321 | (TYPE_HAS_COMPLEX_DFLT, TYPE_HAS_TRIVIAL_DFLT): Add. | |
5322 | (locate_copy, locate_ctor, locate_dtor, finish_trait_expr): Declare. | |
5323 | * cp-tree.def: Add TRAIT_EXPR. | |
5324 | * cp-objcp-common.c (cp_tree_size): Add TRAIT_EXPR case. | |
5325 | * lex.c (struct resword): Add __has_nothrow_assign, | |
5326 | __has_nothrow_constructor, __has_nothrow_copy, __has_trivial_assign, | |
5327 | __has_trivial_constructor, __has_trivial_copy, | |
5328 | __has_trivial_destructor, __has_virtual_destructor, __is_abstract, | |
5329 | __is_base_of, __is_class, __is_convertible_to, __is_empty, __is_enum, | |
5330 | __is_pod, __is_polymorphic, __is_union. | |
5331 | * parser.c (cp_parser_primary_expression): Deal with the new RIDs. | |
5332 | (cp_parser_trait_expr): New. | |
5333 | * semantics.c (finish_trait_expr, trait_expr_value | |
5334 | classtype_has_nothrow_copy_or_assign_p): New. | |
5335 | * method.c (locate_copy, locate_ctor, locate_dtor): Do not define | |
5336 | as static. | |
5337 | * decl.c (cp_tree_node_structure): Add TRAIT_EXPR. | |
5338 | * class.c (check_bases, check_field_decl, check_bases_and_members): | |
5339 | Deal with TYPE_HAS_COMPLEX_DFLT (t) too. | |
5340 | * pt.c (uses_template_parms, tsubst_copy_and_build, | |
5341 | value_dependent_expression_p, type_dependent_expression_p): Deal with | |
5342 | TRAIT_EXPR. | |
5343 | * tree.c (cp_walk_subtrees): Deal with TRAIT_EXPR. | |
5344 | ||
2a42f4aa RG |
5345 | 2007-03-29 Richard Guenther <rguenther@suse.de> |
5346 | ||
5347 | * tree.c (cp_walk_subtrees): Do not set input_location. | |
5348 | ||
71aea5f2 SM |
5349 | 2007-03-28 Simon Martin <simartin@users.sourceforge.net> |
5350 | ||
5351 | PR c++/29077 | |
5352 | * decl.c (grokfndecl): Properly setup decl if it is a constructor or a | |
5353 | destructor. | |
5354 | ||
a2ca1ab2 DG |
5355 | 2007-03-28 Douglas Gregor <doug.gregor@gmail.com> |
5356 | ||
5357 | * parser.c (struct cp_parser): Update comment for | |
5358 | greater_than_is_operator_p. | |
5359 | (cp_parser_primary_expression): In C++0x mode, a cast operator can | |
5360 | be terminated with a `>>' token when !GREATER_THAN_IS_OPERATOR_P. | |
5361 | (TOKEN_PRECEDENCE): In C++0x mode, `>>' is treated like `>' when | |
5362 | !GREATER_THAN_IS_OPERATOR_P. | |
5363 | (cp_parser_binary_expression): When -Wc++0x-compat, warn about | |
5364 | `>>' operators that will become two `>' tokens in C++0x. | |
5365 | (cp_parser_parameter_declaration): Treat `>>' like `>' in C++0x | |
5366 | mode, allowing it to terminate default arguments. | |
5367 | (cp_parser_enclosed_template_argument_list): In C++0x mode, treat | |
5368 | `>>' like two consecutive `>' tokens. | |
5369 | (cp_parser_skip_to_end_of_template_parameter_list): Ditto. | |
5370 | (cp_parser_next_token_ends_template_argument_p): In C++0x, `>>' | |
5371 | ends a template argument. | |
5372 | ||
9b7dd5e8 DG |
5373 | 2007-03-28 Douglas Gregor <doug.gregor@gmail.com> |
5374 | ||
5375 | * decl.c (redeclaration_error_message): Complain when redeclaring | |
5376 | a friend function with default template arguments (C++0x mode only). | |
5377 | * cp-tree.h (check_default_tmpl_args): Declare. | |
5378 | * pt.c (check_default_tmpl_args): In C++0x mode, permit default | |
5379 | template arguments in function templates. Add support for checking | |
5380 | the default template arguments of friend templates. | |
5381 | (push_template_decl_real): Fix call to check_default_tmpl_args. | |
5382 | (type_unification_real): If a template parameter has not been | |
5383 | deduced but provides a default template argument, substitute into | |
5384 | that default template argument. | |
5385 | * parser.c (cp_parser_init_declarator): When declaring (but not | |
5386 | defining!) a function template in C++0x mode, check for default | |
5387 | template arguments. | |
5388 | ||
771026dd DG |
5389 | 2007-03-28 Douglas Gregor <doug.gregor@gmail.com> |
5390 | ||
5391 | PR c++/29993 | |
5392 | * decl.c (grokdeclarator): Deal with cv-qualified function type | |
5393 | typedefs in the same way for member and non-member functions. | |
5394 | ||
df12b78f DM |
5395 | 2007-03-26 Dirk Mueller <dmueller@suse.de> |
5396 | ||
5397 | * parser.c (cp_parser_member_declaration): Pedwarn | |
5398 | about stray semicolons after member declarations. | |
5399 | ||
912291ca PC |
5400 | 2007-03-26 Paolo Carlini <pcarlini@suse.de> |
5401 | ||
5402 | PR c++/30500 | |
5403 | * pt.c (instantiate_decl): Set in_system_header. | |
5404 | ||
8b84995a MM |
5405 | 2007-03-22 Mark Mitchell <mark@codesourcery.com> |
5406 | ||
03c17ccd MM |
5407 | * cp-tree.h (current_tempalte_parms): Improve documentation. |
5408 | * pt.c (current_template_args): Likewise. | |
5409 | ||
8b84995a MM |
5410 | PR c++/30863 |
5411 | * parser.c (cp_parser_parse_and_diagnose_invalid_type_name): Do | |
5412 | not consume tokens when failing. | |
5413 | ||
725d6b87 MM |
5414 | 2007-03-22 Jim Wilson <wilson@specifix.com> |
5415 | Mark Mitchell <mark@codesourcery.com> | |
5416 | ||
5417 | PR c++/31273 | |
5418 | * call.c (standard_conversion): Use type_decays_to. Keep FCODE | |
5419 | consistent with FROM. | |
5420 | ||
5a023baa GDR |
5421 | 2007-03-22 Gabriel Dos Reis <gdr@integrable-solutions.net> |
5422 | ||
5423 | * error.c (dump_expr): Handle dependent names that designate types. | |
5424 | * cxx-pretty-print.c (pp_cxx_unqualified_id): Handle TYPENAME_TYPE. | |
5425 | ||
a757b5c5 KH |
5426 | 2007-03-17 Kazu Hirata <kazu@codesourcery.com> |
5427 | ||
5428 | * cp-tree.def, parser.c, pt.c: Fix comment typos. | |
5429 | ||
07231d4f MLI |
5430 | 2007-03-16 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
5431 | ||
5432 | * cvt.c (cp_convert_and_check) : Define. | |
5433 | * cp-tree.h (cp_convert_and_check): Declare. | |
5434 | * call.c (convert_conversion_warnings): Rename to | |
5435 | conversion_null_warnings. The warning for floating-point to | |
5436 | integer is handled by convert_and_check in convert_like_real. | |
5437 | (convert_like_real): convert_conversion_warnings was renamed as | |
5438 | conversion_null_warnings. | |
5439 | * typeck.c (build_binary_op): Use cp_convert_and_check to warn for | |
5440 | overflow and changes of value during conversion. | |
5441 | ||
2ce88bea MLI |
5442 | 2007-03-15 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
5443 | ||
5444 | PR c++/30891 | |
5445 | * parser.c (cp_parser_statement): If 'namespace' is found, this | |
5446 | only can be a namespace alias definition, so parse it now. | |
5447 | (cp_parser_namespace_alias_definition): if we find an open brace | |
5448 | instead of '=', then this is actually a misplaced namespace | |
5449 | definition. | |
056dd1af | 5450 | |
9b439fe1 MLI |
5451 | 2007-03-15 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
5452 | ||
5453 | PR c++/24924 | |
5454 | * decl.c (cxx_init_decl_processing): Move command-line options | |
5455 | processing to c-opts.c. | |
056dd1af | 5456 | |
30bcc028 DG |
5457 | 2007-03-15 Douglas Gregor <doug.gregor@gmail.com> |
5458 | ||
5459 | * ptree.c (cxx_print_type): Use formatting markup for integers | |
5460 | when printing template parameter index/level/orig level. | |
5461 | (cxx_print_xnode): Ditto. | |
5462 | * cp-tree.h (TEMPLATE_PARM_PARAMETER_PACK): Use TREE_LANG_FLAG_0. | |
5463 | (struct template_parm_index_s): Remove the PARAMETER_PACK member. | |
5464 | Make INDEX, LEVEL, and ORIG_LEVEL integers instead of | |
5465 | HOST_WIDE_INTs. | |
5466 | (struct saved_scope): Make X_PROCESSING_TEMPLATE_DECL an int, | |
5467 | rather than a HOST_WIDE_INT. | |
5468 | Turn X_PROCESSING_EXPLICIT_INSTANTIATION, SKIP_EVALUATION, and | |
5469 | NEED_POP_FUNCTION_CONTEXT into bool bitfields; reorder fields for | |
5470 | better bit-packing. | |
5471 | (struct language_function): Make RETURNS_VALUE, RETURNS_NULL, | |
5472 | RETURNS_ABNORMALLY, IN_FUNCTION_TRY_HANDLER, and | |
5473 | IN_BASE_INITIALIZER bool bitfields. | |
5474 | (struct cp_declarator): Make KIND a 4-bit field. Make | |
5475 | PARAMETER_PACK_P a bool bitfield just after KIND. | |
5476 | * pt.c (uses_parameter_packs): Destroy the pointer set. | |
5477 | (make_pack_expansion): Ditto. | |
5478 | (check_for_bare_parameter_packs): Ditto. | |
5479 | * name-lookup.c (push_to_top_level): Make need_pop a bool value. | |
056dd1af | 5480 | |
344bd5a8 AP |
5481 | 2007-03-14 Andrew Pinski <andrew_pinski@playstation.sony.com> |
5482 | ||
5483 | PR c++/31165 | |
5484 | * call.c (convert_default_arg): Instead of copying the node, | |
5485 | unshare it. | |
5486 | ||
1f7f19c4 DM |
5487 | 2007-03-15 Dirk Mueller <dmueller@suse.de> |
5488 | ||
5489 | PR c++/30860 | |
5490 | * call.c (convert_conversion_warnings): New.. | |
5491 | (convert_like_real): .. factored out from here. | |
5492 | (convert_conversion_warnings): Add warning about | |
5493 | false being converted to NULL in argument passing. | |
5494 | ||
62e00e94 DM |
5495 | 2007-03-14 Dirk Mueller <dmueller@suse.de> |
5496 | ||
b97d8153 | 5497 | * semantics.c (c_finish_if_stmt): Call empty_if_body_warning. |
62e00e94 DM |
5498 | (finish_do_body): Warn about empty body in do/while statement. |
5499 | ||
286d12f9 MLI |
5500 | 2007-03-14 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
5501 | ||
5502 | * class.c (warn_hidden): Add OPT_Woverloaded_virtual to warning. | |
056dd1af | 5503 | |
2e9cb75e MLI |
5504 | 2007-03-14 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
5505 | ||
5506 | PR c/21438 | |
5507 | * typeck.c (build_binary_op): Call warn_for_div_zero instead of | |
5508 | warning. | |
056dd1af | 5509 | |
403d4851 AO |
5510 | 2007-03-13 Alexandre Oliva <aoliva@redhat.com> |
5511 | ||
b97d8153 | 5512 | * repo.c (init_repo): Initialize random_seed saved options. |
403d4851 AO |
5513 | (finish_repo): Adjust. |
5514 | ||
4844b167 MM |
5515 | 2007-03-13 Mark Mitchell <mark@codesourcery.com> |
5516 | ||
5517 | PR bootstrap/30899 | |
5518 | * Make-lang.in (doc/g++.1): Use $< to specify the location from | |
5519 | which to copy. | |
5520 | ||
50d50fc7 SP |
5521 | 2007-03-12 Seongbae Park <seongbae.park@gmail.com> |
5522 | ||
5523 | * decl.c (compute_array_index_type): New warning flag warn_vla. | |
5524 | ||
3026f2df MM |
5525 | 2007-03-12 Mark Mitchell <mark@codesourcery.com> |
5526 | ||
5527 | PR c++/30108 | |
5528 | * call.c (convert_default_arg): Copy non-constant arguments. | |
5529 | ||
3c38f0ff MM |
5530 | 2007-03-11 Mark Mitchell <mark@codesourcery.com> |
5531 | ||
5532 | PR c++/31038 | |
5533 | * parser.c (cp_parser_postfix_expression): Disallow compound | |
5534 | literals in constant expressions. | |
5535 | ||
5536 | PR c++/30328 | |
5537 | * semantics.c (finish_typeof): Use unlowered_expr_type. | |
056dd1af | 5538 | |
f9aa54d3 MM |
5539 | 2007-03-10 Mark Mitchell <mark@codesourcery.com> |
5540 | ||
5541 | PR c++/30274 | |
5542 | * cp-tree.h (unlowered_expr_type): New function. | |
5543 | * typeck.c (is_bitfield_expr_with_lowered_type): Handle | |
5544 | COMPOUND_EXPR, MODIFY_EXPR, and SAVE_EXPR. | |
5545 | (unlowered_expr_type): New function. | |
5546 | (build_unary_op): Disallow predecrements of bool bitfields. | |
5547 | * call.c (build_conditional_expr): Use unlowered_expr_type. | |
5548 | * pt.c (type_unification_real): Likewise. | |
5549 | ||
5d80a306 DG |
5550 | 2007-03-09 Douglas Gregor <doug.gregor@gmail.com> |
5551 | ||
5552 | PR c++/20599 | |
5553 | * typeck.c (check_return_expr): Check for bare parameter packs. | |
5554 | (comptypes): Compare template parameter packs and | |
5555 | type pack expansions. | |
5556 | * decl.c (grokdeclarator): Deal with the declaration of function | |
5557 | parameter packs. | |
5558 | (grokparms): Verify that the (optional) function parameter pack is | |
5559 | at the end of the parameter list. | |
5560 | (xref_basetypes): Handle pack expansions in the base class. | |
5561 | (cp_tree_node_structure): Handle ARGUMENT_PACK_SELECT. | |
5562 | * cp-tree.def (TYPE_ARGUMENT_PACK): New. | |
5563 | (NONTYPE_ARGUMENT_PACK): New. | |
5564 | (TYPE_PACK_EXPANSION): New. | |
5565 | (EXPR_PACK_EXPANSION): New. | |
5566 | (ARGUMENT_PACK_SELECT): New. | |
5567 | * cp-objcp-common.c (cp_tree_size): Compute size of | |
5568 | (NON)TYPE_ARGUMENT_PACK, (TYPE|EXPR)_PACK_EXPANSION, and | |
5569 | ARGUMENT_PACK_SELECT. | |
5570 | * error.c (dump_template_argument): Print template argument packs. | |
5571 | (dump_template_argument_list): Ditto. | |
5572 | (dump_template_parameter): Dump `...' for template type parameter | |
5573 | packs. | |
5574 | (dump_type): Dump TYPE_PACK_EXPANSION nodes. | |
5575 | (dump_parameters): Print function parameter packs. | |
5576 | (dump_template_parms): Print template argument packs. | |
5577 | (dump_expr): Dump EXPR_PACK_EXPANSION nodes. | |
5578 | (maybe_warn_variadic_templates): New. | |
5579 | * operators.def: Add ellipsis operator for EXPR_PACK_EXPANSION. | |
5580 | * tree.c (cp_walk_subtrees): Walk BASELINK, TYPE_ARGUMENT_PACK, | |
5581 | NONTYPE_ARGUMENT_PACK, TYPE_PACK_EXPANSION, EXPR_PACK_EXPANSION, | |
056dd1af | 5582 | CAST_EXPR. |
5d80a306 DG |
5583 | * mangle.c (write_type): Mangle TYPE_PACK_EXPANSION. |
5584 | (write_template_arg): Write argument packs as separate arguments. | |
5585 | * cp-tree.h (struct template_parm_index_s): Add flag that | |
5586 | indicates that the template parameter is actually a parameter | |
5587 | pack. | |
5588 | (struct tree_argument_pack_select): New. | |
5589 | (enum cp_tree_node_structure_enum): Add TS_CP_ARGUMENT_PACK_SELECT. | |
5590 | (union lang_tree_node): Add argument_pack_select. | |
5591 | (FUNCTION_PARAMETER_PACK_P): New. | |
5592 | (PACK_EXPANSION_P): New. | |
5593 | (PACK_EXPANSION_PATTERN): New. | |
5594 | (SET_PACK_EXPANSION_PATTERN): New. | |
5595 | (PACK_EXPANSION_PARAMETER_PACKS): New. | |
5596 | (ARGUMENT_PACK_P): New. | |
5597 | (ARGUMENT_PACK_ARGS): New. | |
5598 | (SET_ARGUMENT_PACK_ARGS): New. | |
5599 | (ARGUMENT_PACK_INCOMPLETE_P): New. | |
5600 | (ARGUMENT_PACK_EXPLICIT_ARGS): New. | |
5601 | (TEMPLATE_PARM_PARAMETER_PACK): New. | |
5602 | (TEMPLATE_TYPE_PARAMETER_PACK): New. | |
5603 | (ARGUMENT_PACK_SELECT_FROM_PACK): New. | |
5604 | (ARGUMENT_PACK_SELECT_INDEX): New. | |
5605 | (ARGUMENT_PACK_SELECT_ARG): New. | |
5606 | (struct cp_declarator): Add parameter_pack_p flag. | |
5607 | (maybe_warn_variadic_templates): Declare. | |
5608 | (process_template_parm): Add bool parameter IS_PARAMETER_PACK, to | |
056dd1af | 5609 | indicate a template parameter pack. |
5d80a306 DG |
5610 | (uses_parameter_packs): Declare. |
5611 | (template_parameter_pack_p): Declare. | |
5612 | (template_parms_variadic_p): Declare. | |
5613 | (make_pack_expansion): Declare. | |
5614 | (check_for_bare_parameter_packs): Declare. | |
5615 | * cxx-pretty-print.c (pp_cxx_unary_expression): Print | |
056dd1af | 5616 | sizeof... expressions. |
5d80a306 DG |
5617 | (pp_cxx_expression): Print pack expansions and non-type argument |
5618 | packs. | |
056dd1af | 5619 | (pp_cxx_exception_specification): Print pack expansions. |
5d80a306 DG |
5620 | (pp_cxx_direct_declarator): Print ellipsis for parameter packs. |
5621 | (pp_cxx_ctor_initializer): Print pack expansions. | |
5622 | (pp_cxx_type_id): Print pack expansions. | |
5623 | (pp_cxx_template_argument_list): Print argument packs. | |
5624 | (pp_cxx_template_parameter): Print ellipsis for template parameter | |
5625 | packs. | |
5626 | * pt.c (comp_template_parms): Compare template parameter packs. | |
5627 | (template_parameter_pack_p): New. | |
5628 | (template_parms_variadic_p): New. | |
5629 | (template_args_variadic_p): New. | |
5630 | (make_ith_pack_parameter_name): New. | |
5631 | (struct find_parameter_pack_data): New. | |
5632 | (find_parameter_packs_r): New. | |
5633 | (uses_parameter_packs): New. | |
5634 | (make_pack_expansion): New. | |
5635 | (check_for_bare_parameter_packs): New. | |
5636 | (expand_template_argument_pack): New. | |
5637 | (reduce_template_parm_level): Propagate parameter pack flag. | |
5638 | (process_template_parm): Add is_parameter_pack parameter to state | |
5639 | when the parameter is actually a parameter pack. Create template | |
5640 | parameter packs when is_parameter_pack is true. | |
5641 | (current_template_args): The argument for a template parameter | |
5642 | pack is an argument pack containing a single pack expansion. | |
5643 | (process_partial_specialization): When checking that non-type | |
5644 | argument expressions do not involve template parameters, loop over | |
5645 | the arguments in argument packs separately. | |
5646 | (push_template_decl_real): Check that the type of the declaration | |
5647 | does not have any bare parameter packs. Check that primary | |
5648 | templates have no more than one parameter pack, and that it comes | |
5649 | at the end of the template parameter list. | |
5650 | (convert_template_argument): Handle coercions for pack expansion | |
5651 | expressions by coercing the pattern then rebuilding the expansion. | |
5652 | (coerce_template_parms): When coercing the arguments for a | |
5653 | variadic template, pack "extra" arguments into an argument pack. | |
5654 | (coerce_template_template_parms): Cannot coerce between parameter | |
5655 | packs and non-pack parameters. | |
5656 | (template_args_equal): Compare PACK_EXPANSION_P expressions. | |
5657 | (comp_template_args): Expand all template arguments packs before | |
5658 | comparing template argument lists. | |
5659 | (mangle_class_name_for_template): Make argument packs as separate | |
5660 | template arguments. | |
056dd1af | 5661 | (for_each_template_parm_r): No need to handle BASELINK. |
5d80a306 DG |
5662 | (instantiate_class_template): Handle pack expansions in the base |
5663 | class list. | |
5664 | (tsubst_pack_expansion): New. | |
5665 | (tsubst_template_args): Handle substitutions of argument packs and | |
5666 | pack expansion into template argument lists. | |
5667 | (tsubst_decl): Expand function parameter packs into separate | |
5668 | function parameters. | |
5669 | (tsubst_arg_types): Expand a type pack expansion into separate | |
5670 | argument types. | |
5671 | (tsubst_exception_specification): Handle pack expansions in | |
5672 | exception specifiers. | |
056dd1af | 5673 | (tsubst): See through ARGUMENT_PACK_SELECT arguments when |
5d80a306 DG |
5674 | replacing a template parameter with its argument. If we encounter |
5675 | a substitution for an argument pack, just return the parameter | |
056dd1af | 5676 | itself. |
5d80a306 DG |
5677 | (tsubst_copy): sizeof(X...) returns the number of elements in |
5678 | parameter pack X. See through ARGUMENT_PACK_SELECT when the | |
5679 | PARM_DECL is a parameter pack. | |
5680 | (tsubst_expr): Expression pack expansions and argument packs | |
5681 | cannot show up here; they will all be handled through function | |
5682 | calls, sizeof, and template argument lists. | |
5683 | (tsubst_copy_and_build): sizeof(X...) returns the number of | |
5684 | elements in parameter pack X. Handle pack expansions in TREE_LIST | |
5685 | and CONSTRUCTOR nodes. | |
5686 | (fn_type_unification): Handle "incomplete" explicit template | |
5687 | argument lists that specify some of the arguments for a template | |
5688 | parameter pack. | |
5689 | (type_unification_real): Unify arguments against pack expansions. | |
5690 | (template_parm_level_and_index): New, helper function. | |
5691 | (unify_pack_expansion): New. | |
5692 | (unify): Unify argument packs on an argument-by-argument basis, | |
5693 | handling variadic argument packs as well. | |
5694 | (more_specialized_fn): Handle unification of function parameter | |
5695 | packs. All things being equal, prefer non-variadic function | |
5696 | templates to variadic function templates. | |
5697 | (more_specialized_class): Prefer the variadic class template | |
5698 | partial specialization that binds fewer arguments to a parameter | |
5699 | pack. | |
5700 | (regenerate_decl_from_template): Expand function parameter packs | |
5701 | into separate parameters. | |
5702 | (instantiate_decl): Ditto. | |
5703 | (tsubst_initializer_list): Handle pack expansions for base-class | |
5704 | initializers. | |
5705 | (dependent_type_p_r): Determine dependent types in argument packs | |
5706 | and pack expansions. | |
5707 | (value_dependent_expression_p): Determine value-dependence of | |
5708 | non-type argument packs. | |
5709 | (dependent_template_arg_p): Handle argument packs. | |
5710 | * semantics.c (finish_cond): Check for bare parameter packs. | |
5711 | (finish_expr_stmt): Ditto. | |
5712 | (finish_for_expr): Ditto. | |
5713 | (finish_switch_cond): Ditto. | |
5714 | (finish_mem_initializers): Ditto. | |
5715 | * name-lookup.c (arg_assoc_type): Handle pack expansions and | |
5716 | argument packs. | |
5717 | * decl2.c (cp_build_parm_decl): Mark function parameter packs. | |
5718 | * parser.c (make_declarator): Declarator is not an expansion. | |
5719 | (make_pointer_declarator): Transfer parameter pack flag to outer | |
5720 | declarator. | |
5721 | (make_reference_declarator): Ditto. | |
5722 | (make_ptrmem_declarator): Ditto. | |
5723 | (make_call_declarator): Ditto. | |
5724 | (make_array_declarator): Ditto. | |
5725 | (cp_parser_postfix_expression): Allow pack expansion expressions | |
5726 | in the argument list for a call expression. | |
5727 | (cp_parser_parenthesized_expression_list): Add new parameter | |
5728 | ALLOW_EXPANSION_P. When true, parse the ellipsis to mean "expand | |
5729 | into separate arguments." | |
5730 | (cp_parser_new_placement): Allow pack expansion expressions. | |
5731 | (cp_parser_new_initializer): Ditto. | |
5732 | (cp_parser_mem_initializer_list): Allow ellipsis to create a | |
5733 | base-class initializer expansion. | |
5734 | (cp_parser_mem_initializer): Ditto. | |
5735 | (cp_parser_template_parameter_list): Keep track of whether the | |
5736 | template parameter is a template parameter pack. | |
5737 | (cp_parser_template_parameter): Parse the ellipsis to indicate a | |
5738 | template parameter pack. | |
5739 | (cp_parser_type_parameter): Ditto. | |
5740 | (cp_parser_template_argument_list): Parse the ellipsis to indicate | |
5741 | a pack expansion. | |
5742 | (cp_parser_direct_declarator): Parse the ellipsis to indicate that | |
5743 | this declarator is a parameter pack. | |
5744 | (cp_parser_parameter_declaration): The ellipsis does not end the | |
5745 | parameter declaration, because it might be a parameter pack. Parse | |
5746 | the ellipsis to indicate a parameter pack. | |
5747 | (cp_parser_initializer): Allow pack expansions. | |
5748 | (cp_parser_initializer_list): Allow ellipsis to create an | |
5749 | initializer expansion. | |
5750 | (cp_parser_base_clause): Allow ellipsis to create a base specifier | |
5751 | expansion. | |
5752 | (cp_parser_type_id_list): Allow ellipsis to create an exception | |
5753 | specifier expansion. | |
5754 | (cp_parser_attribute_list): Don't allow pack expansions. | |
5755 | (cp_parser_functional_cast): Allow pack expansions. | |
5756 | (cp_parser_sizeof_operand): Allow ellipsis following "sizeof" to | |
5757 | compute the length of a parameter pack. | |
5758 | (cp_parser_next_token_ends_template_argument_p): An ellipsis can | |
5759 | end a template argument. | |
5760 | * tree.c (cp_walk_subtrees): Walk BASELINK, TYPE_ARGUMENT_PACK, | |
5761 | NONTYPE_ARGUMENT_PACK, TYPE_PACK_EXPANSION, EXPR_PACK_EXPANSION, | |
056dd1af | 5762 | CAST_EXPR. |
5d80a306 | 5763 | |
63a08740 DM |
5764 | 2007-03-09 Dirk Mueller <dmueller@suse.de> |
5765 | ||
b97d8153 | 5766 | * call.c (build_new_op): Call warn_logical_operator. |
63a08740 | 5767 | |
be349cac | 5768 | 2007-03-08 Volker Reichelt <v.reichelt@netcologne.de> |
cc891727 | 5769 | |
1916c916 VR |
5770 | PR c++/30852 |
5771 | * semantics.c (finish_offsetof): Handle COMPOUND_EXPR. | |
5772 | ||
cc891727 VR |
5773 | PR c++/30534 |
5774 | * pt.c (any_template_arguments_need_structural_equality_p): | |
5775 | Robustify. | |
5776 | ||
ab53bae2 AO |
5777 | 2007-03-08 Alexandre Oliva <aoliva@redhat.com> |
5778 | ||
5779 | * decl.c (grokdeclarator): Disable warnings for anonymous | |
5780 | bitfields. | |
5781 | ||
be349cac | 5782 | 2007-03-05 Volker Reichelt <v.reichelt@netcologne.de> |
fabb00fc VR |
5783 | |
5784 | * typeck2.c (readonly_error): Always emit a hard error. | |
5785 | Remove last argument. | |
5786 | * cp-tree.h (readonly_error): Adjust prototype. | |
5787 | * semantics.c (finish_asm_stmt): Adjust call to readonly_error. | |
5788 | * typeck.c (build_unary_op): Likewise. | |
5789 | (build_modify_expr): Likewise. | |
5790 | ||
2a2193e0 SM |
5791 | 2007-03-04 Simon Martin <simartin@users.sourceforge.net> |
5792 | ||
5793 | PR c++/30895 | |
5794 | * tree.c (cp_tree_equal): Properly handle COMPLEX_CST trees. | |
5795 | ||
4606b05c MLI |
5796 | 2007-03-03 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
5797 | ||
5798 | PR c++/15787 | |
5799 | * parser.c (struct cp_parser): New IN_IF_STMT. | |
5800 | (cp_parser_statement_seq_opt): Handle an unexpected 'else', | |
5801 | returning if parsing the body of an 'if' statement or issuing an | |
5802 | error and continuing. | |
5803 | (cp_parser_selection_statement): Set IN_IF_STMT bit when parsing | |
5804 | body of 'if'. | |
5805 | (cp_parser_jump_statement): Mask new IN_IF_STMT bit. | |
056dd1af | 5806 | |
49fedf5a SM |
5807 | 2007-03-02 Simon Martin <simartin@users.sourceforge.net> |
5808 | ||
5809 | PR c++/28253 | |
5810 | * class.c (update_vtable_entry_for_fn): Properly handle invalid overriders | |
5811 | for thunks. | |
5812 | ||
f9dedbe3 GK |
5813 | 2007-03-02 Geoffrey Keating <geoffk@apple.com> |
5814 | ||
5815 | * g++spec.c (lang_specific_driver): Add -lstdc++ when compiling | |
5816 | Objective-C++. Don't exit early if -shared-libgcc needs to be | |
5817 | added. | |
5818 | ||
4e223867 MLI |
5819 | 2007-03-02 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
5820 | ||
5821 | * typeck.c (common_base_type): Delete unused function. | |
056dd1af | 5822 | |
7fe3e184 BM |
5823 | 2007-03-01 Brooks Moses <brooks.moses@codesourcery.com> |
5824 | ||
5825 | * Make-lang.in: Add dummy lang.install-pdf target. | |
5826 | ||
41dc91a8 SB |
5827 | 2007-03-01 Simon Baldwin <simonb@google.com> |
5828 | ||
5829 | PR c++/23689 | |
5830 | * decl.c (check_tag_decl): Added new warning for typedef ignored | |
5831 | when it precedes an otherwise valid non-typedef declaration. | |
5832 | ||
94a0dd7b SL |
5833 | 2007-02-28 Sandra Loosemore <sandra@codesourcery.com> |
5834 | ||
5835 | * typeck.c (build_function_call): Store converted arguments | |
5836 | in a stack-allocated array instead of building a list. | |
5837 | (convert_arguments): Store arguments in the array passed in as an | |
5838 | argument, and return the actual number of arguments. | |
5839 | * call.c (build_call): Delete, and replace with... | |
5840 | (build_call_n, build_call_a): New. | |
5841 | (build_op_delete_call): Rewrite to avoid constructing argument lists. | |
5842 | (build_over_call): Store converted arguments in a stack-allocated | |
5843 | array instead of building a list. | |
5844 | (build_cxx_call): Pass arguments in an array instead of as a list. | |
5845 | (build_java_interface_fn_ref): Rewrite to avoid constructing | |
5846 | argument lists. | |
5847 | * tree.h: Update declarations to reflect above changes. | |
5848 | * method.c (use_thunk): Use a stack-allocated array to hold | |
5849 | the arguments instead of a list. | |
5850 | * rtti.c (throw_bad_cast): Update call to cxx_call. | |
5851 | (throw_bad_typeid): Likewise. | |
5852 | (build_dynamic_cast_1): Likewise. | |
5853 | * init.c (build_builtin_delete_call): Use build_call_n. | |
5854 | * decl.c (expand_static_init): Likewise. | |
5855 | * except.c (cp_protect_cleanup_actions): Likewise. | |
5856 | * cp-gimplify.c (genericize_eh_spec_block): Likewise. | |
5857 | (gimplify_must_not_throw_expr): Likewise. | |
5858 | (cxx_omp_apply_fn): Use build_call_a. | |
5859 | ||
57a4c089 MM |
5860 | 2007-02-26 Mark Mitchell <mark@codesourcery.com> |
5861 | ||
5862 | * semantics.c (expand_or_defer_fn): Call c_record_cdtor_fn. | |
5863 | * decl2.c (cp_write_gloabl_declarations): Call c_build_cdtor_fns. | |
5864 | ||
fc8600f9 MM |
5865 | 2007-02-25 Mark Mitchell <mark@codesourcery.com> |
5866 | ||
5867 | * cp-tree.h (static_ctors): Remove. | |
5868 | * cp-tree.h (static_dtors): Likewise. | |
5869 | * cp-objcp-common.c (decl_shadowed_for_var_lookup): Adjust for | |
5870 | refactoring of tree_map hierarchy. | |
5871 | (decl_shadowed_for_var_insert): Likewise. | |
5872 | * semantics.c (expand_body): Use c_expand_body. | |
5873 | (expand_or_defer_fn): Don't update static_ctors or static_dtors. | |
5874 | * decl2.c (static_ctors): Remove. | |
5875 | (static_dtors): Likewise. | |
5876 | (generate_ctor_or_dtor_function): Pass NULL_TREE to | |
5877 | objc_generate_static_init_call. Do not call static_[cd]tors. | |
5878 | (generate_ctor_and_dtor_functions_for_priority): Do not check for | |
5879 | static_[cd]tors. | |
5880 | (cp_write_global_declarations): Likewise. | |
5881 | ||
2ae2031e RG |
5882 | 2007-02-23 Richard Guenther <rguenther@suse.de> |
5883 | ||
5884 | * class.c (note_name_declared_in_class): Make declaration | |
5885 | changes meaning a pedwarn. | |
5886 | ||
a0ad3539 MM |
5887 | 2007-02-22 Michael Matz <matz@suse.de> |
5888 | ||
5889 | PR c++/29433 | |
5890 | * cp-tree.h (TFF_UNQUALIFIED_NAME): New formatting flag. | |
5891 | * error.c (dump_aggr_type, dump_simple_decl, dump_decl, | |
5892 | dump_function_decl): Guard emitting outer scopes by new flag. | |
5893 | * cp-lang.c (cxx_dwarf_name): New function. | |
5894 | (LANG_HOOKS_DWARF_NAME): Define to cxx_dwarf_name. | |
5895 | * pt.c (classtype_mangled_name, mangle_class_name_for_template): | |
5896 | Remove functions. | |
5897 | (push_template_decl_real, lookup_template_class): Remove calls | |
5898 | to above functions. | |
5899 | ||
c88b0c50 MM |
5900 | 2007-02-19 Mark Mitchell <mark@codesourcery.com> |
5901 | ||
5902 | * call.c (build_new_method_call): Ensure that explicit calls of | |
5903 | destructors have type "void". | |
5904 | ||
c116cd05 MLI |
5905 | 2007-02-19 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
5906 | ||
5907 | * typeck.c (build_binary_op): Replace -Wstring-literal-comparison | |
5908 | and -Walways-true with -Waddress. | |
5909 | * cvt.c (convert_to_void): Replace unconditional warning with | |
5910 | -Waddress. | |
5911 | ||
b9704fc5 KH |
5912 | 2007-02-18 Kazu Hirata <kazu@codesourcery.com> |
5913 | ||
5914 | * decl.c, tree.c: Fix comment typos. | |
5915 | ||
76b9a2a1 AP |
5916 | 2007-02-15 Andrew Pinski <andrew_pinski@playstation.sony.com> |
5917 | ||
5918 | PR C++/30158 | |
056dd1af | 5919 | * semantics.c (finish_stmt_expr_expr): Set TREE_TYPE of the |
76b9a2a1 | 5920 | statement expression if we had an error mark node. |
5be014d5 | 5921 | |
5039610b SL |
5922 | 2007-02-15 Sandra Loosemore <sandra@codesourcery.com> |
5923 | Brooks Moses <brooks.moses@codesourcery.com> | |
5924 | Lee Millward <lee.millward@codesourcery.com> | |
5925 | ||
5926 | * cp-tree.def (AGGR_INIT_EXPR): Adjust documentation. | |
5927 | Change class to tcc_vl_exp. | |
5928 | ||
056dd1af L |
5929 | * call.c (build_call): Use build_call_list instead |
5930 | of build3. | |
5039610b | 5931 | (build_over_call): Likewise. |
056dd1af | 5932 | (build_new_method_call): Use build_min_non_dep_call_list |
5039610b SL |
5933 | instead of build_min_non_dep. |
5934 | ||
5935 | * error.c (dump_call_expr_args): New function. | |
5936 | (dump_aggr_init_expr_args): New function. | |
056dd1af | 5937 | (dump_expr) <AGGR_INIT_EXPR, CALL_EXPR, INDIRECT_REF>: Use them. |
5039610b SL |
5938 | Update to use new CALL_EXPR and AGGR_INIT_EXPR accessor macros. |
5939 | ||
5940 | * cvt.c (convert_to_void): Use build_call_array instead | |
5941 | of build3; use new AGGR_INIT_EXPR accessor macros. | |
5942 | ||
5943 | * mangle.c (write_expression): Use TREE_OPERAND_LENGTH | |
5944 | instead of TREE_CODE_LENGTH. | |
5945 | ||
5946 | * dump.c (cp_dump_tree) <AGGR_INIT_EXPR>: Update to use new | |
5947 | AGGR_INIT_EXPR accessor macros. | |
5948 | ||
056dd1af | 5949 | * cp-gimplify.c (cp_gimplify_init_expr): Use |
5039610b SL |
5950 | AGGR_INIT_EXPR_SLOT to set the slot operand. |
5951 | ||
5952 | * cp-tree.h (AGGR_INIT_EXPR_FN): New macro. | |
5953 | (AGGR_INIT_EXPR_SLOT): New macro. | |
5954 | (AGGR_INIT_EXPR_ARG): New macro. | |
5955 | (aggr_init_expr_nargs): New macro. | |
5956 | (AGGR_INIT_EXPR_ARGP): New macro. | |
5957 | (aggr_init_expr_arg_iterator): New. | |
5958 | (init_aggr_init_expr_arg_iterator): New. | |
5959 | (next_aggr_init_expr_arg): New. | |
5960 | (first_aggr_init_expr_arg): New. | |
5961 | (more_aggr_init_expr_args_p): New. | |
5962 | (FOR_EACH_AGGR_INIT_EXPR_ARG): New. | |
5963 | (stabilize_aggr_init): New declaration. | |
5964 | (build_min_non_dep_call_list): Likewise. | |
5965 | ||
5966 | * tree.c (process_aggr_init_operands): New function. | |
5967 | (build_aggr_init_array) New function. | |
5968 | (build_cplus_new): Update to use new CALL_EXPR and | |
5969 | AGGR_INIT_EXPR accessor macros. Replace use of build3 with | |
5970 | build_aggr_init_array. | |
5971 | (build_min_non_dep_call_list) New function. | |
5972 | (build_min_nt): Assert input code parameter is not a variable | |
5973 | length expression class. | |
5974 | (build_min, build_min_non_dep): Likewise. | |
5975 | (cp_tree_equal) <CALL_EXPR>: Iterate through the arguments | |
5976 | to check for equality instead of recursing. Handle tcc_vl_exp | |
5977 | tree code classes. | |
056dd1af | 5978 | (stabilize_call): Update to only handle CALL_EXPRs, not |
5039610b SL |
5979 | AGGR_INIT_EXPRs; use new CALL_EXPR accessor macros. |
5980 | (stabilize_aggr_init): New function. | |
5981 | (stabilize_init): Use it. | |
5982 | ||
5983 | * cxx-pretty-print.c (pp_cxx_postfix_expression) | |
5984 | <AGGR_INIT_EXPR, CALL_EXPR>: Update to use new CALL_EXPR and | |
5985 | AGGR_INIT_EXPR accessor macros and argument iterators. | |
056dd1af | 5986 | |
5039610b | 5987 | * pt.c (tsubst_copy) <CALL_EXPR>: Replace build_nt with |
056dd1af | 5988 | build_vl_exp. Iterate through the operands, recursively |
5039610b SL |
5989 | processing each one. |
5990 | (tsubst_copy_and_build) <CALL_EXPR>: Update to use new | |
5991 | CALL_EXPR accessor macros. | |
5992 | (value_dependent_expression_p) <default>: Handle tcc_vl_exp | |
056dd1af | 5993 | tree code classes. Use TREE_OPERAND_LENGTH instead of |
5039610b SL |
5994 | TREE_CODE_LENGTH. |
5995 | ||
5996 | * semantics.c (finish_call_expr): Use build_nt_call_list | |
5997 | instead of build_nt. | |
056dd1af L |
5998 | (simplify_aggr_init_expr): Update to use new AGGR_INIT_EXPR |
5999 | accessor macros. Use build_call_array to construct the | |
5039610b | 6000 | CALL_EXPR node instead of build3 |
056dd1af L |
6001 | |
6002 | * decl2.c (build_offset_ref_call_from_tree): Use | |
5039610b SL |
6003 | build_nt_call_list and build_min_non_dep_call_list instead |
6004 | of build_min_nt and build_min_non_dep. | |
6005 | ||
6006 | * parser.c (cp_parser_postfix_expression) <CPP_OPEN_PAREN>: | |
6007 | Use build_nt_call_list instead of build_min_nt. | |
6008 | ||
21493102 MLI |
6009 | 2007-02-15 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
6010 | ||
6011 | PR c++/28943 | |
6012 | * call.c (build_conditional_expr): Improve error message. | |
056dd1af | 6013 | |
20af23d3 DM |
6014 | 2007-02-13 Dirk Mueller <dmueller@suse.de> |
6015 | ||
6016 | * friend.c (do_friend): Annotate warning about friend | |
6017 | declarations in templates with OPT_Wnon_template_friend. | |
6018 | Convert informal message from warning() to inform(). | |
6019 | ||
8ea6dfae SM |
6020 | 2007-02-12 Simon Martin <simartin@users.sourceforge.net> |
6021 | Mark Mitchell <mark@codesourcery.com> | |
6022 | ||
6023 | PR c++/14622 | |
6024 | * pt.c (do_decl_instantiation): Detect type mismatches in explicit | |
6025 | instantiations for variables. | |
6026 | ||
27f33b15 MLI |
6027 | 2007-02-12 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
6028 | ||
6029 | PR middle-end/7651 | |
6030 | * cp-gimplify.c (gimplify_expr_stmt): Don't check extra_warnings. | |
6031 | Check warn_unused_value just once. | |
6032 | ||
ba139ba8 MM |
6033 | 2007-02-11 Mark Mitchell <mark@codesourcery.com> |
6034 | ||
6035 | PR c++/26988 | |
6036 | * pt.c (determine_specialization): Use skip_artificial_parms_for. | |
6037 | (fn_type_unificiation): Likewise. | |
6038 | (get_bindings): Likewise. | |
6039 | ||
6040 | o2007-02-06 Mark Mitchell <mark@codesourcery.com> | |
56fd65c7 MM |
6041 | |
6042 | PR target/29487 | |
6043 | * decl.c (finish_function): Use DECL_REPLACEABLE. | |
6044 | * tree.c (cp_cannot_inline_tree_fn): Likewise. | |
6045 | ||
097552fa GDR |
6046 | 2007-02-10 Gabriel Dos Reis <gdr@integrable-solutions.net> |
6047 | ||
6048 | * parser.c (cp_parser_primary_expression): Reformat overly long lines. | |
6049 | ||
8893239d RH |
6050 | 2007-02-10 Richard Henderson <rth@redhat.com>, Jakub Jelinek <jakub@redhat.com> |
6051 | ||
6052 | * decl.c (grokvardecl): Don't error if !have_tls. | |
6053 | (grokdeclarator): Likewise. | |
6054 | * parser.c (cp_parser_omp_threadprivate): Likewise. | |
6055 | ||
e02a048f JJ |
6056 | 2007-02-07 Jakub Jelinek <jakub@redhat.com> |
6057 | ||
6058 | PR c++/30703 | |
6059 | * cp-gimplify.c (cp_genericize_r): Don't dereference invisiref | |
6060 | parameters and result decls in omp clauses. | |
6061 | (cxx_omp_privatize_by_reference): Pass also invisiref PARM_DECLs | |
6062 | by reference. | |
6063 | ||
583c0b05 DM |
6064 | 2007-02-05 Dirk Mueller <dmueller@suse.de> |
6065 | ||
6066 | PR bootstrap/30510 | |
6067 | * parser.c (cp_parser_class_specifier): Always initialize bases. | |
6068 | ||
4fe70b31 PB |
6069 | 2007-02-05 Paolo Bonzini <bonzini@gnu.org> |
6070 | ||
6071 | * cp-tree.h (OMP_ATOMIC_CODE): Delete. | |
6072 | (OMP_ATOMIC_DEPENDENT_P): Rewrite. | |
6073 | * pt.c (tsubst_expr): Adjust for new format of dependent OMP_ATOMIC | |
6074 | expressions. | |
6075 | * semantics.c (finish_omp_atomic): Store a whole expression node | |
6076 | in operand 1, and integer_zero_node in operand 0, for dependent | |
6077 | OMP_ATOMIC. Rewrite to make flow easier to understand. | |
6078 | ||
b10fc6f5 GDR |
6079 | 2007-02-03 Gabriel Dos Reis <gdr@integrable-solutions.net> |
6080 | ||
6081 | * decl.c (grokdeclarator): Use OPT_Wreturn_type instead of 0. | |
6082 | ||
3b426391 KH |
6083 | 2007-02-04 Kazu Hirata <kazu@codesourcery.com> |
6084 | ||
6085 | * class.c, cp-tree.h, decl.c, decl2.c, g++spec.c, init.c, | |
6086 | parser.c, pt.c, tree.c, typeck.c: Follow spelling conventions. | |
6087 | ||
f1283f8f DG |
6088 | 2007-02-03 Douglas Gregor <doug.gregor@gmail.com> |
6089 | ||
056dd1af L |
6090 | * parser.c (cp_lexer_get_preprocessor_token): Attach the C++0x |
6091 | keyword warning to -Wc++0x-compat. | |
6092 | ||
5e32a5cf GDR |
6093 | 2007-02-03 Gabriel Dos Reis <gdr@integrable-solutions.net> |
6094 | ||
6095 | * decl.c (grokdeclarator): Update documentation. | |
6096 | ||
3e66d096 JJ |
6097 | 2007-02-02 Jakub Jelinek <jakub@redhat.com> |
6098 | ||
6099 | PR c++/30536 | |
6100 | * decl.c (grokdeclarator): If __thread is used together with | |
6101 | a storage class other than extern and static, clear thread_p | |
6102 | after issuing diagnostics and fall through to checking the | |
6103 | storage class. | |
6104 | ||
5e203bf8 RS |
6105 | 2007-01-30 Roger Sayle <roger@eyesopen.com> |
6106 | ||
6107 | * error.c (dump_type_suffix): Avoid use of cp_build_binary_op when | |
6108 | calculating the size of an array (to avoid recursive errors). | |
6109 | ||
b9edb4b1 MLI |
6110 | 2007-01-30 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
6111 | ||
6112 | PR c++/24745 | |
6113 | * typeck.c (build_binary_op): Fix logic for warning. Move warning | |
6114 | to -Wpointer-arith. | |
6115 | * call.c (convert_like_real): Don't warn when converting to | |
6116 | boolean type. | |
056dd1af | 6117 | |
c616e51b MLI |
6118 | 2007-01-29 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
6119 | ||
6120 | * decl.c (pop_label): Replace warning with call to | |
6121 | warn_for_unused_label. | |
6122 | ||
5cf10afb AP |
6123 | 2007-01-28 Andrew Pinski <pinskia@gmail.com> |
6124 | ||
6125 | PR C++/28988 | |
6126 | * semantics.c (finish_pseudo_destructor_expr): Check the | |
6127 | destrutor name by calling check_dtor_name. | |
6128 | ||
54654d29 DG |
6129 | 2007-01-24 Douglas Gregor <dgregor@osl.iu.edu> |
6130 | ||
6131 | * lex.c (D_CPP0X): Rename. | |
6132 | (D_CXX0X): To this. | |
6133 | (reswords): D_CPP0X -> D_CXX0X. | |
6134 | (init_reswords): Ditto. | |
6135 | * parser.c (cp_lexer_get_preprocessor_token): Warn about the use | |
6136 | of C++0x keywords as identifiers. | |
6137 | ||
815951d8 SM |
6138 | 2007-01-23 Simon Martin <simartin@users.sourceforge.net> |
6139 | ||
6140 | PR c++/27492 | |
6141 | * decl.c (duplicate_decls): Don't reset DECL_INVALID_OVERRIDER_P for | |
6142 | function decls. | |
6143 | ||
a99e5cb4 ILT |
6144 | 2007-01-23 Ian Lance Taylor <iant@google.com> |
6145 | ||
6146 | * typeck.c (convert_for_assignment): Only warn about a = b = c | |
6147 | when converting to bool. | |
6148 | ||
dc569621 RS |
6149 | 2007-01-23 Roger Sayle <roger@eyesopen.com> |
6150 | ||
6151 | * call.c (null_ptr_cst_p): Replace use of TREE_CONSTANT_OVERFLOW with | |
6152 | TREE_OVERFLOW. | |
6153 | * typeck.c (ignore_overflows): Remove the remaining uses of | |
6154 | TREE_CONSTANT_OVERFLOW. | |
6155 | ||
77dbd49b JH |
6156 | 2007-01-20 Jan Hubicka <jh@suse.cz> |
6157 | ||
6158 | * decl2.c (start_objects, start_static_storage_duration_function): | |
6159 | Do not make the functions uninlinable. | |
6160 | ||
efb7e1e0 ILT |
6161 | 2007-01-17 Ian Lance Taylor <iant@google.com> |
6162 | ||
6163 | * class.c (add_method): Call VEC_reserve_exact rather than passing | |
6164 | a negative size to VEC_reserve. | |
6165 | ||
6f9f76e3 SM |
6166 | 2007-01-11 Simon Martin <simartin@users.sourceforge.net> |
6167 | ||
6168 | PR c++/29573 | |
6169 | * tree.c (cp_tree_equal): Properly handle MODOP_EXPR trees. | |
6170 | ||
50ef2c18 MM |
6171 | 2007-01-10 Mark Mitchell <mark@codesourcery.com> |
6172 | ||
6173 | PR c++/28999 | |
6174 | * decl.c (make_typename_type): If the qualified name is not a | |
6175 | type, issue an error. | |
6176 | * parser.c (cp_parser_elaborated_type_specifier): Fix comment | |
6177 | formatting. | |
6178 | ||
157600d0 GK |
6179 | 2007-01-08 Geoffrey Keating <geoffk@apple.com> |
6180 | ||
6181 | * rtti.c: Include target.h. | |
6182 | (emit_support_tinfos): If ! targetm.cxx.library_rtti_comdat (), | |
6183 | don't emit typeinfo for fundamental types as weak. | |
6184 | * Make-lang.in (cp/rtti.o): Update and correct dependencies. | |
6185 | ||
2ac7cbb5 RG |
6186 | 2007-01-08 Richard Guenther <rguenther@suse.de> |
6187 | ||
6188 | * cvt.c (cp_convert_to_pointer): Use build_int_cst_type. | |
6189 | ||
00c8e9f6 MS |
6190 | 2007-01-08 Mark Shinwell <shinwell@codesourcery.com> |
6191 | ||
6192 | * call.c (standard_conversion): Pass flag to | |
6193 | vector_types_convertible_p to disallow emission of note. | |
6194 | * typeck.c (convert_for_assignment): Pass flag to | |
6195 | vector_types_convertible_p to allow emission of note. | |
6196 | (ptr_reasonably_similar): Pass flag to vector_types_convertible_p | |
6197 | to disallow emission of note. | |
6198 | ||
16fd4d2d MLI |
6199 | 2007-01-07 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
6200 | ||
6201 | PR c++/28986 | |
6202 | * typeck.c (build_binary_op): Call overflow_warning if | |
6203 | TREE_OVERFLOW_P is true for the result and not for any of the | |
6204 | operands. | |
056dd1af | 6205 | |
fc40d49c LM |
6206 | 2007-01-06 Lee Millward <lee.millward@codesourcery.com> |
6207 | ||
056dd1af L |
6208 | PR c++/19439 |
6209 | * class.c (add_method): Don't wait until template | |
6210 | instantiation time to complain about duplicate methods. | |
6211 | ||
59c0753d MLI |
6212 | 2007-01-05 Manuel Lopez-Ibanez <manu@gcc.gnu.org> |
6213 | ||
6214 | PR c/19978 | |
6215 | * semantics.c (finish_unary_op_expr): Warn only if result | |
6216 | overflowed and operands did not. | |
6217 | ||
b3c6d2ea ILT |
6218 | 2007-01-05 Ian Lance Taylor <iant@google.com> |
6219 | ||
6220 | * typeck.c (build_binary_op): Warn about comparing a non-weak | |
6221 | address to NULL. | |
6222 | ||
3d761c46 DG |
6223 | 2007-01-05 Douglas Gregor <doug.gregor@gmail.com> |
6224 | ||
6225 | * pt.c (tsubst): Propagate the need for structural equality checks | |
6226 | when reducing the level of template parameters. | |
6227 | ||
c3e188fc KH |
6228 | 2007-01-03 Kazu Hirata <kazu@codesourcery.com> |
6229 | ||
6230 | * pt.c: Fix a comment typo. | |
6231 | ||
2c405565 | 6232 | 2007-01-02 Ian Lance Taylor <iant@google.com> |
fbc8d2d3 ILT |
6233 | |
6234 | * semantics.c (maybe_convert_cond): Optionally warn when using an | |
6235 | assignment as a condition. | |
6236 | * typeck.c (convert_for_assignment): Optionally warn about | |
6237 | assigning the result of an assignment to a bool. | |
6238 | ||
410cf6e6 DG |
6239 | 2007-01-02 Douglas Gregor <doug.gregor@gmail.com> |
6240 | ||
6241 | * pt.c (canonical_template_parms): Correct typo in comment. | |
056dd1af | 6242 | |
06d40de8 DG |
6243 | 2007-01-02 Douglas Gregor <doug.gregor@gmail.com> |
6244 | ||
6245 | * typeck.c (structural_comptypes): Renamed from "comptypes". | |
6246 | (comptypes): Use canonical type information to perform fast type | |
6247 | comparison. When VERIFY_CANONICAL_TYPES, verify that the | |
6248 | canonical type comparison returns the same results as we would see | |
6249 | from the current, structural check. Support COMPARE_STRUCTURAL | |
6250 | when we need structural checks. | |
6251 | * decl.c (typename_compare): Fix comment. | |
6252 | (build_typename_type): TYPENAME_TYPE nodes require structural | |
6253 | equality checks, because they resolve different based on the | |
6254 | current class type. | |
6255 | (make_unbound_class_template): UNBOUND_CLASS_TEMPLATE nodes | |
6256 | require structural equality checks (for now). | |
6257 | (build_ptrmemfunc_type): Build the canonical pointer to member | |
6258 | function type. | |
6259 | (compute_array_index_type): Whenever we build a new index type | |
6260 | to represent the size of an array in a template, we need to mark | |
6261 | this index type as requiring structural equality. This goes for | |
6262 | arrays with value-dependent sizes with the current ABI, or all | |
6263 | arrays with ABI-1. | |
6264 | * tree.c (cplus_array_hash): New. | |
6265 | (struct cplus_array_info): New. | |
6266 | (cplus_array_compare): New. | |
6267 | (cplus_array_htab): New. | |
6268 | (build_cplus_array_type_1): Use a hash table to cache the array | |
6269 | types we build. Build the canonical array type for each array | |
6270 | type. | |
6271 | (cp_build_qualified_type_real): When building a cv-qualified array | |
6272 | type, use the hash table of array types and build canonical array | |
6273 | types as necessary. | |
6274 | (bind_template_template_parm): BOUND_TEMPLATE_TEMPLATE_PARM nodes | |
6275 | use structural equality (for now). | |
6276 | * cp-tree.h (COMPARE_STRUCTURAL): New. | |
6277 | * pt.c (canonical_template_parms): New. | |
6278 | (canonical_type_parameter): New. | |
6279 | (process_template_parm): Find the canonical type parameter. | |
6280 | (lookup_template_class): When we have named the primary template | |
6281 | type, set the canonical type for our template class to the primary | |
6282 | template type. If any of the template arguments need structural | |
6283 | equality checks, the template class needs structural equality | |
6284 | checks. | |
6285 | (tsubst): When reducing the level of a template template | |
6286 | parameter, we require structural equality tests for the resulting | |
6287 | parameter because its template parameters have not had their types | |
6288 | canonicalized. When reducing a template type parameter, find the | |
6289 | canonical reduced type parameter. | |
6290 | (any_template_arguments_need_structural_equality_p): New. | |
6291 |