c++: retval dtor on rethrow [PR112301]
[official-gcc.git] / gcc / c-family / ChangeLog
blob3361fbd0cd0a17980eea7195dd17a65aa6cf58d2
1 2023-11-01  Martin Uecker  <uecker@tugraz.at>
3         PR c/71219
4         * c.opt (Walloc-size): New option.
6 2023-10-31  David Malcolm  <dmalcolm@redhat.com>
8         * c-warn.cc (warn_for_multistatement_macros): Update for removal
9         of MACRO_MAP_EXPANSION_POINT_LOCATION.
11 2023-10-27  Lewis Hyatt  <lhyatt@gmail.com>
13         PR preprocessor/87299
14         * c-pragma.cc (init_pragma): Register `#pragma GCC target' and
15         related pragmas in preprocess-only mode, and enable early handling.
16         (c_reset_target_pragmas): New function refactoring code from...
17         (handle_pragma_reset_options): ...here.
18         * c-pragma.h (c_reset_target_pragmas): Declare.
20 2023-10-26  David Malcolm  <dmalcolm@redhat.com>
22         * c-attribs.cc (c_common_attribute_table): Add
23         "null_terminated_string_arg".
24         (handle_null_terminated_string_arg_attribute): New.
26 2023-10-23  Lewis Hyatt  <lhyatt@gmail.com>
28         PR preprocessor/36887
29         * c-opts.cc (c_common_init_options): Pass new extra hash map
30         argument to cpp_create_reader().
32 2023-10-20  Marek Polacek  <polacek@redhat.com>
34         PR c/111884
35         * c-common.cc (c_common_get_alias_set): Return -1 for char8_t only
36         in C++.
38 2023-10-20  Patrick Palka  <ppalka@redhat.com>
40         * c-warn.cc (check_address_or_pointer_of_packed_member): Handle
41         type-dependent callee of CALL_EXPR.
43 2023-10-20  Alexandre Oliva  <oliva@adacore.com>
45         * c-attribs.cc (handle_expected_throw_attribute): New.
46         (c_common_attribute_table): Add expected_throw.
48 2023-10-19  Lewis Hyatt  <lhyatt@gmail.com>
50         PR c++/89038
51         * c-pragma.cc (handle_pragma_diagnostic_impl):  Handle
52         -Wunknown-pragmas during early processing.
54 2023-10-15  Jakub Jelinek  <jakub@redhat.com>
56         PR tree-optimization/111800
57         * c-warn.cc (match_case_to_enum_1): Assert w.get_precision ()
58         is smaller or equal to WIDE_INT_MAX_INL_PRECISION rather than
59         w.get_len () is smaller or equal to WIDE_INT_MAX_INL_ELTS.
61 2023-10-12  Jakub Jelinek  <jakub@redhat.com>
63         PR c/102989
64         * c-warn.cc (match_case_to_enum_1): Use wi::to_wide just once instead
65         of 3 times, assert get_len () is smaller than WIDE_INT_MAX_INL_ELTS.
67 2023-10-02  David Malcolm  <dmalcolm@redhat.com>
69         * c-common.cc (maybe_add_include_fixit): Update for renaming of
70         diagnostic_context's show_caret to m_source_printing.enabled.
71         * c-opts.cc (c_common_init_options): Update for renaming of
72         diagnostic_context's colorize_source_p to
73         m_source_printing.colorize_source_p.
75 2023-09-20  Jakub Jelinek  <jakub@redhat.com>
77         PR c++/111392
78         * c-omp.cc (c_omp_directives): Add commented out groupprivate
79         directive entry.
81 2023-09-19  Ben Boeckel  <ben.boeckel@kitware.com>
83         * c-opts.cc (c_common_handle_option): Add fdeps_file variable and
84         -fdeps-format=, -fdeps-file=, and -fdeps-target= parsing.
85         * c.opt: Add -fdeps-format=, -fdeps-file=, and -fdeps-target=
86         flags.
88 2023-09-19  Javier Martinez  <javier.martinez.bugzilla@gmail.com>
90         * c-attribs.cc (handle_hot_attribute): remove warning on
91         RECORD_TYPE and UNION_TYPE when in c_dialect_xx.
92         (handle_cold_attribute): Likewise.
94 2023-09-19  Jakub Jelinek  <jakub@redhat.com>
96         * c-common.cc (c_common_signed_or_unsigned_type): Return INTEGER_TYPE
97         for signed variant of unsigned _BitInt(1).
99 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
101         PR c/102989
102         * c-attribs.cc (type_valid_for_vector_size): Reject vector types
103         with BITINT_TYPE elements even if they have mode precision and
104         suitable size.
106 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
108         PR c/102989
109         * c-common.cc (c_common_reswords): Add _BitInt as keyword.
110         (unsafe_conversion_p): Handle BITINT_TYPE like INTEGER_TYPE.
111         (c_common_signed_or_unsigned_type): Handle BITINT_TYPE.
112         (c_common_truthvalue_conversion, c_common_get_alias_set,
113         check_builtin_function_arguments): Handle BITINT_TYPE like
114         INTEGER_TYPE.
115         (sync_resolve_size): Add ORIG_FORMAT argument.  If
116         FETCH && !ORIG_FORMAT, type is BITINT_TYPE, return -1 if size isn't
117         one of 1, 2, 4, 8 or 16 or if it is 16 but TImode is not supported.
118         (atomic_bitint_fetch_using_cas_loop): New function.
119         (resolve_overloaded_builtin): Adjust sync_resolve_size caller.  If
120         -1 is returned, use atomic_bitint_fetch_using_cas_loop to lower it.
121         Formatting fix.
122         (keyword_begins_type_specifier): Handle RID_BITINT.
123         * c-common.h (enum rid): Add RID_BITINT enumerator.
124         * c-cppbuiltin.cc (c_cpp_builtins): For C call
125         targetm.c.bitint_type_info and predefine __BITINT_MAXWIDTH__
126         and for -fbuilding-libgcc also __LIBGCC_BITINT_LIMB_WIDTH__ and
127         __LIBGCC_BITINT_ORDER__ macros if _BitInt is supported.
128         * c-lex.cc (interpret_integer): Handle CPP_N_BITINT.
129         * c-pretty-print.cc (c_pretty_printer::simple_type_specifier,
130         c_pretty_printer::direct_abstract_declarator,
131         c_pretty_printer::direct_declarator, c_pretty_printer::declarator):
132         Handle BITINT_TYPE.
133         (pp_c_integer_constant): Handle printing of large precision wide_ints
134         which would buffer overflow digit_buffer.
135         * c-warn.cc (conversion_warning, warnings_for_convert_and_check,
136         warnings_for_convert_and_check): Handle BITINT_TYPE like
137         INTEGER_TYPE.
139 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
141         PR c/102989
142         * c-ubsan.cc (ubsan_instrument_shift): Use UBSAN_PRINT_FORCE_INT
143         for type0 type descriptor.
145 2023-09-06  Jakub Jelinek  <jakub@redhat.com>
147         * c-lex.cc (interpret_float): For C diagnostics on FN and FNx suffixes
148         append " before C2X" to diagnostics text and follow behavior of
149         pedwarn_c11.
151 2023-09-01  Jakub Jelinek  <jakub@redhat.com>
153         PR c++/111069
154         * c-opts.cc (c_common_post_options): Change latest_abi_version to 19.
156 2023-08-31  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
158         * c.opt: Change spelling to macOS.
160 2023-08-31  Richard Biener  <rguenther@suse.de>
162         PR middle-end/111253
163         * c-pretty-print.cc (c_pretty_printer::primary_expression):
164         Only dump gimple_assign_single_p SSA def RHS.
166 2023-08-25  Sandra Loosemore  <sandra@codesourcery.com>
168         * c-common.h (c_omp_check_loop_binding_exprs): Declare.
169         * c-omp.cc: Include tree-iterator.h.
170         (find_binding_in_body): New.
171         (check_loop_binding_expr_r): New.
172         (LOCATION_OR): New.
173         (check_looop_binding_expr): New.
174         (c_omp_check_loop_binding_exprs): New.
176 2023-08-25  Uros Bizjak  <ubizjak@gmail.com>
178         * c-format.cc (read_any_format_width):
179         Rename TRUE/FALSE to true/false.
181 2023-08-20  Martin Uecker  <uecker@tugraz.at>
183         * c-format.cc: Fix identation.
185 2023-08-20  Tomas Kalibera  <tomas.kalibera@gmail.com>
187         PR c/95130
188         * c-format.cc: skip default format for printf symbol if
189         explicitly declared by prototype.
191 2023-08-17  Jose E. Marchesi  <jose.marchesi@oracle.com>
193         PR c/106537
194         * c.opt (Wcompare-distinct-pointer-types): New option.
196 2023-08-14  Jason Merrill  <jason@redhat.com>
198         * c-cppbuiltin.cc (c_cpp_builtins): Adjust __cpp_concepts.
200 2023-08-11  Jakub Jelinek  <jakub@redhat.com>
202         * c-common.cc (c_common_reswords): Add __typeof_unqual
203         and __typeof_unqual__ spellings of typeof_unqual.
205 2023-08-11  Martin Uecker  <uecker@tugraz.at>
207         PR c/84510
208         * c.opt: Enable warning for C and ObjC.
210 2023-08-05  Martin Uecker  <uecker@tugraz.at>
212         PR c/98536
213         * c-warn.cc (warn_parm_array_mismatch): Do not warn if more
214         bounds are specified.
216 2023-08-04  Tamar Christina  <tamar.christina@arm.com>
218         * c-pragma.h (enum pragma_kind): Add PRAGMA_NOVECTOR.
219         * c-pragma.cc (init_pragma): Use it.
221 2023-08-01  Lewis Hyatt  <lhyatt@gmail.com>
223         * c-common.h (c_init_preprocess): Declare new function.
224         * c-opts.cc (c_common_init): Call it.
225         * c-lex.cc (cb_def_pragma): Add a comment.
226         (get_token): New function wrapping cpp_get_token.
227         (c_lex_with_flags): Use the new wrapper function to support
228         obtaining tokens in preprocess_only mode.
229         (lex_string): Likewise.
230         * c-pragma.cc (pragma_diagnostic_lex_normal): Rename to...
231         (pragma_diagnostic_lex): ...this.
232         (pragma_diagnostic_lex_pp): Remove.
233         (handle_pragma_diagnostic_impl): Call pragma_diagnostic_lex () in
234         all modes.
235         (c_pp_invoke_early_pragma_handler): Adapt to support pragma_lex ()
236         usage.
237         * c-pragma.h (pragma_lex_discard_to_eol): Declare.
239 2023-07-31  Hamza Mahfooz  <someguy@effective-light.com>
241         PR c/65213
242         * c.opt (-Wmissing-variable-declarations): New option.
244 2023-07-20  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
246         PR middle-end/77928
247         * c-common.cc (check_builtin_function_arguments):
248         Handle BUILT_IN_ISEQSIG.
250 2023-07-05  Robin Dapp  <rdapp@ventanamicro.com>
251             Juzhe-Zhong  <juzhe.zhong@rivai.ai>
253         * c-common.cc (c_common_type_for_mode): Use GET_MODE_PRECISION.
255 2023-06-29  Qing Zhao  <qing.zhao@oracle.com>
257         PR c/77650
258         * c.opt: New option -Wflex-array-member-not-at-end.
260 2023-06-28  Jason Merrill  <jason@redhat.com>
262         PR c++/110344
263         * c-cppbuiltin.cc (c_cpp_builtins): Update __cpp_constexpr.
265 2023-06-26  Richard Biener  <rguenther@suse.de>
267         * c-common.cc (shorten_binary_op): Exit early for VECTOR_TYPE
268         operations.
270 2023-06-23  Marek Polacek  <polacek@redhat.com>
272         * c-common.h (cxx_dialect): Add cxx26 as a dialect.
273         * c-opts.cc (set_std_cxx26): New.
274         (c_common_handle_option): Set options when -std={c,gnu}++2{c,6} is
275         enabled.
276         (c_common_post_options): Adjust comments.
277         * c.opt: Add options for -std=c++26, std=c++2c, -std=gnu++26,
278         and -std=gnu++2c.
279         (std=c++2b): Mark as Undocumented.
280         (std=c++23): No longer Undocumented.
282 2023-06-21  Alexander Monakov  <amonakov@ispras.ru>
284         * c-gimplify.cc (fma_supported_p): New helper.
285         (c_gimplify_expr) [PLUS_EXPR, MINUS_EXPR]: Implement FMA
286         contraction.
288 2023-06-16  Alex Coplan  <alex.coplan@arm.com>
290         * c.opt (Welaborated-enum-base): New.
292 2023-06-13  David Malcolm  <dmalcolm@redhat.com>
294         PR c/84890
295         * known-headers.cc
296         (suggest_missing_header::~suggest_missing_header): Reword note to
297         avoid negative tone of "forgetting".
299 2023-06-07  Jason Merrill  <jason@redhat.com>
301         PR c++/58487
302         * c.opt: Add -Wnrvo.
304 2023-05-26  Martin Uecker  <uecker@tugraz.at>
306         * c-attribs.cc (build_attr_access_from_parms): Split loop to first
307         record all parameters.
309 2023-05-18  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
311         * c-ada-spec.cc (has_static_fields): Use _P() defines from tree.h.
312         (dump_ada_declaration): Ditto.
313         (dump_ada_structure): Ditto.
314         * c-common.cc (unsafe_conversion_p): Ditto.
315         (shorten_compare): Ditto.
316         (pointer_int_sum): Ditto.
317         (c_common_truthvalue_conversion): Ditto.
318         (scalar_to_vector): Ditto.
319         * c-common.h (gnu_vector_type_p): Ditto.
320         * c-omp.cc (c_omp_depend_t_p): Ditto.
321         (c_omp_split_clauses): Ditto.
322         * c-ubsan.cc (ubsan_instrument_division): Ditto.
323         * c-warn.cc (conversion_warning): Ditto.
324         (warnings_for_convert_and_check): Ditto.
326 2023-05-18  Joseph Myers  <joseph@codesourcery.com>
328         * c-format.cc (print_char_table): Handle %B like %b.
330 2023-05-15  Joseph Myers  <joseph@codesourcery.com>
332         * c-lex.cc (c_common_has_attribute): Use 202311 as
333         __has_c_attribute return for all C2x attributes.
335 2023-05-15  Patrick Palka  <ppalka@redhat.com>
337         * c-cppbuiltin.cc (c_cpp_builtins): Predefine __cpp_auto_cast
338         for C++23.
340 2023-05-01  Marek Polacek  <polacek@redhat.com>
342         * c-ubsan.cc (ubsan_maybe_instrument_array_ref): Don't copy_node.
344 2023-03-28  David Malcolm  <dmalcolm@redhat.com>
346         PR c/107002
347         * c-common.h (check_for_xor_used_as_pow): Add "rhs_loc" param.
348         * c-warn.cc (check_for_xor_used_as_pow): Add "rhs_loc" param.
349         Reject cases where involving macro expansions.
351 2023-03-28  Jason Merrill  <jason@redhat.com>
353         PR c++/107163
354         * c-common.cc (verify_tree): Don't use sequenced handling
355         for COMPONENT_REF.
357 2023-03-17  Jakub Jelinek  <jakub@redhat.com>
359         PR c/109151
360         * c-ubsan.cc (ubsan_instrument_division): Handle all scalar integral
361         types rather than just INTEGER_TYPE.
363 2023-03-10  Marek Polacek  <polacek@redhat.com>
365         PR sanitizer/108060
366         PR sanitizer/109050
367         * c-gimplify.cc (ubsan_walk_array_refs_r): For a MODIFY_EXPR, instrument
368         the RHS before the LHS.
370 2023-03-04  Jakub Jelinek  <jakub@redhat.com>
372         PR c/107465
373         * c-warn.cc (warn_for_sign_compare): Don't warn for unset bits
374         above innermost zero extension of BIT_NOT_EXPR result.
376 2023-03-04  Jakub Jelinek  <jakub@redhat.com>
378         PR c/107465
379         * c-warn.cc (warn_for_sign_compare): If c_common_get_narrower
380         doesn't return a narrower result, use TYPE_UNSIGNED to set unsignedp0
381         and unsignedp1.  For the one BIT_NOT_EXPR case vs. one without,
382         only check for constant in the non-BIT_NOT_EXPR operand, use std::swap
383         to simplify the code, only warn if BIT_NOT_EXPR operand is extended
384         from narrower unsigned, fix up computation of mask for the constant
385         cases and for unsigned other operand case handle differently
386         BIT_NOT_EXPR result being sign vs. zero extended.
388 2023-03-04  Jakub Jelinek  <jakub@redhat.com>
390         PR c/107846
391         * c-warn.cc: Include langhooks.h.
392         (maybe_warn_shift_overflow): Set type0 to what TREE_TYPE (op0)
393         promotes to rather than TREE_TYPE (op0) itself, if TREE_TYPE (op0)
394         is narrower than type0 and unsigned, use wi::min_precision with
395         UNSIGNED and fold_convert op0 to type0 before emitting the warning.
397 2023-03-03  Alexandre Oliva  <oliva@adacore.com>
399         * c-common.cc (c_common_nodes_and_builtins): Take
400         wchar_type_node for wint_type_node when aliased.
401         (c_stddef_cpp_builtins): Define __WINT_TYPE__, when aliased to
402         wchar_t, to the underlying type rather than wchar_t in
403         non-C++.
404         * c-cppbuiltin.cc (type_suffix): Handle wchar_type_node.
406 2023-02-28  Marek Polacek  <polacek@redhat.com>
408         PR c++/107938
409         * c-warn.cc (check_address_or_pointer_of_packed_member): Check
410         POINTER_TYPE_P.
412 2023-02-28  Jakub Jelinek  <jakub@redhat.com>
414         PR sanitizer/108894
415         * c-common.h (c_strict_flex_array_level_of): Declare.
416         * c-common.cc (c_strict_flex_array_level_of): New function,
417         moved and renamed from c-decl.cc's strict_flex_array_level_of.
418         * c-ubsan.cc (ubsan_instrument_bounds): Fix comment typo.  For
419         C check c_strict_flex_array_level_of whether a trailing array
420         should be treated as flexible member like.  Handle C [0] arrays.
421         Add 1 + index_off_by_one rather than index_off_by_one to bounds
422         and use tree_int_cst_lt rather than tree_int_cst_le for idx vs.
423         bounds comparison.
425 2023-02-23  Jakub Jelinek  <jakub@redhat.com>
427         PR translation/108890
428         * c.opt (fcontracts): Fix description.
430 2023-02-22  Marek Polacek  <polacek@redhat.com>
432         PR c/108880
433         * c-gimplify.cc (c_genericize_control_stmt) <case STATEMENT_LIST>: Pass
434         pset to walk_tree_1.
435         (c_genericize): Call walk_tree with an explicit pset.
437 2023-02-18  Martin Uecker  <uecker@tugraz.at>
439         PR c/105660
440         * c-attribs.cc (append_access_attr): Use order of arguments when
441         construction string.
442         (append_access_attr_idxs): Rename and make static.
443         * c-warn.cc (warn_parm_array_mismatch): Add assertion.
445 2023-02-16  Patrick Palka  <ppalka@redhat.com>
447         * c-common.h: Mechanically drop static from static inline
448         functions via s/^static inline/inline/g.
450 2023-02-01  Jason Merrill  <jason@redhat.com>
452         * c.opt: Add -Wno-changes-meaning.
454 2023-01-31  Marek Polacek  <polacek@redhat.com>
456         PR c++/107593
457         PR c++/108597
458         * c-common.h (instantiation_dependent_expression_p): Declare.
459         * c-warn.cc (warn_duplicated_cond_add_or_warn): If the condition
460         is dependent, invalidate the chain.
462 2023-01-26  Marek Polacek  <polacek@redhat.com>
464         PR c++/105300
465         * c-pragma.cc (handle_pragma_message): Warn for CPP_STRING_USERDEF.
467 2023-01-18  Marek Polacek  <polacek@redhat.com>
469         PR c/108424
470         * c-common.cc (check_case_value): Check INTEGRAL_TYPE_P.
472 2023-01-14  Jakub Jelinek  <jakub@redhat.com>
474         PR c++/108365
475         * c-common.h (may_shorten_divmod): New static inline function.
477 2023-01-13  Eric Botcazou  <ebotcazou@adacore.com>
479         * c-ada-spec.cc (is_float32): New function.
480         (is_float64): Likewise.
481         (is_float128): Tweak.
482         (dump_ada_node) <REAL_TYPE>: Call them to recognize more types.
484 2023-01-12  Lewis Hyatt  <lhyatt@gmail.com>
486         PR preprocessor/108244
487         * c-pragma.cc (c_register_pragma_1): Don't attempt to register any
488         deferred pragmas if -fdirectives-only.
489         (init_pragma): Likewise.
491 2023-01-09  Martin Liska  <mliska@suse.cz>
493         PR c/107993
494         * c-attribs.cc (handle_target_clones_attribute): Check for
495         string constant for all target_clone attribute values.
497 2023-01-03  Florian Weimer  <fweimer@redhat.com>
499         * c-cppbuiltin.cc (c_cpp_builtins): Define
500         __LIBGCC_DWARF_CIE_DATA_ALIGNMENT__.
502 2023-01-03  Florian Weimer  <fweimer@redhat.com>
504         Revert:
505         2023-01-03  Florian Weimer  <fweimer@redhat.com>
507         * c-cppbuiltin.cc (__LIBGCC_DWARF_REG_SIZES_CONSTANT__):
508         Define if constant is known.
510 2023-01-03  Florian Weimer  <fweimer@redhat.com>
512         Revert:
513         2023-01-02  Florian Weimer  <fweimer@redhat.com>
515         * c-cppbuiltin.cc (c_cpp_builtins): Define
516         __LIBGCC_DWARF_CIE_DATA_ALIGNMENT__.
518 2023-01-02  Florian Weimer  <fweimer@redhat.com>
520         * c-cppbuiltin.cc (c_cpp_builtins): Define
521         __LIBGCC_DWARF_CIE_DATA_ALIGNMENT__.
523 2023-01-02  Florian Weimer  <fweimer@redhat.com>
525         * c-cppbuiltin.cc (__LIBGCC_DWARF_REG_SIZES_CONSTANT__):
526         Define if constant is known.
528 2022-12-19  Marek Polacek  <polacek@redhat.com>
530         PR c/98487
531         * c-format.cc (check_function_format): Use get_attribute_name.
533 2022-12-16  Qing Zhao  <qing.zhao@oracle.com>
535         * c.opt (Wstrict-flex-arrays): New option.
537 2022-12-02  Andrew MacLeod  <amacleod@redhat.com>
539         * c-attribs.cc (handle_deprecated_attribute): Use type when
540         using TYPE_NAME.
542 2022-12-02  Jakub Jelinek  <jakub@redhat.com>
544         PR c++/84469
545         * c-omp.cc (c_omp_is_loop_iterator): For range for with structured
546         binding return TREE_VEC_LENGTH (d->declv) even if decl is equal
547         to any of the structured binding decls.
549 2022-11-30  Iskander Shakirzyanov  <iskander@ispras.ru>
550             Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
552         PR driver/107787
553         * c-common.cc (fold_offsetof,
554         convert_vector_to_array_for_subscript): Use OPT_Warray_bounds_
555         instead of OPT_Warray_bounds.
557 2022-11-24  Jakub Jelinek  <jakub@redhat.com>
559         * c.opt (fcontract-role=, fcontract-semantic=): Terminate descriptions
560         with a dot.
562 2022-11-23  Andrew Pinski  <apinski@marvell.com>
563             Jakub Jelinek  <jakub@redhat.com>
565         PR c/107127
566         * c-gimplify.cc (c_genericize): Use walk_tree_without_duplicates
567         instead of walk_tree for c_genericize_control_r.
569 2022-11-23  Jakub Jelinek  <jakub@redhat.com>
571         * c.opt (fcontract-assumption-mode=, fcontract-continuation-mode=,
572         fcontract-role=, fcontract-semantic=): Add RejectNegative.
573         (fcontract-build-level=): Terminate description with dot.
575 2022-11-19  Jakub Jelinek  <jakub@redhat.com>
577         * c-cppbuiltin.cc (c_cpp_builtins): Bump __cpp_constexpr
578         value from 202207L to 202211L.
580 2022-11-19  Jeff Chapman II  <jchapman@lock3software.com>
581             Andrew Sutton   <asutton@lock3software.com>
582             Andrew Marmaduke  <amarmaduke@lock3software.com>
583             Michael Lopez  <mlopez@lock3software.com>
584             Jason Merrill   <jason@redhat.com>
586         * c.opt: Add contracts flags.
587         * c-cppbuiltin.cc (c_cpp_builtins): Add contracts feature-test
588         macros.
590 2022-11-16  Marek Polacek  <polacek@redhat.com>
592         PR c++/106649
593         * c-cppbuiltin.cc (c_cpp_builtins): Update value of __cpp_constexpr for
594         C++23.
595         * c-opts.cc (c_common_post_options): Set warn_invalid_constexpr
596         depending on cxx_dialect.
597         * c.opt (Winvalid-constexpr): New option.
599 2022-11-16  Jakub Jelinek  <jakub@redhat.com>
601         * c-common.def (CONCEPT_DECL): New tree, moved here from
602         cp-tree.def.
603         * c-common.cc (c_common_init_ts): Handle CONCEPT_DECL.
604         * c-attribs.cc (handle_deprecated_attribute): Allow deprecated
605         attribute on CONCEPT_DECL.
607 2022-11-15  Lewis Hyatt  <lhyatt@gmail.com>
609         * c-opts.cc (c_finish_options): Use special_fname_builtin () rather
610         than a hard-coded string.
612 2022-11-15  Jakub Jelinek  <jakub@redhat.com>
614         * c-cppbuiltin.cc (c_cpp_builtins): Bump C++23
615         __cpp_multidimensional_subscript macro value to 202211L.
617 2022-11-15  Patrick Palka  <ppalka@redhat.com>
619         PR c++/107638
620         * c-lex.cc (c_common_has_attribute): Return 1 for init_priority
621         iff SUPPORTS_INIT_PRIORITY.
623 2022-11-14  Martin Liska  <mliska@suse.cz>
625         Revert:
626         2022-11-09  Martin Liska  <mliska@suse.cz>
628         * c-target.def: Port to RST.
630 2022-11-12  Joseph Myers  <joseph@codesourcery.com>
632         * c-common.cc (c_common_reswords): Use D_C2X instead of D_CXXONLY.
634 2022-11-11  Jonathan Wakely  <jwakely@redhat.com>
636         PR c/85487
637         * c-pragma.cc (handle_pragma_ignore): New function.
638         (init_pragma): Register region and endregion pragmas.
640 2022-11-09  Martin Liska  <mliska@suse.cz>
642         * c-target.def: Port to RST.
644 2022-11-05  Lewis Hyatt  <lhyatt@gmail.com>
646         PR preprocessor/55971
647         * c-ppoutput.cc (adjust_for_newlines): Update comment.
649 2022-11-03  Jason Merrill  <jason@redhat.com>
651         * c-opts.cc (c_common_post_options): -fconcepts no longer implies
652         -fconcepts-ts before C++20.
654 2022-10-28  Joseph Myers  <joseph@codesourcery.com>
656         * c-common.cc (def_fn_type): Call build_function_type for
657         zero-argument variable-argument function.
658         (c_common_nodes_and_builtins): Build default_function_type with
659         build_function_type.
660         * c.opt (fallow-parameterless-variadic-functions): Mark as ignored
661         option.
663 2022-10-28  Joseph Myers  <joseph@codesourcery.com>
665         PR c/61469
666         * c-common.h (ENUM_UNDERLYING_TYPE, ENUM_FIXED_UNDERLYING_TYPE_P):
667         New.  Moved from cp/cp-tree.h.
668         * c-warn.cc (warnings_for_convert_and_check): Do not consider
669         conversions to enum with underlying type bool to overflow.
671 2022-10-26  Marek Polacek  <polacek@redhat.com>
673         PR c++/106393
674         * c.opt (Wdangling-reference): New.
676 2022-10-19  Joseph Myers  <joseph@codesourcery.com>
678         * c-format.h (enum format_lengths): Add FMT_LEN_w8, FMT_LEN_w16,
679         FMT_LEN_w32, FMT_LEN_w64, FMT_LEN_wf8, FMT_LEN_wf16, FMT_LEN_wf32
680         and FMT_LEN_wf64.
681         (NOARGUMENTS, NOLENGTHS): Update definitions.
682         (T_I8, T2X_I8, T_I16, T2X_I16, T_I32, T2X_I32, T_I64, T2X_I64)
683         (T_U8, T2X_U8, T_U16, T2X_U16, T_U32, T2X_U32, T_U64, T2X_U64)
684         (T_IF8, T2X_IF8, T_IF16, T2X_IF16, T_IF32, T2X_IF32, T_IF64)
685         (T2X_IF64, T_UF8, T2X_UF8, T_UF16, T2X_UF16, T_UF32, T2X_UF32)
686         (T_UF64, T2X_UF64): New macros.
687         * c-format.cc (printf_length_specs, scanf_length_specs): Add wN
688         and wfN length modifiers.
689         (print_char_table, scan_char_table): Add entries using wN and wfN
690         length modifiers.
692 2022-10-18  Joseph Myers  <joseph@codesourcery.com>
694         PR c/36113
695         * c-common.cc (c_common_type_for_size): Add fallback to
696         widest_unsigned_literal_type_node or
697         widest_integer_literal_type_node for precision that may not
698         exactly match the precision of those types.
700 2022-10-14  Jakub Jelinek  <jakub@redhat.com>
702         * c-cppbuiltin.cc (c_cpp_builtins): If bfloat16_type_node,
703         predefine __BFLT16_*__ macros and for C++23 also
704         __STDCPP_BFLOAT16_T__.  Predefine bfloat16_type_node related
705         macros for -fbuilding-libgcc.
706         * c-lex.cc (interpret_float): Handle CPP_N_BFLOAT16.
708 2022-10-14  Jakub Jelinek  <jakub@redhat.com>
710         PR middle-end/323
711         PR c++/107097
712         * c-common.def (EXCESS_PRECISION_EXPR): Remove comment part about
713         the tree being specific to C/ObjC.
714         * c-opts.cc (c_common_post_options): Handle flag_excess_precision
715         in C++ the same as in C.
716         * c-lex.cc (interpret_float): Set const_type to excess_precision ()
717         even for C++.
719 2022-10-13  Joseph Myers  <joseph@codesourcery.com>
721         * c-cppbuiltin.cc (builtin_define_float_constants): Do not use
722         value 2 for *_IS_IEC_60559.
724 2022-10-12  Lewis Hyatt  <lhyatt@gmail.com>
726         PR preprocessor/60014
727         PR preprocessor/60723
728         * c-ppoutput.cc (class token_streamer): Remove member
729         line_marker_emitted to...
730         (token_streamer::stream): ...a local variable here. Set
731         print.prev_was_system_token on all code paths.
733 2022-10-10  Nathan Sidwell  <nathan@acm.org>
735         * c-opts.cc (c_common_post_options): Bump abi to 18.
737 2022-10-10  Marek Polacek  <polacek@redhat.com>
739         PR c++/106937
740         * c-pretty-print.cc (pp_c_specifier_qualifier_list): Print only GNU
741         attributes here.
742         (c_pretty_printer::direct_abstract_declarator): Print the standard [[]]
743         attributes here.
744         (pp_c_attributes): Remove.
745         (pp_c_attributes_display): Print the [[]] form if appropriate.  Use
746         get_attribute_name.  Don't print a trailing space when printing the
747         [[]] form.
748         * c-pretty-print.h (pp_c_attributes): Remove.
750 2022-10-07  Qing Zhao  <qing.zhao@oracle.com>
752         * c-attribs.cc (handle_strict_flex_array_attribute): New function.
753         (c_common_attribute_table): New item for strict_flex_array.
754         * c.opt: (fstrict-flex-arrays): New option.
755         (fstrict-flex-arrays=): New option.
757 2022-10-07  Martin Liska  <mliska@suse.cz>
759         * name-hint.h: Use std::move.
761 2022-10-07  Jakub Jelinek  <jakub@redhat.com>
763         * c-common.cc (attribute_fallthrough_p): Lookup fallthrough attribute
764         only in gnu namespace or as standard attribute, treat fallthrough
765         attributes in other namespaces like any other unknown attribute.
767 2022-10-06  Joseph Myers  <joseph@codesourcery.com>
769         * c-common.cc (c_common_reswords): Mark typeof as D_EXT11.  Add
770         typeof_unqual.
771         * c-common.h (enum rid): Add RID_TYPEOF_UNQUAL.
772         (D_EXT11): New macro.  Values of subsequent macros updated.
774 2022-10-06  Jakub Jelinek  <jakub@redhat.com>
776         PR c++/106654
777         * c-attribs.cc (handle_assume_attribute): New function.
778         (c_common_attribute_table): Add entry for assume attribute.
779         * c-lex.cc (c_common_has_attribute): Handle
780         __have_cpp_attribute (assume).
782 2022-10-04  Jakub Jelinek  <jakub@redhat.com>
784         * c-omp.cc (c_omp_directives): Uncomment begin declare target
785         entry.
787 2022-10-03  Patrick Palka  <ppalka@redhat.com>
789         * c-common.cc (c_common_reswords): Use RID_IS_SAME instead of
790         RID_IS_SAME_AS.
792 2022-10-03  Joseph Myers  <joseph@codesourcery.com>
794         * c-cppbuiltin.cc (builtin_define_float_constants): Do not
795         special-case __*_EPSILON__ setting for IBM long double for C2x.
797 2022-09-30  Patrick Palka  <ppalka@redhat.com>
799         * c-common.cc (c_common_reswords): Use cp/cp-trait.def to handle
800         C++ traits.
801         * c-common.h (enum rid): Likewise.
803 2022-09-29  Joseph Myers  <joseph@codesourcery.com>
805         * c-lex.cc (c_common_has_attribute): Handle noreturn attribute for
806         C.
808 2022-09-29  Patrick Palka  <ppalka@redhat.com>
810         * c-common.cc (c_common_reswords): Add __remove_cv,
811         __remove_reference and __remove_cvref.
812         * c-common.h (enum rid): Add RID_REMOVE_CV, RID_REMOVE_REFERENCE
813         and RID_REMOVE_CVREF.
815 2022-09-27  Marek Polacek  <polacek@redhat.com>
817         PR c++/101165
818         PR c++/106882
819         * c-cppbuiltin.cc (c_cpp_builtins): Define __cpp_implicit_move.
821 2022-09-27  Marek Polacek  <polacek@redhat.com>
823         * c-format.cc (c_keywords): Drop nothrow.
825 2022-09-27  Jakub Jelinek  <jakub@redhat.com>
827         PR c++/106651
828         * c-cppbuiltin.cc (c_cpp_builtins): Predefine
829         __cpp_static_call_operator=202207L for C++23.
831 2022-09-27  Jakub Jelinek  <jakub@redhat.com>
833         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ASSUME,
834         PRAGMA_OMP_ASSUMES and PRAGMA_OMP_BEGIN.  Rename
835         PRAGMA_OMP_END_DECLARE_TARGET to PRAGMA_OMP_END.
836         * c-pragma.cc (omp_pragmas): Add assumes and begin.
837         For end rename PRAGMA_OMP_END_DECLARE_TARGET to PRAGMA_OMP_END.
838         (omp_pragmas_simd): Add assume.
839         * c-common.h (c_omp_directives): Declare.
840         * c-omp.cc (omp_directives): Rename to ...
841         (c_omp_directives): ... this.  No longer static.  Uncomment
842         assume, assumes, begin assumes and end assumes entries.
843         In end declare target entry rename PRAGMA_OMP_END_DECLARE_TARGET
844         to PRAGMA_OMP_END.
845         (c_omp_categorize_directive): Adjust for omp_directives to
846         c_omp_directives renaming.
848 2022-09-27  Jakub Jelinek  <jakub@redhat.com>
850         PR c++/106652
851         PR c++/85518
852         * c-common.cc (c_common_reswords): Change _Float{16,32,64,128} and
853         _Float{32,64,128}x flags from D_CONLY to 0.
854         (shorten_binary_op): Punt if common_type returns error_mark_node.
855         (shorten_compare): Likewise.
856         (c_common_nodes_and_builtins): For C++ record _Float{16,32,64,128}
857         and _Float{32,64,128}x builtin types if available.  For C++
858         clear float128t_type_node.
859         * c-cppbuiltin.cc (c_cpp_builtins): Predefine
860         __STDCPP_FLOAT{16,32,64,128}_T__ for C++23 if supported.
861         * c-lex.cc (interpret_float): For q/Q suffixes prefer
862         float128t_type_node over float128_type_node.  Allow
863         {f,F}{16,32,64,128} suffixes for C++ if supported with pedwarn
864         for C++20 and older.  Allow {f,F}{32,64,128}x suffixes for C++
865         with pedwarn.  Don't call excess_precision_type for C++.
867 2022-09-26  Marek Polacek  <polacek@redhat.com>
869         PR c++/106656
870         * c-cppbuiltin.cc (c_cpp_builtins): Update value of __cpp_char8_t
871         for C++20.
873 2022-09-23  Marek Polacek  <polacek@redhat.com>
875         PR c++/106784
876         * c-common.cc (c_common_reswords): Add __is_convertible and
877         __is_nothrow_convertible.
878         * c-common.h (enum rid): Add RID_IS_CONVERTIBLE and
879         RID_IS_NOTHROW_CONVERTIBLE.
881 2022-09-22  David Malcolm  <dmalcolm@redhat.com>
883         PR c/106830
884         * c-warn.cc (check_for_xor_used_as_pow): Don't try checking
885         values that don't fit in uhwi.
887 2022-09-15  Richard Biener  <rguenther@suse.de>
889         * c-common.h (build_void_list_node): Remove.
890         * c-common.cc (c_common_nodes_and_builtins): Do not initialize
891         void_list_node.
893 2022-09-09  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
895         * c-format.cc (convert_format_name_to_system_name): Fix warning.
897 2022-09-07  Joseph Myers  <joseph@codesourcery.com>
899         * c-common.cc (c_common_reswords): Use D_C2X instead of D_CXXONLY
900         for alignas, alignof, bool, false, static_assert, thread_local and
901         true.
903 2022-09-07  Jakub Jelinek  <jakub@redhat.com>
905         * c.opt (Winvalid-utf8): Use ObjC instead of objC.  Remove
906         " in comments" from description.
907         (Wunicode): New option.
909 2022-09-06  Jakub Jelinek  <jakub@redhat.com>
911         PR c/106836
912         * c-omp.cc (c_omp_split_clauses): Handle OMP_CLAUSE_DOACROSS.
914 2022-09-03  Jakub Jelinek  <jakub@redhat.com>
916         * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DOACROSS.
917         * c-omp.cc (c_finish_omp_depobj): Check also for OMP_CLAUSE_DOACROSS
918         clause and diagnose it.  Don't handle OMP_CLAUSE_DEPEND_SOURCE and
919         OMP_CLAUSE_DEPEND_SINK.  Assert kind is not OMP_CLAUSE_DEPEND_INVALID.
921 2022-09-02  David Malcolm  <dmalcolm@redhat.com>
923         PR c/90885
924         * c-common.h (check_for_xor_used_as_pow): New decl.
925         * c-lex.cc (c_lex_with_flags): Add DECIMAL_INT to flags as appropriate.
926         * c-warn.cc (check_for_xor_used_as_pow): New.
927         * c.opt (Wxor-used-as-pow): New.
929 2022-09-01  Jason Merrill  <jason@redhat.com>
931         * c-common.cc (c_common_nodes_and_builtins): Set TREE_STRING_FLAG on
932         char8_t.
933         (braced_list_to_string): Check for char-sized elements.
935 2022-09-01  Jakub Jelinek  <jakub@redhat.com>
937         PR c++/106655
938         * c.opt (-Winvalid-utf8): New warning.
939         * c-opts.cc (c_common_handle_option) <case OPT_finput_charset_>:
940         Set cpp_opts->cpp_input_charset_explicit.
941         (c_common_post_options): If -finput-charset=UTF-8 is explicit
942         in C++23, enable -Winvalid-utf8 by default and if -pedantic
943         or -pedantic-errors, make it a pedwarn.
945 2022-08-31  Joseph Myers  <joseph@codesourcery.com>
947         * c-attribs.cc (handle_deprecated_attribute): Check and pedwarn
948         for LABEL_DECL.
949         * c-common.cc (c_add_case_label): Add argument ATTRS.  Call
950         decl_attributes.
951         * c-common.h (do_case, c_add_case_label): Update declarations.
952         * c-lex.cc (c_common_has_attribute): For C, produce a result of
953         201910 for fallthrough and 202106 for maybe_unused.
955 2022-08-26  Marek Polacek  <polacek@redhat.com>
957         PR c++/81159
958         * c.opt (Wself-move): New option.
960 2022-08-26  Jakub Jelinek  <jakub@redhat.com>
962         * c-common.cc (check_builtin_function_arguments): Handle
963         BUILT_IN_ISSIGNALING.
965 2022-08-26  Jakub Jelinek  <jakub@redhat.com>
967         PR c++/106648
968         * c-cppbuiltin.cc (c_cpp_builtins): Predefine
969         __cpp_named_character_escapes to 202207L.
971 2022-08-25  Marek Polacek  <polacek@redhat.com>
973         * c-common.cc (c_common_reswords): Enable nullptr in C2X.
974         (c_common_nodes_and_builtins): Create the built-in node for nullptr.
975         * c-common.h (enum c_tree_index): Add CTI_NULLPTR, CTI_NULLPTR_TYPE.
976         (struct c_common_resword): Resize the disable member.
977         (D_C2X): Add.
978         (nullptr_node): Define.
979         (nullptr_type_node): Define.
980         (NULLPTR_TYPE_P): Define.
981         * c-pretty-print.cc (c_pretty_printer::simple_type_specifier): Handle
982         NULLPTR_TYPE.
983         (c_pretty_printer::direct_abstract_declarator): Likewise.
984         (c_pretty_printer::constant): Likewise.
986 2022-08-16  Tom Honermann  <tom@honermann.net>
988         PR c++/106423
989         * c-opts.cc (c_common_post_options): Disable -Wc++20-compat
990         diagnostics in C++20 and later.
991         * c.opt (Wc++20-compat): Enable hooks for the preprocessor.
993 2022-08-11  Marek Polacek  <polacek@redhat.com>
995         PR middle-end/102633
996         * c-gimplify.cc (c_gimplify_expr) <case DECL_EXPR>: Don't call
997         suppress_warning here.
999 2022-08-08  Tom Honermann  <tom@honermann.net>
1001         PR preprocessor/106426
1002         * c-opts.cc (c_common_post_options): Assign cpp_opts->unsigned_utf8char
1003         subject to -fchar8_t, -fsigned-char, and/or -funsigned-char.
1005 2022-08-08  Tom Honermann  <tom@honermann.net>
1007         * c-lex.cc (lex_string, lex_charconst): Use char8_t as the type
1008         of CPP_UTF8CHAR and CPP_UTF8STRING when char8_t support is
1009         enabled.
1010         * c-opts.cc (c_common_post_options): Set flag_char8_t if
1011         targeting C2x.
1013 2022-07-31  Lewis Hyatt  <lhyatt@gmail.com>
1015         PR c++/66290
1016         * c-common.h: Rename global done_lexing to
1017         override_libcpp_locations.
1018         * c-common.cc (c_cpp_diagnostic): Likewise.
1019         * c-opts.cc (c_common_finish): Set override_libcpp_locations
1020         (formerly done_lexing) immediately prior to calling cpp_finish ().
1022 2022-07-27  Lewis Hyatt  <lhyatt@gmail.com>
1024         * c-ppoutput.cc (token_streamer::stream): Update input_location
1025         prior to streaming each token.
1027 2022-07-23  Immad Mir  <mirimmad@outlook.com>
1029         * c-attribs.cc: (c_common_attribute_table): add three new attributes
1030         namely: fd_arg, fd_arg_read and fd_arg_write.
1031         (handle_fd_arg_attribute): New.
1033 2022-07-15  Marek Polacek  <polacek@redhat.com>
1035         PR c++/104477
1036         * c-common.cc (c_common_reswords): Add
1037         __reference_constructs_from_temporary and
1038         __reference_converts_from_temporary.
1039         * c-common.h (enum rid): Add RID_REF_CONSTRUCTS_FROM_TEMPORARY and
1040         RID_REF_CONVERTS_FROM_TEMPORARY.
1042 2022-07-15  Jonathan Wakely  <jwakely@redhat.com>
1044         * c-format.cc (class range_label_for_format_type_mismatch):
1045         Adjust to new label_text API.
1047 2022-07-11  Lewis Hyatt  <lhyatt@gmail.com>
1049         PR preprocessor/106252
1050         * c-pragma.cc (handle_pragma_diagnostic_impl): Don't look up the
1051         option argument prior to verifying the option was found.
1053 2022-07-07  David Malcolm  <dmalcolm@redhat.com>
1055         * c-format.cc (range_label_for_format_type_mismatch::get_text):
1056         Update for removal of label_text::maybe_free in favor of automatic
1057         memory management.
1059 2022-07-06  Lewis Hyatt  <lhyatt@gmail.com>
1061         PR preprocessor/53920
1062         PR c++/53431
1063         * c-common.cc (c_option_is_from_cpp_diagnostics): New function.
1064         * c-common.h (c_option_is_from_cpp_diagnostics): Declare.
1065         (c_pp_stream_token): Declare.
1066         * c-ppoutput.cc (init_pp_output): Refactor logic about skipping
1067         pragmas to...
1068         (should_output_pragmas): ...here. New function.
1069         (token_streamer::stream): Support handling early pragmas.
1070         (do_line_change): Likewise.
1071         (c_pp_stream_token): New function.
1072         * c-pragma.cc (struct pragma_diagnostic_data): New helper class.
1073         (pragma_diagnostic_lex_normal): New function. Moved logic for
1074         interpreting GCC diagnostic pragmas here.
1075         (pragma_diagnostic_lex_pp): New function for parsing diagnostic pragmas
1076         directly from libcpp.
1077         (handle_pragma_diagnostic): Refactor into helper function...
1078         (handle_pragma_diagnostic_impl): ...here.  New function.
1079         (handle_pragma_diagnostic_early): New function.
1080         (handle_pragma_diagnostic_early_pp): New function.
1081         (struct pragma_ns_name): Renamed to...
1082         (struct pragma_pp_data): ...this.  Add new "early_handler" member.
1083         (c_register_pragma_1): Support early pragmas in the preprocessor.
1084         (c_register_pragma_with_early_handler): New function.
1085         (c_register_pragma): Support the new early handlers in struct
1086         internal_pragma_handler.
1087         (c_register_pragma_with_data): Likewise.
1088         (c_register_pragma_with_expansion): Likewise.
1089         (c_register_pragma_with_expansion_and_data): Likewise.
1090         (c_invoke_early_pragma_handler): New function.
1091         (c_pp_invoke_early_pragma_handler): New function.
1092         (init_pragma): Add early pragma support for diagnostic pragmas.
1093         * c-pragma.h (struct internal_pragma_handler): Add new early handler
1094         members.
1095         (c_register_pragma_with_early_handler): Declare.
1096         (c_invoke_early_pragma_handler): Declare.
1097         (c_pp_invoke_early_pragma_handler): Declare.
1099 2022-07-05  Marek Polacek  <polacek@redhat.com>
1101         PR c++/105626
1102         * c-format.cc (check_format_arg): Don't emit -Wformat warnings with
1103         u8 strings.
1105 2022-07-01  Marek Polacek  <polacek@redhat.com>
1107         PR c++/106111
1108         * c-common.h (enum rid): Update RID_LAST_CXX20.
1110 2022-06-30  Jonathan Wakely  <jwakely@redhat.com>
1112         * known-headers.cc (get_stdlib_header_for_name): Add <time.h>
1113         names.
1115 2022-06-24  Jason Merrill  <jason@redhat.com>
1117         PR c++/87729
1118         PR c++/20423
1119         * c.opt (Woverloaded-virtual): Add levels, include in -Wall.
1121 2022-06-18  Jakub Jelinek  <jakub@redhat.com>
1123         * c-ubsan.cc (ubsan_instrument_division, ubsan_instrument_shift):
1124         Use flag_sanitize_trap & SANITIZE_??? instead of
1125         flag_sanitize_undefined_trap_on_error.  If 2 sanitizers are involved
1126         and flag_sanitize_trap differs for them, emit __builtin_trap only
1127         for the comparison where trap is requested.
1128         (ubsan_instrument_vla, ubsan_instrument_return): Use
1129         lag_sanitize_trap & SANITIZE_??? instead of
1130         flag_sanitize_undefined_trap_on_error.
1132 2022-06-13  Jason Merrill  <jason@redhat.com>
1134         * c-ubsan.cc (ubsan_instrument_return): Use BUILTINS_LOCATION.
1136 2022-05-27  Marek Polacek  <polacek@redhat.com>
1138         PR c/90658
1139         * c-attribs.cc (get_priority): Check FUNCTION_DECL.
1141 2022-05-27  Jakub Jelinek  <jakub@redhat.com>
1143         * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ENTER.
1145 2022-05-20  David Malcolm  <dmalcolm@redhat.com>
1147         * c-format.cc: Replace uses of "FINAL" and "OVERRIDE" with "final"
1148         and "override".
1149         * c-pretty-print.h: Likewise.
1151 2022-05-18  Marek Polacek  <polacek@redhat.com>
1153         PR c/105131
1154         * c.opt (Wenum-int-mismatch): New.
1156 2022-05-18  Marek Polacek  <polacek@redhat.com>
1158         PR c++/105497
1159         * c-warn.cc (c_do_switch_warnings): Don't warn about unhandled
1160         enumerator when it was marked with attribute unused.
1162 2022-05-18  Eric Botcazou  <ebotcazou@adacore.com>
1164         * c-ada-spec.cc (dump_ada_node) <COMPLEX_TYPE>: Deal with usual
1165         floating-point complex types.
1166         <POINTER_TYPE>: Do not use limited_with clause if the designated
1167         type is a scalar type.
1169 2022-05-17  Jakub Jelinek  <jakub@redhat.com>
1171         * c-omp.cc (c_finish_omp_depobj): Handle
1172         OMP_CLAUSE_DEPEND_INOUTSET.
1174 2022-05-16  Jason Merrill  <jason@redhat.com>
1176         PR c/105492
1177         * c-attribs.cc (handle_mode_attribute): Don't fix broken typedefs
1178         here.
1180 2022-05-16  Martin Liska  <mliska@suse.cz>
1182         * c-common.cc (ARRAY_SIZE): Use ARRAY_SIZE.
1183         (c_common_nodes_and_builtins): Likewise.
1184         * c-format.cc (check_tokens): Likewise.
1185         (check_plain): Likewise.
1186         * c-pragma.cc (c_pp_lookup_pragma): Likewise.
1187         (init_pragma): Likewise.
1188         * known-headers.cc (get_string_macro_hint): Likewise.
1189         (get_stdlib_header_for_name): Likewise.
1190         * c-attribs.cc: Likewise.
1192 2022-05-13  Richard Biener  <rguenther@suse.de>
1194         * c-omp.cc: Remove gimple-fold.h include.
1196 2022-05-12  Jakub Jelinek  <jakub@redhat.com>
1198         * c-common.h (enum rid): Add RID_OMP_ALL_MEMORY.
1199         * c-omp.cc (c_finish_omp_depobj): Don't build_fold_addr_expr
1200         if null_pointer_node.
1202 2022-05-11  Martin Liska  <mliska@suse.cz>
1204         PR target/105355
1205         * c-opts.cc (c_common_handle_option): Change option name.
1206         * c.opt: Remove Joined and use Separate option.
1208 2022-05-09  Alex Coplan  <alex.coplan@arm.com>
1210         * c-common.h (get_dump_info): Delete.
1211         * c-gimplify.cc (c_genericize): Get TDI_original dump file info
1212         from the global dump_manager instead of the (now obsolete)
1213         get_dump_info.
1214         * c-opts.cc (original_dump_file): Delete.
1215         (original_dump_flags): Delete.
1216         (c_common_parse_file): Switch to using global dump_manager to
1217         manage the original dump file; fix leak of dump file.
1218         (get_dump_info): Delete.
1220 2022-05-07  Marek Polacek  <polacek@redhat.com>
1222         PR c++/101833
1223         PR c++/47634
1224         * c-attribs.cc (positional_argument): Pass POS by reference.  Deal
1225         with FN being either a function declaration or function type.  Use
1226         maybe_adjust_arg_pos_for_attribute.
1227         * c-common.cc (check_function_arguments): Maybe pass FNDECL down to
1228         check_function_format.
1229         * c-common.h (maybe_adjust_arg_pos_for_attribute): Declare.
1230         (positional_argument): Adjust.
1231         * c-format.cc (get_constant): Rename to ...
1232         (validate_constant): ... this.  Take EXPR by reference.  Return bool
1233         instead of tree.
1234         (handle_format_arg_attribute): Don't overwrite FORMAT_NUM_EXPR by the
1235         return value of validate_constant.
1236         (decode_format_attr): Don't overwrite FORMAT_NUM_EXPR and
1237         FIRST_ARG_NUM_EXPR by the return value of validate_constant.
1238         (check_function_format): Adjust a parameter name.
1239         (handle_format_attribute): Maybe pass FNDECL down to decode_format_attr.
1241 2022-05-04  Marek Polacek  <polacek@redhat.com>
1243         * c-warn.cc (warnings_for_convert_and_check): Convert constants of type
1244         char to int.
1246 2022-04-30  Jason Merrill  <jason@redhat.com>
1248         PR c/100545
1249         * c-attribs.cc (handle_mode_attribute): Copy attributes, aligned,
1250         and typedef.
1251         * c-common.cc (set_underlying_type): Add assert.
1253 2022-04-26  Patrick Palka  <ppalka@redhat.com>
1255         PR c++/105304
1256         * c-common.cc (verify_tree) [restart]: Move up to before the
1257         NULL test.
1259 2022-04-11  Jakub Jelinek  <jakub@redhat.com>
1261         PR c++/105186
1262         * c-common.cc (c_common_nodes_and_builtins): After registering __int%d
1263         and __int%d__ builtin types, initialize corresponding ridpointers
1264         entry.
1266 2022-03-30  Marek Polacek  <polacek@redhat.com>
1268         PR c++/101030
1269         * c-warn.cc (conversion_warning) <case COND_EXPR>: Don't call
1270         conversion_warning when OP1 is null.
1272 2022-03-30  Thomas Schwinge  <thomas@codesourcery.com>
1274         * c.opt (Wc++11-extensions, Wc++14-extensions, Wc++17-extensions)
1275         (Wc++20-extensions, Wc++23-extensions): Remove 'LangEnabledBy'
1276         option properties.
1278 2022-03-30  Thomas Schwinge  <thomas@codesourcery.com>
1280         * c.opt (Wuse-after-free): Remove.
1282 2022-03-30  Thomas Schwinge  <thomas@codesourcery.com>
1284         * c.opt (Warray-bounds): Remove.
1286 2022-03-26  Thomas Schwinge  <thomas@codesourcery.com>
1288         * c.opt: Properly quote comment.
1290 2022-03-25  Eric Botcazou  <ebotcazou@adacore.com>
1292         * c-ada-spec.cc (dump_ada_import): Deal with the "section" attribute
1293         (dump_ada_node) <POINTER_TYPE>: Do not modify and pass the name, but
1294         the referenced type instead.  Deal with the anonymous original type
1295         of a typedef'ed type.  In the actual access case, follow the chain
1296         of external subtypes.
1297         <TYPE_DECL>: Tidy up control flow.
1299 2022-03-21  Qian Jianhua  <qianjh@cn.fujitsu.com>
1301         * c-ada-spec.cc: Change array length
1303 2022-03-19  Arthur Cohen  <arthur.cohen@embecosm.com>
1305         * c-common.cc (c_family_tests): Call the new tests.
1306         * c-common.h (c_diagnostic_tests): Declare.
1307         (c_opt_problem_cc_tests): Likewise.
1309 2022-03-19  Jakub Jelinek  <jakub@redhat.com>
1311         PR c++/101515
1312         * c-pretty-print.cc (c_fold_indirect_ref_for_warn): For C++ don't
1313         return COMPONENT_REFs with FIELD_DECLs whose containing scope can't
1314         be printed.
1316 2022-03-16  Christophe Lyon  <christophe.lyon@arm.com>
1317             Roger Sayle  <roger@nextmovesoftware.com>
1319         PR c/98198
1320         * c-attribs.cc (decl_or_type_attrs): Add error_mark_node check.
1322 2022-03-16  Patrick Palka  <ppalka@redhat.com>
1324         PR c++/96780
1325         * c.opt: Add -ffold-simple-inlines.
1327 2022-03-13  Tobias Burnus  <tobias@codesourcery.com>
1329         * c-target.def (check_string_object_format_arg): Fix description typo.
1331 2022-03-12  Thomas Schwinge  <thomas@codesourcery.com>
1333         PR other/65095
1334         * c-common.h (c_omp_map_clause_name): Remove.
1335         * c-omp.cc (c_omp_map_clause_name): Remove.
1337 2022-03-09  Jakub Jelinek  <jakub@redhat.com>
1339         PR c/104711
1340         * c-opts.cc (c_common_post_options): Don't enable
1341         -Wshift-negative-value from -Wextra for C++20 or later.
1342         * c-ubsan.cc (ubsan_instrument_shift): Adjust comments.
1343         * c-warn.cc (maybe_warn_shift_overflow): Use TYPE_OVERFLOW_WRAPS
1344         instead of TYPE_UNSIGNED.
1346 2022-03-07  Jakub Jelinek  <jakub@redhat.com>
1348         * c-attribs.cc: Fix up duplicated word issue in a comment.
1350 2022-03-01  Martin Liska  <mliska@suse.cz>
1352         PR ipa/104533
1353         * c-attribs.cc (handle_target_clones_attribute): Use
1354         get_target_clone_attr_len and report warning soon.
1356 2022-02-17  Jonathan Wakely  <jwakely@redhat.com>
1358         * c-pragma.cc (handle_pragma_pack): Remove parameter name.
1359         (handle_pragma_weak): Likewise.
1360         (handle_pragma_scalar_storage_order): Likewise.
1361         (handle_pragma_redefine_extname): Likewise.
1362         (handle_pragma_visibility): Likewise.
1363         (handle_pragma_diagnostic): Likewise.
1364         (handle_pragma_target): Likewise.
1365         (handle_pragma_optimize): Likewise.
1366         (handle_pragma_push_options): Likewise.
1367         (handle_pragma_pop_options): Likewise.
1368         (handle_pragma_reset_options): Likewise.
1369         (handle_pragma_message): Likewise.
1370         (handle_pragma_float_const_decimal64): Likewise.
1372 2022-02-16  Jakub Jelinek  <jakub@redhat.com>
1374         PR c/104531
1375         * c-omp.cc (c_finish_omp_atomic): For MIN_EXPR/MAX_EXPR, try first
1376         build_binary_op with LT_EXPR and only if that doesn't return
1377         error_mark_node call build_modify_expr.
1379 2022-02-16  Jakub Jelinek  <jakub@redhat.com>
1381         PR c/104510
1382         * c-common.cc (shorten_compare): Convert original arguments to
1383         the original *restype_ptr when mixing binary and decimal float.
1385 2022-02-14  Richard Biener  <rguenther@suse.de>
1387         PR c/104505
1388         * c-pretty-print.cc (c_pretty_printer::postfix_expression): Handle
1389         internal function calls.
1391 2022-02-11  Richard Biener  <rguenther@suse.de>
1393         * c-attribs.cc (c_common_attribute_table): Add entry for
1394         vector_mask.
1395         (handle_vector_mask_attribute): New.
1397 2022-02-10  Marcel Vollweiler  <marcel@codesourcery.com>
1399         * c-omp.cc (c_omp_split_clauses): Added OMP_CLAUSE_HAS_DEVICE_ADDR case.
1400         * c-pragma.h (enum pragma_kind): Added 5.1 in comment.
1401         (enum pragma_omp_clause): Added PRAGMA_OMP_CLAUSE_HAS_DEVICE_ADDR.
1403 2022-02-09  Jason Merrill  <jason@redhat.com>
1405         * c-cppbuiltin.cc (c_cpp_builtins): Update values
1406         of __cpp_constexpr and __cpp_concepts for C++20.
1408 2022-01-24  Marek Polacek  <polacek@redhat.com>
1410         PR preprocessor/104030
1411         * c.opt (Wbidi-chars): Mark as EnumSet.  Also accept =ucn.
1413 2022-01-21  Jakub Jelinek  <jakub@redhat.com>
1415         PR c++/104148
1416         * c-common.h (check_function_arguments_recurse): Add for_format
1417         arg.
1418         * c-common.cc (check_function_nonnull): Pass false to
1419         check_function_arguments_recurse's last argument.
1420         (check_function_arguments_recurse): Add for_format argument,
1421         if true, don't stop on warning_suppressed_p.
1422         * c-format.cc (check_format_info): Pass true to
1423         check_function_arguments_recurse's last argument.
1425 2022-01-19  David Malcolm  <dmalcolm@redhat.com>
1427         * c-common.cc (c_common_c_tests): Rename to...
1428         (c_common_cc_tests): ...this.
1429         (c_family_tests): Update calls for .c to .cc renaming.
1430         * c-common.h (c_format_c_tests): Rename to...
1431         (c_format_cc_tests): ...this.
1432         (c_indentation_c_tests): Rename to...
1433         (c_indentation_cc_tests): ...this.
1434         (c_pretty_print_c_tests): Rename to...
1435         (c_pretty_print_cc_tests): ...this.
1436         * c-format.cc (c_format_c_tests): Rename to...
1437         (c_format_cc_tests): ...this.
1438         * c-indentation.cc (c_indentation_c_tests): Rename to...
1439         (c_indentation_cc_tests): ...this.
1440         * c-pretty-print.cc (c_pretty_print_c_tests): Rename to...
1441         (c_pretty_print_cc_tests): ...this.
1443 2022-01-17  Martin Liska  <mliska@suse.cz>
1445         * c-ada-spec.cc: Rename .c names to .cc.
1446         * c-ada-spec.h: Likewise.
1447         * c-common.cc (c_build_vec_convert): Likewise.
1448         (warning_candidate_p): Likewise.
1449         * c-common.h (enum rid): Likewise.
1450         (build_real_imag_expr): Likewise.
1451         (finish_label_address_expr): Likewise.
1452         (c_get_substring_location): Likewise.
1453         (c_build_bind_expr): Likewise.
1454         (conflict_marker_get_final_tok_kind): Likewise.
1455         (c_parse_error): Likewise.
1456         (check_missing_format_attribute): Likewise.
1457         (invalid_array_size_error): Likewise.
1458         (warn_for_multistatement_macros): Likewise.
1459         (build_attr_access_from_parms): Likewise.
1460         * c-cppbuiltin.cc (c_cpp_builtins): Likewise.
1461         * c-format.cc: Likewise.
1462         * c-gimplify.cc (c_gimplify_expr): Likewise.
1463         * c-indentation.h: Likewise.
1464         * c-objc.h (objc_prop_attr_kind_for_rid): Likewise.
1465         * c-omp.cc (c_omp_predetermined_mapping): Likewise.
1466         * c-opts.cc (c_common_post_options): Likewise.
1467         (set_std_cxx23): Likewise.
1468         * c-pragma.cc (handle_pragma_redefine_extname): Likewise.
1469         * c-pretty-print.h: Likewise.
1471 2022-01-17  Martin Liska  <mliska@suse.cz>
1473         * c-ada-spec.c: Moved to...
1474         * c-ada-spec.cc: ...here.
1475         * c-attribs.c: Moved to...
1476         * c-attribs.cc: ...here.
1477         * c-common.c: Moved to...
1478         * c-common.cc: ...here.
1479         * c-cppbuiltin.c: Moved to...
1480         * c-cppbuiltin.cc: ...here.
1481         * c-dump.c: Moved to...
1482         * c-dump.cc: ...here.
1483         * c-format.c: Moved to...
1484         * c-format.cc: ...here.
1485         * c-gimplify.c: Moved to...
1486         * c-gimplify.cc: ...here.
1487         * c-indentation.c: Moved to...
1488         * c-indentation.cc: ...here.
1489         * c-lex.c: Moved to...
1490         * c-lex.cc: ...here.
1491         * c-omp.c: Moved to...
1492         * c-omp.cc: ...here.
1493         * c-opts.c: Moved to...
1494         * c-opts.cc: ...here.
1495         * c-pch.c: Moved to...
1496         * c-pch.cc: ...here.
1497         * c-ppoutput.c: Moved to...
1498         * c-ppoutput.cc: ...here.
1499         * c-pragma.c: Moved to...
1500         * c-pragma.cc: ...here.
1501         * c-pretty-print.c: Moved to...
1502         * c-pretty-print.cc: ...here.
1503         * c-semantics.c: Moved to...
1504         * c-semantics.cc: ...here.
1505         * c-ubsan.c: Moved to...
1506         * c-ubsan.cc: ...here.
1507         * c-warn.c: Moved to...
1508         * c-warn.cc: ...here.
1509         * cppspec.c: Moved to...
1510         * cppspec.cc: ...here.
1511         * stub-objc.c: Moved to...
1512         * stub-objc.cc: ...here.
1514 2022-01-15  Martin Sebor  <msebor@redhat.com>
1516         PR c/63272
1517         * c.opt (-Wdangling-pointer): New option.
1519 2022-01-15  Martin Sebor  <msebor@redhat.com>
1521         PR tree-optimization/80532
1522         * c.opt (-Wuse-after-free): New options.
1524 2022-01-14  David Malcolm  <dmalcolm@redhat.com>
1526         * c-attribs.c (c_common_attribute_table): Add "tainted_args".
1527         (handle_tainted_args_attribute): New.
1529 2022-01-13  Anthony Sharp  <anthonysharp15@gmail.com>
1530             Jason Merrill  <jason@redhat.com>
1532         PR c++/70417
1533         * c.opt: Added -Wmissing-template-keyword.
1535 2022-01-13  Richard Biener  <rguenther@suse.de>
1537         PR c/104002
1538         * c-common.c (c_common_mark_addressable_vec): Handle TARGET_EXPR.
1540 2022-01-12  Martin Liska  <mliska@suse.cz>
1542         PR target/103804
1543         * c-attribs.c (handle_optimize_attribute): Do not call
1544         cl_optimization_compare if we seen an error.
1546 2022-01-11  Jakub Jelinek  <jakub@redhat.com>
1548         PR c/101537
1549         PR c/103881
1550         * c-warn.c (conversion_warning): Handle BIT_AND_EXPR, BIT_IOR_EXPR
1551         and BIT_XOR_EXPR.
1553 2022-01-10  Richard Biener  <rguenther@suse.de>
1555         PR middle-end/101530
1556         * c-common.c (c_build_shufflevector): Wrap the BIT_FIELD_REF
1557         in a TARGET_EXPR to force a temporary.
1559 2022-01-06  Marek Polacek  <polacek@redhat.com>
1561         PR c++/103758
1562         * c-pragma.c (handle_pragma_scalar_storage_order): Use %< %> in
1563         diagnostic messages.
1564         (handle_pragma_diagnostic): Likewise.
1566 2022-01-03  Marek Polacek  <polacek@redhat.com>
1568         PR c++/103758
1569         * c-format.c (check_tokens): Accept "decl-specifier*".
1571 2022-01-03  Jakub Jelinek  <jakub@redhat.com>
1573         PR c++/103600
1574         * c-attribs.c (handle_non_overlapping_attribute): New function.
1575         (c_common_attribute_table): Add "non overlapping" attribute.
1577 2021-12-30  Jakub Jelinek  <jakub@redhat.com>
1579         PR c++/103012
1580         * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Perform
1581         cpp_define_unused/cpp_undef calls with forced token locations
1582         BUILTINS_LOCATION.
1584 2021-12-27  Patrick Palka  <ppalka@redhat.com>
1586         PR c++/103700
1587         * c-common.c (pointer_int_sum): When quiet, return
1588         error_mark_node for an incomplete pointed-to type and don't
1589         call size_in_bytes_loc.
1591 2021-12-17  Jason Merrill  <jason@redhat.com>
1593         PR c++/103681
1594         * c-opts.c (c_common_post_options): Update defaults.
1596 2021-12-16  Martin Liska  <mliska@suse.cz>
1598         PR target/103709
1599         * c-pragma.c (handle_pragma_pop_options): Do not check
1600         global options modification when an error is seen in parsing
1601         of options (pragmas or attributes).
1603 2021-12-12  Jonathan Wakely  <jwakely@redhat.com>
1605         * known-headers.cc: Define INCLUDE_MEMORY instead of
1606         INCLUDE_UNIQUE_PTR.
1607         * name-hint.h: Likewise.
1608         (class name_hint): Use std::unique_ptr instead of gnu::unique_ptr.
1610 2021-12-09  Jakub Jelinek  <jakub@redhat.com>
1612         PR pch/71934
1613         * c-pch.c (c_common_no_more_pch): Pass a temporary void * var
1614         with NULL value instead of NULL to host_hooks.gt_pch_use_address.
1616 2021-12-03  Jakub Jelinek  <jakub@redhat.com>
1618         PR pch/71934
1619         * c-pch.c (struct c_pch_validity): Remove pch_init member.
1620         (pch_init): Don't initialize v.pch_init.
1621         (c_common_valid_pch): Don't warn and punt if .text addresses change.
1623 2021-12-01  Jason Merrill  <jason@redhat.com>
1625         PR c++/103310
1626         * c.opt: Add -fconstexpr-fp-except.
1628 2021-11-29  Richard Biener  <rguenther@suse.de>
1630         * c-format.c (check_format_string): Remove spurious
1631         gcc_unreachable.
1633 2021-11-29  Richard Biener  <rguenther@suse.de>
1635         * c-opts.c (c_common_post_options): Remove unreachable return.
1636         * c-pragma.c (handle_pragma_target): Likewise.
1637         (handle_pragma_optimize): Likewise.
1639 2021-11-25  Jakub Jelinek  <jakub@redhat.com>
1641         PR c++/102611
1642         * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
1643         default for C++23 regardless of warn_deprecated.
1644         * c-cppbuiltin.c (c_cpp_builtins): Predefine
1645         __cpp_multidimensional_subscript=202110L for C++23.
1647 2021-11-23  Martin Sebor  <msebor@redhat.com>
1649         PR middle-end/88232
1650         * c.opt: Add -Winfinite-recursion.
1652 2021-11-19  Martin Sebor  <msebor@redhat.com>
1654         PR c++/33925
1655         PR c/102867
1656         * c-common.c (decl_with_nonnull_addr_p): Call maybe_nonzero_address
1657         and improve handling tof defined symbols.
1659 2021-11-19  Martin Liska  <mliska@suse.cz>
1661         Revert:
1662         2021-11-18  Martin Liska  <mliska@suse.cz>
1664         * c-gimplify.c (genericize_c_loop): Use option directly.
1666 2021-11-18  Matthias Kretz  <m.kretz@gsi.de>
1668         * c-common.c (c_common_reswords): Add __builtin_assoc_barrier.
1669         * c-common.h (enum rid): Add RID_BUILTIN_ASSOC_BARRIER.
1671 2021-11-18  Martin Liska  <mliska@suse.cz>
1673         * c-gimplify.c (genericize_c_loop): Use option directly.
1675 2021-11-17  Martin Uecker  <uecker@gcc.gnu.org>
1677         PR c/91038
1678         PR c/29970
1679         * c-common.c (pointer_int_sum): Make sure pointer expressions
1680         are evaluated first when the size expression depends on for
1681         variably-modified types.
1683 2021-11-17  Marek Polacek  <polacek@redhat.com>
1685         PR preprocessor/103026
1686         * c.opt (Wbidi-chars, Wbidi-chars=): New option.
1688 2021-11-16  Jason Merrill  <jason@redhat.com>
1690         * c-common.c (release_tree_vector): Only cache vecs smaller than
1691         16 elements.
1693 2021-11-15  Jason Merrill  <jason@redhat.com>
1695         * c.opt: Add -fimplicit-constexpr.
1696         * c-cppbuiltin.c: Define __cpp_implicit_constexpr.
1697         * c-opts.c (c_common_post_options): Disable below C++14.
1699 2021-11-15  Jakub Jelinek  <jakub@redhat.com>
1701         * c-omp.c (c_omp_split_clauses) <case OMP_CLAUSE_THREAD_LIMIT>:
1702         Duplicate to both OMP_TARGET and OMP_TEAMS.
1704 2021-11-10  Marek Polacek  <polacek@redhat.com>
1706         PR c++/101940
1707         * c-pragma.c (handle_pragma_diagnostic): Handle #pragma GCC diagnostic
1708         ignored_attributes.
1710 2021-11-09  David Malcolm  <dmalcolm@redhat.com>
1712         * c-pragma.c (GCC_BAD_AT): New macro.
1713         (GCC_BAD2_AT): New macro.
1714         (handle_pragma_pack): Use the location of the pertinent token when
1715         issuing diagnostics about invalid constants/actions, and trailing
1716         junk.
1717         (handle_pragma_target): Likewise for non-string "GCC option".
1718         (handle_pragma_message): Likewise for trailing junk.
1720 2021-11-03  Joseph Myers  <joseph@codesourcery.com>
1722         PR c/103031
1723         * c-common.c (convert_and_check): Add argument init_const.  Call
1724         convert_init if init_const.
1725         * c-common.h (convert_and_check): Update prototype.
1726         (convert_init): New prototype.
1728 2021-11-01  David Malcolm  <dmalcolm@redhat.com>
1730         * c-lex.c (c_lex_with_flags): When complaining about non-printable
1731         CPP_OTHER tokens, set the "escape on output" flag.
1733 2021-10-27  Jakub Jelinek  <jakub@redhat.com>
1735         * c-omp.c (c_omp_check_loop_iv_r): Don't clear 3rd bit for
1736         POINTER_PLUS_EXPR.
1737         (c_omp_check_nonrect_loop_iv): Handle POINTER_PLUS_EXPR.
1738         (c_omp_check_loop_iv): Set kind even if the iterator is non-integral.
1740 2021-10-27  Jakub Jelinek  <jakub@redhat.com>
1742         PR c++/102854
1743         * c-common.h (c_omp_check_loop_iv_exprs): Add enum tree_code argument.
1744         * c-omp.c (c_omp_check_loop_iv_r): For trees other than decls,
1745         TREE_VEC, PLUS_EXPR, MINUS_EXPR, MULT_EXPR, POINTER_PLUS_EXPR or
1746         conversions temporarily clear the 3rd bit from d->kind while walking
1747         subtrees.
1748         (c_omp_check_loop_iv_exprs): Add CODE argument.  Or in 4 into data.kind
1749         if possibly non-rectangular.
1751 2021-10-21  Jakub Jelinek  <jakub@redhat.com>
1753         PR middle-end/64888
1754         * c-omp.c (c_omp_predefined_variable): Return true also for
1755         ubsan_create_data created artificial variables.
1757 2021-10-14  Joseph Myers  <joseph@codesourcery.com>
1759         * c-format.c (printf_length_specs, scanf_length_specs)
1760         (print_char_table, scan_char_table): Support DFP formats for C2X.
1761         * c-format.h (TEX_D32, TEX_D64, TEX_D128): Remove.
1762         (T2X_D32, T2X_D64, T2X_D128): New macros.
1764 2021-10-14  Kwok Cheung Yeung  <kcy@codesourcery.com>
1766         * c-omp.c (c_omp_check_context_selector): Rename to
1767         omp_check_context_selector and move to omp-general.c.
1768         (c_omp_mark_declare_variant): Rename to omp_mark_declare_variant and
1769         move to omp-general.c.
1771 2021-10-12  Joseph Myers  <joseph@codesourcery.com>
1773         * c-format.c (print_char_table): Add %b and %B formats.
1774         (scan_char_table): Add %b format.
1775         * c-format.h (T2X_UI, T2X_UL, T2X_ULL, T2X_US, T2X_UC, T2X_ST)
1776         (T2X_UPD, T2X_UIM): New macros.
1778 2021-10-12  Jakub Jelinek  <jakub@redhat.com>
1780         * c-omp.c (c_finish_omp_atomic): Use
1781         clear_padding_type_may_have_padding_p.
1783 2021-10-08  Martin Liska  <mliska@suse.cz>
1785         * c-opts.c (c_common_post_options): Use new macro
1786         OPTION_SET_P.
1788 2021-10-07  Martin Liska  <mliska@suse.cz>
1790         * c-common.c (parse_optimize_options): Make
1791         save_opt_decoded_options a pointer type.
1793 2021-10-06  Jakub Jelinek  <jakub@redhat.com>
1795         PR tree-optimization/102571
1796         * c-omp.c (c_finish_omp_atomic): Optimize the case where type has
1797         padding, but the non-padding bits are contiguous set of bytes
1798         by adjusting the memcmp call arguments instead of emitting
1799         __builtin_clear_padding and then comparing all the type's bytes.
1801 2021-10-06  Jakub Jelinek  <jakub@redhat.com>
1803         PR c++/102612
1804         * c-cppbuiltin.c (c_cpp_builtins): For -std=c++23 predefine
1805         __cpp_constexpr to 202110L rather than 201907L.
1807 2021-10-04  Marek Polacek  <polacek@redhat.com>
1809         PR c++/97573
1810         * c-common.h (do_warn_array_compare): Declare.
1811         * c-warn.c (do_warn_array_compare): New.
1812         * c.opt (Warray-compare): New option.
1814 2021-10-02  Iain Sandoe  <iain@sandoe.co.uk>
1816         * c-format.c: Remove a test of TARGET_FORMAT_TYPES with
1817         NULL, this is not needed.
1819 2021-10-01  Martin Sebor  <msebor@redhat.com>
1821         PR c/102103
1822         * c-common.c (decl_with_nonnull_addr_p): Handle members.
1823         Check and perform warning suppression.
1824         (c_common_truthvalue_conversion): Enhance warning suppression.
1826 2021-10-01  Martin Liska  <mliska@suse.cz>
1828         PR target/102552
1829         * c-common.c (parse_optimize_options): decoded_options[0] is
1830         used for program name, so merged_decoded_options should also
1831         respect that.
1833 2021-10-01  Jakub Jelinek  <jakub@redhat.com>
1834             Richard Biener  <rguenther@suse.de>
1836         PR sanitizer/102515
1837         * c-ubsan.c (ubsan_instrument_division): Check the right
1838         flag_sanitize_recover bit, depending on which sanitization
1839         is done.  Sanitize INT_MIN / -1 under SANITIZE_SI_OVERFLOW
1840         rather than SANITIZE_DIVIDE.  If both SANITIZE_SI_OVERFLOW
1841         and SANITIZE_DIVIDE is enabled, neither check is known
1842         to be false and flag_sanitize_recover bits for those two
1843         aren't the same, emit both __ubsan_handle_divrem_overflow
1844         and __ubsan_handle_divrem_overflow_abort calls.
1846 2021-10-01  Martin Liska  <mliska@suse.cz>
1848         * c-common.c (parse_optimize_options): Combine optimize
1849         options with what was provided on the command line.
1851 2021-10-01  Jakub Jelinek  <jakub@redhat.com>
1853         * c-omp.c (c_omp_split_clauses): Also copy
1854         OMP_CLAUSE_ORDER_REPRODUCIBLE.
1856 2021-09-27  Martin Liska  <mliska@suse.cz>
1858         * c-opts.c (c_common_init_options_struct): Set also
1859         x_flag_default_complex_method.
1861 2021-09-22  Jakub Jelinek  <jakub@redhat.com>
1863         * c-omp.c (c_omp_split_clauses): Copy over OMP_CLAUSE_ALLOCATE_ALIGN.
1865 2021-09-20  Matthias Kretz  <m.kretz@gsi.de>
1867         * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define or
1868         undefine __RECIPROCAL_MATH__, __NO_SIGNED_ZEROS__,
1869         __NO_TRAPPING_MATH__, __ASSOCIATIVE_MATH__, and
1870         __ROUNDING_MATH__ according to the new optimization flags.
1872 2021-09-18  Jakub Jelinek  <jakub@redhat.com>
1874         * c-omp.c (c_omp_split_clauses): Split order clause also to
1875         distribute construct.  Copy over OMP_CLAUSE_ORDER_UNCONSTRAINED.
1877 2021-09-17  Jakub Jelinek  <jakub@redhat.com>
1879         * c-omp.c (c_finish_omp_atomic): Avoid creating
1880         TARGET_EXPR if test is true, use create_tmp_var_raw instead of
1881         create_tmp_var and add a zero initializer to TARGET_EXPRs that
1882         had NULL initializer.  When omitting operands after v = x,
1883         use type of v rather than type of x.  Fix type of vtmp
1884         TARGET_EXPR.
1886 2021-09-13  Jason Merrill  <jason@redhat.com>
1888         * c.opt: Add -Winterference-size.
1889         * c-cppbuiltin.c (cpp_atomic_builtins): Add __GCC_DESTRUCTIVE_SIZE
1890         and __GCC_CONSTRUCTIVE_SIZE.
1892 2021-09-10  Jakub Jelinek  <jakub@redhat.com>
1894         * c-common.h (c_finish_omp_atomic): Add r and weak arguments.
1895         * c-omp.c: Include gimple-fold.h.
1896         (c_finish_omp_atomic): Add r and weak arguments.  Add support for
1897         OpenMP 5.1 atomics.
1899 2021-09-09  qing zhao  <qing.zhao@oracle.com>
1901         * c-attribs.c (handle_uninitialized_attribute): New function.
1902         (c_common_attribute_table): Add "uninitialized" attribute.
1904 2021-09-08  liuhongt  <hongtao.liu@intel.com>
1906         * c-common.c (excess_precision_mode_join): Update below comments.
1907         (c_ts18661_flt_eval_method): Set excess_precision_type to
1908         EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
1909         * c-cppbuiltin.c (cpp_atomic_builtins): Update below comments.
1910         (c_cpp_flt_eval_method_iec_559): Set excess_precision_type to
1911         EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
1913 2021-09-07  Marcel Vollweiler  <marcel@codesourcery.com>
1915         * c-omp.c (c_finish_omp_flush): Handle MEMMODEL_SEQ_CST.
1917 2021-09-03  Eric Botcazou  <ebotcazou@adacore.com>
1919         * c-ada-spec.c (dump_ads): Generate pragmas to disable style checks
1920         and -gnatwu warning for the package specification.
1922 2021-09-01  Iain Sandoe  <iain@sandoe.co.uk>
1924         * c-attribs.c (handle_unavailable_attribute): New.
1926 2021-08-30  Jason Merrill  <jason@redhat.com>
1928         * c.opt: Add -Wmissing-requires.
1930 2021-08-25  Lewis Hyatt  <lhyatt@gmail.com>
1932         PR other/93067
1933         * c-opts.c (c_common_input_charset_cb): New function.
1934         (c_common_post_options): Call new function
1935         diagnostic_initialize_input_context().
1937 2021-08-20  Tobias Burnus  <tobias@codesourcery.com>
1939         * c-format.c (gcc_gfc_length_specs): Add 'll' and 'w'.
1940         (gcc_gfc_char_table): Add T9L_LL and T9L_ULL to
1941         "di" and "u", respecitively; fill with BADLEN to match
1942         size of 'types'.
1943         (get_init_dynamic_hwi): Split off from ...
1944         (init_dynamic_diag_info): ... here. Call it.
1945         (init_dynamic_gfc_info): Call it.
1947 2021-08-20  Jakub Jelinek  <jakub@redhat.com>
1949         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ERROR.
1950         * c-pragma.c (omp_pragmas): Add error directive.
1951         * c-omp.c (omp_directives): Uncomment error directive entry.
1953 2021-08-18  Jakub Jelinek  <jakub@redhat.com>
1955         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_NOTHING.
1956         * c-pragma.c (omp_pragmas): Add nothing directive.
1957         * c-omp.c (omp_directives): Uncomment nothing directive entry.
1959 2021-08-17  Jakub Jelinek  <jakub@redhat.com>
1961         PR c++/101539
1962         * c-common.h (enum rid): Add RID_IS_LAYOUT_COMPATIBLE.
1963         * c-common.c (c_common_reswords): Add __is_layout_compatible.
1965 2021-08-17  Matt Jacobson  <mhjacobson@me.com>
1967         * c-opts.c (c_common_post_options): Default to
1968         flag_objc_sjlj_exceptions = 1 only when flag_objc_abi < 2.
1970 2021-08-17  Jakub Jelinek  <jakub@redhat.com>
1972         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCOPE.
1973         * c-pragma.c (omp_pragmas): Add scope construct.
1974         * c-omp.c (omp_directives): Uncomment scope directive entry.
1976 2021-08-16  Sebastian Huber  <sebastian.huber@embedded-brains.de>
1978         * c-cppbuiltin.c (c_cpp_builtins): Define
1979         __LIBGCC_GCOV_TYPE_SIZE if flag_building_libgcc is true.
1981 2021-08-12  Jakub Jelinek  <jakub@redhat.com>
1983         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_MASKED.
1984         (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FILTER.
1985         * c-pragma.c (omp_pragmas_simd): Add masked construct.
1986         * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_MASKED
1987         enumerator.
1988         (c_finish_omp_masked): Declare.
1989         * c-omp.c (c_finish_omp_masked): New function.
1990         (c_omp_split_clauses): Handle combined masked constructs.
1992 2021-07-30  Jakub Jelinek  <jakub@redhat.com>
1994         PR c++/101539
1995         * c-common.h (enum rid): Add RID_IS_POINTER_INTERCONVERTIBLE_BASE_OF.
1996         * c-common.c (c_common_reswords): Add
1997         __is_pointer_interconvertible_base_of.
1999 2021-07-29  Richard Biener  <rguenther@suse.de>
2001         PR c/101512
2002         * c-common.c (c_common_mark_addressable_vec): Look through
2003         C_MAYBE_CONST_EXPR even if not at the toplevel.
2005 2021-07-27  Martin Sebor  <msebor@redhat.com>
2007         PR c/101585
2008         * c-warn.c (warn_parm_ptrarray_mismatch): Use OEP_DECL_NAME.
2010 2021-07-23  Jakub Jelinek  <jakub@redhat.com>
2012         * c-lex.c (c_common_has_attribute): Call canonicalize_attr_name also
2013         on attr_id.  Return 1 for omp::directive or omp::sequence in C++11
2014         and later.
2016 2021-07-23  Jakub Jelinek  <jakub@redhat.com>
2018         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP__START_ and
2019         PRAGMA_OMP__LAST_ enumerators.
2021 2021-07-21  Thomas Schwinge  <thomas@codesourcery.com>
2022             Joseph Myers  <joseph@codesourcery.com>
2023             Cesar Philippidis  <cesar@codesourcery.com>
2025         * c-pragma.h (pragma_omp_clause): Add 'PRAGMA_OACC_CLAUSE_NOHOST'.
2027 2021-07-20  Martin Sebor  <msebor@redhat.com>
2029         * c-common.c (c_build_shufflevector): Adjust by-value argument to
2030         by-const-reference.
2031         * c-common.h (c_build_shufflevector): Same.
2033 2021-07-16  Andrew Pinski  <apinski@marvell.com>
2035         PR c/101453
2036         * c-common.c (parse_optimize_options): Use the correct
2037         size for buffer.
2039 2021-07-15  Martin Sebor  <msebor@redhat.com>
2041         PR c/101289
2042         PR c/97548
2043         * c-warn.c (warn_parm_array_mismatch): Use OEP_DECL_NAME.
2045 2021-07-14  Jason Merrill  <jason@redhat.com>
2047         * c-opts.c (c_common_post_options): Set -fdelete-dead-exceptions.
2049 2021-07-06  Martin Sebor  <msebor@redhat.com>
2051         * c-format.c (gcc_tdiag_char_table): Remove support for %G and %K.
2052         (gcc_cdiag_char_table): Same.
2053         (gcc_cxxdiag_char_table): Same.
2055 2021-07-02  Jakub Jelinek  <jakub@redhat.com>
2057         * c-common.h (enum c_omp_directive_kind): New enum.
2058         (struct c_omp_directive): New type.
2059         (c_omp_categorize_directive): Declare.
2060         * c-omp.c (omp_directives): New variable.
2061         (c_omp_categorize_directive): New function.
2063 2021-07-01  Eric Botcazou  <ebotcazou@adacore.com>
2065         * c-ada-spec.c (packed_layout): New global variable.
2066         (dump_ada_declaration): Set it upon seeing a packed record type.
2067         Do not put the "aliased" keyword if it is set.
2068         (dump_ada_structure): Add Pack aspect if it is set and clear it.
2070 2021-07-01  Eric Botcazou  <ebotcazou@adacore.com>
2072         * c-ada-spec.c (check_name): Rename into...
2073         (check_type_name_conflict): ...this.  Minor tweak.
2074         (dump_ada_function_declaration): Adjust to above renaming.
2075         (dump_ada_array_domains): Fix oversight.
2076         (dump_ada_declaration): Call check_type_name_conflict for variables.
2078 2021-06-25  Martin Sebor  <msebor@redhat.com>
2080         * c-common.c (c_wrap_maybe_const): Remove TREE_NO_WARNING.
2081         (c_common_truthvalue_conversion): Replace direct uses of
2082         TREE_NO_WARNING with warning_suppressed_p, suppress_warning, and
2083         copy_no_warning.
2084         (check_function_arguments_recurse): Same.
2085         * c-gimplify.c (c_gimplify_expr): Same.
2086         * c-warn.c (overflow_warning): Same.
2087         (warn_logical_operator): Same.
2088         (warn_if_unused_value): Same.
2089         (do_warn_unused_parameter): Same.
2091 2021-06-24  Jakub Jelinek  <jakub@redhat.com>
2093         * c-common.h (enum c_omp_region_type): Add C_ORT_TARGET and
2094         C_ORT_OMP_TARGET.
2095         * c-omp.c (c_omp_split_clauses): For OMP_CLAUSE_IN_REDUCTION on
2096         combined target constructs also add map (always, tofrom:) clause.
2098 2021-06-15  Robin Dapp  <rdapp@linux.ibm.com>
2100         * c-attribs.c (common_handle_aligned_attribute): Remove short
2101         circuit and dead code.
2103 2021-06-14  Jonathan Wakely  <jwakely@redhat.com>
2105         PR c++/101052
2106         * known-headers.cc (get_stdlib_header_for_name): Add known
2107         headers for EXIT_FAILURE, EXIT_SUCCESS, abort, atexit, calloc,
2108         exit, and getenv.
2110 2021-06-12  Jason Merrill  <jason@redhat.com>
2112         * c-attribs.c (handle_unused_attribute): Handle FIELD_DECL.
2114 2021-06-11  Jakub Jelinek  <jakub@redhat.com>
2116         PR c++/100974
2117         * c-cppbuiltin.c (c_cpp_builtins): Predefine __cpp_if_consteval for
2118         -std=c++2b for P1938R3 consteval if support.
2120 2021-06-09  Jason Merrill  <jason@redhat.com>
2122         PR c++/100879
2123         * c-warn.c (warn_for_sign_compare): Remove C++ enum mismatch
2124         warning.
2126 2021-06-07  Martin Liska  <mliska@suse.cz>
2128         * c-target.def: Split long lines and replace them
2129         with '\n\'.
2131 2021-06-04  Martin Sebor  <msebor@redhat.com>
2133         PR c/100783
2134         * c-attribs.c (positional_argument): Bail on erroneous types.
2136 2021-06-04  Martin Sebor  <msebor@redhat.com>
2138         * c-warn.c (warn_parm_array_mismatch): Check TREE_PURPOSE to test
2139         for element presence.
2141 2021-06-03  Eric Botcazou  <ebotcazou@adacore.com>
2143         * c-ada-spec.c (dump_ada_macros): Minor tweaks.
2144         (dump_ada_decl_name): Likewise.
2145         (dump_anonymous_type_name): Remove parent parameter and adjust.
2146         (dump_sloc): Minor tweak.
2147         (dump_ada_array_type): Remove type parameter and adjust.
2148         (dump_ada_enum_type): Remove parent parameter and adjust.
2149         (dump_ada_node): Adjust calls to above functions.
2150         (dumped_anonymous_types): New global variable.
2151         (dump_nested_types_1): Rename into...
2152         (dump_nested_types): ...this.
2153         (dump_nested_type): Remove parent and dumped_types parameters.
2154         <ARRAY_TYPE>: Replace dumped_types with dumped_anonymous_types.
2155         Adjust calls to dump_anonymous_type_name and dump_ada_array_type.
2156         (dump_ada_specs): Initialize and free dumped_anonymous_types.
2158 2021-06-03  Eric Botcazou  <ebotcazou@adacore.com>
2160         * c-ada-spec.c (pp_ada_tree_identifier): Tidy up.
2161         (dump_ada_node) <POINTER_TYPE>: Deal specially with external subtypes.
2163 2021-06-03  Eric Botcazou  <ebotcazou@adacore.com>
2165         * c-ada-spec.c (dump_ada_enum_type): Dump a prefix for constants.
2166         (htable_t): New typedef.
2167         (overloaded_names): Use it.
2168         (add_name): New function.
2169         (init_overloaded_names): Use add_name to populate the table and add
2170         special cases for sigaction and stat.
2171         (overloaded_name_p): Rename into...
2172         (overloading_index): ...this.  Do not initialize overloaded_names table
2173         here.  Return the index or zero.
2174         (dump_ada_declaration): Minor tweaks.  Do not skip overloaded functions
2175         but add an overloading suffix instead.
2176         (dump_ada_specs): Initialize overloaded_names tables here.
2178 2021-06-01  Martin Liska  <mliska@suse.cz>
2180         PR other/100759
2181         * c-attribs.c (handle_optimize_attribute): Limit sanity check
2182         to a situation where we are not in processing of an optimize
2183         pragma.
2184         * c-pragma.c (handle_pragma_pop_options): Restore target
2185         options.
2187 2021-05-31  Indu Bhagat  <indu.bhagat@oracle.com>
2189         PR testsuite/100749
2190         * c-pch.c (c_common_valid_pch): Use xstrdup for debug format set names.
2192 2021-05-31  Richard Biener  <rguenther@suse.de>
2194         PR c++/88601
2195         * c-common.c: Include tree-vector-builder.h and
2196         vec-perm-indices.h.
2197         (c_common_reswords): Add __builtin_shufflevector.
2198         (c_build_shufflevector): New funtion.
2199         * c-common.h (enum rid): Add RID_BUILTIN_SHUFFLEVECTOR.
2200         (c_build_shufflevector): Declare.
2202 2021-05-28  Jakub Jelinek  <jakub@redhat.com>
2204         PR middle-end/99928
2205         * c-omp.c (c_omp_split_clauses): For reduction clause if combined with
2206         target add a map tofrom clause with OMP_CLAUSE_MAP_IMPLICIT.
2208 2021-05-28  Tobias Burnus  <tobias@codesourcery.com>
2210         * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_AFFINITY.
2212 2021-05-25  Martin Liska  <mliska@suse.cz>
2214         PR tree-optimization/92860
2215         PR target/99592
2216         * c-attribs.c (handle_optimize_attribute): Save target node
2217         before calling parse_optimize_options and save it in case
2218         it changes.
2219         * c-pragma.c (handle_pragma_target): Similarly for pragma.
2220         (handle_pragma_pop_options): Likewise here.
2222 2021-05-25  Martin Liska  <mliska@suse.cz>
2224         * c-attribs.c (handle_no_sanitize_coverage_attribute): New.
2226 2021-05-25  Jakub Jelinek  <jakub@redhat.com>
2228         PR middle-end/99928
2229         * c-omp.c (c_omp_split_clauses): Copy reduction to teams when teams is
2230         combined with simd and not with taskloop or for.
2232 2021-05-21  Jakub Jelinek  <jakub@redhat.com>
2234         PR middle-end/99928
2235         * c-omp.c (c_omp_split_clauses): Set OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT
2236         on firstprivate clause copy going to target construct, and for
2237         target simd set also OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT_TARGET bit.
2239 2021-05-20  Jonathan Wakely  <jwakely@redhat.com>
2241         * c.opt (Wc++11-extensions, Wc++14-extensions)
2242         (Wc++17-extensions, Wc++20-extensions, Wc++23-extensions): New
2243         options.
2245 2021-05-20  Indu Bhagat  <indu.bhagat@oracle.com>
2247         * c-lex.c (init_c_lex): Use dwarf_debuginfo_p.
2249 2021-05-20  Indu Bhagat  <indu.bhagat@oracle.com>
2251         * c-opts.c (c_common_post_options): Adjust access to debug_type_names.
2252         * c-pch.c (struct c_pch_validity): Use type uint32_t.
2253         (pch_init): Renamed member.
2254         (c_common_valid_pch): Adjust access to debug_type_names.
2256 2021-05-19  Martin Sebor  <msebor@redhat.com>
2258         PR c/100619
2259         * c-attribs.c (build_attr_access_from_parms): Handle arbitrarily many
2260         bounds.
2262 2021-05-18  Richard Biener  <rguenther@suse.de>
2264         PR c/100547
2265         * c-attribs.c (type_valid_for_vector_size): Reject too large nunits.
2266         Reword existing nunit diagnostic.
2268 2021-05-17  Joern Rennecke  <joern.rennecke@embecosm.com>
2270         * c-common.c (braced_list_to_string): Return CTOR unchanged
2271         if host and target character sizes don't match.
2273 2021-05-14  Martin Liska  <mliska@suse.cz>
2275         * c.opt: Add Warning keyword for 2 options.
2277 2021-05-13  Martin Liska  <mliska@suse.cz>
2279         PR middle-end/100504
2280         * c-attribs.c (handle_target_clones_attribute): Expect a string
2281         argument to target_clone argument.
2283 2021-05-11  Joseph Myers  <joseph@codesourcery.com>
2285         * c-lex.c (interpret_float): Handle digit separators for C2X.
2287 2021-05-10  Martin Liska  <mliska@suse.cz>
2289         * c-ada-spec.c (print_destructor): Use startswith
2290         function instead of strncmp.
2291         (dump_ada_declaration): Likewise.
2292         * c-common.c (disable_builtin_function): Likewise.
2293         (def_builtin_1): Likewise.
2294         * c-format.c (check_tokens): Likewise.
2295         (check_plain): Likewise.
2296         (convert_format_name_to_system_name): Likewise.
2298 2021-04-28  Patrick McGehearty  <patrick.mcgehearty@oracle.com>
2300         * c-cppbuiltin.c (c_cpp_builtins): Add supporting macros for new
2301         complex divide
2303 2021-04-26  Thomas Schwinge  <thomas@codesourcery.com>
2304             Nathan Sidwell  <nathan@codesourcery.com>
2305             Tom de Vries  <vries@codesourcery.com>
2306             Julian Brown  <julian@codesourcery.com>
2307             Kwok Cheung Yeung  <kcy@codesourcery.com>
2309         * c.opt (Wopenacc-parallelism): New.
2311 2021-04-19  Thomas Schwinge  <thomas@codesourcery.com>
2313         * c.opt (fopenacc-kernels=): Remove.
2315 2021-04-08  Jakub Jelinek  <jakub@redhat.com>
2317         * c-warn.c (do_warn_double_promotion): Fix comment typo,
2318         occured -> occurred.
2319         (check_alignment_of_packed_member): Fix a comment typo,
2320         memeber -> member.
2321         (warn_parm_ptrarray_mismatch): Fix comment typos, os -> of
2322         and onless -> unless.
2323         (warn_parm_array_mismatch): Fix comment typos, declaratation
2324         -> declaration and woud -> would.  Fix up comment indentation.
2326 2021-04-08  Martin Sebor  <msebor@redhat.com>
2328         PR middle-end/99883
2329         * c.opt (Wmismatched-new-delete): Correct spelling.
2331 2021-04-05  Eric Botcazou  <ebotcazou@adacore.com>
2333         * c-ada-spec.c (is_simple_enum): Minor tweaks.
2334         (dump_ada_enum_type): Add TYPE and PARENT parameters.  For non-simple
2335         enumeral types use again the type name for the enumeration constants.
2336         (dump_ada_node): Adjust call to dump_ada_enum_type.
2337         (dump_nested_type): Likewise.
2339 2021-04-01  Jason Merrill  <jason@redhat.com>
2341         PR c++/98481
2342         * c-opts.c (c_common_post_options): Bump latest_abi_version.
2344 2021-03-25  Jakub Jelinek  <jakub@redhat.com>
2346         PR c++/99565
2347         * c-warn.c (do_warn_duplicated_branches): Pass also
2348         OEP_ADDRESS_OF_SAME_FIELD to operand_equal_p.
2350 2021-03-20  Jakub Jelinek  <jakub@redhat.com>
2352         PR debug/99230
2353         * c-gimplify.c (c_genericize_control_stmt): Handle STATEMENT_LIST.
2355 2021-03-05  Eric Botcazou  <ebotcazou@adacore.com>
2357         * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Dump nested types
2358         after entering the separate class package, if any.
2360 2021-03-04  Richard Biener  <rguenther@suse.de>
2362         * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator):
2363         Handle ERROR_MARK.
2365 2021-03-04  Jakub Jelinek  <jakub@redhat.com>
2367         PR c/99325
2368         * c-ppoutput.c (print): Change src_line type from int to unsigned.
2369         (token_streamer::stream) Likewise.
2370         (maybe_print_line_1): Likewise.  Don't strcmp src_file if src_loc is
2371         UNKNOWN_LOCATION.
2373 2021-03-03  Jakub Jelinek  <jakub@redhat.com>
2375         PR c/99324
2376         * c-common.c (build_va_arg): Call c_common_mark_addressable_vec
2377         instead of mark_addressable.  Fix a comment typo -
2378         neutrallly -> neutrally.
2380 2021-02-28  Jakub Jelinek  <jakub@redhat.com>
2382         PR c/99304
2383         * c-attribs.c (handle_malloc_attribute): Fix a typo in inform
2384         message - refernced -> referenced.  Remove superfluous space before
2385         closing paren of function calls.
2387 2021-02-25  Nathan Sidwell  <nathan@acm.org>
2389         PR c++/99166
2390         * c.opt (-flang-info-module-cmi): Renamed option.
2392 2021-02-19  Nathan Sidwell  <nathan@acm.org>
2394         * c.opt (flang-info-module-read, flang-info-module-read=): New.
2396 2021-02-18  H.J. Lu  <hjl.tools@gmail.com>
2398         PR target/99113
2399         * c-attribs.c (c_common_attribute_table): Add the "retain"
2400         attribute.
2401         (handle_retain_attribute): New function.
2403 2021-02-16  Marek Polacek  <polacek@redhat.com>
2405         PR c++/99062
2406         * c-attribs.c (handle_assume_aligned_attribute): Check that the
2407         alignment argument is non-negative.  Tweak a warning message.
2409 2021-02-12  Martin Sebor  <msebor@redhat.com>
2411         PR c/99055
2412         * c-warn.c (warn_parm_array_mismatch): Free strings returned from
2413         print_generic_expr_to_str.
2415 2021-02-10  Richard Biener  <rguenther@suse.de>
2417         * c-common.c (parse_optimize_options): Free decoded_options.
2419 2021-02-04  emsr  <3dw4rd@verizon.net>
2421         * c-cppbuiltin.c (c_cpp_builtins): __cpp_size_t_suffix=202011L.
2423 2021-02-03  Ed Smith-Rowland  <3dw4rd@verizon.net>
2425         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_size_t_suffix.
2426         * c-lex.c (interpret_integer): Set node type for size literal.
2428 2021-01-28  Jakub Jelinek  <jakub@redhat.com>
2430         * c.opt (-std=c++2a, -std=c++20, -std=gnu++2a, -std=gnu++20): Remove
2431         draft from description.
2432         (-std=c++2b): Fix a pasto, 2020 -> 2023.
2434 2021-01-26  Paul Fee  <paul.f.fee@gmail.com>
2436         * c-common.h (cxx_dialect): Add cxx23 as a dialect.
2437         * c.opt: Add options for -std=c++23, std=c++2b, -std=gnu++23
2438         and -std=gnu++2b
2439         * c-opts.c (set_std_cxx23): New.
2440         (c_common_handle_option): Set options when -std=c++23 is enabled.
2441         (c_common_post_options): Adjust comments.
2442         (set_std_cxx20): Likewise.
2444 2021-01-25  Martin Sebor  <msebor@redhat.com>
2446         PR c++/98646
2447         * c-common.c (check_nonnull_arg): Adjust warning text.
2449 2021-01-17  Martin Sebor  <msebor@redhat.com>
2451         * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
2452         assume SSA_NAME_IDENTIFIER evaluates to nonzero.
2454 2021-01-16  Kwok Cheung Yeung  <kcy@codesourcery.com>
2456         * c-pragma.h (pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DETACH.
2457         Redefine PRAGMA_OACC_CLAUSE_DETACH.
2459 2021-01-15  Jakub Jelinek  <jakub@redhat.com>
2461         PR tree-optimization/98597
2462         * c-pretty-print.c: Include options.h.
2463         (c_fold_indirect_ref_for_warn): New function.
2464         (print_mem_ref): Use it.  If it returns something that has compatible
2465         type and is TBAA compatible with zero offset, print it and return,
2466         otherwise print it using offsetof syntax or array ref syntax.  Fix up
2467         printing if MEM_REFs first operand is ADDR_EXPR, or when the first
2468         argument has pointer to array type.  Print pointers using the standard
2469         formatting.
2471 2021-01-12  Martin Sebor  <msebor@redhat.com>
2473         PR c/98597
2474         PR c/98592
2475         * c-pretty-print.c (print_mem_ref): Avoid assuming MEM_REF operand
2476         has pointer type.  Remove redundant code.  Avoid calling
2477         gimple_canonical_types_compatible_p.
2479 2021-01-07  Martin Sebor  <msebor@redhat.com>
2481         PR middle-end/98578
2482         * c-pretty-print.c (print_mem_ref): Strip array from access type.
2483         Avoid assuming acces type's size is constant.  Correct condition
2484         guarding the printing of a parenthesis.
2486 2021-01-06  Martin Sebor  <msebor@redhat.com>
2488         PR c++/95768
2489         * c-pretty-print.c (c_pretty_printer::primary_expression): For
2490         SSA_NAMEs print VLA names and GIMPLE defining statements.
2491         (print_mem_ref): New function.
2492         (c_pretty_printer::unary_expression): Call it.
2494 2021-01-06  Richard Biener  <rguenther@suse.de>
2496         PR tree-optimization/95582
2497         * c-attribs.c (c_common_attribute_table): Add entry for
2498         signed_bool_precision.
2499         (handle_signed_bool_precision_attribute): New.
2501 2020-12-24  Iain Sandoe  <iain@sandoe.co.uk>
2503         * c.opt: Add -stdlib= option and enumerations for
2504         libstdc++ and libc++.
2506 2020-12-16  Martin Liska  <mliska@suse.cz>
2508         * c.opt: Remove usage of Report.
2510 2020-12-14  Martin Sebor  <msebor@redhat.com>
2512         PR middle-end/98166
2513         PR c++/57111
2514         PR middle-end/98160
2515         * c-attribs.c (maybe_add_noinline): New function.
2516         (handle_malloc_attribute): Call it.  Use ATTR_FLAG_INTERNAL.
2517         Implicitly add attribute noinline to functions not declared inline
2518         and warn on those.
2520 2020-12-09  Tobias Burnus  <tobias@codesourcery.com>
2522         * c-pragma.c (omp_pragmas): Add 'allocate'.
2523         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ALLOCATE.
2525 2020-12-08  Jakub Jelinek  <jakub@redhat.com>
2527         PR c++/98187
2528         * c-pragma.c (omp_pragmas): Remove "master".
2529         (omp_pragmas_simd): Add "master".
2531 2020-12-07  Marek Polacek  <polacek@redhat.com>
2533         PR c++/98126
2534         * c-common.c (verify_tree_lim_r): New function.
2535         (verify_sequence_points): Use it.  Use nullptr instead of 0.
2537 2020-12-03  Martin Sebor  <msebor@redhat.com>
2539         PR c++/90629
2540         PR middle-end/94527
2541         * c-attribs.c (handle_dealloc_attribute): New function.
2542         (handle_malloc_attribute): Handle argument forms of attribute.
2543         * c.opt (-Wmismatched-dealloc): New option.
2544         (-Wmismatched-new-delete): New option.
2546 2020-12-03  Jakub Jelinek  <jakub@redhat.com>
2548         PR libstdc++/93121
2549         * c-common.h (enum rid): Add RID_BUILTIN_BIT_CAST.
2550         * c-common.c (c_common_reswords): Add __builtin_bit_cast.
2552 2020-12-01  JeanHeyd Meneide  <phdofthehouse@gmail.com>
2554         * c-cppbuiltin.c (c_cpp_builtins): Add predefined
2555         {__GNUC_EXECUTION_CHARSET_NAME} and
2556         _WIDE_EXECUTION_CHARSET_NAME} macros.
2558 2020-12-01  Nathan Sidwell  <nathan@acm.org>
2560         * c-common.c (module, import, export): New internal tokens (with
2561         trailing space).
2562         * c-common.h (RID__MODULE, RID__IMPORT & RID__EXPORT): Enumerate
2563         them.
2564         (D_CXX_MODULES, D_CXX_MODULES_FLAGS): Enable them.
2565         * c-cppbuiltin.c (c_cpp_builtins): Feature macro.
2567 2020-12-01  Nathan Sidwell  <nathan@acm.org>
2569         * c-opts.c (c_common_init_options): Ask for module dependencies.
2570         (c_common_handle_option): Handle -Mmodules -Mno-modules.
2571         * c-pch.c (c_common_valid_pch): ... does not play with C++
2572         modules.
2573         * c.opt (Mmodules, Mno-modules): New preprocessor dependency
2574         options.
2575         (fmodules-ts, fmodule-header, fmodule-implicit-inline)
2576         (fmodule-only, fmodule-mapper, fmodule-lazy)
2577         (fmodule-version-ignore, Winvalid-imported-macros)
2578         (flang-info-include-translate, flang-info-include-translate-not):
2579         New options
2581 2020-11-28  Eric Botcazou  <ebotcazou@adacore.com>
2583         * c-ada-spec.c (dump_nested_type) <RECORD_TYPE>: Remove obsolete code.
2584         (dump_ada_structure): Also deal with convention, unchecked union and
2585         bit-field for nested types.  In the latter case, print an Alignment
2586         aspect along with the Pack aspect.
2588 2020-11-25  Martin Sebor  <msebor@redhat.com>
2590         PR bootstrap/94982
2591         * c-attribs.c (handle_patchable_function_entry_attribute): Avoid
2592         -Wformat-diag.
2594 2020-11-24  Martin Sebor  <msebor@redhat.com>
2596         * c-warn.c (warn_parm_array_mismatch): Avoid invalid redeclarations.
2598 2020-11-23  Jozef Lawrynowicz  <jozef.l@mittosystems.com>
2600         * c-attribs.c (handle_special_var_sec_attribute): New.
2601         (handle_noinit_attribute): Remove.
2602         (attr_noinit_exclusions): Rename to...
2603         (attr_section_exclusions): ...this, and add "persistent" attribute
2604         exclusion.
2605         (c_common_attribute_table): Add "persistent" attribute.
2607 2020-11-21  Aaron Sawdey  <acsawdey@linux.ibm.com>
2609         * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
2610         Treat opaque types like other types.
2611         (c_pretty_printer::direct_abstract_declarator): Opaque types are
2612         supported types.
2614 2020-11-20  Martin Sebor  <msebor@redhat.com>
2616         * c-warn.c (warn_parm_array_mismatch): Bail on invalid redeclarations
2617         with fewer arguments.
2619 2020-11-20  Martin Sebor  <msebor@redhat.com>
2621         PR middle-end/97879
2622         * c-attribs.c (handle_access_attribute): Handle ATTR_FLAG_INTERNAL.
2623         Error out on invalid modes.
2625 2020-11-20  Jakub Jelinek  <jakub@redhat.com>
2627         PR libstdc++/88101
2628         * c-common.c (check_builtin_function_arguments): Handle
2629         BUILT_IN_CLEAR_PADDING.
2631 2020-11-18  Nathan Sidwell  <nathan@acm.org>
2633         * c-lex.c (c_lex_with_flags): CPP_HEADER_NAMEs can now be seen.
2635 2020-11-17  Nathan Sidwell  <nathan@acm.org>
2637         * c-common.h (enum c_tree_index): Reorder to place lazy fields
2638         after newly-added CTI_MODULE_HWM.
2640 2020-11-17  Joseph Myers  <joseph@codesourcery.com>
2642         * c-cppbuiltin.c (builtin_define_float_constants): Define
2643         "*_IS_IEC_60559__" macros.
2645 2020-11-17  Nathan Sidwell  <nathan@acm.org>
2647         * c-lex.c: #include "langhooks.h".
2648         (cb_undef): Maybe call preprocess_undef lang hook.
2649         * c-opts.c (c_common_post_options): Maybe call preprocess_options
2650         lang hook.
2651         (push_command_line_include): Maybe call preprocess_main_file lang
2652         hook.
2653         (cb_file_change): Likewise.
2654         * c-ppoutput.c: #include "langhooks.h.
2655         (scan_translation_unit): Maybe call preprocess_token lang hook.
2656         (class do_streamer): New, derive from token_streamer.
2657         (directives_only_cb): Data pointer is do_streamer, call
2658         preprocess_token lang hook.
2659         (scan_translation_unit_directives_only): Use do_streamer.
2660         (print_line_1): Move src_line recording to after string output.
2661         (cb_undef): Maybe call preprocess_undef lang hook.
2663 2020-11-17  Nathan Sidwell  <nathan@acm.org>
2665         * c-ppoutput.c (scan_translation_unit): Use token_streamer, remove
2666         code duplicating that functionality.
2668 2020-11-17  Jakub Jelinek  <jakub@redhat.com>
2670         PR c/90628
2671         * c-common.c (check_builtin_function_arguments)
2672         <case BUILT_IN_ADD_OVERFLOW>: Diagnose when last argument is pointer
2673         to _Atomic.  For the TYPE_READONLY case, adjust message to be usable
2674         for more builtins and argument positions.
2676 2020-11-16  Iain Sandoe  <iain@sandoe.co.uk>
2678         PR objc/97854
2679         * stub-objc.c: Include c-common.h to declare enum rid.
2681 2020-11-13  Jakub Jelinek  <jakub@redhat.com>
2683         PR c++/63287
2684         * c-cppbuiltin.c: Include configargs.h.
2685         (c_cpp_builtins): For C++11 and later if THREAD_MODEL_SPEC is not
2686         defined, predefine __STDCPP_THREADS__ to 1 unless thread_model is
2687         "single".
2689 2020-11-13  Gergö Barany  <gergo@codesourcery.com>
2690             Thomas Schwinge  <thomas@codesourcery.com>
2692         * c.opt (fopenacc-kernels): Add.
2694 2020-11-13  Jason Merrill  <jason@redhat.com>
2696         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_using_enum.
2698 2020-11-13  Piotr H. Dabrowski  <phd@phd.re>
2700         PR c++/91318
2701         * c-cppbuiltin.c: c_cpp_builtins_optimize_pragma(): use cpp_define_unused()
2703 2020-11-13  Martin Liska  <mliska@suse.cz>
2705         * c-attribs.c (build_attr_access_from_parms): Format properly.
2707 2020-11-13  Iain Sandoe  <iain@sandoe.co.uk>
2709         PR objc/90707
2710         * c-common.c (c_common_reswords): null_unspecified, nullable,
2711         nonnull, null_resettable: New keywords.
2712         * c-common.h (enum rid): RID_NULL_UNSPECIFIED, RID_NULLABLE,
2713         RID_NONNULL, RID_NULL_RESETTABLE: New.
2714         (OBJC_IS_PATTR_KEYWORD): Include nullability keywords in the
2715         ranges accepted for property attributes.
2716         * c-attribs.c (handle_objc_nullability_attribute): New.
2717         * c-objc.h (enum objc_property_attribute_group): Add
2718         OBJC_PROPATTR_GROUP_NULLABLE.
2719         (enum objc_property_attribute_kind):Add
2720         OBJC_PROPERTY_ATTR_NULL_UNSPECIFIED, OBJC_PROPERTY_ATTR_NULLABLE,
2721         OBJC_PROPERTY_ATTR_NONNULL, OBJC_PROPERTY_ATTR_NULL_RESETTABLE.
2723 2020-11-13  Iain Sandoe  <iain@sandoe.co.uk>
2725         PR objc/77404
2726         * c-attribs.c (handle_objc_root_class_attribute): New
2727         * c-objc.h (objc_start_class_interface): Add a location
2728         value for the position of the class name.
2729         * c.opt: Add Wobjc-root-class.
2730         * stub-objc.c (objc_start_class_interface): Add a location
2731         value for the position of the class name.
2733 2020-11-12  Joseph Myers  <joseph@codesourcery.com>
2735         * c-lex.c (c_common_has_attribute): Take argument std_syntax.
2736         Allow scope for C.  Handle standard attributes for C.  Do not
2737         accept unscoped attributes if std_syntax and not handled as
2738         standard attributes.
2739         * c-common.h (c_common_has_attribute): Update prototype.
2741 2020-11-12  Nicholas Guriev  <guriev-ns@ya.ru>
2743         PR pch/86674
2744         * c-pch.c (c_common_valid_pch): Use cpp_warning with CPP_W_INVALID_PCH
2745         reason to fix -Werror=invalid-pch and -Wno-error=invalid-pch switches.
2747 2020-11-11  Patrick Palka  <ppalka@redhat.com>
2749         PR c++/88115
2750         * c-opts.c (c_common_post_options): Update latest_abi_version.
2752 2020-11-10  Jakub Jelinek  <jakub@redhat.com>
2754         PR c/97748
2755         * c-common.h (warn_if_unused_value): Add quiet argument defaulted
2756         to false.
2757         * c-warn.c (warn_if_unused_value): Likewise.  Pass it down
2758         recursively and just return true instead of warning if it is true.
2759         Handle COMPLEX_EXPR.
2761 2020-11-10  Chung-Lin Tang  <cltang@codesourcery.com>
2763         * c-common.h (c_omp_adjust_map_clauses): New declaration.
2764         * c-omp.c (struct map_clause): Helper type for c_omp_adjust_map_clauses.
2765         (c_omp_adjust_map_clauses): New function.
2767 2020-11-09  Marek Polacek  <polacek@redhat.com>
2769         DR 1914
2770         * c-common.c (attribute_fallthrough_p): Tweak the warning
2771         message.
2773 2020-11-09  Patrick Palka  <ppalka@redhat.com>
2775         * c-pragma.c (handle_pragma_diagnostic): Split the
2776         unknown-option -Wpragmas diagnostic into a warning and a
2777         subsequent note containing a spelling suggestion.  Avoid
2778         computing the suggestion if -Wpragmas warnings are being
2779         suppressed.
2781 2020-11-09  Patrick Palka  <ppalka@redhat.com>
2783         PR testsuite/97117
2784         * c-indentation.c (get_visual_column): Remove location_t
2785         parameter.  Move the column-tracking diagnostic code from here
2786         to ...
2787         (should_warn_for_misleading_indentation): ... here, before the
2788         early exit for when the loci are not all distinct.  Don't pass a
2789         location_t argument to get_visual_column.
2790         (assert_get_visual_column_succeeds): Don't pass a location_t
2791         argument to get_visual_column.
2792         (assert_get_visual_column_fails): Likewise.
2794 2020-11-08  Iain Sandoe  <iain@sandoe.co.uk>
2796         * c-common.h (OBJC_IS_PATTR_KEYWORD): Add class to the list
2797         of keywords accepted in @property attribute contexts.
2798         * c-objc.h (enum objc_property_attribute_group): Add
2799         OBJC_PROPATTR_GROUP_CLASS.
2800         (enum objc_property_attribute_kind): Add
2801         OBJC_PROPERTY_ATTR_CLASS.
2803 2020-11-07  Iain Sandoe  <iain@sandoe.co.uk>
2805         * c-common.c (c_common_reswords): Add 'atomic' property
2806         attribute.
2807         * c-common.h (enum rid): Add RID_PROPATOMIC for atomic
2808         property attributes.
2810 2020-11-07  Iain Sandoe  <iain@sandoe.co.uk>
2812         * c-attribs.c (handle_nsobject_attribute): New.
2813         * c.opt: Add WNSObject-attribute.
2815 2020-11-06  Iain Sandoe  <iain@sandoe.co.uk>
2817         * c-objc.h (enum objc_property_attribute_group): New
2818         (enum objc_property_attribute_kind): New.
2819         (OBJC_PROPATTR_GROUP_MASK): New.
2820         (struct property_attribute_info): Small class encapsulating
2821         parser output from property attributes.
2822         (objc_prop_attr_kind_for_rid): New
2823         (objc_add_property_declaration): Simplify interface.
2824         * stub-objc.c (enum rid): Dummy type.
2825         (objc_add_property_declaration): Simplify interface.
2826         (objc_prop_attr_kind_for_rid): New.
2828 2020-11-06  Nathan Sidwell  <nathan@acm.org>
2830         * c-ada-spec.c (collect_ada_nodes): Rename
2831         DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
2832         (collect_ada_node): Likewise.
2833         (dump_forward_type): Likewise.
2834         * c-common.c (set_underlying_type): Rename
2835         DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
2836         (user_facing_original_type, c_common_finalize_early_debug): Likewise.
2838 2020-11-06  Jakub Jelinek  <jakub@redhat.com>
2840         * c-common.c (verify_sequence_points): Remove DEBUG_FUNCTION.
2842 2020-11-05  Marek Polacek  <polacek@redhat.com>
2844         PR c++/97675
2845         * c.opt (Wexceptions): New option.
2847 2020-11-05  Marek Polacek  <polacek@redhat.com>
2849         PR c++/25814
2850         * c.opt (Wvexing-parse): New option.
2852 2020-11-04  Jakub Jelinek  <jakub@redhat.com>
2854         PR c++/97670
2855         * c-omp.c (c_omp_split_clauses): Look through array reductions to find
2856         underlying decl to clear in the allocate_head bitmap.
2858 2020-11-04  Iain Sandoe  <iain@sandoe.co.uk>
2860         * c-objc.h (objc_non_constant_expr_p): New.
2861         * stub-objc.c (objc_non_constant_expr_p): New.
2863 2020-11-03  Nathan Sidwell  <nathan@acm.org>
2865         * c.opt (MQ,MT): Reword description to be make-agnostic.
2867 2020-11-02  Nathan Sidwell  <nathan@acm.org>
2869         * c-opts.c (c_common_post_options): Move var decl to its
2870         initialization point.
2872 2020-11-01  Iain Sandoe  <iain@sandoe.co.uk>
2874         * c-lex.c (c_lex_with_flags): When combining '@' with a
2875         keyword for Objective-C, combine the location ranges too.
2877 2020-10-30  Qing Zhao  <qing.zhao@oracle.com>
2878             H.J.Lu  <hjl.tools@gmail.com>
2880         * c-attribs.c (c_common_attribute_table): Add new attribute
2881         zero_call_used_regs.
2882         (handle_zero_call_used_regs_attribute): New function.
2884 2020-10-28  Marek Polacek  <polacek@redhat.com>
2886         PR c++/97573
2887         * c-opts.c (c_common_post_options): In C++20, turn on
2888         -Wdeprecated-enum-enum-conversion and
2889         -Wdeprecated-enum-float-conversion.
2890         * c.opt (Wdeprecated-enum-enum-conversion,
2891         Wdeprecated-enum-float-conversion): New options.
2892         (Wenum-conversion): Allow for C++ too.
2894 2020-10-28  Jakub Jelinek  <jakub@redhat.com>
2896         * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALLOCATE.
2897         * c-omp.c: Include bitmap.h.
2898         (c_omp_split_clauses): Handle OMP_CLAUSE_ALLOCATE.
2900 2020-10-26  Ville Voutilainen  <ville.voutilainen@gmail.com>
2902         * c-common.c (__is_nothrow_assignable): New.
2903         (__is_nothrow_constructible): Likewise.
2904         * c-common.h (RID_IS_NOTHROW_ASSIGNABLE): New.
2905         (RID_IS_NOTHROW_CONSTRUCTIBLE): Likewise.
2907 2020-10-23  Jan Hubicka  <hubicka@ucw.cz>
2909         * c-common.c (c_common_finalize_early_debug): Update for new thunk api.
2911 2020-10-23  Marek Polacek  <polacek@redhat.com>
2913         PR c++/91741
2914         * c-common.c (verify_tree): Handle PAREN_SIZEOF_EXPR.
2915         (c_common_init_ts): Likewise.
2916         * c-common.def (PAREN_SIZEOF_EXPR): New tree code.
2917         * c-common.h (maybe_warn_sizeof_array_div): Declare.
2918         * c-warn.c (sizeof_pointer_memaccess_warning): Unwrap NOP_EXPRs.
2919         (maybe_warn_sizeof_array_div): New function.
2920         * c.opt (Wsizeof-array-div): New option.
2922 2020-10-23  Martin Sebor  <msebor@redhat.com>
2924         PR c/97463
2925         * c-warn.c (warn_parm_ptrarray_mismatch): Move null test earlier.
2927 2020-10-22  Martin Liska  <mliska@suse.cz>
2929         PR c/94722
2930         * c-attribs.c (handle_no_stack_protect_function_attribute): New.
2931         (handle_stack_protect_attribute): Add error message for a
2932         no_stack_protector function.
2934 2020-10-22  Martin Liska  <mliska@suse.cz>
2936         * c-cppbuiltin.c (c_cpp_builtins): Use the stack_protector enum.
2938 2020-10-22  Jan Hubicka  <hubicka@ucw.cz>
2940         * c-gimplify.c: Include tree-nested.h
2941         (c_genericize): Update for new nested function info.
2943 2020-10-14  Martin Sebor  <msebor@redhat.com>
2945         PR c/97413
2946         * c-attribs.c (build_attr_access_from_parms): Wrap chain of VLA
2947         bounds in an extra list.
2949 2020-10-05  Richard Biener  <rguenther@suse.de>
2950             Jakub Jelinek  <jakub@redhat.com>
2952         PR c++/97197
2953         * c-pretty-print.c: Include langhooks.h.
2954         (c_pretty_printer::postfix_expression): Handle TARGET_MEM_REF as
2955         expression.
2956         (c_pretty_printer::expression): Handle TARGET_MEM_REF as
2957         unary_expression.
2958         (c_pretty_printer::unary_expression): Handle TARGET_MEM_REF.
2960 2020-09-30  Martin Sebor  <msebor@redhat.com>
2962         PR middle-end/97189
2963         * c-attribs.c (append_access_attr): Use the function declaration
2964         location for a warning about an attribute access argument.
2966 2020-09-29  Marek Polacek  <polacek@redhat.com>
2968         PR c++/94695
2969         * c.opt (Wrange-loop-construct): New option.
2971 2020-09-23  Martin Sebor  <msebor@redhat.com>
2973         PR c/97131
2974         * c-warn.c (warn_parm_ptrarray_mismatch): Handle more invalid input.
2976 2020-09-23  Marek Polacek  <polacek@redhat.com>
2978         PR c/97125
2979         * c-gimplify.c (c_genericize): Only call do_warn_duplicated_branches_r
2980         after loops and other structured control constructs have been lowered.
2982 2020-09-22  Jakub Jelinek  <jakub@redhat.com>
2984         * c.opt (Wbuiltin-declaration-mismatch): Fix typo in variable name:
2985         warn_builtin_declaraion_mismatch -> warn_builtin_declaration_mismatch.
2987 2020-09-21  Marek Polacek  <polacek@redhat.com>
2989         * c.opt (Wctad-maybe-unsupported): New option.
2991 2020-09-19  Martin Sebor  <msebor@redhat.com>
2993         PR c/50584
2994         * c-common.h (warn_parm_array_mismatch): Declare new function.
2995         (has_attribute): Move declaration of an existing function.
2996         (build_attr_access_from_parms): Declare new function.
2997         * c-warn.c (parm_array_as_string): Define new function.
2998         (plus_one):  Define new function.
2999         (warn_parm_ptrarray_mismatch): Define new function.
3000         (warn_parm_array_mismatch):  Define new function.
3001         (vla_bound_parm_decl): New function.
3002         * c.opt (-Warray-parameter, -Wvla-parameter): New options.
3003         * c-pretty-print.c (pp_c_type_qualifier_list): Don't print array type
3004         qualifiers here...
3005         (c_pretty_printer::direct_abstract_declarator): ...but instead print
3006         them in brackets here.  Also print [static].  Strip extraneous
3007         expressions from VLA bounds.
3009 2020-09-19  Martin Sebor  <msebor@redhat.com>
3011         PR c/50584
3012         * c-attribs.c (c_common_attribute_table): Add "arg spec" attribute.
3013         (handle_argspec_attribute): New function.
3014         (get_argument, get_argument_type): New functions.
3015         (append_access_attrs): Add overload.  Handle internal attribute
3016         representation in addition to external.
3017         (handle_access_attribute): Handle internal attribute representation
3018         in addition to external.
3019         (build_attr_access_from_parms): New function.
3021 2020-09-19  Sandra Loosemore  <sandra@codesourcery.com>
3023         * c-gimplify.c (genericize_c_loop): Rewrite to match
3024         c_finish_loop in c-typeck.c.
3026 2020-09-19  Sandra Loosemore  <sandra@codesourcery.com>
3028         * c-common.c (c_block_may_fallthrough): New, split from
3029         cxx_block_may_fallthrough in the cp front end.
3030         (c_common_init_ts): Move handling of loop and switch-related
3031         statements here from the cp front end.
3032         * c-common.def (FOR_STMT, WHILE_STMT, DO_STMT): Move here from
3033         cp front end.
3034         (BREAK_STMT, CONTINUE_STMT, SWITCH_STMT): Likewise.
3035         * c-common.h (c_block_may_fallthru): Declare.
3036         (bc_state_t): Move here from cp front end.
3037         (save_bc_state, restore_bc_state): Declare.
3038         (c_genericize_control_stmt): Declare.
3039         (WHILE_COND, WHILE_BODY): Likewise.
3040         (DO_COND, DO_BODY): Likewise.
3041         (FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY, FOR_SCOPE): Likewise.
3042         (SWITCH_STMT_COND, SWITCH_STMT_BODY): Likewise.
3043         (SWITCH_STMT_TYPE, SWITCH_STMT_SCOPE): Likewise.
3044         (SWITCH_STMT_ALL_CASES_P, SWITCH_STMT_NO_BREAK_P): Likewise.
3045         (LABEL_DECL_BREAK, LABEL_DECL_CONTINUE): Likewise.
3046         * c-dump.c (dump_stmt): Copy from cp front end.
3047         (c_dump_tree): Move code to handle structured loop and switch
3048         tree nodes here from cp front end.
3049         * c-gimplify.c: Adjust includes.
3050         (enum bc_t, bc_label, begin_bc_block, finish_bc_block): Move from
3051         cp front end.
3052         (save_bc_state, restore_bc_state): New functions using old code
3053         from cp front end.
3054         (get_bc_label, expr_loc_or_loc): Move from cp front end.
3055         (genericize_c_loop): Move from cp front end.
3056         (genericize_for_stmt, genericize_while_stmt): Likewise.
3057         (genericize_do_stmt, genericize_switch_stmt): Likewise.
3058         (genericize_continue_stmt, genericize_break_stmt): Likewise.
3059         (genericize_omp_for_stmt): Likewise.
3060         (c_genericize_control_stmt): New function using code split from
3061         cp front end.
3062         (c_genericize_control_r): New.
3063         (c_genericize): Call walk_tree with c_genericize_control_r.
3064         * c-pretty-print.c (c_pretty_printer::statement): Move code to handle
3065         structured loop and switch tree nodes here from cp front end.
3067 2020-09-17  Patrick Palka  <ppalka@redhat.com>
3069         PR c/80076
3070         * c-indentation.c (should_warn_for_misleading_indentation): Move
3071         declarations of local variables closer to their first use.
3072         Handle virtual token locations by resolving them to their
3073         respective macro expansion points.  If all three tokens are
3074         produced from the same macro expansion, then instead use their
3075         loci within the macro definition.
3077 2020-09-16  Martin Sebor  <msebor@redhat.com>
3079         PR c/78666
3080         PR c/96126
3081         * c-attribs.c (validate_attr_args): New function.
3082         (validate_attr_arg): Same.
3083         (handle_section_attribute): Call it.  Introduce a local variable.
3084         (handle_alloc_size_attribute):  Same.
3085         (handle_alloc_align_attribute): Same.
3087 2020-09-14  Jakub Jelinek  <jakub@redhat.com>
3089         * c-attribs.c (handle_optimize_attribute): Adjust
3090         cl_optimization_save, cl_optimization_restore and
3091         build_optimization_node callers.
3092         * c-pragma.c (handle_pragma_optimize): Adjust
3093         build_optimization_node caller.
3094         (handle_pragma_push_options): Adjust
3095         build_optimization_node and build_target_option_node callers.
3096         (handle_pragma_pop_options, handle_pragma_reset_options):
3097         Adjust cl_optimization_restore callers.
3099 2020-08-28  Martin Sebor  <msebor@redhat.com>
3101         * c.opt (Wstringop-overread): New option.
3103 2020-08-11  Jakub Jelinek  <jakub@redhat.com>
3105         PR c/96545
3106         * c-common.c (get_atomic_generic_size): Require that first argument's
3107         type points to a complete type and use tree_fits_uhwi_p instead of
3108         just INTEGER_CST TREE_CODE check for the TYPE_SIZE_UNIT.
3110 2020-07-31  Martin Sebor  <msebor@redhat.com>
3112         PR c++/96003
3113         * c-common.c (check_function_arguments_recurse): Return early when
3114         no-warning bit is set.
3116 2020-07-31  Richard Biener  <rguenther@suse.de>
3118         PR debug/96383
3119         * c-common.h (c_common_finalize_early_debug): Declare.
3120         * c-common.c: Include debug.h.
3121         (c_common_finalize_early_debug): finalize_early_debug langhook
3122         implementation generating debug for extern declarations.
3124 2020-07-27  Nathan Sidwell  <nathan@acm.org>
3126         * c-common.c (try_to_locate_new_include_insertion_point): Use
3127         strcmp, not pointer equality.
3129 2020-07-25  Martin Sebor  <msebor@redhat.com>
3131         PR c++/96310
3132         * c-common.c (check_nonnull_arg): Print note only when warning was
3133         issued.
3135 2020-07-22  Tobias Burnus  <tobias@codesourcery.com>
3137         * c-omp.c (c_finish_omp_critical): Check for no name but
3138         nonzero hint provided.
3140 2020-07-20  Jason Merrill  <jason@redhat.com>
3142         * c-cppbuiltin.c (c_cpp_builtins): Update
3143         __cpp_nontype_template_args for C++20.
3145 2020-07-20  Martin Sebor  <msebor@redhat.com>
3147         PR c/96249
3148         * c.opt: Remove stray text.
3150 2020-07-14  Lewis Hyatt  <lhyatt@gmail.com>
3152         PR other/86904
3153         * c-indentation.c (should_warn_for_misleading_indentation): Get
3154         global tabstop from the new source.
3155         * c-opts.c (c_common_handle_option): Remove handling of -ftabstop, which
3156         is now a common option.
3157         * c.opt: Likewise.
3159 2020-07-08  Eric Botcazou  <ebotcazou@adacore.com>
3161         * c.opt (Wscalar-storage-order): Add explicit variable.
3163 2020-07-07  Nathan Sidwell  <nathan@acm.org>
3165         * c-opts.c (c_common_post_options): Add 'injecting' arg to
3166         cpp_read_main_file.
3167         (c_finish_options): Add linemap_line_start calls for builtin and cmd
3168         maps.  Force token position to line_table's highest line.
3169         * c-ppoutput.c (print_line_1): Refactor, print line zero.
3170         (cb_define): Always increment source line.
3172 2020-07-06  Martin Sebor  <msebor@redhat.com>
3174         PR c++/95984
3175         * c-common.c (check_function_nonnull): Avoid checking syntesized calls
3176         to stub lambda objects with null this pointer.
3177         (check_nonnull_arg): Handle C++ nullptr.
3179 2020-07-02  Jason Merrill  <jason@redhat.com>
3180             Jakub Jelinek  <jakub@redhat.com>
3182         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_consteval.
3184 2020-06-30  Jakub Jelinek  <jakub@redhat.com>
3186         PR c++/95963
3187         * c-common.c (check_function_arguments_recurse): Don't crash on
3188         calls to internal functions.
3190 2020-06-28  Martin Sebor  <msebor@redhat.com>
3192         PR c++/86568
3193         * c-common.c (struct nonnull_arg_ctx): Add members.
3194         (check_function_nonnull): Use nonnull_arg_ctx as argument.  Handle
3195         C++ member functions specially.  Consider the this pointer implicitly
3196         nonnull.
3197         (check_nonnull_arg): Use location of argument when available.
3198         (check_function_arguments): Use nonnull_arg_ctx as argument.
3200 2020-06-27  Jakub Jelinek  <jakub@redhat.com>
3202         PR middle-end/95903
3203         * c-common.c (pointer_int_sum): Use TYPE_OVERFLOW_UNDEFINED instead of
3204         !TYPE_UNSIGNED check to see if we can apply distributive law and handle
3205         smaller precision intop operands separately.
3207 2020-06-26  Marek Polacek  <polacek@redhat.com>
3209         * c-opts.c (c_common_init_options): Default to gnu++17.
3211 2020-06-17  Jonathan Wakely  <jwakely@redhat.com>
3213         PR c/95378
3214         * c-common.c (get_atomic_generic_size): Check cv-qualifiers in
3215         pointer arguments.
3217 2020-06-16  Jakub Jelinek  <jakub@redhat.com>
3219         * c-common.h (c_omp_check_loop_iv_exprs): Add an int argument.
3220         * c-omp.c (struct c_omp_check_loop_iv_data): Add maybe_nonrect and
3221         idx members.
3222         (c_omp_is_loop_iterator): New function.
3223         (c_omp_check_loop_iv_r): Use it.  Add support for silent scanning
3224         if outer loop iterator is present.  Perform duplicate checking through
3225         hash_set in the function rather than expecting caller to do that.
3226         Pass NULL instead of d->ppset to walk_tree_1.
3227         (c_omp_check_nonrect_loop_iv): New function.
3228         (c_omp_check_loop_iv): Use it.  Fill in new members, allow
3229         non-rectangular loop forms, diagnose multiple associated loops with
3230         the same iterator.  Pass NULL instead of &pset to walk_tree_1.
3231         (c_omp_check_loop_iv_exprs): Likewise.
3233 2020-06-10  Martin Liska  <mliska@suse.cz>
3235         PR tree-optimization/92860
3236         * c-attribs.c (handle_optimize_attribute):
3237         Save global options and compare it after parsing of function
3238         attribute.
3239         * c-pragma.c (opt_stack::saved_global_options): New field.
3240         (handle_pragma_push_options): Save global_options.
3241         (handle_pragma_pop_options): Compare them after pop.
3243 2020-06-09  Jakub Jelinek  <jakub@redhat.com>
3245         PR c/95580
3246         * c-pretty-print.c (c_pretty_printer::unary_expression): Handle the
3247         case when MEM_REF's first argument has type pointer to incomplete type.
3249 2020-06-05  Jason Merrill  <jason@redhat.com>
3251         * c-pretty-print.c (pp_c_additive_expression): Handle negative
3252         operand to POINTER_PLUS_EXPR.
3254 2020-06-04  Martin Sebor  <msebor@redhat.com>
3256         PR middle-end/10138
3257         PR middle-end/95136
3258         * c-attribs.c (append_access_attrs): Handle attr_access::none.
3259         (handle_access_attribute): Same.
3261 2020-06-03  Mark Wielaard  <mark@klomp.org>
3263         * known-headers.cc (get_cp_stdlib_header_for_string_macro_name):
3264         New function.
3265         * known-headers.h (get_cp_stdlib_header_for_string_macro_name):
3266         New function declaration.
3268 2020-06-03  Mark Wielaard  <mark@klomp.org>
3270         * known-headers.cc (get_string_macro_hint): New function.
3271         (get_stdlib_header_for_name): Use get_string_macro_hint.
3272         (get_c_stdlib_header_for_string_macro_name): New function.
3273         * known-headers.h (get_c_stdlib_header_for_string_macro_name):
3274         New function declaration.
3276 2020-06-03  Tobias Burnus  <tobias@codesourcery.com>
3278         * c-common.h (c_omp_predetermined_mapping): Declare.
3279         * c-omp.c (c_omp_predetermined_mapping): New.
3281 2020-05-22  Mark Wielaard  <mark@klomp.org>
3283         * known-headers.cc (get_stdlib_header_for_name): Add a new
3284         stdlib_hint array for stdbool and stdint.
3286 2020-05-22  Mark Wielaard  <mark@klomp.org>
3288         * known-headers.cc (get_stdlib_header_for_name): Return
3289         "<stdbool.h>" for "bool", "true" or "false" when STDLIB_C and
3290         flag_isoc99.
3292 2020-05-20  Nathan Sidwell  <nathan@acm.org>
3294         * c-common.c (try_to_locate_new_include_insertion_point): Revert change.
3296         * c-common.c (try_to_locate_new_include_insertion_point): Use
3297         strcmp to compare filenames.
3298         * c-lex.c (init_c_lex): Move declaration to initialization.
3299         * c-opts.c (handle_deferred_opts): Move cpp_get_deps call into
3300         deferred count loop.
3302 2020-05-15  Jason Merrill  <jason@redhat.com>
3304         * c-opts.c (set_std_cxx20): Set flag_coroutines.
3306 2020-05-13  Jason Merrill  <jason@redhat.com>
3308         * c.opt (std=c++20): Make c++2a the alias.
3309         (std=gnu++20): Likewise.
3310         * c-common.h (cxx_dialect): Change cxx2a to cxx20.
3311         * c-opts.c: Adjust.
3312         * c-cppbuiltin.c: Adjust.
3313         * c-ubsan.c: Adjust.
3314         * c-warn.c: Adjust.
3316 2020-05-12  Eric Botcazou  <ebotcazou@adacore.com>
3318         * c-ada-spec.c (dump_ads): Output pragma Warnings ("U"); on entry.
3320 2020-05-08  Nathan Sidwell  <nathan@acm.org>
3322         Reimplement directives only processing.
3323         * c-ppoutput.c (token_streamer): Ne.
3324         (directives_only_cb): New.  Swallow ...
3325         (print_lines_directives_only): ... this.
3326         (scan_translation_unit_directives_only): Reimplment using the
3327         published interface.
3329 2020-05-07  Marek Polacek  <polacek@redhat.com>
3331         * c-format.c (badwords): Add "nonstatic".
3333 202-05-07  Jakub Jelinek  <jakub@redhat.com>
3335         PR c/94968
3336         * c-common.c (speculation_safe_value_resolve_params): Return false if
3337         error_operand_p (val2).
3338         (resolve_overloaded_builtin) <case BUILT_IN_SPECULATION_SAFE_VALUE_N>:
3339         Remove extraneous semicolon.
3341 2020-05-06  qing zhao  <qing.zhao@oracle.com>
3343         PR c/94230
3344         * c-indentation.c (get_visual_column): Add a hint to use the new
3345         -flarge-source-files option.
3347 2020-05-05  Stefan Schulze Frielinghaus  <stefansf@linux.ibm.com>
3349         * c-attribs.c (handle_vector_size_attribute): Add attribute
3350         nonnull for argument args in order to silence warning of
3351         uninitialized variable usage.  Since this is local to the
3352         compilation unit and thus cannot be checked at call sides by the
3353         compiler, added an assert statement in order to verify this.
3355 2020-05-01  H.J. Lu  <hongjiu.lu@intel.com>
3357         PR target/93492
3358         * c-attribs.c (handle_patchable_function_entry_attribute): Limit
3359         value to USHRT_MAX (65535).
3361 2020-04-29  Jakub Jelinek  <jakub@redhat.com>
3363         * c-format.c (PP_FORMAT_CHAR_TABLE): Add %{ and %}.
3365 2020-04-27  Jakub Jelinek  <jakub@redhat.com>
3367         PR c/94755
3368         * c-common.c (resolve_overloaded_builtin): Return error_mark_node for
3369         fncode == BUILT_IN_NONE before initialization of first_param.
3371 2020-04-23  Marek Polacek  <polacek@redhat.com>
3373         PR c++/94733
3374         * c-attribs.c (find_tm_attribute): Use get_attribute_name instead of
3375         TREE_PURPOSE.
3377 2020-04-14  Patrick Palka  <ppalka@redhat.com>
3379         PR c++/85278
3380         * c-pretty-print.c (pp_c_pointer) <case REFERENCE_TYPE>: Print a double
3381         ampersand if it's an rvalue reference type.
3383 2020-04-13  Martin Sebor  <msebor@redhat.com>
3385         PR c/92326
3386         * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator): Avoid
3387         printing array bound for flexible array members.
3389 2020-04-13  Iain Sandoe  <iain@sandoe.co.uk>
3391         * c-cppbuiltin.c (c_cpp_builtins): Update coroutines builtin
3392         define, per n4861.
3394 2020-04-02  Richard Biener  <rguenther@suse.de>
3396         PR c/94392
3397         * c-opts.c (c_common_post_options): Enable -ffinite-loops
3398         for -O2 and C++11 or newer.
3400 2020-03-28  Patrick Palka  <ppalka@redhat.com>
3402         * c.opt: Add -fconcepts-diagnostics-depth.
3404 2020-03-27  Martin Sebor  <msebor@redhat.com>
3406         PR c++/94346
3407         * c-attribs.c (handle_copy_attribute): Avoid passing expressions
3408         to decl_attributes.  Make handling of different kinds of entities
3409         more robust.
3411 2020-03-27  Martin Sebor  <msebor@redhat.com>
3413         PR c++/94098
3414         * c-attribs.c (handle_access_attribute): Avoid setting TYPE_ATTRIBUTES
3415         here.
3417 2020-03-23  Jakub Jelinek  <jakub@redhat.com>
3419         PR c++/91993
3420         * c-warn.c (warnings_for_convert_and_check): For expr and/or
3421         result being COMPOUND_EXPRs, skip to ultimate rhs.
3423 2020-03-20  Richard Sandiford  <richard.sandiford@arm.com>
3425         PR middle-end/94072
3426         * c-common.c (c_common_type_for_mode): Before using a registered
3427         built-in type, check that the vectorness of the type matches
3428         the vectorness of the mode.
3430 2020-03-17  Jakub Jelinek  <jakub@redhat.com>
3432         * c-common.c (resolve_overloaded_builtin): Fix up duplicated word
3433         issue in a diagnostic message.
3435 2020-03-15  Lewis Hyatt  <lhyatt@gmail.com>
3437         * c.opt: Avoid redundancy in the help text.
3439 2020-03-02  Marek Polacek  <polacek@redhat.com>
3441         PR c++/93958 - add missing -std=gnu++20.
3442         * c.opt: Add -std=gnu++20.
3444 2020-03-01  Martin Sebor  <msebor@redhat.com>
3446         PR c++/92721
3447         * c-attribs.c (append_access_attrs): Correctly handle attribute.
3448         (handle_access_attribute): Same.
3450 2020-02-25  Jakub Jelinek  <jakub@redhat.com>
3452         PR c/93858
3453         * c-pragma.c (handle_pragma_diagnostic): Add missing ? after
3454         "did you mean" hint in diagnostics.
3456 2020-02-15  Jason Merrill  <jason@redhat.com>
3458         * c.opt: Add -std=c++20.
3460 2020-02-14  Eric Botcazou  <ebotcazou@adacore.com>
3462         * c-ada-spec.c: Include bitmap.h.
3463         (dump_ada_double_name): Rename into...
3464         (dump_anonymous_type_name): ...this.  Always use the TYPE_UID.
3465         (dump_ada_array_type): Adjust to above renaming.  Robustify.
3466         (dump_nested_types_1): New function copied from...  Add dumped_types
3467         parameter and pass it down to dump_nested_type.
3468         (dump_nested_types): ...this.  Remove parent parameter.  Just call
3469         dump_nested_types_1 on an automatic bitmap.
3470         (dump_nested_type): Add dumped_types parameter.
3471         <ARRAY_TYPE>: Do not dump it if already present in dumped_types.
3472         Adjust recursive calls and adjust to above renaming.
3473         (dump_ada_declaration): Adjust call to dump_nested_types.
3474         Tidy up and adjust to above renaming.
3475         (dump_ada_specs): Initialize and release bitmap obstack.
3477 2020-02-10  Martin Sebor  <msebor@redhat.com>
3479         PR c/93640
3480         * c-attribs.c (handle_access_attribute): Correct off-by-one mistakes.
3482 2020-02-10  Jakub Jelinek  <jakub@redhat.com>
3484         PR other/93641
3485         * c-format.c (check_plain): Fix up last argument of strncasecmp.
3486         Remove useless extra test.
3488 2020-02-03  Julian Brown  <julian@codesourcery.com>
3489             Tobias Burnus  <tobias@codesourcery.com>
3491         * c-cppbuiltin.c (c_cpp_builtins): Update _OPENACC define to 201711.
3493 2020-01-29  Jason Merrill  <jason@redhat.com>
3495         PR c++/89357
3496         * c-attribs.c (check_cxx_fundamental_alignment_constraints): Remove.
3498 2020-01-23  Jason Merrill  <jason@redhat.com>
3500         * c-warn.c (conversion_warning): Change -Wsign-conversion handling.
3502 2020-01-23  Martin Sebor  <msebor@redhat.com>
3504         PR c/84919
3505         * c-common.c (check_function_arguments): Avoid overlap checking
3506         of sprintf functions.
3508 2020-01-22  Jason Merrill  <jason@redhat.com>
3510         PR testsuite/93391 - PR 40752 test fails with unsigned plain char.
3511         PR c++/40752
3512         * c-warn.c (conversion_warning): Check operands only after checking
3513         the whole expression.  Don't check second operand of + for sign.
3515 2020-01-21  Jason Merrill  <jason@redhat.com>
3516             Manuel López-Ibáñez  <manu@gcc.gnu.org>
3518         PR c++/40752 - useless -Wconversion with short +=.
3519         * c.opt (-Warith-conversion): New.
3520         * c-warn.c (conversion_warning): Recurse for operands of
3521         operators.  Only warn about the whole expression with
3522         -Warith-conversion.
3524 2020-01-21  Jason Merrill  <jason@redhat.com>
3526         * c-common.c (unsafe_conversion_p): Don't warn, return UNSAFE_SIGN.
3527         * c-warn.c (conversion_warning): Warn about UNSAFE_SIGN.
3529 2020-01-20  Nathan Sidwell  <nathan@acm.org>
3531         PR preprocessor/80005
3532         * c-cppbuiltins.c (c_cpp_builtins): Don't define __has_include{,_next}.
3534 2020-01-18  Iain Sandoe  <iain@sandoe.co.uk>
3536         * c-common.c (co_await, co_yield, co_return): New.
3537         * c-common.h (RID_CO_AWAIT, RID_CO_YIELD,
3538         RID_CO_RETURN): New enumeration values.
3539         (D_CXX_COROUTINES): Bit to identify coroutines are active.
3540         (D_CXX_COROUTINES_FLAGS): Guard for coroutine keywords.
3541         * c-cppbuiltin.c (__cpp_coroutines): New cpp define.
3542         * c.opt (fcoroutines): New command-line switch.
3544 2020-01-10  David Malcolm  <dmalcolm@redhat.com>
3546         * c-format.c (local_event_ptr_node): New.
3547         (PP_FORMAT_CHAR_TABLE): Add entry for "%@".
3548         (init_dynamic_diag_info): Initialize local_event_ptr_node.
3549         * c-format.h (T_EVENT_PTR): New define.
3551 2020-01-10  Martin Sebor  <msebor@redhat.com>
3553         PR c/93132
3554         * c-attribs.c (append_access_attrs): Validate against the translated
3555         access string rather than the human-readable representation.
3557 2020-01-01  Jakub Jelinek  <jakub@redhat.com>
3559         Update copyright years.
3561 2019-12-20  Eric Botcazou  <ebotcazou@adacore.com>
3563         * c-ada-spec.h (decl_sloc): Delete.
3564         * c-ada-spec.c (decl_sloc): Make static.
3566 2019-12-19  Julian Brown  <julian@codesourcery.com>
3568         * c-common.h (c_omp_map_clause_name): Add prototype.
3569         * c-omp.c (c_omp_map_clause_name): New function.
3570         * c-pragma.h (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ATTACH and
3571         PRAGMA_OACC_CLAUSE_DETACH.
3573 2019-12-19  Julian Brown  <julian@codesourcery.com>
3574             Maciej W. Rozycki  <macro@codesourcery.com>
3575             Tobias Burnus  <tobias@codesourcery.com>
3576             Thomas Schwinge  <thomas@codesourcery.com>
3578         * c-pragma.h (pragma_omp_clause): Add
3579         PRAGMA_OACC_CLAUSE_NO_CREATE.
3581 2019-12-17  Martin Sebor  <msebor@redhat.com>
3583         PR c++/61339
3584         * c.opt (-Wmismatched-tags, -Wredundant-tags): New options.
3586 2019-12-11  David Malcolm  <dmalcolm@redhat.com>
3588         * c-pretty-print.c (c_pretty_printer::clone): New vfunc
3589         implementation.
3590         * c-pretty-print.h (c_pretty_printer::clone): New vfunc decl.
3592 2019-12-09  David Malcolm  <dmalcolm@redhat.com>
3594         * c-format.c (range_label_for_format_type_mismatch::get_text):
3595         Replace label_text ctor called with true with label_text::take.
3597 2019-12-09  David Malcolm  <dmalcolm@redhat.com>
3599         * c-format.c (selftest::test_type_mismatch_range_labels): Remove
3600         initial newline from expected outputs.
3601         * c-opts.c (c_diagnostic_finalizer): Add pp_newline call before
3602         call to diagnostic_show_locus.
3604 2019-12-06  Jakub Jelinek  <jakub@redhat.com>
3606         * c-cppbuiltin.c (c_cpp_builtins): Don't define __cpp_consteval for
3607         now.
3609 2019-12-05  Marek Polacek  <polacek@redhat.com>
3610             Jakub Jelinek  <jakub@redhat.com>
3612         PR c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.
3613         * c-cppbuiltin.c (c_cpp_builtins): Adjust the value of __cpp_constexpr.
3615 2019-12-05  Marek Polacek  <polacek@redhat.com>
3617         PR c++/92271 - make __is_same alias for __is_same_as.
3618         * c-common.c: Add __is_same, an alias for __is_same_as.
3620 2019-12-03  Marek Polacek  <polacek@redhat.com>
3622         PR c++/91363 - P0960R3: Parenthesized initialization of aggregates.
3623         * c-cppbuiltin.c (c_cpp_builtins): Predefine
3624         __cpp_aggregate_paren_init=201902 for -std=c++2a.
3626 2019-11-30  Jan Hubicka  <hubicka@ucw.cz>
3628         * c-attribs.c (handle_symver_attribute): New function
3629         (c_common_attributes): Add symver.
3631 2019-11-30  Richard Sandiford  <richard.sandiford@arm.com>
3633         * c-common.c (pointer_int_sum): Use verify_type_context to check
3634         whether the target allows pointer arithmetic for the types involved.
3635         (c_sizeof_or_alignof_type, c_alignof_expr): Use verify_type_context
3636         to check whether the target allows sizeof and alignof operations
3637         for the types involved.
3639 2019-11-27  Jason Merrill  <jason@redhat.com>
3641         * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
3643 2019-11-26  Jakub Jelinek  <jakub@redhat.com>
3645         PR c++/61414
3646         * c-attribs.c (handle_mode_attribute): Add mode attribute to
3647         ENUMERAL_TYPEs.
3649 2019-11-25  Joseph Myers  <joseph@codesourcery.com>
3651         PR c/91985
3652         * c-common.c (c_common_type_for_mode): Handle decimal
3653         floating-point types being NULL_TREE.
3654         * c-format.c (get_format_for_type_1): Handle specified types being
3655         NULL_TREE.
3656         * c-lex.c (interpret_float): Give an error for decimal
3657         floating-point constants when decimal floating-point not
3658         supported.
3660 2019-11-23  Jakub Jelinek  <jakub@redhat.com>
3662         PR middle-end/83859
3663         * c-attribs.c (append_access_attrs): Avoid buffer overflow.  Avoid
3664         memory leak.  Use XNEWVEC macro.  Use auto_diagnostic_group to
3665         group warning with inform together.
3666         (handle_access_attribute): Formatting fix.
3668 2019-11-22  Jakub Jelinek  <jakub@redhat.com>
3670         PR c/90677
3671         * c-common.h (identifier_global_tag): Declare.
3672         * c-format.c (get_pointer_to_named_type): Renamed to ...
3673         (get_named_type): ... this.  Use identifier_global_tag instead of
3674         identifier_global_value, handle the return value being a TYPE_P.
3675         (init_dynamic_diag_info): Adjust get_pointer_to_named_type callers
3676         to call get_named_type instead.  Formatting fixes.
3678         Implement P1902R1, Missing feature-test macros 2017-2019.
3679         * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_init_captures
3680         and __cpp_generic_lambdas for -std=c++2a.  Define
3681         __cpp_designated_initializers, __cpp_constexpr_in_decltype and
3682         __cpp_consteval for -std=c++2a.  Remove a FIXME comment about
3683         __cpp_concepts for -std=c++2a.
3685 2019-11-22  Martin Sebor  <msebor@redhat.com>
3687         PR middle-end/83859
3688         * c-attribs.c (handle_access_attribute): New function.
3689         (c_common_attribute_table): Add new attribute.
3690         (get_argument_type): New function.
3691         (append_access_attrs): New function.
3692         (get_nonnull_operand): Rename...
3693         (get_attribute_operand): ...to this.
3694         * c-common.c (get_nonnull_operand): Rename...
3695         (get_attribute_operand): ...to this.
3697 2019-11-21  Joseph Myers  <joseph@codesourcery.com>
3699         * c-attribs.c (handle_fallthrough_attribute): Use pedwarn instead
3700         of warning.
3702 2019-11-19  Joseph Myers  <joseph@codesourcery.com>
3704         * c-common.c (attribute_fallthrough_p): In C, use pedwarn not
3705         warning for standard attributes mixed with fallthrough attributes.
3707 2019-11-15  Joseph Myers  <joseph@codesourcery.com>
3709         * c-attribs.c (handle_fallthrough_attribute): Remove static.
3710         * c-common.h (handle_fallthrough_attribute): Declare.
3712 2019-11-15  Joseph Myers  <joseph@codesourcery.com>
3714         * c-attribs.c (handle_deprecated_attribute): Remove static.
3715         * c-common.h (handle_deprecated_attribute): Declare.
3717 2019-11-14  Joseph Myers  <joseph@codesourcery.com>
3719         * c-lex.c (lex_charconst): Make CPP_UTF8CHAR constants unsigned
3720         char for C.
3722 2019-11-14  Jakub Jelinek  <jakub@redhat.com>
3724         * c-omp.c (c_omp_check_context_selector): Add nvidia to the list of
3725         valid vendors.
3727         * c-omp.c (c_omp_check_context_selector): Handle name lists
3728         containing string literals.  Don't diagnose atomic_default_mem_order
3729         with multiple props.
3731 2019-11-13  Joseph Myers  <joseph@codesourcery.com>
3733         * c-cppbuiltin.c (builtin_define_float_constants): Also define
3734         NORM_MAX constants.  Update call to get_max_float.
3735         (LAZY_HEX_FP_VALUES_CNT): Update value to include NORM_MAX
3736         constants.
3738 2019-11-13  Eric Botcazou  <ebotcazou@adacore.com>
3740         * c-ada-spec.c (get_underlying_decl): Do not look through typedefs.
3741         (dump_forward_type): Do not generate a declaration for function types.
3742         (dump_nested_type) <ARRAY_TYPE>: Do not generate a nested declaration
3743         of the component type if it is declared in another file.
3745 2019-11-12  Martin Liska  <mliska@suse.cz>
3747         * c-opts.c (c_common_post_options):
3748         Use SET_OPTION_IF_UNSET.
3750 2019-11-12  Maciej W. Rozycki  <macro@codesourcery.com>
3751             Frederik Harwath  <frederik@codesourcery.com>
3753         gcc/c-family/
3754         * c-pragma.h (pragma_kind): Add PRAGMA_OACC_SERIAL enumeration
3755         constant.
3756         * c-pragma.c (oacc_pragmas): Add "serial" entry.
3758 2019-11-08  Richard Sandiford  <richard.sandiford@arm.com>
3760         * c-common.h (gnu_vector_type_p): New function.
3761         * c-common.c (c_build_vec_perm_expr): Require __builtin_shuffle
3762         vectors to satisfy gnu_vector_type_p.
3763         (c_build_vec_convert): Likewise __builtin_convertvector.
3764         (convert_vector_to_array_for_subscript): Likewise when applying
3765         implicit vector to array conversion.
3766         (scalar_to_vector): Likewise when converting vector-scalar
3767         operations to vector-vector operations.
3769 2019-11-08  Joseph Myers  <joseph@codesourcery.com>
3771         * c.opt (Wold-style-definition): Initialize to -1.
3772         * c-opts.c (c_common_post_options): Set warn_old_style_definition
3773         to flag_isoc2x if not set explicitly.
3775 2019-11-07  Joseph Myers  <joseph@codesourcery.com>
3777         * c-attribs.c (parse_tm_stmt_attr): Handle scoped attributes.
3779 2019-11-05  Jason Merrill  <jason@redhat.com>
3781         * c-opts.c (c_common_post_options): -fconcepts-ts implies
3782         -fconcepts.
3784 2019-11-04  Kamlesh Kumar  <kamleshbhalui@gmail.com>
3786         * c-opts.c (c_common_post_options): Update
3787         latest_abi_version.
3789 2019-11-02  Jakub Jelinek  <jakub@redhat.com>
3791         * c-common.h (c_omp_get_context_selector): Remove.
3792         * c-omp.c (c_omp_get_context_selector): Moved to omp-general.c
3793         and renamed to omp_get_context_selector.
3795         * c-omp.c (c_omp_mark_declare_variant): Use
3796         omp_context_selector_set_compare.
3798         PR c++/88335 - Implement P1073R3: Immediate functions
3799         * c-common.h (enum rid): Add RID_CONSTEVAL.
3800         * c-common.c (c_common_reswords): Add consteval.
3802 2019-11-01  Martin Sebor  <msebor@redhat.com>
3804         PR middle-end/91679
3805         PR middle-end/91647
3806         PR middle-end/91463
3807         PR middle-end/92312
3808         * c-pretty-print.c (direct_abstract_declarator): Print
3809         bound in zero-length arrays.
3810         * c.opt (-Wzero-length-bounds): New option.
3812 2019-10-30  Nathan Sidwell  <nathan@acm.org>
3814         * c-cppbuiltin.c (c_cpp_builtins): Add 'L' suffix to feature
3815         macros.
3817 2019-10-28  Martin Sebor  <msebor@redhat.com>
3819         PR c/66970
3820         * c-common.c (c_common_nodes_and_builtins): Call c_define_builtins
3821         even when only preprocessing.
3822         * c-common.h (names_builtin_p): Declare new function.
3823         * c-lex.c (init_c_lex): Set has_builtin.
3824         (c_common_has_builtin): Define a new function.
3825         * c-ppoutput.c (init_pp_output): Set has_builtin.
3827 2019-10-24  Jakub Jelinek  <jakub@redhat.com>
3829         * c-common.h (c_omp_context_selector_matches): Remove.
3830         * c-omp.c (c_omp_context_selector_matches): Remove.
3831         * c-attribs.c (c_common_attribute_table): Add
3832         "omp declare target {host,nohost,block}" attributes.
3834 2019-10-17  JeanHeyd Meneide  <phdofthehouse@gmail.com>
3836         * c-lex.c (c_common_has_attribute): Update nodiscard value.
3838 2019-10-14  Richard Sandiford  <richard.sandiford@arm.com>
3840         * c-common.h (user_facing_original_type_p): Declare.
3841         * c-common.c: Include c-spellcheck.h.
3842         (user_facing_original_type_p): New function.
3844 2019-10-12  Jakub Jelinek  <jakub@redhat.com>
3846         * c-common.h (c_omp_mark_declare_variant,
3847         c_omp_context_selector_matches): Declare.
3848         * c-omp.c: Include attribs.h, gimplify.h, cgraph.h, symbol-summary.h
3849         and hsa-common.h.
3850         (c_omp_get_context_selector): Support second argument NULL.
3851         (c_omp_mark_declare_variant, c_omp_context_selector_matches): New
3852         functions.
3853         * c-attribs.c (c_common_attribute_table): Remove "omp declare variant"
3854         attribute, add "omp declare variant base" and
3855         "omp declare variant variant" attributes.
3857 2019-10-11  Joseph Myers  <joseph@codesourcery.com>
3859         * c.opt (Wc11-c2x-compat): Add CPP(cpp_warn_c11_c2x_compat)
3860         CppReason(CPP_W_C11_C2X_COMPAT).
3862 2019-10-11  Joseph Myers  <joseph@codesourcery.com>
3864         * c-common.c (c_common_reswords): Do not use D_EXT for _Decimal32,
3865         _Decimal64 and _Decimal128.
3867 2019-10-10  Joseph Myers  <joseph@codesourcery.com>
3869         * c-cppbuiltin.c (c_cpp_builtins): Do not define macros for DFP
3870         types if DFP not supported.
3872 2019-10-10  Jakub Jelinek  <jakub@redhat.com>
3874         * c-common.h (c_omp_check_context_selector,
3875         c_omp_get_context_selector): Declare.
3876         * c-omp.c (c_omp_declare_simd_clauses_to_numbers): Fix spelling
3877         in diagnostic message.
3878         (c_omp_check_context_selector, c_omp_get_context_selector): New
3879         functions.
3880         * c-attribs.c (c_common_attribute_table): Add "omp declare variant"
3881         attribute.
3882         (handle_omp_declare_variant_attribute): New function.
3884 2019-10-09  Martin Sebor  <msebor@redhat.com>
3886         PR tree-optimization/90879
3887         * c.opt (-Wstring-compare): New option.
3889 2019-10-08  Andrew Sutton  <asutton@lock3software.com>
3890             Jason Merrill  <jason@redhat.com>
3892         Update the concepts implementation to conform to the C++20
3893         specification, improve compile times, and generally clean up
3894         the implementation.
3896         * c-cppbuiltin.c (c_cpp_builtins): Use new feature test values for
3897         concepts when -std=c++2a. Bump __cpp_concepts to 201907.
3898         * c.opt: Add -Wconcepts-ts.
3899         * c-opts.c (c_common_post_options): Warn when -fconcepts is used
3900         with -std=c++2a. Disable warning for -fconcepts in C++20 mode.
3901         (set_std_cxx2a): Enable concepts by default.
3903 2019-10-08  Joseph Myers  <joseph@codesourcery.com>
3905         * c-opts.c (c_common_post_options): Set
3906         -fno-fp-int-builtin-inexact for C2X.
3908 2019-10-05  Jakub Jelinek  <jakub@redhat.com>
3910         PR c++/91369 - Implement P0784R7: constexpr new
3911         * c-cppbuiltin.c (c_cpp_builtins): Predefine
3912         __cpp_constexpr_dynamic_alloc=201907 for -std=c++2a.
3914 2019-10-04  Joseph Myers  <joseph@codesourcery.com>
3916         PR c/82752
3917         * c-format.c (C_STD_VER): Handle C2x.
3918         (C_STD_NAME): Likewise.
3919         (strftime_flag_specs): Add 'O' modifier with 'p' flag.
3920         (time_char_table): Use separate entry for 'B' and 'b', with 'O'
3921         modifier allowed and 'p' flag.
3922         * c-format.h (enum format_std_version): Add STD_C2X.
3923         (struct format_char_info): Mention 'p' in comment on flags2.
3925 2019-10-01  David Malcolm  <dmalcolm@redhat.com>
3927         * c-opts.c (c_diagnostic_finalizer): Temporarily clear prefix when
3928         calling diagnostic_show_locus, rather than destroying it afterwards.
3930 2019-10-01  Jakub Jelinek  <jakub@redhat.com>
3932         PR c++/91925
3933         * c-warn.c (check_alignment_of_packed_member): Ignore FIELD_DECLs
3934         with NULL DECL_FIELD_OFFSET.
3936 2019-10-01  Richard Sandiford  <richard.sandiford@arm.com>
3938         * c-pretty-print.c (pp_c_specifier_qualifier_list): If a vector type
3939         has a type name, use it in preference to the __vector syntax.
3941 2019-09-30  Richard Sandiford  <richard.sandiford@arm.com>
3943         * c-pretty-print.c (pp_c_parameter_type_list): Avoid printing
3944         two spaces between a comma and "...".
3946 2019-09-27  Jakub Jelinek  <jakub@redhat.com>
3948         PR c++/88203
3949         * c-common.h (c_omp_predefined_variable): Declare.
3950         * c-omp.c (c_omp_predefined_variable): New function.
3951         (c_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
3952         for predefined variables.
3954 2019-09-27  Richard Sandiford  <richard.sandiford@arm.com>
3956         * c-common.h (build_function_call_vec): Take the original
3957         function decl as an optional final parameter.
3958         (check_builtin_function_arguments): Take the original function decl.
3959         * c-common.c (check_builtin_function_arguments): Likewise.
3960         Handle all built-in functions, not just BUILT_IN_NORMAL ones.
3961         Use targetm.check_builtin_call to check BUILT_IN_MD functions.
3963 2019-09-15  Jason Merrill  <jason@redhat.com>
3965         * c-warn.c (warn_logical_operator): Strip location wrappers.  Don't
3966         fold_for_warn in "|| mask" warning.
3968 2019-09-10  Martin Liska  <mliska@suse.cz>
3970         * c.opt: Use newly added WarnRemoved.
3972 2019-09-09  Martin Liska  <mliska@suse.cz>
3974         * c.opt: Update comment of removed
3975         options that are preserved only for backward
3976         compatibility.
3978 2019-09-06  Martin Liska  <mliska@suse.cz>
3980         PR c++/91125
3981         * c-common.c: Remove definition of flag_use_repository.
3982         * c-common.h: Likewise.
3983         * c-opts.c (c_common_handle_option):
3984         Do not handle OPT_frepo option.
3985         * c.opt: Mark the option with Deprecated.
3987 2019-09-04  Marek Polacek  <polacek@redhat.com>
3989         * c.opt (fdeduce-init-list): Ignored.
3991 2019-09-04  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
3993         PR c/78736
3994         * c.opt (Wenum-conversion): New option.
3996 2019-09-03  Jozef Lawrynowicz  <jozef.l@mittosystems.com>
3998         * c-attribs.c (handle_section_attribute): Call the
3999         handle_generic_attribute target hook after performing target
4000         independent processing.
4001         (handle_noinit_attribute): Likewise.
4003 2019-09-03  Ian Lance Taylor  <iant@golang.org>
4005         * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Always expand
4006         when using -fgo-dump-spec.
4008 2019-09-02  Martin Liska  <mliska@suse.cz>
4010         PR c++/91155
4011         * c-common.c (fname_as_string): Use cxx_printable_name for
4012         __PRETTY_FUNCTION__ same as was used before r265711.
4014 2019-08-28  Marek Polacek  <polacek@redhat.com>
4016         Implement P1152R4: Deprecating some uses of volatile.
4017         PR c++/91361
4018         * c-opts.c (c_common_post_options): Enable -Wvolatile by
4019         default for C++2a, unless -Wno-deprecated.
4020         * c.opt (Wvolatile): New warning.
4022 2019-08-28  Marek Polacek  <polacek@redhat.com>
4024         PR c++/91360 - Implement C++20 P1143R2: constinit.
4025         * c-common.c (c_common_reswords): Add constinit and __constinit.
4026         (keyword_is_decl_specifier): Handle RID_CONSTINIT.
4027         * c-common.h (enum rid): Add RID_CONSTINIT, RID_FIRST_CXX20, and
4028         RID_LAST_CXX20.
4029         (D_CXX20): Define.
4030         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_constinit.
4031         * c-format.c (cxx_keywords): Add "constinit".
4032         * c.opt (Wc++2a-compat, Wc++20-compat): New options.
4034 2019-08-27  Jakub Jelinek  <jakub@redhat.com>
4036         PR c++/91415
4037         * c-common.c (verify_tree): For LSHIFT_EXPR, RSHIFT_EXPR,
4038         COMPONENT_REF and ARRAY_REF in cxx_dialect >= cxx17 mode handle it
4039         like COMPOUND_EXPR rather than normal expression.
4041 2019-08-23  Iain Sandoe  <iain@sandoe.co.uk>
4043         PR pch/61250
4044         * c-lex.c (c_lex_with_flags):  Don't call
4045         c_common_no_more_pch () from here.
4047 2019-08-23  Jakub Jelinek  <jakub@redhat.com>
4049         PR middle-end/91283
4050         * c-common.c (c_ts18661_flt_eval_method): Use flag_excess_precision
4051         instead of flag_excess_precision_cmdline.
4052         * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): Likewise.
4053         * c-opts.c (c_common_post_options): Likewise.
4055 2019-08-22  Martin Sebor  <msebor@redhat.com>
4057         PR middle-end/91490
4058         * c-common.c (braced_list_to_string): Add argument and overload.
4059         Handle flexible length arrays and unions.
4061 2019-08-21  Eric Botcazou  <ebotcazou@adacore.com>
4063         * c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
4064         function declarations where arguments are missing.  Rename variables.
4066 2019-08-15  Richard Biener  <rguenther@suse.de>
4068         * c-common.c (c_stddef_cpp_builtins): When the GIMPLE FE is
4069         enabled, define __SIZETYPE__.
4071 2019-08-14  Christophe Lyon  <christophe.lyon@linaro.org>
4073         * c-attribs.c (c_common_attribute_table): Add "noinit" entry. Add
4074         exclusion with "section" attribute.
4075         (attr_noinit_exclusions): New table.
4076         (handle_noinit_attribute): New function.
4078 2019-08-13  Richard Sandiford  <richard.sandiford@arm.com>
4080         PR middle-end/91421
4081         * c-common.c (resolve_overloaded_builtin): Use
4082         copy_decl_built_in_function.
4084 2019-08-13  Martin Sebor  <msebor@redhat.com>
4086         PR c/80619
4087         * c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
4088         (asm_fprintf_length_spec): Same.
4089         * c-format.h (format_lengths): Add FMT_LEN_w.
4091 2019-08-10  Jakub Jelinek  <jakub@redhat.com>
4093         * c-pragma.h (enum pragma_omp_clause): Add
4094         PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
4096 2019-08-07  Jakub Jelinek  <jakub@redhat.com>
4098         * c-pragma.h (enum pragma_omp_clause): Add
4099         PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR.  Set PRAGMA_OACC_CLAUSE_USE_DEVICE
4100         equal to PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR instead of being a separate
4101         enumeration value.
4103 2019-08-05  Marek Polacek  <polacek@redhat.com>
4105         PR c++/91338 - Implement P1161R3: Deprecate a[b,c].
4106         * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
4107         default for C++2a, unless -Wno-deprecated.
4108         * c.opt (Wcomma-subscript): New warning.
4110 2019-07-20  Jakub Jelinek  <jakub@redhat.com>
4112         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_LOOP.
4113         (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_BIND.
4114         * c-pragma.c (omp_pragmas_simd): Add PRAGMA_OMP_LOOP entry.
4115         * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_LOOP.
4116         * c-omp.c (c_omp_split_clauses): Add support for 4 new combined
4117         constructs with the loop construct.
4119 2019-07-13  Jakub Jelinek  <jakub@redhat.com>
4121         PR c/91149
4122         * c-omp.c (c_omp_split_clauses): Fix a pasto in
4123         OMP_CLAUSE_REDUCTION_TASK handling.
4125 2019-07-12  Jakub Jelinek  <jakub@redhat.com>
4127         * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ORDER.
4128         * c-omp.c (c_omp_split_clauses): Handle splitting of OMP_CLAUSE_ORDER.
4130 2019-07-09  Martin Sebor  <msebor@redhat.com>
4132         PR c++/61339
4133         * c-opts.c (handle_deferred_opts): Change class-key of PODs to struct
4134         and others to class.
4135         * c-pretty-print.h: Same.
4137 2019-07-09  Martin Sebor  <msebor@redhat.com>
4139         PR c++/61339
4140         * c-format.c (check_argument_type): Change class-key from class to
4141         struct and vice versa to match convention and avoid -Wclass-is-pod
4142         and -Wstruct-no-pod.
4143         * c-pretty-print.h: Same.
4145 2019-07-03  Martin Liska  <mliska@suse.cz>
4147         * c-common.c (try_to_locate_new_include_insertion_point): Remove
4148         dead assignemts.
4150 2019-07-03  Jakub Jelinek  <jakub@redhat.com>
4152         * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_REDUCTION_INSCAN
4153         clauses on OMP_FOR rather than OMP_PARALLEL when OMP_FOR is combined
4154         with OMP_PARALLEL.
4156 2019-07-02  qing zhao  <qing.zhao@oracle.com>
4158         PR preprocessor/90581
4159         * c-opts.c (c_common_handle_option): Handle -fmax-include-depth.
4160         * c.opt: Add new option -fmax-include-depth.
4162 2019-06-26  Jason Merrill  <jason@redhat.com>
4164         PR c++/55442 - memory-hog with highly recursive constexpr.
4165         * c.opt (fconstexpr-loop-limit): New.
4167 2019-06-25  Jakub Jelinek  <jakub@redhat.com>
4169         PR sanitizer/90954
4170         * c-omp.c (c_finish_omp_atomic): Allow tree_invariant_p in addition
4171         to SAVE_EXPR in first operand of a COMPOUND_EXPR.
4173 2019-06-25  Jozef Lawrynowicz  <jozef.l@mittosystems.com>
4175         * c-common.c (c_common_nodes_and_builtins): Define
4176         alternate "__intN__" name for "__intN" types.
4178 2019-06-24  Jan Hubicka  <jh@suse.cz>
4180         * c-common.c (braced_lists_to_strings): Check that
4181         type is array or integer prior checking string flag.
4183 2019-06-21  Matthew Beliveau  <mbelivea@redhat.com>
4185         PR c++/90875 - added -Wswitch-outside-range option
4186         * c.opt (Wswitch-outside-range): Added new option.
4187         * c-warn.c (c_do_switch_warnings): Use OPT_Wswitch-outside-range.
4189 2019-06-21  Marek Polacek  <polacek@redhat.com>
4191         PR c++/90953 - ICE with -Wmissing-format-attribute.
4192         * c-common.c (check_function_arguments_recurse): Use
4193         get_attribute_name.
4194         (check_missing_format_attribute): Likewise.
4196 2019-06-19  Marek Polacek  <polacek@redhat.com>
4198         PR c++/60364 - noreturn after first decl not diagnosed.
4199         * c-attribs.c (handle_noreturn_attribute): No longer static.
4200         * c-common.h (handle_noreturn_attribute, attr_noreturn_exclusions):
4201         Declare.
4202         * c-format.c (check_function_format): Use get_attribute_name.
4204 2019-06-19  Martin Sebor  <msebor@redhat.com>
4206         PR translation/90156
4207         * c-format.c (function_format_info::format_type): Adjust type.
4208         (function_format_info::is_raw): New member.
4209         (decode_format_type): Adjust signature.  Handle "raw" diag attributes.
4210         (decode_format_attr): Adjust call to decode_format_type.
4211         Avoid a redundant call to convert_format_name_to_system_name.
4212         Avoid abbreviating the word "arguments" in a diagnostic.
4213         (format_warning_substr): New function.
4214         (avoid_dollar_number): Quote dollar sign in a diagnostic.
4215         (finish_dollar_format_checking): Same.
4216         (check_format_info): Same.
4217         (struct baltoks_t): New.
4218         (c_opers, c_keywords, cxx_keywords, badwords, contrs): New arrays.
4219         (maybe_diag_unbalanced_tokens, check_tokens, check_plain): New
4220         functions.
4221         (check_format_info_main): Call check_plain.  Use baltoks_t.  Call
4222         maybe_diag_unbalanced_tokens.
4223         (handle_format_attribute): Spell out the word "arguments" in
4224         a diagnostic.
4226 2019-06-11  Matthew Beliveau  <mbelivea@redhat.com>
4228         PR c++/90449 - add -Winaccessible-base option.
4229         * c.opt (Winaccessible-base): New option.
4231 2019-06-10  Jakub Jelinek  <jakub@redhat.com>
4233         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCAN.
4234         * c-pragma.c (omp_pragmas_simd): Add #pragma omp scan.
4235         * c-omp.c (c_omp_split_clauses): Diagnose inscan reductions on
4236         combined/composite constructs where it is not allowed.  Copy over
4237         OMP_CLAUSE_REDUCTION_INSCAN.
4239 2019-06-05  Martin Sebor  <msebor@redhat.com>
4241         * c-attribs.c (handle_mode_attribute): Adjust quoting and hyphenation.
4242         (handle_alias_ifunc_attribute): Same.
4243         (handle_copy_attribute): Same.
4244         (handle_weakref_attribute): Same.
4245         (handle_nonnull_attribute): Same.
4246         * c-warn.c (warn_for_sign_compare): Same.
4247         (warn_for_restrict): Same.
4248         * c.opt: Same.
4250 2019-06-05  Martin Sebor  <msebor@redhat.com>
4252         * c-pragma.c (handle_pragma_weak): Adjust quoting in a diagnostic.
4253         * c.opt (-Wformat-diag): Remove a spurious period.
4255 2019-05-29  Jakub Jelinek  <jakub@redhat.com>
4257         PR c/90628
4258         * c-common.c (check_builtin_function_arguments)
4259         <case BUILTIN_*_OVERFLOW>: Diagnose pointer to const qualified integer
4260         as last argument.
4262 2019-05-23  Eric Botcazou  <ebotcazou@adacore.com>
4264         * c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
4266 2019-05-22  Martin Liska  <mliska@suse.cz>
4268         PR lto/90500
4269         * c-attribs.c (handle_copy_attribute): Do not copy
4270         target_clones attribute.
4272 2019-05-21  Eric Botcazou  <ebotcazou@adacore.com>
4274         * c-ada-spec.h (enum cpp_operation): Add IS_ASSIGNMENT_OPERATOR.
4275         * c-ada-spec.c (print_assignment_operator): New function.
4276         (dump_ada_declaration) <FUNCTION_DECL>: Call it do dump explicit copy
4277         assignment operators declared as methods and filter out the others.
4279 2019-05-17  Thomas Schwinge  <thomas@codesourcery.com>
4281         PR c/89433
4282         * c-attribs.c (c_common_attribute_table): Set min_len to -1 for
4283         "omp declare target".
4285 2019-05-16  Martin Sebor  <msebor@redhat.com>
4287         * c-attribs.c (handle_no_sanitize_attribute): Quote identifiers,
4288         keywords, operators, and types in diagnostics.
4289         (handle_scalar_storage_order_attribute): Same.
4290         (handle_mode_attribute): Same.
4291         (handle_visibility_attribute): Same.
4292         (handle_assume_aligned_attribute): Same.
4293         (handle_no_split_stack_attribute): Same.
4294         * c-common.c (shorten_compare): Same.
4295         (c_common_truthvalue_conversion): Same.
4296         (cb_get_source_date_epoch): Same.
4297         * c-lex.c (cb_def_pragma): Quote keywords, operators, and types
4298         in diagnostics.
4299         (interpret_float): Same.
4300         * c-omp.c (c_finish_omp_for): Same.
4301         * c-opts.c (c_common_post_options): Same.
4302         * c-pch.c (c_common_pch_pragma): Same.
4303         * c-pragma.c (pop_alignment): Same.
4304         (handle_pragma_pack): Same.
4305         (apply_pragma_weak): Same.
4306         (handle_pragma_weak): Same.
4307         (handle_pragma_scalar_storage_order): Same.
4308         (handle_pragma_redefine_extname): Same.
4309         (add_to_renaming_pragma_list): Same.
4310         (maybe_apply_renaming_pragma): Same.
4311         (push_visibility): Same.
4312         (handle_pragma_visibility): Same.
4313         (handle_pragma_optimize): Same.
4314         (handle_pragma_message): Same.
4315         * c-warn.c (warn_for_omitted_condop): Same.
4316         (lvalue_error): Same.
4318 2019-05-15  Richard Biener  <rguenther@suse.de>
4320         PR c/90474
4321         * c-common.c (c_common_mark_addressable_vec): Also mark
4322         a COMPOUND_LITERAL_EXPR_DECL addressable similar to
4323         c_mark_addressable.
4325 2019-05-06  Nathan Sidwell  <nathan@acm.org>
4327         * c-opts.c (handle_defered_opts): Rename struct deps to struc mkdeps.
4329 2019-04-30  Nathan Sidwell  <nathan@acm.org>
4331         * c-common.c (c_common_init_ts): Use MARK_TS_EXP.  Mark SIZEOF_EXPR.
4333 2019-04-30  Martin Liska  <mliska@suse.cz>
4335         * c-pragma.c (handle_pragma_diagnostic): Provide hints
4336         for unknown options.
4338 2019-04-26  Richard Sandiford  <richard.sandiford@arm.com>
4340         * c-warn.c (strict_aliasing_warning): Apply COMPLETE_TYPE_P to
4341         the pointer target rather than the pointer itself.
4343 2019-04-19  Jakub Jelinek  <jakub@redhat.com>
4345         PR c/89888
4346         * c-common.h (c_add_case_label): Remove orig_type and outside_range_p
4347         arguments.
4348         (c_do_switch_warnings): Remove outside_range_p argument.
4349         * c-common.c (check_case_bounds): Removed.
4350         (c_add_case_label): Remove orig_type and outside_range_p arguments.
4351         Don't call check_case_bounds.  Fold low_value as well as high_value.
4352         * c-warn.c (c_do_switch_warnings): Remove outside_range_p argument.
4353         Check for case labels outside of range of original type here and
4354         adjust them.
4356 2019-04-12  Jakub Jelinek  <jakub@redhat.com>
4358         PR translation/90041
4359         * c.opt (-fhandle-exceptions): Use %< and %> around option names
4360         in the Warn diagnostics.
4362         PR c/89946
4363         * c-attribs.c (handle_patchable_function_entry_attribute): Add
4364         function comment.  Warn if arguments of the attribute are not positive
4365         integer constants.
4367 2019-04-09  Eric Botcazou  <ebotcazou@adacore.com>
4369         * c-ada-spec.c (print_destructor): Deal with deleting destructors.
4370         (dump_ada_declaration) <FUNCTION_DECL>: Likewise.
4372 2019-04-07  Eric Botcazou  <ebotcazou@adacore.com>
4374         * c-ada-spec.c (is_float128): New predicate extracted from...
4375         (dump_ada_node) <COMPLEX_TYPE>: Use it to recognize __cfloat128.
4376         <REAL_TYPE>: ...here.  Call it.
4378 2019-04-05  David Malcolm  <dmalcolm@redhat.com>
4380         PR c/89985
4381         * c-warn.c (check_address_or_pointer_of_packed_member): Add
4382         auto_diagnostic_group.  Guard inform calls by result of
4383         warning_at call.
4385 2019-04-05  Marek Polacek  <polacek@redhat.com>
4387         PR c++/89973 - -Waddress-of-packed-member ICE with invalid conversion.
4388         * c-warn.c (check_address_or_pointer_of_packed_member): Check the type
4389         of RHS.
4391 2019-04-03  Jason Merrill  <jason@redhat.com>
4393         PR c++/86586 - -fcompare-debug=-Wsign-compare.
4394         * c-warn.c (warn_for_sign_compare): Call fold_for_warn.
4396 2019-04-01  Martin Sebor  <msebor@redhat.com>
4398         PR c/89685
4399         * c-attribs.c (handle_copy_attribute): Handle references and
4400         non-constant expressions.
4402 2019-03-22  Jakub Jelinek  <jakub@redhat.com>
4404         PR c++/87481
4405         * c.opt (-fconstexpr-ops-limit=): New option.
4407 2019-03-21  Jakub Jelinek  <jakub@redhat.com>
4409         * c-common.c (per_file_includes_t): Use false as Lazy in hash_set
4410         template param.
4412 2019-03-19  Martin Sebor  <msebor@redhat.com>
4414         PR tree-optimization/89688
4415         * c-common.c (braced_list_to_string): Make static.
4416         (braced_lists_to_strings): Define new function.
4417         * c-common.h (braced_list_to_string): Remove.
4418         (braced_lists_to_strings): Declare.
4420 2019-03-12  Martin Liska  <mliska@suse.cz>
4422         * c-opts.c (c_common_handle_option): Wrap option with %< and %>.
4424 2019-03-11  Martin Liska  <mliska@suse.cz>
4426         * c-opts.c (c_common_post_options): Wrap apostrophes
4427         in gcc internal format with %'.
4429 2019-03-11  Martin Liska  <mliska@suse.cz>
4431         * c-attribs.c (handle_nocf_check_attribute): Wrap an option name
4432         in a string format message and fix GNU coding style.
4433         * c-common.c (vector_types_convertible_p): Likewise.
4434         (c_build_vec_perm_expr): Likewise.
4435         * c-indentation.c (get_visual_column): Likewise.
4436         * c-opts.c (c_common_handle_option): Likewise.
4437         (c_common_post_options): Likewise.
4438         (sanitize_cpp_opts): Likewise.
4439         * c-pch.c (c_common_pch_pragma): Likewise.
4440         * c-pragma.c (handle_pragma_pack): Likewise.
4442 2019-03-08  Jakub Jelinek  <jakub@redhat.com>
4444         PR tree-optimization/89550
4445         * c-common.c (c_common_truthvalue_conversion): Only set
4446         TREE_NO_WARNING if warning_at returned true.
4447         * c-warn.c (overflow_warning, warn_logical_operator): Likewise.
4449 2019-02-25  Sandra Loosemore  <sandra@codesourcery.com>
4450             Martin Sebor  <msebor@gmail.com>
4452         * c.opt (Wmissing-attributes): Clean up doc string.
4454 2019-02-25  Jakub Jelinek  <jakub@redhat.com>
4456         PR c/89495
4457         * c-format.c (maybe_read_dollar_number): Compute nargnum in
4458         HOST_WIDE_INT type to avoid overflows and change overflow_flag
4459         checking.
4461 2019-02-22  Richard Biener  <rguenther@suse.de>
4463         * c-pch.c (no_checksum): Remove.
4464         (pch_init): Remove assertion that executable_checksum is not
4465         all zero.
4466         (c_common_valid_pch): Likewise.
4468 2019-02-18  Martin Sebor  <msebor@redhat.com>
4470         PR middle-end/89294
4471         * c-common.c (invalid_array_size_error): Handle cst_size_not_constant.
4473 2019-02-16  David Malcolm  <dmalcolm@redhat.com>
4475         PR c++/88680
4476         * c-common.c (shorten_compare): Call fold_for_warn on op0 when
4477         implementing -Wtype-limits.
4479 2019-02-11  Martin Sebor  <msebor@redhat.com>
4481         PR c++/87996
4482         * c-common.c (invalid_array_size_error): New function.
4483         (valid_array_size_p): Call it.  Handle size as well as type.
4484         * c-common.h (valid_constant_size_p): New function.
4485         (enum cst_size_error): New type.
4487 2019-01-31  David Malcolm  <dmalcolm@redhat.com>
4489         PR c/89122
4490         * known-headers.cc (get_stdlib_header_for_name): Add
4491         {FLT|DBL|LDBL}_{MAX|MIN} to "hints" array.
4493 2019-01-31  Jakub Jelinek  <jakub@redhat.com>
4495         PR libstdc++/88170
4496         * c-pretty-print.c (pp_c_enumeration_constant): Print always as
4497         a C cast in pp_c_flag_gnu_v3 mode.
4499 2019-01-29  Jakub Jelinek  <jakub@redhat.com>
4501         PR c/86125
4502         * c-common.c (c_common_nodes_and_builtins): Build type variants for
4503         builtin_structptr_types types even for C.
4505 2019-01-28  Bernd Edlinger  <bernd.edlinger@hotmail.de>
4507         * c-warn.c (check_address_or_pointer_of_packed_member): Handle the case
4508         when rhs is of array type correctly.  Fix handling of nested structures.
4509         Fix handling of indirect_ref together with nop_expr and/or addr_expr.
4510         (check_and_warn_address_or_pointer_of_packed_member): Fix handling of
4511         type casts within nested compound expressions.
4513 2019-01-22  Jakub Jelinek  <jakub@redhat.com>
4515         PR middle-end/88968
4516         * c-omp.c (c_finish_omp_atomic): For bitfield atomics, update type
4517         variable after using BIT_FIELD_REF.
4519 2019-01-18  H.J. Lu  <hongjiu.lu@intel.com>
4521         PR c/51628
4522         PR c/88664
4523         * c-common.h (warn_for_address_or_pointer_of_packed_member):
4524         Remove the boolean argument.
4525         * c-warn.c (check_address_of_packed_member): Renamed to ...
4526         (check_address_or_pointer_of_packed_member): This.  Also
4527         warn pointer conversion.
4528         (check_and_warn_address_of_packed_member): Renamed to ...
4529         (check_and_warn_address_or_pointer_of_packed_member): This.
4530         Also warn pointer conversion.
4531         (warn_for_address_or_pointer_of_packed_member): Remove the
4532         boolean argument.  Don't check pointer conversion here.
4534 2019-01-15  Richard Sandiford  <richard.sandiford@arm.com>
4536         PR inline-asm/52813
4537         * c.opt (Wdeprecated): Move documentation and variable to common.opt.
4539 2019-01-14  Jakub Jelinek  <jakub@redhat.com>
4541         * c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
4542         and __cpp_nontype_template_parameter_auto.  Add a comment that
4543         __cpp_template_auto is deprecated.
4545 2019-01-14  Tom Honermann  <tom@honermann.net>
4547         Implement P0482R5, char8_t: A type for UTF-8 characters and strings
4548         * c-common.c (c_common_reswords): Add char8_t.
4549         (fix_string_type): Use char8_t for the type of u8 string literals.
4550         (c_common_get_alias_set): char8_t doesn't alias.
4551         (c_common_nodes_and_builtins): Define char8_t as a builtin type in
4552         C++.
4553         (c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
4554         (keyword_begins_type_specifier): Add RID_CHAR8.
4555         * c-common.h (rid): Add RID_CHAR8.
4556         (c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
4557         Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
4558         Define char8_type_node and char8_array_type_node.
4559         * c-cppbuiltin.c (cpp_atomic_builtins): Predefine
4560         __GCC_ATOMIC_CHAR8_T_LOCK_FREE.
4561         (c_cpp_builtins): Predefine __cpp_char8_t.
4562         * c-lex.c (lex_string): Use char8_array_type_node as the type of
4563         CPP_UTF8STRING.
4564         (lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
4565         * c-opts.c: If not otherwise specified, enable -fchar8_t when
4566         targeting C++2a.
4567         * c.opt: Add the -fchar8_t command line option.
4569 2019-01-14  Martin Sebor  <msebor@redhat.com>
4571         PR target/88638
4572         * c-attribs.c (positional_argument): Call valid_format_string_type_p
4573         and issue errors if it fails.
4574         * c-common.h (valid_format_string_type_p): Declare.
4575         * c-format.c (valid_stringptr_type_p): Rename...
4576         (valid_format_string_type_p): ...to this and make extern.
4577         (handle_format_arg_attribute): Adjust to new name.
4578         (check_format_string): Same.
4580 2019-01-13  H.J. Lu  <hongjiu.lu@intel.com>
4582         * c-warn.c (warn_for_address_or_pointer_of_packed_member):
4583         Replace "may may" with "may" in warning message.
4585 2019-01-07  Jakub Jelinek  <jakub@redhat.com>
4587         PR c++/85052
4588         * c-common.h (enum rid): Add RID_BUILTIN_CONVERTVECTOR.
4589         (c_build_vec_convert): Declare.
4590         * c-common.c (c_build_vec_convert): New function.
4592 2019-01-04  Martin Sebor  <msebor@redhat.com>
4594         PR c/88546
4595         * c-attribs.c (handle_copy_attribute): Avoid copying attribute leaf.
4596         Handle C++ empty throw specification and C11 _Noreturn.
4597         (has_attribute): Also handle C11 _Noreturn.
4599 2019-01-04  Martin Sebor  <msebor@redhat.com>
4601         PR c/88363
4602         * c-attribs.c (positional_argument): Also accept enumerated types.
4604 2019-01-01  Jakub Jelinek  <jakub@redhat.com>
4606         Update copyright years.
4608 2018-12-20  H.J. Lu  <hongjiu.lu@intel.com>
4610         PR c/51628
4611         * c-common.h (warn_for_address_or_pointer_of_packed_member): New.
4612         * c-warn.c (check_alignment_of_packed_member): New function.
4613         (check_address_of_packed_member): Likewise.
4614         (check_and_warn_address_of_packed_member): Likewise.
4615         (warn_for_address_or_pointer_of_packed_member): Likewise.
4616         * c.opt: Add -Wno-address-of-packed-member.
4618 2018-12-20  David Malcolm  <dmalcolm@redhat.com>
4620         PR c++/87504
4621         * c-warn.c (get_outermost_macro_expansion): New function.
4622         (spelled_the_same_p): Use it to unwind the macro expansions, and
4623         compare the outermost macro in each nested expansion, rather than
4624         the innermost.
4626 2018-12-19  David Malcolm  <dmalcolm@redhat.com>
4628         PR c++/87504
4629         * c-common.h (warn_tautological_cmp): Convert 1st param from
4630         location_t to const op_location_t &.
4631         * c-warn.c (find_array_ref_with_const_idx_r): Call fold_for_warn
4632         when testing for INTEGER_CST.
4633         (warn_tautological_bitwise_comparison): Convert 1st param from
4634         location_t to const op_location_t &; use it to build a
4635         binary_op_rich_location, and use this.
4636         (spelled_the_same_p): New function.
4637         (warn_tautological_cmp): Convert 1st param from location_t to
4638         const op_location_t &.  Warn for macro expansions if
4639         spelled_the_same_p.  Use binary_op_rich_location.
4641 2018-12-19  David Malcolm  <dmalcolm@redhat.com>
4643         PR c++/43064
4644         PR c++/43486
4645         * c-common.c (unsafe_conversion_p): Fold any location wrapper.
4646         (verify_tree): Handle location wrappers.
4647         (c_common_truthvalue_conversion): Strip any location wrapper.
4648         Handle CONST_DECL.
4649         (fold_offsetof): Strip any location wrapper.
4650         (complete_array_type): Likewise for initial_value.
4651         (convert_vector_to_array_for_subscript): Call fold_for_warn on the
4652         index before checking for INTEGER_CST.
4653         * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
4654         print parentheses around location wrappers.
4655         * c-warn.c (warn_logical_operator): Call fold_for_warn on op_right
4656         before checking for INTEGER_CST.
4657         (warn_tautological_bitwise_comparison): Call
4658         tree_strip_any_location_wrapper on lhs, rhs, and bitop's operand
4659         before checking for INTEGER_CST.
4660         (readonly_error): Strip any location wrapper.
4661         (warn_array_subscript_with_type_char): Strip location wrappers
4662         before checking for INTEGER_CST.  Use the location of the index if
4663         available.
4665 2018-12-06  Jason Merrill  <jason@redhat.com>
4667         PR c++/88136 - -Wdeprecated-copy false positives
4668         * c.opt (Wdeprecated-copy-dtor): New.
4669         (Wdeprecated-copy): Move to -Wextra.
4671 2018-11-29  Martin Sebor  <msebor@redhat.com>
4673         PR c/88172
4674         PR testsuite/88208
4675         * c-attribs.c (common_handle_aligned_attribute): Silently avoid setting
4676         alignments to values less than the target requires.
4677         (has_attribute): For attribute aligned consider both the attribute
4678         and the alignment bits.
4679         * c-common.c (c_init_attributes): Optionally issue a warning for
4680         zero alignment.
4682 2018-11-28  Martin Sebor  <msebor@redhat.com>
4684         PR c/88065
4685         PR c/87297
4686         * c-warn.c (sizeof_pointer_memaccess_warning): Bail if source
4687         or destination is an error.
4689 2018-11-28  Jakub Jelinek  <jakub@redhat.com>
4691         PR c++/88215
4692         * c-ubsan.c: Include langhooks.h.
4693         (ubsan_instrument_division): Change gcc_assert that main variants
4694         of op0 and op1 types are equal to gcc_checking_assert that the
4695         main variants are compatible types.
4697 2018-11-27  Eric Botcazou  <ebotcazou@adacore.com>
4699         * c-ada-spec.c: Include stringpool.h.
4700         (has_static_fields): Return false for incomplete types.
4701         (is_tagged_type): Likewise.
4702         (has_nontrivial_methods): Likewise.
4703         (dump_ada_node) <INTEGER_TYPE>: Deal specifically with __int128.
4704         (struct overloaded_name_hash): New structure.
4705         (struct overloaded_name_hasher): Likewise.
4706         (overloaded_names): New global variable.
4707         (init_overloaded_names): New static function.
4708         (overloaded_name_p): New predicate.
4709         (dump_ada_declaration) <TYPE_DECL>: Tidy up and set TREE_VISITED
4710         on the TYPE_STUB_DECL of the original type of a typedef, if any.
4711         <FUNCTION_DECL>: Bail out for an unsupported overloaded name.
4712         Remove always-true condition and dump forward types.
4713         (dump_ada_specs): Delete overloaded_names.
4715 2018-11-20  Martin Sebor  <msebor@redhat.com>
4717         * c-attribs.c (type_for_vector_size): New function.
4718         (type_valid_for_vector_size): Same.
4719         (handle_vector_size_attribute): Move code to the functions above
4720         and call them.
4721         (validate_attribute, has_attribute): New functions.
4722         * c-common.h (has_attribute): Declare.
4723         (rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
4724         * c-common.c (c_common_resword): Same.
4726 2018-11-16  Jason Merrill  <jason@redhat.com>
4728         * c-lex.c (c_common_has_attribute): Handle likely/unlikely.
4729         * c-attribs.c (attr_cold_hot_exclusions): Make public.
4731 2018-11-16  Jakub Jelinek  <jakub@redhat.com>
4733         PR middle-end/87854
4734         * c-common.c (fix_string_type): Reject string literals larger than
4735         TYPE_MAX_VALUE (ssizetype) bytes.
4737 2018-11-15  Martin Sebor  <msebor@redhat.com>
4739         PR c++/87541
4740         PR c++/87542
4741         * c-attribs.c (positional_argument): New function.
4742         (handle_alloc_size_attribute): Use it and simplify.
4743         (handle_alloc_align_attribute): Same.
4744         (handle_assume_aligned_attribute): Same.
4745         (handle_nonnull_attribute): Same.
4746         * c-common.c (check_function_arguments): Pass fntype to
4747         check_function_format.
4748         * c-common.h (check_function_format): Add an argument.
4749         (PosArgFlags, positional_argument): Declare new type and function.
4750         * c-format.c (decode_format_attr): Add arguments.
4751         (check_format_string, get_constant): Same.
4752         (convert_format_name_to_system_name): Adjust.
4754 2018-11-15  David Malcolm  <dmalcolm@redhat.com>
4756         PR other/19165
4757         * c-opts.c (c_diagnostic_finalizer): Add diagnostic_t param.
4759 2018-11-14  Jakub Jelinek  <jakub@redhat.com>
4761         P1236R1 - Signed integers are two's complement
4762         * c-warn.c (maybe_warn_shift_overflow): Don't warn for c++2a.
4763         * c-ubsan.c (ubsan_instrument_shift): Make signed shifts
4764         with in-range second operand well defined for -std=c++2a.
4766         PR other/88007
4767         * c-common.c (parse_optimize_options): Allocate option string from
4768         opts_obstack rather than as GC memory.  Move the allocation after
4769         warning for invalid option.
4771 2018-11-13  David Malcolm  <dmalcolm@redhat.com>
4773         * c-common.c (c_get_substring_location): Update for renaming of
4774         get_source_location_for_substring to get_location_within_string.
4775         * c-lex.c: Replace "source_location" with "location_t".
4776         * c-opts.c: Likewise.
4777         * c-ppoutput.c: Likewise.
4779 2018-11-13  Martin Sebor  <msebor@redhat.com>
4781         PR middle-end/81824
4782         * c-attribs.c (handle_copy_attribute): Exclude inlining attributes.
4783         (handle_tls_model_attribute): Improve diagnostics.
4785 2018-11-12  Jason Merrill  <jason@redhat.com>
4787         * c-cppbuiltin.c (c_cpp_builtins): Define
4788         __cpp_impl_destroying_delete.
4790         * c-cppbuiltin.c (c_cpp_builtins): Change __cpp_explicit_bool to
4791         __cpp_conditional_explicit.
4793 2018-11-09  Martin Sebor  <msebor@redhat.com>
4795         PR middle-end/81824
4796         * c-attribs.c (handle_copy_attribute): New function.
4798 2018-11-09  Martin Sebor  <msebor@redhat.com>
4800         PR c/87795
4801         * c-common.c (check_user_alignment): Use MAX_OFILE_ALIGNMENT.
4803 2018-11-08  Jakub Jelinek  <jakub@redhat.com>
4805         * c-common.h (c_finish_omp_taskgroup): Add CLAUSES argument.
4806         (c_finish_omp_atomic): Replace bool SEQ_CST argument with
4807         enum omp_memory_order MEMORY_ORDER.
4808         (c_finish_omp_flush): Add MO argument.
4809         (c_omp_depend_t_p, c_finish_omp_depobj): Declare.
4810         (c_finish_omp_for): Add FINAL_P argument.
4811         * c-omp.c: Include memmodel.h.
4812         (c_finish_omp_taskgroup): Add CLAUSES argument.  Set
4813         OMP_TASKGROUP_CLAUSES to it.
4814         (c_finish_omp_atomic): Replace bool SEQ_CST argument with
4815         enum omp_memory_order MEMORY_ORDER.  Set OMP_ATOMIC_MEMORY_ORDER
4816         instead of OMP_ATOMIC_SEQ_CST.
4817         (c_omp_depend_t_p, c_finish_omp_depobj): New functions.
4818         (c_finish_omp_flush): Add MO argument, if not MEMMODEL_LAST, emit
4819         __atomic_thread_fence call with the given value.
4820         (check_omp_for_incr_expr): Formatting fixes.
4821         (c_finish_omp_for): Add FINAL_P argument.  Allow NE_EXPR
4822         even in OpenMP loops, diagnose if NE_EXPR and incr expression
4823         is not constant expression 1 or -1.  Transform NE_EXPR loops
4824         with iterators pointers to VLA into LT_EXPR or GT_EXPR loops.
4825         (c_omp_check_loop_iv_r): Look for orig decl of C++ range for
4826         loops too.
4827         (c_omp_split_clauses): Add support for combined
4828         #pragma omp parallel master and
4829         #pragma omp {,parallel }master taskloop{, simd} constructs.
4830         Handle OMP_CLAUSE_IN_REDUCTION.  Handle OMP_CLAUSE_REDUCTION_TASK.
4831         Handle OMP_CLAUSE_NONTEMPORAL.  Handle splitting OMP_CLAUSE_IF
4832         also to OMP_SIMD.  Copy OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
4833         (c_omp_predetermined_sharing): Don't return
4834         OMP_CLAUSE_DEFAULT_SHARED for const qualified decls.
4835         * c-pragma.c (omp_pragmas): Add PRAGMA_OMP_DEPOBJ and
4836         PRAGMA_OMP_REQUIRES.
4837         * c-pragma.h (enum pragma_kind): Likewise.
4838         (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_NONTEMPORAL
4839         and PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
4841 2018-11-08  David Malcolm  <dmalcolm@redhat.com>
4843         * c-format.c (gcc_dump_printf_char_table): Add entry for %f.
4845 2018-11-08  David Malcolm  <dmalcolm@redhat.com>
4847         * c-format.c (local_cgraph_node_ptr_node): New variable.
4848         (gcc_dump_printf_char_table): Add entry for %C.
4849         (get_pointer_to_named_type): New function, taken from the handling
4850         code for "gimple *" from...
4851         (init_dynamic_diag_info): ...here.  Add handling for
4852         "cgraph_node *".
4853         * c-format.h (T_CGRAPH_NODE): New.
4855 2018-10-19  Jason Merrill  <jason@redhat.com>
4857         * c-cppbuiltin.c (c_cpp_builtins): Add
4858         __cpp_nontype_template_parameter_class.
4860 2018-10-31  Nathan Sidwell  <nathan@acm.org>
4862         * c-opts.c (c_finish_options): Force command line macro
4863         location.  Refactor to avoid repeating main debug hook.
4864         (push_command_line_include): Clarify comment.
4866         * c-opts.c (c_finish_options): Adjust cpp_force_token_locations call.
4868 2018-10-30  Martin Sebor  <msebor@redhat.com>
4870         PR middle-end/87041
4871         * c-format.c (check_format_types): Avoid diagnosing null pointer
4872         arguments to printf-family of functions.
4874 2018-10-30  Marek Polacek  <polacek@redhat.com>
4876         Implement P0892R2, explicit(bool).
4877         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
4879 2018-10-29  David Malcolm  <dmalcolm@redhat.com>
4881         * name-hint.h (name_hint::take_deferred): New member function.
4883 2018-10-29  David Malcolm  <dmalcolm@redhat.com>
4885         PR c++/56856
4886         * c-common.c (check_function_sentinel): Call fold_for_warn on the
4887         argument.
4888         (check_function_restrict): Rename param "argarray" to
4889         "unfolded_argarray", and make a copy named "argarray", calling
4890         fold_for_warn on each argument.
4891         (check_function_arguments): Add note about responsibility for
4892         folding the arguments.
4894 2018-10-17  Joseph Myers  <joseph@codesourcery.com>
4896         * c-common.c (flag_isoc2x): New variable.
4897         * c-common.h (clk_c): Update comment to reference C2X.
4898         (flag_isoc99, flag_isoc11): Update comments to reference future
4899         standard versions in general.
4900         (flag_isoc2x): Declare.
4901         * c-opts.c (set_std_c2x): New function.
4902         (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
4903         (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
4904         flag_isoc2x to 0.
4905         * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
4907 2018-10-17  Joseph Myers  <joseph@codesourcery.com>
4909         * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
4910         (std=iso9899:2018): Document C17 as published in 2018.
4912 2018-10-12  Christophe Lyon  <christophe.lyon@linaro.org>
4914         PR c++/87364
4915         * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
4917 2018-10-11  Will Wray  <wjwray@gmail.com>
4919         PR c++/87364
4920         * c-pretty-print.h (pp_c_type_cast): Prototype.
4921         (pp_c_integer_constant): Likewise.
4922         * c-pretty-print.c (pp_c_type_cast): No longer static.
4923         (pp_c_integer_constant): Likewise.
4924         (pp_c_enumeration_constant): Fix loop termination when finding
4925         name of constant.  No longer returns a value.  Call
4926         pp_c_integer_constant.
4927         (c_pretty_printer::constant): Update for changes to
4928         pp_c_enumeration_constant.
4930 2018-10-11  Jakub Jelinek  <jakub@redhat.com>
4932         * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
4933         for no_unique_address.
4935 2018-10-09  David Malcolm  <dmalcolm@redhat.com>
4937         * c-common.c (c_option_controlling_cpp_error): Rename to...
4938         (c_option_controlling_cpp_diagnostic): ...this, and convert
4939         "reason" from int to enum.
4940         (c_cpp_error): Rename to...
4941         (c_cpp_diagnostic): ...this, converting level and reason to enums.
4942         * c-common.h (c_cpp_error): Rename to...
4943         (c_cpp_diagnostic): ...this, converting level and reason to enums.
4944         * c-opts.c (c_common_init_options): Update for renaming.
4946 2018-10-08  Richard Sandiford  <richard.sandiford@arm.com>
4948         PR c/87286
4949         * c-common.c (vector_types_compatible_elements_p): Use
4950         INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
4952 2018-10-04  Vinay Kumar  <vinay.kumar@blackfigtech.com>
4954         * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
4955         to generate constructor destructor priority warning.
4956         * c.opt (-Wprio-ctor-dtor): New option.
4958 2018-10-01  Jason Merrill  <jason@redhat.com>
4960         * c-lex.c (c_common_has_attribute): Add no_unique_address.
4962 2018-10-01  Eric Botcazou  <ebotcazou@adacore.com>
4964         * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
4965         (dump_ada_node): Add const keyword.
4967 2018-09-25  Martin Liska  <mliska@suse.cz>
4969         * c-common.c (c_common_truthvalue_conversion):
4970         Remove Pascal from documentation.
4972 2018-09-21  Eric Botcazou  <ebotcazou@adacore.com>
4974         * c-ada-spec.c: Include diagnostic.h.
4975         (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
4977 2018-09-19  Marek Polacek  <polacek@redhat.com>
4979         * c.opt (Wclass-conversion): New.
4981 2018-09-17  David Malcolm  <dmalcolm@redhat.com>
4983         * c-format.c (range_label_for_format_type_mismatch::get_text):
4984         Update for new param.
4986 2018-09-17  David Malcolm  <dmalcolm@redhat.com>
4988         * c-format.c (format_warning_at_char): Update for introduction of
4989         format_string_diagnostic_t.
4990         (format_type_warning): Likewise.
4992 2018-09-17  Martin Jambor  <mjambor@suse.cz>
4994         PR c/63886
4995         * c.opt (Wabsolute-value): New.
4997 2018-09-06  Bernd Edlinger  <bernd.edlinger@hotmail.de>
4999         * c-common.c (complete_flexible_array_elts): New helper function.
5000         * c-common.h (complete_flexible_array_elts): Declare.
5002 2018-09-02  Bernd Edlinger  <bernd.edlinger@hotmail.de>
5004         * c-common.c (braced_list_to_string): Remove eval parameter.
5005         Add some more checks.  Always create zero-terminated STRING_CST.
5006         * c-common.h (braced_list_to_string): Adjust prototype.
5008 2018-08-27  David Malcolm  <dmalcolm@redhat.com>
5010         PR 87091
5011         * c-common.c (c_cpp_error): Update for conversion of show_caret_p
5012         to a tri-state.
5013         (maybe_suggest_missing_token_insertion): Likewise.
5014         (maybe_add_include_fixit): Add param "override_location".  If set,
5015         and source-printing is enabled, then override the rich_location's
5016         primary location with that of the insertion point for the fix-it
5017         hint, marking it with SHOW_LINES_WITHOUT_RANGE.
5018         * c-common.h (extern void maybe_add_include_fixit): Add bool
5019         param.
5020         * c-format.c (selftest::test_type_mismatch_range_labels): Update
5021         for conversion of show_caret_p to a tri-state.
5022         * c-warn.c (warn_for_restrict): Likewise.
5023         * known-headers.cc
5024         (suggest_missing_header::~suggest_missing_header): Update call to
5025         maybe_add_include_fixit to suggest overriding the location, as it
5026         is for a note.
5028 2018-08-27  Martin Liska  <mliska@suse.cz>
5030         * c-common.c (check_function_restrict): Use new function
5031         fndecl_built_in_p and remove check for FUNCTION_DECL if
5032         possible.
5033         (check_builtin_function_arguments): Likewise.
5034         (reject_gcc_builtin): Likewise.
5035         * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
5037 2018-08-26  Marek Polacek  <polacek@redhat.com>
5039         PR c++/87029, Implement -Wredundant-move.
5040         * c.opt (Wredundant-move): New option.
5042 2018-08-21  Marek Polacek  <polacek@redhat.com>
5044         PR c++/86981, Implement -Wpessimizing-move.
5045         * c.opt (Wpessimizing-move): New option.
5047 2018-08-20  David Malcolm  <dmalcolm@redhat.com>
5049         PR other/84889
5050         * c-attribs.c (common_handle_aligned_attribute): Add
5051         auto_diagnostic_group instance.
5052         * c-indentation.c (warn_for_misleading_indentation): Likewise.
5053         * c-opts.c (c_common_post_options): Likewise.
5054         * c-warn.c (warn_logical_not_parentheses): Likewise.
5055         (warn_duplicated_cond_add_or_warn): Likewise.
5056         (warn_for_multistatement_macros): Likewise.
5058 2018-08-20  Nathan Sidwell  <nathan@acm.org>
5060         * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
5061         access.
5063 2018-08-17  Nathan Sidwell  <nathan@acm.org>
5065         * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
5066         field.
5067         (laxy_hex_fp_value_count): Make unsigned.
5068         (lazy_hex_fp_value): Provided with macro & lazy number.  Directly
5069         manipulate the macro.
5070         (builtin_defin_with_hex_fp_value): Adjust callback name, use
5071         cpp_define_lazily.
5073 2018-08-17  David Malcolm  <dmalcolm@redhat.com>
5075         * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
5076         (gcc_dump_printf_length_specs): New.
5077         (gcc_dump_printf_flag_pairs): New.
5078         (gcc_dump_printf_flag_specs): New.
5079         (gcc_dump_printf_char_table): New.
5080         (format_types_orig): Add entry for "gcc_dump_printf".
5081         (init_dynamic_diag_info): Set up length_char_specs and
5082         conversion_specs for gcc_dump_printf_format_type.
5083         (handle_format_attribute): Handle gcc_dump_printf_format_type.
5085 2018-08-17  Nathan Sidwell  <nathan@acm.org>
5087         * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
5089         * c-ada-spec.c: Don't #include "cpp-id-data.h"
5090         * c-cppbuiltin.c: Likewise.
5092 2018-08-17  Martin Liska  <mliska@suse.cz>
5094         * c.opt: Remove Warn, Init and Report for options with
5095         Ignore/Deprecated flag. Warning is done automatically for
5096         Deprecated flags.
5098 2018-08-16  David Malcolm  <dmalcolm@redhat.com>
5100         PR c++/70693
5101         * c-common.c (selftest::c_family_tests): Call
5102         selftest::c_indentation_c_tests.
5103         * c-common.h (selftest::c_indentation_c_tests): New decl.
5104         * c-indentation.c: Include "selftest.h".
5105         (next_tab_stop): Add "tab_width" param, rather than accessing
5106         cpp_opts.
5107         (get_visual_column): Likewise.  Clarify comment.  Bulletproof
5108         against reading past the end of the line.
5109         (get_first_nws_vis_column): Add "tab_width" param.
5110         (detect_intervening_unindent): Likewise.
5111         (should_warn_for_misleading_indentation): Read tab width from
5112         cpp_opts and pass around.
5113         (selftest::test_next_tab_stop): New test.
5114         (selftest::assert_get_visual_column_succeeds): New function.
5115         (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
5116         (selftest::assert_get_visual_column_fails): New function.
5117         (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
5118         (selftest::test_get_visual_column): New test.
5119         (selftest::c_indentation_c_tests): New function.
5121 2018-08-16  Nathan Sidwell  <nathan@acm.org>
5123         * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
5124         (store_ada_macro): Likewise.
5125         * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
5126         * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
5128 2018-08-15  David Malcolm  <dmalcolm@redhat.com>
5130         * c-format.c: Include "selftest-diagnostic.h" and
5131         "gcc-rich-location.h".
5132         (format_warning_at_char): Pass NULL for new label params of
5133         format_warning_va.
5134         (class indirection_suffix): New class.
5135         (class range_label_for_format_type_mismatch): New class.
5136         (format_type_warning): Move logic for generating "*" suffix to
5137         class indirection_suffix.  Create "fmt_label" and "param_label"
5138         to show their types, and pass them to the
5139         format_warning_at_substring calls.
5140         (selftest::test_type_mismatch_range_labels): New test.
5141         (selftest::c_format_c_tests): Call it.
5143 2018-08-13  Martin Sebor  <msebor@redhat.com>
5145         PR tree-optimization/71625
5146         * c-common.c (braced_list_to_string): New function.
5147         * c-common.h (braced_list_to_string): Declare it.
5149 2018-08-08  Nathan Sidwell  <nathan@acm.org>
5151         * c-common.c (try_to_locate_new_include_inertion_point): Use
5152         linemap_included_from_linemap.
5153         * c-lex.c (fe_file_change): Use linemap_included_from.
5154         * c-ppoutput.c (pp_file_change): Likewise.
5156 2018-08-01  Martin Sebor  <msebor@redhat.com>
5158         PR tree-optimization/86650
5159         * c-format.c (gcc_tdiag_char_table): Update comment for "%G".
5160         (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
5161         (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
5162         * c-format.h (T89_G): Update to be "gimple *" rather than
5163         "gcall *".
5164         (local_gcall_ptr_node): Rename...
5165         (local_gimple_ptr_node): ...to this.
5167 2018-07-31  David Malcolm  <dmalcolm@redhat.com>
5169         * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
5170         table entries for gcc_diag_char_table, and the 'Z' entry from
5171         gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
5172         &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
5173         (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
5174         adding missing "Z" for this table.  Remove erroneous "G" and "K"
5175         entries.
5176         (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE.  Remove "v".
5177         (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
5178         (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE.  Remove "v".
5180 2018-07-31  Richard Earnshaw  <rearnsha@arm.com>
5182         * c-common.c (speculation_safe_resolve_call): New function.
5183         (speculation_safe_resolve_params): New function.
5184         (speculation_safe_resolve_return): New function.
5185         (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
5186         * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
5187         __HAVE_SPECULATION_SAFE_VALUE.
5189 2018-07-20  David Malcolm  <dmalcolm@redhat.com>
5191         * c-common.c (c_cpp_error): Remove redundant "line_table"
5192         parameter from call to rich_location::set_range.
5193         (maybe_suggest_missing_token_insertion): Likewise.
5195 2018-07-20  Martin Sebor  <msebor@redhat.com>
5197         PR middle-end/82063
5198         * c.opt (-Warray-bounds): Remove redundant -Wall.
5200 2018-07-20  Martin Sebor  <msebor@redhat.com>
5202         PR middle-end/82063
5203         * c-common.h (c_common_handle_option): Change function argument
5204         to HOST_WIDE_INT.
5205         * c-opts.c (c_common_init_options): Same.
5206         (c_common_handle_option): Same.  Remove special handling of
5207         OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
5208         * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
5209         options to take a HOST_WIDE_INT argument and accept a byte-size
5210         suffix.  Initialize.
5211         (-Wvla-larger-than): Same.
5212         (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
5213         (-Wno-vla-larger-than): Same.
5215 2018-07-12  Jakub Jelinek  <jakub@redhat.com>
5217         * c-attribs.c (c_common_attribute_table): Add
5218         "omp declare target implicit" attribute.
5220 2018-07-12  Richard Biener  <rguenther@suse.de>
5222         PR c/86453
5223         * c-attribs.c (handle_packed_attribute): Do not build a variant
5224         type with TYPE_PACKED, instead ignore the attribute if we may
5225         not apply to the original type.
5227 2018-07-10  Jakub Jelinek  <jakub@redhat.com>
5229         PR c++/86443
5230         * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
5231         to contain TREE_LIST for both the original class iterator and the
5232         "last" helper var.
5234 2018-07-07  Eric Botcazou  <ebotcazou@adacore.com>
5236         * c-ada-spec.c (to_ada_name): Remove index parameter.
5237         (pp_ada_tree_identifier): Likewise.
5238         (dump_ada_macros): Adjust call to to_ada_name.
5239         (struct overloaded_name_hash): Delete.
5240         (struct overloaded_name_hasher): Likewise.
5241         (overloaded_names): Likewise.
5242         (compute_overloading_index): Likewise.
5243         (dump_ada_decl_name): Do not call compute_overloading_index and
5244         adjust calls to pp_ada_tree_identifier.
5245         (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
5246         (dump_ada_import): Add spc parameter and switch to aspect syntax.
5247         (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
5248         (dump_ada_enum_type): Remove type and display_convention parameters.
5249         Adjust calls to pp_ada_tree_identifier.
5250         (dump_ada_node): Likewise and for dump_ada_structure.
5251         (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
5252         and tidy up.
5253         <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
5254         syntax.
5255         (print_constructor): Adjust call to pp_ada_tree_identifier.
5256         (print_destructor): Likewise.
5257         (dump_ada_declaration): Switch to aspect syntax.
5258         (dump_ada_structure): Likewise and tidy up.  Replace display_convention
5259         parameter with nested parameter.
5260         (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
5261         (dump_ada_specs): Do not delete overloaded_names table.
5263 2018-07-06  Peter Bergner  <bergner@linux.ibm.com>
5265         PR target/86324
5266         * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
5267         target hook.
5269 2018-07-05  Nathan Sidwell  <nathan@acm.org>
5271         * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
5272         NO_IMPLICIT_EXTERN_C.
5274 2018-06-28  Martin Liska  <mliska@suse.cz>
5276         * cppspec.c: Include opt-suggestions.h.
5278 2018-06-20  Chung-Lin Tang  <cltang@codesourcery.com>
5279             Thomas Schwinge  <thomas@codesourcery.com>
5280             Cesar Philippidis  <cesar@codesourcery.com>
5282         * c-pragma.h (enum pragma_omp_clause): Add
5283         PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
5284         PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
5286 2018-06-20  Jakub Jelinek  <jakub@redhat.com>
5288         PR c++/86210
5289         * c-common.c (check_nonnull_arg): Use fold_for_warn.  Adjust obsolete
5290         comment.
5292 2018-06-18  Martin Sebor  <msebor@redhat.com>
5294         PR middle-end/85602
5295         * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
5296         nonstring.
5298 2018-06-16  Kugan Vivekanandarajah  <kuganv@linaro.org>
5300         * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
5302 2018-06-13  Jason Merrill  <jason@redhat.com>
5304         * c-opts.c (c_common_post_options): Warn about useless -Wabi.
5305         (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
5306         handling.
5308         PR c++/86094 - wrong code with defaulted move ctor.
5309         * c-opts.c (c_common_post_options): Bump the current ABI version to
5310         13.  Set warn_abi_version and flag_abi_compat_version to the current
5311         version rather than 0.  Fix defaulting flag_abi_compat_version from
5312         warn_abi_version.
5314 2018-06-12  Martin Sebor  <msebor@redhat.com>
5316         PR c/85931
5317         * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
5318         sizeof source and destination yields the same value.
5320 2018-06-12  Martin Liska  <mliska@suse.cz>
5322         * c.opt: Make MPX-related options as Deprecated.
5324 2018-06-08  David Malcolm  <dmalcolm@redhat.com>
5326         * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
5327         rather than 0.
5329 2018-06-08  Martin Liska  <mliska@suse.cz>
5331         * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
5332         for MPX (macros, related functions, fields in cgraph_node, ...).
5333         (handle_bnd_legacy): Likewise.
5334         (handle_bnd_instrument): Likewise.
5335         * c.opt: Likewise.
5337 2018-06-06  Jakub Jelinek  <jakub@redhat.com>
5339         PR c++/86068
5340         * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
5341         __cpp_transactional_memory to 201500 instead of 210500.
5343 2018-06-06  Jason Merrill  <jason@redhat.com>
5345         PR c++/85710 - ICE with -Wmemset-elt-size.
5346         * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
5348 2018-06-01  Jason Merrill  <jason@redhat.com>
5350         * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
5351         201703.
5353 2018-06-01  Eric Botcazou  <ebotcazou@adacore.com>
5355         * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
5356         declaration for a typedef independently of whether the declaration of
5357         the subtype is generated.
5359 2018-05-31  Martin Sebor  <msebor@redhat.com>
5361         PR c/82063
5362         * c.opt (-Wno-alloc-size-larger-than): New option.
5364 2018-04-22  David Pagan  <dave.pagan@oracle.com>
5366         PR c/55976
5367         * c-opts.c (c_common_post_options): Set default for warn_return_type
5368         for C++/C++ with ObjC extensions only. For C, makes it possible to
5369         differentiate between default (no option), -Wreturn-type, and
5370         -Wno-return-type.
5372 2018-05-29  Jason Merrill  <jason@redhat.com>
5374         * c.opt (Winit-list-lifetime): New flag.
5376 2018-05-28  Bernd Edlinger  <bernd.edlinger@hotmail.de>
5378         * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
5379         splay_tree_delete_pointers.
5381 2018-05-26  Jakub Jelinek  <jakub@redhat.com>
5383         PR bootstrap/85921
5384         * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
5385         noinline variable to workaround broken kernel headers.
5387 2018-05-18  Jason Merrill  <jason@redhat.com>
5389         * c.opt (Wdeprecated-copy): New flag.
5391 2018-05-17  Martin Liska  <mliska@suse.cz>
5393         * c-warn.c (overflow_warning): Do not use
5394         space in between 'G_' and '('.
5396 2018-05-09  Jason Merrill  <jason@redhat.com>
5398         * c-common.c (valid_array_size_p): Add complain parameter.
5399         * c-common.h: ...which defaults to true.
5401 2018-05-11  Jakub Jelinek  <jakub@redhat.com>
5403         PR c/85696
5404         * c-omp.c (c_omp_predetermined_sharing): Return
5405         OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
5407 2018-05-11  Martin Liska  <mliska@suse.cz>
5409         PR sanitizer/85556
5410         * c-attribs.c (handle_no_sanitize_attribute): Iterate all
5411         TREE_LIST values.
5413 2018-05-10  Jakub Jelinek  <jakub@redhat.com>
5415         PR c++/85662
5416         * c-common.h (fold_offsetof_1): Removed.
5417         (fold_offsetof): Add TYPE argument defaulted to size_type_node and
5418         CTX argument defaulted to ERROR_MARK.
5419         * c-common.c (fold_offsetof_1): Renamed to ...
5420         (fold_offsetof): ... this.  Remove wrapper function.  Add TYPE
5421         argument, convert the pointer constant to TYPE and use size_binop
5422         with PLUS_EXPR instead of fold_build_pointer_plus if type is not
5423         a pointer type.  Adjust recursive calls.
5425 2018-05-10  Eric Botcazou  <ebotcazou@adacore.com>
5427         PR c++/85400
5428         * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
5430 2018-05-07  Nathan Sidwell  <nathan@acm.org>
5432         * c.opt (ffor-scope): Remove functionality, issue warning.
5434 2018-05-03  Nathan Sidwell  <nathan@acm.org>
5436         * c.opt (ffriend-injection): Remove functionality, issue warning.
5438 2018-05-01  David Malcolm  <dmalcolm@redhat.com>
5440         PR c/84258
5441         * c-format.c (struct format_check_results): Add field
5442         "number_non_char".
5443         (check_format_info): Initialize it, and warn if encountered.
5444         (check_format_arg): Distinguish between wide char and
5445         everything else when detecting arrays of non-char.
5447 2018-04-30  David Malcolm  <dmalcolm@redhat.com>
5449         * c-format.c (get_corrected_substring): Update for
5450         location_get_source_line returning a char_span.  Use a char_span
5451         when handling the prefix of the correction.
5452         * c-indentation.c (get_visual_column): Update for
5453         location_get_source_line returning a char_span.
5454         (get_first_nws_vis_column): Likewise.
5456 2018-03-29  David Malcolm  <dmalcolm@redhat.com>
5458         PR c++/84269
5459         * known-headers.cc (get_stdlib_header_for_name): Add various names
5460         from <assert.h>, <string.h>, and <memory.h>; add more names from
5461         <stdio.h>.
5463 2018-03-27  Jakub Jelinek  <jakub@redhat.com>
5465         PR c++/85061
5466         * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
5467         get_base_address of the second operand is a VAR_P, rather than the
5468         operand itself, and use gcc_checking_assert instead of gcc_assert.
5470 2018-03-23  Marek Polacek  <polacek@redhat.com>
5472         PR c++/85045
5473         * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
5474         <case RDIV_EXPR>: Tweak condition.
5476 2018-03-20  Eric Botcazou  <ebotcazou@adacore.com>
5478         * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
5480 2018-03-16  Jakub Jelinek  <jakub@redhat.com>
5482         PR c/84909
5483         * c-warn.c (conversion_warning): Replace "to to" with "to" in
5484         diagnostics.
5486         PR c/84910
5487         * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
5488         diagnostics.
5490 2018-03-16  Richard Biener  <rguenther@suse.de>
5492         PR c/84873
5493         * c-gimplify.c (c_gimplify_expr): Revert previous change.  Instead
5494         unshare the possibly folded expression.
5496 2018-03-15  Richard Biener  <rguenther@suse.de>
5498         PR c/84873
5499         * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
5501 2018-03-13  Martin Sebor  <msebor@redhat.com>
5503         PR tree-optimization/84725
5504         * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
5505         with all three narrow character types, including their qualified forms.
5507 2018-03-12  Martin Sebor  <msebor@redhat.com>
5509         PR tree-optimization/83456
5510         * c-common.c (check_function_restrict): Return bool.
5511         Restore checking of bounded built-in functions.
5512         (check_function_arguments): Also return the result
5513         of warn_for_restrict.
5514         * c-common.c (check_function_restrict): Return bool.
5515         * c-warn.c (warn_for_restrict): Return bool.
5517 2018-03-02  Marek Polacek  <polacek@redhat.com>
5519         PR c++/84171
5520         * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
5521         is erroneous.
5523 2018-03-02  Thomas Schwinge  <thomas@codesourcery.com>
5525         * c-attribs.c (c_common_attribute_table): Remove "cilk simd
5526         function".
5528 2018-03-01  Marek Polacek  <polacek@redhat.com>
5530         PR c++/84639
5531         * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
5532         alignment in computation.
5534 2018-02-28  Eric Botcazou  <ebotcazou@adacore.com>
5536         * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
5537         <REAL_TYPE>: Deal specifically with _Float128/__float128.
5539 2018-02-28  Eric Botcazou  <ebotcazou@adacore.com>
5541         * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
5542         (is_char_array): Take a type instead of a declaration.
5543         (dump_ada_array_type): Likewise.
5544         (is_simple_enum): Minor tweak.
5545         (dump_ada_enum_type): New function extracted from...
5546         (dump_ada_node) <ENUMERAL_TYPE>: ...here.  Invoke it.
5547         <INTEGER_TYPE>: Remove unreachable code.
5548         <RECORD_TYPE>: Likewise.  Minor tweaks.
5549         (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
5550         <ENUMERAL_TYPE>: New case.
5551         <RECORD_TYPE>: Factor out common code.
5552         (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
5553         Minor tweaks.  Deal with enumeral types.
5554         (dump_ada_structure): Minor tweaks.
5556 2018-02-28  Eric Botcazou  <ebotcazou@adacore.com>
5558         * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
5559         address for incomplete structures.
5560         (dump_forward_type): Do not bail out for incomplete structures.
5561         (dump_ada_declaration): Do not special-case incomplete structures
5562         for subtypes.  Dump them as null records for types.
5564 2018-02-28  Eric Botcazou  <ebotcazou@adacore.com>
5566         * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
5567         (is_char_array): Fix formatting.
5568         (dump_template_types): Likewise.
5569         (dump_generic_ada_node): Rename into...
5570         (dump_ada_node): ...this.
5571         <POINTER_TYPE>: Remove superfluous space.  Use generic address for
5572         incomplete structures and not for empty structures.  Do not use it
5573         when forward declarations are needed.
5574         (dump_forward_type): New function.
5575         (dump_nested_types): Remove FORWARD parameter.  Do not consider
5576         TREE_VISITED and do not generate a forward declaration.  Only dump
5577         original nested types for nested declaration.
5578         (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
5579         <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
5580         <RECORD_TYPE>: Do not consider TREE_VISITED.
5581         (dump_ada_declaration): Use booleans and fix formatting throughout.
5582         <TYPE_DECL>: Skip incomplete structures and not empty structures.
5583         Call dump_forward_type instead of dump_nested_types for a typedef.
5584         Remove superfluous check and adjust call to dump_nested_types.
5585         <POINTER_TYPE>: Call dump_forward_type and fall through.
5586         (dump_ada_struct_decl): Rename into...
5587         (dump_ada_structure): ...this.  Do not special-case empty structures.
5589 2018-02-27  Martin Sebor  <msebor@redhat.com>
5591         PR c++/83871
5592         * c.opt (-Wmissing-attributes): New option.
5594 2018-02-21  Martin Liska  <mliska@suse.cz>
5596         * c.opt (Wcatch-value=): Add IntegerRange.
5598 2018-02-15  Jason Merrill  <jason@redhat.com>
5600         * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
5602 2018-02-09  Nathan Sidwell  <nathan@acm.org>
5604         PR c/84293
5605         * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
5606         arg.
5607         * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
5608         arg.  Adjust.
5610 2018-02-09  Martin Sebor  <msebor@redhat.com>
5612         PR lto/84212
5613         * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
5614         (-Walloc-size-larger-than, -Wformat-truncation=): Same.
5615         (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
5616         (-Wstrict-overflow, -Wsuggest-attribute): Same.
5617         (-Wuninitialized): Same.
5619 2018-02-09  Eric Botcazou  <ebotcazou@adacore.com>
5621         * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
5622         keyword for components.
5624 2018-02-02  Paolo Carlini  <paolo.carlini@oracle.com>
5626         * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
5628 2018-02-02  Julia Koval  <julia.koval@intel.com>
5630         * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
5632 2018-01-29  Marek Polacek  <polacek@redhat.com>
5634         PR c/83966
5635         * c-format.c (check_function_format): Check current_function_decl.
5637 2018-01-27  Jakub Jelinek  <jakub@redhat.com>
5639         * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
5640         argument.
5641         (LAZY_HEX_FP_VALUES_CNT): Define.
5642         (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
5643         values rather than just 12.
5644         (builtin_define_with_hex_fp_value): Likewise.
5646 2018-01-18  Boris Kolpackov  <boris@codesynthesis.com>
5648         PR other/70268
5649         * c.opt (-fmacro-prefix-map): New option.
5650         * c-opts.c (c_common_handle_option): Handle it.
5651         * c-lex.c (init_c_lex): Set remap_filename cpp callback.
5652         * c-ppoutput.c (init_pp_output): Likewise.
5654 2018-01-17  David Malcolm  <dmalcolm@redhat.com>
5656         PR c++/83814
5657         * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
5659 2018-01-10  Eric Botcazou  <ebotcazou@adacore.com>
5661         * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
5662         Skip 'f' and 'F' characters if it is true.
5663         (store_ada_macro): Minor tweak.
5664         (dump_ada_macros) <CPP_COMMENT>: Likewise.
5665         <CPP_WSTRING>: Likewise.
5666         <CPP_STRING>: Output '&' in the buffer if not the first string.
5667         <CPP_NUMBER>: Adjust calls to dump_number.
5669 2018-01-10  David Malcolm  <dmalcolm@redhat.com>
5671         PR c++/43486
5672         * c-common.c: Include "selftest.h".
5673         (get_atomic_generic_size): Perform the test for integral type
5674         before the range test for any integer constant, fixing indentation
5675         of braces.  Call fold_for_warn before testing for an INTEGER_CST.
5676         (reject_gcc_builtin): Strip any location wrapper from EXPR.
5677         (selftest::test_fold_for_warn): New function.
5678         (selftest::c_common_c_tests): New function.
5679         (selftest::c_family_tests): Call it, and
5680         selftest::c_pretty_print_c_tests.
5681         * c-common.h (selftest::c_pretty_print_c_tests): New decl.
5682         * c-format.c (check_format_arg): Convert VAR_P check to a
5683         fold_for_warn.
5684         * c-pretty-print.c: Include "selftest.h".
5685         (pp_c_cast_expression): Don't print casts for location wrappers.
5686         (selftest::assert_c_pretty_printer_output): New function.
5687         (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
5688         (selftest::test_location_wrappers): New function.
5689         (selftest::c_pretty_print_c_tests): New function.
5690         * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
5692 2018-01-03  Richard Sandiford  <richard.sandiford@linaro.org>
5693             Alan Hayward  <alan.hayward@arm.com>
5694             David Sherwood  <david.sherwood@arm.com>
5696         * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
5698 2018-01-03  Richard Sandiford  <richard.sandiford@linaro.org>
5699             Alan Hayward  <alan.hayward@arm.com>
5700             David Sherwood  <david.sherwood@arm.com>
5702         * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
5703         as polynomial.
5705 2018-01-03  Richard Sandiford  <richard.sandiford@linaro.org>
5706             Alan Hayward  <alan.hayward@arm.com>
5707             David Sherwood  <david.sherwood@arm.com>
5709         * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
5710         (convert_vector_to_array_for_subscript): Handle polynomial
5711         TYPE_VECTOR_SUBPARTS.
5712         (c_common_type_for_mode): Check valid_vector_subparts_p.
5713         * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
5714         VECTOR_CST_NELTS.
5716 2018-01-03  Jakub Jelinek  <jakub@redhat.com>
5718         Update copyright years.
5720 2017-12-22  Mike Stump  <mikestump@comcast.net>
5721             Eric Botcazou  <ebotcazou@adacore.com>
5723         * c-pragma.c (init_pragma): Register pragma GCC unroll.
5724         * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
5726 2017-12-22  Alexandre Oliva  <aoliva@redhat.com>
5728         PR debug/83527
5729         PR debug/83419
5730         * c-semantics.c (only_debug_stmts_after_p): New.
5731         (pop_stmt_list): Clear side effects in debug-only stmt list.
5732         Check for single nondebug stmt followed by debug stmts only.
5734 2017-12-21  Alexandre Oliva  <aoliva@redhat.com>
5736         PR debug/83419
5737         * c-semantics.c (pop_stmt_list): Propagate side effects from
5738         single nondebug stmt to container list.
5740 2017-12-19  Jakub Jelinek  <jakub@redhat.com>
5742         * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
5743         conditions with typical order conditions.
5745 2017-12-18  Marek Polacek  <polacek@redhat.com>
5747         * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
5748         not in effect.
5750 2017-12-17  Martin Sebor  <msebor@redhat.com>
5752         * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
5753         an error for attribute warn_if_not_aligned.
5755 2017-12-16  Martin Sebor  <msebor@redhat.com>
5757         PR tree-optimization/78918
5758         * c-common.c (check_function_restrict): Avoid checking built-ins.
5759         * c.opt (-Wrestrict): Include in -Wall.
5761 2017-12-15  Jakub Jelinek  <jakub@redhat.com>
5763         * c-attribs.c (c_common_attribute_table,
5764         c_common_format_attribute_table): Swap affects_type_identity
5765         and handler fields, adjust comments.
5767 2017-12-14  Bernd Edlinger  <bernd.edlinger@hotmail.de>
5769         * c.opt (Wcast-function-type): New warning option.
5770         * c-lex.c (get_fileinfo): Avoid warning.
5771         * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
5773 2017-12-14  Qing Zhao  <qing.zhao@oracle.com>
5775         PR middle_end/79538
5776         * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
5777         Adjust the size of buf1 and buf2, add a new buf to avoid
5778         format-overflow warning.
5780 2017-12-12  Alexandre Oliva  <aoliva@redhat.com>
5782         * c-semantics.c (pop_stmt_list): Move begin stmt marker into
5783         subsequent statement list.
5785 2017-12-07  Martin Sebor  <msebor@redhat.com>
5787         PR c/81544
5788         PR c/81566
5789         * c-attribs.c (attr_aligned_exclusions): New array.
5790         (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
5791         (attr_common_exclusions, attr_const_pure_exclusions): Same.
5792         (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
5793         (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
5794         (attr_warn_unused_result_exclusions): Same.
5795         (handle_hot_attribute, handle_cold_attribute): Simplify.
5796         (handle_const_attribute): Warn on function returning void.
5797         (handle_pure_attribute): Same.
5798         (handle_aligned_attribute): Diagnose conflicting attribute
5799         specifications.
5800         * c-warn.c (diagnose_mismatched_attributes): Simplify.
5802 2017-12-06  David Malcolm  <dmalcolm@redhat.com>
5804         PR c/83236
5805         * c-common.c (selftest::c_family_tests): Call
5806         selftest::c_spellcheck_cc_tests.
5807         * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
5808         * c-spellcheck.cc: Include "selftest.h".
5809         (name_reserved_for_implementation_p): New function.
5810         (should_suggest_as_macro_p): New function.
5811         (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
5812         should_suggest_as_macro_p and call it.
5813         (selftest::test_name_reserved_for_implementation_p): New function.
5814         (selftest::c_spellcheck_cc_tests): New function.
5815         * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
5817 2017-12-06  David Malcolm  <dmalcolm@redhat.com>
5819         * c-spellcheck.cc: New file, taken from macro-handling code in
5820         spellcheck-tree.c.
5821         * c-spellcheck.h: New file, taken from macro-handling code in
5822         spellcheck-tree.h.
5824 2017-12-01  Jakub Jelinek  <jakub@redhat.com>
5826         * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
5827         attribute.
5828         (handle_simd_attribute): Don't check for "cilk simd function"
5829         attribute.  Reindent, formatting changes.
5831 2017-11-30  Julia Koval  <julia.koval@intel.com>
5833         * c-common.h (inv_list): Remove.
5835 2017-11-28  Jakub Jelinek  <jakub@redhat.com>
5837         PR sanitizer/81275
5838         * c-common.c (c_switch_covers_all_cases_p_1,
5839         c_switch_covers_all_cases_p): New functions.
5840         * c-common.h (c_switch_covers_all_cases_p): Declare.
5842 2017-11-28  Julia Koval  <julia.koval@intel.com>
5843             Sebastian Peryt  <sebastian.peryt@intel.com>
5845         * array-notation-common.c: Delete.
5846         * c-cilkplus.c: Ditto.
5847         * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
5848         * c-common.def (ARRAY_NOTATION_REF): Remove.
5849         * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
5850         build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
5851         c_validate_cilk_plus_loop, cilkplus_an_parts,
5852         cilk_ignorable_spawn_rhs_op,
5853         cilk_recognize_spawn): Remove.
5854         * c-gimplify.c (CILK_SPAWN_STMT): Remove.
5855         * c-omp.c: Remove CILK_SIMD check.
5856         * c-pragma.c: Ditto.
5857         * c-pragma.h: Remove CILK related pragmas.
5858         * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
5859         ARRAY_NOTATION_REF condition.
5860         (c_pretty_printer::expression): Ditto.
5861         * c.opt (fcilkplus): Remove.
5862         * cilk.c: Delete.
5864 2017-11-21  Marc Glisse  <marc.glisse@inria.fr>
5866         * c-pretty-print.c (pp_c_additive_expression,
5867         c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
5869 2017-11-21  Jakub Jelinek  <jakub@redhat.com>
5871         * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
5873         PR c++/83059
5874         * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
5875         instead of tree_to_uhwi, formatting fix.
5877 2017-11-20  David Malcolm  <dmalcolm@redhat.com>
5879         PR c/81404
5880         * known-headers.cc: New file, based on material from c/c-decl.c.
5881         (suggest_missing_header): Copied as-is.
5882         (get_stdlib_header_for_name): New, based on get_c_name_hint but
5883         heavily edited to add C++ support.  Add some knowledge about
5884         <limits.h>, <stdint.h>, and <wchar.h>.
5885         * known-headers.h: Likewise.
5887 2017-11-20  David Malcolm  <dmalcolm@redhat.com>
5889         * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
5890         (lookup_name_fuzzy): Likewise.  Convert return type from
5891         const char * to name_hint.  Add location_t param.
5892         * name-hint.h: New header.
5894 2017-11-19  Jakub Jelinek  <jakub@redhat.com>
5896         PR c/66618
5897         PR c/69960
5898         * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
5900 2017-11-16  Joseph Myers  <joseph@codesourcery.com>
5902         * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
5903         expected publication date of C17.
5904         (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
5906 2017-11-15  Joseph Myers  <joseph@codesourcery.com>
5908         PR c/81156
5909         * c-common.c (c_common_reswords): Add __builtin_tgmath.
5910         * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
5912 2017-11-10  Martin Sebor  <msebor@redhat.com>
5914         PR c/81117
5915         * c-common.c (catenate_strings): Use memcpy instead of strncpy.
5916         * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
5917         * c.opt (-Wstringop-truncation): New option.
5919 2017-11-06  Martin Liska  <mliska@suse.cz>
5921         PR middle-end/82404
5922         * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
5923         FE.
5924         * c.opt: Set default value of warn_return_type.
5926 2017-10-31  David Malcolm  <dmalcolm@redhat.com>
5928         * c-common.c (binary_op_error): Update for renaming of
5929         error_at_rich_loc.
5930         (c_parse_error): Likewise.
5931         * c-warn.c (warn_logical_not_parentheses): Likewise for
5932         renaming of inform_at_rich_loc.
5933         (warn_for_restrict): Likewise for renaming of
5934         warning_at_rich_loc_n.
5936 2017-10-30  Joseph Myers  <joseph@codesourcery.com>
5938         * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
5939         * c-opts.c (set_std_c17): New function.
5940         (c_common_init_options): Use gnu17 as default C version.
5941         (c_common_handle_option): Handle -std=c17 and -std=gnu17.
5943 2017-10-27  Michael Meissner  <meissner@linux.vnet.ibm.com>
5945         * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
5946         (c_cpp_builtins): If a machine has a fast fma _Float<N> and
5947         _Float<N>X variant, define __FP_FAST_FMA<N> and/or
5948         __FP_FAST_FMA<N>X.
5950 2017-10-23  Marek Polacek  <polacek@redhat.com>
5952         PR c/82681
5953         * c-warn.c (warnings_for_convert_and_check): Fix typos.
5955 2017-10-19  Eric Botcazou  <ebotcazou@adacore.com>
5957         * c-common.c (check_builtin_function_arguments): Also check arguments
5958         of __builtin_alloca_with_align_and_max.
5960 2017-10-17  David Malcolm  <dmalcolm@redhat.com>
5962         * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
5963         rather than NULL to format_warning_va.
5964         (check_format_types): Likewise when calling format_type_warning.
5965         Remove code to extract source_ranges and source_range * in favor
5966         of just a location_t.
5967         (format_type_warning): Convert source_range * param to a
5968         location_t.
5970 2017-10-13  Jakub Jelinek  <jakub@redhat.com>
5972         * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
5973         [LR]SHIFT_EXPR.
5975 2017-10-12  David Malcolm  <dmalcolm@redhat.com>
5977         * c-common.c (enum missing_token_insertion_kind): New enum.
5978         (get_missing_token_insertion_kind): New function.
5979         (maybe_suggest_missing_token_insertion): New function.
5980         * c-common.h (maybe_suggest_missing_token_insertion): New decl.
5982 2017-10-11  Nathan Sidwell  <nathan@acm.org>
5984         * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
5985         (c_common_handle_option): Update incpath_kind names.
5987 2017-10-11  Martin Liska  <mliska@suse.cz>
5989         PR sanitizer/82490
5990         * c-attribs.c (handle_no_sanitize_attribute): Report directly
5991         Wattributes warning.
5993 2017-10-10  Richard Sandiford  <richard.sandiford@linaro.org>
5995         * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
5996         operating on trees as wide_ints.
5997         * c-common.c (pointer_int_sum): Likewise.
5998         * c-pretty-print.c (pp_c_integer_constant): Likewise.
5999         * c-warn.c (match_case_to_enum_1): Likewise.
6000         (c_do_switch_warnings): Likewise.
6001         (maybe_warn_shift_overflow): Likewise.
6003 2017-10-10  Jakub Jelinek  <jakub@redhat.com>
6005         PR c/82437
6006         * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
6007         instead of wide_int::from.
6009 2017-10-06  Jakub Jelinek  <jakub@redhat.com>
6011         PR c/82437
6012         * c-warn.c (warn_tautological_bitwise_comparison): Instead of
6013         using to_widest use wide_int with the larger of the two precisions.
6015 2017-10-05  Bernd Edlinger  <bernd.edlinger@hotmail.de>
6017         * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
6018         functions.
6020 2017-10-02  Richard Sandiford  <richard.sandiford@linaro.org>
6022         * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
6023         when combining the original unconverted comparison operands.
6025 2017-09-29  Jakub Jelinek  <jakub@redhat.com>
6027         * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
6028         attribute.
6030 2017-09-29  Eric Botcazou  <ebotcazou@adacore.com>
6032         * c-ada-spec.c (to_ada_name): Add index parameter.
6033         (pp_ada_tree_identifier): Likewise.
6034         (dump_ada_macros): Adjust call to to_ada_name.
6035         (struct overloaded_name_hash): New type.
6036         (struct overloaded_name_hasher): Likewise.
6037         (overloaded_names): New hash table.
6038         (compute_overloading_index): New function.
6039         (dump_ada_decl_name): Call it and pass the result to
6040         pp_ada_tree_identifier.
6041         (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
6042         (dump_ada_function_declaration): Likewise.
6043         (dump_generic_ada_node): Likewise.
6044         (print_constructor): Likewise.
6045         (print_destructor): Likewise.
6046         (dump_ada_specs): Delete overloaded_names table.
6048 2017-09-29  Eric Botcazou  <ebotcazou@adacore.com>
6050         * c-ada-spec.c (max_ada_macros): Move around.
6051         (store_ada_macro_index): Likewise.
6052         (source_file): Rename into...
6053         (macro_source_file): ...this.
6054         (count_ada_macro): Move around.
6055         (store_ada_macro): Likewise.
6056         (compare_macro): Likewise.
6057         (print_ada_macros): Merge in...
6058         (dump_ada_macros): ...this.
6059         (source_file_base): Rename into...
6060         (current_source_file): ...this.
6061         (print_comment): Move around.
6062         (dump_ada_nodes): Call dump_ada_declaration directly.
6063         (struct with): Change type of limited field to bool.
6064         (append_withs): Change type of limited_access parameter to bool.
6065         (pp_ada_tree_identifie): Likewise.
6066         (dump_ada_decl_nam): Likewise.
6067         (dump_generic_ada_node): Likewise.  Do not print the return type.
6068         (to_ada_name): Change type of space_found parameter to bool.
6069         (dump_ada_function_declaration): Return void and change type of
6070         parameters to bool.  Also print the return type for a function.
6071         (print_ada_methods): Rename into...
6072         (dump_ada_methods): ...this.
6073         (print_ada_declaration): Rename into ...
6074         (dump_ada_declaration): ...this.  Do not print the return type.
6075         (print_ada_struct_decl): Rename into...
6076         (dump_ada_struct_decl): ...this.
6078 2017-09-29  Jakub Jelinek  <jakub@redhat.com>
6080         * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
6081         rather than DECL_INITIAL.
6082         (common_handle_aligned_attribute): Likewise.
6084 2017-09-20  Alexandre Oliva  <aoliva@redhat.com>
6086         * c.opt (gen-decls): Add RejectNegative.
6088 2017-09-15  Andrew Sutton  <andrew.n.sutton@gmail.com>
6089             Jakub Jelinek  <jakub@redhat.com>
6091         Add support for -std=c++2a.
6092         * c-common.h (cxx_dialect): Add cxx2a as a dialect.
6093         * opt.c: Add options for -std=c++2a and -std=gnu++2a.
6094         * c-opts.c (set_std_cxx2a): New.
6095         (c_common_handle_option): Set options when -std=c++2a is enabled.
6096         (c_common_post_options): Adjust comments.
6097         (set_std_cxx14, set_std_cxx17): Likewise.
6099 2017-09-15  Eric Botcazou  <ebotcazou@adacore.com>
6101         * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
6102         message for non-uniform endianness and issue a warning in C++.
6104 2017-09-15  Jakub Jelinek  <jakub@redhat.com>
6106         * c.opt (Wc++1z-compat): Change from option to undocumented alias.
6107         (Wc++17-compat): Change from undocumented alias to option.
6108         (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
6109         change C++1z to C++17 in description.
6110         (std=c++1z, std=gnu++1z): Change from option to undocumented
6111         deprecated alias.
6112         (std=c++17, std=gnu++17): Change from undocumented alias to option.
6113         Adjust description.
6114         * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
6115         * c-opts.c (set_std_cxx1z): Rename to ...
6116         (set_std_cxx17): ... this.
6117         (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
6118         and OPT_std_gnu__1z to OPT_std_gnu__17.  Adjust set_std_cxx1z
6119         caller.
6120         (c_common_post_options): Use cxx17 instead of cxx1z.  Adjust
6121         comments.
6123 2017-09-12  H.J. Lu  <hongjiu.lu@intel.com>
6125         * c-attribs.c (common_handle_aligned_attribute): Don't warn
6126         function alignment if warn_if_not_aligned_p is true.
6128 2017-09-12  Nathan Sidwell  <nathan@acm.org>
6130         * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
6131         resort_sorted_fields): Move to c/c-decl.c.
6132         * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
6133         (struct sorted_fields_type): Move to c/c-lang.h.
6135 2017-09-09  Jonathan Wakely  <jwakely@redhat.com>
6137         PR c++/81852
6138         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
6140 2017-09-04  Marek Polacek  <polacek@redhat.com>
6142         PR c/81783
6143         * c-warn.c (warn_tautological_bitwise_comparison): New function.
6144         (warn_tautological_cmp): Call it.
6146 2017-09-01  Boris Kolpackov  <boris@codesynthesis.com>
6148         * c-opts.c (c_common_finish): Write dependency information even if
6149         there are errors.
6151 2017-09-01  Jakub Jelinek  <jakub@redhat.com>
6153         PR c/81887
6154         * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
6155         (omp_pragmas_simd): ... here.
6156         * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
6157         create new clauses list containing just simd clause.
6159 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
6160             Alan Hayward  <alan.hayward@arm.com>
6161             David Sherwood  <david.sherwood@arm.com>
6163         * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
6164         into scalar_mode_supported_p call.
6165         (handle_mode_attribute): Update call to scalar_mode_supported_p.
6167 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
6168             Alan Hayward  <alan.hayward@arm.com>
6169             David Sherwood  <david.sherwood@arm.com>
6171         * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
6172         for the mode iterator.
6174 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
6175             Alan Hayward  <alan.hayward@arm.com>
6176             David Sherwood  <david.sherwood@arm.com>
6178         * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
6179         * c-common.c (c_build_vec_perm_expr): Likewise.
6181 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
6182             Alan Hayward  <alan.hayward@arm.com>
6183             David Sherwood  <david.sherwood@arm.com>
6185         * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
6187 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
6188             Alan Hayward  <alan.hayward@arm.com>
6189             David Sherwood  <david.sherwood@arm.com>
6191         * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
6192         before calling targetm.addr_space.valid_pointer_mode.
6194 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
6195             Alan Hayward  <alan.hayward@arm.com>
6196             David Sherwood  <david.sherwood@arm.com>
6198         * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
6200 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
6201             Alan Hayward  <alan.hayward@arm.com>
6202             David Sherwood  <david.sherwood@arm.com>
6204         * c-common.c (c_common_fixed_point_type_for_size): Use new mode
6205         iterators.
6206         * c-cppbuiltin.c (c_cpp_builtins): Likewise.
6208 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
6209             Alan Hayward  <alan.hayward@arm.com>
6210             David Sherwood  <david.sherwood@arm.com>
6212         * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
6213         case statements.
6215 2017-08-29  Martin Liska  <mliska@suse.cz>
6217         PR other/39851
6218         * c-common.c (parse_optimize_options): Add argument to function
6219         call.
6220         * c-pragma.c (handle_pragma_diagnostic): Likewise.
6222 2017-08-24  David Malcolm  <dmalcolm@redhat.com>
6224         * c-lex.c (interpret_float): Use token location
6225         when building an EXCESS_PRECISION_EXPR.
6227 2017-08-21  David Malcolm  <dmalcolm@redhat.com>
6229         * c-common.c (check_function_arguments): Add "arglogs" param; pass
6230         it to check_function_format.
6231         * c-common.h (check_function_arguments): Add vec<location_t> *
6232         param.
6233         (check_function_format): Likewise.
6234         * c-format.c (struct format_check_context): Add field "arglocs".
6235         (check_function_format): Add param "arglocs"; pass it to
6236         check_format_info.
6237         (check_format_info): Add param "arglocs"; use it to initialize
6238         new field of format_ctx.
6239         (check_format_arg): Pass format_ctx->arglocs to new param of
6240         check_format_info_main.
6241         (class argument_parser): New field "arglocs".
6242         (argument_parser::argument_parser): Add "arglocs_" param and use
6243         it to initialize new field.
6244         (argument_parser::check_argument_type): Pass new arglocs field to
6245         check_format_types.
6246         (check_format_info_main): Add param "arglocs", and use it when
6247         constructing arg_parser.
6248         (check_format_types): Add param "arglocs"; use it if non-NULL when
6249         !EXPR_HAS_LOCATION (cur_param) to get at location information.
6251 2017-08-18  H.J. Lu  <hongjiu.lu@intel.com>
6253         PR c/53037
6254         * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
6255         (c_common_attribute_table): Add warn_if_not_aligned.
6256         (handle_aligned_attribute): Renamed to ...
6257         (common_handle_aligned_attribute): Remove argument, name, and add
6258         argument, warn_if_not_aligned.  Handle warn_if_not_aligned.
6259         (handle_aligned_attribute): New.
6260         * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
6262 2017-08-14  Martin Sebor  <msebor@redhat.com>
6264         PR c/81117
6265         * c-attribs.c (c_common_attribute_table): Add nonstring entry.
6266         (handle_nonstring_attribute): New function.
6268 2017-08-14  Martin Sebor  <msebor@redhat.com>
6270         PR c/81117
6271         * c-format.h (T89_G): New macro.
6272         * c-format.c (local_gcall_ptr_node): New variable.
6273         (init_dynamic_diag_info): Initialize it.
6275 2017-08-11  Martin Liska  <mliska@suse.cz>
6277         * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
6278         TARGET_SUPPORTS_ALIASES.
6280 2017-08-10  David Malcolm  <dmalcolm@redhat.com>
6282         * c-common.c (c_parse_error): Add rich_location * param, using it
6283         rather implicitly using input_location.
6284         * c-common.h (c_parse_error): Add rich_location * param.
6286 2017-08-09  Marek Polacek  <polacek@redhat.com>
6288         * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
6289         (c_common_truthvalue_conversion): Likewise.
6290         * c-omp.c (c_finish_omp_atomic): Likewise.
6291         * c-common.h (build_binary_op): Update declaration.
6293 2017-08-08  Martin Liska  <mliska@suse.cz>
6295         * c-ada-spec.c: Include header files.
6296         * c-ubsan.c: Likewise.
6297         * c-warn.c: Likewise.
6299 2017-08-07  Jakub Jelinek  <jakub@redhat.com>
6301         PR c/69389
6302         * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
6304 2017-08-07  Eric Botcazou  <ebotcazou@adacore.com>
6306         * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
6307         (print_ada_methods): Likewise.
6308         (print_ada_declaration): Likewise.
6310 2017-08-07  Martin Liska  <mliska@suse.cz>
6312         * array-notation-common.c: Add new includes.
6313         * c-format.c( handle_format_attribute): Canonicalize a format
6314         function name.
6315         * c-lex.c (c_common_has_attribute): Canonicalize name of an
6316         attribute.
6317         * c-pretty-print.c: Add new include.
6319 2017-08-05  Eric Botcazou  <ebotcazou@adacore.com>
6321         * c-ada-spec.c (has_static_fields): Look only into variables.
6322         (print_constructor): Add TYPE parameter and use it for the name.
6323         (print_destructor): Likewise.
6324         (print_ada_declaration): Adjust to new constructor/destructor names.
6325         Adjust calls to print_constructor and print_destructor.
6326         (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
6327         Look only into variables in the final loop.
6329 2017-08-01  Eric Botcazou  <ebotcazou@adacore.com>
6331         * c-ada-spec.c (has_static_fields): Look only into fields.
6332         (dump_generic_ada_node): Small tweak.
6333         (dump_nested_types): Look only into fields.
6334         (print_ada_declaration): Look only into methods.  Small tweak.
6335         (print_ada_struct_decl): Look only into fields.  Use DECL_VIRTUAL_P.
6337 2017-08-01  Eric Botcazou  <ebotcazou@adacore.com>
6339         * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
6340         (dump_ada_function_declaration): Likewise.
6341         (dump_generic_ada_node): Likewise.
6342         (print_ada_declaration): Add support for const-qualified variables.
6344 2017-07-31  Martin Liska  <mliska@suse.cz>
6346         PR sanitize/81530
6347         * c-ubsan.c (ubsan_maybe_instrument_array_ref):
6348         Guard condition with flag_sanitize_p also with current_function_decl
6349         non-null equality.
6350         (ubsan_maybe_instrument_reference_or_call): Likewise.
6352 2017-07-30  Uros Bizjak  <ubizjak@gmail.com>
6354         * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
6356 2017-07-29  Eric Botcazou  <ebotcazou@adacore.com>
6358         * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
6359         for enumeral types.
6360         (print_ada_declaration): Add missing guard for record types.
6362 2017-07-27  Jakub Jelinek  <jakub@redhat.com>
6364         PR c/45784
6365         * c-omp.c (c_finish_omp_for): If the condition is wrapped in
6366         rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
6367         new COMPOUND_EXPRs around the rhs of the comparison.
6369 2017-07-27  Marek Polacek  <polacek@redhat.com>
6371         PR c/81417
6372         * c-warn.c (warn_for_sign_compare): Tweak the warning message.  Print
6373         the types.
6375 2017-07-27  Jakub Jelinek  <jakub@redhat.com>
6377         * c-attribs.c (c_common_attribute_table): Add noipa attribute.
6378         (handle_noipa_attribute): New function.
6380 2017-07-07  Torsten Duwe  <duwe@suse.de>
6382         * c-attribs.c (c_common_attribute_table): Add entry for
6383         "patchable_function_entry".
6385 2017-07-20  Nathan Sidwell  <nathan@acm.org>
6387         Remove TYPE_METHODS.
6388         * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
6389         dump_ada_template, print_ada_methods,
6390         print_ada_declaration): Member fns are on TYPE_FIELDS.
6392 2017-07-18  Nathan Sidwell  <nathan@acm.org>
6394         * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
6396 2017-07-14  David Malcolm  <dmalcolm@redhat.com>
6398         * c-common.c (try_to_locate_new_include_insertion_point): New
6399         function.
6400         (per_file_includes_t): New typedef.
6401         (added_includes_t): New typedef.
6402         (added_includes): New variable.
6403         (maybe_add_include_fixit): New function.
6404         * c-common.h (maybe_add_include_fixit): New decl.
6406 2017-07-10  Martin Sebor  <msebor@redhat.com>
6408         PR other/81345
6409         * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
6411 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
6413         * c-common.c (selftest::c_family_tests): New.
6414         * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
6415         (selftest::c_family_tests): New decl.
6417 2017-07-04  Marek Polacek  <polacek@redhat.com>
6419         PR c/81231
6420         * c-common.c (sync_resolve_size): Give error for pointers to incomplete
6421         types.
6423 2017-07-04  Marek Polacek  <polacek@redhat.com>
6425         * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
6427 2017-06-28  Martin Liska  <mliska@suse.cz>
6429         PR ipa/81128
6430         * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
6431         to a function declaration.
6433 2017-06-28  Martin Liska  <mliska@suse.cz>
6435         PR driver/79659
6436         * c.opt: Add IntegerRange to various options.
6438 2017-06-26  Marek Polacek  <polacek@redhat.com>
6440         PR c/80116
6441         * c-common.h (warn_for_multistatement_macros): Declare.
6442         * c-warn.c: Include "c-family/c-indentation.h".
6443         (warn_for_multistatement_macros): New function.
6444         * c.opt (Wmultistatement-macros): New option.
6445         * c-indentation.c (guard_tinfo_to_string): No longer static.
6446         Change the parameter type to "enum rid".  Handle RID_SWITCH.
6447         * c-indentation.h (guard_tinfo_to_string): Declare.
6449 2017-06-23  Marc Glisse  <marc.glisse@inria.fr>
6451         * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
6453 2017-06-15  Martin Sebor  <msebor@redhat.com>
6455         PR c++/80560
6456         * c.opt (-Wclass-memaccess): New option.
6458 2017-06-14  Boris Kolpackov  <boris@codesynthesis.com>
6460         * c-opts.c (c_common_finish): Handle '-' special value to -MF.
6462 2017-06-13  Marek Polacek  <polacek@redhat.com>
6464         PR objc/80949
6465         * c-warn.c (do_warn_duplicated_branches): Return if any of the
6466         branches is null.
6468 2017-06-13  Martin Liska  <mliska@suse.cz>
6470         PR sanitize/78204
6471         * c-attribs.c (add_no_sanitize_value): New function.
6472         (handle_no_sanitize_attribute): Likewise.
6473         (handle_no_sanitize_address_attribute): Use the function.
6474         (handle_no_sanitize_thread_attribute): New function.
6475         (handle_no_address_safety_analysis_attribute): Use
6476         add_no_sanitize_value.
6477         (handle_no_sanitize_undefined_attribute): Likewise.
6478         * c-common.h: Declare new functions.
6479         * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
6480         (ubsan_instrument_shift): Likewise.
6481         (ubsan_instrument_bounds): Likewise.
6482         (ubsan_maybe_instrument_array_ref): Likewise.
6483         (ubsan_maybe_instrument_reference_or_call): Likewise.
6485 2017-06-11  Jason Merrill  <jason@redhat.com>
6487         * c-ada-spec.c, c-pragma.c: Use id_equal.
6489 2017-06-04  Marek Polacek  <polacek@redhat.com>
6491         PR c/80919
6492         * c-format.c (matching_type_p): Return false if any of the types
6493         requires structural equality.
6495 2017-06-02  Martin Sebor  <msebor@redhat.com>
6497         PR c/80892
6498         * c-warn.c (conversion_warning): Use -Wconversion for integer
6499         conversion and -Wfloat-conversion for floating one.
6501 2017-06-02  Bernd Edlinger  <bernd.edlinger@hotmail.de>
6503         * c.opt (Wsizeof-pointer-div): New warning option.
6505 2017-06-01  Volker Reichelt  <v.reichelt@netcologne.de>
6507         * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
6508         (Wcatch-value=1): Enable by -Wall.
6510 2017-05-30  David Malcolm  <dmalcolm@redhat.com>
6512         * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
6513         format_chars.
6514         * c.opt (fdiagnostics-show-template-tree): New option.
6515         (felide-type): New option.
6517 2017-05-25  Volker Reichelt  <v.reichelt@netcologne.de>
6519         * c.opt (Wcatch-value=): New C++ warning flag.
6521 2017-05-24  Nathan Sidwell  <nathan@acm.org>
6523         * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
6524         const casts to avoid warning.
6526 2017-05-24  Martin Sebor  <msebor@redhat.com>
6528         PR c/80731
6529         * c-common.h (unsafe_conversion_p): Add a function argument.
6530         * c-common.c (unsafe_conversion_p): Same.
6531         Add type names and values to diagnostics.
6532         (scalar_to_vector): Adjust.
6533         * c-warn.c (constant_expression_error): Add a function argument.
6534         Add type names and values to diagnostics.
6535         (conversion_warning): Add a function argument.
6536         Add type names and values to diagnostics.
6537         (warnings_for_convert_and_check): Same.
6539 2017-05-19  Jason Merrill  <jason@redhat.com>
6541         * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
6542         enumerators.
6544 2017-05-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>
6546         * c-format.c (locus): Move out of function scope,
6547         add GTY attribute.
6549 2017-05-19  Nathan Sidwell  <nathan@acm.org>
6551         * c-opts.c (class_dump_file, class_dump_flags): Delete.
6552         (c_common_parse_file): Remove class dump handling.
6553         (get_dump_info): Likewise.
6555 2017-05-19  Richard Biener  <rguenther@suse.de>
6557         PR c++/80593
6558         * c-warn.c (strict_aliasing_warning): Do not warn for accesses
6559         to alias-set zero memory.
6561 2017-05-18  Bernd Edlinger  <bernd.edlinger@hotmail.de>
6563         * c-format.c (local_tree_type_node): Add GTY attribute.
6565 2017-05-18  Marek Polacek  <polacek@redhat.com>
6567         * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
6568         (c_common_fixed_point_type_for_size): Likewise.
6569         (c_common_type_for_mode): Likewise.
6570         (shorten_compare): Likewise.
6571         (c_promoting_integer_type_p): Use false/true instead of 0/1.
6572         * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
6574 2017-05-18  Marek Polacek  <polacek@redhat.com>
6576         * c-common.c (self_promoting_args_p): Change the return type to bool.
6577         Use false/true instead of 0/1.
6578         * c-common.h (self_promoting_args_p): Update.
6580 2017-05-17  Marek Polacek  <polacek@redhat.com>
6582         * c-common.c: Use NULL_TREE instead of 0 where appropriate.
6583         * c-warn.c: Likewise.
6585 2017-05-17  Ville Voutilainen  <ville.voutilainen@gmail.com>
6587         Implement new C++ intrinsics __is_assignable and __is_constructible.
6588         * c-common.c (__is_assignable, __is_constructible): New.
6589         * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
6591 2017-05-17  Martin Liska  <mliska@suse.cz>
6593         * c-common.h: Introduce dump_flags_t type and
6594         use it instead of int type.
6595         * c-gimplify.c (c_genericize): Likewise.
6596         * c-opts.c: Likewise.
6598 2017-05-17  Marek Polacek  <polacek@redhat.com>
6600         * c-common.c (c_save_expr): Remove.
6601         (c_common_truthvalue_conversion): Remove a call to c_save_expr.
6602         * c-common.h (c_save_expr): Remove declaration.
6604 2017-05-09  Volker Reichelt  <v.reichelt@netcologne.de>
6606         PR c/35441
6607         * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
6608         MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
6609         (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
6610         (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
6611         RDIV_EXPR.
6612         (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
6614 2017-05-09  Marek Polacek  <polacek@redhat.com>
6616         PR c/80525
6617         * c-warn.c (unwrap_c_maybe_const): New.
6618         (warn_logical_operator): Call it.
6620 2017-05-09  Nathan Sidwell  <nathan@acm.org>
6622         * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
6623         * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
6625 2017-05-08  Martin Sebor  <msebor@redhat.com>
6627         PR translation/80280
6628         * c-format.h (struct format_flag_spec): Add new member.
6629         (T89_T): New macro.
6630         * c-format.c (local_tree_type_node): New global.
6631         (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
6632         (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
6633         (strfmon_flag_specs): Likewise.
6634         (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
6635         with distinct quoting properties.
6636         (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
6637         (flag_chars_t::validate): Add argument and handle bad quoting.
6638         (check_format_info_main): Handle quoting problems.
6639         (init_dynamic_diag_info): Simplify.
6641 2017-05-08  Jason Merrill  <jason@redhat.com>
6643         * c-opts.c (c_common_post_options): Update defaults for
6644         flag_abi_version and flag_abi_compat_version.
6646 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
6648         * c-common.c (c_cpp_error): Replace report_diagnostic
6649         with diagnostic_report_diagnostic.
6651 2017-05-04  Martin Sebor  <msebor@redhat.com>
6653         PR translation/80280
6654         * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
6655         (handle_weakref_attribute): Same.
6657 2017-05-03  Nathan Sidwell  <nathan@acm.org>
6659         Canonicalize canonical type hashing
6660         * c-common.c (complete_array_type): Use type_hash_canon.
6662 2017-05-01  Xi Ruoyao  <ryxi@stu.xidian.edu.cn>
6664         PR c++/80038
6665         * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
6666         prototype.
6667         (cilk_install_body_pedigree_operations): Likewise.
6668         * cilk.c (cilk_set_spawn_marker): Mark functions that should be
6669         detatched.
6670         (cilk_gimplify_call_params_in_spawned_fn): Remove.
6671         (cilk_install_body_pedigree_operations): Likewise.
6672         (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
6673         unwrapping.
6675 2017-04-27  Jakub Jelinek  <jakub@redhat.com>
6677         PR c++/80534
6678         * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
6679         flag on non-aggregate element types.
6681 2017-04-25  Bernd Edlinger  <bernd.edlinger@hotmail.de>
6683         * c-common.c (c_type_hasher, type_hash_table): Remove.
6684         (c_common_get_alias_set): Remove unreachable code.
6685         * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
6687 2017-04-20  Volker Reichelt  <v.reichelt@netcologne.de>
6689         * c.opt (Wextra-semi): New C++ warning flag.
6691 2017-04-20  Jakub Jelinek  <jakub@redhat.com>
6693         PR middle-end/80423
6694         * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
6696 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
6698         PR middle-end/79788
6699         PR middle-end/80375
6700         * c-common.c (c_common_type_for_mode): Don't handle
6701         widest_*_literal_type_node here.
6702         c_common_signed_or_unsigned_type): Likewise.
6703         (c_common_nodes_and_builtins): Set widest_*_literal_type_node
6704         to *intTI_type_node or *intDI_type_node depending on whether
6705         TImode is supported by the target or not.
6707 2017-04-10  Martin Liska  <mliska@suse.cz>
6709         PR sanitizer/80350
6710         * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
6711         doing an UBSAN check.
6713 2017-04-03  Jonathan Wakely  <jwakely@redhat.com>
6715         * c-warn.c (do_warn_double_promotion): Fix typo in comment.
6717 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
6719         PR c++/79572
6720         * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
6721         tree *.
6722         * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise.  Handle
6723         not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
6724         REFERENCE_TYPE.
6726 2017-03-31  David Malcolm  <dmalcolm@redhat.com>
6728         PR documentation/78732
6729         * c.opt (Wendif-labels): Fix description to refer to
6730         #else rather than #elif.
6732 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
6734         PR libstdc++/80251
6735         * c-common.h (enum rid): Add RID_IS_AGGREGATE.
6736         * c-common.c (c_common_reswords): Add __is_aggregate trait.
6738 2017-03-27  Jakub Jelinek  <jakub@redhat.com>
6740         PR middle-end/80162
6741         * c-common.c (c_common_mark_addressable_vec): Don't set
6742         TREE_ADDRESSABLE on DECL_HARD_REGISTER.
6744 2017-03-21  Martin Sebor  <msebor@redhat.com>
6746         PR c++/79548
6747         * c-common.c (set_underlying_type): Mark type used only when
6748         original del is declared unused.
6750 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
6752         PR translation/79848
6753         * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
6754         "%qs".
6756 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
6758         PR c/79921
6759         * c-indentation.c (warn_for_misleading_indentation): Remove parens
6760         from inform's message, so that xgettext can locate it.
6762 2017-03-09  Marek Polacek  <polacek@redhat.com>
6764         PR c++/79962
6765         PR c++/79984
6766         * c-attribs.c (handle_nonnull_attribute): Save the result of default
6767         conversion to the attribute list.
6769 2017-03-09  Martin Liska  <mliska@suse.cz>
6771         * c-ada-spec.c (macro_length): Increment value instead of a pointer.
6773 2017-03-03  Jason Merrill  <jason@redhat.com>
6775         * c.opt (Wnoexcept-type): New.
6777 2017-03-02  Richard Biener  <rguenther@suse.de>
6779         PR c/79756
6780         * c-common.c (c_common_mark_addressable_vec): Look through
6781         C_MAYBE_CONST_EXPR.
6783 2017-02-28  Martin Liska  <mliska@suse.cz>
6785         * c.opt: Replace space with tabular for options of <number>
6786         type.
6788 2017-02-28  Martin Liska  <mliska@suse.cz>
6790         * c.opt: Fix --help=option -Q for options which are of
6791         an enum type.
6793 2017-02-24  Jakub Jelinek  <jakub@redhat.com>
6795         PR c++/79588
6796         * c-common.c (check_function_restrict): New function.
6797         (check_function_arguments): Add FNDECL argument.  Call
6798         check_function_restrict if -Wrestrict.
6799         * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
6800         and NARGS.  Use auto_vec for ARG_POSITIONS, simplify.
6801         * c-common.h (check_function_arguments): Add FNDECL argument.
6802         (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
6804 2017-02-24  Eric Botcazou  <ebotcazou@adacore.com>
6806         * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
6807         treatment of parameters with pointer-to-tagged type and tidy up.
6808         (print_ada_methods): Remove the special treatment of C++ static member
6809         functions.
6811 2017-02-22  Martin Liska  <mliska@suse.cz>
6813         * c.opt: Replace inequality signs with square brackets
6814         for -Wnornalized.
6816 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
6818         PR c++/79641
6819         * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
6820         preserve quals.
6822 2017-02-17  Joseph Myers  <joseph@codesourcery.com>
6824         * c-cppbuiltin.c (builtin_define_float_constants): Define
6825         __DECIMAL_DIG__ to the value for long double.
6827 2017-02-15  Marek Polacek  <polacek@redhat.com>
6829         PR c/79515
6830         * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
6831         conversion has occured.
6833 2017-01-24  David Malcolm  <dmalcolm@redhat.com>
6835         * c-common.c (c_common_reswords): Add "__RTL".
6836         * c-common.h (enum rid): Add RID_RTL.
6838 2017-01-20  Marek Polacek  <polacek@redhat.com>
6840         PR c/64279
6841         * c-common.h (do_warn_duplicated_branches_r): Declare.
6842         * c-gimplify.c (c_genericize): Walk the function tree calling
6843         do_warn_duplicated_branches_r.
6844         * c-warn.c (expr_from_macro_expansion_r): New.
6845         (do_warn_duplicated_branches): New.
6846         (do_warn_duplicated_branches_r): New.
6847         * c.opt (Wduplicated-branches): New option.
6849 2017-01-17  David Malcolm  <dmalcolm@redhat.com>
6851         PR c++/71497
6852         * c-indentation.c (warn_for_misleading_indentation): Use the past
6853         subjunctive in the note.
6855 2017-01-17  Aldy Hernandez  <aldyh@redhat.com>
6857         PR c/79116
6858         * array-notation-common.c (cilkplus_extract_an_triplets): Convert
6859         start type to integer_type.
6861 2017-01-16  Jakub Jelinek  <jakub@redhat.com>
6863         PR driver/49726
6864         * c.opt (gen-decls): Add Driver flag.
6866 2017-01-16  Paolo Carlini  <paolo.carlini@oracle.com>
6868         Revert:
6869         2017-01-16  Paolo Carlini  <paolo.carlini@oracle.com>
6871         PR c++/71737
6872         * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
6874 2017-01-16  Paolo Carlini  <paolo.carlini@oracle.com>
6876         PR c++/71737
6877         * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
6879 2017-01-12  Martin Sebor  <msebor@redhat.com>
6881         (-Wformat-overflow): ...to this.
6883 2017-01-11  Martin Sebor  <msebor@redhat.com>
6885         PR c/78768
6886         * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
6887         Also enable for LTO.
6889 2017-01-10  Jason Merrill  <jason@redhat.com>
6891         Implement P0195R2, C++17 variadic using.
6892         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
6894 2017-01-09  Jakub Jelinek  <jakub@redhat.com>
6896         PR translation/79019
6897         PR translation/79020
6898         * c.opt (Wnormalized=): Fix typo in description.
6900 2017-01-08  Martin Sebor  <msebor@redhat.com>
6902         PR middle-end/77708
6903         * c.opt (-Wformat-truncation): New option.
6905 2017-01-06  Alexandre Oliva  <aoliva@redhat.com>
6907         * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
6908         value to unsigned short to fit in 4 hex digits without
6909         warnings.
6911 2017-01-05  Eric Botcazou  <ebotcazou@adacore.com>
6913         * c.opt (fsso-struct): Add 'native' value.
6915 2017-01-05  Martin Liska  <mliska@suse.cz>
6917         PR pch/78970
6918         * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
6919         header.
6921 2017-01-04  Marek Polacek  <polacek@redhat.com>
6923         PR c++/64767
6924         * c.opt (Wpointer-compare): New option.
6926 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
6928         PR driver/78957
6929         * c.opt (fsso-struct=): Add RejectNegative.
6931 2017-01-01  Jakub Jelinek  <jakub@redhat.com>
6933         Update copyright years.
6935 2016-12-29  Martin Liska  <mliska@suse.cz>
6937         PR c/78933
6938         * c.opt (strong-eval-order): Add RejectNegative keyword.
6940 2016-12-22  Jason Merrill  <jason@redhat.com>
6942         Implement P0522R0, matching of template template arguments.
6943         * c-cppbuiltin.c (c_cpp_builtins): Define
6944         __cpp_template_template_args.
6946 2016-12-21  Jakub Jelinek  <jakub@redhat.com>
6948         PR bootstrap/78817
6949         * c-common.c (struct nonnull_arg_ctx): New type.
6950         (check_function_nonnull): Return bool instead of void.  Use
6951         nonnull_arg_ctx as context rather than just location_t.
6952         (check_nonnull_arg): Adjust for the new context type, set
6953         warned_p to true if a warning has been diagnosed.
6954         (check_function_arguments): Return bool instead of void.
6955         * c-common.h (check_function_arguments): Adjust prototype.
6957 2016-12-21  Jason Merrill  <jason@redhat.com>
6959         * c.opt (-fnew-ttp-matching): New flag.
6960         * c-opts.c (c_common_post_options): Default on if -std=c++1z.
6962 2016-12-14  Martin Jambor  <mjambor@suse.cz>
6964         * c-omp.c: Include omp-general.h instead of omp-low.h.
6965         (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
6966         name.
6968 2016-12-14  Martin Sebor  <msebor@redhat.com>
6970         PR c/17308
6971         * c-common.c (check_nonnull_arg): Disable when optimization
6972         is enabled.
6974 2016-12-12  Marek Polacek  <polacek@redhat.com>
6976         PR c++/78647
6977         * c-common.c (attribute_fallthrough_p): Return false for
6978         error_mark_node.
6980 2016-12-08  Martin Sebor  <msebor@redhat.com>
6982         PR c/78284
6983         * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
6985 2016-12-08  Martin Sebor  <msebor@redhat.com>
6987         PR c/78165
6988         * c-pretty-print (pp_c_integer_constant): Avoid formatting type
6989         suffix.
6991 2016-12-07  Martin Sebor  <msebor@redhat.com>
6993         PR c/53562
6994         PR middle-end/77784
6995         PR middle-end/78149
6996         PR middle-end/78138
6997         * c.opt (-Wstringop-overflow): New option.
6999 2016-12-02  Maxim Ostapenko  <m.ostapenko@samsung.com>
7001         * c-attribs.c (asan odr indicator): New attribute.
7002         (handle_asan_odr_indicator_attribute): New function.
7004 2016-11-26  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
7006         * c-common.c (c_common_nodes_and_builtins): Remove initialization of
7007         ptrdiff_type_node;
7009 2016-11-23  James Greenhalgh  <james.greenhalgh@arm.com>
7011         * c-common.c (excess_precision_mode_join): New.
7012         (c_ts18661_flt_eval_method): New.
7013         (c_c11_flt_eval_method): Likewise.
7014         (c_flt_eval_method): Likewise.
7015         * c-common.h (excess_precision_mode_join): New.
7016         (c_flt_eval_method): Likewise.
7017         * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
7018         (cpp_iec_559_value): Call it.
7019         (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
7020         call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
7021         __FLT_EVAL_METHOD_TS_18661_3__.
7023 2016-11-23  James Greenhalgh  <james.greenhalgh@arm.com>
7025         * c-opts.c (c_common_post_options): Add logic to handle the default
7026         case for -fpermitted-flt-eval-methods.
7028 2016-11-23  Paolo Bonzini  <bonzini@gnu.org>
7030         * c.opt (Wexpansion-to-defined): New.
7032 2016-11-23  Jakub Jelinek  <jakub@redhat.com>
7034         PR target/78451
7035         * c-pragma.c (handle_pragma_target): Don't replace
7036         current_target_pragma, but chainon the new args to the current one.
7038 2016-11-22  Nathan Sidwell  <nathan@acm.org>
7040         * array-notation-common.c (cilkplus_extract_an_trplets): Fix
7041         indentation and formatting.
7043 2016-11-21  Martin Sebor  <msebor@redhat.com>
7045         * c.opt (-fprintf-return-value): Enable by default.
7047 2016-11-21  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7049         PR c++/71973
7050         * c.opt (-Wbuiltin-declaration-mismatch): New warning.
7051         * c-common.c (c_common_nodes_and_builtins): Initialize
7052         const_tm_ptr_type_node.
7054 2016-11-16  Marek Polacek  <polacek@redhat.com>
7056         PR c/78285
7057         * c-common.c (c_add_case_label): Turn error_at calls into inform.
7059 2016-11-14  Jakub Jelinek  <jakub@redhat.com>
7061         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
7063 2016-11-14  Prasad Ghangal  <prasad.ghangal@gmail.com>
7064             Richard Biener  <rguenther@suse.de>
7066         * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
7067         * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
7068         * c.opt (fgimple): New option.
7070 2016-11-13  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
7072         PR c/35503
7073         * c-common.h (warn_for_restrict): Declare.
7074         * c-warn.c: Include gcc-rich-location.h.
7075         (warn_for_restrict): New function.
7076         * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
7077         (gcc_cdiag_char_table): Likewise.
7078         (gcc_cxxdiag_char_table): Likewise.
7079         * c.opt (Wrestrict): New option.
7081 2016-11-13  Eric Botcazou  <ebotcazou@adacore.com>
7083         * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
7084         for nested types only if the type is a record or union and dump SLOC.
7086 2016-11-09  Jason Merrill  <jason@redhat.com>
7088         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
7090 2016-11-09  Jakub Jelinek  <jakub@redhat.com>
7092         * c-ubsan.c (ubsan_instrument_shift): Handle split
7093         -fsanitize=shift-base and -fsanitize=shift-exponent.
7095 2016-11-07  Jason Merrill  <jason@redhat.com>
7097         * c.opt (Wc++1z-compat): New.
7098         * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
7100 2016-11-07  Martin Liska  <mliska@suse.cz>
7102         * c-warn.c (warn_for_unused_label): Save all labels used
7103         in goto or in &label.
7105 2016-11-03  Jason Merrill  <jason@redhat.com>
7107         * c-cppbuiltin.c (c_cpp_builtins): Correct
7108         __cpp_inheriting_constructors.
7110 2016-11-01  Jason Merrill  <jason@redhat.com>
7112         * c-cppbuiltin.c (c_cpp_builtins): Update
7113         __cpp_inheriting_constructors.
7115         * c.opt (-fnew-inheriting-ctors): New.
7116         * c-opts.c: Default to on for ABI 11+.
7118 2016-10-31  Jakub Jelinek  <jakub@redhat.com>
7120         PR c++/77948
7121         * c.opt (fext-numeric-literals): Add Var and Init.
7122         * c-opts.c (c_common_handle_option): Don't clear
7123         cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
7124         (c_common_post_options): Clear it here if not set
7125         explicitly.
7127 2016-10-28  Aldy Hernandez  <aldyh@redhat.com>
7129         PR debug/77773
7130         * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
7131         if NULL.
7133 2016-10-25  Jakub Jelinek  <jakub@redhat.com>
7135         * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
7136         * c-common.c (c_common_reswords): Add __builtin_launder.
7138 2016-10-24  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7140         * c-common.c (c_common_truthvalue_conversion): Warn for
7141         multiplications in boolean context.  Fix the quoting of '<<' and '<'
7142         in the shift warning.
7144 2016-10-20  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7146         * c-common.c (c_common_truthvalue_conversion): Fix the comment.
7148 2016-10-20  Jason Merrill  <jason@redhat.com>
7150         * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
7152 2016-10-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7154         * c-common.c (c_common_truthvalue_conversion): Warn only for signed
7155         integer shift ops in boolean context.
7157 2016-10-18  Aldy Hernandez  <aldyh@redhat.com>
7159         * c.opt (Walloca): New.
7160         (Walloca-larger-than=): New.
7161         (Wvla-larger-than=): New.
7163 2016-10-17  Marek Polacek  <polacek@redhat.com>
7165         * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
7166         Return immediately when finding a match.
7167         (warn_tautological_cmp): Remove a boolean variable that is no longer
7168         needed.
7170 2016-10-17  Marek Polacek  <polacek@redhat.com>
7172         * c-attribs.c: New file.
7173         * c-common.c: Move attributes handling to c-attribs.c.
7174         (get_nonnull_operand): No longer static.
7175         * c-common.h: Move the declarations from c-attribs.c to its own section.
7177 2016-10-14  Jason Merrill  <jason@redhat.com>
7179         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
7180         and __cpp_deduction_guides.
7182 2016-10-13  Jason Merrill  <jason@redhat.com>
7184         * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
7186 2016-10-13  Thomas Preud'homme  <thomas.preudhomme@arm.com>
7188         * c-cppbuiltin.c: Include memmodel.h.
7189         * c-opts.c: Likewise.
7190         * c-pragma.c: Likewise.
7191         * c-warn.c: Likewise.
7193 2016-10-12  Jakub Jelinek  <jakub@redhat.com>
7195         * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
7196         (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
7197         * c-opts.c (sanitize_cpp_opts): Initialize
7198         cpp_opts->cpp_warn_implicit_fallthrough.
7200 2016-10-11  Marek Polacek  <polacek@redhat.com>
7202         * c-common.c (warning_candidate_p): Change the return type to bool
7203         and return true/false instead of 1/0.
7204         (vector_mode_valid_p): Likewise.
7206 2016-10-11  Marek Polacek  <polacek@redhat.com>
7208         * c-common.c (fold_for_warn): No longer static.
7209         (bool_promoted_to_int_p): Likewise.
7210         (c_common_get_narrower): Likewise.
7211         (constant_expression_warning): Move to c-warn.c.
7212         (constant_expression_error): Likewise.
7213         (overflow_warning): Likewise.
7214         (warn_logical_operator): Likewise.
7215         (find_array_ref_with_const_idx_r): Likewise.
7216         (warn_tautological_cmp): Likewise.
7217         (expr_has_boolean_operands_p): Likewise.
7218         (warn_logical_not_parentheses): Likewise.
7219         (warn_if_unused_value): Likewise.
7220         (strict_aliasing_warning): Likewise.
7221         (sizeof_pointer_memaccess_warning): Likewise.
7222         (check_main_parameter_types): Likewise.
7223         (conversion_warning): Likewise.
7224         (warnings_for_convert_and_check): Likewise.
7225         (match_case_to_enum_1): Likewise.
7226         (match_case_to_enum): Likewise.
7227         (c_do_switch_warnings): Likewise.
7228         (warn_for_omitted_condop): Likewise.
7229         (readonly_error): Likewise.
7230         (lvalue_error): Likewise.
7231         (invalid_indirection_error): Likewise.
7232         (warn_array_subscript_with_type_char): Likewise.
7233         (warn_about_parentheses): Likewise.
7234         (warn_for_unused_label): Likewise.
7235         (warn_for_div_by_zero): Likewise.
7236         (warn_for_memset): Likewise.
7237         (warn_for_sign_compare): Likewise.
7238         (do_warn_double_promotion): Likewise.
7239         (do_warn_unused_parameter): Likewise.
7240         (record_locally_defined_typedef): Likewise.
7241         (maybe_record_typedef_use): Likewise.
7242         (maybe_warn_unused_local_typedefs): Likewise.
7243         (maybe_warn_bool_compare): Likewise.
7244         (maybe_warn_shift_overflow): Likewise.
7245         (warn_duplicated_cond_add_or_warn): Likewise.
7246         (diagnose_mismatched_attributes): Likewise.
7247         * c-common.h: Move the declarations from c-warn.c to its own section.
7248         * c-warn.c: New file.
7250 2016-10-08  Jason Merrill  <jason@redhat.com>
7252         * c-common.c (c_common_truthvalue_conversion): Don't distribute
7253         into COND_EXPR in C++.
7255 2016-10-08  Jakub Jelinek  <jakub@redhat.com>
7257         * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
7258         token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
7259         CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
7261 2016-10-07  Jakub Jelinek  <jakub@redhat.com>
7263         Implement LWG2296 helper intrinsic
7264         * c-common.h (enum rid): Add RID_ADDRESSOF.
7265         * c-common.c (c_common_reswords): Add __builtin_addressof.
7267 2016-10-07  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7269         PR c++/77700
7270         * c-common.c (c_common_truthvalue_conversion): Warn also for
7271         suspicious enum values in boolean context.
7273 2016-10-06  Jakub Jelinek  <jakub@redhat.com>
7275         Implement P0258R2 - helper for C++17
7276         std::has_unique_object_representations trait
7277         * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
7278         * c-common.c (c_common_reswords): Add
7279         __has_unique_object_representations.
7281 2016-10-05  Jakub Jelinek  <jakub@redhat.com>
7283         PR sanitizer/66343
7284         * c-ubsan.c (ubsan_instrument_return): Don't call
7285         initialize_sanitizer_builtins here.
7287 2016-10-05  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7289         * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
7290         conditional expression in boolean context when only one arm is
7291         non-boolean.
7293 2016-10-05  Jakub Jelinek  <jakub@redhat.com>
7295         PR sanitizer/77823
7296         * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
7297         is not integral.
7299         * c-common.c (c_common_reswords): Update comment for C++11.
7301 2016-10-04  Jason Merrill  <jason@redhat.com>
7303         * c-common.c (make_tree_vector_from_ctor): New.
7304         * c-common.h: Declare it.
7306 2016-10-04  Jakub Jelinek  <jakub@redhat.com>
7308         * c-cppbuiltin.c (c_cpp_builtins): Don't define
7309         __LIBGCC_JCR_SECTION_NAME__.
7311 2016-10-03  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7313         * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
7314         left shift in boolean context.
7316 2016-09-29  Jakub Jelinek  <jakub@redhat.com>
7318         Implement P0001R1 - C++17 removal of register storage class specifier
7319         * c.opt (Wregister): New warning.
7320         * c-opts.c (c_common_post_options): Enable -Wregister by
7321         default for C++17.
7323 2016-09-29  James Greenhalgh  <james.greenhalgh@arm.com>
7325         * c-opts.c (c_common_post_options): Remove special case for
7326         TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
7327         in C++.
7329 2016-09-27  Jakub Jelinek  <jakub@redhat.com>
7331         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
7332         -std=c++1z.
7334         * c-ada-spec.c (print_ada_declaration): Remove break after return.
7336 2016-09-26  Thomas Preud'homme  <thomas.preudhomme@arm.com>
7338         * c-common.c: Include memmodel.h.
7340 2016-09-26  Marek Polacek  <polacek@redhat.com>
7342         * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
7344 2016-09-26  Marek Polacek  <polacek@redhat.com>
7346         PR c/7652
7347         * c-common.c (c_common_attribute_table): Add fallthrough attribute.
7348         (handle_fallthrough_attribute): New function.
7349         (attribute_fallthrough_p): New function.
7350         * c-common.h (attribute_fallthrough_p): Declare.
7352 2016-09-24  Marek Polacek  <polacek@redhat.com>
7354         PR c/77490
7355         * c.opt (Wbool-operation): New.
7357 2016-09-21  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7359         * c-common.c (c_common_truthvalue_conversion): Inhibit
7360         Wint-in-bool-context warning with from_macro_definition_at.
7361         Mention the expression will always evaluate to true.
7363 2016-09-21  Martin Sebor  <msebor@redhat.com>
7365         PR bootstrap/77676
7366         * c.opt (fprintf-return-value): Temporarily initialize to zero
7367         to unblock bootstrap failures.
7369 2016-09-21  Jakub Jelinek  <jakub@redhat.com>
7371         PR c++/77651
7372         * c.opt (Waligned-new=): Add RejectNegative.
7373         (faligned-new=): Likewise.  Spelling fix - change
7374         aligned_new_threshhold to aligned_new_threshold.
7375         * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
7376         to aligned_new_threshold.
7378 2016-09-20  Martin Sebor  <msebor@redhat.com>
7380         PR middle-end/49905
7381         * c.opt: Add -Wformat-length and -fprintf-return-value.
7383 2016-09-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7385         PR c++/77434
7386         * c.opt (Wint-in-bool-context): New warning.
7387         * c-common.c (c_common_truthvalue_conversion): Warn on integer
7388         constants in boolean context.
7390 2016-09-19  Joseph Myers  <joseph@codesourcery.com>
7392         * c-common.c (max_align_t_align): Also consider alignment of
7393         float128_type_node.
7395 2016-09-15  Jason Merrill  <jason@redhat.com>
7397         * c-common.c (check_cxx_fundamental_alignment_constraints): Check
7398         DECL_EXTERNAL.
7400 2016-09-14  Jason Merrill  <jason@redhat.com>
7402         * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
7403         limit FIELD_DECL, either.
7405 2016-09-14  Marek Polacek  <polacek@redhat.com>
7407         * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
7408         * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
7409         * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
7411 2016-09-13  David Malcolm  <dmalcolm@redhat.com>
7413         * c-common.c (warn_logical_not_parentheses): Replace
7414         rich_location::add_fixit_insert calls with add_fixit_insert_before
7415         and add_fixit_insert_after, eliminating the "next_loc" calculation.
7417 2016-09-13  Jason Merrill  <jason@redhat.com>
7418             Tom de Vries  <tom@codesourcery.com>
7420         PR c++/77427
7421         * c-common.c (set_underlying_type): Don't treat array as builtin type.
7423 2016-09-13  Jason Merrill  <jason@redhat.com>
7425         * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
7426         limit types at all.
7428 2016-09-12  Jason Merrill  <jason@redhat.com>
7430         * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
7431         bit/byte confusion, allow large alignment for types.
7433 2016-09-12  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7435         PR c++/77496
7436         * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
7438 2016-09-12  David Malcolm  <dmalcolm@redhat.com>
7440         PR c/72858
7441         * c-format.c (argument_parser::check_argument_type): Add params
7442         "type_start" and "conversion_char".  Use the former to generate
7443         offset_to_type_start and pass it and conversion_char to
7444         check_format_types.
7445         (check_format_info_main): Capture the start of the type
7446         information as "type_start", and pass it an format_char
7447         to arg_parser.check_argument_type.
7448         (check_format_types): Provide an example in the leading comment.
7449         Add params "offset_to_type_start" and "conversion_char"; pass
7450         them to format_type_warning calls.
7451         (test_get_modifier_for_format_len): Likewise.
7452         (matching_type_p): New function.
7453         (get_format_for_type): Add param "conversion_char" and move
7454         implementation into...
7455         (get_format_for_type_1): ...new function, called twice.
7456         Use new function matching_type_p rather than checking for
7457         TYPE_CANONICAL equality.
7458         (get_corrected_substring): New function.
7459         (format_type_warning): Provide an example in the leading comment.
7460         Add params "offset_to_type_start" and "conversion_char".  Replace
7461         call to get_format_for_type with call to get_corrected_substring
7462         and move rejection of hints for widths/precisions there.
7463         (assert_format_for_type_streq): Add param "conversion_char".
7464         (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
7465         (test_get_format_for_type_printf): Add conversion chars to the
7466         tests, adding coverage for various combinations of integer
7467         vs double conversions, and for preserving octal and hexadecimal
7468         conversions.
7469         (test_get_format_for_type_scanf): Add conversion chars to the
7470         tests.
7472 2016-09-10  Tom de Vries  <tom@codesourcery.com>
7474         PR C/71602
7475         * c-common.c (build_va_arg): Handle more strict
7476         targetm.canonical_va_list_type.  Replace first argument type error with
7477         assert.
7479 2016-09-09  Martin Sebor  <msebor@redhat.com>
7481         PR c/77520
7482         PR c/77521
7483         * c-format.c (argument_parser::find_format_char_info): Use %qc
7484         format directive unconditionally.
7486 2016-09-09  Jason Merrill  <jason@redhat.com>
7488         Implement C++17 new of over-aligned types.
7489         * c.opt: Add -faligned-new and -Waligned-new.
7490         * c-common.c (max_align_t_align): Split out from...
7491         (cxx_fundamental_alignment_p): ...here.
7492         * c-common.h: Declare it.
7493         * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
7495 2016-09-09  Joseph Myers  <joseph@codesourcery.com>
7497         * c-cppbuiltin.c (builtin_define_type_width): New function.
7498         (builtin_define_stdint_macros, c_cpp_builtins): Define type width
7499         macros.
7501 2016-09-07  David Malcolm  <dmalcolm@redhat.com>
7503         * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
7504         a POINTER_TYPE.
7505         (substring_loc::get_location): Move to substring-locations.c,
7506         keeping implementation as...
7507         (c_get_substring_location): New function, from the above, reworked
7508         to use accessors rather than member lookup.
7509         * c-common.h (class substring_loc): Move to substring-locations.h,
7510         replacing with a forward decl.
7511         (c_get_substring_location): New decl.
7512         * c-format.c: Include "substring-locations.h".
7513         (format_warning_va): Move to substring-locations.c.
7514         (format_warning_at_substring): Likewise.
7516 2016-09-06  Martin Sebor  <msebor@redhat.com>
7518         PR c/77336
7519         * c-format.c (check_function_format): Avoid issuing warnings for
7520         functions unless they call format functions with non-constant
7521         format strings.
7523 2016-09-06  Richard Biener  <rguenther@suse.de>
7525         PR c/77450
7526         * c-common.c (c_common_mark_addressable_vec): Handle
7527         COMPOUND_LITERAL_EXPR.
7529 2016-09-05  Marek Polacek  <polacek@redhat.com>
7531         PR c/77423
7532         * c-common.c (bool_promoted_to_int_p): New function.
7533         (expr_has_boolean_operands_p): New function.
7534         (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
7535         (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
7537 2016-09-04  Tom de Vries  <tom@codesourcery.com>
7539         revert:
7540         2016-08-29  Tom de Vries  <tom@codesourcery.com>
7542         * c-common.c (build_va_arg): Replace first argument type error
7543         with assert.
7545 2016-09-02  Jakub Jelinek  <jakub@redhat.com>
7547         PR c/65467
7548         * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
7549         (c_finish_omp_for): Reject _Atomic qualified iterators.
7551 2016-09-01  Martin Sebor  <msebor@redhat.com>
7553         * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
7554         size to guarantee it fits the output of the formatted function
7555         regardless of its arguments.
7557 2016-09-01  Marek Polacek  <polacek@redhat.com>
7559         PR c/7652
7560         * c-common.c (resolve_overloaded_builtin): Fix formatting.  Add
7561         FALLTHRU comments.
7563 2016-08-29  Marek Polacek  <polacek@redhat.com>
7565         PR c/77292
7566         * c-common.c (warn_logical_not_parentheses): Don't warn for
7567         a comparison or a logical operator.
7569 2016-08-29  Tom de Vries  <tom@codesourcery.com>
7571         * c-common.c (build_va_arg): Fix type comparison assert.
7573 2016-08-29  Tom de Vries  <tom@codesourcery.com>
7575         * c-common.c (build_va_arg): Replace first argument type error
7576         with assert.
7578 2016-08-29  Tom de Vries  <tom@codesourcery.com>
7580         PR c/77398
7581         * c-common.c (build_va_arg): Add first argument error.  Build va_arg
7582         with error_mark_node as va_list instead of with illegal va_list.
7584 2016-08-25  Marek Polacek  <polacek@redhat.com>
7585             David Malcolm  <dmalcolm@redhat.com>
7587         * c-common.c (warn_logical_not_parentheses): Print fixit hints.
7588         * c-common.h (warn_logical_not_parentheses): Update declaration.
7590 2016-08-22  Marek Polacek  <polacek@redhat.com>
7592         PR c++/77321
7593         * c-common.c (warn_for_memset): Check type for null.
7595 2016-08-22  Joseph Myers  <joseph@codesourcery.com>
7597         * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
7598         _FloatNx types for suffixes for built-in functions.
7600 2016-08-19  Joseph Myers  <joseph@codesourcery.com>
7602         PR c/32187
7603         * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
7604         (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
7605         (RID_FLOAT128X): New enum rid values.
7606         (CASE_RID_FLOATN_NX): New macro.
7607         * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
7608         keywords.
7609         (c_common_type_for_mode): Check for _FloatN and _FloatNx and
7610         corresponding complex types.
7611         (c_common_nodes_and_builtins): For non-C++, register _FloatN and
7612         _FloatNx and corresponding complex types.
7613         (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
7614         * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
7615         and _FloatNx types for the widest type for determining
7616         DECIMAL_DIG.  Define __LDBL_DECIMAL_DIG__ as well as
7617         __DECIMAL_DIG__ for long double.  Handle FMA_SUFFIX being NULL.
7618         (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
7619         and _FloatNx types.
7620         * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
7621         constants.
7622         * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
7623         _FloatNx types.
7625 2016-08-18  David Malcolm  <dmalcolm@redhat.com>
7627         * c-opts.c (c_diagnostic_finalizer): Update for change to
7628         diagnostic_show_locus.
7630 2016-08-18  David Malcolm  <dmalcolm@redhat.com>
7632         * c-common.c: Include "spellcheck.h".
7633         (cb_get_suggestion): New function.
7634         * c-common.h (cb_get_suggestion): New decl.
7635         * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
7636         cb_get_suggestion.
7638 2016-08-18  Marek Polacek  <polacek@redhat.com>
7640         PR c/71514
7641         * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
7642         and pointer-to-VLA.
7644 2016-08-16  David Malcolm  <dmalcolm@redhat.com>
7646         PR c/72857
7647         * c-common.c (substring_loc::get_range): Rename to...
7648         (substring_loc::get_location): ...this, converting param from a
7649         source_range * to a location_t *.  Call
7650         get_source_location_for_substring rather than
7651         get_source_range_for_substring, and pass in m_caret_idx.
7652         * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
7653         (substring_loc::get_range): Replace with...
7654         (substring_loc::get_location): ...this.
7655         (substring_loc::set_caret_index): New method.
7656         (substring_loc): Add field m_caret_idx.
7657         * c-format.c (format_warning_va): Update for above changes.
7658         Rename local "substring_loc" to "fmt_substring_loc" to avoid
7659         clashing with type name.
7660         (format_warning_at_char): Add caret_idx param to substring_loc ctor.
7661         (check_argument_type): Likewise.
7662         (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
7663         Use a copy when emitting warnings, setting the caret index from TYPE.
7665 2016-08-16  Eric Botcazou  <ebotcazou@adacore.com>
7666             Arnaud Charlet  <charlet@adacore.com>
7668         * c-ada-spec.c (dump_number): New function.
7669         (handle_escape_character): Likewise.
7670         (print_ada_macros): Add handling of constant integers and strings.
7672 2016-08-12  Marek Polacek  <polacek@redhat.com>
7674         PR c/7652
7675         * c-common.c (scalar_to_vector): Adjust fall through comment.
7676         * c-opts.c (c_common_handle_option): Likewise.
7677         * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
7678         * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
7679         fall through comment.
7680         * cilk.c (extract_free_variables): Add FALLTHRU.
7682 2016-08-10  Jason Merrill  <jason@redhat.com>
7684         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
7686 2016-08-09  Jason Merrill  <jason@redhat.com>
7688         * c-common.c (c_common_attribute_table): vector_size affects type
7689         identity.
7691 2016-08-09  Marek Polacek  <polacek@redhat.com>
7693         PR c/7652
7694         * c-ada-spec.c (dump_generic_ada_node): Add return.
7696 2016-08-09  Jason Merrill  <jason@redhat.com>
7698         * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
7699         C++17 constexpr lambdas.
7701 2016-08-08  David Malcolm  <dmalcolm@redhat.com>
7703         PR c/64955
7704         * c-common.h (selftest::c_format_c_tests): New declaration.
7705         (selftest::run_c_tests): New declaration.
7706         * c-format.c: Include "selftest.h.
7707         (format_warning_va): Add param "corrected_substring" and use
7708         it to add a replacement fix-it hint.
7709         (format_warning_at_substring): Likewise.
7710         (format_warning_at_char): Update for new param of
7711         format_warning_va.
7712         (argument_parser::check_argument_type): Pass "fki" to
7713         check_format_types.
7714         (check_format_types): Add param "fki" and pass it to
7715         format_type_warning.
7716         (deref_n_times): New function.
7717         (get_modifier_for_format_len): New function.
7718         (selftest::test_get_modifier_for_format_len): New function.
7719         (get_format_for_type): New function.
7720         (format_type_warning): Add param "fki" and use it to attempt
7721         to provide hints for argument types when calling
7722         format_warning_at_substring.
7723         (selftest::get_info): New function.
7724         (selftest::assert_format_for_type_streq): New function.
7725         (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
7726         (selftest::test_get_format_for_type_printf): New function.
7727         (selftest::test_get_format_for_type_scanf): New function.
7728         (selftest::c_format_c_tests): New function.
7730 2016-08-08  David Malcolm  <dmalcolm@redhat.com>
7732         PR c/52952
7733         * c-format.c: Include "diagnostic.h".
7734         (location_column_from_byte_offset): Delete.
7735         (location_from_offset): Delete.
7736         (format_warning_va): New function.
7737         (format_warning_at_substring): New function.
7738         (format_warning_at_char): New function.
7739         (check_format_arg): Capture location of format_tree and pass to
7740         check_format_info_main.
7741         (argument_parser): Add fields "start_of_this_format" and
7742         "format_string_cst".
7743         (flag_chars_t::validate): Add param "format_string_cst".  Convert
7744         warning_at call using location_from_offset to call to
7745         format_warning_at_char.
7746         (argument_parser::argument_parser): Add param "format_string_cst_"
7747         and use use it to initialize field "format_string_cst".
7748         Initialize new field "start_of_this_format".
7749         (argument_parser::read_format_flags): Convert warning_at call
7750         using location_from_offset to a call to format_warning_at_char.
7751         (argument_parser::read_any_format_left_precision): Likewise.
7752         (argument_parser::read_any_format_precision): Likewise.
7753         (argument_parser::read_any_other_modifier): Likewise.
7754         (argument_parser::find_format_char_info): Likewise, in three places.
7755         (argument_parser::parse_any_scan_set): Likewise, in one place.
7756         (argument_parser::handle_conversions): Likewise, in two places.
7757         (argument_parser::check_argument_type): Add param "fmt_param_loc"
7758         and use it to make a substring_loc.  Pass the latter to
7759         check_format_types.
7760         (check_format_info_main): Add params "fmt_param_loc" and
7761         "format_string_cst".  Convert warning_at calls using
7762         location_from_offset to calls to format_warning_at_char.  Pass the
7763         new params to the arg_parser ctor.  Pass "format_string_cst" to
7764         flag_chars.validate.  Pass "fmt_param_loc" to
7765         arg_parser.check_argument_type.
7766         (check_format_types): Convert first param from a location_t
7767         to a const substring_loc & and rename to "fmt_loc".  Attempt
7768         to extract the range of the relevant parameter and pass it
7769         to format_type_warning.
7770         (format_type_warning): Convert first param from a location_t
7771         to a const substring_loc & and rename to "fmt_loc".  Add
7772         params "param_range" and "type".  Replace calls to warning_at
7773         with calls to format_warning_at_substring.
7775 2016-08-08  David Malcolm  <dmalcolm@redhat.com>
7777         * c-format.c (class flag_chars_t): New class.
7778         (struct length_modifier): New struct.
7779         (class argument_parser): New class.
7780         (flag_chars_t::flag_chars_t): New ctor.
7781         (flag_chars_t::has_char_p): New method.
7782         (flag_chars_t::add_char): New method.
7783         (flag_chars_t::validate): New method.
7784         (flag_chars_t::get_alloc_flag): New method.
7785         (flag_chars_t::assignment_suppression_p): New method.
7786         (argument_parser::argument_parser): New ctor.
7787         (argument_parser::read_any_dollar): New method.
7788         (argument_parser::read_format_flags): New method.
7789         (argument_parser::read_any_format_width): New method.
7790         (argument_parser::read_any_format_left_precision): New method.
7791         (argument_parser::read_any_format_precision): New method.
7792         (argument_parser::handle_alloc_chars): New method.
7793         (argument_parser::read_any_length_modifier): New method.
7794         (argument_parser::read_any_other_modifier): New method.
7795         (argument_parser::find_format_char_info): New method.
7796         (argument_parser::validate_flag_pairs): New method.
7797         (argument_parser::give_y2k_warnings): New method.
7798         (argument_parser::parse_any_scan_set): New method.
7799         (argument_parser::handle_conversions): New method.
7800         (argument_parser::check_argument_type): New method.
7801         (check_format_info_main): Introduce classes argument_parser
7802         and flag_chars_t, moving the code within the loop into methods
7803         of these classes.  Make various locals "const".
7805 2016-08-05  David Malcolm  <dmalcolm@redhat.com>
7807         * c-common.c: Include "substring-locations.h".
7808         (get_cpp_ttype_from_string_type): New function.
7809         (g_string_concat_db): New global.
7810         (substring_loc::get_range): New method.
7811         * c-common.h (g_string_concat_db): New declaration.
7812         (class substring_loc): New class.
7813         * c-lex.c (lex_string): When concatenating strings, capture the
7814         locations of all tokens using a new obstack, and record the
7815         concatenation locations within g_string_concat_db.
7816         * c-opts.c (c_common_init_options): Construct g_string_concat_db
7817         on the ggc-heap.
7819 2016-07-29  Marek Polacek  <polacek@redhat.com>
7821         PR c/71926
7822         * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
7823         parentheses warning.
7825         PR c/71574
7826         * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
7828 2016-07-28  Martin Liska  <mliska@suse.cz>
7830         PR gcov-profile/68025
7831         * c-common.c (handle_no_profile_instrument_function_attribute):
7833 2016-07-27  Bernd Edlinger  <bernd.edlinger@hotmail.de>
7835         * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
7836         BITS_PER_UNIT_LOG.
7838 2016-07-25  Jason Merrill  <jason@redhat.com>
7840         PR c++/65970
7841         * c.opt (fconstexpr-loop-limit): New.
7843 2016-07-22  Martin Sebor  <msebor@redhat.com>
7845         PR c++/71675
7846         * c-common.c (resolve_overloaded_builtin): Avoid converting
7847         __atomic_compare_exchange_n return type to that of what its
7848         first argument points to.
7850 2016-07-22  Uros Bizjak  <ubizjak@gmail.com>
7852         * c-common.c: Use HOST_WIDE_INT_M1U instead of
7853         ~(unsigned HOST_WIDE_INT) 0.
7855 2016-07-22  Martin Liska  <mliska@suse.cz>
7857         PR gcov-profile/69028
7858         PR gcov-profile/62047
7859         * cilk.c (create_cilk_helper_decl): Set location of a new decl
7860         to the current_function_decl.
7862 2016-07-21  Jason Merrill  <jason@redhat.com>
7864         PR c++/65168
7865         * c-common.c (c_common_truthvalue_conversion): Check
7866         c_inhibit_evaluation_warnings for warning about address of
7867         reference.
7869 2016-07-20  David Malcolm  <dmalcolm@redhat.com>
7871         * c-common.h (lookup_name_fuzzy): Convert return type from tree to
7872         const char *.
7874 2016-07-15  Jason Merrill  <jason@redhat.com>
7876         * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
7878 2016-07-15  Jakub Jelinek  <jakub@redhat.com>
7880         PR c/71858
7881         * c-common.h (enum lookup_name_fuzzy_kind): Add
7882         FUZZY_LOOKUP_FUNCTION_NAME.
7884 2016-07-08  Jason Merrill  <jason@redhat.com>
7886         P0145: Refining Expression Order for C++.
7887         * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
7888         * c-opts.c: Adjust.
7890 2016-07-05  Markus Trippelsdorf  <markus@trippelsdorf.de>
7892         PR c++/71214
7893         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
7895 2016-06-29  Thomas Schwinge  <thomas@codesourcery.com>
7897         * c-pragma.h (enum pragma_kind): Rename
7898         PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE.  Adjust all
7899         users.
7901 2016-06-29  Richard Biener  <rguenther@suse.de>
7903         PR middle-end/71002
7904         * c-common.c (c_common_get_alias_set): Remove union type punning case.
7906 2016-06-24  Jason Merrill  <jason@redhat.com>
7908         P0145R2: Refining Expression Order for C++.
7909         * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
7910         MODIFY_EXPR.
7912 2016-06-24  Jakub Jelinek  <jakub@redhat.com>
7914         * c-common.c (check_builtin_function_arguments): Require last
7915         argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
7916         Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
7917         if the last argument is pointer to enumerated or boolean type.
7919 2016-06-22  David Malcolm  <dmalcolm@redhat.com>
7921         PR c/70339
7922         * c-common.h (enum lookup_name_fuzzy_kind): New enum.
7923         (lookup_name_fuzzy): New prototype.
7925 2016-06-21  John David Anglin  <danglin@gcc.gnu.org>
7927         * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
7929 2016-06-14  Jason Merrill  <jason@redhat.com>
7931         P0145R2: Refining Expression Order for C++.
7932         * c.opt (fargs-in-order): New.
7933         * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
7935 2016-06-13  Jakub Jelinek  <jakub@redhat.com>
7937         PR sanitizer/71498
7938         * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
7939         all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
7941         PR preprocessor/71183
7942         * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
7943         to cb_get_source_date_epoch.
7945 2016-06-10  Jakub Jelinek  <jakub@redhat.com>
7947         PR c/68657
7948         * c.opt (Wpsabi): Add Warning flag.
7950 2016-06-10  Martin Sebor  <msebor@redhat.com>
7952         PR c/71392
7953         * c-common.c (handle_nonnull_attribute): Accept
7954         the nonnull attribute in type-generic builtins.
7956 2016-06-09  Martin Sebor  <msebor@redhat.com>
7958         PR c/70883
7959         * c-common.c (builtin_function_validate_nargs): Make text of error
7960         message consistent with others like it.
7962 2016-06-08  Martin Sebor  <msebor@redhat.com>
7963             Jakub Jelinek  <jakub@redhat.com>
7965         PR c++/70507
7966         PR c/68120
7967         * c-common.c (check_builtin_function_arguments): Handle
7968         BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
7970 2016-06-08  Richard Biener  <rguenther@suse.de>
7972         * c-common.c (parse_optimize_options): Improve diagnostic messages.
7974 2016-06-07  Richard Biener  <rguenther@suse.de>
7976         PR c/61564
7977         * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
7978         options and warn about others.
7980 2016-06-01  Eduard Sanou  <dhole@openmailbox.org>
7982         * c-common.c (get_source_date_epoch): Rename to
7983         cb_get_source_date_epoch.
7984         * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
7985         message when the parsing fails.  Use error_at instead of fatal_error.
7986         * c-common.h (get_source_date_epoch): Rename to
7987         cb_get_source_date_epoch.
7988         * c-common.h (cb_get_source_date_epoch): Prototype.
7989         * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
7990         * c-common.h (c_omp_region_type): Remove trailing comma.
7991         * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
7992         * c-lex.c (c_lex_with_flags): Remove initialization of
7993         pfile->source_date_epoch.
7995 2016-05-30  Jakub Jelinek  <jakub@redhat.com>
7997         PR c++/71349
7998         * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
7999         C_OMP_CLAUSE_SPLIT_TARGET.  Put OMP_CLAUSE_NOWAIT to
8000         C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
8001         instead of C_OMP_CLAUSE_SPLIT_FOR.
8003 2016-05-24  Richard Biener  <rguenther@suse.de>
8005         PR middle-end/70434
8006         PR c/69504
8007         * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
8008         (convert_vector_to_array_for_subscript): ... this.
8009         * c-common.c (convert_vector_to_pointer_for_subscript): Use a
8010         VIEW_CONVERT_EXPR to an array type.  Rename to ...
8011         (convert_vector_to_array_for_subscript): ... this.
8013 2016-05-12  Marek Polacek  <polacek@redhat.com>
8015         PR c/70756
8016         * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
8017         size_in_bytes and pass LOC to it.
8019 2016-05-11  Mikhail Maltsev  <maltsevm@gmail.com>
8021         PR c/43651
8022         * c.opt (Wduplicate-decl-specifier): New option.
8024 2016-05-11  Marek Polacek  <polacek@redhat.com>
8026         PR c++/71024
8027         * c-common.c (diagnose_mismatched_attributes): New function.
8028         * c-common.h (diagnose_mismatched_attributes): Declare.
8030 2016-05-04  Marek Polacek  <polacek@redhat.com>
8032         * c.opt (Wdangling-else): New option.
8034 2016-05-03  Marek Polacek  <polacek@redhat.com>
8036         PR c/70859
8037         * c-common.c (builtin_function_validate_nargs): Add location
8038         parameter.  Use it.
8039         (check_builtin_function_arguments): Add location and arguments
8040         parameters.  Use them.
8041         * c-common.h (check_builtin_function_arguments): Update declaration.
8043 2016-05-03  Richard Biener  <rguenther@suse.de>
8045         * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
8046         allow call args to gimplify to SSA names.
8048 2016-05-03  Marek Polacek  <polacek@redhat.com>
8050         * c-common.h (enum c_omp_region_type): Remove stray comma.
8052 2016-05-02  Cesar Philippidis  <cesar@codesourcery.com>
8054         * c-common.h (enum c_omp_region_type): Define.
8056 2016-05-02  Richard Sandiford  <richard.sandiford@arm.com>
8058         * c-common.c (shorten_compare): Use wi::to_wide.
8060 2016-04-29  Cesar Philippidis  <cesar@codesourcery.com>
8062         PR middle-end/70626
8063         * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
8064         * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
8065         reduction clauses in acc parallel loops.
8067 2016-04-29  Marek Polacek  <polacek@redhat.com>
8069         PR c/70852
8070         * c-common.c (warn_for_memset): Check domain before accessing it.
8072 2016-04-29  Dominik Vogt  <vogt@linux.vnet.ibm.com>
8074         PR/69089
8075         * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
8076         "aligned" attribute.
8078 2016-04-28  Jason Merrill  <jason@redhat.com>
8080         * c-lex.c (c_common_has_attribute): Handle nodiscard.
8082 2016-04-28  Eduard Sanou  <dhole@openmailbox.org>
8083             Matthias Klose  <doko@debian.org>
8085         * c-common.c (get_source_date_epoch): New function, gets the environment
8086         variable SOURCE_DATE_EPOCH and parses it as long long with error
8087         handling.
8088         * c-common.h (get_source_date_epoch): Prototype.
8089         * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
8091 2015-04-27  Ryan Burn  <contact@rnburn.com>
8093         PR c++/69024
8094         PR c++/68997
8095         * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
8096         (cilk_recognize_spawn): Renamed from recognize_spawn and change to
8097         external linkage.
8098         (cilk_detect_and_unwrap): Corresponding changes.
8099         (extract_free_variables): Don't extract free variables from
8100         AGGR_INIT_EXPR slot.
8101         * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
8102         (cilk_recognize_spawn): Likewise.
8104 2016-04-27  Bernd Schmidt  <bschmidt@redhat.com>
8106         * c.opt (Wmemset-elt-size): New option.
8107         * c-common.c (warn_for_memset): New function.
8108         * c-common.h (warn_for_memset): Declare.
8110 2016-04-25  Jason Merrill  <jason@redhat.com>
8112         * c-common.c (handle_unused_attribute): Accept CONST_DECL.
8113         No longer static.
8114         * c-common.h: Declare it.
8115         * c-lex.c (c_common_has_attribute): Add maybe_unused.
8117 2016-04-22  Jason Merrill  <jason@redhat.com>
8119         * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
8121 2016-04-20  Ilya Verbin  <ilya.verbin@intel.com>
8123         PR c++/69363
8124         * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
8125         * c-common.h (c_finish_cilk_clauses): Remove declaration.
8127 2016-04-18  Michael Matz  <matz@suse.de>
8129         * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
8130         and SET_DECL_ALIGN.
8132 2016-04-17  Eric Botcazou  <ebotcazou@adacore.com>
8134         * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
8135         (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
8136         to incomplete types.
8137         (dump_nested_type): Remove redundant tests and tidy up.
8138         (print_ada_declaration): Also set TREE_VISITED on the declaration of
8139         a type which is the typedef of an original type.
8141 2016-04-15  Marek Polacek  <polacek@redhat.com>
8143         PR c/70651
8144         * c-common.c (build_va_arg): Change two asserts into errors and return
8145         error_mark_node.
8147 2016-04-13  Marek Polacek  <polacek@redhat.com>
8149         PR c++/70639
8150         * c-indentation.c (should_warn_for_misleading_indentation): Bail out
8151         for switch statements, too.
8153 2016-03-28  Jason Merrill  <jason@redhat.com>
8155         * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
8157 2016-03-23  Marek Polacek  <polacek@redhat.com>
8159         PR c++/69884
8160         * c.opt (Wignored-attributes): New option.
8162 2016-03-22  David Malcolm  <dmalcolm@redhat.com>
8164         PR c/69993
8165         * c-indentation.c (warn_for_misleading_indentation): Rewrite the
8166         diagnostic text, reversing the order of the warning and note so
8167         that they appear in source order.
8169 2016-03-17  Marek Polacek  <polacek@redhat.com>
8171         PR c/69407
8172         * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
8173         operations.
8175 2016-03-14  Jason Merrill  <jason@redhat.com>
8177         * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
8179         * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
8181 2016-03-09  Richard Biener  <rguenther@suse.de>
8183         PR c/70143
8184         * c-common.c (strict_aliasing_warning): Add back
8185         alias_sets_conflict_p check.
8187 2016-03-08  Jason Merrill  <jason@redhat.com>
8189         * c-opts.c (set_std_cxx1z): Don't enable concepts.
8191 2016-03-04  David Malcolm  <dmalcolm@redhat.com>
8193         PR c/68187
8194         * c-indentation.c (get_visual_column): Move code to determine next
8195         tab stop to...
8196         (next_tab_stop): ...this new function.
8197         (line_contains_hash_if): Delete function.
8198         (detect_preprocessor_logic): Delete function.
8199         (get_first_nws_vis_column): New function.
8200         (detect_intervening_unindent): New function.
8201         (should_warn_for_misleading_indentation): Replace call to
8202         detect_preprocessor_logic with a call to
8203         detect_intervening_unindent.
8205 2016-03-04  David Malcolm  <dmalcolm@redhat.com>
8207         PR c/68187
8208         * c-indentation.c (should_warn_for_misleading_indentation): When
8209         suppressing warnings about cases where the guard and body are on
8210         the same column, only use the first non-whitespace column in place
8211         of the guard token column when dealing with "else" clauses.
8212         When rejecting aligned BODY and NEXT, loosen the requirement
8213         from equality with the first non-whitespace of guard to simply
8214         that they not be indented relative to it.
8216 2016-03-04  Richard Biener  <rguenther@suse.de>
8218         PR c++/70054
8219         * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
8220         instead of alias_sets_conflict_p.
8222 2016-03-01  Marek Polacek  <polacek@redhat.com>
8224         PR c++/69795
8225         * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
8226         any DECL.
8228 2016-02-22  Martin Sebor  <msebor@redhat.com>
8230         PR middle-end/69780
8231         * c-common.c (check_builtin_function_arguments): Validate and
8232         reject invalid arguments to __builtin_alloca_with_align.
8234 2016-02-20  Mark Wielaard  <mjw@redhat.com>
8236         PR c/28901
8237         * c.opt (Wunused-const-variable): Turn into Alias for...
8238         (Wunused-const-variable=): New option.
8240 2016-02-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>
8242         PR c++/69865
8243         * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
8244         here...
8245         (c_common_init_options): ...to here.
8246         (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
8248 2016-02-19  Jakub Jelinek  <jakub@redhat.com>
8250         PR c++/69826
8251         * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
8252         (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
8253         flag_preprocess_only.
8255 2016-02-16  Jakub Jelinek  <jakub@redhat.com>
8257         PR c/69835
8258         * c.opt (Wnonnull-compare): Enable for -Wall.
8260 2016-02-15  Jakub Jelinek  <jakub@redhat.com>
8262         PR c++/69797
8263         * c-common.c (sync_resolve_size): Diagnose too few arguments
8264         even when params is non-NULL empty vector.
8266 2016-02-08  Bernd Schmidt  <bschmidt@redhat.com>
8268         PR target/60410
8269         * c.opt (fshort-double): Remove.
8271 2016-02-05  Martin Sebor  <msebor@redhat.com>
8273         PR c++/69662
8274         * c.opt (Warning options): Update -Wplacement-new to take
8275         an optional argument.
8277 2016-02-01  Jakub Jelinek  <jakub@redhat.com>
8279         PR preprocessor/69543
8280         PR c/69558
8281         * c-pragma.c (handle_pragma_diagnostic): Pass input_location
8282         instead of loc to control_warning_option.
8284 2016-02-01  Nathan Sidwell  <nathan@codesourcery.com>
8286         * c.opt (fopenacc-dim=): New option.
8288 2016-01-27  Ryan Burn  <contact@rnburn.com>
8290         PR cilkplus/69267
8291         * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
8292         gimplify_arg. Removed superfluous post_p argument.
8293         * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
8294         superfluous post_p argument.
8295         * c-gimplify.c (c_gimplify_expr): Likewise.
8297 2016-01-26  David Malcolm  <dmalcolm@redhat.com>
8299         PR other/69006
8300         * c-opts.c (c_diagnostic_finalizer): Replace invocation of
8301         pp_newline_and_flush with pp_flush.
8303 2016-01-20  Martin Sebor  <msebor@redhat.com>
8305         PR c/69405
8306         * c-common.c (sync_resolve_size): Avoid printing diagnostic about
8307         an incompatible argument when the argument isn't a valid tree node.
8309 2016-01-18  Jason Merrill  <jason@redhat.com>
8311         PR c++/68767
8312         * c-common.c (check_function_arguments_recurse): Fold the whole
8313         COND_EXPR, not just the condition.
8315 2016-01-18  Tom de Vries  <tom@codesourcery.com>
8317         * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
8318         classify as loop clause.
8320 2016-01-15  Jakub Jelinek  <jakub@redhat.com>
8322         PR bootstrap/68271
8323         * c-pragma.c (c_register_pragma_1): Adjust comment to note that
8324         C++ FE no longer has limit on number of pragmas.
8326 2015-01-14  Ryan Burn  <contact@rnburn.com>
8328         PR c++/69048
8329         * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
8330         to add missing cleanup point.
8332 2016-01-14  David Malcolm  <dmalcolm@redhat.com>
8334         PR c++/68819
8335         * c-indentation.c (get_visual_column): Add location_t param.
8336         Handle the column number being zero by effectively disabling the
8337         warning, with an "inform".
8338         (should_warn_for_misleading_indentation): Add location_t argument
8339         for all uses of get_visual_column.
8341 2016-01-10  Patrick Palka  <ppalka@gcc.gnu.org>
8343         PR c++/69029
8344         * c-indentation.c (should_warn_for_misleading_indentation):
8345         Don't warn about do-while statements.
8347 2016-01-07  Martin Sebor  <msebor@redhat.com>
8349         PR c/68966
8350         * c-common.c (sync_resolve_size): Reject first argument when it's
8351         a pointer to _Bool.
8353 2016-01-05  David Malcolm  <dmalcolm@redhat.com>
8355         PR c/69122
8356         * c-indentation.c (get_visual_column): Remove default argument.
8357         (should_warn_for_misleading_indentation): For the multiline case,
8358         update call to get_visual_column for next_stmt_exploc so that it
8359         captures the location of the first non-whitespace character in the
8360         relevant line.  Don't issue warnings if there is non-whitespace
8361         before the next statement.
8363 2016-01-04  Jakub Jelinek  <jakub@redhat.com>
8365         Update copyright years.
8367 2015-12-21  David Malcolm  <dmalcolm@redhat.com>
8369         * c-common.c (binary_op_error): Convert first param from
8370         location_t to rich_location * and use it when emitting an error.
8371         * c-common.h (binary_op_error): Convert first param from
8372         location_t to rich_location *.
8374 2015-12-16  David Malcolm  <dmalcolm@redhat.com>
8376         * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
8377         * c-lex.c (conflict_marker_get_final_tok_kind): New function.
8379 2015-12-15  Ilya Verbin  <ilya.verbin@intel.com>
8381         * c-common.c (c_common_attribute_table): Handle "omp declare target
8382         link" attribute.
8384 2015-12-14  Jakub Jelinek  <jakub@redhat.com>
8386         PR c/68833
8387         * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
8389 2014-12-12  Tobias Burnus  <burnus@net-b.de>
8391         PR fortran/68815
8392         * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
8393         specifiers (%d, %i,%u and %c).
8395 2015-12-10  David Malcolm  <dmalcolm@redhat.com>
8397         * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
8399 2015-12-08  Jakub Jelinek  <jakub@redhat.com>
8401         PR c/48088
8402         PR c/68657
8403         * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
8404         * c-pragma.c (handle_pragma_diagnostic): Adjust
8405         control_warning_option caller.
8407 2015-12-07  David Malcolm  <dmalcolm@redhat.com>
8409         * c-common.c (c_cpp_error): Update for change to
8410         rich_location::set_range.
8412 2015-12-04  Paolo Bonzini  <bonzini@gnu.org>
8414         * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
8415         shifting 1 out of the sign bit.
8417 2015-12-04  Kirill Yukhin  <kirill.yukhin@intel.com>
8419         * c-common.c (c_common_attribute_table[]): Update max arguments
8420         count for "simd" attribute.
8421         (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
8423 2015-12-03  Jakub Jelinek  <jakub@redhat.com>
8425         PR preprocessor/57580
8426         * c-ppoutput.c (print): Change printed field to bool.
8427         Move src_file last for smaller padding.
8428         (init_pp_output): Set print.printed to false instead of 0.
8429         (scan_translation_unit): Fix up formatting.  Set print.printed
8430         to true after printing something other than newline.
8431         (scan_translation_unit_trad): Set print.printed to true instead of 1.
8432         (maybe_print_line_1): Set print.printed to false instead of 0.
8433         (print_line_1): Likewise.
8434         (do_line_change): Set print.printed to true instead of 1.
8435         (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
8436         dump_macro): Set print.printed to false after printing newline.
8438 2015-12-02  Jason Merrill  <jason@redhat.com>
8440         * c-common.c (fold_for_warn): New.
8441         (warn_logical_operator, warn_tautological_cmp)
8442         (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
8444         * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
8445         (c_fully_fold_internal, decl_constant_value_for_optimization):
8446         Move to c/c-fold.c.
8447         * c-common.h: Don't declare decl_constant_value_for_optimization.
8449 2015-12-02  Joseph Myers  <joseph@codesourcery.com>
8451         PR c/68162
8452         * c-common.h (c_build_qualified_type): Add extra default
8453         arguments.
8455 2015-12-01  Julian Brown  <julian@codesourcery.com>
8456             Cesar Philippidis  <cesar@codesourcery.com>
8457             James Norris  <James_Norris@mentor.com>
8459         * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
8460         * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
8461         (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
8463 2015-11-30  Eric Botcazou  <ebotcazou@adacore.com>
8465         * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
8466         (decl_sloc_common): Delete and move bulk of processing to...
8467         (decl_sloc): ...here.
8468         (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
8469         (dump_ada_double_name): Remove S parameter and compute the suffix.
8470         (dump_ada_array_type): Add PARENT parameter.  Simplify computation of
8471         element type and deal with an anonymous one.
8472         (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
8473         (dump_generic_ada_node): Tweak.  Adjust call to dump_ada_array_type
8474         and remove reference to QUAL_UNION_TYPE.
8475         (dump_nested_types): Make 2 passes on the fields and move bulk to...
8476         (dump_nested_type): ...here.  New function extracted from above.
8477         Generate a full declaration for anonymous element type of arrays.
8478         (print_ada_declaration): Really skip anonymous declarations.  Remove
8479         references to QUAL_UNION_TYPE.  Adjust call to dump_ada_array_type.
8480         Clean up processing of declarations of array types and objects.
8481         (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
8482         Remove obsolete code and tidy up.
8484 2015-11-29  Jan Hubicka  <hubicka@ucw.cz>
8486         PR c/67581
8487         * c-common.c (handle_transparent_union_attribute): Update
8488         also type variants.
8490 2015-11-27  Martin Liska  <mliska@suse.cz>
8492         PR c++/68312
8493         * array-notation-common.c (cilkplus_extract_an_triplets):
8494         Release vector of vectors.
8495         * cilk.c (gimplify_cilk_spawn): Free allocated memory.
8497 2015-11-26  Eric Botcazou  <ebotcazou@adacore.com>
8499         PR c++/68527
8500         * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
8501         (print_ada_struct_decl): Likewise.
8503 2015-11-23  Igor Zamyatin  <igor.zamyatin@intel.com>
8505         PR c++/68001
8506         * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
8507         * cilk.c (recognize_spawn): Determine location in a more precise
8508         way.
8510 2015-11-19  Jason Merrill  <jason@redhat.com>
8512         * c-common.c (shorten_compare): But look through macros from
8513         system headers.
8515 2015-11-18  Jason Merrill  <jason@redhat.com>
8517         * c-common.c (shorten_compare): Don't -Wtype-limits if the
8518         non-constant operand comes from a macro.
8520 2015-11-17  Jason Merrill  <jason@redhat.com>
8522         PR bootstrap/68346
8523         * c-common.c (warn_tautological_cmp): Fold before checking for
8524         constants.
8526 2015-11-16  Marek Polacek  <polacek@redhat.com>
8528         PR c++/68362
8529         * c-common.c (check_case_bounds): Fold low and high cases.
8531 2015-11-16  Marek Polacek  <polacek@redhat.com>
8533         * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
8534         * c-common.c (c_common_get_alias_set): Likewise.
8535         (handle_visibility_attribute): Likewise.
8537 2015-11-16  Kirill Yukhin  <kirill.yukhin@intel.com>
8539         * c-common.c (handle_simd_attribute): New.
8540         (struct attribute_spec): Add entry for "simd".
8541         (handle_simd_attribute): New.
8543 2015-11-13  Kai Tietz  <ktietz70@googlemail.com>
8545         * c-lex.c (interpret_float): Use fold_convert.
8547 2015-11-13  David Malcolm  <dmalcolm@redhat.com>
8549         * c-common.c (c_fully_fold_internal): Capture existing souce_range,
8550         and store it on the result.
8551         * c-opts.c (c_common_init_options): Set
8552         global_dc->colorize_source_p.
8554 2015-11-12  James Norris  <jnorris@codesourcery.com>
8555             Joseph Myers  <joseph@codesourcery.com>
8557         * c-pragma.c (oacc_pragmas): Add entry for declare directive.
8558         * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
8559         (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
8560         PRAGMA_OACC_CLAUSE_LINK.
8562 2015-11-11  Marek Polacek  <polacek@redhat.com>
8564         PR c/68107
8565         PR c++/68266
8566         * c-common.c (valid_array_size_p): New function.
8567         * c-common.h (valid_array_size_p): Declare.
8569 2015-11-11  Dominique d'Humieres  <dominiq@lps.ens.fr>
8571         PR bootstrap/68271
8572         * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
8574 2015-11-11  Andrew MacLeod  <amacleod@redhat.com>
8576         * array-notation-common.c: Remove unused header files.
8577         * c-ada-spec.c: Likewise.
8578         * c-cilkplus.c: Likewise.
8579         * c-common.c: Likewise.
8580         * c-cppbuiltin.c: Likewise.
8581         * c-dump.c: Likewise.
8582         * c-format.c: Likewise.
8583         * c-gimplify.c: Likewise.
8584         * c-indentation.c: Likewise.
8585         * c-lex.c: Likewise.
8586         * c-omp.c: Likewise.
8587         * c-opts.c: Likewise.
8588         * c-pch.c: Likewise.
8589         * c-ppoutput.c: Likewise.
8590         * c-pragma.c: Likewise.
8591         * c-pretty-print.c: Likewise.
8592         * c-semantics.c: Likewise.
8593         * c-ubsan.c: Likewise.
8594         * cilk.c: Likewise.
8595         * stub-objc.c: Likewise.
8597 2015-11-09  Thomas Schwinge  <thomas@codesourcery.com>
8598             Cesar Philippidis  <cesar@codesourcery.com>
8599             James Norris  <jnorris@codesourcery.com>
8600             Julian Brown  <julian@codesourcery.com>
8601             Nathan Sidwell  <nathan@codesourcery.com>
8603         * c-pragma.c (oacc_pragmas): Add "routine".
8604         * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
8606 2015-11-08  Eric Botcazou  <ebotcazou@adacore.com>
8608         * c-common.c (c_common_attributes): Add scalar_storage_order.
8609         (handle_scalar_storage_order_attribute): New function.
8610         * c-pragma.c (global_sso): New variable.
8611         (maybe_apply_pragma_scalar_storage_order): New function.
8612         (handle_pragma_scalar_storage_order): Likewise.
8613         (init_pragma): Register scalar_storage_order.
8614         * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
8615         * c.opt (Wscalar-storage-order): New warning.
8616         (fsso-struct=): New option.
8618 2015-11-08  Martin Sebor  <msebor@redhat.com>
8620         * c.opt (Wplacement-new): Add a period to the end of a sentence.
8622 2015-11-07  Richard Sandiford  <richard.sandiford@arm.com>
8624         * c-common.c: Don't undef DEF_BUILTIN.
8626 2015-11-06  David Malcolm  <dmalcolm@redhat.com>
8628         * c-common.c (c_cpp_error): Convert parameter from location_t to
8629         rich_location *.  Eliminate the "column_override" parameter and
8630         the call to diagnostic_override_column.
8631         Update the "done_lexing" clause to set range 0
8632         on the rich_location, rather than overwriting a location_t.
8633         * c-common.h (c_cpp_error): Convert parameter from location_t to
8634         rich_location *.  Eliminate the "column_override" parameter.
8636 2015-11-05  Cesar Philippidis  <cesar@codesourcery.com>
8637             Thomas Schwinge  <thomas@codesourcery.com>
8638             James Norris  <jnorris@codesourcery.com>
8640         * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
8641         AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses.  Associate REDUCTION
8642         clauses with parallel and kernels and loops.
8643         * c-pragma.h (enum pragma_omp_clause): Add entries for
8644         PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
8645         * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
8646         NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
8647         INDEPENDENT,SEQ}.
8648         (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
8650 2015-11-05  Martin Sebor  <msebor@redhat.com>
8652         PR c++/67942
8653         * c.opt (-Wplacement-new): New option.
8655 2015-11-05  Jakub Jelinek  <jakub@redhat.com>
8657         * c-common.h (c_finish_omp_atomic): Add TEST argument.
8658         (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
8659         * c-omp.c (c_finish_omp_atomic): Add TEST argument.  Don't call
8660         save_expr or create_tmp_var* if TEST is true.
8661         (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
8662         Don't call add_stmt here.
8663         (struct c_omp_check_loop_iv_data): New type.
8664         (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
8665         c_omp_check_loop_iv_exprs): New functions.
8666         (c_omp_split_clauses): Adjust for lastprivate being allowed on
8667         distribute.
8668         (c_omp_declare_simd_clauses_to_numbers): Change
8669         OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
8670         (c_omp_declare_simd_clauses_to_decls): Similarly change those
8671         from numbers to PARM_DECLs.
8673 2015-11-04  Mikhail Maltsev  <maltsevm@gmail.com>
8675         * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
8676         flag_checking.
8678 2015-11-03  Bernd Schmidt  <bschmidt@redhat.com>
8680         PR c++-common/67882
8681         * c-common.h (fold_offsetof_1): Add argument.
8682         * c-common.c (fold_offsetof_1): Diagnose more invalid
8683         offsetof expressions that reference elements past the end of
8684         an array.
8686 2015-11-03  Thomas Schwinge  <thomas@codesourcery.com>
8687             Chung-Lin Tang  <cltang@codesourcery.com>
8689         * c-pragma.c (oacc_pragmas): Add "atomic".
8690         * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
8692 2015-10-30  Evgeny Stupachenko  <evstupac@gmail.com>
8694         * c-common.c (handle_target_clones_attribute): New.
8695         (c_common_attribute_table): Add handle_target_clones_attribute.
8696         (handle_always_inline_attribute): Add check on target_clones attribute.
8697         (handle_target_attribute): Ditto.
8699 2015-10-29  Andrew MacLeod  <amacleod@redhat.com>
8701         * array-notation-common.c: Reorder #include's and remove duplicates.
8702         * c-ada-spec.c: Likewise.
8703         * c-cilkplus.c: Likewise.
8704         * c-common.c: Likewise.
8705         * c-cppbuiltin.c: Likewise.
8706         * c-dump.c: Likewise.
8707         * c-format.c: Likewise.
8708         * c-gimplify.c: Likewise.
8709         * c-indentation.c: Likewise.
8710         * c-lex.c: Likewise.
8711         * c-omp.c: Likewise.
8712         * c-opts.c: Likewise.
8713         * c-pch.c: Likewise.
8714         * c-ppoutput.c: Likewise.
8715         * c-pragma.c: Likewise.
8716         * c-pretty-print.c: Likewise.
8717         * c-semantics.c: Likewise.
8718         * c-ubsan.c: Likewise.
8719         * cilk.c: Likewise.
8720         * stub-objc.c: Likewise.
8722 2015-10-28  Jason Merrill  <jason@redhat.com>
8724         * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
8726 2015-10-27  Thomas Schwinge  <thomas@codesourcery.com>
8727             James Norris  <jnorris@codesourcery.com>
8728             Cesar Philippidis  <cesar@codesourcery.com>
8730         PR c/64765
8731         PR c/64880
8732         * c-common.h (c_oacc_split_loop_clauses): Declare function.
8733         * c-omp.c (c_oacc_split_loop_clauses): New function.
8735 2015-10-21  Martin Sebor  <msebor@redhat.com>
8737         PR driver/68043
8738         * c.opt: End each sentence that describes an option with a period.
8740 2015-10-20  Marek Polacek  <polacek@redhat.com>
8742         * array-notation-common.c (is_cilkplus_vector_p): Define.
8743         * c-common.h (is_cilkplus_vector_p): Declare.
8745 2015-10-20  Marek Polacek  <polacek@redhat.com>
8747         * c.opt (std=gnu++11): Do not describe as experimental.
8748         (std=gnu++14): Likewise.
8750 2015-10-19  Jason Merrill  <jason@redhat.com>
8752         * c-cppbuiltin.c (c_cpp_builtins): Define
8753         __cpp_nontype_template_args.
8755 2015-10-19  Jason Merrill  <jason@redhat.com>
8757         * c-cppbuiltin.c (c_cpp_builtins): Define
8758         __cpp_enumerator_attributes, __cpp_fold_expressions,
8759         __cpp_unicode_characters.
8761 2015-10-13  Jakub Jelinek  <jakub@redhat.com>
8762             Aldy Hernandez  <aldyh@redhat.com>
8764         * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
8765         DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
8766         (c_define_builtins): Likewise.
8767         * c-common.h (enum c_omp_clause_split): Add
8768         C_OMP_CLAUSE_SPLIT_TASKLOOP.
8769         (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
8770         (c_finish_omp_for): Add ORIG_DECLV argument.
8771         * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
8772         201511 instead of 201307.
8773         * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
8774         OMP_CRITICAL_CLAUSES to it.
8775         (c_finish_omp_ordered): Add CLAUSES argument, set
8776         OMP_ORDERED_CLAUSES to it.
8777         (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
8778         to it if OMP_FOR.  Clear DECL_INITIAL on the IVs.
8779         (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
8780         constructs and new OpenMP 4.5 clauses.  Clear
8781         OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD.  Add
8782         verification code.
8783         * c-pragma.c (omp_pragmas_simd): Add taskloop.
8784         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
8785         (enum pragma_omp_clause): Add
8786         PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
8787         and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
8789 2015-10-05  Richard Sandiford  <richard.sandiford@arm.com>
8791         * c-lex.c (interpret_float): Use real_equal instead of
8792         REAL_VALUES_EQUAL.
8794 2015-10-04  Jason Merrill  <jason@redhat.com>
8796         Implement N4514, C++ Extensions for Transactional Memory.
8797         * c-common.c (c_common_reswords): Add C++ TM TS keywords.
8798         (c_common_attribute_table): Add transaction_safe_dynamic.
8799         transaction_safe now affects type identity.
8800         (handle_tm_attribute): Handle transaction_safe_dynamic.
8801         * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
8802         RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
8803         (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
8804         (D_TRANSMEM): New.
8805         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
8806         * c-pretty-print.c (pp_c_attributes_display): Don't print
8807         transaction_safe in C++.
8809 2015-10-02  Marek Polacek  <polacek@redhat.com>
8811         * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
8813 2015-10-02  Marek Polacek  <polacek@redhat.com>
8815         PR c/64249
8816         * c-common.c (warn_duplicated_cond_add_or_warn): New function.
8817         * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
8818         * c.opt (Wduplicated-cond): New option.
8820 2015-10-01  Joseph Myers  <joseph@codesourcery.com>
8822         * c.opt (std=c11): Do not describe as experimental.
8823         (std=gnu11): Likewise.
8824         (std=iso9899:2011): Likewise.
8826 2015-09-28  Nathan Sidwell  <nathan@codesourcery.com>
8828         * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
8829         (DEF_FUNCTION_TYPE_VAR_11): Delete.
8831 2015-09-25  Marek Polacek  <polacek@redhat.com>
8833         * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
8834         (ubsan_instrument_shift): Likewise.
8836 2015-09-25  Marek Polacek  <polacek@redhat.com>
8838         PR sanitizer/64906
8839         * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
8841 2015-09-24  Patrick Palka  <ppalka@gcc.gnu.org>
8843         * c-indentation.c (should_warn_for_misleading_indentation):
8844         Compare next_stmt_vis_column with guard_line_first_nws instead
8845         of with guard_line_vis_column.
8847 2015-09-23  Manuel López-Ibáñez  <manu@gcc.gnu.org>
8849         PR c/49654
8850         PR c/49655
8851         * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
8852         options and options not valid for the current language.
8854 2015-09-22  Patrick Palka  <ppalka@gcc.gnu.org>
8856         * c-indentation.c (should_warn_for_misleading_indentation):
8857         Float out and consolidate the calls to get_visual_column that
8858         are passed guard_exploc as an argument.  Compare
8859         next_stmt_vis_column with guard_line_first_nws instead of with
8860         body_line_first_nws.
8862 2015-09-22  Nathan Sidwell  <nathan@codesourcery.com>
8864         * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
8865         Wnamespaces): New C++ warnings.
8867 2015-09-22  Jason Merrill  <jason@redhat.com>
8869         * c-common.h (abi_compat_version_crosses): New.
8870         (warn_abi_version): Declare.
8871         * c-common.c: Define it.
8872         * c-opts.c (c_common_post_options): Handle it.
8873         flag_abi_compat_version defaults to 8.
8875 2015-09-21  Ville Voutilainen  <ville.voutilainen@gmail.com>
8877         Complete the implementation of N4230, Nested namespace definition.
8878         * c-cppbuiltin.c: Add __cpp_namespace_attributes and
8879         __cpp_nested_namespace_definitions.
8881 2015-09-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>
8883         * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
8885 2015-09-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>
8887         * c-pragma.c (handle_pragma_diagnostic): Use explicit location
8888         when warning.
8889         * c-pragma.h (pragma_lex): Add optional loc argument.
8891 2015-09-16  Mikhail Maltsev  <maltsevm@gmail.com>
8893         * c-format.c (check_format_arg): Adjust to use common block size in all
8894         object pools.
8896 2015-09-15  David Malcolm  <dmalcolm@redhat.com>
8898         * c-format.c (location_from_offset): Update for change in
8899         signature of location_get_source_line.
8900         * c-indentation.c (get_visual_column): Likewise.
8901         (line_contains_hash_if): Likewise.
8903 2015-09-14  Marek Polacek  <polacek@redhat.com>
8905         * c-opts.c (c_common_post_options): Set C++ standard earlier, before
8906         setting various warnings.
8908 2015-09-14  Marek Polacek  <polacek@redhat.com>
8910         * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
8911         a negative value.
8913 2015-09-11  Mark Wielaard  <mjw@redhat.com>
8915         PR c/28901
8916         * c.opt (Wunused-variable): Option from common.opt.
8917         (Wunused-const-variable): New option.
8919 2015-09-09  Paolo Carlini  <paolo.carlini@oracle.com>
8921         PR c++/53184
8922         * c.opt ([Wsubobject-linkage]): Add.
8924 2015-09-03  Martin Sebor  <msebor@redhat.com>
8926         PR c/66516
8927         * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
8928         functions.
8929         * c-common.c (reject_gcc_builtin): Define.
8931 2015-09-02  Balaji V. Iyer  <balaji.v.iyer@intel.com>
8933         PR middle-end/60586
8934         * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
8935         prototype.
8936         * c-gimplify.c (c_gimplify_expr): Added a call to the function
8937         cilk_gimplify_call_params_in_spawned_fn.
8938         * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
8939         (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
8940         unwrapping.
8942 2015-08-25  Marek Polacek  <polacek@redhat.com>
8944         PR middle-end/67330
8945         * c-common.c (handle_weak_attribute): Don't check whether the
8946         visibility can be changed here.
8948 2015-08-22  Manuel López-Ibáñez  <manu@gcc.gnu.org>
8950         * c-lex.c (c_lex_with_flags): Use explicit locations.
8952 2015-08-18  Trevor Saunders  <tbsaunde@tbsaunde.org>
8954         * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
8955         c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
8957 2015-08-18  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
8959         PR middle-end/36757
8960         * c-common.c (check_builtin_function_arguments): Add check
8961         for BUILT_IN_SIGNBIT argument.
8963 2015-08-18  Paolo Carlini  <paolo.carlini@oracle.com>
8965         PR c++/67160
8966         * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
8967         in c++1z mode.
8969 2015-08-17  Marek Polacek  <polacek@redhat.com>
8971         * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
8972         with whitespaces before qualifier names.
8974 2015-08-12  Marek Polacek  <polacek@redhat.com>
8976         PR c++/55095
8977         * c-common.c (maybe_warn_shift_overflow): Properly handle
8978         left-shifting 1 into the sign bit.
8980 2015-08-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
8982         * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
8984 2015-08-06  Andrew Sutton  <andrew.n.sutton@gmail.com>
8985             Braden Obrzut  <admin@maniacsvault.net>
8986             Jason Merrill  <jason@redhat.com>
8988         Add C++ Concepts TS support.
8989         * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
8990         * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
8991         (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
8992         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
8993         * c-opts.c (set_std_cxx1z): Set flag_concepts.
8994         * c.opt (fconcepts): New.
8996 2015-08-02  Martin Sebor  <msebor@redhat.com>
8998         * c.opt (-Wframe-address): New warning option.
9000 2015-08-02  Patrick Palka  <ppalka@gcc.gnu.org>
9002         * c-indentation.c (should_warn_for_misleading_indentation):
9003         Improve heuristics.
9005 2015-08-02  Patrick Palka  <ppalka@gcc.gnu.org>
9007         * c-indentation.c (get_visual_column): Add parameter first_nws,
9008         use it.  Update comment documenting the function.
9009         (is_first_nonwhitespace_on_line): Remove.
9010         (should_warn_for_misleading_indentation): Replace usage of
9011         of is_first_nonwhitespace_on_line with get_visual_column.
9013 2015-08-02  Patrick Palka  <ppalka@gcc.gnu.org>
9015         * c-indentation.h (struct token_indent_info): Define.
9016         (get_token_indent_info): Define.
9017         (warn_for_misleading_information): Declare.
9018         * c-common.h (warn_for_misleading_information): Remove.
9019         * c-identation.c (warn_for_misleading_indentation):
9020         Change declaration to take three token_indent_infos.  Adjust
9021         accordingly.
9022         * c-identation.c (should_warn_for_misleading_indentation):
9023         Likewise.  Bail out early if the body is a compound statement.
9024         (guard_tinfo_to_string): Define.
9026 2015-07-30  Jason Merrill  <jason@redhat.com>
9028         * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
9029         '*' for reference decay.
9031 2015-07-30  Marek Polacek  <polacek@redhat.com>
9033         * c-common.c (warn_tautological_cmp): Bail for float types.
9035 2015-07-27  Marek Polacek  <polacek@redhat.com>
9037         PR bootstrap/67030
9038         * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
9040 2015-07-27  Marek Polacek  <polacek@redhat.com>
9042         PR c++/66555
9043         PR c/54979
9044         * c-common.c (find_array_ref_with_const_idx_r): New function.
9045         (warn_tautological_cmp): New function.
9046         * c-common.h (warn_tautological_cmp): Declare.
9047         * c.opt (Wtautological-compare): New option.
9049 2015-07-23  Marek Polacek  <polacek@redhat.com>
9051         * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
9052         (ubsan_instrument_shift): Likewise.
9054 2015-07-23  Marek Polacek  <polacek@redhat.com>
9056         PR sanitizer/66908
9057         * c-ubsan.c: Include gimplify.h.
9058         (ubsan_instrument_division): Unshare OP0 and OP1.
9059         (ubsan_instrument_shift): Likewise.
9061 2015-07-20  Marek Polacek  <polacek@redhat.com>
9062             Richard Sandiford  <richard.sandiford@arm.com>
9064         PR c++/55095
9065         * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
9066         Use EXPR_LOC_OR_LOC.
9067         (maybe_warn_shift_overflow): New function.
9068         * c-common.h (maybe_warn_shift_overflow): Declare.
9069         * c-opts.c (c_common_post_options): Set warn_shift_overflow.
9070         * c.opt (Wshift-overflow): New option.
9072 2015-07-16  Martin Liska  <mliska@suse.cz>
9074         * c-format.c (static void check_format_info_main): Use
9075         object_allocator instead of pool_allocator.
9076         (check_format_arg): Likewise.
9077         (check_format_info_main): Likewise.
9079 2015-07-15  Andrew MacLeod  <amacleod@redhat.com>
9081         * c-opts.c: Remove multiline #include comment.
9083 2015-07-12  Aldy Hernandez  <aldyh@redhat.com>
9085         * c-common.c: Fix double word typos.
9087 2015-07-10  Eric Botcazou  <ebotcazou@adacore.com>
9089         * c-ada-spec.h (cpp_operation): Revert latest change.
9090         * c-ada-spec.c (print_ada_declaration): Likewise.  Skip implicit
9091         constructors and destructors.
9093 2015-07-09  Andrew MacLeod  <amacleod@redhat.com>
9095         * c-common.h: Adjust includes for flags.h changes.
9096         * stub-objc.c: Likewise.
9098 2015-07-08  Eric Botcazou  <ebotcazou@adacore.com>
9100         * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
9101         * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
9103 2015-07-08  Jakub Jelinek  <jakub@redhat.com>
9105         * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
9106         are to be removed, return NULL rather than original clauses list.
9108 2015-07-07  Andrew MacLeod  <amacleod@redhat.com>
9110         * array-notation-common.c: Adjust includes.
9111         * c-ada-spec.c: Likewise.
9112         * c-cilkplus.c: Likewise.
9113         * c-common.h: Likewise.
9114         * c-cppbuiltin.c: Likewise.
9115         * c-dump.c: Likewise.
9116         * c-format.c: Likewise.
9117         * c-gimplify.c: Likewise.
9118         * c-indentation.c: Likewise.
9119         * c-lex.c: Likewise.
9120         * c-omp.c: Likewise.
9121         * c-opts.c: Likewise.
9122         * c-pch.c: Likewise.
9123         * c-ppoutput.c: Likewise.
9124         * c-pragma.c: Likewise.
9125         * c-pretty-print.c: Likewise.
9126         * c-semantics.c: Likewise.
9127         * c-ubsan.c: Likewise.
9128         * cilk.c: Likewise.
9129         * stub-objc.c: Likewise.
9131 2015-07-07  Eric Botcazou  <ebotcazou@adacore.com>
9133         * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
9134         * c-ada-spec.c (print_ada_declaration): Skip move constructors.
9136 2015-07-01  Jason Merrill  <jason@redhat.com>
9138         * c-common.h (D_CXX11): Rename from D_CXX0X.
9139         (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
9140         * c-common.c: Adjust.
9142         * c-opts.c (c_common_post_options): Default to C++14.
9144         * c-opts.c (c_common_post_options): Highest ABI level is now 10.
9146 2015-06-30  Edward Smith-Rowland  <3dw4rd@verizon.net>
9148         Implement N4197 - Adding u8 character literals
9149         * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
9150         CPP_CHAR.
9151         * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
9152         CPP_UTF8CHAR_USERDEF tokens.
9153         * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
9154         and CPP_UTF8CHAR tokens.
9155         (lex_charconst): Treat CPP_UTF8CHAR token.
9157 2015-06-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
9159         PR fortran/66605
9160         * c-common.c (do_warn_unused_parameter): Move here.
9161         * c-common.h (do_warn_unused_parameter): Declare.
9163 2015-06-29  Marek Polacek  <polacek@redhat.com>
9165         PR c/66322
9166         * c-common.c (check_case_bounds): Add bool * parameter.  Set
9167         OUTSIDE_RANGE_P.
9168         (c_add_case_label): Add bool * parameter.  Pass it down to
9169         check_case_bounds.
9170         (c_do_switch_warnings): Add bool parameters.  Implement -Wswitch-bool
9171         warning here.
9172         * c-common.h (c_add_case_label, c_do_switch_warnings): Update
9173         declarations.
9175 2015-06-27  Marek Polacek  <polacek@redhat.com>
9177         * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
9178         or VECTOR_INTEGER_TYPE_P throughout.
9179         * c-gimplify.c: Likewise.
9181 2015-06-26  Marek Polacek  <polacek@redhat.com>
9183         * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
9184         * c-common.c (c_fully_fold_internal): Likewise.
9185         (c_alignof_expr): Likewise.
9186         * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
9187         * c-ubsan.c (ubsan_instrument_bounds): Likewise.
9188         * cilk.c (create_parm_list): Likewise.
9190 2015-06-26  Marek Polacek  <polacek@redhat.com>
9192         * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
9194 2015-06-25  Andrew MacLeod  <amacleod@redhat.com>
9196         * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
9197         * c-gimplify.c: Likewise.
9198         * c-pragma.c: Likewise.
9199         * c-ubsan.c: Likewise.
9200         * cilk.c: Likewise.
9202 2015-06-25  Richard Sandiford  <richard.sandiford@arm.com>
9204         * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
9205         ggc_hasher.
9207 2015-06-25  Andrew MacLeod  <amacleod@redhat.com>
9209         * cilk.c: Move calls.h after tm.h in the include chain.
9211 2015-06-25  Marek Polacek  <polacek@redhat.com>
9213         * array-notation-common.c: Use VAR_P throughout.
9214         * c-ada-spec.c: Likewise.
9215         * c-common.c: Likewise.
9216         * c-format.c: Likewise.
9217         * c-gimplify.c: Likewise.
9218         * c-omp.c: Likewise.
9219         * c-pragma.c: Likewise.
9220         * c-pretty-print.c: Likewise.
9221         * cilk.c: Likewise.
9223 2015-06-25  Marek Polacek  <polacek@redhat.com>
9225         * cilk.c (extract_free_variables): Use is_global_var.
9227 2015-06-23  Richard Sandiford  <richard.sandiford@arm.com>
9229         * c-common.c: Don't include target-def.h.
9231 2015-06-23  Marek Polacek  <polacek@redhat.com>
9233         * c-common.c (warn_logical_operator): Use tree_int_cst_equal
9234         when comparing INTEGER_CSTs.
9236 2015-06-22  Pierre-Marie de Rodat  <derodat@adacore.com>
9238         * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
9239         * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
9240         (dump_ada_template): Skip partially specialized types.
9242 2015-06-22  Mikhail Maltsev  <maltsevm@gmail.com>
9244         * c-common.c (scalar_to_vector): Use std::swap instead of manually
9245         swapping.
9247 2015-06-17  Andrew MacLeod  <amacleod@redhat.com>
9249         * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
9250         * c-ada-spec.c: Likewise.
9251         * c-cilkplus.c: Likewise.
9252         * c-common.c: Likewise.
9253         * c-common.h: Likewise.
9254         * c-cppbuiltin.c: Likewise.
9255         * c-dump.c: Likewise.
9256         * c-format.c: Likewise.
9257         * c-gimplify.c: Likewise.
9258         * c-indentation.c: Likewise.
9259         * c-lex.c: Likewise.
9260         * c-omp.c: Likewise.
9261         * c-opts.c: Likewise.
9262         * c-pch.c: Likewise.
9263         * c-ppoutput.c: Likewise.
9264         * c-pragma.c: Likewise.
9265         * c-pretty-print.c: Likewise.
9266         * c-semantics.c: Likewise.
9267         * c-ubsan.c: Likewise.
9268         * cilk.c: Likewise.
9269         * stub-objc.c: Likewise.
9271 2015-06-13  Patrick Palka  <ppalka@gcc.gnu.org>
9273         PR c++/65168
9274         * c-common.c (c_common_truthvalue_conversion): Warn when
9275         converting an address of a reference to a truth value.
9277 2015-06-08  Andrew MacLeod  <amacleod@redhat.com>
9279         * array-notation-common.c : Adjust include files.
9280         * c-ada-spec.c : Likewise.
9281         * c-cilkplus.c : Likewise.
9282         * c-common.c : Likewise.
9283         * c-common.h : Likewise.
9284         * c-cppbuiltin.c : Likewise.
9285         * c-dump.c : Likewise.
9286         * c-format.c : Likewise.
9287         * c-gimplify.c : Likewise.
9288         * c-indentation.c : Likewise.
9289         * c-lex.c : Likewise.
9290         * c-omp.c : Likewise.
9291         * c-opts.c : Likewise.
9292         * c-pch.c : Likewise.
9293         * c-ppoutput.c : Likewise.
9294         * c-pragma.c : Likewise.
9295         * c-pretty-print.c : Likewise.
9296         * c-semantics.c : Likewise.
9297         * c-ubsan.c : Likewise.
9298         * cilk.c : Likewise.
9299         * stub-objc.c : Likewise.
9301 2015-06-08  Marek Polacek  <polacek@redhat.com>
9303         PR c/66415
9304         * c-format.c (location_from_offset): Return LOC if LINE is null.
9306 2015-06-05  Aldy Hernandez  <aldyh@redhat.com>
9308         * c-common.h (c_parse_final_cleanups): New prototype.
9309         * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
9311 2015-06-04  Sriraman Tallam  <tmsriram@google.com>
9313         * c-common.c (noplt): New attribute.
9314         (handle_noplt_attribute): New handler.
9316 2015-06-04  Andrew MacLeod  <amacleod@redhat.com>
9318         * array-notation-common.c: Adjust includes for restructured coretypes.h.
9319         * c-ada-spec.c: Likewise.
9320         * c-cilkplus.c: Likewise.
9321         * c-common.c: Likewise.
9322         * c-common.h: Likewise.
9323         * c-cppbuiltin.c: Likewise.
9324         * c-dump.c: Likewise.
9325         * c-format.c: Likewise.
9326         * c-gimplify.c: Likewise.
9327         * c-indentation.c: Likewise.
9328         * c-lex.c: Likewise.
9329         * c-omp.c: Likewise.
9330         * c-opts.c: Likewise.
9331         * c-pch.c: Likewise.
9332         * c-ppoutput.c: Likewise.
9333         * c-pragma.c: Likewise.
9334         * c-pretty-print.c: Likewise.
9335         * c-semantics.c: Likewise.
9336         * c-ubsan.c: Likewise.
9337         * cilk.c: Likewise.
9338         * stub-objc.c: Likewise.
9340 2015-06-02  David Malcolm  <dmalcolm@redhat.com>
9342         PR c/66220:
9343         * c-indentation.c (should_warn_for_misleading_indentation): Use
9344         expand_location rather than expand_location_to_spelling_point.
9345         Don't warn if the guarding statement is more indented than the
9346         next/body stmts.
9348 2015-06-02  David Malcolm  <dmalcolm@redhat.com>
9350         * c-indentation.c (warn_for_misleading_indentation): Bail out
9351         immediately if -Wmisleading-indentation isn't enabled.
9353 2015-06-01  Martin Liska  <mliska@suse.cz>
9355         * c-format.c (check_format_arg):Use new type-based pool allocator.
9356         (check_format_info_main) Likewise.
9358 2015-05-31  Eric Botcazou  <ebotcazou@adacore.com>
9360         * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
9361         (has_nontrivial_methods): Likewise.
9363 2015-05-25  Marek Polacek  <polacek@redhat.com>
9365         * c-ubsan.c (ubsan_instrument_shift): Use type0.
9367 2015-05-22  Marek Polacek  <polacek@redhat.com>
9369         PR c/47043
9370         * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
9372 2015-05-21  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
9374         * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
9375         STACK_GROWS_DOWNWARD.
9377 2015-05-21  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
9379         * c-cppbuiltin.c (c_cpp_builtins): Check the value of
9380         STACK_GROWS_DOWNWARD rather than if it is defined.
9382 2015-05-21  Manuel López-Ibáñez  <manu@gcc.gnu.org>
9384         PR c/52952
9385         * c-format.c (location_column_from_byte_offset): New.
9386         (location_from_offset): New.
9387         (struct format_wanted_type): Add offset_loc field.
9388         (check_format_info): Move handling of location for extra arguments
9389         closer to the point of warning.
9390         (check_format_info_main): Pass the result of location_from_offset
9391         to warning_at.
9392         (format_type_warning): Pass the result of location_from_offset
9393         to warning_at.
9395 2015-05-20  Marek Polacek  <polacek@redhat.com>
9397         * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
9399 2015-05-20  Marek Polacek  <polacek@redhat.com>
9401         * c-ada-spec.c (dump_sloc): Use DECL_P.
9403 2015-05-20  Marek Polacek  <polacek@redhat.com>
9405         * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
9406         * c-common.c: Likewise.
9408 2015-05-19  David Malcolm  <dmalcolm@redhat.com>
9410         * c-common.h (fe_file_change): Strengthen param from
9411         const line_map * to const line_map_ordinary *.
9412         (pp_file_change): Likewise.
9413         * c-lex.c (fe_file_change): Likewise.
9414         (cb_define): Use linemap_check_ordinary when invoking
9415         SOURCE_LINE.
9416         (cb_undef): Likewise.
9417         * c-opts.c (c_finish_options): Use linemap_check_ordinary when
9418         invoking cb_file_change.
9419         (c_finish_options): Likewise.
9420         (push_command_line_include): Likewise.
9421         (cb_file_change): Strengthen param "new_map" from
9422         const line_map * to const line_map_ordinary *.
9423         * c-ppoutput.c (cb_define): Likewise for local "map".
9424         (pp_file_change): Likewise for param "map" and local "from".
9426 2015-05-19  Mikhail Maltsev  <maltsevm@gmail.com>
9428         * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
9430 2015-05-18  Tom de Vries  <tom@codesourcery.com>
9432         * c-common.c (build_va_arg_1): New function.
9433         (build_va_arg): Add address operator to va_list operand if necessary.
9435 2015-05-15  Mikhail Maltsev  <maltsevm@gmail.com>
9437         PR c/48956
9438         * c-common.c (int_safely_convertible_to_real_p): Define.
9439         (unsafe_conversion_p): Check conversions involving complex types.
9440         (conversion_warning): Add new warning message for conversions which
9441         discard imaginary component.
9442         * c-common.h: (enum conversion_safety): Add new enumerator for such
9443         conversions.
9445 2015-05-14  Marek Polacek  <polacek@redhat.com>
9447         PR c/66066
9448         PR c/66127
9449         * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
9450         (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
9451         C_MAYBE_CONST_EXPR_INT_OPERANDS set.  Add FOR_INT_CONST argument and
9452         use it.  If FOR_INT_CONST, require that all evaluated operands be
9453         INTEGER_CSTs.
9455 2015-05-12  David Malcolm  <dmalcolm@redhat.com>
9457         * c-common.h (warn_for_misleading_indentation): New prototype.
9458         * c-indentation.c: New file.
9459         * c.opt (Wmisleading-indentation): New option.
9461 2015-05-12  Tom de Vries  <tom@codesourcery.com>
9463         PR tree-optimization/66010
9464         * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
9466 2015-05-09  Jason Merrill  <jason@redhat.com>
9468         * c-opts.c (c_common_post_options): Also clear
9469         cpp_opts->cpp_warn_cxx11_compat.
9471         * c-common.h (enum cxx_dialect): Add cxx_unset.
9472         * c-common.c (cxx_dialect): Initialize to cxx_unset.
9473         * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
9475         * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
9476         (std=gnu++0x): Mark as Undocumented.
9477         (std=gnu++1y): Add deprecated message.
9479 2015-05-08  Jason Merrill  <jason@redhat.com>
9481         * c.opt (Wc++11-compat): Make primary.  Rename var warn_cxx11_compat.
9482         * c-opts.c: Adjust.
9484         * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
9486 2015-05-08  Marek Polacek  <polacek@redhat.com>
9488         PR c/64918
9489         * c.opt (Woverride-init-side-effects): New option.
9491 2015-05-07  Marek Polacek  <polacek@redhat.com>
9493         PR c/65179
9494         * c-common.c (c_fully_fold_internal): Warn when left shifting a
9495         negative value.
9496         * c.opt (Wshift-negative-value): New option.
9497         * c-opts.c (c_common_post_options): Set warn_shift_negative_value
9498         when -Wextra and C99/C++11 mode.
9500 2015-05-07  Marek Polacek  <polacek@redhat.com>
9501             Martin Uecker  <uecker@eecs.berkeley.edu>
9503         * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
9504         flexible member array-like members if SANITIZE_BOUNDS_STRICT.
9506 2015-05-05  Jason Merrill  <jason@redhat.com>
9508         * c.opt (Wterminate): New.
9510 2015-04-30  Marek Polacek  <polacek@redhat.com>
9512         * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
9513         require that the non-constant be of a boolean type.
9515 2015-04-29  Josh Triplett  <josh@joshtriplett.org>
9517         * c-common.c (handle_section_attribute): Refactor to reduce
9518         nesting and distinguish between error cases.
9520 2015-04-29  Marek Polacek  <polacek@redhat.com>
9522         PR c/64610
9523         * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
9524         with 0/1.
9526 2015-04-29  Jakub Jelinek  <jakub@redhat.com>
9528         * c-common.h (omp_clause_mask): Unconditionally define as a class.
9529         Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
9530         HOST_BITS_PER_WIDE_INT.
9532 2015-04-28  Tom de Vries  <tom@codesourcery.com>
9534         PR tree-optimization/65887
9535         * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
9537 2015-04-28  Eric Botcazou  <ebotcazou@adacore.com>
9538             Pierre-Marie de Rodat  <derodat@adacore.com>
9540         * c-ada-spec.c (in_function): Delete.
9541         (dump_generic_ada_node): Do not change in_function and remove the
9542         redundant code dealing with it.
9543         (print_ada_declaration): Do not change in_function.  Use INDENT_INCR.
9544         (print_ada_methods): Output the static member functions in a nested
9545         package after the regular methods as well as associated renamings.
9547 2015-04-24  Marek Polacek  <polacek@redhat.com>
9549         PR c/65830
9550         * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
9551         and OPT_Wshift_count_overflow.
9553         PR c/63357
9554         * c-common.c (warn_logical_operator): Warn if the operands have the
9555         same expressions.
9557 2015-04-24  Marek Polacek  <polacek@redhat.com>
9559         PR c/61534
9560         * c-common.c (warn_logical_operator): Bail if either operand comes
9561         from a macro expansion.
9563 2015-04-10  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
9565         PR target/55143
9566         * c-common.c (c_default_pointer_mode): Add definition.
9567         * c-common.h (c_default_pointer_mode): Add declaration.
9569 2015-03-11  Jakub Jelinek  <jakub@redhat.com>
9571         * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
9572         on record_builtin_type argument.
9574 2015-03-10  Jakub Jelinek  <jakub@redhat.com>
9576         PR c/65120
9577         * c-common.c (warn_logical_not_parentheses): Don't warn for
9578         !x == 0 or !x != 0.
9580 2015-03-07  Marek Polacek  <polacek@redhat.com>
9582         PR sanitizer/65280
9583         * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
9584         before trying to figure out whether we have a flexible array member.
9586 2015-03-06  Eric Botcazou  <ebotcazou@adacore.com>
9587             Jonathan Wakely  <jwakely.gcc@gmail.com>
9589         * c-ada-spec.c (dump_ada_double_name): Fix pasto.
9591 2015-03-05  Eric Botcazou  <ebotcazou@adacore.com>
9593         PR ada/65319
9594         * c-ada-spec.c (print_destructor): Remove obsolete code.
9596 2015-03-01  Eric Botcazou  <ebotcazou@adacore.com>
9598         * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
9599         (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
9600         DECL_TEMPLATE_RESULT emulations.
9601         (dump_ada_template)): Add guard for TYPE_METHODS.
9603 2015-02-27  Marek Polacek  <polacek@redhat.com>
9605         PR c/65040
9606         * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
9608 2015-02-27  Kai Tietz  <ktietz@redhat.com>
9610         PR c/35330
9611         * c-pragma.c (handle_pragma_weak): Do not try to create
9612         weak/alias of declarations not being function, or variable
9613         declarations.
9615 2015-02-24  Thomas Schwinge  <thomas@codesourcery.com>
9617         PR libgomp/64625
9618         * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
9619         Remove macros.
9620         (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
9622 2015-02-16  Marek Polacek  <polacek@redhat.com>
9624         PR c/65066
9625         * c-format.c (check_format_types): Handle null param.
9627 2015-02-13  Marek Polacek  <polacek@redhat.com>
9629         PR c/65040
9630         * c-format.c (check_format_types): Don't warn about different
9631         signedness if the original value is in the range of WANTED_TYPE.
9633 2015-02-12  Jason Merrill  <jason@redhat.com>
9635         PR c++/64956
9636         * c-opts.c (c_common_post_options): Change flag_abi_version from 0
9637         to the current highest version.
9638         * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
9640 2015-02-04  Jakub Jelinek  <jakub@redhat.com>
9642         PR c/64824
9643         PR c/64868
9644         * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
9645         instead of RDIV_EXPR.  Use build_binary_op instead of
9646         build2_loc.
9648 2015-01-30  Joseph Myers  <joseph@codesourcery.com>
9650         * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
9651         to pass input_location as first argument.
9653 2015-01-23  Tom de Vries  <tom@codesourcery.com>
9655         PR libgomp/64672
9656         * c.opt (fopenacc): Mark as LTO option.
9658 2015-01-23  Tom de Vries  <tom@codesourcery.com>
9660         PR libgomp/64707
9661         * c.opt (fopenmp): Mark as LTO option.
9663 2015-01-21  Jakub Jelinek  <jakub@redhat.com>
9665         PR c/63307
9666         * cilk.c (fill_decls_vec): Only put decls into vector v.
9667         (compare_decls): Fix up formatting.
9669 2015-01-21  Igor Zamyatin  <igor.zamyatin@intel.com>
9671         PR c/63307
9672         * cilk.c: Include vec.h.
9673         (struct cilk_decls): New structure.
9674         (wrapper_parm_cb): Split this function to...
9675         (fill_decls_vec): ...this...
9676         (create_parm_list): ...and this.
9677         (compare_decls): New function.
9678         (for_local_cb): Remove.
9679         (wrapper_local_cb): Ditto.
9680         (build_wrapper_type): For now first traverse and fill vector of
9681         declarations then sort it and then deal with sorted vector.
9682         (cilk_outline): Ditto.
9683         (declare_one_free_variable): Ditto.
9685 2015-01-21  Jason Merrill  <jason@redhat.com>
9687         PR c++/64629
9688         * c-format.c (check_format_arg): Call decl_constant_value.
9690 2015-01-19  Martin Liska  <mliska@suse.cz>
9692         * c-common.c (handle_noicf_attribute): New function.
9694 2015-01-15  Thomas Schwinge  <thomas@codesourcery.com>
9695             Bernd Schmidt  <bernds@codesourcery.com>
9696             James Norris  <jnorris@codesourcery.com>
9697             Cesar Philippidis  <cesar@codesourcery.com>
9698             Ilmir Usmanov  <i.usmanov@samsung.com>
9699             Jakub Jelinek  <jakub@redhat.com>
9701         * c.opt (fopenacc): New option.
9702         * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
9703         * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
9704         New macros.
9705         * c-common.h (c_finish_oacc_wait): New prototype.
9706         * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
9707         (c_finish_oacc_wait): New function.
9708         * c-pragma.c (oacc_pragmas): New variable.
9709         (c_pp_lookup_pragma, init_pragma): Handle it.
9710         * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
9711         PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
9712         PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
9713         PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
9714         (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
9715         PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
9716         PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
9717         PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
9718         PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
9719         PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
9720         PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
9721         PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
9722         PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
9723         PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
9724         PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
9725         PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
9726         PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
9727         PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
9728         PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
9729         PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
9730         PRAGMA_OACC_CLAUSE_WORKER.
9732 2015-01-14  Marcos Diaz  <marcos.diaz@tallertechnologies.com>
9734         * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
9735         for the new option fstack-protector_explicit.
9736         * c-common.c (c_common_attribute_table): Add stack_protect attribute.
9737         (handle_stack_protect_attribute): New function.
9739 2015-01-13  Martin Uecker  <uecker@eecs.berkeley.edu>
9741         * c.opt: New option -Warray-bounds=.
9743 2015-01-09  Michael Collison  <michael.collison@linaro.org>
9745         * array-notation-common.c: Include hash-set.h, machmode.h,
9746         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9747         fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
9748         * c-ada-spec.c: Ditto.
9749         * c-cilkplus.c: Ditto.
9750         * c-common.c: Include input.h due to flattening of tree.h.
9751         Define macro GCC_C_COMMON_C.
9752         * c-common.h: Flatten tree.h header files into c-common.h.
9753         Remove include of tree-core.h.
9754         * c-cppbuiltin.c: Include hash-set.h, machmode.h,
9755         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9756         fold-const.h, wide-int.h, and inchash.h due to
9757         flattening of tree.h.
9758         * c-dump.c: Ditto.
9759         * c-format.c: Flatten tree.h header files into c-common.h.
9760         * c-cppbuiltin.c: Include hash-set.h, machmode.h,
9761         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9762         fold-const.h, wide-int.h, and inchash.h due to
9763         flattening of tree.h.
9764         * c-dump.c: Include hash-set.h, machmode.h,
9765         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9766         fold-const.h, wide-int.h, and inchash.h due to
9767         flattening of tree.h.
9768         * c-format.c: Include hash-set.h, machmode.h,
9769         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9770         fold-const.h, wide-int.h, inchash.h and real.h due to
9771         flattening of tree.h.
9772         * c-gimplify.c: Include hash-set.h, machmode.h,
9773         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9774         fold-const.h, wide-int.h, and inchash.h due to
9775         flattening of tree.h.
9776         * cilk.c: Ditto.
9777         * c-lex.c: Ditto.
9778         * c-omp.c: Ditto.
9779         * c-opts.c: Ditto.
9780         * c-pch.c: Ditto.
9781         * c-ppoutput.c: Ditto.
9782         * c-pragma.c: Ditto.
9783         * c-pretty-print.c: Ditto.
9784         * c-semantics.c: Ditto.
9785         * c-ubsan.c: Ditto.
9786         * stub-objc.c: Ditto.
9788 2015-01-08  Jason Merrill  <jason@redhat.com>
9790         * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
9791         do_ubsan_in_current_function.
9792         (ubsan_maybe_instrument_reference_or_call): Likewise.
9793         * c-ubsan.h: Declare it.
9795 2015-01-08  Mike Stump  <mikestump@comcast.net>
9797         * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
9799 2015-01-07  Marek Polacek  <polacek@redhat.com>
9801         PR c/64440
9802         * c-common.c (c_fully_fold_internal): Warn for division and modulo
9803         if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
9805 2015-01-05  Trevor Saunders  <tsaunders@mozilla.com>
9807         PR c++/31397
9808         * c.opt (Wsuggest-override): New option.
9810 2015-01-05  Jakub Jelinek  <jakub@redhat.com>
9812         Update copyright years.
9814 2015-01-05  Marek Polacek  <polacek@redhat.com>
9816         PR c/64423
9817         * c-common.c (warn_array_subscript_with_type_char): Add location_t
9818         parameter.  Use it.
9819         * c-common.h (warn_array_subscript_with_type_char): Update
9820         declaration.
9822 2014-12-20  Edward Smith-Rowland  <3dw4rd@verizon.net>
9824         * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
9825         Control macro with flag_sized_deallocation.
9827 2014-12-20  Martin Uecker  <uecker@eecs.berkeley.edu>
9829         * c.opt (Wdiscarded-array-qualifiers): New option.
9831 2014-12-19  Jakub Jelinek  <jakub@redhat.com>
9833         PR preprocessor/63831
9834         * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
9835         and __has_cpp_attribute here.
9836         * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
9837         c_common_has_attribute.
9838         * c-common.h (c_common_has_attribute): New prototype.
9839         * c-lex.c (init_c_lex): Set cb->has_attribute to
9840         c_common_has_attribute instead of cb_has_attribute.
9841         (get_token_no_padding): New function.
9842         (cb_has_attribute): Renamed to ...
9843         (c_common_has_attribute): ... this.  No longer static.  Use
9844         get_token_no_padding, require ()s, don't build TREE_LIST
9845         unnecessarily, fix up formatting, adjust diagnostics, call
9846         init_attributes.
9848 2014-12-15  Jason Merrill  <jason@redhat.com>
9850         * c.opt (-fsized-deallocation, -Wc++14-compat): New.
9851         (-Wsized-deallocation): New.
9852         * c-opts.c (c_common_post_options): -fsized-deallocation defaults
9853         to on in C++14 and up.
9855 2014-12-11  Jason Merrill  <jason@redhat.com>
9857         * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
9859         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
9860         we aren't complaining about VLAs.
9862 2014-12-06  Marek Polacek  <polacek@redhat.com>
9864         PR tree-optimization/64183
9865         * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
9866         shift-expression if it is integer_type_node.  Use types_compatible_p.
9868 2014-11-29  Jakub Jelinek  <jakub@redhat.com>
9870         * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
9871         last argument from create_tmp_var_raw and create_tmp_var calls.
9872         * cilk.c (gimplify_cilk_spawn): Likewise.
9873         * c-omp.c (c_finish_omp_atomic): Likewise.
9875 2014-11-28  Marek Polacek  <polacek@redhat.com>
9877         * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
9878         instead of unsigned_type_node.
9880 2014-11-28  Marek Polacek  <polacek@redhat.com>
9882         PR c/63862
9883         * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
9884         to op1_utype.
9885         * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
9886         expression to unsigned_type_node.
9888 2014-11-20  Mark Wielaard  <mjw@redhat.com>
9890         PR debug/38757
9891         * c-opts.c (set_std_c89): Set lang_hooks.name.
9892         (set_std_c99): Likewise.
9893         (set_std_c11): Likewise.
9894         (set_std_cxx98): Likewise.
9895         (set_std_cxx11): Likewise.
9896         (set_std_cxx14): Likewise.
9897         (set_std_cxx1z): Likewise.
9899 2014-11-21  Jakub Jelinek  <jakub@redhat.com>
9901         PR target/63764
9902         * c-common.h (convert_vector_to_pointer_for_subscript): Change
9903         return type to bool.
9904         * c-common.c: Include gimple-expr.h.
9905         (convert_vector_to_pointer_for_subscript): Change return type to
9906         bool.  If *vecp is not lvalue_p and has VECTOR_TYPE, return true
9907         and copy it into a TARGET_EXPR and use that instead of *vecp
9908         directly.
9910 2014-11-19  David Malcolm  <dmalcolm@redhat.com>
9912         Merger of git branch "gimple-classes-v2-option-3".
9913         * ChangeLog.gimple-classes: New.
9914         * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
9915         from being just a vec<gimple> to a vec<gbind *>.
9917 2014-11-18  Jakub Jelinek  <jakub@redhat.com>
9919         PR sanitizer/63813
9920         * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
9921         argument to ptype, set type to TREE_TYPE (ptype).  Don't call
9922         get_pointer_alignment for non-pointers.  Use ptype, or if it is
9923         reference type, corresponding pointer type, as type of kind
9924         argument.
9925         (ubsan_maybe_instrument_reference,
9926         ubsan_maybe_instrument_member_call): Adjust callers.
9928 2014-11-15  Marek Polacek  <polacek@redhat.com>
9930         PR middle-end/63884
9931         * array-notation-common.c (is_sec_implicit_index_fn): Return false
9932         for NULL fndecl.
9933         (extract_array_notation_exprs): Return for NULL node.
9935 2014-11-12  Joseph Myers  <joseph@codesourcery.com>
9937         * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
9938         undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
9940 2014-11-12  Jakub Jelinek  <jakub@redhat.com>
9942         PR c/59708
9943         * c-common.c (check_builtin_function_arguments): Handle
9944         BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
9946 2014-11-10  Andi Kleen  <ak@linux.intel.com>
9948         PR c/60804
9949         * c-common.h (check_no_cilk): Declare.
9950         * cilk.c (get_error_location): New function.
9951         (check_no_cilk): Dito.
9953 2014-11-10  Andi Kleen  <ak@linux.intel.com>
9955         * cilk.c (recognize_spawn): Use expression location
9956         for error message.
9958 2014-11-10  Paolo Carlini  <paolo.carlini@oracle.com>
9960         * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
9962 2014-11-10  Edward Smith-Rowland  <3dw4rd@verizon.net>
9964         * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
9965         (__cpp_rtti, __cpp_exceptions): New macros for C++98;
9966         (__cpp_range_based_for, __cpp_initializer_lists,
9967         __cpp_delegating_constructors, __cpp_nsdmi,
9968         __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
9969         for C++11; (__cpp_attribute_deprecated): Remove in favor of
9970         __has_cpp_attribute.
9971         * c-lex.c (cb_has_attribute): New callback CPP function;
9972         (init_c_lex): Set has_attribute callback.
9974 2014-11-04  Richard Biener  <rguenther@suse.de>
9976         * c-common.c (shorten_compare): Do not shorten mixed
9977         DFP and non-DFP compares.
9979 2014-11-01  Edward Smith-Rowland  <3dw4rd@verizon.net>
9981         * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
9982         * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
9983         Commentary and rearrangement of tests.
9984         * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
9985         Commentary and rearrangement of tests.
9986         * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
9987         * g++.dg/cpp1y/feat-cxx98.C: Commentary.
9989 2014-10-29  Richard Sandiford  <richard.sandiford@arm.com>
9991         * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
9992         enum from machine_mode.
9994 2014-10-28  Andrew MacLeod  <amacleod@redhat.com>
9996         * c-common.c: Adjust include files.
9997         * c-gimplify.c: Ditto.
9998         * cilk.c: Ditto.
9999         * c-pragma.c: Ditto.
10000         * c-ubsan.c: Ditto.
10002 2014-10-27  Andrew MacLeod  <amacleod@redhat.com>
10004         * c-gimplify.c: Adjust include files.
10006 2014-10-26  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10008         PR c++/53061
10009         * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
10010         c_common_initialize_diagnostics.
10011         * c-common.h: Likewise.
10013 2014-10-24  Marek Polacek  <polacek@redhat.com>
10015         PR c/56980
10016         * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
10017         print "struct"/"union"/"enum" for typedefed names.
10019 2014-10-23  Marek Polacek  <polacek@redhat.com>
10021         * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
10022         in unsigned type.
10024 2014-10-22  Jakub Jelinek  <jakub@redhat.com>
10025             Yury Gribov  <y.gribov@samsung.com>
10027         * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
10028         ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
10029         instead of flag_sanitize_recover as bool flag.
10031 2014-10-21  Kirill Yukhin  <kirill.yukhin@intel.com>
10033         * cilk.c: Revert previous change.
10035 2014-10-20  Igor Zamyatin  <igor.zamyatin@intel.com>
10037         PR c/63307
10038         * cilk.c: Include vec.h.
10039         (struct cilk_decls): New structure.
10040         (wrapper_parm_cb): Split this function to...
10041         (fill_decls_vec): ...this...
10042         (create_parm_list): ...and this.
10043         (compare_decls): New function.
10044         (for_local_cb): Remove.
10045         (wrapper_local_cb): Ditto.
10046         (build_wrapper_type): For now first traverse and fill vector of
10047         declarations then sort it and then deal with sorted vector.
10048         (cilk_outline): Ditto.
10049         (declare_one_free_variable): Ditto.
10051 2014-10-17  Marek Polacek  <polacek@redhat.com>
10053         * c-opts.c (c_common_post_options): Set warn_implicit_int.
10054         * c.opt (Wimplicit-int): Initialize to -1.
10056 2014-10-16  Andrew MacLeod  <amacleod@redhat.com>
10058         * c-pragma.c: Adjust include files.
10059         * c-semantics.c: Likewise.
10061 2014-10-16  DJ Delorie  <dj@redhat.com>
10063         * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
10064         multiples of bytes.
10066 2014-10-14  Jason Merrill  <jason@redhat.com>
10068         PR c++/63455
10069         * c-common.h (CPP_PREPARSED_EXPR): New.
10070         (N_CP_TTYPES): Adjust.
10072 2014-10-15  Marek Polacek  <polacek@redhat.com>
10074         * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
10076 2014-10-14  DJ Delorie  <dj@redhat.com>
10078         * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
10079         types, not just __int128.
10080         * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
10081         types, not just __int128.
10082         (cpp_atomic_builtins): Round pointer sizes up.
10083         (type_suffix): Use type precision, not specific types.
10084         * c-common.c (c_common_reswords): Remove __int128 special case.
10085         (c_common_type_for_size): Check for all __intN types, not just
10086         __int128.
10087         (c_common_type_for_mode): Likewise.
10088         (c_common_signed_or_unsigned_type): Likewise.
10089         (c_build_bitfield_integer_type): Likewise.
10090         (c_common_nodes_and_builtins): Likewise.
10091         (keyword_begins_type_specifier): Likewise.
10092         * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
10093         __intN variants.
10095 2014-10-12  Trevor Saunders  <tsaunders@mozilla.com>
10097         * c-common.c: Use hash_table instead of hashtab.
10099 2014-10-06  Edward Smith-Rowland  <3dw4rd@verizon.net>
10101         * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
10102         C++11 section.
10104 2014-10-03  Marc Glisse  <marc.glisse@inria.fr>
10106         PR c++/54427
10107         PR c++/57198
10108         PR c++/58845
10109         * c-common.c (warn_logical_operator): Punt for vectors.
10111 2014-10-01  Edward Smith-Rowland  <3dw4rd@verizon.net>
10113         Implement SD-6: SG10 Feature Test Recommendations
10114         * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
10115         macros and the __has_header macro.
10117 2014-09-30  Jason Merrill  <jason@redhat.com>
10119         * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
10120         RID_IS_TRIVIALLY_CONSTRUCTIBLE.
10121         * c-common.c (c_common_reswords): Add __is_trivially_copyable.
10123         * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
10124         * c-common.c (c_common_reswords): Add __is_trivially_copyable.
10126         * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
10127         * c-common.c (c_common_reswords): Remove __is_convertible_to.
10129 2014-09-24  Marek Polacek  <polacek@redhat.com>
10131         PR c/61405
10132         PR c/53874
10133         * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
10135 2014-09-23  Andi Kleen  <ak@linux.intel.com>
10137         * c-common.c (handle_no_reorder_attribute): New function.
10138         (c_common_attribute_table): Add no_reorder attribute.
10140 2014-09-22  Joseph Myers  <joseph@codesourcery.com>
10142         * c-cppbuiltin.c (c_cpp_builtins): Define
10143         __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
10144         modes.
10146 2014-09-18  Joseph Myers  <joseph@codesourcery.com>
10148         * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
10149         for supported floating-point modes.
10151 2014-09-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10153         * c.opt (Wpsabi): Use LangEnabledBy.
10154         * c-opts.c (c_common_handle_option): Do not handle here.
10156 2014-09-12  Joseph Myers  <joseph@codesourcery.com>
10158         * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
10159         macros for floating-point modes.
10161 2014-09-11  Marc Glisse  <marc.glisse@inria.fr>
10163         PR target/58757
10164         * c-cppbuiltin.c (builtin_define_float_constants): Correct
10165         __*_DENORM_MIN__ without denormals.
10167 2014-09-10  Jakub Jelinek  <jakub@redhat.com>
10169         * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
10170         ubsan_instrument_vla, ubsan_instrument_return): Adjust
10171         ubsan_create_data callers.
10172         (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
10173         index is constant or BIT_AND_EXPR with constant mask and is
10174         small enough for the bound.
10175         * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
10176         ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
10178 2014-09-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10180         * c.opt: Add CppReason to various flags.
10181         (Wdate-time): Re-sort.
10182         * c-common.c: Include c-common.h earlier.
10183         (struct reason_option_codes_t): Delete.
10184         (c_option_controlling_cpp_error): Prefix global type and struct
10185         with cpp_.
10187 2014-09-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10189         * c.opt (Wnormalized): New.
10190         (Wnormalized=): Use Enum and Reject Negative.
10191         * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
10193 2014-09-08  Joseph Myers  <joseph@codesourcery.com>
10195         * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
10196         digits of floating-point modes if -fbuilding-libgcc.
10198 2014-09-05  Joseph Myers  <joseph@codesourcery.com>
10200         * c-cppbuiltin.c (c_cpp_builtins): Also define
10201         __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
10202         __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
10203         __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
10204         __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
10205         __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
10206         __LIBGCC_STACK_GROWS_DOWNWARD__,
10207         __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
10208         __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
10209         __LIBGCC_DWARF_FRAME_REGISTERS__,
10210         __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
10211         __LIBGCC_STACK_POINTER_REGNUM__ and
10212         __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
10213         (builtin_define_with_value): Handle backslash-escaping in string
10214         macro values.
10216 2014-09-05  Richard Biener  <rguenther@suse.de>
10218         PR middle-end/63148
10219         * c-format.c (check_format_arg): Properly handle
10220         effectively signed POINTER_PLUS_EXPR offset.
10222 2014-09-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10224         * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
10225         Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
10226         (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
10227         and Init.
10228         * c-opts.c (c_common_handle_option): Do not handle here.
10229         (sanitize_cpp_opts): Likewise.
10230         * c-common.c (struct reason_option_codes_t): Handle
10231         CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
10233 2014-09-03  Marek Polacek  <polacek@redhat.com>
10235         * c.opt (Wlogical-not-parentheses): Enable by -Wall.
10237 2014-09-02  Jakub Jelinek  <jakub@redhat.com>
10238             Balaji V. Iyer  <balaji.v.iyer@intel.com>
10239             Igor Zamyatin  <igor.zamyatin@intel.com>
10241         * c-cilkplus.c (cilk_for_number_of_iterations): New function.
10242         * c-common.c (c_common_reswords): Added _Cilk_for.
10243         * c-common.h (enum rid): Added RID_CILK_FOR.
10244         (cilk_for_number_of_iterations): Add declaration.
10245         * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
10246         CILK_FOR.
10247         * c-pragma.c (init_pragma): Register "grainsize" pragma.
10248         * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
10250 2014-08-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10252         * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
10253         Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
10254         Wundef): Use CPP, Var and Init.
10255         * c-opts.c (c_common_handle_option): Do not handle the above flags here.
10257 2014-08-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10259         * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
10260         * c-opts.c (c_common_handle_option): Do not handle here.
10262 2014-08-25  Jason Merrill  <jason@redhat.com>
10264         * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
10265         -std=c++14 and -std=gnu++14, rather than the reverse.
10266         * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
10267         OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
10268         * c-common.h (cxx_dialect): Remove cxx1y.
10270 2014-08-23  Edward Smith-Rowland  <3dw4rd@verizon.net>
10272         * c-common.h (enum cxx_dialect): Add cxx14.
10273         * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
10274         * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
10275         cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
10277 2014-08-22  Jason Merrill  <jason@redhat.com>
10279         * c.opt (std=gnu++17): Fix alias.
10281 2014-08-22  Marek Polacek  <polacek@redhat.com>
10283         PR c++/62199
10284         * c-common.c (warn_logical_not_parentheses): Don't check LHS.  Don't
10285         check for vector types.  Drop LHS argument.
10286         * c-common.h (warn_logical_not_parentheses): Adjust.
10288 2014-08-22  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10290         * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
10291         (Wmultichar): Likewise.
10292         (Wdate-time): Use C-family languages instead of Common. Use CPP
10293         and Var.
10294         * c-opts.c (c_common_handle_option): Do not handle the above
10295         options here.
10296         (sanitize_cpp_opts): Likewise.
10298 2014-08-21  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10300         PR fortran/44054
10301         * c-opts.c: Include tree-diagnostics.h.
10302         (c_diagnostic_finalizer): New.
10303         (c_common_initialize_diagnostics): Use it.
10305 2014-08-20  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10307         PR preprocessor/51303
10308         * c-common.c (struct reason_option_codes_t option_codes):
10309         Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
10311 2014-08-20  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10313         PR c/60975
10314         PR c/53063
10315         * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
10316         * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
10317         (c_common_post_options): Call init_global_opts_from_cpp.
10318         (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
10320 2014-08-19  Marek Polacek  <polacek@redhat.com>
10322         PR c++/62153
10323         * c-common.c (maybe_warn_bool_compare): New function.
10324         * c-common.h (maybe_warn_bool_compare): Declare.
10325         * c.opt (Wbool-compare): New option.
10327 2014-08-19  Marek Polacek  <polacek@redhat.com>
10329         * c.opt (Wc99-c11-compat): New option.
10331 2014-08-19  Marek Polacek  <polacek@redhat.com>
10333         * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
10334         to warn_c90_c99_compat.
10335         * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
10336         to -1.
10338 2014-08-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10339             Steven Bosscher  <steven@gcc.gnu.org>
10341         PR c/52952
10342         * c-format.c: Add extra_arg_loc and format_string_loc to struct
10343         format_check_results.
10344         (check_function_format): Use true and add comment for boolean
10345         argument.
10346         (finish_dollar_format_checking): Use explicit location when warning.
10347         (check_format_info): Likewise.
10348         (check_format_arg): Set extra_arg_loc and format_string_loc.
10349         (check_format_info_main): Use explicit location when warning.
10350         (check_format_types): Pass explicit location.
10351         (format_type_warning): Likewise.
10353 2014-08-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
10355         PR fortran/44054
10356         * c-format.c: Handle Fortran flags.
10358 2014-08-12  Igor Zamyatin  <igor.zamyatin@intel.com>
10360         PR other/61962
10361         * array-notation-common.c (find_rank): Added handling for other
10362         types of references.
10364 2014-08-10  Marek Polacek  <polacek@redhat.com>
10366         PR c/51849
10367         * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
10368         * c.opt (Wc90-c99-compat): Add option.
10370 2014-08-07  Trevor Saunders  <tsaunders@mozilla.com>
10372         * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
10374 2014-08-03  Marek Polacek  <polacek@redhat.com>
10376         * c-common.c (check_case_value): Add location_t parameter.  Use it.
10377         (c_add_case_label): Pass loc to check_case_value.
10379 2014-08-02  Trevor Saunders  <tsaunders@mozilla.com>
10381         * cilk.c: Use hash_map instead of pointer_map.
10383 2014-08-02  Trevor Saunders  <tsaunders@mozilla.com>
10385         * c-gimplify.c: Use hash_set instead of pointer_set.
10387 2014-08-01  Igor Zamyatin  <igor.zamyatin@intel.com>
10389         PR middle-end/61455
10390         * array-notation-common.c (extract_array_notation_exprs): Handling
10391         of DECL_EXPR added.
10393 2014-08-01  Jakub Jelinek  <jakub@redhat.com>
10395         * c-common.h (min_align_of_type): Removed prototype.
10396         * c-common.c (min_align_of_type): Removed.
10397         * c-ubsan.h (ubsan_maybe_instrument_reference,
10398         ubsan_maybe_instrument_member_call): New prototypes.
10399         * c-ubsan.c: Include stor-layout.h and builtins.h.
10400         (ubsan_maybe_instrument_reference_or_call,
10401         ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
10402         functions.
10404 2014-07-31  Marc Glisse  <marc.glisse@inria.fr>
10406         PR c++/60517
10407         * c.opt (-Wreturn-local-addr): Move to common.opt.
10409 2014-07-30  Jason Merrill  <jason@redhat.com>
10411         PR c++/61659
10412         PR c++/61687
10413         Revert:
10414         * c.opt (-fuse-all-virtuals): New.
10416 2014-07-30  Tom Tromey  <tromey@redhat.com>
10418         PR c/59855
10419         * c.opt (Wdesignated-init): New option.
10420         * c-common.c (c_common_attribute_table): Add "designated_init".
10421         (handle_designated_init): New function.
10423 2014-07-24  Marek Polacek  <polacek@redhat.com>
10425         PR c/57653
10426         * c-opts.c (c_finish_options): If -imacros is in effect, return.
10428 2014-07-16  Dodji Seketeli  <dodji@redhat.com>
10430         PR preprocessor/60723 - missing system-ness marks for macro tokens
10431         * c-ppoutput.c (struct print::prev_was_system_token): New data
10432         member.
10433         (init_pp_output): Initialize it.
10434         (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
10435         (do_line_change): Return a flag saying if a line marker was
10436         emitted or not.
10437         (scan_translation_unit): Detect if the system-ness of the token we
10438         are about to emit is different from the one of the previously
10439         emitted token.  If so, emit a line marker.  Avoid emitting useless
10440         adjacent line markers.  Avoid emitting line markers for tokens
10441         originating from the expansion of built-in macros.
10442         (scan_translation_unit_directives_only): Adjust.
10444 2014-07-15  Marek Polacek  <polacek@redhat.com>
10446         * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
10447         TYPE_MAX_VALUE is NULL.
10449 2014-07-14  Jakub Jelinek  <jakub@redhat.com>
10451         PR middle-end/61294
10452         * c.opt (Wmemset-transposed-args): New warning.
10454 2014-07-10  Jason Merrill  <jason@redhat.com>
10456         PR c++/61659
10457         PR c++/61687
10458         * c.opt (-fuse-all-virtuals): New.
10460 2014-07-09  Richard Biener  <rguenther@suse.de>
10462         PR c-family/61741
10463         * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
10464         using unsigned arithmetic if overflow does not wrap instead of
10465         if overflow is undefined.
10467 2014-07-06  Marek Polacek  <polacek@redhat.com>
10469         PR c/6940
10470         * c.opt (Wsizeof-array-argument): New option.
10472 2014-07-03  Jakub Jelinek  <jakub@redhat.com>
10474         * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
10475         comments->count <= 1, as comments->entries might be NULL.
10477 2014-07-01  Marek Polacek  <polacek@redhat.com>
10479         * c.opt (Wint-conversion): New option.
10481 2014-07-01  Marek Polacek  <polacek@redhat.com>
10483         PR c/58286
10484         * c.opt (Wincompatible-pointer-types): New option.
10486 2014-06-30  Paolo Carlini  <paolo.carlini@oracle.com>
10488         PR c++/51400
10489         * c-common.c (handle_noreturn_attribute, handle_const_attribute):
10490         Do not discard TYPE_QUALS of type.
10492 2014-06-26  Jason Merrill  <jason@redhat.com>
10494         * c-common.h (enum cxx_dialect): Add cxx1z.
10495         * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
10496         * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
10498 2014-06-26  Teresa Johnson  <tejohnson@google.com>
10500         * c-common.h (get_dump_info): Declare.
10501         * c-gimplify.c (c_genericize): Use saved dump files.
10502         * c-opts.c (c_common_parse_file): Begin and end dumps
10503         once around parsing invocation.
10504         (get_dump_info): New function.
10506 2014-06-23  Marek Polacek  <polacek@redhat.com>
10507             Andrew MacLeod  <amacleod@redhat.com>
10509         PR c/61553
10510         * c-common.c (get_atomic_generic_size): Don't segfault if the
10511         type doesn't have a size.
10513 2014-06-20  Marek Polacek  <polacek@redhat.com>
10515         * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
10516         (ubsan_walk_array_refs_r): New function.
10517         (c_genericize): Instrument array bounds.
10518         * c-ubsan.c: Include "internal-fn.h".
10519         (ubsan_instrument_division): Mark instrumented arrays as having
10520         side effects.  Adjust ubsan_type_descriptor call.
10521         (ubsan_instrument_shift): Likewise.
10522         (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
10523         (ubsan_instrument_bounds): New function.
10524         (ubsan_array_ref_instrumented_p): New function.
10525         (ubsan_maybe_instrument_array_ref): New function.
10526         * c-ubsan.h (ubsan_instrument_bounds): Declare.
10527         (ubsan_array_ref_instrumented_p): Declare.
10528         (ubsan_maybe_instrument_array_ref): Declare.
10530 2014-06-20  Hale Wang  <hale.wang@arm.com>
10532         PR lto/61123
10533         * c.opt (fshort-enums): Add to LTO.
10534         * c.opt (fshort-wchar): Likewise.
10536 2014-06-16  Marek Polacek  <polacek@redhat.com>
10538         PR c/60439
10539         * c.opt (Wswitch-bool): Add Var.
10541 2014-06-12  Jakub Jelinek  <jakub@redhat.com>
10543         PR middle-end/61486
10544         * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
10545         #pragma omp target teams or
10546         #pragma omp {,target }teams distribute simd.
10548 2014-06-12  Jason Merrill  <jason@redhat.com>
10550         * c.opt (Wabi=, fabi-compat-version): New.
10551         * c-opts.c (c_common_handle_option): Handle -Wabi=.
10552         (c_common_post_options): Handle flag_abi_compat_version default.
10553         Disallow -fabi-compat-version=1.
10554         * c-common.h (abi_version_crosses): New.
10556 2014-06-11  Jan Hubicka  <hubicka@ucw.cz>
10558         * c-common.c (handle_section_attribute): Update handling for
10559         section names that are no longer trees.
10561 2014-06-10  Jakub Jelinek  <jakub@redhat.com>
10563         PR fortran/60928
10564         * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
10565         (omp_pragmas): ... back here.
10567 2014-06-05  Marek Polacek  <polacek@redhat.com>
10569         PR c/49706
10570         * c-common.c (warn_logical_not_parentheses): New function.
10571         * c-common.h (warn_logical_not_parentheses): Declare.
10572         * c.opt (Wlogical-not-parentheses): New option.
10574 2014-06-04  Marek Polacek  <polacek@redhat.com>
10576         PR c/30020
10577         * c-common.c (check_case_bounds): Add location parameter.
10578         Use it.
10579         (c_add_case_label): Pass loc to check_case_bounds.
10581 2014-06-03  Marek Polacek  <polacek@redhat.com>
10583         PR c/60439
10584         * c.opt (Wswitch-bool): New option.
10586 2014-05-22  Thomas Schwinge  <thomas@codesourcery.com>
10588         * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
10589         Remove prototypes.
10590         (record_types_used_by_current_var_decl): Move prototype to where
10591         it belongs.
10593         * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
10594         (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
10595         (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
10597 2014-05-21  Richard Sandiford  <rsandifo@linux.vnet.ibm.com>
10599         * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
10600         * c-common.c (c_common_nodes_and_builtins): Don't initialize
10601         void_zero_node.
10602         * c-pretty-print.c (pp_c_void_constant): New function.
10603         (c_pretty_printer::constant, c_pretty_printer::primary_expression)
10604         (c_pretty_printer::expression): Handle VOID_CST.
10605         * cilk.c (extract_free_variables): Likewise.
10606         * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
10607         (ubsan_instrument_vla): Use void_node instead of void_zero_node.
10609 2014-05-17  Trevor Saunders  <tsaunders@mozilla.com>
10611         * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
10612         * c-pragma.c (push_alignment): Adjust.
10613         (handle_pragma_push_options): Likewise.
10615 2014-05-09  Marek Polacek  <polacek@redhat.com>
10617         PR c/50459
10618         * c-common.c (check_user_alignment): Return -1 if alignment is error
10619         node.
10620         (handle_aligned_attribute): Don't call default_conversion on
10621         FUNCTION_DECLs.
10622         (handle_vector_size_attribute): Likewise.
10623         (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
10624         (handle_sentinel_attribute): Call default_conversion and allow even
10625         integral types as an argument.
10627 2014-05-08  Marek Polacek  <polacek@redhat.com>
10629         PR c/61053
10630         * c-common.c (min_align_of_type): New function factored out from...
10631         (c_sizeof_or_alignof_type): ...here.
10632         * c-common.h (min_align_of_type): Declare.
10634 2014-05-08  Marek Polacek  <polacek@redhat.com>
10636         PR c/61077
10637         * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
10638         parameter type of main.
10640 2014-05-07  DJ Delorie  <dj@redhat.com>
10642         * c-cppbuiltin.c (print_bits_of_hex): New.
10643         (builtin_define_type_minmax): Print values using hex so as not to
10644         require a pre-computed list of string values.
10646 2014-05-06  Kenneth Zadeck  <zadeck@naturalbridge.com>
10647             Mike Stump  <mikestump@comcast.net>
10648             Richard Sandiford  <rdsandiford@googlemail.com>
10650         * c-ada-spec.c: Include wide-int.h.
10651         (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
10652         (dump_generic_ada_node): Use wide-int interfaces.
10653         * c-common.c: Include wide-int-print.h.
10654         (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
10655         (pointer_int_sum): Use wide-int interfaces.
10656         (c_common_nodes_and_builtins): Use make_int_cst.
10657         (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
10658         (handle_alloc_size_attribute): Use wide-int interfaces.
10659         (get_nonnull_operand): Likewise.
10660         * c-format.c (get_constant): Use tree_fits_uhwi_p.
10661         * c-lex.c: Include wide-int.h.
10662         (narrowest_unsigned_type): Take a widest_int rather than two
10663         HOST_WIDE_INTs.
10664         (narrowest_signed_type): Likewise.
10665         (interpret_integer): Update accordingly.  Use wide-int interfaces.
10666         (lex_charconst): Use wide-int interfaces.
10667         * c-pretty-print.c: Include wide-int.h.
10668         (pp_c_integer_constant): Use wide-int interfaces.
10669         * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
10670         INT_CST_LT_UNSIGNED.
10672 2014-05-06  Richard Biener  <rguenther@suse.de>
10674         * c-opts.c (c_common_post_options): For -freestanding,
10675         -fno-hosted and -fno-builtin disable pattern recognition
10676         if not enabled explicitely.
10678 2014-05-02  Marek Polacek  <polacek@redhat.com>
10680         * c.opt (Wsizeof-pointer-memaccess): Describe option.
10682 2014-05-01  Marek Polacek  <polacek@redhat.com>
10684         PR c/43245
10685         * c.opt (Wdiscarded-qualifiers): Add.
10687 2014-04-30  Marek Polacek  <polacek@redhat.com>
10689         * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs.  Perform
10690         INT_MIN / -1 sanitization only for integer types.
10692 2014-04-25  Marek Polacek  <polacek@redhat.com>
10694         PR c/18079
10695         * c-common.c (handle_noinline_attribute): Warn if the attribute
10696         conflicts with always_inline attribute.
10697         (handle_always_inline_attribute): Warn if the attribute conflicts
10698         with noinline attribute.
10700 2014-04-25  Marek Polacek  <polacek@redhat.com>
10702         PR c/60156
10703         * c-common.c (check_main_parameter_types): Warn about variadic main.
10705 2014-04-24  Mike Stump  <mikestump@comcast.net>
10707         * c.opt (Wshadow-ivar): Default to on.
10709 2014-04-24  Dimitris Papavasiliou  <dpapavas@gmail.com>
10711         * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
10713 2014-04-23  Marek Polacek  <polacek@redhat.com>
10715         * c-common.c (handle_tm_wrap_attribute): Tweak error message.
10717 2014-04-22  Jakub Jelinek  <jakub@redhat.com>
10719         PR sanitizer/60275
10720         * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
10721         if flag_sanitize_undefined_trap_on_error.
10722         (ubsan_instrument_division, ubsan_instrument_shift,
10723         ubsan_instrument_vla): Likewise.  Use __ubsan_handle_*_abort ()
10724         if !flag_sanitize_recover.
10726 2014-04-22  Marc Glisse  <marc.glisse@inria.fr>
10728         PR libstdc++/43622
10729         * c-common.c (registered_builtin_types): Make non-static.
10730         * c-common.h (registered_builtin_types): Declare.
10732 2014-04-14  Richard Biener  <rguenther@suse.de>
10733             Marc Glisse  <marc.glisse@inria.fr>
10735         PR c/60819
10736         * c-common.c (convert_vector_to_pointer_for_subscript): Properly
10737         apply may-alias the scalar pointer type when applicable.
10739 2014-04-12  Igor Zamyatin  <igor.zamyatin@intel.com>
10741         PR middle-end/60467
10742         * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
10743         as possible argument for Cilk_spawn.
10745 2014-04-11  Tobias Burnus  <burnus@net-b.de>
10747         PR c/60194
10748         * c.opt (Wformat-signedness): Add
10749         * c-format.c(check_format_types): Use it.
10751 2014-04-11  Jason Merrill  <jason@redhat.com>
10753         PR c++/57926
10754         * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
10755         default_conversion for an array argument.
10757 2014-04-08  Marek Polacek  <polacek@redhat.com>
10759         PR sanitizer/60745
10760         * c-ubsan.c: Include asan.h.
10761         (ubsan_instrument_return): Call initialize_sanitizer_builtins.
10763 2014-04-03  Nathan Sidwell  <nathan@codesourcery.com>
10765         * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
10767 2014-04-02  Marek Polacek  <polacek@redhat.com>
10769         * c-common.h (c_expand_expr): Remove declaration.
10771 2014-03-28  Jakub Jelinek  <jakub@redhat.com>
10773         PR c++/60689
10774         * c-common.c (add_atomic_size_parameter): When creating new
10775         params vector, push the size argument first.
10777 2014-03-26  Jakub Jelinek  <jakub@redhat.com>
10779         * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
10780         ubsan_instrument_vla, ubsan_instrument_return): Adjust
10781         ubsan_create_data callers.
10783 2014-03-22  Jakub Jelinek  <jakub@redhat.com>
10785         PR debug/60603
10786         * c-opts.c (c_finish_options): Restore cb_file_change call to
10787         <built-in>.
10789 2014-03-13  Jakub Jelinek  <jakub@redhat.com>
10791         PR middle-end/36282
10792         * c-pragma.c (apply_pragma_weak): Only look at
10793         TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
10794         DECL_ASSEMBLER_NAME_SET_P (decl).
10795         (maybe_apply_pending_pragma_weaks): Exit early if
10796         vec_safe_is_empty (pending_weaks) rather than only when
10797         !pending_weaks.
10798         (maybe_apply_pragma_weak): Likewise.  If !DECL_ASSEMBLER_NAME_SET_P,
10799         set assembler name back to NULL afterwards.
10801 2014-03-11  Jason Merrill  <jason@redhat.com>
10803         * c.opt: Add -std=gnu++14.
10805 2014-03-11  Ian Bolton  <ian.bolton@arm.com>
10807         * c-opts.c (c_common_post_options): Don't override
10808         -ffp-contract=fast if unsafe-math-optimizations is on.
10810 2014-03-08  Paulo Matos  <paulo@matos-sorge.com>
10812         * c.opt: Enable LTO FE for fshort-double.
10814 2014-03-07  Jason Merrill  <jason@redhat.com>
10816         * c.opt: Add -std=c++14.
10818 2014-03-06  Marek Polacek  <polacek@redhat.com>
10820         PR c/60197
10821         * cilk.c (contains_cilk_spawn_stmt): New function.
10822         (contains_cilk_spawn_stmt_walker): Likewise.
10823         (recognize_spawn): Give error on invalid use of _Cilk_spawn.
10824         * c-common.h (contains_cilk_spawn_stmt): Add declaration.
10826 2014-03-03  Jakub Jelinek  <jakub@redhat.com>
10828         * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
10829         (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
10830         even when flag_preprocess_only.
10832 2014-02-26  Jason Merrill  <jason@redhat.com>
10834         PR c++/59231
10835         PR c++/11586
10836         * c-common.c (shorten_compare): Don't check
10837         c_inhibit_evaluation_warnings.
10839 2014-02-19  Jakub Jelinek  <jakub@redhat.com>
10841         PR c/37743
10842         * c-common.c (c_common_nodes_and_builtins): When initializing
10843         c_uint{16,32,64}_type_node, also set corresponding
10844         uint{16,32,64}_type_node to the same value.
10846         PR c++/60267
10847         * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
10848         for PRAGMA_IVDEP if flag_preprocess_only.
10850 2014-02-12  Jakub Jelinek  <jakub@redhat.com>
10852         PR c/60101
10853         * c-common.c (merge_tlist): If copy is true, call new_tlist,
10854         if false, add ADD itself, rather than vice versa.
10855         (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
10856         copy.  For SAVE_EXPR, only call merge_tlist once.
10858 2014-02-08  Jakub Jelinek  <jakub@redhat.com>
10860         PR middle-end/60092
10861         * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
10862         and tree_to_uhwi.
10863         (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
10864         functions.
10865         (c_common_attribute_table): Add alloc_align and assume_aligned
10866         attributes.
10868 2014-02-06  Marek Polacek  <polacek@redhat.com>
10870         PR c/60087
10871         * c-common.c (warn_for_sign_compare): Call warning_at with location
10872         instead of warning.
10874 2014-02-05  Marek Polacek  <polacek@redhat.com>
10876         PR c/53123
10877         * c-omp.c (c_finish_omp_atomic): Remove unreachable return
10878         statement.
10880 2014-02-04  Marek Polacek  <polacek@redhat.com>
10882         PR c/60036
10883         * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
10884         SAVE_EXPR.
10886 2014-02-03  Marc Glisse  <marc.glisse@inria.fr>
10888         PR c++/53017
10889         PR c++/59211
10890         * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
10891         handle_vector_size_attribute, handle_nonnull_attribute): Call
10892         default_conversion on the attribute argument.
10893         (handle_nonnull_attribute): Increment the argument number.
10895 2014-01-31  Marek Polacek  <polacek@redhat.com>
10897         PR c/59963
10898         * c-common.c (add_atomic_size_parameter): Pass vNULL to
10899         build_function_call_vec.
10900         (resolve_overloaded_builtin): Likewise.
10901         * c-common.h (build_function_call_vec): Adjust declaration.
10903 2014-01-30  Marek Polacek  <polacek@redhat.com>
10905         PR c/59940
10906         * c-common.h (unsafe_conversion_p): Adjust declaration.
10907         (warnings_for_convert_and_check): Likewise.
10908         (convert_and_check): Likewise.
10909         * c-common.c (unsafe_conversion_p): Add location parameter.  Call
10910         expansion_point_location_if_in_system_header on it.
10911         (warnings_for_convert_and_check): Add location parameter.  Call
10912         expansion_point_location_if_in_system_header on it.  Use it.
10913         (convert_and_check): Add location parameter.  Use it.
10914         (conversion_warning): Likewise.
10915         (c_add_case_label): Adjust convert_and_check calls.
10916         (scalar_to_vector): Adjust unsafe_conversion_p calls.
10918 2014-01-24  Balaji V. Iyer  <balaji.v.iyer@intel.com>
10920         * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
10921         flag_cilkplus.
10922         * c-pragma.c (init_pragma): Likewise.
10923         * c.opt: Likewise.
10925 2014-01-23  Marek Polacek  <polacek@redhat.com>
10927         PR c/59846
10928         * c-common.c (shorten_compare): Add location_t parameter.
10929         * c-common.h (shorten_binary_op): Adjust declaration.
10931 2014-01-23  Marek Polacek  <polacek@redhat.com>
10933         PR c/58346
10934         * c-common.c (pointer_to_zero_sized_aggr_p): New function.
10935         * c-common.h: Declare it.
10937 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
10939         * c-ada-spec.h (dump_ada_specs): Revert prototype change.
10940         * c-ada-spec.c (dump_ads): Likewise.
10941         (cpp_check): Likewise.
10942         (dump_ada_specs): Likewise.
10944 2014-01-15  Laurent Alfonsi  <laurent.alfonsi@st.com>
10946         PR c++/49718
10947         * c-common.c (handle_no_instrument_function_attribute): Allow
10948         no_instrument_function attribute in class member
10949         definition/declaration.
10951 2014-01-15  Jakub Jelinek  <jakub@redhat.com>
10953         PR c/58943
10954         * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
10955         build_modify_expr with non-NOP_EXPR opcode.  Handle return from it
10956         being COMPOUND_EXPR.
10957         (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
10958         operand a SAVE_EXPR and second MODIFY_EXPR.
10960 2014-01-09  Jakub Jelinek  <jakub@redhat.com>
10962         PR target/58115
10963         * c-pch.c (c_common_write_pch): Call
10964         prepare_target_option_nodes_for_pch.
10966 2014-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
10968         Update copyright years
10970 2014-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
10972         * array-notation-common.c, c-cilkplus.c: Use the standard form for
10973         the copyright notice.
10975 2013-12-28  Eric Botcazou  <ebotcazou@adacore.com>
10977         * c-ada-spec.c (print_constructor): New function.
10978         (print_destructor): Retrieve the origin of the destructor.
10979         (print_ada_declaration): Revamp handling of constructors/destructors.
10981 2013-12-23  Stuart Hastings  <stuart@apple.com>
10982             Bill Maddox  <maddox@google.com>
10983             Jason Merrill  <jason@redhat.com>
10985         * c.opt: Add -fdeclone-ctor-dtor.
10986         * c-opts.c (c_common_post_options): Default to on iff -Os.
10988 2013-12-18  Balaji V. Iyer  <balaji.v.iyer@intel.com>
10990         * c-common.c (c_common_attribute_table): Added "cilk simd function"
10991         attribute.
10992         * c-pragma.h (enum pragma_cilk_clause): Remove.
10993         (enum pragma_omp_clause): Added the following fields:
10994         PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
10995         PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
10996         PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
10997         PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
10998         PRAGMA_CILK_CLAUSE_UNIFORM.
11001 2013-12-11  Balaji V. Iyer  <balaji.v.iyer@intel.com>
11003         * cilk.c (cilk_outline): Made this function non-static.
11004         (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
11005         (create_cilk_wrapper): Added a new parameter: a function pointer.
11006         (c_install_body_w_frame_cleanup): Remove
11007         (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
11008         * c-common.h (cilk_outline): New prototype.
11009         (gimplify_cilk_spawn): Removed two parameters.
11010         (cilk_install_body_with_frame_cleanup): New prototype.
11011         * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
11012         CILK_SPAWN_STMT case.
11014 2013-12-11  Bernd Schmidt  <bernds@codesourcery.com>
11016         * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
11018         * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
11019         (int_array_type_node): Remove.
11020         * c-common.c (c_common_nodes_and_builtins): Don't build it.
11022 2013-12-05  Marek Polacek  <polacek@redhat.com>
11024         PR c/52023
11025         * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
11026         [ADJUST_FIELD_ALIGN].
11028 2013-12-04  Joseph Myers  <joseph@codesourcery.com>
11030         PR c/52023
11031         * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
11032         and check field alignment if set.
11033         * c-common.h (c_sizeof_or_alignof_type): Update prototype.
11034         (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
11036 2013-12-04  Jakub Jelinek  <jakub@redhat.com>
11037             Marek Polacek  <polacek@redhat.com>
11039         * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
11040         sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
11042 2013-11-29   H.J. Lu  <hongjiu.lu@intel.com>
11044         PR c/59309
11045         * cilk.c (gimplify_cilk_spawn): Properly handle function without
11046         arguments.
11048 2013-11-29  Jakub Jelinek  <jakub@redhat.com>
11050         PR c/59280
11051         * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
11052         goto invalid.  If it is error_mark_node, don't issue further
11053         diagnostics.
11055 2013-11-28  Sergey Ostanevich  <sergos.gnu@gmail.com>
11057         * c.opt (Wopenmp-simd): New.
11059 2013-11-22  Jakub Jelinek  <jakub@redhat.com>
11061         * c-ubsan.h (ubsan_instrument_return): New prototype.
11062         * c-ubsan.c (ubsan_instrument_return): New function.
11064 2013-11-22  Andrew MacLeod  <amacleod@redhat.com>
11066         * c-common.c: Add required include files from gimple.h.
11067         * c-gimplify.c: Likewise.
11068         * cilk.c: Likewise.
11070 2013-11-22  David Malcolm  <dmalcolm@redhat.com>
11072         * c-common.c (unsafe_conversion_p): Remove use of
11073         EXPR_LOC_OR_HERE macro.
11074         (conversion_warning): Likewise.
11075         (warnings_for_convert_and_check): Likewise.
11076         (warn_for_collisions_1): Likewise.
11077         (shorten_compare): Likewise, and remove use of in_system_header
11078         macro, using the location from the former.
11079         * c-lex.c (dump_one_header): Remove use of input_filename macro.
11080         (cb_def_pragma): Remove use of in_system_header macro.
11081         (lex_string): Likewise.
11082         * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
11084 2013-11-20  Kenneth Zadeck  <zadeck@naturalbridge.com>
11085             Mike Stump  <mikestump@comcast.net>
11086             Richard Sandiford  <rdsandiford@googlemail.com>
11088         * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
11089         instead of TREE_INT_CST_LOW, in cases where there is a protecting
11090         tree_fits_shwi_p or tree_fits_uhwi_p.
11091         (dump_generic_ada_node): Likewise.
11092         * c-format.c (check_format_arg): Likewise.
11093         * c-pretty-print.c (pp_c_integer_constant): Likewise.
11095 2013-11-20  Kenneth Zadeck  <zadeck@naturalbridge.com>
11097         * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
11099 2013-11-19  Joshua J Cogliati  <jrincayc@yahoo.com>
11101         PR c/53001
11102         * c-common.c (unsafe_conversion_p): Make this function
11103         return an enumeration with more detail.
11104         (conversion_warning): Use the new return type of
11105         unsafe_conversion_p to separately warn either about conversions
11106         that lower floating point number precision or about the other
11107         kinds of conversions.
11108         * c-common.h (enum conversion_safety): New enumeration.
11109         (unsafe_conversion_p): switching return type to
11110         conversion_safety enumeration.
11111         * c.opt: Adding new warning -Wfloat-conversion and
11112         enabling it with -Wconversion.
11114 2013-11-19  Basile Starynkevitch  <basile@starynkevitch.net>
11116         * c-opts.c: Include plugin.h.
11117         (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
11119 2013-11-19  Marek Polacek  <polacek@redhat.com>
11121         * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
11122         call.
11123         (ubsan_instrument_shift): Likewise.
11124         (ubsan_instrument_vla): Likewise.
11126 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
11128         * c-common.c (convert_vector_to_pointer_for_subscript): Remove
11129         cast to unsigned type.
11131 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
11133         * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
11134         tree_low_cst.
11135         (complete_array_type): Update comment to refer to tree_to_[su]hwi
11136         rather than tree_low_cst.
11138 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
11140         * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
11141         tree_to_uhwi throughout.
11143 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
11145         * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
11146         tree_low_cst (..., 0) with tree_to_shwi throughout.
11148 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
11150         * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
11151         host_integerp (..., 1) with tree_fits_uhwi_p throughout.
11153 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
11155         * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
11156         host_integerp (..., 0) with tree_fits_shwi_p throughout.
11158 2013-11-15  Aldy Hernandez  <aldyh@redhat.com>
11160         * c-cilkplus.c: New file.
11161         * c-common.c (readonly_error): Add location argument.
11162         * c-common.h (readonly_error): Same.
11163         (c_finish_cilk_clauses): Protoize.
11164         (c_check_cilk_loop): Same.
11165         c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
11166         Do not fail on error_mark_node.
11167         Abstract increment canonicalization to here...
11168         (c_omp_for_incr_canonicalize_ptr): New.
11169         c-pragma.c (init_pragma): Register "simd" pragma.
11170         c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
11171         (enum pragma_cilk_clause): New.
11173 2013-11-15  Richard Sandiford  <rdsandiford@googlemail.com>
11175         * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
11176         wchar_type and host_integerp checks.
11178 2013-11-14  Andrew MacLeod  <amacleod@redhat.com>
11180         * c-common.c: Likewise.
11181         * c-gimplify.c: Likewise.
11182         * cilk.c: Likewise.
11184 2013-11-14  Diego Novillo  <dnovillo@google.com>
11186         * c-common.c: Include fold-const.h.
11187         Include stor-layout.h.
11188         Include calls.h.
11189         Include stringpool.h.
11190         Include attribs.h.
11191         Include varasm.h.
11192         Include trans-mem.h.
11193         * c-cppbuiltin.c: Include stor-layout.h.
11194         Include stringpool.h.
11195         * c-format.c: Include stringpool.h.
11196         * c-lex.c: Include stringpool.h.
11197         Include stor-layout.h.
11198         * c-pragma.c: Include stringpool.h.
11199         Include attribs.h.
11200         Include varasm.h.
11201         Include gcc-symtab.h.
11202         * c-pretty-print.c: Include stor-layout.h.
11203         Include attribs.h.
11204         * cilk.c: Include stringpool.h.
11205         Include calls.h.
11207 2013-11-13  Joseph Myers  <joseph@codesourcery.com>
11209         * c-common.h (enum rid): Add RID_AUTO_TYPE.
11210         * c-common.c (c_common_reswords): Add __auto_type.
11211         (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
11213 2013-11-12  Andrew MacLeod  <amacleod@redhat.com>
11215         * c-common.c: Include gimplify.h.
11216         * c-gimplify.c: Likewise.
11217         * cilk.c: Likewise.
11218         * c-omp.c: Include gimple-expr.h instead of gimple.h.
11219         * c-ubsan.c: Don't include gimple.h.
11221 2013-11-12  Joseph Myers  <joseph@codesourcery.com>
11223         * c-common.c (c_common_reswords): Add _Thread_local.
11225 2013-11-09  Joseph Myers  <joseph@codesourcery.com>
11227         * c-common.c (atomic_size_supported_p): New function.
11228         (resolve_overloaded_atomic_exchange)
11229         (resolve_overloaded_atomic_compare_exchange)
11230         (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
11231         Use it instead of comparing size with a local list of sizes.
11233 2013-11-07  Andrew MacLeod  <amacleod@redhat.com>
11234             Joseph Myers  <joseph@codesourcery.com>
11236         * c-common.h (enum rid): Add RID_ATOMIC.
11237         * c-common.c (c_common_reswords): Add _Atomic.
11238         (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
11239         (keyword_is_type_qualifier): Accept RID_ATOMIC.
11240         * c-format.c (check_format_types): Check for extra _Atomic
11241         qualifiers in format argument.
11242         * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
11243         (pp_c_type_qualifier_list): Mention _Atomic in comment.
11245 2013-11-06  Tobias Burnus  <burnus@net-b.de>
11247         * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
11249 2013-11-06  Joseph Myers  <joseph@codesourcery.com>
11251         * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
11252         standards modes.
11253         * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
11254         to mean lack of IEEE 754 support.
11256 2013-11-05  Tobias Burnus  <burnus@net-b.de>
11258         * c.opt (-Wdate-time): New option
11259         * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
11261 2013-11-05  Joseph Myers  <joseph@codesourcery.com>
11263         * c-cppbuiltin.c (cpp_iec_559_value): Test
11264         flag_excess_precision_cmdline not flag_excess_precision.
11266 2013-11-05  Tobias Burnus  <burnus@net-b.de>
11268         * c.opt (fopenmp-simd): New option.
11269         * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
11270         (omp_pragmas): ... this new struct.
11271         (c_pp_lookup_pragma): Also walk omp_pragmas.
11272         (init_pragma): Init pragmas for -fopenmp-simd.
11274 2013-11-04  Marek Polacek  <polacek@redhat.com>
11276         PR c++/58979
11277         * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
11279 2013-11-04  Joseph Myers  <joseph@codesourcery.com>
11281         * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
11282         New functions.
11283         (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
11285 2013-11-04  Eric Botcazou  <ebotcazou@adacore.com>
11287         * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
11288         (dump_ada_specs): Adjust prototype of second callback.
11289         * c-ada-spec.c (cpp_check): New global variable.
11290         (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
11291         (print_generic_ada_decl): Likewise.
11292         (has_static_fields): Change return type to bool and add guard.
11293         (has_nontrivial_methods): New predicate.
11294         (is_tagged_type): Change return type to bool.
11295         (separate_class_package): Call has_nontrivial_methods.
11296         (pp_ada_tree_identifier): Minor tweaks.
11297         (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
11298         (dump_ada_array_domains): Likewise.
11299         (dump_ada_array_type): Likewise.
11300         (dump_template_types): Remove cpp_check parameter and do not pass it to
11301         dump_generic_ada_node.
11302         (dump_ada_template): Likewise.
11303         (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
11304         recursively.
11305         (print_ada_methods): Change return type to integer.  Remove cpp_check
11306         parameter and do not pass it down.
11307         (dump_nested_types): Remove cpp_check parameter and do not pass it to
11308         dump_generic_ada_node.
11309         (print_ada_declaration): Likewise.  Test RECORD_OR_UNION_TYPE_P before
11310         accessing methods.
11311         (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
11312         down.  Use has_nontrivial_methods to recognize C++ classes.  Use return
11313         value of print_ada_methods.
11314         (dump_ads): Rename cpp_check parameter to check and adjust prototype.
11315         Set cpp_check to it before invoking dump_ada_nodes.
11316         (dump_ada_specs): Likewise.
11318 2013-11-03  Marek Polacek  <polacek@redhat.com>
11320         * c-ubsan.c: Don't include hash-table.h.
11321         (ubsan_instrument_vla): New function.
11322         * c-ubsan.h: Declare it.
11324 2013-10-31  David Malcolm  <dmalcolm@redhat.com>
11326         Automated part of renaming of symtab_node_base to symtab_node.
11328         Patch autogenerated by rename_symtab.py from
11329         https://github.com/davidmalcolm/gcc-refactoring-scripts
11330         revision 58bb219cc090b2f4516a9297d868c245495ee622
11332         * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
11333         symtab_node_base to symtab_node.
11335 2013-10-31  Edward Smith-Rowland  <3dw4rd@verizon.net>
11337         Implement C++14 digit separators.
11338         * c-lex.c (interpret_float): Remove digit separators from scratch string
11339         before building real literal.
11341 2013-10-30  Jakub Jelinek  <jakub@redhat.com>
11343         * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
11345 2013-10-29  Balaji V. Iyer  <balaji.v.iyer@intel.com>
11347         * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
11348         fields.
11349         (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
11350         enabled.
11351         * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
11352         (insert_cilk_frame): New prototype.
11353         (cilk_init_builtins): Likewise.
11354         (gimplify_cilk_spawn): Likewise.
11355         (c_cilk_install_body_w_frame_cleanup): Likewise.
11356         (cilk_detect_spawn_and_unwrap): Likewise.
11357         (cilk_set_spawn_marker): Likewise.
11358         (build_cilk_sync): Likewise.
11359         (build_cilk_spawn): Likewise.
11360         * cilk.c: New file.
11362 2013-10-29  David Malcolm  <dmalcolm@redhat.com>
11364         Patch autogenerated by refactor_symtab.py from
11365         https://github.com/davidmalcolm/gcc-refactoring-scripts
11366         revision 58bb219cc090b2f4516a9297d868c245495ee622
11368         * c-gimplify.c (c_genericize): Update for conversion of symtab types
11369         to a true class hierarchy.
11370         * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
11372 2013-10-27  Richard Sandiford  <rdsandiford@googlemail.com>
11374         * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
11376 2013-10-26  Jeff Law  <law@redhat.com>
11378         * c-common.c (c_define_builtins): Remove mudflap support.
11379         * c.opt: Ignore and warn for mudflap options.
11381 2013-10-24  Tobias Burnus  <burnus@net-b.de>
11383         PR other/33426
11384         * c-pragma.c (init_pragma) Add #pragma ivdep handling.
11385         * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
11387 2013-10-23  Jason Merrill  <jason@redhat.com>
11389         * c-format.c (gcc_cxxdiag_char_table): Add %X.
11391 2013-10-11  Jakub Jelinek  <jakub@redhat.com>
11393         * c-common.h (omp_clause_mask::operator !=): New method.
11394         * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
11395         instead of if (mask & something) tests everywhere.
11397         * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
11398         201307 instead of 201107.
11399         * c-common.c (DEF_FUNCTION_TYPE_8): Define.
11400         (c_common_attribute_table): Add "omp declare target" and
11401         "omp declare simd" attributes.
11402         (handle_omp_declare_target_attribute,
11403         handle_omp_declare_simd_attribute): New functions.
11404         * c-omp.c: Include c-pragma.h.
11405         (c_finish_omp_taskgroup): New function.
11406         (c_finish_omp_atomic): Add swapped argument, if true,
11407         build the operation first with rhs, lhs arguments and use NOP_EXPR
11408         build_modify_expr.
11409         (c_finish_omp_for): Add code argument, pass it down to make_code.
11410         (c_omp_split_clauses): New function.
11411         (c_split_parallel_clauses): Removed.
11412         (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
11413         c_omp_declare_simd_clauses_to_decls): New functions.
11414         * c-common.h (omp_clause_mask): New type.
11415         (OMP_CLAUSE_MASK_1): Define.
11416         (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
11417         omp_clause_mask::operator |=, omp_clause_mask::operator ~,
11418         omp_clause_mask::operator |, omp_clause_mask::operator &,
11419         omp_clause_mask::operator <<, omp_clause_mask::operator >>,
11420         omp_clause_mask::operator ==): New methods.
11421         (enum c_omp_clause_split): New.
11422         (c_finish_omp_taskgroup): New prototype.
11423         (c_finish_omp_atomic): Add swapped argument.
11424         (c_finish_omp_for): Add code argument.
11425         (c_omp_split_clauses): New prototype.
11426         (c_split_parallel_clauses): Removed.
11427         (c_omp_declare_simd_clauses_to_numbers,
11428         c_omp_declare_simd_clauses_to_decls): New prototypes.
11429         * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
11430         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
11431         PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
11432         PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
11433         PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
11434         Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
11435         (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
11436         PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
11437         PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
11438         PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
11439         PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
11440         PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
11441         PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
11442         PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
11443         PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
11444         PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
11445         PRAGMA_OMP_CLAUSE_UNIFORM.
11447 2013-10-09  Marc Glisse  <marc.glisse@inria.fr>
11449         PR tree-optimization/20318
11450         * c-common.c (handle_returns_nonnull_attribute): New function.
11451         (c_common_attribute_table): Add returns_nonnull.
11453 2013-10-03  Marc Glisse  <marc.glisse@inria.fr>
11455         PR c++/19476
11456         * c.opt (fcheck-new): Move to common.opt.
11458 2013-09-25  Marek Polacek  <polacek@redhat.com>
11459             Jakub Jelinek  <jakub@redhat.com>
11461         PR sanitizer/58413
11462         * c-ubsan.c (ubsan_instrument_shift): Don't instrument
11463         an expression if we can prove it is correct.
11464         (ubsan_instrument_division): Likewise.  Remove unnecessary
11465         check.
11467 2013-09-18  Marek Polacek  <polacek@redhat.com>
11469         PR sanitizer/58411
11470         * c-common.c (handle_no_sanitize_undefined_attribute): New function.
11471         Declare it.
11472         (struct attribute_spec c_common_att): Add no_sanitize_undefined.
11474 2013-09-14  Iain Sandoe  <iain@codesourcery.com>
11476         PR target/48094
11477         * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
11478         fobjc-gc, freplace-objc-classes): Accept for LTO.
11480 2013-09-13  Jacek Caban  <jacek@codeweavers.com>
11482         * c-target.def: New hook
11484 2013-09-09  Paolo Carlini  <paolo.carlini@oracle.com>
11486         PR c++/43452
11487         * c.opt (Wdelete-incomplete): Add.
11489 2013-09-08  Joern Rennecke  <joern.rennecke@embecosm.com>
11491         * c-common.c (same_scalar_type_ignoring_signedness): Delete.
11492         (vector_types_compatible_elements_p): New function.
11493         * c-common.h: (same_scalar_type_ignoring_signedness): Delete
11494         declaration.
11495         (vector_types_compatible_elements_p): Declare.
11497 2013-09-04  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11499         * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
11500         a virtual member function.
11501         (pp_simple_type_specifier): Remove.
11502         (pp_c_type_specifier): Likewise.
11503         * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
11504         Rename from pp_c_type_specifier.  Adjust.
11505         (c_pretty_printer::c_pretty_printer): Do not assign to
11506         simple_type_specifier.
11508 2013-09-03  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11510         * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
11511         member function.
11512         (c_pretty_printer::storage_class_specifier): Likewise.
11513         (c_pretty_printer::initializer): Likewise.
11514         (pp_declaration): Remove.
11515         (pp_declaration_specifiers): Likewise.
11516         (pp_abstract_declarator): Likewise.
11517         (pp_declarator): Likewise.
11518         (pp_type_id): Likewise.
11519         (pp_statement): Likewise.
11520         (pp_constant): Likewise.
11521         (pp_id_expression): Likewise.
11522         (pp_primary_expression): Likewise.
11523         (pp_unary_expression): Likewise.
11524         (pp_multiplicative_expression): Likewise.
11525         (pp_conditional_expression): Likewise.
11526         (pp_assignment_expression): Likewise.
11527         (pp_expression): Likewise.
11528         (pp_c_type_id): Likewise.
11529         (pp_c_storage_class_specifier): Likewise.
11530         * c-pretty-print.c (pp_c_type_cast): Tidy.
11531         (pp_c_pointer): Likewise.
11532         (pp_c_type_specifier): Likewise.
11533         (pp_c_parameter_type_list): Likewise.
11534         (pp_c_function_definition): Likewise.
11535         (pp_c_init_declarator): Likewise.
11536         (pp_c_initializer_list): Likewise.
11537         (pp_c_constructor_elts): Likewise.
11538         (c_pretty_printer::direct_abstract_declarator): Likewise.
11539         (c_pretty_printer::declaration_specifiers): Likewise.
11540         (c_pretty_printer::primary_expression): Likewise.
11541         (c_pretty_printer::postfix_expression): Likewise.
11542         (c_pretty_printer::type_id): Rename from pp_c_type_id.
11543         (c_pretty_printer::storage_class_specifier): Rename from
11544         pp_c_storage_class_specifier.
11545         (c_pretty_printer::initializer): Rename from pp_c_initializer.
11546         (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
11547         storage_class_specifier, initializer, offset_list, flags.
11549 2013-08-30  Marek Polacek  <polacek@redhat.com>
11551         * c-ubsan.c: New file.
11552         * c-ubsan.h: New file.
11554 2013-08-30  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11556         * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
11557         member function.
11558         (c_pretty_printer::declaration_specifiers): Likewise.
11559         (c_pretty_printer::declarator): Likewise.
11560         (c_pretty_printer::abstract_declarator): Likewise.
11561         (c_pretty_printer::direct_abstract_declarator): Likewise.
11562         (c_pretty_printer::direct_declarator): Likewise.
11563         (c_pretty_printer::function_specifier): Likewise.
11564         (pp_declaration): Adjust.
11565         (pp_declaration_specifiers): Likewise.
11566         (pp_abstract_declarator): Likewise.
11567         (pp_direct_declarator): Likewise.
11568         (pp_function_specifier): Likewise.
11569         (pp_direct_abstract_declarator): Remove as unused.
11570         (pp_c_declaration): Remove.
11571         (pp_c_declaration_specifiers): Likewise.
11572         (pp_c_declarator): Likewise.
11573         (pp_c_direct_declarator): Likewise.
11574         (pp_c_function_specifier): Likewise.
11575         (pp_c_direct_abstract_declarator): Likewise.
11576         * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
11577         from pp_c_abstract_declarator.  Adjust.
11578         (c_pretty_printer::direct_abstract_declarator): Rename from
11579         pp_c_direct_abstract_declarator.  Adjust.
11580         (c_pretty_printer::function_specifier): Rename from
11581         pp_c_function_specifier.  Adjust.
11582         (c_pretty_printer::declaration_specifiers): Rename from
11583         pp_c_declaration_specifiers.  Adjust.
11584         (c_pretty_printer::direct_declarator): Rename from
11585         pp_c_direct_declarator.  Adjust.
11586         (c_pretty_printer::declarator): Rename from pp_c_declarator.  Adjust.
11587         (c_pretty_printer::declaration): Rename from pp_c_declaration.  Adjust.
11588         (c_pretty_printer::c_pretty_printer): Do not assign to
11589         declaration, declaration_specifiers, declarator,
11590         direct_declarator, direct_abstract_declarator, function_specifier.
11592 2013-08-26  Gabriel Dos Reis  <gdre@integrable-solutions.net>
11594         * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
11595         virtual member function.
11596         (c_pretty_printer::multiplicative_expression): Likewise.
11597         (c_pretty_printer::conditional_expression): Likewise.
11598         (c_pretty_printer::assignment_expression): Likewise.
11599         (c_pretty_printer::expression): Likewise.
11600         (pp_unary_expression): Adjust.
11601         (pp_multiplicative_expression): Likewise.
11602         (pp_assignment_expression): Likewise.
11603         (pp_conditional_expression): Likewise.
11604         (pp_expression): Likewise.
11605         * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
11606         from pp_c_unary_expression.  Adjust.
11607         (c_pretty_printer::multiplicative_expression): Rename from
11608         pp_c_multiplicative_expression.  Adjust.
11609         (c_pretty_printer::conditional_expression): Rename from
11610         pp_c_conditional_expression.  Adjust.
11611         (c_pretty_printer::assignment_expression): Rename from
11612         pp_c_assignment_expression.  Adjust.
11613         (c_pretty_printer::expression): Rename from pp_c_expression.  Adjust.
11614         (c_pretty_printer::c_pretty_printer): Do not assign to
11615         unary_expression, multiplicative_expression,
11616         conditional_expression, expression.
11618 2013-08-25  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11620         * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
11621         virtual member function.
11622         (pp_postfix_expression): Adjust.
11623         (pp_c_postfix_expression): Remove.
11624         * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
11625         from pp_c_postfix_expression.  Adjust.
11626         (c_pretty_printer::c_pretty_printer): Do not assign to
11627         postfix_expression.
11629 2013-08-25  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11631         * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
11632         virtua member function.
11633         (pp_primary_expression): Adjust.
11634         (pp_c_primary_expression): Remove.
11635         * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
11636         from pp_c_primary_expression.  Adjust.
11637         (pp_c_initializer_list): Use pp_primary_expression.
11638         (c_pretty_printer::c_pretty_printer): Do not assign to
11639         primary_expression.
11641 2013-08-25  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11643         * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
11644         * c-pretty-print.c (M_): Remove.
11645         (c_pretty_printer::translate_string): Define.
11646         (pp_c_type_specifier): Use it.
11647         (pp_c_primary_expression): Likewise.
11648         (pp_c_expression): Likewise.
11650 2013-08-24  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11652         * c-pretty-print.h (c_pretty_printer::id_expression): Now a
11653         virtual function.
11654         (pp_c_id_expression): Remove.
11655         (pp_id_expression): Adjust.
11656         * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
11657         pp_c_id_expression.  Adjust.
11658         (pp_c_postfix_expression): Use pp_id_expression.
11659         (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
11661 2013-08-24  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11663         * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
11664         member function.
11665         (pp_constant): Adjust.
11666         (pp_c_constant): Remove.
11667         * c-pretty-print.c (c_pretty_printer::constant): Rename from
11668         pp_c_constant.  Adjust.
11669         (pp_c_constant)
11670         (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
11671         (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
11673 2013-08-22  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11675         * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
11676         (c_pretty_printer::c_pretty_printer): Declare.
11677         * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
11678         c_pretty_printer_init.  Adjust.
11679         (print_c_tree): Do not call c_pretty_printer_init.
11680         * c-ada-spec.c (dump_ads): Remove call to pp_construct.
11682 2013-08-09  Arnaud Charlet  <charlet@adacore.com>
11684         * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
11686 2013-08-05  Paolo Carlini  <paolo.carlini@oracle.com>
11688         PR c++/58080
11689         * c-common.c (pointer_int_sum): Add bool parameter.
11690         * c-common.h (pointer_int_sum): Adjust declaration.
11692 2013-08-05  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11694         * c-pretty-print.c (print_c_tree): Simplify.  Use non-static local
11695         c_pretty_printer variable.
11697 2013-08-04  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11699         * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
11700         (pp_base): Remove.
11701         (pp_c_base): Likewise.  Adjust users.
11702         * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
11703         (pp_c_whitespace): Do not call pp_base.
11704         (pp_c_left_paren): Likewise.
11705         (pp_c_right_paren): Likewise.
11706         (pp_c_left_brace): Likewise.
11707         (pp_c_right_brace): Likewise.
11708         (pp_c_left_bracket): Likewise.
11709         (pp_c_right_bracket): Likewise.
11710         (pp_c_dot): Likewise.
11711         (pp_c_ampersand): Likewise.
11712         (pp_c_star): Likewise.
11713         (pp_c_arrow): Likewise.
11714         (pp_c_semicolon): Likewise.
11715         (pp_c_complement): Likewise.
11716         (pp_c_exclamation): Likewise.
11717         (pp_c_direct_declarator): Likewise.
11718         (pp_c_ws_string): Likewise.
11719         (pp_c_identifier): Likewise.
11720         (pp_c_statement): Likewise.
11721         (print_c_tree): Likewise.
11723 2013-08-04  Ed Smith-Rowland  <3dw4rd@verizon.net>
11725         PR c++/58072
11726         * c-common.c (c_parse_error): Catch user-defined literal tokens and
11727         provide useful error strings.
11729 2013-08-03  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11731         * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
11732         printer functions instead of pp_string or operators and punctuators.
11733         (dump_generic_ada_node): Likewise.
11734         * c-pretty-print.c (pp_c_type_specifier): Likewise.
11735         (pp_c_relational_expression): Likewise.
11736         (pp_c_logical_or_expression): Likewise.
11738 2013-08-03  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11740         * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
11741         functions instead of pp_character.
11742         (pp_ada_tree_identifier): Likewise.
11743         (dump_ada_double_name): Likewise.
11744         (dump_ada_function_declaration): Likewise.
11745         (dump_ada_array_domains): Likewise.
11746         (dump_template_types): Likewise.
11747         (dump_generic_ada_node): Likewise.
11748         (print_ada_declaration): Likewise.
11749         (print_ada_struct_decl): Likewise.
11750         * c-pretty-print.c (pp_c_integer_constant): Likewise.
11752 2013-07-23  Tom Tromey  <tromey@redhat.com>
11754         * c-common.h (enum rid) <RID_GENERIC>: New constant.
11755         * c-common.c (c_common_reswords): Add _Generic.
11757 2013-07-21   Ondřej Bílka  <neleai@seznam.cz>
11759         * c-common.c: Fix typos.
11760         * c-common.h: Likewise.
11762 2013-07-13  Lubos Lunak  <l.lunak@suse.cz>
11764         PR c++/55203
11765         * c-common.c (c_common_attribute_table): Add warn_unused.
11766         (handle_warn_unused_attribute): New.
11768 2013-07-10  Jakub Jelinek  <jakub@redhat.com>
11770         * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
11771         for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
11773 2013-07-10  Paolo Carlini  <paolo.carlini@oracle.com>
11775         PR c++/57869
11776         * c.opt: Add Wconditionally-supported.
11778 2013-07-08  Graham Stott  <graham.stott@btinternet.com>
11780         * array-notation-common.c (length_mismatch_in_expr_p): Delete
11781         unused variables l_length and l_node.
11783 2013-07-04  Joern Rennecke  <joern.rennecke@embecosm.com>
11785         PR c/57821
11786         * c-common.c (complete_array_type): Delay folding first index
11787         like other indices.  When folding, check for index overflow.
11789 2013-06-27  Marc Glisse  <marc.glisse@inria.fr>
11791         PR c++/57509
11792         * c-common.h (c_build_vec_perm_expr): New complain argument.
11793         * c-common.c (c_build_vec_perm_expr): Likewise.
11794         Use save_expr also in C++.
11796 2013-06-22  Gabriel Dos Reis  <gdr@integrable-solutions.net>
11798         * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
11799         * c-cppbuiltin.c (c_cpp_builtins): Likewise.
11800         * c-opts.c (c_common_post_options): Likewise.
11802 2013-06-21  Balaji V. Iyer  <balaji.v.iyer@intel.com>
11804         * array-notation-common.c (length_mismatch_in_expr): Changed the
11805         parameter type's from a dynamic array to a vec_tree.  Also removed
11806         the size parameters.
11807         * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
11808         the change above.
11810 2013-06-21  Balaji V. Iyer  <balaji.v.iyer@intel.com>
11812         * c-common.h (struct cilkplus_an_parts): New structure.
11813         (struct cilkplus_an_loop_parts): Likewise.
11814         (cilkplus_extract_an_triplets): New prototype.
11815         (fix_sec_implicit_args): Likewise.
11816         * array-notation-common.c (cilkplus_extract_an_triplets): New function.
11817         (fix_sec_implicit_args): Likewise.
11819 2013-06-20  Balaji V. Iyer  <balaji.v.iyer@intel.com>
11821         * array-notation-common.c (find_inv_trees): Removed an unwanted
11822         typecasting.
11823         * c-common.h (struct inv_list::additional_tcodes): Changed type from
11824         enum rid to enum tree_code.
11826 2013-06-11  Jan Hubicka  <jh@suse.cz>
11828         * c-common.c (handle_alias_ifunc_attribute): Do not set
11829         DECL_EXTERNAL for weakref variables.
11830         * c-pragma.c (handle_pragma_weak): Make sure aliases
11831         are not declared as external.
11833 2013-06-07  Balaji V. Iyer  <balaji.v.iyer@intel.com>
11835         * array-notation-common.c (length_mismatch_in_expr_p): Moved this
11836         function from c/c-array-notation.c.
11837         (is_cilkplus_reduce_builtin): Likewise.
11838         (find_rank): Likewise.
11839         (extract_array_notation_exprs): Likewise.
11840         (replace_array_notations): Likewise.
11841         (find_inv_trees): Likewise.
11842         (replace_inv_trees): Likewise.
11843         (contains_array_notation_expr): Likewise.
11844         (find_correct_array_notation_type): Likewise.
11845         * c-common.h (struct inv_list): Moved this struct from the file
11846         c/c-array-notation.c and added a new field called additional tcodes.
11847         (length_mismatch_in_expr_p): New prototype.
11848         (is_cilkplus_reduce_builtin): Likewise.
11849         (find_rank): Likewise.
11850         (extract_array_notation_exprs): Likewise.
11851         (replace_array_notation): Likewise.
11852         (find_inv_trees): Likewise.
11853         (replace_inv_trees): Likewise.
11854         (find_correct_array_notation_type): Likewise.
11856 2013-05-28  Balaji V. Iyer  <balaji.v.iyer@intel.com>
11858         * c-common.c (c_define_builtins): When cilkplus is enabled, the
11859         function array_notation_init_builtins is called.
11860         (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
11861         * c-common.def (ARRAY_NOTATION_REF): New tree.
11862         * c-common.h (build_array_notation_expr): New function declaration.
11863         (build_array_notation_ref): Likewise.
11864         (extract_sec_implicit_index_arg): New extern declaration.
11865         (is_sec_implicit_index_fn): Likewise.
11866         (ARRAY_NOTATION_CHECK): New define.
11867         (ARRAY_NOTATION_ARRAY): Likewise.
11868         (ARRAY_NOTATION_START): Likewise.
11869         (ARRAY_NOTATION_LENGTH): Likewise.
11870         (ARRAY_NOTATION_STRIDE): Likewise.
11871         * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
11872         ARRAY_NOTATION_REF.
11873         (pp_c_expression): Likewise.
11874         * c.opt (flag_enable_cilkplus): New flag.
11875         * array-notation-common.c: New file.
11877 2013-05-14  Jakub Jelinek  <jakub@redhat.com>
11879         PR c++/57274
11880         * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
11882 2013-05-10  Marc Glisse  <marc.glisse@inria.fr>
11884         * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
11885         vectors.
11887 2013-05-07  Han Shen  <shenhan@google.com>
11889         * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
11891 2013-04-29  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
11893         * c-common.c (check_user_alignment): Emit error for negative values.
11895 2013-04-24  Paolo Carlini  <paolo.carlini@oracle.com>
11897         * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
11899 2013-04-24  Paolo Carlini  <paolo.carlini@oracle.com>
11901         * c-cppbuiltin.c (c_cpp_builtins): Do not define
11902         __GXX_EXPERIMENTAL_CXX1Y__.
11904 2013-04-24  Paolo Carlini  <paolo.carlini@oracle.com>
11905             Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
11907         * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
11908         * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
11909         to simply use OPT_Wpointer_arith.
11910         (c_sizeof_or_alignof_type): Likewise.
11912 2013-04-24  Paolo Carlini  <paolo.carlini@oracle.com>
11914         * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
11916 2013-04-12  Jakub Jelinek  <jakub@redhat.com>
11918         * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
11919         gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
11920         specifiers.
11922 2013-04-07  Steven Bosscher  <steven@gcc.gnu.org>
11924         * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
11926 2013-04-03  Paolo Carlini  <paolo.carlini@oracle.com>
11928         * c-common.c (pointer_int_sum): Remove dead code.
11930 2013-03-09  Richard Sandiford  <rdsandiford@googlemail.com>
11932         PR middle-end/56524
11933         * c-common.c (handle_optimize_attribute): Don't call
11934         save_optabs_if_changed.
11936 2013-03-05  Jakub Jelinek  <jakub@redhat.com>
11938         PR middle-end/56461
11939         * c-pch.c (pch_init): Free target_validity at the end.
11941 2013-03-04  Jakub Jelinek  <jakub@redhat.com>
11943         * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
11945 2013-02-28  Konstantin Serebryany  <konstantin.s.serebryany@gmail.com>
11946             Jakub Jelinek  <jakub@redhat.com>
11948         PR sanitizer/56454
11949         * c-common.c (handle_no_sanitize_address_attribute): New function.
11950         (c_common_attribute_table): Add no_sanitize_address attribute.
11951         (handle_no_address_safety_analysis_attribute): Add
11952         no_sanitize_address attribute, not no_address_safety_analysis
11953         attribute.
11955 2013-02-18  Aldy Hernandez  <aldyh@redhat.com>
11957         PR target/52555
11958         * c-common.c (handle_optimize_attribute): Call
11959         save_optabs_if_changed.
11961 2013-02-18  Jakub Jelinek  <jakub@redhat.com>
11962             Steven Bosscher  <steven@gcc.gnu.org>
11964         PR pch/54117
11965         * c-opts.c (c_common_post_options): If debug info is enabled
11966         and non-dwarf*, refuse to load PCH files and when writing PCH
11967         file warn.
11969 2013-02-05  Jakub Jelinek  <jakub@redhat.com>
11971         PR middle-end/56167
11972         * c-common.c (handle_error_attribute): Fix condition.
11974 2013-01-30  Jakub Jelinek  <jakub@redhat.com>
11976         PR c++/55742
11977         * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
11979 2013-01-18  Jason Merrill  <jason@redhat.com>
11981         PR target/54908
11982         * c.opt (-fextern-tls-init): New.
11983         * c-opts.c (c_common_post_options): Handle it.
11985 2013-01-09  Jakub Jelinek  <jakub@redhat.com>
11987         PR c/48418
11988         * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
11989         RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
11990         and is either negative or bigger or equal to type precision
11991         of the first operand.
11993 2012-12-03  Marek Polacek  <polacek@redhat.com>
11995         PR c/55570
11996         * c-common.c (check_user_alignment): Swap order of tests,
11997         check TREE_CODE first.
11999 2012-11-29  Ed Smith-Rowland  <3dw4rd@verizon.net>
12001         PR c++/52654
12002         * c-common.h (overflow_type): New enum.
12003         (build_userdef_literal): Add overflow_type argument.
12004         (tree_userdef_literal): Add overflow_type.
12005         (USERDEF_LITERAL_OVERFLOW): New access macro.
12006         * c-common.c (build_userdef_literal): Add overflow_type
12007         argument.
12008         * c-lex.c (c_lex_with_flags): Add overflow_type to
12009         build_userdef_literal calls.
12010         (interpret_integer, interpret_float): Add overflow_type argument.
12012 2012-11-28  Richard Biener  <rguenther@suse.de>
12014         PR c/35634
12015         * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
12016         here and use a type with proper overflow behavior for types that would
12017         need to be promoted for the arithmetic.
12019 2012-11-23  Jakub Jelinek  <jakub@redhat.com>
12021         PR sanitizer/55435
12022         * c-common.c (handle_no_address_safety_analysis_attribute): New
12023         function.
12024         (c_common_attribute_table): Add no_address_safety_analysis.
12026 2012-11-16  Simon Baldwin  <simonb@google.com>
12028         * c.opt: Add f[no-]canonical-system-headers.
12029         * c-opts.c (c_common_handle_option): Handle
12030         OPT_fcanonical_system_headers.
12032 2012-11-09  Ed Smith-Rowland  <3dw4rd@verizon.net>
12034         PR c++/54413
12035         * c-opts.c (c_common_handle_option): Set new flags.
12036         * c.opt: Describe new flags.
12038 2012-11-09  Jason Merrill  <jason@redhat.com>
12040         * c.opt (Wabi-tag): New.
12042 2012-11-09  Andi Kleen  <ak@linux.intel.com>
12044         PR 55139
12045         * c-common.c (get_atomic_generic_size): Mask with
12046         MEMMODEL_MASK
12048 2012-11-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12050         PR c/53063
12051         * c.opt (Wformat): Make it Alias Wformat=1.
12052         (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
12053         Wformat-security,Wformat-y2k,Wformat-zero-length): Use
12054         LangEnabledBy.
12055         (Wformat=): RejectNegative. Use LangEnabledBy.
12056         (Wnonnull): Use LangEnabledBy.
12057         * c-opts.c (c_common_handle_option): Do not handle Wformat here.
12058         * c-format.c (set_Wformat): Delete.
12059         (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
12060         (maybe_read_dollar_number): Likewise.
12061         (avoid_dollar_number): Likewise.
12062         (finish_dollar_format_checking): Likewise.
12063         (check_format_info): Likewise.
12064         (check_format_info_main): Likewise.
12065         (check_format_types): Likewise.
12066         (format_type_warning): Likewise.
12067         * c-common.c (int): Likewise.
12068         (check_function_sentinel): Likewise.
12069         * c-common.h (warn_format,set_Wformat): Do not declare here.
12071 2012-11-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12073         PR c/53063
12074         * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
12075         Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
12076         Use LangEnabledBy.
12077         (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
12078         common.opt.
12079         (Wvariadic-macros): Init(1).
12080         * c-opts.c (c_common_handle_option): Do not handle them
12081         explicitly.
12082         (c_common_post_options): Likewise.
12083         (sanitize_cpp_opts): warn_unused_macros is now
12084         cpp_warn_unused_macros.
12085         (push_command_line_include): Likewise.
12086         * c-common.c (warn_unknown_pragmas): Do not define.
12087         * c-common.h (warn_unknown_pragmas): Do not declare.
12089 2012-11-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12091         PR c/51294
12092         * c-common.c (conversion_warning): Handle conditional expressions.
12094 2012-10-29  Jonathan Wakely  <jwakely.gcc@gmail.com>
12096         PR c++/54930
12097         * c.opt (Wreturn_local_addr): Define new option.
12099 2012-10-25  Jason Merrill  <jason@redhat.com>
12101         * c.opt (Wvirtual-move-assign): New.
12103         * c.opt (Winherited-variadic-ctor): New.
12105 2012-10-25  Marc Glisse  <marc.glisse@inria.fr>
12107         PR c++/54427
12108         * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
12110 2012-10-23  Joseph Myers  <joseph@codesourcery.com>
12112         * c-common.h (pch_cpp_save_state): Declare.
12113         * c-target.def (c_preinclude): New hook.
12114         * c-opts.c (done_preinclude): New.
12115         (push_command_line_include): Handle default preincluded header.
12116         (cb_file_change): Call pch_cpp_save_state when calling
12117         push_command_line_include.
12118         * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
12119         (pch_cpp_save_state): New.
12120         (pch_init): Call pch_cpp_save_state conditionally, instead of
12121         calling cpp_save_state.
12123 2012-10-20  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12125         PR c/53063
12126         PR c/40989
12127         * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
12128         Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
12129         Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
12130         Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
12131         Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
12132         * c-opts.c (c_common_handle_option): Remove explicit handling from
12133         here.
12134         (c_common_post_options): Likewise.
12136 2012-10-18  Eric Botcazou  <ebotcazou@adacore.com>
12138         * c-ada-spec.c (LOCATION_COL): Delete.
12139         (compare_location): New function.
12140         (compare_node): Use it.
12141         (compare_comment): Likewise.
12143 2012-10-16  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12145         PR c/53063
12146         PR c/40989
12147         * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
12148         * c-opts.c (c_common_handle_option): Do not set them here. Add
12149         comment.
12150         (c_common_post_options): Likewise.
12152 2012-10-16  Eric Botcazou  <ebotcazou@adacore.com>
12154         * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
12155         (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
12156         Remove POINTER_TYPE handling, add large unsigned handling and use
12157         ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
12159 2012-10-12  Jakub Jelinek  <jakub@redhat.com>
12161         PR c/54381
12162         * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
12163         * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
12164         locs and array of 3 trees instead of just single loc and single
12165         sizeof_arg tree.  Handle __builtin___*_chk builtins too, and
12166         also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
12167         For *cmp* builtins that take two sources strings report warnings
12168         about first and second source, not about destination and source.
12170 2012-10-12  Marc Glisse  <marc.glisse@inria.fr>
12172         PR c++/53055
12173         * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
12175 2012-10-11  Eric Botcazou  <ebotcazou@adacore.com>
12177         * c-ada-spec.c (dump_ada_template): Bail out for template declarations
12178         declaring something coming from another file.
12180 2012-10-10  Arnaud Charlet  <charlet@adacore.com>
12182         PR ada/54845
12183         * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
12185 2012-10-09  Paolo Carlini  <paolo.carlini@oracle.com>
12187         PR c++/54194
12188         * c-common.c (warn_about_parentheses): Add location_t parameter;
12189         use EXPR_LOC_OR_LOC.
12190         * c-common.h: Update declaration.
12192 2012-10-09  Marc Glisse  <marc.glisse@inria.fr>
12194         PR c++/54427
12195         * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
12196         more operations. Make error messages optional.
12197         * c-common.h (enum stv_conv): Moved from c-typeck.c.
12198         (scalar_to_vector): Declare.
12200 2012-10-08  Jason Merrill  <jason@redhat.com>
12202         * c-common.c (c_common_reswords): Add thread_local.
12204 2012-10-08  Dodji Seketeli  <dodji@redhat.com>
12206         PR c++/53528 C++11 attribute support
12207         * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
12208         new functions.
12209         * c-common.c (check_cxx_fundamental_alignment_constraints): New
12210         static function.
12211         (handle_aligned_attribute): In choose strictest alignment
12212         among many.  Use new check_cxx_fundamental_alignment_constraints.
12213         (handle_transparent_union_attribute): In c++11 attribute syntax,
12214         don't look through typedefs.
12216 2012-10-04  Arnaud Charlet  <charlet@adacore.com>
12218         * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
12219         * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
12220         out of dumpfile.h.
12222 2012-09-25  Dehao Chen  <dehao@google.com>
12224         PR middle-end/54645
12225         * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
12226         map when read in the pch.
12228 2012-09-18  Arnaud Charlet  <charlet@adacore.com>
12230         * c-ada-spec.c: Style fixes.
12232 2012-09-18  Thomas Quinot  <quinot@adacore.com>
12234         * c.opt (-fada-spec-parent): Define new command line switch.
12235         * c-ada-spec.c (get_ada_package): When -fada-spec-parent
12236         is specified, generate binding spec as a child of the specified unit.
12238 2012-09-13  Paolo Carlini  <paolo.carlini@oracle.com>
12239             Manuel López-Ibáñez  <manu@gcc.gnu.org>
12241         PR c++/53210
12242         * c.opt ([Winit-self]): Enabled by -Wall in C++.
12244 2012-08-23  Arnaud Charlet  <charlet@adacore.com>
12246         * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
12247         for pointers, and add missing Convention C pragma.
12248         (print_ada_struct_decl): Add missing aliased keyword.
12249         (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
12251 2012-08-17  Jakub Jelinek  <jakub@redhat.com>
12253         * c-common.c (sizeof_pointer_memaccess_warning): New function.
12254         * c.opt (-Wsizeof-pointer-memaccess): Add new option.
12255         * c-opts.c (c_common_handle_option): Enable it for -Wall.
12256         * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
12257         * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
12259 2012-08-10  Richard Guenther  <rguenther@suse.de>
12261         * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
12263 2012-08-07  Steven Bosscher  <steven@gcc.gnu.org>
12265         * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
12266         instead of separate pp_newline and pp_flush.
12267         (print_c_tree): Likewise.
12269 2012-07-26  Richard Henderson  <rth@redhat.com>
12271         * c-common.c (handle_hot_attribute): Allow labels.
12272         (handle_cold_attribute): Likewise.
12274 2012-07-20  Jakub Jelinek  <jakub@redhat.com>
12276         PR c++/28656
12277         * c-common.c (check_function_nonnull): Handle multiple nonnull
12278         attributes properly.
12280 2012-07-16  Steven Bosscher  <steven@gcc.gnu.org>
12282         * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
12283         * c-ada-spec.c: Likewise.
12284         * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
12286 2012-07-14  Steven Bosscher  <steven@gcc.gnu.org>
12288         * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
12289         Remove code conditional on it.
12291 2012-07-11  Steven Bosscher  <steven@gcc.gnu.org>
12293         * c-gimplify.c: Do not include basic-block.h.
12294         * c-common.c: Do not include linfuncs.h.
12296 2012-07-08  Steven Bosscher  <steven@gcc.gnu.org>
12298         * c-common.h: Include tree.h.
12300 2012-07-02  Jason Merrill  <jason@redhat.com>
12302         PR c++/53524
12303         * c-common.c (get_priority): Call default_conversion.
12305 2012-07-01  Uros Bizjak  <ubizjak@gmail.com>
12307         * c-pch.c (c_common_write_pch): Remove unused variables.
12309 2012-06-29  Steven Bosscher  <steven@gcc.gnu.org>
12311         * cppspec.c: Moved from gcc/ to here.
12313 2012-06-27  Kai Tietz  <ktietz@redhat.com>
12315         PR preprocessor/37215
12316         * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
12318 2012-06-21  Steven Bosscher  <steven@gcc.gnu.org>
12320         * c-common.h (c_common_print_pch_checksum): Remove.
12321         * c-pch.c: Do not include output.h.
12322         (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
12323         (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
12324         (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
12325         (struct c_pch_header): Remove.
12326         (get_ident): Update gpch version.
12327         (pch_init): Do not print executable_checksum to asm_out_file.
12328         Do not fail if there is no asm_out_file to read back from.  Set
12329         asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
12330         (c_common_write_pch): Verify that nothing was written to asm_out_file
12331         since pch_init was called.  Do not write a c_pch_header, and do not
12332         copy from asm_out_file to the PCH.
12333         (c_common_read_pch): Do not read a c_pch_header, and do not restore
12334         the content of asm_out_file from the PCH.
12335         (c_common_print_pch_checksum): Remove.
12336         * c-opts.c (c_common_init): Print out executable_checksum directly.
12338 2012-06-19  Steven Bosscher  <steven@gcc.gnu.org>
12340         * c-target.def (objc_declare_unresolved_class_reference,
12341         objc_declare_class_definition): Add new hooks.
12343 2012-06-19  Steven Bosscher  <steven@gcc.gnu.org>
12345         * c-lex.c: Do not include output.h.
12346         (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
12347         Remove uses of ASM_OUTPUT_IDENT.
12349 2012-06-15  Marc Glisse  <marc.glisse@inria.fr>
12351         PR c++/51033
12352         * c-common.h (c_build_vec_perm_expr): Move decl here.
12353         * c-common.c (c_build_vec_perm_expr): Move definition
12354         here.
12356 2012-06-06  Steven Bosscher  <steven@gcc.gnu.org>
12358         * c.opt (fconserve-space): Turn into a no-op.
12360 2012-06-04  Sterling Augustine  <saugustine@google.com>
12362         * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
12363         * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
12364         both the start and end of the function.
12366 2012-06-04  Steven Bosscher  <steven@gcc.gnu.org>
12368         * c-common.c: Do not include output.h.
12369         * c-pragma.c: Likewise.
12371 2012-06-04  Steven Bosscher  <steven@gcc.gnu.org>
12373         * error.c (dump_decl): Check pp_c_flag_gnu_v3.
12374         (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
12375         (lang_decl_name): Handle namespace decls.
12377 2012-05-31  Steven Bosscher  <steven@gcc.gnu.org>
12379         * c-ada-spec.c: Do not include output.h.
12380         * c-semantics.c: Likewise.
12382 2012-05-29  Joseph Myers  <joseph@codesourcery.com>
12384         * c-common.c: Fix typo.
12386 2012-05-29  Michael Matz  <matz@suse.de>
12388         * c-common.h (c_expand_decl): Remove prototype.
12390 2012-05-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12392         * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
12393         * c-opts.c (c_common_handle_option): Remove code handling
12394         warn_missing_braces.
12396 2012-05-28  Paolo Carlini  <paolo.carlini@oracle.com>
12398         PR c++/25137
12399         * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
12400         -Wmissing_braces.
12402 2012-05-22  Dodji Seketeli  <dodji@redhat.com>
12404         PR c++/53322
12405         * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
12407 2012-05-17  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12409         * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
12410         * c-opts.c (c_common_handle_option): Do not handle explicitly
12411         Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
12413 2012-05-16  Dodji Seketeli  <dodji@redhat.com>
12415         PR preprocessor/7263
12416         * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
12417         to cpp_classify_number.  For diagnostics, use the precise location
12418         instead of the global input_location.
12420 2012-05-15  Paolo Carlini  <paolo.carlini@oracle.com>
12422         PR c++/11856
12423         * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
12425 2012-05-14  Bernd Schmidt  <bernds@codesourcery.com>
12427         * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
12429 2012-05-14  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12431         PR 53063
12432         * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
12433         Wreorder): Use LangEnabledBy.
12434         * c-opts.c (c_common_handle_option): Do not enable them
12435         explicitly. Call lang-specific generated functions.
12436         (c_common_post_options): Do not set them here.
12438 2012-05-13  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12440         * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
12441         Wmissing-field-initializers,Wmissing-parameter-type,
12442         Wold-style-declaration,Woverride-init): Use EnabledBy.
12443         * c-opts.c (c_common_post_options): Do not set here explicitly.
12445 2012-05-11  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12447         PR 53063
12448         * c-opts.c (c_common_handle_option): Use handle_generated_option
12449         to enable sub-options.
12451 2012-05-10  Paolo Carlini  <paolo.carlini@oracle.com>
12453         PR c++/53158
12454         * c-common.c (warnings_for_convert_and_check): Use warning_at.
12456 2012-05-10  Richard Guenther  <rguenther@suse.de>
12458         * c-common.c (c_sizeof_or_alignof_type): Remove assert and
12459         adjust commentary about TYPE_IS_SIZETYPE types.
12461 2012-05-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12463         PR c++/53261
12464         * c-common.c (warn_logical_operator): Check that argument of
12465         integer_zerop is not NULL.
12467 2012-05-05  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12469         PR c/43772
12470         * c-common.c (warn_logical_operator): Do not warn if either side
12471         is already true or false.
12473 2012-05-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12475         PR c/51712
12476         * c-common.c (expr_original_type): New.
12477         (shorten_compare): Do not warn for enumeration types.
12479 2012-05-03  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12481         * c.opt (fpermissive): Add Var(flag_permissive).
12483 2012-04-30  Marc Glisse  <marc.glisse@inria.fr>
12485         PR c++/51033
12486         * c-common.c (convert_vector_to_pointer_for_subscript): New function.
12487         * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
12489 2012-04-30  Dodji Seketeli  <dodji@redhat.com>
12491         Add -Wvarargs option
12492         * c.opt (Wvarargs): Define new option.
12494 2012-04-30  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12496         * c-common.c (check_function_arguments): Replace
12497         Wmissing-format-attribute with Wsuggest-attribute=format.
12499 2012-04-30  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12501         * c.opt (Wsuggest-attribute=format): New. Alias of
12502         Wmissing-format-attribute.
12503         * c-format.c (decode_format_type): Replace
12504         Wmissing-format-attribute with Wsuggest-attribute=format.
12505         (check_function_format): Likewise.
12507 2012-04-27  Ollie Wild  <aaw@google.com>
12509         * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
12510         * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
12511         * c.opt: Add Wliteral-suffix.
12513 2012-04-22  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12515         PR c/44774
12516         * c.opt (Wpedantic): New.
12517         (pedantic): Alias Wpedantic.
12518         * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
12519         (c_common_post_options): Likewise.
12520         (sanitize_cpp_opts): Likewise.
12521         * c-lex.c (interpret_float): Likewise.
12522         * c-format.c (check_format_types): Likewise.
12523         * c-common.c (pointer_int_sum): Likewise.
12524         (c_sizeof_or_alignof_type): Likewise.
12525         (c_add_case_label): Likewise.
12526         (c_do_switch_warnings): Likewise.
12527         * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
12529 2012-04-15  Jason Merrill  <jason@redhat.com>
12531         PR c++/52818
12532         * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
12533         (C_STD_NAME): Distinguish between C++98 and C++11.
12535 2012-04-11  Eric Botcazou  <ebotcazou@adacore.com>
12537         PR target/52624
12538         * c-common.h (uint16_type_node): Rename into...
12539         (c_uint16_type_node): ...this.
12540         * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
12541         * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
12543 2012-04-10  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12545         * c-common.c (warn_if_unused_value): Move definition to here.
12546         * c-common.h (warn_if_unused_value): Move declaration to here.
12548 2012-03-23  William Bader  <williambader@hotmail.com>
12550         * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
12552 2012-03-20  Jason Merrill  <jason@redhat.com>
12554         * c-common.h (enum cxx_dialect): Add cxx1y.
12555         * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
12556         test.
12557         * c-cppbuiltin.c (c_cpp_builtins): Likewise.
12558         * c-opts.c (c_common_post_options): Likewise.
12559         (set_std_cxx1y): New.
12560         (c_common_handle_option): Call it.
12561         * c.opt (-std=c++1y, -std=gnu++1y): New flags.
12563 2012-03-19  Paolo Carlini  <paolo.carlini@oracle.com>
12565         PR c++/14710
12566         * c.opt ([Wuseless-cast]): Add.
12568 2012-03-16  Richard Guenther  <rguenther@suse.de>
12570         * c-pretty-print.c (pp_c_initializer_list): Adjust.
12572 2012-03-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
12574         PR c++/44783
12575         * c.opt (ftemplate-backtrace-limit) Add.
12577 2012-03-12  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
12579         * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
12580         handling.
12581         * c-pragma.c (handle_pragma_extern_prefix): Remove.
12582         (init_pragma): Don't register extern_prefix.
12584 2012-03-12  Richard Guenther  <rguenther@suse.de>
12586         * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
12587         (builtin_type_for_size): Likewise.
12589 2012-02-13  Jakub Jelinek  <jakub@redhat.com>
12591         PR c++/52215
12592         * c-common.c (sync_resolve_params): Don't decide whether to convert
12593         or not based on TYPE_SIZE comparison, convert whenever arg_type
12594         is unsigned INTEGER_TYPE.
12596 2012-02-06  Paolo Carlini  <paolo.carlini@oracle.com>
12598         PR c/52118
12599         * c.opt ([Wunused-local-typedefs]): Fix description.
12601 2012-01-24  Mike Stump  <mikestump@comcast.net>
12603         * c-common.c (c_common_type_for_mode): Match signed/unsigned types
12604         exactly.
12606 2012-01-18  Richard Guenther  <rguenther@suse.de>
12608         * c-opts.c (c_common_post_options): Reset LTO flags if
12609         we are about to generate a PCH.
12611 2012-01-17  Paolo Carlini  <paolo.carlini@oracle.com>
12613         PR c++/51777
12614         * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
12615         use pp_unsigned_wide_integer.
12617 2012-01-10  Richard Guenther  <rguenther@suse.de>
12619         PR middle-end/51806
12620         * c-opts.c (c_common_handle_option): Move -Werror handling
12621         to language independent code.
12623 2012-01-05  Richard Guenther  <rguenther@suse.de>
12625         PR middle-end/51764
12626         * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
12627         from common.opt.
12629 2011-12-30  Paolo Carlini  <paolo.carlini@oracle.com>
12631         PR c++/51316
12632         * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
12633         of array types with an unknown bound.
12635 2011-12-20  Joseph Myers  <joseph@codesourcery.com>
12637         * c-common.c (flag_isoc99): Update comment to refer to C11.
12638         (flag_isoc1x): Change to flag_isoc11.
12639         * c-common.h (flag_isoc99): Update comment to refer to C11.
12640         (flag_isoc1x): Change to flag_isoc11.
12641         * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
12642         C11.
12643         * c-opts.c (set_std_c1x): Change to set_std_c11.
12644         (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
12645         Call set_std_c11.
12646         (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
12647         (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
12648         * c.opt (std=c1x): Change to std=c11.  Document as non-draft
12649         standard.
12650         (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
12651         (std=gnu1x): Change to std=gnu11.  Refer to non-draft standard.
12652         (std=gnu1x): Make alias of std=gnu11.
12654 2011-12-19  Jason Merrill  <jason@redhat.com>
12656         PR c++/51228
12657         * c-common.c (handle_transparent_union_attribute): Check the first
12658         field if the type is complete.
12660 2011-12-15  Jonathan Wakely  <jwakely.gcc@gmail.com>
12662         PR libstdc++/51365
12663         * c-common.c (RID_IS_FINAL): Add.
12664         * c-common.h (RID_IS_FINAL): Add.
12666 2011-11-30  Iain Sandoe  <iains@gcc.gnu.org>
12668         * c.opt (fgnu-runtime): Provide full description.
12669         (fnext-runtime): Likewise.
12670         * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
12672 2011-11-28  Andrew MacLeod  <amacleod@redhat.com>
12674         * c-cpp-builtin.c (cpp_atomic_builtins):New.  Emit all atomic
12675         predefines in one place.  Add LOCK_FREE predefines.
12676         (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
12677         new func.
12679 2011-11-24  Andrew MacLeod  <amacleod@redhat.com>
12681         PR c/51256
12682         * c-common.c (get_atomic_generic_size): Check for various error
12683         conditions
12684         (resolve_overloaded_atomic_exchange,
12685         resolve_overloaded_atomic_compare_exchange,
12686         resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
12687         error_mark_node for error conditions.
12689 2011-11-08  Richard Guenther  <rguenther@suse.de>
12691         PR middle-end/51010
12692         * c-pretty-print.c (pp_c_expression): Handle SSA_NAMEs.
12694 2011-11-07  Richard Henderson  <rth@redhat.com>
12695             Aldy Hernandez  <aldyh@redhat.com>
12696             Torvald Riegel  <triegel@redhat.com>
12698         Merged from transactional-memory.
12700         * c-common.c (handle_tm_wrap_attribute,
12701         handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
12702         (struct c_common_reswords): Added __transaction* keywords.
12703         (struct c_common_attribute_table): Added transaction* and tm_regparm
12704         attributes.
12705         * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
12706         masks.
12707         (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
12708         find_tm_attribute): Declare.
12710 2011-11-07  Jason Merrill  <jason@redhat.com>
12712         PR c++/35688
12713         * c-common.c, c-common.h: Revert yesterday's changes.
12715 2011-11-06  Jason Merrill  <jason@redhat.com>
12717         PR c++/35688
12718         * c-common.c (decl_has_visibility_attr): Split out from...
12719         (c_determine_visibility): ...here.
12720         * c-common.h: Declare it.
12722 2011-11-06  Joseph Myers  <joseph@codesourcery.com>
12724         * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
12725         (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
12726         type.
12727         (check_user_alignment): New.  Split out of
12728         handle_aligned_attribute.  Disallow integer constants with
12729         noninteger types.  Conditionally allow zero.
12730         (handle_aligned_attribute): Use check_user_alignment.
12731         * c-common.h (RID_ALIGNAS, check_user_alignment): New.
12733 2011-11-06  Andrew MacLeod  <amacleod@redhat.com>
12734             Richard Henderson  <rth@redhat.com>
12736         Merged from cxx-mem-model.
12738         * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
12739         * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
12740         parameters that are the same type size.
12741         (get_atomic_generic_size): New.  Find size of generic
12742         atomic function parameters and do typechecking.
12743         (add_atomic_size_parameter): New.  Insert size into parameter list.
12744         (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
12745         either __atomic_exchange_n or external library call.
12746         (resolve_overloaded_atomic_compare_exchange): Restructure
12747         __atomic_compare_exchange to either _n variant or external library call.
12748         (resolve_overloaded_atomic_load): Restructure __atomic_load to either
12749         __atomic_load_n or an external library call.
12750         (resolve_overloaded_atomic_store): Restructure __atomic_store to either
12751         __atomic_store_n or an external library call.
12752         (resolve_overloaded_builtin): Handle new __atomic builtins.
12754 2011-11-04  Eric Botcazou  <ebotcazou@adacore.com>
12756         PR c++/50608
12757         * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
12758         (fold_offsetof_1): Make global.  Remove STOP_REF argument and adjust.
12759         <INDIRECT_REF>: Return the argument.
12760         <ARRAY_REF>: Remove special code for negative offset.
12761         Call fold_build_pointer_plus instead of size_binop.
12762         (fold_offsetof): Remove STOP_REF argument and adjust.
12763         * c-common.h (fold_offsetof_1): Declare.
12764         (fold_offsetof): Remove STOP_REF argument.
12766 2011-11-02  Paolo Carlini  <paolo.carlini@oracle.com>
12768         PR c++/50810
12769         * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
12770         of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
12771         Wnarrowing for C++0x and C++98.
12772         * c.opt ([Wnarrowing]): Update.
12774 2011-11-01  Paolo Carlini  <paolo.carlini@oracle.com>
12776         PR c++/44277
12777         * c.opt: Add Wzero-as-null-pointer-constant.
12779 2011-10-31  Jason Merrill  <jason@redhat.com>
12781         * c.opt (-fdeduce-init-list): Off by default.
12783         PR c++/50920
12784         * c-common.h (cxx_dialect): Add cxx11 and cxx03.
12785         * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
12786         and -Wc++11-compat.
12787         * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
12789 2011-10-27  Roberto Agostino Vitillo  <ravitillo@lbl.gov>
12791         PR c++/30066
12792         * c.opt (fvisibility-inlines-hidden): Description change.
12794 2011-10-26  Ed Smith-Rowland  <3dw4rd@verizon.net>
12796         Implement C++11 user-defined literals.
12797         * c-common.c (build_userdef_literal): New.
12798         * c-common.def: New tree code.
12799         * c-common.h (tree_userdef_literal): New tree struct and accessors.
12800         * c-lex.c (interpret_float): Add suffix parm.
12801         (c_lex_with_flags): Build literal tokens.
12803 2011-10-23  Paolo Carlini  <paolo.carlini@oracle.com>
12805         PR c++/50841
12806         Revert:
12807         2011-10-23  Paolo Carlini  <paolo.carlini@oracle.com>
12809         PR c++/50810
12810         * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
12811         of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
12812         Wnarrowing for C++0x and C++98.
12813         * c.opt ([Wnarrowing]): Update.
12815 2011-10-23  Paolo Carlini  <paolo.carlini@oracle.com>
12817         PR c++/50810
12818         * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
12819         of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
12820         Wnarrowing for C++0x and C++98.
12821         * c.opt ([Wnarrowing]): Update.
12823 2011-10-21  Paolo Carlini  <paolo.carlini@oracle.com>
12825         PR c++/45385
12826         * c-common.c (conversion_warning): Remove code looking for
12827         artificial operands.
12829 2011-10-18  Dodji Seketeli  <dodji@redhat.com>
12831         PR bootstrap/50760
12832         * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
12833         !NO_IMPLICIT_EXTERN_C.
12835 2011-10-17  Michael Spertus  <mike_spertus@symantec.com>
12837         * c-common.c (c_common_reswords): Add __bases,
12838         __direct_bases.
12839         * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
12841 2011-10-17  Paolo Carlini  <paolo.carlini@oracle.com>
12843         PR c++/50757
12844         * c.opt ([Wnonnull]): Add C++ and Objective-C++.
12846 2011-10-15  Tom Tromey  <tromey@redhat.com>
12847             Dodji Seketeli  <dodji@redhat.com>
12849         * c.opt (fdebug-cpp): New option.
12850         * c-opts.c (c_common_handle_option): Handle the option.
12851         * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
12852         output stream in parameter. Factorized from ...
12853         (maybe_print_line): ... this. Dump location debug information when
12854         -fdebug-cpp is in effect.
12855         (print_line_1): New static function. Takes an output stream in
12856         parameter. Factorized from ...
12857         (print_line): ... here. Dump location information when -fdebug-cpp
12858         is in effect.
12859         (scan_translation_unit): Dump location information when
12860         -fdebug-cpp is in effect.
12862 2011-10-15  Tom Tromey  <tromey@redhat.com>
12863             Dodji Seketeli  <dodji@redhat.com>
12865         * c.opt (ftrack-macro-expansion): New option. Handle it with and
12866         without argument.
12867         * c-opts.c (c_common_handle_option)<case
12868         OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
12869         cases. Handle -ftrack-macro-expansion with and without argument.
12871 2011-10-15  Tom Tromey  <tromey@redhat.com>
12872             Dodji Seketeli  <dodji@redhat.com>
12874         * c-ppoutput.c (scan_translation_unit, maybe_print_line)
12875         (print_line, cb_define, do_line_change): Adjust to avoid touching
12876         the internals of struct line_map.  Use the public API instead.
12877         * c-pch.c (c_common_read_pch): Likewise.
12878         * c-lex.c (fe_file_change): Likewise.
12880 2011-10-14  Paolo Carlini  <paolo.carlini@oracle.com>
12882         PR c++/17212
12883         * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
12885 2011-10-11  Paolo Carlini  <paolo.carlini@oracle.com>
12887         PR c++/33067
12888         * c-pretty-print.c (pp_c_floating_constant): Output
12889         max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
12891 2011-10-11  Michael Meissner  <meissner@linux.vnet.ibm.com>
12893         * c-common.c (def_builtin_1): Delete old interface with two
12894         parallel arrays to hold standard builtin declarations, and replace
12895         it with a function based interface that can support creating
12896         builtins on the fly in the future.  Change all uses, and poison
12897         the old names.  Make sure 0 is not a legitimate builtin index.
12898         * c-omp.c (c_finish_omp_barrier): Ditto.
12899         (c_finish_omp_taskwait): Ditto.
12900         (c_finish_omp_flush): Ditto.
12902 2011-10-11  Tristan Gingold  <gingold@adacore.com>
12904         * c.opt: (fallow-parameterless-variadic-functions): New.
12906 2011-09-08  Dodji Seketeli  <dodji@redhat.com>
12908         PR c++/33255 - Support -Wunused-local-typedefs warning
12909         * c-common.h (struct c_language_function::local_typedefs): New
12910         field.
12911         (record_locally_defined_typedef, maybe_record_typedef_use)
12912         (maybe_warn_unused_local_typedefs): Declare new functions.
12913         * c-common.c (record_locally_defined_typedef)
12914         (maybe_record_typedef_use)
12915         (maybe_warn_unused_local_typedefs): Define new functions.
12916         * c.opt: Declare new -Wunused-local-typedefs flag.
12918 2011-09-06  Eric Botcazou  <ebotcazou@adacore.com>
12920         PR middle-end/50266
12921         * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
12922         computations.
12924 2011-09-05  Richard Guenther  <rguenther@suse.de>
12926         * c-common.c (complete_array_type): Use ssize_int (-1) instead
12927         of integer_minus_one_node for empty array upper bounds.
12929 2011-08-28  Dodji Seketeli  <dodji@redhat.com>
12931         * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
12932         it's the first time it's being called on this main TU.
12934 2011-08-24  Richard Guenther  <rguenther@suse.de>
12936         PR c/49396
12937         * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
12939 2011-08-22  Gabriel Charette  <gchare@google.com>
12941         * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
12942         defined in cpp_init_builtins and c_cpp_builtins.
12944 2011-08-19  Joseph Myers  <joseph@codesourcery.com>
12946         * c-common.c (c_common_reswords): Add __builtin_complex.
12947         * c-common.h (RID_BUILTIN_COMPLEX): New.
12949 2011-08-18  Joseph Myers  <joseph@codesourcery.com>
12951         * c-common.c (c_common_reswords): Add _Noreturn.
12952         (keyword_is_function_specifier): Handle RID_NORETURN.
12953         * c-common.h (RID_NORETURN): New.
12955 2011-08-10  Artjoms Sinkarovs  <artyom.shinakroff@gmail.com>
12957         * c-common.c (unsafe_conversion_p): New function. Check if it is
12958         unsafe to convert an expression to the type.
12959         (conversion_warning): Adjust, use unsafe_conversion_p.
12960         * c-common.h (unsafe_conversion_p): New function declaration.
12962 2011-08-02  Jakub Jelinek  <jakub@redhat.com>
12964         * c-common.h (c_finish_omp_atomic): Adjust prototype.
12965         (c_finish_omp_taskyield): New prototype.
12966         * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
12967         arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
12968         OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC.  If LHS1
12969         or RHS1 have side-effects, evaluate those too in the right spot,
12970         if it is a decl and LHS is also a decl, error out if they
12971         aren't the same.
12972         (c_finish_omp_taskyield): New function.
12973         * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
12974         * c-pragma.c (omp_pragmas): Add taskyield.
12975         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
12976         (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
12977         PRAGMA_OMP_CLAUSE_MERGEABLE.
12979 2011-07-25  Dodji Seketeli  <dodji@redhat.com>
12981         * c-common.h (set_underlying_type): Remove parm name from
12982         declaration.
12984 2011-07-25  Romain Geissler  <romain.geissler@gmail.com>
12986         * c-pretty-print.h: Search c-common.h in c-family.
12988 2011-07-22  Jason Merrill  <jason@redhat.com>
12990         PR c++/49793
12991         * c.opt (Wnarrowing): New.
12993         PR c++/30112
12994         * c-common.h: Declare c_linkage_bindings.
12995         * c-pragma.c (handle_pragma_redefine_extname): Use it.
12997         PR c++/49813
12998         * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
12999         * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
13000         as flag_isoc99 for 'restrict'.
13001         (pp_c_specifier_qualifier_list): Likewise for _Complex.
13003 2011-07-21  Ian Lance Taylor  <iant@google.com>
13005         PR middle-end/49705
13006         * c-common.c (c_disable_warnings): New static function.
13007         (c_enable_warnings): New static function.
13008         (c_fully_fold_internal): Change local unused_p to bool.  Call
13009         c_disable_warnings and c_enable_warnings rather than change
13010         c_inhibit_evaluation_warnings.
13012 2011-07-20  Jason Merrill  <jason@redhat.com>
13014         PR c++/6709 (DR 743)
13015         PR c++/42603 (DR 950)
13016         * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
13017         (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
13018         (CPP_DECLTYPE): New.
13019         * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
13021 2011-07-19  Richard Guenther  <rguenther@suse.de>
13023         * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
13024         * c-omp.c (c_finish_omp_for): Likewise.
13026 2011-07-12  Eric Botcazou  <ebotcazou@adacore.com>
13028         * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
13029         body on the next line.
13031 2011-07-08  Jason Merrill  <jason@redhat.com>
13033         PR c++/45437
13034         * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
13036         PR c++/49673
13037         * c-common.c (c_apply_type_quals_to_decl): Don't check
13038         TYPE_NEEDS_CONSTRUCTING.
13040 2011-07-06  Richard Guenther  <rguenther@suse.de>
13042         * c-common.c (c_common_nodes_and_builtins):
13043         Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
13045 2011-07-05  Richard Guenther  <rguenther@suse.de>
13047         * c-common.c (c_common_nodes_and_builtins): Build all common
13048         tree nodes first.
13050 2011-06-27  Jakub Jelinek  <jakub@redhat.com>
13052         * c-common.h (c_tree_chain_next): New static inline function.
13054         * c-common.c (check_builtin_function_arguments): Handle
13055         BUILT_IN_ASSUME_ALIGNED.
13057 2011-06-21  Andrew MacLeod  <amacleod@redhat.com>
13059         * c-common.c: Add sync_ or SYNC__ to builtin names.
13060         * c-omp.c: Add sync_ or SYNC__ to builtin names.
13062 2011-06-20  Pierre Vittet  <piervit@pvittet.com>
13064         * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
13065         handler.
13066         (gen_pragma_handler): New union.
13067         (internal_pragma_handler): New type.
13068         (c_register_pragma_with_data)
13069         (c_register_pragma_with_expansion_and_data): New functions.
13071         * c-pragma.c (registered_pragmas, c_register_pragma_1)
13072         (c_register_pragma, c_register_pragma_with_expansion)
13073         (c_invoke_pragma_handler): Changed to work with
13074         internal_pragma_handler.
13075         (c_register_pragma_with_data)
13076         (c_register_pragma_with_expansion_and_data): New functions.
13078 2011-06-14  Joseph Myers  <joseph@codesourcery.com>
13080         * c-common.c: Include common/common-target.h.
13081         (handle_section_attribute): Use
13082         targetm_common.have_named_sections.
13083         * c-cppbuiltin.c: Include common/common-target.h.
13084         (c_cpp_builtins): Use targetm_common.except_unwind_info.
13086 2011-06-10  Richard Guenther  <rguenther@suse.de>
13088         * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
13089         to print a IDENTIFIER_NODE.
13091 2011-06-09  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
13092             Joseph Myers  <joseph@codesourcery.com>
13094         * c.opt (fbuilding-libgcc): New option.
13095         * c-cppbuiltin.c (c_cpp_builtins): Define
13096         __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
13098 2011-06-07  Jason Merrill  <jason@redhat.com>
13100         * c-common.c (max_tinst_depth): Lower default to 900.
13102         * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
13104 2011-06-07  Richard Guenther  <rguenther@suse.de>
13106         * c-common.c (c_common_nodes_and_builtins): Do not set
13107         size_type_node or call set_sizetype.
13109 2011-06-07  Dodji Seketeli  <dodji@redhat.com>
13111         PR debug/49130
13112         * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
13113         type when using pointer comparison to compare types.
13115 2011-06-02  Jonathan Wakely  <jwakely.gcc@gmail.com>
13117         * c.opt: Add -Wdelete-non-virtual-dtor.
13118         * c-opts.c (c_common_handle_option): Include it in -Wall.
13120 2011-05-30  Nathan Froyd  <froydnj@gcc.gnu.org>
13122         PR bootstrap/49190
13124         Revert:
13125         2011-05-26  Nathan Froyd  <froydnj@codesourcery.com>
13127         * c-common.h (struct c_common_identifier): Inherit from tree_typed,
13128         not tree_common.
13130 2011-05-27  Jakub Jelinek  <jakub@redhat.com>
13132         PR c++/49165
13133         * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
13134         C++ don't call c_common_truthvalue_conversion on void type arms.
13136 2011-05-27  Nathan Froyd  <froydnj@codesourcery.com>
13138         * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
13139         (stmt_list_stack): Define.
13140         (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
13141         * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
13143 2011-05-26  Nathan Froyd  <froydnj@codesourcery.com>
13145         * c-common.c (warning_candidate_p): Check for BLOCKs.
13147 2011-05-26  Nathan Froyd  <froydnj@codesourcery.com>
13149         * c-common.h (struct c_common_identifier): Inherit from tree_typed,
13150         not tree_common.
13152 2011-05-25  Jakub Jelinek  <jakub@redhat.com>
13154         * c-common.c (def_fn_type): Remove extra va_end.
13156 2011-05-23  Jason Merrill  <jason@redhat.com>
13158         PR c++/48106
13159         * c-common.c (c_common_get_narrower): New.
13160         (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
13162 2011-05-23  Nathan Froyd  <froydnj@codesourcery.com>
13164         * c-common.h (check_function_arguments): Tweak prototype of
13165         check_function_arguments.
13166         * c-common.c (check_function_arguments): Likewise.  Adjust
13167         calls to check_function_nonnull, check_function_format, and
13168         check_function_sentinel.
13169         (check_function_sentinel): Take a FUNCTION_TYPE rather than
13170         separate attributes and typelist arguments.  Use
13171         FOREACH_FUNCTION_ARGS to iterate over argument types.
13173 2011-05-15  Paolo Carlini  <paolo.carlini@oracle.com>
13175         * c-common.c (c_common_reswords): Reorder.
13176         * c-common.h (rid): Likewise.
13178 2011-05-10  Nathan Froyd  <froydnj@codesourcery.com>
13180         * c-common.c (def_fn_type): Don't call build_function_type, call
13181         build_function_type_array or build_varargs_function_type_array
13182         instead.
13183         (c_common_nodes_and_builtins): Likewise.
13185 2011-05-05  Nathan Froyd  <froydnj@codesourcery.com>
13187         * c-common.c (c_add_case_label): Omit the loc argument to
13188         build_case_label.
13189         * c-common.h (build_case_label): Remove.
13190         * c-semantics.c (build_case_label): Remove.
13192 2011-05-05  Joseph Myers  <joseph@codesourcery.com>
13194         * c-objc.h (objc_start_method_definition): Update prototype.
13195         * stub-objc.c (objc_start_method_definition): Add extra parameter.
13197 2011-05-04  Nathan Froyd  <froydnj@codesourcery.com>
13199         * c-common.c (check_main_parameter_types): Reindent.  Don't use
13200         TYPE_ARG_TYPES directly.
13201         (handle_nonnull_attribute): Likewise.
13202         (sync_resolve_params): Likewise.
13203         * c-format.c (handle_format_arg_attribute): Likewise.  Adjust call
13204         to check_format_string.
13205         (handle_format_attribute): Likewise.
13206         (check_format_string): Take a function type to examine instead of
13207         a type list.  Use a function_arg_iterator to step through argument
13208         types.
13210 2011-05-04  Richard Guenther  <rguenther@suse.de>
13212         * c-common.c (fix_string_type): Use size_int for index type bounds.
13213         (start_fname_decls): Do not pass NULL to build_int_cst.
13214         (c_init_attributes): Likewise.
13215         * c-lex.c (c_lex_with_flags): Likewise.
13217 2011-04-27  Jason Merrill  <jason@redhat.com>
13219         * c-common.c (make_tree_vector_from_list): New.
13220         * c-common.h: Declare it.
13222 2011-04-26  Richard Guenther  <rguenther@suse.de>
13224         PR preprocessor/48248
13225         * c-ppoutput.c (maybe_print_line): Always optimize newlines
13226         for output size with -P.
13228 2011-04-25  Paolo Carlini  <paolo.carlini@oracle.com>
13230         * c-common.c (struct c_common_resword): Add __underlying_type.
13231         * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
13233 2011-04-20  Jim Meyering  <meyering@redhat.com>
13235         * c-format.c (init_dollar_format_checking): Remove useless
13236         if-before-free.
13238 2011-04-15  Nicola Pero  <nicola.pero@meta-innovation.com>
13240         * c-objc.h (objc_get_interface_ivars): Removed.
13241         (objc_detect_field_duplicates): New.
13242         * stub-objc.c: Likewise.
13244 2011-04-14  Nicola Pero  <nicola.pero@meta-innovation.com>
13246         * stub-objc.c (objc_declare_protocols): Renamed to
13247         objc_declare_protocol.
13248         * c-objc.h: Likewise.
13250 2011-04-14  Nicola Pero  <nicola.pero@meta-innovation.com>
13252         * stub-objc.c (objc_declare_class): Updated argument name.
13254 2011-04-12  Nathan Froyd  <froydnj@codesourcery.com>
13256         * c-common.h (c_common_init_ts): Declare.
13257         * c-common.c (c_common_init_ts): Define.
13259 2011-04-12  Nicola Pero  <nicola.pero@meta-innovation.com>
13261         * c-objc.h (objc_build_message_expr): Updated prototype.
13262         * stub-objc.c (objc_build_message_expr): Likewise.
13264 2011-04-12  Martin Jambor  <mjambor@suse.cz>
13266         * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
13267         of cgraph_node.
13269 2011-04-11  Richard Guenther  <rguenther@suse.de>
13271         * c-common.c (complete_array_type): Build a range type of
13272         proper type.
13274 2011-04-08  Nathan Froyd  <froydnj@codesourcery.com>
13276         * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
13277         (handle_type_generic_attribute): Likewise.
13279 2011-04-07  Jason Merrill  <jason@redhat.com>
13281         PR c++/48450
13282         * c-common.c (c_common_truthvalue_conversion): Don't ignore
13283         conversion from C++0x scoped enum.
13285 2011-04-06  Joseph Myers  <joseph@codesourcery.com>
13287         * c-target-def.h: New file.
13288         * c-target.def: New file.
13289         * c-target.h: New file.
13290         * c-common.c (targetcm): Don't define here.
13291         * c-common.h (default_handle_c_option): Declare.
13292         * c-format.c: Include c-target.h instead of target.h.
13293         * c-opts.c: Include c-target.h instead of target.h.  Explicitly
13294         include tm.h.
13295         (default_handle_c_option): Move from targhooks.c.
13297 2011-03-29  Jakub Jelinek  <jakub@redhat.com>
13299         PR preprocessor/48248
13300         * c-ppoutput.c (print): Add src_file field.
13301         (init_pp_output): Initialize it.
13302         (maybe_print_line): Don't optimize by adding up to 8 newlines
13303         if map->to_file and print.src_file are different file.
13304         (print_line): Update print.src_file.
13306 2011-03-25  Kai Tietz  <ktietz@redhat.com>
13308         * c-ada-spec.c (compare_comment): Use filename_cmp
13309         instead of strcmp for filename.
13311 2011-03-25  Jeff Law  <law@redhat.com>
13313         * c-common.c (def_fn_type): Add missing va_end.
13315 2011-03-25  Jason Merrill  <jason@redhat.com>
13317         * c.opt: Add -std=c++03.
13319 2011-03-22  Eric Botcazou  <ebotcazou@adacore.com>
13321         * c-ada-spec.c (dump_ada_template): Skip non-class instances.
13323 2011-03-17  Kai Tietz  <ktietz@redhat.com>
13325         PR target/12171
13326         * c-pretty-print.c (pp_c_specifier_qualifier_list):
13327         Display allowed attributes for function pointer types.
13328         (pp_c_attributes_display): New function to display
13329         attributes having affects_type_identity flag set to true.
13330         * c-pretty-print.h (pp_c_attributes_display): New prototype.
13332         * c-common.c (c_common_attribute_table):
13333         Add new element.
13334         (c_common_format_attribute_table): Likewise.
13336 2011-03-18  Jason Merrill  <jason@redhat.com>
13338         * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
13339         * c-common.h: Don't declare it here.
13340         * c-common.c: Or define it here.
13341         * c-opts.c (c_common_handle_option): Or set it here.
13343         PR c++/35315
13344         * c-common.c (handle_transparent_union_attribute): Don't
13345         make a duplicate type in C++.
13347 2011-03-15  Jason Merrill  <jason@redhat.com>
13349         * c-common.c (max_constexpr_depth): New.
13350         * c-common.h: Declare it.
13351         * c-opts.c (c_common_handle_option): Set it.
13352         * c.opt (fconstexpr-depth): New option.
13354 2011-03-11  Jason Merrill  <jason@redhat.com>
13356         * c-common.c (attribute_takes_identifier_p): Add missing const.
13358         PR c++/46803
13359         * c-common.c (attribute_takes_identifier_p): Assume that an
13360         unknown attribute takes an identifier.
13362 2011-03-07  Nathan Froyd  <froydnj@codesourcery.com>
13364         PR c/47786
13365         * c-common.c (c_type_hash): Call list_length instead of iterating
13366         through DECL_CHAIN.  Rename 'i' to 'n_elements'.
13368 2011-02-19  Jakub Jelinek  <jakub@redhat.com>
13370         PR c/47809
13371         * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
13373 2011-02-17  Iain Sandoe  <iains@gcc.gnu.org>
13375         * c.opt (fobjc-abi-version=) New.
13376         (fobjc-nilcheck): New.
13378 2011-02-03  Nathan Froyd  <froydnj@codesourcery.com>
13380         PR c++/46890
13381         * c-common.h (keyword_is_decl_specifier): Declare.
13382         * c-common.c (keyword_is_decl_specifier): Define.
13383         (keyword_is_function_specifier): New function.
13385 2011-01-26  Jakub Jelinek  <jakub@redhat.com>
13387         PR c/47473
13388         * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
13389         EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
13390         REAL_TYPE.
13392 2011-01-26  Arnaud Charlet  <charlet@adacore.com>
13394         * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
13396 2011-01-26  Jakub Jelinek  <jakub@redhat.com>
13398         PR pch/47430
13399         * c-opts.c (c_common_post_options): Call c_common_no_more_pch
13400         after init_c_lex if pch_file is set.
13402 2011-01-26  Dave Korn  <dave.korn.cygwin@gmail.com>
13404         PR c++/43601
13405         * c.opt (-fkeep-inline-dllexport): New switch.
13407 2011-01-12  Richard Guenther  <rguenther@suse.de>
13409         PR middle-end/32511
13410         * c-common.c (handle_weak_attribute): Warn instead of error
13411         on declaring an inline function weak.
13413 2011-01-05  Tom Tromey  <tromey@redhat.com>
13415         * c-common.h (lvalue_error): Update.
13416         * c-common.c (lvalue_error): Add 'loc' argument.  Call error_at,
13417         not error.
13419 2010-12-29  Nicola Pero  <nicola.pero@meta-innovation.com>
13421         PR objc/47075
13422         * c-objc.h (objc_finish_message_expr): Added argument to
13423         prototype.
13425 2010-12-22  Nathan Froyd  <froydnj@codesourcery.com>
13427         * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
13428         Use prototype_p.
13430 2010-12-18  Nicola Pero  <nicola.pero@meta-innovation.com>
13432         * c-objc.h (objc_maybe_warn_exceptions): New.
13433         * stub-objc.c (objc_maybe_warn_exceptions): New.
13435 2010-12-10  Nathan Froyd  <froydnj@codesourcery.com>
13437         * c-common.h (readonly_error): Declare.
13438         * c-common.c (readonly_error): Define.
13440 2010-12-09  Nathan Froyd  <froydnj@codesourcery.com>
13442         * c-common.h (invalid_indirection_error): Declare.
13443         * c-common.c (invalid_indirection_error): Define.
13445 2010-12-03  Richard Guenther  <rguenther@suse.de>
13447         PR c/46745
13448         * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
13449         (pp_c_unary_expression): Likewise.
13450         (pp_c_expression): Likewise.
13452 2010-11-30  Nicola Pero  <nicola.pero@meta-innovation.com>
13454         * c-common.h (objc_finish_function): New.
13455         (objc_non_volatilized_type): Removed.
13456         (objc_type_quals_match): Removed.
13457         * stub-objc.c (objc_finish_function): New.
13458         (objc_non_volatilized_type): Removed.
13459         (objc_type_quals_match): Removed.
13461 2010-11-30  Joseph Myers  <joseph@codesourcery.com>
13463         * c-common.h (parse_optimize_options): Declare.
13464         * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
13465         c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
13467 2010-11-29  Joseph Myers  <joseph@codesourcery.com>
13469         * c-opts.c (check_deps_environment_vars): Use getenv instead of
13470         GET_ENVIRONMENT.
13471         * c-pch.c (O_BINARY): Don't define here.
13472         * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
13474 2010-11-25  Joseph Myers  <joseph@codesourcery.com>
13476         * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
13477         targetm.except_unwind_info.
13479 2010-11-23  Joseph Myers  <joseph@codesourcery.com>
13481         * c-opts.c (c_common_handle_option): Pass location to
13482         set_struct_debug_option.
13484 2010-11-23  Joseph Myers  <joseph@codesourcery.com>
13486         * c-common.c (visibility_options): Move from ../opts.c.
13487         * c-common.h (struct visibility_flags, visibility_options):
13488         Declare here.
13489         * c-opts.c (finish_options): Rename to c_finish_options.
13490         (c_common_init): Update call to finish_options.
13492 2010-11-22  Nicola Pero  <nicola.pero@meta-innovation.com>
13494         PR objc/34033
13495         * c-lex.c (lex_string): Check that each string in an Objective-C
13496         string concat sequence starts with either one or zero '@', and
13497         that there are no spurious '@' signs at the end.
13499 2010-11-20  Joseph Myers  <joseph@codesourcery.com>
13501         * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
13502         HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
13503         HANDLE_PRAGMA_VISIBILITY.
13504         * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
13505         HANDLE_PRAGMA_VISIBILITY): Don't define.
13506         (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
13508 2010-11-20  Nathan Froyd  <froydnj@codesourcery.com>
13510         PR c++/16189
13511         PR c++/36888
13512         PR c++/45331
13513         * c-common.h (keyword_begins_type_specifier): Declare.
13514         (keyword_is_storage_class_specifier): Declare.
13515         (keyword_is_type_qualifier): Declare.
13516         * c-common.c (keyword_begins_type_specifier): New function.
13517         (keyword_is_storage_class_specifier): New function.
13518         (keyword_is_type_qualifier): Declare.
13520 2010-11-19  Joseph Myers  <joseph@codesourcery.com>
13522         PR c/46547
13523         * c-common.c (in_late_binary_op): Define.
13524         (c_common_truthvalue_conversion): Check in_late_binary_op before
13525         calling c_save_expr.
13526         * c-common.h (in_late_binary_op): Declare.
13528 2010-11-19  Joseph Myers  <joseph@codesourcery.com>
13530         * c-opts.c (c_common_handle_option): Update calls to
13531         set_struct_debug_option.
13533 2010-11-19  Nicola Pero  <nicola.pero@meta-innovation.com>
13535         * c-common.h (objc_declare_protocols): Added additional argument.
13536         * stub-objc.c (objc_declare_protocol): Same change.
13538 2010-11-18  Nathan Froyd  <froydnj@codesourcery.com>
13540         PR c/33193
13541         * c-common.h (build_real_imag_expr): Declare.
13542         * c-semantics.c (build_real_imag_expr): Define.
13544 2010-11-17  Joseph Myers  <joseph@codesourcery.com>
13546         * c-opts.c (c_common_parse_file): Take no arguments.
13547         * c-common.h (c_common_parse_file): Update prototype.
13549 2010-11-16  Jakub Jelinek  <jakub@redhat.com>
13551         PR c++/46401
13552         * c-common.c (warning_candidate_p): Don't track non-const calls
13553         or STRING_CSTs.
13555 2010-11-15  Ian Lance Taylor  <iant@google.com>
13557         * c-lex.c (init_c_lex): Set macro debug callbacks if
13558         flag_dump_go_spec is set.
13560 2010-11-15  Nicola Pero  <nicola.pero@meta-innovation.com>
13562         * c-common.h (objc_build_incr_expr_for_property_ref): New.
13563         * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
13565 2010-11-15  Nathan Froyd  <froydnj@codesourcery.com>
13567         PR preprocessor/45038
13568         * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
13569         dialects.
13571 2010-11-12  Joseph Myers  <joseph@codesourcery.com>
13573         * c-common.h (c_family_lang_mask): Declare.
13574         * c-opts.c (c_family_lang_mask): Make extern.
13575         * c-pragma.c (handle_pragma_diagnostic): Use
13576         control_warning_option.
13578 2010-11-12  Joseph Myers  <joseph@codesourcery.com>
13580         * c-common.c (parse_optimize_options): Update call to
13581         decode_options.
13582         * c-common.h (c_common_handle_option): Update prototype.
13583         * c-opts.c (c_common_handle_option): Take location_t parameter and
13584         pass it to other functions.
13586 2010-11-11  Joseph Myers  <joseph@codesourcery.com>
13588         * c-opts.c (warning_as_error_callback): Remove.
13589         (c_common_initialize_diagnostics): Don't call
13590         register_warning_as_error_callback.
13591         (c_common_handle_option): Handle -Werror=normalized= here.
13593 2010-11-10  Joseph Myers  <joseph@codesourcery.com>
13595         * c-common.c (handle_mode_attribute): Use %' and word "signedness"
13596         in diagnostic.
13597         * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
13598         letter.
13599         * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
13600         Remove trailing '.' from diagnostics.
13601         * c.opt (Wwrite-strings_: Avoid '`' in help text.
13603 2010-11-10  Joseph Myers  <joseph@codesourcery.com>
13605         * c-common.c (parse_optimize_options): Pass global_dc to
13606         decode_options.
13607         * c-opts.c (c_common_handle_option): Pass &global_options to
13608         set_Wstrict_aliasing.
13609         * c.opt (v): Don't mark Common or document here.
13611 2010-11-06  Iain Sandoe  <iains@gcc.gnu.org>
13613         PR target/44981
13614         * c-format.c (format_type): New type gcc_objc_string_format_type.
13615         (valid_stringptr_type_p): New.
13616         (handle_format_arg_attribute): Use valid_stringptr_type_p ().
13617         (check_format_string): Pass expected type, use
13618         valid_stringptr_type_p (), check that the format string types are
13619         consistent with the format specification.
13620         (decode_format_attr): Warn if NSString is used outside objective-c.
13621         (format_types_orig): Add NSString.
13622         (format_name): New.
13623         (format_flags): New.
13624         (check_format_arg): Handle format strings requiring an external parser.
13625         first_target_format_type: New variable.
13626         (handle_format_attribute): Set up first_target_format_type, pass the
13627         expected format arg string type to check_format_string().
13628         * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
13629         * stub-objc.c (objc_string_ref_type_p): New.
13630         (objc_check_format_arg): New.
13632 2010-11-04  Nicola Pero  <nicola.pero@meta-innovation.com>
13634         Fixed using the Objective-C 2.0 dot-syntax with class names.
13635         * c-common.h (objc_build_class_component_ref): New.
13636         * stub-objc.c (objc_build_class_component_ref): New.
13638 2010-11-03  Nicola Pero  <nicola.pero@meta-innovation.com>
13640         * c.opt (Wproperty-assign-default): New option.
13642 2010-11-03  Nicola Pero  <nicola.pero@meta-innovation.com>
13644         Implemented -fobjc-std=objc1 flag.
13645         * c.opt (fobjc-std=objc1): New option.
13647 2010-11-01  Nicola Pero  <nicola.pero@meta-innovation.com>
13649         Implemented format and noreturn attributes for Objective-C methods.
13650         * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
13651         attribute for Objective-C methods.
13653 2010-10-31  Jason Merrill  <jason@redhat.com>
13655         * c-common.c (conversion_warning, warn_for_collisions_1): Use
13656         EXPR_LOC_OR_HERE.
13658 2010-10-30  Nicola Pero  <nicola.pero@meta-innovation.com>
13660         Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
13661         * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
13662         (objc_add_property_declaration): Removed arguments for copies and
13663         ivar.
13664         (objc_build_getter_call): Renamed to
13665         objc_maybe_build_component_ref.
13666         (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
13667         (objc_is_property_ref): New.
13668         * c-common.c (c_common_reswords): Removed copies and ivar.
13669         * stub-objc.c (objc_add_property_declaration): Removed arguments
13670         for copies and ivar.
13671         (objc_build_getter_call): Renamed to
13672         objc_maybe_build_component_ref.
13673         (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
13674         (objc_is_property_ref): New.
13676 2010-10-29  Arnaud Charlet  <charlet@adacore.com>
13677             Matthew Gingell  <gingell@adacore.com>
13679         * c-ada-spec.c (separate_class_package): New function.
13680         (pp_ada_tree_identifier): Prefix references to C++ classes with the
13681         name of their enclosing package.
13682         (print_ada_declaration): Use separate_class_package.
13684 2010-10-27  Jason Merrill  <jason@redhat.com>
13686         * c-common.c (c_common_reswords): Add __is_literal_type.
13687         * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
13689         * c-common.c (check_case_value): Remove special C++ code.
13691 2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>
13693         * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
13694         RID_RETAIN, RID_COPY and RID_NONATOMIC.  Updated RID_FIRST_PATTR
13695         and RID_LAST_PATTR.
13696         (objc_add_property_declaration): Added additional arguments.
13697         (objc_property_attribute_kind): Removed.
13698         (objc_set_property_attr): Removed.
13699         * c-common.c (c_common_reswords): Added readwrite, assign, retain,
13700         copy and nonatomic.
13701         * stub-objc.c (objc_add_property_declaration): Added additional
13702         arguments.
13703         (objc_set_property_attr): Removed.
13705 2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>
13707         * c-common.h (objc_add_property_variable): Renamed to
13708         objc_add_property_declaration.  Added location argument.
13709         * stub-objc.c (objc_add_property_variable): Same change.
13711 2010-10-23  Nicola Pero  <nicola.pero@meta-innovation.com>
13713         * c-common.h (objc_maybe_printable_name): New.
13714         * stub-objc.c (objc_maybe_printable_name): New.
13716 2010-10-22  Artjoms Sinkarovs  <artyom.shinakroff@gmail.com>
13717             Andrew Pinski  <pinskia@gmail.com>
13719         * c-common.h (c_common_mark_addressable_vec): Declare.
13720         * c-common.c (c_common_mark_addressable_vec): New function.
13722 2010-10-20  Nicola Pero  <nicola.pero@meta-innovation.com>
13724         * c-common.h (objc_set_method_type): Removed.
13725         (objc_add_method_declaration): Added boolean argument.
13726         (objc_start_method_definition): Same change.
13727         (objc_build_method_signature): Same change.
13728         * stub-objc.c (objc_set_method_type): Removed.
13729         (objc_add_method_declaration): Added boolean argument.
13730         (objc_start_method_definition): Same change.
13731         (objc_build_method_signature): Same change.
13733 2010-10-20  Nicola Pero  <nicola.pero@meta-innovation.com>
13735         * c-common.h (finish_file): Removed.
13736         (objc_write_global_declarations): New.
13737         * c-opts.c (c_common_parse_file): Do not call finish_file.
13738         * stub-objc.c (objc_write_global_declarations): New.
13740 2010-10-18  Nicola Pero  <nicola.pero@meta-innovation.com>
13742         Implemented parsing @synthesize and @dynamic for
13743         Objective-C/Objective-C++.
13744         * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
13745         (objc_add_synthesize_declaration): New.
13746         (objc_add_dynamic_declaration): New.
13747         * c-common.c (c_common_reswords): Add synthesize and dynamic.
13748         * stub-objc.c (objc_add_synthesize_declaration): New.
13749         (objc_add_dynamic_declaration): New.
13751 2010-10-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
13753         PR target/46041
13754         * c-cppbuiltin.c (mode_has_fma): Move function here from
13755         builtins.c.  Don't use the fma optab, instead just use the
13756         HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
13757         using -save-temps.
13759 2010-10-18  Nicola Pero  <nicola.pero@meta-innovation.com>
13761         Merge from 'apple/trunk' branch on FSF servers.
13763         2005-11-08  Fariborz Jahanian  <fjahanian@apple.com>
13765         Radar 4330422
13766         * c-common.h (objc_non_volatilized_type): New declaration
13767         * stub-objc.c (objc_non_volatilized_type): New stub.
13769 2010-10-17  Nicola Pero  <nicola.pero@meta-innovation.com>
13771         Merge from 'apple/trunk' branch on FSF servers.
13773         2006-03-27  Fariborz Jahanian  <fjahanian@apple.com>
13775         Radar 4133425
13776         * c-common.h (objc_diagnose_private_ivar): New decl.
13777         * stub-objc.c (objc_diagnose_private_ivar): New stub.
13779 2010-10-17  Iain Sandoe  <iains@gcc.gnu.org>
13781         * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
13782         * c-common.h (enum rid): Add RID_AT_PACKAGE.
13783         (objc_ivar_visibility_kind): New enum.
13784         (objc_set_visibility): Adjust prototype to use visibility enum.
13785         * stub-objc.c (objc_set_visibility): Adjust stub to use
13786         visibility enum.
13788 2010-10-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
13790         * c-cppbuiltin.c (builtin_define_float_constants): Emit
13791         __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
13792         has the appropriate fma builtins.
13793         (c_cpp_builtins): Adjust call to builtin_define_float_constants.
13795 2010-10-14  Iain Sandoe  <iains@gcc.gnu.org>
13797         merge from FSF apple 'trunk' branch.
13798         2006 Fariborz Jahanian  <fjahanian@apple.com>
13800         Radars 4436866, 4505126, 4506903, 4517826
13801         * c-common.c (c_common_resword): Define @property and its attributes.
13802         * c-common.h: Define property attribute enum entries.
13803         (OBJC_IS_PATTR_KEYWORD): New.
13804         (objc_property_attribute_kind): New enum.
13805         Declare objc_set_property_attr (), objc_add_property_variable (),
13806         objc_build_getter_call () and objc_build_setter_call ().
13807         * stub-objc.c (objc_set_property_attr): New stub.
13808         (objc_add_property_variable): Likewise.
13809         (objc_build_getter_call): Likewise.
13810         (objc_build_setter_call) Likewise.
13812 2010-10-13  Iain Sandoe  <iains@gcc.gnu.org>
13814         merge from FSF apple 'trunk' branch.
13815         2006-04-26  Fariborz Jahanian  <fjahanian@apple.com>
13817         Radar 3803157 (method attributes)
13818         * c-common.c (handle_deprecated_attribute): Recognize
13819         objc methods as valid declarations.
13820         * c-common.h: Declare objc_method_decl ().
13821         * stub-objc.c (objc_method_decl): New stub.
13823 2010-10-08  Joseph Myers  <joseph@codesourcery.com>
13825         * c-common.c (parse_optimize_options): Call
13826         decode_cmdline_options_to_array_default_mask before
13827         decode_options.  Update arguments to decode_options.
13828         * c-common.h (c_common_init_options_struct): Declare.
13829         * c-opts.c (c_common_init_options_struct): New.  Split out from
13830         c_common_init_options.
13832 2010-10-06  Nicola Pero  <nicola.pero@meta-innovation.com>
13834         Implemented fast enumeration for Objective-C.
13835         * c-common.h (objc_finish_foreach_loop): New.
13836         * stub-objc.c (objc_finish_foreach_loop): New.
13838 2010-10-05  Joseph Myers  <joseph@codesourcery.com>
13840         * c-common.h (struct diagnostic_context): Don't declare here.
13841         (c_common_initialize_diagnostics): Declare using
13842         diagnostic_context typedef.
13843         * c-opts.c (c_common_handle_option): Pass global_dc to
13844         handle_generated_option.
13846 2010-10-04  Joseph Myers  <joseph@codesourcery.com>
13848         * c-opts.c (c_common_handle_option): Pass &global_options_set to
13849         handle_generated_option.
13851 2010-10-03  Ian Lance Taylor  <iant@google.com>
13853         * c.opt (-fplan9-extensions): New option.
13855 2010-10-03  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
13857         * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
13858         Remove.
13859         (c_cpp_builtins): Call functions from cppbuiltin.c instead
13860         of duplicating code.
13862 2010-09-30  Iain Sandoe  <iains@gcc.gnu.org>
13864         * c-common.c: Add two new entries for @optional
13865         and @required keywords.
13867         merge from FSF 'apple/trunk' branch.
13868         2006-01-30  Fariborz Jahanian  <fjahanian@apple.com>
13870         Radar 4386773
13871         * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
13872         objective-c keywords.
13873         (objc_set_method_opt): New declaration.
13874         * stub-objc.c (objc_set_method_opt): New stub.
13876 2010-09-30  Joseph Myers  <joseph@codesourcery.com>
13878         * c-common.c (handle_optimize_attribute): Pass &global_options to
13879         cl_optimization_save and cl_optimization_restore.
13880         * c-opts.c (c_common_handle_option): Pass &global_options to
13881         handle_generated_option.
13882         * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
13883         (handle_pragma_pop_options, handle_pragma_reset_options): Pass
13884         &global_options to cl_optimization_restore.
13886 2010-09-30  Nicola Pero  <nicola.pero@meta-innovation.com>
13888         * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
13889         Objective-C/Objective-C++ keywords.
13891 2010-09-29  Nicola Pero  <nicola.pero@meta-innovation.com>
13893         Merge from 'apple/trunk' branch on FSF servers.
13895         2005-10-04  Fariborz Jahanian  <fjahanian@apple.com>
13897         Radar 4281748
13898         * c-common.h (objc_check_global_decl): New declaration.
13899         * stub-objc.c (objc_check_global_decl): New stub.
13901 2010-09-29  Joseph Myers  <joseph@codesourcery.com>
13903         * c.opt: Don't use VarExists.
13905 2010-09-29  Joseph Myers  <joseph@codesourcery.com>
13907         * c-common.c (c_cpp_error): Update names of diagnostic_context
13908         members.
13909         * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
13910         cl_optimization members.
13911         * c-opts.c (warning_as_error_callback, c_common_handle_option,
13912         sanitize_cpp_opts, finish_options): Update names of cpp_options
13913         members.
13915 2010-09-29  Nicola Pero  <nicola.pero@meta-innovation.com>
13917         * c-common.h (OBJC_IS_CXX_KEYWORD): New macro.  Updated comments.
13918         (objc_is_reserved_word): Removed.
13919         * c-common.c: Updated comments.
13920         * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
13921         objc_is_reserved_word.
13922         * stub-objc.c (objc_is_reserved_word): Removed.
13924 2010-09-28  Iain Sandoe  <iains@gcc.gnu.org>
13926         * c-common.h (objc_add_method_declaration): Adjust prototype to
13927         include attributes.
13928         (objc_start_method_definition): Likewise.
13929         (objc_build_keyword_decl): Likewise.
13930         * stub-objc.c:(objc_add_method_declaration): Handle attributes.
13931         (objc_start_method_definition): Likewise.
13932         (objc_build_keyword_decl): Likewise.
13934 2010-09-28  Iain Sandoe  <iains@gcc.gnu.org>
13936         * c-common.h (objc_start_class_interface): Adjust prototype.
13937         (objc_start_category_interface): Likewise.
13938         (objc_start_protocol): Likewise.
13939         * stub-objc.c (objc_start_protocol): Adjust for extra argument.
13940         (objc_start_class_interface): Likewise.
13941         (objc_start_category_interface): Likewise.
13943 2010-09-27  Ian Lance Taylor  <iant@google.com>
13945         * c-common.c (c_common_attribute_table): Add no_split_stack.
13946         (handle_no_split_stack_attribute): New static function.
13948 2010-09-27  Nicola Pero  <nicola.pero@meta-innovation.com>
13950         Merge from 'apple/trunk' branch on FSF servers.
13952         2005-12-15  Fariborz Jahanian  <fjahanian@apple.com>
13954         Radar 4229905
13955         * c-common.h (objc_have_common_type): New declaration.
13956         * stub-objc.c (objc_have_common_type): New stub.
13958         2005-06-22  Ziemowit Laski  <zlaski@apple.com>
13960         Radar 4154928
13961         * c-common.h (objc_common_type): New prototype.
13962         * stub-objc.c (objc_common_type): New stub.
13964 2010-09-24  Jan Hubicka  <jh@suse.cz>
13966         * c-common.c (handle_leaf_attribute): New function.
13967         (struct attribute_spec c_common_att): Add leaf.
13969 2010-09-22  Joseph Myers  <joseph@codesourcery.com>
13971         * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
13972         -comments-in-macros, -define-macro, -define-macro=, -dependencies,
13973         -dump, -dump=, -imacros, -imacros=, -include, -include=,
13974         -include-barrier, -include-directory, -include-directory=,
13975         -include-directory-after, -include-directory-after=,
13976         -include-prefix, -include-prefix=, -include-with-prefix,
13977         -include-with-prefix=, -include-with-prefix-after,
13978         -include-with-prefix-after=, -include-with-prefix-before,
13979         -include-with-prefix-before=, -no-integrated-cpp,
13980         -no-line-commands, -no-standard-includes, -no-warnings, -output,
13981         -output=, -pedantic, -pedantic-errors, -preprocess,
13982         -print-missing-file-dependencies, -trace-includes, -traditional,
13983         -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
13984         -user-dependencies, -verbose, -write-dependencies,
13985         -write-user-dependencies, no-integrated-cpp, traditional): New.
13987 2010-09-21  Nicola Pero  <nicola.pero@meta-innovation.com>
13989         PR objc/23710
13990         * c-common.h (objc_start_method_definition): Return bool instead
13991         of void.
13992         * stub-objc.c (objc_start_method_definition): Return bool instead
13993         of void.
13995 2010-09-21  Nicola Pero  <nicola.pero@meta-innovation.com>
13997         PR objc/25965
13998         * c-common.h (objc_get_interface_ivars): New declaration.
13999         * stub-objc.c (objc_get_interface_ivars): New stub.
14001 2010-09-15  Ian Lance Taylor  <iant@google.com>
14003         * c-common.c (parse_optimize_options): Do not capitalize warning
14004         messages.  Remove period at end of warning message.
14006 2010-09-09  Nathan Sidwell  <nathan@codesourcery.com>
14008         * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
14009         (handle_alias_attribute): ... here.
14010         (handle_ifunc_attribute): New.
14012 2010-09-06  Mark Mitchell  <mark@codesourcery.com>
14014         * c-common.h (do_warn_double_promotion): Declare.
14015         * c-common.c (do_warn_double_promotion): Define.
14017 2010-09-05  Mark Mitchell  <mark@codesourcery.com>
14019         * c.opt (Wdouble-promotion): New.
14021 2010-09-02  Joseph Myers  <joseph@codesourcery.com>
14023         * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
14024         fvtable-thunks, fxref): Mark no longer supported in help text.
14026 2010-09-02  Joseph Myers  <joseph@codesourcery.com>
14028         * c.opt (Wimport, fall-virtual, falt-external-templates,
14029         fdefault-inline, fenum-int-equiv, fexternal-templates,
14030         fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
14031         fname-mangling-version-, fnew-abi, fnonnull-objects,
14032         foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
14033         fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
14034         applicable.
14035         (fhandle-exceptions): Mark with Alias and Warn.
14036         * c-opts.c (c_common_handle_option): Don't handle options marked
14037         as ignored.
14039 2010-09-02  Joseph Myers  <joseph@codesourcery.com>
14041         * c.opt (Wcomments, Werror-implicit-function-declaration,
14042         ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
14043         std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
14044         aliases.
14045         * c-common.c (option_codes): Use OPT_Wcomment instead of
14046         OPT_Wcomments.
14047         * c-opts.c (warning_as_error_callback, c_common_handle_option):
14048         Don't handle options marked as aliases.
14050 2010-08-25  Richard Guenther  <rguenther@suse.de>
14052         * c-common.c (c_common_get_alias_set): Remove special
14053         handling for pointers.
14055 2010-08-20  Nathan Froyd  <froydnj@codesourcery.com>
14057         * c-common.c: Use FOR_EACH_VEC_ELT.
14058         * c-gimplify.c: Likewise.
14059         * c-pragma.c: Likewise.
14061 2010-08-16  Joseph Myers  <joseph@codesourcery.com>
14063         * c.opt (MDX): Change back to MD.  Mark NoDriverArg instead of
14064         RejectDriver.
14065         (MMDX): Change back to MMD.  Mark NoDriverArg instead of
14066         RejectDriver.
14067         * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
14068         instead of OPT_MDX and OPT_MMDX.
14070 2010-08-16  Joseph Myers  <joseph@codesourcery.com>
14072         * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
14074 2010-08-12  Joseph Myers  <joseph@codesourcery.com>
14076         * c.opt (MD, MMD): Change to MDX and MMDX.
14077         * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
14079 2010-08-11  Joseph Myers  <joseph@codesourcery.com>
14081         * c-opts.c (c_common_handle_option): Call handle_generated_option
14082         instead of handle_option.
14084 2010-08-08  Nathan Froyd  <froydnj@codesourcery.com>
14086         * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
14087         (maybe_apply_renaming_pragma): Delete unneeded declarations.
14089 2010-08-08  Nathan Froyd  <froydnj@codesourcery.com>
14091         * c-pragma.c (pending_redefinition): Declare.  Declare a VEC of it.
14092         (pending_redefine_extname): Change type to a VEC.
14093         (add_to_renaming_pragma_list): Update for new type of
14094         pending_redefine_extname.
14095         (maybe_apply_renaming_pragma): Likewise.
14097 2010-08-04  Arnaud Charlet  <charlet@adacore.com>
14099         * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
14100         visited.
14101         (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
14102         decide whether a type has already been declared/seen.
14103         Do not go to the original type.
14104         (dump_nested_types): New parameter forward.
14105         Generate forward declaration if needed and mark type as visited.
14106         (print_ada_declaration): Call dump_nested_types if not already done.
14107         Mark types as visited.
14109 2010-08-03  Joseph Myers  <joseph@codesourcery.com>
14111         * c.opt (-print-pch-checksum): Remove option.
14112         * c-opts.c (c_common_handle_option): Don't handle
14113         OPT_print_pch_checksum.
14115 2010-07-27  Joseph Myers  <joseph@codesourcery.com>
14117         * c-common.h (c_common_handle_option): Update prototype and return
14118         value type.
14119         * c-opts.c (c_common_handle_option): Update prototype and return
14120         value type.  Update calls to handle_option and
14121         enable_warning_as_error.
14123 2010-07-27  Jakub Jelinek  <jakub@redhat.com>
14125         PR c/45079
14126         * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
14128 2010-07-27  Joseph Myers  <joseph@codesourcery.com>
14130         * c-common.h (c_common_missing_argument): Remove.
14131         * c-opts.c (c_common_missing_argument): Remove.
14132         * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
14133         idirafter, imacros, include, isysroot, isystem, iquote): Add
14134         MissingArgError.
14135         * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
14137 2010-07-27  Joseph Myers  <joseph@codesourcery.com>
14139         * c-common.h (c_common_option_lang_mask,
14140         c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
14141         New.
14142         (c_common_init_options): Update prototype.
14143         * c-opts.c (c_common_option_lang_mask): New.
14144         (c_common_initialize_diagnostics): Split out of
14145         c_common_init_options.
14146         (accept_all_c_family_options, c_common_complain_wrong_lang_p):
14147         New.
14148         (c_common_init_options): Update prototype.  Use decoded options in
14149         search for -lang-asm.
14151 2010-07-15  Nathan Froyd  <froydnj@codesourcery.com>
14153         * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
14154         * c-format.c: Likewise.
14156 2010-07-08  Manuel López-Ibáñez  <manu@gcc.gnu.org>
14158         * c-common.h: Include diagnostic-core.h. Error if already
14159         included.
14160         * c-semantics.c: Do not define GCC_DIAG_STYLE here.
14162 2010-07-03  Manuel López-Ibáñez  <manu@gcc.gnu.org>
14164         * c-common.c (IN_GCC_FRONTEND): Do not undef.
14165         Do not include expr.h
14166         (vector_mode_valid_p): Move here.
14168 2010-06-21  DJ Delorie  <dj@redhat.com>
14170         * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
14171         allow these pragmas anywhere.
14173 2010-06-14  Jakub Jelinek  <jakub@redhat.com>
14175         PR bootstrap/44509
14176         * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
14177         (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
14178         (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
14179         ggc_strdup instead of xstrdup.
14181 2010-06-10  Jakub Jelinek  <jakub@redhat.com>
14183         * c-cppbuiltin.c: Include cpp-id-data.h.
14184         (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
14185         (lazy_hex_fp_value): New function.
14186         (builtin_define_with_hex_fp_value): Provide definitions lazily.
14188 2010-06-30  Manuel López-Ibáñez  <manu@gcc.gnu.org>
14190         * c-gimplify.c: Do not include tree-flow.h
14192 2010-06-29  Joern Rennecke  <joern.rennecke@embecosm.com>
14194         PR other/44034
14195         * c-common.c: Rename targetm member:
14196         targetm.enum_va_list -> targetm.enum_va_list_p
14198 2010-06-28  Anatoly Sokolov  <aesok@post.ru>
14200         * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
14202 2010-06-28  Steven Bosscher  <steven@gcc.gnu.org>
14204         * c-cppbuiltin.c: Do not include except.h.
14206 2010-06-24  Andi Kleen  <ak@linux.intel.com>
14208         * c-common.c (warn_for_omitted_condop): New.
14209         * c-common.h (warn_for_omitted_condop): Add prototype.
14211 2010-06-21  Joseph Myers  <joseph@codesourcery.com>
14213         * c.opt (lang-objc): Remove.
14214         * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
14216 2010-06-21  Joern Rennecke  <joern.rennecke@embecosm.com>
14218         * c-opts.c: Include "tm_p.h".
14220 2010-06-20  Joseph Myers  <joseph@codesourcery.com>
14222         * c-common.c (parse_optimize_options): Update call to
14223         decode_options.
14225 2010-06-18  Nathan Froyd  <froydnj@codesourcery.com>
14227         * c-common.c (record_types_used_by_current_var_decl): Adjust for
14228         new type of types_used_by_cur_var_decl.
14230 2010-06-17  Joern Rennecke  <joern.rennecke@embecosm.com>
14232         PR bootstrap/44512
14233         * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
14234         for C++ standard compliance.
14236 2010-06-16  Jason Merrill  <jason@redhat.com>
14238         * c.opt: Add -Wnoexcept.
14240 2010-06-16  Richard Guenther  <rguenther@suse.de>
14242         PR c/44555
14243         * c-common.c (c_common_truthvalue_conversion): Remove
14244         premature and wrong optimization concering ADDR_EXPRs.
14246 2010-06-15  Arnaud Charlet  <charlet@adacore.com>
14248         * c-ada-spec.c (dump_sloc): Remove column info.
14249         (is_simple_enum): New function.
14250         (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
14251         enum types when relevant.
14253 2010-06-11  Manuel López-Ibáñez  <manu@gcc.gnu.org>
14255         * c-common.c (conversion_warning): Warn at expression
14256         location.
14258 2010-06-10  Joseph Myers  <joseph@codesourcery.com>
14260         * c-opts.c (c_common_handle_option): Don't handle
14261         OPT_fshow_column.
14263 2010-06-08  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
14265         * c-pragma.c (push_alignment): Use typed GC allocation.
14266         (handle_pragma_push_options): Likewise.
14268         * c-common.c (parse_optimize_options): Likewise.
14270         * c-common.h (struct sorted_fields_type): Add variable_size GTY
14271         option.
14273 2010-06-07  Joseph Myers  <joseph@codesourcery.com>
14275         * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
14276         flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
14277         flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
14278         flag_signed_bitfields, warn_strict_null_sentinel,
14279         flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
14280         flag_gen_declaration, flag_no_gnu_keywords,
14281         flag_implement_inlines, flag_implicit_templates,
14282         flag_implicit_inline_templates, flag_optional_diags,
14283         flag_elide_constructors, flag_default_inline, flag_rtti,
14284         flag_conserve_space, flag_access_control, flag_check_new,
14285         flag_new_for_scope, flag_weak, flag_working_directory,
14286         flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
14287         flag_enforce_eh_specs, flag_threadsafe_statics,
14288         flag_pretty_templates): Remove.
14289         * c-common.h (flag_preprocess_only, flag_nil_receivers,
14290         flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
14291         flag_replace_objc_classes, flag_undef, flag_no_builtin,
14292         flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
14293         flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
14294         flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
14295         flag_no_gnu_keywords, flag_implement_inlines,
14296         flag_implicit_templates, flag_implicit_inline_templates,
14297         flag_optional_diags, flag_elide_constructors, flag_default_inline,
14298         flag_rtti, flag_conserve_space, flag_access_control,
14299         flag_check_new, flag_new_for_scope, flag_weak,
14300         flag_working_directory, flag_use_cxa_atexit,
14301         flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
14302         flag_threadsafe_statics, flag_pretty_templates,
14303         warn_strict_null_sentinel): Remove.
14304         * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
14305         fbuiltin, fcheck-new, fconserve-space, felide-constructors,
14306         fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
14307         fimplicit-inline-templates, fimplicit-templates,
14308         flax-vector-conversions, fms-extensions, fnil-receivers,
14309         fnonansi-builtins, fpretty-templates, freplace-objc-classes,
14310         frtti, fshort-double, fshort-enums, fshort-wchar,
14311         fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
14312         funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
14313         fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
14314         gen-decls, undef): Use Var.
14315         (fdefault-inline, foptional-diags): Document as doing nothing.
14316         * c-opts.c (c_common_handle_option): Remove cases for options now
14317         using Var.  Mark ignored options as such.
14319 2010-06-05  Steven Bosscher  <steven@gcc.gnu.org>
14321         * c-common.c: Moved to here from parent directory.
14322         * c-common.def: Likewise.
14323         * c-common.h: Likewise.
14324         * c-cppbuiltin.c: Likewise.
14325         * c-dump.c: Likewise.
14326         * c-format.c: Likewise.
14327         * c-format.h : Likewise.
14328         * c-gimplify.c: Likewise.
14329         * c-lex.c: Likewise.
14330         * c-omp.c: Likewise.
14331         * c.opt: Likewise.
14332         * c-opts.c: Likewise.
14333         * c-pch.c: Likewise.
14334         * c-ppoutput.c: Likewise.
14335         * c-pragma.c: Likewise.
14336         * c-pragma.h: Likewise.
14337         * c-pretty-print.c: Likewise.
14338         * c-pretty-print.h: Likewise.
14339         * c-semantics.c: Likewise.
14340         * stub-objc.c: Likewise.
14342         * c-common.c: Include gt-c-family-c-common.h.
14343         * c-pragma.c: Include gt-c-family-c-pragma.h.
14345 Copyright (C) 2010-2023 Free Software Foundation, Inc.
14347 Copying and distribution of this file, with or without modification,
14348 are permitted in any medium without royalty provided the copyright
14349 notice and this notice are preserved.