1 2011-02-23 Nathan Froyd <froydnj@codesourcery.com>
4 * parser.c (cp_parser_class_specifier): Require a closing brace
5 to attempt error recovery.
7 2011-02-23 Jakub Jelinek <jakub@redhat.com>
10 * pt.c (struct pending_template): Add chain_next GTY option.
11 * decl.c (struct named_label_use_entry): Likewise.
13 2011-02-22 Paolo Carlini <paolo.carlini@oracle.com>
16 * semantics.c (build_lambda_object): Bail out if a field is
19 2011-02-22 Dodji Seketeli <dodji@redhat.com>
22 * class.c (dfs_declare_virt_assop_and_dtor)
23 (declare_virt_assop_and_dtor): New static functions.
24 (add_implicitly_declared_members): Use
25 declare_virt_assop_and_dtor.
27 2011-02-21 Jason Merrill <jason@redhat.com>
30 * decl2.c (decl_constant_var_p): A constexpr var needs an
31 initializer to be constant.
32 * semantics.c (cxx_eval_constant_expression): Complain about
33 constexpr var used in its own initializer.
34 * call.c (set_up_extended_ref_temp): Set
35 DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P too.
37 2011-02-20 Jason Merrill <jason@redhat.com>
40 * semantics.c (cxx_eval_call_expression): Call
41 cxx_eval_constant_expression in trivial shortcut.
44 * call.c (convert_class_to_reference): Don't try to set up a
45 second conv sequence for non-viable candidates.
48 * error.c (location_of): Handle non-tagged types.
51 * method.c (process_subob_fn): Instantiate constexpr templates.
52 * optimize.c (maybe_clone_body): Propagate DECL_DECLARED_CONSTEXPR_P.
54 2011-02-20 Dodji Seketeli <dodji@redhat.com>
57 * pt.c (tsubst_pack_expansion): do not use
58 cp_tree_equal/same_type_p to detect an expansion of a parameter
61 2011-02-19 Jason Merrill <jason@redhat.com>
64 * semantics.c (cxx_eval_call_expression): Shortcut trivial copy.
66 2011-02-18 Paolo Carlini <paolo.carlini@oracle.com>
69 * semantics.c (finish_non_static_data_member): Early return if
70 object is error_mark_node.
72 2011-02-18 Dodji Seketeli <dodji@redhat.com>
75 * pt.c (do_auto_deduction): Do not mention error_mark_node in
77 * semantics.c (finish_id_expression): Do not pass erroneous decl
78 to decl_constant_var_p.
80 2011-02-17 Jakub Jelinek <jakub@redhat.com>
83 * cvt.c (convert_from_reference): Call mark_exp_read.
85 2011-02-11 Dodji Seketeli <dodji@redhat.com>
88 * pt.c (finish_call_expr): Consider a call expression that has a
89 dependent "this" pointer as being dependent. Add comments.
90 (dependent_type_p, type_dependent_expression_p): Update comments.
92 2011-02-16 Dodji Seketeli <dodji@redhat.com>
95 * pt.c (tsubst_copy)<case SIZEOF_EXPR>: Ensure that even pack
96 expansion arguments are not evaluated.
98 2011-02-16 Jakub Jelinek <jakub@redhat.com>
101 * cp-tree.h (ENUM_FIXED_UNDERLYING_TYPE_P): Use TYPE_LANG_FLAG_5
102 instead of TYPE_LANG_FLAG_3.
103 * pt.c (lookup_template_class): Copy over
104 ENUM_FIXED_UNDERLYING_TYPE_P.
106 2011-02-15 Jason Merrill <jason@redhat.com>
109 * method.c (synthesized_method_walk): Always exit early for
110 trivial fn in C++98 mode.
112 2011-02-14 Jason Merrill <jason@redhat.com>
115 * parser.c (cp_parser_enumerator_definition): Call
116 fold_non_dependent_expr.
118 2011-02-09 Jason Merrill <jason@redhat.com>
120 * decl.c (cp_make_fname_decl): Set DECL_THIS_STATIC at toplevel.
121 * semantics.c (finish_fname): Only return the name if we're in
124 * decl.c (build_enumerator): Don't perform integral promotions on
125 non-integral constants.
127 * cvt.c (convert_to_void): Handle null op1.
129 * class.c (type_has_constexpr_default_constructor): Make sure the
130 caller stripped an enclosing array.
131 * init.c (perform_member_init): Strip arrays before calling it.
134 * semantics.c (potential_constant_expression_1): Handle TEMPLATE_DECL.
136 2011-02-03 Dodji Seketeli <dodji@redhat.com>
139 * tree.c (cp_tree_equal)<TEMPLATE_PARM_INDEX>: Take the number of
140 template parameters in account.
142 2011-02-03 Nathan Froyd <froydnj@codesourcery.com>
145 * parser.c (cp_parser_class_specifier): Fix setting of
148 2011-01-31 Jakub Jelinek <jakub@redhat.com>
151 * semantics.c (build_data_member_initialization): Handle
152 STATEMENT_LIST always instead of just for CLEANUP_BODY.
154 2011-01-31 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
156 * g++spec.c (lang_specific_driver) [HAVE_LD_STATIC_DYNAMIC] Use
157 LD_STATIC_OPTION, LD_DYNAMIC_OPTION.
159 2011-01-29 Dodji Seketeli <dodji@redhat.com>
162 * cp-tree.h (fixup_template_parms): Declare.
163 * pt.c (end_template_parm_list): Do not fixup template parms here.
164 (fixup_template_parms): Remove static. Fix typo in the
165 comments. Remove useless code statement.
166 (fixup_template_parm): For a template template parameter, fixup
167 its attributes before fixing up its type.
169 (cp_parser_template_declaration_after_export): After parsing
170 template parameters fixup their types.
172 2011-01-26 Jakub Jelinek <jakub@redhat.com>
175 * semantics.c (potential_constant_expression_1): Handle
178 2011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
181 * semantics.c (expand_or_defer_fn_1): Handle it.
182 * decl2.c (decl_needed_p): Likewise.
184 2011-01-21 Jason Merrill <jason@redhat.com>
187 * semantics.c (build_constexpr_constructor_member_initializers):
190 2011-01-21 Jakub Jelinek <jakub@redhat.com>
193 * semantics.c (begin_for_stmt): If -fno-for-scope, don't
194 assume init must be NULL if scope is NULL.
195 (begin_range_for_stmt): Likewise.
197 2011-01-21 Jason Merrill <jason@redhat.com>
200 * semantics.c (cxx_eval_constant_expression): Handle OFFSET_REF.
203 * semantics.c (potential_constant_expression_1): Split out from
204 potential_constant_expression. Add want_rval parm. Handle
205 template expression forms. Don't enforce restriction on address
206 of automatic variable here. Add a couple of diagnostics that
208 (require_potential_constant_expression): New entry point.
209 (build_data_member_initialization, register_constexpr_fundef): Adjust.
210 (maybe_constant_value): Check potential_constant_expression.
211 * pt.c (fold_non_dependent_expr_sfinae): Likewise.
212 * tree.c (build_vec_init_expr): Adjust.
214 2011-01-19 Jakub Jelinek <jakub@redhat.com>
217 * decl2.c (finish_anon_union): Only call mangle_decl if TREE_STATIC
220 2011-01-17 Jason Merrill <jason@redhat.com>
223 * semantics.c (base_field_constructor_elt): New fn.
224 (cxx_eval_bare_aggregate): Use it.
225 (build_data_member_initialization): Leave COMPONENT_REF for
228 2011-01-14 Rodrigo Rivas Costa <rodrigorivascosta@gmail.com>
230 * parser.c (cp_parser_range_for): Remove the "unused variable" warning
233 2011-01-15 Giovanni Funchal <gafunchal@gmail.com>
234 Jonathan Wakely <jwakely.gcc@gmail.com>
237 * decl.c (grokdeclarator): Reject mutable reference members.
239 2011-01-14 Jason Merrill <jason@redhat.com>
242 * pt.c (coerce_template_parms): Fix error recovery.
245 * typeck2.c (check_narrowing): Only check arithmetic types.
248 * tree.c (build_vec_init_expr): Handle flexible array
251 2011-01-13 Kai Tietz <kai.tietz@onevision.com>
254 * cp-tree.h (CLASSTYPE_VISIBILITY): Use
255 TYPE_MAIN_DECL instead of TYPE_NAME.
256 (CLASSTYPE_VISIBILITY_SPECIFIED): Likewise.
257 * decl2.c (determine_visibility): Add check
258 of CLASS_TYPE_P for underlying_type.
260 2011-01-12 Rodrigo Rivas Costa <rodrigorivascosta@gmail.com>
262 * cp-tree.h (begin_for_scope): New prototype.
263 (begin_for_stmt): Update prototype.
264 (begin_range_for_stmt): Update prototype.
265 * init.c (build_vec_init): Update call to begin_for_stmt.
266 * parser.c (cp_parser_for): New.
267 (cp_parser_c_for): Add three new parameters.
268 (cp_parser_range_for): Likewise. Most parsing code removed.
269 (cp_parser_iteration_statement): Call cp_parser_for instead of
270 cp_parser_c_for and cp_parser_range_for.
271 (cp_parser_for_init_statement): Add new parameter and return type.
272 (cp_parser_block_declaration): Update call to
273 cp_parser_simple_declaration.
274 (cp_parser_simple_declaration): Add new parameter.
275 Update call to cp_parser_init_declarator.
276 (cp_parser_init_declarator): Add new parameter.
277 * pt.c (tsubst_expr): Update call to begin_for_stmt.
278 * semantics.c (begin_for_scope): New.
279 (begin_for_stmt): Add two new parameters.
280 (begin_range_for_stmt): Likewise.
282 2011-01-12 Nicola Pero <nicola.pero@meta-innovation.com>
284 * parser.c (cp_parser_objc_at_property_declaration): Improved
287 2011-01-11 Dodji Seketeli <dodji@redhat.com>
290 * cp-lang.c (get_template_innermost_arguments_folded)
291 (get_template_argument_pack_elems_folded)
292 (template_arg_needs_folding, fold_cplus_constants): New static
294 (LANG_HOOKS_GET_INNERMOST_GENERIC_ARGS): Set this hook to
295 get_template_innermost_arguments_folded.
296 (LANG_HOOKS_GET_ARGUMENT_PACK_ELEMS): Set this hook to
297 get_template_argument_pack_elems_folded.
299 2011-01-11 Jason Merrill <jason@redhat.com>
302 * init.c (build_new_1): Handle value-init in templates differently.
305 * tree.c (maybe_dummy_object): Check current_class_ref against
306 context, not current_class_type.
308 2011-01-08 Nicola Pero <nicola.pero@meta-innovation.com>
311 * parser.c (cp_parser_objc_typename): If the type is unknown, for
312 error recovery purposes behave as if it was not specified so that
313 the default type is used.
315 2011-01-07 Jakub Jelinek <jakub@redhat.com>
318 * pt.c (tsubst_copy_and_build): Use tsubst instead of tsubst_copy
319 for the second build_x_va_arg argument.
321 2011-01-05 Tom Tromey <tromey@redhat.com>
323 * typeck.c (cp_build_addr_expr_1): Update call to lvalue_error.
324 (lvalue_or_else): Likewise.
326 2011-01-01 Kai Tietz <kai.tietz@onevision.com>
329 * tree.c (cxx_type_hash_eq):
330 Allow METHOD_TYPE, too.
333 Copyright (C) 2011 Free Software Foundation, Inc.
335 Copying and distribution of this file, with or without modification,
336 are permitted in any medium without royalty provided the copyright
337 notice and this notice are preserved.