OSDN Git Service

PR c++/39055
[pf3gnuchains/gcc-fork.git] / gcc / cp / ChangeLog
1 2012-02-14  Jason Merrill  <jason@redhat.com>
2
3         PR c++/39055
4         * decl.c (local_variable_p_walkfn): Don't check DECL_ARTIFICIAL.
5
6 2012-02-14  Jakub Jelinek  <jakub@redhat.com>
7
8         PR c/52181
9         * decl.c (duplicate_decls): If olddecl has bigger DECL_ALIGN than
10         newdecl, copy DECL_ALIGN to newdecl and or DECL_USER_ALIGN bits.
11
12 2012-02-07  Jason Merrill  <jason@redhat.com>
13
14         PR c++/51675
15         * semantics.c (cx_check_missing_mem_inits): Handle unions.
16         Fix constexpr default constructor logic.
17
18         PR c++/52035
19         * pt.c (tsubst): Strip uninstantiated typedef.
20
21 2012-02-06  Jason Merrill  <jason@redhat.com>
22
23         PR c++/52088
24         * cvt.c (build_expr_type_conversion): Check for template conversion.
25
26 2012-01-31  Jason Merrill  <jason@redhat.com>
27
28         PR c++/52043
29         * cp-tree.h (PACK_EXPANSION_LOCAL_P): New.
30         * pt.c (make_pack_expansion, tsubst_initializer_list): Set it.
31         (tsubst_pack_expansion): Check it.
32
33 2012-01-29  Paolo Carlini  <paolo.carlini@oracle.com>
34
35         PR c++/51327
36         * class.c (explain_non_literal_class): Correctly handle implicitly
37         deleted constructors.
38
39 2012-01-27  Jakub Jelinek  <jakub@redhat.com>
40
41         PR c++/51852
42         * pt.c (tsubst_pack_expansion): Delete and restore
43         local_specialization whenever need_local_specialization, not just
44         when saved_local_specializations is non-NULL.
45
46 2012-01-26  Paolo Carlini  <paolo.carlini@oracle.com>
47
48         PR c++/51370
49         * error.c (dump_decl, [TEMPLATE_ID_EXPR]): Handle error_mark_node
50         as TREE_OPERAND (t, 1).
51
52 2012-01-24  Jason Merrill  <jason@redhat.com>
53
54         PR c++/51917
55         * decl.c (xref_basetypes): Check VEC_length instead of VEC_space.
56
57         PR c++/51973
58         * tree.c (called_fns_equal): Check template args.
59         (cp_tree_equal): Call it.
60
61 2012-01-24  Aldy Hernandez  <aldyh@redhat.com>
62             Patrick Marlier  <patrick.marlier@gmail.com>
63
64         PR c++/51928
65         * class.c (set_method_tm_attributes): Use TARGET_THUNK instead of
66         thunk for set_one_vmethod_tm_attributes.
67
68 2012-01-24  Paolo Carlini  <paolo.carlini@oracle.com>
69
70         PR c++/51223
71         * call.c (build_over_call): Check for error_mark_node as
72         TREE_VALUE when default arguments are processed.
73
74 2012-01-23  Jason Merrill  <jason@redhat.com>
75
76         PR c++/51930
77         * decl2.c (determine_visibility): Check for visibility attribute
78         on template specialization.
79
80 2012-01-23  Paolo Carlini  <paolo.carlini@oracle.com>
81
82         PR c++/51398
83         * pt.c (parameter_of_template_p): Skip error_mark_node parameters.
84
85 2012-01-23  Jason Merrill  <jason@redhat.com>
86
87         PR c++/51925
88         * class.c (add_method): Set OVL_USED for using-decls.
89         * tree.c (ovl_scope): New.
90         * cp-tree.h: Declare it.
91         * parser.c (cp_parser_template_name): Use it.
92         * semantics.c (baselink_for_fns): Likewise.
93         * name-lookup.c (set_inherited_value_binding_p): Likewise.
94
95 2012-01-20  Paolo Carlini  <paolo.carlini@oracle.com>
96
97         PR c++/51402
98         * pt.c (lookup_template_class_1): Check context returned by
99         tsubst for error_mark_node.
100
101 2012-01-19  Kai Tietz  <ktietz@redhat.com>
102
103         PR c++/51344
104         * decl2.c (save_template_attributes): Use merge_attributes
105         instead of chaining up via TREE_CHAIN.
106
107 2012-01-19  Jason Merrill  <jason@redhat.com>
108
109         PR c++/51889
110         * class.c (finish_struct): Call add_method here for function usings.
111         * semantics.c (finish_member_declaration): Not here.
112
113 2012-01-18  Paolo Carlini  <paolo.carlini@oracle.com>
114
115         PR c++/51225
116         * typeck2.c (store_init_value): Within a template guard
117         cxx_constant_value with require_potential_constant_expression.
118         * pt.c (convert_nontype_argument): Likewise.
119
120 2012-01-16  Jakub Jelinek  <jakub@redhat.com>
121
122         PR c++/51854
123         * mangle.c (write_template_arg_literal): Handle complex.
124
125 2012-01-16  Jason Merrill  <jason@redhat.com>
126
127         PR c++/51827
128         * mangle.c (mangle_decl): Don't mangle uninstantiated templates.
129
130         PR c++/51868
131         * typeck.c (build_static_cast_1): Handle bit-fields properly.
132
133 2012-01-13  Ian Lance Taylor  <iant@google.com>
134
135         PR c++/50012
136         * typeck.c (enum_cast_to_int): New static function.
137         (cp_build_binary_op): When handling warn_sign_compare, don't test
138         for TREE_NO_WARNING.  Do call enum_cast_to_int.
139         * call.c (avoid_sign_compare_warnings): Remove static function.
140         (build_new_op_1): Don't call avoid_sign_compare_warnings.
141
142 2012-01-13  Steven Bosscher  <steven@gcc.gnu.org>
143
144         * decl2.c: Do not include tree-mudflap.h
145         * semantics.c: Likewise.
146
147 2012-01-13  Jason Merrill  <jason@redhat.com>
148
149         PR c++/20681
150         * semantics.c (finish_break_stmt): Avoid adding an unreachable
151         BREAK_STMT.
152
153         PR c++/51813
154         * decl2.c (constrain_visibility): Clear DECL_VISIBILITY_SPECIFIED
155         when reducing the visibility.
156
157         PR c++/51620
158         * class.c (build_vtbl_initializer): Use __cxa_deleted_virtual.
159
160 2012-01-12  Jason Merrill  <jason@redhat.com>
161
162         PR c++/51714
163         * pt.c (value_dependent_expression_p): Treat STMT_EXPR as
164         value-dependent.
165
166 2012-01-13  Dodji Seketeli  <dodji@redhat.com>
167
168         PR c++/51633
169         * semantics.c (cp_parser_ctor_initializer_opt_and_function_body):
170         Set the pointer to the last block of the constructor to the
171         current statement.
172         (build_constexpr_constructor_member_initializers): Get
173         build_data_member_initialization a chance to deal with more
174         statements before we choke.
175
176 2012-01-12  Jason Merrill  <jason@redhat.com>
177
178         PR c++/48051
179         * mangle.c (write_expression): Mangle BASELINK scope if
180         BASELINK_QUALIFIED_P.
181         * search.c (adjust_result_of_qualified_name_lookup): Set
182         BASELINK_QUALIFIED_P.
183         * tree.c (cp_tree_equal) [BASELINK]: Compare BASELINK_QUALIFIED_P.
184         * parser.c (cp_parser_postfix_dot_deref_expression): Don't call
185         adjust_result_of_qualified_name_lookup for non-qualified names.
186
187         PR c++/51403
188         * pt.c (unify): Handle error_mark_node.
189
190 2012-01-11  Jason Merrill  <jason@redhat.com>
191
192         PR c++/51565
193         * call.c (standard_conversion): For ptrmemfuncs, compare the
194         static_fn_types.
195
196         PR c++/51818
197         * mangle.c (find_substitution): A type is only a substitution
198         match if we're looking for a type.
199         (write_nested_name): Use decl_mangling_context.
200
201         * decl.c (decls_match): Assert that the arguments are decls.
202
203         PR c++/51613
204         * pt.c (resolve_overloaded_unification): Compare types with
205         same_type_p, not decls_match.
206
207 2012-01-10  Jason Merrill  <jason@redhat.com>
208
209         PR c++/51614
210         * class.c (build_base_path): Diagnose ambiguous base.
211
212         PR c++/51433
213         * semantics.c (cxx_eval_call_expression): Always retry previously
214         non-constant expressions.
215
216 2012-01-06  Jason Merrill  <jason@redhat.com>
217
218         DR 686
219         PR c++/47450
220         * parser.c (cp_parser_new_expression): Set
221         type_definition_forbidden_message.
222
223         PR c++/6057
224         PR c++/48051
225         PR c++/50855
226         PR c++/51322
227         * mangle.c (write_expression): Support NEW_EXPR, DELETE_EXPR,
228         THROW_EXPR, CONSTRUCTOR, OVERLOAD.  Fix PREINCREMENT_EXPR and
229         PREDECREMENT_EXPR.
230         (write_template_arg): Fix mangling of class-scope functions and
231         argument packs.
232         (mangle_decl): Update suggested -fabi-version argument.
233         * operators.def: Add DOTSTAR_EXPR, REINTERPRET_CAST_EXPR,
234         DYNAMIC_CAST_EXPR; correct CONST_CAST_EXPR, STATIC_CAST_EXPR.
235         * tree.c (dependent_name): No longer static.
236         * cp-tree.h: Declare it.
237         * pt.c (unify): Defer handling of unconverted functions.
238
239         * mangle.c (mangle_decl): Don't generate mangling aliases
240         for maybe-in-charge [cd]tors.
241
242         * error.c (dump_expr): Print type of CONSTRUCTOR.
243
244 2012-01-05  Dodji Seketeli  <dodji@redhat.com>
245
246         PR c++/51541
247         * parser.c (cp_parser_alias_declaration): Get out early upon
248         errors in the identifier or the attributes.
249
250 2012-01-04  Paolo Carlini  <paolo.carlini@oracle.com>
251
252         PR c++/51064
253         * pt.c (tsubst_copy_and_build): Maybe set TREE_NO_WARNING on
254         the tree returned by build_x_binary_op.
255
256 2012-01-03  Paolo Carlini  <paolo.carlini@oracle.com>
257
258         PR c++/51738
259         * parser.c (cp_parser_postfix_open_square_expression): Handle
260         postfix-expression [ braced-init-list ].
261
262 2012-01-03  Paolo Carlini  <paolo.carlini@oracle.com>
263
264         PR c++/29273
265         * rtti.c (build_dynamic_cast_1): In case of T a pointer type,
266         call decay_conversion on v.
267
268 2012-01-03  Paolo Carlini  <paolo.carlini@oracle.com>
269
270         PR c++/15867
271         * decl.c (duplicate_decls): With -Wredundant-decls don't warn for
272         declaration followed by specialization.
273
274 2012-01-03  Jakub Jelinek  <jakub@redhat.com>
275
276         PR c++/51669
277         * semantics.c (finish_omp_clauses): Call fold_build_cleanup_point_expr
278         on OMP_CLAUSE_{IF,FINAL,NUM_THREADS,SCHEDULE_CHUNK}_EXPR.
279
280 2012-01-02  Jason Merrill  <jason@redhat.com>
281
282         DR 1359
283         PR c++/51675
284         * method.c (walk_field_subobs): Don't check for uninitialized
285         fields in a union.
286         (synthesized_method_walk): Check here.
287
288         DR 325
289         PR c++/51666
290         * parser.c (cp_parser_cache_defarg): Split out...
291         (cp_parser_parameter_declaration): ...from here.
292         (cp_parser_save_nsdmi): Use it.
293         (cp_parser_cache_group): Remove CPP_COMMA support.
294
295 2012-01-02  Dodji Seketeli  <dodji@redhat.com>
296
297         PR c++/51462
298         * semantics.c (cx_check_missing_mem_inits): Don't assert in case
299         of error.
300
301 2012-01-02  Paolo Carlini  <paolo.carlini@oracle.com>
302
303         PR c++/20140
304         * typeck2.c (digest_init_r): Use copy_init when initializing
305         an array of chars.
306
307 2012-01-01  Paolo Carlini  <paolo.carlini@oracle.com>
308
309         PR c++/16603
310         * decl.c (build_enumerator): Don't call perform_integral_promotions
311         on the value.
312
313 2012-01-01  Paolo Carlini  <paolo.carlini@oracle.com>
314
315         PR c++/51379
316         * typeck.c (build_reinterpret_cast_1): Implement resolution of
317         DR 799.
318
319 2012-01-01  Fabien ChĂȘne  <fabien@gcc.gnu.org>
320
321         * parser.c (cp_parser_using_declaration): Add a warning about
322         deprecated access declarations when no errors were encountered
323         while parsing the access declaration. Save the first token in
324         order to emit the warning at the right place.
325 \f
326 Copyright (C) 2012 Free Software Foundation, Inc.
327
328 Copying and distribution of this file, with or without modification,
329 are permitted in any medium without royalty provided the copyright
330 notice and this notice are preserved.