OSDN Git Service

3935cc21241cb6f252b47e4499b14386b2c1026f
[pf3gnuchains/gcc-fork.git] / gcc / cp / ChangeLog
1 2010-04-27  Fabien Chêne  <fabien.chene@gmail.com>
2
3         PR c++/29043
4         * init.c (perform_member_init): check for uninitialized const or
5         reference members, including array types.
6
7 2010-04-24  Jason Merrill  <jason@redhat.com>
8
9         * tree.c (get_fns): Split out from get_first_fn.
10         * cp-tree.h: Declare it.
11         * search.c (shared_member_p): Use it.
12         * semantics.c (finish_qualified_id_expr): Simplify.
13         (finish_id_expression): Simplify.
14
15         * semantics.c (finish_non_static_data_member): Call maybe_dummy_object
16         whenever object is NULL_TREE.  Don't do 'this' capture here.
17         (finish_qualified_id_expr): Pass NULL_TREE.
18         (finish_id_expression): Likewise.
19         (lambda_expr_this_capture): Likewise.
20
21         * semantics.c (finish_qualified_id_expr): Use maybe_dummy_object
22         rather than checking current_class_ref directly.
23         (finish_call_expr): Likewise.
24
25         PR c++/43856
26         * name-lookup.c (qualify_lookup): Disqualify lambda op().
27         * class.c (current_nonlambda_class_type): New fn.
28         * semantics.c (nonlambda_method_basetype): New.
29         * cp-tree.h: Declare them.
30         * tree.c (maybe_dummy_object): Handle implicit 'this' capture.
31
32         * semantics.c (baselink_for_fns): Correct BASELINK_BINFO.
33
34         PR c++/43875
35         * semantics.c (lambda_return_type): Complain about
36         braced-init-list.
37
38         PR c++/43790
39         * tree.c (cv_unqualified): Handle error_mark_node.
40
41         PR c++/41468
42         * call.c (convert_like_real) [ck_ambig]: Just return error_mark_node
43         if we don't want errors.
44
45         PR c++/41468
46         * class.c (convert_to_base): Add complain parameter.  Pass
47         ba_quiet to lookup_base if we don't want errors.
48         (build_vfield_ref): Pass complain to convert_to_base.
49         * call.c (convert_like_real): Likewise.
50         (initialize_reference): Likewise.
51         (perform_direct_initialization_if_possible): Pass complain to
52         convert_like_real.
53         * cp-tree.h: Adjust.
54
55 2010-04-27  Fabien Chêne  <fabien.chene@gmail.com>
56             Jason Merrill  <jason@redhat.com>
57
58         PR c++/42844
59         * decl.c (check_for_uninitialized_const_var): Handle classes that need
60         constructing, too.
61         (check_initializer): Call it for classes that need constructing, too.
62         * class.c (in_class_defaulted_default_constructor): New.
63         * cp-tree.h: Declare it.
64
65 2010-04-20  Jason Merrill  <jason@redhat.com>
66
67         PR c++/9335
68         * init.c (constant_value_1): Treat error_mark_node as a constant
69         if DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P is set.
70         * cvt.c (ocp_convert): Handle getting error_mark_node from
71         integral_constant_value.
72         * decl.c (compute_array_index_type): Likewise.
73
74 2010-04-20  Dodji Seketeli  <dodji@redhat.com>
75
76         PR c++/43800
77         PR c++/43704
78         * typeck.c (incompatible_dependent_types_p): If one of the
79         compared types if not a typedef then honour their main variant
80         equivalence.
81
82 2010-04-20  Jakub Jelinek  <jakub@redhat.com>
83
84         * cp-tree.h (TYPE_REF_IS_RVALUE): Remove.
85
86 2010-04-19  Dodji Seketeli  <dodji@redhat.com>
87
88         PR c++/43704
89         * typeck.c (structural_comptypes): Test dependent typedefs
90         incompatibility before testing for their main variant based
91         equivalence.
92
93 2010-04-19  Jakub Jelinek  <jakub@redhat.com>
94
95         * cp-tree.h (SCOPED_ENUM_P, UNSCOPED_ENUM_P, SET_SCOPED_ENUM_P): Use
96         ENUM_IS_SCOPED bit instead of TYPE_LANG_FLAG_5.
97
98 2010-04-18  Eric Botcazou  <ebotcazou@adacore.com>
99
100         * decl.c (cxx_init_decl_processing): Remove second argument in call to
101         build_common_tree_nodes.
102
103 2010-04-14  Jason Merrill  <jason@redhat.com>
104
105         PR c++/36625
106         * parser.c (cp_parser_parenthesized_expression_list): Change
107         is_attribute_list parm to int to indicate whether or not to
108         handle initial identifier specially.
109         (cp_parser_attribute_list): Use attribute_takes_identifier_p.
110
111 2010-04-13  Jason Merrill  <jason@redhat.com>
112
113         * call.c (type_decays_to): Check MAYBE_CLASS_TYPE_P instead of
114         CLASS_TYPE_P.
115         * parser.c (cp_parser_lambda_expression): Complain about lambda in
116         unevaluated context.
117         * pt.c (iterative_hash_template_arg): Don't crash on lambda.
118
119 2010-04-12  Jason Merrill  <jason@redhat.com>
120
121         PR c++/43641
122         * semantics.c (maybe_add_lambda_conv_op): Use build_call_a and tweak
123         return value directly.
124
125         * call.c (type_decays_to): Call cv_unqualified for non-class type.
126
127 2010-04-12  Fabien Chene  <fabien.chene@gmail.com>
128
129         PR c++/25811
130         * cp-tree.h (diagnose_uninitialized_cst_or_ref_member): Declare.
131         * init.c (build_new_1): Check for uninitialized const members and
132         uninitialized reference members, when using new without
133         new-initializer. Call diagnose_uninitialized_cst_or_ref_member.
134         (diagnose_uninitialized_cst_or_ref_member): Define, call
135         diagnose_uninitialized_cst_or_ref_member_1.
136         (diagnose_uninitialized_cst_or_ref_member_1): New function.
137
138 2010-04-12  Richard Guenther  <rguenther@suse.de>
139
140         PR c++/43611
141         * semantics.c (expand_or_defer_fn_1): Do not keep extern
142         template inline functions.
143
144 2010-04-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
145
146         PR c++/28584
147         * typeck.c (cp_build_c_cast): Warn for casting integer to larger
148         pointer type.
149
150 2010-04-07  Jason Merrill  <jason@redhat.com>
151
152         PR c++/43016
153         * decl.c (start_preparsed_function): Do defer nested functions.
154
155         PR c++/11094, DR 408
156         * cp-tree.h (VAR_HAD_UNKNOWN_BOUND, SET_VAR_HAD_UNKNOWN_BOUND): New.
157         * decl2.c (finish_static_data_member_decl): Set it.
158         * decl.c (duplicate_decls): Propagate it.
159         * pt.c (tsubst_decl): Don't substitute the domain of an array
160         VAR_DECL if it's set.
161         (regenerate_decl_from_template): Substitute it here.
162         (type_dependent_expression_p): Return true if it's set.
163         * semantics.c (finish_decltype_type): Instantiate such a variable.
164         * typeck.c (cxx_sizeof_expr): Likewise.
165         (strip_array_domain): New.
166
167         * name-lookup.c (current_decl_namespace): Non-static.
168         (pop_nested_namespace): Sanity check.
169         * cp-tree.h: Declare current_decl_namespace.
170         * decl.c (grokvardecl): Use it instead of current_namespace.
171         (grokfndecl): Likewise.
172
173         PR c++/38392
174         * pt.c (tsubst_friend_function): Instatiate a friend that has already
175         been used.
176
177         * pt.c (print_template_statistics): New.
178         * cp-tree.h: Declare it.
179         * tree.c (cxx_print_statistics): Call it.
180
181         PR c++/41970
182         * decl.c (grokvardecl): Tweak warning message.
183         (grokfndecl): Likewise.
184
185 2010-04-07  Dodji Seketeli  <dodji@redhat.com>
186
187         PR c++/42697
188         *pt.c (tsubst_decl): Get the arguments of a specialization from
189         the specialization template, not from the most general template.
190
191 2010-04-07  Dodji Seketeli  <dodji@redhat.com>
192
193         PR c++/40239
194         * typeck2.c (process_init_constructor_record):
195         value-initialize members that are are not explicitely
196         initialized.
197
198 2010-04-07  Jie Zhang  <jie@codesourcery.com>
199
200         PR c++/42556
201         * typeck2.c (split_nonconstant_init_1): Drop empty CONSTRUCTOR
202         when all of its elements are non-constant and have been split out.
203
204 2010-04-06  Taras Glek  <taras@mozilla.com>
205             Jason Merrill  <jason@redhat.com>
206
207         * parser.c (cp_parser_class_specifier): Set class location to that
208         of IDENTIFIER_NODE instead of '{' when possible.
209         * semantics.c (begin_class_definition): Do not overide locations
210         with less precise ones.
211
212 2010-04-06  Jason Merrill  <jason@redhat.com>
213
214         PR c++/43648
215         * name-lookup.c (constructor_name_p): Allow X::~X even for typedefs.
216
217         PR c++/43621
218         * pt.c (maybe_update_decl_type): Check the return value from
219         push_scope.
220
221 2010-04-01  Jason Merrill  <jason@redhat.com>
222
223         * decl.c (next_initializable_field): No longer static.
224         * cp-tree.h: Declare it.
225         * call.c (build_aggr_conv): Fail if there are more initializers
226         than initializable fields.
227
228         * semantics.c (maybe_add_lambda_conv_op): Use null_pointer_node
229         instead of void_zero_node.
230
231 2010-03-31  Dodji Seketeli  <dodji@redhat.com>
232
233         PR c++/43558
234         * cp-tree.h (TEMPLATE_TYPE_PARM_SIBLING_PARMS): New accessor macro.
235         * pt.c (end_template_parm_list): Store sibling template parms of
236         each TEMPLATE_TYPE_PARMs into its TEMPLATE_TYPE_PARM_SIBLING_PARMS.
237         (push_template_decl_real): Don't store the containing template decl
238         into the DECL_CONTEXT of TEMPLATE_TYPE_PARMs anymore.
239         * typeck.c (get_template_parms_of_dependent_type): Get sibling parms
240         of a TEMPLATE_TYPE_PARM from TEMPLATE_TYPE_PARM_SIBLING_PARMS.
241         Simplify the logic.
242
243 2010-03-30  Jason Merrill  <jason@redhat.com>
244
245         PR c++/43076
246         * pt.c (push_template_decl_real): Deal better with running out of
247         scopes before running out of template parms.
248
249         PR c++/41185
250         PR c++/41786
251         * parser.c (cp_parser_direct_declarator): Don't allow VLAs in
252         function parameter context.  Don't print an error if parsing
253         tentatively.
254
255         PR c++/43559
256         * pt.c (more_specialized_fn): Don't control cv-qualifier check
257         with same_type_p.
258
259 2010-03-26  Jason Merrill  <jason@redhat.com>
260
261         PR c++/43509
262         * parser.c (cp_parser_qualifying_entity): Do accept enum names in
263         c++0x mode, but not other type-names.
264
265 2010-03-26  Dodji Seketeli  <dodji@redhat.com>
266
267         PR c++/43327
268         * pt.c (add_to_template_args): Support NULL ARGS;
269         (most_specialized_class): call coerce_template_parms on
270         template arguments passed to get_class_bindings. Use
271         add_to_template_args.
272         (unify): Handle VAR_DECLs.
273
274 2010-03-26  Dodji Seketeli  <dodji@redhat.com>
275
276         * cp-tree.h (get_template_parms_at_level): Change unsigned parm
277         into int.
278         * pt.c (get_template_parms_at_level): Adjust.
279
280 2010-03-25  Dodji Seketeli  <dodji@redhat.com>
281
282         PR c++/43206
283         * cp-tree.h (get_template_parms_at_level): Declare ...
284         * pt.c (get_template_parms_at_level): ... new function.
285         * typeck.c (get_template_parms_of_dependent_type): If a template
286         type parm's DECL_CONTEXT isn't yet set, get its siblings from
287         current_template_parms. Use get_template_parms_at_level. Remove
288         useless test.
289         (incompatible_dependent_types_p): If we get empty parms from just one
290         of the template type parms we are comparing then the template parms are
291         incompatible.
292
293 2010-03-24  Jason Merrill  <jason@redhat.com>
294
295         PR c++/43502
296         * parser.c (make_declarator): Initialize id_loc.
297         (cp_parser_lambda_declarator_opt): And set it.
298
299 2010-03-23  Jason Merrill  <jason@redhat.com>
300
301         Make lambda conversion op and op() non-static.
302         * semantics.c (maybe_add_lambda_conv_op): Make non-static.
303         Also add the thunk function returned by the conversion op.
304         Mark the conversion deleted if the op() is variadic.
305         * decl2.c (mark_used): Give helpful message about deleted conversion.
306         * parser.c (cp_parser_lambda_declarator_opt): Don't make op() static.
307         * semantics.c (finish_this_expr): Adjust.
308         * mangle.c (write_closure_type_name): Adjust.
309         * decl.c (grok_op_properties): Don't allow it.
310         * call.c (build_user_type_conversion_1): No static conversion ops.
311         (build_op_call): Or op().
312
313         * decl2.c (change_return_type): Fix 'this' quals.
314
315 2010-03-22  Jason Merrill  <jason@redhat.com>
316
317         PR c++/43333
318         * tree.c (pod_type_p): Use old meaning in C++98 mode.
319
320         PR c++/43281
321         * pt.c (contains_auto_r): New fn.
322         (do_auto_deduction): Use it.
323         (tsubst): Don't look at TREE_TYPE of a TEMPLATE_TYPE_PARM.
324
325 2010-03-20  Simon Martin  <simartin@users.sourceforge.net>
326
327         PR c++/43081:
328         * decl2.c (grokfield): Handle invalid initializers for member
329         functions.
330
331 2010-03-20  Dodji Seketeli  <dodji@redhat.com>
332
333         PR c++/43375
334         * method.c (make_alias_for): Avoid crashing when DECL_LANG_SPECIFIC
335         is NULL.
336         * decl2.c (vague_linkage_p): Likewise.
337
338 2010-03-18  Paolo Carlini  <paolo.carlini@oracle.com>
339
340         PR c++/43418
341         * parser.c (cp_parser_for_init_statement): Use NULL_TREE, not
342         false, in the cp_parser_expression_statement call.
343
344 2010-03-05  Jason Merrill  <jason@redhat.com>
345
346         * mangle.c (mangle_decl): Give name collision error even without
347         ASM_OUTPUT_DEF.
348
349 2010-03-04  Marco Poletti  <poletti.marco@gmail.com>
350
351         * pt.c (process_partial_specialization): Use error_n instead of
352         error.
353
354 2010-03-03  Jason Merrill  <jason@redhat.com>
355
356         PR c++/12909
357         * mangle.c (mangle_decl): Handle VAR_DECL, too.
358
359 2010-03-03  Jason Merrill  <jason@redhat.com>
360
361         PR c++/12909
362         * mangle.c: Include cgraph.h.
363         (mangle_decl): If the mangled name will change in a later
364         ABI version, make the later mangled name an alias.
365         * method.c (make_alias_for): Copy DECL_ARGUMENTS.
366         * Make-lang.in (mangle.o): Depend on cgraph.h.
367         * method.c (make_alias_for): Handle VAR_DECL, too.
368         * decl2.c (vague_linkage_p): Rename from vague_linkage_fn_p.
369         * tree.c (no_linkage_check): Adjust.
370         * decl.c (maybe_commonize_var): Adjust.
371         * cp-tree.h: Adjust.
372
373 2010-03-01  Marco Poletti  <poletti.marco@gmail.com>
374
375         * pt.c (redeclare_class_template): Use error_n and inform_n.
376
377 2010-02-27  Mark Mitchell  <mark@codesourcery.com>
378
379         PR c++/42748
380         * cp-tree.h (push_tinst_level): Declare.
381         (pop_tinst_level): Likewise.
382         * pt.c (push_tinst_level): Give it external linkage.
383         (pop_tinst_level): Likewise.
384         * mangle.c (mangle_decl_string): Set the source location to that
385         of the decl while mangling.
386
387 2010-02-27  Simon Martin  <simartin@users.sourceforge.net>
388
389         PR c++/42054
390         * pt.c (redeclare_class_template): Return false if there are erroneous
391         template parameters.
392
393 2010-02-24  Manuel López-Ibáñez  <manu@gcc.gnu.org>
394
395         * pt.c (push_tinst_level): Replace -ftemplate-depth- with 
396         -ftemplate-depth=.
397
398 2010-02-24  Jason Merrill  <jason@redhat.com>
399
400         PR c++/12909
401         * mangle.c (write_type): Give -Wabi warning for old vector mangling.
402
403         * class.c (layout_class_type): Don't give -Wabi warning for a bug
404         in a previous ABI version.
405
406 2010-02-23  Jason Merrill  <jason@redhat.com>
407
408         PR c++/43143
409         * typeck2.c (digest_init_r): Accept value init of array.
410
411 2010-02-22  Manuel López-Ibáñez  <manu@gcc.gnu.org>
412
413         PR c++/43126
414         * typeck.c (convert_arguments): Update error message.
415
416 2010-02-22  Mike Stump  <mikestump@comcast.net>
417
418         PR c++/43125
419         * decl.c (duplicate_decls): Merge DECL_PRESERVE_P.
420
421 2010-02-21  Manuel López-Ibáñez  <manu@gcc.gnu.org>
422
423         PR c++/23510
424         * error.c (print_instantiation_partial_context_line): New.
425         (print_instantiation_partial_context): Print at most 12 contexts,
426         skip the rest with a message.
427
428 2010-02-21  Dodji Seketeli  <dodji@redhat.com>
429
430         PR c++/42824
431         * pt.c (lookup_template_class): Better support of specialization
432         of member of class template implicit instantiation.
433
434 2010-02-20  Manuel López-Ibáñez  <manu@gcc.gnu.org>
435
436         PR c++/35669
437         * call.c (conversion_null_warnings): Replace -Wconversion with
438         -Wconversion-null.
439         * cvt.c (build_expr_type_conversion): Likewise.
440
441 2010-02-18  Jason Merrill  <jason@redhat.com>
442
443         PR c++/42837
444         * class.c (create_vtable_ptr): Set DECL_PACKED if type is packed.
445
446         PR c++/43108
447         * typeck.c (cp_build_binary_op): Adapt mixed complex/non handling from
448         C build_binary_op.
449         * cp-tree.h (WANT_VECTOR_OR_COMPLEX): Rename from WANT_VECTOR.
450         * cvt.c (build_expr_type_conversion): Allow COMPLEX_TYPE.
451
452         PR c++/43070
453         * semantics.c (finish_goto_stmt): Don't call decay_conversion.
454
455         PR c++/26261
456         PR c++/43101
457         * pt.c (tsubst_qualified_id): Do normal lookup in non-dependent scope.
458         (maybe_update_decl_type): New fn.
459         * parser.c (cp_parser_init_declarator): Use it.
460
461         PR c++/43109
462         * semantics.c (begin_class_definition): Don't crash on unnamed ns.
463
464 2010-02-17  Jason Merrill  <jason@redhat.com>
465
466         PR c++/43075
467         * call.c (build_over_call): Don't create zero-sized assignments.
468         * cp-gimplify.c (cp_genericize_r): Don't remove them here.
469         * cp-objcp-common.c (cp_expr_size): Remove.
470         * cp-tree.h: Remove prototype.
471
472         PR c++/43069
473         * name-lookup.c (set_decl_namespace): Don't copy DECL_CONTEXT if the
474         decl we looked up doesn't match.
475
476         PR c++/43093
477         * cp-gimplify.c (cp_gimplify_expr) [INIT_EXPR]: Return if we don't
478         have an INIT_EXPR anymore.
479
480         PR c++/43079
481         * pt.c (convert_nontype_argument): Change assert to test.
482
483 2010-02-16  Jason Merrill  <jason@redhat.com>
484
485         * cp-gimplify.c (cp_gimplify_expr): Fix error recovery.
486
487         PR c++/43031
488         * cp-gimplify.c (cp_gimplify_expr) [MODIFY_EXPR]: Use
489         VIEW_CONVERT_EXPR for conversions between structural equality types
490         that the back end can't tell are the same.
491
492         PR c++/43036
493         * tree.c (build_cplus_array_type): Set TYPE_MAIN_VARIANT to strip
494         cv-quals from element here.
495         (cp_build_qualified_type_real): Not here.  Preserve typedef name.
496
497 2010-02-14  Jason Merrill  <jason@redhat.com>
498
499         PR c++/41997
500         * semantics.c (finish_compound_literal): Use
501         cp_apply_type_quals_to_decl when creating a static variable.
502
503 2010-02-12  Jason Merrill  <jason@redhat.com>
504
505         PR c++/43024
506         * name-lookup.h (current_binding_level): Check for null
507         cp_function_chain.
508
509 2010-02-12  Jason Merrill  <jason@redhat.com>
510
511         PR c++/43054
512         * tree.c (cp_tree_equal): Correct CALL_EXPR logic.
513
514 2010-02-12  Jakub Jelinek  <jakub@redhat.com>
515
516         PR c++/43033
517         * name-lookup.c (pushdecl_maybe_friend): Check default args of t
518         instead of x.
519
520 2010-02-10  Jason Merrill  <jason@redhat.com>
521
522         PR c++/41896
523         * semantics.c (outer_lambda_capture_p): Revert.
524         (add_capture): Only finish_member_declaration if
525         we're in the lambda class.
526         (register_capture_members): New.
527         * cp-tree.h: Declare it.
528         * parser.c (cp_parser_lambda_expression): Call it.
529
530 2010-02-10  Jason Merrill  <jason@redhat.com>
531
532         PR c++/41896
533         * semantics.c (outer_lambda_capture_p): Use current_function_decl
534         instead of current_class_type.
535
536 2010-02-10  Jason Merrill  <jason@redhat.com>
537
538         PR c++/42983, core issue 906
539         * method.c (defaultable_fn_check): Check virtualness.
540
541 2010-02-10  Jason Merrill  <jason@redhat.com>
542
543         PR c++/43016
544         * semantics.c (maybe_add_lambda_conv_op): Set DECL_INTERFACE_KNOWN.
545
546 2010-02-10  Shujing Zhao  <pearly.zhao@oracle.com>
547
548         * Make-lang.in (cp/cvt.o, cp/parser.o, cp/search.o): Depend on intl.h.
549         * cvt.c (warn_ref_binding): Wrap the messages into G_() for easy
550         translation.
551         * parser.c (cp_parser_postfix_expression, cp_parser_new_type_id)
552         (cp_parser_cast_expression, cp_parser_condition, cp_parser_decltype)
553         (cp_parser_parameter_declaration)
554         (cp_parser_exception_specification_opt)
555         (cp_parser_exception_declaration): Likewise.
556         * pt.c (check_default_tmpl_args): Likewise.
557         * search.c (lookup_field_r): Likewise.
558
559 2010-02-09  Jason Merrill  <jason@redhat.com>
560
561         PR c++/42399
562         * pt.c (tsubst_copy_and_build): Propagate LAMBDA_EXPR_LOCATION.
563
564 2010-02-09  Jason Merrill  <jason@redhat.com>
565
566         PR c++/42370
567         * decl2.c (change_return_type): New fn.
568         * semantics.c (apply_lambda_return_type): Use it.
569         * cp-tree.h: Declare it.
570
571 2010-02-05  Richard Guenther  <rguenther@suse.de>
572
573         * Make-lang.in (cp/cp-lang.o): Depend on gt-cp-cp-lang.h.
574         * cp-lang.c: Include gt-cp-cp-lang.h.
575         * config-lang.in (gtfiles): Add cp/cp-lang.c.
576
577 2010-02-05  Dodji Seketeli  <dodji@redhat.com>
578
579         PR c++/42915
580         * typeck.c (get_template_parms_of_dependent_type): Try getting
581         the template parameters fromt the type itself first.
582
583 2010-02-03  Jason Merrill  <jason@redhat.com>
584
585         PR c++/4926
586         PR c++/38600
587         * mangle.c (write_unqualified_id): Split out from write_expression.
588         (write_unqualified_name): Call it.
589         (write_member_name): Likewise.
590         (write_expression): Support TEMPLATE_ID_EXPR.
591         Disambiguate operator names.
592
593         PR c++/12909
594         * mangle.c (write_type) [VECTOR_TYPE]: Change mangling with
595         -fabi-version=4.
596
597 2010-02-02  Jason Merrill  <jason@redhat.com>
598
599         PR c++/41090
600         * decl.c (cp_finish_decl): Add local statics to cfun->local_decls.
601         * optimize.c (clone_body): Remap their initializers when making base
602         variants.
603         (maybe_clone_body): Complain if multiple clones aren't safe.
604
605 2010-01-29  Dodji Seketeli  <dodji@redhat.com>
606
607         PR c++/42758
608         PR c++/42634
609         PR c++/42336
610         PR c++/42797
611         PR c++/42880
612         * cp-tree.h (NON_DEFAULT_TEMPLATE_ARGS_COUNT,
613         SET_NON_DEFAULT_TEMPLATE_ARGS_COUNT,
614         GET_NON_DEFAULT_TEMPLATE_ARGS_COUNT): New accessor macros.
615         * pt.c (coerce_template_parms, type_unification_real,
616         expand_template_argument_pack, coerce_template_parameter_pack):
617         Set the non default template args count.
618         (current_template_args): Always set non defaulted
619         template args count when compiled with --enable-checking
620         (tsubst_template_args, type_unification_real): Propagate the non
621         defaulted template args count.
622         * error.c (get_non_default_template_args_count): Renamed
623         count_non_default_template_args into this. Don't calculate the
624         non default template argument count anymore. Use the new
625         accessor macros above to get it.
626         (dump_template_argument_list, dump_type, dump_decl,
627         dump_template_parms): Adjust.
628         * parser.c (cp_parser_template_argument_list): Always set defaulted
629         template args count when compiled with --enable-checking.
630
631 2010-01-29  Shujing Zhao  <pearly.zhao@oracle.com>
632
633         * decl.c (redeclaration_error_message): Wrap the return messages into
634         G_() for easy translation.
635
636 2010-01-28  Jason Merrill  <jason@redhat.com>
637
638         PR c++/42880
639         * semantics.c (begin_class_definition): Don't use type_as_string.
640
641 2010-01-28  Dodji Seketeli  <dodji@redhat.com>
642
643         PR c++/42713
644         PR c++/42820
645         * typeck.c (get_template_parms_of_dependent_type): Factorized
646         this out of incompatible_template_type_parms_p
647         (incompatible_dependent_types_p): Renamed
648         incompatible_template_type_parms_p into this. Make it detect
649         two incompatible dependent typedefs too.
650         (structural_comptypes): Use incompatible_dependent_types_p.
651         * pt.c (get_template_info):
652         Handle BOUND_TEMPLATE_TEMPLATE_PARAM.
653
654 2010-01-20  Janis Johnson  <janis187@us.ibm.com>
655             Jason Merrill  <jason@redhat.com>
656
657         * mangle.c (write_type): Mangle transparent record as member type.
658         * semantics.c (begin_class_definition): Recognize decimal classes
659         and set TYPE_TRANSPARENT_AGGR.
660
661 2010-01-20  Jason Merrill  <jason@redhat.com>
662
663         PR c++/42338
664         * mangle.c (write_expression): Handle tree codes that have extra
665         arguments in the middle-end.
666
667 2010-01-20  Paolo Carlini  <paolo.carlini@oracle.com>
668
669         PR c++/42038
670         * except.c (expand_start_catch_block): Deal correctly with
671         do_begin_catch returning error_mark_node.
672
673 2010-01-20  Jason Merrill  <jason@redhat.com>
674
675         PR c++/41788
676         * class.c (layout_class_type): Set packed_maybe_necessary for packed
677         non-PODs.
678
679         PR c++/41920
680         * semantics.c (build_lambda_object): Call mark_used on captured
681         variables.
682
683         PR c++/40750
684         * decl.c (grokdeclarator): Clear type_quals for a member function
685         declared using a typedef.  Don't complain about adding cv-quals
686         to a function typedef in C++0x mode.
687
688 2010-01-20  Jakub Jelinek  <jakub@redhat.com>
689
690         * decl.c (create_array_type_for_decl): Remove set but not used
691         variable error_msg.  Remove break stmts after return stmts.
692
693 2010-01-19  Dodji Seketeli  <dodji@redhat.com>
694
695         * error.c (dump_template_parms, count_non_default_template_args):
696         Revert fix of PR c++/42634.
697
698 2010-01-18  Dodji Seketeli  <dodji@redhat.com>
699
700         PR c++/42634
701         * error.c (dump_template_parms): Use innermost template
702         arguments before calling count_non_default_template_args.
703         (count_non_default_template_args): We are being called with
704         template innermost arguments now. There is no need to ensure
705         that again.
706
707 2010-01-18  Dodji Seketeli  <dodji@redhat.com>
708
709         PR c++/42766
710         * cvt.c (build_expr_type_conversion): Look through OVERLOAD.
711
712 2010-01-17  Dodji Seketeli  <dodji@redhat.com>
713
714         PR c++/42697
715         *pt.c (tsubst_decl):  Revert commit for PR c++/42697.
716
717 2010-01-17  Dodji Seketeli  <dodji@redhat.com>
718
719         PR c++/42697
720         *pt.c (tsubst_decl): Get the arguments of a specialization from
721         the specialization template, not from the most general template.
722
723 2010-01-16  Jason Merrill  <jason@redhat.com>
724
725         PR c++/42761
726         * semantics.c (finish_decltype_type): Within a template, treat
727         unresolved CALL_EXPR as dependent.
728
729 2010-01-15  Dodji Seketeli  <dodji@redhat.com>
730
731         * error.c (dump_template_parms,count_non_default_template_args):
732         Revert changes of PR c++/42634.
733
734 2010-01-14  Jakub Jelinek  <jakub@redhat.com>
735
736         PR middle-end/42674
737         * decl.c (finish_function): Don't emit -Wreturn-type warnings in
738         functions with noreturn attribute.
739
740 2010-01-14  Jason Merrill  <jason@redhat.com>
741
742         PR c++/42701
743         * call.c (build_new_method_call): Don't free the vec here.
744
745         PR c++/42655
746         * call.c (convert_like_real): Do full decay_conversion for ck_rvalue.
747
748 2010-01-13  Dodji Seketeli  <dodji@redhat.com>
749
750         PR c++/42634
751         * error.c (dump_template_parms): Use innermost template
752         arguments before calling count_non_default_template_args.
753         (count_non_default_template_args): We are being called with
754         template innermost arguments now. There is no need to ensure
755         that again.
756
757 2010-01-07  Dodji Seketeli  <dodji@redhat.com>
758
759         c++/40155
760         * pt.c (unify_pack_expansion): In non-deduced contexts, re-use template
761         arguments that were previously deduced.
762
763 2010-01-05  Jason Merrill  <jason@redhat.com>
764
765         * pt.c (unify_pack_expansion): Handle deduction from init-list.
766         * call.c (build_over_call): Don't complain about it.
767
768 2010-01-04  Jason Merrill  <jason@redhat.com>
769
770         PR c++/42555
771         * pt.c (tsubst_decl): Don't apply type attributes in place.
772
773         PR c++/42567
774         * semantics.c (describable_type): Remove decltype comment and
775         semantics.
776
777
778 \f
779 Copyright (C) 2010 Free Software Foundation, Inc.
780
781 Copying and distribution of this file, with or without modification,
782 are permitted in any medium without royalty provided the copyright
783 notice and this notice are preserved.