1 2009-05-27 Jason Merrill <jason@redhat.com>
3 * call.c (implicit_conversion): Handle conversion from
4 initializer-list to scalar.
5 (convert_like_real): Likewise. Avoid crashing on list
6 initialization with bad conversions.
7 (can_convert): Use LOOKUP_EXPLICIT.
8 (can_convert_arg_bad): Add flags parm.
10 * typeck.c (convert_for_assignment): Pass flags.
12 2009-05-27 Ian Lance Taylor <iant@google.com>
14 * Make-lang.in (g++$(exeext)): Change $(COMPILER) to $(LINKER).
15 (cc1plus-dummy$(exeext), cc1plus$(exeext)): Likewise.
17 2009-05-26 Ian Lance Taylor <iant@google.com>
19 * Make-lang.in (g++spec.o): Use $(COMPILER).
20 (g++$(exeext), cc1plus-dummy$(exeext)): Likewise.
21 (cc1plus$(exeext)): Likewise.
23 2009-05-26 Dodji Seketeli <dodji@redhat.com>
26 * cp-tree.h (MEMBER_TYPES_NEEDING_ACCESS_CHECK): Remove this accessor.
27 (TI_TYPEDEFS_NEEDING_ACCESS_CHECKING): New accessor.
28 (get_types_needing_access_check): Declare new entry point.
29 * pt.c (append_type_to_template_for_access_check_1,
30 get_types_needing_access_check): New functions.
31 (perform_typedefs_access_check): Accept FUNCTION_DECLs and
32 RECORD_TYPEs rather than TEMPLATE_DECLs. Use the new
33 get_types_needing_access_check, no more
34 MEMBER_TYPES_NEEDING_ACCESS_CHECK.
35 (instantiate_class_template): Set input_location to the source
36 location of the most specialized template definition.
37 Perform access check using the RECORD_TYPE of the template, not its
38 associated most generic TEMPLATE_DECL.
39 (append_type_to_template_for_access_check): Augment function
40 comments. Use the new get_types_needing_access_check, not
41 MEMBER_TYPE_NEEDING_ACCESS_CHECK. Use the new
42 append_type_to_template_for_access_check_1 subroutine.
44 2009-05-22 Jason Merrill <jason@redhat.com>
47 * typeck.c (cp_build_binary_op): Allow ENUMERAL_TYPE in
48 arithmetic comparisons.
49 (cp_common_type): Handle scoped enums.
51 * call.c (promoted_arithmetic_type_p): Don't use INTEGRAL_TYPE_P.
52 (add_builtin_candidate, add_builtin_candidates): Likewise.
53 (convert_like_real): Likewise.
54 * class.c (check_bitfield_decl): Likewise.
55 * decl.c (check_static_variable_definition): Likewise.
56 (compute_array_index_type): Likewise.
57 * decl2.c (grokbitfield): Likewise.
58 * init.c (build_new_1): Likewise.
59 * pt.c (convert_nontype_argument): Likewise.
60 (current_instantiation): Likewise.
61 * tree.c (pod_type_p): Likewise.
62 * typeck.c (build_static_cast_1): Likewise.
63 (build_reinterpret_cast_1): Likewise.
65 2009-05-22 Richard Guenther <rguenther@suse.de>
68 * init.c (avoid_placement_new_aliasing): Remove.
69 (build_new_1): Do not call it.
71 2009-05-22 Mark Mitchell <mark@codesourcery.com>
73 * decl2.c (decl_needed_p): Consider dllexport'd functions needed.
74 * semantics.c (expand_or_defer_fn): Similarly.
76 2009-05-20 Ian Lance Taylor <iant@google.com>
78 * parser.c (cp_parser_postfix_expression): Change args to a vec.
80 (tree_vector): Define typedef. Define VEC functions.
81 (cp_parser_parenthesized_expression_list): Change return type to
82 vec. Change all callers.
83 (cp_parser_new_expression): Change placement and initializer to
84 vecs. Release them when done.
85 (cp_parser_new_placement): Change return type to vec. Change all
87 (cp_parser_new_initializer): Likewise.
88 * typeck.c (build_function_call_vec): Just call
89 cp_build_function_call_vec.
90 (cp_build_function_call): Just build a vec and call
91 cp_build_function_call_vec.
92 (cp_build_function_call_vec): New function based on old
93 cp_build_function_call.
94 (convert_arguments): Remove nargs and argarray parameters. Change
95 values to a vec. Change caller.
96 (build_x_compound_expr_from_vec): New function.
97 (cp_build_modify_expr): Build vec to pass to
98 build_special_member_call.
99 * call.c (struct z_candidate): Add first_arg field. Change args
101 (convert_class_to_reference): Handle first argument separately.
102 (add_candidate): Add first_arg parameter. Change args parameter
103 to vec. Change all callers.
104 (add_function_candidate, add_conv_candidate): Likewise.
105 (add_template_candidate_real, add_template_candidate): Likewise.
106 (add_template_conv_candidate): Likewise.
107 (build_user_type_conversion_1): Handle first argument separately.
108 (resolve_args): Change return type and parameter type to vecs.
110 (perform_overload_resolution): Change args parameter to vec.
112 (build_new_function_call, build_operator_new_call): Likewise.
113 (add_candidates): Likewise.
114 (build_op_call): New globally visible function, built from and
115 replacing static function build_object_call.
116 (build_new_op): Don't handle CALL_EXPR. Build vec, not tree_list,
118 (build_op_delete_call): Build vec to pass to
119 cp_build_function_call_vec.
120 (build_temp): Build vec to pass to build_special_member_call.
121 (convert_like_real): Likewise.
122 (perform_direct_initialization_if_possible): Likewise.
123 (build_over_call): Handle first_arg field. Use build_call_array
124 rather than build_call_list.
125 (build_special_member_call): Change args parameter to vec. Change
127 (build_new_method_call): Likewise.
128 * init.c (expand_default_init): Change parms to vec.
129 (build_raw_new_expr): Change placement and init to vecs. Change
131 (build_new_1, build_new): Likewise.
132 * class.c (resolve_address_of_overloaded_function): Build array to
133 pass to fn_type_unification.
134 * pt.c (tsubst_copy_and_build): For NEW_EXPR build vecs to pass to
135 build_new. For CALL_EXPR create a vec rather than a tree_list;
136 expand a pack if necessary.
137 (fn_type_unification): Change args parameter to const tree *. Add
138 nargs parameter. Change all callers.
139 (type_unification_real): Likewise.
140 (unify): Build array to pass to type_unification_real.
141 (get_bindings): Build array to pass to fn_type_unification.
142 (any_type_dependent_arguments_p): Change args parameter to a vec.
144 (make_args_non_dependent): Renamed from build_non_dependent_args.
145 Change return type to void. Change parameter type to vec. Change
147 (do_auto_deduction): Pass an array to type_unification_real.
148 * semantics.c (perform_koenig_lookup): Change args to vec. Change
150 (finish_call_expr): Change args to vec. Change all callers. Call
151 build_op_call instead of passing CALL_EXPR to build_new_op.
152 (cxx_omp_create_clause_info): Allocate vec to pass to
153 build_special_member_call.
154 * decl2.c (build_offset_ref_call_from_tree): Change args parameter
155 to vec. Change all callers.
156 * name-lookup.c (lookup_function_nonclass): Likewise.
157 (struct arg_lookup): Change args to vec.
158 (arg_assoc_namespace): Handle args as a vec.
159 (arg_assoc_args_vec): New static function.
160 (lookup_arg_dependent): Change args parameter to vec. Change all
162 * method.c (do_build_assign_ref): Allocate vec to pass to
163 build_special_member_call.
164 * except.c (build_throw): Likewise.
165 * typeck2.c (build_functional_cast): Likewise.
166 * cvt.c (ocp_convert): Likewise.
167 * tree.c (build_min_non_dep_call_vec): Change last parameter to
168 vec. Change all callers.
169 * cp-tree.h: Update declarations.
170 * name-lookup.h: Update declarations.
172 2009-05-20 Sandra Loosemore <sandra@codesourcery.com>
174 * typeck.c (default_conversion): Check targetm.promoted_type.
175 * decl.c (grokdeclarator): Check targetm.invalid_return_type.
176 (grokparms): Check targetm.invalid_parameter_type.
177 * cvt.c (ocp_convert): Check targetm.convert_to_type.
178 (build_expr_type_conversion): Check targetm.promoted_type.
180 2009-05-19 Andrew Pinski <andrew_pinski@playstation.sony.com>
182 * typeck.c (build_binary_op): Allow % on integal vectors.
184 2009-05-18 Jason Merrill <jason@redhat.com>
186 Implement explicit conversions ops as specified in N2437.
187 * decl.c (grokdeclarator): Handle explicit conversion ops.
188 (check_initializer): Pass flags to store_init_value.
189 * decl2.c (maybe_emit_vtables): Likewise.
190 * init.c (expand_aggr_init_1): Likewise.
191 * call.c (convert_class_to_reference): Take flags parm,
192 check DECL_NONCONVERTING_P.
193 (build_user_type_conversion_1): Check DECL_NONCONVERTING_P.
194 (add_builtin_candidates): Simplify getting type of conversion.
195 (build_object_call): Likewise. Check DECL_NONCONVERTING_P.
196 (implicit_conversion): Pass through LOOKUP_ONLYCONVERTING.
197 (reference_binding): Take flags parm. Direct-initialize copy parm.
198 (add_function_candidate): Direct-initialize the copy parm.
199 (add_conv_candidate): Use LOOKUP_IMPLICIT, not LOOKUP_NORMAL.
200 (build_builtin_candidate): Add LOOKUP_ONLYCONVERTING.
201 (conditional_conversion): Likewise.
202 (convert_like_real): Only complain about DECL_NONCONVERTING_P
204 (perform_implicit_conversion_flags): Add flags parm to
205 perform_implicit_conversion. Improve diagnostics.
206 * cp-tree.h (LOOKUP_IMPLICIT): New macro.
207 (LOOKUP_COPY_PARM): New bit macro.
208 * cvt.c (build_expr_type_conversion): Check DECL_NONCONVERTING_P.
209 * typeck.c (convert_for_assignment): Take flags parm, pass it to
210 perform_implicit_conversion_flags.
211 (cp_build_modify_expr): Pass flags to convert_for_assignment.
212 (convert_for_initialization): Likewise.
213 * typeck2.c (store_init_value): Take flags parm, pass to
215 (digest_init_flags): Add flags parm to digest_init.
216 (digest_init_r): Take flags parm, pass to convert_for_initialization.
217 (process_init_constructor_array): Pass it.
218 (process_init_constructor_record): Likewise.
219 (process_init_constructor_union): Likewise.
221 2009-05-16 Jason Merrill <jason@redhat.com>
224 * pt.c (tsubst_qualified_id): Retain the type if we aren't dealing
225 with a dependent type. Actually look up the destructor.
226 * semantics.c (finish_id_expression): Fix logic.
227 (finish_qualified_id_expr): Don't try to use 'this' if we aren't in
229 * typeck.c (build_x_unary_op): Diagnose taking the address of a
230 constructor or destructor.
231 * tree.c (get_first_fn): Handle OFFSET_REF.
233 2009-05-17 Joseph Myers <joseph@codesourcery.com>
235 * tree.c (cxx_printable_name_internal): Allow consecutive
236 translated and untranslated cached copies of the name of the
239 2009-05-15 Ian Lance Taylor <iant@google.com>
241 * cp-tree.h (enum cp_lvalue_kind_flags): Rename from
242 cp_lvalue_kind. Change all uses.
243 (enum base_access_flags): Rename from enum base_access. Change
245 * parser.c (enum cp_parser_flags): Remove enum tag.
247 2009-05-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
250 * call.c (build_new_op): Update calls to warn_logical_operator.
252 2009-05-14 Ian Lance Taylor <iant@google.com>
254 * class.c (layout_class_type): Change itk to unsigned int.
255 * decl.c (finish_enum): Change itk to unsigned int.
256 * parser.c (cp_parser_check_decl_spec): Change ds to int. Remove
259 2009-05-13 David Mandelin <dmandelin@mozilla.com>:
261 * decl.c (duplicate_decls): Preserve parameter attributes.
263 2009-05-10 Jan Hubicka <jh@suse.cz>
265 * decl2.c (cxx_callgraph_analyze_expr): Use
266 cgraph_mark_address_taken.
268 2009-05-10 Joseph Myers <joseph@codesourcery.com>
270 * call.c (name_as_c_string): Call type_as_string_translate.
271 Translate identifiers to locale character set.
272 * cp-tree.h (lang_decl_name): Update prototype.
273 (type_as_string_translate, decl_as_string_translate,
274 cxx_printable_name_translate): Declare.
275 * cxx-pretty-print.c (M_): Define.
276 (pp_cxx_unqualified_id, pp_cxx_canonical_template_parameter): Mark
277 English fragments for conditional translation with M_.
278 * decl.c (grokdeclarator): Translate identifiers to locale
279 character set for diagnostics.
280 * error.c (M_): Define.
281 (dump_template_bindings, dump_type, dump_aggr_type,
282 dump_type_prefix, dump_global_iord, dump_simple_decl, dump_decl,
283 dump_function_decl, dump_template_parms, dump_expr,
284 dump_binary_op, op_to_string, assop_to_string): Mark English
285 fragments for conditional translation with M_.
286 (type_as_string): Disable translation of identifiers.
287 (type_as_string_translate): New.
288 (expr_as_string): Disable translation of identifiers.
289 (decl_as_string): Disable translation of identifiers.
290 (decl_as_string_translate): New.
291 (lang_decl_name): Add parameter translate.
292 (args_to_string): Call type_as_string_translate.
293 (cp_print_error_function): Call cxx_printable_name_translate.
294 (print_instantiation_full_context,
295 print_instantiation_partial_context): Call
296 decl_as_string_translate.
297 * parser.c (cp_lexer_get_preprocessor_token): Use %qE for
298 identifier in diagnostic.
299 * tree.c (cxx_printable_name): Change to
300 cxx_printable_name_internal. Add parameter translate.
301 (cxx_printable_name, cxx_printable_name_translate): New wrappers
302 round cxx_printable_name_internal.
304 2009-05-08 H.J. Lu <hongjiu.lu@intel.com>
307 * call.c (build_call_a): Updated warn_deprecated_use call.
308 (build_over_call): Likewise.
309 * decl.c (grokdeclarator): Likewise.
310 (grokparms): Likewise.
311 * semantics.c (finish_id_expression): Likewise.
312 * typeck.c (build_class_member_access_expr): Likewise.
313 (finish_class_member_access_expr): Likewise.
315 2009-05-06 Dodji Seketeli <dodji@redhat.com>
318 * pt.c (tsubst_copy) <case PARM_DECL>: We don't want to tsubst the
319 whole list of PARM_DECLs, just the current one.
321 2009-05-05 Shujing Zhao <pearly.zhao@oracle.com>
324 (opname_tab, assignop_tab, update_member_visibility, yyerror, yyhook,
325 mangle_compound_literal): Remove unused declarations.
326 (build_vfield_ref, cxx_print_statistics, clone_function_decl,
327 adjust_clone_args, maybe_push_cleanup_level, pushtag, make_anon_name,
328 pushdecl_top_level_maybe_friend, pushdecl_top_level_and_finish,
329 check_for_out_of_scope_variable, print_other_binding_stack,
330 maybe_push_decl, cxx_mark_addressable, force_target_expr,
331 build_target_expr_with_type, finish_case_label,
332 cxx_maybe_build_cleanup, begin_eh_spec_block, finish_eh_spec_block,
333 check_template_keyword, cxx_omp_predetermined_sharing,
334 cxx_omp_clause_default_ctor, cxx_omp_clause_copy_ctor,
335 cxx_omp_clause_assign_op, cxx_omp_clause_dtor, cxx_omp_finish_clause,
336 cxx_omp_privatize_by_reference): Rearrange the declarations line to
337 match the comment that indicates the .c file which the functions are
339 (cxx_print_xnode, cxx_print_decl, cxx_print_type,
340 cxx_print_identifier, cxx_print_error_function, pushdecl): Add comment.
342 2009-05-05 Nathan Sidwell <nathan@codesourcery.com>
344 * typeck.c (cp_build_compound_expr): Require RHS to have a known
346 * class.c (resolve_address_of_overloaded_function): Use
347 OVL_CURRENT for error message.
348 (instantiate_type): Forbid COMPOUND_EXPRs and remove code dealing
349 with them. Do not copy the node.
351 2009-05-05 Jakub Jelinek <jakub@redhat.com>
354 * pt.c (tsubst): If magic NOP_EXPR with side-effects has no type,
355 set it from its operand's type after tsubst_expr.
357 2009-05-04 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
360 * parser.c (cp_lexer_get_preprocessor_token): Do not store the
361 canonical spelling for keywords.
362 (cp_parser_attribute_list): Use the canonical spelling for
363 keywords in attributes.
365 2009-05-01 Joseph Myers <joseph@codesourcery.com>
367 * cxx-pretty-print.c (is_destructor_name, pp_cxx_unqualified_id,
368 pp_cxx_template_keyword_if_needed, pp_cxx_postfix_expression,
369 pp_cxx_new_expression, pp_cxx_delete_expression,
370 pp_cxx_unary_expression, pp_cxx_assignment_operator,
371 pp_cxx_assignment_expression, pp_cxx_expression,
372 pp_cxx_function_specifier, pp_cxx_decl_specifier_seq,
373 pp_cxx_simple_type_specifier, pp_cxx_type_specifier_seq,
374 pp_cxx_exception_specification, pp_cxx_direct_declarator,
375 pp_cxx_ctor_initializer, pp_cxx_type_id, pp_cxx_statement,
376 pp_cxx_namespace_alias_definition, pp_cxx_template_parameter,
377 pp_cxx_canonical_template_parameter, pp_cxx_template_declaration,
378 pp_cxx_declaration, pp_cxx_typeid_expression,
379 pp_cxx_va_arg_expression, pp_cxx_offsetof_expression,
380 pp_cxx_trait_expression): Mostly use pp_string and
381 pp_cxx_ws_string in place of pp_identifier and pp_cxx_identifier
382 for non-identifiers. Mark English strings for translation.
383 * cxx-pretty-print.h (pp_cxx_ws_string): Define.
384 * error.c (dump_template_parameter, dump_template_bindings,
385 dump_type, dump_aggr_type, dump_type_prefix, dump_simple_decl,
386 dump_decl, dump_template_decl, dump_function_decl,
387 dump_parameters, dump_exception_spec, dump_template_parms,
388 dump_expr, dump_binary_op, dump_unary_op, op_to_string,
389 assop_to_string, args_to_string, cp_print_error_function,
390 print_instantiation_full_context,
391 print_instantiation_partial_context): Mostly use pp_string and
392 pp_cxx_ws_string in place of pp_identifier and pp_cxx_identifier
393 for non-identifiers. Mark English strings for translation.
394 (dump_global_iord): Mark strings for translation; use longer
395 strings instead of substituting single words.
396 (function_category): Return a format string marked for
397 translation, not a single word or phrase to substitute in a longer
400 2009-04-28 Ben Elliston <bje@au.ibm.com>
405 2009-03-27 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
407 * typeck.c (cp_pointer_sum): Adjust call to pointer_int_sum.
409 2009-04-27 Ian Lance Taylor <iant@google.com>
411 * semantics.c (finish_omp_clauses): Change type of c_kind to enum
414 2009-04-27 Jakub Jelinek <jakub@redhat.com>
417 * cvt.c (convert_to_void) <case INDIRECT_REF>: Only warn about
418 -Wunused-value if implicit.
420 2009-04-24 Ian Lance Taylor <iant@google.com>
422 * call.c (build_temp): Change 0 to enum constant.
423 * cp-tree.h (cp_lvalue_kind): Typedef to int rather than enum
425 * cp-gimplify.c (cp_gimplify_expr): Add cast to enum type.
426 * decl2.c (constrain_visibility): Likewise.
427 * parser.c (cp_lexer_get_preprocessor_token): Likewise.
428 (cp_parser_flags): Typedef to int rather than enum type.
429 (cp_parser_expression_stack_entry): Change prec field to enum
432 * typeck.c (build_modify_expr): Add lhs_origtype parameter.
435 2009-04-22 Dodji Seketeli <dodji@redhat.com>
438 * parser.c (cp_parser_template_argument_list): Display an error
439 when an ellipsis is not preceded by a parameter pack. Also, warn
440 about variadic templates usage without -std=c++0x.
442 2009-04-21 Taras Glek <tglek@mozilla.com>
444 * cp-tree.h: Update GTY annotations to new syntax.
446 * mangle.c: Likewise.
447 * name-lookup.c: Likewise.
448 * name-lookup.h: Likewise.
449 * parser.c: Likewise.
452 * semantics.c: Likewise.
453 * typeck2.c: Likewise.
455 2009-04-22 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
458 * parser.c (cp_parser_error): Pass token->flags to c_parse_error.
460 2009-04-21 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
463 * typeck.c (check_for_casting_away_constness): We diagnose casting
464 away any qualifiers not just constness.
465 (casts_away_constness): Mention that it handles more than just
468 2009-04-21 Joseph Myers <joseph@codesourcery.com>
470 * ChangeLog, ChangeLog-1993, ChangeLog-1994, ChangeLog-1995,
471 ChangeLog-1996, ChangeLog-1997, ChangeLog-1998, ChangeLog-1999,
472 ChangeLog-2000, ChangeLog-2001, ChangeLog-2002, ChangeLog-2003,
473 ChangeLog-2004, ChangeLog-2005, ChangeLog-2006, ChangeLog-2007,
474 ChangeLog-2008, ChangeLog.ptr, ChangeLog.tree-ssa, NEWS,
475 cfns.gperf: Add copyright and license notices.
476 * cfns.h: Regenerate.
477 * ChangeLog, ChangeLog-2004: Correct dates.
479 2009-04-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
482 * tree.c (lvalue_p_1): Use const_tree.
483 Use CONST_CAST_TREE to avoid warning.
484 (lvalue_p): Returns bool, receives const_tree.
486 2009-04-21 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
489 * parser.c (cp_parser_check_decl_spec): Drop redundant flags.
490 * error.c (pedwarn_cxx98): New.
491 * cp-tree.h (pedwarn_cxx98): Declare.
493 2009-04-20 Le-Chun Wu <lcwu@google.com>
496 * init.c (build_vec_init): Set TREE_NO_WARNING on the
497 compiler-generated INDIRECT_REF expression.
499 2009-04-20 Ian Lance Taylor <iant@google.com>
501 * typeck.c (build_function_call_vec): New function.
502 (cp_build_function_call): Only pass first parameter to
503 objc_rewrite_function_call.
504 (build_modify_expr): Add rhs_origtype parameter. Change all
506 * decl.c (finish_decl): Add origtype parameter. Change all
508 * semantics.c (finish_call_expr): Pass VEC to
509 resolve_overloaded_builtin.
511 2009-04-20 Ian Lance Taylor <iant@google.com>
513 * cp-tree.h (base_access): Change typedef to int.
514 * parser.c (cp_parser_omp_flush): Change 0 to OMP_CLAUSE_ERROR.
515 (cp_parser_omp_threadprivate): Likewise.
516 * pt.c (unify_pack_expansion): Add casts to enum type.
518 2009-04-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
522 * call.c (build_new_op): Save the original codes of operands
525 2009-04-18 Kazu Hirata <kazu@codesourcery.com>
527 * cp-tree.h: Remove the prototype for insert_block.
528 * decl.c (insert_block): Remove.
530 2009-04-16 Ian Lance Taylor <iant@google.com>
532 * cp-tree.h (enum tsubst_flags): Rename from enum tsubst_flags_t.
533 (tsubst_flags_t): Change typedef from enum type to int.
535 2009-04-16 Paolo Bonzini <bonzini@gnu.org>
537 * decl.c (check_initializer): Use TYPE_VECTOR_OPAQUE
538 instead of targetm.vector_opaque_p.
540 2009-04-15 Le-Chun Wu <lcwu@google.com>
543 * call.c (build_over_call): Set TREE_NO_WARNING on the
544 compiler-generated INDIRECT_REF expression.
545 * cvt.c (convert_to_void): Emit warning when stripping off
548 2009-04-14 Diego Novillo <dnovillo@google.com>
550 * parser.c (cp_parser_type_specifier_seq): Move call to
551 invoke_plugin_callbacks ...
552 (cp_parser_type_specifier_seq): ... here.
554 2009-04-14 Le-Chun Wu <lcwu@google.com>
556 * Make-lang.in: Modify dependencies of files including plugin.h.
557 * decl.c (finish_function): Call invoke_plugin_callbacks.
558 * parser.c (cp_parser_type_specifier): Call invoke_plugin_callbacks.
560 2009-04-14 Jason Merrill <jason@redhat.com>
563 * name-lookup.c (pushdecl_maybe_friend): Avoid all warnings
564 about shadowing by tentative parms.
566 2009-04-13 Jason Merrill <jason@redhat.com>
569 * call.c (build_over_call): Don't call memcpy if the target is
570 the same as the source.
572 2009-04-13 Jason Merrill <jason@redhat.com>
575 * pt.c (uses_template_parms): Handle CONSTRUCTOR.
577 2009-04-12 Jason Merrill <jason@redhat.com>
580 * call.c (joust): Don't crash on variadic fn.
582 2009-04-10 Jason Merrill <jason@redhat.com>
585 * parser.c (cp_parser_skip_to_end_of_block_or_statement): Return
586 if we see a close brace without an open brace.
588 2009-04-10 H.J. Lu <hongjiu.lu@intel.com>
590 * parser.c (cp_parser_class_specifier): Remove the unused
591 has_trailing_semicolon.
593 2009-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
596 * parser.c (cp_parser_check_template_parameters): Take a
597 cp_declarator parameter.
598 (cp_parser_elaborated_type_specifier): Update to
599 cp_parser_check_template_parameters.
600 (cp_parser_class_head): Likewise.
601 (cp_parser_check_declarator_template_parameters): Likewise.
602 (cp_parser_check_template_parameters): Handle first the non-error
603 conditions. Give more accurate diagnostics if a declarator is
606 2009-04-08 Jason Merrill <jason@redhat.com>
609 * error.c (dump_aggr_type): Chase template typedefs if
610 -fno-pretty-templates.
612 2009-04-08 Dodji Seketeli <dodji@redhat.com>
615 * parser.c (cp_parser_enumerator_definition): Make sure the
616 initializer of the enumerator doesn't contain any bare parameter pack.
618 2009-04-07 Jason Merrill <jason@redhat.com>
621 * name-lookup.c (merge_functions): Keep multiple extern "C" functions.
622 * call.c (joust): Complain about mismatched default arguments
623 in extern "C" functions.
624 * class.c (resolve_address_of_overloaded_function): Handle multiple
625 extern "C" functions.
626 * pt.c (resolve_overloaded_unification): Likewise.
628 2009-04-07 Jason Merrill <jason@redhat.com>
631 * error.c (dump_function_decl): Don't pretty-print templates
632 if -fno-pretty-templates.
633 (count_non_default_template_args): Print all args if
634 -fno-pretty-templates.
636 2009-04-06 Jason Merrill <jason@redhat.com>
639 * pt.c (fn_type_unification): For DEDUCE_EXACT check that
640 the deduced template arguments give us the parameter types
643 2009-04-05 Giovanni Bajo <giovannibajo@libero.it>
644 Jason Merrill <jason@redhat.com>
647 * error.c (count_non_default_template_args): New fn.
648 (dump_template_parms): Call it.
649 (dump_template_argument_list): Call it. Add parms parm.
650 (dump_template_argument): Adjust call to dump_template_argument_list.
651 (dump_type, dump_decl): Likewise.
652 (dump_template_bindings): Refactor logic.
654 2009-04-03 Jason Merrill <jason@redhat.com>
657 * error.c (dump_template_bindings): Look through typedefs in
659 (dump_type) [TYPENAME_TYPE]: Print the typedef name if any.
660 (find_typenames_r): Also collect typedefs.
661 * pt.c (unify): Strip typedefs.
664 * semantics.c (finish_id_expression): Don't assume a dependent
665 member of the current instantiation isn't a valid integral
666 constant expression. Check dependent_scope_p.
667 * pt.c (dependent_scope_p): Check TYPE_P.
668 (tsubst_copy): If args is null, just return.
670 2009-04-02 Jason Merrill <jason@redhat.com>
673 * error.c (find_typenames, find_typenames_r): New fns.
674 (dump_function_decl): Call find_typenames.
675 (dump_template_bindings): Print typenames as well.
676 * pt.c (tsubst): Non-static.
677 * cp-tree.h: Declare it.
679 2009-04-02 Dodji Seketeli <dodji@redhat.com>
682 * decl2.c (grokfield): when a typedef appears in a
683 class, create the typedef variant type node for it.
684 (save_template_attributes): Creating typedef variant type node
686 * decl.c (grokdeclarator): If the typedef'ed struct/class was
687 anonymous, set the proper type name to all its type variants.
688 (xref_basetypes) : Fixup the variant types after setting
690 * name-lookup.c (pushdecl_maybe_friend): Reuse the
691 set_underlying_type function to install typedef variant types.
692 * cp-tree.h (MEMBER_TYPES_NEEDING_ACCESS_CHECK): New template accessor
694 (append_type_to_template_for_access_check): New entry points.
695 * semantics.c (check_accessibility_of_qualified_id):
696 When a typedef that is a member of a class appears in a template,
697 add it to the template. It will be ...
698 * class.c (finish_struct_bits): Split type variant fixup into ...
699 (fixup_type_variants): A new entry point.
700 * pt.c (instantiate_class_template, instantiate_template ): ... access
701 checked at template instantiation time.
702 (resolve_type_name_type): The type name should be the name of the
704 (retrieve_specialization): Specializations of template typedefs aren't
705 to looked up in DECL_TEMPLATE_INSTANTIATIONS (tmpl).
706 (append_type_to_template_for_access_check): New entry point.
707 (tsubst_decl): For typedefs, build the variant type from the correct
709 (get_class_bindings): Fix function comment.
710 (perform_typedefs_access_check): New entry point.
712 2009-03-31 Jason Merrill <jason@redhat.com>
715 * name-lookup.c (pushdecl_maybe_friend): Diagnose mismatched
716 extern "C" declarations.
719 * semantics.c (finish_non_static_data_member): Allow such references
720 without an associated object in sizeof/decltype/alignof.
722 * ptree.c (cxx_print_decl): Pretty-print full name of
724 (cxx_print_type): Pretty-print full name of class.
726 * decl.c (grokdeclarator): Reject pointer to qualified function
729 PR c++/37806, core issue 547
730 * typeck.c (cp_apply_type_quals_to_decl): Don't apply any quals
732 * tree.c (cp_build_qualified_type_real): Don't apply restrict to a
734 * decl.h (enum decl_context): Add TEMPLATE_TYPE_ARG.
735 * decl.c (groktypename): Add is_template_arg parameter.
736 (grokdeclarator): Allow function cv-quals on a template type arg.
737 * parser.c (cp_parser_new_type_id, cp_parser_type_id): Add
738 is_template_arg argument in calls to groktypename.
739 * cp-tree.h: Adjust prototype.
740 * error.c (dump_type_prefix, dump_type_suffix): Fix plain
741 FUNCTION_TYPE printing.
743 * mangle.c (write_expression): Mangle dependent name as
746 PR c++/38030, 38850, 39070
747 * pt.c (type_dependent_expression_p_push): New fn.
748 (tsubst_copy_and_build) [CALL_EXPR]: Only do arg-dep lookup when the
749 substitution makes the call non-dependent. Preserve koenig_p.
750 * parser.c (cp_parser_postfix_expression): Only do arg-dep lookup
751 for non-dependent calls.
752 * semantics.c (finish_call_expr): Revert earlier changes.
753 * cp-tree.h: Revert change to finish_call_expr prototype.
755 2009-03-29 Joseph Myers <joseph@codesourcery.com>
757 PR preprocessor/34695
758 * cp-tree.h (cp_cpp_error): Remove.
759 * error.c (cp_cpp_error): Remove.
760 * parser.c (cp_lexer_new_main): Set done_lexing instead of
761 client_diagnostic and error callback.
763 2009-03-28 Paolo Bonzini <bonzini@gnu.org>
765 * cp/cp-objcp-common.h (LANG_HOOKS_STATICP): Remove.
766 * cp/cp-objcp-common.c (cxx_staticp): Remove.
767 * cp/cp-tree.h (cxx_staticp): Remove.
769 2009-03-28 Jakub Jelinek <jakub@redhat.com>
772 * parser.c (cp_parser_postfix_expression): Don't call
773 warning_if_disallowed_function_p.
775 2009-03-27 Jan Hubicka <jh@suse.cz>
777 * except.c (choose_personality_routine): Set terminate_node to abort
780 2009-03-27 Dodji Seketeli <dodji@redhat.com>
781 Jakub Jelinek <jakub@redhat.com>
784 * cp-objcp-common.h (LANG_HOOKS_FUNCTION_DECL_EXPLICIT_P): Define.
785 (cp_function_decl_explicit_p): New prototype.
786 * cp-objcp-common.c (cp_function_decl_explicit_p): New function.
788 2009-03-27 Andrew Pinski <andrew_pinski@playstation.sony.com>
791 * parser.c (cp_parser_elaborated_type_specifier): If we have a
792 typename tag and don't have either a TYPE_DECL or a
793 TEMPLATE_ID_EXPR, set the type to NULL.
795 2009-03-27 Simon Martin <simartin@users.sourceforge.net>
798 * decl.c (grokdeclarator): Reject [con|de]stuctors in a non-class
801 2009-03-27 Simon Martin <simartin@users.sourceforge.net>
804 * decl.c (check_array_designated_initializer): Handle error_mark_node.
806 2009-03-27 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
809 * typeck.c (cp_pointer_sum): Adjust call to pointer_int_sum.
811 2009-03-26 Andrew Haley <aph@redhat.com>
814 * decl2.c (possibly_inlined_p): If java exceptions are in use
815 don't inline a decl unless it is explicitly marked inline.
816 * lex.c: (pragma_java_exceptions): New variable.
817 (handle_pragma_java_exceptions): Set pragma_java_exceptions.
818 * cp-tree.h (pragma_java_exceptions): Declare new variable.
820 2009-03-24 Jason Merrill <jason@redhat.com>
823 * name-lookup.c (pushdecl_maybe_friend): Check default args later.
825 2009-03-23 Jakub Jelinek <jakub@redhat.com>
828 * semantics.c (handle_omp_for_class_iterator): Swap cond operands and
829 code if iter is the second operand.
830 * parser.c (cp_parser_binary_expression): Add no_toplevel_fold_p
831 argument. If it is set, don't build the toplevel expression with
832 build_x_binary_op, but build2.
833 (cp_parser_assignment_expression, cp_parser_omp_for_incr): Adjust
835 (cp_parser_omp_for_cond): Don't assume the first operand of the
836 comparison must be decl.
838 2009-03-23 Jason Merrill <jason@redhat.com>
841 * pt.c (make_fnparm_pack): Split out from...
842 (instantiate_decl): ...here.
843 (tsubst_pack_expansion): Handle being called in a late-specified
847 * name-lookup.c (pushdecl_maybe_friend): Don't warn about shadowing
850 2009-03-20 Jason Merrill <jason@redhat.com>
853 * parser.c (cp_parser_direct_declarator): In a template, wrap
854 non-constant expression in NOP_EXPR with TREE_SIDE_EFFECTS set.
855 * pt.c (tsubst): Preserve it in a partial instantiation.
856 (dependent_type_p_r): Don't check value_dependent_expression_p.
857 * decl.c (compute_array_index_type): Don't check
858 value_dependent_expression_p if TREE_SIDE_EFFECTS.
861 * typeck2.c (check_narrowing): Don't complain about loss of
862 precision when converting a floating-point constant.
864 2009-03-19 Jakub Jelinek <jakub@redhat.com>
867 * parser.c (cp_parser_omp_for_cond): Don't check lhs if decl is NULL.
868 (cp_parser_omp_for_loop): Always use cp_parser_omp_for_cond.
870 2009-03-18 Jakub Jelinek <jakub@redhat.com>
872 * parser.c (struct cp_token): Reorder fields for 64-bit hosts.
875 2009-03-18 H.J. Lu <hongjiu.lu@intel.com>
878 * parser.c (cp_parser_explicit_specialization): Don't skip the
879 rest of the specialization when begin_specialization returns
882 2009-03-17 Jason Merrill <jason@redhat.com>
884 * decl.c (grokfndecl): Set DECL_CONTEXT on parms.
885 (duplicate_decls): Adjust DECL_CONTEXT of newdecl's parms.
886 * pt.c (check_explicit_specialization): Likewise.
887 (tsubst_copy) [PARM_DECL]: Return a dummy parm if we don't have a
888 local specialization.
889 * tree.c (cp_tree_equal) [PARM_DECL]: Check type and index, not name.
890 * decl2.c (parm_index): New fn.
891 * semantics.c (finish_decltype_type): Don't use describable_type.
892 * mangle.c (write_expression): Likewise. Mangle ALIGNOF_EXPR.
893 Give a sorry for unsupported codes rather than crash. Mangle
894 conversions with other than 1 operand. New mangling for PARM_DECL.
895 * operators.def (ALIGNOF_EXPR): Mangle as "az".
897 2009-03-17 Jing Yu <jingyu@google.com>
900 * method.c (use_thunk): Change is_thunk from crtl to cfun.
902 2009-03-17 Paolo Carlini <paolo.carlini@oracle.com>
905 * semantics.c (check_trait_type): New.
906 (finish_trait_expr): Use it.
908 2009-03-17 Jakub Jelinek <jakub@redhat.com>
910 * name-lookup.c (cp_emit_debug_info_for_using): Emit USING_STMTs
911 instead of calling imported_module_or_decl debug hook if
912 building_stmt_tree ().
913 * cp-gimplify.c (cp_gimplify_expr): Don't assert the first operand
917 * name-lookup.c (do_namespace_alias): Don't call global_decl debug
918 hook at function scope.
921 * cp-gimplify.c (cp_gimplify_expr): Don't set DECL_NAME
924 2009-03-09 Jakub Jelinek <jakub@redhat.com>
927 * semantics.c (finish_switch_cond): Don't call get_unwidened.
928 * decl.c (finish_case_label): Pass SWITCH_STMT_TYPE as 3rd argument
929 instead of TREE_TYPE (cond).
931 2009-03-08 H.J. Lu <hongjiu.lu@intel.com>
934 * parser.c (cp_parser_late_parsing_default_args): Continue
935 the loop when cp_parser_assignment_expression returns
938 2009-03-07 Jason Merrill <jason@redhat.com>
941 * init.c (build_new_1): Don't use a VLA type.
942 (build_vec_init): Handle getting a pointer for BASE.
944 2009-03-06 H.J. Lu <hongjiu.lu@intel.com>
947 * cp-tree.h: Check NO_DOT_IN_LABEL before NO_DOLLAR_IN_LABEL
948 when mangling symbols.
950 2009-03-06 Paolo Carlini <paolo.carlini@oracle.com>
953 * error.c (dump_expr): Don't try to print THROW_EXPRs in full.
955 2009-03-06 Alexandre Oliva <aoliva@redhat.com>
957 * decl.c (record_builtin_java_type): Use canonicalized integer
960 2009-03-04 Jason Merrill <jason@redhat.com>
963 * class.c (is_really_empty_class): New fn.
964 * cp-tree.h: Declare it.
965 * cp-objcp-common.c (cp_expr_size): Use it.
968 * semantics.c (perform_koenig_lookup): Handle TEMPLATE_ID_EXPR.
969 * parser.c (cp_parser_postfix_expression): Call it for
971 * tree.c (is_overloaded_fn): Look through TEMPLATE_ID_EXPR.
972 (get_first_fn): Likewise.
978 * decl.c (make_typename_type): Do look inside currently open classes.
979 * parser.c (cp_parser_lookup_name): Likewise.
980 (cp_parser_template_name): Likewise.
981 * pt.c (dependent_scope_p): New function.
982 * cp-tree.h: Declare it.
983 * class.c (currently_open_class): Return fast if T isn't a class.
985 2009-02-26 H.J. Lu <hongjiu.lu@intel.com>
988 * parser.c (cp_parser_mem_initializer): Return error_mark_node
989 if cp_parser_mem_initializer_id returns error_mark_node.
991 2009-02-24 Richard Guenther <rguenther@suse.de>
994 * pt.c (instantiate_decl): Do not instantiate extern, non-inline
997 2009-02-23 H.J. Lu <hongjiu.lu@intel.com>
1000 * pt.c (coerce_template_template_parms): Return 0 if parameter
1003 2009-02-23 Jason Merrill <jason@redhat.com>
1005 * pt.c (unify): Call maybe_adjust_types_for_deduction when
1006 deducing from an initializer list.
1008 2009-02-20 Jason Merrill <jason@redhat.com>
1011 * decl.c (grokdeclarator): Handle ~identifier.
1013 2009-02-19 Jakub Jelinek <jakub@redhat.com>
1016 * decl2.c (determine_visibility): If visibility changed and
1017 DECL_RTL has been already set, call make_decl_rtl to update symbol
1020 2009-02-19 H.J. Lu <hongjiu.lu@intel.com>
1023 * cp-tree.h (maybe_commonize_var): New.
1025 * decl.c (maybe_commonize_var): Make it extern.
1027 * decl2.c (finish_anon_union): Call maybe_commonize_var.
1029 2009-02-18 H.J. Lu <hongjiu.lu@intel.com>
1032 * parser.c (cp_parser_enum_specifier): Apply all attributes.
1034 2009-02-18 Jason Merrill <jason@redhat.com>
1036 * cfns.h: Tweak pathname for cfns.gperf.
1038 2009-02-13 Jason Merrill <jason@redhat.com>
1041 * semantics.c (finish_call_expr): Change koenig_p parm to int.
1042 If -1, don't set KOENIG_LOOKUP_P but do keep hidden candidates.
1043 * cp-tree.h: Adjust prototype.
1044 * pt.c (tsubst_copy_and_build) [CALL_EXPR]: Pass -1.
1046 2009-02-12 Jason Merrill <jason@redhat.com>
1049 * pt.c (unify)[TEMPLATE_PARM_INDEX]: Convert to the tsubsted type.
1051 2009-02-11 Jason Merrill <jason@redhat.com>
1054 * decl2.c (cp_write_global_declarations):
1055 Check DECL_DEFAULTED_FN, not DECL_ARTIFICIAL.
1058 * init.c (build_value_init_noctor): Split out from...
1059 (build_value_init): ...here.
1060 (expand_aggr_init_1): Handle value-initialization.
1061 * cp-tree.h: Add declaration.
1062 * class.c (type_has_user_provided_constructor):
1063 Handle non-class arguments.
1065 2009-02-10 Jason Merrill <jason@redhat.com>
1068 * class.c (defaultable_fn_p): Handle ... properly.
1071 * tree.c (lvalue_p_1): Condition rvalue ref handling on
1072 treat_class_rvalues_as_lvalues, too.
1074 2009-02-10 Paolo Carlini <paolo.carlini@oracle.com>
1077 * typeck.c (build_x_array_ref): New.
1078 * cp-tree.h: Declare it.
1079 * pt.c (tsubst_copy_and_build): Use it for case ARRAY_REF.
1081 2009-02-09 Jason Merrill <jason@redhat.com>
1084 * semantics.c (simplify_aggr_init_expr): Do zero-initialization here.
1085 * init.c (build_value_init): Not here. Don't build a TARGET_EXPR.
1086 * tree.c (get_target_expr): Handle AGGR_INIT_EXPR.
1087 * cp-gimplify.c (cp_gimplify_init_expr): Remove special handling
1088 for build_value_init TARGET_EXPR.
1089 * cp-tree.h (AGGR_INIT_ZERO_FIRST): New macro.
1091 2009-02-06 Paolo Carlini <paolo.carlini@oracle.com>
1095 * cp-tree.h (TMPL_ARGS_HAVE_MULTIPLE_LEVELS): Check TREE_VEC_LENGTH.
1097 2009-02-04 Jakub Jelinek <jakub@redhat.com>
1100 * operators.def: Use COMPONENT_REF code for ->/pt operator again,
1101 remove ./dt operator.
1102 * mangle.c (write_expression): Handle COMPONENT_REF after handling
1103 ADDR_EXPR, for COMPONENT_REF without ARROW_EXPR inside of it
1104 write_string ("dt") instead of using operators.def.
1106 2009-02-03 Jason Merrill <jason@redhat.com>
1108 * typeck.c (cp_build_unary_op): Only complain about taking address
1109 of main if pedantic.
1111 2009-02-03 Jakub Jelinek <jakub@redhat.com>
1114 * parser.c (cp_parser_primary_expression): Reject FIXED_CSTs.
1117 * typeck2.c (digest_init_r): Don't call process_init_constructor
1120 2009-02-03 Paolo Bonzini <bonzini@gnu.org>
1123 * pt.c (convert_nontype_argument_function): Expect expr to be an
1127 * typeck.c (merge_types): Call resolve_typename_type if only
1128 one type is a typename.
1130 2009-02-02 Jason Merrill <jason@redhat.com>
1133 * parser.c (cp_parser_unqualified_id): Don't wrap error_mark_node
1136 2009-02-01 Paolo Carlini <paolo.carlini@oracle.com>
1139 * parser.c (cp_parser_pure_specifier): If there are no tokens left
1140 do not call cp_lexer_consume_token.
1142 2009-01-30 Jakub Jelinek <jakub@redhat.com>
1145 * parser.c (cp_parser_already_scoped_statement): Handle __label__
1148 2009-01-30 Paolo Carlini <paolo.carlini@oracle.com>
1151 * error.c (dump_expr): Handle FIX_TRUNC_EXPR and FLOAT_EXPR.
1153 2009-01-30 Paolo Carlini <paolo.carlini@oracle.com>
1156 * error.c (dump_type_prefix, dump_type_suffix): Handle FIXED_POINT_TYPE.
1158 2009-01-29 Paolo Carlini <paolo.carlini@oracle.com>
1160 * typeck.c (invalid_nonstatic_memfn_p): Use
1161 DECL_NONSTATIC_MEMBER_FUNCTION_P.
1163 2009-01-27 Paolo Carlini <paolo.carlini@oracle.com>
1166 * call.c (build_over_call): If convert_for_arg_passing returns
1167 error_mark_node unconditionally return it.
1169 2009-01-22 Adam Nemet <anemet@caviumnetworks.com>
1171 * class.c (check_field_decls): Also inherit packed for bitfields
1172 regardless of their type.
1174 2009-01-22 Dodji Seketeli <dodji@redhat.com>
1177 * decl2.c (grokfield): Reverting changes of PR c++/26693
1178 (save_template_attributes): Likewise.
1179 * decl.c (grokdeclarator): Likewise.
1180 * name-lookup.c (pushdecl_maybe_friend): Likewise.
1181 * cp-tree.h (MEMBER_TYPES_NEEDING_ACCESS_CHECK): Likewise.
1182 (append_type_to_template_for_access_check): Likewise.
1183 * semantics.c (check_accessibility_of_qualified_id): Likewise.
1184 * pt.c (instantiate_class_template, instantiate_template ): Likewise.
1186 (resolve_type_name_type): Likewise.
1187 (append_type_to_template_for_access_check): Likewise.
1189 2009-01-21 Dodji Seketeli <dodji@redhat.com>
1192 * decl2.c (grokfield): when a typedef appears in a
1193 class, create the typedef variant type node for it.
1194 (save_template_attributes): Creating typedef variant type node
1195 here is now useless.
1196 * decl.c (grokdeclarator): If the typedef'ed struct/class was
1197 anonymous, set the proper type name to all its type variants.
1198 * name-lookup.c (pushdecl_maybe_friend): Reuse the
1199 set_underlying_type function to install typedef variant types.
1200 * cp-tree.h (MEMBER_TYPES_NEEDING_ACCESS_CHECK): New template accessor
1202 (append_type_to_template_for_access_check): New entry points.
1203 * semantics.c (check_accessibility_of_qualified_id):
1204 When a typedef that is a member of a class appears in a template,
1205 add it to the template. It will be ...
1206 * pt.c (instantiate_class_template, instantiate_template ): ... access
1207 checked at template instantiation time.
1208 (tsubst): Handle the case of being called with NULL args.
1209 (resolve_type_name_type): The type name should be the name of the
1211 (append_type_to_template_for_access_check): New entry point.
1213 2009-01-19 Jason Merrill <jason@redhat.com>
1216 * parser.c (cp_parser_unqualified_id): In a template,
1218 * typeck.c (lookup_destructor): Handle IDENTIFIER_NODE.
1220 2009-01-16 Jason Merrill <jason@redhat.com>
1223 * tree.c (lvalue_p_1): Allow non-fields in COMPONENT_REF.
1224 * init.c (build_new): Don't call describable_type unless we
1228 * pt.c (tsubst_decl) [USING_DECL]: Propagate access flags.
1231 * search.c (protected_accessible_p): N doesn't vary.
1233 2009-01-15 Jason Merrill <jason@redhat.com>
1236 * pt.c (tsubst_copy_and_build): Tell finish_call_expr to
1237 accept hidden friends.
1239 2009-01-15 Andrew Pinski <andrew_pinski@playstation.sony.com>
1242 * decl.c (grokdeclarator): Check for a non namespace/class context.
1244 2009-01-15 Jason Merrill <jason@redhat.com>
1248 * tree.c (lvalue_p_1): Handle BASELINK. A COMPONENT_REF to
1249 a function isn't necessarily an lvalue. Take tree, not const_tree.
1250 (lvalue_p, real_lvalue_p): Take tree, not const_tree.
1251 * typeck.c (lvalue_or_else): Likewise.
1252 * cp-tree.h: Adjust prototypes.
1254 2009-01-15 Steve Ellcey <sje@cup.hp.com>
1257 * pt.c (tsubst): Check for NULL args.
1259 2009-01-15 Dodji Seketeli <dodji@redhat.com>
1262 * name-lookup.c (pushtag): Don't create members to types that are not
1265 2009-01-14 Nick Clifton <nickc@redhat.com>
1268 * parser.c: Pass cp_id_kind computed in
1269 cp_parser_postfix_dot_deref_expression to
1270 cp_parser_primary_expression.
1272 2009-01-13 Jakub Jelinek <jakub@redhat.com>
1275 * tree.c (cp_walk_subtrees): Handle REINTERPRET_CAST_EXPR,
1276 STATIC_CAST_EXPR, CONST_CAST_EXPR and DYNAMIC_CAST_EXPR the same
1279 2009-01-12 Jason Merrill <jason@redhat.com>
1280 Steve Ellcey <sje@cup.hp.com>
1283 * name-lookup.c (lookup_name_real): Keep looking past a hidden
1286 2009-01-12 Dodji Seketeli <dodji@redhat.com>
1289 * pt.c (parameter_of_template_p): New function.
1290 * cp-tree.h: Declare it.
1291 * name-lookup.c (binding_to_template_parms_of_scope_p): New
1293 (outer_binding): Take template parameters in account when looking for
1296 2009-01-12 Jason Merrill <jason@redhat.com>
1299 * tree.c (pod_type_p): Return 1 for structs created by the back end.
1301 2009-01-12 Jakub Jelinek <jakub@redhat.com>
1304 * parser.c (cp_parser_builtin_offsetof): Allow `->' in
1305 offsetof member-designator, handle it as `[0].'.
1308 * decl.c (start_function): If grokdeclarator hasn't returned
1309 FUNCTION_DECL nor error_mark_node, issue diagnostics.
1311 2009-01-11 Jakub Jelinek <jakub@redhat.com>
1314 * cp-gimplify.c (genericize_if_stmt): Renamed from ...
1315 (gimplify_if_stmt): ... this.
1316 (cp_gimplify_expr): Don't handle IF_STMT here.
1317 (cp_genericize_r): Call genericize_if_stmt for IF_STMT.
1319 2009-01-10 Andrew Pinski <pinskia@gmail.com>
1322 * typeck.c (cp_build_modify_expr): Check for NULL current_function_decl.
1325 * typeck2.c (build_functional_cast): Check for reference type and NULL
1328 2009-01-09 Steve Ellcey <sje@cup.hp.com>
1330 * typeck.c (cp_build_unary_op): Check for ERROR_MARK.
1332 2009-01-09 Jakub Jelinek <jakub@redhat.com>
1335 * error.c (dump_expr): Handle EXPR_STMT like BIND_EXPR.
1337 2009-01-09 John F. Carr <jfc@mit.edu>
1340 * parser.c (cp_parser_class_specifier): Clear
1341 parser->in_unbraced_linkage_specification_p while parsing class
1344 2009-01-07 Jakub Jelinek <jakub@redhat.com>
1347 * semantics.c (finish_goto_stmt): Convert destination to
1350 2009-01-06 Jason Merrill <jason@redhat.com>
1357 * pt.c (check_default_tmpl_args): Don't complain about
1358 out-of-order parameter packs in the enclosing class
1359 or parameter packs after default args.
1360 (coerce_template_parms): If we have more than one
1361 parameter pack, don't flatten argument packs.
1362 (template_args_equal): Handle argument packs.
1363 (comp_template_args): Don't flatten argument packs.
1364 (check_instantiated_arg): Split out from...
1365 (check_instantiated_args): Here. Handle arg packs.
1366 (convert_template_argument): Just check that nontype argument
1367 packs have the right type.
1369 2009-01-05 Dodji Seketeli <dodji@redhat.com>
1372 * typeck.c (type_after_usual_arithmetic_conversions): Fix a typo.
1374 2009-01-05 Jason Merrill <jason@redhat.com>
1377 * typeck2.c (process_init_constructor_union): Handle union with
1380 * mangle.c (write_expression): Remove mangling for zero-operand
1384 * decl.c (cp_finish_decl): Clear DECL_INITIAL for invalid
1388 * class.c (defaultable_fn_p): Only operator== can be a copy
1389 assignment operator.
1391 2009-01-02 Jason Merrill <jason@redhat.com>
1394 * typeck2.c (process_init_constructor_union): Handle excess
1396 (process_init_constructor_record): Likewise.
1399 * typeck2.c (digest_init_r): Don't use process_init_constructor
1400 for non-aggregate classes.
1403 Copyright (C) 2009 Free Software Foundation, Inc.
1405 Copying and distribution of this file, with or without modification,
1406 are permitted in any medium without royalty provided the copyright
1407 notice and this notice are preserved.