1 2018-10-30 Martin Sebor <msebor@redhat.com>
4 * c-format.c (check_format_types): Avoid diagnosing null pointer
5 arguments to printf-family of functions.
7 2018-10-30 Marek Polacek <polacek@redhat.com>
9 Implement P0892R2, explicit(bool).
10 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
12 2018-10-29 David Malcolm <dmalcolm@redhat.com>
14 * name-hint.h (name_hint::take_deferred): New member function.
16 2018-10-29 David Malcolm <dmalcolm@redhat.com>
19 * c-common.c (check_function_sentinel): Call fold_for_warn on the
21 (check_function_restrict): Rename param "argarray" to
22 "unfolded_argarray", and make a copy named "argarray", calling
23 fold_for_warn on each argument.
24 (check_function_arguments): Add note about responsibility for
25 folding the arguments.
27 2018-10-17 Joseph Myers <joseph@codesourcery.com>
29 * c-common.c (flag_isoc2x): New variable.
30 * c-common.h (clk_c): Update comment to reference C2X.
31 (flag_isoc99, flag_isoc11): Update comments to reference future
32 standard versions in general.
33 (flag_isoc2x): Declare.
34 * c-opts.c (set_std_c2x): New function.
35 (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
36 (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
38 * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
40 2018-10-17 Joseph Myers <joseph@codesourcery.com>
42 * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
43 (std=iso9899:2018): Document C17 as published in 2018.
45 2018-10-12 Christophe Lyon <christophe.lyon@linaro.org>
48 * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
50 2018-10-11 Will Wray <wjwray@gmail.com>
53 * c-pretty-print.h (pp_c_type_cast): Prototype.
54 (pp_c_integer_constant): Likewise.
55 * c-pretty-print.c (pp_c_type_cast): No longer static.
56 (pp_c_integer_constant): Likewise.
57 (pp_c_enumeration_constant): Fix loop termination when finding
58 name of constant. No longer returns a value. Call
59 pp_c_integer_constant.
60 (c_pretty_printer::constant): Update for changes to
61 pp_c_enumeration_constant.
63 2018-10-11 Jakub Jelinek <jakub@redhat.com>
65 * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
66 for no_unique_address.
68 2018-10-09 David Malcolm <dmalcolm@redhat.com>
70 * c-common.c (c_option_controlling_cpp_error): Rename to...
71 (c_option_controlling_cpp_diagnostic): ...this, and convert
72 "reason" from int to enum.
73 (c_cpp_error): Rename to...
74 (c_cpp_diagnostic): ...this, converting level and reason to enums.
75 * c-common.h (c_cpp_error): Rename to...
76 (c_cpp_diagnostic): ...this, converting level and reason to enums.
77 * c-opts.c (c_common_init_options): Update for renaming.
79 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
82 * c-common.c (vector_types_compatible_elements_p): Use
83 INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
85 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
87 * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
88 to generate constructor destructor priority warning.
89 * c.opt (-Wprio-ctor-dtor): New option.
91 2018-10-01 Jason Merrill <jason@redhat.com>
93 * c-lex.c (c_common_has_attribute): Add no_unique_address.
95 2018-10-01 Eric Botcazou <ebotcazou@adacore.com>
97 * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
98 (dump_ada_node): Add const keyword.
100 2018-09-25 Martin Liska <mliska@suse.cz>
102 * c-common.c (c_common_truthvalue_conversion):
103 Remove Pascal from documentation.
105 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
107 * c-ada-spec.c: Include diagnostic.h.
108 (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
110 2018-09-19 Marek Polacek <polacek@redhat.com>
112 * c.opt (Wclass-conversion): New.
114 2018-09-17 David Malcolm <dmalcolm@redhat.com>
116 * c-format.c (range_label_for_format_type_mismatch::get_text):
117 Update for new param.
119 2018-09-17 David Malcolm <dmalcolm@redhat.com>
121 * c-format.c (format_warning_at_char): Update for introduction of
122 format_string_diagnostic_t.
123 (format_type_warning): Likewise.
125 2018-09-17 Martin Jambor <mjambor@suse.cz>
128 * c.opt (Wabsolute-value): New.
130 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
132 * c-common.c (complete_flexible_array_elts): New helper function.
133 * c-common.h (complete_flexible_array_elts): Declare.
135 2018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
137 * c-common.c (braced_list_to_string): Remove eval parameter.
138 Add some more checks. Always create zero-terminated STRING_CST.
139 * c-common.h (braced_list_to_string): Adjust prototype.
141 2018-08-27 David Malcolm <dmalcolm@redhat.com>
144 * c-common.c (c_cpp_error): Update for conversion of show_caret_p
146 (maybe_suggest_missing_token_insertion): Likewise.
147 (maybe_add_include_fixit): Add param "override_location". If set,
148 and source-printing is enabled, then override the rich_location's
149 primary location with that of the insertion point for the fix-it
150 hint, marking it with SHOW_LINES_WITHOUT_RANGE.
151 * c-common.h (extern void maybe_add_include_fixit): Add bool
153 * c-format.c (selftest::test_type_mismatch_range_labels): Update
154 for conversion of show_caret_p to a tri-state.
155 * c-warn.c (warn_for_restrict): Likewise.
157 (suggest_missing_header::~suggest_missing_header): Update call to
158 maybe_add_include_fixit to suggest overriding the location, as it
161 2018-08-27 Martin Liska <mliska@suse.cz>
163 * c-common.c (check_function_restrict): Use new function
164 fndecl_built_in_p and remove check for FUNCTION_DECL if
166 (check_builtin_function_arguments): Likewise.
167 (reject_gcc_builtin): Likewise.
168 * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
170 2018-08-26 Marek Polacek <polacek@redhat.com>
172 PR c++/87029, Implement -Wredundant-move.
173 * c.opt (Wredundant-move): New option.
175 2018-08-21 Marek Polacek <polacek@redhat.com>
177 PR c++/86981, Implement -Wpessimizing-move.
178 * c.opt (Wpessimizing-move): New option.
180 2018-08-20 David Malcolm <dmalcolm@redhat.com>
183 * c-attribs.c (common_handle_aligned_attribute): Add
184 auto_diagnostic_group instance.
185 * c-indentation.c (warn_for_misleading_indentation): Likewise.
186 * c-opts.c (c_common_post_options): Likewise.
187 * c-warn.c (warn_logical_not_parentheses): Likewise.
188 (warn_duplicated_cond_add_or_warn): Likewise.
189 (warn_for_multistatement_macros): Likewise.
191 2018-08-20 Nathan Sidwell <nathan@acm.org>
193 * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
196 2018-08-17 Nathan Sidwell <nathan@acm.org>
198 * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
200 (laxy_hex_fp_value_count): Make unsigned.
201 (lazy_hex_fp_value): Provided with macro & lazy number. Directly
202 manipulate the macro.
203 (builtin_defin_with_hex_fp_value): Adjust callback name, use
206 2018-08-17 David Malcolm <dmalcolm@redhat.com>
208 * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
209 (gcc_dump_printf_length_specs): New.
210 (gcc_dump_printf_flag_pairs): New.
211 (gcc_dump_printf_flag_specs): New.
212 (gcc_dump_printf_char_table): New.
213 (format_types_orig): Add entry for "gcc_dump_printf".
214 (init_dynamic_diag_info): Set up length_char_specs and
215 conversion_specs for gcc_dump_printf_format_type.
216 (handle_format_attribute): Handle gcc_dump_printf_format_type.
218 2018-08-17 Nathan Sidwell <nathan@acm.org>
220 * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
222 * c-ada-spec.c: Don't #include "cpp-id-data.h"
223 * c-cppbuiltin.c: Likewise.
225 2018-08-17 Martin Liska <mliska@suse.cz>
227 * c.opt: Remove Warn, Init and Report for options with
228 Ignore/Deprecated flag. Warning is done automatically for
231 2018-08-16 David Malcolm <dmalcolm@redhat.com>
234 * c-common.c (selftest::c_family_tests): Call
235 selftest::c_indentation_c_tests.
236 * c-common.h (selftest::c_indentation_c_tests): New decl.
237 * c-indentation.c: Include "selftest.h".
238 (next_tab_stop): Add "tab_width" param, rather than accessing
240 (get_visual_column): Likewise. Clarify comment. Bulletproof
241 against reading past the end of the line.
242 (get_first_nws_vis_column): Add "tab_width" param.
243 (detect_intervening_unindent): Likewise.
244 (should_warn_for_misleading_indentation): Read tab width from
245 cpp_opts and pass around.
246 (selftest::test_next_tab_stop): New test.
247 (selftest::assert_get_visual_column_succeeds): New function.
248 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
249 (selftest::assert_get_visual_column_fails): New function.
250 (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
251 (selftest::test_get_visual_column): New test.
252 (selftest::c_indentation_c_tests): New function.
254 2018-08-16 Nathan Sidwell <nathan@acm.org>
256 * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
257 (store_ada_macro): Likewise.
258 * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
259 * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
261 2018-08-15 David Malcolm <dmalcolm@redhat.com>
263 * c-format.c: Include "selftest-diagnostic.h" and
264 "gcc-rich-location.h".
265 (format_warning_at_char): Pass NULL for new label params of
267 (class indirection_suffix): New class.
268 (class range_label_for_format_type_mismatch): New class.
269 (format_type_warning): Move logic for generating "*" suffix to
270 class indirection_suffix. Create "fmt_label" and "param_label"
271 to show their types, and pass them to the
272 format_warning_at_substring calls.
273 (selftest::test_type_mismatch_range_labels): New test.
274 (selftest::c_format_c_tests): Call it.
276 2018-08-13 Martin Sebor <msebor@redhat.com>
278 PR tree-optimization/71625
279 * c-common.c (braced_list_to_string): New function.
280 * c-common.h (braced_list_to_string): Declare it.
282 2018-08-08 Nathan Sidwell <nathan@acm.org>
284 * c-common.c (try_to_locate_new_include_inertion_point): Use
285 linemap_included_from_linemap.
286 * c-lex.c (fe_file_change): Use linemap_included_from.
287 * c-ppoutput.c (pp_file_change): Likewise.
289 2018-08-01 Martin Sebor <msebor@redhat.com>
291 PR tree-optimization/86650
292 * c-family/c-format.c (gcc_tdiag_char_table): Update comment for "%G".
293 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
294 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
295 * c-format.h (T89_G): Update to be "gimple *" rather than
297 (local_gcall_ptr_node): Rename...
298 (local_gimple_ptr_node): ...to this.
300 2018-07-31 David Malcolm <dmalcolm@redhat.com>
302 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
303 table entries for gcc_diag_char_table, and the 'Z' entry from
304 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
305 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
306 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
307 adding missing "Z" for this table. Remove erroneous "G" and "K"
309 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
310 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
311 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
313 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
315 * c-common.c (speculation_safe_resolve_call): New function.
316 (speculation_safe_resolve_params): New function.
317 (speculation_safe_resolve_return): New function.
318 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
319 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
320 __HAVE_SPECULATION_SAFE_VALUE.
322 2018-07-20 David Malcolm <dmalcolm@redhat.com>
324 * c-common.c (c_cpp_error): Remove redundant "line_table"
325 parameter from call to rich_location::set_range.
326 (maybe_suggest_missing_token_insertion): Likewise.
328 2018-07-20 Martin Sebor <msebor@redhat.com>
331 * gcc/c-family/c.opt (-Warray-bounds): Remove redundant -Wall.
333 2018-07-20 Martin Sebor <msebor@redhat.com>
336 * c-common.h (c_common_handle_option): Change function argument
338 * c-opts.c (c_common_init_options): Same.
339 (c_common_handle_option): Same. Remove special handling of
340 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
341 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
342 options to take a HOST_WIDE_INT argument and accept a byte-size
344 (-Wvla-larger-than): Same.
345 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
346 (-Wno-vla-larger-than): Same.
348 2018-07-12 Jakub Jelinek <jakub@redhat.com>
350 * c-attribs.c (c_common_attribute_table): Add
351 "omp declare target implicit" attribute.
353 2018-07-12 Richard Biener <rguenther@suse.de>
356 * c-attribs.c (handle_packed_attribute): Do not build a variant
357 type with TYPE_PACKED, instead ignore the attribute if we may
358 not apply to the original type.
360 2018-07-10 Jakub Jelinek <jakub@redhat.com>
363 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
364 to contain TREE_LIST for both the original class iterator and the
367 2018-07-07 Eric Botcazou <ebotcazou@adacore.com>
369 * c-ada-spec.c (to_ada_name): Remove index parameter.
370 (pp_ada_tree_identifier): Likewise.
371 (dump_ada_macros): Adjust call to to_ada_name.
372 (struct overloaded_name_hash): Delete.
373 (struct overloaded_name_hasher): Likewise.
374 (overloaded_names): Likewise.
375 (compute_overloading_index): Likewise.
376 (dump_ada_decl_name): Do not call compute_overloading_index and
377 adjust calls to pp_ada_tree_identifier.
378 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
379 (dump_ada_import): Add spc parameter and switch to aspect syntax.
380 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
381 (dump_ada_enum_type): Remove type and display_convention parameters.
382 Adjust calls to pp_ada_tree_identifier.
383 (dump_ada_node): Likewise and for dump_ada_structure.
384 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
386 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
388 (print_constructor): Adjust call to pp_ada_tree_identifier.
389 (print_destructor): Likewise.
390 (dump_ada_declaration): Switch to aspect syntax.
391 (dump_ada_structure): Likewise and tidy up. Replace display_convention
392 parameter with nested parameter.
393 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
394 (dump_ada_specs): Do not delete overloaded_names table.
396 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
399 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
402 2018-07-05 Nathan Sidwell <nathan@acm.org>
404 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
405 NO_IMPLICIT_EXTERN_C.
407 2018-06-28 Martin Liska <mliska@suse.cz>
409 * cppspec.c: Include opt-suggestions.h.
411 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
412 Thomas Schwinge <thomas@codesourcery.com>
413 Cesar Philippidis <cesar@codesourcery.com>
415 * c-pragma.h (enum pragma_omp_clause): Add
416 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
417 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
419 2018-06-20 Jakub Jelinek <jakub@redhat.com>
422 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
425 2018-06-18 Martin Sebor <msebor@redhat.com>
428 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
431 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
433 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
435 2018-06-13 Jason Merrill <jason@redhat.com>
437 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
438 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
441 PR c++/86094 - wrong code with defaulted move ctor.
442 * c-opts.c (c_common_post_options): Bump the current ABI version to
443 13. Set warn_abi_version and flag_abi_compat_version to the current
444 version rather than 0. Fix defaulting flag_abi_compat_version from
447 2018-06-12 Martin Sebor <msebor@redhat.com>
450 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
451 sizeof source and destination yields the same value.
453 2018-06-12 Martin Liska <mliska@suse.cz>
455 * c.opt: Make MPX-related options as Deprecated.
457 2018-06-08 David Malcolm <dmalcolm@redhat.com>
459 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
462 2018-06-08 Martin Liska <mliska@suse.cz>
464 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
465 for MPX (macros, related functions, fields in cgraph_node, ...).
466 (handle_bnd_legacy): Likewise.
467 (handle_bnd_instrument): Likewise.
470 2018-06-06 Jakub Jelinek <jakub@redhat.com>
473 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
474 __cpp_transactional_memory to 201500 instead of 210500.
476 2018-06-06 Jason Merrill <jason@redhat.com>
478 PR c++/85710 - ICE with -Wmemset-elt-size.
479 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
481 2018-06-01 Jason Merrill <jason@redhat.com>
483 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
486 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
488 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
489 declaration for a typedef independently of whether the declaration of
490 the subtype is generated.
492 2018-05-31 Martin Sebor <msebor@redhat.com>
495 * c.opt (-Wno-alloc-size-larger-than): New option.
497 2018-04-22 David Pagan <dave.pagan@oracle.com>
500 * c-opts.c (c_common_post_options): Set default for warn_return_type
501 for C++/C++ with ObjC extensions only. For C, makes it possible to
502 differentiate between default (no option), -Wreturn-type, and
505 2018-05-29 Jason Merrill <jason@redhat.com>
507 * c.opt (Winit-list-lifetime): New flag.
509 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
511 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
512 splay_tree_delete_pointers.
514 2018-05-26 Jakub Jelinek <jakub@redhat.com>
517 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
518 noinline variable to workaround broken kernel headers.
520 2018-05-18 Jason Merrill <jason@redhat.com>
522 * c.opt (Wdeprecated-copy): New flag.
524 2018-05-17 Martin Liska <mliska@suse.cz>
526 * c-warn.c (overflow_warning): Do not use
527 space in between 'G_' and '('.
529 2018-05-09 Jason Merrill <jason@redhat.com>
531 * c-common.c (valid_array_size_p): Add complain parameter.
532 * c-common.h: ...which defaults to true.
534 2018-05-11 Jakub Jelinek <jakub@redhat.com>
537 * c-omp.c (c_omp_predetermined_sharing): Return
538 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
540 2018-05-11 Martin Liska <mliska@suse.cz>
543 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
546 2018-05-10 Jakub Jelinek <jakub@redhat.com>
549 * c-common.h (fold_offsetof_1): Removed.
550 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
551 CTX argument defaulted to ERROR_MARK.
552 * c-common.c (fold_offsetof_1): Renamed to ...
553 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
554 argument, convert the pointer constant to TYPE and use size_binop
555 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
556 a pointer type. Adjust recursive calls.
558 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
561 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
563 2018-05-07 Nathan Sidwell <nathan@acm.org>
565 * c.opt (ffor-scope): Remove functionality, issue warning.
567 2018-05-03 Nathan Sidwell <nathan@acm.org>
569 * c.opt (ffriend-injection): Remove functionality, issue warning.
571 2018-05-01 David Malcolm <dmalcolm@redhat.com>
574 * c-format.c (struct format_check_results): Add field
576 (check_format_info): Initialize it, and warn if encountered.
577 (check_format_arg): Distinguish between wide char and
578 everything else when detecting arrays of non-char.
580 2018-04-30 David Malcolm <dmalcolm@redhat.com>
582 * c-format.c (get_corrected_substring): Update for
583 location_get_source_line returning a char_span. Use a char_span
584 when handling the prefix of the correction.
585 * c-indentation.c (get_visual_column): Update for
586 location_get_source_line returning a char_span.
587 (get_first_nws_vis_column): Likewise.
589 2018-03-29 David Malcolm <dmalcolm@redhat.com>
592 * known-headers.cc (get_stdlib_header_for_name): Add various names
593 from <assert.h>, <string.h>, and <memory.h>; add more names from
596 2018-03-27 Jakub Jelinek <jakub@redhat.com>
599 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
600 get_base_address of the second operand is a VAR_P, rather than the
601 operand itself, and use gcc_checking_assert instead of gcc_assert.
603 2018-03-23 Marek Polacek <polacek@redhat.com>
606 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
607 <case RDIV_EXPR>: Tweak condition.
609 2018-03-20 Eric Botcazou <ebotcazou@adacore.com>
611 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
613 2018-03-16 Jakub Jelinek <jakub@redhat.com>
616 * c-warn.c (conversion_warning): Replace "to to" with "to" in
620 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
623 2018-03-16 Richard Biener <rguenther@suse.de>
626 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
627 unshare the possibly folded expression.
629 2018-03-15 Richard Biener <rguenther@suse.de>
632 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
634 2018-03-13 Martin Sebor <msebor@redhat.com>
636 PR tree-optimization/84725
637 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
638 with all three narrow character types, including their qualified forms.
640 2018-03-12 Martin Sebor <msebor@redhat.com>
642 PR tree-optimization/83456
643 * gcc/c-family/c-common.c (check_function_restrict): Return bool.
644 Restore checking of bounded built-in functions.
645 (check_function_arguments): Also return the result
646 of warn_for_restrict.
647 * gcc/c-family/c-common.c (check_function_restrict): Return bool.
648 * gcc/c-family/c-warn.c (warn_for_restrict): Return bool.
650 2018-03-02 Marek Polacek <polacek@redhat.com>
653 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
656 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
658 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
661 2018-03-01 Marek Polacek <polacek@redhat.com>
664 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
665 alignment in computation.
667 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
669 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
670 <REAL_TYPE>: Deal specifically with _Float128/__float128.
672 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
674 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
675 (is_char_array): Take a type instead of a declaration.
676 (dump_ada_array_type): Likewise.
677 (is_simple_enum): Minor tweak.
678 (dump_ada_enum_type): New function extracted from...
679 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
680 <INTEGER_TYPE>: Remove unreachable code.
681 <RECORD_TYPE>: Likewise. Minor tweaks.
682 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
683 <ENUMERAL_TYPE>: New case.
684 <RECORD_TYPE>: Factor out common code.
685 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
686 Minor tweaks. Deal with enumeral types.
687 (dump_ada_structure): Minor tweaks.
689 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
691 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
692 address for incomplete structures.
693 (dump_forward_type): Do not bail out for incomplete structures.
694 (dump_ada_declaration): Do not special-case incomplete structures
695 for subtypes. Dump them as null records for types.
697 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
699 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
700 (is_char_array): Fix formatting.
701 (dump_template_types): Likewise.
702 (dump_generic_ada_node): Rename into...
703 (dump_ada_node): ...this.
704 <POINTER_TYPE>: Remove superfluous space. Use generic address for
705 incomplete structures and not for empty structures. Do not use it
706 when forward declarations are needed.
707 (dump_forward_type): New function.
708 (dump_nested_types): Remove FORWARD parameter. Do not consider
709 TREE_VISITED and do not generate a forward declaration. Only dump
710 original nested types for nested declaration.
711 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
712 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
713 <RECORD_TYPE>: Do not consider TREE_VISITED.
714 (dump_ada_declaration): Use booleans and fix formatting throughout.
715 <TYPE_DECL>: Skip incomplete structures and not empty structures.
716 Call dump_forward_type instead of dump_nested_types for a typedef.
717 Remove superfluous check and adjust call to dump_nested_types.
718 <POINTER_TYPE>: Call dump_forward_type and fall through.
719 (dump_ada_struct_decl): Rename into...
720 (dump_ada_structure): ...this. Do not special-case empty structures.
722 2018-02-27 Martin Sebor <msebor@redhat.com>
725 * c.opt (-Wmissing-attributes): New option.
727 2018-02-21 Martin Liska <mliska@suse.cz>
729 * c.opt (Wcatch-value=): Add IntegerRange.
731 2018-02-15 Jason Merrill <jason@redhat.com>
733 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
735 2018-02-09 Nathan Sidwell <nathan@acm.org>
738 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
740 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
743 2018-02-09 Martin Sebor <msebor@redhat.com>
746 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
747 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
748 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
749 (-Wstrict-overflow, -Wsuggest-attribute): Same.
750 (-Wuninitialized): Same.
752 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
754 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
755 keyword for components.
757 2018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
759 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
761 2018-02-02 Julia Koval <julia.koval@intel.com>
763 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
765 2018-01-29 Marek Polacek <polacek@redhat.com>
768 * c-format.c (check_function_format): Check current_function_decl.
770 2018-01-27 Jakub Jelinek <jakub@redhat.com>
772 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
774 (LAZY_HEX_FP_VALUES_CNT): Define.
775 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
776 values rather than just 12.
777 (builtin_define_with_hex_fp_value): Likewise.
779 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
782 * c.opt (-fmacro-prefix-map): New option.
783 * c-opts.c (c_common_handle_option): Handle it.
784 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
785 * c-ppoutput.c (init_pp_output): Likewise.
787 2018-01-17 David Malcolm <dmalcolm@redhat.com>
790 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
792 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
794 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
795 Skip 'f' and 'F' characters if it is true.
796 (store_ada_macro): Minor tweak.
797 (dump_ada_macros) <CPP_COMMENT>: Likewise.
798 <CPP_WSTRING>: Likewise.
799 <CPP_STRING>: Output '&' in the buffer if not the first string.
800 <CPP_NUMBER>: Adjust calls to dump_number.
802 2018-01-10 David Malcolm <dmalcolm@redhat.com>
805 * c-common.c: Include "selftest.h".
806 (get_atomic_generic_size): Perform the test for integral type
807 before the range test for any integer constant, fixing indentation
808 of braces. Call fold_for_warn before testing for an INTEGER_CST.
809 (reject_gcc_builtin): Strip any location wrapper from EXPR.
810 (selftest::test_fold_for_warn): New function.
811 (selftest::c_common_c_tests): New function.
812 (selftest::c_family_tests): Call it, and
813 selftest::c_pretty_print_c_tests.
814 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
815 * c-format.c (check_format_arg): Convert VAR_P check to a
817 * c-pretty-print.c: Include "selftest.h".
818 (pp_c_cast_expression): Don't print casts for location wrappers.
819 (selftest::assert_c_pretty_printer_output): New function.
820 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
821 (selftest::test_location_wrappers): New function.
822 (selftest::c_pretty_print_c_tests): New function.
823 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
825 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
826 Alan Hayward <alan.hayward@arm.com>
827 David Sherwood <david.sherwood@arm.com>
829 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
831 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
832 Alan Hayward <alan.hayward@arm.com>
833 David Sherwood <david.sherwood@arm.com>
835 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
838 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
839 Alan Hayward <alan.hayward@arm.com>
840 David Sherwood <david.sherwood@arm.com>
842 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
843 (convert_vector_to_array_for_subscript): Handle polynomial
844 TYPE_VECTOR_SUBPARTS.
845 (c_common_type_for_mode): Check valid_vector_subparts_p.
846 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
849 2018-01-03 Jakub Jelinek <jakub@redhat.com>
851 Update copyright years.
853 2017-12-22 Mike Stump <mikestump@comcast.net>
854 Eric Botcazou <ebotcazou@adacore.com>
856 * c-pragma.c (init_pragma): Register pragma GCC unroll.
857 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
859 2017-12-22 Alexandre Oliva <aoliva@redhat.com>
863 * c-semantics.c (only_debug_stmts_after_p): New.
864 (pop_stmt_list): Clear side effects in debug-only stmt list.
865 Check for single nondebug stmt followed by debug stmts only.
867 2017-12-21 Alexandre Oliva <aoliva@redhat.com>
870 * c-semantics.c (pop_stmt_list): Propagate side effects from
871 single nondebug stmt to container list.
873 2017-12-19 Jakub Jelinek <jakub@redhat.com>
875 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
876 conditions with typical order conditions.
878 2017-12-18 Marek Polacek <polacek@redhat.com>
880 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
883 2017-12-17 Martin Sebor <msebor@redhat.com>
885 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
886 an error for attribute warn_if_not_aligned.
888 2017-12-16 Martin Sebor <msebor@redhat.com>
890 PR tree-optimization/78918
891 * c-common.c (check_function_restrict): Avoid checking built-ins.
892 * c.opt (-Wrestrict): Include in -Wall.
894 2017-12-15 Jakub Jelinek <jakub@redhat.com>
896 * c-attribs.c (c_common_attribute_table,
897 c_common_format_attribute_table): Swap affects_type_identity
898 and handler fields, adjust comments.
900 2017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
902 * c.opt (Wcast-function-type): New warning option.
903 * c-lex.c (get_fileinfo): Avoid warning.
904 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
906 2017-12-14 Qing Zhao <qing.zhao@oracle.com>
909 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
910 Adjust the size of buf1 and buf2, add a new buf to avoid
911 format-overflow warning.
913 2017-12-12 Alexandre Oliva <aoliva@redhat.com>
915 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
916 subsequent statement list.
918 2017-12-07 Martin Sebor <msebor@redhat.com>
922 * c-attribs.c (attr_aligned_exclusions): New array.
923 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
924 (attr_common_exclusions, attr_const_pure_exclusions): Same.
925 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
926 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
927 (attr_warn_unused_result_exclusions): Same.
928 (handle_hot_attribute, handle_cold_attribute): Simplify.
929 (handle_const_attribute): Warn on function returning void.
930 (handle_pure_attribute): Same.
931 (handle_aligned_attribute): Diagnose conflicting attribute
933 * c-warn.c (diagnose_mismatched_attributes): Simplify.
935 2017-12-06 David Malcolm <dmalcolm@redhat.com>
938 * c-common.c (selftest::c_family_tests): Call
939 selftest::c_spellcheck_cc_tests.
940 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
941 * c-spellcheck.cc: Include "selftest.h".
942 (name_reserved_for_implementation_p): New function.
943 (should_suggest_as_macro_p): New function.
944 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
945 should_suggest_as_macro_p and call it.
946 (selftest::test_name_reserved_for_implementation_p): New function.
947 (selftest::c_spellcheck_cc_tests): New function.
948 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
950 2017-12-06 David Malcolm <dmalcolm@redhat.com>
952 * c-spellcheck.cc: New file, taken from macro-handling code in
954 * c-spellcheck.h: New file, taken from macro-handling code in
957 2017-12-01 Jakub Jelinek <jakub@redhat.com>
959 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
961 (handle_simd_attribute): Don't check for "cilk simd function"
962 attribute. Reindent, formatting changes.
964 2017-11-30 Julia Koval <julia.koval@intel.com>
966 * c-common.h (inv_list): Remove.
968 2017-11-28 Jakub Jelinek <jakub@redhat.com>
971 * c-common.c (c_switch_covers_all_cases_p_1,
972 c_switch_covers_all_cases_p): New functions.
973 * c-common.h (c_switch_covers_all_cases_p): Declare.
975 2017-11-28 Julia Koval <julia.koval@intel.com>
976 Sebastian Peryt <sebastian.peryt@intel.com>
978 * array-notation-common.c: Delete.
979 * c-cilkplus.c: Ditto.
980 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
981 * c-common.def (ARRAY_NOTATION_REF): Remove.
982 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
983 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
984 c_validate_cilk_plus_loop, cilkplus_an_parts,
985 cilk_ignorable_spawn_rhs_op,
986 cilk_recognize_spawn): Remove.
987 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
988 * c-omp.c: Remove CILK_SIMD check.
990 * c-pragma.h: Remove CILK related pragmas.
991 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
992 ARRAY_NOTATION_REF condition.
993 (c_pretty_printer::expression): Ditto.
994 * c.opt (fcilkplus): Remove.
997 2017-11-21 Marc Glisse <marc.glisse@inria.fr>
999 * c-pretty-print.c (pp_c_additive_expression,
1000 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
1002 2017-11-21 Jakub Jelinek <jakub@redhat.com>
1004 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
1007 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
1008 instead of tree_to_uhwi, formatting fix.
1010 2017-11-20 David Malcolm <dmalcolm@redhat.com>
1013 * known-headers.cc: New file, based on material from c/c-decl.c.
1014 (suggest_missing_header): Copied as-is.
1015 (get_stdlib_header_for_name): New, based on get_c_name_hint but
1016 heavily edited to add C++ support. Add some knowledge about
1017 <limits.h>, <stdint.h>, and <wchar.h>.
1018 * known-headers.h: Likewise.
1020 2017-11-20 David Malcolm <dmalcolm@redhat.com>
1022 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
1023 (lookup_name_fuzzy): Likewise. Convert return type from
1024 const char * to name_hint. Add location_t param.
1025 * name-hint.h: New header.
1027 2017-11-19 Jakub Jelinek <jakub@redhat.com>
1031 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
1033 2017-11-16 Joseph Myers <joseph@codesourcery.com>
1035 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
1036 expected publication date of C17.
1037 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
1039 2017-11-15 Joseph Myers <joseph@codesourcery.com>
1042 * c-common.c (c_common_reswords): Add __builtin_tgmath.
1043 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
1045 2017-11-10 Martin Sebor <msebor@redhat.com>
1048 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
1049 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
1050 * c.opt (-Wstringop-truncation): New option.
1052 2017-11-06 Martin Liska <mliska@suse.cz>
1055 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
1057 * c.opt: Set default value of warn_return_type.
1059 2017-10-31 David Malcolm <dmalcolm@redhat.com>
1061 * c-common.c (binary_op_error): Update for renaming of
1063 (c_parse_error): Likewise.
1064 * c-warn.c (warn_logical_not_parentheses): Likewise for
1065 renaming of inform_at_rich_loc.
1066 (warn_for_restrict): Likewise for renaming of
1067 warning_at_rich_loc_n.
1069 2017-10-30 Joseph Myers <joseph@codesourcery.com>
1071 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
1072 * c-opts.c (set_std_c17): New function.
1073 (c_common_init_options): Use gnu17 as default C version.
1074 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
1076 2017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
1078 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
1079 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
1080 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
1083 2017-10-23 Marek Polacek <polacek@redhat.com>
1086 * c-warn.c (warnings_for_convert_and_check): Fix typos.
1088 2017-10-19 Eric Botcazou <ebotcazou@adacore.com>
1090 * c-common.c (check_builtin_function_arguments): Also check arguments
1091 of __builtin_alloca_with_align_and_max.
1093 2017-10-17 David Malcolm <dmalcolm@redhat.com>
1095 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
1096 rather than NULL to format_warning_va.
1097 (check_format_types): Likewise when calling format_type_warning.
1098 Remove code to extract source_ranges and source_range * in favor
1099 of just a location_t.
1100 (format_type_warning): Convert source_range * param to a
1103 2017-10-13 Jakub Jelinek <jakub@redhat.com>
1105 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
1108 2017-10-12 David Malcolm <dmalcolm@redhat.com>
1110 * c-common.c (enum missing_token_insertion_kind): New enum.
1111 (get_missing_token_insertion_kind): New function.
1112 (maybe_suggest_missing_token_insertion): New function.
1113 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
1115 2017-10-11 Nathan Sidwell <nathan@acm.org>
1117 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
1118 (c_common_handle_option): Update incpath_kind names.
1120 2017-10-11 Martin Liska <mliska@suse.cz>
1123 * c-attribs.c (handle_no_sanitize_attribute): Report directly
1124 Wattributes warning.
1126 2017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
1128 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
1129 operating on trees as wide_ints.
1130 * c-common.c (pointer_int_sum): Likewise.
1131 * c-pretty-print.c (pp_c_integer_constant): Likewise.
1132 * c-warn.c (match_case_to_enum_1): Likewise.
1133 (c_do_switch_warnings): Likewise.
1134 (maybe_warn_shift_overflow): Likewise.
1136 2017-10-10 Jakub Jelinek <jakub@redhat.com>
1139 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
1140 instead of wide_int::from.
1142 2017-10-06 Jakub Jelinek <jakub@redhat.com>
1145 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
1146 using to_widest use wide_int with the larger of the two precisions.
1148 2017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
1150 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
1153 2017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
1155 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
1156 when combining the original unconverted comparison operands.
1158 2017-09-29 Jakub Jelinek <jakub@redhat.com>
1160 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
1163 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
1165 * c-ada-spec.c (to_ada_name): Add index parameter.
1166 (pp_ada_tree_identifier): Likewise.
1167 (dump_ada_macros): Adjust call to to_ada_name.
1168 (struct overloaded_name_hash): New type.
1169 (struct overloaded_name_hasher): Likewise.
1170 (overloaded_names): New hash table.
1171 (compute_overloading_index): New function.
1172 (dump_ada_decl_name): Call it and pass the result to
1173 pp_ada_tree_identifier.
1174 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
1175 (dump_ada_function_declaration): Likewise.
1176 (dump_generic_ada_node): Likewise.
1177 (print_constructor): Likewise.
1178 (print_destructor): Likewise.
1179 (dump_ada_specs): Delete overloaded_names table.
1181 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
1183 * c-ada-spec.c (max_ada_macros): Move around.
1184 (store_ada_macro_index): Likewise.
1185 (source_file): Rename into...
1186 (macro_source_file): ...this.
1187 (count_ada_macro): Move around.
1188 (store_ada_macro): Likewise.
1189 (compare_macro): Likewise.
1190 (print_ada_macros): Merge in...
1191 (dump_ada_macros): ...this.
1192 (source_file_base): Rename into...
1193 (current_source_file): ...this.
1194 (print_comment): Move around.
1195 (dump_ada_nodes): Call dump_ada_declaration directly.
1196 (struct with): Change type of limited field to bool.
1197 (append_withs): Change type of limited_access parameter to bool.
1198 (pp_ada_tree_identifie): Likewise.
1199 (dump_ada_decl_nam): Likewise.
1200 (dump_generic_ada_node): Likewise. Do not print the return type.
1201 (to_ada_name): Change type of space_found parameter to bool.
1202 (dump_ada_function_declaration): Return void and change type of
1203 parameters to bool. Also print the return type for a function.
1204 (print_ada_methods): Rename into...
1205 (dump_ada_methods): ...this.
1206 (print_ada_declaration): Rename into ...
1207 (dump_ada_declaration): ...this. Do not print the return type.
1208 (print_ada_struct_decl): Rename into...
1209 (dump_ada_struct_decl): ...this.
1211 2017-09-29 Jakub Jelinek <jakub@redhat.com>
1213 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
1214 rather than DECL_INITIAL.
1215 (common_handle_aligned_attribute): Likewise.
1217 2017-09-20 Alexandre Oliva <aoliva@redhat.com>
1219 * c.opt (gen-decls): Add RejectNegative.
1221 2017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
1222 Jakub Jelinek <jakub@redhat.com>
1224 Add support for -std=c++2a.
1225 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
1226 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
1227 * c-opts.c (set_std_cxx2a): New.
1228 (c_common_handle_option): Set options when -std=c++2a is enabled.
1229 (c_common_post_options): Adjust comments.
1230 (set_std_cxx14, set_std_cxx17): Likewise.
1232 2017-09-15 Eric Botcazou <ebotcazou@adacore.com>
1234 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
1235 message for non-uniform endianness and issue a warning in C++.
1237 2017-09-15 Jakub Jelinek <jakub@redhat.com>
1239 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
1240 (Wc++17-compat): Change from undocumented alias to option.
1241 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
1242 change C++1z to C++17 in description.
1243 (std=c++1z, std=gnu++1z): Change from option to undocumented
1245 (std=c++17, std=gnu++17): Change from undocumented alias to option.
1247 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
1248 * c-opts.c (set_std_cxx1z): Rename to ...
1249 (set_std_cxx17): ... this.
1250 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
1251 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
1253 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
1256 2017-09-12 H.J. Lu <hongjiu.lu@intel.com>
1258 * c-attribs.c (common_handle_aligned_attribute): Don't warn
1259 function alignment if warn_if_not_aligned_p is true.
1261 2017-09-12 Nathan Sidwell <nathan@acm.org>
1263 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
1264 resort_sorted_fields): Move to c/c-decl.c.
1265 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
1266 (struct sorted_fields_type): Move to c/c-lang.h.
1268 2017-09-09 Jonathan Wakely <jwakely@redhat.com>
1271 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
1273 2017-09-04 Marek Polacek <polacek@redhat.com>
1276 * c-warn.c (warn_tautological_bitwise_comparison): New function.
1277 (warn_tautological_cmp): Call it.
1279 2017-09-01 Boris Kolpackov <boris@codesynthesis.com>
1281 * c-opts.c (c_common_finish): Write dependency information even if
1284 2017-09-01 Jakub Jelinek <jakub@redhat.com>
1287 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
1288 (omp_pragmas_simd): ... here.
1289 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
1290 create new clauses list containing just simd clause.
1292 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1293 Alan Hayward <alan.hayward@arm.com>
1294 David Sherwood <david.sherwood@arm.com>
1296 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
1297 into scalar_mode_supported_p call.
1298 (handle_mode_attribute): Update call to scalar_mode_supported_p.
1300 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1301 Alan Hayward <alan.hayward@arm.com>
1302 David Sherwood <david.sherwood@arm.com>
1304 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
1305 for the mode iterator.
1307 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1308 Alan Hayward <alan.hayward@arm.com>
1309 David Sherwood <david.sherwood@arm.com>
1311 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
1312 * c-common.c (c_build_vec_perm_expr): Likewise.
1314 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1315 Alan Hayward <alan.hayward@arm.com>
1316 David Sherwood <david.sherwood@arm.com>
1318 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
1320 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1321 Alan Hayward <alan.hayward@arm.com>
1322 David Sherwood <david.sherwood@arm.com>
1324 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
1325 before calling targetm.addr_space.valid_pointer_mode.
1327 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1328 Alan Hayward <alan.hayward@arm.com>
1329 David Sherwood <david.sherwood@arm.com>
1331 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
1333 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1334 Alan Hayward <alan.hayward@arm.com>
1335 David Sherwood <david.sherwood@arm.com>
1337 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
1339 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
1341 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1342 Alan Hayward <alan.hayward@arm.com>
1343 David Sherwood <david.sherwood@arm.com>
1345 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
1348 2017-08-29 Martin Liska <mliska@suse.cz>
1351 * c-common.c (parse_optimize_options): Add argument to function
1353 * c-pragma.c (handle_pragma_diagnostic): Likewise.
1355 2017-08-24 David Malcolm <dmalcolm@redhat.com>
1357 * c-lex.c (interpret_float): Use token location
1358 when building an EXCESS_PRECISION_EXPR.
1360 2017-08-21 David Malcolm <dmalcolm@redhat.com>
1362 * c-common.c (check_function_arguments): Add "arglogs" param; pass
1363 it to check_function_format.
1364 * c-common.h (check_function_arguments): Add vec<location_t> *
1366 (check_function_format): Likewise.
1367 * c-format.c (struct format_check_context): Add field "arglocs".
1368 (check_function_format): Add param "arglocs"; pass it to
1370 (check_format_info): Add param "arglocs"; use it to initialize
1371 new field of format_ctx.
1372 (check_format_arg): Pass format_ctx->arglocs to new param of
1373 check_format_info_main.
1374 (class argument_parser): New field "arglocs".
1375 (argument_parser::argument_parser): Add "arglocs_" param and use
1376 it to initialize new field.
1377 (argument_parser::check_argument_type): Pass new arglocs field to
1379 (check_format_info_main): Add param "arglocs", and use it when
1380 constructing arg_parser.
1381 (check_format_types): Add param "arglocs"; use it if non-NULL when
1382 !EXPR_HAS_LOCATION (cur_param) to get at location information.
1384 2017-08-18 H.J. Lu <hongjiu.lu@intel.com>
1387 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
1388 (c_common_attribute_table): Add warn_if_not_aligned.
1389 (handle_aligned_attribute): Renamed to ...
1390 (common_handle_aligned_attribute): Remove argument, name, and add
1391 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
1392 (handle_aligned_attribute): New.
1393 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
1395 2017-08-14 Martin Sebor <msebor@redhat.com>
1398 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
1399 (handle_nonstring_attribute): New function.
1401 2017-08-14 Martin Sebor <msebor@redhat.com>
1404 * c-format.h (T89_G): New macro.
1405 * c-format.c (local_gcall_ptr_node): New variable.
1406 (init_dynamic_diag_info): Initialize it.
1408 2017-08-11 Martin Liska <mliska@suse.cz>
1410 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
1411 TARGET_SUPPORTS_ALIASES.
1413 2017-08-10 David Malcolm <dmalcolm@redhat.com>
1415 * c-common.c (c_parse_error): Add rich_location * param, using it
1416 rather implicitly using input_location.
1417 * c-common.h (c_parse_error): Add rich_location * param.
1419 2017-08-09 Marek Polacek <polacek@redhat.com>
1421 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
1422 (c_common_truthvalue_conversion): Likewise.
1423 * c-omp.c (c_finish_omp_atomic): Likewise.
1424 * c-common.h (build_binary_op): Update declaration.
1426 2017-08-08 Martin Liska <mliska@suse.cz>
1428 * c-ada-spec.c: Include header files.
1429 * c-ubsan.c: Likewise.
1430 * c-warn.c: Likewise.
1432 2017-08-07 Jakub Jelinek <jakub@redhat.com>
1435 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
1437 2017-08-07 Eric Botcazou <ebotcazou@adacore.com>
1439 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
1440 (print_ada_methods): Likewise.
1441 (print_ada_declaration): Likewise.
1443 2017-08-07 Martin Liska <mliska@suse.cz>
1445 * array-notation-common.c: Add new includes.
1446 * c-format.c( handle_format_attribute): Canonicalize a format
1448 * c-lex.c (c_common_has_attribute): Canonicalize name of an
1450 * c-pretty-print.c: Add new include.
1452 2017-08-05 Eric Botcazou <ebotcazou@adacore.com>
1454 * c-ada-spec.c (has_static_fields): Look only into variables.
1455 (print_constructor): Add TYPE parameter and use it for the name.
1456 (print_destructor): Likewise.
1457 (print_ada_declaration): Adjust to new constructor/destructor names.
1458 Adjust calls to print_constructor and print_destructor.
1459 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
1460 Look only into variables in the final loop.
1462 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
1464 * c-ada-spec.c (has_static_fields): Look only into fields.
1465 (dump_generic_ada_node): Small tweak.
1466 (dump_nested_types): Look only into fields.
1467 (print_ada_declaration): Look only into methods. Small tweak.
1468 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
1470 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
1472 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
1473 (dump_ada_function_declaration): Likewise.
1474 (dump_generic_ada_node): Likewise.
1475 (print_ada_declaration): Add support for const-qualified variables.
1477 2017-07-31 Martin Liska <mliska@suse.cz>
1480 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
1481 Guard condition with flag_sanitize_p also with current_function_decl
1483 (ubsan_maybe_instrument_reference_or_call): Likewise.
1485 2017-07-30 Uros Bizjak <ubizjak@gmail.com>
1487 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
1489 2017-07-29 Eric Botcazou <ebotcazou@adacore.com>
1491 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
1493 (print_ada_declaration): Add missing guard for record types.
1495 2017-07-27 Jakub Jelinek <jakub@redhat.com>
1498 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
1499 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
1500 new COMPOUND_EXPRs around the rhs of the comparison.
1502 2017-07-27 Marek Polacek <polacek@redhat.com>
1505 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
1508 2017-07-27 Jakub Jelinek <jakub@redhat.com>
1510 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
1511 (handle_noipa_attribute): New function.
1513 2017-07-07 Torsten Duwe <duwe@suse.de>
1515 * c-attribs.c (c_common_attribute_table): Add entry for
1516 "patchable_function_entry".
1518 2017-07-20 Nathan Sidwell <nathan@acm.org>
1520 Remove TYPE_METHODS.
1521 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
1522 dump_ada_template, print_ada_methods,
1523 print_ada_declaration): Member fns are on TYPE_FIELDS.
1525 2017-07-18 Nathan Sidwell <nathan@acm.org>
1527 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
1529 2017-07-14 David Malcolm <dmalcolm@redhat.com>
1531 * c-common.c (try_to_locate_new_include_insertion_point): New
1533 (per_file_includes_t): New typedef.
1534 (added_includes_t): New typedef.
1535 (added_includes): New variable.
1536 (maybe_add_include_fixit): New function.
1537 * c-common.h (maybe_add_include_fixit): New decl.
1539 2017-07-10 Martin Sebor <msebor@redhat.com>
1542 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
1544 2017-07-06 David Malcolm <dmalcolm@redhat.com>
1546 * c-common.c (selftest::c_family_tests): New.
1547 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
1548 (selftest::c_family_tests): New decl.
1550 2017-07-04 Marek Polacek <polacek@redhat.com>
1553 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
1556 2017-07-04 Marek Polacek <polacek@redhat.com>
1558 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
1560 2017-06-28 Martin Liska <mliska@suse.cz>
1563 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
1564 to a function declaration.
1566 2017-06-28 Martin Liska <mliska@suse.cz>
1569 * c.opt: Add IntegerRange to various options.
1571 2017-06-26 Marek Polacek <polacek@redhat.com>
1574 * c-common.h (warn_for_multistatement_macros): Declare.
1575 * c-warn.c: Include "c-family/c-indentation.h".
1576 (warn_for_multistatement_macros): New function.
1577 * c.opt (Wmultistatement-macros): New option.
1578 * c-indentation.c (guard_tinfo_to_string): No longer static.
1579 Change the parameter type to "enum rid". Handle RID_SWITCH.
1580 * c-indentation.h (guard_tinfo_to_string): Declare.
1582 2017-06-23 Marc Glisse <marc.glisse@inria.fr>
1584 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
1586 2017-06-15 Martin Sebor <msebor@redhat.com>
1589 * c.opt (-Wclass-memaccess): New option.
1591 2017-06-14 Boris Kolpackov <boris@codesynthesis.com>
1593 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
1595 2017-06-13 Marek Polacek <polacek@redhat.com>
1598 * c-warn.c (do_warn_duplicated_branches): Return if any of the
1601 2017-06-13 Martin Liska <mliska@suse.cz>
1604 * c-attribs.c (add_no_sanitize_value): New function.
1605 (handle_no_sanitize_attribute): Likewise.
1606 (handle_no_sanitize_address_attribute): Use the function.
1607 (handle_no_sanitize_thread_attribute): New function.
1608 (handle_no_address_safety_analysis_attribute): Use
1609 add_no_sanitize_value.
1610 (handle_no_sanitize_undefined_attribute): Likewise.
1611 * c-common.h: Declare new functions.
1612 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
1613 (ubsan_instrument_shift): Likewise.
1614 (ubsan_instrument_bounds): Likewise.
1615 (ubsan_maybe_instrument_array_ref): Likewise.
1616 (ubsan_maybe_instrument_reference_or_call): Likewise.
1618 2017-06-11 Jason Merrill <jason@redhat.com>
1620 * c-ada-spec.c, c-pragma.c: Use id_equal.
1622 2017-06-04 Marek Polacek <polacek@redhat.com>
1625 * c-format.c (matching_type_p): Return false if any of the types
1626 requires structural equality.
1628 2017-06-02 Martin Sebor <msebor@redhat.com>
1631 * c-warn.c (conversion_warning): Use -Wconversion for integer
1632 conversion and -Wfloat-conversion for floating one.
1634 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
1636 * c.opt (Wsizeof-pointer-div): New warning option.
1638 2017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
1640 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
1641 (Wcatch-value=1): Enable by -Wall.
1643 2017-05-30 David Malcolm <dmalcolm@redhat.com>
1645 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
1647 * c.opt (fdiagnostics-show-template-tree): New option.
1648 (felide-type): New option.
1650 2017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
1652 * c.opt (Wcatch-value=): New C++ warning flag.
1654 2017-05-24 Nathan Sidwell <nathan@acm.org>
1656 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
1657 const casts to avoid warning.
1659 2017-05-24 Martin Sebor <msebor@redhat.com>
1662 * c-common.h (unsafe_conversion_p): Add a function argument.
1663 * c-common.c (unsafe_conversion_p): Same.
1664 Add type names and values to diagnostics.
1665 (scalar_to_vector): Adjust.
1666 * c-warn.c (constant_expression_error): Add a function argument.
1667 Add type names and values to diagnostics.
1668 (conversion_warning): Add a function argument.
1669 Add type names and values to diagnostics.
1670 (warnings_for_convert_and_check): Same.
1672 2017-05-19 Jason Merrill <jason@redhat.com>
1674 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
1677 2017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
1679 * c-format.c (locus): Move out of function scope,
1682 2017-05-19 Nathan Sidwell <nathan@acm.org>
1684 * c-opts.c (class_dump_file, class_dump_flags): Delete.
1685 (c_common_parse_file): Remove class dump handling.
1686 (get_dump_info): Likewise.
1688 2017-05-19 Richard Biener <rguenther@suse.de>
1691 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
1692 to alias-set zero memory.
1694 2017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
1696 * c-format.c (local_tree_type_node): Add GTY attribute.
1698 2017-05-18 Marek Polacek <polacek@redhat.com>
1700 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
1701 (c_common_fixed_point_type_for_size): Likewise.
1702 (c_common_type_for_mode): Likewise.
1703 (shorten_compare): Likewise.
1704 (c_promoting_integer_type_p): Use false/true instead of 0/1.
1705 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
1707 2017-05-18 Marek Polacek <polacek@redhat.com>
1709 * c-common.c (self_promoting_args_p): Change the return type to bool.
1710 Use false/true instead of 0/1.
1711 * c-common.h (self_promoting_args_p): Update.
1713 2017-05-17 Marek Polacek <polacek@redhat.com>
1715 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
1716 * c-warn.c: Likewise.
1718 2017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
1720 Implement new C++ intrinsics __is_assignable and __is_constructible.
1721 * c-common.c (__is_assignable, __is_constructible): New.
1722 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
1724 2017-05-17 Martin Liska <mliska@suse.cz>
1726 * c-common.h: Introduce dump_flags_t type and
1727 use it instead of int type.
1728 * c-gimplify.c (c_genericize): Likewise.
1729 * c-opts.c: Likewise.
1731 2017-05-17 Marek Polacek <polacek@redhat.com>
1733 * c-common.c (c_save_expr): Remove.
1734 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
1735 * c-common.h (c_save_expr): Remove declaration.
1737 2017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
1740 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
1741 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
1742 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
1743 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
1745 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
1747 2017-05-09 Marek Polacek <polacek@redhat.com>
1750 * c-warn.c (unwrap_c_maybe_const): New.
1751 (warn_logical_operator): Call it.
1753 2017-05-09 Nathan Sidwell <nathan@acm.org>
1755 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
1756 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
1758 2017-05-08 Martin Sebor <msebor@redhat.com>
1760 PR translation/80280
1761 * c-format.h (struct format_flag_spec): Add new member.
1763 * c-format.c (local_tree_type_node): New global.
1764 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
1765 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
1766 (strfmon_flag_specs): Likewise.
1767 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
1768 with distinct quoting properties.
1769 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
1770 (flag_chars_t::validate): Add argument and handle bad quoting.
1771 (check_format_info_main): Handle quoting problems.
1772 (init_dynamic_diag_info): Simplify.
1774 2017-05-08 Jason Merrill <jason@redhat.com>
1776 * c-opts.c (c_common_post_options): Update defaults for
1777 flag_abi_version and flag_abi_compat_version.
1779 2017-05-05 David Malcolm <dmalcolm@redhat.com>
1781 * c-common.c (c_cpp_error): Replace report_diagnostic
1782 with diagnostic_report_diagnostic.
1784 2017-05-04 Martin Sebor <msebor@redhat.com>
1786 PR translation/80280
1787 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
1788 (handle_weakref_attribute): Same.
1790 2017-05-03 Nathan Sidwell <nathan@acm.org>
1792 Canonicalize canonical type hashing
1793 * c-common.c (complete_array_type): Use type_hash_canon.
1795 2017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
1798 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
1800 (cilk_install_body_pedigree_operations): Likewise.
1801 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
1803 (cilk_gimplify_call_params_in_spawned_fn): Remove.
1804 (cilk_install_body_pedigree_operations): Likewise.
1805 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
1808 2017-04-27 Jakub Jelinek <jakub@redhat.com>
1811 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
1812 flag on non-aggregate element types.
1814 2017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
1816 * c-common.c (c_type_hasher, type_hash_table): Remove.
1817 (c_common_get_alias_set): Remove unreachable code.
1818 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
1820 2017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
1822 * c.opt (Wextra-semi): New C++ warning flag.
1824 2017-04-20 Jakub Jelinek <jakub@redhat.com>
1827 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
1829 2017-04-18 Jakub Jelinek <jakub@redhat.com>
1833 * c-common.c (c_common_type_for_mode): Don't handle
1834 widest_*_literal_type_node here.
1835 c_common_signed_or_unsigned_type): Likewise.
1836 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
1837 to *intTI_type_node or *intDI_type_node depending on whether
1838 TImode is supported by the target or not.
1840 2017-04-10 Martin Liska <mliska@suse.cz>
1843 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
1844 doing an UBSAN check.
1846 2017-04-03 Jonathan Wakely <jwakely@redhat.com>
1848 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
1850 2017-03-31 Jakub Jelinek <jakub@redhat.com>
1853 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
1855 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
1856 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
1859 2017-03-31 David Malcolm <dmalcolm@redhat.com>
1861 PR documentation/78732
1862 * c.opt (Wendif-labels): Fix description to refer to
1863 #else rather than #elif.
1865 2017-03-31 Jakub Jelinek <jakub@redhat.com>
1868 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
1869 * c-common.c (c_common_reswords): Add __is_aggregate trait.
1871 2017-03-27 Jakub Jelinek <jakub@redhat.com>
1874 * c-common.c (c_common_mark_addressable_vec): Don't set
1875 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
1877 2017-03-21 Martin Sebor <msebor@redhat.com>
1880 * c-common.c (set_underlying_type): Mark type used only when
1881 original del is declared unused.
1883 2017-03-10 David Malcolm <dmalcolm@redhat.com>
1885 PR translation/79848
1886 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
1889 2017-03-10 David Malcolm <dmalcolm@redhat.com>
1892 * c-indentation.c (warn_for_misleading_indentation): Remove parens
1893 from inform's message, so that xgettext can locate it.
1895 2017-03-09 Marek Polacek <polacek@redhat.com>
1899 * c-attribs.c (handle_nonnull_attribute): Save the result of default
1900 conversion to the attribute list.
1902 2017-03-09 Martin Liska <mliska@suse.cz>
1904 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
1906 2017-03-03 Jason Merrill <jason@redhat.com>
1908 * c.opt (Wnoexcept-type): New.
1910 2017-03-02 Richard Biener <rguenther@suse.de>
1913 * c-common.c (c_common_mark_addressable_vec): Look through
1916 2017-02-28 Martin Liska <mliska@suse.cz>
1918 * c.opt: Replace space with tabular for options of <number>
1921 2017-02-28 Martin Liska <mliska@suse.cz>
1923 * c.opt: Fix --help=option -Q for options which are of
1926 2017-02-24 Jakub Jelinek <jakub@redhat.com>
1929 * c-common.c (check_function_restrict): New function.
1930 (check_function_arguments): Add FNDECL argument. Call
1931 check_function_restrict if -Wrestrict.
1932 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
1933 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
1934 * c-common.h (check_function_arguments): Add FNDECL argument.
1935 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
1937 2017-02-24 Eric Botcazou <ebotcazou@adacore.com>
1939 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
1940 treatment of parameters with pointer-to-tagged type and tidy up.
1941 (print_ada_methods): Remove the special treatment of C++ static member
1944 2017-02-22 Martin Liska <mliska@suse.cz>
1946 * c.opt: Replace inequality signs with square brackets
1949 2017-02-21 Jakub Jelinek <jakub@redhat.com>
1952 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
1955 2017-02-17 Joseph Myers <joseph@codesourcery.com>
1957 * c-cppbuiltin.c (builtin_define_float_constants): Define
1958 __DECIMAL_DIG__ to the value for long double.
1960 2017-02-15 Marek Polacek <polacek@redhat.com>
1963 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
1964 conversion has occured.
1966 2017-01-24 David Malcolm <dmalcolm@redhat.com>
1968 * c-common.c (c_common_reswords): Add "__RTL".
1969 * c-common.h (enum rid): Add RID_RTL.
1971 2017-01-20 Marek Polacek <polacek@redhat.com>
1974 * c-common.h (do_warn_duplicated_branches_r): Declare.
1975 * c-gimplify.c (c_genericize): Walk the function tree calling
1976 do_warn_duplicated_branches_r.
1977 * c-warn.c (expr_from_macro_expansion_r): New.
1978 (do_warn_duplicated_branches): New.
1979 (do_warn_duplicated_branches_r): New.
1980 * c.opt (Wduplicated-branches): New option.
1982 2017-01-17 David Malcolm <dmalcolm@redhat.com>
1985 * c-indentation.c (warn_for_misleading_indentation): Use the past
1986 subjunctive in the note.
1988 2017-01-17 Aldy Hernandez <aldyh@redhat.com>
1991 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
1992 start type to integer_type.
1994 2017-01-16 Jakub Jelinek <jakub@redhat.com>
1997 * c.opt (gen-decls): Add Driver flag.
1999 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
2002 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
2005 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
2007 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
2010 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
2012 2017-01-12 Martin Sebor <msebor@redhat.com>
2014 (-Wformat-overflow): ...to this.
2016 2017-01-11 Martin Sebor <msebor@redhat.com>
2019 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
2020 Also enable for LTO.
2022 2017-01-10 Jason Merrill <jason@redhat.com>
2024 Implement P0195R2, C++17 variadic using.
2025 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
2027 2017-01-09 Jakub Jelinek <jakub@redhat.com>
2029 PR translation/79019
2030 PR translation/79020
2031 * c.opt (Wnormalized=): Fix typo in description.
2033 2017-01-08 Martin Sebor <msebor@redhat.com>
2036 * c.opt (-Wformat-truncation): New option.
2038 2017-01-06 Alexandre Oliva <aoliva@redhat.com>
2040 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
2041 value to unsigned short to fit in 4 hex digits without
2044 2017-01-05 Eric Botcazou <ebotcazou@adacore.com>
2046 * c.opt (fsso-struct): Add 'native' value.
2048 2017-01-05 Martin Liska <mliska@suse.cz>
2051 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
2054 2017-01-04 Marek Polacek <polacek@redhat.com>
2057 * c.opt (Wpointer-compare): New option.
2059 2017-01-04 Jakub Jelinek <jakub@redhat.com>
2062 * c.opt (fsso-struct=): Add RejectNegative.
2064 2017-01-01 Jakub Jelinek <jakub@redhat.com>
2066 Update copyright years.
2068 2016-12-29 Martin Liska <mliska@suse.cz>
2071 * c.opt (strong-eval-order): Add RejectNegative keyword.
2073 2016-12-22 Jason Merrill <jason@redhat.com>
2075 Implement P0522R0, matching of template template arguments.
2076 * c-cppbuiltin.c (c_cpp_builtins): Define
2077 __cpp_template_template_args.
2079 2016-12-21 Jakub Jelinek <jakub@redhat.com>
2082 * c-common.c (struct nonnull_arg_ctx): New type.
2083 (check_function_nonnull): Return bool instead of void. Use
2084 nonnull_arg_ctx as context rather than just location_t.
2085 (check_nonnull_arg): Adjust for the new context type, set
2086 warned_p to true if a warning has been diagnosed.
2087 (check_function_arguments): Return bool instead of void.
2088 * c-common.h (check_function_arguments): Adjust prototype.
2090 2016-12-21 Jason Merrill <jason@redhat.com>
2092 * c.opt (-fnew-ttp-matching): New flag.
2093 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
2095 2016-12-14 Martin Jambor <mjambor@suse.cz>
2097 * c-omp.c: Include omp-general.h instead of omp-low.h.
2098 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
2101 2016-12-14 Martin Sebor <msebor@redhat.com>
2104 * c-common.c (check_nonnull_arg): Disable when optimization
2107 2016-12-12 Marek Polacek <polacek@redhat.com>
2110 * c-common.c (attribute_fallthrough_p): Return false for
2113 2016-12-08 Martin Sebor <msebor@redhat.com>
2116 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
2118 2016-12-08 Martin Sebor <msebor@redhat.com>
2121 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
2124 2016-12-07 Martin Sebor <msebor@redhat.com>
2130 * c.opt (-Wstringop-overflow): New option.
2132 2016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
2134 * c-attribs.c (asan odr indicator): New attribute.
2135 (handle_asan_odr_indicator_attribute): New function.
2137 2016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2139 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
2142 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
2144 * c-common.c (excess_precision_mode_join): New.
2145 (c_ts18661_flt_eval_method): New.
2146 (c_c11_flt_eval_method): Likewise.
2147 (c_flt_eval_method): Likewise.
2148 * c-common.h (excess_precision_mode_join): New.
2149 (c_flt_eval_method): Likewise.
2150 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
2151 (cpp_iec_559_value): Call it.
2152 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
2153 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
2154 __FLT_EVAL_METHOD_TS_18661_3__.
2156 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
2158 * c-opts.c (c_common_post_options): Add logic to handle the default
2159 case for -fpermitted-flt-eval-methods.
2161 2016-11-23 Paolo Bonzini <bonzini@gnu.org>
2163 * c.opt (Wexpansion-to-defined): New.
2165 2016-11-23 Jakub Jelinek <jakub@redhat.com>
2168 * c-pragma.c (handle_pragma_target): Don't replace
2169 current_target_pragma, but chainon the new args to the current one.
2171 2016-11-22 Nathan Sidwell <nathan@acm.org>
2173 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
2174 indentation and formatting.
2176 2016-11-21 Martin Sebor <msebor@redhat.com>
2178 * c.opt (-fprintf-return-value): Enable by default.
2180 2016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
2183 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
2184 * c-common.c (c_common_nodes_and_builtins): Initialize
2185 const_tm_ptr_type_node.
2187 2016-11-16 Marek Polacek <polacek@redhat.com>
2190 * c-common.c (c_add_case_label): Turn error_at calls into inform.
2192 2016-11-14 Jakub Jelinek <jakub@redhat.com>
2194 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
2196 2016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
2197 Richard Biener <rguenther@suse.de>
2199 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
2200 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
2201 * c.opt (fgimple): New option.
2203 2016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2206 * c-common.h (warn_for_restrict): Declare.
2207 * c-warn.c: Include gcc-rich-location.h.
2208 (warn_for_restrict): New function.
2209 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
2210 (gcc_cdiag_char_table): Likewise.
2211 (gcc_cxxdiag_char_table): Likewise.
2212 * c.opt (Wrestrict): New option.
2214 2016-11-13 Eric Botcazou <ebotcazou@adacore.com>
2216 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
2217 for nested types only if the type is a record or union and dump SLOC.
2219 2016-11-09 Jason Merrill <jason@redhat.com>
2221 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
2223 2016-11-09 Jakub Jelinek <jakub@redhat.com>
2225 * c-ubsan.c (ubsan_instrument_shift): Handle split
2226 -fsanitize=shift-base and -fsanitize=shift-exponent.
2228 2016-11-07 Jason Merrill <jason@redhat.com>
2230 * c.opt (Wc++1z-compat): New.
2231 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
2233 2016-11-07 Martin Liska <mliska@suse.cz>
2235 * c-warn.c (warn_for_unused_label): Save all labels used
2236 in goto or in &label.
2238 2016-11-03 Jason Merrill <jason@redhat.com>
2240 * c-cppbuiltin.c (c_cpp_builtins): Correct
2241 __cpp_inheriting_constructors.
2243 2016-11-01 Jason Merrill <jason@redhat.com>
2245 * c-cppbuiltin.c (c_cpp_builtins): Update
2246 __cpp_inheriting_constructors.
2248 * c.opt (-fnew-inheriting-ctors): New.
2249 * c-opts.c: Default to on for ABI 11+.
2251 2016-10-31 Jakub Jelinek <jakub@redhat.com>
2254 * c.opt (fext-numeric-literals): Add Var and Init.
2255 * c-opts.c (c_common_handle_option): Don't clear
2256 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
2257 (c_common_post_options): Clear it here if not set
2260 2016-10-28 Aldy Hernandez <aldyh@redhat.com>
2263 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
2266 2016-10-25 Jakub Jelinek <jakub@redhat.com>
2268 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
2269 * c-common.c (c_common_reswords): Add __builtin_launder.
2271 2016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
2273 * c-common.c (c_common_truthvalue_conversion): Warn for
2274 multiplications in boolean context. Fix the quoting of '<<' and '<'
2275 in the shift warning.
2277 2016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
2279 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
2281 2016-10-20 Jason Merrill <jason@redhat.com>
2283 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
2285 2016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
2287 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
2288 integer shift ops in boolean context.
2290 2016-10-18 Aldy Hernandez <aldyh@redhat.com>
2292 * c.opt (Walloca): New.
2293 (Walloca-larger-than=): New.
2294 (Wvla-larger-than=): New.
2296 2016-10-17 Marek Polacek <polacek@redhat.com>
2298 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
2299 Return immediately when finding a match.
2300 (warn_tautological_cmp): Remove a boolean variable that is no longer
2303 2016-10-17 Marek Polacek <polacek@redhat.com>
2305 * c-attribs.c: New file.
2306 * c-common.c: Move attributes handling to c-attribs.c.
2307 (get_nonnull_operand): No longer static.
2308 * c-common.h: Move the declarations from c-attribs.c to its own section.
2310 2016-10-14 Jason Merrill <jason@redhat.com>
2312 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
2313 and __cpp_deduction_guides.
2315 2016-10-13 Jason Merrill <jason@redhat.com>
2317 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
2319 2016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
2321 * c-cppbuiltin.c: Include memmodel.h.
2322 * c-opts.c: Likewise.
2323 * c-pragma.c: Likewise.
2324 * c-warn.c: Likewise.
2326 2016-10-12 Jakub Jelinek <jakub@redhat.com>
2328 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
2329 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
2330 * c-opts.c (sanitize_cpp_opts): Initialize
2331 cpp_opts->cpp_warn_implicit_fallthrough.
2333 2016-10-11 Marek Polacek <polacek@redhat.com>
2335 * c-common.c (warning_candidate_p): Change the return type to bool
2336 and return true/false instead of 1/0.
2337 (vector_mode_valid_p): Likewise.
2339 2016-10-11 Marek Polacek <polacek@redhat.com>
2341 * c-common.c (fold_for_warn): No longer static.
2342 (bool_promoted_to_int_p): Likewise.
2343 (c_common_get_narrower): Likewise.
2344 (constant_expression_warning): Move to c-warn.c.
2345 (constant_expression_error): Likewise.
2346 (overflow_warning): Likewise.
2347 (warn_logical_operator): Likewise.
2348 (find_array_ref_with_const_idx_r): Likewise.
2349 (warn_tautological_cmp): Likewise.
2350 (expr_has_boolean_operands_p): Likewise.
2351 (warn_logical_not_parentheses): Likewise.
2352 (warn_if_unused_value): Likewise.
2353 (strict_aliasing_warning): Likewise.
2354 (sizeof_pointer_memaccess_warning): Likewise.
2355 (check_main_parameter_types): Likewise.
2356 (conversion_warning): Likewise.
2357 (warnings_for_convert_and_check): Likewise.
2358 (match_case_to_enum_1): Likewise.
2359 (match_case_to_enum): Likewise.
2360 (c_do_switch_warnings): Likewise.
2361 (warn_for_omitted_condop): Likewise.
2362 (readonly_error): Likewise.
2363 (lvalue_error): Likewise.
2364 (invalid_indirection_error): Likewise.
2365 (warn_array_subscript_with_type_char): Likewise.
2366 (warn_about_parentheses): Likewise.
2367 (warn_for_unused_label): Likewise.
2368 (warn_for_div_by_zero): Likewise.
2369 (warn_for_memset): Likewise.
2370 (warn_for_sign_compare): Likewise.
2371 (do_warn_double_promotion): Likewise.
2372 (do_warn_unused_parameter): Likewise.
2373 (record_locally_defined_typedef): Likewise.
2374 (maybe_record_typedef_use): Likewise.
2375 (maybe_warn_unused_local_typedefs): Likewise.
2376 (maybe_warn_bool_compare): Likewise.
2377 (maybe_warn_shift_overflow): Likewise.
2378 (warn_duplicated_cond_add_or_warn): Likewise.
2379 (diagnose_mismatched_attributes): Likewise.
2380 * c-common.h: Move the declarations from c-warn.c to its own section.
2381 * c-warn.c: New file.
2383 2016-10-08 Jason Merrill <jason@redhat.com>
2385 * c-common.c (c_common_truthvalue_conversion): Don't distribute
2386 into COND_EXPR in C++.
2388 2016-10-08 Jakub Jelinek <jakub@redhat.com>
2390 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
2391 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
2392 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
2394 2016-10-07 Jakub Jelinek <jakub@redhat.com>
2396 Implement LWG2296 helper intrinsic
2397 * c-common.h (enum rid): Add RID_ADDRESSOF.
2398 * c-common.c (c_common_reswords): Add __builtin_addressof.
2400 2016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
2403 * c-common.c (c_common_truthvalue_conversion): Warn also for
2404 suspicious enum values in boolean context.
2406 2016-10-06 Jakub Jelinek <jakub@redhat.com>
2408 Implement P0258R2 - helper for C++17
2409 std::has_unique_object_representations trait
2410 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
2411 * c-common.c (c_common_reswords): Add
2412 __has_unique_object_representations.
2414 2016-10-05 Jakub Jelinek <jakub@redhat.com>
2417 * c-ubsan.c (ubsan_instrument_return): Don't call
2418 initialize_sanitizer_builtins here.
2420 2016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
2422 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
2423 conditional expression in boolean context when only one arm is
2426 2016-10-05 Jakub Jelinek <jakub@redhat.com>
2429 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
2432 * c-common.c (c_common_reswords): Update comment for C++11.
2434 2016-10-04 Jason Merrill <jason@redhat.com>
2436 * c-common.c (make_tree_vector_from_ctor): New.
2437 * c-common.h: Declare it.
2439 2016-10-04 Jakub Jelinek <jakub@redhat.com>
2441 * c-cppbuiltin.c (c_cpp_builtins): Don't define
2442 __LIBGCC_JCR_SECTION_NAME__.
2444 2016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
2446 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
2447 left shift in boolean context.
2449 2016-09-29 Jakub Jelinek <jakub@redhat.com>
2451 Implement P0001R1 - C++17 removal of register storage class specifier
2452 * c.opt (Wregister): New warning.
2453 * c-opts.c (c_common_post_options): Enable -Wregister by
2456 2016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
2458 * c-opts.c (c_common_post_options): Remove special case for
2459 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
2462 2016-09-27 Jakub Jelinek <jakub@redhat.com>
2464 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
2467 * c-ada-spec.c (print_ada_declaration): Remove break after return.
2469 2016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
2471 * c-common.c: Include memmodel.h.
2473 2016-09-26 Marek Polacek <polacek@redhat.com>
2475 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
2477 2016-09-26 Marek Polacek <polacek@redhat.com>
2480 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
2481 (handle_fallthrough_attribute): New function.
2482 (attribute_fallthrough_p): New function.
2483 * c-common.h (attribute_fallthrough_p): Declare.
2485 2016-09-24 Marek Polacek <polacek@redhat.com>
2488 * c.opt (Wbool-operation): New.
2490 2016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
2492 * c-common.c (c_common_truthvalue_conversion): Inhibit
2493 Wint-in-bool-context warning with from_macro_definition_at.
2494 Mention the expression will always evaluate to true.
2496 2016-09-21 Martin Sebor <msebor@redhat.com>
2499 * c.opt (fprintf-return-value): Temporarily initialize to zero
2500 to unblock bootstrap failures.
2502 2016-09-21 Jakub Jelinek <jakub@redhat.com>
2505 * c.opt (Waligned-new=): Add RejectNegative.
2506 (faligned-new=): Likewise. Spelling fix - change
2507 aligned_new_threshhold to aligned_new_threshold.
2508 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
2509 to aligned_new_threshold.
2511 2016-09-20 Martin Sebor <msebor@redhat.com>
2514 * c.opt: Add -Wformat-length and -fprintf-return-value.
2516 2016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
2519 * c.opt (Wint-in-bool-context): New warning.
2520 * c-common.c (c_common_truthvalue_conversion): Warn on integer
2521 constants in boolean context.
2523 2016-09-19 Joseph Myers <joseph@codesourcery.com>
2525 * c-common.c (max_align_t_align): Also consider alignment of
2528 2016-09-15 Jason Merrill <jason@redhat.com>
2530 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
2533 2016-09-14 Jason Merrill <jason@redhat.com>
2535 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
2536 limit FIELD_DECL, either.
2538 2016-09-14 Marek Polacek <polacek@redhat.com>
2540 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
2541 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
2542 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
2544 2016-09-13 David Malcolm <dmalcolm@redhat.com>
2546 * c-common.c (warn_logical_not_parentheses): Replace
2547 rich_location::add_fixit_insert calls with add_fixit_insert_before
2548 and add_fixit_insert_after, eliminating the "next_loc" calculation.
2550 2016-09-13 Jason Merrill <jason@redhat.com>
2551 Tom de Vries <tom@codesourcery.com>
2554 * c-common.c (set_underlying_type): Don't treat array as builtin type.
2556 2016-09-13 Jason Merrill <jason@redhat.com>
2558 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
2561 2016-09-12 Jason Merrill <jason@redhat.com>
2563 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
2564 bit/byte confusion, allow large alignment for types.
2566 2016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
2569 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
2571 2016-09-12 David Malcolm <dmalcolm@redhat.com>
2574 * c-format.c (argument_parser::check_argument_type): Add params
2575 "type_start" and "conversion_char". Use the former to generate
2576 offset_to_type_start and pass it and conversion_char to
2578 (check_format_info_main): Capture the start of the type
2579 information as "type_start", and pass it an format_char
2580 to arg_parser.check_argument_type.
2581 (check_format_types): Provide an example in the leading comment.
2582 Add params "offset_to_type_start" and "conversion_char"; pass
2583 them to format_type_warning calls.
2584 (test_get_modifier_for_format_len): Likewise.
2585 (matching_type_p): New function.
2586 (get_format_for_type): Add param "conversion_char" and move
2587 implementation into...
2588 (get_format_for_type_1): ...new function, called twice.
2589 Use new function matching_type_p rather than checking for
2590 TYPE_CANONICAL equality.
2591 (get_corrected_substring): New function.
2592 (format_type_warning): Provide an example in the leading comment.
2593 Add params "offset_to_type_start" and "conversion_char". Replace
2594 call to get_format_for_type with call to get_corrected_substring
2595 and move rejection of hints for widths/precisions there.
2596 (assert_format_for_type_streq): Add param "conversion_char".
2597 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
2598 (test_get_format_for_type_printf): Add conversion chars to the
2599 tests, adding coverage for various combinations of integer
2600 vs double conversions, and for preserving octal and hexadecimal
2602 (test_get_format_for_type_scanf): Add conversion chars to the
2605 2016-09-10 Tom de Vries <tom@codesourcery.com>
2608 * c-common.c (build_va_arg): Handle more strict
2609 targetm.canonical_va_list_type. Replace first argument type error with
2612 2016-09-09 Martin Sebor <msebor@redhat.com>
2616 * c-format.c (argument_parser::find_format_char_info): Use %qc
2617 format directive unconditionally.
2619 2016-09-09 Jason Merrill <jason@redhat.com>
2621 Implement C++17 new of over-aligned types.
2622 * c.opt: Add -faligned-new and -Waligned-new.
2623 * c-common.c (max_align_t_align): Split out from...
2624 (cxx_fundamental_alignment_p): ...here.
2625 * c-common.h: Declare it.
2626 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
2628 2016-09-09 Joseph Myers <joseph@codesourcery.com>
2630 * c-cppbuiltin.c (builtin_define_type_width): New function.
2631 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
2634 2016-09-07 David Malcolm <dmalcolm@redhat.com>
2636 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
2638 (substring_loc::get_location): Move to substring-locations.c,
2639 keeping implementation as...
2640 (c_get_substring_location): New function, from the above, reworked
2641 to use accessors rather than member lookup.
2642 * c-common.h (class substring_loc): Move to substring-locations.h,
2643 replacing with a forward decl.
2644 (c_get_substring_location): New decl.
2645 * c-format.c: Include "substring-locations.h".
2646 (format_warning_va): Move to substring-locations.c.
2647 (format_warning_at_substring): Likewise.
2649 2016-09-06 Martin Sebor <msebor@redhat.com>
2652 * c-format.c (check_function_format): Avoid issuing warnings for
2653 functions unless they call format functions with non-constant
2656 2016-09-06 Richard Biener <rguenther@suse.de>
2659 * c-common.c (c_common_mark_addressable_vec): Handle
2660 COMPOUND_LITERAL_EXPR.
2662 2016-09-05 Marek Polacek <polacek@redhat.com>
2665 * c-common.c (bool_promoted_to_int_p): New function.
2666 (expr_has_boolean_operands_p): New function.
2667 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
2668 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
2670 2016-09-04 Tom de Vries <tom@codesourcery.com>
2673 2016-08-29 Tom de Vries <tom@codesourcery.com>
2675 * c-common.c (build_va_arg): Replace first argument type error
2678 2016-09-02 Jakub Jelinek <jakub@redhat.com>
2681 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
2682 (c_finish_omp_for): Reject _Atomic qualified iterators.
2684 2016-09-01 Martin Sebor <msebor@redhat.com>
2686 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
2687 size to guarantee it fits the output of the formatted function
2688 regardless of its arguments.
2690 2016-09-01 Marek Polacek <polacek@redhat.com>
2693 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
2696 2016-08-29 Marek Polacek <polacek@redhat.com>
2699 * c-common.c (warn_logical_not_parentheses): Don't warn for
2700 a comparison or a logical operator.
2702 2016-08-29 Tom de Vries <tom@codesourcery.com>
2704 * c-common.c (build_va_arg): Fix type comparison assert.
2706 2016-08-29 Tom de Vries <tom@codesourcery.com>
2708 * c-common.c (build_va_arg): Replace first argument type error
2711 2016-08-29 Tom de Vries <tom@codesourcery.com>
2714 * c-common.c (build_va_arg): Add first argument error. Build va_arg
2715 with error_mark_node as va_list instead of with illegal va_list.
2717 2016-08-25 Marek Polacek <polacek@redhat.com>
2718 David Malcolm <dmalcolm@redhat.com>
2720 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
2721 * c-common.h (warn_logical_not_parentheses): Update declaration.
2723 2016-08-22 Marek Polacek <polacek@redhat.com>
2726 * c-common.c (warn_for_memset): Check type for null.
2728 2016-08-22 Joseph Myers <joseph@codesourcery.com>
2730 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
2731 _FloatNx types for suffixes for built-in functions.
2733 2016-08-19 Joseph Myers <joseph@codesourcery.com>
2736 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
2737 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
2738 (RID_FLOAT128X): New enum rid values.
2739 (CASE_RID_FLOATN_NX): New macro.
2740 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
2742 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
2743 corresponding complex types.
2744 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
2745 _FloatNx and corresponding complex types.
2746 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
2747 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
2748 and _FloatNx types for the widest type for determining
2749 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
2750 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
2751 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
2753 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
2755 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
2758 2016-08-18 David Malcolm <dmalcolm@redhat.com>
2760 * c-opts.c (c_diagnostic_finalizer): Update for change to
2761 diagnostic_show_locus.
2763 2016-08-18 David Malcolm <dmalcolm@redhat.com>
2765 * c-common.c: Include "spellcheck.h".
2766 (cb_get_suggestion): New function.
2767 * c-common.h (cb_get_suggestion): New decl.
2768 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
2771 2016-08-18 Marek Polacek <polacek@redhat.com>
2774 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
2777 2016-08-16 David Malcolm <dmalcolm@redhat.com>
2780 * c-common.c (substring_loc::get_range): Rename to...
2781 (substring_loc::get_location): ...this, converting param from a
2782 source_range * to a location_t *. Call
2783 get_source_location_for_substring rather than
2784 get_source_range_for_substring, and pass in m_caret_idx.
2785 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
2786 (substring_loc::get_range): Replace with...
2787 (substring_loc::get_location): ...this.
2788 (substring_loc::set_caret_index): New method.
2789 (substring_loc): Add field m_caret_idx.
2790 * c-format.c (format_warning_va): Update for above changes.
2791 Rename local "substring_loc" to "fmt_substring_loc" to avoid
2792 clashing with type name.
2793 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
2794 (check_argument_type): Likewise.
2795 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
2796 Use a copy when emitting warnings, setting the caret index from TYPE.
2798 2016-08-16 Eric Botcazou <ebotcazou@adacore.com>
2799 Arnaud Charlet <charlet@adacore.com>
2801 * c-ada-spec.c (dump_number): New function.
2802 (handle_escape_character): Likewise.
2803 (print_ada_macros): Add handling of constant integers and strings.
2805 2016-08-12 Marek Polacek <polacek@redhat.com>
2808 * c-common.c (scalar_to_vector): Adjust fall through comment.
2809 * c-opts.c (c_common_handle_option): Likewise.
2810 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
2811 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
2812 fall through comment.
2813 * cilk.c (extract_free_variables): Add FALLTHRU.
2815 2016-08-10 Jason Merrill <jason@redhat.com>
2817 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
2819 2016-08-09 Jason Merrill <jason@redhat.com>
2821 * c-common.c (c_common_attribute_table): vector_size affects type
2824 2016-08-09 Marek Polacek <polacek@redhat.com>
2827 * c-ada-spec.c (dump_generic_ada_node): Add return.
2829 2016-08-09 Jason Merrill <jason@redhat.com>
2831 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
2832 C++17 constexpr lambdas.
2834 2016-08-08 David Malcolm <dmalcolm@redhat.com>
2837 * c-common.h (selftest::c_format_c_tests): New declaration.
2838 (selftest::run_c_tests): New declaration.
2839 * c-format.c: Include "selftest.h.
2840 (format_warning_va): Add param "corrected_substring" and use
2841 it to add a replacement fix-it hint.
2842 (format_warning_at_substring): Likewise.
2843 (format_warning_at_char): Update for new param of
2845 (argument_parser::check_argument_type): Pass "fki" to
2847 (check_format_types): Add param "fki" and pass it to
2848 format_type_warning.
2849 (deref_n_times): New function.
2850 (get_modifier_for_format_len): New function.
2851 (selftest::test_get_modifier_for_format_len): New function.
2852 (get_format_for_type): New function.
2853 (format_type_warning): Add param "fki" and use it to attempt
2854 to provide hints for argument types when calling
2855 format_warning_at_substring.
2856 (selftest::get_info): New function.
2857 (selftest::assert_format_for_type_streq): New function.
2858 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
2859 (selftest::test_get_format_for_type_printf): New function.
2860 (selftest::test_get_format_for_type_scanf): New function.
2861 (selftest::c_format_c_tests): New function.
2863 2016-08-08 David Malcolm <dmalcolm@redhat.com>
2866 * c-format.c: Include "diagnostic.h".
2867 (location_column_from_byte_offset): Delete.
2868 (location_from_offset): Delete.
2869 (format_warning_va): New function.
2870 (format_warning_at_substring): New function.
2871 (format_warning_at_char): New function.
2872 (check_format_arg): Capture location of format_tree and pass to
2873 check_format_info_main.
2874 (argument_parser): Add fields "start_of_this_format" and
2875 "format_string_cst".
2876 (flag_chars_t::validate): Add param "format_string_cst". Convert
2877 warning_at call using location_from_offset to call to
2878 format_warning_at_char.
2879 (argument_parser::argument_parser): Add param "format_string_cst_"
2880 and use use it to initialize field "format_string_cst".
2881 Initialize new field "start_of_this_format".
2882 (argument_parser::read_format_flags): Convert warning_at call
2883 using location_from_offset to a call to format_warning_at_char.
2884 (argument_parser::read_any_format_left_precision): Likewise.
2885 (argument_parser::read_any_format_precision): Likewise.
2886 (argument_parser::read_any_other_modifier): Likewise.
2887 (argument_parser::find_format_char_info): Likewise, in three places.
2888 (argument_parser::parse_any_scan_set): Likewise, in one place.
2889 (argument_parser::handle_conversions): Likewise, in two places.
2890 (argument_parser::check_argument_type): Add param "fmt_param_loc"
2891 and use it to make a substring_loc. Pass the latter to
2893 (check_format_info_main): Add params "fmt_param_loc" and
2894 "format_string_cst". Convert warning_at calls using
2895 location_from_offset to calls to format_warning_at_char. Pass the
2896 new params to the arg_parser ctor. Pass "format_string_cst" to
2897 flag_chars.validate. Pass "fmt_param_loc" to
2898 arg_parser.check_argument_type.
2899 (check_format_types): Convert first param from a location_t
2900 to a const substring_loc & and rename to "fmt_loc". Attempt
2901 to extract the range of the relevant parameter and pass it
2902 to format_type_warning.
2903 (format_type_warning): Convert first param from a location_t
2904 to a const substring_loc & and rename to "fmt_loc". Add
2905 params "param_range" and "type". Replace calls to warning_at
2906 with calls to format_warning_at_substring.
2908 2016-08-08 David Malcolm <dmalcolm@redhat.com>
2910 * c-format.c (class flag_chars_t): New class.
2911 (struct length_modifier): New struct.
2912 (class argument_parser): New class.
2913 (flag_chars_t::flag_chars_t): New ctor.
2914 (flag_chars_t::has_char_p): New method.
2915 (flag_chars_t::add_char): New method.
2916 (flag_chars_t::validate): New method.
2917 (flag_chars_t::get_alloc_flag): New method.
2918 (flag_chars_t::assignment_suppression_p): New method.
2919 (argument_parser::argument_parser): New ctor.
2920 (argument_parser::read_any_dollar): New method.
2921 (argument_parser::read_format_flags): New method.
2922 (argument_parser::read_any_format_width): New method.
2923 (argument_parser::read_any_format_left_precision): New method.
2924 (argument_parser::read_any_format_precision): New method.
2925 (argument_parser::handle_alloc_chars): New method.
2926 (argument_parser::read_any_length_modifier): New method.
2927 (argument_parser::read_any_other_modifier): New method.
2928 (argument_parser::find_format_char_info): New method.
2929 (argument_parser::validate_flag_pairs): New method.
2930 (argument_parser::give_y2k_warnings): New method.
2931 (argument_parser::parse_any_scan_set): New method.
2932 (argument_parser::handle_conversions): New method.
2933 (argument_parser::check_argument_type): New method.
2934 (check_format_info_main): Introduce classes argument_parser
2935 and flag_chars_t, moving the code within the loop into methods
2936 of these classes. Make various locals "const".
2938 2016-08-05 David Malcolm <dmalcolm@redhat.com>
2940 * c-common.c: Include "substring-locations.h".
2941 (get_cpp_ttype_from_string_type): New function.
2942 (g_string_concat_db): New global.
2943 (substring_loc::get_range): New method.
2944 * c-common.h (g_string_concat_db): New declaration.
2945 (class substring_loc): New class.
2946 * c-lex.c (lex_string): When concatenating strings, capture the
2947 locations of all tokens using a new obstack, and record the
2948 concatenation locations within g_string_concat_db.
2949 * c-opts.c (c_common_init_options): Construct g_string_concat_db
2952 2016-07-29 Marek Polacek <polacek@redhat.com>
2955 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
2956 parentheses warning.
2959 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
2961 2016-07-28 Martin Liska <mliska@suse.cz>
2963 PR gcov-profile/68025
2964 * c-common.c (handle_no_profile_instrument_function_attribute):
2966 2016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
2968 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
2971 2016-07-25 Jason Merrill <jason@redhat.com>
2974 * c.opt (fconstexpr-loop-limit): New.
2976 2016-07-22 Martin Sebor <msebor@redhat.com>
2979 * c-common.c (resolve_overloaded_builtin): Avoid converting
2980 __atomic_compare_exchange_n return type to that of what its
2981 first argument points to.
2983 2016-07-22 Uros Bizjak <ubizjak@gmail.com>
2985 * c-common.c: Use HOST_WIDE_INT_M1U instead of
2986 ~(unsigned HOST_WIDE_INT) 0.
2988 2016-07-22 Martin Liska <mliska@suse.cz>
2990 PR gcov-profile/69028
2991 PR gcov-profile/62047
2992 * cilk.c (create_cilk_helper_decl): Set location of a new decl
2993 to the current_function_decl.
2995 2016-07-21 Jason Merrill <jason@redhat.com>
2998 * c-common.c (c_common_truthvalue_conversion): Check
2999 c_inhibit_evaluation_warnings for warning about address of
3002 2016-07-20 David Malcolm <dmalcolm@redhat.com>
3004 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
3007 2016-07-15 Jason Merrill <jason@redhat.com>
3009 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
3011 2016-07-15 Jakub Jelinek <jakub@redhat.com>
3014 * c-common.h (enum lookup_name_fuzzy_kind): Add
3015 FUZZY_LOOKUP_FUNCTION_NAME.
3017 2016-07-08 Jason Merrill <jason@redhat.com>
3019 P0145: Refining Expression Order for C++.
3020 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
3023 2016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
3026 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
3028 2016-06-29 Thomas Schwinge <thomas@codesourcery.com>
3030 * c-pragma.h (enum pragma_kind): Rename
3031 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
3034 2016-06-29 Richard Biener <rguenther@suse.de>
3037 * c-common.c (c_common_get_alias_set): Remove union type punning case.
3039 2016-06-24 Jason Merrill <jason@redhat.com>
3041 P0145R2: Refining Expression Order for C++.
3042 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
3045 2016-06-24 Jakub Jelinek <jakub@redhat.com>
3047 * c-common.c (check_builtin_function_arguments): Require last
3048 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
3049 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
3050 if the last argument is pointer to enumerated or boolean type.
3052 2016-06-22 David Malcolm <dmalcolm@redhat.com>
3055 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
3056 (lookup_name_fuzzy): New prototype.
3058 2016-06-21 John David Anglin <danglin@gcc.gnu.org>
3060 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
3062 2016-06-14 Jason Merrill <jason@redhat.com>
3064 P0145R2: Refining Expression Order for C++.
3065 * c.opt (fargs-in-order): New.
3066 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
3068 2016-06-13 Jakub Jelinek <jakub@redhat.com>
3071 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
3072 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
3074 PR preprocessor/71183
3075 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
3076 to cb_get_source_date_epoch.
3078 2016-06-10 Jakub Jelinek <jakub@redhat.com>
3081 * c.opt (Wpsabi): Add Warning flag.
3083 2016-06-10 Martin Sebor <msebor@redhat.com>
3086 * c-common.c (handle_nonnull_attribute): Accept
3087 the nonnull attribute in type-generic builtins.
3089 2016-06-09 Martin Sebor <msebor@redhat.com>
3092 * c-common.c (builtin_function_validate_nargs): Make text of error
3093 message consistent with others like it.
3095 2016-06-08 Martin Sebor <msebor@redhat.com>
3096 Jakub Jelinek <jakub@redhat.com>
3100 * c-common.c (check_builtin_function_arguments): Handle
3101 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
3103 2016-06-08 Richard Biener <rguenther@suse.de>
3105 * c-common.c (parse_optimize_options): Improve diagnostic messages.
3107 2016-06-07 Richard Biener <rguenther@suse.de>
3110 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
3111 options and warn about others.
3113 2016-06-01 Eduard Sanou <dhole@openmailbox.org>
3115 * c-common.c (get_source_date_epoch): Rename to
3116 cb_get_source_date_epoch.
3117 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
3118 message when the parsing fails. Use error_at instead of fatal_error.
3119 * c-common.h (get_source_date_epoch): Rename to
3120 cb_get_source_date_epoch.
3121 * c-common.h (cb_get_source_date_epoch): Prototype.
3122 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
3123 * c-common.h (c_omp_region_type): Remove trailing comma.
3124 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
3125 * c-lex.c (c_lex_with_flags): Remove initialization of
3126 pfile->source_date_epoch.
3128 2016-05-30 Jakub Jelinek <jakub@redhat.com>
3131 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
3132 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
3133 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
3134 instead of C_OMP_CLAUSE_SPLIT_FOR.
3136 2016-05-24 Richard Biener <rguenther@suse.de>
3140 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
3141 (convert_vector_to_array_for_subscript): ... this.
3142 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
3143 VIEW_CONVERT_EXPR to an array type. Rename to ...
3144 (convert_vector_to_array_for_subscript): ... this.
3146 2016-05-12 Marek Polacek <polacek@redhat.com>
3149 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
3150 size_in_bytes and pass LOC to it.
3152 2016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
3155 * c.opt (Wduplicate-decl-specifier): New option.
3157 2016-05-11 Marek Polacek <polacek@redhat.com>
3160 * c-common.c (diagnose_mismatched_attributes): New function.
3161 * c-common.h (diagnose_mismatched_attributes): Declare.
3163 2016-05-04 Marek Polacek <polacek@redhat.com>
3165 * c.opt (Wdangling-else): New option.
3167 2016-05-03 Marek Polacek <polacek@redhat.com>
3170 * c-common.c (builtin_function_validate_nargs): Add location
3172 (check_builtin_function_arguments): Add location and arguments
3173 parameters. Use them.
3174 * c-common.h (check_builtin_function_arguments): Update declaration.
3176 2016-05-03 Richard Biener <rguenther@suse.de>
3178 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
3179 allow call args to gimplify to SSA names.
3181 2016-05-03 Marek Polacek <polacek@redhat.com>
3183 * c-common.h (enum c_omp_region_type): Remove stray comma.
3185 2016-05-02 Cesar Philippidis <cesar@codesourcery.com>
3187 * c-common.h (enum c_omp_region_type): Define.
3189 2016-05-02 Richard Sandiford <richard.sandiford@arm.com>
3191 * c-common.c (shorten_compare): Use wi::to_wide.
3193 2016-04-29 Cesar Philippidis <cesar@codesourcery.com>
3196 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
3197 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
3198 reduction clauses in acc parallel loops.
3200 2016-04-29 Marek Polacek <polacek@redhat.com>
3203 * c-common.c (warn_for_memset): Check domain before accessing it.
3205 2016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
3208 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
3209 "aligned" attribute.
3211 2016-04-28 Jason Merrill <jason@redhat.com>
3213 * c-lex.c (c_common_has_attribute): Handle nodiscard.
3215 2016-04-28 Eduard Sanou <dhole@openmailbox.org>
3216 Matthias Klose <doko@debian.org>
3218 * c-common.c (get_source_date_epoch): New function, gets the environment
3219 variable SOURCE_DATE_EPOCH and parses it as long long with error
3221 * c-common.h (get_source_date_epoch): Prototype.
3222 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
3224 2015-04-27 Ryan Burn <contact@rnburn.com>
3228 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
3229 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
3231 (cilk_detect_and_unwrap): Corresponding changes.
3232 (extract_free_variables): Don't extract free variables from
3233 AGGR_INIT_EXPR slot.
3234 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
3235 (cilk_recognize_spawn): Likewise.
3237 2016-04-27 Bernd Schmidt <bschmidt@redhat.com>
3239 * c.opt (Wmemset-elt-size): New option.
3240 * c-common.c (warn_for_memset): New function.
3241 * c-common.h (warn_for_memset): Declare.
3243 2016-04-25 Jason Merrill <jason@redhat.com>
3245 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
3247 * c-common.h: Declare it.
3248 * c-lex.c (c_common_has_attribute): Add maybe_unused.
3250 2016-04-22 Jason Merrill <jason@redhat.com>
3252 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
3254 2016-04-20 Ilya Verbin <ilya.verbin@intel.com>
3257 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
3258 * c-common.h (c_finish_cilk_clauses): Remove declaration.
3260 2016-04-18 Michael Matz <matz@suse.de>
3262 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
3265 2016-04-17 Eric Botcazou <ebotcazou@adacore.com>
3267 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
3268 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
3269 to incomplete types.
3270 (dump_nested_type): Remove redundant tests and tidy up.
3271 (print_ada_declaration): Also set TREE_VISITED on the declaration of
3272 a type which is the typedef of an original type.
3274 2016-04-15 Marek Polacek <polacek@redhat.com>
3277 * c-common.c (build_va_arg): Change two asserts into errors and return
3280 2016-04-13 Marek Polacek <polacek@redhat.com>
3283 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
3284 for switch statements, too.
3286 2016-03-28 Jason Merrill <jason@redhat.com>
3288 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
3290 2016-03-23 Marek Polacek <polacek@redhat.com>
3293 * c.opt (Wignored-attributes): New option.
3295 2016-03-22 David Malcolm <dmalcolm@redhat.com>
3298 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
3299 diagnostic text, reversing the order of the warning and note so
3300 that they appear in source order.
3302 2016-03-17 Marek Polacek <polacek@redhat.com>
3305 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
3308 2016-03-14 Jason Merrill <jason@redhat.com>
3310 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
3312 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
3314 2016-03-09 Richard Biener <rguenther@suse.de>
3317 * c-common.c (strict_aliasing_warning): Add back
3318 alias_sets_conflict_p check.
3320 2016-03-08 Jason Merrill <jason@redhat.com>
3322 * c-opts.c (set_std_cxx1z): Don't enable concepts.
3324 2016-03-04 David Malcolm <dmalcolm@redhat.com>
3327 * c-indentation.c (get_visual_column): Move code to determine next
3329 (next_tab_stop): ...this new function.
3330 (line_contains_hash_if): Delete function.
3331 (detect_preprocessor_logic): Delete function.
3332 (get_first_nws_vis_column): New function.
3333 (detect_intervening_unindent): New function.
3334 (should_warn_for_misleading_indentation): Replace call to
3335 detect_preprocessor_logic with a call to
3336 detect_intervening_unindent.
3338 2016-03-04 David Malcolm <dmalcolm@redhat.com>
3341 * c-indentation.c (should_warn_for_misleading_indentation): When
3342 suppressing warnings about cases where the guard and body are on
3343 the same column, only use the first non-whitespace column in place
3344 of the guard token column when dealing with "else" clauses.
3345 When rejecting aligned BODY and NEXT, loosen the requirement
3346 from equality with the first non-whitespace of guard to simply
3347 that they not be indented relative to it.
3349 2016-03-04 Richard Biener <rguenther@suse.de>
3352 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
3353 instead of alias_sets_conflict_p.
3355 2016-03-01 Marek Polacek <polacek@redhat.com>
3358 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
3361 2016-02-22 Martin Sebor <msebor@redhat.com>
3364 * c-common.c (check_builtin_function_arguments): Validate and
3365 reject invalid arguments to __builtin_alloca_with_align.
3367 2016-02-20 Mark Wielaard <mjw@redhat.com>
3370 * c.opt (Wunused-const-variable): Turn into Alias for...
3371 (Wunused-const-variable=): New option.
3373 2016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
3376 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
3378 (c_common_init_options): ...to here.
3379 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
3381 2016-02-19 Jakub Jelinek <jakub@redhat.com>
3384 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
3385 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
3386 flag_preprocess_only.
3388 2016-02-16 Jakub Jelinek <jakub@redhat.com>
3391 * c.opt (Wnonnull-compare): Enable for -Wall.
3393 2016-02-15 Jakub Jelinek <jakub@redhat.com>
3396 * c-common.c (sync_resolve_size): Diagnose too few arguments
3397 even when params is non-NULL empty vector.
3399 2016-02-08 Bernd Schmidt <bschmidt@redhat.com>
3402 * c.opt (fshort-double): Remove.
3404 2016-02-05 Martin Sebor <msebor@redhat.com>
3407 * c.opt (Warning options): Update -Wplacement-new to take
3408 an optional argument.
3410 2016-02-01 Jakub Jelinek <jakub@redhat.com>
3412 PR preprocessor/69543
3414 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
3415 instead of loc to control_warning_option.
3417 2016-02-01 Nathan Sidwell <nathan@codesourcery.com>
3419 * c.opt (fopenacc-dim=): New option.
3421 2016-01-27 Ryan Burn <contact@rnburn.com>
3424 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
3425 gimplify_arg. Removed superfluous post_p argument.
3426 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
3427 superfluous post_p argument.
3428 * c-gimplify.c (c_gimplify_expr): Likewise.
3430 2016-01-26 David Malcolm <dmalcolm@redhat.com>
3433 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
3434 pp_newline_and_flush with pp_flush.
3436 2016-01-20 Martin Sebor <msebor@redhat.com>
3439 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
3440 an incompatible argument when the argument isn't a valid tree node.
3442 2016-01-18 Jason Merrill <jason@redhat.com>
3445 * c-common.c (check_function_arguments_recurse): Fold the whole
3446 COND_EXPR, not just the condition.
3448 2016-01-18 Tom de Vries <tom@codesourcery.com>
3450 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
3451 classify as loop clause.
3453 2016-01-15 Jakub Jelinek <jakub@redhat.com>
3456 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
3457 C++ FE no longer has limit on number of pragmas.
3459 2015-01-14 Ryan Burn <contact@rnburn.com>
3462 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
3463 to add missing cleanup point.
3465 2016-01-14 David Malcolm <dmalcolm@redhat.com>
3468 * c-indentation.c (get_visual_column): Add location_t param.
3469 Handle the column number being zero by effectively disabling the
3470 warning, with an "inform".
3471 (should_warn_for_misleading_indentation): Add location_t argument
3472 for all uses of get_visual_column.
3474 2016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
3477 * c-indentation.c (should_warn_for_misleading_indentation):
3478 Don't warn about do-while statements.
3480 2016-01-07 Martin Sebor <msebor@redhat.com>
3483 * c-common.c (sync_resolve_size): Reject first argument when it's
3486 2016-01-05 David Malcolm <dmalcolm@redhat.com>
3489 * c-indentation.c (get_visual_column): Remove default argument.
3490 (should_warn_for_misleading_indentation): For the multiline case,
3491 update call to get_visual_column for next_stmt_exploc so that it
3492 captures the location of the first non-whitespace character in the
3493 relevant line. Don't issue warnings if there is non-whitespace
3494 before the next statement.
3496 2016-01-04 Jakub Jelinek <jakub@redhat.com>
3498 Update copyright years.
3500 2015-12-21 David Malcolm <dmalcolm@redhat.com>
3502 * c-common.c (binary_op_error): Convert first param from
3503 location_t to rich_location * and use it when emitting an error.
3504 * c-common.h (binary_op_error): Convert first param from
3505 location_t to rich_location *.
3507 2015-12-16 David Malcolm <dmalcolm@redhat.com>
3509 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
3510 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
3512 2015-12-15 Ilya Verbin <ilya.verbin@intel.com>
3514 * c-common.c (c_common_attribute_table): Handle "omp declare target
3517 2015-12-14 Jakub Jelinek <jakub@redhat.com>
3520 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
3522 2014-12-12 Tobias Burnus <burnus@net-b.de>
3525 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
3526 specifiers (%d, %i,%u and %c).
3528 2015-12-10 David Malcolm <dmalcolm@redhat.com>
3530 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
3532 2015-12-08 Jakub Jelinek <jakub@redhat.com>
3536 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
3537 * c-pragma.c (handle_pragma_diagnostic): Adjust
3538 control_warning_option caller.
3540 2015-12-07 David Malcolm <dmalcolm@redhat.com>
3542 * c-common.c (c_cpp_error): Update for change to
3543 rich_location::set_range.
3545 2015-12-04 Paolo Bonzini <bonzini@gnu.org>
3547 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
3548 shifting 1 out of the sign bit.
3550 2015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
3552 * c-common.c (c_common_attribute_table[]): Update max arguments
3553 count for "simd" attribute.
3554 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
3556 2015-12-03 Jakub Jelinek <jakub@redhat.com>
3558 PR preprocessor/57580
3559 * c-ppoutput.c (print): Change printed field to bool.
3560 Move src_file last for smaller padding.
3561 (init_pp_output): Set print.printed to false instead of 0.
3562 (scan_translation_unit): Fix up formatting. Set print.printed
3563 to true after printing something other than newline.
3564 (scan_translation_unit_trad): Set print.printed to true instead of 1.
3565 (maybe_print_line_1): Set print.printed to false instead of 0.
3566 (print_line_1): Likewise.
3567 (do_line_change): Set print.printed to true instead of 1.
3568 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
3569 dump_macro): Set print.printed to false after printing newline.
3571 2015-12-02 Jason Merrill <jason@redhat.com>
3573 * c-common.c (fold_for_warn): New.
3574 (warn_logical_operator, warn_tautological_cmp)
3575 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
3577 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
3578 (c_fully_fold_internal, decl_constant_value_for_optimization):
3580 * c-common.h: Don't declare decl_constant_value_for_optimization.
3582 2015-12-02 Joseph Myers <joseph@codesourcery.com>
3585 * c-common.h (c_build_qualified_type): Add extra default
3588 2015-12-01 Julian Brown <julian@codesourcery.com>
3589 Cesar Philippidis <cesar@codesourcery.com>
3590 James Norris <James_Norris@mentor.com>
3592 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
3593 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
3594 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
3596 2015-11-30 Eric Botcazou <ebotcazou@adacore.com>
3598 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
3599 (decl_sloc_common): Delete and move bulk of processing to...
3600 (decl_sloc): ...here.
3601 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
3602 (dump_ada_double_name): Remove S parameter and compute the suffix.
3603 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
3604 element type and deal with an anonymous one.
3605 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
3606 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
3607 and remove reference to QUAL_UNION_TYPE.
3608 (dump_nested_types): Make 2 passes on the fields and move bulk to...
3609 (dump_nested_type): ...here. New function extracted from above.
3610 Generate a full declaration for anonymous element type of arrays.
3611 (print_ada_declaration): Really skip anonymous declarations. Remove
3612 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
3613 Clean up processing of declarations of array types and objects.
3614 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
3615 Remove obsolete code and tidy up.
3617 2015-11-29 Jan Hubicka <hubicka@ucw.cz>
3620 * c-common.c (handle_transparent_union_attribute): Update
3623 2015-11-27 Martin Liska <mliska@suse.cz>
3626 * array-notation-common.c (cilkplus_extract_an_triplets):
3627 Release vector of vectors.
3628 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
3630 2015-11-26 Eric Botcazou <ebotcazou@adacore.com>
3633 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
3634 (print_ada_struct_decl): Likewise.
3636 2015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
3639 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
3640 * cilk.c (recognize_spawn): Determine location in a more precise
3643 2015-11-19 Jason Merrill <jason@redhat.com>
3645 * c-common.c (shorten_compare): But look through macros from
3648 2015-11-18 Jason Merrill <jason@redhat.com>
3650 * c-common.c (shorten_compare): Don't -Wtype-limits if the
3651 non-constant operand comes from a macro.
3653 2015-11-17 Jason Merrill <jason@redhat.com>
3656 * c-common.c (warn_tautological_cmp): Fold before checking for
3659 2015-11-16 Marek Polacek <polacek@redhat.com>
3662 * c-common.c (check_case_bounds): Fold low and high cases.
3664 2015-11-16 Marek Polacek <polacek@redhat.com>
3666 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
3667 * c-common.c (c_common_get_alias_set): Likewise.
3668 (handle_visibility_attribute): Likewise.
3670 2015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
3672 * c-common.c (handle_simd_attribute): New.
3673 (struct attribute_spec): Add entry for "simd".
3674 (handle_simd_attribute): New.
3676 2015-11-13 Kai Tietz <ktietz70@googlemail.com>
3678 * c-lex.c (interpret_float): Use fold_convert.
3680 2015-11-13 David Malcolm <dmalcolm@redhat.com>
3682 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
3683 and store it on the result.
3684 * c-opts.c (c_common_init_options): Set
3685 global_dc->colorize_source_p.
3687 2015-11-12 James Norris <jnorris@codesourcery.com>
3688 Joseph Myers <joseph@codesourcery.com>
3690 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
3691 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
3692 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
3693 PRAGMA_OACC_CLAUSE_LINK.
3695 2015-11-11 Marek Polacek <polacek@redhat.com>
3699 * c-common.c (valid_array_size_p): New function.
3700 * c-common.h (valid_array_size_p): Declare.
3702 2015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
3705 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
3707 2015-11-11 Andrew MacLeod <amacleod@redhat.com>
3709 * array-notation-common.c: Remove unused header files.
3710 * c-ada-spec.c: Likewise.
3711 * c-cilkplus.c: Likewise.
3712 * c-common.c: Likewise.
3713 * c-cppbuiltin.c: Likewise.
3714 * c-dump.c: Likewise.
3715 * c-format.c: Likewise.
3716 * c-gimplify.c: Likewise.
3717 * c-indentation.c: Likewise.
3718 * c-lex.c: Likewise.
3719 * c-omp.c: Likewise.
3720 * c-opts.c: Likewise.
3721 * c-pch.c: Likewise.
3722 * c-ppoutput.c: Likewise.
3723 * c-pragma.c: Likewise.
3724 * c-pretty-print.c: Likewise.
3725 * c-semantics.c: Likewise.
3726 * c-ubsan.c: Likewise.
3728 * stub-objc.c: Likewise.
3730 2015-11-09 Thomas Schwinge <thomas@codesourcery.com>
3731 Cesar Philippidis <cesar@codesourcery.com>
3732 James Norris <jnorris@codesourcery.com>
3733 Julian Brown <julian@codesourcery.com>
3734 Nathan Sidwell <nathan@codesourcery.com>
3736 * c-pragma.c (oacc_pragmas): Add "routine".
3737 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
3739 2015-11-08 Eric Botcazou <ebotcazou@adacore.com>
3741 * c-common.c (c_common_attributes): Add scalar_storage_order.
3742 (handle_scalar_storage_order_attribute): New function.
3743 * c-pragma.c (global_sso): New variable.
3744 (maybe_apply_pragma_scalar_storage_order): New function.
3745 (handle_pragma_scalar_storage_order): Likewise.
3746 (init_pragma): Register scalar_storage_order.
3747 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
3748 * c.opt (Wscalar-storage-order): New warning.
3749 (fsso-struct=): New option.
3751 2015-11-08 Martin Sebor <msebor@redhat.com>
3753 * c.opt (Wplacement-new): Add a period to the end of a sentence.
3755 2015-11-07 Richard Sandiford <richard.sandiford@arm.com>
3757 * c-common.c: Don't undef DEF_BUILTIN.
3759 2015-11-06 David Malcolm <dmalcolm@redhat.com>
3761 * c-common.c (c_cpp_error): Convert parameter from location_t to
3762 rich_location *. Eliminate the "column_override" parameter and
3763 the call to diagnostic_override_column.
3764 Update the "done_lexing" clause to set range 0
3765 on the rich_location, rather than overwriting a location_t.
3766 * c-common.h (c_cpp_error): Convert parameter from location_t to
3767 rich_location *. Eliminate the "column_override" parameter.
3769 2015-11-05 Cesar Philippidis <cesar@codesourcery.com>
3770 Thomas Schwinge <thomas@codesourcery.com>
3771 James Norris <jnorris@codesourcery.com>
3773 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
3774 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
3775 clauses with parallel and kernels and loops.
3776 * c-pragma.h (enum pragma_omp_clause): Add entries for
3777 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
3778 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
3779 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
3781 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
3783 2015-11-05 Martin Sebor <msebor@redhat.com>
3786 * c.opt (-Wplacement-new): New option.
3788 2015-11-05 Jakub Jelinek <jakub@redhat.com>
3790 * c-common.h (c_finish_omp_atomic): Add TEST argument.
3791 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
3792 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
3793 save_expr or create_tmp_var* if TEST is true.
3794 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
3795 Don't call add_stmt here.
3796 (struct c_omp_check_loop_iv_data): New type.
3797 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
3798 c_omp_check_loop_iv_exprs): New functions.
3799 (c_omp_split_clauses): Adjust for lastprivate being allowed on
3801 (c_omp_declare_simd_clauses_to_numbers): Change
3802 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
3803 (c_omp_declare_simd_clauses_to_decls): Similarly change those
3804 from numbers to PARM_DECLs.
3806 2015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
3808 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
3811 2015-11-03 Bernd Schmidt <bschmidt@redhat.com>
3814 * c-common.h (fold_offsetof_1): Add argument.
3815 * c-common.c (fold_offsetof_1): Diagnose more invalid
3816 offsetof expressions that reference elements past the end of
3819 2015-11-03 Thomas Schwinge <thomas@codesourcery.com>
3820 Chung-Lin Tang <cltang@codesourcery.com>
3822 * c-pragma.c (oacc_pragmas): Add "atomic".
3823 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
3825 2015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
3827 * c-common.c (handle_target_clones_attribute): New.
3828 (c_common_attribute_table): Add handle_target_clones_attribute.
3829 (handle_always_inline_attribute): Add check on target_clones attribute.
3830 (handle_target_attribute): Ditto.
3832 2015-10-29 Andrew MacLeod <amacleod@redhat.com>
3834 * array-notation-common.c: Reorder #include's and remove duplicates.
3835 * c-ada-spec.c: Likewise.
3836 * c-cilkplus.c: Likewise.
3837 * c-common.c: Likewise.
3838 * c-cppbuiltin.c: Likewise.
3839 * c-dump.c: Likewise.
3840 * c-format.c: Likewise.
3841 * c-gimplify.c: Likewise.
3842 * c-indentation.c: Likewise.
3843 * c-lex.c: Likewise.
3844 * c-omp.c: Likewise.
3845 * c-opts.c: Likewise.
3846 * c-pch.c: Likewise.
3847 * c-ppoutput.c: Likewise.
3848 * c-pragma.c: Likewise.
3849 * c-pretty-print.c: Likewise.
3850 * c-semantics.c: Likewise.
3851 * c-ubsan.c: Likewise.
3853 * stub-objc.c: Likewise.
3855 2015-10-28 Jason Merrill <jason@redhat.com>
3857 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
3859 2015-10-27 Thomas Schwinge <thomas@codesourcery.com>
3860 James Norris <jnorris@codesourcery.com>
3861 Cesar Philippidis <cesar@codesourcery.com>
3865 * c-common.h (c_oacc_split_loop_clauses): Declare function.
3866 * c-omp.c (c_oacc_split_loop_clauses): New function.
3868 2015-10-21 Martin Sebor <msebor@redhat.com>
3871 * c.opt: End each sentence that describes an option with a period.
3873 2015-10-20 Marek Polacek <polacek@redhat.com>
3875 * array-notation-common.c (is_cilkplus_vector_p): Define.
3876 * c-common.h (is_cilkplus_vector_p): Declare.
3878 2015-10-20 Marek Polacek <polacek@redhat.com>
3880 * c.opt (std=gnu++11): Do not describe as experimental.
3881 (std=gnu++14): Likewise.
3883 2015-10-19 Jason Merrill <jason@redhat.com>
3885 * c-cppbuiltin.c (c_cpp_builtins): Define
3886 __cpp_nontype_template_args.
3888 2015-10-19 Jason Merrill <jason@redhat.com>
3890 * c-cppbuiltin.c (c_cpp_builtins): Define
3891 __cpp_enumerator_attributes, __cpp_fold_expressions,
3892 __cpp_unicode_characters.
3894 2015-10-13 Jakub Jelinek <jakub@redhat.com>
3895 Aldy Hernandez <aldyh@redhat.com>
3897 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
3898 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
3899 (c_define_builtins): Likewise.
3900 * c-common.h (enum c_omp_clause_split): Add
3901 C_OMP_CLAUSE_SPLIT_TASKLOOP.
3902 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
3903 (c_finish_omp_for): Add ORIG_DECLV argument.
3904 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
3905 201511 instead of 201307.
3906 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
3907 OMP_CRITICAL_CLAUSES to it.
3908 (c_finish_omp_ordered): Add CLAUSES argument, set
3909 OMP_ORDERED_CLAUSES to it.
3910 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
3911 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
3912 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
3913 constructs and new OpenMP 4.5 clauses. Clear
3914 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
3916 * c-pragma.c (omp_pragmas_simd): Add taskloop.
3917 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
3918 (enum pragma_omp_clause): Add
3919 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
3920 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
3922 2015-10-05 Richard Sandiford <richard.sandiford@arm.com>
3924 * c-lex.c (interpret_float): Use real_equal instead of
3927 2015-10-04 Jason Merrill <jason@redhat.com>
3929 Implement N4514, C++ Extensions for Transactional Memory.
3930 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
3931 (c_common_attribute_table): Add transaction_safe_dynamic.
3932 transaction_safe now affects type identity.
3933 (handle_tm_attribute): Handle transaction_safe_dynamic.
3934 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
3935 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
3936 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
3938 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
3939 * c-pretty-print.c (pp_c_attributes_display): Don't print
3940 transaction_safe in C++.
3942 2015-10-02 Marek Polacek <polacek@redhat.com>
3944 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
3946 2015-10-02 Marek Polacek <polacek@redhat.com>
3949 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
3950 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
3951 * c.opt (Wduplicated-cond): New option.
3953 2015-10-01 Joseph Myers <joseph@codesourcery.com>
3955 * c.opt (std=c11): Do not describe as experimental.
3956 (std=gnu11): Likewise.
3957 (std=iso9899:2011): Likewise.
3959 2015-09-28 Nathan Sidwell <nathan@codesourcery.com>
3961 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
3962 (DEF_FUNCTION_TYPE_VAR_11): Delete.
3964 2015-09-25 Marek Polacek <polacek@redhat.com>
3966 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
3967 (ubsan_instrument_shift): Likewise.
3969 2015-09-25 Marek Polacek <polacek@redhat.com>
3972 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
3974 2015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
3976 * c-indentation.c (should_warn_for_misleading_indentation):
3977 Compare next_stmt_vis_column with guard_line_first_nws instead
3978 of with guard_line_vis_column.
3980 2015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
3984 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
3985 options and options not valid for the current language.
3987 2015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
3989 * c-indentation.c (should_warn_for_misleading_indentation):
3990 Float out and consolidate the calls to get_visual_column that
3991 are passed guard_exploc as an argument. Compare
3992 next_stmt_vis_column with guard_line_first_nws instead of with
3993 body_line_first_nws.
3995 2015-09-22 Nathan Sidwell <nathan@codesourcery.com>
3997 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
3998 Wnamespaces): New C++ warnings.
4000 2015-09-22 Jason Merrill <jason@redhat.com>
4002 * c-common.h (abi_compat_version_crosses): New.
4003 (warn_abi_version): Declare.
4004 * c-common.c: Define it.
4005 * c-opts.c (c_common_post_options): Handle it.
4006 flag_abi_compat_version defaults to 8.
4008 2015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
4010 Complete the implementation of N4230, Nested namespace definition.
4011 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
4012 __cpp_nested_namespace_definitions.
4014 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
4016 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
4018 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
4020 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
4022 * c-pragma.h (pragma_lex): Add optional loc argument.
4024 2015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
4026 * c-format.c (check_format_arg): Adjust to use common block size in all
4029 2015-09-15 David Malcolm <dmalcolm@redhat.com>
4031 * c-format.c (location_from_offset): Update for change in
4032 signature of location_get_source_line.
4033 * c-indentation.c (get_visual_column): Likewise.
4034 (line_contains_hash_if): Likewise.
4036 2015-09-14 Marek Polacek <polacek@redhat.com>
4038 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
4039 setting various warnings.
4041 2015-09-14 Marek Polacek <polacek@redhat.com>
4043 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
4046 2015-09-11 Mark Wielaard <mjw@redhat.com>
4049 * c.opt (Wunused-variable): Option from common.opt.
4050 (Wunused-const-variable): New option.
4052 2015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
4055 * c.opt ([Wsubobject-linkage]): Add.
4057 2015-09-03 Martin Sebor <msebor@redhat.com>
4060 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
4062 * c-common.c (reject_gcc_builtin): Define.
4064 2015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
4067 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
4069 * c-gimplify.c (c_gimplify_expr): Added a call to the function
4070 cilk_gimplify_call_params_in_spawned_fn.
4071 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
4072 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
4075 2015-08-25 Marek Polacek <polacek@redhat.com>
4078 * c-common.c (handle_weak_attribute): Don't check whether the
4079 visibility can be changed here.
4081 2015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
4083 * c-lex.c (c_lex_with_flags): Use explicit locations.
4085 2015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
4087 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
4088 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
4090 2015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
4093 * c-common.c (check_builtin_function_arguments): Add check
4094 for BUILT_IN_SIGNBIT argument.
4096 2015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
4099 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
4102 2015-08-17 Marek Polacek <polacek@redhat.com>
4104 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
4105 with whitespaces before qualifier names.
4107 2015-08-12 Marek Polacek <polacek@redhat.com>
4110 * c-common.c (maybe_warn_shift_overflow): Properly handle
4111 left-shifting 1 into the sign bit.
4113 2015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
4115 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
4117 2015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
4118 Braden Obrzut <admin@maniacsvault.net>
4119 Jason Merrill <jason@redhat.com>
4121 Add C++ Concepts TS support.
4122 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
4123 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
4124 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
4125 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
4126 * c-opts.c (set_std_cxx1z): Set flag_concepts.
4127 * c.opt (fconcepts): New.
4129 2015-08-02 Martin Sebor <msebor@redhat.com>
4131 * c.opt (-Wframe-address): New warning option.
4133 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
4135 * c-indentation.c (should_warn_for_misleading_indentation):
4138 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
4140 * c-indentation.c (get_visual_column): Add parameter first_nws,
4141 use it. Update comment documenting the function.
4142 (is_first_nonwhitespace_on_line): Remove.
4143 (should_warn_for_misleading_indentation): Replace usage of
4144 of is_first_nonwhitespace_on_line with get_visual_column.
4146 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
4148 * c-indentation.h (struct token_indent_info): Define.
4149 (get_token_indent_info): Define.
4150 (warn_for_misleading_information): Declare.
4151 * c-common.h (warn_for_misleading_information): Remove.
4152 * c-identation.c (warn_for_misleading_indentation):
4153 Change declaration to take three token_indent_infos. Adjust
4155 * c-identation.c (should_warn_for_misleading_indentation):
4156 Likewise. Bail out early if the body is a compound statement.
4157 (guard_tinfo_to_string): Define.
4159 2015-07-30 Jason Merrill <jason@redhat.com>
4161 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
4162 '*' for reference decay.
4164 2015-07-30 Marek Polacek <polacek@redhat.com>
4166 * c-common.c (warn_tautological_cmp): Bail for float types.
4168 2015-07-27 Marek Polacek <polacek@redhat.com>
4171 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
4173 2015-07-27 Marek Polacek <polacek@redhat.com>
4177 * c-common.c (find_array_ref_with_const_idx_r): New function.
4178 (warn_tautological_cmp): New function.
4179 * c-common.h (warn_tautological_cmp): Declare.
4180 * c.opt (Wtautological-compare): New option.
4182 2015-07-23 Marek Polacek <polacek@redhat.com>
4184 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
4185 (ubsan_instrument_shift): Likewise.
4187 2015-07-23 Marek Polacek <polacek@redhat.com>
4190 * c-ubsan.c: Include gimplify.h.
4191 (ubsan_instrument_division): Unshare OP0 and OP1.
4192 (ubsan_instrument_shift): Likewise.
4194 2015-07-20 Marek Polacek <polacek@redhat.com>
4195 Richard Sandiford <richard.sandiford@arm.com>
4198 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
4199 Use EXPR_LOC_OR_LOC.
4200 (maybe_warn_shift_overflow): New function.
4201 * c-common.h (maybe_warn_shift_overflow): Declare.
4202 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
4203 * c.opt (Wshift-overflow): New option.
4205 2015-07-16 Martin Liska <mliska@suse.cz>
4207 * c-format.c (static void check_format_info_main): Use
4208 object_allocator instead of pool_allocator.
4209 (check_format_arg): Likewise.
4210 (check_format_info_main): Likewise.
4212 2015-07-15 Andrew MacLeod <amacleod@redhat.com>
4214 * c-opts.c: Remove multiline #include comment.
4216 2015-07-12 Aldy Hernandez <aldyh@redhat.com>
4218 * c-common.c: Fix double word typos.
4220 2015-07-10 Eric Botcazou <ebotcazou@adacore.com>
4222 * c-ada-spec.h (cpp_operation): Revert latest change.
4223 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
4224 constructors and destructors.
4226 2015-07-09 Andrew MacLeod <amacleod@redhat.com>
4228 * c-common.h: Adjust includes for flags.h changes.
4229 * stub-objc.c: Likewise.
4231 2015-07-08 Eric Botcazou <ebotcazou@adacore.com>
4233 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
4234 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
4236 2015-07-08 Jakub Jelinek <jakub@redhat.com>
4238 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
4239 are to be removed, return NULL rather than original clauses list.
4241 2015-07-07 Andrew MacLeod <amacleod@redhat.com>
4243 * array-notation-common.c: Adjust includes.
4244 * c-ada-spec.c: Likewise.
4245 * c-cilkplus.c: Likewise.
4246 * c-common.h: Likewise.
4247 * c-cppbuiltin.c: Likewise.
4248 * c-dump.c: Likewise.
4249 * c-format.c: Likewise.
4250 * c-gimplify.c: Likewise.
4251 * c-indentation.c: Likewise.
4252 * c-lex.c: Likewise.
4253 * c-omp.c: Likewise.
4254 * c-opts.c: Likewise.
4255 * c-pch.c: Likewise.
4256 * c-ppoutput.c: Likewise.
4257 * c-pragma.c: Likewise.
4258 * c-pretty-print.c: Likewise.
4259 * c-semantics.c: Likewise.
4260 * c-ubsan.c: Likewise.
4262 * stub-objc.c: Likewise.
4264 2015-07-07 Eric Botcazou <ebotcazou@adacore.com>
4266 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
4267 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
4269 2015-07-01 Jason Merrill <jason@redhat.com>
4271 * c-common.h (D_CXX11): Rename from D_CXX0X.
4272 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
4273 * c-common.c: Adjust.
4275 * c-opts.c (c_common_post_options): Default to C++14.
4277 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
4279 2015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
4281 Implement N4197 - Adding u8 character literals
4282 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
4284 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
4285 CPP_UTF8CHAR_USERDEF tokens.
4286 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
4287 and CPP_UTF8CHAR tokens.
4288 (lex_charconst): Treat CPP_UTF8CHAR token.
4290 2015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
4293 * c-common.c (do_warn_unused_parameter): Move here.
4294 * c-common.h (do_warn_unused_parameter): Declare.
4296 2015-06-29 Marek Polacek <polacek@redhat.com>
4299 * c-common.c (check_case_bounds): Add bool * parameter. Set
4301 (c_add_case_label): Add bool * parameter. Pass it down to
4303 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
4305 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
4308 2015-06-27 Marek Polacek <polacek@redhat.com>
4310 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
4311 or VECTOR_INTEGER_TYPE_P throughout.
4312 * c-gimplify.c: Likewise.
4314 2015-06-26 Marek Polacek <polacek@redhat.com>
4316 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
4317 * c-common.c (c_fully_fold_internal): Likewise.
4318 (c_alignof_expr): Likewise.
4319 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
4320 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
4321 * cilk.c (create_parm_list): Likewise.
4323 2015-06-26 Marek Polacek <polacek@redhat.com>
4325 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
4327 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
4329 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
4330 * c-gimplify.c: Likewise.
4331 * c-pragma.c: Likewise.
4332 * c-ubsan.c: Likewise.
4335 2015-06-25 Richard Sandiford <richard.sandiford@arm.com>
4337 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
4340 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
4342 * cilk.c: Move calls.h after tm.h in the include chain.
4344 2015-06-25 Marek Polacek <polacek@redhat.com>
4346 * array-notation-common.c: Use VAR_P throughout.
4347 * c-ada-spec.c: Likewise.
4348 * c-common.c: Likewise.
4349 * c-format.c: Likewise.
4350 * c-gimplify.c: Likewise.
4351 * c-omp.c: Likewise.
4352 * c-pragma.c: Likewise.
4353 * c-pretty-print.c: Likewise.
4356 2015-06-25 Marek Polacek <polacek@redhat.com>
4358 * cilk.c (extract_free_variables): Use is_global_var.
4360 2015-06-23 Richard Sandiford <richard.sandiford@arm.com>
4362 * c-common.c: Don't include target-def.h.
4364 2015-06-23 Marek Polacek <polacek@redhat.com>
4366 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
4367 when comparing INTEGER_CSTs.
4369 2015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
4371 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
4372 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
4373 (dump_ada_template): Skip partially specialized types.
4375 2015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
4377 * c-common.c (scalar_to_vector): Use std::swap instead of manually
4380 2015-06-17 Andrew MacLeod <amacleod@redhat.com>
4382 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
4383 * c-ada-spec.c: Likewise.
4384 * c-cilkplus.c: Likewise.
4385 * c-common.c: Likewise.
4386 * c-common.h: Likewise.
4387 * c-cppbuiltin.c: Likewise.
4388 * c-dump.c: Likewise.
4389 * c-format.c: Likewise.
4390 * c-gimplify.c: Likewise.
4391 * c-indentation.c: Likewise.
4392 * c-lex.c: Likewise.
4393 * c-omp.c: Likewise.
4394 * c-opts.c: Likewise.
4395 * c-pch.c: Likewise.
4396 * c-ppoutput.c: Likewise.
4397 * c-pragma.c: Likewise.
4398 * c-pretty-print.c: Likewise.
4399 * c-semantics.c: Likewise.
4400 * c-ubsan.c: Likewise.
4402 * stub-objc.c: Likewise.
4404 2015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
4407 * c-common.c (c_common_truthvalue_conversion): Warn when
4408 converting an address of a reference to a truth value.
4410 2015-06-08 Andrew MacLeod <amacleod@redhat.com>
4412 * array-notation-common.c : Adjust include files.
4413 * c-ada-spec.c : Likewise.
4414 * c-cilkplus.c : Likewise.
4415 * c-common.c : Likewise.
4416 * c-common.h : Likewise.
4417 * c-cppbuiltin.c : Likewise.
4418 * c-dump.c : Likewise.
4419 * c-format.c : Likewise.
4420 * c-gimplify.c : Likewise.
4421 * c-indentation.c : Likewise.
4422 * c-lex.c : Likewise.
4423 * c-omp.c : Likewise.
4424 * c-opts.c : Likewise.
4425 * c-pch.c : Likewise.
4426 * c-ppoutput.c : Likewise.
4427 * c-pragma.c : Likewise.
4428 * c-pretty-print.c : Likewise.
4429 * c-semantics.c : Likewise.
4430 * c-ubsan.c : Likewise.
4431 * cilk.c : Likewise.
4432 * stub-objc.c : Likewise.
4434 2015-06-08 Marek Polacek <polacek@redhat.com>
4437 * c-format.c (location_from_offset): Return LOC if LINE is null.
4439 2015-06-05 Aldy Hernandez <aldyh@redhat.com>
4441 * c-common.h (c_parse_final_cleanups): New prototype.
4442 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
4444 2015-06-04 Sriraman Tallam <tmsriram@google.com>
4446 * c-common.c (noplt): New attribute.
4447 (handle_noplt_attribute): New handler.
4449 2015-06-04 Andrew MacLeod <amacleod@redhat.com>
4451 * array-notation-common.c: Adjust includes for restructured coretypes.h.
4452 * c-ada-spec.c: Likewise.
4453 * c-cilkplus.c: Likewise.
4454 * c-common.c: Likewise.
4455 * c-common.h: Likewise.
4456 * c-cppbuiltin.c: Likewise.
4457 * c-dump.c: Likewise.
4458 * c-format.c: Likewise.
4459 * c-gimplify.c: Likewise.
4460 * c-indentation.c: Likewise.
4461 * c-lex.c: Likewise.
4462 * c-omp.c: Likewise.
4463 * c-opts.c: Likewise.
4464 * c-pch.c: Likewise.
4465 * c-ppoutput.c: Likewise.
4466 * c-pragma.c: Likewise.
4467 * c-pretty-print.c: Likewise.
4468 * c-semantics.c: Likewise.
4469 * c-ubsan.c: Likewise.
4471 * stub-objc.c: Likewise.
4473 2015-06-02 David Malcolm <dmalcolm@redhat.com>
4476 * c-indentation.c (should_warn_for_misleading_indentation): Use
4477 expand_location rather than expand_location_to_spelling_point.
4478 Don't warn if the guarding statement is more indented than the
4481 2015-06-02 David Malcolm <dmalcolm@redhat.com>
4483 * c-indentation.c (warn_for_misleading_indentation): Bail out
4484 immediately if -Wmisleading-indentation isn't enabled.
4486 2015-06-01 Martin Liska <mliska@suse.cz>
4488 * c-format.c (check_format_arg):Use new type-based pool allocator.
4489 (check_format_info_main) Likewise.
4491 2015-05-31 Eric Botcazou <ebotcazou@adacore.com>
4493 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
4494 (has_nontrivial_methods): Likewise.
4496 2015-05-25 Marek Polacek <polacek@redhat.com>
4498 * c-ubsan.c (ubsan_instrument_shift): Use type0.
4500 2015-05-22 Marek Polacek <polacek@redhat.com>
4503 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
4505 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
4507 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
4508 STACK_GROWS_DOWNWARD.
4510 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
4512 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
4513 STACK_GROWS_DOWNWARD rather than if it is defined.
4515 2015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
4518 * c-format.c (location_column_from_byte_offset): New.
4519 (location_from_offset): New.
4520 (struct format_wanted_type): Add offset_loc field.
4521 (check_format_info): Move handling of location for extra arguments
4522 closer to the point of warning.
4523 (check_format_info_main): Pass the result of location_from_offset
4525 (format_type_warning): Pass the result of location_from_offset
4528 2015-05-20 Marek Polacek <polacek@redhat.com>
4530 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
4532 2015-05-20 Marek Polacek <polacek@redhat.com>
4534 * c-ada-spec.c (dump_sloc): Use DECL_P.
4536 2015-05-20 Marek Polacek <polacek@redhat.com>
4538 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
4539 * c-common.c: Likewise.
4541 2015-05-19 David Malcolm <dmalcolm@redhat.com>
4543 * c-common.h (fe_file_change): Strengthen param from
4544 const line_map * to const line_map_ordinary *.
4545 (pp_file_change): Likewise.
4546 * c-lex.c (fe_file_change): Likewise.
4547 (cb_define): Use linemap_check_ordinary when invoking
4549 (cb_undef): Likewise.
4550 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
4551 invoking cb_file_change.
4552 (c_finish_options): Likewise.
4553 (push_command_line_include): Likewise.
4554 (cb_file_change): Strengthen param "new_map" from
4555 const line_map * to const line_map_ordinary *.
4556 * c-ppoutput.c (cb_define): Likewise for local "map".
4557 (pp_file_change): Likewise for param "map" and local "from".
4559 2015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
4561 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
4563 2015-05-18 Tom de Vries <tom@codesourcery.com>
4565 * c-common.c (build_va_arg_1): New function.
4566 (build_va_arg): Add address operator to va_list operand if necessary.
4568 2015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
4571 * c-common.c (int_safely_convertible_to_real_p): Define.
4572 (unsafe_conversion_p): Check conversions involving complex types.
4573 (conversion_warning): Add new warning message for conversions which
4574 discard imaginary component.
4575 * c-common.h: (enum conversion_safety): Add new enumerator for such
4578 2015-05-14 Marek Polacek <polacek@redhat.com>
4582 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
4583 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
4584 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
4585 use it. If FOR_INT_CONST, require that all evaluated operands be
4588 2015-05-12 David Malcolm <dmalcolm@redhat.com>
4590 * c-common.h (warn_for_misleading_indentation): New prototype.
4591 * c-indentation.c: New file.
4592 * c.opt (Wmisleading-indentation): New option.
4594 2015-05-12 Tom de Vries <tom@codesourcery.com>
4596 PR tree-optimization/66010
4597 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
4599 2015-05-09 Jason Merrill <jason@redhat.com>
4601 * c-opts.c (c_common_post_options): Also clear
4602 cpp_opts->cpp_warn_cxx11_compat.
4604 * c-common.h (enum cxx_dialect): Add cxx_unset.
4605 * c-common.c (cxx_dialect): Initialize to cxx_unset.
4606 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
4608 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
4609 (std=gnu++0x): Mark as Undocumented.
4610 (std=gnu++1y): Add deprecated message.
4612 2015-05-08 Jason Merrill <jason@redhat.com>
4614 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
4617 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
4619 2015-05-08 Marek Polacek <polacek@redhat.com>
4622 * c.opt (Woverride-init-side-effects): New option.
4624 2015-05-07 Marek Polacek <polacek@redhat.com>
4627 * c-common.c (c_fully_fold_internal): Warn when left shifting a
4629 * c.opt (Wshift-negative-value): New option.
4630 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
4631 when -Wextra and C99/C++11 mode.
4633 2015-05-07 Marek Polacek <polacek@redhat.com>
4634 Martin Uecker <uecker@eecs.berkeley.edu>
4636 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
4637 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
4639 2015-05-05 Jason Merrill <jason@redhat.com>
4641 * c.opt (Wterminate): New.
4643 2015-04-30 Marek Polacek <polacek@redhat.com>
4645 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
4646 require that the non-constant be of a boolean type.
4648 2015-04-29 Josh Triplett <josh@joshtriplett.org>
4650 * c-common.c (handle_section_attribute): Refactor to reduce
4651 nesting and distinguish between error cases.
4653 2015-04-29 Marek Polacek <polacek@redhat.com>
4656 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
4659 2015-04-29 Jakub Jelinek <jakub@redhat.com>
4661 * c-common.h (omp_clause_mask): Unconditionally define as a class.
4662 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
4663 HOST_BITS_PER_WIDE_INT.
4665 2015-04-28 Tom de Vries <tom@codesourcery.com>
4667 PR tree-optimization/65887
4668 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
4670 2015-04-28 Eric Botcazou <ebotcazou@adacore.com>
4671 Pierre-Marie de Rodat <derodat@adacore.com>
4673 * c-ada-spec.c (in_function): Delete.
4674 (dump_generic_ada_node): Do not change in_function and remove the
4675 redundant code dealing with it.
4676 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
4677 (print_ada_methods): Output the static member functions in a nested
4678 package after the regular methods as well as associated renamings.
4680 2015-04-24 Marek Polacek <polacek@redhat.com>
4683 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
4684 and OPT_Wshift_count_overflow.
4687 * c-common.c (warn_logical_operator): Warn if the operands have the
4690 2015-04-24 Marek Polacek <polacek@redhat.com>
4693 * c-common.c (warn_logical_operator): Bail if either operand comes
4694 from a macro expansion.
4696 2015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
4699 * c-common.c (c_default_pointer_mode): Add definition.
4700 * c-common.h (c_default_pointer_mode): Add declaration.
4702 2015-03-11 Jakub Jelinek <jakub@redhat.com>
4704 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
4705 on record_builtin_type argument.
4707 2015-03-10 Jakub Jelinek <jakub@redhat.com>
4710 * c-common.c (warn_logical_not_parentheses): Don't warn for
4713 2015-03-07 Marek Polacek <polacek@redhat.com>
4716 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
4717 before trying to figure out whether we have a flexible array member.
4719 2015-03-06 Eric Botcazou <ebotcazou@adacore.com>
4720 Jonathan Wakely <jwakely.gcc@gmail.com>
4722 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
4724 2015-03-05 Eric Botcazou <ebotcazou@adacore.com>
4727 * c-ada-spec.c (print_destructor): Remove obsolete code.
4729 2015-03-01 Eric Botcazou <ebotcazou@adacore.com>
4731 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
4732 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
4733 DECL_TEMPLATE_RESULT emulations.
4734 (dump_ada_template)): Add guard for TYPE_METHODS.
4736 2015-02-27 Marek Polacek <polacek@redhat.com>
4739 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
4741 2015-02-27 Kai Tietz <ktietz@redhat.com>
4744 * c-pragma.c (handle_pragma_weak): Do not try to create
4745 weak/alias of declarations not being function, or variable
4748 2015-02-24 Thomas Schwinge <thomas@codesourcery.com>
4751 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
4753 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
4755 2015-02-16 Marek Polacek <polacek@redhat.com>
4758 * c-format.c (check_format_types): Handle null param.
4760 2015-02-13 Marek Polacek <polacek@redhat.com>
4763 * c-format.c (check_format_types): Don't warn about different
4764 signedness if the original value is in the range of WANTED_TYPE.
4766 2015-02-12 Jason Merrill <jason@redhat.com>
4769 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
4770 to the current highest version.
4771 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
4773 2015-02-04 Jakub Jelinek <jakub@redhat.com>
4777 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
4778 instead of RDIV_EXPR. Use build_binary_op instead of
4781 2015-01-30 Joseph Myers <joseph@codesourcery.com>
4783 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
4784 to pass input_location as first argument.
4786 2015-01-23 Tom de Vries <tom@codesourcery.com>
4789 * c.opt (fopenacc): Mark as LTO option.
4791 2015-01-23 Tom de Vries <tom@codesourcery.com>
4794 * c.opt (fopenmp): Mark as LTO option.
4796 2015-01-21 Jakub Jelinek <jakub@redhat.com>
4799 * cilk.c (fill_decls_vec): Only put decls into vector v.
4800 (compare_decls): Fix up formatting.
4802 2015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
4805 * cilk.c: Include vec.h.
4806 (struct cilk_decls): New structure.
4807 (wrapper_parm_cb): Split this function to...
4808 (fill_decls_vec): ...this...
4809 (create_parm_list): ...and this.
4810 (compare_decls): New function.
4811 (for_local_cb): Remove.
4812 (wrapper_local_cb): Ditto.
4813 (build_wrapper_type): For now first traverse and fill vector of
4814 declarations then sort it and then deal with sorted vector.
4815 (cilk_outline): Ditto.
4816 (declare_one_free_variable): Ditto.
4818 2015-01-21 Jason Merrill <jason@redhat.com>
4821 * c-format.c (check_format_arg): Call decl_constant_value.
4823 2015-01-19 Martin Liska <mliska@suse.cz>
4825 * c-common.c (handle_noicf_attribute): New function.
4827 2015-01-15 Thomas Schwinge <thomas@codesourcery.com>
4828 Bernd Schmidt <bernds@codesourcery.com>
4829 James Norris <jnorris@codesourcery.com>
4830 Cesar Philippidis <cesar@codesourcery.com>
4831 Ilmir Usmanov <i.usmanov@samsung.com>
4832 Jakub Jelinek <jakub@redhat.com>
4834 * c.opt (fopenacc): New option.
4835 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
4836 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
4838 * c-common.h (c_finish_oacc_wait): New prototype.
4839 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
4840 (c_finish_oacc_wait): New function.
4841 * c-pragma.c (oacc_pragmas): New variable.
4842 (c_pp_lookup_pragma, init_pragma): Handle it.
4843 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
4844 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
4845 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
4846 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
4847 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
4848 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
4849 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
4850 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
4851 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
4852 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
4853 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
4854 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
4855 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
4856 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
4857 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
4858 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
4859 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
4860 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
4861 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
4862 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
4863 PRAGMA_OACC_CLAUSE_WORKER.
4865 2015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
4867 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
4868 for the new option fstack-protector_explicit.
4869 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
4870 (handle_stack_protect_attribute): New function.
4872 2015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
4874 * c.opt: New option -Warray-bounds=.
4876 2015-01-09 Michael Collison <michael.collison@linaro.org>
4878 * array-notation-common.c: Include hash-set.h, machmode.h,
4879 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4880 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
4881 * c-ada-spec.c: Ditto.
4882 * c-cilkplus.c: Ditto.
4883 * c-common.c: Include input.h due to flattening of tree.h.
4884 Define macro GCC_C_COMMON_C.
4885 * c-common.h: Flatten tree.h header files into c-common.h.
4886 Remove include of tree-core.h.
4887 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
4888 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4889 fold-const.h, wide-int.h, and inchash.h due to
4890 flattening of tree.h.
4892 * c-format.c: Flatten tree.h header files into c-common.h.
4893 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
4894 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4895 fold-const.h, wide-int.h, and inchash.h due to
4896 flattening of tree.h.
4897 * c-dump.c: Include hash-set.h, machmode.h,
4898 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4899 fold-const.h, wide-int.h, and inchash.h due to
4900 flattening of tree.h.
4901 * c-format.c: Include hash-set.h, machmode.h,
4902 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4903 fold-const.h, wide-int.h, inchash.h and real.h due to
4904 flattening of tree.h.
4905 * c-gimplify.c: Include hash-set.h, machmode.h,
4906 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4907 fold-const.h, wide-int.h, and inchash.h due to
4908 flattening of tree.h.
4914 * c-ppoutput.c: Ditto.
4915 * c-pragma.c: Ditto.
4916 * c-pretty-print.c: Ditto.
4917 * c-semantics.c: Ditto.
4919 * stub-objc.c: Ditto.
4921 2015-01-08 Jason Merrill <jason@redhat.com>
4923 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
4924 do_ubsan_in_current_function.
4925 (ubsan_maybe_instrument_reference_or_call): Likewise.
4926 * c-ubsan.h: Declare it.
4928 2015-01-08 Mike Stump <mikestump@comcast.net>
4930 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
4932 2015-01-07 Marek Polacek <polacek@redhat.com>
4935 * c-common.c (c_fully_fold_internal): Warn for division and modulo
4936 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
4938 2015-01-05 Trevor Saunders <tsaunders@mozilla.com>
4941 * c.opt (Wsuggest-override): New option.
4943 2015-01-05 Jakub Jelinek <jakub@redhat.com>
4945 Update copyright years.
4947 2015-01-05 Marek Polacek <polacek@redhat.com>
4950 * c-common.c (warn_array_subscript_with_type_char): Add location_t
4952 * c-common.h (warn_array_subscript_with_type_char): Update
4955 2014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
4957 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
4958 Control macro with flag_sized_deallocation.
4960 2014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
4962 * c.opt (Wdiscarded-array-qualifiers): New option.
4964 2014-12-19 Jakub Jelinek <jakub@redhat.com>
4966 PR preprocessor/63831
4967 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
4968 and __has_cpp_attribute here.
4969 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
4970 c_common_has_attribute.
4971 * c-common.h (c_common_has_attribute): New prototype.
4972 * c-lex.c (init_c_lex): Set cb->has_attribute to
4973 c_common_has_attribute instead of cb_has_attribute.
4974 (get_token_no_padding): New function.
4975 (cb_has_attribute): Renamed to ...
4976 (c_common_has_attribute): ... this. No longer static. Use
4977 get_token_no_padding, require ()s, don't build TREE_LIST
4978 unnecessarily, fix up formatting, adjust diagnostics, call
4981 2014-12-15 Jason Merrill <jason@redhat.com>
4983 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
4984 (-Wsized-deallocation): New.
4985 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
4986 to on in C++14 and up.
4988 2014-12-11 Jason Merrill <jason@redhat.com>
4990 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
4992 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
4993 we aren't complaining about VLAs.
4995 2014-12-06 Marek Polacek <polacek@redhat.com>
4997 PR tree-optimization/64183
4998 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
4999 shift-expression if it is integer_type_node. Use types_compatible_p.
5001 2014-11-29 Jakub Jelinek <jakub@redhat.com>
5003 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
5004 last argument from create_tmp_var_raw and create_tmp_var calls.
5005 * cilk.c (gimplify_cilk_spawn): Likewise.
5006 * c-omp.c (c_finish_omp_atomic): Likewise.
5008 2014-11-28 Marek Polacek <polacek@redhat.com>
5010 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
5011 instead of unsigned_type_node.
5013 2014-11-28 Marek Polacek <polacek@redhat.com>
5016 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
5018 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
5019 expression to unsigned_type_node.
5021 2014-11-20 Mark Wielaard <mjw@redhat.com>
5024 * c-opts.c (set_std_c89): Set lang_hooks.name.
5025 (set_std_c99): Likewise.
5026 (set_std_c11): Likewise.
5027 (set_std_cxx98): Likewise.
5028 (set_std_cxx11): Likewise.
5029 (set_std_cxx14): Likewise.
5030 (set_std_cxx1z): Likewise.
5032 2014-11-21 Jakub Jelinek <jakub@redhat.com>
5035 * c-common.h (convert_vector_to_pointer_for_subscript): Change
5036 return type to bool.
5037 * c-common.c: Include gimple-expr.h.
5038 (convert_vector_to_pointer_for_subscript): Change return type to
5039 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
5040 and copy it into a TARGET_EXPR and use that instead of *vecp
5043 2014-11-19 David Malcolm <dmalcolm@redhat.com>
5045 Merger of git branch "gimple-classes-v2-option-3".
5046 * ChangeLog.gimple-classes: New.
5047 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
5048 from being just a vec<gimple> to a vec<gbind *>.
5050 2014-11-18 Jakub Jelinek <jakub@redhat.com>
5053 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
5054 argument to ptype, set type to TREE_TYPE (ptype). Don't call
5055 get_pointer_alignment for non-pointers. Use ptype, or if it is
5056 reference type, corresponding pointer type, as type of kind
5058 (ubsan_maybe_instrument_reference,
5059 ubsan_maybe_instrument_member_call): Adjust callers.
5061 2014-11-15 Marek Polacek <polacek@redhat.com>
5064 * array-notation-common.c (is_sec_implicit_index_fn): Return false
5066 (extract_array_notation_exprs): Return for NULL node.
5068 2014-11-12 Joseph Myers <joseph@codesourcery.com>
5070 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
5071 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
5073 2014-11-12 Jakub Jelinek <jakub@redhat.com>
5076 * c-common.c (check_builtin_function_arguments): Handle
5077 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
5079 2014-11-10 Andi Kleen <ak@linux.intel.com>
5082 * c-common.h (check_no_cilk): Declare.
5083 * cilk.c (get_error_location): New function.
5084 (check_no_cilk): Dito.
5086 2014-11-10 Andi Kleen <ak@linux.intel.com>
5088 * cilk.c (recognize_spawn): Use expression location
5091 2014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
5093 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
5095 2014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
5097 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
5098 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
5099 (__cpp_range_based_for, __cpp_initializer_lists,
5100 __cpp_delegating_constructors, __cpp_nsdmi,
5101 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
5102 for C++11; (__cpp_attribute_deprecated): Remove in favor of
5103 __has_cpp_attribute.
5104 * c-lex.c (cb_has_attribute): New callback CPP function;
5105 (init_c_lex): Set has_attribute callback.
5107 2014-11-04 Richard Biener <rguenther@suse.de>
5109 * c-common.c (shorten_compare): Do not shorten mixed
5110 DFP and non-DFP compares.
5112 2014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
5114 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
5115 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
5116 Commentary and rearrangement of tests.
5117 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
5118 Commentary and rearrangement of tests.
5119 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto
5120 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
5122 2014-10-29 Richard Sandiford <richard.sandiford@arm.com>
5124 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
5125 enum from machine_mode.
5127 2014-10-28 Andrew MacLeod <amacleod@redhat.com>
5129 * c-common.c: Adjust include files.
5130 * c-gimplify.c: Ditto.
5132 * c-pragma.c: Ditto.
5135 2014-10-27 Andrew MacLeod <amacleod@redhat.com>
5137 * c-gimplify.c: Adjust include files.
5139 2014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
5142 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
5143 c_common_initialize_diagnostics.
5144 * c-common.h: Likewise.
5146 2014-10-24 Marek Polacek <polacek@redhat.com>
5149 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
5150 print "struct"/"union"/"enum" for typedefed names.
5152 2014-10-23 Marek Polacek <polacek@redhat.com>
5154 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
5157 2014-10-22 Jakub Jelinek <jakub@redhat.com>
5158 Yury Gribov <y.gribov@samsung.com>
5160 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5161 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
5162 instead of flag_sanitize_recover as bool flag.
5164 2014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
5166 * cilk.c: Revert previous change.
5168 2014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
5171 * cilk.c: Include vec.h.
5172 (struct cilk_decls): New structure.
5173 (wrapper_parm_cb): Split this function to...
5174 (fill_decls_vec): ...this...
5175 (create_parm_list): ...and this.
5176 (compare_decls): New function.
5177 (for_local_cb): Remove.
5178 (wrapper_local_cb): Ditto.
5179 (build_wrapper_type): For now first traverse and fill vector of
5180 declarations then sort it and then deal with sorted vector.
5181 (cilk_outline): Ditto.
5182 (declare_one_free_variable): Ditto.
5184 2014-10-17 Marek Polacek <polacek@redhat.com>
5186 * c-opts.c (c_common_post_options): Set warn_implicit_int.
5187 * c.opt (Wimplicit-int): Initialize to -1.
5189 2014-10-16 Andrew MacLeod <amacleod@redhat.com>
5191 * c-pragma.c: Adjust include files.
5192 * c-semantics.c: Likewise.
5194 2014-10-16 DJ Delorie <dj@redhat.com>
5196 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
5199 2014-10-14 Jason Merrill <jason@redhat.com>
5202 * c-common.h (CPP_PREPARSED_EXPR): New.
5203 (N_CP_TTYPES): Adjust.
5205 2014-10-15 Marek Polacek <polacek@redhat.com>
5207 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
5209 2014-10-14 DJ Delorie <dj@redhat.com>
5211 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
5212 types, not just __int128.
5213 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
5214 types, not just __int128.
5215 (cpp_atomic_builtins): Round pointer sizes up.
5216 (type_suffix): Use type precision, not specific types.
5217 * c-common.c (c_common_reswords): Remove __int128 special case.
5218 (c_common_type_for_size): Check for all __intN types, not just
5220 (c_common_type_for_mode): Likewise.
5221 (c_common_signed_or_unsigned_type): Likewise.
5222 (c_build_bitfield_integer_type): Likewise.
5223 (c_common_nodes_and_builtins): Likewise.
5224 (keyword_begins_type_specifier): Likewise.
5225 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
5228 2014-10-12 Trevor Saunders <tsaunders@mozilla.com>
5230 * c-common.c: Use hash_table instead of hashtab.
5232 2014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
5234 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
5237 2014-10-03 Marc Glisse <marc.glisse@inria.fr>
5242 * c-common.c (warn_logical_operator): Punt for vectors.
5244 2014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
5246 Implement SD-6: SG10 Feature Test Recommendations
5247 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
5248 macros and the __has_header macro.
5250 2014-09-30 Jason Merrill <jason@redhat.com>
5252 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
5253 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
5254 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
5256 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
5257 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
5259 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
5260 * c-common.c (c_common_reswords): Remove __is_convertible_to.
5262 2014-09-24 Marek Polacek <polacek@redhat.com>
5266 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
5268 2014-09-23 Andi Kleen <ak@linux.intel.com>
5270 * c-common.c (handle_no_reorder_attribute): New function.
5271 (c_common_attribute_table): Add no_reorder attribute.
5273 2014-09-22 Joseph Myers <joseph@codesourcery.com>
5275 * c-cppbuiltin.c (c_cpp_builtins): Define
5276 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
5279 2014-09-18 Joseph Myers <joseph@codesourcery.com>
5281 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
5282 for supported floating-point modes.
5284 2014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
5286 * c.opt (Wpsabi): Use LangEnabledBy.
5287 * c-opts.c (c_common_handle_option): Do not handle here.
5289 2014-09-12 Joseph Myers <joseph@codesourcery.com>
5291 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
5292 macros for floating-point modes.
5294 2014-09-11 Marc Glisse <marc.glisse@inria.fr>
5297 * c-cppbuiltin.c (builtin_define_float_constants): Correct
5298 __*_DENORM_MIN__ without denormals.
5300 2014-09-10 Jakub Jelinek <jakub@redhat.com>
5302 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5303 ubsan_instrument_vla, ubsan_instrument_return): Adjust
5304 ubsan_create_data callers.
5305 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
5306 index is constant or BIT_AND_EXPR with constant mask and is
5307 small enough for the bound.
5308 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
5309 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
5311 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
5313 * c.opt: Add CppReason to various flags.
5314 (Wdate-time): Re-sort.
5315 * c-common.c: Include c-common.h earlier.
5316 (struct reason_option_codes_t): Delete.
5317 (c_option_controlling_cpp_error): Prefix global type and struct
5320 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
5322 * c.opt (Wnormalized): New.
5323 (Wnormalized=): Use Enum and Reject Negative.
5324 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
5326 2014-09-08 Joseph Myers <joseph@codesourcery.com>
5328 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
5329 digits of floating-point modes if -fbuilding-libgcc.
5331 2014-09-05 Joseph Myers <joseph@codesourcery.com>
5333 * c-cppbuiltin.c (c_cpp_builtins): Also define
5334 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
5335 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
5336 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
5337 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
5338 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
5339 __LIBGCC_STACK_GROWS_DOWNWARD__,
5340 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
5341 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
5342 __LIBGCC_DWARF_FRAME_REGISTERS__,
5343 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
5344 __LIBGCC_STACK_POINTER_REGNUM__ and
5345 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
5346 (builtin_define_with_value): Handle backslash-escaping in string
5349 2014-09-05 Richard Biener <rguenther@suse.de>
5352 * c-format.c (check_format_arg): Properly handle
5353 effectively signed POINTER_PLUS_EXPR offset.
5355 2014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
5357 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
5358 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
5359 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
5361 * c-opts.c (c_common_handle_option): Do not handle here.
5362 (sanitize_cpp_opts): Likewise.
5363 * c-common.c (struct reason_option_codes_t): Handle
5364 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
5366 2014-09-03 Marek Polacek <polacek@redhat.com>
5368 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
5370 2014-09-02 Jakub Jelinek <jakub@redhat.com>
5371 Balaji V. Iyer <balaji.v.iyer@intel.com>
5372 Igor Zamyatin <igor.zamyatin@intel.com>
5374 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
5375 * c-common.c (c_common_reswords): Added _Cilk_for.
5376 * c-common.h (enum rid): Added RID_CILK_FOR.
5377 (cilk_for_number_of_iterations): Add declaration.
5378 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
5380 * c-pragma.c (init_pragma): Register "grainsize" pragma.
5381 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
5383 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
5385 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
5386 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
5387 Wundef): Use CPP, Var and Init.
5388 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
5390 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
5392 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
5393 * c-opts.c (c_common_handle_option): Do not handle here.
5395 2014-08-25 Jason Merrill <jason@redhat.com>
5397 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
5398 -std=c++14 and -std=gnu++14, rather than the reverse.
5399 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
5400 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
5401 * c-common.h (cxx_dialect): Remove cxx1y.
5403 2014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
5405 * c-common.h (enum cxx_dialect): Add cxx14.
5406 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
5407 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
5408 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
5410 2014-08-22 Jason Merrill <jason@redhat.com>
5412 * c.opt (std=gnu++17): Fix alias.
5414 2014-08-22 Marek Polacek <polacek@redhat.com>
5417 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
5418 check for vector types. Drop LHS argument.
5419 * c-common.h (warn_logical_not_parentheses): Adjust.
5421 2014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
5423 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
5424 (Wmultichar): Likewise.
5425 (Wdate-time): Use C-family languages instead of Common. Use CPP
5427 * c-opts.c (c_common_handle_option): Do not handle the above
5429 (sanitize_cpp_opts): Likewise.
5431 2014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
5434 * c-opts.c: Include tree-diagnostics.h.
5435 (c_diagnostic_finalizer): New.
5436 (c_common_initialize_diagnostics): Use it.
5438 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
5440 PR preprocessor/51303
5441 * c-common.c (struct reason_option_codes_t option_codes):
5442 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
5444 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
5448 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
5449 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
5450 (c_common_post_options): Call init_global_opts_from_cpp.
5451 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
5453 2014-08-19 Marek Polacek <polacek@redhat.com>
5456 * c-common.c (maybe_warn_bool_compare): New function.
5457 * c-common.h (maybe_warn_bool_compare): Declare.
5458 * c.opt (Wbool-compare): New option.
5460 2014-08-19 Marek Polacek <polacek@redhat.com>
5462 * c.opt (Wc99-c11-compat): New option.
5464 2014-08-19 Marek Polacek <polacek@redhat.com>
5466 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
5467 to warn_c90_c99_compat.
5468 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
5471 2014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
5472 Steven Bosscher <steven@gcc.gnu.org>
5475 * c-format.c: Add extra_arg_loc and format_string_loc to struct
5476 format_check_results.
5477 (check_function_format): Use true and add comment for boolean
5479 (finish_dollar_format_checking): Use explicit location when warning.
5480 (check_format_info): Likewise.
5481 (check_format_arg): Set extra_arg_loc and format_string_loc.
5482 (check_format_info_main): Use explicit location when warning.
5483 (check_format_types): Pass explicit location.
5484 (format_type_warning): Likewise.
5486 2014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
5489 * c-format.c: Handle Fortran flags.
5491 2014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
5494 * array-notation-common.c (find_rank): Added handling for other
5495 types of references.
5497 2014-08-10 Marek Polacek <polacek@redhat.com>
5500 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
5501 * c.opt (Wc90-c99-compat): Add option.
5503 2014-08-07 Trevor Saunders <tsaunders@mozilla.com>
5505 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
5507 2014-08-03 Marek Polacek <polacek@redhat.com>
5509 * c-common.c (check_case_value): Add location_t parameter. Use it.
5510 (c_add_case_label): Pass loc to check_case_value.
5512 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
5514 * cilk.c: Use hash_map instead of pointer_map.
5516 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
5518 * c-gimplify.c: Use hash_set instead of pointer_set.
5520 2014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
5523 * array-notation-common.c (extract_array_notation_exprs): Handling
5526 2014-08-01 Jakub Jelinek <jakub@redhat.com>
5528 * c-common.h (min_align_of_type): Removed prototype.
5529 * c-common.c (min_align_of_type): Removed.
5530 * c-ubsan.h (ubsan_maybe_instrument_reference,
5531 ubsan_maybe_instrument_member_call): New prototypes.
5532 * c-ubsan.c: Include stor-layout.h and builtins.h.
5533 (ubsan_maybe_instrument_reference_or_call,
5534 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
5537 2014-07-31 Marc Glisse <marc.glisse@inria.fr>
5540 * c.opt (-Wreturn-local-addr): Move to common.opt.
5542 2014-07-30 Jason Merrill <jason@redhat.com>
5547 * c.opt (-fuse-all-virtuals): New.
5549 2014-07-30 Tom Tromey <tromey@redhat.com>
5552 * c.opt (Wdesignated-init): New option.
5553 * c-common.c (c_common_attribute_table): Add "designated_init".
5554 (handle_designated_init): New function.
5556 2014-07-24 Marek Polacek <polacek@redhat.com>
5559 * c-opts.c (c_finish_options): If -imacros is in effect, return.
5561 2014-07-16 Dodji Seketeli <dodji@redhat.com>
5563 PR preprocessor/60723 - missing system-ness marks for macro tokens
5564 * c-ppoutput.c (struct print::prev_was_system_token): New data
5566 (init_pp_output): Initialize it.
5567 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
5568 (do_line_change): Return a flag saying if a line marker was
5570 (scan_translation_unit): Detect if the system-ness of the token we
5571 are about to emit is different from the one of the previously
5572 emitted token. If so, emit a line marker. Avoid emitting useless
5573 adjacent line markers. Avoid emitting line markers for tokens
5574 originating from the expansion of built-in macros.
5575 (scan_translation_unit_directives_only): Adjust.
5577 2014-07-15 Marek Polacek <polacek@redhat.com>
5579 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
5580 TYPE_MAX_VALUE is NULL.
5582 2014-07-14 Jakub Jelinek <jakub@redhat.com>
5585 * c.opt (Wmemset-transposed-args): New warning.
5587 2014-07-10 Jason Merrill <jason@redhat.com>
5591 * c.opt (-fuse-all-virtuals): New.
5593 2014-07-09 Richard Biener <rguenther@suse.de>
5596 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
5597 using unsigned arithmetic if overflow does not wrap instead of
5598 if overflow is undefined.
5600 2014-07-06 Marek Polacek <polacek@redhat.com>
5603 * c.opt (Wsizeof-array-argument): New option.
5605 2014-07-03 Jakub Jelinek <jakub@redhat.com>
5607 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
5608 comments->count <= 1, as comments->entries might be NULL.
5610 2014-07-01 Marek Polacek <polacek@redhat.com>
5612 * c.opt (Wint-conversion): New option.
5614 2014-07-01 Marek Polacek <polacek@redhat.com>
5617 * c.opt (Wincompatible-pointer-types): New option.
5619 2014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
5622 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
5623 Do not discard TYPE_QUALS of type.
5625 2014-06-26 Jason Merrill <jason@redhat.com>
5627 * c-common.h (enum cxx_dialect): Add cxx1z.
5628 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
5629 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
5631 2014-06-26 Teresa Johnson <tejohnson@google.com>
5633 * c-common.h (get_dump_info): Declare.
5634 * c-gimplify.c (c_genericize): Use saved dump files.
5635 * c-opts.c (c_common_parse_file): Begin and end dumps
5636 once around parsing invocation.
5637 (get_dump_info): New function.
5639 2014-06-23 Marek Polacek <polacek@redhat.com>
5640 Andrew MacLeod <amacleod@redhat.com>
5643 * c-common.c (get_atomic_generic_size): Don't segfault if the
5644 type doesn't have a size.
5646 2014-06-20 Marek Polacek <polacek@redhat.com>
5648 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
5649 (ubsan_walk_array_refs_r): New function.
5650 (c_genericize): Instrument array bounds.
5651 * c-ubsan.c: Include "internal-fn.h".
5652 (ubsan_instrument_division): Mark instrumented arrays as having
5653 side effects. Adjust ubsan_type_descriptor call.
5654 (ubsan_instrument_shift): Likewise.
5655 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
5656 (ubsan_instrument_bounds): New function.
5657 (ubsan_array_ref_instrumented_p): New function.
5658 (ubsan_maybe_instrument_array_ref): New function.
5659 * c-ubsan.h (ubsan_instrument_bounds): Declare.
5660 (ubsan_array_ref_instrumented_p): Declare.
5661 (ubsan_maybe_instrument_array_ref): Declare.
5663 2014-06-20 Hale Wang <hale.wang@arm.com>
5666 * c.opt (fshort-enums): Add to LTO.
5667 * c.opt (fshort-wchar): Likewise.
5669 2014-06-16 Marek Polacek <polacek@redhat.com>
5672 * c.opt (Wswitch-bool): Add Var.
5674 2014-06-12 Jakub Jelinek <jakub@redhat.com>
5677 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
5678 #pragma omp target teams or
5679 #pragma omp {,target }teams distribute simd.
5681 2014-06-12 Jason Merrill <jason@redhat.com>
5683 * c.opt (Wabi=, fabi-compat-version): New.
5684 * c-opts.c (c_common_handle_option): Handle -Wabi=.
5685 (c_common_post_options): Handle flag_abi_compat_version default.
5686 Disallow -fabi-compat-version=1.
5687 * c-common.h (abi_version_crosses): New.
5689 2014-06-11 Jan Hubicka <hubicka@ucw.cz>
5691 * c-common.c (handle_section_attribute): Update handling for
5692 section names that are no longer trees.
5694 2014-06-10 Jakub Jelinek <jakub@redhat.com>
5697 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
5698 (omp_pragmas): ... back here.
5700 2014-06-05 Marek Polacek <polacek@redhat.com>
5703 * c-common.c (warn_logical_not_parentheses): New function.
5704 * c-common.h (warn_logical_not_parentheses): Declare.
5705 * c.opt (Wlogical-not-parentheses): New option.
5707 2014-06-04 Marek Polacek <polacek@redhat.com>
5710 * c-common.c (check_case_bounds): Add location parameter.
5712 (c_add_case_label): Pass loc to check_case_bounds.
5714 2014-06-03 Marek Polacek <polacek@redhat.com>
5717 * c.opt (Wswitch-bool): New option.
5719 2014-05-22 Thomas Schwinge <thomas@codesourcery.com>
5721 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
5723 (record_types_used_by_current_var_decl): Move prototype to where
5726 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
5727 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
5728 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
5730 2014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
5732 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
5733 * c-common.c (c_common_nodes_and_builtins): Don't initialize
5735 * c-pretty-print.c (pp_c_void_constant): New function.
5736 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
5737 (c_pretty_printer::expression): Handle VOID_CST.
5738 * cilk.c (extract_free_variables): Likewise.
5739 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
5740 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
5742 2014-05-17 Trevor Saunders <tsaunders@mozilla.com>
5744 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
5745 * c-pragma.c (push_alignment): Adjust.
5746 (handle_pragma_push_options): Likewise.
5748 2014-05-09 Marek Polacek <polacek@redhat.com>
5751 * c-common.c (check_user_alignment): Return -1 if alignment is error
5753 (handle_aligned_attribute): Don't call default_conversion on
5755 (handle_vector_size_attribute): Likewise.
5756 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
5757 (handle_sentinel_attribute): Call default_conversion and allow even
5758 integral types as an argument.
5760 2014-05-08 Marek Polacek <polacek@redhat.com>
5763 * c-common.c (min_align_of_type): New function factored out from...
5764 (c_sizeof_or_alignof_type): ...here.
5765 * c-common.h (min_align_of_type): Declare.
5767 2014-05-08 Marek Polacek <polacek@redhat.com>
5770 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
5771 parameter type of main.
5773 2014-05-07 DJ Delorie <dj@redhat.com>
5775 * c-cppbuiltin.c (print_bits_of_hex): New.
5776 (builtin_define_type_minmax): Print values using hex so as not to
5777 require a pre-computed list of string values.
5779 2014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
5780 Mike Stump <mikestump@comcast.net>
5781 Richard Sandiford <rdsandiford@googlemail.com>
5783 * c-ada-spec.c: Include wide-int.h.
5784 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
5785 (dump_generic_ada_node): Use wide-int interfaces.
5786 * c-common.c: Include wide-int-print.h.
5787 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
5788 (pointer_int_sum): Use wide-int interfaces.
5789 (c_common_nodes_and_builtins): Use make_int_cst.
5790 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
5791 (handle_alloc_size_attribute): Use wide-int interfaces.
5792 (get_nonnull_operand): Likewise.
5793 * c-format.c (get_constant): Use tree_fits_uhwi_p.
5794 * c-lex.c: Include wide-int.h.
5795 (narrowest_unsigned_type): Take a widest_int rather than two
5797 (narrowest_signed_type): Likewise.
5798 (interpret_integer): Update accordingly. Use wide-int interfaces.
5799 (lex_charconst): Use wide-int interfaces.
5800 * c-pretty-print.c: Include wide-int.h.
5801 (pp_c_integer_constant): Use wide-int interfaces.
5802 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
5803 INT_CST_LT_UNSIGNED.
5805 2014-05-06 Richard Biener <rguenther@suse.de>
5807 * c-opts.c (c_common_post_options): For -freestanding,
5808 -fno-hosted and -fno-builtin disable pattern recognition
5809 if not enabled explicitely.
5811 2014-05-02 Marek Polacek <polacek@redhat.com>
5813 * c.opt (Wsizeof-pointer-memaccess): Describe option.
5815 2014-05-01 Marek Polacek <polacek@redhat.com>
5818 * c.opt (Wdiscarded-qualifiers): Add.
5820 2014-04-30 Marek Polacek <polacek@redhat.com>
5822 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
5823 INT_MIN / -1 sanitization only for integer types.
5825 2014-04-25 Marek Polacek <polacek@redhat.com>
5828 * c-common.c (handle_noinline_attribute): Warn if the attribute
5829 conflicts with always_inline attribute.
5830 (handle_always_inline_attribute): Warn if the attribute conflicts
5831 with noinline attribute.
5833 2014-04-25 Marek Polacek <polacek@redhat.com>
5836 * c-common.c (check_main_parameter_types): Warn about variadic main.
5838 2014-04-24 Mike Stump <mikestump@comcast.net>
5840 * c.opt (Wshadow-ivar): Default to on.
5842 2014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
5844 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
5846 2014-04-23 Marek Polacek <polacek@redhat.com>
5848 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
5850 2014-04-22 Jakub Jelinek <jakub@redhat.com>
5853 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
5854 if flag_sanitize_undefined_trap_on_error.
5855 (ubsan_instrument_division, ubsan_instrument_shift,
5856 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
5857 if !flag_sanitize_recover.
5859 2014-04-22 Marc Glisse <marc.glisse@inria.fr>
5862 * c-common.c (registered_builtin_types): Make non-static.
5863 * c-common.h (registered_builtin_types): Declare.
5865 2014-04-14 Richard Biener <rguenther@suse.de>
5866 Marc Glisse <marc.glisse@inria.fr>
5869 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
5870 apply may-alias the scalar pointer type when applicable.
5872 2014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
5875 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
5876 as possible argument for Cilk_spawn.
5878 2014-04-11 Tobias Burnus <burnus@net-b.de>
5881 * c.opt (Wformat-signedness): Add
5882 * c-format.c(check_format_types): Use it.
5884 2014-04-11 Jason Merrill <jason@redhat.com>
5887 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
5888 default_conversion for an array argument.
5890 2014-04-08 Marek Polacek <polacek@redhat.com>
5893 * c-ubsan.c: Include asan.h.
5894 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
5896 2014-04-03 Nathan Sidwell <nathan@codesourcery.com>
5898 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
5900 2014-04-02 Marek Polacek <polacek@redhat.com>
5902 * c-common.h (c_expand_expr): Remove declaration.
5904 2014-03-28 Jakub Jelinek <jakub@redhat.com>
5907 * c-common.c (add_atomic_size_parameter): When creating new
5908 params vector, push the size argument first.
5910 2014-03-26 Jakub Jelinek <jakub@redhat.com>
5912 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5913 ubsan_instrument_vla, ubsan_instrument_return): Adjust
5914 ubsan_create_data callers.
5916 2014-03-22 Jakub Jelinek <jakub@redhat.com>
5919 * c-opts.c (c_finish_options): Restore cb_file_change call to
5922 2014-03-13 Jakub Jelinek <jakub@redhat.com>
5925 * c-pragma.c (apply_pragma_weak): Only look at
5926 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
5927 DECL_ASSEMBLER_NAME_SET_P (decl).
5928 (maybe_apply_pending_pragma_weaks): Exit early if
5929 vec_safe_is_empty (pending_weaks) rather than only when
5931 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
5932 set assembler name back to NULL afterwards.
5934 2014-03-11 Jason Merrill <jason@redhat.com>
5936 * c.opt: Add -std=gnu++14.
5938 2014-03-11 Ian Bolton <ian.bolton@arm.com>
5940 * c-opts.c (c_common_post_options): Don't override
5941 -ffp-contract=fast if unsafe-math-optimizations is on.
5943 2014-03-08 Paulo Matos <paulo@matos-sorge.com>
5945 * c.opt: Enable LTO FE for fshort-double.
5947 2014-03-07 Jason Merrill <jason@redhat.com>
5949 * c.opt: Add -std=c++14.
5951 2014-03-06 Marek Polacek <polacek@redhat.com>
5954 * cilk.c (contains_cilk_spawn_stmt): New function.
5955 (contains_cilk_spawn_stmt_walker): Likewise.
5956 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
5957 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
5959 2014-03-03 Jakub Jelinek <jakub@redhat.com>
5961 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
5962 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
5963 even when flag_preprocess_only.
5965 2014-02-26 Jason Merrill <jason@redhat.com>
5969 * c-common.c (shorten_compare): Don't check
5970 c_inhibit_evaluation_warnings.
5972 2014-02-19 Jakub Jelinek <jakub@redhat.com>
5975 * c-common.c (c_common_nodes_and_builtins): When initializing
5976 c_uint{16,32,64}_type_node, also set corresponding
5977 uint{16,32,64}_type_node to the same value.
5980 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
5981 for PRAGMA_IVDEP if flag_preprocess_only.
5983 2014-02-12 Jakub Jelinek <jakub@redhat.com>
5986 * c-common.c (merge_tlist): If copy is true, call new_tlist,
5987 if false, add ADD itself, rather than vice versa.
5988 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
5989 copy. For SAVE_EXPR, only call merge_tlist once.
5991 2014-02-08 Jakub Jelinek <jakub@redhat.com>
5994 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
5996 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
5998 (c_common_attribute_table): Add alloc_align and assume_aligned
6001 2014-02-06 Marek Polacek <polacek@redhat.com>
6004 * c-common.c (warn_for_sign_compare): Call warning_at with location
6007 2014-02-05 Marek Polacek <polacek@redhat.com>
6010 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
6013 2014-02-04 Marek Polacek <polacek@redhat.com>
6016 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
6019 2014-02-03 Marc Glisse <marc.glisse@inria.fr>
6023 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
6024 handle_vector_size_attribute, handle_nonnull_attribute): Call
6025 default_conversion on the attribute argument.
6026 (handle_nonnull_attribute): Increment the argument number.
6028 2014-01-31 Marek Polacek <polacek@redhat.com>
6031 * c-common.c (add_atomic_size_parameter): Pass vNULL to
6032 build_function_call_vec.
6033 (resolve_overloaded_builtin): Likewise.
6034 * c-common.h (build_function_call_vec): Adjust declaration.
6036 2014-01-30 Marek Polacek <polacek@redhat.com>
6039 * c-common.h (unsafe_conversion_p): Adjust declaration.
6040 (warnings_for_convert_and_check): Likewise.
6041 (convert_and_check): Likewise.
6042 * c-common.c (unsafe_conversion_p): Add location parameter. Call
6043 expansion_point_location_if_in_system_header on it.
6044 (warnings_for_convert_and_check): Add location parameter. Call
6045 expansion_point_location_if_in_system_header on it. Use it.
6046 (convert_and_check): Add location parameter. Use it.
6047 (conversion_warning): Likewise.
6048 (c_add_case_label): Adjust convert_and_check calls.
6049 (scalar_to_vector): Adjust unsafe_conversion_p calls.
6051 2014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
6053 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
6055 * c-pragma.c (init_pragma): Likewise.
6058 2014-01-23 Marek Polacek <polacek@redhat.com>
6061 * c-common.c (shorten_compare): Add location_t parameter.
6062 * c-common.h (shorten_binary_op): Adjust declaration.
6064 2014-01-23 Marek Polacek <polacek@redhat.com>
6067 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
6068 * c-common.h: Declare it.
6070 2014-01-20 Eric Botcazou <ebotcazou@adacore.com>
6072 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
6073 * c-ada-spec.c (dump_ads): Likewise.
6074 (cpp_check): Likewise.
6075 (dump_ada_specs): Likewise.
6077 2014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
6080 * c-common.c (handle_no_instrument_function_attribute): Allow
6081 no_instrument_function attribute in class member
6082 definition/declaration.
6084 2014-01-15 Jakub Jelinek <jakub@redhat.com>
6087 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
6088 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
6089 being COMPOUND_EXPR.
6090 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
6091 operand a SAVE_EXPR and second MODIFY_EXPR.
6093 2014-01-09 Jakub Jelinek <jakub@redhat.com>
6096 * c-pch.c (c_common_write_pch): Call
6097 prepare_target_option_nodes_for_pch.
6099 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
6101 Update copyright years
6103 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
6105 * array-notation-common.c, c-cilkplus.c: Use the standard form for
6106 the copyright notice.
6108 2013-12-28 Eric Botcazou <ebotcazou@adacore.com>
6110 * c-ada-spec.c (print_constructor): New function.
6111 (print_destructor): Retrieve the origin of the destructor.
6112 (print_ada_declaration): Revamp handling of constructors/destructors.
6114 2013-12-23 Stuart Hastings <stuart@apple.com>
6115 Bill Maddox <maddox@google.com>
6116 Jason Merrill <jason@redhat.com>
6118 * c.opt: Add -fdeclone-ctor-dtor.
6119 * c-opts.c (c_common_post_options): Default to on iff -Os.
6121 2013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
6123 * c-common.c (c_common_attribute_table): Added "cilk simd function"
6125 * c-pragma.h (enum pragma_cilk_clause): Remove.
6126 (enum pragma_omp_clause): Added the following fields:
6127 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
6128 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
6129 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
6130 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
6131 PRAGMA_CILK_CLAUSE_UNIFORM.
6134 2013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
6136 * cilk.c (cilk_outline): Made this function non-static.
6137 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
6138 (create_cilk_wrapper): Added a new parameter: a function pointer.
6139 (c_install_body_w_frame_cleanup): Remove
6140 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
6141 * c-common.h (cilk_outline): New prototype.
6142 (gimplify_cilk_spawn): Removed two parameters.
6143 (cilk_install_body_with_frame_cleanup): New prototype.
6144 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
6145 CILK_SPAWN_STMT case.
6147 2013-12-11 Bernd Schmidt <bernds@codesourcery.com>
6149 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
6151 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
6152 (int_array_type_node): Remove.
6153 * c-common.c (c_common_nodes_and_builtins): Don't build it.
6155 2013-12-05 Marek Polacek <polacek@redhat.com>
6158 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
6159 [ADJUST_FIELD_ALIGN].
6161 2013-12-04 Joseph Myers <joseph@codesourcery.com>
6164 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
6165 and check field alignment if set.
6166 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
6167 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
6169 2013-12-04 Jakub Jelinek <jakub@redhat.com>
6170 Marek Polacek <polacek@redhat.com>
6172 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
6173 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
6175 2013-11-29 H.J. Lu <hongjiu.lu@intel.com>
6178 * cilk.c (gimplify_cilk_spawn): Properly handle function without
6181 2013-11-29 Jakub Jelinek <jakub@redhat.com>
6184 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
6185 goto invalid. If it is error_mark_node, don't issue further
6188 2013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
6190 * c.opt (Wopenmp-simd): New.
6192 2013-11-22 Jakub Jelinek <jakub@redhat.com>
6194 * c-ubsan.h (ubsan_instrument_return): New prototype.
6195 * c-ubsan.c (ubsan_instrument_return): New function.
6197 2013-11-22 Andrew MacLeod <amacleod@redhat.com>
6199 * c-common.c: Add required include files from gimple.h.
6200 * c-gimplify.c: Likewise
6203 2013-11-22 David Malcolm <dmalcolm@redhat.com>
6205 * c-common.c (unsafe_conversion_p): Remove use of
6206 EXPR_LOC_OR_HERE macro.
6207 (conversion_warning): Likewise.
6208 (warnings_for_convert_and_check): Likewise.
6209 (warn_for_collisions_1): Likewise.
6210 (shorten_compare): Likewise, and remove use of in_system_header
6211 macro, using the location from the former.
6212 * c-lex.c (dump_one_header): Remove use of input_filename macro.
6213 (cb_def_pragma): Remove use of in_system_header macro.
6214 (lex_string): Likewise.
6215 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
6217 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
6218 Mike Stump <mikestump@comcast.net>
6219 Richard Sandiford <rdsandiford@googlemail.com>
6221 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
6222 instead of TREE_INT_CST_LOW, in cases where there is a protecting
6223 tree_fits_shwi_p or tree_fits_uhwi_p.
6224 (dump_generic_ada_node): Likewise.
6225 * c-format.c (check_format_arg): Likewise.
6226 * c-pretty-print.c (pp_c_integer_constant): Likewise.
6228 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
6230 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
6232 2013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
6235 * c-common.c (unsafe_conversion_p): Make this function
6236 return an enumeration with more detail.
6237 (conversion_warning): Use the new return type of
6238 unsafe_conversion_p to separately warn either about conversions
6239 that lower floating point number precision or about the other
6240 kinds of conversions.
6241 * c-common.h (enum conversion_safety): New enumeration.
6242 (unsafe_conversion_p): switching return type to
6243 conversion_safety enumeration.
6244 * c.opt: Adding new warning -Wfloat-conversion and
6245 enabling it with -Wconversion.
6247 2013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
6249 * c-opts.c: Include plugin.h.
6250 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
6252 2013-11-19 Marek Polacek <polacek@redhat.com>
6254 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
6256 (ubsan_instrument_shift): Likewise.
6257 (ubsan_instrument_vla): Likewise.
6259 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6261 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
6262 cast to unsigned type.
6264 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6266 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
6268 (complete_array_type): Update comment to refer to tree_to_[su]hwi
6269 rather than tree_low_cst.
6271 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6273 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
6274 tree_to_uhwi throughout.
6276 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6278 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
6279 tree_low_cst (..., 0) with tree_to_shwi throughout.
6281 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6283 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
6284 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
6286 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6288 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
6289 host_integerp (..., 0) with tree_fits_shwi_p throughout.
6291 2013-11-15 Aldy Hernandez <aldyh@redhat.com>
6293 * c-cilkplus.c: New file.
6294 * c-common.c (readonly_error): Add location argument.
6295 * c-common.h (readonly_error): Same.
6296 (c_finish_cilk_clauses): Protoize.
6297 (c_check_cilk_loop): Same.
6298 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
6299 Do not fail on error_mark_node.
6300 Abstract increment canonicalization to here...
6301 (c_omp_for_incr_canonicalize_ptr): New.
6302 c-pragma.c (init_pragma): Register "simd" pragma.
6303 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
6304 (enum pragma_cilk_clause): New.
6306 2013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
6308 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
6309 wchar_type and host_integerp checks.
6311 2013-11-14 Andrew MacLeod <amacleod@redhat.com>
6313 * c-common.c: Likewise.
6314 * c-gimplify.c: Likewise.
6317 2013-11-14 Diego Novillo <dnovillo@google.com>
6319 * c-common.c: Include fold-const.h.
6320 Include stor-layout.h.
6322 Include stringpool.h.
6325 Include trans-mem.h.
6326 * c-cppbuiltin.c: Include stor-layout.h.
6327 Include stringpool.h.
6328 * c-format.c: Include stringpool.h.
6329 * c-lex.c: Include stringpool.h.
6330 Include stor-layout.h.
6331 * c-pragma.c: Include stringpool.h.
6334 Include gcc-symtab.h.
6335 * c-pretty-print.c: Include stor-layout.h.
6337 * cilk.c: Include stringpool.h.
6340 2013-11-13 Joseph Myers <joseph@codesourcery.com>
6342 * c-common.h (enum rid): Add RID_AUTO_TYPE.
6343 * c-common.c (c_common_reswords): Add __auto_type.
6344 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
6346 2013-11-12 Andrew MacLeod <amacleod@redhat.com>
6348 * c-common.c: Include gimplify.h.
6349 * c-gimplify.c: Likewise.
6351 * c-omp.c: Include gimple-expr.h instead of gimple.h.
6352 * c-ubsan.c: Don't include gimple.h.
6354 2013-11-12 Joseph Myers <joseph@codesourcery.com>
6356 * c-common.c (c_common_reswords): Add _Thread_local.
6358 2013-11-09 Joseph Myers <joseph@codesourcery.com>
6360 * c-common.c (atomic_size_supported_p): New function.
6361 (resolve_overloaded_atomic_exchange)
6362 (resolve_overloaded_atomic_compare_exchange)
6363 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
6364 Use it instead of comparing size with a local list of sizes.
6366 2013-11-07 Andrew MacLeod <amacleod@redhat.com>
6367 Joseph Myers <joseph@codesourcery.com>
6369 * c-common.h (enum rid): Add RID_ATOMIC.
6370 * c-common.c (c_common_reswords): Add _Atomic.
6371 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
6372 (keyword_is_type_qualifier): Accept RID_ATOMIC.
6373 * c-format.c (check_format_types): Check for extra _Atomic
6374 qualifiers in format argument.
6375 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
6376 (pp_c_type_qualifier_list): Mention _Atomic in comment.
6378 2013-11-06 Tobias Burnus <burnus@net-b.de>
6380 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
6382 2013-11-06 Joseph Myers <joseph@codesourcery.com>
6384 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
6386 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
6387 to mean lack of IEEE 754 support.
6389 2013-11-05 Tobias Burnus <burnus@net-b.de>
6391 * c.opt (-Wdate-time): New option
6392 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
6394 2013-11-05 Joseph Myers <joseph@codesourcery.com>
6396 * c-cppbuiltin.c (cpp_iec_559_value): Test
6397 flag_excess_precision_cmdline not flag_excess_precision.
6399 2013-11-05 Tobias Burnus <burnus@net-b.de>
6401 * c.opt (fopenmp-simd): New option.
6402 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
6403 (omp_pragmas): ... this new struct.
6404 (c_pp_lookup_pragma): Also walk omp_pragmas.
6405 (init_pragma): Init pragmas for -fopenmp-simd.
6407 2013-11-04 Marek Polacek <polacek@redhat.com>
6410 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
6412 2013-11-04 Joseph Myers <joseph@codesourcery.com>
6414 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
6416 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
6418 2013-11-04 Eric Botcazou <ebotcazou@adacore.com>
6420 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
6421 (dump_ada_specs): Adjust prototype of second callback.
6422 * c-ada-spec.c (cpp_check): New global variable.
6423 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
6424 (print_generic_ada_decl): Likewise.
6425 (has_static_fields): Change return type to bool and add guard.
6426 (has_nontrivial_methods): New predicate.
6427 (is_tagged_type): Change return type to bool.
6428 (separate_class_package): Call has_nontrivial_methods.
6429 (pp_ada_tree_identifier): Minor tweaks.
6430 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
6431 (dump_ada_array_domains): Likewise.
6432 (dump_ada_array_type): Likewise.
6433 (dump_template_types): Remove cpp_check parameter and do not pass it to
6434 dump_generic_ada_node.
6435 (dump_ada_template): Likewise.
6436 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
6438 (print_ada_methods): Change return type to integer. Remove cpp_check
6439 parameter and do not pass it down.
6440 (dump_nested_types): Remove cpp_check parameter and do not pass it to
6441 dump_generic_ada_node.
6442 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
6444 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
6445 down. Use has_nontrivial_methods to recognize C++ classes. Use return
6446 value of print_ada_methods.
6447 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
6448 Set cpp_check to it before invoking dump_ada_nodes.
6449 (dump_ada_specs): Likewise.
6451 2013-11-03 Marek Polacek <polacek@redhat.com>
6453 * c-ubsan.c: Don't include hash-table.h.
6454 (ubsan_instrument_vla): New function.
6455 * c-ubsan.h: Declare it.
6457 2013-10-31 David Malcolm <dmalcolm@redhat.com>
6459 Automated part of renaming of symtab_node_base to symtab_node.
6461 Patch autogenerated by rename_symtab.py from
6462 https://github.com/davidmalcolm/gcc-refactoring-scripts
6463 revision 58bb219cc090b2f4516a9297d868c245495ee622
6465 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
6466 symtab_node_base to symtab_node.
6468 2013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
6470 Implement C++14 digit separators.
6471 * c-lex.c (interpret_float): Remove digit separators from scratch string
6472 before building real literal.
6474 2013-10-30 Jakub Jelinek <jakub@redhat.com>
6476 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
6478 2013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
6480 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
6482 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
6484 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
6485 (insert_cilk_frame): New prototype.
6486 (cilk_init_builtins): Likewise.
6487 (gimplify_cilk_spawn): Likewise.
6488 (c_cilk_install_body_w_frame_cleanup): Likewise.
6489 (cilk_detect_spawn_and_unwrap): Likewise.
6490 (cilk_set_spawn_marker): Likewise.
6491 (build_cilk_sync): Likewise.
6492 (build_cilk_spawn): Likewise.
6495 2013-10-29 David Malcolm <dmalcolm@redhat.com>
6497 Patch autogenerated by refactor_symtab.py from
6498 https://github.com/davidmalcolm/gcc-refactoring-scripts
6499 revision 58bb219cc090b2f4516a9297d868c245495ee622
6501 * c-gimplify.c (c_genericize): Update for conversion of symtab types
6502 to a true class hierarchy.
6503 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
6505 2013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
6507 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
6509 2013-10-26 Jeff Law <law@redhat.com>
6511 * c-common.c (c_define_builtins): Remove mudflap support.
6512 * c.opt: Ignore and warn for mudflap options.
6514 2013-10-24 Tobias Burnus <burnus@net-b.de>
6517 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
6518 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
6520 2013-10-23 Jason Merrill <jason@redhat.com>
6522 * c-format.c (gcc_cxxdiag_char_table): Add %X.
6524 2013-10-11 Jakub Jelinek <jakub@redhat.com>
6526 * c-common.h (omp_clause_mask::operator !=): New method.
6527 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
6528 instead of if (mask & something) tests everywhere.
6530 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
6531 201307 instead of 201107.
6532 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
6533 (c_common_attribute_table): Add "omp declare target" and
6534 "omp declare simd" attributes.
6535 (handle_omp_declare_target_attribute,
6536 handle_omp_declare_simd_attribute): New functions.
6537 * c-omp.c: Include c-pragma.h.
6538 (c_finish_omp_taskgroup): New function.
6539 (c_finish_omp_atomic): Add swapped argument, if true,
6540 build the operation first with rhs, lhs arguments and use NOP_EXPR
6542 (c_finish_omp_for): Add code argument, pass it down to make_code.
6543 (c_omp_split_clauses): New function.
6544 (c_split_parallel_clauses): Removed.
6545 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
6546 c_omp_declare_simd_clauses_to_decls): New functions.
6547 * c-common.h (omp_clause_mask): New type.
6548 (OMP_CLAUSE_MASK_1): Define.
6549 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
6550 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
6551 omp_clause_mask::operator |, omp_clause_mask::operator &,
6552 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
6553 omp_clause_mask::operator ==): New methods.
6554 (enum c_omp_clause_split): New.
6555 (c_finish_omp_taskgroup): New prototype.
6556 (c_finish_omp_atomic): Add swapped argument.
6557 (c_finish_omp_for): Add code argument.
6558 (c_omp_split_clauses): New prototype.
6559 (c_split_parallel_clauses): Removed.
6560 (c_omp_declare_simd_clauses_to_numbers,
6561 c_omp_declare_simd_clauses_to_decls): New prototypes.
6562 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
6563 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
6564 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
6565 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
6566 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
6567 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
6568 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
6569 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
6570 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
6571 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
6572 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
6573 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
6574 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
6575 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
6576 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
6577 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
6578 PRAGMA_OMP_CLAUSE_UNIFORM.
6580 2013-10-09 Marc Glisse <marc.glisse@inria.fr>
6582 PR tree-optimization/20318
6583 * c-common.c (handle_returns_nonnull_attribute): New function.
6584 (c_common_attribute_table): Add returns_nonnull.
6586 2013-10-03 Marc Glisse <marc.glisse@inria.fr>
6589 * c.opt (fcheck-new): Move to common.opt.
6591 2013-09-25 Marek Polacek <polacek@redhat.com>
6592 Jakub Jelinek <jakub@redhat.com>
6595 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
6596 an expression if we can prove it is correct.
6597 (ubsan_instrument_division): Likewise. Remove unnecessary
6600 2013-09-18 Marek Polacek <polacek@redhat.com>
6603 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
6605 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
6607 2013-09-14 Iain Sandoe <iain@codesourcery.com>
6610 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
6611 fobjc-gc, freplace-objc-classes): Accept for LTO.
6613 2013-09-13 Jacek Caban <jacek@codeweavers.com>
6615 * c-target.def: New hook
6617 2013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
6620 * c.opt (Wdelete-incomplete): Add.
6622 2013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
6624 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
6625 (vector_types_compatible_elements_p): New function.
6626 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
6628 (vector_types_compatible_elements_p): Declare.
6630 2013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
6632 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
6633 a virtual member function.
6634 (pp_simple_type_specifier): Remove.
6635 (pp_c_type_specifier): Likewise.
6636 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
6637 Rename from pp_c_type_specifier. Adjust.
6638 (c_pretty_printer::c_pretty_printer): Do not assign to
6639 simple_type_specifier.
6641 2013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6643 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
6645 (c_pretty_printer::storage_class_specifier): Likewise.
6646 (c_pretty_printer::initializer): Likewise.
6647 (pp_declaration): Remove.
6648 (pp_declaration_specifiers): Likewise.
6649 (pp_abstract_declarator): Likewise.
6650 (pp_declarator): Likewise.
6651 (pp_type_id): Likewise.
6652 (pp_statement): Likewise.
6653 (pp_constant): Likewise.
6654 (pp_id_expression): Likewise.
6655 (pp_primary_expression): Likewise.
6656 (pp_unary_expression): Likewise.
6657 (pp_multiplicative_expression): Likewise.
6658 (pp_conditional_expression): Likewise.
6659 (pp_assignment_expression): Likewise.
6660 (pp_expression): Likewise.
6661 (pp_c_type_id): Likewise.
6662 (pp_c_storage_class_specifier): Likewise.
6663 * c-pretty-print.c (pp_c_type_cast): Tidy.
6664 (pp_c_pointer): Likewise.
6665 (pp_c_type_specifier): Likewise.
6666 (pp_c_parameter_type_list): Likewise.
6667 (pp_c_function_definition): Likewise.
6668 (pp_c_init_declarator): Likewise.
6669 (pp_c_initializer_list): Likewise.
6670 (pp_c_constructor_elts): Likewise.
6671 (c_pretty_printer::direct_abstract_declarator): Likewise.
6672 (c_pretty_printer::declaration_specifiers): Likewise.
6673 (c_pretty_printer::primary_expression): Likewise.
6674 (c_pretty_printer::postfix_expression): Likewise.
6675 (c_pretty_printer::type_id): Rename from pp_c_type_id.
6676 (c_pretty_printer::storage_class_specifier): Rename from
6677 pp_c_storage_class_specifier.
6678 (c_pretty_printer::initializer): Rename from pp_c_initializer.
6679 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
6680 storage_class_specifier, initializer, offset_list, flags.
6682 2013-08-30 Marek Polacek <polacek@redhat.com>
6684 * c-ubsan.c: New file.
6685 * c-ubsan.h: New file.
6687 2013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
6689 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
6691 (c_pretty_printer::declaration_specifiers): Likewise.
6692 (c_pretty_printer::declarator): Likewise.
6693 (c_pretty_printer::abstract_declarator): Likewise.
6694 (c_pretty_printer::direct_abstract_declarator): Likewise.
6695 (c_pretty_printer::direct_declarator): Likewise.
6696 (c_pretty_printer::function_specifier): Likewise.
6697 (pp_declaration): Adjust.
6698 (pp_declaration_specifiers): Likewise.
6699 (pp_abstract_declarator): Likewise.
6700 (pp_direct_declarator): Likewise.
6701 (pp_function_specifier): Likewise.
6702 (pp_direct_abstract_declarator): Remove as unused.
6703 (pp_c_declaration): Remove.
6704 (pp_c_declaration_specifiers): Likewise.
6705 (pp_c_declarator): Likewise.
6706 (pp_c_direct_declarator): Likewise.
6707 (pp_c_function_specifier): Likewise.
6708 (pp_c_direct_abstract_declarator): Likewise.
6709 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
6710 from pp_c_abstract_declarator. Adjust.
6711 (c_pretty_printer::direct_abstract_declarator): Rename from
6712 pp_c_direct_abstract_declarator. Adjust.
6713 (c_pretty_printer::function_specifier): Rename from
6714 pp_c_function_specifier. Adjust.
6715 (c_pretty_printer::declaration_specifiers): Rename from
6716 pp_c_declaration_specifiers. Adjust.
6717 (c_pretty_printer::direct_declarator): Rename from
6718 pp_c_direct_declarator. Adjust.
6719 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
6720 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
6721 (c_pretty_printer::c_pretty_printer): Do not assign to
6722 declaration, declaration_specifiers, declarator,
6723 direct_declarator, direct_abstract_declarator, function_specifier.
6725 2013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
6727 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
6728 virtual member function.
6729 (c_pretty_printer::multiplicative_expression): Likewise.
6730 (c_pretty_printer::conditional_expression): Likewise.
6731 (c_pretty_printer::assignment_expression): Likewise.
6732 (c_pretty_printer::expression): Likewise.
6733 (pp_unary_expression): Adjust.
6734 (pp_multiplicative_expression): Likewise.
6735 (pp_assignment_expression): Likewise.
6736 (pp_conditional_expression): Likewise.
6737 (pp_expression): Likewise.
6738 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
6739 from pp_c_unary_expression. Adjust.
6740 (c_pretty_printer::multiplicative_expression): Rename from
6741 pp_c_multiplicative_expression. Adjust.
6742 (c_pretty_printer::conditional_expression): Rename from
6743 pp_c_conditional_expression. Adjust.
6744 (c_pretty_printer::assignment_expression): Rename from
6745 pp_c_assignment_expression. Adjust.
6746 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
6747 (c_pretty_printer::c_pretty_printer): Do not assign to
6748 unary_expression, multiplicative_expression,
6749 conditional_expression, expression.
6751 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
6753 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
6754 virtual member function.
6755 (pp_postfix_expression): Adjust.
6756 (pp_c_postfix_expression): Remove.
6757 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
6758 from pp_c_postfix_expression. Adjust.
6759 (c_pretty_printer::c_pretty_printer): Do not assign to
6762 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
6764 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
6765 virtua member function.
6766 (pp_primary_expression): Adjust.
6767 (pp_c_primary_expression): Remove.
6768 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
6769 from pp_c_primary_expression. Adjust.
6770 (pp_c_initializer_list): Use pp_primary_expression.
6771 (c_pretty_printer::c_pretty_printer): Do not assign to
6774 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
6776 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
6777 * c-pretty-print.c (M_): Remove.
6778 (c_pretty_printer::translate_string): Define.
6779 (pp_c_type_specifier): Use it.
6780 (pp_c_primary_expression): Likewise.
6781 (pp_c_expression): Likewise.
6783 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
6785 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
6787 (pp_c_id_expression): Remove.
6788 (pp_id_expression): Adjust.
6789 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
6790 pp_c_id_expression. Adjust.
6791 (pp_c_postfix_expression): Use pp_id_expression.
6792 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
6794 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
6796 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
6798 (pp_constant): Adjust.
6799 (pp_c_constant): Remove.
6800 * c-pretty-print.c (c_pretty_printer::constant): Rename from
6801 pp_c_constant. Adjust.
6803 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
6804 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
6806 2013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
6808 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
6809 (c_pretty_printer::c_pretty_printer): Declare.
6810 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
6811 c_pretty_printer_init. Adjust.
6812 (print_c_tree): Do not call c_pretty_printer_init.
6813 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
6815 2013-08-09 Arnaud Charlet <charlet@adacore.com>
6817 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
6819 2013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
6822 * c-common.c (pointer_int_sum): Add bool parameter.
6823 * c-common.h (pointer_int_sum): Adjust declaration.
6825 2013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
6827 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
6828 c_pretty_printer variable.
6830 2013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
6832 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
6834 (pp_c_base): Likewise. Adjust users.
6835 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
6836 (pp_c_whitespace): Do not call pp_base.
6837 (pp_c_left_paren): Likewise.
6838 (pp_c_right_paren): Likewise.
6839 (pp_c_left_brace): Likewise.
6840 (pp_c_right_brace): Likewise.
6841 (pp_c_left_bracket): Likewise.
6842 (pp_c_right_bracket): Likewise.
6843 (pp_c_dot): Likewise.
6844 (pp_c_ampersand): Likewise.
6845 (pp_c_star): Likewise.
6846 (pp_c_arrow): Likewise.
6847 (pp_c_semicolon): Likewise.
6848 (pp_c_complement): Likewise.
6849 (pp_c_exclamation): Likewise.
6850 (pp_c_direct_declarator): Likewise.
6851 (pp_c_ws_string): Likewise.
6852 (pp_c_identifier): Likewise.
6853 (pp_c_statement): Likewise.
6854 (print_c_tree): Likewise.
6856 2013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
6859 * c-common.c (c_parse_error): Catch user-defined literal tokens and
6860 provide useful error strings.
6862 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6864 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
6865 printer functions instead of pp_string or operators and punctuators.
6866 (dump_generic_ada_node): Likewise.
6867 * c-pretty-print.c (pp_c_type_specifier): Likewise.
6868 (pp_c_relational_expression): Likewise.
6869 (pp_c_logical_or_expression): Likewise.
6871 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6873 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
6874 functions instead of pp_character.
6875 (pp_ada_tree_identifier): Likewise.
6876 (dump_ada_double_name): Likewise.
6877 (dump_ada_function_declaration): Likewise.
6878 (dump_ada_array_domains): Likewise.
6879 (dump_template_types): Likewise.
6880 (dump_generic_ada_node): Likewise.
6881 (print_ada_declaration): Likewise.
6882 (print_ada_struct_decl): Likewise.
6883 * c-pretty-print.c (pp_c_integer_constant): Likewise.
6885 2013-07-23 Tom Tromey <tromey@redhat.com>
6887 * c-common.h (enum rid) <RID_GENERIC>: New constant.
6888 * c-common.c (c_common_reswords): Add _Generic.
6890 2013-07-21 OndÅ
\99ej BÃlka <neleai@seznam.cz>
6892 * c-common.c: Fix typos.
6893 * c-common.h: Likewise.
6895 2013-07-13 Lubos Lunak <l.lunak@suse.cz>
6898 * c-common.c (c_common_attribute_table): Add warn_unused.
6899 (handle_warn_unused_attribute): New.
6901 2013-07-10 Jakub Jelinek <jakub@redhat.com>
6903 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
6904 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
6906 2013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
6909 * c.opt: Add Wconditionally-supported.
6911 2013-07-08 Graham Stott <graham.stott@btinternet.com>
6913 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6914 unused variables l_length and l_node.
6916 2013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
6919 * c-common.c (complete_array_type): Delay folding first index
6920 like other indices. When folding, check for index overflow.
6922 2013-06-27 Marc Glisse <marc.glisse@inria.fr>
6925 * c-common.h (c_build_vec_perm_expr): New complain argument.
6926 * c-common.c (c_build_vec_perm_expr): Likewise.
6927 Use save_expr also in C++.
6929 2013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
6931 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
6932 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
6933 * c-opts.c (c_common_post_options): Likewise.
6935 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
6937 * array-notation-common.c (length_mismatch_in_expr): Changed the
6938 parameter type's from a dynamic array to a vec_tree. Also removed
6939 the size parameters.
6940 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
6943 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
6945 * c-common.h (struct cilkplus_an_parts): New structure.
6946 (struct cilkplus_an_loop_parts): Likewise.
6947 (cilkplus_extract_an_triplets): New prototype.
6948 (fix_sec_implicit_args): Likewise.
6949 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
6950 (fix_sec_implicit_args): Likewise.
6952 2013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
6954 * array-notation-common.c (find_inv_trees): Removed an unwanted
6956 * c-common.h (struct inv_list::additional_tcodes): Changed type from
6957 enum rid to enum tree_code.
6959 2013-06-11 Jan Hubicka <jh@suse.cz>
6961 * c-common.c (handle_alias_ifunc_attribute): Do not set
6962 DECL_EXTERNAL for weakref variables.
6963 * c-pragma.c (handle_pragma_weak): Make sure aliases
6964 are not declared as external.
6966 2013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
6968 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
6969 function from c/c-array-notation.c.
6970 (is_cilkplus_reduce_builtin): Likewise.
6971 (find_rank): Likewise.
6972 (extract_array_notation_exprs): Likewise.
6973 (replace_array_notations): Likewise.
6974 (find_inv_trees): Likewise.
6975 (replace_inv_trees): Likewise.
6976 (contains_array_notation_expr): Likewise.
6977 (find_correct_array_notation_type): Likewise.
6978 * c-common.h (struct inv_list): Moved this struct from the file
6979 c/c-array-notation.c and added a new field called additional tcodes.
6980 (length_mismatch_in_expr_p): New prototype.
6981 (is_cilkplus_reduce_builtin): Likewise.
6982 (find_rank): Likewise.
6983 (extract_array_notation_exprs): Likewise.
6984 (replace_array_notation): Likewise.
6985 (find_inv_trees): Likewise.
6986 (replace_inv_trees): Likewise.
6987 (find_correct_array_notation_type): Likewise.
6989 2013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
6991 * c-common.c (c_define_builtins): When cilkplus is enabled, the
6992 function array_notation_init_builtins is called.
6993 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
6994 * c-common.def (ARRAY_NOTATION_REF): New tree.
6995 * c-common.h (build_array_notation_expr): New function declaration.
6996 (build_array_notation_ref): Likewise.
6997 (extract_sec_implicit_index_arg): New extern declaration.
6998 (is_sec_implicit_index_fn): Likewise.
6999 (ARRAY_NOTATION_CHECK): New define.
7000 (ARRAY_NOTATION_ARRAY): Likewise.
7001 (ARRAY_NOTATION_START): Likewise.
7002 (ARRAY_NOTATION_LENGTH): Likewise.
7003 (ARRAY_NOTATION_STRIDE): Likewise.
7004 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
7006 (pp_c_expression): Likewise.
7007 * c.opt (flag_enable_cilkplus): New flag.
7008 * array-notation-common.c: New file.
7010 2013-05-14 Jakub Jelinek <jakub@redhat.com>
7013 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
7015 2013-05-10 Marc Glisse <marc.glisse@inria.fr>
7017 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
7020 2013-05-07 Han Shen <shenhan@google.com>
7022 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
7024 2013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
7026 * c-common.c (check_user_alignment): Emit error for negative values.
7028 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
7030 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
7032 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
7034 * c-cppbuiltin.c (c_cpp_builtins): Do not define
7035 __GXX_EXPERIMENTAL_CXX1Y__.
7037 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
7038 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
7040 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
7041 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
7042 to simply use OPT_Wpointer_arith.
7043 (c_sizeof_or_alignof_type): Likewise.
7045 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
7047 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
7049 2013-04-12 Jakub Jelinek <jakub@redhat.com>
7051 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
7052 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
7055 2013-04-07 Steven Bosscher <steven@gcc.gnu.org>
7057 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
7059 2013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
7061 * c-common.c (pointer_int_sum): Remove dead code.
7063 2013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
7066 * c-common.c (handle_optimize_attribute): Don't call
7067 save_optabs_if_changed.
7069 2013-03-05 Jakub Jelinek <jakub@redhat.com>
7072 * c-pch.c (pch_init): Free target_validity at the end.
7074 2013-03-04 Jakub Jelinek <jakub@redhat.com>
7076 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
7078 2013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
7079 Jakub Jelinek <jakub@redhat.com>
7082 * c-common.c (handle_no_sanitize_address_attribute): New function.
7083 (c_common_attribute_table): Add no_sanitize_address attribute.
7084 (handle_no_address_safety_analysis_attribute): Add
7085 no_sanitize_address attribute, not no_address_safety_analysis
7088 2013-02-18 Aldy Hernandez <aldyh@redhat.com>
7091 * c-common.c (handle_optimize_attribute): Call
7092 save_optabs_if_changed.
7094 2013-02-18 Jakub Jelinek <jakub@redhat.com>
7095 Steven Bosscher <steven@gcc.gnu.org>
7098 * c-opts.c (c_common_post_options): If debug info is enabled
7099 and non-dwarf*, refuse to load PCH files and when writing PCH
7102 2013-02-05 Jakub Jelinek <jakub@redhat.com>
7105 * c-common.c (handle_error_attribute): Fix condition.
7107 2013-01-30 Jakub Jelinek <jakub@redhat.com>
7110 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
7112 2013-01-18 Jason Merrill <jason@redhat.com>
7115 * c.opt (-fextern-tls-init): New.
7116 * c-opts.c (c_common_post_options): Handle it.
7118 2013-01-09 Jakub Jelinek <jakub@redhat.com>
7121 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
7122 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
7123 and is either negative or bigger or equal to type precision
7124 of the first operand.
7126 2012-12-03 Marek Polacek <polacek@redhat.com>
7129 * c-common.c (check_user_alignment): Swap order of tests,
7130 check TREE_CODE first.
7132 2012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
7135 * c-common.h (overflow_type): New enum.
7136 (build_userdef_literal): Add overflow_type argument.
7137 (tree_userdef_literal): Add overflow_type.
7138 (USERDEF_LITERAL_OVERFLOW): New access macro.
7139 * c-common.c (build_userdef_literal): Add overflow_type
7141 * c-lex.c (c_lex_with_flags): Add overflow_type to
7142 build_userdef_literal calls.
7143 (interpret_integer, interpret_float): Add overflow_type argument.
7145 2012-11-28 Richard Biener <rguenther@suse.de>
7148 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
7149 here and use a type with proper overflow behavior for types that would
7150 need to be promoted for the arithmetic.
7152 2012-11-23 Jakub Jelinek <jakub@redhat.com>
7155 * c-common.c (handle_no_address_safety_analysis_attribute): New
7157 (c_common_attribute_table): Add no_address_safety_analysis.
7159 2012-11-16 Simon Baldwin <simonb@google.com>
7161 * c.opt: Add f[no-]canonical-system-headers.
7162 * c-opts.c (c_common_handle_option): Handle
7163 OPT_fcanonical_system_headers.
7165 2012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
7168 * c-opts.c (c_common_handle_option): Set new flags.
7169 * c.opt: Describe new flags.
7171 2012-11-09 Jason Merrill <jason@redhat.com>
7173 * c.opt (Wabi-tag): New.
7175 2012-11-09 Andi Kleen <ak@linux.intel.com>
7178 * c-common.c (get_atomic_generic_size): Mask with
7181 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
7184 * c.opt (Wformat): Make it Alias Wformat=1.
7185 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
7186 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
7188 (Wformat=): RejectNegative. Use LangEnabledBy.
7189 (Wnonnull): Use LangEnabledBy.
7190 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
7191 * c-format.c (set_Wformat): Delete.
7192 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
7193 (maybe_read_dollar_number): Likewise.
7194 (avoid_dollar_number): Likewise.
7195 (finish_dollar_format_checking): Likewise.
7196 (check_format_info): Likewise.
7197 (check_format_info_main): Likewise.
7198 (check_format_types): Likewise.
7199 (format_type_warning): Likewise.
7200 * c-common.c (int): Likewise.
7201 (check_function_sentinel): Likewise.
7202 * c-common.h (warn_format,set_Wformat): Do not declare here.
7204 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
7207 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
7208 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
7210 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
7212 (Wvariadic-macros): Init(1).
7213 * c-opts.c (c_common_handle_option): Do not handle them
7215 (c_common_post_options): Likewise.
7216 (sanitize_cpp_opts): warn_unused_macros is now
7217 cpp_warn_unused_macros.
7218 (push_command_line_include): Likewise.
7219 * c-common.c (warn_unknown_pragmas): Do not define.
7220 * c-common.h (warn_unknown_pragmas): Do not declare.
7222 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
7225 * c-common.c (conversion_warning): Handle conditional expressions.
7227 2012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
7230 * c.opt (Wreturn_local_addr): Define new option.
7232 2012-10-25 Jason Merrill <jason@redhat.com>
7234 * c.opt (Wvirtual-move-assign): New.
7236 * c.opt (Winherited-variadic-ctor): New.
7238 2012-10-25 Marc Glisse <marc.glisse@inria.fr>
7241 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
7243 2012-10-23 Joseph Myers <joseph@codesourcery.com>
7245 * c-common.h (pch_cpp_save_state): Declare.
7246 * c-target.def (c_preinclude): New hook.
7247 * c-opts.c (done_preinclude): New.
7248 (push_command_line_include): Handle default preincluded header.
7249 (cb_file_change): Call pch_cpp_save_state when calling
7250 push_command_line_include.
7251 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
7252 (pch_cpp_save_state): New.
7253 (pch_init): Call pch_cpp_save_state conditionally, instead of
7254 calling cpp_save_state.
7256 2012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
7260 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
7261 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
7262 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
7263 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
7264 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
7265 * c-opts.c (c_common_handle_option): Remove explicit handling from
7267 (c_common_post_options): Likewise.
7269 2012-10-18 Eric Botcazou <ebotcazou@adacore.com>
7271 * c-ada-spec.c (LOCATION_COL): Delete.
7272 (compare_location): New function.
7273 (compare_node): Use it.
7274 (compare_comment): Likewise.
7276 2012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
7280 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
7281 * c-opts.c (c_common_handle_option): Do not set them here. Add
7283 (c_common_post_options): Likewise.
7285 2012-10-16 Eric Botcazou <ebotcazou@adacore.com>
7287 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
7288 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
7289 Remove POINTER_TYPE handling, add large unsigned handling and use
7290 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
7292 2012-10-12 Jakub Jelinek <jakub@redhat.com>
7295 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
7296 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
7297 locs and array of 3 trees instead of just single loc and single
7298 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
7299 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
7300 For *cmp* builtins that take two sources strings report warnings
7301 about first and second source, not about destination and source.
7303 2012-10-12 Marc Glisse <marc.glisse@inria.fr>
7306 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
7308 2012-10-11 Eric Botcazou <ebotcazou@adacore.com>
7310 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
7311 declaring something coming from another file.
7313 2012-10-10 Arnaud Charlet <charlet@adacore.com>
7316 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
7318 2012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
7321 * c-common.c (warn_about_parentheses): Add location_t parameter;
7322 use EXPR_LOC_OR_LOC.
7323 * c-common.h: Update declaration.
7325 2012-10-09 Marc Glisse <marc.glisse@inria.fr>
7328 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
7329 more operations. Make error messages optional.
7330 * c-common.h (enum stv_conv): Moved from c-typeck.c.
7331 (scalar_to_vector): Declare.
7333 2012-10-08 Jason Merrill <jason@redhat.com>
7335 * c-common.c (c_common_reswords): Add thread_local.
7337 2012-10-08 Dodji Seketeli <dodji@redhat.com>
7339 PR c++/53528 C++11 attribute support
7340 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
7342 * c-common.c (check_cxx_fundamental_alignment_constraints): New
7344 (handle_aligned_attribute): In choose strictest alignment
7345 among many. Use new check_cxx_fundamental_alignment_constraints.
7346 (handle_transparent_union_attribute): In c++11 attribute syntax,
7347 don't look through typedefs.
7349 2012-10-04 Arnaud Charlet <charlet@adacore.com>
7351 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
7352 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
7355 2012-09-25 Dehao Chen <dehao@google.com>
7358 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
7359 map when read in the pch.
7361 2012-09-18 Arnaud Charlet <charlet@adacore.com>
7363 * c-ada-spec.c: Style fixes.
7365 2012-09-18 Thomas Quinot <quinot@adacore.com>
7367 * c.opt (-fada-spec-parent): Define new command line switch.
7368 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
7369 is specified, generate binding spec as a child of the specified unit.
7371 2012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
7372 Manuel López-Ibáñez <manu@gcc.gnu.org>
7375 * c.opt ([Winit-self]): Enabled by -Wall in C++.
7377 2012-08-23 Arnaud Charlet <charlet@adacore.com>
7379 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
7380 for pointers, and add missing Convention C pragma.
7381 (print_ada_struct_decl): Add missing aliased keyword.
7382 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
7384 2012-08-17 Jakub Jelinek <jakub@redhat.com>
7386 * c-common.c (sizeof_pointer_memaccess_warning): New function.
7387 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
7388 * c-opts.c (c_common_handle_option): Enable it for -Wall.
7389 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
7390 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
7392 2012-08-10 Richard Guenther <rguenther@suse.de>
7394 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
7396 2012-08-07 Steven Bosscher <steven@gcc.gnu.org>
7398 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
7399 instead of separate pp_newline and pp_flush.
7400 (print_c_tree): Likewise.
7402 2012-07-26 Richard Henderson <rth@redhat.com>
7404 * c-common.c (handle_hot_attribute): Allow labels.
7405 (handle_cold_attribute): Likewise.
7407 2012-07-20 Jakub Jelinek <jakub@redhat.com>
7410 * c-common.c (check_function_nonnull): Handle multiple nonnull
7411 attributes properly.
7413 2012-07-16 Steven Bosscher <steven@gcc.gnu.org>
7415 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
7416 * c-ada-spec.c: Likewise.
7417 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
7419 2012-07-14 Steven Bosscher <steven@gcc.gnu.org>
7421 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
7422 Remove code conditional on it.
7424 2012-07-11 Steven Bosscher <steven@gcc.gnu.org>
7426 * c-gimplify.c: Do not include basic-block.h.
7427 * c-common.c: Do not include linfuncs.h.
7429 2012-07-08 Steven Bosscher <steven@gcc.gnu.org>
7431 * c-common.h: Include tree.h.
7433 2012-07-02 Jason Merrill <jason@redhat.com>
7436 * c-common.c (get_priority): Call default_conversion.
7438 2012-07-01 Uros Bizjak <ubizjak@gmail.com>
7440 * c-pch.c (c_common_write_pch): Remove unused variables.
7442 2012-06-29 Steven Bosscher <steven@gcc.gnu.org>
7444 * cppspec.c: Moved from gcc/ to here.
7446 2012-06-27 Kai Tietz <ktietz@redhat.com>
7448 PR preprocessor/37215
7449 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
7451 2012-06-21 Steven Bosscher <steven@gcc.gnu.org>
7453 * c-common.h (c_common_print_pch_checksum): Remove.
7454 * c-pch.c: Do not include output.h.
7455 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
7456 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
7457 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
7458 (struct c_pch_header): Remove.
7459 (get_ident): Update gpch version.
7460 (pch_init): Do not print executable_checksum to asm_out_file.
7461 Do not fail if there is no asm_out_file to read back from. Set
7462 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
7463 (c_common_write_pch): Verify that nothing was written to asm_out_file
7464 since pch_init was called. Do not write a c_pch_header, and do not
7465 copy from asm_out_file to the PCH.
7466 (c_common_read_pch): Do not read a c_pch_header, and do not restore
7467 the content of asm_out_file from the PCH.
7468 (c_common_print_pch_checksum): Remove.
7469 * c-opts.c (c_common_init): Print out executable_checksum directly.
7471 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
7473 * c-target.def (objc_declare_unresolved_class_reference,
7474 objc_declare_class_definition): Add new hooks.
7476 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
7478 * c-lex.c: Do not include output.h.
7479 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
7480 Remove uses of ASM_OUTPUT_IDENT.
7482 2012-06-15 Marc Glisse <marc.glisse@inria.fr>
7485 * c-common.h (c_build_vec_perm_expr): Move decl here.
7486 * c-common.c (c_build_vec_perm_expr): Move definition
7489 2012-06-06 Steven Bosscher <steven@gcc.gnu.org>
7491 * c.opt (fconserve-space): Turn into a no-op.
7493 2012-06-04 Sterling Augustine <saugustine@google.com>
7495 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
7496 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
7497 both the start and end of the function.
7499 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
7501 * c-common.c: Do not include output.h.
7502 * c-pragma.c: Likewise.
7504 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
7506 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
7507 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
7508 (lang_decl_name): Handle namespace decls.
7510 2012-05-31 Steven Bosscher <steven@gcc.gnu.org>
7512 * c-ada-spec.c: Do not include output.h.
7513 * c-semantics.c: Likewise.
7515 2012-05-29 Joseph Myers <joseph@codesourcery.com>
7517 * c-common.c: Fix typo.
7519 2012-05-29 Michael Matz <matz@suse.de>
7521 * c-common.h (c_expand_decl): Remove prototype.
7523 2012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
7525 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
7526 * c-opts.c (c_common_handle_option): Remove code handling
7527 warn_missing_braces.
7529 2012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
7532 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
7535 2012-05-22 Dodji Seketeli <dodji@redhat.com>
7538 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
7540 2012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
7542 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
7543 * c-opts.c (c_common_handle_option): Do not handle explicitly
7544 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
7546 2012-05-16 Dodji Seketeli <dodji@redhat.com>
7548 PR preprocessor/7263
7549 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
7550 to cpp_classify_number. For diagnostics, use the precise location
7551 instead of the global input_location.
7553 2012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
7556 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
7558 2012-05-14 Bernd Schmidt <bernds@codesourcery.com>
7560 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
7562 2012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
7565 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
7566 Wreorder): Use LangEnabledBy.
7567 * c-opts.c (c_common_handle_option): Do not enable them
7568 explicitly. Call lang-specific generated functions.
7569 (c_common_post_options): Do not set them here.
7571 2012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
7573 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
7574 Wmissing-field-initializers,Wmissing-parameter-type,
7575 Wold-style-declaration,Woverride-init): Use EnabledBy.
7576 * c-opts.c (c_common_post_options): Do not set here explicitly.
7578 2012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
7581 * c-opts.c (c_common_handle_option): Use handle_generated_option
7582 to enable sub-options.
7584 2012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
7587 * c-common.c (warnings_for_convert_and_check): Use warning_at.
7589 2012-05-10 Richard Guenther <rguenther@suse.de>
7591 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
7592 adjust commentary about TYPE_IS_SIZETYPE types.
7594 2012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
7597 * c-common.c (warn_logical_operator): Check that argument of
7598 integer_zerop is not NULL.
7600 2012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
7603 * c-common.c (warn_logical_operator): Do not warn if either side
7604 is already true or false.
7606 2012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
7609 * c-common.c (expr_original_type): New.
7610 (shorten_compare): Do not warn for enumeration types.
7612 2012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
7614 * c.opt (fpermissive): Add Var(flag_permissive).
7616 2012-04-30 Marc Glisse <marc.glisse@inria.fr>
7619 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
7620 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
7622 2012-04-30 Dodji Seketeli <dodji@redhat.com>
7624 Add -Wvarargs option
7625 * c.opt (Wvarargs): Define new option.
7627 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
7629 * c-common.c (check_function_arguments): Replace
7630 Wmissing-format-attribute with Wsuggest-attribute=format.
7632 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
7634 * c.opt (Wsuggest-attribute=format): New. Alias of
7635 Wmissing-format-attribute.
7636 * c-format.c (decode_format_type): Replace
7637 Wmissing-format-attribute with Wsuggest-attribute=format.
7638 (check_function_format): Likewise.
7640 2012-04-27 Ollie Wild <aaw@google.com>
7642 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
7643 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
7644 * c.opt: Add Wliteral-suffix.
7646 2012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
7649 * c.opt (Wpedantic): New.
7650 (pedantic): Alias Wpedantic.
7651 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
7652 (c_common_post_options): Likewise.
7653 (sanitize_cpp_opts): Likewise.
7654 * c-lex.c (interpret_float): Likewise.
7655 * c-format.c (check_format_types): Likewise.
7656 * c-common.c (pointer_int_sum): Likewise.
7657 (c_sizeof_or_alignof_type): Likewise.
7658 (c_add_case_label): Likewise.
7659 (c_do_switch_warnings): Likewise.
7660 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
7662 2012-04-15 Jason Merrill <jason@redhat.com>
7665 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
7666 (C_STD_NAME): Distinguish between C++98 and C++11.
7668 2012-04-11 Eric Botcazou <ebotcazou@adacore.com>
7671 * c-common.h (uint16_type_node): Rename into...
7672 (c_uint16_type_node): ...this.
7673 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
7674 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
7676 2012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
7678 * c-common.c (warn_if_unused_value): Move definition to here.
7679 * c-common.h (warn_if_unused_value): Move declaration to here.
7681 2012-03-23 William Bader <williambader@hotmail.com>
7683 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
7685 2012-03-20 Jason Merrill <jason@redhat.com>
7687 * c-common.h (enum cxx_dialect): Add cxx1y.
7688 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
7690 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
7691 * c-opts.c (c_common_post_options): Likewise.
7692 (set_std_cxx1y): New.
7693 (c_common_handle_option): Call it.
7694 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
7696 2012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
7699 * c.opt ([Wuseless-cast]): Add.
7701 2012-03-16 Richard Guenther <rguenther@suse.de>
7703 * c-pretty-print.c (pp_c_initializer_list): Adjust.
7705 2012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
7708 * c.opt (ftemplate-backtrace-limit) Add.
7710 2012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7712 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
7714 * c-pragma.c (handle_pragma_extern_prefix): Remove.
7715 (init_pragma): Don't register extern_prefix.
7717 2012-03-12 Richard Guenther <rguenther@suse.de>
7719 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
7720 (builtin_type_for_size): Likewise.
7722 2012-02-13 Jakub Jelinek <jakub@redhat.com>
7725 * c-common.c (sync_resolve_params): Don't decide whether to convert
7726 or not based on TYPE_SIZE comparison, convert whenever arg_type
7727 is unsigned INTEGER_TYPE.
7729 2012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
7732 * c.opt ([Wunused-local-typedefs]): Fix description.
7734 2012-01-24 Mike Stump <mikestump@comcast.net>
7736 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
7739 2012-01-18 Richard Guenther <rguenther@suse.de>
7741 * c-opts.c (c_common_post_options): Reset LTO flags if
7742 we are about to generate a PCH.
7744 2012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
7747 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
7748 use pp_unsigned_wide_integer.
7750 2012-01-10 Richard Guenther <rguenther@suse.de>
7753 * c-opts.c (c_common_handle_option): Move -Werror handling
7754 to language independent code.
7756 2012-01-05 Richard Guenther <rguenther@suse.de>
7759 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
7762 2011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
7765 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
7766 of array types with an unknown bound.
7768 2011-12-20 Joseph Myers <joseph@codesourcery.com>
7770 * c-common.c (flag_isoc99): Update comment to refer to C11.
7771 (flag_isoc1x): Change to flag_isoc11.
7772 * c-common.h (flag_isoc99): Update comment to refer to C11.
7773 (flag_isoc1x): Change to flag_isoc11.
7774 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
7776 * c-opts.c (set_std_c1x): Change to set_std_c11.
7777 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
7779 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
7780 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
7781 * c.opt (std=c1x): Change to std=c11. Document as non-draft
7783 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
7784 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
7785 (std=gnu1x): Make alias of std=gnu11.
7787 2011-12-19 Jason Merrill <jason@redhat.com>
7790 * c-common.c (handle_transparent_union_attribute): Check the first
7791 field if the type is complete.
7793 2011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
7796 * c-common.c (RID_IS_FINAL): Add.
7797 * c-common.h (RID_IS_FINAL): Add.
7799 2011-11-30 Iain Sandoe <iains@gcc.gnu.org>
7801 * c.opt (fgnu-runtime): Provide full description.
7802 (fnext-runtime): Likewise.
7803 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
7805 2011-11-28 Andrew MacLeod <amacleod@redhat.com>
7807 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
7808 predefines in one place. Add LOCK_FREE predefines.
7809 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
7812 2011-11-24 Andrew MacLeod <amacleod@redhat.com>
7815 * c-common.c (get_atomic_generic_size): Check for various error
7817 (resolve_overloaded_atomic_exchange,
7818 resolve_overloaded_atomic_compare_exchange,
7819 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
7820 error_mark_node for error conditions.
7822 2011-11-08 Richard Guenther <rguenther@suse.de>
7827 2011-11-07 Richard Henderson <rth@redhat.com>
7828 Aldy Hernandez <aldyh@redhat.com>
7829 Torvald Riegel <triegel@redhat.com>
7831 Merged from transactional-memory.
7833 * c-common.c (handle_tm_wrap_attribute,
7834 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
7835 (struct c_common_reswords): Added __transaction* keywords.
7836 (struct c_common_attribute_table): Added transaction* and tm_regparm
7838 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
7840 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
7841 find_tm_attribute): Declare.
7843 2011-11-07 Jason Merrill <jason@redhat.com>
7846 * c-common.c, c-common.h: Revert yesterday's changes.
7848 2011-11-06 Jason Merrill <jason@redhat.com>
7851 * c-common.c (decl_has_visibility_attr): Split out from...
7852 (c_determine_visibility): ...here.
7853 * c-common.h: Declare it.
7855 2011-11-06 Joseph Myers <joseph@codesourcery.com>
7857 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
7858 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
7860 (check_user_alignment): New. Split out of
7861 handle_aligned_attribute. Disallow integer constants with
7862 noninteger types. Conditionally allow zero.
7863 (handle_aligned_attribute): Use check_user_alignment.
7864 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
7866 2011-11-06 Andrew MacLeod <amacleod@redhat.com>
7867 Richard Henderson <rth@redhat.com>
7869 Merged from cxx-mem-model.
7871 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
7872 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
7873 parameters that are the same type size.
7874 (get_atomic_generic_size): New. Find size of generic
7875 atomic function parameters and do typechecking.
7876 (add_atomic_size_parameter): New. Insert size into parameter list.
7877 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
7878 either __atomic_exchange_n or external library call.
7879 (resolve_overloaded_atomic_compare_exchange): Restructure
7880 __atomic_compare_exchange to either _n variant or external library call.
7881 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
7882 __atomic_load_n or an external library call.
7883 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
7884 __atomic_store_n or an external library call.
7885 (resolve_overloaded_builtin): Handle new __atomic builtins.
7887 2011-11-04 Eric Botcazou <ebotcazou@adacore.com>
7890 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
7891 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
7892 <INDIRECT_REF>: Return the argument.
7893 <ARRAY_REF>: Remove special code for negative offset.
7894 Call fold_build_pointer_plus instead of size_binop.
7895 (fold_offsetof): Remove STOP_REF argument and adjust.
7896 * c-common.h (fold_offsetof_1): Declare.
7897 (fold_offsetof): Remove STOP_REF argument.
7899 2011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
7902 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7903 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7904 Wnarrowing for C++0x and C++98.
7905 * c.opt ([Wnarrowing]): Update.
7907 2011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
7910 * c.opt: Add Wzero-as-null-pointer-constant.
7912 2011-10-31 Jason Merrill <jason@redhat.com>
7914 * c.opt (-fdeduce-init-list): Off by default.
7917 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
7918 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
7920 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
7922 2011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
7925 * c.opt (fvisibility-inlines-hidden): Description change.
7927 2011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
7929 Implement C++11 user-defined literals.
7930 * c-common.c (build_userdef_literal): New.
7931 * c-common.def: New tree code.
7932 * c-common.h (tree_userdef_literal): New tree struct and accessors.
7933 * c-lex.c (interpret_float): Add suffix parm.
7934 (c_lex_with_flags): Build literal tokens.
7936 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
7940 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
7943 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7944 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7945 Wnarrowing for C++0x and C++98.
7946 * c.opt ([Wnarrowing]): Update.
7948 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
7951 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7952 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7953 Wnarrowing for C++0x and C++98.
7954 * c.opt ([Wnarrowing]): Update.
7956 2011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
7959 * c-common.c (conversion_warning): Remove code looking for
7960 artificial operands.
7962 2011-10-18 Dodji Seketeli <dodji@redhat.com>
7965 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
7966 !NO_IMPLICIT_EXTERN_C.
7968 2011-10-17 Michael Spertus <mike_spertus@symantec.com>
7970 * c-common.c (c_common_reswords): Add __bases,
7972 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
7974 2011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
7977 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
7979 2011-10-15 Tom Tromey <tromey@redhat.com>
7980 Dodji Seketeli <dodji@redhat.com>
7982 * c.opt (fdebug-cpp): New option.
7983 * c-opts.c (c_common_handle_option): Handle the option.
7984 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
7985 output stream in parameter. Factorized from ...
7986 (maybe_print_line): ... this. Dump location debug information when
7987 -fdebug-cpp is in effect.
7988 (print_line_1): New static function. Takes an output stream in
7989 parameter. Factorized from ...
7990 (print_line): ... here. Dump location information when -fdebug-cpp
7992 (scan_translation_unit): Dump location information when
7993 -fdebug-cpp is in effect.
7995 2011-10-15 Tom Tromey <tromey@redhat.com>
7996 Dodji Seketeli <dodji@redhat.com>
7998 * c.opt (ftrack-macro-expansion): New option. Handle it with and
8000 * c-opts.c (c_common_handle_option)<case
8001 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
8002 cases. Handle -ftrack-macro-expansion with and without argument.
8004 2011-10-15 Tom Tromey <tromey@redhat.com>
8005 Dodji Seketeli <dodji@redhat.com>
8007 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
8008 (print_line, cb_define, do_line_change): Adjust to avoid touching
8009 the internals of struct line_map. Use the public API instead.
8010 * c-pch.c (c_common_read_pch): Likewise.
8011 * c-lex.c (fe_file_change): Likewise.
8013 2011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
8016 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
8018 2011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
8021 * c-pretty-print.c (pp_c_floating_constant): Output
8022 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
8024 2011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
8026 * c-common.c (def_builtin_1): Delete old interface with two
8027 parallel arrays to hold standard builtin declarations, and replace
8028 it with a function based interface that can support creating
8029 builtins on the fly in the future. Change all uses, and poison
8030 the old names. Make sure 0 is not a legitimate builtin index.
8031 * c-omp.c (c_finish_omp_barrier): Ditto.
8032 (c_finish_omp_taskwait): Ditto.
8033 (c_finish_omp_flush): Ditto.
8035 2011-10-11 Tristan Gingold <gingold@adacore.com>
8037 * c.opt: (fallow-parameterless-variadic-functions): New.
8039 2011-09-08 Dodji Seketeli <dodji@redhat.com>
8041 PR c++/33255 - Support -Wunused-local-typedefs warning
8042 * c-common.h (struct c_language_function::local_typedefs): New
8044 (record_locally_defined_typedef, maybe_record_typedef_use)
8045 (maybe_warn_unused_local_typedefs): Declare new functions.
8046 * c-common.c (record_locally_defined_typedef)
8047 (maybe_record_typedef_use)
8048 (maybe_warn_unused_local_typedefs): Define new functions.
8049 * c.opt: Declare new -Wunused-local-typedefs flag.
8051 2011-09-06 Eric Botcazou <ebotcazou@adacore.com>
8054 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
8057 2011-09-05 Richard Guenther <rguenther@suse.de>
8059 * c-common.c (complete_array_type): Use ssize_int (-1) instead
8060 of integer_minus_one_node for empty array upper bounds.
8062 2011-08-28 Dodji Seketeli <dodji@redhat.com>
8064 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
8065 it's the first time it's being called on this main TU.
8067 2011-08-24 Richard Guenther <rguenther@suse.de>
8070 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
8072 2011-08-22 Gabriel Charette <gchare@google.com>
8074 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
8075 defined in cpp_init_builtins and c_cpp_builtins.
8077 2011-08-19 Joseph Myers <joseph@codesourcery.com>
8079 * c-common.c (c_common_reswords): Add __builtin_complex.
8080 * c-common.h (RID_BUILTIN_COMPLEX): New.
8082 2011-08-18 Joseph Myers <joseph@codesourcery.com>
8084 * c-common.c (c_common_reswords): Add _Noreturn.
8085 (keyword_is_function_specifier): Handle RID_NORETURN.
8086 * c-common.h (RID_NORETURN): New.
8088 2011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
8090 * c-common.c (unsafe_conversion_p): New function. Check if it is
8091 unsafe to convert an expression to the type.
8092 (conversion_warning): Adjust, use unsafe_conversion_p.
8093 * c-common.h (unsafe_conversion_p): New function declaration.
8095 2011-08-02 Jakub Jelinek <jakub@redhat.com>
8097 * c-common.h (c_finish_omp_atomic): Adjust prototype.
8098 (c_finish_omp_taskyield): New prototype.
8099 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
8100 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
8101 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
8102 or RHS1 have side-effects, evaluate those too in the right spot,
8103 if it is a decl and LHS is also a decl, error out if they
8105 (c_finish_omp_taskyield): New function.
8106 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
8107 * c-pragma.c (omp_pragmas): Add taskyield.
8108 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
8109 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
8110 PRAGMA_OMP_CLAUSE_MERGEABLE.
8112 2011-07-25 Dodji Seketeli <dodji@redhat.com>
8114 * c-common.h (set_underlying_type): Remove parm name from
8117 2011-07-25 Romain Geissler <romain.geissler@gmail.com>
8119 * c-pretty-print.h: Search c-common.h in c-family.
8121 2011-07-22 Jason Merrill <jason@redhat.com>
8124 * c.opt (Wnarrowing): New.
8127 * c-common.h: Declare c_linkage_bindings.
8128 * c-pragma.c (handle_pragma_redefine_extname): Use it.
8131 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
8132 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
8133 as flag_isoc99 for 'restrict'.
8134 (pp_c_specifier_qualifier_list): Likewise for _Complex.
8136 2011-07-21 Ian Lance Taylor <iant@google.com>
8139 * c-common.c (c_disable_warnings): New static function.
8140 (c_enable_warnings): New static function.
8141 (c_fully_fold_internal): Change local unused_p to bool. Call
8142 c_disable_warnings and c_enable_warnings rather than change
8143 c_inhibit_evaluation_warnings.
8145 2011-07-20 Jason Merrill <jason@redhat.com>
8147 PR c++/6709 (DR 743)
8148 PR c++/42603 (DR 950)
8149 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
8150 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
8151 (CPP_DECLTYPE): New.
8152 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
8154 2011-07-19 Richard Guenther <rguenther@suse.de>
8156 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
8157 * c-omp.c (c_finish_omp_for): Likewise.
8159 2011-07-12 Eric Botcazou <ebotcazou@adacore.com>
8161 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
8162 body on the next line.
8164 2011-07-08 Jason Merrill <jason@redhat.com>
8167 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
8170 * c-common.c (c_apply_type_quals_to_decl): Don't check
8171 TYPE_NEEDS_CONSTRUCTING.
8173 2011-07-06 Richard Guenther <rguenther@suse.de>
8175 * c-common.c (c_common_nodes_and_builtins):
8176 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
8178 2011-07-05 Richard Guenther <rguenther@suse.de>
8180 * c-common.c (c_common_nodes_and_builtins): Build all common
8183 2011-06-27 Jakub Jelinek <jakub@redhat.com>
8185 * c-common.h (c_tree_chain_next): New static inline function.
8187 * c-common.c (check_builtin_function_arguments): Handle
8188 BUILT_IN_ASSUME_ALIGNED.
8190 2011-06-21 Andrew MacLeod <amacleod@redhat.com>
8192 * c-common.c: Add sync_ or SYNC__ to builtin names.
8193 * c-omp.c: Add sync_ or SYNC__ to builtin names.
8195 2011-06-20 Pierre Vittet <piervit@pvittet.com>
8197 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
8199 (gen_pragma_handler): New union.
8200 (internal_pragma_handler): New type.
8201 (c_register_pragma_with_data)
8202 (c_register_pragma_with_expansion_and_data): New functions.
8204 * c-pragma.c (registered_pragmas, c_register_pragma_1)
8205 (c_register_pragma, c_register_pragma_with_expansion)
8206 (c_invoke_pragma_handler): Changed to work with
8207 internal_pragma_handler.
8208 (c_register_pragma_with_data)
8209 (c_register_pragma_with_expansion_and_data): New functions.
8211 2011-06-14 Joseph Myers <joseph@codesourcery.com>
8213 * c-common.c: Include common/common-target.h.
8214 (handle_section_attribute): Use
8215 targetm_common.have_named_sections.
8216 * c-cppbuiltin.c: Include common/common-target.h.
8217 (c_cpp_builtins): Use targetm_common.except_unwind_info.
8219 2011-06-10 Richard Guenther <rguenther@suse.de>
8221 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
8222 to print a IDENTIFIER_NODE.
8224 2011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8225 Joseph Myers <joseph@codesourcery.com>
8227 * c.opt (fbuilding-libgcc): New option.
8228 * c-cppbuiltin.c (c_cpp_builtins): Define
8229 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
8231 2011-06-07 Jason Merrill <jason@redhat.com>
8233 * c-common.c (max_tinst_depth): Lower default to 900.
8235 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
8237 2011-06-07 Richard Guenther <rguenther@suse.de>
8239 * c-common.c (c_common_nodes_and_builtins): Do not set
8240 size_type_node or call set_sizetype.
8242 2011-06-07 Dodji Seketeli <dodji@redhat.com>
8245 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
8246 type when using pointer comparison to compare types.
8248 2011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
8250 * c.opt: Add -Wdelete-non-virtual-dtor.
8251 * c-opts.c (c_common_handle_option): Include it in -Wall.
8253 2011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
8258 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
8260 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
8263 2011-05-27 Jakub Jelinek <jakub@redhat.com>
8266 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
8267 C++ don't call c_common_truthvalue_conversion on void type arms.
8269 2011-05-27 Nathan Froyd <froydnj@codesourcery.com>
8271 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
8272 (stmt_list_stack): Define.
8273 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
8274 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
8276 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
8278 * c-common.c (warning_candidate_p): Check for BLOCKs.
8280 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
8282 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
8285 2011-05-25 Jakub Jelinek <jakub@redhat.com>
8287 * c-common.c (def_fn_type): Remove extra va_end.
8289 2011-05-23 Jason Merrill <jason@redhat.com>
8292 * c-common.c (c_common_get_narrower): New.
8293 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
8295 2011-05-23 Nathan Froyd <froydnj@codesourcery.com>
8297 * c-common.h (check_function_arguments): Tweak prototype of
8298 check_function_arguments.
8299 * c-common.c (check_function_arguments): Likewise. Adjust
8300 calls to check_function_nonnull, check_function_format, and
8301 check_function_sentinel.
8302 (check_function_sentinel): Take a FUNCTION_TYPE rather than
8303 separate attributes and typelist arguments. Use
8304 FOREACH_FUNCTION_ARGS to iterate over argument types.
8306 2011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
8308 * c-common.c (c_common_reswords): Reorder.
8309 * c-common.h (rid): Likewise.
8311 2011-05-10 Nathan Froyd <froydnj@codesourcery.com>
8313 * c-common.c (def_fn_type): Don't call build_function_type, call
8314 build_function_type_array or build_varargs_function_type_array
8316 (c_common_nodes_and_builtins): Likewise.
8318 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
8320 * c-common.c (c_add_case_label): Omit the loc argument to
8322 * c-common.h (build_case_label): Remove.
8323 * c-semantics.c (build_case_label): Remove.
8325 2011-05-05 Joseph Myers <joseph@codesourcery.com>
8327 * c-objc.h (objc_start_method_definition): Update prototype.
8328 * stub-objc.c (objc_start_method_definition): Add extra parameter.
8330 2011-05-04 Nathan Froyd <froydnj@codesourcery.com>
8332 * c-common.c (check_main_parameter_types): Reindent. Don't use
8333 TYPE_ARG_TYPES directly.
8334 (handle_nonnull_attribute): Likewise.
8335 (sync_resolve_params): Likewise.
8336 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
8337 to check_format_string.
8338 (handle_format_attribute): Likewise.
8339 (check_format_string): Take a function type to examine instead of
8340 a type list. Use a function_arg_iterator to step through argument
8343 2011-05-04 Richard Guenther <rguenther@suse.de>
8345 * c-common.c (fix_string_type): Use size_int for index type bounds.
8346 (start_fname_decls): Do not pass NULL to build_int_cst.
8347 (c_init_attributes): Likewise.
8348 * c-lex.c (c_lex_with_flags): Likewise.
8350 2011-04-27 Jason Merrill <jason@redhat.com>
8352 * c-common.c (make_tree_vector_from_list): New.
8353 * c-common.h: Declare it.
8355 2011-04-26 Richard Guenther <rguenther@suse.de>
8357 PR preprocessor/48248
8358 * c-ppoutput.c (maybe_print_line): Always optimize newlines
8359 for output size with -P.
8361 2011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
8363 * c-common.c (struct c_common_resword): Add __underlying_type.
8364 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
8366 2011-04-20 Jim Meyering <meyering@redhat.com>
8368 * c-format.c (init_dollar_format_checking): Remove useless
8371 2011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
8373 * c-objc.h (objc_get_interface_ivars): Removed.
8374 (objc_detect_field_duplicates): New.
8375 * stub-objc.c: Likewise.
8377 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
8379 * stub-objc.c (objc_declare_protocols): Renamed to
8380 objc_declare_protocol.
8381 * c-objc.h: Likewise.
8383 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
8385 * stub-objc.c (objc_declare_class): Updated argument name.
8387 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
8389 * c-common.h (c_common_init_ts): Declare.
8390 * c-common.c (c_common_init_ts): Define.
8392 2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
8394 * c-objc.h (objc_build_message_expr): Updated prototype.
8395 * stub-objc.c (objc_build_message_expr): Likewise.
8397 2011-04-12 Martin Jambor <mjambor@suse.cz>
8399 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
8402 2011-04-11 Richard Guenther <rguenther@suse.de>
8404 * c-common.c (complete_array_type): Build a range type of
8407 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
8409 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
8410 (handle_type_generic_attribute): Likewise.
8412 2011-04-07 Jason Merrill <jason@redhat.com>
8415 * c-common.c (c_common_truthvalue_conversion): Don't ignore
8416 conversion from C++0x scoped enum.
8418 2011-04-06 Joseph Myers <joseph@codesourcery.com>
8420 * c-target-def.h: New file.
8421 * c-target.def: New file.
8422 * c-target.h: New file.
8423 * c-common.c (targetcm): Don't define here.
8424 * c-common.h (default_handle_c_option): Declare.
8425 * c-format.c: Include c-target.h instead of target.h.
8426 * c-opts.c: Include c-target.h instead of target.h. Explicitly
8428 (default_handle_c_option): Move from targhooks.c.
8430 2011-03-29 Jakub Jelinek <jakub@redhat.com>
8432 PR preprocessor/48248
8433 * c-ppoutput.c (print): Add src_file field.
8434 (init_pp_output): Initialize it.
8435 (maybe_print_line): Don't optimize by adding up to 8 newlines
8436 if map->to_file and print.src_file are different file.
8437 (print_line): Update print.src_file.
8439 2011-03-25 Kai Tietz <ktietz@redhat.com>
8441 * c-ada-spec.c (compare_comment): Use filename_cmp
8442 instead of strcmp for filename.
8444 2011-03-25 Jeff Law <law@redhat.com>
8446 * c-common.c (def_fn_type): Add missing va_end.
8448 2011-03-25 Jason Merrill <jason@redhat.com>
8450 * c.opt: Add -std=c++03.
8452 2011-03-22 Eric Botcazou <ebotcazou@adacore.com>
8454 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
8456 2011-03-17 Kai Tietz <ktietz@redhat.com>
8459 * c-pretty-print.c (pp_c_specifier_qualifier_list):
8460 Display allowed attributes for function pointer types.
8461 (pp_c_attributes_display): New function to display
8462 attributes having affects_type_identity flag set to true.
8463 * c-pretty-print.h (pp_c_attributes_display): New prototype.
8465 * c-common.c (c_common_attribute_table):
8467 (c_common_format_attribute_table): Likewise.
8469 2011-03-18 Jason Merrill <jason@redhat.com>
8471 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
8472 * c-common.h: Don't declare it here.
8473 * c-common.c: Or define it here.
8474 * c-opts.c (c_common_handle_option): Or set it here.
8477 * c-common.c (handle_transparent_union_attribute): Don't
8478 make a duplicate type in C++.
8480 2011-03-15 Jason Merrill <jason@redhat.com>
8482 * c-common.c (max_constexpr_depth): New.
8483 * c-common.h: Declare it.
8484 * c-opts.c (c_common_handle_option): Set it.
8485 * c.opt (fconstexpr-depth): New option.
8487 2011-03-11 Jason Merrill <jason@redhat.com>
8489 * c-common.c (attribute_takes_identifier_p): Add missing const.
8492 * c-common.c (attribute_takes_identifier_p): Assume that an
8493 unknown attribute takes an identifier.
8495 2011-03-07 Nathan Froyd <froydnj@codesourcery.com>
8498 * c-common.c (c_type_hash): Call list_length instead of iterating
8499 through DECL_CHAIN. Rename 'i' to 'n_elements'.
8501 2011-02-19 Jakub Jelinek <jakub@redhat.com>
8504 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
8506 2011-02-17 Iain Sandoe <iains@gcc.gnu.org>
8508 * c.opt (fobjc-abi-version=) New.
8509 (fobjc-nilcheck): New.
8511 2011-02-03 Nathan Froyd <froydnj@codesourcery.com>
8514 * c-common.h (keyword_is_decl_specifier): Declare.
8515 * c-common.c (keyword_is_decl_specifier): Define.
8516 (keyword_is_function_specifier): New function.
8518 2011-01-26 Jakub Jelinek <jakub@redhat.com>
8521 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
8522 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
8525 2011-01-26 Arnaud Charlet <charlet@adacore.com>
8527 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
8529 2011-01-26 Jakub Jelinek <jakub@redhat.com>
8532 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
8533 after init_c_lex if pch_file is set.
8535 2011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
8538 * c.opt (-fkeep-inline-dllexport): New switch.
8540 2011-01-12 Richard Guenther <rguenther@suse.de>
8543 * c-common.c (handle_weak_attribute): Warn instead of error
8544 on declaring an inline function weak.
8546 2011-01-05 Tom Tromey <tromey@redhat.com>
8548 * c-common.h (lvalue_error): Update.
8549 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
8552 2010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
8555 * c-objc.h (objc_finish_message_expr): Added argument to
8558 2010-12-22 Nathan Froyd <froydnj@codesourcery.com>
8560 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
8563 2010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
8565 * c-objc.h (objc_maybe_warn_exceptions): New.
8566 * stub-objc.c (objc_maybe_warn_exceptions): New.
8568 2010-12-10 Nathan Froyd <froydnj@codesourcery.com>
8570 * c-common.h (readonly_error): Declare.
8571 * c-common.c (readonly_error): Define.
8573 2010-12-09 Nathan Froyd <froydnj@codesourcery.com>
8575 * c-common.h (invalid_indirection_error): Declare.
8576 * c-common.c (invalid_indirection_error): Define.
8578 2010-12-03 Richard Guenther <rguenther@suse.de>
8581 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
8582 (pp_c_unary_expression): Likewise.
8583 (pp_c_expression): Likewise.
8585 2010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
8587 * c-common.h (objc_finish_function): New.
8588 (objc_non_volatilized_type): Removed.
8589 (objc_type_quals_match): Removed.
8590 * stub-objc.c (objc_finish_function): New.
8591 (objc_non_volatilized_type): Removed.
8592 (objc_type_quals_match): Removed.
8594 2010-11-30 Joseph Myers <joseph@codesourcery.com>
8596 * c-common.h (parse_optimize_options): Declare.
8597 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
8598 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
8600 2010-11-29 Joseph Myers <joseph@codesourcery.com>
8602 * c-opts.c (check_deps_environment_vars): Use getenv instead of
8604 * c-pch.c (O_BINARY): Don't define here.
8605 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
8607 2010-11-25 Joseph Myers <joseph@codesourcery.com>
8609 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
8610 targetm.except_unwind_info.
8612 2010-11-23 Joseph Myers <joseph@codesourcery.com>
8614 * c-opts.c (c_common_handle_option): Pass location to
8615 set_struct_debug_option.
8617 2010-11-23 Joseph Myers <joseph@codesourcery.com>
8619 * c-common.c (visibility_options): Move from ../opts.c.
8620 * c-common.h (struct visibility_flags, visibility_options):
8622 * c-opts.c (finish_options): Rename to c_finish_options.
8623 (c_common_init): Update call to finish_options.
8625 2010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
8628 * c-lex.c (lex_string): Check that each string in an Objective-C
8629 string concat sequence starts with either one or zero '@', and
8630 that there are no spurious '@' signs at the end.
8632 2010-11-20 Joseph Myers <joseph@codesourcery.com>
8634 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
8635 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
8636 HANDLE_PRAGMA_VISIBILITY.
8637 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
8638 HANDLE_PRAGMA_VISIBILITY): Don't define.
8639 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
8641 2010-11-20 Nathan Froyd <froydnj@codesourcery.com>
8646 * c-common.h (keyword_begins_type_specifier): Declare.
8647 (keyword_is_storage_class_specifier): Declare.
8648 (keyword_is_type_qualifier): Declare.
8649 * c-common.c (keyword_begins_type_specifier): New function.
8650 (keyword_is_storage_class_specifier): New function.
8651 (keyword_is_type_qualifier): Declare.
8653 2010-11-19 Joseph Myers <joseph@codesourcery.com>
8656 * c-common.c (in_late_binary_op): Define.
8657 (c_common_truthvalue_conversion): Check in_late_binary_op before
8658 calling c_save_expr.
8659 * c-common.h (in_late_binary_op): Declare.
8661 2010-11-19 Joseph Myers <joseph@codesourcery.com>
8663 * c-opts.c (c_common_handle_option): Update calls to
8664 set_struct_debug_option.
8666 2010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
8668 * c-common.h (objc_declare_protocols): Added additional argument.
8669 * stub-objc.c (objc_declare_protocol): Same change.
8671 2010-11-18 Nathan Froyd <froydnj@codesourcery.com>
8674 * c-common.h (build_real_imag_expr): Declare.
8675 * c-semantics.c (build_real_imag_expr): Define.
8677 2010-11-17 Joseph Myers <joseph@codesourcery.com>
8679 * c-opts.c (c_common_parse_file): Take no arguments.
8680 * c-common.h (c_common_parse_file): Update prototype.
8682 2010-11-16 Jakub Jelinek <jakub@redhat.com>
8685 * c-common.c (warning_candidate_p): Don't track non-const calls
8688 2010-11-15 Ian Lance Taylor <iant@google.com>
8690 * c-lex.c (init_c_lex): Set macro debug callbacks if
8691 flag_dump_go_spec is set.
8693 2010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
8695 * c-common.h (objc_build_incr_expr_for_property_ref): New.
8696 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
8698 2010-11-15 Nathan Froyd <froydnj@codesourcery.com>
8700 PR preprocessor/45038
8701 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
8704 2010-11-12 Joseph Myers <joseph@codesourcery.com>
8706 * c-common.h (c_family_lang_mask): Declare.
8707 * c-opts.c (c_family_lang_mask): Make extern.
8708 * c-pragma.c (handle_pragma_diagnostic): Use
8709 control_warning_option.
8711 2010-11-12 Joseph Myers <joseph@codesourcery.com>
8713 * c-common.c (parse_optimize_options): Update call to
8715 * c-common.h (c_common_handle_option): Update prototype.
8716 * c-opts.c (c_common_handle_option): Take location_t parameter and
8717 pass it to other functions.
8719 2010-11-11 Joseph Myers <joseph@codesourcery.com>
8721 * c-opts.c (warning_as_error_callback): Remove.
8722 (c_common_initialize_diagnostics): Don't call
8723 register_warning_as_error_callback.
8724 (c_common_handle_option): Handle -Werror=normalized= here.
8726 2010-11-10 Joseph Myers <joseph@codesourcery.com>
8728 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
8730 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
8732 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
8733 Remove trailing '.' from diagnostics.
8734 * c.opt (Wwrite-strings_: Avoid '`' in help text.
8736 2010-11-10 Joseph Myers <joseph@codesourcery.com>
8738 * c-common.c (parse_optimize_options): Pass global_dc to
8740 * c-opts.c (c_common_handle_option): Pass &global_options to
8741 set_Wstrict_aliasing.
8742 * c.opt (v): Don't mark Common or document here.
8744 2010-11-06 Iain Sandoe <iains@gcc.gnu.org>
8747 * c-format.c (format_type): New type gcc_objc_string_format_type.
8748 (valid_stringptr_type_p): New.
8749 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
8750 (check_format_string): Pass expected type, use
8751 valid_stringptr_type_p (), check that the format string types are
8752 consistent with the format specification.
8753 (decode_format_attr): Warn if NSString is used outside objective-c.
8754 (format_types_orig): Add NSString.
8756 (format_flags): New.
8757 (check_format_arg): Handle format strings requiring an external parser.
8758 first_target_format_type: New variable.
8759 (handle_format_attribute): Set up first_target_format_type, pass the
8760 expected format arg string type to check_format_string().
8761 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
8762 * stub-objc.c (objc_string_ref_type_p): New.
8763 (objc_check_format_arg): New.
8765 2010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
8767 Fixed using the Objective-C 2.0 dot-syntax with class names.
8768 * c-common.h (objc_build_class_component_ref): New.
8769 * stub-objc.c (objc_build_class_component_ref): New.
8771 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
8773 * c.opt (Wproperty-assign-default): New option.
8775 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
8777 Implemented -fobjc-std=objc1 flag.
8778 * c.opt (fobjc-std=objc1): New option.
8780 2010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
8782 Implemented format and noreturn attributes for Objective-C methods.
8783 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
8784 attribute for Objective-C methods.
8786 2010-10-31 Jason Merrill <jason@redhat.com>
8788 * c-common.c (conversion_warning, warn_for_collisions_1): Use
8791 2010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
8793 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
8794 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
8795 (objc_add_property_declaration): Removed arguments for copies and
8797 (objc_build_getter_call): Renamed to
8798 objc_maybe_build_component_ref.
8799 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
8800 (objc_is_property_ref): New.
8801 * c-common.c (c_common_reswords): Removed copies and ivar.
8802 * stub-objc.c (objc_add_property_declaration): Removed arguments
8803 for copies and ivar.
8804 (objc_build_getter_call): Renamed to
8805 objc_maybe_build_component_ref.
8806 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
8807 (objc_is_property_ref): New.
8809 2010-10-29 Arnaud Charlet <charlet@adacore.com>
8810 Matthew Gingell <gingell@adacore.com>
8812 * c-ada-spec.c (separate_class_package): New function.
8813 (pp_ada_tree_identifier): Prefix references to C++ classes with the
8814 name of their enclosing package.
8815 (print_ada_declaration): Use separate_class_package.
8817 2010-10-27 Jason Merrill <jason@redhat.com>
8819 * c-common.c (c_common_reswords): Add __is_literal_type.
8820 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
8822 * c-common.c (check_case_value): Remove special C++ code.
8824 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
8826 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
8827 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
8829 (objc_add_property_declaration): Added additional arguments.
8830 (objc_property_attribute_kind): Removed.
8831 (objc_set_property_attr): Removed.
8832 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
8834 * stub-objc.c (objc_add_property_declaration): Added additional
8836 (objc_set_property_attr): Removed.
8838 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
8840 * c-common.h (objc_add_property_variable): Renamed to
8841 objc_add_property_declaration. Added location argument.
8842 * stub-objc.c (objc_add_property_variable): Same change.
8844 2010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
8846 * c-common.h (objc_maybe_printable_name): New.
8847 * stub-objc.c (objc_maybe_printable_name): New.
8849 2010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
8850 Andrew Pinski <pinskia@gmail.com>
8852 * c-common.h (c_common_mark_addressable_vec): Declare.
8853 * c-common.c (c_common_mark_addressable_vec): New function.
8855 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
8857 * c-common.h (objc_set_method_type): Removed.
8858 (objc_add_method_declaration): Added boolean argument.
8859 (objc_start_method_definition): Same change.
8860 (objc_build_method_signature): Same change.
8861 * stub-objc.c (objc_set_method_type): Removed.
8862 (objc_add_method_declaration): Added boolean argument.
8863 (objc_start_method_definition): Same change.
8864 (objc_build_method_signature): Same change.
8866 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
8868 * c-common.h (finish_file): Removed.
8869 (objc_write_global_declarations): New.
8870 * c-opts.c (c_common_parse_file): Do not call finish_file.
8871 * stub-objc.c (objc_write_global_declarations): New.
8873 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
8875 Implemented parsing @synthesize and @dynamic for
8876 Objective-C/Objective-C++.
8877 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
8878 (objc_add_synthesize_declaration): New.
8879 (objc_add_dynamic_declaration): New.
8880 * c-common.c (c_common_reswords): Add synthesize and dynamic.
8881 * stub-objc.c (objc_add_synthesize_declaration): New.
8882 (objc_add_dynamic_declaration): New.
8884 2010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
8887 * c-cppbuiltin.c (mode_has_fma): Move function here from
8888 builtins.c. Don't use the fma optab, instead just use the
8889 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
8892 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
8894 Merge from 'apple/trunk' branch on FSF servers.
8896 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
8899 * c-common.h (objc_non_volatilized_type): New declaration
8900 * stub-objc.c (objc_non_volatilized_type): New stub.
8902 2010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
8904 Merge from 'apple/trunk' branch on FSF servers.
8906 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
8909 * c-common.h (objc_diagnose_private_ivar): New decl.
8910 * stub-objc.c (objc_diagnose_private_ivar): New stub.
8912 2010-10-17 Iain Sandoe <iains@gcc.gnu.org>
8914 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
8915 * c-common.h (enum rid): Add RID_AT_PACKAGE.
8916 (objc_ivar_visibility_kind): New enum.
8917 (objc_set_visibility): Adjust prototype to use visibility enum.
8918 * stub-objc.c (objc_set_visibility): Adjust stub to use
8921 2010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
8923 * c-cppbuiltin.c (builtin_define_float_constants): Emit
8924 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
8925 has the appropriate fma builtins.
8926 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
8928 2010-10-14 Iain Sandoe <iains@gcc.gnu.org>
8930 merge from FSF apple 'trunk' branch.
8931 2006 Fariborz Jahanian <fjahanian@apple.com>
8933 Radars 4436866, 4505126, 4506903, 4517826
8934 * c-common.c (c_common_resword): Define @property and its attributes.
8935 * c-common.h: Define property attribute enum entries.
8936 (OBJC_IS_PATTR_KEYWORD): New.
8937 (objc_property_attribute_kind): New enum.
8938 Declare objc_set_property_attr (), objc_add_property_variable (),
8939 objc_build_getter_call () and objc_build_setter_call ().
8940 * stub-objc.c (objc_set_property_attr): New stub.
8941 (objc_add_property_variable): Likewise.
8942 (objc_build_getter_call): Likewise.
8943 (objc_build_setter_call) Likewise.
8945 2010-10-13 Iain Sandoe <iains@gcc.gnu.org>
8947 merge from FSF apple 'trunk' branch.
8948 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
8950 Radar 3803157 (method attributes)
8951 * c-common.c (handle_deprecated_attribute): Recognize
8952 objc methods as valid declarations.
8953 * c-common.h: Declare objc_method_decl ().
8954 * stub-objc.c (objc_method_decl): New stub.
8956 2010-10-08 Joseph Myers <joseph@codesourcery.com>
8958 * c-common.c (parse_optimize_options): Call
8959 decode_cmdline_options_to_array_default_mask before
8960 decode_options. Update arguments to decode_options.
8961 * c-common.h (c_common_init_options_struct): Declare.
8962 * c-opts.c (c_common_init_options_struct): New. Split out from
8963 c_common_init_options.
8965 2010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
8967 Implemented fast enumeration for Objective-C.
8968 * c-common.h (objc_finish_foreach_loop): New.
8969 * stub-objc.c (objc_finish_foreach_loop): New.
8971 2010-10-05 Joseph Myers <joseph@codesourcery.com>
8973 * c-common.h (struct diagnostic_context): Don't declare here.
8974 (c_common_initialize_diagnostics): Declare using
8975 diagnostic_context typedef.
8976 * c-opts.c (c_common_handle_option): Pass global_dc to
8977 handle_generated_option.
8979 2010-10-04 Joseph Myers <joseph@codesourcery.com>
8981 * c-opts.c (c_common_handle_option): Pass &global_options_set to
8982 handle_generated_option.
8984 2010-10-03 Ian Lance Taylor <iant@google.com>
8986 * c.opt (-fplan9-extensions): New option.
8988 2010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
8990 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
8992 (c_cpp_builtins): Call functions from cppbuiltin.c instead
8993 of duplicating code.
8995 2010-09-30 Iain Sandoe <iains@gcc.gnu.org>
8997 * c-common.c: Add two new entries for @optional
8998 and @required keywords.
9000 merge from FSF 'apple/trunk' branch.
9001 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
9004 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
9005 objective-c keywords.
9006 (objc_set_method_opt): New declaration.
9007 * stub-objc.c (objc_set_method_opt): New stub.
9009 2010-09-30 Joseph Myers <joseph@codesourcery.com>
9011 * c-common.c (handle_optimize_attribute): Pass &global_options to
9012 cl_optimization_save and cl_optimization_restore.
9013 * c-opts.c (c_common_handle_option): Pass &global_options to
9014 handle_generated_option.
9015 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
9016 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
9017 &global_options to cl_optimization_restore.
9019 2010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
9021 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
9022 Objective-C/Objective-C++ keywords.
9024 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
9026 Merge from 'apple/trunk' branch on FSF servers.
9028 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
9031 * c-common.h (objc_check_global_decl): New declaration.
9032 * stub-objc.c (objc_check_global_decl): New stub.
9034 2010-09-29 Joseph Myers <joseph@codesourcery.com>
9036 * c.opt: Don't use VarExists.
9038 2010-09-29 Joseph Myers <joseph@codesourcery.com>
9040 * c-common.c (c_cpp_error): Update names of diagnostic_context
9042 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
9043 cl_optimization members.
9044 * c-opts.c (warning_as_error_callback, c_common_handle_option,
9045 sanitize_cpp_opts, finish_options): Update names of cpp_options
9048 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
9050 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
9051 (objc_is_reserved_word): Removed.
9052 * c-common.c: Updated comments.
9053 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
9054 objc_is_reserved_word.
9055 * stub-objc.c (objc_is_reserved_word): Removed.
9057 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
9059 * c-common.h (objc_add_method_declaration): Adjust prototype to
9061 (objc_start_method_definition): Likewise.
9062 (objc_build_keyword_decl): Likewise.
9063 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
9064 (objc_start_method_definition): Likewise.
9065 (objc_build_keyword_decl): Likewise.
9067 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
9069 * c-common.h (objc_start_class_interface): Adjust prototype.
9070 (objc_start_category_interface): Likewise.
9071 (objc_start_protocol): Likewise.
9072 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
9073 (objc_start_class_interface): Likewise.
9074 (objc_start_category_interface): Likewise.
9076 2010-09-27 Ian Lance Taylor <iant@google.com>
9078 * c-common.c (c_common_attribute_table): Add no_split_stack.
9079 (handle_no_split_stack_attribute): New static function.
9081 2010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
9083 Merge from 'apple/trunk' branch on FSF servers.
9085 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
9088 * c-common.h (objc_have_common_type): New declaration.
9089 * stub-objc.c (objc_have_common_type): New stub.
9091 2005-06-22 Ziemowit Laski <zlaski@apple.com>
9094 * c-common.h (objc_common_type): New prototype.
9095 * stub-objc.c (objc_common_type): New stub.
9097 2010-09-24 Jan Hubicka <jh@suse.cz>
9099 * c-common.c (handle_leaf_attribute): New function.
9100 (struct attribute_spec c_common_att): Add leaf.
9102 2010-09-22 Joseph Myers <joseph@codesourcery.com>
9104 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
9105 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
9106 -dump, -dump=, -imacros, -imacros=, -include, -include=,
9107 -include-barrier, -include-directory, -include-directory=,
9108 -include-directory-after, -include-directory-after=,
9109 -include-prefix, -include-prefix=, -include-with-prefix,
9110 -include-with-prefix=, -include-with-prefix-after,
9111 -include-with-prefix-after=, -include-with-prefix-before,
9112 -include-with-prefix-before=, -no-integrated-cpp,
9113 -no-line-commands, -no-standard-includes, -no-warnings, -output,
9114 -output=, -pedantic, -pedantic-errors, -preprocess,
9115 -print-missing-file-dependencies, -trace-includes, -traditional,
9116 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
9117 -user-dependencies, -verbose, -write-dependencies,
9118 -write-user-dependencies, no-integrated-cpp, traditional): New.
9120 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
9123 * c-common.h (objc_start_method_definition): Return bool instead
9125 * stub-objc.c (objc_start_method_definition): Return bool instead
9128 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
9131 * c-common.h (objc_get_interface_ivars): New declaration.
9132 * stub-objc.c (objc_get_interface_ivars): New stub.
9134 2010-09-15 Ian Lance Taylor <iant@google.com>
9136 * c-common.c (parse_optimize_options): Do not capitalize warning
9137 messages. Remove period at end of warning message.
9139 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
9141 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
9142 (handle_alias_attribute): ... here.
9143 (handle_ifunc_attribute): New.
9145 2010-09-06 Mark Mitchell <mark@codesourcery.com>
9147 * c-common.h (do_warn_double_promotion): Declare.
9148 * c-common.c (do_warn_double_promotion): Define.
9150 2010-09-05 Mark Mitchell <mark@codesourcery.com>
9152 * c.opt (Wdouble-promotion): New.
9154 2010-09-02 Joseph Myers <joseph@codesourcery.com>
9156 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
9157 fvtable-thunks, fxref): Mark no longer supported in help text.
9159 2010-09-02 Joseph Myers <joseph@codesourcery.com>
9161 * c.opt (Wimport, fall-virtual, falt-external-templates,
9162 fdefault-inline, fenum-int-equiv, fexternal-templates,
9163 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
9164 fname-mangling-version-, fnew-abi, fnonnull-objects,
9165 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
9166 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
9168 (fhandle-exceptions): Mark with Alias and Warn.
9169 * c-opts.c (c_common_handle_option): Don't handle options marked
9172 2010-09-02 Joseph Myers <joseph@codesourcery.com>
9174 * c.opt (Wcomments, Werror-implicit-function-declaration,
9175 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
9176 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
9178 * c-common.c (option_codes): Use OPT_Wcomment instead of
9180 * c-opts.c (warning_as_error_callback, c_common_handle_option):
9181 Don't handle options marked as aliases.
9183 2010-08-25 Richard Guenther <rguenther@suse.de>
9185 * c-common.c (c_common_get_alias_set): Remove special
9186 handling for pointers.
9188 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
9190 * c-common.c: Use FOR_EACH_VEC_ELT.
9191 * c-gimplify.c: Likewise.
9192 * c-pragma.c: Likewise.
9194 2010-08-16 Joseph Myers <joseph@codesourcery.com>
9196 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
9198 (MMDX): Change back to MMD. Mark NoDriverArg instead of
9200 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
9201 instead of OPT_MDX and OPT_MMDX.
9203 2010-08-16 Joseph Myers <joseph@codesourcery.com>
9205 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
9207 2010-08-12 Joseph Myers <joseph@codesourcery.com>
9209 * c.opt (MD, MMD): Change to MDX and MMDX.
9210 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
9212 2010-08-11 Joseph Myers <joseph@codesourcery.com>
9214 * c-opts.c (c_common_handle_option): Call handle_generated_option
9215 instead of handle_option.
9217 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
9219 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
9220 (maybe_apply_renaming_pragma): Delete unneeded declarations.
9222 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
9224 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
9225 (pending_redefine_extname): Change type to a VEC.
9226 (add_to_renaming_pragma_list): Update for new type of
9227 pending_redefine_extname.
9228 (maybe_apply_renaming_pragma): Likewise.
9230 2010-08-04 Arnaud Charlet <charlet@adacore.com>
9232 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
9234 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
9235 decide whether a type has already been declared/seen.
9236 Do not go to the original type.
9237 (dump_nested_types): New parameter forward.
9238 Generate forward declaration if needed and mark type as visited.
9239 (print_ada_declaration): Call dump_nested_types if not already done.
9240 Mark types as visited.
9242 2010-08-03 Joseph Myers <joseph@codesourcery.com>
9244 * c.opt (-print-pch-checksum): Remove option.
9245 * c-opts.c (c_common_handle_option): Don't handle
9246 OPT_print_pch_checksum.
9248 2010-07-27 Joseph Myers <joseph@codesourcery.com>
9250 * c-common.h (c_common_handle_option): Update prototype and return
9252 * c-opts.c (c_common_handle_option): Update prototype and return
9253 value type. Update calls to handle_option and
9254 enable_warning_as_error.
9256 2010-07-27 Jakub Jelinek <jakub@redhat.com>
9259 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
9261 2010-07-27 Joseph Myers <joseph@codesourcery.com>
9263 * c-common.h (c_common_missing_argument): Remove.
9264 * c-opts.c (c_common_missing_argument): Remove.
9265 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
9266 idirafter, imacros, include, isysroot, isystem, iquote): Add
9268 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
9270 2010-07-27 Joseph Myers <joseph@codesourcery.com>
9272 * c-common.h (c_common_option_lang_mask,
9273 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
9275 (c_common_init_options): Update prototype.
9276 * c-opts.c (c_common_option_lang_mask): New.
9277 (c_common_initialize_diagnostics): Split out of
9278 c_common_init_options.
9279 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
9281 (c_common_init_options): Update prototype. Use decoded options in
9282 search for -lang-asm.
9284 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
9286 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
9287 * c-format.c: Likewise.
9289 2010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
9291 * c-common.h: Include diagnostic-core.h. Error if already
9293 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
9295 2010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
9297 * c-common.c (IN_GCC_FRONTEND): Do not undef.
9298 Do not include expr.h
9299 (vector_mode_valid_p): Move here.
9301 2010-06-21 DJ Delorie <dj@redhat.com>
9303 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
9304 allow these pragmas anywhere.
9306 2010-06-14 Jakub Jelinek <jakub@redhat.com>
9309 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
9310 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
9311 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
9312 ggc_strdup instead of xstrdup.
9314 2010-06-10 Jakub Jelinek <jakub@redhat.com>
9316 * c-cppbuiltin.c: Include cpp-id-data.h.
9317 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
9318 (lazy_hex_fp_value): New function.
9319 (builtin_define_with_hex_fp_value): Provide definitions lazily.
9321 2010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
9323 * c-gimplify.c: Do not include tree-flow.h
9325 2010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
9328 * c-common.c: Rename targetm member:
9329 targetm.enum_va_list -> targetm.enum_va_list_p
9331 2010-06-28 Anatoly Sokolov <aesok@post.ru>
9333 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
9335 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
9337 * c-cppbuiltin.c: Do not include except.h.
9339 2010-06-24 Andi Kleen <ak@linux.intel.com>
9341 * c-common.c (warn_for_omitted_condop): New.
9342 * c-common.h (warn_for_omitted_condop): Add prototype.
9344 2010-06-21 Joseph Myers <joseph@codesourcery.com>
9346 * c.opt (lang-objc): Remove.
9347 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
9349 2010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
9351 * c-opts.c: Include "tm_p.h".
9353 2010-06-20 Joseph Myers <joseph@codesourcery.com>
9355 * c-common.c (parse_optimize_options): Update call to
9358 2010-06-18 Nathan Froyd <froydnj@codesourcery.com>
9360 * c-common.c (record_types_used_by_current_var_decl): Adjust for
9361 new type of types_used_by_cur_var_decl.
9363 2010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
9366 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
9367 for C++ standard compliance.
9369 2010-06-16 Jason Merrill <jason@redhat.com>
9371 * c.opt: Add -Wnoexcept.
9373 2010-06-16 Richard Guenther <rguenther@suse.de>
9376 * c-common.c (c_common_truthvalue_conversion): Remove
9377 premature and wrong optimization concering ADDR_EXPRs.
9379 2010-06-15 Arnaud Charlet <charlet@adacore.com>
9381 * c-ada-spec.c (dump_sloc): Remove column info.
9382 (is_simple_enum): New function.
9383 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
9384 enum types when relevant.
9386 2010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
9388 * c-common.c (conversion_warning): Warn at expression
9391 2010-06-10 Joseph Myers <joseph@codesourcery.com>
9393 * c-opts.c (c_common_handle_option): Don't handle
9396 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
9398 * c-pragma.c (push_alignment): Use typed GC allocation.
9399 (handle_pragma_push_options): Likewise.
9401 * c-common.c (parse_optimize_options): Likewise.
9403 * c-common.h (struct sorted_fields_type): Add variable_size GTY
9406 2010-06-07 Joseph Myers <joseph@codesourcery.com>
9408 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
9409 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
9410 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
9411 flag_signed_bitfields, warn_strict_null_sentinel,
9412 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
9413 flag_gen_declaration, flag_no_gnu_keywords,
9414 flag_implement_inlines, flag_implicit_templates,
9415 flag_implicit_inline_templates, flag_optional_diags,
9416 flag_elide_constructors, flag_default_inline, flag_rtti,
9417 flag_conserve_space, flag_access_control, flag_check_new,
9418 flag_new_for_scope, flag_weak, flag_working_directory,
9419 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
9420 flag_enforce_eh_specs, flag_threadsafe_statics,
9421 flag_pretty_templates): Remove.
9422 * c-common.h (flag_preprocess_only, flag_nil_receivers,
9423 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
9424 flag_replace_objc_classes, flag_undef, flag_no_builtin,
9425 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
9426 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
9427 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
9428 flag_no_gnu_keywords, flag_implement_inlines,
9429 flag_implicit_templates, flag_implicit_inline_templates,
9430 flag_optional_diags, flag_elide_constructors, flag_default_inline,
9431 flag_rtti, flag_conserve_space, flag_access_control,
9432 flag_check_new, flag_new_for_scope, flag_weak,
9433 flag_working_directory, flag_use_cxa_atexit,
9434 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
9435 flag_threadsafe_statics, flag_pretty_templates,
9436 warn_strict_null_sentinel): Remove.
9437 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
9438 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
9439 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
9440 fimplicit-inline-templates, fimplicit-templates,
9441 flax-vector-conversions, fms-extensions, fnil-receivers,
9442 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
9443 frtti, fshort-double, fshort-enums, fshort-wchar,
9444 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
9445 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
9446 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
9447 gen-decls, undef): Use Var.
9448 (fdefault-inline, foptional-diags): Document as doing nothing.
9449 * c-opts.c (c_common_handle_option): Remove cases for options now
9450 using Var. Mark ignored options as such.
9452 2010-06-05 Steven Bosscher <steven@gcc.gnu.org>
9454 * c-common.c: Moved to here from parent directory.
9455 * c-common.def: Likewise.
9456 * c-common.h: Likewise.
9457 * c-cppbuiltin.c: Likewise.
9458 * c-dump.c: Likewise.
9459 * c-format.c: Likewise.
9460 * c-format.h : Likewise.
9461 * c-gimplify.c: Likewise.
9462 * c-lex.c: Likewise.
9463 * c-omp.c: Likewise.
9465 * c-opts.c: Likewise.
9466 * c-pch.c: Likewise.
9467 * c-ppoutput.c: Likewise.
9468 * c-pragma.c: Likewise.
9469 * c-pragma.h: Likewise.
9470 * c-pretty-print.c: Likewise.
9471 * c-pretty-print.h: Likewise.
9472 * c-semantics.c: Likewise.
9473 * stub-objc.c: Likewise.
9475 * c-common.c: Include gt-c-family-c-common.h.
9476 * c-pragma.c: Include gt-c-family-c-pragma.h.
9478 Copyright (C) 2010-2018 Free Software Foundation, Inc.
9480 Copying and distribution of this file, with or without modification,
9481 are permitted in any medium without royalty provided the copyright
9482 notice and this notice are preserved.