Don't ICE on vectors of enums (PR 87286)
[official-gcc.git] / gcc / c-family / ChangeLog
blob630733786a3194b07448f3df17eb4f2bd27f4808
1 2018-10-08  Richard Sandiford  <richard.sandiford@arm.com>
3         PR c/87286
4         * c-common.c (vector_types_compatible_elements_p): Use
5         INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
7 2018-10-04  Vinay Kumar  <vinay.kumar@blackfigtech.com>
9         * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
10         to generate constructor destructor priority warning.
11         * c.opt (-Wprio-ctor-dtor): New option.
13 2018-10-01  Jason Merrill  <jason@redhat.com>
15         * c-lex.c (c_common_has_attribute): Add no_unique_address.
17 2018-10-01  Eric Botcazou  <ebotcazou@adacore.com>
19         * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
20         (dump_ada_node): Add const keyword.
22 2018-09-25  Martin Liska  <mliska@suse.cz>
24         * c-common.c (c_common_truthvalue_conversion):
25         Remove Pascal from documentation.
27 2018-09-21  Eric Botcazou  <ebotcazou@adacore.com>
29         * c-ada-spec.c: Include diagnostic.h.
30         (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
32 2018-09-19  Marek Polacek  <polacek@redhat.com>
34         * c.opt (Wclass-conversion): New.
36 2018-09-17  David Malcolm  <dmalcolm@redhat.com>
38         * c-format.c (range_label_for_format_type_mismatch::get_text):
39         Update for new param.
41 2018-09-17  David Malcolm  <dmalcolm@redhat.com>
43         * c-format.c (format_warning_at_char): Update for introduction of
44         format_string_diagnostic_t.
45         (format_type_warning): Likewise.
47 2018-09-17  Martin Jambor  <mjambor@suse.cz>
49         PR c/63886
50         * c.opt (Wabsolute-value): New.
52 2018-09-06  Bernd Edlinger  <bernd.edlinger@hotmail.de>
54         * c-common.c (complete_flexible_array_elts): New helper function.
55         * c-common.h (complete_flexible_array_elts): Declare.
57 2018-09-02  Bernd Edlinger  <bernd.edlinger@hotmail.de>
59         * c-common.c (braced_list_to_string): Remove eval parameter.
60         Add some more checks.  Always create zero-terminated STRING_CST.
61         * c-common.h (braced_list_to_string): Adjust prototype.
63 2018-08-27  David Malcolm  <dmalcolm@redhat.com>
65         PR 87091
66         * c-common.c (c_cpp_error): Update for conversion of show_caret_p
67         to a tri-state.
68         (maybe_suggest_missing_token_insertion): Likewise.
69         (maybe_add_include_fixit): Add param "override_location".  If set,
70         and source-printing is enabled, then override the rich_location's
71         primary location with that of the insertion point for the fix-it
72         hint, marking it with SHOW_LINES_WITHOUT_RANGE.
73         * c-common.h (extern void maybe_add_include_fixit): Add bool
74         param.
75         * c-format.c (selftest::test_type_mismatch_range_labels): Update
76         for conversion of show_caret_p to a tri-state.
77         * c-warn.c (warn_for_restrict): Likewise.
78         * known-headers.cc
79         (suggest_missing_header::~suggest_missing_header): Update call to
80         maybe_add_include_fixit to suggest overriding the location, as it
81         is for a note.
83 2018-08-27  Martin Liska  <mliska@suse.cz>
85         * c-common.c (check_function_restrict): Use new function
86         fndecl_built_in_p and remove check for FUNCTION_DECL if
87         possible.
88         (check_builtin_function_arguments): Likewise.
89         (reject_gcc_builtin): Likewise.
90         * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
92 2018-08-26  Marek Polacek  <polacek@redhat.com>
94         PR c++/87029, Implement -Wredundant-move.
95         * c.opt (Wredundant-move): New option.
97 2018-08-21  Marek Polacek  <polacek@redhat.com>
99         PR c++/86981, Implement -Wpessimizing-move.
100         * c.opt (Wpessimizing-move): New option.
102 2018-08-20  David Malcolm  <dmalcolm@redhat.com>
104         PR other/84889
105         * c-attribs.c (common_handle_aligned_attribute): Add
106         auto_diagnostic_group instance.
107         * c-indentation.c (warn_for_misleading_indentation): Likewise.
108         * c-opts.c (c_common_post_options): Likewise.
109         * c-warn.c (warn_logical_not_parentheses): Likewise.
110         (warn_duplicated_cond_add_or_warn): Likewise.
111         (warn_for_multistatement_macros): Likewise.
113 2018-08-20  Nathan Sidwell  <nathan@acm.org>
115         * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
116         access.
118 2018-08-17  Nathan Sidwell  <nathan@acm.org>
120         * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
121         field.
122         (laxy_hex_fp_value_count): Make unsigned.
123         (lazy_hex_fp_value): Provided with macro & lazy number.  Directly
124         manipulate the macro.
125         (builtin_defin_with_hex_fp_value): Adjust callback name, use
126         cpp_define_lazily.
128 2018-08-17  David Malcolm  <dmalcolm@redhat.com>
130         * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
131         (gcc_dump_printf_length_specs): New.
132         (gcc_dump_printf_flag_pairs): New.
133         (gcc_dump_printf_flag_specs): New.
134         (gcc_dump_printf_char_table): New.
135         (format_types_orig): Add entry for "gcc_dump_printf".
136         (init_dynamic_diag_info): Set up length_char_specs and
137         conversion_specs for gcc_dump_printf_format_type.
138         (handle_format_attribute): Handle gcc_dump_printf_format_type.
140 2018-08-17  Nathan Sidwell  <nathan@acm.org>
142         * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
144         * c-ada-spec.c: Don't #include "cpp-id-data.h"
145         * c-cppbuiltin.c: Likewise.
147 2018-08-17  Martin Liska  <mliska@suse.cz>
149         * c.opt: Remove Warn, Init and Report for options with
150         Ignore/Deprecated flag. Warning is done automatically for
151         Deprecated flags.
153 2018-08-16  David Malcolm  <dmalcolm@redhat.com>
155         PR c++/70693
156         * c-common.c (selftest::c_family_tests): Call
157         selftest::c_indentation_c_tests.
158         * c-common.h (selftest::c_indentation_c_tests): New decl.
159         * c-indentation.c: Include "selftest.h".
160         (next_tab_stop): Add "tab_width" param, rather than accessing
161         cpp_opts.
162         (get_visual_column): Likewise.  Clarify comment.  Bulletproof
163         against reading past the end of the line.
164         (get_first_nws_vis_column): Add "tab_width" param.
165         (detect_intervening_unindent): Likewise.
166         (should_warn_for_misleading_indentation): Read tab width from
167         cpp_opts and pass around.
168         (selftest::test_next_tab_stop): New test.
169         (selftest::assert_get_visual_column_succeeds): New function.
170         (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
171         (selftest::assert_get_visual_column_fails): New function.
172         (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
173         (selftest::test_get_visual_column): New test.
174         (selftest::c_indentation_c_tests): New function.
176 2018-08-16  Nathan Sidwell  <nathan@acm.org>
178         * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
179         (store_ada_macro): Likewise.
180         * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
181         * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
183 2018-08-15  David Malcolm  <dmalcolm@redhat.com>
185         * c-format.c: Include "selftest-diagnostic.h" and
186         "gcc-rich-location.h".
187         (format_warning_at_char): Pass NULL for new label params of
188         format_warning_va.
189         (class indirection_suffix): New class.
190         (class range_label_for_format_type_mismatch): New class.
191         (format_type_warning): Move logic for generating "*" suffix to
192         class indirection_suffix.  Create "fmt_label" and "param_label"
193         to show their types, and pass them to the
194         format_warning_at_substring calls.
195         (selftest::test_type_mismatch_range_labels): New test.
196         (selftest::c_format_c_tests): Call it.
198 2018-08-13  Martin Sebor  <msebor@redhat.com>
200         PR tree-optimization/71625
201         * c-common.c (braced_list_to_string): New function.
202         * c-common.h (braced_list_to_string): Declare it.
204 2018-08-08  Nathan Sidwell  <nathan@acm.org>
206         * c-common.c (try_to_locate_new_include_inertion_point): Use
207         linemap_included_from_linemap.
208         * c-lex.c (fe_file_change): Use linemap_included_from.
209         * c-ppoutput.c (pp_file_change): Likewise.
211 2018-08-01  Martin Sebor  <msebor@redhat.com>
213         PR tree-optimization/86650
214         * c-family/c-format.c (gcc_tdiag_char_table): Update comment for "%G".
215         (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
216         (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
217         * c-format.h (T89_G): Update to be "gimple *" rather than
218         "gcall *".
219         (local_gcall_ptr_node): Rename...
220         (local_gimple_ptr_node): ...to this.
222 2018-07-31  David Malcolm  <dmalcolm@redhat.com>
224         * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
225         table entries for gcc_diag_char_table, and the 'Z' entry from
226         gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
227         &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
228         (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
229         adding missing "Z" for this table.  Remove erroneous "G" and "K"
230         entries.
231         (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE.  Remove "v".
232         (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
233         (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE.  Remove "v".
235 2018-07-31  Richard Earnshaw  <rearnsha@arm.com>
237         * c-common.c (speculation_safe_resolve_call): New function.
238         (speculation_safe_resolve_params): New function.
239         (speculation_safe_resolve_return): New function.
240         (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
241         * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
242         __HAVE_SPECULATION_SAFE_VALUE.
244 2018-07-20  David Malcolm  <dmalcolm@redhat.com>
246         * c-common.c (c_cpp_error): Remove redundant "line_table"
247         parameter from call to rich_location::set_range.
248         (maybe_suggest_missing_token_insertion): Likewise.
250 2018-07-20  Martin Sebor  <msebor@redhat.com>
252         PR middle-end/82063
253         * gcc/c-family/c.opt (-Warray-bounds): Remove redundant -Wall.
255 2018-07-20  Martin Sebor  <msebor@redhat.com>
257         PR middle-end/82063
258         * c-common.h (c_common_handle_option): Change function argument
259         to HOST_WIDE_INT.
260         * c-opts.c (c_common_init_options): Same.
261         (c_common_handle_option): Same.  Remove special handling of
262         OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
263         * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
264         options to take a HOST_WIDE_INT argument and accept a byte-size
265         suffix.  Initialize.
266         (-Wvla-larger-than): Same.
267         (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
268         (-Wno-vla-larger-than): Same.
270 2018-07-12  Jakub Jelinek  <jakub@redhat.com>
272         * c-attribs.c (c_common_attribute_table): Add
273         "omp declare target implicit" attribute.
275 2018-07-12  Richard Biener  <rguenther@suse.de>
277         PR c/86453
278         * c-attribs.c (handle_packed_attribute): Do not build a variant
279         type with TYPE_PACKED, instead ignore the attribute if we may
280         not apply to the original type.
282 2018-07-10  Jakub Jelinek  <jakub@redhat.com>
284         PR c++/86443
285         * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
286         to contain TREE_LIST for both the original class iterator and the
287         "last" helper var.
289 2018-07-07  Eric Botcazou  <ebotcazou@adacore.com>
291         * c-ada-spec.c (to_ada_name): Remove index parameter.
292         (pp_ada_tree_identifier): Likewise.
293         (dump_ada_macros): Adjust call to to_ada_name.
294         (struct overloaded_name_hash): Delete.
295         (struct overloaded_name_hasher): Likewise.
296         (overloaded_names): Likewise.
297         (compute_overloading_index): Likewise.
298         (dump_ada_decl_name): Do not call compute_overloading_index and
299         adjust calls to pp_ada_tree_identifier.
300         (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
301         (dump_ada_import): Add spc parameter and switch to aspect syntax.
302         (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
303         (dump_ada_enum_type): Remove type and display_convention parameters.
304         Adjust calls to pp_ada_tree_identifier.
305         (dump_ada_node): Likewise and for dump_ada_structure.
306         (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
307         and tidy up.
308         <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
309         syntax.
310         (print_constructor): Adjust call to pp_ada_tree_identifier.
311         (print_destructor): Likewise.
312         (dump_ada_declaration): Switch to aspect syntax.
313         (dump_ada_structure): Likewise and tidy up.  Replace display_convention
314         parameter with nested parameter.
315         (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
316         (dump_ada_specs): Do not delete overloaded_names table.
318 2018-07-06  Peter Bergner  <bergner@linux.ibm.com>
320         PR target/86324
321         * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
322         target hook.
324 2018-07-05  Nathan Sidwell  <nathan@acm.org>
326         * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
327         NO_IMPLICIT_EXTERN_C.
329 2018-06-28  Martin Liska  <mliska@suse.cz>
331         * cppspec.c: Include opt-suggestions.h.
333 2018-06-20  Chung-Lin Tang <cltang@codesourcery.com>
334             Thomas Schwinge <thomas@codesourcery.com>
335             Cesar Philippidis  <cesar@codesourcery.com>
337         * c-pragma.h (enum pragma_omp_clause): Add
338         PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
339         PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
341 2018-06-20  Jakub Jelinek  <jakub@redhat.com>
343         PR c++/86210
344         * c-common.c (check_nonnull_arg): Use fold_for_warn.  Adjust obsolete
345         comment.
347 2018-06-18  Martin Sebor  <msebor@redhat.com>
349         PR middle-end/85602
350         * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
351         nonstring.
353 2018-06-16  Kugan Vivekanandarajah  <kuganv@linaro.org>
355         * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
357 2018-06-13  Jason Merrill  <jason@redhat.com>
359         * c-opts.c (c_common_post_options): Warn about useless -Wabi.
360         (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
361         handling.
363         PR c++/86094 - wrong code with defaulted move ctor.
364         * c-opts.c (c_common_post_options): Bump the current ABI version to
365         13.  Set warn_abi_version and flag_abi_compat_version to the current
366         version rather than 0.  Fix defaulting flag_abi_compat_version from
367         warn_abi_version.
369 2018-06-12  Martin Sebor  <msebor@redhat.com>
371         PR c/85931
372         * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
373         sizeof source and destination yields the same value.
375 2018-06-12  Martin Liska  <mliska@suse.cz>
377         * c.opt: Make MPX-related options as Deprecated.
379 2018-06-08  David Malcolm  <dmalcolm@redhat.com>
381         * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
382         rather than 0.
384 2018-06-08  Martin Liska  <mliska@suse.cz>
386         * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
387         for MPX (macros, related functions, fields in cgraph_node, ...).
388         (handle_bnd_legacy): Likewise.
389         (handle_bnd_instrument): Likewise.
390         * c.opt: Likewise.
392 2018-06-06  Jakub Jelinek  <jakub@redhat.com>
394         PR c++/86068
395         * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
396         __cpp_transactional_memory to 201500 instead of 210500.
398 2018-06-06  Jason Merrill  <jason@redhat.com>
400         PR c++/85710 - ICE with -Wmemset-elt-size.
401         * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
403 2018-06-01  Jason Merrill  <jason@redhat.com>
405         * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
406         201703.
408 2018-06-01  Eric Botcazou  <ebotcazou@adacore.com>
410         * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
411         declaration for a typedef independently of whether the declaration of
412         the subtype is generated.
414 2018-05-31  Martin Sebor  <msebor@redhat.com>
416         PR c/82063
417         * c.opt (-Wno-alloc-size-larger-than): New option.
419 2018-04-22  David Pagan  <dave.pagan@oracle.com>
421         PR c/55976
422         * c-opts.c (c_common_post_options): Set default for warn_return_type
423         for C++/C++ with ObjC extensions only. For C, makes it possible to 
424         differentiate between default (no option), -Wreturn-type, and
425         -Wno-return-type.
427 2018-05-29  Jason Merrill  <jason@redhat.com>
429         * c.opt (Winit-list-lifetime): New flag.
431 2018-05-28  Bernd Edlinger  <bernd.edlinger@hotmail.de>
433         * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
434         splay_tree_delete_pointers.
436 2018-05-26  Jakub Jelinek  <jakub@redhat.com>
438         PR bootstrap/85921
439         * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
440         noinline variable to workaround broken kernel headers.
442 2018-05-18  Jason Merrill  <jason@redhat.com>
444         * c.opt (Wdeprecated-copy): New flag.
446 2018-05-17  Martin Liska  <mliska@suse.cz>
448         * c-warn.c (overflow_warning): Do not use
449         space in between 'G_' and '('.
451 2018-05-09  Jason Merrill  <jason@redhat.com>
453         * c-common.c (valid_array_size_p): Add complain parameter.
454         * c-common.h: ...which defaults to true.
456 2018-05-11  Jakub Jelinek  <jakub@redhat.com>
458         PR c/85696
459         * c-omp.c (c_omp_predetermined_sharing): Return
460         OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
462 2018-05-11  Martin Liska  <mliska@suse.cz>
464         PR sanitizer/85556
465         * c-attribs.c (handle_no_sanitize_attribute): Iterate all
466         TREE_LIST values.
468 2018-05-10  Jakub Jelinek  <jakub@redhat.com>
470         PR c++/85662
471         * c-common.h (fold_offsetof_1): Removed.
472         (fold_offsetof): Add TYPE argument defaulted to size_type_node and
473         CTX argument defaulted to ERROR_MARK.
474         * c-common.c (fold_offsetof_1): Renamed to ...
475         (fold_offsetof): ... this.  Remove wrapper function.  Add TYPE
476         argument, convert the pointer constant to TYPE and use size_binop
477         with PLUS_EXPR instead of fold_build_pointer_plus if type is not
478         a pointer type.  Adjust recursive calls.
480 2018-05-10  Eric Botcazou  <ebotcazou@adacore.com>
482         PR c++/85400
483         * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
485 2018-05-07  Nathan Sidwell  <nathan@acm.org>
487         * c.opt (ffor-scope): Remove functionality, issue warning.
489 2018-05-03  Nathan Sidwell  <nathan@acm.org>
491         * c.opt (ffriend-injection): Remove functionality, issue warning.
493 2018-05-01  David Malcolm  <dmalcolm@redhat.com>
495         PR c/84258
496         * c-format.c (struct format_check_results): Add field
497         "number_non_char".
498         (check_format_info): Initialize it, and warn if encountered.
499         (check_format_arg): Distinguish between wide char and
500         everything else when detecting arrays of non-char.
502 2018-04-30  David Malcolm  <dmalcolm@redhat.com>
504         * c-format.c (get_corrected_substring): Update for
505         location_get_source_line returning a char_span.  Use a char_span
506         when handling the prefix of the correction.
507         * c-indentation.c (get_visual_column): Update for
508         location_get_source_line returning a char_span.
509         (get_first_nws_vis_column): Likewise.
511 2018-03-29  David Malcolm  <dmalcolm@redhat.com>
513         PR c++/84269
514         * known-headers.cc (get_stdlib_header_for_name): Add various names
515         from <assert.h>, <string.h>, and <memory.h>; add more names from
516         <stdio.h>.
518 2018-03-27  Jakub Jelinek  <jakub@redhat.com>
520         PR c++/85061
521         * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
522         get_base_address of the second operand is a VAR_P, rather than the
523         operand itself, and use gcc_checking_assert instead of gcc_assert.
525 2018-03-23  Marek Polacek  <polacek@redhat.com>
527         PR c++/85045
528         * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
529         <case RDIV_EXPR>: Tweak condition.
531 2018-03-20  Eric Botcazou  <ebotcazou@adacore.com>
533         * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
535 2018-03-16  Jakub Jelinek  <jakub@redhat.com>
537         PR c/84909
538         * c-warn.c (conversion_warning): Replace "to to" with "to" in
539         diagnostics.
541         PR c/84910
542         * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
543         diagnostics.
545 2018-03-16  Richard Biener  <rguenther@suse.de>
547         PR c/84873
548         * c-gimplify.c (c_gimplify_expr): Revert previous change.  Instead
549         unshare the possibly folded expression.
551 2018-03-15  Richard Biener  <rguenther@suse.de>
553         PR c/84873
554         * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
556 2018-03-13  Martin Sebor  <msebor@redhat.com>
558         PR tree-optimization/84725
559         * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
560         with all three narrow character types, including their qualified forms.
562 2018-03-12  Martin Sebor  <msebor@redhat.com>
564         PR tree-optimization/83456
565         * gcc/c-family/c-common.c (check_function_restrict): Return bool.
566         Restore checking of bounded built-in functions.
567         (check_function_arguments): Also return the result
568         of warn_for_restrict.
569         * gcc/c-family/c-common.c (check_function_restrict): Return bool.
570         * gcc/c-family/c-warn.c (warn_for_restrict): Return bool.
572 2018-03-02  Marek Polacek  <polacek@redhat.com>
574         PR c++/84171
575         * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
576         is erroneous.
578 2018-03-02  Thomas Schwinge  <thomas@codesourcery.com>
580         * c-attribs.c (c_common_attribute_table): Remove "cilk simd
581         function".
583 2018-03-01  Marek Polacek  <polacek@redhat.com>
585         PR c++/84639
586         * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
587         alignment in computation.
589 2018-02-28  Eric Botcazou  <ebotcazou@adacore.com>
591         * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
592         <REAL_TYPE>: Deal specifically with _Float128/__float128.
594 2018-02-28  Eric Botcazou  <ebotcazou@adacore.com>
596         * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
597         (is_char_array): Take a type instead of a declaration.
598         (dump_ada_array_type): Likewise.
599         (is_simple_enum): Minor tweak.
600         (dump_ada_enum_type): New function extracted from...
601         (dump_ada_node) <ENUMERAL_TYPE>: ...here.  Invoke it.
602         <INTEGER_TYPE>: Remove unreachable code.
603         <RECORD_TYPE>: Likewise.  Minor tweaks.
604         (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
605         <ENUMERAL_TYPE>: New case.
606         <RECORD_TYPE>: Factor out common code.
607         (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
608         Minor tweaks.  Deal with enumeral types.
609         (dump_ada_structure): Minor tweaks.
611 2018-02-28  Eric Botcazou  <ebotcazou@adacore.com>
613         * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
614         address for incomplete structures.
615         (dump_forward_type): Do not bail out for incomplete structures.
616         (dump_ada_declaration): Do not special-case incomplete structures
617         for subtypes.  Dump them as null records for types.
619 2018-02-28  Eric Botcazou  <ebotcazou@adacore.com>
621         * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
622         (is_char_array): Fix formatting.
623         (dump_template_types): Likewise.
624         (dump_generic_ada_node): Rename into...
625         (dump_ada_node): ...this.
626         <POINTER_TYPE>: Remove superfluous space.  Use generic address for
627         incomplete structures and not for empty structures.  Do not use it
628         when forward declarations are needed.
629         (dump_forward_type): New function.
630         (dump_nested_types): Remove FORWARD parameter.  Do not consider
631         TREE_VISITED and do not generate a forward declaration.  Only dump
632         original nested types for nested declaration.
633         (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
634         <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
635         <RECORD_TYPE>: Do not consider TREE_VISITED.
636         (dump_ada_declaration): Use booleans and fix formatting throughout.
637         <TYPE_DECL>: Skip incomplete structures and not empty structures.
638         Call dump_forward_type instead of dump_nested_types for a typedef.
639         Remove superfluous check and adjust call to dump_nested_types.
640         <POINTER_TYPE>: Call dump_forward_type and fall through.
641         (dump_ada_struct_decl): Rename into...
642         (dump_ada_structure): ...this.  Do not special-case empty structures.
644 2018-02-27  Martin Sebor  <msebor@redhat.com>
646         PR c++/83871
647         * c.opt (-Wmissing-attributes): New option.
649 2018-02-21  Martin Liska  <mliska@suse.cz>
651         * c.opt (Wcatch-value=): Add IntegerRange.
653 2018-02-15  Jason Merrill  <jason@redhat.com>
655         * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
657 2018-02-09  Nathan Sidwell  <nathan@acm.org>
659         PR c/84293
660         * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
661         arg.
662         * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
663         arg.  Adjust.
665 2018-02-09  Martin Sebor  <msebor@redhat.com>
667         PR lto/84212
668         * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
669         (-Walloc-size-larger-than, -Wformat-truncation=): Same.
670         (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
671         (-Wstrict-overflow, -Wsuggest-attribute): Same.
672         (-Wuninitialized): Same.
674 2018-02-09  Eric Botcazou  <ebotcazou@adacore.com>
676         * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
677         keyword for components.
679 2018-02-02  Paolo Carlini  <paolo.carlini@oracle.com>
681         * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
683 2018-02-02  Julia Koval  <julia.koval@intel.com>
685         * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
687 2018-01-29  Marek Polacek  <polacek@redhat.com>
689         PR c/83966
690         * c-format.c (check_function_format): Check current_function_decl.
692 2018-01-27  Jakub Jelinek  <jakub@redhat.com>
694         * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
695         argument.
696         (LAZY_HEX_FP_VALUES_CNT): Define.
697         (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
698         values rather than just 12.
699         (builtin_define_with_hex_fp_value): Likewise.
701 2018-01-18  Boris Kolpackov  <boris@codesynthesis.com>
703         PR other/70268
704         * c.opt (-fmacro-prefix-map): New option.
705         * c-opts.c (c_common_handle_option): Handle it.
706         * c-lex.c (init_c_lex): Set remap_filename cpp callback.
707         * c-ppoutput.c (init_pp_output): Likewise.
709 2018-01-17  David Malcolm  <dmalcolm@redhat.com>
711         PR c++/83814
712         * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
714 2018-01-10  Eric Botcazou  <ebotcazou@adacore.com>
716         * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
717         Skip 'f' and 'F' characters if it is true.
718         (store_ada_macro): Minor tweak.
719         (dump_ada_macros) <CPP_COMMENT>: Likewise.
720         <CPP_WSTRING>: Likewise.
721         <CPP_STRING>: Output '&' in the buffer if not the first string.
722         <CPP_NUMBER>: Adjust calls to dump_number.
724 2018-01-10  David Malcolm  <dmalcolm@redhat.com>
726         PR c++/43486
727         * c-common.c: Include "selftest.h".
728         (get_atomic_generic_size): Perform the test for integral type
729         before the range test for any integer constant, fixing indentation
730         of braces.  Call fold_for_warn before testing for an INTEGER_CST.
731         (reject_gcc_builtin): Strip any location wrapper from EXPR.
732         (selftest::test_fold_for_warn): New function.
733         (selftest::c_common_c_tests): New function.
734         (selftest::c_family_tests): Call it, and
735         selftest::c_pretty_print_c_tests.
736         * c-common.h (selftest::c_pretty_print_c_tests): New decl.
737         * c-format.c (check_format_arg): Convert VAR_P check to a
738         fold_for_warn.
739         * c-pretty-print.c: Include "selftest.h".
740         (pp_c_cast_expression): Don't print casts for location wrappers.
741         (selftest::assert_c_pretty_printer_output): New function.
742         (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
743         (selftest::test_location_wrappers): New function.
744         (selftest::c_pretty_print_c_tests): New function.
745         * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
747 2018-01-03  Richard Sandiford  <richard.sandiford@linaro.org>
748             Alan Hayward  <alan.hayward@arm.com>
749             David Sherwood  <david.sherwood@arm.com>
751         * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
753 2018-01-03  Richard Sandiford  <richard.sandiford@linaro.org>
754             Alan Hayward  <alan.hayward@arm.com>
755             David Sherwood  <david.sherwood@arm.com>
757         * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
758         as polynomial.
760 2018-01-03  Richard Sandiford  <richard.sandiford@linaro.org>
761             Alan Hayward  <alan.hayward@arm.com>
762             David Sherwood  <david.sherwood@arm.com>
764         * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
765         (convert_vector_to_array_for_subscript): Handle polynomial
766         TYPE_VECTOR_SUBPARTS.
767         (c_common_type_for_mode): Check valid_vector_subparts_p.
768         * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
769         VECTOR_CST_NELTS.
771 2018-01-03  Jakub Jelinek  <jakub@redhat.com>
773         Update copyright years.
775 2017-12-22  Mike Stump  <mikestump@comcast.net>
776             Eric Botcazou  <ebotcazou@adacore.com>
778         * c-pragma.c (init_pragma): Register pragma GCC unroll.
779         * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
781 2017-12-22  Alexandre Oliva <aoliva@redhat.com>
783         PR debug/83527
784         PR debug/83419
785         * c-semantics.c (only_debug_stmts_after_p): New.
786         (pop_stmt_list): Clear side effects in debug-only stmt list.
787         Check for single nondebug stmt followed by debug stmts only.
789 2017-12-21  Alexandre Oliva  <aoliva@redhat.com>
791         PR debug/83419
792         * c-semantics.c (pop_stmt_list): Propagate side effects from
793         single nondebug stmt to container list.
795 2017-12-19  Jakub Jelinek  <jakub@redhat.com>
797         * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
798         conditions with typical order conditions.
800 2017-12-18  Marek Polacek  <polacek@redhat.com>
802         * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
803         not in effect.
805 2017-12-17  Martin Sebor  <msebor@redhat.com>
807         * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
808         an error for attribute warn_if_not_aligned.
810 2017-12-16  Martin Sebor  <msebor@redhat.com>
812         PR tree-optimization/78918
813         * c-common.c (check_function_restrict): Avoid checking built-ins.
814         * c.opt (-Wrestrict): Include in -Wall.
816 2017-12-15  Jakub Jelinek  <jakub@redhat.com>
818         * c-attribs.c (c_common_attribute_table,
819         c_common_format_attribute_table): Swap affects_type_identity
820         and handler fields, adjust comments.
822 2017-12-14  Bernd Edlinger  <bernd.edlinger@hotmail.de>
824         * c.opt (Wcast-function-type): New warning option.
825         * c-lex.c (get_fileinfo): Avoid warning.
826         * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
828 2017-12-14  Qing Zhao  <qing.zhao@oracle.com>
830         PR middle_end/79538
831         * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
832         Adjust the size of buf1 and buf2, add a new buf to avoid
833         format-overflow warning.
835 2017-12-12  Alexandre Oliva <aoliva@redhat.com>
837         * c-semantics.c (pop_stmt_list): Move begin stmt marker into
838         subsequent statement list.
840 2017-12-07  Martin Sebor  <msebor@redhat.com>
842         PR c/81544
843         PR c/81566
844         * c-attribs.c (attr_aligned_exclusions): New array.
845         (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
846         (attr_common_exclusions, attr_const_pure_exclusions): Same.
847         (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
848         (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
849         (attr_warn_unused_result_exclusions): Same.
850         (handle_hot_attribute, handle_cold_attribute): Simplify.
851         (handle_const_attribute): Warn on function returning void.
852         (handle_pure_attribute): Same.
853         (handle_aligned_attribute): Diagnose conflicting attribute
854         specifications.
855         * c-warn.c (diagnose_mismatched_attributes): Simplify.
857 2017-12-06  David Malcolm  <dmalcolm@redhat.com>
859         PR c/83236
860         * c-common.c (selftest::c_family_tests): Call
861         selftest::c_spellcheck_cc_tests.
862         * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
863         * c-spellcheck.cc: Include "selftest.h".
864         (name_reserved_for_implementation_p): New function.
865         (should_suggest_as_macro_p): New function.
866         (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
867         should_suggest_as_macro_p and call it.
868         (selftest::test_name_reserved_for_implementation_p): New function.
869         (selftest::c_spellcheck_cc_tests): New function.
870         * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
872 2017-12-06  David Malcolm  <dmalcolm@redhat.com>
874         * c-spellcheck.cc: New file, taken from macro-handling code in
875         spellcheck-tree.c.
876         * c-spellcheck.h: New file, taken from macro-handling code in
877         spellcheck-tree.h.
879 2017-12-01  Jakub Jelinek  <jakub@redhat.com>
881         * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
882         attribute.
883         (handle_simd_attribute): Don't check for "cilk simd function"
884         attribute.  Reindent, formatting changes.
886 2017-11-30  Julia Koval  <julia.koval@intel.com>
888         * c-common.h (inv_list): Remove.
890 2017-11-28  Jakub Jelinek  <jakub@redhat.com>
892         PR sanitizer/81275
893         * c-common.c (c_switch_covers_all_cases_p_1,
894         c_switch_covers_all_cases_p): New functions.
895         * c-common.h (c_switch_covers_all_cases_p): Declare.
897 2017-11-28  Julia Koval  <julia.koval@intel.com>
898             Sebastian Peryt  <sebastian.peryt@intel.com>
900         * array-notation-common.c: Delete.
901         * c-cilkplus.c: Ditto.
902         * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
903         * c-common.def (ARRAY_NOTATION_REF): Remove.
904         * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
905         build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
906         c_validate_cilk_plus_loop, cilkplus_an_parts,
907         cilk_ignorable_spawn_rhs_op,
908         cilk_recognize_spawn): Remove.
909         * c-gimplify.c (CILK_SPAWN_STMT): Remove.
910         * c-omp.c: Remove CILK_SIMD check.
911         * c-pragma.c: Ditto.
912         * c-pragma.h: Remove CILK related pragmas.
913         * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
914         ARRAY_NOTATION_REF condition.
915         (c_pretty_printer::expression): Ditto.
916         * c.opt (fcilkplus): Remove.
917         * cilk.c: Delete.
919 2017-11-21  Marc Glisse  <marc.glisse@inria.fr>
921         * c-pretty-print.c (pp_c_additive_expression,
922         c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
924 2017-11-21  Jakub Jelinek  <jakub@redhat.com>
926         * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
928         PR c++/83059
929         * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
930         instead of tree_to_uhwi, formatting fix.
932 2017-11-20  David Malcolm  <dmalcolm@redhat.com>
934         PR c/81404
935         * known-headers.cc: New file, based on material from c/c-decl.c.
936         (suggest_missing_header): Copied as-is.
937         (get_stdlib_header_for_name): New, based on get_c_name_hint but
938         heavily edited to add C++ support.  Add some knowledge about
939         <limits.h>, <stdint.h>, and <wchar.h>.
940         * known-headers.h: Likewise.
942 2017-11-20  David Malcolm  <dmalcolm@redhat.com>
944         * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
945         (lookup_name_fuzzy): Likewise.  Convert return type from
946         const char * to name_hint.  Add location_t param.
947         * name-hint.h: New header.
949 2017-11-19  Jakub Jelinek  <jakub@redhat.com>
951         PR c/66618
952         PR c/69960
953         * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
955 2017-11-16  Joseph Myers  <joseph@codesourcery.com>
957         * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
958         expected publication date of C17.
959         (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
961 2017-11-15  Joseph Myers  <joseph@codesourcery.com>
963         PR c/81156
964         * c-common.c (c_common_reswords): Add __builtin_tgmath.
965         * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
967 2017-11-10  Martin Sebor  <msebor@redhat.com>
969         PR c/81117
970         * c-common.c (catenate_strings): Use memcpy instead of strncpy.
971         * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
972         * c.opt (-Wstringop-truncation): New option.
974 2017-11-06  Martin Liska  <mliska@suse.cz>
976         PR middle-end/82404
977         * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
978         FE.
979         * c.opt: Set default value of warn_return_type.
981 2017-10-31  David Malcolm  <dmalcolm@redhat.com>
983         * c-common.c (binary_op_error): Update for renaming of
984         error_at_rich_loc.
985         (c_parse_error): Likewise.
986         * c-warn.c (warn_logical_not_parentheses): Likewise for
987         renaming of inform_at_rich_loc.
988         (warn_for_restrict): Likewise for renaming of
989         warning_at_rich_loc_n.
991 2017-10-30  Joseph Myers  <joseph@codesourcery.com>
993         * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
994         * c-opts.c (set_std_c17): New function.
995         (c_common_init_options): Use gnu17 as default C version.
996         (c_common_handle_option): Handle -std=c17 and -std=gnu17.
998 2017-10-27  Michael Meissner  <meissner@linux.vnet.ibm.com>
1000         * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
1001         (c_cpp_builtins): If a machine has a fast fma _Float<N> and
1002         _Float<N>X variant, define __FP_FAST_FMA<N> and/or
1003         __FP_FAST_FMA<N>X.
1005 2017-10-23  Marek Polacek  <polacek@redhat.com>
1007         PR c/82681
1008         * c-warn.c (warnings_for_convert_and_check): Fix typos.
1010 2017-10-19  Eric Botcazou  <ebotcazou@adacore.com>
1012         * c-common.c (check_builtin_function_arguments): Also check arguments
1013         of __builtin_alloca_with_align_and_max.
1015 2017-10-17  David Malcolm  <dmalcolm@redhat.com>
1017         * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
1018         rather than NULL to format_warning_va.
1019         (check_format_types): Likewise when calling format_type_warning.
1020         Remove code to extract source_ranges and source_range * in favor
1021         of just a location_t.
1022         (format_type_warning): Convert source_range * param to a
1023         location_t.
1025 2017-10-13  Jakub Jelinek  <jakub@redhat.com>
1027         * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
1028         [LR]SHIFT_EXPR.
1030 2017-10-12  David Malcolm  <dmalcolm@redhat.com>
1032         * c-common.c (enum missing_token_insertion_kind): New enum.
1033         (get_missing_token_insertion_kind): New function.
1034         (maybe_suggest_missing_token_insertion): New function.
1035         * c-common.h (maybe_suggest_missing_token_insertion): New decl.
1037 2017-10-11  Nathan Sidwell  <nathan@acm.org>
1039         * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
1040         (c_common_handle_option): Update incpath_kind names.
1042 2017-10-11  Martin Liska  <mliska@suse.cz>
1044         PR sanitizer/82490
1045         * c-attribs.c (handle_no_sanitize_attribute): Report directly
1046         Wattributes warning.
1048 2017-10-10  Richard Sandiford  <richard.sandiford@linaro.org>
1050         * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
1051         operating on trees as wide_ints.
1052         * c-common.c (pointer_int_sum): Likewise.
1053         * c-pretty-print.c (pp_c_integer_constant): Likewise.
1054         * c-warn.c (match_case_to_enum_1): Likewise.
1055         (c_do_switch_warnings): Likewise.
1056         (maybe_warn_shift_overflow): Likewise.
1058 2017-10-10  Jakub Jelinek  <jakub@redhat.com>
1060         PR c/82437
1061         * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
1062         instead of wide_int::from.
1064 2017-10-06  Jakub Jelinek  <jakub@redhat.com>
1066         PR c/82437
1067         * c-warn.c (warn_tautological_bitwise_comparison): Instead of
1068         using to_widest use wide_int with the larger of the two precisions.
1070 2017-10-05  Bernd Edlinger  <bernd.edlinger@hotmail.de>
1072         * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
1073         functions.
1075 2017-10-02  Richard Sandiford  <richard.sandiford@linaro.org>
1077         * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
1078         when combining the original unconverted comparison operands.
1080 2017-09-29  Jakub Jelinek  <jakub@redhat.com>
1082         * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
1083         attribute.
1085 2017-09-29  Eric Botcazou  <ebotcazou@adacore.com>
1087         * c-ada-spec.c (to_ada_name): Add index parameter.
1088         (pp_ada_tree_identifier): Likewise.
1089         (dump_ada_macros): Adjust call to to_ada_name.
1090         (struct overloaded_name_hash): New type.
1091         (struct overloaded_name_hasher): Likewise.
1092         (overloaded_names): New hash table.
1093         (compute_overloading_index): New function.
1094         (dump_ada_decl_name): Call it and pass the result to
1095         pp_ada_tree_identifier.
1096         (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
1097         (dump_ada_function_declaration): Likewise.
1098         (dump_generic_ada_node): Likewise.
1099         (print_constructor): Likewise.
1100         (print_destructor): Likewise.
1101         (dump_ada_specs): Delete overloaded_names table.
1103 2017-09-29  Eric Botcazou  <ebotcazou@adacore.com>
1105         * c-ada-spec.c (max_ada_macros): Move around.
1106         (store_ada_macro_index): Likewise.
1107         (source_file): Rename into...
1108         (macro_source_file): ...this.
1109         (count_ada_macro): Move around.
1110         (store_ada_macro): Likewise.
1111         (compare_macro): Likewise.
1112         (print_ada_macros): Merge in...
1113         (dump_ada_macros): ...this.
1114         (source_file_base): Rename into...
1115         (current_source_file): ...this.
1116         (print_comment): Move around.
1117         (dump_ada_nodes): Call dump_ada_declaration directly.
1118         (struct with): Change type of limited field to bool.
1119         (append_withs): Change type of limited_access parameter to bool.
1120         (pp_ada_tree_identifie): Likewise.
1121         (dump_ada_decl_nam): Likewise.
1122         (dump_generic_ada_node): Likewise.  Do not print the return type.
1123         (to_ada_name): Change type of space_found parameter to bool.
1124         (dump_ada_function_declaration): Return void and change type of
1125         parameters to bool.  Also print the return type for a function.
1126         (print_ada_methods): Rename into...
1127         (dump_ada_methods): ...this.
1128         (print_ada_declaration): Rename into ...
1129         (dump_ada_declaration): ...this.  Do not print the return type.
1130         (print_ada_struct_decl): Rename into...
1131         (dump_ada_struct_decl): ...this.
1133 2017-09-29  Jakub Jelinek  <jakub@redhat.com>
1135         * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
1136         rather than DECL_INITIAL.
1137         (common_handle_aligned_attribute): Likewise.
1139 2017-09-20  Alexandre Oliva <aoliva@redhat.com>
1141         * c.opt (gen-decls): Add RejectNegative.
1143 2017-09-15  Andrew Sutton  <andrew.n.sutton@gmail.com>
1144             Jakub Jelinek  <jakub@redhat.com>
1146         Add support for -std=c++2a.
1147         * c-common.h (cxx_dialect): Add cxx2a as a dialect.
1148         * opt.c: Add options for -std=c++2a and -std=gnu++2a.
1149         * c-opts.c (set_std_cxx2a): New.
1150         (c_common_handle_option): Set options when -std=c++2a is enabled.
1151         (c_common_post_options): Adjust comments.
1152         (set_std_cxx14, set_std_cxx17): Likewise.
1154 2017-09-15  Eric Botcazou  <ebotcazou@adacore.com>
1156         * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
1157         message for non-uniform endianness and issue a warning in C++.
1159 2017-09-15  Jakub Jelinek  <jakub@redhat.com>
1161         * c.opt (Wc++1z-compat): Change from option to undocumented alias.
1162         (Wc++17-compat): Change from undocumented alias to option.
1163         (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
1164         change C++1z to C++17 in description.
1165         (std=c++1z, std=gnu++1z): Change from option to undocumented
1166         deprecated alias.
1167         (std=c++17, std=gnu++17): Change from undocumented alias to option.
1168         Adjust description.
1169         * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
1170         * c-opts.c (set_std_cxx1z): Rename to ...
1171         (set_std_cxx17): ... this.
1172         (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
1173         and OPT_std_gnu__1z to OPT_std_gnu__17.  Adjust set_std_cxx1z
1174         caller.
1175         (c_common_post_options): Use cxx17 instead of cxx1z.  Adjust
1176         comments.
1178 2017-09-12  H.J. Lu  <hongjiu.lu@intel.com>
1180         * c-attribs.c (common_handle_aligned_attribute): Don't warn
1181         function alignment if warn_if_not_aligned_p is true.
1183 2017-09-12  Nathan Sidwell  <nathan@acm.org>
1185         * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
1186         resort_sorted_fields): Move to c/c-decl.c.
1187         * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
1188         (struct sorted_fields_type): Move to c/c-lang.h.
1190 2017-09-09  Jonathan Wakely  <jwakely@redhat.com>
1192         PR c++/81852
1193         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
1195 2017-09-04  Marek Polacek  <polacek@redhat.com>
1197         PR c/81783
1198         * c-warn.c (warn_tautological_bitwise_comparison): New function.
1199         (warn_tautological_cmp): Call it.
1201 2017-09-01  Boris Kolpackov <boris@codesynthesis.com>
1203         * c-opts.c (c_common_finish): Write dependency information even if
1204         there are errors.
1206 2017-09-01  Jakub Jelinek  <jakub@redhat.com>
1208         PR c/81887
1209         * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
1210         (omp_pragmas_simd): ... here.
1211         * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
1212         create new clauses list containing just simd clause.
1214 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
1215             Alan Hayward  <alan.hayward@arm.com>
1216             David Sherwood  <david.sherwood@arm.com>
1218         * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
1219         into scalar_mode_supported_p call.
1220         (handle_mode_attribute): Update call to scalar_mode_supported_p.
1222 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
1223             Alan Hayward  <alan.hayward@arm.com>
1224             David Sherwood  <david.sherwood@arm.com>
1226         * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
1227         for the mode iterator.
1229 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
1230             Alan Hayward  <alan.hayward@arm.com>
1231             David Sherwood  <david.sherwood@arm.com>
1233         * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
1234         * c-common.c (c_build_vec_perm_expr): Likewise.
1236 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
1237             Alan Hayward  <alan.hayward@arm.com>
1238             David Sherwood  <david.sherwood@arm.com>
1240         * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
1242 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
1243             Alan Hayward  <alan.hayward@arm.com>
1244             David Sherwood  <david.sherwood@arm.com>
1246         * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
1247         before calling targetm.addr_space.valid_pointer_mode.
1249 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
1250             Alan Hayward  <alan.hayward@arm.com>
1251             David Sherwood  <david.sherwood@arm.com>
1253         * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
1255 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
1256             Alan Hayward  <alan.hayward@arm.com>
1257             David Sherwood  <david.sherwood@arm.com>
1259         * c-common.c (c_common_fixed_point_type_for_size): Use new mode
1260         iterators.
1261         * c-cppbuiltin.c (c_cpp_builtins): Likewise.
1263 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
1264             Alan Hayward  <alan.hayward@arm.com>
1265             David Sherwood  <david.sherwood@arm.com>
1267         * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
1268         case statements.
1270 2017-08-29  Martin Liska  <mliska@suse.cz>
1272         PR other/39851
1273         * c-common.c (parse_optimize_options): Add argument to function
1274         call.
1275         * c-pragma.c (handle_pragma_diagnostic): Likewise.
1277 2017-08-24  David Malcolm  <dmalcolm@redhat.com>
1279         * c-lex.c (interpret_float): Use token location
1280         when building an EXCESS_PRECISION_EXPR.
1282 2017-08-21  David Malcolm  <dmalcolm@redhat.com>
1284         * c-common.c (check_function_arguments): Add "arglogs" param; pass
1285         it to check_function_format.
1286         * c-common.h (check_function_arguments): Add vec<location_t> *
1287         param.
1288         (check_function_format): Likewise.
1289         * c-format.c (struct format_check_context): Add field "arglocs".
1290         (check_function_format): Add param "arglocs"; pass it to
1291         check_format_info.
1292         (check_format_info):  Add param "arglocs"; use it to initialize
1293         new field of format_ctx.
1294         (check_format_arg): Pass format_ctx->arglocs to new param of
1295         check_format_info_main.
1296         (class argument_parser): New field "arglocs".
1297         (argument_parser::argument_parser): Add "arglocs_" param and use
1298         it to initialize new field.
1299         (argument_parser::check_argument_type): Pass new arglocs field to
1300         check_format_types.
1301         (check_format_info_main): Add param "arglocs", and use it when
1302         constructing arg_parser.
1303         (check_format_types): Add param "arglocs"; use it if non-NULL when
1304         !EXPR_HAS_LOCATION (cur_param) to get at location information.
1306 2017-08-18  H.J. Lu  <hongjiu.lu@intel.com>
1308         PR c/53037
1309         * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
1310         (c_common_attribute_table): Add warn_if_not_aligned.
1311         (handle_aligned_attribute): Renamed to ...
1312         (common_handle_aligned_attribute): Remove argument, name, and add
1313         argument, warn_if_not_aligned.  Handle warn_if_not_aligned.
1314         (handle_aligned_attribute): New.
1315         * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
1317 2017-08-14  Martin Sebor  <msebor@redhat.com>
1319         PR c/81117
1320         * c-attribs.c (c_common_attribute_table): Add nonstring entry.
1321         (handle_nonstring_attribute): New function.
1323 2017-08-14  Martin Sebor  <msebor@redhat.com>
1325         PR c/81117
1326         * c-format.h (T89_G): New macro.
1327         * c-format.c (local_gcall_ptr_node): New variable.
1328         (init_dynamic_diag_info): Initialize it.
1330 2017-08-11  Martin Liska  <mliska@suse.cz>
1332         * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
1333         TARGET_SUPPORTS_ALIASES.
1335 2017-08-10  David Malcolm  <dmalcolm@redhat.com>
1337         * c-common.c (c_parse_error): Add rich_location * param, using it
1338         rather implicitly using input_location.
1339         * c-common.h (c_parse_error): Add rich_location * param.
1341 2017-08-09  Marek Polacek  <polacek@redhat.com>
1343         * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
1344         (c_common_truthvalue_conversion): Likewise.
1345         * c-omp.c (c_finish_omp_atomic): Likewise.
1346         * c-common.h (build_binary_op): Update declaration.
1348 2017-08-08  Martin Liska  <mliska@suse.cz>
1350         * c-ada-spec.c: Include header files.
1351         * c-ubsan.c: Likewise.
1352         * c-warn.c: Likewise.
1354 2017-08-07  Jakub Jelinek  <jakub@redhat.com>
1356         PR c/69389
1357         * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
1359 2017-08-07  Eric Botcazou  <ebotcazou@adacore.com>
1361         * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
1362         (print_ada_methods): Likewise.
1363         (print_ada_declaration): Likewise.
1365 2017-08-07  Martin Liska  <mliska@suse.cz>
1367         * array-notation-common.c: Add new includes.
1368         * c-format.c( handle_format_attribute): Canonicalize a format
1369         function name.
1370         * c-lex.c (c_common_has_attribute): Canonicalize name of an
1371         attribute.
1372         * c-pretty-print.c: Add new include.
1374 2017-08-05  Eric Botcazou  <ebotcazou@adacore.com>
1376         * c-ada-spec.c (has_static_fields): Look only into variables.
1377         (print_constructor): Add TYPE parameter and use it for the name.
1378         (print_destructor): Likewise.
1379         (print_ada_declaration): Adjust to new constructor/destructor names.
1380         Adjust calls to print_constructor and print_destructor.
1381         (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
1382         Look only into variables in the final loop.
1384 2017-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1386         * c-ada-spec.c (has_static_fields): Look only into fields.
1387         (dump_generic_ada_node): Small tweak.
1388         (dump_nested_types): Look only into fields.
1389         (print_ada_declaration): Look only into methods.  Small tweak.
1390         (print_ada_struct_decl): Look only into fields.  Use DECL_VIRTUAL_P.
1392 2017-08-01  Eric Botcazou  <ebotcazou@adacore.com>
1394         * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
1395         (dump_ada_function_declaration): Likewise.
1396         (dump_generic_ada_node): Likewise.
1397         (print_ada_declaration): Add support for const-qualified variables.
1399 2017-07-31  Martin Liska  <mliska@suse.cz>
1401         PR sanitize/81530
1402         * c-ubsan.c (ubsan_maybe_instrument_array_ref):
1403         Guard condition with flag_sanitize_p also with current_function_decl
1404         non-null equality.
1405         (ubsan_maybe_instrument_reference_or_call): Likewise.
1407 2017-07-30  Uros Bizjak  <ubizjak@gmail.com>
1409         * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
1411 2017-07-29  Eric Botcazou  <ebotcazou@adacore.com>
1413         * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
1414         for enumeral types.
1415         (print_ada_declaration): Add missing guard for record types.
1417 2017-07-27  Jakub Jelinek  <jakub@redhat.com>
1419         PR c/45784
1420         * c-omp.c (c_finish_omp_for): If the condition is wrapped in
1421         rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
1422         new COMPOUND_EXPRs around the rhs of the comparison.
1424 2017-07-27  Marek Polacek  <polacek@redhat.com>
1426         PR c/81417
1427         * c-warn.c (warn_for_sign_compare): Tweak the warning message.  Print
1428         the types.
1430 2017-07-27  Jakub Jelinek  <jakub@redhat.com>
1432         * c-attribs.c (c_common_attribute_table): Add noipa attribute.
1433         (handle_noipa_attribute): New function.
1435 2017-07-07  Torsten Duwe  <duwe@suse.de>
1437         * c-attribs.c (c_common_attribute_table): Add entry for
1438         "patchable_function_entry".
1440 2017-07-20  Nathan Sidwell  <nathan@acm.org>
1442         Remove TYPE_METHODS.
1443         * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
1444         dump_ada_template, print_ada_methods,
1445         print_ada_declaration): Member fns are on TYPE_FIELDS.
1447 2017-07-18  Nathan Sidwell  <nathan@acm.org>
1449         * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
1451 2017-07-14  David Malcolm  <dmalcolm@redhat.com>
1453         * c-common.c (try_to_locate_new_include_insertion_point): New
1454         function.
1455         (per_file_includes_t): New typedef.
1456         (added_includes_t): New typedef.
1457         (added_includes): New variable.
1458         (maybe_add_include_fixit): New function.
1459         * c-common.h (maybe_add_include_fixit): New decl.
1461 2017-07-10  Martin Sebor  <msebor@redhat.com>
1463         PR other/81345
1464         * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
1466 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
1468         * c-common.c (selftest::c_family_tests): New.
1469         * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
1470         (selftest::c_family_tests): New decl.
1472 2017-07-04  Marek Polacek  <polacek@redhat.com>
1474         PR c/81231
1475         * c-common.c (sync_resolve_size): Give error for pointers to incomplete
1476         types.
1478 2017-07-04  Marek Polacek  <polacek@redhat.com>
1480         * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
1482 2017-06-28  Martin Liska  <mliska@suse.cz>
1484         PR ipa/81128
1485         * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
1486         to a function declaration.
1488 2017-06-28  Martin Liska  <mliska@suse.cz>
1490         PR driver/79659
1491         * c.opt: Add IntegerRange to various options.
1493 2017-06-26  Marek Polacek  <polacek@redhat.com>
1495         PR c/80116
1496         * c-common.h (warn_for_multistatement_macros): Declare.
1497         * c-warn.c: Include "c-family/c-indentation.h".
1498         (warn_for_multistatement_macros): New function.
1499         * c.opt (Wmultistatement-macros): New option.
1500         * c-indentation.c (guard_tinfo_to_string): No longer static.
1501         Change the parameter type to "enum rid".  Handle RID_SWITCH.
1502         * c-indentation.h (guard_tinfo_to_string): Declare.
1504 2017-06-23  Marc Glisse  <marc.glisse@inria.fr>
1506         * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
1508 2017-06-15  Martin Sebor  <msebor@redhat.com>
1510         PR c++/80560
1511         * c.opt (-Wclass-memaccess): New option.
1513 2017-06-14  Boris Kolpackov  <boris@codesynthesis.com>
1515         * c-opts.c (c_common_finish): Handle '-' special value to -MF.
1517 2017-06-13  Marek Polacek  <polacek@redhat.com>
1519         PR objc/80949
1520         * c-warn.c (do_warn_duplicated_branches): Return if any of the
1521         branches is null.
1523 2017-06-13  Martin Liska  <mliska@suse.cz>
1525         PR sanitize/78204
1526         * c-attribs.c (add_no_sanitize_value): New function.
1527         (handle_no_sanitize_attribute): Likewise.
1528         (handle_no_sanitize_address_attribute): Use the function.
1529         (handle_no_sanitize_thread_attribute): New function.
1530         (handle_no_address_safety_analysis_attribute): Use
1531         add_no_sanitize_value.
1532         (handle_no_sanitize_undefined_attribute): Likewise.
1533         * c-common.h: Declare new functions.
1534         * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
1535         (ubsan_instrument_shift): Likewise.
1536         (ubsan_instrument_bounds): Likewise.
1537         (ubsan_maybe_instrument_array_ref): Likewise.
1538         (ubsan_maybe_instrument_reference_or_call): Likewise.
1540 2017-06-11  Jason Merrill  <jason@redhat.com>
1542         * c-ada-spec.c, c-pragma.c: Use id_equal.
1544 2017-06-04  Marek Polacek  <polacek@redhat.com>
1546         PR c/80919
1547         * c-format.c (matching_type_p): Return false if any of the types
1548         requires structural equality.
1550 2017-06-02  Martin Sebor  <msebor@redhat.com>
1552         PR c/80892
1553         * c-warn.c (conversion_warning): Use -Wconversion for integer
1554         conversion and -Wfloat-conversion for floating one.
1556 2017-06-02  Bernd Edlinger  <bernd.edlinger@hotmail.de>
1558         * c.opt (Wsizeof-pointer-div): New warning option.
1560 2017-06-01  Volker Reichelt  <v.reichelt@netcologne.de>
1562         * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
1563         (Wcatch-value=1): Enable by -Wall.
1565 2017-05-30  David Malcolm  <dmalcolm@redhat.com>
1567         * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
1568         format_chars.
1569         * c.opt (fdiagnostics-show-template-tree): New option.
1570         (felide-type): New option.
1572 2017-05-25  Volker Reichelt  <v.reichelt@netcologne.de>
1574         * c.opt (Wcatch-value=): New C++ warning flag.
1576 2017-05-24  Nathan Sidwell  <nathan@acm.org>
1578         * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
1579         const casts to avoid warning.
1581 2017-05-24  Martin Sebor  <msebor@redhat.com>
1583         PR c/80731
1584         * c-common.h (unsafe_conversion_p): Add a function argument.
1585         * c-common.c (unsafe_conversion_p): Same.
1586         Add type names and values to diagnostics.
1587         (scalar_to_vector): Adjust.
1588         * c-warn.c (constant_expression_error): Add a function argument.
1589         Add type names and values to diagnostics.
1590         (conversion_warning): Add a function argument.
1591         Add type names and values to diagnostics.
1592         (warnings_for_convert_and_check): Same.
1594 2017-05-19  Jason Merrill  <jason@redhat.com>
1596         * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
1597         enumerators.
1599 2017-05-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>
1601         * c-format.c (locus): Move out of function scope,
1602         add GTY attribute.
1604 2017-05-19  Nathan Sidwell  <nathan@acm.org>
1606         * c-opts.c (class_dump_file, class_dump_flags): Delete.
1607         (c_common_parse_file): Remove class dump handling.
1608         (get_dump_info): Likewise.
1610 2017-05-19  Richard Biener  <rguenther@suse.de>
1612         PR c++/80593
1613         * c-warn.c (strict_aliasing_warning): Do not warn for accesses
1614         to alias-set zero memory.
1616 2017-05-18  Bernd Edlinger  <bernd.edlinger@hotmail.de>
1618         * c-format.c (local_tree_type_node): Add GTY attribute.
1620 2017-05-18  Marek Polacek  <polacek@redhat.com>
1622         * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
1623         (c_common_fixed_point_type_for_size): Likewise.
1624         (c_common_type_for_mode): Likewise.
1625         (shorten_compare): Likewise.
1626         (c_promoting_integer_type_p): Use false/true instead of 0/1.
1627         * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
1629 2017-05-18  Marek Polacek  <polacek@redhat.com>
1631         * c-common.c (self_promoting_args_p): Change the return type to bool.
1632         Use false/true instead of 0/1.
1633         * c-common.h (self_promoting_args_p): Update.
1635 2017-05-17  Marek Polacek  <polacek@redhat.com>
1637         * c-common.c: Use NULL_TREE instead of 0 where appropriate.
1638         * c-warn.c: Likewise.
1640 2017-05-17  Ville Voutilainen  <ville.voutilainen@gmail.com>
1642         Implement new C++ intrinsics __is_assignable and __is_constructible.
1643         * c-common.c (__is_assignable, __is_constructible): New.
1644         * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
1646 2017-05-17  Martin Liska  <mliska@suse.cz>
1648         * c-common.h: Introduce dump_flags_t type and
1649         use it instead of int type.
1650         * c-gimplify.c (c_genericize): Likewise.
1651         * c-opts.c: Likewise.
1653 2017-05-17  Marek Polacek  <polacek@redhat.com>
1655         * c-common.c (c_save_expr): Remove.
1656         (c_common_truthvalue_conversion): Remove a call to c_save_expr.
1657         * c-common.h (c_save_expr): Remove declaration.
1659 2017-05-09  Volker Reichelt  <v.reichelt@netcologne.de>
1661         PR c/35441
1662         * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
1663         MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
1664         (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
1665         (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
1666         RDIV_EXPR.
1667         (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
1669 2017-05-09  Marek Polacek  <polacek@redhat.com>
1671         PR c/80525
1672         * c-warn.c (unwrap_c_maybe_const): New.
1673         (warn_logical_operator): Call it.
1675 2017-05-09  Nathan Sidwell  <nathan@acm.org>
1677         * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
1678         * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
1680 2017-05-08  Martin Sebor  <msebor@redhat.com>
1682         PR translation/80280
1683         * c-format.h (struct format_flag_spec): Add new member.
1684         (T89_T): New macro.
1685         * c-format.c (local_tree_type_node): New global.
1686         (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
1687         (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
1688         (strfmon_flag_specs): Likewise.
1689         (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
1690         with distinct quoting properties.
1691         (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
1692         (flag_chars_t::validate): Add argument and handle bad quoting.
1693         (check_format_info_main): Handle quoting problems.
1694         (init_dynamic_diag_info): Simplify.
1696 2017-05-08  Jason Merrill  <jason@redhat.com>
1698         * c-opts.c (c_common_post_options): Update defaults for
1699         flag_abi_version and flag_abi_compat_version.
1701 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
1703         * c-common.c (c_cpp_error): Replace report_diagnostic
1704         with diagnostic_report_diagnostic.
1706 2017-05-04  Martin Sebor  <msebor@redhat.com>
1708         PR translation/80280
1709         * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
1710         (handle_weakref_attribute): Same.
1712 2017-05-03  Nathan Sidwell  <nathan@acm.org>
1714         Canonicalize canonical type hashing
1715         * c-common.c (complete_array_type): Use type_hash_canon.
1717 2017-05-01  Xi Ruoyao  <ryxi@stu.xidian.edu.cn>
1719         PR c++/80038
1720         * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
1721         prototype.
1722         (cilk_install_body_pedigree_operations): Likewise.
1723         * cilk.c (cilk_set_spawn_marker): Mark functions that should be
1724         detatched.
1725         (cilk_gimplify_call_params_in_spawned_fn): Remove.
1726         (cilk_install_body_pedigree_operations): Likewise.
1727         (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
1728         unwrapping.
1730 2017-04-27  Jakub Jelinek  <jakub@redhat.com>
1732         PR c++/80534
1733         * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
1734         flag on non-aggregate element types.
1736 2017-04-25  Bernd Edlinger  <bernd.edlinger@hotmail.de>
1738         * c-common.c (c_type_hasher, type_hash_table): Remove.
1739         (c_common_get_alias_set): Remove unreachable code.
1740         * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
1742 2017-04-20  Volker Reichelt  <v.reichelt@netcologne.de>
1744         * c.opt (Wextra-semi): New C++ warning flag.
1746 2017-04-20  Jakub Jelinek  <jakub@redhat.com>
1748         PR middle-end/80423
1749         * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
1751 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
1753         PR middle-end/79788
1754         PR middle-end/80375
1755         * c-common.c (c_common_type_for_mode): Don't handle
1756         widest_*_literal_type_node here.
1757         c_common_signed_or_unsigned_type): Likewise.
1758         (c_common_nodes_and_builtins): Set widest_*_literal_type_node
1759         to *intTI_type_node or *intDI_type_node depending on whether
1760         TImode is supported by the target or not.
1762 2017-04-10  Martin Liska  <mliska@suse.cz>
1764         PR sanitizer/80350
1765         * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
1766         doing an UBSAN check.
1768 2017-04-03  Jonathan Wakely  <jwakely@redhat.com>
1770         * c-warn.c (do_warn_double_promotion): Fix typo in comment.
1772 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
1774         PR c++/79572
1775         * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
1776         tree *.
1777         * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise.  Handle
1778         not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
1779         REFERENCE_TYPE.
1781 2017-03-31  David Malcolm  <dmalcolm@redhat.com>
1783         PR documentation/78732
1784         * c.opt (Wendif-labels): Fix description to refer to
1785         #else rather than #elif.
1787 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
1789         PR libstdc++/80251
1790         * c-common.h (enum rid): Add RID_IS_AGGREGATE.
1791         * c-common.c (c_common_reswords): Add __is_aggregate trait.
1793 2017-03-27  Jakub Jelinek  <jakub@redhat.com>
1795         PR middle-end/80162
1796         * c-common.c (c_common_mark_addressable_vec): Don't set
1797         TREE_ADDRESSABLE on DECL_HARD_REGISTER.
1799 2017-03-21  Martin Sebor  <msebor@redhat.com>
1801         PR c++/79548
1802         * c-common.c (set_underlying_type): Mark type used only when
1803         original del is declared unused.
1805 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
1807         PR translation/79848
1808         * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
1809         "%qs".
1811 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
1813         PR c/79921
1814         * c-indentation.c (warn_for_misleading_indentation): Remove parens
1815         from inform's message, so that xgettext can locate it.
1817 2017-03-09  Marek Polacek  <polacek@redhat.com>
1819         PR c++/79962
1820         PR c++/79984
1821         * c-attribs.c (handle_nonnull_attribute): Save the result of default
1822         conversion to the attribute list.
1824 2017-03-09  Martin Liska  <mliska@suse.cz>
1826         * c-ada-spec.c (macro_length): Increment value instead of a pointer.
1828 2017-03-03  Jason Merrill  <jason@redhat.com>
1830         * c.opt (Wnoexcept-type): New.
1832 2017-03-02  Richard Biener  <rguenther@suse.de>
1834         PR c/79756
1835         * c-common.c (c_common_mark_addressable_vec): Look through
1836         C_MAYBE_CONST_EXPR.
1838 2017-02-28  Martin Liska  <mliska@suse.cz>
1840         * c.opt: Replace space with tabular for options of <number>
1841         type.
1843 2017-02-28  Martin Liska  <mliska@suse.cz>
1845         * c.opt: Fix --help=option -Q for options which are of
1846         an enum type.
1848 2017-02-24  Jakub Jelinek  <jakub@redhat.com>
1850         PR c++/79588
1851         * c-common.c (check_function_restrict): New function.
1852         (check_function_arguments): Add FNDECL argument.  Call
1853         check_function_restrict if -Wrestrict.
1854         * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
1855         and NARGS.  Use auto_vec for ARG_POSITIONS, simplify.
1856         * c-common.h (check_function_arguments): Add FNDECL argument.
1857         (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
1859 2017-02-24  Eric Botcazou  <ebotcazou@adacore.com>
1861         * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
1862         treatment of parameters with pointer-to-tagged type and tidy up.
1863         (print_ada_methods): Remove the special treatment of C++ static member
1864         functions.
1866 2017-02-22  Martin Liska  <mliska@suse.cz>
1868         * c.opt: Replace inequality signs with square brackets
1869         for -Wnornalized.
1871 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
1873         PR c++/79641
1874         * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
1875         preserve quals.
1877 2017-02-17  Joseph Myers  <joseph@codesourcery.com>
1879         * c-cppbuiltin.c (builtin_define_float_constants): Define
1880         __DECIMAL_DIG__ to the value for long double.
1882 2017-02-15  Marek Polacek  <polacek@redhat.com>
1884         PR c/79515
1885         * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
1886         conversion has occured.
1888 2017-01-24  David Malcolm  <dmalcolm@redhat.com>
1890         * c-common.c (c_common_reswords): Add "__RTL".
1891         * c-common.h (enum rid): Add RID_RTL.
1893 2017-01-20  Marek Polacek  <polacek@redhat.com>
1895         PR c/64279
1896         * c-common.h (do_warn_duplicated_branches_r): Declare.
1897         * c-gimplify.c (c_genericize): Walk the function tree calling
1898         do_warn_duplicated_branches_r.
1899         * c-warn.c (expr_from_macro_expansion_r): New.
1900         (do_warn_duplicated_branches): New.
1901         (do_warn_duplicated_branches_r): New.
1902         * c.opt (Wduplicated-branches): New option.
1904 2017-01-17  David Malcolm  <dmalcolm@redhat.com>
1906         PR c++/71497
1907         * c-indentation.c (warn_for_misleading_indentation): Use the past
1908         subjunctive in the note.
1910 2017-01-17  Aldy Hernandez  <aldyh@redhat.com>
1912         PR c/79116
1913         * array-notation-common.c (cilkplus_extract_an_triplets): Convert
1914         start type to integer_type.
1916 2017-01-16  Jakub Jelinek  <jakub@redhat.com>
1918         PR driver/49726
1919         * c.opt (gen-decls): Add Driver flag.
1921 2017-01-16  Paolo Carlini  <paolo.carlini@oracle.com>
1923         Revert:
1924         2017-01-16  Paolo Carlini  <paolo.carlini@oracle.com>
1926         PR c++/71737
1927         * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
1929 2017-01-16  Paolo Carlini  <paolo.carlini@oracle.com>
1931         PR c++/71737
1932         * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
1934 2017-01-12  Martin Sebor  <msebor@redhat.com>
1936         (-Wformat-overflow): ...to this.
1938 2017-01-11  Martin Sebor  <msebor@redhat.com>
1940         PR c/78768
1941         * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
1942         Also enable for LTO.
1944 2017-01-10  Jason Merrill  <jason@redhat.com>
1946         Implement P0195R2, C++17 variadic using.
1947         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
1949 2017-01-09  Jakub Jelinek  <jakub@redhat.com>
1951         PR translation/79019
1952         PR translation/79020
1953         * c.opt (Wnormalized=): Fix typo in description.
1955 2017-01-08  Martin Sebor  <msebor@redhat.com>
1957         PR middle-end/77708
1958         * c.opt (-Wformat-truncation): New option.
1960 2017-01-06  Alexandre Oliva <aoliva@redhat.com>
1962         * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
1963         value to unsigned short to fit in 4 hex digits without
1964         warnings.
1966 2017-01-05  Eric Botcazou  <ebotcazou@adacore.com>
1968         * c.opt (fsso-struct): Add 'native' value.
1970 2017-01-05  Martin Liska  <mliska@suse.cz>
1972         PR pch/78970
1973         * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
1974         header.
1976 2017-01-04  Marek Polacek  <polacek@redhat.com>
1978         PR c++/64767
1979         * c.opt (Wpointer-compare): New option.
1981 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
1983         PR driver/78957
1984         * c.opt (fsso-struct=): Add RejectNegative.
1986 2017-01-01  Jakub Jelinek  <jakub@redhat.com>
1988         Update copyright years.
1990 2016-12-29  Martin Liska  <mliska@suse.cz>
1992         PR c/78933
1993         * c.opt (strong-eval-order): Add RejectNegative keyword.
1995 2016-12-22  Jason Merrill  <jason@redhat.com>
1997         Implement P0522R0, matching of template template arguments.
1998         * c-cppbuiltin.c (c_cpp_builtins): Define
1999         __cpp_template_template_args.
2001 2016-12-21  Jakub Jelinek  <jakub@redhat.com>
2003         PR bootstrap/78817
2004         * c-common.c (struct nonnull_arg_ctx): New type.
2005         (check_function_nonnull): Return bool instead of void.  Use
2006         nonnull_arg_ctx as context rather than just location_t.
2007         (check_nonnull_arg): Adjust for the new context type, set
2008         warned_p to true if a warning has been diagnosed.
2009         (check_function_arguments): Return bool instead of void.
2010         * c-common.h (check_function_arguments): Adjust prototype.
2012 2016-12-21  Jason Merrill  <jason@redhat.com>
2014         * c.opt (-fnew-ttp-matching): New flag.
2015         * c-opts.c (c_common_post_options): Default on if -std=c++1z.
2017 2016-12-14  Martin Jambor  <mjambor@suse.cz>
2019         * c-omp.c: Include omp-general.h instead of omp-low.h.
2020         (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
2021         name.
2023 2016-12-14  Martin Sebor  <msebor@redhat.com>
2025         PR c/17308
2026         * c-common.c (check_nonnull_arg): Disable when optimization
2027         is enabled.
2029 2016-12-12  Marek Polacek  <polacek@redhat.com>
2031         PR c++/78647
2032         * c-common.c (attribute_fallthrough_p): Return false for
2033         error_mark_node.
2035 2016-12-08  Martin Sebor  <msebor@redhat.com>
2037         PR c/78284
2038         * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
2040 2016-12-08  Martin Sebor  <msebor@redhat.com>
2042         PR c/78165
2043         * c-pretty-print (pp_c_integer_constant): Avoid formatting type
2044         suffix.
2046 2016-12-07  Martin Sebor  <msebor@redhat.com>
2048         PR c/53562
2049         PR middle-end/77784
2050         PR middle-end/78149
2051         PR middle-end/78138
2052         * c.opt (-Wstringop-overflow): New option.
2054 2016-12-02  Maxim Ostapenko  <m.ostapenko@samsung.com>
2056         * c-attribs.c (asan odr indicator): New attribute.
2057         (handle_asan_odr_indicator_attribute): New function.
2059 2016-11-26  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
2061         * c-common.c (c_common_nodes_and_builtins): Remove initialization of
2062         ptrdiff_type_node;
2064 2016-11-23  James Greenhalgh  <james.greenhalgh@arm.com>
2066         * c-common.c (excess_precision_mode_join): New.
2067         (c_ts18661_flt_eval_method): New.
2068         (c_c11_flt_eval_method): Likewise.
2069         (c_flt_eval_method): Likewise.
2070         * c-common.h (excess_precision_mode_join): New.
2071         (c_flt_eval_method): Likewise.
2072         * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
2073         (cpp_iec_559_value): Call it.
2074         (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
2075         call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
2076         __FLT_EVAL_METHOD_TS_18661_3__.
2078 2016-11-23  James Greenhalgh  <james.greenhalgh@arm.com>
2080         * c-opts.c (c_common_post_options): Add logic to handle the default
2081         case for -fpermitted-flt-eval-methods.
2083 2016-11-23  Paolo Bonzini  <bonzini@gnu.org>
2085         * c.opt (Wexpansion-to-defined): New.
2087 2016-11-23  Jakub Jelinek  <jakub@redhat.com>
2089         PR target/78451
2090         * c-pragma.c (handle_pragma_target): Don't replace
2091         current_target_pragma, but chainon the new args to the current one.
2093 2016-11-22  Nathan Sidwell  <nathan@acm.org>
2095         * array-notation-common.c (cilkplus_extract_an_trplets): Fix
2096         indentation and formatting.
2098 2016-11-21  Martin Sebor  <msebor@redhat.com>
2100         * c.opt (-fprintf-return-value): Enable by default.
2102 2016-11-21  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2104         PR c++/71973
2105         * c.opt (-Wbuiltin-declaration-mismatch): New warning.
2106         * c-common.c (c_common_nodes_and_builtins): Initialize
2107         const_tm_ptr_type_node.
2109 2016-11-16  Marek Polacek  <polacek@redhat.com>
2111         PR c/78285
2112         * c-common.c (c_add_case_label): Turn error_at calls into inform.
2114 2016-11-14  Jakub Jelinek  <jakub@redhat.com>
2116         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
2118 2016-11-14  Prasad Ghangal  <prasad.ghangal@gmail.com>
2119             Richard Biener  <rguenther@suse.de>
2121         * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
2122         * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
2123         * c.opt (fgimple): New option.
2125 2016-11-13  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
2127         PR c/35503
2128         * c-common.h (warn_for_restrict): Declare.
2129         * c-warn.c: Include gcc-rich-location.h.
2130         (warn_for_restrict): New function.
2131         * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
2132         (gcc_cdiag_char_table): Likewise.
2133         (gcc_cxxdiag_char_table): Likewise.
2134         * c.opt (Wrestrict): New option.
2136 2016-11-13  Eric Botcazou  <ebotcazou@adacore.com>
2138         * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
2139         for nested types only if the type is a record or union and dump SLOC.
2141 2016-11-09  Jason Merrill  <jason@redhat.com>
2143         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
2145 2016-11-09  Jakub Jelinek  <jakub@redhat.com>
2147         * c-ubsan.c (ubsan_instrument_shift): Handle split
2148         -fsanitize=shift-base and -fsanitize=shift-exponent.
2150 2016-11-07  Jason Merrill  <jason@redhat.com>
2152         * c.opt (Wc++1z-compat): New.
2153         * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
2155 2016-11-07  Martin Liska  <mliska@suse.cz>
2157         * c-warn.c (warn_for_unused_label): Save all labels used
2158         in goto or in &label.
2160 2016-11-03  Jason Merrill  <jason@redhat.com>
2162         * c-cppbuiltin.c (c_cpp_builtins): Correct
2163         __cpp_inheriting_constructors.
2165 2016-11-01  Jason Merrill  <jason@redhat.com>
2167         * c-cppbuiltin.c (c_cpp_builtins): Update
2168         __cpp_inheriting_constructors.
2170         * c.opt (-fnew-inheriting-ctors): New.
2171         * c-opts.c: Default to on for ABI 11+.
2173 2016-10-31  Jakub Jelinek  <jakub@redhat.com>
2175         PR c++/77948
2176         * c.opt (fext-numeric-literals): Add Var and Init.
2177         * c-opts.c (c_common_handle_option): Don't clear
2178         cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
2179         (c_common_post_options): Clear it here if not set
2180         explicitly.
2182 2016-10-28  Aldy Hernandez  <aldyh@redhat.com>
2184         PR debug/77773
2185         * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
2186         if NULL.
2188 2016-10-25  Jakub Jelinek  <jakub@redhat.com>
2190         * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
2191         * c-common.c (c_common_reswords): Add __builtin_launder.
2193 2016-10-24  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2195         * c-common.c (c_common_truthvalue_conversion): Warn for
2196         multiplications in boolean context.  Fix the quoting of '<<' and '<'
2197         in the shift warning.
2199 2016-10-20  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2201         * c-common.c (c_common_truthvalue_conversion): Fix the comment.
2203 2016-10-20  Jason Merrill  <jason@redhat.com>
2205         * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
2207 2016-10-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2209         * c-common.c (c_common_truthvalue_conversion): Warn only for signed
2210         integer shift ops in boolean context.
2212 2016-10-18  Aldy Hernandez  <aldyh@redhat.com>
2214         * c.opt (Walloca): New.
2215         (Walloca-larger-than=): New.
2216         (Wvla-larger-than=): New.
2218 2016-10-17  Marek Polacek  <polacek@redhat.com>
2220         * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
2221         Return immediately when finding a match.
2222         (warn_tautological_cmp): Remove a boolean variable that is no longer
2223         needed.
2225 2016-10-17  Marek Polacek  <polacek@redhat.com>
2227         * c-attribs.c: New file.
2228         * c-common.c: Move attributes handling to c-attribs.c.
2229         (get_nonnull_operand): No longer static.
2230         * c-common.h: Move the declarations from c-attribs.c to its own section.
2232 2016-10-14  Jason Merrill  <jason@redhat.com>
2234         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
2235         and __cpp_deduction_guides.
2237 2016-10-13  Jason Merrill  <jason@redhat.com>
2239         * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
2241 2016-10-13  Thomas Preud'homme  <thomas.preudhomme@arm.com>
2243         * c-cppbuiltin.c: Include memmodel.h.
2244         * c-opts.c: Likewise.
2245         * c-pragma.c: Likewise.
2246         * c-warn.c: Likewise.
2248 2016-10-12  Jakub Jelinek  <jakub@redhat.com>
2250         * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
2251         (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
2252         * c-opts.c (sanitize_cpp_opts): Initialize
2253         cpp_opts->cpp_warn_implicit_fallthrough.
2255 2016-10-11  Marek Polacek  <polacek@redhat.com>
2257         * c-common.c (warning_candidate_p): Change the return type to bool
2258         and return true/false instead of 1/0.
2259         (vector_mode_valid_p): Likewise.
2261 2016-10-11  Marek Polacek  <polacek@redhat.com>
2263         * c-common.c (fold_for_warn): No longer static.
2264         (bool_promoted_to_int_p): Likewise.
2265         (c_common_get_narrower): Likewise.
2266         (constant_expression_warning): Move to c-warn.c.
2267         (constant_expression_error): Likewise.
2268         (overflow_warning): Likewise.
2269         (warn_logical_operator): Likewise.
2270         (find_array_ref_with_const_idx_r): Likewise.
2271         (warn_tautological_cmp): Likewise.
2272         (expr_has_boolean_operands_p): Likewise.
2273         (warn_logical_not_parentheses): Likewise.
2274         (warn_if_unused_value): Likewise.
2275         (strict_aliasing_warning): Likewise.
2276         (sizeof_pointer_memaccess_warning): Likewise.
2277         (check_main_parameter_types): Likewise.
2278         (conversion_warning): Likewise.
2279         (warnings_for_convert_and_check): Likewise.
2280         (match_case_to_enum_1): Likewise.
2281         (match_case_to_enum): Likewise.
2282         (c_do_switch_warnings): Likewise.
2283         (warn_for_omitted_condop): Likewise.
2284         (readonly_error): Likewise.
2285         (lvalue_error): Likewise.
2286         (invalid_indirection_error): Likewise.
2287         (warn_array_subscript_with_type_char): Likewise.
2288         (warn_about_parentheses): Likewise.
2289         (warn_for_unused_label): Likewise.
2290         (warn_for_div_by_zero): Likewise.
2291         (warn_for_memset): Likewise.
2292         (warn_for_sign_compare): Likewise.
2293         (do_warn_double_promotion): Likewise.
2294         (do_warn_unused_parameter): Likewise.
2295         (record_locally_defined_typedef): Likewise.
2296         (maybe_record_typedef_use): Likewise.
2297         (maybe_warn_unused_local_typedefs): Likewise.
2298         (maybe_warn_bool_compare): Likewise.
2299         (maybe_warn_shift_overflow): Likewise.
2300         (warn_duplicated_cond_add_or_warn): Likewise.
2301         (diagnose_mismatched_attributes): Likewise.
2302         * c-common.h: Move the declarations from c-warn.c to its own section.
2303         * c-warn.c: New file.
2305 2016-10-08  Jason Merrill  <jason@redhat.com>
2307         * c-common.c (c_common_truthvalue_conversion): Don't distribute
2308         into COND_EXPR in C++.
2310 2016-10-08  Jakub Jelinek  <jakub@redhat.com>
2312         * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
2313         token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
2314         CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
2316 2016-10-07  Jakub Jelinek  <jakub@redhat.com>
2318         Implement LWG2296 helper intrinsic
2319         * c-common.h (enum rid): Add RID_ADDRESSOF.
2320         * c-common.c (c_common_reswords): Add __builtin_addressof.
2322 2016-10-07  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2324         PR c++/77700
2325         * c-common.c (c_common_truthvalue_conversion): Warn also for
2326         suspicious enum values in boolean context.
2328 2016-10-06  Jakub Jelinek  <jakub@redhat.com>
2330         Implement P0258R2 - helper for C++17
2331         std::has_unique_object_representations trait
2332         * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
2333         * c-common.c (c_common_reswords): Add
2334         __has_unique_object_representations.
2336 2016-10-05  Jakub Jelinek  <jakub@redhat.com>
2338         PR sanitizer/66343
2339         * c-ubsan.c (ubsan_instrument_return): Don't call
2340         initialize_sanitizer_builtins here.
2342 2016-10-05  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2344         * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
2345         conditional expression in boolean context when only one arm is
2346         non-boolean.
2348 2016-10-05  Jakub Jelinek  <jakub@redhat.com>
2350         PR sanitizer/77823
2351         * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
2352         is not integral.
2354         * c-common.c (c_common_reswords): Update comment for C++11.
2356 2016-10-04  Jason Merrill  <jason@redhat.com>
2358         * c-common.c (make_tree_vector_from_ctor): New.
2359         * c-common.h: Declare it.
2361 2016-10-04  Jakub Jelinek  <jakub@redhat.com>
2363         * c-cppbuiltin.c (c_cpp_builtins): Don't define
2364         __LIBGCC_JCR_SECTION_NAME__.
2366 2016-10-03  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2368         * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
2369         left shift in boolean context.
2371 2016-09-29  Jakub Jelinek  <jakub@redhat.com>
2373         Implement P0001R1 - C++17 removal of register storage class specifier
2374         * c.opt (Wregister): New warning.
2375         * c-opts.c (c_common_post_options): Enable -Wregister by
2376         default for C++17.
2378 2016-09-29  James Greenhalgh  <james.greenhalgh@arm.com>
2380         * c-opts.c (c_common_post_options): Remove special case for
2381         TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
2382         in C++.
2384 2016-09-27  Jakub Jelinek  <jakub@redhat.com>
2386         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
2387         -std=c++1z.
2389         * c-ada-spec.c (print_ada_declaration): Remove break after return.
2391 2016-09-26  Thomas Preud'homme  <thomas.preudhomme@arm.com>
2393         * c-common.c: Include memmodel.h.
2395 2016-09-26  Marek Polacek  <polacek@redhat.com>
2397         * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
2399 2016-09-26  Marek Polacek  <polacek@redhat.com>
2401         PR c/7652
2402         * c-common.c (c_common_attribute_table): Add fallthrough attribute.
2403         (handle_fallthrough_attribute): New function.
2404         (attribute_fallthrough_p): New function.
2405         * c-common.h (attribute_fallthrough_p): Declare.
2407 2016-09-24  Marek Polacek  <polacek@redhat.com>
2409         PR c/77490
2410         * c.opt (Wbool-operation): New.
2412 2016-09-21  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2414         * c-common.c (c_common_truthvalue_conversion): Inhibit
2415         Wint-in-bool-context warning with from_macro_definition_at.
2416         Mention the expression will always evaluate to true.
2418 2016-09-21  Martin Sebor  <msebor@redhat.com>
2420         PR bootstrap/77676
2421         * c.opt (fprintf-return-value): Temporarily initialize to zero
2422         to unblock bootstrap failures.
2424 2016-09-21  Jakub Jelinek  <jakub@redhat.com>
2426         PR c++/77651
2427         * c.opt (Waligned-new=): Add RejectNegative.
2428         (faligned-new=): Likewise.  Spelling fix - change
2429         aligned_new_threshhold to aligned_new_threshold.
2430         * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
2431         to aligned_new_threshold.
2433 2016-09-20  Martin Sebor  <msebor@redhat.com>
2435         PR middle-end/49905
2436         * c.opt: Add -Wformat-length and -fprintf-return-value.
2438 2016-09-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2440         PR c++/77434
2441         * c.opt (Wint-in-bool-context): New warning.
2442         * c-common.c (c_common_truthvalue_conversion): Warn on integer
2443         constants in boolean context.
2445 2016-09-19  Joseph Myers  <joseph@codesourcery.com>
2447         * c-common.c (max_align_t_align): Also consider alignment of
2448         float128_type_node.
2450 2016-09-15  Jason Merrill  <jason@redhat.com>
2452         * c-common.c (check_cxx_fundamental_alignment_constraints): Check
2453         DECL_EXTERNAL.
2455 2016-09-14  Jason Merrill  <jason@redhat.com>
2457         * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
2458         limit FIELD_DECL, either.
2460 2016-09-14  Marek Polacek  <polacek@redhat.com>
2462         * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
2463         * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
2464         * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
2466 2016-09-13  David Malcolm  <dmalcolm@redhat.com>
2468         * c-common.c (warn_logical_not_parentheses): Replace
2469         rich_location::add_fixit_insert calls with add_fixit_insert_before
2470         and add_fixit_insert_after, eliminating the "next_loc" calculation.
2472 2016-09-13  Jason Merrill  <jason@redhat.com>
2473             Tom de Vries  <tom@codesourcery.com>
2475         PR c++/77427
2476         * c-common.c (set_underlying_type): Don't treat array as builtin type.
2478 2016-09-13  Jason Merrill  <jason@redhat.com>
2480         * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
2481         limit types at all.
2483 2016-09-12  Jason Merrill  <jason@redhat.com>
2485         * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
2486         bit/byte confusion, allow large alignment for types.
2488 2016-09-12  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2490         PR c++/77496
2491         * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
2493 2016-09-12  David Malcolm  <dmalcolm@redhat.com>
2495         PR c/72858
2496         * c-format.c (argument_parser::check_argument_type): Add params
2497         "type_start" and "conversion_char".  Use the former to generate
2498         offset_to_type_start and pass it and conversion_char to
2499         check_format_types.
2500         (check_format_info_main): Capture the start of the type
2501         information as "type_start", and pass it an format_char
2502         to arg_parser.check_argument_type.
2503         (check_format_types): Provide an example in the leading comment.
2504         Add params "offset_to_type_start" and "conversion_char"; pass
2505         them to format_type_warning calls.
2506         (test_get_modifier_for_format_len): Likewise.
2507         (matching_type_p): New function.
2508         (get_format_for_type): Add param "conversion_char" and move
2509         implementation into...
2510         (get_format_for_type_1): ...new function, called twice.
2511         Use new function matching_type_p rather than checking for
2512         TYPE_CANONICAL equality.
2513         (get_corrected_substring): New function.
2514         (format_type_warning): Provide an example in the leading comment.
2515         Add params "offset_to_type_start" and "conversion_char".  Replace
2516         call to get_format_for_type with call to get_corrected_substring
2517         and move rejection of hints for widths/precisions there.
2518         (assert_format_for_type_streq): Add param "conversion_char".
2519         (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
2520         (test_get_format_for_type_printf): Add conversion chars to the
2521         tests, adding coverage for various combinations of integer
2522         vs double conversions, and for preserving octal and hexadecimal
2523         conversions.
2524         (test_get_format_for_type_scanf): Add conversion chars to the
2525         tests.
2527 2016-09-10  Tom de Vries  <tom@codesourcery.com>
2529         PR C/71602
2530         * c-common.c (build_va_arg): Handle more strict
2531         targetm.canonical_va_list_type.  Replace first argument type error with
2532         assert.
2534 2016-09-09  Martin Sebor  <msebor@redhat.com>
2536         PR c/77520
2537         PR c/77521
2538         * c-format.c (argument_parser::find_format_char_info): Use %qc
2539         format directive unconditionally.
2541 2016-09-09  Jason Merrill  <jason@redhat.com>
2543         Implement C++17 new of over-aligned types.
2544         * c.opt: Add -faligned-new and -Waligned-new.
2545         * c-common.c (max_align_t_align): Split out from...
2546         (cxx_fundamental_alignment_p): ...here.
2547         * c-common.h: Declare it.
2548         * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
2550 2016-09-09  Joseph Myers  <joseph@codesourcery.com>
2552         * c-cppbuiltin.c (builtin_define_type_width): New function.
2553         (builtin_define_stdint_macros, c_cpp_builtins): Define type width
2554         macros.
2556 2016-09-07  David Malcolm  <dmalcolm@redhat.com>
2558         * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
2559         a POINTER_TYPE.
2560         (substring_loc::get_location): Move to substring-locations.c,
2561         keeping implementation as...
2562         (c_get_substring_location): New function, from the above, reworked
2563         to use accessors rather than member lookup.
2564         * c-common.h (class substring_loc): Move to substring-locations.h,
2565         replacing with a forward decl.
2566         (c_get_substring_location): New decl.
2567         * c-format.c: Include "substring-locations.h".
2568         (format_warning_va): Move to substring-locations.c.
2569         (format_warning_at_substring): Likewise.
2571 2016-09-06 Martin Sebor  <msebor@redhat.com>
2573         PR c/77336
2574         * c-format.c (check_function_format): Avoid issuing warnings for
2575         functions unless they call format functions with non-constant
2576         format strings.
2578 2016-09-06  Richard Biener  <rguenther@suse.de>
2580         PR c/77450
2581         * c-common.c (c_common_mark_addressable_vec): Handle
2582         COMPOUND_LITERAL_EXPR.
2584 2016-09-05  Marek Polacek  <polacek@redhat.com>
2586         PR c/77423
2587         * c-common.c (bool_promoted_to_int_p): New function.
2588         (expr_has_boolean_operands_p): New function.
2589         (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
2590         (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
2592 2016-09-04  Tom de Vries  <tom@codesourcery.com>
2594         revert:
2595         2016-08-29  Tom de Vries  <tom@codesourcery.com>
2597         * c-common.c (build_va_arg): Replace first argument type error
2598         with assert.
2600 2016-09-02  Jakub Jelinek  <jakub@redhat.com>
2602         PR c/65467
2603         * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
2604         (c_finish_omp_for): Reject _Atomic qualified iterators.
2606 2016-09-01  Martin Sebor  <msebor@redhat.com>
2608         * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
2609         size to guarantee it fits the output of the formatted function
2610         regardless of its arguments.
2612 2016-09-01  Marek Polacek  <polacek@redhat.com>
2614         PR c/7652
2615         * c-common.c (resolve_overloaded_builtin): Fix formatting.  Add
2616         FALLTHRU comments.
2618 2016-08-29  Marek Polacek  <polacek@redhat.com>
2620         PR c/77292
2621         * c-common.c (warn_logical_not_parentheses): Don't warn for
2622         a comparison or a logical operator.
2624 2016-08-29  Tom de Vries  <tom@codesourcery.com>
2626         * c-common.c (build_va_arg): Fix type comparison assert.
2628 2016-08-29  Tom de Vries  <tom@codesourcery.com>
2630         * c-common.c (build_va_arg): Replace first argument type error
2631         with assert.
2633 2016-08-29  Tom de Vries  <tom@codesourcery.com>
2635         PR c/77398
2636         * c-common.c (build_va_arg): Add first argument error.  Build va_arg
2637         with error_mark_node as va_list instead of with illegal va_list.
2639 2016-08-25  Marek Polacek  <polacek@redhat.com>
2640             David Malcolm  <dmalcolm@redhat.com>
2642         * c-common.c (warn_logical_not_parentheses): Print fixit hints.
2643         * c-common.h (warn_logical_not_parentheses): Update declaration.
2645 2016-08-22  Marek Polacek  <polacek@redhat.com>
2647         PR c++/77321
2648         * c-common.c (warn_for_memset): Check type for null.
2650 2016-08-22  Joseph Myers  <joseph@codesourcery.com>
2652         * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
2653         _FloatNx types for suffixes for built-in functions.
2655 2016-08-19  Joseph Myers  <joseph@codesourcery.com>
2657         PR c/32187
2658         * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
2659         (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
2660         (RID_FLOAT128X): New enum rid values.
2661         (CASE_RID_FLOATN_NX): New macro.
2662         * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
2663         keywords.
2664         (c_common_type_for_mode): Check for _FloatN and _FloatNx and
2665         corresponding complex types.
2666         (c_common_nodes_and_builtins): For non-C++, register _FloatN and
2667         _FloatNx and corresponding complex types.
2668         (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
2669         * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
2670         and _FloatNx types for the widest type for determining
2671         DECIMAL_DIG.  Define __LDBL_DECIMAL_DIG__ as well as
2672         __DECIMAL_DIG__ for long double.  Handle FMA_SUFFIX being NULL.
2673         (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
2674         and _FloatNx types.
2675         * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
2676         constants.
2677         * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
2678         _FloatNx types.
2680 2016-08-18  David Malcolm  <dmalcolm@redhat.com>
2682         * c-opts.c (c_diagnostic_finalizer): Update for change to
2683         diagnostic_show_locus.
2685 2016-08-18  David Malcolm  <dmalcolm@redhat.com>
2687         * c-common.c: Include "spellcheck.h".
2688         (cb_get_suggestion): New function.
2689         * c-common.h (cb_get_suggestion): New decl.
2690         * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
2691         cb_get_suggestion.
2693 2016-08-18  Marek Polacek  <polacek@redhat.com>
2695         PR c/71514
2696         * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
2697         and pointer-to-VLA.
2699 2016-08-16  David Malcolm  <dmalcolm@redhat.com>
2701         PR c/72857
2702         * c-common.c (substring_loc::get_range): Rename to...
2703         (substring_loc::get_location): ...this, converting param from a
2704         source_range * to a location_t *.  Call
2705         get_source_location_for_substring rather than
2706         get_source_range_for_substring, and pass in m_caret_idx.
2707         * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
2708         (substring_loc::get_range): Replace with...
2709         (substring_loc::get_location): ...this.
2710         (substring_loc::set_caret_index): New method.
2711         (substring_loc): Add field m_caret_idx.
2712         * c-format.c (format_warning_va): Update for above changes.
2713         Rename local "substring_loc" to "fmt_substring_loc" to avoid
2714         clashing with type name.
2715         (format_warning_at_char): Add caret_idx param to substring_loc ctor.
2716         (check_argument_type): Likewise.
2717         (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
2718         Use a copy when emitting warnings, setting the caret index from TYPE.
2720 2016-08-16  Eric Botcazou  <ebotcazou@adacore.com>
2721             Arnaud Charlet  <charlet@adacore.com>
2723         * c-ada-spec.c (dump_number): New function.
2724         (handle_escape_character): Likewise.
2725         (print_ada_macros): Add handling of constant integers and strings.
2727 2016-08-12  Marek Polacek  <polacek@redhat.com>
2729         PR c/7652
2730         * c-common.c (scalar_to_vector): Adjust fall through comment.
2731         * c-opts.c (c_common_handle_option): Likewise.
2732         * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
2733         * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
2734         fall through comment.
2735         * cilk.c (extract_free_variables): Add FALLTHRU.
2737 2016-08-10  Jason Merrill  <jason@redhat.com>
2739         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
2741 2016-08-09  Jason Merrill  <jason@redhat.com>
2743         * c-common.c (c_common_attribute_table): vector_size affects type
2744         identity.
2746 2016-08-09  Marek Polacek  <polacek@redhat.com>
2748         PR c/7652
2749         * c-ada-spec.c (dump_generic_ada_node): Add return.
2751 2016-08-09  Jason Merrill  <jason@redhat.com>
2753         * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
2754         C++17 constexpr lambdas.
2756 2016-08-08  David Malcolm  <dmalcolm@redhat.com>
2758         PR c/64955
2759         * c-common.h (selftest::c_format_c_tests): New declaration.
2760         (selftest::run_c_tests): New declaration.
2761         * c-format.c: Include "selftest.h.
2762         (format_warning_va): Add param "corrected_substring" and use
2763         it to add a replacement fix-it hint.
2764         (format_warning_at_substring): Likewise.
2765         (format_warning_at_char): Update for new param of
2766         format_warning_va.
2767         (argument_parser::check_argument_type): Pass "fki" to
2768         check_format_types.
2769         (check_format_types): Add param "fki" and pass it to
2770         format_type_warning.
2771         (deref_n_times): New function.
2772         (get_modifier_for_format_len): New function.
2773         (selftest::test_get_modifier_for_format_len): New function.
2774         (get_format_for_type): New function.
2775         (format_type_warning): Add param "fki" and use it to attempt
2776         to provide hints for argument types when calling
2777         format_warning_at_substring.
2778         (selftest::get_info): New function.
2779         (selftest::assert_format_for_type_streq): New function.
2780         (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
2781         (selftest::test_get_format_for_type_printf): New function.
2782         (selftest::test_get_format_for_type_scanf): New function.
2783         (selftest::c_format_c_tests): New function.
2785 2016-08-08  David Malcolm  <dmalcolm@redhat.com>
2787         PR c/52952
2788         * c-format.c: Include "diagnostic.h".
2789         (location_column_from_byte_offset): Delete.
2790         (location_from_offset): Delete.
2791         (format_warning_va): New function.
2792         (format_warning_at_substring): New function.
2793         (format_warning_at_char): New function.
2794         (check_format_arg): Capture location of format_tree and pass to
2795         check_format_info_main.
2796         (argument_parser): Add fields "start_of_this_format" and
2797         "format_string_cst".
2798         (flag_chars_t::validate): Add param "format_string_cst".  Convert
2799         warning_at call using location_from_offset to call to
2800         format_warning_at_char.
2801         (argument_parser::argument_parser): Add param "format_string_cst_"
2802         and use use it to initialize field "format_string_cst".
2803         Initialize new field "start_of_this_format".
2804         (argument_parser::read_format_flags): Convert warning_at call
2805         using location_from_offset to a call to format_warning_at_char.
2806         (argument_parser::read_any_format_left_precision): Likewise.
2807         (argument_parser::read_any_format_precision): Likewise.
2808         (argument_parser::read_any_other_modifier): Likewise.
2809         (argument_parser::find_format_char_info): Likewise, in three places.
2810         (argument_parser::parse_any_scan_set): Likewise, in one place.
2811         (argument_parser::handle_conversions): Likewise, in two places.
2812         (argument_parser::check_argument_type): Add param "fmt_param_loc"
2813         and use it to make a substring_loc.  Pass the latter to
2814         check_format_types.
2815         (check_format_info_main): Add params "fmt_param_loc" and
2816         "format_string_cst".  Convert warning_at calls using
2817         location_from_offset to calls to format_warning_at_char.  Pass the
2818         new params to the arg_parser ctor.  Pass "format_string_cst" to
2819         flag_chars.validate.  Pass "fmt_param_loc" to
2820         arg_parser.check_argument_type.
2821         (check_format_types): Convert first param from a location_t
2822         to a const substring_loc & and rename to "fmt_loc".  Attempt
2823         to extract the range of the relevant parameter and pass it
2824         to format_type_warning.
2825         (format_type_warning): Convert first param from a location_t
2826         to a const substring_loc & and rename to "fmt_loc".  Add
2827         params "param_range" and "type".  Replace calls to warning_at
2828         with calls to format_warning_at_substring.
2830 2016-08-08  David Malcolm  <dmalcolm@redhat.com>
2832         * c-format.c (class flag_chars_t): New class.
2833         (struct length_modifier): New struct.
2834         (class argument_parser): New class.
2835         (flag_chars_t::flag_chars_t): New ctor.
2836         (flag_chars_t::has_char_p): New method.
2837         (flag_chars_t::add_char): New method.
2838         (flag_chars_t::validate): New method.
2839         (flag_chars_t::get_alloc_flag): New method.
2840         (flag_chars_t::assignment_suppression_p): New method.
2841         (argument_parser::argument_parser): New ctor.
2842         (argument_parser::read_any_dollar): New method.
2843         (argument_parser::read_format_flags): New method.
2844         (argument_parser::read_any_format_width): New method.
2845         (argument_parser::read_any_format_left_precision): New method.
2846         (argument_parser::read_any_format_precision): New method.
2847         (argument_parser::handle_alloc_chars): New method.
2848         (argument_parser::read_any_length_modifier): New method.
2849         (argument_parser::read_any_other_modifier): New method.
2850         (argument_parser::find_format_char_info): New method.
2851         (argument_parser::validate_flag_pairs): New method.
2852         (argument_parser::give_y2k_warnings): New method.
2853         (argument_parser::parse_any_scan_set): New method.
2854         (argument_parser::handle_conversions): New method.
2855         (argument_parser::check_argument_type): New method.
2856         (check_format_info_main): Introduce classes argument_parser
2857         and flag_chars_t, moving the code within the loop into methods
2858         of these classes.  Make various locals "const".
2860 2016-08-05  David Malcolm  <dmalcolm@redhat.com>
2862         * c-common.c: Include "substring-locations.h".
2863         (get_cpp_ttype_from_string_type): New function.
2864         (g_string_concat_db): New global.
2865         (substring_loc::get_range): New method.
2866         * c-common.h (g_string_concat_db): New declaration.
2867         (class substring_loc): New class.
2868         * c-lex.c (lex_string): When concatenating strings, capture the
2869         locations of all tokens using a new obstack, and record the
2870         concatenation locations within g_string_concat_db.
2871         * c-opts.c (c_common_init_options): Construct g_string_concat_db
2872         on the ggc-heap.
2874 2016-07-29  Marek Polacek  <polacek@redhat.com>
2876         PR c/71926
2877         * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
2878         parentheses warning.
2880         PR c/71574
2881         * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
2883 2016-07-28  Martin Liska  <mliska@suse.cz>
2885         PR gcov-profile/68025
2886         * c-common.c (handle_no_profile_instrument_function_attribute):
2888 2016-07-27  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2890         * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
2891         BITS_PER_UNIT_LOG.
2893 2016-07-25  Jason Merrill  <jason@redhat.com>
2895         PR c++/65970
2896         * c.opt (fconstexpr-loop-limit): New.
2898 2016-07-22  Martin Sebor  <msebor@redhat.com>
2900         PR c++/71675
2901         * c-common.c (resolve_overloaded_builtin): Avoid converting
2902         __atomic_compare_exchange_n return type to that of what its
2903         first argument points to.
2905 2016-07-22  Uros Bizjak  <ubizjak@gmail.com>
2907         * c-common.c: Use HOST_WIDE_INT_M1U instead of
2908         ~(unsigned HOST_WIDE_INT) 0.
2910 2016-07-22  Martin Liska  <mliska@suse.cz>
2912         PR gcov-profile/69028
2913         PR gcov-profile/62047
2914         * cilk.c (create_cilk_helper_decl): Set location of a new decl
2915         to the current_function_decl.
2917 2016-07-21  Jason Merrill  <jason@redhat.com>
2919         PR c++/65168
2920         * c-common.c (c_common_truthvalue_conversion): Check
2921         c_inhibit_evaluation_warnings for warning about address of
2922         reference.
2924 2016-07-20  David Malcolm  <dmalcolm@redhat.com>
2926         * c-common.h (lookup_name_fuzzy): Convert return type from tree to
2927         const char *.
2929 2016-07-15  Jason Merrill  <jason@redhat.com>
2931         * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
2933 2016-07-15  Jakub Jelinek  <jakub@redhat.com>
2935         PR c/71858
2936         * c-common.h (enum lookup_name_fuzzy_kind): Add
2937         FUZZY_LOOKUP_FUNCTION_NAME.
2939 2016-07-08  Jason Merrill  <jason@redhat.com>
2941         P0145: Refining Expression Order for C++.
2942         * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
2943         * c-opts.c: Adjust.
2945 2016-07-05  Markus Trippelsdorf  <markus@trippelsdorf.de>
2947         PR c++/71214
2948         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
2950 2016-06-29  Thomas Schwinge  <thomas@codesourcery.com>
2952         * c-pragma.h (enum pragma_kind): Rename
2953         PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE.  Adjust all
2954         users.
2956 2016-06-29  Richard Biener  <rguenther@suse.de>
2958         PR middle-end/71002
2959         * c-common.c (c_common_get_alias_set): Remove union type punning case.
2961 2016-06-24  Jason Merrill  <jason@redhat.com>
2963         P0145R2: Refining Expression Order for C++.
2964         * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
2965         MODIFY_EXPR.
2967 2016-06-24  Jakub Jelinek  <jakub@redhat.com>
2969         * c-common.c (check_builtin_function_arguments): Require last
2970         argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
2971         Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
2972         if the last argument is pointer to enumerated or boolean type.
2974 2016-06-22  David Malcolm  <dmalcolm@redhat.com>
2976         PR c/70339
2977         * c-common.h (enum lookup_name_fuzzy_kind): New enum.
2978         (lookup_name_fuzzy): New prototype.
2980 2016-06-21  John David Anglin  <danglin@gcc.gnu.org>
2982         * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
2984 2016-06-14  Jason Merrill  <jason@redhat.com>
2986         P0145R2: Refining Expression Order for C++.
2987         * c.opt (fargs-in-order): New.
2988         * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
2990 2016-06-13  Jakub Jelinek  <jakub@redhat.com>
2992         PR sanitizer/71498
2993         * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
2994         all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
2996         PR preprocessor/71183
2997         * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
2998         to cb_get_source_date_epoch.
3000 2016-06-10  Jakub Jelinek  <jakub@redhat.com>
3002         PR c/68657
3003         * c.opt (Wpsabi): Add Warning flag.
3005 2016-06-10  Martin Sebor  <msebor@redhat.com>
3007         PR c/71392
3008         * c-common.c (handle_nonnull_attribute): Accept
3009         the nonnull attribute in type-generic builtins.
3011 2016-06-09  Martin Sebor  <msebor@redhat.com>
3013         PR c/70883
3014         * c-common.c (builtin_function_validate_nargs): Make text of error
3015         message consistent with others like it.
3017 2016-06-08  Martin Sebor  <msebor@redhat.com>
3018             Jakub Jelinek  <jakub@redhat.com>
3020         PR c++/70507
3021         PR c/68120
3022         * c-common.c (check_builtin_function_arguments): Handle
3023         BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
3025 2016-06-08  Richard Biener  <rguenther@suse.de>
3027         * c-common.c (parse_optimize_options): Improve diagnostic messages.
3029 2016-06-07  Richard Biener  <rguenther@suse.de>
3031         PR c/61564
3032         * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
3033         options and warn about others.
3035 2016-06-01  Eduard Sanou  <dhole@openmailbox.org>
3037         * c-common.c (get_source_date_epoch): Rename to
3038         cb_get_source_date_epoch.
3039         * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
3040         message when the parsing fails.  Use error_at instead of fatal_error.
3041         * c-common.h (get_source_date_epoch): Rename to
3042         cb_get_source_date_epoch.
3043         * c-common.h (cb_get_source_date_epoch): Prototype.
3044         * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
3045         * c-common.h (c_omp_region_type): Remove trailing comma.
3046         * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
3047         * c-lex.c (c_lex_with_flags): Remove initialization of
3048         pfile->source_date_epoch.
3050 2016-05-30  Jakub Jelinek  <jakub@redhat.com>
3052         PR c++/71349
3053         * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
3054         C_OMP_CLAUSE_SPLIT_TARGET.  Put OMP_CLAUSE_NOWAIT to
3055         C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
3056         instead of C_OMP_CLAUSE_SPLIT_FOR.
3058 2016-05-24  Richard Biener  <rguenther@suse.de>
3060         PR middle-end/70434
3061         PR c/69504
3062         * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
3063         (convert_vector_to_array_for_subscript): ... this.
3064         * c-common.c (convert_vector_to_pointer_for_subscript): Use a
3065         VIEW_CONVERT_EXPR to an array type.  Rename to ...
3066         (convert_vector_to_array_for_subscript): ... this.
3068 2016-05-12  Marek Polacek  <polacek@redhat.com>
3070         PR c/70756
3071         * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
3072         size_in_bytes and pass LOC to it.
3074 2016-05-11  Mikhail Maltsev  <maltsevm@gmail.com>
3076         PR c/43651
3077         * c.opt (Wduplicate-decl-specifier): New option.
3079 2016-05-11  Marek Polacek  <polacek@redhat.com>
3081         PR c++/71024
3082         * c-common.c (diagnose_mismatched_attributes): New function.
3083         * c-common.h (diagnose_mismatched_attributes): Declare.
3085 2016-05-04  Marek Polacek  <polacek@redhat.com>
3087         * c.opt (Wdangling-else): New option.
3089 2016-05-03  Marek Polacek  <polacek@redhat.com>
3091         PR c/70859
3092         * c-common.c (builtin_function_validate_nargs): Add location
3093         parameter.  Use it.
3094         (check_builtin_function_arguments): Add location and arguments
3095         parameters.  Use them.
3096         * c-common.h (check_builtin_function_arguments): Update declaration.
3098 2016-05-03  Richard Biener  <rguenther@suse.de>
3100         * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
3101         allow call args to gimplify to SSA names.
3103 2016-05-03  Marek Polacek  <polacek@redhat.com>
3105         * c-common.h (enum c_omp_region_type): Remove stray comma.
3107 2016-05-02  Cesar Philippidis  <cesar@codesourcery.com>
3109         * c-common.h (enum c_omp_region_type): Define.
3111 2016-05-02  Richard Sandiford  <richard.sandiford@arm.com>
3113         * c-common.c (shorten_compare): Use wi::to_wide.
3115 2016-04-29  Cesar Philippidis  <cesar@codesourcery.com>
3117         PR middle-end/70626
3118         * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
3119         * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
3120         reduction clauses in acc parallel loops.
3122 2016-04-29  Marek Polacek  <polacek@redhat.com>
3124         PR c/70852
3125         * c-common.c (warn_for_memset): Check domain before accessing it.
3127 2016-04-29  Dominik Vogt  <vogt@linux.vnet.ibm.com>
3129         PR/69089
3130         * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
3131         "aligned" attribute.
3133 2016-04-28  Jason Merrill  <jason@redhat.com>
3135         * c-lex.c (c_common_has_attribute): Handle nodiscard.
3137 2016-04-28  Eduard Sanou  <dhole@openmailbox.org>
3138             Matthias Klose  <doko@debian.org>
3140         * c-common.c (get_source_date_epoch): New function, gets the environment
3141         variable SOURCE_DATE_EPOCH and parses it as long long with error
3142         handling.
3143         * c-common.h (get_source_date_epoch): Prototype.
3144         * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
3146 2015-04-27  Ryan Burn  <contact@rnburn.com>
3148         PR c++/69024
3149         PR c++/68997
3150         * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
3151         (cilk_recognize_spawn): Renamed from recognize_spawn and change to
3152         external linkage.
3153         (cilk_detect_and_unwrap): Corresponding changes.
3154         (extract_free_variables): Don't extract free variables from
3155         AGGR_INIT_EXPR slot.
3156         * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
3157         (cilk_recognize_spawn): Likewise.
3159 2016-04-27  Bernd Schmidt  <bschmidt@redhat.com>
3161         * c.opt (Wmemset-elt-size): New option.
3162         * c-common.c (warn_for_memset): New function.
3163         * c-common.h (warn_for_memset): Declare.
3165 2016-04-25  Jason Merrill  <jason@redhat.com>
3167         * c-common.c (handle_unused_attribute): Accept CONST_DECL.
3168         No longer static.
3169         * c-common.h: Declare it.
3170         * c-lex.c (c_common_has_attribute): Add maybe_unused.
3172 2016-04-22  Jason Merrill  <jason@redhat.com>
3174         * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
3176 2016-04-20  Ilya Verbin  <ilya.verbin@intel.com>
3178         PR c++/69363
3179         * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
3180         * c-common.h (c_finish_cilk_clauses): Remove declaration.
3182 2016-04-18  Michael Matz  <matz@suse.de>
3184         * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
3185         and SET_DECL_ALIGN.
3187 2016-04-17  Eric Botcazou  <ebotcazou@adacore.com>
3189         * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
3190         (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
3191         to incomplete types.
3192         (dump_nested_type): Remove redundant tests and tidy up.
3193         (print_ada_declaration): Also set TREE_VISITED on the declaration of
3194         a type which is the typedef of an original type.
3196 2016-04-15  Marek Polacek  <polacek@redhat.com>
3198         PR c/70651
3199         * c-common.c (build_va_arg): Change two asserts into errors and return
3200         error_mark_node.
3202 2016-04-13  Marek Polacek  <polacek@redhat.com>
3204         PR c++/70639
3205         * c-indentation.c (should_warn_for_misleading_indentation): Bail out
3206         for switch statements, too.
3208 2016-03-28  Jason Merrill  <jason@redhat.com>
3210         * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
3212 2016-03-23  Marek Polacek  <polacek@redhat.com>
3214         PR c++/69884
3215         * c.opt (Wignored-attributes): New option.
3217 2016-03-22  David Malcolm  <dmalcolm@redhat.com>
3219         PR c/69993
3220         * c-indentation.c (warn_for_misleading_indentation): Rewrite the
3221         diagnostic text, reversing the order of the warning and note so
3222         that they appear in source order.
3224 2016-03-17  Marek Polacek  <polacek@redhat.com>
3226         PR c/69407
3227         * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
3228         operations.
3230 2016-03-14  Jason Merrill  <jason@redhat.com>
3232         * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
3234         * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
3236 2016-03-09  Richard Biener  <rguenther@suse.de>
3238         PR c/70143
3239         * c-common.c (strict_aliasing_warning): Add back
3240         alias_sets_conflict_p check.
3242 2016-03-08  Jason Merrill  <jason@redhat.com>
3244         * c-opts.c (set_std_cxx1z): Don't enable concepts.
3246 2016-03-04  David Malcolm  <dmalcolm@redhat.com>
3248         PR c/68187
3249         * c-indentation.c (get_visual_column): Move code to determine next
3250         tab stop to...
3251         (next_tab_stop): ...this new function.
3252         (line_contains_hash_if): Delete function.
3253         (detect_preprocessor_logic): Delete function.
3254         (get_first_nws_vis_column): New function.
3255         (detect_intervening_unindent): New function.
3256         (should_warn_for_misleading_indentation): Replace call to
3257         detect_preprocessor_logic with a call to
3258         detect_intervening_unindent.
3260 2016-03-04  David Malcolm  <dmalcolm@redhat.com>
3262         PR c/68187
3263         * c-indentation.c (should_warn_for_misleading_indentation): When
3264         suppressing warnings about cases where the guard and body are on
3265         the same column, only use the first non-whitespace column in place
3266         of the guard token column when dealing with "else" clauses.
3267         When rejecting aligned BODY and NEXT, loosen the requirement
3268         from equality with the first non-whitespace of guard to simply
3269         that they not be indented relative to it.
3271 2016-03-04  Richard Biener  <rguenther@suse.de>
3273         PR c++/70054
3274         * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
3275         instead of alias_sets_conflict_p.
3277 2016-03-01  Marek Polacek  <polacek@redhat.com>
3279         PR c++/69795
3280         * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
3281         any DECL.
3283 2016-02-22  Martin Sebor  <msebor@redhat.com>
3285         PR middle-end/69780
3286         * c-common.c (check_builtin_function_arguments): Validate and
3287         reject invalid arguments to __builtin_alloca_with_align.
3289 2016-02-20  Mark Wielaard  <mjw@redhat.com>
3291         PR c/28901
3292         * c.opt (Wunused-const-variable): Turn into Alias for...
3293         (Wunused-const-variable=): New option.
3295 2016-02-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>
3297         PR c++/69865
3298         * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
3299         here...
3300         (c_common_init_options): ...to here.
3301         (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
3303 2016-02-19  Jakub Jelinek  <jakub@redhat.com>
3305         PR c++/69826
3306         * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
3307         (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
3308         flag_preprocess_only.
3310 2016-02-16  Jakub Jelinek  <jakub@redhat.com>
3312         PR c/69835
3313         * c.opt (Wnonnull-compare): Enable for -Wall.
3315 2016-02-15  Jakub Jelinek  <jakub@redhat.com>
3317         PR c++/69797
3318         * c-common.c (sync_resolve_size): Diagnose too few arguments
3319         even when params is non-NULL empty vector.
3321 2016-02-08  Bernd Schmidt  <bschmidt@redhat.com>
3323         PR target/60410
3324         * c.opt (fshort-double): Remove.
3326 2016-02-05  Martin Sebor  <msebor@redhat.com>
3328         PR c++/69662
3329         * c.opt (Warning options): Update -Wplacement-new to take
3330         an optional argument.
3332 2016-02-01  Jakub Jelinek  <jakub@redhat.com>
3334         PR preprocessor/69543
3335         PR c/69558
3336         * c-pragma.c (handle_pragma_diagnostic): Pass input_location
3337         instead of loc to control_warning_option.
3339 2016-02-01  Nathan Sidwell  <nathan@codesourcery.com>
3341         * c.opt (fopenacc-dim=): New option.
3343 2016-01-27  Ryan Burn  <contact@rnburn.com>
3345         PR cilkplus/69267
3346         * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
3347         gimplify_arg. Removed superfluous post_p argument.
3348         * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
3349         superfluous post_p argument.
3350         * c-gimplify.c (c_gimplify_expr): Likewise.
3352 2016-01-26  David Malcolm  <dmalcolm@redhat.com>
3354         PR other/69006
3355         * c-opts.c (c_diagnostic_finalizer): Replace invocation of
3356         pp_newline_and_flush with pp_flush.
3358 2016-01-20  Martin Sebor  <msebor@redhat.com>
3360         PR c/69405
3361         * c-common.c (sync_resolve_size): Avoid printing diagnostic about
3362         an incompatible argument when the argument isn't a valid tree node.
3364 2016-01-18  Jason Merrill  <jason@redhat.com>
3366         PR c++/68767
3367         * c-common.c (check_function_arguments_recurse): Fold the whole
3368         COND_EXPR, not just the condition.
3370 2016-01-18  Tom de Vries  <tom@codesourcery.com>
3372         * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
3373         classify as loop clause.
3375 2016-01-15  Jakub Jelinek  <jakub@redhat.com>
3377         PR bootstrap/68271
3378         * c-pragma.c (c_register_pragma_1): Adjust comment to note that
3379         C++ FE no longer has limit on number of pragmas.
3381 2015-01-14  Ryan Burn  <contact@rnburn.com>
3383         PR c++/69048
3384         * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
3385         to add missing cleanup point.
3387 2016-01-14  David Malcolm  <dmalcolm@redhat.com>
3389         PR c++/68819
3390         * c-indentation.c (get_visual_column): Add location_t param.
3391         Handle the column number being zero by effectively disabling the
3392         warning, with an "inform".
3393         (should_warn_for_misleading_indentation): Add location_t argument
3394         for all uses of get_visual_column.
3396 2016-01-10  Patrick Palka  <ppalka@gcc.gnu.org>
3398         PR c++/69029
3399         * c-indentation.c (should_warn_for_misleading_indentation):
3400         Don't warn about do-while statements.
3402 2016-01-07  Martin Sebor  <msebor@redhat.com>
3404         PR c/68966
3405         * c-common.c (sync_resolve_size): Reject first argument when it's
3406         a pointer to _Bool.
3408 2016-01-05  David Malcolm  <dmalcolm@redhat.com>
3410         PR c/69122
3411         * c-indentation.c (get_visual_column): Remove default argument.
3412         (should_warn_for_misleading_indentation): For the multiline case,
3413         update call to get_visual_column for next_stmt_exploc so that it
3414         captures the location of the first non-whitespace character in the
3415         relevant line.  Don't issue warnings if there is non-whitespace
3416         before the next statement.
3418 2016-01-04  Jakub Jelinek  <jakub@redhat.com>
3420         Update copyright years.
3422 2015-12-21  David Malcolm  <dmalcolm@redhat.com>
3424         * c-common.c (binary_op_error): Convert first param from
3425         location_t to rich_location * and use it when emitting an error.
3426         * c-common.h (binary_op_error): Convert first param from
3427         location_t to rich_location *.
3429 2015-12-16  David Malcolm  <dmalcolm@redhat.com>
3431         * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
3432         * c-lex.c (conflict_marker_get_final_tok_kind): New function.
3434 2015-12-15  Ilya Verbin  <ilya.verbin@intel.com>
3436         * c-common.c (c_common_attribute_table): Handle "omp declare target
3437         link" attribute.
3439 2015-12-14  Jakub Jelinek  <jakub@redhat.com>
3441         PR c/68833
3442         * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
3444 2014-12-12  Tobias Burnus  <burnus@net-b.de>
3446         PR fortran/68815
3447         * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
3448         specifiers (%d, %i,%u and %c).
3450 2015-12-10  David Malcolm  <dmalcolm@redhat.com>
3452         * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
3454 2015-12-08  Jakub Jelinek  <jakub@redhat.com>
3456         PR c/48088
3457         PR c/68657
3458         * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
3459         * c-pragma.c (handle_pragma_diagnostic): Adjust
3460         control_warning_option caller.
3462 2015-12-07  David Malcolm  <dmalcolm@redhat.com>
3464         * c-common.c (c_cpp_error): Update for change to
3465         rich_location::set_range.
3467 2015-12-04  Paolo Bonzini  <bonzini@gnu.org>
3469         * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
3470         shifting 1 out of the sign bit.
3472 2015-12-04  Kirill Yukhin  <kirill.yukhin@intel.com>
3474         * c-common.c (c_common_attribute_table[]): Update max arguments
3475         count for "simd" attribute.
3476         (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
3478 2015-12-03  Jakub Jelinek  <jakub@redhat.com>
3480         PR preprocessor/57580
3481         * c-ppoutput.c (print): Change printed field to bool.
3482         Move src_file last for smaller padding.
3483         (init_pp_output): Set print.printed to false instead of 0.
3484         (scan_translation_unit): Fix up formatting.  Set print.printed
3485         to true after printing something other than newline.
3486         (scan_translation_unit_trad): Set print.printed to true instead of 1.
3487         (maybe_print_line_1): Set print.printed to false instead of 0.
3488         (print_line_1): Likewise.
3489         (do_line_change): Set print.printed to true instead of 1.
3490         (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
3491         dump_macro): Set print.printed to false after printing newline.
3493 2015-12-02  Jason Merrill  <jason@redhat.com>
3495         * c-common.c (fold_for_warn): New.
3496         (warn_logical_operator, warn_tautological_cmp)
3497         (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
3499         * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
3500         (c_fully_fold_internal, decl_constant_value_for_optimization):
3501         Move to c/c-fold.c.
3502         * c-common.h: Don't declare decl_constant_value_for_optimization.
3504 2015-12-02  Joseph Myers  <joseph@codesourcery.com>
3506         PR c/68162
3507         * c-common.h (c_build_qualified_type): Add extra default
3508         arguments.
3510 2015-12-01  Julian Brown  <julian@codesourcery.com>
3511             Cesar Philippidis  <cesar@codesourcery.com>
3512             James Norris  <James_Norris@mentor.com>
3514         * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
3515         * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
3516         (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
3518 2015-11-30  Eric Botcazou  <ebotcazou@adacore.com>
3520         * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
3521         (decl_sloc_common): Delete and move bulk of processing to...
3522         (decl_sloc): ...here.
3523         (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
3524         (dump_ada_double_name): Remove S parameter and compute the suffix.
3525         (dump_ada_array_type): Add PARENT parameter.  Simplify computation of
3526         element type and deal with an anonymous one.
3527         (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
3528         (dump_generic_ada_node): Tweak.  Adjust call to dump_ada_array_type
3529         and remove reference to QUAL_UNION_TYPE.
3530         (dump_nested_types): Make 2 passes on the fields and move bulk to...
3531         (dump_nested_type): ...here.  New function extracted from above.
3532         Generate a full declaration for anonymous element type of arrays.
3533         (print_ada_declaration): Really skip anonymous declarations.  Remove
3534         references to QUAL_UNION_TYPE.  Adjust call to dump_ada_array_type.
3535         Clean up processing of declarations of array types and objects.
3536         (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
3537         Remove obsolete code and tidy up.
3539 2015-11-29  Jan Hubicka  <hubicka@ucw.cz>
3541         PR c/67581
3542         * c-common.c (handle_transparent_union_attribute): Update
3543         also type variants.
3545 2015-11-27  Martin Liska  <mliska@suse.cz>
3547         PR c++/68312
3548         * array-notation-common.c (cilkplus_extract_an_triplets):
3549         Release vector of vectors.
3550         * cilk.c (gimplify_cilk_spawn): Free allocated memory.
3552 2015-11-26  Eric Botcazou  <ebotcazou@adacore.com>
3554         PR c++/68527
3555         * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
3556         (print_ada_struct_decl): Likewise.
3558 2015-11-23  Igor Zamyatin  <igor.zamyatin@intel.com>
3560         PR c++/68001
3561         * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
3562         * cilk.c (recognize_spawn): Determine location in a more precise
3563         way.
3565 2015-11-19  Jason Merrill  <jason@redhat.com>
3567         * c-common.c (shorten_compare): But look through macros from
3568         system headers.
3570 2015-11-18  Jason Merrill  <jason@redhat.com>
3572         * c-common.c (shorten_compare): Don't -Wtype-limits if the
3573         non-constant operand comes from a macro.
3575 2015-11-17  Jason Merrill  <jason@redhat.com>
3577         PR bootstrap/68346
3578         * c-common.c (warn_tautological_cmp): Fold before checking for
3579         constants.
3581 2015-11-16  Marek Polacek  <polacek@redhat.com>
3583         PR c++/68362
3584         * c-common.c (check_case_bounds): Fold low and high cases.
3586 2015-11-16  Marek Polacek  <polacek@redhat.com>
3588         * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
3589         * c-common.c (c_common_get_alias_set): Likewise.
3590         (handle_visibility_attribute): Likewise.
3592 2015-11-16  Kirill Yukhin  <kirill.yukhin@intel.com>
3594         * c-common.c (handle_simd_attribute): New.
3595         (struct attribute_spec): Add entry for "simd".
3596         (handle_simd_attribute): New.
3598 2015-11-13  Kai Tietz  <ktietz70@googlemail.com>
3600         * c-lex.c (interpret_float): Use fold_convert.
3602 2015-11-13  David Malcolm  <dmalcolm@redhat.com>
3604         * c-common.c (c_fully_fold_internal): Capture existing souce_range,
3605         and store it on the result.
3606         * c-opts.c (c_common_init_options): Set
3607         global_dc->colorize_source_p.
3609 2015-11-12  James Norris  <jnorris@codesourcery.com>
3610             Joseph Myers  <joseph@codesourcery.com>
3612         * c-pragma.c (oacc_pragmas): Add entry for declare directive.
3613         * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
3614         (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
3615         PRAGMA_OACC_CLAUSE_LINK.
3617 2015-11-11  Marek Polacek  <polacek@redhat.com>
3619         PR c/68107
3620         PR c++/68266
3621         * c-common.c (valid_array_size_p): New function.
3622         * c-common.h (valid_array_size_p): Declare.
3624 2015-11-11  Dominique d'Humieres  <dominiq@lps.ens.fr>
3626         PR bootstrap/68271
3627         * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
3629 2015-11-11  Andrew MacLeod  <amacleod@redhat.com>
3631         * array-notation-common.c: Remove unused header files.
3632         * c-ada-spec.c: Likewise.
3633         * c-cilkplus.c: Likewise.
3634         * c-common.c: Likewise.
3635         * c-cppbuiltin.c: Likewise.
3636         * c-dump.c: Likewise.
3637         * c-format.c: Likewise.
3638         * c-gimplify.c: Likewise.
3639         * c-indentation.c: Likewise.
3640         * c-lex.c: Likewise.
3641         * c-omp.c: Likewise.
3642         * c-opts.c: Likewise.
3643         * c-pch.c: Likewise.
3644         * c-ppoutput.c: Likewise.
3645         * c-pragma.c: Likewise.
3646         * c-pretty-print.c: Likewise.
3647         * c-semantics.c: Likewise.
3648         * c-ubsan.c: Likewise.
3649         * cilk.c: Likewise.
3650         * stub-objc.c: Likewise.
3652 2015-11-09  Thomas Schwinge  <thomas@codesourcery.com>
3653             Cesar Philippidis  <cesar@codesourcery.com>
3654             James Norris  <jnorris@codesourcery.com>
3655             Julian Brown  <julian@codesourcery.com>
3656             Nathan Sidwell  <nathan@codesourcery.com>
3658         * c-pragma.c (oacc_pragmas): Add "routine".
3659         * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
3661 2015-11-08  Eric Botcazou  <ebotcazou@adacore.com>
3663         * c-common.c (c_common_attributes): Add scalar_storage_order.
3664         (handle_scalar_storage_order_attribute): New function.
3665         * c-pragma.c (global_sso): New variable.
3666         (maybe_apply_pragma_scalar_storage_order): New function.
3667         (handle_pragma_scalar_storage_order): Likewise.
3668         (init_pragma): Register scalar_storage_order.
3669         * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
3670         * c.opt (Wscalar-storage-order): New warning.
3671         (fsso-struct=): New option.
3673 2015-11-08  Martin Sebor  <msebor@redhat.com>
3675         * c.opt (Wplacement-new): Add a period to the end of a sentence.
3677 2015-11-07  Richard Sandiford  <richard.sandiford@arm.com>
3679         * c-common.c: Don't undef DEF_BUILTIN.
3681 2015-11-06  David Malcolm  <dmalcolm@redhat.com>
3683         * c-common.c (c_cpp_error): Convert parameter from location_t to
3684         rich_location *.  Eliminate the "column_override" parameter and
3685         the call to diagnostic_override_column.
3686         Update the "done_lexing" clause to set range 0
3687         on the rich_location, rather than overwriting a location_t.
3688         * c-common.h (c_cpp_error): Convert parameter from location_t to
3689         rich_location *.  Eliminate the "column_override" parameter.
3691 2015-11-05  Cesar Philippidis  <cesar@codesourcery.com>
3692             Thomas Schwinge  <thomas@codesourcery.com>
3693             James Norris  <jnorris@codesourcery.com>
3695         * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
3696         AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses.  Associate REDUCTION
3697         clauses with parallel and kernels and loops.
3698         * c-pragma.h (enum pragma_omp_clause): Add entries for
3699         PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
3700         * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
3701         NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
3702         INDEPENDENT,SEQ}.
3703         (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
3705 2015-11-05  Martin Sebor  <msebor@redhat.com>
3707         PR c++/67942
3708         * c.opt (-Wplacement-new): New option.
3710 2015-11-05  Jakub Jelinek  <jakub@redhat.com>
3712         * c-common.h (c_finish_omp_atomic): Add TEST argument.
3713         (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
3714         * c-omp.c (c_finish_omp_atomic): Add TEST argument.  Don't call
3715         save_expr or create_tmp_var* if TEST is true.
3716         (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
3717         Don't call add_stmt here.
3718         (struct c_omp_check_loop_iv_data): New type.
3719         (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
3720         c_omp_check_loop_iv_exprs): New functions.
3721         (c_omp_split_clauses): Adjust for lastprivate being allowed on
3722         distribute.
3723         (c_omp_declare_simd_clauses_to_numbers): Change
3724         OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
3725         (c_omp_declare_simd_clauses_to_decls): Similarly change those
3726         from numbers to PARM_DECLs.
3728 2015-11-04  Mikhail Maltsev  <maltsevm@gmail.com>
3730         * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
3731         flag_checking.
3733 2015-11-03  Bernd Schmidt  <bschmidt@redhat.com>
3735         PR c++-common/67882
3736         * c-common.h (fold_offsetof_1): Add argument.
3737         * c-common.c (fold_offsetof_1): Diagnose more invalid
3738         offsetof expressions that reference elements past the end of
3739         an array.
3741 2015-11-03  Thomas Schwinge  <thomas@codesourcery.com>
3742             Chung-Lin Tang  <cltang@codesourcery.com>
3744         * c-pragma.c (oacc_pragmas): Add "atomic".
3745         * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
3747 2015-10-30  Evgeny Stupachenko  <evstupac@gmail.com>
3749         * c-common.c (handle_target_clones_attribute): New.
3750         (c_common_attribute_table): Add handle_target_clones_attribute.
3751         (handle_always_inline_attribute): Add check on target_clones attribute.
3752         (handle_target_attribute): Ditto.
3754 2015-10-29  Andrew MacLeod  <amacleod@redhat.com>
3756         * array-notation-common.c: Reorder #include's and remove duplicates.
3757         * c-ada-spec.c: Likewise.
3758         * c-cilkplus.c: Likewise.
3759         * c-common.c: Likewise.
3760         * c-cppbuiltin.c: Likewise.
3761         * c-dump.c: Likewise.
3762         * c-format.c: Likewise.
3763         * c-gimplify.c: Likewise.
3764         * c-indentation.c: Likewise.
3765         * c-lex.c: Likewise.
3766         * c-omp.c: Likewise.
3767         * c-opts.c: Likewise.
3768         * c-pch.c: Likewise.
3769         * c-ppoutput.c: Likewise.
3770         * c-pragma.c: Likewise.
3771         * c-pretty-print.c: Likewise.
3772         * c-semantics.c: Likewise.
3773         * c-ubsan.c: Likewise.
3774         * cilk.c: Likewise.
3775         * stub-objc.c: Likewise.
3777 2015-10-28  Jason Merrill  <jason@redhat.com>
3779         * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
3781 2015-10-27  Thomas Schwinge  <thomas@codesourcery.com>
3782             James Norris  <jnorris@codesourcery.com>
3783             Cesar Philippidis  <cesar@codesourcery.com>
3785         PR c/64765
3786         PR c/64880
3787         * c-common.h (c_oacc_split_loop_clauses): Declare function.
3788         * c-omp.c (c_oacc_split_loop_clauses): New function.
3790 2015-10-21  Martin Sebor  <msebor@redhat.com>
3792         PR driver/68043
3793         * c.opt: End each sentence that describes an option with a period.
3795 2015-10-20  Marek Polacek  <polacek@redhat.com>
3797         * array-notation-common.c (is_cilkplus_vector_p): Define.
3798         * c-common.h (is_cilkplus_vector_p): Declare.
3800 2015-10-20  Marek Polacek  <polacek@redhat.com>
3802         * c.opt (std=gnu++11): Do not describe as experimental.
3803         (std=gnu++14): Likewise.
3805 2015-10-19  Jason Merrill  <jason@redhat.com>
3807         * c-cppbuiltin.c (c_cpp_builtins): Define
3808         __cpp_nontype_template_args.
3810 2015-10-19  Jason Merrill  <jason@redhat.com>
3812         * c-cppbuiltin.c (c_cpp_builtins): Define
3813         __cpp_enumerator_attributes, __cpp_fold_expressions,
3814         __cpp_unicode_characters.
3816 2015-10-13  Jakub Jelinek  <jakub@redhat.com>
3817             Aldy Hernandez  <aldyh@redhat.com>
3819         * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
3820         DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
3821         (c_define_builtins): Likewise.
3822         * c-common.h (enum c_omp_clause_split): Add
3823         C_OMP_CLAUSE_SPLIT_TASKLOOP.
3824         (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
3825         (c_finish_omp_for): Add ORIG_DECLV argument.
3826         * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
3827         201511 instead of 201307.
3828         * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
3829         OMP_CRITICAL_CLAUSES to it.
3830         (c_finish_omp_ordered): Add CLAUSES argument, set
3831         OMP_ORDERED_CLAUSES to it.
3832         (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
3833         to it if OMP_FOR.  Clear DECL_INITIAL on the IVs.
3834         (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
3835         constructs and new OpenMP 4.5 clauses.  Clear
3836         OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD.  Add
3837         verification code.
3838         * c-pragma.c (omp_pragmas_simd): Add taskloop.
3839         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
3840         (enum pragma_omp_clause): Add
3841         PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
3842         and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
3844 2015-10-05  Richard Sandiford  <richard.sandiford@arm.com>
3846         * c-lex.c (interpret_float): Use real_equal instead of
3847         REAL_VALUES_EQUAL.
3849 2015-10-04  Jason Merrill  <jason@redhat.com>
3851         Implement N4514, C++ Extensions for Transactional Memory.
3852         * c-common.c (c_common_reswords): Add C++ TM TS keywords.
3853         (c_common_attribute_table): Add transaction_safe_dynamic.
3854         transaction_safe now affects type identity.
3855         (handle_tm_attribute): Handle transaction_safe_dynamic.
3856         * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
3857         RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
3858         (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
3859         (D_TRANSMEM): New.
3860         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
3861         * c-pretty-print.c (pp_c_attributes_display): Don't print
3862         transaction_safe in C++.
3864 2015-10-02  Marek Polacek  <polacek@redhat.com>
3866         * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
3868 2015-10-02  Marek Polacek  <polacek@redhat.com>
3870         PR c/64249
3871         * c-common.c (warn_duplicated_cond_add_or_warn): New function.
3872         * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
3873         * c.opt (Wduplicated-cond): New option.
3875 2015-10-01  Joseph Myers  <joseph@codesourcery.com>
3877         * c.opt (std=c11): Do not describe as experimental.
3878         (std=gnu11): Likewise.
3879         (std=iso9899:2011): Likewise.
3881 2015-09-28  Nathan Sidwell  <nathan@codesourcery.com>
3883         * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
3884         (DEF_FUNCTION_TYPE_VAR_11): Delete.
3886 2015-09-25  Marek Polacek  <polacek@redhat.com>
3888         * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
3889         (ubsan_instrument_shift): Likewise.
3891 2015-09-25  Marek Polacek  <polacek@redhat.com>
3893         PR sanitizer/64906
3894         * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
3896 2015-09-24  Patrick Palka  <ppalka@gcc.gnu.org>
3898         * c-indentation.c (should_warn_for_misleading_indentation):
3899         Compare next_stmt_vis_column with guard_line_first_nws instead
3900         of with guard_line_vis_column.
3902 2015-09-23  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3904         PR c/49654
3905         PR c/49655
3906         * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
3907         options and options not valid for the current language.
3909 2015-09-22  Patrick Palka  <ppalka@gcc.gnu.org>
3911         * c-indentation.c (should_warn_for_misleading_indentation):
3912         Float out and consolidate the calls to get_visual_column that
3913         are passed guard_exploc as an argument.  Compare
3914         next_stmt_vis_column with guard_line_first_nws instead of with
3915         body_line_first_nws.
3917 2015-09-22  Nathan Sidwell  <nathan@codesourcery.com>
3919         * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
3920         Wnamespaces): New C++ warnings.
3922 2015-09-22  Jason Merrill  <jason@redhat.com>
3924         * c-common.h (abi_compat_version_crosses): New.
3925         (warn_abi_version): Declare.
3926         * c-common.c: Define it.
3927         * c-opts.c (c_common_post_options): Handle it.
3928         flag_abi_compat_version defaults to 8.
3930 2015-09-21  Ville Voutilainen  <ville.voutilainen@gmail.com>
3932         Complete the implementation of N4230, Nested namespace definition.
3933         * c-cppbuiltin.c: Add __cpp_namespace_attributes and
3934         __cpp_nested_namespace_definitions.
3936 2015-09-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3938         * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
3940 2015-09-18  Manuel López-Ibáñez  <manu@gcc.gnu.org>
3942         * c-pragma.c (handle_pragma_diagnostic): Use explicit location
3943         when warning.
3944         * c-pragma.h (pragma_lex): Add optional loc argument.
3946 2015-09-16  Mikhail Maltsev  <maltsevm@gmail.com>
3948         * c-format.c (check_format_arg): Adjust to use common block size in all
3949         object pools.
3951 2015-09-15  David Malcolm  <dmalcolm@redhat.com>
3953         * c-format.c (location_from_offset): Update for change in
3954         signature of location_get_source_line.
3955         * c-indentation.c (get_visual_column): Likewise.
3956         (line_contains_hash_if): Likewise.
3958 2015-09-14  Marek Polacek  <polacek@redhat.com>
3960         * c-opts.c (c_common_post_options): Set C++ standard earlier, before
3961         setting various warnings.
3963 2015-09-14  Marek Polacek  <polacek@redhat.com>
3965         * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
3966         a negative value.
3968 2015-09-11  Mark Wielaard  <mjw@redhat.com>
3970         PR c/28901
3971         * c.opt (Wunused-variable): Option from common.opt.
3972         (Wunused-const-variable): New option.
3974 2015-09-09  Paolo Carlini  <paolo.carlini@oracle.com>
3976         PR c++/53184
3977         * c.opt ([Wsubobject-linkage]): Add.
3979 2015-09-03  Martin Sebor  <msebor@redhat.com>
3981         PR c/66516
3982         * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
3983         functions.
3984         * c-common.c (reject_gcc_builtin): Define.
3986 2015-09-02  Balaji V. Iyer  <balaji.v.iyer@intel.com>
3988         PR middle-end/60586
3989         * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
3990         prototype.
3991         * c-gimplify.c (c_gimplify_expr): Added a call to the function
3992         cilk_gimplify_call_params_in_spawned_fn.
3993         * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
3994         (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
3995         unwrapping.
3997 2015-08-25  Marek Polacek  <polacek@redhat.com>
3999         PR middle-end/67330
4000         * c-common.c (handle_weak_attribute): Don't check whether the
4001         visibility can be changed here.
4003 2015-08-22  Manuel López-Ibáñez  <manu@gcc.gnu.org>
4005         * c-lex.c (c_lex_with_flags): Use explicit locations.
4007 2015-08-18  Trevor Saunders  <tbsaunde@tbsaunde.org>
4009         * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
4010         c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
4012 2015-08-18  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
4014         PR middle-end/36757
4015         * c-common.c (check_builtin_function_arguments): Add check
4016         for BUILT_IN_SIGNBIT argument.
4018 2015-08-18  Paolo Carlini  <paolo.carlini@oracle.com>
4020         PR c++/67160
4021         * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
4022         in c++1z mode.
4024 2015-08-17  Marek Polacek  <polacek@redhat.com>
4026         * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
4027         with whitespaces before qualifier names.
4029 2015-08-12  Marek Polacek  <polacek@redhat.com>
4031         PR c++/55095
4032         * c-common.c (maybe_warn_shift_overflow): Properly handle
4033         left-shifting 1 into the sign bit.
4035 2015-08-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
4037         * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
4039 2015-08-06  Andrew Sutton  <andrew.n.sutton@gmail.com>
4040             Braden Obrzut  <admin@maniacsvault.net>
4041             Jason Merrill  <jason@redhat.com>
4043         Add C++ Concepts TS support.
4044         * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
4045         * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
4046         (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
4047         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
4048         * c-opts.c (set_std_cxx1z): Set flag_concepts.
4049         * c.opt (fconcepts): New.
4051 2015-08-02  Martin Sebor  <msebor@redhat.com>
4053         * c.opt (-Wframe-address): New warning option.
4055 2015-08-02  Patrick Palka  <ppalka@gcc.gnu.org>
4057         * c-indentation.c (should_warn_for_misleading_indentation):
4058         Improve heuristics.
4060 2015-08-02  Patrick Palka  <ppalka@gcc.gnu.org>
4062         * c-indentation.c (get_visual_column): Add parameter first_nws,
4063         use it.  Update comment documenting the function.
4064         (is_first_nonwhitespace_on_line): Remove.
4065         (should_warn_for_misleading_indentation): Replace usage of
4066         of is_first_nonwhitespace_on_line with get_visual_column.
4068 2015-08-02  Patrick Palka  <ppalka@gcc.gnu.org>
4070         * c-indentation.h (struct token_indent_info): Define.
4071         (get_token_indent_info): Define.
4072         (warn_for_misleading_information): Declare.
4073         * c-common.h (warn_for_misleading_information): Remove.
4074         * c-identation.c (warn_for_misleading_indentation):
4075         Change declaration to take three token_indent_infos.  Adjust
4076         accordingly.
4077         * c-identation.c (should_warn_for_misleading_indentation):
4078         Likewise.  Bail out early if the body is a compound statement.
4079         (guard_tinfo_to_string): Define.
4081 2015-07-30  Jason Merrill  <jason@redhat.com>
4083         * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
4084         '*' for reference decay.
4086 2015-07-30  Marek Polacek  <polacek@redhat.com>
4088         * c-common.c (warn_tautological_cmp): Bail for float types.
4090 2015-07-27  Marek Polacek  <polacek@redhat.com>
4092         PR bootstrap/67030
4093         * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
4095 2015-07-27  Marek Polacek  <polacek@redhat.com>
4097         PR c++/66555
4098         PR c/54979
4099         * c-common.c (find_array_ref_with_const_idx_r): New function.
4100         (warn_tautological_cmp): New function.
4101         * c-common.h (warn_tautological_cmp): Declare.
4102         * c.opt (Wtautological-compare): New option.
4104 2015-07-23  Marek Polacek  <polacek@redhat.com>
4106         * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
4107         (ubsan_instrument_shift): Likewise.
4109 2015-07-23  Marek Polacek  <polacek@redhat.com>
4111         PR sanitizer/66908
4112         * c-ubsan.c: Include gimplify.h.
4113         (ubsan_instrument_division): Unshare OP0 and OP1.
4114         (ubsan_instrument_shift): Likewise.
4116 2015-07-20  Marek Polacek  <polacek@redhat.com>
4117             Richard Sandiford  <richard.sandiford@arm.com>
4119         PR c++/55095
4120         * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
4121         Use EXPR_LOC_OR_LOC.
4122         (maybe_warn_shift_overflow): New function.
4123         * c-common.h (maybe_warn_shift_overflow): Declare.
4124         * c-opts.c (c_common_post_options): Set warn_shift_overflow.
4125         * c.opt (Wshift-overflow): New option.
4127 2015-07-16  Martin Liska  <mliska@suse.cz>
4129         * c-format.c (static void check_format_info_main): Use
4130         object_allocator instead of pool_allocator.
4131         (check_format_arg): Likewise.
4132         (check_format_info_main): Likewise.
4134 2015-07-15  Andrew MacLeod  <amacleod@redhat.com>
4136         * c-opts.c: Remove multiline #include comment.
4138 2015-07-12  Aldy Hernandez  <aldyh@redhat.com>
4140         * c-common.c: Fix double word typos.
4142 2015-07-10  Eric Botcazou  <ebotcazou@adacore.com>
4144         * c-ada-spec.h (cpp_operation): Revert latest change.
4145         * c-ada-spec.c (print_ada_declaration): Likewise.  Skip implicit
4146         constructors and destructors.
4148 2015-07-09  Andrew MacLeod  <amacleod@redhat.com>
4150         * c-common.h: Adjust includes for flags.h changes.
4151         * stub-objc.c: Likewise.
4153 2015-07-08  Eric Botcazou  <ebotcazou@adacore.com>
4155         * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
4156         * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
4158 2015-07-08  Jakub Jelinek  <jakub@redhat.com>
4160         * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
4161         are to be removed, return NULL rather than original clauses list.
4163 2015-07-07  Andrew MacLeod  <amacleod@redhat.com>
4165         * array-notation-common.c: Adjust includes.
4166         * c-ada-spec.c: Likewise.
4167         * c-cilkplus.c: Likewise.
4168         * c-common.h: Likewise.
4169         * c-cppbuiltin.c: Likewise.
4170         * c-dump.c: Likewise.
4171         * c-format.c: Likewise.
4172         * c-gimplify.c: Likewise.
4173         * c-indentation.c: Likewise.
4174         * c-lex.c: Likewise.
4175         * c-omp.c: Likewise.
4176         * c-opts.c: Likewise.
4177         * c-pch.c: Likewise.
4178         * c-ppoutput.c: Likewise.
4179         * c-pragma.c: Likewise.
4180         * c-pretty-print.c: Likewise.
4181         * c-semantics.c: Likewise.
4182         * c-ubsan.c: Likewise.
4183         * cilk.c: Likewise.
4184         * stub-objc.c: Likewise.
4186 2015-07-07  Eric Botcazou  <ebotcazou@adacore.com>
4188         * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
4189         * c-ada-spec.c (print_ada_declaration): Skip move constructors.
4191 2015-07-01  Jason Merrill  <jason@redhat.com>
4193         * c-common.h (D_CXX11): Rename from D_CXX0X.
4194         (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
4195         * c-common.c: Adjust.
4197         * c-opts.c (c_common_post_options): Default to C++14.
4199         * c-opts.c (c_common_post_options): Highest ABI level is now 10.
4201 2015-06-30  Edward Smith-Rowland  <3dw4rd@verizon.net>
4203         Implement N4197 - Adding u8 character literals
4204         * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
4205         CPP_CHAR.
4206         * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
4207         CPP_UTF8CHAR_USERDEF tokens.
4208         * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
4209         and CPP_UTF8CHAR tokens.
4210         (lex_charconst): Treat CPP_UTF8CHAR token.
4212 2015-06-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
4214         PR fortran/66605
4215         * c-common.c (do_warn_unused_parameter): Move here.
4216         * c-common.h (do_warn_unused_parameter): Declare.
4218 2015-06-29  Marek Polacek  <polacek@redhat.com>
4220         PR c/66322
4221         * c-common.c (check_case_bounds): Add bool * parameter.  Set
4222         OUTSIDE_RANGE_P.
4223         (c_add_case_label): Add bool * parameter.  Pass it down to
4224         check_case_bounds.
4225         (c_do_switch_warnings): Add bool parameters.  Implement -Wswitch-bool
4226         warning here.
4227         * c-common.h (c_add_case_label, c_do_switch_warnings): Update
4228         declarations.
4230 2015-06-27  Marek Polacek  <polacek@redhat.com>
4232         * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
4233         or VECTOR_INTEGER_TYPE_P throughout.
4234         * c-gimplify.c: Likewise.
4236 2015-06-26  Marek Polacek  <polacek@redhat.com>
4238         * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
4239         * c-common.c (c_fully_fold_internal): Likewise.
4240         (c_alignof_expr): Likewise.
4241         * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
4242         * c-ubsan.c (ubsan_instrument_bounds): Likewise.
4243         * cilk.c (create_parm_list): Likewise.
4245 2015-06-26  Marek Polacek  <polacek@redhat.com>
4247         * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
4249 2015-06-25  Andrew MacLeod  <amacleod@redhat.com>
4251         * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
4252         * c-gimplify.c: Likewise.
4253         * c-pragma.c: Likewise.
4254         * c-ubsan.c: Likewise.
4255         * cilk.c: Likewise.
4257 2015-06-25  Richard Sandiford  <richard.sandiford@arm.com>
4259         * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
4260         ggc_hasher.
4262 2015-06-25  Andrew MacLeod  <amacleod@redhat.com>
4264         * cilk.c: Move calls.h after tm.h in the include chain.
4266 2015-06-25  Marek Polacek  <polacek@redhat.com>
4268         * array-notation-common.c: Use VAR_P throughout.
4269         * c-ada-spec.c: Likewise.
4270         * c-common.c: Likewise.
4271         * c-format.c: Likewise.
4272         * c-gimplify.c: Likewise.
4273         * c-omp.c: Likewise.
4274         * c-pragma.c: Likewise.
4275         * c-pretty-print.c: Likewise.
4276         * cilk.c: Likewise.
4278 2015-06-25  Marek Polacek  <polacek@redhat.com>
4280         * cilk.c (extract_free_variables): Use is_global_var.
4282 2015-06-23  Richard Sandiford  <richard.sandiford@arm.com>
4284         * c-common.c: Don't include target-def.h.
4286 2015-06-23  Marek Polacek  <polacek@redhat.com>
4288         * c-common.c (warn_logical_operator): Use tree_int_cst_equal
4289         when comparing INTEGER_CSTs.
4291 2015-06-22  Pierre-Marie de Rodat  <derodat@adacore.com>
4293         * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
4294         * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
4295         (dump_ada_template): Skip partially specialized types.
4297 2015-06-22  Mikhail Maltsev  <maltsevm@gmail.com>
4299         * c-common.c (scalar_to_vector): Use std::swap instead of manually
4300         swapping.
4302 2015-06-17  Andrew MacLeod  <amacleod@redhat.com>
4304         * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
4305         * c-ada-spec.c: Likewise.
4306         * c-cilkplus.c: Likewise.
4307         * c-common.c: Likewise.
4308         * c-common.h: Likewise.
4309         * c-cppbuiltin.c: Likewise.
4310         * c-dump.c: Likewise.
4311         * c-format.c: Likewise.
4312         * c-gimplify.c: Likewise.
4313         * c-indentation.c: Likewise.
4314         * c-lex.c: Likewise.
4315         * c-omp.c: Likewise.
4316         * c-opts.c: Likewise.
4317         * c-pch.c: Likewise.
4318         * c-ppoutput.c: Likewise.
4319         * c-pragma.c: Likewise.
4320         * c-pretty-print.c: Likewise.
4321         * c-semantics.c: Likewise.
4322         * c-ubsan.c: Likewise.
4323         * cilk.c: Likewise.
4324         * stub-objc.c: Likewise.
4326 2015-06-13  Patrick Palka  <ppalka@gcc.gnu.org>
4328         PR c++/65168
4329         * c-common.c (c_common_truthvalue_conversion): Warn when
4330         converting an address of a reference to a truth value.
4332 2015-06-08  Andrew MacLeod  <amacleod@redhat.com>
4334         * array-notation-common.c : Adjust include files.
4335         * c-ada-spec.c : Likewise.
4336         * c-cilkplus.c : Likewise.
4337         * c-common.c : Likewise.
4338         * c-common.h : Likewise.
4339         * c-cppbuiltin.c : Likewise.
4340         * c-dump.c : Likewise.
4341         * c-format.c : Likewise.
4342         * c-gimplify.c : Likewise.
4343         * c-indentation.c : Likewise.
4344         * c-lex.c : Likewise.
4345         * c-omp.c : Likewise.
4346         * c-opts.c : Likewise.
4347         * c-pch.c : Likewise.
4348         * c-ppoutput.c : Likewise.
4349         * c-pragma.c : Likewise.
4350         * c-pretty-print.c : Likewise.
4351         * c-semantics.c : Likewise.
4352         * c-ubsan.c : Likewise.
4353         * cilk.c : Likewise.
4354         * stub-objc.c : Likewise.
4356 2015-06-08  Marek Polacek  <polacek@redhat.com>
4358         PR c/66415
4359         * c-format.c (location_from_offset): Return LOC if LINE is null.
4361 2015-06-05  Aldy Hernandez  <aldyh@redhat.com>
4363         * c-common.h (c_parse_final_cleanups): New prototype.
4364         * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
4366 2015-06-04  Sriraman Tallam  <tmsriram@google.com>
4368         * c-common.c (noplt): New attribute.
4369         (handle_noplt_attribute): New handler.
4371 2015-06-04  Andrew MacLeod  <amacleod@redhat.com>
4373         * array-notation-common.c: Adjust includes for restructured coretypes.h.
4374         * c-ada-spec.c: Likewise.
4375         * c-cilkplus.c: Likewise.
4376         * c-common.c: Likewise.
4377         * c-common.h: Likewise.
4378         * c-cppbuiltin.c: Likewise.
4379         * c-dump.c: Likewise.
4380         * c-format.c: Likewise.
4381         * c-gimplify.c: Likewise.
4382         * c-indentation.c: Likewise.
4383         * c-lex.c: Likewise.
4384         * c-omp.c: Likewise.
4385         * c-opts.c: Likewise.
4386         * c-pch.c: Likewise.
4387         * c-ppoutput.c: Likewise.
4388         * c-pragma.c: Likewise.
4389         * c-pretty-print.c: Likewise.
4390         * c-semantics.c: Likewise.
4391         * c-ubsan.c: Likewise.
4392         * cilk.c: Likewise.
4393         * stub-objc.c: Likewise.
4395 2015-06-02  David Malcolm  <dmalcolm@redhat.com>
4397         PR c/66220:
4398         * c-indentation.c (should_warn_for_misleading_indentation): Use
4399         expand_location rather than expand_location_to_spelling_point.
4400         Don't warn if the guarding statement is more indented than the
4401         next/body stmts.
4403 2015-06-02  David Malcolm  <dmalcolm@redhat.com>
4405         * c-indentation.c (warn_for_misleading_indentation): Bail out
4406         immediately if -Wmisleading-indentation isn't enabled.
4408 2015-06-01  Martin Liska  <mliska@suse.cz>
4410         * c-format.c (check_format_arg):Use new type-based pool allocator.
4411         (check_format_info_main) Likewise.
4413 2015-05-31  Eric Botcazou  <ebotcazou@adacore.com>
4415         * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
4416         (has_nontrivial_methods): Likewise.
4418 2015-05-25  Marek Polacek  <polacek@redhat.com>
4420         * c-ubsan.c (ubsan_instrument_shift): Use type0.
4422 2015-05-22  Marek Polacek  <polacek@redhat.com>
4424         PR c/47043
4425         * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
4427 2015-05-21  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
4429         * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
4430         STACK_GROWS_DOWNWARD.
4432 2015-05-21  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
4434         * c-cppbuiltin.c (c_cpp_builtins): Check the value of
4435         STACK_GROWS_DOWNWARD rather than if it is defined.
4437 2015-05-21  Manuel López-Ibáñez  <manu@gcc.gnu.org>
4439         PR c/52952
4440         * c-format.c (location_column_from_byte_offset): New.
4441         (location_from_offset): New.
4442         (struct format_wanted_type): Add offset_loc field.
4443         (check_format_info): Move handling of location for extra arguments
4444         closer to the point of warning.
4445         (check_format_info_main): Pass the result of location_from_offset
4446         to warning_at.
4447         (format_type_warning): Pass the result of location_from_offset
4448         to warning_at.
4450 2015-05-20  Marek Polacek  <polacek@redhat.com>
4452         * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
4454 2015-05-20  Marek Polacek  <polacek@redhat.com>
4456         * c-ada-spec.c (dump_sloc): Use DECL_P.
4458 2015-05-20  Marek Polacek  <polacek@redhat.com>
4460         * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
4461         * c-common.c: Likewise.
4463 2015-05-19  David Malcolm  <dmalcolm@redhat.com>
4465         * c-common.h (fe_file_change): Strengthen param from
4466         const line_map * to const line_map_ordinary *.
4467         (pp_file_change): Likewise.
4468         * c-lex.c (fe_file_change): Likewise.
4469         (cb_define): Use linemap_check_ordinary when invoking
4470         SOURCE_LINE.
4471         (cb_undef): Likewise.
4472         * c-opts.c (c_finish_options): Use linemap_check_ordinary when
4473         invoking cb_file_change.
4474         (c_finish_options): Likewise.
4475         (push_command_line_include): Likewise.
4476         (cb_file_change): Strengthen param "new_map" from
4477         const line_map * to const line_map_ordinary *.
4478         * c-ppoutput.c (cb_define): Likewise for local "map".
4479         (pp_file_change): Likewise for param "map" and local "from".
4481 2015-05-19  Mikhail Maltsev  <maltsevm@gmail.com>
4483         * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
4485 2015-05-18  Tom de Vries  <tom@codesourcery.com>
4487         * c-common.c (build_va_arg_1): New function.
4488         (build_va_arg): Add address operator to va_list operand if necessary.
4490 2015-05-15  Mikhail Maltsev  <maltsevm@gmail.com>
4492         PR c/48956
4493         * c-common.c (int_safely_convertible_to_real_p): Define.
4494         (unsafe_conversion_p): Check conversions involving complex types.
4495         (conversion_warning): Add new warning message for conversions which
4496         discard imaginary component.
4497         * c-common.h: (enum conversion_safety): Add new enumerator for such
4498         conversions.
4500 2015-05-14  Marek Polacek  <polacek@redhat.com>
4502         PR c/66066
4503         PR c/66127
4504         * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
4505         (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
4506         C_MAYBE_CONST_EXPR_INT_OPERANDS set.  Add FOR_INT_CONST argument and
4507         use it.  If FOR_INT_CONST, require that all evaluated operands be
4508         INTEGER_CSTs.
4510 2015-05-12  David Malcolm  <dmalcolm@redhat.com>
4512         * c-common.h (warn_for_misleading_indentation): New prototype.
4513         * c-indentation.c: New file.
4514         * c.opt (Wmisleading-indentation): New option.
4516 2015-05-12  Tom de Vries  <tom@codesourcery.com>
4518         PR tree-optimization/66010
4519         * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
4521 2015-05-09  Jason Merrill  <jason@redhat.com>
4523         * c-opts.c (c_common_post_options): Also clear
4524         cpp_opts->cpp_warn_cxx11_compat.
4526         * c-common.h (enum cxx_dialect): Add cxx_unset.
4527         * c-common.c (cxx_dialect): Initialize to cxx_unset.
4528         * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
4530         * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
4531         (std=gnu++0x): Mark as Undocumented.
4532         (std=gnu++1y): Add deprecated message.
4534 2015-05-08  Jason Merrill  <jason@redhat.com>
4536         * c.opt (Wc++11-compat): Make primary.  Rename var warn_cxx11_compat.
4537         * c-opts.c: Adjust.
4539         * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
4541 2015-05-08  Marek Polacek  <polacek@redhat.com>
4543         PR c/64918
4544         * c.opt (Woverride-init-side-effects): New option.
4546 2015-05-07  Marek Polacek  <polacek@redhat.com>
4548         PR c/65179
4549         * c-common.c (c_fully_fold_internal): Warn when left shifting a
4550         negative value.
4551         * c.opt (Wshift-negative-value): New option.
4552         * c-opts.c (c_common_post_options): Set warn_shift_negative_value
4553         when -Wextra and C99/C++11 mode.
4555 2015-05-07  Marek Polacek  <polacek@redhat.com>
4556             Martin Uecker  <uecker@eecs.berkeley.edu>
4558         * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
4559         flexible member array-like members if SANITIZE_BOUNDS_STRICT.
4561 2015-05-05  Jason Merrill  <jason@redhat.com>
4563         * c.opt (Wterminate): New.
4565 2015-04-30  Marek Polacek  <polacek@redhat.com>
4567         * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
4568         require that the non-constant be of a boolean type.
4570 2015-04-29  Josh Triplett  <josh@joshtriplett.org>
4572         * c-common.c (handle_section_attribute): Refactor to reduce
4573         nesting and distinguish between error cases.
4575 2015-04-29  Marek Polacek  <polacek@redhat.com>
4577         PR c/64610
4578         * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
4579         with 0/1.
4581 2015-04-29  Jakub Jelinek  <jakub@redhat.com>
4583         * c-common.h (omp_clause_mask): Unconditionally define as a class.
4584         Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
4585         HOST_BITS_PER_WIDE_INT.
4587 2015-04-28  Tom de Vries  <tom@codesourcery.com>
4589         PR tree-optimization/65887
4590         * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
4592 2015-04-28  Eric Botcazou  <ebotcazou@adacore.com>
4593             Pierre-Marie de Rodat  <derodat@adacore.com>
4595         * c-ada-spec.c (in_function): Delete.
4596         (dump_generic_ada_node): Do not change in_function and remove the
4597         redundant code dealing with it.
4598         (print_ada_declaration): Do not change in_function.  Use INDENT_INCR.
4599         (print_ada_methods): Output the static member functions in a nested
4600         package after the regular methods as well as associated renamings.
4602 2015-04-24  Marek Polacek  <polacek@redhat.com>
4604         PR c/65830
4605         * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
4606         and OPT_Wshift_count_overflow.
4608         PR c/63357
4609         * c-common.c (warn_logical_operator): Warn if the operands have the
4610         same expressions.
4612 2015-04-24  Marek Polacek  <polacek@redhat.com>
4614         PR c/61534
4615         * c-common.c (warn_logical_operator): Bail if either operand comes
4616         from a macro expansion.
4618 2015-04-10  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
4620         PR target/55143
4621         * c-common.c (c_default_pointer_mode): Add definition.
4622         * c-common.h (c_default_pointer_mode): Add declaration.
4624 2015-03-11  Jakub Jelinek  <jakub@redhat.com>
4626         * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
4627         on record_builtin_type argument.
4629 2015-03-10  Jakub Jelinek  <jakub@redhat.com>
4631         PR c/65120
4632         * c-common.c (warn_logical_not_parentheses): Don't warn for
4633         !x == 0 or !x != 0.
4635 2015-03-07  Marek Polacek  <polacek@redhat.com>
4637         PR sanitizer/65280
4638         * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
4639         before trying to figure out whether we have a flexible array member.
4641 2015-03-06  Eric Botcazou  <ebotcazou@adacore.com>
4642             Jonathan Wakely  <jwakely.gcc@gmail.com>
4644         * c-ada-spec.c (dump_ada_double_name): Fix pasto.
4646 2015-03-05  Eric Botcazou  <ebotcazou@adacore.com>
4648         PR ada/65319
4649         * c-ada-spec.c (print_destructor): Remove obsolete code.
4651 2015-03-01  Eric Botcazou  <ebotcazou@adacore.com>
4653         * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
4654         (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
4655         DECL_TEMPLATE_RESULT emulations.
4656         (dump_ada_template)): Add guard for TYPE_METHODS.
4658 2015-02-27  Marek Polacek  <polacek@redhat.com>
4660         PR c/65040
4661         * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
4663 2015-02-27  Kai Tietz  <ktietz@redhat.com>
4665         PR c/35330
4666         * c-pragma.c (handle_pragma_weak): Do not try to create
4667         weak/alias of declarations not being function, or variable
4668         declarations.
4670 2015-02-24  Thomas Schwinge  <thomas@codesourcery.com>
4672         PR libgomp/64625
4673         * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
4674         Remove macros.
4675         (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
4677 2015-02-16  Marek Polacek  <polacek@redhat.com>
4679         PR c/65066
4680         * c-format.c (check_format_types): Handle null param.
4682 2015-02-13  Marek Polacek  <polacek@redhat.com>
4684         PR c/65040
4685         * c-format.c (check_format_types): Don't warn about different
4686         signedness if the original value is in the range of WANTED_TYPE.
4688 2015-02-12  Jason Merrill  <jason@redhat.com>
4690         PR c++/64956
4691         * c-opts.c (c_common_post_options): Change flag_abi_version from 0
4692         to the current highest version.
4693         * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
4695 2015-02-04  Jakub Jelinek  <jakub@redhat.com>
4697         PR c/64824
4698         PR c/64868
4699         * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
4700         instead of RDIV_EXPR.  Use build_binary_op instead of
4701         build2_loc.
4703 2015-01-30  Joseph Myers  <joseph@codesourcery.com>
4705         * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
4706         to pass input_location as first argument.
4708 2015-01-23  Tom de Vries  <tom@codesourcery.com>
4710         PR libgomp/64672
4711         * c.opt (fopenacc): Mark as LTO option.
4713 2015-01-23  Tom de Vries  <tom@codesourcery.com>
4715         PR libgomp/64707
4716         * c.opt (fopenmp): Mark as LTO option.
4718 2015-01-21  Jakub Jelinek  <jakub@redhat.com>
4720         PR c/63307
4721         * cilk.c (fill_decls_vec): Only put decls into vector v.
4722         (compare_decls): Fix up formatting.
4724 2015-01-21  Igor Zamyatin  <igor.zamyatin@intel.com>
4726         PR c/63307
4727         * cilk.c: Include vec.h.
4728         (struct cilk_decls): New structure.
4729         (wrapper_parm_cb): Split this function to...
4730         (fill_decls_vec): ...this...
4731         (create_parm_list): ...and this.
4732         (compare_decls): New function.
4733         (for_local_cb): Remove.
4734         (wrapper_local_cb): Ditto.
4735         (build_wrapper_type): For now first traverse and fill vector of
4736         declarations then sort it and then deal with sorted vector.
4737         (cilk_outline): Ditto.
4738         (declare_one_free_variable): Ditto.
4740 2015-01-21  Jason Merrill  <jason@redhat.com>
4742         PR c++/64629
4743         * c-format.c (check_format_arg): Call decl_constant_value.
4745 2015-01-19  Martin Liska  <mliska@suse.cz>
4747         * c-common.c (handle_noicf_attribute): New function.
4749 2015-01-15  Thomas Schwinge  <thomas@codesourcery.com>
4750             Bernd Schmidt  <bernds@codesourcery.com>
4751             James Norris  <jnorris@codesourcery.com>
4752             Cesar Philippidis  <cesar@codesourcery.com>
4753             Ilmir Usmanov  <i.usmanov@samsung.com>
4754             Jakub Jelinek  <jakub@redhat.com>
4756         * c.opt (fopenacc): New option.
4757         * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
4758         * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
4759         New macros.
4760         * c-common.h (c_finish_oacc_wait): New prototype.
4761         * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
4762         (c_finish_oacc_wait): New function.
4763         * c-pragma.c (oacc_pragmas): New variable.
4764         (c_pp_lookup_pragma, init_pragma): Handle it.
4765         * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
4766         PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
4767         PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
4768         PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
4769         (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
4770         PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
4771         PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
4772         PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
4773         PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
4774         PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
4775         PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
4776         PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
4777         PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
4778         PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
4779         PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
4780         PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
4781         PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
4782         PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
4783         PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
4784         PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
4785         PRAGMA_OACC_CLAUSE_WORKER.
4787 2015-01-14  Marcos Diaz  <marcos.diaz@tallertechnologies.com>
4789         * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
4790         for the new option fstack-protector_explicit.
4791         * c-common.c (c_common_attribute_table): Add stack_protect attribute.
4792         (handle_stack_protect_attribute): New function.
4794 2015-01-13  Martin Uecker  <uecker@eecs.berkeley.edu>
4796         * c.opt: New option -Warray-bounds=.
4798 2015-01-09  Michael Collison  <michael.collison@linaro.org>
4800         * array-notation-common.c: Include hash-set.h, machmode.h,
4801         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4802         fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
4803         * c-ada-spec.c: Ditto.
4804         * c-cilkplus.c: Ditto.
4805         * c-common.c: Include input.h due to flattening of tree.h.
4806         Define macro GCC_C_COMMON_C.
4807         * c-common.h: Flatten tree.h header files into c-common.h.
4808         Remove include of tree-core.h.
4809         * c-cppbuiltin.c: Include hash-set.h, machmode.h,
4810         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4811         fold-const.h, wide-int.h, and inchash.h due to
4812         flattening of tree.h.
4813         * c-dump.c: Ditto.
4814         * c-format.c: Flatten tree.h header files into c-common.h.
4815         * c-cppbuiltin.c: Include hash-set.h, machmode.h,
4816         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4817         fold-const.h, wide-int.h, and inchash.h due to
4818         flattening of tree.h.
4819         * c-dump.c: Include hash-set.h, machmode.h,
4820         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4821         fold-const.h, wide-int.h, and inchash.h due to
4822         flattening of tree.h.
4823         * c-format.c: Include hash-set.h, machmode.h,
4824         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4825         fold-const.h, wide-int.h, inchash.h and real.h due to
4826         flattening of tree.h.
4827         * c-gimplify.c: Include hash-set.h, machmode.h,
4828         vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4829         fold-const.h, wide-int.h, and inchash.h due to
4830         flattening of tree.h.
4831         * cilk.c: Ditto.
4832         * c-lex.c: Ditto.
4833         * c-omp.c: Ditto.
4834         * c-opts.c: Ditto.
4835         * c-pch.c: Ditto.
4836         * c-ppoutput.c: Ditto.
4837         * c-pragma.c: Ditto.
4838         * c-pretty-print.c: Ditto.
4839         * c-semantics.c: Ditto.
4840         * c-ubsan.c: Ditto.
4841         * stub-objc.c: Ditto.
4843 2015-01-08  Jason Merrill  <jason@redhat.com>
4845         * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
4846         do_ubsan_in_current_function.
4847         (ubsan_maybe_instrument_reference_or_call): Likewise.
4848         * c-ubsan.h: Declare it.
4850 2015-01-08  Mike Stump  <mikestump@comcast.net>
4852         * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
4854 2015-01-07  Marek Polacek  <polacek@redhat.com>
4856         PR c/64440
4857         * c-common.c (c_fully_fold_internal): Warn for division and modulo
4858         if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
4860 2015-01-05  Trevor Saunders  <tsaunders@mozilla.com>
4862         PR c++/31397
4863         * c.opt (Wsuggest-override): New option.
4865 2015-01-05  Jakub Jelinek  <jakub@redhat.com>
4867         Update copyright years.
4869 2015-01-05  Marek Polacek  <polacek@redhat.com>
4871         PR c/64423
4872         * c-common.c (warn_array_subscript_with_type_char): Add location_t
4873         parameter.  Use it.
4874         * c-common.h (warn_array_subscript_with_type_char): Update
4875         declaration.
4877 2014-12-20  Edward Smith-Rowland  <3dw4rd@verizon.net>
4879         * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
4880         Control macro with flag_sized_deallocation.
4882 2014-12-20  Martin Uecker  <uecker@eecs.berkeley.edu>
4884         * c.opt (Wdiscarded-array-qualifiers): New option.
4886 2014-12-19  Jakub Jelinek  <jakub@redhat.com>
4888         PR preprocessor/63831
4889         * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
4890         and __has_cpp_attribute here.
4891         * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
4892         c_common_has_attribute.
4893         * c-common.h (c_common_has_attribute): New prototype.
4894         * c-lex.c (init_c_lex): Set cb->has_attribute to
4895         c_common_has_attribute instead of cb_has_attribute.
4896         (get_token_no_padding): New function.
4897         (cb_has_attribute): Renamed to ...
4898         (c_common_has_attribute): ... this.  No longer static.  Use
4899         get_token_no_padding, require ()s, don't build TREE_LIST
4900         unnecessarily, fix up formatting, adjust diagnostics, call
4901         init_attributes.
4903 2014-12-15  Jason Merrill  <jason@redhat.com>
4905         * c.opt (-fsized-deallocation, -Wc++14-compat): New.
4906         (-Wsized-deallocation): New.
4907         * c-opts.c (c_common_post_options): -fsized-deallocation defaults
4908         to on in C++14 and up.
4910 2014-12-11  Jason Merrill  <jason@redhat.com>
4912         * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
4914         * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
4915         we aren't complaining about VLAs.
4917 2014-12-06  Marek Polacek  <polacek@redhat.com>
4919         PR tree-optimization/64183
4920         * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
4921         shift-expression if it is integer_type_node.  Use types_compatible_p.
4923 2014-11-29  Jakub Jelinek  <jakub@redhat.com>
4925         * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
4926         last argument from create_tmp_var_raw and create_tmp_var calls.
4927         * cilk.c (gimplify_cilk_spawn): Likewise.
4928         * c-omp.c (c_finish_omp_atomic): Likewise.
4930 2014-11-28  Marek Polacek  <polacek@redhat.com>
4932         * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
4933         instead of unsigned_type_node.
4935 2014-11-28  Marek Polacek  <polacek@redhat.com>
4937         PR c/63862
4938         * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
4939         to op1_utype.
4940         * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
4941         expression to unsigned_type_node.
4943 2014-11-20  Mark Wielaard  <mjw@redhat.com>
4945         PR debug/38757
4946         * c-opts.c (set_std_c89): Set lang_hooks.name.
4947         (set_std_c99): Likewise.
4948         (set_std_c11): Likewise.
4949         (set_std_cxx98): Likewise.
4950         (set_std_cxx11): Likewise.
4951         (set_std_cxx14): Likewise.
4952         (set_std_cxx1z): Likewise.
4954 2014-11-21  Jakub Jelinek  <jakub@redhat.com>
4956         PR target/63764
4957         * c-common.h (convert_vector_to_pointer_for_subscript): Change
4958         return type to bool.
4959         * c-common.c: Include gimple-expr.h.
4960         (convert_vector_to_pointer_for_subscript): Change return type to
4961         bool.  If *vecp is not lvalue_p and has VECTOR_TYPE, return true
4962         and copy it into a TARGET_EXPR and use that instead of *vecp
4963         directly.
4965 2014-11-19  David Malcolm  <dmalcolm@redhat.com>
4967         Merger of git branch "gimple-classes-v2-option-3".
4968         * ChangeLog.gimple-classes: New.
4969         * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
4970         from being just a vec<gimple> to a vec<gbind *>.
4972 2014-11-18  Jakub Jelinek  <jakub@redhat.com>
4974         PR sanitizer/63813
4975         * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
4976         argument to ptype, set type to TREE_TYPE (ptype).  Don't call
4977         get_pointer_alignment for non-pointers.  Use ptype, or if it is
4978         reference type, corresponding pointer type, as type of kind
4979         argument.
4980         (ubsan_maybe_instrument_reference,
4981         ubsan_maybe_instrument_member_call): Adjust callers.
4983 2014-11-15  Marek Polacek  <polacek@redhat.com>
4985         PR middle-end/63884
4986         * array-notation-common.c (is_sec_implicit_index_fn): Return false
4987         for NULL fndecl.
4988         (extract_array_notation_exprs): Return for NULL node.
4990 2014-11-12  Joseph Myers  <joseph@codesourcery.com>
4992         * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
4993         undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
4995 2014-11-12  Jakub Jelinek  <jakub@redhat.com>
4997         PR c/59708
4998         * c-common.c (check_builtin_function_arguments): Handle
4999         BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
5001 2014-11-10  Andi Kleen  <ak@linux.intel.com>
5003         PR c/60804
5004         * c-common.h (check_no_cilk): Declare.
5005         * cilk.c (get_error_location): New function.
5006         (check_no_cilk): Dito.
5008 2014-11-10  Andi Kleen  <ak@linux.intel.com>
5010         * cilk.c (recognize_spawn): Use expression location
5011         for error message.
5013 2014-11-10  Paolo Carlini  <paolo.carlini@oracle.com>
5015         * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
5017 2014-11-10  Edward Smith-Rowland  <3dw4rd@verizon.net>
5019         * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
5020         (__cpp_rtti, __cpp_exceptions): New macros for C++98;
5021         (__cpp_range_based_for, __cpp_initializer_lists,
5022         __cpp_delegating_constructors, __cpp_nsdmi,
5023         __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
5024         for C++11; (__cpp_attribute_deprecated): Remove in favor of
5025         __has_cpp_attribute.
5026         * c-lex.c (cb_has_attribute): New callback CPP function;
5027         (init_c_lex): Set has_attribute callback.
5029 2014-11-04  Richard Biener  <rguenther@suse.de>
5031         * c-common.c (shorten_compare): Do not shorten mixed
5032         DFP and non-DFP compares.
5034 2014-11-01  Edward Smith-Rowland  <3dw4rd@verizon.net>
5036         * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
5037         * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
5038         Commentary and rearrangement of tests.
5039         * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
5040         Commentary and rearrangement of tests.
5041         * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto
5042         * g++.dg/cpp1y/feat-cxx98.C: Commentary.
5044 2014-10-29  Richard Sandiford  <richard.sandiford@arm.com>
5046         * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
5047         enum from machine_mode.
5049 2014-10-28  Andrew MacLeod  <amacleod@redhat.com>
5051         * c-common.c: Adjust include files.
5052         * c-gimplify.c: Ditto.
5053         * cilk.c: Ditto.
5054         * c-pragma.c: Ditto.
5055         * c-ubsan.c: Ditto.
5057 2014-10-27  Andrew MacLeod  <amacleod@redhat.com>
5059         * c-gimplify.c: Adjust include files.
5061 2014-10-26  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5063         PR c++/53061
5064         * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
5065         c_common_initialize_diagnostics.
5066         * c-common.h: Likewise.
5068 2014-10-24  Marek Polacek  <polacek@redhat.com>
5070         PR c/56980
5071         * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
5072         print "struct"/"union"/"enum" for typedefed names.
5074 2014-10-23  Marek Polacek  <polacek@redhat.com>
5076         * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
5077         in unsigned type.
5079 2014-10-22  Jakub Jelinek  <jakub@redhat.com>
5080             Yury Gribov  <y.gribov@samsung.com>
5082         * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5083         ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
5084         instead of flag_sanitize_recover as bool flag.
5086 2014-10-21  Kirill Yukhin  <kirill.yukhin@intel.com>
5088         * cilk.c: Revert previous change.
5090 2014-10-20  Igor Zamyatin  <igor.zamyatin@intel.com>
5092         PR c/63307
5093         * cilk.c: Include vec.h.
5094         (struct cilk_decls): New structure.
5095         (wrapper_parm_cb): Split this function to...
5096         (fill_decls_vec): ...this...
5097         (create_parm_list): ...and this.
5098         (compare_decls): New function.
5099         (for_local_cb): Remove.
5100         (wrapper_local_cb): Ditto.
5101         (build_wrapper_type): For now first traverse and fill vector of
5102         declarations then sort it and then deal with sorted vector.
5103         (cilk_outline): Ditto.
5104         (declare_one_free_variable): Ditto.
5106 2014-10-17  Marek Polacek  <polacek@redhat.com>
5108         * c-opts.c (c_common_post_options): Set warn_implicit_int.
5109         * c.opt (Wimplicit-int): Initialize to -1.
5111 2014-10-16  Andrew MacLeod  <amacleod@redhat.com>
5113         * c-pragma.c: Adjust include files.
5114         * c-semantics.c: Likewise.
5116 2014-10-16  DJ Delorie  <dj@redhat.com>
5118         * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
5119         multiples of bytes.
5121 2014-10-14  Jason Merrill  <jason@redhat.com>
5123         PR c++/63455
5124         * c-common.h (CPP_PREPARSED_EXPR): New.
5125         (N_CP_TTYPES): Adjust.
5127 2014-10-15  Marek Polacek  <polacek@redhat.com>
5129         * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
5131 2014-10-14  DJ Delorie  <dj@redhat.com>
5133         * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
5134         types, not just __int128.
5135         * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
5136         types, not just __int128.
5137         (cpp_atomic_builtins): Round pointer sizes up.
5138         (type_suffix): Use type precision, not specific types.
5139         * c-common.c (c_common_reswords): Remove __int128 special case.
5140         (c_common_type_for_size): Check for all __intN types, not just
5141         __int128.
5142         (c_common_type_for_mode): Likewise.
5143         (c_common_signed_or_unsigned_type): Likewise.
5144         (c_build_bitfield_integer_type): Likewise.
5145         (c_common_nodes_and_builtins): Likewise.
5146         (keyword_begins_type_specifier): Likewise.
5147         * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
5148         __intN variants.
5150 2014-10-12  Trevor Saunders  <tsaunders@mozilla.com>
5152         * c-common.c: Use hash_table instead of hashtab.
5154 2014-10-06  Edward Smith-Rowland  <3dw4rd@verizon.net>
5156         * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
5157         C++11 section.
5159 2014-10-03  Marc Glisse  <marc.glisse@inria.fr>
5161         PR c++/54427
5162         PR c++/57198
5163         PR c++/58845
5164         * c-common.c (warn_logical_operator): Punt for vectors.
5166 2014-10-01  Edward Smith-Rowland  <3dw4rd@verizon.net>
5168         Implement SD-6: SG10 Feature Test Recommendations
5169         * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
5170         macros and the __has_header macro.
5172 2014-09-30  Jason Merrill  <jason@redhat.com>
5174         * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
5175         RID_IS_TRIVIALLY_CONSTRUCTIBLE.
5176         * c-common.c (c_common_reswords): Add __is_trivially_copyable.
5178         * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
5179         * c-common.c (c_common_reswords): Add __is_trivially_copyable.
5181         * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
5182         * c-common.c (c_common_reswords): Remove __is_convertible_to.
5184 2014-09-24  Marek Polacek  <polacek@redhat.com>
5186         PR c/61405
5187         PR c/53874
5188         * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
5190 2014-09-23  Andi Kleen  <ak@linux.intel.com>
5192         * c-common.c (handle_no_reorder_attribute): New function.
5193         (c_common_attribute_table): Add no_reorder attribute.
5195 2014-09-22  Joseph Myers  <joseph@codesourcery.com>
5197         * c-cppbuiltin.c (c_cpp_builtins): Define
5198         __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
5199         modes.
5201 2014-09-18  Joseph Myers  <joseph@codesourcery.com>
5203         * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
5204         for supported floating-point modes.
5206 2014-09-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5208         * c.opt (Wpsabi): Use LangEnabledBy.
5209         * c-opts.c (c_common_handle_option): Do not handle here.
5211 2014-09-12  Joseph Myers  <joseph@codesourcery.com>
5213         * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
5214         macros for floating-point modes.
5216 2014-09-11  Marc Glisse  <marc.glisse@inria.fr>
5218         PR target/58757
5219         * c-cppbuiltin.c (builtin_define_float_constants): Correct
5220         __*_DENORM_MIN__ without denormals.
5222 2014-09-10  Jakub Jelinek  <jakub@redhat.com>
5224         * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5225         ubsan_instrument_vla, ubsan_instrument_return): Adjust
5226         ubsan_create_data callers.
5227         (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
5228         index is constant or BIT_AND_EXPR with constant mask and is
5229         small enough for the bound.
5230         * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
5231         ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
5233 2014-09-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5235         * c.opt: Add CppReason to various flags.
5236         (Wdate-time): Re-sort.
5237         * c-common.c: Include c-common.h earlier.
5238         (struct reason_option_codes_t): Delete.
5239         (c_option_controlling_cpp_error): Prefix global type and struct
5240         with cpp_.
5242 2014-09-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5244         * c.opt (Wnormalized): New.
5245         (Wnormalized=): Use Enum and Reject Negative.
5246         * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
5248 2014-09-08  Joseph Myers  <joseph@codesourcery.com>
5250         * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
5251         digits of floating-point modes if -fbuilding-libgcc.
5253 2014-09-05  Joseph Myers  <joseph@codesourcery.com>
5255         * c-cppbuiltin.c (c_cpp_builtins): Also define
5256         __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
5257         __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
5258         __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
5259         __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
5260         __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
5261         __LIBGCC_STACK_GROWS_DOWNWARD__,
5262         __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
5263         __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
5264         __LIBGCC_DWARF_FRAME_REGISTERS__,
5265         __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
5266         __LIBGCC_STACK_POINTER_REGNUM__ and
5267         __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
5268         (builtin_define_with_value): Handle backslash-escaping in string
5269         macro values.
5271 2014-09-05  Richard Biener  <rguenther@suse.de>
5273         PR middle-end/63148
5274         * c-format.c (check_format_arg): Properly handle
5275         effectively signed POINTER_PLUS_EXPR offset.
5277 2014-09-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5279         * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
5280         Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
5281         (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
5282         and Init.
5283         * c-opts.c (c_common_handle_option): Do not handle here.
5284         (sanitize_cpp_opts): Likewise.
5285         * c-common.c (struct reason_option_codes_t): Handle
5286         CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
5288 2014-09-03  Marek Polacek  <polacek@redhat.com>
5290         * c.opt (Wlogical-not-parentheses): Enable by -Wall.
5292 2014-09-02  Jakub Jelinek  <jakub@redhat.com>
5293             Balaji V. Iyer  <balaji.v.iyer@intel.com>
5294             Igor Zamyatin  <igor.zamyatin@intel.com>
5296         * c-cilkplus.c (cilk_for_number_of_iterations): New function.
5297         * c-common.c (c_common_reswords): Added _Cilk_for.
5298         * c-common.h (enum rid): Added RID_CILK_FOR.
5299         (cilk_for_number_of_iterations): Add declaration.
5300         * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
5301         CILK_FOR.
5302         * c-pragma.c (init_pragma): Register "grainsize" pragma.
5303         * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
5305 2014-08-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5307         * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
5308         Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
5309         Wundef): Use CPP, Var and Init.
5310         * c-opts.c (c_common_handle_option): Do not handle the above flags here.
5312 2014-08-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5314         * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
5315         * c-opts.c (c_common_handle_option): Do not handle here.
5317 2014-08-25  Jason Merrill  <jason@redhat.com>
5319         * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
5320         -std=c++14 and -std=gnu++14, rather than the reverse.
5321         * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
5322         OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
5323         * c-common.h (cxx_dialect): Remove cxx1y.
5325 2014-08-23  Edward Smith-Rowland  <3dw4rd@verizon.net>
5327         * c-common.h (enum cxx_dialect): Add cxx14.
5328         * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
5329         * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
5330         cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
5332 2014-08-22  Jason Merrill  <jason@redhat.com>
5334         * c.opt (std=gnu++17): Fix alias.
5336 2014-08-22  Marek Polacek  <polacek@redhat.com>
5338         PR c++/62199
5339         * c-common.c (warn_logical_not_parentheses): Don't check LHS.  Don't
5340         check for vector types.  Drop LHS argument.
5341         * c-common.h (warn_logical_not_parentheses): Adjust.
5343 2014-08-22  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5345         * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
5346         (Wmultichar): Likewise.
5347         (Wdate-time): Use C-family languages instead of Common. Use CPP
5348         and Var.
5349         * c-opts.c (c_common_handle_option): Do not handle the above
5350         options here.
5351         (sanitize_cpp_opts): Likewise.
5353 2014-08-21  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5355         PR fortran/44054
5356         * c-opts.c: Include tree-diagnostics.h.
5357         (c_diagnostic_finalizer): New.
5358         (c_common_initialize_diagnostics): Use it.
5360 2014-08-20  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5362         PR preprocessor/51303
5363         * c-common.c (struct reason_option_codes_t option_codes):
5364         Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
5366 2014-08-20  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5368         PR c/60975
5369         PR c/53063
5370         * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
5371         * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
5372         (c_common_post_options): Call init_global_opts_from_cpp.
5373         (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
5375 2014-08-19  Marek Polacek  <polacek@redhat.com>
5377         PR c++/62153
5378         * c-common.c (maybe_warn_bool_compare): New function.
5379         * c-common.h (maybe_warn_bool_compare): Declare.
5380         * c.opt (Wbool-compare): New option.
5382 2014-08-19  Marek Polacek  <polacek@redhat.com>
5384         * c.opt (Wc99-c11-compat): New option.
5386 2014-08-19  Marek Polacek  <polacek@redhat.com>
5388         * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
5389         to warn_c90_c99_compat.
5390         * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
5391         to -1.
5393 2014-08-19  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5394             Steven Bosscher  <steven@gcc.gnu.org>
5396         PR c/52952
5397         * c-format.c: Add extra_arg_loc and format_string_loc to struct
5398         format_check_results.
5399         (check_function_format): Use true and add comment for boolean
5400         argument.
5401         (finish_dollar_format_checking): Use explicit location when warning.
5402         (check_format_info): Likewise.
5403         (check_format_arg): Set extra_arg_loc and format_string_loc.
5404         (check_format_info_main): Use explicit location when warning.
5405         (check_format_types): Pass explicit location.
5406         (format_type_warning): Likewise.
5408 2014-08-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
5410         PR fortran/44054
5411         * c-format.c: Handle Fortran flags.
5413 2014-08-12  Igor Zamyatin  <igor.zamyatin@intel.com>
5415         PR other/61962
5416         * array-notation-common.c (find_rank): Added handling for other
5417         types of references.
5419 2014-08-10  Marek Polacek  <polacek@redhat.com>
5421         PR c/51849
5422         * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
5423         * c.opt (Wc90-c99-compat): Add option.
5425 2014-08-07  Trevor Saunders  <tsaunders@mozilla.com>
5427         * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
5429 2014-08-03  Marek Polacek  <polacek@redhat.com>
5431         * c-common.c (check_case_value):  Add location_t parameter.  Use it.
5432         (c_add_case_label): Pass loc to check_case_value.
5434 2014-08-02  Trevor Saunders  <tsaunders@mozilla.com>
5436         * cilk.c: Use hash_map instead of pointer_map.
5438 2014-08-02  Trevor Saunders  <tsaunders@mozilla.com>
5440         * c-gimplify.c: Use hash_set instead of pointer_set.
5442 2014-08-01  Igor Zamyatin  <igor.zamyatin@intel.com>
5444         PR middle-end/61455
5445         * array-notation-common.c (extract_array_notation_exprs): Handling
5446         of DECL_EXPR added.
5448 2014-08-01  Jakub Jelinek  <jakub@redhat.com>
5450         * c-common.h (min_align_of_type): Removed prototype.
5451         * c-common.c (min_align_of_type): Removed.
5452         * c-ubsan.h (ubsan_maybe_instrument_reference,
5453         ubsan_maybe_instrument_member_call): New prototypes.
5454         * c-ubsan.c: Include stor-layout.h and builtins.h.
5455         (ubsan_maybe_instrument_reference_or_call,
5456         ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
5457         functions.
5459 2014-07-31  Marc Glisse  <marc.glisse@inria.fr>
5461         PR c++/60517
5462         * c.opt (-Wreturn-local-addr): Move to common.opt.
5464 2014-07-30  Jason Merrill  <jason@redhat.com>
5466         PR c++/61659
5467         PR c++/61687
5468         Revert:
5469         * c.opt (-fuse-all-virtuals): New.
5471 2014-07-30  Tom Tromey  <tromey@redhat.com>
5473         PR c/59855
5474         * c.opt (Wdesignated-init): New option.
5475         * c-common.c (c_common_attribute_table): Add "designated_init".
5476         (handle_designated_init): New function.
5478 2014-07-24  Marek Polacek  <polacek@redhat.com>
5480         PR c/57653
5481         * c-opts.c (c_finish_options): If -imacros is in effect, return.
5483 2014-07-16  Dodji Seketeli  <dodji@redhat.com>
5485         PR preprocessor/60723 - missing system-ness marks for macro tokens
5486         * c-ppoutput.c (struct print::prev_was_system_token): New data
5487         member.
5488         (init_pp_output): Initialize it.
5489         (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
5490         (do_line_change): Return a flag saying if a line marker was
5491         emitted or not.
5492         (scan_translation_unit): Detect if the system-ness of the token we
5493         are about to emit is different from the one of the previously
5494         emitted token.  If so, emit a line marker.  Avoid emitting useless
5495         adjacent line markers.  Avoid emitting line markers for tokens
5496         originating from the expansion of built-in macros.
5497         (scan_translation_unit_directives_only): Adjust.
5499 2014-07-15  Marek Polacek  <polacek@redhat.com>
5501         * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
5502         TYPE_MAX_VALUE is NULL.
5504 2014-07-14  Jakub Jelinek  <jakub@redhat.com>
5506         PR middle-end/61294
5507         * c.opt (Wmemset-transposed-args): New warning.
5509 2014-07-10  Jason Merrill  <jason@redhat.com>
5511         PR c++/61659
5512         PR c++/61687
5513         * c.opt (-fuse-all-virtuals): New.
5515 2014-07-09  Richard Biener  <rguenther@suse.de>
5517         PR c-family/61741
5518         * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
5519         using unsigned arithmetic if overflow does not wrap instead of
5520         if overflow is undefined.
5522 2014-07-06  Marek Polacek  <polacek@redhat.com>
5524         PR c/6940
5525         * c.opt (Wsizeof-array-argument): New option.
5527 2014-07-03  Jakub Jelinek  <jakub@redhat.com>
5529         * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
5530         comments->count <= 1, as comments->entries might be NULL.
5532 2014-07-01  Marek Polacek  <polacek@redhat.com>
5534         * c.opt (Wint-conversion): New option.
5536 2014-07-01  Marek Polacek  <polacek@redhat.com>
5538         PR c/58286
5539         * c.opt (Wincompatible-pointer-types): New option.
5541 2014-06-30  Paolo Carlini  <paolo.carlini@oracle.com>
5543         PR c++/51400
5544         * c-common.c (handle_noreturn_attribute, handle_const_attribute):
5545         Do not discard TYPE_QUALS of type.
5547 2014-06-26  Jason Merrill  <jason@redhat.com>
5549         * c-common.h (enum cxx_dialect): Add cxx1z.
5550         * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
5551         * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
5553 2014-06-26  Teresa Johnson  <tejohnson@google.com>
5555         * c-common.h (get_dump_info): Declare.
5556         * c-gimplify.c (c_genericize): Use saved dump files.
5557         * c-opts.c (c_common_parse_file): Begin and end dumps
5558         once around parsing invocation.
5559         (get_dump_info): New function.
5561 2014-06-23  Marek Polacek  <polacek@redhat.com>
5562             Andrew MacLeod  <amacleod@redhat.com>
5564         PR c/61553
5565         * c-common.c (get_atomic_generic_size): Don't segfault if the
5566         type doesn't have a size.
5568 2014-06-20  Marek Polacek  <polacek@redhat.com>
5570         * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
5571         (ubsan_walk_array_refs_r): New function.
5572         (c_genericize): Instrument array bounds.
5573         * c-ubsan.c: Include "internal-fn.h".
5574         (ubsan_instrument_division): Mark instrumented arrays as having
5575         side effects.  Adjust ubsan_type_descriptor call.
5576         (ubsan_instrument_shift): Likewise.
5577         (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
5578         (ubsan_instrument_bounds): New function.
5579         (ubsan_array_ref_instrumented_p): New function.
5580         (ubsan_maybe_instrument_array_ref): New function.
5581         * c-ubsan.h (ubsan_instrument_bounds): Declare.
5582         (ubsan_array_ref_instrumented_p): Declare.
5583         (ubsan_maybe_instrument_array_ref): Declare.
5585 2014-06-20  Hale Wang  <hale.wang@arm.com>
5587         PR lto/61123
5588         * c.opt (fshort-enums): Add to LTO.
5589         * c.opt (fshort-wchar): Likewise.
5591 2014-06-16  Marek Polacek  <polacek@redhat.com>
5593         PR c/60439
5594         * c.opt (Wswitch-bool): Add Var.
5596 2014-06-12  Jakub Jelinek  <jakub@redhat.com>
5598         PR middle-end/61486
5599         * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
5600         #pragma omp target teams or
5601         #pragma omp {,target }teams distribute simd.
5603 2014-06-12  Jason Merrill  <jason@redhat.com>
5605         * c.opt (Wabi=, fabi-compat-version): New.
5606         * c-opts.c (c_common_handle_option): Handle -Wabi=.
5607         (c_common_post_options): Handle flag_abi_compat_version default.
5608         Disallow -fabi-compat-version=1.
5609         * c-common.h (abi_version_crosses): New.
5611 2014-06-11  Jan Hubicka  <hubicka@ucw.cz>
5613         * c-common.c (handle_section_attribute): Update handling for
5614         section names that are no longer trees.
5616 2014-06-10  Jakub Jelinek  <jakub@redhat.com>
5618         PR fortran/60928
5619         * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
5620         (omp_pragmas): ... back here.
5622 2014-06-05  Marek Polacek  <polacek@redhat.com>
5624         PR c/49706
5625         * c-common.c (warn_logical_not_parentheses): New function.
5626         * c-common.h (warn_logical_not_parentheses): Declare.
5627         * c.opt (Wlogical-not-parentheses): New option.
5629 2014-06-04  Marek Polacek  <polacek@redhat.com>
5631         PR c/30020
5632         * c-common.c (check_case_bounds): Add location parameter.
5633         Use it.
5634         (c_add_case_label): Pass loc to check_case_bounds.
5636 2014-06-03  Marek Polacek  <polacek@redhat.com>
5638         PR c/60439
5639         * c.opt (Wswitch-bool): New option.
5641 2014-05-22  Thomas Schwinge  <thomas@codesourcery.com>
5643         * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
5644         Remove prototypes.
5645         (record_types_used_by_current_var_decl): Move prototype to where
5646         it belongs.
5648         * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
5649         (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
5650         (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
5652 2014-05-21  Richard Sandiford  <rsandifo@linux.vnet.ibm.com>
5654         * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
5655         * c-common.c (c_common_nodes_and_builtins): Don't initialize
5656         void_zero_node.
5657         * c-pretty-print.c (pp_c_void_constant): New function.
5658         (c_pretty_printer::constant, c_pretty_printer::primary_expression)
5659         (c_pretty_printer::expression): Handle VOID_CST.
5660         * cilk.c (extract_free_variables): Likewise.
5661         * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
5662         (ubsan_instrument_vla): Use void_node instead of void_zero_node.
5664 2014-05-17  Trevor Saunders  <tsaunders@mozilla.com>
5666         * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
5667         * c-pragma.c (push_alignment): Adjust.
5668         (handle_pragma_push_options): Likewise.
5670 2014-05-09  Marek Polacek  <polacek@redhat.com>
5672         PR c/50459
5673         * c-common.c (check_user_alignment): Return -1 if alignment is error
5674         node.
5675         (handle_aligned_attribute): Don't call default_conversion on
5676         FUNCTION_DECLs.
5677         (handle_vector_size_attribute): Likewise.
5678         (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
5679         (handle_sentinel_attribute): Call default_conversion and allow even
5680         integral types as an argument.
5682 2014-05-08  Marek Polacek  <polacek@redhat.com>
5684         PR c/61053
5685         * c-common.c (min_align_of_type): New function factored out from...
5686         (c_sizeof_or_alignof_type): ...here.
5687         * c-common.h (min_align_of_type): Declare.
5689 2014-05-08  Marek Polacek  <polacek@redhat.com>
5691         PR c/61077
5692         * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
5693         parameter type of main.
5695 2014-05-07  DJ Delorie  <dj@redhat.com>
5697         * c-cppbuiltin.c (print_bits_of_hex): New.
5698         (builtin_define_type_minmax): Print values using hex so as not to
5699         require a pre-computed list of string values.
5701 2014-05-06  Kenneth Zadeck  <zadeck@naturalbridge.com>
5702             Mike Stump  <mikestump@comcast.net>
5703             Richard Sandiford  <rdsandiford@googlemail.com>
5705         * c-ada-spec.c: Include wide-int.h.
5706         (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
5707         (dump_generic_ada_node): Use wide-int interfaces.
5708         * c-common.c: Include wide-int-print.h.
5709         (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
5710         (pointer_int_sum): Use wide-int interfaces.
5711         (c_common_nodes_and_builtins): Use make_int_cst.
5712         (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
5713         (handle_alloc_size_attribute): Use wide-int interfaces.
5714         (get_nonnull_operand): Likewise.
5715         * c-format.c (get_constant): Use tree_fits_uhwi_p.
5716         * c-lex.c: Include wide-int.h.
5717         (narrowest_unsigned_type): Take a widest_int rather than two
5718         HOST_WIDE_INTs.
5719         (narrowest_signed_type): Likewise.
5720         (interpret_integer): Update accordingly.  Use wide-int interfaces.
5721         (lex_charconst): Use wide-int interfaces.
5722         * c-pretty-print.c: Include wide-int.h.
5723         (pp_c_integer_constant): Use wide-int interfaces.
5724         * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
5725         INT_CST_LT_UNSIGNED.
5727 2014-05-06  Richard Biener  <rguenther@suse.de>
5729         * c-opts.c (c_common_post_options): For -freestanding,
5730         -fno-hosted and -fno-builtin disable pattern recognition
5731         if not enabled explicitely.
5733 2014-05-02  Marek Polacek  <polacek@redhat.com>
5735         * c.opt (Wsizeof-pointer-memaccess): Describe option.
5737 2014-05-01  Marek Polacek  <polacek@redhat.com>
5739         PR c/43245
5740         * c.opt (Wdiscarded-qualifiers): Add.
5742 2014-04-30  Marek Polacek  <polacek@redhat.com>
5744         * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs.  Perform
5745         INT_MIN / -1 sanitization only for integer types.
5747 2014-04-25  Marek Polacek  <polacek@redhat.com>
5749         PR c/18079
5750         * c-common.c (handle_noinline_attribute): Warn if the attribute
5751         conflicts with always_inline attribute.
5752         (handle_always_inline_attribute): Warn if the attribute conflicts
5753         with noinline attribute.
5755 2014-04-25  Marek Polacek  <polacek@redhat.com>
5757         PR c/60156
5758         * c-common.c (check_main_parameter_types): Warn about variadic main.
5760 2014-04-24  Mike Stump  <mikestump@comcast.net>
5762         * c.opt (Wshadow-ivar): Default to on.
5764 2014-04-24  Dimitris Papavasiliou  <dpapavas@gmail.com>
5766         * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
5768 2014-04-23  Marek Polacek  <polacek@redhat.com>
5770         * c-common.c (handle_tm_wrap_attribute): Tweak error message.
5772 2014-04-22  Jakub Jelinek  <jakub@redhat.com>
5774         PR sanitizer/60275
5775         * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
5776         if flag_sanitize_undefined_trap_on_error.
5777         (ubsan_instrument_division, ubsan_instrument_shift,
5778         ubsan_instrument_vla): Likewise.  Use __ubsan_handle_*_abort ()
5779         if !flag_sanitize_recover.
5781 2014-04-22  Marc Glisse  <marc.glisse@inria.fr>
5783         PR libstdc++/43622
5784         * c-common.c (registered_builtin_types): Make non-static.
5785         * c-common.h (registered_builtin_types): Declare.
5787 2014-04-14  Richard Biener  <rguenther@suse.de>
5788         Marc Glisse  <marc.glisse@inria.fr>
5790         PR c/60819
5791         * c-common.c (convert_vector_to_pointer_for_subscript): Properly
5792         apply may-alias the scalar pointer type when applicable.
5794 2014-04-12  Igor Zamyatin  <igor.zamyatin@intel.com>
5796         PR middle-end/60467
5797         * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
5798         as possible argument for Cilk_spawn.
5800 2014-04-11  Tobias Burnus  <burnus@net-b.de>
5802         PR c/60194
5803         * c.opt (Wformat-signedness): Add
5804         * c-format.c(check_format_types): Use it.
5806 2014-04-11  Jason Merrill  <jason@redhat.com>
5808         PR c++/57926
5809         * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
5810         default_conversion for an array argument.
5812 2014-04-08  Marek Polacek  <polacek@redhat.com>
5814         PR sanitizer/60745
5815         * c-ubsan.c: Include asan.h.
5816         (ubsan_instrument_return): Call initialize_sanitizer_builtins.
5818 2014-04-03  Nathan Sidwell  <nathan@codesourcery.com>
5820         * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
5822 2014-04-02  Marek Polacek  <polacek@redhat.com>
5824         * c-common.h (c_expand_expr): Remove declaration.
5826 2014-03-28  Jakub Jelinek  <jakub@redhat.com>
5828         PR c++/60689
5829         * c-common.c (add_atomic_size_parameter): When creating new
5830         params vector, push the size argument first.
5832 2014-03-26  Jakub Jelinek  <jakub@redhat.com>
5834         * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5835         ubsan_instrument_vla, ubsan_instrument_return): Adjust
5836         ubsan_create_data callers.
5838 2014-03-22  Jakub Jelinek  <jakub@redhat.com>
5840         PR debug/60603
5841         * c-opts.c (c_finish_options): Restore cb_file_change call to
5842         <built-in>.
5844 2014-03-13  Jakub Jelinek  <jakub@redhat.com>
5846         PR middle-end/36282
5847         * c-pragma.c (apply_pragma_weak): Only look at
5848         TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
5849         DECL_ASSEMBLER_NAME_SET_P (decl).
5850         (maybe_apply_pending_pragma_weaks): Exit early if
5851         vec_safe_is_empty (pending_weaks) rather than only when
5852         !pending_weaks.
5853         (maybe_apply_pragma_weak): Likewise.  If !DECL_ASSEMBLER_NAME_SET_P,
5854         set assembler name back to NULL afterwards.
5856 2014-03-11  Jason Merrill  <jason@redhat.com>
5858         * c.opt: Add -std=gnu++14.
5860 2014-03-11  Ian Bolton  <ian.bolton@arm.com>
5862         * c-opts.c (c_common_post_options): Don't override
5863         -ffp-contract=fast if unsafe-math-optimizations is on.
5865 2014-03-08  Paulo Matos  <paulo@matos-sorge.com>
5867         * c.opt: Enable LTO FE for fshort-double.
5869 2014-03-07  Jason Merrill  <jason@redhat.com>
5871         * c.opt: Add -std=c++14.
5873 2014-03-06  Marek Polacek  <polacek@redhat.com>
5875         PR c/60197
5876         * cilk.c (contains_cilk_spawn_stmt): New function.
5877         (contains_cilk_spawn_stmt_walker): Likewise.
5878         (recognize_spawn): Give error on invalid use of _Cilk_spawn.
5879         * c-common.h (contains_cilk_spawn_stmt): Add declaration.
5881 2014-03-03  Jakub Jelinek  <jakub@redhat.com>
5883         * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
5884         (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
5885         even when flag_preprocess_only.
5887 2014-02-26  Jason Merrill  <jason@redhat.com>
5889         PR c++/59231
5890         PR c++/11586
5891         * c-common.c (shorten_compare): Don't check
5892         c_inhibit_evaluation_warnings.
5894 2014-02-19  Jakub Jelinek  <jakub@redhat.com>
5896         PR c/37743
5897         * c-common.c (c_common_nodes_and_builtins): When initializing
5898         c_uint{16,32,64}_type_node, also set corresponding
5899         uint{16,32,64}_type_node to the same value.
5901         PR c++/60267
5902         * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
5903         for PRAGMA_IVDEP if flag_preprocess_only.
5905 2014-02-12  Jakub Jelinek  <jakub@redhat.com>
5907         PR c/60101
5908         * c-common.c (merge_tlist): If copy is true, call new_tlist,
5909         if false, add ADD itself, rather than vice versa.
5910         (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
5911         copy.  For SAVE_EXPR, only call merge_tlist once.
5913 2014-02-08  Jakub Jelinek  <jakub@redhat.com>
5915         PR middle-end/60092
5916         * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
5917         and tree_to_uhwi.
5918         (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
5919         functions.
5920         (c_common_attribute_table): Add alloc_align and assume_aligned
5921         attributes.
5923 2014-02-06  Marek Polacek  <polacek@redhat.com>
5925         PR c/60087
5926         * c-common.c (warn_for_sign_compare): Call warning_at with location
5927         instead of warning.
5929 2014-02-05  Marek Polacek  <polacek@redhat.com>
5931         PR c/53123
5932         * c-omp.c (c_finish_omp_atomic): Remove unreachable return
5933         statement.
5935 2014-02-04  Marek Polacek  <polacek@redhat.com>
5937         PR c/60036
5938         * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
5939         SAVE_EXPR.
5941 2014-02-03  Marc Glisse  <marc.glisse@inria.fr>
5943         PR c++/53017
5944         PR c++/59211
5945         * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
5946         handle_vector_size_attribute, handle_nonnull_attribute): Call
5947         default_conversion on the attribute argument.
5948         (handle_nonnull_attribute): Increment the argument number.
5950 2014-01-31  Marek Polacek  <polacek@redhat.com>
5952         PR c/59963
5953         * c-common.c (add_atomic_size_parameter): Pass vNULL to
5954         build_function_call_vec.
5955         (resolve_overloaded_builtin): Likewise.
5956         * c-common.h (build_function_call_vec): Adjust declaration.
5958 2014-01-30  Marek Polacek  <polacek@redhat.com>
5960         PR c/59940
5961         * c-common.h (unsafe_conversion_p): Adjust declaration.
5962         (warnings_for_convert_and_check): Likewise.
5963         (convert_and_check): Likewise.
5964         * c-common.c (unsafe_conversion_p): Add location parameter.  Call
5965         expansion_point_location_if_in_system_header on it.
5966         (warnings_for_convert_and_check): Add location parameter.  Call
5967         expansion_point_location_if_in_system_header on it.  Use it.
5968         (convert_and_check): Add location parameter.  Use it.
5969         (conversion_warning): Likewise.
5970         (c_add_case_label): Adjust convert_and_check calls.
5971         (scalar_to_vector): Adjust unsafe_conversion_p calls.
5973 2014-01-24  Balaji V. Iyer  <balaji.v.iyer@intel.com>
5975         * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
5976         flag_cilkplus.
5977         * c-pragma.c (init_pragma): Likewise.
5978         * c.opt: Likewise.
5980 2014-01-23  Marek Polacek  <polacek@redhat.com>
5982         PR c/59846
5983         * c-common.c (shorten_compare): Add location_t parameter.
5984         * c-common.h (shorten_binary_op): Adjust declaration.
5986 2014-01-23  Marek Polacek  <polacek@redhat.com>
5988         PR c/58346
5989         * c-common.c (pointer_to_zero_sized_aggr_p): New function.
5990         * c-common.h: Declare it.
5992 2014-01-20  Eric Botcazou  <ebotcazou@adacore.com>
5994         * c-ada-spec.h (dump_ada_specs): Revert prototype change.
5995         * c-ada-spec.c (dump_ads): Likewise.
5996         (cpp_check): Likewise.
5997         (dump_ada_specs): Likewise.
5999 2014-01-15  Laurent Alfonsi  <laurent.alfonsi@st.com>
6001         PR c++/49718
6002         * c-common.c (handle_no_instrument_function_attribute): Allow
6003         no_instrument_function attribute in class member
6004         definition/declaration.
6006 2014-01-15  Jakub Jelinek  <jakub@redhat.com>
6008         PR c/58943
6009         * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
6010         build_modify_expr with non-NOP_EXPR opcode.  Handle return from it
6011         being COMPOUND_EXPR.
6012         (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
6013         operand a SAVE_EXPR and second MODIFY_EXPR.
6015 2014-01-09  Jakub Jelinek  <jakub@redhat.com>
6017         PR target/58115
6018         * c-pch.c (c_common_write_pch): Call
6019         prepare_target_option_nodes_for_pch.
6021 2014-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
6023         Update copyright years
6025 2014-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
6027         * array-notation-common.c, c-cilkplus.c: Use the standard form for
6028         the copyright notice.
6030 2013-12-28  Eric Botcazou  <ebotcazou@adacore.com>
6032         * c-ada-spec.c (print_constructor): New function.
6033         (print_destructor): Retrieve the origin of the destructor.
6034         (print_ada_declaration): Revamp handling of constructors/destructors.
6036 2013-12-23  Stuart Hastings  <stuart@apple.com>
6037             Bill Maddox  <maddox@google.com>
6038             Jason Merrill  <jason@redhat.com>
6040         * c.opt: Add -fdeclone-ctor-dtor.
6041         * c-opts.c (c_common_post_options): Default to on iff -Os.
6043 2013-12-18  Balaji V. Iyer  <balaji.v.iyer@intel.com>
6045         * c-common.c (c_common_attribute_table): Added "cilk simd function"
6046         attribute.
6047         * c-pragma.h (enum pragma_cilk_clause): Remove.
6048         (enum pragma_omp_clause):  Added the following fields:
6049         PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
6050         PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
6051         PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
6052         PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
6053         PRAGMA_CILK_CLAUSE_UNIFORM.
6056 2013-12-11  Balaji V. Iyer  <balaji.v.iyer@intel.com>
6058         * cilk.c (cilk_outline): Made this function non-static.
6059         (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
6060         (create_cilk_wrapper): Added a new parameter: a function pointer.
6061         (c_install_body_w_frame_cleanup): Remove
6062         (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
6063         * c-common.h (cilk_outline): New prototype.
6064         (gimplify_cilk_spawn): Removed two parameters.
6065         (cilk_install_body_with_frame_cleanup): New prototype.
6066         * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
6067         CILK_SPAWN_STMT case.
6069 2013-12-11  Bernd Schmidt  <bernds@codesourcery.com>
6071         * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
6073         * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
6074         (int_array_type_node): Remove.
6075         * c-common.c (c_common_nodes_and_builtins): Don't build it.
6077 2013-12-05  Marek Polacek  <polacek@redhat.com>
6079         PR c/52023
6080         * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
6081         [ADJUST_FIELD_ALIGN].
6083 2013-12-04  Joseph Myers  <joseph@codesourcery.com>
6085         PR c/52023
6086         * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
6087         and check field alignment if set.
6088         * c-common.h (c_sizeof_or_alignof_type): Update prototype.
6089         (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
6091 2013-12-04  Jakub Jelinek  <jakub@redhat.com>
6092             Marek Polacek  <polacek@redhat.com>
6094         * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
6095         sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
6097 2013-11-29   H.J. Lu  <hongjiu.lu@intel.com>
6099         PR c/59309
6100         * cilk.c (gimplify_cilk_spawn): Properly handle function without
6101         arguments.
6103 2013-11-29  Jakub Jelinek  <jakub@redhat.com>
6105         PR c/59280
6106         * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
6107         goto invalid.  If it is error_mark_node, don't issue further
6108         diagnostics.
6110 2013-11-28  Sergey Ostanevich  <sergos.gnu@gmail.com>
6112         * c.opt (Wopenmp-simd): New.
6114 2013-11-22  Jakub Jelinek  <jakub@redhat.com>
6116         * c-ubsan.h (ubsan_instrument_return): New prototype.
6117         * c-ubsan.c (ubsan_instrument_return): New function.
6119 2013-11-22  Andrew MacLeod  <amacleod@redhat.com>
6121         * c-common.c: Add required include files from gimple.h.
6122         * c-gimplify.c: Likewise
6123         * cilk.c: Likewise
6125 2013-11-22  David Malcolm  <dmalcolm@redhat.com>
6127         * c-common.c (unsafe_conversion_p): Remove use of
6128         EXPR_LOC_OR_HERE macro.
6129         (conversion_warning): Likewise.
6130         (warnings_for_convert_and_check): Likewise.
6131         (warn_for_collisions_1): Likewise.
6132         (shorten_compare): Likewise, and remove use of in_system_header
6133         macro, using the location from the former.
6134         * c-lex.c (dump_one_header): Remove use of input_filename macro.
6135         (cb_def_pragma): Remove use of in_system_header macro.
6136         (lex_string): Likewise.
6137         * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
6139 2013-11-20  Kenneth Zadeck  <zadeck@naturalbridge.com>
6140             Mike Stump  <mikestump@comcast.net>
6141             Richard Sandiford  <rdsandiford@googlemail.com>
6143         * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
6144         instead of TREE_INT_CST_LOW, in cases where there is a protecting
6145         tree_fits_shwi_p or tree_fits_uhwi_p.
6146         (dump_generic_ada_node): Likewise.
6147         * c-format.c (check_format_arg): Likewise.
6148         * c-pretty-print.c (pp_c_integer_constant): Likewise.
6150 2013-11-20  Kenneth Zadeck  <zadeck@naturalbridge.com>
6152         * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
6154 2013-11-19  Joshua J Cogliati  <jrincayc@yahoo.com>
6156         PR c/53001
6157         * c-common.c (unsafe_conversion_p): Make this function
6158         return an enumeration with more detail.
6159         (conversion_warning): Use the new return type of
6160         unsafe_conversion_p to separately warn either about conversions
6161         that lower floating point number precision or about the other
6162         kinds of conversions.
6163         * c-common.h (enum conversion_safety): New enumeration.
6164         (unsafe_conversion_p): switching return type to
6165         conversion_safety enumeration.
6166         * c.opt: Adding new warning -Wfloat-conversion and
6167         enabling it with -Wconversion.
6169 2013-11-19  Basile Starynkevitch  <basile@starynkevitch.net>
6171         * c-opts.c: Include plugin.h.
6172         (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
6174 2013-11-19  Marek Polacek  <polacek@redhat.com>
6176         * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
6177         call.
6178         (ubsan_instrument_shift): Likewise.
6179         (ubsan_instrument_vla): Likewise.
6181 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
6183         * c-common.c (convert_vector_to_pointer_for_subscript): Remove
6184         cast to unsigned type.
6186 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
6188         * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
6189         tree_low_cst.
6190         (complete_array_type): Update comment to refer to tree_to_[su]hwi
6191         rather than tree_low_cst.
6193 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
6195         * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
6196         tree_to_uhwi throughout.
6198 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
6200         * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
6201         tree_low_cst (..., 0) with tree_to_shwi throughout.
6203 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
6205         * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
6206         host_integerp (..., 1) with tree_fits_uhwi_p throughout.
6208 2013-11-18  Richard Sandiford  <rdsandiford@googlemail.com>
6210         * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
6211         host_integerp (..., 0) with tree_fits_shwi_p throughout.
6213 2013-11-15  Aldy Hernandez  <aldyh@redhat.com>
6215         * c-cilkplus.c: New file.
6216         * c-common.c (readonly_error): Add location argument.
6217         * c-common.h (readonly_error): Same.
6218         (c_finish_cilk_clauses): Protoize.
6219         (c_check_cilk_loop): Same.
6220         c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
6221         Do not fail on error_mark_node.
6222         Abstract increment canonicalization to here...
6223         (c_omp_for_incr_canonicalize_ptr): New.
6224         c-pragma.c (init_pragma): Register "simd" pragma.
6225         c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
6226         (enum pragma_cilk_clause): New.
6228 2013-11-15  Richard Sandiford  <rdsandiford@googlemail.com>
6230         * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
6231         wchar_type and host_integerp checks.
6233 2013-11-14  Andrew MacLeod  <amacleod@redhat.com>
6235         * c-common.c: Likewise.
6236         * c-gimplify.c: Likewise.
6237         * cilk.c: Likewise.
6239 2013-11-14  Diego Novillo  <dnovillo@google.com>
6241         * c-common.c: Include fold-const.h.
6242         Include stor-layout.h.
6243         Include calls.h.
6244         Include stringpool.h.
6245         Include attribs.h.
6246         Include varasm.h.
6247         Include trans-mem.h.
6248         * c-cppbuiltin.c: Include stor-layout.h.
6249         Include stringpool.h.
6250         * c-format.c: Include stringpool.h.
6251         * c-lex.c: Include stringpool.h.
6252         Include stor-layout.h.
6253         * c-pragma.c: Include stringpool.h.
6254         Include attribs.h.
6255         Include varasm.h.
6256         Include gcc-symtab.h.
6257         * c-pretty-print.c: Include stor-layout.h.
6258         Include attribs.h.
6259         * cilk.c: Include stringpool.h.
6260         Include calls.h.
6262 2013-11-13  Joseph Myers  <joseph@codesourcery.com>
6264         * c-common.h (enum rid): Add RID_AUTO_TYPE.
6265         * c-common.c (c_common_reswords): Add __auto_type.
6266         (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
6268 2013-11-12  Andrew MacLeod  <amacleod@redhat.com>
6270         * c-common.c: Include gimplify.h.
6271         * c-gimplify.c: Likewise.
6272         * cilk.c: Likewise.
6273         * c-omp.c: Include gimple-expr.h instead of gimple.h.
6274         * c-ubsan.c: Don't include gimple.h.
6276 2013-11-12  Joseph Myers  <joseph@codesourcery.com>
6278         * c-common.c (c_common_reswords): Add _Thread_local.
6280 2013-11-09  Joseph Myers  <joseph@codesourcery.com>
6282         * c-common.c (atomic_size_supported_p): New function.
6283         (resolve_overloaded_atomic_exchange)
6284         (resolve_overloaded_atomic_compare_exchange)
6285         (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
6286         Use it instead of comparing size with a local list of sizes.
6288 2013-11-07  Andrew MacLeod  <amacleod@redhat.com>
6289             Joseph Myers  <joseph@codesourcery.com>
6291         * c-common.h (enum rid): Add RID_ATOMIC.
6292         * c-common.c (c_common_reswords): Add _Atomic.
6293         (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
6294         (keyword_is_type_qualifier): Accept RID_ATOMIC.
6295         * c-format.c (check_format_types): Check for extra _Atomic
6296         qualifiers in format argument.
6297         * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
6298         (pp_c_type_qualifier_list): Mention _Atomic in comment.
6300 2013-11-06  Tobias Burnus  <burnus@net-b.de>
6302         * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
6304 2013-11-06  Joseph Myers  <joseph@codesourcery.com>
6306         * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
6307         standards modes.
6308         * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
6309         to mean lack of IEEE 754 support.
6311 2013-11-05  Tobias Burnus  <burnus@net-b.de>
6313         * c.opt (-Wdate-time): New option
6314         * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
6316 2013-11-05  Joseph Myers  <joseph@codesourcery.com>
6318         * c-cppbuiltin.c (cpp_iec_559_value): Test
6319         flag_excess_precision_cmdline not flag_excess_precision.
6321 2013-11-05  Tobias Burnus  <burnus@net-b.de>
6323         * c.opt (fopenmp-simd): New option.
6324         * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
6325         (omp_pragmas): ... this new struct.
6326         (c_pp_lookup_pragma): Also walk omp_pragmas.
6327         (init_pragma): Init pragmas for -fopenmp-simd.
6329 2013-11-04  Marek Polacek  <polacek@redhat.com>
6331         PR c++/58979
6332         * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
6334 2013-11-04  Joseph Myers  <joseph@codesourcery.com>
6336         * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
6337         New functions.
6338         (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
6340 2013-11-04  Eric Botcazou  <ebotcazou@adacore.com>
6342         * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
6343         (dump_ada_specs): Adjust prototype of second callback.
6344         * c-ada-spec.c (cpp_check): New global variable.
6345         (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
6346         (print_generic_ada_decl): Likewise.
6347         (has_static_fields): Change return type to bool and add guard.
6348         (has_nontrivial_methods): New predicate.
6349         (is_tagged_type): Change return type to bool.
6350         (separate_class_package): Call has_nontrivial_methods.
6351         (pp_ada_tree_identifier): Minor tweaks.
6352         (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
6353         (dump_ada_array_domains): Likewise.
6354         (dump_ada_array_type): Likewise.
6355         (dump_template_types): Remove cpp_check parameter and do not pass it to
6356         dump_generic_ada_node.
6357         (dump_ada_template): Likewise.
6358         (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
6359         recursively.
6360         (print_ada_methods): Change return type to integer.  Remove cpp_check
6361         parameter and do not pass it down.
6362         (dump_nested_types): Remove cpp_check parameter and do not pass it to
6363         dump_generic_ada_node.
6364         (print_ada_declaration): Likewise.  Test RECORD_OR_UNION_TYPE_P before
6365         accessing methods.
6366         (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
6367         down.  Use has_nontrivial_methods to recognize C++ classes.  Use return
6368         value of print_ada_methods.
6369         (dump_ads): Rename cpp_check parameter to check and adjust prototype.
6370         Set cpp_check to it before invoking dump_ada_nodes.
6371         (dump_ada_specs): Likewise.
6373 2013-11-03  Marek Polacek  <polacek@redhat.com>
6375         * c-ubsan.c: Don't include hash-table.h.
6376         (ubsan_instrument_vla): New function.
6377         * c-ubsan.h: Declare it.
6379 2013-10-31  David Malcolm  <dmalcolm@redhat.com>
6381         Automated part of renaming of symtab_node_base to symtab_node.
6383         Patch autogenerated by rename_symtab.py from
6384         https://github.com/davidmalcolm/gcc-refactoring-scripts
6385         revision 58bb219cc090b2f4516a9297d868c245495ee622
6387         * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
6388         symtab_node_base to symtab_node.
6390 2013-10-31  Edward Smith-Rowland  <3dw4rd@verizon.net>
6392         Implement C++14 digit separators.
6393         * c-lex.c (interpret_float): Remove digit separators from scratch string
6394         before building real literal.
6396 2013-10-30  Jakub Jelinek  <jakub@redhat.com>
6398         * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
6400 2013-10-29  Balaji V. Iyer  <balaji.v.iyer@intel.com>
6402         * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
6403         fields.
6404         (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
6405         enabled.
6406         * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
6407         (insert_cilk_frame): New prototype.
6408         (cilk_init_builtins): Likewise.
6409         (gimplify_cilk_spawn): Likewise.
6410         (c_cilk_install_body_w_frame_cleanup): Likewise.
6411         (cilk_detect_spawn_and_unwrap): Likewise.
6412         (cilk_set_spawn_marker): Likewise.
6413         (build_cilk_sync): Likewise.
6414         (build_cilk_spawn): Likewise.
6415         * cilk.c: New file.
6417 2013-10-29  David Malcolm  <dmalcolm@redhat.com>
6419         Patch autogenerated by refactor_symtab.py from
6420         https://github.com/davidmalcolm/gcc-refactoring-scripts
6421         revision 58bb219cc090b2f4516a9297d868c245495ee622
6423         * c-gimplify.c (c_genericize): Update for conversion of symtab types
6424         to a true class hierarchy.
6425         * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
6427 2013-10-27  Richard Sandiford  <rdsandiford@googlemail.com>
6429         * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
6431 2013-10-26  Jeff Law  <law@redhat.com>
6433         * c-common.c (c_define_builtins): Remove mudflap support.
6434         * c.opt: Ignore and warn for mudflap options.
6436 2013-10-24  Tobias Burnus  <burnus@net-b.de>
6438         PR other/33426
6439         * c-pragma.c (init_pragma) Add #pragma ivdep handling.
6440         * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
6442 2013-10-23  Jason Merrill  <jason@redhat.com>
6444         * c-format.c (gcc_cxxdiag_char_table): Add %X.
6446 2013-10-11  Jakub Jelinek  <jakub@redhat.com>
6448         * c-common.h (omp_clause_mask::operator !=): New method.
6449         * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
6450         instead of if (mask & something) tests everywhere.
6452         * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
6453         201307 instead of 201107.
6454         * c-common.c (DEF_FUNCTION_TYPE_8): Define.
6455         (c_common_attribute_table): Add "omp declare target" and
6456         "omp declare simd" attributes.
6457         (handle_omp_declare_target_attribute,
6458         handle_omp_declare_simd_attribute): New functions.
6459         * c-omp.c: Include c-pragma.h.
6460         (c_finish_omp_taskgroup): New function.
6461         (c_finish_omp_atomic): Add swapped argument, if true,
6462         build the operation first with rhs, lhs arguments and use NOP_EXPR
6463         build_modify_expr.
6464         (c_finish_omp_for): Add code argument, pass it down to make_code.
6465         (c_omp_split_clauses): New function.
6466         (c_split_parallel_clauses): Removed.
6467         (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
6468         c_omp_declare_simd_clauses_to_decls): New functions.
6469         * c-common.h (omp_clause_mask): New type.
6470         (OMP_CLAUSE_MASK_1): Define.
6471         (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
6472         omp_clause_mask::operator |=, omp_clause_mask::operator ~,
6473         omp_clause_mask::operator |, omp_clause_mask::operator &,
6474         omp_clause_mask::operator <<, omp_clause_mask::operator >>,
6475         omp_clause_mask::operator ==): New methods.
6476         (enum c_omp_clause_split): New.
6477         (c_finish_omp_taskgroup): New prototype.
6478         (c_finish_omp_atomic): Add swapped argument.
6479         (c_finish_omp_for): Add code argument.
6480         (c_omp_split_clauses): New prototype.
6481         (c_split_parallel_clauses): Removed.
6482         (c_omp_declare_simd_clauses_to_numbers,
6483         c_omp_declare_simd_clauses_to_decls): New prototypes.
6484         * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
6485         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
6486         PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
6487         PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
6488         PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
6489         Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
6490         (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
6491         PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
6492         PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
6493         PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
6494         PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
6495         PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
6496         PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
6497         PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
6498         PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
6499         PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
6500         PRAGMA_OMP_CLAUSE_UNIFORM.
6502 2013-10-09  Marc Glisse  <marc.glisse@inria.fr>
6504         PR tree-optimization/20318
6505         * c-common.c (handle_returns_nonnull_attribute): New function.
6506         (c_common_attribute_table): Add returns_nonnull.
6508 2013-10-03  Marc Glisse  <marc.glisse@inria.fr>
6510         PR c++/19476
6511         * c.opt (fcheck-new): Move to common.opt.
6513 2013-09-25  Marek Polacek  <polacek@redhat.com>
6514             Jakub Jelinek  <jakub@redhat.com>
6516         PR sanitizer/58413
6517         * c-ubsan.c (ubsan_instrument_shift): Don't instrument
6518         an expression if we can prove it is correct.
6519         (ubsan_instrument_division): Likewise.  Remove unnecessary
6520         check.
6522 2013-09-18  Marek Polacek  <polacek@redhat.com>
6524         PR sanitizer/58411
6525         * c-common.c (handle_no_sanitize_undefined_attribute): New function.
6526         Declare it.
6527         (struct attribute_spec c_common_att): Add no_sanitize_undefined.
6529 2013-09-14  Iain Sandoe  <iain@codesourcery.com>
6531         PR target/48094
6532         * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
6533         fobjc-gc, freplace-objc-classes): Accept for LTO.
6535 2013-09-13  Jacek Caban  <jacek@codeweavers.com>
6537         * c-target.def: New hook
6539 2013-09-09  Paolo Carlini  <paolo.carlini@oracle.com>
6541         PR c++/43452
6542         * c.opt (Wdelete-incomplete): Add.
6544 2013-09-08  Joern Rennecke  <joern.rennecke@embecosm.com>
6546         * c-common.c (same_scalar_type_ignoring_signedness): Delete.
6547         (vector_types_compatible_elements_p): New function.
6548         * c-common.h: (same_scalar_type_ignoring_signedness): Delete
6549         declaration.
6550         (vector_types_compatible_elements_p): Declare.
6552 2013-09-04  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6554         * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
6555         a virtual member function.
6556         (pp_simple_type_specifier): Remove.
6557         (pp_c_type_specifier): Likewise.
6558         * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
6559         Rename from pp_c_type_specifier.  Adjust.
6560         (c_pretty_printer::c_pretty_printer): Do not assign to
6561         simple_type_specifier.
6563 2013-09-03  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6565         * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
6566         member function.
6567         (c_pretty_printer::storage_class_specifier): Likewise.
6568         (c_pretty_printer::initializer): Likewise.
6569         (pp_declaration): Remove.
6570         (pp_declaration_specifiers): Likewise.
6571         (pp_abstract_declarator): Likewise.
6572         (pp_declarator): Likewise.
6573         (pp_type_id): Likewise.
6574         (pp_statement): Likewise.
6575         (pp_constant): Likewise.
6576         (pp_id_expression): Likewise.
6577         (pp_primary_expression): Likewise.
6578         (pp_unary_expression): Likewise.
6579         (pp_multiplicative_expression): Likewise.
6580         (pp_conditional_expression): Likewise.
6581         (pp_assignment_expression): Likewise.
6582         (pp_expression): Likewise.
6583         (pp_c_type_id): Likewise.
6584         (pp_c_storage_class_specifier): Likewise.
6585         * c-pretty-print.c (pp_c_type_cast): Tidy.
6586         (pp_c_pointer): Likewise.
6587         (pp_c_type_specifier): Likewise.
6588         (pp_c_parameter_type_list): Likewise.
6589         (pp_c_function_definition): Likewise.
6590         (pp_c_init_declarator): Likewise.
6591         (pp_c_initializer_list): Likewise.
6592         (pp_c_constructor_elts): Likewise.
6593         (c_pretty_printer::direct_abstract_declarator): Likewise.
6594         (c_pretty_printer::declaration_specifiers): Likewise.
6595         (c_pretty_printer::primary_expression): Likewise.
6596         (c_pretty_printer::postfix_expression): Likewise.
6597         (c_pretty_printer::type_id): Rename from pp_c_type_id.
6598         (c_pretty_printer::storage_class_specifier): Rename from
6599         pp_c_storage_class_specifier.
6600         (c_pretty_printer::initializer): Rename from pp_c_initializer.
6601         (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
6602         storage_class_specifier, initializer, offset_list, flags.
6604 2013-08-30  Marek Polacek  <polacek@redhat.com>
6606         * c-ubsan.c: New file.
6607         * c-ubsan.h: New file.
6609 2013-08-30  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6611         * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
6612         member function.
6613         (c_pretty_printer::declaration_specifiers): Likewise.
6614         (c_pretty_printer::declarator): Likewise.
6615         (c_pretty_printer::abstract_declarator): Likewise.
6616         (c_pretty_printer::direct_abstract_declarator): Likewise.
6617         (c_pretty_printer::direct_declarator): Likewise.
6618         (c_pretty_printer::function_specifier): Likewise.
6619         (pp_declaration): Adjust.
6620         (pp_declaration_specifiers): Likewise.
6621         (pp_abstract_declarator): Likewise.
6622         (pp_direct_declarator): Likewise.
6623         (pp_function_specifier): Likewise.
6624         (pp_direct_abstract_declarator): Remove as unused.
6625         (pp_c_declaration): Remove.
6626         (pp_c_declaration_specifiers): Likewise.
6627         (pp_c_declarator): Likewise.
6628         (pp_c_direct_declarator): Likewise.
6629         (pp_c_function_specifier): Likewise.
6630         (pp_c_direct_abstract_declarator): Likewise.
6631         * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
6632         from pp_c_abstract_declarator.  Adjust.
6633         (c_pretty_printer::direct_abstract_declarator):  Rename from
6634         pp_c_direct_abstract_declarator.  Adjust.
6635         (c_pretty_printer::function_specifier): Rename from
6636         pp_c_function_specifier.  Adjust.
6637         (c_pretty_printer::declaration_specifiers): Rename from
6638         pp_c_declaration_specifiers.  Adjust.
6639         (c_pretty_printer::direct_declarator): Rename from
6640         pp_c_direct_declarator.  Adjust.
6641         (c_pretty_printer::declarator): Rename from pp_c_declarator.  Adjust.
6642         (c_pretty_printer::declaration): Rename from pp_c_declaration.  Adjust.
6643         (c_pretty_printer::c_pretty_printer): Do not assign to
6644         declaration, declaration_specifiers, declarator,
6645         direct_declarator, direct_abstract_declarator, function_specifier.
6647 2013-08-26  Gabriel Dos Reis  <gdre@integrable-solutions.net>
6649         * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
6650         virtual member function.
6651         (c_pretty_printer::multiplicative_expression): Likewise.
6652         (c_pretty_printer::conditional_expression): Likewise.
6653         (c_pretty_printer::assignment_expression): Likewise.
6654         (c_pretty_printer::expression): Likewise.
6655         (pp_unary_expression): Adjust.
6656         (pp_multiplicative_expression): Likewise.
6657         (pp_assignment_expression): Likewise.
6658         (pp_conditional_expression): Likewise.
6659         (pp_expression): Likewise.
6660         * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
6661         from pp_c_unary_expression.  Adjust.
6662         (c_pretty_printer::multiplicative_expression): Rename from
6663         pp_c_multiplicative_expression.  Adjust.
6664         (c_pretty_printer::conditional_expression): Rename from
6665         pp_c_conditional_expression.  Adjust.
6666         (c_pretty_printer::assignment_expression): Rename from
6667         pp_c_assignment_expression.  Adjust.
6668         (c_pretty_printer::expression): Rename from pp_c_expression.  Adjust.
6669         (c_pretty_printer::c_pretty_printer): Do not assign to
6670         unary_expression, multiplicative_expression,
6671         conditional_expression, expression.
6673 2013-08-25  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6675         * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
6676         virtual member function.
6677         (pp_postfix_expression): Adjust.
6678         (pp_c_postfix_expression): Remove.
6679         * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
6680         from pp_c_postfix_expression.  Adjust.
6681         (c_pretty_printer::c_pretty_printer): Do not assign to
6682         postfix_expression.
6684 2013-08-25  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6686         * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
6687         virtua member function.
6688         (pp_primary_expression): Adjust.
6689         (pp_c_primary_expression): Remove.
6690         * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
6691         from pp_c_primary_expression.  Adjust.
6692         (pp_c_initializer_list): Use pp_primary_expression.
6693         (c_pretty_printer::c_pretty_printer): Do not assign to
6694         primary_expression.
6696 2013-08-25  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6698         * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
6699         * c-pretty-print.c (M_): Remove.
6700         (c_pretty_printer::translate_string): Define.
6701         (pp_c_type_specifier): Use it.
6702         (pp_c_primary_expression): Likewise.
6703         (pp_c_expression): Likewise.
6705 2013-08-24  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6707         * c-pretty-print.h (c_pretty_printer::id_expression): Now a
6708         virtual function.
6709         (pp_c_id_expression): Remove.
6710         (pp_id_expression): Adjust.
6711         * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
6712         pp_c_id_expression.  Adjust.
6713         (pp_c_postfix_expression): Use pp_id_expression.
6714         (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
6716 2013-08-24  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6718         * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
6719         member function.
6720         (pp_constant): Adjust.
6721         (pp_c_constant): Remove.
6722         * c-pretty-print.c (c_pretty_printer::constant): Rename from
6723         pp_c_constant.  Adjust.
6724         (pp_c_constant)
6725         (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
6726         (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
6728 2013-08-22  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6730         * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
6731         (c_pretty_printer::c_pretty_printer): Declare.
6732         * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
6733         c_pretty_printer_init.  Adjust.
6734         (print_c_tree): Do not call c_pretty_printer_init.
6735         * c-ada-spec.c (dump_ads): Remove call to pp_construct.
6737 2013-08-09  Arnaud Charlet  <charlet@adacore.com>
6739         * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
6741 2013-08-05  Paolo Carlini  <paolo.carlini@oracle.com>
6743         PR c++/58080
6744         * c-common.c (pointer_int_sum): Add bool parameter.
6745         * c-common.h (pointer_int_sum): Adjust declaration.
6747 2013-08-05  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6749         * c-pretty-print.c (print_c_tree): Simplify.  Use non-static local
6750         c_pretty_printer variable.
6752 2013-08-04  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6754         * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
6755         (pp_base): Remove.
6756         (pp_c_base): Likewise.  Adjust users.
6757         * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
6758         (pp_c_whitespace): Do not call pp_base.
6759         (pp_c_left_paren): Likewise.
6760         (pp_c_right_paren): Likewise.
6761         (pp_c_left_brace): Likewise.
6762         (pp_c_right_brace): Likewise.
6763         (pp_c_left_bracket): Likewise.
6764         (pp_c_right_bracket): Likewise.
6765         (pp_c_dot): Likewise.
6766         (pp_c_ampersand): Likewise.
6767         (pp_c_star): Likewise.
6768         (pp_c_arrow): Likewise.
6769         (pp_c_semicolon): Likewise.
6770         (pp_c_complement): Likewise.
6771         (pp_c_exclamation): Likewise.
6772         (pp_c_direct_declarator): Likewise.
6773         (pp_c_ws_string): Likewise.
6774         (pp_c_identifier): Likewise.
6775         (pp_c_statement): Likewise.
6776         (print_c_tree): Likewise.
6778 2013-08-04  Ed Smith-Rowland  <3dw4rd@verizon.net>
6780         PR c++/58072
6781         * c-common.c (c_parse_error): Catch user-defined literal tokens and
6782         provide useful error strings.
6784 2013-08-03  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6786         * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
6787         printer functions instead of pp_string or operators and punctuators.
6788         (dump_generic_ada_node): Likewise.
6789         * c-pretty-print.c (pp_c_type_specifier): Likewise.
6790         (pp_c_relational_expression): Likewise.
6791         (pp_c_logical_or_expression): Likewise.
6793 2013-08-03  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6795         * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
6796         functions instead of pp_character.
6797         (pp_ada_tree_identifier): Likewise.
6798         (dump_ada_double_name): Likewise.
6799         (dump_ada_function_declaration): Likewise.
6800         (dump_ada_array_domains): Likewise.
6801         (dump_template_types): Likewise.
6802         (dump_generic_ada_node): Likewise.
6803         (print_ada_declaration): Likewise.
6804         (print_ada_struct_decl): Likewise.
6805         * c-pretty-print.c (pp_c_integer_constant): Likewise.
6807 2013-07-23  Tom Tromey  <tromey@redhat.com>
6809         * c-common.h (enum rid) <RID_GENERIC>: New constant.
6810         * c-common.c (c_common_reswords): Add _Generic.
6812 2013-07-21   Ondřej Bílka  <neleai@seznam.cz>
6814         * c-common.c: Fix typos.
6815         * c-common.h: Likewise.
6817 2013-07-13  Lubos Lunak  <l.lunak@suse.cz>
6819         PR c++/55203
6820         * c-common.c (c_common_attribute_table): Add warn_unused.
6821         (handle_warn_unused_attribute): New.
6823 2013-07-10  Jakub Jelinek  <jakub@redhat.com>
6825         * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
6826         for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
6828 2013-07-10  Paolo Carlini  <paolo.carlini@oracle.com>
6830         PR c++/57869
6831         * c.opt: Add Wconditionally-supported.
6833 2013-07-08  Graham Stott  <graham.stott@btinternet.com>
6835         * array-notation-common.c (length_mismatch_in_expr_p): Delete
6836         unused variables l_length and l_node.
6838 2013-07-04  Joern Rennecke  <joern.rennecke@embecosm.com>
6840         PR c/57821
6841         * c-common.c (complete_array_type): Delay folding first index
6842         like other indices.  When folding, check for index overflow.
6844 2013-06-27  Marc Glisse  <marc.glisse@inria.fr>
6846         PR c++/57509
6847         * c-common.h (c_build_vec_perm_expr): New complain argument.
6848         * c-common.c (c_build_vec_perm_expr): Likewise.
6849         Use save_expr also in C++.
6851 2013-06-22  Gabriel Dos Reis  <gdr@integrable-solutions.net>
6853         * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
6854         * c-cppbuiltin.c (c_cpp_builtins): Likewise.
6855         * c-opts.c (c_common_post_options): Likewise.
6857 2013-06-21  Balaji V. Iyer  <balaji.v.iyer@intel.com>
6859         * array-notation-common.c (length_mismatch_in_expr): Changed the
6860         parameter type's from a dynamic array to a vec_tree.  Also removed
6861         the size parameters.
6862         * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
6863         the change above.
6865 2013-06-21  Balaji V. Iyer  <balaji.v.iyer@intel.com>
6867         * c-common.h (struct cilkplus_an_parts): New structure.
6868         (struct cilkplus_an_loop_parts): Likewise.
6869         (cilkplus_extract_an_triplets): New prototype.
6870         (fix_sec_implicit_args): Likewise.
6871         * array-notation-common.c (cilkplus_extract_an_triplets): New function.
6872         (fix_sec_implicit_args): Likewise.
6874 2013-06-20  Balaji V. Iyer  <balaji.v.iyer@intel.com>
6876         * array-notation-common.c (find_inv_trees): Removed an unwanted
6877         typecasting.
6878         * c-common.h (struct inv_list::additional_tcodes): Changed type from
6879         enum rid to enum tree_code.
6881 2013-06-11  Jan Hubicka  <jh@suse.cz>
6883         * c-common.c (handle_alias_ifunc_attribute): Do not set
6884         DECL_EXTERNAL for weakref variables.
6885         * c-pragma.c (handle_pragma_weak): Make sure aliases
6886         are not declared as external.
6888 2013-06-07  Balaji V. Iyer  <balaji.v.iyer@intel.com>
6890         * array-notation-common.c (length_mismatch_in_expr_p): Moved this
6891         function from c/c-array-notation.c.
6892         (is_cilkplus_reduce_builtin): Likewise.
6893         (find_rank): Likewise.
6894         (extract_array_notation_exprs): Likewise.
6895         (replace_array_notations): Likewise.
6896         (find_inv_trees): Likewise.
6897         (replace_inv_trees): Likewise.
6898         (contains_array_notation_expr): Likewise.
6899         (find_correct_array_notation_type): Likewise.
6900         * c-common.h (struct inv_list): Moved this struct from the file
6901         c/c-array-notation.c and added a new field called additional tcodes.
6902         (length_mismatch_in_expr_p): New prototype.
6903         (is_cilkplus_reduce_builtin): Likewise.
6904         (find_rank): Likewise.
6905         (extract_array_notation_exprs): Likewise.
6906         (replace_array_notation): Likewise.
6907         (find_inv_trees): Likewise.
6908         (replace_inv_trees): Likewise.
6909         (find_correct_array_notation_type): Likewise.
6911 2013-05-28  Balaji V. Iyer  <balaji.v.iyer@intel.com>
6913         * c-common.c (c_define_builtins): When cilkplus is enabled, the
6914         function array_notation_init_builtins is called.
6915         (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
6916         * c-common.def (ARRAY_NOTATION_REF): New tree.
6917         * c-common.h (build_array_notation_expr): New function declaration.
6918         (build_array_notation_ref): Likewise.
6919         (extract_sec_implicit_index_arg): New extern declaration.
6920         (is_sec_implicit_index_fn): Likewise.
6921         (ARRAY_NOTATION_CHECK): New define.
6922         (ARRAY_NOTATION_ARRAY): Likewise.
6923         (ARRAY_NOTATION_START): Likewise.
6924         (ARRAY_NOTATION_LENGTH): Likewise.
6925         (ARRAY_NOTATION_STRIDE): Likewise.
6926         * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
6927         ARRAY_NOTATION_REF.
6928         (pp_c_expression): Likewise.
6929         * c.opt (flag_enable_cilkplus): New flag.
6930         * array-notation-common.c: New file.
6932 2013-05-14  Jakub Jelinek  <jakub@redhat.com>
6934         PR c++/57274
6935         * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
6937 2013-05-10  Marc Glisse  <marc.glisse@inria.fr>
6939         * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
6940         vectors.
6942 2013-05-07  Han Shen  <shenhan@google.com>
6944         * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
6946 2013-04-29  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
6948         * c-common.c (check_user_alignment): Emit error for negative values.
6950 2013-04-24  Paolo Carlini  <paolo.carlini@oracle.com>
6952         * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
6954 2013-04-24  Paolo Carlini  <paolo.carlini@oracle.com>
6956         * c-cppbuiltin.c (c_cpp_builtins): Do not define
6957         __GXX_EXPERIMENTAL_CXX1Y__.
6959 2013-04-24  Paolo Carlini  <paolo.carlini@oracle.com>
6960             Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
6962         * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
6963         * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
6964         to simply use OPT_Wpointer_arith.
6965         (c_sizeof_or_alignof_type): Likewise.
6967 2013-04-24  Paolo Carlini  <paolo.carlini@oracle.com>
6969         * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
6971 2013-04-12  Jakub Jelinek  <jakub@redhat.com>
6973         * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
6974         gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
6975         specifiers.
6977 2013-04-07  Steven Bosscher  <steven@gcc.gnu.org>
6979         * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
6981 2013-04-03  Paolo Carlini  <paolo.carlini@oracle.com>
6983         * c-common.c (pointer_int_sum): Remove dead code.
6985 2013-03-09  Richard Sandiford  <rdsandiford@googlemail.com>
6987         PR middle-end/56524
6988         * c-common.c (handle_optimize_attribute): Don't call
6989         save_optabs_if_changed.
6991 2013-03-05  Jakub Jelinek  <jakub@redhat.com>
6993         PR middle-end/56461
6994         * c-pch.c (pch_init): Free target_validity at the end.
6996 2013-03-04  Jakub Jelinek  <jakub@redhat.com>
6998         * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
7000 2013-02-28  Konstantin Serebryany  <konstantin.s.serebryany@gmail.com>
7001             Jakub Jelinek  <jakub@redhat.com>
7003         PR sanitizer/56454
7004         * c-common.c (handle_no_sanitize_address_attribute): New function.
7005         (c_common_attribute_table): Add no_sanitize_address attribute.
7006         (handle_no_address_safety_analysis_attribute): Add
7007         no_sanitize_address attribute, not no_address_safety_analysis
7008         attribute.
7010 2013-02-18  Aldy Hernandez  <aldyh@redhat.com>
7012         PR target/52555
7013         * c-common.c (handle_optimize_attribute): Call
7014         save_optabs_if_changed.
7016 2013-02-18  Jakub Jelinek  <jakub@redhat.com>
7017             Steven Bosscher  <steven@gcc.gnu.org>
7019         PR pch/54117
7020         * c-opts.c (c_common_post_options): If debug info is enabled
7021         and non-dwarf*, refuse to load PCH files and when writing PCH
7022         file warn.
7024 2013-02-05  Jakub Jelinek  <jakub@redhat.com>
7026         PR middle-end/56167
7027         * c-common.c (handle_error_attribute): Fix condition.
7029 2013-01-30  Jakub Jelinek  <jakub@redhat.com>
7031         PR c++/55742
7032         * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
7034 2013-01-18  Jason Merrill  <jason@redhat.com>
7036         PR target/54908
7037         * c.opt (-fextern-tls-init): New.
7038         * c-opts.c (c_common_post_options): Handle it.
7040 2013-01-09  Jakub Jelinek  <jakub@redhat.com>
7042         PR c/48418
7043         * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
7044         RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
7045         and is either negative or bigger or equal to type precision
7046         of the first operand.
7048 2012-12-03  Marek Polacek  <polacek@redhat.com>
7050         PR c/55570
7051         * c-common.c (check_user_alignment): Swap order of tests,
7052         check TREE_CODE first.
7054 2012-11-29  Ed Smith-Rowland  <3dw4rd@verizon.net>
7056         PR c++/52654
7057         * c-common.h (overflow_type): New enum.
7058         (build_userdef_literal): Add overflow_type argument.
7059         (tree_userdef_literal): Add overflow_type.
7060         (USERDEF_LITERAL_OVERFLOW): New access macro.
7061         * c-common.c (build_userdef_literal): Add overflow_type
7062         argument.
7063         * c-lex.c (c_lex_with_flags): Add overflow_type to
7064         build_userdef_literal calls.
7065         (interpret_integer, interpret_float): Add overflow_type argument.
7067 2012-11-28  Richard Biener  <rguenther@suse.de>
7069         PR c/35634
7070         * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
7071         here and use a type with proper overflow behavior for types that would
7072         need to be promoted for the arithmetic.
7074 2012-11-23  Jakub Jelinek  <jakub@redhat.com>
7076         PR sanitizer/55435
7077         * c-common.c (handle_no_address_safety_analysis_attribute): New
7078         function.
7079         (c_common_attribute_table): Add no_address_safety_analysis.
7081 2012-11-16  Simon Baldwin  <simonb@google.com>
7083         * c.opt: Add f[no-]canonical-system-headers.
7084         * c-opts.c (c_common_handle_option): Handle
7085         OPT_fcanonical_system_headers.
7087 2012-11-09  Ed Smith-Rowland  <3dw4rd@verizon.net>
7089         PR c++/54413
7090         * c-opts.c (c_common_handle_option): Set new flags.
7091         * c.opt: Describe new flags.
7093 2012-11-09  Jason Merrill  <jason@redhat.com>
7095         * c.opt (Wabi-tag): New.
7097 2012-11-09  Andi Kleen  <ak@linux.intel.com>
7099         PR 55139
7100         * c-common.c (get_atomic_generic_size): Mask with
7101         MEMMODEL_MASK
7103 2012-11-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7105         PR c/53063
7106         * c.opt (Wformat): Make it Alias Wformat=1.
7107         (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
7108         Wformat-security,Wformat-y2k,Wformat-zero-length): Use
7109         LangEnabledBy.
7110         (Wformat=): RejectNegative. Use LangEnabledBy.
7111         (Wnonnull): Use LangEnabledBy.
7112         * c-opts.c (c_common_handle_option): Do not handle Wformat here.
7113         * c-format.c (set_Wformat): Delete.
7114         (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
7115         (maybe_read_dollar_number):  Likewise.
7116         (avoid_dollar_number):  Likewise.
7117         (finish_dollar_format_checking):  Likewise.
7118         (check_format_info):  Likewise.
7119         (check_format_info_main):  Likewise.
7120         (check_format_types):  Likewise.
7121         (format_type_warning):  Likewise.
7122         * c-common.c (int):  Likewise.
7123         (check_function_sentinel):  Likewise.
7124         * c-common.h (warn_format,set_Wformat): Do not declare here.
7126 2012-11-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7128         PR c/53063
7129         * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
7130         Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
7131         Use LangEnabledBy.
7132         (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
7133         common.opt.
7134         (Wvariadic-macros): Init(1).
7135         * c-opts.c (c_common_handle_option): Do not handle them
7136         explicitly.
7137         (c_common_post_options): Likewise.
7138         (sanitize_cpp_opts): warn_unused_macros is now
7139         cpp_warn_unused_macros.
7140         (push_command_line_include): Likewise.
7141         * c-common.c (warn_unknown_pragmas): Do not define.
7142         * c-common.h (warn_unknown_pragmas): Do not declare.
7144 2012-11-07  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7146         PR c/51294
7147         * c-common.c (conversion_warning): Handle conditional expressions.
7149 2012-10-29  Jonathan Wakely  <jwakely.gcc@gmail.com>
7151         PR c++/54930
7152         * c.opt (Wreturn_local_addr): Define new option.
7154 2012-10-25  Jason Merrill  <jason@redhat.com>
7156         * c.opt (Wvirtual-move-assign): New.
7158         * c.opt (Winherited-variadic-ctor): New.
7160 2012-10-25  Marc Glisse  <marc.glisse@inria.fr>
7162         PR c++/54427
7163         * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
7165 2012-10-23  Joseph Myers  <joseph@codesourcery.com>
7167         * c-common.h (pch_cpp_save_state): Declare.
7168         * c-target.def (c_preinclude): New hook.
7169         * c-opts.c (done_preinclude): New.
7170         (push_command_line_include): Handle default preincluded header.
7171         (cb_file_change): Call pch_cpp_save_state when calling
7172         push_command_line_include.
7173         * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
7174         (pch_cpp_save_state): New.
7175         (pch_init): Call pch_cpp_save_state conditionally, instead of
7176         calling cpp_save_state.
7178 2012-10-20  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7180         PR c/53063
7181         PR c/40989
7182         * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
7183         Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
7184         Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
7185         Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
7186         Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
7187         * c-opts.c (c_common_handle_option): Remove explicit handling from
7188         here.
7189         (c_common_post_options): Likewise.
7191 2012-10-18  Eric Botcazou  <ebotcazou@adacore.com>
7193         * c-ada-spec.c (LOCATION_COL): Delete.
7194         (compare_location): New function.
7195         (compare_node): Use it.
7196         (compare_comment): Likewise.
7198 2012-10-16  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7200         PR c/53063
7201         PR c/40989
7202         * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
7203         * c-opts.c (c_common_handle_option): Do not set them here. Add
7204         comment.
7205         (c_common_post_options): Likewise.
7207 2012-10-16  Eric Botcazou  <ebotcazou@adacore.com>
7209         * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
7210         (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
7211         Remove POINTER_TYPE handling, add large unsigned handling and use
7212         ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
7214 2012-10-12  Jakub Jelinek  <jakub@redhat.com>
7216         PR c/54381
7217         * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
7218         * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
7219         locs and array of 3 trees instead of just single loc and single
7220         sizeof_arg tree.  Handle __builtin___*_chk builtins too, and
7221         also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
7222         For *cmp* builtins that take two sources strings report warnings
7223         about first and second source, not about destination and source.
7225 2012-10-12  Marc Glisse  <marc.glisse@inria.fr>
7227         PR c++/53055
7228         * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
7230 2012-10-11  Eric Botcazou  <ebotcazou@adacore.com>
7232         * c-ada-spec.c (dump_ada_template): Bail out for template declarations
7233         declaring something coming from another file.
7235 2012-10-10  Arnaud Charlet  <charlet@adacore.com>
7237         PR ada/54845
7238         * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
7240 2012-10-09  Paolo Carlini  <paolo.carlini@oracle.com>
7242         PR c++/54194
7243         * c-common.c (warn_about_parentheses): Add location_t parameter;
7244         use EXPR_LOC_OR_LOC.
7245         * c-common.h: Update declaration.
7247 2012-10-09  Marc Glisse  <marc.glisse@inria.fr>
7249         PR c++/54427
7250         * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
7251         more operations. Make error messages optional.
7252         * c-common.h (enum stv_conv): Moved from c-typeck.c.
7253         (scalar_to_vector): Declare.
7255 2012-10-08  Jason Merrill  <jason@redhat.com>
7257         * c-common.c (c_common_reswords): Add thread_local.
7259 2012-10-08  Dodji Seketeli  <dodji@redhat.com>
7261         PR c++/53528 C++11 attribute support
7262         * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
7263         new functions.
7264         * c-common.c (check_cxx_fundamental_alignment_constraints): New
7265         static function.
7266         (handle_aligned_attribute): In choose strictest alignment
7267         among many.  Use new check_cxx_fundamental_alignment_constraints.
7268         (handle_transparent_union_attribute): In c++11 attribute syntax,
7269         don't look through typedefs.
7271 2012-10-04  Arnaud Charlet  <charlet@adacore.com>
7273         * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
7274         * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
7275         out of dumpfile.h.
7277 2012-09-25  Dehao Chen  <dehao@google.com>
7279         PR middle-end/54645
7280         * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
7281         map when read in the pch.
7283 2012-09-18  Arnaud Charlet  <charlet@adacore.com>
7285         * c-ada-spec.c: Style fixes.
7287 2012-09-18  Thomas Quinot  <quinot@adacore.com>
7289         * c.opt (-fada-spec-parent): Define new command line switch.
7290         * c-ada-spec.c (get_ada_package): When -fada-spec-parent
7291         is specified, generate binding spec as a child of the specified unit.
7293 2012-09-13  Paolo Carlini  <paolo.carlini@oracle.com>
7294             Manuel López-Ibáñez  <manu@gcc.gnu.org>
7296         PR c++/53210
7297         * c.opt ([Winit-self]): Enabled by -Wall in C++.
7299 2012-08-23  Arnaud Charlet  <charlet@adacore.com>
7301         * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
7302         for pointers, and add missing Convention C pragma.
7303         (print_ada_struct_decl): Add missing aliased keyword.
7304         (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
7306 2012-08-17  Jakub Jelinek  <jakub@redhat.com>
7308         * c-common.c (sizeof_pointer_memaccess_warning): New function.
7309         * c.opt (-Wsizeof-pointer-memaccess): Add new option.
7310         * c-opts.c (c_common_handle_option): Enable it for -Wall.
7311         * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
7312         * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
7314 2012-08-10  Richard Guenther  <rguenther@suse.de>
7316         * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
7318 2012-08-07  Steven Bosscher  <steven@gcc.gnu.org>
7320         * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
7321         instead of separate pp_newline and pp_flush.
7322         (print_c_tree): Likewise.
7324 2012-07-26  Richard Henderson  <rth@redhat.com>
7326         * c-common.c (handle_hot_attribute): Allow labels.
7327         (handle_cold_attribute): Likewise.
7329 2012-07-20  Jakub Jelinek  <jakub@redhat.com>
7331         PR c++/28656
7332         * c-common.c (check_function_nonnull): Handle multiple nonnull
7333         attributes properly.
7335 2012-07-16  Steven Bosscher  <steven@gcc.gnu.org>
7337         * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
7338         * c-ada-spec.c: Likewise.
7339         * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
7341 2012-07-14  Steven Bosscher  <steven@gcc.gnu.org>
7343         * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
7344         Remove code conditional on it.
7346 2012-07-11  Steven Bosscher  <steven@gcc.gnu.org>
7348         * c-gimplify.c: Do not include basic-block.h.
7349         * c-common.c: Do not include linfuncs.h.
7351 2012-07-08  Steven Bosscher  <steven@gcc.gnu.org>
7353         * c-common.h: Include tree.h.
7355 2012-07-02  Jason Merrill  <jason@redhat.com>
7357         PR c++/53524
7358         * c-common.c (get_priority): Call default_conversion.
7360 2012-07-01  Uros Bizjak  <ubizjak@gmail.com>
7362         * c-pch.c (c_common_write_pch): Remove unused variables.
7364 2012-06-29  Steven Bosscher  <steven@gcc.gnu.org>
7366         * cppspec.c: Moved from gcc/ to here.
7368 2012-06-27  Kai Tietz  <ktietz@redhat.com>
7370         PR preprocessor/37215
7371         * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
7373 2012-06-21  Steven Bosscher  <steven@gcc.gnu.org>
7375         * c-common.h (c_common_print_pch_checksum): Remove.
7376         * c-pch.c: Do not include output.h.
7377         (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
7378         (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
7379         (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
7380         (struct c_pch_header): Remove.
7381         (get_ident): Update gpch version.
7382         (pch_init): Do not print executable_checksum to asm_out_file.
7383         Do not fail if there is no asm_out_file to read back from.  Set
7384         asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
7385         (c_common_write_pch): Verify that nothing was written to asm_out_file
7386         since pch_init was called.  Do not write a c_pch_header, and do not
7387         copy from asm_out_file to the PCH.
7388         (c_common_read_pch): Do not read a c_pch_header, and do not restore
7389         the content of asm_out_file from the PCH.
7390         (c_common_print_pch_checksum): Remove.
7391         * c-opts.c (c_common_init): Print out executable_checksum directly.
7393 2012-06-19  Steven Bosscher  <steven@gcc.gnu.org>
7395         * c-target.def (objc_declare_unresolved_class_reference,
7396         objc_declare_class_definition): Add new hooks.
7398 2012-06-19  Steven Bosscher  <steven@gcc.gnu.org>
7400         * c-lex.c: Do not include output.h.
7401         (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
7402         Remove uses of ASM_OUTPUT_IDENT.
7404 2012-06-15  Marc Glisse  <marc.glisse@inria.fr>
7406         PR c++/51033
7407         * c-common.h (c_build_vec_perm_expr): Move decl here.
7408         * c-common.c (c_build_vec_perm_expr): Move definition
7409         here.
7411 2012-06-06  Steven Bosscher  <steven@gcc.gnu.org>
7413         * c.opt (fconserve-space): Turn into a no-op.
7415 2012-06-04  Sterling Augustine  <saugustine@google.com>
7417         * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
7418         * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
7419         both the start and end of the function.
7421 2012-06-04  Steven Bosscher  <steven@gcc.gnu.org>
7423         * c-common.c: Do not include output.h.
7424         * c-pragma.c: Likewise.
7426 2012-06-04  Steven Bosscher  <steven@gcc.gnu.org>
7428         * error.c (dump_decl): Check pp_c_flag_gnu_v3.
7429         (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
7430         (lang_decl_name): Handle namespace decls.
7432 2012-05-31  Steven Bosscher  <steven@gcc.gnu.org>
7434         * c-ada-spec.c: Do not include output.h.
7435         * c-semantics.c: Likewise.
7437 2012-05-29  Joseph Myers  <joseph@codesourcery.com>
7439         * c-common.c: Fix typo.
7441 2012-05-29  Michael Matz  <matz@suse.de>
7443         * c-common.h (c_expand_decl): Remove prototype.
7445 2012-05-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7447         * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
7448         * c-opts.c (c_common_handle_option): Remove code handling
7449         warn_missing_braces.
7451 2012-05-28  Paolo Carlini  <paolo.carlini@oracle.com>
7453         PR c++/25137
7454         * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
7455         -Wmissing_braces.
7457 2012-05-22  Dodji Seketeli  <dodji@redhat.com>
7459         PR c++/53322
7460         * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
7462 2012-05-17  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7464         * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
7465         * c-opts.c (c_common_handle_option): Do not handle explicitly
7466         Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
7468 2012-05-16  Dodji Seketeli  <dodji@redhat.com>
7470         PR preprocessor/7263
7471         * c-lex.c (c_lex_with_flags):  Pass a virtual location to the call
7472         to cpp_classify_number.  For diagnostics, use the precise location
7473         instead of the global input_location.
7475 2012-05-15  Paolo Carlini  <paolo.carlini@oracle.com>
7477         PR c++/11856
7478         * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
7480 2012-05-14  Bernd Schmidt  <bernds@codesourcery.com>
7482         * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
7484 2012-05-14  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7486         PR 53063
7487         * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
7488         Wreorder): Use LangEnabledBy.
7489         * c-opts.c (c_common_handle_option): Do not enable them
7490         explicitly. Call lang-specific generated functions.
7491         (c_common_post_options): Do not set them here.
7493 2012-05-13  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7495         * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
7496         Wmissing-field-initializers,Wmissing-parameter-type,
7497         Wold-style-declaration,Woverride-init): Use EnabledBy.
7498         * c-opts.c (c_common_post_options): Do not set here explicitly.
7500 2012-05-11  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7502         PR 53063
7503         * c-opts.c (c_common_handle_option): Use handle_generated_option
7504         to enable sub-options.
7506 2012-05-10  Paolo Carlini  <paolo.carlini@oracle.com>
7508         PR c++/53158
7509         * c-common.c (warnings_for_convert_and_check): Use warning_at.
7511 2012-05-10  Richard Guenther  <rguenther@suse.de>
7513         * c-common.c (c_sizeof_or_alignof_type): Remove assert and
7514         adjust commentary about TYPE_IS_SIZETYPE types.
7516 2012-05-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7518         PR c++/53261
7519         * c-common.c (warn_logical_operator): Check that argument of
7520         integer_zerop is not NULL.
7522 2012-05-05  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7524         PR c/43772
7525         * c-common.c (warn_logical_operator): Do not warn if either side
7526         is already true or false.
7528 2012-05-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7530         PR c/51712
7531         * c-common.c (expr_original_type): New.
7532         (shorten_compare): Do not warn for enumeration types.
7534 2012-05-03  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7536         * c.opt (fpermissive): Add Var(flag_permissive).
7538 2012-04-30  Marc Glisse  <marc.glisse@inria.fr>
7540         PR c++/51033
7541         * c-common.c (convert_vector_to_pointer_for_subscript): New function.
7542         * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
7544 2012-04-30  Dodji Seketeli  <dodji@redhat.com>
7546         Add -Wvarargs option
7547         * c.opt (Wvarargs):  Define new option.
7549 2012-04-30  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7551         * c-common.c (check_function_arguments): Replace
7552         Wmissing-format-attribute with Wsuggest-attribute=format.
7554 2012-04-30  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7556         * c.opt (Wsuggest-attribute=format): New. Alias of
7557         Wmissing-format-attribute.
7558         * c-format.c (decode_format_type): Replace
7559         Wmissing-format-attribute with Wsuggest-attribute=format.
7560         (check_function_format): Likewise.
7562 2012-04-27  Ollie Wild  <aaw@google.com>
7564         * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
7565         * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
7566         * c.opt: Add Wliteral-suffix.
7568 2012-04-22  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7570         PR c/44774
7571         * c.opt (Wpedantic): New.
7572         (pedantic): Alias Wpedantic.
7573         * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
7574         (c_common_post_options): Likewise.
7575         (sanitize_cpp_opts): Likewise.
7576         * c-lex.c (interpret_float): Likewise.
7577         * c-format.c (check_format_types): Likewise.
7578         * c-common.c (pointer_int_sum): Likewise.
7579         (c_sizeof_or_alignof_type): Likewise.
7580         (c_add_case_label): Likewise.
7581         (c_do_switch_warnings): Likewise.
7582         * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
7584 2012-04-15  Jason Merrill  <jason@redhat.com>
7586         PR c++/52818
7587         * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
7588         (C_STD_NAME): Distinguish between C++98 and C++11.
7590 2012-04-11  Eric Botcazou  <ebotcazou@adacore.com>
7592         PR target/52624
7593         * c-common.h (uint16_type_node): Rename into...
7594         (c_uint16_type_node): ...this.
7595         * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
7596         * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
7598 2012-04-10  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7600         * c-common.c (warn_if_unused_value): Move definition to here.
7601         * c-common.h (warn_if_unused_value): Move declaration to here.
7603 2012-03-23  William Bader  <williambader@hotmail.com>
7605         * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
7607 2012-03-20  Jason Merrill  <jason@redhat.com>
7609         * c-common.h (enum cxx_dialect): Add cxx1y.
7610         * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
7611         test.
7612         * c-cppbuiltin.c (c_cpp_builtins): Likewise.
7613         * c-opts.c (c_common_post_options): Likewise.
7614         (set_std_cxx1y): New.
7615         (c_common_handle_option): Call it.
7616         * c.opt (-std=c++1y, -std=gnu++1y): New flags.
7618 2012-03-19  Paolo Carlini  <paolo.carlini@oracle.com>
7620         PR c++/14710
7621         * c.opt ([Wuseless-cast]): Add.
7623 2012-03-16  Richard Guenther  <rguenther@suse.de>
7625         * c-pretty-print.c (pp_c_initializer_list): Adjust.
7627 2012-03-15  Manuel López-Ibáñez  <manu@gcc.gnu.org>
7629         PR c++/44783
7630         * c.opt (ftemplate-backtrace-limit) Add.
7632 2012-03-12  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
7634         * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
7635         handling.
7636         * c-pragma.c (handle_pragma_extern_prefix): Remove.
7637         (init_pragma): Don't register extern_prefix.
7639 2012-03-12  Richard Guenther  <rguenther@suse.de>
7641         * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
7642         (builtin_type_for_size): Likewise.
7644 2012-02-13  Jakub Jelinek  <jakub@redhat.com>
7646         PR c++/52215
7647         * c-common.c (sync_resolve_params): Don't decide whether to convert
7648         or not based on TYPE_SIZE comparison, convert whenever arg_type
7649         is unsigned INTEGER_TYPE.
7651 2012-02-06  Paolo Carlini  <paolo.carlini@oracle.com>
7653         PR c/52118
7654         * c.opt ([Wunused-local-typedefs]): Fix description.
7656 2012-01-24  Mike Stump  <mikestump@comcast.net>
7658         * c-common.c (c_common_type_for_mode): Match signed/unsigned types
7659         exactly.
7661 2012-01-18  Richard Guenther  <rguenther@suse.de>
7663         * c-opts.c (c_common_post_options): Reset LTO flags if
7664         we are about to generate a PCH.
7666 2012-01-17  Paolo Carlini  <paolo.carlini@oracle.com>
7668         PR c++/51777
7669         * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
7670         use pp_unsigned_wide_integer.
7672 2012-01-10  Richard Guenther  <rguenther@suse.de>
7674         PR middle-end/51806
7675         * c-opts.c (c_common_handle_option): Move -Werror handling
7676         to language independent code.
7678 2012-01-05  Richard Guenther  <rguenther@suse.de>
7680         PR middle-end/51764
7681         * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
7682         from common.opt.
7684 2011-12-30  Paolo Carlini  <paolo.carlini@oracle.com>
7686         PR c++/51316
7687         * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
7688         of array types with an unknown bound.
7690 2011-12-20  Joseph Myers  <joseph@codesourcery.com>
7692         * c-common.c (flag_isoc99): Update comment to refer to C11.
7693         (flag_isoc1x): Change to flag_isoc11.
7694         * c-common.h (flag_isoc99): Update comment to refer to C11.
7695         (flag_isoc1x): Change to flag_isoc11.
7696         * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
7697         C11.
7698         * c-opts.c (set_std_c1x): Change to set_std_c11.
7699         (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
7700         Call set_std_c11.
7701         (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
7702         (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
7703         * c.opt (std=c1x): Change to std=c11.  Document as non-draft
7704         standard.
7705         (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
7706         (std=gnu1x): Change to std=gnu11.  Refer to non-draft standard.
7707         (std=gnu1x): Make alias of std=gnu11.
7709 2011-12-19  Jason Merrill  <jason@redhat.com>
7711         PR c++/51228
7712         * c-common.c (handle_transparent_union_attribute): Check the first
7713         field if the type is complete.
7715 2011-12-15  Jonathan Wakely  <jwakely.gcc@gmail.com>
7717         PR libstdc++/51365
7718         * c-common.c (RID_IS_FINAL): Add.
7719         * c-common.h (RID_IS_FINAL): Add.
7721 2011-11-30  Iain Sandoe  <iains@gcc.gnu.org>
7723         * c.opt (fgnu-runtime): Provide full description.
7724         (fnext-runtime): Likewise.
7725         * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
7727 2011-11-28  Andrew MacLeod  <amacleod@redhat.com>
7729         * c-cpp-builtin.c (cpp_atomic_builtins):New.  Emit all atomic
7730         predefines in one place.  Add LOCK_FREE predefines.
7731         (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
7732         new func.
7734 2011-11-24  Andrew MacLeod  <amacleod@redhat.com>
7736         PR c/51256
7737         * c-common.c (get_atomic_generic_size): Check for various error
7738         conditions
7739         (resolve_overloaded_atomic_exchange,
7740         resolve_overloaded_atomic_compare_exchange,
7741         resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
7742         error_mark_node for error conditions.
7744 2011-11-08  Richard Guenther  <rguenther@suse.de>
7746         PR middle-end/51010
7747         c-family/
7749 2011-11-07  Richard Henderson  <rth@redhat.com>
7750             Aldy Hernandez  <aldyh@redhat.com>
7751             Torvald Riegel  <triegel@redhat.com>
7753         Merged from transactional-memory.
7755         * c-common.c (handle_tm_wrap_attribute,
7756         handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
7757         (struct c_common_reswords): Added __transaction* keywords.
7758         (struct c_common_attribute_table): Added transaction* and tm_regparm
7759         attributes.
7760         * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
7761         masks.
7762         (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
7763         find_tm_attribute): Declare.
7765 2011-11-07  Jason Merrill  <jason@redhat.com>
7767         PR c++/35688
7768         * c-common.c, c-common.h: Revert yesterday's changes.
7770 2011-11-06  Jason Merrill  <jason@redhat.com>
7772         PR c++/35688
7773         * c-common.c (decl_has_visibility_attr): Split out from...
7774         (c_determine_visibility): ...here.
7775         * c-common.h: Declare it.
7777 2011-11-06  Joseph Myers  <joseph@codesourcery.com>
7779         * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
7780         (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
7781         type.
7782         (check_user_alignment): New.  Split out of
7783         handle_aligned_attribute.  Disallow integer constants with
7784         noninteger types.  Conditionally allow zero.
7785         (handle_aligned_attribute): Use check_user_alignment.
7786         * c-common.h (RID_ALIGNAS, check_user_alignment): New.
7788 2011-11-06  Andrew MacLeod  <amacleod@redhat.com>
7789             Richard Henderson  <rth@redhat.com>
7791         Merged from cxx-mem-model.
7793         * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
7794         * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
7795         parameters that are the same type size.
7796         (get_atomic_generic_size): New.  Find size of generic
7797         atomic function parameters and do typechecking.
7798         (add_atomic_size_parameter): New.  Insert size into parameter list.
7799         (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
7800         either __atomic_exchange_n or external library call.
7801         (resolve_overloaded_atomic_compare_exchange): Restructure
7802         __atomic_compare_exchange to either _n variant or external library call.
7803         (resolve_overloaded_atomic_load): Restructure __atomic_load to either
7804         __atomic_load_n or an external library call.
7805         (resolve_overloaded_atomic_store): Restructure __atomic_store to either
7806         __atomic_store_n or an external library call.
7807         (resolve_overloaded_builtin): Handle new __atomic builtins.
7809 2011-11-04  Eric Botcazou  <ebotcazou@adacore.com>
7811         PR c++/50608
7812         * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
7813         (fold_offsetof_1): Make global.  Remove STOP_REF argument and adjust.
7814         <INDIRECT_REF>: Return the argument.
7815         <ARRAY_REF>: Remove special code for negative offset.
7816         Call fold_build_pointer_plus instead of size_binop.
7817         (fold_offsetof): Remove STOP_REF argument and adjust.
7818         * c-common.h (fold_offsetof_1): Declare.
7819         (fold_offsetof): Remove STOP_REF argument.
7821 2011-11-02  Paolo Carlini  <paolo.carlini@oracle.com>
7823         PR c++/50810
7824         * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7825         of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7826         Wnarrowing for C++0x and C++98.
7827         * c.opt ([Wnarrowing]): Update.
7829 2011-11-01  Paolo Carlini  <paolo.carlini@oracle.com>
7831         PR c++/44277
7832         * c.opt: Add Wzero-as-null-pointer-constant.
7834 2011-10-31  Jason Merrill  <jason@redhat.com>
7836         * c.opt (-fdeduce-init-list): Off by default.
7838         PR c++/50920
7839         * c-common.h (cxx_dialect): Add cxx11 and cxx03.
7840         * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
7841         and -Wc++11-compat.
7842         * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
7844 2011-10-27  Roberto Agostino Vitillo  <ravitillo@lbl.gov>
7846         PR c++/30066
7847         * c.opt (fvisibility-inlines-hidden): Description change.
7849 2011-10-26  Ed Smith-Rowland  <3dw4rd@verizon.net>
7851         Implement C++11 user-defined literals.
7852         * c-common.c (build_userdef_literal): New.
7853         * c-common.def: New tree code.
7854         * c-common.h (tree_userdef_literal): New tree struct and accessors.
7855         * c-lex.c (interpret_float): Add suffix parm.
7856         (c_lex_with_flags): Build literal tokens.
7858 2011-10-23  Paolo Carlini  <paolo.carlini@oracle.com>
7860         PR c++/50841
7861         Revert:
7862         2011-10-23  Paolo Carlini  <paolo.carlini@oracle.com>
7864         PR c++/50810
7865         * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7866         of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7867         Wnarrowing for C++0x and C++98.
7868         * c.opt ([Wnarrowing]): Update.
7870 2011-10-23  Paolo Carlini  <paolo.carlini@oracle.com>
7872         PR c++/50810
7873         * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7874         of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7875         Wnarrowing for C++0x and C++98.
7876         * c.opt ([Wnarrowing]): Update.
7878 2011-10-21  Paolo Carlini  <paolo.carlini@oracle.com>
7880         PR c++/45385
7881         * c-common.c (conversion_warning): Remove code looking for
7882         artificial operands.
7884 2011-10-18  Dodji Seketeli  <dodji@redhat.com>
7886         PR bootstrap/50760
7887         * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
7888         !NO_IMPLICIT_EXTERN_C.
7890 2011-10-17  Michael Spertus  <mike_spertus@symantec.com>
7892         * c-common.c (c_common_reswords): Add __bases,
7893         __direct_bases.
7894         * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
7896 2011-10-17  Paolo Carlini  <paolo.carlini@oracle.com>
7898         PR c++/50757
7899         * c.opt ([Wnonnull]): Add C++ and Objective-C++.
7901 2011-10-15  Tom Tromey  <tromey@redhat.com>
7902             Dodji Seketeli  <dodji@redhat.com>
7904         * c.opt (fdebug-cpp): New option.
7905         * c-opts.c (c_common_handle_option): Handle the option.
7906         * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
7907         output stream in parameter. Factorized from ...
7908         (maybe_print_line): ... this. Dump location debug information when
7909         -fdebug-cpp is in effect.
7910         (print_line_1): New static function. Takes an output stream in
7911         parameter. Factorized from ...
7912         (print_line): ... here. Dump location information when -fdebug-cpp
7913         is in effect.
7914         (scan_translation_unit): Dump location information when
7915         -fdebug-cpp is in effect.
7917 2011-10-15  Tom Tromey  <tromey@redhat.com>
7918             Dodji Seketeli  <dodji@redhat.com>
7920         * c.opt (ftrack-macro-expansion): New option. Handle it with and
7921         without argument.
7922         * c-opts.c (c_common_handle_option)<case
7923         OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
7924         cases. Handle -ftrack-macro-expansion with and without argument.
7926 2011-10-15  Tom Tromey  <tromey@redhat.com>
7927             Dodji Seketeli  <dodji@redhat.com>
7929         * c-ppoutput.c (scan_translation_unit, maybe_print_line)
7930         (print_line, cb_define, do_line_change): Adjust to avoid touching
7931         the internals of struct line_map.  Use the public API instead.
7932         * c-pch.c (c_common_read_pch): Likewise.
7933         * c-lex.c (fe_file_change): Likewise.
7935 2011-10-14  Paolo Carlini  <paolo.carlini@oracle.com>
7937         PR c++/17212
7938         * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
7940 2011-10-11  Paolo Carlini  <paolo.carlini@oracle.com>
7942         PR c++/33067
7943         * c-pretty-print.c (pp_c_floating_constant): Output
7944         max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
7946 2011-10-11  Michael Meissner  <meissner@linux.vnet.ibm.com>
7948         * c-common.c (def_builtin_1): Delete old interface with two
7949         parallel arrays to hold standard builtin declarations, and replace
7950         it with a function based interface that can support creating
7951         builtins on the fly in the future.  Change all uses, and poison
7952         the old names.  Make sure 0 is not a legitimate builtin index.
7953         * c-omp.c (c_finish_omp_barrier): Ditto.
7954         (c_finish_omp_taskwait): Ditto.
7955         (c_finish_omp_flush): Ditto.
7957 2011-10-11  Tristan Gingold  <gingold@adacore.com>
7959         * c.opt: (fallow-parameterless-variadic-functions): New.
7961 2011-09-08  Dodji Seketeli  <dodji@redhat.com>
7963         PR c++/33255 - Support -Wunused-local-typedefs warning
7964         * c-common.h (struct c_language_function::local_typedefs): New
7965         field.
7966         (record_locally_defined_typedef, maybe_record_typedef_use)
7967         (maybe_warn_unused_local_typedefs): Declare new functions.
7968         * c-common.c (record_locally_defined_typedef)
7969         (maybe_record_typedef_use)
7970         (maybe_warn_unused_local_typedefs): Define new functions.
7971         * c.opt: Declare new -Wunused-local-typedefs flag.
7973 2011-09-06  Eric Botcazou  <ebotcazou@adacore.com>
7975         PR middle-end/50266
7976         * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
7977         computations.
7979 2011-09-05  Richard Guenther  <rguenther@suse.de>
7981         * c-common.c (complete_array_type): Use ssize_int (-1) instead
7982         of integer_minus_one_node for empty array upper bounds.
7984 2011-08-28  Dodji Seketeli  <dodji@redhat.com>
7986         * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
7987         it's the first time it's being called on this main TU.
7989 2011-08-24  Richard Guenther  <rguenther@suse.de>
7991         PR c/49396
7992         * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
7994 2011-08-22  Gabriel Charette  <gchare@google.com>
7996         * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
7997         defined in cpp_init_builtins and c_cpp_builtins.
7999 2011-08-19  Joseph Myers  <joseph@codesourcery.com>
8001         * c-common.c (c_common_reswords): Add __builtin_complex.
8002         * c-common.h (RID_BUILTIN_COMPLEX): New.
8004 2011-08-18  Joseph Myers  <joseph@codesourcery.com>
8006         * c-common.c (c_common_reswords): Add _Noreturn.
8007         (keyword_is_function_specifier): Handle RID_NORETURN.
8008         * c-common.h (RID_NORETURN): New.
8010 2011-08-10  Artjoms Sinkarovs  <artyom.shinakroff@gmail.com>
8012         * c-common.c (unsafe_conversion_p): New function. Check if it is
8013         unsafe to convert an expression to the type.
8014         (conversion_warning): Adjust, use unsafe_conversion_p.
8015         * c-common.h (unsafe_conversion_p): New function declaration.
8017 2011-08-02  Jakub Jelinek  <jakub@redhat.com>
8019         * c-common.h (c_finish_omp_atomic): Adjust prototype.
8020         (c_finish_omp_taskyield): New prototype.
8021         * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
8022         arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
8023         OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC.  If LHS1
8024         or RHS1 have side-effects, evaluate those too in the right spot,
8025         if it is a decl and LHS is also a decl, error out if they
8026         aren't the same.
8027         (c_finish_omp_taskyield): New function.
8028         * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
8029         * c-pragma.c (omp_pragmas): Add taskyield.
8030         * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
8031         (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
8032         PRAGMA_OMP_CLAUSE_MERGEABLE.
8034 2011-07-25  Dodji Seketeli  <dodji@redhat.com>
8036         * c-common.h (set_underlying_type): Remove parm name from
8037         declaration.
8039 2011-07-25  Romain Geissler  <romain.geissler@gmail.com>
8041         * c-pretty-print.h: Search c-common.h in c-family.
8043 2011-07-22  Jason Merrill  <jason@redhat.com>
8045         PR c++/49793
8046         * c.opt (Wnarrowing): New.
8048         PR c++/30112
8049         * c-common.h: Declare c_linkage_bindings.
8050         * c-pragma.c (handle_pragma_redefine_extname): Use it.
8052         PR c++/49813
8053         * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
8054         * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
8055         as flag_isoc99 for 'restrict'.
8056         (pp_c_specifier_qualifier_list): Likewise for _Complex.
8058 2011-07-21  Ian Lance Taylor  <iant@google.com>
8060         PR middle-end/49705
8061         * c-common.c (c_disable_warnings): New static function.
8062         (c_enable_warnings): New static function.
8063         (c_fully_fold_internal): Change local unused_p to bool.  Call
8064         c_disable_warnings and c_enable_warnings rather than change
8065         c_inhibit_evaluation_warnings.
8067 2011-07-20  Jason Merrill  <jason@redhat.com>
8069         PR c++/6709 (DR 743)
8070         PR c++/42603 (DR 950)
8071         * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
8072         (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
8073         (CPP_DECLTYPE): New.
8074         * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
8076 2011-07-19  Richard Guenther  <rguenther@suse.de>
8078         * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
8079         * c-omp.c (c_finish_omp_for): Likewise.
8081 2011-07-12  Eric Botcazou  <ebotcazou@adacore.com>
8083         * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
8084         body on the next line.
8086 2011-07-08  Jason Merrill  <jason@redhat.com>
8088         PR c++/45437
8089         * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
8091         PR c++/49673
8092         * c-common.c (c_apply_type_quals_to_decl): Don't check
8093         TYPE_NEEDS_CONSTRUCTING.
8095 2011-07-06  Richard Guenther  <rguenther@suse.de>
8097         * c-common.c (c_common_nodes_and_builtins):
8098         Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
8100 2011-07-05  Richard Guenther  <rguenther@suse.de>
8102         * c-common.c (c_common_nodes_and_builtins): Build all common
8103         tree nodes first.
8105 2011-06-27  Jakub Jelinek  <jakub@redhat.com>
8107         * c-common.h (c_tree_chain_next): New static inline function.
8109         * c-common.c (check_builtin_function_arguments): Handle
8110         BUILT_IN_ASSUME_ALIGNED.
8112 2011-06-21  Andrew MacLeod  <amacleod@redhat.com>
8114         * c-common.c: Add sync_ or SYNC__ to builtin names.
8115         * c-omp.c: Add sync_ or SYNC__ to builtin names.
8117 2011-06-20  Pierre Vittet  <piervit@pvittet.com>
8119         * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
8120         handler.
8121         (gen_pragma_handler): New union.
8122         (internal_pragma_handler): New type.
8123         (c_register_pragma_with_data)
8124         (c_register_pragma_with_expansion_and_data): New functions.
8126         * c-pragma.c (registered_pragmas, c_register_pragma_1)
8127         (c_register_pragma, c_register_pragma_with_expansion)
8128         (c_invoke_pragma_handler): Changed to work with
8129         internal_pragma_handler.
8130         (c_register_pragma_with_data)
8131         (c_register_pragma_with_expansion_and_data): New functions.
8133 2011-06-14  Joseph Myers  <joseph@codesourcery.com>
8135         * c-common.c: Include common/common-target.h.
8136         (handle_section_attribute): Use
8137         targetm_common.have_named_sections.
8138         * c-cppbuiltin.c: Include common/common-target.h.
8139         (c_cpp_builtins): Use targetm_common.except_unwind_info.
8141 2011-06-10  Richard Guenther  <rguenther@suse.de>
8143         * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
8144         to print a IDENTIFIER_NODE.
8146 2011-06-09  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
8147             Joseph Myers  <joseph@codesourcery.com>
8149         * c.opt (fbuilding-libgcc): New option.
8150         * c-cppbuiltin.c (c_cpp_builtins): Define
8151         __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
8153 2011-06-07  Jason Merrill  <jason@redhat.com>
8155         * c-common.c (max_tinst_depth): Lower default to 900.
8157         * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
8159 2011-06-07  Richard Guenther  <rguenther@suse.de>
8161         * c-common.c (c_common_nodes_and_builtins): Do not set
8162         size_type_node or call set_sizetype.
8164 2011-06-07  Dodji Seketeli  <dodji@redhat.com>
8166         PR debug/49130
8167         * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
8168         type when using pointer comparison to compare types.
8170 2011-06-02  Jonathan Wakely  <jwakely.gcc@gmail.com>
8172         * c.opt: Add -Wdelete-non-virtual-dtor.
8173         * c-opts.c (c_common_handle_option): Include it in -Wall.
8175 2011-05-30  Nathan Froyd  <froydnj@gcc.gnu.org>
8177         PR bootstrap/49190
8179         Revert:
8180         2011-05-26  Nathan Froyd  <froydnj@codesourcery.com>
8182         * c-common.h (struct c_common_identifier): Inherit from tree_typed,
8183         not tree_common.
8185 2011-05-27  Jakub Jelinek  <jakub@redhat.com>
8187         PR c++/49165
8188         * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
8189         C++ don't call c_common_truthvalue_conversion on void type arms.
8191 2011-05-27  Nathan Froyd  <froydnj@codesourcery.com>
8193         * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
8194         (stmt_list_stack): Define.
8195         (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
8196         * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
8198 2011-05-26  Nathan Froyd  <froydnj@codesourcery.com>
8200         * c-common.c (warning_candidate_p): Check for BLOCKs.
8202 2011-05-26  Nathan Froyd  <froydnj@codesourcery.com>
8204         * c-common.h (struct c_common_identifier): Inherit from tree_typed,
8205         not tree_common.
8207 2011-05-25  Jakub Jelinek  <jakub@redhat.com>
8209         * c-common.c (def_fn_type): Remove extra va_end.
8211 2011-05-23  Jason Merrill  <jason@redhat.com>
8213         PR c++/48106
8214         * c-common.c (c_common_get_narrower): New.
8215         (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
8217 2011-05-23  Nathan Froyd  <froydnj@codesourcery.com>
8219         * c-common.h (check_function_arguments): Tweak prototype of
8220         check_function_arguments.
8221         * c-common.c (check_function_arguments): Likewise.  Adjust
8222         calls to check_function_nonnull, check_function_format, and
8223         check_function_sentinel.
8224         (check_function_sentinel): Take a FUNCTION_TYPE rather than
8225         separate attributes and typelist arguments.  Use
8226         FOREACH_FUNCTION_ARGS to iterate over argument types.
8228 2011-05-15  Paolo Carlini  <paolo.carlini@oracle.com>
8230         * c-common.c (c_common_reswords): Reorder.
8231         * c-common.h (rid): Likewise.
8233 2011-05-10  Nathan Froyd  <froydnj@codesourcery.com>
8235         * c-common.c (def_fn_type): Don't call build_function_type, call
8236         build_function_type_array or build_varargs_function_type_array
8237         instead.
8238         (c_common_nodes_and_builtins): Likewise.
8240 2011-05-05  Nathan Froyd  <froydnj@codesourcery.com>
8242         * c-common.c (c_add_case_label): Omit the loc argument to
8243         build_case_label.
8244         * c-common.h (build_case_label): Remove.
8245         * c-semantics.c (build_case_label): Remove.
8247 2011-05-05  Joseph Myers  <joseph@codesourcery.com>
8249         * c-objc.h (objc_start_method_definition): Update prototype.
8250         * stub-objc.c (objc_start_method_definition): Add extra parameter.
8252 2011-05-04  Nathan Froyd  <froydnj@codesourcery.com>
8254         * c-common.c (check_main_parameter_types): Reindent.  Don't use
8255         TYPE_ARG_TYPES directly.
8256         (handle_nonnull_attribute): Likewise.
8257         (sync_resolve_params): Likewise.
8258         * c-format.c (handle_format_arg_attribute): Likewise.  Adjust call
8259         to check_format_string.
8260         (handle_format_attribute): Likewise.
8261         (check_format_string): Take a function type to examine instead of
8262         a type list.  Use a function_arg_iterator to step through argument
8263         types.
8265 2011-05-04  Richard Guenther  <rguenther@suse.de>
8267         * c-common.c (fix_string_type): Use size_int for index type bounds.
8268         (start_fname_decls): Do not pass NULL to build_int_cst.
8269         (c_init_attributes): Likewise.
8270         * c-lex.c (c_lex_with_flags): Likewise.
8272 2011-04-27  Jason Merrill  <jason@redhat.com>
8274         * c-common.c (make_tree_vector_from_list): New.
8275         * c-common.h: Declare it.
8277 2011-04-26  Richard Guenther  <rguenther@suse.de>
8279         PR preprocessor/48248
8280         * c-ppoutput.c (maybe_print_line): Always optimize newlines
8281         for output size with -P.
8283 2011-04-25  Paolo Carlini  <paolo.carlini@oracle.com>
8285         * c-common.c (struct c_common_resword): Add __underlying_type.
8286         * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
8288 2011-04-20  Jim Meyering  <meyering@redhat.com>
8290         * c-format.c (init_dollar_format_checking): Remove useless
8291         if-before-free.
8293 2011-04-15  Nicola Pero  <nicola.pero@meta-innovation.com>
8295         * c-objc.h (objc_get_interface_ivars): Removed.
8296         (objc_detect_field_duplicates): New.
8297         * stub-objc.c: Likewise.
8299 2011-04-14  Nicola Pero  <nicola.pero@meta-innovation.com>
8301         * stub-objc.c (objc_declare_protocols): Renamed to
8302         objc_declare_protocol.
8303         * c-objc.h: Likewise.
8305 2011-04-14  Nicola Pero  <nicola.pero@meta-innovation.com>
8307         * stub-objc.c (objc_declare_class): Updated argument name.
8309 2011-04-12  Nathan Froyd  <froydnj@codesourcery.com>
8311         * c-common.h (c_common_init_ts): Declare.
8312         * c-common.c (c_common_init_ts): Define.
8314 2011-04-12  Nicola Pero  <nicola.pero@meta-innovation.com>
8316         * c-objc.h (objc_build_message_expr): Updated prototype.
8317         * stub-objc.c (objc_build_message_expr): Likewise.
8319 2011-04-12  Martin Jambor  <mjambor@suse.cz>
8321         * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
8322         of cgraph_node.
8324 2011-04-11  Richard Guenther  <rguenther@suse.de>
8326         * c-common.c (complete_array_type): Build a range type of
8327         proper type.
8329 2011-04-08  Nathan Froyd  <froydnj@codesourcery.com>
8331         * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
8332         (handle_type_generic_attribute): Likewise.
8334 2011-04-07  Jason Merrill  <jason@redhat.com>
8336         PR c++/48450
8337         * c-common.c (c_common_truthvalue_conversion): Don't ignore
8338         conversion from C++0x scoped enum.
8340 2011-04-06  Joseph Myers  <joseph@codesourcery.com>
8342         * c-target-def.h: New file.
8343         * c-target.def: New file.
8344         * c-target.h: New file.
8345         * c-common.c (targetcm): Don't define here.
8346         * c-common.h (default_handle_c_option): Declare.
8347         * c-format.c: Include c-target.h instead of target.h.
8348         * c-opts.c: Include c-target.h instead of target.h.  Explicitly
8349         include tm.h.
8350         (default_handle_c_option): Move from targhooks.c.
8352 2011-03-29  Jakub Jelinek  <jakub@redhat.com>
8354         PR preprocessor/48248
8355         * c-ppoutput.c (print): Add src_file field.
8356         (init_pp_output): Initialize it.
8357         (maybe_print_line): Don't optimize by adding up to 8 newlines
8358         if map->to_file and print.src_file are different file.
8359         (print_line): Update print.src_file.
8361 2011-03-25  Kai Tietz  <ktietz@redhat.com>
8363         * c-ada-spec.c (compare_comment): Use filename_cmp
8364         instead of strcmp for filename.
8366 2011-03-25  Jeff Law  <law@redhat.com>
8368         * c-common.c (def_fn_type): Add missing va_end.
8370 2011-03-25  Jason Merrill  <jason@redhat.com>
8372         * c.opt: Add -std=c++03.
8374 2011-03-22  Eric Botcazou  <ebotcazou@adacore.com>
8376         * c-ada-spec.c (dump_ada_template): Skip non-class instances.
8378 2011-03-17  Kai Tietz  <ktietz@redhat.com>
8380         PR target/12171
8381         * c-pretty-print.c (pp_c_specifier_qualifier_list):
8382         Display allowed attributes for function pointer types.
8383         (pp_c_attributes_display): New function to display
8384         attributes having affects_type_identity flag set to true.
8385         * c-pretty-print.h (pp_c_attributes_display): New prototype.
8387         * c-common.c (c_common_attribute_table):
8388         Add new element.
8389         (c_common_format_attribute_table): Likewise.
8391 2011-03-18  Jason Merrill  <jason@redhat.com>
8393         * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
8394         * c-common.h: Don't declare it here.
8395         * c-common.c: Or define it here.
8396         * c-opts.c (c_common_handle_option): Or set it here.
8398         PR c++/35315
8399         * c-common.c (handle_transparent_union_attribute): Don't
8400         make a duplicate type in C++.
8402 2011-03-15  Jason Merrill  <jason@redhat.com>
8404         * c-common.c (max_constexpr_depth): New.
8405         * c-common.h: Declare it.
8406         * c-opts.c (c_common_handle_option): Set it.
8407         * c.opt (fconstexpr-depth): New option.
8409 2011-03-11  Jason Merrill  <jason@redhat.com>
8411         * c-common.c (attribute_takes_identifier_p): Add missing const.
8413         PR c++/46803
8414         * c-common.c (attribute_takes_identifier_p): Assume that an
8415         unknown attribute takes an identifier.
8417 2011-03-07  Nathan Froyd  <froydnj@codesourcery.com>
8419         PR c/47786
8420         * c-common.c (c_type_hash): Call list_length instead of iterating
8421         through DECL_CHAIN.  Rename 'i' to 'n_elements'.
8423 2011-02-19  Jakub Jelinek  <jakub@redhat.com>
8425         PR c/47809
8426         * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
8428 2011-02-17  Iain Sandoe  <iains@gcc.gnu.org>
8430         * c.opt (fobjc-abi-version=) New.
8431         (fobjc-nilcheck): New.
8433 2011-02-03  Nathan Froyd  <froydnj@codesourcery.com>
8435         PR c++/46890
8436         * c-common.h (keyword_is_decl_specifier): Declare.
8437         * c-common.c (keyword_is_decl_specifier): Define.
8438         (keyword_is_function_specifier): New function.
8440 2011-01-26  Jakub Jelinek  <jakub@redhat.com>
8442         PR c/47473
8443         * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
8444         EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
8445         REAL_TYPE.
8447 2011-01-26  Arnaud Charlet  <charlet@adacore.com>
8449         * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
8451 2011-01-26  Jakub Jelinek  <jakub@redhat.com>
8453         PR pch/47430
8454         * c-opts.c (c_common_post_options): Call c_common_no_more_pch
8455         after init_c_lex if pch_file is set.
8457 2011-01-26  Dave Korn  <dave.korn.cygwin@gmail.com>
8459         PR c++/43601
8460         * c.opt (-fkeep-inline-dllexport): New switch.
8462 2011-01-12  Richard Guenther  <rguenther@suse.de>
8464         PR middle-end/32511
8465         * c-common.c (handle_weak_attribute): Warn instead of error
8466         on declaring an inline function weak.
8468 2011-01-05  Tom Tromey  <tromey@redhat.com>
8470         * c-common.h (lvalue_error): Update.
8471         * c-common.c (lvalue_error): Add 'loc' argument.  Call error_at,
8472         not error.
8474 2010-12-29  Nicola Pero  <nicola.pero@meta-innovation.com>
8476         PR objc/47075
8477         * c-objc.h (objc_finish_message_expr): Added argument to
8478         prototype.
8480 2010-12-22  Nathan Froyd  <froydnj@codesourcery.com>
8482         * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
8483         Use prototype_p.
8485 2010-12-18  Nicola Pero  <nicola.pero@meta-innovation.com>
8487         * c-objc.h (objc_maybe_warn_exceptions): New.
8488         * stub-objc.c (objc_maybe_warn_exceptions): New.
8490 2010-12-10  Nathan Froyd  <froydnj@codesourcery.com>
8492         * c-common.h (readonly_error): Declare.
8493         * c-common.c (readonly_error): Define.
8495 2010-12-09  Nathan Froyd  <froydnj@codesourcery.com>
8497         * c-common.h (invalid_indirection_error): Declare.
8498         * c-common.c (invalid_indirection_error): Define.
8500 2010-12-03  Richard Guenther  <rguenther@suse.de>
8502         PR c/46745
8503         * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
8504         (pp_c_unary_expression): Likewise.
8505         (pp_c_expression): Likewise.
8507 2010-11-30  Nicola Pero  <nicola.pero@meta-innovation.com>
8509         * c-common.h (objc_finish_function): New.
8510         (objc_non_volatilized_type): Removed.
8511         (objc_type_quals_match): Removed.
8512         * stub-objc.c (objc_finish_function): New.
8513         (objc_non_volatilized_type): Removed.
8514         (objc_type_quals_match): Removed.
8516 2010-11-30  Joseph Myers  <joseph@codesourcery.com>
8518         * c-common.h (parse_optimize_options): Declare.
8519         * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
8520         c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
8522 2010-11-29  Joseph Myers  <joseph@codesourcery.com>
8524         * c-opts.c (check_deps_environment_vars): Use getenv instead of
8525         GET_ENVIRONMENT.
8526         * c-pch.c (O_BINARY): Don't define here.
8527         * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
8529 2010-11-25  Joseph Myers  <joseph@codesourcery.com>
8531         * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
8532         targetm.except_unwind_info.
8534 2010-11-23  Joseph Myers  <joseph@codesourcery.com>
8536         * c-opts.c (c_common_handle_option): Pass location to
8537         set_struct_debug_option.
8539 2010-11-23  Joseph Myers  <joseph@codesourcery.com>
8541         * c-common.c (visibility_options): Move from ../opts.c.
8542         * c-common.h (struct visibility_flags, visibility_options):
8543         Declare here.
8544         * c-opts.c (finish_options): Rename to c_finish_options.
8545         (c_common_init): Update call to finish_options.
8547 2010-11-22  Nicola Pero  <nicola.pero@meta-innovation.com>
8549         PR objc/34033
8550         * c-lex.c (lex_string): Check that each string in an Objective-C
8551         string concat sequence starts with either one or zero '@', and
8552         that there are no spurious '@' signs at the end.
8554 2010-11-20  Joseph Myers  <joseph@codesourcery.com>
8556         * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
8557         HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
8558         HANDLE_PRAGMA_VISIBILITY.
8559         * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
8560         HANDLE_PRAGMA_VISIBILITY): Don't define.
8561         (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
8563 2010-11-20  Nathan Froyd  <froydnj@codesourcery.com>
8565         PR c++/16189
8566         PR c++/36888
8567         PR c++/45331
8568         * c-common.h (keyword_begins_type_specifier): Declare.
8569         (keyword_is_storage_class_specifier): Declare.
8570         (keyword_is_type_qualifier): Declare.
8571         * c-common.c (keyword_begins_type_specifier): New function.
8572         (keyword_is_storage_class_specifier): New function.
8573         (keyword_is_type_qualifier): Declare.
8575 2010-11-19  Joseph Myers  <joseph@codesourcery.com>
8577         PR c/46547
8578         * c-common.c (in_late_binary_op): Define.
8579         (c_common_truthvalue_conversion): Check in_late_binary_op before
8580         calling c_save_expr.
8581         * c-common.h (in_late_binary_op): Declare.
8583 2010-11-19  Joseph Myers  <joseph@codesourcery.com>
8585         * c-opts.c (c_common_handle_option): Update calls to
8586         set_struct_debug_option.
8588 2010-11-19  Nicola Pero  <nicola.pero@meta-innovation.com>
8590         * c-common.h (objc_declare_protocols): Added additional argument.
8591         * stub-objc.c (objc_declare_protocol): Same change.
8593 2010-11-18  Nathan Froyd  <froydnj@codesourcery.com>
8595         PR c/33193
8596         * c-common.h (build_real_imag_expr): Declare.
8597         * c-semantics.c (build_real_imag_expr): Define.
8599 2010-11-17  Joseph Myers  <joseph@codesourcery.com>
8601         * c-opts.c (c_common_parse_file): Take no arguments.
8602         * c-common.h (c_common_parse_file): Update prototype.
8604 2010-11-16  Jakub Jelinek  <jakub@redhat.com>
8606         PR c++/46401
8607         * c-common.c (warning_candidate_p): Don't track non-const calls
8608         or STRING_CSTs.
8610 2010-11-15  Ian Lance Taylor  <iant@google.com>
8612         * c-lex.c (init_c_lex): Set macro debug callbacks if
8613         flag_dump_go_spec is set.
8615 2010-11-15  Nicola Pero  <nicola.pero@meta-innovation.com>
8617         * c-common.h (objc_build_incr_expr_for_property_ref): New.
8618         * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
8620 2010-11-15  Nathan Froyd  <froydnj@codesourcery.com>
8622         PR preprocessor/45038
8623         * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
8624         dialects.
8626 2010-11-12  Joseph Myers  <joseph@codesourcery.com>
8628         * c-common.h (c_family_lang_mask): Declare.
8629         * c-opts.c (c_family_lang_mask): Make extern.
8630         * c-pragma.c (handle_pragma_diagnostic): Use
8631         control_warning_option.
8633 2010-11-12  Joseph Myers  <joseph@codesourcery.com>
8635         * c-common.c (parse_optimize_options): Update call to
8636         decode_options.
8637         * c-common.h (c_common_handle_option): Update prototype.
8638         * c-opts.c (c_common_handle_option): Take location_t parameter and
8639         pass it to other functions.
8641 2010-11-11  Joseph Myers  <joseph@codesourcery.com>
8643         * c-opts.c (warning_as_error_callback): Remove.
8644         (c_common_initialize_diagnostics): Don't call
8645         register_warning_as_error_callback.
8646         (c_common_handle_option): Handle -Werror=normalized= here.
8648 2010-11-10  Joseph Myers  <joseph@codesourcery.com>
8650         * c-common.c (handle_mode_attribute): Use %' and word "signedness"
8651         in diagnostic.
8652         * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
8653         letter.
8654         * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
8655         Remove trailing '.' from diagnostics.
8656         * c.opt (Wwrite-strings_: Avoid '`' in help text.
8658 2010-11-10  Joseph Myers  <joseph@codesourcery.com>
8660         * c-common.c (parse_optimize_options): Pass global_dc to
8661         decode_options.
8662         * c-opts.c (c_common_handle_option): Pass &global_options to
8663         set_Wstrict_aliasing.
8664         * c.opt (v): Don't mark Common or document here.
8666 2010-11-06  Iain Sandoe  <iains@gcc.gnu.org>
8668         PR target/44981
8669         * c-format.c (format_type): New type gcc_objc_string_format_type.
8670         (valid_stringptr_type_p): New.
8671         (handle_format_arg_attribute): Use valid_stringptr_type_p ().
8672         (check_format_string): Pass expected type, use
8673         valid_stringptr_type_p (), check that the format string types are
8674         consistent with the format specification.
8675         (decode_format_attr): Warn if NSString is used outside objective-c.
8676         (format_types_orig): Add NSString.
8677         (format_name): New.
8678         (format_flags): New.
8679         (check_format_arg): Handle format strings requiring an external parser.
8680         first_target_format_type: New variable.
8681         (handle_format_attribute): Set up first_target_format_type, pass the
8682         expected format arg string type to check_format_string().
8683         * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL):  New flag.
8684         * stub-objc.c (objc_string_ref_type_p): New.
8685         (objc_check_format_arg): New.
8687 2010-11-04  Nicola Pero  <nicola.pero@meta-innovation.com>
8689         Fixed using the Objective-C 2.0 dot-syntax with class names.
8690         * c-common.h (objc_build_class_component_ref): New.
8691         * stub-objc.c (objc_build_class_component_ref): New.
8693 2010-11-03  Nicola Pero  <nicola.pero@meta-innovation.com>
8695         * c.opt (Wproperty-assign-default): New option.
8697 2010-11-03  Nicola Pero  <nicola.pero@meta-innovation.com>
8699         Implemented -fobjc-std=objc1 flag.
8700         * c.opt (fobjc-std=objc1): New option.
8702 2010-11-01  Nicola Pero  <nicola.pero@meta-innovation.com>
8704         Implemented format and noreturn attributes for Objective-C methods.
8705         * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
8706         attribute for Objective-C methods.
8708 2010-10-31  Jason Merrill  <jason@redhat.com>
8710         * c-common.c (conversion_warning, warn_for_collisions_1): Use
8711         EXPR_LOC_OR_HERE.
8713 2010-10-30  Nicola Pero  <nicola.pero@meta-innovation.com>
8715         Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
8716         * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
8717         (objc_add_property_declaration): Removed arguments for copies and
8718         ivar.
8719         (objc_build_getter_call): Renamed to
8720         objc_maybe_build_component_ref.
8721         (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
8722         (objc_is_property_ref): New.
8723         * c-common.c (c_common_reswords): Removed copies and ivar.
8724         * stub-objc.c (objc_add_property_declaration): Removed arguments
8725         for copies and ivar.
8726         (objc_build_getter_call): Renamed to
8727         objc_maybe_build_component_ref.
8728         (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
8729         (objc_is_property_ref): New.
8731 2010-10-29  Arnaud Charlet  <charlet@adacore.com>
8732             Matthew Gingell  <gingell@adacore.com>
8734         * c-ada-spec.c (separate_class_package): New function.
8735         (pp_ada_tree_identifier): Prefix references to C++ classes with the
8736         name of their enclosing package.
8737         (print_ada_declaration): Use separate_class_package.
8739 2010-10-27  Jason Merrill  <jason@redhat.com>
8741         * c-common.c (c_common_reswords): Add __is_literal_type.
8742         * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
8744         * c-common.c (check_case_value): Remove special C++ code.
8746 2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>
8748         * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
8749         RID_RETAIN, RID_COPY and RID_NONATOMIC.  Updated RID_FIRST_PATTR
8750         and RID_LAST_PATTR.
8751         (objc_add_property_declaration): Added additional arguments.
8752         (objc_property_attribute_kind): Removed.
8753         (objc_set_property_attr): Removed.
8754         * c-common.c (c_common_reswords): Added readwrite, assign, retain,
8755         copy and nonatomic.
8756         * stub-objc.c (objc_add_property_declaration): Added additional
8757         arguments.
8758         (objc_set_property_attr): Removed.
8760 2010-10-27  Nicola Pero  <nicola.pero@meta-innovation.com>
8762         * c-common.h (objc_add_property_variable): Renamed to
8763         objc_add_property_declaration.  Added location argument.
8764         * stub-objc.c (objc_add_property_variable): Same change.
8766 2010-10-23  Nicola Pero  <nicola.pero@meta-innovation.com>
8768         * c-common.h (objc_maybe_printable_name): New.
8769         * stub-objc.c (objc_maybe_printable_name): New.
8771 2010-10-22  Artjoms Sinkarovs  <artyom.shinakroff@gmail.com>
8772             Andrew Pinski  <pinskia@gmail.com>
8774         * c-common.h (c_common_mark_addressable_vec): Declare.
8775         * c-common.c (c_common_mark_addressable_vec): New function.
8777 2010-10-20  Nicola Pero  <nicola.pero@meta-innovation.com>
8779         * c-common.h (objc_set_method_type): Removed.
8780         (objc_add_method_declaration): Added boolean argument.
8781         (objc_start_method_definition): Same change.
8782         (objc_build_method_signature): Same change.
8783         * stub-objc.c (objc_set_method_type): Removed.
8784         (objc_add_method_declaration): Added boolean argument.
8785         (objc_start_method_definition): Same change.
8786         (objc_build_method_signature): Same change.
8788 2010-10-20  Nicola Pero  <nicola.pero@meta-innovation.com>
8790         * c-common.h (finish_file): Removed.
8791         (objc_write_global_declarations): New.
8792         * c-opts.c (c_common_parse_file): Do not call finish_file.
8793         * stub-objc.c (objc_write_global_declarations): New.
8795 2010-10-18  Nicola Pero  <nicola.pero@meta-innovation.com>
8797         Implemented parsing @synthesize and @dynamic for
8798         Objective-C/Objective-C++.
8799         * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
8800         (objc_add_synthesize_declaration): New.
8801         (objc_add_dynamic_declaration): New.
8802         * c-common.c (c_common_reswords): Add synthesize and dynamic.
8803         * stub-objc.c (objc_add_synthesize_declaration): New.
8804         (objc_add_dynamic_declaration): New.
8806 2010-10-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
8808         PR target/46041
8809         * c-cppbuiltin.c (mode_has_fma): Move function here from
8810         builtins.c.  Don't use the fma optab, instead just use the
8811         HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
8812         using -save-temps.
8814 2010-10-18  Nicola Pero  <nicola.pero@meta-innovation.com>
8816         Merge from 'apple/trunk' branch on FSF servers.
8818         2005-11-08  Fariborz Jahanian  <fjahanian@apple.com>
8820         Radar 4330422
8821         * c-common.h (objc_non_volatilized_type): New declaration
8822         * stub-objc.c (objc_non_volatilized_type): New stub.
8824 2010-10-17  Nicola Pero  <nicola.pero@meta-innovation.com>
8826         Merge from 'apple/trunk' branch on FSF servers.
8828         2006-03-27 Fariborz Jahanian  <fjahanian@apple.com>
8830         Radar 4133425
8831         * c-common.h (objc_diagnose_private_ivar): New decl.
8832         * stub-objc.c (objc_diagnose_private_ivar): New stub.
8834 2010-10-17  Iain Sandoe  <iains@gcc.gnu.org>
8836         * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
8837         * c-common.h (enum rid): Add RID_AT_PACKAGE.
8838         (objc_ivar_visibility_kind): New enum.
8839         (objc_set_visibility): Adjust prototype to use visibility enum.
8840         * stub-objc.c (objc_set_visibility): Adjust stub to use
8841         visibility enum.
8843 2010-10-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
8845         * c-cppbuiltin.c (builtin_define_float_constants): Emit
8846         __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
8847         has the appropriate fma builtins.
8848         (c_cpp_builtins): Adjust call to builtin_define_float_constants.
8850 2010-10-14  Iain Sandoe  <iains@gcc.gnu.org>
8852         merge from FSF apple 'trunk' branch.
8853         2006 Fariborz Jahanian  <fjahanian@apple.com>
8855         Radars 4436866, 4505126, 4506903, 4517826
8856         * c-common.c (c_common_resword): Define @property and its attributes.
8857         * c-common.h: Define property attribute enum entries.
8858         (OBJC_IS_PATTR_KEYWORD): New.
8859         (objc_property_attribute_kind): New enum.
8860         Declare objc_set_property_attr (), objc_add_property_variable (),
8861         objc_build_getter_call () and objc_build_setter_call ().
8862         * stub-objc.c (objc_set_property_attr): New stub.
8863         (objc_add_property_variable): Likewise.
8864         (objc_build_getter_call): Likewise.
8865         (objc_build_setter_call) Likewise.
8867 2010-10-13  Iain Sandoe  <iains@gcc.gnu.org>
8869         merge from FSF apple 'trunk' branch.
8870         2006-04-26 Fariborz Jahanian  <fjahanian@apple.com>
8872         Radar 3803157 (method attributes)
8873         * c-common.c (handle_deprecated_attribute): Recognize
8874         objc methods as valid declarations.
8875         * c-common.h: Declare objc_method_decl ().
8876         * stub-objc.c (objc_method_decl): New stub.
8878 2010-10-08  Joseph Myers  <joseph@codesourcery.com>
8880         * c-common.c (parse_optimize_options): Call
8881         decode_cmdline_options_to_array_default_mask before
8882         decode_options.  Update arguments to decode_options.
8883         * c-common.h (c_common_init_options_struct): Declare.
8884         * c-opts.c (c_common_init_options_struct): New.  Split out from
8885         c_common_init_options.
8887 2010-10-06  Nicola Pero  <nicola.pero@meta-innovation.com>
8889         Implemented fast enumeration for Objective-C.
8890         * c-common.h (objc_finish_foreach_loop): New.
8891         * stub-objc.c (objc_finish_foreach_loop): New.
8893 2010-10-05  Joseph Myers  <joseph@codesourcery.com>
8895         * c-common.h (struct diagnostic_context): Don't declare here.
8896         (c_common_initialize_diagnostics): Declare using
8897         diagnostic_context typedef.
8898         * c-opts.c (c_common_handle_option): Pass global_dc to
8899         handle_generated_option.
8901 2010-10-04  Joseph Myers  <joseph@codesourcery.com>
8903         * c-opts.c (c_common_handle_option): Pass &global_options_set to
8904         handle_generated_option.
8906 2010-10-03  Ian Lance Taylor  <iant@google.com>
8908         * c.opt (-fplan9-extensions): New option.
8910 2010-10-03  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
8912         * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
8913         Remove.
8914         (c_cpp_builtins): Call functions from cppbuiltin.c instead
8915         of duplicating code.
8917 2010-09-30  Iain Sandoe  <iains@gcc.gnu.org>
8919         * c-common.c: Add two new entries for @optional
8920         and @required keywords.
8922         merge from FSF 'apple/trunk' branch.
8923         2006-01-30  Fariborz Jahanian  <fjahanian@apple.com>
8925         Radar 4386773
8926         * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
8927         objective-c keywords.
8928         (objc_set_method_opt): New declaration.
8929         * stub-objc.c (objc_set_method_opt): New stub.
8931 2010-09-30  Joseph Myers  <joseph@codesourcery.com>
8933         * c-common.c (handle_optimize_attribute): Pass &global_options to
8934         cl_optimization_save and cl_optimization_restore.
8935         * c-opts.c (c_common_handle_option): Pass &global_options to
8936         handle_generated_option.
8937         * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
8938         (handle_pragma_pop_options, handle_pragma_reset_options): Pass
8939         &global_options to cl_optimization_restore.
8941 2010-09-30  Nicola Pero  <nicola.pero@meta-innovation.com>
8943         * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
8944         Objective-C/Objective-C++ keywords.
8946 2010-09-29  Nicola Pero  <nicola.pero@meta-innovation.com>
8948         Merge from 'apple/trunk' branch on FSF servers.
8950         2005-10-04  Fariborz Jahanian  <fjahanian@apple.com>
8952         Radar 4281748
8953         * c-common.h (objc_check_global_decl): New declaration.
8954         * stub-objc.c (objc_check_global_decl): New stub.
8956 2010-09-29  Joseph Myers  <joseph@codesourcery.com>
8958         * c.opt: Don't use VarExists.
8960 2010-09-29  Joseph Myers  <joseph@codesourcery.com>
8962         * c-common.c (c_cpp_error): Update names of diagnostic_context
8963         members.
8964         * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
8965         cl_optimization members.
8966         * c-opts.c (warning_as_error_callback, c_common_handle_option,
8967         sanitize_cpp_opts, finish_options): Update names of cpp_options
8968         members.
8970 2010-09-29  Nicola Pero  <nicola.pero@meta-innovation.com>
8972         * c-common.h (OBJC_IS_CXX_KEYWORD): New macro.  Updated comments.
8973         (objc_is_reserved_word): Removed.
8974         * c-common.c: Updated comments.
8975         * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
8976         objc_is_reserved_word.
8977         * stub-objc.c (objc_is_reserved_word): Removed.
8979 2010-09-28  Iain Sandoe  <iains@gcc.gnu.org>
8981         * c-common.h (objc_add_method_declaration): Adjust prototype to
8982         include attributes.
8983         (objc_start_method_definition): Likewise.
8984         (objc_build_keyword_decl): Likewise.
8985         * stub-objc.c:(objc_add_method_declaration): Handle attributes.
8986         (objc_start_method_definition): Likewise.
8987         (objc_build_keyword_decl): Likewise.
8989 2010-09-28  Iain Sandoe  <iains@gcc.gnu.org>
8991         * c-common.h (objc_start_class_interface): Adjust prototype.
8992         (objc_start_category_interface): Likewise.
8993         (objc_start_protocol): Likewise.
8994         * stub-objc.c (objc_start_protocol): Adjust for extra argument.
8995         (objc_start_class_interface): Likewise.
8996         (objc_start_category_interface): Likewise.
8998 2010-09-27  Ian Lance Taylor  <iant@google.com>
9000         * c-common.c (c_common_attribute_table): Add no_split_stack.
9001         (handle_no_split_stack_attribute): New static function.
9003 2010-09-27  Nicola Pero  <nicola.pero@meta-innovation.com>
9005         Merge from 'apple/trunk' branch on FSF servers.
9007         2005-12-15  Fariborz Jahanian  <fjahanian@apple.com>
9009         Radar 4229905
9010         * c-common.h (objc_have_common_type): New declaration.
9011         * stub-objc.c (objc_have_common_type): New stub.
9013         2005-06-22  Ziemowit Laski  <zlaski@apple.com>
9015         Radar 4154928
9016         * c-common.h (objc_common_type): New prototype.
9017         * stub-objc.c (objc_common_type): New stub.
9019 2010-09-24  Jan Hubicka  <jh@suse.cz>
9021         * c-common.c (handle_leaf_attribute): New function.
9022         (struct attribute_spec c_common_att): Add leaf.
9024 2010-09-22  Joseph Myers  <joseph@codesourcery.com>
9026         * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
9027         -comments-in-macros, -define-macro, -define-macro=, -dependencies,
9028         -dump, -dump=, -imacros, -imacros=, -include, -include=,
9029         -include-barrier, -include-directory, -include-directory=,
9030         -include-directory-after, -include-directory-after=,
9031         -include-prefix, -include-prefix=, -include-with-prefix,
9032         -include-with-prefix=, -include-with-prefix-after,
9033         -include-with-prefix-after=, -include-with-prefix-before,
9034         -include-with-prefix-before=, -no-integrated-cpp,
9035         -no-line-commands, -no-standard-includes, -no-warnings, -output,
9036         -output=, -pedantic, -pedantic-errors, -preprocess,
9037         -print-missing-file-dependencies, -trace-includes, -traditional,
9038         -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
9039         -user-dependencies, -verbose, -write-dependencies,
9040         -write-user-dependencies, no-integrated-cpp, traditional): New.
9042 2010-09-21  Nicola Pero  <nicola.pero@meta-innovation.com>
9044         PR objc/23710
9045         * c-common.h (objc_start_method_definition): Return bool instead
9046         of void.
9047         * stub-objc.c (objc_start_method_definition): Return bool instead
9048         of void.
9050 2010-09-21  Nicola Pero  <nicola.pero@meta-innovation.com>
9052         PR objc/25965
9053         * c-common.h (objc_get_interface_ivars): New declaration.
9054         * stub-objc.c (objc_get_interface_ivars): New stub.
9056 2010-09-15  Ian Lance Taylor  <iant@google.com>
9058         * c-common.c (parse_optimize_options): Do not capitalize warning
9059         messages.  Remove period at end of warning message.
9061 2010-09-09  Nathan Sidwell  <nathan@codesourcery.com>
9063         * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
9064         (handle_alias_attribute): ... here.
9065         (handle_ifunc_attribute): New.
9067 2010-09-06  Mark Mitchell  <mark@codesourcery.com>
9069         * c-common.h (do_warn_double_promotion): Declare.
9070         * c-common.c (do_warn_double_promotion): Define.
9072 2010-09-05  Mark Mitchell  <mark@codesourcery.com>
9074         * c.opt (Wdouble-promotion): New.
9076 2010-09-02  Joseph Myers  <joseph@codesourcery.com>
9078         * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
9079         fvtable-thunks, fxref): Mark no longer supported in help text.
9081 2010-09-02  Joseph Myers  <joseph@codesourcery.com>
9083         * c.opt (Wimport, fall-virtual, falt-external-templates,
9084         fdefault-inline, fenum-int-equiv, fexternal-templates,
9085         fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
9086         fname-mangling-version-, fnew-abi, fnonnull-objects,
9087         foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
9088         fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
9089         applicable.
9090         (fhandle-exceptions): Mark with Alias and Warn.
9091         * c-opts.c (c_common_handle_option): Don't handle options marked
9092         as ignored.
9094 2010-09-02  Joseph Myers  <joseph@codesourcery.com>
9096         * c.opt (Wcomments, Werror-implicit-function-declaration,
9097         ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
9098         std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
9099         aliases.
9100         * c-common.c (option_codes): Use OPT_Wcomment instead of
9101         OPT_Wcomments.
9102         * c-opts.c (warning_as_error_callback, c_common_handle_option):
9103         Don't handle options marked as aliases.
9105 2010-08-25  Richard Guenther  <rguenther@suse.de>
9107         * c-common.c (c_common_get_alias_set): Remove special
9108         handling for pointers.
9110 2010-08-20  Nathan Froyd  <froydnj@codesourcery.com>
9112         * c-common.c: Use FOR_EACH_VEC_ELT.
9113         * c-gimplify.c: Likewise.
9114         * c-pragma.c: Likewise.
9116 2010-08-16  Joseph Myers  <joseph@codesourcery.com>
9118         * c.opt (MDX): Change back to MD.  Mark NoDriverArg instead of
9119         RejectDriver.
9120         (MMDX): Change back to MMD.  Mark NoDriverArg instead of
9121         RejectDriver.
9122         * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
9123         instead of OPT_MDX and OPT_MMDX.
9125 2010-08-16  Joseph Myers  <joseph@codesourcery.com>
9127         * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
9129 2010-08-12  Joseph Myers  <joseph@codesourcery.com>
9131         * c.opt (MD, MMD): Change to MDX and MMDX.
9132         * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
9134 2010-08-11  Joseph Myers  <joseph@codesourcery.com>
9136         * c-opts.c (c_common_handle_option): Call handle_generated_option
9137         instead of handle_option.
9139 2010-08-08  Nathan Froyd  <froydnj@codesourcery.com>
9141         * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
9142         (maybe_apply_renaming_pragma): Delete unneeded declarations.
9144 2010-08-08  Nathan Froyd  <froydnj@codesourcery.com>
9146         * c-pragma.c (pending_redefinition): Declare.  Declare a VEC of it.
9147         (pending_redefine_extname): Change type to a VEC.
9148         (add_to_renaming_pragma_list): Update for new type of
9149         pending_redefine_extname.
9150         (maybe_apply_renaming_pragma): Likewise.
9152 2010-08-04  Arnaud Charlet  <charlet@adacore.com>
9154         * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
9155         visited.
9156         (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
9157         decide whether a type has already been declared/seen.
9158         Do not go to the original type.
9159         (dump_nested_types): New parameter forward.
9160         Generate forward declaration if needed and mark type as visited.
9161         (print_ada_declaration): Call dump_nested_types if not already done.
9162         Mark types as visited.
9164 2010-08-03  Joseph Myers  <joseph@codesourcery.com>
9166         * c.opt (-print-pch-checksum): Remove option.
9167         * c-opts.c (c_common_handle_option): Don't handle
9168         OPT_print_pch_checksum.
9170 2010-07-27  Joseph Myers  <joseph@codesourcery.com>
9172         * c-common.h (c_common_handle_option): Update prototype and return
9173         value type.
9174         * c-opts.c (c_common_handle_option): Update prototype and return
9175         value type.  Update calls to handle_option and
9176         enable_warning_as_error.
9178 2010-07-27  Jakub Jelinek  <jakub@redhat.com>
9180         PR c/45079
9181         * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
9183 2010-07-27  Joseph Myers  <joseph@codesourcery.com>
9185         * c-common.h (c_common_missing_argument): Remove.
9186         * c-opts.c (c_common_missing_argument): Remove.
9187         * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
9188         idirafter, imacros, include, isysroot, isystem, iquote): Add
9189         MissingArgError.
9190         * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
9192 2010-07-27  Joseph Myers  <joseph@codesourcery.com>
9194         * c-common.h (c_common_option_lang_mask,
9195         c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
9196         New.
9197         (c_common_init_options): Update prototype.
9198         * c-opts.c (c_common_option_lang_mask): New.
9199         (c_common_initialize_diagnostics): Split out of
9200         c_common_init_options.
9201         (accept_all_c_family_options, c_common_complain_wrong_lang_p):
9202         New.
9203         (c_common_init_options): Update prototype.  Use decoded options in
9204         search for -lang-asm.
9206 2010-07-15  Nathan Froyd  <froydnj@codesourcery.com>
9208         * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
9209         * c-format.c: Likewise.
9211 2010-07-08  Manuel López-Ibáñez  <manu@gcc.gnu.org>
9213         * c-common.h: Include diagnostic-core.h. Error if already
9214         included.
9215         * c-semantics.c: Do not define GCC_DIAG_STYLE here.
9217 2010-07-03  Manuel López-Ibáñez  <manu@gcc.gnu.org>
9219         * c-common.c (IN_GCC_FRONTEND): Do not undef.
9220         Do not include expr.h
9221         (vector_mode_valid_p): Move here.
9223 2010-06-21  DJ Delorie  <dj@redhat.com>
9225         * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
9226         allow these pragmas anywhere.
9228 2010-06-14  Jakub Jelinek  <jakub@redhat.com>
9230         PR bootstrap/44509
9231         * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
9232         (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
9233         (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
9234         ggc_strdup instead of xstrdup.
9236 2010-06-10  Jakub Jelinek  <jakub@redhat.com>
9238         * c-cppbuiltin.c: Include cpp-id-data.h.
9239         (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
9240         (lazy_hex_fp_value): New function.
9241         (builtin_define_with_hex_fp_value): Provide definitions lazily.
9243 2010-06-30  Manuel López-Ibáñez  <manu@gcc.gnu.org>
9245         * c-gimplify.c: Do not include tree-flow.h
9247 2010-06-29  Joern Rennecke  <joern.rennecke@embecosm.com>
9249         PR other/44034
9250         * c-common.c: Rename targetm member:
9251         targetm.enum_va_list -> targetm.enum_va_list_p
9253 2010-06-28  Anatoly Sokolov  <aesok@post.ru>
9255         * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
9257 2010-06-28  Steven Bosscher  <steven@gcc.gnu.org>
9259         * c-cppbuiltin.c: Do not include except.h.
9261 2010-06-24  Andi Kleen  <ak@linux.intel.com>
9263         * c-common.c (warn_for_omitted_condop): New.
9264         * c-common.h (warn_for_omitted_condop): Add prototype.
9266 2010-06-21  Joseph Myers  <joseph@codesourcery.com>
9268         * c.opt (lang-objc): Remove.
9269         * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
9271 2010-06-21  Joern Rennecke  <joern.rennecke@embecosm.com>
9273         * c-opts.c: Include "tm_p.h".
9275 2010-06-20  Joseph Myers  <joseph@codesourcery.com>
9277         * c-common.c (parse_optimize_options): Update call to
9278         decode_options.
9280 2010-06-18  Nathan Froyd  <froydnj@codesourcery.com>
9282         * c-common.c (record_types_used_by_current_var_decl): Adjust for
9283         new type of types_used_by_cur_var_decl.
9285 2010-06-17  Joern Rennecke  <joern.rennecke@embecosm.com>
9287         PR bootstrap/44512
9288         * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
9289         for C++ standard compliance.
9291 2010-06-16  Jason Merrill  <jason@redhat.com>
9293         * c.opt: Add -Wnoexcept.
9295 2010-06-16  Richard Guenther  <rguenther@suse.de>
9297         PR c/44555
9298         * c-common.c (c_common_truthvalue_conversion): Remove
9299         premature and wrong optimization concering ADDR_EXPRs.
9301 2010-06-15  Arnaud Charlet  <charlet@adacore.com>
9303         * c-ada-spec.c (dump_sloc): Remove column info.
9304         (is_simple_enum): New function.
9305         (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
9306         enum types when relevant.
9308 2010-06-11  Manuel López-Ibáñez  <manu@gcc.gnu.org>
9310         * c-common.c (conversion_warning): Warn at expression
9311         location.
9313 2010-06-10  Joseph Myers  <joseph@codesourcery.com>
9315         * c-opts.c (c_common_handle_option): Don't handle
9316         OPT_fshow_column.
9318 2010-06-08  Laurynas Biveinis  <laurynas.biveinis@gmail.com>
9320         * c-pragma.c (push_alignment): Use typed GC allocation.
9321         (handle_pragma_push_options): Likewise.
9323         * c-common.c (parse_optimize_options): Likewise.
9325         * c-common.h (struct sorted_fields_type): Add variable_size GTY
9326         option.
9328 2010-06-07  Joseph Myers  <joseph@codesourcery.com>
9330         * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
9331         flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
9332         flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
9333         flag_signed_bitfields, warn_strict_null_sentinel,
9334         flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
9335         flag_gen_declaration, flag_no_gnu_keywords,
9336         flag_implement_inlines, flag_implicit_templates,
9337         flag_implicit_inline_templates, flag_optional_diags,
9338         flag_elide_constructors, flag_default_inline, flag_rtti,
9339         flag_conserve_space, flag_access_control, flag_check_new,
9340         flag_new_for_scope, flag_weak, flag_working_directory,
9341         flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
9342         flag_enforce_eh_specs, flag_threadsafe_statics,
9343         flag_pretty_templates): Remove.
9344         * c-common.h (flag_preprocess_only, flag_nil_receivers,
9345         flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
9346         flag_replace_objc_classes, flag_undef, flag_no_builtin,
9347         flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
9348         flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
9349         flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
9350         flag_no_gnu_keywords, flag_implement_inlines,
9351         flag_implicit_templates, flag_implicit_inline_templates,
9352         flag_optional_diags, flag_elide_constructors, flag_default_inline,
9353         flag_rtti, flag_conserve_space, flag_access_control,
9354         flag_check_new, flag_new_for_scope, flag_weak,
9355         flag_working_directory, flag_use_cxa_atexit,
9356         flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
9357         flag_threadsafe_statics, flag_pretty_templates,
9358         warn_strict_null_sentinel): Remove.
9359         * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
9360         fbuiltin, fcheck-new, fconserve-space, felide-constructors,
9361         fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
9362         fimplicit-inline-templates, fimplicit-templates,
9363         flax-vector-conversions, fms-extensions, fnil-receivers,
9364         fnonansi-builtins, fpretty-templates, freplace-objc-classes,
9365         frtti, fshort-double, fshort-enums, fshort-wchar,
9366         fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
9367         funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
9368         fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
9369         gen-decls, undef): Use Var.
9370         (fdefault-inline, foptional-diags): Document as doing nothing.
9371         * c-opts.c (c_common_handle_option): Remove cases for options now
9372         using Var.  Mark ignored options as such.
9374 2010-06-05  Steven Bosscher  <steven@gcc.gnu.org>
9376         * c-common.c: Moved to here from parent directory.
9377         * c-common.def: Likewise.
9378         * c-common.h: Likewise.
9379         * c-cppbuiltin.c: Likewise.
9380         * c-dump.c: Likewise.
9381         * c-format.c: Likewise.
9382         * c-format.h : Likewise.
9383         * c-gimplify.c: Likewise.
9384         * c-lex.c: Likewise.
9385         * c-omp.c: Likewise.
9386         * c.opt: Likewise.
9387         * c-opts.c: Likewise.
9388         * c-pch.c: Likewise.
9389         * c-ppoutput.c: Likewise.
9390         * c-pragma.c: Likewise.
9391         * c-pragma.h: Likewise.
9392         * c-pretty-print.c: Likewise.
9393         * c-pretty-print.h: Likewise.
9394         * c-semantics.c: Likewise.
9395         * stub-objc.c: Likewise.
9397         * c-common.c: Include gt-c-family-c-common.h.
9398         * c-pragma.c: Include gt-c-family-c-pragma.h.
9400 Copyright (C) 2010-2018 Free Software Foundation, Inc.
9402 Copying and distribution of this file, with or without modification,
9403 are permitted in any medium without royalty provided the copyright
9404 notice and this notice are preserved.