2010-06-20 Tobias Burnus <burnus@net-b.de>
[official-gcc.git] / gcc / cp / ChangeLog
blob2d989016fd392f2e7955e9b87b903629c995e51f
1 2010-06-17  Nathan Froyd  <froydnj@codesourcery.com>
3         * name-lookup.c (struct arg_lookup): Convert namespaces and
4         classes fields to VEC.
5         (arg_assoc_namespace): Adjust for new type of namespaces.
6         (arg_assoc_class): Adjust for new type of classes.
7         (lookup_arg_dependent): Use make_tree_vector and
8         release_tree_vector.
9         * typeck2.c (build_x_arrow): Use vec_member.
11 2010-06-17  Manuel López-Ibáñez  <manu@gcc.gnu.org>
13         PR c++/44486
14         * error.c (dump_decl): Better wording for anonymous namespace.
16 2010-06-16  Nathan Froyd  <froydnj@codesourcery.com>
18         * class.c (build_vtbl_initializer): Adjust computation of new_position
19         and which entry to add padding for.
21 2010-06-16  Jason Merrill  <jason@redhat.com>
23         * except.c (check_noexcept_r): Return the problematic function.
24         (finish_noexcept_expr): Give -Wnoexcept warning.  Add complain parm.
25         * pt.c (tsubst_copy_and_build): Pass it.
26         * parser.c (cp_parser_unary_expression): Likewise.
27         * cp-tree.h: Adjust prototype.
29         * method.c (defaulted_late_check): Give the defaulted method
30         the same exception specification as the implicit declaration.
32 2010-06-15  Jason Merrill  <jason@redhat.com>
34         * class.c (add_implicitly_declared_members): Implicit assignment
35         operators can also be virtual overriders.
36         * method.c (lazily_declare_fn): Likewise.
38         * call.c (convert_like_real): Give "initializing argument of"
39         information for ambiguous conversion.  Give source position
40         of function.
42         * call.c (print_z_candidates): Do print viable deleted candidates.
43         (joust): Don't choose a deleted function just because its worst
44         conversion is better than another candidate's worst.
46         * call.c (convert_like_real): Don't complain about
47         list-value-initialization from an explicit constructor.
49         * decl.c (duplicate_decls): Use DECL_IS_BUILTIN rather than test
50         DECL_SOURCE_LOCATION directly.
52         * class.c (type_has_user_provided_default_constructor): Use
53         sufficient_parms_p.
55         * call.c (is_subseq): Handle ck_aggr, ck_list.
56         (compare_ics): Treat an aggregate or ambiguous conversion to the
57         same type as involving the same function.
59 2010-06-13  Shujing Zhao  <pearly.zhao@oracle.com>
61         * typeck.c (convert_for_assignment): Fix comment. Change message
62         format from %d to %qP.
63         (convert_for_initialization): Fix comment. 
65 2010-06-11  Shujing Zhao  <pearly.zhao@oracle.com>
67         * cp-tree.h (expr_list_kind): New type.
68         (impl_conv_rhs): New type.
69         (build_x_compound_expr_from_list, convert_for_initialization): Adjust
70         prototype.
71         (typeck.c (convert_arguments): Use impl_conv_rhs and emit the
72         diagnostics for easy translation. Change caller.
73         (convert_for_initialization): Use impl_conv_rhs and change caller.
74         (build_x_compound_expr_from_list): Use expr_list_kind and emit the
75         diagnostics for easy translation. Change caller.
76         * decl.c (bad_spec_place): New enum.
77         (bad_specifiers): Use it and emit the diagnostics for easy
78         translation. Change caller.
79         * pt.c (coerce_template_parms): Put the diagnostics in full sentence.
81 2010-06-09  Nathan Froyd  <froydnj@codesourcery.com>
83         * cp-tree.h (struct saved_scope): Change decl_ns_list field type
84         to a VEC.
85         * decl2.c (cp_write_global_declarations): Adjust for new type of
86         decl_namespace_list.
87         * name-lookup.c (current_decl_namespace): Likewise.
88         (push_decl_namespace): Likewise.
89         (pop_decl_namespace): Likewise.
91 2010-06-09  Nathan Froyd  <froydnj@codesourcery.com>
93         * call.c (build_java_interface_fn_ref): Call build_function_type_list
94         instead of build_function_type.
95         * decl.c (cxx_init_decl_processing): Likewise.
96         (declare_global_var): Likewise.
97         (get_atexit_node): Likewise.
98         (expand_static_init): Likewise.
99         * decl2.c (start_objects): Likewise.
100         (start_static_storage_duration_function): Likewise.
101         * except.c (init_exception_processing): Likewise.
102         (build_exc_ptr): Likewise.
103         (build_throw): Likewise.
104         * rtti.c (throw_bad_cast): Likewise.
105         (throw_bad_typeid): Likewise.
106         (build_dynamic_cast_1): Likewise.
108 2010-06-09  Nathan Froyd  <froydnj@codesourcery.com>
110         * call.c (build_call_n): Call XALLOCAVEC instead of alloca.
111         (build_op_delete_call): Likewise.
112         (build_over_call): Likewise.
113         * cp-gimplify.c (cxx_omp_clause_apply_fn): Likewise.
114         * pt.c (process_partial_specialization): Likewise.
115         (tsubst_template_args): Likewise.
116         * semantics.c (finish_asm_stmt): Likewise.
118 2010-06-08  Nathan Sidwell  <nathan@codesourcery.com>
120         * decl.c (record_key_method_defined): New, broken out of ...
121         (finish_function): ... here.  Call it.  
122         (start_decl): Treat aliases as definitions.
124 2010-06-08  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
126         * typeck2.c (abstract_virtuals_error): Use typed GC allocation.
128         * pt.c (maybe_process_partial_specialization): Likewise.
129         (register_specialization): Likewise.
130         (add_pending_template): Likewise.
131         (lookup_template_class): Likewise.
132         (push_tinst_level): Likewise.
134         * parser.c (cp_lexer_new_main): Likewise.
135         (cp_lexer_new_from_tokens): Likewise.
136         (cp_token_cache_new): Likewise.
137         (cp_parser_context_new): Likewise.
138         (cp_parser_new): Likewise.
139         (cp_parser_nested_name_specifier_opt): Likewise.
140         (cp_parser_template_id): Likewise.
142         * name-lookup.c (binding_entry_make): Likewise.
143         (binding_table_construct): Likewise.
144         (binding_table_new): Likewise.
145         (cxx_binding_make): Likewise.
146         (pushdecl_maybe_friend): Likewise.
147         (begin_scope): Likewise.
148         (push_to_top_level): Likewise.
150         * lex.c (init_reswords): Likewise.
151         (retrofit_lang_decl): Likewise.
152         (cxx_dup_lang_specific_decl): Likewise.
153         (copy_lang_type): Likewise.
154         (cxx_make_type): Likewise.
156         * decl.c (make_label_decl): Likewise.
157         (check_goto): Likewise.
158         (start_preparsed_function): Likewise.
159         (save_function_data): Likewise.
161         * cp-tree.h (TYPE_SET_PTRMEMFUNC_TYPE): Likewise.
163         * cp-objcp-common.c (decl_shadowed_for_var_insert): Likewise.
165         * class.c (finish_struct_1): Likewise.
167         * cp-tree.h (struct lang_type): Add variable_size GTY option.
168         (struct lang_decl): Likewise.
170         * parser.c (cp_parser_new): Update comment to not reference
171         ggc_alloc.
173 2010-06-07  Jason Merrill  <jason@redhat.com>
175         PR c++/44366
176         * error.c (dump_parameters): Mask out TFF_SCOPE.
177         (dump_simple_decl): Don't print the scope of a PARM_DECL.
178         (dump_scope): Remove no-op mask.
180         PR c++/44401
181         * parser.c (cp_parser_lookup_name): Fix naming the constructor.
183         * cp-tree.h (COMPLETE_OR_OPEN_TYPE_P): New macro.
184         * init.c (build_offset_ref): Use it.
185         * pt.c (maybe_process_partial_specialization): Use it.
186         (instantiate_class_template): Use it.
187         * search.c (lookup_base): Use it.
189 2010-06-07  Jakub Jelinek  <jakub@redhat.com>
191         PR c++/44444
192         * expr.c (mark_exp_read): Handle INDIRECT_REF.
193         * cvt.c (convert_to_void): Handle INDIRECT_REF like
194         handled_component_p.
196         PR c++/44443
197         * decl.c (initialize_local_var): If TREE_USED is set on the type,
198         set also DECL_READ_P on the decl.
200 2010-05-25  Dodji Seketeli  <dodji@redhat.com>
202         PR c++/44188
203         * cp-tree.h (typedef_variant_p): Move this declaration to
204         gcc/tree.h.
205         * tree.c (typedef_variant_p): Move this definition to gcc/tree.c.
206         * decl.c (grokdeclarator): Do not rename debug info of an
207         anonymous tagged type named by a typedef.
209 2010-06-05  Fabien Chêne  <fabien@gcc.gnu.org>
211         PR c++/44086
212         * class.c (check_field_decls): Move the call to
213         check_bitfield_decl before trying to set the
214         CLASSTYPE_READONLY_FIELDS_NEED_INIT flag.
216 2010-06-05  Steven Bosscher  <steven@gcc.gnu.org>
218         * typeck.c: Update include path for moved files.
219         * decl.c: Likewise.
220         * rtti.c: Likewise.
221         * cp-gimplify.c: Likewise.
222         * cp-lang.c: Likewise.
223         * pt.c: Likewise.
224         * semantics.c: Likewise.
225         * cxx-pretty-print.h: Likewise.
226         * decl2.c: Likewise.
227         * parser.c: Likewise.
228         * cp-objcp-common.c: Likewise.
229         * cp-tree.h: Likewise.
230         * name-lookup.c: Likewise.
231         * lex.c: Likewise.
232         * name-lookup.h: Likewise.
233         * config-lang.in: Update paths in gtfiles for files in c-family/.
234         * Make-lang.in: Likewise.
236 2010-06-04  Magnus Fromreide  <magfr@lysator.liu.se>
238         * cvt.c (cp_convert_to_pointer): Use null_ptr_cst_p.
239         * typeck.c (build_ptrmemfunc): Likewise.
241 2010-06-04  Jason Merrill  <jason@redhat.com>
243         * typeck2.c (merge_exception_specifiers): Adjust merging of
244         throw() and noexcept(true).
246         * pt.c (value_dependent_expression_p) [NOEXCEPT_EXPR]: Avoid
247         using an uninitialized variable.
249         * cxx-pretty-print.c (pp_cxx_unary_expression): Handle NOEXCEPT_EXPR.
250         (pp_cxx_expression): Likewise.
252         Implement noexcept-specification (15.4)
253         * parser.c (cp_parser_exception_specification_opt): Parse it.
254         Give -Wdeprecated warning about throw() specs.
255         * pt.c (tsubst_exception_specification): Handle it.
256         * error.c (dump_exception_spec): Handle it.
257         (dump_expr): Handle NOEXCEPT_EXPR.
258         * cxx-pretty-print.c (pp_cxx_exception_specification): Likewise.
259         * typeck.c (comp_except_specs): Handle compatibility rules.
260         Change exact parm to take an enum.
261         * typeck2.c (merge_exception_specifiers): Handle noexcept.
262         * except.c (nothrow_spec_p, type_noexcept_p): New fns.
263         (type_throw_all_p, build_noexcept_spec): New fns.
264         * cp-tree.h (TYPE_NOTHROW_P, TYPE_NOEXCEPT_P): Use them.
265         (comp_except_specs): Define ce_derived, ce_normal, ce_exact enums.
266         (cp_tree_index): Add CPTI_NOEXCEPT_TRUE_SPEC, CPTI_NOEXCEPT_FALSE_SPEC.
267         (noexcept_true_spec, noexcept_false_spec): New macros.
268         * name-lookup.c (pushdecl_maybe_friend): Adjust.
269         * search.c (check_final_overrider): Adjust.
270         * decl.c (check_redeclaration_exception_specification): Adjust.
271         (use_eh_spec_block): Use type_throw_all_p.
272         (cxx_init_decl_processing): Set noexcept_false_spec,noexcept_true_spec.
273         Give operator new a noexcept-specification in C++0x mode.
274         * tree.c (build_exception_variant, cxx_type_hash_eq): Adjust.
275         (cp_build_type_attribute_variant): Don't test TYPE_RAISES_EXCEPTIONS.
277         Implement noexcept operator (5.3.7)
278         * cp-tree.def (NOEXCEPT_EXPR): New.
279         * except.c (check_noexcept_r, finish_noexcept_expr): New.
280         * cp-tree.h: Declare finish_noexcept_expr.
281         * parser.c (cp_parser_unary_expression): Parse noexcept-expression.
282         * pt.c (tsubst_copy_and_build): And tsubst it.
283         (type_dependent_expression_p): Handle it.
284         (value_dependent_expression_p): Handle it.
286         * call.c (build_conditional_expr): Never fold in unevaluated context.
287         * tree.c (build_aggr_init_expr): Propagate TREE_NOTHROW.
288         * semantics.c (simplify_aggr_init_expr): Likewise.
289         * typeck.c (merge_types): Call merge_exception_specifiers.
290         * decl.c (duplicate_decls): Check DECL_SOURCE_LOCATION rather than
291         DECL_ANTICIPATED for preferring new type.
293 2010-06-04  Joseph Myers  <joseph@codesourcery.com>
295         * g++spec.c (lang_specific_driver): Use GCC-specific formats in
296         diagnostics.
298 2010-06-04  Jakub Jelinek  <jakub@redhat.com>
300         PR c++/44412
301         * typeck.c (build_class_member_access_expr): Call mark_exp_read
302         on object for static data members.
304 2010-06-04  Jakub Jelinek  <jakub@redhat.com>
305             Jason Merrill  <jason@redhat.com>
307         PR c++/44362
308         * call.c (build_conditional_expr): If both arg2 and arg3 are lvalues
309         with the same type, call mark_lvalue_use on both.
311 2010-06-03  Nathan Froyd  <froydnj@codesourcery.com>
313         * class.c (struct vtbl_init_data_s): Remove last_init field.
314         (struct secondary_vptr_vtt_init_data_s): Change type of inits field
315         to a VEC.
316         (finish_vtbls): Use a VEC rather than a TREE_LIST for the accumulated
317         initializers.
318         (build_vtt): Likewise.
319         (initialize_vtable): Take a VEC instead of a tree.
320         (build_vtt_inits): Change return type to void.  Take a VEC **
321         instead of a tree *; accumulate results into said VEC.
322         (build_ctor_vtbl_group): Use a VEC rather than a TREE_LIST for the
323         accumulated initializers.  Pass the vtable to accumulate_vtbl_inits.
324         (accumulate_vtbl_inits): Add extra vtable tree parameter; take a VEC
325         instead of a tree.
326         (dfs_accumulate_vtbl_inits): Likewise.  Change return type to void.
327         (build_vtbl_initializer): Add VEC parameter; accumulate initializers
328         into it.
329         (dfs_build_secondary_vptr_vtt_inits): Use CONSTRUCTOR_APPEND_ELT
330         rather than tree_cons.
331         (build_vbase_offset_vtbl_entries): Likewise.
332         (add_vcall_offset): Likewise.
333         (build_rtti_vtbl_entries): Likewise.
334         * cp-tree.h (initialize_artificial_var): Take a VEC instead of a tree.
335         * decl.c (initialize_artificial_var): Use build_constructor instead
336         of build_constructor_from_list.
338 2010-06-03  H.J. Lu  <hongjiu.lu@intel.com>
340         PR c++/44294
341         * class.c (layout_class_type): Check MAX_FIXED_MODE_SIZE on
342         bit-field.
344 2010-06-02  Jonathan Wakely  <jwakely.gcc@gmail.com>
346         * parser.c (cp_parser_mem_initializer_list): Change error text.
348 2010-06-02  Jakub Jelinek  <jakub@redhat.com>
350         * cp-objcp-common.c (shadowed_var_for_decl): Change into
351         tree_decl_map hashtab from tree_map.
352         (decl_shadowed_for_var_lookup, decl_shadowed_for_var_insert): Adjust.
353         (init_shadowed_var_for_decl): Adjust initialization.
355         PR c++/44361
356         * cvt.c (convert_to_void): If implicit is NULL, call mark_rvalue_use
357         instead of calling mark_exp_read only when not an assignment.
359         PR debug/44367
360         * semantics.c (finalize_nrv): Don't copy DECL_ARTIFICIAL, DECL_IGNORED_P,
361         DECL_SOURCE_LOCATION and DECL_ABSTRACT_ORIGIN from var to result.
362         Set DECL_VALUE_EXPR on var.
364 2010-06-02  Jason Merrill  <jason@redhat.com>
366         * error.c (dump_type): Improve typedef handling.
368         PR c++/9726
369         PR c++/23594
370         PR c++/44333
371         * name-lookup.c (same_entity_p): New.
372         (ambiguous_decl): Multiple declarations of the same entity
373         are not ambiguous.
375 2010-06-01  Jason Merrill  <jason@redhat.com>
377         DR 990
378         * call.c (add_list_candidates): Prefer the default constructor.
379         (build_aggr_conv): Treat missing initializers like { }.
380         * typeck2.c (process_init_constructor_record): Likewise.
381         * init.c (expand_default_init): Use digest_init for
382         direct aggregate initialization, too.
384         * call.c (add_list_candidates): Split out...
385         (build_user_type_conversion_1): ...from here.
386         (build_new_method_call): And here.
387         (implicit_conversion): Propagate LOOKUP_NO_NARROWING.
389         PR c++/44358
390         * call.c (build_list_conv): Set list-initialization flags properly.
392 2010-06-01  Nathan Froyd  <froydnj@codesourcery.com>
394         * typeck2.c (build_x_arrow): Make types_memoized a VEC.
396 2010-06-01  Arnaud Charlet  <charlet@adacore.com>
397             Matthew Gingell  <gingell@adacore.com>
399         * Make-lang.in (CXX_C_OBJS): Add c-ada-spec.o.
400         * decl2.c: Include langhooks.h and c-ada-spec.h.
401         (cpp_check, collect_source_refs, collect_ada_namespace,
402         collect_all_refs): New functions.
403         (cp_write_global_declarations): Add handling of -fdump-ada-spec.
404         * lang-specs.h: Ditto.
406 2010-05-29  Nathan Froyd  <froydnj@codesourcery.com>
408         * cp-tree.h (cp_build_function_call_nary): Declare.
409         * typeck.c (cp_build_function_call_nary): Define.
410         * decl.c (register_dtor_fn): Use it instead of
411         cp_build_function_call.
412         (cxx_maybe_build_cleanup): Likewise.
413         * decl2.c (generate_ctor_or_dtor_function): Likewise.
414         * except.c (do_get_exception_ptr): Likewise.
415         (do_begin_catch): Likewise.
416         (do_allocate_exception): Likewise.
417         (do_free_exception): Likewise.
418         (build_throw): Likewise.  Use cp_build_function_call_vec instead
419         of cp_build_function_call.
420         (do_end_catch): Likewise.
422 2010-05-29  Nathan Froyd  <froydnj@codesourcery.com>
424         * cp-tree.h (struct cp_decl_specifier_seq): Move type_location field up.
425         (struct cp_declarator): Move id_loc field up.
427 2010-05-29  Steven Bosscher  <steven@gcc.gnu.org>
429         * cp-tree.h (ATTRIBUTE_GCC_CXXDIAG): Remove.  Require that
430         this file is included before c-common.h.  Define GCC_DIAG_STYLE
431         before including diagnostic-core.h and toplev.h.
432         (pedwarn_cxx98): Use ATTRIBUTE_GCC_DIAG.
433         * pt.c: Include cp-tree.h before c-common.h.
435 2010-05-29  Steven Bosscher  <steven@gcc.gnu.org>
437         * tree.c (c_register_addr_space): Add stub.
439 2010-05-28  Joseph Myers  <joseph@codesourcery.com>
441         * g++spec.c (lang_specific_driver): Use fatal_error instead of
442         fatal.
444 2010-05-28  Dodji Seketeli  <dodji@redhat.com>
446         Revert fix of PR c++/44188
447         * cp-tree.h (typedef_variant_p): Revert moving this declaration to
448         gcc/tree.h.
449         * tree.c (typedef_variant_p): Revert moving this definition to
450         gcc/tree.c.
451         * decl.c (grokdeclarator): Revert naming typedef handling.
453 2010-05-27  Joseph Myers  <joseph@codesourcery.com>
455         * call.c: Include diagnostic-core.h instead of diagnostic.h.
456         * cp-lang.c: Don't include diagnostic.h
457         * name-lookup.c: Include diagnostic-core.h instead of
458         diagnostic.h.
459         (cp_emit_debug_info_for_using): Use seen_error.
460         * optimize.c: Include diagnostic-core.h instead of diagnostic.h.
461         * parser.c: Include diagnostic-core.h instead of diagnostic.h.
462         * pt.c (iterative_hash_template_arg): Use seen_error.
463         * repo.c: Include diagnostic-core.h instead of diagnostic.h.
464         * typeck2.c: Include diagnostic-core.h instead of diagnostic.h.
465         * Make-lang.in (cp/cp-lang.o, cp/typeck2.o, cp/call.o, cp/repo.o,
466         cp/optimize.o, cp/parser.o, cp/name-lookup.o): Update
467         dependencies.
469 2010-05-25  Dodji Seketeli  <dodji@redhat.com>
471         PR c++/44188
472         * cp-tree.h (typedef_variant_p): Move this declaration to
473         gcc/tree.h.
474         * tree.c (typedef_variant_p): Move this definition to gcc/tree.c.
475         * decl.c (grokdeclarator): Do not rename debug info of an
476         anonymous tagged type named by a typedef.
478 2010-05-27  Jason Merrill  <jason@redhat.com>
480         PR c++/43555
481         * decl.c (grokdeclarator) [cdk_pointer et al]: Force evaluation of
482         anonymous VLA size.
484 2010-05-27  Kai Tietz  <kai.tietz@onevision.com>
486         PR bootstrap/44287
487         * rtti.c (emit_support_tinfos): Check for NULL_TREE.
488         * class.c (layout_class_type): Likewise.
489         * decl.c (finish_enum): Likewise.
490         * mangle.c (write_builitin_type): Likewise.
492 2010-05-26  Kai Tietz  <kai.tietz@onevision.com>
494         * cp-tree.h (cp_decl_specifier_seq): Add new bifield
495         explicit_int128_p.
496         * decl.c (grokdeclarator): Handle __int128.
497         * parser.c (cp_lexer_next_token_is_decl_specifier_ke): Likewise.
498         (cp_parser_simple_type_specifier): Likewise.
499         * rtti.c (emit_support_tinfos): Add int128 nodes for rtti.
500         * typeck.c (cp_common_type): Handle __int128.
501         * mangle.c (integer_type_codes): Add itk_int128 and
502         itk_unsigned_int128.
504 2010-05-26  Jason Merrill  <jason@redhat.com>
506         PR c++/43382
507         * pt.c (tsubst_pack_expansion): Don't get confused by recursive
508         unification.
510 2010-05-26  Steven Bosscher  <steven@gcc.gnu.org>
512         * cp-lang.c: Do not include expr.h.
514 2010-05-26  Steven Bosscher  <steven@gcc.gnu.org>
516         * decl.c: Do not include rtl.h
517         * semantics.c: Likewise.
519 2010-05-25  Steven Bosscher  <steven@gcc.gnu.org>
521         * cp-tree.h: Do not include splay-tree.h.
522         (struct prtmem_cst): Remove unused field and false comment.
523         * typeck.c: Do not include rtl.h, expr.h, and tm_p.h.
524         * optimize.c: Do not inclde rtl.h, insn-config.h, and integrate.h.
525         * init.c: Do not include rtl.h and expr.h.
526         * class.c: Do not include rtl.h.  Include splay-tree.h.
527         (build_clone): Use plain NULL instead of NULL_RTX.
528         * decl.c: Do not include expr.h.  Explain why rtl.h has to be
529         included.  Include splay-tree.h.
530         * method.c: Do not include rtl.h and expr.h.
531         (use_thunk): Use plain NULL instead of NULL_RTX.
532         * except.c: Do not include rtl.h, expr.h, and libfuncs.h.
533         * tree.c: Do not include rtl.h, insn-config.h, integrate.h,
534         and target.h.  Include splay-tree.h.
535         * expr.c: Do not include rtl.h and expr.h.
536         * pt.c: Do not include obstack.h and rtl.h.
537         (tsubst_friend_function): Use plain NULL instead of NULL_RTX.
538         (tsubst_decl): Likewise.
539         (instantiate_decl): Likewise.
540         * semantics.c: Do not include exprt.h and debug.h.  Explain why
541         rtl.h has to be included.
542         * decl2.c: Do not include rtl.h and expr.h.  Include splay-tree.h.
543         * call.c: Do not include rtl.h and expr.h.
544         * search.c: Do not include obstack.h and rtl.h.
545         * friend.c: Do not include rtl.h and expr.h.
546         * Make-lang.in: Update dependencies.
548 2010-05-25  Jakub Jelinek  <jakub@redhat.com>
550         PR c++/18249
551         * parser.c (non_integral_constant): Add NIC_NONE.
552         (required_token): Add RT_NONE.
553         (cp_parser_unary_expression): Initialize non_constant_p
554         to NIC_NONE.
555         (cp_parser_asm_definition): Initialize missing to RT_NONE.
556         (cp_parser_primary_expression, cp_parser_postfix_expression,
557         cp_parser_cast_expression, cp_parser_binary_expression,
558         cp_parser_functional_cast): Fix formatting.
560 2010-05-25  Shujing Zhao  <pearly.zhao@oracle.com>
561         
562         PR c++/18249
563         * parser.c: Remove inclusion of dyn-string.h.
564         (non_integral_constant): New enum.
565         (name_lookup_error): New enum.
566         (required_token): New enum.
567         (cp_parser_required_error): New function.
568         (cp_parser_require): Change the type of variable token_desc to
569         required_token and use cp_parser_required_error.
570         (cp_parser_require_keyword): Likewise.
571         (cp_parser_error): Use gmsgid as parameter.
572         (cp_parser_name_lookup_error): Change the type of variable desired to
573         name_lookup_error and put the diagnostic in the full sentences. Change
574         caller.
575         (cp_parser_non_integral_constant_expression): Change the type of the
576         variable thing to non_integral_constant and put the diagnostics in
577         full sentences. Change caller.
579 2010-05-24  Eric Botcazou  <ebotcazou@adacore.com>
581         PR middle-end/44100
582         * typeck.c (cp_build_unary_op): Fold offsetof-like computations.
584 2010-05-24  Joseph Myers  <joseph@codesourcery.com>
586         * error.c (cp_diagnostic_starter): Update call to
587         diagnostic_build_prefix.
588         (cp_print_error_function,
589         print_instantiation_partial_context_line): Check show_column flag
590         in context.
592 2010-05-24  Jason Merrill  <jason@redhat.com>
594         PR c++/41510
595         * decl.c (check_initializer): Don't wrap an init-list in a
596         TREE_LIST.
597         * init.c (build_aggr_init): Don't assume copy-initialization if
598         init has CONSTRUCTOR_IS_DIRECT_INIT.
599         * call.c (build_new_method_call): Sanity check.
601 2010-05-24  Nathan Froyd  <froydnj@codesourcery.com>
603         * rtti.c (tinfo_base_init): Use build_constructor instead of
604         build_constructor_from_list.  Don't cons a tree node for
605         returning.
606         (generic_initializer): Use build_constructor_single instead of
607         build_constructor_from_list.
608         (ptr_initializer): Use build_constructor instead of
609         build_constructor_from_list
610         (ptm_initializer): Likewise.
611         (class_initializer): Likewise.  Take varargs instead of TRAIL.
612         (get_pseudo_ti_init): Adjust calls to class_initializer.  Use
613         build_constructor instead of build_constructor_from_list.
615 2010-05-22  Steven Bosscher  <steven@gcc.gnu.org>
617         * semantics.c: Include bitmap.h.
618         * Make-lang.in: Update dependencies.
620 2010-05-22  Jan Hubicka  <jh@suse.cz>
622         * decl2.c (maybe_emit_vtables): Produce same comdat group when outputting
623         comdat vtables.
624         (cxx_callgraph_analyze_expr): Remove code marking vtables needed.
626 2010-05-21  Joseph Myers  <joseph@codesourcery.com>
628         * cxx-pretty-print.c: Correct merge error.
630 2010-05-21  Joseph Myers  <joseph@codesourcery.com>
632         * error.c: Include tree-diagnostic.h and tree-pretty-print.h.
633         (cp_print_error_function): Use diagnostic_abstract_origin macro.
634         (cp_printer): Handle %K here using percent_K_format.
635         * cxx-pretty-print.c: Include tree-pretty-print.h.
636         * Make-lang.in (cp/error.o, cp/cxx-pretty-print.o): Update
637         dependencies.
639 2010-05-21  Steven Bosscher  <steven@gcc.gnu.org>
641         * error.c, tree.c, typeck2.c, cxx-pretty-print.c, mangle.c:
642         Clean up redundant includes.
644 2010-05-20  Paolo Carlini  <paolo.carlini@oracle.com>
646         PR c++/30298
647         * decl.c (xref_basetypes): Return false in case of ill-formed
648         redefinition.
650 2010-05-19  Jason Merrill  <jason@redhat.com>
652         * call.c (reference_binding): Use cp_build_qualified_type_real
653         and cp_type_quals consistently.
654         (add_function_candidate): Likewise.
655         (build_conditional_expr): Likewise.
656         (convert_like_real): Likewise.
657         (type_passed_as): Likewise.
658         * class.c (add_method): Likewise.
659         (same_signature_p): Likewise.
660         (layout_class_type): Likewise.
661         * decl.c (cxx_init_decl_processing): Likewise.
662         (cp_fname_init): Likewise.
663         (grokdeclarator): Likewise.
664         * decl2.c (cp_reconstruct_complex_type): Likewise.
665         * init.c (build_new_1): Likewise.
666         * method.c (do_build_copy_constructor): Likewise.
667         (implicitly_declare_fn): Likewise.
668         * pt.c (tsubst_aggr_type): Likewise.
669         (tsubst): Likewise.
670         * rtti.c (init_rtti_processing): Likewise.
671         (build_headof): Likewise.
672         (build_dynamic_cast_1): Likewise.
673         (tinfo_base_init): Likewise.
674         (emit_support_tinfos): Likewise.
675         * semantics.c (capture_decltype): Likewise.
676         * tree.c (cv_unqualified): Likewise.
677         * typeck.c (composite_pointer_type): Likewise.
678         (string_conv_p): Likewise.
680         * mangle.c (write_CV_qualifiers_for_type): Tweak.
682         * call.c (initialize_reference): Use CP_TYPE_CONST_P.
683         * decl.c (start_decl): Likewise.
684         * semantics.c (finish_compound_literal): Likewise.
685         * typeck.c (check_return_expr): Use CP_TYPE_VOLATILE_P.
686         (cp_type_readonly): Remove.
687         * cp-tree.h: Remove declaration.
689         * typeck.c (merge_types): Preserve memfn quals.
691         * decl.c (grokdeclarator): Don't check quals on fn type.
692         * typeck.c (cp_apply_type_quals_to_decl): Likewise.
693         * tree.c (cp_build_qualified_type_real): Simplify qualifier checking.
695         PR c++/44193
696         * typeck.c (type_memfn_quals): New fn.
697         (apply_memfn_quals): New fn.
698         (cp_type_quals): Return TYPE_UNQUALIFIED for FUNCTION_TYPE.
699         (cp_type_readonly): Use cp_type_quals.
700         * cp-tree.h: Add declarations.
701         * tree.c (cp_build_qualified_type_real): Don't set, but do
702         preserve, quals on FUNCTION_TYPE.
703         (strip_typedefs): Use apply_memfn_quals and type_memfn_quals.
704         * decl.c (build_ptrmem_type): Likewise.
705         (grokdeclarator): Likewise.
706         (static_fn_type): Likewise.
707         * decl2.c (change_return_type): Likewise.
708         (cp_reconstruct_complex_type): Likewise.
709         * pt.c (tsubst_function_type): Likewise.
710         (unify): Likewise.
711         (tsubst): Likewise.  Drop special FUNCTION_TYPE substitution code.
713 2010-05-18  Nathan Froyd  <froydnj@codesourcery.com>
715         * tree.c (build_min_non_dep_call_vec): Update comment.
717 2010-05-17  Jason Merrill  <jason@redhat.com>
719         * call.c (struct z_candidate): Add explicit_targs field.
720         (add_template_candidate_real): Set it.
721         (build_over_call): Use it to control init-list warning.
723         PR c++/44157
724         * call.c (build_over_call): Limit init-list deduction warning to
725         cases where the argument is actually an init-list.
727         PR c++/44158
728         * call.c (build_over_call): Don't do bitwise copy for move ctor.
730 2010-05-17  Dodji Seketeli  <dodji@redhat.com>
731             Jason Merrill  <jason@redhat.com>
733         PR c++/44108
734         * decl.c (compute_array_index_type): Call mark_rvalue_use.
736 2010-05-15  Jason Merrill  <jason@redhat.com>
738         * cp-tree.h (TYPE_NOEXCEPT_P): New macro.
739         * except.c (begin_eh_spec_block): Use MUST_NOT_THROW_EXPR if
740         TYPE_NOEXCEPT_P.
741         (finish_eh_spec_block): Adjust.
743 2010-05-15  Jakub Jelinek  <jakub@redhat.com>
745         PR c++/44148
746         * pt.c (tsubst): Unshare template argument.
748 2010-05-15  Steven Bosscher  <steven@gcc.gnu.org>
750         * decl.c: Include tree-iterator.h, as fixup for tree-inline.h changes.
751         * Make-lang.in: Fix dependencies accordingly.
753 2010-05-14  Jason Merrill  <jason@redhat.com>
755         C++ DR 475
756         * except.c (build_throw): Simplify, adjust for DR 475.
758         PR c++/44127
759         * except.c (dtor_nothrow): Return nonzero for type with
760         trivial destructor.
762         PR c++/44127
763         * cp-gimplify.c (gimplify_must_not_throw_expr): Use
764         gimple_build_eh_must_not_throw.
766 2010-05-14  Martin Jambor  <mjambor@suse.cz>
768         * cp-lang.c (LANG_HOOKS_FOLD_OBJ_TYPE_REF): Remove both its undef
769         and define.
771 2010-05-14  Jonathan Wakely  <jwakely.gcc@gmail.com>
773         * call.c (build_new_method_call): Change warning text.
774         * typeck2.c (build_functional_cast): Change error text.
776 2010-05-14  Shujing Zhao  <pearly.zhao@oracle.com>
778         PR c++/30566
779         * name-lookup.c (pushdecl_maybe_friend): Avoid the warnings about
780         shadowing the outer parameter or variables by the declaration of
781         nested function in nested structure or class. Warn the shadowing by
782         the declaration of nested lambda expression.
784 2010-05-13  Jason Merrill  <jason@redhat.com>
786         * typeck.c (cp_build_array_ref): Factor out from...
787         (build_array_ref): ...here.  Drop complain parm.
788         (build_new_op): Adjust.
789         * class.c (build_vtbl_ref_1): Adjust.
790         * decl2.c (grok_array_decl): Adjust.
791         * cp-tree.h: Adjust prototypes.
793 2010-05-13  Jan Hubicka  <jh@suse.cz>
795         * decl.c (cp_finish_decl): Do not worry about used attribute.
797 2010-05-12  Jason Merrill  <jason@redhat.com>
799         * typeck.c (build_array_ref): Take complain parm.
800         * cp-tree.h: Add it to prototype.
801         * call.c (build_new_op): Pass it.
802         * class.c (build_vtbl_ref): Pass it.
803         * decl2.c (grok_array_decl): Pass it.
805         PR bootstrap/44048
806         PR target/44099
807         * cp-tree.def (NULLPTR_TYPE): Remove.
808         * cp-tree.h (NULLPTR_TYPE_P): New.
809         (SCALAR_TYPE_P): Use it.
810         (nullptr_type_node): New.
811         (cp_tree_index): Add CPTI_NULLPTR_TYPE.
812         * decl.c (cxx_init_decl_processing): Call record_builtin_type on
813         nullptr_type_node.
814         * cvt.c (ocp_convert): Use NULLPTR_TYPE_P instead of NULLPTR_TYPE.
815         * cxx-pretty-print.c (pp_cxx_constant): Likewise.
816         * error.c (dump_type, dump_type_prefix, dump_type_suffix): Likewise.
817         * mangle.c (write_type): Likewise.
818         * name-lookup.c (arg_assoc_type): Likewise.
819         * typeck.c (build_reinterpret_cast_1): Likewise.
820         * rtti.c (typeinfo_in_lib_p): Likewise.
821         (emit_support_tinfos): Remove local nullptr_type_node.
823         * cp-tree.h (UNKNOWN_TYPE): Remove.
824         * decl.c (cxx_init_decl_processing): Use LANG_TYPE instead.
825         * error.c (dumy_type, dump_type_prefix, dump_type_suffix): Likewise.
826         * typeck2.c (cxx_incomplete_type_diagnostic): Likewise.
827         * class.c (instantiate_type): Check unknown_type_node rather than
828         UNKNOWN_TYPE.
829         * name-lookup.c (maybe_push_decl): Likewise.
830         * rtti.c (get_tinfo_decl_dynamic): Likewise.
831         (get_typeid): Likewise.
832         * semantics.c (finish_offsetof): Likewise.
834         PR c++/20669
835         * call.c (add_template_candidate_real): If deduction fails, still
836         add the template as a non-viable candidate.
837         (equal_functions): Handle template candidates.
838         (print_z_candidate): Likewise.
839         (print_z_candidates): Likewise.
840         (build_new_function_call): Likewise.
842         * cp-tree.h (LOOKUP_LIST_ONLY): New.
843         * call.c (add_candidates): Enforce it.
844         (build_new_method_call): Try non-list ctor if no viable list ctor.
845         (build_user_type_conversion_1): Likewise.
847         * call.c (add_candidates): Distinguish between type(x) and
848         x.operator type().
849         (convert_class_to_reference): Set LOOKUP_NO_CONVERSION.
850         (build_new_method_call): Give better error for conversion op.
852         * call.c (add_candidates): Add first_arg and return_type parms.
853         Add special constructor/conversion op handling.
854         (convert_class_to_reference): Use it.
855         (build_user_type_conversion_1): Likewise.
856         (build_op_call): Likewise.
857         (build_new_method_call): Likewise.
858         (build_new_op): Adjust.
859         (perform_overload_resolution): Adjust.
861 2010-05-11  Paolo Carlini  <paolo.carlini@oracle.com>
863         PR c++/34272
864         PR c++/43630
865         PR c++/34491
866         * pt.c (process_partial_specialization): Return error_mark_node
867         in case of unused template parameters in partial specialization.
869 2010-05-11  Jakub Jelinek  <jakub@redhat.com>
871         PR c++/44062
872         * semantics.c (finish_expr_stmt): Don't call mark_exp_read here...
873         * cvt.c (convert_to_void): ... but here.  If expr is a COMPOUND_EXPR,
874         look at its second operand.
876 2010-05-10  Jason Merrill  <jason@redhat.com>
878         PR c++/44017
879         * semantics.c (baselink_for_fns): Revert earlier change.
881         PR c++/44045
882         * typeck.c (cp_build_modify_expr): Complain about assignment to
883         array from init list.
885 2010-05-10  Fabien Chêne  <fabien.chene@gmail.com>
887         PR c++/43719
888         * decl.c (check_initializer): strip array type before checking for
889         uninitialized const or ref members.
891 2010-05-07  Fabien Chêne  <fabien.chene@gmail.com>
893         PR c++/43951
894         * init.c (diagnose_uninitialized_cst_or_ref_member_1): Returns the
895         error count. Emit errors only if compain is true.
896         (build_new_1): Do not return error_mark_node if
897         diagnose_uninitialized_cst_or_ref_member_1 does not diagnose any
898         errors. Delay the check for user-provided constructor.
899         (perform_member_init): Adjust.
900         * cp-tree.h (diagnose_uninitialized_cst_or_ref_member): Change the
901         prototype.
903 2010-05-06  Magnus Fromreide  <magfr@lysator.liu.se>
904             Jason Merrill  <jason@redhat.com>
906         Add support for C++0x nullptr.
907         * cp-tree.def: Add NULLPTR_TYPE.
908         * cp-tree.h: Add nullptr_node.
909         (cp_tree_index): Add CPTI_NULLPTR.
910         (SCALAR_TYPE_P): Add NULLPTR_TYPE.
911         * call.c (null_ptr_cst_p): Handle nullptr.
912         (standard_conversion): Likewise.
913         (convert_arg_to_ellipsis): Likewise.
914         * mangle.c (write_type): Likewise.
915         * name-lookup.c (arg_assoc_type): Likewise.
916         * parser.c (cp_parser_primary_expression): Likewise.
917         * typeck.c (cp_build_binary_op): Likewise.
918         (build_reinterpret_cast_1): Likewise.
919         * error.c (dump_type): Likewise.
920         (dump_type_prefix, dump_type_suffix): Likewise.
921         * decl.c (cxx_init_decl_processing): Likewise.
922         * cxx-pretty-print.c (pp_cxx_constant): Likewise.
923         * cvt.c (ocp_convert): Likewise.
924         * rtti.c (typeinfo_in_lib_p, emit_support_tinfos): Put
925         nullptr_t tinfo in libsupc++.
927 2010-05-06  Jason Merrill  <jason@redhat.com>
929         * semantics.c (simplify_aggr_init_expr): Use INIT_EXPR.
931 2010-04-22  Jakub Jelinek <jakub@redhat.com>
932             Dodji Seketeli <dodji@redhat.com>
934         PR c/18624
935         * cp-tree.h (mark_exp_read, rvalue_use, lvalue_use, type_use):
936         Declare ...
937         * expr.c (mark_exp_read, rvalue_use, lvalue_use, type_use): ... new fns.
938         * typeck.c (cxx_sizeof_expr, cxx_alignof_expr): Call type_use.
939         (decay_conversion, perform_integral_promotions): Call rvalue_use.
940         (cp_build_unary_op): Call lvalue_use.
941         * decl.c (unused_but_set_errorcount): New variable.
942         (poplevel): Issue -Wunused-but-set-variable diagnostics.
943         (duplicate_decls): Merge DECL_READ_P flags.
944         (start_cleanup_fn): Set DECL_READ_P flag.
945         (finish_function): Issue -Wunused-but-set-parameter diagnostics.
946         * tree.c (rvalue): Call rvalue_use.
947         * pt.c (convert_nontype_argument): Likewise.
948         * semantics.c (finish_expr_stmt, finish_asm_stmt, finish_typeof,
949         finish_decltype_type): Likewise.
950         * call.c (convert_like_real) <ck_identity, ck_user>: Call rvalue use.
951         (build_x_va_arg, build_new_method_call, build_over_call): Call lvalue_use
952         or rvalue_use depending on the expr.
953         * init.c (build_new, build_delete): Likewise.
954         * rtti.c (build_typeid, build_dynamic_cast_1): Likewise.
956 2010-05-05  Jason Merrill  <jason@redhat.com>
958         PR c++/43787
959         * cp-gimplify.c (cp_gimplify_expr): Remove copies of empty classes.
960         * call.c (build_over_call): Don't try to avoid INIT_EXPR copies here.
962 2010-05-04  Paolo Carlini  <paolo.carlini@oracle.com>
964         PR c++/43028
965         * pt.c (unify): Check each elt for error_mark_node.
967 2010-05-04  Jason Merrill  <jason@redhat.com>
969         PR c++/38064
970         * typeck.c (cp_build_binary_op): Allow enums for <> as well.
972 2010-05-04  Paolo Carlini  <paolo.carlini@oracle.com>
974         PR c++/43705
975         * call.c (build_new_method_call): Return error_mark_node if fns is
976         NULL_TREE.
978 2010-05-03  Dodji Seketeli  <dodji@redhat.com>
980         PR c++/43953
981         * pt.c (most_specialized_class): Pretend we are processing
982         a template decl during the call to coerce_template_parms.
984 2010-05-03  Jason Merrill  <jason@redhat.com>
986         PR c++/42810
987         PR c++/43680
988         * decl.c (finish_enum): Use the TYPE_MIN_VALUE and TYPE_MAX_VALUE
989         from the selected underlying type unless -fstrict-enums.  Set
990         ENUM_UNDERLYING_TYPE to have the restricted range.
991         * cvt.c (type_promotes_to): Use ENUM_UNDERLYING_TYPE.
992         * class.c (check_bitfield_decl): Likewise.
994 2010-05-01  H.J. Lu  <hongjiu.lu@intel.com>
996         PR c++/43951
997         * init.c (build_new_1): Revert the accidental checkin in
998         revision 158918.
1000 2010-04-30  Jason Merrill  <jason@redhat.com>
1002         PR c++/43868
1003         * cxx-pretty-print.c (pp_cxx_decl_specifier_seq): Move pmf handling...
1004         (pp_cxx_type_specifier_seq): ...here.
1006 2010-04-30  Steven Bosscher  <steven@gcc.gnu.org>
1008         * optimize.c, parser.c, mangle.c, cp-tree.h: Do not include varray.h.
1009         * Make-lang.in: Don't include varray.h dependency in CXX_TREE_H.
1011 2010-04-30  Shujing Zhao  <pearly.zhao@oracle.com>
1013         PR c++/43779
1014         * typeck.c (warn_args_num): New function.
1015         (convert_arguments): Use warn_args_num to print the diagnostic
1016         messages. 
1018 2010-04-29  Fabien Chêne  <fabien.chene@gmail.com>
1020         PR c++/43890
1021         * init.c (diagnose_uninitialized_cst_or_ref_member): check for
1022         user-provided constructor while recursing.
1024 2010-04-28  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1026         PR c++/9335
1027         * error.c (print_instantiation_partial_context_line): Handle
1028         recursive instantiation.
1029         (print_instantiation_partial_context): Likewise.
1031 2010-04-27  Jason Merrill  <jason@redhat.com>
1033         * init.c (perform_member_init): Check CLASS_TYPE_P.
1035 2010-04-27  Fabien Chêne  <fabien.chene@gmail.com>
1037         PR c++/29043
1038         * init.c (perform_member_init): check for uninitialized const or
1039         reference members, including array types.
1041 2010-04-24  Jason Merrill  <jason@redhat.com>
1043         * tree.c (get_fns): Split out from get_first_fn.
1044         * cp-tree.h: Declare it.
1045         * search.c (shared_member_p): Use it.
1046         * semantics.c (finish_qualified_id_expr): Simplify.
1047         (finish_id_expression): Simplify.
1049         * semantics.c (finish_non_static_data_member): Call maybe_dummy_object
1050         whenever object is NULL_TREE.  Don't do 'this' capture here.
1051         (finish_qualified_id_expr): Pass NULL_TREE.
1052         (finish_id_expression): Likewise.
1053         (lambda_expr_this_capture): Likewise.
1055         * semantics.c (finish_qualified_id_expr): Use maybe_dummy_object
1056         rather than checking current_class_ref directly.
1057         (finish_call_expr): Likewise.
1059         PR c++/43856
1060         * name-lookup.c (qualify_lookup): Disqualify lambda op().
1061         * class.c (current_nonlambda_class_type): New fn.
1062         * semantics.c (nonlambda_method_basetype): New.
1063         * cp-tree.h: Declare them.
1064         * tree.c (maybe_dummy_object): Handle implicit 'this' capture.
1066         * semantics.c (baselink_for_fns): Correct BASELINK_BINFO.
1068         PR c++/43875
1069         * semantics.c (lambda_return_type): Complain about
1070         braced-init-list.
1072         PR c++/43790
1073         * tree.c (cv_unqualified): Handle error_mark_node.
1075         PR c++/41468
1076         * call.c (convert_like_real) [ck_ambig]: Just return error_mark_node
1077         if we don't want errors.
1079         PR c++/41468
1080         * class.c (convert_to_base): Add complain parameter.  Pass
1081         ba_quiet to lookup_base if we don't want errors.
1082         (build_vfield_ref): Pass complain to convert_to_base.
1083         * call.c (convert_like_real): Likewise.
1084         (initialize_reference): Likewise.
1085         (perform_direct_initialization_if_possible): Pass complain to
1086         convert_like_real.
1087         * cp-tree.h: Adjust.
1089 2010-04-27  Fabien Chêne  <fabien.chene@gmail.com>
1090             Jason Merrill  <jason@redhat.com>
1092         PR c++/42844
1093         * decl.c (check_for_uninitialized_const_var): Handle classes that need
1094         constructing, too.
1095         (check_initializer): Call it for classes that need constructing, too.
1096         * class.c (in_class_defaulted_default_constructor): New.
1097         * cp-tree.h: Declare it.
1099 2010-04-20  Jason Merrill  <jason@redhat.com>
1101         PR c++/9335
1102         * init.c (constant_value_1): Treat error_mark_node as a constant
1103         if DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P is set.
1104         * cvt.c (ocp_convert): Handle getting error_mark_node from
1105         integral_constant_value.
1106         * decl.c (compute_array_index_type): Likewise.
1108 2010-04-20  Dodji Seketeli  <dodji@redhat.com>
1110         PR c++/43800
1111         PR c++/43704
1112         * typeck.c (incompatible_dependent_types_p): If one of the
1113         compared types if not a typedef then honour their main variant
1114         equivalence.
1116 2010-04-20  Jakub Jelinek  <jakub@redhat.com>
1118         * cp-tree.h (TYPE_REF_IS_RVALUE): Remove.
1120 2010-04-19  Dodji Seketeli  <dodji@redhat.com>
1122         PR c++/43704
1123         * typeck.c (structural_comptypes): Test dependent typedefs
1124         incompatibility before testing for their main variant based
1125         equivalence.
1127 2010-04-19  Jakub Jelinek  <jakub@redhat.com>
1129         * cp-tree.h (SCOPED_ENUM_P, UNSCOPED_ENUM_P, SET_SCOPED_ENUM_P): Use
1130         ENUM_IS_SCOPED bit instead of TYPE_LANG_FLAG_5.
1132 2010-04-18  Eric Botcazou  <ebotcazou@adacore.com>
1134         * decl.c (cxx_init_decl_processing): Remove second argument in call to
1135         build_common_tree_nodes.
1137 2010-04-14  Jason Merrill  <jason@redhat.com>
1139         PR c++/36625
1140         * parser.c (cp_parser_parenthesized_expression_list): Change
1141         is_attribute_list parm to int to indicate whether or not to
1142         handle initial identifier specially.
1143         (cp_parser_attribute_list): Use attribute_takes_identifier_p.
1145 2010-04-13  Jason Merrill  <jason@redhat.com>
1147         * call.c (type_decays_to): Check MAYBE_CLASS_TYPE_P instead of
1148         CLASS_TYPE_P.
1149         * parser.c (cp_parser_lambda_expression): Complain about lambda in
1150         unevaluated context.
1151         * pt.c (iterative_hash_template_arg): Don't crash on lambda.
1153 2010-04-12  Jason Merrill  <jason@redhat.com>
1155         PR c++/43641
1156         * semantics.c (maybe_add_lambda_conv_op): Use build_call_a and tweak
1157         return value directly.
1159         * call.c (type_decays_to): Call cv_unqualified for non-class type.
1161 2010-04-12  Fabien Chene  <fabien.chene@gmail.com>
1163         PR c++/25811
1164         * cp-tree.h (diagnose_uninitialized_cst_or_ref_member): Declare.
1165         * init.c (build_new_1): Check for uninitialized const members and
1166         uninitialized reference members, when using new without
1167         new-initializer. Call diagnose_uninitialized_cst_or_ref_member.
1168         (diagnose_uninitialized_cst_or_ref_member): Define, call
1169         diagnose_uninitialized_cst_or_ref_member_1.
1170         (diagnose_uninitialized_cst_or_ref_member_1): New function.
1172 2010-04-12  Richard Guenther  <rguenther@suse.de>
1174         PR c++/43611
1175         * semantics.c (expand_or_defer_fn_1): Do not keep extern
1176         template inline functions.
1178 2010-04-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1180         PR c++/28584
1181         * typeck.c (cp_build_c_cast): Warn for casting integer to larger
1182         pointer type.
1184 2010-04-07  Jason Merrill  <jason@redhat.com>
1186         PR c++/43016
1187         * decl.c (start_preparsed_function): Do defer nested functions.
1189         PR c++/11094, DR 408
1190         * cp-tree.h (VAR_HAD_UNKNOWN_BOUND, SET_VAR_HAD_UNKNOWN_BOUND): New.
1191         * decl2.c (finish_static_data_member_decl): Set it.
1192         * decl.c (duplicate_decls): Propagate it.
1193         * pt.c (tsubst_decl): Don't substitute the domain of an array
1194         VAR_DECL if it's set.
1195         (regenerate_decl_from_template): Substitute it here.
1196         (type_dependent_expression_p): Return true if it's set.
1197         * semantics.c (finish_decltype_type): Instantiate such a variable.
1198         * typeck.c (cxx_sizeof_expr): Likewise.
1199         (strip_array_domain): New.
1201         PR c++/43145
1202         * name-lookup.c (current_decl_namespace): Non-static.
1203         (pop_nested_namespace): Sanity check.
1204         * cp-tree.h: Declare current_decl_namespace.
1205         * decl.c (grokvardecl): Use it instead of current_namespace.
1206         (grokfndecl): Likewise.
1208         PR c++/38392
1209         * pt.c (tsubst_friend_function): Instatiate a friend that has already
1210         been used.
1212         * pt.c (print_template_statistics): New.
1213         * cp-tree.h: Declare it.
1214         * tree.c (cxx_print_statistics): Call it.
1216         PR c++/41970
1217         * decl.c (grokvardecl): Tweak warning message.
1218         (grokfndecl): Likewise.
1220 2010-04-07  Dodji Seketeli  <dodji@redhat.com>
1222         PR c++/42697
1223         *pt.c (tsubst_decl): Get the arguments of a specialization from
1224         the specialization template, not from the most general template.
1226 2010-04-07  Dodji Seketeli  <dodji@redhat.com>
1228         PR c++/40239
1229         * typeck2.c (process_init_constructor_record):
1230         value-initialize members that are are not explicitely
1231         initialized.
1233 2010-04-07  Jie Zhang  <jie@codesourcery.com>
1235         PR c++/42556
1236         * typeck2.c (split_nonconstant_init_1): Drop empty CONSTRUCTOR
1237         when all of its elements are non-constant and have been split out.
1239 2010-04-06  Taras Glek  <taras@mozilla.com>
1240             Jason Merrill  <jason@redhat.com>
1242         * parser.c (cp_parser_class_specifier): Set class location to that
1243         of IDENTIFIER_NODE instead of '{' when possible.
1244         * semantics.c (begin_class_definition): Do not overide locations
1245         with less precise ones.
1247 2010-04-06  Jason Merrill  <jason@redhat.com>
1249         PR c++/43648
1250         * name-lookup.c (constructor_name_p): Allow X::~X even for typedefs.
1252         PR c++/43621
1253         * pt.c (maybe_update_decl_type): Check the return value from
1254         push_scope.
1256 2010-04-01  Jason Merrill  <jason@redhat.com>
1258         * decl.c (next_initializable_field): No longer static.
1259         * cp-tree.h: Declare it.
1260         * call.c (build_aggr_conv): Fail if there are more initializers
1261         than initializable fields.
1263         * semantics.c (maybe_add_lambda_conv_op): Use null_pointer_node
1264         instead of void_zero_node.
1266 2010-03-31  Dodji Seketeli  <dodji@redhat.com>
1268         PR c++/43558
1269         * cp-tree.h (TEMPLATE_TYPE_PARM_SIBLING_PARMS): New accessor macro.
1270         * pt.c (end_template_parm_list): Store sibling template parms of
1271         each TEMPLATE_TYPE_PARMs into its TEMPLATE_TYPE_PARM_SIBLING_PARMS.
1272         (push_template_decl_real): Don't store the containing template decl
1273         into the DECL_CONTEXT of TEMPLATE_TYPE_PARMs anymore.
1274         * typeck.c (get_template_parms_of_dependent_type): Get sibling parms
1275         of a TEMPLATE_TYPE_PARM from TEMPLATE_TYPE_PARM_SIBLING_PARMS.
1276         Simplify the logic.
1278 2010-03-30  Jason Merrill  <jason@redhat.com>
1280         PR c++/43076
1281         * pt.c (push_template_decl_real): Deal better with running out of
1282         scopes before running out of template parms.
1284         PR c++/41185
1285         PR c++/41786
1286         * parser.c (cp_parser_direct_declarator): Don't allow VLAs in
1287         function parameter context.  Don't print an error if parsing
1288         tentatively.
1290         PR c++/43559
1291         * pt.c (more_specialized_fn): Don't control cv-qualifier check
1292         with same_type_p.
1294 2010-03-26  Jason Merrill  <jason@redhat.com>
1296         PR c++/43509
1297         * parser.c (cp_parser_qualifying_entity): Do accept enum names in
1298         c++0x mode, but not other type-names.
1300 2010-03-26  Dodji Seketeli  <dodji@redhat.com>
1302         PR c++/43327
1303         * pt.c (add_to_template_args): Support NULL ARGS;
1304         (most_specialized_class): call coerce_template_parms on
1305         template arguments passed to get_class_bindings. Use
1306         add_to_template_args.
1307         (unify): Handle VAR_DECLs.
1309 2010-03-26  Dodji Seketeli  <dodji@redhat.com>
1311         * cp-tree.h (get_template_parms_at_level): Change unsigned parm
1312         into int.
1313         * pt.c (get_template_parms_at_level): Adjust.
1315 2010-03-25  Dodji Seketeli  <dodji@redhat.com>
1317         PR c++/43206
1318         * cp-tree.h (get_template_parms_at_level): Declare ...
1319         * pt.c (get_template_parms_at_level): ... new function.
1320         * typeck.c (get_template_parms_of_dependent_type): If a template
1321         type parm's DECL_CONTEXT isn't yet set, get its siblings from
1322         current_template_parms. Use get_template_parms_at_level. Remove
1323         useless test.
1324         (incompatible_dependent_types_p): If we get empty parms from just one
1325         of the template type parms we are comparing then the template parms are
1326         incompatible.
1328 2010-03-24  Jason Merrill  <jason@redhat.com>
1330         PR c++/43502
1331         * parser.c (make_declarator): Initialize id_loc.
1332         (cp_parser_lambda_declarator_opt): And set it.
1334 2010-03-23  Jason Merrill  <jason@redhat.com>
1336         Make lambda conversion op and op() non-static.
1337         * semantics.c (maybe_add_lambda_conv_op): Make non-static.
1338         Also add the thunk function returned by the conversion op.
1339         Mark the conversion deleted if the op() is variadic.
1340         * decl2.c (mark_used): Give helpful message about deleted conversion.
1341         * parser.c (cp_parser_lambda_declarator_opt): Don't make op() static.
1342         * semantics.c (finish_this_expr): Adjust.
1343         * mangle.c (write_closure_type_name): Adjust.
1344         * decl.c (grok_op_properties): Don't allow it.
1345         * call.c (build_user_type_conversion_1): No static conversion ops.
1346         (build_op_call): Or op().
1348         * decl2.c (change_return_type): Fix 'this' quals.
1350 2010-03-22  Jason Merrill  <jason@redhat.com>
1352         PR c++/43333
1353         * tree.c (pod_type_p): Use old meaning in C++98 mode.
1355         PR c++/43281
1356         * pt.c (contains_auto_r): New fn.
1357         (do_auto_deduction): Use it.
1358         (tsubst): Don't look at TREE_TYPE of a TEMPLATE_TYPE_PARM.
1360 2010-03-20  Simon Martin  <simartin@users.sourceforge.net>
1362         PR c++/43081:
1363         * decl2.c (grokfield): Handle invalid initializers for member
1364         functions.
1366 2010-03-20  Dodji Seketeli  <dodji@redhat.com>
1368         PR c++/43375
1369         * method.c (make_alias_for): Avoid crashing when DECL_LANG_SPECIFIC
1370         is NULL.
1371         * decl2.c (vague_linkage_p): Likewise.
1373 2010-03-18  Paolo Carlini  <paolo.carlini@oracle.com>
1375         PR c++/43418
1376         * parser.c (cp_parser_for_init_statement): Use NULL_TREE, not
1377         false, in the cp_parser_expression_statement call.
1379 2010-03-05  Jason Merrill  <jason@redhat.com>
1381         * mangle.c (mangle_decl): Give name collision error even without
1382         ASM_OUTPUT_DEF.
1384 2010-03-04  Marco Poletti  <poletti.marco@gmail.com>
1386         * pt.c (process_partial_specialization): Use error_n instead of
1387         error.
1389 2010-03-03  Jason Merrill  <jason@redhat.com>
1391         PR c++/12909
1392         * mangle.c (mangle_decl): Handle VAR_DECL, too.
1394 2010-03-03  Jason Merrill  <jason@redhat.com>
1396         PR c++/12909
1397         * mangle.c: Include cgraph.h.
1398         (mangle_decl): If the mangled name will change in a later
1399         ABI version, make the later mangled name an alias.
1400         * method.c (make_alias_for): Copy DECL_ARGUMENTS.
1401         * Make-lang.in (mangle.o): Depend on cgraph.h.
1402         * method.c (make_alias_for): Handle VAR_DECL, too.
1403         * decl2.c (vague_linkage_p): Rename from vague_linkage_fn_p.
1404         * tree.c (no_linkage_check): Adjust.
1405         * decl.c (maybe_commonize_var): Adjust.
1406         * cp-tree.h: Adjust.
1408 2010-03-01  Marco Poletti  <poletti.marco@gmail.com>
1410         * pt.c (redeclare_class_template): Use error_n and inform_n.
1412 2010-02-27  Mark Mitchell  <mark@codesourcery.com>
1414         PR c++/42748
1415         * cp-tree.h (push_tinst_level): Declare.
1416         (pop_tinst_level): Likewise.
1417         * pt.c (push_tinst_level): Give it external linkage.
1418         (pop_tinst_level): Likewise.
1419         * mangle.c (mangle_decl_string): Set the source location to that
1420         of the decl while mangling.
1422 2010-02-27  Simon Martin  <simartin@users.sourceforge.net>
1424         PR c++/42054
1425         * pt.c (redeclare_class_template): Return false if there are erroneous
1426         template parameters.
1428 2010-02-24  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1430         * pt.c (push_tinst_level): Replace -ftemplate-depth- with 
1431         -ftemplate-depth=.
1433 2010-02-24  Jason Merrill  <jason@redhat.com>
1435         PR c++/12909
1436         * mangle.c (write_type): Give -Wabi warning for old vector mangling.
1438         * class.c (layout_class_type): Don't give -Wabi warning for a bug
1439         in a previous ABI version.
1441 2010-02-23  Jason Merrill  <jason@redhat.com>
1443         PR c++/43143
1444         * typeck2.c (digest_init_r): Accept value init of array.
1446 2010-02-22  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1448         PR c++/43126
1449         * typeck.c (convert_arguments): Update error message.
1451 2010-02-22  Mike Stump  <mikestump@comcast.net>
1453         PR c++/43125
1454         * decl.c (duplicate_decls): Merge DECL_PRESERVE_P.
1456 2010-02-21  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1458         PR c++/23510
1459         * error.c (print_instantiation_partial_context_line): New.
1460         (print_instantiation_partial_context): Print at most 12 contexts,
1461         skip the rest with a message.
1463 2010-02-21  Dodji Seketeli  <dodji@redhat.com>
1465         PR c++/42824
1466         * pt.c (lookup_template_class): Better support of specialization
1467         of member of class template implicit instantiation.
1469 2010-02-20  Manuel López-Ibáñez  <manu@gcc.gnu.org>
1471         PR c++/35669
1472         * call.c (conversion_null_warnings): Replace -Wconversion with
1473         -Wconversion-null.
1474         * cvt.c (build_expr_type_conversion): Likewise.
1476 2010-02-18  Jason Merrill  <jason@redhat.com>
1478         PR c++/42837
1479         * class.c (create_vtable_ptr): Set DECL_PACKED if type is packed.
1481         PR c++/43108
1482         * typeck.c (cp_build_binary_op): Adapt mixed complex/non handling from
1483         C build_binary_op.
1484         * cp-tree.h (WANT_VECTOR_OR_COMPLEX): Rename from WANT_VECTOR.
1485         * cvt.c (build_expr_type_conversion): Allow COMPLEX_TYPE.
1487         PR c++/43070
1488         * semantics.c (finish_goto_stmt): Don't call decay_conversion.
1490         PR c++/26261
1491         PR c++/43101
1492         * pt.c (tsubst_qualified_id): Do normal lookup in non-dependent scope.
1493         (maybe_update_decl_type): New fn.
1494         * parser.c (cp_parser_init_declarator): Use it.
1496         PR c++/43109
1497         * semantics.c (begin_class_definition): Don't crash on unnamed ns.
1499 2010-02-17  Jason Merrill  <jason@redhat.com>
1501         PR c++/43075
1502         * call.c (build_over_call): Don't create zero-sized assignments.
1503         * cp-gimplify.c (cp_genericize_r): Don't remove them here.
1504         * cp-objcp-common.c (cp_expr_size): Remove.
1505         * cp-tree.h: Remove prototype.
1507         PR c++/43069
1508         * name-lookup.c (set_decl_namespace): Don't copy DECL_CONTEXT if the
1509         decl we looked up doesn't match.
1511         PR c++/43093
1512         * cp-gimplify.c (cp_gimplify_expr) [INIT_EXPR]: Return if we don't
1513         have an INIT_EXPR anymore.
1515         PR c++/43079
1516         * pt.c (convert_nontype_argument): Change assert to test.
1518 2010-02-16  Jason Merrill  <jason@redhat.com>
1520         * cp-gimplify.c (cp_gimplify_expr): Fix error recovery.
1522         PR c++/43031
1523         * cp-gimplify.c (cp_gimplify_expr) [MODIFY_EXPR]: Use
1524         VIEW_CONVERT_EXPR for conversions between structural equality types
1525         that the back end can't tell are the same.
1527         PR c++/43036
1528         * tree.c (build_cplus_array_type): Set TYPE_MAIN_VARIANT to strip
1529         cv-quals from element here.
1530         (cp_build_qualified_type_real): Not here.  Preserve typedef name.
1532 2010-02-14  Jason Merrill  <jason@redhat.com>
1534         PR c++/41997
1535         * semantics.c (finish_compound_literal): Use
1536         cp_apply_type_quals_to_decl when creating a static variable.
1538 2010-02-12  Jason Merrill  <jason@redhat.com>
1540         PR c++/43024
1541         * name-lookup.h (current_binding_level): Check for null
1542         cp_function_chain.
1544 2010-02-12  Jason Merrill  <jason@redhat.com>
1546         PR c++/43054
1547         * tree.c (cp_tree_equal): Correct CALL_EXPR logic.
1549 2010-02-12  Jakub Jelinek  <jakub@redhat.com>
1551         PR c++/43033
1552         * name-lookup.c (pushdecl_maybe_friend): Check default args of t
1553         instead of x.
1555 2010-02-10  Jason Merrill  <jason@redhat.com>
1557         PR c++/41896
1558         * semantics.c (outer_lambda_capture_p): Revert.
1559         (add_capture): Only finish_member_declaration if
1560         we're in the lambda class.
1561         (register_capture_members): New.
1562         * cp-tree.h: Declare it.
1563         * parser.c (cp_parser_lambda_expression): Call it.
1565 2010-02-10  Jason Merrill  <jason@redhat.com>
1567         PR c++/41896
1568         * semantics.c (outer_lambda_capture_p): Use current_function_decl
1569         instead of current_class_type.
1571 2010-02-10  Jason Merrill  <jason@redhat.com>
1573         PR c++/42983, core issue 906
1574         * method.c (defaultable_fn_check): Check virtualness.
1576 2010-02-10  Jason Merrill  <jason@redhat.com>
1578         PR c++/43016
1579         * semantics.c (maybe_add_lambda_conv_op): Set DECL_INTERFACE_KNOWN.
1581 2010-02-10  Shujing Zhao  <pearly.zhao@oracle.com>
1583         * Make-lang.in (cp/cvt.o, cp/parser.o, cp/search.o): Depend on intl.h.
1584         * cvt.c (warn_ref_binding): Wrap the messages into G_() for easy
1585         translation.
1586         * parser.c (cp_parser_postfix_expression, cp_parser_new_type_id)
1587         (cp_parser_cast_expression, cp_parser_condition, cp_parser_decltype)
1588         (cp_parser_parameter_declaration)
1589         (cp_parser_exception_specification_opt)
1590         (cp_parser_exception_declaration): Likewise.
1591         * pt.c (check_default_tmpl_args): Likewise.
1592         * search.c (lookup_field_r): Likewise.
1594 2010-02-09  Jason Merrill  <jason@redhat.com>
1596         PR c++/42399
1597         * pt.c (tsubst_copy_and_build): Propagate LAMBDA_EXPR_LOCATION.
1599 2010-02-09  Jason Merrill  <jason@redhat.com>
1601         PR c++/42370
1602         * decl2.c (change_return_type): New fn.
1603         * semantics.c (apply_lambda_return_type): Use it.
1604         * cp-tree.h: Declare it.
1606 2010-02-05  Richard Guenther  <rguenther@suse.de>
1608         * Make-lang.in (cp/cp-lang.o): Depend on gt-cp-cp-lang.h.
1609         * cp-lang.c: Include gt-cp-cp-lang.h.
1610         * config-lang.in (gtfiles): Add cp/cp-lang.c.
1612 2010-02-05  Dodji Seketeli  <dodji@redhat.com>
1614         PR c++/42915
1615         * typeck.c (get_template_parms_of_dependent_type): Try getting
1616         the template parameters fromt the type itself first.
1618 2010-02-03  Jason Merrill  <jason@redhat.com>
1620         PR c++/4926
1621         PR c++/38600
1622         * mangle.c (write_unqualified_id): Split out from write_expression.
1623         (write_unqualified_name): Call it.
1624         (write_member_name): Likewise.
1625         (write_expression): Support TEMPLATE_ID_EXPR.
1626         Disambiguate operator names.
1628         PR c++/12909
1629         * mangle.c (write_type) [VECTOR_TYPE]: Change mangling with
1630         -fabi-version=4.
1632 2010-02-02  Jason Merrill  <jason@redhat.com>
1634         PR c++/41090
1635         * decl.c (cp_finish_decl): Add local statics to cfun->local_decls.
1636         * optimize.c (clone_body): Remap their initializers when making base
1637         variants.
1638         (maybe_clone_body): Complain if multiple clones aren't safe.
1640 2010-01-29  Dodji Seketeli  <dodji@redhat.com>
1642         PR c++/42758
1643         PR c++/42634
1644         PR c++/42336
1645         PR c++/42797
1646         PR c++/42880
1647         * cp-tree.h (NON_DEFAULT_TEMPLATE_ARGS_COUNT,
1648         SET_NON_DEFAULT_TEMPLATE_ARGS_COUNT,
1649         GET_NON_DEFAULT_TEMPLATE_ARGS_COUNT): New accessor macros.
1650         * pt.c (coerce_template_parms, type_unification_real,
1651         expand_template_argument_pack, coerce_template_parameter_pack):
1652         Set the non default template args count.
1653         (current_template_args): Always set non defaulted
1654         template args count when compiled with --enable-checking
1655         (tsubst_template_args, type_unification_real): Propagate the non
1656         defaulted template args count.
1657         * error.c (get_non_default_template_args_count): Renamed
1658         count_non_default_template_args into this. Don't calculate the
1659         non default template argument count anymore. Use the new
1660         accessor macros above to get it.
1661         (dump_template_argument_list, dump_type, dump_decl,
1662         dump_template_parms): Adjust.
1663         * parser.c (cp_parser_template_argument_list): Always set defaulted
1664         template args count when compiled with --enable-checking.
1666 2010-01-29  Shujing Zhao  <pearly.zhao@oracle.com>
1668         * decl.c (redeclaration_error_message): Wrap the return messages into
1669         G_() for easy translation.
1671 2010-01-28  Jason Merrill  <jason@redhat.com>
1673         PR c++/42880
1674         * semantics.c (begin_class_definition): Don't use type_as_string.
1676 2010-01-28  Dodji Seketeli  <dodji@redhat.com>
1678         PR c++/42713
1679         PR c++/42820
1680         * typeck.c (get_template_parms_of_dependent_type): Factorized
1681         this out of incompatible_template_type_parms_p
1682         (incompatible_dependent_types_p): Renamed
1683         incompatible_template_type_parms_p into this. Make it detect
1684         two incompatible dependent typedefs too.
1685         (structural_comptypes): Use incompatible_dependent_types_p.
1686         * pt.c (get_template_info):
1687         Handle BOUND_TEMPLATE_TEMPLATE_PARAM.
1689 2010-01-20  Janis Johnson  <janis187@us.ibm.com>
1690             Jason Merrill  <jason@redhat.com>
1692         * mangle.c (write_type): Mangle transparent record as member type.
1693         * semantics.c (begin_class_definition): Recognize decimal classes
1694         and set TYPE_TRANSPARENT_AGGR.
1696 2010-01-20  Jason Merrill  <jason@redhat.com>
1698         PR c++/42338
1699         * mangle.c (write_expression): Handle tree codes that have extra
1700         arguments in the middle-end.
1702 2010-01-20  Paolo Carlini  <paolo.carlini@oracle.com>
1704         PR c++/42038
1705         * except.c (expand_start_catch_block): Deal correctly with
1706         do_begin_catch returning error_mark_node.
1708 2010-01-20  Jason Merrill  <jason@redhat.com>
1710         PR c++/41788
1711         * class.c (layout_class_type): Set packed_maybe_necessary for packed
1712         non-PODs.
1714         PR c++/41920
1715         * semantics.c (build_lambda_object): Call mark_used on captured
1716         variables.
1718         PR c++/40750
1719         * decl.c (grokdeclarator): Clear type_quals for a member function
1720         declared using a typedef.  Don't complain about adding cv-quals
1721         to a function typedef in C++0x mode.
1723 2010-01-20  Jakub Jelinek  <jakub@redhat.com>
1725         * decl.c (create_array_type_for_decl): Remove set but not used
1726         variable error_msg.  Remove break stmts after return stmts.
1728 2010-01-19  Dodji Seketeli  <dodji@redhat.com>
1730         * error.c (dump_template_parms, count_non_default_template_args):
1731         Revert fix of PR c++/42634.
1733 2010-01-18  Dodji Seketeli  <dodji@redhat.com>
1735         PR c++/42634
1736         * error.c (dump_template_parms): Use innermost template
1737         arguments before calling count_non_default_template_args.
1738         (count_non_default_template_args): We are being called with
1739         template innermost arguments now. There is no need to ensure
1740         that again.
1742 2010-01-18  Dodji Seketeli  <dodji@redhat.com>
1744         PR c++/42766
1745         * cvt.c (build_expr_type_conversion): Look through OVERLOAD.
1747 2010-01-17  Dodji Seketeli  <dodji@redhat.com>
1749         PR c++/42697
1750         *pt.c (tsubst_decl):  Revert commit for PR c++/42697.
1752 2010-01-17  Dodji Seketeli  <dodji@redhat.com>
1754         PR c++/42697
1755         *pt.c (tsubst_decl): Get the arguments of a specialization from
1756         the specialization template, not from the most general template.
1758 2010-01-16  Jason Merrill  <jason@redhat.com>
1760         PR c++/42761
1761         * semantics.c (finish_decltype_type): Within a template, treat
1762         unresolved CALL_EXPR as dependent.
1764 2010-01-15  Dodji Seketeli  <dodji@redhat.com>
1766         * error.c (dump_template_parms,count_non_default_template_args):
1767         Revert changes of PR c++/42634.
1769 2010-01-14  Jakub Jelinek  <jakub@redhat.com>
1771         PR middle-end/42674
1772         * decl.c (finish_function): Don't emit -Wreturn-type warnings in
1773         functions with noreturn attribute.
1775 2010-01-14  Jason Merrill  <jason@redhat.com>
1777         PR c++/42701
1778         * call.c (build_new_method_call): Don't free the vec here.
1780         PR c++/42655
1781         * call.c (convert_like_real): Do full decay_conversion for ck_rvalue.
1783 2010-01-13  Dodji Seketeli  <dodji@redhat.com>
1785         PR c++/42634
1786         * error.c (dump_template_parms): Use innermost template
1787         arguments before calling count_non_default_template_args.
1788         (count_non_default_template_args): We are being called with
1789         template innermost arguments now. There is no need to ensure
1790         that again.
1792 2010-01-07  Dodji Seketeli  <dodji@redhat.com>
1794         c++/40155
1795         * pt.c (unify_pack_expansion): In non-deduced contexts, re-use template
1796         arguments that were previously deduced.
1798 2010-01-05  Jason Merrill  <jason@redhat.com>
1800         * pt.c (unify_pack_expansion): Handle deduction from init-list.
1801         * call.c (build_over_call): Don't complain about it.
1803 2010-01-04  Jason Merrill  <jason@redhat.com>
1805         PR c++/42555
1806         * pt.c (tsubst_decl): Don't apply type attributes in place.
1808         PR c++/42567
1809         * semantics.c (describable_type): Remove decltype comment and
1810         semantics.
1814 Copyright (C) 2010 Free Software Foundation, Inc.
1816 Copying and distribution of this file, with or without modification,
1817 are permitted in any medium without royalty provided the copyright
1818 notice and this notice are preserved.