re PR c++/69267 ([cilkplus] ICE when calling a function with an empty class as an...
[platform/upstream/gcc.git] / gcc / cp / ChangeLog
1 2016-01-27  Ryan Burn  <contact@rnburn.com>
2
3         PR cilkplus/69267
4         * cp-gimplify.c (cilk_cp_gimplify_call_params_in_spawned_fn): Removed
5         superfluous post_p argument in call to
6         cilk_gimplify_call_params_in_spawned_fn.
7
8 2016-01-27  Marek Polacek  <polacek@redhat.com>
9
10         PR c++/69379
11         * constexpr.c (cxx_eval_constant_expression): Handle PTRMEM_CSTs
12         wrapped in NOP_EXPRs.
13
14 2016-01-27  Martin Sebor  <msebor@redhat.com>
15
16         PR c++/69317
17         * mangle.c (mangle_decl): Reference the correct (saved) version
18         of the ABI in -Wabi diagnostics.
19
20 2016-01-27  Marek Polacek  <polacek@redhat.com>
21
22         PR c++/69496
23         * constexpr.c (cxx_eval_array_reference): Evaluate the number of
24         elements of the array.
25
26 2016-01-26  Jason Merrill  <jason@redhat.com>
27
28         PR c++/68949
29         * constexpr.c (register_constexpr_fundef): Keep the un-massaged body.
30         (cxx_eval_call_expression): Don't look through clones.
31         * optimize.c (maybe_clone_body): Clear DECL_SAVED_TREE of the alias.
32         * semantics.c (expand_or_defer_fn_1): Keep DECL_SAVED_TREE of
33         maybe-in-charge *tor.
34
35 2016-01-26  Jason Merrill  <jason@redhat.com>
36
37         PR c++/68782
38         * constexpr.c (cxx_eval_bare_aggregate): Update TREE_CONSTANT
39         and TREE_SIDE_EFFECTS.
40         (cxx_eval_constant_expression) [CONSTRUCTOR]: Call
41         verify_constructor_flags.
42
43 2016-01-26  Jakub Jelinek  <jakub@redhat.com>
44
45         PR c++/68357
46         * cp-gimplify.c (cp_fold): If some operand folds to error_mark_node,
47         return error_mark_node instead of building trees with error_mark_node
48         operands.
49
50 2016-01-26  David Malcolm  <dmalcolm@redhat.com>
51
52         PR other/69006
53         * error.c (print_instantiation_partial_context_line): Add missing
54         newlines from output for the t == NULL case.
55         (print_instantiation_partial_context): Remove call to pp_newline.
56
57 2016-01-24  Patrick Palka  <ppalka@gcc.gnu.org>
58
59         Revert:
60         2016-01-18  Patrick Palka  <ppalka@gcc.gnu.org>
61
62         PR c++/11858
63         PR c++/24663
64         PR c++/24664
65         * decl.c (grokdeclarator): Don't decay array parameter type to
66         a pointer type if it's dependent.
67         (grokparms): Invoke strip_top_quals instead of directly invoking
68         cp_build_qualified_type.
69         * pt.c (decay_dependent_array_parm_type): New static function.
70         (type_unification_real): Call decay_dependent_array_parm_type
71         to decay a dependent array parameter type to its corresponding
72         pointer type before unification.
73         (more_specialized_fn): Likewise.
74         (get_bindings): Likewise.
75         * tree.c (cp_build_qualified_type): Trivial typofix in
76         documentation.
77
78 2016-01-23  Martin Sebor  <msebor@redhat.com>
79
80         PR c++/58109
81         PR c++/69022
82         * decl2.c (is_late_template_attribute): Handle dependent argument
83         to attribute align and attribute vector_size.
84
85 2016-01-21  Jason Merrill  <jason@redhat.com>
86
87         PR c++/69392
88         * lambda.c (lambda_capture_field_type): Handle 'this' specially
89         for init-capture, too.
90
91         PR c++/65687
92         * decl.c (type_is_deprecated): Don't look into a typedef.
93
94         PR c++/40751
95         PR c++/64987
96         * decl.c (copy_type_enum): Respect TYPE_USER_ALIGN.
97
98         PR c++/43407
99         * decl.c (start_enum): Add attributes parameter.
100         * parser.c (cp_parser_enum_specifier): Pass it.
101         * pt.c (lookup_template_class_1): Pass it.
102         * cp-tree.h: Adjust.
103
104 2016-01-19  Jason Merrill  <jason@redhat.com>
105
106         PR c++/59759
107         * pt.c (convert_template_argument): Handle VAR_DECL properly.
108
109 2016-01-19  Marek Polacek  <polacek@redhat.com>
110
111         PR c++/68586
112         * constexpr.c (clear_cv_cache): New.
113         * cp-gimplify.c (clear_fold_cache): New.
114         * cp-tree.h (clear_cv_cache, clear_fold_cache): Declare.
115         * decl.c (finish_enum_value_list): Call them.
116
117         PR c++/68965
118         * pt.c (tsubst_copy): Mark elements in expanded vector as used.
119
120 2016-01-18  Patrick Palka  <ppalka@gcc.gnu.org>
121
122         PR c++/11858
123         PR c++/24663
124         PR c++/24664
125         * decl.c (grokdeclarator): Don't decay array parameter type to
126         a pointer type if it's dependent.
127         (grokparms): Invoke strip_top_quals instead of directly invoking
128         cp_build_qualified_type.
129         * pt.c (decay_dependent_array_parm_type): New static function.
130         (type_unification_real): Call decay_dependent_array_parm_type
131         to decay a dependent array parameter type to its corresponding
132         pointer type before unification.
133         (more_specialized_fn): Likewise.
134         (get_bindings): Likewise.
135         * tree.c (cp_build_qualified_type): Trivial typofix in
136         documentation.
137
138 2016-01-18  Jason Merrill  <jason@redhat.com>
139
140         * cp-gimplify.c (cp_fold) [CONSTRUCTOR]: Don't clobber the input.
141
142         * cp-gimplify.c (cp_fold): Remove unnecessary special cases.
143
144         PR c++/68767
145         * cp-gimplify.c (cp_fold) [COND_EXPR]: Simplify.  Do fold COND_EXPR.
146         (contains_label_1, contains_label_p): Remove.
147
148 2016-01-16  Patrick Palka  <ppalka@gcc.gnu.org>
149
150         PR c++/69091
151         * pt.c (type_dependent_expression_p): For a function template
152         specialization, a type is dependent iff any of its template
153         arguments are.
154
155 2016-01-16  Patrick Palka  <ppalka@gcc.gnu.org>
156
157         * cp-array-notation.c (cp_expand_cond_array_notations): Return
158         error_mark_node only if find_rank failed, not if it was
159         successful.
160
161 2016-01-16  Patrick Palka  <ppalka@gcc.gnu.org>
162
163         PR c++/68936
164         * tree.c (build_min_non_dep_call_vec): Don't retain the
165         KOENIG_LOOKUP_P flag of the non-dependent expression that's
166         been built.
167         (build_min_non_dep_op_overload): Instead, do it here.
168
169 2016-01-15  Jakub Jelinek  <jakub@redhat.com>
170
171         PR bootstrap/68271
172         * parser.h (cp_token): Remove pragma_kind field.  Add comment
173         with number of unused bits.
174         * parser.c (eof_token): Remove pragma_kind field initializer.
175         (cp_lexer_get_preprocessor_token): Don't set pragma_kind
176         field, don't clear CPP_PRAGMA u.value.
177         (cp_parser_pragma_kind): New function.
178         (cp_parser_omp_sections_scope, cp_parser_oacc_kernels_parallel,
179         cp_parser_omp_construct, cp_parser_initial_pragma,
180         cp_parser_pragma): Use cp_parser_pragma_kind instead of accessing
181         pragma_kind field.
182
183 2016-01-15  Jason Merrill  <jason@redhat.com>
184
185         PR c++/68847
186         * call.c (build_cxx_call): Use fold_non_dependent_expr.
187
188         * typeck2.c (cxx_incomplete_type_diagnostic): Use the location of
189         value.
190
191         PR c++/69257
192         * typeck.c (decay_conversion): Don't call mark_rvalue_use for
193         array/function-to-pointer conversion.  Call
194         complete_type_or_maybe_complain for lvalue-to-rvalue conversion.
195         * call.c (convert_like_real): Print call context if
196         decay_conversion errors.
197
198 2016-01-14  Tom de Vries  <tom@codesourcery.com>
199
200         PR tree-optimization/68773
201         * parser.c (cp_parser_oacc_declare, cp_parser_omp_declare_target): Don't
202         set force_output.
203
204 2016-01-14  Jason Merrill  <jason@redhat.com>
205
206         PR c++/69261
207         * constexpr.c (find_array_ctor_elt): Handle splitting RANGE_EXPR.
208
209 2016-01-12  Marek Polacek  <polacek@redhat.com>
210
211         PR c++/68979
212         * constexpr.c (cxx_eval_check_shift_p): Use permerror rather than
213         error_at and adjust the return value.
214
215 2016-01-12  Jakub Jelinek  <jakub@redhat.com>
216
217         PR objc++/68511
218         PR c++/69213
219         * cp-gimplify.c (cp_gimplify_expr) <case INIT_EXPR>: Don't return
220         GS_ERROR whenever seen_error (), only if *expr_p contains
221         cilk spawn stmt, but cilk_detect_spawn_and_unwrap failed.
222
223         PR c++/66808
224         PR c++/69000
225         * pt.c (tsubst_decl): If not local_p, clear DECL_TEMPLATE_INFO.
226
227 2016-01-11  Jason Merrill  <jason@redhat.com>
228
229         PR c++/69131
230         * method.c (walk_field_subobs): Add dtor_from_ctor parm.
231         (process_subob_fn): Likewise.  Don't consider triviality if true.
232         (synthesize_method_walk): Pass it.
233
234 2016-01-11  David Malcolm  <dmalcolm@redhat.com>
235
236         PR c++/68795
237         * parser.c (cp_parser_postfix_expression): Initialize
238         close_paren_loc to UNKNOWN_LOCATION; only use it if
239         it has been written to by
240         cp_parser_parenthesized_expression_list.
241         (cp_parser_parenthesized_expression_list): Document the behavior
242         with respect to the CLOSE_PAREN_LOC param.
243
244 2016-01-11  Jakub Jelinek  <jakub@redhat.com>
245
246         PR c++/69211
247         * cp-gimplify.c (cp_fold): If COMPOUND_EXPR or MODIFY_EXPR
248         folded operands have side-effects, but folding changed any of them,
249         build a new tree with the folded operands instead of returning the
250         unfolded tree.
251
252 2016-01-09  Marek Polacek  <polacek@redhat.com>
253
254         PR c++/69113
255         * decl2.c (comdat_linkage): Only set DECL_COMDAT if TREE_PUBLIC is set.
256
257 2016-01-09  Jakub Jelinek  <jakub@redhat.com>
258
259         PR c++/69164
260         * class.c (layout_class_type): Use copy_node to copy FIELD_DECLs.
261
262 2016-01-08  Jason Merrill  <jason@redhat.com>
263
264         PR c++/69158
265         * constexpr.c (cxx_fold_indirect_ref): Handle array type differing
266         in completion.
267
268 2016-01-08  Marek Polacek  <polacek@redhat.com>
269
270         PR c++/68449
271         * constexpr.c (cxx_eval_constant_expression): Handle NULL initializer.
272
273 2016-01-08  Jason Merrill  <jason@redhat.com>
274
275         * constexpr.c (cxx_eval_call_expression): Remove convert_to_void
276         workaround.
277
278         PR c++/68983
279         PR c++/67557
280         * cvt.c (convert_to_void): Don't strip a TARGET_EXPR of
281         TREE_ADDRESSABLE type.
282
283         PR c++/68983
284         PR c++/67557
285         * call.c (unsafe_copy_elision_p): Look through COMPOUND_EXPR.
286
287 2016-01-05  Nathan Sidwell  <nathan@acm.org>
288
289         PR c++/58583
290         * pt.c (build_non_dependent_expr): Don't try a checking fold when
291         parsing an nsdmi.
292
293 2016-01-04  Jakub Jelinek  <jakub@redhat.com>
294
295         Update copyright years.
296 \f
297 Copyright (C) 2016 Free Software Foundation, Inc.
298
299 Copying and distribution of this file, with or without modification,
300 are permitted in any medium without royalty provided the copyright
301 notice and this notice are preserved.