1 2018-08-13 Martin Sebor <msebor@redhat.com>
3 PR tree-optimization/71625
4 * c-common.c (braced_list_to_string): New function.
5 * c-common.h (braced_list_to_string): Declare it.
7 2018-08-08 Nathan Sidwell <nathan@acm.org>
9 * c-common.c (try_to_locate_new_include_inertion_point): Use
10 linemap_included_from_linemap.
11 * c-lex.c (fe_file_change): Use linemap_included_from.
12 * c-ppoutput.c (pp_file_change): Likewise.
14 2018-08-01 Martin Sebor <msebor@redhat.com>
16 PR tree-optimization/86650
17 * c-family/c-format.c (gcc_tdiag_char_table): Update comment for "%G".
18 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
19 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
20 * c-format.h (T89_G): Update to be "gimple *" rather than
22 (local_gcall_ptr_node): Rename...
23 (local_gimple_ptr_node): ...to this.
25 2018-07-31 David Malcolm <dmalcolm@redhat.com>
27 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
28 table entries for gcc_diag_char_table, and the 'Z' entry from
29 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
30 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
31 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
32 adding missing "Z" for this table. Remove erroneous "G" and "K"
34 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
35 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
36 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
38 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
40 * c-common.c (speculation_safe_resolve_call): New function.
41 (speculation_safe_resolve_params): New function.
42 (speculation_safe_resolve_return): New function.
43 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
44 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
45 __HAVE_SPECULATION_SAFE_VALUE.
47 2018-07-20 David Malcolm <dmalcolm@redhat.com>
49 * c-common.c (c_cpp_error): Remove redundant "line_table"
50 parameter from call to rich_location::set_range.
51 (maybe_suggest_missing_token_insertion): Likewise.
53 2018-07-20 Martin Sebor <msebor@redhat.com>
56 * gcc/c-family/c.opt (-Warray-bounds): Remove redundant -Wall.
58 2018-07-20 Martin Sebor <msebor@redhat.com>
61 * c-common.h (c_common_handle_option): Change function argument
63 * c-opts.c (c_common_init_options): Same.
64 (c_common_handle_option): Same. Remove special handling of
65 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
66 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
67 options to take a HOST_WIDE_INT argument and accept a byte-size
69 (-Wvla-larger-than): Same.
70 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
71 (-Wno-vla-larger-than): Same.
73 2018-07-12 Jakub Jelinek <jakub@redhat.com>
75 * c-attribs.c (c_common_attribute_table): Add
76 "omp declare target implicit" attribute.
78 2018-07-12 Richard Biener <rguenther@suse.de>
81 * c-attribs.c (handle_packed_attribute): Do not build a variant
82 type with TYPE_PACKED, instead ignore the attribute if we may
83 not apply to the original type.
85 2018-07-10 Jakub Jelinek <jakub@redhat.com>
88 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
89 to contain TREE_LIST for both the original class iterator and the
92 2018-07-07 Eric Botcazou <ebotcazou@adacore.com>
94 * c-ada-spec.c (to_ada_name): Remove index parameter.
95 (pp_ada_tree_identifier): Likewise.
96 (dump_ada_macros): Adjust call to to_ada_name.
97 (struct overloaded_name_hash): Delete.
98 (struct overloaded_name_hasher): Likewise.
99 (overloaded_names): Likewise.
100 (compute_overloading_index): Likewise.
101 (dump_ada_decl_name): Do not call compute_overloading_index and
102 adjust calls to pp_ada_tree_identifier.
103 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
104 (dump_ada_import): Add spc parameter and switch to aspect syntax.
105 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
106 (dump_ada_enum_type): Remove type and display_convention parameters.
107 Adjust calls to pp_ada_tree_identifier.
108 (dump_ada_node): Likewise and for dump_ada_structure.
109 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
111 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
113 (print_constructor): Adjust call to pp_ada_tree_identifier.
114 (print_destructor): Likewise.
115 (dump_ada_declaration): Switch to aspect syntax.
116 (dump_ada_structure): Likewise and tidy up. Replace display_convention
117 parameter with nested parameter.
118 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
119 (dump_ada_specs): Do not delete overloaded_names table.
121 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
124 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
127 2018-07-05 Nathan Sidwell <nathan@acm.org>
129 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
130 NO_IMPLICIT_EXTERN_C.
132 2018-06-28 Martin Liska <mliska@suse.cz>
134 * cppspec.c: Include opt-suggestions.h.
136 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
137 Thomas Schwinge <thomas@codesourcery.com>
138 Cesar Philippidis <cesar@codesourcery.com>
140 * c-pragma.h (enum pragma_omp_clause): Add
141 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
142 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
144 2018-06-20 Jakub Jelinek <jakub@redhat.com>
147 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
150 2018-06-18 Martin Sebor <msebor@redhat.com>
153 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
156 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
158 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
160 2018-06-13 Jason Merrill <jason@redhat.com>
162 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
163 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
166 PR c++/86094 - wrong code with defaulted move ctor.
167 * c-opts.c (c_common_post_options): Bump the current ABI version to
168 13. Set warn_abi_version and flag_abi_compat_version to the current
169 version rather than 0. Fix defaulting flag_abi_compat_version from
172 2018-06-12 Martin Sebor <msebor@redhat.com>
175 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
176 sizeof source and destination yields the same value.
178 2018-06-12 Martin Liska <mliska@suse.cz>
180 * c.opt: Make MPX-related options as Deprecated.
182 2018-06-08 David Malcolm <dmalcolm@redhat.com>
184 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
187 2018-06-08 Martin Liska <mliska@suse.cz>
189 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
190 for MPX (macros, related functions, fields in cgraph_node, ...).
191 (handle_bnd_legacy): Likewise.
192 (handle_bnd_instrument): Likewise.
195 2018-06-06 Jakub Jelinek <jakub@redhat.com>
198 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
199 __cpp_transactional_memory to 201500 instead of 210500.
201 2018-06-06 Jason Merrill <jason@redhat.com>
203 PR c++/85710 - ICE with -Wmemset-elt-size.
204 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
206 2018-06-01 Jason Merrill <jason@redhat.com>
208 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
211 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
213 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
214 declaration for a typedef independently of whether the declaration of
215 the subtype is generated.
217 2018-05-31 Martin Sebor <msebor@redhat.com>
220 * c.opt (-Wno-alloc-size-larger-than): New option.
222 2018-04-22 David Pagan <dave.pagan@oracle.com>
225 * c-opts.c (c_common_post_options): Set default for warn_return_type
226 for C++/C++ with ObjC extensions only. For C, makes it possible to
227 differentiate between default (no option), -Wreturn-type, and
230 2018-05-29 Jason Merrill <jason@redhat.com>
232 * c.opt (Winit-list-lifetime): New flag.
234 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
236 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
237 splay_tree_delete_pointers.
239 2018-05-26 Jakub Jelinek <jakub@redhat.com>
242 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
243 noinline variable to workaround broken kernel headers.
245 2018-05-18 Jason Merrill <jason@redhat.com>
247 * c.opt (Wdeprecated-copy): New flag.
249 2018-05-17 Martin Liska <mliska@suse.cz>
251 * c-warn.c (overflow_warning): Do not use
252 space in between 'G_' and '('.
254 2018-05-09 Jason Merrill <jason@redhat.com>
256 * c-common.c (valid_array_size_p): Add complain parameter.
257 * c-common.h: ...which defaults to true.
259 2018-05-11 Jakub Jelinek <jakub@redhat.com>
262 * c-omp.c (c_omp_predetermined_sharing): Return
263 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
265 2018-05-11 Martin Liska <mliska@suse.cz>
268 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
271 2018-05-10 Jakub Jelinek <jakub@redhat.com>
274 * c-common.h (fold_offsetof_1): Removed.
275 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
276 CTX argument defaulted to ERROR_MARK.
277 * c-common.c (fold_offsetof_1): Renamed to ...
278 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
279 argument, convert the pointer constant to TYPE and use size_binop
280 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
281 a pointer type. Adjust recursive calls.
283 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
286 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
288 2018-05-07 Nathan Sidwell <nathan@acm.org>
290 * c.opt (ffor-scope): Remove functionality, issue warning.
292 2018-05-03 Nathan Sidwell <nathan@acm.org>
294 * c.opt (ffriend-injection): Remove functionality, issue warning.
296 2018-05-01 David Malcolm <dmalcolm@redhat.com>
299 * c-format.c (struct format_check_results): Add field
301 (check_format_info): Initialize it, and warn if encountered.
302 (check_format_arg): Distinguish between wide char and
303 everything else when detecting arrays of non-char.
305 2018-04-30 David Malcolm <dmalcolm@redhat.com>
307 * c-format.c (get_corrected_substring): Update for
308 location_get_source_line returning a char_span. Use a char_span
309 when handling the prefix of the correction.
310 * c-indentation.c (get_visual_column): Update for
311 location_get_source_line returning a char_span.
312 (get_first_nws_vis_column): Likewise.
314 2018-03-29 David Malcolm <dmalcolm@redhat.com>
317 * known-headers.cc (get_stdlib_header_for_name): Add various names
318 from <assert.h>, <string.h>, and <memory.h>; add more names from
321 2018-03-27 Jakub Jelinek <jakub@redhat.com>
324 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
325 get_base_address of the second operand is a VAR_P, rather than the
326 operand itself, and use gcc_checking_assert instead of gcc_assert.
328 2018-03-23 Marek Polacek <polacek@redhat.com>
331 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
332 <case RDIV_EXPR>: Tweak condition.
334 2018-03-20 Eric Botcazou <ebotcazou@adacore.com>
336 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
338 2018-03-16 Jakub Jelinek <jakub@redhat.com>
341 * c-warn.c (conversion_warning): Replace "to to" with "to" in
345 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
348 2018-03-16 Richard Biener <rguenther@suse.de>
351 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
352 unshare the possibly folded expression.
354 2018-03-15 Richard Biener <rguenther@suse.de>
357 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
359 2018-03-13 Martin Sebor <msebor@redhat.com>
361 PR tree-optimization/84725
362 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
363 with all three narrow character types, including their qualified forms.
365 2018-03-12 Martin Sebor <msebor@redhat.com>
367 PR tree-optimization/83456
368 * gcc/c-family/c-common.c (check_function_restrict): Return bool.
369 Restore checking of bounded built-in functions.
370 (check_function_arguments): Also return the result
371 of warn_for_restrict.
372 * gcc/c-family/c-common.c (check_function_restrict): Return bool.
373 * gcc/c-family/c-warn.c (warn_for_restrict): Return bool.
375 2018-03-02 Marek Polacek <polacek@redhat.com>
378 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
381 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
383 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
386 2018-03-01 Marek Polacek <polacek@redhat.com>
389 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
390 alignment in computation.
392 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
394 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
395 <REAL_TYPE>: Deal specifically with _Float128/__float128.
397 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
399 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
400 (is_char_array): Take a type instead of a declaration.
401 (dump_ada_array_type): Likewise.
402 (is_simple_enum): Minor tweak.
403 (dump_ada_enum_type): New function extracted from...
404 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
405 <INTEGER_TYPE>: Remove unreachable code.
406 <RECORD_TYPE>: Likewise. Minor tweaks.
407 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
408 <ENUMERAL_TYPE>: New case.
409 <RECORD_TYPE>: Factor out common code.
410 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
411 Minor tweaks. Deal with enumeral types.
412 (dump_ada_structure): Minor tweaks.
414 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
416 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
417 address for incomplete structures.
418 (dump_forward_type): Do not bail out for incomplete structures.
419 (dump_ada_declaration): Do not special-case incomplete structures
420 for subtypes. Dump them as null records for types.
422 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
424 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
425 (is_char_array): Fix formatting.
426 (dump_template_types): Likewise.
427 (dump_generic_ada_node): Rename into...
428 (dump_ada_node): ...this.
429 <POINTER_TYPE>: Remove superfluous space. Use generic address for
430 incomplete structures and not for empty structures. Do not use it
431 when forward declarations are needed.
432 (dump_forward_type): New function.
433 (dump_nested_types): Remove FORWARD parameter. Do not consider
434 TREE_VISITED and do not generate a forward declaration. Only dump
435 original nested types for nested declaration.
436 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
437 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
438 <RECORD_TYPE>: Do not consider TREE_VISITED.
439 (dump_ada_declaration): Use booleans and fix formatting throughout.
440 <TYPE_DECL>: Skip incomplete structures and not empty structures.
441 Call dump_forward_type instead of dump_nested_types for a typedef.
442 Remove superfluous check and adjust call to dump_nested_types.
443 <POINTER_TYPE>: Call dump_forward_type and fall through.
444 (dump_ada_struct_decl): Rename into...
445 (dump_ada_structure): ...this. Do not special-case empty structures.
447 2018-02-27 Martin Sebor <msebor@redhat.com>
450 * c.opt (-Wmissing-attributes): New option.
452 2018-02-21 Martin Liska <mliska@suse.cz>
454 * c.opt (Wcatch-value=): Add IntegerRange.
456 2018-02-15 Jason Merrill <jason@redhat.com>
458 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
460 2018-02-09 Nathan Sidwell <nathan@acm.org>
463 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
465 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
468 2018-02-09 Martin Sebor <msebor@redhat.com>
471 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
472 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
473 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
474 (-Wstrict-overflow, -Wsuggest-attribute): Same.
475 (-Wuninitialized): Same.
477 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
479 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
480 keyword for components.
482 2018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
484 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
486 2018-02-02 Julia Koval <julia.koval@intel.com>
488 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
490 2018-01-29 Marek Polacek <polacek@redhat.com>
493 * c-format.c (check_function_format): Check current_function_decl.
495 2018-01-27 Jakub Jelinek <jakub@redhat.com>
497 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
499 (LAZY_HEX_FP_VALUES_CNT): Define.
500 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
501 values rather than just 12.
502 (builtin_define_with_hex_fp_value): Likewise.
504 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
507 * c.opt (-fmacro-prefix-map): New option.
508 * c-opts.c (c_common_handle_option): Handle it.
509 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
510 * c-ppoutput.c (init_pp_output): Likewise.
512 2018-01-17 David Malcolm <dmalcolm@redhat.com>
515 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
517 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
519 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
520 Skip 'f' and 'F' characters if it is true.
521 (store_ada_macro): Minor tweak.
522 (dump_ada_macros) <CPP_COMMENT>: Likewise.
523 <CPP_WSTRING>: Likewise.
524 <CPP_STRING>: Output '&' in the buffer if not the first string.
525 <CPP_NUMBER>: Adjust calls to dump_number.
527 2018-01-10 David Malcolm <dmalcolm@redhat.com>
530 * c-common.c: Include "selftest.h".
531 (get_atomic_generic_size): Perform the test for integral type
532 before the range test for any integer constant, fixing indentation
533 of braces. Call fold_for_warn before testing for an INTEGER_CST.
534 (reject_gcc_builtin): Strip any location wrapper from EXPR.
535 (selftest::test_fold_for_warn): New function.
536 (selftest::c_common_c_tests): New function.
537 (selftest::c_family_tests): Call it, and
538 selftest::c_pretty_print_c_tests.
539 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
540 * c-format.c (check_format_arg): Convert VAR_P check to a
542 * c-pretty-print.c: Include "selftest.h".
543 (pp_c_cast_expression): Don't print casts for location wrappers.
544 (selftest::assert_c_pretty_printer_output): New function.
545 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
546 (selftest::test_location_wrappers): New function.
547 (selftest::c_pretty_print_c_tests): New function.
548 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
550 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
551 Alan Hayward <alan.hayward@arm.com>
552 David Sherwood <david.sherwood@arm.com>
554 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
556 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
557 Alan Hayward <alan.hayward@arm.com>
558 David Sherwood <david.sherwood@arm.com>
560 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
563 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
564 Alan Hayward <alan.hayward@arm.com>
565 David Sherwood <david.sherwood@arm.com>
567 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
568 (convert_vector_to_array_for_subscript): Handle polynomial
569 TYPE_VECTOR_SUBPARTS.
570 (c_common_type_for_mode): Check valid_vector_subparts_p.
571 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
574 2018-01-03 Jakub Jelinek <jakub@redhat.com>
576 Update copyright years.
578 2017-12-22 Mike Stump <mikestump@comcast.net>
579 Eric Botcazou <ebotcazou@adacore.com>
581 * c-pragma.c (init_pragma): Register pragma GCC unroll.
582 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
584 2017-12-22 Alexandre Oliva <aoliva@redhat.com>
588 * c-semantics.c (only_debug_stmts_after_p): New.
589 (pop_stmt_list): Clear side effects in debug-only stmt list.
590 Check for single nondebug stmt followed by debug stmts only.
592 2017-12-21 Alexandre Oliva <aoliva@redhat.com>
595 * c-semantics.c (pop_stmt_list): Propagate side effects from
596 single nondebug stmt to container list.
598 2017-12-19 Jakub Jelinek <jakub@redhat.com>
600 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
601 conditions with typical order conditions.
603 2017-12-18 Marek Polacek <polacek@redhat.com>
605 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
608 2017-12-17 Martin Sebor <msebor@redhat.com>
610 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
611 an error for attribute warn_if_not_aligned.
613 2017-12-16 Martin Sebor <msebor@redhat.com>
615 PR tree-optimization/78918
616 * c-common.c (check_function_restrict): Avoid checking built-ins.
617 * c.opt (-Wrestrict): Include in -Wall.
619 2017-12-15 Jakub Jelinek <jakub@redhat.com>
621 * c-attribs.c (c_common_attribute_table,
622 c_common_format_attribute_table): Swap affects_type_identity
623 and handler fields, adjust comments.
625 2017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
627 * c.opt (Wcast-function-type): New warning option.
628 * c-lex.c (get_fileinfo): Avoid warning.
629 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
631 2017-12-14 Qing Zhao <qing.zhao@oracle.com>
634 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
635 Adjust the size of buf1 and buf2, add a new buf to avoid
636 format-overflow warning.
638 2017-12-12 Alexandre Oliva <aoliva@redhat.com>
640 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
641 subsequent statement list.
643 2017-12-07 Martin Sebor <msebor@redhat.com>
647 * c-attribs.c (attr_aligned_exclusions): New array.
648 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
649 (attr_common_exclusions, attr_const_pure_exclusions): Same.
650 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
651 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
652 (attr_warn_unused_result_exclusions): Same.
653 (handle_hot_attribute, handle_cold_attribute): Simplify.
654 (handle_const_attribute): Warn on function returning void.
655 (handle_pure_attribute): Same.
656 (handle_aligned_attribute): Diagnose conflicting attribute
658 * c-warn.c (diagnose_mismatched_attributes): Simplify.
660 2017-12-06 David Malcolm <dmalcolm@redhat.com>
663 * c-common.c (selftest::c_family_tests): Call
664 selftest::c_spellcheck_cc_tests.
665 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
666 * c-spellcheck.cc: Include "selftest.h".
667 (name_reserved_for_implementation_p): New function.
668 (should_suggest_as_macro_p): New function.
669 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
670 should_suggest_as_macro_p and call it.
671 (selftest::test_name_reserved_for_implementation_p): New function.
672 (selftest::c_spellcheck_cc_tests): New function.
673 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
675 2017-12-06 David Malcolm <dmalcolm@redhat.com>
677 * c-spellcheck.cc: New file, taken from macro-handling code in
679 * c-spellcheck.h: New file, taken from macro-handling code in
682 2017-12-01 Jakub Jelinek <jakub@redhat.com>
684 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
686 (handle_simd_attribute): Don't check for "cilk simd function"
687 attribute. Reindent, formatting changes.
689 2017-11-30 Julia Koval <julia.koval@intel.com>
691 * c-common.h (inv_list): Remove.
693 2017-11-28 Jakub Jelinek <jakub@redhat.com>
696 * c-common.c (c_switch_covers_all_cases_p_1,
697 c_switch_covers_all_cases_p): New functions.
698 * c-common.h (c_switch_covers_all_cases_p): Declare.
700 2017-11-28 Julia Koval <julia.koval@intel.com>
701 Sebastian Peryt <sebastian.peryt@intel.com>
703 * array-notation-common.c: Delete.
704 * c-cilkplus.c: Ditto.
705 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
706 * c-common.def (ARRAY_NOTATION_REF): Remove.
707 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
708 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
709 c_validate_cilk_plus_loop, cilkplus_an_parts,
710 cilk_ignorable_spawn_rhs_op,
711 cilk_recognize_spawn): Remove.
712 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
713 * c-omp.c: Remove CILK_SIMD check.
715 * c-pragma.h: Remove CILK related pragmas.
716 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
717 ARRAY_NOTATION_REF condition.
718 (c_pretty_printer::expression): Ditto.
719 * c.opt (fcilkplus): Remove.
722 2017-11-21 Marc Glisse <marc.glisse@inria.fr>
724 * c-pretty-print.c (pp_c_additive_expression,
725 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
727 2017-11-21 Jakub Jelinek <jakub@redhat.com>
729 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
732 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
733 instead of tree_to_uhwi, formatting fix.
735 2017-11-20 David Malcolm <dmalcolm@redhat.com>
738 * known-headers.cc: New file, based on material from c/c-decl.c.
739 (suggest_missing_header): Copied as-is.
740 (get_stdlib_header_for_name): New, based on get_c_name_hint but
741 heavily edited to add C++ support. Add some knowledge about
742 <limits.h>, <stdint.h>, and <wchar.h>.
743 * known-headers.h: Likewise.
745 2017-11-20 David Malcolm <dmalcolm@redhat.com>
747 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
748 (lookup_name_fuzzy): Likewise. Convert return type from
749 const char * to name_hint. Add location_t param.
750 * name-hint.h: New header.
752 2017-11-19 Jakub Jelinek <jakub@redhat.com>
756 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
758 2017-11-16 Joseph Myers <joseph@codesourcery.com>
760 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
761 expected publication date of C17.
762 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
764 2017-11-15 Joseph Myers <joseph@codesourcery.com>
767 * c-common.c (c_common_reswords): Add __builtin_tgmath.
768 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
770 2017-11-10 Martin Sebor <msebor@redhat.com>
773 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
774 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
775 * c.opt (-Wstringop-truncation): New option.
777 2017-11-06 Martin Liska <mliska@suse.cz>
780 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
782 * c.opt: Set default value of warn_return_type.
784 2017-10-31 David Malcolm <dmalcolm@redhat.com>
786 * c-common.c (binary_op_error): Update for renaming of
788 (c_parse_error): Likewise.
789 * c-warn.c (warn_logical_not_parentheses): Likewise for
790 renaming of inform_at_rich_loc.
791 (warn_for_restrict): Likewise for renaming of
792 warning_at_rich_loc_n.
794 2017-10-30 Joseph Myers <joseph@codesourcery.com>
796 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
797 * c-opts.c (set_std_c17): New function.
798 (c_common_init_options): Use gnu17 as default C version.
799 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
801 2017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
803 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
804 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
805 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
808 2017-10-23 Marek Polacek <polacek@redhat.com>
811 * c-warn.c (warnings_for_convert_and_check): Fix typos.
813 2017-10-19 Eric Botcazou <ebotcazou@adacore.com>
815 * c-common.c (check_builtin_function_arguments): Also check arguments
816 of __builtin_alloca_with_align_and_max.
818 2017-10-17 David Malcolm <dmalcolm@redhat.com>
820 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
821 rather than NULL to format_warning_va.
822 (check_format_types): Likewise when calling format_type_warning.
823 Remove code to extract source_ranges and source_range * in favor
824 of just a location_t.
825 (format_type_warning): Convert source_range * param to a
828 2017-10-13 Jakub Jelinek <jakub@redhat.com>
830 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
833 2017-10-12 David Malcolm <dmalcolm@redhat.com>
835 * c-common.c (enum missing_token_insertion_kind): New enum.
836 (get_missing_token_insertion_kind): New function.
837 (maybe_suggest_missing_token_insertion): New function.
838 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
840 2017-10-11 Nathan Sidwell <nathan@acm.org>
842 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
843 (c_common_handle_option): Update incpath_kind names.
845 2017-10-11 Martin Liska <mliska@suse.cz>
848 * c-attribs.c (handle_no_sanitize_attribute): Report directly
851 2017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
853 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
854 operating on trees as wide_ints.
855 * c-common.c (pointer_int_sum): Likewise.
856 * c-pretty-print.c (pp_c_integer_constant): Likewise.
857 * c-warn.c (match_case_to_enum_1): Likewise.
858 (c_do_switch_warnings): Likewise.
859 (maybe_warn_shift_overflow): Likewise.
861 2017-10-10 Jakub Jelinek <jakub@redhat.com>
864 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
865 instead of wide_int::from.
867 2017-10-06 Jakub Jelinek <jakub@redhat.com>
870 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
871 using to_widest use wide_int with the larger of the two precisions.
873 2017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
875 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
878 2017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
880 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
881 when combining the original unconverted comparison operands.
883 2017-09-29 Jakub Jelinek <jakub@redhat.com>
885 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
888 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
890 * c-ada-spec.c (to_ada_name): Add index parameter.
891 (pp_ada_tree_identifier): Likewise.
892 (dump_ada_macros): Adjust call to to_ada_name.
893 (struct overloaded_name_hash): New type.
894 (struct overloaded_name_hasher): Likewise.
895 (overloaded_names): New hash table.
896 (compute_overloading_index): New function.
897 (dump_ada_decl_name): Call it and pass the result to
898 pp_ada_tree_identifier.
899 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
900 (dump_ada_function_declaration): Likewise.
901 (dump_generic_ada_node): Likewise.
902 (print_constructor): Likewise.
903 (print_destructor): Likewise.
904 (dump_ada_specs): Delete overloaded_names table.
906 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
908 * c-ada-spec.c (max_ada_macros): Move around.
909 (store_ada_macro_index): Likewise.
910 (source_file): Rename into...
911 (macro_source_file): ...this.
912 (count_ada_macro): Move around.
913 (store_ada_macro): Likewise.
914 (compare_macro): Likewise.
915 (print_ada_macros): Merge in...
916 (dump_ada_macros): ...this.
917 (source_file_base): Rename into...
918 (current_source_file): ...this.
919 (print_comment): Move around.
920 (dump_ada_nodes): Call dump_ada_declaration directly.
921 (struct with): Change type of limited field to bool.
922 (append_withs): Change type of limited_access parameter to bool.
923 (pp_ada_tree_identifie): Likewise.
924 (dump_ada_decl_nam): Likewise.
925 (dump_generic_ada_node): Likewise. Do not print the return type.
926 (to_ada_name): Change type of space_found parameter to bool.
927 (dump_ada_function_declaration): Return void and change type of
928 parameters to bool. Also print the return type for a function.
929 (print_ada_methods): Rename into...
930 (dump_ada_methods): ...this.
931 (print_ada_declaration): Rename into ...
932 (dump_ada_declaration): ...this. Do not print the return type.
933 (print_ada_struct_decl): Rename into...
934 (dump_ada_struct_decl): ...this.
936 2017-09-29 Jakub Jelinek <jakub@redhat.com>
938 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
939 rather than DECL_INITIAL.
940 (common_handle_aligned_attribute): Likewise.
942 2017-09-20 Alexandre Oliva <aoliva@redhat.com>
944 * c.opt (gen-decls): Add RejectNegative.
946 2017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
947 Jakub Jelinek <jakub@redhat.com>
949 Add support for -std=c++2a.
950 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
951 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
952 * c-opts.c (set_std_cxx2a): New.
953 (c_common_handle_option): Set options when -std=c++2a is enabled.
954 (c_common_post_options): Adjust comments.
955 (set_std_cxx14, set_std_cxx17): Likewise.
957 2017-09-15 Eric Botcazou <ebotcazou@adacore.com>
959 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
960 message for non-uniform endianness and issue a warning in C++.
962 2017-09-15 Jakub Jelinek <jakub@redhat.com>
964 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
965 (Wc++17-compat): Change from undocumented alias to option.
966 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
967 change C++1z to C++17 in description.
968 (std=c++1z, std=gnu++1z): Change from option to undocumented
970 (std=c++17, std=gnu++17): Change from undocumented alias to option.
972 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
973 * c-opts.c (set_std_cxx1z): Rename to ...
974 (set_std_cxx17): ... this.
975 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
976 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
978 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
981 2017-09-12 H.J. Lu <hongjiu.lu@intel.com>
983 * c-attribs.c (common_handle_aligned_attribute): Don't warn
984 function alignment if warn_if_not_aligned_p is true.
986 2017-09-12 Nathan Sidwell <nathan@acm.org>
988 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
989 resort_sorted_fields): Move to c/c-decl.c.
990 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
991 (struct sorted_fields_type): Move to c/c-lang.h.
993 2017-09-09 Jonathan Wakely <jwakely@redhat.com>
996 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
998 2017-09-04 Marek Polacek <polacek@redhat.com>
1001 * c-warn.c (warn_tautological_bitwise_comparison): New function.
1002 (warn_tautological_cmp): Call it.
1004 2017-09-01 Boris Kolpackov <boris@codesynthesis.com>
1006 * c-opts.c (c_common_finish): Write dependency information even if
1009 2017-09-01 Jakub Jelinek <jakub@redhat.com>
1012 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
1013 (omp_pragmas_simd): ... here.
1014 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
1015 create new clauses list containing just simd clause.
1017 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1018 Alan Hayward <alan.hayward@arm.com>
1019 David Sherwood <david.sherwood@arm.com>
1021 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
1022 into scalar_mode_supported_p call.
1023 (handle_mode_attribute): Update call to scalar_mode_supported_p.
1025 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1026 Alan Hayward <alan.hayward@arm.com>
1027 David Sherwood <david.sherwood@arm.com>
1029 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
1030 for the mode iterator.
1032 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1033 Alan Hayward <alan.hayward@arm.com>
1034 David Sherwood <david.sherwood@arm.com>
1036 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
1037 * c-common.c (c_build_vec_perm_expr): Likewise.
1039 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1040 Alan Hayward <alan.hayward@arm.com>
1041 David Sherwood <david.sherwood@arm.com>
1043 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
1045 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1046 Alan Hayward <alan.hayward@arm.com>
1047 David Sherwood <david.sherwood@arm.com>
1049 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
1050 before calling targetm.addr_space.valid_pointer_mode.
1052 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1053 Alan Hayward <alan.hayward@arm.com>
1054 David Sherwood <david.sherwood@arm.com>
1056 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
1058 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1059 Alan Hayward <alan.hayward@arm.com>
1060 David Sherwood <david.sherwood@arm.com>
1062 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
1064 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
1066 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1067 Alan Hayward <alan.hayward@arm.com>
1068 David Sherwood <david.sherwood@arm.com>
1070 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
1073 2017-08-29 Martin Liska <mliska@suse.cz>
1076 * c-common.c (parse_optimize_options): Add argument to function
1078 * c-pragma.c (handle_pragma_diagnostic): Likewise.
1080 2017-08-24 David Malcolm <dmalcolm@redhat.com>
1082 * c-lex.c (interpret_float): Use token location
1083 when building an EXCESS_PRECISION_EXPR.
1085 2017-08-21 David Malcolm <dmalcolm@redhat.com>
1087 * c-common.c (check_function_arguments): Add "arglogs" param; pass
1088 it to check_function_format.
1089 * c-common.h (check_function_arguments): Add vec<location_t> *
1091 (check_function_format): Likewise.
1092 * c-format.c (struct format_check_context): Add field "arglocs".
1093 (check_function_format): Add param "arglocs"; pass it to
1095 (check_format_info): Add param "arglocs"; use it to initialize
1096 new field of format_ctx.
1097 (check_format_arg): Pass format_ctx->arglocs to new param of
1098 check_format_info_main.
1099 (class argument_parser): New field "arglocs".
1100 (argument_parser::argument_parser): Add "arglocs_" param and use
1101 it to initialize new field.
1102 (argument_parser::check_argument_type): Pass new arglocs field to
1104 (check_format_info_main): Add param "arglocs", and use it when
1105 constructing arg_parser.
1106 (check_format_types): Add param "arglocs"; use it if non-NULL when
1107 !EXPR_HAS_LOCATION (cur_param) to get at location information.
1109 2017-08-18 H.J. Lu <hongjiu.lu@intel.com>
1112 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
1113 (c_common_attribute_table): Add warn_if_not_aligned.
1114 (handle_aligned_attribute): Renamed to ...
1115 (common_handle_aligned_attribute): Remove argument, name, and add
1116 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
1117 (handle_aligned_attribute): New.
1118 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
1120 2017-08-14 Martin Sebor <msebor@redhat.com>
1123 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
1124 (handle_nonstring_attribute): New function.
1126 2017-08-14 Martin Sebor <msebor@redhat.com>
1129 * c-format.h (T89_G): New macro.
1130 * c-format.c (local_gcall_ptr_node): New variable.
1131 (init_dynamic_diag_info): Initialize it.
1133 2017-08-11 Martin Liska <mliska@suse.cz>
1135 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
1136 TARGET_SUPPORTS_ALIASES.
1138 2017-08-10 David Malcolm <dmalcolm@redhat.com>
1140 * c-common.c (c_parse_error): Add rich_location * param, using it
1141 rather implicitly using input_location.
1142 * c-common.h (c_parse_error): Add rich_location * param.
1144 2017-08-09 Marek Polacek <polacek@redhat.com>
1146 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
1147 (c_common_truthvalue_conversion): Likewise.
1148 * c-omp.c (c_finish_omp_atomic): Likewise.
1149 * c-common.h (build_binary_op): Update declaration.
1151 2017-08-08 Martin Liska <mliska@suse.cz>
1153 * c-ada-spec.c: Include header files.
1154 * c-ubsan.c: Likewise.
1155 * c-warn.c: Likewise.
1157 2017-08-07 Jakub Jelinek <jakub@redhat.com>
1160 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
1162 2017-08-07 Eric Botcazou <ebotcazou@adacore.com>
1164 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
1165 (print_ada_methods): Likewise.
1166 (print_ada_declaration): Likewise.
1168 2017-08-07 Martin Liska <mliska@suse.cz>
1170 * array-notation-common.c: Add new includes.
1171 * c-format.c( handle_format_attribute): Canonicalize a format
1173 * c-lex.c (c_common_has_attribute): Canonicalize name of an
1175 * c-pretty-print.c: Add new include.
1177 2017-08-05 Eric Botcazou <ebotcazou@adacore.com>
1179 * c-ada-spec.c (has_static_fields): Look only into variables.
1180 (print_constructor): Add TYPE parameter and use it for the name.
1181 (print_destructor): Likewise.
1182 (print_ada_declaration): Adjust to new constructor/destructor names.
1183 Adjust calls to print_constructor and print_destructor.
1184 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
1185 Look only into variables in the final loop.
1187 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
1189 * c-ada-spec.c (has_static_fields): Look only into fields.
1190 (dump_generic_ada_node): Small tweak.
1191 (dump_nested_types): Look only into fields.
1192 (print_ada_declaration): Look only into methods. Small tweak.
1193 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
1195 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
1197 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
1198 (dump_ada_function_declaration): Likewise.
1199 (dump_generic_ada_node): Likewise.
1200 (print_ada_declaration): Add support for const-qualified variables.
1202 2017-07-31 Martin Liska <mliska@suse.cz>
1205 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
1206 Guard condition with flag_sanitize_p also with current_function_decl
1208 (ubsan_maybe_instrument_reference_or_call): Likewise.
1210 2017-07-30 Uros Bizjak <ubizjak@gmail.com>
1212 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
1214 2017-07-29 Eric Botcazou <ebotcazou@adacore.com>
1216 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
1218 (print_ada_declaration): Add missing guard for record types.
1220 2017-07-27 Jakub Jelinek <jakub@redhat.com>
1223 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
1224 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
1225 new COMPOUND_EXPRs around the rhs of the comparison.
1227 2017-07-27 Marek Polacek <polacek@redhat.com>
1230 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
1233 2017-07-27 Jakub Jelinek <jakub@redhat.com>
1235 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
1236 (handle_noipa_attribute): New function.
1238 2017-07-07 Torsten Duwe <duwe@suse.de>
1240 * c-attribs.c (c_common_attribute_table): Add entry for
1241 "patchable_function_entry".
1243 2017-07-20 Nathan Sidwell <nathan@acm.org>
1245 Remove TYPE_METHODS.
1246 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
1247 dump_ada_template, print_ada_methods,
1248 print_ada_declaration): Member fns are on TYPE_FIELDS.
1250 2017-07-18 Nathan Sidwell <nathan@acm.org>
1252 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
1254 2017-07-14 David Malcolm <dmalcolm@redhat.com>
1256 * c-common.c (try_to_locate_new_include_insertion_point): New
1258 (per_file_includes_t): New typedef.
1259 (added_includes_t): New typedef.
1260 (added_includes): New variable.
1261 (maybe_add_include_fixit): New function.
1262 * c-common.h (maybe_add_include_fixit): New decl.
1264 2017-07-10 Martin Sebor <msebor@redhat.com>
1267 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
1269 2017-07-06 David Malcolm <dmalcolm@redhat.com>
1271 * c-common.c (selftest::c_family_tests): New.
1272 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
1273 (selftest::c_family_tests): New decl.
1275 2017-07-04 Marek Polacek <polacek@redhat.com>
1278 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
1281 2017-07-04 Marek Polacek <polacek@redhat.com>
1283 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
1285 2017-06-28 Martin Liska <mliska@suse.cz>
1288 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
1289 to a function declaration.
1291 2017-06-28 Martin Liska <mliska@suse.cz>
1294 * c.opt: Add IntegerRange to various options.
1296 2017-06-26 Marek Polacek <polacek@redhat.com>
1299 * c-common.h (warn_for_multistatement_macros): Declare.
1300 * c-warn.c: Include "c-family/c-indentation.h".
1301 (warn_for_multistatement_macros): New function.
1302 * c.opt (Wmultistatement-macros): New option.
1303 * c-indentation.c (guard_tinfo_to_string): No longer static.
1304 Change the parameter type to "enum rid". Handle RID_SWITCH.
1305 * c-indentation.h (guard_tinfo_to_string): Declare.
1307 2017-06-23 Marc Glisse <marc.glisse@inria.fr>
1309 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
1311 2017-06-15 Martin Sebor <msebor@redhat.com>
1314 * c.opt (-Wclass-memaccess): New option.
1316 2017-06-14 Boris Kolpackov <boris@codesynthesis.com>
1318 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
1320 2017-06-13 Marek Polacek <polacek@redhat.com>
1323 * c-warn.c (do_warn_duplicated_branches): Return if any of the
1326 2017-06-13 Martin Liska <mliska@suse.cz>
1329 * c-attribs.c (add_no_sanitize_value): New function.
1330 (handle_no_sanitize_attribute): Likewise.
1331 (handle_no_sanitize_address_attribute): Use the function.
1332 (handle_no_sanitize_thread_attribute): New function.
1333 (handle_no_address_safety_analysis_attribute): Use
1334 add_no_sanitize_value.
1335 (handle_no_sanitize_undefined_attribute): Likewise.
1336 * c-common.h: Declare new functions.
1337 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
1338 (ubsan_instrument_shift): Likewise.
1339 (ubsan_instrument_bounds): Likewise.
1340 (ubsan_maybe_instrument_array_ref): Likewise.
1341 (ubsan_maybe_instrument_reference_or_call): Likewise.
1343 2017-06-11 Jason Merrill <jason@redhat.com>
1345 * c-ada-spec.c, c-pragma.c: Use id_equal.
1347 2017-06-04 Marek Polacek <polacek@redhat.com>
1350 * c-format.c (matching_type_p): Return false if any of the types
1351 requires structural equality.
1353 2017-06-02 Martin Sebor <msebor@redhat.com>
1356 * c-warn.c (conversion_warning): Use -Wconversion for integer
1357 conversion and -Wfloat-conversion for floating one.
1359 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
1361 * c.opt (Wsizeof-pointer-div): New warning option.
1363 2017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
1365 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
1366 (Wcatch-value=1): Enable by -Wall.
1368 2017-05-30 David Malcolm <dmalcolm@redhat.com>
1370 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
1372 * c.opt (fdiagnostics-show-template-tree): New option.
1373 (felide-type): New option.
1375 2017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
1377 * c.opt (Wcatch-value=): New C++ warning flag.
1379 2017-05-24 Nathan Sidwell <nathan@acm.org>
1381 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
1382 const casts to avoid warning.
1384 2017-05-24 Martin Sebor <msebor@redhat.com>
1387 * c-common.h (unsafe_conversion_p): Add a function argument.
1388 * c-common.c (unsafe_conversion_p): Same.
1389 Add type names and values to diagnostics.
1390 (scalar_to_vector): Adjust.
1391 * c-warn.c (constant_expression_error): Add a function argument.
1392 Add type names and values to diagnostics.
1393 (conversion_warning): Add a function argument.
1394 Add type names and values to diagnostics.
1395 (warnings_for_convert_and_check): Same.
1397 2017-05-19 Jason Merrill <jason@redhat.com>
1399 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
1402 2017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
1404 * c-format.c (locus): Move out of function scope,
1407 2017-05-19 Nathan Sidwell <nathan@acm.org>
1409 * c-opts.c (class_dump_file, class_dump_flags): Delete.
1410 (c_common_parse_file): Remove class dump handling.
1411 (get_dump_info): Likewise.
1413 2017-05-19 Richard Biener <rguenther@suse.de>
1416 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
1417 to alias-set zero memory.
1419 2017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
1421 * c-format.c (local_tree_type_node): Add GTY attribute.
1423 2017-05-18 Marek Polacek <polacek@redhat.com>
1425 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
1426 (c_common_fixed_point_type_for_size): Likewise.
1427 (c_common_type_for_mode): Likewise.
1428 (shorten_compare): Likewise.
1429 (c_promoting_integer_type_p): Use false/true instead of 0/1.
1430 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
1432 2017-05-18 Marek Polacek <polacek@redhat.com>
1434 * c-common.c (self_promoting_args_p): Change the return type to bool.
1435 Use false/true instead of 0/1.
1436 * c-common.h (self_promoting_args_p): Update.
1438 2017-05-17 Marek Polacek <polacek@redhat.com>
1440 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
1441 * c-warn.c: Likewise.
1443 2017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
1445 Implement new C++ intrinsics __is_assignable and __is_constructible.
1446 * c-common.c (__is_assignable, __is_constructible): New.
1447 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
1449 2017-05-17 Martin Liska <mliska@suse.cz>
1451 * c-common.h: Introduce dump_flags_t type and
1452 use it instead of int type.
1453 * c-gimplify.c (c_genericize): Likewise.
1454 * c-opts.c: Likewise.
1456 2017-05-17 Marek Polacek <polacek@redhat.com>
1458 * c-common.c (c_save_expr): Remove.
1459 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
1460 * c-common.h (c_save_expr): Remove declaration.
1462 2017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
1465 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
1466 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
1467 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
1468 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
1470 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
1472 2017-05-09 Marek Polacek <polacek@redhat.com>
1475 * c-warn.c (unwrap_c_maybe_const): New.
1476 (warn_logical_operator): Call it.
1478 2017-05-09 Nathan Sidwell <nathan@acm.org>
1480 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
1481 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
1483 2017-05-08 Martin Sebor <msebor@redhat.com>
1485 PR translation/80280
1486 * c-format.h (struct format_flag_spec): Add new member.
1488 * c-format.c (local_tree_type_node): New global.
1489 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
1490 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
1491 (strfmon_flag_specs): Likewise.
1492 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
1493 with distinct quoting properties.
1494 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
1495 (flag_chars_t::validate): Add argument and handle bad quoting.
1496 (check_format_info_main): Handle quoting problems.
1497 (init_dynamic_diag_info): Simplify.
1499 2017-05-08 Jason Merrill <jason@redhat.com>
1501 * c-opts.c (c_common_post_options): Update defaults for
1502 flag_abi_version and flag_abi_compat_version.
1504 2017-05-05 David Malcolm <dmalcolm@redhat.com>
1506 * c-common.c (c_cpp_error): Replace report_diagnostic
1507 with diagnostic_report_diagnostic.
1509 2017-05-04 Martin Sebor <msebor@redhat.com>
1511 PR translation/80280
1512 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
1513 (handle_weakref_attribute): Same.
1515 2017-05-03 Nathan Sidwell <nathan@acm.org>
1517 Canonicalize canonical type hashing
1518 * c-common.c (complete_array_type): Use type_hash_canon.
1520 2017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
1523 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
1525 (cilk_install_body_pedigree_operations): Likewise.
1526 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
1528 (cilk_gimplify_call_params_in_spawned_fn): Remove.
1529 (cilk_install_body_pedigree_operations): Likewise.
1530 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
1533 2017-04-27 Jakub Jelinek <jakub@redhat.com>
1536 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
1537 flag on non-aggregate element types.
1539 2017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
1541 * c-common.c (c_type_hasher, type_hash_table): Remove.
1542 (c_common_get_alias_set): Remove unreachable code.
1543 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
1545 2017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
1547 * c.opt (Wextra-semi): New C++ warning flag.
1549 2017-04-20 Jakub Jelinek <jakub@redhat.com>
1552 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
1554 2017-04-18 Jakub Jelinek <jakub@redhat.com>
1558 * c-common.c (c_common_type_for_mode): Don't handle
1559 widest_*_literal_type_node here.
1560 c_common_signed_or_unsigned_type): Likewise.
1561 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
1562 to *intTI_type_node or *intDI_type_node depending on whether
1563 TImode is supported by the target or not.
1565 2017-04-10 Martin Liska <mliska@suse.cz>
1568 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
1569 doing an UBSAN check.
1571 2017-04-03 Jonathan Wakely <jwakely@redhat.com>
1573 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
1575 2017-03-31 Jakub Jelinek <jakub@redhat.com>
1578 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
1580 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
1581 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
1584 2017-03-31 David Malcolm <dmalcolm@redhat.com>
1586 PR documentation/78732
1587 * c.opt (Wendif-labels): Fix description to refer to
1588 #else rather than #elif.
1590 2017-03-31 Jakub Jelinek <jakub@redhat.com>
1593 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
1594 * c-common.c (c_common_reswords): Add __is_aggregate trait.
1596 2017-03-27 Jakub Jelinek <jakub@redhat.com>
1599 * c-common.c (c_common_mark_addressable_vec): Don't set
1600 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
1602 2017-03-21 Martin Sebor <msebor@redhat.com>
1605 * c-common.c (set_underlying_type): Mark type used only when
1606 original del is declared unused.
1608 2017-03-10 David Malcolm <dmalcolm@redhat.com>
1610 PR translation/79848
1611 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
1614 2017-03-10 David Malcolm <dmalcolm@redhat.com>
1617 * c-indentation.c (warn_for_misleading_indentation): Remove parens
1618 from inform's message, so that xgettext can locate it.
1620 2017-03-09 Marek Polacek <polacek@redhat.com>
1624 * c-attribs.c (handle_nonnull_attribute): Save the result of default
1625 conversion to the attribute list.
1627 2017-03-09 Martin Liska <mliska@suse.cz>
1629 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
1631 2017-03-03 Jason Merrill <jason@redhat.com>
1633 * c.opt (Wnoexcept-type): New.
1635 2017-03-02 Richard Biener <rguenther@suse.de>
1638 * c-common.c (c_common_mark_addressable_vec): Look through
1641 2017-02-28 Martin Liska <mliska@suse.cz>
1643 * c.opt: Replace space with tabular for options of <number>
1646 2017-02-28 Martin Liska <mliska@suse.cz>
1648 * c.opt: Fix --help=option -Q for options which are of
1651 2017-02-24 Jakub Jelinek <jakub@redhat.com>
1654 * c-common.c (check_function_restrict): New function.
1655 (check_function_arguments): Add FNDECL argument. Call
1656 check_function_restrict if -Wrestrict.
1657 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
1658 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
1659 * c-common.h (check_function_arguments): Add FNDECL argument.
1660 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
1662 2017-02-24 Eric Botcazou <ebotcazou@adacore.com>
1664 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
1665 treatment of parameters with pointer-to-tagged type and tidy up.
1666 (print_ada_methods): Remove the special treatment of C++ static member
1669 2017-02-22 Martin Liska <mliska@suse.cz>
1671 * c.opt: Replace inequality signs with square brackets
1674 2017-02-21 Jakub Jelinek <jakub@redhat.com>
1677 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
1680 2017-02-17 Joseph Myers <joseph@codesourcery.com>
1682 * c-cppbuiltin.c (builtin_define_float_constants): Define
1683 __DECIMAL_DIG__ to the value for long double.
1685 2017-02-15 Marek Polacek <polacek@redhat.com>
1688 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
1689 conversion has occured.
1691 2017-01-24 David Malcolm <dmalcolm@redhat.com>
1693 * c-common.c (c_common_reswords): Add "__RTL".
1694 * c-common.h (enum rid): Add RID_RTL.
1696 2017-01-20 Marek Polacek <polacek@redhat.com>
1699 * c-common.h (do_warn_duplicated_branches_r): Declare.
1700 * c-gimplify.c (c_genericize): Walk the function tree calling
1701 do_warn_duplicated_branches_r.
1702 * c-warn.c (expr_from_macro_expansion_r): New.
1703 (do_warn_duplicated_branches): New.
1704 (do_warn_duplicated_branches_r): New.
1705 * c.opt (Wduplicated-branches): New option.
1707 2017-01-17 David Malcolm <dmalcolm@redhat.com>
1710 * c-indentation.c (warn_for_misleading_indentation): Use the past
1711 subjunctive in the note.
1713 2017-01-17 Aldy Hernandez <aldyh@redhat.com>
1716 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
1717 start type to integer_type.
1719 2017-01-16 Jakub Jelinek <jakub@redhat.com>
1722 * c.opt (gen-decls): Add Driver flag.
1724 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
1727 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
1730 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
1732 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
1735 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
1737 2017-01-12 Martin Sebor <msebor@redhat.com>
1739 (-Wformat-overflow): ...to this.
1741 2017-01-11 Martin Sebor <msebor@redhat.com>
1744 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
1745 Also enable for LTO.
1747 2017-01-10 Jason Merrill <jason@redhat.com>
1749 Implement P0195R2, C++17 variadic using.
1750 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
1752 2017-01-09 Jakub Jelinek <jakub@redhat.com>
1754 PR translation/79019
1755 PR translation/79020
1756 * c.opt (Wnormalized=): Fix typo in description.
1758 2017-01-08 Martin Sebor <msebor@redhat.com>
1761 * c.opt (-Wformat-truncation): New option.
1763 2017-01-06 Alexandre Oliva <aoliva@redhat.com>
1765 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
1766 value to unsigned short to fit in 4 hex digits without
1769 2017-01-05 Eric Botcazou <ebotcazou@adacore.com>
1771 * c.opt (fsso-struct): Add 'native' value.
1773 2017-01-05 Martin Liska <mliska@suse.cz>
1776 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
1779 2017-01-04 Marek Polacek <polacek@redhat.com>
1782 * c.opt (Wpointer-compare): New option.
1784 2017-01-04 Jakub Jelinek <jakub@redhat.com>
1787 * c.opt (fsso-struct=): Add RejectNegative.
1789 2017-01-01 Jakub Jelinek <jakub@redhat.com>
1791 Update copyright years.
1793 2016-12-29 Martin Liska <mliska@suse.cz>
1796 * c.opt (strong-eval-order): Add RejectNegative keyword.
1798 2016-12-22 Jason Merrill <jason@redhat.com>
1800 Implement P0522R0, matching of template template arguments.
1801 * c-cppbuiltin.c (c_cpp_builtins): Define
1802 __cpp_template_template_args.
1804 2016-12-21 Jakub Jelinek <jakub@redhat.com>
1807 * c-common.c (struct nonnull_arg_ctx): New type.
1808 (check_function_nonnull): Return bool instead of void. Use
1809 nonnull_arg_ctx as context rather than just location_t.
1810 (check_nonnull_arg): Adjust for the new context type, set
1811 warned_p to true if a warning has been diagnosed.
1812 (check_function_arguments): Return bool instead of void.
1813 * c-common.h (check_function_arguments): Adjust prototype.
1815 2016-12-21 Jason Merrill <jason@redhat.com>
1817 * c.opt (-fnew-ttp-matching): New flag.
1818 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
1820 2016-12-14 Martin Jambor <mjambor@suse.cz>
1822 * c-omp.c: Include omp-general.h instead of omp-low.h.
1823 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
1826 2016-12-14 Martin Sebor <msebor@redhat.com>
1829 * c-common.c (check_nonnull_arg): Disable when optimization
1832 2016-12-12 Marek Polacek <polacek@redhat.com>
1835 * c-common.c (attribute_fallthrough_p): Return false for
1838 2016-12-08 Martin Sebor <msebor@redhat.com>
1841 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
1843 2016-12-08 Martin Sebor <msebor@redhat.com>
1846 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
1849 2016-12-07 Martin Sebor <msebor@redhat.com>
1855 * c.opt (-Wstringop-overflow): New option.
1857 2016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
1859 * c-attribs.c (asan odr indicator): New attribute.
1860 (handle_asan_odr_indicator_attribute): New function.
1862 2016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1864 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
1867 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
1869 * c-common.c (excess_precision_mode_join): New.
1870 (c_ts18661_flt_eval_method): New.
1871 (c_c11_flt_eval_method): Likewise.
1872 (c_flt_eval_method): Likewise.
1873 * c-common.h (excess_precision_mode_join): New.
1874 (c_flt_eval_method): Likewise.
1875 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
1876 (cpp_iec_559_value): Call it.
1877 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
1878 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
1879 __FLT_EVAL_METHOD_TS_18661_3__.
1881 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
1883 * c-opts.c (c_common_post_options): Add logic to handle the default
1884 case for -fpermitted-flt-eval-methods.
1886 2016-11-23 Paolo Bonzini <bonzini@gnu.org>
1888 * c.opt (Wexpansion-to-defined): New.
1890 2016-11-23 Jakub Jelinek <jakub@redhat.com>
1893 * c-pragma.c (handle_pragma_target): Don't replace
1894 current_target_pragma, but chainon the new args to the current one.
1896 2016-11-22 Nathan Sidwell <nathan@acm.org>
1898 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
1899 indentation and formatting.
1901 2016-11-21 Martin Sebor <msebor@redhat.com>
1903 * c.opt (-fprintf-return-value): Enable by default.
1905 2016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
1908 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
1909 * c-common.c (c_common_nodes_and_builtins): Initialize
1910 const_tm_ptr_type_node.
1912 2016-11-16 Marek Polacek <polacek@redhat.com>
1915 * c-common.c (c_add_case_label): Turn error_at calls into inform.
1917 2016-11-14 Jakub Jelinek <jakub@redhat.com>
1919 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
1921 2016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
1922 Richard Biener <rguenther@suse.de>
1924 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
1925 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
1926 * c.opt (fgimple): New option.
1928 2016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1931 * c-common.h (warn_for_restrict): Declare.
1932 * c-warn.c: Include gcc-rich-location.h.
1933 (warn_for_restrict): New function.
1934 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
1935 (gcc_cdiag_char_table): Likewise.
1936 (gcc_cxxdiag_char_table): Likewise.
1937 * c.opt (Wrestrict): New option.
1939 2016-11-13 Eric Botcazou <ebotcazou@adacore.com>
1941 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
1942 for nested types only if the type is a record or union and dump SLOC.
1944 2016-11-09 Jason Merrill <jason@redhat.com>
1946 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
1948 2016-11-09 Jakub Jelinek <jakub@redhat.com>
1950 * c-ubsan.c (ubsan_instrument_shift): Handle split
1951 -fsanitize=shift-base and -fsanitize=shift-exponent.
1953 2016-11-07 Jason Merrill <jason@redhat.com>
1955 * c.opt (Wc++1z-compat): New.
1956 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
1958 2016-11-07 Martin Liska <mliska@suse.cz>
1960 * c-warn.c (warn_for_unused_label): Save all labels used
1961 in goto or in &label.
1963 2016-11-03 Jason Merrill <jason@redhat.com>
1965 * c-cppbuiltin.c (c_cpp_builtins): Correct
1966 __cpp_inheriting_constructors.
1968 2016-11-01 Jason Merrill <jason@redhat.com>
1970 * c-cppbuiltin.c (c_cpp_builtins): Update
1971 __cpp_inheriting_constructors.
1973 * c.opt (-fnew-inheriting-ctors): New.
1974 * c-opts.c: Default to on for ABI 11+.
1976 2016-10-31 Jakub Jelinek <jakub@redhat.com>
1979 * c.opt (fext-numeric-literals): Add Var and Init.
1980 * c-opts.c (c_common_handle_option): Don't clear
1981 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
1982 (c_common_post_options): Clear it here if not set
1985 2016-10-28 Aldy Hernandez <aldyh@redhat.com>
1988 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
1991 2016-10-25 Jakub Jelinek <jakub@redhat.com>
1993 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
1994 * c-common.c (c_common_reswords): Add __builtin_launder.
1996 2016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
1998 * c-common.c (c_common_truthvalue_conversion): Warn for
1999 multiplications in boolean context. Fix the quoting of '<<' and '<'
2000 in the shift warning.
2002 2016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
2004 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
2006 2016-10-20 Jason Merrill <jason@redhat.com>
2008 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
2010 2016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
2012 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
2013 integer shift ops in boolean context.
2015 2016-10-18 Aldy Hernandez <aldyh@redhat.com>
2017 * c.opt (Walloca): New.
2018 (Walloca-larger-than=): New.
2019 (Wvla-larger-than=): New.
2021 2016-10-17 Marek Polacek <polacek@redhat.com>
2023 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
2024 Return immediately when finding a match.
2025 (warn_tautological_cmp): Remove a boolean variable that is no longer
2028 2016-10-17 Marek Polacek <polacek@redhat.com>
2030 * c-attribs.c: New file.
2031 * c-common.c: Move attributes handling to c-attribs.c.
2032 (get_nonnull_operand): No longer static.
2033 * c-common.h: Move the declarations from c-attribs.c to its own section.
2035 2016-10-14 Jason Merrill <jason@redhat.com>
2037 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
2038 and __cpp_deduction_guides.
2040 2016-10-13 Jason Merrill <jason@redhat.com>
2042 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
2044 2016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
2046 * c-cppbuiltin.c: Include memmodel.h.
2047 * c-opts.c: Likewise.
2048 * c-pragma.c: Likewise.
2049 * c-warn.c: Likewise.
2051 2016-10-12 Jakub Jelinek <jakub@redhat.com>
2053 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
2054 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
2055 * c-opts.c (sanitize_cpp_opts): Initialize
2056 cpp_opts->cpp_warn_implicit_fallthrough.
2058 2016-10-11 Marek Polacek <polacek@redhat.com>
2060 * c-common.c (warning_candidate_p): Change the return type to bool
2061 and return true/false instead of 1/0.
2062 (vector_mode_valid_p): Likewise.
2064 2016-10-11 Marek Polacek <polacek@redhat.com>
2066 * c-common.c (fold_for_warn): No longer static.
2067 (bool_promoted_to_int_p): Likewise.
2068 (c_common_get_narrower): Likewise.
2069 (constant_expression_warning): Move to c-warn.c.
2070 (constant_expression_error): Likewise.
2071 (overflow_warning): Likewise.
2072 (warn_logical_operator): Likewise.
2073 (find_array_ref_with_const_idx_r): Likewise.
2074 (warn_tautological_cmp): Likewise.
2075 (expr_has_boolean_operands_p): Likewise.
2076 (warn_logical_not_parentheses): Likewise.
2077 (warn_if_unused_value): Likewise.
2078 (strict_aliasing_warning): Likewise.
2079 (sizeof_pointer_memaccess_warning): Likewise.
2080 (check_main_parameter_types): Likewise.
2081 (conversion_warning): Likewise.
2082 (warnings_for_convert_and_check): Likewise.
2083 (match_case_to_enum_1): Likewise.
2084 (match_case_to_enum): Likewise.
2085 (c_do_switch_warnings): Likewise.
2086 (warn_for_omitted_condop): Likewise.
2087 (readonly_error): Likewise.
2088 (lvalue_error): Likewise.
2089 (invalid_indirection_error): Likewise.
2090 (warn_array_subscript_with_type_char): Likewise.
2091 (warn_about_parentheses): Likewise.
2092 (warn_for_unused_label): Likewise.
2093 (warn_for_div_by_zero): Likewise.
2094 (warn_for_memset): Likewise.
2095 (warn_for_sign_compare): Likewise.
2096 (do_warn_double_promotion): Likewise.
2097 (do_warn_unused_parameter): Likewise.
2098 (record_locally_defined_typedef): Likewise.
2099 (maybe_record_typedef_use): Likewise.
2100 (maybe_warn_unused_local_typedefs): Likewise.
2101 (maybe_warn_bool_compare): Likewise.
2102 (maybe_warn_shift_overflow): Likewise.
2103 (warn_duplicated_cond_add_or_warn): Likewise.
2104 (diagnose_mismatched_attributes): Likewise.
2105 * c-common.h: Move the declarations from c-warn.c to its own section.
2106 * c-warn.c: New file.
2108 2016-10-08 Jason Merrill <jason@redhat.com>
2110 * c-common.c (c_common_truthvalue_conversion): Don't distribute
2111 into COND_EXPR in C++.
2113 2016-10-08 Jakub Jelinek <jakub@redhat.com>
2115 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
2116 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
2117 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
2119 2016-10-07 Jakub Jelinek <jakub@redhat.com>
2121 Implement LWG2296 helper intrinsic
2122 * c-common.h (enum rid): Add RID_ADDRESSOF.
2123 * c-common.c (c_common_reswords): Add __builtin_addressof.
2125 2016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
2128 * c-common.c (c_common_truthvalue_conversion): Warn also for
2129 suspicious enum values in boolean context.
2131 2016-10-06 Jakub Jelinek <jakub@redhat.com>
2133 Implement P0258R2 - helper for C++17
2134 std::has_unique_object_representations trait
2135 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
2136 * c-common.c (c_common_reswords): Add
2137 __has_unique_object_representations.
2139 2016-10-05 Jakub Jelinek <jakub@redhat.com>
2142 * c-ubsan.c (ubsan_instrument_return): Don't call
2143 initialize_sanitizer_builtins here.
2145 2016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
2147 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
2148 conditional expression in boolean context when only one arm is
2151 2016-10-05 Jakub Jelinek <jakub@redhat.com>
2154 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
2157 * c-common.c (c_common_reswords): Update comment for C++11.
2159 2016-10-04 Jason Merrill <jason@redhat.com>
2161 * c-common.c (make_tree_vector_from_ctor): New.
2162 * c-common.h: Declare it.
2164 2016-10-04 Jakub Jelinek <jakub@redhat.com>
2166 * c-cppbuiltin.c (c_cpp_builtins): Don't define
2167 __LIBGCC_JCR_SECTION_NAME__.
2169 2016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
2171 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
2172 left shift in boolean context.
2174 2016-09-29 Jakub Jelinek <jakub@redhat.com>
2176 Implement P0001R1 - C++17 removal of register storage class specifier
2177 * c.opt (Wregister): New warning.
2178 * c-opts.c (c_common_post_options): Enable -Wregister by
2181 2016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
2183 * c-opts.c (c_common_post_options): Remove special case for
2184 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
2187 2016-09-27 Jakub Jelinek <jakub@redhat.com>
2189 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
2192 * c-ada-spec.c (print_ada_declaration): Remove break after return.
2194 2016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
2196 * c-common.c: Include memmodel.h.
2198 2016-09-26 Marek Polacek <polacek@redhat.com>
2200 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
2202 2016-09-26 Marek Polacek <polacek@redhat.com>
2205 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
2206 (handle_fallthrough_attribute): New function.
2207 (attribute_fallthrough_p): New function.
2208 * c-common.h (attribute_fallthrough_p): Declare.
2210 2016-09-24 Marek Polacek <polacek@redhat.com>
2213 * c.opt (Wbool-operation): New.
2215 2016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
2217 * c-common.c (c_common_truthvalue_conversion): Inhibit
2218 Wint-in-bool-context warning with from_macro_definition_at.
2219 Mention the expression will always evaluate to true.
2221 2016-09-21 Martin Sebor <msebor@redhat.com>
2224 * c.opt (fprintf-return-value): Temporarily initialize to zero
2225 to unblock bootstrap failures.
2227 2016-09-21 Jakub Jelinek <jakub@redhat.com>
2230 * c.opt (Waligned-new=): Add RejectNegative.
2231 (faligned-new=): Likewise. Spelling fix - change
2232 aligned_new_threshhold to aligned_new_threshold.
2233 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
2234 to aligned_new_threshold.
2236 2016-09-20 Martin Sebor <msebor@redhat.com>
2239 * c.opt: Add -Wformat-length and -fprintf-return-value.
2241 2016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
2244 * c.opt (Wint-in-bool-context): New warning.
2245 * c-common.c (c_common_truthvalue_conversion): Warn on integer
2246 constants in boolean context.
2248 2016-09-19 Joseph Myers <joseph@codesourcery.com>
2250 * c-common.c (max_align_t_align): Also consider alignment of
2253 2016-09-15 Jason Merrill <jason@redhat.com>
2255 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
2258 2016-09-14 Jason Merrill <jason@redhat.com>
2260 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
2261 limit FIELD_DECL, either.
2263 2016-09-14 Marek Polacek <polacek@redhat.com>
2265 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
2266 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
2267 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
2269 2016-09-13 David Malcolm <dmalcolm@redhat.com>
2271 * c-common.c (warn_logical_not_parentheses): Replace
2272 rich_location::add_fixit_insert calls with add_fixit_insert_before
2273 and add_fixit_insert_after, eliminating the "next_loc" calculation.
2275 2016-09-13 Jason Merrill <jason@redhat.com>
2276 Tom de Vries <tom@codesourcery.com>
2279 * c-common.c (set_underlying_type): Don't treat array as builtin type.
2281 2016-09-13 Jason Merrill <jason@redhat.com>
2283 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
2286 2016-09-12 Jason Merrill <jason@redhat.com>
2288 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
2289 bit/byte confusion, allow large alignment for types.
2291 2016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
2294 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
2296 2016-09-12 David Malcolm <dmalcolm@redhat.com>
2299 * c-format.c (argument_parser::check_argument_type): Add params
2300 "type_start" and "conversion_char". Use the former to generate
2301 offset_to_type_start and pass it and conversion_char to
2303 (check_format_info_main): Capture the start of the type
2304 information as "type_start", and pass it an format_char
2305 to arg_parser.check_argument_type.
2306 (check_format_types): Provide an example in the leading comment.
2307 Add params "offset_to_type_start" and "conversion_char"; pass
2308 them to format_type_warning calls.
2309 (test_get_modifier_for_format_len): Likewise.
2310 (matching_type_p): New function.
2311 (get_format_for_type): Add param "conversion_char" and move
2312 implementation into...
2313 (get_format_for_type_1): ...new function, called twice.
2314 Use new function matching_type_p rather than checking for
2315 TYPE_CANONICAL equality.
2316 (get_corrected_substring): New function.
2317 (format_type_warning): Provide an example in the leading comment.
2318 Add params "offset_to_type_start" and "conversion_char". Replace
2319 call to get_format_for_type with call to get_corrected_substring
2320 and move rejection of hints for widths/precisions there.
2321 (assert_format_for_type_streq): Add param "conversion_char".
2322 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
2323 (test_get_format_for_type_printf): Add conversion chars to the
2324 tests, adding coverage for various combinations of integer
2325 vs double conversions, and for preserving octal and hexadecimal
2327 (test_get_format_for_type_scanf): Add conversion chars to the
2330 2016-09-10 Tom de Vries <tom@codesourcery.com>
2333 * c-common.c (build_va_arg): Handle more strict
2334 targetm.canonical_va_list_type. Replace first argument type error with
2337 2016-09-09 Martin Sebor <msebor@redhat.com>
2341 * c-format.c (argument_parser::find_format_char_info): Use %qc
2342 format directive unconditionally.
2344 2016-09-09 Jason Merrill <jason@redhat.com>
2346 Implement C++17 new of over-aligned types.
2347 * c.opt: Add -faligned-new and -Waligned-new.
2348 * c-common.c (max_align_t_align): Split out from...
2349 (cxx_fundamental_alignment_p): ...here.
2350 * c-common.h: Declare it.
2351 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
2353 2016-09-09 Joseph Myers <joseph@codesourcery.com>
2355 * c-cppbuiltin.c (builtin_define_type_width): New function.
2356 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
2359 2016-09-07 David Malcolm <dmalcolm@redhat.com>
2361 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
2363 (substring_loc::get_location): Move to substring-locations.c,
2364 keeping implementation as...
2365 (c_get_substring_location): New function, from the above, reworked
2366 to use accessors rather than member lookup.
2367 * c-common.h (class substring_loc): Move to substring-locations.h,
2368 replacing with a forward decl.
2369 (c_get_substring_location): New decl.
2370 * c-format.c: Include "substring-locations.h".
2371 (format_warning_va): Move to substring-locations.c.
2372 (format_warning_at_substring): Likewise.
2374 2016-09-06 Martin Sebor <msebor@redhat.com>
2377 * c-format.c (check_function_format): Avoid issuing warnings for
2378 functions unless they call format functions with non-constant
2381 2016-09-06 Richard Biener <rguenther@suse.de>
2384 * c-common.c (c_common_mark_addressable_vec): Handle
2385 COMPOUND_LITERAL_EXPR.
2387 2016-09-05 Marek Polacek <polacek@redhat.com>
2390 * c-common.c (bool_promoted_to_int_p): New function.
2391 (expr_has_boolean_operands_p): New function.
2392 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
2393 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
2395 2016-09-04 Tom de Vries <tom@codesourcery.com>
2398 2016-08-29 Tom de Vries <tom@codesourcery.com>
2400 * c-common.c (build_va_arg): Replace first argument type error
2403 2016-09-02 Jakub Jelinek <jakub@redhat.com>
2406 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
2407 (c_finish_omp_for): Reject _Atomic qualified iterators.
2409 2016-09-01 Martin Sebor <msebor@redhat.com>
2411 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
2412 size to guarantee it fits the output of the formatted function
2413 regardless of its arguments.
2415 2016-09-01 Marek Polacek <polacek@redhat.com>
2418 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
2421 2016-08-29 Marek Polacek <polacek@redhat.com>
2424 * c-common.c (warn_logical_not_parentheses): Don't warn for
2425 a comparison or a logical operator.
2427 2016-08-29 Tom de Vries <tom@codesourcery.com>
2429 * c-common.c (build_va_arg): Fix type comparison assert.
2431 2016-08-29 Tom de Vries <tom@codesourcery.com>
2433 * c-common.c (build_va_arg): Replace first argument type error
2436 2016-08-29 Tom de Vries <tom@codesourcery.com>
2439 * c-common.c (build_va_arg): Add first argument error. Build va_arg
2440 with error_mark_node as va_list instead of with illegal va_list.
2442 2016-08-25 Marek Polacek <polacek@redhat.com>
2443 David Malcolm <dmalcolm@redhat.com>
2445 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
2446 * c-common.h (warn_logical_not_parentheses): Update declaration.
2448 2016-08-22 Marek Polacek <polacek@redhat.com>
2451 * c-common.c (warn_for_memset): Check type for null.
2453 2016-08-22 Joseph Myers <joseph@codesourcery.com>
2455 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
2456 _FloatNx types for suffixes for built-in functions.
2458 2016-08-19 Joseph Myers <joseph@codesourcery.com>
2461 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
2462 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
2463 (RID_FLOAT128X): New enum rid values.
2464 (CASE_RID_FLOATN_NX): New macro.
2465 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
2467 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
2468 corresponding complex types.
2469 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
2470 _FloatNx and corresponding complex types.
2471 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
2472 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
2473 and _FloatNx types for the widest type for determining
2474 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
2475 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
2476 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
2478 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
2480 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
2483 2016-08-18 David Malcolm <dmalcolm@redhat.com>
2485 * c-opts.c (c_diagnostic_finalizer): Update for change to
2486 diagnostic_show_locus.
2488 2016-08-18 David Malcolm <dmalcolm@redhat.com>
2490 * c-common.c: Include "spellcheck.h".
2491 (cb_get_suggestion): New function.
2492 * c-common.h (cb_get_suggestion): New decl.
2493 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
2496 2016-08-18 Marek Polacek <polacek@redhat.com>
2499 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
2502 2016-08-16 David Malcolm <dmalcolm@redhat.com>
2505 * c-common.c (substring_loc::get_range): Rename to...
2506 (substring_loc::get_location): ...this, converting param from a
2507 source_range * to a location_t *. Call
2508 get_source_location_for_substring rather than
2509 get_source_range_for_substring, and pass in m_caret_idx.
2510 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
2511 (substring_loc::get_range): Replace with...
2512 (substring_loc::get_location): ...this.
2513 (substring_loc::set_caret_index): New method.
2514 (substring_loc): Add field m_caret_idx.
2515 * c-format.c (format_warning_va): Update for above changes.
2516 Rename local "substring_loc" to "fmt_substring_loc" to avoid
2517 clashing with type name.
2518 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
2519 (check_argument_type): Likewise.
2520 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
2521 Use a copy when emitting warnings, setting the caret index from TYPE.
2523 2016-08-16 Eric Botcazou <ebotcazou@adacore.com>
2524 Arnaud Charlet <charlet@adacore.com>
2526 * c-ada-spec.c (dump_number): New function.
2527 (handle_escape_character): Likewise.
2528 (print_ada_macros): Add handling of constant integers and strings.
2530 2016-08-12 Marek Polacek <polacek@redhat.com>
2533 * c-common.c (scalar_to_vector): Adjust fall through comment.
2534 * c-opts.c (c_common_handle_option): Likewise.
2535 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
2536 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
2537 fall through comment.
2538 * cilk.c (extract_free_variables): Add FALLTHRU.
2540 2016-08-10 Jason Merrill <jason@redhat.com>
2542 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
2544 2016-08-09 Jason Merrill <jason@redhat.com>
2546 * c-common.c (c_common_attribute_table): vector_size affects type
2549 2016-08-09 Marek Polacek <polacek@redhat.com>
2552 * c-ada-spec.c (dump_generic_ada_node): Add return.
2554 2016-08-09 Jason Merrill <jason@redhat.com>
2556 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
2557 C++17 constexpr lambdas.
2559 2016-08-08 David Malcolm <dmalcolm@redhat.com>
2562 * c-common.h (selftest::c_format_c_tests): New declaration.
2563 (selftest::run_c_tests): New declaration.
2564 * c-format.c: Include "selftest.h.
2565 (format_warning_va): Add param "corrected_substring" and use
2566 it to add a replacement fix-it hint.
2567 (format_warning_at_substring): Likewise.
2568 (format_warning_at_char): Update for new param of
2570 (argument_parser::check_argument_type): Pass "fki" to
2572 (check_format_types): Add param "fki" and pass it to
2573 format_type_warning.
2574 (deref_n_times): New function.
2575 (get_modifier_for_format_len): New function.
2576 (selftest::test_get_modifier_for_format_len): New function.
2577 (get_format_for_type): New function.
2578 (format_type_warning): Add param "fki" and use it to attempt
2579 to provide hints for argument types when calling
2580 format_warning_at_substring.
2581 (selftest::get_info): New function.
2582 (selftest::assert_format_for_type_streq): New function.
2583 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
2584 (selftest::test_get_format_for_type_printf): New function.
2585 (selftest::test_get_format_for_type_scanf): New function.
2586 (selftest::c_format_c_tests): New function.
2588 2016-08-08 David Malcolm <dmalcolm@redhat.com>
2591 * c-format.c: Include "diagnostic.h".
2592 (location_column_from_byte_offset): Delete.
2593 (location_from_offset): Delete.
2594 (format_warning_va): New function.
2595 (format_warning_at_substring): New function.
2596 (format_warning_at_char): New function.
2597 (check_format_arg): Capture location of format_tree and pass to
2598 check_format_info_main.
2599 (argument_parser): Add fields "start_of_this_format" and
2600 "format_string_cst".
2601 (flag_chars_t::validate): Add param "format_string_cst". Convert
2602 warning_at call using location_from_offset to call to
2603 format_warning_at_char.
2604 (argument_parser::argument_parser): Add param "format_string_cst_"
2605 and use use it to initialize field "format_string_cst".
2606 Initialize new field "start_of_this_format".
2607 (argument_parser::read_format_flags): Convert warning_at call
2608 using location_from_offset to a call to format_warning_at_char.
2609 (argument_parser::read_any_format_left_precision): Likewise.
2610 (argument_parser::read_any_format_precision): Likewise.
2611 (argument_parser::read_any_other_modifier): Likewise.
2612 (argument_parser::find_format_char_info): Likewise, in three places.
2613 (argument_parser::parse_any_scan_set): Likewise, in one place.
2614 (argument_parser::handle_conversions): Likewise, in two places.
2615 (argument_parser::check_argument_type): Add param "fmt_param_loc"
2616 and use it to make a substring_loc. Pass the latter to
2618 (check_format_info_main): Add params "fmt_param_loc" and
2619 "format_string_cst". Convert warning_at calls using
2620 location_from_offset to calls to format_warning_at_char. Pass the
2621 new params to the arg_parser ctor. Pass "format_string_cst" to
2622 flag_chars.validate. Pass "fmt_param_loc" to
2623 arg_parser.check_argument_type.
2624 (check_format_types): Convert first param from a location_t
2625 to a const substring_loc & and rename to "fmt_loc". Attempt
2626 to extract the range of the relevant parameter and pass it
2627 to format_type_warning.
2628 (format_type_warning): Convert first param from a location_t
2629 to a const substring_loc & and rename to "fmt_loc". Add
2630 params "param_range" and "type". Replace calls to warning_at
2631 with calls to format_warning_at_substring.
2633 2016-08-08 David Malcolm <dmalcolm@redhat.com>
2635 * c-format.c (class flag_chars_t): New class.
2636 (struct length_modifier): New struct.
2637 (class argument_parser): New class.
2638 (flag_chars_t::flag_chars_t): New ctor.
2639 (flag_chars_t::has_char_p): New method.
2640 (flag_chars_t::add_char): New method.
2641 (flag_chars_t::validate): New method.
2642 (flag_chars_t::get_alloc_flag): New method.
2643 (flag_chars_t::assignment_suppression_p): New method.
2644 (argument_parser::argument_parser): New ctor.
2645 (argument_parser::read_any_dollar): New method.
2646 (argument_parser::read_format_flags): New method.
2647 (argument_parser::read_any_format_width): New method.
2648 (argument_parser::read_any_format_left_precision): New method.
2649 (argument_parser::read_any_format_precision): New method.
2650 (argument_parser::handle_alloc_chars): New method.
2651 (argument_parser::read_any_length_modifier): New method.
2652 (argument_parser::read_any_other_modifier): New method.
2653 (argument_parser::find_format_char_info): New method.
2654 (argument_parser::validate_flag_pairs): New method.
2655 (argument_parser::give_y2k_warnings): New method.
2656 (argument_parser::parse_any_scan_set): New method.
2657 (argument_parser::handle_conversions): New method.
2658 (argument_parser::check_argument_type): New method.
2659 (check_format_info_main): Introduce classes argument_parser
2660 and flag_chars_t, moving the code within the loop into methods
2661 of these classes. Make various locals "const".
2663 2016-08-05 David Malcolm <dmalcolm@redhat.com>
2665 * c-common.c: Include "substring-locations.h".
2666 (get_cpp_ttype_from_string_type): New function.
2667 (g_string_concat_db): New global.
2668 (substring_loc::get_range): New method.
2669 * c-common.h (g_string_concat_db): New declaration.
2670 (class substring_loc): New class.
2671 * c-lex.c (lex_string): When concatenating strings, capture the
2672 locations of all tokens using a new obstack, and record the
2673 concatenation locations within g_string_concat_db.
2674 * c-opts.c (c_common_init_options): Construct g_string_concat_db
2677 2016-07-29 Marek Polacek <polacek@redhat.com>
2680 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
2681 parentheses warning.
2684 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
2686 2016-07-28 Martin Liska <mliska@suse.cz>
2688 PR gcov-profile/68025
2689 * c-common.c (handle_no_profile_instrument_function_attribute):
2691 2016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
2693 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
2696 2016-07-25 Jason Merrill <jason@redhat.com>
2699 * c.opt (fconstexpr-loop-limit): New.
2701 2016-07-22 Martin Sebor <msebor@redhat.com>
2704 * c-common.c (resolve_overloaded_builtin): Avoid converting
2705 __atomic_compare_exchange_n return type to that of what its
2706 first argument points to.
2708 2016-07-22 Uros Bizjak <ubizjak@gmail.com>
2710 * c-common.c: Use HOST_WIDE_INT_M1U instead of
2711 ~(unsigned HOST_WIDE_INT) 0.
2713 2016-07-22 Martin Liska <mliska@suse.cz>
2715 PR gcov-profile/69028
2716 PR gcov-profile/62047
2717 * cilk.c (create_cilk_helper_decl): Set location of a new decl
2718 to the current_function_decl.
2720 2016-07-21 Jason Merrill <jason@redhat.com>
2723 * c-common.c (c_common_truthvalue_conversion): Check
2724 c_inhibit_evaluation_warnings for warning about address of
2727 2016-07-20 David Malcolm <dmalcolm@redhat.com>
2729 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
2732 2016-07-15 Jason Merrill <jason@redhat.com>
2734 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
2736 2016-07-15 Jakub Jelinek <jakub@redhat.com>
2739 * c-common.h (enum lookup_name_fuzzy_kind): Add
2740 FUZZY_LOOKUP_FUNCTION_NAME.
2742 2016-07-08 Jason Merrill <jason@redhat.com>
2744 P0145: Refining Expression Order for C++.
2745 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
2748 2016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
2751 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
2753 2016-06-29 Thomas Schwinge <thomas@codesourcery.com>
2755 * c-pragma.h (enum pragma_kind): Rename
2756 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
2759 2016-06-29 Richard Biener <rguenther@suse.de>
2762 * c-common.c (c_common_get_alias_set): Remove union type punning case.
2764 2016-06-24 Jason Merrill <jason@redhat.com>
2766 P0145R2: Refining Expression Order for C++.
2767 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
2770 2016-06-24 Jakub Jelinek <jakub@redhat.com>
2772 * c-common.c (check_builtin_function_arguments): Require last
2773 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
2774 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
2775 if the last argument is pointer to enumerated or boolean type.
2777 2016-06-22 David Malcolm <dmalcolm@redhat.com>
2780 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
2781 (lookup_name_fuzzy): New prototype.
2783 2016-06-21 John David Anglin <danglin@gcc.gnu.org>
2785 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
2787 2016-06-14 Jason Merrill <jason@redhat.com>
2789 P0145R2: Refining Expression Order for C++.
2790 * c.opt (fargs-in-order): New.
2791 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
2793 2016-06-13 Jakub Jelinek <jakub@redhat.com>
2796 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
2797 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
2799 PR preprocessor/71183
2800 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
2801 to cb_get_source_date_epoch.
2803 2016-06-10 Jakub Jelinek <jakub@redhat.com>
2806 * c.opt (Wpsabi): Add Warning flag.
2808 2016-06-10 Martin Sebor <msebor@redhat.com>
2811 * c-common.c (handle_nonnull_attribute): Accept
2812 the nonnull attribute in type-generic builtins.
2814 2016-06-09 Martin Sebor <msebor@redhat.com>
2817 * c-common.c (builtin_function_validate_nargs): Make text of error
2818 message consistent with others like it.
2820 2016-06-08 Martin Sebor <msebor@redhat.com>
2821 Jakub Jelinek <jakub@redhat.com>
2825 * c-common.c (check_builtin_function_arguments): Handle
2826 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
2828 2016-06-08 Richard Biener <rguenther@suse.de>
2830 * c-common.c (parse_optimize_options): Improve diagnostic messages.
2832 2016-06-07 Richard Biener <rguenther@suse.de>
2835 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
2836 options and warn about others.
2838 2016-06-01 Eduard Sanou <dhole@openmailbox.org>
2840 * c-common.c (get_source_date_epoch): Rename to
2841 cb_get_source_date_epoch.
2842 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
2843 message when the parsing fails. Use error_at instead of fatal_error.
2844 * c-common.h (get_source_date_epoch): Rename to
2845 cb_get_source_date_epoch.
2846 * c-common.h (cb_get_source_date_epoch): Prototype.
2847 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
2848 * c-common.h (c_omp_region_type): Remove trailing comma.
2849 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
2850 * c-lex.c (c_lex_with_flags): Remove initialization of
2851 pfile->source_date_epoch.
2853 2016-05-30 Jakub Jelinek <jakub@redhat.com>
2856 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
2857 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
2858 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
2859 instead of C_OMP_CLAUSE_SPLIT_FOR.
2861 2016-05-24 Richard Biener <rguenther@suse.de>
2865 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
2866 (convert_vector_to_array_for_subscript): ... this.
2867 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
2868 VIEW_CONVERT_EXPR to an array type. Rename to ...
2869 (convert_vector_to_array_for_subscript): ... this.
2871 2016-05-12 Marek Polacek <polacek@redhat.com>
2874 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
2875 size_in_bytes and pass LOC to it.
2877 2016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
2880 * c.opt (Wduplicate-decl-specifier): New option.
2882 2016-05-11 Marek Polacek <polacek@redhat.com>
2885 * c-common.c (diagnose_mismatched_attributes): New function.
2886 * c-common.h (diagnose_mismatched_attributes): Declare.
2888 2016-05-04 Marek Polacek <polacek@redhat.com>
2890 * c.opt (Wdangling-else): New option.
2892 2016-05-03 Marek Polacek <polacek@redhat.com>
2895 * c-common.c (builtin_function_validate_nargs): Add location
2897 (check_builtin_function_arguments): Add location and arguments
2898 parameters. Use them.
2899 * c-common.h (check_builtin_function_arguments): Update declaration.
2901 2016-05-03 Richard Biener <rguenther@suse.de>
2903 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
2904 allow call args to gimplify to SSA names.
2906 2016-05-03 Marek Polacek <polacek@redhat.com>
2908 * c-common.h (enum c_omp_region_type): Remove stray comma.
2910 2016-05-02 Cesar Philippidis <cesar@codesourcery.com>
2912 * c-common.h (enum c_omp_region_type): Define.
2914 2016-05-02 Richard Sandiford <richard.sandiford@arm.com>
2916 * c-common.c (shorten_compare): Use wi::to_wide.
2918 2016-04-29 Cesar Philippidis <cesar@codesourcery.com>
2921 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
2922 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
2923 reduction clauses in acc parallel loops.
2925 2016-04-29 Marek Polacek <polacek@redhat.com>
2928 * c-common.c (warn_for_memset): Check domain before accessing it.
2930 2016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
2933 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
2934 "aligned" attribute.
2936 2016-04-28 Jason Merrill <jason@redhat.com>
2938 * c-lex.c (c_common_has_attribute): Handle nodiscard.
2940 2016-04-28 Eduard Sanou <dhole@openmailbox.org>
2941 Matthias Klose <doko@debian.org>
2943 * c-common.c (get_source_date_epoch): New function, gets the environment
2944 variable SOURCE_DATE_EPOCH and parses it as long long with error
2946 * c-common.h (get_source_date_epoch): Prototype.
2947 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
2949 2015-04-27 Ryan Burn <contact@rnburn.com>
2953 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
2954 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
2956 (cilk_detect_and_unwrap): Corresponding changes.
2957 (extract_free_variables): Don't extract free variables from
2958 AGGR_INIT_EXPR slot.
2959 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
2960 (cilk_recognize_spawn): Likewise.
2962 2016-04-27 Bernd Schmidt <bschmidt@redhat.com>
2964 * c.opt (Wmemset-elt-size): New option.
2965 * c-common.c (warn_for_memset): New function.
2966 * c-common.h (warn_for_memset): Declare.
2968 2016-04-25 Jason Merrill <jason@redhat.com>
2970 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
2972 * c-common.h: Declare it.
2973 * c-lex.c (c_common_has_attribute): Add maybe_unused.
2975 2016-04-22 Jason Merrill <jason@redhat.com>
2977 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
2979 2016-04-20 Ilya Verbin <ilya.verbin@intel.com>
2982 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
2983 * c-common.h (c_finish_cilk_clauses): Remove declaration.
2985 2016-04-18 Michael Matz <matz@suse.de>
2987 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
2990 2016-04-17 Eric Botcazou <ebotcazou@adacore.com>
2992 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
2993 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
2994 to incomplete types.
2995 (dump_nested_type): Remove redundant tests and tidy up.
2996 (print_ada_declaration): Also set TREE_VISITED on the declaration of
2997 a type which is the typedef of an original type.
2999 2016-04-15 Marek Polacek <polacek@redhat.com>
3002 * c-common.c (build_va_arg): Change two asserts into errors and return
3005 2016-04-13 Marek Polacek <polacek@redhat.com>
3008 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
3009 for switch statements, too.
3011 2016-03-28 Jason Merrill <jason@redhat.com>
3013 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
3015 2016-03-23 Marek Polacek <polacek@redhat.com>
3018 * c.opt (Wignored-attributes): New option.
3020 2016-03-22 David Malcolm <dmalcolm@redhat.com>
3023 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
3024 diagnostic text, reversing the order of the warning and note so
3025 that they appear in source order.
3027 2016-03-17 Marek Polacek <polacek@redhat.com>
3030 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
3033 2016-03-14 Jason Merrill <jason@redhat.com>
3035 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
3037 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
3039 2016-03-09 Richard Biener <rguenther@suse.de>
3042 * c-common.c (strict_aliasing_warning): Add back
3043 alias_sets_conflict_p check.
3045 2016-03-08 Jason Merrill <jason@redhat.com>
3047 * c-opts.c (set_std_cxx1z): Don't enable concepts.
3049 2016-03-04 David Malcolm <dmalcolm@redhat.com>
3052 * c-indentation.c (get_visual_column): Move code to determine next
3054 (next_tab_stop): ...this new function.
3055 (line_contains_hash_if): Delete function.
3056 (detect_preprocessor_logic): Delete function.
3057 (get_first_nws_vis_column): New function.
3058 (detect_intervening_unindent): New function.
3059 (should_warn_for_misleading_indentation): Replace call to
3060 detect_preprocessor_logic with a call to
3061 detect_intervening_unindent.
3063 2016-03-04 David Malcolm <dmalcolm@redhat.com>
3066 * c-indentation.c (should_warn_for_misleading_indentation): When
3067 suppressing warnings about cases where the guard and body are on
3068 the same column, only use the first non-whitespace column in place
3069 of the guard token column when dealing with "else" clauses.
3070 When rejecting aligned BODY and NEXT, loosen the requirement
3071 from equality with the first non-whitespace of guard to simply
3072 that they not be indented relative to it.
3074 2016-03-04 Richard Biener <rguenther@suse.de>
3077 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
3078 instead of alias_sets_conflict_p.
3080 2016-03-01 Marek Polacek <polacek@redhat.com>
3083 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
3086 2016-02-22 Martin Sebor <msebor@redhat.com>
3089 * c-common.c (check_builtin_function_arguments): Validate and
3090 reject invalid arguments to __builtin_alloca_with_align.
3092 2016-02-20 Mark Wielaard <mjw@redhat.com>
3095 * c.opt (Wunused-const-variable): Turn into Alias for...
3096 (Wunused-const-variable=): New option.
3098 2016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
3101 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
3103 (c_common_init_options): ...to here.
3104 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
3106 2016-02-19 Jakub Jelinek <jakub@redhat.com>
3109 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
3110 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
3111 flag_preprocess_only.
3113 2016-02-16 Jakub Jelinek <jakub@redhat.com>
3116 * c.opt (Wnonnull-compare): Enable for -Wall.
3118 2016-02-15 Jakub Jelinek <jakub@redhat.com>
3121 * c-common.c (sync_resolve_size): Diagnose too few arguments
3122 even when params is non-NULL empty vector.
3124 2016-02-08 Bernd Schmidt <bschmidt@redhat.com>
3127 * c.opt (fshort-double): Remove.
3129 2016-02-05 Martin Sebor <msebor@redhat.com>
3132 * c.opt (Warning options): Update -Wplacement-new to take
3133 an optional argument.
3135 2016-02-01 Jakub Jelinek <jakub@redhat.com>
3137 PR preprocessor/69543
3139 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
3140 instead of loc to control_warning_option.
3142 2016-02-01 Nathan Sidwell <nathan@codesourcery.com>
3144 * c.opt (fopenacc-dim=): New option.
3146 2016-01-27 Ryan Burn <contact@rnburn.com>
3149 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
3150 gimplify_arg. Removed superfluous post_p argument.
3151 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
3152 superfluous post_p argument.
3153 * c-gimplify.c (c_gimplify_expr): Likewise.
3155 2016-01-26 David Malcolm <dmalcolm@redhat.com>
3158 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
3159 pp_newline_and_flush with pp_flush.
3161 2016-01-20 Martin Sebor <msebor@redhat.com>
3164 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
3165 an incompatible argument when the argument isn't a valid tree node.
3167 2016-01-18 Jason Merrill <jason@redhat.com>
3170 * c-common.c (check_function_arguments_recurse): Fold the whole
3171 COND_EXPR, not just the condition.
3173 2016-01-18 Tom de Vries <tom@codesourcery.com>
3175 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
3176 classify as loop clause.
3178 2016-01-15 Jakub Jelinek <jakub@redhat.com>
3181 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
3182 C++ FE no longer has limit on number of pragmas.
3184 2015-01-14 Ryan Burn <contact@rnburn.com>
3187 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
3188 to add missing cleanup point.
3190 2016-01-14 David Malcolm <dmalcolm@redhat.com>
3193 * c-indentation.c (get_visual_column): Add location_t param.
3194 Handle the column number being zero by effectively disabling the
3195 warning, with an "inform".
3196 (should_warn_for_misleading_indentation): Add location_t argument
3197 for all uses of get_visual_column.
3199 2016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
3202 * c-indentation.c (should_warn_for_misleading_indentation):
3203 Don't warn about do-while statements.
3205 2016-01-07 Martin Sebor <msebor@redhat.com>
3208 * c-common.c (sync_resolve_size): Reject first argument when it's
3211 2016-01-05 David Malcolm <dmalcolm@redhat.com>
3214 * c-indentation.c (get_visual_column): Remove default argument.
3215 (should_warn_for_misleading_indentation): For the multiline case,
3216 update call to get_visual_column for next_stmt_exploc so that it
3217 captures the location of the first non-whitespace character in the
3218 relevant line. Don't issue warnings if there is non-whitespace
3219 before the next statement.
3221 2016-01-04 Jakub Jelinek <jakub@redhat.com>
3223 Update copyright years.
3225 2015-12-21 David Malcolm <dmalcolm@redhat.com>
3227 * c-common.c (binary_op_error): Convert first param from
3228 location_t to rich_location * and use it when emitting an error.
3229 * c-common.h (binary_op_error): Convert first param from
3230 location_t to rich_location *.
3232 2015-12-16 David Malcolm <dmalcolm@redhat.com>
3234 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
3235 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
3237 2015-12-15 Ilya Verbin <ilya.verbin@intel.com>
3239 * c-common.c (c_common_attribute_table): Handle "omp declare target
3242 2015-12-14 Jakub Jelinek <jakub@redhat.com>
3245 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
3247 2014-12-12 Tobias Burnus <burnus@net-b.de>
3250 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
3251 specifiers (%d, %i,%u and %c).
3253 2015-12-10 David Malcolm <dmalcolm@redhat.com>
3255 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
3257 2015-12-08 Jakub Jelinek <jakub@redhat.com>
3261 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
3262 * c-pragma.c (handle_pragma_diagnostic): Adjust
3263 control_warning_option caller.
3265 2015-12-07 David Malcolm <dmalcolm@redhat.com>
3267 * c-common.c (c_cpp_error): Update for change to
3268 rich_location::set_range.
3270 2015-12-04 Paolo Bonzini <bonzini@gnu.org>
3272 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
3273 shifting 1 out of the sign bit.
3275 2015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
3277 * c-common.c (c_common_attribute_table[]): Update max arguments
3278 count for "simd" attribute.
3279 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
3281 2015-12-03 Jakub Jelinek <jakub@redhat.com>
3283 PR preprocessor/57580
3284 * c-ppoutput.c (print): Change printed field to bool.
3285 Move src_file last for smaller padding.
3286 (init_pp_output): Set print.printed to false instead of 0.
3287 (scan_translation_unit): Fix up formatting. Set print.printed
3288 to true after printing something other than newline.
3289 (scan_translation_unit_trad): Set print.printed to true instead of 1.
3290 (maybe_print_line_1): Set print.printed to false instead of 0.
3291 (print_line_1): Likewise.
3292 (do_line_change): Set print.printed to true instead of 1.
3293 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
3294 dump_macro): Set print.printed to false after printing newline.
3296 2015-12-02 Jason Merrill <jason@redhat.com>
3298 * c-common.c (fold_for_warn): New.
3299 (warn_logical_operator, warn_tautological_cmp)
3300 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
3302 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
3303 (c_fully_fold_internal, decl_constant_value_for_optimization):
3305 * c-common.h: Don't declare decl_constant_value_for_optimization.
3307 2015-12-02 Joseph Myers <joseph@codesourcery.com>
3310 * c-common.h (c_build_qualified_type): Add extra default
3313 2015-12-01 Julian Brown <julian@codesourcery.com>
3314 Cesar Philippidis <cesar@codesourcery.com>
3315 James Norris <James_Norris@mentor.com>
3317 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
3318 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
3319 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
3321 2015-11-30 Eric Botcazou <ebotcazou@adacore.com>
3323 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
3324 (decl_sloc_common): Delete and move bulk of processing to...
3325 (decl_sloc): ...here.
3326 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
3327 (dump_ada_double_name): Remove S parameter and compute the suffix.
3328 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
3329 element type and deal with an anonymous one.
3330 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
3331 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
3332 and remove reference to QUAL_UNION_TYPE.
3333 (dump_nested_types): Make 2 passes on the fields and move bulk to...
3334 (dump_nested_type): ...here. New function extracted from above.
3335 Generate a full declaration for anonymous element type of arrays.
3336 (print_ada_declaration): Really skip anonymous declarations. Remove
3337 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
3338 Clean up processing of declarations of array types and objects.
3339 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
3340 Remove obsolete code and tidy up.
3342 2015-11-29 Jan Hubicka <hubicka@ucw.cz>
3345 * c-common.c (handle_transparent_union_attribute): Update
3348 2015-11-27 Martin Liska <mliska@suse.cz>
3351 * array-notation-common.c (cilkplus_extract_an_triplets):
3352 Release vector of vectors.
3353 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
3355 2015-11-26 Eric Botcazou <ebotcazou@adacore.com>
3358 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
3359 (print_ada_struct_decl): Likewise.
3361 2015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
3364 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
3365 * cilk.c (recognize_spawn): Determine location in a more precise
3368 2015-11-19 Jason Merrill <jason@redhat.com>
3370 * c-common.c (shorten_compare): But look through macros from
3373 2015-11-18 Jason Merrill <jason@redhat.com>
3375 * c-common.c (shorten_compare): Don't -Wtype-limits if the
3376 non-constant operand comes from a macro.
3378 2015-11-17 Jason Merrill <jason@redhat.com>
3381 * c-common.c (warn_tautological_cmp): Fold before checking for
3384 2015-11-16 Marek Polacek <polacek@redhat.com>
3387 * c-common.c (check_case_bounds): Fold low and high cases.
3389 2015-11-16 Marek Polacek <polacek@redhat.com>
3391 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
3392 * c-common.c (c_common_get_alias_set): Likewise.
3393 (handle_visibility_attribute): Likewise.
3395 2015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
3397 * c-common.c (handle_simd_attribute): New.
3398 (struct attribute_spec): Add entry for "simd".
3399 (handle_simd_attribute): New.
3401 2015-11-13 Kai Tietz <ktietz70@googlemail.com>
3403 * c-lex.c (interpret_float): Use fold_convert.
3405 2015-11-13 David Malcolm <dmalcolm@redhat.com>
3407 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
3408 and store it on the result.
3409 * c-opts.c (c_common_init_options): Set
3410 global_dc->colorize_source_p.
3412 2015-11-12 James Norris <jnorris@codesourcery.com>
3413 Joseph Myers <joseph@codesourcery.com>
3415 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
3416 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
3417 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
3418 PRAGMA_OACC_CLAUSE_LINK.
3420 2015-11-11 Marek Polacek <polacek@redhat.com>
3424 * c-common.c (valid_array_size_p): New function.
3425 * c-common.h (valid_array_size_p): Declare.
3427 2015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
3430 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
3432 2015-11-11 Andrew MacLeod <amacleod@redhat.com>
3434 * array-notation-common.c: Remove unused header files.
3435 * c-ada-spec.c: Likewise.
3436 * c-cilkplus.c: Likewise.
3437 * c-common.c: Likewise.
3438 * c-cppbuiltin.c: Likewise.
3439 * c-dump.c: Likewise.
3440 * c-format.c: Likewise.
3441 * c-gimplify.c: Likewise.
3442 * c-indentation.c: Likewise.
3443 * c-lex.c: Likewise.
3444 * c-omp.c: Likewise.
3445 * c-opts.c: Likewise.
3446 * c-pch.c: Likewise.
3447 * c-ppoutput.c: Likewise.
3448 * c-pragma.c: Likewise.
3449 * c-pretty-print.c: Likewise.
3450 * c-semantics.c: Likewise.
3451 * c-ubsan.c: Likewise.
3453 * stub-objc.c: Likewise.
3455 2015-11-09 Thomas Schwinge <thomas@codesourcery.com>
3456 Cesar Philippidis <cesar@codesourcery.com>
3457 James Norris <jnorris@codesourcery.com>
3458 Julian Brown <julian@codesourcery.com>
3459 Nathan Sidwell <nathan@codesourcery.com>
3461 * c-pragma.c (oacc_pragmas): Add "routine".
3462 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
3464 2015-11-08 Eric Botcazou <ebotcazou@adacore.com>
3466 * c-common.c (c_common_attributes): Add scalar_storage_order.
3467 (handle_scalar_storage_order_attribute): New function.
3468 * c-pragma.c (global_sso): New variable.
3469 (maybe_apply_pragma_scalar_storage_order): New function.
3470 (handle_pragma_scalar_storage_order): Likewise.
3471 (init_pragma): Register scalar_storage_order.
3472 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
3473 * c.opt (Wscalar-storage-order): New warning.
3474 (fsso-struct=): New option.
3476 2015-11-08 Martin Sebor <msebor@redhat.com>
3478 * c.opt (Wplacement-new): Add a period to the end of a sentence.
3480 2015-11-07 Richard Sandiford <richard.sandiford@arm.com>
3482 * c-common.c: Don't undef DEF_BUILTIN.
3484 2015-11-06 David Malcolm <dmalcolm@redhat.com>
3486 * c-common.c (c_cpp_error): Convert parameter from location_t to
3487 rich_location *. Eliminate the "column_override" parameter and
3488 the call to diagnostic_override_column.
3489 Update the "done_lexing" clause to set range 0
3490 on the rich_location, rather than overwriting a location_t.
3491 * c-common.h (c_cpp_error): Convert parameter from location_t to
3492 rich_location *. Eliminate the "column_override" parameter.
3494 2015-11-05 Cesar Philippidis <cesar@codesourcery.com>
3495 Thomas Schwinge <thomas@codesourcery.com>
3496 James Norris <jnorris@codesourcery.com>
3498 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
3499 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
3500 clauses with parallel and kernels and loops.
3501 * c-pragma.h (enum pragma_omp_clause): Add entries for
3502 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
3503 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
3504 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
3506 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
3508 2015-11-05 Martin Sebor <msebor@redhat.com>
3511 * c.opt (-Wplacement-new): New option.
3513 2015-11-05 Jakub Jelinek <jakub@redhat.com>
3515 * c-common.h (c_finish_omp_atomic): Add TEST argument.
3516 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
3517 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
3518 save_expr or create_tmp_var* if TEST is true.
3519 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
3520 Don't call add_stmt here.
3521 (struct c_omp_check_loop_iv_data): New type.
3522 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
3523 c_omp_check_loop_iv_exprs): New functions.
3524 (c_omp_split_clauses): Adjust for lastprivate being allowed on
3526 (c_omp_declare_simd_clauses_to_numbers): Change
3527 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
3528 (c_omp_declare_simd_clauses_to_decls): Similarly change those
3529 from numbers to PARM_DECLs.
3531 2015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
3533 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
3536 2015-11-03 Bernd Schmidt <bschmidt@redhat.com>
3539 * c-common.h (fold_offsetof_1): Add argument.
3540 * c-common.c (fold_offsetof_1): Diagnose more invalid
3541 offsetof expressions that reference elements past the end of
3544 2015-11-03 Thomas Schwinge <thomas@codesourcery.com>
3545 Chung-Lin Tang <cltang@codesourcery.com>
3547 * c-pragma.c (oacc_pragmas): Add "atomic".
3548 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
3550 2015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
3552 * c-common.c (handle_target_clones_attribute): New.
3553 (c_common_attribute_table): Add handle_target_clones_attribute.
3554 (handle_always_inline_attribute): Add check on target_clones attribute.
3555 (handle_target_attribute): Ditto.
3557 2015-10-29 Andrew MacLeod <amacleod@redhat.com>
3559 * array-notation-common.c: Reorder #include's and remove duplicates.
3560 * c-ada-spec.c: Likewise.
3561 * c-cilkplus.c: Likewise.
3562 * c-common.c: Likewise.
3563 * c-cppbuiltin.c: Likewise.
3564 * c-dump.c: Likewise.
3565 * c-format.c: Likewise.
3566 * c-gimplify.c: Likewise.
3567 * c-indentation.c: Likewise.
3568 * c-lex.c: Likewise.
3569 * c-omp.c: Likewise.
3570 * c-opts.c: Likewise.
3571 * c-pch.c: Likewise.
3572 * c-ppoutput.c: Likewise.
3573 * c-pragma.c: Likewise.
3574 * c-pretty-print.c: Likewise.
3575 * c-semantics.c: Likewise.
3576 * c-ubsan.c: Likewise.
3578 * stub-objc.c: Likewise.
3580 2015-10-28 Jason Merrill <jason@redhat.com>
3582 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
3584 2015-10-27 Thomas Schwinge <thomas@codesourcery.com>
3585 James Norris <jnorris@codesourcery.com>
3586 Cesar Philippidis <cesar@codesourcery.com>
3590 * c-common.h (c_oacc_split_loop_clauses): Declare function.
3591 * c-omp.c (c_oacc_split_loop_clauses): New function.
3593 2015-10-21 Martin Sebor <msebor@redhat.com>
3596 * c.opt: End each sentence that describes an option with a period.
3598 2015-10-20 Marek Polacek <polacek@redhat.com>
3600 * array-notation-common.c (is_cilkplus_vector_p): Define.
3601 * c-common.h (is_cilkplus_vector_p): Declare.
3603 2015-10-20 Marek Polacek <polacek@redhat.com>
3605 * c.opt (std=gnu++11): Do not describe as experimental.
3606 (std=gnu++14): Likewise.
3608 2015-10-19 Jason Merrill <jason@redhat.com>
3610 * c-cppbuiltin.c (c_cpp_builtins): Define
3611 __cpp_nontype_template_args.
3613 2015-10-19 Jason Merrill <jason@redhat.com>
3615 * c-cppbuiltin.c (c_cpp_builtins): Define
3616 __cpp_enumerator_attributes, __cpp_fold_expressions,
3617 __cpp_unicode_characters.
3619 2015-10-13 Jakub Jelinek <jakub@redhat.com>
3620 Aldy Hernandez <aldyh@redhat.com>
3622 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
3623 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
3624 (c_define_builtins): Likewise.
3625 * c-common.h (enum c_omp_clause_split): Add
3626 C_OMP_CLAUSE_SPLIT_TASKLOOP.
3627 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
3628 (c_finish_omp_for): Add ORIG_DECLV argument.
3629 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
3630 201511 instead of 201307.
3631 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
3632 OMP_CRITICAL_CLAUSES to it.
3633 (c_finish_omp_ordered): Add CLAUSES argument, set
3634 OMP_ORDERED_CLAUSES to it.
3635 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
3636 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
3637 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
3638 constructs and new OpenMP 4.5 clauses. Clear
3639 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
3641 * c-pragma.c (omp_pragmas_simd): Add taskloop.
3642 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
3643 (enum pragma_omp_clause): Add
3644 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
3645 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
3647 2015-10-05 Richard Sandiford <richard.sandiford@arm.com>
3649 * c-lex.c (interpret_float): Use real_equal instead of
3652 2015-10-04 Jason Merrill <jason@redhat.com>
3654 Implement N4514, C++ Extensions for Transactional Memory.
3655 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
3656 (c_common_attribute_table): Add transaction_safe_dynamic.
3657 transaction_safe now affects type identity.
3658 (handle_tm_attribute): Handle transaction_safe_dynamic.
3659 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
3660 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
3661 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
3663 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
3664 * c-pretty-print.c (pp_c_attributes_display): Don't print
3665 transaction_safe in C++.
3667 2015-10-02 Marek Polacek <polacek@redhat.com>
3669 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
3671 2015-10-02 Marek Polacek <polacek@redhat.com>
3674 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
3675 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
3676 * c.opt (Wduplicated-cond): New option.
3678 2015-10-01 Joseph Myers <joseph@codesourcery.com>
3680 * c.opt (std=c11): Do not describe as experimental.
3681 (std=gnu11): Likewise.
3682 (std=iso9899:2011): Likewise.
3684 2015-09-28 Nathan Sidwell <nathan@codesourcery.com>
3686 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
3687 (DEF_FUNCTION_TYPE_VAR_11): Delete.
3689 2015-09-25 Marek Polacek <polacek@redhat.com>
3691 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
3692 (ubsan_instrument_shift): Likewise.
3694 2015-09-25 Marek Polacek <polacek@redhat.com>
3697 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
3699 2015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
3701 * c-indentation.c (should_warn_for_misleading_indentation):
3702 Compare next_stmt_vis_column with guard_line_first_nws instead
3703 of with guard_line_vis_column.
3705 2015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
3709 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
3710 options and options not valid for the current language.
3712 2015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
3714 * c-indentation.c (should_warn_for_misleading_indentation):
3715 Float out and consolidate the calls to get_visual_column that
3716 are passed guard_exploc as an argument. Compare
3717 next_stmt_vis_column with guard_line_first_nws instead of with
3718 body_line_first_nws.
3720 2015-09-22 Nathan Sidwell <nathan@codesourcery.com>
3722 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
3723 Wnamespaces): New C++ warnings.
3725 2015-09-22 Jason Merrill <jason@redhat.com>
3727 * c-common.h (abi_compat_version_crosses): New.
3728 (warn_abi_version): Declare.
3729 * c-common.c: Define it.
3730 * c-opts.c (c_common_post_options): Handle it.
3731 flag_abi_compat_version defaults to 8.
3733 2015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
3735 Complete the implementation of N4230, Nested namespace definition.
3736 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
3737 __cpp_nested_namespace_definitions.
3739 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
3741 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
3743 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
3745 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
3747 * c-pragma.h (pragma_lex): Add optional loc argument.
3749 2015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
3751 * c-format.c (check_format_arg): Adjust to use common block size in all
3754 2015-09-15 David Malcolm <dmalcolm@redhat.com>
3756 * c-format.c (location_from_offset): Update for change in
3757 signature of location_get_source_line.
3758 * c-indentation.c (get_visual_column): Likewise.
3759 (line_contains_hash_if): Likewise.
3761 2015-09-14 Marek Polacek <polacek@redhat.com>
3763 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
3764 setting various warnings.
3766 2015-09-14 Marek Polacek <polacek@redhat.com>
3768 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
3771 2015-09-11 Mark Wielaard <mjw@redhat.com>
3774 * c.opt (Wunused-variable): Option from common.opt.
3775 (Wunused-const-variable): New option.
3777 2015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
3780 * c.opt ([Wsubobject-linkage]): Add.
3782 2015-09-03 Martin Sebor <msebor@redhat.com>
3785 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
3787 * c-common.c (reject_gcc_builtin): Define.
3789 2015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
3792 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
3794 * c-gimplify.c (c_gimplify_expr): Added a call to the function
3795 cilk_gimplify_call_params_in_spawned_fn.
3796 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
3797 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
3800 2015-08-25 Marek Polacek <polacek@redhat.com>
3803 * c-common.c (handle_weak_attribute): Don't check whether the
3804 visibility can be changed here.
3806 2015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
3808 * c-lex.c (c_lex_with_flags): Use explicit locations.
3810 2015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
3812 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
3813 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
3815 2015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3818 * c-common.c (check_builtin_function_arguments): Add check
3819 for BUILT_IN_SIGNBIT argument.
3821 2015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
3824 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
3827 2015-08-17 Marek Polacek <polacek@redhat.com>
3829 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
3830 with whitespaces before qualifier names.
3832 2015-08-12 Marek Polacek <polacek@redhat.com>
3835 * c-common.c (maybe_warn_shift_overflow): Properly handle
3836 left-shifting 1 into the sign bit.
3838 2015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
3840 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
3842 2015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
3843 Braden Obrzut <admin@maniacsvault.net>
3844 Jason Merrill <jason@redhat.com>
3846 Add C++ Concepts TS support.
3847 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
3848 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
3849 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
3850 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
3851 * c-opts.c (set_std_cxx1z): Set flag_concepts.
3852 * c.opt (fconcepts): New.
3854 2015-08-02 Martin Sebor <msebor@redhat.com>
3856 * c.opt (-Wframe-address): New warning option.
3858 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
3860 * c-indentation.c (should_warn_for_misleading_indentation):
3863 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
3865 * c-indentation.c (get_visual_column): Add parameter first_nws,
3866 use it. Update comment documenting the function.
3867 (is_first_nonwhitespace_on_line): Remove.
3868 (should_warn_for_misleading_indentation): Replace usage of
3869 of is_first_nonwhitespace_on_line with get_visual_column.
3871 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
3873 * c-indentation.h (struct token_indent_info): Define.
3874 (get_token_indent_info): Define.
3875 (warn_for_misleading_information): Declare.
3876 * c-common.h (warn_for_misleading_information): Remove.
3877 * c-identation.c (warn_for_misleading_indentation):
3878 Change declaration to take three token_indent_infos. Adjust
3880 * c-identation.c (should_warn_for_misleading_indentation):
3881 Likewise. Bail out early if the body is a compound statement.
3882 (guard_tinfo_to_string): Define.
3884 2015-07-30 Jason Merrill <jason@redhat.com>
3886 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
3887 '*' for reference decay.
3889 2015-07-30 Marek Polacek <polacek@redhat.com>
3891 * c-common.c (warn_tautological_cmp): Bail for float types.
3893 2015-07-27 Marek Polacek <polacek@redhat.com>
3896 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
3898 2015-07-27 Marek Polacek <polacek@redhat.com>
3902 * c-common.c (find_array_ref_with_const_idx_r): New function.
3903 (warn_tautological_cmp): New function.
3904 * c-common.h (warn_tautological_cmp): Declare.
3905 * c.opt (Wtautological-compare): New option.
3907 2015-07-23 Marek Polacek <polacek@redhat.com>
3909 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
3910 (ubsan_instrument_shift): Likewise.
3912 2015-07-23 Marek Polacek <polacek@redhat.com>
3915 * c-ubsan.c: Include gimplify.h.
3916 (ubsan_instrument_division): Unshare OP0 and OP1.
3917 (ubsan_instrument_shift): Likewise.
3919 2015-07-20 Marek Polacek <polacek@redhat.com>
3920 Richard Sandiford <richard.sandiford@arm.com>
3923 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
3924 Use EXPR_LOC_OR_LOC.
3925 (maybe_warn_shift_overflow): New function.
3926 * c-common.h (maybe_warn_shift_overflow): Declare.
3927 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
3928 * c.opt (Wshift-overflow): New option.
3930 2015-07-16 Martin Liska <mliska@suse.cz>
3932 * c-format.c (static void check_format_info_main): Use
3933 object_allocator instead of pool_allocator.
3934 (check_format_arg): Likewise.
3935 (check_format_info_main): Likewise.
3937 2015-07-15 Andrew MacLeod <amacleod@redhat.com>
3939 * c-opts.c: Remove multiline #include comment.
3941 2015-07-12 Aldy Hernandez <aldyh@redhat.com>
3943 * c-common.c: Fix double word typos.
3945 2015-07-10 Eric Botcazou <ebotcazou@adacore.com>
3947 * c-ada-spec.h (cpp_operation): Revert latest change.
3948 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
3949 constructors and destructors.
3951 2015-07-09 Andrew MacLeod <amacleod@redhat.com>
3953 * c-common.h: Adjust includes for flags.h changes.
3954 * stub-objc.c: Likewise.
3956 2015-07-08 Eric Botcazou <ebotcazou@adacore.com>
3958 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
3959 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
3961 2015-07-08 Jakub Jelinek <jakub@redhat.com>
3963 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
3964 are to be removed, return NULL rather than original clauses list.
3966 2015-07-07 Andrew MacLeod <amacleod@redhat.com>
3968 * array-notation-common.c: Adjust includes.
3969 * c-ada-spec.c: Likewise.
3970 * c-cilkplus.c: Likewise.
3971 * c-common.h: Likewise.
3972 * c-cppbuiltin.c: Likewise.
3973 * c-dump.c: Likewise.
3974 * c-format.c: Likewise.
3975 * c-gimplify.c: Likewise.
3976 * c-indentation.c: Likewise.
3977 * c-lex.c: Likewise.
3978 * c-omp.c: Likewise.
3979 * c-opts.c: Likewise.
3980 * c-pch.c: Likewise.
3981 * c-ppoutput.c: Likewise.
3982 * c-pragma.c: Likewise.
3983 * c-pretty-print.c: Likewise.
3984 * c-semantics.c: Likewise.
3985 * c-ubsan.c: Likewise.
3987 * stub-objc.c: Likewise.
3989 2015-07-07 Eric Botcazou <ebotcazou@adacore.com>
3991 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
3992 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
3994 2015-07-01 Jason Merrill <jason@redhat.com>
3996 * c-common.h (D_CXX11): Rename from D_CXX0X.
3997 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
3998 * c-common.c: Adjust.
4000 * c-opts.c (c_common_post_options): Default to C++14.
4002 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
4004 2015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
4006 Implement N4197 - Adding u8 character literals
4007 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
4009 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
4010 CPP_UTF8CHAR_USERDEF tokens.
4011 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
4012 and CPP_UTF8CHAR tokens.
4013 (lex_charconst): Treat CPP_UTF8CHAR token.
4015 2015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
4018 * c-common.c (do_warn_unused_parameter): Move here.
4019 * c-common.h (do_warn_unused_parameter): Declare.
4021 2015-06-29 Marek Polacek <polacek@redhat.com>
4024 * c-common.c (check_case_bounds): Add bool * parameter. Set
4026 (c_add_case_label): Add bool * parameter. Pass it down to
4028 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
4030 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
4033 2015-06-27 Marek Polacek <polacek@redhat.com>
4035 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
4036 or VECTOR_INTEGER_TYPE_P throughout.
4037 * c-gimplify.c: Likewise.
4039 2015-06-26 Marek Polacek <polacek@redhat.com>
4041 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
4042 * c-common.c (c_fully_fold_internal): Likewise.
4043 (c_alignof_expr): Likewise.
4044 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
4045 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
4046 * cilk.c (create_parm_list): Likewise.
4048 2015-06-26 Marek Polacek <polacek@redhat.com>
4050 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
4052 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
4054 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
4055 * c-gimplify.c: Likewise.
4056 * c-pragma.c: Likewise.
4057 * c-ubsan.c: Likewise.
4060 2015-06-25 Richard Sandiford <richard.sandiford@arm.com>
4062 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
4065 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
4067 * cilk.c: Move calls.h after tm.h in the include chain.
4069 2015-06-25 Marek Polacek <polacek@redhat.com>
4071 * array-notation-common.c: Use VAR_P throughout.
4072 * c-ada-spec.c: Likewise.
4073 * c-common.c: Likewise.
4074 * c-format.c: Likewise.
4075 * c-gimplify.c: Likewise.
4076 * c-omp.c: Likewise.
4077 * c-pragma.c: Likewise.
4078 * c-pretty-print.c: Likewise.
4081 2015-06-25 Marek Polacek <polacek@redhat.com>
4083 * cilk.c (extract_free_variables): Use is_global_var.
4085 2015-06-23 Richard Sandiford <richard.sandiford@arm.com>
4087 * c-common.c: Don't include target-def.h.
4089 2015-06-23 Marek Polacek <polacek@redhat.com>
4091 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
4092 when comparing INTEGER_CSTs.
4094 2015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
4096 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
4097 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
4098 (dump_ada_template): Skip partially specialized types.
4100 2015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
4102 * c-common.c (scalar_to_vector): Use std::swap instead of manually
4105 2015-06-17 Andrew MacLeod <amacleod@redhat.com>
4107 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
4108 * c-ada-spec.c: Likewise.
4109 * c-cilkplus.c: Likewise.
4110 * c-common.c: Likewise.
4111 * c-common.h: Likewise.
4112 * c-cppbuiltin.c: Likewise.
4113 * c-dump.c: Likewise.
4114 * c-format.c: Likewise.
4115 * c-gimplify.c: Likewise.
4116 * c-indentation.c: Likewise.
4117 * c-lex.c: Likewise.
4118 * c-omp.c: Likewise.
4119 * c-opts.c: Likewise.
4120 * c-pch.c: Likewise.
4121 * c-ppoutput.c: Likewise.
4122 * c-pragma.c: Likewise.
4123 * c-pretty-print.c: Likewise.
4124 * c-semantics.c: Likewise.
4125 * c-ubsan.c: Likewise.
4127 * stub-objc.c: Likewise.
4129 2015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
4132 * c-common.c (c_common_truthvalue_conversion): Warn when
4133 converting an address of a reference to a truth value.
4135 2015-06-08 Andrew MacLeod <amacleod@redhat.com>
4137 * array-notation-common.c : Adjust include files.
4138 * c-ada-spec.c : Likewise.
4139 * c-cilkplus.c : Likewise.
4140 * c-common.c : Likewise.
4141 * c-common.h : Likewise.
4142 * c-cppbuiltin.c : Likewise.
4143 * c-dump.c : Likewise.
4144 * c-format.c : Likewise.
4145 * c-gimplify.c : Likewise.
4146 * c-indentation.c : Likewise.
4147 * c-lex.c : Likewise.
4148 * c-omp.c : Likewise.
4149 * c-opts.c : Likewise.
4150 * c-pch.c : Likewise.
4151 * c-ppoutput.c : Likewise.
4152 * c-pragma.c : Likewise.
4153 * c-pretty-print.c : Likewise.
4154 * c-semantics.c : Likewise.
4155 * c-ubsan.c : Likewise.
4156 * cilk.c : Likewise.
4157 * stub-objc.c : Likewise.
4159 2015-06-08 Marek Polacek <polacek@redhat.com>
4162 * c-format.c (location_from_offset): Return LOC if LINE is null.
4164 2015-06-05 Aldy Hernandez <aldyh@redhat.com>
4166 * c-common.h (c_parse_final_cleanups): New prototype.
4167 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
4169 2015-06-04 Sriraman Tallam <tmsriram@google.com>
4171 * c-common.c (noplt): New attribute.
4172 (handle_noplt_attribute): New handler.
4174 2015-06-04 Andrew MacLeod <amacleod@redhat.com>
4176 * array-notation-common.c: Adjust includes for restructured coretypes.h.
4177 * c-ada-spec.c: Likewise.
4178 * c-cilkplus.c: Likewise.
4179 * c-common.c: Likewise.
4180 * c-common.h: Likewise.
4181 * c-cppbuiltin.c: Likewise.
4182 * c-dump.c: Likewise.
4183 * c-format.c: Likewise.
4184 * c-gimplify.c: Likewise.
4185 * c-indentation.c: Likewise.
4186 * c-lex.c: Likewise.
4187 * c-omp.c: Likewise.
4188 * c-opts.c: Likewise.
4189 * c-pch.c: Likewise.
4190 * c-ppoutput.c: Likewise.
4191 * c-pragma.c: Likewise.
4192 * c-pretty-print.c: Likewise.
4193 * c-semantics.c: Likewise.
4194 * c-ubsan.c: Likewise.
4196 * stub-objc.c: Likewise.
4198 2015-06-02 David Malcolm <dmalcolm@redhat.com>
4201 * c-indentation.c (should_warn_for_misleading_indentation): Use
4202 expand_location rather than expand_location_to_spelling_point.
4203 Don't warn if the guarding statement is more indented than the
4206 2015-06-02 David Malcolm <dmalcolm@redhat.com>
4208 * c-indentation.c (warn_for_misleading_indentation): Bail out
4209 immediately if -Wmisleading-indentation isn't enabled.
4211 2015-06-01 Martin Liska <mliska@suse.cz>
4213 * c-format.c (check_format_arg):Use new type-based pool allocator.
4214 (check_format_info_main) Likewise.
4216 2015-05-31 Eric Botcazou <ebotcazou@adacore.com>
4218 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
4219 (has_nontrivial_methods): Likewise.
4221 2015-05-25 Marek Polacek <polacek@redhat.com>
4223 * c-ubsan.c (ubsan_instrument_shift): Use type0.
4225 2015-05-22 Marek Polacek <polacek@redhat.com>
4228 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
4230 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
4232 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
4233 STACK_GROWS_DOWNWARD.
4235 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
4237 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
4238 STACK_GROWS_DOWNWARD rather than if it is defined.
4240 2015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
4243 * c-format.c (location_column_from_byte_offset): New.
4244 (location_from_offset): New.
4245 (struct format_wanted_type): Add offset_loc field.
4246 (check_format_info): Move handling of location for extra arguments
4247 closer to the point of warning.
4248 (check_format_info_main): Pass the result of location_from_offset
4250 (format_type_warning): Pass the result of location_from_offset
4253 2015-05-20 Marek Polacek <polacek@redhat.com>
4255 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
4257 2015-05-20 Marek Polacek <polacek@redhat.com>
4259 * c-ada-spec.c (dump_sloc): Use DECL_P.
4261 2015-05-20 Marek Polacek <polacek@redhat.com>
4263 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
4264 * c-common.c: Likewise.
4266 2015-05-19 David Malcolm <dmalcolm@redhat.com>
4268 * c-common.h (fe_file_change): Strengthen param from
4269 const line_map * to const line_map_ordinary *.
4270 (pp_file_change): Likewise.
4271 * c-lex.c (fe_file_change): Likewise.
4272 (cb_define): Use linemap_check_ordinary when invoking
4274 (cb_undef): Likewise.
4275 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
4276 invoking cb_file_change.
4277 (c_finish_options): Likewise.
4278 (push_command_line_include): Likewise.
4279 (cb_file_change): Strengthen param "new_map" from
4280 const line_map * to const line_map_ordinary *.
4281 * c-ppoutput.c (cb_define): Likewise for local "map".
4282 (pp_file_change): Likewise for param "map" and local "from".
4284 2015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
4286 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
4288 2015-05-18 Tom de Vries <tom@codesourcery.com>
4290 * c-common.c (build_va_arg_1): New function.
4291 (build_va_arg): Add address operator to va_list operand if necessary.
4293 2015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
4296 * c-common.c (int_safely_convertible_to_real_p): Define.
4297 (unsafe_conversion_p): Check conversions involving complex types.
4298 (conversion_warning): Add new warning message for conversions which
4299 discard imaginary component.
4300 * c-common.h: (enum conversion_safety): Add new enumerator for such
4303 2015-05-14 Marek Polacek <polacek@redhat.com>
4307 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
4308 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
4309 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
4310 use it. If FOR_INT_CONST, require that all evaluated operands be
4313 2015-05-12 David Malcolm <dmalcolm@redhat.com>
4315 * c-common.h (warn_for_misleading_indentation): New prototype.
4316 * c-indentation.c: New file.
4317 * c.opt (Wmisleading-indentation): New option.
4319 2015-05-12 Tom de Vries <tom@codesourcery.com>
4321 PR tree-optimization/66010
4322 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
4324 2015-05-09 Jason Merrill <jason@redhat.com>
4326 * c-opts.c (c_common_post_options): Also clear
4327 cpp_opts->cpp_warn_cxx11_compat.
4329 * c-common.h (enum cxx_dialect): Add cxx_unset.
4330 * c-common.c (cxx_dialect): Initialize to cxx_unset.
4331 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
4333 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
4334 (std=gnu++0x): Mark as Undocumented.
4335 (std=gnu++1y): Add deprecated message.
4337 2015-05-08 Jason Merrill <jason@redhat.com>
4339 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
4342 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
4344 2015-05-08 Marek Polacek <polacek@redhat.com>
4347 * c.opt (Woverride-init-side-effects): New option.
4349 2015-05-07 Marek Polacek <polacek@redhat.com>
4352 * c-common.c (c_fully_fold_internal): Warn when left shifting a
4354 * c.opt (Wshift-negative-value): New option.
4355 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
4356 when -Wextra and C99/C++11 mode.
4358 2015-05-07 Marek Polacek <polacek@redhat.com>
4359 Martin Uecker <uecker@eecs.berkeley.edu>
4361 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
4362 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
4364 2015-05-05 Jason Merrill <jason@redhat.com>
4366 * c.opt (Wterminate): New.
4368 2015-04-30 Marek Polacek <polacek@redhat.com>
4370 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
4371 require that the non-constant be of a boolean type.
4373 2015-04-29 Josh Triplett <josh@joshtriplett.org>
4375 * c-common.c (handle_section_attribute): Refactor to reduce
4376 nesting and distinguish between error cases.
4378 2015-04-29 Marek Polacek <polacek@redhat.com>
4381 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
4384 2015-04-29 Jakub Jelinek <jakub@redhat.com>
4386 * c-common.h (omp_clause_mask): Unconditionally define as a class.
4387 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
4388 HOST_BITS_PER_WIDE_INT.
4390 2015-04-28 Tom de Vries <tom@codesourcery.com>
4392 PR tree-optimization/65887
4393 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
4395 2015-04-28 Eric Botcazou <ebotcazou@adacore.com>
4396 Pierre-Marie de Rodat <derodat@adacore.com>
4398 * c-ada-spec.c (in_function): Delete.
4399 (dump_generic_ada_node): Do not change in_function and remove the
4400 redundant code dealing with it.
4401 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
4402 (print_ada_methods): Output the static member functions in a nested
4403 package after the regular methods as well as associated renamings.
4405 2015-04-24 Marek Polacek <polacek@redhat.com>
4408 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
4409 and OPT_Wshift_count_overflow.
4412 * c-common.c (warn_logical_operator): Warn if the operands have the
4415 2015-04-24 Marek Polacek <polacek@redhat.com>
4418 * c-common.c (warn_logical_operator): Bail if either operand comes
4419 from a macro expansion.
4421 2015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
4424 * c-common.c (c_default_pointer_mode): Add definition.
4425 * c-common.h (c_default_pointer_mode): Add declaration.
4427 2015-03-11 Jakub Jelinek <jakub@redhat.com>
4429 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
4430 on record_builtin_type argument.
4432 2015-03-10 Jakub Jelinek <jakub@redhat.com>
4435 * c-common.c (warn_logical_not_parentheses): Don't warn for
4438 2015-03-07 Marek Polacek <polacek@redhat.com>
4441 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
4442 before trying to figure out whether we have a flexible array member.
4444 2015-03-06 Eric Botcazou <ebotcazou@adacore.com>
4445 Jonathan Wakely <jwakely.gcc@gmail.com>
4447 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
4449 2015-03-05 Eric Botcazou <ebotcazou@adacore.com>
4452 * c-ada-spec.c (print_destructor): Remove obsolete code.
4454 2015-03-01 Eric Botcazou <ebotcazou@adacore.com>
4456 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
4457 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
4458 DECL_TEMPLATE_RESULT emulations.
4459 (dump_ada_template)): Add guard for TYPE_METHODS.
4461 2015-02-27 Marek Polacek <polacek@redhat.com>
4464 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
4466 2015-02-27 Kai Tietz <ktietz@redhat.com>
4469 * c-pragma.c (handle_pragma_weak): Do not try to create
4470 weak/alias of declarations not being function, or variable
4473 2015-02-24 Thomas Schwinge <thomas@codesourcery.com>
4476 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
4478 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
4480 2015-02-16 Marek Polacek <polacek@redhat.com>
4483 * c-format.c (check_format_types): Handle null param.
4485 2015-02-13 Marek Polacek <polacek@redhat.com>
4488 * c-format.c (check_format_types): Don't warn about different
4489 signedness if the original value is in the range of WANTED_TYPE.
4491 2015-02-12 Jason Merrill <jason@redhat.com>
4494 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
4495 to the current highest version.
4496 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
4498 2015-02-04 Jakub Jelinek <jakub@redhat.com>
4502 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
4503 instead of RDIV_EXPR. Use build_binary_op instead of
4506 2015-01-30 Joseph Myers <joseph@codesourcery.com>
4508 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
4509 to pass input_location as first argument.
4511 2015-01-23 Tom de Vries <tom@codesourcery.com>
4514 * c.opt (fopenacc): Mark as LTO option.
4516 2015-01-23 Tom de Vries <tom@codesourcery.com>
4519 * c.opt (fopenmp): Mark as LTO option.
4521 2015-01-21 Jakub Jelinek <jakub@redhat.com>
4524 * cilk.c (fill_decls_vec): Only put decls into vector v.
4525 (compare_decls): Fix up formatting.
4527 2015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
4530 * cilk.c: Include vec.h.
4531 (struct cilk_decls): New structure.
4532 (wrapper_parm_cb): Split this function to...
4533 (fill_decls_vec): ...this...
4534 (create_parm_list): ...and this.
4535 (compare_decls): New function.
4536 (for_local_cb): Remove.
4537 (wrapper_local_cb): Ditto.
4538 (build_wrapper_type): For now first traverse and fill vector of
4539 declarations then sort it and then deal with sorted vector.
4540 (cilk_outline): Ditto.
4541 (declare_one_free_variable): Ditto.
4543 2015-01-21 Jason Merrill <jason@redhat.com>
4546 * c-format.c (check_format_arg): Call decl_constant_value.
4548 2015-01-19 Martin Liska <mliska@suse.cz>
4550 * c-common.c (handle_noicf_attribute): New function.
4552 2015-01-15 Thomas Schwinge <thomas@codesourcery.com>
4553 Bernd Schmidt <bernds@codesourcery.com>
4554 James Norris <jnorris@codesourcery.com>
4555 Cesar Philippidis <cesar@codesourcery.com>
4556 Ilmir Usmanov <i.usmanov@samsung.com>
4557 Jakub Jelinek <jakub@redhat.com>
4559 * c.opt (fopenacc): New option.
4560 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
4561 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
4563 * c-common.h (c_finish_oacc_wait): New prototype.
4564 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
4565 (c_finish_oacc_wait): New function.
4566 * c-pragma.c (oacc_pragmas): New variable.
4567 (c_pp_lookup_pragma, init_pragma): Handle it.
4568 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
4569 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
4570 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
4571 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
4572 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
4573 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
4574 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
4575 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
4576 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
4577 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
4578 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
4579 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
4580 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
4581 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
4582 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
4583 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
4584 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
4585 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
4586 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
4587 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
4588 PRAGMA_OACC_CLAUSE_WORKER.
4590 2015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
4592 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
4593 for the new option fstack-protector_explicit.
4594 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
4595 (handle_stack_protect_attribute): New function.
4597 2015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
4599 * c.opt: New option -Warray-bounds=.
4601 2015-01-09 Michael Collison <michael.collison@linaro.org>
4603 * array-notation-common.c: Include hash-set.h, machmode.h,
4604 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4605 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
4606 * c-ada-spec.c: Ditto.
4607 * c-cilkplus.c: Ditto.
4608 * c-common.c: Include input.h due to flattening of tree.h.
4609 Define macro GCC_C_COMMON_C.
4610 * c-common.h: Flatten tree.h header files into c-common.h.
4611 Remove include of tree-core.h.
4612 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
4613 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4614 fold-const.h, wide-int.h, and inchash.h due to
4615 flattening of tree.h.
4617 * c-format.c: Flatten tree.h header files into c-common.h.
4618 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
4619 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4620 fold-const.h, wide-int.h, and inchash.h due to
4621 flattening of tree.h.
4622 * c-dump.c: Include hash-set.h, machmode.h,
4623 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4624 fold-const.h, wide-int.h, and inchash.h due to
4625 flattening of tree.h.
4626 * c-format.c: Include hash-set.h, machmode.h,
4627 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4628 fold-const.h, wide-int.h, inchash.h and real.h due to
4629 flattening of tree.h.
4630 * c-gimplify.c: Include hash-set.h, machmode.h,
4631 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4632 fold-const.h, wide-int.h, and inchash.h due to
4633 flattening of tree.h.
4639 * c-ppoutput.c: Ditto.
4640 * c-pragma.c: Ditto.
4641 * c-pretty-print.c: Ditto.
4642 * c-semantics.c: Ditto.
4644 * stub-objc.c: Ditto.
4646 2015-01-08 Jason Merrill <jason@redhat.com>
4648 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
4649 do_ubsan_in_current_function.
4650 (ubsan_maybe_instrument_reference_or_call): Likewise.
4651 * c-ubsan.h: Declare it.
4653 2015-01-08 Mike Stump <mikestump@comcast.net>
4655 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
4657 2015-01-07 Marek Polacek <polacek@redhat.com>
4660 * c-common.c (c_fully_fold_internal): Warn for division and modulo
4661 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
4663 2015-01-05 Trevor Saunders <tsaunders@mozilla.com>
4666 * c.opt (Wsuggest-override): New option.
4668 2015-01-05 Jakub Jelinek <jakub@redhat.com>
4670 Update copyright years.
4672 2015-01-05 Marek Polacek <polacek@redhat.com>
4675 * c-common.c (warn_array_subscript_with_type_char): Add location_t
4677 * c-common.h (warn_array_subscript_with_type_char): Update
4680 2014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
4682 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
4683 Control macro with flag_sized_deallocation.
4685 2014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
4687 * c.opt (Wdiscarded-array-qualifiers): New option.
4689 2014-12-19 Jakub Jelinek <jakub@redhat.com>
4691 PR preprocessor/63831
4692 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
4693 and __has_cpp_attribute here.
4694 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
4695 c_common_has_attribute.
4696 * c-common.h (c_common_has_attribute): New prototype.
4697 * c-lex.c (init_c_lex): Set cb->has_attribute to
4698 c_common_has_attribute instead of cb_has_attribute.
4699 (get_token_no_padding): New function.
4700 (cb_has_attribute): Renamed to ...
4701 (c_common_has_attribute): ... this. No longer static. Use
4702 get_token_no_padding, require ()s, don't build TREE_LIST
4703 unnecessarily, fix up formatting, adjust diagnostics, call
4706 2014-12-15 Jason Merrill <jason@redhat.com>
4708 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
4709 (-Wsized-deallocation): New.
4710 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
4711 to on in C++14 and up.
4713 2014-12-11 Jason Merrill <jason@redhat.com>
4715 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
4717 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
4718 we aren't complaining about VLAs.
4720 2014-12-06 Marek Polacek <polacek@redhat.com>
4722 PR tree-optimization/64183
4723 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
4724 shift-expression if it is integer_type_node. Use types_compatible_p.
4726 2014-11-29 Jakub Jelinek <jakub@redhat.com>
4728 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
4729 last argument from create_tmp_var_raw and create_tmp_var calls.
4730 * cilk.c (gimplify_cilk_spawn): Likewise.
4731 * c-omp.c (c_finish_omp_atomic): Likewise.
4733 2014-11-28 Marek Polacek <polacek@redhat.com>
4735 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
4736 instead of unsigned_type_node.
4738 2014-11-28 Marek Polacek <polacek@redhat.com>
4741 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
4743 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
4744 expression to unsigned_type_node.
4746 2014-11-20 Mark Wielaard <mjw@redhat.com>
4749 * c-opts.c (set_std_c89): Set lang_hooks.name.
4750 (set_std_c99): Likewise.
4751 (set_std_c11): Likewise.
4752 (set_std_cxx98): Likewise.
4753 (set_std_cxx11): Likewise.
4754 (set_std_cxx14): Likewise.
4755 (set_std_cxx1z): Likewise.
4757 2014-11-21 Jakub Jelinek <jakub@redhat.com>
4760 * c-common.h (convert_vector_to_pointer_for_subscript): Change
4761 return type to bool.
4762 * c-common.c: Include gimple-expr.h.
4763 (convert_vector_to_pointer_for_subscript): Change return type to
4764 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
4765 and copy it into a TARGET_EXPR and use that instead of *vecp
4768 2014-11-19 David Malcolm <dmalcolm@redhat.com>
4770 Merger of git branch "gimple-classes-v2-option-3".
4771 * ChangeLog.gimple-classes: New.
4772 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
4773 from being just a vec<gimple> to a vec<gbind *>.
4775 2014-11-18 Jakub Jelinek <jakub@redhat.com>
4778 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
4779 argument to ptype, set type to TREE_TYPE (ptype). Don't call
4780 get_pointer_alignment for non-pointers. Use ptype, or if it is
4781 reference type, corresponding pointer type, as type of kind
4783 (ubsan_maybe_instrument_reference,
4784 ubsan_maybe_instrument_member_call): Adjust callers.
4786 2014-11-15 Marek Polacek <polacek@redhat.com>
4789 * array-notation-common.c (is_sec_implicit_index_fn): Return false
4791 (extract_array_notation_exprs): Return for NULL node.
4793 2014-11-12 Joseph Myers <joseph@codesourcery.com>
4795 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
4796 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
4798 2014-11-12 Jakub Jelinek <jakub@redhat.com>
4801 * c-common.c (check_builtin_function_arguments): Handle
4802 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
4804 2014-11-10 Andi Kleen <ak@linux.intel.com>
4807 * c-common.h (check_no_cilk): Declare.
4808 * cilk.c (get_error_location): New function.
4809 (check_no_cilk): Dito.
4811 2014-11-10 Andi Kleen <ak@linux.intel.com>
4813 * cilk.c (recognize_spawn): Use expression location
4816 2014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
4818 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
4820 2014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
4822 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
4823 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
4824 (__cpp_range_based_for, __cpp_initializer_lists,
4825 __cpp_delegating_constructors, __cpp_nsdmi,
4826 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
4827 for C++11; (__cpp_attribute_deprecated): Remove in favor of
4828 __has_cpp_attribute.
4829 * c-lex.c (cb_has_attribute): New callback CPP function;
4830 (init_c_lex): Set has_attribute callback.
4832 2014-11-04 Richard Biener <rguenther@suse.de>
4834 * c-common.c (shorten_compare): Do not shorten mixed
4835 DFP and non-DFP compares.
4837 2014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
4839 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
4840 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
4841 Commentary and rearrangement of tests.
4842 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
4843 Commentary and rearrangement of tests.
4844 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto
4845 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
4847 2014-10-29 Richard Sandiford <richard.sandiford@arm.com>
4849 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
4850 enum from machine_mode.
4852 2014-10-28 Andrew MacLeod <amacleod@redhat.com>
4854 * c-common.c: Adjust include files.
4855 * c-gimplify.c: Ditto.
4857 * c-pragma.c: Ditto.
4860 2014-10-27 Andrew MacLeod <amacleod@redhat.com>
4862 * c-gimplify.c: Adjust include files.
4864 2014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
4867 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
4868 c_common_initialize_diagnostics.
4869 * c-common.h: Likewise.
4871 2014-10-24 Marek Polacek <polacek@redhat.com>
4874 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
4875 print "struct"/"union"/"enum" for typedefed names.
4877 2014-10-23 Marek Polacek <polacek@redhat.com>
4879 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
4882 2014-10-22 Jakub Jelinek <jakub@redhat.com>
4883 Yury Gribov <y.gribov@samsung.com>
4885 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
4886 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
4887 instead of flag_sanitize_recover as bool flag.
4889 2014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
4891 * cilk.c: Revert previous change.
4893 2014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
4896 * cilk.c: Include vec.h.
4897 (struct cilk_decls): New structure.
4898 (wrapper_parm_cb): Split this function to...
4899 (fill_decls_vec): ...this...
4900 (create_parm_list): ...and this.
4901 (compare_decls): New function.
4902 (for_local_cb): Remove.
4903 (wrapper_local_cb): Ditto.
4904 (build_wrapper_type): For now first traverse and fill vector of
4905 declarations then sort it and then deal with sorted vector.
4906 (cilk_outline): Ditto.
4907 (declare_one_free_variable): Ditto.
4909 2014-10-17 Marek Polacek <polacek@redhat.com>
4911 * c-opts.c (c_common_post_options): Set warn_implicit_int.
4912 * c.opt (Wimplicit-int): Initialize to -1.
4914 2014-10-16 Andrew MacLeod <amacleod@redhat.com>
4916 * c-pragma.c: Adjust include files.
4917 * c-semantics.c: Likewise.
4919 2014-10-16 DJ Delorie <dj@redhat.com>
4921 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
4924 2014-10-14 Jason Merrill <jason@redhat.com>
4927 * c-common.h (CPP_PREPARSED_EXPR): New.
4928 (N_CP_TTYPES): Adjust.
4930 2014-10-15 Marek Polacek <polacek@redhat.com>
4932 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
4934 2014-10-14 DJ Delorie <dj@redhat.com>
4936 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
4937 types, not just __int128.
4938 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
4939 types, not just __int128.
4940 (cpp_atomic_builtins): Round pointer sizes up.
4941 (type_suffix): Use type precision, not specific types.
4942 * c-common.c (c_common_reswords): Remove __int128 special case.
4943 (c_common_type_for_size): Check for all __intN types, not just
4945 (c_common_type_for_mode): Likewise.
4946 (c_common_signed_or_unsigned_type): Likewise.
4947 (c_build_bitfield_integer_type): Likewise.
4948 (c_common_nodes_and_builtins): Likewise.
4949 (keyword_begins_type_specifier): Likewise.
4950 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
4953 2014-10-12 Trevor Saunders <tsaunders@mozilla.com>
4955 * c-common.c: Use hash_table instead of hashtab.
4957 2014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
4959 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
4962 2014-10-03 Marc Glisse <marc.glisse@inria.fr>
4967 * c-common.c (warn_logical_operator): Punt for vectors.
4969 2014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
4971 Implement SD-6: SG10 Feature Test Recommendations
4972 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
4973 macros and the __has_header macro.
4975 2014-09-30 Jason Merrill <jason@redhat.com>
4977 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
4978 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
4979 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
4981 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
4982 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
4984 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
4985 * c-common.c (c_common_reswords): Remove __is_convertible_to.
4987 2014-09-24 Marek Polacek <polacek@redhat.com>
4991 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
4993 2014-09-23 Andi Kleen <ak@linux.intel.com>
4995 * c-common.c (handle_no_reorder_attribute): New function.
4996 (c_common_attribute_table): Add no_reorder attribute.
4998 2014-09-22 Joseph Myers <joseph@codesourcery.com>
5000 * c-cppbuiltin.c (c_cpp_builtins): Define
5001 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
5004 2014-09-18 Joseph Myers <joseph@codesourcery.com>
5006 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
5007 for supported floating-point modes.
5009 2014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
5011 * c.opt (Wpsabi): Use LangEnabledBy.
5012 * c-opts.c (c_common_handle_option): Do not handle here.
5014 2014-09-12 Joseph Myers <joseph@codesourcery.com>
5016 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
5017 macros for floating-point modes.
5019 2014-09-11 Marc Glisse <marc.glisse@inria.fr>
5022 * c-cppbuiltin.c (builtin_define_float_constants): Correct
5023 __*_DENORM_MIN__ without denormals.
5025 2014-09-10 Jakub Jelinek <jakub@redhat.com>
5027 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5028 ubsan_instrument_vla, ubsan_instrument_return): Adjust
5029 ubsan_create_data callers.
5030 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
5031 index is constant or BIT_AND_EXPR with constant mask and is
5032 small enough for the bound.
5033 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
5034 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
5036 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
5038 * c.opt: Add CppReason to various flags.
5039 (Wdate-time): Re-sort.
5040 * c-common.c: Include c-common.h earlier.
5041 (struct reason_option_codes_t): Delete.
5042 (c_option_controlling_cpp_error): Prefix global type and struct
5045 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
5047 * c.opt (Wnormalized): New.
5048 (Wnormalized=): Use Enum and Reject Negative.
5049 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
5051 2014-09-08 Joseph Myers <joseph@codesourcery.com>
5053 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
5054 digits of floating-point modes if -fbuilding-libgcc.
5056 2014-09-05 Joseph Myers <joseph@codesourcery.com>
5058 * c-cppbuiltin.c (c_cpp_builtins): Also define
5059 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
5060 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
5061 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
5062 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
5063 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
5064 __LIBGCC_STACK_GROWS_DOWNWARD__,
5065 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
5066 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
5067 __LIBGCC_DWARF_FRAME_REGISTERS__,
5068 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
5069 __LIBGCC_STACK_POINTER_REGNUM__ and
5070 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
5071 (builtin_define_with_value): Handle backslash-escaping in string
5074 2014-09-05 Richard Biener <rguenther@suse.de>
5077 * c-format.c (check_format_arg): Properly handle
5078 effectively signed POINTER_PLUS_EXPR offset.
5080 2014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
5082 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
5083 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
5084 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
5086 * c-opts.c (c_common_handle_option): Do not handle here.
5087 (sanitize_cpp_opts): Likewise.
5088 * c-common.c (struct reason_option_codes_t): Handle
5089 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
5091 2014-09-03 Marek Polacek <polacek@redhat.com>
5093 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
5095 2014-09-02 Jakub Jelinek <jakub@redhat.com>
5096 Balaji V. Iyer <balaji.v.iyer@intel.com>
5097 Igor Zamyatin <igor.zamyatin@intel.com>
5099 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
5100 * c-common.c (c_common_reswords): Added _Cilk_for.
5101 * c-common.h (enum rid): Added RID_CILK_FOR.
5102 (cilk_for_number_of_iterations): Add declaration.
5103 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
5105 * c-pragma.c (init_pragma): Register "grainsize" pragma.
5106 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
5108 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
5110 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
5111 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
5112 Wundef): Use CPP, Var and Init.
5113 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
5115 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
5117 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
5118 * c-opts.c (c_common_handle_option): Do not handle here.
5120 2014-08-25 Jason Merrill <jason@redhat.com>
5122 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
5123 -std=c++14 and -std=gnu++14, rather than the reverse.
5124 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
5125 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
5126 * c-common.h (cxx_dialect): Remove cxx1y.
5128 2014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
5130 * c-common.h (enum cxx_dialect): Add cxx14.
5131 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
5132 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
5133 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
5135 2014-08-22 Jason Merrill <jason@redhat.com>
5137 * c.opt (std=gnu++17): Fix alias.
5139 2014-08-22 Marek Polacek <polacek@redhat.com>
5142 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
5143 check for vector types. Drop LHS argument.
5144 * c-common.h (warn_logical_not_parentheses): Adjust.
5146 2014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
5148 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
5149 (Wmultichar): Likewise.
5150 (Wdate-time): Use C-family languages instead of Common. Use CPP
5152 * c-opts.c (c_common_handle_option): Do not handle the above
5154 (sanitize_cpp_opts): Likewise.
5156 2014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
5159 * c-opts.c: Include tree-diagnostics.h.
5160 (c_diagnostic_finalizer): New.
5161 (c_common_initialize_diagnostics): Use it.
5163 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
5165 PR preprocessor/51303
5166 * c-common.c (struct reason_option_codes_t option_codes):
5167 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
5169 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
5173 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
5174 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
5175 (c_common_post_options): Call init_global_opts_from_cpp.
5176 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
5178 2014-08-19 Marek Polacek <polacek@redhat.com>
5181 * c-common.c (maybe_warn_bool_compare): New function.
5182 * c-common.h (maybe_warn_bool_compare): Declare.
5183 * c.opt (Wbool-compare): New option.
5185 2014-08-19 Marek Polacek <polacek@redhat.com>
5187 * c.opt (Wc99-c11-compat): New option.
5189 2014-08-19 Marek Polacek <polacek@redhat.com>
5191 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
5192 to warn_c90_c99_compat.
5193 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
5196 2014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
5197 Steven Bosscher <steven@gcc.gnu.org>
5200 * c-format.c: Add extra_arg_loc and format_string_loc to struct
5201 format_check_results.
5202 (check_function_format): Use true and add comment for boolean
5204 (finish_dollar_format_checking): Use explicit location when warning.
5205 (check_format_info): Likewise.
5206 (check_format_arg): Set extra_arg_loc and format_string_loc.
5207 (check_format_info_main): Use explicit location when warning.
5208 (check_format_types): Pass explicit location.
5209 (format_type_warning): Likewise.
5211 2014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
5214 * c-format.c: Handle Fortran flags.
5216 2014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
5219 * array-notation-common.c (find_rank): Added handling for other
5220 types of references.
5222 2014-08-10 Marek Polacek <polacek@redhat.com>
5225 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
5226 * c.opt (Wc90-c99-compat): Add option.
5228 2014-08-07 Trevor Saunders <tsaunders@mozilla.com>
5230 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
5232 2014-08-03 Marek Polacek <polacek@redhat.com>
5234 * c-common.c (check_case_value): Add location_t parameter. Use it.
5235 (c_add_case_label): Pass loc to check_case_value.
5237 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
5239 * cilk.c: Use hash_map instead of pointer_map.
5241 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
5243 * c-gimplify.c: Use hash_set instead of pointer_set.
5245 2014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
5248 * array-notation-common.c (extract_array_notation_exprs): Handling
5251 2014-08-01 Jakub Jelinek <jakub@redhat.com>
5253 * c-common.h (min_align_of_type): Removed prototype.
5254 * c-common.c (min_align_of_type): Removed.
5255 * c-ubsan.h (ubsan_maybe_instrument_reference,
5256 ubsan_maybe_instrument_member_call): New prototypes.
5257 * c-ubsan.c: Include stor-layout.h and builtins.h.
5258 (ubsan_maybe_instrument_reference_or_call,
5259 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
5262 2014-07-31 Marc Glisse <marc.glisse@inria.fr>
5265 * c.opt (-Wreturn-local-addr): Move to common.opt.
5267 2014-07-30 Jason Merrill <jason@redhat.com>
5272 * c.opt (-fuse-all-virtuals): New.
5274 2014-07-30 Tom Tromey <tromey@redhat.com>
5277 * c.opt (Wdesignated-init): New option.
5278 * c-common.c (c_common_attribute_table): Add "designated_init".
5279 (handle_designated_init): New function.
5281 2014-07-24 Marek Polacek <polacek@redhat.com>
5284 * c-opts.c (c_finish_options): If -imacros is in effect, return.
5286 2014-07-16 Dodji Seketeli <dodji@redhat.com>
5288 PR preprocessor/60723 - missing system-ness marks for macro tokens
5289 * c-ppoutput.c (struct print::prev_was_system_token): New data
5291 (init_pp_output): Initialize it.
5292 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
5293 (do_line_change): Return a flag saying if a line marker was
5295 (scan_translation_unit): Detect if the system-ness of the token we
5296 are about to emit is different from the one of the previously
5297 emitted token. If so, emit a line marker. Avoid emitting useless
5298 adjacent line markers. Avoid emitting line markers for tokens
5299 originating from the expansion of built-in macros.
5300 (scan_translation_unit_directives_only): Adjust.
5302 2014-07-15 Marek Polacek <polacek@redhat.com>
5304 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
5305 TYPE_MAX_VALUE is NULL.
5307 2014-07-14 Jakub Jelinek <jakub@redhat.com>
5310 * c.opt (Wmemset-transposed-args): New warning.
5312 2014-07-10 Jason Merrill <jason@redhat.com>
5316 * c.opt (-fuse-all-virtuals): New.
5318 2014-07-09 Richard Biener <rguenther@suse.de>
5321 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
5322 using unsigned arithmetic if overflow does not wrap instead of
5323 if overflow is undefined.
5325 2014-07-06 Marek Polacek <polacek@redhat.com>
5328 * c.opt (Wsizeof-array-argument): New option.
5330 2014-07-03 Jakub Jelinek <jakub@redhat.com>
5332 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
5333 comments->count <= 1, as comments->entries might be NULL.
5335 2014-07-01 Marek Polacek <polacek@redhat.com>
5337 * c.opt (Wint-conversion): New option.
5339 2014-07-01 Marek Polacek <polacek@redhat.com>
5342 * c.opt (Wincompatible-pointer-types): New option.
5344 2014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
5347 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
5348 Do not discard TYPE_QUALS of type.
5350 2014-06-26 Jason Merrill <jason@redhat.com>
5352 * c-common.h (enum cxx_dialect): Add cxx1z.
5353 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
5354 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
5356 2014-06-26 Teresa Johnson <tejohnson@google.com>
5358 * c-common.h (get_dump_info): Declare.
5359 * c-gimplify.c (c_genericize): Use saved dump files.
5360 * c-opts.c (c_common_parse_file): Begin and end dumps
5361 once around parsing invocation.
5362 (get_dump_info): New function.
5364 2014-06-23 Marek Polacek <polacek@redhat.com>
5365 Andrew MacLeod <amacleod@redhat.com>
5368 * c-common.c (get_atomic_generic_size): Don't segfault if the
5369 type doesn't have a size.
5371 2014-06-20 Marek Polacek <polacek@redhat.com>
5373 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
5374 (ubsan_walk_array_refs_r): New function.
5375 (c_genericize): Instrument array bounds.
5376 * c-ubsan.c: Include "internal-fn.h".
5377 (ubsan_instrument_division): Mark instrumented arrays as having
5378 side effects. Adjust ubsan_type_descriptor call.
5379 (ubsan_instrument_shift): Likewise.
5380 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
5381 (ubsan_instrument_bounds): New function.
5382 (ubsan_array_ref_instrumented_p): New function.
5383 (ubsan_maybe_instrument_array_ref): New function.
5384 * c-ubsan.h (ubsan_instrument_bounds): Declare.
5385 (ubsan_array_ref_instrumented_p): Declare.
5386 (ubsan_maybe_instrument_array_ref): Declare.
5388 2014-06-20 Hale Wang <hale.wang@arm.com>
5391 * c.opt (fshort-enums): Add to LTO.
5392 * c.opt (fshort-wchar): Likewise.
5394 2014-06-16 Marek Polacek <polacek@redhat.com>
5397 * c.opt (Wswitch-bool): Add Var.
5399 2014-06-12 Jakub Jelinek <jakub@redhat.com>
5402 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
5403 #pragma omp target teams or
5404 #pragma omp {,target }teams distribute simd.
5406 2014-06-12 Jason Merrill <jason@redhat.com>
5408 * c.opt (Wabi=, fabi-compat-version): New.
5409 * c-opts.c (c_common_handle_option): Handle -Wabi=.
5410 (c_common_post_options): Handle flag_abi_compat_version default.
5411 Disallow -fabi-compat-version=1.
5412 * c-common.h (abi_version_crosses): New.
5414 2014-06-11 Jan Hubicka <hubicka@ucw.cz>
5416 * c-common.c (handle_section_attribute): Update handling for
5417 section names that are no longer trees.
5419 2014-06-10 Jakub Jelinek <jakub@redhat.com>
5422 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
5423 (omp_pragmas): ... back here.
5425 2014-06-05 Marek Polacek <polacek@redhat.com>
5428 * c-common.c (warn_logical_not_parentheses): New function.
5429 * c-common.h (warn_logical_not_parentheses): Declare.
5430 * c.opt (Wlogical-not-parentheses): New option.
5432 2014-06-04 Marek Polacek <polacek@redhat.com>
5435 * c-common.c (check_case_bounds): Add location parameter.
5437 (c_add_case_label): Pass loc to check_case_bounds.
5439 2014-06-03 Marek Polacek <polacek@redhat.com>
5442 * c.opt (Wswitch-bool): New option.
5444 2014-05-22 Thomas Schwinge <thomas@codesourcery.com>
5446 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
5448 (record_types_used_by_current_var_decl): Move prototype to where
5451 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
5452 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
5453 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
5455 2014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
5457 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
5458 * c-common.c (c_common_nodes_and_builtins): Don't initialize
5460 * c-pretty-print.c (pp_c_void_constant): New function.
5461 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
5462 (c_pretty_printer::expression): Handle VOID_CST.
5463 * cilk.c (extract_free_variables): Likewise.
5464 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
5465 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
5467 2014-05-17 Trevor Saunders <tsaunders@mozilla.com>
5469 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
5470 * c-pragma.c (push_alignment): Adjust.
5471 (handle_pragma_push_options): Likewise.
5473 2014-05-09 Marek Polacek <polacek@redhat.com>
5476 * c-common.c (check_user_alignment): Return -1 if alignment is error
5478 (handle_aligned_attribute): Don't call default_conversion on
5480 (handle_vector_size_attribute): Likewise.
5481 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
5482 (handle_sentinel_attribute): Call default_conversion and allow even
5483 integral types as an argument.
5485 2014-05-08 Marek Polacek <polacek@redhat.com>
5488 * c-common.c (min_align_of_type): New function factored out from...
5489 (c_sizeof_or_alignof_type): ...here.
5490 * c-common.h (min_align_of_type): Declare.
5492 2014-05-08 Marek Polacek <polacek@redhat.com>
5495 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
5496 parameter type of main.
5498 2014-05-07 DJ Delorie <dj@redhat.com>
5500 * c-cppbuiltin.c (print_bits_of_hex): New.
5501 (builtin_define_type_minmax): Print values using hex so as not to
5502 require a pre-computed list of string values.
5504 2014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
5505 Mike Stump <mikestump@comcast.net>
5506 Richard Sandiford <rdsandiford@googlemail.com>
5508 * c-ada-spec.c: Include wide-int.h.
5509 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
5510 (dump_generic_ada_node): Use wide-int interfaces.
5511 * c-common.c: Include wide-int-print.h.
5512 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
5513 (pointer_int_sum): Use wide-int interfaces.
5514 (c_common_nodes_and_builtins): Use make_int_cst.
5515 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
5516 (handle_alloc_size_attribute): Use wide-int interfaces.
5517 (get_nonnull_operand): Likewise.
5518 * c-format.c (get_constant): Use tree_fits_uhwi_p.
5519 * c-lex.c: Include wide-int.h.
5520 (narrowest_unsigned_type): Take a widest_int rather than two
5522 (narrowest_signed_type): Likewise.
5523 (interpret_integer): Update accordingly. Use wide-int interfaces.
5524 (lex_charconst): Use wide-int interfaces.
5525 * c-pretty-print.c: Include wide-int.h.
5526 (pp_c_integer_constant): Use wide-int interfaces.
5527 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
5528 INT_CST_LT_UNSIGNED.
5530 2014-05-06 Richard Biener <rguenther@suse.de>
5532 * c-opts.c (c_common_post_options): For -freestanding,
5533 -fno-hosted and -fno-builtin disable pattern recognition
5534 if not enabled explicitely.
5536 2014-05-02 Marek Polacek <polacek@redhat.com>
5538 * c.opt (Wsizeof-pointer-memaccess): Describe option.
5540 2014-05-01 Marek Polacek <polacek@redhat.com>
5543 * c.opt (Wdiscarded-qualifiers): Add.
5545 2014-04-30 Marek Polacek <polacek@redhat.com>
5547 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
5548 INT_MIN / -1 sanitization only for integer types.
5550 2014-04-25 Marek Polacek <polacek@redhat.com>
5553 * c-common.c (handle_noinline_attribute): Warn if the attribute
5554 conflicts with always_inline attribute.
5555 (handle_always_inline_attribute): Warn if the attribute conflicts
5556 with noinline attribute.
5558 2014-04-25 Marek Polacek <polacek@redhat.com>
5561 * c-common.c (check_main_parameter_types): Warn about variadic main.
5563 2014-04-24 Mike Stump <mikestump@comcast.net>
5565 * c.opt (Wshadow-ivar): Default to on.
5567 2014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
5569 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
5571 2014-04-23 Marek Polacek <polacek@redhat.com>
5573 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
5575 2014-04-22 Jakub Jelinek <jakub@redhat.com>
5578 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
5579 if flag_sanitize_undefined_trap_on_error.
5580 (ubsan_instrument_division, ubsan_instrument_shift,
5581 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
5582 if !flag_sanitize_recover.
5584 2014-04-22 Marc Glisse <marc.glisse@inria.fr>
5587 * c-common.c (registered_builtin_types): Make non-static.
5588 * c-common.h (registered_builtin_types): Declare.
5590 2014-04-14 Richard Biener <rguenther@suse.de>
5591 Marc Glisse <marc.glisse@inria.fr>
5594 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
5595 apply may-alias the scalar pointer type when applicable.
5597 2014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
5600 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
5601 as possible argument for Cilk_spawn.
5603 2014-04-11 Tobias Burnus <burnus@net-b.de>
5606 * c.opt (Wformat-signedness): Add
5607 * c-format.c(check_format_types): Use it.
5609 2014-04-11 Jason Merrill <jason@redhat.com>
5612 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
5613 default_conversion for an array argument.
5615 2014-04-08 Marek Polacek <polacek@redhat.com>
5618 * c-ubsan.c: Include asan.h.
5619 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
5621 2014-04-03 Nathan Sidwell <nathan@codesourcery.com>
5623 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
5625 2014-04-02 Marek Polacek <polacek@redhat.com>
5627 * c-common.h (c_expand_expr): Remove declaration.
5629 2014-03-28 Jakub Jelinek <jakub@redhat.com>
5632 * c-common.c (add_atomic_size_parameter): When creating new
5633 params vector, push the size argument first.
5635 2014-03-26 Jakub Jelinek <jakub@redhat.com>
5637 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5638 ubsan_instrument_vla, ubsan_instrument_return): Adjust
5639 ubsan_create_data callers.
5641 2014-03-22 Jakub Jelinek <jakub@redhat.com>
5644 * c-opts.c (c_finish_options): Restore cb_file_change call to
5647 2014-03-13 Jakub Jelinek <jakub@redhat.com>
5650 * c-pragma.c (apply_pragma_weak): Only look at
5651 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
5652 DECL_ASSEMBLER_NAME_SET_P (decl).
5653 (maybe_apply_pending_pragma_weaks): Exit early if
5654 vec_safe_is_empty (pending_weaks) rather than only when
5656 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
5657 set assembler name back to NULL afterwards.
5659 2014-03-11 Jason Merrill <jason@redhat.com>
5661 * c.opt: Add -std=gnu++14.
5663 2014-03-11 Ian Bolton <ian.bolton@arm.com>
5665 * c-opts.c (c_common_post_options): Don't override
5666 -ffp-contract=fast if unsafe-math-optimizations is on.
5668 2014-03-08 Paulo Matos <paulo@matos-sorge.com>
5670 * c.opt: Enable LTO FE for fshort-double.
5672 2014-03-07 Jason Merrill <jason@redhat.com>
5674 * c.opt: Add -std=c++14.
5676 2014-03-06 Marek Polacek <polacek@redhat.com>
5679 * cilk.c (contains_cilk_spawn_stmt): New function.
5680 (contains_cilk_spawn_stmt_walker): Likewise.
5681 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
5682 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
5684 2014-03-03 Jakub Jelinek <jakub@redhat.com>
5686 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
5687 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
5688 even when flag_preprocess_only.
5690 2014-02-26 Jason Merrill <jason@redhat.com>
5694 * c-common.c (shorten_compare): Don't check
5695 c_inhibit_evaluation_warnings.
5697 2014-02-19 Jakub Jelinek <jakub@redhat.com>
5700 * c-common.c (c_common_nodes_and_builtins): When initializing
5701 c_uint{16,32,64}_type_node, also set corresponding
5702 uint{16,32,64}_type_node to the same value.
5705 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
5706 for PRAGMA_IVDEP if flag_preprocess_only.
5708 2014-02-12 Jakub Jelinek <jakub@redhat.com>
5711 * c-common.c (merge_tlist): If copy is true, call new_tlist,
5712 if false, add ADD itself, rather than vice versa.
5713 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
5714 copy. For SAVE_EXPR, only call merge_tlist once.
5716 2014-02-08 Jakub Jelinek <jakub@redhat.com>
5719 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
5721 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
5723 (c_common_attribute_table): Add alloc_align and assume_aligned
5726 2014-02-06 Marek Polacek <polacek@redhat.com>
5729 * c-common.c (warn_for_sign_compare): Call warning_at with location
5732 2014-02-05 Marek Polacek <polacek@redhat.com>
5735 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
5738 2014-02-04 Marek Polacek <polacek@redhat.com>
5741 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
5744 2014-02-03 Marc Glisse <marc.glisse@inria.fr>
5748 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
5749 handle_vector_size_attribute, handle_nonnull_attribute): Call
5750 default_conversion on the attribute argument.
5751 (handle_nonnull_attribute): Increment the argument number.
5753 2014-01-31 Marek Polacek <polacek@redhat.com>
5756 * c-common.c (add_atomic_size_parameter): Pass vNULL to
5757 build_function_call_vec.
5758 (resolve_overloaded_builtin): Likewise.
5759 * c-common.h (build_function_call_vec): Adjust declaration.
5761 2014-01-30 Marek Polacek <polacek@redhat.com>
5764 * c-common.h (unsafe_conversion_p): Adjust declaration.
5765 (warnings_for_convert_and_check): Likewise.
5766 (convert_and_check): Likewise.
5767 * c-common.c (unsafe_conversion_p): Add location parameter. Call
5768 expansion_point_location_if_in_system_header on it.
5769 (warnings_for_convert_and_check): Add location parameter. Call
5770 expansion_point_location_if_in_system_header on it. Use it.
5771 (convert_and_check): Add location parameter. Use it.
5772 (conversion_warning): Likewise.
5773 (c_add_case_label): Adjust convert_and_check calls.
5774 (scalar_to_vector): Adjust unsafe_conversion_p calls.
5776 2014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
5778 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
5780 * c-pragma.c (init_pragma): Likewise.
5783 2014-01-23 Marek Polacek <polacek@redhat.com>
5786 * c-common.c (shorten_compare): Add location_t parameter.
5787 * c-common.h (shorten_binary_op): Adjust declaration.
5789 2014-01-23 Marek Polacek <polacek@redhat.com>
5792 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
5793 * c-common.h: Declare it.
5795 2014-01-20 Eric Botcazou <ebotcazou@adacore.com>
5797 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
5798 * c-ada-spec.c (dump_ads): Likewise.
5799 (cpp_check): Likewise.
5800 (dump_ada_specs): Likewise.
5802 2014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
5805 * c-common.c (handle_no_instrument_function_attribute): Allow
5806 no_instrument_function attribute in class member
5807 definition/declaration.
5809 2014-01-15 Jakub Jelinek <jakub@redhat.com>
5812 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
5813 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
5814 being COMPOUND_EXPR.
5815 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
5816 operand a SAVE_EXPR and second MODIFY_EXPR.
5818 2014-01-09 Jakub Jelinek <jakub@redhat.com>
5821 * c-pch.c (c_common_write_pch): Call
5822 prepare_target_option_nodes_for_pch.
5824 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
5826 Update copyright years
5828 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
5830 * array-notation-common.c, c-cilkplus.c: Use the standard form for
5831 the copyright notice.
5833 2013-12-28 Eric Botcazou <ebotcazou@adacore.com>
5835 * c-ada-spec.c (print_constructor): New function.
5836 (print_destructor): Retrieve the origin of the destructor.
5837 (print_ada_declaration): Revamp handling of constructors/destructors.
5839 2013-12-23 Stuart Hastings <stuart@apple.com>
5840 Bill Maddox <maddox@google.com>
5841 Jason Merrill <jason@redhat.com>
5843 * c.opt: Add -fdeclone-ctor-dtor.
5844 * c-opts.c (c_common_post_options): Default to on iff -Os.
5846 2013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
5848 * c-common.c (c_common_attribute_table): Added "cilk simd function"
5850 * c-pragma.h (enum pragma_cilk_clause): Remove.
5851 (enum pragma_omp_clause): Added the following fields:
5852 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
5853 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
5854 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
5855 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
5856 PRAGMA_CILK_CLAUSE_UNIFORM.
5859 2013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
5861 * cilk.c (cilk_outline): Made this function non-static.
5862 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
5863 (create_cilk_wrapper): Added a new parameter: a function pointer.
5864 (c_install_body_w_frame_cleanup): Remove
5865 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
5866 * c-common.h (cilk_outline): New prototype.
5867 (gimplify_cilk_spawn): Removed two parameters.
5868 (cilk_install_body_with_frame_cleanup): New prototype.
5869 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
5870 CILK_SPAWN_STMT case.
5872 2013-12-11 Bernd Schmidt <bernds@codesourcery.com>
5874 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
5876 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
5877 (int_array_type_node): Remove.
5878 * c-common.c (c_common_nodes_and_builtins): Don't build it.
5880 2013-12-05 Marek Polacek <polacek@redhat.com>
5883 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
5884 [ADJUST_FIELD_ALIGN].
5886 2013-12-04 Joseph Myers <joseph@codesourcery.com>
5889 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
5890 and check field alignment if set.
5891 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
5892 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
5894 2013-12-04 Jakub Jelinek <jakub@redhat.com>
5895 Marek Polacek <polacek@redhat.com>
5897 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
5898 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
5900 2013-11-29 H.J. Lu <hongjiu.lu@intel.com>
5903 * cilk.c (gimplify_cilk_spawn): Properly handle function without
5906 2013-11-29 Jakub Jelinek <jakub@redhat.com>
5909 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
5910 goto invalid. If it is error_mark_node, don't issue further
5913 2013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
5915 * c.opt (Wopenmp-simd): New.
5917 2013-11-22 Jakub Jelinek <jakub@redhat.com>
5919 * c-ubsan.h (ubsan_instrument_return): New prototype.
5920 * c-ubsan.c (ubsan_instrument_return): New function.
5922 2013-11-22 Andrew MacLeod <amacleod@redhat.com>
5924 * c-common.c: Add required include files from gimple.h.
5925 * c-gimplify.c: Likewise
5928 2013-11-22 David Malcolm <dmalcolm@redhat.com>
5930 * c-common.c (unsafe_conversion_p): Remove use of
5931 EXPR_LOC_OR_HERE macro.
5932 (conversion_warning): Likewise.
5933 (warnings_for_convert_and_check): Likewise.
5934 (warn_for_collisions_1): Likewise.
5935 (shorten_compare): Likewise, and remove use of in_system_header
5936 macro, using the location from the former.
5937 * c-lex.c (dump_one_header): Remove use of input_filename macro.
5938 (cb_def_pragma): Remove use of in_system_header macro.
5939 (lex_string): Likewise.
5940 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
5942 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
5943 Mike Stump <mikestump@comcast.net>
5944 Richard Sandiford <rdsandiford@googlemail.com>
5946 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
5947 instead of TREE_INT_CST_LOW, in cases where there is a protecting
5948 tree_fits_shwi_p or tree_fits_uhwi_p.
5949 (dump_generic_ada_node): Likewise.
5950 * c-format.c (check_format_arg): Likewise.
5951 * c-pretty-print.c (pp_c_integer_constant): Likewise.
5953 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
5955 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
5957 2013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
5960 * c-common.c (unsafe_conversion_p): Make this function
5961 return an enumeration with more detail.
5962 (conversion_warning): Use the new return type of
5963 unsafe_conversion_p to separately warn either about conversions
5964 that lower floating point number precision or about the other
5965 kinds of conversions.
5966 * c-common.h (enum conversion_safety): New enumeration.
5967 (unsafe_conversion_p): switching return type to
5968 conversion_safety enumeration.
5969 * c.opt: Adding new warning -Wfloat-conversion and
5970 enabling it with -Wconversion.
5972 2013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
5974 * c-opts.c: Include plugin.h.
5975 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
5977 2013-11-19 Marek Polacek <polacek@redhat.com>
5979 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
5981 (ubsan_instrument_shift): Likewise.
5982 (ubsan_instrument_vla): Likewise.
5984 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
5986 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
5987 cast to unsigned type.
5989 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
5991 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
5993 (complete_array_type): Update comment to refer to tree_to_[su]hwi
5994 rather than tree_low_cst.
5996 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
5998 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
5999 tree_to_uhwi throughout.
6001 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6003 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
6004 tree_low_cst (..., 0) with tree_to_shwi throughout.
6006 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6008 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
6009 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
6011 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6013 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
6014 host_integerp (..., 0) with tree_fits_shwi_p throughout.
6016 2013-11-15 Aldy Hernandez <aldyh@redhat.com>
6018 * c-cilkplus.c: New file.
6019 * c-common.c (readonly_error): Add location argument.
6020 * c-common.h (readonly_error): Same.
6021 (c_finish_cilk_clauses): Protoize.
6022 (c_check_cilk_loop): Same.
6023 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
6024 Do not fail on error_mark_node.
6025 Abstract increment canonicalization to here...
6026 (c_omp_for_incr_canonicalize_ptr): New.
6027 c-pragma.c (init_pragma): Register "simd" pragma.
6028 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
6029 (enum pragma_cilk_clause): New.
6031 2013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
6033 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
6034 wchar_type and host_integerp checks.
6036 2013-11-14 Andrew MacLeod <amacleod@redhat.com>
6038 * c-common.c: Likewise.
6039 * c-gimplify.c: Likewise.
6042 2013-11-14 Diego Novillo <dnovillo@google.com>
6044 * c-common.c: Include fold-const.h.
6045 Include stor-layout.h.
6047 Include stringpool.h.
6050 Include trans-mem.h.
6051 * c-cppbuiltin.c: Include stor-layout.h.
6052 Include stringpool.h.
6053 * c-format.c: Include stringpool.h.
6054 * c-lex.c: Include stringpool.h.
6055 Include stor-layout.h.
6056 * c-pragma.c: Include stringpool.h.
6059 Include gcc-symtab.h.
6060 * c-pretty-print.c: Include stor-layout.h.
6062 * cilk.c: Include stringpool.h.
6065 2013-11-13 Joseph Myers <joseph@codesourcery.com>
6067 * c-common.h (enum rid): Add RID_AUTO_TYPE.
6068 * c-common.c (c_common_reswords): Add __auto_type.
6069 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
6071 2013-11-12 Andrew MacLeod <amacleod@redhat.com>
6073 * c-common.c: Include gimplify.h.
6074 * c-gimplify.c: Likewise.
6076 * c-omp.c: Include gimple-expr.h instead of gimple.h.
6077 * c-ubsan.c: Don't include gimple.h.
6079 2013-11-12 Joseph Myers <joseph@codesourcery.com>
6081 * c-common.c (c_common_reswords): Add _Thread_local.
6083 2013-11-09 Joseph Myers <joseph@codesourcery.com>
6085 * c-common.c (atomic_size_supported_p): New function.
6086 (resolve_overloaded_atomic_exchange)
6087 (resolve_overloaded_atomic_compare_exchange)
6088 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
6089 Use it instead of comparing size with a local list of sizes.
6091 2013-11-07 Andrew MacLeod <amacleod@redhat.com>
6092 Joseph Myers <joseph@codesourcery.com>
6094 * c-common.h (enum rid): Add RID_ATOMIC.
6095 * c-common.c (c_common_reswords): Add _Atomic.
6096 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
6097 (keyword_is_type_qualifier): Accept RID_ATOMIC.
6098 * c-format.c (check_format_types): Check for extra _Atomic
6099 qualifiers in format argument.
6100 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
6101 (pp_c_type_qualifier_list): Mention _Atomic in comment.
6103 2013-11-06 Tobias Burnus <burnus@net-b.de>
6105 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
6107 2013-11-06 Joseph Myers <joseph@codesourcery.com>
6109 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
6111 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
6112 to mean lack of IEEE 754 support.
6114 2013-11-05 Tobias Burnus <burnus@net-b.de>
6116 * c.opt (-Wdate-time): New option
6117 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
6119 2013-11-05 Joseph Myers <joseph@codesourcery.com>
6121 * c-cppbuiltin.c (cpp_iec_559_value): Test
6122 flag_excess_precision_cmdline not flag_excess_precision.
6124 2013-11-05 Tobias Burnus <burnus@net-b.de>
6126 * c.opt (fopenmp-simd): New option.
6127 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
6128 (omp_pragmas): ... this new struct.
6129 (c_pp_lookup_pragma): Also walk omp_pragmas.
6130 (init_pragma): Init pragmas for -fopenmp-simd.
6132 2013-11-04 Marek Polacek <polacek@redhat.com>
6135 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
6137 2013-11-04 Joseph Myers <joseph@codesourcery.com>
6139 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
6141 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
6143 2013-11-04 Eric Botcazou <ebotcazou@adacore.com>
6145 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
6146 (dump_ada_specs): Adjust prototype of second callback.
6147 * c-ada-spec.c (cpp_check): New global variable.
6148 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
6149 (print_generic_ada_decl): Likewise.
6150 (has_static_fields): Change return type to bool and add guard.
6151 (has_nontrivial_methods): New predicate.
6152 (is_tagged_type): Change return type to bool.
6153 (separate_class_package): Call has_nontrivial_methods.
6154 (pp_ada_tree_identifier): Minor tweaks.
6155 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
6156 (dump_ada_array_domains): Likewise.
6157 (dump_ada_array_type): Likewise.
6158 (dump_template_types): Remove cpp_check parameter and do not pass it to
6159 dump_generic_ada_node.
6160 (dump_ada_template): Likewise.
6161 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
6163 (print_ada_methods): Change return type to integer. Remove cpp_check
6164 parameter and do not pass it down.
6165 (dump_nested_types): Remove cpp_check parameter and do not pass it to
6166 dump_generic_ada_node.
6167 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
6169 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
6170 down. Use has_nontrivial_methods to recognize C++ classes. Use return
6171 value of print_ada_methods.
6172 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
6173 Set cpp_check to it before invoking dump_ada_nodes.
6174 (dump_ada_specs): Likewise.
6176 2013-11-03 Marek Polacek <polacek@redhat.com>
6178 * c-ubsan.c: Don't include hash-table.h.
6179 (ubsan_instrument_vla): New function.
6180 * c-ubsan.h: Declare it.
6182 2013-10-31 David Malcolm <dmalcolm@redhat.com>
6184 Automated part of renaming of symtab_node_base to symtab_node.
6186 Patch autogenerated by rename_symtab.py from
6187 https://github.com/davidmalcolm/gcc-refactoring-scripts
6188 revision 58bb219cc090b2f4516a9297d868c245495ee622
6190 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
6191 symtab_node_base to symtab_node.
6193 2013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
6195 Implement C++14 digit separators.
6196 * c-lex.c (interpret_float): Remove digit separators from scratch string
6197 before building real literal.
6199 2013-10-30 Jakub Jelinek <jakub@redhat.com>
6201 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
6203 2013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
6205 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
6207 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
6209 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
6210 (insert_cilk_frame): New prototype.
6211 (cilk_init_builtins): Likewise.
6212 (gimplify_cilk_spawn): Likewise.
6213 (c_cilk_install_body_w_frame_cleanup): Likewise.
6214 (cilk_detect_spawn_and_unwrap): Likewise.
6215 (cilk_set_spawn_marker): Likewise.
6216 (build_cilk_sync): Likewise.
6217 (build_cilk_spawn): Likewise.
6220 2013-10-29 David Malcolm <dmalcolm@redhat.com>
6222 Patch autogenerated by refactor_symtab.py from
6223 https://github.com/davidmalcolm/gcc-refactoring-scripts
6224 revision 58bb219cc090b2f4516a9297d868c245495ee622
6226 * c-gimplify.c (c_genericize): Update for conversion of symtab types
6227 to a true class hierarchy.
6228 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
6230 2013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
6232 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
6234 2013-10-26 Jeff Law <law@redhat.com>
6236 * c-common.c (c_define_builtins): Remove mudflap support.
6237 * c.opt: Ignore and warn for mudflap options.
6239 2013-10-24 Tobias Burnus <burnus@net-b.de>
6242 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
6243 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
6245 2013-10-23 Jason Merrill <jason@redhat.com>
6247 * c-format.c (gcc_cxxdiag_char_table): Add %X.
6249 2013-10-11 Jakub Jelinek <jakub@redhat.com>
6251 * c-common.h (omp_clause_mask::operator !=): New method.
6252 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
6253 instead of if (mask & something) tests everywhere.
6255 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
6256 201307 instead of 201107.
6257 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
6258 (c_common_attribute_table): Add "omp declare target" and
6259 "omp declare simd" attributes.
6260 (handle_omp_declare_target_attribute,
6261 handle_omp_declare_simd_attribute): New functions.
6262 * c-omp.c: Include c-pragma.h.
6263 (c_finish_omp_taskgroup): New function.
6264 (c_finish_omp_atomic): Add swapped argument, if true,
6265 build the operation first with rhs, lhs arguments and use NOP_EXPR
6267 (c_finish_omp_for): Add code argument, pass it down to make_code.
6268 (c_omp_split_clauses): New function.
6269 (c_split_parallel_clauses): Removed.
6270 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
6271 c_omp_declare_simd_clauses_to_decls): New functions.
6272 * c-common.h (omp_clause_mask): New type.
6273 (OMP_CLAUSE_MASK_1): Define.
6274 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
6275 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
6276 omp_clause_mask::operator |, omp_clause_mask::operator &,
6277 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
6278 omp_clause_mask::operator ==): New methods.
6279 (enum c_omp_clause_split): New.
6280 (c_finish_omp_taskgroup): New prototype.
6281 (c_finish_omp_atomic): Add swapped argument.
6282 (c_finish_omp_for): Add code argument.
6283 (c_omp_split_clauses): New prototype.
6284 (c_split_parallel_clauses): Removed.
6285 (c_omp_declare_simd_clauses_to_numbers,
6286 c_omp_declare_simd_clauses_to_decls): New prototypes.
6287 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
6288 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
6289 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
6290 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
6291 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
6292 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
6293 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
6294 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
6295 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
6296 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
6297 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
6298 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
6299 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
6300 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
6301 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
6302 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
6303 PRAGMA_OMP_CLAUSE_UNIFORM.
6305 2013-10-09 Marc Glisse <marc.glisse@inria.fr>
6307 PR tree-optimization/20318
6308 * c-common.c (handle_returns_nonnull_attribute): New function.
6309 (c_common_attribute_table): Add returns_nonnull.
6311 2013-10-03 Marc Glisse <marc.glisse@inria.fr>
6314 * c.opt (fcheck-new): Move to common.opt.
6316 2013-09-25 Marek Polacek <polacek@redhat.com>
6317 Jakub Jelinek <jakub@redhat.com>
6320 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
6321 an expression if we can prove it is correct.
6322 (ubsan_instrument_division): Likewise. Remove unnecessary
6325 2013-09-18 Marek Polacek <polacek@redhat.com>
6328 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
6330 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
6332 2013-09-14 Iain Sandoe <iain@codesourcery.com>
6335 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
6336 fobjc-gc, freplace-objc-classes): Accept for LTO.
6338 2013-09-13 Jacek Caban <jacek@codeweavers.com>
6340 * c-target.def: New hook
6342 2013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
6345 * c.opt (Wdelete-incomplete): Add.
6347 2013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
6349 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
6350 (vector_types_compatible_elements_p): New function.
6351 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
6353 (vector_types_compatible_elements_p): Declare.
6355 2013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
6357 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
6358 a virtual member function.
6359 (pp_simple_type_specifier): Remove.
6360 (pp_c_type_specifier): Likewise.
6361 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
6362 Rename from pp_c_type_specifier. Adjust.
6363 (c_pretty_printer::c_pretty_printer): Do not assign to
6364 simple_type_specifier.
6366 2013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6368 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
6370 (c_pretty_printer::storage_class_specifier): Likewise.
6371 (c_pretty_printer::initializer): Likewise.
6372 (pp_declaration): Remove.
6373 (pp_declaration_specifiers): Likewise.
6374 (pp_abstract_declarator): Likewise.
6375 (pp_declarator): Likewise.
6376 (pp_type_id): Likewise.
6377 (pp_statement): Likewise.
6378 (pp_constant): Likewise.
6379 (pp_id_expression): Likewise.
6380 (pp_primary_expression): Likewise.
6381 (pp_unary_expression): Likewise.
6382 (pp_multiplicative_expression): Likewise.
6383 (pp_conditional_expression): Likewise.
6384 (pp_assignment_expression): Likewise.
6385 (pp_expression): Likewise.
6386 (pp_c_type_id): Likewise.
6387 (pp_c_storage_class_specifier): Likewise.
6388 * c-pretty-print.c (pp_c_type_cast): Tidy.
6389 (pp_c_pointer): Likewise.
6390 (pp_c_type_specifier): Likewise.
6391 (pp_c_parameter_type_list): Likewise.
6392 (pp_c_function_definition): Likewise.
6393 (pp_c_init_declarator): Likewise.
6394 (pp_c_initializer_list): Likewise.
6395 (pp_c_constructor_elts): Likewise.
6396 (c_pretty_printer::direct_abstract_declarator): Likewise.
6397 (c_pretty_printer::declaration_specifiers): Likewise.
6398 (c_pretty_printer::primary_expression): Likewise.
6399 (c_pretty_printer::postfix_expression): Likewise.
6400 (c_pretty_printer::type_id): Rename from pp_c_type_id.
6401 (c_pretty_printer::storage_class_specifier): Rename from
6402 pp_c_storage_class_specifier.
6403 (c_pretty_printer::initializer): Rename from pp_c_initializer.
6404 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
6405 storage_class_specifier, initializer, offset_list, flags.
6407 2013-08-30 Marek Polacek <polacek@redhat.com>
6409 * c-ubsan.c: New file.
6410 * c-ubsan.h: New file.
6412 2013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
6414 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
6416 (c_pretty_printer::declaration_specifiers): Likewise.
6417 (c_pretty_printer::declarator): Likewise.
6418 (c_pretty_printer::abstract_declarator): Likewise.
6419 (c_pretty_printer::direct_abstract_declarator): Likewise.
6420 (c_pretty_printer::direct_declarator): Likewise.
6421 (c_pretty_printer::function_specifier): Likewise.
6422 (pp_declaration): Adjust.
6423 (pp_declaration_specifiers): Likewise.
6424 (pp_abstract_declarator): Likewise.
6425 (pp_direct_declarator): Likewise.
6426 (pp_function_specifier): Likewise.
6427 (pp_direct_abstract_declarator): Remove as unused.
6428 (pp_c_declaration): Remove.
6429 (pp_c_declaration_specifiers): Likewise.
6430 (pp_c_declarator): Likewise.
6431 (pp_c_direct_declarator): Likewise.
6432 (pp_c_function_specifier): Likewise.
6433 (pp_c_direct_abstract_declarator): Likewise.
6434 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
6435 from pp_c_abstract_declarator. Adjust.
6436 (c_pretty_printer::direct_abstract_declarator): Rename from
6437 pp_c_direct_abstract_declarator. Adjust.
6438 (c_pretty_printer::function_specifier): Rename from
6439 pp_c_function_specifier. Adjust.
6440 (c_pretty_printer::declaration_specifiers): Rename from
6441 pp_c_declaration_specifiers. Adjust.
6442 (c_pretty_printer::direct_declarator): Rename from
6443 pp_c_direct_declarator. Adjust.
6444 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
6445 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
6446 (c_pretty_printer::c_pretty_printer): Do not assign to
6447 declaration, declaration_specifiers, declarator,
6448 direct_declarator, direct_abstract_declarator, function_specifier.
6450 2013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
6452 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
6453 virtual member function.
6454 (c_pretty_printer::multiplicative_expression): Likewise.
6455 (c_pretty_printer::conditional_expression): Likewise.
6456 (c_pretty_printer::assignment_expression): Likewise.
6457 (c_pretty_printer::expression): Likewise.
6458 (pp_unary_expression): Adjust.
6459 (pp_multiplicative_expression): Likewise.
6460 (pp_assignment_expression): Likewise.
6461 (pp_conditional_expression): Likewise.
6462 (pp_expression): Likewise.
6463 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
6464 from pp_c_unary_expression. Adjust.
6465 (c_pretty_printer::multiplicative_expression): Rename from
6466 pp_c_multiplicative_expression. Adjust.
6467 (c_pretty_printer::conditional_expression): Rename from
6468 pp_c_conditional_expression. Adjust.
6469 (c_pretty_printer::assignment_expression): Rename from
6470 pp_c_assignment_expression. Adjust.
6471 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
6472 (c_pretty_printer::c_pretty_printer): Do not assign to
6473 unary_expression, multiplicative_expression,
6474 conditional_expression, expression.
6476 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
6478 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
6479 virtual member function.
6480 (pp_postfix_expression): Adjust.
6481 (pp_c_postfix_expression): Remove.
6482 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
6483 from pp_c_postfix_expression. Adjust.
6484 (c_pretty_printer::c_pretty_printer): Do not assign to
6487 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
6489 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
6490 virtua member function.
6491 (pp_primary_expression): Adjust.
6492 (pp_c_primary_expression): Remove.
6493 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
6494 from pp_c_primary_expression. Adjust.
6495 (pp_c_initializer_list): Use pp_primary_expression.
6496 (c_pretty_printer::c_pretty_printer): Do not assign to
6499 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
6501 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
6502 * c-pretty-print.c (M_): Remove.
6503 (c_pretty_printer::translate_string): Define.
6504 (pp_c_type_specifier): Use it.
6505 (pp_c_primary_expression): Likewise.
6506 (pp_c_expression): Likewise.
6508 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
6510 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
6512 (pp_c_id_expression): Remove.
6513 (pp_id_expression): Adjust.
6514 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
6515 pp_c_id_expression. Adjust.
6516 (pp_c_postfix_expression): Use pp_id_expression.
6517 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
6519 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
6521 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
6523 (pp_constant): Adjust.
6524 (pp_c_constant): Remove.
6525 * c-pretty-print.c (c_pretty_printer::constant): Rename from
6526 pp_c_constant. Adjust.
6528 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
6529 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
6531 2013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
6533 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
6534 (c_pretty_printer::c_pretty_printer): Declare.
6535 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
6536 c_pretty_printer_init. Adjust.
6537 (print_c_tree): Do not call c_pretty_printer_init.
6538 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
6540 2013-08-09 Arnaud Charlet <charlet@adacore.com>
6542 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
6544 2013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
6547 * c-common.c (pointer_int_sum): Add bool parameter.
6548 * c-common.h (pointer_int_sum): Adjust declaration.
6550 2013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
6552 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
6553 c_pretty_printer variable.
6555 2013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
6557 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
6559 (pp_c_base): Likewise. Adjust users.
6560 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
6561 (pp_c_whitespace): Do not call pp_base.
6562 (pp_c_left_paren): Likewise.
6563 (pp_c_right_paren): Likewise.
6564 (pp_c_left_brace): Likewise.
6565 (pp_c_right_brace): Likewise.
6566 (pp_c_left_bracket): Likewise.
6567 (pp_c_right_bracket): Likewise.
6568 (pp_c_dot): Likewise.
6569 (pp_c_ampersand): Likewise.
6570 (pp_c_star): Likewise.
6571 (pp_c_arrow): Likewise.
6572 (pp_c_semicolon): Likewise.
6573 (pp_c_complement): Likewise.
6574 (pp_c_exclamation): Likewise.
6575 (pp_c_direct_declarator): Likewise.
6576 (pp_c_ws_string): Likewise.
6577 (pp_c_identifier): Likewise.
6578 (pp_c_statement): Likewise.
6579 (print_c_tree): Likewise.
6581 2013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
6584 * c-common.c (c_parse_error): Catch user-defined literal tokens and
6585 provide useful error strings.
6587 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6589 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
6590 printer functions instead of pp_string or operators and punctuators.
6591 (dump_generic_ada_node): Likewise.
6592 * c-pretty-print.c (pp_c_type_specifier): Likewise.
6593 (pp_c_relational_expression): Likewise.
6594 (pp_c_logical_or_expression): Likewise.
6596 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6598 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
6599 functions instead of pp_character.
6600 (pp_ada_tree_identifier): Likewise.
6601 (dump_ada_double_name): Likewise.
6602 (dump_ada_function_declaration): Likewise.
6603 (dump_ada_array_domains): Likewise.
6604 (dump_template_types): Likewise.
6605 (dump_generic_ada_node): Likewise.
6606 (print_ada_declaration): Likewise.
6607 (print_ada_struct_decl): Likewise.
6608 * c-pretty-print.c (pp_c_integer_constant): Likewise.
6610 2013-07-23 Tom Tromey <tromey@redhat.com>
6612 * c-common.h (enum rid) <RID_GENERIC>: New constant.
6613 * c-common.c (c_common_reswords): Add _Generic.
6615 2013-07-21 OndÅ
\99ej BÃlka <neleai@seznam.cz>
6617 * c-common.c: Fix typos.
6618 * c-common.h: Likewise.
6620 2013-07-13 Lubos Lunak <l.lunak@suse.cz>
6623 * c-common.c (c_common_attribute_table): Add warn_unused.
6624 (handle_warn_unused_attribute): New.
6626 2013-07-10 Jakub Jelinek <jakub@redhat.com>
6628 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
6629 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
6631 2013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
6634 * c.opt: Add Wconditionally-supported.
6636 2013-07-08 Graham Stott <graham.stott@btinternet.com>
6638 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6639 unused variables l_length and l_node.
6641 2013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
6644 * c-common.c (complete_array_type): Delay folding first index
6645 like other indices. When folding, check for index overflow.
6647 2013-06-27 Marc Glisse <marc.glisse@inria.fr>
6650 * c-common.h (c_build_vec_perm_expr): New complain argument.
6651 * c-common.c (c_build_vec_perm_expr): Likewise.
6652 Use save_expr also in C++.
6654 2013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
6656 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
6657 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
6658 * c-opts.c (c_common_post_options): Likewise.
6660 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
6662 * array-notation-common.c (length_mismatch_in_expr): Changed the
6663 parameter type's from a dynamic array to a vec_tree. Also removed
6664 the size parameters.
6665 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
6668 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
6670 * c-common.h (struct cilkplus_an_parts): New structure.
6671 (struct cilkplus_an_loop_parts): Likewise.
6672 (cilkplus_extract_an_triplets): New prototype.
6673 (fix_sec_implicit_args): Likewise.
6674 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
6675 (fix_sec_implicit_args): Likewise.
6677 2013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
6679 * array-notation-common.c (find_inv_trees): Removed an unwanted
6681 * c-common.h (struct inv_list::additional_tcodes): Changed type from
6682 enum rid to enum tree_code.
6684 2013-06-11 Jan Hubicka <jh@suse.cz>
6686 * c-common.c (handle_alias_ifunc_attribute): Do not set
6687 DECL_EXTERNAL for weakref variables.
6688 * c-pragma.c (handle_pragma_weak): Make sure aliases
6689 are not declared as external.
6691 2013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
6693 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
6694 function from c/c-array-notation.c.
6695 (is_cilkplus_reduce_builtin): Likewise.
6696 (find_rank): Likewise.
6697 (extract_array_notation_exprs): Likewise.
6698 (replace_array_notations): Likewise.
6699 (find_inv_trees): Likewise.
6700 (replace_inv_trees): Likewise.
6701 (contains_array_notation_expr): Likewise.
6702 (find_correct_array_notation_type): Likewise.
6703 * c-common.h (struct inv_list): Moved this struct from the file
6704 c/c-array-notation.c and added a new field called additional tcodes.
6705 (length_mismatch_in_expr_p): New prototype.
6706 (is_cilkplus_reduce_builtin): Likewise.
6707 (find_rank): Likewise.
6708 (extract_array_notation_exprs): Likewise.
6709 (replace_array_notation): Likewise.
6710 (find_inv_trees): Likewise.
6711 (replace_inv_trees): Likewise.
6712 (find_correct_array_notation_type): Likewise.
6714 2013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
6716 * c-common.c (c_define_builtins): When cilkplus is enabled, the
6717 function array_notation_init_builtins is called.
6718 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
6719 * c-common.def (ARRAY_NOTATION_REF): New tree.
6720 * c-common.h (build_array_notation_expr): New function declaration.
6721 (build_array_notation_ref): Likewise.
6722 (extract_sec_implicit_index_arg): New extern declaration.
6723 (is_sec_implicit_index_fn): Likewise.
6724 (ARRAY_NOTATION_CHECK): New define.
6725 (ARRAY_NOTATION_ARRAY): Likewise.
6726 (ARRAY_NOTATION_START): Likewise.
6727 (ARRAY_NOTATION_LENGTH): Likewise.
6728 (ARRAY_NOTATION_STRIDE): Likewise.
6729 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
6731 (pp_c_expression): Likewise.
6732 * c.opt (flag_enable_cilkplus): New flag.
6733 * array-notation-common.c: New file.
6735 2013-05-14 Jakub Jelinek <jakub@redhat.com>
6738 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
6740 2013-05-10 Marc Glisse <marc.glisse@inria.fr>
6742 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
6745 2013-05-07 Han Shen <shenhan@google.com>
6747 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
6749 2013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
6751 * c-common.c (check_user_alignment): Emit error for negative values.
6753 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
6755 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
6757 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
6759 * c-cppbuiltin.c (c_cpp_builtins): Do not define
6760 __GXX_EXPERIMENTAL_CXX1Y__.
6762 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
6763 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
6765 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
6766 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
6767 to simply use OPT_Wpointer_arith.
6768 (c_sizeof_or_alignof_type): Likewise.
6770 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
6772 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
6774 2013-04-12 Jakub Jelinek <jakub@redhat.com>
6776 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
6777 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
6780 2013-04-07 Steven Bosscher <steven@gcc.gnu.org>
6782 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
6784 2013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
6786 * c-common.c (pointer_int_sum): Remove dead code.
6788 2013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
6791 * c-common.c (handle_optimize_attribute): Don't call
6792 save_optabs_if_changed.
6794 2013-03-05 Jakub Jelinek <jakub@redhat.com>
6797 * c-pch.c (pch_init): Free target_validity at the end.
6799 2013-03-04 Jakub Jelinek <jakub@redhat.com>
6801 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
6803 2013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
6804 Jakub Jelinek <jakub@redhat.com>
6807 * c-common.c (handle_no_sanitize_address_attribute): New function.
6808 (c_common_attribute_table): Add no_sanitize_address attribute.
6809 (handle_no_address_safety_analysis_attribute): Add
6810 no_sanitize_address attribute, not no_address_safety_analysis
6813 2013-02-18 Aldy Hernandez <aldyh@redhat.com>
6816 * c-common.c (handle_optimize_attribute): Call
6817 save_optabs_if_changed.
6819 2013-02-18 Jakub Jelinek <jakub@redhat.com>
6820 Steven Bosscher <steven@gcc.gnu.org>
6823 * c-opts.c (c_common_post_options): If debug info is enabled
6824 and non-dwarf*, refuse to load PCH files and when writing PCH
6827 2013-02-05 Jakub Jelinek <jakub@redhat.com>
6830 * c-common.c (handle_error_attribute): Fix condition.
6832 2013-01-30 Jakub Jelinek <jakub@redhat.com>
6835 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
6837 2013-01-18 Jason Merrill <jason@redhat.com>
6840 * c.opt (-fextern-tls-init): New.
6841 * c-opts.c (c_common_post_options): Handle it.
6843 2013-01-09 Jakub Jelinek <jakub@redhat.com>
6846 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
6847 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
6848 and is either negative or bigger or equal to type precision
6849 of the first operand.
6851 2012-12-03 Marek Polacek <polacek@redhat.com>
6854 * c-common.c (check_user_alignment): Swap order of tests,
6855 check TREE_CODE first.
6857 2012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
6860 * c-common.h (overflow_type): New enum.
6861 (build_userdef_literal): Add overflow_type argument.
6862 (tree_userdef_literal): Add overflow_type.
6863 (USERDEF_LITERAL_OVERFLOW): New access macro.
6864 * c-common.c (build_userdef_literal): Add overflow_type
6866 * c-lex.c (c_lex_with_flags): Add overflow_type to
6867 build_userdef_literal calls.
6868 (interpret_integer, interpret_float): Add overflow_type argument.
6870 2012-11-28 Richard Biener <rguenther@suse.de>
6873 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
6874 here and use a type with proper overflow behavior for types that would
6875 need to be promoted for the arithmetic.
6877 2012-11-23 Jakub Jelinek <jakub@redhat.com>
6880 * c-common.c (handle_no_address_safety_analysis_attribute): New
6882 (c_common_attribute_table): Add no_address_safety_analysis.
6884 2012-11-16 Simon Baldwin <simonb@google.com>
6886 * c.opt: Add f[no-]canonical-system-headers.
6887 * c-opts.c (c_common_handle_option): Handle
6888 OPT_fcanonical_system_headers.
6890 2012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
6893 * c-opts.c (c_common_handle_option): Set new flags.
6894 * c.opt: Describe new flags.
6896 2012-11-09 Jason Merrill <jason@redhat.com>
6898 * c.opt (Wabi-tag): New.
6900 2012-11-09 Andi Kleen <ak@linux.intel.com>
6903 * c-common.c (get_atomic_generic_size): Mask with
6906 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
6909 * c.opt (Wformat): Make it Alias Wformat=1.
6910 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
6911 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
6913 (Wformat=): RejectNegative. Use LangEnabledBy.
6914 (Wnonnull): Use LangEnabledBy.
6915 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
6916 * c-format.c (set_Wformat): Delete.
6917 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
6918 (maybe_read_dollar_number): Likewise.
6919 (avoid_dollar_number): Likewise.
6920 (finish_dollar_format_checking): Likewise.
6921 (check_format_info): Likewise.
6922 (check_format_info_main): Likewise.
6923 (check_format_types): Likewise.
6924 (format_type_warning): Likewise.
6925 * c-common.c (int): Likewise.
6926 (check_function_sentinel): Likewise.
6927 * c-common.h (warn_format,set_Wformat): Do not declare here.
6929 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
6932 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
6933 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
6935 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
6937 (Wvariadic-macros): Init(1).
6938 * c-opts.c (c_common_handle_option): Do not handle them
6940 (c_common_post_options): Likewise.
6941 (sanitize_cpp_opts): warn_unused_macros is now
6942 cpp_warn_unused_macros.
6943 (push_command_line_include): Likewise.
6944 * c-common.c (warn_unknown_pragmas): Do not define.
6945 * c-common.h (warn_unknown_pragmas): Do not declare.
6947 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
6950 * c-common.c (conversion_warning): Handle conditional expressions.
6952 2012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
6955 * c.opt (Wreturn_local_addr): Define new option.
6957 2012-10-25 Jason Merrill <jason@redhat.com>
6959 * c.opt (Wvirtual-move-assign): New.
6961 * c.opt (Winherited-variadic-ctor): New.
6963 2012-10-25 Marc Glisse <marc.glisse@inria.fr>
6966 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
6968 2012-10-23 Joseph Myers <joseph@codesourcery.com>
6970 * c-common.h (pch_cpp_save_state): Declare.
6971 * c-target.def (c_preinclude): New hook.
6972 * c-opts.c (done_preinclude): New.
6973 (push_command_line_include): Handle default preincluded header.
6974 (cb_file_change): Call pch_cpp_save_state when calling
6975 push_command_line_include.
6976 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
6977 (pch_cpp_save_state): New.
6978 (pch_init): Call pch_cpp_save_state conditionally, instead of
6979 calling cpp_save_state.
6981 2012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
6985 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
6986 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
6987 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
6988 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
6989 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
6990 * c-opts.c (c_common_handle_option): Remove explicit handling from
6992 (c_common_post_options): Likewise.
6994 2012-10-18 Eric Botcazou <ebotcazou@adacore.com>
6996 * c-ada-spec.c (LOCATION_COL): Delete.
6997 (compare_location): New function.
6998 (compare_node): Use it.
6999 (compare_comment): Likewise.
7001 2012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
7005 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
7006 * c-opts.c (c_common_handle_option): Do not set them here. Add
7008 (c_common_post_options): Likewise.
7010 2012-10-16 Eric Botcazou <ebotcazou@adacore.com>
7012 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
7013 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
7014 Remove POINTER_TYPE handling, add large unsigned handling and use
7015 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
7017 2012-10-12 Jakub Jelinek <jakub@redhat.com>
7020 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
7021 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
7022 locs and array of 3 trees instead of just single loc and single
7023 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
7024 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
7025 For *cmp* builtins that take two sources strings report warnings
7026 about first and second source, not about destination and source.
7028 2012-10-12 Marc Glisse <marc.glisse@inria.fr>
7031 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
7033 2012-10-11 Eric Botcazou <ebotcazou@adacore.com>
7035 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
7036 declaring something coming from another file.
7038 2012-10-10 Arnaud Charlet <charlet@adacore.com>
7041 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
7043 2012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
7046 * c-common.c (warn_about_parentheses): Add location_t parameter;
7047 use EXPR_LOC_OR_LOC.
7048 * c-common.h: Update declaration.
7050 2012-10-09 Marc Glisse <marc.glisse@inria.fr>
7053 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
7054 more operations. Make error messages optional.
7055 * c-common.h (enum stv_conv): Moved from c-typeck.c.
7056 (scalar_to_vector): Declare.
7058 2012-10-08 Jason Merrill <jason@redhat.com>
7060 * c-common.c (c_common_reswords): Add thread_local.
7062 2012-10-08 Dodji Seketeli <dodji@redhat.com>
7064 PR c++/53528 C++11 attribute support
7065 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
7067 * c-common.c (check_cxx_fundamental_alignment_constraints): New
7069 (handle_aligned_attribute): In choose strictest alignment
7070 among many. Use new check_cxx_fundamental_alignment_constraints.
7071 (handle_transparent_union_attribute): In c++11 attribute syntax,
7072 don't look through typedefs.
7074 2012-10-04 Arnaud Charlet <charlet@adacore.com>
7076 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
7077 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
7080 2012-09-25 Dehao Chen <dehao@google.com>
7083 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
7084 map when read in the pch.
7086 2012-09-18 Arnaud Charlet <charlet@adacore.com>
7088 * c-ada-spec.c: Style fixes.
7090 2012-09-18 Thomas Quinot <quinot@adacore.com>
7092 * c.opt (-fada-spec-parent): Define new command line switch.
7093 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
7094 is specified, generate binding spec as a child of the specified unit.
7096 2012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
7097 Manuel López-Ibáñez <manu@gcc.gnu.org>
7100 * c.opt ([Winit-self]): Enabled by -Wall in C++.
7102 2012-08-23 Arnaud Charlet <charlet@adacore.com>
7104 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
7105 for pointers, and add missing Convention C pragma.
7106 (print_ada_struct_decl): Add missing aliased keyword.
7107 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
7109 2012-08-17 Jakub Jelinek <jakub@redhat.com>
7111 * c-common.c (sizeof_pointer_memaccess_warning): New function.
7112 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
7113 * c-opts.c (c_common_handle_option): Enable it for -Wall.
7114 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
7115 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
7117 2012-08-10 Richard Guenther <rguenther@suse.de>
7119 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
7121 2012-08-07 Steven Bosscher <steven@gcc.gnu.org>
7123 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
7124 instead of separate pp_newline and pp_flush.
7125 (print_c_tree): Likewise.
7127 2012-07-26 Richard Henderson <rth@redhat.com>
7129 * c-common.c (handle_hot_attribute): Allow labels.
7130 (handle_cold_attribute): Likewise.
7132 2012-07-20 Jakub Jelinek <jakub@redhat.com>
7135 * c-common.c (check_function_nonnull): Handle multiple nonnull
7136 attributes properly.
7138 2012-07-16 Steven Bosscher <steven@gcc.gnu.org>
7140 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
7141 * c-ada-spec.c: Likewise.
7142 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
7144 2012-07-14 Steven Bosscher <steven@gcc.gnu.org>
7146 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
7147 Remove code conditional on it.
7149 2012-07-11 Steven Bosscher <steven@gcc.gnu.org>
7151 * c-gimplify.c: Do not include basic-block.h.
7152 * c-common.c: Do not include linfuncs.h.
7154 2012-07-08 Steven Bosscher <steven@gcc.gnu.org>
7156 * c-common.h: Include tree.h.
7158 2012-07-02 Jason Merrill <jason@redhat.com>
7161 * c-common.c (get_priority): Call default_conversion.
7163 2012-07-01 Uros Bizjak <ubizjak@gmail.com>
7165 * c-pch.c (c_common_write_pch): Remove unused variables.
7167 2012-06-29 Steven Bosscher <steven@gcc.gnu.org>
7169 * cppspec.c: Moved from gcc/ to here.
7171 2012-06-27 Kai Tietz <ktietz@redhat.com>
7173 PR preprocessor/37215
7174 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
7176 2012-06-21 Steven Bosscher <steven@gcc.gnu.org>
7178 * c-common.h (c_common_print_pch_checksum): Remove.
7179 * c-pch.c: Do not include output.h.
7180 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
7181 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
7182 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
7183 (struct c_pch_header): Remove.
7184 (get_ident): Update gpch version.
7185 (pch_init): Do not print executable_checksum to asm_out_file.
7186 Do not fail if there is no asm_out_file to read back from. Set
7187 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
7188 (c_common_write_pch): Verify that nothing was written to asm_out_file
7189 since pch_init was called. Do not write a c_pch_header, and do not
7190 copy from asm_out_file to the PCH.
7191 (c_common_read_pch): Do not read a c_pch_header, and do not restore
7192 the content of asm_out_file from the PCH.
7193 (c_common_print_pch_checksum): Remove.
7194 * c-opts.c (c_common_init): Print out executable_checksum directly.
7196 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
7198 * c-target.def (objc_declare_unresolved_class_reference,
7199 objc_declare_class_definition): Add new hooks.
7201 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
7203 * c-lex.c: Do not include output.h.
7204 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
7205 Remove uses of ASM_OUTPUT_IDENT.
7207 2012-06-15 Marc Glisse <marc.glisse@inria.fr>
7210 * c-common.h (c_build_vec_perm_expr): Move decl here.
7211 * c-common.c (c_build_vec_perm_expr): Move definition
7214 2012-06-06 Steven Bosscher <steven@gcc.gnu.org>
7216 * c.opt (fconserve-space): Turn into a no-op.
7218 2012-06-04 Sterling Augustine <saugustine@google.com>
7220 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
7221 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
7222 both the start and end of the function.
7224 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
7226 * c-common.c: Do not include output.h.
7227 * c-pragma.c: Likewise.
7229 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
7231 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
7232 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
7233 (lang_decl_name): Handle namespace decls.
7235 2012-05-31 Steven Bosscher <steven@gcc.gnu.org>
7237 * c-ada-spec.c: Do not include output.h.
7238 * c-semantics.c: Likewise.
7240 2012-05-29 Joseph Myers <joseph@codesourcery.com>
7242 * c-common.c: Fix typo.
7244 2012-05-29 Michael Matz <matz@suse.de>
7246 * c-common.h (c_expand_decl): Remove prototype.
7248 2012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
7250 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
7251 * c-opts.c (c_common_handle_option): Remove code handling
7252 warn_missing_braces.
7254 2012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
7257 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
7260 2012-05-22 Dodji Seketeli <dodji@redhat.com>
7263 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
7265 2012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
7267 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
7268 * c-opts.c (c_common_handle_option): Do not handle explicitly
7269 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
7271 2012-05-16 Dodji Seketeli <dodji@redhat.com>
7273 PR preprocessor/7263
7274 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
7275 to cpp_classify_number. For diagnostics, use the precise location
7276 instead of the global input_location.
7278 2012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
7281 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
7283 2012-05-14 Bernd Schmidt <bernds@codesourcery.com>
7285 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
7287 2012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
7290 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
7291 Wreorder): Use LangEnabledBy.
7292 * c-opts.c (c_common_handle_option): Do not enable them
7293 explicitly. Call lang-specific generated functions.
7294 (c_common_post_options): Do not set them here.
7296 2012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
7298 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
7299 Wmissing-field-initializers,Wmissing-parameter-type,
7300 Wold-style-declaration,Woverride-init): Use EnabledBy.
7301 * c-opts.c (c_common_post_options): Do not set here explicitly.
7303 2012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
7306 * c-opts.c (c_common_handle_option): Use handle_generated_option
7307 to enable sub-options.
7309 2012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
7312 * c-common.c (warnings_for_convert_and_check): Use warning_at.
7314 2012-05-10 Richard Guenther <rguenther@suse.de>
7316 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
7317 adjust commentary about TYPE_IS_SIZETYPE types.
7319 2012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
7322 * c-common.c (warn_logical_operator): Check that argument of
7323 integer_zerop is not NULL.
7325 2012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
7328 * c-common.c (warn_logical_operator): Do not warn if either side
7329 is already true or false.
7331 2012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
7334 * c-common.c (expr_original_type): New.
7335 (shorten_compare): Do not warn for enumeration types.
7337 2012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
7339 * c.opt (fpermissive): Add Var(flag_permissive).
7341 2012-04-30 Marc Glisse <marc.glisse@inria.fr>
7344 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
7345 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
7347 2012-04-30 Dodji Seketeli <dodji@redhat.com>
7349 Add -Wvarargs option
7350 * c.opt (Wvarargs): Define new option.
7352 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
7354 * c-common.c (check_function_arguments): Replace
7355 Wmissing-format-attribute with Wsuggest-attribute=format.
7357 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
7359 * c.opt (Wsuggest-attribute=format): New. Alias of
7360 Wmissing-format-attribute.
7361 * c-format.c (decode_format_type): Replace
7362 Wmissing-format-attribute with Wsuggest-attribute=format.
7363 (check_function_format): Likewise.
7365 2012-04-27 Ollie Wild <aaw@google.com>
7367 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
7368 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
7369 * c.opt: Add Wliteral-suffix.
7371 2012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
7374 * c.opt (Wpedantic): New.
7375 (pedantic): Alias Wpedantic.
7376 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
7377 (c_common_post_options): Likewise.
7378 (sanitize_cpp_opts): Likewise.
7379 * c-lex.c (interpret_float): Likewise.
7380 * c-format.c (check_format_types): Likewise.
7381 * c-common.c (pointer_int_sum): Likewise.
7382 (c_sizeof_or_alignof_type): Likewise.
7383 (c_add_case_label): Likewise.
7384 (c_do_switch_warnings): Likewise.
7385 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
7387 2012-04-15 Jason Merrill <jason@redhat.com>
7390 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
7391 (C_STD_NAME): Distinguish between C++98 and C++11.
7393 2012-04-11 Eric Botcazou <ebotcazou@adacore.com>
7396 * c-common.h (uint16_type_node): Rename into...
7397 (c_uint16_type_node): ...this.
7398 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
7399 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
7401 2012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
7403 * c-common.c (warn_if_unused_value): Move definition to here.
7404 * c-common.h (warn_if_unused_value): Move declaration to here.
7406 2012-03-23 William Bader <williambader@hotmail.com>
7408 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
7410 2012-03-20 Jason Merrill <jason@redhat.com>
7412 * c-common.h (enum cxx_dialect): Add cxx1y.
7413 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
7415 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
7416 * c-opts.c (c_common_post_options): Likewise.
7417 (set_std_cxx1y): New.
7418 (c_common_handle_option): Call it.
7419 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
7421 2012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
7424 * c.opt ([Wuseless-cast]): Add.
7426 2012-03-16 Richard Guenther <rguenther@suse.de>
7428 * c-pretty-print.c (pp_c_initializer_list): Adjust.
7430 2012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
7433 * c.opt (ftemplate-backtrace-limit) Add.
7435 2012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7437 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
7439 * c-pragma.c (handle_pragma_extern_prefix): Remove.
7440 (init_pragma): Don't register extern_prefix.
7442 2012-03-12 Richard Guenther <rguenther@suse.de>
7444 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
7445 (builtin_type_for_size): Likewise.
7447 2012-02-13 Jakub Jelinek <jakub@redhat.com>
7450 * c-common.c (sync_resolve_params): Don't decide whether to convert
7451 or not based on TYPE_SIZE comparison, convert whenever arg_type
7452 is unsigned INTEGER_TYPE.
7454 2012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
7457 * c.opt ([Wunused-local-typedefs]): Fix description.
7459 2012-01-24 Mike Stump <mikestump@comcast.net>
7461 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
7464 2012-01-18 Richard Guenther <rguenther@suse.de>
7466 * c-opts.c (c_common_post_options): Reset LTO flags if
7467 we are about to generate a PCH.
7469 2012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
7472 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
7473 use pp_unsigned_wide_integer.
7475 2012-01-10 Richard Guenther <rguenther@suse.de>
7478 * c-opts.c (c_common_handle_option): Move -Werror handling
7479 to language independent code.
7481 2012-01-05 Richard Guenther <rguenther@suse.de>
7484 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
7487 2011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
7490 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
7491 of array types with an unknown bound.
7493 2011-12-20 Joseph Myers <joseph@codesourcery.com>
7495 * c-common.c (flag_isoc99): Update comment to refer to C11.
7496 (flag_isoc1x): Change to flag_isoc11.
7497 * c-common.h (flag_isoc99): Update comment to refer to C11.
7498 (flag_isoc1x): Change to flag_isoc11.
7499 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
7501 * c-opts.c (set_std_c1x): Change to set_std_c11.
7502 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
7504 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
7505 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
7506 * c.opt (std=c1x): Change to std=c11. Document as non-draft
7508 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
7509 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
7510 (std=gnu1x): Make alias of std=gnu11.
7512 2011-12-19 Jason Merrill <jason@redhat.com>
7515 * c-common.c (handle_transparent_union_attribute): Check the first
7516 field if the type is complete.
7518 2011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
7521 * c-common.c (RID_IS_FINAL): Add.
7522 * c-common.h (RID_IS_FINAL): Add.
7524 2011-11-30 Iain Sandoe <iains@gcc.gnu.org>
7526 * c.opt (fgnu-runtime): Provide full description.
7527 (fnext-runtime): Likewise.
7528 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
7530 2011-11-28 Andrew MacLeod <amacleod@redhat.com>
7532 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
7533 predefines in one place. Add LOCK_FREE predefines.
7534 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
7537 2011-11-24 Andrew MacLeod <amacleod@redhat.com>
7540 * c-common.c (get_atomic_generic_size): Check for various error
7542 (resolve_overloaded_atomic_exchange,
7543 resolve_overloaded_atomic_compare_exchange,
7544 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
7545 error_mark_node for error conditions.
7547 2011-11-08 Richard Guenther <rguenther@suse.de>
7552 2011-11-07 Richard Henderson <rth@redhat.com>
7553 Aldy Hernandez <aldyh@redhat.com>
7554 Torvald Riegel <triegel@redhat.com>
7556 Merged from transactional-memory.
7558 * c-common.c (handle_tm_wrap_attribute,
7559 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
7560 (struct c_common_reswords): Added __transaction* keywords.
7561 (struct c_common_attribute_table): Added transaction* and tm_regparm
7563 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
7565 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
7566 find_tm_attribute): Declare.
7568 2011-11-07 Jason Merrill <jason@redhat.com>
7571 * c-common.c, c-common.h: Revert yesterday's changes.
7573 2011-11-06 Jason Merrill <jason@redhat.com>
7576 * c-common.c (decl_has_visibility_attr): Split out from...
7577 (c_determine_visibility): ...here.
7578 * c-common.h: Declare it.
7580 2011-11-06 Joseph Myers <joseph@codesourcery.com>
7582 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
7583 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
7585 (check_user_alignment): New. Split out of
7586 handle_aligned_attribute. Disallow integer constants with
7587 noninteger types. Conditionally allow zero.
7588 (handle_aligned_attribute): Use check_user_alignment.
7589 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
7591 2011-11-06 Andrew MacLeod <amacleod@redhat.com>
7592 Richard Henderson <rth@redhat.com>
7594 Merged from cxx-mem-model.
7596 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
7597 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
7598 parameters that are the same type size.
7599 (get_atomic_generic_size): New. Find size of generic
7600 atomic function parameters and do typechecking.
7601 (add_atomic_size_parameter): New. Insert size into parameter list.
7602 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
7603 either __atomic_exchange_n or external library call.
7604 (resolve_overloaded_atomic_compare_exchange): Restructure
7605 __atomic_compare_exchange to either _n variant or external library call.
7606 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
7607 __atomic_load_n or an external library call.
7608 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
7609 __atomic_store_n or an external library call.
7610 (resolve_overloaded_builtin): Handle new __atomic builtins.
7612 2011-11-04 Eric Botcazou <ebotcazou@adacore.com>
7615 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
7616 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
7617 <INDIRECT_REF>: Return the argument.
7618 <ARRAY_REF>: Remove special code for negative offset.
7619 Call fold_build_pointer_plus instead of size_binop.
7620 (fold_offsetof): Remove STOP_REF argument and adjust.
7621 * c-common.h (fold_offsetof_1): Declare.
7622 (fold_offsetof): Remove STOP_REF argument.
7624 2011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
7627 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7628 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7629 Wnarrowing for C++0x and C++98.
7630 * c.opt ([Wnarrowing]): Update.
7632 2011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
7635 * c.opt: Add Wzero-as-null-pointer-constant.
7637 2011-10-31 Jason Merrill <jason@redhat.com>
7639 * c.opt (-fdeduce-init-list): Off by default.
7642 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
7643 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
7645 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
7647 2011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
7650 * c.opt (fvisibility-inlines-hidden): Description change.
7652 2011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
7654 Implement C++11 user-defined literals.
7655 * c-common.c (build_userdef_literal): New.
7656 * c-common.def: New tree code.
7657 * c-common.h (tree_userdef_literal): New tree struct and accessors.
7658 * c-lex.c (interpret_float): Add suffix parm.
7659 (c_lex_with_flags): Build literal tokens.
7661 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
7665 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
7668 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7669 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7670 Wnarrowing for C++0x and C++98.
7671 * c.opt ([Wnarrowing]): Update.
7673 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
7676 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7677 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7678 Wnarrowing for C++0x and C++98.
7679 * c.opt ([Wnarrowing]): Update.
7681 2011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
7684 * c-common.c (conversion_warning): Remove code looking for
7685 artificial operands.
7687 2011-10-18 Dodji Seketeli <dodji@redhat.com>
7690 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
7691 !NO_IMPLICIT_EXTERN_C.
7693 2011-10-17 Michael Spertus <mike_spertus@symantec.com>
7695 * c-common.c (c_common_reswords): Add __bases,
7697 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
7699 2011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
7702 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
7704 2011-10-15 Tom Tromey <tromey@redhat.com>
7705 Dodji Seketeli <dodji@redhat.com>
7707 * c.opt (fdebug-cpp): New option.
7708 * c-opts.c (c_common_handle_option): Handle the option.
7709 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
7710 output stream in parameter. Factorized from ...
7711 (maybe_print_line): ... this. Dump location debug information when
7712 -fdebug-cpp is in effect.
7713 (print_line_1): New static function. Takes an output stream in
7714 parameter. Factorized from ...
7715 (print_line): ... here. Dump location information when -fdebug-cpp
7717 (scan_translation_unit): Dump location information when
7718 -fdebug-cpp is in effect.
7720 2011-10-15 Tom Tromey <tromey@redhat.com>
7721 Dodji Seketeli <dodji@redhat.com>
7723 * c.opt (ftrack-macro-expansion): New option. Handle it with and
7725 * c-opts.c (c_common_handle_option)<case
7726 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
7727 cases. Handle -ftrack-macro-expansion with and without argument.
7729 2011-10-15 Tom Tromey <tromey@redhat.com>
7730 Dodji Seketeli <dodji@redhat.com>
7732 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
7733 (print_line, cb_define, do_line_change): Adjust to avoid touching
7734 the internals of struct line_map. Use the public API instead.
7735 * c-pch.c (c_common_read_pch): Likewise.
7736 * c-lex.c (fe_file_change): Likewise.
7738 2011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
7741 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
7743 2011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
7746 * c-pretty-print.c (pp_c_floating_constant): Output
7747 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
7749 2011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
7751 * c-common.c (def_builtin_1): Delete old interface with two
7752 parallel arrays to hold standard builtin declarations, and replace
7753 it with a function based interface that can support creating
7754 builtins on the fly in the future. Change all uses, and poison
7755 the old names. Make sure 0 is not a legitimate builtin index.
7756 * c-omp.c (c_finish_omp_barrier): Ditto.
7757 (c_finish_omp_taskwait): Ditto.
7758 (c_finish_omp_flush): Ditto.
7760 2011-10-11 Tristan Gingold <gingold@adacore.com>
7762 * c.opt: (fallow-parameterless-variadic-functions): New.
7764 2011-09-08 Dodji Seketeli <dodji@redhat.com>
7766 PR c++/33255 - Support -Wunused-local-typedefs warning
7767 * c-common.h (struct c_language_function::local_typedefs): New
7769 (record_locally_defined_typedef, maybe_record_typedef_use)
7770 (maybe_warn_unused_local_typedefs): Declare new functions.
7771 * c-common.c (record_locally_defined_typedef)
7772 (maybe_record_typedef_use)
7773 (maybe_warn_unused_local_typedefs): Define new functions.
7774 * c.opt: Declare new -Wunused-local-typedefs flag.
7776 2011-09-06 Eric Botcazou <ebotcazou@adacore.com>
7779 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
7782 2011-09-05 Richard Guenther <rguenther@suse.de>
7784 * c-common.c (complete_array_type): Use ssize_int (-1) instead
7785 of integer_minus_one_node for empty array upper bounds.
7787 2011-08-28 Dodji Seketeli <dodji@redhat.com>
7789 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
7790 it's the first time it's being called on this main TU.
7792 2011-08-24 Richard Guenther <rguenther@suse.de>
7795 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
7797 2011-08-22 Gabriel Charette <gchare@google.com>
7799 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
7800 defined in cpp_init_builtins and c_cpp_builtins.
7802 2011-08-19 Joseph Myers <joseph@codesourcery.com>
7804 * c-common.c (c_common_reswords): Add __builtin_complex.
7805 * c-common.h (RID_BUILTIN_COMPLEX): New.
7807 2011-08-18 Joseph Myers <joseph@codesourcery.com>
7809 * c-common.c (c_common_reswords): Add _Noreturn.
7810 (keyword_is_function_specifier): Handle RID_NORETURN.
7811 * c-common.h (RID_NORETURN): New.
7813 2011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
7815 * c-common.c (unsafe_conversion_p): New function. Check if it is
7816 unsafe to convert an expression to the type.
7817 (conversion_warning): Adjust, use unsafe_conversion_p.
7818 * c-common.h (unsafe_conversion_p): New function declaration.
7820 2011-08-02 Jakub Jelinek <jakub@redhat.com>
7822 * c-common.h (c_finish_omp_atomic): Adjust prototype.
7823 (c_finish_omp_taskyield): New prototype.
7824 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
7825 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
7826 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
7827 or RHS1 have side-effects, evaluate those too in the right spot,
7828 if it is a decl and LHS is also a decl, error out if they
7830 (c_finish_omp_taskyield): New function.
7831 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
7832 * c-pragma.c (omp_pragmas): Add taskyield.
7833 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
7834 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
7835 PRAGMA_OMP_CLAUSE_MERGEABLE.
7837 2011-07-25 Dodji Seketeli <dodji@redhat.com>
7839 * c-common.h (set_underlying_type): Remove parm name from
7842 2011-07-25 Romain Geissler <romain.geissler@gmail.com>
7844 * c-pretty-print.h: Search c-common.h in c-family.
7846 2011-07-22 Jason Merrill <jason@redhat.com>
7849 * c.opt (Wnarrowing): New.
7852 * c-common.h: Declare c_linkage_bindings.
7853 * c-pragma.c (handle_pragma_redefine_extname): Use it.
7856 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
7857 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
7858 as flag_isoc99 for 'restrict'.
7859 (pp_c_specifier_qualifier_list): Likewise for _Complex.
7861 2011-07-21 Ian Lance Taylor <iant@google.com>
7864 * c-common.c (c_disable_warnings): New static function.
7865 (c_enable_warnings): New static function.
7866 (c_fully_fold_internal): Change local unused_p to bool. Call
7867 c_disable_warnings and c_enable_warnings rather than change
7868 c_inhibit_evaluation_warnings.
7870 2011-07-20 Jason Merrill <jason@redhat.com>
7872 PR c++/6709 (DR 743)
7873 PR c++/42603 (DR 950)
7874 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
7875 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
7876 (CPP_DECLTYPE): New.
7877 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
7879 2011-07-19 Richard Guenther <rguenther@suse.de>
7881 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
7882 * c-omp.c (c_finish_omp_for): Likewise.
7884 2011-07-12 Eric Botcazou <ebotcazou@adacore.com>
7886 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
7887 body on the next line.
7889 2011-07-08 Jason Merrill <jason@redhat.com>
7892 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
7895 * c-common.c (c_apply_type_quals_to_decl): Don't check
7896 TYPE_NEEDS_CONSTRUCTING.
7898 2011-07-06 Richard Guenther <rguenther@suse.de>
7900 * c-common.c (c_common_nodes_and_builtins):
7901 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
7903 2011-07-05 Richard Guenther <rguenther@suse.de>
7905 * c-common.c (c_common_nodes_and_builtins): Build all common
7908 2011-06-27 Jakub Jelinek <jakub@redhat.com>
7910 * c-common.h (c_tree_chain_next): New static inline function.
7912 * c-common.c (check_builtin_function_arguments): Handle
7913 BUILT_IN_ASSUME_ALIGNED.
7915 2011-06-21 Andrew MacLeod <amacleod@redhat.com>
7917 * c-common.c: Add sync_ or SYNC__ to builtin names.
7918 * c-omp.c: Add sync_ or SYNC__ to builtin names.
7920 2011-06-20 Pierre Vittet <piervit@pvittet.com>
7922 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
7924 (gen_pragma_handler): New union.
7925 (internal_pragma_handler): New type.
7926 (c_register_pragma_with_data)
7927 (c_register_pragma_with_expansion_and_data): New functions.
7929 * c-pragma.c (registered_pragmas, c_register_pragma_1)
7930 (c_register_pragma, c_register_pragma_with_expansion)
7931 (c_invoke_pragma_handler): Changed to work with
7932 internal_pragma_handler.
7933 (c_register_pragma_with_data)
7934 (c_register_pragma_with_expansion_and_data): New functions.
7936 2011-06-14 Joseph Myers <joseph@codesourcery.com>
7938 * c-common.c: Include common/common-target.h.
7939 (handle_section_attribute): Use
7940 targetm_common.have_named_sections.
7941 * c-cppbuiltin.c: Include common/common-target.h.
7942 (c_cpp_builtins): Use targetm_common.except_unwind_info.
7944 2011-06-10 Richard Guenther <rguenther@suse.de>
7946 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
7947 to print a IDENTIFIER_NODE.
7949 2011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7950 Joseph Myers <joseph@codesourcery.com>
7952 * c.opt (fbuilding-libgcc): New option.
7953 * c-cppbuiltin.c (c_cpp_builtins): Define
7954 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
7956 2011-06-07 Jason Merrill <jason@redhat.com>
7958 * c-common.c (max_tinst_depth): Lower default to 900.
7960 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
7962 2011-06-07 Richard Guenther <rguenther@suse.de>
7964 * c-common.c (c_common_nodes_and_builtins): Do not set
7965 size_type_node or call set_sizetype.
7967 2011-06-07 Dodji Seketeli <dodji@redhat.com>
7970 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
7971 type when using pointer comparison to compare types.
7973 2011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
7975 * c.opt: Add -Wdelete-non-virtual-dtor.
7976 * c-opts.c (c_common_handle_option): Include it in -Wall.
7978 2011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
7983 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
7985 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
7988 2011-05-27 Jakub Jelinek <jakub@redhat.com>
7991 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
7992 C++ don't call c_common_truthvalue_conversion on void type arms.
7994 2011-05-27 Nathan Froyd <froydnj@codesourcery.com>
7996 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
7997 (stmt_list_stack): Define.
7998 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
7999 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
8001 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
8003 * c-common.c (warning_candidate_p): Check for BLOCKs.
8005 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
8007 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
8010 2011-05-25 Jakub Jelinek <jakub@redhat.com>
8012 * c-common.c (def_fn_type): Remove extra va_end.
8014 2011-05-23 Jason Merrill <jason@redhat.com>
8017 * c-common.c (c_common_get_narrower): New.
8018 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
8020 2011-05-23 Nathan Froyd <froydnj@codesourcery.com>
8022 * c-common.h (check_function_arguments): Tweak prototype of
8023 check_function_arguments.
8024 * c-common.c (check_function_arguments): Likewise. Adjust
8025 calls to check_function_nonnull, check_function_format, and
8026 check_function_sentinel.
8027 (check_function_sentinel): Take a FUNCTION_TYPE rather than
8028 separate attributes and typelist arguments. Use
8029 FOREACH_FUNCTION_ARGS to iterate over argument types.
8031 2011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
8033 * c-common.c (c_common_reswords): Reorder.
8034 * c-common.h (rid): Likewise.
8036 2011-05-10 Nathan Froyd <froydnj@codesourcery.com>
8038 * c-common.c (def_fn_type): Don't call build_function_type, call
8039 build_function_type_array or build_varargs_function_type_array
8041 (c_common_nodes_and_builtins): Likewise.
8043 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
8045 * c-common.c (c_add_case_label): Omit the loc argument to
8047 * c-common.h (build_case_label): Remove.
8048 * c-semantics.c (build_case_label): Remove.
8050 2011-05-05 Joseph Myers <joseph@codesourcery.com>
8052 * c-objc.h (objc_start_method_definition): Update prototype.
8053 * stub-objc.c (objc_start_method_definition): Add extra parameter.
8055 2011-05-04 Nathan Froyd <froydnj@codesourcery.com>
8057 * c-common.c (check_main_parameter_types): Reindent. Don't use
8058 TYPE_ARG_TYPES directly.
8059 (handle_nonnull_attribute): Likewise.
8060 (sync_resolve_params): Likewise.
8061 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
8062 to check_format_string.
8063 (handle_format_attribute): Likewise.
8064 (check_format_string): Take a function type to examine instead of
8065 a type list. Use a function_arg_iterator to step through argument
8068 2011-05-04 Richard Guenther <rguenther@suse.de>
8070 * c-common.c (fix_string_type): Use size_int for index type bounds.
8071 (start_fname_decls): Do not pass NULL to build_int_cst.
8072 (c_init_attributes): Likewise.
8073 * c-lex.c (c_lex_with_flags): Likewise.
8075 2011-04-27 Jason Merrill <jason@redhat.com>
8077 * c-common.c (make_tree_vector_from_list): New.
8078 * c-common.h: Declare it.
8080 2011-04-26 Richard Guenther <rguenther@suse.de>
8082 PR preprocessor/48248
8083 * c-ppoutput.c (maybe_print_line): Always optimize newlines
8084 for output size with -P.
8086 2011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
8088 * c-common.c (struct c_common_resword): Add __underlying_type.
8089 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
8091 2011-04-20 Jim Meyering <meyering@redhat.com>
8093 * c-format.c (init_dollar_format_checking): Remove useless
8096 2011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
8098 * c-objc.h (objc_get_interface_ivars): Removed.
8099 (objc_detect_field_duplicates): New.
8100 * stub-objc.c: Likewise.
8102 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
8104 * stub-objc.c (objc_declare_protocols): Renamed to
8105 objc_declare_protocol.
8106 * c-objc.h: Likewise.
8108 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
8110 * stub-objc.c (objc_declare_class): Updated argument name.
8112 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
8114 * c-common.h (c_common_init_ts): Declare.
8115 * c-common.c (c_common_init_ts): Define.
8117 2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
8119 * c-objc.h (objc_build_message_expr): Updated prototype.
8120 * stub-objc.c (objc_build_message_expr): Likewise.
8122 2011-04-12 Martin Jambor <mjambor@suse.cz>
8124 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
8127 2011-04-11 Richard Guenther <rguenther@suse.de>
8129 * c-common.c (complete_array_type): Build a range type of
8132 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
8134 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
8135 (handle_type_generic_attribute): Likewise.
8137 2011-04-07 Jason Merrill <jason@redhat.com>
8140 * c-common.c (c_common_truthvalue_conversion): Don't ignore
8141 conversion from C++0x scoped enum.
8143 2011-04-06 Joseph Myers <joseph@codesourcery.com>
8145 * c-target-def.h: New file.
8146 * c-target.def: New file.
8147 * c-target.h: New file.
8148 * c-common.c (targetcm): Don't define here.
8149 * c-common.h (default_handle_c_option): Declare.
8150 * c-format.c: Include c-target.h instead of target.h.
8151 * c-opts.c: Include c-target.h instead of target.h. Explicitly
8153 (default_handle_c_option): Move from targhooks.c.
8155 2011-03-29 Jakub Jelinek <jakub@redhat.com>
8157 PR preprocessor/48248
8158 * c-ppoutput.c (print): Add src_file field.
8159 (init_pp_output): Initialize it.
8160 (maybe_print_line): Don't optimize by adding up to 8 newlines
8161 if map->to_file and print.src_file are different file.
8162 (print_line): Update print.src_file.
8164 2011-03-25 Kai Tietz <ktietz@redhat.com>
8166 * c-ada-spec.c (compare_comment): Use filename_cmp
8167 instead of strcmp for filename.
8169 2011-03-25 Jeff Law <law@redhat.com>
8171 * c-common.c (def_fn_type): Add missing va_end.
8173 2011-03-25 Jason Merrill <jason@redhat.com>
8175 * c.opt: Add -std=c++03.
8177 2011-03-22 Eric Botcazou <ebotcazou@adacore.com>
8179 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
8181 2011-03-17 Kai Tietz <ktietz@redhat.com>
8184 * c-pretty-print.c (pp_c_specifier_qualifier_list):
8185 Display allowed attributes for function pointer types.
8186 (pp_c_attributes_display): New function to display
8187 attributes having affects_type_identity flag set to true.
8188 * c-pretty-print.h (pp_c_attributes_display): New prototype.
8190 * c-common.c (c_common_attribute_table):
8192 (c_common_format_attribute_table): Likewise.
8194 2011-03-18 Jason Merrill <jason@redhat.com>
8196 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
8197 * c-common.h: Don't declare it here.
8198 * c-common.c: Or define it here.
8199 * c-opts.c (c_common_handle_option): Or set it here.
8202 * c-common.c (handle_transparent_union_attribute): Don't
8203 make a duplicate type in C++.
8205 2011-03-15 Jason Merrill <jason@redhat.com>
8207 * c-common.c (max_constexpr_depth): New.
8208 * c-common.h: Declare it.
8209 * c-opts.c (c_common_handle_option): Set it.
8210 * c.opt (fconstexpr-depth): New option.
8212 2011-03-11 Jason Merrill <jason@redhat.com>
8214 * c-common.c (attribute_takes_identifier_p): Add missing const.
8217 * c-common.c (attribute_takes_identifier_p): Assume that an
8218 unknown attribute takes an identifier.
8220 2011-03-07 Nathan Froyd <froydnj@codesourcery.com>
8223 * c-common.c (c_type_hash): Call list_length instead of iterating
8224 through DECL_CHAIN. Rename 'i' to 'n_elements'.
8226 2011-02-19 Jakub Jelinek <jakub@redhat.com>
8229 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
8231 2011-02-17 Iain Sandoe <iains@gcc.gnu.org>
8233 * c.opt (fobjc-abi-version=) New.
8234 (fobjc-nilcheck): New.
8236 2011-02-03 Nathan Froyd <froydnj@codesourcery.com>
8239 * c-common.h (keyword_is_decl_specifier): Declare.
8240 * c-common.c (keyword_is_decl_specifier): Define.
8241 (keyword_is_function_specifier): New function.
8243 2011-01-26 Jakub Jelinek <jakub@redhat.com>
8246 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
8247 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
8250 2011-01-26 Arnaud Charlet <charlet@adacore.com>
8252 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
8254 2011-01-26 Jakub Jelinek <jakub@redhat.com>
8257 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
8258 after init_c_lex if pch_file is set.
8260 2011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
8263 * c.opt (-fkeep-inline-dllexport): New switch.
8265 2011-01-12 Richard Guenther <rguenther@suse.de>
8268 * c-common.c (handle_weak_attribute): Warn instead of error
8269 on declaring an inline function weak.
8271 2011-01-05 Tom Tromey <tromey@redhat.com>
8273 * c-common.h (lvalue_error): Update.
8274 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
8277 2010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
8280 * c-objc.h (objc_finish_message_expr): Added argument to
8283 2010-12-22 Nathan Froyd <froydnj@codesourcery.com>
8285 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
8288 2010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
8290 * c-objc.h (objc_maybe_warn_exceptions): New.
8291 * stub-objc.c (objc_maybe_warn_exceptions): New.
8293 2010-12-10 Nathan Froyd <froydnj@codesourcery.com>
8295 * c-common.h (readonly_error): Declare.
8296 * c-common.c (readonly_error): Define.
8298 2010-12-09 Nathan Froyd <froydnj@codesourcery.com>
8300 * c-common.h (invalid_indirection_error): Declare.
8301 * c-common.c (invalid_indirection_error): Define.
8303 2010-12-03 Richard Guenther <rguenther@suse.de>
8306 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
8307 (pp_c_unary_expression): Likewise.
8308 (pp_c_expression): Likewise.
8310 2010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
8312 * c-common.h (objc_finish_function): New.
8313 (objc_non_volatilized_type): Removed.
8314 (objc_type_quals_match): Removed.
8315 * stub-objc.c (objc_finish_function): New.
8316 (objc_non_volatilized_type): Removed.
8317 (objc_type_quals_match): Removed.
8319 2010-11-30 Joseph Myers <joseph@codesourcery.com>
8321 * c-common.h (parse_optimize_options): Declare.
8322 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
8323 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
8325 2010-11-29 Joseph Myers <joseph@codesourcery.com>
8327 * c-opts.c (check_deps_environment_vars): Use getenv instead of
8329 * c-pch.c (O_BINARY): Don't define here.
8330 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
8332 2010-11-25 Joseph Myers <joseph@codesourcery.com>
8334 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
8335 targetm.except_unwind_info.
8337 2010-11-23 Joseph Myers <joseph@codesourcery.com>
8339 * c-opts.c (c_common_handle_option): Pass location to
8340 set_struct_debug_option.
8342 2010-11-23 Joseph Myers <joseph@codesourcery.com>
8344 * c-common.c (visibility_options): Move from ../opts.c.
8345 * c-common.h (struct visibility_flags, visibility_options):
8347 * c-opts.c (finish_options): Rename to c_finish_options.
8348 (c_common_init): Update call to finish_options.
8350 2010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
8353 * c-lex.c (lex_string): Check that each string in an Objective-C
8354 string concat sequence starts with either one or zero '@', and
8355 that there are no spurious '@' signs at the end.
8357 2010-11-20 Joseph Myers <joseph@codesourcery.com>
8359 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
8360 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
8361 HANDLE_PRAGMA_VISIBILITY.
8362 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
8363 HANDLE_PRAGMA_VISIBILITY): Don't define.
8364 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
8366 2010-11-20 Nathan Froyd <froydnj@codesourcery.com>
8371 * c-common.h (keyword_begins_type_specifier): Declare.
8372 (keyword_is_storage_class_specifier): Declare.
8373 (keyword_is_type_qualifier): Declare.
8374 * c-common.c (keyword_begins_type_specifier): New function.
8375 (keyword_is_storage_class_specifier): New function.
8376 (keyword_is_type_qualifier): Declare.
8378 2010-11-19 Joseph Myers <joseph@codesourcery.com>
8381 * c-common.c (in_late_binary_op): Define.
8382 (c_common_truthvalue_conversion): Check in_late_binary_op before
8383 calling c_save_expr.
8384 * c-common.h (in_late_binary_op): Declare.
8386 2010-11-19 Joseph Myers <joseph@codesourcery.com>
8388 * c-opts.c (c_common_handle_option): Update calls to
8389 set_struct_debug_option.
8391 2010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
8393 * c-common.h (objc_declare_protocols): Added additional argument.
8394 * stub-objc.c (objc_declare_protocol): Same change.
8396 2010-11-18 Nathan Froyd <froydnj@codesourcery.com>
8399 * c-common.h (build_real_imag_expr): Declare.
8400 * c-semantics.c (build_real_imag_expr): Define.
8402 2010-11-17 Joseph Myers <joseph@codesourcery.com>
8404 * c-opts.c (c_common_parse_file): Take no arguments.
8405 * c-common.h (c_common_parse_file): Update prototype.
8407 2010-11-16 Jakub Jelinek <jakub@redhat.com>
8410 * c-common.c (warning_candidate_p): Don't track non-const calls
8413 2010-11-15 Ian Lance Taylor <iant@google.com>
8415 * c-lex.c (init_c_lex): Set macro debug callbacks if
8416 flag_dump_go_spec is set.
8418 2010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
8420 * c-common.h (objc_build_incr_expr_for_property_ref): New.
8421 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
8423 2010-11-15 Nathan Froyd <froydnj@codesourcery.com>
8425 PR preprocessor/45038
8426 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
8429 2010-11-12 Joseph Myers <joseph@codesourcery.com>
8431 * c-common.h (c_family_lang_mask): Declare.
8432 * c-opts.c (c_family_lang_mask): Make extern.
8433 * c-pragma.c (handle_pragma_diagnostic): Use
8434 control_warning_option.
8436 2010-11-12 Joseph Myers <joseph@codesourcery.com>
8438 * c-common.c (parse_optimize_options): Update call to
8440 * c-common.h (c_common_handle_option): Update prototype.
8441 * c-opts.c (c_common_handle_option): Take location_t parameter and
8442 pass it to other functions.
8444 2010-11-11 Joseph Myers <joseph@codesourcery.com>
8446 * c-opts.c (warning_as_error_callback): Remove.
8447 (c_common_initialize_diagnostics): Don't call
8448 register_warning_as_error_callback.
8449 (c_common_handle_option): Handle -Werror=normalized= here.
8451 2010-11-10 Joseph Myers <joseph@codesourcery.com>
8453 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
8455 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
8457 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
8458 Remove trailing '.' from diagnostics.
8459 * c.opt (Wwrite-strings_: Avoid '`' in help text.
8461 2010-11-10 Joseph Myers <joseph@codesourcery.com>
8463 * c-common.c (parse_optimize_options): Pass global_dc to
8465 * c-opts.c (c_common_handle_option): Pass &global_options to
8466 set_Wstrict_aliasing.
8467 * c.opt (v): Don't mark Common or document here.
8469 2010-11-06 Iain Sandoe <iains@gcc.gnu.org>
8472 * c-format.c (format_type): New type gcc_objc_string_format_type.
8473 (valid_stringptr_type_p): New.
8474 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
8475 (check_format_string): Pass expected type, use
8476 valid_stringptr_type_p (), check that the format string types are
8477 consistent with the format specification.
8478 (decode_format_attr): Warn if NSString is used outside objective-c.
8479 (format_types_orig): Add NSString.
8481 (format_flags): New.
8482 (check_format_arg): Handle format strings requiring an external parser.
8483 first_target_format_type: New variable.
8484 (handle_format_attribute): Set up first_target_format_type, pass the
8485 expected format arg string type to check_format_string().
8486 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
8487 * stub-objc.c (objc_string_ref_type_p): New.
8488 (objc_check_format_arg): New.
8490 2010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
8492 Fixed using the Objective-C 2.0 dot-syntax with class names.
8493 * c-common.h (objc_build_class_component_ref): New.
8494 * stub-objc.c (objc_build_class_component_ref): New.
8496 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
8498 * c.opt (Wproperty-assign-default): New option.
8500 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
8502 Implemented -fobjc-std=objc1 flag.
8503 * c.opt (fobjc-std=objc1): New option.
8505 2010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
8507 Implemented format and noreturn attributes for Objective-C methods.
8508 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
8509 attribute for Objective-C methods.
8511 2010-10-31 Jason Merrill <jason@redhat.com>
8513 * c-common.c (conversion_warning, warn_for_collisions_1): Use
8516 2010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
8518 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
8519 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
8520 (objc_add_property_declaration): Removed arguments for copies and
8522 (objc_build_getter_call): Renamed to
8523 objc_maybe_build_component_ref.
8524 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
8525 (objc_is_property_ref): New.
8526 * c-common.c (c_common_reswords): Removed copies and ivar.
8527 * stub-objc.c (objc_add_property_declaration): Removed arguments
8528 for copies and ivar.
8529 (objc_build_getter_call): Renamed to
8530 objc_maybe_build_component_ref.
8531 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
8532 (objc_is_property_ref): New.
8534 2010-10-29 Arnaud Charlet <charlet@adacore.com>
8535 Matthew Gingell <gingell@adacore.com>
8537 * c-ada-spec.c (separate_class_package): New function.
8538 (pp_ada_tree_identifier): Prefix references to C++ classes with the
8539 name of their enclosing package.
8540 (print_ada_declaration): Use separate_class_package.
8542 2010-10-27 Jason Merrill <jason@redhat.com>
8544 * c-common.c (c_common_reswords): Add __is_literal_type.
8545 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
8547 * c-common.c (check_case_value): Remove special C++ code.
8549 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
8551 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
8552 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
8554 (objc_add_property_declaration): Added additional arguments.
8555 (objc_property_attribute_kind): Removed.
8556 (objc_set_property_attr): Removed.
8557 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
8559 * stub-objc.c (objc_add_property_declaration): Added additional
8561 (objc_set_property_attr): Removed.
8563 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
8565 * c-common.h (objc_add_property_variable): Renamed to
8566 objc_add_property_declaration. Added location argument.
8567 * stub-objc.c (objc_add_property_variable): Same change.
8569 2010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
8571 * c-common.h (objc_maybe_printable_name): New.
8572 * stub-objc.c (objc_maybe_printable_name): New.
8574 2010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
8575 Andrew Pinski <pinskia@gmail.com>
8577 * c-common.h (c_common_mark_addressable_vec): Declare.
8578 * c-common.c (c_common_mark_addressable_vec): New function.
8580 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
8582 * c-common.h (objc_set_method_type): Removed.
8583 (objc_add_method_declaration): Added boolean argument.
8584 (objc_start_method_definition): Same change.
8585 (objc_build_method_signature): Same change.
8586 * stub-objc.c (objc_set_method_type): Removed.
8587 (objc_add_method_declaration): Added boolean argument.
8588 (objc_start_method_definition): Same change.
8589 (objc_build_method_signature): Same change.
8591 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
8593 * c-common.h (finish_file): Removed.
8594 (objc_write_global_declarations): New.
8595 * c-opts.c (c_common_parse_file): Do not call finish_file.
8596 * stub-objc.c (objc_write_global_declarations): New.
8598 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
8600 Implemented parsing @synthesize and @dynamic for
8601 Objective-C/Objective-C++.
8602 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
8603 (objc_add_synthesize_declaration): New.
8604 (objc_add_dynamic_declaration): New.
8605 * c-common.c (c_common_reswords): Add synthesize and dynamic.
8606 * stub-objc.c (objc_add_synthesize_declaration): New.
8607 (objc_add_dynamic_declaration): New.
8609 2010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
8612 * c-cppbuiltin.c (mode_has_fma): Move function here from
8613 builtins.c. Don't use the fma optab, instead just use the
8614 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
8617 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
8619 Merge from 'apple/trunk' branch on FSF servers.
8621 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
8624 * c-common.h (objc_non_volatilized_type): New declaration
8625 * stub-objc.c (objc_non_volatilized_type): New stub.
8627 2010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
8629 Merge from 'apple/trunk' branch on FSF servers.
8631 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
8634 * c-common.h (objc_diagnose_private_ivar): New decl.
8635 * stub-objc.c (objc_diagnose_private_ivar): New stub.
8637 2010-10-17 Iain Sandoe <iains@gcc.gnu.org>
8639 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
8640 * c-common.h (enum rid): Add RID_AT_PACKAGE.
8641 (objc_ivar_visibility_kind): New enum.
8642 (objc_set_visibility): Adjust prototype to use visibility enum.
8643 * stub-objc.c (objc_set_visibility): Adjust stub to use
8646 2010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
8648 * c-cppbuiltin.c (builtin_define_float_constants): Emit
8649 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
8650 has the appropriate fma builtins.
8651 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
8653 2010-10-14 Iain Sandoe <iains@gcc.gnu.org>
8655 merge from FSF apple 'trunk' branch.
8656 2006 Fariborz Jahanian <fjahanian@apple.com>
8658 Radars 4436866, 4505126, 4506903, 4517826
8659 * c-common.c (c_common_resword): Define @property and its attributes.
8660 * c-common.h: Define property attribute enum entries.
8661 (OBJC_IS_PATTR_KEYWORD): New.
8662 (objc_property_attribute_kind): New enum.
8663 Declare objc_set_property_attr (), objc_add_property_variable (),
8664 objc_build_getter_call () and objc_build_setter_call ().
8665 * stub-objc.c (objc_set_property_attr): New stub.
8666 (objc_add_property_variable): Likewise.
8667 (objc_build_getter_call): Likewise.
8668 (objc_build_setter_call) Likewise.
8670 2010-10-13 Iain Sandoe <iains@gcc.gnu.org>
8672 merge from FSF apple 'trunk' branch.
8673 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
8675 Radar 3803157 (method attributes)
8676 * c-common.c (handle_deprecated_attribute): Recognize
8677 objc methods as valid declarations.
8678 * c-common.h: Declare objc_method_decl ().
8679 * stub-objc.c (objc_method_decl): New stub.
8681 2010-10-08 Joseph Myers <joseph@codesourcery.com>
8683 * c-common.c (parse_optimize_options): Call
8684 decode_cmdline_options_to_array_default_mask before
8685 decode_options. Update arguments to decode_options.
8686 * c-common.h (c_common_init_options_struct): Declare.
8687 * c-opts.c (c_common_init_options_struct): New. Split out from
8688 c_common_init_options.
8690 2010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
8692 Implemented fast enumeration for Objective-C.
8693 * c-common.h (objc_finish_foreach_loop): New.
8694 * stub-objc.c (objc_finish_foreach_loop): New.
8696 2010-10-05 Joseph Myers <joseph@codesourcery.com>
8698 * c-common.h (struct diagnostic_context): Don't declare here.
8699 (c_common_initialize_diagnostics): Declare using
8700 diagnostic_context typedef.
8701 * c-opts.c (c_common_handle_option): Pass global_dc to
8702 handle_generated_option.
8704 2010-10-04 Joseph Myers <joseph@codesourcery.com>
8706 * c-opts.c (c_common_handle_option): Pass &global_options_set to
8707 handle_generated_option.
8709 2010-10-03 Ian Lance Taylor <iant@google.com>
8711 * c.opt (-fplan9-extensions): New option.
8713 2010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
8715 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
8717 (c_cpp_builtins): Call functions from cppbuiltin.c instead
8718 of duplicating code.
8720 2010-09-30 Iain Sandoe <iains@gcc.gnu.org>
8722 * c-common.c: Add two new entries for @optional
8723 and @required keywords.
8725 merge from FSF 'apple/trunk' branch.
8726 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
8729 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
8730 objective-c keywords.
8731 (objc_set_method_opt): New declaration.
8732 * stub-objc.c (objc_set_method_opt): New stub.
8734 2010-09-30 Joseph Myers <joseph@codesourcery.com>
8736 * c-common.c (handle_optimize_attribute): Pass &global_options to
8737 cl_optimization_save and cl_optimization_restore.
8738 * c-opts.c (c_common_handle_option): Pass &global_options to
8739 handle_generated_option.
8740 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
8741 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
8742 &global_options to cl_optimization_restore.
8744 2010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
8746 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
8747 Objective-C/Objective-C++ keywords.
8749 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
8751 Merge from 'apple/trunk' branch on FSF servers.
8753 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
8756 * c-common.h (objc_check_global_decl): New declaration.
8757 * stub-objc.c (objc_check_global_decl): New stub.
8759 2010-09-29 Joseph Myers <joseph@codesourcery.com>
8761 * c.opt: Don't use VarExists.
8763 2010-09-29 Joseph Myers <joseph@codesourcery.com>
8765 * c-common.c (c_cpp_error): Update names of diagnostic_context
8767 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
8768 cl_optimization members.
8769 * c-opts.c (warning_as_error_callback, c_common_handle_option,
8770 sanitize_cpp_opts, finish_options): Update names of cpp_options
8773 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
8775 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
8776 (objc_is_reserved_word): Removed.
8777 * c-common.c: Updated comments.
8778 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
8779 objc_is_reserved_word.
8780 * stub-objc.c (objc_is_reserved_word): Removed.
8782 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
8784 * c-common.h (objc_add_method_declaration): Adjust prototype to
8786 (objc_start_method_definition): Likewise.
8787 (objc_build_keyword_decl): Likewise.
8788 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
8789 (objc_start_method_definition): Likewise.
8790 (objc_build_keyword_decl): Likewise.
8792 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
8794 * c-common.h (objc_start_class_interface): Adjust prototype.
8795 (objc_start_category_interface): Likewise.
8796 (objc_start_protocol): Likewise.
8797 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
8798 (objc_start_class_interface): Likewise.
8799 (objc_start_category_interface): Likewise.
8801 2010-09-27 Ian Lance Taylor <iant@google.com>
8803 * c-common.c (c_common_attribute_table): Add no_split_stack.
8804 (handle_no_split_stack_attribute): New static function.
8806 2010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
8808 Merge from 'apple/trunk' branch on FSF servers.
8810 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
8813 * c-common.h (objc_have_common_type): New declaration.
8814 * stub-objc.c (objc_have_common_type): New stub.
8816 2005-06-22 Ziemowit Laski <zlaski@apple.com>
8819 * c-common.h (objc_common_type): New prototype.
8820 * stub-objc.c (objc_common_type): New stub.
8822 2010-09-24 Jan Hubicka <jh@suse.cz>
8824 * c-common.c (handle_leaf_attribute): New function.
8825 (struct attribute_spec c_common_att): Add leaf.
8827 2010-09-22 Joseph Myers <joseph@codesourcery.com>
8829 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
8830 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
8831 -dump, -dump=, -imacros, -imacros=, -include, -include=,
8832 -include-barrier, -include-directory, -include-directory=,
8833 -include-directory-after, -include-directory-after=,
8834 -include-prefix, -include-prefix=, -include-with-prefix,
8835 -include-with-prefix=, -include-with-prefix-after,
8836 -include-with-prefix-after=, -include-with-prefix-before,
8837 -include-with-prefix-before=, -no-integrated-cpp,
8838 -no-line-commands, -no-standard-includes, -no-warnings, -output,
8839 -output=, -pedantic, -pedantic-errors, -preprocess,
8840 -print-missing-file-dependencies, -trace-includes, -traditional,
8841 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
8842 -user-dependencies, -verbose, -write-dependencies,
8843 -write-user-dependencies, no-integrated-cpp, traditional): New.
8845 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
8848 * c-common.h (objc_start_method_definition): Return bool instead
8850 * stub-objc.c (objc_start_method_definition): Return bool instead
8853 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
8856 * c-common.h (objc_get_interface_ivars): New declaration.
8857 * stub-objc.c (objc_get_interface_ivars): New stub.
8859 2010-09-15 Ian Lance Taylor <iant@google.com>
8861 * c-common.c (parse_optimize_options): Do not capitalize warning
8862 messages. Remove period at end of warning message.
8864 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
8866 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
8867 (handle_alias_attribute): ... here.
8868 (handle_ifunc_attribute): New.
8870 2010-09-06 Mark Mitchell <mark@codesourcery.com>
8872 * c-common.h (do_warn_double_promotion): Declare.
8873 * c-common.c (do_warn_double_promotion): Define.
8875 2010-09-05 Mark Mitchell <mark@codesourcery.com>
8877 * c.opt (Wdouble-promotion): New.
8879 2010-09-02 Joseph Myers <joseph@codesourcery.com>
8881 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
8882 fvtable-thunks, fxref): Mark no longer supported in help text.
8884 2010-09-02 Joseph Myers <joseph@codesourcery.com>
8886 * c.opt (Wimport, fall-virtual, falt-external-templates,
8887 fdefault-inline, fenum-int-equiv, fexternal-templates,
8888 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
8889 fname-mangling-version-, fnew-abi, fnonnull-objects,
8890 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
8891 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
8893 (fhandle-exceptions): Mark with Alias and Warn.
8894 * c-opts.c (c_common_handle_option): Don't handle options marked
8897 2010-09-02 Joseph Myers <joseph@codesourcery.com>
8899 * c.opt (Wcomments, Werror-implicit-function-declaration,
8900 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
8901 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
8903 * c-common.c (option_codes): Use OPT_Wcomment instead of
8905 * c-opts.c (warning_as_error_callback, c_common_handle_option):
8906 Don't handle options marked as aliases.
8908 2010-08-25 Richard Guenther <rguenther@suse.de>
8910 * c-common.c (c_common_get_alias_set): Remove special
8911 handling for pointers.
8913 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
8915 * c-common.c: Use FOR_EACH_VEC_ELT.
8916 * c-gimplify.c: Likewise.
8917 * c-pragma.c: Likewise.
8919 2010-08-16 Joseph Myers <joseph@codesourcery.com>
8921 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
8923 (MMDX): Change back to MMD. Mark NoDriverArg instead of
8925 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
8926 instead of OPT_MDX and OPT_MMDX.
8928 2010-08-16 Joseph Myers <joseph@codesourcery.com>
8930 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
8932 2010-08-12 Joseph Myers <joseph@codesourcery.com>
8934 * c.opt (MD, MMD): Change to MDX and MMDX.
8935 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
8937 2010-08-11 Joseph Myers <joseph@codesourcery.com>
8939 * c-opts.c (c_common_handle_option): Call handle_generated_option
8940 instead of handle_option.
8942 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
8944 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
8945 (maybe_apply_renaming_pragma): Delete unneeded declarations.
8947 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
8949 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
8950 (pending_redefine_extname): Change type to a VEC.
8951 (add_to_renaming_pragma_list): Update for new type of
8952 pending_redefine_extname.
8953 (maybe_apply_renaming_pragma): Likewise.
8955 2010-08-04 Arnaud Charlet <charlet@adacore.com>
8957 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
8959 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
8960 decide whether a type has already been declared/seen.
8961 Do not go to the original type.
8962 (dump_nested_types): New parameter forward.
8963 Generate forward declaration if needed and mark type as visited.
8964 (print_ada_declaration): Call dump_nested_types if not already done.
8965 Mark types as visited.
8967 2010-08-03 Joseph Myers <joseph@codesourcery.com>
8969 * c.opt (-print-pch-checksum): Remove option.
8970 * c-opts.c (c_common_handle_option): Don't handle
8971 OPT_print_pch_checksum.
8973 2010-07-27 Joseph Myers <joseph@codesourcery.com>
8975 * c-common.h (c_common_handle_option): Update prototype and return
8977 * c-opts.c (c_common_handle_option): Update prototype and return
8978 value type. Update calls to handle_option and
8979 enable_warning_as_error.
8981 2010-07-27 Jakub Jelinek <jakub@redhat.com>
8984 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
8986 2010-07-27 Joseph Myers <joseph@codesourcery.com>
8988 * c-common.h (c_common_missing_argument): Remove.
8989 * c-opts.c (c_common_missing_argument): Remove.
8990 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
8991 idirafter, imacros, include, isysroot, isystem, iquote): Add
8993 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
8995 2010-07-27 Joseph Myers <joseph@codesourcery.com>
8997 * c-common.h (c_common_option_lang_mask,
8998 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
9000 (c_common_init_options): Update prototype.
9001 * c-opts.c (c_common_option_lang_mask): New.
9002 (c_common_initialize_diagnostics): Split out of
9003 c_common_init_options.
9004 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
9006 (c_common_init_options): Update prototype. Use decoded options in
9007 search for -lang-asm.
9009 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
9011 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
9012 * c-format.c: Likewise.
9014 2010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
9016 * c-common.h: Include diagnostic-core.h. Error if already
9018 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
9020 2010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
9022 * c-common.c (IN_GCC_FRONTEND): Do not undef.
9023 Do not include expr.h
9024 (vector_mode_valid_p): Move here.
9026 2010-06-21 DJ Delorie <dj@redhat.com>
9028 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
9029 allow these pragmas anywhere.
9031 2010-06-14 Jakub Jelinek <jakub@redhat.com>
9034 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
9035 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
9036 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
9037 ggc_strdup instead of xstrdup.
9039 2010-06-10 Jakub Jelinek <jakub@redhat.com>
9041 * c-cppbuiltin.c: Include cpp-id-data.h.
9042 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
9043 (lazy_hex_fp_value): New function.
9044 (builtin_define_with_hex_fp_value): Provide definitions lazily.
9046 2010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
9048 * c-gimplify.c: Do not include tree-flow.h
9050 2010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
9053 * c-common.c: Rename targetm member:
9054 targetm.enum_va_list -> targetm.enum_va_list_p
9056 2010-06-28 Anatoly Sokolov <aesok@post.ru>
9058 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
9060 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
9062 * c-cppbuiltin.c: Do not include except.h.
9064 2010-06-24 Andi Kleen <ak@linux.intel.com>
9066 * c-common.c (warn_for_omitted_condop): New.
9067 * c-common.h (warn_for_omitted_condop): Add prototype.
9069 2010-06-21 Joseph Myers <joseph@codesourcery.com>
9071 * c.opt (lang-objc): Remove.
9072 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
9074 2010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
9076 * c-opts.c: Include "tm_p.h".
9078 2010-06-20 Joseph Myers <joseph@codesourcery.com>
9080 * c-common.c (parse_optimize_options): Update call to
9083 2010-06-18 Nathan Froyd <froydnj@codesourcery.com>
9085 * c-common.c (record_types_used_by_current_var_decl): Adjust for
9086 new type of types_used_by_cur_var_decl.
9088 2010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
9091 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
9092 for C++ standard compliance.
9094 2010-06-16 Jason Merrill <jason@redhat.com>
9096 * c.opt: Add -Wnoexcept.
9098 2010-06-16 Richard Guenther <rguenther@suse.de>
9101 * c-common.c (c_common_truthvalue_conversion): Remove
9102 premature and wrong optimization concering ADDR_EXPRs.
9104 2010-06-15 Arnaud Charlet <charlet@adacore.com>
9106 * c-ada-spec.c (dump_sloc): Remove column info.
9107 (is_simple_enum): New function.
9108 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
9109 enum types when relevant.
9111 2010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
9113 * c-common.c (conversion_warning): Warn at expression
9116 2010-06-10 Joseph Myers <joseph@codesourcery.com>
9118 * c-opts.c (c_common_handle_option): Don't handle
9121 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
9123 * c-pragma.c (push_alignment): Use typed GC allocation.
9124 (handle_pragma_push_options): Likewise.
9126 * c-common.c (parse_optimize_options): Likewise.
9128 * c-common.h (struct sorted_fields_type): Add variable_size GTY
9131 2010-06-07 Joseph Myers <joseph@codesourcery.com>
9133 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
9134 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
9135 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
9136 flag_signed_bitfields, warn_strict_null_sentinel,
9137 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
9138 flag_gen_declaration, flag_no_gnu_keywords,
9139 flag_implement_inlines, flag_implicit_templates,
9140 flag_implicit_inline_templates, flag_optional_diags,
9141 flag_elide_constructors, flag_default_inline, flag_rtti,
9142 flag_conserve_space, flag_access_control, flag_check_new,
9143 flag_new_for_scope, flag_weak, flag_working_directory,
9144 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
9145 flag_enforce_eh_specs, flag_threadsafe_statics,
9146 flag_pretty_templates): Remove.
9147 * c-common.h (flag_preprocess_only, flag_nil_receivers,
9148 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
9149 flag_replace_objc_classes, flag_undef, flag_no_builtin,
9150 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
9151 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
9152 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
9153 flag_no_gnu_keywords, flag_implement_inlines,
9154 flag_implicit_templates, flag_implicit_inline_templates,
9155 flag_optional_diags, flag_elide_constructors, flag_default_inline,
9156 flag_rtti, flag_conserve_space, flag_access_control,
9157 flag_check_new, flag_new_for_scope, flag_weak,
9158 flag_working_directory, flag_use_cxa_atexit,
9159 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
9160 flag_threadsafe_statics, flag_pretty_templates,
9161 warn_strict_null_sentinel): Remove.
9162 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
9163 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
9164 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
9165 fimplicit-inline-templates, fimplicit-templates,
9166 flax-vector-conversions, fms-extensions, fnil-receivers,
9167 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
9168 frtti, fshort-double, fshort-enums, fshort-wchar,
9169 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
9170 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
9171 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
9172 gen-decls, undef): Use Var.
9173 (fdefault-inline, foptional-diags): Document as doing nothing.
9174 * c-opts.c (c_common_handle_option): Remove cases for options now
9175 using Var. Mark ignored options as such.
9177 2010-06-05 Steven Bosscher <steven@gcc.gnu.org>
9179 * c-common.c: Moved to here from parent directory.
9180 * c-common.def: Likewise.
9181 * c-common.h: Likewise.
9182 * c-cppbuiltin.c: Likewise.
9183 * c-dump.c: Likewise.
9184 * c-format.c: Likewise.
9185 * c-format.h : Likewise.
9186 * c-gimplify.c: Likewise.
9187 * c-lex.c: Likewise.
9188 * c-omp.c: Likewise.
9190 * c-opts.c: Likewise.
9191 * c-pch.c: Likewise.
9192 * c-ppoutput.c: Likewise.
9193 * c-pragma.c: Likewise.
9194 * c-pragma.h: Likewise.
9195 * c-pretty-print.c: Likewise.
9196 * c-pretty-print.h: Likewise.
9197 * c-semantics.c: Likewise.
9198 * stub-objc.c: Likewise.
9200 * c-common.c: Include gt-c-family-c-common.h.
9201 * c-pragma.c: Include gt-c-family-c-pragma.h.
9203 Copyright (C) 2010-2018 Free Software Foundation, Inc.
9205 Copying and distribution of this file, with or without modification,
9206 are permitted in any medium without royalty provided the copyright
9207 notice and this notice are preserved.