1 2021-10-01 Martin Sebor <msebor@redhat.com>
4 * c-common.c (decl_with_nonnull_addr_p): Handle members.
5 Check and perform warning suppression.
6 (c_common_truthvalue_conversion): Enhance warning suppression.
8 2021-10-01 Martin Liska <mliska@suse.cz>
11 * c-common.c (parse_optimize_options): decoded_options[0] is
12 used for program name, so merged_decoded_options should also
15 2021-10-01 Jakub Jelinek <jakub@redhat.com>
16 Richard Biener <rguenther@suse.de>
19 * c-ubsan.c (ubsan_instrument_division): Check the right
20 flag_sanitize_recover bit, depending on which sanitization
21 is done. Sanitize INT_MIN / -1 under SANITIZE_SI_OVERFLOW
22 rather than SANITIZE_DIVIDE. If both SANITIZE_SI_OVERFLOW
23 and SANITIZE_DIVIDE is enabled, neither check is known
24 to be false and flag_sanitize_recover bits for those two
25 aren't the same, emit both __ubsan_handle_divrem_overflow
26 and __ubsan_handle_divrem_overflow_abort calls.
28 2021-10-01 Martin Liska <mliska@suse.cz>
30 * c-common.c (parse_optimize_options): Combine optimize
31 options with what was provided on the command line.
33 2021-10-01 Jakub Jelinek <jakub@redhat.com>
35 * c-omp.c (c_omp_split_clauses): Also copy
36 OMP_CLAUSE_ORDER_REPRODUCIBLE.
38 2021-09-27 Martin Liska <mliska@suse.cz>
40 * c-opts.c (c_common_init_options_struct): Set also
41 x_flag_default_complex_method.
43 2021-09-22 Jakub Jelinek <jakub@redhat.com>
45 * c-omp.c (c_omp_split_clauses): Copy over OMP_CLAUSE_ALLOCATE_ALIGN.
47 2021-09-20 Matthias Kretz <m.kretz@gsi.de>
49 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define or
50 undefine __RECIPROCAL_MATH__, __NO_SIGNED_ZEROS__,
51 __NO_TRAPPING_MATH__, __ASSOCIATIVE_MATH__, and
52 __ROUNDING_MATH__ according to the new optimization flags.
54 2021-09-18 Jakub Jelinek <jakub@redhat.com>
56 * c-omp.c (c_omp_split_clauses): Split order clause also to
57 distribute construct. Copy over OMP_CLAUSE_ORDER_UNCONSTRAINED.
59 2021-09-17 Jakub Jelinek <jakub@redhat.com>
61 * c-omp.c (c_finish_omp_atomic): Avoid creating
62 TARGET_EXPR if test is true, use create_tmp_var_raw instead of
63 create_tmp_var and add a zero initializer to TARGET_EXPRs that
64 had NULL initializer. When omitting operands after v = x,
65 use type of v rather than type of x. Fix type of vtmp
68 2021-09-13 Jason Merrill <jason@redhat.com>
70 * c.opt: Add -Winterference-size.
71 * c-cppbuiltin.c (cpp_atomic_builtins): Add __GCC_DESTRUCTIVE_SIZE
72 and __GCC_CONSTRUCTIVE_SIZE.
74 2021-09-10 Jakub Jelinek <jakub@redhat.com>
76 * c-common.h (c_finish_omp_atomic): Add r and weak arguments.
77 * c-omp.c: Include gimple-fold.h.
78 (c_finish_omp_atomic): Add r and weak arguments. Add support for
81 2021-09-09 qing zhao <qing.zhao@oracle.com>
83 * c-attribs.c (handle_uninitialized_attribute): New function.
84 (c_common_attribute_table): Add "uninitialized" attribute.
86 2021-09-08 liuhongt <hongtao.liu@intel.com>
88 * c-common.c (excess_precision_mode_join): Update below comments.
89 (c_ts18661_flt_eval_method): Set excess_precision_type to
90 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
91 * c-cppbuiltin.c (cpp_atomic_builtins): Update below comments.
92 (c_cpp_flt_eval_method_iec_559): Set excess_precision_type to
93 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
95 2021-09-07 Marcel Vollweiler <marcel@codesourcery.com>
97 * c-omp.c (c_finish_omp_flush): Handle MEMMODEL_SEQ_CST.
99 2021-09-03 Eric Botcazou <ebotcazou@adacore.com>
101 * c-ada-spec.c (dump_ads): Generate pragmas to disable style checks
102 and -gnatwu warning for the package specification.
104 2021-09-01 Iain Sandoe <iain@sandoe.co.uk>
106 * c-attribs.c (handle_unavailable_attribute): New.
108 2021-08-30 Jason Merrill <jason@redhat.com>
110 * c.opt: Add -Wmissing-requires.
112 2021-08-25 Lewis Hyatt <lhyatt@gmail.com>
115 * c-opts.c (c_common_input_charset_cb): New function.
116 (c_common_post_options): Call new function
117 diagnostic_initialize_input_context().
119 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
121 * c-format.c (gcc_gfc_length_specs): Add 'll' and 'w'.
122 (gcc_gfc_char_table): Add T9L_LL and T9L_ULL to
123 "di" and "u", respecitively; fill with BADLEN to match
125 (get_init_dynamic_hwi): Split off from ...
126 (init_dynamic_diag_info): ... here. Call it.
127 (init_dynamic_gfc_info): Call it.
129 2021-08-20 Jakub Jelinek <jakub@redhat.com>
131 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ERROR.
132 * c-pragma.c (omp_pragmas): Add error directive.
133 * c-omp.c (omp_directives): Uncomment error directive entry.
135 2021-08-18 Jakub Jelinek <jakub@redhat.com>
137 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_NOTHING.
138 * c-pragma.c (omp_pragmas): Add nothing directive.
139 * c-omp.c (omp_directives): Uncomment nothing directive entry.
141 2021-08-17 Jakub Jelinek <jakub@redhat.com>
144 * c-common.h (enum rid): Add RID_IS_LAYOUT_COMPATIBLE.
145 * c-common.c (c_common_reswords): Add __is_layout_compatible.
147 2021-08-17 Matt Jacobson <mhjacobson@me.com>
149 * c-opts.c (c_common_post_options): Default to
150 flag_objc_sjlj_exceptions = 1 only when flag_objc_abi < 2.
152 2021-08-17 Jakub Jelinek <jakub@redhat.com>
154 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCOPE.
155 * c-pragma.c (omp_pragmas): Add scope construct.
156 * c-omp.c (omp_directives): Uncomment scope directive entry.
158 2021-08-16 Sebastian Huber <sebastian.huber@embedded-brains.de>
160 * c-cppbuiltin.c (c_cpp_builtins): Define
161 __LIBGCC_GCOV_TYPE_SIZE if flag_building_libgcc is true.
163 2021-08-12 Jakub Jelinek <jakub@redhat.com>
165 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_MASKED.
166 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FILTER.
167 * c-pragma.c (omp_pragmas_simd): Add masked construct.
168 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_MASKED
170 (c_finish_omp_masked): Declare.
171 * c-omp.c (c_finish_omp_masked): New function.
172 (c_omp_split_clauses): Handle combined masked constructs.
174 2021-07-30 Jakub Jelinek <jakub@redhat.com>
177 * c-common.h (enum rid): Add RID_IS_POINTER_INTERCONVERTIBLE_BASE_OF.
178 * c-common.c (c_common_reswords): Add
179 __is_pointer_interconvertible_base_of.
181 2021-07-29 Richard Biener <rguenther@suse.de>
184 * c-common.c (c_common_mark_addressable_vec): Look through
185 C_MAYBE_CONST_EXPR even if not at the toplevel.
187 2021-07-27 Martin Sebor <msebor@redhat.com>
190 * c-warn.c (warn_parm_ptrarray_mismatch): Use OEP_DECL_NAME.
192 2021-07-23 Jakub Jelinek <jakub@redhat.com>
194 * c-lex.c (c_common_has_attribute): Call canonicalize_attr_name also
195 on attr_id. Return 1 for omp::directive or omp::sequence in C++11
198 2021-07-23 Jakub Jelinek <jakub@redhat.com>
200 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP__START_ and
201 PRAGMA_OMP__LAST_ enumerators.
203 2021-07-21 Thomas Schwinge <thomas@codesourcery.com>
204 Joseph Myers <joseph@codesourcery.com>
205 Cesar Philippidis <cesar@codesourcery.com>
207 * c-pragma.h (pragma_omp_clause): Add 'PRAGMA_OACC_CLAUSE_NOHOST'.
209 2021-07-20 Martin Sebor <msebor@redhat.com>
211 * c-common.c (c_build_shufflevector): Adjust by-value argument to
213 * c-common.h (c_build_shufflevector): Same.
215 2021-07-16 Andrew Pinski <apinski@marvell.com>
218 * c-common.c (parse_optimize_options): Use the correct
221 2021-07-15 Martin Sebor <msebor@redhat.com>
225 * c-warn.c (warn_parm_array_mismatch): Use OEP_DECL_NAME.
227 2021-07-14 Jason Merrill <jason@redhat.com>
229 * c-opts.c (c_common_post_options): Set -fdelete-dead-exceptions.
231 2021-07-06 Martin Sebor <msebor@redhat.com>
233 * c-format.c (gcc_tdiag_char_table): Remove support for %G and %K.
234 (gcc_cdiag_char_table): Same.
235 (gcc_cxxdiag_char_table): Same.
237 2021-07-02 Jakub Jelinek <jakub@redhat.com>
239 * c-common.h (enum c_omp_directive_kind): New enum.
240 (struct c_omp_directive): New type.
241 (c_omp_categorize_directive): Declare.
242 * c-omp.c (omp_directives): New variable.
243 (c_omp_categorize_directive): New function.
245 2021-07-01 Eric Botcazou <ebotcazou@adacore.com>
247 * c-ada-spec.c (packed_layout): New global variable.
248 (dump_ada_declaration): Set it upon seeing a packed record type.
249 Do not put the "aliased" keyword if it is set.
250 (dump_ada_structure): Add Pack aspect if it is set and clear it.
252 2021-07-01 Eric Botcazou <ebotcazou@adacore.com>
254 * c-ada-spec.c (check_name): Rename into...
255 (check_type_name_conflict): ...this. Minor tweak.
256 (dump_ada_function_declaration): Adjust to above renaming.
257 (dump_ada_array_domains): Fix oversight.
258 (dump_ada_declaration): Call check_type_name_conflict for variables.
260 2021-06-25 Martin Sebor <msebor@redhat.com>
262 * c-common.c (c_wrap_maybe_const): Remove TREE_NO_WARNING.
263 (c_common_truthvalue_conversion): Replace direct uses of
264 TREE_NO_WARNING with warning_suppressed_p, suppress_warning, and
266 (check_function_arguments_recurse): Same.
267 * c-gimplify.c (c_gimplify_expr): Same.
268 * c-warn.c (overflow_warning): Same.
269 (warn_logical_operator): Same.
270 (warn_if_unused_value): Same.
271 (do_warn_unused_parameter): Same.
273 2021-06-24 Jakub Jelinek <jakub@redhat.com>
275 * c-common.h (enum c_omp_region_type): Add C_ORT_TARGET and
277 * c-omp.c (c_omp_split_clauses): For OMP_CLAUSE_IN_REDUCTION on
278 combined target constructs also add map (always, tofrom:) clause.
280 2021-06-15 Robin Dapp <rdapp@linux.ibm.com>
282 * c-attribs.c (common_handle_aligned_attribute): Remove short
283 circuit and dead code.
285 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
288 * known-headers.cc (get_stdlib_header_for_name): Add known
289 headers for EXIT_FAILURE, EXIT_SUCCESS, abort, atexit, calloc,
292 2021-06-12 Jason Merrill <jason@redhat.com>
294 * c-attribs.c (handle_unused_attribute): Handle FIELD_DECL.
296 2021-06-11 Jakub Jelinek <jakub@redhat.com>
299 * c-cppbuiltin.c (c_cpp_builtins): Predefine __cpp_if_consteval for
300 -std=c++2b for P1938R3 consteval if support.
302 2021-06-09 Jason Merrill <jason@redhat.com>
305 * c-warn.c (warn_for_sign_compare): Remove C++ enum mismatch
308 2021-06-07 Martin Liska <mliska@suse.cz>
310 * c-target.def: Split long lines and replace them
313 2021-06-04 Martin Sebor <msebor@redhat.com>
316 * c-attribs.c (positional_argument): Bail on erroneous types.
318 2021-06-04 Martin Sebor <msebor@redhat.com>
320 * c-warn.c (warn_parm_array_mismatch): Check TREE_PURPOSE to test
321 for element presence.
323 2021-06-03 Eric Botcazou <ebotcazou@adacore.com>
325 * c-ada-spec.c (dump_ada_macros): Minor tweaks.
326 (dump_ada_decl_name): Likewise.
327 (dump_anonymous_type_name): Remove parent parameter and adjust.
328 (dump_sloc): Minor tweak.
329 (dump_ada_array_type): Remove type parameter and adjust.
330 (dump_ada_enum_type): Remove parent parameter and adjust.
331 (dump_ada_node): Adjust calls to above functions.
332 (dumped_anonymous_types): New global variable.
333 (dump_nested_types_1): Rename into...
334 (dump_nested_types): ...this.
335 (dump_nested_type): Remove parent and dumped_types parameters.
336 <ARRAY_TYPE>: Replace dumped_types with dumped_anonymous_types.
337 Adjust calls to dump_anonymous_type_name and dump_ada_array_type.
338 (dump_ada_specs): Initialize and free dumped_anonymous_types.
340 2021-06-03 Eric Botcazou <ebotcazou@adacore.com>
342 * c-ada-spec.c (pp_ada_tree_identifier): Tidy up.
343 (dump_ada_node) <POINTER_TYPE>: Deal specially with external subtypes.
345 2021-06-03 Eric Botcazou <ebotcazou@adacore.com>
347 * c-ada-spec.c (dump_ada_enum_type): Dump a prefix for constants.
348 (htable_t): New typedef.
349 (overloaded_names): Use it.
350 (add_name): New function.
351 (init_overloaded_names): Use add_name to populate the table and add
352 special cases for sigaction and stat.
353 (overloaded_name_p): Rename into...
354 (overloading_index): ...this. Do not initialize overloaded_names table
355 here. Return the index or zero.
356 (dump_ada_declaration): Minor tweaks. Do not skip overloaded functions
357 but add an overloading suffix instead.
358 (dump_ada_specs): Initialize overloaded_names tables here.
360 2021-06-01 Martin Liska <mliska@suse.cz>
363 * c-attribs.c (handle_optimize_attribute): Limit sanity check
364 to a situation where we are not in processing of an optimize
366 * c-pragma.c (handle_pragma_pop_options): Restore target
369 2021-05-31 Indu Bhagat <indu.bhagat@oracle.com>
372 * c-pch.c (c_common_valid_pch): Use xstrdup for debug format set names.
374 2021-05-31 Richard Biener <rguenther@suse.de>
377 * c-common.c: Include tree-vector-builder.h and
379 (c_common_reswords): Add __builtin_shufflevector.
380 (c_build_shufflevector): New funtion.
381 * c-common.h (enum rid): Add RID_BUILTIN_SHUFFLEVECTOR.
382 (c_build_shufflevector): Declare.
384 2021-05-28 Jakub Jelinek <jakub@redhat.com>
387 * c-omp.c (c_omp_split_clauses): For reduction clause if combined with
388 target add a map tofrom clause with OMP_CLAUSE_MAP_IMPLICIT.
390 2021-05-28 Tobias Burnus <tobias@codesourcery.com>
392 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_AFFINITY.
394 2021-05-25 Martin Liska <mliska@suse.cz>
396 PR tree-optimization/92860
398 * c-attribs.c (handle_optimize_attribute): Save target node
399 before calling parse_optimize_options and save it in case
401 * c-pragma.c (handle_pragma_target): Similarly for pragma.
402 (handle_pragma_pop_options): Likewise here.
404 2021-05-25 Martin Liska <mliska@suse.cz>
406 * c-attribs.c (handle_no_sanitize_coverage_attribute): New.
408 2021-05-25 Jakub Jelinek <jakub@redhat.com>
411 * c-omp.c (c_omp_split_clauses): Copy reduction to teams when teams is
412 combined with simd and not with taskloop or for.
414 2021-05-21 Jakub Jelinek <jakub@redhat.com>
417 * c-omp.c (c_omp_split_clauses): Set OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT
418 on firstprivate clause copy going to target construct, and for
419 target simd set also OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT_TARGET bit.
421 2021-05-20 Jonathan Wakely <jwakely@redhat.com>
423 * c.opt (Wc++11-extensions, Wc++14-extensions)
424 (Wc++17-extensions, Wc++20-extensions, Wc++23-extensions): New
427 2021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
429 * c-lex.c (init_c_lex): Use dwarf_debuginfo_p.
431 2021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
433 * c-opts.c (c_common_post_options): Adjust access to debug_type_names.
434 * c-pch.c (struct c_pch_validity): Use type uint32_t.
435 (pch_init): Renamed member.
436 (c_common_valid_pch): Adjust access to debug_type_names.
438 2021-05-19 Martin Sebor <msebor@redhat.com>
441 * c-attribs.c (build_attr_access_from_parms): Handle arbitrarily many
444 2021-05-18 Richard Biener <rguenther@suse.de>
447 * c-attribs.c (type_valid_for_vector_size): Reject too large nunits.
448 Reword existing nunit diagnostic.
450 2021-05-17 Joern Rennecke <joern.rennecke@embecosm.com>
452 * c-common.c (braced_list_to_string): Return CTOR unchanged
453 if host and target character sizes don't match.
455 2021-05-14 Martin Liska <mliska@suse.cz>
457 * c.opt: Add Warning keyword for 2 options.
459 2021-05-13 Martin Liska <mliska@suse.cz>
462 * c-attribs.c (handle_target_clones_attribute): Expect a string
463 argument to target_clone argument.
465 2021-05-11 Joseph Myers <joseph@codesourcery.com>
467 * c-lex.c (interpret_float): Handle digit separators for C2X.
469 2021-05-10 Martin Liska <mliska@suse.cz>
471 * c-ada-spec.c (print_destructor): Use startswith
472 function instead of strncmp.
473 (dump_ada_declaration): Likewise.
474 * c-common.c (disable_builtin_function): Likewise.
475 (def_builtin_1): Likewise.
476 * c-format.c (check_tokens): Likewise.
477 (check_plain): Likewise.
478 (convert_format_name_to_system_name): Likewise.
480 2021-04-28 Patrick McGehearty <patrick.mcgehearty@oracle.com>
482 * c-cppbuiltin.c (c_cpp_builtins): Add supporting macros for new
485 2021-04-26 Thomas Schwinge <thomas@codesourcery.com>
486 Nathan Sidwell <nathan@codesourcery.com>
487 Tom de Vries <vries@codesourcery.com>
488 Julian Brown <julian@codesourcery.com>
489 Kwok Cheung Yeung <kcy@codesourcery.com>
491 * c.opt (Wopenacc-parallelism): New.
493 2021-04-19 Thomas Schwinge <thomas@codesourcery.com>
495 * c.opt (fopenacc-kernels=): Remove.
497 2021-04-08 Jakub Jelinek <jakub@redhat.com>
499 * c-warn.c (do_warn_double_promotion): Fix comment typo,
501 (check_alignment_of_packed_member): Fix a comment typo,
503 (warn_parm_ptrarray_mismatch): Fix comment typos, os -> of
504 and onless -> unless.
505 (warn_parm_array_mismatch): Fix comment typos, declaratation
506 -> declaration and woud -> would. Fix up comment indentation.
508 2021-04-08 Martin Sebor <msebor@redhat.com>
511 * c.opt (Wmismatched-new-delete): Correct spelling.
513 2021-04-05 Eric Botcazou <ebotcazou@adacore.com>
515 * c-ada-spec.c (is_simple_enum): Minor tweaks.
516 (dump_ada_enum_type): Add TYPE and PARENT parameters. For non-simple
517 enumeral types use again the type name for the enumeration constants.
518 (dump_ada_node): Adjust call to dump_ada_enum_type.
519 (dump_nested_type): Likewise.
521 2021-04-01 Jason Merrill <jason@redhat.com>
524 * c-opts.c (c_common_post_options): Bump latest_abi_version.
526 2021-03-25 Jakub Jelinek <jakub@redhat.com>
529 * c-warn.c (do_warn_duplicated_branches): Pass also
530 OEP_ADDRESS_OF_SAME_FIELD to operand_equal_p.
532 2021-03-20 Jakub Jelinek <jakub@redhat.com>
535 * c-gimplify.c (c_genericize_control_stmt): Handle STATEMENT_LIST.
537 2021-03-05 Eric Botcazou <ebotcazou@adacore.com>
539 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Dump nested types
540 after entering the separate class package, if any.
542 2021-03-04 Richard Biener <rguenther@suse.de>
544 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator):
547 2021-03-04 Jakub Jelinek <jakub@redhat.com>
550 * c-ppoutput.c (print): Change src_line type from int to unsigned.
551 (token_streamer::stream) Likewise.
552 (maybe_print_line_1): Likewise. Don't strcmp src_file if src_loc is
555 2021-03-03 Jakub Jelinek <jakub@redhat.com>
558 * c-common.c (build_va_arg): Call c_common_mark_addressable_vec
559 instead of mark_addressable. Fix a comment typo -
560 neutrallly -> neutrally.
562 2021-02-28 Jakub Jelinek <jakub@redhat.com>
565 * c-attribs.c (handle_malloc_attribute): Fix a typo in inform
566 message - refernced -> referenced. Remove superfluous space before
567 closing paren of function calls.
569 2021-02-25 Nathan Sidwell <nathan@acm.org>
572 * c.opt (-flang-info-module-cmi): Renamed option.
574 2021-02-19 Nathan Sidwell <nathan@acm.org>
576 * c.opt (flang-info-module-read, flang-info-module-read=): New.
578 2021-02-18 H.J. Lu <hjl.tools@gmail.com>
581 * c-attribs.c (c_common_attribute_table): Add the "retain"
583 (handle_retain_attribute): New function.
585 2021-02-16 Marek Polacek <polacek@redhat.com>
588 * c-attribs.c (handle_assume_aligned_attribute): Check that the
589 alignment argument is non-negative. Tweak a warning message.
591 2021-02-12 Martin Sebor <msebor@redhat.com>
594 * c-warn.c (warn_parm_array_mismatch): Free strings returned from
595 print_generic_expr_to_str.
597 2021-02-10 Richard Biener <rguenther@suse.de>
599 * c-common.c (parse_optimize_options): Free decoded_options.
601 2021-02-04 emsr <3dw4rd@verizon.net>
603 * c-cppbuiltin.c (c_cpp_builtins): __cpp_size_t_suffix=202011L.
605 2021-02-03 Ed Smith-Rowland <3dw4rd@verizon.net>
607 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_size_t_suffix.
608 * c-lex.c (interpret_integer): Set node type for size literal.
610 2021-01-28 Jakub Jelinek <jakub@redhat.com>
612 * c.opt (-std=c++2a, -std=c++20, -std=gnu++2a, -std=gnu++20): Remove
613 draft from description.
614 (-std=c++2b): Fix a pasto, 2020 -> 2023.
616 2021-01-26 Paul Fee <paul.f.fee@gmail.com>
618 * c-common.h (cxx_dialect): Add cxx23 as a dialect.
619 * c.opt: Add options for -std=c++23, std=c++2b, -std=gnu++23
621 * c-opts.c (set_std_cxx23): New.
622 (c_common_handle_option): Set options when -std=c++23 is enabled.
623 (c_common_post_options): Adjust comments.
624 (set_std_cxx20): Likewise.
626 2021-01-25 Martin Sebor <msebor@redhat.com>
629 * c-common.c (check_nonnull_arg): Adjust warning text.
631 2021-01-17 Martin Sebor <msebor@redhat.com>
633 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
634 assume SSA_NAME_IDENTIFIER evaluates to nonzero.
636 2021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
638 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DETACH.
639 Redefine PRAGMA_OACC_CLAUSE_DETACH.
641 2021-01-15 Jakub Jelinek <jakub@redhat.com>
643 PR tree-optimization/98597
644 * c-pretty-print.c: Include options.h.
645 (c_fold_indirect_ref_for_warn): New function.
646 (print_mem_ref): Use it. If it returns something that has compatible
647 type and is TBAA compatible with zero offset, print it and return,
648 otherwise print it using offsetof syntax or array ref syntax. Fix up
649 printing if MEM_REFs first operand is ADDR_EXPR, or when the first
650 argument has pointer to array type. Print pointers using the standard
653 2021-01-12 Martin Sebor <msebor@redhat.com>
657 * c-pretty-print.c (print_mem_ref): Avoid assuming MEM_REF operand
658 has pointer type. Remove redundant code. Avoid calling
659 gimple_canonical_types_compatible_p.
661 2021-01-07 Martin Sebor <msebor@redhat.com>
664 * c-pretty-print.c (print_mem_ref): Strip array from access type.
665 Avoid assuming acces type's size is constant. Correct condition
666 guarding the printing of a parenthesis.
668 2021-01-06 Martin Sebor <msebor@redhat.com>
671 * c-pretty-print.c (c_pretty_printer::primary_expression): For
672 SSA_NAMEs print VLA names and GIMPLE defining statements.
673 (print_mem_ref): New function.
674 (c_pretty_printer::unary_expression): Call it.
676 2021-01-06 Richard Biener <rguenther@suse.de>
678 PR tree-optimization/95582
679 * c-attribs.c (c_common_attribute_table): Add entry for
680 signed_bool_precision.
681 (handle_signed_bool_precision_attribute): New.
683 2020-12-24 Iain Sandoe <iain@sandoe.co.uk>
685 * c.opt: Add -stdlib= option and enumerations for
686 libstdc++ and libc++.
688 2020-12-16 Martin Liska <mliska@suse.cz>
690 * c.opt: Remove usage of Report.
692 2020-12-14 Martin Sebor <msebor@redhat.com>
697 * c-attribs.c (maybe_add_noinline): New function.
698 (handle_malloc_attribute): Call it. Use ATTR_FLAG_INTERNAL.
699 Implicitly add attribute noinline to functions not declared inline
702 2020-12-09 Tobias Burnus <tobias@codesourcery.com>
704 * c-pragma.c (omp_pragmas): Add 'allocate'.
705 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ALLOCATE.
707 2020-12-08 Jakub Jelinek <jakub@redhat.com>
710 * c-pragma.c (omp_pragmas): Remove "master".
711 (omp_pragmas_simd): Add "master".
713 2020-12-07 Marek Polacek <polacek@redhat.com>
716 * c-common.c (verify_tree_lim_r): New function.
717 (verify_sequence_points): Use it. Use nullptr instead of 0.
719 2020-12-03 Martin Sebor <msebor@redhat.com>
723 * c-attribs.c (handle_dealloc_attribute): New function.
724 (handle_malloc_attribute): Handle argument forms of attribute.
725 * c.opt (-Wmismatched-dealloc): New option.
726 (-Wmismatched-new-delete): New option.
728 2020-12-03 Jakub Jelinek <jakub@redhat.com>
731 * c-common.h (enum rid): Add RID_BUILTIN_BIT_CAST.
732 * c-common.c (c_common_reswords): Add __builtin_bit_cast.
734 2020-12-01 JeanHeyd Meneide <phdofthehouse@gmail.com>
736 * c-cppbuiltin.c (c_cpp_builtins): Add predefined
737 {__GNUC_EXECUTION_CHARSET_NAME} and
738 _WIDE_EXECUTION_CHARSET_NAME} macros.
740 2020-12-01 Nathan Sidwell <nathan@acm.org>
742 * c-common.c (module, import, export): New internal tokens (with
744 * c-common.h (RID__MODULE, RID__IMPORT & RID__EXPORT): Enumerate
746 (D_CXX_MODULES, D_CXX_MODULES_FLAGS): Enable them.
747 * c-cppbuiltin.c (c_cpp_builtins): Feature macro.
749 2020-12-01 Nathan Sidwell <nathan@acm.org>
751 * c-opts.c (c_common_init_options): Ask for module dependencies.
752 (c_common_handle_option): Handle -Mmodules -Mno-modules.
753 * c-pch.c (c_common_valid_pch): ... does not play with C++
755 * c.opt (Mmodules, Mno-modules): New preprocessor dependency
757 (fmodules-ts, fmodule-header, fmodule-implicit-inline)
758 (fmodule-only, fmodule-mapper, fmodule-lazy)
759 (fmodule-version-ignore, Winvalid-imported-macros)
760 (flang-info-include-translate, flang-info-include-translate-not):
763 2020-11-28 Eric Botcazou <ebotcazou@adacore.com>
765 * c-ada-spec.c (dump_nested_type) <RECORD_TYPE>: Remove obsolete code.
766 (dump_ada_structure): Also deal with convention, unchecked union and
767 bit-field for nested types. In the latter case, print an Alignment
768 aspect along with the Pack aspect.
770 2020-11-25 Martin Sebor <msebor@redhat.com>
773 * c-attribs.c (handle_patchable_function_entry_attribute): Avoid
776 2020-11-24 Martin Sebor <msebor@redhat.com>
778 * c-warn.c (warn_parm_array_mismatch): Avoid invalid redeclarations.
780 2020-11-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
782 * c-attribs.c (handle_special_var_sec_attribute): New.
783 (handle_noinit_attribute): Remove.
784 (attr_noinit_exclusions): Rename to...
785 (attr_section_exclusions): ...this, and add "persistent" attribute
787 (c_common_attribute_table): Add "persistent" attribute.
789 2020-11-21 Aaron Sawdey <acsawdey@linux.ibm.com>
791 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
792 Treat opaque types like other types.
793 (c_pretty_printer::direct_abstract_declarator): Opaque types are
796 2020-11-20 Martin Sebor <msebor@redhat.com>
798 * c-warn.c (warn_parm_array_mismatch): Bail on invalid redeclarations
799 with fewer arguments.
801 2020-11-20 Martin Sebor <msebor@redhat.com>
804 * c-attribs.c (handle_access_attribute): Handle ATTR_FLAG_INTERNAL.
805 Error out on invalid modes.
807 2020-11-20 Jakub Jelinek <jakub@redhat.com>
810 * c-common.c (check_builtin_function_arguments): Handle
811 BUILT_IN_CLEAR_PADDING.
813 2020-11-18 Nathan Sidwell <nathan@acm.org>
815 * c-lex.c (c_lex_with_flags): CPP_HEADER_NAMEs can now be seen.
817 2020-11-17 Nathan Sidwell <nathan@acm.org>
819 * c-common.h (enum c_tree_index): Reorder to place lazy fields
820 after newly-added CTI_MODULE_HWM.
822 2020-11-17 Joseph Myers <joseph@codesourcery.com>
824 * c-cppbuiltin.c (builtin_define_float_constants): Define
825 "*_IS_IEC_60559__" macros.
827 2020-11-17 Nathan Sidwell <nathan@acm.org>
829 * c-lex.c: #include "langhooks.h".
830 (cb_undef): Maybe call preprocess_undef lang hook.
831 * c-opts.c (c_common_post_options): Maybe call preprocess_options
833 (push_command_line_include): Maybe call preprocess_main_file lang
835 (cb_file_change): Likewise.
836 * c-ppoutput.c: #include "langhooks.h.
837 (scan_translation_unit): Maybe call preprocess_token lang hook.
838 (class do_streamer): New, derive from token_streamer.
839 (directives_only_cb): Data pointer is do_streamer, call
840 preprocess_token lang hook.
841 (scan_translation_unit_directives_only): Use do_streamer.
842 (print_line_1): Move src_line recording to after string output.
843 (cb_undef): Maybe call preprocess_undef lang hook.
845 2020-11-17 Nathan Sidwell <nathan@acm.org>
847 * c-ppoutput.c (scan_translation_unit): Use token_streamer, remove
848 code duplicating that functionality.
850 2020-11-17 Jakub Jelinek <jakub@redhat.com>
853 * c-common.c (check_builtin_function_arguments)
854 <case BUILT_IN_ADD_OVERFLOW>: Diagnose when last argument is pointer
855 to _Atomic. For the TYPE_READONLY case, adjust message to be usable
856 for more builtins and argument positions.
858 2020-11-16 Iain Sandoe <iain@sandoe.co.uk>
861 * stub-objc.c: Include c-common.h to declare enum rid.
863 2020-11-13 Jakub Jelinek <jakub@redhat.com>
866 * c-cppbuiltin.c: Include configargs.h.
867 (c_cpp_builtins): For C++11 and later if THREAD_MODEL_SPEC is not
868 defined, predefine __STDCPP_THREADS__ to 1 unless thread_model is
871 2020-11-13 Gergö Barany <gergo@codesourcery.com>
872 Thomas Schwinge <thomas@codesourcery.com>
874 * c.opt (fopenacc-kernels): Add.
876 2020-11-13 Jason Merrill <jason@redhat.com>
878 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_using_enum.
880 2020-11-13 Piotr H. Dabrowski <phd@phd.re>
883 * c-cppbuiltin.c: c_cpp_builtins_optimize_pragma(): use cpp_define_unused()
885 2020-11-13 Martin Liska <mliska@suse.cz>
887 * c-attribs.c (build_attr_access_from_parms): Format properly.
889 2020-11-13 Iain Sandoe <iain@sandoe.co.uk>
892 * c-common.c (c_common_reswords): null_unspecified, nullable,
893 nonnull, null_resettable: New keywords.
894 * c-common.h (enum rid): RID_NULL_UNSPECIFIED, RID_NULLABLE,
895 RID_NONNULL, RID_NULL_RESETTABLE: New.
896 (OBJC_IS_PATTR_KEYWORD): Include nullability keywords in the
897 ranges accepted for property attributes.
898 * c-attribs.c (handle_objc_nullability_attribute): New.
899 * c-objc.h (enum objc_property_attribute_group): Add
900 OBJC_PROPATTR_GROUP_NULLABLE.
901 (enum objc_property_attribute_kind):Add
902 OBJC_PROPERTY_ATTR_NULL_UNSPECIFIED, OBJC_PROPERTY_ATTR_NULLABLE,
903 OBJC_PROPERTY_ATTR_NONNULL, OBJC_PROPERTY_ATTR_NULL_RESETTABLE.
905 2020-11-13 Iain Sandoe <iain@sandoe.co.uk>
908 * c-attribs.c (handle_objc_root_class_attribute): New
909 * c-objc.h (objc_start_class_interface): Add a location
910 value for the position of the class name.
911 * c.opt: Add Wobjc-root-class.
912 * stub-objc.c (objc_start_class_interface): Add a location
913 value for the position of the class name.
915 2020-11-12 Joseph Myers <joseph@codesourcery.com>
917 * c-lex.c (c_common_has_attribute): Take argument std_syntax.
918 Allow scope for C. Handle standard attributes for C. Do not
919 accept unscoped attributes if std_syntax and not handled as
921 * c-common.h (c_common_has_attribute): Update prototype.
923 2020-11-12 Nicholas Guriev <guriev-ns@ya.ru>
926 * c-pch.c (c_common_valid_pch): Use cpp_warning with CPP_W_INVALID_PCH
927 reason to fix -Werror=invalid-pch and -Wno-error=invalid-pch switches.
929 2020-11-11 Patrick Palka <ppalka@redhat.com>
932 * c-opts.c (c_common_post_options): Update latest_abi_version.
934 2020-11-10 Jakub Jelinek <jakub@redhat.com>
937 * c-common.h (warn_if_unused_value): Add quiet argument defaulted
939 * c-warn.c (warn_if_unused_value): Likewise. Pass it down
940 recursively and just return true instead of warning if it is true.
943 2020-11-10 Chung-Lin Tang <cltang@codesourcery.com>
945 * c-common.h (c_omp_adjust_map_clauses): New declaration.
946 * c-omp.c (struct map_clause): Helper type for c_omp_adjust_map_clauses.
947 (c_omp_adjust_map_clauses): New function.
949 2020-11-09 Marek Polacek <polacek@redhat.com>
952 * c-common.c (attribute_fallthrough_p): Tweak the warning
955 2020-11-09 Patrick Palka <ppalka@redhat.com>
957 * c-pragma.c (handle_pragma_diagnostic): Split the
958 unknown-option -Wpragmas diagnostic into a warning and a
959 subsequent note containing a spelling suggestion. Avoid
960 computing the suggestion if -Wpragmas warnings are being
963 2020-11-09 Patrick Palka <ppalka@redhat.com>
966 * c-indentation.c (get_visual_column): Remove location_t
967 parameter. Move the column-tracking diagnostic code from here
969 (should_warn_for_misleading_indentation): ... here, before the
970 early exit for when the loci are not all distinct. Don't pass a
971 location_t argument to get_visual_column.
972 (assert_get_visual_column_succeeds): Don't pass a location_t
973 argument to get_visual_column.
974 (assert_get_visual_column_fails): Likewise.
976 2020-11-08 Iain Sandoe <iain@sandoe.co.uk>
978 * c-common.h (OBJC_IS_PATTR_KEYWORD): Add class to the list
979 of keywords accepted in @property attribute contexts.
980 * c-objc.h (enum objc_property_attribute_group): Add
981 OBJC_PROPATTR_GROUP_CLASS.
982 (enum objc_property_attribute_kind): Add
983 OBJC_PROPERTY_ATTR_CLASS.
985 2020-11-07 Iain Sandoe <iain@sandoe.co.uk>
987 * c-common.c (c_common_reswords): Add 'atomic' property
989 * c-common.h (enum rid): Add RID_PROPATOMIC for atomic
992 2020-11-07 Iain Sandoe <iain@sandoe.co.uk>
994 * c-attribs.c (handle_nsobject_attribute): New.
995 * c.opt: Add WNSObject-attribute.
997 2020-11-06 Iain Sandoe <iain@sandoe.co.uk>
999 * c-objc.h (enum objc_property_attribute_group): New
1000 (enum objc_property_attribute_kind): New.
1001 (OBJC_PROPATTR_GROUP_MASK): New.
1002 (struct property_attribute_info): Small class encapsulating
1003 parser output from property attributes.
1004 (objc_prop_attr_kind_for_rid): New
1005 (objc_add_property_declaration): Simplify interface.
1006 * stub-objc.c (enum rid): Dummy type.
1007 (objc_add_property_declaration): Simplify interface.
1008 (objc_prop_attr_kind_for_rid): New.
1010 2020-11-06 Nathan Sidwell <nathan@acm.org>
1012 * c-ada-spec.c (collect_ada_nodes): Rename
1013 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
1014 (collect_ada_node): Likewise.
1015 (dump_forward_type): Likewise.
1016 * c-common.c (set_underlying_type): Rename
1017 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
1018 (user_facing_original_type, c_common_finalize_early_debug): Likewise.
1020 2020-11-06 Jakub Jelinek <jakub@redhat.com>
1022 * c-common.c (verify_sequence_points): Remove DEBUG_FUNCTION.
1024 2020-11-05 Marek Polacek <polacek@redhat.com>
1027 * c.opt (Wexceptions): New option.
1029 2020-11-05 Marek Polacek <polacek@redhat.com>
1032 * c.opt (Wvexing-parse): New option.
1034 2020-11-04 Jakub Jelinek <jakub@redhat.com>
1037 * c-omp.c (c_omp_split_clauses): Look through array reductions to find
1038 underlying decl to clear in the allocate_head bitmap.
1040 2020-11-04 Iain Sandoe <iain@sandoe.co.uk>
1042 * c-objc.h (objc_non_constant_expr_p): New.
1043 * stub-objc.c (objc_non_constant_expr_p): New.
1045 2020-11-03 Nathan Sidwell <nathan@acm.org>
1047 * c.opt (MQ,MT): Reword description to be make-agnostic.
1049 2020-11-02 Nathan Sidwell <nathan@acm.org>
1051 * c-opts.c (c_common_post_options): Move var decl to its
1052 initialization point.
1054 2020-11-01 Iain Sandoe <iain@sandoe.co.uk>
1056 * c-lex.c (c_lex_with_flags): When combining '@' with a
1057 keyword for Objective-C, combine the location ranges too.
1059 2020-10-30 Qing Zhao <qing.zhao@oracle.com>
1060 H.J.Lu <hjl.tools@gmail.com>
1062 * c-attribs.c (c_common_attribute_table): Add new attribute
1063 zero_call_used_regs.
1064 (handle_zero_call_used_regs_attribute): New function.
1066 2020-10-28 Marek Polacek <polacek@redhat.com>
1069 * c-opts.c (c_common_post_options): In C++20, turn on
1070 -Wdeprecated-enum-enum-conversion and
1071 -Wdeprecated-enum-float-conversion.
1072 * c.opt (Wdeprecated-enum-enum-conversion,
1073 Wdeprecated-enum-float-conversion): New options.
1074 (Wenum-conversion): Allow for C++ too.
1076 2020-10-28 Jakub Jelinek <jakub@redhat.com>
1078 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALLOCATE.
1079 * c-omp.c: Include bitmap.h.
1080 (c_omp_split_clauses): Handle OMP_CLAUSE_ALLOCATE.
1082 2020-10-26 Ville Voutilainen <ville.voutilainen@gmail.com>
1084 * c-common.c (__is_nothrow_assignable): New.
1085 (__is_nothrow_constructible): Likewise.
1086 * c-common.h (RID_IS_NOTHROW_ASSIGNABLE): New.
1087 (RID_IS_NOTHROW_CONSTRUCTIBLE): Likewise.
1089 2020-10-23 Jan Hubicka <hubicka@ucw.cz>
1091 * c-common.c (c_common_finalize_early_debug): Update for new thunk api.
1093 2020-10-23 Marek Polacek <polacek@redhat.com>
1096 * c-common.c (verify_tree): Handle PAREN_SIZEOF_EXPR.
1097 (c_common_init_ts): Likewise.
1098 * c-common.def (PAREN_SIZEOF_EXPR): New tree code.
1099 * c-common.h (maybe_warn_sizeof_array_div): Declare.
1100 * c-warn.c (sizeof_pointer_memaccess_warning): Unwrap NOP_EXPRs.
1101 (maybe_warn_sizeof_array_div): New function.
1102 * c.opt (Wsizeof-array-div): New option.
1104 2020-10-23 Martin Sebor <msebor@redhat.com>
1107 * c-warn.c (warn_parm_ptrarray_mismatch): Move null test earlier.
1109 2020-10-22 Martin Liska <mliska@suse.cz>
1112 * c-attribs.c (handle_no_stack_protect_function_attribute): New.
1113 (handle_stack_protect_attribute): Add error message for a
1114 no_stack_protector function.
1116 2020-10-22 Martin Liska <mliska@suse.cz>
1118 * c-cppbuiltin.c (c_cpp_builtins): Use the stack_protector enum.
1120 2020-10-22 Jan Hubicka <hubicka@ucw.cz>
1122 * c-gimplify.c: Include tree-nested.h
1123 (c_genericize): Update for new nested function info.
1125 2020-10-14 Martin Sebor <msebor@redhat.com>
1128 * c-attribs.c (build_attr_access_from_parms): Wrap chain of VLA
1129 bounds in an extra list.
1131 2020-10-05 Richard Biener <rguenther@suse.de>
1132 Jakub Jelinek <jakub@redhat.com>
1135 * c-pretty-print.c: Include langhooks.h.
1136 (c_pretty_printer::postfix_expression): Handle TARGET_MEM_REF as
1138 (c_pretty_printer::expression): Handle TARGET_MEM_REF as
1140 (c_pretty_printer::unary_expression): Handle TARGET_MEM_REF.
1142 2020-09-30 Martin Sebor <msebor@redhat.com>
1145 * c-attribs.c (append_access_attr): Use the function declaration
1146 location for a warning about an attribute access argument.
1148 2020-09-29 Marek Polacek <polacek@redhat.com>
1151 * c.opt (Wrange-loop-construct): New option.
1153 2020-09-23 Martin Sebor <msebor@redhat.com>
1156 * c-warn.c (warn_parm_ptrarray_mismatch): Handle more invalid input.
1158 2020-09-23 Marek Polacek <polacek@redhat.com>
1161 * c-gimplify.c (c_genericize): Only call do_warn_duplicated_branches_r
1162 after loops and other structured control constructs have been lowered.
1164 2020-09-22 Jakub Jelinek <jakub@redhat.com>
1166 * c.opt (Wbuiltin-declaration-mismatch): Fix typo in variable name:
1167 warn_builtin_declaraion_mismatch -> warn_builtin_declaration_mismatch.
1169 2020-09-21 Marek Polacek <polacek@redhat.com>
1171 * c.opt (Wctad-maybe-unsupported): New option.
1173 2020-09-19 Martin Sebor <msebor@redhat.com>
1176 * c-common.h (warn_parm_array_mismatch): Declare new function.
1177 (has_attribute): Move declaration of an existing function.
1178 (build_attr_access_from_parms): Declare new function.
1179 * c-warn.c (parm_array_as_string): Define new function.
1180 (plus_one): Define new function.
1181 (warn_parm_ptrarray_mismatch): Define new function.
1182 (warn_parm_array_mismatch): Define new function.
1183 (vla_bound_parm_decl): New function.
1184 * c.opt (-Warray-parameter, -Wvla-parameter): New options.
1185 * c-pretty-print.c (pp_c_type_qualifier_list): Don't print array type
1187 (c_pretty_printer::direct_abstract_declarator): ...but instead print
1188 them in brackets here. Also print [static]. Strip extraneous
1189 expressions from VLA bounds.
1191 2020-09-19 Martin Sebor <msebor@redhat.com>
1194 * c-attribs.c (c_common_attribute_table): Add "arg spec" attribute.
1195 (handle_argspec_attribute): New function.
1196 (get_argument, get_argument_type): New functions.
1197 (append_access_attrs): Add overload. Handle internal attribute
1198 representation in addition to external.
1199 (handle_access_attribute): Handle internal attribute representation
1200 in addition to external.
1201 (build_attr_access_from_parms): New function.
1203 2020-09-19 Sandra Loosemore <sandra@codesourcery.com>
1205 * c-gimplify.c (genericize_c_loop): Rewrite to match
1206 c_finish_loop in c-typeck.c.
1208 2020-09-19 Sandra Loosemore <sandra@codesourcery.com>
1210 * c-common.c (c_block_may_fallthrough): New, split from
1211 cxx_block_may_fallthrough in the cp front end.
1212 (c_common_init_ts): Move handling of loop and switch-related
1213 statements here from the cp front end.
1214 * c-common.def (FOR_STMT, WHILE_STMT, DO_STMT): Move here from
1216 (BREAK_STMT, CONTINUE_STMT, SWITCH_STMT): Likewise.
1217 * c-common.h (c_block_may_fallthru): Declare.
1218 (bc_state_t): Move here from cp front end.
1219 (save_bc_state, restore_bc_state): Declare.
1220 (c_genericize_control_stmt): Declare.
1221 (WHILE_COND, WHILE_BODY): Likewise.
1222 (DO_COND, DO_BODY): Likewise.
1223 (FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY, FOR_SCOPE): Likewise.
1224 (SWITCH_STMT_COND, SWITCH_STMT_BODY): Likewise.
1225 (SWITCH_STMT_TYPE, SWITCH_STMT_SCOPE): Likewise.
1226 (SWITCH_STMT_ALL_CASES_P, SWITCH_STMT_NO_BREAK_P): Likewise.
1227 (LABEL_DECL_BREAK, LABEL_DECL_CONTINUE): Likewise.
1228 * c-dump.c (dump_stmt): Copy from cp front end.
1229 (c_dump_tree): Move code to handle structured loop and switch
1230 tree nodes here from cp front end.
1231 * c-gimplify.c: Adjust includes.
1232 (enum bc_t, bc_label, begin_bc_block, finish_bc_block): Move from
1234 (save_bc_state, restore_bc_state): New functions using old code
1236 (get_bc_label, expr_loc_or_loc): Move from cp front end.
1237 (genericize_c_loop): Move from cp front end.
1238 (genericize_for_stmt, genericize_while_stmt): Likewise.
1239 (genericize_do_stmt, genericize_switch_stmt): Likewise.
1240 (genericize_continue_stmt, genericize_break_stmt): Likewise.
1241 (genericize_omp_for_stmt): Likewise.
1242 (c_genericize_control_stmt): New function using code split from
1244 (c_genericize_control_r): New.
1245 (c_genericize): Call walk_tree with c_genericize_control_r.
1246 * c-pretty-print.c (c_pretty_printer::statement): Move code to handle
1247 structured loop and switch tree nodes here from cp front end.
1249 2020-09-17 Patrick Palka <ppalka@redhat.com>
1252 * c-indentation.c (should_warn_for_misleading_indentation): Move
1253 declarations of local variables closer to their first use.
1254 Handle virtual token locations by resolving them to their
1255 respective macro expansion points. If all three tokens are
1256 produced from the same macro expansion, then instead use their
1257 loci within the macro definition.
1259 2020-09-16 Martin Sebor <msebor@redhat.com>
1263 * c-attribs.c (validate_attr_args): New function.
1264 (validate_attr_arg): Same.
1265 (handle_section_attribute): Call it. Introduce a local variable.
1266 (handle_alloc_size_attribute): Same.
1267 (handle_alloc_align_attribute): Same.
1269 2020-09-14 Jakub Jelinek <jakub@redhat.com>
1271 * c-attribs.c (handle_optimize_attribute): Adjust
1272 cl_optimization_save, cl_optimization_restore and
1273 build_optimization_node callers.
1274 * c-pragma.c (handle_pragma_optimize): Adjust
1275 build_optimization_node caller.
1276 (handle_pragma_push_options): Adjust
1277 build_optimization_node and build_target_option_node callers.
1278 (handle_pragma_pop_options, handle_pragma_reset_options):
1279 Adjust cl_optimization_restore callers.
1281 2020-08-28 Martin Sebor <msebor@redhat.com>
1283 * c.opt (Wstringop-overread): New option.
1285 2020-08-11 Jakub Jelinek <jakub@redhat.com>
1288 * c-common.c (get_atomic_generic_size): Require that first argument's
1289 type points to a complete type and use tree_fits_uhwi_p instead of
1290 just INTEGER_CST TREE_CODE check for the TYPE_SIZE_UNIT.
1292 2020-07-31 Martin Sebor <msebor@redhat.com>
1295 * c-common.c (check_function_arguments_recurse): Return early when
1296 no-warning bit is set.
1298 2020-07-31 Richard Biener <rguenther@suse.de>
1301 * c-common.h (c_common_finalize_early_debug): Declare.
1302 * c-common.c: Include debug.h.
1303 (c_common_finalize_early_debug): finalize_early_debug langhook
1304 implementation generating debug for extern declarations.
1306 2020-07-27 Nathan Sidwell <nathan@acm.org>
1308 * c-common.c (try_to_locate_new_include_insertion_point): Use
1309 strcmp, not pointer equality.
1311 2020-07-25 Martin Sebor <msebor@redhat.com>
1314 * c-common.c (check_nonnull_arg): Print note only when warning was
1317 2020-07-22 Tobias Burnus <tobias@codesourcery.com>
1319 * c-omp.c (c_finish_omp_critical): Check for no name but
1320 nonzero hint provided.
1322 2020-07-20 Jason Merrill <jason@redhat.com>
1324 * c-cppbuiltin.c (c_cpp_builtins): Update
1325 __cpp_nontype_template_args for C++20.
1327 2020-07-20 Martin Sebor <msebor@redhat.com>
1330 * c.opt: Remove stray text.
1332 2020-07-14 Lewis Hyatt <lhyatt@gmail.com>
1335 * c-indentation.c (should_warn_for_misleading_indentation): Get
1336 global tabstop from the new source.
1337 * c-opts.c (c_common_handle_option): Remove handling of -ftabstop, which
1338 is now a common option.
1341 2020-07-08 Eric Botcazou <ebotcazou@adacore.com>
1343 * c.opt (Wscalar-storage-order): Add explicit variable.
1345 2020-07-07 Nathan Sidwell <nathan@acm.org>
1347 * c-opts.c (c_common_post_options): Add 'injecting' arg to
1349 (c_finish_options): Add linemap_line_start calls for builtin and cmd
1350 maps. Force token position to line_table's highest line.
1351 * c-ppoutput.c (print_line_1): Refactor, print line zero.
1352 (cb_define): Always increment source line.
1354 2020-07-06 Martin Sebor <msebor@redhat.com>
1357 * c-common.c (check_function_nonnull): Avoid checking syntesized calls
1358 to stub lambda objects with null this pointer.
1359 (check_nonnull_arg): Handle C++ nullptr.
1361 2020-07-02 Jason Merrill <jason@redhat.com>
1362 Jakub Jelinek <jakub@redhat.com>
1364 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_consteval.
1366 2020-06-30 Jakub Jelinek <jakub@redhat.com>
1369 * c-common.c (check_function_arguments_recurse): Don't crash on
1370 calls to internal functions.
1372 2020-06-28 Martin Sebor <msebor@redhat.com>
1375 * c-common.c (struct nonnull_arg_ctx): Add members.
1376 (check_function_nonnull): Use nonnull_arg_ctx as argument. Handle
1377 C++ member functions specially. Consider the this pointer implicitly
1379 (check_nonnull_arg): Use location of argument when available.
1380 (check_function_arguments): Use nonnull_arg_ctx as argument.
1382 2020-06-27 Jakub Jelinek <jakub@redhat.com>
1385 * c-common.c (pointer_int_sum): Use TYPE_OVERFLOW_UNDEFINED instead of
1386 !TYPE_UNSIGNED check to see if we can apply distributive law and handle
1387 smaller precision intop operands separately.
1389 2020-06-26 Marek Polacek <polacek@redhat.com>
1391 * c-opts.c (c_common_init_options): Default to gnu++17.
1393 2020-06-17 Jonathan Wakely <jwakely@redhat.com>
1396 * c-common.c (get_atomic_generic_size): Check cv-qualifiers in
1399 2020-06-16 Jakub Jelinek <jakub@redhat.com>
1401 * c-common.h (c_omp_check_loop_iv_exprs): Add an int argument.
1402 * c-omp.c (struct c_omp_check_loop_iv_data): Add maybe_nonrect and
1404 (c_omp_is_loop_iterator): New function.
1405 (c_omp_check_loop_iv_r): Use it. Add support for silent scanning
1406 if outer loop iterator is present. Perform duplicate checking through
1407 hash_set in the function rather than expecting caller to do that.
1408 Pass NULL instead of d->ppset to walk_tree_1.
1409 (c_omp_check_nonrect_loop_iv): New function.
1410 (c_omp_check_loop_iv): Use it. Fill in new members, allow
1411 non-rectangular loop forms, diagnose multiple associated loops with
1412 the same iterator. Pass NULL instead of &pset to walk_tree_1.
1413 (c_omp_check_loop_iv_exprs): Likewise.
1415 2020-06-10 Martin Liska <mliska@suse.cz>
1417 PR tree-optimization/92860
1418 * c-attribs.c (handle_optimize_attribute):
1419 Save global options and compare it after parsing of function
1421 * c-pragma.c (opt_stack::saved_global_options): New field.
1422 (handle_pragma_push_options): Save global_options.
1423 (handle_pragma_pop_options): Compare them after pop.
1425 2020-06-09 Jakub Jelinek <jakub@redhat.com>
1428 * c-pretty-print.c (c_pretty_printer::unary_expression): Handle the
1429 case when MEM_REF's first argument has type pointer to incomplete type.
1431 2020-06-05 Jason Merrill <jason@redhat.com>
1433 * c-pretty-print.c (pp_c_additive_expression): Handle negative
1434 operand to POINTER_PLUS_EXPR.
1436 2020-06-04 Martin Sebor <msebor@redhat.com>
1440 * c-attribs.c (append_access_attrs): Handle attr_access::none.
1441 (handle_access_attribute): Same.
1443 2020-06-03 Mark Wielaard <mark@klomp.org>
1445 * known-headers.cc (get_cp_stdlib_header_for_string_macro_name):
1447 * known-headers.h (get_cp_stdlib_header_for_string_macro_name):
1448 New function declaration.
1450 2020-06-03 Mark Wielaard <mark@klomp.org>
1452 * known-headers.cc (get_string_macro_hint): New function.
1453 (get_stdlib_header_for_name): Use get_string_macro_hint.
1454 (get_c_stdlib_header_for_string_macro_name): New function.
1455 * known-headers.h (get_c_stdlib_header_for_string_macro_name):
1456 New function declaration.
1458 2020-06-03 Tobias Burnus <tobias@codesourcery.com>
1460 * c-common.h (c_omp_predetermined_mapping): Declare.
1461 * c-omp.c (c_omp_predetermined_mapping): New.
1463 2020-05-22 Mark Wielaard <mark@klomp.org>
1465 * known-headers.cc (get_stdlib_header_for_name): Add a new
1466 stdlib_hint array for stdbool and stdint.
1468 2020-05-22 Mark Wielaard <mark@klomp.org>
1470 * known-headers.cc (get_stdlib_header_for_name): Return
1471 "<stdbool.h>" for "bool", "true" or "false" when STDLIB_C and
1474 2020-05-20 Nathan Sidwell <nathan@acm.org>
1476 * c-common.c (try_to_locate_new_include_insertion_point): Revert change.
1478 * c-common.c (try_to_locate_new_include_insertion_point): Use
1479 strcmp to compare filenames.
1480 * c-lex.c (init_c_lex): Move declaration to initialization.
1481 * c-opts.c (handle_deferred_opts): Move cpp_get_deps call into
1482 deferred count loop.
1484 2020-05-15 Jason Merrill <jason@redhat.com>
1486 * c-opts.c (set_std_cxx20): Set flag_coroutines.
1488 2020-05-13 Jason Merrill <jason@redhat.com>
1490 * c.opt (std=c++20): Make c++2a the alias.
1491 (std=gnu++20): Likewise.
1492 * c-common.h (cxx_dialect): Change cxx2a to cxx20.
1494 * c-cppbuiltin.c: Adjust.
1495 * c-ubsan.c: Adjust.
1498 2020-05-12 Eric Botcazou <ebotcazou@adacore.com>
1500 * c-ada-spec.c (dump_ads): Output pragma Warnings ("U"); on entry.
1502 2020-05-08 Nathan Sidwell <nathan@acm.org>
1504 Reimplement directives only processing.
1505 * c-ppoutput.c (token_streamer): Ne.
1506 (directives_only_cb): New. Swallow ...
1507 (print_lines_directives_only): ... this.
1508 (scan_translation_unit_directives_only): Reimplment using the
1509 published interface.
1511 2020-05-07 Marek Polacek <polacek@redhat.com>
1513 * c-format.c (badwords): Add "nonstatic".
1515 202-05-07 Jakub Jelinek <jakub@redhat.com>
1518 * c-common.c (speculation_safe_value_resolve_params): Return false if
1519 error_operand_p (val2).
1520 (resolve_overloaded_builtin) <case BUILT_IN_SPECULATION_SAFE_VALUE_N>:
1521 Remove extraneous semicolon.
1523 2020-05-06 qing zhao <qing.zhao@oracle.com>
1526 * c-indentation.c (get_visual_column): Add a hint to use the new
1527 -flarge-source-files option.
1529 2020-05-05 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
1531 * c-attribs.c (handle_vector_size_attribute): Add attribute
1532 nonnull for argument args in order to silence warning of
1533 uninitialized variable usage. Since this is local to the
1534 compilation unit and thus cannot be checked at call sides by the
1535 compiler, added an assert statement in order to verify this.
1537 2020-05-01 H.J. Lu <hongjiu.lu@intel.com>
1540 * c-attribs.c (handle_patchable_function_entry_attribute): Limit
1541 value to USHRT_MAX (65535).
1543 2020-04-29 Jakub Jelinek <jakub@redhat.com>
1545 * c-format.c (PP_FORMAT_CHAR_TABLE): Add %{ and %}.
1547 2020-04-27 Jakub Jelinek <jakub@redhat.com>
1550 * c-common.c (resolve_overloaded_builtin): Return error_mark_node for
1551 fncode == BUILT_IN_NONE before initialization of first_param.
1553 2020-04-23 Marek Polacek <polacek@redhat.com>
1556 * c-attribs.c (find_tm_attribute): Use get_attribute_name instead of
1559 2020-04-14 Patrick Palka <ppalka@redhat.com>
1562 * c-pretty-print.c (pp_c_pointer) <case REFERENCE_TYPE>: Print a double
1563 ampersand if it's an rvalue reference type.
1565 2020-04-13 Martin Sebor <msebor@redhat.com>
1568 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator): Avoid
1569 printing array bound for flexible array members.
1571 2020-04-13 Iain Sandoe <iain@sandoe.co.uk>
1573 * c-cppbuiltin.c (c_cpp_builtins): Update coroutines builtin
1576 2020-04-02 Richard Biener <rguenther@suse.de>
1579 * c-opts.c (c_common_post_options): Enable -ffinite-loops
1580 for -O2 and C++11 or newer.
1582 2020-03-28 Patrick Palka <ppalka@redhat.com>
1584 * c.opt: Add -fconcepts-diagnostics-depth.
1586 2020-03-27 Martin Sebor <msebor@redhat.com>
1589 * c-attribs.c (handle_copy_attribute): Avoid passing expressions
1590 to decl_attributes. Make handling of different kinds of entities
1593 2020-03-27 Martin Sebor <msebor@redhat.com>
1596 * c-attribs.c (handle_access_attribute): Avoid setting TYPE_ATTRIBUTES
1599 2020-03-23 Jakub Jelinek <jakub@redhat.com>
1602 * c-warn.c (warnings_for_convert_and_check): For expr and/or
1603 result being COMPOUND_EXPRs, skip to ultimate rhs.
1605 2020-03-20 Richard Sandiford <richard.sandiford@arm.com>
1608 * c-common.c (c_common_type_for_mode): Before using a registered
1609 built-in type, check that the vectorness of the type matches
1610 the vectorness of the mode.
1612 2020-03-17 Jakub Jelinek <jakub@redhat.com>
1614 * c-common.c (resolve_overloaded_builtin): Fix up duplicated word
1615 issue in a diagnostic message.
1617 2020-03-15 Lewis Hyatt <lhyatt@gmail.com>
1619 * c.opt: Avoid redundancy in the help text.
1621 2020-03-02 Marek Polacek <polacek@redhat.com>
1623 PR c++/93958 - add missing -std=gnu++20.
1624 * c.opt: Add -std=gnu++20.
1626 2020-03-01 Martin Sebor <msebor@redhat.com>
1629 * c-attribs.c (append_access_attrs): Correctly handle attribute.
1630 (handle_access_attribute): Same.
1632 2020-02-25 Jakub Jelinek <jakub@redhat.com>
1635 * c-pragma.c (handle_pragma_diagnostic): Add missing ? after
1636 "did you mean" hint in diagnostics.
1638 2020-02-15 Jason Merrill <jason@redhat.com>
1640 * c.opt: Add -std=c++20.
1642 2020-02-14 Eric Botcazou <ebotcazou@adacore.com>
1644 * c-ada-spec.c: Include bitmap.h.
1645 (dump_ada_double_name): Rename into...
1646 (dump_anonymous_type_name): ...this. Always use the TYPE_UID.
1647 (dump_ada_array_type): Adjust to above renaming. Robustify.
1648 (dump_nested_types_1): New function copied from... Add dumped_types
1649 parameter and pass it down to dump_nested_type.
1650 (dump_nested_types): ...this. Remove parent parameter. Just call
1651 dump_nested_types_1 on an automatic bitmap.
1652 (dump_nested_type): Add dumped_types parameter.
1653 <ARRAY_TYPE>: Do not dump it if already present in dumped_types.
1654 Adjust recursive calls and adjust to above renaming.
1655 (dump_ada_declaration): Adjust call to dump_nested_types.
1656 Tidy up and adjust to above renaming.
1657 (dump_ada_specs): Initialize and release bitmap obstack.
1659 2020-02-10 Martin Sebor <msebor@redhat.com>
1662 * c-attribs.c (handle_access_attribute): Correct off-by-one mistakes.
1664 2020-02-10 Jakub Jelinek <jakub@redhat.com>
1667 * c-format.c (check_plain): Fix up last argument of strncasecmp.
1668 Remove useless extra test.
1670 2020-02-03 Julian Brown <julian@codesourcery.com>
1671 Tobias Burnus <tobias@codesourcery.com>
1673 * c-cppbuiltin.c (c_cpp_builtins): Update _OPENACC define to 201711.
1675 2020-01-29 Jason Merrill <jason@redhat.com>
1678 * c-attribs.c (check_cxx_fundamental_alignment_constraints): Remove.
1680 2020-01-23 Jason Merrill <jason@redhat.com>
1682 * c-warn.c (conversion_warning): Change -Wsign-conversion handling.
1684 2020-01-23 Martin Sebor <msebor@redhat.com>
1687 * c-common.c (check_function_arguments): Avoid overlap checking
1688 of sprintf functions.
1690 2020-01-22 Jason Merrill <jason@redhat.com>
1692 PR testsuite/93391 - PR 40752 test fails with unsigned plain char.
1694 * c-warn.c (conversion_warning): Check operands only after checking
1695 the whole expression. Don't check second operand of + for sign.
1697 2020-01-21 Jason Merrill <jason@redhat.com>
1698 Manuel López-Ibáñez <manu@gcc.gnu.org>
1700 PR c++/40752 - useless -Wconversion with short +=.
1701 * c.opt (-Warith-conversion): New.
1702 * c-warn.c (conversion_warning): Recurse for operands of
1703 operators. Only warn about the whole expression with
1706 2020-01-21 Jason Merrill <jason@redhat.com>
1708 * c-common.c (unsafe_conversion_p): Don't warn, return UNSAFE_SIGN.
1709 * c-warn.c (conversion_warning): Warn about UNSAFE_SIGN.
1711 2020-01-20 Nathan Sidwell <nathan@acm.org>
1713 PR preprocessor/80005
1714 * c-cppbuiltins.c (c_cpp_builtins): Don't define __has_include{,_next}.
1716 2020-01-18 Iain Sandoe <iain@sandoe.co.uk>
1718 * c-common.c (co_await, co_yield, co_return): New.
1719 * c-common.h (RID_CO_AWAIT, RID_CO_YIELD,
1720 RID_CO_RETURN): New enumeration values.
1721 (D_CXX_COROUTINES): Bit to identify coroutines are active.
1722 (D_CXX_COROUTINES_FLAGS): Guard for coroutine keywords.
1723 * c-cppbuiltin.c (__cpp_coroutines): New cpp define.
1724 * c.opt (fcoroutines): New command-line switch.
1726 2020-01-10 David Malcolm <dmalcolm@redhat.com>
1728 * c-format.c (local_event_ptr_node): New.
1729 (PP_FORMAT_CHAR_TABLE): Add entry for "%@".
1730 (init_dynamic_diag_info): Initialize local_event_ptr_node.
1731 * c-format.h (T_EVENT_PTR): New define.
1733 2020-01-10 Martin Sebor <msebor@redhat.com>
1736 * c-attribs.c (append_access_attrs): Validate against the translated
1737 access string rather than the human-readable representation.
1739 2020-01-01 Jakub Jelinek <jakub@redhat.com>
1741 Update copyright years.
1743 2019-12-20 Eric Botcazou <ebotcazou@adacore.com>
1745 * c-ada-spec.h (decl_sloc): Delete.
1746 * c-ada-spec.c (decl_sloc): Make static.
1748 2019-12-19 Julian Brown <julian@codesourcery.com>
1750 * c-common.h (c_omp_map_clause_name): Add prototype.
1751 * c-omp.c (c_omp_map_clause_name): New function.
1752 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ATTACH and
1753 PRAGMA_OACC_CLAUSE_DETACH.
1755 2019-12-19 Julian Brown <julian@codesourcery.com>
1756 Maciej W. Rozycki <macro@codesourcery.com>
1757 Tobias Burnus <tobias@codesourcery.com>
1758 Thomas Schwinge <thomas@codesourcery.com>
1760 * c-pragma.h (pragma_omp_clause): Add
1761 PRAGMA_OACC_CLAUSE_NO_CREATE.
1763 2019-12-17 Martin Sebor <msebor@redhat.com>
1766 * c.opt (-Wmismatched-tags, -Wredundant-tags): New options.
1768 2019-12-11 David Malcolm <dmalcolm@redhat.com>
1770 * c-pretty-print.c (c_pretty_printer::clone): New vfunc
1772 * c-pretty-print.h (c_pretty_printer::clone): New vfunc decl.
1774 2019-12-09 David Malcolm <dmalcolm@redhat.com>
1776 * c-format.c (range_label_for_format_type_mismatch::get_text):
1777 Replace label_text ctor called with true with label_text::take.
1779 2019-12-09 David Malcolm <dmalcolm@redhat.com>
1781 * c-format.c (selftest::test_type_mismatch_range_labels): Remove
1782 initial newline from expected outputs.
1783 * c-opts.c (c_diagnostic_finalizer): Add pp_newline call before
1784 call to diagnostic_show_locus.
1786 2019-12-06 Jakub Jelinek <jakub@redhat.com>
1788 * c-cppbuiltin.c (c_cpp_builtins): Don't define __cpp_consteval for
1791 2019-12-05 Marek Polacek <polacek@redhat.com>
1792 Jakub Jelinek <jakub@redhat.com>
1794 PR c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.
1795 * c-cppbuiltin.c (c_cpp_builtins): Adjust the value of __cpp_constexpr.
1797 2019-12-05 Marek Polacek <polacek@redhat.com>
1799 PR c++/92271 - make __is_same alias for __is_same_as.
1800 * c-common.c: Add __is_same, an alias for __is_same_as.
1802 2019-12-03 Marek Polacek <polacek@redhat.com>
1804 PR c++/91363 - P0960R3: Parenthesized initialization of aggregates.
1805 * c-cppbuiltin.c (c_cpp_builtins): Predefine
1806 __cpp_aggregate_paren_init=201902 for -std=c++2a.
1808 2019-11-30 Jan Hubicka <hubicka@ucw.cz>
1810 * c-attribs.c (handle_symver_attribute): New function
1811 (c_common_attributes): Add symver.
1813 2019-11-30 Richard Sandiford <richard.sandiford@arm.com>
1815 * c-common.c (pointer_int_sum): Use verify_type_context to check
1816 whether the target allows pointer arithmetic for the types involved.
1817 (c_sizeof_or_alignof_type, c_alignof_expr): Use verify_type_context
1818 to check whether the target allows sizeof and alignof operations
1819 for the types involved.
1821 2019-11-27 Jason Merrill <jason@redhat.com>
1823 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
1825 2019-11-26 Jakub Jelinek <jakub@redhat.com>
1828 * c-attribs.c (handle_mode_attribute): Add mode attribute to
1831 2019-11-25 Joseph Myers <joseph@codesourcery.com>
1834 * c-common.c (c_common_type_for_mode): Handle decimal
1835 floating-point types being NULL_TREE.
1836 * c-format.c (get_format_for_type_1): Handle specified types being
1838 * c-lex.c (interpret_float): Give an error for decimal
1839 floating-point constants when decimal floating-point not
1842 2019-11-23 Jakub Jelinek <jakub@redhat.com>
1845 * c-attribs.c (append_access_attrs): Avoid buffer overflow. Avoid
1846 memory leak. Use XNEWVEC macro. Use auto_diagnostic_group to
1847 group warning with inform together.
1848 (handle_access_attribute): Formatting fix.
1850 2019-11-22 Jakub Jelinek <jakub@redhat.com>
1853 * c-common.h (identifier_global_tag): Declare.
1854 * c-format.c (get_pointer_to_named_type): Renamed to ...
1855 (get_named_type): ... this. Use identifier_global_tag instead of
1856 identifier_global_value, handle the return value being a TYPE_P.
1857 (init_dynamic_diag_info): Adjust get_pointer_to_named_type callers
1858 to call get_named_type instead. Formatting fixes.
1860 Implement P1902R1, Missing feature-test macros 2017-2019.
1861 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_init_captures
1862 and __cpp_generic_lambdas for -std=c++2a. Define
1863 __cpp_designated_initializers, __cpp_constexpr_in_decltype and
1864 __cpp_consteval for -std=c++2a. Remove a FIXME comment about
1865 __cpp_concepts for -std=c++2a.
1867 2019-11-22 Martin Sebor <msebor@redhat.com>
1870 * c-attribs.c (handle_access_attribute): New function.
1871 (c_common_attribute_table): Add new attribute.
1872 (get_argument_type): New function.
1873 (append_access_attrs): New function.
1874 (get_nonnull_operand): Rename...
1875 (get_attribute_operand): ...to this.
1876 * c-common.c (get_nonnull_operand): Rename...
1877 (get_attribute_operand): ...to this.
1879 2019-11-21 Joseph Myers <joseph@codesourcery.com>
1881 * c-attribs.c (handle_fallthrough_attribute): Use pedwarn instead
1884 2019-11-19 Joseph Myers <joseph@codesourcery.com>
1886 * c-common.c (attribute_fallthrough_p): In C, use pedwarn not
1887 warning for standard attributes mixed with fallthrough attributes.
1889 2019-11-15 Joseph Myers <joseph@codesourcery.com>
1891 * c-attribs.c (handle_fallthrough_attribute): Remove static.
1892 * c-common.h (handle_fallthrough_attribute): Declare.
1894 2019-11-15 Joseph Myers <joseph@codesourcery.com>
1896 * c-attribs.c (handle_deprecated_attribute): Remove static.
1897 * c-common.h (handle_deprecated_attribute): Declare.
1899 2019-11-14 Joseph Myers <joseph@codesourcery.com>
1901 * c-lex.c (lex_charconst): Make CPP_UTF8CHAR constants unsigned
1904 2019-11-14 Jakub Jelinek <jakub@redhat.com>
1906 * c-omp.c (c_omp_check_context_selector): Add nvidia to the list of
1909 * c-omp.c (c_omp_check_context_selector): Handle name lists
1910 containing string literals. Don't diagnose atomic_default_mem_order
1911 with multiple props.
1913 2019-11-13 Joseph Myers <joseph@codesourcery.com>
1915 * c-cppbuiltin.c (builtin_define_float_constants): Also define
1916 NORM_MAX constants. Update call to get_max_float.
1917 (LAZY_HEX_FP_VALUES_CNT): Update value to include NORM_MAX
1920 2019-11-13 Eric Botcazou <ebotcazou@adacore.com>
1922 * c-ada-spec.c (get_underlying_decl): Do not look through typedefs.
1923 (dump_forward_type): Do not generate a declaration for function types.
1924 (dump_nested_type) <ARRAY_TYPE>: Do not generate a nested declaration
1925 of the component type if it is declared in another file.
1927 2019-11-12 Martin Liska <mliska@suse.cz>
1929 * c-opts.c (c_common_post_options):
1930 Use SET_OPTION_IF_UNSET.
1932 2019-11-12 Maciej W. Rozycki <macro@codesourcery.com>
1933 Frederik Harwath <frederik@codesourcery.com>
1936 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_SERIAL enumeration
1938 * c-pragma.c (oacc_pragmas): Add "serial" entry.
1940 2019-11-08 Richard Sandiford <richard.sandiford@arm.com>
1942 * c-common.h (gnu_vector_type_p): New function.
1943 * c-common.c (c_build_vec_perm_expr): Require __builtin_shuffle
1944 vectors to satisfy gnu_vector_type_p.
1945 (c_build_vec_convert): Likewise __builtin_convertvector.
1946 (convert_vector_to_array_for_subscript): Likewise when applying
1947 implicit vector to array conversion.
1948 (scalar_to_vector): Likewise when converting vector-scalar
1949 operations to vector-vector operations.
1951 2019-11-08 Joseph Myers <joseph@codesourcery.com>
1953 * c.opt (Wold-style-definition): Initialize to -1.
1954 * c-opts.c (c_common_post_options): Set warn_old_style_definition
1955 to flag_isoc2x if not set explicitly.
1957 2019-11-07 Joseph Myers <joseph@codesourcery.com>
1959 * c-attribs.c (parse_tm_stmt_attr): Handle scoped attributes.
1961 2019-11-05 Jason Merrill <jason@redhat.com>
1963 * c-opts.c (c_common_post_options): -fconcepts-ts implies
1966 2019-11-04 Kamlesh Kumar <kamleshbhalui@gmail.com>
1968 * c-opts.c (c_common_post_options): Update
1971 2019-11-02 Jakub Jelinek <jakub@redhat.com>
1973 * c-common.h (c_omp_get_context_selector): Remove.
1974 * c-omp.c (c_omp_get_context_selector): Moved to omp-general.c
1975 and renamed to omp_get_context_selector.
1977 * c-omp.c (c_omp_mark_declare_variant): Use
1978 omp_context_selector_set_compare.
1980 PR c++/88335 - Implement P1073R3: Immediate functions
1981 * c-common.h (enum rid): Add RID_CONSTEVAL.
1982 * c-common.c (c_common_reswords): Add consteval.
1984 2019-11-01 Martin Sebor <msebor@redhat.com>
1990 * c-pretty-print.c (direct_abstract_declarator): Print
1991 bound in zero-length arrays.
1992 * c.opt (-Wzero-length-bounds): New option.
1994 2019-10-30 Nathan Sidwell <nathan@acm.org>
1996 * c-cppbuiltin.c (c_cpp_builtins): Add 'L' suffix to feature
1999 2019-10-28 Martin Sebor <msebor@redhat.com>
2002 * c-common.c (c_common_nodes_and_builtins): Call c_define_builtins
2003 even when only preprocessing.
2004 * c-common.h (names_builtin_p): Declare new function.
2005 * c-lex.c (init_c_lex): Set has_builtin.
2006 (c_common_has_builtin): Define a new function.
2007 * c-ppoutput.c (init_pp_output): Set has_builtin.
2009 2019-10-24 Jakub Jelinek <jakub@redhat.com>
2011 * c-common.h (c_omp_context_selector_matches): Remove.
2012 * c-omp.c (c_omp_context_selector_matches): Remove.
2013 * c-attribs.c (c_common_attribute_table): Add
2014 "omp declare target {host,nohost,block}" attributes.
2016 2019-10-17 JeanHeyd Meneide <phdofthehouse@gmail.com>
2018 * c-lex.c (c_common_has_attribute): Update nodiscard value.
2020 2019-10-14 Richard Sandiford <richard.sandiford@arm.com>
2022 * c-common.h (user_facing_original_type_p): Declare.
2023 * c-common.c: Include c-spellcheck.h.
2024 (user_facing_original_type_p): New function.
2026 2019-10-12 Jakub Jelinek <jakub@redhat.com>
2028 * c-common.h (c_omp_mark_declare_variant,
2029 c_omp_context_selector_matches): Declare.
2030 * c-omp.c: Include attribs.h, gimplify.h, cgraph.h, symbol-summary.h
2032 (c_omp_get_context_selector): Support second argument NULL.
2033 (c_omp_mark_declare_variant, c_omp_context_selector_matches): New
2035 * c-attribs.c (c_common_attribute_table): Remove "omp declare variant"
2036 attribute, add "omp declare variant base" and
2037 "omp declare variant variant" attributes.
2039 2019-10-11 Joseph Myers <joseph@codesourcery.com>
2041 * c.opt (Wc11-c2x-compat): Add CPP(cpp_warn_c11_c2x_compat)
2042 CppReason(CPP_W_C11_C2X_COMPAT).
2044 2019-10-11 Joseph Myers <joseph@codesourcery.com>
2046 * c-common.c (c_common_reswords): Do not use D_EXT for _Decimal32,
2047 _Decimal64 and _Decimal128.
2049 2019-10-10 Joseph Myers <joseph@codesourcery.com>
2051 * c-cppbuiltin.c (c_cpp_builtins): Do not define macros for DFP
2052 types if DFP not supported.
2054 2019-10-10 Jakub Jelinek <jakub@redhat.com>
2056 * c-common.h (c_omp_check_context_selector,
2057 c_omp_get_context_selector): Declare.
2058 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): Fix spelling
2059 in diagnostic message.
2060 (c_omp_check_context_selector, c_omp_get_context_selector): New
2062 * c-attribs.c (c_common_attribute_table): Add "omp declare variant"
2064 (handle_omp_declare_variant_attribute): New function.
2066 2019-10-09 Martin Sebor <msebor@redhat.com>
2068 PR tree-optimization/90879
2069 * c.opt (-Wstring-compare): New option.
2071 2019-10-08 Andrew Sutton <asutton@lock3software.com>
2072 Jason Merrill <jason@redhat.com>
2074 Update the concepts implementation to conform to the C++20
2075 specification, improve compile times, and generally clean up
2078 * c-cppbuiltin.c (c_cpp_builtins): Use new feature test values for
2079 concepts when -std=c++2a. Bump __cpp_concepts to 201907.
2080 * c.opt: Add -Wconcepts-ts.
2081 * c-opts.c (c_common_post_options): Warn when -fconcepts is used
2082 with -std=c++2a. Disable warning for -fconcepts in C++20 mode.
2083 (set_std_cxx2a): Enable concepts by default.
2085 2019-10-08 Joseph Myers <joseph@codesourcery.com>
2087 * c-opts.c (c_common_post_options): Set
2088 -fno-fp-int-builtin-inexact for C2X.
2090 2019-10-05 Jakub Jelinek <jakub@redhat.com>
2092 PR c++/91369 - Implement P0784R7: constexpr new
2093 * c-cppbuiltin.c (c_cpp_builtins): Predefine
2094 __cpp_constexpr_dynamic_alloc=201907 for -std=c++2a.
2096 2019-10-04 Joseph Myers <joseph@codesourcery.com>
2099 * c-format.c (C_STD_VER): Handle C2x.
2100 (C_STD_NAME): Likewise.
2101 (strftime_flag_specs): Add 'O' modifier with 'p' flag.
2102 (time_char_table): Use separate entry for 'B' and 'b', with 'O'
2103 modifier allowed and 'p' flag.
2104 * c-format.h (enum format_std_version): Add STD_C2X.
2105 (struct format_char_info): Mention 'p' in comment on flags2.
2107 2019-10-01 David Malcolm <dmalcolm@redhat.com>
2109 * c-opts.c (c_diagnostic_finalizer): Temporarily clear prefix when
2110 calling diagnostic_show_locus, rather than destroying it afterwards.
2112 2019-10-01 Jakub Jelinek <jakub@redhat.com>
2115 * c-warn.c (check_alignment_of_packed_member): Ignore FIELD_DECLs
2116 with NULL DECL_FIELD_OFFSET.
2118 2019-10-01 Richard Sandiford <richard.sandiford@arm.com>
2120 * c-pretty-print.c (pp_c_specifier_qualifier_list): If a vector type
2121 has a type name, use it in preference to the __vector syntax.
2123 2019-09-30 Richard Sandiford <richard.sandiford@arm.com>
2125 * c-pretty-print.c (pp_c_parameter_type_list): Avoid printing
2126 two spaces between a comma and "...".
2128 2019-09-27 Jakub Jelinek <jakub@redhat.com>
2131 * c-common.h (c_omp_predefined_variable): Declare.
2132 * c-omp.c (c_omp_predefined_variable): New function.
2133 (c_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
2134 for predefined variables.
2136 2019-09-27 Richard Sandiford <richard.sandiford@arm.com>
2138 * c-common.h (build_function_call_vec): Take the original
2139 function decl as an optional final parameter.
2140 (check_builtin_function_arguments): Take the original function decl.
2141 * c-common.c (check_builtin_function_arguments): Likewise.
2142 Handle all built-in functions, not just BUILT_IN_NORMAL ones.
2143 Use targetm.check_builtin_call to check BUILT_IN_MD functions.
2145 2019-09-15 Jason Merrill <jason@redhat.com>
2147 * c-warn.c (warn_logical_operator): Strip location wrappers. Don't
2148 fold_for_warn in "|| mask" warning.
2150 2019-09-10 Martin Liska <mliska@suse.cz>
2152 * c.opt: Use newly added WarnRemoved.
2154 2019-09-09 Martin Liska <mliska@suse.cz>
2156 * c.opt: Update comment of removed
2157 options that are preserved only for backward
2160 2019-09-06 Martin Liska <mliska@suse.cz>
2163 * c-common.c: Remove definition of flag_use_repository.
2164 * c-common.h: Likewise.
2165 * c-opts.c (c_common_handle_option):
2166 Do not handle OPT_frepo option.
2167 * c.opt: Mark the option with Deprecated.
2169 2019-09-04 Marek Polacek <polacek@redhat.com>
2171 * c.opt (fdeduce-init-list): Ignored.
2173 2019-09-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2176 * c.opt (Wenum-conversion): New option.
2178 2019-09-03 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2180 * c-attribs.c (handle_section_attribute): Call the
2181 handle_generic_attribute target hook after performing target
2182 independent processing.
2183 (handle_noinit_attribute): Likewise.
2185 2019-09-03 Ian Lance Taylor <iant@golang.org>
2187 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Always expand
2188 when using -fgo-dump-spec.
2190 2019-09-02 Martin Liska <mliska@suse.cz>
2193 * c-common.c (fname_as_string): Use cxx_printable_name for
2194 __PRETTY_FUNCTION__ same as was used before r265711.
2196 2019-08-28 Marek Polacek <polacek@redhat.com>
2198 Implement P1152R4: Deprecating some uses of volatile.
2200 * c-opts.c (c_common_post_options): Enable -Wvolatile by
2201 default for C++2a, unless -Wno-deprecated.
2202 * c.opt (Wvolatile): New warning.
2204 2019-08-28 Marek Polacek <polacek@redhat.com>
2206 PR c++/91360 - Implement C++20 P1143R2: constinit.
2207 * c-common.c (c_common_reswords): Add constinit and __constinit.
2208 (keyword_is_decl_specifier): Handle RID_CONSTINIT.
2209 * c-common.h (enum rid): Add RID_CONSTINIT, RID_FIRST_CXX20, and
2212 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_constinit.
2213 * c-format.c (cxx_keywords): Add "constinit".
2214 * c.opt (Wc++2a-compat, Wc++20-compat): New options.
2216 2019-08-27 Jakub Jelinek <jakub@redhat.com>
2219 * c-common.c (verify_tree): For LSHIFT_EXPR, RSHIFT_EXPR,
2220 COMPONENT_REF and ARRAY_REF in cxx_dialect >= cxx17 mode handle it
2221 like COMPOUND_EXPR rather than normal expression.
2223 2019-08-23 Iain Sandoe <iain@sandoe.co.uk>
2226 * c-lex.c (c_lex_with_flags): Don't call
2227 c_common_no_more_pch () from here.
2229 2019-08-23 Jakub Jelinek <jakub@redhat.com>
2232 * c-common.c (c_ts18661_flt_eval_method): Use flag_excess_precision
2233 instead of flag_excess_precision_cmdline.
2234 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): Likewise.
2235 * c-opts.c (c_common_post_options): Likewise.
2237 2019-08-22 Martin Sebor <msebor@redhat.com>
2240 * c-common.c (braced_list_to_string): Add argument and overload.
2241 Handle flexible length arrays and unions.
2243 2019-08-21 Eric Botcazou <ebotcazou@adacore.com>
2245 * c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
2246 function declarations where arguments are missing. Rename variables.
2248 2019-08-15 Richard Biener <rguenther@suse.de>
2250 * c-common.c (c_stddef_cpp_builtins): When the GIMPLE FE is
2251 enabled, define __SIZETYPE__.
2253 2019-08-14 Christophe Lyon <christophe.lyon@linaro.org>
2255 * c-attribs.c (c_common_attribute_table): Add "noinit" entry. Add
2256 exclusion with "section" attribute.
2257 (attr_noinit_exclusions): New table.
2258 (handle_noinit_attribute): New function.
2260 2019-08-13 Richard Sandiford <richard.sandiford@arm.com>
2263 * c-common.c (resolve_overloaded_builtin): Use
2264 copy_decl_built_in_function.
2266 2019-08-13 Martin Sebor <msebor@redhat.com>
2269 * c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
2270 (asm_fprintf_length_spec): Same.
2271 * c-format.h (format_lengths): Add FMT_LEN_w.
2273 2019-08-10 Jakub Jelinek <jakub@redhat.com>
2275 * c-pragma.h (enum pragma_omp_clause): Add
2276 PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
2278 2019-08-07 Jakub Jelinek <jakub@redhat.com>
2280 * c-pragma.h (enum pragma_omp_clause): Add
2281 PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. Set PRAGMA_OACC_CLAUSE_USE_DEVICE
2282 equal to PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR instead of being a separate
2285 2019-08-05 Marek Polacek <polacek@redhat.com>
2287 PR c++/91338 - Implement P1161R3: Deprecate a[b,c].
2288 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
2289 default for C++2a, unless -Wno-deprecated.
2290 * c.opt (Wcomma-subscript): New warning.
2292 2019-07-20 Jakub Jelinek <jakub@redhat.com>
2294 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_LOOP.
2295 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_BIND.
2296 * c-pragma.c (omp_pragmas_simd): Add PRAGMA_OMP_LOOP entry.
2297 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_LOOP.
2298 * c-omp.c (c_omp_split_clauses): Add support for 4 new combined
2299 constructs with the loop construct.
2301 2019-07-13 Jakub Jelinek <jakub@redhat.com>
2304 * c-omp.c (c_omp_split_clauses): Fix a pasto in
2305 OMP_CLAUSE_REDUCTION_TASK handling.
2307 2019-07-12 Jakub Jelinek <jakub@redhat.com>
2309 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ORDER.
2310 * c-omp.c (c_omp_split_clauses): Handle splitting of OMP_CLAUSE_ORDER.
2312 2019-07-09 Martin Sebor <msebor@redhat.com>
2315 * c-opts.c (handle_deferred_opts): Change class-key of PODs to struct
2316 and others to class.
2317 * c-pretty-print.h: Same.
2319 2019-07-09 Martin Sebor <msebor@redhat.com>
2322 * c-format.c (check_argument_type): Change class-key from class to
2323 struct and vice versa to match convention and avoid -Wclass-is-pod
2324 and -Wstruct-no-pod.
2325 * c-pretty-print.h: Same.
2327 2019-07-03 Martin Liska <mliska@suse.cz>
2329 * c-common.c (try_to_locate_new_include_insertion_point): Remove
2332 2019-07-03 Jakub Jelinek <jakub@redhat.com>
2334 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_REDUCTION_INSCAN
2335 clauses on OMP_FOR rather than OMP_PARALLEL when OMP_FOR is combined
2338 2019-07-02 qing zhao <qing.zhao@oracle.com>
2340 PR preprocessor/90581
2341 * c-opts.c (c_common_handle_option): Handle -fmax-include-depth.
2342 * c.opt: Add new option -fmax-include-depth.
2344 2019-06-26 Jason Merrill <jason@redhat.com>
2346 PR c++/55442 - memory-hog with highly recursive constexpr.
2347 * c.opt (fconstexpr-loop-limit): New.
2349 2019-06-25 Jakub Jelinek <jakub@redhat.com>
2352 * c-omp.c (c_finish_omp_atomic): Allow tree_invariant_p in addition
2353 to SAVE_EXPR in first operand of a COMPOUND_EXPR.
2355 2019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2357 * c-common.c (c_common_nodes_and_builtins): Define
2358 alternate "__intN__" name for "__intN" types.
2360 2019-06-24 Jan Hubicka <jh@suse.cz>
2362 * c-common.c (braced_lists_to_strings): Check that
2363 type is array or integer prior checking string flag.
2365 2019-06-21 Matthew Beliveau <mbelivea@redhat.com>
2367 PR c++/90875 - added -Wswitch-outside-range option
2368 * c.opt (Wswitch-outside-range): Added new option.
2369 * c-warn.c (c_do_switch_warnings): Use OPT_Wswitch-outside-range.
2371 2019-06-21 Marek Polacek <polacek@redhat.com>
2373 PR c++/90953 - ICE with -Wmissing-format-attribute.
2374 * c-common.c (check_function_arguments_recurse): Use
2376 (check_missing_format_attribute): Likewise.
2378 2019-06-19 Marek Polacek <polacek@redhat.com>
2380 PR c++/60364 - noreturn after first decl not diagnosed.
2381 * c-attribs.c (handle_noreturn_attribute): No longer static.
2382 * c-common.h (handle_noreturn_attribute, attr_noreturn_exclusions):
2384 * c-format.c (check_function_format): Use get_attribute_name.
2386 2019-06-19 Martin Sebor <msebor@redhat.com>
2388 PR translation/90156
2389 * c-format.c (function_format_info::format_type): Adjust type.
2390 (function_format_info::is_raw): New member.
2391 (decode_format_type): Adjust signature. Handle "raw" diag attributes.
2392 (decode_format_attr): Adjust call to decode_format_type.
2393 Avoid a redundant call to convert_format_name_to_system_name.
2394 Avoid abbreviating the word "arguments" in a diagnostic.
2395 (format_warning_substr): New function.
2396 (avoid_dollar_number): Quote dollar sign in a diagnostic.
2397 (finish_dollar_format_checking): Same.
2398 (check_format_info): Same.
2399 (struct baltoks_t): New.
2400 (c_opers, c_keywords, cxx_keywords, badwords, contrs): New arrays.
2401 (maybe_diag_unbalanced_tokens, check_tokens, check_plain): New
2403 (check_format_info_main): Call check_plain. Use baltoks_t. Call
2404 maybe_diag_unbalanced_tokens.
2405 (handle_format_attribute): Spell out the word "arguments" in
2408 2019-06-11 Matthew Beliveau <mbelivea@redhat.com>
2410 PR c++/90449 - add -Winaccessible-base option.
2411 * c.opt (Winaccessible-base): New option.
2413 2019-06-10 Jakub Jelinek <jakub@redhat.com>
2415 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCAN.
2416 * c-pragma.c (omp_pragmas_simd): Add #pragma omp scan.
2417 * c-omp.c (c_omp_split_clauses): Diagnose inscan reductions on
2418 combined/composite constructs where it is not allowed. Copy over
2419 OMP_CLAUSE_REDUCTION_INSCAN.
2421 2019-06-05 Martin Sebor <msebor@redhat.com>
2423 * c-attribs.c (handle_mode_attribute): Adjust quoting and hyphenation.
2424 (handle_alias_ifunc_attribute): Same.
2425 (handle_copy_attribute): Same.
2426 (handle_weakref_attribute): Same.
2427 (handle_nonnull_attribute): Same.
2428 * c-warn.c (warn_for_sign_compare): Same.
2429 (warn_for_restrict): Same.
2432 2019-06-05 Martin Sebor <msebor@redhat.com>
2434 * c-pragma.c (handle_pragma_weak): Adjust quoting in a diagnostic.
2435 * c.opt (-Wformat-diag): Remove a spurious period.
2437 2019-05-29 Jakub Jelinek <jakub@redhat.com>
2440 * c-common.c (check_builtin_function_arguments)
2441 <case BUILTIN_*_OVERFLOW>: Diagnose pointer to const qualified integer
2444 2019-05-23 Eric Botcazou <ebotcazou@adacore.com>
2446 * c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
2448 2019-05-22 Martin Liska <mliska@suse.cz>
2451 * c-attribs.c (handle_copy_attribute): Do not copy
2452 target_clones attribute.
2454 2019-05-21 Eric Botcazou <ebotcazou@adacore.com>
2456 * c-ada-spec.h (enum cpp_operation): Add IS_ASSIGNMENT_OPERATOR.
2457 * c-ada-spec.c (print_assignment_operator): New function.
2458 (dump_ada_declaration) <FUNCTION_DECL>: Call it do dump explicit copy
2459 assignment operators declared as methods and filter out the others.
2461 2019-05-17 Thomas Schwinge <thomas@codesourcery.com>
2464 * c-attribs.c (c_common_attribute_table): Set min_len to -1 for
2465 "omp declare target".
2467 2019-05-16 Martin Sebor <msebor@redhat.com>
2469 * c-attribs.c (handle_no_sanitize_attribute): Quote identifiers,
2470 keywords, operators, and types in diagnostics.
2471 (handle_scalar_storage_order_attribute): Same.
2472 (handle_mode_attribute): Same.
2473 (handle_visibility_attribute): Same.
2474 (handle_assume_aligned_attribute): Same.
2475 (handle_no_split_stack_attribute): Same.
2476 * c-common.c (shorten_compare): Same.
2477 (c_common_truthvalue_conversion): Same.
2478 (cb_get_source_date_epoch): Same.
2479 * c-lex.c (cb_def_pragma): Quote keywords, operators, and types
2481 (interpret_float): Same.
2482 * c-omp.c (c_finish_omp_for): Same.
2483 * c-opts.c (c_common_post_options): Same.
2484 * c-pch.c (c_common_pch_pragma): Same.
2485 * c-pragma.c (pop_alignment): Same.
2486 (handle_pragma_pack): Same.
2487 (apply_pragma_weak): Same.
2488 (handle_pragma_weak): Same.
2489 (handle_pragma_scalar_storage_order): Same.
2490 (handle_pragma_redefine_extname): Same.
2491 (add_to_renaming_pragma_list): Same.
2492 (maybe_apply_renaming_pragma): Same.
2493 (push_visibility): Same.
2494 (handle_pragma_visibility): Same.
2495 (handle_pragma_optimize): Same.
2496 (handle_pragma_message): Same.
2497 * c-warn.c (warn_for_omitted_condop): Same.
2498 (lvalue_error): Same.
2500 2019-05-15 Richard Biener <rguenther@suse.de>
2503 * c-common.c (c_common_mark_addressable_vec): Also mark
2504 a COMPOUND_LITERAL_EXPR_DECL addressable similar to
2507 2019-05-06 Nathan Sidwell <nathan@acm.org>
2509 * c-opts.c (handle_defered_opts): Rename struct deps to struc mkdeps.
2511 2019-04-30 Nathan Sidwell <nathan@acm.org>
2513 * c-common.c (c_common_init_ts): Use MARK_TS_EXP. Mark SIZEOF_EXPR.
2515 2019-04-30 Martin Liska <mliska@suse.cz>
2517 * c-pragma.c (handle_pragma_diagnostic): Provide hints
2518 for unknown options.
2520 2019-04-26 Richard Sandiford <richard.sandiford@arm.com>
2522 * c-warn.c (strict_aliasing_warning): Apply COMPLETE_TYPE_P to
2523 the pointer target rather than the pointer itself.
2525 2019-04-19 Jakub Jelinek <jakub@redhat.com>
2528 * c-common.h (c_add_case_label): Remove orig_type and outside_range_p
2530 (c_do_switch_warnings): Remove outside_range_p argument.
2531 * c-common.c (check_case_bounds): Removed.
2532 (c_add_case_label): Remove orig_type and outside_range_p arguments.
2533 Don't call check_case_bounds. Fold low_value as well as high_value.
2534 * c-warn.c (c_do_switch_warnings): Remove outside_range_p argument.
2535 Check for case labels outside of range of original type here and
2538 2019-04-12 Jakub Jelinek <jakub@redhat.com>
2540 PR translation/90041
2541 * c.opt (-fhandle-exceptions): Use %< and %> around option names
2542 in the Warn diagnostics.
2545 * c-attribs.c (handle_patchable_function_entry_attribute): Add
2546 function comment. Warn if arguments of the attribute are not positive
2549 2019-04-09 Eric Botcazou <ebotcazou@adacore.com>
2551 * c-ada-spec.c (print_destructor): Deal with deleting destructors.
2552 (dump_ada_declaration) <FUNCTION_DECL>: Likewise.
2554 2019-04-07 Eric Botcazou <ebotcazou@adacore.com>
2556 * c-ada-spec.c (is_float128): New predicate extracted from...
2557 (dump_ada_node) <COMPLEX_TYPE>: Use it to recognize __cfloat128.
2558 <REAL_TYPE>: ...here. Call it.
2560 2019-04-05 David Malcolm <dmalcolm@redhat.com>
2563 * c-warn.c (check_address_or_pointer_of_packed_member): Add
2564 auto_diagnostic_group. Guard inform calls by result of
2567 2019-04-05 Marek Polacek <polacek@redhat.com>
2569 PR c++/89973 - -Waddress-of-packed-member ICE with invalid conversion.
2570 * c-warn.c (check_address_or_pointer_of_packed_member): Check the type
2573 2019-04-03 Jason Merrill <jason@redhat.com>
2575 PR c++/86586 - -fcompare-debug=-Wsign-compare.
2576 * c-warn.c (warn_for_sign_compare): Call fold_for_warn.
2578 2019-04-01 Martin Sebor <msebor@redhat.com>
2581 * c-attribs.c (handle_copy_attribute): Handle references and
2582 non-constant expressions.
2584 2019-03-22 Jakub Jelinek <jakub@redhat.com>
2587 * c.opt (-fconstexpr-ops-limit=): New option.
2589 2019-03-21 Jakub Jelinek <jakub@redhat.com>
2591 * c-common.c (per_file_includes_t): Use false as Lazy in hash_set
2594 2019-03-19 Martin Sebor <msebor@redhat.com>
2596 PR tree-optimization/89688
2597 * c-common.c (braced_list_to_string): Make static.
2598 (braced_lists_to_strings): Define new function.
2599 * c-common.h (braced_list_to_string): Remove.
2600 (braced_lists_to_strings): Declare.
2602 2019-03-12 Martin Liska <mliska@suse.cz>
2604 * c-opts.c (c_common_handle_option): Wrap option with %< and %>.
2606 2019-03-11 Martin Liska <mliska@suse.cz>
2608 * c-opts.c (c_common_post_options): Wrap apostrophes
2609 in gcc internal format with %'.
2611 2019-03-11 Martin Liska <mliska@suse.cz>
2613 * c-attribs.c (handle_nocf_check_attribute): Wrap an option name
2614 in a string format message and fix GNU coding style.
2615 * c-common.c (vector_types_convertible_p): Likewise.
2616 (c_build_vec_perm_expr): Likewise.
2617 * c-indentation.c (get_visual_column): Likewise.
2618 * c-opts.c (c_common_handle_option): Likewise.
2619 (c_common_post_options): Likewise.
2620 (sanitize_cpp_opts): Likewise.
2621 * c-pch.c (c_common_pch_pragma): Likewise.
2622 * c-pragma.c (handle_pragma_pack): Likewise.
2624 2019-03-08 Jakub Jelinek <jakub@redhat.com>
2626 PR tree-optimization/89550
2627 * c-common.c (c_common_truthvalue_conversion): Only set
2628 TREE_NO_WARNING if warning_at returned true.
2629 * c-warn.c (overflow_warning, warn_logical_operator): Likewise.
2631 2019-02-25 Sandra Loosemore <sandra@codesourcery.com>
2632 Martin Sebor <msebor@gmail.com>
2634 * c.opt (Wmissing-attributes): Clean up doc string.
2636 2019-02-25 Jakub Jelinek <jakub@redhat.com>
2639 * c-format.c (maybe_read_dollar_number): Compute nargnum in
2640 HOST_WIDE_INT type to avoid overflows and change overflow_flag
2643 2019-02-22 Richard Biener <rguenther@suse.de>
2645 * c-pch.c (no_checksum): Remove.
2646 (pch_init): Remove assertion that executable_checksum is not
2648 (c_common_valid_pch): Likewise.
2650 2019-02-18 Martin Sebor <msebor@redhat.com>
2653 * c-common.c (invalid_array_size_error): Handle cst_size_not_constant.
2655 2019-02-16 David Malcolm <dmalcolm@redhat.com>
2658 * c-common.c (shorten_compare): Call fold_for_warn on op0 when
2659 implementing -Wtype-limits.
2661 2019-02-11 Martin Sebor <msebor@redhat.com>
2664 * c-common.c (invalid_array_size_error): New function.
2665 (valid_array_size_p): Call it. Handle size as well as type.
2666 * c-common.h (valid_constant_size_p): New function.
2667 (enum cst_size_error): New type.
2669 2019-01-31 David Malcolm <dmalcolm@redhat.com>
2672 * known-headers.cc (get_stdlib_header_for_name): Add
2673 {FLT|DBL|LDBL}_{MAX|MIN} to "hints" array.
2675 2019-01-31 Jakub Jelinek <jakub@redhat.com>
2678 * c-pretty-print.c (pp_c_enumeration_constant): Print always as
2679 a C cast in pp_c_flag_gnu_v3 mode.
2681 2019-01-29 Jakub Jelinek <jakub@redhat.com>
2684 * c-common.c (c_common_nodes_and_builtins): Build type variants for
2685 builtin_structptr_types types even for C.
2687 2019-01-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
2689 * c-warn.c (check_address_or_pointer_of_packed_member): Handle the case
2690 when rhs is of array type correctly. Fix handling of nested structures.
2691 Fix handling of indirect_ref together with nop_expr and/or addr_expr.
2692 (check_and_warn_address_or_pointer_of_packed_member): Fix handling of
2693 type casts within nested compound expressions.
2695 2019-01-22 Jakub Jelinek <jakub@redhat.com>
2698 * c-omp.c (c_finish_omp_atomic): For bitfield atomics, update type
2699 variable after using BIT_FIELD_REF.
2701 2019-01-18 H.J. Lu <hongjiu.lu@intel.com>
2705 * c-common.h (warn_for_address_or_pointer_of_packed_member):
2706 Remove the boolean argument.
2707 * c-warn.c (check_address_of_packed_member): Renamed to ...
2708 (check_address_or_pointer_of_packed_member): This. Also
2709 warn pointer conversion.
2710 (check_and_warn_address_of_packed_member): Renamed to ...
2711 (check_and_warn_address_or_pointer_of_packed_member): This.
2712 Also warn pointer conversion.
2713 (warn_for_address_or_pointer_of_packed_member): Remove the
2714 boolean argument. Don't check pointer conversion here.
2716 2019-01-15 Richard Sandiford <richard.sandiford@arm.com>
2719 * c.opt (Wdeprecated): Move documentation and variable to common.opt.
2721 2019-01-14 Jakub Jelinek <jakub@redhat.com>
2723 * c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
2724 and __cpp_nontype_template_parameter_auto. Add a comment that
2725 __cpp_template_auto is deprecated.
2727 2019-01-14 Tom Honermann <tom@honermann.net>
2729 Implement P0482R5, char8_t: A type for UTF-8 characters and strings
2730 * c-common.c (c_common_reswords): Add char8_t.
2731 (fix_string_type): Use char8_t for the type of u8 string literals.
2732 (c_common_get_alias_set): char8_t doesn't alias.
2733 (c_common_nodes_and_builtins): Define char8_t as a builtin type in
2735 (c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
2736 (keyword_begins_type_specifier): Add RID_CHAR8.
2737 * c-common.h (rid): Add RID_CHAR8.
2738 (c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
2739 Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
2740 Define char8_type_node and char8_array_type_node.
2741 * c-cppbuiltin.c (cpp_atomic_builtins): Predefine
2742 __GCC_ATOMIC_CHAR8_T_LOCK_FREE.
2743 (c_cpp_builtins): Predefine __cpp_char8_t.
2744 * c-lex.c (lex_string): Use char8_array_type_node as the type of
2746 (lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
2747 * c-opts.c: If not otherwise specified, enable -fchar8_t when
2749 * c.opt: Add the -fchar8_t command line option.
2751 2019-01-14 Martin Sebor <msebor@redhat.com>
2754 * c-attribs.c (positional_argument): Call valid_format_string_type_p
2755 and issue errors if it fails.
2756 * c-common.h (valid_format_string_type_p): Declare.
2757 * c-format.c (valid_stringptr_type_p): Rename...
2758 (valid_format_string_type_p): ...to this and make extern.
2759 (handle_format_arg_attribute): Adjust to new name.
2760 (check_format_string): Same.
2762 2019-01-13 H.J. Lu <hongjiu.lu@intel.com>
2764 * c-warn.c (warn_for_address_or_pointer_of_packed_member):
2765 Replace "may may" with "may" in warning message.
2767 2019-01-07 Jakub Jelinek <jakub@redhat.com>
2770 * c-common.h (enum rid): Add RID_BUILTIN_CONVERTVECTOR.
2771 (c_build_vec_convert): Declare.
2772 * c-common.c (c_build_vec_convert): New function.
2774 2019-01-04 Martin Sebor <msebor@redhat.com>
2777 * c-attribs.c (handle_copy_attribute): Avoid copying attribute leaf.
2778 Handle C++ empty throw specification and C11 _Noreturn.
2779 (has_attribute): Also handle C11 _Noreturn.
2781 2019-01-04 Martin Sebor <msebor@redhat.com>
2784 * c-attribs.c (positional_argument): Also accept enumerated types.
2786 2019-01-01 Jakub Jelinek <jakub@redhat.com>
2788 Update copyright years.
2790 2018-12-20 H.J. Lu <hongjiu.lu@intel.com>
2793 * c-common.h (warn_for_address_or_pointer_of_packed_member): New.
2794 * c-warn.c (check_alignment_of_packed_member): New function.
2795 (check_address_of_packed_member): Likewise.
2796 (check_and_warn_address_of_packed_member): Likewise.
2797 (warn_for_address_or_pointer_of_packed_member): Likewise.
2798 * c.opt: Add -Wno-address-of-packed-member.
2800 2018-12-20 David Malcolm <dmalcolm@redhat.com>
2803 * c-warn.c (get_outermost_macro_expansion): New function.
2804 (spelled_the_same_p): Use it to unwind the macro expansions, and
2805 compare the outermost macro in each nested expansion, rather than
2808 2018-12-19 David Malcolm <dmalcolm@redhat.com>
2811 * c-common.h (warn_tautological_cmp): Convert 1st param from
2812 location_t to const op_location_t &.
2813 * c-warn.c (find_array_ref_with_const_idx_r): Call fold_for_warn
2814 when testing for INTEGER_CST.
2815 (warn_tautological_bitwise_comparison): Convert 1st param from
2816 location_t to const op_location_t &; use it to build a
2817 binary_op_rich_location, and use this.
2818 (spelled_the_same_p): New function.
2819 (warn_tautological_cmp): Convert 1st param from location_t to
2820 const op_location_t &. Warn for macro expansions if
2821 spelled_the_same_p. Use binary_op_rich_location.
2823 2018-12-19 David Malcolm <dmalcolm@redhat.com>
2827 * c-common.c (unsafe_conversion_p): Fold any location wrapper.
2828 (verify_tree): Handle location wrappers.
2829 (c_common_truthvalue_conversion): Strip any location wrapper.
2831 (fold_offsetof): Strip any location wrapper.
2832 (complete_array_type): Likewise for initial_value.
2833 (convert_vector_to_array_for_subscript): Call fold_for_warn on the
2834 index before checking for INTEGER_CST.
2835 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
2836 print parentheses around location wrappers.
2837 * c-warn.c (warn_logical_operator): Call fold_for_warn on op_right
2838 before checking for INTEGER_CST.
2839 (warn_tautological_bitwise_comparison): Call
2840 tree_strip_any_location_wrapper on lhs, rhs, and bitop's operand
2841 before checking for INTEGER_CST.
2842 (readonly_error): Strip any location wrapper.
2843 (warn_array_subscript_with_type_char): Strip location wrappers
2844 before checking for INTEGER_CST. Use the location of the index if
2847 2018-12-06 Jason Merrill <jason@redhat.com>
2849 PR c++/88136 - -Wdeprecated-copy false positives
2850 * c.opt (Wdeprecated-copy-dtor): New.
2851 (Wdeprecated-copy): Move to -Wextra.
2853 2018-11-29 Martin Sebor <msebor@redhat.com>
2857 * c-attribs.c (common_handle_aligned_attribute): Silently avoid setting
2858 alignments to values less than the target requires.
2859 (has_attribute): For attribute aligned consider both the attribute
2860 and the alignment bits.
2861 * c-common.c (c_init_attributes): Optionally issue a warning for
2864 2018-11-28 Martin Sebor <msebor@redhat.com>
2868 * c-warn.c (sizeof_pointer_memaccess_warning): Bail if source
2869 or destination is an error.
2871 2018-11-28 Jakub Jelinek <jakub@redhat.com>
2874 * c-ubsan.c: Include langhooks.h.
2875 (ubsan_instrument_division): Change gcc_assert that main variants
2876 of op0 and op1 types are equal to gcc_checking_assert that the
2877 main variants are compatible types.
2879 2018-11-27 Eric Botcazou <ebotcazou@adacore.com>
2881 * c-ada-spec.c: Include stringpool.h.
2882 (has_static_fields): Return false for incomplete types.
2883 (is_tagged_type): Likewise.
2884 (has_nontrivial_methods): Likewise.
2885 (dump_ada_node) <INTEGER_TYPE>: Deal specifically with __int128.
2886 (struct overloaded_name_hash): New structure.
2887 (struct overloaded_name_hasher): Likewise.
2888 (overloaded_names): New global variable.
2889 (init_overloaded_names): New static function.
2890 (overloaded_name_p): New predicate.
2891 (dump_ada_declaration) <TYPE_DECL>: Tidy up and set TREE_VISITED
2892 on the TYPE_STUB_DECL of the original type of a typedef, if any.
2893 <FUNCTION_DECL>: Bail out for an unsupported overloaded name.
2894 Remove always-true condition and dump forward types.
2895 (dump_ada_specs): Delete overloaded_names.
2897 2018-11-20 Martin Sebor <msebor@redhat.com>
2899 * c-attribs.c (type_for_vector_size): New function.
2900 (type_valid_for_vector_size): Same.
2901 (handle_vector_size_attribute): Move code to the functions above
2903 (validate_attribute, has_attribute): New functions.
2904 * c-common.h (has_attribute): Declare.
2905 (rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
2906 * c-common.c (c_common_resword): Same.
2908 2018-11-16 Jason Merrill <jason@redhat.com>
2910 * c-lex.c (c_common_has_attribute): Handle likely/unlikely.
2911 * c-attribs.c (attr_cold_hot_exclusions): Make public.
2913 2018-11-16 Jakub Jelinek <jakub@redhat.com>
2916 * c-common.c (fix_string_type): Reject string literals larger than
2917 TYPE_MAX_VALUE (ssizetype) bytes.
2919 2018-11-15 Martin Sebor <msebor@redhat.com>
2923 * c-attribs.c (positional_argument): New function.
2924 (handle_alloc_size_attribute): Use it and simplify.
2925 (handle_alloc_align_attribute): Same.
2926 (handle_assume_aligned_attribute): Same.
2927 (handle_nonnull_attribute): Same.
2928 * c-common.c (check_function_arguments): Pass fntype to
2929 check_function_format.
2930 * c-common.h (check_function_format): Add an argument.
2931 (PosArgFlags, positional_argument): Declare new type and function.
2932 * c-format.c (decode_format_attr): Add arguments.
2933 (check_format_string, get_constant): Same.
2934 (convert_format_name_to_system_name): Adjust.
2936 2018-11-15 David Malcolm <dmalcolm@redhat.com>
2939 * c-opts.c (c_diagnostic_finalizer): Add diagnostic_t param.
2941 2018-11-14 Jakub Jelinek <jakub@redhat.com>
2943 P1236R1 - Signed integers are two's complement
2944 * c-warn.c (maybe_warn_shift_overflow): Don't warn for c++2a.
2945 * c-ubsan.c (ubsan_instrument_shift): Make signed shifts
2946 with in-range second operand well defined for -std=c++2a.
2949 * c-common.c (parse_optimize_options): Allocate option string from
2950 opts_obstack rather than as GC memory. Move the allocation after
2951 warning for invalid option.
2953 2018-11-13 David Malcolm <dmalcolm@redhat.com>
2955 * c-common.c (c_get_substring_location): Update for renaming of
2956 get_source_location_for_substring to get_location_within_string.
2957 * c-lex.c: Replace "source_location" with "location_t".
2958 * c-opts.c: Likewise.
2959 * c-ppoutput.c: Likewise.
2961 2018-11-13 Martin Sebor <msebor@redhat.com>
2964 * c-attribs.c (handle_copy_attribute): Exclude inlining attributes.
2965 (handle_tls_model_attribute): Improve diagnostics.
2967 2018-11-12 Jason Merrill <jason@redhat.com>
2969 * c-cppbuiltin.c (c_cpp_builtins): Define
2970 __cpp_impl_destroying_delete.
2972 * c-cppbuiltin.c (c_cpp_builtins): Change __cpp_explicit_bool to
2973 __cpp_conditional_explicit.
2975 2018-11-09 Martin Sebor <msebor@redhat.com>
2978 * c-attribs.c (handle_copy_attribute): New function.
2980 2018-11-09 Martin Sebor <msebor@redhat.com>
2983 * c-common.c (check_user_alignment): Use MAX_OFILE_ALIGNMENT.
2985 2018-11-08 Jakub Jelinek <jakub@redhat.com>
2987 * c-common.h (c_finish_omp_taskgroup): Add CLAUSES argument.
2988 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
2989 enum omp_memory_order MEMORY_ORDER.
2990 (c_finish_omp_flush): Add MO argument.
2991 (c_omp_depend_t_p, c_finish_omp_depobj): Declare.
2992 (c_finish_omp_for): Add FINAL_P argument.
2993 * c-omp.c: Include memmodel.h.
2994 (c_finish_omp_taskgroup): Add CLAUSES argument. Set
2995 OMP_TASKGROUP_CLAUSES to it.
2996 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
2997 enum omp_memory_order MEMORY_ORDER. Set OMP_ATOMIC_MEMORY_ORDER
2998 instead of OMP_ATOMIC_SEQ_CST.
2999 (c_omp_depend_t_p, c_finish_omp_depobj): New functions.
3000 (c_finish_omp_flush): Add MO argument, if not MEMMODEL_LAST, emit
3001 __atomic_thread_fence call with the given value.
3002 (check_omp_for_incr_expr): Formatting fixes.
3003 (c_finish_omp_for): Add FINAL_P argument. Allow NE_EXPR
3004 even in OpenMP loops, diagnose if NE_EXPR and incr expression
3005 is not constant expression 1 or -1. Transform NE_EXPR loops
3006 with iterators pointers to VLA into LT_EXPR or GT_EXPR loops.
3007 (c_omp_check_loop_iv_r): Look for orig decl of C++ range for
3009 (c_omp_split_clauses): Add support for combined
3010 #pragma omp parallel master and
3011 #pragma omp {,parallel }master taskloop{, simd} constructs.
3012 Handle OMP_CLAUSE_IN_REDUCTION. Handle OMP_CLAUSE_REDUCTION_TASK.
3013 Handle OMP_CLAUSE_NONTEMPORAL. Handle splitting OMP_CLAUSE_IF
3014 also to OMP_SIMD. Copy OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
3015 (c_omp_predetermined_sharing): Don't return
3016 OMP_CLAUSE_DEFAULT_SHARED for const qualified decls.
3017 * c-pragma.c (omp_pragmas): Add PRAGMA_OMP_DEPOBJ and
3018 PRAGMA_OMP_REQUIRES.
3019 * c-pragma.h (enum pragma_kind): Likewise.
3020 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_NONTEMPORAL
3021 and PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
3023 2018-11-08 David Malcolm <dmalcolm@redhat.com>
3025 * c-format.c (gcc_dump_printf_char_table): Add entry for %f.
3027 2018-11-08 David Malcolm <dmalcolm@redhat.com>
3029 * c-format.c (local_cgraph_node_ptr_node): New variable.
3030 (gcc_dump_printf_char_table): Add entry for %C.
3031 (get_pointer_to_named_type): New function, taken from the handling
3032 code for "gimple *" from...
3033 (init_dynamic_diag_info): ...here. Add handling for
3035 * c-format.h (T_CGRAPH_NODE): New.
3037 2018-10-19 Jason Merrill <jason@redhat.com>
3039 * c-cppbuiltin.c (c_cpp_builtins): Add
3040 __cpp_nontype_template_parameter_class.
3042 2018-10-31 Nathan Sidwell <nathan@acm.org>
3044 * c-opts.c (c_finish_options): Force command line macro
3045 location. Refactor to avoid repeating main debug hook.
3046 (push_command_line_include): Clarify comment.
3048 * c-opts.c (c_finish_options): Adjust cpp_force_token_locations call.
3050 2018-10-30 Martin Sebor <msebor@redhat.com>
3053 * c-format.c (check_format_types): Avoid diagnosing null pointer
3054 arguments to printf-family of functions.
3056 2018-10-30 Marek Polacek <polacek@redhat.com>
3058 Implement P0892R2, explicit(bool).
3059 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
3061 2018-10-29 David Malcolm <dmalcolm@redhat.com>
3063 * name-hint.h (name_hint::take_deferred): New member function.
3065 2018-10-29 David Malcolm <dmalcolm@redhat.com>
3068 * c-common.c (check_function_sentinel): Call fold_for_warn on the
3070 (check_function_restrict): Rename param "argarray" to
3071 "unfolded_argarray", and make a copy named "argarray", calling
3072 fold_for_warn on each argument.
3073 (check_function_arguments): Add note about responsibility for
3074 folding the arguments.
3076 2018-10-17 Joseph Myers <joseph@codesourcery.com>
3078 * c-common.c (flag_isoc2x): New variable.
3079 * c-common.h (clk_c): Update comment to reference C2X.
3080 (flag_isoc99, flag_isoc11): Update comments to reference future
3081 standard versions in general.
3082 (flag_isoc2x): Declare.
3083 * c-opts.c (set_std_c2x): New function.
3084 (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
3085 (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
3087 * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
3089 2018-10-17 Joseph Myers <joseph@codesourcery.com>
3091 * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
3092 (std=iso9899:2018): Document C17 as published in 2018.
3094 2018-10-12 Christophe Lyon <christophe.lyon@linaro.org>
3097 * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
3099 2018-10-11 Will Wray <wjwray@gmail.com>
3102 * c-pretty-print.h (pp_c_type_cast): Prototype.
3103 (pp_c_integer_constant): Likewise.
3104 * c-pretty-print.c (pp_c_type_cast): No longer static.
3105 (pp_c_integer_constant): Likewise.
3106 (pp_c_enumeration_constant): Fix loop termination when finding
3107 name of constant. No longer returns a value. Call
3108 pp_c_integer_constant.
3109 (c_pretty_printer::constant): Update for changes to
3110 pp_c_enumeration_constant.
3112 2018-10-11 Jakub Jelinek <jakub@redhat.com>
3114 * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
3115 for no_unique_address.
3117 2018-10-09 David Malcolm <dmalcolm@redhat.com>
3119 * c-common.c (c_option_controlling_cpp_error): Rename to...
3120 (c_option_controlling_cpp_diagnostic): ...this, and convert
3121 "reason" from int to enum.
3122 (c_cpp_error): Rename to...
3123 (c_cpp_diagnostic): ...this, converting level and reason to enums.
3124 * c-common.h (c_cpp_error): Rename to...
3125 (c_cpp_diagnostic): ...this, converting level and reason to enums.
3126 * c-opts.c (c_common_init_options): Update for renaming.
3128 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
3131 * c-common.c (vector_types_compatible_elements_p): Use
3132 INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
3134 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
3136 * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
3137 to generate constructor destructor priority warning.
3138 * c.opt (-Wprio-ctor-dtor): New option.
3140 2018-10-01 Jason Merrill <jason@redhat.com>
3142 * c-lex.c (c_common_has_attribute): Add no_unique_address.
3144 2018-10-01 Eric Botcazou <ebotcazou@adacore.com>
3146 * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
3147 (dump_ada_node): Add const keyword.
3149 2018-09-25 Martin Liska <mliska@suse.cz>
3151 * c-common.c (c_common_truthvalue_conversion):
3152 Remove Pascal from documentation.
3154 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
3156 * c-ada-spec.c: Include diagnostic.h.
3157 (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
3159 2018-09-19 Marek Polacek <polacek@redhat.com>
3161 * c.opt (Wclass-conversion): New.
3163 2018-09-17 David Malcolm <dmalcolm@redhat.com>
3165 * c-format.c (range_label_for_format_type_mismatch::get_text):
3166 Update for new param.
3168 2018-09-17 David Malcolm <dmalcolm@redhat.com>
3170 * c-format.c (format_warning_at_char): Update for introduction of
3171 format_string_diagnostic_t.
3172 (format_type_warning): Likewise.
3174 2018-09-17 Martin Jambor <mjambor@suse.cz>
3177 * c.opt (Wabsolute-value): New.
3179 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
3181 * c-common.c (complete_flexible_array_elts): New helper function.
3182 * c-common.h (complete_flexible_array_elts): Declare.
3184 2018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
3186 * c-common.c (braced_list_to_string): Remove eval parameter.
3187 Add some more checks. Always create zero-terminated STRING_CST.
3188 * c-common.h (braced_list_to_string): Adjust prototype.
3190 2018-08-27 David Malcolm <dmalcolm@redhat.com>
3193 * c-common.c (c_cpp_error): Update for conversion of show_caret_p
3195 (maybe_suggest_missing_token_insertion): Likewise.
3196 (maybe_add_include_fixit): Add param "override_location". If set,
3197 and source-printing is enabled, then override the rich_location's
3198 primary location with that of the insertion point for the fix-it
3199 hint, marking it with SHOW_LINES_WITHOUT_RANGE.
3200 * c-common.h (extern void maybe_add_include_fixit): Add bool
3202 * c-format.c (selftest::test_type_mismatch_range_labels): Update
3203 for conversion of show_caret_p to a tri-state.
3204 * c-warn.c (warn_for_restrict): Likewise.
3206 (suggest_missing_header::~suggest_missing_header): Update call to
3207 maybe_add_include_fixit to suggest overriding the location, as it
3210 2018-08-27 Martin Liska <mliska@suse.cz>
3212 * c-common.c (check_function_restrict): Use new function
3213 fndecl_built_in_p and remove check for FUNCTION_DECL if
3215 (check_builtin_function_arguments): Likewise.
3216 (reject_gcc_builtin): Likewise.
3217 * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
3219 2018-08-26 Marek Polacek <polacek@redhat.com>
3221 PR c++/87029, Implement -Wredundant-move.
3222 * c.opt (Wredundant-move): New option.
3224 2018-08-21 Marek Polacek <polacek@redhat.com>
3226 PR c++/86981, Implement -Wpessimizing-move.
3227 * c.opt (Wpessimizing-move): New option.
3229 2018-08-20 David Malcolm <dmalcolm@redhat.com>
3232 * c-attribs.c (common_handle_aligned_attribute): Add
3233 auto_diagnostic_group instance.
3234 * c-indentation.c (warn_for_misleading_indentation): Likewise.
3235 * c-opts.c (c_common_post_options): Likewise.
3236 * c-warn.c (warn_logical_not_parentheses): Likewise.
3237 (warn_duplicated_cond_add_or_warn): Likewise.
3238 (warn_for_multistatement_macros): Likewise.
3240 2018-08-20 Nathan Sidwell <nathan@acm.org>
3242 * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
3245 2018-08-17 Nathan Sidwell <nathan@acm.org>
3247 * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
3249 (laxy_hex_fp_value_count): Make unsigned.
3250 (lazy_hex_fp_value): Provided with macro & lazy number. Directly
3251 manipulate the macro.
3252 (builtin_defin_with_hex_fp_value): Adjust callback name, use
3255 2018-08-17 David Malcolm <dmalcolm@redhat.com>
3257 * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
3258 (gcc_dump_printf_length_specs): New.
3259 (gcc_dump_printf_flag_pairs): New.
3260 (gcc_dump_printf_flag_specs): New.
3261 (gcc_dump_printf_char_table): New.
3262 (format_types_orig): Add entry for "gcc_dump_printf".
3263 (init_dynamic_diag_info): Set up length_char_specs and
3264 conversion_specs for gcc_dump_printf_format_type.
3265 (handle_format_attribute): Handle gcc_dump_printf_format_type.
3267 2018-08-17 Nathan Sidwell <nathan@acm.org>
3269 * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
3271 * c-ada-spec.c: Don't #include "cpp-id-data.h"
3272 * c-cppbuiltin.c: Likewise.
3274 2018-08-17 Martin Liska <mliska@suse.cz>
3276 * c.opt: Remove Warn, Init and Report for options with
3277 Ignore/Deprecated flag. Warning is done automatically for
3280 2018-08-16 David Malcolm <dmalcolm@redhat.com>
3283 * c-common.c (selftest::c_family_tests): Call
3284 selftest::c_indentation_c_tests.
3285 * c-common.h (selftest::c_indentation_c_tests): New decl.
3286 * c-indentation.c: Include "selftest.h".
3287 (next_tab_stop): Add "tab_width" param, rather than accessing
3289 (get_visual_column): Likewise. Clarify comment. Bulletproof
3290 against reading past the end of the line.
3291 (get_first_nws_vis_column): Add "tab_width" param.
3292 (detect_intervening_unindent): Likewise.
3293 (should_warn_for_misleading_indentation): Read tab width from
3294 cpp_opts and pass around.
3295 (selftest::test_next_tab_stop): New test.
3296 (selftest::assert_get_visual_column_succeeds): New function.
3297 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
3298 (selftest::assert_get_visual_column_fails): New function.
3299 (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
3300 (selftest::test_get_visual_column): New test.
3301 (selftest::c_indentation_c_tests): New function.
3303 2018-08-16 Nathan Sidwell <nathan@acm.org>
3305 * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
3306 (store_ada_macro): Likewise.
3307 * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
3308 * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
3310 2018-08-15 David Malcolm <dmalcolm@redhat.com>
3312 * c-format.c: Include "selftest-diagnostic.h" and
3313 "gcc-rich-location.h".
3314 (format_warning_at_char): Pass NULL for new label params of
3316 (class indirection_suffix): New class.
3317 (class range_label_for_format_type_mismatch): New class.
3318 (format_type_warning): Move logic for generating "*" suffix to
3319 class indirection_suffix. Create "fmt_label" and "param_label"
3320 to show their types, and pass them to the
3321 format_warning_at_substring calls.
3322 (selftest::test_type_mismatch_range_labels): New test.
3323 (selftest::c_format_c_tests): Call it.
3325 2018-08-13 Martin Sebor <msebor@redhat.com>
3327 PR tree-optimization/71625
3328 * c-common.c (braced_list_to_string): New function.
3329 * c-common.h (braced_list_to_string): Declare it.
3331 2018-08-08 Nathan Sidwell <nathan@acm.org>
3333 * c-common.c (try_to_locate_new_include_inertion_point): Use
3334 linemap_included_from_linemap.
3335 * c-lex.c (fe_file_change): Use linemap_included_from.
3336 * c-ppoutput.c (pp_file_change): Likewise.
3338 2018-08-01 Martin Sebor <msebor@redhat.com>
3340 PR tree-optimization/86650
3341 * c-format.c (gcc_tdiag_char_table): Update comment for "%G".
3342 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
3343 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
3344 * c-format.h (T89_G): Update to be "gimple *" rather than
3346 (local_gcall_ptr_node): Rename...
3347 (local_gimple_ptr_node): ...to this.
3349 2018-07-31 David Malcolm <dmalcolm@redhat.com>
3351 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
3352 table entries for gcc_diag_char_table, and the 'Z' entry from
3353 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
3354 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
3355 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
3356 adding missing "Z" for this table. Remove erroneous "G" and "K"
3358 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
3359 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
3360 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
3362 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
3364 * c-common.c (speculation_safe_resolve_call): New function.
3365 (speculation_safe_resolve_params): New function.
3366 (speculation_safe_resolve_return): New function.
3367 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
3368 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
3369 __HAVE_SPECULATION_SAFE_VALUE.
3371 2018-07-20 David Malcolm <dmalcolm@redhat.com>
3373 * c-common.c (c_cpp_error): Remove redundant "line_table"
3374 parameter from call to rich_location::set_range.
3375 (maybe_suggest_missing_token_insertion): Likewise.
3377 2018-07-20 Martin Sebor <msebor@redhat.com>
3380 * c.opt (-Warray-bounds): Remove redundant -Wall.
3382 2018-07-20 Martin Sebor <msebor@redhat.com>
3385 * c-common.h (c_common_handle_option): Change function argument
3387 * c-opts.c (c_common_init_options): Same.
3388 (c_common_handle_option): Same. Remove special handling of
3389 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
3390 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
3391 options to take a HOST_WIDE_INT argument and accept a byte-size
3393 (-Wvla-larger-than): Same.
3394 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
3395 (-Wno-vla-larger-than): Same.
3397 2018-07-12 Jakub Jelinek <jakub@redhat.com>
3399 * c-attribs.c (c_common_attribute_table): Add
3400 "omp declare target implicit" attribute.
3402 2018-07-12 Richard Biener <rguenther@suse.de>
3405 * c-attribs.c (handle_packed_attribute): Do not build a variant
3406 type with TYPE_PACKED, instead ignore the attribute if we may
3407 not apply to the original type.
3409 2018-07-10 Jakub Jelinek <jakub@redhat.com>
3412 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
3413 to contain TREE_LIST for both the original class iterator and the
3416 2018-07-07 Eric Botcazou <ebotcazou@adacore.com>
3418 * c-ada-spec.c (to_ada_name): Remove index parameter.
3419 (pp_ada_tree_identifier): Likewise.
3420 (dump_ada_macros): Adjust call to to_ada_name.
3421 (struct overloaded_name_hash): Delete.
3422 (struct overloaded_name_hasher): Likewise.
3423 (overloaded_names): Likewise.
3424 (compute_overloading_index): Likewise.
3425 (dump_ada_decl_name): Do not call compute_overloading_index and
3426 adjust calls to pp_ada_tree_identifier.
3427 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
3428 (dump_ada_import): Add spc parameter and switch to aspect syntax.
3429 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
3430 (dump_ada_enum_type): Remove type and display_convention parameters.
3431 Adjust calls to pp_ada_tree_identifier.
3432 (dump_ada_node): Likewise and for dump_ada_structure.
3433 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
3435 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
3437 (print_constructor): Adjust call to pp_ada_tree_identifier.
3438 (print_destructor): Likewise.
3439 (dump_ada_declaration): Switch to aspect syntax.
3440 (dump_ada_structure): Likewise and tidy up. Replace display_convention
3441 parameter with nested parameter.
3442 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
3443 (dump_ada_specs): Do not delete overloaded_names table.
3445 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
3448 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
3451 2018-07-05 Nathan Sidwell <nathan@acm.org>
3453 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
3454 NO_IMPLICIT_EXTERN_C.
3456 2018-06-28 Martin Liska <mliska@suse.cz>
3458 * cppspec.c: Include opt-suggestions.h.
3460 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
3461 Thomas Schwinge <thomas@codesourcery.com>
3462 Cesar Philippidis <cesar@codesourcery.com>
3464 * c-pragma.h (enum pragma_omp_clause): Add
3465 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
3466 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
3468 2018-06-20 Jakub Jelinek <jakub@redhat.com>
3471 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
3474 2018-06-18 Martin Sebor <msebor@redhat.com>
3477 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
3480 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
3482 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
3484 2018-06-13 Jason Merrill <jason@redhat.com>
3486 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
3487 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
3490 PR c++/86094 - wrong code with defaulted move ctor.
3491 * c-opts.c (c_common_post_options): Bump the current ABI version to
3492 13. Set warn_abi_version and flag_abi_compat_version to the current
3493 version rather than 0. Fix defaulting flag_abi_compat_version from
3496 2018-06-12 Martin Sebor <msebor@redhat.com>
3499 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
3500 sizeof source and destination yields the same value.
3502 2018-06-12 Martin Liska <mliska@suse.cz>
3504 * c.opt: Make MPX-related options as Deprecated.
3506 2018-06-08 David Malcolm <dmalcolm@redhat.com>
3508 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
3511 2018-06-08 Martin Liska <mliska@suse.cz>
3513 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
3514 for MPX (macros, related functions, fields in cgraph_node, ...).
3515 (handle_bnd_legacy): Likewise.
3516 (handle_bnd_instrument): Likewise.
3519 2018-06-06 Jakub Jelinek <jakub@redhat.com>
3522 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
3523 __cpp_transactional_memory to 201500 instead of 210500.
3525 2018-06-06 Jason Merrill <jason@redhat.com>
3527 PR c++/85710 - ICE with -Wmemset-elt-size.
3528 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
3530 2018-06-01 Jason Merrill <jason@redhat.com>
3532 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
3535 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
3537 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
3538 declaration for a typedef independently of whether the declaration of
3539 the subtype is generated.
3541 2018-05-31 Martin Sebor <msebor@redhat.com>
3544 * c.opt (-Wno-alloc-size-larger-than): New option.
3546 2018-04-22 David Pagan <dave.pagan@oracle.com>
3549 * c-opts.c (c_common_post_options): Set default for warn_return_type
3550 for C++/C++ with ObjC extensions only. For C, makes it possible to
3551 differentiate between default (no option), -Wreturn-type, and
3554 2018-05-29 Jason Merrill <jason@redhat.com>
3556 * c.opt (Winit-list-lifetime): New flag.
3558 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
3560 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
3561 splay_tree_delete_pointers.
3563 2018-05-26 Jakub Jelinek <jakub@redhat.com>
3566 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
3567 noinline variable to workaround broken kernel headers.
3569 2018-05-18 Jason Merrill <jason@redhat.com>
3571 * c.opt (Wdeprecated-copy): New flag.
3573 2018-05-17 Martin Liska <mliska@suse.cz>
3575 * c-warn.c (overflow_warning): Do not use
3576 space in between 'G_' and '('.
3578 2018-05-09 Jason Merrill <jason@redhat.com>
3580 * c-common.c (valid_array_size_p): Add complain parameter.
3581 * c-common.h: ...which defaults to true.
3583 2018-05-11 Jakub Jelinek <jakub@redhat.com>
3586 * c-omp.c (c_omp_predetermined_sharing): Return
3587 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
3589 2018-05-11 Martin Liska <mliska@suse.cz>
3592 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
3595 2018-05-10 Jakub Jelinek <jakub@redhat.com>
3598 * c-common.h (fold_offsetof_1): Removed.
3599 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
3600 CTX argument defaulted to ERROR_MARK.
3601 * c-common.c (fold_offsetof_1): Renamed to ...
3602 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
3603 argument, convert the pointer constant to TYPE and use size_binop
3604 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
3605 a pointer type. Adjust recursive calls.
3607 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
3610 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
3612 2018-05-07 Nathan Sidwell <nathan@acm.org>
3614 * c.opt (ffor-scope): Remove functionality, issue warning.
3616 2018-05-03 Nathan Sidwell <nathan@acm.org>
3618 * c.opt (ffriend-injection): Remove functionality, issue warning.
3620 2018-05-01 David Malcolm <dmalcolm@redhat.com>
3623 * c-format.c (struct format_check_results): Add field
3625 (check_format_info): Initialize it, and warn if encountered.
3626 (check_format_arg): Distinguish between wide char and
3627 everything else when detecting arrays of non-char.
3629 2018-04-30 David Malcolm <dmalcolm@redhat.com>
3631 * c-format.c (get_corrected_substring): Update for
3632 location_get_source_line returning a char_span. Use a char_span
3633 when handling the prefix of the correction.
3634 * c-indentation.c (get_visual_column): Update for
3635 location_get_source_line returning a char_span.
3636 (get_first_nws_vis_column): Likewise.
3638 2018-03-29 David Malcolm <dmalcolm@redhat.com>
3641 * known-headers.cc (get_stdlib_header_for_name): Add various names
3642 from <assert.h>, <string.h>, and <memory.h>; add more names from
3645 2018-03-27 Jakub Jelinek <jakub@redhat.com>
3648 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
3649 get_base_address of the second operand is a VAR_P, rather than the
3650 operand itself, and use gcc_checking_assert instead of gcc_assert.
3652 2018-03-23 Marek Polacek <polacek@redhat.com>
3655 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
3656 <case RDIV_EXPR>: Tweak condition.
3658 2018-03-20 Eric Botcazou <ebotcazou@adacore.com>
3660 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
3662 2018-03-16 Jakub Jelinek <jakub@redhat.com>
3665 * c-warn.c (conversion_warning): Replace "to to" with "to" in
3669 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
3672 2018-03-16 Richard Biener <rguenther@suse.de>
3675 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
3676 unshare the possibly folded expression.
3678 2018-03-15 Richard Biener <rguenther@suse.de>
3681 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
3683 2018-03-13 Martin Sebor <msebor@redhat.com>
3685 PR tree-optimization/84725
3686 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
3687 with all three narrow character types, including their qualified forms.
3689 2018-03-12 Martin Sebor <msebor@redhat.com>
3691 PR tree-optimization/83456
3692 * c-common.c (check_function_restrict): Return bool.
3693 Restore checking of bounded built-in functions.
3694 (check_function_arguments): Also return the result
3695 of warn_for_restrict.
3696 * c-common.c (check_function_restrict): Return bool.
3697 * c-warn.c (warn_for_restrict): Return bool.
3699 2018-03-02 Marek Polacek <polacek@redhat.com>
3702 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
3705 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
3707 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
3710 2018-03-01 Marek Polacek <polacek@redhat.com>
3713 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
3714 alignment in computation.
3716 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3718 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
3719 <REAL_TYPE>: Deal specifically with _Float128/__float128.
3721 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3723 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
3724 (is_char_array): Take a type instead of a declaration.
3725 (dump_ada_array_type): Likewise.
3726 (is_simple_enum): Minor tweak.
3727 (dump_ada_enum_type): New function extracted from...
3728 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
3729 <INTEGER_TYPE>: Remove unreachable code.
3730 <RECORD_TYPE>: Likewise. Minor tweaks.
3731 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
3732 <ENUMERAL_TYPE>: New case.
3733 <RECORD_TYPE>: Factor out common code.
3734 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
3735 Minor tweaks. Deal with enumeral types.
3736 (dump_ada_structure): Minor tweaks.
3738 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3740 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
3741 address for incomplete structures.
3742 (dump_forward_type): Do not bail out for incomplete structures.
3743 (dump_ada_declaration): Do not special-case incomplete structures
3744 for subtypes. Dump them as null records for types.
3746 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3748 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
3749 (is_char_array): Fix formatting.
3750 (dump_template_types): Likewise.
3751 (dump_generic_ada_node): Rename into...
3752 (dump_ada_node): ...this.
3753 <POINTER_TYPE>: Remove superfluous space. Use generic address for
3754 incomplete structures and not for empty structures. Do not use it
3755 when forward declarations are needed.
3756 (dump_forward_type): New function.
3757 (dump_nested_types): Remove FORWARD parameter. Do not consider
3758 TREE_VISITED and do not generate a forward declaration. Only dump
3759 original nested types for nested declaration.
3760 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
3761 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
3762 <RECORD_TYPE>: Do not consider TREE_VISITED.
3763 (dump_ada_declaration): Use booleans and fix formatting throughout.
3764 <TYPE_DECL>: Skip incomplete structures and not empty structures.
3765 Call dump_forward_type instead of dump_nested_types for a typedef.
3766 Remove superfluous check and adjust call to dump_nested_types.
3767 <POINTER_TYPE>: Call dump_forward_type and fall through.
3768 (dump_ada_struct_decl): Rename into...
3769 (dump_ada_structure): ...this. Do not special-case empty structures.
3771 2018-02-27 Martin Sebor <msebor@redhat.com>
3774 * c.opt (-Wmissing-attributes): New option.
3776 2018-02-21 Martin Liska <mliska@suse.cz>
3778 * c.opt (Wcatch-value=): Add IntegerRange.
3780 2018-02-15 Jason Merrill <jason@redhat.com>
3782 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
3784 2018-02-09 Nathan Sidwell <nathan@acm.org>
3787 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
3789 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
3792 2018-02-09 Martin Sebor <msebor@redhat.com>
3795 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
3796 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
3797 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
3798 (-Wstrict-overflow, -Wsuggest-attribute): Same.
3799 (-Wuninitialized): Same.
3801 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
3803 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
3804 keyword for components.
3806 2018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
3808 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
3810 2018-02-02 Julia Koval <julia.koval@intel.com>
3812 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
3814 2018-01-29 Marek Polacek <polacek@redhat.com>
3817 * c-format.c (check_function_format): Check current_function_decl.
3819 2018-01-27 Jakub Jelinek <jakub@redhat.com>
3821 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
3823 (LAZY_HEX_FP_VALUES_CNT): Define.
3824 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
3825 values rather than just 12.
3826 (builtin_define_with_hex_fp_value): Likewise.
3828 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
3831 * c.opt (-fmacro-prefix-map): New option.
3832 * c-opts.c (c_common_handle_option): Handle it.
3833 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
3834 * c-ppoutput.c (init_pp_output): Likewise.
3836 2018-01-17 David Malcolm <dmalcolm@redhat.com>
3839 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
3841 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
3843 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
3844 Skip 'f' and 'F' characters if it is true.
3845 (store_ada_macro): Minor tweak.
3846 (dump_ada_macros) <CPP_COMMENT>: Likewise.
3847 <CPP_WSTRING>: Likewise.
3848 <CPP_STRING>: Output '&' in the buffer if not the first string.
3849 <CPP_NUMBER>: Adjust calls to dump_number.
3851 2018-01-10 David Malcolm <dmalcolm@redhat.com>
3854 * c-common.c: Include "selftest.h".
3855 (get_atomic_generic_size): Perform the test for integral type
3856 before the range test for any integer constant, fixing indentation
3857 of braces. Call fold_for_warn before testing for an INTEGER_CST.
3858 (reject_gcc_builtin): Strip any location wrapper from EXPR.
3859 (selftest::test_fold_for_warn): New function.
3860 (selftest::c_common_c_tests): New function.
3861 (selftest::c_family_tests): Call it, and
3862 selftest::c_pretty_print_c_tests.
3863 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
3864 * c-format.c (check_format_arg): Convert VAR_P check to a
3866 * c-pretty-print.c: Include "selftest.h".
3867 (pp_c_cast_expression): Don't print casts for location wrappers.
3868 (selftest::assert_c_pretty_printer_output): New function.
3869 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
3870 (selftest::test_location_wrappers): New function.
3871 (selftest::c_pretty_print_c_tests): New function.
3872 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
3874 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
3875 Alan Hayward <alan.hayward@arm.com>
3876 David Sherwood <david.sherwood@arm.com>
3878 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
3880 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
3881 Alan Hayward <alan.hayward@arm.com>
3882 David Sherwood <david.sherwood@arm.com>
3884 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
3887 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
3888 Alan Hayward <alan.hayward@arm.com>
3889 David Sherwood <david.sherwood@arm.com>
3891 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
3892 (convert_vector_to_array_for_subscript): Handle polynomial
3893 TYPE_VECTOR_SUBPARTS.
3894 (c_common_type_for_mode): Check valid_vector_subparts_p.
3895 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
3898 2018-01-03 Jakub Jelinek <jakub@redhat.com>
3900 Update copyright years.
3902 2017-12-22 Mike Stump <mikestump@comcast.net>
3903 Eric Botcazou <ebotcazou@adacore.com>
3905 * c-pragma.c (init_pragma): Register pragma GCC unroll.
3906 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
3908 2017-12-22 Alexandre Oliva <aoliva@redhat.com>
3912 * c-semantics.c (only_debug_stmts_after_p): New.
3913 (pop_stmt_list): Clear side effects in debug-only stmt list.
3914 Check for single nondebug stmt followed by debug stmts only.
3916 2017-12-21 Alexandre Oliva <aoliva@redhat.com>
3919 * c-semantics.c (pop_stmt_list): Propagate side effects from
3920 single nondebug stmt to container list.
3922 2017-12-19 Jakub Jelinek <jakub@redhat.com>
3924 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
3925 conditions with typical order conditions.
3927 2017-12-18 Marek Polacek <polacek@redhat.com>
3929 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
3932 2017-12-17 Martin Sebor <msebor@redhat.com>
3934 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
3935 an error for attribute warn_if_not_aligned.
3937 2017-12-16 Martin Sebor <msebor@redhat.com>
3939 PR tree-optimization/78918
3940 * c-common.c (check_function_restrict): Avoid checking built-ins.
3941 * c.opt (-Wrestrict): Include in -Wall.
3943 2017-12-15 Jakub Jelinek <jakub@redhat.com>
3945 * c-attribs.c (c_common_attribute_table,
3946 c_common_format_attribute_table): Swap affects_type_identity
3947 and handler fields, adjust comments.
3949 2017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
3951 * c.opt (Wcast-function-type): New warning option.
3952 * c-lex.c (get_fileinfo): Avoid warning.
3953 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
3955 2017-12-14 Qing Zhao <qing.zhao@oracle.com>
3958 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
3959 Adjust the size of buf1 and buf2, add a new buf to avoid
3960 format-overflow warning.
3962 2017-12-12 Alexandre Oliva <aoliva@redhat.com>
3964 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
3965 subsequent statement list.
3967 2017-12-07 Martin Sebor <msebor@redhat.com>
3971 * c-attribs.c (attr_aligned_exclusions): New array.
3972 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
3973 (attr_common_exclusions, attr_const_pure_exclusions): Same.
3974 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
3975 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
3976 (attr_warn_unused_result_exclusions): Same.
3977 (handle_hot_attribute, handle_cold_attribute): Simplify.
3978 (handle_const_attribute): Warn on function returning void.
3979 (handle_pure_attribute): Same.
3980 (handle_aligned_attribute): Diagnose conflicting attribute
3982 * c-warn.c (diagnose_mismatched_attributes): Simplify.
3984 2017-12-06 David Malcolm <dmalcolm@redhat.com>
3987 * c-common.c (selftest::c_family_tests): Call
3988 selftest::c_spellcheck_cc_tests.
3989 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
3990 * c-spellcheck.cc: Include "selftest.h".
3991 (name_reserved_for_implementation_p): New function.
3992 (should_suggest_as_macro_p): New function.
3993 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
3994 should_suggest_as_macro_p and call it.
3995 (selftest::test_name_reserved_for_implementation_p): New function.
3996 (selftest::c_spellcheck_cc_tests): New function.
3997 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
3999 2017-12-06 David Malcolm <dmalcolm@redhat.com>
4001 * c-spellcheck.cc: New file, taken from macro-handling code in
4003 * c-spellcheck.h: New file, taken from macro-handling code in
4006 2017-12-01 Jakub Jelinek <jakub@redhat.com>
4008 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
4010 (handle_simd_attribute): Don't check for "cilk simd function"
4011 attribute. Reindent, formatting changes.
4013 2017-11-30 Julia Koval <julia.koval@intel.com>
4015 * c-common.h (inv_list): Remove.
4017 2017-11-28 Jakub Jelinek <jakub@redhat.com>
4020 * c-common.c (c_switch_covers_all_cases_p_1,
4021 c_switch_covers_all_cases_p): New functions.
4022 * c-common.h (c_switch_covers_all_cases_p): Declare.
4024 2017-11-28 Julia Koval <julia.koval@intel.com>
4025 Sebastian Peryt <sebastian.peryt@intel.com>
4027 * array-notation-common.c: Delete.
4028 * c-cilkplus.c: Ditto.
4029 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
4030 * c-common.def (ARRAY_NOTATION_REF): Remove.
4031 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
4032 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
4033 c_validate_cilk_plus_loop, cilkplus_an_parts,
4034 cilk_ignorable_spawn_rhs_op,
4035 cilk_recognize_spawn): Remove.
4036 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
4037 * c-omp.c: Remove CILK_SIMD check.
4038 * c-pragma.c: Ditto.
4039 * c-pragma.h: Remove CILK related pragmas.
4040 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
4041 ARRAY_NOTATION_REF condition.
4042 (c_pretty_printer::expression): Ditto.
4043 * c.opt (fcilkplus): Remove.
4046 2017-11-21 Marc Glisse <marc.glisse@inria.fr>
4048 * c-pretty-print.c (pp_c_additive_expression,
4049 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
4051 2017-11-21 Jakub Jelinek <jakub@redhat.com>
4053 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
4056 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
4057 instead of tree_to_uhwi, formatting fix.
4059 2017-11-20 David Malcolm <dmalcolm@redhat.com>
4062 * known-headers.cc: New file, based on material from c/c-decl.c.
4063 (suggest_missing_header): Copied as-is.
4064 (get_stdlib_header_for_name): New, based on get_c_name_hint but
4065 heavily edited to add C++ support. Add some knowledge about
4066 <limits.h>, <stdint.h>, and <wchar.h>.
4067 * known-headers.h: Likewise.
4069 2017-11-20 David Malcolm <dmalcolm@redhat.com>
4071 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
4072 (lookup_name_fuzzy): Likewise. Convert return type from
4073 const char * to name_hint. Add location_t param.
4074 * name-hint.h: New header.
4076 2017-11-19 Jakub Jelinek <jakub@redhat.com>
4080 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
4082 2017-11-16 Joseph Myers <joseph@codesourcery.com>
4084 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
4085 expected publication date of C17.
4086 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
4088 2017-11-15 Joseph Myers <joseph@codesourcery.com>
4091 * c-common.c (c_common_reswords): Add __builtin_tgmath.
4092 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
4094 2017-11-10 Martin Sebor <msebor@redhat.com>
4097 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
4098 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
4099 * c.opt (-Wstringop-truncation): New option.
4101 2017-11-06 Martin Liska <mliska@suse.cz>
4104 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
4106 * c.opt: Set default value of warn_return_type.
4108 2017-10-31 David Malcolm <dmalcolm@redhat.com>
4110 * c-common.c (binary_op_error): Update for renaming of
4112 (c_parse_error): Likewise.
4113 * c-warn.c (warn_logical_not_parentheses): Likewise for
4114 renaming of inform_at_rich_loc.
4115 (warn_for_restrict): Likewise for renaming of
4116 warning_at_rich_loc_n.
4118 2017-10-30 Joseph Myers <joseph@codesourcery.com>
4120 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
4121 * c-opts.c (set_std_c17): New function.
4122 (c_common_init_options): Use gnu17 as default C version.
4123 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
4125 2017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
4127 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
4128 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
4129 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
4132 2017-10-23 Marek Polacek <polacek@redhat.com>
4135 * c-warn.c (warnings_for_convert_and_check): Fix typos.
4137 2017-10-19 Eric Botcazou <ebotcazou@adacore.com>
4139 * c-common.c (check_builtin_function_arguments): Also check arguments
4140 of __builtin_alloca_with_align_and_max.
4142 2017-10-17 David Malcolm <dmalcolm@redhat.com>
4144 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
4145 rather than NULL to format_warning_va.
4146 (check_format_types): Likewise when calling format_type_warning.
4147 Remove code to extract source_ranges and source_range * in favor
4148 of just a location_t.
4149 (format_type_warning): Convert source_range * param to a
4152 2017-10-13 Jakub Jelinek <jakub@redhat.com>
4154 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
4157 2017-10-12 David Malcolm <dmalcolm@redhat.com>
4159 * c-common.c (enum missing_token_insertion_kind): New enum.
4160 (get_missing_token_insertion_kind): New function.
4161 (maybe_suggest_missing_token_insertion): New function.
4162 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
4164 2017-10-11 Nathan Sidwell <nathan@acm.org>
4166 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
4167 (c_common_handle_option): Update incpath_kind names.
4169 2017-10-11 Martin Liska <mliska@suse.cz>
4172 * c-attribs.c (handle_no_sanitize_attribute): Report directly
4173 Wattributes warning.
4175 2017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
4177 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
4178 operating on trees as wide_ints.
4179 * c-common.c (pointer_int_sum): Likewise.
4180 * c-pretty-print.c (pp_c_integer_constant): Likewise.
4181 * c-warn.c (match_case_to_enum_1): Likewise.
4182 (c_do_switch_warnings): Likewise.
4183 (maybe_warn_shift_overflow): Likewise.
4185 2017-10-10 Jakub Jelinek <jakub@redhat.com>
4188 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
4189 instead of wide_int::from.
4191 2017-10-06 Jakub Jelinek <jakub@redhat.com>
4194 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
4195 using to_widest use wide_int with the larger of the two precisions.
4197 2017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
4199 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
4202 2017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
4204 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
4205 when combining the original unconverted comparison operands.
4207 2017-09-29 Jakub Jelinek <jakub@redhat.com>
4209 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
4212 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
4214 * c-ada-spec.c (to_ada_name): Add index parameter.
4215 (pp_ada_tree_identifier): Likewise.
4216 (dump_ada_macros): Adjust call to to_ada_name.
4217 (struct overloaded_name_hash): New type.
4218 (struct overloaded_name_hasher): Likewise.
4219 (overloaded_names): New hash table.
4220 (compute_overloading_index): New function.
4221 (dump_ada_decl_name): Call it and pass the result to
4222 pp_ada_tree_identifier.
4223 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
4224 (dump_ada_function_declaration): Likewise.
4225 (dump_generic_ada_node): Likewise.
4226 (print_constructor): Likewise.
4227 (print_destructor): Likewise.
4228 (dump_ada_specs): Delete overloaded_names table.
4230 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
4232 * c-ada-spec.c (max_ada_macros): Move around.
4233 (store_ada_macro_index): Likewise.
4234 (source_file): Rename into...
4235 (macro_source_file): ...this.
4236 (count_ada_macro): Move around.
4237 (store_ada_macro): Likewise.
4238 (compare_macro): Likewise.
4239 (print_ada_macros): Merge in...
4240 (dump_ada_macros): ...this.
4241 (source_file_base): Rename into...
4242 (current_source_file): ...this.
4243 (print_comment): Move around.
4244 (dump_ada_nodes): Call dump_ada_declaration directly.
4245 (struct with): Change type of limited field to bool.
4246 (append_withs): Change type of limited_access parameter to bool.
4247 (pp_ada_tree_identifie): Likewise.
4248 (dump_ada_decl_nam): Likewise.
4249 (dump_generic_ada_node): Likewise. Do not print the return type.
4250 (to_ada_name): Change type of space_found parameter to bool.
4251 (dump_ada_function_declaration): Return void and change type of
4252 parameters to bool. Also print the return type for a function.
4253 (print_ada_methods): Rename into...
4254 (dump_ada_methods): ...this.
4255 (print_ada_declaration): Rename into ...
4256 (dump_ada_declaration): ...this. Do not print the return type.
4257 (print_ada_struct_decl): Rename into...
4258 (dump_ada_struct_decl): ...this.
4260 2017-09-29 Jakub Jelinek <jakub@redhat.com>
4262 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
4263 rather than DECL_INITIAL.
4264 (common_handle_aligned_attribute): Likewise.
4266 2017-09-20 Alexandre Oliva <aoliva@redhat.com>
4268 * c.opt (gen-decls): Add RejectNegative.
4270 2017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
4271 Jakub Jelinek <jakub@redhat.com>
4273 Add support for -std=c++2a.
4274 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
4275 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
4276 * c-opts.c (set_std_cxx2a): New.
4277 (c_common_handle_option): Set options when -std=c++2a is enabled.
4278 (c_common_post_options): Adjust comments.
4279 (set_std_cxx14, set_std_cxx17): Likewise.
4281 2017-09-15 Eric Botcazou <ebotcazou@adacore.com>
4283 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
4284 message for non-uniform endianness and issue a warning in C++.
4286 2017-09-15 Jakub Jelinek <jakub@redhat.com>
4288 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
4289 (Wc++17-compat): Change from undocumented alias to option.
4290 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
4291 change C++1z to C++17 in description.
4292 (std=c++1z, std=gnu++1z): Change from option to undocumented
4294 (std=c++17, std=gnu++17): Change from undocumented alias to option.
4296 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
4297 * c-opts.c (set_std_cxx1z): Rename to ...
4298 (set_std_cxx17): ... this.
4299 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
4300 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
4302 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
4305 2017-09-12 H.J. Lu <hongjiu.lu@intel.com>
4307 * c-attribs.c (common_handle_aligned_attribute): Don't warn
4308 function alignment if warn_if_not_aligned_p is true.
4310 2017-09-12 Nathan Sidwell <nathan@acm.org>
4312 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
4313 resort_sorted_fields): Move to c/c-decl.c.
4314 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
4315 (struct sorted_fields_type): Move to c/c-lang.h.
4317 2017-09-09 Jonathan Wakely <jwakely@redhat.com>
4320 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
4322 2017-09-04 Marek Polacek <polacek@redhat.com>
4325 * c-warn.c (warn_tautological_bitwise_comparison): New function.
4326 (warn_tautological_cmp): Call it.
4328 2017-09-01 Boris Kolpackov <boris@codesynthesis.com>
4330 * c-opts.c (c_common_finish): Write dependency information even if
4333 2017-09-01 Jakub Jelinek <jakub@redhat.com>
4336 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
4337 (omp_pragmas_simd): ... here.
4338 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
4339 create new clauses list containing just simd clause.
4341 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4342 Alan Hayward <alan.hayward@arm.com>
4343 David Sherwood <david.sherwood@arm.com>
4345 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
4346 into scalar_mode_supported_p call.
4347 (handle_mode_attribute): Update call to scalar_mode_supported_p.
4349 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4350 Alan Hayward <alan.hayward@arm.com>
4351 David Sherwood <david.sherwood@arm.com>
4353 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
4354 for the mode iterator.
4356 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4357 Alan Hayward <alan.hayward@arm.com>
4358 David Sherwood <david.sherwood@arm.com>
4360 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
4361 * c-common.c (c_build_vec_perm_expr): Likewise.
4363 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4364 Alan Hayward <alan.hayward@arm.com>
4365 David Sherwood <david.sherwood@arm.com>
4367 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
4369 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4370 Alan Hayward <alan.hayward@arm.com>
4371 David Sherwood <david.sherwood@arm.com>
4373 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
4374 before calling targetm.addr_space.valid_pointer_mode.
4376 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4377 Alan Hayward <alan.hayward@arm.com>
4378 David Sherwood <david.sherwood@arm.com>
4380 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
4382 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4383 Alan Hayward <alan.hayward@arm.com>
4384 David Sherwood <david.sherwood@arm.com>
4386 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
4388 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
4390 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4391 Alan Hayward <alan.hayward@arm.com>
4392 David Sherwood <david.sherwood@arm.com>
4394 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
4397 2017-08-29 Martin Liska <mliska@suse.cz>
4400 * c-common.c (parse_optimize_options): Add argument to function
4402 * c-pragma.c (handle_pragma_diagnostic): Likewise.
4404 2017-08-24 David Malcolm <dmalcolm@redhat.com>
4406 * c-lex.c (interpret_float): Use token location
4407 when building an EXCESS_PRECISION_EXPR.
4409 2017-08-21 David Malcolm <dmalcolm@redhat.com>
4411 * c-common.c (check_function_arguments): Add "arglogs" param; pass
4412 it to check_function_format.
4413 * c-common.h (check_function_arguments): Add vec<location_t> *
4415 (check_function_format): Likewise.
4416 * c-format.c (struct format_check_context): Add field "arglocs".
4417 (check_function_format): Add param "arglocs"; pass it to
4419 (check_format_info): Add param "arglocs"; use it to initialize
4420 new field of format_ctx.
4421 (check_format_arg): Pass format_ctx->arglocs to new param of
4422 check_format_info_main.
4423 (class argument_parser): New field "arglocs".
4424 (argument_parser::argument_parser): Add "arglocs_" param and use
4425 it to initialize new field.
4426 (argument_parser::check_argument_type): Pass new arglocs field to
4428 (check_format_info_main): Add param "arglocs", and use it when
4429 constructing arg_parser.
4430 (check_format_types): Add param "arglocs"; use it if non-NULL when
4431 !EXPR_HAS_LOCATION (cur_param) to get at location information.
4433 2017-08-18 H.J. Lu <hongjiu.lu@intel.com>
4436 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
4437 (c_common_attribute_table): Add warn_if_not_aligned.
4438 (handle_aligned_attribute): Renamed to ...
4439 (common_handle_aligned_attribute): Remove argument, name, and add
4440 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
4441 (handle_aligned_attribute): New.
4442 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
4444 2017-08-14 Martin Sebor <msebor@redhat.com>
4447 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
4448 (handle_nonstring_attribute): New function.
4450 2017-08-14 Martin Sebor <msebor@redhat.com>
4453 * c-format.h (T89_G): New macro.
4454 * c-format.c (local_gcall_ptr_node): New variable.
4455 (init_dynamic_diag_info): Initialize it.
4457 2017-08-11 Martin Liska <mliska@suse.cz>
4459 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
4460 TARGET_SUPPORTS_ALIASES.
4462 2017-08-10 David Malcolm <dmalcolm@redhat.com>
4464 * c-common.c (c_parse_error): Add rich_location * param, using it
4465 rather implicitly using input_location.
4466 * c-common.h (c_parse_error): Add rich_location * param.
4468 2017-08-09 Marek Polacek <polacek@redhat.com>
4470 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
4471 (c_common_truthvalue_conversion): Likewise.
4472 * c-omp.c (c_finish_omp_atomic): Likewise.
4473 * c-common.h (build_binary_op): Update declaration.
4475 2017-08-08 Martin Liska <mliska@suse.cz>
4477 * c-ada-spec.c: Include header files.
4478 * c-ubsan.c: Likewise.
4479 * c-warn.c: Likewise.
4481 2017-08-07 Jakub Jelinek <jakub@redhat.com>
4484 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
4486 2017-08-07 Eric Botcazou <ebotcazou@adacore.com>
4488 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
4489 (print_ada_methods): Likewise.
4490 (print_ada_declaration): Likewise.
4492 2017-08-07 Martin Liska <mliska@suse.cz>
4494 * array-notation-common.c: Add new includes.
4495 * c-format.c( handle_format_attribute): Canonicalize a format
4497 * c-lex.c (c_common_has_attribute): Canonicalize name of an
4499 * c-pretty-print.c: Add new include.
4501 2017-08-05 Eric Botcazou <ebotcazou@adacore.com>
4503 * c-ada-spec.c (has_static_fields): Look only into variables.
4504 (print_constructor): Add TYPE parameter and use it for the name.
4505 (print_destructor): Likewise.
4506 (print_ada_declaration): Adjust to new constructor/destructor names.
4507 Adjust calls to print_constructor and print_destructor.
4508 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
4509 Look only into variables in the final loop.
4511 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
4513 * c-ada-spec.c (has_static_fields): Look only into fields.
4514 (dump_generic_ada_node): Small tweak.
4515 (dump_nested_types): Look only into fields.
4516 (print_ada_declaration): Look only into methods. Small tweak.
4517 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
4519 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
4521 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
4522 (dump_ada_function_declaration): Likewise.
4523 (dump_generic_ada_node): Likewise.
4524 (print_ada_declaration): Add support for const-qualified variables.
4526 2017-07-31 Martin Liska <mliska@suse.cz>
4529 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
4530 Guard condition with flag_sanitize_p also with current_function_decl
4532 (ubsan_maybe_instrument_reference_or_call): Likewise.
4534 2017-07-30 Uros Bizjak <ubizjak@gmail.com>
4536 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
4538 2017-07-29 Eric Botcazou <ebotcazou@adacore.com>
4540 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
4542 (print_ada_declaration): Add missing guard for record types.
4544 2017-07-27 Jakub Jelinek <jakub@redhat.com>
4547 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
4548 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
4549 new COMPOUND_EXPRs around the rhs of the comparison.
4551 2017-07-27 Marek Polacek <polacek@redhat.com>
4554 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
4557 2017-07-27 Jakub Jelinek <jakub@redhat.com>
4559 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
4560 (handle_noipa_attribute): New function.
4562 2017-07-07 Torsten Duwe <duwe@suse.de>
4564 * c-attribs.c (c_common_attribute_table): Add entry for
4565 "patchable_function_entry".
4567 2017-07-20 Nathan Sidwell <nathan@acm.org>
4569 Remove TYPE_METHODS.
4570 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
4571 dump_ada_template, print_ada_methods,
4572 print_ada_declaration): Member fns are on TYPE_FIELDS.
4574 2017-07-18 Nathan Sidwell <nathan@acm.org>
4576 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
4578 2017-07-14 David Malcolm <dmalcolm@redhat.com>
4580 * c-common.c (try_to_locate_new_include_insertion_point): New
4582 (per_file_includes_t): New typedef.
4583 (added_includes_t): New typedef.
4584 (added_includes): New variable.
4585 (maybe_add_include_fixit): New function.
4586 * c-common.h (maybe_add_include_fixit): New decl.
4588 2017-07-10 Martin Sebor <msebor@redhat.com>
4591 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
4593 2017-07-06 David Malcolm <dmalcolm@redhat.com>
4595 * c-common.c (selftest::c_family_tests): New.
4596 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
4597 (selftest::c_family_tests): New decl.
4599 2017-07-04 Marek Polacek <polacek@redhat.com>
4602 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
4605 2017-07-04 Marek Polacek <polacek@redhat.com>
4607 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
4609 2017-06-28 Martin Liska <mliska@suse.cz>
4612 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
4613 to a function declaration.
4615 2017-06-28 Martin Liska <mliska@suse.cz>
4618 * c.opt: Add IntegerRange to various options.
4620 2017-06-26 Marek Polacek <polacek@redhat.com>
4623 * c-common.h (warn_for_multistatement_macros): Declare.
4624 * c-warn.c: Include "c-family/c-indentation.h".
4625 (warn_for_multistatement_macros): New function.
4626 * c.opt (Wmultistatement-macros): New option.
4627 * c-indentation.c (guard_tinfo_to_string): No longer static.
4628 Change the parameter type to "enum rid". Handle RID_SWITCH.
4629 * c-indentation.h (guard_tinfo_to_string): Declare.
4631 2017-06-23 Marc Glisse <marc.glisse@inria.fr>
4633 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
4635 2017-06-15 Martin Sebor <msebor@redhat.com>
4638 * c.opt (-Wclass-memaccess): New option.
4640 2017-06-14 Boris Kolpackov <boris@codesynthesis.com>
4642 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
4644 2017-06-13 Marek Polacek <polacek@redhat.com>
4647 * c-warn.c (do_warn_duplicated_branches): Return if any of the
4650 2017-06-13 Martin Liska <mliska@suse.cz>
4653 * c-attribs.c (add_no_sanitize_value): New function.
4654 (handle_no_sanitize_attribute): Likewise.
4655 (handle_no_sanitize_address_attribute): Use the function.
4656 (handle_no_sanitize_thread_attribute): New function.
4657 (handle_no_address_safety_analysis_attribute): Use
4658 add_no_sanitize_value.
4659 (handle_no_sanitize_undefined_attribute): Likewise.
4660 * c-common.h: Declare new functions.
4661 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
4662 (ubsan_instrument_shift): Likewise.
4663 (ubsan_instrument_bounds): Likewise.
4664 (ubsan_maybe_instrument_array_ref): Likewise.
4665 (ubsan_maybe_instrument_reference_or_call): Likewise.
4667 2017-06-11 Jason Merrill <jason@redhat.com>
4669 * c-ada-spec.c, c-pragma.c: Use id_equal.
4671 2017-06-04 Marek Polacek <polacek@redhat.com>
4674 * c-format.c (matching_type_p): Return false if any of the types
4675 requires structural equality.
4677 2017-06-02 Martin Sebor <msebor@redhat.com>
4680 * c-warn.c (conversion_warning): Use -Wconversion for integer
4681 conversion and -Wfloat-conversion for floating one.
4683 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
4685 * c.opt (Wsizeof-pointer-div): New warning option.
4687 2017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
4689 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
4690 (Wcatch-value=1): Enable by -Wall.
4692 2017-05-30 David Malcolm <dmalcolm@redhat.com>
4694 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
4696 * c.opt (fdiagnostics-show-template-tree): New option.
4697 (felide-type): New option.
4699 2017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
4701 * c.opt (Wcatch-value=): New C++ warning flag.
4703 2017-05-24 Nathan Sidwell <nathan@acm.org>
4705 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
4706 const casts to avoid warning.
4708 2017-05-24 Martin Sebor <msebor@redhat.com>
4711 * c-common.h (unsafe_conversion_p): Add a function argument.
4712 * c-common.c (unsafe_conversion_p): Same.
4713 Add type names and values to diagnostics.
4714 (scalar_to_vector): Adjust.
4715 * c-warn.c (constant_expression_error): Add a function argument.
4716 Add type names and values to diagnostics.
4717 (conversion_warning): Add a function argument.
4718 Add type names and values to diagnostics.
4719 (warnings_for_convert_and_check): Same.
4721 2017-05-19 Jason Merrill <jason@redhat.com>
4723 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
4726 2017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
4728 * c-format.c (locus): Move out of function scope,
4731 2017-05-19 Nathan Sidwell <nathan@acm.org>
4733 * c-opts.c (class_dump_file, class_dump_flags): Delete.
4734 (c_common_parse_file): Remove class dump handling.
4735 (get_dump_info): Likewise.
4737 2017-05-19 Richard Biener <rguenther@suse.de>
4740 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
4741 to alias-set zero memory.
4743 2017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
4745 * c-format.c (local_tree_type_node): Add GTY attribute.
4747 2017-05-18 Marek Polacek <polacek@redhat.com>
4749 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
4750 (c_common_fixed_point_type_for_size): Likewise.
4751 (c_common_type_for_mode): Likewise.
4752 (shorten_compare): Likewise.
4753 (c_promoting_integer_type_p): Use false/true instead of 0/1.
4754 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
4756 2017-05-18 Marek Polacek <polacek@redhat.com>
4758 * c-common.c (self_promoting_args_p): Change the return type to bool.
4759 Use false/true instead of 0/1.
4760 * c-common.h (self_promoting_args_p): Update.
4762 2017-05-17 Marek Polacek <polacek@redhat.com>
4764 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
4765 * c-warn.c: Likewise.
4767 2017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
4769 Implement new C++ intrinsics __is_assignable and __is_constructible.
4770 * c-common.c (__is_assignable, __is_constructible): New.
4771 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
4773 2017-05-17 Martin Liska <mliska@suse.cz>
4775 * c-common.h: Introduce dump_flags_t type and
4776 use it instead of int type.
4777 * c-gimplify.c (c_genericize): Likewise.
4778 * c-opts.c: Likewise.
4780 2017-05-17 Marek Polacek <polacek@redhat.com>
4782 * c-common.c (c_save_expr): Remove.
4783 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
4784 * c-common.h (c_save_expr): Remove declaration.
4786 2017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
4789 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
4790 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
4791 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
4792 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
4794 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
4796 2017-05-09 Marek Polacek <polacek@redhat.com>
4799 * c-warn.c (unwrap_c_maybe_const): New.
4800 (warn_logical_operator): Call it.
4802 2017-05-09 Nathan Sidwell <nathan@acm.org>
4804 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
4805 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
4807 2017-05-08 Martin Sebor <msebor@redhat.com>
4809 PR translation/80280
4810 * c-format.h (struct format_flag_spec): Add new member.
4812 * c-format.c (local_tree_type_node): New global.
4813 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
4814 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
4815 (strfmon_flag_specs): Likewise.
4816 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
4817 with distinct quoting properties.
4818 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
4819 (flag_chars_t::validate): Add argument and handle bad quoting.
4820 (check_format_info_main): Handle quoting problems.
4821 (init_dynamic_diag_info): Simplify.
4823 2017-05-08 Jason Merrill <jason@redhat.com>
4825 * c-opts.c (c_common_post_options): Update defaults for
4826 flag_abi_version and flag_abi_compat_version.
4828 2017-05-05 David Malcolm <dmalcolm@redhat.com>
4830 * c-common.c (c_cpp_error): Replace report_diagnostic
4831 with diagnostic_report_diagnostic.
4833 2017-05-04 Martin Sebor <msebor@redhat.com>
4835 PR translation/80280
4836 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
4837 (handle_weakref_attribute): Same.
4839 2017-05-03 Nathan Sidwell <nathan@acm.org>
4841 Canonicalize canonical type hashing
4842 * c-common.c (complete_array_type): Use type_hash_canon.
4844 2017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
4847 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
4849 (cilk_install_body_pedigree_operations): Likewise.
4850 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
4852 (cilk_gimplify_call_params_in_spawned_fn): Remove.
4853 (cilk_install_body_pedigree_operations): Likewise.
4854 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
4857 2017-04-27 Jakub Jelinek <jakub@redhat.com>
4860 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
4861 flag on non-aggregate element types.
4863 2017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
4865 * c-common.c (c_type_hasher, type_hash_table): Remove.
4866 (c_common_get_alias_set): Remove unreachable code.
4867 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
4869 2017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
4871 * c.opt (Wextra-semi): New C++ warning flag.
4873 2017-04-20 Jakub Jelinek <jakub@redhat.com>
4876 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
4878 2017-04-18 Jakub Jelinek <jakub@redhat.com>
4882 * c-common.c (c_common_type_for_mode): Don't handle
4883 widest_*_literal_type_node here.
4884 c_common_signed_or_unsigned_type): Likewise.
4885 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
4886 to *intTI_type_node or *intDI_type_node depending on whether
4887 TImode is supported by the target or not.
4889 2017-04-10 Martin Liska <mliska@suse.cz>
4892 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
4893 doing an UBSAN check.
4895 2017-04-03 Jonathan Wakely <jwakely@redhat.com>
4897 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
4899 2017-03-31 Jakub Jelinek <jakub@redhat.com>
4902 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
4904 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
4905 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
4908 2017-03-31 David Malcolm <dmalcolm@redhat.com>
4910 PR documentation/78732
4911 * c.opt (Wendif-labels): Fix description to refer to
4912 #else rather than #elif.
4914 2017-03-31 Jakub Jelinek <jakub@redhat.com>
4917 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
4918 * c-common.c (c_common_reswords): Add __is_aggregate trait.
4920 2017-03-27 Jakub Jelinek <jakub@redhat.com>
4923 * c-common.c (c_common_mark_addressable_vec): Don't set
4924 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
4926 2017-03-21 Martin Sebor <msebor@redhat.com>
4929 * c-common.c (set_underlying_type): Mark type used only when
4930 original del is declared unused.
4932 2017-03-10 David Malcolm <dmalcolm@redhat.com>
4934 PR translation/79848
4935 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
4938 2017-03-10 David Malcolm <dmalcolm@redhat.com>
4941 * c-indentation.c (warn_for_misleading_indentation): Remove parens
4942 from inform's message, so that xgettext can locate it.
4944 2017-03-09 Marek Polacek <polacek@redhat.com>
4948 * c-attribs.c (handle_nonnull_attribute): Save the result of default
4949 conversion to the attribute list.
4951 2017-03-09 Martin Liska <mliska@suse.cz>
4953 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
4955 2017-03-03 Jason Merrill <jason@redhat.com>
4957 * c.opt (Wnoexcept-type): New.
4959 2017-03-02 Richard Biener <rguenther@suse.de>
4962 * c-common.c (c_common_mark_addressable_vec): Look through
4965 2017-02-28 Martin Liska <mliska@suse.cz>
4967 * c.opt: Replace space with tabular for options of <number>
4970 2017-02-28 Martin Liska <mliska@suse.cz>
4972 * c.opt: Fix --help=option -Q for options which are of
4975 2017-02-24 Jakub Jelinek <jakub@redhat.com>
4978 * c-common.c (check_function_restrict): New function.
4979 (check_function_arguments): Add FNDECL argument. Call
4980 check_function_restrict if -Wrestrict.
4981 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
4982 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
4983 * c-common.h (check_function_arguments): Add FNDECL argument.
4984 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
4986 2017-02-24 Eric Botcazou <ebotcazou@adacore.com>
4988 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
4989 treatment of parameters with pointer-to-tagged type and tidy up.
4990 (print_ada_methods): Remove the special treatment of C++ static member
4993 2017-02-22 Martin Liska <mliska@suse.cz>
4995 * c.opt: Replace inequality signs with square brackets
4998 2017-02-21 Jakub Jelinek <jakub@redhat.com>
5001 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
5004 2017-02-17 Joseph Myers <joseph@codesourcery.com>
5006 * c-cppbuiltin.c (builtin_define_float_constants): Define
5007 __DECIMAL_DIG__ to the value for long double.
5009 2017-02-15 Marek Polacek <polacek@redhat.com>
5012 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
5013 conversion has occured.
5015 2017-01-24 David Malcolm <dmalcolm@redhat.com>
5017 * c-common.c (c_common_reswords): Add "__RTL".
5018 * c-common.h (enum rid): Add RID_RTL.
5020 2017-01-20 Marek Polacek <polacek@redhat.com>
5023 * c-common.h (do_warn_duplicated_branches_r): Declare.
5024 * c-gimplify.c (c_genericize): Walk the function tree calling
5025 do_warn_duplicated_branches_r.
5026 * c-warn.c (expr_from_macro_expansion_r): New.
5027 (do_warn_duplicated_branches): New.
5028 (do_warn_duplicated_branches_r): New.
5029 * c.opt (Wduplicated-branches): New option.
5031 2017-01-17 David Malcolm <dmalcolm@redhat.com>
5034 * c-indentation.c (warn_for_misleading_indentation): Use the past
5035 subjunctive in the note.
5037 2017-01-17 Aldy Hernandez <aldyh@redhat.com>
5040 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
5041 start type to integer_type.
5043 2017-01-16 Jakub Jelinek <jakub@redhat.com>
5046 * c.opt (gen-decls): Add Driver flag.
5048 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
5051 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
5054 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
5056 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
5059 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
5061 2017-01-12 Martin Sebor <msebor@redhat.com>
5063 (-Wformat-overflow): ...to this.
5065 2017-01-11 Martin Sebor <msebor@redhat.com>
5068 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
5069 Also enable for LTO.
5071 2017-01-10 Jason Merrill <jason@redhat.com>
5073 Implement P0195R2, C++17 variadic using.
5074 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
5076 2017-01-09 Jakub Jelinek <jakub@redhat.com>
5078 PR translation/79019
5079 PR translation/79020
5080 * c.opt (Wnormalized=): Fix typo in description.
5082 2017-01-08 Martin Sebor <msebor@redhat.com>
5085 * c.opt (-Wformat-truncation): New option.
5087 2017-01-06 Alexandre Oliva <aoliva@redhat.com>
5089 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
5090 value to unsigned short to fit in 4 hex digits without
5093 2017-01-05 Eric Botcazou <ebotcazou@adacore.com>
5095 * c.opt (fsso-struct): Add 'native' value.
5097 2017-01-05 Martin Liska <mliska@suse.cz>
5100 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
5103 2017-01-04 Marek Polacek <polacek@redhat.com>
5106 * c.opt (Wpointer-compare): New option.
5108 2017-01-04 Jakub Jelinek <jakub@redhat.com>
5111 * c.opt (fsso-struct=): Add RejectNegative.
5113 2017-01-01 Jakub Jelinek <jakub@redhat.com>
5115 Update copyright years.
5117 2016-12-29 Martin Liska <mliska@suse.cz>
5120 * c.opt (strong-eval-order): Add RejectNegative keyword.
5122 2016-12-22 Jason Merrill <jason@redhat.com>
5124 Implement P0522R0, matching of template template arguments.
5125 * c-cppbuiltin.c (c_cpp_builtins): Define
5126 __cpp_template_template_args.
5128 2016-12-21 Jakub Jelinek <jakub@redhat.com>
5131 * c-common.c (struct nonnull_arg_ctx): New type.
5132 (check_function_nonnull): Return bool instead of void. Use
5133 nonnull_arg_ctx as context rather than just location_t.
5134 (check_nonnull_arg): Adjust for the new context type, set
5135 warned_p to true if a warning has been diagnosed.
5136 (check_function_arguments): Return bool instead of void.
5137 * c-common.h (check_function_arguments): Adjust prototype.
5139 2016-12-21 Jason Merrill <jason@redhat.com>
5141 * c.opt (-fnew-ttp-matching): New flag.
5142 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
5144 2016-12-14 Martin Jambor <mjambor@suse.cz>
5146 * c-omp.c: Include omp-general.h instead of omp-low.h.
5147 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
5150 2016-12-14 Martin Sebor <msebor@redhat.com>
5153 * c-common.c (check_nonnull_arg): Disable when optimization
5156 2016-12-12 Marek Polacek <polacek@redhat.com>
5159 * c-common.c (attribute_fallthrough_p): Return false for
5162 2016-12-08 Martin Sebor <msebor@redhat.com>
5165 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
5167 2016-12-08 Martin Sebor <msebor@redhat.com>
5170 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
5173 2016-12-07 Martin Sebor <msebor@redhat.com>
5179 * c.opt (-Wstringop-overflow): New option.
5181 2016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
5183 * c-attribs.c (asan odr indicator): New attribute.
5184 (handle_asan_odr_indicator_attribute): New function.
5186 2016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
5188 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
5191 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
5193 * c-common.c (excess_precision_mode_join): New.
5194 (c_ts18661_flt_eval_method): New.
5195 (c_c11_flt_eval_method): Likewise.
5196 (c_flt_eval_method): Likewise.
5197 * c-common.h (excess_precision_mode_join): New.
5198 (c_flt_eval_method): Likewise.
5199 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
5200 (cpp_iec_559_value): Call it.
5201 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
5202 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
5203 __FLT_EVAL_METHOD_TS_18661_3__.
5205 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
5207 * c-opts.c (c_common_post_options): Add logic to handle the default
5208 case for -fpermitted-flt-eval-methods.
5210 2016-11-23 Paolo Bonzini <bonzini@gnu.org>
5212 * c.opt (Wexpansion-to-defined): New.
5214 2016-11-23 Jakub Jelinek <jakub@redhat.com>
5217 * c-pragma.c (handle_pragma_target): Don't replace
5218 current_target_pragma, but chainon the new args to the current one.
5220 2016-11-22 Nathan Sidwell <nathan@acm.org>
5222 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
5223 indentation and formatting.
5225 2016-11-21 Martin Sebor <msebor@redhat.com>
5227 * c.opt (-fprintf-return-value): Enable by default.
5229 2016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
5232 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
5233 * c-common.c (c_common_nodes_and_builtins): Initialize
5234 const_tm_ptr_type_node.
5236 2016-11-16 Marek Polacek <polacek@redhat.com>
5239 * c-common.c (c_add_case_label): Turn error_at calls into inform.
5241 2016-11-14 Jakub Jelinek <jakub@redhat.com>
5243 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
5245 2016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
5246 Richard Biener <rguenther@suse.de>
5248 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
5249 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
5250 * c.opt (fgimple): New option.
5252 2016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
5255 * c-common.h (warn_for_restrict): Declare.
5256 * c-warn.c: Include gcc-rich-location.h.
5257 (warn_for_restrict): New function.
5258 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
5259 (gcc_cdiag_char_table): Likewise.
5260 (gcc_cxxdiag_char_table): Likewise.
5261 * c.opt (Wrestrict): New option.
5263 2016-11-13 Eric Botcazou <ebotcazou@adacore.com>
5265 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
5266 for nested types only if the type is a record or union and dump SLOC.
5268 2016-11-09 Jason Merrill <jason@redhat.com>
5270 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
5272 2016-11-09 Jakub Jelinek <jakub@redhat.com>
5274 * c-ubsan.c (ubsan_instrument_shift): Handle split
5275 -fsanitize=shift-base and -fsanitize=shift-exponent.
5277 2016-11-07 Jason Merrill <jason@redhat.com>
5279 * c.opt (Wc++1z-compat): New.
5280 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
5282 2016-11-07 Martin Liska <mliska@suse.cz>
5284 * c-warn.c (warn_for_unused_label): Save all labels used
5285 in goto or in &label.
5287 2016-11-03 Jason Merrill <jason@redhat.com>
5289 * c-cppbuiltin.c (c_cpp_builtins): Correct
5290 __cpp_inheriting_constructors.
5292 2016-11-01 Jason Merrill <jason@redhat.com>
5294 * c-cppbuiltin.c (c_cpp_builtins): Update
5295 __cpp_inheriting_constructors.
5297 * c.opt (-fnew-inheriting-ctors): New.
5298 * c-opts.c: Default to on for ABI 11+.
5300 2016-10-31 Jakub Jelinek <jakub@redhat.com>
5303 * c.opt (fext-numeric-literals): Add Var and Init.
5304 * c-opts.c (c_common_handle_option): Don't clear
5305 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
5306 (c_common_post_options): Clear it here if not set
5309 2016-10-28 Aldy Hernandez <aldyh@redhat.com>
5312 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
5315 2016-10-25 Jakub Jelinek <jakub@redhat.com>
5317 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
5318 * c-common.c (c_common_reswords): Add __builtin_launder.
5320 2016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
5322 * c-common.c (c_common_truthvalue_conversion): Warn for
5323 multiplications in boolean context. Fix the quoting of '<<' and '<'
5324 in the shift warning.
5326 2016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
5328 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
5330 2016-10-20 Jason Merrill <jason@redhat.com>
5332 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
5334 2016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
5336 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
5337 integer shift ops in boolean context.
5339 2016-10-18 Aldy Hernandez <aldyh@redhat.com>
5341 * c.opt (Walloca): New.
5342 (Walloca-larger-than=): New.
5343 (Wvla-larger-than=): New.
5345 2016-10-17 Marek Polacek <polacek@redhat.com>
5347 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
5348 Return immediately when finding a match.
5349 (warn_tautological_cmp): Remove a boolean variable that is no longer
5352 2016-10-17 Marek Polacek <polacek@redhat.com>
5354 * c-attribs.c: New file.
5355 * c-common.c: Move attributes handling to c-attribs.c.
5356 (get_nonnull_operand): No longer static.
5357 * c-common.h: Move the declarations from c-attribs.c to its own section.
5359 2016-10-14 Jason Merrill <jason@redhat.com>
5361 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
5362 and __cpp_deduction_guides.
5364 2016-10-13 Jason Merrill <jason@redhat.com>
5366 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
5368 2016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
5370 * c-cppbuiltin.c: Include memmodel.h.
5371 * c-opts.c: Likewise.
5372 * c-pragma.c: Likewise.
5373 * c-warn.c: Likewise.
5375 2016-10-12 Jakub Jelinek <jakub@redhat.com>
5377 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
5378 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
5379 * c-opts.c (sanitize_cpp_opts): Initialize
5380 cpp_opts->cpp_warn_implicit_fallthrough.
5382 2016-10-11 Marek Polacek <polacek@redhat.com>
5384 * c-common.c (warning_candidate_p): Change the return type to bool
5385 and return true/false instead of 1/0.
5386 (vector_mode_valid_p): Likewise.
5388 2016-10-11 Marek Polacek <polacek@redhat.com>
5390 * c-common.c (fold_for_warn): No longer static.
5391 (bool_promoted_to_int_p): Likewise.
5392 (c_common_get_narrower): Likewise.
5393 (constant_expression_warning): Move to c-warn.c.
5394 (constant_expression_error): Likewise.
5395 (overflow_warning): Likewise.
5396 (warn_logical_operator): Likewise.
5397 (find_array_ref_with_const_idx_r): Likewise.
5398 (warn_tautological_cmp): Likewise.
5399 (expr_has_boolean_operands_p): Likewise.
5400 (warn_logical_not_parentheses): Likewise.
5401 (warn_if_unused_value): Likewise.
5402 (strict_aliasing_warning): Likewise.
5403 (sizeof_pointer_memaccess_warning): Likewise.
5404 (check_main_parameter_types): Likewise.
5405 (conversion_warning): Likewise.
5406 (warnings_for_convert_and_check): Likewise.
5407 (match_case_to_enum_1): Likewise.
5408 (match_case_to_enum): Likewise.
5409 (c_do_switch_warnings): Likewise.
5410 (warn_for_omitted_condop): Likewise.
5411 (readonly_error): Likewise.
5412 (lvalue_error): Likewise.
5413 (invalid_indirection_error): Likewise.
5414 (warn_array_subscript_with_type_char): Likewise.
5415 (warn_about_parentheses): Likewise.
5416 (warn_for_unused_label): Likewise.
5417 (warn_for_div_by_zero): Likewise.
5418 (warn_for_memset): Likewise.
5419 (warn_for_sign_compare): Likewise.
5420 (do_warn_double_promotion): Likewise.
5421 (do_warn_unused_parameter): Likewise.
5422 (record_locally_defined_typedef): Likewise.
5423 (maybe_record_typedef_use): Likewise.
5424 (maybe_warn_unused_local_typedefs): Likewise.
5425 (maybe_warn_bool_compare): Likewise.
5426 (maybe_warn_shift_overflow): Likewise.
5427 (warn_duplicated_cond_add_or_warn): Likewise.
5428 (diagnose_mismatched_attributes): Likewise.
5429 * c-common.h: Move the declarations from c-warn.c to its own section.
5430 * c-warn.c: New file.
5432 2016-10-08 Jason Merrill <jason@redhat.com>
5434 * c-common.c (c_common_truthvalue_conversion): Don't distribute
5435 into COND_EXPR in C++.
5437 2016-10-08 Jakub Jelinek <jakub@redhat.com>
5439 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
5440 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
5441 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
5443 2016-10-07 Jakub Jelinek <jakub@redhat.com>
5445 Implement LWG2296 helper intrinsic
5446 * c-common.h (enum rid): Add RID_ADDRESSOF.
5447 * c-common.c (c_common_reswords): Add __builtin_addressof.
5449 2016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
5452 * c-common.c (c_common_truthvalue_conversion): Warn also for
5453 suspicious enum values in boolean context.
5455 2016-10-06 Jakub Jelinek <jakub@redhat.com>
5457 Implement P0258R2 - helper for C++17
5458 std::has_unique_object_representations trait
5459 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
5460 * c-common.c (c_common_reswords): Add
5461 __has_unique_object_representations.
5463 2016-10-05 Jakub Jelinek <jakub@redhat.com>
5466 * c-ubsan.c (ubsan_instrument_return): Don't call
5467 initialize_sanitizer_builtins here.
5469 2016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
5471 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
5472 conditional expression in boolean context when only one arm is
5475 2016-10-05 Jakub Jelinek <jakub@redhat.com>
5478 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
5481 * c-common.c (c_common_reswords): Update comment for C++11.
5483 2016-10-04 Jason Merrill <jason@redhat.com>
5485 * c-common.c (make_tree_vector_from_ctor): New.
5486 * c-common.h: Declare it.
5488 2016-10-04 Jakub Jelinek <jakub@redhat.com>
5490 * c-cppbuiltin.c (c_cpp_builtins): Don't define
5491 __LIBGCC_JCR_SECTION_NAME__.
5493 2016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
5495 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
5496 left shift in boolean context.
5498 2016-09-29 Jakub Jelinek <jakub@redhat.com>
5500 Implement P0001R1 - C++17 removal of register storage class specifier
5501 * c.opt (Wregister): New warning.
5502 * c-opts.c (c_common_post_options): Enable -Wregister by
5505 2016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
5507 * c-opts.c (c_common_post_options): Remove special case for
5508 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
5511 2016-09-27 Jakub Jelinek <jakub@redhat.com>
5513 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
5516 * c-ada-spec.c (print_ada_declaration): Remove break after return.
5518 2016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
5520 * c-common.c: Include memmodel.h.
5522 2016-09-26 Marek Polacek <polacek@redhat.com>
5524 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
5526 2016-09-26 Marek Polacek <polacek@redhat.com>
5529 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
5530 (handle_fallthrough_attribute): New function.
5531 (attribute_fallthrough_p): New function.
5532 * c-common.h (attribute_fallthrough_p): Declare.
5534 2016-09-24 Marek Polacek <polacek@redhat.com>
5537 * c.opt (Wbool-operation): New.
5539 2016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
5541 * c-common.c (c_common_truthvalue_conversion): Inhibit
5542 Wint-in-bool-context warning with from_macro_definition_at.
5543 Mention the expression will always evaluate to true.
5545 2016-09-21 Martin Sebor <msebor@redhat.com>
5548 * c.opt (fprintf-return-value): Temporarily initialize to zero
5549 to unblock bootstrap failures.
5551 2016-09-21 Jakub Jelinek <jakub@redhat.com>
5554 * c.opt (Waligned-new=): Add RejectNegative.
5555 (faligned-new=): Likewise. Spelling fix - change
5556 aligned_new_threshhold to aligned_new_threshold.
5557 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
5558 to aligned_new_threshold.
5560 2016-09-20 Martin Sebor <msebor@redhat.com>
5563 * c.opt: Add -Wformat-length and -fprintf-return-value.
5565 2016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
5568 * c.opt (Wint-in-bool-context): New warning.
5569 * c-common.c (c_common_truthvalue_conversion): Warn on integer
5570 constants in boolean context.
5572 2016-09-19 Joseph Myers <joseph@codesourcery.com>
5574 * c-common.c (max_align_t_align): Also consider alignment of
5577 2016-09-15 Jason Merrill <jason@redhat.com>
5579 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
5582 2016-09-14 Jason Merrill <jason@redhat.com>
5584 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
5585 limit FIELD_DECL, either.
5587 2016-09-14 Marek Polacek <polacek@redhat.com>
5589 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
5590 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
5591 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
5593 2016-09-13 David Malcolm <dmalcolm@redhat.com>
5595 * c-common.c (warn_logical_not_parentheses): Replace
5596 rich_location::add_fixit_insert calls with add_fixit_insert_before
5597 and add_fixit_insert_after, eliminating the "next_loc" calculation.
5599 2016-09-13 Jason Merrill <jason@redhat.com>
5600 Tom de Vries <tom@codesourcery.com>
5603 * c-common.c (set_underlying_type): Don't treat array as builtin type.
5605 2016-09-13 Jason Merrill <jason@redhat.com>
5607 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
5610 2016-09-12 Jason Merrill <jason@redhat.com>
5612 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
5613 bit/byte confusion, allow large alignment for types.
5615 2016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
5618 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
5620 2016-09-12 David Malcolm <dmalcolm@redhat.com>
5623 * c-format.c (argument_parser::check_argument_type): Add params
5624 "type_start" and "conversion_char". Use the former to generate
5625 offset_to_type_start and pass it and conversion_char to
5627 (check_format_info_main): Capture the start of the type
5628 information as "type_start", and pass it an format_char
5629 to arg_parser.check_argument_type.
5630 (check_format_types): Provide an example in the leading comment.
5631 Add params "offset_to_type_start" and "conversion_char"; pass
5632 them to format_type_warning calls.
5633 (test_get_modifier_for_format_len): Likewise.
5634 (matching_type_p): New function.
5635 (get_format_for_type): Add param "conversion_char" and move
5636 implementation into...
5637 (get_format_for_type_1): ...new function, called twice.
5638 Use new function matching_type_p rather than checking for
5639 TYPE_CANONICAL equality.
5640 (get_corrected_substring): New function.
5641 (format_type_warning): Provide an example in the leading comment.
5642 Add params "offset_to_type_start" and "conversion_char". Replace
5643 call to get_format_for_type with call to get_corrected_substring
5644 and move rejection of hints for widths/precisions there.
5645 (assert_format_for_type_streq): Add param "conversion_char".
5646 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
5647 (test_get_format_for_type_printf): Add conversion chars to the
5648 tests, adding coverage for various combinations of integer
5649 vs double conversions, and for preserving octal and hexadecimal
5651 (test_get_format_for_type_scanf): Add conversion chars to the
5654 2016-09-10 Tom de Vries <tom@codesourcery.com>
5657 * c-common.c (build_va_arg): Handle more strict
5658 targetm.canonical_va_list_type. Replace first argument type error with
5661 2016-09-09 Martin Sebor <msebor@redhat.com>
5665 * c-format.c (argument_parser::find_format_char_info): Use %qc
5666 format directive unconditionally.
5668 2016-09-09 Jason Merrill <jason@redhat.com>
5670 Implement C++17 new of over-aligned types.
5671 * c.opt: Add -faligned-new and -Waligned-new.
5672 * c-common.c (max_align_t_align): Split out from...
5673 (cxx_fundamental_alignment_p): ...here.
5674 * c-common.h: Declare it.
5675 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
5677 2016-09-09 Joseph Myers <joseph@codesourcery.com>
5679 * c-cppbuiltin.c (builtin_define_type_width): New function.
5680 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
5683 2016-09-07 David Malcolm <dmalcolm@redhat.com>
5685 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
5687 (substring_loc::get_location): Move to substring-locations.c,
5688 keeping implementation as...
5689 (c_get_substring_location): New function, from the above, reworked
5690 to use accessors rather than member lookup.
5691 * c-common.h (class substring_loc): Move to substring-locations.h,
5692 replacing with a forward decl.
5693 (c_get_substring_location): New decl.
5694 * c-format.c: Include "substring-locations.h".
5695 (format_warning_va): Move to substring-locations.c.
5696 (format_warning_at_substring): Likewise.
5698 2016-09-06 Martin Sebor <msebor@redhat.com>
5701 * c-format.c (check_function_format): Avoid issuing warnings for
5702 functions unless they call format functions with non-constant
5705 2016-09-06 Richard Biener <rguenther@suse.de>
5708 * c-common.c (c_common_mark_addressable_vec): Handle
5709 COMPOUND_LITERAL_EXPR.
5711 2016-09-05 Marek Polacek <polacek@redhat.com>
5714 * c-common.c (bool_promoted_to_int_p): New function.
5715 (expr_has_boolean_operands_p): New function.
5716 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
5717 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
5719 2016-09-04 Tom de Vries <tom@codesourcery.com>
5722 2016-08-29 Tom de Vries <tom@codesourcery.com>
5724 * c-common.c (build_va_arg): Replace first argument type error
5727 2016-09-02 Jakub Jelinek <jakub@redhat.com>
5730 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
5731 (c_finish_omp_for): Reject _Atomic qualified iterators.
5733 2016-09-01 Martin Sebor <msebor@redhat.com>
5735 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
5736 size to guarantee it fits the output of the formatted function
5737 regardless of its arguments.
5739 2016-09-01 Marek Polacek <polacek@redhat.com>
5742 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
5745 2016-08-29 Marek Polacek <polacek@redhat.com>
5748 * c-common.c (warn_logical_not_parentheses): Don't warn for
5749 a comparison or a logical operator.
5751 2016-08-29 Tom de Vries <tom@codesourcery.com>
5753 * c-common.c (build_va_arg): Fix type comparison assert.
5755 2016-08-29 Tom de Vries <tom@codesourcery.com>
5757 * c-common.c (build_va_arg): Replace first argument type error
5760 2016-08-29 Tom de Vries <tom@codesourcery.com>
5763 * c-common.c (build_va_arg): Add first argument error. Build va_arg
5764 with error_mark_node as va_list instead of with illegal va_list.
5766 2016-08-25 Marek Polacek <polacek@redhat.com>
5767 David Malcolm <dmalcolm@redhat.com>
5769 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
5770 * c-common.h (warn_logical_not_parentheses): Update declaration.
5772 2016-08-22 Marek Polacek <polacek@redhat.com>
5775 * c-common.c (warn_for_memset): Check type for null.
5777 2016-08-22 Joseph Myers <joseph@codesourcery.com>
5779 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
5780 _FloatNx types for suffixes for built-in functions.
5782 2016-08-19 Joseph Myers <joseph@codesourcery.com>
5785 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
5786 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
5787 (RID_FLOAT128X): New enum rid values.
5788 (CASE_RID_FLOATN_NX): New macro.
5789 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
5791 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
5792 corresponding complex types.
5793 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
5794 _FloatNx and corresponding complex types.
5795 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
5796 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
5797 and _FloatNx types for the widest type for determining
5798 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
5799 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
5800 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
5802 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
5804 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
5807 2016-08-18 David Malcolm <dmalcolm@redhat.com>
5809 * c-opts.c (c_diagnostic_finalizer): Update for change to
5810 diagnostic_show_locus.
5812 2016-08-18 David Malcolm <dmalcolm@redhat.com>
5814 * c-common.c: Include "spellcheck.h".
5815 (cb_get_suggestion): New function.
5816 * c-common.h (cb_get_suggestion): New decl.
5817 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
5820 2016-08-18 Marek Polacek <polacek@redhat.com>
5823 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
5826 2016-08-16 David Malcolm <dmalcolm@redhat.com>
5829 * c-common.c (substring_loc::get_range): Rename to...
5830 (substring_loc::get_location): ...this, converting param from a
5831 source_range * to a location_t *. Call
5832 get_source_location_for_substring rather than
5833 get_source_range_for_substring, and pass in m_caret_idx.
5834 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
5835 (substring_loc::get_range): Replace with...
5836 (substring_loc::get_location): ...this.
5837 (substring_loc::set_caret_index): New method.
5838 (substring_loc): Add field m_caret_idx.
5839 * c-format.c (format_warning_va): Update for above changes.
5840 Rename local "substring_loc" to "fmt_substring_loc" to avoid
5841 clashing with type name.
5842 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
5843 (check_argument_type): Likewise.
5844 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
5845 Use a copy when emitting warnings, setting the caret index from TYPE.
5847 2016-08-16 Eric Botcazou <ebotcazou@adacore.com>
5848 Arnaud Charlet <charlet@adacore.com>
5850 * c-ada-spec.c (dump_number): New function.
5851 (handle_escape_character): Likewise.
5852 (print_ada_macros): Add handling of constant integers and strings.
5854 2016-08-12 Marek Polacek <polacek@redhat.com>
5857 * c-common.c (scalar_to_vector): Adjust fall through comment.
5858 * c-opts.c (c_common_handle_option): Likewise.
5859 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
5860 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
5861 fall through comment.
5862 * cilk.c (extract_free_variables): Add FALLTHRU.
5864 2016-08-10 Jason Merrill <jason@redhat.com>
5866 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
5868 2016-08-09 Jason Merrill <jason@redhat.com>
5870 * c-common.c (c_common_attribute_table): vector_size affects type
5873 2016-08-09 Marek Polacek <polacek@redhat.com>
5876 * c-ada-spec.c (dump_generic_ada_node): Add return.
5878 2016-08-09 Jason Merrill <jason@redhat.com>
5880 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
5881 C++17 constexpr lambdas.
5883 2016-08-08 David Malcolm <dmalcolm@redhat.com>
5886 * c-common.h (selftest::c_format_c_tests): New declaration.
5887 (selftest::run_c_tests): New declaration.
5888 * c-format.c: Include "selftest.h.
5889 (format_warning_va): Add param "corrected_substring" and use
5890 it to add a replacement fix-it hint.
5891 (format_warning_at_substring): Likewise.
5892 (format_warning_at_char): Update for new param of
5894 (argument_parser::check_argument_type): Pass "fki" to
5896 (check_format_types): Add param "fki" and pass it to
5897 format_type_warning.
5898 (deref_n_times): New function.
5899 (get_modifier_for_format_len): New function.
5900 (selftest::test_get_modifier_for_format_len): New function.
5901 (get_format_for_type): New function.
5902 (format_type_warning): Add param "fki" and use it to attempt
5903 to provide hints for argument types when calling
5904 format_warning_at_substring.
5905 (selftest::get_info): New function.
5906 (selftest::assert_format_for_type_streq): New function.
5907 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
5908 (selftest::test_get_format_for_type_printf): New function.
5909 (selftest::test_get_format_for_type_scanf): New function.
5910 (selftest::c_format_c_tests): New function.
5912 2016-08-08 David Malcolm <dmalcolm@redhat.com>
5915 * c-format.c: Include "diagnostic.h".
5916 (location_column_from_byte_offset): Delete.
5917 (location_from_offset): Delete.
5918 (format_warning_va): New function.
5919 (format_warning_at_substring): New function.
5920 (format_warning_at_char): New function.
5921 (check_format_arg): Capture location of format_tree and pass to
5922 check_format_info_main.
5923 (argument_parser): Add fields "start_of_this_format" and
5924 "format_string_cst".
5925 (flag_chars_t::validate): Add param "format_string_cst". Convert
5926 warning_at call using location_from_offset to call to
5927 format_warning_at_char.
5928 (argument_parser::argument_parser): Add param "format_string_cst_"
5929 and use use it to initialize field "format_string_cst".
5930 Initialize new field "start_of_this_format".
5931 (argument_parser::read_format_flags): Convert warning_at call
5932 using location_from_offset to a call to format_warning_at_char.
5933 (argument_parser::read_any_format_left_precision): Likewise.
5934 (argument_parser::read_any_format_precision): Likewise.
5935 (argument_parser::read_any_other_modifier): Likewise.
5936 (argument_parser::find_format_char_info): Likewise, in three places.
5937 (argument_parser::parse_any_scan_set): Likewise, in one place.
5938 (argument_parser::handle_conversions): Likewise, in two places.
5939 (argument_parser::check_argument_type): Add param "fmt_param_loc"
5940 and use it to make a substring_loc. Pass the latter to
5942 (check_format_info_main): Add params "fmt_param_loc" and
5943 "format_string_cst". Convert warning_at calls using
5944 location_from_offset to calls to format_warning_at_char. Pass the
5945 new params to the arg_parser ctor. Pass "format_string_cst" to
5946 flag_chars.validate. Pass "fmt_param_loc" to
5947 arg_parser.check_argument_type.
5948 (check_format_types): Convert first param from a location_t
5949 to a const substring_loc & and rename to "fmt_loc". Attempt
5950 to extract the range of the relevant parameter and pass it
5951 to format_type_warning.
5952 (format_type_warning): Convert first param from a location_t
5953 to a const substring_loc & and rename to "fmt_loc". Add
5954 params "param_range" and "type". Replace calls to warning_at
5955 with calls to format_warning_at_substring.
5957 2016-08-08 David Malcolm <dmalcolm@redhat.com>
5959 * c-format.c (class flag_chars_t): New class.
5960 (struct length_modifier): New struct.
5961 (class argument_parser): New class.
5962 (flag_chars_t::flag_chars_t): New ctor.
5963 (flag_chars_t::has_char_p): New method.
5964 (flag_chars_t::add_char): New method.
5965 (flag_chars_t::validate): New method.
5966 (flag_chars_t::get_alloc_flag): New method.
5967 (flag_chars_t::assignment_suppression_p): New method.
5968 (argument_parser::argument_parser): New ctor.
5969 (argument_parser::read_any_dollar): New method.
5970 (argument_parser::read_format_flags): New method.
5971 (argument_parser::read_any_format_width): New method.
5972 (argument_parser::read_any_format_left_precision): New method.
5973 (argument_parser::read_any_format_precision): New method.
5974 (argument_parser::handle_alloc_chars): New method.
5975 (argument_parser::read_any_length_modifier): New method.
5976 (argument_parser::read_any_other_modifier): New method.
5977 (argument_parser::find_format_char_info): New method.
5978 (argument_parser::validate_flag_pairs): New method.
5979 (argument_parser::give_y2k_warnings): New method.
5980 (argument_parser::parse_any_scan_set): New method.
5981 (argument_parser::handle_conversions): New method.
5982 (argument_parser::check_argument_type): New method.
5983 (check_format_info_main): Introduce classes argument_parser
5984 and flag_chars_t, moving the code within the loop into methods
5985 of these classes. Make various locals "const".
5987 2016-08-05 David Malcolm <dmalcolm@redhat.com>
5989 * c-common.c: Include "substring-locations.h".
5990 (get_cpp_ttype_from_string_type): New function.
5991 (g_string_concat_db): New global.
5992 (substring_loc::get_range): New method.
5993 * c-common.h (g_string_concat_db): New declaration.
5994 (class substring_loc): New class.
5995 * c-lex.c (lex_string): When concatenating strings, capture the
5996 locations of all tokens using a new obstack, and record the
5997 concatenation locations within g_string_concat_db.
5998 * c-opts.c (c_common_init_options): Construct g_string_concat_db
6001 2016-07-29 Marek Polacek <polacek@redhat.com>
6004 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
6005 parentheses warning.
6008 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
6010 2016-07-28 Martin Liska <mliska@suse.cz>
6012 PR gcov-profile/68025
6013 * c-common.c (handle_no_profile_instrument_function_attribute):
6015 2016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
6017 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
6020 2016-07-25 Jason Merrill <jason@redhat.com>
6023 * c.opt (fconstexpr-loop-limit): New.
6025 2016-07-22 Martin Sebor <msebor@redhat.com>
6028 * c-common.c (resolve_overloaded_builtin): Avoid converting
6029 __atomic_compare_exchange_n return type to that of what its
6030 first argument points to.
6032 2016-07-22 Uros Bizjak <ubizjak@gmail.com>
6034 * c-common.c: Use HOST_WIDE_INT_M1U instead of
6035 ~(unsigned HOST_WIDE_INT) 0.
6037 2016-07-22 Martin Liska <mliska@suse.cz>
6039 PR gcov-profile/69028
6040 PR gcov-profile/62047
6041 * cilk.c (create_cilk_helper_decl): Set location of a new decl
6042 to the current_function_decl.
6044 2016-07-21 Jason Merrill <jason@redhat.com>
6047 * c-common.c (c_common_truthvalue_conversion): Check
6048 c_inhibit_evaluation_warnings for warning about address of
6051 2016-07-20 David Malcolm <dmalcolm@redhat.com>
6053 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
6056 2016-07-15 Jason Merrill <jason@redhat.com>
6058 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
6060 2016-07-15 Jakub Jelinek <jakub@redhat.com>
6063 * c-common.h (enum lookup_name_fuzzy_kind): Add
6064 FUZZY_LOOKUP_FUNCTION_NAME.
6066 2016-07-08 Jason Merrill <jason@redhat.com>
6068 P0145: Refining Expression Order for C++.
6069 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
6072 2016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
6075 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
6077 2016-06-29 Thomas Schwinge <thomas@codesourcery.com>
6079 * c-pragma.h (enum pragma_kind): Rename
6080 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
6083 2016-06-29 Richard Biener <rguenther@suse.de>
6086 * c-common.c (c_common_get_alias_set): Remove union type punning case.
6088 2016-06-24 Jason Merrill <jason@redhat.com>
6090 P0145R2: Refining Expression Order for C++.
6091 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
6094 2016-06-24 Jakub Jelinek <jakub@redhat.com>
6096 * c-common.c (check_builtin_function_arguments): Require last
6097 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
6098 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
6099 if the last argument is pointer to enumerated or boolean type.
6101 2016-06-22 David Malcolm <dmalcolm@redhat.com>
6104 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
6105 (lookup_name_fuzzy): New prototype.
6107 2016-06-21 John David Anglin <danglin@gcc.gnu.org>
6109 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
6111 2016-06-14 Jason Merrill <jason@redhat.com>
6113 P0145R2: Refining Expression Order for C++.
6114 * c.opt (fargs-in-order): New.
6115 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
6117 2016-06-13 Jakub Jelinek <jakub@redhat.com>
6120 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
6121 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
6123 PR preprocessor/71183
6124 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
6125 to cb_get_source_date_epoch.
6127 2016-06-10 Jakub Jelinek <jakub@redhat.com>
6130 * c.opt (Wpsabi): Add Warning flag.
6132 2016-06-10 Martin Sebor <msebor@redhat.com>
6135 * c-common.c (handle_nonnull_attribute): Accept
6136 the nonnull attribute in type-generic builtins.
6138 2016-06-09 Martin Sebor <msebor@redhat.com>
6141 * c-common.c (builtin_function_validate_nargs): Make text of error
6142 message consistent with others like it.
6144 2016-06-08 Martin Sebor <msebor@redhat.com>
6145 Jakub Jelinek <jakub@redhat.com>
6149 * c-common.c (check_builtin_function_arguments): Handle
6150 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
6152 2016-06-08 Richard Biener <rguenther@suse.de>
6154 * c-common.c (parse_optimize_options): Improve diagnostic messages.
6156 2016-06-07 Richard Biener <rguenther@suse.de>
6159 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
6160 options and warn about others.
6162 2016-06-01 Eduard Sanou <dhole@openmailbox.org>
6164 * c-common.c (get_source_date_epoch): Rename to
6165 cb_get_source_date_epoch.
6166 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
6167 message when the parsing fails. Use error_at instead of fatal_error.
6168 * c-common.h (get_source_date_epoch): Rename to
6169 cb_get_source_date_epoch.
6170 * c-common.h (cb_get_source_date_epoch): Prototype.
6171 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
6172 * c-common.h (c_omp_region_type): Remove trailing comma.
6173 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
6174 * c-lex.c (c_lex_with_flags): Remove initialization of
6175 pfile->source_date_epoch.
6177 2016-05-30 Jakub Jelinek <jakub@redhat.com>
6180 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
6181 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
6182 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
6183 instead of C_OMP_CLAUSE_SPLIT_FOR.
6185 2016-05-24 Richard Biener <rguenther@suse.de>
6189 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
6190 (convert_vector_to_array_for_subscript): ... this.
6191 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
6192 VIEW_CONVERT_EXPR to an array type. Rename to ...
6193 (convert_vector_to_array_for_subscript): ... this.
6195 2016-05-12 Marek Polacek <polacek@redhat.com>
6198 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
6199 size_in_bytes and pass LOC to it.
6201 2016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
6204 * c.opt (Wduplicate-decl-specifier): New option.
6206 2016-05-11 Marek Polacek <polacek@redhat.com>
6209 * c-common.c (diagnose_mismatched_attributes): New function.
6210 * c-common.h (diagnose_mismatched_attributes): Declare.
6212 2016-05-04 Marek Polacek <polacek@redhat.com>
6214 * c.opt (Wdangling-else): New option.
6216 2016-05-03 Marek Polacek <polacek@redhat.com>
6219 * c-common.c (builtin_function_validate_nargs): Add location
6221 (check_builtin_function_arguments): Add location and arguments
6222 parameters. Use them.
6223 * c-common.h (check_builtin_function_arguments): Update declaration.
6225 2016-05-03 Richard Biener <rguenther@suse.de>
6227 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
6228 allow call args to gimplify to SSA names.
6230 2016-05-03 Marek Polacek <polacek@redhat.com>
6232 * c-common.h (enum c_omp_region_type): Remove stray comma.
6234 2016-05-02 Cesar Philippidis <cesar@codesourcery.com>
6236 * c-common.h (enum c_omp_region_type): Define.
6238 2016-05-02 Richard Sandiford <richard.sandiford@arm.com>
6240 * c-common.c (shorten_compare): Use wi::to_wide.
6242 2016-04-29 Cesar Philippidis <cesar@codesourcery.com>
6245 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
6246 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
6247 reduction clauses in acc parallel loops.
6249 2016-04-29 Marek Polacek <polacek@redhat.com>
6252 * c-common.c (warn_for_memset): Check domain before accessing it.
6254 2016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
6257 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
6258 "aligned" attribute.
6260 2016-04-28 Jason Merrill <jason@redhat.com>
6262 * c-lex.c (c_common_has_attribute): Handle nodiscard.
6264 2016-04-28 Eduard Sanou <dhole@openmailbox.org>
6265 Matthias Klose <doko@debian.org>
6267 * c-common.c (get_source_date_epoch): New function, gets the environment
6268 variable SOURCE_DATE_EPOCH and parses it as long long with error
6270 * c-common.h (get_source_date_epoch): Prototype.
6271 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
6273 2015-04-27 Ryan Burn <contact@rnburn.com>
6277 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
6278 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
6280 (cilk_detect_and_unwrap): Corresponding changes.
6281 (extract_free_variables): Don't extract free variables from
6282 AGGR_INIT_EXPR slot.
6283 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
6284 (cilk_recognize_spawn): Likewise.
6286 2016-04-27 Bernd Schmidt <bschmidt@redhat.com>
6288 * c.opt (Wmemset-elt-size): New option.
6289 * c-common.c (warn_for_memset): New function.
6290 * c-common.h (warn_for_memset): Declare.
6292 2016-04-25 Jason Merrill <jason@redhat.com>
6294 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
6296 * c-common.h: Declare it.
6297 * c-lex.c (c_common_has_attribute): Add maybe_unused.
6299 2016-04-22 Jason Merrill <jason@redhat.com>
6301 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
6303 2016-04-20 Ilya Verbin <ilya.verbin@intel.com>
6306 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
6307 * c-common.h (c_finish_cilk_clauses): Remove declaration.
6309 2016-04-18 Michael Matz <matz@suse.de>
6311 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
6314 2016-04-17 Eric Botcazou <ebotcazou@adacore.com>
6316 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
6317 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
6318 to incomplete types.
6319 (dump_nested_type): Remove redundant tests and tidy up.
6320 (print_ada_declaration): Also set TREE_VISITED on the declaration of
6321 a type which is the typedef of an original type.
6323 2016-04-15 Marek Polacek <polacek@redhat.com>
6326 * c-common.c (build_va_arg): Change two asserts into errors and return
6329 2016-04-13 Marek Polacek <polacek@redhat.com>
6332 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
6333 for switch statements, too.
6335 2016-03-28 Jason Merrill <jason@redhat.com>
6337 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
6339 2016-03-23 Marek Polacek <polacek@redhat.com>
6342 * c.opt (Wignored-attributes): New option.
6344 2016-03-22 David Malcolm <dmalcolm@redhat.com>
6347 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
6348 diagnostic text, reversing the order of the warning and note so
6349 that they appear in source order.
6351 2016-03-17 Marek Polacek <polacek@redhat.com>
6354 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
6357 2016-03-14 Jason Merrill <jason@redhat.com>
6359 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
6361 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
6363 2016-03-09 Richard Biener <rguenther@suse.de>
6366 * c-common.c (strict_aliasing_warning): Add back
6367 alias_sets_conflict_p check.
6369 2016-03-08 Jason Merrill <jason@redhat.com>
6371 * c-opts.c (set_std_cxx1z): Don't enable concepts.
6373 2016-03-04 David Malcolm <dmalcolm@redhat.com>
6376 * c-indentation.c (get_visual_column): Move code to determine next
6378 (next_tab_stop): ...this new function.
6379 (line_contains_hash_if): Delete function.
6380 (detect_preprocessor_logic): Delete function.
6381 (get_first_nws_vis_column): New function.
6382 (detect_intervening_unindent): New function.
6383 (should_warn_for_misleading_indentation): Replace call to
6384 detect_preprocessor_logic with a call to
6385 detect_intervening_unindent.
6387 2016-03-04 David Malcolm <dmalcolm@redhat.com>
6390 * c-indentation.c (should_warn_for_misleading_indentation): When
6391 suppressing warnings about cases where the guard and body are on
6392 the same column, only use the first non-whitespace column in place
6393 of the guard token column when dealing with "else" clauses.
6394 When rejecting aligned BODY and NEXT, loosen the requirement
6395 from equality with the first non-whitespace of guard to simply
6396 that they not be indented relative to it.
6398 2016-03-04 Richard Biener <rguenther@suse.de>
6401 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
6402 instead of alias_sets_conflict_p.
6404 2016-03-01 Marek Polacek <polacek@redhat.com>
6407 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
6410 2016-02-22 Martin Sebor <msebor@redhat.com>
6413 * c-common.c (check_builtin_function_arguments): Validate and
6414 reject invalid arguments to __builtin_alloca_with_align.
6416 2016-02-20 Mark Wielaard <mjw@redhat.com>
6419 * c.opt (Wunused-const-variable): Turn into Alias for...
6420 (Wunused-const-variable=): New option.
6422 2016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
6425 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
6427 (c_common_init_options): ...to here.
6428 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
6430 2016-02-19 Jakub Jelinek <jakub@redhat.com>
6433 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
6434 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
6435 flag_preprocess_only.
6437 2016-02-16 Jakub Jelinek <jakub@redhat.com>
6440 * c.opt (Wnonnull-compare): Enable for -Wall.
6442 2016-02-15 Jakub Jelinek <jakub@redhat.com>
6445 * c-common.c (sync_resolve_size): Diagnose too few arguments
6446 even when params is non-NULL empty vector.
6448 2016-02-08 Bernd Schmidt <bschmidt@redhat.com>
6451 * c.opt (fshort-double): Remove.
6453 2016-02-05 Martin Sebor <msebor@redhat.com>
6456 * c.opt (Warning options): Update -Wplacement-new to take
6457 an optional argument.
6459 2016-02-01 Jakub Jelinek <jakub@redhat.com>
6461 PR preprocessor/69543
6463 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
6464 instead of loc to control_warning_option.
6466 2016-02-01 Nathan Sidwell <nathan@codesourcery.com>
6468 * c.opt (fopenacc-dim=): New option.
6470 2016-01-27 Ryan Burn <contact@rnburn.com>
6473 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
6474 gimplify_arg. Removed superfluous post_p argument.
6475 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
6476 superfluous post_p argument.
6477 * c-gimplify.c (c_gimplify_expr): Likewise.
6479 2016-01-26 David Malcolm <dmalcolm@redhat.com>
6482 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
6483 pp_newline_and_flush with pp_flush.
6485 2016-01-20 Martin Sebor <msebor@redhat.com>
6488 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
6489 an incompatible argument when the argument isn't a valid tree node.
6491 2016-01-18 Jason Merrill <jason@redhat.com>
6494 * c-common.c (check_function_arguments_recurse): Fold the whole
6495 COND_EXPR, not just the condition.
6497 2016-01-18 Tom de Vries <tom@codesourcery.com>
6499 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
6500 classify as loop clause.
6502 2016-01-15 Jakub Jelinek <jakub@redhat.com>
6505 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
6506 C++ FE no longer has limit on number of pragmas.
6508 2015-01-14 Ryan Burn <contact@rnburn.com>
6511 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
6512 to add missing cleanup point.
6514 2016-01-14 David Malcolm <dmalcolm@redhat.com>
6517 * c-indentation.c (get_visual_column): Add location_t param.
6518 Handle the column number being zero by effectively disabling the
6519 warning, with an "inform".
6520 (should_warn_for_misleading_indentation): Add location_t argument
6521 for all uses of get_visual_column.
6523 2016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
6526 * c-indentation.c (should_warn_for_misleading_indentation):
6527 Don't warn about do-while statements.
6529 2016-01-07 Martin Sebor <msebor@redhat.com>
6532 * c-common.c (sync_resolve_size): Reject first argument when it's
6535 2016-01-05 David Malcolm <dmalcolm@redhat.com>
6538 * c-indentation.c (get_visual_column): Remove default argument.
6539 (should_warn_for_misleading_indentation): For the multiline case,
6540 update call to get_visual_column for next_stmt_exploc so that it
6541 captures the location of the first non-whitespace character in the
6542 relevant line. Don't issue warnings if there is non-whitespace
6543 before the next statement.
6545 2016-01-04 Jakub Jelinek <jakub@redhat.com>
6547 Update copyright years.
6549 2015-12-21 David Malcolm <dmalcolm@redhat.com>
6551 * c-common.c (binary_op_error): Convert first param from
6552 location_t to rich_location * and use it when emitting an error.
6553 * c-common.h (binary_op_error): Convert first param from
6554 location_t to rich_location *.
6556 2015-12-16 David Malcolm <dmalcolm@redhat.com>
6558 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
6559 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
6561 2015-12-15 Ilya Verbin <ilya.verbin@intel.com>
6563 * c-common.c (c_common_attribute_table): Handle "omp declare target
6566 2015-12-14 Jakub Jelinek <jakub@redhat.com>
6569 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
6571 2014-12-12 Tobias Burnus <burnus@net-b.de>
6574 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
6575 specifiers (%d, %i,%u and %c).
6577 2015-12-10 David Malcolm <dmalcolm@redhat.com>
6579 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
6581 2015-12-08 Jakub Jelinek <jakub@redhat.com>
6585 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
6586 * c-pragma.c (handle_pragma_diagnostic): Adjust
6587 control_warning_option caller.
6589 2015-12-07 David Malcolm <dmalcolm@redhat.com>
6591 * c-common.c (c_cpp_error): Update for change to
6592 rich_location::set_range.
6594 2015-12-04 Paolo Bonzini <bonzini@gnu.org>
6596 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
6597 shifting 1 out of the sign bit.
6599 2015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
6601 * c-common.c (c_common_attribute_table[]): Update max arguments
6602 count for "simd" attribute.
6603 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
6605 2015-12-03 Jakub Jelinek <jakub@redhat.com>
6607 PR preprocessor/57580
6608 * c-ppoutput.c (print): Change printed field to bool.
6609 Move src_file last for smaller padding.
6610 (init_pp_output): Set print.printed to false instead of 0.
6611 (scan_translation_unit): Fix up formatting. Set print.printed
6612 to true after printing something other than newline.
6613 (scan_translation_unit_trad): Set print.printed to true instead of 1.
6614 (maybe_print_line_1): Set print.printed to false instead of 0.
6615 (print_line_1): Likewise.
6616 (do_line_change): Set print.printed to true instead of 1.
6617 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
6618 dump_macro): Set print.printed to false after printing newline.
6620 2015-12-02 Jason Merrill <jason@redhat.com>
6622 * c-common.c (fold_for_warn): New.
6623 (warn_logical_operator, warn_tautological_cmp)
6624 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
6626 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
6627 (c_fully_fold_internal, decl_constant_value_for_optimization):
6629 * c-common.h: Don't declare decl_constant_value_for_optimization.
6631 2015-12-02 Joseph Myers <joseph@codesourcery.com>
6634 * c-common.h (c_build_qualified_type): Add extra default
6637 2015-12-01 Julian Brown <julian@codesourcery.com>
6638 Cesar Philippidis <cesar@codesourcery.com>
6639 James Norris <James_Norris@mentor.com>
6641 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
6642 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
6643 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
6645 2015-11-30 Eric Botcazou <ebotcazou@adacore.com>
6647 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
6648 (decl_sloc_common): Delete and move bulk of processing to...
6649 (decl_sloc): ...here.
6650 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
6651 (dump_ada_double_name): Remove S parameter and compute the suffix.
6652 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
6653 element type and deal with an anonymous one.
6654 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
6655 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
6656 and remove reference to QUAL_UNION_TYPE.
6657 (dump_nested_types): Make 2 passes on the fields and move bulk to...
6658 (dump_nested_type): ...here. New function extracted from above.
6659 Generate a full declaration for anonymous element type of arrays.
6660 (print_ada_declaration): Really skip anonymous declarations. Remove
6661 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
6662 Clean up processing of declarations of array types and objects.
6663 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
6664 Remove obsolete code and tidy up.
6666 2015-11-29 Jan Hubicka <hubicka@ucw.cz>
6669 * c-common.c (handle_transparent_union_attribute): Update
6672 2015-11-27 Martin Liska <mliska@suse.cz>
6675 * array-notation-common.c (cilkplus_extract_an_triplets):
6676 Release vector of vectors.
6677 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
6679 2015-11-26 Eric Botcazou <ebotcazou@adacore.com>
6682 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
6683 (print_ada_struct_decl): Likewise.
6685 2015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
6688 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
6689 * cilk.c (recognize_spawn): Determine location in a more precise
6692 2015-11-19 Jason Merrill <jason@redhat.com>
6694 * c-common.c (shorten_compare): But look through macros from
6697 2015-11-18 Jason Merrill <jason@redhat.com>
6699 * c-common.c (shorten_compare): Don't -Wtype-limits if the
6700 non-constant operand comes from a macro.
6702 2015-11-17 Jason Merrill <jason@redhat.com>
6705 * c-common.c (warn_tautological_cmp): Fold before checking for
6708 2015-11-16 Marek Polacek <polacek@redhat.com>
6711 * c-common.c (check_case_bounds): Fold low and high cases.
6713 2015-11-16 Marek Polacek <polacek@redhat.com>
6715 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
6716 * c-common.c (c_common_get_alias_set): Likewise.
6717 (handle_visibility_attribute): Likewise.
6719 2015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
6721 * c-common.c (handle_simd_attribute): New.
6722 (struct attribute_spec): Add entry for "simd".
6723 (handle_simd_attribute): New.
6725 2015-11-13 Kai Tietz <ktietz70@googlemail.com>
6727 * c-lex.c (interpret_float): Use fold_convert.
6729 2015-11-13 David Malcolm <dmalcolm@redhat.com>
6731 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
6732 and store it on the result.
6733 * c-opts.c (c_common_init_options): Set
6734 global_dc->colorize_source_p.
6736 2015-11-12 James Norris <jnorris@codesourcery.com>
6737 Joseph Myers <joseph@codesourcery.com>
6739 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
6740 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
6741 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
6742 PRAGMA_OACC_CLAUSE_LINK.
6744 2015-11-11 Marek Polacek <polacek@redhat.com>
6748 * c-common.c (valid_array_size_p): New function.
6749 * c-common.h (valid_array_size_p): Declare.
6751 2015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
6754 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
6756 2015-11-11 Andrew MacLeod <amacleod@redhat.com>
6758 * array-notation-common.c: Remove unused header files.
6759 * c-ada-spec.c: Likewise.
6760 * c-cilkplus.c: Likewise.
6761 * c-common.c: Likewise.
6762 * c-cppbuiltin.c: Likewise.
6763 * c-dump.c: Likewise.
6764 * c-format.c: Likewise.
6765 * c-gimplify.c: Likewise.
6766 * c-indentation.c: Likewise.
6767 * c-lex.c: Likewise.
6768 * c-omp.c: Likewise.
6769 * c-opts.c: Likewise.
6770 * c-pch.c: Likewise.
6771 * c-ppoutput.c: Likewise.
6772 * c-pragma.c: Likewise.
6773 * c-pretty-print.c: Likewise.
6774 * c-semantics.c: Likewise.
6775 * c-ubsan.c: Likewise.
6777 * stub-objc.c: Likewise.
6779 2015-11-09 Thomas Schwinge <thomas@codesourcery.com>
6780 Cesar Philippidis <cesar@codesourcery.com>
6781 James Norris <jnorris@codesourcery.com>
6782 Julian Brown <julian@codesourcery.com>
6783 Nathan Sidwell <nathan@codesourcery.com>
6785 * c-pragma.c (oacc_pragmas): Add "routine".
6786 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
6788 2015-11-08 Eric Botcazou <ebotcazou@adacore.com>
6790 * c-common.c (c_common_attributes): Add scalar_storage_order.
6791 (handle_scalar_storage_order_attribute): New function.
6792 * c-pragma.c (global_sso): New variable.
6793 (maybe_apply_pragma_scalar_storage_order): New function.
6794 (handle_pragma_scalar_storage_order): Likewise.
6795 (init_pragma): Register scalar_storage_order.
6796 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
6797 * c.opt (Wscalar-storage-order): New warning.
6798 (fsso-struct=): New option.
6800 2015-11-08 Martin Sebor <msebor@redhat.com>
6802 * c.opt (Wplacement-new): Add a period to the end of a sentence.
6804 2015-11-07 Richard Sandiford <richard.sandiford@arm.com>
6806 * c-common.c: Don't undef DEF_BUILTIN.
6808 2015-11-06 David Malcolm <dmalcolm@redhat.com>
6810 * c-common.c (c_cpp_error): Convert parameter from location_t to
6811 rich_location *. Eliminate the "column_override" parameter and
6812 the call to diagnostic_override_column.
6813 Update the "done_lexing" clause to set range 0
6814 on the rich_location, rather than overwriting a location_t.
6815 * c-common.h (c_cpp_error): Convert parameter from location_t to
6816 rich_location *. Eliminate the "column_override" parameter.
6818 2015-11-05 Cesar Philippidis <cesar@codesourcery.com>
6819 Thomas Schwinge <thomas@codesourcery.com>
6820 James Norris <jnorris@codesourcery.com>
6822 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
6823 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
6824 clauses with parallel and kernels and loops.
6825 * c-pragma.h (enum pragma_omp_clause): Add entries for
6826 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
6827 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
6828 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
6830 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
6832 2015-11-05 Martin Sebor <msebor@redhat.com>
6835 * c.opt (-Wplacement-new): New option.
6837 2015-11-05 Jakub Jelinek <jakub@redhat.com>
6839 * c-common.h (c_finish_omp_atomic): Add TEST argument.
6840 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
6841 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
6842 save_expr or create_tmp_var* if TEST is true.
6843 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
6844 Don't call add_stmt here.
6845 (struct c_omp_check_loop_iv_data): New type.
6846 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
6847 c_omp_check_loop_iv_exprs): New functions.
6848 (c_omp_split_clauses): Adjust for lastprivate being allowed on
6850 (c_omp_declare_simd_clauses_to_numbers): Change
6851 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
6852 (c_omp_declare_simd_clauses_to_decls): Similarly change those
6853 from numbers to PARM_DECLs.
6855 2015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
6857 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
6860 2015-11-03 Bernd Schmidt <bschmidt@redhat.com>
6863 * c-common.h (fold_offsetof_1): Add argument.
6864 * c-common.c (fold_offsetof_1): Diagnose more invalid
6865 offsetof expressions that reference elements past the end of
6868 2015-11-03 Thomas Schwinge <thomas@codesourcery.com>
6869 Chung-Lin Tang <cltang@codesourcery.com>
6871 * c-pragma.c (oacc_pragmas): Add "atomic".
6872 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
6874 2015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
6876 * c-common.c (handle_target_clones_attribute): New.
6877 (c_common_attribute_table): Add handle_target_clones_attribute.
6878 (handle_always_inline_attribute): Add check on target_clones attribute.
6879 (handle_target_attribute): Ditto.
6881 2015-10-29 Andrew MacLeod <amacleod@redhat.com>
6883 * array-notation-common.c: Reorder #include's and remove duplicates.
6884 * c-ada-spec.c: Likewise.
6885 * c-cilkplus.c: Likewise.
6886 * c-common.c: Likewise.
6887 * c-cppbuiltin.c: Likewise.
6888 * c-dump.c: Likewise.
6889 * c-format.c: Likewise.
6890 * c-gimplify.c: Likewise.
6891 * c-indentation.c: Likewise.
6892 * c-lex.c: Likewise.
6893 * c-omp.c: Likewise.
6894 * c-opts.c: Likewise.
6895 * c-pch.c: Likewise.
6896 * c-ppoutput.c: Likewise.
6897 * c-pragma.c: Likewise.
6898 * c-pretty-print.c: Likewise.
6899 * c-semantics.c: Likewise.
6900 * c-ubsan.c: Likewise.
6902 * stub-objc.c: Likewise.
6904 2015-10-28 Jason Merrill <jason@redhat.com>
6906 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
6908 2015-10-27 Thomas Schwinge <thomas@codesourcery.com>
6909 James Norris <jnorris@codesourcery.com>
6910 Cesar Philippidis <cesar@codesourcery.com>
6914 * c-common.h (c_oacc_split_loop_clauses): Declare function.
6915 * c-omp.c (c_oacc_split_loop_clauses): New function.
6917 2015-10-21 Martin Sebor <msebor@redhat.com>
6920 * c.opt: End each sentence that describes an option with a period.
6922 2015-10-20 Marek Polacek <polacek@redhat.com>
6924 * array-notation-common.c (is_cilkplus_vector_p): Define.
6925 * c-common.h (is_cilkplus_vector_p): Declare.
6927 2015-10-20 Marek Polacek <polacek@redhat.com>
6929 * c.opt (std=gnu++11): Do not describe as experimental.
6930 (std=gnu++14): Likewise.
6932 2015-10-19 Jason Merrill <jason@redhat.com>
6934 * c-cppbuiltin.c (c_cpp_builtins): Define
6935 __cpp_nontype_template_args.
6937 2015-10-19 Jason Merrill <jason@redhat.com>
6939 * c-cppbuiltin.c (c_cpp_builtins): Define
6940 __cpp_enumerator_attributes, __cpp_fold_expressions,
6941 __cpp_unicode_characters.
6943 2015-10-13 Jakub Jelinek <jakub@redhat.com>
6944 Aldy Hernandez <aldyh@redhat.com>
6946 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
6947 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
6948 (c_define_builtins): Likewise.
6949 * c-common.h (enum c_omp_clause_split): Add
6950 C_OMP_CLAUSE_SPLIT_TASKLOOP.
6951 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
6952 (c_finish_omp_for): Add ORIG_DECLV argument.
6953 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
6954 201511 instead of 201307.
6955 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
6956 OMP_CRITICAL_CLAUSES to it.
6957 (c_finish_omp_ordered): Add CLAUSES argument, set
6958 OMP_ORDERED_CLAUSES to it.
6959 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
6960 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
6961 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
6962 constructs and new OpenMP 4.5 clauses. Clear
6963 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
6965 * c-pragma.c (omp_pragmas_simd): Add taskloop.
6966 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
6967 (enum pragma_omp_clause): Add
6968 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
6969 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
6971 2015-10-05 Richard Sandiford <richard.sandiford@arm.com>
6973 * c-lex.c (interpret_float): Use real_equal instead of
6976 2015-10-04 Jason Merrill <jason@redhat.com>
6978 Implement N4514, C++ Extensions for Transactional Memory.
6979 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
6980 (c_common_attribute_table): Add transaction_safe_dynamic.
6981 transaction_safe now affects type identity.
6982 (handle_tm_attribute): Handle transaction_safe_dynamic.
6983 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
6984 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
6985 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
6987 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
6988 * c-pretty-print.c (pp_c_attributes_display): Don't print
6989 transaction_safe in C++.
6991 2015-10-02 Marek Polacek <polacek@redhat.com>
6993 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
6995 2015-10-02 Marek Polacek <polacek@redhat.com>
6998 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
6999 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
7000 * c.opt (Wduplicated-cond): New option.
7002 2015-10-01 Joseph Myers <joseph@codesourcery.com>
7004 * c.opt (std=c11): Do not describe as experimental.
7005 (std=gnu11): Likewise.
7006 (std=iso9899:2011): Likewise.
7008 2015-09-28 Nathan Sidwell <nathan@codesourcery.com>
7010 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
7011 (DEF_FUNCTION_TYPE_VAR_11): Delete.
7013 2015-09-25 Marek Polacek <polacek@redhat.com>
7015 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
7016 (ubsan_instrument_shift): Likewise.
7018 2015-09-25 Marek Polacek <polacek@redhat.com>
7021 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
7023 2015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
7025 * c-indentation.c (should_warn_for_misleading_indentation):
7026 Compare next_stmt_vis_column with guard_line_first_nws instead
7027 of with guard_line_vis_column.
7029 2015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
7033 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
7034 options and options not valid for the current language.
7036 2015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
7038 * c-indentation.c (should_warn_for_misleading_indentation):
7039 Float out and consolidate the calls to get_visual_column that
7040 are passed guard_exploc as an argument. Compare
7041 next_stmt_vis_column with guard_line_first_nws instead of with
7042 body_line_first_nws.
7044 2015-09-22 Nathan Sidwell <nathan@codesourcery.com>
7046 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
7047 Wnamespaces): New C++ warnings.
7049 2015-09-22 Jason Merrill <jason@redhat.com>
7051 * c-common.h (abi_compat_version_crosses): New.
7052 (warn_abi_version): Declare.
7053 * c-common.c: Define it.
7054 * c-opts.c (c_common_post_options): Handle it.
7055 flag_abi_compat_version defaults to 8.
7057 2015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
7059 Complete the implementation of N4230, Nested namespace definition.
7060 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
7061 __cpp_nested_namespace_definitions.
7063 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
7065 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
7067 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
7069 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
7071 * c-pragma.h (pragma_lex): Add optional loc argument.
7073 2015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
7075 * c-format.c (check_format_arg): Adjust to use common block size in all
7078 2015-09-15 David Malcolm <dmalcolm@redhat.com>
7080 * c-format.c (location_from_offset): Update for change in
7081 signature of location_get_source_line.
7082 * c-indentation.c (get_visual_column): Likewise.
7083 (line_contains_hash_if): Likewise.
7085 2015-09-14 Marek Polacek <polacek@redhat.com>
7087 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
7088 setting various warnings.
7090 2015-09-14 Marek Polacek <polacek@redhat.com>
7092 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
7095 2015-09-11 Mark Wielaard <mjw@redhat.com>
7098 * c.opt (Wunused-variable): Option from common.opt.
7099 (Wunused-const-variable): New option.
7101 2015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
7104 * c.opt ([Wsubobject-linkage]): Add.
7106 2015-09-03 Martin Sebor <msebor@redhat.com>
7109 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
7111 * c-common.c (reject_gcc_builtin): Define.
7113 2015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
7116 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
7118 * c-gimplify.c (c_gimplify_expr): Added a call to the function
7119 cilk_gimplify_call_params_in_spawned_fn.
7120 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
7121 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
7124 2015-08-25 Marek Polacek <polacek@redhat.com>
7127 * c-common.c (handle_weak_attribute): Don't check whether the
7128 visibility can be changed here.
7130 2015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
7132 * c-lex.c (c_lex_with_flags): Use explicit locations.
7134 2015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
7136 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
7137 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
7139 2015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
7142 * c-common.c (check_builtin_function_arguments): Add check
7143 for BUILT_IN_SIGNBIT argument.
7145 2015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
7148 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
7151 2015-08-17 Marek Polacek <polacek@redhat.com>
7153 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
7154 with whitespaces before qualifier names.
7156 2015-08-12 Marek Polacek <polacek@redhat.com>
7159 * c-common.c (maybe_warn_shift_overflow): Properly handle
7160 left-shifting 1 into the sign bit.
7162 2015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
7164 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
7166 2015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
7167 Braden Obrzut <admin@maniacsvault.net>
7168 Jason Merrill <jason@redhat.com>
7170 Add C++ Concepts TS support.
7171 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
7172 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
7173 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
7174 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
7175 * c-opts.c (set_std_cxx1z): Set flag_concepts.
7176 * c.opt (fconcepts): New.
7178 2015-08-02 Martin Sebor <msebor@redhat.com>
7180 * c.opt (-Wframe-address): New warning option.
7182 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
7184 * c-indentation.c (should_warn_for_misleading_indentation):
7187 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
7189 * c-indentation.c (get_visual_column): Add parameter first_nws,
7190 use it. Update comment documenting the function.
7191 (is_first_nonwhitespace_on_line): Remove.
7192 (should_warn_for_misleading_indentation): Replace usage of
7193 of is_first_nonwhitespace_on_line with get_visual_column.
7195 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
7197 * c-indentation.h (struct token_indent_info): Define.
7198 (get_token_indent_info): Define.
7199 (warn_for_misleading_information): Declare.
7200 * c-common.h (warn_for_misleading_information): Remove.
7201 * c-identation.c (warn_for_misleading_indentation):
7202 Change declaration to take three token_indent_infos. Adjust
7204 * c-identation.c (should_warn_for_misleading_indentation):
7205 Likewise. Bail out early if the body is a compound statement.
7206 (guard_tinfo_to_string): Define.
7208 2015-07-30 Jason Merrill <jason@redhat.com>
7210 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
7211 '*' for reference decay.
7213 2015-07-30 Marek Polacek <polacek@redhat.com>
7215 * c-common.c (warn_tautological_cmp): Bail for float types.
7217 2015-07-27 Marek Polacek <polacek@redhat.com>
7220 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
7222 2015-07-27 Marek Polacek <polacek@redhat.com>
7226 * c-common.c (find_array_ref_with_const_idx_r): New function.
7227 (warn_tautological_cmp): New function.
7228 * c-common.h (warn_tautological_cmp): Declare.
7229 * c.opt (Wtautological-compare): New option.
7231 2015-07-23 Marek Polacek <polacek@redhat.com>
7233 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
7234 (ubsan_instrument_shift): Likewise.
7236 2015-07-23 Marek Polacek <polacek@redhat.com>
7239 * c-ubsan.c: Include gimplify.h.
7240 (ubsan_instrument_division): Unshare OP0 and OP1.
7241 (ubsan_instrument_shift): Likewise.
7243 2015-07-20 Marek Polacek <polacek@redhat.com>
7244 Richard Sandiford <richard.sandiford@arm.com>
7247 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
7248 Use EXPR_LOC_OR_LOC.
7249 (maybe_warn_shift_overflow): New function.
7250 * c-common.h (maybe_warn_shift_overflow): Declare.
7251 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
7252 * c.opt (Wshift-overflow): New option.
7254 2015-07-16 Martin Liska <mliska@suse.cz>
7256 * c-format.c (static void check_format_info_main): Use
7257 object_allocator instead of pool_allocator.
7258 (check_format_arg): Likewise.
7259 (check_format_info_main): Likewise.
7261 2015-07-15 Andrew MacLeod <amacleod@redhat.com>
7263 * c-opts.c: Remove multiline #include comment.
7265 2015-07-12 Aldy Hernandez <aldyh@redhat.com>
7267 * c-common.c: Fix double word typos.
7269 2015-07-10 Eric Botcazou <ebotcazou@adacore.com>
7271 * c-ada-spec.h (cpp_operation): Revert latest change.
7272 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
7273 constructors and destructors.
7275 2015-07-09 Andrew MacLeod <amacleod@redhat.com>
7277 * c-common.h: Adjust includes for flags.h changes.
7278 * stub-objc.c: Likewise.
7280 2015-07-08 Eric Botcazou <ebotcazou@adacore.com>
7282 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
7283 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
7285 2015-07-08 Jakub Jelinek <jakub@redhat.com>
7287 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
7288 are to be removed, return NULL rather than original clauses list.
7290 2015-07-07 Andrew MacLeod <amacleod@redhat.com>
7292 * array-notation-common.c: Adjust includes.
7293 * c-ada-spec.c: Likewise.
7294 * c-cilkplus.c: Likewise.
7295 * c-common.h: Likewise.
7296 * c-cppbuiltin.c: Likewise.
7297 * c-dump.c: Likewise.
7298 * c-format.c: Likewise.
7299 * c-gimplify.c: Likewise.
7300 * c-indentation.c: Likewise.
7301 * c-lex.c: Likewise.
7302 * c-omp.c: Likewise.
7303 * c-opts.c: Likewise.
7304 * c-pch.c: Likewise.
7305 * c-ppoutput.c: Likewise.
7306 * c-pragma.c: Likewise.
7307 * c-pretty-print.c: Likewise.
7308 * c-semantics.c: Likewise.
7309 * c-ubsan.c: Likewise.
7311 * stub-objc.c: Likewise.
7313 2015-07-07 Eric Botcazou <ebotcazou@adacore.com>
7315 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
7316 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
7318 2015-07-01 Jason Merrill <jason@redhat.com>
7320 * c-common.h (D_CXX11): Rename from D_CXX0X.
7321 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
7322 * c-common.c: Adjust.
7324 * c-opts.c (c_common_post_options): Default to C++14.
7326 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
7328 2015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
7330 Implement N4197 - Adding u8 character literals
7331 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
7333 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
7334 CPP_UTF8CHAR_USERDEF tokens.
7335 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
7336 and CPP_UTF8CHAR tokens.
7337 (lex_charconst): Treat CPP_UTF8CHAR token.
7339 2015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
7342 * c-common.c (do_warn_unused_parameter): Move here.
7343 * c-common.h (do_warn_unused_parameter): Declare.
7345 2015-06-29 Marek Polacek <polacek@redhat.com>
7348 * c-common.c (check_case_bounds): Add bool * parameter. Set
7350 (c_add_case_label): Add bool * parameter. Pass it down to
7352 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
7354 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
7357 2015-06-27 Marek Polacek <polacek@redhat.com>
7359 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
7360 or VECTOR_INTEGER_TYPE_P throughout.
7361 * c-gimplify.c: Likewise.
7363 2015-06-26 Marek Polacek <polacek@redhat.com>
7365 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
7366 * c-common.c (c_fully_fold_internal): Likewise.
7367 (c_alignof_expr): Likewise.
7368 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
7369 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
7370 * cilk.c (create_parm_list): Likewise.
7372 2015-06-26 Marek Polacek <polacek@redhat.com>
7374 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
7376 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
7378 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
7379 * c-gimplify.c: Likewise.
7380 * c-pragma.c: Likewise.
7381 * c-ubsan.c: Likewise.
7384 2015-06-25 Richard Sandiford <richard.sandiford@arm.com>
7386 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
7389 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
7391 * cilk.c: Move calls.h after tm.h in the include chain.
7393 2015-06-25 Marek Polacek <polacek@redhat.com>
7395 * array-notation-common.c: Use VAR_P throughout.
7396 * c-ada-spec.c: Likewise.
7397 * c-common.c: Likewise.
7398 * c-format.c: Likewise.
7399 * c-gimplify.c: Likewise.
7400 * c-omp.c: Likewise.
7401 * c-pragma.c: Likewise.
7402 * c-pretty-print.c: Likewise.
7405 2015-06-25 Marek Polacek <polacek@redhat.com>
7407 * cilk.c (extract_free_variables): Use is_global_var.
7409 2015-06-23 Richard Sandiford <richard.sandiford@arm.com>
7411 * c-common.c: Don't include target-def.h.
7413 2015-06-23 Marek Polacek <polacek@redhat.com>
7415 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
7416 when comparing INTEGER_CSTs.
7418 2015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
7420 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
7421 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
7422 (dump_ada_template): Skip partially specialized types.
7424 2015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
7426 * c-common.c (scalar_to_vector): Use std::swap instead of manually
7429 2015-06-17 Andrew MacLeod <amacleod@redhat.com>
7431 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
7432 * c-ada-spec.c: Likewise.
7433 * c-cilkplus.c: Likewise.
7434 * c-common.c: Likewise.
7435 * c-common.h: Likewise.
7436 * c-cppbuiltin.c: Likewise.
7437 * c-dump.c: Likewise.
7438 * c-format.c: Likewise.
7439 * c-gimplify.c: Likewise.
7440 * c-indentation.c: Likewise.
7441 * c-lex.c: Likewise.
7442 * c-omp.c: Likewise.
7443 * c-opts.c: Likewise.
7444 * c-pch.c: Likewise.
7445 * c-ppoutput.c: Likewise.
7446 * c-pragma.c: Likewise.
7447 * c-pretty-print.c: Likewise.
7448 * c-semantics.c: Likewise.
7449 * c-ubsan.c: Likewise.
7451 * stub-objc.c: Likewise.
7453 2015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
7456 * c-common.c (c_common_truthvalue_conversion): Warn when
7457 converting an address of a reference to a truth value.
7459 2015-06-08 Andrew MacLeod <amacleod@redhat.com>
7461 * array-notation-common.c : Adjust include files.
7462 * c-ada-spec.c : Likewise.
7463 * c-cilkplus.c : Likewise.
7464 * c-common.c : Likewise.
7465 * c-common.h : Likewise.
7466 * c-cppbuiltin.c : Likewise.
7467 * c-dump.c : Likewise.
7468 * c-format.c : Likewise.
7469 * c-gimplify.c : Likewise.
7470 * c-indentation.c : Likewise.
7471 * c-lex.c : Likewise.
7472 * c-omp.c : Likewise.
7473 * c-opts.c : Likewise.
7474 * c-pch.c : Likewise.
7475 * c-ppoutput.c : Likewise.
7476 * c-pragma.c : Likewise.
7477 * c-pretty-print.c : Likewise.
7478 * c-semantics.c : Likewise.
7479 * c-ubsan.c : Likewise.
7480 * cilk.c : Likewise.
7481 * stub-objc.c : Likewise.
7483 2015-06-08 Marek Polacek <polacek@redhat.com>
7486 * c-format.c (location_from_offset): Return LOC if LINE is null.
7488 2015-06-05 Aldy Hernandez <aldyh@redhat.com>
7490 * c-common.h (c_parse_final_cleanups): New prototype.
7491 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
7493 2015-06-04 Sriraman Tallam <tmsriram@google.com>
7495 * c-common.c (noplt): New attribute.
7496 (handle_noplt_attribute): New handler.
7498 2015-06-04 Andrew MacLeod <amacleod@redhat.com>
7500 * array-notation-common.c: Adjust includes for restructured coretypes.h.
7501 * c-ada-spec.c: Likewise.
7502 * c-cilkplus.c: Likewise.
7503 * c-common.c: Likewise.
7504 * c-common.h: Likewise.
7505 * c-cppbuiltin.c: Likewise.
7506 * c-dump.c: Likewise.
7507 * c-format.c: Likewise.
7508 * c-gimplify.c: Likewise.
7509 * c-indentation.c: Likewise.
7510 * c-lex.c: Likewise.
7511 * c-omp.c: Likewise.
7512 * c-opts.c: Likewise.
7513 * c-pch.c: Likewise.
7514 * c-ppoutput.c: Likewise.
7515 * c-pragma.c: Likewise.
7516 * c-pretty-print.c: Likewise.
7517 * c-semantics.c: Likewise.
7518 * c-ubsan.c: Likewise.
7520 * stub-objc.c: Likewise.
7522 2015-06-02 David Malcolm <dmalcolm@redhat.com>
7525 * c-indentation.c (should_warn_for_misleading_indentation): Use
7526 expand_location rather than expand_location_to_spelling_point.
7527 Don't warn if the guarding statement is more indented than the
7530 2015-06-02 David Malcolm <dmalcolm@redhat.com>
7532 * c-indentation.c (warn_for_misleading_indentation): Bail out
7533 immediately if -Wmisleading-indentation isn't enabled.
7535 2015-06-01 Martin Liska <mliska@suse.cz>
7537 * c-format.c (check_format_arg):Use new type-based pool allocator.
7538 (check_format_info_main) Likewise.
7540 2015-05-31 Eric Botcazou <ebotcazou@adacore.com>
7542 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
7543 (has_nontrivial_methods): Likewise.
7545 2015-05-25 Marek Polacek <polacek@redhat.com>
7547 * c-ubsan.c (ubsan_instrument_shift): Use type0.
7549 2015-05-22 Marek Polacek <polacek@redhat.com>
7552 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
7554 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
7556 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
7557 STACK_GROWS_DOWNWARD.
7559 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
7561 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
7562 STACK_GROWS_DOWNWARD rather than if it is defined.
7564 2015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
7567 * c-format.c (location_column_from_byte_offset): New.
7568 (location_from_offset): New.
7569 (struct format_wanted_type): Add offset_loc field.
7570 (check_format_info): Move handling of location for extra arguments
7571 closer to the point of warning.
7572 (check_format_info_main): Pass the result of location_from_offset
7574 (format_type_warning): Pass the result of location_from_offset
7577 2015-05-20 Marek Polacek <polacek@redhat.com>
7579 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
7581 2015-05-20 Marek Polacek <polacek@redhat.com>
7583 * c-ada-spec.c (dump_sloc): Use DECL_P.
7585 2015-05-20 Marek Polacek <polacek@redhat.com>
7587 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
7588 * c-common.c: Likewise.
7590 2015-05-19 David Malcolm <dmalcolm@redhat.com>
7592 * c-common.h (fe_file_change): Strengthen param from
7593 const line_map * to const line_map_ordinary *.
7594 (pp_file_change): Likewise.
7595 * c-lex.c (fe_file_change): Likewise.
7596 (cb_define): Use linemap_check_ordinary when invoking
7598 (cb_undef): Likewise.
7599 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
7600 invoking cb_file_change.
7601 (c_finish_options): Likewise.
7602 (push_command_line_include): Likewise.
7603 (cb_file_change): Strengthen param "new_map" from
7604 const line_map * to const line_map_ordinary *.
7605 * c-ppoutput.c (cb_define): Likewise for local "map".
7606 (pp_file_change): Likewise for param "map" and local "from".
7608 2015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
7610 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
7612 2015-05-18 Tom de Vries <tom@codesourcery.com>
7614 * c-common.c (build_va_arg_1): New function.
7615 (build_va_arg): Add address operator to va_list operand if necessary.
7617 2015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
7620 * c-common.c (int_safely_convertible_to_real_p): Define.
7621 (unsafe_conversion_p): Check conversions involving complex types.
7622 (conversion_warning): Add new warning message for conversions which
7623 discard imaginary component.
7624 * c-common.h: (enum conversion_safety): Add new enumerator for such
7627 2015-05-14 Marek Polacek <polacek@redhat.com>
7631 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
7632 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
7633 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
7634 use it. If FOR_INT_CONST, require that all evaluated operands be
7637 2015-05-12 David Malcolm <dmalcolm@redhat.com>
7639 * c-common.h (warn_for_misleading_indentation): New prototype.
7640 * c-indentation.c: New file.
7641 * c.opt (Wmisleading-indentation): New option.
7643 2015-05-12 Tom de Vries <tom@codesourcery.com>
7645 PR tree-optimization/66010
7646 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
7648 2015-05-09 Jason Merrill <jason@redhat.com>
7650 * c-opts.c (c_common_post_options): Also clear
7651 cpp_opts->cpp_warn_cxx11_compat.
7653 * c-common.h (enum cxx_dialect): Add cxx_unset.
7654 * c-common.c (cxx_dialect): Initialize to cxx_unset.
7655 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
7657 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
7658 (std=gnu++0x): Mark as Undocumented.
7659 (std=gnu++1y): Add deprecated message.
7661 2015-05-08 Jason Merrill <jason@redhat.com>
7663 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
7666 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
7668 2015-05-08 Marek Polacek <polacek@redhat.com>
7671 * c.opt (Woverride-init-side-effects): New option.
7673 2015-05-07 Marek Polacek <polacek@redhat.com>
7676 * c-common.c (c_fully_fold_internal): Warn when left shifting a
7678 * c.opt (Wshift-negative-value): New option.
7679 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
7680 when -Wextra and C99/C++11 mode.
7682 2015-05-07 Marek Polacek <polacek@redhat.com>
7683 Martin Uecker <uecker@eecs.berkeley.edu>
7685 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
7686 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
7688 2015-05-05 Jason Merrill <jason@redhat.com>
7690 * c.opt (Wterminate): New.
7692 2015-04-30 Marek Polacek <polacek@redhat.com>
7694 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
7695 require that the non-constant be of a boolean type.
7697 2015-04-29 Josh Triplett <josh@joshtriplett.org>
7699 * c-common.c (handle_section_attribute): Refactor to reduce
7700 nesting and distinguish between error cases.
7702 2015-04-29 Marek Polacek <polacek@redhat.com>
7705 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
7708 2015-04-29 Jakub Jelinek <jakub@redhat.com>
7710 * c-common.h (omp_clause_mask): Unconditionally define as a class.
7711 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
7712 HOST_BITS_PER_WIDE_INT.
7714 2015-04-28 Tom de Vries <tom@codesourcery.com>
7716 PR tree-optimization/65887
7717 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
7719 2015-04-28 Eric Botcazou <ebotcazou@adacore.com>
7720 Pierre-Marie de Rodat <derodat@adacore.com>
7722 * c-ada-spec.c (in_function): Delete.
7723 (dump_generic_ada_node): Do not change in_function and remove the
7724 redundant code dealing with it.
7725 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
7726 (print_ada_methods): Output the static member functions in a nested
7727 package after the regular methods as well as associated renamings.
7729 2015-04-24 Marek Polacek <polacek@redhat.com>
7732 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
7733 and OPT_Wshift_count_overflow.
7736 * c-common.c (warn_logical_operator): Warn if the operands have the
7739 2015-04-24 Marek Polacek <polacek@redhat.com>
7742 * c-common.c (warn_logical_operator): Bail if either operand comes
7743 from a macro expansion.
7745 2015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
7748 * c-common.c (c_default_pointer_mode): Add definition.
7749 * c-common.h (c_default_pointer_mode): Add declaration.
7751 2015-03-11 Jakub Jelinek <jakub@redhat.com>
7753 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
7754 on record_builtin_type argument.
7756 2015-03-10 Jakub Jelinek <jakub@redhat.com>
7759 * c-common.c (warn_logical_not_parentheses): Don't warn for
7762 2015-03-07 Marek Polacek <polacek@redhat.com>
7765 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
7766 before trying to figure out whether we have a flexible array member.
7768 2015-03-06 Eric Botcazou <ebotcazou@adacore.com>
7769 Jonathan Wakely <jwakely.gcc@gmail.com>
7771 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
7773 2015-03-05 Eric Botcazou <ebotcazou@adacore.com>
7776 * c-ada-spec.c (print_destructor): Remove obsolete code.
7778 2015-03-01 Eric Botcazou <ebotcazou@adacore.com>
7780 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
7781 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
7782 DECL_TEMPLATE_RESULT emulations.
7783 (dump_ada_template)): Add guard for TYPE_METHODS.
7785 2015-02-27 Marek Polacek <polacek@redhat.com>
7788 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
7790 2015-02-27 Kai Tietz <ktietz@redhat.com>
7793 * c-pragma.c (handle_pragma_weak): Do not try to create
7794 weak/alias of declarations not being function, or variable
7797 2015-02-24 Thomas Schwinge <thomas@codesourcery.com>
7800 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
7802 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
7804 2015-02-16 Marek Polacek <polacek@redhat.com>
7807 * c-format.c (check_format_types): Handle null param.
7809 2015-02-13 Marek Polacek <polacek@redhat.com>
7812 * c-format.c (check_format_types): Don't warn about different
7813 signedness if the original value is in the range of WANTED_TYPE.
7815 2015-02-12 Jason Merrill <jason@redhat.com>
7818 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
7819 to the current highest version.
7820 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
7822 2015-02-04 Jakub Jelinek <jakub@redhat.com>
7826 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
7827 instead of RDIV_EXPR. Use build_binary_op instead of
7830 2015-01-30 Joseph Myers <joseph@codesourcery.com>
7832 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
7833 to pass input_location as first argument.
7835 2015-01-23 Tom de Vries <tom@codesourcery.com>
7838 * c.opt (fopenacc): Mark as LTO option.
7840 2015-01-23 Tom de Vries <tom@codesourcery.com>
7843 * c.opt (fopenmp): Mark as LTO option.
7845 2015-01-21 Jakub Jelinek <jakub@redhat.com>
7848 * cilk.c (fill_decls_vec): Only put decls into vector v.
7849 (compare_decls): Fix up formatting.
7851 2015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
7854 * cilk.c: Include vec.h.
7855 (struct cilk_decls): New structure.
7856 (wrapper_parm_cb): Split this function to...
7857 (fill_decls_vec): ...this...
7858 (create_parm_list): ...and this.
7859 (compare_decls): New function.
7860 (for_local_cb): Remove.
7861 (wrapper_local_cb): Ditto.
7862 (build_wrapper_type): For now first traverse and fill vector of
7863 declarations then sort it and then deal with sorted vector.
7864 (cilk_outline): Ditto.
7865 (declare_one_free_variable): Ditto.
7867 2015-01-21 Jason Merrill <jason@redhat.com>
7870 * c-format.c (check_format_arg): Call decl_constant_value.
7872 2015-01-19 Martin Liska <mliska@suse.cz>
7874 * c-common.c (handle_noicf_attribute): New function.
7876 2015-01-15 Thomas Schwinge <thomas@codesourcery.com>
7877 Bernd Schmidt <bernds@codesourcery.com>
7878 James Norris <jnorris@codesourcery.com>
7879 Cesar Philippidis <cesar@codesourcery.com>
7880 Ilmir Usmanov <i.usmanov@samsung.com>
7881 Jakub Jelinek <jakub@redhat.com>
7883 * c.opt (fopenacc): New option.
7884 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
7885 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
7887 * c-common.h (c_finish_oacc_wait): New prototype.
7888 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
7889 (c_finish_oacc_wait): New function.
7890 * c-pragma.c (oacc_pragmas): New variable.
7891 (c_pp_lookup_pragma, init_pragma): Handle it.
7892 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
7893 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
7894 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
7895 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
7896 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
7897 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
7898 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
7899 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
7900 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
7901 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
7902 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
7903 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
7904 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
7905 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
7906 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
7907 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
7908 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
7909 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
7910 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
7911 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
7912 PRAGMA_OACC_CLAUSE_WORKER.
7914 2015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
7916 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
7917 for the new option fstack-protector_explicit.
7918 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
7919 (handle_stack_protect_attribute): New function.
7921 2015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
7923 * c.opt: New option -Warray-bounds=.
7925 2015-01-09 Michael Collison <michael.collison@linaro.org>
7927 * array-notation-common.c: Include hash-set.h, machmode.h,
7928 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7929 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
7930 * c-ada-spec.c: Ditto.
7931 * c-cilkplus.c: Ditto.
7932 * c-common.c: Include input.h due to flattening of tree.h.
7933 Define macro GCC_C_COMMON_C.
7934 * c-common.h: Flatten tree.h header files into c-common.h.
7935 Remove include of tree-core.h.
7936 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
7937 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7938 fold-const.h, wide-int.h, and inchash.h due to
7939 flattening of tree.h.
7941 * c-format.c: Flatten tree.h header files into c-common.h.
7942 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
7943 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7944 fold-const.h, wide-int.h, and inchash.h due to
7945 flattening of tree.h.
7946 * c-dump.c: Include hash-set.h, machmode.h,
7947 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7948 fold-const.h, wide-int.h, and inchash.h due to
7949 flattening of tree.h.
7950 * c-format.c: Include hash-set.h, machmode.h,
7951 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7952 fold-const.h, wide-int.h, inchash.h and real.h due to
7953 flattening of tree.h.
7954 * c-gimplify.c: Include hash-set.h, machmode.h,
7955 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7956 fold-const.h, wide-int.h, and inchash.h due to
7957 flattening of tree.h.
7963 * c-ppoutput.c: Ditto.
7964 * c-pragma.c: Ditto.
7965 * c-pretty-print.c: Ditto.
7966 * c-semantics.c: Ditto.
7968 * stub-objc.c: Ditto.
7970 2015-01-08 Jason Merrill <jason@redhat.com>
7972 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
7973 do_ubsan_in_current_function.
7974 (ubsan_maybe_instrument_reference_or_call): Likewise.
7975 * c-ubsan.h: Declare it.
7977 2015-01-08 Mike Stump <mikestump@comcast.net>
7979 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
7981 2015-01-07 Marek Polacek <polacek@redhat.com>
7984 * c-common.c (c_fully_fold_internal): Warn for division and modulo
7985 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
7987 2015-01-05 Trevor Saunders <tsaunders@mozilla.com>
7990 * c.opt (Wsuggest-override): New option.
7992 2015-01-05 Jakub Jelinek <jakub@redhat.com>
7994 Update copyright years.
7996 2015-01-05 Marek Polacek <polacek@redhat.com>
7999 * c-common.c (warn_array_subscript_with_type_char): Add location_t
8001 * c-common.h (warn_array_subscript_with_type_char): Update
8004 2014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
8006 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
8007 Control macro with flag_sized_deallocation.
8009 2014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
8011 * c.opt (Wdiscarded-array-qualifiers): New option.
8013 2014-12-19 Jakub Jelinek <jakub@redhat.com>
8015 PR preprocessor/63831
8016 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
8017 and __has_cpp_attribute here.
8018 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
8019 c_common_has_attribute.
8020 * c-common.h (c_common_has_attribute): New prototype.
8021 * c-lex.c (init_c_lex): Set cb->has_attribute to
8022 c_common_has_attribute instead of cb_has_attribute.
8023 (get_token_no_padding): New function.
8024 (cb_has_attribute): Renamed to ...
8025 (c_common_has_attribute): ... this. No longer static. Use
8026 get_token_no_padding, require ()s, don't build TREE_LIST
8027 unnecessarily, fix up formatting, adjust diagnostics, call
8030 2014-12-15 Jason Merrill <jason@redhat.com>
8032 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
8033 (-Wsized-deallocation): New.
8034 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
8035 to on in C++14 and up.
8037 2014-12-11 Jason Merrill <jason@redhat.com>
8039 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
8041 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
8042 we aren't complaining about VLAs.
8044 2014-12-06 Marek Polacek <polacek@redhat.com>
8046 PR tree-optimization/64183
8047 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
8048 shift-expression if it is integer_type_node. Use types_compatible_p.
8050 2014-11-29 Jakub Jelinek <jakub@redhat.com>
8052 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
8053 last argument from create_tmp_var_raw and create_tmp_var calls.
8054 * cilk.c (gimplify_cilk_spawn): Likewise.
8055 * c-omp.c (c_finish_omp_atomic): Likewise.
8057 2014-11-28 Marek Polacek <polacek@redhat.com>
8059 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
8060 instead of unsigned_type_node.
8062 2014-11-28 Marek Polacek <polacek@redhat.com>
8065 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
8067 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
8068 expression to unsigned_type_node.
8070 2014-11-20 Mark Wielaard <mjw@redhat.com>
8073 * c-opts.c (set_std_c89): Set lang_hooks.name.
8074 (set_std_c99): Likewise.
8075 (set_std_c11): Likewise.
8076 (set_std_cxx98): Likewise.
8077 (set_std_cxx11): Likewise.
8078 (set_std_cxx14): Likewise.
8079 (set_std_cxx1z): Likewise.
8081 2014-11-21 Jakub Jelinek <jakub@redhat.com>
8084 * c-common.h (convert_vector_to_pointer_for_subscript): Change
8085 return type to bool.
8086 * c-common.c: Include gimple-expr.h.
8087 (convert_vector_to_pointer_for_subscript): Change return type to
8088 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
8089 and copy it into a TARGET_EXPR and use that instead of *vecp
8092 2014-11-19 David Malcolm <dmalcolm@redhat.com>
8094 Merger of git branch "gimple-classes-v2-option-3".
8095 * ChangeLog.gimple-classes: New.
8096 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
8097 from being just a vec<gimple> to a vec<gbind *>.
8099 2014-11-18 Jakub Jelinek <jakub@redhat.com>
8102 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
8103 argument to ptype, set type to TREE_TYPE (ptype). Don't call
8104 get_pointer_alignment for non-pointers. Use ptype, or if it is
8105 reference type, corresponding pointer type, as type of kind
8107 (ubsan_maybe_instrument_reference,
8108 ubsan_maybe_instrument_member_call): Adjust callers.
8110 2014-11-15 Marek Polacek <polacek@redhat.com>
8113 * array-notation-common.c (is_sec_implicit_index_fn): Return false
8115 (extract_array_notation_exprs): Return for NULL node.
8117 2014-11-12 Joseph Myers <joseph@codesourcery.com>
8119 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
8120 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
8122 2014-11-12 Jakub Jelinek <jakub@redhat.com>
8125 * c-common.c (check_builtin_function_arguments): Handle
8126 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
8128 2014-11-10 Andi Kleen <ak@linux.intel.com>
8131 * c-common.h (check_no_cilk): Declare.
8132 * cilk.c (get_error_location): New function.
8133 (check_no_cilk): Dito.
8135 2014-11-10 Andi Kleen <ak@linux.intel.com>
8137 * cilk.c (recognize_spawn): Use expression location
8140 2014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
8142 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
8144 2014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
8146 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
8147 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
8148 (__cpp_range_based_for, __cpp_initializer_lists,
8149 __cpp_delegating_constructors, __cpp_nsdmi,
8150 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
8151 for C++11; (__cpp_attribute_deprecated): Remove in favor of
8152 __has_cpp_attribute.
8153 * c-lex.c (cb_has_attribute): New callback CPP function;
8154 (init_c_lex): Set has_attribute callback.
8156 2014-11-04 Richard Biener <rguenther@suse.de>
8158 * c-common.c (shorten_compare): Do not shorten mixed
8159 DFP and non-DFP compares.
8161 2014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
8163 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
8164 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
8165 Commentary and rearrangement of tests.
8166 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
8167 Commentary and rearrangement of tests.
8168 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
8169 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
8171 2014-10-29 Richard Sandiford <richard.sandiford@arm.com>
8173 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
8174 enum from machine_mode.
8176 2014-10-28 Andrew MacLeod <amacleod@redhat.com>
8178 * c-common.c: Adjust include files.
8179 * c-gimplify.c: Ditto.
8181 * c-pragma.c: Ditto.
8184 2014-10-27 Andrew MacLeod <amacleod@redhat.com>
8186 * c-gimplify.c: Adjust include files.
8188 2014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
8191 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
8192 c_common_initialize_diagnostics.
8193 * c-common.h: Likewise.
8195 2014-10-24 Marek Polacek <polacek@redhat.com>
8198 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
8199 print "struct"/"union"/"enum" for typedefed names.
8201 2014-10-23 Marek Polacek <polacek@redhat.com>
8203 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
8206 2014-10-22 Jakub Jelinek <jakub@redhat.com>
8207 Yury Gribov <y.gribov@samsung.com>
8209 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
8210 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
8211 instead of flag_sanitize_recover as bool flag.
8213 2014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
8215 * cilk.c: Revert previous change.
8217 2014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
8220 * cilk.c: Include vec.h.
8221 (struct cilk_decls): New structure.
8222 (wrapper_parm_cb): Split this function to...
8223 (fill_decls_vec): ...this...
8224 (create_parm_list): ...and this.
8225 (compare_decls): New function.
8226 (for_local_cb): Remove.
8227 (wrapper_local_cb): Ditto.
8228 (build_wrapper_type): For now first traverse and fill vector of
8229 declarations then sort it and then deal with sorted vector.
8230 (cilk_outline): Ditto.
8231 (declare_one_free_variable): Ditto.
8233 2014-10-17 Marek Polacek <polacek@redhat.com>
8235 * c-opts.c (c_common_post_options): Set warn_implicit_int.
8236 * c.opt (Wimplicit-int): Initialize to -1.
8238 2014-10-16 Andrew MacLeod <amacleod@redhat.com>
8240 * c-pragma.c: Adjust include files.
8241 * c-semantics.c: Likewise.
8243 2014-10-16 DJ Delorie <dj@redhat.com>
8245 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
8248 2014-10-14 Jason Merrill <jason@redhat.com>
8251 * c-common.h (CPP_PREPARSED_EXPR): New.
8252 (N_CP_TTYPES): Adjust.
8254 2014-10-15 Marek Polacek <polacek@redhat.com>
8256 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
8258 2014-10-14 DJ Delorie <dj@redhat.com>
8260 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
8261 types, not just __int128.
8262 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
8263 types, not just __int128.
8264 (cpp_atomic_builtins): Round pointer sizes up.
8265 (type_suffix): Use type precision, not specific types.
8266 * c-common.c (c_common_reswords): Remove __int128 special case.
8267 (c_common_type_for_size): Check for all __intN types, not just
8269 (c_common_type_for_mode): Likewise.
8270 (c_common_signed_or_unsigned_type): Likewise.
8271 (c_build_bitfield_integer_type): Likewise.
8272 (c_common_nodes_and_builtins): Likewise.
8273 (keyword_begins_type_specifier): Likewise.
8274 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
8277 2014-10-12 Trevor Saunders <tsaunders@mozilla.com>
8279 * c-common.c: Use hash_table instead of hashtab.
8281 2014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
8283 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
8286 2014-10-03 Marc Glisse <marc.glisse@inria.fr>
8291 * c-common.c (warn_logical_operator): Punt for vectors.
8293 2014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
8295 Implement SD-6: SG10 Feature Test Recommendations
8296 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
8297 macros and the __has_header macro.
8299 2014-09-30 Jason Merrill <jason@redhat.com>
8301 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
8302 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
8303 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
8305 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
8306 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
8308 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
8309 * c-common.c (c_common_reswords): Remove __is_convertible_to.
8311 2014-09-24 Marek Polacek <polacek@redhat.com>
8315 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
8317 2014-09-23 Andi Kleen <ak@linux.intel.com>
8319 * c-common.c (handle_no_reorder_attribute): New function.
8320 (c_common_attribute_table): Add no_reorder attribute.
8322 2014-09-22 Joseph Myers <joseph@codesourcery.com>
8324 * c-cppbuiltin.c (c_cpp_builtins): Define
8325 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
8328 2014-09-18 Joseph Myers <joseph@codesourcery.com>
8330 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
8331 for supported floating-point modes.
8333 2014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
8335 * c.opt (Wpsabi): Use LangEnabledBy.
8336 * c-opts.c (c_common_handle_option): Do not handle here.
8338 2014-09-12 Joseph Myers <joseph@codesourcery.com>
8340 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
8341 macros for floating-point modes.
8343 2014-09-11 Marc Glisse <marc.glisse@inria.fr>
8346 * c-cppbuiltin.c (builtin_define_float_constants): Correct
8347 __*_DENORM_MIN__ without denormals.
8349 2014-09-10 Jakub Jelinek <jakub@redhat.com>
8351 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
8352 ubsan_instrument_vla, ubsan_instrument_return): Adjust
8353 ubsan_create_data callers.
8354 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
8355 index is constant or BIT_AND_EXPR with constant mask and is
8356 small enough for the bound.
8357 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
8358 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
8360 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
8362 * c.opt: Add CppReason to various flags.
8363 (Wdate-time): Re-sort.
8364 * c-common.c: Include c-common.h earlier.
8365 (struct reason_option_codes_t): Delete.
8366 (c_option_controlling_cpp_error): Prefix global type and struct
8369 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
8371 * c.opt (Wnormalized): New.
8372 (Wnormalized=): Use Enum and Reject Negative.
8373 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
8375 2014-09-08 Joseph Myers <joseph@codesourcery.com>
8377 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
8378 digits of floating-point modes if -fbuilding-libgcc.
8380 2014-09-05 Joseph Myers <joseph@codesourcery.com>
8382 * c-cppbuiltin.c (c_cpp_builtins): Also define
8383 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
8384 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
8385 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
8386 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
8387 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
8388 __LIBGCC_STACK_GROWS_DOWNWARD__,
8389 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
8390 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
8391 __LIBGCC_DWARF_FRAME_REGISTERS__,
8392 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
8393 __LIBGCC_STACK_POINTER_REGNUM__ and
8394 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
8395 (builtin_define_with_value): Handle backslash-escaping in string
8398 2014-09-05 Richard Biener <rguenther@suse.de>
8401 * c-format.c (check_format_arg): Properly handle
8402 effectively signed POINTER_PLUS_EXPR offset.
8404 2014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
8406 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
8407 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
8408 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
8410 * c-opts.c (c_common_handle_option): Do not handle here.
8411 (sanitize_cpp_opts): Likewise.
8412 * c-common.c (struct reason_option_codes_t): Handle
8413 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
8415 2014-09-03 Marek Polacek <polacek@redhat.com>
8417 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
8419 2014-09-02 Jakub Jelinek <jakub@redhat.com>
8420 Balaji V. Iyer <balaji.v.iyer@intel.com>
8421 Igor Zamyatin <igor.zamyatin@intel.com>
8423 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
8424 * c-common.c (c_common_reswords): Added _Cilk_for.
8425 * c-common.h (enum rid): Added RID_CILK_FOR.
8426 (cilk_for_number_of_iterations): Add declaration.
8427 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
8429 * c-pragma.c (init_pragma): Register "grainsize" pragma.
8430 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
8432 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
8434 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
8435 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
8436 Wundef): Use CPP, Var and Init.
8437 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
8439 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
8441 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
8442 * c-opts.c (c_common_handle_option): Do not handle here.
8444 2014-08-25 Jason Merrill <jason@redhat.com>
8446 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
8447 -std=c++14 and -std=gnu++14, rather than the reverse.
8448 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
8449 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
8450 * c-common.h (cxx_dialect): Remove cxx1y.
8452 2014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
8454 * c-common.h (enum cxx_dialect): Add cxx14.
8455 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
8456 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
8457 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
8459 2014-08-22 Jason Merrill <jason@redhat.com>
8461 * c.opt (std=gnu++17): Fix alias.
8463 2014-08-22 Marek Polacek <polacek@redhat.com>
8466 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
8467 check for vector types. Drop LHS argument.
8468 * c-common.h (warn_logical_not_parentheses): Adjust.
8470 2014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
8472 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
8473 (Wmultichar): Likewise.
8474 (Wdate-time): Use C-family languages instead of Common. Use CPP
8476 * c-opts.c (c_common_handle_option): Do not handle the above
8478 (sanitize_cpp_opts): Likewise.
8480 2014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
8483 * c-opts.c: Include tree-diagnostics.h.
8484 (c_diagnostic_finalizer): New.
8485 (c_common_initialize_diagnostics): Use it.
8487 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
8489 PR preprocessor/51303
8490 * c-common.c (struct reason_option_codes_t option_codes):
8491 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
8493 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
8497 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
8498 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
8499 (c_common_post_options): Call init_global_opts_from_cpp.
8500 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
8502 2014-08-19 Marek Polacek <polacek@redhat.com>
8505 * c-common.c (maybe_warn_bool_compare): New function.
8506 * c-common.h (maybe_warn_bool_compare): Declare.
8507 * c.opt (Wbool-compare): New option.
8509 2014-08-19 Marek Polacek <polacek@redhat.com>
8511 * c.opt (Wc99-c11-compat): New option.
8513 2014-08-19 Marek Polacek <polacek@redhat.com>
8515 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
8516 to warn_c90_c99_compat.
8517 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
8520 2014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
8521 Steven Bosscher <steven@gcc.gnu.org>
8524 * c-format.c: Add extra_arg_loc and format_string_loc to struct
8525 format_check_results.
8526 (check_function_format): Use true and add comment for boolean
8528 (finish_dollar_format_checking): Use explicit location when warning.
8529 (check_format_info): Likewise.
8530 (check_format_arg): Set extra_arg_loc and format_string_loc.
8531 (check_format_info_main): Use explicit location when warning.
8532 (check_format_types): Pass explicit location.
8533 (format_type_warning): Likewise.
8535 2014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
8538 * c-format.c: Handle Fortran flags.
8540 2014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
8543 * array-notation-common.c (find_rank): Added handling for other
8544 types of references.
8546 2014-08-10 Marek Polacek <polacek@redhat.com>
8549 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
8550 * c.opt (Wc90-c99-compat): Add option.
8552 2014-08-07 Trevor Saunders <tsaunders@mozilla.com>
8554 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
8556 2014-08-03 Marek Polacek <polacek@redhat.com>
8558 * c-common.c (check_case_value): Add location_t parameter. Use it.
8559 (c_add_case_label): Pass loc to check_case_value.
8561 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
8563 * cilk.c: Use hash_map instead of pointer_map.
8565 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
8567 * c-gimplify.c: Use hash_set instead of pointer_set.
8569 2014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
8572 * array-notation-common.c (extract_array_notation_exprs): Handling
8575 2014-08-01 Jakub Jelinek <jakub@redhat.com>
8577 * c-common.h (min_align_of_type): Removed prototype.
8578 * c-common.c (min_align_of_type): Removed.
8579 * c-ubsan.h (ubsan_maybe_instrument_reference,
8580 ubsan_maybe_instrument_member_call): New prototypes.
8581 * c-ubsan.c: Include stor-layout.h and builtins.h.
8582 (ubsan_maybe_instrument_reference_or_call,
8583 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
8586 2014-07-31 Marc Glisse <marc.glisse@inria.fr>
8589 * c.opt (-Wreturn-local-addr): Move to common.opt.
8591 2014-07-30 Jason Merrill <jason@redhat.com>
8596 * c.opt (-fuse-all-virtuals): New.
8598 2014-07-30 Tom Tromey <tromey@redhat.com>
8601 * c.opt (Wdesignated-init): New option.
8602 * c-common.c (c_common_attribute_table): Add "designated_init".
8603 (handle_designated_init): New function.
8605 2014-07-24 Marek Polacek <polacek@redhat.com>
8608 * c-opts.c (c_finish_options): If -imacros is in effect, return.
8610 2014-07-16 Dodji Seketeli <dodji@redhat.com>
8612 PR preprocessor/60723 - missing system-ness marks for macro tokens
8613 * c-ppoutput.c (struct print::prev_was_system_token): New data
8615 (init_pp_output): Initialize it.
8616 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
8617 (do_line_change): Return a flag saying if a line marker was
8619 (scan_translation_unit): Detect if the system-ness of the token we
8620 are about to emit is different from the one of the previously
8621 emitted token. If so, emit a line marker. Avoid emitting useless
8622 adjacent line markers. Avoid emitting line markers for tokens
8623 originating from the expansion of built-in macros.
8624 (scan_translation_unit_directives_only): Adjust.
8626 2014-07-15 Marek Polacek <polacek@redhat.com>
8628 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
8629 TYPE_MAX_VALUE is NULL.
8631 2014-07-14 Jakub Jelinek <jakub@redhat.com>
8634 * c.opt (Wmemset-transposed-args): New warning.
8636 2014-07-10 Jason Merrill <jason@redhat.com>
8640 * c.opt (-fuse-all-virtuals): New.
8642 2014-07-09 Richard Biener <rguenther@suse.de>
8645 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
8646 using unsigned arithmetic if overflow does not wrap instead of
8647 if overflow is undefined.
8649 2014-07-06 Marek Polacek <polacek@redhat.com>
8652 * c.opt (Wsizeof-array-argument): New option.
8654 2014-07-03 Jakub Jelinek <jakub@redhat.com>
8656 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
8657 comments->count <= 1, as comments->entries might be NULL.
8659 2014-07-01 Marek Polacek <polacek@redhat.com>
8661 * c.opt (Wint-conversion): New option.
8663 2014-07-01 Marek Polacek <polacek@redhat.com>
8666 * c.opt (Wincompatible-pointer-types): New option.
8668 2014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
8671 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
8672 Do not discard TYPE_QUALS of type.
8674 2014-06-26 Jason Merrill <jason@redhat.com>
8676 * c-common.h (enum cxx_dialect): Add cxx1z.
8677 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
8678 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
8680 2014-06-26 Teresa Johnson <tejohnson@google.com>
8682 * c-common.h (get_dump_info): Declare.
8683 * c-gimplify.c (c_genericize): Use saved dump files.
8684 * c-opts.c (c_common_parse_file): Begin and end dumps
8685 once around parsing invocation.
8686 (get_dump_info): New function.
8688 2014-06-23 Marek Polacek <polacek@redhat.com>
8689 Andrew MacLeod <amacleod@redhat.com>
8692 * c-common.c (get_atomic_generic_size): Don't segfault if the
8693 type doesn't have a size.
8695 2014-06-20 Marek Polacek <polacek@redhat.com>
8697 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
8698 (ubsan_walk_array_refs_r): New function.
8699 (c_genericize): Instrument array bounds.
8700 * c-ubsan.c: Include "internal-fn.h".
8701 (ubsan_instrument_division): Mark instrumented arrays as having
8702 side effects. Adjust ubsan_type_descriptor call.
8703 (ubsan_instrument_shift): Likewise.
8704 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
8705 (ubsan_instrument_bounds): New function.
8706 (ubsan_array_ref_instrumented_p): New function.
8707 (ubsan_maybe_instrument_array_ref): New function.
8708 * c-ubsan.h (ubsan_instrument_bounds): Declare.
8709 (ubsan_array_ref_instrumented_p): Declare.
8710 (ubsan_maybe_instrument_array_ref): Declare.
8712 2014-06-20 Hale Wang <hale.wang@arm.com>
8715 * c.opt (fshort-enums): Add to LTO.
8716 * c.opt (fshort-wchar): Likewise.
8718 2014-06-16 Marek Polacek <polacek@redhat.com>
8721 * c.opt (Wswitch-bool): Add Var.
8723 2014-06-12 Jakub Jelinek <jakub@redhat.com>
8726 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
8727 #pragma omp target teams or
8728 #pragma omp {,target }teams distribute simd.
8730 2014-06-12 Jason Merrill <jason@redhat.com>
8732 * c.opt (Wabi=, fabi-compat-version): New.
8733 * c-opts.c (c_common_handle_option): Handle -Wabi=.
8734 (c_common_post_options): Handle flag_abi_compat_version default.
8735 Disallow -fabi-compat-version=1.
8736 * c-common.h (abi_version_crosses): New.
8738 2014-06-11 Jan Hubicka <hubicka@ucw.cz>
8740 * c-common.c (handle_section_attribute): Update handling for
8741 section names that are no longer trees.
8743 2014-06-10 Jakub Jelinek <jakub@redhat.com>
8746 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
8747 (omp_pragmas): ... back here.
8749 2014-06-05 Marek Polacek <polacek@redhat.com>
8752 * c-common.c (warn_logical_not_parentheses): New function.
8753 * c-common.h (warn_logical_not_parentheses): Declare.
8754 * c.opt (Wlogical-not-parentheses): New option.
8756 2014-06-04 Marek Polacek <polacek@redhat.com>
8759 * c-common.c (check_case_bounds): Add location parameter.
8761 (c_add_case_label): Pass loc to check_case_bounds.
8763 2014-06-03 Marek Polacek <polacek@redhat.com>
8766 * c.opt (Wswitch-bool): New option.
8768 2014-05-22 Thomas Schwinge <thomas@codesourcery.com>
8770 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
8772 (record_types_used_by_current_var_decl): Move prototype to where
8775 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
8776 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
8777 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
8779 2014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
8781 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
8782 * c-common.c (c_common_nodes_and_builtins): Don't initialize
8784 * c-pretty-print.c (pp_c_void_constant): New function.
8785 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
8786 (c_pretty_printer::expression): Handle VOID_CST.
8787 * cilk.c (extract_free_variables): Likewise.
8788 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
8789 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
8791 2014-05-17 Trevor Saunders <tsaunders@mozilla.com>
8793 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
8794 * c-pragma.c (push_alignment): Adjust.
8795 (handle_pragma_push_options): Likewise.
8797 2014-05-09 Marek Polacek <polacek@redhat.com>
8800 * c-common.c (check_user_alignment): Return -1 if alignment is error
8802 (handle_aligned_attribute): Don't call default_conversion on
8804 (handle_vector_size_attribute): Likewise.
8805 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
8806 (handle_sentinel_attribute): Call default_conversion and allow even
8807 integral types as an argument.
8809 2014-05-08 Marek Polacek <polacek@redhat.com>
8812 * c-common.c (min_align_of_type): New function factored out from...
8813 (c_sizeof_or_alignof_type): ...here.
8814 * c-common.h (min_align_of_type): Declare.
8816 2014-05-08 Marek Polacek <polacek@redhat.com>
8819 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
8820 parameter type of main.
8822 2014-05-07 DJ Delorie <dj@redhat.com>
8824 * c-cppbuiltin.c (print_bits_of_hex): New.
8825 (builtin_define_type_minmax): Print values using hex so as not to
8826 require a pre-computed list of string values.
8828 2014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
8829 Mike Stump <mikestump@comcast.net>
8830 Richard Sandiford <rdsandiford@googlemail.com>
8832 * c-ada-spec.c: Include wide-int.h.
8833 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
8834 (dump_generic_ada_node): Use wide-int interfaces.
8835 * c-common.c: Include wide-int-print.h.
8836 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
8837 (pointer_int_sum): Use wide-int interfaces.
8838 (c_common_nodes_and_builtins): Use make_int_cst.
8839 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
8840 (handle_alloc_size_attribute): Use wide-int interfaces.
8841 (get_nonnull_operand): Likewise.
8842 * c-format.c (get_constant): Use tree_fits_uhwi_p.
8843 * c-lex.c: Include wide-int.h.
8844 (narrowest_unsigned_type): Take a widest_int rather than two
8846 (narrowest_signed_type): Likewise.
8847 (interpret_integer): Update accordingly. Use wide-int interfaces.
8848 (lex_charconst): Use wide-int interfaces.
8849 * c-pretty-print.c: Include wide-int.h.
8850 (pp_c_integer_constant): Use wide-int interfaces.
8851 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
8852 INT_CST_LT_UNSIGNED.
8854 2014-05-06 Richard Biener <rguenther@suse.de>
8856 * c-opts.c (c_common_post_options): For -freestanding,
8857 -fno-hosted and -fno-builtin disable pattern recognition
8858 if not enabled explicitely.
8860 2014-05-02 Marek Polacek <polacek@redhat.com>
8862 * c.opt (Wsizeof-pointer-memaccess): Describe option.
8864 2014-05-01 Marek Polacek <polacek@redhat.com>
8867 * c.opt (Wdiscarded-qualifiers): Add.
8869 2014-04-30 Marek Polacek <polacek@redhat.com>
8871 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
8872 INT_MIN / -1 sanitization only for integer types.
8874 2014-04-25 Marek Polacek <polacek@redhat.com>
8877 * c-common.c (handle_noinline_attribute): Warn if the attribute
8878 conflicts with always_inline attribute.
8879 (handle_always_inline_attribute): Warn if the attribute conflicts
8880 with noinline attribute.
8882 2014-04-25 Marek Polacek <polacek@redhat.com>
8885 * c-common.c (check_main_parameter_types): Warn about variadic main.
8887 2014-04-24 Mike Stump <mikestump@comcast.net>
8889 * c.opt (Wshadow-ivar): Default to on.
8891 2014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
8893 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
8895 2014-04-23 Marek Polacek <polacek@redhat.com>
8897 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
8899 2014-04-22 Jakub Jelinek <jakub@redhat.com>
8902 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
8903 if flag_sanitize_undefined_trap_on_error.
8904 (ubsan_instrument_division, ubsan_instrument_shift,
8905 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
8906 if !flag_sanitize_recover.
8908 2014-04-22 Marc Glisse <marc.glisse@inria.fr>
8911 * c-common.c (registered_builtin_types): Make non-static.
8912 * c-common.h (registered_builtin_types): Declare.
8914 2014-04-14 Richard Biener <rguenther@suse.de>
8915 Marc Glisse <marc.glisse@inria.fr>
8918 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
8919 apply may-alias the scalar pointer type when applicable.
8921 2014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
8924 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
8925 as possible argument for Cilk_spawn.
8927 2014-04-11 Tobias Burnus <burnus@net-b.de>
8930 * c.opt (Wformat-signedness): Add
8931 * c-format.c(check_format_types): Use it.
8933 2014-04-11 Jason Merrill <jason@redhat.com>
8936 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
8937 default_conversion for an array argument.
8939 2014-04-08 Marek Polacek <polacek@redhat.com>
8942 * c-ubsan.c: Include asan.h.
8943 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
8945 2014-04-03 Nathan Sidwell <nathan@codesourcery.com>
8947 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
8949 2014-04-02 Marek Polacek <polacek@redhat.com>
8951 * c-common.h (c_expand_expr): Remove declaration.
8953 2014-03-28 Jakub Jelinek <jakub@redhat.com>
8956 * c-common.c (add_atomic_size_parameter): When creating new
8957 params vector, push the size argument first.
8959 2014-03-26 Jakub Jelinek <jakub@redhat.com>
8961 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
8962 ubsan_instrument_vla, ubsan_instrument_return): Adjust
8963 ubsan_create_data callers.
8965 2014-03-22 Jakub Jelinek <jakub@redhat.com>
8968 * c-opts.c (c_finish_options): Restore cb_file_change call to
8971 2014-03-13 Jakub Jelinek <jakub@redhat.com>
8974 * c-pragma.c (apply_pragma_weak): Only look at
8975 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
8976 DECL_ASSEMBLER_NAME_SET_P (decl).
8977 (maybe_apply_pending_pragma_weaks): Exit early if
8978 vec_safe_is_empty (pending_weaks) rather than only when
8980 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
8981 set assembler name back to NULL afterwards.
8983 2014-03-11 Jason Merrill <jason@redhat.com>
8985 * c.opt: Add -std=gnu++14.
8987 2014-03-11 Ian Bolton <ian.bolton@arm.com>
8989 * c-opts.c (c_common_post_options): Don't override
8990 -ffp-contract=fast if unsafe-math-optimizations is on.
8992 2014-03-08 Paulo Matos <paulo@matos-sorge.com>
8994 * c.opt: Enable LTO FE for fshort-double.
8996 2014-03-07 Jason Merrill <jason@redhat.com>
8998 * c.opt: Add -std=c++14.
9000 2014-03-06 Marek Polacek <polacek@redhat.com>
9003 * cilk.c (contains_cilk_spawn_stmt): New function.
9004 (contains_cilk_spawn_stmt_walker): Likewise.
9005 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
9006 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
9008 2014-03-03 Jakub Jelinek <jakub@redhat.com>
9010 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
9011 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
9012 even when flag_preprocess_only.
9014 2014-02-26 Jason Merrill <jason@redhat.com>
9018 * c-common.c (shorten_compare): Don't check
9019 c_inhibit_evaluation_warnings.
9021 2014-02-19 Jakub Jelinek <jakub@redhat.com>
9024 * c-common.c (c_common_nodes_and_builtins): When initializing
9025 c_uint{16,32,64}_type_node, also set corresponding
9026 uint{16,32,64}_type_node to the same value.
9029 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
9030 for PRAGMA_IVDEP if flag_preprocess_only.
9032 2014-02-12 Jakub Jelinek <jakub@redhat.com>
9035 * c-common.c (merge_tlist): If copy is true, call new_tlist,
9036 if false, add ADD itself, rather than vice versa.
9037 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
9038 copy. For SAVE_EXPR, only call merge_tlist once.
9040 2014-02-08 Jakub Jelinek <jakub@redhat.com>
9043 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
9045 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
9047 (c_common_attribute_table): Add alloc_align and assume_aligned
9050 2014-02-06 Marek Polacek <polacek@redhat.com>
9053 * c-common.c (warn_for_sign_compare): Call warning_at with location
9056 2014-02-05 Marek Polacek <polacek@redhat.com>
9059 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
9062 2014-02-04 Marek Polacek <polacek@redhat.com>
9065 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
9068 2014-02-03 Marc Glisse <marc.glisse@inria.fr>
9072 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
9073 handle_vector_size_attribute, handle_nonnull_attribute): Call
9074 default_conversion on the attribute argument.
9075 (handle_nonnull_attribute): Increment the argument number.
9077 2014-01-31 Marek Polacek <polacek@redhat.com>
9080 * c-common.c (add_atomic_size_parameter): Pass vNULL to
9081 build_function_call_vec.
9082 (resolve_overloaded_builtin): Likewise.
9083 * c-common.h (build_function_call_vec): Adjust declaration.
9085 2014-01-30 Marek Polacek <polacek@redhat.com>
9088 * c-common.h (unsafe_conversion_p): Adjust declaration.
9089 (warnings_for_convert_and_check): Likewise.
9090 (convert_and_check): Likewise.
9091 * c-common.c (unsafe_conversion_p): Add location parameter. Call
9092 expansion_point_location_if_in_system_header on it.
9093 (warnings_for_convert_and_check): Add location parameter. Call
9094 expansion_point_location_if_in_system_header on it. Use it.
9095 (convert_and_check): Add location parameter. Use it.
9096 (conversion_warning): Likewise.
9097 (c_add_case_label): Adjust convert_and_check calls.
9098 (scalar_to_vector): Adjust unsafe_conversion_p calls.
9100 2014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
9102 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
9104 * c-pragma.c (init_pragma): Likewise.
9107 2014-01-23 Marek Polacek <polacek@redhat.com>
9110 * c-common.c (shorten_compare): Add location_t parameter.
9111 * c-common.h (shorten_binary_op): Adjust declaration.
9113 2014-01-23 Marek Polacek <polacek@redhat.com>
9116 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
9117 * c-common.h: Declare it.
9119 2014-01-20 Eric Botcazou <ebotcazou@adacore.com>
9121 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
9122 * c-ada-spec.c (dump_ads): Likewise.
9123 (cpp_check): Likewise.
9124 (dump_ada_specs): Likewise.
9126 2014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
9129 * c-common.c (handle_no_instrument_function_attribute): Allow
9130 no_instrument_function attribute in class member
9131 definition/declaration.
9133 2014-01-15 Jakub Jelinek <jakub@redhat.com>
9136 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
9137 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
9138 being COMPOUND_EXPR.
9139 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
9140 operand a SAVE_EXPR and second MODIFY_EXPR.
9142 2014-01-09 Jakub Jelinek <jakub@redhat.com>
9145 * c-pch.c (c_common_write_pch): Call
9146 prepare_target_option_nodes_for_pch.
9148 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
9150 Update copyright years
9152 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
9154 * array-notation-common.c, c-cilkplus.c: Use the standard form for
9155 the copyright notice.
9157 2013-12-28 Eric Botcazou <ebotcazou@adacore.com>
9159 * c-ada-spec.c (print_constructor): New function.
9160 (print_destructor): Retrieve the origin of the destructor.
9161 (print_ada_declaration): Revamp handling of constructors/destructors.
9163 2013-12-23 Stuart Hastings <stuart@apple.com>
9164 Bill Maddox <maddox@google.com>
9165 Jason Merrill <jason@redhat.com>
9167 * c.opt: Add -fdeclone-ctor-dtor.
9168 * c-opts.c (c_common_post_options): Default to on iff -Os.
9170 2013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
9172 * c-common.c (c_common_attribute_table): Added "cilk simd function"
9174 * c-pragma.h (enum pragma_cilk_clause): Remove.
9175 (enum pragma_omp_clause): Added the following fields:
9176 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
9177 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
9178 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
9179 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
9180 PRAGMA_CILK_CLAUSE_UNIFORM.
9183 2013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
9185 * cilk.c (cilk_outline): Made this function non-static.
9186 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
9187 (create_cilk_wrapper): Added a new parameter: a function pointer.
9188 (c_install_body_w_frame_cleanup): Remove
9189 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
9190 * c-common.h (cilk_outline): New prototype.
9191 (gimplify_cilk_spawn): Removed two parameters.
9192 (cilk_install_body_with_frame_cleanup): New prototype.
9193 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
9194 CILK_SPAWN_STMT case.
9196 2013-12-11 Bernd Schmidt <bernds@codesourcery.com>
9198 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
9200 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
9201 (int_array_type_node): Remove.
9202 * c-common.c (c_common_nodes_and_builtins): Don't build it.
9204 2013-12-05 Marek Polacek <polacek@redhat.com>
9207 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
9208 [ADJUST_FIELD_ALIGN].
9210 2013-12-04 Joseph Myers <joseph@codesourcery.com>
9213 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
9214 and check field alignment if set.
9215 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
9216 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
9218 2013-12-04 Jakub Jelinek <jakub@redhat.com>
9219 Marek Polacek <polacek@redhat.com>
9221 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
9222 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
9224 2013-11-29 H.J. Lu <hongjiu.lu@intel.com>
9227 * cilk.c (gimplify_cilk_spawn): Properly handle function without
9230 2013-11-29 Jakub Jelinek <jakub@redhat.com>
9233 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
9234 goto invalid. If it is error_mark_node, don't issue further
9237 2013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
9239 * c.opt (Wopenmp-simd): New.
9241 2013-11-22 Jakub Jelinek <jakub@redhat.com>
9243 * c-ubsan.h (ubsan_instrument_return): New prototype.
9244 * c-ubsan.c (ubsan_instrument_return): New function.
9246 2013-11-22 Andrew MacLeod <amacleod@redhat.com>
9248 * c-common.c: Add required include files from gimple.h.
9249 * c-gimplify.c: Likewise.
9252 2013-11-22 David Malcolm <dmalcolm@redhat.com>
9254 * c-common.c (unsafe_conversion_p): Remove use of
9255 EXPR_LOC_OR_HERE macro.
9256 (conversion_warning): Likewise.
9257 (warnings_for_convert_and_check): Likewise.
9258 (warn_for_collisions_1): Likewise.
9259 (shorten_compare): Likewise, and remove use of in_system_header
9260 macro, using the location from the former.
9261 * c-lex.c (dump_one_header): Remove use of input_filename macro.
9262 (cb_def_pragma): Remove use of in_system_header macro.
9263 (lex_string): Likewise.
9264 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
9266 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
9267 Mike Stump <mikestump@comcast.net>
9268 Richard Sandiford <rdsandiford@googlemail.com>
9270 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
9271 instead of TREE_INT_CST_LOW, in cases where there is a protecting
9272 tree_fits_shwi_p or tree_fits_uhwi_p.
9273 (dump_generic_ada_node): Likewise.
9274 * c-format.c (check_format_arg): Likewise.
9275 * c-pretty-print.c (pp_c_integer_constant): Likewise.
9277 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
9279 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
9281 2013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
9284 * c-common.c (unsafe_conversion_p): Make this function
9285 return an enumeration with more detail.
9286 (conversion_warning): Use the new return type of
9287 unsafe_conversion_p to separately warn either about conversions
9288 that lower floating point number precision or about the other
9289 kinds of conversions.
9290 * c-common.h (enum conversion_safety): New enumeration.
9291 (unsafe_conversion_p): switching return type to
9292 conversion_safety enumeration.
9293 * c.opt: Adding new warning -Wfloat-conversion and
9294 enabling it with -Wconversion.
9296 2013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
9298 * c-opts.c: Include plugin.h.
9299 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
9301 2013-11-19 Marek Polacek <polacek@redhat.com>
9303 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
9305 (ubsan_instrument_shift): Likewise.
9306 (ubsan_instrument_vla): Likewise.
9308 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9310 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
9311 cast to unsigned type.
9313 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9315 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
9317 (complete_array_type): Update comment to refer to tree_to_[su]hwi
9318 rather than tree_low_cst.
9320 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9322 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
9323 tree_to_uhwi throughout.
9325 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9327 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
9328 tree_low_cst (..., 0) with tree_to_shwi throughout.
9330 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9332 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
9333 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
9335 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9337 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
9338 host_integerp (..., 0) with tree_fits_shwi_p throughout.
9340 2013-11-15 Aldy Hernandez <aldyh@redhat.com>
9342 * c-cilkplus.c: New file.
9343 * c-common.c (readonly_error): Add location argument.
9344 * c-common.h (readonly_error): Same.
9345 (c_finish_cilk_clauses): Protoize.
9346 (c_check_cilk_loop): Same.
9347 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
9348 Do not fail on error_mark_node.
9349 Abstract increment canonicalization to here...
9350 (c_omp_for_incr_canonicalize_ptr): New.
9351 c-pragma.c (init_pragma): Register "simd" pragma.
9352 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
9353 (enum pragma_cilk_clause): New.
9355 2013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
9357 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
9358 wchar_type and host_integerp checks.
9360 2013-11-14 Andrew MacLeod <amacleod@redhat.com>
9362 * c-common.c: Likewise.
9363 * c-gimplify.c: Likewise.
9366 2013-11-14 Diego Novillo <dnovillo@google.com>
9368 * c-common.c: Include fold-const.h.
9369 Include stor-layout.h.
9371 Include stringpool.h.
9374 Include trans-mem.h.
9375 * c-cppbuiltin.c: Include stor-layout.h.
9376 Include stringpool.h.
9377 * c-format.c: Include stringpool.h.
9378 * c-lex.c: Include stringpool.h.
9379 Include stor-layout.h.
9380 * c-pragma.c: Include stringpool.h.
9383 Include gcc-symtab.h.
9384 * c-pretty-print.c: Include stor-layout.h.
9386 * cilk.c: Include stringpool.h.
9389 2013-11-13 Joseph Myers <joseph@codesourcery.com>
9391 * c-common.h (enum rid): Add RID_AUTO_TYPE.
9392 * c-common.c (c_common_reswords): Add __auto_type.
9393 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
9395 2013-11-12 Andrew MacLeod <amacleod@redhat.com>
9397 * c-common.c: Include gimplify.h.
9398 * c-gimplify.c: Likewise.
9400 * c-omp.c: Include gimple-expr.h instead of gimple.h.
9401 * c-ubsan.c: Don't include gimple.h.
9403 2013-11-12 Joseph Myers <joseph@codesourcery.com>
9405 * c-common.c (c_common_reswords): Add _Thread_local.
9407 2013-11-09 Joseph Myers <joseph@codesourcery.com>
9409 * c-common.c (atomic_size_supported_p): New function.
9410 (resolve_overloaded_atomic_exchange)
9411 (resolve_overloaded_atomic_compare_exchange)
9412 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
9413 Use it instead of comparing size with a local list of sizes.
9415 2013-11-07 Andrew MacLeod <amacleod@redhat.com>
9416 Joseph Myers <joseph@codesourcery.com>
9418 * c-common.h (enum rid): Add RID_ATOMIC.
9419 * c-common.c (c_common_reswords): Add _Atomic.
9420 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
9421 (keyword_is_type_qualifier): Accept RID_ATOMIC.
9422 * c-format.c (check_format_types): Check for extra _Atomic
9423 qualifiers in format argument.
9424 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
9425 (pp_c_type_qualifier_list): Mention _Atomic in comment.
9427 2013-11-06 Tobias Burnus <burnus@net-b.de>
9429 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
9431 2013-11-06 Joseph Myers <joseph@codesourcery.com>
9433 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
9435 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
9436 to mean lack of IEEE 754 support.
9438 2013-11-05 Tobias Burnus <burnus@net-b.de>
9440 * c.opt (-Wdate-time): New option
9441 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
9443 2013-11-05 Joseph Myers <joseph@codesourcery.com>
9445 * c-cppbuiltin.c (cpp_iec_559_value): Test
9446 flag_excess_precision_cmdline not flag_excess_precision.
9448 2013-11-05 Tobias Burnus <burnus@net-b.de>
9450 * c.opt (fopenmp-simd): New option.
9451 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
9452 (omp_pragmas): ... this new struct.
9453 (c_pp_lookup_pragma): Also walk omp_pragmas.
9454 (init_pragma): Init pragmas for -fopenmp-simd.
9456 2013-11-04 Marek Polacek <polacek@redhat.com>
9459 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
9461 2013-11-04 Joseph Myers <joseph@codesourcery.com>
9463 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
9465 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
9467 2013-11-04 Eric Botcazou <ebotcazou@adacore.com>
9469 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
9470 (dump_ada_specs): Adjust prototype of second callback.
9471 * c-ada-spec.c (cpp_check): New global variable.
9472 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
9473 (print_generic_ada_decl): Likewise.
9474 (has_static_fields): Change return type to bool and add guard.
9475 (has_nontrivial_methods): New predicate.
9476 (is_tagged_type): Change return type to bool.
9477 (separate_class_package): Call has_nontrivial_methods.
9478 (pp_ada_tree_identifier): Minor tweaks.
9479 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
9480 (dump_ada_array_domains): Likewise.
9481 (dump_ada_array_type): Likewise.
9482 (dump_template_types): Remove cpp_check parameter and do not pass it to
9483 dump_generic_ada_node.
9484 (dump_ada_template): Likewise.
9485 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
9487 (print_ada_methods): Change return type to integer. Remove cpp_check
9488 parameter and do not pass it down.
9489 (dump_nested_types): Remove cpp_check parameter and do not pass it to
9490 dump_generic_ada_node.
9491 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
9493 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
9494 down. Use has_nontrivial_methods to recognize C++ classes. Use return
9495 value of print_ada_methods.
9496 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
9497 Set cpp_check to it before invoking dump_ada_nodes.
9498 (dump_ada_specs): Likewise.
9500 2013-11-03 Marek Polacek <polacek@redhat.com>
9502 * c-ubsan.c: Don't include hash-table.h.
9503 (ubsan_instrument_vla): New function.
9504 * c-ubsan.h: Declare it.
9506 2013-10-31 David Malcolm <dmalcolm@redhat.com>
9508 Automated part of renaming of symtab_node_base to symtab_node.
9510 Patch autogenerated by rename_symtab.py from
9511 https://github.com/davidmalcolm/gcc-refactoring-scripts
9512 revision 58bb219cc090b2f4516a9297d868c245495ee622
9514 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
9515 symtab_node_base to symtab_node.
9517 2013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
9519 Implement C++14 digit separators.
9520 * c-lex.c (interpret_float): Remove digit separators from scratch string
9521 before building real literal.
9523 2013-10-30 Jakub Jelinek <jakub@redhat.com>
9525 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
9527 2013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
9529 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
9531 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
9533 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
9534 (insert_cilk_frame): New prototype.
9535 (cilk_init_builtins): Likewise.
9536 (gimplify_cilk_spawn): Likewise.
9537 (c_cilk_install_body_w_frame_cleanup): Likewise.
9538 (cilk_detect_spawn_and_unwrap): Likewise.
9539 (cilk_set_spawn_marker): Likewise.
9540 (build_cilk_sync): Likewise.
9541 (build_cilk_spawn): Likewise.
9544 2013-10-29 David Malcolm <dmalcolm@redhat.com>
9546 Patch autogenerated by refactor_symtab.py from
9547 https://github.com/davidmalcolm/gcc-refactoring-scripts
9548 revision 58bb219cc090b2f4516a9297d868c245495ee622
9550 * c-gimplify.c (c_genericize): Update for conversion of symtab types
9551 to a true class hierarchy.
9552 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
9554 2013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
9556 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
9558 2013-10-26 Jeff Law <law@redhat.com>
9560 * c-common.c (c_define_builtins): Remove mudflap support.
9561 * c.opt: Ignore and warn for mudflap options.
9563 2013-10-24 Tobias Burnus <burnus@net-b.de>
9566 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
9567 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
9569 2013-10-23 Jason Merrill <jason@redhat.com>
9571 * c-format.c (gcc_cxxdiag_char_table): Add %X.
9573 2013-10-11 Jakub Jelinek <jakub@redhat.com>
9575 * c-common.h (omp_clause_mask::operator !=): New method.
9576 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
9577 instead of if (mask & something) tests everywhere.
9579 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
9580 201307 instead of 201107.
9581 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
9582 (c_common_attribute_table): Add "omp declare target" and
9583 "omp declare simd" attributes.
9584 (handle_omp_declare_target_attribute,
9585 handle_omp_declare_simd_attribute): New functions.
9586 * c-omp.c: Include c-pragma.h.
9587 (c_finish_omp_taskgroup): New function.
9588 (c_finish_omp_atomic): Add swapped argument, if true,
9589 build the operation first with rhs, lhs arguments and use NOP_EXPR
9591 (c_finish_omp_for): Add code argument, pass it down to make_code.
9592 (c_omp_split_clauses): New function.
9593 (c_split_parallel_clauses): Removed.
9594 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
9595 c_omp_declare_simd_clauses_to_decls): New functions.
9596 * c-common.h (omp_clause_mask): New type.
9597 (OMP_CLAUSE_MASK_1): Define.
9598 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
9599 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
9600 omp_clause_mask::operator |, omp_clause_mask::operator &,
9601 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
9602 omp_clause_mask::operator ==): New methods.
9603 (enum c_omp_clause_split): New.
9604 (c_finish_omp_taskgroup): New prototype.
9605 (c_finish_omp_atomic): Add swapped argument.
9606 (c_finish_omp_for): Add code argument.
9607 (c_omp_split_clauses): New prototype.
9608 (c_split_parallel_clauses): Removed.
9609 (c_omp_declare_simd_clauses_to_numbers,
9610 c_omp_declare_simd_clauses_to_decls): New prototypes.
9611 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
9612 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
9613 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
9614 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
9615 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
9616 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
9617 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
9618 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
9619 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
9620 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
9621 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
9622 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
9623 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
9624 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
9625 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
9626 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
9627 PRAGMA_OMP_CLAUSE_UNIFORM.
9629 2013-10-09 Marc Glisse <marc.glisse@inria.fr>
9631 PR tree-optimization/20318
9632 * c-common.c (handle_returns_nonnull_attribute): New function.
9633 (c_common_attribute_table): Add returns_nonnull.
9635 2013-10-03 Marc Glisse <marc.glisse@inria.fr>
9638 * c.opt (fcheck-new): Move to common.opt.
9640 2013-09-25 Marek Polacek <polacek@redhat.com>
9641 Jakub Jelinek <jakub@redhat.com>
9644 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
9645 an expression if we can prove it is correct.
9646 (ubsan_instrument_division): Likewise. Remove unnecessary
9649 2013-09-18 Marek Polacek <polacek@redhat.com>
9652 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
9654 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
9656 2013-09-14 Iain Sandoe <iain@codesourcery.com>
9659 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
9660 fobjc-gc, freplace-objc-classes): Accept for LTO.
9662 2013-09-13 Jacek Caban <jacek@codeweavers.com>
9664 * c-target.def: New hook
9666 2013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
9669 * c.opt (Wdelete-incomplete): Add.
9671 2013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
9673 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
9674 (vector_types_compatible_elements_p): New function.
9675 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
9677 (vector_types_compatible_elements_p): Declare.
9679 2013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
9681 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
9682 a virtual member function.
9683 (pp_simple_type_specifier): Remove.
9684 (pp_c_type_specifier): Likewise.
9685 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
9686 Rename from pp_c_type_specifier. Adjust.
9687 (c_pretty_printer::c_pretty_printer): Do not assign to
9688 simple_type_specifier.
9690 2013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
9692 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
9694 (c_pretty_printer::storage_class_specifier): Likewise.
9695 (c_pretty_printer::initializer): Likewise.
9696 (pp_declaration): Remove.
9697 (pp_declaration_specifiers): Likewise.
9698 (pp_abstract_declarator): Likewise.
9699 (pp_declarator): Likewise.
9700 (pp_type_id): Likewise.
9701 (pp_statement): Likewise.
9702 (pp_constant): Likewise.
9703 (pp_id_expression): Likewise.
9704 (pp_primary_expression): Likewise.
9705 (pp_unary_expression): Likewise.
9706 (pp_multiplicative_expression): Likewise.
9707 (pp_conditional_expression): Likewise.
9708 (pp_assignment_expression): Likewise.
9709 (pp_expression): Likewise.
9710 (pp_c_type_id): Likewise.
9711 (pp_c_storage_class_specifier): Likewise.
9712 * c-pretty-print.c (pp_c_type_cast): Tidy.
9713 (pp_c_pointer): Likewise.
9714 (pp_c_type_specifier): Likewise.
9715 (pp_c_parameter_type_list): Likewise.
9716 (pp_c_function_definition): Likewise.
9717 (pp_c_init_declarator): Likewise.
9718 (pp_c_initializer_list): Likewise.
9719 (pp_c_constructor_elts): Likewise.
9720 (c_pretty_printer::direct_abstract_declarator): Likewise.
9721 (c_pretty_printer::declaration_specifiers): Likewise.
9722 (c_pretty_printer::primary_expression): Likewise.
9723 (c_pretty_printer::postfix_expression): Likewise.
9724 (c_pretty_printer::type_id): Rename from pp_c_type_id.
9725 (c_pretty_printer::storage_class_specifier): Rename from
9726 pp_c_storage_class_specifier.
9727 (c_pretty_printer::initializer): Rename from pp_c_initializer.
9728 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
9729 storage_class_specifier, initializer, offset_list, flags.
9731 2013-08-30 Marek Polacek <polacek@redhat.com>
9733 * c-ubsan.c: New file.
9734 * c-ubsan.h: New file.
9736 2013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
9738 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
9740 (c_pretty_printer::declaration_specifiers): Likewise.
9741 (c_pretty_printer::declarator): Likewise.
9742 (c_pretty_printer::abstract_declarator): Likewise.
9743 (c_pretty_printer::direct_abstract_declarator): Likewise.
9744 (c_pretty_printer::direct_declarator): Likewise.
9745 (c_pretty_printer::function_specifier): Likewise.
9746 (pp_declaration): Adjust.
9747 (pp_declaration_specifiers): Likewise.
9748 (pp_abstract_declarator): Likewise.
9749 (pp_direct_declarator): Likewise.
9750 (pp_function_specifier): Likewise.
9751 (pp_direct_abstract_declarator): Remove as unused.
9752 (pp_c_declaration): Remove.
9753 (pp_c_declaration_specifiers): Likewise.
9754 (pp_c_declarator): Likewise.
9755 (pp_c_direct_declarator): Likewise.
9756 (pp_c_function_specifier): Likewise.
9757 (pp_c_direct_abstract_declarator): Likewise.
9758 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
9759 from pp_c_abstract_declarator. Adjust.
9760 (c_pretty_printer::direct_abstract_declarator): Rename from
9761 pp_c_direct_abstract_declarator. Adjust.
9762 (c_pretty_printer::function_specifier): Rename from
9763 pp_c_function_specifier. Adjust.
9764 (c_pretty_printer::declaration_specifiers): Rename from
9765 pp_c_declaration_specifiers. Adjust.
9766 (c_pretty_printer::direct_declarator): Rename from
9767 pp_c_direct_declarator. Adjust.
9768 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
9769 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
9770 (c_pretty_printer::c_pretty_printer): Do not assign to
9771 declaration, declaration_specifiers, declarator,
9772 direct_declarator, direct_abstract_declarator, function_specifier.
9774 2013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
9776 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
9777 virtual member function.
9778 (c_pretty_printer::multiplicative_expression): Likewise.
9779 (c_pretty_printer::conditional_expression): Likewise.
9780 (c_pretty_printer::assignment_expression): Likewise.
9781 (c_pretty_printer::expression): Likewise.
9782 (pp_unary_expression): Adjust.
9783 (pp_multiplicative_expression): Likewise.
9784 (pp_assignment_expression): Likewise.
9785 (pp_conditional_expression): Likewise.
9786 (pp_expression): Likewise.
9787 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
9788 from pp_c_unary_expression. Adjust.
9789 (c_pretty_printer::multiplicative_expression): Rename from
9790 pp_c_multiplicative_expression. Adjust.
9791 (c_pretty_printer::conditional_expression): Rename from
9792 pp_c_conditional_expression. Adjust.
9793 (c_pretty_printer::assignment_expression): Rename from
9794 pp_c_assignment_expression. Adjust.
9795 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
9796 (c_pretty_printer::c_pretty_printer): Do not assign to
9797 unary_expression, multiplicative_expression,
9798 conditional_expression, expression.
9800 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
9802 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
9803 virtual member function.
9804 (pp_postfix_expression): Adjust.
9805 (pp_c_postfix_expression): Remove.
9806 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
9807 from pp_c_postfix_expression. Adjust.
9808 (c_pretty_printer::c_pretty_printer): Do not assign to
9811 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
9813 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
9814 virtua member function.
9815 (pp_primary_expression): Adjust.
9816 (pp_c_primary_expression): Remove.
9817 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
9818 from pp_c_primary_expression. Adjust.
9819 (pp_c_initializer_list): Use pp_primary_expression.
9820 (c_pretty_printer::c_pretty_printer): Do not assign to
9823 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
9825 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
9826 * c-pretty-print.c (M_): Remove.
9827 (c_pretty_printer::translate_string): Define.
9828 (pp_c_type_specifier): Use it.
9829 (pp_c_primary_expression): Likewise.
9830 (pp_c_expression): Likewise.
9832 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
9834 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
9836 (pp_c_id_expression): Remove.
9837 (pp_id_expression): Adjust.
9838 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
9839 pp_c_id_expression. Adjust.
9840 (pp_c_postfix_expression): Use pp_id_expression.
9841 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
9843 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
9845 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
9847 (pp_constant): Adjust.
9848 (pp_c_constant): Remove.
9849 * c-pretty-print.c (c_pretty_printer::constant): Rename from
9850 pp_c_constant. Adjust.
9852 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
9853 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
9855 2013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
9857 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
9858 (c_pretty_printer::c_pretty_printer): Declare.
9859 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
9860 c_pretty_printer_init. Adjust.
9861 (print_c_tree): Do not call c_pretty_printer_init.
9862 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
9864 2013-08-09 Arnaud Charlet <charlet@adacore.com>
9866 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
9868 2013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
9871 * c-common.c (pointer_int_sum): Add bool parameter.
9872 * c-common.h (pointer_int_sum): Adjust declaration.
9874 2013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
9876 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
9877 c_pretty_printer variable.
9879 2013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
9881 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
9883 (pp_c_base): Likewise. Adjust users.
9884 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
9885 (pp_c_whitespace): Do not call pp_base.
9886 (pp_c_left_paren): Likewise.
9887 (pp_c_right_paren): Likewise.
9888 (pp_c_left_brace): Likewise.
9889 (pp_c_right_brace): Likewise.
9890 (pp_c_left_bracket): Likewise.
9891 (pp_c_right_bracket): Likewise.
9892 (pp_c_dot): Likewise.
9893 (pp_c_ampersand): Likewise.
9894 (pp_c_star): Likewise.
9895 (pp_c_arrow): Likewise.
9896 (pp_c_semicolon): Likewise.
9897 (pp_c_complement): Likewise.
9898 (pp_c_exclamation): Likewise.
9899 (pp_c_direct_declarator): Likewise.
9900 (pp_c_ws_string): Likewise.
9901 (pp_c_identifier): Likewise.
9902 (pp_c_statement): Likewise.
9903 (print_c_tree): Likewise.
9905 2013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
9908 * c-common.c (c_parse_error): Catch user-defined literal tokens and
9909 provide useful error strings.
9911 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
9913 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
9914 printer functions instead of pp_string or operators and punctuators.
9915 (dump_generic_ada_node): Likewise.
9916 * c-pretty-print.c (pp_c_type_specifier): Likewise.
9917 (pp_c_relational_expression): Likewise.
9918 (pp_c_logical_or_expression): Likewise.
9920 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
9922 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
9923 functions instead of pp_character.
9924 (pp_ada_tree_identifier): Likewise.
9925 (dump_ada_double_name): Likewise.
9926 (dump_ada_function_declaration): Likewise.
9927 (dump_ada_array_domains): Likewise.
9928 (dump_template_types): Likewise.
9929 (dump_generic_ada_node): Likewise.
9930 (print_ada_declaration): Likewise.
9931 (print_ada_struct_decl): Likewise.
9932 * c-pretty-print.c (pp_c_integer_constant): Likewise.
9934 2013-07-23 Tom Tromey <tromey@redhat.com>
9936 * c-common.h (enum rid) <RID_GENERIC>: New constant.
9937 * c-common.c (c_common_reswords): Add _Generic.
9939 2013-07-21 OndÅej BÃlka <neleai@seznam.cz>
9941 * c-common.c: Fix typos.
9942 * c-common.h: Likewise.
9944 2013-07-13 Lubos Lunak <l.lunak@suse.cz>
9947 * c-common.c (c_common_attribute_table): Add warn_unused.
9948 (handle_warn_unused_attribute): New.
9950 2013-07-10 Jakub Jelinek <jakub@redhat.com>
9952 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
9953 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
9955 2013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
9958 * c.opt: Add Wconditionally-supported.
9960 2013-07-08 Graham Stott <graham.stott@btinternet.com>
9962 * array-notation-common.c (length_mismatch_in_expr_p): Delete
9963 unused variables l_length and l_node.
9965 2013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
9968 * c-common.c (complete_array_type): Delay folding first index
9969 like other indices. When folding, check for index overflow.
9971 2013-06-27 Marc Glisse <marc.glisse@inria.fr>
9974 * c-common.h (c_build_vec_perm_expr): New complain argument.
9975 * c-common.c (c_build_vec_perm_expr): Likewise.
9976 Use save_expr also in C++.
9978 2013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
9980 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
9981 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
9982 * c-opts.c (c_common_post_options): Likewise.
9984 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
9986 * array-notation-common.c (length_mismatch_in_expr): Changed the
9987 parameter type's from a dynamic array to a vec_tree. Also removed
9988 the size parameters.
9989 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
9992 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
9994 * c-common.h (struct cilkplus_an_parts): New structure.
9995 (struct cilkplus_an_loop_parts): Likewise.
9996 (cilkplus_extract_an_triplets): New prototype.
9997 (fix_sec_implicit_args): Likewise.
9998 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
9999 (fix_sec_implicit_args): Likewise.
10001 2013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
10003 * array-notation-common.c (find_inv_trees): Removed an unwanted
10005 * c-common.h (struct inv_list::additional_tcodes): Changed type from
10006 enum rid to enum tree_code.
10008 2013-06-11 Jan Hubicka <jh@suse.cz>
10010 * c-common.c (handle_alias_ifunc_attribute): Do not set
10011 DECL_EXTERNAL for weakref variables.
10012 * c-pragma.c (handle_pragma_weak): Make sure aliases
10013 are not declared as external.
10015 2013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
10017 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
10018 function from c/c-array-notation.c.
10019 (is_cilkplus_reduce_builtin): Likewise.
10020 (find_rank): Likewise.
10021 (extract_array_notation_exprs): Likewise.
10022 (replace_array_notations): Likewise.
10023 (find_inv_trees): Likewise.
10024 (replace_inv_trees): Likewise.
10025 (contains_array_notation_expr): Likewise.
10026 (find_correct_array_notation_type): Likewise.
10027 * c-common.h (struct inv_list): Moved this struct from the file
10028 c/c-array-notation.c and added a new field called additional tcodes.
10029 (length_mismatch_in_expr_p): New prototype.
10030 (is_cilkplus_reduce_builtin): Likewise.
10031 (find_rank): Likewise.
10032 (extract_array_notation_exprs): Likewise.
10033 (replace_array_notation): Likewise.
10034 (find_inv_trees): Likewise.
10035 (replace_inv_trees): Likewise.
10036 (find_correct_array_notation_type): Likewise.
10038 2013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
10040 * c-common.c (c_define_builtins): When cilkplus is enabled, the
10041 function array_notation_init_builtins is called.
10042 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
10043 * c-common.def (ARRAY_NOTATION_REF): New tree.
10044 * c-common.h (build_array_notation_expr): New function declaration.
10045 (build_array_notation_ref): Likewise.
10046 (extract_sec_implicit_index_arg): New extern declaration.
10047 (is_sec_implicit_index_fn): Likewise.
10048 (ARRAY_NOTATION_CHECK): New define.
10049 (ARRAY_NOTATION_ARRAY): Likewise.
10050 (ARRAY_NOTATION_START): Likewise.
10051 (ARRAY_NOTATION_LENGTH): Likewise.
10052 (ARRAY_NOTATION_STRIDE): Likewise.
10053 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
10054 ARRAY_NOTATION_REF.
10055 (pp_c_expression): Likewise.
10056 * c.opt (flag_enable_cilkplus): New flag.
10057 * array-notation-common.c: New file.
10059 2013-05-14 Jakub Jelinek <jakub@redhat.com>
10062 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
10064 2013-05-10 Marc Glisse <marc.glisse@inria.fr>
10066 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
10069 2013-05-07 Han Shen <shenhan@google.com>
10071 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
10073 2013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
10075 * c-common.c (check_user_alignment): Emit error for negative values.
10077 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
10079 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
10081 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
10083 * c-cppbuiltin.c (c_cpp_builtins): Do not define
10084 __GXX_EXPERIMENTAL_CXX1Y__.
10086 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
10087 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
10089 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
10090 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
10091 to simply use OPT_Wpointer_arith.
10092 (c_sizeof_or_alignof_type): Likewise.
10094 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
10096 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
10098 2013-04-12 Jakub Jelinek <jakub@redhat.com>
10100 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
10101 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
10104 2013-04-07 Steven Bosscher <steven@gcc.gnu.org>
10106 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
10108 2013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
10110 * c-common.c (pointer_int_sum): Remove dead code.
10112 2013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
10114 PR middle-end/56524
10115 * c-common.c (handle_optimize_attribute): Don't call
10116 save_optabs_if_changed.
10118 2013-03-05 Jakub Jelinek <jakub@redhat.com>
10120 PR middle-end/56461
10121 * c-pch.c (pch_init): Free target_validity at the end.
10123 2013-03-04 Jakub Jelinek <jakub@redhat.com>
10125 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
10127 2013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
10128 Jakub Jelinek <jakub@redhat.com>
10131 * c-common.c (handle_no_sanitize_address_attribute): New function.
10132 (c_common_attribute_table): Add no_sanitize_address attribute.
10133 (handle_no_address_safety_analysis_attribute): Add
10134 no_sanitize_address attribute, not no_address_safety_analysis
10137 2013-02-18 Aldy Hernandez <aldyh@redhat.com>
10140 * c-common.c (handle_optimize_attribute): Call
10141 save_optabs_if_changed.
10143 2013-02-18 Jakub Jelinek <jakub@redhat.com>
10144 Steven Bosscher <steven@gcc.gnu.org>
10147 * c-opts.c (c_common_post_options): If debug info is enabled
10148 and non-dwarf*, refuse to load PCH files and when writing PCH
10151 2013-02-05 Jakub Jelinek <jakub@redhat.com>
10153 PR middle-end/56167
10154 * c-common.c (handle_error_attribute): Fix condition.
10156 2013-01-30 Jakub Jelinek <jakub@redhat.com>
10159 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
10161 2013-01-18 Jason Merrill <jason@redhat.com>
10164 * c.opt (-fextern-tls-init): New.
10165 * c-opts.c (c_common_post_options): Handle it.
10167 2013-01-09 Jakub Jelinek <jakub@redhat.com>
10170 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
10171 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
10172 and is either negative or bigger or equal to type precision
10173 of the first operand.
10175 2012-12-03 Marek Polacek <polacek@redhat.com>
10178 * c-common.c (check_user_alignment): Swap order of tests,
10179 check TREE_CODE first.
10181 2012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
10184 * c-common.h (overflow_type): New enum.
10185 (build_userdef_literal): Add overflow_type argument.
10186 (tree_userdef_literal): Add overflow_type.
10187 (USERDEF_LITERAL_OVERFLOW): New access macro.
10188 * c-common.c (build_userdef_literal): Add overflow_type
10190 * c-lex.c (c_lex_with_flags): Add overflow_type to
10191 build_userdef_literal calls.
10192 (interpret_integer, interpret_float): Add overflow_type argument.
10194 2012-11-28 Richard Biener <rguenther@suse.de>
10197 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
10198 here and use a type with proper overflow behavior for types that would
10199 need to be promoted for the arithmetic.
10201 2012-11-23 Jakub Jelinek <jakub@redhat.com>
10204 * c-common.c (handle_no_address_safety_analysis_attribute): New
10206 (c_common_attribute_table): Add no_address_safety_analysis.
10208 2012-11-16 Simon Baldwin <simonb@google.com>
10210 * c.opt: Add f[no-]canonical-system-headers.
10211 * c-opts.c (c_common_handle_option): Handle
10212 OPT_fcanonical_system_headers.
10214 2012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
10217 * c-opts.c (c_common_handle_option): Set new flags.
10218 * c.opt: Describe new flags.
10220 2012-11-09 Jason Merrill <jason@redhat.com>
10222 * c.opt (Wabi-tag): New.
10224 2012-11-09 Andi Kleen <ak@linux.intel.com>
10227 * c-common.c (get_atomic_generic_size): Mask with
10230 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
10233 * c.opt (Wformat): Make it Alias Wformat=1.
10234 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
10235 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
10237 (Wformat=): RejectNegative. Use LangEnabledBy.
10238 (Wnonnull): Use LangEnabledBy.
10239 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
10240 * c-format.c (set_Wformat): Delete.
10241 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
10242 (maybe_read_dollar_number): Likewise.
10243 (avoid_dollar_number): Likewise.
10244 (finish_dollar_format_checking): Likewise.
10245 (check_format_info): Likewise.
10246 (check_format_info_main): Likewise.
10247 (check_format_types): Likewise.
10248 (format_type_warning): Likewise.
10249 * c-common.c (int): Likewise.
10250 (check_function_sentinel): Likewise.
10251 * c-common.h (warn_format,set_Wformat): Do not declare here.
10253 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
10256 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
10257 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
10259 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
10261 (Wvariadic-macros): Init(1).
10262 * c-opts.c (c_common_handle_option): Do not handle them
10264 (c_common_post_options): Likewise.
10265 (sanitize_cpp_opts): warn_unused_macros is now
10266 cpp_warn_unused_macros.
10267 (push_command_line_include): Likewise.
10268 * c-common.c (warn_unknown_pragmas): Do not define.
10269 * c-common.h (warn_unknown_pragmas): Do not declare.
10271 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
10274 * c-common.c (conversion_warning): Handle conditional expressions.
10276 2012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
10279 * c.opt (Wreturn_local_addr): Define new option.
10281 2012-10-25 Jason Merrill <jason@redhat.com>
10283 * c.opt (Wvirtual-move-assign): New.
10285 * c.opt (Winherited-variadic-ctor): New.
10287 2012-10-25 Marc Glisse <marc.glisse@inria.fr>
10290 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
10292 2012-10-23 Joseph Myers <joseph@codesourcery.com>
10294 * c-common.h (pch_cpp_save_state): Declare.
10295 * c-target.def (c_preinclude): New hook.
10296 * c-opts.c (done_preinclude): New.
10297 (push_command_line_include): Handle default preincluded header.
10298 (cb_file_change): Call pch_cpp_save_state when calling
10299 push_command_line_include.
10300 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
10301 (pch_cpp_save_state): New.
10302 (pch_init): Call pch_cpp_save_state conditionally, instead of
10303 calling cpp_save_state.
10305 2012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
10309 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
10310 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
10311 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
10312 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
10313 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
10314 * c-opts.c (c_common_handle_option): Remove explicit handling from
10316 (c_common_post_options): Likewise.
10318 2012-10-18 Eric Botcazou <ebotcazou@adacore.com>
10320 * c-ada-spec.c (LOCATION_COL): Delete.
10321 (compare_location): New function.
10322 (compare_node): Use it.
10323 (compare_comment): Likewise.
10325 2012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
10329 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
10330 * c-opts.c (c_common_handle_option): Do not set them here. Add
10332 (c_common_post_options): Likewise.
10334 2012-10-16 Eric Botcazou <ebotcazou@adacore.com>
10336 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
10337 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
10338 Remove POINTER_TYPE handling, add large unsigned handling and use
10339 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
10341 2012-10-12 Jakub Jelinek <jakub@redhat.com>
10344 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
10345 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
10346 locs and array of 3 trees instead of just single loc and single
10347 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
10348 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
10349 For *cmp* builtins that take two sources strings report warnings
10350 about first and second source, not about destination and source.
10352 2012-10-12 Marc Glisse <marc.glisse@inria.fr>
10355 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
10357 2012-10-11 Eric Botcazou <ebotcazou@adacore.com>
10359 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
10360 declaring something coming from another file.
10362 2012-10-10 Arnaud Charlet <charlet@adacore.com>
10365 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
10367 2012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
10370 * c-common.c (warn_about_parentheses): Add location_t parameter;
10371 use EXPR_LOC_OR_LOC.
10372 * c-common.h: Update declaration.
10374 2012-10-09 Marc Glisse <marc.glisse@inria.fr>
10377 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
10378 more operations. Make error messages optional.
10379 * c-common.h (enum stv_conv): Moved from c-typeck.c.
10380 (scalar_to_vector): Declare.
10382 2012-10-08 Jason Merrill <jason@redhat.com>
10384 * c-common.c (c_common_reswords): Add thread_local.
10386 2012-10-08 Dodji Seketeli <dodji@redhat.com>
10388 PR c++/53528 C++11 attribute support
10389 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
10391 * c-common.c (check_cxx_fundamental_alignment_constraints): New
10393 (handle_aligned_attribute): In choose strictest alignment
10394 among many. Use new check_cxx_fundamental_alignment_constraints.
10395 (handle_transparent_union_attribute): In c++11 attribute syntax,
10396 don't look through typedefs.
10398 2012-10-04 Arnaud Charlet <charlet@adacore.com>
10400 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
10401 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
10404 2012-09-25 Dehao Chen <dehao@google.com>
10406 PR middle-end/54645
10407 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
10408 map when read in the pch.
10410 2012-09-18 Arnaud Charlet <charlet@adacore.com>
10412 * c-ada-spec.c: Style fixes.
10414 2012-09-18 Thomas Quinot <quinot@adacore.com>
10416 * c.opt (-fada-spec-parent): Define new command line switch.
10417 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
10418 is specified, generate binding spec as a child of the specified unit.
10420 2012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
10421 Manuel López-Ibáñez <manu@gcc.gnu.org>
10424 * c.opt ([Winit-self]): Enabled by -Wall in C++.
10426 2012-08-23 Arnaud Charlet <charlet@adacore.com>
10428 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
10429 for pointers, and add missing Convention C pragma.
10430 (print_ada_struct_decl): Add missing aliased keyword.
10431 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
10433 2012-08-17 Jakub Jelinek <jakub@redhat.com>
10435 * c-common.c (sizeof_pointer_memaccess_warning): New function.
10436 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
10437 * c-opts.c (c_common_handle_option): Enable it for -Wall.
10438 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
10439 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
10441 2012-08-10 Richard Guenther <rguenther@suse.de>
10443 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
10445 2012-08-07 Steven Bosscher <steven@gcc.gnu.org>
10447 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
10448 instead of separate pp_newline and pp_flush.
10449 (print_c_tree): Likewise.
10451 2012-07-26 Richard Henderson <rth@redhat.com>
10453 * c-common.c (handle_hot_attribute): Allow labels.
10454 (handle_cold_attribute): Likewise.
10456 2012-07-20 Jakub Jelinek <jakub@redhat.com>
10459 * c-common.c (check_function_nonnull): Handle multiple nonnull
10460 attributes properly.
10462 2012-07-16 Steven Bosscher <steven@gcc.gnu.org>
10464 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
10465 * c-ada-spec.c: Likewise.
10466 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
10468 2012-07-14 Steven Bosscher <steven@gcc.gnu.org>
10470 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
10471 Remove code conditional on it.
10473 2012-07-11 Steven Bosscher <steven@gcc.gnu.org>
10475 * c-gimplify.c: Do not include basic-block.h.
10476 * c-common.c: Do not include linfuncs.h.
10478 2012-07-08 Steven Bosscher <steven@gcc.gnu.org>
10480 * c-common.h: Include tree.h.
10482 2012-07-02 Jason Merrill <jason@redhat.com>
10485 * c-common.c (get_priority): Call default_conversion.
10487 2012-07-01 Uros Bizjak <ubizjak@gmail.com>
10489 * c-pch.c (c_common_write_pch): Remove unused variables.
10491 2012-06-29 Steven Bosscher <steven@gcc.gnu.org>
10493 * cppspec.c: Moved from gcc/ to here.
10495 2012-06-27 Kai Tietz <ktietz@redhat.com>
10497 PR preprocessor/37215
10498 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
10500 2012-06-21 Steven Bosscher <steven@gcc.gnu.org>
10502 * c-common.h (c_common_print_pch_checksum): Remove.
10503 * c-pch.c: Do not include output.h.
10504 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
10505 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
10506 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
10507 (struct c_pch_header): Remove.
10508 (get_ident): Update gpch version.
10509 (pch_init): Do not print executable_checksum to asm_out_file.
10510 Do not fail if there is no asm_out_file to read back from. Set
10511 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
10512 (c_common_write_pch): Verify that nothing was written to asm_out_file
10513 since pch_init was called. Do not write a c_pch_header, and do not
10514 copy from asm_out_file to the PCH.
10515 (c_common_read_pch): Do not read a c_pch_header, and do not restore
10516 the content of asm_out_file from the PCH.
10517 (c_common_print_pch_checksum): Remove.
10518 * c-opts.c (c_common_init): Print out executable_checksum directly.
10520 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
10522 * c-target.def (objc_declare_unresolved_class_reference,
10523 objc_declare_class_definition): Add new hooks.
10525 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
10527 * c-lex.c: Do not include output.h.
10528 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
10529 Remove uses of ASM_OUTPUT_IDENT.
10531 2012-06-15 Marc Glisse <marc.glisse@inria.fr>
10534 * c-common.h (c_build_vec_perm_expr): Move decl here.
10535 * c-common.c (c_build_vec_perm_expr): Move definition
10538 2012-06-06 Steven Bosscher <steven@gcc.gnu.org>
10540 * c.opt (fconserve-space): Turn into a no-op.
10542 2012-06-04 Sterling Augustine <saugustine@google.com>
10544 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
10545 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
10546 both the start and end of the function.
10548 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
10550 * c-common.c: Do not include output.h.
10551 * c-pragma.c: Likewise.
10553 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
10555 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
10556 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
10557 (lang_decl_name): Handle namespace decls.
10559 2012-05-31 Steven Bosscher <steven@gcc.gnu.org>
10561 * c-ada-spec.c: Do not include output.h.
10562 * c-semantics.c: Likewise.
10564 2012-05-29 Joseph Myers <joseph@codesourcery.com>
10566 * c-common.c: Fix typo.
10568 2012-05-29 Michael Matz <matz@suse.de>
10570 * c-common.h (c_expand_decl): Remove prototype.
10572 2012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
10574 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
10575 * c-opts.c (c_common_handle_option): Remove code handling
10576 warn_missing_braces.
10578 2012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
10581 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
10584 2012-05-22 Dodji Seketeli <dodji@redhat.com>
10587 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
10589 2012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
10591 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
10592 * c-opts.c (c_common_handle_option): Do not handle explicitly
10593 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
10595 2012-05-16 Dodji Seketeli <dodji@redhat.com>
10597 PR preprocessor/7263
10598 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
10599 to cpp_classify_number. For diagnostics, use the precise location
10600 instead of the global input_location.
10602 2012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
10605 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
10607 2012-05-14 Bernd Schmidt <bernds@codesourcery.com>
10609 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
10611 2012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
10614 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
10615 Wreorder): Use LangEnabledBy.
10616 * c-opts.c (c_common_handle_option): Do not enable them
10617 explicitly. Call lang-specific generated functions.
10618 (c_common_post_options): Do not set them here.
10620 2012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
10622 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
10623 Wmissing-field-initializers,Wmissing-parameter-type,
10624 Wold-style-declaration,Woverride-init): Use EnabledBy.
10625 * c-opts.c (c_common_post_options): Do not set here explicitly.
10627 2012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
10630 * c-opts.c (c_common_handle_option): Use handle_generated_option
10631 to enable sub-options.
10633 2012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
10636 * c-common.c (warnings_for_convert_and_check): Use warning_at.
10638 2012-05-10 Richard Guenther <rguenther@suse.de>
10640 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
10641 adjust commentary about TYPE_IS_SIZETYPE types.
10643 2012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
10646 * c-common.c (warn_logical_operator): Check that argument of
10647 integer_zerop is not NULL.
10649 2012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
10652 * c-common.c (warn_logical_operator): Do not warn if either side
10653 is already true or false.
10655 2012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
10658 * c-common.c (expr_original_type): New.
10659 (shorten_compare): Do not warn for enumeration types.
10661 2012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
10663 * c.opt (fpermissive): Add Var(flag_permissive).
10665 2012-04-30 Marc Glisse <marc.glisse@inria.fr>
10668 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
10669 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
10671 2012-04-30 Dodji Seketeli <dodji@redhat.com>
10673 Add -Wvarargs option
10674 * c.opt (Wvarargs): Define new option.
10676 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
10678 * c-common.c (check_function_arguments): Replace
10679 Wmissing-format-attribute with Wsuggest-attribute=format.
10681 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
10683 * c.opt (Wsuggest-attribute=format): New. Alias of
10684 Wmissing-format-attribute.
10685 * c-format.c (decode_format_type): Replace
10686 Wmissing-format-attribute with Wsuggest-attribute=format.
10687 (check_function_format): Likewise.
10689 2012-04-27 Ollie Wild <aaw@google.com>
10691 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
10692 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
10693 * c.opt: Add Wliteral-suffix.
10695 2012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
10698 * c.opt (Wpedantic): New.
10699 (pedantic): Alias Wpedantic.
10700 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
10701 (c_common_post_options): Likewise.
10702 (sanitize_cpp_opts): Likewise.
10703 * c-lex.c (interpret_float): Likewise.
10704 * c-format.c (check_format_types): Likewise.
10705 * c-common.c (pointer_int_sum): Likewise.
10706 (c_sizeof_or_alignof_type): Likewise.
10707 (c_add_case_label): Likewise.
10708 (c_do_switch_warnings): Likewise.
10709 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
10711 2012-04-15 Jason Merrill <jason@redhat.com>
10714 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
10715 (C_STD_NAME): Distinguish between C++98 and C++11.
10717 2012-04-11 Eric Botcazou <ebotcazou@adacore.com>
10720 * c-common.h (uint16_type_node): Rename into...
10721 (c_uint16_type_node): ...this.
10722 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
10723 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
10725 2012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
10727 * c-common.c (warn_if_unused_value): Move definition to here.
10728 * c-common.h (warn_if_unused_value): Move declaration to here.
10730 2012-03-23 William Bader <williambader@hotmail.com>
10732 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
10734 2012-03-20 Jason Merrill <jason@redhat.com>
10736 * c-common.h (enum cxx_dialect): Add cxx1y.
10737 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
10739 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
10740 * c-opts.c (c_common_post_options): Likewise.
10741 (set_std_cxx1y): New.
10742 (c_common_handle_option): Call it.
10743 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
10745 2012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
10748 * c.opt ([Wuseless-cast]): Add.
10750 2012-03-16 Richard Guenther <rguenther@suse.de>
10752 * c-pretty-print.c (pp_c_initializer_list): Adjust.
10754 2012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
10757 * c.opt (ftemplate-backtrace-limit) Add.
10759 2012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10761 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
10763 * c-pragma.c (handle_pragma_extern_prefix): Remove.
10764 (init_pragma): Don't register extern_prefix.
10766 2012-03-12 Richard Guenther <rguenther@suse.de>
10768 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
10769 (builtin_type_for_size): Likewise.
10771 2012-02-13 Jakub Jelinek <jakub@redhat.com>
10774 * c-common.c (sync_resolve_params): Don't decide whether to convert
10775 or not based on TYPE_SIZE comparison, convert whenever arg_type
10776 is unsigned INTEGER_TYPE.
10778 2012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
10781 * c.opt ([Wunused-local-typedefs]): Fix description.
10783 2012-01-24 Mike Stump <mikestump@comcast.net>
10785 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
10788 2012-01-18 Richard Guenther <rguenther@suse.de>
10790 * c-opts.c (c_common_post_options): Reset LTO flags if
10791 we are about to generate a PCH.
10793 2012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
10796 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
10797 use pp_unsigned_wide_integer.
10799 2012-01-10 Richard Guenther <rguenther@suse.de>
10801 PR middle-end/51806
10802 * c-opts.c (c_common_handle_option): Move -Werror handling
10803 to language independent code.
10805 2012-01-05 Richard Guenther <rguenther@suse.de>
10807 PR middle-end/51764
10808 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
10811 2011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
10814 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
10815 of array types with an unknown bound.
10817 2011-12-20 Joseph Myers <joseph@codesourcery.com>
10819 * c-common.c (flag_isoc99): Update comment to refer to C11.
10820 (flag_isoc1x): Change to flag_isoc11.
10821 * c-common.h (flag_isoc99): Update comment to refer to C11.
10822 (flag_isoc1x): Change to flag_isoc11.
10823 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
10825 * c-opts.c (set_std_c1x): Change to set_std_c11.
10826 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
10828 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
10829 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
10830 * c.opt (std=c1x): Change to std=c11. Document as non-draft
10832 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
10833 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
10834 (std=gnu1x): Make alias of std=gnu11.
10836 2011-12-19 Jason Merrill <jason@redhat.com>
10839 * c-common.c (handle_transparent_union_attribute): Check the first
10840 field if the type is complete.
10842 2011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
10845 * c-common.c (RID_IS_FINAL): Add.
10846 * c-common.h (RID_IS_FINAL): Add.
10848 2011-11-30 Iain Sandoe <iains@gcc.gnu.org>
10850 * c.opt (fgnu-runtime): Provide full description.
10851 (fnext-runtime): Likewise.
10852 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
10854 2011-11-28 Andrew MacLeod <amacleod@redhat.com>
10856 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
10857 predefines in one place. Add LOCK_FREE predefines.
10858 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
10861 2011-11-24 Andrew MacLeod <amacleod@redhat.com>
10864 * c-common.c (get_atomic_generic_size): Check for various error
10866 (resolve_overloaded_atomic_exchange,
10867 resolve_overloaded_atomic_compare_exchange,
10868 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
10869 error_mark_node for error conditions.
10871 2011-11-08 Richard Guenther <rguenther@suse.de>
10873 PR middle-end/51010
10874 * c-pretty-print.c (pp_c_expression): Handle SSA_NAMEs.
10876 2011-11-07 Richard Henderson <rth@redhat.com>
10877 Aldy Hernandez <aldyh@redhat.com>
10878 Torvald Riegel <triegel@redhat.com>
10880 Merged from transactional-memory.
10882 * c-common.c (handle_tm_wrap_attribute,
10883 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
10884 (struct c_common_reswords): Added __transaction* keywords.
10885 (struct c_common_attribute_table): Added transaction* and tm_regparm
10887 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
10889 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
10890 find_tm_attribute): Declare.
10892 2011-11-07 Jason Merrill <jason@redhat.com>
10895 * c-common.c, c-common.h: Revert yesterday's changes.
10897 2011-11-06 Jason Merrill <jason@redhat.com>
10900 * c-common.c (decl_has_visibility_attr): Split out from...
10901 (c_determine_visibility): ...here.
10902 * c-common.h: Declare it.
10904 2011-11-06 Joseph Myers <joseph@codesourcery.com>
10906 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
10907 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
10909 (check_user_alignment): New. Split out of
10910 handle_aligned_attribute. Disallow integer constants with
10911 noninteger types. Conditionally allow zero.
10912 (handle_aligned_attribute): Use check_user_alignment.
10913 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
10915 2011-11-06 Andrew MacLeod <amacleod@redhat.com>
10916 Richard Henderson <rth@redhat.com>
10918 Merged from cxx-mem-model.
10920 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
10921 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
10922 parameters that are the same type size.
10923 (get_atomic_generic_size): New. Find size of generic
10924 atomic function parameters and do typechecking.
10925 (add_atomic_size_parameter): New. Insert size into parameter list.
10926 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
10927 either __atomic_exchange_n or external library call.
10928 (resolve_overloaded_atomic_compare_exchange): Restructure
10929 __atomic_compare_exchange to either _n variant or external library call.
10930 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
10931 __atomic_load_n or an external library call.
10932 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
10933 __atomic_store_n or an external library call.
10934 (resolve_overloaded_builtin): Handle new __atomic builtins.
10936 2011-11-04 Eric Botcazou <ebotcazou@adacore.com>
10939 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
10940 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
10941 <INDIRECT_REF>: Return the argument.
10942 <ARRAY_REF>: Remove special code for negative offset.
10943 Call fold_build_pointer_plus instead of size_binop.
10944 (fold_offsetof): Remove STOP_REF argument and adjust.
10945 * c-common.h (fold_offsetof_1): Declare.
10946 (fold_offsetof): Remove STOP_REF argument.
10948 2011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
10951 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
10952 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
10953 Wnarrowing for C++0x and C++98.
10954 * c.opt ([Wnarrowing]): Update.
10956 2011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
10959 * c.opt: Add Wzero-as-null-pointer-constant.
10961 2011-10-31 Jason Merrill <jason@redhat.com>
10963 * c.opt (-fdeduce-init-list): Off by default.
10966 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
10967 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
10968 and -Wc++11-compat.
10969 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
10971 2011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
10974 * c.opt (fvisibility-inlines-hidden): Description change.
10976 2011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
10978 Implement C++11 user-defined literals.
10979 * c-common.c (build_userdef_literal): New.
10980 * c-common.def: New tree code.
10981 * c-common.h (tree_userdef_literal): New tree struct and accessors.
10982 * c-lex.c (interpret_float): Add suffix parm.
10983 (c_lex_with_flags): Build literal tokens.
10985 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
10989 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
10992 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
10993 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
10994 Wnarrowing for C++0x and C++98.
10995 * c.opt ([Wnarrowing]): Update.
10997 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
11000 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
11001 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
11002 Wnarrowing for C++0x and C++98.
11003 * c.opt ([Wnarrowing]): Update.
11005 2011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
11008 * c-common.c (conversion_warning): Remove code looking for
11009 artificial operands.
11011 2011-10-18 Dodji Seketeli <dodji@redhat.com>
11014 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
11015 !NO_IMPLICIT_EXTERN_C.
11017 2011-10-17 Michael Spertus <mike_spertus@symantec.com>
11019 * c-common.c (c_common_reswords): Add __bases,
11021 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
11023 2011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
11026 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
11028 2011-10-15 Tom Tromey <tromey@redhat.com>
11029 Dodji Seketeli <dodji@redhat.com>
11031 * c.opt (fdebug-cpp): New option.
11032 * c-opts.c (c_common_handle_option): Handle the option.
11033 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
11034 output stream in parameter. Factorized from ...
11035 (maybe_print_line): ... this. Dump location debug information when
11036 -fdebug-cpp is in effect.
11037 (print_line_1): New static function. Takes an output stream in
11038 parameter. Factorized from ...
11039 (print_line): ... here. Dump location information when -fdebug-cpp
11041 (scan_translation_unit): Dump location information when
11042 -fdebug-cpp is in effect.
11044 2011-10-15 Tom Tromey <tromey@redhat.com>
11045 Dodji Seketeli <dodji@redhat.com>
11047 * c.opt (ftrack-macro-expansion): New option. Handle it with and
11049 * c-opts.c (c_common_handle_option)<case
11050 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
11051 cases. Handle -ftrack-macro-expansion with and without argument.
11053 2011-10-15 Tom Tromey <tromey@redhat.com>
11054 Dodji Seketeli <dodji@redhat.com>
11056 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
11057 (print_line, cb_define, do_line_change): Adjust to avoid touching
11058 the internals of struct line_map. Use the public API instead.
11059 * c-pch.c (c_common_read_pch): Likewise.
11060 * c-lex.c (fe_file_change): Likewise.
11062 2011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
11065 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
11067 2011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
11070 * c-pretty-print.c (pp_c_floating_constant): Output
11071 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
11073 2011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
11075 * c-common.c (def_builtin_1): Delete old interface with two
11076 parallel arrays to hold standard builtin declarations, and replace
11077 it with a function based interface that can support creating
11078 builtins on the fly in the future. Change all uses, and poison
11079 the old names. Make sure 0 is not a legitimate builtin index.
11080 * c-omp.c (c_finish_omp_barrier): Ditto.
11081 (c_finish_omp_taskwait): Ditto.
11082 (c_finish_omp_flush): Ditto.
11084 2011-10-11 Tristan Gingold <gingold@adacore.com>
11086 * c.opt: (fallow-parameterless-variadic-functions): New.
11088 2011-09-08 Dodji Seketeli <dodji@redhat.com>
11090 PR c++/33255 - Support -Wunused-local-typedefs warning
11091 * c-common.h (struct c_language_function::local_typedefs): New
11093 (record_locally_defined_typedef, maybe_record_typedef_use)
11094 (maybe_warn_unused_local_typedefs): Declare new functions.
11095 * c-common.c (record_locally_defined_typedef)
11096 (maybe_record_typedef_use)
11097 (maybe_warn_unused_local_typedefs): Define new functions.
11098 * c.opt: Declare new -Wunused-local-typedefs flag.
11100 2011-09-06 Eric Botcazou <ebotcazou@adacore.com>
11102 PR middle-end/50266
11103 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
11106 2011-09-05 Richard Guenther <rguenther@suse.de>
11108 * c-common.c (complete_array_type): Use ssize_int (-1) instead
11109 of integer_minus_one_node for empty array upper bounds.
11111 2011-08-28 Dodji Seketeli <dodji@redhat.com>
11113 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
11114 it's the first time it's being called on this main TU.
11116 2011-08-24 Richard Guenther <rguenther@suse.de>
11119 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
11121 2011-08-22 Gabriel Charette <gchare@google.com>
11123 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
11124 defined in cpp_init_builtins and c_cpp_builtins.
11126 2011-08-19 Joseph Myers <joseph@codesourcery.com>
11128 * c-common.c (c_common_reswords): Add __builtin_complex.
11129 * c-common.h (RID_BUILTIN_COMPLEX): New.
11131 2011-08-18 Joseph Myers <joseph@codesourcery.com>
11133 * c-common.c (c_common_reswords): Add _Noreturn.
11134 (keyword_is_function_specifier): Handle RID_NORETURN.
11135 * c-common.h (RID_NORETURN): New.
11137 2011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
11139 * c-common.c (unsafe_conversion_p): New function. Check if it is
11140 unsafe to convert an expression to the type.
11141 (conversion_warning): Adjust, use unsafe_conversion_p.
11142 * c-common.h (unsafe_conversion_p): New function declaration.
11144 2011-08-02 Jakub Jelinek <jakub@redhat.com>
11146 * c-common.h (c_finish_omp_atomic): Adjust prototype.
11147 (c_finish_omp_taskyield): New prototype.
11148 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
11149 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
11150 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
11151 or RHS1 have side-effects, evaluate those too in the right spot,
11152 if it is a decl and LHS is also a decl, error out if they
11154 (c_finish_omp_taskyield): New function.
11155 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
11156 * c-pragma.c (omp_pragmas): Add taskyield.
11157 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
11158 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
11159 PRAGMA_OMP_CLAUSE_MERGEABLE.
11161 2011-07-25 Dodji Seketeli <dodji@redhat.com>
11163 * c-common.h (set_underlying_type): Remove parm name from
11166 2011-07-25 Romain Geissler <romain.geissler@gmail.com>
11168 * c-pretty-print.h: Search c-common.h in c-family.
11170 2011-07-22 Jason Merrill <jason@redhat.com>
11173 * c.opt (Wnarrowing): New.
11176 * c-common.h: Declare c_linkage_bindings.
11177 * c-pragma.c (handle_pragma_redefine_extname): Use it.
11180 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
11181 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
11182 as flag_isoc99 for 'restrict'.
11183 (pp_c_specifier_qualifier_list): Likewise for _Complex.
11185 2011-07-21 Ian Lance Taylor <iant@google.com>
11187 PR middle-end/49705
11188 * c-common.c (c_disable_warnings): New static function.
11189 (c_enable_warnings): New static function.
11190 (c_fully_fold_internal): Change local unused_p to bool. Call
11191 c_disable_warnings and c_enable_warnings rather than change
11192 c_inhibit_evaluation_warnings.
11194 2011-07-20 Jason Merrill <jason@redhat.com>
11196 PR c++/6709 (DR 743)
11197 PR c++/42603 (DR 950)
11198 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
11199 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
11200 (CPP_DECLTYPE): New.
11201 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
11203 2011-07-19 Richard Guenther <rguenther@suse.de>
11205 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
11206 * c-omp.c (c_finish_omp_for): Likewise.
11208 2011-07-12 Eric Botcazou <ebotcazou@adacore.com>
11210 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
11211 body on the next line.
11213 2011-07-08 Jason Merrill <jason@redhat.com>
11216 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
11219 * c-common.c (c_apply_type_quals_to_decl): Don't check
11220 TYPE_NEEDS_CONSTRUCTING.
11222 2011-07-06 Richard Guenther <rguenther@suse.de>
11224 * c-common.c (c_common_nodes_and_builtins):
11225 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
11227 2011-07-05 Richard Guenther <rguenther@suse.de>
11229 * c-common.c (c_common_nodes_and_builtins): Build all common
11232 2011-06-27 Jakub Jelinek <jakub@redhat.com>
11234 * c-common.h (c_tree_chain_next): New static inline function.
11236 * c-common.c (check_builtin_function_arguments): Handle
11237 BUILT_IN_ASSUME_ALIGNED.
11239 2011-06-21 Andrew MacLeod <amacleod@redhat.com>
11241 * c-common.c: Add sync_ or SYNC__ to builtin names.
11242 * c-omp.c: Add sync_ or SYNC__ to builtin names.
11244 2011-06-20 Pierre Vittet <piervit@pvittet.com>
11246 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
11248 (gen_pragma_handler): New union.
11249 (internal_pragma_handler): New type.
11250 (c_register_pragma_with_data)
11251 (c_register_pragma_with_expansion_and_data): New functions.
11253 * c-pragma.c (registered_pragmas, c_register_pragma_1)
11254 (c_register_pragma, c_register_pragma_with_expansion)
11255 (c_invoke_pragma_handler): Changed to work with
11256 internal_pragma_handler.
11257 (c_register_pragma_with_data)
11258 (c_register_pragma_with_expansion_and_data): New functions.
11260 2011-06-14 Joseph Myers <joseph@codesourcery.com>
11262 * c-common.c: Include common/common-target.h.
11263 (handle_section_attribute): Use
11264 targetm_common.have_named_sections.
11265 * c-cppbuiltin.c: Include common/common-target.h.
11266 (c_cpp_builtins): Use targetm_common.except_unwind_info.
11268 2011-06-10 Richard Guenther <rguenther@suse.de>
11270 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
11271 to print a IDENTIFIER_NODE.
11273 2011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11274 Joseph Myers <joseph@codesourcery.com>
11276 * c.opt (fbuilding-libgcc): New option.
11277 * c-cppbuiltin.c (c_cpp_builtins): Define
11278 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
11280 2011-06-07 Jason Merrill <jason@redhat.com>
11282 * c-common.c (max_tinst_depth): Lower default to 900.
11284 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
11286 2011-06-07 Richard Guenther <rguenther@suse.de>
11288 * c-common.c (c_common_nodes_and_builtins): Do not set
11289 size_type_node or call set_sizetype.
11291 2011-06-07 Dodji Seketeli <dodji@redhat.com>
11294 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
11295 type when using pointer comparison to compare types.
11297 2011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
11299 * c.opt: Add -Wdelete-non-virtual-dtor.
11300 * c-opts.c (c_common_handle_option): Include it in -Wall.
11302 2011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
11307 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
11309 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
11312 2011-05-27 Jakub Jelinek <jakub@redhat.com>
11315 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
11316 C++ don't call c_common_truthvalue_conversion on void type arms.
11318 2011-05-27 Nathan Froyd <froydnj@codesourcery.com>
11320 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
11321 (stmt_list_stack): Define.
11322 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
11323 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
11325 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
11327 * c-common.c (warning_candidate_p): Check for BLOCKs.
11329 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
11331 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
11334 2011-05-25 Jakub Jelinek <jakub@redhat.com>
11336 * c-common.c (def_fn_type): Remove extra va_end.
11338 2011-05-23 Jason Merrill <jason@redhat.com>
11341 * c-common.c (c_common_get_narrower): New.
11342 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
11344 2011-05-23 Nathan Froyd <froydnj@codesourcery.com>
11346 * c-common.h (check_function_arguments): Tweak prototype of
11347 check_function_arguments.
11348 * c-common.c (check_function_arguments): Likewise. Adjust
11349 calls to check_function_nonnull, check_function_format, and
11350 check_function_sentinel.
11351 (check_function_sentinel): Take a FUNCTION_TYPE rather than
11352 separate attributes and typelist arguments. Use
11353 FOREACH_FUNCTION_ARGS to iterate over argument types.
11355 2011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
11357 * c-common.c (c_common_reswords): Reorder.
11358 * c-common.h (rid): Likewise.
11360 2011-05-10 Nathan Froyd <froydnj@codesourcery.com>
11362 * c-common.c (def_fn_type): Don't call build_function_type, call
11363 build_function_type_array or build_varargs_function_type_array
11365 (c_common_nodes_and_builtins): Likewise.
11367 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
11369 * c-common.c (c_add_case_label): Omit the loc argument to
11371 * c-common.h (build_case_label): Remove.
11372 * c-semantics.c (build_case_label): Remove.
11374 2011-05-05 Joseph Myers <joseph@codesourcery.com>
11376 * c-objc.h (objc_start_method_definition): Update prototype.
11377 * stub-objc.c (objc_start_method_definition): Add extra parameter.
11379 2011-05-04 Nathan Froyd <froydnj@codesourcery.com>
11381 * c-common.c (check_main_parameter_types): Reindent. Don't use
11382 TYPE_ARG_TYPES directly.
11383 (handle_nonnull_attribute): Likewise.
11384 (sync_resolve_params): Likewise.
11385 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
11386 to check_format_string.
11387 (handle_format_attribute): Likewise.
11388 (check_format_string): Take a function type to examine instead of
11389 a type list. Use a function_arg_iterator to step through argument
11392 2011-05-04 Richard Guenther <rguenther@suse.de>
11394 * c-common.c (fix_string_type): Use size_int for index type bounds.
11395 (start_fname_decls): Do not pass NULL to build_int_cst.
11396 (c_init_attributes): Likewise.
11397 * c-lex.c (c_lex_with_flags): Likewise.
11399 2011-04-27 Jason Merrill <jason@redhat.com>
11401 * c-common.c (make_tree_vector_from_list): New.
11402 * c-common.h: Declare it.
11404 2011-04-26 Richard Guenther <rguenther@suse.de>
11406 PR preprocessor/48248
11407 * c-ppoutput.c (maybe_print_line): Always optimize newlines
11408 for output size with -P.
11410 2011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
11412 * c-common.c (struct c_common_resword): Add __underlying_type.
11413 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
11415 2011-04-20 Jim Meyering <meyering@redhat.com>
11417 * c-format.c (init_dollar_format_checking): Remove useless
11420 2011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
11422 * c-objc.h (objc_get_interface_ivars): Removed.
11423 (objc_detect_field_duplicates): New.
11424 * stub-objc.c: Likewise.
11426 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
11428 * stub-objc.c (objc_declare_protocols): Renamed to
11429 objc_declare_protocol.
11430 * c-objc.h: Likewise.
11432 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
11434 * stub-objc.c (objc_declare_class): Updated argument name.
11436 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
11438 * c-common.h (c_common_init_ts): Declare.
11439 * c-common.c (c_common_init_ts): Define.
11441 2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
11443 * c-objc.h (objc_build_message_expr): Updated prototype.
11444 * stub-objc.c (objc_build_message_expr): Likewise.
11446 2011-04-12 Martin Jambor <mjambor@suse.cz>
11448 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
11451 2011-04-11 Richard Guenther <rguenther@suse.de>
11453 * c-common.c (complete_array_type): Build a range type of
11456 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
11458 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
11459 (handle_type_generic_attribute): Likewise.
11461 2011-04-07 Jason Merrill <jason@redhat.com>
11464 * c-common.c (c_common_truthvalue_conversion): Don't ignore
11465 conversion from C++0x scoped enum.
11467 2011-04-06 Joseph Myers <joseph@codesourcery.com>
11469 * c-target-def.h: New file.
11470 * c-target.def: New file.
11471 * c-target.h: New file.
11472 * c-common.c (targetcm): Don't define here.
11473 * c-common.h (default_handle_c_option): Declare.
11474 * c-format.c: Include c-target.h instead of target.h.
11475 * c-opts.c: Include c-target.h instead of target.h. Explicitly
11477 (default_handle_c_option): Move from targhooks.c.
11479 2011-03-29 Jakub Jelinek <jakub@redhat.com>
11481 PR preprocessor/48248
11482 * c-ppoutput.c (print): Add src_file field.
11483 (init_pp_output): Initialize it.
11484 (maybe_print_line): Don't optimize by adding up to 8 newlines
11485 if map->to_file and print.src_file are different file.
11486 (print_line): Update print.src_file.
11488 2011-03-25 Kai Tietz <ktietz@redhat.com>
11490 * c-ada-spec.c (compare_comment): Use filename_cmp
11491 instead of strcmp for filename.
11493 2011-03-25 Jeff Law <law@redhat.com>
11495 * c-common.c (def_fn_type): Add missing va_end.
11497 2011-03-25 Jason Merrill <jason@redhat.com>
11499 * c.opt: Add -std=c++03.
11501 2011-03-22 Eric Botcazou <ebotcazou@adacore.com>
11503 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
11505 2011-03-17 Kai Tietz <ktietz@redhat.com>
11508 * c-pretty-print.c (pp_c_specifier_qualifier_list):
11509 Display allowed attributes for function pointer types.
11510 (pp_c_attributes_display): New function to display
11511 attributes having affects_type_identity flag set to true.
11512 * c-pretty-print.h (pp_c_attributes_display): New prototype.
11514 * c-common.c (c_common_attribute_table):
11516 (c_common_format_attribute_table): Likewise.
11518 2011-03-18 Jason Merrill <jason@redhat.com>
11520 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
11521 * c-common.h: Don't declare it here.
11522 * c-common.c: Or define it here.
11523 * c-opts.c (c_common_handle_option): Or set it here.
11526 * c-common.c (handle_transparent_union_attribute): Don't
11527 make a duplicate type in C++.
11529 2011-03-15 Jason Merrill <jason@redhat.com>
11531 * c-common.c (max_constexpr_depth): New.
11532 * c-common.h: Declare it.
11533 * c-opts.c (c_common_handle_option): Set it.
11534 * c.opt (fconstexpr-depth): New option.
11536 2011-03-11 Jason Merrill <jason@redhat.com>
11538 * c-common.c (attribute_takes_identifier_p): Add missing const.
11541 * c-common.c (attribute_takes_identifier_p): Assume that an
11542 unknown attribute takes an identifier.
11544 2011-03-07 Nathan Froyd <froydnj@codesourcery.com>
11547 * c-common.c (c_type_hash): Call list_length instead of iterating
11548 through DECL_CHAIN. Rename 'i' to 'n_elements'.
11550 2011-02-19 Jakub Jelinek <jakub@redhat.com>
11553 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
11555 2011-02-17 Iain Sandoe <iains@gcc.gnu.org>
11557 * c.opt (fobjc-abi-version=) New.
11558 (fobjc-nilcheck): New.
11560 2011-02-03 Nathan Froyd <froydnj@codesourcery.com>
11563 * c-common.h (keyword_is_decl_specifier): Declare.
11564 * c-common.c (keyword_is_decl_specifier): Define.
11565 (keyword_is_function_specifier): New function.
11567 2011-01-26 Jakub Jelinek <jakub@redhat.com>
11570 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
11571 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
11574 2011-01-26 Arnaud Charlet <charlet@adacore.com>
11576 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
11578 2011-01-26 Jakub Jelinek <jakub@redhat.com>
11581 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
11582 after init_c_lex if pch_file is set.
11584 2011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
11587 * c.opt (-fkeep-inline-dllexport): New switch.
11589 2011-01-12 Richard Guenther <rguenther@suse.de>
11591 PR middle-end/32511
11592 * c-common.c (handle_weak_attribute): Warn instead of error
11593 on declaring an inline function weak.
11595 2011-01-05 Tom Tromey <tromey@redhat.com>
11597 * c-common.h (lvalue_error): Update.
11598 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
11601 2010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
11604 * c-objc.h (objc_finish_message_expr): Added argument to
11607 2010-12-22 Nathan Froyd <froydnj@codesourcery.com>
11609 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
11612 2010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
11614 * c-objc.h (objc_maybe_warn_exceptions): New.
11615 * stub-objc.c (objc_maybe_warn_exceptions): New.
11617 2010-12-10 Nathan Froyd <froydnj@codesourcery.com>
11619 * c-common.h (readonly_error): Declare.
11620 * c-common.c (readonly_error): Define.
11622 2010-12-09 Nathan Froyd <froydnj@codesourcery.com>
11624 * c-common.h (invalid_indirection_error): Declare.
11625 * c-common.c (invalid_indirection_error): Define.
11627 2010-12-03 Richard Guenther <rguenther@suse.de>
11630 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
11631 (pp_c_unary_expression): Likewise.
11632 (pp_c_expression): Likewise.
11634 2010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
11636 * c-common.h (objc_finish_function): New.
11637 (objc_non_volatilized_type): Removed.
11638 (objc_type_quals_match): Removed.
11639 * stub-objc.c (objc_finish_function): New.
11640 (objc_non_volatilized_type): Removed.
11641 (objc_type_quals_match): Removed.
11643 2010-11-30 Joseph Myers <joseph@codesourcery.com>
11645 * c-common.h (parse_optimize_options): Declare.
11646 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
11647 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
11649 2010-11-29 Joseph Myers <joseph@codesourcery.com>
11651 * c-opts.c (check_deps_environment_vars): Use getenv instead of
11653 * c-pch.c (O_BINARY): Don't define here.
11654 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
11656 2010-11-25 Joseph Myers <joseph@codesourcery.com>
11658 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
11659 targetm.except_unwind_info.
11661 2010-11-23 Joseph Myers <joseph@codesourcery.com>
11663 * c-opts.c (c_common_handle_option): Pass location to
11664 set_struct_debug_option.
11666 2010-11-23 Joseph Myers <joseph@codesourcery.com>
11668 * c-common.c (visibility_options): Move from ../opts.c.
11669 * c-common.h (struct visibility_flags, visibility_options):
11671 * c-opts.c (finish_options): Rename to c_finish_options.
11672 (c_common_init): Update call to finish_options.
11674 2010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
11677 * c-lex.c (lex_string): Check that each string in an Objective-C
11678 string concat sequence starts with either one or zero '@', and
11679 that there are no spurious '@' signs at the end.
11681 2010-11-20 Joseph Myers <joseph@codesourcery.com>
11683 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
11684 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
11685 HANDLE_PRAGMA_VISIBILITY.
11686 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
11687 HANDLE_PRAGMA_VISIBILITY): Don't define.
11688 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
11690 2010-11-20 Nathan Froyd <froydnj@codesourcery.com>
11695 * c-common.h (keyword_begins_type_specifier): Declare.
11696 (keyword_is_storage_class_specifier): Declare.
11697 (keyword_is_type_qualifier): Declare.
11698 * c-common.c (keyword_begins_type_specifier): New function.
11699 (keyword_is_storage_class_specifier): New function.
11700 (keyword_is_type_qualifier): Declare.
11702 2010-11-19 Joseph Myers <joseph@codesourcery.com>
11705 * c-common.c (in_late_binary_op): Define.
11706 (c_common_truthvalue_conversion): Check in_late_binary_op before
11707 calling c_save_expr.
11708 * c-common.h (in_late_binary_op): Declare.
11710 2010-11-19 Joseph Myers <joseph@codesourcery.com>
11712 * c-opts.c (c_common_handle_option): Update calls to
11713 set_struct_debug_option.
11715 2010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
11717 * c-common.h (objc_declare_protocols): Added additional argument.
11718 * stub-objc.c (objc_declare_protocol): Same change.
11720 2010-11-18 Nathan Froyd <froydnj@codesourcery.com>
11723 * c-common.h (build_real_imag_expr): Declare.
11724 * c-semantics.c (build_real_imag_expr): Define.
11726 2010-11-17 Joseph Myers <joseph@codesourcery.com>
11728 * c-opts.c (c_common_parse_file): Take no arguments.
11729 * c-common.h (c_common_parse_file): Update prototype.
11731 2010-11-16 Jakub Jelinek <jakub@redhat.com>
11734 * c-common.c (warning_candidate_p): Don't track non-const calls
11737 2010-11-15 Ian Lance Taylor <iant@google.com>
11739 * c-lex.c (init_c_lex): Set macro debug callbacks if
11740 flag_dump_go_spec is set.
11742 2010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
11744 * c-common.h (objc_build_incr_expr_for_property_ref): New.
11745 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
11747 2010-11-15 Nathan Froyd <froydnj@codesourcery.com>
11749 PR preprocessor/45038
11750 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
11753 2010-11-12 Joseph Myers <joseph@codesourcery.com>
11755 * c-common.h (c_family_lang_mask): Declare.
11756 * c-opts.c (c_family_lang_mask): Make extern.
11757 * c-pragma.c (handle_pragma_diagnostic): Use
11758 control_warning_option.
11760 2010-11-12 Joseph Myers <joseph@codesourcery.com>
11762 * c-common.c (parse_optimize_options): Update call to
11764 * c-common.h (c_common_handle_option): Update prototype.
11765 * c-opts.c (c_common_handle_option): Take location_t parameter and
11766 pass it to other functions.
11768 2010-11-11 Joseph Myers <joseph@codesourcery.com>
11770 * c-opts.c (warning_as_error_callback): Remove.
11771 (c_common_initialize_diagnostics): Don't call
11772 register_warning_as_error_callback.
11773 (c_common_handle_option): Handle -Werror=normalized= here.
11775 2010-11-10 Joseph Myers <joseph@codesourcery.com>
11777 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
11779 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
11781 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
11782 Remove trailing '.' from diagnostics.
11783 * c.opt (Wwrite-strings_: Avoid '`' in help text.
11785 2010-11-10 Joseph Myers <joseph@codesourcery.com>
11787 * c-common.c (parse_optimize_options): Pass global_dc to
11789 * c-opts.c (c_common_handle_option): Pass &global_options to
11790 set_Wstrict_aliasing.
11791 * c.opt (v): Don't mark Common or document here.
11793 2010-11-06 Iain Sandoe <iains@gcc.gnu.org>
11796 * c-format.c (format_type): New type gcc_objc_string_format_type.
11797 (valid_stringptr_type_p): New.
11798 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
11799 (check_format_string): Pass expected type, use
11800 valid_stringptr_type_p (), check that the format string types are
11801 consistent with the format specification.
11802 (decode_format_attr): Warn if NSString is used outside objective-c.
11803 (format_types_orig): Add NSString.
11804 (format_name): New.
11805 (format_flags): New.
11806 (check_format_arg): Handle format strings requiring an external parser.
11807 first_target_format_type: New variable.
11808 (handle_format_attribute): Set up first_target_format_type, pass the
11809 expected format arg string type to check_format_string().
11810 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
11811 * stub-objc.c (objc_string_ref_type_p): New.
11812 (objc_check_format_arg): New.
11814 2010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
11816 Fixed using the Objective-C 2.0 dot-syntax with class names.
11817 * c-common.h (objc_build_class_component_ref): New.
11818 * stub-objc.c (objc_build_class_component_ref): New.
11820 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
11822 * c.opt (Wproperty-assign-default): New option.
11824 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
11826 Implemented -fobjc-std=objc1 flag.
11827 * c.opt (fobjc-std=objc1): New option.
11829 2010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
11831 Implemented format and noreturn attributes for Objective-C methods.
11832 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
11833 attribute for Objective-C methods.
11835 2010-10-31 Jason Merrill <jason@redhat.com>
11837 * c-common.c (conversion_warning, warn_for_collisions_1): Use
11840 2010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
11842 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
11843 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
11844 (objc_add_property_declaration): Removed arguments for copies and
11846 (objc_build_getter_call): Renamed to
11847 objc_maybe_build_component_ref.
11848 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
11849 (objc_is_property_ref): New.
11850 * c-common.c (c_common_reswords): Removed copies and ivar.
11851 * stub-objc.c (objc_add_property_declaration): Removed arguments
11852 for copies and ivar.
11853 (objc_build_getter_call): Renamed to
11854 objc_maybe_build_component_ref.
11855 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
11856 (objc_is_property_ref): New.
11858 2010-10-29 Arnaud Charlet <charlet@adacore.com>
11859 Matthew Gingell <gingell@adacore.com>
11861 * c-ada-spec.c (separate_class_package): New function.
11862 (pp_ada_tree_identifier): Prefix references to C++ classes with the
11863 name of their enclosing package.
11864 (print_ada_declaration): Use separate_class_package.
11866 2010-10-27 Jason Merrill <jason@redhat.com>
11868 * c-common.c (c_common_reswords): Add __is_literal_type.
11869 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
11871 * c-common.c (check_case_value): Remove special C++ code.
11873 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
11875 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
11876 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
11877 and RID_LAST_PATTR.
11878 (objc_add_property_declaration): Added additional arguments.
11879 (objc_property_attribute_kind): Removed.
11880 (objc_set_property_attr): Removed.
11881 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
11882 copy and nonatomic.
11883 * stub-objc.c (objc_add_property_declaration): Added additional
11885 (objc_set_property_attr): Removed.
11887 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
11889 * c-common.h (objc_add_property_variable): Renamed to
11890 objc_add_property_declaration. Added location argument.
11891 * stub-objc.c (objc_add_property_variable): Same change.
11893 2010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
11895 * c-common.h (objc_maybe_printable_name): New.
11896 * stub-objc.c (objc_maybe_printable_name): New.
11898 2010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
11899 Andrew Pinski <pinskia@gmail.com>
11901 * c-common.h (c_common_mark_addressable_vec): Declare.
11902 * c-common.c (c_common_mark_addressable_vec): New function.
11904 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
11906 * c-common.h (objc_set_method_type): Removed.
11907 (objc_add_method_declaration): Added boolean argument.
11908 (objc_start_method_definition): Same change.
11909 (objc_build_method_signature): Same change.
11910 * stub-objc.c (objc_set_method_type): Removed.
11911 (objc_add_method_declaration): Added boolean argument.
11912 (objc_start_method_definition): Same change.
11913 (objc_build_method_signature): Same change.
11915 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
11917 * c-common.h (finish_file): Removed.
11918 (objc_write_global_declarations): New.
11919 * c-opts.c (c_common_parse_file): Do not call finish_file.
11920 * stub-objc.c (objc_write_global_declarations): New.
11922 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
11924 Implemented parsing @synthesize and @dynamic for
11925 Objective-C/Objective-C++.
11926 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
11927 (objc_add_synthesize_declaration): New.
11928 (objc_add_dynamic_declaration): New.
11929 * c-common.c (c_common_reswords): Add synthesize and dynamic.
11930 * stub-objc.c (objc_add_synthesize_declaration): New.
11931 (objc_add_dynamic_declaration): New.
11933 2010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
11936 * c-cppbuiltin.c (mode_has_fma): Move function here from
11937 builtins.c. Don't use the fma optab, instead just use the
11938 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
11941 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
11943 Merge from 'apple/trunk' branch on FSF servers.
11945 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
11948 * c-common.h (objc_non_volatilized_type): New declaration
11949 * stub-objc.c (objc_non_volatilized_type): New stub.
11951 2010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
11953 Merge from 'apple/trunk' branch on FSF servers.
11955 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
11958 * c-common.h (objc_diagnose_private_ivar): New decl.
11959 * stub-objc.c (objc_diagnose_private_ivar): New stub.
11961 2010-10-17 Iain Sandoe <iains@gcc.gnu.org>
11963 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
11964 * c-common.h (enum rid): Add RID_AT_PACKAGE.
11965 (objc_ivar_visibility_kind): New enum.
11966 (objc_set_visibility): Adjust prototype to use visibility enum.
11967 * stub-objc.c (objc_set_visibility): Adjust stub to use
11970 2010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
11972 * c-cppbuiltin.c (builtin_define_float_constants): Emit
11973 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
11974 has the appropriate fma builtins.
11975 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
11977 2010-10-14 Iain Sandoe <iains@gcc.gnu.org>
11979 merge from FSF apple 'trunk' branch.
11980 2006 Fariborz Jahanian <fjahanian@apple.com>
11982 Radars 4436866, 4505126, 4506903, 4517826
11983 * c-common.c (c_common_resword): Define @property and its attributes.
11984 * c-common.h: Define property attribute enum entries.
11985 (OBJC_IS_PATTR_KEYWORD): New.
11986 (objc_property_attribute_kind): New enum.
11987 Declare objc_set_property_attr (), objc_add_property_variable (),
11988 objc_build_getter_call () and objc_build_setter_call ().
11989 * stub-objc.c (objc_set_property_attr): New stub.
11990 (objc_add_property_variable): Likewise.
11991 (objc_build_getter_call): Likewise.
11992 (objc_build_setter_call) Likewise.
11994 2010-10-13 Iain Sandoe <iains@gcc.gnu.org>
11996 merge from FSF apple 'trunk' branch.
11997 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
11999 Radar 3803157 (method attributes)
12000 * c-common.c (handle_deprecated_attribute): Recognize
12001 objc methods as valid declarations.
12002 * c-common.h: Declare objc_method_decl ().
12003 * stub-objc.c (objc_method_decl): New stub.
12005 2010-10-08 Joseph Myers <joseph@codesourcery.com>
12007 * c-common.c (parse_optimize_options): Call
12008 decode_cmdline_options_to_array_default_mask before
12009 decode_options. Update arguments to decode_options.
12010 * c-common.h (c_common_init_options_struct): Declare.
12011 * c-opts.c (c_common_init_options_struct): New. Split out from
12012 c_common_init_options.
12014 2010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
12016 Implemented fast enumeration for Objective-C.
12017 * c-common.h (objc_finish_foreach_loop): New.
12018 * stub-objc.c (objc_finish_foreach_loop): New.
12020 2010-10-05 Joseph Myers <joseph@codesourcery.com>
12022 * c-common.h (struct diagnostic_context): Don't declare here.
12023 (c_common_initialize_diagnostics): Declare using
12024 diagnostic_context typedef.
12025 * c-opts.c (c_common_handle_option): Pass global_dc to
12026 handle_generated_option.
12028 2010-10-04 Joseph Myers <joseph@codesourcery.com>
12030 * c-opts.c (c_common_handle_option): Pass &global_options_set to
12031 handle_generated_option.
12033 2010-10-03 Ian Lance Taylor <iant@google.com>
12035 * c.opt (-fplan9-extensions): New option.
12037 2010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
12039 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
12041 (c_cpp_builtins): Call functions from cppbuiltin.c instead
12042 of duplicating code.
12044 2010-09-30 Iain Sandoe <iains@gcc.gnu.org>
12046 * c-common.c: Add two new entries for @optional
12047 and @required keywords.
12049 merge from FSF 'apple/trunk' branch.
12050 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
12053 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
12054 objective-c keywords.
12055 (objc_set_method_opt): New declaration.
12056 * stub-objc.c (objc_set_method_opt): New stub.
12058 2010-09-30 Joseph Myers <joseph@codesourcery.com>
12060 * c-common.c (handle_optimize_attribute): Pass &global_options to
12061 cl_optimization_save and cl_optimization_restore.
12062 * c-opts.c (c_common_handle_option): Pass &global_options to
12063 handle_generated_option.
12064 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
12065 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
12066 &global_options to cl_optimization_restore.
12068 2010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
12070 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
12071 Objective-C/Objective-C++ keywords.
12073 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
12075 Merge from 'apple/trunk' branch on FSF servers.
12077 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
12080 * c-common.h (objc_check_global_decl): New declaration.
12081 * stub-objc.c (objc_check_global_decl): New stub.
12083 2010-09-29 Joseph Myers <joseph@codesourcery.com>
12085 * c.opt: Don't use VarExists.
12087 2010-09-29 Joseph Myers <joseph@codesourcery.com>
12089 * c-common.c (c_cpp_error): Update names of diagnostic_context
12091 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
12092 cl_optimization members.
12093 * c-opts.c (warning_as_error_callback, c_common_handle_option,
12094 sanitize_cpp_opts, finish_options): Update names of cpp_options
12097 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
12099 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
12100 (objc_is_reserved_word): Removed.
12101 * c-common.c: Updated comments.
12102 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
12103 objc_is_reserved_word.
12104 * stub-objc.c (objc_is_reserved_word): Removed.
12106 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
12108 * c-common.h (objc_add_method_declaration): Adjust prototype to
12109 include attributes.
12110 (objc_start_method_definition): Likewise.
12111 (objc_build_keyword_decl): Likewise.
12112 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
12113 (objc_start_method_definition): Likewise.
12114 (objc_build_keyword_decl): Likewise.
12116 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
12118 * c-common.h (objc_start_class_interface): Adjust prototype.
12119 (objc_start_category_interface): Likewise.
12120 (objc_start_protocol): Likewise.
12121 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
12122 (objc_start_class_interface): Likewise.
12123 (objc_start_category_interface): Likewise.
12125 2010-09-27 Ian Lance Taylor <iant@google.com>
12127 * c-common.c (c_common_attribute_table): Add no_split_stack.
12128 (handle_no_split_stack_attribute): New static function.
12130 2010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
12132 Merge from 'apple/trunk' branch on FSF servers.
12134 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
12137 * c-common.h (objc_have_common_type): New declaration.
12138 * stub-objc.c (objc_have_common_type): New stub.
12140 2005-06-22 Ziemowit Laski <zlaski@apple.com>
12143 * c-common.h (objc_common_type): New prototype.
12144 * stub-objc.c (objc_common_type): New stub.
12146 2010-09-24 Jan Hubicka <jh@suse.cz>
12148 * c-common.c (handle_leaf_attribute): New function.
12149 (struct attribute_spec c_common_att): Add leaf.
12151 2010-09-22 Joseph Myers <joseph@codesourcery.com>
12153 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
12154 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
12155 -dump, -dump=, -imacros, -imacros=, -include, -include=,
12156 -include-barrier, -include-directory, -include-directory=,
12157 -include-directory-after, -include-directory-after=,
12158 -include-prefix, -include-prefix=, -include-with-prefix,
12159 -include-with-prefix=, -include-with-prefix-after,
12160 -include-with-prefix-after=, -include-with-prefix-before,
12161 -include-with-prefix-before=, -no-integrated-cpp,
12162 -no-line-commands, -no-standard-includes, -no-warnings, -output,
12163 -output=, -pedantic, -pedantic-errors, -preprocess,
12164 -print-missing-file-dependencies, -trace-includes, -traditional,
12165 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
12166 -user-dependencies, -verbose, -write-dependencies,
12167 -write-user-dependencies, no-integrated-cpp, traditional): New.
12169 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
12172 * c-common.h (objc_start_method_definition): Return bool instead
12174 * stub-objc.c (objc_start_method_definition): Return bool instead
12177 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
12180 * c-common.h (objc_get_interface_ivars): New declaration.
12181 * stub-objc.c (objc_get_interface_ivars): New stub.
12183 2010-09-15 Ian Lance Taylor <iant@google.com>
12185 * c-common.c (parse_optimize_options): Do not capitalize warning
12186 messages. Remove period at end of warning message.
12188 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12190 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
12191 (handle_alias_attribute): ... here.
12192 (handle_ifunc_attribute): New.
12194 2010-09-06 Mark Mitchell <mark@codesourcery.com>
12196 * c-common.h (do_warn_double_promotion): Declare.
12197 * c-common.c (do_warn_double_promotion): Define.
12199 2010-09-05 Mark Mitchell <mark@codesourcery.com>
12201 * c.opt (Wdouble-promotion): New.
12203 2010-09-02 Joseph Myers <joseph@codesourcery.com>
12205 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
12206 fvtable-thunks, fxref): Mark no longer supported in help text.
12208 2010-09-02 Joseph Myers <joseph@codesourcery.com>
12210 * c.opt (Wimport, fall-virtual, falt-external-templates,
12211 fdefault-inline, fenum-int-equiv, fexternal-templates,
12212 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
12213 fname-mangling-version-, fnew-abi, fnonnull-objects,
12214 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
12215 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
12217 (fhandle-exceptions): Mark with Alias and Warn.
12218 * c-opts.c (c_common_handle_option): Don't handle options marked
12221 2010-09-02 Joseph Myers <joseph@codesourcery.com>
12223 * c.opt (Wcomments, Werror-implicit-function-declaration,
12224 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
12225 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
12227 * c-common.c (option_codes): Use OPT_Wcomment instead of
12229 * c-opts.c (warning_as_error_callback, c_common_handle_option):
12230 Don't handle options marked as aliases.
12232 2010-08-25 Richard Guenther <rguenther@suse.de>
12234 * c-common.c (c_common_get_alias_set): Remove special
12235 handling for pointers.
12237 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
12239 * c-common.c: Use FOR_EACH_VEC_ELT.
12240 * c-gimplify.c: Likewise.
12241 * c-pragma.c: Likewise.
12243 2010-08-16 Joseph Myers <joseph@codesourcery.com>
12245 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
12247 (MMDX): Change back to MMD. Mark NoDriverArg instead of
12249 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
12250 instead of OPT_MDX and OPT_MMDX.
12252 2010-08-16 Joseph Myers <joseph@codesourcery.com>
12254 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
12256 2010-08-12 Joseph Myers <joseph@codesourcery.com>
12258 * c.opt (MD, MMD): Change to MDX and MMDX.
12259 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
12261 2010-08-11 Joseph Myers <joseph@codesourcery.com>
12263 * c-opts.c (c_common_handle_option): Call handle_generated_option
12264 instead of handle_option.
12266 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
12268 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
12269 (maybe_apply_renaming_pragma): Delete unneeded declarations.
12271 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
12273 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
12274 (pending_redefine_extname): Change type to a VEC.
12275 (add_to_renaming_pragma_list): Update for new type of
12276 pending_redefine_extname.
12277 (maybe_apply_renaming_pragma): Likewise.
12279 2010-08-04 Arnaud Charlet <charlet@adacore.com>
12281 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
12283 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
12284 decide whether a type has already been declared/seen.
12285 Do not go to the original type.
12286 (dump_nested_types): New parameter forward.
12287 Generate forward declaration if needed and mark type as visited.
12288 (print_ada_declaration): Call dump_nested_types if not already done.
12289 Mark types as visited.
12291 2010-08-03 Joseph Myers <joseph@codesourcery.com>
12293 * c.opt (-print-pch-checksum): Remove option.
12294 * c-opts.c (c_common_handle_option): Don't handle
12295 OPT_print_pch_checksum.
12297 2010-07-27 Joseph Myers <joseph@codesourcery.com>
12299 * c-common.h (c_common_handle_option): Update prototype and return
12301 * c-opts.c (c_common_handle_option): Update prototype and return
12302 value type. Update calls to handle_option and
12303 enable_warning_as_error.
12305 2010-07-27 Jakub Jelinek <jakub@redhat.com>
12308 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
12310 2010-07-27 Joseph Myers <joseph@codesourcery.com>
12312 * c-common.h (c_common_missing_argument): Remove.
12313 * c-opts.c (c_common_missing_argument): Remove.
12314 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
12315 idirafter, imacros, include, isysroot, isystem, iquote): Add
12317 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
12319 2010-07-27 Joseph Myers <joseph@codesourcery.com>
12321 * c-common.h (c_common_option_lang_mask,
12322 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
12324 (c_common_init_options): Update prototype.
12325 * c-opts.c (c_common_option_lang_mask): New.
12326 (c_common_initialize_diagnostics): Split out of
12327 c_common_init_options.
12328 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
12330 (c_common_init_options): Update prototype. Use decoded options in
12331 search for -lang-asm.
12333 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
12335 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
12336 * c-format.c: Likewise.
12338 2010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
12340 * c-common.h: Include diagnostic-core.h. Error if already
12342 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
12344 2010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
12346 * c-common.c (IN_GCC_FRONTEND): Do not undef.
12347 Do not include expr.h
12348 (vector_mode_valid_p): Move here.
12350 2010-06-21 DJ Delorie <dj@redhat.com>
12352 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
12353 allow these pragmas anywhere.
12355 2010-06-14 Jakub Jelinek <jakub@redhat.com>
12358 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
12359 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
12360 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
12361 ggc_strdup instead of xstrdup.
12363 2010-06-10 Jakub Jelinek <jakub@redhat.com>
12365 * c-cppbuiltin.c: Include cpp-id-data.h.
12366 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
12367 (lazy_hex_fp_value): New function.
12368 (builtin_define_with_hex_fp_value): Provide definitions lazily.
12370 2010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
12372 * c-gimplify.c: Do not include tree-flow.h
12374 2010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
12377 * c-common.c: Rename targetm member:
12378 targetm.enum_va_list -> targetm.enum_va_list_p
12380 2010-06-28 Anatoly Sokolov <aesok@post.ru>
12382 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
12384 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
12386 * c-cppbuiltin.c: Do not include except.h.
12388 2010-06-24 Andi Kleen <ak@linux.intel.com>
12390 * c-common.c (warn_for_omitted_condop): New.
12391 * c-common.h (warn_for_omitted_condop): Add prototype.
12393 2010-06-21 Joseph Myers <joseph@codesourcery.com>
12395 * c.opt (lang-objc): Remove.
12396 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
12398 2010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
12400 * c-opts.c: Include "tm_p.h".
12402 2010-06-20 Joseph Myers <joseph@codesourcery.com>
12404 * c-common.c (parse_optimize_options): Update call to
12407 2010-06-18 Nathan Froyd <froydnj@codesourcery.com>
12409 * c-common.c (record_types_used_by_current_var_decl): Adjust for
12410 new type of types_used_by_cur_var_decl.
12412 2010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
12415 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
12416 for C++ standard compliance.
12418 2010-06-16 Jason Merrill <jason@redhat.com>
12420 * c.opt: Add -Wnoexcept.
12422 2010-06-16 Richard Guenther <rguenther@suse.de>
12425 * c-common.c (c_common_truthvalue_conversion): Remove
12426 premature and wrong optimization concering ADDR_EXPRs.
12428 2010-06-15 Arnaud Charlet <charlet@adacore.com>
12430 * c-ada-spec.c (dump_sloc): Remove column info.
12431 (is_simple_enum): New function.
12432 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
12433 enum types when relevant.
12435 2010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
12437 * c-common.c (conversion_warning): Warn at expression
12440 2010-06-10 Joseph Myers <joseph@codesourcery.com>
12442 * c-opts.c (c_common_handle_option): Don't handle
12445 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
12447 * c-pragma.c (push_alignment): Use typed GC allocation.
12448 (handle_pragma_push_options): Likewise.
12450 * c-common.c (parse_optimize_options): Likewise.
12452 * c-common.h (struct sorted_fields_type): Add variable_size GTY
12455 2010-06-07 Joseph Myers <joseph@codesourcery.com>
12457 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
12458 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
12459 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
12460 flag_signed_bitfields, warn_strict_null_sentinel,
12461 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
12462 flag_gen_declaration, flag_no_gnu_keywords,
12463 flag_implement_inlines, flag_implicit_templates,
12464 flag_implicit_inline_templates, flag_optional_diags,
12465 flag_elide_constructors, flag_default_inline, flag_rtti,
12466 flag_conserve_space, flag_access_control, flag_check_new,
12467 flag_new_for_scope, flag_weak, flag_working_directory,
12468 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
12469 flag_enforce_eh_specs, flag_threadsafe_statics,
12470 flag_pretty_templates): Remove.
12471 * c-common.h (flag_preprocess_only, flag_nil_receivers,
12472 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
12473 flag_replace_objc_classes, flag_undef, flag_no_builtin,
12474 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
12475 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
12476 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
12477 flag_no_gnu_keywords, flag_implement_inlines,
12478 flag_implicit_templates, flag_implicit_inline_templates,
12479 flag_optional_diags, flag_elide_constructors, flag_default_inline,
12480 flag_rtti, flag_conserve_space, flag_access_control,
12481 flag_check_new, flag_new_for_scope, flag_weak,
12482 flag_working_directory, flag_use_cxa_atexit,
12483 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
12484 flag_threadsafe_statics, flag_pretty_templates,
12485 warn_strict_null_sentinel): Remove.
12486 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
12487 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
12488 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
12489 fimplicit-inline-templates, fimplicit-templates,
12490 flax-vector-conversions, fms-extensions, fnil-receivers,
12491 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
12492 frtti, fshort-double, fshort-enums, fshort-wchar,
12493 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
12494 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
12495 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
12496 gen-decls, undef): Use Var.
12497 (fdefault-inline, foptional-diags): Document as doing nothing.
12498 * c-opts.c (c_common_handle_option): Remove cases for options now
12499 using Var. Mark ignored options as such.
12501 2010-06-05 Steven Bosscher <steven@gcc.gnu.org>
12503 * c-common.c: Moved to here from parent directory.
12504 * c-common.def: Likewise.
12505 * c-common.h: Likewise.
12506 * c-cppbuiltin.c: Likewise.
12507 * c-dump.c: Likewise.
12508 * c-format.c: Likewise.
12509 * c-format.h : Likewise.
12510 * c-gimplify.c: Likewise.
12511 * c-lex.c: Likewise.
12512 * c-omp.c: Likewise.
12514 * c-opts.c: Likewise.
12515 * c-pch.c: Likewise.
12516 * c-ppoutput.c: Likewise.
12517 * c-pragma.c: Likewise.
12518 * c-pragma.h: Likewise.
12519 * c-pretty-print.c: Likewise.
12520 * c-pretty-print.h: Likewise.
12521 * c-semantics.c: Likewise.
12522 * stub-objc.c: Likewise.
12524 * c-common.c: Include gt-c-family-c-common.h.
12525 * c-pragma.c: Include gt-c-family-c-pragma.h.
12527 Copyright (C) 2010-2021 Free Software Foundation, Inc.
12529 Copying and distribution of this file, with or without modification,
12530 are permitted in any medium without royalty provided the copyright
12531 notice and this notice are preserved.