+2023-12-05 Richard Sandiford <richard.sandiford@arm.com>
+
+ * c-decl.cc (std_attribute_table): Add extra braces to work
+ around PR 16333 in older compilers.
+
+2023-12-05 Richard Biener <rguenther@suse.de>
+
+ PR c/86869
+ * c-typeck.cc (c_build_qualified_type): Preserve address-space
+ info for ARRAY_TYPE.
+
+2023-12-02 Richard Sandiford <richard.sandiford@arm.com>
+
+ * c-tree.h (std_attribute_table): Declare.
+ * c-decl.cc (std_attribute_table): Change type to
+ scoped_attribute_specs, using...
+ (std_attributes): ...this as the underlying array.
+ (c_init_decl_processing): Remove call to register_scoped_attributes.
+ * c-objc-common.h (c_objc_attribute_table): New global.
+ (LANG_HOOKS_ATTRIBUTE_TABLE): Use it.
+ (LANG_HOOKS_COMMON_ATTRIBUTE_TABLE): Delete.
+ (LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE): Delete.
+
+2023-12-01 Florian Weimer <fweimer@redhat.com>
+
+ PR other/44209
+ * c-decl.cc (grokparms): Issue permerror for
+ OPT_Wdeclaration_missing_parameter_type instead of a pedwarn.
+
+2023-12-01 Florian Weimer <fweimer@redhat.com>
+
+ PR c/96284
+ * c-typeck.cc (build_conditional_expr): Upgrade most pointer
+ type mismatches to a permerror.
+ (convert_for_assignment): Use permerror_opt and
+ permerror_init for OPT_Wincompatible_pointer_types warnings.
+
+2023-12-01 Florian Weimer <fweimer@redhat.com>
+
+ PR c/96284
+ * c-typeck.cc (c_finish_return): Use permerrors
+ for OPT_Wreturn_mismatch diagnostics.
+
+2023-12-01 Florian Weimer <fweimer@redhat.com>
+
+ * c-decl.cc (grokdeclarator): Do not skip -Wimplicit-int
+ warnings or errors in system headers.
+
+2023-12-01 Florian Weimer <fweimer@redhat.com>
+
+ * c-decl.cc (warn_defaults_to): Remove.
+ (grok_declarator, start_function): Call permerror_opt
+ instead of warn_defaults_to.
+ (store_parm_decls_oldstyle): Call permerror_opt for
+ OPT_Wimplicit_int.
+
+2023-12-01 Florian Weimer <fweimer@redhat.com>
+
+ PR c/91092
+ PR c/96284
+ * c-decl.cc (implicit_decl_permerror): Rename from
+ implicit_decl_warning. Call permerror_opt instead of
+ pedwarn and warning_at.
+ (implicitly_declare): Adjust callers.
+
+2023-12-01 Florian Weimer <fweimer@redhat.com>
+
+ PR c/96284
+ PR c/106416
+ * c-typeck.cc (build_conditional_expr): Use permerror_opt for
+ pointer/integer type mismatches, based on -Wint-conversion.
+ (pedwarn_permerror_init, permerror_init): New function.
+ (pedwarn_init): Call pedwarn_permerror_init.
+ (convert_for_assignment): Use permerror_opt and
+ permerror_init for -Wint-conversion warnings.
+
+2023-11-29 Alexandre Oliva <oliva@adacore.com>
+
+ * c-typeck.cc (convert_lvalue_to_rvalue): Decay hardbools.
+ * c-convert.cc (convert): Convert to hardbool through
+ truthvalue.
+ * c-decl.cc (check_bitfield_type_and_width): Skip enumeral
+ truncation warnings for hardbool.
+ (finish_struct): Propagate hardbool attribute to bitfield
+ types.
+ (digest_init): Convert to hardbool.
+
+2023-11-28 Jason Merrill <jason@redhat.com>
+
+ PR c++/94264
+ PR c++/53220
+ * c-typeck.cc (array_to_pointer_conversion): Adjust -Wc++-compat
+ diagnostic.
+
+2023-11-28 Richard Biener <rguenther@suse.de>
+
+ PR middle-end/112741
+ * gimple-parser.cc (c_parser_parse_gimple_body): Also
+ set DECL_SEEN_IN_BIND_EXPR_Pfor locals.
+
+2023-11-27 Alex Coplan <alex.coplan@arm.com>
+ Iain Sandoe <iain@sandoe.co.uk>
+
+ PR c++/60512
+ * c-lang.cc (c_family_register_lang_features): New.
+ * c-objc-common.cc (struct c_feature_info): New.
+ (c_register_features): New.
+ * c-objc-common.h (c_register_features): New.
+
+2023-11-24 Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_clause_num_threads,
+ c_parser_omp_clause_num_tasks, c_parser_omp_clause_grainsize,
+ c_parser_omp_clause_priority, c_parser_omp_clause_schedule,
+ c_parser_omp_clause_num_teams, c_parser_omp_clause_thread_limit,
+ c_parser_omp_clause_dist_schedule, c_parser_omp_depobj,
+ c_parser_omp_scan_loop_body, c_parser_omp_assumption_clauses):
+ Add OPT_Wopenmp to warning_at.
+
+2023-11-24 Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_depobj): Accept optionally an argument
+ to the destroy clause.
+
+2023-11-23 Jakub Jelinek <jakub@redhat.com>
+
+ * c-parser.cc (c_parser_postfix_expression): Handle RID_BUILTIN_STDC.
+ * c-decl.cc (names_builtin_p): Likewise.
+
+2023-11-14 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/111309
+ * c-typeck.cc (convert_arguments): Don't promote first argument
+ of BUILT_IN_{CLZ,CTZ,CLRSB,FFS,PARITY,POPCOUNT}G.
+
+2023-11-10 Martin Uecker <uecker@tugraz.at>
+
+ * c-typeck.cc (struct comptypes_data): Add anon_field flag.
+ (comptypes, comptypes_check_unum_int,
+ comptypes_check_different_types): Remove old cache.
+ (tagged_tu_types_compatible_p): Rewrite.
+
+2023-11-09 Florian Weimer <fweimer@redhat.com>
+
+ * c-typeck.cc (c_finish_return): Use pedwarn with
+ OPT_Wreturn_mismatch for missing/extra return expressions.
+
+2023-11-07 Kwok Cheung Yeung <kcy@codesourcery.com>
+
+ * c-decl.cc (c_decl_attributes): Add attribute for indirect
+ functions.
+ * c-lang.h (c_omp_declare_target_attr): Add indirect field.
+ * c-parser.cc (c_parser_omp_clause_name): Handle indirect clause.
+ (c_parser_omp_clause_indirect): New.
+ (c_parser_omp_all_clauses): Handle indirect clause.
+ (OMP_DECLARE_TARGET_CLAUSE_MASK): Add indirect clause to mask.
+ (c_parser_omp_declare_target): Handle indirect clause. Emit error
+ message if device_type or indirect clauses used alone. Emit error
+ if indirect clause used with device_type that is not 'any'.
+ (OMP_BEGIN_DECLARE_TARGET_CLAUSE_MASK): Add indirect clause to mask.
+ (c_parser_omp_begin): Handle indirect clause.
+ * c-typeck.cc (c_finish_omp_clauses): Handle indirect clause.
+
+2023-11-07 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc: Use flag_isoc23 instead of flag_isoc2x and c23_auto_p
+ instead of c2x_auto_p. Refer to C23 instead of C2X in diagnostics
+ and comments.
+ * c-errors.cc: Use flag_isoc23 instead of flag_isoc2x and
+ warn_c11_c23_compat instead of warn_c11_c2x_compat. Refer to C23
+ instead of C2X in comments.
+ * c-parser.cc: Use flag_isoc23 instead of flag_isoc2x,
+ warn_c11_c23_compat instead of warn_c11_c2x_compat, c23_auto_p
+ instead of c2x_auto_p and D_C23 instead of D_C2X. Refer to C23
+ instead of C2X in diagnostics and comments.
+ * c-tree.h: Refer to C23 instead of C2X in comments.
+ (struct c_declspecs): Rename c2x_auto_p to c23_auto_p.
+ * c-typeck.cc: Use flag_isoc23 instead of flag_isoc2x and
+ warn_c11_c23_compat instead of warn_c11_c2x_compat. Refer to C23
+ instead of C2X in diagnostics and comments.
+
+2023-11-06 Joseph Myers <joseph@codesourcery.com>
+
+ PR c/107954
+ * c-errors.cc (pedwarn_c11): Use OPT_Wc11_c23_compat instead of
+ OPT_Wc11_c2x_compat.
+ * c-typeck.cc (build_conditional_expr, convert_for_assignment):
+ Use OPT_Wc11_c23_compat instead of OPT_Wc11_c2x_compat.
+
+2023-11-04 Jakub Jelinek <jakub@redhat.com>
+
+ * c-parser.h (c_maybe_parse_omp_decl): Declare.
+ * c-parser.cc (struct c_parser): Add in_omp_decl_attribute member.
+ (c_parser_std_attribute): Uncoment omp::decl handling.
+ (c_parser_omp_var_list_parens): If parser->in_omp_decl_attribute
+ don't expect any arguments, instead create clause or TREE_LIST for
+ that decl.
+ (c_maybe_parse_omp_decl): New function.
+ (c_parser_omp_declare_target): If parser->in_omp_decl_attribute and
+ first token isn't name or comma invoke c_parser_omp_var_list_parens.
+ * c-decl.cc (c_decl_attributes): Uncomment omp::decl handling and
+ use *node rather than non-existing *decl.
+
+2023-11-04 Jakub Jelinek <jakub@redhat.com>
+
+ * c-tree.def: New file.
+ * c-tree.h (struct c_tree_token_vec): Forward declare.
+ (c_tree_size): Declare.
+ * c-lang.h (struct c_omp_declare_target_attr): Add attr_syntax member.
+ (struct c_omp_begin_assumes_data): New type.
+ (current_omp_begin_assumes): Change type from int to
+ vec<c_omp_begin_assumes_data, va_gc> *.
+ * c-lang.cc: Include c-family/c-pragma.h and c-parser.h.
+ * c-parser.h (struct c_tree_token_vec_struct): New type.
+ (C_TOKEN_VEC_TOKENS): New macro.
+ * c-parser.cc (struct c_parser): Add omp_attrs_forbidden_p and
+ in_omp_attribute_pragma members.
+ (c_parser_skip_until_found): Handle CPP_PRAGMA_EOL when
+ parser->in_omp_attribute_pragma.
+ (c_parser_skip_to_pragma_eol): Likewise.
+ (c_parser_translation_unit): Adjust for current_omp_begin_assumes
+ being a vector rather than counter.
+ (c_parser_declaration_or_fndef): Handle omp::directive and
+ omp::sequence attributes on attribute declaration and declare simd
+ or declare variant directives in those on function declarations.
+ (c_parser_check_balanced_raw_token_sequence): Forward declare.
+ (c_parser_omp_directive_args, c_parser_omp_sequence_args): New
+ functions.
+ (c_parser_std_attribute): Handle omp::directive and omp::sequence
+ attributes.
+ (struct c_omp_attribute_data): New type.
+ (c_parser_handle_statement_omp_attributes,
+ c_parser_handle_directive_omp_attributes): New functions.
+ (c_parser_compound_statement_nostart): Handle omp::directive and
+ omp::sequence attributes on statements. Formatting fix.
+ (c_parser_all_labels): Handle omp::directive and omp::sequence
+ attributes on statements.
+ (c_parser_statement): Clear parser->omp_attrs_forbidden_p.
+ (c_parser_omp_variable_list): Handle parser->tokens
+ != &parser->tokens_buf[0] by saving/restoring it.
+ (c_parser_omp_structured_block): Set parser->omp_attrs_forbidden_p.
+ (c_parser_omp_section_scan): New function.
+ (c_parser_omp_structured_block_sequence, c_parser_omp_sections_scope):
+ Use it.
+ (c_parser_omp_parallel): Set parser->omp_attrs_forbidden_p.
+ (c_parser_omp_task): Likewise.
+ (c_parser_omp_declare_simd): Handle function declaration after
+ std attributes.
+ (c_finish_omp_declare_simd): Don't assert all kinds are the same.
+ (c_parser_omp_declare_target): Also push attr_syntax flag.
+ (c_parser_omp_begin): Likewise. Adjust for current_omp_begin_assumes
+ type change.
+ (c_parser_omp_end): Adjust for current_omp_begin_assumes type
+ change. Diagnose mixing of attribute vs. pragma syntax on end assumes
+ or end declare target.
+ (c_parser_omp_declare_reduction): Handle parser->tokens
+ != &parser->tokens_buf[0] by saving/restoring it.
+ * c-decl.cc: Include c-parser.h.
+ (current_omp_begin_assumes): Change type from int to
+ vec<c_omp_begin_assumes_data, va_gc> *.
+ (struct c_tree_token_vec): New type. Add static assertions
+ for sizeof and offsetof.
+ (union lang_tree_node): Add c_token_vec member and adjust GTY
+ desc for it.
+ (c_tree_size): New function.
+ (c_decl_attributes): Diagnose invalid omp::directive attribute
+ uses.
+ * c-objc-common.h (LANG_HOOKS_TREE_SIZE): Redefine.
+
+2023-11-02 Martin Uecker <uecker@tugraz.at>
+
+ PR c/112347
+ * c-typeck.cc (convert_for_assignment): Add missing check.
+
+2023-11-01 Martin Uecker <uecker@tugraz.at>
+
+ PR c/71219
+ * c-typeck.cc (convert_for_assignment): Add warning.
+
+2023-10-26 liuhongt <hongtao.liu@intel.com>
+
+ * c-typeck.cc (build_vec_cmp): Pass type of arg0 to
+ truth_type_for.
+
+2023-10-25 Thomas Schwinge <thomas@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_clause_name): Return
+ 'PRAGMA_OACC_CLAUSE_SELF' for "self".
+ (c_parser_oacc_data_clause, OACC_UPDATE_CLAUSE_MASK): Adjust.
+ (c_parser_oacc_all_clauses): Remove 'bool compute_p' formal
+ parameter, and instead locally determine whether we're called for
+ an OpenACC compute construct or OpenACC 'update' directive.
+ (c_parser_oacc_compute): Adjust.
+
+2023-10-25 Chung-Lin Tang <cltang@codesourcery.com>
+
+ * c-parser.cc (c_parser_oacc_compute_clause_self): New function.
+ (c_parser_oacc_all_clauses): Add new 'bool compute_p = false'
+ parameter, add parsing of self clause when compute_p is true.
+ (OACC_KERNELS_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_SELF.
+ (OACC_PARALLEL_CLAUSE_MASK): Likewise,
+ (OACC_SERIAL_CLAUSE_MASK): Likewise.
+ (c_parser_oacc_compute): Adjust call to c_parser_oacc_all_clauses to
+ set compute_p argument to true.
+ * c-typeck.cc (c_finish_omp_clauses): Add OMP_CLAUSE_SELF case.
+
+2023-10-20 Florian Weimer <fweimer@redhat.com>
+
+ PR c/109827
+ PR other/44209
+ * c-typeck.cc (build_conditional_expr): Use OPT_Wint_conversion
+ for pointer/integer mismatch warnings.
+
+2023-10-20 Florian Weimer <fweimer@redhat.com>
+
+ PR c/109826
+ PR other/44209
+ * c-typeck.cc (build_conditional_expr): Use
+ OPT_Wincompatible_pointer_types for pointer mismatches.
+ Emit location information for the operand.
+
+2023-10-19 Andrew Pinski <pinskia@gmail.com>
+
+ PR c/100532
+ * c-typeck.cc (convert_argument): After erroring out
+ about an incomplete type return error_mark_node.
+
+2023-10-19 Andrew Pinski <pinskia@gmail.com>
+
+ PR c/104822
+ * c-typeck.cc (convert_for_assignment): Check for null pointer
+ before warning about an incompatible scalar storage order.
+
+2023-10-18 Andrew Pinski <pinskia@gmail.com>
+
+ PR c/101364
+ * c-decl.cc (diagnose_arglist_conflict): Test for
+ error mark before calling of c_type_promotes_to.
+
+2023-10-18 Andrew Pinski <pinskia@gmail.com>
+
+ PR c/101285
+ * c-typeck.cc (c_safe_arg_type_equiv_p): Return true for error
+ operands early.
+
+2023-10-17 Martin Uecker <uecker@tugraz.at>
+
+ PR c/111708
+ * c-decl.cc (grokdeclarator): Add error.
+
+2023-10-03 David Malcolm <dmalcolm@redhat.com>
+
+ * c-objc-common.cc (c_tree_printer): Update for "m_" prefixes to
+ text_info fields.
+
+2023-09-30 Eugene Rozenfeld <erozen@microsoft.com>
+
+ * Make-lang.in: Make create_fdas_for_cc1 target not .PHONY
+
+2023-09-20 Jakub Jelinek <jakub@redhat.com>
+
+ * c-parser.cc (c_parser_postfix_expression_after_primary): Parse
+ __builtin_classify_type call with typename as argument.
+
+2023-09-19 Richard Biener <rguenther@suse.de>
+
+ PR c/111468
+ * gimple-parser.cc (c_parser_gimple_binary_expression): Handle __LTGT.
+
+2023-09-19 Richard Biener <rguenther@suse.de>
+
+ PR c/111468
+ * gimple-parser.cc (c_parser_gimple_binary_expression): Add
+ return type argument.
+ (c_parser_gimple_statement): Adjust.
+ (c_parser_gimple_paren_condition): Likewise.
+ (c_parser_gimple_binary_expression): Use passed in return type,
+ add support for - as POINTER_DIFF_EXPR, __UN{LT,LE,GT,GE,EQ},
+ __UNORDERED and __ORDERED.
+
+2023-09-12 Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (struct c_omp_loc_tree): New.
+ (c_check_omp_allocate_allocator_r): New; checking moved from ...
+ (c_parser_omp_allocate): ... here. Call it via walk_tree. Avoid
+ ICE with tree_to_shwi for invalid too-large value.
+
+2023-09-12 Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_construct): Move call to
+ c_parser_omp_allocate to ...
+ (c_parser_pragma): ... here.
+ (c_parser_omp_allocate): Avoid ICE is allocator could not be
+ parsed; set 'omp allocate' attribute for stack/automatic variables
+ and only reject static variables; add several additional
+ restriction checks.
+ * c-tree.h (c_mark_decl_jump_unsafe_in_current_scope): New prototype.
+ * c-decl.cc (decl_jump_unsafe): Return true for omp-allocated decls.
+ (c_mark_decl_jump_unsafe_in_current_scope): New.
+ (warn_about_goto, c_check_switch_jump_warnings): Add error for
+ omp-allocated decls.
+
+2023-09-12 Martin Uecker <uecker@tugraz.at>
+
+ * c-typeck.cc (struct comptypes_data): Add structure.
+ (tagged_types_tu_compatible_p,
+ function_types_compatible_p, type_lists_compatible_p,
+ comptypes_internal): Add structure to interface, change
+ return type to bool, and adapt calls.
+ (comptarget_types): Change return type too bool.
+ (comptypes, comptypes_check_enum_int,
+ comptypes_check_different_types): Adapt calls.
+
+2023-09-06 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/102989
+ * c-decl.cc (finish_declspecs): Emit pedwarn_c11 on _BitInt.
+ * c-typeck.cc (c_common_type): Emit sorry for common type between
+ _Complex integer and larger _BitInt and return the _Complex integer.
+
+2023-09-06 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/102989
+ * c-convert.cc (c_convert): Handle BITINT_TYPE like INTEGER_TYPE.
+ * c-decl.cc (check_bitfield_type_and_width): Allow BITINT_TYPE
+ bit-fields.
+ (finish_struct): Prefer to use BITINT_TYPE for BITINT_TYPE bit-fields
+ if possible.
+ (declspecs_add_type): Formatting fixes. Handle cts_bitint. Adjust
+ for added union in *specs. Handle RID_BITINT.
+ (finish_declspecs): Handle cts_bitint. Adjust for added union
+ in *specs.
+ * c-parser.cc (c_keyword_starts_typename, c_token_starts_declspecs,
+ c_parser_declspecs, c_parser_gnu_attribute_any_word): Handle
+ RID_BITINT.
+ (c_parser_omp_clause_schedule): Handle BITINT_TYPE like INTEGER_TYPE.
+ * c-tree.h (enum c_typespec_keyword): Mention _BitInt in comment.
+ Add cts_bitint enumerator.
+ (struct c_declspecs): Move int_n_idx and floatn_nx_idx into a union
+ and add bitint_prec there as well.
+ * c-typeck.cc (c_common_type, comptypes_internal):
+ Handle BITINT_TYPE.
+ (perform_integral_promotions): Promote BITINT_TYPE bit-fields to
+ their declared type.
+ (build_array_ref, build_unary_op, build_conditional_expr,
+ build_c_cast, convert_for_assignment, digest_init, build_binary_op):
+ Handle BITINT_TYPE.
+ * c-fold.cc (c_fully_fold_internal): Handle BITINT_TYPE like
+ INTEGER_TYPE.
+ * c-aux-info.cc (gen_type): Handle BITINT_TYPE.
+
+2023-09-06 Jakub Jelinek <jakub@redhat.com>
+
+ * c-decl.cc (declspecs_add_type): Use pedwarn_c11 rather than pedwarn
+ for _FloatN{,x} diagnostics and append " before C2X" to the diagnostic
+ text.
+
+2023-09-05 Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_clause_allocate): Handle
+ error_mark_node.
+
+2023-08-25 Sandra Loosemore <sandra@codesourcery.com>
+
+ * c-parser.cc (struct c_parser): Add omp_for_parse_state field.
+ (struct omp_for_parse_data): New.
+ (check_omp_intervening_code): New.
+ (add_structured_block_stmt): New.
+ (c_parser_compound_statement_nostart): Recognize intervening code,
+ nested loops, and other things that need special handling in
+ OpenMP loop constructs.
+ (c_parser_while_statement): Error on loop in intervening code.
+ (c_parser_do_statement): Likewise.
+ (c_parser_for_statement): Likewise.
+ (c_parser_postfix_expression_after_primary): Error on calls to
+ the OpenMP runtime in intervening code.
+ (c_parser_pragma): Error on OpenMP pragmas in intervening code.
+ (c_parser_omp_loop_nest): New.
+ (c_parser_omp_for_loop): Rewrite to use recursive descent, calling
+ c_parser_omp_loop_nest to do the heavy lifting.
+
+2023-08-24 Richard Sandiford <richard.sandiford@arm.com>
+
+ * c-parser.cc (c_parser_std_attribute): Conditionally allow
+ two colons to be used in place of ::.
+ (c_parser_std_attribute_list): New function, split out from...
+ (c_parser_std_attribute_specifier): ...here. Allow the attribute-list
+ to start with __extension__. When it does, also allow two colons
+ to be used in place of ::.
+
+2023-08-22 Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_clause_defaultmap): Parse
+ 'all' as category.
+
+2023-08-17 Jose E. Marchesi <jose.marchesi@oracle.com>
+
+ PR c/106537
+ * c-typeck.cc (build_binary_op): Warning on comparing distinct
+ pointer types only when -Wcompare-distinct-pointer-types.
+
+2023-08-15 Chung-Lin Tang <cltang@codesourcery.com>
+ Thomas Schwinge <thomas@codesourcery.com>
+
+ * c-parser.cc (OACC_DATA_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_DEFAULT.
+
+2023-08-11 Jakub Jelinek <jakub@redhat.com>
+
+ * c-parser.cc (c_parser_typeof_specifier): Handle
+ __typeof_unqual and __typeof_unqual__ as !is_std.
+
+2023-08-11 Martin Uecker <uecker@tugraz.at>
+
+ PR c/84510
+ * c-typeck.cc (build_c_cast): Add warning.
+
+2023-08-05 Martin Uecker <uecker@tugraz.at>
+
+ * c-parser.cc (c_parser_generic_selection): Inhibit evaluation
+ warnings branches that are known not be taken during parsing.
+
+2023-08-04 Tamar Christina <tamar.christina@arm.com>
+
+ * c-parser.cc (c_parser_while_statement, c_parser_do_statement,
+ c_parser_for_statement, c_parser_statement_after_labels,
+ c_parse_pragma_novector, c_parser_pragma): Wire through novector and
+ default to false.
+
+2023-08-02 Eric Feng <ef2648@columbia.edu>
+
+ PR analyzer/107646
+ * c-parser.cc: New functions on stashing values for the
+ analyzer.
+
+2023-08-01 Lewis Hyatt <lhyatt@gmail.com>
+
+ * c-parser.cc (pragma_lex_discard_to_eol): New function.
+ (c_init_preprocess): New function.
+
+2023-07-31 Hamza Mahfooz <someguy@effective-light.com>
+
+ PR c/65213
+ * c-decl.cc (start_decl): Handle
+ -Wmissing-variable-declarations.
+
+2023-07-31 Chung-Lin Tang <cltang@codesourcery.com>
+
+ * c-parser.cc (c_parser_oacc_host_data): Add checking requiring OpenACC
+ host_data construct to have an use_device clause.
+
+2023-06-29 Qing Zhao <qing.zhao@oracle.com>
+
+ PR c/77650
+ * c-decl.cc (finish_struct): Issue warnings for new option.
+
+2023-06-29 Qing Zhao <qing.zhao@oracle.com>
+
+ * c-decl.cc (finish_struct): Set TYPE_INCLUDES_FLEXARRAY for
+ struct/union type.
+
+2023-06-29 Richard Biener <rguenther@suse.de>
+
+ PR c/110454
+ * c-typeck.cc (convert_argument): Sink formal_prec compute
+ to where TYPE_PRECISION is valid to use.
+
+2023-06-29 Eugene Rozenfeld <erozen@microsoft.com>
+
+ * Make-lang.in: Pass correct stage cc1 when processing
+ profile data collected while building target libraries
+
+2023-06-16 David Malcolm <dmalcolm@redhat.com>
+
+ PR c/107583
+ * c-parser.cc (c_parser_declspecs): Add hints to "unknown type
+ name" error.
+
+2023-06-12 Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_clause_map): Reword error message for
+ clearness especially with 'omp target (enter/exit) data.'
+
+2023-06-06 Kwok Cheung Yeung <kcy@codesourcery.com>
+ Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_clause_defaultmap,
+ c_parser_omp_clause_map): Parse 'present'.
+ (c_parser_omp_clause_to, c_parser_omp_clause_from): Remove.
+ (c_parser_omp_clause_from_to): New; parse to/from clauses with
+ optional present modifer.
+ (c_parser_omp_all_clauses): Update call.
+ (c_parser_omp_target_data, c_parser_omp_target_enter_data,
+ c_parser_omp_target_exit_data): Handle new map enum values
+ for 'present' mapping.
+
+2023-05-30 Tobias Burnus <tobias@codesourcery.com>
+
+ PR c/109999
+ * c-parser.cc (c_parser_oacc_all_clauses,
+ c_parser_omp_all_clauses): Improve error wording.
+
+2023-05-23 Martin Uecker <uecker@tugraz.at>
+
+ PR c/109450
+ * c-decl.cc (add_decl_expr): New function.
+ (grokdeclarator): Add decl expr for size expression in
+ types pointed to by parameters declared as arrays.
+
+2023-05-23 Martin Uecker <uecker@tugraz.at>
+
+ PR c/70418
+ PR c/106465
+ PR c/107557
+ PR c/108423
+ * c-decl.cc (start_decl): Make sure size expression are
+ evaluated only in correct context.
+ (grokdeclarator): Size expression in fields may need a bind
+ expression, make sure DECL_EXPR is always created.
+ (grokfield, declspecs_add_type): Pass along size expressions.
+ (finish_struct): Remove unneeded DECL_EXPR.
+ (start_function): Evaluate size expressions for nested functions.
+ * c-parser.cc (c_parser_struct_declarations,
+ c_parser_struct_or_union_specifier): Pass along size expressions.
+ (c_parser_declaration_or_fndef): Evaluate size expression.
+ (c_parser_objc_at_property_declaration,
+ c_parser_objc_class_instance_variables): Adapt.
+ * c-tree.h (grokfield): Adapt declaration.
+
+2023-05-19 Martin Uecker <uecker@tugraz.at>
+
+ * c-decl.cc (set_type_context): Remove.
+ (pop_scope, diagnose_mismatched_decls, pushdecl):
+ Remove dead code.
+ * c-typeck.cc (comptypes_internal): Remove dead code.
+ (same_translation_unit_p): Remove.
+ (tagged_types_tu_compatible_p): Some fixes.
+
+2023-05-19 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (diagnose_mismatched_decls): Do not handle
+ thread-local declarations as tentative definitions for C2x.
+ (finish_decl): Do not allow thread-local definition with
+ incomplete type for C2x.
+
+2023-05-18 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
+
+ * c-convert.cc (c_convert): Ditto.
+ * c-decl.cc (merge_decls): Ditto.
+ * c-parser.cc (c_parser_omp_clause_reduction): Ditto.
+ (c_parser_omp_declare_reduction): Ditto.
+ * c-typeck.cc (build_component_ref): Ditto.
+ (convert_argument): Ditto.
+ (pointer_diff): Ditto.
+ (build_unary_op): Ditto.
+ (build_c_cast): Ditto.
+ (build_modify_expr): Ditto.
+ (store_init_value): Ditto.
+ (constexpr_init_fits_real_type): Ditto.
+ (check_constexpr_init): Ditto.
+ (c_finish_return): Ditto.
+ (handle_omp_array_sections_1): Ditto.
+ (c_finish_omp_clauses): Ditto.
+ * gimple-parser.cc (c_finish_gimple_return): Ditto.
+
+2023-05-16 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (check_for_loop_decls): Use pedwarn_c11 for
+ diagnostics.
+
+2023-05-15 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (grokdeclarator): Ignore _Atomic on function return
+ type for C2x.
+
+2023-04-30 Andrew Pinski <apinski@marvell.com>
+
+ * c-typeck.cc (process_init_element): Print out array type
+ for excessive elements.
+
+2023-04-30 Andrew Pinski <apinski@marvell.com>
+
+ PR c/107926
+ * c-typeck.cc (process_init_element): Move the check
+ for string cst until after the error message.
+
+2023-04-28 Eugene Rozenfeld <erozen@microsoft.com>
+
+ * Make-lang.in: Merge perf data collected when compiling cc1 and runtime libraries
+
+2023-04-27 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/109409
+ * c-parser.cc (c_parser_initializer): Move diagnostics about
+ initialization of variable sized object with non-empty initializer
+ after c_parser_expr_no_commas call and ret.set_error (); after it.
+
+2023-04-27 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/107682
+ PR c/109412
+ * c-typeck.cc (pop_init_level): If constructor_type is FUNCTION_TYPE,
+ reject empty initializer as invalid.
+
+2023-04-26 Richard Biener <rguenther@suse.de>
+
+ * gimple-parser.cc (c_parser_parse_gimple_body): Avoid
+ last_stmt.
+
+2023-04-25 Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_scan_loop_body): Handle
+ zero exec statements before/after 'omp scan'.
+
+2023-04-20 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/107041
+ * c-decl.cc (diagnose_mismatched_decls): Avoid -Wenum-int-mismatch
+ warning on acc_on_device declaration.
+
+2023-03-28 David Malcolm <dmalcolm@redhat.com>
+
+ PR c/107002
+ * c-typeck.cc (parser_build_binary_op): Update for new param of
+ check_for_xor_used_as_pow.
+
+2023-03-10 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/108079
+ * c-decl.cc (pop_scope): Suppress OPT_Wunused_variable warning
+ after diagnosing it.
+
+2023-02-28 Jakub Jelinek <jakub@redhat.com>
+
+ PR sanitizer/108894
+ * c-decl.cc (strict_flex_array_level_of): Move to c-common.cc
+ and rename to c_strict_flex_array_level_of.
+ (is_flexible_array_member_p): Adjust caller.
+
+2023-02-18 Martin Uecker <uecker@tugraz.at>
+
+ PR c/108375
+ * c-decl.cc (decl_jump_unsafe): Use c_type_variably_modified_p.
+ (diagnose_mismatched_decl): Dito.
+ (warn_about_goto): Dito:
+ (c_check_switch_jump_warnings): Dito.
+ (finish_decl): Dito.
+ (finish_struct): Dito.
+ (grokdeclarator): Set C_TYPE_VARIABLY_MODIFIED.
+ (finish_struct): Set C_TYPE_VARIABLY_MODIFIED.
+ * c-objc-common.cc (c_var_mod_p): New function.
+ (c_var_unspec_p): Remove.
+ * c-objc-common.h: Set lang hook.
+ * c-parser.cc (c_parser_declararion_or_fndef): Use c_type_variably_modified_p.
+ (c_parser_typeof_specifier): Dito.
+ (c_parser_has_attribute_expression): Dito.
+ (c_parser_generic_selection): Dito.
+ * c-tree.h: Define C_TYPE_VARIABLY_MODIFIED and define c_var_mode_p.
+ * c-typeck.cc: Remove c_vla_mod_p and use C_TYPE_VARIABLY_MODIFIED.
+
+2023-02-16 Patrick Palka <ppalka@redhat.com>
+
+ * c-parser.h: Mechanically drop static from static inline
+ functions via s/^static inline/inline/g.
+
+2023-02-10 Joseph Myers <joseph@codesourcery.com>
+
+ * c-convert.cc (c_convert): Allow conversion of a null pointer
+ constant to nullptr_t.
+ * c-typeck.cc (null_pointer_constant_p): Remove static.
+ (convert_for_assignment): Allow conversion of a null pointer
+ constant to nullptr_t.
+ (digest_init): Handle NULLPTR_TYPE among scalar conversions.
+ * c-tree.h (null_pointer_constant_p): Declare.
+
+2023-02-09 Tobias Burnus <tobias@codesourcery.com>
+
+ * c-parser.cc (c_parser_omp_allocate): Parse align
+ clause and check for restrictions.
+
+2023-02-08 Joseph Myers <joseph@codesourcery.com>
+
+ * c-typeck.cc (check_constexpr_init): Remove argument
+ null_pointer_constant. Only check pointer initializers for being
+ null.
+ (digest_init): Update calls to check_constexpr_init.
+
+2023-02-02 Joseph Myers <joseph@codesourcery.com>
+
+ * c-typeck.cc (build_binary_op): Allow comparisons between
+ pointers and nullptr_t values that are not null pointer constants.
+
+2023-02-02 Joseph Myers <joseph@codesourcery.com>
+
+ * c-typeck.cc: Include "realmpfr.h".
+ (constexpr_init_fits_real_type): Do not allow signaling NaN
+ conversions to different types with the same mode. Handle
+ conversions from binary to decimal types.
+ (check_constexpr_init): Do not disallow real initializers for
+ complex types. Do not disallow binary initializers for decimal
+ floating types.
+
+2023-01-31 Marek Polacek <polacek@redhat.com>
+
+ PR c++/107593
+ PR c++/108597
+ * c-objc-common.cc (instantiation_dependent_expression_p): New.
+
+2023-01-27 Joseph Myers <joseph@codesourcery.com>
+
+ * c-parser.cc (c_parser_declaration_or_fndef): Do not allow braces
+ around auto initializer.
+
+2023-01-16 Jakub Jelinek <jakub@redhat.com>
+
+ PR c++/105593
+ * c-parser.cc (c_parser_initializer): Check warning_enabled_at
+ at the DECL_SOURCE_LOCATION (decl) for OPT_Winit_self instead
+ of warn_init_self.
+
+2023-01-14 Jakub Jelinek <jakub@redhat.com>
+
+ PR c++/108365
+ * c-typeck.cc (build_binary_op): Use may_shorten_divmod for integral
+ division or modulo.
+
+2023-01-13 Qing Zhao <qing.zhao@oracle.com>
+
+ * c-decl.cc (strict_flex_array_level_of): ... here.
+
+2023-01-11 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/105972
+ * c-parser.cc (c_parser_declaration_or_fndef): Disable debug non-bind
+ markers for K&R function parameter declarations of nested functions.
+
+2023-01-09 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (build_compound_literal): Call record_inline_static.
+
+2023-01-06 Joseph Myers <joseph@codesourcery.com>
+
+ * c-parser.cc (c_parser_postfix_expression): Handle integer
+ generic arguments to functions passed to __builtin_tgmath as
+ _Float32x if any argument has _FloatNx or _Complex _FloatNx type.
+ Do not handle integer arguments to some narrowing functions as
+ _Float64.
+
+2022-12-19 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/108043
+ * c-parser.cc (c_parser_postfix_expression_after_paren_type): Diagnose
+ compound literals with function type.
+
+2022-12-07 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (declspecs_add_type, declspecs_add_scspec): Check for
+ auto, constexpr and a type used together.
+
+2022-12-06 Qing Zhao <qing.zhao@oracle.com>
+
+ * c-decl.cc (is_flexible_array_member_p): Call new function
+ strict_flex_array_level_of.
+
+2022-11-24 Florian Weimer <fweimer@redhat.com>
+
+ PR c/107805
+ * c-decl.cc (declspecs_add_type): Propagate error_mark_bode
+ from type to specs.
+
+2022-11-17 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
+
+ * c-decl.cc (start_function): Set the result decl source
+ location to the location of the typespec.
+
+2022-11-17 David Malcolm <dmalcolm@redhat.com>
+
+ PR analyzer/107711
+ * c-parser.cc (ana::c_translation_unit::consider_macro): Pass NULL
+ to cpp_create_reader, rather than ident_hash, so that the new
+ reader gets its own hash table.
+
+2022-11-15 David Malcolm <dmalcolm@redhat.com>
+
+ PR analyzer/106302
+ * c-parser.cc: Include "analyzer/analyzer-language.h" and "toplev.h".
+ (class ana::c_translation_unit): New.
+ (c_parser_translation_unit): Call ana::on_finish_translation_unit.
+
+2022-11-12 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (start_underspecified_init)
+ (finish_underspecified_init): Handle name == NULL_TREE for
+ compound literals.
+ (merge_decls): Merge C_DECL_DECLARED_CONSTEXPR.
+ (shadow_tag_warned): Check for constexpr.
+ (start_decl): Add parameter do_push.
+ (build_compound_literal): Set C_DECL_DECLARED_CONSTEXPR.
+ (grokdeclarator): Handle constexpr.
+ (finish_struct): Set C_TYPE_FIELDS_NON_CONSTEXPR.
+ (declspecs_add_scspec): Handle constexpr.
+ * c-parser.cc (c_token_starts_compound_literal)
+ (c_token_starts_declspecs, c_parser_declaration_or_fndef)
+ (c_parser_declspecs, c_parser_gnu_attribute_any_word)
+ (c_parser_compound_literal_scspecs)
+ (c_parser_postfix_expression_after_paren_type): Handle constexpr.
+ Update calls to start_init.
+ (c_parser_declaration_or_fndef, c_parser_initializer)
+ (c_parser_initval): Pass true for new argument of
+ convert_lvalue_to_rvalue. Call convert_lvalue_to_rvalue for
+ constexpr compound literals.
+ (c_parser_static_assert_declaration_no_semi)
+ (c_parser_enum_specifier, c_parser_struct_declaration)
+ (c_parser_alignas_specifier, c_parser_initelt, c_parser_label):
+ Call convert_lvalue_to_rvalue on expressions required to be
+ integer constant expressions.
+ (c_parser_omp_declare_reduction): Update call to start_init.
+ * c-tree.h (C_TYPE_FIELDS_NON_CONSTEXPR)
+ (C_DECL_DECLARED_CONSTEXPR): New macros.
+ (struct c_declspecs): Add constexpr_p.
+ (start_decl, convert_lvalue_to_rvalue, start_init): Update
+ prototypes.
+ * c-typeck.cc (require_constant_value, require_constant_elements):
+ Change to bool.
+ (require_constexpr_value, maybe_get_constexpr_init)
+ (constexpr_init_fits_real_type, check_constexpr_init): New.
+ (convert_lvalue_to_rvalue): Add new parameter for_init. Call
+ maybe_get_constexpr_init.
+ (store_init_value): Update call to digest_init.
+ (digest_init): Add parameters int_const_expr, arith_const_expr and
+ require_constexpr. Check constexpr initializers.
+ (constructor_top_level): Remove.
+ (struct initializer_stack): Remove top_level. Add
+ require_constexpr_value.
+ (start_init): Remove parameter top_level. Add parameters
+ init_require_constant and init_require_constexpr. Save
+ require_constexpr_value on stack.
+ (pop_init_level): Use a null pointer constant for zero initializer
+ of pointer initialized with {}.
+ (output_init_element): Update call to digest_init. Avoid passing
+ null pointer constants of pointer type through digest_init a
+ second time when initializing a constexpr object.
+
+2022-11-03 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (in_underspecified_init, start_underspecified_init)
+ (finish_underspecified_init): New.
+ (shadow_tag_warned, parser_xref_tag, start_struct, start_enum):
+ Give errors inside initializers of underspecified declarations.
+ (grokdeclarator): Handle (erroneous) case of C2X auto on a
+ parameter.
+ (declspecs_add_type): Handle c2x_auto_p case.
+ (declspecs_add_scspec): Handle auto possibly setting c2x_auto_p in
+ C2X mode.
+ (finish_declspecs): Handle c2x_auto_p.
+ * c-parser.cc (c_parser_declaration_or_fndef): Handle C2X auto.
+ * c-tree.h (C_DECL_UNDERSPECIFIED): New macro.
+ (struct c_declspecs): Add c2x_auto_p.
+ (start_underspecified_init, finish_underspecified_init): New
+ prototypes.
+ * c-typeck.cc (build_external_ref): Give error for underspecified
+ declaration referenced in its initializer.
+
+2022-10-28 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (grokdeclarator): Pass
+ arg_info->no_named_args_stdarg_p to build_function_type.
+ (grokparms): Check arg_info->no_named_args_stdarg_p before
+ converting () to (void).
+ (build_arg_info): Initialize no_named_args_stdarg_p.
+ (get_parm_info): Set no_named_args_stdarg_p.
+ (start_function): Pass TYPE_NO_NAMED_ARGS_STDARG_P to
+ build_function_type.
+ (store_parm_decls): Count (...) functions as prototyped.
+ * c-parser.cc (c_parser_direct_declarator): Allow '...' after open
+ parenthesis to start parameter list.
+ (c_parser_parms_list_declarator): Always allow '...' with no
+ arguments, call pedwarn_c11 and set no_named_args_stdarg_p.
+ * c-tree.h (struct c_arg_info): Add field no_named_args_stdarg_p.
+ * c-typeck.cc (composite_type): Handle
+ TYPE_NO_NAMED_ARGS_STDARG_P.
+ (function_types_compatible_p): Compare
+ TYPE_NO_NAMED_ARGS_STDARG_P.
+
+2022-10-28 Jakub Jelinek <jakub@redhat.com>
+
+ * c-parser.cc (c_parser_omp_all_clauses): Allow optional
+ comma before the first clause.
+ (c_parser_omp_allocate, c_parser_omp_atomic, c_parser_omp_depobj,
+ c_parser_omp_flush, c_parser_omp_scan_loop_body,
+ c_parser_omp_ordered, c_finish_omp_declare_variant,
+ c_parser_omp_declare_target, c_parser_omp_declare_reduction,
+ c_parser_omp_requires, c_parser_omp_error,
+ c_parser_omp_assumption_clauses): Likewise.
+
+2022-10-28 Joseph Myers <joseph@codesourcery.com>
+
+ PR c/61469
+ * c-convert.cc (c_convert): Handle enums with underlying boolean
+ type like bool.
+ * c-decl.cc (shadow_tag_warned): Allow shadowing declarations for
+ enums with enum type specifier, but give errors for storage class
+ specifiers, qualifiers or alignment specifiers in non-definition
+ declarations of such enums.
+ (grokdeclarator): Give error for non-definition use of type
+ specifier with an enum type specifier.
+ (parser_xref_tag): Add argument has_enum_type_specifier. Pass it
+ to lookup_tag and use it to set ENUM_FIXED_UNDERLYING_TYPE_P.
+ (xref_tag): Update call to parser_xref_tag.
+ (start_enum): Add argument fixed_underlying_type. Complete enum
+ type with a fixed underlying type given in the definition. Give
+ error for defining without a fixed underlying type in the
+ definition if one was given in a prior declaration. Do not mark
+ enums with fixed underlying type as packed for -fshort-enums.
+ Store the enum type in the_enum.
+ (finish_enum): Do not adjust types of values or check their range
+ for an enum with a fixed underlying type. Set underlying type of
+ enum and variants.
+ (build_enumerator): Check enumeration constants for enum with
+ fixed underlying type against that type and convert to that type.
+ Increment in the underlying integer type, with handling for bool.
+ (c_simulate_enum_decl): Update call to start_enum.
+ (declspecs_add_type): Set specs->enum_type_specifier_ref_p.
+ * c-objc-common.cc (c_get_alias_set): Use ENUM_UNDERLYING_TYPE
+ rather than recomputing an underlying type based on size.
+ * c-parser.cc (c_parser_declspecs)
+ (c_parser_struct_or_union_specifier, c_parser_typeof_specifier):
+ Set has_enum_type_specifier for type specifiers.
+ (c_parser_enum_specifier): Handle enum type specifiers.
+ (c_parser_struct_or_union_specifier): Update call to
+ parser_xref_tag.
+ (c_parser_omp_atomic): Check for boolean increment or decrement
+ using C_BOOLEAN_TYPE_P.
+ * c-tree.h (C_BOOLEAN_TYPE_P): New.
+ (struct c_typespec): Add has_enum_type_specifier.
+ (struct c_declspecs): Add enum_type_specifier_ref_p.
+ (struct c_enum_contents): Add enum_type.
+ (start_enum, parser_xref_tag): Update prototypes.
+ * c-typeck.cc (composite_type): Allow for enumerated types
+ compatible with bool.
+ (common_type, comptypes_internal, perform_integral_promotions):
+ Use ENUM_UNDERLYING_TYPE.
+ (parser_build_binary_op, build_unary_op, convert_for_assignment)
+ (c_finish_return, c_start_switch, build_binary_op): Check for
+ boolean types using C_BOOLEAN_TYPE_P.
+
+2022-10-24 Jakub Jelinek <jakub@redhat.com>
+
+ PR c++/107358
+ * c-typeck.cc (build_binary_op): Pass operands before excess precision
+ promotions to scalar_to_vector call.
+
+2022-10-24 Arsen Arsenović <arsen@aarsen.me>
+
+ * c-decl.cc (finish_function): Ignore hosted when deciding
+ whether to implicitly return zero, but check noreturn.
+ * c-objc-common.cc (c_missing_noreturn_ok_p): Loosen the
+ requirements to just MAIN_NAME_P when hosted, or `int main'
+ otherwise.
+
+2022-10-20 Richard Biener <rguenther@suse.de>
+
+ PR c/107305
+ PR c/107306
+ * gimple-parser.cc (c_parser_parse_gimple_body): Verify
+ the parsed IL and zap the body on error.
+
+2022-10-18 Joseph Myers <joseph@codesourcery.com>
+
+ PR c/107164
+ * c-decl.cc (shadow_tag_warned): If pedantic, diagnose "enum tag;"
+ with previous declaration visible.
+
+2022-10-18 Joseph Myers <joseph@codesourcery.com>
+
+ PR c/36113
+ * c-decl.cc (finish_enum): If any enumerators do not fit in int,
+ convert all to the type of the enumeration. pedwarn if no integer
+ type fits all enumerators and default to
+ widest_integer_literal_type_node in that case. Otherwise pedwarn
+ for type wider than intmax_t.
+ (build_enumerator): pedwarn for enumerators outside the range of
+ uintmax_t or intmax_t, and otherwise use pedwarn_c11 for
+ enumerators outside the range of int. On overflow, attempt to
+ find a wider type that can hold the value of the next enumerator.
+ Do not convert value to type determined with
+ c_common_type_for_size.
+
+2022-10-14 Jakub Jelinek <jakub@redhat.com>
+
+ * c-typeck.cc (convert_arguments): Don't promote __bf16 to
+ double.
+
+2022-10-14 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (build_compound_literal): Add parameter scspecs.
+ Handle storage class specifiers.
+ * c-parser.cc (c_token_starts_compound_literal)
+ (c_parser_compound_literal_scspecs): New.
+ (c_parser_postfix_expression_after_paren_type): Add parameter
+ scspecs. Call pedwarn_c11 for use of storage class specifiers.
+ Update call to build_compound_literal.
+ (c_parser_cast_expression, c_parser_sizeof_expression)
+ (c_parser_alignof_expression): Handle storage class specifiers for
+ compound literals. Update calls to
+ c_parser_postfix_expression_after_paren_type.
+ (c_parser_postfix_expression): Update syntax comment.
+ * c-tree.h (build_compound_literal): Update prototype.
+ * c-typeck.cc (c_mark_addressable): Diagnose taking address of
+ register compound literal.
+
+2022-10-07 Qing Zhao <qing.zhao@oracle.com>
+
+ * c-decl.cc (flexible_array_member_type_p): New function.
+ (one_element_array_type_p): Likewise.
+ (zero_length_array_type_p): Likewise.
+ (add_flexible_array_elts_to_size): Call new utility
+ routine flexible_array_member_type_p.
+ (is_flexible_array_member_p): New function.
+ (finish_struct): Set the new DECL_NOT_FLEXARRAY flag.
+
+2022-10-06 Joseph Myers <joseph@codesourcery.com>
+
+ * c-parser.cc (c_parse_init): Add D_EXT11 to mask if flag_no_asm
+ and not C2x.
+ (c_keyword_starts_typename, c_token_starts_declspecs)
+ (c_parser_declspecs, c_parser_objc_selector): Handle
+ RID_TYPEOF_UNQUAL.
+ (c_parser_typeof_specifier): Handle RID_TYPEOF_UNQUAL.
+ Distinguish typeof for C2x from __typeof__ for all standard
+ versions and typeof before C2x.
+ * c-typeck.cc (build_function_call_vec): Use unqualified version
+ of non-void return type.
+ (build_unary_op): Use unqualified type for increment and
+ decrement.
+
+2022-10-06 Jakub Jelinek <jakub@redhat.com>
+
+ * c-parser.cc (c_parser_omp_assumption_clauses): Emit IFN_ASSUME
+ call for holds clause on assume construct.
+
+2022-10-06 Jakub Jelinek <jakub@redhat.com>
+
+ PR c++/106654
+ * c-parser.cc (handle_assume_attribute): New function.
+ (c_parser_declaration_or_fndef): Handle assume attribute.
+ (c_parser_attribute_arguments): Add assume_attr argument,
+ if true, parse first argument as conditional expression.
+ (c_parser_gnu_attribute, c_parser_std_attribute): Adjust
+ c_parser_attribute_arguments callers.
+ (c_parser_statement_after_labels) <case RID_ATTRIBUTE>: Handle
+ assume attribute.
+
+2022-10-04 Jakub Jelinek <jakub@redhat.com>
+
+ * c-lang.h (struct c_omp_declare_target_attr): New type.
+ (current_omp_declare_target_attribute): Change type from
+ int to vec<c_omp_declare_target_attr, va_gc> *.
+ * c-parser.cc (c_parser_translation_unit): Adjust for that change.
+ If last pushed directive was begin declare target, use different
+ wording and simplify format strings for easier translations.
+ (c_parser_omp_clause_device_type): Uncomment
+ check_no_duplicate_clause call.
+ (c_parser_omp_declare_target): Adjust for the
+ current_omp_declare_target_attribute type change, push { -1 }.
+ Use error_at rather than warning_at for declare target with
+ only device_type clauses.
+ (OMP_BEGIN_DECLARE_TARGET_CLAUSE_MASK): Define.
+ (c_parser_omp_begin): Add begin declare target support.
+ (c_parser_omp_end): Adjust for the
+ current_omp_declare_target_attribute type change, adjust
+ diagnostics wording and simplify format strings for easier
+ translations.
+ * c-decl.cc (current_omp_declare_target_attribute): Change type from
+ int to vec<c_omp_declare_target_attr, va_gc> *.
+ (c_decl_attributes): Adjust for the
+ current_omp_declare_target_attribute type change. If device_type
+ was present on begin declare target, add "omp declare target host"
+ and/or "omp declare target nohost" attributes.
+
+2022-09-29 Joseph Myers <joseph@codesourcery.com>
+
+ * c-decl.cc (handle_std_noreturn_attribute): New function.
+ (std_attribute_table): Add _Noreturn and noreturn.
+
+2022-09-27 Jakub Jelinek <jakub@redhat.com>
+
+ * c-lang.h (current_omp_begin_assumes): Declare.
+ * c-parser.cc: Include bitmap.h.
+ (c_parser_omp_end_declare_target): Rename to ...
+ (c_parser_omp_end): ... this. Handle also end assumes.
+ (c_parser_omp_begin, c_parser_omp_assumption_clauses,
+ c_parser_omp_assumes, c_parser_omp_assume): New functions.
+ (c_parser_translation_unit): Also diagnose #pragma omp begin assumes
+ without corresponding #pragma omp end assumes.
+ (c_parser_pragma): Use %s in may only be used at file scope
+ diagnostics to decrease number of translatable messages. Handle
+ PRAGMA_OMP_BEGIN and PRAGMA_OMP_ASSUMES. Handle PRAGMA_OMP_END
+ rather than PRAGMA_OMP_END_DECLARE_TARGET and call c_parser_omp_end
+ for it rather than c_parser_omp_end_declare_target.
+ (c_parser_omp_construct): Handle PRAGMA_OMP_ASSUME.
+ * c-decl.cc (current_omp_begin_assumes): Define.
+
+2022-09-24 Jakub Jelinek <jakub@redhat.com>
+
+ PR c/106981
+ * c-typeck.cc (c_tree_equal): Only strip NON_LVALUE_EXPRs at the
+ start. For CONSTANT_CLASS_P or CASE_CONVERT: return false if t1 and
+ t2 have different types.
+
2022-09-22 David Malcolm <dmalcolm@redhat.com>
PR c/106830
* c-decl.c: Likewise. Include gt-c-c-decl.h, not gt-c-decl.h.
* c-parser.c: Likewise. Include gt-c-c-parser.h, not gt-c-parser.h.
\f
-Copyright (C) 2012-2022 Free Software Foundation, Inc.
+Copyright (C) 2012-2023 Free Software Foundation, Inc.
Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright