1 2009-05-26 Dodji Seketeli <dodji@redhat.com>
4 * cp-tree.h (MEMBER_TYPES_NEEDING_ACCESS_CHECK): Remove this accessor.
5 (TI_TYPEDEFS_NEEDING_ACCESS_CHECKING): New accessor.
6 (get_types_needing_access_check): Declare new entry point.
7 * pt.c (append_type_to_template_for_access_check_1,
8 get_types_needing_access_check): New functions.
9 (perform_typedefs_access_check): Accept FUNCTION_DECLs and
10 RECORD_TYPEs rather than TEMPLATE_DECLs. Use the new
11 get_types_needing_access_check, no more
12 MEMBER_TYPES_NEEDING_ACCESS_CHECK.
13 (instantiate_class_template): Set input_location to the source
14 location of the most specialized template definition.
15 Perform access check using the RECORD_TYPE of the template, not its
16 associated most generic TEMPLATE_DECL.
17 (append_type_to_template_for_access_check): Augment function
18 comments. Use the new get_types_needing_access_check, not
19 MEMBER_TYPE_NEEDING_ACCESS_CHECK. Use the new
20 append_type_to_template_for_access_check_1 subroutine.
22 2009-05-22 Jason Merrill <jason@redhat.com>
25 * typeck.c (cp_build_binary_op): Allow ENUMERAL_TYPE in
26 arithmetic comparisons.
27 (cp_common_type): Handle scoped enums.
29 * call.c (promoted_arithmetic_type_p): Don't use INTEGRAL_TYPE_P.
30 (add_builtin_candidate, add_builtin_candidates): Likewise.
31 (convert_like_real): Likewise.
32 * class.c (check_bitfield_decl): Likewise.
33 * decl.c (check_static_variable_definition): Likewise.
34 (compute_array_index_type): Likewise.
35 * decl2.c (grokbitfield): Likewise.
36 * init.c (build_new_1): Likewise.
37 * pt.c (convert_nontype_argument): Likewise.
38 (current_instantiation): Likewise.
39 * tree.c (pod_type_p): Likewise.
40 * typeck.c (build_static_cast_1): Likewise.
41 (build_reinterpret_cast_1): Likewise.
43 2009-05-22 Richard Guenther <rguenther@suse.de>
46 * init.c (avoid_placement_new_aliasing): Remove.
47 (build_new_1): Do not call it.
49 2009-05-22 Mark Mitchell <mark@codesourcery.com>
51 * decl2.c (decl_needed_p): Consider dllexport'd functions needed.
52 * semantics.c (expand_or_defer_fn): Similarly.
54 2009-05-20 Ian Lance Taylor <iant@google.com>
56 * parser.c (cp_parser_postfix_expression): Change args to a vec.
58 (tree_vector): Define typedef. Define VEC functions.
59 (cp_parser_parenthesized_expression_list): Change return type to
60 vec. Change all callers.
61 (cp_parser_new_expression): Change placement and initializer to
62 vecs. Release them when done.
63 (cp_parser_new_placement): Change return type to vec. Change all
65 (cp_parser_new_initializer): Likewise.
66 * typeck.c (build_function_call_vec): Just call
67 cp_build_function_call_vec.
68 (cp_build_function_call): Just build a vec and call
69 cp_build_function_call_vec.
70 (cp_build_function_call_vec): New function based on old
71 cp_build_function_call.
72 (convert_arguments): Remove nargs and argarray parameters. Change
73 values to a vec. Change caller.
74 (build_x_compound_expr_from_vec): New function.
75 (cp_build_modify_expr): Build vec to pass to
76 build_special_member_call.
77 * call.c (struct z_candidate): Add first_arg field. Change args
79 (convert_class_to_reference): Handle first argument separately.
80 (add_candidate): Add first_arg parameter. Change args parameter
81 to vec. Change all callers.
82 (add_function_candidate, add_conv_candidate): Likewise.
83 (add_template_candidate_real, add_template_candidate): Likewise.
84 (add_template_conv_candidate): Likewise.
85 (build_user_type_conversion_1): Handle first argument separately.
86 (resolve_args): Change return type and parameter type to vecs.
88 (perform_overload_resolution): Change args parameter to vec.
90 (build_new_function_call, build_operator_new_call): Likewise.
91 (add_candidates): Likewise.
92 (build_op_call): New globally visible function, built from and
93 replacing static function build_object_call.
94 (build_new_op): Don't handle CALL_EXPR. Build vec, not tree_list,
96 (build_op_delete_call): Build vec to pass to
97 cp_build_function_call_vec.
98 (build_temp): Build vec to pass to build_special_member_call.
99 (convert_like_real): Likewise.
100 (perform_direct_initialization_if_possible): Likewise.
101 (build_over_call): Handle first_arg field. Use build_call_array
102 rather than build_call_list.
103 (build_special_member_call): Change args parameter to vec. Change
105 (build_new_method_call): Likewise.
106 * init.c (expand_default_init): Change parms to vec.
107 (build_raw_new_expr): Change placement and init to vecs. Change
109 (build_new_1, build_new): Likewise.
110 * class.c (resolve_address_of_overloaded_function): Build array to
111 pass to fn_type_unification.
112 * pt.c (tsubst_copy_and_build): For NEW_EXPR build vecs to pass to
113 build_new. For CALL_EXPR create a vec rather than a tree_list;
114 expand a pack if necessary.
115 (fn_type_unification): Change args parameter to const tree *. Add
116 nargs parameter. Change all callers.
117 (type_unification_real): Likewise.
118 (unify): Build array to pass to type_unification_real.
119 (get_bindings): Build array to pass to fn_type_unification.
120 (any_type_dependent_arguments_p): Change args parameter to a vec.
122 (make_args_non_dependent): Renamed from build_non_dependent_args.
123 Change return type to void. Change parameter type to vec. Change
125 (do_auto_deduction): Pass an array to type_unification_real.
126 * semantics.c (perform_koenig_lookup): Change args to vec. Change
128 (finish_call_expr): Change args to vec. Change all callers. Call
129 build_op_call instead of passing CALL_EXPR to build_new_op.
130 (cxx_omp_create_clause_info): Allocate vec to pass to
131 build_special_member_call.
132 * decl2.c (build_offset_ref_call_from_tree): Change args parameter
133 to vec. Change all callers.
134 * name-lookup.c (lookup_function_nonclass): Likewise.
135 (struct arg_lookup): Change args to vec.
136 (arg_assoc_namespace): Handle args as a vec.
137 (arg_assoc_args_vec): New static function.
138 (lookup_arg_dependent): Change args parameter to vec. Change all
140 * method.c (do_build_assign_ref): Allocate vec to pass to
141 build_special_member_call.
142 * except.c (build_throw): Likewise.
143 * typeck2.c (build_functional_cast): Likewise.
144 * cvt.c (ocp_convert): Likewise.
145 * tree.c (build_min_non_dep_call_vec): Change last parameter to
146 vec. Change all callers.
147 * cp-tree.h: Update declarations.
148 * name-lookup.h: Update declarations.
150 2009-05-20 Sandra Loosemore <sandra@codesourcery.com>
152 * typeck.c (default_conversion): Check targetm.promoted_type.
153 * decl.c (grokdeclarator): Check targetm.invalid_return_type.
154 (grokparms): Check targetm.invalid_parameter_type.
155 * cvt.c (ocp_convert): Check targetm.convert_to_type.
156 (build_expr_type_conversion): Check targetm.promoted_type.
158 2009-05-19 Andrew Pinski <andrew_pinski@playstation.sony.com>
160 * typeck.c (build_binary_op): Allow % on integal vectors.
162 2009-05-18 Jason Merrill <jason@redhat.com>
164 Implement explicit conversions ops as specified in N2437.
165 * decl.c (grokdeclarator): Handle explicit conversion ops.
166 (check_initializer): Pass flags to store_init_value.
167 * decl2.c (maybe_emit_vtables): Likewise.
168 * init.c (expand_aggr_init_1): Likewise.
169 * call.c (convert_class_to_reference): Take flags parm,
170 check DECL_NONCONVERTING_P.
171 (build_user_type_conversion_1): Check DECL_NONCONVERTING_P.
172 (add_builtin_candidates): Simplify getting type of conversion.
173 (build_object_call): Likewise. Check DECL_NONCONVERTING_P.
174 (implicit_conversion): Pass through LOOKUP_ONLYCONVERTING.
175 (reference_binding): Take flags parm. Direct-initialize copy parm.
176 (add_function_candidate): Direct-initialize the copy parm.
177 (add_conv_candidate): Use LOOKUP_IMPLICIT, not LOOKUP_NORMAL.
178 (build_builtin_candidate): Add LOOKUP_ONLYCONVERTING.
179 (conditional_conversion): Likewise.
180 (convert_like_real): Only complain about DECL_NONCONVERTING_P
182 (perform_implicit_conversion_flags): Add flags parm to
183 perform_implicit_conversion. Improve diagnostics.
184 * cp-tree.h (LOOKUP_IMPLICIT): New macro.
185 (LOOKUP_COPY_PARM): New bit macro.
186 * cvt.c (build_expr_type_conversion): Check DECL_NONCONVERTING_P.
187 * typeck.c (convert_for_assignment): Take flags parm, pass it to
188 perform_implicit_conversion_flags.
189 (cp_build_modify_expr): Pass flags to convert_for_assignment.
190 (convert_for_initialization): Likewise.
191 * typeck2.c (store_init_value): Take flags parm, pass to
193 (digest_init_flags): Add flags parm to digest_init.
194 (digest_init_r): Take flags parm, pass to convert_for_initialization.
195 (process_init_constructor_array): Pass it.
196 (process_init_constructor_record): Likewise.
197 (process_init_constructor_union): Likewise.
199 2009-05-16 Jason Merrill <jason@redhat.com>
202 * pt.c (tsubst_qualified_id): Retain the type if we aren't dealing
203 with a dependent type. Actually look up the destructor.
204 * semantics.c (finish_id_expression): Fix logic.
205 (finish_qualified_id_expr): Don't try to use 'this' if we aren't in
207 * typeck.c (build_x_unary_op): Diagnose taking the address of a
208 constructor or destructor.
209 * tree.c (get_first_fn): Handle OFFSET_REF.
211 2009-05-17 Joseph Myers <joseph@codesourcery.com>
213 * tree.c (cxx_printable_name_internal): Allow consecutive
214 translated and untranslated cached copies of the name of the
217 2009-05-15 Ian Lance Taylor <iant@google.com>
219 * cp-tree.h (enum cp_lvalue_kind_flags): Rename from
220 cp_lvalue_kind. Change all uses.
221 (enum base_access_flags): Rename from enum base_access. Change
223 * parser.c (enum cp_parser_flags): Remove enum tag.
225 2009-05-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
228 * call.c (build_new_op): Update calls to warn_logical_operator.
230 2009-05-14 Ian Lance Taylor <iant@google.com>
232 * class.c (layout_class_type): Change itk to unsigned int.
233 * decl.c (finish_enum): Change itk to unsigned int.
234 * parser.c (cp_parser_check_decl_spec): Change ds to int. Remove
237 2009-05-13 David Mandelin <dmandelin@mozilla.com>:
239 * decl.c (duplicate_decls): Preserve parameter attributes.
241 2009-05-10 Jan Hubicka <jh@suse.cz>
243 * decl2.c (cxx_callgraph_analyze_expr): Use
244 cgraph_mark_address_taken.
246 2009-05-10 Joseph Myers <joseph@codesourcery.com>
248 * call.c (name_as_c_string): Call type_as_string_translate.
249 Translate identifiers to locale character set.
250 * cp-tree.h (lang_decl_name): Update prototype.
251 (type_as_string_translate, decl_as_string_translate,
252 cxx_printable_name_translate): Declare.
253 * cxx-pretty-print.c (M_): Define.
254 (pp_cxx_unqualified_id, pp_cxx_canonical_template_parameter): Mark
255 English fragments for conditional translation with M_.
256 * decl.c (grokdeclarator): Translate identifiers to locale
257 character set for diagnostics.
258 * error.c (M_): Define.
259 (dump_template_bindings, dump_type, dump_aggr_type,
260 dump_type_prefix, dump_global_iord, dump_simple_decl, dump_decl,
261 dump_function_decl, dump_template_parms, dump_expr,
262 dump_binary_op, op_to_string, assop_to_string): Mark English
263 fragments for conditional translation with M_.
264 (type_as_string): Disable translation of identifiers.
265 (type_as_string_translate): New.
266 (expr_as_string): Disable translation of identifiers.
267 (decl_as_string): Disable translation of identifiers.
268 (decl_as_string_translate): New.
269 (lang_decl_name): Add parameter translate.
270 (args_to_string): Call type_as_string_translate.
271 (cp_print_error_function): Call cxx_printable_name_translate.
272 (print_instantiation_full_context,
273 print_instantiation_partial_context): Call
274 decl_as_string_translate.
275 * parser.c (cp_lexer_get_preprocessor_token): Use %qE for
276 identifier in diagnostic.
277 * tree.c (cxx_printable_name): Change to
278 cxx_printable_name_internal. Add parameter translate.
279 (cxx_printable_name, cxx_printable_name_translate): New wrappers
280 round cxx_printable_name_internal.
282 2009-05-08 H.J. Lu <hongjiu.lu@intel.com>
285 * call.c (build_call_a): Updated warn_deprecated_use call.
286 (build_over_call): Likewise.
287 * decl.c (grokdeclarator): Likewise.
288 (grokparms): Likewise.
289 * semantics.c (finish_id_expression): Likewise.
290 * typeck.c (build_class_member_access_expr): Likewise.
291 (finish_class_member_access_expr): Likewise.
293 2009-05-06 Dodji Seketeli <dodji@redhat.com>
296 * pt.c (tsubst_copy) <case PARM_DECL>: We don't want to tsubst the
297 whole list of PARM_DECLs, just the current one.
299 2009-05-05 Shujing Zhao <pearly.zhao@oracle.com>
302 (opname_tab, assignop_tab, update_member_visibility, yyerror, yyhook,
303 mangle_compound_literal): Remove unused declarations.
304 (build_vfield_ref, cxx_print_statistics, clone_function_decl,
305 adjust_clone_args, maybe_push_cleanup_level, pushtag, make_anon_name,
306 pushdecl_top_level_maybe_friend, pushdecl_top_level_and_finish,
307 check_for_out_of_scope_variable, print_other_binding_stack,
308 maybe_push_decl, cxx_mark_addressable, force_target_expr,
309 build_target_expr_with_type, finish_case_label,
310 cxx_maybe_build_cleanup, begin_eh_spec_block, finish_eh_spec_block,
311 check_template_keyword, cxx_omp_predetermined_sharing,
312 cxx_omp_clause_default_ctor, cxx_omp_clause_copy_ctor,
313 cxx_omp_clause_assign_op, cxx_omp_clause_dtor, cxx_omp_finish_clause,
314 cxx_omp_privatize_by_reference): Rearrange the declarations line to
315 match the comment that indicates the .c file which the functions are
317 (cxx_print_xnode, cxx_print_decl, cxx_print_type,
318 cxx_print_identifier, cxx_print_error_function, pushdecl): Add comment.
320 2009-05-05 Nathan Sidwell <nathan@codesourcery.com>
322 * typeck.c (cp_build_compound_expr): Require RHS to have a known
324 * class.c (resolve_address_of_overloaded_function): Use
325 OVL_CURRENT for error message.
326 (instantiate_type): Forbid COMPOUND_EXPRs and remove code dealing
327 with them. Do not copy the node.
329 2009-05-05 Jakub Jelinek <jakub@redhat.com>
332 * pt.c (tsubst): If magic NOP_EXPR with side-effects has no type,
333 set it from its operand's type after tsubst_expr.
335 2009-05-04 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
338 * parser.c (cp_lexer_get_preprocessor_token): Do not store the
339 canonical spelling for keywords.
340 (cp_parser_attribute_list): Use the canonical spelling for
341 keywords in attributes.
343 2009-05-01 Joseph Myers <joseph@codesourcery.com>
345 * cxx-pretty-print.c (is_destructor_name, pp_cxx_unqualified_id,
346 pp_cxx_template_keyword_if_needed, pp_cxx_postfix_expression,
347 pp_cxx_new_expression, pp_cxx_delete_expression,
348 pp_cxx_unary_expression, pp_cxx_assignment_operator,
349 pp_cxx_assignment_expression, pp_cxx_expression,
350 pp_cxx_function_specifier, pp_cxx_decl_specifier_seq,
351 pp_cxx_simple_type_specifier, pp_cxx_type_specifier_seq,
352 pp_cxx_exception_specification, pp_cxx_direct_declarator,
353 pp_cxx_ctor_initializer, pp_cxx_type_id, pp_cxx_statement,
354 pp_cxx_namespace_alias_definition, pp_cxx_template_parameter,
355 pp_cxx_canonical_template_parameter, pp_cxx_template_declaration,
356 pp_cxx_declaration, pp_cxx_typeid_expression,
357 pp_cxx_va_arg_expression, pp_cxx_offsetof_expression,
358 pp_cxx_trait_expression): Mostly use pp_string and
359 pp_cxx_ws_string in place of pp_identifier and pp_cxx_identifier
360 for non-identifiers. Mark English strings for translation.
361 * cxx-pretty-print.h (pp_cxx_ws_string): Define.
362 * error.c (dump_template_parameter, dump_template_bindings,
363 dump_type, dump_aggr_type, dump_type_prefix, dump_simple_decl,
364 dump_decl, dump_template_decl, dump_function_decl,
365 dump_parameters, dump_exception_spec, dump_template_parms,
366 dump_expr, dump_binary_op, dump_unary_op, op_to_string,
367 assop_to_string, args_to_string, cp_print_error_function,
368 print_instantiation_full_context,
369 print_instantiation_partial_context): Mostly use pp_string and
370 pp_cxx_ws_string in place of pp_identifier and pp_cxx_identifier
371 for non-identifiers. Mark English strings for translation.
372 (dump_global_iord): Mark strings for translation; use longer
373 strings instead of substituting single words.
374 (function_category): Return a format string marked for
375 translation, not a single word or phrase to substitute in a longer
378 2009-04-28 Ben Elliston <bje@au.ibm.com>
383 2009-03-27 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
385 * typeck.c (cp_pointer_sum): Adjust call to pointer_int_sum.
387 2009-04-27 Ian Lance Taylor <iant@google.com>
389 * semantics.c (finish_omp_clauses): Change type of c_kind to enum
392 2009-04-27 Jakub Jelinek <jakub@redhat.com>
395 * cvt.c (convert_to_void) <case INDIRECT_REF>: Only warn about
396 -Wunused-value if implicit.
398 2009-04-24 Ian Lance Taylor <iant@google.com>
400 * call.c (build_temp): Change 0 to enum constant.
401 * cp-tree.h (cp_lvalue_kind): Typedef to int rather than enum
403 * cp-gimplify.c (cp_gimplify_expr): Add cast to enum type.
404 * decl2.c (constrain_visibility): Likewise.
405 * parser.c (cp_lexer_get_preprocessor_token): Likewise.
406 (cp_parser_flags): Typedef to int rather than enum type.
407 (cp_parser_expression_stack_entry): Change prec field to enum
410 * typeck.c (build_modify_expr): Add lhs_origtype parameter.
413 2009-04-22 Dodji Seketeli <dodji@redhat.com>
416 * parser.c (cp_parser_template_argument_list): Display an error
417 when an ellipsis is not preceded by a parameter pack. Also, warn
418 about variadic templates usage without -std=c++0x.
420 2009-04-21 Taras Glek <tglek@mozilla.com>
422 * cp-tree.h: Update GTY annotations to new syntax.
424 * mangle.c: Likewise.
425 * name-lookup.c: Likewise.
426 * name-lookup.h: Likewise.
427 * parser.c: Likewise.
430 * semantics.c: Likewise.
431 * typeck2.c: Likewise.
433 2009-04-22 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
436 * parser.c (cp_parser_error): Pass token->flags to c_parse_error.
438 2009-04-21 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
441 * typeck.c (check_for_casting_away_constness): We diagnose casting
442 away any qualifiers not just constness.
443 (casts_away_constness): Mention that it handles more than just
446 2009-04-21 Joseph Myers <joseph@codesourcery.com>
448 * ChangeLog, ChangeLog-1993, ChangeLog-1994, ChangeLog-1995,
449 ChangeLog-1996, ChangeLog-1997, ChangeLog-1998, ChangeLog-1999,
450 ChangeLog-2000, ChangeLog-2001, ChangeLog-2002, ChangeLog-2003,
451 ChangeLog-2004, ChangeLog-2005, ChangeLog-2006, ChangeLog-2007,
452 ChangeLog-2008, ChangeLog.ptr, ChangeLog.tree-ssa, NEWS,
453 cfns.gperf: Add copyright and license notices.
454 * cfns.h: Regenerate.
455 * ChangeLog, ChangeLog-2004: Correct dates.
457 2009-04-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
460 * tree.c (lvalue_p_1): Use const_tree.
461 Use CONST_CAST_TREE to avoid warning.
462 (lvalue_p): Returns bool, receives const_tree.
464 2009-04-21 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
467 * parser.c (cp_parser_check_decl_spec): Drop redundant flags.
468 * error.c (pedwarn_cxx98): New.
469 * cp-tree.h (pedwarn_cxx98): Declare.
471 2009-04-20 Le-Chun Wu <lcwu@google.com>
474 * init.c (build_vec_init): Set TREE_NO_WARNING on the
475 compiler-generated INDIRECT_REF expression.
477 2009-04-20 Ian Lance Taylor <iant@google.com>
479 * typeck.c (build_function_call_vec): New function.
480 (cp_build_function_call): Only pass first parameter to
481 objc_rewrite_function_call.
482 (build_modify_expr): Add rhs_origtype parameter. Change all
484 * decl.c (finish_decl): Add origtype parameter. Change all
486 * semantics.c (finish_call_expr): Pass VEC to
487 resolve_overloaded_builtin.
489 2009-04-20 Ian Lance Taylor <iant@google.com>
491 * cp-tree.h (base_access): Change typedef to int.
492 * parser.c (cp_parser_omp_flush): Change 0 to OMP_CLAUSE_ERROR.
493 (cp_parser_omp_threadprivate): Likewise.
494 * pt.c (unify_pack_expansion): Add casts to enum type.
496 2009-04-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
500 * call.c (build_new_op): Save the original codes of operands
503 2009-04-18 Kazu Hirata <kazu@codesourcery.com>
505 * cp-tree.h: Remove the prototype for insert_block.
506 * decl.c (insert_block): Remove.
508 2009-04-16 Ian Lance Taylor <iant@google.com>
510 * cp-tree.h (enum tsubst_flags): Rename from enum tsubst_flags_t.
511 (tsubst_flags_t): Change typedef from enum type to int.
513 2009-04-16 Paolo Bonzini <bonzini@gnu.org>
515 * decl.c (check_initializer): Use TYPE_VECTOR_OPAQUE
516 instead of targetm.vector_opaque_p.
518 2009-04-15 Le-Chun Wu <lcwu@google.com>
521 * call.c (build_over_call): Set TREE_NO_WARNING on the
522 compiler-generated INDIRECT_REF expression.
523 * cvt.c (convert_to_void): Emit warning when stripping off
526 2009-04-14 Diego Novillo <dnovillo@google.com>
528 * parser.c (cp_parser_type_specifier_seq): Move call to
529 invoke_plugin_callbacks ...
530 (cp_parser_type_specifier_seq): ... here.
532 2009-04-14 Le-Chun Wu <lcwu@google.com>
534 * Make-lang.in: Modify dependencies of files including plugin.h.
535 * decl.c (finish_function): Call invoke_plugin_callbacks.
536 * parser.c (cp_parser_type_specifier): Call invoke_plugin_callbacks.
538 2009-04-14 Jason Merrill <jason@redhat.com>
541 * name-lookup.c (pushdecl_maybe_friend): Avoid all warnings
542 about shadowing by tentative parms.
544 2009-04-13 Jason Merrill <jason@redhat.com>
547 * call.c (build_over_call): Don't call memcpy if the target is
548 the same as the source.
550 2009-04-13 Jason Merrill <jason@redhat.com>
553 * pt.c (uses_template_parms): Handle CONSTRUCTOR.
555 2009-04-12 Jason Merrill <jason@redhat.com>
558 * call.c (joust): Don't crash on variadic fn.
560 2009-04-10 Jason Merrill <jason@redhat.com>
563 * parser.c (cp_parser_skip_to_end_of_block_or_statement): Return
564 if we see a close brace without an open brace.
566 2009-04-10 H.J. Lu <hongjiu.lu@intel.com>
568 * parser.c (cp_parser_class_specifier): Remove the unused
569 has_trailing_semicolon.
571 2009-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
574 * parser.c (cp_parser_check_template_parameters): Take a
575 cp_declarator parameter.
576 (cp_parser_elaborated_type_specifier): Update to
577 cp_parser_check_template_parameters.
578 (cp_parser_class_head): Likewise.
579 (cp_parser_check_declarator_template_parameters): Likewise.
580 (cp_parser_check_template_parameters): Handle first the non-error
581 conditions. Give more accurate diagnostics if a declarator is
584 2009-04-08 Jason Merrill <jason@redhat.com>
587 * error.c (dump_aggr_type): Chase template typedefs if
588 -fno-pretty-templates.
590 2009-04-08 Dodji Seketeli <dodji@redhat.com>
593 * parser.c (cp_parser_enumerator_definition): Make sure the
594 initializer of the enumerator doesn't contain any bare parameter pack.
596 2009-04-07 Jason Merrill <jason@redhat.com>
599 * name-lookup.c (merge_functions): Keep multiple extern "C" functions.
600 * call.c (joust): Complain about mismatched default arguments
601 in extern "C" functions.
602 * class.c (resolve_address_of_overloaded_function): Handle multiple
603 extern "C" functions.
604 * pt.c (resolve_overloaded_unification): Likewise.
606 2009-04-07 Jason Merrill <jason@redhat.com>
609 * error.c (dump_function_decl): Don't pretty-print templates
610 if -fno-pretty-templates.
611 (count_non_default_template_args): Print all args if
612 -fno-pretty-templates.
614 2009-04-06 Jason Merrill <jason@redhat.com>
617 * pt.c (fn_type_unification): For DEDUCE_EXACT check that
618 the deduced template arguments give us the parameter types
621 2009-04-05 Giovanni Bajo <giovannibajo@libero.it>
622 Jason Merrill <jason@redhat.com>
625 * error.c (count_non_default_template_args): New fn.
626 (dump_template_parms): Call it.
627 (dump_template_argument_list): Call it. Add parms parm.
628 (dump_template_argument): Adjust call to dump_template_argument_list.
629 (dump_type, dump_decl): Likewise.
630 (dump_template_bindings): Refactor logic.
632 2009-04-03 Jason Merrill <jason@redhat.com>
635 * error.c (dump_template_bindings): Look through typedefs in
637 (dump_type) [TYPENAME_TYPE]: Print the typedef name if any.
638 (find_typenames_r): Also collect typedefs.
639 * pt.c (unify): Strip typedefs.
642 * semantics.c (finish_id_expression): Don't assume a dependent
643 member of the current instantiation isn't a valid integral
644 constant expression. Check dependent_scope_p.
645 * pt.c (dependent_scope_p): Check TYPE_P.
646 (tsubst_copy): If args is null, just return.
648 2009-04-02 Jason Merrill <jason@redhat.com>
651 * error.c (find_typenames, find_typenames_r): New fns.
652 (dump_function_decl): Call find_typenames.
653 (dump_template_bindings): Print typenames as well.
654 * pt.c (tsubst): Non-static.
655 * cp-tree.h: Declare it.
657 2009-04-02 Dodji Seketeli <dodji@redhat.com>
660 * decl2.c (grokfield): when a typedef appears in a
661 class, create the typedef variant type node for it.
662 (save_template_attributes): Creating typedef variant type node
664 * decl.c (grokdeclarator): If the typedef'ed struct/class was
665 anonymous, set the proper type name to all its type variants.
666 (xref_basetypes) : Fixup the variant types after setting
668 * name-lookup.c (pushdecl_maybe_friend): Reuse the
669 set_underlying_type function to install typedef variant types.
670 * cp-tree.h (MEMBER_TYPES_NEEDING_ACCESS_CHECK): New template accessor
672 (append_type_to_template_for_access_check): New entry points.
673 * semantics.c (check_accessibility_of_qualified_id):
674 When a typedef that is a member of a class appears in a template,
675 add it to the template. It will be ...
676 * class.c (finish_struct_bits): Split type variant fixup into ...
677 (fixup_type_variants): A new entry point.
678 * pt.c (instantiate_class_template, instantiate_template ): ... access
679 checked at template instantiation time.
680 (resolve_type_name_type): The type name should be the name of the
682 (retrieve_specialization): Specializations of template typedefs aren't
683 to looked up in DECL_TEMPLATE_INSTANTIATIONS (tmpl).
684 (append_type_to_template_for_access_check): New entry point.
685 (tsubst_decl): For typedefs, build the variant type from the correct
687 (get_class_bindings): Fix function comment.
688 (perform_typedefs_access_check): New entry point.
690 2009-03-31 Jason Merrill <jason@redhat.com>
693 * name-lookup.c (pushdecl_maybe_friend): Diagnose mismatched
694 extern "C" declarations.
697 * semantics.c (finish_non_static_data_member): Allow such references
698 without an associated object in sizeof/decltype/alignof.
700 * ptree.c (cxx_print_decl): Pretty-print full name of
702 (cxx_print_type): Pretty-print full name of class.
704 * decl.c (grokdeclarator): Reject pointer to qualified function
707 PR c++/37806, core issue 547
708 * typeck.c (cp_apply_type_quals_to_decl): Don't apply any quals
710 * tree.c (cp_build_qualified_type_real): Don't apply restrict to a
712 * decl.h (enum decl_context): Add TEMPLATE_TYPE_ARG.
713 * decl.c (groktypename): Add is_template_arg parameter.
714 (grokdeclarator): Allow function cv-quals on a template type arg.
715 * parser.c (cp_parser_new_type_id, cp_parser_type_id): Add
716 is_template_arg argument in calls to groktypename.
717 * cp-tree.h: Adjust prototype.
718 * error.c (dump_type_prefix, dump_type_suffix): Fix plain
719 FUNCTION_TYPE printing.
721 * mangle.c (write_expression): Mangle dependent name as
724 PR c++/38030, 38850, 39070
725 * pt.c (type_dependent_expression_p_push): New fn.
726 (tsubst_copy_and_build) [CALL_EXPR]: Only do arg-dep lookup when the
727 substitution makes the call non-dependent. Preserve koenig_p.
728 * parser.c (cp_parser_postfix_expression): Only do arg-dep lookup
729 for non-dependent calls.
730 * semantics.c (finish_call_expr): Revert earlier changes.
731 * cp-tree.h: Revert change to finish_call_expr prototype.
733 2009-03-29 Joseph Myers <joseph@codesourcery.com>
735 PR preprocessor/34695
736 * cp-tree.h (cp_cpp_error): Remove.
737 * error.c (cp_cpp_error): Remove.
738 * parser.c (cp_lexer_new_main): Set done_lexing instead of
739 client_diagnostic and error callback.
741 2009-03-28 Paolo Bonzini <bonzini@gnu.org>
743 * cp/cp-objcp-common.h (LANG_HOOKS_STATICP): Remove.
744 * cp/cp-objcp-common.c (cxx_staticp): Remove.
745 * cp/cp-tree.h (cxx_staticp): Remove.
747 2009-03-28 Jakub Jelinek <jakub@redhat.com>
750 * parser.c (cp_parser_postfix_expression): Don't call
751 warning_if_disallowed_function_p.
753 2009-03-27 Jan Hubicka <jh@suse.cz>
755 * except.c (choose_personality_routine): Set terminate_node to abort
758 2009-03-27 Dodji Seketeli <dodji@redhat.com>
759 Jakub Jelinek <jakub@redhat.com>
762 * cp-objcp-common.h (LANG_HOOKS_FUNCTION_DECL_EXPLICIT_P): Define.
763 (cp_function_decl_explicit_p): New prototype.
764 * cp-objcp-common.c (cp_function_decl_explicit_p): New function.
766 2009-03-27 Andrew Pinski <andrew_pinski@playstation.sony.com>
769 * parser.c (cp_parser_elaborated_type_specifier): If we have a
770 typename tag and don't have either a TYPE_DECL or a
771 TEMPLATE_ID_EXPR, set the type to NULL.
773 2009-03-27 Simon Martin <simartin@users.sourceforge.net>
776 * decl.c (grokdeclarator): Reject [con|de]stuctors in a non-class
779 2009-03-27 Simon Martin <simartin@users.sourceforge.net>
782 * decl.c (check_array_designated_initializer): Handle error_mark_node.
784 2009-03-27 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
787 * typeck.c (cp_pointer_sum): Adjust call to pointer_int_sum.
789 2009-03-26 Andrew Haley <aph@redhat.com>
792 * decl2.c (possibly_inlined_p): If java exceptions are in use
793 don't inline a decl unless it is explicitly marked inline.
794 * lex.c: (pragma_java_exceptions): New variable.
795 (handle_pragma_java_exceptions): Set pragma_java_exceptions.
796 * cp-tree.h (pragma_java_exceptions): Declare new variable.
798 2009-03-24 Jason Merrill <jason@redhat.com>
801 * name-lookup.c (pushdecl_maybe_friend): Check default args later.
803 2009-03-23 Jakub Jelinek <jakub@redhat.com>
806 * semantics.c (handle_omp_for_class_iterator): Swap cond operands and
807 code if iter is the second operand.
808 * parser.c (cp_parser_binary_expression): Add no_toplevel_fold_p
809 argument. If it is set, don't build the toplevel expression with
810 build_x_binary_op, but build2.
811 (cp_parser_assignment_expression, cp_parser_omp_for_incr): Adjust
813 (cp_parser_omp_for_cond): Don't assume the first operand of the
814 comparison must be decl.
816 2009-03-23 Jason Merrill <jason@redhat.com>
819 * pt.c (make_fnparm_pack): Split out from...
820 (instantiate_decl): ...here.
821 (tsubst_pack_expansion): Handle being called in a late-specified
825 * name-lookup.c (pushdecl_maybe_friend): Don't warn about shadowing
828 2009-03-20 Jason Merrill <jason@redhat.com>
831 * parser.c (cp_parser_direct_declarator): In a template, wrap
832 non-constant expression in NOP_EXPR with TREE_SIDE_EFFECTS set.
833 * pt.c (tsubst): Preserve it in a partial instantiation.
834 (dependent_type_p_r): Don't check value_dependent_expression_p.
835 * decl.c (compute_array_index_type): Don't check
836 value_dependent_expression_p if TREE_SIDE_EFFECTS.
839 * typeck2.c (check_narrowing): Don't complain about loss of
840 precision when converting a floating-point constant.
842 2009-03-19 Jakub Jelinek <jakub@redhat.com>
845 * parser.c (cp_parser_omp_for_cond): Don't check lhs if decl is NULL.
846 (cp_parser_omp_for_loop): Always use cp_parser_omp_for_cond.
848 2009-03-18 Jakub Jelinek <jakub@redhat.com>
850 * parser.c (struct cp_token): Reorder fields for 64-bit hosts.
853 2009-03-18 H.J. Lu <hongjiu.lu@intel.com>
856 * parser.c (cp_parser_explicit_specialization): Don't skip the
857 rest of the specialization when begin_specialization returns
860 2009-03-17 Jason Merrill <jason@redhat.com>
862 * decl.c (grokfndecl): Set DECL_CONTEXT on parms.
863 (duplicate_decls): Adjust DECL_CONTEXT of newdecl's parms.
864 * pt.c (check_explicit_specialization): Likewise.
865 (tsubst_copy) [PARM_DECL]: Return a dummy parm if we don't have a
866 local specialization.
867 * tree.c (cp_tree_equal) [PARM_DECL]: Check type and index, not name.
868 * decl2.c (parm_index): New fn.
869 * semantics.c (finish_decltype_type): Don't use describable_type.
870 * mangle.c (write_expression): Likewise. Mangle ALIGNOF_EXPR.
871 Give a sorry for unsupported codes rather than crash. Mangle
872 conversions with other than 1 operand. New mangling for PARM_DECL.
873 * operators.def (ALIGNOF_EXPR): Mangle as "az".
875 2009-03-17 Jing Yu <jingyu@google.com>
878 * method.c (use_thunk): Change is_thunk from crtl to cfun.
880 2009-03-17 Paolo Carlini <paolo.carlini@oracle.com>
883 * semantics.c (check_trait_type): New.
884 (finish_trait_expr): Use it.
886 2009-03-17 Jakub Jelinek <jakub@redhat.com>
888 * name-lookup.c (cp_emit_debug_info_for_using): Emit USING_STMTs
889 instead of calling imported_module_or_decl debug hook if
890 building_stmt_tree ().
891 * cp-gimplify.c (cp_gimplify_expr): Don't assert the first operand
895 * name-lookup.c (do_namespace_alias): Don't call global_decl debug
896 hook at function scope.
899 * cp-gimplify.c (cp_gimplify_expr): Don't set DECL_NAME
902 2009-03-09 Jakub Jelinek <jakub@redhat.com>
905 * semantics.c (finish_switch_cond): Don't call get_unwidened.
906 * decl.c (finish_case_label): Pass SWITCH_STMT_TYPE as 3rd argument
907 instead of TREE_TYPE (cond).
909 2009-03-08 H.J. Lu <hongjiu.lu@intel.com>
912 * parser.c (cp_parser_late_parsing_default_args): Continue
913 the loop when cp_parser_assignment_expression returns
916 2009-03-07 Jason Merrill <jason@redhat.com>
919 * init.c (build_new_1): Don't use a VLA type.
920 (build_vec_init): Handle getting a pointer for BASE.
922 2009-03-06 H.J. Lu <hongjiu.lu@intel.com>
925 * cp-tree.h: Check NO_DOT_IN_LABEL before NO_DOLLAR_IN_LABEL
926 when mangling symbols.
928 2009-03-06 Paolo Carlini <paolo.carlini@oracle.com>
931 * error.c (dump_expr): Don't try to print THROW_EXPRs in full.
933 2009-03-06 Alexandre Oliva <aoliva@redhat.com>
935 * decl.c (record_builtin_java_type): Use canonicalized integer
938 2009-03-04 Jason Merrill <jason@redhat.com>
941 * class.c (is_really_empty_class): New fn.
942 * cp-tree.h: Declare it.
943 * cp-objcp-common.c (cp_expr_size): Use it.
946 * semantics.c (perform_koenig_lookup): Handle TEMPLATE_ID_EXPR.
947 * parser.c (cp_parser_postfix_expression): Call it for
949 * tree.c (is_overloaded_fn): Look through TEMPLATE_ID_EXPR.
950 (get_first_fn): Likewise.
956 * decl.c (make_typename_type): Do look inside currently open classes.
957 * parser.c (cp_parser_lookup_name): Likewise.
958 (cp_parser_template_name): Likewise.
959 * pt.c (dependent_scope_p): New function.
960 * cp-tree.h: Declare it.
961 * class.c (currently_open_class): Return fast if T isn't a class.
963 2009-02-26 H.J. Lu <hongjiu.lu@intel.com>
966 * parser.c (cp_parser_mem_initializer): Return error_mark_node
967 if cp_parser_mem_initializer_id returns error_mark_node.
969 2009-02-24 Richard Guenther <rguenther@suse.de>
972 * pt.c (instantiate_decl): Do not instantiate extern, non-inline
975 2009-02-23 H.J. Lu <hongjiu.lu@intel.com>
978 * pt.c (coerce_template_template_parms): Return 0 if parameter
981 2009-02-23 Jason Merrill <jason@redhat.com>
983 * pt.c (unify): Call maybe_adjust_types_for_deduction when
984 deducing from an initializer list.
986 2009-02-20 Jason Merrill <jason@redhat.com>
989 * decl.c (grokdeclarator): Handle ~identifier.
991 2009-02-19 Jakub Jelinek <jakub@redhat.com>
994 * decl2.c (determine_visibility): If visibility changed and
995 DECL_RTL has been already set, call make_decl_rtl to update symbol
998 2009-02-19 H.J. Lu <hongjiu.lu@intel.com>
1001 * cp-tree.h (maybe_commonize_var): New.
1003 * decl.c (maybe_commonize_var): Make it extern.
1005 * decl2.c (finish_anon_union): Call maybe_commonize_var.
1007 2009-02-18 H.J. Lu <hongjiu.lu@intel.com>
1010 * parser.c (cp_parser_enum_specifier): Apply all attributes.
1012 2009-02-18 Jason Merrill <jason@redhat.com>
1014 * cfns.h: Tweak pathname for cfns.gperf.
1016 2009-02-13 Jason Merrill <jason@redhat.com>
1019 * semantics.c (finish_call_expr): Change koenig_p parm to int.
1020 If -1, don't set KOENIG_LOOKUP_P but do keep hidden candidates.
1021 * cp-tree.h: Adjust prototype.
1022 * pt.c (tsubst_copy_and_build) [CALL_EXPR]: Pass -1.
1024 2009-02-12 Jason Merrill <jason@redhat.com>
1027 * pt.c (unify)[TEMPLATE_PARM_INDEX]: Convert to the tsubsted type.
1029 2009-02-11 Jason Merrill <jason@redhat.com>
1032 * decl2.c (cp_write_global_declarations):
1033 Check DECL_DEFAULTED_FN, not DECL_ARTIFICIAL.
1036 * init.c (build_value_init_noctor): Split out from...
1037 (build_value_init): ...here.
1038 (expand_aggr_init_1): Handle value-initialization.
1039 * cp-tree.h: Add declaration.
1040 * class.c (type_has_user_provided_constructor):
1041 Handle non-class arguments.
1043 2009-02-10 Jason Merrill <jason@redhat.com>
1046 * class.c (defaultable_fn_p): Handle ... properly.
1049 * tree.c (lvalue_p_1): Condition rvalue ref handling on
1050 treat_class_rvalues_as_lvalues, too.
1052 2009-02-10 Paolo Carlini <paolo.carlini@oracle.com>
1055 * typeck.c (build_x_array_ref): New.
1056 * cp-tree.h: Declare it.
1057 * pt.c (tsubst_copy_and_build): Use it for case ARRAY_REF.
1059 2009-02-09 Jason Merrill <jason@redhat.com>
1062 * semantics.c (simplify_aggr_init_expr): Do zero-initialization here.
1063 * init.c (build_value_init): Not here. Don't build a TARGET_EXPR.
1064 * tree.c (get_target_expr): Handle AGGR_INIT_EXPR.
1065 * cp-gimplify.c (cp_gimplify_init_expr): Remove special handling
1066 for build_value_init TARGET_EXPR.
1067 * cp-tree.h (AGGR_INIT_ZERO_FIRST): New macro.
1069 2009-02-06 Paolo Carlini <paolo.carlini@oracle.com>
1073 * cp-tree.h (TMPL_ARGS_HAVE_MULTIPLE_LEVELS): Check TREE_VEC_LENGTH.
1075 2009-02-04 Jakub Jelinek <jakub@redhat.com>
1078 * operators.def: Use COMPONENT_REF code for ->/pt operator again,
1079 remove ./dt operator.
1080 * mangle.c (write_expression): Handle COMPONENT_REF after handling
1081 ADDR_EXPR, for COMPONENT_REF without ARROW_EXPR inside of it
1082 write_string ("dt") instead of using operators.def.
1084 2009-02-03 Jason Merrill <jason@redhat.com>
1086 * typeck.c (cp_build_unary_op): Only complain about taking address
1087 of main if pedantic.
1089 2009-02-03 Jakub Jelinek <jakub@redhat.com>
1092 * parser.c (cp_parser_primary_expression): Reject FIXED_CSTs.
1095 * typeck2.c (digest_init_r): Don't call process_init_constructor
1098 2009-02-03 Paolo Bonzini <bonzini@gnu.org>
1101 * pt.c (convert_nontype_argument_function): Expect expr to be an
1105 * typeck.c (merge_types): Call resolve_typename_type if only
1106 one type is a typename.
1108 2009-02-02 Jason Merrill <jason@redhat.com>
1111 * parser.c (cp_parser_unqualified_id): Don't wrap error_mark_node
1114 2009-02-01 Paolo Carlini <paolo.carlini@oracle.com>
1117 * parser.c (cp_parser_pure_specifier): If there are no tokens left
1118 do not call cp_lexer_consume_token.
1120 2009-01-30 Jakub Jelinek <jakub@redhat.com>
1123 * parser.c (cp_parser_already_scoped_statement): Handle __label__
1126 2009-01-30 Paolo Carlini <paolo.carlini@oracle.com>
1129 * error.c (dump_expr): Handle FIX_TRUNC_EXPR and FLOAT_EXPR.
1131 2009-01-30 Paolo Carlini <paolo.carlini@oracle.com>
1134 * error.c (dump_type_prefix, dump_type_suffix): Handle FIXED_POINT_TYPE.
1136 2009-01-29 Paolo Carlini <paolo.carlini@oracle.com>
1138 * typeck.c (invalid_nonstatic_memfn_p): Use
1139 DECL_NONSTATIC_MEMBER_FUNCTION_P.
1141 2009-01-27 Paolo Carlini <paolo.carlini@oracle.com>
1144 * call.c (build_over_call): If convert_for_arg_passing returns
1145 error_mark_node unconditionally return it.
1147 2009-01-22 Adam Nemet <anemet@caviumnetworks.com>
1149 * class.c (check_field_decls): Also inherit packed for bitfields
1150 regardless of their type.
1152 2009-01-22 Dodji Seketeli <dodji@redhat.com>
1155 * decl2.c (grokfield): Reverting changes of PR c++/26693
1156 (save_template_attributes): Likewise.
1157 * decl.c (grokdeclarator): Likewise.
1158 * name-lookup.c (pushdecl_maybe_friend): Likewise.
1159 * cp-tree.h (MEMBER_TYPES_NEEDING_ACCESS_CHECK): Likewise.
1160 (append_type_to_template_for_access_check): Likewise.
1161 * semantics.c (check_accessibility_of_qualified_id): Likewise.
1162 * pt.c (instantiate_class_template, instantiate_template ): Likewise.
1164 (resolve_type_name_type): Likewise.
1165 (append_type_to_template_for_access_check): Likewise.
1167 2009-01-21 Dodji Seketeli <dodji@redhat.com>
1170 * decl2.c (grokfield): when a typedef appears in a
1171 class, create the typedef variant type node for it.
1172 (save_template_attributes): Creating typedef variant type node
1173 here is now useless.
1174 * decl.c (grokdeclarator): If the typedef'ed struct/class was
1175 anonymous, set the proper type name to all its type variants.
1176 * name-lookup.c (pushdecl_maybe_friend): Reuse the
1177 set_underlying_type function to install typedef variant types.
1178 * cp-tree.h (MEMBER_TYPES_NEEDING_ACCESS_CHECK): New template accessor
1180 (append_type_to_template_for_access_check): New entry points.
1181 * semantics.c (check_accessibility_of_qualified_id):
1182 When a typedef that is a member of a class appears in a template,
1183 add it to the template. It will be ...
1184 * pt.c (instantiate_class_template, instantiate_template ): ... access
1185 checked at template instantiation time.
1186 (tsubst): Handle the case of being called with NULL args.
1187 (resolve_type_name_type): The type name should be the name of the
1189 (append_type_to_template_for_access_check): New entry point.
1191 2009-01-19 Jason Merrill <jason@redhat.com>
1194 * parser.c (cp_parser_unqualified_id): In a template,
1196 * typeck.c (lookup_destructor): Handle IDENTIFIER_NODE.
1198 2009-01-16 Jason Merrill <jason@redhat.com>
1201 * tree.c (lvalue_p_1): Allow non-fields in COMPONENT_REF.
1202 * init.c (build_new): Don't call describable_type unless we
1206 * pt.c (tsubst_decl) [USING_DECL]: Propagate access flags.
1209 * search.c (protected_accessible_p): N doesn't vary.
1211 2009-01-15 Jason Merrill <jason@redhat.com>
1214 * pt.c (tsubst_copy_and_build): Tell finish_call_expr to
1215 accept hidden friends.
1217 2009-01-15 Andrew Pinski <andrew_pinski@playstation.sony.com>
1220 * decl.c (grokdeclarator): Check for a non namespace/class context.
1222 2009-01-15 Jason Merrill <jason@redhat.com>
1226 * tree.c (lvalue_p_1): Handle BASELINK. A COMPONENT_REF to
1227 a function isn't necessarily an lvalue. Take tree, not const_tree.
1228 (lvalue_p, real_lvalue_p): Take tree, not const_tree.
1229 * typeck.c (lvalue_or_else): Likewise.
1230 * cp-tree.h: Adjust prototypes.
1232 2009-01-15 Steve Ellcey <sje@cup.hp.com>
1235 * pt.c (tsubst): Check for NULL args.
1237 2009-01-15 Dodji Seketeli <dodji@redhat.com>
1240 * name-lookup.c (pushtag): Don't create members to types that are not
1243 2009-01-14 Nick Clifton <nickc@redhat.com>
1246 * parser.c: Pass cp_id_kind computed in
1247 cp_parser_postfix_dot_deref_expression to
1248 cp_parser_primary_expression.
1250 2009-01-13 Jakub Jelinek <jakub@redhat.com>
1253 * tree.c (cp_walk_subtrees): Handle REINTERPRET_CAST_EXPR,
1254 STATIC_CAST_EXPR, CONST_CAST_EXPR and DYNAMIC_CAST_EXPR the same
1257 2009-01-12 Jason Merrill <jason@redhat.com>
1258 Steve Ellcey <sje@cup.hp.com>
1261 * name-lookup.c (lookup_name_real): Keep looking past a hidden
1264 2009-01-12 Dodji Seketeli <dodji@redhat.com>
1267 * pt.c (parameter_of_template_p): New function.
1268 * cp-tree.h: Declare it.
1269 * name-lookup.c (binding_to_template_parms_of_scope_p): New
1271 (outer_binding): Take template parameters in account when looking for
1274 2009-01-12 Jason Merrill <jason@redhat.com>
1277 * tree.c (pod_type_p): Return 1 for structs created by the back end.
1279 2009-01-12 Jakub Jelinek <jakub@redhat.com>
1282 * parser.c (cp_parser_builtin_offsetof): Allow `->' in
1283 offsetof member-designator, handle it as `[0].'.
1286 * decl.c (start_function): If grokdeclarator hasn't returned
1287 FUNCTION_DECL nor error_mark_node, issue diagnostics.
1289 2009-01-11 Jakub Jelinek <jakub@redhat.com>
1292 * cp-gimplify.c (genericize_if_stmt): Renamed from ...
1293 (gimplify_if_stmt): ... this.
1294 (cp_gimplify_expr): Don't handle IF_STMT here.
1295 (cp_genericize_r): Call genericize_if_stmt for IF_STMT.
1297 2009-01-10 Andrew Pinski <pinskia@gmail.com>
1300 * typeck.c (cp_build_modify_expr): Check for NULL current_function_decl.
1303 * typeck2.c (build_functional_cast): Check for reference type and NULL
1306 2009-01-09 Steve Ellcey <sje@cup.hp.com>
1308 * typeck.c (cp_build_unary_op): Check for ERROR_MARK.
1310 2009-01-09 Jakub Jelinek <jakub@redhat.com>
1313 * error.c (dump_expr): Handle EXPR_STMT like BIND_EXPR.
1315 2009-01-09 John F. Carr <jfc@mit.edu>
1318 * parser.c (cp_parser_class_specifier): Clear
1319 parser->in_unbraced_linkage_specification_p while parsing class
1322 2009-01-07 Jakub Jelinek <jakub@redhat.com>
1325 * semantics.c (finish_goto_stmt): Convert destination to
1328 2009-01-06 Jason Merrill <jason@redhat.com>
1335 * pt.c (check_default_tmpl_args): Don't complain about
1336 out-of-order parameter packs in the enclosing class
1337 or parameter packs after default args.
1338 (coerce_template_parms): If we have more than one
1339 parameter pack, don't flatten argument packs.
1340 (template_args_equal): Handle argument packs.
1341 (comp_template_args): Don't flatten argument packs.
1342 (check_instantiated_arg): Split out from...
1343 (check_instantiated_args): Here. Handle arg packs.
1344 (convert_template_argument): Just check that nontype argument
1345 packs have the right type.
1347 2009-01-05 Dodji Seketeli <dodji@redhat.com>
1350 * typeck.c (type_after_usual_arithmetic_conversions): Fix a typo.
1352 2009-01-05 Jason Merrill <jason@redhat.com>
1355 * typeck2.c (process_init_constructor_union): Handle union with
1358 * mangle.c (write_expression): Remove mangling for zero-operand
1362 * decl.c (cp_finish_decl): Clear DECL_INITIAL for invalid
1366 * class.c (defaultable_fn_p): Only operator== can be a copy
1367 assignment operator.
1369 2009-01-02 Jason Merrill <jason@redhat.com>
1372 * typeck2.c (process_init_constructor_union): Handle excess
1374 (process_init_constructor_record): Likewise.
1377 * typeck2.c (digest_init_r): Don't use process_init_constructor
1378 for non-aggregate classes.
1381 Copyright (C) 2009 Free Software Foundation, Inc.
1383 Copying and distribution of this file, with or without modification,
1384 are permitted in any medium without royalty provided the copyright
1385 notice and this notice are preserved.