]> gcc.gnu.org Git - gcc.git/blame - gcc/c-family/ChangeLog
Fixup unaligned load/store cost for znver5
[gcc.git] / gcc / c-family / ChangeLog
CommitLineData
8ccfa571
GA
12024-07-14 Alejandro Colomar <alx@kernel.org>
2
3 PR c/115185
4 * c.opt: Add -Wunterminated-string-initialization.
5
944e4251
GA
62024-07-13 David Malcolm <dmalcolm@redhat.com>
7
8 * c-common.cc: Include "tree-pretty-print-markup.h".
9 (binary_op_error): Use pp_markup::element_quoted_type and %e.
10 (check_function_arguments): Add "comp_types" param and pass it to
11 check_function_format.
12 * c-common.h (check_function_arguments): Add "comp_types" param.
13 (check_function_format): Likewise.
14 * c-format.cc: Include "tree-pretty-print-markup.h".
15 (local_pp_element_ptr_node): New.
16 (PP_FORMAT_CHAR_TABLE): Add entry for %e.
17 (struct format_check_context): Add "m_comp_types" field.
18 (check_function_format): Add "comp_types" param and pass it to
19 check_format_info.
20 (check_format_info): Likewise, passing it to format_ctx's ctor.
21 (check_format_arg): Extract m_comp_types from format_ctx and
22 pass it to check_format_info_main.
23 (check_format_info_main): Add "comp_types" param and pass it to
24 arg_parser's ctor.
25 (class argument_parser): Add "m_comp_types" field.
26 (argument_parser::check_argument_type): Pass m_comp_types to
27 check_format_types.
28 (handle_subclass_of_pp_element_p): New.
29 (check_format_types): Add "comp_types" param, and use it to
30 call handle_subclass_of_pp_element_p.
31 (class element_format_substring): New.
32 (class element_expected_type_with_indirection): New.
33 (format_type_warning): Use element_expected_type_with_indirection
34 to unify the if (wanted_type_name) branches, reducing from four
35 emit_warning calls to two. Simplify these further using %e.
36 Doing so also gives suitable colorization of the text within the
37 diagnostics.
38 (init_dynamic_diag_info): Initialize local_pp_element_ptr_node.
39 (selftest::test_type_mismatch_range_labels): Add nullptr for new
40 param of gcc_rich_location label overload.
41 * c-format.h (T_PP_ELEMENT_PTR): New.
42 * c-type-mismatch.cc: Include "diagnostic-highlight-colors.h".
43 (binary_op_rich_location::binary_op_rich_location): Use
44 highlight_colors::lhs and highlight_colors::rhs for the ranges.
45 * c-type-mismatch.h (class binary_op_rich_location): Add comment
46 about highlight_colors.
47
f777ab31
GA
482024-07-10 Marek Polacek <polacek@redhat.com>
49
50 * c-cppbuiltin.cc (c_cpp_builtins): Remove flag_concepts_ts code.
51 * c-opts.cc (c_common_post_options): Likewise.
52 * c.opt: Remove -fconcepts-ts.
53 * c.opt.urls: Regenerate.
54
ceb944ad
GA
552024-07-08 David Malcolm <dmalcolm@redhat.com>
56
57 * c-format.cc (format_check_results::format_check_results): New
58 ctor.
59 (struct format_check_context): Add ctor; add "m_" prefix to all
60 fields.
61 (check_format_info): Use above ctors.
62 (check_format_arg): Update for "m_" prefix to
63 format_check_context.
64
0720394a
GA
652024-07-03 Lewis Hyatt <lhyatt@gmail.com>
66
67 PR pch/115312
68 * c-opts.cc (c_common_init): Call c_init_preprocess() before
69 c_finish_options() so that a parser is available to process any
70 includes specified on the command line.
71
9fe669ce
GA
722024-06-25 Andrew Pinski <quic_apinski@quicinc.com>
73
74 PR c++/115624
75 * c.opt (Wnrvo): Add Warning property.
76
a008fa34
GA
772024-06-18 David Malcolm <dmalcolm@redhat.com>
78
79 * c-opts.cc: Replace include of "tree-diagnostic.h" with
80 "diagnostic-macro-unwinding.h".
81
31e275d7
GA
822024-06-17 Eric Botcazou <ebotcazou@adacore.com>
83
84 * c-ada-spec.cc (is_float16): New predicate.
85 (dump_ada_node) <REAL_TYPE>: Call it.
86
872024-06-17 Joseph Myers <josmyers@redhat.com>
88
89 * c-common.cc (c_sizeof_or_alignof_type): Allow alignof on an
90 incomplete array type for C2Y.
91
922024-06-17 Jakub Jelinek <jakub@redhat.com>
93
94 PR c/115290
95 * c-warn.cc (do_warn_array_compare): Use %E rather than %D for
96 printing op0 and op1; if those operands aren't decls, also print
97 parens around them.
98
158ce8ad
GA
992024-06-12 David Malcolm <dmalcolm@redhat.com>
100
101 * c-ada-spec.cc (dump_ads): Update for fields of pretty_printer
102 becoming private.
103 * c-pretty-print.cc: Likewise throughout.
104
1052024-06-12 David Malcolm <dmalcolm@redhat.com>
106
107 * c-ada-spec.cc: Rename pretty_printer "buffer" to "pp"
108 throughout.
109
7fa4b335
GA
1102024-06-11 Joseph Myers <josmyers@redhat.com>
111
112 * c-common.cc (flag_isoc2y): New.
113 (flag_isoc99, flag_isoc11, flag_isoc23): Update comments.
114 * c-common.h (flag_isoc2y): New.
115 (clk_c, flag_isoc23): Update comments.
116 * c-opts.cc (set_std_c2y): New.
117 (c_common_handle_option): Handle OPT_std_c2y and OPT_std_gnu2y.
118 (set_std_c89, set_std_c99, set_std_c11, set_std_c17, set_std_c23):
119 Set flag_isoc2y.
120 (set_std_c23): Update comment.
121 * c.opt (Wc23-c2y-compat, std=c2y, std=gnu2y): New.
122 * c.opt.urls: Regenerate.
123
1242024-06-11 Andi Kleen <ak@linux.intel.com>
125
126 * c-cppbuiltin.cc (c_cpp_builtins): Define __GXX_CONSTEXPR_ASM__
127
10cb3336
GA
1282024-06-05 Jakub Jelinek <jakub@redhat.com>
129 Frederik Harwath <frederik@codesourcery.com>
130 Sandra Loosemore <sandra@codesourcery.com>
131
132 * c-common.h (c_omp_find_generated_loop): Declare.
133 * c-gimplify.cc (c_genericize_control_stmt): Handle OMP_TILE and
134 OMP_UNROLL.
135 * c-omp.cc (c_finish_omp_for): Handle generated loops.
136 (c_omp_is_loop_iterator): Likewise.
137 (c_find_nested_loop_xform_r, c_omp_find_generated_loop): New
138 functions.
139 (c_omp_check_loop_iv): Handle generated loops. For now sorry
140 on mixing non-rectangular loop with generated loops.
141 (c_omp_check_loop_binding_exprs): For now sorry on mixing
142 imperfect loops with generated loops.
143 (c_omp_directives): Uncomment tile and unroll entries.
144 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TILE and
145 PRAGMA_OMP_UNROLL, change PRAGMA_OMP__LAST_ to the latter.
146 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FULL and
147 PRAGMA_OMP_CLAUSE_PARTIAL.
148 * c-pragma.cc (omp_pragmas_simd): Add tile and unroll omp pragmas.
149
3c75a4c0
GA
1502024-05-31 Qing Zhao <qing.zhao@oracle.com>
151
152 * c-ubsan.cc (get_bound_from_access_with_size): New function.
153 (ubsan_instrument_bounds): Handle call to .ACCESS_WITH_SIZE.
154
1552024-05-31 Qing Zhao <qing.zhao@oracle.com>
156
157 * c-attribs.cc (handle_counted_by_attribute): New function.
158 (attribute_takes_identifier_p): Add counted_by attribute to the list.
159 * c-common.cc (c_flexible_array_member_type_p): ...To this.
160 * c-common.h (c_flexible_array_member_type_p): New prototype.
161
1622024-05-31 Martin Uecker <uecker@tugraz.at>
163
164 PR tree-optimization/115157
165 PR tree-optimization/115177
166 * c-attribs.cc (handle_hardbool_attribute): Set TYPE_CANONICAL
167 for hardbools.
168
d815d9ad
GA
1692024-05-29 Jason Merrill <jason@redhat.com>
170
171 PR c++/109753
172 * c-attribs.cc (handle_optimize_attribute): Set
173 cgraph_node::semantic_interposition.
174
1752024-05-29 Oskari Pirhonen <xxc3ncoredxx@gmail.com>
176
177 * known-headers.cc (get_stdlib_header_for_name): Add strerror.
178
2b841697
GA
1792024-05-28 David Malcolm <dmalcolm@redhat.com>
180
181 PR bootstrap/115167
182 * c-format.cc: Replace include of "gcc-rich-location.h" with
183 "c-family/c-type-mismatch.h".
184 * c-type-mismatch.cc: New file, taking material from
185 gcc-rich-location.cc.
186 * c-type-mismatch.h: New file, taking material from
187 gcc-rich-location.h.
188 * c-warn.cc: Replace include of "gcc-rich-location.h" with
189 "c-family/c-type-mismatch.h".
190
6c0b7e12
GA
1912024-05-24 Eric Botcazou <ebotcazou@adacore.com>
192
193 * c-ada-spec.cc (is_cpp_float): New predicate.
194 (dump_number): Deal with more preprocessing floating constants.
195 (dump_ada_macros) <CPP_NUMBER>: Use is_cpp_float.
196
ee492101
GA
1972024-05-23 Eric Botcazou <ebotcazou@adacore.com>
198
199 * c-ada-spec.cc (check_type_name_conflict): Add guard.
200 (is_char_array): Simplify.
201 (dump_ada_array_type): Use strip_array_types.
202 (dump_ada_node) <POINTER_TYPE>: Deal with anonymous array types.
203 (dump_nested_type): Use strip_array_types.
204
8713d5ee
GA
2052024-05-17 Eric Botcazou <ebotcazou@adacore.com>
206
207 * c-ada-spec.cc (bitfield_used): Move around.
208 (packed_layout): Likewise.
209 (dump_ada_array_type): Do not put "aliased" for a packed layout.
210
25456c0e
GA
2112024-05-15 Marek Polacek <polacek@redhat.com>
212
213 DR 1693
214 PR c++/113760
215 DR 569
216 * c.opt (Wextra-semi): Initialize to -1.
217
d508d708
GA
2182024-05-08 Marek Polacek <polacek@redhat.com>
219
220 PR c++/113582
221 * c-warn.cc (warn_for_unused_label): Don't warn if -Wunused-label has
222 been suppressed for the label.
223
2242024-05-07 Andrew Pinski <quic_apinski@quicinc.com>
225
226 PR c++/89224
227 * c-common.cc (convert_vector_to_array_for_subscript): Call build_qualified_type
228 for the inner type.
229
2302024-05-07 Jakub Jelinek <jakub@redhat.com>
231
232 PR c++/114459
233 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
234 __cpp_variadic_friend=202403L for C++26.
235
2362024-05-07 Richard Biener <rguenther@suse.de>
237
238 PR middle-end/114931
239 * c-common.cc (complete_array_type): Set TYPE_STRUCTURAL_EQUALITY_P
240 before probing with type_hash_canon.
241
f2d01160
GA
2422024-05-02 Jakub Jelinek <jakub@redhat.com>
243
244 PR c++/114458
245 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
246 __cpp_deleted_function=202403L for C++26.
247
610415bb
GA
2482024-04-30 Jakub Jelinek <jakub@redhat.com>
249
250 PR c++/114456
251 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
252 __cpp_structured_bindings for C++26 to 202403L rather than
253 201606L.
254
3091f1df
GA
2552024-04-23 Jakub Jelinek <jakub@redhat.com>
256
257 * c-attribs.cc (handle_objc_nullability_attribute): Spelling fix:
258 recognised -> recognized.
259
2602024-04-23 Jakub Jelinek <jakub@redhat.com>
261
262 * c.opt (Wstrict-flex-arrays): Spelling fix: inproper -> improper.
263
90ded751
GA
2642024-04-19 Jakub Jelinek <jakub@redhat.com>
265
266 PR c/114780
267 * c-common.cc (check_function_sentinel): Allow as sentinel any
268 argument of NULLPTR_TYPE.
269
3319d1a4
GA
2702024-04-13 Mark Wielaard <mark@klomp.org>
271
272 * c.opt.urls: Regenerate.
273
1667962a
GA
2742024-04-12 Jason Merrill <jason@redhat.com>
275 Patrick Palka <ppalka@redhat.com>
276
277 PR c++/113141
278 * c.opt: Add -Wcast-user-defined.
279
1a96eb0a
GA
2802024-04-05 Marek Polacek <polacek@redhat.com>
281
282 * c-warn.cc (warn_about_parentheses): Remove an #undef.
283
feafff04
GA
2842024-03-27 Jakub Jelinek <jakub@redhat.com>
285
286 PR tree-optimization/114469
287 * c-common.cc (resolve_overloaded_builtin): For _BitInt result
288 on !extended targets convert result to the _BitInt type before
289 using VIEW_CONVERT_EXPR.
290
4b8e7b57
GA
2912024-03-26 Jakub Jelinek <jakub@redhat.com>
292
293 PR c++/112724
294 * c-pretty-print.cc (pp_c_cast_expression,
295 c_pretty_printer::expression): Handle EXCESS_PRECISION_EXPR like
296 NOP_EXPR.
297
cc606a91
GA
2982024-03-19 Jakub Jelinek <jakub@redhat.com>
299
300 PR c/114364
301 * c-omp.cc (enum check_loop_binding_expr_ctx): New type.
302 (check_loop_binding_expr): Remove context argument, add ctx
303 argument with check_loop_binding_expr_ctx type at the end. Don't
304 create diagnostic message from multiple pieces.
305 (c_omp_check_loop_binding_exprs): Adjust callers.
306
c775a030
GA
3072024-03-08 Jakub Jelinek <jakub@redhat.com>
308
309 * c-common.cc (resolve_overloaded_atomic_exchange): Instead of setting
310 p1 to VIEW_CONVERT_EXPR<I_type> (*p1), set it to MEM_REF with p1 and
311 (typeof (p1)) 0 operands and I_type type.
312 (resolve_overloaded_atomic_compare_exchange): Similarly for p2.
313
214dadf3
GA
3142024-03-05 Mark Wielaard <mark@klomp.org>
315
316 * c.opt.urls: Regenerate.
317
3182024-03-05 Patrick Palka <ppalka@redhat.com>
319
320 * c.opt (Wglobal-module): New warning.
321
264e3ad4
GA
3222024-03-04 Mark Wielaard <mark@klomp.org>
323
324 * c.opt.urls: Regenerate.
325
77de8b72
GA
3262024-02-22 Jakub Jelinek <jakub@redhat.com>
327
328 PR c/114007
329 * c-lex.cc (c_common_has_attribute): Parse 2 CPP_COLONs with
330 the first one with COLON_SCOPE flag the same as CPP_SCOPE.
331
67d5b10e
GA
3322024-02-10 Marek Polacek <polacek@redhat.com>
333
334 DR 2237
335 PR c++/107126
336 PR c++/97202
337 * c-opts.cc (c_common_post_options): In C++20 or with -Wc++20-compat,
338 turn on -Wtemplate-id-cdtor.
339 * c.opt (Wtemplate-id-cdtor): New.
340
3412024-02-10 Jakub Jelinek <jakub@redhat.com>
342
343 * c-format.cc (gcc_diag_length_specs): Add t and z modifiers.
344 (PP_FORMAT_CHAR_TABLE, gcc_gfc_char_table): Add entries for t and
345 z modifiers.
346
3472024-02-10 Jakub Jelinek <jakub@redhat.com>
348
349 * c-ada-spec.cc (dump_template_types): Use HOST_SIZE_T_PRINT_UNSIGNED
350 and casts to fmt_size_t instead of "%lu" and casts to unsigned long.
351
e2554540
GA
3522024-02-01 Lewis Hyatt <lhyatt@gmail.com>
353
354 PR preprocessor/105608
355 * c-pch.cc (c_common_read_pch): Adjust line map so that libcpp
356 assigns a location to restored macros which is the same location
357 that triggered the PCH include.
358
dd3455f6
GA
3592024-01-31 Marek Polacek <polacek@redhat.com>
360
361 * c-opts.cc (c_common_post_options): Add an inform saying that
362 -fconcepts-ts is deprecated and will be removed in GCC 15.
363
3979171d
GA
3642024-01-27 Lewis Hyatt <lhyatt@gmail.com>
365
366 PR preprocessor/105608
367 * c-pch.cc (c_common_read_pch): Start a new line map before asking
368 libcpp to restore macros defined prior to reading the PCH, instead
369 of afterward.
370
3128786c
GA
3712024-01-23 Jakub Jelinek <jakub@redhat.com>
372
373 PR c/113518
374 * c-common.cc (atomic_bitint_fetch_using_cas_loop): Call c_fully_fold
375 on lhs_addr, val and model for C.
376
3772024-01-23 Sandra Loosemore <sandra@codesourcery.com>
378
379 * c.opt: Improve sorting of warning options.
380
1a177974
GA
3812024-01-16 Eric Botcazou <ebotcazou@adacore.com>
382
383 PR ada/113397
384 * c-ada-spec.cc (check_type_name_conflict): Add guard for the
385 presence of DECL_NAME on a TYPE_DECL.
386
1a80e955
GA
3872024-01-11 Julian Brown <julian@codesourcery.com>
388
389 * c-pretty-print.cc (c_pretty_printer::postfix_expression,
390 c_pretty_printer::expression): Add OMP_ARRAY_SECTION support.
391
73ce73fc
GA
3922024-01-09 waffl3x <waffl3x@protonmail.com>
393
394 PR c++/102609
395 PR c++/102609
396 C++23 P0847R7 (deducing this) - diagnostics.
397 * c-cppbuiltin.cc (c_cpp_builtins): Define
398 __cpp_explicit_this_parameter=202110L feature test macro.
399
4002024-01-09 Jakub Jelinek <jakub@redhat.com>
401
402 PR c/113262
403 * c-attribs.cc (handle_copy_attribute): Don't use
404 DECL_SOURCE_LOCATION (decl) if decl is not DECL_P, use input_location
405 instead. Formatting fixes.
406
4072024-01-09 Julian Brown <julian@codesourcery.com>
408
409 * c-common.h (c_omp_address_inspector): Remove static from get_origin
410 and maybe_unconvert_ref methods.
411 * c-omp.cc (c_omp_split_clauses): Support OMP_ARRAY_SECTION.
412 (c_omp_address_inspector::map_supported_p): Handle OMP_ARRAY_SECTION.
413 (c_omp_address_inspector::get_origin): Avoid dereferencing possibly
414 NULL type when processing template decls.
415 (c_omp_address_inspector::maybe_unconvert_ref): Likewise.
416
81d1a6e9
GA
4172024-01-04 David Malcolm <dmalcolm@redhat.com>
418
419 * c.opt.urls: New file, autogenerated by regenerate-opt-urls.py.
420
cdfaa4aa
GA
4212023-12-21 Jakub Jelinek <jakub@redhat.com>
422
423 * c.opt (Walloc-size): Enable also for C++ and ObjC++.
424
4252023-12-21 Jakub Jelinek <jakub@redhat.com>
426
427 PR sanitizer/113092
428 * c-ubsan.cc (ubsan_instrument_shift): Workaround for missing
429 ubsan _BitInt support for the shift count.
430
7ad9058c
GA
4312023-12-20 Florian Weimer <fweimer@redhat.com>
432
433 PR c/113050
434 * c-common.cc (get_atomic_generic_size): Use
435 OPT_Wdiscarded_qualifiers instead of
436 OPT_Wincompatible_pointer_types.
437
4382023-12-20 Jakub Jelinek <jakub@redhat.com>
439
440 * c.opt (Wcalloc-transposed-args): New warning.
441 * c-common.h (warn_for_calloc, warn_for_alloc_size): Declare.
442 * c-warn.cc (warn_for_calloc, warn_for_alloc_size): New functions.
443
7e6f0faa
GA
4442023-12-16 Andrew Carlotti <andrew.carlotti@arm.com>
445
446 * c-attribs.cc (attr_target_exclusions): Make
447 target/target_clones exclusion target-dependent.
448 (attr_target_clones_exclusions): Ditto, and add target_version.
449 (attr_target_version_exclusions): New.
450 (c_common_attribute_table): Add target_version.
451 (handle_target_version_attribute): New.
452 (handle_target_attribute): Amend comment.
453 (handle_target_clones_attribute): Ditto.
454
4552023-12-16 Andrew Carlotti <andrew.carlotti@arm.com>
456
457 * c-attribs.cc (attr_always_inline_exclusions): New.
458 (attr_target_exclusions): Ditto.
459 (attr_target_clones_exclusions): Ditto.
460 (c_common_attribute_table): Add new exclusion lists.
461 (handle_noinline_attribute): Remove custom exclusion handling.
462 (handle_always_inline_attribute): Ditto.
463 (handle_target_attribute): Ditto.
464 (handle_target_clones_attribute): Ditto.
465
e8018ccf
GA
4662023-12-13 Patrick Palka <ppalka@redhat.com>
467
468 * c.opt: Add -fdiagnostics-all-candidates.
469
4702023-12-13 Jason Merrill <jason@redhat.com>
471
472 * c-warn.cc (check_address_or_pointer_of_packed_member):
473 Rename to check_address_of_packed_member.
474 (check_and_warn_address_or_pointer_of_packed_member):
475 Rename to check_and_warn_address_of_packed_member.
476 (warn_for_address_or_pointer_of_packed_member):
477 Rename to warn_for_address_of_packed_member.
478 * c-common.h: Adjust.
479
4802023-12-13 Jason Merrill <jason@redhat.com>
481
482 * c-warn.cc (check_address_or_pointer_of_packed_member):
483 Remove warning based on TYPE_PACKED.
484
4852023-12-13 Julian Brown <julian@codesourcery.com>
486
487 * c-common.h (c_omp_region_type): Add C_ORT_EXIT_DATA,
488 C_ORT_OMP_EXIT_DATA and C_ORT_ACC_TARGET.
489 (omp_addr_token): Add forward declaration.
490 (c_omp_address_inspector): New class.
491 * c-omp.cc (c_omp_adjust_map_clauses): Mark decls addressable here, but
492 do not change any mapping node types.
493 (c_omp_address_inspector::unconverted_ref_origin,
494 c_omp_address_inspector::component_access_p,
495 c_omp_address_inspector::check_clause,
496 c_omp_address_inspector::get_root_term,
497 c_omp_address_inspector::map_supported_p,
498 c_omp_address_inspector::get_origin,
499 c_omp_address_inspector::maybe_unconvert_ref,
500 c_omp_address_inspector::maybe_zero_length_array_section,
501 c_omp_address_inspector::expand_array_base,
502 c_omp_address_inspector::expand_component_selector,
503 c_omp_address_inspector::expand_map_clause): New methods.
504 (omp_expand_access_chain): New function.
505
8a5d6ce0
GA
5062023-12-12 Richard Biener <rguenther@suse.de>
507
508 PR ipa/92606
509 * c-attribs.cc (handle_noicf_attribute): Also allow the
510 attribute on global variables.
511
4a6613e2
GA
5122023-12-10 Ken Matsui <kmatsui@gcc.gnu.org>
513 Patrick Palka <ppalka@redhat.com>
514
515 * c-common.cc (c_common_reswords): Remove all mappings of
516 built-in traits.
517 * c-common.h (enum rid): Remove all RID values for built-in
518 traits.
519
08f89e5e
GA
5202023-12-07 Andrew Pinski <pinskia@gmail.com>
521 Jakub Jelinek <jakub@redhat.com>
522
523 PR preprocessor/111965
524 * c-opts.cc (c_common_handle_option) <case OPT_fdebug_cpp>: Set
525 cpp_opts->debug to value rather than 1.
526
ae9e48e5
GA
5272023-12-06 David Malcolm <dmalcolm@redhat.com>
528
529 * c-opts.cc (c_diagnostic_finalizer): Make "diagnostic" param
530 const.
531
3dd09cd9
GA
5322023-12-06 Alexandre Oliva <oliva@adacore.com>
533
534 * c-attribs.cc: Include ipa-strub.h.
535 (handle_strub_attribute): New.
536 (c_common_attribute_table): Add strub.
537
5382023-12-05 Richard Sandiford <richard.sandiford@arm.com>
539
540 * c-attribs.cc (c_common_gnu_attribute_table): Add extra
541 braces to work around PR 16333 in older compilers.
542
5432023-12-05 Richard Biener <rguenther@suse.de>
544
545 PR c/89270
546 * c-common.cc (c_common_type_for_size): Consider
547 registered_builtin_types.
548
5492023-12-05 Marek Polacek <polacek@redhat.com>
550
551 PR c++/107687
552 PR c++/110997
553 * c-cppbuiltin.cc (c_cpp_builtins): Update __cpp_consteval.
554 * c-opts.cc (c_common_post_options): Pre-C++20, unset
555 flag_immediate_escalation.
556 * c.opt (fimmediate-escalation): New option.
557
04d4a494
GA
5582023-12-02 Richard Sandiford <richard.sandiford@arm.com>
559
560 * c-common.h (c_common_attribute_table): Replace with...
561 (c_common_gnu_attribute_table): ...this.
562 (c_common_format_attribute_table): Change type to
563 scoped_attribute_specs.
564 * c-attribs.cc (c_common_attribute_table): Replace with...
565 (c_common_gnu_attributes, c_common_gnu_attribute_table): ...these
566 new globals.
567 (c_common_format_attribute_table): Change type to
568 scoped_attribute_specs, using...
569 (c_common_format_attributes): ...this as the underlying array.
570
2e0f3f97
GA
5712023-12-01 Florian Weimer <fweimer@redhat.com>
572
573 * c.opt (Wdeclaration-missing-parameter-type): New.
574
8428bcd7
GA
5752023-11-30 Jakub Jelinek <jakub@redhat.com>
576
577 PR c++/110349
578 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
579 __cpp_placeholder_variables=202306L for C++26.
580
31d8cf17
GA
5812023-11-29 Alexandre Oliva <oliva@adacore.com>
582
583 * c-attribs.cc (c_common_attribute_table): Add hardbool.
584 (handle_hardbool_attribute): New.
585 (type_valid_for_vector_size): Reject hardbool.
586 * c-common.cc (convert_and_check): Skip warnings for convert
587 and check for hardbool.
588 (c_hardbool_type_attr_1): New.
589 * c-common.h (c_hardbool_type_attr): New.
590
ad3e759c
GA
5912023-11-27 Alex Coplan <alex.coplan@arm.com>
592 Iain Sandoe <iain@sandoe.co.uk>
593
594 PR c++/60512
595 * c-common.cc (struct hf_feature_info): New.
596 (c_common_register_feature): New.
597 (init_has_feature): New.
598 (has_feature_p): New.
599 * c-common.h (c_common_has_feature): New.
600 (c_family_register_lang_features): New.
601 (c_common_register_feature): New.
602 (has_feature_p): New.
603 * c-lex.cc (init_c_lex): Plumb through has_feature callback.
604 (c_common_has_builtin): Generalize and move common part ...
605 (c_common_lex_availability_macro): ... here.
606 (c_common_has_feature): New.
607 * c-ppoutput.cc (init_pp_output): Plumb through has_feature.
608
77cf1dba
GA
6092023-11-24 Lewis Hyatt <lhyatt@gmail.com>
610
611 PR pch/112319
612 * c-ppoutput.cc (cb_read_pch): Reinitialize the frontend parser
613 after loading a PCH.
614
6152023-11-24 Tobias Burnus <tobias@codesourcery.com>
616
617 * c.opt (-Wopenmp): Add missing tailing '.'.
618
6192023-11-24 Tobias Burnus <tobias@codesourcery.com>
620
621 * c.opt (Wopenmp): Add, enable by default.
622
6fb55db0
GA
6232023-11-23 Marek Polacek <polacek@redhat.com>
624
625 * c-opts.cc: Include "target.h".
626 (c_finish_options): Maybe cpp_define _FORTIFY_SOURCE
627 and _GLIBCXX_ASSERTIONS.
628
6292023-11-23 Jakub Jelinek <jakub@redhat.com>
630
631 * c-common.h (enum rid): Add RID_BUILTIN_STDC: New.
632 * c-common.cc (c_common_reswords): Add __builtin_stdc_bit_ceil,
633 __builtin_stdc_bit_floor, __builtin_stdc_bit_width,
634 __builtin_stdc_count_ones, __builtin_stdc_count_zeros,
635 __builtin_stdc_first_leading_one, __builtin_stdc_first_leading_zero,
636 __builtin_stdc_first_trailing_one, __builtin_stdc_first_trailing_zero,
637 __builtin_stdc_has_single_bit, __builtin_stdc_leading_ones,
638 __builtin_stdc_leading_zeros, __builtin_stdc_trailing_ones and
639 __builtin_stdc_trailing_zeros. Move __builtin_assoc_barrier
640 alphabetically earlier.
641
6422023-11-23 Jakub Jelinek <jakub@redhat.com>
643
644 PR c++/110348
645 * c.opt (Wc++26-extensions): New option.
646 * c-cppbuiltin.cc (c_cpp_builtins): For C++26 predefine
647 __cpp_static_assert to 202306L rather than 201411L.
648
b54b3800
GA
6492023-11-19 David Malcolm <dmalcolm@redhat.com>
650
651 * c-lex.cc: Include "rich-location.h".
652
9d58d2d8
GA
6532023-11-18 Sebastian Huber <sebastian.huber@embedded-brains.de>
654
655 * c-cppbuiltin.cc (c_cpp_builtins): Define
656 __LIBGCC_HAVE_LIBATOMIC for libgcov.
657
6582023-11-18 Sebastian Huber <sebastian.huber@embedded-brains.de>
659
660 Revert:
661 2021-08-16 Sebastian Huber <sebastian.huber@embedded-brains.de>
662
663 * c-cppbuiltin.c (c_cpp_builtins): Define
664 __LIBGCC_GCOV_TYPE_SIZE if flag_building_libgcc is true.
665
c63a0bbc
GA
6662023-11-17 Jakub Jelinek <jakub@redhat.com>
667
668 PR c++/107571
669 * c-gimplify.cc (genericize_c_loop): For C++ mark IFN_FALLTHROUGH
670 call at the end of loop body as TREE_NOTHROW.
671
eaedb56a
GA
6722023-11-14 Lewis Hyatt <lhyatt@gmail.com>
673
674 PR pch/9471
675 PR pch/47857
676 * c-opts.cc (c_common_post_options): Set cpp_opts->main_search
677 so libcpp knows it is compiling a header file separately.
678
6792023-11-14 David Malcolm <dmalcolm@redhat.com>
680
681 * c-warn.cc (conversion_warning): Update call to
682 global_dc->m_option_enabled to use option_enabled_p.
683
6842023-11-14 David Malcolm <dmalcolm@redhat.com>
685
686 * c-common.cc (c_get_substring_location): Use global_dc's
687 file_cache.
688 * c-format.cc (get_corrected_substring): Likewise.
689 * c-indentation.cc (get_visual_column): Add file_cache param.
690 (get_first_nws_vis_column): Likewise.
691 (detect_intervening_unindent): Likewise.
692 (should_warn_for_misleading_indentation): Use global_dc's
693 file_cache.
694 (assert_get_visual_column_succeeds): Add file_cache param.
695 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): Likewise.
696 (assert_get_visual_column_fails): Likewise.
697 (define ASSERT_GET_VISUAL_COLUMN_FAILS): Likewise.
698 (selftest::test_get_visual_column): Create and use a temporary
699 file_cache.
700
b9fd8399
GA
7012023-11-14 Jakub Jelinek <jakub@redhat.com>
702
703 PR c/111309
704 * c-common.cc (check_builtin_function_arguments): Handle
705 BUILT_IN_{CLZ,CTZ,CLRSB,FFS,PARITY,POPCOUNT}G.
706 * c-gimplify.cc (c_gimplify_expr): If __builtin_c[lt]zg second
707 argument hasn't been folded into constant yet, transform it to one
708 argument call inside of a COND_EXPR which for first argument 0
709 returns the second argument.
710
7112023-11-11 Martin Uecker <uecker@tugraz.at>
712
713 PR c/110815
714 PR c/112428
715 * c-attribs.cc (build_attr_access_from_parms): Synthesize
716 nonnull attribute for parameters declared with `static`.
717
7182023-11-09 Florian Weimer <fweimer@redhat.com>
719
720 * c.opt (Wreturn-mismatch): New.
721
3e9461a3
GA
7222023-11-08 Florian Weimer <fweimer@redhat.com>
723
724 * c.opt (fpermissive): Enable for C and ObjC.
725 * c-opts.cc (c_common_post_options): Enable -fpermissive.
726
c48f1056
GA
7272023-11-07 Joseph Myers <joseph@codesourcery.com>
728
729 * c-format.h (T2X_UI): Rename to T23_UI.
730 (T2X_UL): Rename to T23_UL.
731 (T2X_ULL): Rename to T23_ULL.
732 (T2X_US): Rename to T23_US.
733 (T2X_UC): Rename to T23_UC.
734 (T2X_ST): Rename to T23_ST.
735 (T2X_UPD): Rename to T23_UPD.
736 (T2X_UIM): Rename to T23_UIM.
737 (T2X_D32): Rename to T23_D32.
738 (T2X_D64): Rename to T23_D64.
739 (T2X_D128): Rename to T23_D128.
740 (T2X_I8): Rename to T23_I8.
741 (T2X_I16): Rename to T23_I16.
742 (T2X_I32): Rename to T23_I32.
743 (T2X_I64): Rename to T23_I64.
744 (T2X_U8): Rename to T23_U8.
745 (T2X_U16): Rename to T23_U16.
746 (T2X_U32): Rename to T23_U32.
747 (T2X_U64): Rename to T23_U64.
748 (T2X_IF8): Rename to T23_IF8.
749 (T2X_IF16): Rename to T23_IF16.
750 (T2X_IF32): Rename to T23_IF32.
751 (T2X_IF64): Rename to T23_IF64.
752 (T2X_UF8): Rename to T23_UF8.
753 (T2X_UF16): Rename to T23_UF16.
754 (T2X_UF32): Rename to T23_UF32.
755 (T2X_UF64): Rename to T23_UF64.
756 * c-format.cc: Update all uses of T2X_* macros to use T23_*.
757
7582023-11-07 Kwok Cheung Yeung <kcy@codesourcery.com>
759
760 * c-attribs.cc (c_common_attribute_table): Add attribute for
761 indirect functions.
762 * c-pragma.h (enum parma_omp_clause): Add entry for indirect clause.
763
7642023-11-07 Joseph Myers <joseph@codesourcery.com>
765
766 * c-common.cc (flag_isoc2x): Rename to flag_isoc23.
767 (c_common_reswords): Use D_C23 instead of D_C2X.
768 * c-common.h: Refer throughout to C23 instead of C2X in comments.
769 (D_C2X): Rename to D_C23.
770 (flag_isoc2x): Rename to flag_isoc23.
771 * c-cppbuiltin.cc (builtin_define_float_constants): Use
772 flag_isoc23 instead of flag_isoc2x. Refer to C23 instead of C2x
773 in comments.
774 * c-format.cc: Use STD_C23 instead of STD_C2X and flag_isoc23
775 instead of flag_isoc2x. Refer to C23 instead of C2X in comments.
776 * c-format.h: Use STD_C23 instead of STD_C2X.
777 * c-lex.cc: Use warn_c11_c23_compat instead of warn_c11_c2x_compat
778 and flag_isoc23 instead of flag_isoc2x. Refer to C23 instead of
779 C2X in diagnostics.
780 * c-opts.cc: Use flag_isoc23 instead of flag_isoc2x. Refer to C23
781 instead of C2X in comments.
782 (set_std_c2x): Rename to set_std_c23.
783 * c.opt (Wc11-c23-compat): Use CPP(cpp_warn_c11_c23_compat)
784 CppReason(CPP_W_C11_C23_COMPAT) Var(warn_c11_c23_compat) instead
785 of CPP(cpp_warn_c11_c2x_compat) CppReason(CPP_W_C11_C2X_COMPAT)
786 Var(warn_c11_c2x_compat).
787
2cca6ae6
GA
7882023-11-06 Joseph Myers <joseph@codesourcery.com>
789
790 PR c/107954
791 * c.opt (Wc11-c2x-compat): Rename to Wc11-c23-compat and make into
792 a deprecated alias of Wc11-c23-compat.
793 (std=c2x): Rename to std=c23 and make into a deprecated alias of
794 std=c23.
795 (std=gnu2x): Rename to std=gnu23 and make into a deprecated alias
796 of std=gnu23.
797 (std=iso9899:2024): New option. Alias of std=c23.
798 * c-lex.cc (interpret_float): Use OPT_Wc11_c23_compat instead of
799 OPT_Wc11_c2x_compat.
800 * c-opts.cc (c_common_handle_option): Use OPT_std_c23 instead of
801 OPT_std_c2x and OPT_std_gnu23 instead of OPT_std_gnu2x.
802
459866ea
GA
8032023-11-05 Jakub Jelinek <jakub@redhat.com>
804
805 * c-lex.cc (c_common_has_attribute): Return 1 for omp::directive
806 and omp::sequence with -fopenmp or -fopenmp-simd also for C, not
807 just for C++. Return 1 for omp::decl with -fopenmp or -fopenmp-simd
808 for both C and C++.
809
eb4e1b62
GA
8102023-11-04 David Malcolm <dmalcolm@redhat.com>
811
812 * c-pragma.cc:: (handle_pragma_push_options): Fix missing "GCC" in
813 name of pragma in "junk" message.
814 (handle_pragma_pop_options): Likewise.
815
8162023-11-04 David Malcolm <dmalcolm@redhat.com>
817
818 * c-common.cc: Update for changes to diagnostic_context.
819 * c-indentation.cc: Likewise.
820 * c-opts.cc: Likewise.
821 * c-warn.cc: Likewise.
822
c73d2d49
GA
8232023-11-01 Martin Uecker <uecker@tugraz.at>
824
825 PR c/71219
826 * c.opt (Walloc-size): New option.
827
eac0917b
GA
8282023-10-31 David Malcolm <dmalcolm@redhat.com>
829
830 * c-warn.cc (warn_for_multistatement_macros): Update for removal
831 of MACRO_MAP_EXPANSION_POINT_LOCATION.
832
7f974c5f
GA
8332023-10-27 Lewis Hyatt <lhyatt@gmail.com>
834
835 PR preprocessor/87299
836 * c-pragma.cc (init_pragma): Register `#pragma GCC target' and
837 related pragmas in preprocess-only mode, and enable early handling.
838 (c_reset_target_pragmas): New function refactoring code from...
839 (handle_pragma_reset_options): ...here.
840 * c-pragma.h (c_reset_target_pragmas): Declare.
841
ecca503b
GA
8422023-10-26 David Malcolm <dmalcolm@redhat.com>
843
844 * c-attribs.cc (c_common_attribute_table): Add
845 "null_terminated_string_arg".
846 (handle_null_terminated_string_arg_attribute): New.
847
9cf2e744
GA
8482023-10-23 Lewis Hyatt <lhyatt@gmail.com>
849
850 PR preprocessor/36887
851 * c-opts.cc (c_common_init_options): Pass new extra hash map
852 argument to cpp_create_reader().
853
6f684dd2
GA
8542023-10-20 Marek Polacek <polacek@redhat.com>
855
856 PR c/111884
857 * c-common.cc (c_common_get_alias_set): Return -1 for char8_t only
858 in C++.
859
8602023-10-20 Patrick Palka <ppalka@redhat.com>
861
862 * c-warn.cc (check_address_or_pointer_of_packed_member): Handle
863 type-dependent callee of CALL_EXPR.
864
8652023-10-20 Alexandre Oliva <oliva@adacore.com>
866
867 * c-attribs.cc (handle_expected_throw_attribute): New.
868 (c_common_attribute_table): Add expected_throw.
869
c85f7481
GA
8702023-10-19 Lewis Hyatt <lhyatt@gmail.com>
871
872 PR c++/89038
873 * c-pragma.cc (handle_pragma_diagnostic_impl): Handle
874 -Wunknown-pragmas during early processing.
875
d5cfabc6
GA
8762023-10-15 Jakub Jelinek <jakub@redhat.com>
877
878 PR tree-optimization/111800
879 * c-warn.cc (match_case_to_enum_1): Assert w.get_precision ()
880 is smaller or equal to WIDE_INT_MAX_INL_PRECISION rather than
881 w.get_len () is smaller or equal to WIDE_INT_MAX_INL_ELTS.
882
f9ef2e6d
GA
8832023-10-12 Jakub Jelinek <jakub@redhat.com>
884
885 PR c/102989
886 * c-warn.cc (match_case_to_enum_1): Use wi::to_wide just once instead
887 of 3 times, assert get_len () is smaller than WIDE_INT_MAX_INL_ELTS.
888
41d1c9a9
GA
8892023-10-02 David Malcolm <dmalcolm@redhat.com>
890
891 * c-common.cc (maybe_add_include_fixit): Update for renaming of
892 diagnostic_context's show_caret to m_source_printing.enabled.
893 * c-opts.cc (c_common_init_options): Update for renaming of
894 diagnostic_context's colorize_source_p to
895 m_source_printing.colorize_source_p.
896
4907d220
GA
8972023-09-20 Jakub Jelinek <jakub@redhat.com>
898
899 PR c++/111392
900 * c-omp.cc (c_omp_directives): Add commented out groupprivate
901 directive entry.
902
590a8bec
GA
9032023-09-19 Ben Boeckel <ben.boeckel@kitware.com>
904
905 * c-opts.cc (c_common_handle_option): Add fdeps_file variable and
906 -fdeps-format=, -fdeps-file=, and -fdeps-target= parsing.
907 * c.opt: Add -fdeps-format=, -fdeps-file=, and -fdeps-target=
908 flags.
909
9102023-09-19 Javier Martinez <javier.martinez.bugzilla@gmail.com>
911
912 * c-attribs.cc (handle_hot_attribute): remove warning on
913 RECORD_TYPE and UNION_TYPE when in c_dialect_xx.
914 (handle_cold_attribute): Likewise.
915
9162023-09-19 Jakub Jelinek <jakub@redhat.com>
917
918 * c-common.cc (c_common_signed_or_unsigned_type): Return INTEGER_TYPE
919 for signed variant of unsigned _BitInt(1).
920
a134b6ce
GA
9212023-09-06 Jakub Jelinek <jakub@redhat.com>
922
923 PR c/102989
924 * c-attribs.cc (type_valid_for_vector_size): Reject vector types
925 with BITINT_TYPE elements even if they have mode precision and
926 suitable size.
927
9282023-09-06 Jakub Jelinek <jakub@redhat.com>
929
930 PR c/102989
931 * c-common.cc (c_common_reswords): Add _BitInt as keyword.
932 (unsafe_conversion_p): Handle BITINT_TYPE like INTEGER_TYPE.
933 (c_common_signed_or_unsigned_type): Handle BITINT_TYPE.
934 (c_common_truthvalue_conversion, c_common_get_alias_set,
935 check_builtin_function_arguments): Handle BITINT_TYPE like
936 INTEGER_TYPE.
937 (sync_resolve_size): Add ORIG_FORMAT argument. If
938 FETCH && !ORIG_FORMAT, type is BITINT_TYPE, return -1 if size isn't
939 one of 1, 2, 4, 8 or 16 or if it is 16 but TImode is not supported.
940 (atomic_bitint_fetch_using_cas_loop): New function.
941 (resolve_overloaded_builtin): Adjust sync_resolve_size caller. If
942 -1 is returned, use atomic_bitint_fetch_using_cas_loop to lower it.
943 Formatting fix.
944 (keyword_begins_type_specifier): Handle RID_BITINT.
945 * c-common.h (enum rid): Add RID_BITINT enumerator.
946 * c-cppbuiltin.cc (c_cpp_builtins): For C call
947 targetm.c.bitint_type_info and predefine __BITINT_MAXWIDTH__
948 and for -fbuilding-libgcc also __LIBGCC_BITINT_LIMB_WIDTH__ and
949 __LIBGCC_BITINT_ORDER__ macros if _BitInt is supported.
950 * c-lex.cc (interpret_integer): Handle CPP_N_BITINT.
951 * c-pretty-print.cc (c_pretty_printer::simple_type_specifier,
952 c_pretty_printer::direct_abstract_declarator,
953 c_pretty_printer::direct_declarator, c_pretty_printer::declarator):
954 Handle BITINT_TYPE.
955 (pp_c_integer_constant): Handle printing of large precision wide_ints
956 which would buffer overflow digit_buffer.
957 * c-warn.cc (conversion_warning, warnings_for_convert_and_check,
958 warnings_for_convert_and_check): Handle BITINT_TYPE like
959 INTEGER_TYPE.
960
9612023-09-06 Jakub Jelinek <jakub@redhat.com>
962
963 PR c/102989
964 * c-ubsan.cc (ubsan_instrument_shift): Use UBSAN_PRINT_FORCE_INT
965 for type0 type descriptor.
966
9672023-09-06 Jakub Jelinek <jakub@redhat.com>
968
969 * c-lex.cc (interpret_float): For C diagnostics on FN and FNx suffixes
970 append " before C2X" to diagnostics text and follow behavior of
971 pedwarn_c11.
972
80907b03
GA
9732023-09-01 Jakub Jelinek <jakub@redhat.com>
974
975 PR c++/111069
976 * c-opts.cc (c_common_post_options): Change latest_abi_version to 19.
977
65c36ecc
GA
9782023-08-31 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
979
980 * c.opt: Change spelling to macOS.
981
9822023-08-31 Richard Biener <rguenther@suse.de>
983
984 PR middle-end/111253
985 * c-pretty-print.cc (c_pretty_printer::primary_expression):
986 Only dump gimple_assign_single_p SSA def RHS.
987
b8863640
GA
9882023-08-25 Sandra Loosemore <sandra@codesourcery.com>
989
990 * c-common.h (c_omp_check_loop_binding_exprs): Declare.
991 * c-omp.cc: Include tree-iterator.h.
992 (find_binding_in_body): New.
993 (check_loop_binding_expr_r): New.
994 (LOCATION_OR): New.
995 (check_looop_binding_expr): New.
996 (c_omp_check_loop_binding_exprs): New.
997
9982023-08-25 Uros Bizjak <ubizjak@gmail.com>
999
1000 * c-format.cc (read_any_format_width):
1001 Rename TRUE/FALSE to true/false.
1002
a7593210
GA
10032023-08-20 Martin Uecker <uecker@tugraz.at>
1004
1005 * c-format.cc: Fix identation.
1006
10072023-08-20 Tomas Kalibera <tomas.kalibera@gmail.com>
1008
1009 PR c/95130
1010 * c-format.cc: skip default format for printf symbol if
1011 explicitly declared by prototype.
1012
1eb2433f
GA
10132023-08-17 Jose E. Marchesi <jose.marchesi@oracle.com>
1014
1015 PR c/106537
1016 * c.opt (Wcompare-distinct-pointer-types): New option.
1017
3cc78cf2
GA
10182023-08-14 Jason Merrill <jason@redhat.com>
1019
1020 * c-cppbuiltin.cc (c_cpp_builtins): Adjust __cpp_concepts.
1021
886afed6
GA
10222023-08-11 Jakub Jelinek <jakub@redhat.com>
1023
1024 * c-common.cc (c_common_reswords): Add __typeof_unqual
1025 and __typeof_unqual__ spellings of typeof_unqual.
1026
10272023-08-11 Martin Uecker <uecker@tugraz.at>
1028
1029 PR c/84510
1030 * c.opt: Enable warning for C and ObjC.
1031
87b0749c
GA
10322023-08-05 Martin Uecker <uecker@tugraz.at>
1033
1034 PR c/98536
1035 * c-warn.cc (warn_parm_array_mismatch): Do not warn if more
1036 bounds are specified.
1037
5b42ee2c
GA
10382023-08-04 Tamar Christina <tamar.christina@arm.com>
1039
1040 * c-pragma.h (enum pragma_kind): Add PRAGMA_NOVECTOR.
1041 * c-pragma.cc (init_pragma): Use it.
1042
cf58b896
GA
10432023-08-01 Lewis Hyatt <lhyatt@gmail.com>
1044
1045 * c-common.h (c_init_preprocess): Declare new function.
1046 * c-opts.cc (c_common_init): Call it.
1047 * c-lex.cc (cb_def_pragma): Add a comment.
1048 (get_token): New function wrapping cpp_get_token.
1049 (c_lex_with_flags): Use the new wrapper function to support
1050 obtaining tokens in preprocess_only mode.
1051 (lex_string): Likewise.
1052 * c-pragma.cc (pragma_diagnostic_lex_normal): Rename to...
1053 (pragma_diagnostic_lex): ...this.
1054 (pragma_diagnostic_lex_pp): Remove.
1055 (handle_pragma_diagnostic_impl): Call pragma_diagnostic_lex () in
1056 all modes.
1057 (c_pp_invoke_early_pragma_handler): Adapt to support pragma_lex ()
1058 usage.
1059 * c-pragma.h (pragma_lex_discard_to_eol): Declare.
1060
a2f31d79
GA
10612023-07-31 Hamza Mahfooz <someguy@effective-light.com>
1062
1063 PR c/65213
1064 * c.opt (-Wmissing-variable-declarations): New option.
1065
e2bf82d5
GA
10662023-07-20 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1067
1068 PR middle-end/77928
1069 * c-common.cc (check_builtin_function_arguments):
1070 Handle BUILT_IN_ISEQSIG.
1071
5158918a
GA
10722023-07-05 Robin Dapp <rdapp@ventanamicro.com>
1073 Juzhe-Zhong <juzhe.zhong@rivai.ai>
1074
1075 * c-common.cc (c_common_type_for_mode): Use GET_MODE_PRECISION.
1076
14bfda60
GA
10772023-06-29 Qing Zhao <qing.zhao@oracle.com>
1078
1079 PR c/77650
1080 * c.opt: New option -Wflex-array-member-not-at-end.
1081
5f590ee3
GA
10822023-06-28 Jason Merrill <jason@redhat.com>
1083
1084 PR c++/110344
1085 * c-cppbuiltin.cc (c_cpp_builtins): Update __cpp_constexpr.
1086
267e1fea
GA
10872023-06-26 Richard Biener <rguenther@suse.de>
1088
1089 * c-common.cc (shorten_binary_op): Exit early for VECTOR_TYPE
1090 operations.
1091
6f78df4c
GA
10922023-06-23 Marek Polacek <polacek@redhat.com>
1093
1094 * c-common.h (cxx_dialect): Add cxx26 as a dialect.
1095 * c-opts.cc (set_std_cxx26): New.
1096 (c_common_handle_option): Set options when -std={c,gnu}++2{c,6} is
1097 enabled.
1098 (c_common_post_options): Adjust comments.
1099 * c.opt: Add options for -std=c++26, std=c++2c, -std=gnu++26,
1100 and -std=gnu++2c.
1101 (std=c++2b): Mark as Undocumented.
1102 (std=c++23): No longer Undocumented.
1103
80e9ca0e
GA
11042023-06-21 Alexander Monakov <amonakov@ispras.ru>
1105
1106 * c-gimplify.cc (fma_supported_p): New helper.
1107 (c_gimplify_expr) [PLUS_EXPR, MINUS_EXPR]: Implement FMA
1108 contraction.
1109
f10a4ce0
GA
11102023-06-16 Alex Coplan <alex.coplan@arm.com>
1111
1112 * c.opt (Welaborated-enum-base): New.
1113
532fb120
GA
11142023-06-13 David Malcolm <dmalcolm@redhat.com>
1115
1116 PR c/84890
1117 * known-headers.cc
1118 (suggest_missing_header::~suggest_missing_header): Reword note to
1119 avoid negative tone of "forgetting".
1120
8c5b1365
GA
11212023-06-07 Jason Merrill <jason@redhat.com>
1122
1123 PR c++/58487
1124 * c.opt: Add -Wnrvo.
1125
6e6bb373
GA
11262023-05-26 Martin Uecker <uecker@tugraz.at>
1127
1128 * c-attribs.cc (build_attr_access_from_parms): Split loop to first
1129 record all parameters.
1130
b2776076
GA
11312023-05-18 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
1132
1133 * c-ada-spec.cc (has_static_fields): Use _P() defines from tree.h.
1134 (dump_ada_declaration): Ditto.
1135 (dump_ada_structure): Ditto.
1136 * c-common.cc (unsafe_conversion_p): Ditto.
1137 (shorten_compare): Ditto.
1138 (pointer_int_sum): Ditto.
1139 (c_common_truthvalue_conversion): Ditto.
1140 (scalar_to_vector): Ditto.
1141 * c-common.h (gnu_vector_type_p): Ditto.
1142 * c-omp.cc (c_omp_depend_t_p): Ditto.
1143 (c_omp_split_clauses): Ditto.
1144 * c-ubsan.cc (ubsan_instrument_division): Ditto.
1145 * c-warn.cc (conversion_warning): Ditto.
1146 (warnings_for_convert_and_check): Ditto.
1147
ff2dcddf
GA
11482023-05-18 Joseph Myers <joseph@codesourcery.com>
1149
1150 * c-format.cc (print_char_table): Handle %B like %b.
1151
3427b51b
GA
11522023-05-15 Joseph Myers <joseph@codesourcery.com>
1153
1154 * c-lex.cc (c_common_has_attribute): Use 202311 as
1155 __has_c_attribute return for all C2x attributes.
1156
11572023-05-15 Patrick Palka <ppalka@redhat.com>
1158
1159 * c-cppbuiltin.cc (c_cpp_builtins): Predefine __cpp_auto_cast
1160 for C++23.
1161
1fc8da95
GA
11622023-05-01 Marek Polacek <polacek@redhat.com>
1163
1164 * c-ubsan.cc (ubsan_maybe_instrument_array_ref): Don't copy_node.
1165
579cdc1e
GA
11662023-03-28 David Malcolm <dmalcolm@redhat.com>
1167
1168 PR c/107002
1169 * c-common.h (check_for_xor_used_as_pow): Add "rhs_loc" param.
1170 * c-warn.cc (check_for_xor_used_as_pow): Add "rhs_loc" param.
1171 Reject cases where involving macro expansions.
1172
11732023-03-28 Jason Merrill <jason@redhat.com>
1174
1175 PR c++/107163
1176 * c-common.cc (verify_tree): Don't use sequenced handling
1177 for COMPONENT_REF.
1178
454a4d50
GA
11792023-03-17 Jakub Jelinek <jakub@redhat.com>
1180
1181 PR c/109151
1182 * c-ubsan.cc (ubsan_instrument_division): Handle all scalar integral
1183 types rather than just INTEGER_TYPE.
1184
c8065441
GA
11852023-03-10 Marek Polacek <polacek@redhat.com>
1186
1187 PR sanitizer/108060
1188 PR sanitizer/109050
1189 * c-gimplify.cc (ubsan_walk_array_refs_r): For a MODIFY_EXPR, instrument
1190 the RHS before the LHS.
1191
2858bf16
GA
11922023-03-04 Jakub Jelinek <jakub@redhat.com>
1193
1194 PR c/107465
1195 * c-warn.cc (warn_for_sign_compare): Don't warn for unset bits
1196 above innermost zero extension of BIT_NOT_EXPR result.
1197
11982023-03-04 Jakub Jelinek <jakub@redhat.com>
1199
1200 PR c/107465
1201 * c-warn.cc (warn_for_sign_compare): If c_common_get_narrower
1202 doesn't return a narrower result, use TYPE_UNSIGNED to set unsignedp0
1203 and unsignedp1. For the one BIT_NOT_EXPR case vs. one without,
1204 only check for constant in the non-BIT_NOT_EXPR operand, use std::swap
1205 to simplify the code, only warn if BIT_NOT_EXPR operand is extended
1206 from narrower unsigned, fix up computation of mask for the constant
1207 cases and for unsigned other operand case handle differently
1208 BIT_NOT_EXPR result being sign vs. zero extended.
1209
12102023-03-04 Jakub Jelinek <jakub@redhat.com>
1211
1212 PR c/107846
1213 * c-warn.cc: Include langhooks.h.
1214 (maybe_warn_shift_overflow): Set type0 to what TREE_TYPE (op0)
1215 promotes to rather than TREE_TYPE (op0) itself, if TREE_TYPE (op0)
1216 is narrower than type0 and unsigned, use wi::min_precision with
1217 UNSIGNED and fold_convert op0 to type0 before emitting the warning.
1218
2aa6673e
GA
12192023-03-03 Alexandre Oliva <oliva@adacore.com>
1220
1221 * c-common.cc (c_common_nodes_and_builtins): Take
1222 wchar_type_node for wint_type_node when aliased.
1223 (c_stddef_cpp_builtins): Define __WINT_TYPE__, when aliased to
1224 wchar_t, to the underlying type rather than wchar_t in
1225 non-C++.
1226 * c-cppbuiltin.cc (type_suffix): Handle wchar_type_node.
1227
6f9e2f14
GA
12282023-02-28 Marek Polacek <polacek@redhat.com>
1229
1230 PR c++/107938
1231 * c-warn.cc (check_address_or_pointer_of_packed_member): Check
1232 POINTER_TYPE_P.
1233
12342023-02-28 Jakub Jelinek <jakub@redhat.com>
1235
1236 PR sanitizer/108894
1237 * c-common.h (c_strict_flex_array_level_of): Declare.
1238 * c-common.cc (c_strict_flex_array_level_of): New function,
1239 moved and renamed from c-decl.cc's strict_flex_array_level_of.
1240 * c-ubsan.cc (ubsan_instrument_bounds): Fix comment typo. For
1241 C check c_strict_flex_array_level_of whether a trailing array
1242 should be treated as flexible member like. Handle C [0] arrays.
1243 Add 1 + index_off_by_one rather than index_off_by_one to bounds
1244 and use tree_int_cst_lt rather than tree_int_cst_le for idx vs.
1245 bounds comparison.
1246
e2b20ed3
GA
12472023-02-23 Jakub Jelinek <jakub@redhat.com>
1248
1249 PR translation/108890
1250 * c.opt (fcontracts): Fix description.
1251
b6f98991
GA
12522023-02-22 Marek Polacek <polacek@redhat.com>
1253
1254 PR c/108880
1255 * c-gimplify.cc (c_genericize_control_stmt) <case STATEMENT_LIST>: Pass
1256 pset to walk_tree_1.
1257 (c_genericize): Call walk_tree with an explicit pset.
1258
0263e9d5
GA
12592023-02-18 Martin Uecker <uecker@tugraz.at>
1260
1261 PR c/105660
1262 * c-attribs.cc (append_access_attr): Use order of arguments when
1263 construction string.
1264 (append_access_attr_idxs): Rename and make static.
1265 * c-warn.cc (warn_parm_array_mismatch): Add assertion.
1266
88cc4495
GA
12672023-02-16 Patrick Palka <ppalka@redhat.com>
1268
1269 * c-common.h: Mechanically drop static from static inline
1270 functions via s/^static inline/inline/g.
1271
0a251e74
GA
12722023-02-01 Jason Merrill <jason@redhat.com>
1273
1274 * c.opt: Add -Wno-changes-meaning.
1275
317525b0
GA
12762023-01-31 Marek Polacek <polacek@redhat.com>
1277
1278 PR c++/107593
1279 PR c++/108597
1280 * c-common.h (instantiation_dependent_expression_p): Declare.
1281 * c-warn.cc (warn_duplicated_cond_add_or_warn): If the condition
1282 is dependent, invalidate the chain.
1283
2371d100
GA
12842023-01-26 Marek Polacek <polacek@redhat.com>
1285
1286 PR c++/105300
1287 * c-pragma.cc (handle_pragma_message): Warn for CPP_STRING_USERDEF.
1288
9f98cfa5
GA
12892023-01-18 Marek Polacek <polacek@redhat.com>
1290
1291 PR c/108424
1292 * c-common.cc (check_case_value): Check INTEGRAL_TYPE_P.
1293
5013c3bb
GA
12942023-01-14 Jakub Jelinek <jakub@redhat.com>
1295
1296 PR c++/108365
1297 * c-common.h (may_shorten_divmod): New static inline function.
1298
12992023-01-13 Eric Botcazou <ebotcazou@adacore.com>
1300
1301 * c-ada-spec.cc (is_float32): New function.
1302 (is_float64): Likewise.
1303 (is_float128): Tweak.
1304 (dump_ada_node) <REAL_TYPE>: Call them to recognize more types.
1305
81ed98bc
GA
13062023-01-12 Lewis Hyatt <lhyatt@gmail.com>
1307
1308 PR preprocessor/108244
1309 * c-pragma.cc (c_register_pragma_1): Don't attempt to register any
1310 deferred pragmas if -fdirectives-only.
1311 (init_pragma): Likewise.
1312
84723aca
GA
13132023-01-09 Martin Liska <mliska@suse.cz>
1314
1315 PR c/107993
1316 * c-attribs.cc (handle_target_clones_attribute): Check for
1317 string constant for all target_clone attribute values.
1318
0f8fbb57
GA
13192023-01-03 Florian Weimer <fweimer@redhat.com>
1320
1321 * c-cppbuiltin.cc (c_cpp_builtins): Define
1322 __LIBGCC_DWARF_CIE_DATA_ALIGNMENT__.
1323
13242023-01-03 Florian Weimer <fweimer@redhat.com>
1325
1326 Revert:
1327 2023-01-03 Florian Weimer <fweimer@redhat.com>
1328
1329 * c-cppbuiltin.cc (__LIBGCC_DWARF_REG_SIZES_CONSTANT__):
1330 Define if constant is known.
1331
13322023-01-03 Florian Weimer <fweimer@redhat.com>
1333
1334 Revert:
1335 2023-01-02 Florian Weimer <fweimer@redhat.com>
1336
1337 * c-cppbuiltin.cc (c_cpp_builtins): Define
1338 __LIBGCC_DWARF_CIE_DATA_ALIGNMENT__.
1339
fee53a31
GA
13402023-01-02 Florian Weimer <fweimer@redhat.com>
1341
1342 * c-cppbuiltin.cc (c_cpp_builtins): Define
1343 __LIBGCC_DWARF_CIE_DATA_ALIGNMENT__.
1344
13452023-01-02 Florian Weimer <fweimer@redhat.com>
1346
1347 * c-cppbuiltin.cc (__LIBGCC_DWARF_REG_SIZES_CONSTANT__):
1348 Define if constant is known.
1349
d2ef2327
GA
13502022-12-19 Marek Polacek <polacek@redhat.com>
1351
1352 PR c/98487
1353 * c-format.cc (check_function_format): Use get_attribute_name.
1354
5fb1e674
GA
13552022-12-16 Qing Zhao <qing.zhao@oracle.com>
1356
1357 * c.opt (Wstrict-flex-arrays): New option.
1358
596dbfff
GA
13592022-12-02 Andrew MacLeod <amacleod@redhat.com>
1360
1361 * c-attribs.cc (handle_deprecated_attribute): Use type when
1362 using TYPE_NAME.
1363
b35680ec
GA
13642022-12-02 Jakub Jelinek <jakub@redhat.com>
1365
1366 PR c++/84469
1367 * c-omp.cc (c_omp_is_loop_iterator): For range for with structured
1368 binding return TREE_VEC_LENGTH (d->declv) even if decl is equal
1369 to any of the structured binding decls.
1370
6eea85a9
GA
13712022-11-30 Iskander Shakirzyanov <iskander@ispras.ru>
1372 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
1373
1374 PR driver/107787
1375 * c-common.cc (fold_offsetof,
1376 convert_vector_to_array_for_subscript): Use OPT_Warray_bounds_
1377 instead of OPT_Warray_bounds.
1378
9a1b4f1d
GA
13792022-11-24 Jakub Jelinek <jakub@redhat.com>
1380
1381 * c.opt (fcontract-role=, fcontract-semantic=): Terminate descriptions
1382 with a dot.
1383
8761284f
GA
13842022-11-23 Andrew Pinski <apinski@marvell.com>
1385 Jakub Jelinek <jakub@redhat.com>
1386
1387 PR c/107127
1388 * c-gimplify.cc (c_genericize): Use walk_tree_without_duplicates
1389 instead of walk_tree for c_genericize_control_r.
1390
13912022-11-23 Jakub Jelinek <jakub@redhat.com>
1392
1393 * c.opt (fcontract-assumption-mode=, fcontract-continuation-mode=,
1394 fcontract-role=, fcontract-semantic=): Add RejectNegative.
1395 (fcontract-build-level=): Terminate description with dot.
1396
fb98ede8
GA
13972022-11-19 Jakub Jelinek <jakub@redhat.com>
1398
1399 * c-cppbuiltin.cc (c_cpp_builtins): Bump __cpp_constexpr
1400 value from 202207L to 202211L.
1401
14022022-11-19 Jeff Chapman II <jchapman@lock3software.com>
1403 Andrew Sutton <asutton@lock3software.com>
1404 Andrew Marmaduke <amarmaduke@lock3software.com>
1405 Michael Lopez <mlopez@lock3software.com>
1406 Jason Merrill <jason@redhat.com>
1407
1408 * c.opt: Add contracts flags.
1409 * c-cppbuiltin.cc (c_cpp_builtins): Add contracts feature-test
1410 macros.
1411
80909529
GA
14122022-11-16 Marek Polacek <polacek@redhat.com>
1413
1414 PR c++/106649
1415 * c-cppbuiltin.cc (c_cpp_builtins): Update value of __cpp_constexpr for
1416 C++23.
1417 * c-opts.cc (c_common_post_options): Set warn_invalid_constexpr
1418 depending on cxx_dialect.
1419 * c.opt (Winvalid-constexpr): New option.
1420
14212022-11-16 Jakub Jelinek <jakub@redhat.com>
1422
1423 * c-common.def (CONCEPT_DECL): New tree, moved here from
1424 cp-tree.def.
1425 * c-common.cc (c_common_init_ts): Handle CONCEPT_DECL.
1426 * c-attribs.cc (handle_deprecated_attribute): Allow deprecated
1427 attribute on CONCEPT_DECL.
1428
cdc34229
GA
14292022-11-15 Lewis Hyatt <lhyatt@gmail.com>
1430
1431 * c-opts.cc (c_finish_options): Use special_fname_builtin () rather
1432 than a hard-coded string.
1433
83d400bd
GA
14342022-11-15 Jakub Jelinek <jakub@redhat.com>
1435
1436 * c-cppbuiltin.cc (c_cpp_builtins): Bump C++23
1437 __cpp_multidimensional_subscript macro value to 202211L.
1438
14392022-11-15 Patrick Palka <ppalka@redhat.com>
1440
1441 PR c++/107638
1442 * c-lex.cc (c_common_has_attribute): Return 1 for init_priority
1443 iff SUPPORTS_INIT_PRIORITY.
1444
14452022-11-14 Martin Liska <mliska@suse.cz>
1446
1447 Revert:
1448 2022-11-09 Martin Liska <mliska@suse.cz>
1449
1450 * c-target.def: Port to RST.
1451
30d77d49
GA
14522022-11-12 Joseph Myers <joseph@codesourcery.com>
1453
1454 * c-common.cc (c_common_reswords): Use D_C2X instead of D_CXXONLY.
1455
5b6ce16a
GA
14562022-11-11 Jonathan Wakely <jwakely@redhat.com>
1457
1458 PR c/85487
1459 * c-pragma.cc (handle_pragma_ignore): New function.
1460 (init_pragma): Register region and endregion pragmas.
1461
1cdfd0e5
GA
14622022-11-09 Martin Liska <mliska@suse.cz>
1463
1464 * c-target.def: Port to RST.
1465
05788e9b
GA
14662022-11-05 Lewis Hyatt <lhyatt@gmail.com>
1467
1468 PR preprocessor/55971
1469 * c-ppoutput.cc (adjust_for_newlines): Update comment.
1470
d29260ce
GA
14712022-11-03 Jason Merrill <jason@redhat.com>
1472
1473 * c-opts.cc (c_common_post_options): -fconcepts no longer implies
1474 -fconcepts-ts before C++20.
1475
3055829a
GA
14762022-10-28 Joseph Myers <joseph@codesourcery.com>
1477
1478 * c-common.cc (def_fn_type): Call build_function_type for
1479 zero-argument variable-argument function.
1480 (c_common_nodes_and_builtins): Build default_function_type with
1481 build_function_type.
1482 * c.opt (fallow-parameterless-variadic-functions): Mark as ignored
1483 option.
1484
14852022-10-28 Joseph Myers <joseph@codesourcery.com>
1486
1487 PR c/61469
1488 * c-common.h (ENUM_UNDERLYING_TYPE, ENUM_FIXED_UNDERLYING_TYPE_P):
1489 New. Moved from cp/cp-tree.h.
1490 * c-warn.cc (warnings_for_convert_and_check): Do not consider
1491 conversions to enum with underlying type bool to overflow.
1492
486a5037
GA
14932022-10-26 Marek Polacek <polacek@redhat.com>
1494
1495 PR c++/106393
1496 * c.opt (Wdangling-reference): New.
1497
87f9c4a4
GA
14982022-10-19 Joseph Myers <joseph@codesourcery.com>
1499
1500 * c-format.h (enum format_lengths): Add FMT_LEN_w8, FMT_LEN_w16,
1501 FMT_LEN_w32, FMT_LEN_w64, FMT_LEN_wf8, FMT_LEN_wf16, FMT_LEN_wf32
1502 and FMT_LEN_wf64.
1503 (NOARGUMENTS, NOLENGTHS): Update definitions.
1504 (T_I8, T2X_I8, T_I16, T2X_I16, T_I32, T2X_I32, T_I64, T2X_I64)
1505 (T_U8, T2X_U8, T_U16, T2X_U16, T_U32, T2X_U32, T_U64, T2X_U64)
1506 (T_IF8, T2X_IF8, T_IF16, T2X_IF16, T_IF32, T2X_IF32, T_IF64)
1507 (T2X_IF64, T_UF8, T2X_UF8, T_UF16, T2X_UF16, T_UF32, T2X_UF32)
1508 (T_UF64, T2X_UF64): New macros.
1509 * c-format.cc (printf_length_specs, scanf_length_specs): Add wN
1510 and wfN length modifiers.
1511 (print_char_table, scan_char_table): Add entries using wN and wfN
1512 length modifiers.
1513
21de009f
GA
15142022-10-18 Joseph Myers <joseph@codesourcery.com>
1515
1516 PR c/36113
1517 * c-common.cc (c_common_type_for_size): Add fallback to
1518 widest_unsigned_literal_type_node or
1519 widest_integer_literal_type_node for precision that may not
1520 exactly match the precision of those types.
1521
baeec7cc
GA
15222022-10-14 Jakub Jelinek <jakub@redhat.com>
1523
1524 * c-cppbuiltin.cc (c_cpp_builtins): If bfloat16_type_node,
1525 predefine __BFLT16_*__ macros and for C++23 also
1526 __STDCPP_BFLOAT16_T__. Predefine bfloat16_type_node related
1527 macros for -fbuilding-libgcc.
1528 * c-lex.cc (interpret_float): Handle CPP_N_BFLOAT16.
1529
15302022-10-14 Jakub Jelinek <jakub@redhat.com>
1531
1532 PR middle-end/323
1533 PR c++/107097
1534 * c-common.def (EXCESS_PRECISION_EXPR): Remove comment part about
1535 the tree being specific to C/ObjC.
1536 * c-opts.cc (c_common_post_options): Handle flag_excess_precision
1537 in C++ the same as in C.
1538 * c-lex.cc (interpret_float): Set const_type to excess_precision ()
1539 even for C++.
1540
621a911d
GA
15412022-10-13 Joseph Myers <joseph@codesourcery.com>
1542
1543 * c-cppbuiltin.cc (builtin_define_float_constants): Do not use
1544 value 2 for *_IS_IEC_60559.
1545
781f477a
GA
15462022-10-12 Lewis Hyatt <lhyatt@gmail.com>
1547
1548 PR preprocessor/60014
1549 PR preprocessor/60723
1550 * c-ppoutput.cc (class token_streamer): Remove member
1551 line_marker_emitted to...
1552 (token_streamer::stream): ...a local variable here. Set
1553 print.prev_was_system_token on all code paths.
1554
27bfe54e
GA
15552022-10-10 Nathan Sidwell <nathan@acm.org>
1556
1557 * c-opts.cc (c_common_post_options): Bump abi to 18.
1558
15592022-10-10 Marek Polacek <polacek@redhat.com>
1560
1561 PR c++/106937
1562 * c-pretty-print.cc (pp_c_specifier_qualifier_list): Print only GNU
1563 attributes here.
1564 (c_pretty_printer::direct_abstract_declarator): Print the standard [[]]
1565 attributes here.
1566 (pp_c_attributes): Remove.
1567 (pp_c_attributes_display): Print the [[]] form if appropriate. Use
1568 get_attribute_name. Don't print a trailing space when printing the
1569 [[]] form.
1570 * c-pretty-print.h (pp_c_attributes): Remove.
1571
9ff6c33e
GA
15722022-10-07 Qing Zhao <qing.zhao@oracle.com>
1573
1574 * c-attribs.cc (handle_strict_flex_array_attribute): New function.
1575 (c_common_attribute_table): New item for strict_flex_array.
1576 * c.opt: (fstrict-flex-arrays): New option.
1577 (fstrict-flex-arrays=): New option.
1578
15792022-10-07 Martin Liska <mliska@suse.cz>
1580
1581 * name-hint.h: Use std::move.
1582
15832022-10-07 Jakub Jelinek <jakub@redhat.com>
1584
1585 * c-common.cc (attribute_fallthrough_p): Lookup fallthrough attribute
1586 only in gnu namespace or as standard attribute, treat fallthrough
1587 attributes in other namespaces like any other unknown attribute.
1588
629d04d3
GA
15892022-10-06 Joseph Myers <joseph@codesourcery.com>
1590
1591 * c-common.cc (c_common_reswords): Mark typeof as D_EXT11. Add
1592 typeof_unqual.
1593 * c-common.h (enum rid): Add RID_TYPEOF_UNQUAL.
1594 (D_EXT11): New macro. Values of subsequent macros updated.
1595
15962022-10-06 Jakub Jelinek <jakub@redhat.com>
1597
1598 PR c++/106654
1599 * c-attribs.cc (handle_assume_attribute): New function.
1600 (c_common_attribute_table): Add entry for assume attribute.
1601 * c-lex.cc (c_common_has_attribute): Handle
1602 __have_cpp_attribute (assume).
1603
85872a69
GA
16042022-10-04 Jakub Jelinek <jakub@redhat.com>
1605
1606 * c-omp.cc (c_omp_directives): Uncomment begin declare target
1607 entry.
1608
69fd6dcc
GA
16092022-10-03 Patrick Palka <ppalka@redhat.com>
1610
1611 * c-common.cc (c_common_reswords): Use RID_IS_SAME instead of
1612 RID_IS_SAME_AS.
1613
16142022-10-03 Joseph Myers <joseph@codesourcery.com>
1615
1616 * c-cppbuiltin.cc (builtin_define_float_constants): Do not
1617 special-case __*_EPSILON__ setting for IBM long double for C2x.
1618
3a221b73
GA
16192022-09-30 Patrick Palka <ppalka@redhat.com>
1620
1621 * c-common.cc (c_common_reswords): Use cp/cp-trait.def to handle
1622 C++ traits.
1623 * c-common.h (enum rid): Likewise.
1624
bbdcdf5c
GA
16252022-09-29 Joseph Myers <joseph@codesourcery.com>
1626
1627 * c-lex.cc (c_common_has_attribute): Handle noreturn attribute for
1628 C.
1629
16302022-09-29 Patrick Palka <ppalka@redhat.com>
1631
1632 * c-common.cc (c_common_reswords): Add __remove_cv,
1633 __remove_reference and __remove_cvref.
1634 * c-common.h (enum rid): Add RID_REMOVE_CV, RID_REMOVE_REFERENCE
1635 and RID_REMOVE_CVREF.
1636
1f16a020
GA
16372022-09-27 Marek Polacek <polacek@redhat.com>
1638
1639 PR c++/101165
1640 PR c++/106882
1641 * c-cppbuiltin.cc (c_cpp_builtins): Define __cpp_implicit_move.
1642
16432022-09-27 Marek Polacek <polacek@redhat.com>
1644
1645 * c-format.cc (c_keywords): Drop nothrow.
1646
16472022-09-27 Jakub Jelinek <jakub@redhat.com>
1648
1649 PR c++/106651
1650 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
1651 __cpp_static_call_operator=202207L for C++23.
1652
16532022-09-27 Jakub Jelinek <jakub@redhat.com>
1654
1655 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ASSUME,
1656 PRAGMA_OMP_ASSUMES and PRAGMA_OMP_BEGIN. Rename
1657 PRAGMA_OMP_END_DECLARE_TARGET to PRAGMA_OMP_END.
1658 * c-pragma.cc (omp_pragmas): Add assumes and begin.
1659 For end rename PRAGMA_OMP_END_DECLARE_TARGET to PRAGMA_OMP_END.
1660 (omp_pragmas_simd): Add assume.
1661 * c-common.h (c_omp_directives): Declare.
1662 * c-omp.cc (omp_directives): Rename to ...
1663 (c_omp_directives): ... this. No longer static. Uncomment
1664 assume, assumes, begin assumes and end assumes entries.
1665 In end declare target entry rename PRAGMA_OMP_END_DECLARE_TARGET
1666 to PRAGMA_OMP_END.
1667 (c_omp_categorize_directive): Adjust for omp_directives to
1668 c_omp_directives renaming.
1669
16702022-09-27 Jakub Jelinek <jakub@redhat.com>
1671
1672 PR c++/106652
1673 PR c++/85518
1674 * c-common.cc (c_common_reswords): Change _Float{16,32,64,128} and
1675 _Float{32,64,128}x flags from D_CONLY to 0.
1676 (shorten_binary_op): Punt if common_type returns error_mark_node.
1677 (shorten_compare): Likewise.
1678 (c_common_nodes_and_builtins): For C++ record _Float{16,32,64,128}
1679 and _Float{32,64,128}x builtin types if available. For C++
1680 clear float128t_type_node.
1681 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
1682 __STDCPP_FLOAT{16,32,64,128}_T__ for C++23 if supported.
1683 * c-lex.cc (interpret_float): For q/Q suffixes prefer
1684 float128t_type_node over float128_type_node. Allow
1685 {f,F}{16,32,64,128} suffixes for C++ if supported with pedwarn
1686 for C++20 and older. Allow {f,F}{32,64,128}x suffixes for C++
1687 with pedwarn. Don't call excess_precision_type for C++.
1688
220c4d8e
GA
16892022-09-26 Marek Polacek <polacek@redhat.com>
1690
1691 PR c++/106656
1692 * c-cppbuiltin.cc (c_cpp_builtins): Update value of __cpp_char8_t
1693 for C++20.
1694
4afaeaab
GA
16952022-09-23 Marek Polacek <polacek@redhat.com>
1696
1697 PR c++/106784
1698 * c-common.cc (c_common_reswords): Add __is_convertible and
1699 __is_nothrow_convertible.
1700 * c-common.h (enum rid): Add RID_IS_CONVERTIBLE and
1701 RID_IS_NOTHROW_CONVERTIBLE.
1702
279c6715
GA
17032022-09-22 David Malcolm <dmalcolm@redhat.com>
1704
1705 PR c/106830
1706 * c-warn.cc (check_for_xor_used_as_pow): Don't try checking
1707 values that don't fit in uhwi.
1708
d0fc05e8
GA
17092022-09-15 Richard Biener <rguenther@suse.de>
1710
1711 * c-common.h (build_void_list_node): Remove.
1712 * c-common.cc (c_common_nodes_and_builtins): Do not initialize
1713 void_list_node.
1714
861d1a11
GA
17152022-09-09 Jan-Benedict Glaw <jbglaw@lug-owl.de>
1716
1717 * c-format.cc (convert_format_name_to_system_name): Fix warning.
1718
fe2a8ce9
GA
17192022-09-07 Joseph Myers <joseph@codesourcery.com>
1720
1721 * c-common.cc (c_common_reswords): Use D_C2X instead of D_CXXONLY
1722 for alignas, alignof, bool, false, static_assert, thread_local and
1723 true.
1724
17252022-09-07 Jakub Jelinek <jakub@redhat.com>
1726
1727 * c.opt (Winvalid-utf8): Use ObjC instead of objC. Remove
1728 " in comments" from description.
1729 (Wunicode): New option.
1730
25aeb922
GA
17312022-09-06 Jakub Jelinek <jakub@redhat.com>
1732
1733 PR c/106836
1734 * c-omp.cc (c_omp_split_clauses): Handle OMP_CLAUSE_DOACROSS.
1735
83f2f228
GA
17362022-09-03 Jakub Jelinek <jakub@redhat.com>
1737
1738 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DOACROSS.
1739 * c-omp.cc (c_finish_omp_depobj): Check also for OMP_CLAUSE_DOACROSS
1740 clause and diagnose it. Don't handle OMP_CLAUSE_DEPEND_SOURCE and
1741 OMP_CLAUSE_DEPEND_SINK. Assert kind is not OMP_CLAUSE_DEPEND_INVALID.
1742
c64b0947
GA
17432022-09-02 David Malcolm <dmalcolm@redhat.com>
1744
1745 PR c/90885
1746 * c-common.h (check_for_xor_used_as_pow): New decl.
1747 * c-lex.cc (c_lex_with_flags): Add DECIMAL_INT to flags as appropriate.
1748 * c-warn.cc (check_for_xor_used_as_pow): New.
1749 * c.opt (Wxor-used-as-pow): New.
1750
bb0a1556
GA
17512022-09-01 Jason Merrill <jason@redhat.com>
1752
1753 * c-common.cc (c_common_nodes_and_builtins): Set TREE_STRING_FLAG on
1754 char8_t.
1755 (braced_list_to_string): Check for char-sized elements.
1756
17572022-09-01 Jakub Jelinek <jakub@redhat.com>
1758
1759 PR c++/106655
1760 * c.opt (-Winvalid-utf8): New warning.
1761 * c-opts.cc (c_common_handle_option) <case OPT_finput_charset_>:
1762 Set cpp_opts->cpp_input_charset_explicit.
1763 (c_common_post_options): If -finput-charset=UTF-8 is explicit
1764 in C++23, enable -Winvalid-utf8 by default and if -pedantic
1765 or -pedantic-errors, make it a pedwarn.
1766
542c60c4
GA
17672022-08-31 Joseph Myers <joseph@codesourcery.com>
1768
1769 * c-attribs.cc (handle_deprecated_attribute): Check and pedwarn
1770 for LABEL_DECL.
1771 * c-common.cc (c_add_case_label): Add argument ATTRS. Call
1772 decl_attributes.
1773 * c-common.h (do_case, c_add_case_label): Update declarations.
1774 * c-lex.cc (c_common_has_attribute): For C, produce a result of
1775 201910 for fallthrough and 202106 for maybe_unused.
1776
16f542d6
GA
17772022-08-26 Marek Polacek <polacek@redhat.com>
1778
1779 PR c++/81159
1780 * c.opt (Wself-move): New option.
1781
17822022-08-26 Jakub Jelinek <jakub@redhat.com>
1783
1784 * c-common.cc (check_builtin_function_arguments): Handle
1785 BUILT_IN_ISSIGNALING.
1786
17872022-08-26 Jakub Jelinek <jakub@redhat.com>
1788
1789 PR c++/106648
1790 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
1791 __cpp_named_character_escapes to 202207L.
1792
5d4389dc
GA
17932022-08-25 Marek Polacek <polacek@redhat.com>
1794
1795 * c-common.cc (c_common_reswords): Enable nullptr in C2X.
1796 (c_common_nodes_and_builtins): Create the built-in node for nullptr.
1797 * c-common.h (enum c_tree_index): Add CTI_NULLPTR, CTI_NULLPTR_TYPE.
1798 (struct c_common_resword): Resize the disable member.
1799 (D_C2X): Add.
1800 (nullptr_node): Define.
1801 (nullptr_type_node): Define.
1802 (NULLPTR_TYPE_P): Define.
1803 * c-pretty-print.cc (c_pretty_printer::simple_type_specifier): Handle
1804 NULLPTR_TYPE.
1805 (c_pretty_printer::direct_abstract_declarator): Likewise.
1806 (c_pretty_printer::constant): Likewise.
1807
47a61e65
GA
18082022-08-16 Tom Honermann <tom@honermann.net>
1809
1810 PR c++/106423
1811 * c-opts.cc (c_common_post_options): Disable -Wc++20-compat
1812 diagnostics in C++20 and later.
1813 * c.opt (Wc++20-compat): Enable hooks for the preprocessor.
1814
5cd525f0
GA
18152022-08-11 Marek Polacek <polacek@redhat.com>
1816
1817 PR middle-end/102633
1818 * c-gimplify.cc (c_gimplify_expr) <case DECL_EXPR>: Don't call
1819 suppress_warning here.
1820
5f17badb
GA
18212022-08-08 Tom Honermann <tom@honermann.net>
1822
1823 PR preprocessor/106426
1824 * c-opts.cc (c_common_post_options): Assign cpp_opts->unsigned_utf8char
1825 subject to -fchar8_t, -fsigned-char, and/or -funsigned-char.
1826
18272022-08-08 Tom Honermann <tom@honermann.net>
1828
1829 * c-lex.cc (lex_string, lex_charconst): Use char8_t as the type
1830 of CPP_UTF8CHAR and CPP_UTF8STRING when char8_t support is
1831 enabled.
1832 * c-opts.cc (c_common_post_options): Set flag_char8_t if
1833 targeting C2x.
1834
4a7274dd
GA
18352022-07-31 Lewis Hyatt <lhyatt@gmail.com>
1836
1837 PR c++/66290
1838 * c-common.h: Rename global done_lexing to
1839 override_libcpp_locations.
1840 * c-common.cc (c_cpp_diagnostic): Likewise.
1841 * c-opts.cc (c_common_finish): Set override_libcpp_locations
1842 (formerly done_lexing) immediately prior to calling cpp_finish ().
1843
1e2c5f4c
GA
18442022-07-27 Lewis Hyatt <lhyatt@gmail.com>
1845
1846 * c-ppoutput.cc (token_streamer::stream): Update input_location
1847 prior to streaming each token.
1848
0e6fa997
GA
18492022-07-23 Immad Mir <mirimmad@outlook.com>
1850
1851 * c-attribs.cc: (c_common_attribute_table): add three new attributes
1852 namely: fd_arg, fd_arg_read and fd_arg_write.
1853 (handle_fd_arg_attribute): New.
1854
bdc7b765
GA
18552022-07-15 Marek Polacek <polacek@redhat.com>
1856
1857 PR c++/104477
1858 * c-common.cc (c_common_reswords): Add
1859 __reference_constructs_from_temporary and
1860 __reference_converts_from_temporary.
1861 * c-common.h (enum rid): Add RID_REF_CONSTRUCTS_FROM_TEMPORARY and
1862 RID_REF_CONVERTS_FROM_TEMPORARY.
1863
18642022-07-15 Jonathan Wakely <jwakely@redhat.com>
1865
1866 * c-format.cc (class range_label_for_format_type_mismatch):
1867 Adjust to new label_text API.
1868
c72d4714
GA
18692022-07-11 Lewis Hyatt <lhyatt@gmail.com>
1870
1871 PR preprocessor/106252
1872 * c-pragma.cc (handle_pragma_diagnostic_impl): Don't look up the
1873 option argument prior to verifying the option was found.
1874
6345c414
GA
18752022-07-07 David Malcolm <dmalcolm@redhat.com>
1876
1877 * c-format.cc (range_label_for_format_type_mismatch::get_text):
1878 Update for removal of label_text::maybe_free in favor of automatic
1879 memory management.
1880
4bc92c3b
GA
18812022-07-06 Lewis Hyatt <lhyatt@gmail.com>
1882
1883 PR preprocessor/53920
1884 PR c++/53431
1885 * c-common.cc (c_option_is_from_cpp_diagnostics): New function.
1886 * c-common.h (c_option_is_from_cpp_diagnostics): Declare.
1887 (c_pp_stream_token): Declare.
1888 * c-ppoutput.cc (init_pp_output): Refactor logic about skipping
1889 pragmas to...
1890 (should_output_pragmas): ...here. New function.
1891 (token_streamer::stream): Support handling early pragmas.
1892 (do_line_change): Likewise.
1893 (c_pp_stream_token): New function.
1894 * c-pragma.cc (struct pragma_diagnostic_data): New helper class.
1895 (pragma_diagnostic_lex_normal): New function. Moved logic for
1896 interpreting GCC diagnostic pragmas here.
1897 (pragma_diagnostic_lex_pp): New function for parsing diagnostic pragmas
1898 directly from libcpp.
1899 (handle_pragma_diagnostic): Refactor into helper function...
1900 (handle_pragma_diagnostic_impl): ...here. New function.
1901 (handle_pragma_diagnostic_early): New function.
1902 (handle_pragma_diagnostic_early_pp): New function.
1903 (struct pragma_ns_name): Renamed to...
1904 (struct pragma_pp_data): ...this. Add new "early_handler" member.
1905 (c_register_pragma_1): Support early pragmas in the preprocessor.
1906 (c_register_pragma_with_early_handler): New function.
1907 (c_register_pragma): Support the new early handlers in struct
1908 internal_pragma_handler.
1909 (c_register_pragma_with_data): Likewise.
1910 (c_register_pragma_with_expansion): Likewise.
1911 (c_register_pragma_with_expansion_and_data): Likewise.
1912 (c_invoke_early_pragma_handler): New function.
1913 (c_pp_invoke_early_pragma_handler): New function.
1914 (init_pragma): Add early pragma support for diagnostic pragmas.
1915 * c-pragma.h (struct internal_pragma_handler): Add new early handler
1916 members.
1917 (c_register_pragma_with_early_handler): Declare.
1918 (c_invoke_early_pragma_handler): Declare.
1919 (c_pp_invoke_early_pragma_handler): Declare.
1920
d1f3a3ff
GA
19212022-07-05 Marek Polacek <polacek@redhat.com>
1922
1923 PR c++/105626
1924 * c-format.cc (check_format_arg): Don't emit -Wformat warnings with
1925 u8 strings.
1926
ed974488
GA
19272022-07-01 Marek Polacek <polacek@redhat.com>
1928
1929 PR c++/106111
1930 * c-common.h (enum rid): Update RID_LAST_CXX20.
1931
976196b3
GA
19322022-06-30 Jonathan Wakely <jwakely@redhat.com>
1933
1934 * known-headers.cc (get_stdlib_header_for_name): Add <time.h>
1935 names.
1936
84c2131d
GA
19372022-06-24 Jason Merrill <jason@redhat.com>
1938
1939 PR c++/87729
1940 PR c++/20423
1941 * c.opt (Woverloaded-virtual): Add levels, include in -Wall.
1942
4390e7bf
GA
19432022-06-18 Jakub Jelinek <jakub@redhat.com>
1944
1945 * c-ubsan.cc (ubsan_instrument_division, ubsan_instrument_shift):
1946 Use flag_sanitize_trap & SANITIZE_??? instead of
1947 flag_sanitize_undefined_trap_on_error. If 2 sanitizers are involved
1948 and flag_sanitize_trap differs for them, emit __builtin_trap only
1949 for the comparison where trap is requested.
1950 (ubsan_instrument_vla, ubsan_instrument_return): Use
1951 lag_sanitize_trap & SANITIZE_??? instead of
1952 flag_sanitize_undefined_trap_on_error.
1953
c3642271
GA
19542022-06-13 Jason Merrill <jason@redhat.com>
1955
1956 * c-ubsan.cc (ubsan_instrument_return): Use BUILTINS_LOCATION.
1957
d9176e64
GA
19582022-05-27 Marek Polacek <polacek@redhat.com>
1959
1960 PR c/90658
1961 * c-attribs.cc (get_priority): Check FUNCTION_DECL.
1962
19632022-05-27 Jakub Jelinek <jakub@redhat.com>
1964
1965 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ENTER.
1966
57f2ce6a
GA
19672022-05-20 David Malcolm <dmalcolm@redhat.com>
1968
1969 * c-format.cc: Replace uses of "FINAL" and "OVERRIDE" with "final"
1970 and "override".
1971 * c-pretty-print.h: Likewise.
1972
1cda629f
GA
19732022-05-18 Marek Polacek <polacek@redhat.com>
1974
1975 PR c/105131
1976 * c.opt (Wenum-int-mismatch): New.
1977
19782022-05-18 Marek Polacek <polacek@redhat.com>
1979
1980 PR c++/105497
1981 * c-warn.cc (c_do_switch_warnings): Don't warn about unhandled
1982 enumerator when it was marked with attribute unused.
1983
19842022-05-18 Eric Botcazou <ebotcazou@adacore.com>
1985
1986 * c-ada-spec.cc (dump_ada_node) <COMPLEX_TYPE>: Deal with usual
1987 floating-point complex types.
1988 <POINTER_TYPE>: Do not use limited_with clause if the designated
1989 type is a scalar type.
1990
3d9439b1
GA
19912022-05-17 Jakub Jelinek <jakub@redhat.com>
1992
1993 * c-omp.cc (c_finish_omp_depobj): Handle
1994 OMP_CLAUSE_DEPEND_INOUTSET.
1995
702bd11f
GA
19962022-05-16 Jason Merrill <jason@redhat.com>
1997
1998 PR c/105492
1999 * c-attribs.cc (handle_mode_attribute): Don't fix broken typedefs
2000 here.
2001
20022022-05-16 Martin Liska <mliska@suse.cz>
2003
2004 * c-common.cc (ARRAY_SIZE): Use ARRAY_SIZE.
2005 (c_common_nodes_and_builtins): Likewise.
2006 * c-format.cc (check_tokens): Likewise.
2007 (check_plain): Likewise.
2008 * c-pragma.cc (c_pp_lookup_pragma): Likewise.
2009 (init_pragma): Likewise.
2010 * known-headers.cc (get_string_macro_hint): Likewise.
2011 (get_stdlib_header_for_name): Likewise.
2012 * c-attribs.cc: Likewise.
2013
9df4ffe4
GA
20142022-05-13 Richard Biener <rguenther@suse.de>
2015
2016 * c-omp.cc: Remove gimple-fold.h include.
2017
49ace834
GA
20182022-05-12 Jakub Jelinek <jakub@redhat.com>
2019
2020 * c-common.h (enum rid): Add RID_OMP_ALL_MEMORY.
2021 * c-omp.cc (c_finish_omp_depobj): Don't build_fold_addr_expr
2022 if null_pointer_node.
2023
d0d513b5
GA
20242022-05-11 Martin Liska <mliska@suse.cz>
2025
2026 PR target/105355
2027 * c-opts.cc (c_common_handle_option): Change option name.
2028 * c.opt: Remove Joined and use Separate option.
2029
bd022ff9
GA
20302022-05-09 Alex Coplan <alex.coplan@arm.com>
2031
2032 * c-common.h (get_dump_info): Delete.
2033 * c-gimplify.cc (c_genericize): Get TDI_original dump file info
2034 from the global dump_manager instead of the (now obsolete)
2035 get_dump_info.
2036 * c-opts.cc (original_dump_file): Delete.
2037 (original_dump_flags): Delete.
2038 (c_common_parse_file): Switch to using global dump_manager to
2039 manage the original dump file; fix leak of dump file.
2040 (get_dump_info): Delete.
2041
a1947c92
GA
20422022-05-07 Marek Polacek <polacek@redhat.com>
2043
2044 PR c++/101833
2045 PR c++/47634
2046 * c-attribs.cc (positional_argument): Pass POS by reference. Deal
2047 with FN being either a function declaration or function type. Use
2048 maybe_adjust_arg_pos_for_attribute.
2049 * c-common.cc (check_function_arguments): Maybe pass FNDECL down to
2050 check_function_format.
2051 * c-common.h (maybe_adjust_arg_pos_for_attribute): Declare.
2052 (positional_argument): Adjust.
2053 * c-format.cc (get_constant): Rename to ...
2054 (validate_constant): ... this. Take EXPR by reference. Return bool
2055 instead of tree.
2056 (handle_format_arg_attribute): Don't overwrite FORMAT_NUM_EXPR by the
2057 return value of validate_constant.
2058 (decode_format_attr): Don't overwrite FORMAT_NUM_EXPR and
2059 FIRST_ARG_NUM_EXPR by the return value of validate_constant.
2060 (check_function_format): Adjust a parameter name.
2061 (handle_format_attribute): Maybe pass FNDECL down to decode_format_attr.
2062
3e7db517
GA
20632022-05-04 Marek Polacek <polacek@redhat.com>
2064
2065 * c-warn.cc (warnings_for_convert_and_check): Convert constants of type
2066 char to int.
2067
95874f95
GA
20682022-04-30 Jason Merrill <jason@redhat.com>
2069
2070 PR c/100545
2071 * c-attribs.cc (handle_mode_attribute): Copy attributes, aligned,
2072 and typedef.
2073 * c-common.cc (set_underlying_type): Add assert.
2074
01ad093b
GA
20752022-04-26 Patrick Palka <ppalka@redhat.com>
2076
2077 PR c++/105304
2078 * c-common.cc (verify_tree) [restart]: Move up to before the
2079 NULL test.
2080
da066c42
GA
20812022-04-11 Jakub Jelinek <jakub@redhat.com>
2082
2083 PR c++/105186
2084 * c-common.cc (c_common_nodes_and_builtins): After registering __int%d
2085 and __int%d__ builtin types, initialize corresponding ridpointers
2086 entry.
2087
150ab50f
GA
20882022-03-30 Marek Polacek <polacek@redhat.com>
2089
2090 PR c++/101030
2091 * c-warn.cc (conversion_warning) <case COND_EXPR>: Don't call
2092 conversion_warning when OP1 is null.
2093
20942022-03-30 Thomas Schwinge <thomas@codesourcery.com>
2095
2096 * c.opt (Wc++11-extensions, Wc++14-extensions, Wc++17-extensions)
2097 (Wc++20-extensions, Wc++23-extensions): Remove 'LangEnabledBy'
2098 option properties.
2099
21002022-03-30 Thomas Schwinge <thomas@codesourcery.com>
2101
2102 * c.opt (Wuse-after-free): Remove.
2103
21042022-03-30 Thomas Schwinge <thomas@codesourcery.com>
2105
2106 * c.opt (Warray-bounds): Remove.
2107
d2906412
GA
21082022-03-26 Thomas Schwinge <thomas@codesourcery.com>
2109
2110 * c.opt: Properly quote comment.
2111
31e989a2
GA
21122022-03-25 Eric Botcazou <ebotcazou@adacore.com>
2113
2114 * c-ada-spec.cc (dump_ada_import): Deal with the "section" attribute
2115 (dump_ada_node) <POINTER_TYPE>: Do not modify and pass the name, but
2116 the referenced type instead. Deal with the anonymous original type
2117 of a typedef'ed type. In the actual access case, follow the chain
2118 of external subtypes.
2119 <TYPE_DECL>: Tidy up control flow.
2120
d156bb87
GA
21212022-03-21 Qian Jianhua <qianjh@cn.fujitsu.com>
2122
2123 * c-ada-spec.cc: Change array length
2124
d7f00da1
GA
21252022-03-19 Arthur Cohen <arthur.cohen@embecosm.com>
2126
2127 * c-common.cc (c_family_tests): Call the new tests.
2128 * c-common.h (c_diagnostic_tests): Declare.
2129 (c_opt_problem_cc_tests): Likewise.
2130
21312022-03-19 Jakub Jelinek <jakub@redhat.com>
2132
2133 PR c++/101515
2134 * c-pretty-print.cc (c_fold_indirect_ref_for_warn): For C++ don't
2135 return COMPONENT_REFs with FIELD_DECLs whose containing scope can't
2136 be printed.
2137
9fc8f278
GA
21382022-03-16 Christophe Lyon <christophe.lyon@arm.com>
2139 Roger Sayle <roger@nextmovesoftware.com>
2140
2141 PR c/98198
2142 * c-attribs.cc (decl_or_type_attrs): Add error_mark_node check.
2143
21442022-03-16 Patrick Palka <ppalka@redhat.com>
2145
2146 PR c++/96780
2147 * c.opt: Add -ffold-simple-inlines.
2148
b9756c08
GA
21492022-03-13 Tobias Burnus <tobias@codesourcery.com>
2150
2151 * c-target.def (check_string_object_format_arg): Fix description typo.
2152
57eeedda
GA
21532022-03-12 Thomas Schwinge <thomas@codesourcery.com>
2154
2155 PR other/65095
2156 * c-common.h (c_omp_map_clause_name): Remove.
2157 * c-omp.cc (c_omp_map_clause_name): Remove.
2158
8cc4f9cd
GA
21592022-03-09 Jakub Jelinek <jakub@redhat.com>
2160
2161 PR c/104711
2162 * c-opts.cc (c_common_post_options): Don't enable
2163 -Wshift-negative-value from -Wextra for C++20 or later.
2164 * c-ubsan.cc (ubsan_instrument_shift): Adjust comments.
2165 * c-warn.cc (maybe_warn_shift_overflow): Use TYPE_OVERFLOW_WRAPS
2166 instead of TYPE_UNSIGNED.
2167
e6533e2e
GA
21682022-03-07 Jakub Jelinek <jakub@redhat.com>
2169
2170 * c-attribs.cc: Fix up duplicated word issue in a comment.
2171
12d4552e
GA
21722022-03-01 Martin Liska <mliska@suse.cz>
2173
2174 PR ipa/104533
2175 * c-attribs.cc (handle_target_clones_attribute): Use
2176 get_target_clone_attr_len and report warning soon.
2177
0bdb0498
GA
21782022-02-17 Jonathan Wakely <jwakely@redhat.com>
2179
2180 * c-pragma.cc (handle_pragma_pack): Remove parameter name.
2181 (handle_pragma_weak): Likewise.
2182 (handle_pragma_scalar_storage_order): Likewise.
2183 (handle_pragma_redefine_extname): Likewise.
2184 (handle_pragma_visibility): Likewise.
2185 (handle_pragma_diagnostic): Likewise.
2186 (handle_pragma_target): Likewise.
2187 (handle_pragma_optimize): Likewise.
2188 (handle_pragma_push_options): Likewise.
2189 (handle_pragma_pop_options): Likewise.
2190 (handle_pragma_reset_options): Likewise.
2191 (handle_pragma_message): Likewise.
2192 (handle_pragma_float_const_decimal64): Likewise.
2193
cb3afcd2
GA
21942022-02-16 Jakub Jelinek <jakub@redhat.com>
2195
2196 PR c/104531
2197 * c-omp.cc (c_finish_omp_atomic): For MIN_EXPR/MAX_EXPR, try first
2198 build_binary_op with LT_EXPR and only if that doesn't return
2199 error_mark_node call build_modify_expr.
2200
22012022-02-16 Jakub Jelinek <jakub@redhat.com>
2202
2203 PR c/104510
2204 * c-common.cc (shorten_compare): Convert original arguments to
2205 the original *restype_ptr when mixing binary and decimal float.
2206
1f8a09d2
GA
22072022-02-14 Richard Biener <rguenther@suse.de>
2208
2209 PR c/104505
2210 * c-pretty-print.cc (c_pretty_printer::postfix_expression): Handle
2211 internal function calls.
2212
e8d68f0a
GA
22132022-02-11 Richard Biener <rguenther@suse.de>
2214
2215 * c-attribs.cc (c_common_attribute_table): Add entry for
2216 vector_mask.
2217 (handle_vector_mask_attribute): New.
2218
a645583d
GA
22192022-02-10 Marcel Vollweiler <marcel@codesourcery.com>
2220
2221 * c-omp.cc (c_omp_split_clauses): Added OMP_CLAUSE_HAS_DEVICE_ADDR case.
2222 * c-pragma.h (enum pragma_kind): Added 5.1 in comment.
2223 (enum pragma_omp_clause): Added PRAGMA_OMP_CLAUSE_HAS_DEVICE_ADDR.
2224
3adf509f
GA
22252022-02-09 Jason Merrill <jason@redhat.com>
2226
2227 * c-cppbuiltin.cc (c_cpp_builtins): Update values
2228 of __cpp_constexpr and __cpp_concepts for C++20.
2229
bb99171b
GA
22302022-01-24 Marek Polacek <polacek@redhat.com>
2231
2232 PR preprocessor/104030
2233 * c.opt (Wbidi-chars): Mark as EnumSet. Also accept =ucn.
2234
9dd44357
GA
22352022-01-21 Jakub Jelinek <jakub@redhat.com>
2236
2237 PR c++/104148
2238 * c-common.h (check_function_arguments_recurse): Add for_format
2239 arg.
2240 * c-common.cc (check_function_nonnull): Pass false to
2241 check_function_arguments_recurse's last argument.
2242 (check_function_arguments_recurse): Add for_format argument,
2243 if true, don't stop on warning_suppressed_p.
2244 * c-format.cc (check_format_info): Pass true to
2245 check_function_arguments_recurse's last argument.
2246
fe1ad141
GA
22472022-01-19 David Malcolm <dmalcolm@redhat.com>
2248
2249 * c-common.cc (c_common_c_tests): Rename to...
2250 (c_common_cc_tests): ...this.
2251 (c_family_tests): Update calls for .c to .cc renaming.
2252 * c-common.h (c_format_c_tests): Rename to...
2253 (c_format_cc_tests): ...this.
2254 (c_indentation_c_tests): Rename to...
2255 (c_indentation_cc_tests): ...this.
2256 (c_pretty_print_c_tests): Rename to...
2257 (c_pretty_print_cc_tests): ...this.
2258 * c-format.cc (c_format_c_tests): Rename to...
2259 (c_format_cc_tests): ...this.
2260 * c-indentation.cc (c_indentation_c_tests): Rename to...
2261 (c_indentation_cc_tests): ...this.
2262 * c-pretty-print.cc (c_pretty_print_c_tests): Rename to...
2263 (c_pretty_print_cc_tests): ...this.
2264
fc829782
GA
22652022-01-17 Martin Liska <mliska@suse.cz>
2266
2267 * c-ada-spec.cc: Rename .c names to .cc.
2268 * c-ada-spec.h: Likewise.
2269 * c-common.cc (c_build_vec_convert): Likewise.
2270 (warning_candidate_p): Likewise.
2271 * c-common.h (enum rid): Likewise.
2272 (build_real_imag_expr): Likewise.
2273 (finish_label_address_expr): Likewise.
2274 (c_get_substring_location): Likewise.
2275 (c_build_bind_expr): Likewise.
2276 (conflict_marker_get_final_tok_kind): Likewise.
2277 (c_parse_error): Likewise.
2278 (check_missing_format_attribute): Likewise.
2279 (invalid_array_size_error): Likewise.
2280 (warn_for_multistatement_macros): Likewise.
2281 (build_attr_access_from_parms): Likewise.
2282 * c-cppbuiltin.cc (c_cpp_builtins): Likewise.
2283 * c-format.cc: Likewise.
2284 * c-gimplify.cc (c_gimplify_expr): Likewise.
2285 * c-indentation.h: Likewise.
2286 * c-objc.h (objc_prop_attr_kind_for_rid): Likewise.
2287 * c-omp.cc (c_omp_predetermined_mapping): Likewise.
2288 * c-opts.cc (c_common_post_options): Likewise.
2289 (set_std_cxx23): Likewise.
2290 * c-pragma.cc (handle_pragma_redefine_extname): Likewise.
2291 * c-pretty-print.h: Likewise.
2292
22932022-01-17 Martin Liska <mliska@suse.cz>
2294
2295 * c-ada-spec.c: Moved to...
2296 * c-ada-spec.cc: ...here.
2297 * c-attribs.c: Moved to...
2298 * c-attribs.cc: ...here.
2299 * c-common.c: Moved to...
2300 * c-common.cc: ...here.
2301 * c-cppbuiltin.c: Moved to...
2302 * c-cppbuiltin.cc: ...here.
2303 * c-dump.c: Moved to...
2304 * c-dump.cc: ...here.
2305 * c-format.c: Moved to...
2306 * c-format.cc: ...here.
2307 * c-gimplify.c: Moved to...
2308 * c-gimplify.cc: ...here.
2309 * c-indentation.c: Moved to...
2310 * c-indentation.cc: ...here.
2311 * c-lex.c: Moved to...
2312 * c-lex.cc: ...here.
2313 * c-omp.c: Moved to...
2314 * c-omp.cc: ...here.
2315 * c-opts.c: Moved to...
2316 * c-opts.cc: ...here.
2317 * c-pch.c: Moved to...
2318 * c-pch.cc: ...here.
2319 * c-ppoutput.c: Moved to...
2320 * c-ppoutput.cc: ...here.
2321 * c-pragma.c: Moved to...
2322 * c-pragma.cc: ...here.
2323 * c-pretty-print.c: Moved to...
2324 * c-pretty-print.cc: ...here.
2325 * c-semantics.c: Moved to...
2326 * c-semantics.cc: ...here.
2327 * c-ubsan.c: Moved to...
2328 * c-ubsan.cc: ...here.
2329 * c-warn.c: Moved to...
2330 * c-warn.cc: ...here.
2331 * cppspec.c: Moved to...
2332 * cppspec.cc: ...here.
2333 * stub-objc.c: Moved to...
2334 * stub-objc.cc: ...here.
2335
9248ee41
GA
23362022-01-15 Martin Sebor <msebor@redhat.com>
2337
2338 PR c/63272
2339 * c.opt (-Wdangling-pointer): New option.
2340
23412022-01-15 Martin Sebor <msebor@redhat.com>
2342
2343 PR tree-optimization/80532
2344 * c.opt (-Wuse-after-free): New options.
2345
617db51d
GA
23462022-01-14 David Malcolm <dmalcolm@redhat.com>
2347
2348 * c-attribs.c (c_common_attribute_table): Add "tainted_args".
2349 (handle_tainted_args_attribute): New.
2350
ad3f0d08
GA
23512022-01-13 Anthony Sharp <anthonysharp15@gmail.com>
2352 Jason Merrill <jason@redhat.com>
2353
2354 PR c++/70417
2355 * c.opt: Added -Wmissing-template-keyword.
2356
23572022-01-13 Richard Biener <rguenther@suse.de>
2358
2359 PR c/104002
2360 * c-common.c (c_common_mark_addressable_vec): Handle TARGET_EXPR.
2361
02a8a01b
GA
23622022-01-12 Martin Liska <mliska@suse.cz>
2363
2364 PR target/103804
2365 * c-attribs.c (handle_optimize_attribute): Do not call
2366 cl_optimization_compare if we seen an error.
2367
01a254e3
GA
23682022-01-11 Jakub Jelinek <jakub@redhat.com>
2369
2370 PR c/101537
2371 PR c/103881
2372 * c-warn.c (conversion_warning): Handle BIT_AND_EXPR, BIT_IOR_EXPR
2373 and BIT_XOR_EXPR.
2374
d9450aa0
GA
23752022-01-10 Richard Biener <rguenther@suse.de>
2376
2377 PR middle-end/101530
2378 * c-common.c (c_build_shufflevector): Wrap the BIT_FIELD_REF
2379 in a TARGET_EXPR to force a temporary.
2380
11ce8d04
GA
23812022-01-06 Marek Polacek <polacek@redhat.com>
2382
2383 PR c++/103758
2384 * c-pragma.c (handle_pragma_scalar_storage_order): Use %< %> in
2385 diagnostic messages.
2386 (handle_pragma_diagnostic): Likewise.
2387
a4ae8c37
GA
23882022-01-03 Marek Polacek <polacek@redhat.com>
2389
2390 PR c++/103758
2391 * c-format.c (check_tokens): Accept "decl-specifier*".
2392
23932022-01-03 Jakub Jelinek <jakub@redhat.com>
2394
2395 PR c++/103600
2396 * c-attribs.c (handle_non_overlapping_attribute): New function.
2397 (c_common_attribute_table): Add "non overlapping" attribute.
2398
84790a9d
GA
23992021-12-30 Jakub Jelinek <jakub@redhat.com>
2400
2401 PR c++/103012
2402 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Perform
2403 cpp_define_unused/cpp_undef calls with forced token locations
2404 BUILTINS_LOCATION.
2405
d1e111da
GA
24062021-12-27 Patrick Palka <ppalka@redhat.com>
2407
2408 PR c++/103700
2409 * c-common.c (pointer_int_sum): When quiet, return
2410 error_mark_node for an incomplete pointed-to type and don't
2411 call size_in_bytes_loc.
2412
2554e2da
GA
24132021-12-17 Jason Merrill <jason@redhat.com>
2414
2415 PR c++/103681
2416 * c-opts.c (c_common_post_options): Update defaults.
2417
774269aa
GA
24182021-12-16 Martin Liska <mliska@suse.cz>
2419
2420 PR target/103709
2421 * c-pragma.c (handle_pragma_pop_options): Do not check
2422 global options modification when an error is seen in parsing
2423 of options (pragmas or attributes).
2424
c8dcf64b
GA
24252021-12-12 Jonathan Wakely <jwakely@redhat.com>
2426
2427 * known-headers.cc: Define INCLUDE_MEMORY instead of
2428 INCLUDE_UNIQUE_PTR.
2429 * name-hint.h: Likewise.
2430 (class name_hint): Use std::unique_ptr instead of gnu::unique_ptr.
2431
4b4839e3
GA
24322021-12-09 Jakub Jelinek <jakub@redhat.com>
2433
2434 PR pch/71934
2435 * c-pch.c (c_common_no_more_pch): Pass a temporary void * var
2436 with NULL value instead of NULL to host_hooks.gt_pch_use_address.
2437
03a9bd05
GA
24382021-12-03 Jakub Jelinek <jakub@redhat.com>
2439
2440 PR pch/71934
2441 * c-pch.c (struct c_pch_validity): Remove pch_init member.
2442 (pch_init): Don't initialize v.pch_init.
2443 (c_common_valid_pch): Don't warn and punt if .text addresses change.
2444
40fa651e
GA
24452021-12-01 Jason Merrill <jason@redhat.com>
2446
2447 PR c++/103310
2448 * c.opt: Add -fconstexpr-fp-except.
2449
87cd82c8
GA
24502021-11-29 Richard Biener <rguenther@suse.de>
2451
2452 * c-format.c (check_format_string): Remove spurious
2453 gcc_unreachable.
2454
24552021-11-29 Richard Biener <rguenther@suse.de>
2456
2457 * c-opts.c (c_common_post_options): Remove unreachable return.
2458 * c-pragma.c (handle_pragma_target): Likewise.
2459 (handle_pragma_optimize): Likewise.
2460
091ccc06
GA
24612021-11-25 Jakub Jelinek <jakub@redhat.com>
2462
2463 PR c++/102611
2464 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
2465 default for C++23 regardless of warn_deprecated.
2466 * c-cppbuiltin.c (c_cpp_builtins): Predefine
2467 __cpp_multidimensional_subscript=202110L for C++23.
2468
e1d43592
GA
24692021-11-23 Martin Sebor <msebor@redhat.com>
2470
2471 PR middle-end/88232
2472 * c.opt: Add -Winfinite-recursion.
2473
9c077398
GA
24742021-11-19 Martin Sebor <msebor@redhat.com>
2475
2476 PR c++/33925
2477 PR c/102867
2478 * c-common.c (decl_with_nonnull_addr_p): Call maybe_nonzero_address
2479 and improve handling tof defined symbols.
2480
24812021-11-19 Martin Liska <mliska@suse.cz>
2482
2483 Revert:
2484 2021-11-18 Martin Liska <mliska@suse.cz>
2485
2486 * c-gimplify.c (genericize_c_loop): Use option directly.
2487
483092d3
GA
24882021-11-18 Matthias Kretz <m.kretz@gsi.de>
2489
2490 * c-common.c (c_common_reswords): Add __builtin_assoc_barrier.
2491 * c-common.h (enum rid): Add RID_BUILTIN_ASSOC_BARRIER.
2492
24932021-11-18 Martin Liska <mliska@suse.cz>
2494
2495 * c-gimplify.c (genericize_c_loop): Use option directly.
2496
280d2838
GA
24972021-11-17 Martin Uecker <uecker@gcc.gnu.org>
2498
2499 PR c/91038
2500 PR c/29970
2501 * c-common.c (pointer_int_sum): Make sure pointer expressions
2502 are evaluated first when the size expression depends on for
2503 variably-modified types.
2504
25052021-11-17 Marek Polacek <polacek@redhat.com>
2506
2507 PR preprocessor/103026
2508 * c.opt (Wbidi-chars, Wbidi-chars=): New option.
2509
6b1695f4
GA
25102021-11-16 Jason Merrill <jason@redhat.com>
2511
2512 * c-common.c (release_tree_vector): Only cache vecs smaller than
2513 16 elements.
2514
e2b57363
GA
25152021-11-15 Jason Merrill <jason@redhat.com>
2516
2517 * c.opt: Add -fimplicit-constexpr.
2518 * c-cppbuiltin.c: Define __cpp_implicit_constexpr.
2519 * c-opts.c (c_common_post_options): Disable below C++14.
2520
25212021-11-15 Jakub Jelinek <jakub@redhat.com>
2522
2523 * c-omp.c (c_omp_split_clauses) <case OMP_CLAUSE_THREAD_LIMIT>:
2524 Duplicate to both OMP_TARGET and OMP_TEAMS.
2525
8d36a0d2
GA
25262021-11-10 Marek Polacek <polacek@redhat.com>
2527
2528 PR c++/101940
2529 * c-pragma.c (handle_pragma_diagnostic): Handle #pragma GCC diagnostic
2530 ignored_attributes.
2531
c9b1334e
GA
25322021-11-09 David Malcolm <dmalcolm@redhat.com>
2533
2534 * c-pragma.c (GCC_BAD_AT): New macro.
2535 (GCC_BAD2_AT): New macro.
2536 (handle_pragma_pack): Use the location of the pertinent token when
2537 issuing diagnostics about invalid constants/actions, and trailing
2538 junk.
2539 (handle_pragma_target): Likewise for non-string "GCC option".
2540 (handle_pragma_message): Likewise for trailing junk.
2541
18ae471f
GA
25422021-11-03 Joseph Myers <joseph@codesourcery.com>
2543
2544 PR c/103031
2545 * c-common.c (convert_and_check): Add argument init_const. Call
2546 convert_init if init_const.
2547 * c-common.h (convert_and_check): Update prototype.
2548 (convert_init): New prototype.
2549
cf82e8d9
GA
25502021-11-01 David Malcolm <dmalcolm@redhat.com>
2551
2552 * c-lex.c (c_lex_with_flags): When complaining about non-printable
2553 CPP_OTHER tokens, set the "escape on output" flag.
2554
04a2cf3f
GA
25552021-10-27 Jakub Jelinek <jakub@redhat.com>
2556
2557 * c-omp.c (c_omp_check_loop_iv_r): Don't clear 3rd bit for
2558 POINTER_PLUS_EXPR.
2559 (c_omp_check_nonrect_loop_iv): Handle POINTER_PLUS_EXPR.
2560 (c_omp_check_loop_iv): Set kind even if the iterator is non-integral.
2561
25622021-10-27 Jakub Jelinek <jakub@redhat.com>
2563
2564 PR c++/102854
2565 * c-common.h (c_omp_check_loop_iv_exprs): Add enum tree_code argument.
2566 * c-omp.c (c_omp_check_loop_iv_r): For trees other than decls,
2567 TREE_VEC, PLUS_EXPR, MINUS_EXPR, MULT_EXPR, POINTER_PLUS_EXPR or
2568 conversions temporarily clear the 3rd bit from d->kind while walking
2569 subtrees.
2570 (c_omp_check_loop_iv_exprs): Add CODE argument. Or in 4 into data.kind
2571 if possibly non-rectangular.
2572
ae5c5406
GA
25732021-10-21 Jakub Jelinek <jakub@redhat.com>
2574
2575 PR middle-end/64888
2576 * c-omp.c (c_omp_predefined_variable): Return true also for
2577 ubsan_create_data created artificial variables.
2578
5d5885c9
GA
25792021-10-14 Joseph Myers <joseph@codesourcery.com>
2580
2581 * c-format.c (printf_length_specs, scanf_length_specs)
2582 (print_char_table, scan_char_table): Support DFP formats for C2X.
2583 * c-format.h (TEX_D32, TEX_D64, TEX_D128): Remove.
2584 (T2X_D32, T2X_D64, T2X_D128): New macros.
2585
25862021-10-14 Kwok Cheung Yeung <kcy@codesourcery.com>
2587
2588 * c-omp.c (c_omp_check_context_selector): Rename to
2589 omp_check_context_selector and move to omp-general.c.
2590 (c_omp_mark_declare_variant): Rename to omp_mark_declare_variant and
2591 move to omp-general.c.
2592
52055987
GA
25932021-10-12 Joseph Myers <joseph@codesourcery.com>
2594
2595 * c-format.c (print_char_table): Add %b and %B formats.
2596 (scan_char_table): Add %b format.
2597 * c-format.h (T2X_UI, T2X_UL, T2X_ULL, T2X_US, T2X_UC, T2X_ST)
2598 (T2X_UPD, T2X_UIM): New macros.
2599
26002021-10-12 Jakub Jelinek <jakub@redhat.com>
2601
2602 * c-omp.c (c_finish_omp_atomic): Use
2603 clear_padding_type_may_have_padding_p.
2604
ce6eec39
GA
26052021-10-08 Martin Liska <mliska@suse.cz>
2606
2607 * c-opts.c (c_common_post_options): Use new macro
2608 OPTION_SET_P.
2609
50e20ee6
GA
26102021-10-07 Martin Liska <mliska@suse.cz>
2611
2612 * c-common.c (parse_optimize_options): Make
2613 save_opt_decoded_options a pointer type.
2614
57c7ec62
GA
26152021-10-06 Jakub Jelinek <jakub@redhat.com>
2616
2617 PR tree-optimization/102571
2618 * c-omp.c (c_finish_omp_atomic): Optimize the case where type has
2619 padding, but the non-padding bits are contiguous set of bytes
2620 by adjusting the memcmp call arguments instead of emitting
2621 __builtin_clear_padding and then comparing all the type's bytes.
2622
26232021-10-06 Jakub Jelinek <jakub@redhat.com>
2624
2625 PR c++/102612
2626 * c-cppbuiltin.c (c_cpp_builtins): For -std=c++23 predefine
2627 __cpp_constexpr to 202110L rather than 201907L.
2628
da9c5f78
GA
26292021-10-04 Marek Polacek <polacek@redhat.com>
2630
2631 PR c++/97573
2632 * c-common.h (do_warn_array_compare): Declare.
2633 * c-warn.c (do_warn_array_compare): New.
2634 * c.opt (Warray-compare): New option.
2635
e3e07b89
GA
26362021-10-02 Iain Sandoe <iain@sandoe.co.uk>
2637
2638 * c-format.c: Remove a test of TARGET_FORMAT_TYPES with
2639 NULL, this is not needed.
2640
9d116bcc
GA
26412021-10-01 Martin Sebor <msebor@redhat.com>
2642
2643 PR c/102103
2644 * c-common.c (decl_with_nonnull_addr_p): Handle members.
2645 Check and perform warning suppression.
2646 (c_common_truthvalue_conversion): Enhance warning suppression.
2647
26482021-10-01 Martin Liska <mliska@suse.cz>
2649
2650 PR target/102552
2651 * c-common.c (parse_optimize_options): decoded_options[0] is
3d3b561f
ML
2652 used for program name, so merged_decoded_options should also
2653 respect that.
9d116bcc
GA
2654
26552021-10-01 Jakub Jelinek <jakub@redhat.com>
2656 Richard Biener <rguenther@suse.de>
2657
2658 PR sanitizer/102515
2659 * c-ubsan.c (ubsan_instrument_division): Check the right
2660 flag_sanitize_recover bit, depending on which sanitization
2661 is done. Sanitize INT_MIN / -1 under SANITIZE_SI_OVERFLOW
2662 rather than SANITIZE_DIVIDE. If both SANITIZE_SI_OVERFLOW
2663 and SANITIZE_DIVIDE is enabled, neither check is known
2664 to be false and flag_sanitize_recover bits for those two
2665 aren't the same, emit both __ubsan_handle_divrem_overflow
2666 and __ubsan_handle_divrem_overflow_abort calls.
2667
26682021-10-01 Martin Liska <mliska@suse.cz>
2669
2670 * c-common.c (parse_optimize_options): Combine optimize
2671 options with what was provided on the command line.
2672
26732021-10-01 Jakub Jelinek <jakub@redhat.com>
2674
2675 * c-omp.c (c_omp_split_clauses): Also copy
2676 OMP_CLAUSE_ORDER_REPRODUCIBLE.
2677
cf966403
GA
26782021-09-27 Martin Liska <mliska@suse.cz>
2679
2680 * c-opts.c (c_common_init_options_struct): Set also
3d3b561f 2681 x_flag_default_complex_method.
cf966403 2682
e4777439
GA
26832021-09-22 Jakub Jelinek <jakub@redhat.com>
2684
2685 * c-omp.c (c_omp_split_clauses): Copy over OMP_CLAUSE_ALLOCATE_ALIGN.
2686
62498024
GA
26872021-09-20 Matthias Kretz <m.kretz@gsi.de>
2688
2689 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define or
2690 undefine __RECIPROCAL_MATH__, __NO_SIGNED_ZEROS__,
2691 __NO_TRAPPING_MATH__, __ASSOCIATIVE_MATH__, and
2692 __ROUNDING_MATH__ according to the new optimization flags.
2693
cf74e7b5
GA
26942021-09-18 Jakub Jelinek <jakub@redhat.com>
2695
2696 * c-omp.c (c_omp_split_clauses): Split order clause also to
2697 distribute construct. Copy over OMP_CLAUSE_ORDER_UNCONSTRAINED.
2698
0a4cb439
GA
26992021-09-17 Jakub Jelinek <jakub@redhat.com>
2700
2701 * c-omp.c (c_finish_omp_atomic): Avoid creating
2702 TARGET_EXPR if test is true, use create_tmp_var_raw instead of
2703 create_tmp_var and add a zero initializer to TARGET_EXPRs that
2704 had NULL initializer. When omitting operands after v = x,
2705 use type of v rather than type of x. Fix type of vtmp
2706 TARGET_EXPR.
2707
07985c47
GA
27082021-09-13 Jason Merrill <jason@redhat.com>
2709
2710 * c.opt: Add -Winterference-size.
2711 * c-cppbuiltin.c (cpp_atomic_builtins): Add __GCC_DESTRUCTIVE_SIZE
2712 and __GCC_CONSTRUCTIVE_SIZE.
2713
a26206ec
GA
27142021-09-10 Jakub Jelinek <jakub@redhat.com>
2715
2716 * c-common.h (c_finish_omp_atomic): Add r and weak arguments.
2717 * c-omp.c: Include gimple-fold.h.
2718 (c_finish_omp_atomic): Add r and weak arguments. Add support for
2719 OpenMP 5.1 atomics.
2720
f84e2f0b
GA
27212021-09-09 qing zhao <qing.zhao@oracle.com>
2722
2723 * c-attribs.c (handle_uninitialized_attribute): New function.
2724 (c_common_attribute_table): Add "uninitialized" attribute.
2725
b6db7cd4
GA
27262021-09-08 liuhongt <hongtao.liu@intel.com>
2727
2728 * c-common.c (excess_precision_mode_join): Update below comments.
2729 (c_ts18661_flt_eval_method): Set excess_precision_type to
2730 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
2731 * c-cppbuiltin.c (cpp_atomic_builtins): Update below comments.
2732 (c_cpp_flt_eval_method_iec_559): Set excess_precision_type to
2733 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
2734
b2748138
GA
27352021-09-07 Marcel Vollweiler <marcel@codesourcery.com>
2736
2737 * c-omp.c (c_finish_omp_flush): Handle MEMMODEL_SEQ_CST.
2738
7b739540
GA
27392021-09-03 Eric Botcazou <ebotcazou@adacore.com>
2740
2741 * c-ada-spec.c (dump_ads): Generate pragmas to disable style checks
2742 and -gnatwu warning for the package specification.
2743
e11c6046
GA
27442021-09-01 Iain Sandoe <iain@sandoe.co.uk>
2745
2746 * c-attribs.c (handle_unavailable_attribute): New.
2747
1e2f030b
GA
27482021-08-30 Jason Merrill <jason@redhat.com>
2749
2750 * c.opt: Add -Wmissing-requires.
2751
85d77ac4
GA
27522021-08-25 Lewis Hyatt <lhyatt@gmail.com>
2753
2754 PR other/93067
2755 * c-opts.c (c_common_input_charset_cb): New function.
2756 (c_common_post_options): Call new function
2757 diagnostic_initialize_input_context().
2758
7c9e1645
GA
27592021-08-20 Tobias Burnus <tobias@codesourcery.com>
2760
2761 * c-format.c (gcc_gfc_length_specs): Add 'll' and 'w'.
2762 (gcc_gfc_char_table): Add T9L_LL and T9L_ULL to
2763 "di" and "u", respecitively; fill with BADLEN to match
2764 size of 'types'.
2765 (get_init_dynamic_hwi): Split off from ...
2766 (init_dynamic_diag_info): ... here. Call it.
2767 (init_dynamic_gfc_info): Call it.
2768
27692021-08-20 Jakub Jelinek <jakub@redhat.com>
2770
2771 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ERROR.
2772 * c-pragma.c (omp_pragmas): Add error directive.
2773 * c-omp.c (omp_directives): Uncomment error directive entry.
2774
6e529985
GA
27752021-08-18 Jakub Jelinek <jakub@redhat.com>
2776
2777 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_NOTHING.
2778 * c-pragma.c (omp_pragmas): Add nothing directive.
2779 * c-omp.c (omp_directives): Uncomment nothing directive entry.
2780
2d14d64b
GA
27812021-08-17 Jakub Jelinek <jakub@redhat.com>
2782
2783 PR c++/101539
2784 * c-common.h (enum rid): Add RID_IS_LAYOUT_COMPATIBLE.
2785 * c-common.c (c_common_reswords): Add __is_layout_compatible.
2786
27872021-08-17 Matt Jacobson <mhjacobson@me.com>
2788
2789 * c-opts.c (c_common_post_options): Default to
2790 flag_objc_sjlj_exceptions = 1 only when flag_objc_abi < 2.
2791
27922021-08-17 Jakub Jelinek <jakub@redhat.com>
2793
2794 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCOPE.
2795 * c-pragma.c (omp_pragmas): Add scope construct.
2796 * c-omp.c (omp_directives): Uncomment scope directive entry.
2797
9d1d9fc8
GA
27982021-08-16 Sebastian Huber <sebastian.huber@embedded-brains.de>
2799
2800 * c-cppbuiltin.c (c_cpp_builtins): Define
2801 __LIBGCC_GCOV_TYPE_SIZE if flag_building_libgcc is true.
2802
72be20e2
GA
28032021-08-12 Jakub Jelinek <jakub@redhat.com>
2804
2805 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_MASKED.
2806 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FILTER.
2807 * c-pragma.c (omp_pragmas_simd): Add masked construct.
2808 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_MASKED
2809 enumerator.
2810 (c_finish_omp_masked): Declare.
2811 * c-omp.c (c_finish_omp_masked): New function.
2812 (c_omp_split_clauses): Handle combined masked constructs.
2813
4d17ca1b
GA
28142021-07-30 Jakub Jelinek <jakub@redhat.com>
2815
2816 PR c++/101539
2817 * c-common.h (enum rid): Add RID_IS_POINTER_INTERCONVERTIBLE_BASE_OF.
2818 * c-common.c (c_common_reswords): Add
2819 __is_pointer_interconvertible_base_of.
2820
28212021-07-29 Richard Biener <rguenther@suse.de>
2822
2823 PR c/101512
2824 * c-common.c (c_common_mark_addressable_vec): Look through
2825 C_MAYBE_CONST_EXPR even if not at the toplevel.
2826
af3f12e6
GA
28272021-07-27 Martin Sebor <msebor@redhat.com>
2828
2829 PR c/101585
2830 * c-warn.c (warn_parm_ptrarray_mismatch): Use OEP_DECL_NAME.
2831
ead235f6
GA
28322021-07-23 Jakub Jelinek <jakub@redhat.com>
2833
2834 * c-lex.c (c_common_has_attribute): Call canonicalize_attr_name also
2835 on attr_id. Return 1 for omp::directive or omp::sequence in C++11
2836 and later.
2837
28382021-07-23 Jakub Jelinek <jakub@redhat.com>
2839
2840 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP__START_ and
2841 PRAGMA_OMP__LAST_ enumerators.
2842
419c6c68
GA
28432021-07-21 Thomas Schwinge <thomas@codesourcery.com>
2844 Joseph Myers <joseph@codesourcery.com>
2845 Cesar Philippidis <cesar@codesourcery.com>
2846
2847 * c-pragma.h (pragma_omp_clause): Add 'PRAGMA_OACC_CLAUSE_NOHOST'.
2848
92d45509
GA
28492021-07-20 Martin Sebor <msebor@redhat.com>
2850
2851 * c-common.c (c_build_shufflevector): Adjust by-value argument to
2852 by-const-reference.
2853 * c-common.h (c_build_shufflevector): Same.
2854
87277b6a
GA
28552021-07-16 Andrew Pinski <apinski@marvell.com>
2856
2857 PR c/101453
2858 * c-common.c (parse_optimize_options): Use the correct
2859 size for buffer.
2860
d97d71a1
GA
28612021-07-15 Martin Sebor <msebor@redhat.com>
2862
2863 PR c/101289
2864 PR c/97548
2865 * c-warn.c (warn_parm_array_mismatch): Use OEP_DECL_NAME.
2866
c4fee1c6
GA
28672021-07-14 Jason Merrill <jason@redhat.com>
2868
2869 * c-opts.c (c_common_post_options): Set -fdelete-dead-exceptions.
2870
6fba0eea
GA
28712021-07-06 Martin Sebor <msebor@redhat.com>
2872
2873 * c-format.c (gcc_tdiag_char_table): Remove support for %G and %K.
3d3b561f
ML
2874 (gcc_cdiag_char_table): Same.
2875 (gcc_cxxdiag_char_table): Same.
6fba0eea 2876
7a60a6e8
GA
28772021-07-02 Jakub Jelinek <jakub@redhat.com>
2878
2879 * c-common.h (enum c_omp_directive_kind): New enum.
2880 (struct c_omp_directive): New type.
2881 (c_omp_categorize_directive): Declare.
2882 * c-omp.c (omp_directives): New variable.
2883 (c_omp_categorize_directive): New function.
2884
bea7c16a
GA
28852021-07-01 Eric Botcazou <ebotcazou@adacore.com>
2886
2887 * c-ada-spec.c (packed_layout): New global variable.
2888 (dump_ada_declaration): Set it upon seeing a packed record type.
2889 Do not put the "aliased" keyword if it is set.
2890 (dump_ada_structure): Add Pack aspect if it is set and clear it.
2891
28922021-07-01 Eric Botcazou <ebotcazou@adacore.com>
2893
2894 * c-ada-spec.c (check_name): Rename into...
2895 (check_type_name_conflict): ...this. Minor tweak.
2896 (dump_ada_function_declaration): Adjust to above renaming.
2897 (dump_ada_array_domains): Fix oversight.
2898 (dump_ada_declaration): Call check_type_name_conflict for variables.
2899
90708f87
GA
29002021-06-25 Martin Sebor <msebor@redhat.com>
2901
2902 * c-common.c (c_wrap_maybe_const): Remove TREE_NO_WARNING.
2903 (c_common_truthvalue_conversion): Replace direct uses of
2904 TREE_NO_WARNING with warning_suppressed_p, suppress_warning, and
2905 copy_no_warning.
2906 (check_function_arguments_recurse): Same.
2907 * c-gimplify.c (c_gimplify_expr): Same.
2908 * c-warn.c (overflow_warning): Same.
2909 (warn_logical_operator): Same.
2910 (warn_if_unused_value): Same.
2911 (do_warn_unused_parameter): Same.
2912
9aa8327e
GA
29132021-06-24 Jakub Jelinek <jakub@redhat.com>
2914
2915 * c-common.h (enum c_omp_region_type): Add C_ORT_TARGET and
2916 C_ORT_OMP_TARGET.
2917 * c-omp.c (c_omp_split_clauses): For OMP_CLAUSE_IN_REDUCTION on
2918 combined target constructs also add map (always, tofrom:) clause.
2919
ede6c356
GA
29202021-06-15 Robin Dapp <rdapp@linux.ibm.com>
2921
2922 * c-attribs.c (common_handle_aligned_attribute): Remove short
2923 circuit and dead code.
2924
8dc48181
GA
29252021-06-14 Jonathan Wakely <jwakely@redhat.com>
2926
2927 PR c++/101052
2928 * known-headers.cc (get_stdlib_header_for_name): Add known
2929 headers for EXIT_FAILURE, EXIT_SUCCESS, abort, atexit, calloc,
2930 exit, and getenv.
2931
8b8c3912
GA
29322021-06-12 Jason Merrill <jason@redhat.com>
2933
2934 * c-attribs.c (handle_unused_attribute): Handle FIELD_DECL.
2935
f16f65f8
GA
29362021-06-11 Jakub Jelinek <jakub@redhat.com>
2937
2938 PR c++/100974
2939 * c-cppbuiltin.c (c_cpp_builtins): Predefine __cpp_if_consteval for
2940 -std=c++2b for P1938R3 consteval if support.
2941
4f625f47
GA
29422021-06-09 Jason Merrill <jason@redhat.com>
2943
2944 PR c++/100879
2945 * c-warn.c (warn_for_sign_compare): Remove C++ enum mismatch
2946 warning.
2947
438aac59
GA
29482021-06-07 Martin Liska <mliska@suse.cz>
2949
2950 * c-target.def: Split long lines and replace them
2951 with '\n\'.
2952
600f90cb
GA
29532021-06-04 Martin Sebor <msebor@redhat.com>
2954
2955 PR c/100783
2956 * c-attribs.c (positional_argument): Bail on erroneous types.
2957
29582021-06-04 Martin Sebor <msebor@redhat.com>
2959
2960 * c-warn.c (warn_parm_array_mismatch): Check TREE_PURPOSE to test
2961 for element presence.
2962
440c8a0a
GA
29632021-06-03 Eric Botcazou <ebotcazou@adacore.com>
2964
2965 * c-ada-spec.c (dump_ada_macros): Minor tweaks.
2966 (dump_ada_decl_name): Likewise.
2967 (dump_anonymous_type_name): Remove parent parameter and adjust.
2968 (dump_sloc): Minor tweak.
2969 (dump_ada_array_type): Remove type parameter and adjust.
2970 (dump_ada_enum_type): Remove parent parameter and adjust.
2971 (dump_ada_node): Adjust calls to above functions.
2972 (dumped_anonymous_types): New global variable.
2973 (dump_nested_types_1): Rename into...
2974 (dump_nested_types): ...this.
2975 (dump_nested_type): Remove parent and dumped_types parameters.
2976 <ARRAY_TYPE>: Replace dumped_types with dumped_anonymous_types.
2977 Adjust calls to dump_anonymous_type_name and dump_ada_array_type.
2978 (dump_ada_specs): Initialize and free dumped_anonymous_types.
2979
29802021-06-03 Eric Botcazou <ebotcazou@adacore.com>
2981
2982 * c-ada-spec.c (pp_ada_tree_identifier): Tidy up.
2983 (dump_ada_node) <POINTER_TYPE>: Deal specially with external subtypes.
2984
29852021-06-03 Eric Botcazou <ebotcazou@adacore.com>
2986
2987 * c-ada-spec.c (dump_ada_enum_type): Dump a prefix for constants.
2988 (htable_t): New typedef.
2989 (overloaded_names): Use it.
2990 (add_name): New function.
2991 (init_overloaded_names): Use add_name to populate the table and add
2992 special cases for sigaction and stat.
2993 (overloaded_name_p): Rename into...
2994 (overloading_index): ...this. Do not initialize overloaded_names table
2995 here. Return the index or zero.
2996 (dump_ada_declaration): Minor tweaks. Do not skip overloaded functions
2997 but add an overloading suffix instead.
2998 (dump_ada_specs): Initialize overloaded_names tables here.
2999
b75978d1
GA
30002021-06-01 Martin Liska <mliska@suse.cz>
3001
3002 PR other/100759
3003 * c-attribs.c (handle_optimize_attribute): Limit sanity check
3004 to a situation where we are not in processing of an optimize
3005 pragma.
3006 * c-pragma.c (handle_pragma_pop_options): Restore target
3007 options.
3008
ee682192
GA
30092021-05-31 Indu Bhagat <indu.bhagat@oracle.com>
3010
3011 PR testsuite/100749
3012 * c-pch.c (c_common_valid_pch): Use xstrdup for debug format set names.
3013
30142021-05-31 Richard Biener <rguenther@suse.de>
3015
3016 PR c++/88601
3017 * c-common.c: Include tree-vector-builder.h and
3018 vec-perm-indices.h.
3019 (c_common_reswords): Add __builtin_shufflevector.
3020 (c_build_shufflevector): New funtion.
3021 * c-common.h (enum rid): Add RID_BUILTIN_SHUFFLEVECTOR.
3022 (c_build_shufflevector): Declare.
3023
48166757
GA
30242021-05-28 Jakub Jelinek <jakub@redhat.com>
3025
3026 PR middle-end/99928
3027 * c-omp.c (c_omp_split_clauses): For reduction clause if combined with
3028 target add a map tofrom clause with OMP_CLAUSE_MAP_IMPLICIT.
3029
30302021-05-28 Tobias Burnus <tobias@codesourcery.com>
3031
3032 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_AFFINITY.
3033
2bc6dace
GA
30342021-05-25 Martin Liska <mliska@suse.cz>
3035
3036 PR tree-optimization/92860
3037 PR target/99592
3038 * c-attribs.c (handle_optimize_attribute): Save target node
3039 before calling parse_optimize_options and save it in case
3040 it changes.
3041 * c-pragma.c (handle_pragma_target): Similarly for pragma.
3042 (handle_pragma_pop_options): Likewise here.
3043
30442021-05-25 Martin Liska <mliska@suse.cz>
3045
3046 * c-attribs.c (handle_no_sanitize_coverage_attribute): New.
3047
30482021-05-25 Jakub Jelinek <jakub@redhat.com>
3049
3050 PR middle-end/99928
3051 * c-omp.c (c_omp_split_clauses): Copy reduction to teams when teams is
3052 combined with simd and not with taskloop or for.
3053
2832d51b
GA
30542021-05-21 Jakub Jelinek <jakub@redhat.com>
3055
3056 PR middle-end/99928
3057 * c-omp.c (c_omp_split_clauses): Set OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT
3058 on firstprivate clause copy going to target construct, and for
3059 target simd set also OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT_TARGET bit.
3060
ea34e2ed
GA
30612021-05-20 Jonathan Wakely <jwakely@redhat.com>
3062
3063 * c.opt (Wc++11-extensions, Wc++14-extensions)
3064 (Wc++17-extensions, Wc++20-extensions, Wc++23-extensions): New
3065 options.
3066
30672021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
3068
3069 * c-lex.c (init_c_lex): Use dwarf_debuginfo_p.
3070
30712021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
3072
3073 * c-opts.c (c_common_post_options): Adjust access to debug_type_names.
3074 * c-pch.c (struct c_pch_validity): Use type uint32_t.
3075 (pch_init): Renamed member.
3076 (c_common_valid_pch): Adjust access to debug_type_names.
3077
65f32e5d
GA
30782021-05-19 Martin Sebor <msebor@redhat.com>
3079
3080 PR c/100619
3081 * c-attribs.c (build_attr_access_from_parms): Handle arbitrarily many
3082 bounds.
3083
a8daf9a1
GA
30842021-05-18 Richard Biener <rguenther@suse.de>
3085
3086 PR c/100547
3087 * c-attribs.c (type_valid_for_vector_size): Reject too large nunits.
3088 Reword existing nunit diagnostic.
3089
a7ffc1ef
GA
30902021-05-17 Joern Rennecke <joern.rennecke@embecosm.com>
3091
3092 * c-common.c (braced_list_to_string): Return CTOR unchanged
3093 if host and target character sizes don't match.
3094
87a7d10c
GA
30952021-05-14 Martin Liska <mliska@suse.cz>
3096
3097 * c.opt: Add Warning keyword for 2 options.
3098
f9af11c7
GA
30992021-05-13 Martin Liska <mliska@suse.cz>
3100
3101 PR middle-end/100504
3102 * c-attribs.c (handle_target_clones_attribute): Expect a string
3103 argument to target_clone argument.
3104
037e3661
GA
31052021-05-11 Joseph Myers <joseph@codesourcery.com>
3106
3107 * c-lex.c (interpret_float): Handle digit separators for C2X.
3108
aa891c56
GA
31092021-05-10 Martin Liska <mliska@suse.cz>
3110
3111 * c-ada-spec.c (print_destructor): Use startswith
3112 function instead of strncmp.
3113 (dump_ada_declaration): Likewise.
3114 * c-common.c (disable_builtin_function): Likewise.
3115 (def_builtin_1): Likewise.
3116 * c-format.c (check_tokens): Likewise.
3117 (check_plain): Likewise.
3118 (convert_format_name_to_system_name): Likewise.
3119
e4ff4ffb
GA
31202021-04-28 Patrick McGehearty <patrick.mcgehearty@oracle.com>
3121
3122 * c-cppbuiltin.c (c_cpp_builtins): Add supporting macros for new
3123 complex divide
3124
c0fa3f2f
GA
31252021-04-26 Thomas Schwinge <thomas@codesourcery.com>
3126 Nathan Sidwell <nathan@codesourcery.com>
3127 Tom de Vries <vries@codesourcery.com>
3128 Julian Brown <julian@codesourcery.com>
3129 Kwok Cheung Yeung <kcy@codesourcery.com>
3130
3131 * c.opt (Wopenacc-parallelism): New.
3132
6e81e015
GA
31332021-04-19 Thomas Schwinge <thomas@codesourcery.com>
3134
3135 * c.opt (fopenacc-kernels=): Remove.
3136
019a9220
GA
31372021-04-08 Jakub Jelinek <jakub@redhat.com>
3138
3139 * c-warn.c (do_warn_double_promotion): Fix comment typo,
3140 occured -> occurred.
3141 (check_alignment_of_packed_member): Fix a comment typo,
3142 memeber -> member.
3143 (warn_parm_ptrarray_mismatch): Fix comment typos, os -> of
3144 and onless -> unless.
3145 (warn_parm_array_mismatch): Fix comment typos, declaratation
3146 -> declaration and woud -> would. Fix up comment indentation.
3147
31482021-04-08 Martin Sebor <msebor@redhat.com>
3149
3150 PR middle-end/99883
3151 * c.opt (Wmismatched-new-delete): Correct spelling.
3152
b1da9916
GA
31532021-04-05 Eric Botcazou <ebotcazou@adacore.com>
3154
3155 * c-ada-spec.c (is_simple_enum): Minor tweaks.
3156 (dump_ada_enum_type): Add TYPE and PARENT parameters. For non-simple
3157 enumeral types use again the type name for the enumeration constants.
3158 (dump_ada_node): Adjust call to dump_ada_enum_type.
3159 (dump_nested_type): Likewise.
3160
f1607029
GA
31612021-04-01 Jason Merrill <jason@redhat.com>
3162
3163 PR c++/98481
3164 * c-opts.c (c_common_post_options): Bump latest_abi_version.
3165
4493b1c1
GA
31662021-03-25 Jakub Jelinek <jakub@redhat.com>
3167
3168 PR c++/99565
3169 * c-warn.c (do_warn_duplicated_branches): Pass also
3170 OEP_ADDRESS_OF_SAME_FIELD to operand_equal_p.
3171
6af7b307
GA
31722021-03-20 Jakub Jelinek <jakub@redhat.com>
3173
3174 PR debug/99230
3175 * c-gimplify.c (c_genericize_control_stmt): Handle STATEMENT_LIST.
3176
ceae9533
GA
31772021-03-05 Eric Botcazou <ebotcazou@adacore.com>
3178
3179 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Dump nested types
3180 after entering the separate class package, if any.
3181
67f10d28
GA
31822021-03-04 Richard Biener <rguenther@suse.de>
3183
3184 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator):
3185 Handle ERROR_MARK.
3186
31872021-03-04 Jakub Jelinek <jakub@redhat.com>
3188
3189 PR c/99325
3190 * c-ppoutput.c (print): Change src_line type from int to unsigned.
3191 (token_streamer::stream) Likewise.
3192 (maybe_print_line_1): Likewise. Don't strcmp src_file if src_loc is
3193 UNKNOWN_LOCATION.
3194
f3641ac7
GA
31952021-03-03 Jakub Jelinek <jakub@redhat.com>
3196
3197 PR c/99324
3198 * c-common.c (build_va_arg): Call c_common_mark_addressable_vec
3199 instead of mark_addressable. Fix a comment typo -
3200 neutrallly -> neutrally.
3201
2c83c3fb
GA
32022021-02-28 Jakub Jelinek <jakub@redhat.com>
3203
3204 PR c/99304
3205 * c-attribs.c (handle_malloc_attribute): Fix a typo in inform
3206 message - refernced -> referenced. Remove superfluous space before
3207 closing paren of function calls.
3208
daa68844
GA
32092021-02-25 Nathan Sidwell <nathan@acm.org>
3210
3211 PR c++/99166
3212 * c.opt (-flang-info-module-cmi): Renamed option.
3213
50352c6c
GA
32142021-02-19 Nathan Sidwell <nathan@acm.org>
3215
3216 * c.opt (flang-info-module-read, flang-info-module-read=): New.
3217
bf81237e
GA
32182021-02-18 H.J. Lu <hjl.tools@gmail.com>
3219
3220 PR target/99113
3221 * c-attribs.c (c_common_attribute_table): Add the "retain"
3222 attribute.
3223 (handle_retain_attribute): New function.
3224
0e804ce3
GA
32252021-02-16 Marek Polacek <polacek@redhat.com>
3226
3227 PR c++/99062
3228 * c-attribs.c (handle_assume_aligned_attribute): Check that the
3229 alignment argument is non-negative. Tweak a warning message.
3230
fab095da
GA
32312021-02-12 Martin Sebor <msebor@redhat.com>
3232
3233 PR c/99055
3234 * c-warn.c (warn_parm_array_mismatch): Free strings returned from
3235 print_generic_expr_to_str.
3236
4b37c3ea
GA
32372021-02-10 Richard Biener <rguenther@suse.de>
3238
3239 * c-common.c (parse_optimize_options): Free decoded_options.
3240
a19dd5e6
GA
32412021-02-04 emsr <3dw4rd@verizon.net>
3242
3243 * c-cppbuiltin.c (c_cpp_builtins): __cpp_size_t_suffix=202011L.
3244
9faaa807
GA
32452021-02-03 Ed Smith-Rowland <3dw4rd@verizon.net>
3246
3247 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_size_t_suffix.
3248 * c-lex.c (interpret_integer): Set node type for size literal.
3249
85d04a2e
GA
32502021-01-28 Jakub Jelinek <jakub@redhat.com>
3251
3252 * c.opt (-std=c++2a, -std=c++20, -std=gnu++2a, -std=gnu++20): Remove
3253 draft from description.
3254 (-std=c++2b): Fix a pasto, 2020 -> 2023.
3255
e62bb7f0
GA
32562021-01-26 Paul Fee <paul.f.fee@gmail.com>
3257
3258 * c-common.h (cxx_dialect): Add cxx23 as a dialect.
3259 * c.opt: Add options for -std=c++23, std=c++2b, -std=gnu++23
3260 and -std=gnu++2b
3261 * c-opts.c (set_std_cxx23): New.
3262 (c_common_handle_option): Set options when -std=c++23 is enabled.
3263 (c_common_post_options): Adjust comments.
3264 (set_std_cxx20): Likewise.
3265
161e4c08
GA
32662021-01-25 Martin Sebor <msebor@redhat.com>
3267
3268 PR c++/98646
3269 * c-common.c (check_nonnull_arg): Adjust warning text.
3270
4c9bcd5c
GA
32712021-01-17 Martin Sebor <msebor@redhat.com>
3272
3273 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
3274 assume SSA_NAME_IDENTIFIER evaluates to nonzero.
3275
59cf67d1
GA
32762021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
3277
3278 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DETACH.
3279 Redefine PRAGMA_OACC_CLAUSE_DETACH.
3280
2f7f0d32
GA
32812021-01-15 Jakub Jelinek <jakub@redhat.com>
3282
3283 PR tree-optimization/98597
3284 * c-pretty-print.c: Include options.h.
3285 (c_fold_indirect_ref_for_warn): New function.
3286 (print_mem_ref): Use it. If it returns something that has compatible
3287 type and is TBAA compatible with zero offset, print it and return,
3288 otherwise print it using offsetof syntax or array ref syntax. Fix up
3289 printing if MEM_REFs first operand is ADDR_EXPR, or when the first
3290 argument has pointer to array type. Print pointers using the standard
3291 formatting.
3292
6851dda2
GA
32932021-01-12 Martin Sebor <msebor@redhat.com>
3294
3295 PR c/98597
3296 PR c/98592
3297 * c-pretty-print.c (print_mem_ref): Avoid assuming MEM_REF operand
3298 has pointer type. Remove redundant code. Avoid calling
3299 gimple_canonical_types_compatible_p.
3300
7d187e4f
GA
33012021-01-07 Martin Sebor <msebor@redhat.com>
3302
3303 PR middle-end/98578
3304 * c-pretty-print.c (print_mem_ref): Strip array from access type.
3305 Avoid assuming acces type's size is constant. Correct condition
3306 guarding the printing of a parenthesis.
3307
942ae5be
GA
33082021-01-06 Martin Sebor <msebor@redhat.com>
3309
3310 PR c++/95768
3311 * c-pretty-print.c (c_pretty_printer::primary_expression): For
3312 SSA_NAMEs print VLA names and GIMPLE defining statements.
3313 (print_mem_ref): New function.
3314 (c_pretty_printer::unary_expression): Call it.
3315
33162021-01-06 Richard Biener <rguenther@suse.de>
3317
3318 PR tree-optimization/95582
3319 * c-attribs.c (c_common_attribute_table): Add entry for
3320 signed_bool_precision.
3321 (handle_signed_bool_precision_attribute): New.
3322
8daa719b
GA
33232020-12-24 Iain Sandoe <iain@sandoe.co.uk>
3324
3325 * c.opt: Add -stdlib= option and enumerations for
3326 libstdc++ and libc++.
3327
eefe499f
GA
33282020-12-16 Martin Liska <mliska@suse.cz>
3329
3330 * c.opt: Remove usage of Report.
3331
d52945ce
GA
33322020-12-14 Martin Sebor <msebor@redhat.com>
3333
3334 PR middle-end/98166
3335 PR c++/57111
3336 PR middle-end/98160
3337 * c-attribs.c (maybe_add_noinline): New function.
3338 (handle_malloc_attribute): Call it. Use ATTR_FLAG_INTERNAL.
3339 Implicitly add attribute noinline to functions not declared inline
3340 and warn on those.
3341
ca2bd949
GA
33422020-12-09 Tobias Burnus <tobias@codesourcery.com>
3343
3344 * c-pragma.c (omp_pragmas): Add 'allocate'.
3345 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ALLOCATE.
3346
f6e8e279
GA
33472020-12-08 Jakub Jelinek <jakub@redhat.com>
3348
3349 PR c++/98187
3350 * c-pragma.c (omp_pragmas): Remove "master".
3351 (omp_pragmas_simd): Add "master".
3352
bc8a7013
GA
33532020-12-07 Marek Polacek <polacek@redhat.com>
3354
3355 PR c++/98126
3356 * c-common.c (verify_tree_lim_r): New function.
3357 (verify_sequence_points): Use it. Use nullptr instead of 0.
3358
b8dd0ef7
GA
33592020-12-03 Martin Sebor <msebor@redhat.com>
3360
3361 PR c++/90629
3362 PR middle-end/94527
3363 * c-attribs.c (handle_dealloc_attribute): New function.
3364 (handle_malloc_attribute): Handle argument forms of attribute.
3365 * c.opt (-Wmismatched-dealloc): New option.
3366 (-Wmismatched-new-delete): New option.
3367
33682020-12-03 Jakub Jelinek <jakub@redhat.com>
3369
3370 PR libstdc++/93121
3371 * c-common.h (enum rid): Add RID_BUILTIN_BIT_CAST.
3372 * c-common.c (c_common_reswords): Add __builtin_bit_cast.
3373
e0f5e792
GA
33742020-12-01 JeanHeyd Meneide <phdofthehouse@gmail.com>
3375
3376 * c-cppbuiltin.c (c_cpp_builtins): Add predefined
3377 {__GNUC_EXECUTION_CHARSET_NAME} and
3378 _WIDE_EXECUTION_CHARSET_NAME} macros.
3379
33802020-12-01 Nathan Sidwell <nathan@acm.org>
3381
3382 * c-common.c (module, import, export): New internal tokens (with
3383 trailing space).
3384 * c-common.h (RID__MODULE, RID__IMPORT & RID__EXPORT): Enumerate
3385 them.
3386 (D_CXX_MODULES, D_CXX_MODULES_FLAGS): Enable them.
3387 * c-cppbuiltin.c (c_cpp_builtins): Feature macro.
3388
33892020-12-01 Nathan Sidwell <nathan@acm.org>
3390
3391 * c-opts.c (c_common_init_options): Ask for module dependencies.
3392 (c_common_handle_option): Handle -Mmodules -Mno-modules.
3393 * c-pch.c (c_common_valid_pch): ... does not play with C++
3394 modules.
3395 * c.opt (Mmodules, Mno-modules): New preprocessor dependency
3396 options.
3397 (fmodules-ts, fmodule-header, fmodule-implicit-inline)
3398 (fmodule-only, fmodule-mapper, fmodule-lazy)
3399 (fmodule-version-ignore, Winvalid-imported-macros)
3400 (flang-info-include-translate, flang-info-include-translate-not):
3401 New options
3402
5fbf0ecb
GA
34032020-11-28 Eric Botcazou <ebotcazou@adacore.com>
3404
3405 * c-ada-spec.c (dump_nested_type) <RECORD_TYPE>: Remove obsolete code.
3406 (dump_ada_structure): Also deal with convention, unchecked union and
3407 bit-field for nested types. In the latter case, print an Alignment
3408 aspect along with the Pack aspect.
3409
360258da
GA
34102020-11-25 Martin Sebor <msebor@redhat.com>
3411
3412 PR bootstrap/94982
3413 * c-attribs.c (handle_patchable_function_entry_attribute): Avoid
3414 -Wformat-diag.
3415
1e2c9a27
GA
34162020-11-24 Martin Sebor <msebor@redhat.com>
3417
3418 * c-warn.c (warn_parm_array_mismatch): Avoid invalid redeclarations.
3419
8e6198d0
GA
34202020-11-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3421
3422 * c-attribs.c (handle_special_var_sec_attribute): New.
3423 (handle_noinit_attribute): Remove.
3424 (attr_noinit_exclusions): Rename to...
3425 (attr_section_exclusions): ...this, and add "persistent" attribute
3426 exclusion.
3427 (c_common_attribute_table): Add "persistent" attribute.
3428
7a97e2fc
GA
34292020-11-21 Aaron Sawdey <acsawdey@linux.ibm.com>
3430
3431 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
3432 Treat opaque types like other types.
3433 (c_pretty_printer::direct_abstract_declarator): Opaque types are
3434 supported types.
3435
82e5048e
GA
34362020-11-20 Martin Sebor <msebor@redhat.com>
3437
3438 * c-warn.c (warn_parm_array_mismatch): Bail on invalid redeclarations
3439 with fewer arguments.
3440
34412020-11-20 Martin Sebor <msebor@redhat.com>
3442
3443 PR middle-end/97879
3444 * c-attribs.c (handle_access_attribute): Handle ATTR_FLAG_INTERNAL.
3445 Error out on invalid modes.
3446
34472020-11-20 Jakub Jelinek <jakub@redhat.com>
3448
3449 PR libstdc++/88101
3450 * c-common.c (check_builtin_function_arguments): Handle
3451 BUILT_IN_CLEAR_PADDING.
3452
25bb75f8
GA
34532020-11-18 Nathan Sidwell <nathan@acm.org>
3454
3455 * c-lex.c (c_lex_with_flags): CPP_HEADER_NAMEs can now be seen.
3456
4dabb037
GA
34572020-11-17 Nathan Sidwell <nathan@acm.org>
3458
3459 * c-common.h (enum c_tree_index): Reorder to place lazy fields
3460 after newly-added CTI_MODULE_HWM.
3461
34622020-11-17 Joseph Myers <joseph@codesourcery.com>
3463
3464 * c-cppbuiltin.c (builtin_define_float_constants): Define
3465 "*_IS_IEC_60559__" macros.
3466
34672020-11-17 Nathan Sidwell <nathan@acm.org>
3468
3469 * c-lex.c: #include "langhooks.h".
3470 (cb_undef): Maybe call preprocess_undef lang hook.
3471 * c-opts.c (c_common_post_options): Maybe call preprocess_options
3472 lang hook.
3473 (push_command_line_include): Maybe call preprocess_main_file lang
3474 hook.
3475 (cb_file_change): Likewise.
3476 * c-ppoutput.c: #include "langhooks.h.
3477 (scan_translation_unit): Maybe call preprocess_token lang hook.
3478 (class do_streamer): New, derive from token_streamer.
3479 (directives_only_cb): Data pointer is do_streamer, call
3480 preprocess_token lang hook.
3481 (scan_translation_unit_directives_only): Use do_streamer.
3482 (print_line_1): Move src_line recording to after string output.
3483 (cb_undef): Maybe call preprocess_undef lang hook.
3484
34852020-11-17 Nathan Sidwell <nathan@acm.org>
3486
3487 * c-ppoutput.c (scan_translation_unit): Use token_streamer, remove
3488 code duplicating that functionality.
3489
34902020-11-17 Jakub Jelinek <jakub@redhat.com>
3491
3492 PR c/90628
3493 * c-common.c (check_builtin_function_arguments)
3494 <case BUILT_IN_ADD_OVERFLOW>: Diagnose when last argument is pointer
3495 to _Atomic. For the TYPE_READONLY case, adjust message to be usable
3496 for more builtins and argument positions.
3497
29c5d9ce
GA
34982020-11-16 Iain Sandoe <iain@sandoe.co.uk>
3499
3500 PR objc/97854
3501 * stub-objc.c: Include c-common.h to declare enum rid.
3502
77f67db2
GA
35032020-11-13 Jakub Jelinek <jakub@redhat.com>
3504
3505 PR c++/63287
3506 * c-cppbuiltin.c: Include configargs.h.
3507 (c_cpp_builtins): For C++11 and later if THREAD_MODEL_SPEC is not
3508 defined, predefine __STDCPP_THREADS__ to 1 unless thread_model is
3509 "single".
3510
35112020-11-13 Gergö Barany <gergo@codesourcery.com>
3512 Thomas Schwinge <thomas@codesourcery.com>
3513
3514 * c.opt (fopenacc-kernels): Add.
3515
35162020-11-13 Jason Merrill <jason@redhat.com>
3517
3518 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_using_enum.
3519
35202020-11-13 Piotr H. Dabrowski <phd@phd.re>
3521
3522 PR c++/91318
3523 * c-cppbuiltin.c: c_cpp_builtins_optimize_pragma(): use cpp_define_unused()
3524
35252020-11-13 Martin Liska <mliska@suse.cz>
3526
3527 * c-attribs.c (build_attr_access_from_parms): Format properly.
3528
35292020-11-13 Iain Sandoe <iain@sandoe.co.uk>
3530
3531 PR objc/90707
3532 * c-common.c (c_common_reswords): null_unspecified, nullable,
3533 nonnull, null_resettable: New keywords.
3534 * c-common.h (enum rid): RID_NULL_UNSPECIFIED, RID_NULLABLE,
3535 RID_NONNULL, RID_NULL_RESETTABLE: New.
3536 (OBJC_IS_PATTR_KEYWORD): Include nullability keywords in the
3537 ranges accepted for property attributes.
3538 * c-attribs.c (handle_objc_nullability_attribute): New.
3539 * c-objc.h (enum objc_property_attribute_group): Add
3540 OBJC_PROPATTR_GROUP_NULLABLE.
3541 (enum objc_property_attribute_kind):Add
3542 OBJC_PROPERTY_ATTR_NULL_UNSPECIFIED, OBJC_PROPERTY_ATTR_NULLABLE,
3543 OBJC_PROPERTY_ATTR_NONNULL, OBJC_PROPERTY_ATTR_NULL_RESETTABLE.
3544
35452020-11-13 Iain Sandoe <iain@sandoe.co.uk>
3546
3547 PR objc/77404
3548 * c-attribs.c (handle_objc_root_class_attribute): New
3549 * c-objc.h (objc_start_class_interface): Add a location
3550 value for the position of the class name.
3551 * c.opt: Add Wobjc-root-class.
3552 * stub-objc.c (objc_start_class_interface): Add a location
3553 value for the position of the class name.
3554
a5a11525
GA
35552020-11-12 Joseph Myers <joseph@codesourcery.com>
3556
3557 * c-lex.c (c_common_has_attribute): Take argument std_syntax.
3558 Allow scope for C. Handle standard attributes for C. Do not
3559 accept unscoped attributes if std_syntax and not handled as
3560 standard attributes.
3561 * c-common.h (c_common_has_attribute): Update prototype.
3562
35632020-11-12 Nicholas Guriev <guriev-ns@ya.ru>
3564
3565 PR pch/86674
3566 * c-pch.c (c_common_valid_pch): Use cpp_warning with CPP_W_INVALID_PCH
3567 reason to fix -Werror=invalid-pch and -Wno-error=invalid-pch switches.
3568
0f5f9ed5
GA
35692020-11-11 Patrick Palka <ppalka@redhat.com>
3570
3571 PR c++/88115
3572 * c-opts.c (c_common_post_options): Update latest_abi_version.
3573
bb622641
GA
35742020-11-10 Jakub Jelinek <jakub@redhat.com>
3575
3576 PR c/97748
3577 * c-common.h (warn_if_unused_value): Add quiet argument defaulted
3578 to false.
3579 * c-warn.c (warn_if_unused_value): Likewise. Pass it down
3580 recursively and just return true instead of warning if it is true.
3581 Handle COMPLEX_EXPR.
3582
35832020-11-10 Chung-Lin Tang <cltang@codesourcery.com>
3584
3585 * c-common.h (c_omp_adjust_map_clauses): New declaration.
3586 * c-omp.c (struct map_clause): Helper type for c_omp_adjust_map_clauses.
3587 (c_omp_adjust_map_clauses): New function.
3588
2bee28dd
GA
35892020-11-09 Marek Polacek <polacek@redhat.com>
3590
3591 DR 1914
3592 * c-common.c (attribute_fallthrough_p): Tweak the warning
3593 message.
3594
35952020-11-09 Patrick Palka <ppalka@redhat.com>
3596
3597 * c-pragma.c (handle_pragma_diagnostic): Split the
3598 unknown-option -Wpragmas diagnostic into a warning and a
3599 subsequent note containing a spelling suggestion. Avoid
3600 computing the suggestion if -Wpragmas warnings are being
3601 suppressed.
3602
36032020-11-09 Patrick Palka <ppalka@redhat.com>
3604
3605 PR testsuite/97117
3606 * c-indentation.c (get_visual_column): Remove location_t
3607 parameter. Move the column-tracking diagnostic code from here
3608 to ...
3609 (should_warn_for_misleading_indentation): ... here, before the
3610 early exit for when the loci are not all distinct. Don't pass a
3611 location_t argument to get_visual_column.
3612 (assert_get_visual_column_succeeds): Don't pass a location_t
3613 argument to get_visual_column.
3614 (assert_get_visual_column_fails): Likewise.
3615
fb95de7a
GA
36162020-11-08 Iain Sandoe <iain@sandoe.co.uk>
3617
3618 * c-common.h (OBJC_IS_PATTR_KEYWORD): Add class to the list
3619 of keywords accepted in @property attribute contexts.
3620 * c-objc.h (enum objc_property_attribute_group): Add
3621 OBJC_PROPATTR_GROUP_CLASS.
3622 (enum objc_property_attribute_kind): Add
3623 OBJC_PROPERTY_ATTR_CLASS.
3624
2da7ee05
GA
36252020-11-07 Iain Sandoe <iain@sandoe.co.uk>
3626
3627 * c-common.c (c_common_reswords): Add 'atomic' property
3628 attribute.
3629 * c-common.h (enum rid): Add RID_PROPATOMIC for atomic
3630 property attributes.
3631
36322020-11-07 Iain Sandoe <iain@sandoe.co.uk>
3633
3634 * c-attribs.c (handle_nsobject_attribute): New.
3635 * c.opt: Add WNSObject-attribute.
3636
44cab2d8
GA
36372020-11-06 Iain Sandoe <iain@sandoe.co.uk>
3638
3639 * c-objc.h (enum objc_property_attribute_group): New
3640 (enum objc_property_attribute_kind): New.
3641 (OBJC_PROPATTR_GROUP_MASK): New.
3642 (struct property_attribute_info): Small class encapsulating
3643 parser output from property attributes.
3644 (objc_prop_attr_kind_for_rid): New
3645 (objc_add_property_declaration): Simplify interface.
3646 * stub-objc.c (enum rid): Dummy type.
3647 (objc_add_property_declaration): Simplify interface.
3648 (objc_prop_attr_kind_for_rid): New.
3649
36502020-11-06 Nathan Sidwell <nathan@acm.org>
3651
3652 * c-ada-spec.c (collect_ada_nodes): Rename
3653 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
3654 (collect_ada_node): Likewise.
3655 (dump_forward_type): Likewise.
3656 * c-common.c (set_underlying_type): Rename
3657 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
3658 (user_facing_original_type, c_common_finalize_early_debug): Likewise.
3659
36602020-11-06 Jakub Jelinek <jakub@redhat.com>
3661
3662 * c-common.c (verify_sequence_points): Remove DEBUG_FUNCTION.
3663
0cfd9109
GA
36642020-11-05 Marek Polacek <polacek@redhat.com>
3665
3666 PR c++/97675
3667 * c.opt (Wexceptions): New option.
3668
36692020-11-05 Marek Polacek <polacek@redhat.com>
3670
3671 PR c++/25814
3672 * c.opt (Wvexing-parse): New option.
3673
35c125cb
GA
36742020-11-04 Jakub Jelinek <jakub@redhat.com>
3675
3676 PR c++/97670
3677 * c-omp.c (c_omp_split_clauses): Look through array reductions to find
3678 underlying decl to clear in the allocate_head bitmap.
3679
36802020-11-04 Iain Sandoe <iain@sandoe.co.uk>
3681
3682 * c-objc.h (objc_non_constant_expr_p): New.
3683 * stub-objc.c (objc_non_constant_expr_p): New.
3684
fd2325ea
GA
36852020-11-03 Nathan Sidwell <nathan@acm.org>
3686
3687 * c.opt (MQ,MT): Reword description to be make-agnostic.
3688
88ce3d5f
GA
36892020-11-02 Nathan Sidwell <nathan@acm.org>
3690
3691 * c-opts.c (c_common_post_options): Move var decl to its
3692 initialization point.
3693
36942020-11-01 Iain Sandoe <iain@sandoe.co.uk>
3695
3696 * c-lex.c (c_lex_with_flags): When combining '@' with a
3697 keyword for Objective-C, combine the location ranges too.
3698
36992020-10-30 Qing Zhao <qing.zhao@oracle.com>
3700 H.J.Lu <hjl.tools@gmail.com>
3701
3702 * c-attribs.c (c_common_attribute_table): Add new attribute
3703 zero_call_used_regs.
3704 (handle_zero_call_used_regs_attribute): New function.
3705
e93aae4a
GA
37062020-10-28 Marek Polacek <polacek@redhat.com>
3707
3708 PR c++/97573
3709 * c-opts.c (c_common_post_options): In C++20, turn on
3710 -Wdeprecated-enum-enum-conversion and
3711 -Wdeprecated-enum-float-conversion.
3712 * c.opt (Wdeprecated-enum-enum-conversion,
3713 Wdeprecated-enum-float-conversion): New options.
3714 (Wenum-conversion): Allow for C++ too.
3715
37162020-10-28 Jakub Jelinek <jakub@redhat.com>
3717
3718 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALLOCATE.
3719 * c-omp.c: Include bitmap.h.
3720 (c_omp_split_clauses): Handle OMP_CLAUSE_ALLOCATE.
3721
f19e7c8d
GA
37222020-10-26 Ville Voutilainen <ville.voutilainen@gmail.com>
3723
3724 * c-common.c (__is_nothrow_assignable): New.
3725 (__is_nothrow_constructible): Likewise.
3726 * c-common.h (RID_IS_NOTHROW_ASSIGNABLE): New.
3727 (RID_IS_NOTHROW_CONSTRUCTIBLE): Likewise.
3728
efe71fcc
GA
37292020-10-23 Jan Hubicka <hubicka@ucw.cz>
3730
3731 * c-common.c (c_common_finalize_early_debug): Update for new thunk api.
3732
37332020-10-23 Marek Polacek <polacek@redhat.com>
3734
3735 PR c++/91741
3736 * c-common.c (verify_tree): Handle PAREN_SIZEOF_EXPR.
3737 (c_common_init_ts): Likewise.
3738 * c-common.def (PAREN_SIZEOF_EXPR): New tree code.
3739 * c-common.h (maybe_warn_sizeof_array_div): Declare.
3740 * c-warn.c (sizeof_pointer_memaccess_warning): Unwrap NOP_EXPRs.
3741 (maybe_warn_sizeof_array_div): New function.
3742 * c.opt (Wsizeof-array-div): New option.
3743
37442020-10-23 Martin Sebor <msebor@redhat.com>
3745
3746 PR c/97463
3747 * c-warn.c (warn_parm_ptrarray_mismatch): Move null test earlier.
3748
56ddd5e2
GA
37492020-10-22 Martin Liska <mliska@suse.cz>
3750
3751 PR c/94722
3752 * c-attribs.c (handle_no_stack_protect_function_attribute): New.
3753 (handle_stack_protect_attribute): Add error message for a
3754 no_stack_protector function.
3755
37562020-10-22 Martin Liska <mliska@suse.cz>
3757
3758 * c-cppbuiltin.c (c_cpp_builtins): Use the stack_protector enum.
3759
37602020-10-22 Jan Hubicka <hubicka@ucw.cz>
3761
3762 * c-gimplify.c: Include tree-nested.h
3763 (c_genericize): Update for new nested function info.
3764
b2698c21
GA
37652020-10-14 Martin Sebor <msebor@redhat.com>
3766
3767 PR c/97413
3768 * c-attribs.c (build_attr_access_from_parms): Wrap chain of VLA
3769 bounds in an extra list.
3770
7e9282ae
GA
37712020-10-05 Richard Biener <rguenther@suse.de>
3772 Jakub Jelinek <jakub@redhat.com>
3773
3774 PR c++/97197
3775 * c-pretty-print.c: Include langhooks.h.
3776 (c_pretty_printer::postfix_expression): Handle TARGET_MEM_REF as
3777 expression.
3778 (c_pretty_printer::expression): Handle TARGET_MEM_REF as
3779 unary_expression.
3780 (c_pretty_printer::unary_expression): Handle TARGET_MEM_REF.
3781
660bfe61
GA
37822020-09-30 Martin Sebor <msebor@redhat.com>
3783
3784 PR middle-end/97189
3785 * c-attribs.c (append_access_attr): Use the function declaration
3786 location for a warning about an attribute access argument.
3787
93bca37c
GA
37882020-09-29 Marek Polacek <polacek@redhat.com>
3789
3790 PR c++/94695
3791 * c.opt (Wrange-loop-construct): New option.
3792
82b77dee
GA
37932020-09-23 Martin Sebor <msebor@redhat.com>
3794
3795 PR c/97131
3796 * c-warn.c (warn_parm_ptrarray_mismatch): Handle more invalid input.
3797
37982020-09-23 Marek Polacek <polacek@redhat.com>
3799
3800 PR c/97125
3801 * c-gimplify.c (c_genericize): Only call do_warn_duplicated_branches_r
3802 after loops and other structured control constructs have been lowered.
3803
521d2711
GA
38042020-09-22 Jakub Jelinek <jakub@redhat.com>
3805
3806 * c.opt (Wbuiltin-declaration-mismatch): Fix typo in variable name:
3807 warn_builtin_declaraion_mismatch -> warn_builtin_declaration_mismatch.
3808
44135373
GA
38092020-09-21 Marek Polacek <polacek@redhat.com>
3810
3811 * c.opt (Wctad-maybe-unsupported): New option.
3812
2fe5b7d1
GA
38132020-09-19 Martin Sebor <msebor@redhat.com>
3814
3815 PR c/50584
3816 * c-common.h (warn_parm_array_mismatch): Declare new function.
3817 (has_attribute): Move declaration of an existing function.
3818 (build_attr_access_from_parms): Declare new function.
3819 * c-warn.c (parm_array_as_string): Define new function.
3820 (plus_one): Define new function.
3821 (warn_parm_ptrarray_mismatch): Define new function.
3822 (warn_parm_array_mismatch): Define new function.
3823 (vla_bound_parm_decl): New function.
3824 * c.opt (-Warray-parameter, -Wvla-parameter): New options.
3825 * c-pretty-print.c (pp_c_type_qualifier_list): Don't print array type
3826 qualifiers here...
3827 (c_pretty_printer::direct_abstract_declarator): ...but instead print
3828 them in brackets here. Also print [static]. Strip extraneous
3829 expressions from VLA bounds.
3830
38312020-09-19 Martin Sebor <msebor@redhat.com>
3832
3833 PR c/50584
3834 * c-attribs.c (c_common_attribute_table): Add "arg spec" attribute.
3835 (handle_argspec_attribute): New function.
3836 (get_argument, get_argument_type): New functions.
3837 (append_access_attrs): Add overload. Handle internal attribute
3838 representation in addition to external.
3839 (handle_access_attribute): Handle internal attribute representation
3840 in addition to external.
3841 (build_attr_access_from_parms): New function.
3842
38432020-09-19 Sandra Loosemore <sandra@codesourcery.com>
3844
3845 * c-gimplify.c (genericize_c_loop): Rewrite to match
3846 c_finish_loop in c-typeck.c.
3847
38482020-09-19 Sandra Loosemore <sandra@codesourcery.com>
3849
3850 * c-common.c (c_block_may_fallthrough): New, split from
3851 cxx_block_may_fallthrough in the cp front end.
3852 (c_common_init_ts): Move handling of loop and switch-related
3853 statements here from the cp front end.
3854 * c-common.def (FOR_STMT, WHILE_STMT, DO_STMT): Move here from
3855 cp front end.
3856 (BREAK_STMT, CONTINUE_STMT, SWITCH_STMT): Likewise.
3857 * c-common.h (c_block_may_fallthru): Declare.
3858 (bc_state_t): Move here from cp front end.
3859 (save_bc_state, restore_bc_state): Declare.
3860 (c_genericize_control_stmt): Declare.
3861 (WHILE_COND, WHILE_BODY): Likewise.
3862 (DO_COND, DO_BODY): Likewise.
3863 (FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY, FOR_SCOPE): Likewise.
3864 (SWITCH_STMT_COND, SWITCH_STMT_BODY): Likewise.
3865 (SWITCH_STMT_TYPE, SWITCH_STMT_SCOPE): Likewise.
3866 (SWITCH_STMT_ALL_CASES_P, SWITCH_STMT_NO_BREAK_P): Likewise.
3867 (LABEL_DECL_BREAK, LABEL_DECL_CONTINUE): Likewise.
3868 * c-dump.c (dump_stmt): Copy from cp front end.
3869 (c_dump_tree): Move code to handle structured loop and switch
3870 tree nodes here from cp front end.
3871 * c-gimplify.c: Adjust includes.
3872 (enum bc_t, bc_label, begin_bc_block, finish_bc_block): Move from
3873 cp front end.
3874 (save_bc_state, restore_bc_state): New functions using old code
3875 from cp front end.
3876 (get_bc_label, expr_loc_or_loc): Move from cp front end.
3877 (genericize_c_loop): Move from cp front end.
3878 (genericize_for_stmt, genericize_while_stmt): Likewise.
3879 (genericize_do_stmt, genericize_switch_stmt): Likewise.
3880 (genericize_continue_stmt, genericize_break_stmt): Likewise.
3881 (genericize_omp_for_stmt): Likewise.
3882 (c_genericize_control_stmt): New function using code split from
3883 cp front end.
3884 (c_genericize_control_r): New.
3885 (c_genericize): Call walk_tree with c_genericize_control_r.
3886 * c-pretty-print.c (c_pretty_printer::statement): Move code to handle
3887 structured loop and switch tree nodes here from cp front end.
3888
2aad20c0
GA
38892020-09-17 Patrick Palka <ppalka@redhat.com>
3890
3891 PR c/80076
3892 * c-indentation.c (should_warn_for_misleading_indentation): Move
3893 declarations of local variables closer to their first use.
3894 Handle virtual token locations by resolving them to their
3895 respective macro expansion points. If all three tokens are
3896 produced from the same macro expansion, then instead use their
3897 loci within the macro definition.
3898
ecde1b0a
GA
38992020-09-16 Martin Sebor <msebor@redhat.com>
3900
3901 PR c/78666
3902 PR c/96126
3903 * c-attribs.c (validate_attr_args): New function.
3904 (validate_attr_arg): Same.
3905 (handle_section_attribute): Call it. Introduce a local variable.
3906 (handle_alloc_size_attribute): Same.
3907 (handle_alloc_align_attribute): Same.
3908
50a71cd0
GA
39092020-09-14 Jakub Jelinek <jakub@redhat.com>
3910
3911 * c-attribs.c (handle_optimize_attribute): Adjust
3912 cl_optimization_save, cl_optimization_restore and
3913 build_optimization_node callers.
3914 * c-pragma.c (handle_pragma_optimize): Adjust
3915 build_optimization_node caller.
3916 (handle_pragma_push_options): Adjust
3917 build_optimization_node and build_target_option_node callers.
3918 (handle_pragma_pop_options, handle_pragma_reset_options):
3919 Adjust cl_optimization_restore callers.
3920
8f7ea26a
GA
39212020-08-28 Martin Sebor <msebor@redhat.com>
3922
3923 * c.opt (Wstringop-overread): New option.
3924
a6493809
GA
39252020-08-11 Jakub Jelinek <jakub@redhat.com>
3926
3927 PR c/96545
3928 * c-common.c (get_atomic_generic_size): Require that first argument's
3929 type points to a complete type and use tree_fits_uhwi_p instead of
3930 just INTEGER_CST TREE_CODE check for the TYPE_SIZE_UNIT.
3931
48cc2e46
GA
39322020-07-31 Martin Sebor <msebor@redhat.com>
3933
3934 PR c++/96003
3935 * c-common.c (check_function_arguments_recurse): Return early when
3936 no-warning bit is set.
3937
39382020-07-31 Richard Biener <rguenther@suse.de>
3939
3940 PR debug/96383
3941 * c-common.h (c_common_finalize_early_debug): Declare.
3942 * c-common.c: Include debug.h.
3943 (c_common_finalize_early_debug): finalize_early_debug langhook
3944 implementation generating debug for extern declarations.
3945
e71dab87
GA
39462020-07-27 Nathan Sidwell <nathan@acm.org>
3947
3948 * c-common.c (try_to_locate_new_include_insertion_point): Use
3949 strcmp, not pointer equality.
3950
ae2e0bc1
GA
39512020-07-25 Martin Sebor <msebor@redhat.com>
3952
3953 PR c++/96310
3954 * c-common.c (check_nonnull_arg): Print note only when warning was
3955 issued.
3956
3ea9abca
GA
39572020-07-22 Tobias Burnus <tobias@codesourcery.com>
3958
3959 * c-omp.c (c_finish_omp_critical): Check for no name but
3960 nonzero hint provided.
3961
0933f508
GA
39622020-07-20 Jason Merrill <jason@redhat.com>
3963
3964 * c-cppbuiltin.c (c_cpp_builtins): Update
3965 __cpp_nontype_template_args for C++20.
3966
39672020-07-20 Martin Sebor <msebor@redhat.com>
3968
3969 PR c/96249
3970 * c.opt: Remove stray text.
3971
8ca07a30
GA
39722020-07-14 Lewis Hyatt <lhyatt@gmail.com>
3973
3974 PR other/86904
3975 * c-indentation.c (should_warn_for_misleading_indentation): Get
3976 global tabstop from the new source.
3977 * c-opts.c (c_common_handle_option): Remove handling of -ftabstop, which
3978 is now a common option.
3979 * c.opt: Likewise.
3980
a82c4c4c 39812020-07-08 Eric Botcazou <ebotcazou@adacore.com>
50873cc5
GA
3982
3983 * c.opt (Wscalar-storage-order): Add explicit variable.
3984
f60ee68d
GA
39852020-07-07 Nathan Sidwell <nathan@acm.org>
3986
3987 * c-opts.c (c_common_post_options): Add 'injecting' arg to
3988 cpp_read_main_file.
3989 (c_finish_options): Add linemap_line_start calls for builtin and cmd
3990 maps. Force token position to line_table's highest line.
3991 * c-ppoutput.c (print_line_1): Refactor, print line zero.
3992 (cb_define): Always increment source line.
3993
4077d74c
GA
39942020-07-06 Martin Sebor <msebor@redhat.com>
3995
3996 PR c++/95984
3997 * c-common.c (check_function_nonnull): Avoid checking syntesized calls
3998 to stub lambda objects with null this pointer.
3999 (check_nonnull_arg): Handle C++ nullptr.
4000
b5f24739
GA
40012020-07-02 Jason Merrill <jason@redhat.com>
4002 Jakub Jelinek <jakub@redhat.com>
4003
4004 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_consteval.
4005
46fbb6c6
GA
40062020-06-30 Jakub Jelinek <jakub@redhat.com>
4007
4008 PR c++/95963
4009 * c-common.c (check_function_arguments_recurse): Don't crash on
4010 calls to internal functions.
4011
69273534
GA
40122020-06-28 Martin Sebor <msebor@redhat.com>
4013
4014 PR c++/86568
4015 * c-common.c (struct nonnull_arg_ctx): Add members.
4016 (check_function_nonnull): Use nonnull_arg_ctx as argument. Handle
4017 C++ member functions specially. Consider the this pointer implicitly
4018 nonnull.
4019 (check_nonnull_arg): Use location of argument when available.
4020 (check_function_arguments): Use nonnull_arg_ctx as argument.
4021
9a33c41f
GA
40222020-06-27 Jakub Jelinek <jakub@redhat.com>
4023
4024 PR middle-end/95903
4025 * c-common.c (pointer_int_sum): Use TYPE_OVERFLOW_UNDEFINED instead of
4026 !TYPE_UNSIGNED check to see if we can apply distributive law and handle
4027 smaller precision intop operands separately.
4028
c9c05f73
GA
40292020-06-26 Marek Polacek <polacek@redhat.com>
4030
4031 * c-opts.c (c_common_init_options): Default to gnu++17.
4032
aff95ee7
GA
40332020-06-17 Jonathan Wakely <jwakely@redhat.com>
4034
bd0a89dc 4035 PR c/95378
aff95ee7
GA
4036 * c-common.c (get_atomic_generic_size): Check cv-qualifiers in
4037 pointer arguments.
4038
56638b9b
GA
40392020-06-16 Jakub Jelinek <jakub@redhat.com>
4040
4041 * c-common.h (c_omp_check_loop_iv_exprs): Add an int argument.
4042 * c-omp.c (struct c_omp_check_loop_iv_data): Add maybe_nonrect and
4043 idx members.
4044 (c_omp_is_loop_iterator): New function.
4045 (c_omp_check_loop_iv_r): Use it. Add support for silent scanning
4046 if outer loop iterator is present. Perform duplicate checking through
4047 hash_set in the function rather than expecting caller to do that.
4048 Pass NULL instead of d->ppset to walk_tree_1.
4049 (c_omp_check_nonrect_loop_iv): New function.
4050 (c_omp_check_loop_iv): Use it. Fill in new members, allow
4051 non-rectangular loop forms, diagnose multiple associated loops with
4052 the same iterator. Pass NULL instead of &pset to walk_tree_1.
4053 (c_omp_check_loop_iv_exprs): Likewise.
4054
ec6ffbb9
GA
40552020-06-10 Martin Liska <mliska@suse.cz>
4056
4057 PR tree-optimization/92860
4058 * c-attribs.c (handle_optimize_attribute):
4059 Save global options and compare it after parsing of function
4060 attribute.
4061 * c-pragma.c (opt_stack::saved_global_options): New field.
4062 (handle_pragma_push_options): Save global_options.
4063 (handle_pragma_pop_options): Compare them after pop.
4064
b952c2cf
GA
40652020-06-09 Jakub Jelinek <jakub@redhat.com>
4066
4067 PR c/95580
4068 * c-pretty-print.c (c_pretty_printer::unary_expression): Handle the
4069 case when MEM_REF's first argument has type pointer to incomplete type.
4070
1a59f3db
GA
40712020-06-05 Jason Merrill <jason@redhat.com>
4072
4073 * c-pretty-print.c (pp_c_additive_expression): Handle negative
4074 operand to POINTER_PLUS_EXPR.
4075
3add3425
GA
40762020-06-04 Martin Sebor <msebor@redhat.com>
4077
4078 PR middle-end/10138
4079 PR middle-end/95136
4080 * c-attribs.c (append_access_attrs): Handle attr_access::none.
4081 (handle_access_attribute): Same.
4082
9a5b7438
GA
40832020-06-03 Mark Wielaard <mark@klomp.org>
4084
4085 * known-headers.cc (get_cp_stdlib_header_for_string_macro_name):
4086 New function.
4087 * known-headers.h (get_cp_stdlib_header_for_string_macro_name):
4088 New function declaration.
4089
40902020-06-03 Mark Wielaard <mark@klomp.org>
4091
4092 * known-headers.cc (get_string_macro_hint): New function.
4093 (get_stdlib_header_for_name): Use get_string_macro_hint.
4094 (get_c_stdlib_header_for_string_macro_name): New function.
4095 * known-headers.h (get_c_stdlib_header_for_string_macro_name):
4096 New function declaration.
4097
40982020-06-03 Tobias Burnus <tobias@codesourcery.com>
4099
4100 * c-common.h (c_omp_predetermined_mapping): Declare.
4101 * c-omp.c (c_omp_predetermined_mapping): New.
4102
af114c38
MW
41032020-05-22 Mark Wielaard <mark@klomp.org>
4104
4105 * known-headers.cc (get_stdlib_header_for_name): Add a new
4106 stdlib_hint array for stdbool and stdint.
4107
45c50b6a
MW
41082020-05-22 Mark Wielaard <mark@klomp.org>
4109
4110 * known-headers.cc (get_stdlib_header_for_name): Return
4111 "<stdbool.h>" for "bool", "true" or "false" when STDLIB_C and
4112 flag_isoc99.
4113
c22027a0
NS
41142020-05-20 Nathan Sidwell <nathan@acm.org>
4115
38a4db21
NS
4116 * c-common.c (try_to_locate_new_include_insertion_point): Revert change.
4117
c22027a0
NS
4118 * c-common.c (try_to_locate_new_include_insertion_point): Use
4119 strcmp to compare filenames.
4120 * c-lex.c (init_c_lex): Move declaration to initialization.
4121 * c-opts.c (handle_deferred_opts): Move cpp_get_deps call into
4122 deferred count loop.
4123
29f0e90d
JM
41242020-05-15 Jason Merrill <jason@redhat.com>
4125
4126 * c-opts.c (set_std_cxx20): Set flag_coroutines.
4127
b04445d4
JM
41282020-05-13 Jason Merrill <jason@redhat.com>
4129
4130 * c.opt (std=c++20): Make c++2a the alias.
4131 (std=gnu++20): Likewise.
4132 * c-common.h (cxx_dialect): Change cxx2a to cxx20.
4133 * c-opts.c: Adjust.
4134 * c-cppbuiltin.c: Adjust.
4135 * c-ubsan.c: Adjust.
4136 * c-warn.c: Adjust.
4137
11dd3be5
EB
41382020-05-12 Eric Botcazou <ebotcazou@adacore.com>
4139
4140 * c-ada-spec.c (dump_ads): Output pragma Warnings ("U"); on entry.
4141
b224c376
NS
41422020-05-08 Nathan Sidwell <nathan@acm.org>
4143
4144 Reimplement directives only processing.
4145 * c-ppoutput.c (token_streamer): Ne.
4146 (directives_only_cb): New. Swallow ...
4147 (print_lines_directives_only): ... this.
4148 (scan_translation_unit_directives_only): Reimplment using the
4149 published interface.
4150
f1d94677
MP
41512020-05-07 Marek Polacek <polacek@redhat.com>
4152
4153 * c-format.c (badwords): Add "nonstatic".
4154
9b95bb52
JJ
4155202-05-07 Jakub Jelinek <jakub@redhat.com>
4156
4157 PR c/94968
4158 * c-common.c (speculation_safe_value_resolve_params): Return false if
4159 error_operand_p (val2).
4160 (resolve_overloaded_builtin) <case BUILT_IN_SPECULATION_SAFE_VALUE_N>:
4161 Remove extraneous semicolon.
4162
530b4409 41632020-05-06 qing zhao <qing.zhao@oracle.com>
4164
4165 PR c/94230
4166 * c-indentation.c (get_visual_column): Add a hint to use the new
4167 -flarge-source-files option.
4168
b776bdca
SSF
41692020-05-05 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
4170
4171 * c-attribs.c (handle_vector_size_attribute): Add attribute
4172 nonnull for argument args in order to silence warning of
4173 uninitialized variable usage. Since this is local to the
4174 compilation unit and thus cannot be checked at call sides by the
4175 compiler, added an assert statement in order to verify this.
4176
6607bdd9
L
41772020-05-01 H.J. Lu <hongjiu.lu@intel.com>
4178
4179 PR target/93492
4180 * c-attribs.c (handle_patchable_function_entry_attribute): Limit
4181 value to USHRT_MAX (65535).
4182
691eeb65
JJ
41832020-04-29 Jakub Jelinek <jakub@redhat.com>
4184
4185 * c-format.c (PP_FORMAT_CHAR_TABLE): Add %{ and %}.
4186
26d76be7
JJ
41872020-04-27 Jakub Jelinek <jakub@redhat.com>
4188
4189 PR c/94755
4190 * c-common.c (resolve_overloaded_builtin): Return error_mark_node for
4191 fncode == BUILT_IN_NONE before initialization of first_param.
4192
7291b2ed
MP
41932020-04-23 Marek Polacek <polacek@redhat.com>
4194
4195 PR c++/94733
4196 * c-attribs.c (find_tm_attribute): Use get_attribute_name instead of
4197 TREE_PURPOSE.
4198
58a29af8
PP
41992020-04-14 Patrick Palka <ppalka@redhat.com>
4200
4201 PR c++/85278
4202 * c-pretty-print.c (pp_c_pointer) <case REFERENCE_TYPE>: Print a double
4203 ampersand if it's an rvalue reference type.
4204
09f04139
MS
42052020-04-13 Martin Sebor <msebor@redhat.com>
4206
4207 PR c/92326
4208 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator): Avoid
4209 printing array bound for flexible array members.
4210
ee26baf4
IS
42112020-04-13 Iain Sandoe <iain@sandoe.co.uk>
4212
4213 * c-cppbuiltin.c (c_cpp_builtins): Update coroutines builtin
4214 define, per n4861.
4215
75efe9cb
RB
42162020-04-02 Richard Biener <rguenther@suse.de>
4217
4218 PR c/94392
4219 * c-opts.c (c_common_post_options): Enable -ffinite-loops
4220 for -O2 and C++11 or newer.
4221
75defde9
PP
42222020-03-28 Patrick Palka <ppalka@redhat.com>
4223
4224 * c.opt: Add -fconcepts-diagnostics-depth.
4225
52f24a9e
MS
42262020-03-27 Martin Sebor <msebor@redhat.com>
4227
4228 PR c++/94346
4229 * c-attribs.c (handle_copy_attribute): Avoid passing expressions
4230 to decl_attributes. Make handling of different kinds of entities
4231 more robust.
4232
ccacf77b
MS
42332020-03-27 Martin Sebor <msebor@redhat.com>
4234
4235 PR c++/94098
4236 * c-attribs.c (handle_access_attribute): Avoid setting TYPE_ATTRIBUTES
4237 here.
4238
ca6c7225
JJ
42392020-03-23 Jakub Jelinek <jakub@redhat.com>
4240
4241 PR c++/91993
4242 * c-warn.c (warnings_for_convert_and_check): For expr and/or
4243 result being COMPOUND_EXPRs, skip to ultimate rhs.
4244
1aa22b19
RS
42452020-03-20 Richard Sandiford <richard.sandiford@arm.com>
4246
4247 PR middle-end/94072
4248 * c-common.c (c_common_type_for_mode): Before using a registered
4249 built-in type, check that the vectorness of the type matches
4250 the vectorness of the mode.
4251
700d4cb0
JJ
42522020-03-17 Jakub Jelinek <jakub@redhat.com>
4253
4254 * c-common.c (resolve_overloaded_builtin): Fix up duplicated word
4255 issue in a diagnostic message.
4256
b408e010
LH
42572020-03-15 Lewis Hyatt <lhyatt@gmail.com>
4258
4259 * c.opt: Avoid redundancy in the help text.
4260
e78e50d5
MP
42612020-03-02 Marek Polacek <polacek@redhat.com>
4262
4263 PR c++/93958 - add missing -std=gnu++20.
4264 * c.opt: Add -std=gnu++20.
4265
649e1741
MS
42662020-03-01 Martin Sebor <msebor@redhat.com>
4267
4268 PR c++/92721
4269 * c-attribs.c (append_access_attrs): Correctly handle attribute.
4270 (handle_access_attribute): Same.
4271
7b60f3ba
JJ
42722020-02-25 Jakub Jelinek <jakub@redhat.com>
4273
4274 PR c/93858
4275 * c-pragma.c (handle_pragma_diagnostic): Add missing ? after
4276 "did you mean" hint in diagnostics.
4277
fb260504
JM
42782020-02-15 Jason Merrill <jason@redhat.com>
4279
4280 * c.opt: Add -std=c++20.
4281
1d757b09
EB
42822020-02-14 Eric Botcazou <ebotcazou@adacore.com>
4283
4284 * c-ada-spec.c: Include bitmap.h.
4285 (dump_ada_double_name): Rename into...
4286 (dump_anonymous_type_name): ...this. Always use the TYPE_UID.
4287 (dump_ada_array_type): Adjust to above renaming. Robustify.
4288 (dump_nested_types_1): New function copied from... Add dumped_types
4289 parameter and pass it down to dump_nested_type.
4290 (dump_nested_types): ...this. Remove parent parameter. Just call
4291 dump_nested_types_1 on an automatic bitmap.
4292 (dump_nested_type): Add dumped_types parameter.
4293 <ARRAY_TYPE>: Do not dump it if already present in dumped_types.
4294 Adjust recursive calls and adjust to above renaming.
4295 (dump_ada_declaration): Adjust call to dump_nested_types.
4296 Tidy up and adjust to above renaming.
4297 (dump_ada_specs): Initialize and release bitmap obstack.
4298
0cc575e4
MS
42992020-02-10 Martin Sebor <msebor@redhat.com>
4300
4301 PR c/93640
4302 * c-attribs.c (handle_access_attribute): Correct off-by-one mistakes.
4303
a59aa302
JJ
43042020-02-10 Jakub Jelinek <jakub@redhat.com>
4305
4306 PR other/93641
4307 * c-format.c (check_plain): Fix up last argument of strncasecmp.
4308 Remove useless extra test.
4309
e464fc90
TB
43102020-02-03 Julian Brown <julian@codesourcery.com>
4311 Tobias Burnus <tobias@codesourcery.com>
4312
4313 * c-cppbuiltin.c (c_cpp_builtins): Update _OPENACC define to 201711.
4314
e3b6c052
JM
43152020-01-29 Jason Merrill <jason@redhat.com>
4316
4317 PR c++/89357
4318 * c-attribs.c (check_cxx_fundamental_alignment_constraints): Remove.
4319
6d00f052
JM
43202020-01-23 Jason Merrill <jason@redhat.com>
4321
4322 * c-warn.c (conversion_warning): Change -Wsign-conversion handling.
4323
8a990ffa
MS
43242020-01-23 Martin Sebor <msebor@redhat.com>
4325
4326 PR c/84919
4327 * c-common.c (check_function_arguments): Avoid overlap checking
4328 of sprintf functions.
4329
55b7df8b
JM
43302020-01-22 Jason Merrill <jason@redhat.com>
4331
4332 PR testsuite/93391 - PR 40752 test fails with unsigned plain char.
4333 PR c++/40752
4334 * c-warn.c (conversion_warning): Check operands only after checking
4335 the whole expression. Don't check second operand of + for sign.
4336
c77074d0
JM
43372020-01-21 Jason Merrill <jason@redhat.com>
4338 Manuel López-Ibáñez <manu@gcc.gnu.org>
4339
4340 PR c++/40752 - useless -Wconversion with short +=.
4341 * c.opt (-Warith-conversion): New.
4342 * c-warn.c (conversion_warning): Recurse for operands of
4343 operators. Only warn about the whole expression with
4344 -Warith-conversion.
4345
731dbfc3
JM
43462020-01-21 Jason Merrill <jason@redhat.com>
4347
4348 * c-common.c (unsafe_conversion_p): Don't warn, return UNSAFE_SIGN.
4349 * c-warn.c (conversion_warning): Warn about UNSAFE_SIGN.
4350
ad1a3914
NS
43512020-01-20 Nathan Sidwell <nathan@acm.org>
4352
4353 PR preprocessor/80005
4354 * c-cppbuiltins.c (c_cpp_builtins): Don't define __has_include{,_next}.
4355
49789fd0
IS
43562020-01-18 Iain Sandoe <iain@sandoe.co.uk>
4357
4358 * c-common.c (co_await, co_yield, co_return): New.
4359 * c-common.h (RID_CO_AWAIT, RID_CO_YIELD,
4360 RID_CO_RETURN): New enumeration values.
4361 (D_CXX_COROUTINES): Bit to identify coroutines are active.
4362 (D_CXX_COROUTINES_FLAGS): Guard for coroutine keywords.
4363 * c-cppbuiltin.c (__cpp_coroutines): New cpp define.
4364 * c.opt (fcoroutines): New command-line switch.
4365
4bc1899b
DM
43662020-01-10 David Malcolm <dmalcolm@redhat.com>
4367
4368 * c-format.c (local_event_ptr_node): New.
4369 (PP_FORMAT_CHAR_TABLE): Add entry for "%@".
4370 (init_dynamic_diag_info): Initialize local_event_ptr_node.
4371 * c-format.h (T_EVENT_PTR): New define.
4372
f25e33fa
MS
43732020-01-10 Martin Sebor <msebor@redhat.com>
4374
4375 PR c/93132
4376 * c-attribs.c (append_access_attrs): Validate against the translated
4377 access string rather than the human-readable representation.
4378
8d9254fc
JJ
43792020-01-01 Jakub Jelinek <jakub@redhat.com>
4380
4381 Update copyright years.
4382
39292e25
EB
43832019-12-20 Eric Botcazou <ebotcazou@adacore.com>
4384
4385 * c-ada-spec.h (decl_sloc): Delete.
4386 * c-ada-spec.c (decl_sloc): Make static.
4387
519d7496
JB
43882019-12-19 Julian Brown <julian@codesourcery.com>
4389
4390 * c-common.h (c_omp_map_clause_name): Add prototype.
4391 * c-omp.c (c_omp_map_clause_name): New function.
4392 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ATTACH and
4393 PRAGMA_OACC_CLAUSE_DETACH.
4394
a6163563
JB
43952019-12-19 Julian Brown <julian@codesourcery.com>
4396 Maciej W. Rozycki <macro@codesourcery.com>
4397 Tobias Burnus <tobias@codesourcery.com>
4398 Thomas Schwinge <thomas@codesourcery.com>
4399
4400 * c-pragma.h (pragma_omp_clause): Add
4401 PRAGMA_OACC_CLAUSE_NO_CREATE.
4402
e8f1ade2
MS
44032019-12-17 Martin Sebor <msebor@redhat.com>
4404
4405 PR c++/61339
4406 * c.opt (-Wmismatched-tags, -Wredundant-tags): New options.
4407
368877a1
DM
44082019-12-11 David Malcolm <dmalcolm@redhat.com>
4409
4410 * c-pretty-print.c (c_pretty_printer::clone): New vfunc
4411 implementation.
4412 * c-pretty-print.h (c_pretty_printer::clone): New vfunc decl.
4413
d68f5d45
DM
44142019-12-09 David Malcolm <dmalcolm@redhat.com>
4415
4416 * c-format.c (range_label_for_format_type_mismatch::get_text):
4417 Replace label_text ctor called with true with label_text::take.
4418
d3e28653
DM
44192019-12-09 David Malcolm <dmalcolm@redhat.com>
4420
4421 * c-format.c (selftest::test_type_mismatch_range_labels): Remove
4422 initial newline from expected outputs.
4423 * c-opts.c (c_diagnostic_finalizer): Add pp_newline call before
4424 call to diagnostic_show_locus.
4425
abd6d8cc
JJ
44262019-12-06 Jakub Jelinek <jakub@redhat.com>
4427
4428 * c-cppbuiltin.c (c_cpp_builtins): Don't define __cpp_consteval for
4429 now.
4430
7906797e
MP
44312019-12-05 Marek Polacek <polacek@redhat.com>
4432 Jakub Jelinek <jakub@redhat.com>
4433
4434 PR c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.
4435 * c-cppbuiltin.c (c_cpp_builtins): Adjust the value of __cpp_constexpr.
4436
5c04da88
MP
44372019-12-05 Marek Polacek <polacek@redhat.com>
4438
4439 PR c++/92271 - make __is_same alias for __is_same_as.
4440 * c-common.c: Add __is_same, an alias for __is_same_as.
4441
43aae289
MP
44422019-12-03 Marek Polacek <polacek@redhat.com>
4443
4444 PR c++/91363 - P0960R3: Parenthesized initialization of aggregates.
4445 * c-cppbuiltin.c (c_cpp_builtins): Predefine
4446 __cpp_aggregate_paren_init=201902 for -std=c++2a.
4447
d7ddfbcb
JH
44482019-11-30 Jan Hubicka <hubicka@ucw.cz>
4449
4450 * c-attribs.c (handle_symver_attribute): New function
4451 (c_common_attributes): Add symver.
4452
65ef05d0
RS
44532019-11-30 Richard Sandiford <richard.sandiford@arm.com>
4454
4455 * c-common.c (pointer_int_sum): Use verify_type_context to check
4456 whether the target allows pointer arithmetic for the types involved.
4457 (c_sizeof_or_alignof_type, c_alignof_expr): Use verify_type_context
4458 to check whether the target allows sizeof and alignof operations
4459 for the types involved.
4460
1a291106
JM
44612019-11-27 Jason Merrill <jason@redhat.com>
4462
4463 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
4464
05d6cb1a
JJ
44652019-11-26 Jakub Jelinek <jakub@redhat.com>
4466
4467 PR c++/61414
4468 * c-attribs.c (handle_mode_attribute): Add mode attribute to
4469 ENUMERAL_TYPEs.
4470
5b8d9367
JM
44712019-11-25 Joseph Myers <joseph@codesourcery.com>
4472
4473 PR c/91985
4474 * c-common.c (c_common_type_for_mode): Handle decimal
4475 floating-point types being NULL_TREE.
4476 * c-format.c (get_format_for_type_1): Handle specified types being
4477 NULL_TREE.
4478 * c-lex.c (interpret_float): Give an error for decimal
4479 floating-point constants when decimal floating-point not
4480 supported.
4481
1fbf51cb
JJ
44822019-11-23 Jakub Jelinek <jakub@redhat.com>
4483
4484 PR middle-end/83859
4485 * c-attribs.c (append_access_attrs): Avoid buffer overflow. Avoid
4486 memory leak. Use XNEWVEC macro. Use auto_diagnostic_group to
4487 group warning with inform together.
4488 (handle_access_attribute): Formatting fix.
4489
761df906
JJ
44902019-11-22 Jakub Jelinek <jakub@redhat.com>
4491
bdaf8be1
JJ
4492 PR c/90677
4493 * c-common.h (identifier_global_tag): Declare.
4494 * c-format.c (get_pointer_to_named_type): Renamed to ...
4495 (get_named_type): ... this. Use identifier_global_tag instead of
4496 identifier_global_value, handle the return value being a TYPE_P.
4497 (init_dynamic_diag_info): Adjust get_pointer_to_named_type callers
4498 to call get_named_type instead. Formatting fixes.
4499
c2ecce6d 4500 Implement P1902R1, Missing feature-test macros 2017-2019.
761df906
JJ
4501 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_init_captures
4502 and __cpp_generic_lambdas for -std=c++2a. Define
4503 __cpp_designated_initializers, __cpp_constexpr_in_decltype and
4504 __cpp_consteval for -std=c++2a. Remove a FIXME comment about
4505 __cpp_concepts for -std=c++2a.
4506
54aa6b58
MS
45072019-11-22 Martin Sebor <msebor@redhat.com>
4508
4509 PR middle-end/83859
4510 * c-attribs.c (handle_access_attribute): New function.
4511 (c_common_attribute_table): Add new attribute.
4512 (get_argument_type): New function.
4513 (append_access_attrs): New function.
4514 (get_nonnull_operand): Rename...
4515 (get_attribute_operand): ...to this.
4516 * c-common.c (get_nonnull_operand): Rename...
4517 (get_attribute_operand): ...to this.
4518
6c80b1b5
JM
45192019-11-21 Joseph Myers <joseph@codesourcery.com>
4520
4521 * c-attribs.c (handle_fallthrough_attribute): Use pedwarn instead
4522 of warning.
4523
192961ff
JM
45242019-11-19 Joseph Myers <joseph@codesourcery.com>
4525
4526 * c-common.c (attribute_fallthrough_p): In C, use pedwarn not
4527 warning for standard attributes mixed with fallthrough attributes.
4528
f8aea5e3
JM
45292019-11-15 Joseph Myers <joseph@codesourcery.com>
4530
4531 * c-attribs.c (handle_fallthrough_attribute): Remove static.
4532 * c-common.h (handle_fallthrough_attribute): Declare.
4533
2cc94aa8
JM
45342019-11-15 Joseph Myers <joseph@codesourcery.com>
4535
4536 * c-attribs.c (handle_deprecated_attribute): Remove static.
4537 * c-common.h (handle_deprecated_attribute): Declare.
4538
7c5890cc
JM
45392019-11-14 Joseph Myers <joseph@codesourcery.com>
4540
4541 * c-lex.c (lex_charconst): Make CPP_UTF8CHAR constants unsigned
4542 char for C.
4543
b2417b59
JJ
45442019-11-14 Jakub Jelinek <jakub@redhat.com>
4545
d0ec7c93
JJ
4546 * c-omp.c (c_omp_check_context_selector): Add nvidia to the list of
4547 valid vendors.
4548
b2417b59
JJ
4549 * c-omp.c (c_omp_check_context_selector): Handle name lists
4550 containing string literals. Don't diagnose atomic_default_mem_order
4551 with multiple props.
4552
00be2a5f
JM
45532019-11-13 Joseph Myers <joseph@codesourcery.com>
4554
4555 * c-cppbuiltin.c (builtin_define_float_constants): Also define
4556 NORM_MAX constants. Update call to get_max_float.
4557 (LAZY_HEX_FP_VALUES_CNT): Update value to include NORM_MAX
4558 constants.
4559
2dbad62d
EB
45602019-11-13 Eric Botcazou <ebotcazou@adacore.com>
4561
4562 * c-ada-spec.c (get_underlying_decl): Do not look through typedefs.
4563 (dump_forward_type): Do not generate a declaration for function types.
4564 (dump_nested_type) <ARRAY_TYPE>: Do not generate a nested declaration
4565 of the component type if it is declared in another file.
4566
6ed76044
ML
45672019-11-12 Martin Liska <mliska@suse.cz>
4568
4569 * c-opts.c (c_common_post_options):
4570 Use SET_OPTION_IF_UNSET.
4571
62aee289
MR
45722019-11-12 Maciej W. Rozycki <macro@codesourcery.com>
4573 Frederik Harwath <frederik@codesourcery.com>
4574
4575 gcc/c-family/
4576 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_SERIAL enumeration
4577 constant.
4578 * c-pragma.c (oacc_pragmas): Add "serial" entry.
4579
f486280c
RS
45802019-11-08 Richard Sandiford <richard.sandiford@arm.com>
4581
4582 * c-common.h (gnu_vector_type_p): New function.
4583 * c-common.c (c_build_vec_perm_expr): Require __builtin_shuffle
4584 vectors to satisfy gnu_vector_type_p.
4585 (c_build_vec_convert): Likewise __builtin_convertvector.
4586 (convert_vector_to_array_for_subscript): Likewise when applying
4587 implicit vector to array conversion.
4588 (scalar_to_vector): Likewise when converting vector-scalar
4589 operations to vector-vector operations.
4590
017c6491
JM
45912019-11-08 Joseph Myers <joseph@codesourcery.com>
4592
4593 * c.opt (Wold-style-definition): Initialize to -1.
4594 * c-opts.c (c_common_post_options): Set warn_old_style_definition
4595 to flag_isoc2x if not set explicitly.
4596
c01bd174
JM
45972019-11-07 Joseph Myers <joseph@codesourcery.com>
4598
4599 * c-attribs.c (parse_tm_stmt_attr): Handle scoped attributes.
4600
0df65305
JM
46012019-11-05 Jason Merrill <jason@redhat.com>
4602
4603 * c-opts.c (c_common_post_options): -fconcepts-ts implies
4604 -fconcepts.
4605
e0c866dd
KK
46062019-11-04 Kamlesh Kumar <kamleshbhalui@gmail.com>
4607
4608 * c-opts.c (c_common_post_options): Update
4609 latest_abi_version.
4610
f968ef9b
JJ
46112019-11-02 Jakub Jelinek <jakub@redhat.com>
4612
d0c464d2
JJ
4613 * c-common.h (c_omp_get_context_selector): Remove.
4614 * c-omp.c (c_omp_get_context_selector): Moved to omp-general.c
4615 and renamed to omp_get_context_selector.
4616
917dd789
JJ
4617 * c-omp.c (c_omp_mark_declare_variant): Use
4618 omp_context_selector_set_compare.
4619
f968ef9b
JJ
4620 PR c++/88335 - Implement P1073R3: Immediate functions
4621 * c-common.h (enum rid): Add RID_CONSTEVAL.
4622 * c-common.c (c_common_reswords): Add consteval.
4623
5f6705b7
JJ
46242019-11-01 Martin Sebor <msebor@redhat.com>
4625
4626 PR middle-end/91679
4627 PR middle-end/91647
4628 PR middle-end/91463
4629 PR middle-end/92312
4630 * c-pretty-print.c (direct_abstract_declarator): Print
4631 bound in zero-length arrays.
4632 * c.opt (-Wzero-length-bounds): New option.
4633
43f1814c
NS
46342019-10-30 Nathan Sidwell <nathan@acm.org>
4635
4636 * c-cppbuiltin.c (c_cpp_builtins): Add 'L' suffix to feature
4637 macros.
4638
ad1539d5
MS
46392019-10-28 Martin Sebor <msebor@redhat.com>
4640
4641 PR c/66970
4642 * c-common.c (c_common_nodes_and_builtins): Call c_define_builtins
4643 even when only preprocessing.
4644 * c-common.h (names_builtin_p): Declare new function.
4645 * c-lex.c (init_c_lex): Set has_builtin.
4646 (c_common_has_builtin): Define a new function.
4647 * c-ppoutput.c (init_pp_output): Set has_builtin.
4648
135df52c
JJ
46492019-10-24 Jakub Jelinek <jakub@redhat.com>
4650
4651 * c-common.h (c_omp_context_selector_matches): Remove.
4652 * c-omp.c (c_omp_context_selector_matches): Remove.
4653 * c-attribs.c (c_common_attribute_table): Add
4654 "omp declare target {host,nohost,block}" attributes.
4655
8ad0c477
JM
46562019-10-17 JeanHeyd Meneide <phdofthehouse@gmail.com>
4657
4658 * c-lex.c (c_common_has_attribute): Update nodiscard value.
4659
56898e43
RS
46602019-10-14 Richard Sandiford <richard.sandiford@arm.com>
4661
4662 * c-common.h (user_facing_original_type_p): Declare.
4663 * c-common.c: Include c-spellcheck.h.
4664 (user_facing_original_type_p): New function.
4665
20de9568
JJ
46662019-10-12 Jakub Jelinek <jakub@redhat.com>
4667
4668 * c-common.h (c_omp_mark_declare_variant,
4669 c_omp_context_selector_matches): Declare.
4670 * c-omp.c: Include attribs.h, gimplify.h, cgraph.h, symbol-summary.h
4671 and hsa-common.h.
4672 (c_omp_get_context_selector): Support second argument NULL.
4673 (c_omp_mark_declare_variant, c_omp_context_selector_matches): New
4674 functions.
4675 * c-attribs.c (c_common_attribute_table): Remove "omp declare variant"
4676 attribute, add "omp declare variant base" and
4677 "omp declare variant variant" attributes.
4678
175a85b2
JM
46792019-10-11 Joseph Myers <joseph@codesourcery.com>
4680
4681 * c.opt (Wc11-c2x-compat): Add CPP(cpp_warn_c11_c2x_compat)
4682 CppReason(CPP_W_C11_C2X_COMPAT).
4683
fe2bc27c
JM
46842019-10-11 Joseph Myers <joseph@codesourcery.com>
4685
4686 * c-common.c (c_common_reswords): Do not use D_EXT for _Decimal32,
4687 _Decimal64 and _Decimal128.
4688
27dfdc0f
JM
46892019-10-10 Joseph Myers <joseph@codesourcery.com>
4690
4691 * c-cppbuiltin.c (c_cpp_builtins): Do not define macros for DFP
4692 types if DFP not supported.
4693
94e7f906
JJ
46942019-10-10 Jakub Jelinek <jakub@redhat.com>
4695
4696 * c-common.h (c_omp_check_context_selector,
4697 c_omp_get_context_selector): Declare.
4698 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): Fix spelling
4699 in diagnostic message.
4700 (c_omp_check_context_selector, c_omp_get_context_selector): New
4701 functions.
4702 * c-attribs.c (c_common_attribute_table): Add "omp declare variant"
4703 attribute.
4704 (handle_omp_declare_variant_attribute): New function.
4705
a7160771
MS
47062019-10-09 Martin Sebor <msebor@redhat.com>
4707
4708 PR tree-optimization/90879
4709 * c.opt (-Wstring-compare): New option.
4710
cb57504a
JM
47112019-10-08 Andrew Sutton <asutton@lock3software.com>
4712 Jason Merrill <jason@redhat.com>
4713
4714 Update the concepts implementation to conform to the C++20
4715 specification, improve compile times, and generally clean up
4716 the implementation.
4717
4718 * c-cppbuiltin.c (c_cpp_builtins): Use new feature test values for
4719 concepts when -std=c++2a. Bump __cpp_concepts to 201907.
4720 * c.opt: Add -Wconcepts-ts.
4721 * c-opts.c (c_common_post_options): Warn when -fconcepts is used
4722 with -std=c++2a. Disable warning for -fconcepts in C++20 mode.
4723 (set_std_cxx2a): Enable concepts by default.
4724
fbb2a6dc
JM
47252019-10-08 Joseph Myers <joseph@codesourcery.com>
4726
4727 * c-opts.c (c_common_post_options): Set
4728 -fno-fp-int-builtin-inexact for C2X.
4729
8e007055
JJ
47302019-10-05 Jakub Jelinek <jakub@redhat.com>
4731
4732 PR c++/91369 - Implement P0784R7: constexpr new
4733 * c-cppbuiltin.c (c_cpp_builtins): Predefine
4734 __cpp_constexpr_dynamic_alloc=201907 for -std=c++2a.
4735
843f104d
JM
47362019-10-04 Joseph Myers <joseph@codesourcery.com>
4737
4738 PR c/82752
4739 * c-format.c (C_STD_VER): Handle C2x.
4740 (C_STD_NAME): Likewise.
4741 (strftime_flag_specs): Add 'O' modifier with 'p' flag.
4742 (time_char_table): Use separate entry for 'B' and 'b', with 'O'
4743 modifier allowed and 'p' flag.
4744 * c-format.h (enum format_std_version): Add STD_C2X.
4745 (struct format_char_info): Mention 'p' in comment on flags2.
4746
e9c9a142
DM
47472019-10-01 David Malcolm <dmalcolm@redhat.com>
4748
4749 * c-opts.c (c_diagnostic_finalizer): Temporarily clear prefix when
4750 calling diagnostic_show_locus, rather than destroying it afterwards.
4751
7552c36a
JJ
47522019-10-01 Jakub Jelinek <jakub@redhat.com>
4753
4754 PR c++/91925
4755 * c-warn.c (check_alignment_of_packed_member): Ignore FIELD_DECLs
4756 with NULL DECL_FIELD_OFFSET.
4757
8209db25
RS
47582019-10-01 Richard Sandiford <richard.sandiford@arm.com>
4759
4760 * c-pretty-print.c (pp_c_specifier_qualifier_list): If a vector type
4761 has a type name, use it in preference to the __vector syntax.
4762
9343bf99
RS
47632019-09-30 Richard Sandiford <richard.sandiford@arm.com>
4764
4765 * c-pretty-print.c (pp_c_parameter_type_list): Avoid printing
4766 two spaces between a comma and "...".
4767
59bc434a
JJ
47682019-09-27 Jakub Jelinek <jakub@redhat.com>
4769
4770 PR c++/88203
4771 * c-common.h (c_omp_predefined_variable): Declare.
4772 * c-omp.c (c_omp_predefined_variable): New function.
4773 (c_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
4774 for predefined variables.
4775
c6447c20
RS
47762019-09-27 Richard Sandiford <richard.sandiford@arm.com>
4777
4778 * c-common.h (build_function_call_vec): Take the original
4779 function decl as an optional final parameter.
4780 (check_builtin_function_arguments): Take the original function decl.
4781 * c-common.c (check_builtin_function_arguments): Likewise.
4782 Handle all built-in functions, not just BUILT_IN_NORMAL ones.
4783 Use targetm.check_builtin_call to check BUILT_IN_MD functions.
4784
c4438114
JM
47852019-09-15 Jason Merrill <jason@redhat.com>
4786
4787 * c-warn.c (warn_logical_operator): Strip location wrappers. Don't
4788 fold_for_warn in "|| mask" warning.
4789
68a57628
ML
47902019-09-10 Martin Liska <mliska@suse.cz>
4791
4792 * c.opt: Use newly added WarnRemoved.
4793
f48ef52e
ML
47942019-09-09 Martin Liska <mliska@suse.cz>
4795
4796 * c.opt: Update comment of removed
4797 options that are preserved only for backward
4798 compatibility.
4799
67f6e649
ML
48002019-09-06 Martin Liska <mliska@suse.cz>
4801
4802 PR c++/91125
4803 * c-common.c: Remove definition of flag_use_repository.
4804 * c-common.h: Likewise.
4805 * c-opts.c (c_common_handle_option):
4806 Do not handle OPT_frepo option.
4807 * c.opt: Mark the option with Deprecated.
4808
db9d2274
MP
48092019-09-04 Marek Polacek <polacek@redhat.com>
4810
4811 * c.opt (fdeduce-init-list): Ignored.
4812
68e2c199
PK
48132019-09-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4814
4815 PR c/78736
4816 * c.opt (Wenum-conversion): New option.
4817
7a4418a5
JL
48182019-09-03 Jozef Lawrynowicz <jozef.l@mittosystems.com>
4819
4820 * c-attribs.c (handle_section_attribute): Call the
4821 handle_generic_attribute target hook after performing target
4822 independent processing.
4823 (handle_noinit_attribute): Likewise.
4824
5f76ab15
ILT
48252019-09-03 Ian Lance Taylor <iant@golang.org>
4826
4827 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Always expand
4828 when using -fgo-dump-spec.
4829
ae0d3f6a
ML
48302019-09-02 Martin Liska <mliska@suse.cz>
4831
4832 PR c++/91155
4833 * c-common.c (fname_as_string): Use cxx_printable_name for
4834 __PRETTY_FUNCTION__ same as was used before r265711.
4835
8a902edb
MP
48362019-08-28 Marek Polacek <polacek@redhat.com>
4837
4838 Implement P1152R4: Deprecating some uses of volatile.
4839 PR c++/91361
4840 * c-opts.c (c_common_post_options): Enable -Wvolatile by
4841 default for C++2a, unless -Wno-deprecated.
4842 * c.opt (Wvolatile): New warning.
4843
4742dbe7
MP
48442019-08-28 Marek Polacek <polacek@redhat.com>
4845
4846 PR c++/91360 - Implement C++20 P1143R2: constinit.
4847 * c-common.c (c_common_reswords): Add constinit and __constinit.
4848 (keyword_is_decl_specifier): Handle RID_CONSTINIT.
4849 * c-common.h (enum rid): Add RID_CONSTINIT, RID_FIRST_CXX20, and
4850 RID_LAST_CXX20.
4851 (D_CXX20): Define.
4852 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_constinit.
4853 * c-format.c (cxx_keywords): Add "constinit".
4854 * c.opt (Wc++2a-compat, Wc++20-compat): New options.
4855
6a074892
JJ
48562019-08-27 Jakub Jelinek <jakub@redhat.com>
4857
4858 PR c++/91415
4859 * c-common.c (verify_tree): For LSHIFT_EXPR, RSHIFT_EXPR,
4860 COMPONENT_REF and ARRAY_REF in cxx_dialect >= cxx17 mode handle it
4861 like COMPOUND_EXPR rather than normal expression.
4862
22f8849d
IS
48632019-08-23 Iain Sandoe <iain@sandoe.co.uk>
4864
4865 PR pch/61250
4866 * c-lex.c (c_lex_with_flags): Don't call
4867 c_common_no_more_pch () from here.
4868
df375b03
JJ
48692019-08-23 Jakub Jelinek <jakub@redhat.com>
4870
4871 PR middle-end/91283
4872 * c-common.c (c_ts18661_flt_eval_method): Use flag_excess_precision
4873 instead of flag_excess_precision_cmdline.
4874 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): Likewise.
4875 * c-opts.c (c_common_post_options): Likewise.
4876
14b7950f
MS
48772019-08-22 Martin Sebor <msebor@redhat.com>
4878
4879 PR middle-end/91490
4880 * c-common.c (braced_list_to_string): Add argument and overload.
4881 Handle flexible length arrays and unions.
4882
8bb2ee59
EB
48832019-08-21 Eric Botcazou <ebotcazou@adacore.com>
4884
4885 * c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
4886 function declarations where arguments are missing. Rename variables.
4887
21c1e205
RB
48882019-08-15 Richard Biener <rguenther@suse.de>
4889
4890 * c-common.c (c_stddef_cpp_builtins): When the GIMPLE FE is
4891 enabled, define __SIZETYPE__.
4892
f0033821
CL
48932019-08-14 Christophe Lyon <christophe.lyon@linaro.org>
4894
4895 * c-attribs.c (c_common_attribute_table): Add "noinit" entry. Add
4896 exclusion with "section" attribute.
4897 (attr_noinit_exclusions): New table.
4898 (handle_noinit_attribute): New function.
4899
4d732405
RS
49002019-08-13 Richard Sandiford <richard.sandiford@arm.com>
4901
4902 PR middle-end/91421
4903 * c-common.c (resolve_overloaded_builtin): Use
4904 copy_decl_built_in_function.
4905
51ad8481
MS
49062019-08-13 Martin Sebor <msebor@redhat.com>
4907
4908 PR c/80619
4909 * c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
4910 (asm_fprintf_length_spec): Same.
4911 * c-format.h (format_lengths): Add FMT_LEN_w.
4912
77eb117f
JJ
49132019-08-10 Jakub Jelinek <jakub@redhat.com>
4914
4915 * c-pragma.h (enum pragma_omp_clause): Add
4916 PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
4917
398e3feb
JJ
49182019-08-07 Jakub Jelinek <jakub@redhat.com>
4919
4920 * c-pragma.h (enum pragma_omp_clause): Add
4921 PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. Set PRAGMA_OACC_CLAUSE_USE_DEVICE
4922 equal to PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR instead of being a separate
4923 enumeration value.
4924
ab574db6
MP
49252019-08-05 Marek Polacek <polacek@redhat.com>
4926
4927 PR c++/91338 - Implement P1161R3: Deprecate a[b,c].
4928 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
4929 default for C++2a, unless -Wno-deprecated.
4930 * c.opt (Wcomma-subscript): New warning.
4931
554a530f
JJ
49322019-07-20 Jakub Jelinek <jakub@redhat.com>
4933
4934 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_LOOP.
4935 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_BIND.
4936 * c-pragma.c (omp_pragmas_simd): Add PRAGMA_OMP_LOOP entry.
4937 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_LOOP.
4938 * c-omp.c (c_omp_split_clauses): Add support for 4 new combined
4939 constructs with the loop construct.
4940
1a888209
JJ
49412019-07-13 Jakub Jelinek <jakub@redhat.com>
4942
4943 PR c/91149
4944 * c-omp.c (c_omp_split_clauses): Fix a pasto in
4945 OMP_CLAUSE_REDUCTION_TASK handling.
4946
1fdd6f04
JJ
49472019-07-12 Jakub Jelinek <jakub@redhat.com>
4948
4949 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ORDER.
4950 * c-omp.c (c_omp_split_clauses): Handle splitting of OMP_CLAUSE_ORDER.
4951
99b1c316
MS
49522019-07-09 Martin Sebor <msebor@redhat.com>
4953
4954 PR c++/61339
1fdd6f04 4955 * c-opts.c (handle_deferred_opts): Change class-key of PODs to struct
99b1c316
MS
4956 and others to class.
4957 * c-pretty-print.h: Same.
4958
6c1dae73
MS
49592019-07-09 Martin Sebor <msebor@redhat.com>
4960
4961 PR c++/61339
4962 * c-format.c (check_argument_type): Change class-key from class to
4963 struct and vice versa to match convention and avoid -Wclass-is-pod
4964 and -Wstruct-no-pod.
4965 * c-pretty-print.h: Same.
4966
8ba6ea87
ML
49672019-07-03 Martin Liska <mliska@suse.cz>
4968
4969 * c-common.c (try_to_locate_new_include_insertion_point): Remove
4970 dead assignemts.
4971
83eb9522
JJ
49722019-07-03 Jakub Jelinek <jakub@redhat.com>
4973
4974 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_REDUCTION_INSCAN
4975 clauses on OMP_FOR rather than OMP_PARALLEL when OMP_FOR is combined
4976 with OMP_PARALLEL.
4977
1c6ffbab
QZ
49782019-07-02 qing zhao <qing.zhao@oracle.com>
4979
4980 PR preprocessor/90581
4981 * c-opts.c (c_common_handle_option): Handle -fmax-include-depth.
4982 * c.opt: Add new option -fmax-include-depth.
4983
7ffc7de5
JM
49842019-06-26 Jason Merrill <jason@redhat.com>
4985
4986 PR c++/55442 - memory-hog with highly recursive constexpr.
4987 * c.opt (fconstexpr-loop-limit): New.
4988
361af3e4
JJ
49892019-06-25 Jakub Jelinek <jakub@redhat.com>
4990
4991 PR sanitizer/90954
4992 * c-omp.c (c_finish_omp_atomic): Allow tree_invariant_p in addition
4993 to SAVE_EXPR in first operand of a COMPOUND_EXPR.
4994
ab20d992
JJ
49952019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
4996
4997 * c-common.c (c_common_nodes_and_builtins): Define
4998 alternate "__intN__" name for "__intN" types.
4999
f4af4019
JH
50002019-06-24 Jan Hubicka <jh@suse.cz>
5001
5002 * c-common.c (braced_lists_to_strings): Check that
5003 type is array or integer prior checking string flag.
5004
da9e9b57
MB
50052019-06-21 Matthew Beliveau <mbelivea@redhat.com>
5006
5007 PR c++/90875 - added -Wswitch-outside-range option
5008 * c.opt (Wswitch-outside-range): Added new option.
5009 * c-warn.c (c_do_switch_warnings): Use OPT_Wswitch-outside-range.
5010
3f3d6a6f
MP
50112019-06-21 Marek Polacek <polacek@redhat.com>
5012
5013 PR c++/90953 - ICE with -Wmissing-format-attribute.
5014 * c-common.c (check_function_arguments_recurse): Use
5015 get_attribute_name.
5016 (check_missing_format_attribute): Likewise.
5017
1bf32c11
MP
50182019-06-19 Marek Polacek <polacek@redhat.com>
5019
5020 PR c++/60364 - noreturn after first decl not diagnosed.
5021 * c-attribs.c (handle_noreturn_attribute): No longer static.
5022 * c-common.h (handle_noreturn_attribute, attr_noreturn_exclusions):
5023 Declare.
5024 * c-format.c (check_function_format): Use get_attribute_name.
5025
a04c0734
MS
50262019-06-19 Martin Sebor <msebor@redhat.com>
5027
5028 PR translation/90156
5029 * c-format.c (function_format_info::format_type): Adjust type.
5030 (function_format_info::is_raw): New member.
5031 (decode_format_type): Adjust signature. Handle "raw" diag attributes.
5032 (decode_format_attr): Adjust call to decode_format_type.
5033 Avoid a redundant call to convert_format_name_to_system_name.
5034 Avoid abbreviating the word "arguments" in a diagnostic.
5035 (format_warning_substr): New function.
5036 (avoid_dollar_number): Quote dollar sign in a diagnostic.
5037 (finish_dollar_format_checking): Same.
5038 (check_format_info): Same.
5039 (struct baltoks_t): New.
5040 (c_opers, c_keywords, cxx_keywords, badwords, contrs): New arrays.
5041 (maybe_diag_unbalanced_tokens, check_tokens, check_plain): New
5042 functions.
5043 (check_format_info_main): Call check_plain. Use baltoks_t. Call
5044 maybe_diag_unbalanced_tokens.
5045 (handle_format_attribute): Spell out the word "arguments" in
5046 a diagnostic.
5047
d3786ebb
MB
50482019-06-11 Matthew Beliveau <mbelivea@redhat.com>
5049
5050 PR c++/90449 - add -Winaccessible-base option.
5051 * c.opt (Winaccessible-base): New option.
5052
bf38f7e9
JJ
50532019-06-10 Jakub Jelinek <jakub@redhat.com>
5054
5055 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCAN.
5056 * c-pragma.c (omp_pragmas_simd): Add #pragma omp scan.
5057 * c-omp.c (c_omp_split_clauses): Diagnose inscan reductions on
5058 combined/composite constructs where it is not allowed. Copy over
5059 OMP_CLAUSE_REDUCTION_INSCAN.
5060
0ecf545c
MS
50612019-06-05 Martin Sebor <msebor@redhat.com>
5062
5063 * c-attribs.c (handle_mode_attribute): Adjust quoting and hyphenation.
5064 (handle_alias_ifunc_attribute): Same.
5065 (handle_copy_attribute): Same.
5066 (handle_weakref_attribute): Same.
5067 (handle_nonnull_attribute): Same.
5068 * c-warn.c (warn_for_sign_compare): Same.
5069 (warn_for_restrict): Same.
5070 * c.opt: Same.
5071
36b34127
MS
50722019-06-05 Martin Sebor <msebor@redhat.com>
5073
5074 * c-pragma.c (handle_pragma_weak): Adjust quoting in a diagnostic.
5075 * c.opt (-Wformat-diag): Remove a spurious period.
5076
357a352f
JJ
50772019-05-29 Jakub Jelinek <jakub@redhat.com>
5078
5079 PR c/90628
5080 * c-common.c (check_builtin_function_arguments)
5081 <case BUILTIN_*_OVERFLOW>: Diagnose pointer to const qualified integer
5082 as last argument.
5083
2b8235ea
EB
50842019-05-23 Eric Botcazou <ebotcazou@adacore.com>
5085
5086 * c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
5087
6d86ddc4
ML
50882019-05-22 Martin Liska <mliska@suse.cz>
5089
5090 PR lto/90500
5091 * c-attribs.c (handle_copy_attribute): Do not copy
5092 target_clones attribute.
5093
419ba5b9
EB
50942019-05-21 Eric Botcazou <ebotcazou@adacore.com>
5095
5096 * c-ada-spec.h (enum cpp_operation): Add IS_ASSIGNMENT_OPERATOR.
5097 * c-ada-spec.c (print_assignment_operator): New function.
5098 (dump_ada_declaration) <FUNCTION_DECL>: Call it do dump explicit copy
5099 assignment operators declared as methods and filter out the others.
5100
e03436e7
TS
51012019-05-17 Thomas Schwinge <thomas@codesourcery.com>
5102
5103 PR c/89433
5104 * c-attribs.c (c_common_attribute_table): Set min_len to -1 for
5105 "omp declare target".
5106
a9c697b8
MS
51072019-05-16 Martin Sebor <msebor@redhat.com>
5108
ab20d992
JJ
5109 * c-attribs.c (handle_no_sanitize_attribute): Quote identifiers,
5110 keywords, operators, and types in diagnostics.
5111 (handle_scalar_storage_order_attribute): Same.
5112 (handle_mode_attribute): Same.
5113 (handle_visibility_attribute): Same.
5114 (handle_assume_aligned_attribute): Same.
5115 (handle_no_split_stack_attribute): Same.
5116 * c-common.c (shorten_compare): Same.
5117 (c_common_truthvalue_conversion): Same.
5118 (cb_get_source_date_epoch): Same.
5119 * c-lex.c (cb_def_pragma): Quote keywords, operators, and types
5120 in diagnostics.
5121 (interpret_float): Same.
5122 * c-omp.c (c_finish_omp_for): Same.
5123 * c-opts.c (c_common_post_options): Same.
5124 * c-pch.c (c_common_pch_pragma): Same.
5125 * c-pragma.c (pop_alignment): Same.
5126 (handle_pragma_pack): Same.
5127 (apply_pragma_weak): Same.
5128 (handle_pragma_weak): Same.
5129 (handle_pragma_scalar_storage_order): Same.
5130 (handle_pragma_redefine_extname): Same.
5131 (add_to_renaming_pragma_list): Same.
5132 (maybe_apply_renaming_pragma): Same.
5133 (push_visibility): Same.
5134 (handle_pragma_visibility): Same.
5135 (handle_pragma_optimize): Same.
5136 (handle_pragma_message): Same.
5137 * c-warn.c (warn_for_omitted_condop): Same.
5138 (lvalue_error): Same.
a9c697b8 5139
6b943512
RB
51402019-05-15 Richard Biener <rguenther@suse.de>
5141
5142 PR c/90474
5143 * c-common.c (c_common_mark_addressable_vec): Also mark
5144 a COMPOUND_LITERAL_EXPR_DECL addressable similar to
5145 c_mark_addressable.
ab20d992 5146
b744fc85
NS
51472019-05-06 Nathan Sidwell <nathan@acm.org>
5148
5149 * c-opts.c (handle_defered_opts): Rename struct deps to struc mkdeps.
5150
598f50d7
NS
51512019-04-30 Nathan Sidwell <nathan@acm.org>
5152
5153 * c-common.c (c_common_init_ts): Use MARK_TS_EXP. Mark SIZEOF_EXPR.
5154
5bcc5a3b
ML
51552019-04-30 Martin Liska <mliska@suse.cz>
5156
5157 * c-pragma.c (handle_pragma_diagnostic): Provide hints
5158 for unknown options.
5159
e78a87f7
RS
51602019-04-26 Richard Sandiford <richard.sandiford@arm.com>
5161
5162 * c-warn.c (strict_aliasing_warning): Apply COMPLETE_TYPE_P to
5163 the pointer target rather than the pointer itself.
5164
c280b7ee
JJ
51652019-04-19 Jakub Jelinek <jakub@redhat.com>
5166
5167 PR c/89888
5168 * c-common.h (c_add_case_label): Remove orig_type and outside_range_p
5169 arguments.
5170 (c_do_switch_warnings): Remove outside_range_p argument.
5171 * c-common.c (check_case_bounds): Removed.
5172 (c_add_case_label): Remove orig_type and outside_range_p arguments.
5173 Don't call check_case_bounds. Fold low_value as well as high_value.
5174 * c-warn.c (c_do_switch_warnings): Remove outside_range_p argument.
5175 Check for case labels outside of range of original type here and
5176 adjust them.
5177
8e8225e6
JJ
51782019-04-12 Jakub Jelinek <jakub@redhat.com>
5179
63b8a166
JJ
5180 PR translation/90041
5181 * c.opt (-fhandle-exceptions): Use %< and %> around option names
5182 in the Warn diagnostics.
5183
8e8225e6
JJ
5184 PR c/89946
5185 * c-attribs.c (handle_patchable_function_entry_attribute): Add
5186 function comment. Warn if arguments of the attribute are not positive
5187 integer constants.
5188
53a3f614
EB
51892019-04-09 Eric Botcazou <ebotcazou@adacore.com>
5190
5191 * c-ada-spec.c (print_destructor): Deal with deleting destructors.
5192 (dump_ada_declaration) <FUNCTION_DECL>: Likewise.
5193
22be5873
EB
51942019-04-07 Eric Botcazou <ebotcazou@adacore.com>
5195
5196 * c-ada-spec.c (is_float128): New predicate extracted from...
5197 (dump_ada_node) <COMPLEX_TYPE>: Use it to recognize __cfloat128.
5198 <REAL_TYPE>: ...here. Call it.
5199
34facf20
DM
52002019-04-05 David Malcolm <dmalcolm@redhat.com>
5201
5202 PR c/89985
5203 * c-warn.c (check_address_or_pointer_of_packed_member): Add
5204 auto_diagnostic_group. Guard inform calls by result of
5205 warning_at call.
5206
05564120
MP
52072019-04-05 Marek Polacek <polacek@redhat.com>
5208
ab20d992 5209 PR c++/89973 - -Waddress-of-packed-member ICE with invalid conversion.
05564120
MP
5210 * c-warn.c (check_address_or_pointer_of_packed_member): Check the type
5211 of RHS.
5212
7a506c3c
JM
52132019-04-03 Jason Merrill <jason@redhat.com>
5214
5215 PR c++/86586 - -fcompare-debug=-Wsign-compare.
5216 * c-warn.c (warn_for_sign_compare): Call fold_for_warn.
5217
ddeae8c8
MS
52182019-04-01 Martin Sebor <msebor@redhat.com>
5219
5220 PR c/89685
5221 * c-attribs.c (handle_copy_attribute): Handle references and
5222 non-constant expressions.
5223
a15ffa22
JJ
52242019-03-22 Jakub Jelinek <jakub@redhat.com>
5225
5226 PR c++/87481
5227 * c.opt (-fconstexpr-ops-limit=): New option.
5228
36a3a7a3
JJ
52292019-03-21 Jakub Jelinek <jakub@redhat.com>
5230
5231 * c-common.c (per_file_includes_t): Use false as Lazy in hash_set
5232 template param.
5233
bec1da64
MS
52342019-03-19 Martin Sebor <msebor@redhat.com>
5235
5236 PR tree-optimization/89688
5237 * c-common.c (braced_list_to_string): Make static.
5238 (braced_lists_to_strings): Define new function.
5239 * c-common.h (braced_list_to_string): Remove.
5240 (braced_lists_to_strings): Declare.
5241
1fe61adf
ML
52422019-03-12 Martin Liska <mliska@suse.cz>
5243
5244 * c-opts.c (c_common_handle_option): Wrap option with %< and %>.
5245
93964ebd
ML
52462019-03-11 Martin Liska <mliska@suse.cz>
5247
5248 * c-opts.c (c_common_post_options): Wrap apostrophes
5249 in gcc internal format with %'.
5250
a3f9f006
ML
52512019-03-11 Martin Liska <mliska@suse.cz>
5252
5253 * c-attribs.c (handle_nocf_check_attribute): Wrap an option name
5254 in a string format message and fix GNU coding style.
5255 * c-common.c (vector_types_convertible_p): Likewise.
5256 (c_build_vec_perm_expr): Likewise.
5257 * c-indentation.c (get_visual_column): Likewise.
5258 * c-opts.c (c_common_handle_option): Likewise.
5259 (c_common_post_options): Likewise.
5260 (sanitize_cpp_opts): Likewise.
5261 * c-pch.c (c_common_pch_pragma): Likewise.
5262 * c-pragma.c (handle_pragma_pack): Likewise.
5263
1db01ff9
JJ
52642019-03-08 Jakub Jelinek <jakub@redhat.com>
5265
5266 PR tree-optimization/89550
5267 * c-common.c (c_common_truthvalue_conversion): Only set
5268 TREE_NO_WARNING if warning_at returned true.
5269 * c-warn.c (overflow_warning, warn_logical_operator): Likewise.
5270
ba790e6f
JJ
52712019-02-25 Sandra Loosemore <sandra@codesourcery.com>
5272 Martin Sebor <msebor@gmail.com>
5273
5274 * c.opt (Wmissing-attributes): Clean up doc string.
5275
7da73ba7
JJ
52762019-02-25 Jakub Jelinek <jakub@redhat.com>
5277
5278 PR c/89495
5279 * c-format.c (maybe_read_dollar_number): Compute nargnum in
5280 HOST_WIDE_INT type to avoid overflows and change overflow_flag
5281 checking.
5282
921bb9d1
RB
52832019-02-22 Richard Biener <rguenther@suse.de>
5284
5285 * c-pch.c (no_checksum): Remove.
5286 (pch_init): Remove assertion that executable_checksum is not
5287 all zero.
5288 (c_common_valid_pch): Likewise.
5289
e2ebb05c
MS
52902019-02-18 Martin Sebor <msebor@redhat.com>
5291
5292 PR middle-end/89294
5293 * c-common.c (invalid_array_size_error): Handle cst_size_not_constant.
5294
3fe53000
DM
52952019-02-16 David Malcolm <dmalcolm@redhat.com>
5296
5297 PR c++/88680
5298 * c-common.c (shorten_compare): Call fold_for_warn on op0 when
5299 implementing -Wtype-limits.
5300
28a8cef1
MS
53012019-02-11 Martin Sebor <msebor@redhat.com>
5302
5303 PR c++/87996
5304 * c-common.c (invalid_array_size_error): New function.
5305 (valid_array_size_p): Call it. Handle size as well as type.
5306 * c-common.h (valid_constant_size_p): New function.
5307 (enum cst_size_error): New type.
5308
ec2be203
DM
53092019-01-31 David Malcolm <dmalcolm@redhat.com>
5310
5311 PR c/89122
5312 * known-headers.cc (get_stdlib_header_for_name): Add
5313 {FLT|DBL|LDBL}_{MAX|MIN} to "hints" array.
5314
8936f047
JJ
53152019-01-31 Jakub Jelinek <jakub@redhat.com>
5316
5317 PR libstdc++/88170
5318 * c-pretty-print.c (pp_c_enumeration_constant): Print always as
5319 a C cast in pp_c_flag_gnu_v3 mode.
5320
6a335b96
JJ
53212019-01-29 Jakub Jelinek <jakub@redhat.com>
5322
5323 PR c/86125
5324 * c-common.c (c_common_nodes_and_builtins): Build type variants for
5325 builtin_structptr_types types even for C.
5326
2a06eba5
BE
53272019-01-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
5328
5329 * c-warn.c (check_address_or_pointer_of_packed_member): Handle the case
5330 when rhs is of array type correctly. Fix handling of nested structures.
5331 Fix handling of indirect_ref together with nop_expr and/or addr_expr.
5332 (check_and_warn_address_or_pointer_of_packed_member): Fix handling of
5333 type casts within nested compound expressions.
5334
18a23298
JJ
53352019-01-22 Jakub Jelinek <jakub@redhat.com>
5336
5337 PR middle-end/88968
5338 * c-omp.c (c_finish_omp_atomic): For bitfield atomics, update type
5339 variable after using BIT_FIELD_REF.
5340
420183d9
L
53412019-01-18 H.J. Lu <hongjiu.lu@intel.com>
5342
5343 PR c/51628
5344 PR c/88664
5345 * c-common.h (warn_for_address_or_pointer_of_packed_member):
5346 Remove the boolean argument.
5347 * c-warn.c (check_address_of_packed_member): Renamed to ...
5348 (check_address_or_pointer_of_packed_member): This. Also
5349 warn pointer conversion.
5350 (check_and_warn_address_of_packed_member): Renamed to ...
5351 (check_and_warn_address_or_pointer_of_packed_member): This.
5352 Also warn pointer conversion.
5353 (warn_for_address_or_pointer_of_packed_member): Remove the
5354 boolean argument. Don't check pointer conversion here.
5355
99063eee
RS
53562019-01-15 Richard Sandiford <richard.sandiford@arm.com>
5357
5358 PR inline-asm/52813
5359 * c.opt (Wdeprecated): Move documentation and variable to common.opt.
5360
a30d0196
JJ
53612019-01-14 Jakub Jelinek <jakub@redhat.com>
5362
5363 * c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
5364 and __cpp_nontype_template_parameter_auto. Add a comment that
5365 __cpp_template_auto is deprecated.
5366
2d91f79d
TH
53672019-01-14 Tom Honermann <tom@honermann.net>
5368
5369 Implement P0482R5, char8_t: A type for UTF-8 characters and strings
5370 * c-common.c (c_common_reswords): Add char8_t.
5371 (fix_string_type): Use char8_t for the type of u8 string literals.
5372 (c_common_get_alias_set): char8_t doesn't alias.
5373 (c_common_nodes_and_builtins): Define char8_t as a builtin type in
5374 C++.
5375 (c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
5376 (keyword_begins_type_specifier): Add RID_CHAR8.
5377 * c-common.h (rid): Add RID_CHAR8.
5378 (c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
5379 Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
5380 Define char8_type_node and char8_array_type_node.
5381 * c-cppbuiltin.c (cpp_atomic_builtins): Predefine
5382 __GCC_ATOMIC_CHAR8_T_LOCK_FREE.
5383 (c_cpp_builtins): Predefine __cpp_char8_t.
5384 * c-lex.c (lex_string): Use char8_array_type_node as the type of
5385 CPP_UTF8STRING.
5386 (lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
5387 * c-opts.c: If not otherwise specified, enable -fchar8_t when
5388 targeting C++2a.
5389 * c.opt: Add the -fchar8_t command line option.
5390
23db6ced
MS
53912019-01-14 Martin Sebor <msebor@redhat.com>
5392
5393 PR target/88638
5394 * c-attribs.c (positional_argument): Call valid_format_string_type_p
5395 and issue errors if it fails.
5396 * c-common.h (valid_format_string_type_p): Declare.
5397 * c-format.c (valid_stringptr_type_p): Rename...
5398 (valid_format_string_type_p): ...to this and make extern.
5399 (handle_format_arg_attribute): Adjust to new name.
5400 (check_format_string): Same.
5401
234c3818
L
54022019-01-13 H.J. Lu <hongjiu.lu@intel.com>
5403
5404 * c-warn.c (warn_for_address_or_pointer_of_packed_member):
5405 Replace "may may" with "may" in warning message.
5406
d8fcab68
JJ
54072019-01-07 Jakub Jelinek <jakub@redhat.com>
5408
5409 PR c++/85052
5410 * c-common.h (enum rid): Add RID_BUILTIN_CONVERTVECTOR.
5411 (c_build_vec_convert): Declare.
5412 * c-common.c (c_build_vec_convert): New function.
5413
29d24852
MS
54142019-01-04 Martin Sebor <msebor@redhat.com>
5415
5416 PR c/88546
5417 * c-attribs.c (handle_copy_attribute): Avoid copying attribute leaf.
5418 Handle C++ empty throw specification and C11 _Noreturn.
5419 (has_attribute): Also handle C11 _Noreturn.
5420
9069a4c9
MS
54212019-01-04 Martin Sebor <msebor@redhat.com>
5422
5423 PR c/88363
5424 * c-attribs.c (positional_argument): Also accept enumerated types.
5425
a5544970
JJ
54262019-01-01 Jakub Jelinek <jakub@redhat.com>
5427
5428 Update copyright years.
5429
da77eace
L
54302018-12-20 H.J. Lu <hongjiu.lu@intel.com>
5431
5432 PR c/51628
5433 * c-common.h (warn_for_address_or_pointer_of_packed_member): New.
5434 * c-warn.c (check_alignment_of_packed_member): New function.
5435 (check_address_of_packed_member): Likewise.
5436 (check_and_warn_address_of_packed_member): Likewise.
5437 (warn_for_address_or_pointer_of_packed_member): Likewise.
5438 * c.opt: Add -Wno-address-of-packed-member.
5439
573767d4
DM
54402018-12-20 David Malcolm <dmalcolm@redhat.com>
5441
5442 PR c++/87504
5443 * c-warn.c (get_outermost_macro_expansion): New function.
5444 (spelled_the_same_p): Use it to unwind the macro expansions, and
5445 compare the outermost macro in each nested expansion, rather than
5446 the innermost.
5447
a14feb3c
DM
54482018-12-19 David Malcolm <dmalcolm@redhat.com>
5449
5450 PR c++/87504
5451 * c-common.h (warn_tautological_cmp): Convert 1st param from
5452 location_t to const op_location_t &.
5453 * c-warn.c (find_array_ref_with_const_idx_r): Call fold_for_warn
5454 when testing for INTEGER_CST.
5455 (warn_tautological_bitwise_comparison): Convert 1st param from
5456 location_t to const op_location_t &; use it to build a
5457 binary_op_rich_location, and use this.
5458 (spelled_the_same_p): New function.
5459 (warn_tautological_cmp): Convert 1st param from location_t to
5460 const op_location_t &. Warn for macro expansions if
5461 spelled_the_same_p. Use binary_op_rich_location.
5462
dfd7fdca
DM
54632018-12-19 David Malcolm <dmalcolm@redhat.com>
5464
5465 PR c++/43064
5466 PR c++/43486
5467 * c-common.c (unsafe_conversion_p): Fold any location wrapper.
5468 (verify_tree): Handle location wrappers.
5469 (c_common_truthvalue_conversion): Strip any location wrapper.
5470 Handle CONST_DECL.
5471 (fold_offsetof): Strip any location wrapper.
5472 (complete_array_type): Likewise for initial_value.
5473 (convert_vector_to_array_for_subscript): Call fold_for_warn on the
5474 index before checking for INTEGER_CST.
5475 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
5476 print parentheses around location wrappers.
5477 * c-warn.c (warn_logical_operator): Call fold_for_warn on op_right
5478 before checking for INTEGER_CST.
5479 (warn_tautological_bitwise_comparison): Call
5480 tree_strip_any_location_wrapper on lhs, rhs, and bitop's operand
5481 before checking for INTEGER_CST.
5482 (readonly_error): Strip any location wrapper.
5483 (warn_array_subscript_with_type_char): Strip location wrappers
5484 before checking for INTEGER_CST. Use the location of the index if
5485 available.
5486
5c8b3702
JM
54872018-12-06 Jason Merrill <jason@redhat.com>
5488
5489 PR c++/88136 - -Wdeprecated-copy false positives
5490 * c.opt (Wdeprecated-copy-dtor): New.
5491 (Wdeprecated-copy): Move to -Wextra.
5492
673670da
MS
54932018-11-29 Martin Sebor <msebor@redhat.com>
5494
5495 PR c/88172
5496 PR testsuite/88208
5497 * c-attribs.c (common_handle_aligned_attribute): Silently avoid setting
5498 alignments to values less than the target requires.
5499 (has_attribute): For attribute aligned consider both the attribute
5500 and the alignment bits.
5501 * c-common.c (c_init_attributes): Optionally issue a warning for
5502 zero alignment.
5503
04864ec8
MS
55042018-11-28 Martin Sebor <msebor@redhat.com>
5505
5506 PR c/88065
5507 PR c/87297
5508 * c-warn.c (sizeof_pointer_memaccess_warning): Bail if source
5509 or destination is an error.
5510
ace83db0
JJ
55112018-11-28 Jakub Jelinek <jakub@redhat.com>
5512
5513 PR c++/88215
5514 * c-ubsan.c: Include langhooks.h.
5515 (ubsan_instrument_division): Change gcc_assert that main variants
5516 of op0 and op1 types are equal to gcc_checking_assert that the
5517 main variants are compatible types.
5518
da193a27
EB
55192018-11-27 Eric Botcazou <ebotcazou@adacore.com>
5520
5521 * c-ada-spec.c: Include stringpool.h.
5522 (has_static_fields): Return false for incomplete types.
5523 (is_tagged_type): Likewise.
5524 (has_nontrivial_methods): Likewise.
5525 (dump_ada_node) <INTEGER_TYPE>: Deal specifically with __int128.
5526 (struct overloaded_name_hash): New structure.
5527 (struct overloaded_name_hasher): Likewise.
5528 (overloaded_names): New global variable.
5529 (init_overloaded_names): New static function.
5530 (overloaded_name_p): New predicate.
5531 (dump_ada_declaration) <TYPE_DECL>: Tidy up and set TREE_VISITED
5532 on the TYPE_STUB_DECL of the original type of a typedef, if any.
5533 <FUNCTION_DECL>: Bail out for an unsupported overloaded name.
5534 Remove always-true condition and dump forward types.
5535 (dump_ada_specs): Delete overloaded_names.
5536
98f08eb8
MS
55372018-11-20 Martin Sebor <msebor@redhat.com>
5538
5539 * c-attribs.c (type_for_vector_size): New function.
5540 (type_valid_for_vector_size): Same.
5541 (handle_vector_size_attribute): Move code to the functions above
5542 and call them.
5543 (validate_attribute, has_attribute): New functions.
5544 * c-common.h (has_attribute): Declare.
5545 (rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
5546 * c-common.c (c_common_resword): Same.
5547
2674fa47
JM
55482018-11-16 Jason Merrill <jason@redhat.com>
5549
5550 * c-lex.c (c_common_has_attribute): Handle likely/unlikely.
5551 * c-attribs.c (attr_cold_hot_exclusions): Make public.
5552
258b3854
JJ
55532018-11-16 Jakub Jelinek <jakub@redhat.com>
5554
5555 PR middle-end/87854
5556 * c-common.c (fix_string_type): Reject string literals larger than
5557 TYPE_MAX_VALUE (ssizetype) bytes.
5558
1d249509
MS
55592018-11-15 Martin Sebor <msebor@redhat.com>
5560
5561 PR c++/87541
5562 PR c++/87542
5563 * c-attribs.c (positional_argument): New function.
5564 (handle_alloc_size_attribute): Use it and simplify.
5565 (handle_alloc_align_attribute): Same.
5566 (handle_assume_aligned_attribute): Same.
5567 (handle_nonnull_attribute): Same.
5568 * c-common.c (check_function_arguments): Pass fntype to
5569 check_function_format.
5570 * c-common.h (check_function_format): Add an argument.
5571 (PosArgFlags, positional_argument): Declare new type and function.
5572 * c-format.c (decode_format_attr): Add arguments.
5573 (check_format_string, get_constant): Same.
5574 (convert_format_name_to_system_name): Adjust.
5575
478dd60d
DM
55762018-11-15 David Malcolm <dmalcolm@redhat.com>
5577
5578 PR other/19165
5579 * c-opts.c (c_diagnostic_finalizer): Add diagnostic_t param.
5580
8cca0163
JJ
55812018-11-14 Jakub Jelinek <jakub@redhat.com>
5582
8ee09943
JJ
5583 P1236R1 - Signed integers are two's complement
5584 * c-warn.c (maybe_warn_shift_overflow): Don't warn for c++2a.
5585 * c-ubsan.c (ubsan_instrument_shift): Make signed shifts
5586 with in-range second operand well defined for -std=c++2a.
5587
8cca0163
JJ
5588 PR other/88007
5589 * c-common.c (parse_optimize_options): Allocate option string from
5590 opts_obstack rather than as GC memory. Move the allocation after
5591 warning for invalid option.
5592
620e594b
DM
55932018-11-13 David Malcolm <dmalcolm@redhat.com>
5594
5595 * c-common.c (c_get_substring_location): Update for renaming of
5596 get_source_location_for_substring to get_location_within_string.
5597 * c-lex.c: Replace "source_location" with "location_t".
5598 * c-opts.c: Likewise.
5599 * c-ppoutput.c: Likewise.
5600
f9731de3
MS
56012018-11-13 Martin Sebor <msebor@redhat.com>
5602
5603 PR middle-end/81824
5604 * c-attribs.c (handle_copy_attribute): Exclude inlining attributes.
5605 (handle_tls_model_attribute): Improve diagnostics.
5606
e4bd6d5e
JM
56072018-11-12 Jason Merrill <jason@redhat.com>
5608
a6bb6b07
JM
5609 * c-cppbuiltin.c (c_cpp_builtins): Define
5610 __cpp_impl_destroying_delete.
5611
e4bd6d5e
JM
5612 * c-cppbuiltin.c (c_cpp_builtins): Change __cpp_explicit_bool to
5613 __cpp_conditional_explicit.
5614
79a2c428
MS
56152018-11-09 Martin Sebor <msebor@redhat.com>
5616
5617 PR middle-end/81824
5618 * c-attribs.c (handle_copy_attribute): New function.
5619
4c7bd361
MS
56202018-11-09 Martin Sebor <msebor@redhat.com>
5621
5622 PR c/87795
5623 * c-common.c (check_user_alignment): Use MAX_OFILE_ALIGNMENT.
5624
28567c40
JJ
56252018-11-08 Jakub Jelinek <jakub@redhat.com>
5626
5627 * c-common.h (c_finish_omp_taskgroup): Add CLAUSES argument.
5628 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
5629 enum omp_memory_order MEMORY_ORDER.
5630 (c_finish_omp_flush): Add MO argument.
5631 (c_omp_depend_t_p, c_finish_omp_depobj): Declare.
5632 (c_finish_omp_for): Add FINAL_P argument.
5633 * c-omp.c: Include memmodel.h.
5634 (c_finish_omp_taskgroup): Add CLAUSES argument. Set
5635 OMP_TASKGROUP_CLAUSES to it.
5636 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
5637 enum omp_memory_order MEMORY_ORDER. Set OMP_ATOMIC_MEMORY_ORDER
5638 instead of OMP_ATOMIC_SEQ_CST.
5639 (c_omp_depend_t_p, c_finish_omp_depobj): New functions.
5640 (c_finish_omp_flush): Add MO argument, if not MEMMODEL_LAST, emit
5641 __atomic_thread_fence call with the given value.
5642 (check_omp_for_incr_expr): Formatting fixes.
5643 (c_finish_omp_for): Add FINAL_P argument. Allow NE_EXPR
5644 even in OpenMP loops, diagnose if NE_EXPR and incr expression
5645 is not constant expression 1 or -1. Transform NE_EXPR loops
5646 with iterators pointers to VLA into LT_EXPR or GT_EXPR loops.
5647 (c_omp_check_loop_iv_r): Look for orig decl of C++ range for
5648 loops too.
5649 (c_omp_split_clauses): Add support for combined
5650 #pragma omp parallel master and
5651 #pragma omp {,parallel }master taskloop{, simd} constructs.
5652 Handle OMP_CLAUSE_IN_REDUCTION. Handle OMP_CLAUSE_REDUCTION_TASK.
5653 Handle OMP_CLAUSE_NONTEMPORAL. Handle splitting OMP_CLAUSE_IF
5654 also to OMP_SIMD. Copy OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
5655 (c_omp_predetermined_sharing): Don't return
5656 OMP_CLAUSE_DEFAULT_SHARED for const qualified decls.
5657 * c-pragma.c (omp_pragmas): Add PRAGMA_OMP_DEPOBJ and
5658 PRAGMA_OMP_REQUIRES.
5659 * c-pragma.h (enum pragma_kind): Likewise.
5660 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_NONTEMPORAL
5661 and PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
5662
204839e7
DM
56632018-11-08 David Malcolm <dmalcolm@redhat.com>
5664
5665 * c-format.c (gcc_dump_printf_char_table): Add entry for %f.
5666
d8010ee4
DM
56672018-11-08 David Malcolm <dmalcolm@redhat.com>
5668
5669 * c-format.c (local_cgraph_node_ptr_node): New variable.
5670 (gcc_dump_printf_char_table): Add entry for %C.
5671 (get_pointer_to_named_type): New function, taken from the handling
5672 code for "gimple *" from...
5673 (init_dynamic_diag_info): ...here. Add handling for
5674 "cgraph_node *".
5675 * c-format.h (T_CGRAPH_NODE): New.
5676
4be5c72c
JM
56772018-10-19 Jason Merrill <jason@redhat.com>
5678
5679 * c-cppbuiltin.c (c_cpp_builtins): Add
5680 __cpp_nontype_template_parameter_class.
5681
f3f6029d
NS
56822018-10-31 Nathan Sidwell <nathan@acm.org>
5683
ab5324fb
NS
5684 * c-opts.c (c_finish_options): Force command line macro
5685 location. Refactor to avoid repeating main debug hook.
5686 (push_command_line_include): Clarify comment.
5687
f3f6029d
NS
5688 * c-opts.c (c_finish_options): Adjust cpp_force_token_locations call.
5689
91e3ec29
MS
56902018-10-30 Martin Sebor <msebor@redhat.com>
5691
5692 PR middle-end/87041
5693 * c-format.c (check_format_types): Avoid diagnosing null pointer
5694 arguments to printf-family of functions.
5695
b5ff4f5c
MP
56962018-10-30 Marek Polacek <polacek@redhat.com>
5697
5698 Implement P0892R2, explicit(bool).
5699 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
5700
7e2de6df
DM
57012018-10-29 David Malcolm <dmalcolm@redhat.com>
5702
5703 * name-hint.h (name_hint::take_deferred): New member function.
5704
b2bf438c
DM
57052018-10-29 David Malcolm <dmalcolm@redhat.com>
5706
5707 PR c++/56856
5708 * c-common.c (check_function_sentinel): Call fold_for_warn on the
5709 argument.
5710 (check_function_restrict): Rename param "argarray" to
5711 "unfolded_argarray", and make a copy named "argarray", calling
5712 fold_for_warn on each argument.
5713 (check_function_arguments): Add note about responsibility for
5714 folding the arguments.
5715
9f936c86
JM
57162018-10-17 Joseph Myers <joseph@codesourcery.com>
5717
5718 * c-common.c (flag_isoc2x): New variable.
5719 * c-common.h (clk_c): Update comment to reference C2X.
5720 (flag_isoc99, flag_isoc11): Update comments to reference future
5721 standard versions in general.
5722 (flag_isoc2x): Declare.
5723 * c-opts.c (set_std_c2x): New function.
5724 (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
5725 (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
5726 flag_isoc2x to 0.
5727 * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
5728
7a8a92c4
JM
57292018-10-17 Joseph Myers <joseph@codesourcery.com>
5730
5731 * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
5732 (std=iso9899:2018): Document C17 as published in 2018.
5733
4dc003ff
CL
57342018-10-12 Christophe Lyon <christophe.lyon@linaro.org>
5735
5736 PR c++/87364
5737 * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
5738
79371671
WW
57392018-10-11 Will Wray <wjwray@gmail.com>
5740
5741 PR c++/87364
5742 * c-pretty-print.h (pp_c_type_cast): Prototype.
5743 (pp_c_integer_constant): Likewise.
5744 * c-pretty-print.c (pp_c_type_cast): No longer static.
5745 (pp_c_integer_constant): Likewise.
5746 (pp_c_enumeration_constant): Fix loop termination when finding
5747 name of constant. No longer returns a value. Call
5748 pp_c_integer_constant.
5749 (c_pretty_printer::constant): Update for changes to
5750 pp_c_enumeration_constant.
5751
46c62690
JJ
57522018-10-11 Jakub Jelinek <jakub@redhat.com>
5753
5754 * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
5755 for no_unique_address.
5756
c24300ba
DM
57572018-10-09 David Malcolm <dmalcolm@redhat.com>
5758
5759 * c-common.c (c_option_controlling_cpp_error): Rename to...
5760 (c_option_controlling_cpp_diagnostic): ...this, and convert
5761 "reason" from int to enum.
5762 (c_cpp_error): Rename to...
5763 (c_cpp_diagnostic): ...this, converting level and reason to enums.
5764 * c-common.h (c_cpp_error): Rename to...
5765 (c_cpp_diagnostic): ...this, converting level and reason to enums.
5766 * c-opts.c (c_common_init_options): Update for renaming.
5767
8656dafa
RS
57682018-10-08 Richard Sandiford <richard.sandiford@arm.com>
5769
5770 PR c/87286
5771 * c-common.c (vector_types_compatible_elements_p): Use
5772 INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
5773
8cff0652
VK
57742018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
5775
5776 * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
5777 to generate constructor destructor priority warning.
5778 * c.opt (-Wprio-ctor-dtor): New option.
5779
bedf03a2
JM
57802018-10-01 Jason Merrill <jason@redhat.com>
5781
5782 * c-lex.c (c_common_has_attribute): Add no_unique_address.
5783
6cc430c1
EB
57842018-10-01 Eric Botcazou <ebotcazou@adacore.com>
5785
5786 * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
5787 (dump_ada_node): Add const keyword.
5788
87677ac7
ML
57892018-09-25 Martin Liska <mliska@suse.cz>
5790
5791 * c-common.c (c_common_truthvalue_conversion):
5792 Remove Pascal from documentation.
5793
518196cb
EB
57942018-09-21 Eric Botcazou <ebotcazou@adacore.com>
5795
5796 * c-ada-spec.c: Include diagnostic.h.
5797 (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
5798
a599af84
MP
57992018-09-19 Marek Polacek <polacek@redhat.com>
5800
5801 * c.opt (Wclass-conversion): New.
5802
9c4a4b3c
DM
58032018-09-17 David Malcolm <dmalcolm@redhat.com>
5804
5805 * c-format.c (range_label_for_format_type_mismatch::get_text):
5806 Update for new param.
5807
c896ecfe
DM
58082018-09-17 David Malcolm <dmalcolm@redhat.com>
5809
5810 * c-format.c (format_warning_at_char): Update for introduction of
5811 format_string_diagnostic_t.
5812 (format_type_warning): Likewise.
5813
80c6d1f4
MJ
58142018-09-17 Martin Jambor <mjambor@suse.cz>
5815
5816 PR c/63886
5817 * c.opt (Wabsolute-value): New.
5818
6d900107
BE
58192018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
5820
5821 * c-common.c (complete_flexible_array_elts): New helper function.
5822 * c-common.h (complete_flexible_array_elts): Declare.
5823
b5764229
BE
58242018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
5825
5826 * c-common.c (braced_list_to_string): Remove eval parameter.
5827 Add some more checks. Always create zero-terminated STRING_CST.
5828 * c-common.h (braced_list_to_string): Adjust prototype.
5829
85204e23
DM
58302018-08-27 David Malcolm <dmalcolm@redhat.com>
5831
5832 PR 87091
5833 * c-common.c (c_cpp_error): Update for conversion of show_caret_p
5834 to a tri-state.
5835 (maybe_suggest_missing_token_insertion): Likewise.
5836 (maybe_add_include_fixit): Add param "override_location". If set,
5837 and source-printing is enabled, then override the rich_location's
5838 primary location with that of the insertion point for the fix-it
5839 hint, marking it with SHOW_LINES_WITHOUT_RANGE.
5840 * c-common.h (extern void maybe_add_include_fixit): Add bool
5841 param.
5842 * c-format.c (selftest::test_type_mismatch_range_labels): Update
5843 for conversion of show_caret_p to a tri-state.
5844 * c-warn.c (warn_for_restrict): Likewise.
5845 * known-headers.cc
5846 (suggest_missing_header::~suggest_missing_header): Update call to
5847 maybe_add_include_fixit to suggest overriding the location, as it
5848 is for a note.
5849
3d78e008
ML
58502018-08-27 Martin Liska <mliska@suse.cz>
5851
5852 * c-common.c (check_function_restrict): Use new function
92a285c1
ML
5853 fndecl_built_in_p and remove check for FUNCTION_DECL if
5854 possible.
3d78e008
ML
5855 (check_builtin_function_arguments): Likewise.
5856 (reject_gcc_builtin): Likewise.
5857 * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
5858
b5be6d0c
MP
58592018-08-26 Marek Polacek <polacek@redhat.com>
5860
5861 PR c++/87029, Implement -Wredundant-move.
5862 * c.opt (Wredundant-move): New option.
5863
79ca9c35
MP
58642018-08-21 Marek Polacek <polacek@redhat.com>
5865
5866 PR c++/86981, Implement -Wpessimizing-move.
5867 * c.opt (Wpessimizing-move): New option.
5868
097f82ec
DM
58692018-08-20 David Malcolm <dmalcolm@redhat.com>
5870
5871 PR other/84889
5872 * c-attribs.c (common_handle_aligned_attribute): Add
5873 auto_diagnostic_group instance.
5874 * c-indentation.c (warn_for_misleading_indentation): Likewise.
5875 * c-opts.c (c_common_post_options): Likewise.
5876 * c-warn.c (warn_logical_not_parentheses): Likewise.
5877 (warn_duplicated_cond_add_or_warn): Likewise.
5878 (warn_for_multistatement_macros): Likewise.
5879
3fb558b1
NS
58802018-08-20 Nathan Sidwell <nathan@acm.org>
5881
5882 * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
5883 access.
5884
800c0e98
NS
58852018-08-17 Nathan Sidwell <nathan@acm.org>
5886
5887 * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
5888 field.
5889 (laxy_hex_fp_value_count): Make unsigned.
5890 (lazy_hex_fp_value): Provided with macro & lazy number. Directly
5891 manipulate the macro.
5892 (builtin_defin_with_hex_fp_value): Adjust callback name, use
5893 cpp_define_lazily.
5894
6f795a92
DM
58952018-08-17 David Malcolm <dmalcolm@redhat.com>
5896
5897 * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
5898 (gcc_dump_printf_length_specs): New.
5899 (gcc_dump_printf_flag_pairs): New.
5900 (gcc_dump_printf_flag_specs): New.
5901 (gcc_dump_printf_char_table): New.
5902 (format_types_orig): Add entry for "gcc_dump_printf".
5903 (init_dynamic_diag_info): Set up length_char_specs and
5904 conversion_specs for gcc_dump_printf_format_type.
5905 (handle_format_attribute): Handle gcc_dump_printf_format_type.
5906
c5d725c0
NS
59072018-08-17 Nathan Sidwell <nathan@acm.org>
5908
10f04917
NS
5909 * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
5910
c5d725c0
NS
5911 * c-ada-spec.c: Don't #include "cpp-id-data.h"
5912 * c-cppbuiltin.c: Likewise.
5913
c0c12356
ML
59142018-08-17 Martin Liska <mliska@suse.cz>
5915
5916 * c.opt: Remove Warn, Init and Report for options with
92a285c1
ML
5917 Ignore/Deprecated flag. Warning is done automatically for
5918 Deprecated flags.
c0c12356 5919
10fcc142
DM
59202018-08-16 David Malcolm <dmalcolm@redhat.com>
5921
5922 PR c++/70693
5923 * c-common.c (selftest::c_family_tests): Call
5924 selftest::c_indentation_c_tests.
5925 * c-common.h (selftest::c_indentation_c_tests): New decl.
5926 * c-indentation.c: Include "selftest.h".
5927 (next_tab_stop): Add "tab_width" param, rather than accessing
5928 cpp_opts.
5929 (get_visual_column): Likewise. Clarify comment. Bulletproof
5930 against reading past the end of the line.
5931 (get_first_nws_vis_column): Add "tab_width" param.
5932 (detect_intervening_unindent): Likewise.
5933 (should_warn_for_misleading_indentation): Read tab width from
5934 cpp_opts and pass around.
5935 (selftest::test_next_tab_stop): New test.
5936 (selftest::assert_get_visual_column_succeeds): New function.
5937 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
5938 (selftest::assert_get_visual_column_fails): New function.
5939 (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
5940 (selftest::test_get_visual_column): New test.
5941 (selftest::c_indentation_c_tests): New function.
5942
3f6677f4
NS
59432018-08-16 Nathan Sidwell <nathan@acm.org>
5944
5945 * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
5946 (store_ada_macro): Likewise.
5947 * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
5948 * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
5949
96e6ae57
DM
59502018-08-15 David Malcolm <dmalcolm@redhat.com>
5951
5952 * c-format.c: Include "selftest-diagnostic.h" and
5953 "gcc-rich-location.h".
5954 (format_warning_at_char): Pass NULL for new label params of
5955 format_warning_va.
5956 (class indirection_suffix): New class.
5957 (class range_label_for_format_type_mismatch): New class.
5958 (format_type_warning): Move logic for generating "*" suffix to
5959 class indirection_suffix. Create "fmt_label" and "param_label"
5960 to show their types, and pass them to the
5961 format_warning_at_substring calls.
5962 (selftest::test_type_mismatch_range_labels): New test.
5963 (selftest::c_format_c_tests): Call it.
5964
23aa9f7c
MS
59652018-08-13 Martin Sebor <msebor@redhat.com>
5966
5967 PR tree-optimization/71625
5968 * c-common.c (braced_list_to_string): New function.
5969 * c-common.h (braced_list_to_string): Declare it.
5970
f10a9135
NS
59712018-08-08 Nathan Sidwell <nathan@acm.org>
5972
5973 * c-common.c (try_to_locate_new_include_inertion_point): Use
5974 linemap_included_from_linemap.
5975 * c-lex.c (fe_file_change): Use linemap_included_from.
5976 * c-ppoutput.c (pp_file_change): Likewise.
5977
8a45b051
MS
59782018-08-01 Martin Sebor <msebor@redhat.com>
5979
5980 PR tree-optimization/86650
ab20d992 5981 * c-format.c (gcc_tdiag_char_table): Update comment for "%G".
8a45b051
MS
5982 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
5983 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
5984 * c-format.h (T89_G): Update to be "gimple *" rather than
5985 "gcall *".
5986 (local_gcall_ptr_node): Rename...
5987 (local_gimple_ptr_node): ...to this.
5988
e540ccc0
DM
59892018-07-31 David Malcolm <dmalcolm@redhat.com>
5990
5991 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
5992 table entries for gcc_diag_char_table, and the 'Z' entry from
5993 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
5994 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
5995 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
5996 adding missing "Z" for this table. Remove erroneous "G" and "K"
5997 entries.
5998 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
5999 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
6000 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
6001
425fc685
RE
60022018-07-31 Richard Earnshaw <rearnsha@arm.com>
6003
6004 * c-common.c (speculation_safe_resolve_call): New function.
6005 (speculation_safe_resolve_params): New function.
6006 (speculation_safe_resolve_return): New function.
6007 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
6008 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
6009 __HAVE_SPECULATION_SAFE_VALUE.
6010
181463c2
DM
60112018-07-20 David Malcolm <dmalcolm@redhat.com>
6012
6013 * c-common.c (c_cpp_error): Remove redundant "line_table"
6014 parameter from call to rich_location::set_range.
6015 (maybe_suggest_missing_token_insertion): Likewise.
6016
0d7f9065
MS
60172018-07-20 Martin Sebor <msebor@redhat.com>
6018
6019 PR middle-end/82063
ab20d992 6020 * c.opt (-Warray-bounds): Remove redundant -Wall.
0d7f9065 6021
00abf86c
MS
60222018-07-20 Martin Sebor <msebor@redhat.com>
6023
6024 PR middle-end/82063
6025 * c-common.h (c_common_handle_option): Change function argument
6026 to HOST_WIDE_INT.
6027 * c-opts.c (c_common_init_options): Same.
6028 (c_common_handle_option): Same. Remove special handling of
6029 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
6030 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
6031 options to take a HOST_WIDE_INT argument and accept a byte-size
6032 suffix. Initialize.
6033 (-Wvla-larger-than): Same.
6034 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
6035 (-Wno-vla-larger-than): Same.
6036
9b452033
JJ
60372018-07-12 Jakub Jelinek <jakub@redhat.com>
6038
6039 * c-attribs.c (c_common_attribute_table): Add
6040 "omp declare target implicit" attribute.
6041
cd0762f3
RB
60422018-07-12 Richard Biener <rguenther@suse.de>
6043
6044 PR c/86453
6045 * c-attribs.c (handle_packed_attribute): Do not build a variant
6046 type with TYPE_PACKED, instead ignore the attribute if we may
6047 not apply to the original type.
6048
0b27c3ed
JJ
60492018-07-10 Jakub Jelinek <jakub@redhat.com>
6050
6051 PR c++/86443
6052 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
6053 to contain TREE_LIST for both the original class iterator and the
6054 "last" helper var.
6055
e730a0ef
EB
60562018-07-07 Eric Botcazou <ebotcazou@adacore.com>
6057
6058 * c-ada-spec.c (to_ada_name): Remove index parameter.
6059 (pp_ada_tree_identifier): Likewise.
6060 (dump_ada_macros): Adjust call to to_ada_name.
6061 (struct overloaded_name_hash): Delete.
6062 (struct overloaded_name_hasher): Likewise.
6063 (overloaded_names): Likewise.
6064 (compute_overloading_index): Likewise.
6065 (dump_ada_decl_name): Do not call compute_overloading_index and
6066 adjust calls to pp_ada_tree_identifier.
6067 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
6068 (dump_ada_import): Add spc parameter and switch to aspect syntax.
6069 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
6070 (dump_ada_enum_type): Remove type and display_convention parameters.
6071 Adjust calls to pp_ada_tree_identifier.
6072 (dump_ada_node): Likewise and for dump_ada_structure.
6073 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
6074 and tidy up.
6075 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
6076 syntax.
6077 (print_constructor): Adjust call to pp_ada_tree_identifier.
6078 (print_destructor): Likewise.
6079 (dump_ada_declaration): Switch to aspect syntax.
6080 (dump_ada_structure): Likewise and tidy up. Replace display_convention
6081 parameter with nested parameter.
6082 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
6083 (dump_ada_specs): Do not delete overloaded_names table.
6084
8de583fc
PB
60852018-07-06 Peter Bergner <bergner@linux.ibm.com>
6086
6087 PR target/86324
e730a0ef 6088 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
8de583fc
PB
6089 target hook.
6090
09cff37b
NS
60912018-07-05 Nathan Sidwell <nathan@acm.org>
6092
6093 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
6094 NO_IMPLICIT_EXTERN_C.
6095
98086b2b
ML
60962018-06-28 Martin Liska <mliska@suse.cz>
6097
6098 * cppspec.c: Include opt-suggestions.h.
6099
ab20d992
JJ
61002018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
6101 Thomas Schwinge <thomas@codesourcery.com>
829c6349
CLT
6102 Cesar Philippidis <cesar@codesourcery.com>
6103
6104 * c-pragma.h (enum pragma_omp_clause): Add
6105 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
6106 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
6107
f41b7612
JJ
61082018-06-20 Jakub Jelinek <jakub@redhat.com>
6109
6110 PR c++/86210
6111 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
6112 comment.
6113
4252ccd7
MS
61142018-06-18 Martin Sebor <msebor@redhat.com>
6115
6116 PR middle-end/85602
6117 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
6118 nonstring.
6119
e197e64e
KV
61202018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
6121
6122 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
6123
34a7a230
JM
61242018-06-13 Jason Merrill <jason@redhat.com>
6125
5cef3733
JM
6126 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
6127 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
6128 handling.
6129
34a7a230
JM
6130 PR c++/86094 - wrong code with defaulted move ctor.
6131 * c-opts.c (c_common_post_options): Bump the current ABI version to
6132 13. Set warn_abi_version and flag_abi_compat_version to the current
6133 version rather than 0. Fix defaulting flag_abi_compat_version from
6134 warn_abi_version.
6135
bb0f14ae
MS
61362018-06-12 Martin Sebor <msebor@redhat.com>
6137
6138 PR c/85931
6139 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
6140 sizeof source and destination yields the same value.
6141
3713f2e2
ML
61422018-06-12 Martin Liska <mliska@suse.cz>
6143
6144 * c.opt: Make MPX-related options as Deprecated.
6145
4af78ef8
DM
61462018-06-08 David Malcolm <dmalcolm@redhat.com>
6147
6148 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
6149 rather than 0.
6150
31db0fe0
ML
61512018-06-08 Martin Liska <mliska@suse.cz>
6152
6153 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
6154 for MPX (macros, related functions, fields in cgraph_node, ...).
6155 (handle_bnd_legacy): Likewise.
6156 (handle_bnd_instrument): Likewise.
6157 * c.opt: Likewise.
6158
fe16acf2
JJ
61592018-06-06 Jakub Jelinek <jakub@redhat.com>
6160
6161 PR c++/86068
6162 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
6163 __cpp_transactional_memory to 201500 instead of 210500.
6164
4dbdb49b
JM
61652018-06-06 Jason Merrill <jason@redhat.com>
6166
6167 PR c++/85710 - ICE with -Wmemset-elt-size.
6168 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
6169
f8ad043f
JM
61702018-06-01 Jason Merrill <jason@redhat.com>
6171
6172 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
6173 201703.
6174
abc24d93
EB
61752018-06-01 Eric Botcazou <ebotcazou@adacore.com>
6176
6177 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
6178 declaration for a typedef independently of whether the declaration of
6179 the subtype is generated.
6180
d258f4aa
MS
61812018-05-31 Martin Sebor <msebor@redhat.com>
6182
6183 PR c/82063
6184 * c.opt (-Wno-alloc-size-larger-than): New option.
6185
b67b9225
DP
61862018-04-22 David Pagan <dave.pagan@oracle.com>
6187
6188 PR c/55976
6189 * c-opts.c (c_common_post_options): Set default for warn_return_type
ab20d992 6190 for C++/C++ with ObjC extensions only. For C, makes it possible to
b67b9225
DP
6191 differentiate between default (no option), -Wreturn-type, and
6192 -Wno-return-type.
6193
04eb9c55
JM
61942018-05-29 Jason Merrill <jason@redhat.com>
6195
6196 * c.opt (Winit-list-lifetime): New flag.
6197
b0c31bc6
BE
61982018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
6199
6200 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
6201 splay_tree_delete_pointers.
6202
44284983
JJ
62032018-05-26 Jakub Jelinek <jakub@redhat.com>
6204
6205 PR bootstrap/85921
6206 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
6207 noinline variable to workaround broken kernel headers.
6208
b46b715d
JM
62092018-05-18 Jason Merrill <jason@redhat.com>
6210
6211 * c.opt (Wdeprecated-copy): New flag.
6212
40659769
ML
62132018-05-17 Martin Liska <mliska@suse.cz>
6214
6215 * c-warn.c (overflow_warning): Do not use
6216 space in between 'G_' and '('.
6217
403962ea
JM
62182018-05-09 Jason Merrill <jason@redhat.com>
6219
6220 * c-common.c (valid_array_size_p): Add complain parameter.
6221 * c-common.h: ...which defaults to true.
6222
1c9ee609
JJ
62232018-05-11 Jakub Jelinek <jakub@redhat.com>
6224
6225 PR c/85696
6226 * c-omp.c (c_omp_predetermined_sharing): Return
6227 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
6228
19916065
ML
62292018-05-11 Martin Liska <mliska@suse.cz>
6230
92a285c1 6231 PR sanitizer/85556
19916065
ML
6232 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
6233 TREE_LIST values.
6234
79e7b1fe
JJ
62352018-05-10 Jakub Jelinek <jakub@redhat.com>
6236
6237 PR c++/85662
6238 * c-common.h (fold_offsetof_1): Removed.
6239 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
6240 CTX argument defaulted to ERROR_MARK.
6241 * c-common.c (fold_offsetof_1): Renamed to ...
6242 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
6243 argument, convert the pointer constant to TYPE and use size_binop
6244 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
6245 a pointer type. Adjust recursive calls.
6246
86c12f76
EB
62472018-05-10 Eric Botcazou <ebotcazou@adacore.com>
6248
6249 PR c++/85400
6250 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
6251
ee336e84
NS
62522018-05-07 Nathan Sidwell <nathan@acm.org>
6253
6254 * c.opt (ffor-scope): Remove functionality, issue warning.
6255
6c072e21
NS
62562018-05-03 Nathan Sidwell <nathan@acm.org>
6257
6258 * c.opt (ffriend-injection): Remove functionality, issue warning.
6259
2cc7d3a7
DM
62602018-05-01 David Malcolm <dmalcolm@redhat.com>
6261
6262 PR c/84258
6263 * c-format.c (struct format_check_results): Add field
6264 "number_non_char".
6265 (check_format_info): Initialize it, and warn if encountered.
6266 (check_format_arg): Distinguish between wide char and
6267 everything else when detecting arrays of non-char.
6268
7761dfbe
DM
62692018-04-30 David Malcolm <dmalcolm@redhat.com>
6270
6271 * c-format.c (get_corrected_substring): Update for
6272 location_get_source_line returning a char_span. Use a char_span
6273 when handling the prefix of the correction.
6274 * c-indentation.c (get_visual_column): Update for
6275 location_get_source_line returning a char_span.
6276 (get_first_nws_vis_column): Likewise.
6277
62e98ef1
DM
62782018-03-29 David Malcolm <dmalcolm@redhat.com>
6279
6280 PR c++/84269
6281 * known-headers.cc (get_stdlib_header_for_name): Add various names
6282 from <assert.h>, <string.h>, and <memory.h>; add more names from
6283 <stdio.h>.
6284
a7dea617
JJ
62852018-03-27 Jakub Jelinek <jakub@redhat.com>
6286
6287 PR c++/85061
6288 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
6289 get_base_address of the second operand is a VAR_P, rather than the
6290 operand itself, and use gcc_checking_assert instead of gcc_assert.
6291
889a3a30
MP
62922018-03-23 Marek Polacek <polacek@redhat.com>
6293
6294 PR c++/85045
6295 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
6296 <case RDIV_EXPR>: Tweak condition.
6297
452154b9
EB
62982018-03-20 Eric Botcazou <ebotcazou@adacore.com>
6299
6300 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
6301
63ecb626
JJ
63022018-03-16 Jakub Jelinek <jakub@redhat.com>
6303
ce811fc4
JJ
6304 PR c/84909
6305 * c-warn.c (conversion_warning): Replace "to to" with "to" in
6306 diagnostics.
6307
63ecb626
JJ
6308 PR c/84910
6309 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
6310 diagnostics.
6311
a1295eec
RB
63122018-03-16 Richard Biener <rguenther@suse.de>
6313
6314 PR c/84873
6315 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
6316 unshare the possibly folded expression.
6317
919674fb
RB
63182018-03-15 Richard Biener <rguenther@suse.de>
6319
6320 PR c/84873
6321 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
6322
f99309b2
MS
63232018-03-13 Martin Sebor <msebor@redhat.com>
6324
6325 PR tree-optimization/84725
6326 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
6327 with all three narrow character types, including their qualified forms.
6328
e9b9fa4c
MS
63292018-03-12 Martin Sebor <msebor@redhat.com>
6330
6331 PR tree-optimization/83456
ab20d992 6332 * c-common.c (check_function_restrict): Return bool.
e9b9fa4c
MS
6333 Restore checking of bounded built-in functions.
6334 (check_function_arguments): Also return the result
6335 of warn_for_restrict.
ab20d992
JJ
6336 * c-common.c (check_function_restrict): Return bool.
6337 * c-warn.c (warn_for_restrict): Return bool.
e9b9fa4c 6338
0805d020
MP
63392018-03-02 Marek Polacek <polacek@redhat.com>
6340
6341 PR c++/84171
6342 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
6343 is erroneous.
6344
ed2a2f08
TS
63452018-03-02 Thomas Schwinge <thomas@codesourcery.com>
6346
6347 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
6348 function".
6349
90abdde0
MP
63502018-03-01 Marek Polacek <polacek@redhat.com>
6351
6352 PR c++/84639
6353 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
6354 alignment in computation.
6355
c6db43fa
EB
63562018-02-28 Eric Botcazou <ebotcazou@adacore.com>
6357
6358 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
6359 <REAL_TYPE>: Deal specifically with _Float128/__float128.
6360
9e25c7ed
EB
63612018-02-28 Eric Botcazou <ebotcazou@adacore.com>
6362
6363 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
6364 (is_char_array): Take a type instead of a declaration.
6365 (dump_ada_array_type): Likewise.
6366 (is_simple_enum): Minor tweak.
6367 (dump_ada_enum_type): New function extracted from...
6368 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
6369 <INTEGER_TYPE>: Remove unreachable code.
6370 <RECORD_TYPE>: Likewise. Minor tweaks.
6371 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
6372 <ENUMERAL_TYPE>: New case.
6373 <RECORD_TYPE>: Factor out common code.
6374 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
6375 Minor tweaks. Deal with enumeral types.
6376 (dump_ada_structure): Minor tweaks.
6377
09de3550
EB
63782018-02-28 Eric Botcazou <ebotcazou@adacore.com>
6379
6380 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
6381 address for incomplete structures.
6382 (dump_forward_type): Do not bail out for incomplete structures.
6383 (dump_ada_declaration): Do not special-case incomplete structures
6384 for subtypes. Dump them as null records for types.
6385
095d8d4b
EB
63862018-02-28 Eric Botcazou <ebotcazou@adacore.com>
6387
6388 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
6389 (is_char_array): Fix formatting.
6390 (dump_template_types): Likewise.
6391 (dump_generic_ada_node): Rename into...
6392 (dump_ada_node): ...this.
6393 <POINTER_TYPE>: Remove superfluous space. Use generic address for
6394 incomplete structures and not for empty structures. Do not use it
6395 when forward declarations are needed.
6396 (dump_forward_type): New function.
6397 (dump_nested_types): Remove FORWARD parameter. Do not consider
6398 TREE_VISITED and do not generate a forward declaration. Only dump
6399 original nested types for nested declaration.
6400 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
6401 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
6402 <RECORD_TYPE>: Do not consider TREE_VISITED.
6403 (dump_ada_declaration): Use booleans and fix formatting throughout.
6404 <TYPE_DECL>: Skip incomplete structures and not empty structures.
6405 Call dump_forward_type instead of dump_nested_types for a typedef.
6406 Remove superfluous check and adjust call to dump_nested_types.
6407 <POINTER_TYPE>: Call dump_forward_type and fall through.
6408 (dump_ada_struct_decl): Rename into...
6409 (dump_ada_structure): ...this. Do not special-case empty structures.
6410
d4cfd486
MS
64112018-02-27 Martin Sebor <msebor@redhat.com>
6412
6413 PR c++/83871
6414 * c.opt (-Wmissing-attributes): New option.
6415
b22dbd03
ML
64162018-02-21 Martin Liska <mliska@suse.cz>
6417
6418 * c.opt (Wcatch-value=): Add IntegerRange.
6419
883dfe2a
JM
64202018-02-15 Jason Merrill <jason@redhat.com>
6421
6422 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
6423
0444aa9c
NS
64242018-02-09 Nathan Sidwell <nathan@acm.org>
6425
6426 PR c/84293
6427 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
6428 arg.
6429 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
6430 arg. Adjust.
6431
cea71f0a
MS
64322018-02-09 Martin Sebor <msebor@redhat.com>
6433
6434 PR lto/84212
6435 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
6436 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
6437 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
6438 (-Wstrict-overflow, -Wsuggest-attribute): Same.
6439 (-Wuninitialized): Same.
6440
8c8b7be5
EB
64412018-02-09 Eric Botcazou <ebotcazou@adacore.com>
6442
6443 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
6444 keyword for components.
6445
7c30b12a
PC
64462018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
6447
6448 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
6449
eece7fe5
JK
64502018-02-02 Julia Koval <julia.koval@intel.com>
6451
6452 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
6453
7d07a93a
MP
64542018-01-29 Marek Polacek <polacek@redhat.com>
6455
6456 PR c/83966
6457 * c-format.c (check_function_format): Check current_function_decl.
6458
53723269
JJ
64592018-01-27 Jakub Jelinek <jakub@redhat.com>
6460
6461 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
6462 argument.
6463 (LAZY_HEX_FP_VALUES_CNT): Define.
6464 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
6465 values rather than just 12.
6466 (builtin_define_with_hex_fp_value): Likewise.
6467
7365279f
BK
64682018-01-18 Boris Kolpackov <boris@codesynthesis.com>
6469
92a285c1
ML
6470 PR other/70268
6471 * c.opt (-fmacro-prefix-map): New option.
6472 * c-opts.c (c_common_handle_option): Handle it.
6473 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
6474 * c-ppoutput.c (init_pp_output): Likewise.
7365279f 6475
bb9869d5
DM
64762018-01-17 David Malcolm <dmalcolm@redhat.com>
6477
6478 PR c++/83814
6479 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
6480
68dc87c3
EB
64812018-01-10 Eric Botcazou <ebotcazou@adacore.com>
6482
6483 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
6484 Skip 'f' and 'F' characters if it is true.
6485 (store_ada_macro): Minor tweak.
6486 (dump_ada_macros) <CPP_COMMENT>: Likewise.
6487 <CPP_WSTRING>: Likewise.
6488 <CPP_STRING>: Output '&' in the buffer if not the first string.
6489 <CPP_NUMBER>: Adjust calls to dump_number.
6490
9a004410
DM
64912018-01-10 David Malcolm <dmalcolm@redhat.com>
6492
6493 PR c++/43486
6494 * c-common.c: Include "selftest.h".
6495 (get_atomic_generic_size): Perform the test for integral type
6496 before the range test for any integer constant, fixing indentation
6497 of braces. Call fold_for_warn before testing for an INTEGER_CST.
6498 (reject_gcc_builtin): Strip any location wrapper from EXPR.
6499 (selftest::test_fold_for_warn): New function.
6500 (selftest::c_common_c_tests): New function.
6501 (selftest::c_family_tests): Call it, and
6502 selftest::c_pretty_print_c_tests.
6503 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
6504 * c-format.c (check_format_arg): Convert VAR_P check to a
6505 fold_for_warn.
6506 * c-pretty-print.c: Include "selftest.h".
6507 (pp_c_cast_expression): Don't print casts for location wrappers.
6508 (selftest::assert_c_pretty_printer_output): New function.
6509 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
6510 (selftest::test_location_wrappers): New function.
6511 (selftest::c_pretty_print_c_tests): New function.
6512 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
6513
5c0caeb3
RS
65142018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
6515 Alan Hayward <alan.hayward@arm.com>
6516 David Sherwood <david.sherwood@arm.com>
6517
6518 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
6519
73a699ae
RS
65202018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
6521 Alan Hayward <alan.hayward@arm.com>
6522 David Sherwood <david.sherwood@arm.com>
6523
6524 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
6525 as polynomial.
6526
928686b1
RS
65272018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
6528 Alan Hayward <alan.hayward@arm.com>
6529 David Sherwood <david.sherwood@arm.com>
6530
6531 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
6532 (convert_vector_to_array_for_subscript): Handle polynomial
6533 TYPE_VECTOR_SUBPARTS.
6534 (c_common_type_for_mode): Check valid_vector_subparts_p.
6535 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
6536 VECTOR_CST_NELTS.
6537
85ec4feb
JJ
65382018-01-03 Jakub Jelinek <jakub@redhat.com>
6539
6540 Update copyright years.
6541
170a8bd6 65422017-12-22 Mike Stump <mikestump@comcast.net>
92a285c1 6543 Eric Botcazou <ebotcazou@adacore.com>
170a8bd6
EB
6544
6545 * c-pragma.c (init_pragma): Register pragma GCC unroll.
6546 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
6547
ab20d992 65482017-12-22 Alexandre Oliva <aoliva@redhat.com>
18408e96
AO
6549
6550 PR debug/83527
6551 PR debug/83419
6552 * c-semantics.c (only_debug_stmts_after_p): New.
6553 (pop_stmt_list): Clear side effects in debug-only stmt list.
6554 Check for single nondebug stmt followed by debug stmts only.
6555
c12d20d4
AO
65562017-12-21 Alexandre Oliva <aoliva@redhat.com>
6557
6558 PR debug/83419
6559 * c-semantics.c (pop_stmt_list): Propagate side effects from
6560 single nondebug stmt to container list.
6561
01512446
JJ
65622017-12-19 Jakub Jelinek <jakub@redhat.com>
6563
6564 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
6565 conditions with typical order conditions.
6566
82cfbd01
MP
65672017-12-18 Marek Polacek <polacek@redhat.com>
6568
6569 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
6570 not in effect.
6571
99da11ec
MS
65722017-12-17 Martin Sebor <msebor@redhat.com>
6573
6574 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
6575 an error for attribute warn_if_not_aligned.
6576
cc8bea0a
MS
65772017-12-16 Martin Sebor <msebor@redhat.com>
6578
6579 PR tree-optimization/78918
6580 * c-common.c (check_function_restrict): Avoid checking built-ins.
6581 * c.opt (-Wrestrict): Include in -Wall.
6582
4849deb1
JJ
65832017-12-15 Jakub Jelinek <jakub@redhat.com>
6584
6585 * c-attribs.c (c_common_attribute_table,
6586 c_common_format_attribute_table): Swap affects_type_identity
6587 and handler fields, adjust comments.
6588
c65e18d3
BE
65892017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
6590
6591 * c.opt (Wcast-function-type): New warning option.
6592 * c-lex.c (get_fileinfo): Avoid warning.
6593 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
6594
2004617a
QZ
65952017-12-14 Qing Zhao <qing.zhao@oracle.com>
6596
7365279f 6597 PR middle_end/79538
2004617a
QZ
6598 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
6599 Adjust the size of buf1 and buf2, add a new buf to avoid
6600 format-overflow warning.
6601
ab20d992 66022017-12-12 Alexandre Oliva <aoliva@redhat.com>
96a95ac1
AO
6603
6604 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
6605 subsequent statement list.
6606
5d9ae53d
MS
66072017-12-07 Martin Sebor <msebor@redhat.com>
6608
6609 PR c/81544
6610 PR c/81566
6611 * c-attribs.c (attr_aligned_exclusions): New array.
6612 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
6613 (attr_common_exclusions, attr_const_pure_exclusions): Same.
6614 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
6615 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
6616 (attr_warn_unused_result_exclusions): Same.
6617 (handle_hot_attribute, handle_cold_attribute): Simplify.
6618 (handle_const_attribute): Warn on function returning void.
6619 (handle_pure_attribute): Same.
6620 (handle_aligned_attribute): Diagnose conflicting attribute
6621 specifications.
6622 * c-warn.c (diagnose_mismatched_attributes): Simplify.
6623
c79144f8
DM
66242017-12-06 David Malcolm <dmalcolm@redhat.com>
6625
6626 PR c/83236
6627 * c-common.c (selftest::c_family_tests): Call
6628 selftest::c_spellcheck_cc_tests.
6629 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
6630 * c-spellcheck.cc: Include "selftest.h".
6631 (name_reserved_for_implementation_p): New function.
6632 (should_suggest_as_macro_p): New function.
6633 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
6634 should_suggest_as_macro_p and call it.
6635 (selftest::test_name_reserved_for_implementation_p): New function.
6636 (selftest::c_spellcheck_cc_tests): New function.
6637 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
6638
613bc14f
DM
66392017-12-06 David Malcolm <dmalcolm@redhat.com>
6640
6641 * c-spellcheck.cc: New file, taken from macro-handling code in
6642 spellcheck-tree.c.
6643 * c-spellcheck.h: New file, taken from macro-handling code in
6644 spellcheck-tree.h.
6645
e76c7157
JJ
66462017-12-01 Jakub Jelinek <jakub@redhat.com>
6647
6648 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
6649 attribute.
6650 (handle_simd_attribute): Don't check for "cilk simd function"
6651 attribute. Reindent, formatting changes.
6652
b0da4034
JK
66532017-11-30 Julia Koval <julia.koval@intel.com>
6654
6655 * c-common.h (inv_list): Remove.
6656
058f0b9e
JJ
66572017-11-28 Jakub Jelinek <jakub@redhat.com>
6658
6659 PR sanitizer/81275
6660 * c-common.c (c_switch_covers_all_cases_p_1,
6661 c_switch_covers_all_cases_p): New functions.
6662 * c-common.h (c_switch_covers_all_cases_p): Declare.
6663
5e9d6aa4 66642017-11-28 Julia Koval <julia.koval@intel.com>
92a285c1 6665 Sebastian Peryt <sebastian.peryt@intel.com>
5e9d6aa4
JK
6666
6667 * array-notation-common.c: Delete.
6668 * c-cilkplus.c: Ditto.
6669 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
6670 * c-common.def (ARRAY_NOTATION_REF): Remove.
6671 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
6672 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
6673 c_validate_cilk_plus_loop, cilkplus_an_parts,
6674 cilk_ignorable_spawn_rhs_op,
6675 cilk_recognize_spawn): Remove.
6676 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
6677 * c-omp.c: Remove CILK_SIMD check.
6678 * c-pragma.c: Ditto.
6679 * c-pragma.h: Remove CILK related pragmas.
6680 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
6681 ARRAY_NOTATION_REF condition.
6682 (c_pretty_printer::expression): Ditto.
6683 * c.opt (fcilkplus): Remove.
6684 * cilk.c: Delete.
6685
1af4ebf5
MG
66862017-11-21 Marc Glisse <marc.glisse@inria.fr>
6687
6688 * c-pretty-print.c (pp_c_additive_expression,
6689 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
6690
d44ed508
JJ
66912017-11-21 Jakub Jelinek <jakub@redhat.com>
6692
7d2f0f9b
JJ
6693 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
6694
d44ed508
JJ
6695 PR c++/83059
6696 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
6697 instead of tree_to_uhwi, formatting fix.
6698
26edace6
DM
66992017-11-20 David Malcolm <dmalcolm@redhat.com>
6700
6701 PR c/81404
6702 * known-headers.cc: New file, based on material from c/c-decl.c.
6703 (suggest_missing_header): Copied as-is.
6704 (get_stdlib_header_for_name): New, based on get_c_name_hint but
6705 heavily edited to add C++ support. Add some knowledge about
6706 <limits.h>, <stdint.h>, and <wchar.h>.
6707 * known-headers.h: Likewise.
6708
6c7a259b
DM
67092017-11-20 David Malcolm <dmalcolm@redhat.com>
6710
6711 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
6712 (lookup_name_fuzzy): Likewise. Convert return type from
6713 const char * to name_hint. Add location_t param.
6714 * name-hint.h: New header.
6715
f9c59f7e
JJ
67162017-11-19 Jakub Jelinek <jakub@redhat.com>
6717
6718 PR c/66618
6719 PR c/69960
6720 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
6721
1e39313a
JM
67222017-11-16 Joseph Myers <joseph@codesourcery.com>
6723
6724 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
6725 expected publication date of C17.
6726 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
6727
3ca0dc60
JM
67282017-11-15 Joseph Myers <joseph@codesourcery.com>
6729
6730 PR c/81156
6731 * c-common.c (c_common_reswords): Add __builtin_tgmath.
6732 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
6733
025d57f0
MS
67342017-11-10 Martin Sebor <msebor@redhat.com>
6735
6736 PR c/81117
6737 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
6738 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
6739 * c.opt (-Wstringop-truncation): New option.
6740
1b6fa695
ML
67412017-11-06 Martin Liska <mliska@suse.cz>
6742
6743 PR middle-end/82404
6744 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
6745 FE.
6746 * c.opt: Set default value of warn_return_type.
6747
64a5912c
DM
67482017-10-31 David Malcolm <dmalcolm@redhat.com>
6749
6750 * c-common.c (binary_op_error): Update for renaming of
6751 error_at_rich_loc.
6752 (c_parse_error): Likewise.
6753 * c-warn.c (warn_logical_not_parentheses): Likewise for
6754 renaming of inform_at_rich_loc.
6755 (warn_for_restrict): Likewise for renaming of
6756 warning_at_rich_loc_n.
6757
c76dc9c3
JM
67582017-10-30 Joseph Myers <joseph@codesourcery.com>
6759
6760 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
6761 * c-opts.c (set_std_c17): New function.
6762 (c_common_init_options): Use gnu17 as default C version.
6763 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
6764
ee5fd23a
MM
67652017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
6766
6767 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
6768 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
6769 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
6770 __FP_FAST_FMA<N>X.
6771
d1047465
MP
67722017-10-23 Marek Polacek <polacek@redhat.com>
6773
6774 PR c/82681
6775 * c-warn.c (warnings_for_convert_and_check): Fix typos.
6776
9e878cf1
EB
67772017-10-19 Eric Botcazou <ebotcazou@adacore.com>
6778
6779 * c-common.c (check_builtin_function_arguments): Also check arguments
6780 of __builtin_alloca_with_align_and_max.
6781
89b6abbb
DM
67822017-10-17 David Malcolm <dmalcolm@redhat.com>
6783
6784 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
6785 rather than NULL to format_warning_va.
6786 (check_format_types): Likewise when calling format_type_warning.
6787 Remove code to extract source_ranges and source_range * in favor
6788 of just a location_t.
6789 (format_type_warning): Convert source_range * param to a
6790 location_t.
6791
39382c09
JJ
67922017-10-13 Jakub Jelinek <jakub@redhat.com>
6793
6794 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
6795 [LR]SHIFT_EXPR.
6796
62e1c678
DM
67972017-10-12 David Malcolm <dmalcolm@redhat.com>
6798
6799 * c-common.c (enum missing_token_insertion_kind): New enum.
6800 (get_missing_token_insertion_kind): New function.
6801 (maybe_suggest_missing_token_insertion): New function.
6802 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
6803
b90c9338
NS
68042017-10-11 Nathan Sidwell <nathan@acm.org>
6805
6806 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
6807 (c_common_handle_option): Update incpath_kind names.
6808
3a266bcd
ML
68092017-10-11 Martin Liska <mliska@suse.cz>
6810
6811 PR sanitizer/82490
6812 * c-attribs.c (handle_no_sanitize_attribute): Report directly
6813 Wattributes warning.
6814
8e6cdc90
RS
68152017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
6816
6817 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
6818 operating on trees as wide_ints.
6819 * c-common.c (pointer_int_sum): Likewise.
6820 * c-pretty-print.c (pp_c_integer_constant): Likewise.
6821 * c-warn.c (match_case_to_enum_1): Likewise.
6822 (c_do_switch_warnings): Likewise.
6823 (maybe_warn_shift_overflow): Likewise.
6824
802b38c9
JJ
68252017-10-10 Jakub Jelinek <jakub@redhat.com>
6826
6827 PR c/82437
6828 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
6829 instead of wide_int::from.
6830
4e34b338
JJ
68312017-10-06 Jakub Jelinek <jakub@redhat.com>
6832
6833 PR c/82437
6834 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
6835 using to_widest use wide_int with the larger of the two precisions.
6836
4bc4b2b4
BE
68372017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
6838
6839 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
6840 functions.
6841
a1488398
RS
68422017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
6843
6844 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
6845 when combining the original unconverted comparison operands.
6846
01c9fb68
JJ
68472017-09-29 Jakub Jelinek <jakub@redhat.com>
6848
6849 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
6850 attribute.
6851
6e3e8419
EB
68522017-09-29 Eric Botcazou <ebotcazou@adacore.com>
6853
6854 * c-ada-spec.c (to_ada_name): Add index parameter.
6855 (pp_ada_tree_identifier): Likewise.
6856 (dump_ada_macros): Adjust call to to_ada_name.
6857 (struct overloaded_name_hash): New type.
6858 (struct overloaded_name_hasher): Likewise.
6859 (overloaded_names): New hash table.
6860 (compute_overloading_index): New function.
6861 (dump_ada_decl_name): Call it and pass the result to
6862 pp_ada_tree_identifier.
6863 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
6864 (dump_ada_function_declaration): Likewise.
6865 (dump_generic_ada_node): Likewise.
6866 (print_constructor): Likewise.
6867 (print_destructor): Likewise.
6868 (dump_ada_specs): Delete overloaded_names table.
6869
79310774
EB
68702017-09-29 Eric Botcazou <ebotcazou@adacore.com>
6871
6872 * c-ada-spec.c (max_ada_macros): Move around.
6873 (store_ada_macro_index): Likewise.
6874 (source_file): Rename into...
6875 (macro_source_file): ...this.
6876 (count_ada_macro): Move around.
6877 (store_ada_macro): Likewise.
6878 (compare_macro): Likewise.
6879 (print_ada_macros): Merge in...
6880 (dump_ada_macros): ...this.
6881 (source_file_base): Rename into...
6882 (current_source_file): ...this.
6883 (print_comment): Move around.
6884 (dump_ada_nodes): Call dump_ada_declaration directly.
6885 (struct with): Change type of limited field to bool.
6886 (append_withs): Change type of limited_access parameter to bool.
6887 (pp_ada_tree_identifie): Likewise.
6888 (dump_ada_decl_nam): Likewise.
6889 (dump_generic_ada_node): Likewise. Do not print the return type.
6890 (to_ada_name): Change type of space_found parameter to bool.
6891 (dump_ada_function_declaration): Return void and change type of
6892 parameters to bool. Also print the return type for a function.
6893 (print_ada_methods): Rename into...
6894 (dump_ada_methods): ...this.
6895 (print_ada_declaration): Rename into ...
6896 (dump_ada_declaration): ...this. Do not print the return type.
6897 (print_ada_struct_decl): Rename into...
6898 (dump_ada_struct_decl): ...this.
6899
7d386d45
JJ
69002017-09-29 Jakub Jelinek <jakub@redhat.com>
6901
6902 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
6903 rather than DECL_INITIAL.
6904 (common_handle_aligned_attribute): Likewise.
6905
ab20d992 69062017-09-20 Alexandre Oliva <aoliva@redhat.com>
9ed32e27
AO
6907
6908 * c.opt (gen-decls): Add RejectNegative.
6909
026a79f7
AS
69102017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
6911 Jakub Jelinek <jakub@redhat.com>
6912
6913 Add support for -std=c++2a.
6914 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
6915 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
6916 * c-opts.c (set_std_cxx2a): New.
6917 (c_common_handle_option): Set options when -std=c++2a is enabled.
6918 (c_common_post_options): Adjust comments.
6919 (set_std_cxx14, set_std_cxx17): Likewise.
6920
4a8ca690
EB
69212017-09-15 Eric Botcazou <ebotcazou@adacore.com>
6922
6923 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
6924 message for non-uniform endianness and issue a warning in C++.
6925
7b936140
JJ
69262017-09-15 Jakub Jelinek <jakub@redhat.com>
6927
6928 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
6929 (Wc++17-compat): Change from undocumented alias to option.
6930 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
6931 change C++1z to C++17 in description.
6932 (std=c++1z, std=gnu++1z): Change from option to undocumented
6933 deprecated alias.
6934 (std=c++17, std=gnu++17): Change from undocumented alias to option.
6935 Adjust description.
6936 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
6937 * c-opts.c (set_std_cxx1z): Rename to ...
6938 (set_std_cxx17): ... this.
6939 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
6940 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
7365279f 6941 caller.
7b936140
JJ
6942 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
6943 comments.
6944
12263f13
L
69452017-09-12 H.J. Lu <hongjiu.lu@intel.com>
6946
6947 * c-attribs.c (common_handle_aligned_attribute): Don't warn
6948 function alignment if warn_if_not_aligned_p is true.
6949
6836632e
NS
69502017-09-12 Nathan Sidwell <nathan@acm.org>
6951
6952 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
6953 resort_sorted_fields): Move to c/c-decl.c.
6954 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
6955 (struct sorted_fields_type): Move to c/c-lang.h.
6956
019bf9ad
JW
69572017-09-09 Jonathan Wakely <jwakely@redhat.com>
6958
6959 PR c++/81852
6960 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
6961
bc7fe952
MP
69622017-09-04 Marek Polacek <polacek@redhat.com>
6963
6964 PR c/81783
6965 * c-warn.c (warn_tautological_bitwise_comparison): New function.
6966 (warn_tautological_cmp): Call it.
6967
ab20d992 69682017-09-01 Boris Kolpackov <boris@codesynthesis.com>
de7c2c6a
BK
6969
6970 * c-opts.c (c_common_finish): Write dependency information even if
6971 there are errors.
6972
d2e05fcb
JJ
69732017-09-01 Jakub Jelinek <jakub@redhat.com>
6974
6975 PR c/81887
6976 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
6977 (omp_pragmas_simd): ... here.
6978 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
6979 create new clauses list containing just simd clause.
6980
18e2a8b8
RS
69812017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
6982 Alan Hayward <alan.hayward@arm.com>
6983 David Sherwood <david.sherwood@arm.com>
6984
6985 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
6986 into scalar_mode_supported_p call.
6987 (handle_mode_attribute): Update call to scalar_mode_supported_p.
6988
16d22000
RS
69892017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
6990 Alan Hayward <alan.hayward@arm.com>
6991 David Sherwood <david.sherwood@arm.com>
6992
6993 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
6994 for the mode iterator.
6995
b397965c
RS
69962017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
6997 Alan Hayward <alan.hayward@arm.com>
6998 David Sherwood <david.sherwood@arm.com>
6999
7000 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
7001 * c-common.c (c_build_vec_perm_expr): Likewise.
7002
357b7604
RS
70032017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
7004 Alan Hayward <alan.hayward@arm.com>
7005 David Sherwood <david.sherwood@arm.com>
7006
7007 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
7008
e05c94ba
RS
70092017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
7010 Alan Hayward <alan.hayward@arm.com>
7011 David Sherwood <david.sherwood@arm.com>
7012
7013 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
7014 before calling targetm.addr_space.valid_pointer_mode.
7015
5c20c4af
RS
70162017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
7017 Alan Hayward <alan.hayward@arm.com>
7018 David Sherwood <david.sherwood@arm.com>
7019
7020 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
7021
c94843d2 70222017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
92a285c1
ML
7023 Alan Hayward <alan.hayward@arm.com>
7024 David Sherwood <david.sherwood@arm.com>
c94843d2
RS
7025
7026 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
7027 iterators.
7028 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
7029
4e10a5a7
RS
70302017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
7031 Alan Hayward <alan.hayward@arm.com>
7032 David Sherwood <david.sherwood@arm.com>
7033
7034 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
7035 case statements.
7036
130fcab0
ML
70372017-08-29 Martin Liska <mliska@suse.cz>
7038
7039 PR other/39851
7040 * c-common.c (parse_optimize_options): Add argument to function
7041 call.
7042 * c-pragma.c (handle_pragma_diagnostic): Likewise.
7043
14e18d71
DM
70442017-08-24 David Malcolm <dmalcolm@redhat.com>
7045
7046 * c-lex.c (interpret_float): Use token location
7047 when building an EXCESS_PRECISION_EXPR.
7048
2f687306
DM
70492017-08-21 David Malcolm <dmalcolm@redhat.com>
7050
7051 * c-common.c (check_function_arguments): Add "arglogs" param; pass
7052 it to check_function_format.
7053 * c-common.h (check_function_arguments): Add vec<location_t> *
7054 param.
7055 (check_function_format): Likewise.
7056 * c-format.c (struct format_check_context): Add field "arglocs".
7057 (check_function_format): Add param "arglocs"; pass it to
7058 check_format_info.
ab20d992 7059 (check_format_info): Add param "arglocs"; use it to initialize
2f687306
DM
7060 new field of format_ctx.
7061 (check_format_arg): Pass format_ctx->arglocs to new param of
7062 check_format_info_main.
7063 (class argument_parser): New field "arglocs".
7064 (argument_parser::argument_parser): Add "arglocs_" param and use
7065 it to initialize new field.
7066 (argument_parser::check_argument_type): Pass new arglocs field to
7067 check_format_types.
7068 (check_format_info_main): Add param "arglocs", and use it when
7069 constructing arg_parser.
7070 (check_format_types): Add param "arglocs"; use it if non-NULL when
7071 !EXPR_HAS_LOCATION (cur_param) to get at location information.
7072
00aa1fa2
L
70732017-08-18 H.J. Lu <hongjiu.lu@intel.com>
7074
7075 PR c/53037
7076 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
7077 (c_common_attribute_table): Add warn_if_not_aligned.
7078 (handle_aligned_attribute): Renamed to ...
7079 (common_handle_aligned_attribute): Remove argument, name, and add
7080 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
7081 (handle_aligned_attribute): New.
7082 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
7083
27be025d
MS
70842017-08-14 Martin Sebor <msebor@redhat.com>
7085
7086 PR c/81117
7087 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
7088 (handle_nonstring_attribute): New function.
7089
da67acb9
MS
70902017-08-14 Martin Sebor <msebor@redhat.com>
7091
7092 PR c/81117
7093 * c-format.h (T89_G): New macro.
7094 * c-format.c (local_gcall_ptr_node): New variable.
7095 (init_dynamic_diag_info): Initialize it.
7096
a8b522b4
ML
70972017-08-11 Martin Liska <mliska@suse.cz>
7098
7099 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
7100 TARGET_SUPPORTS_ALIASES.
7101
32129a17
DM
71022017-08-10 David Malcolm <dmalcolm@redhat.com>
7103
7104 * c-common.c (c_parse_error): Add rich_location * param, using it
7105 rather implicitly using input_location.
7106 * c-common.h (c_parse_error): Add rich_location * param.
7107
30af3a2b
MP
71082017-08-09 Marek Polacek <polacek@redhat.com>
7109
7110 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
7111 (c_common_truthvalue_conversion): Likewise.
7112 * c-omp.c (c_finish_omp_atomic): Likewise.
7113 * c-common.h (build_binary_op): Update declaration.
7114
314e6352
ML
71152017-08-08 Martin Liska <mliska@suse.cz>
7116
7117 * c-ada-spec.c: Include header files.
7118 * c-ubsan.c: Likewise.
7119 * c-warn.c: Likewise.
7120
56b5041c
JJ
71212017-08-07 Jakub Jelinek <jakub@redhat.com>
7122
7123 PR c/69389
7124 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
7125
db440138
EB
71262017-08-07 Eric Botcazou <ebotcazou@adacore.com>
7127
7128 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
7129 (print_ada_methods): Likewise.
7130 (print_ada_declaration): Likewise.
7131
577eec56
ML
71322017-08-07 Martin Liska <mliska@suse.cz>
7133
7134 * array-notation-common.c: Add new includes.
7135 * c-format.c( handle_format_attribute): Canonicalize a format
7136 function name.
7137 * c-lex.c (c_common_has_attribute): Canonicalize name of an
7138 attribute.
7139 * c-pretty-print.c: Add new include.
7140
b854df3c
EB
71412017-08-05 Eric Botcazou <ebotcazou@adacore.com>
7142
7143 * c-ada-spec.c (has_static_fields): Look only into variables.
7144 (print_constructor): Add TYPE parameter and use it for the name.
7145 (print_destructor): Likewise.
7146 (print_ada_declaration): Adjust to new constructor/destructor names.
7147 Adjust calls to print_constructor and print_destructor.
7148 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
7149 Look only into variables in the final loop.
7150
9f2cb25e
EB
71512017-08-01 Eric Botcazou <ebotcazou@adacore.com>
7152
7153 * c-ada-spec.c (has_static_fields): Look only into fields.
7154 (dump_generic_ada_node): Small tweak.
7155 (dump_nested_types): Look only into fields.
7156 (print_ada_declaration): Look only into methods. Small tweak.
7157 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
7158
f4bcd9eb
EB
71592017-08-01 Eric Botcazou <ebotcazou@adacore.com>
7160
7161 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
7162 (dump_ada_function_declaration): Likewise.
7163 (dump_generic_ada_node): Likewise.
7164 (print_ada_declaration): Add support for const-qualified variables.
7165
f34ebeb2
ML
71662017-07-31 Martin Liska <mliska@suse.cz>
7167
7168 PR sanitize/81530
7169 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
7170 Guard condition with flag_sanitize_p also with current_function_decl
7171 non-null equality.
7172 (ubsan_maybe_instrument_reference_or_call): Likewise.
7173
218e5d04
UB
71742017-07-30 Uros Bizjak <ubizjak@gmail.com>
7175
7176 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
7177
942047f2
EB
71782017-07-29 Eric Botcazou <ebotcazou@adacore.com>
7179
7180 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
7181 for enumeral types.
7182 (print_ada_declaration): Add missing guard for record types.
7183
a40ff0ae
JJ
71842017-07-27 Jakub Jelinek <jakub@redhat.com>
7185
7186 PR c/45784
7187 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
7188 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
7189 new COMPOUND_EXPRs around the rhs of the comparison.
7190
06bd22f6
MP
71912017-07-27 Marek Polacek <polacek@redhat.com>
7192
7193 PR c/81417
7194 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
7195 the types.
7196
036ea399
JJ
71972017-07-27 Jakub Jelinek <jakub@redhat.com>
7198
7199 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
7200 (handle_noipa_attribute): New function.
7201
417ca011
TD
72022017-07-07 Torsten Duwe <duwe@suse.de>
7203
7204 * c-attribs.c (c_common_attribute_table): Add entry for
7205 "patchable_function_entry".
7206
5aaa8fb4
NS
72072017-07-20 Nathan Sidwell <nathan@acm.org>
7208
7209 Remove TYPE_METHODS.
7210 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
7211 dump_ada_template, print_ada_methods,
7212 print_ada_declaration): Member fns are on TYPE_FIELDS.
7213
ff22eb12
NS
72142017-07-18 Nathan Sidwell <nathan@acm.org>
7215
7216 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
7217
eea77d1f
DM
72182017-07-14 David Malcolm <dmalcolm@redhat.com>
7219
7220 * c-common.c (try_to_locate_new_include_insertion_point): New
7221 function.
7222 (per_file_includes_t): New typedef.
7223 (added_includes_t): New typedef.
7224 (added_includes): New variable.
7225 (maybe_add_include_fixit): New function.
7226 * c-common.h (maybe_add_include_fixit): New decl.
7227
281ac396
MS
72282017-07-10 Martin Sebor <msebor@redhat.com>
7229
7230 PR other/81345
7231 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
7232
b6f43128
DM
72332017-07-06 David Malcolm <dmalcolm@redhat.com>
7234
7235 * c-common.c (selftest::c_family_tests): New.
7236 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
7237 (selftest::c_family_tests): New decl.
7238
efbf55b0
MP
72392017-07-04 Marek Polacek <polacek@redhat.com>
7240
7241 PR c/81231
7242 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
7243 types.
7244
6c86bd88
MP
72452017-07-04 Marek Polacek <polacek@redhat.com>
7246
7247 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
7248
17a7218b
ML
72492017-06-28 Martin Liska <mliska@suse.cz>
7250
7251 PR ipa/81128
7252 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
7253 to a function declaration.
7254
63010089
ML
72552017-06-28 Martin Liska <mliska@suse.cz>
7256
7257 PR driver/79659
7258 * c.opt: Add IntegerRange to various options.
7259
3e2becc4
MP
72602017-06-26 Marek Polacek <polacek@redhat.com>
7261
7262 PR c/80116
7263 * c-common.h (warn_for_multistatement_macros): Declare.
7264 * c-warn.c: Include "c-family/c-indentation.h".
7265 (warn_for_multistatement_macros): New function.
7266 * c.opt (Wmultistatement-macros): New option.
7267 * c-indentation.c (guard_tinfo_to_string): No longer static.
7268 Change the parameter type to "enum rid". Handle RID_SWITCH.
7269 * c-indentation.h (guard_tinfo_to_string): Declare.
7270
2db9b7cd
MG
72712017-06-23 Marc Glisse <marc.glisse@inria.fr>
7272
7273 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
7274
c3684b7b
MS
72752017-06-15 Martin Sebor <msebor@redhat.com>
7276
7277 PR c++/80560
7278 * c.opt (-Wclass-memaccess): New option.
7279
e72c4afd
BK
72802017-06-14 Boris Kolpackov <boris@codesynthesis.com>
7281
7282 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
7283
8a516588
MP
72842017-06-13 Marek Polacek <polacek@redhat.com>
7285
7286 PR objc/80949
7287 * c-warn.c (do_warn_duplicated_branches): Return if any of the
7288 branches is null.
7289
45b2222a
ML
72902017-06-13 Martin Liska <mliska@suse.cz>
7291
7292 PR sanitize/78204
7293 * c-attribs.c (add_no_sanitize_value): New function.
7294 (handle_no_sanitize_attribute): Likewise.
7295 (handle_no_sanitize_address_attribute): Use the function.
7296 (handle_no_sanitize_thread_attribute): New function.
7297 (handle_no_address_safety_analysis_attribute): Use
7298 add_no_sanitize_value.
7299 (handle_no_sanitize_undefined_attribute): Likewise.
7300 * c-common.h: Declare new functions.
7301 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
7302 (ubsan_instrument_shift): Likewise.
7303 (ubsan_instrument_bounds): Likewise.
7304 (ubsan_maybe_instrument_array_ref): Likewise.
7305 (ubsan_maybe_instrument_reference_or_call): Likewise.
7306
a01f151f
JM
73072017-06-11 Jason Merrill <jason@redhat.com>
7308
7309 * c-ada-spec.c, c-pragma.c: Use id_equal.
7310
3de4ac6d
MP
73112017-06-04 Marek Polacek <polacek@redhat.com>
7312
7313 PR c/80919
7314 * c-format.c (matching_type_p): Return false if any of the types
7315 requires structural equality.
7316
2474f48f
MS
73172017-06-02 Martin Sebor <msebor@redhat.com>
7318
7319 PR c/80892
7320 * c-warn.c (conversion_warning): Use -Wconversion for integer
7321 conversion and -Wfloat-conversion for floating one.
7322
40ffd95f
BE
73232017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
7324
7325 * c.opt (Wsizeof-pointer-div): New warning option.
7326
3fa4634c
VR
73272017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
7328
7329 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
7330 (Wcatch-value=1): Enable by -Wall.
7331
f012c8ef
DM
73322017-05-30 David Malcolm <dmalcolm@redhat.com>
7333
7334 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
7335 format_chars.
7336 * c.opt (fdiagnostics-show-template-tree): New option.
7337 (felide-type): New option.
7338
63dbcd13
VR
73392017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
7340
7341 * c.opt (Wcatch-value=): New C++ warning flag.
7342
be136b5c
NS
73432017-05-24 Nathan Sidwell <nathan@acm.org>
7344
7345 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
7346 const casts to avoid warning.
7347
3cd211af
MS
73482017-05-24 Martin Sebor <msebor@redhat.com>
7349
7350 PR c/80731
7351 * c-common.h (unsafe_conversion_p): Add a function argument.
7352 * c-common.c (unsafe_conversion_p): Same.
7353 Add type names and values to diagnostics.
7354 (scalar_to_vector): Adjust.
7355 * c-warn.c (constant_expression_error): Add a function argument.
7356 Add type names and values to diagnostics.
7357 (conversion_warning): Add a function argument.
7358 Add type names and values to diagnostics.
7359 (warnings_for_convert_and_check): Same.
7360
1ff7be5a
JM
73612017-05-19 Jason Merrill <jason@redhat.com>
7362
7363 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
7364 enumerators.
7365
ff502317
BE
73662017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
7367
7368 * c-format.c (locus): Move out of function scope,
7369 add GTY attribute.
7370
2a8a8d7b
NS
73712017-05-19 Nathan Sidwell <nathan@acm.org>
7372
7373 * c-opts.c (class_dump_file, class_dump_flags): Delete.
7374 (c_common_parse_file): Remove class dump handling.
7375 (get_dump_info): Likewise.
7376
39aac208
RB
73772017-05-19 Richard Biener <rguenther@suse.de>
7378
7379 PR c++/80593
7380 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
7381 to alias-set zero memory.
7382
6ecd2339
BE
73832017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
7384
7385 * c-format.c (local_tree_type_node): Add GTY attribute.
7386
6574d78e
MP
73872017-05-18 Marek Polacek <polacek@redhat.com>
7388
7389 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
7390 (c_common_fixed_point_type_for_size): Likewise.
7391 (c_common_type_for_mode): Likewise.
7392 (shorten_compare): Likewise.
7393 (c_promoting_integer_type_p): Use false/true instead of 0/1.
7394 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
7395
e3455240
MP
73962017-05-18 Marek Polacek <polacek@redhat.com>
7397
7398 * c-common.c (self_promoting_args_p): Change the return type to bool.
7399 Use false/true instead of 0/1.
7400 * c-common.h (self_promoting_args_p): Update.
7401
3fa8871b
MP
74022017-05-17 Marek Polacek <polacek@redhat.com>
7403
7404 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
7405 * c-warn.c: Likewise.
7406
b42cc3ca
VV
74072017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
7408
7409 Implement new C++ intrinsics __is_assignable and __is_constructible.
7410 * c-common.c (__is_assignable, __is_constructible): New.
7411 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
7412
1a817418
ML
74132017-05-17 Martin Liska <mliska@suse.cz>
7414
7415 * c-common.h: Introduce dump_flags_t type and
7416 use it instead of int type.
7417 * c-gimplify.c (c_genericize): Likewise.
7418 * c-opts.c: Likewise.
7419
b2fa0a8b
MP
74202017-05-17 Marek Polacek <polacek@redhat.com>
7421
7422 * c-common.c (c_save_expr): Remove.
7423 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
7424 * c-common.h (c_save_expr): Remove declaration.
7425
31c2d57d
VR
74262017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
7427
7428 PR c/35441
7429 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
7430 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
7431 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
7432 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
7433 RDIV_EXPR.
7434 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
7435
684f84de
MP
74362017-05-09 Marek Polacek <polacek@redhat.com>
7437
7438 PR c/80525
7439 * c-warn.c (unwrap_c_maybe_const): New.
7440 (warn_logical_operator): Call it.
7441
641da50a
NS
74422017-05-09 Nathan Sidwell <nathan@acm.org>
7443
7444 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
7445 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
7446
631238ac
MS
74472017-05-08 Martin Sebor <msebor@redhat.com>
7448
7449 PR translation/80280
7450 * c-format.h (struct format_flag_spec): Add new member.
7451 (T89_T): New macro.
7452 * c-format.c (local_tree_type_node): New global.
7453 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
7454 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
7455 (strfmon_flag_specs): Likewise.
7456 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
7457 with distinct quoting properties.
7458 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
7459 (flag_chars_t::validate): Add argument and handle bad quoting.
7460 (check_format_info_main): Handle quoting problems.
7461 (init_dynamic_diag_info): Simplify.
7462
49f0c04c
JM
74632017-05-08 Jason Merrill <jason@redhat.com>
7464
7465 * c-opts.c (c_common_post_options): Update defaults for
7466 flag_abi_version and flag_abi_compat_version.
7467
56d35585
DM
74682017-05-05 David Malcolm <dmalcolm@redhat.com>
7469
7470 * c-common.c (c_cpp_error): Replace report_diagnostic
7471 with diagnostic_report_diagnostic.
7472
0f2c4a8f
MS
74732017-05-04 Martin Sebor <msebor@redhat.com>
7474
7475 PR translation/80280
7476 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
7477 (handle_weakref_attribute): Same.
7478
6fe63fb4
NS
74792017-05-03 Nathan Sidwell <nathan@acm.org>
7480
7481 Canonicalize canonical type hashing
7482 * c-common.c (complete_array_type): Use type_hash_canon.
7483
815d9cc6
XR
74842017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
7485
92a285c1 7486 PR c++/80038
815d9cc6
XR
7487 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
7488 prototype.
7489 (cilk_install_body_pedigree_operations): Likewise.
7490 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
7491 detatched.
7492 (cilk_gimplify_call_params_in_spawned_fn): Remove.
7493 (cilk_install_body_pedigree_operations): Likewise.
7494 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
7495 unwrapping.
7496
f8a36447
JJ
74972017-04-27 Jakub Jelinek <jakub@redhat.com>
7498
7499 PR c++/80534
7500 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
7501 flag on non-aggregate element types.
7502
7c145456
BE
75032017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
7504
7505 * c-common.c (c_type_hasher, type_hash_table): Remove.
7506 (c_common_get_alias_set): Remove unreachable code.
7507 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
7508
c3cbcd45
VR
75092017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
7510
7511 * c.opt (Wextra-semi): New C++ warning flag.
7512
8a59d466
JJ
75132017-04-20 Jakub Jelinek <jakub@redhat.com>
7514
7515 PR middle-end/80423
7516 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
7517
8487c9a5
JJ
75182017-04-18 Jakub Jelinek <jakub@redhat.com>
7519
7520 PR middle-end/79788
7521 PR middle-end/80375
7522 * c-common.c (c_common_type_for_mode): Don't handle
7523 widest_*_literal_type_node here.
7524 c_common_signed_or_unsigned_type): Likewise.
7525 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
7526 to *intTI_type_node or *intDI_type_node depending on whether
7527 TImode is supported by the target or not.
7528
3ee0fb02
ML
75292017-04-10 Martin Liska <mliska@suse.cz>
7530
7531 PR sanitizer/80350
7532 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
7533 doing an UBSAN check.
7534
5764ee3c
JW
75352017-04-03 Jonathan Wakely <jwakely@redhat.com>
7536
7537 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
7538
6f3af356
JJ
75392017-03-31 Jakub Jelinek <jakub@redhat.com>
7540
7541 PR c++/79572
7542 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
7543 tree *.
7544 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
7545 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
7546 REFERENCE_TYPE.
7547
f6a7a9d5
DM
75482017-03-31 David Malcolm <dmalcolm@redhat.com>
7549
7550 PR documentation/78732
7551 * c.opt (Wendif-labels): Fix description to refer to
7552 #else rather than #elif.
7553
af88f557
JJ
75542017-03-31 Jakub Jelinek <jakub@redhat.com>
7555
7556 PR libstdc++/80251
7557 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
7558 * c-common.c (c_common_reswords): Add __is_aggregate trait.
7559
a9e4a1a5
JJ
75602017-03-27 Jakub Jelinek <jakub@redhat.com>
7561
7562 PR middle-end/80162
7563 * c-common.c (c_common_mark_addressable_vec): Don't set
7564 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
7565
3f01b620
MS
75662017-03-21 Martin Sebor <msebor@redhat.com>
7567
7568 PR c++/79548
7569 * c-common.c (set_underlying_type): Mark type used only when
7570 original del is declared unused.
7571
2f6f187a
DM
75722017-03-10 David Malcolm <dmalcolm@redhat.com>
7573
7574 PR translation/79848
7575 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
7576 "%qs".
7577
a02fa805
DM
75782017-03-10 David Malcolm <dmalcolm@redhat.com>
7579
7580 PR c/79921
7581 * c-indentation.c (warn_for_misleading_indentation): Remove parens
7582 from inform's message, so that xgettext can locate it.
7583
822a132c
MP
75842017-03-09 Marek Polacek <polacek@redhat.com>
7585
7586 PR c++/79962
7587 PR c++/79984
7588 * c-attribs.c (handle_nonnull_attribute): Save the result of default
7589 conversion to the attribute list.
7590
bba81f1c
ML
75912017-03-09 Martin Liska <mliska@suse.cz>
7592
7593 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
7594
108154ff
JM
75952017-03-03 Jason Merrill <jason@redhat.com>
7596
7597 * c.opt (Wnoexcept-type): New.
7598
eb0e7c34
RB
75992017-03-02 Richard Biener <rguenther@suse.de>
7600
7601 PR c/79756
7602 * c-common.c (c_common_mark_addressable_vec): Look through
7603 C_MAYBE_CONST_EXPR.
7604
9453ba0a
ML
76052017-02-28 Martin Liska <mliska@suse.cz>
7606
7607 * c.opt: Replace space with tabular for options of <number>
7608 type.
7609
6a825afe
ML
76102017-02-28 Martin Liska <mliska@suse.cz>
7611
7612 * c.opt: Fix --help=option -Q for options which are of
7613 an enum type.
7614
4227c9ad
JJ
76152017-02-24 Jakub Jelinek <jakub@redhat.com>
7616
7617 PR c++/79588
7618 * c-common.c (check_function_restrict): New function.
7619 (check_function_arguments): Add FNDECL argument. Call
7620 check_function_restrict if -Wrestrict.
7621 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
7622 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
7623 * c-common.h (check_function_arguments): Add FNDECL argument.
7624 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
7625
59909673
EB
76262017-02-24 Eric Botcazou <ebotcazou@adacore.com>
7627
7628 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
7629 treatment of parameters with pointer-to-tagged type and tidy up.
7630 (print_ada_methods): Remove the special treatment of C++ static member
7631 functions.
7632
54dcd526
ML
76332017-02-22 Martin Liska <mliska@suse.cz>
7634
7635 * c.opt: Replace inequality signs with square brackets
7636 for -Wnornalized.
7637
00bc9de3
JJ
76382017-02-21 Jakub Jelinek <jakub@redhat.com>
7639
7640 PR c++/79641
7641 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
7642 preserve quals.
7643
97fcf744
JM
76442017-02-17 Joseph Myers <joseph@codesourcery.com>
7645
7646 * c-cppbuiltin.c (builtin_define_float_constants): Define
7647 __DECIMAL_DIG__ to the value for long double.
7648
c7545f1c
MP
76492017-02-15 Marek Polacek <polacek@redhat.com>
7650
7651 PR c/79515
7652 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
7653 conversion has occured.
7654
c2e84327
DM
76552017-01-24 David Malcolm <dmalcolm@redhat.com>
7656
7657 * c-common.c (c_common_reswords): Add "__RTL".
7658 * c-common.h (enum rid): Add RID_RTL.
7659
2ebd93e1
MP
76602017-01-20 Marek Polacek <polacek@redhat.com>
7661
7662 PR c/64279
7663 * c-common.h (do_warn_duplicated_branches_r): Declare.
7664 * c-gimplify.c (c_genericize): Walk the function tree calling
7665 do_warn_duplicated_branches_r.
7666 * c-warn.c (expr_from_macro_expansion_r): New.
7667 (do_warn_duplicated_branches): New.
7668 (do_warn_duplicated_branches_r): New.
7669 * c.opt (Wduplicated-branches): New option.
7670
0d80ab91
DM
76712017-01-17 David Malcolm <dmalcolm@redhat.com>
7672
7673 PR c++/71497
7674 * c-indentation.c (warn_for_misleading_indentation): Use the past
7675 subjunctive in the note.
7676
7f991c36
AH
76772017-01-17 Aldy Hernandez <aldyh@redhat.com>
7678
7679 PR c/79116
7680 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
7681 start type to integer_type.
7682
1c70261c
JJ
76832017-01-16 Jakub Jelinek <jakub@redhat.com>
7684
7685 PR driver/49726
7686 * c.opt (gen-decls): Add Driver flag.
7687
1ddca3f3
PC
76882017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
7689
7690 Revert:
7691 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
7692
7693 PR c++/71737
7694 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
7695
7d2f3f1d
PC
76962017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
7697
7698 PR c++/71737
7699 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
7700
bce6f760
MS
77012017-01-12 Martin Sebor <msebor@redhat.com>
7702
7703 (-Wformat-overflow): ...to this.
7704
bf5fbf46
MS
77052017-01-11 Martin Sebor <msebor@redhat.com>
7706
7707 PR c/78768
7708 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
7709 Also enable for LTO.
7710
e363df3f
JM
77112017-01-10 Jason Merrill <jason@redhat.com>
7712
7713 Implement P0195R2, C++17 variadic using.
7714 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
7715
bd2c6270
JJ
77162017-01-09 Jakub Jelinek <jakub@redhat.com>
7717
7718 PR translation/79019
7719 PR translation/79020
7720 * c.opt (Wnormalized=): Fix typo in description.
7721
efcc8d38
MS
77222017-01-08 Martin Sebor <msebor@redhat.com>
7723
7724 PR middle-end/77708
7725 * c.opt (-Wformat-truncation): New option.
7726
ab20d992 77272017-01-06 Alexandre Oliva <aoliva@redhat.com>
435f3f7a
AO
7728
7729 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
7730 value to unsigned short to fit in 4 hex digits without
7731 warnings.
7732
4e89adf9
EB
77332017-01-05 Eric Botcazou <ebotcazou@adacore.com>
7734
7735 * c.opt (fsso-struct): Add 'native' value.
7736
cd445b54
ML
77372017-01-05 Martin Liska <mliska@suse.cz>
7738
7739 PR pch/78970
7740 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
7741 header.
7742
a9342885
MP
77432017-01-04 Marek Polacek <polacek@redhat.com>
7744
7745 PR c++/64767
7746 * c.opt (Wpointer-compare): New option.
7747
fc73e60c
JJ
77482017-01-04 Jakub Jelinek <jakub@redhat.com>
7749
7750 PR driver/78957
7751 * c.opt (fsso-struct=): Add RejectNegative.
7752
cbe34bb5
JJ
77532017-01-01 Jakub Jelinek <jakub@redhat.com>
7754
7755 Update copyright years.
7756
d4a6c0ea
ML
77572016-12-29 Martin Liska <mliska@suse.cz>
7758
7759 PR c/78933
7760 * c.opt (strong-eval-order): Add RejectNegative keyword.
7761
67a5ad7c
JM
77622016-12-22 Jason Merrill <jason@redhat.com>
7763
7764 Implement P0522R0, matching of template template arguments.
7765 * c-cppbuiltin.c (c_cpp_builtins): Define
7766 __cpp_template_template_args.
7767
0dba7960
JJ
77682016-12-21 Jakub Jelinek <jakub@redhat.com>
7769
7770 PR bootstrap/78817
7771 * c-common.c (struct nonnull_arg_ctx): New type.
7772 (check_function_nonnull): Return bool instead of void. Use
7773 nonnull_arg_ctx as context rather than just location_t.
7774 (check_nonnull_arg): Adjust for the new context type, set
7775 warned_p to true if a warning has been diagnosed.
7776 (check_function_arguments): Return bool instead of void.
7777 * c-common.h (check_function_arguments): Adjust prototype.
7778
31bfc9b9
JM
77792016-12-21 Jason Merrill <jason@redhat.com>
7780
7781 * c.opt (-fnew-ttp-matching): New flag.
7782 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
7783
629b3d75
MJ
77842016-12-14 Martin Jambor <mjambor@suse.cz>
7785
7786 * c-omp.c: Include omp-general.h instead of omp-low.h.
7787 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
7788 name.
7789
474da67e
MS
77902016-12-14 Martin Sebor <msebor@redhat.com>
7791
7792 PR c/17308
7793 * c-common.c (check_nonnull_arg): Disable when optimization
7794 is enabled.
7795
fe366b87
MP
77962016-12-12 Marek Polacek <polacek@redhat.com>
7797
7798 PR c++/78647
7799 * c-common.c (attribute_fallthrough_p): Return false for
7800 error_mark_node.
7801
8bd9f164
MS
78022016-12-08 Martin Sebor <msebor@redhat.com>
7803
7804 PR c/78284
7805 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
7806
060162e0
MS
78072016-12-08 Martin Sebor <msebor@redhat.com>
7808
7809 PR c/78165
92a285c1
ML
7810 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
7811 suffix.
060162e0 7812
ee92e7ba
MS
78132016-12-07 Martin Sebor <msebor@redhat.com>
7814
7815 PR c/53562
7816 PR middle-end/77784
7817 PR middle-end/78149
7818 PR middle-end/78138
7819 * c.opt (-Wstringop-overflow): New option.
7820
84b0769e
MO
78212016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
7822
7823 * c-attribs.c (asan odr indicator): New attribute.
7824 (handle_asan_odr_indicator_attribute): New function.
7825
7fa6a965
PK
78262016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
7827
7828 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
7829 ptrdiff_type_node;
7830
56d8ffc1
JG
78312016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
7832
7833 * c-common.c (excess_precision_mode_join): New.
7834 (c_ts18661_flt_eval_method): New.
7835 (c_c11_flt_eval_method): Likewise.
7836 (c_flt_eval_method): Likewise.
7837 * c-common.h (excess_precision_mode_join): New.
7838 (c_flt_eval_method): Likewise.
7839 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
7840 (cpp_iec_559_value): Call it.
7841 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
7842 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
7843 __FLT_EVAL_METHOD_TS_18661_3__.
7844
04f0fcf7
JG
78452016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
7846
7847 * c-opts.c (c_common_post_options): Add logic to handle the default
7848 case for -fpermitted-flt-eval-methods.
7849
fb2675cb
PB
78502016-11-23 Paolo Bonzini <bonzini@gnu.org>
7851
7852 * c.opt (Wexpansion-to-defined): New.
7853
ec1c5694
JJ
78542016-11-23 Jakub Jelinek <jakub@redhat.com>
7855
7856 PR target/78451
7857 * c-pragma.c (handle_pragma_target): Don't replace
7858 current_target_pragma, but chainon the new args to the current one.
7859
730c9e75
NS
78602016-11-22 Nathan Sidwell <nathan@acm.org>
7861
7862 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
cacd29be 7863 indentation and formatting.
730c9e75 7864
89990732
MS
78652016-11-21 Martin Sebor <msebor@redhat.com>
7866
7867 * c.opt (-fprintf-return-value): Enable by default.
7868
48330c93
BE
78692016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
7870
7871 PR c++/71973
7872 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
7873 * c-common.c (c_common_nodes_and_builtins): Initialize
7874 const_tm_ptr_type_node.
7875
0d939c95
MP
78762016-11-16 Marek Polacek <polacek@redhat.com>
7877
7878 PR c/78285
7879 * c-common.c (c_add_case_label): Turn error_at calls into inform.
7880
8e745a17
JJ
78812016-11-14 Jakub Jelinek <jakub@redhat.com>
7882
7883 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
7884
1ee62b92 78852016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
8e745a17
JJ
7886 Richard Biener <rguenther@suse.de>
7887
7888 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
7889 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
7890 * c.opt (fgimple): New option.
1ee62b92 7891
22b15758
UB
78922016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
7893
7894 PR c/35503
7895 * c-common.h (warn_for_restrict): Declare.
7896 * c-warn.c: Include gcc-rich-location.h.
7897 (warn_for_restrict): New function.
7898 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
7899 (gcc_cdiag_char_table): Likewise.
7900 (gcc_cxxdiag_char_table): Likewise.
7901 * c.opt (Wrestrict): New option.
7902
4be719cd
EB
79032016-11-13 Eric Botcazou <ebotcazou@adacore.com>
7904
7905 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
7906 for nested types only if the type is a record or union and dump SLOC.
7907
4a826ca6
JM
79082016-11-09 Jason Merrill <jason@redhat.com>
7909
7910 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
7911
2e955d50
JJ
79122016-11-09 Jakub Jelinek <jakub@redhat.com>
7913
7914 * c-ubsan.c (ubsan_instrument_shift): Handle split
7915 -fsanitize=shift-base and -fsanitize=shift-exponent.
7916
51dc6603
JM
79172016-11-07 Jason Merrill <jason@redhat.com>
7918
7919 * c.opt (Wc++1z-compat): New.
7920 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
7921
6dc4a604
ML
79222016-11-07 Martin Liska <mliska@suse.cz>
7923
7924 * c-warn.c (warn_for_unused_label): Save all labels used
7925 in goto or in &label.
7926
b302001e
JM
79272016-11-03 Jason Merrill <jason@redhat.com>
7928
7929 * c-cppbuiltin.c (c_cpp_builtins): Correct
7930 __cpp_inheriting_constructors.
7931
31f7f784
JM
79322016-11-01 Jason Merrill <jason@redhat.com>
7933
2bc78e3c
JM
7934 * c-cppbuiltin.c (c_cpp_builtins): Update
7935 __cpp_inheriting_constructors.
7936
31f7f784
JM
7937 * c.opt (-fnew-inheriting-ctors): New.
7938 * c-opts.c: Default to on for ABI 11+.
7939
dcb466ec
JJ
79402016-10-31 Jakub Jelinek <jakub@redhat.com>
7941
7942 PR c++/77948
7943 * c.opt (fext-numeric-literals): Add Var and Init.
7944 * c-opts.c (c_common_handle_option): Don't clear
7945 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
7946 (c_common_post_options): Clear it here if not set
7947 explicitly.
7948
52e1b91e
AH
79492016-10-28 Aldy Hernandez <aldyh@redhat.com>
7950
7951 PR debug/77773
7952 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
7953 if NULL.
7954
e16f1cc7
JJ
79552016-10-25 Jakub Jelinek <jakub@redhat.com>
7956
7957 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
7958 * c-common.c (c_common_reswords): Add __builtin_launder.
7959
f8348061
BE
79602016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
7961
7962 * c-common.c (c_common_truthvalue_conversion): Warn for
7963 multiplications in boolean context. Fix the quoting of '<<' and '<'
7964 in the shift warning.
7965
eff89e01
BE
79662016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
7967
7968 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
7969
24bc7bf4
JM
79702016-10-20 Jason Merrill <jason@redhat.com>
7971
7972 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
7973
4c712374
BE
79742016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
7975
7976 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
7977 integer shift ops in boolean context.
7978
79792016-10-18 Aldy Hernandez <aldyh@redhat.com>
adc577c5
AH
7980
7981 * c.opt (Walloca): New.
7982 (Walloca-larger-than=): New.
7983 (Wvla-larger-than=): New.
7984
8fa18c06
MP
79852016-10-17 Marek Polacek <polacek@redhat.com>
7986
7987 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
7988 Return immediately when finding a match.
7989 (warn_tautological_cmp): Remove a boolean variable that is no longer
7990 needed.
7991
b12b1915
MP
79922016-10-17 Marek Polacek <polacek@redhat.com>
7993
7994 * c-attribs.c: New file.
7995 * c-common.c: Move attributes handling to c-attribs.c.
7996 (get_nonnull_operand): No longer static.
7997 * c-common.h: Move the declarations from c-attribs.c to its own section.
7998
2045acd9
JM
79992016-10-14 Jason Merrill <jason@redhat.com>
8000
8001 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
8002 and __cpp_deduction_guides.
8003
14a2c9aa
JM
80042016-10-13 Jason Merrill <jason@redhat.com>
8005
8006 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
8007
4d0cdd0c
TP
80082016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
8009
8010 * c-cppbuiltin.c: Include memmodel.h.
8011 * c-opts.c: Likewise.
8012 * c-pragma.c: Likewise.
8013 * c-warn.c: Likewise.
8014
70f6d5e1
JJ
80152016-10-12 Jakub Jelinek <jakub@redhat.com>
8016
8017 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
8018 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
8019 * c-opts.c (sanitize_cpp_opts): Initialize
8020 cpp_opts->cpp_warn_implicit_fallthrough.
8021
78f61294
MP
80222016-10-11 Marek Polacek <polacek@redhat.com>
8023
8024 * c-common.c (warning_candidate_p): Change the return type to bool
8025 and return true/false instead of 1/0.
8026 (vector_mode_valid_p): Likewise.
8027
038b5cc0
MP
80282016-10-11 Marek Polacek <polacek@redhat.com>
8029
8030 * c-common.c (fold_for_warn): No longer static.
8031 (bool_promoted_to_int_p): Likewise.
8032 (c_common_get_narrower): Likewise.
8033 (constant_expression_warning): Move to c-warn.c.
8034 (constant_expression_error): Likewise.
8035 (overflow_warning): Likewise.
8036 (warn_logical_operator): Likewise.
8037 (find_array_ref_with_const_idx_r): Likewise.
8038 (warn_tautological_cmp): Likewise.
8039 (expr_has_boolean_operands_p): Likewise.
8040 (warn_logical_not_parentheses): Likewise.
8041 (warn_if_unused_value): Likewise.
8042 (strict_aliasing_warning): Likewise.
8043 (sizeof_pointer_memaccess_warning): Likewise.
8044 (check_main_parameter_types): Likewise.
8045 (conversion_warning): Likewise.
8046 (warnings_for_convert_and_check): Likewise.
8047 (match_case_to_enum_1): Likewise.
8048 (match_case_to_enum): Likewise.
8049 (c_do_switch_warnings): Likewise.
8050 (warn_for_omitted_condop): Likewise.
8051 (readonly_error): Likewise.
8052 (lvalue_error): Likewise.
8053 (invalid_indirection_error): Likewise.
8054 (warn_array_subscript_with_type_char): Likewise.
8055 (warn_about_parentheses): Likewise.
8056 (warn_for_unused_label): Likewise.
8057 (warn_for_div_by_zero): Likewise.
8058 (warn_for_memset): Likewise.
8059 (warn_for_sign_compare): Likewise.
8060 (do_warn_double_promotion): Likewise.
8061 (do_warn_unused_parameter): Likewise.
8062 (record_locally_defined_typedef): Likewise.
8063 (maybe_record_typedef_use): Likewise.
8064 (maybe_warn_unused_local_typedefs): Likewise.
8065 (maybe_warn_bool_compare): Likewise.
8066 (maybe_warn_shift_overflow): Likewise.
8067 (warn_duplicated_cond_add_or_warn): Likewise.
8068 (diagnose_mismatched_attributes): Likewise.
8069 * c-common.h: Move the declarations from c-warn.c to its own section.
8070 * c-warn.c: New file.
8071
627be19f
JM
80722016-10-08 Jason Merrill <jason@redhat.com>
8073
8074 * c-common.c (c_common_truthvalue_conversion): Don't distribute
8075 into COND_EXPR in C++.
8076
7bad794a
JJ
80772016-10-08 Jakub Jelinek <jakub@redhat.com>
8078
8079 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
8080 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
8081 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
8082
be845b04
JJ
80832016-10-07 Jakub Jelinek <jakub@redhat.com>
8084
8085 Implement LWG2296 helper intrinsic
8086 * c-common.h (enum rid): Add RID_ADDRESSOF.
8087 * c-common.c (c_common_reswords): Add __builtin_addressof.
8088
c09c4992
BE
80892016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
8090
8091 PR c++/77700
8092 * c-common.c (c_common_truthvalue_conversion): Warn also for
8093 suspicious enum values in boolean context.
8094
342cfb3e
JJ
80952016-10-06 Jakub Jelinek <jakub@redhat.com>
8096
8097 Implement P0258R2 - helper for C++17
8098 std::has_unique_object_representations trait
8099 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
8100 * c-common.c (c_common_reswords): Add
8101 __has_unique_object_representations.
8102
2e69f143
JJ
81032016-10-05 Jakub Jelinek <jakub@redhat.com>
8104
8105 PR sanitizer/66343
8106 * c-ubsan.c (ubsan_instrument_return): Don't call
8107 initialize_sanitizer_builtins here.
8108
700fff34
BE
81092016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
8110
8111 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
8112 conditional expression in boolean context when only one arm is
8113 non-boolean.
8114
9563bfcd
JJ
81152016-10-05 Jakub Jelinek <jakub@redhat.com>
8116
04a32443
JJ
8117 PR sanitizer/77823
8118 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
8119 is not integral.
8120
9563bfcd
JJ
8121 * c-common.c (c_common_reswords): Update comment for C++11.
8122
f1644724
JM
81232016-10-04 Jason Merrill <jason@redhat.com>
8124
8125 * c-common.c (make_tree_vector_from_ctor): New.
8126 * c-common.h: Declare it.
8127
5a79befb
JJ
81282016-10-04 Jakub Jelinek <jakub@redhat.com>
8129
8130 * c-cppbuiltin.c (c_cpp_builtins): Don't define
8131 __LIBGCC_JCR_SECTION_NAME__.
8132
1633d3b9
BE
81332016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
8134
8135 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
8136 left shift in boolean context.
8137
a2c6e7f2
JJ
81382016-09-29 Jakub Jelinek <jakub@redhat.com>
8139
8140 Implement P0001R1 - C++17 removal of register storage class specifier
8141 * c.opt (Wregister): New warning.
8142 * c-opts.c (c_common_post_options): Enable -Wregister by
8143 default for C++17.
8144
75304c87
JG
81452016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
8146
8147 * c-opts.c (c_common_post_options): Remove special case for
8148 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
8149 in C++.
8150
bbfac6da
JJ
81512016-09-27 Jakub Jelinek <jakub@redhat.com>
8152
6e39060a
JJ
8153 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
8154 -std=c++1z.
8155
bbfac6da
JJ
8156 * c-ada-spec.c (print_ada_declaration): Remove break after return.
8157
e73cf9a2
TP
81582016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
8159
8160 * c-common.c: Include memmodel.h.
8161
c6147dc4
MP
81622016-09-26 Marek Polacek <polacek@redhat.com>
8163
8164 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
8165
81fea426
MP
81662016-09-26 Marek Polacek <polacek@redhat.com>
8167
8168 PR c/7652
8169 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
8170 (handle_fallthrough_attribute): New function.
8171 (attribute_fallthrough_p): New function.
8172 * c-common.h (attribute_fallthrough_p): Declare.
8173
9a2300e9
MP
81742016-09-24 Marek Polacek <polacek@redhat.com>
8175
8176 PR c/77490
8177 * c.opt (Wbool-operation): New.
8178
a09e9e35
BE
81792016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
8180
8181 * c-common.c (c_common_truthvalue_conversion): Inhibit
8182 Wint-in-bool-context warning with from_macro_definition_at.
8183 Mention the expression will always evaluate to true.
8184
d43b4ccc
MS
81852016-09-21 Martin Sebor <msebor@redhat.com>
8186
8187 PR bootstrap/77676
8188 * c.opt (fprintf-return-value): Temporarily initialize to zero
8189 to unblock bootstrap failures.
8190
2e1c20b1
JJ
81912016-09-21 Jakub Jelinek <jakub@redhat.com>
8192
8193 PR c++/77651
8194 * c.opt (Waligned-new=): Add RejectNegative.
8195 (faligned-new=): Likewise. Spelling fix - change
8196 aligned_new_threshhold to aligned_new_threshold.
8197 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
8198 to aligned_new_threshold.
8199
88d0c3f0
MS
82002016-09-20 Martin Sebor <msebor@redhat.com>
8201
8202 PR middle-end/49905
8203 * c.opt: Add -Wformat-length and -fprintf-return-value.
8204
144a96e4
BE
82052016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
8206
8207 PR c++/77434
8208 * c.opt (Wint-in-bool-context): New warning.
8209 * c-common.c (c_common_truthvalue_conversion): Warn on integer
8210 constants in boolean context.
8211
63012d9a
JM
82122016-09-19 Joseph Myers <joseph@codesourcery.com>
8213
8214 * c-common.c (max_align_t_align): Also consider alignment of
8215 float128_type_node.
8216
931388ce
JM
82172016-09-15 Jason Merrill <jason@redhat.com>
8218
8219 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
8220 DECL_EXTERNAL.
8221
38711381
JM
82222016-09-14 Jason Merrill <jason@redhat.com>
8223
8224 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
8225 limit FIELD_DECL, either.
8226
e51fbec3
MP
82272016-09-14 Marek Polacek <polacek@redhat.com>
8228
8229 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
8230 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
8231 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
8232
254830ba
DM
82332016-09-13 David Malcolm <dmalcolm@redhat.com>
8234
8235 * c-common.c (warn_logical_not_parentheses): Replace
8236 rich_location::add_fixit_insert calls with add_fixit_insert_before
8237 and add_fixit_insert_after, eliminating the "next_loc" calculation.
8238
42763690
JM
82392016-09-13 Jason Merrill <jason@redhat.com>
8240 Tom de Vries <tom@codesourcery.com>
8241
8242 PR c++/77427
8243 * c-common.c (set_underlying_type): Don't treat array as builtin type.
8244
9453eee9
JM
82452016-09-13 Jason Merrill <jason@redhat.com>
8246
8247 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
8248 limit types at all.
8249
e96809e3
JM
82502016-09-12 Jason Merrill <jason@redhat.com>
8251
8252 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
8253 bit/byte confusion, allow large alignment for types.
8254
54dcdb88
BE
82552016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
8256
8257 PR c++/77496
8258 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
8259
d1463eb9
DM
82602016-09-12 David Malcolm <dmalcolm@redhat.com>
8261
8262 PR c/72858
8263 * c-format.c (argument_parser::check_argument_type): Add params
8264 "type_start" and "conversion_char". Use the former to generate
8265 offset_to_type_start and pass it and conversion_char to
8266 check_format_types.
8267 (check_format_info_main): Capture the start of the type
8268 information as "type_start", and pass it an format_char
8269 to arg_parser.check_argument_type.
8270 (check_format_types): Provide an example in the leading comment.
8271 Add params "offset_to_type_start" and "conversion_char"; pass
8272 them to format_type_warning calls.
8273 (test_get_modifier_for_format_len): Likewise.
8274 (matching_type_p): New function.
8275 (get_format_for_type): Add param "conversion_char" and move
8276 implementation into...
8277 (get_format_for_type_1): ...new function, called twice.
8278 Use new function matching_type_p rather than checking for
8279 TYPE_CANONICAL equality.
8280 (get_corrected_substring): New function.
8281 (format_type_warning): Provide an example in the leading comment.
8282 Add params "offset_to_type_start" and "conversion_char". Replace
8283 call to get_format_for_type with call to get_corrected_substring
8284 and move rejection of hints for widths/precisions there.
8285 (assert_format_for_type_streq): Add param "conversion_char".
8286 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
8287 (test_get_format_for_type_printf): Add conversion chars to the
8288 tests, adding coverage for various combinations of integer
8289 vs double conversions, and for preserving octal and hexadecimal
8290 conversions.
8291 (test_get_format_for_type_scanf): Add conversion chars to the
8292 tests.
8293
5b28efbb
TV
82942016-09-10 Tom de Vries <tom@codesourcery.com>
8295
8296 PR C/71602
8297 * c-common.c (build_va_arg): Handle more strict
8298 targetm.canonical_va_list_type. Replace first argument type error with
8299 assert.
8300
3f0177e7
MS
83012016-09-09 Martin Sebor <msebor@redhat.com>
8302
8303 PR c/77520
8304 PR c/77521
8305 * c-format.c (argument_parser::find_format_char_info): Use %qc
8306 format directive unconditionally.
8307
af63ba4b
JM
83082016-09-09 Jason Merrill <jason@redhat.com>
8309
8310 Implement C++17 new of over-aligned types.
8311 * c.opt: Add -faligned-new and -Waligned-new.
8312 * c-common.c (max_align_t_align): Split out from...
8313 (cxx_fundamental_alignment_p): ...here.
8314 * c-common.h: Declare it.
8315 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
8316
c65248cb
JM
83172016-09-09 Joseph Myers <joseph@codesourcery.com>
8318
8319 * c-cppbuiltin.c (builtin_define_type_width): New function.
8320 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
8321 macros.
8322
e5106e27
DM
83232016-09-07 David Malcolm <dmalcolm@redhat.com>
8324
8325 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
8326 a POINTER_TYPE.
8327 (substring_loc::get_location): Move to substring-locations.c,
8328 keeping implementation as...
8329 (c_get_substring_location): New function, from the above, reworked
8330 to use accessors rather than member lookup.
8331 * c-common.h (class substring_loc): Move to substring-locations.h,
8332 replacing with a forward decl.
8333 (c_get_substring_location): New decl.
8334 * c-format.c: Include "substring-locations.h".
8335 (format_warning_va): Move to substring-locations.c.
8336 (format_warning_at_substring): Likewise.
8337
ab20d992 83382016-09-06 Martin Sebor <msebor@redhat.com>
a42e7952
MS
8339
8340 PR c/77336
8341 * c-format.c (check_function_format): Avoid issuing warnings for
8342 functions unless they call format functions with non-constant
8343 format strings.
8344
b772a565
RB
83452016-09-06 Richard Biener <rguenther@suse.de>
8346
8347 PR c/77450
8348 * c-common.c (c_common_mark_addressable_vec): Handle
8349 COMPOUND_LITERAL_EXPR.
8350
25ff5dd3
MP
83512016-09-05 Marek Polacek <polacek@redhat.com>
8352
8353 PR c/77423
8354 * c-common.c (bool_promoted_to_int_p): New function.
8355 (expr_has_boolean_operands_p): New function.
8356 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
8357 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
8358
21234eb5
TV
83592016-09-04 Tom de Vries <tom@codesourcery.com>
8360
8361 revert:
8362 2016-08-29 Tom de Vries <tom@codesourcery.com>
8363
8364 * c-common.c (build_va_arg): Replace first argument type error
8365 with assert.
8366
9dc5773f
JJ
83672016-09-02 Jakub Jelinek <jakub@redhat.com>
8368
8369 PR c/65467
8370 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
8371 (c_finish_omp_for): Reject _Atomic qualified iterators.
8372
83732016-09-01 Martin Sebor <msebor@redhat.com>
3d7b83b6
MS
8374
8375 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
8376 size to guarantee it fits the output of the formatted function
8377 regardless of its arguments.
8378
295844f6
MP
83792016-09-01 Marek Polacek <polacek@redhat.com>
8380
8381 PR c/7652
8382 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
8383 FALLTHRU comments.
8384
3d06b6f2
MP
83852016-08-29 Marek Polacek <polacek@redhat.com>
8386
8387 PR c/77292
8388 * c-common.c (warn_logical_not_parentheses): Don't warn for
8389 a comparison or a logical operator.
8390
34cedad5
TV
83912016-08-29 Tom de Vries <tom@codesourcery.com>
8392
8393 * c-common.c (build_va_arg): Fix type comparison assert.
8394
f162d717
TV
83952016-08-29 Tom de Vries <tom@codesourcery.com>
8396
8397 * c-common.c (build_va_arg): Replace first argument type error
8398 with assert.
8399
ba9bbd6f
TV
84002016-08-29 Tom de Vries <tom@codesourcery.com>
8401
8402 PR c/77398
8403 * c-common.c (build_va_arg): Add first argument error. Build va_arg
8404 with error_mark_node as va_list instead of with illegal va_list.
8405
ebef225f
MP
84062016-08-25 Marek Polacek <polacek@redhat.com>
8407 David Malcolm <dmalcolm@redhat.com>
8408
8409 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
8410 * c-common.h (warn_logical_not_parentheses): Update declaration.
8411
b00e6e75
MP
84122016-08-22 Marek Polacek <polacek@redhat.com>
8413
8414 PR c++/77321
8415 * c-common.c (warn_for_memset): Check type for null.
8416
6dc198e3
JM
84172016-08-22 Joseph Myers <joseph@codesourcery.com>
8418
14ec014e 8419 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
6dc198e3
JM
8420 _FloatNx types for suffixes for built-in functions.
8421
c65699ef
JM
84222016-08-19 Joseph Myers <joseph@codesourcery.com>
8423
8424 PR c/32187
8425 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
8426 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
8427 (RID_FLOAT128X): New enum rid values.
8428 (CASE_RID_FLOATN_NX): New macro.
8429 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
8430 keywords.
8431 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
8432 corresponding complex types.
8433 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
8434 _FloatNx and corresponding complex types.
8435 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
8436 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
8437 and _FloatNx types for the widest type for determining
8438 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
8439 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
8440 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
8441 and _FloatNx types.
8442 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
8443 constants.
8444 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
8445 _FloatNx types.
8446
cc015f3a
DM
84472016-08-18 David Malcolm <dmalcolm@redhat.com>
8448
8449 * c-opts.c (c_diagnostic_finalizer): Update for change to
8450 diagnostic_show_locus.
8451
cb18fd07
DM
84522016-08-18 David Malcolm <dmalcolm@redhat.com>
8453
8454 * c-common.c: Include "spellcheck.h".
8455 (cb_get_suggestion): New function.
8456 * c-common.h (cb_get_suggestion): New decl.
8457 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
8458 cb_get_suggestion.
8459
a76989dc
MP
84602016-08-18 Marek Polacek <polacek@redhat.com>
8461
8462 PR c/71514
8463 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
8464 and pointer-to-VLA.
8465
65e736c0
DM
84662016-08-16 David Malcolm <dmalcolm@redhat.com>
8467
8468 PR c/72857
8469 * c-common.c (substring_loc::get_range): Rename to...
8470 (substring_loc::get_location): ...this, converting param from a
8471 source_range * to a location_t *. Call
8472 get_source_location_for_substring rather than
8473 get_source_range_for_substring, and pass in m_caret_idx.
8474 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
8475 (substring_loc::get_range): Replace with...
8476 (substring_loc::get_location): ...this.
8477 (substring_loc::set_caret_index): New method.
8478 (substring_loc): Add field m_caret_idx.
8479 * c-format.c (format_warning_va): Update for above changes.
8480 Rename local "substring_loc" to "fmt_substring_loc" to avoid
8481 clashing with type name.
8482 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
8483 (check_argument_type): Likewise.
8484 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
8485 Use a copy when emitting warnings, setting the caret index from TYPE.
8486
7e1dde14 84872016-08-16 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 8488 Arnaud Charlet <charlet@adacore.com>
7e1dde14
EB
8489
8490 * c-ada-spec.c (dump_number): New function.
8491 (handle_escape_character): Likewise.
8492 (print_ada_macros): Add handling of constant integers and strings.
8493
191816a3
MP
84942016-08-12 Marek Polacek <polacek@redhat.com>
8495
8496 PR c/7652
8497 * c-common.c (scalar_to_vector): Adjust fall through comment.
8498 * c-opts.c (c_common_handle_option): Likewise.
8499 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
8500 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
8501 fall through comment.
8502 * cilk.c (extract_free_variables): Add FALLTHRU.
8503
452df4a4
JM
85042016-08-10 Jason Merrill <jason@redhat.com>
8505
8506 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
8507
f3365c12
JM
85082016-08-09 Jason Merrill <jason@redhat.com>
8509
8510 * c-common.c (c_common_attribute_table): vector_size affects type
8511 identity.
8512
f0bc3323
MP
85132016-08-09 Marek Polacek <polacek@redhat.com>
8514
8515 PR c/7652
8516 * c-ada-spec.c (dump_generic_ada_node): Add return.
8517
98e5a19a
JM
85182016-08-09 Jason Merrill <jason@redhat.com>
8519
8520 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
8521 C++17 constexpr lambdas.
8522
895aa8e1
DM
85232016-08-08 David Malcolm <dmalcolm@redhat.com>
8524
8525 PR c/64955
8526 * c-common.h (selftest::c_format_c_tests): New declaration.
8527 (selftest::run_c_tests): New declaration.
8528 * c-format.c: Include "selftest.h.
8529 (format_warning_va): Add param "corrected_substring" and use
8530 it to add a replacement fix-it hint.
8531 (format_warning_at_substring): Likewise.
8532 (format_warning_at_char): Update for new param of
8533 format_warning_va.
8534 (argument_parser::check_argument_type): Pass "fki" to
8535 check_format_types.
8536 (check_format_types): Add param "fki" and pass it to
8537 format_type_warning.
8538 (deref_n_times): New function.
8539 (get_modifier_for_format_len): New function.
8540 (selftest::test_get_modifier_for_format_len): New function.
8541 (get_format_for_type): New function.
8542 (format_type_warning): Add param "fki" and use it to attempt
8543 to provide hints for argument types when calling
8544 format_warning_at_substring.
8545 (selftest::get_info): New function.
8546 (selftest::assert_format_for_type_streq): New function.
8547 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
8548 (selftest::test_get_format_for_type_printf): New function.
8549 (selftest::test_get_format_for_type_scanf): New function.
8550 (selftest::c_format_c_tests): New function.
8551
e52ed3fe
DM
85522016-08-08 David Malcolm <dmalcolm@redhat.com>
8553
8554 PR c/52952
8555 * c-format.c: Include "diagnostic.h".
8556 (location_column_from_byte_offset): Delete.
8557 (location_from_offset): Delete.
8558 (format_warning_va): New function.
8559 (format_warning_at_substring): New function.
8560 (format_warning_at_char): New function.
8561 (check_format_arg): Capture location of format_tree and pass to
8562 check_format_info_main.
8563 (argument_parser): Add fields "start_of_this_format" and
8564 "format_string_cst".
8565 (flag_chars_t::validate): Add param "format_string_cst". Convert
8566 warning_at call using location_from_offset to call to
8567 format_warning_at_char.
8568 (argument_parser::argument_parser): Add param "format_string_cst_"
8569 and use use it to initialize field "format_string_cst".
8570 Initialize new field "start_of_this_format".
8571 (argument_parser::read_format_flags): Convert warning_at call
8572 using location_from_offset to a call to format_warning_at_char.
8573 (argument_parser::read_any_format_left_precision): Likewise.
8574 (argument_parser::read_any_format_precision): Likewise.
8575 (argument_parser::read_any_other_modifier): Likewise.
8576 (argument_parser::find_format_char_info): Likewise, in three places.
8577 (argument_parser::parse_any_scan_set): Likewise, in one place.
8578 (argument_parser::handle_conversions): Likewise, in two places.
8579 (argument_parser::check_argument_type): Add param "fmt_param_loc"
8580 and use it to make a substring_loc. Pass the latter to
8581 check_format_types.
8582 (check_format_info_main): Add params "fmt_param_loc" and
8583 "format_string_cst". Convert warning_at calls using
8584 location_from_offset to calls to format_warning_at_char. Pass the
8585 new params to the arg_parser ctor. Pass "format_string_cst" to
8586 flag_chars.validate. Pass "fmt_param_loc" to
8587 arg_parser.check_argument_type.
8588 (check_format_types): Convert first param from a location_t
8589 to a const substring_loc & and rename to "fmt_loc". Attempt
8590 to extract the range of the relevant parameter and pass it
8591 to format_type_warning.
8592 (format_type_warning): Convert first param from a location_t
8593 to a const substring_loc & and rename to "fmt_loc". Add
8594 params "param_range" and "type". Replace calls to warning_at
8595 with calls to format_warning_at_substring.
8596
1c4d457e
DM
85972016-08-08 David Malcolm <dmalcolm@redhat.com>
8598
8599 * c-format.c (class flag_chars_t): New class.
8600 (struct length_modifier): New struct.
8601 (class argument_parser): New class.
8602 (flag_chars_t::flag_chars_t): New ctor.
8603 (flag_chars_t::has_char_p): New method.
8604 (flag_chars_t::add_char): New method.
8605 (flag_chars_t::validate): New method.
8606 (flag_chars_t::get_alloc_flag): New method.
8607 (flag_chars_t::assignment_suppression_p): New method.
8608 (argument_parser::argument_parser): New ctor.
8609 (argument_parser::read_any_dollar): New method.
8610 (argument_parser::read_format_flags): New method.
8611 (argument_parser::read_any_format_width): New method.
8612 (argument_parser::read_any_format_left_precision): New method.
8613 (argument_parser::read_any_format_precision): New method.
8614 (argument_parser::handle_alloc_chars): New method.
8615 (argument_parser::read_any_length_modifier): New method.
8616 (argument_parser::read_any_other_modifier): New method.
8617 (argument_parser::find_format_char_info): New method.
8618 (argument_parser::validate_flag_pairs): New method.
8619 (argument_parser::give_y2k_warnings): New method.
8620 (argument_parser::parse_any_scan_set): New method.
8621 (argument_parser::handle_conversions): New method.
8622 (argument_parser::check_argument_type): New method.
8623 (check_format_info_main): Introduce classes argument_parser
8624 and flag_chars_t, moving the code within the loop into methods
8625 of these classes. Make various locals "const".
8626
88fa5555
DM
86272016-08-05 David Malcolm <dmalcolm@redhat.com>
8628
8629 * c-common.c: Include "substring-locations.h".
8630 (get_cpp_ttype_from_string_type): New function.
8631 (g_string_concat_db): New global.
8632 (substring_loc::get_range): New method.
8633 * c-common.h (g_string_concat_db): New declaration.
8634 (class substring_loc): New class.
8635 * c-lex.c (lex_string): When concatenating strings, capture the
8636 locations of all tokens using a new obstack, and record the
8637 concatenation locations within g_string_concat_db.
8638 * c-opts.c (c_common_init_options): Construct g_string_concat_db
8639 on the ggc-heap.
8640
78169471
MP
86412016-07-29 Marek Polacek <polacek@redhat.com>
8642
638fc14f
MP
8643 PR c/71926
8644 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
8645 parentheses warning.
8646
78169471
MP
8647 PR c/71574
8648 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
8649
1225d6b1
ML
86502016-07-28 Martin Liska <mliska@suse.cz>
8651
8652 PR gcov-profile/68025
8653 * c-common.c (handle_no_profile_instrument_function_attribute):
8654
ec1e2a40
BE
86552016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
8656
8657 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
8658 BITS_PER_UNIT_LOG.
8659
5ec2cd9f
JM
86602016-07-25 Jason Merrill <jason@redhat.com>
8661
8662 PR c++/65970
8663 * c.opt (fconstexpr-loop-limit): New.
8664
9dc5773f 86652016-07-22 Martin Sebor <msebor@redhat.com>
2e6b45af
MS
8666
8667 PR c++/71675
8668 * c-common.c (resolve_overloaded_builtin): Avoid converting
8669 __atomic_compare_exchange_n return type to that of what its
8670 first argument points to.
8671
e3fe09c1
UB
86722016-07-22 Uros Bizjak <ubizjak@gmail.com>
8673
8674 * c-common.c: Use HOST_WIDE_INT_M1U instead of
8675 ~(unsigned HOST_WIDE_INT) 0.
8676
bc91c436
ML
86772016-07-22 Martin Liska <mliska@suse.cz>
8678
8679 PR gcov-profile/69028
8680 PR gcov-profile/62047
8681 * cilk.c (create_cilk_helper_decl): Set location of a new decl
8682 to the current_function_decl.
8683
451dcc66
JM
86842016-07-21 Jason Merrill <jason@redhat.com>
8685
8686 PR c++/65168
8687 * c-common.c (c_common_truthvalue_conversion): Check
8688 c_inhibit_evaluation_warnings for warning about address of
8689 reference.
8690
de6a69ee
DM
86912016-07-20 David Malcolm <dmalcolm@redhat.com>
8692
8693 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
8694 const char *.
8695
d022c55a
JM
86962016-07-15 Jason Merrill <jason@redhat.com>
8697
8698 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
8699
ddbbcb19
JJ
87002016-07-15 Jakub Jelinek <jakub@redhat.com>
8701
8702 PR c/71858
8703 * c-common.h (enum lookup_name_fuzzy_kind): Add
8704 FUZZY_LOOKUP_FUNCTION_NAME.
8705
d0cf395a
JM
87062016-07-08 Jason Merrill <jason@redhat.com>
8707
8708 P0145: Refining Expression Order for C++.
8709 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
8710 * c-opts.c: Adjust.
8711
98d44e93
MT
87122016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
8713
8714 PR c++/71214
8715 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
8716
f9d8d994
TS
87172016-06-29 Thomas Schwinge <thomas@codesourcery.com>
8718
8719 * c-pragma.h (enum pragma_kind): Rename
8720 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
8721 users.
8722
4aa83879
RB
87232016-06-29 Richard Biener <rguenther@suse.de>
8724
8725 PR middle-end/71002
8726 * c-common.c (c_common_get_alias_set): Remove union type punning case.
8727
a25bd9e6
JM
87282016-06-24 Jason Merrill <jason@redhat.com>
8729
8730 P0145R2: Refining Expression Order for C++.
8731 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
8732 MODIFY_EXPR.
8733
a86451b9
JJ
87342016-06-24 Jakub Jelinek <jakub@redhat.com>
8735
8736 * c-common.c (check_builtin_function_arguments): Require last
8737 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
8738 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
8739 if the last argument is pointer to enumerated or boolean type.
8740
1a4f11c8
DM
87412016-06-22 David Malcolm <dmalcolm@redhat.com>
8742
8743 PR c/70339
8744 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
8745 (lookup_name_fuzzy): New prototype.
8746
fe55692c
JDA
87472016-06-21 John David Anglin <danglin@gcc.gnu.org>
8748
8749 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
8750
4eb24e01
JM
87512016-06-14 Jason Merrill <jason@redhat.com>
8752
8753 P0145R2: Refining Expression Order for C++.
8754 * c.opt (fargs-in-order): New.
8755 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
8756
ef7cf206
JJ
87572016-06-13 Jakub Jelinek <jakub@redhat.com>
8758
0dda258b
JJ
8759 PR sanitizer/71498
8760 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
8761 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
8762
ef7cf206
JJ
8763 PR preprocessor/71183
8764 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
8765 to cb_get_source_date_epoch.
8766
50b15873
JJ
87672016-06-10 Jakub Jelinek <jakub@redhat.com>
8768
8769 PR c/68657
8770 * c.opt (Wpsabi): Add Warning flag.
8771
4d926e34
MS
87722016-06-10 Martin Sebor <msebor@redhat.com>
8773
8774 PR c/71392
14ec014e 8775 * c-common.c (handle_nonnull_attribute): Accept
4d926e34
MS
8776 the nonnull attribute in type-generic builtins.
8777
e01b4e16
MS
87782016-06-09 Martin Sebor <msebor@redhat.com>
8779
8780 PR c/70883
8781 * c-common.c (builtin_function_validate_nargs): Make text of error
8782 message consistent with others like it.
8783
44a845ca
MS
87842016-06-08 Martin Sebor <msebor@redhat.com>
8785 Jakub Jelinek <jakub@redhat.com>
8786
8787 PR c++/70507
8788 PR c/68120
8789 * c-common.c (check_builtin_function_arguments): Handle
8790 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
8791
a80a7051
RB
87922016-06-08 Richard Biener <rguenther@suse.de>
8793
8794 * c-common.c (parse_optimize_options): Improve diagnostic messages.
8795
bfd67b47
RB
87962016-06-07 Richard Biener <rguenther@suse.de>
8797
8798 PR c/61564
8799 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
8800 options and warn about others.
8801
15c98b2e
ES
88022016-06-01 Eduard Sanou <dhole@openmailbox.org>
8803
8804 * c-common.c (get_source_date_epoch): Rename to
8805 cb_get_source_date_epoch.
8806 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
8807 message when the parsing fails. Use error_at instead of fatal_error.
8808 * c-common.h (get_source_date_epoch): Rename to
8809 cb_get_source_date_epoch.
8810 * c-common.h (cb_get_source_date_epoch): Prototype.
8811 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
8812 * c-common.h (c_omp_region_type): Remove trailing comma.
8813 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
8814 * c-lex.c (c_lex_with_flags): Remove initialization of
8815 pfile->source_date_epoch.
8816
00631022
JJ
88172016-05-30 Jakub Jelinek <jakub@redhat.com>
8818
8819 PR c++/71349
8820 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
8821 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
8822 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
8823 instead of C_OMP_CLAUSE_SPLIT_FOR.
8824
f17a223d
RB
88252016-05-24 Richard Biener <rguenther@suse.de>
8826
8827 PR middle-end/70434
8828 PR c/69504
8829 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
8830 (convert_vector_to_array_for_subscript): ... this.
8831 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
8832 VIEW_CONVERT_EXPR to an array type. Rename to ...
8833 (convert_vector_to_array_for_subscript): ... this.
8834
4f2e1536
MP
88352016-05-12 Marek Polacek <polacek@redhat.com>
8836
8837 PR c/70756
8838 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
8839 size_in_bytes and pass LOC to it.
8840
d6e83a8d
MM
88412016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
8842
8843 PR c/43651
8844 * c.opt (Wduplicate-decl-specifier): New option.
8845
5c3a10fb
MP
88462016-05-11 Marek Polacek <polacek@redhat.com>
8847
8848 PR c++/71024
8849 * c-common.c (diagnose_mismatched_attributes): New function.
8850 * c-common.h (diagnose_mismatched_attributes): Declare.
8851
deef7113
MP
88522016-05-04 Marek Polacek <polacek@redhat.com>
8853
8854 * c.opt (Wdangling-else): New option.
8855
79ce98bc
MP
88562016-05-03 Marek Polacek <polacek@redhat.com>
8857
8858 PR c/70859
8859 * c-common.c (builtin_function_validate_nargs): Add location
8860 parameter. Use it.
8861 (check_builtin_function_arguments): Add location and arguments
8862 parameters. Use them.
8863 * c-common.h (check_builtin_function_arguments): Update declaration.
8864
381cdae4
RB
88652016-05-03 Richard Biener <rguenther@suse.de>
8866
8867 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
8868 allow call args to gimplify to SSA names.
8869
1d793c34
MP
88702016-05-03 Marek Polacek <polacek@redhat.com>
8871
8872 * c-common.h (enum c_omp_region_type): Remove stray comma.
8873
77886428
CP
88742016-05-02 Cesar Philippidis <cesar@codesourcery.com>
8875
8876 * c-common.h (enum c_omp_region_type): Define.
8877
697e0b28
RS
88782016-05-02 Richard Sandiford <richard.sandiford@arm.com>
8879
8880 * c-common.c (shorten_compare): Use wi::to_wide.
8881
e7ff0319
CP
88822016-04-29 Cesar Philippidis <cesar@codesourcery.com>
8883
8884 PR middle-end/70626
8885 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
8886 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
8887 reduction clauses in acc parallel loops.
8888
2fff3db8
MP
88892016-04-29 Marek Polacek <polacek@redhat.com>
8890
8891 PR c/70852
8892 * c-common.c (warn_for_memset): Check domain before accessing it.
8893
509063eb
DV
88942016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
8895
8896 PR/69089
8897 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
8898 "aligned" attribute.
8899
b632761d
JM
89002016-04-28 Jason Merrill <jason@redhat.com>
8901
8902 * c-lex.c (c_common_has_attribute): Handle nodiscard.
8903
174f6622
ES
89042016-04-28 Eduard Sanou <dhole@openmailbox.org>
8905 Matthias Klose <doko@debian.org>
8906
8907 * c-common.c (get_source_date_epoch): New function, gets the environment
7365279f 8908 variable SOURCE_DATE_EPOCH and parses it as long long with error
174f6622
ES
8909 handling.
8910 * c-common.h (get_source_date_epoch): Prototype.
8911 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
8912
6bc2bb18
RB
89132015-04-27 Ryan Burn <contact@rnburn.com>
8914
8915 PR c++/69024
8916 PR c++/68997
8917 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
8918 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
8919 external linkage.
8920 (cilk_detect_and_unwrap): Corresponding changes.
8921 (extract_free_variables): Don't extract free variables from
8922 AGGR_INIT_EXPR slot.
8923 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
8924 (cilk_recognize_spawn): Likewise.
8925
c1e1f433
BS
89262016-04-27 Bernd Schmidt <bschmidt@redhat.com>
8927
8928 * c.opt (Wmemset-elt-size): New option.
8929 * c-common.c (warn_for_memset): New function.
8930 * c-common.h (warn_for_memset): Declare.
8931
d067e05f
JM
89322016-04-25 Jason Merrill <jason@redhat.com>
8933
8934 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
8935 No longer static.
8936 * c-common.h: Declare it.
8937 * c-lex.c (c_common_has_attribute): Add maybe_unused.
8938
9aa36ae5
JM
89392016-04-22 Jason Merrill <jason@redhat.com>
8940
8941 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
8942
477d4906
IV
89432016-04-20 Ilya Verbin <ilya.verbin@intel.com>
8944
8945 PR c++/69363
8946 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
8947 * c-common.h (c_finish_cilk_clauses): Remove declaration.
8948
fe37c7af
MM
89492016-04-18 Michael Matz <matz@suse.de>
8950
8951 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
8952 and SET_DECL_ALIGN.
8953
23f2660f
EB
89542016-04-17 Eric Botcazou <ebotcazou@adacore.com>
8955
8956 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
8957 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
8958 to incomplete types.
8959 (dump_nested_type): Remove redundant tests and tidy up.
8960 (print_ada_declaration): Also set TREE_VISITED on the declaration of
8961 a type which is the typedef of an original type.
8962
1e77281b
MP
89632016-04-15 Marek Polacek <polacek@redhat.com>
8964
8965 PR c/70651
8966 * c-common.c (build_va_arg): Change two asserts into errors and return
8967 error_mark_node.
8968
b3a77f21
MP
89692016-04-13 Marek Polacek <polacek@redhat.com>
8970
8971 PR c++/70639
8972 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
8973 for switch statements, too.
8974
322b8466
JM
89752016-03-28 Jason Merrill <jason@redhat.com>
8976
8977 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
8978
fbdb6baf
MP
89792016-03-23 Marek Polacek <polacek@redhat.com>
8980
8981 PR c++/69884
8982 * c.opt (Wignored-attributes): New option.
8983
5c240f4d
DM
89842016-03-22 David Malcolm <dmalcolm@redhat.com>
8985
8986 PR c/69993
8987 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
8988 diagnostic text, reversing the order of the warning and note so
8989 that they appear in source order.
8990
14ba7b28
MP
89912016-03-17 Marek Polacek <polacek@redhat.com>
8992
8993 PR c/69407
8994 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
8995 operations.
8996
08a1cadc
JM
89972016-03-14 Jason Merrill <jason@redhat.com>
8998
2aaeea19
JM
8999 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
9000
08a1cadc
JM
9001 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
9002
c06d25bb
RB
90032016-03-09 Richard Biener <rguenther@suse.de>
9004
9005 PR c/70143
9006 * c-common.c (strict_aliasing_warning): Add back
9007 alias_sets_conflict_p check.
9008
80aac5c8
JM
90092016-03-08 Jason Merrill <jason@redhat.com>
9010
9011 * c-opts.c (set_std_cxx1z): Don't enable concepts.
9012
64b23c13
DM
90132016-03-04 David Malcolm <dmalcolm@redhat.com>
9014
9015 PR c/68187
9016 * c-indentation.c (get_visual_column): Move code to determine next
9017 tab stop to...
9018 (next_tab_stop): ...this new function.
9019 (line_contains_hash_if): Delete function.
9020 (detect_preprocessor_logic): Delete function.
9021 (get_first_nws_vis_column): New function.
9022 (detect_intervening_unindent): New function.
9023 (should_warn_for_misleading_indentation): Replace call to
9024 detect_preprocessor_logic with a call to
9025 detect_intervening_unindent.
9026
729526f5
DM
90272016-03-04 David Malcolm <dmalcolm@redhat.com>
9028
9029 PR c/68187
9030 * c-indentation.c (should_warn_for_misleading_indentation): When
9031 suppressing warnings about cases where the guard and body are on
9032 the same column, only use the first non-whitespace column in place
9033 of the guard token column when dealing with "else" clauses.
9034 When rejecting aligned BODY and NEXT, loosen the requirement
9035 from equality with the first non-whitespace of guard to simply
9036 that they not be indented relative to it.
9037
e9a35493
RB
90382016-03-04 Richard Biener <rguenther@suse.de>
9039
9040 PR c++/70054
9041 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
9042 instead of alias_sets_conflict_p.
9043
1be56bc5
MP
90442016-03-01 Marek Polacek <polacek@redhat.com>
9045
9046 PR c++/69795
9047 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
9048 any DECL.
9049
35886f0b
MS
90502016-02-22 Martin Sebor <msebor@redhat.com>
9051
9052 PR middle-end/69780
9053 * c-common.c (check_builtin_function_arguments): Validate and
9054 reject invalid arguments to __builtin_alloca_with_align.
9055
4246c8da
MW
90562016-02-20 Mark Wielaard <mjw@redhat.com>
9057
9058 PR c/28901
9059 * c.opt (Wunused-const-variable): Turn into Alias for...
9060 (Wunused-const-variable=): New option.
9061
268be88c
BE
90622016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
9063
9064 PR c++/69865
9065 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
9066 here...
9067 (c_common_init_options): ...to here.
9068 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
9069
871b3f47
JJ
90702016-02-19 Jakub Jelinek <jakub@redhat.com>
9071
9072 PR c++/69826
9073 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
9074 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
9075 flag_preprocess_only.
9076
bf14eba2
JJ
90772016-02-16 Jakub Jelinek <jakub@redhat.com>
9078
9079 PR c/69835
9080 * c.opt (Wnonnull-compare): Enable for -Wall.
9081
ba6b3795
JJ
90822016-02-15 Jakub Jelinek <jakub@redhat.com>
9083
9084 PR c++/69797
9085 * c-common.c (sync_resolve_size): Diagnose too few arguments
9086 even when params is non-NULL empty vector.
9087
a011cd92
BS
90882016-02-08 Bernd Schmidt <bschmidt@redhat.com>
9089
9090 PR target/60410
9091 * c.opt (fshort-double): Remove.
9092
46cb9332
MS
90932016-02-05 Martin Sebor <msebor@redhat.com>
9094
9095 PR c++/69662
9096 * c.opt (Warning options): Update -Wplacement-new to take
9097 an optional argument.
9098
e1b81f2b
JJ
90992016-02-01 Jakub Jelinek <jakub@redhat.com>
9100
9101 PR preprocessor/69543
9102 PR c/69558
9103 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
9104 instead of loc to control_warning_option.
9105
b6adbb9f
NS
91062016-02-01 Nathan Sidwell <nathan@codesourcery.com>
9107
9108 * c.opt (fopenacc-dim=): New option.
9109
5d70666e
RB
91102016-01-27 Ryan Burn <contact@rnburn.com>
9111
9112 PR cilkplus/69267
9113 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
9114 gimplify_arg. Removed superfluous post_p argument.
9115 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
9116 superfluous post_p argument.
9117 * c-gimplify.c (c_gimplify_expr): Likewise.
9118
01e1dea3
DM
91192016-01-26 David Malcolm <dmalcolm@redhat.com>
9120
9121 PR other/69006
9122 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
9123 pp_newline_and_flush with pp_flush.
9124
9f04a53e
MS
91252016-01-20 Martin Sebor <msebor@redhat.com>
9126
9127 PR c/69405
9128 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
9129 an incompatible argument when the argument isn't a valid tree node.
9130
7f26f7df
JM
91312016-01-18 Jason Merrill <jason@redhat.com>
9132
9133 PR c++/68767
9134 * c-common.c (check_function_arguments_recurse): Fold the whole
9135 COND_EXPR, not just the condition.
9136
f62bf092
TV
91372016-01-18 Tom de Vries <tom@codesourcery.com>
9138
9139 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
9140 classify as loop clause.
9141
e0a575ff
JJ
91422016-01-15 Jakub Jelinek <jakub@redhat.com>
9143
9144 PR bootstrap/68271
9145 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
9146 C++ FE no longer has limit on number of pragmas.
9147
91482015-01-14 Ryan Burn <contact@rnburn.com>
b6e3db06
RB
9149
9150 PR c++/69048
9151 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
c47eaca6 9152 to add missing cleanup point.
b6e3db06 9153
c7df95d8
DM
91542016-01-14 David Malcolm <dmalcolm@redhat.com>
9155
9156 PR c++/68819
9157 * c-indentation.c (get_visual_column): Add location_t param.
9158 Handle the column number being zero by effectively disabling the
9159 warning, with an "inform".
9160 (should_warn_for_misleading_indentation): Add location_t argument
9161 for all uses of get_visual_column.
9162
21efdd80
PP
91632016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
9164
9165 PR c++/69029
9166 * c-indentation.c (should_warn_for_misleading_indentation):
9167 Don't warn about do-while statements.
9168
7a127fa7
MS
91692016-01-07 Martin Sebor <msebor@redhat.com>
9170
9171 PR c/68966
9172 * c-common.c (sync_resolve_size): Reject first argument when it's
9173 a pointer to _Bool.
9174
c589e975
DM
91752016-01-05 David Malcolm <dmalcolm@redhat.com>
9176
9177 PR c/69122
9178 * c-indentation.c (get_visual_column): Remove default argument.
9179 (should_warn_for_misleading_indentation): For the multiline case,
9180 update call to get_visual_column for next_stmt_exploc so that it
9181 captures the location of the first non-whitespace character in the
9182 relevant line. Don't issue warnings if there is non-whitespace
9183 before the next statement.
9184
818ab71a
JJ
91852016-01-04 Jakub Jelinek <jakub@redhat.com>
9186
9187 Update copyright years.
9188
745e411d
DM
91892015-12-21 David Malcolm <dmalcolm@redhat.com>
9190
9191 * c-common.c (binary_op_error): Convert first param from
9192 location_t to rich_location * and use it when emitting an error.
9193 * c-common.h (binary_op_error): Convert first param from
9194 location_t to rich_location *.
9195
de67c4c3
DM
91962015-12-16 David Malcolm <dmalcolm@redhat.com>
9197
9198 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
9199 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
9200
4a38b02b
IV
92012015-12-15 Ilya Verbin <ilya.verbin@intel.com>
9202
9203 * c-common.c (c_common_attribute_table): Handle "omp declare target
9204 link" attribute.
9205
54d62f51
JJ
92062015-12-14 Jakub Jelinek <jakub@redhat.com>
9207
9208 PR c/68833
9209 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
9210
8d4227c8
TB
92112014-12-12 Tobias Burnus <burnus@net-b.de>
9212
9213 PR fortran/68815
9214 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
9215 specifiers (%d, %i,%u and %c).
9216
f6069ccc
DM
92172015-12-10 David Malcolm <dmalcolm@redhat.com>
9218
9219 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
9220
63bbf46d
JJ
92212015-12-08 Jakub Jelinek <jakub@redhat.com>
9222
9223 PR c/48088
9224 PR c/68657
9225 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
9226 * c-pragma.c (handle_pragma_diagnostic): Adjust
9227 control_warning_option caller.
9228
f79520bb
DM
92292015-12-07 David Malcolm <dmalcolm@redhat.com>
9230
9231 * c-common.c (c_cpp_error): Update for change to
9232 rich_location::set_range.
9233
b3d5bc62
JJ
92342015-12-04 Paolo Bonzini <bonzini@gnu.org>
9235
9236 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
9237 shifting 1 out of the sign bit.
9238
92392015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
9240
9241 * c-common.c (c_common_attribute_table[]): Update max arguments
9242 count for "simd" attribute.
9243 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
9244
6eb4a537
JJ
92452015-12-03 Jakub Jelinek <jakub@redhat.com>
9246
9247 PR preprocessor/57580
9248 * c-ppoutput.c (print): Change printed field to bool.
9249 Move src_file last for smaller padding.
9250 (init_pp_output): Set print.printed to false instead of 0.
9251 (scan_translation_unit): Fix up formatting. Set print.printed
9252 to true after printing something other than newline.
9253 (scan_translation_unit_trad): Set print.printed to true instead of 1.
9254 (maybe_print_line_1): Set print.printed to false instead of 0.
9255 (print_line_1): Likewise.
9256 (do_line_change): Set print.printed to true instead of 1.
9257 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
9258 dump_macro): Set print.printed to false after printing newline.
9259
4250754e
JM
92602015-12-02 Jason Merrill <jason@redhat.com>
9261
f479b43d
JM
9262 * c-common.c (fold_for_warn): New.
9263 (warn_logical_operator, warn_tautological_cmp)
9264 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
9265
4250754e
JM
9266 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
9267 (c_fully_fold_internal, decl_constant_value_for_optimization):
9268 Move to c/c-fold.c.
9269 * c-common.h: Don't declare decl_constant_value_for_optimization.
9270
e9e32ee6
JM
92712015-12-02 Joseph Myers <joseph@codesourcery.com>
9272
9273 PR c/68162
9274 * c-common.h (c_build_qualified_type): Add extra default
9275 arguments.
9276
37d5ad46
JB
92772015-12-01 Julian Brown <julian@codesourcery.com>
9278 Cesar Philippidis <cesar@codesourcery.com>
9279 James Norris <James_Norris@mentor.com>
9280
9281 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
9282 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
9283 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
9284
f07862c7
EB
92852015-11-30 Eric Botcazou <ebotcazou@adacore.com>
9286
9287 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
9288 (decl_sloc_common): Delete and move bulk of processing to...
9289 (decl_sloc): ...here.
9290 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
9291 (dump_ada_double_name): Remove S parameter and compute the suffix.
9292 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
9293 element type and deal with an anonymous one.
9294 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
9295 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
9296 and remove reference to QUAL_UNION_TYPE.
9297 (dump_nested_types): Make 2 passes on the fields and move bulk to...
9298 (dump_nested_type): ...here. New function extracted from above.
9299 Generate a full declaration for anonymous element type of arrays.
9300 (print_ada_declaration): Really skip anonymous declarations. Remove
9301 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
9302 Clean up processing of declarations of array types and objects.
9303 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
9304 Remove obsolete code and tidy up.
9305
75c8aac3
JH
93062015-11-29 Jan Hubicka <hubicka@ucw.cz>
9307
9308 PR c/67581
9309 * c-common.c (handle_transparent_union_attribute): Update
9310 also type variants.
9311
b58d3df2
ML
93122015-11-27 Martin Liska <mliska@suse.cz>
9313
9314 PR c++/68312
9315 * array-notation-common.c (cilkplus_extract_an_triplets):
9316 Release vector of vectors.
9317 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
9318
89a01fcf
EB
93192015-11-26 Eric Botcazou <ebotcazou@adacore.com>
9320
9321 PR c++/68527
9322 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
9323 (print_ada_struct_decl): Likewise.
9324
cc5c5226
IZ
93252015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
9326
9327 PR c++/68001
9328 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
9329 * cilk.c (recognize_spawn): Determine location in a more precise
9330 way.
9331
269adb9d
JM
93322015-11-19 Jason Merrill <jason@redhat.com>
9333
9334 * c-common.c (shorten_compare): But look through macros from
9335 system headers.
9336
d0eccfcd
JM
93372015-11-18 Jason Merrill <jason@redhat.com>
9338
9339 * c-common.c (shorten_compare): Don't -Wtype-limits if the
9340 non-constant operand comes from a macro.
9341
3e44547c
JM
93422015-11-17 Jason Merrill <jason@redhat.com>
9343
9344 PR bootstrap/68346
9345 * c-common.c (warn_tautological_cmp): Fold before checking for
9346 constants.
9347
0f62c7a0
MP
93482015-11-16 Marek Polacek <polacek@redhat.com>
9349
9350 PR c++/68362
9351 * c-common.c (check_case_bounds): Fold low and high cases.
9352
a868811e
MP
93532015-11-16 Marek Polacek <polacek@redhat.com>
9354
9355 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
9356 * c-common.c (c_common_get_alias_set): Likewise.
9357 (handle_visibility_attribute): Likewise.
9358
fff77217
KY
93592015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
9360
9361 * c-common.c (handle_simd_attribute): New.
9362 (struct attribute_spec): Add entry for "simd".
9363 (handle_simd_attribute): New.
9364
269e63b7
KT
93652015-11-13 Kai Tietz <ktietz70@googlemail.com>
9366
9367 * c-lex.c (interpret_float): Use fold_convert.
9368
ebedc9a3
DM
93692015-11-13 David Malcolm <dmalcolm@redhat.com>
9370
9371 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
9372 and store it on the result.
9373 * c-opts.c (c_common_init_options): Set
9374 global_dc->colorize_source_p.
9375
6e232ba4
JN
93762015-11-12 James Norris <jnorris@codesourcery.com>
9377 Joseph Myers <joseph@codesourcery.com>
9378
7365279f 9379 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
6e232ba4
JN
9380 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
9381 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
9382 PRAGMA_OACC_CLAUSE_LINK.
9383
e78bede6
MP
93842015-11-11 Marek Polacek <polacek@redhat.com>
9385
9386 PR c/68107
9387 PR c++/68266
9388 * c-common.c (valid_array_size_p): New function.
9389 * c-common.h (valid_array_size_p): Declare.
9390
3f8257db 93912015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4ac93c7c
DH
9392
9393 PR bootstrap/68271
9394 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
9395
69f293c9
AM
93962015-11-11 Andrew MacLeod <amacleod@redhat.com>
9397
9398 * array-notation-common.c: Remove unused header files.
9399 * c-ada-spec.c: Likewise.
9400 * c-cilkplus.c: Likewise.
9401 * c-common.c: Likewise.
9402 * c-cppbuiltin.c: Likewise.
9403 * c-dump.c: Likewise.
9404 * c-format.c: Likewise.
9405 * c-gimplify.c: Likewise.
9406 * c-indentation.c: Likewise.
9407 * c-lex.c: Likewise.
9408 * c-omp.c: Likewise.
9409 * c-opts.c: Likewise.
9410 * c-pch.c: Likewise.
9411 * c-ppoutput.c: Likewise.
9412 * c-pragma.c: Likewise.
9413 * c-pretty-print.c: Likewise.
9414 * c-semantics.c: Likewise.
9415 * c-ubsan.c: Likewise.
9416 * cilk.c: Likewise.
9417 * stub-objc.c: Likewise.
9418
3a40d81d
NS
94192015-11-09 Thomas Schwinge <thomas@codesourcery.com>
9420 Cesar Philippidis <cesar@codesourcery.com>
9421 James Norris <jnorris@codesourcery.com>
9422 Julian Brown <julian@codesourcery.com>
9423 Nathan Sidwell <nathan@codesourcery.com>
9424
9425 * c-pragma.c (oacc_pragmas): Add "routine".
9426 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
9427
ee45a32d
EB
94282015-11-08 Eric Botcazou <ebotcazou@adacore.com>
9429
9430 * c-common.c (c_common_attributes): Add scalar_storage_order.
9431 (handle_scalar_storage_order_attribute): New function.
9432 * c-pragma.c (global_sso): New variable.
9433 (maybe_apply_pragma_scalar_storage_order): New function.
9434 (handle_pragma_scalar_storage_order): Likewise.
9435 (init_pragma): Register scalar_storage_order.
9436 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
9437 * c.opt (Wscalar-storage-order): New warning.
9438 (fsso-struct=): New option.
9439
eb11eb15
MS
94402015-11-08 Martin Sebor <msebor@redhat.com>
9441
9442 * c.opt (Wplacement-new): Add a period to the end of a sentence.
9443
0aad0198
RS
94442015-11-07 Richard Sandiford <richard.sandiford@arm.com>
9445
9446 * c-common.c: Don't undef DEF_BUILTIN.
9447
8a645150
DM
94482015-11-06 David Malcolm <dmalcolm@redhat.com>
9449
9450 * c-common.c (c_cpp_error): Convert parameter from location_t to
9451 rich_location *. Eliminate the "column_override" parameter and
9452 the call to diagnostic_override_column.
9453 Update the "done_lexing" clause to set range 0
9454 on the rich_location, rather than overwriting a location_t.
9455 * c-common.h (c_cpp_error): Convert parameter from location_t to
9456 rich_location *. Eliminate the "column_override" parameter.
9457
7a5e4956
CP
94582015-11-05 Cesar Philippidis <cesar@codesourcery.com>
9459 Thomas Schwinge <thomas@codesourcery.com>
9460 James Norris <jnorris@codesourcery.com>
9461
9462 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
9463 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
9464 clauses with parallel and kernels and loops.
9465 * c-pragma.h (enum pragma_omp_clause): Add entries for
9466 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
9467 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
9468 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
9469 INDEPENDENT,SEQ}.
9470 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
9471
e2f5cc96
MS
94722015-11-05 Martin Sebor <msebor@redhat.com>
9473
9474 PR c++/67942
9475 * c.opt (-Wplacement-new): New option.
9476
e01d41e5
JJ
94772015-11-05 Jakub Jelinek <jakub@redhat.com>
9478
9479 * c-common.h (c_finish_omp_atomic): Add TEST argument.
9480 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
9481 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
9482 save_expr or create_tmp_var* if TEST is true.
9483 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
9484 Don't call add_stmt here.
9485 (struct c_omp_check_loop_iv_data): New type.
9486 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
9487 c_omp_check_loop_iv_exprs): New functions.
9488 (c_omp_split_clauses): Adjust for lastprivate being allowed on
9489 distribute.
9490 (c_omp_declare_simd_clauses_to_numbers): Change
9491 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
9492 (c_omp_declare_simd_clauses_to_decls): Similarly change those
9493 from numbers to PARM_DECLs.
9494
595278be
MM
94952015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
9496
9497 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
9498 flag_checking.
9499
3f8257db 95002015-11-03 Bernd Schmidt <bschmidt@redhat.com>
c85158de
MS
9501
9502 PR c++-common/67882
b3d5bc62
JJ
9503 * c-common.h (fold_offsetof_1): Add argument.
9504 * c-common.c (fold_offsetof_1): Diagnose more invalid
c85158de
MS
9505 offsetof expressions that reference elements past the end of
9506 an array.
9507
4bf9e5a8
TS
95082015-11-03 Thomas Schwinge <thomas@codesourcery.com>
9509 Chung-Lin Tang <cltang@codesourcery.com>
9510
9511 * c-pragma.c (oacc_pragmas): Add "atomic".
9512 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
9513
3b1661a9
ES
95142015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
9515
9516 * c-common.c (handle_target_clones_attribute): New.
9517 (c_common_attribute_table): Add handle_target_clones_attribute.
9518 (handle_always_inline_attribute): Add check on target_clones attribute.
9519 (handle_target_attribute): Ditto.
9520
2adfab87
AM
95212015-10-29 Andrew MacLeod <amacleod@redhat.com>
9522
9523 * array-notation-common.c: Reorder #include's and remove duplicates.
9524 * c-ada-spec.c: Likewise.
9525 * c-cilkplus.c: Likewise.
9526 * c-common.c: Likewise.
9527 * c-cppbuiltin.c: Likewise.
9528 * c-dump.c: Likewise.
9529 * c-format.c: Likewise.
9530 * c-gimplify.c: Likewise.
9531 * c-indentation.c: Likewise.
9532 * c-lex.c: Likewise.
9533 * c-omp.c: Likewise.
9534 * c-opts.c: Likewise.
9535 * c-pch.c: Likewise.
9536 * c-ppoutput.c: Likewise.
9537 * c-pragma.c: Likewise.
9538 * c-pretty-print.c: Likewise.
9539 * c-semantics.c: Likewise.
9540 * c-ubsan.c: Likewise.
9541 * cilk.c: Likewise.
9542 * stub-objc.c: Likewise.
9543
d90ec4f2
JM
95442015-10-28 Jason Merrill <jason@redhat.com>
9545
9546 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
9547
88bae6f4
TS
95482015-10-27 Thomas Schwinge <thomas@codesourcery.com>
9549 James Norris <jnorris@codesourcery.com>
9550 Cesar Philippidis <cesar@codesourcery.com>
9551
9552 PR c/64765
9553 PR c/64880
9554 * c-common.h (c_oacc_split_loop_clauses): Declare function.
9555 * c-omp.c (c_oacc_split_loop_clauses): New function.
9556
b1726d6c
MS
95572015-10-21 Martin Sebor <msebor@redhat.com>
9558
9559 PR driver/68043
9560 * c.opt: End each sentence that describes an option with a period.
9561
fa60eeb9
MP
95622015-10-20 Marek Polacek <polacek@redhat.com>
9563
9564 * array-notation-common.c (is_cilkplus_vector_p): Define.
9565 * c-common.h (is_cilkplus_vector_p): Declare.
9566
95979049
MP
95672015-10-20 Marek Polacek <polacek@redhat.com>
9568
9569 * c.opt (std=gnu++11): Do not describe as experimental.
9570 (std=gnu++14): Likewise.
9571
2a9fb712
JM
95722015-10-19 Jason Merrill <jason@redhat.com>
9573
9574 * c-cppbuiltin.c (c_cpp_builtins): Define
9575 __cpp_nontype_template_args.
9576
13b380a3
JM
95772015-10-19 Jason Merrill <jason@redhat.com>
9578
9579 * c-cppbuiltin.c (c_cpp_builtins): Define
9580 __cpp_enumerator_attributes, __cpp_fold_expressions,
9581 __cpp_unicode_characters.
9582
d9a6bd32
JJ
95832015-10-13 Jakub Jelinek <jakub@redhat.com>
9584 Aldy Hernandez <aldyh@redhat.com>
9585
9586 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
9587 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
9588 (c_define_builtins): Likewise.
9589 * c-common.h (enum c_omp_clause_split): Add
9590 C_OMP_CLAUSE_SPLIT_TASKLOOP.
9591 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
9592 (c_finish_omp_for): Add ORIG_DECLV argument.
9593 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
9594 201511 instead of 201307.
9595 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
9596 OMP_CRITICAL_CLAUSES to it.
9597 (c_finish_omp_ordered): Add CLAUSES argument, set
9598 OMP_ORDERED_CLAUSES to it.
9599 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
9600 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
9601 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
9602 constructs and new OpenMP 4.5 clauses. Clear
9603 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
9604 verification code.
9605 * c-pragma.c (omp_pragmas_simd): Add taskloop.
9606 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
9607 (enum pragma_omp_clause): Add
9608 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
9609 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
9610
624d31fe
RS
96112015-10-05 Richard Sandiford <richard.sandiford@arm.com>
9612
9613 * c-lex.c (interpret_float): Use real_equal instead of
9614 REAL_VALUES_EQUAL.
9615
b8fd7909
JM
96162015-10-04 Jason Merrill <jason@redhat.com>
9617
9618 Implement N4514, C++ Extensions for Transactional Memory.
9619 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
9620 (c_common_attribute_table): Add transaction_safe_dynamic.
9621 transaction_safe now affects type identity.
9622 (handle_tm_attribute): Handle transaction_safe_dynamic.
9623 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
9624 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
9625 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
9626 (D_TRANSMEM): New.
9627 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
9628 * c-pretty-print.c (pp_c_attributes_display): Don't print
9629 transaction_safe in C++.
9630
12651878
MP
96312015-10-02 Marek Polacek <polacek@redhat.com>
9632
9633 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
9634
3e3b8d63
MP
96352015-10-02 Marek Polacek <polacek@redhat.com>
9636
9637 PR c/64249
9638 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
9639 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
9640 * c.opt (Wduplicated-cond): New option.
9641
0d1a8f75
JM
96422015-10-01 Joseph Myers <joseph@codesourcery.com>
9643
9644 * c.opt (std=c11): Do not describe as experimental.
9645 (std=gnu11): Likewise.
9646 (std=iso9899:2011): Likewise.
9647
3e32ee19
NS
96482015-09-28 Nathan Sidwell <nathan@codesourcery.com>
9649
9650 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
9651 (DEF_FUNCTION_TYPE_VAR_11): Delete.
9652
974348ee
MP
96532015-09-25 Marek Polacek <polacek@redhat.com>
9654
9655 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
9656 (ubsan_instrument_shift): Likewise.
9657
15dbc1a6
MP
96582015-09-25 Marek Polacek <polacek@redhat.com>
9659
9660 PR sanitizer/64906
9661 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
9662
6b95d7cc
PP
96632015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
9664
9665 * c-indentation.c (should_warn_for_misleading_indentation):
9666 Compare next_stmt_vis_column with guard_line_first_nws instead
9667 of with guard_line_vis_column.
9668
c1822f9c
MLI
96692015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
9670
9671 PR c/49654
9672 PR c/49655
9673 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
9674 options and options not valid for the current language.
9675
d5398058
PP
96762015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
9677
9678 * c-indentation.c (should_warn_for_misleading_indentation):
9679 Float out and consolidate the calls to get_visual_column that
9680 are passed guard_exploc as an argument. Compare
9681 next_stmt_vis_column with guard_line_first_nws instead of with
9682 body_line_first_nws.
9683
6b333269
NS
96842015-09-22 Nathan Sidwell <nathan@codesourcery.com>
9685
9686 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
9687 Wnamespaces): New C++ warnings.
9688
a75f1574
JM
96892015-09-22 Jason Merrill <jason@redhat.com>
9690
9691 * c-common.h (abi_compat_version_crosses): New.
9692 (warn_abi_version): Declare.
9693 * c-common.c: Define it.
9694 * c-opts.c (c_common_post_options): Handle it.
9695 flag_abi_compat_version defaults to 8.
9696
bdaaa8b7
VV
96972015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
9698
9699 Complete the implementation of N4230, Nested namespace definition.
9700 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
9701 __cpp_nested_namespace_definitions.
9702
eaa797e8
MLI
97032015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
9704
9705 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
9706
c4914de6
MLI
97072015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
9708
9709 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
9710 when warning.
9711 * c-pragma.h (pragma_lex): Add optional loc argument.
9712
fcb87c50
MM
97132015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
9714
9715 * c-format.c (check_format_arg): Adjust to use common block size in all
9716 object pools.
9717
31bdd08a
DM
97182015-09-15 David Malcolm <dmalcolm@redhat.com>
9719
9720 * c-format.c (location_from_offset): Update for change in
9721 signature of location_get_source_line.
9722 * c-indentation.c (get_visual_column): Likewise.
9723 (line_contains_hash_if): Likewise.
9724
aa9f4b4c
MP
97252015-09-14 Marek Polacek <polacek@redhat.com>
9726
9727 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
9728 setting various warnings.
9729
aa256c4a
MP
97302015-09-14 Marek Polacek <polacek@redhat.com>
9731
9732 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
9733 a negative value.
9734
0f876f22
MW
97352015-09-11 Mark Wielaard <mjw@redhat.com>
9736
9737 PR c/28901
9738 * c.opt (Wunused-variable): Option from common.opt.
9739 (Wunused-const-variable): New option.
9740
273aa49e
PC
97412015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
9742
9743 PR c++/53184
9744 * c.opt ([Wsubobject-linkage]): Add.
9745
1807ffc1
MS
97462015-09-03 Martin Sebor <msebor@redhat.com>
9747
9748 PR c/66516
9749 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
9750 functions.
9751 * c-common.c (reject_gcc_builtin): Define.
9752
38942840
BI
97532015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
9754
9755 PR middle-end/60586
9756 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
9757 prototype.
9758 * c-gimplify.c (c_gimplify_expr): Added a call to the function
9759 cilk_gimplify_call_params_in_spawned_fn.
9760 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
9761 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
9762 unwrapping.
9763
c316b5e4
MP
97642015-08-25 Marek Polacek <polacek@redhat.com>
9765
9766 PR middle-end/67330
9767 * c-common.c (handle_weak_attribute): Don't check whether the
9768 visibility can be changed here.
9769
584a7c46
MLI
97702015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
9771
9772 * c-lex.c (c_lex_with_flags): Use explicit locations.
9773
a79683d5
TS
97742015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
9775
9776 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
9777 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
9778
61717a45
FXC
97792015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
9780
9781 PR middle-end/36757
9782 * c-common.c (check_builtin_function_arguments): Add check
9783 for BUILT_IN_SIGNBIT argument.
9784
329524f5
PC
97852015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
9786
9787 PR c++/67160
9788 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
9789 in c++1z mode.
9790
4ee55665
MP
97912015-08-17 Marek Polacek <polacek@redhat.com>
9792
9793 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
9794 with whitespaces before qualifier names.
9795
b893e375
MP
97962015-08-12 Marek Polacek <polacek@redhat.com>
9797
9798 PR c++/55095
9799 * c-common.c (maybe_warn_shift_overflow): Properly handle
9800 left-shifting 1 into the sign bit.
9801
c2d89095
MLI
98022015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
9803
9804 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
9805
971e17ff
AS
98062015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
9807 Braden Obrzut <admin@maniacsvault.net>
9808 Jason Merrill <jason@redhat.com>
9809
9810 Add C++ Concepts TS support.
9811 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
9812 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
9813 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
9814 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
9815 * c-opts.c (set_std_cxx1z): Set flag_concepts.
9816 * c.opt (fconcepts): New.
9817
b3d5bc62
JJ
98182015-08-02 Martin Sebor <msebor@redhat.com>
9819
9820 * c.opt (-Wframe-address): New warning option.
9821
8ebca419
PP
98222015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
9823
9824 * c-indentation.c (should_warn_for_misleading_indentation):
9825 Improve heuristics.
9826
1a1e101f
PP
98272015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
9828
9829 * c-indentation.c (get_visual_column): Add parameter first_nws,
9830 use it. Update comment documenting the function.
9831 (is_first_nonwhitespace_on_line): Remove.
9832 (should_warn_for_misleading_indentation): Replace usage of
9833 of is_first_nonwhitespace_on_line with get_visual_column.
9834
992118a1
PP
98352015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
9836
9837 * c-indentation.h (struct token_indent_info): Define.
9838 (get_token_indent_info): Define.
9839 (warn_for_misleading_information): Declare.
9840 * c-common.h (warn_for_misleading_information): Remove.
9841 * c-identation.c (warn_for_misleading_indentation):
9842 Change declaration to take three token_indent_infos. Adjust
9843 accordingly.
9844 * c-identation.c (should_warn_for_misleading_indentation):
9845 Likewise. Bail out early if the body is a compound statement.
9846 (guard_tinfo_to_string): Define.
9847
e8fa3817
JM
98482015-07-30 Jason Merrill <jason@redhat.com>
9849
9850 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
9851 '*' for reference decay.
9852
173864e8
MP
98532015-07-30 Marek Polacek <polacek@redhat.com>
9854
9855 * c-common.c (warn_tautological_cmp): Bail for float types.
9856
f2afe6dd
MP
98572015-07-27 Marek Polacek <polacek@redhat.com>
9858
9859 PR bootstrap/67030
9860 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
9861
05b28fd6
MP
98622015-07-27 Marek Polacek <polacek@redhat.com>
9863
9864 PR c++/66555
9865 PR c/54979
9866 * c-common.c (find_array_ref_with_const_idx_r): New function.
9867 (warn_tautological_cmp): New function.
9868 * c-common.h (warn_tautological_cmp): Declare.
9869 * c.opt (Wtautological-compare): New option.
9870
5a5062b8
MP
98712015-07-23 Marek Polacek <polacek@redhat.com>
9872
9873 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
9874 (ubsan_instrument_shift): Likewise.
9875
dc891fe7
MP
98762015-07-23 Marek Polacek <polacek@redhat.com>
9877
9878 PR sanitizer/66908
9879 * c-ubsan.c: Include gimplify.h.
9880 (ubsan_instrument_division): Unshare OP0 and OP1.
9881 (ubsan_instrument_shift): Likewise.
9882
451b5e48
MP
98832015-07-20 Marek Polacek <polacek@redhat.com>
9884 Richard Sandiford <richard.sandiford@arm.com>
9885
9886 PR c++/55095
9887 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
9888 Use EXPR_LOC_OR_LOC.
9889 (maybe_warn_shift_overflow): New function.
9890 * c-common.h (maybe_warn_shift_overflow): Declare.
9891 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
9892 * c.opt (Wshift-overflow): New option.
9893
fb0b2914
ML
98942015-07-16 Martin Liska <mliska@suse.cz>
9895
9896 * c-format.c (static void check_format_info_main): Use
9897 object_allocator instead of pool_allocator.
9898 (check_format_arg): Likewise.
9899 (check_format_info_main): Likewise.
9900
903f5c23
AM
99012015-07-15 Andrew MacLeod <amacleod@redhat.com>
9902
9903 * c-opts.c: Remove multiline #include comment.
9904
026c3cfd
AH
99052015-07-12 Aldy Hernandez <aldyh@redhat.com>
9906
9907 * c-common.c: Fix double word typos.
9908
bb49ee66
EB
99092015-07-10 Eric Botcazou <ebotcazou@adacore.com>
9910
9911 * c-ada-spec.h (cpp_operation): Revert latest change.
9912 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
9913 constructors and destructors.
9914
1916bcb5
AM
99152015-07-09 Andrew MacLeod <amacleod@redhat.com>
9916
9917 * c-common.h: Adjust includes for flags.h changes.
9918 * stub-objc.c: Likewise.
026c3cfd 9919
a9dcd529
EB
99202015-07-08 Eric Botcazou <ebotcazou@adacore.com>
9921
9922 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
9923 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
9924
b03b462f
JJ
99252015-07-08 Jakub Jelinek <jakub@redhat.com>
9926
9927 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
9928 are to be removed, return NULL rather than original clauses list.
9929
c7131fb2
AM
99302015-07-07 Andrew MacLeod <amacleod@redhat.com>
9931
9932 * array-notation-common.c: Adjust includes.
9933 * c-ada-spec.c: Likewise.
9934 * c-cilkplus.c: Likewise.
9935 * c-common.h: Likewise.
9936 * c-cppbuiltin.c: Likewise.
9937 * c-dump.c: Likewise.
9938 * c-format.c: Likewise.
9939 * c-gimplify.c: Likewise.
9940 * c-indentation.c: Likewise.
9941 * c-lex.c: Likewise.
9942 * c-omp.c: Likewise.
9943 * c-opts.c: Likewise.
9944 * c-pch.c: Likewise.
9945 * c-ppoutput.c: Likewise.
9946 * c-pragma.c: Likewise.
9947 * c-pretty-print.c: Likewise.
9948 * c-semantics.c: Likewise.
9949 * c-ubsan.c: Likewise.
9950 * cilk.c: Likewise.
9951 * stub-objc.c: Likewise.
9952
2a7fb83f
EB
99532015-07-07 Eric Botcazou <ebotcazou@adacore.com>
9954
9955 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
9956 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
9957
a03c9bf1
JM
99582015-07-01 Jason Merrill <jason@redhat.com>
9959
36a85135
JM
9960 * c-common.h (D_CXX11): Rename from D_CXX0X.
9961 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
9962 * c-common.c: Adjust.
9963
e7fa68d5
JM
9964 * c-opts.c (c_common_post_options): Default to C++14.
9965
a03c9bf1
JM
9966 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
9967
fe95b036
ESR
99682015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
9969
9970 Implement N4197 - Adding u8 character literals
b3d5bc62 9971 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
a64be36b 9972 CPP_CHAR.
b3d5bc62 9973 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
a64be36b 9974 CPP_UTF8CHAR_USERDEF tokens.
b3d5bc62 9975 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
a64be36b
EB
9976 and CPP_UTF8CHAR tokens.
9977 (lex_charconst): Treat CPP_UTF8CHAR token.
fe95b036 9978
da2e71c9
MLI
99792015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
9980
9981 PR fortran/66605
9982 * c-common.c (do_warn_unused_parameter): Move here.
9983 * c-common.h (do_warn_unused_parameter): Declare.
9984
b155cfd9
MP
99852015-06-29 Marek Polacek <polacek@redhat.com>
9986
9987 PR c/66322
9988 * c-common.c (check_case_bounds): Add bool * parameter. Set
9989 OUTSIDE_RANGE_P.
9990 (c_add_case_label): Add bool * parameter. Pass it down to
9991 check_case_bounds.
9992 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
9993 warning here.
9994 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
9995 declarations.
9996
31521951
MP
99972015-06-27 Marek Polacek <polacek@redhat.com>
9998
9999 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
10000 or VECTOR_INTEGER_TYPE_P throughout.
10001 * c-gimplify.c: Likewise.
10002
22d03525
MP
100032015-06-26 Marek Polacek <polacek@redhat.com>
10004
10005 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
10006 * c-common.c (c_fully_fold_internal): Likewise.
10007 (c_alignof_expr): Likewise.
10008 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
10009 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
b1726d6c 10010 * cilk.c (create_parm_list): Likewise.
22d03525 10011
af05e6e5
MP
100122015-06-26 Marek Polacek <polacek@redhat.com>
10013
10014 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
10015
f0889939
AM
100162015-06-25 Andrew MacLeod <amacleod@redhat.com>
10017
10018 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
10019 * c-gimplify.c: Likewise.
10020 * c-pragma.c: Likewise.
10021 * c-ubsan.c: Likewise.
10022 * cilk.c: Likewise.
10023
ca752f39
RS
100242015-06-25 Richard Sandiford <richard.sandiford@arm.com>
10025
10026 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
10027 ggc_hasher.
10028
16a16ec7
AM
100292015-06-25 Andrew MacLeod <amacleod@redhat.com>
10030
10031 * cilk.c: Move calls.h after tm.h in the include chain.
10032
0ae9bd27
MP
100332015-06-25 Marek Polacek <polacek@redhat.com>
10034
10035 * array-notation-common.c: Use VAR_P throughout.
10036 * c-ada-spec.c: Likewise.
10037 * c-common.c: Likewise.
10038 * c-format.c: Likewise.
10039 * c-gimplify.c: Likewise.
10040 * c-omp.c: Likewise.
10041 * c-pragma.c: Likewise.
10042 * c-pretty-print.c: Likewise.
10043 * cilk.c: Likewise.
10044
62f9079a
MP
100452015-06-25 Marek Polacek <polacek@redhat.com>
10046
10047 * cilk.c (extract_free_variables): Use is_global_var.
10048
0fa16060
RS
100492015-06-23 Richard Sandiford <richard.sandiford@arm.com>
10050
10051 * c-common.c: Don't include target-def.h.
10052
a68ae2e1
MP
100532015-06-23 Marek Polacek <polacek@redhat.com>
10054
10055 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
10056 when comparing INTEGER_CSTs.
10057
c6a2f2d9
PMR
100582015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
10059
10060 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
10061 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
10062 (dump_ada_template): Skip partially specialized types.
10063
6b4db501
MM
100642015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
10065
10066 * c-common.c (scalar_to_vector): Use std::swap instead of manually
10067 swapping.
10068
abb226c9
AM
100692015-06-17 Andrew MacLeod <amacleod@redhat.com>
10070
10071 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
10072 * c-ada-spec.c: Likewise.
10073 * c-cilkplus.c: Likewise.
10074 * c-common.c: Likewise.
10075 * c-common.h: Likewise.
10076 * c-cppbuiltin.c: Likewise.
10077 * c-dump.c: Likewise.
10078 * c-format.c: Likewise.
10079 * c-gimplify.c: Likewise.
10080 * c-indentation.c: Likewise.
10081 * c-lex.c: Likewise.
10082 * c-omp.c: Likewise.
10083 * c-opts.c: Likewise.
10084 * c-pch.c: Likewise.
10085 * c-ppoutput.c: Likewise.
10086 * c-pragma.c: Likewise.
10087 * c-pretty-print.c: Likewise.
10088 * c-semantics.c: Likewise.
10089 * c-ubsan.c: Likewise.
10090 * cilk.c: Likewise.
10091 * stub-objc.c: Likewise.
10092
076fecad
PP
100932015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
10094
10095 PR c++/65168
10096 * c-common.c (c_common_truthvalue_conversion): Warn when
10097 converting an address of a reference to a truth value.
10098
13fdf2e2
AM
100992015-06-08 Andrew MacLeod <amacleod@redhat.com>
10100
10101 * array-notation-common.c : Adjust include files.
10102 * c-ada-spec.c : Likewise.
10103 * c-cilkplus.c : Likewise.
10104 * c-common.c : Likewise.
10105 * c-common.h : Likewise.
10106 * c-cppbuiltin.c : Likewise.
10107 * c-dump.c : Likewise.
10108 * c-format.c : Likewise.
10109 * c-gimplify.c : Likewise.
10110 * c-indentation.c : Likewise.
10111 * c-lex.c : Likewise.
10112 * c-omp.c : Likewise.
10113 * c-opts.c : Likewise.
10114 * c-pch.c : Likewise.
10115 * c-ppoutput.c : Likewise.
10116 * c-pragma.c : Likewise.
10117 * c-pretty-print.c : Likewise.
10118 * c-semantics.c : Likewise.
10119 * c-ubsan.c : Likewise.
10120 * cilk.c : Likewise.
10121 * stub-objc.c : Likewise.
10122
a1661b90
MP
101232015-06-08 Marek Polacek <polacek@redhat.com>
10124
10125 PR c/66415
10126 * c-format.c (location_from_offset): Return LOC if LINE is null.
10127
d7438551
AH
101282015-06-05 Aldy Hernandez <aldyh@redhat.com>
10129
10130 * c-common.h (c_parse_final_cleanups): New prototype.
10131 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
10132
b3d5bc62
JJ
101332015-06-04 Sriraman Tallam <tmsriram@google.com>
10134
10135 * c-common.c (noplt): New attribute.
10136 (handle_noplt_attribute): New handler.
10137
ecb9f223
AM
101382015-06-04 Andrew MacLeod <amacleod@redhat.com>
10139
10140 * array-notation-common.c: Adjust includes for restructured coretypes.h.
10141 * c-ada-spec.c: Likewise.
10142 * c-cilkplus.c: Likewise.
10143 * c-common.c: Likewise.
10144 * c-common.h: Likewise.
10145 * c-cppbuiltin.c: Likewise.
10146 * c-dump.c: Likewise.
10147 * c-format.c: Likewise.
10148 * c-gimplify.c: Likewise.
10149 * c-indentation.c: Likewise.
10150 * c-lex.c: Likewise.
10151 * c-omp.c: Likewise.
10152 * c-opts.c: Likewise.
10153 * c-pch.c: Likewise.
10154 * c-ppoutput.c: Likewise.
10155 * c-pragma.c: Likewise.
10156 * c-pretty-print.c: Likewise.
10157 * c-semantics.c: Likewise.
10158 * c-ubsan.c: Likewise.
10159 * cilk.c: Likewise.
10160 * stub-objc.c: Likewise.
10161
6ac48155
DM
101622015-06-02 David Malcolm <dmalcolm@redhat.com>
10163
10164 PR c/66220:
10165 * c-indentation.c (should_warn_for_misleading_indentation): Use
10166 expand_location rather than expand_location_to_spelling_point.
10167 Don't warn if the guarding statement is more indented than the
10168 next/body stmts.
10169
773ce42e
DM
101702015-06-02 David Malcolm <dmalcolm@redhat.com>
10171
10172 * c-indentation.c (warn_for_misleading_indentation): Bail out
10173 immediately if -Wmisleading-indentation isn't enabled.
10174
4fef8379
ML
101752015-06-01 Martin Liska <mliska@suse.cz>
10176
10177 * c-format.c (check_format_arg):Use new type-based pool allocator.
10178 (check_format_info_main) Likewise.
10179
1edfb384
EB
101802015-05-31 Eric Botcazou <ebotcazou@adacore.com>
10181
10182 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
10183 (has_nontrivial_methods): Likewise.
10184
9677ef52
MP
101852015-05-25 Marek Polacek <polacek@redhat.com>
10186
10187 * c-ubsan.c (ubsan_instrument_shift): Use type0.
10188
fd5c817a
MP
101892015-05-22 Marek Polacek <polacek@redhat.com>
10190
10191 PR c/47043
10192 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
10193
a2f45fe6 101942015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
581edfa3
TS
10195
10196 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
10197 STACK_GROWS_DOWNWARD.
10198
a2f45fe6 101992015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
62f9f30b
TS
10200
10201 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
10202 STACK_GROWS_DOWNWARD rather than if it is defined.
10203
0fee2ac2 102042015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
b1726d6c 10205
0fee2ac2
MLI
10206 PR c/52952
10207 * c-format.c (location_column_from_byte_offset): New.
10208 (location_from_offset): New.
10209 (struct format_wanted_type): Add offset_loc field.
10210 (check_format_info): Move handling of location for extra arguments
10211 closer to the point of warning.
10212 (check_format_info_main): Pass the result of location_from_offset
10213 to warning_at.
10214 (format_type_warning): Pass the result of location_from_offset
10215 to warning_at.
10216
cf4ef6f7
MP
102172015-05-20 Marek Polacek <polacek@redhat.com>
10218
10219 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
10220
3a65ee74
MP
102212015-05-20 Marek Polacek <polacek@redhat.com>
10222
10223 * c-ada-spec.c (dump_sloc): Use DECL_P.
10224
21b634ae
MP
102252015-05-20 Marek Polacek <polacek@redhat.com>
10226
10227 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
10228 * c-common.c: Likewise.
10229
0e50b624
DM
102302015-05-19 David Malcolm <dmalcolm@redhat.com>
10231
10232 * c-common.h (fe_file_change): Strengthen param from
10233 const line_map * to const line_map_ordinary *.
10234 (pp_file_change): Likewise.
10235 * c-lex.c (fe_file_change): Likewise.
10236 (cb_define): Use linemap_check_ordinary when invoking
10237 SOURCE_LINE.
10238 (cb_undef): Likewise.
10239 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
10240 invoking cb_file_change.
10241 (c_finish_options): Likewise.
10242 (push_command_line_include): Likewise.
10243 (cb_file_change): Strengthen param "new_map" from
10244 const line_map * to const line_map_ordinary *.
10245 * c-ppoutput.c (cb_define): Likewise for local "map".
10246 (pp_file_change): Likewise for param "map" and local "from".
10247
fab27f52
MM
102482015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
10249
10250 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
10251
2fe1d762
TV
102522015-05-18 Tom de Vries <tom@codesourcery.com>
10253
10254 * c-common.c (build_va_arg_1): New function.
10255 (build_va_arg): Add address operator to va_list operand if necessary.
10256
7a37fa90
MM
102572015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
10258
10259 PR c/48956
10260 * c-common.c (int_safely_convertible_to_real_p): Define.
10261 (unsafe_conversion_p): Check conversions involving complex types.
10262 (conversion_warning): Add new warning message for conversions which
10263 discard imaginary component.
10264 * c-common.h: (enum conversion_safety): Add new enumerator for such
10265 conversions.
10266
3aa3c9fc
MP
102672015-05-14 Marek Polacek <polacek@redhat.com>
10268
10269 PR c/66066
10270 PR c/66127
10271 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
10272 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
10273 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
10274 use it. If FOR_INT_CONST, require that all evaluated operands be
10275 INTEGER_CSTs.
10276
c3388e62
DM
102772015-05-12 David Malcolm <dmalcolm@redhat.com>
10278
10279 * c-common.h (warn_for_misleading_indentation): New prototype.
10280 * c-indentation.c: New file.
10281 * c.opt (Wmisleading-indentation): New option.
10282
c7b38fd5
TV
102832015-05-12 Tom de Vries <tom@codesourcery.com>
10284
10285 PR tree-optimization/66010
10286 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
10287
381bf11e
JM
102882015-05-09 Jason Merrill <jason@redhat.com>
10289
edff0c06
JM
10290 * c-opts.c (c_common_post_options): Also clear
10291 cpp_opts->cpp_warn_cxx11_compat.
10292
129211bc
JM
10293 * c-common.h (enum cxx_dialect): Add cxx_unset.
10294 * c-common.c (cxx_dialect): Initialize to cxx_unset.
10295 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
10296
381bf11e
JM
10297 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
10298 (std=gnu++0x): Mark as Undocumented.
10299 (std=gnu++1y): Add deprecated message.
10300
fe191308
JM
103012015-05-08 Jason Merrill <jason@redhat.com>
10302
765189ff
JM
10303 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
10304 * c-opts.c: Adjust.
10305
fe191308
JM
10306 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
10307
755e528f
MP
103082015-05-08 Marek Polacek <polacek@redhat.com>
10309
10310 PR c/64918
10311 * c.opt (Woverride-init-side-effects): New option.
10312
0173bd2a
MP
103132015-05-07 Marek Polacek <polacek@redhat.com>
10314
10315 PR c/65179
10316 * c-common.c (c_fully_fold_internal): Warn when left shifting a
10317 negative value.
10318 * c.opt (Wshift-negative-value): New option.
10319 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
10320 when -Wextra and C99/C++11 mode.
10321
e0f0d3b9
MP
103222015-05-07 Marek Polacek <polacek@redhat.com>
10323 Martin Uecker <uecker@eecs.berkeley.edu>
10324
10325 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
10326 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
10327
8243e2a9
JM
103282015-05-05 Jason Merrill <jason@redhat.com>
10329
10330 * c.opt (Wterminate): New.
10331
577cd070
MP
103322015-04-30 Marek Polacek <polacek@redhat.com>
10333
10334 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
10335 require that the non-constant be of a boolean type.
10336
0373796b
JT
103372015-04-29 Josh Triplett <josh@joshtriplett.org>
10338
e0f0d3b9
MP
10339 * c-common.c (handle_section_attribute): Refactor to reduce
10340 nesting and distinguish between error cases.
0373796b 10341
716c0ba6
MP
103422015-04-29 Marek Polacek <polacek@redhat.com>
10343
10344 PR c/64610
10345 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
10346 with 0/1.
10347
8848828b
JJ
103482015-04-29 Jakub Jelinek <jakub@redhat.com>
10349
10350 * c-common.h (omp_clause_mask): Unconditionally define as a class.
10351 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
10352 HOST_BITS_PER_WIDE_INT.
10353
ecd0e562
TV
103542015-04-28 Tom de Vries <tom@codesourcery.com>
10355
10356 PR tree-optimization/65887
10357 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
10358
2a877204 103592015-04-28 Eric Botcazou <ebotcazou@adacore.com>
e0f0d3b9 10360 Pierre-Marie de Rodat <derodat@adacore.com>
2a877204
EB
10361
10362 * c-ada-spec.c (in_function): Delete.
10363 (dump_generic_ada_node): Do not change in_function and remove the
10364 redundant code dealing with it.
10365 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
10366 (print_ada_methods): Output the static member functions in a nested
10367 package after the regular methods as well as associated renamings.
10368
4853031e
MP
103692015-04-24 Marek Polacek <polacek@redhat.com>
10370
10371 PR c/65830
10372 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
10373 and OPT_Wshift_count_overflow.
10374
8c2b7f79
MP
10375 PR c/63357
10376 * c-common.c (warn_logical_operator): Warn if the operands have the
10377 same expressions.
10378
b8787813
MP
103792015-04-24 Marek Polacek <polacek@redhat.com>
10380
10381 PR c/61534
10382 * c-common.c (warn_logical_operator): Bail if either operand comes
10383 from a macro expansion.
10384
8fba1830
BRF
103852015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
10386
10387 PR target/55143
10388 * c-common.c (c_default_pointer_mode): Add definition.
10389 * c-common.h (c_default_pointer_mode): Add declaration.
10390
17958621
JJ
103912015-03-11 Jakub Jelinek <jakub@redhat.com>
10392
10393 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
10394 on record_builtin_type argument.
10395
7ccb1a11
JJ
103962015-03-10 Jakub Jelinek <jakub@redhat.com>
10397
10398 PR c/65120
10399 * c-common.c (warn_logical_not_parentheses): Don't warn for
10400 !x == 0 or !x != 0.
10401
04fd785e
MP
104022015-03-07 Marek Polacek <polacek@redhat.com>
10403
10404 PR sanitizer/65280
10405 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
10406 before trying to figure out whether we have a flexible array member.
10407
a4e26206 104082015-03-06 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 10409 Jonathan Wakely <jwakely.gcc@gmail.com>
a4e26206
EB
10410
10411 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
10412
0d2489f4
EB
104132015-03-05 Eric Botcazou <ebotcazou@adacore.com>
10414
10415 PR ada/65319
10416 * c-ada-spec.c (print_destructor): Remove obsolete code.
10417
83ed54d7
EB
104182015-03-01 Eric Botcazou <ebotcazou@adacore.com>
10419
10420 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
10421 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
10422 DECL_TEMPLATE_RESULT emulations.
10423 (dump_ada_template)): Add guard for TYPE_METHODS.
10424
7631f0e2
MP
104252015-02-27 Marek Polacek <polacek@redhat.com>
10426
10427 PR c/65040
10428 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
10429
d1783ae5
KT
104302015-02-27 Kai Tietz <ktietz@redhat.com>
10431
10432 PR c/35330
10433 * c-pragma.c (handle_pragma_weak): Do not try to create
10434 weak/alias of declarations not being function, or variable
10435 declarations.
10436
56a9f6bc
TS
104372015-02-24 Thomas Schwinge <thomas@codesourcery.com>
10438
10439 PR libgomp/64625
10440 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
10441 Remove macros.
10442 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
10443
3d5cb23d
MP
104442015-02-16 Marek Polacek <polacek@redhat.com>
10445
10446 PR c/65066
10447 * c-format.c (check_format_types): Handle null param.
10448
fa008882
MP
104492015-02-13 Marek Polacek <polacek@redhat.com>
10450
10451 PR c/65040
10452 * c-format.c (check_format_types): Don't warn about different
10453 signedness if the original value is in the range of WANTED_TYPE.
10454
785f21af
JM
104552015-02-12 Jason Merrill <jason@redhat.com>
10456
10457 PR c++/64956
10458 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
10459 to the current highest version.
10460 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
10461
4886ec8e
JJ
104622015-02-04 Jakub Jelinek <jakub@redhat.com>
10463
10464 PR c/64824
10465 PR c/64868
10466 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
10467 instead of RDIV_EXPR. Use build_binary_op instead of
10468 build2_loc.
10469
40fecdd6
JM
104702015-01-30 Joseph Myers <joseph@codesourcery.com>
10471
10472 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
10473 to pass input_location as first argument.
10474
a0c88d06
TV
104752015-01-23 Tom de Vries <tom@codesourcery.com>
10476
10477 PR libgomp/64672
10478 * c.opt (fopenacc): Mark as LTO option.
10479
1506ae0e
TV
104802015-01-23 Tom de Vries <tom@codesourcery.com>
10481
10482 PR libgomp/64707
10483 * c.opt (fopenmp): Mark as LTO option.
10484
31be63ab
JJ
104852015-01-21 Jakub Jelinek <jakub@redhat.com>
10486
10487 PR c/63307
b1726d6c 10488 * cilk.c (fill_decls_vec): Only put decls into vector v.
31be63ab
JJ
10489 (compare_decls): Fix up formatting.
10490
104912015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
10492
10493 PR c/63307
10494 * cilk.c: Include vec.h.
10495 (struct cilk_decls): New structure.
10496 (wrapper_parm_cb): Split this function to...
10497 (fill_decls_vec): ...this...
10498 (create_parm_list): ...and this.
10499 (compare_decls): New function.
10500 (for_local_cb): Remove.
10501 (wrapper_local_cb): Ditto.
10502 (build_wrapper_type): For now first traverse and fill vector of
10503 declarations then sort it and then deal with sorted vector.
10504 (cilk_outline): Ditto.
10505 (declare_one_free_variable): Ditto.
10506
6875457f
JM
105072015-01-21 Jason Merrill <jason@redhat.com>
10508
10509 PR c++/64629
10510 * c-format.c (check_format_arg): Call decl_constant_value.
10511
185c9e56
ML
105122015-01-19 Martin Liska <mliska@suse.cz>
10513
10514 * c-common.c (handle_noicf_attribute): New function.
10515
41dbbb37
TS
105162015-01-15 Thomas Schwinge <thomas@codesourcery.com>
10517 Bernd Schmidt <bernds@codesourcery.com>
10518 James Norris <jnorris@codesourcery.com>
10519 Cesar Philippidis <cesar@codesourcery.com>
10520 Ilmir Usmanov <i.usmanov@samsung.com>
10521 Jakub Jelinek <jakub@redhat.com>
10522
10523 * c.opt (fopenacc): New option.
10524 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
10525 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
10526 New macros.
10527 * c-common.h (c_finish_oacc_wait): New prototype.
10528 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
10529 (c_finish_oacc_wait): New function.
10530 * c-pragma.c (oacc_pragmas): New variable.
10531 (c_pp_lookup_pragma, init_pragma): Handle it.
10532 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
10533 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
10534 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
10535 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
10536 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
10537 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
10538 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
10539 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
10540 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
10541 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
10542 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
10543 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
10544 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
10545 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
10546 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
10547 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
10548 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
10549 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
10550 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
10551 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
10552 PRAGMA_OACC_CLAUSE_WORKER.
10553
3f8257db 105542015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
5434dc07
MD
10555
10556 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
10557 for the new option fstack-protector_explicit.
10558 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
10559 (handle_stack_protect_attribute): New function.
10560
3f8257db 105612015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
de1b5c17
MU
10562
10563 * c.opt: New option -Warray-bounds=.
10564
adfac8df
JJ
105652015-01-09 Michael Collison <michael.collison@linaro.org>
10566
10567 * array-notation-common.c: Include hash-set.h, machmode.h,
10568 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
10569 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
10570 * c-ada-spec.c: Ditto.
10571 * c-cilkplus.c: Ditto.
10572 * c-common.c: Include input.h due to flattening of tree.h.
10573 Define macro GCC_C_COMMON_C.
10574 * c-common.h: Flatten tree.h header files into c-common.h.
10575 Remove include of tree-core.h.
10576 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
10577 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
10578 fold-const.h, wide-int.h, and inchash.h due to
10579 flattening of tree.h.
10580 * c-dump.c: Ditto.
10581 * c-format.c: Flatten tree.h header files into c-common.h.
10582 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
10583 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
10584 fold-const.h, wide-int.h, and inchash.h due to
10585 flattening of tree.h.
10586 * c-dump.c: Include hash-set.h, machmode.h,
10587 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
10588 fold-const.h, wide-int.h, and inchash.h due to
10589 flattening of tree.h.
10590 * c-format.c: Include hash-set.h, machmode.h,
10591 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
10592 fold-const.h, wide-int.h, inchash.h and real.h due to
10593 flattening of tree.h.
10594 * c-gimplify.c: Include hash-set.h, machmode.h,
10595 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
10596 fold-const.h, wide-int.h, and inchash.h due to
10597 flattening of tree.h.
10598 * cilk.c: Ditto.
10599 * c-lex.c: Ditto.
10600 * c-omp.c: Ditto.
10601 * c-opts.c: Ditto.
10602 * c-pch.c: Ditto.
10603 * c-ppoutput.c: Ditto.
10604 * c-pragma.c: Ditto.
10605 * c-pretty-print.c: Ditto.
10606 * c-semantics.c: Ditto.
10607 * c-ubsan.c: Ditto.
10608 * stub-objc.c: Ditto.
10609
f5481fc4
JM
106102015-01-08 Jason Merrill <jason@redhat.com>
10611
10612 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
10613 do_ubsan_in_current_function.
10614 (ubsan_maybe_instrument_reference_or_call): Likewise.
10615 * c-ubsan.h: Declare it.
10616
de35aa66
MS
106172015-01-08 Mike Stump <mikestump@comcast.net>
10618
10619 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
10620
4a9a42ab
MP
106212015-01-07 Marek Polacek <polacek@redhat.com>
10622
10623 PR c/64440
10624 * c-common.c (c_fully_fold_internal): Warn for division and modulo
10625 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
10626
2f42e5de
TS
106272015-01-05 Trevor Saunders <tsaunders@mozilla.com>
10628
10629 PR c++/31397
10630 * c.opt (Wsuggest-override): New option.
10631
5624e564
JJ
106322015-01-05 Jakub Jelinek <jakub@redhat.com>
10633
10634 Update copyright years.
10635
5bd012f8
MP
106362015-01-05 Marek Polacek <polacek@redhat.com>
10637
10638 PR c/64423
10639 * c-common.c (warn_array_subscript_with_type_char): Add location_t
10640 parameter. Use it.
10641 * c-common.h (warn_array_subscript_with_type_char): Update
10642 declaration.
10643
a7fa8d18
ESR
106442014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
10645
10646 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
10647 Control macro with flag_sized_deallocation.
10648
3f8257db 106492014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
768952be
MU
10650
10651 * c.opt (Wdiscarded-array-qualifiers): New option.
10652
1f8d3e84
JJ
106532014-12-19 Jakub Jelinek <jakub@redhat.com>
10654
10655 PR preprocessor/63831
10656 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
10657 and __has_cpp_attribute here.
10658 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
10659 c_common_has_attribute.
10660 * c-common.h (c_common_has_attribute): New prototype.
10661 * c-lex.c (init_c_lex): Set cb->has_attribute to
10662 c_common_has_attribute instead of cb_has_attribute.
10663 (get_token_no_padding): New function.
10664 (cb_has_attribute): Renamed to ...
10665 (c_common_has_attribute): ... this. No longer static. Use
10666 get_token_no_padding, require ()s, don't build TREE_LIST
10667 unnecessarily, fix up formatting, adjust diagnostics, call
10668 init_attributes.
10669
20b06add
JM
106702014-12-15 Jason Merrill <jason@redhat.com>
10671
10672 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
10673 (-Wsized-deallocation): New.
10674 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
10675 to on in C++14 and up.
10676
94a073b2
JM
106772014-12-11 Jason Merrill <jason@redhat.com>
10678
acaa5911
JM
10679 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
10680
94a073b2
JM
10681 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
10682 we aren't complaining about VLAs.
10683
7fb66c15
MP
106842014-12-06 Marek Polacek <polacek@redhat.com>
10685
10686 PR tree-optimization/64183
10687 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
10688 shift-expression if it is integer_type_node. Use types_compatible_p.
10689
b731b390
JJ
106902014-11-29 Jakub Jelinek <jakub@redhat.com>
10691
10692 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
10693 last argument from create_tmp_var_raw and create_tmp_var calls.
10694 * cilk.c (gimplify_cilk_spawn): Likewise.
10695 * c-omp.c (c_finish_omp_atomic): Likewise.
10696
6a4da643
MP
106972014-11-28 Marek Polacek <polacek@redhat.com>
10698
10699 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
10700 instead of unsigned_type_node.
10701
541e35a6
MP
107022014-11-28 Marek Polacek <polacek@redhat.com>
10703
10704 PR c/63862
10705 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
10706 to op1_utype.
10707 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
10708 expression to unsigned_type_node.
10709
dcc97066
MW
107102014-11-20 Mark Wielaard <mjw@redhat.com>
10711
10712 PR debug/38757
10713 * c-opts.c (set_std_c89): Set lang_hooks.name.
10714 (set_std_c99): Likewise.
10715 (set_std_c11): Likewise.
10716 (set_std_cxx98): Likewise.
10717 (set_std_cxx11): Likewise.
10718 (set_std_cxx14): Likewise.
10719 (set_std_cxx1z): Likewise.
10720
aa7da51a
JJ
107212014-11-21 Jakub Jelinek <jakub@redhat.com>
10722
10723 PR target/63764
10724 * c-common.h (convert_vector_to_pointer_for_subscript): Change
10725 return type to bool.
009a3480 10726 * c-common.c: Include gimple-expr.h.
aa7da51a
JJ
10727 (convert_vector_to_pointer_for_subscript): Change return type to
10728 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
10729 and copy it into a TARGET_EXPR and use that instead of *vecp
10730 directly.
10731
538dd0b7
DM
107322014-11-19 David Malcolm <dmalcolm@redhat.com>
10733
10734 Merger of git branch "gimple-classes-v2-option-3".
10735 * ChangeLog.gimple-classes: New.
10736 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
10737 from being just a vec<gimple> to a vec<gbind *>.
10738
c39a5e99
JJ
107392014-11-18 Jakub Jelinek <jakub@redhat.com>
10740
10741 PR sanitizer/63813
10742 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
10743 argument to ptype, set type to TREE_TYPE (ptype). Don't call
10744 get_pointer_alignment for non-pointers. Use ptype, or if it is
10745 reference type, corresponding pointer type, as type of kind
10746 argument.
10747 (ubsan_maybe_instrument_reference,
10748 ubsan_maybe_instrument_member_call): Adjust callers.
10749
8537a4a9
MP
107502014-11-15 Marek Polacek <polacek@redhat.com>
10751
10752 PR middle-end/63884
10753 * array-notation-common.c (is_sec_implicit_index_fn): Return false
10754 for NULL fndecl.
10755 (extract_array_notation_exprs): Return for NULL node.
10756
2079956a
JM
107572014-11-12 Joseph Myers <joseph@codesourcery.com>
10758
10759 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
10760 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
10761
1304953e
JJ
107622014-11-12 Jakub Jelinek <jakub@redhat.com>
10763
10764 PR c/59708
10765 * c-common.c (check_builtin_function_arguments): Handle
10766 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
10767
e5e44252
AK
107682014-11-10 Andi Kleen <ak@linux.intel.com>
10769
10770 PR c/60804
10771 * c-common.h (check_no_cilk): Declare.
10772 * cilk.c (get_error_location): New function.
10773 (check_no_cilk): Dito.
10774
e64b984d
AK
107752014-11-10 Andi Kleen <ak@linux.intel.com>
10776
10777 * cilk.c (recognize_spawn): Use expression location
10778 for error message.
10779
13c21655
PC
107802014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
10781
10782 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
10783
42fd12b1
ESR
107842014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
10785
10786 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
10787 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
10788 (__cpp_range_based_for, __cpp_initializer_lists,
10789 __cpp_delegating_constructors, __cpp_nsdmi,
10790 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
10791 for C++11; (__cpp_attribute_deprecated): Remove in favor of
10792 __has_cpp_attribute.
10793 * c-lex.c (cb_has_attribute): New callback CPP function;
10794 (init_c_lex): Set has_attribute callback.
10795
6f450181
RB
107962014-11-04 Richard Biener <rguenther@suse.de>
10797
10798 * c-common.c (shorten_compare): Do not shorten mixed
10799 DFP and non-DFP compares.
10800
26f0e1d6
ESR
108012014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
10802
10803 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
10804 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
10805 Commentary and rearrangement of tests.
10806 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
10807 Commentary and rearrangement of tests.
ab20d992 10808 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
26f0e1d6
ESR
10809 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
10810
ef4bddc2
RS
108112014-10-29 Richard Sandiford <richard.sandiford@arm.com>
10812
10813 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
10814 enum from machine_mode.
10815
c582198b
AM
108162014-10-28 Andrew MacLeod <amacleod@redhat.com>
10817
adfac8df
JJ
10818 * c-common.c: Adjust include files.
10819 * c-gimplify.c: Ditto.
10820 * cilk.c: Ditto.
10821 * c-pragma.c: Ditto.
10822 * c-ubsan.c: Ditto.
c582198b 10823
60393bbc
AM
108242014-10-27 Andrew MacLeod <amacleod@redhat.com>
10825
10826 * c-gimplify.c: Adjust include files.
10827
d723bb7c
MLI
108282014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
10829
10830 PR c++/53061
10831 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
10832 c_common_initialize_diagnostics.
10833 * c-common.h: Likewise.
10834
90f3520e
MP
108352014-10-24 Marek Polacek <polacek@redhat.com>
10836
10837 PR c/56980
10838 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
10839 print "struct"/"union"/"enum" for typedefed names.
10840
59d7607a
MP
108412014-10-23 Marek Polacek <polacek@redhat.com>
10842
10843 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
10844 in unsigned type.
10845
d95a2703
JJ
108462014-10-22 Jakub Jelinek <jakub@redhat.com>
10847 Yury Gribov <y.gribov@samsung.com>
10848
10849 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
10850 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
10851 instead of flag_sanitize_recover as bool flag.
10852
8e6ef852
KY
108532014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
10854
10855 * cilk.c: Revert previous change.
10856
948cf550
IZ
108572014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
10858
10859 PR c/63307
10860 * cilk.c: Include vec.h.
10861 (struct cilk_decls): New structure.
10862 (wrapper_parm_cb): Split this function to...
10863 (fill_decls_vec): ...this...
10864 (create_parm_list): ...and this.
10865 (compare_decls): New function.
10866 (for_local_cb): Remove.
10867 (wrapper_local_cb): Ditto.
10868 (build_wrapper_type): For now first traverse and fill vector of
10869 declarations then sort it and then deal with sorted vector.
10870 (cilk_outline): Ditto.
10871 (declare_one_free_variable): Ditto.
10872
92574c7c
MP
108732014-10-17 Marek Polacek <polacek@redhat.com>
10874
10875 * c-opts.c (c_common_post_options): Set warn_implicit_int.
10876 * c.opt (Wimplicit-int): Initialize to -1.
10877
83685514
AM
108782014-10-16 Andrew MacLeod <amacleod@redhat.com>
10879
10880 * c-pragma.c: Adjust include files.
10881 * c-semantics.c: Likewise.
10882
5b8300ea
DD
108832014-10-16 DJ Delorie <dj@redhat.com>
10884
10885 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
10886 multiples of bytes.
10887
5f83e90b
JM
108882014-10-14 Jason Merrill <jason@redhat.com>
10889
10890 PR c++/63455
10891 * c-common.h (CPP_PREPARSED_EXPR): New.
10892 (N_CP_TTYPES): Adjust.
10893
d73326ca
MP
108942014-10-15 Marek Polacek <polacek@redhat.com>
10895
10896 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
10897
78a7c317
DD
108982014-10-14 DJ Delorie <dj@redhat.com>
10899
10900 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
10901 types, not just __int128.
10902 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
10903 types, not just __int128.
10904 (cpp_atomic_builtins): Round pointer sizes up.
10905 (type_suffix): Use type precision, not specific types.
10906 * c-common.c (c_common_reswords): Remove __int128 special case.
10907 (c_common_type_for_size): Check for all __intN types, not just
10908 __int128.
10909 (c_common_type_for_mode): Likewise.
10910 (c_common_signed_or_unsigned_type): Likewise.
10911 (c_build_bitfield_integer_type): Likewise.
10912 (c_common_nodes_and_builtins): Likewise.
10913 (keyword_begins_type_specifier): Likewise.
10914 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
10915 __intN variants.
10916
2a22f99c
TS
109172014-10-12 Trevor Saunders <tsaunders@mozilla.com>
10918
10919 * c-common.c: Use hash_table instead of hashtab.
10920
2a8ef767
ESR
109212014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
10922
adfac8df 10923 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
2a8ef767
ESR
10924 C++11 section.
10925
3c9aabbd
MG
109262014-10-03 Marc Glisse <marc.glisse@inria.fr>
10927
10928 PR c++/54427
10929 PR c++/57198
10930 PR c++/58845
10931 * c-common.c (warn_logical_operator): Punt for vectors.
10932
a15f7cb8
ESR
109332014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
10934
10935 Implement SD-6: SG10 Feature Test Recommendations
10936 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
10937 macros and the __has_header macro.
10938
8d0cf15e
JM
109392014-09-30 Jason Merrill <jason@redhat.com>
10940
dd5d5481
JM
10941 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
10942 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
10943 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
10944
b752325e
JM
10945 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
10946 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
10947
8d0cf15e
JM
10948 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
10949 * c-common.c (c_common_reswords): Remove __is_convertible_to.
10950
083e891e
MP
109512014-09-24 Marek Polacek <polacek@redhat.com>
10952
10953 PR c/61405
10954 PR c/53874
10955 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
10956
7861b648
AK
109572014-09-23 Andi Kleen <ak@linux.intel.com>
10958
10959 * c-common.c (handle_no_reorder_attribute): New function.
10960 (c_common_attribute_table): Add no_reorder attribute.
10961
9a79452d
JM
109622014-09-22 Joseph Myers <joseph@codesourcery.com>
10963
10964 * c-cppbuiltin.c (c_cpp_builtins): Define
10965 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
10966 modes.
10967
dd69f047
JM
109682014-09-18 Joseph Myers <joseph@codesourcery.com>
10969
10970 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
10971 for supported floating-point modes.
10972
737a4826
MLI
109732014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
10974
10975 * c.opt (Wpsabi): Use LangEnabledBy.
10976 * c-opts.c (c_common_handle_option): Do not handle here.
10977
8cc4b7a2
JM
109782014-09-12 Joseph Myers <joseph@codesourcery.com>
10979
10980 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
10981 macros for floating-point modes.
10982
179b5a55
MG
109832014-09-11 Marc Glisse <marc.glisse@inria.fr>
10984
10985 PR target/58757
10986 * c-cppbuiltin.c (builtin_define_float_constants): Correct
10987 __*_DENORM_MIN__ without denormals.
10988
570a11fe
JJ
109892014-09-10 Jakub Jelinek <jakub@redhat.com>
10990
10991 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
10992 ubsan_instrument_vla, ubsan_instrument_return): Adjust
10993 ubsan_create_data callers.
10994 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
10995 index is constant or BIT_AND_EXPR with constant mask and is
10996 small enough for the bound.
10997 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
10998 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
10999
b559c810
MLI
110002014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
11001
11002 * c.opt: Add CppReason to various flags.
11003 (Wdate-time): Re-sort.
11004 * c-common.c: Include c-common.h earlier.
11005 (struct reason_option_codes_t): Delete.
11006 (c_option_controlling_cpp_error): Prefix global type and struct
11007 with cpp_.
11008
1ef33fd4
MLI
110092014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
11010
11011 * c.opt (Wnormalized): New.
11012 (Wnormalized=): Use Enum and Reject Negative.
11013 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
11014
66bb34c0
JM
110152014-09-08 Joseph Myers <joseph@codesourcery.com>
11016
11017 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
11018 digits of floating-point modes if -fbuilding-libgcc.
11019
53d68b9f
JM
110202014-09-05 Joseph Myers <joseph@codesourcery.com>
11021
11022 * c-cppbuiltin.c (c_cpp_builtins): Also define
11023 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
11024 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
11025 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
11026 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
11027 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
11028 __LIBGCC_STACK_GROWS_DOWNWARD__,
11029 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
11030 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
11031 __LIBGCC_DWARF_FRAME_REGISTERS__,
11032 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
11033 __LIBGCC_STACK_POINTER_REGNUM__ and
11034 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
11035 (builtin_define_with_value): Handle backslash-escaping in string
11036 macro values.
11037
f65586dc
RB
110382014-09-05 Richard Biener <rguenther@suse.de>
11039
11040 PR middle-end/63148
11041 * c-format.c (check_format_arg): Properly handle
11042 effectively signed POINTER_PLUS_EXPR offset.
11043
2b71f4a4
MLI
110442014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
11045
11046 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
11047 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
11048 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
11049 and Init.
11050 * c-opts.c (c_common_handle_option): Do not handle here.
11051 (sanitize_cpp_opts): Likewise.
11052 * c-common.c (struct reason_option_codes_t): Handle
11053 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
11054
d2e4feca
MP
110552014-09-03 Marek Polacek <polacek@redhat.com>
11056
11057 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
11058
9a771876
JJ
110592014-09-02 Jakub Jelinek <jakub@redhat.com>
11060 Balaji V. Iyer <balaji.v.iyer@intel.com>
11061 Igor Zamyatin <igor.zamyatin@intel.com>
11062
11063 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
11064 * c-common.c (c_common_reswords): Added _Cilk_for.
11065 * c-common.h (enum rid): Added RID_CILK_FOR.
11066 (cilk_for_number_of_iterations): Add declaration.
11067 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
11068 CILK_FOR.
11069 * c-pragma.c (init_pragma): Register "grainsize" pragma.
11070 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
11071
81b5d104
MLI
110722014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
11073
11074 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
11075 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
11076 Wundef): Use CPP, Var and Init.
11077 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
11078
b753b37b
MLI
110792014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
11080
11081 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
11082 * c-opts.c (c_common_handle_option): Do not handle here.
11083
028aee17
JM
110842014-08-25 Jason Merrill <jason@redhat.com>
11085
11086 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
11087 -std=c++14 and -std=gnu++14, rather than the reverse.
11088 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
11089 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
11090 * c-common.h (cxx_dialect): Remove cxx1y.
11091
e4276ba5
ESR
110922014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
11093
11094 * c-common.h (enum cxx_dialect): Add cxx14.
11095 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
11096 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
11097 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
11098
a545cacd
JM
110992014-08-22 Jason Merrill <jason@redhat.com>
11100
11101 * c.opt (std=gnu++17): Fix alias.
11102
59ea0364
MP
111032014-08-22 Marek Polacek <polacek@redhat.com>
11104
11105 PR c++/62199
11106 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
11107 check for vector types. Drop LHS argument.
11108 * c-common.h (warn_logical_not_parentheses): Adjust.
11109
596e808c
MLI
111102014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
11111
11112 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
11113 (Wmultichar): Likewise.
11114 (Wdate-time): Use C-family languages instead of Common. Use CPP
11115 and Var.
11116 * c-opts.c (c_common_handle_option): Do not handle the above
11117 options here.
11118 (sanitize_cpp_opts): Likewise.
11119
18767f65
MLI
111202014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
11121
11122 PR fortran/44054
11123 * c-opts.c: Include tree-diagnostics.h.
11124 (c_diagnostic_finalizer): New.
11125 (c_common_initialize_diagnostics): Use it.
11126
b4413594
MLI
111272014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
11128
11129 PR preprocessor/51303
11130 * c-common.c (struct reason_option_codes_t option_codes):
11131 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
11132
43f9a13c
MLI
111332014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
11134
11135 PR c/60975
11136 PR c/53063
11137 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
11138 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
11139 (c_common_post_options): Call init_global_opts_from_cpp.
11140 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
11141
04159acf
MP
111422014-08-19 Marek Polacek <polacek@redhat.com>
11143
11144 PR c++/62153
11145 * c-common.c (maybe_warn_bool_compare): New function.
11146 * c-common.h (maybe_warn_bool_compare): Declare.
11147 * c.opt (Wbool-compare): New option.
11148
35aff4fb
MP
111492014-08-19 Marek Polacek <polacek@redhat.com>
11150
11151 * c.opt (Wc99-c11-compat): New option.
11152
177cce46
MP
111532014-08-19 Marek Polacek <polacek@redhat.com>
11154
11155 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
11156 to warn_c90_c99_compat.
11157 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
11158 to -1.
11159
6ae9194f
MLI
111602014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
11161 Steven Bosscher <steven@gcc.gnu.org>
11162
11163 PR c/52952
11164 * c-format.c: Add extra_arg_loc and format_string_loc to struct
11165 format_check_results.
11166 (check_function_format): Use true and add comment for boolean
11167 argument.
11168 (finish_dollar_format_checking): Use explicit location when warning.
11169 (check_format_info): Likewise.
11170 (check_format_arg): Set extra_arg_loc and format_string_loc.
11171 (check_format_info_main): Use explicit location when warning.
11172 (check_format_types): Pass explicit location.
11173 (format_type_warning): Likewise.
11174
8e54f6d3
MLI
111752014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
11176
11177 PR fortran/44054
11178 * c-format.c: Handle Fortran flags.
11179
cd4e76fc
IZ
111802014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
11181
11182 PR other/61962
11183 * array-notation-common.c (find_rank): Added handling for other
11184 types of references.
11185
f3bede71
MP
111862014-08-10 Marek Polacek <polacek@redhat.com>
11187
11188 PR c/51849
11189 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
11190 * c.opt (Wc90-c99-compat): Add option.
11191
9f25a338
TS
111922014-08-07 Trevor Saunders <tsaunders@mozilla.com>
11193
11194 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
11195
62e4eb35
MP
111962014-08-03 Marek Polacek <polacek@redhat.com>
11197
ab20d992 11198 * c-common.c (check_case_value): Add location_t parameter. Use it.
62e4eb35
MP
11199 (c_add_case_label): Pass loc to check_case_value.
11200
b787e7a2
TS
112012014-08-02 Trevor Saunders <tsaunders@mozilla.com>
11202
11203 * cilk.c: Use hash_map instead of pointer_map.
11204
6e2830c3
TS
112052014-08-02 Trevor Saunders <tsaunders@mozilla.com>
11206
11207 * c-gimplify.c: Use hash_set instead of pointer_set.
11208
a7ee52fb
IZ
112092014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
11210
11211 PR middle-end/61455
11212 * array-notation-common.c (extract_array_notation_exprs): Handling
11213 of DECL_EXPR added.
11214
944fa280
JJ
112152014-08-01 Jakub Jelinek <jakub@redhat.com>
11216
11217 * c-common.h (min_align_of_type): Removed prototype.
11218 * c-common.c (min_align_of_type): Removed.
11219 * c-ubsan.h (ubsan_maybe_instrument_reference,
11220 ubsan_maybe_instrument_member_call): New prototypes.
11221 * c-ubsan.c: Include stor-layout.h and builtins.h.
11222 (ubsan_maybe_instrument_reference_or_call,
11223 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
11224 functions.
11225
b4dfdc11
MG
112262014-07-31 Marc Glisse <marc.glisse@inria.fr>
11227
11228 PR c++/60517
11229 * c.opt (-Wreturn-local-addr): Move to common.opt.
11230
a41844e5
JM
112312014-07-30 Jason Merrill <jason@redhat.com>
11232
11233 PR c++/61659
11234 PR c++/61687
11235 Revert:
11236 * c.opt (-fuse-all-virtuals): New.
11237
976d5a22
TT
112382014-07-30 Tom Tromey <tromey@redhat.com>
11239
11240 PR c/59855
11241 * c.opt (Wdesignated-init): New option.
11242 * c-common.c (c_common_attribute_table): Add "designated_init".
11243 (handle_designated_init): New function.
11244
cdc94aca
MP
112452014-07-24 Marek Polacek <polacek@redhat.com>
11246
11247 PR c/57653
11248 * c-opts.c (c_finish_options): If -imacros is in effect, return.
11249
f41373b6
DS
112502014-07-16 Dodji Seketeli <dodji@redhat.com>
11251
11252 PR preprocessor/60723 - missing system-ness marks for macro tokens
11253 * c-ppoutput.c (struct print::prev_was_system_token): New data
11254 member.
11255 (init_pp_output): Initialize it.
11256 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
11257 (do_line_change): Return a flag saying if a line marker was
11258 emitted or not.
11259 (scan_translation_unit): Detect if the system-ness of the token we
11260 are about to emit is different from the one of the previously
11261 emitted token. If so, emit a line marker. Avoid emitting useless
11262 adjacent line markers. Avoid emitting line markers for tokens
11263 originating from the expansion of built-in macros.
11264 (scan_translation_unit_directives_only): Adjust.
11265
4d661eaa
MP
112662014-07-15 Marek Polacek <polacek@redhat.com>
11267
11268 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
11269 TYPE_MAX_VALUE is NULL.
11270
b108f48f
JJ
112712014-07-14 Jakub Jelinek <jakub@redhat.com>
11272
11273 PR middle-end/61294
11274 * c.opt (Wmemset-transposed-args): New warning.
11275
c0221884
JM
112762014-07-10 Jason Merrill <jason@redhat.com>
11277
11278 PR c++/61659
11279 PR c++/61687
11280 * c.opt (-fuse-all-virtuals): New.
11281
63dfbb95
RB
112822014-07-09 Richard Biener <rguenther@suse.de>
11283
11284 PR c-family/61741
11285 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
11286 using unsigned arithmetic if overflow does not wrap instead of
11287 if overflow is undefined.
11288
773ec47f
MP
112892014-07-06 Marek Polacek <polacek@redhat.com>
11290
11291 PR c/6940
11292 * c.opt (Wsizeof-array-argument): New option.
11293
00a7ba58
JJ
112942014-07-03 Jakub Jelinek <jakub@redhat.com>
11295
b1726d6c 11296 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
00a7ba58
JJ
11297 comments->count <= 1, as comments->entries might be NULL.
11298
52ec0ea3
MP
112992014-07-01 Marek Polacek <polacek@redhat.com>
11300
11301 * c.opt (Wint-conversion): New option.
11302
d5c3d343
MP
113032014-07-01 Marek Polacek <polacek@redhat.com>
11304
11305 PR c/58286
11306 * c.opt (Wincompatible-pointer-types): New option.
11307
6e7ceb17
PC
113082014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
11309
11310 PR c++/51400
11311 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
11312 Do not discard TYPE_QUALS of type.
11313
da73100b
JM
113142014-06-26 Jason Merrill <jason@redhat.com>
11315
11316 * c-common.h (enum cxx_dialect): Add cxx1z.
11317 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
11318 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
11319
08eedf75
TJ
113202014-06-26 Teresa Johnson <tejohnson@google.com>
11321
11322 * c-common.h (get_dump_info): Declare.
11323 * c-gimplify.c (c_genericize): Use saved dump files.
11324 * c-opts.c (c_common_parse_file): Begin and end dumps
11325 once around parsing invocation.
11326 (get_dump_info): New function.
11327
7b56b2f8
MP
113282014-06-23 Marek Polacek <polacek@redhat.com>
11329 Andrew MacLeod <amacleod@redhat.com>
11330
11331 PR c/61553
11332 * c-common.c (get_atomic_generic_size): Don't segfault if the
11333 type doesn't have a size.
11334
0e37a2f3
MP
113352014-06-20 Marek Polacek <polacek@redhat.com>
11336
11337 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
11338 (ubsan_walk_array_refs_r): New function.
11339 (c_genericize): Instrument array bounds.
11340 * c-ubsan.c: Include "internal-fn.h".
11341 (ubsan_instrument_division): Mark instrumented arrays as having
11342 side effects. Adjust ubsan_type_descriptor call.
11343 (ubsan_instrument_shift): Likewise.
11344 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
11345 (ubsan_instrument_bounds): New function.
11346 (ubsan_array_ref_instrumented_p): New function.
11347 (ubsan_maybe_instrument_array_ref): New function.
11348 * c-ubsan.h (ubsan_instrument_bounds): Declare.
11349 (ubsan_array_ref_instrumented_p): Declare.
11350 (ubsan_maybe_instrument_array_ref): Declare.
11351
113522014-06-20 Hale Wang <hale.wang@arm.com>
dd6fe7d4
HW
11353
11354 PR lto/61123
11355 * c.opt (fshort-enums): Add to LTO.
11356 * c.opt (fshort-wchar): Likewise.
11357
5c3d09f7
MP
113582014-06-16 Marek Polacek <polacek@redhat.com>
11359
11360 PR c/60439
11361 * c.opt (Wswitch-bool): Add Var.
11362
9cf32741
JJ
113632014-06-12 Jakub Jelinek <jakub@redhat.com>
11364
11365 PR middle-end/61486
11366 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
11367 #pragma omp target teams or
11368 #pragma omp {,target }teams distribute simd.
11369
62984918
JM
113702014-06-12 Jason Merrill <jason@redhat.com>
11371
11372 * c.opt (Wabi=, fabi-compat-version): New.
11373 * c-opts.c (c_common_handle_option): Handle -Wabi=.
11374 (c_common_post_options): Handle flag_abi_compat_version default.
11375 Disallow -fabi-compat-version=1.
11376 * c-common.h (abi_version_crosses): New.
11377
f961457f
JH
113782014-06-11 Jan Hubicka <hubicka@ucw.cz>
11379
adfac8df 11380 * c-common.c (handle_section_attribute): Update handling for
f961457f
JH
11381 section names that are no longer trees.
11382
92d28cbb
JJ
113832014-06-10 Jakub Jelinek <jakub@redhat.com>
11384
11385 PR fortran/60928
11386 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
11387 (omp_pragmas): ... back here.
11388
742938c9
MP
113892014-06-05 Marek Polacek <polacek@redhat.com>
11390
11391 PR c/49706
11392 * c-common.c (warn_logical_not_parentheses): New function.
11393 * c-common.h (warn_logical_not_parentheses): Declare.
11394 * c.opt (Wlogical-not-parentheses): New option.
11395
9d548dfb
MP
113962014-06-04 Marek Polacek <polacek@redhat.com>
11397
11398 PR c/30020
11399 * c-common.c (check_case_bounds): Add location parameter.
11400 Use it.
11401 (c_add_case_label): Pass loc to check_case_bounds.
11402
fedfecef
MP
114032014-06-03 Marek Polacek <polacek@redhat.com>
11404
11405 PR c/60439
11406 * c.opt (Wswitch-bool): New option.
11407
f6a7cffc
TS
114082014-05-22 Thomas Schwinge <thomas@codesourcery.com>
11409
040d18b6
TS
11410 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
11411 Remove prototypes.
11412 (record_types_used_by_current_var_decl): Move prototype to where
11413 it belongs.
11414
f6a7cffc
TS
11415 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
11416 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
11417 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
11418
632f2871
RS
114192014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
11420
11421 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
11422 * c-common.c (c_common_nodes_and_builtins): Don't initialize
11423 void_zero_node.
11424 * c-pretty-print.c (pp_c_void_constant): New function.
11425 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
11426 (c_pretty_printer::expression): Handle VOID_CST.
11427 * cilk.c (extract_free_variables): Likewise.
11428 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
11429 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
11430
766090c2
TS
114312014-05-17 Trevor Saunders <tsaunders@mozilla.com>
11432
11433 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
11434 * c-pragma.c (push_alignment): Adjust.
11435 (handle_pragma_push_options): Likewise.
11436
661a0813
MP
114372014-05-09 Marek Polacek <polacek@redhat.com>
11438
11439 PR c/50459
11440 * c-common.c (check_user_alignment): Return -1 if alignment is error
11441 node.
11442 (handle_aligned_attribute): Don't call default_conversion on
11443 FUNCTION_DECLs.
11444 (handle_vector_size_attribute): Likewise.
11445 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
11446 (handle_sentinel_attribute): Call default_conversion and allow even
11447 integral types as an argument.
11448
2793eeab
MP
114492014-05-08 Marek Polacek <polacek@redhat.com>
11450
11451 PR c/61053
11452 * c-common.c (min_align_of_type): New function factored out from...
11453 (c_sizeof_or_alignof_type): ...here.
11454 * c-common.h (min_align_of_type): Declare.
11455
f827930a
MP
114562014-05-08 Marek Polacek <polacek@redhat.com>
11457
11458 PR c/61077
11459 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
11460 parameter type of main.
11461
ca49b74e
DD
114622014-05-07 DJ Delorie <dj@redhat.com>
11463
11464 * c-cppbuiltin.c (print_bits_of_hex): New.
11465 (builtin_define_type_minmax): Print values using hex so as not to
11466 require a pre-computed list of string values.
11467
1d60af08
KZ
114682014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
11469 Mike Stump <mikestump@comcast.net>
11470 Richard Sandiford <rdsandiford@googlemail.com>
11471
11472 * c-ada-spec.c: Include wide-int.h.
11473 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
11474 (dump_generic_ada_node): Use wide-int interfaces.
11475 * c-common.c: Include wide-int-print.h.
11476 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
11477 (pointer_int_sum): Use wide-int interfaces.
11478 (c_common_nodes_and_builtins): Use make_int_cst.
11479 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
11480 (handle_alloc_size_attribute): Use wide-int interfaces.
11481 (get_nonnull_operand): Likewise.
11482 * c-format.c (get_constant): Use tree_fits_uhwi_p.
11483 * c-lex.c: Include wide-int.h.
11484 (narrowest_unsigned_type): Take a widest_int rather than two
11485 HOST_WIDE_INTs.
11486 (narrowest_signed_type): Likewise.
11487 (interpret_integer): Update accordingly. Use wide-int interfaces.
11488 (lex_charconst): Use wide-int interfaces.
11489 * c-pretty-print.c: Include wide-int.h.
11490 (pp_c_integer_constant): Use wide-int interfaces.
11491 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
11492 INT_CST_LT_UNSIGNED.
11493
b15458be
RB
114942014-05-06 Richard Biener <rguenther@suse.de>
11495
11496 * c-opts.c (c_common_post_options): For -freestanding,
11497 -fno-hosted and -fno-builtin disable pattern recognition
11498 if not enabled explicitely.
11499
6577374e
MP
115002014-05-02 Marek Polacek <polacek@redhat.com>
11501
11502 * c.opt (Wsizeof-pointer-memaccess): Describe option.
11503
d00887e8
MP
115042014-05-01 Marek Polacek <polacek@redhat.com>
11505
11506 PR c/43245
11507 * c.opt (Wdiscarded-qualifiers): Add.
11508
f8ed5150
MP
115092014-04-30 Marek Polacek <polacek@redhat.com>
11510
11511 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
11512 INT_MIN / -1 sanitization only for integer types.
11513
45484dcf
MP
115142014-04-25 Marek Polacek <polacek@redhat.com>
11515
11516 PR c/18079
11517 * c-common.c (handle_noinline_attribute): Warn if the attribute
11518 conflicts with always_inline attribute.
11519 (handle_always_inline_attribute): Warn if the attribute conflicts
11520 with noinline attribute.
11521
38e514c0
MP
115222014-04-25 Marek Polacek <polacek@redhat.com>
11523
11524 PR c/60156
11525 * c-common.c (check_main_parameter_types): Warn about variadic main.
11526
44875f92
MS
115272014-04-24 Mike Stump <mikestump@comcast.net>
11528
11529 * c.opt (Wshadow-ivar): Default to on.
11530
dcaaa5a0
DP
115312014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
11532
11533 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
11534
c07d7c02
MP
115352014-04-23 Marek Polacek <polacek@redhat.com>
11536
11537 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
11538
1c33c9b7
JJ
115392014-04-22 Jakub Jelinek <jakub@redhat.com>
11540
11541 PR sanitizer/60275
11542 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
11543 if flag_sanitize_undefined_trap_on_error.
11544 (ubsan_instrument_division, ubsan_instrument_shift,
11545 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
11546 if !flag_sanitize_recover.
11547
793c625f
MG
115482014-04-22 Marc Glisse <marc.glisse@inria.fr>
11549
11550 PR libstdc++/43622
11551 * c-common.c (registered_builtin_types): Make non-static.
11552 * c-common.h (registered_builtin_types): Declare.
11553
b0f1bf36 115542014-04-14 Richard Biener <rguenther@suse.de>
ab20d992 11555 Marc Glisse <marc.glisse@inria.fr>
b0f1bf36
RB
11556
11557 PR c/60819
11558 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
11559 apply may-alias the scalar pointer type when applicable.
11560
3b07fa4a
IZ
115612014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
11562
11563 PR middle-end/60467
11564 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
11565 as possible argument for Cilk_spawn.
11566
cbbd2b1c
TB
115672014-04-11 Tobias Burnus <burnus@net-b.de>
11568
11569 PR c/60194
11570 * c.opt (Wformat-signedness): Add
11571 * c-format.c(check_format_types): Use it.
11572
6415bd5d
JM
115732014-04-11 Jason Merrill <jason@redhat.com>
11574
11575 PR c++/57926
11576 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
11577 default_conversion for an array argument.
11578
6525783a
MP
115792014-04-08 Marek Polacek <polacek@redhat.com>
11580
11581 PR sanitizer/60745
11582 * c-ubsan.c: Include asan.h.
11583 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
11584
880a467b
NS
115852014-04-03 Nathan Sidwell <nathan@codesourcery.com>
11586
11587 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
11588
7b59ff2d
MP
115892014-04-02 Marek Polacek <polacek@redhat.com>
11590
11591 * c-common.h (c_expand_expr): Remove declaration.
11592
8edbfaa6
JJ
115932014-03-28 Jakub Jelinek <jakub@redhat.com>
11594
11595 PR c++/60689
11596 * c-common.c (add_atomic_size_parameter): When creating new
11597 params vector, push the size argument first.
11598
07d72e1d
JJ
115992014-03-26 Jakub Jelinek <jakub@redhat.com>
11600
11601 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
11602 ubsan_instrument_vla, ubsan_instrument_return): Adjust
11603 ubsan_create_data callers.
11604
b35e0fa0
JJ
116052014-03-22 Jakub Jelinek <jakub@redhat.com>
11606
11607 PR debug/60603
11608 * c-opts.c (c_finish_options): Restore cb_file_change call to
11609 <built-in>.
11610
39a1ebb3
JJ
116112014-03-13 Jakub Jelinek <jakub@redhat.com>
11612
11613 PR middle-end/36282
11614 * c-pragma.c (apply_pragma_weak): Only look at
11615 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
11616 DECL_ASSEMBLER_NAME_SET_P (decl).
11617 (maybe_apply_pending_pragma_weaks): Exit early if
11618 vec_safe_is_empty (pending_weaks) rather than only when
11619 !pending_weaks.
11620 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
11621 set assembler name back to NULL afterwards.
11622
a07f6ed2
JM
116232014-03-11 Jason Merrill <jason@redhat.com>
11624
11625 * c.opt: Add -std=gnu++14.
11626
75b107f5
IB
116272014-03-11 Ian Bolton <ian.bolton@arm.com>
11628
11629 * c-opts.c (c_common_post_options): Don't override
11630 -ffp-contract=fast if unsafe-math-optimizations is on.
11631
f42c637e
PM
116322014-03-08 Paulo Matos <paulo@matos-sorge.com>
11633
22b15758 11634 * c.opt: Enable LTO FE for fshort-double.
f42c637e 11635
70e24808
JM
116362014-03-07 Jason Merrill <jason@redhat.com>
11637
11638 * c.opt: Add -std=c++14.
11639
3af9c5e9
MP
116402014-03-06 Marek Polacek <polacek@redhat.com>
11641
11642 PR c/60197
11643 * cilk.c (contains_cilk_spawn_stmt): New function.
11644 (contains_cilk_spawn_stmt_walker): Likewise.
11645 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
11646 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
11647
b3bdf019
JJ
116482014-03-03 Jakub Jelinek <jakub@redhat.com>
11649
11650 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
11651 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
11652 even when flag_preprocess_only.
11653
ca7e759d
JM
116542014-02-26 Jason Merrill <jason@redhat.com>
11655
11656 PR c++/59231
11657 PR c++/11586
11658 * c-common.c (shorten_compare): Don't check
11659 c_inhibit_evaluation_warnings.
11660
28e41874
JJ
116612014-02-19 Jakub Jelinek <jakub@redhat.com>
11662
cca615af
JJ
11663 PR c/37743
11664 * c-common.c (c_common_nodes_and_builtins): When initializing
11665 c_uint{16,32,64}_type_node, also set corresponding
11666 uint{16,32,64}_type_node to the same value.
11667
28e41874
JJ
11668 PR c++/60267
11669 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
11670 for PRAGMA_IVDEP if flag_preprocess_only.
11671
c2bf53a1
JJ
116722014-02-12 Jakub Jelinek <jakub@redhat.com>
11673
11674 PR c/60101
11675 * c-common.c (merge_tlist): If copy is true, call new_tlist,
11676 if false, add ADD itself, rather than vice versa.
11677 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
11678 copy. For SAVE_EXPR, only call merge_tlist once.
11679
8fcbce72
JJ
116802014-02-08 Jakub Jelinek <jakub@redhat.com>
11681
11682 PR middle-end/60092
11683 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
11684 and tree_to_uhwi.
11685 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
11686 functions.
11687 (c_common_attribute_table): Add alloc_align and assume_aligned
11688 attributes.
11689
0a756a3f
MP
116902014-02-06 Marek Polacek <polacek@redhat.com>
11691
11692 PR c/60087
11693 * c-common.c (warn_for_sign_compare): Call warning_at with location
11694 instead of warning.
11695
7ec4847a
MP
116962014-02-05 Marek Polacek <polacek@redhat.com>
11697
11698 PR c/53123
11699 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
11700 statement.
11701
66f20604
MP
117022014-02-04 Marek Polacek <polacek@redhat.com>
11703
11704 PR c/60036
11705 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
11706 SAVE_EXPR.
11707
5d77fb19
MG
117082014-02-03 Marc Glisse <marc.glisse@inria.fr>
11709
11710 PR c++/53017
11711 PR c++/59211
11712 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
11713 handle_vector_size_attribute, handle_nonnull_attribute): Call
11714 default_conversion on the attribute argument.
11715 (handle_nonnull_attribute): Increment the argument number.
11716
81e5eca8
MP
117172014-01-31 Marek Polacek <polacek@redhat.com>
11718
11719 PR c/59963
11720 * c-common.c (add_atomic_size_parameter): Pass vNULL to
11721 build_function_call_vec.
11722 (resolve_overloaded_builtin): Likewise.
11723 * c-common.h (build_function_call_vec): Adjust declaration.
11724
68fca595
MP
117252014-01-30 Marek Polacek <polacek@redhat.com>
11726
11727 PR c/59940
11728 * c-common.h (unsafe_conversion_p): Adjust declaration.
11729 (warnings_for_convert_and_check): Likewise.
11730 (convert_and_check): Likewise.
11731 * c-common.c (unsafe_conversion_p): Add location parameter. Call
11732 expansion_point_location_if_in_system_header on it.
11733 (warnings_for_convert_and_check): Add location parameter. Call
11734 expansion_point_location_if_in_system_header on it. Use it.
11735 (convert_and_check): Add location parameter. Use it.
11736 (conversion_warning): Likewise.
11737 (c_add_case_label): Adjust convert_and_check calls.
11738 (scalar_to_vector): Adjust unsafe_conversion_p calls.
11739
b72271b9
BI
117402014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
11741
11742 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
11743 flag_cilkplus.
11744 * c-pragma.c (init_pragma): Likewise.
11745 * c.opt: Likewise.
11746
393e8e8b
MP
117472014-01-23 Marek Polacek <polacek@redhat.com>
11748
11749 PR c/59846
11750 * c-common.c (shorten_compare): Add location_t parameter.
11751 * c-common.h (shorten_binary_op): Adjust declaration.
11752
f04dda30
MP
117532014-01-23 Marek Polacek <polacek@redhat.com>
11754
11755 PR c/58346
11756 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
11757 * c-common.h: Declare it.
11758
621955cb
EB
117592014-01-20 Eric Botcazou <ebotcazou@adacore.com>
11760
11761 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
11762 * c-ada-spec.c (dump_ads): Likewise.
11763 (cpp_check): Likewise.
11764 (dump_ada_specs): Likewise.
11765
117662014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
67bf2939
LA
11767
11768 PR c++/49718
11769 * c-common.c (handle_no_instrument_function_attribute): Allow
11770 no_instrument_function attribute in class member
11771 definition/declaration.
11772
241f845a
JJ
117732014-01-15 Jakub Jelinek <jakub@redhat.com>
11774
11775 PR c/58943
11776 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
11777 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
11778 being COMPOUND_EXPR.
11779 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
11780 operand a SAVE_EXPR and second MODIFY_EXPR.
11781
e83b8e2e
JJ
117822014-01-09 Jakub Jelinek <jakub@redhat.com>
11783
11784 PR target/58115
11785 * c-pch.c (c_common_write_pch): Call
11786 prepare_target_option_nodes_for_pch.
11787
23a5b65a
RS
117882014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
11789
11790 Update copyright years
11791
f9030485
RS
117922014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
11793
11794 * array-notation-common.c, c-cilkplus.c: Use the standard form for
11795 the copyright notice.
11796
f2aa696b
EB
117972013-12-28 Eric Botcazou <ebotcazou@adacore.com>
11798
11799 * c-ada-spec.c (print_constructor): New function.
11800 (print_destructor): Retrieve the origin of the destructor.
11801 (print_ada_declaration): Revamp handling of constructors/destructors.
11802
3f8257db 118032013-12-23 Stuart Hastings <stuart@apple.com>
1f26ac87
JM
11804 Bill Maddox <maddox@google.com>
11805 Jason Merrill <jason@redhat.com>
11806
11807 * c.opt: Add -fdeclone-ctor-dtor.
11808 * c-opts.c (c_common_post_options): Default to on iff -Os.
11809
41958c28
BI
118102013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
11811
11812 * c-common.c (c_common_attribute_table): Added "cilk simd function"
11813 attribute.
11814 * c-pragma.h (enum pragma_cilk_clause): Remove.
ab20d992 11815 (enum pragma_omp_clause): Added the following fields:
41958c28
BI
11816 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
11817 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
11818 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
11819 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
11820 PRAGMA_CILK_CLAUSE_UNIFORM.
11821
b1726d6c 11822
12893402
BI
118232013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
11824
11825 * cilk.c (cilk_outline): Made this function non-static.
11826 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
11827 (create_cilk_wrapper): Added a new parameter: a function pointer.
11828 (c_install_body_w_frame_cleanup): Remove
11829 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
11830 * c-common.h (cilk_outline): New prototype.
11831 (gimplify_cilk_spawn): Removed two parameters.
11832 (cilk_install_body_with_frame_cleanup): New prototype.
11833 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
11834 CILK_SPAWN_STMT case.
11835
085b42ed
BS
118362013-12-11 Bernd Schmidt <bernds@codesourcery.com>
11837
2ce064c3
BS
11838 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
11839
085b42ed
BS
11840 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
11841 (int_array_type_node): Remove.
11842 * c-common.c (c_common_nodes_and_builtins): Don't build it.
11843
9e36c9ed
MP
118442013-12-05 Marek Polacek <polacek@redhat.com>
11845
11846 PR c/52023
11847 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
11848 [ADJUST_FIELD_ALIGN].
11849
296674db
JM
118502013-12-04 Joseph Myers <joseph@codesourcery.com>
11851
11852 PR c/52023
11853 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
11854 and check field alignment if set.
11855 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
11856 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
11857
b1726d6c 118582013-12-04 Jakub Jelinek <jakub@redhat.com>
31e071ae
MP
11859 Marek Polacek <polacek@redhat.com>
11860
11861 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
11862 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
11863
d7947e19
L
118642013-11-29 H.J. Lu <hongjiu.lu@intel.com>
11865
11866 PR c/59309
11867 * cilk.c (gimplify_cilk_spawn): Properly handle function without
11868 arguments.
11869
fad7652e
JJ
118702013-11-29 Jakub Jelinek <jakub@redhat.com>
11871
11872 PR c/59280
11873 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
11874 goto invalid. If it is error_mark_node, don't issue further
11875 diagnostics.
11876
8b5e1202
SO
118772013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
11878
11879 * c.opt (Wopenmp-simd): New.
11880
0a508bb6
JJ
118812013-11-22 Jakub Jelinek <jakub@redhat.com>
11882
11883 * c-ubsan.h (ubsan_instrument_return): New prototype.
11884 * c-ubsan.c (ubsan_instrument_return): New function.
11885
2fb9a547
AM
118862013-11-22 Andrew MacLeod <amacleod@redhat.com>
11887
11888 * c-common.c: Add required include files from gimple.h.
ab20d992
JJ
11889 * c-gimplify.c: Likewise.
11890 * cilk.c: Likewise.
2fb9a547 11891
8400e75e
DM
118922013-11-22 David Malcolm <dmalcolm@redhat.com>
11893
11894 * c-common.c (unsafe_conversion_p): Remove use of
11895 EXPR_LOC_OR_HERE macro.
11896 (conversion_warning): Likewise.
11897 (warnings_for_convert_and_check): Likewise.
11898 (warn_for_collisions_1): Likewise.
11899 (shorten_compare): Likewise, and remove use of in_system_header
11900 macro, using the location from the former.
11901 * c-lex.c (dump_one_header): Remove use of input_filename macro.
11902 (cb_def_pragma): Remove use of in_system_header macro.
11903 (lex_string): Likewise.
11904 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
11905
eb1ce453
KZ
119062013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
11907 Mike Stump <mikestump@comcast.net>
11908 Richard Sandiford <rdsandiford@googlemail.com>
11909
11910 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
11911 instead of TREE_INT_CST_LOW, in cases where there is a protecting
11912 tree_fits_shwi_p or tree_fits_uhwi_p.
11913 (dump_generic_ada_node): Likewise.
11914 * c-format.c (check_format_arg): Likewise.
11915 * c-pretty-print.c (pp_c_integer_constant): Likewise.
11916
6b3b8c27
KZ
119172013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
11918
11919 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
11920
49b0aa18
JC
119212013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
11922
11923 PR c/53001
11924 * c-common.c (unsafe_conversion_p): Make this function
11925 return an enumeration with more detail.
11926 (conversion_warning): Use the new return type of
11927 unsafe_conversion_p to separately warn either about conversions
11928 that lower floating point number precision or about the other
11929 kinds of conversions.
11930 * c-common.h (enum conversion_safety): New enumeration.
8e745a17
JJ
11931 (unsafe_conversion_p): switching return type to
11932 conversion_safety enumeration.
49b0aa18
JC
11933 * c.opt: Adding new warning -Wfloat-conversion and
11934 enabling it with -Wconversion.
11935
b826515a
BS
119362013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
11937
8e745a17
JJ
11938 * c-opts.c: Include plugin.h.
11939 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
b826515a 11940
b9a55b13
MP
119412013-11-19 Marek Polacek <polacek@redhat.com>
11942
11943 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
11944 call.
11945 (ubsan_instrument_shift): Likewise.
11946 (ubsan_instrument_vla): Likewise.
11947
7d362f6c
RS
119482013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
11949
11950 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
11951 cast to unsigned type.
11952
386b1f1f
RS
119532013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
11954
11955 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
11956 tree_low_cst.
11957 (complete_array_type): Update comment to refer to tree_to_[su]hwi
11958 rather than tree_low_cst.
11959
ae7e9ddd
RS
119602013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
11961
11962 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
11963 tree_to_uhwi throughout.
11964
9439e9a1
RS
119652013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
11966
11967 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
11968 tree_low_cst (..., 0) with tree_to_shwi throughout.
11969
cc269bb6
RS
119702013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
11971
11972 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
11973 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
11974
9541ffee
RS
119752013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
11976
11977 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
11978 host_integerp (..., 0) with tree_fits_shwi_p throughout.
11979
c02065fc
AH
119802013-11-15 Aldy Hernandez <aldyh@redhat.com>
11981
11982 * c-cilkplus.c: New file.
11983 * c-common.c (readonly_error): Add location argument.
11984 * c-common.h (readonly_error): Same.
11985 (c_finish_cilk_clauses): Protoize.
11986 (c_check_cilk_loop): Same.
11987 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
11988 Do not fail on error_mark_node.
11989 Abstract increment canonicalization to here...
11990 (c_omp_for_incr_canonicalize_ptr): New.
11991 c-pragma.c (init_pragma): Register "simd" pragma.
11992 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
11993 (enum pragma_cilk_clause): New.
11994
9cc65f15
RS
119952013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
11996
11997 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
11998 wchar_type and host_integerp checks.
11999
18f429e2
AM
120002013-11-14 Andrew MacLeod <amacleod@redhat.com>
12001
12002 * c-common.c: Likewise.
12003 * c-gimplify.c: Likewise.
12004 * cilk.c: Likewise.
12005
d8a2d370
DN
120062013-11-14 Diego Novillo <dnovillo@google.com>
12007
12008 * c-common.c: Include fold-const.h.
12009 Include stor-layout.h.
12010 Include calls.h.
12011 Include stringpool.h.
12012 Include attribs.h.
12013 Include varasm.h.
12014 Include trans-mem.h.
12015 * c-cppbuiltin.c: Include stor-layout.h.
12016 Include stringpool.h.
12017 * c-format.c: Include stringpool.h.
12018 * c-lex.c: Include stringpool.h.
12019 Include stor-layout.h.
12020 * c-pragma.c: Include stringpool.h.
12021 Include attribs.h.
12022 Include varasm.h.
12023 Include gcc-symtab.h.
12024 * c-pretty-print.c: Include stor-layout.h.
12025 Include attribs.h.
12026 * cilk.c: Include stringpool.h.
12027 Include calls.h.
12028
38b7bc7f
JM
120292013-11-13 Joseph Myers <joseph@codesourcery.com>
12030
12031 * c-common.h (enum rid): Add RID_AUTO_TYPE.
12032 * c-common.c (c_common_reswords): Add __auto_type.
12033 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
12034
45b0be94
AM
120352013-11-12 Andrew MacLeod <amacleod@redhat.com>
12036
18f429e2
AM
12037 * c-common.c: Include gimplify.h.
12038 * c-gimplify.c: Likewise.
12039 * cilk.c: Likewise.
12040 * c-omp.c: Include gimple-expr.h instead of gimple.h.
12041 * c-ubsan.c: Don't include gimple.h.
45b0be94 12042
582d9b50
JM
120432013-11-12 Joseph Myers <joseph@codesourcery.com>
12044
12045 * c-common.c (c_common_reswords): Add _Thread_local.
12046
6b28e197
JM
120472013-11-09 Joseph Myers <joseph@codesourcery.com>
12048
12049 * c-common.c (atomic_size_supported_p): New function.
12050 (resolve_overloaded_atomic_exchange)
12051 (resolve_overloaded_atomic_compare_exchange)
12052 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
12053 Use it instead of comparing size with a local list of sizes.
12054
267bac10
JM
120552013-11-07 Andrew MacLeod <amacleod@redhat.com>
12056 Joseph Myers <joseph@codesourcery.com>
12057
12058 * c-common.h (enum rid): Add RID_ATOMIC.
12059 * c-common.c (c_common_reswords): Add _Atomic.
12060 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
12061 (keyword_is_type_qualifier): Accept RID_ATOMIC.
12062 * c-format.c (check_format_types): Check for extra _Atomic
12063 qualifiers in format argument.
12064 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
12065 (pp_c_type_qualifier_list): Mention _Atomic in comment.
12066
5157b91e
TB
120672013-11-06 Tobias Burnus <burnus@net-b.de>
12068
12069 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
12070
6dbe0958
JM
120712013-11-06 Joseph Myers <joseph@codesourcery.com>
12072
12073 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
12074 standards modes.
12075 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
12076 to mean lack of IEEE 754 support.
12077
e8ff5196
TB
120782013-11-05 Tobias Burnus <burnus@net-b.de>
12079
12080 * c.opt (-Wdate-time): New option
12081 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
12082
254a0760
JM
120832013-11-05 Joseph Myers <joseph@codesourcery.com>
12084
12085 * c-cppbuiltin.c (cpp_iec_559_value): Test
12086 flag_excess_precision_cmdline not flag_excess_precision.
12087
6d7f7e0a
TB
120882013-11-05 Tobias Burnus <burnus@net-b.de>
12089
12090 * c.opt (fopenmp-simd): New option.
12091 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
12092 (omp_pragmas): ... this new struct.
12093 (c_pp_lookup_pragma): Also walk omp_pragmas.
12094 (init_pragma): Init pragmas for -fopenmp-simd.
12095
55a7f02f
MP
120962013-11-04 Marek Polacek <polacek@redhat.com>
12097
12098 PR c++/58979
12099 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
12100
9193fb05
JM
121012013-11-04 Joseph Myers <joseph@codesourcery.com>
12102
12103 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
12104 New functions.
12105 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
12106
94159ecf
EB
121072013-11-04 Eric Botcazou <ebotcazou@adacore.com>
12108
12109 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
12110 (dump_ada_specs): Adjust prototype of second callback.
12111 * c-ada-spec.c (cpp_check): New global variable.
12112 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
12113 (print_generic_ada_decl): Likewise.
12114 (has_static_fields): Change return type to bool and add guard.
12115 (has_nontrivial_methods): New predicate.
12116 (is_tagged_type): Change return type to bool.
12117 (separate_class_package): Call has_nontrivial_methods.
12118 (pp_ada_tree_identifier): Minor tweaks.
12119 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
12120 (dump_ada_array_domains): Likewise.
12121 (dump_ada_array_type): Likewise.
12122 (dump_template_types): Remove cpp_check parameter and do not pass it to
12123 dump_generic_ada_node.
12124 (dump_ada_template): Likewise.
12125 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
12126 recursively.
12127 (print_ada_methods): Change return type to integer. Remove cpp_check
12128 parameter and do not pass it down.
12129 (dump_nested_types): Remove cpp_check parameter and do not pass it to
12130 dump_generic_ada_node.
12131 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
12132 accessing methods.
12133 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
12134 down. Use has_nontrivial_methods to recognize C++ classes. Use return
12135 value of print_ada_methods.
12136 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
12137 Set cpp_check to it before invoking dump_ada_nodes.
12138 (dump_ada_specs): Likewise.
12139
b906f4ca
MP
121402013-11-03 Marek Polacek <polacek@redhat.com>
12141
12142 * c-ubsan.c: Don't include hash-table.h.
12143 (ubsan_instrument_vla): New function.
12144 * c-ubsan.h: Declare it.
12145
5e20cdc9
DM
121462013-10-31 David Malcolm <dmalcolm@redhat.com>
12147
12148 Automated part of renaming of symtab_node_base to symtab_node.
12149
12150 Patch autogenerated by rename_symtab.py from
12151 https://github.com/davidmalcolm/gcc-refactoring-scripts
12152 revision 58bb219cc090b2f4516a9297d868c245495ee622
12153
12154 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
12155 symtab_node_base to symtab_node.
12156
7057e645
ESR
121572013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
12158
8e745a17 12159 Implement C++14 digit separators.
7057e645
ESR
12160 * c-lex.c (interpret_float): Remove digit separators from scratch string
12161 before building real literal.
12162
193ea7bc
JJ
121632013-10-30 Jakub Jelinek <jakub@redhat.com>
12164
12165 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
12166
939b37da
BI
121672013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
12168
12169 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
12170 fields.
12171 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
12172 enabled.
12173 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
12174 (insert_cilk_frame): New prototype.
12175 (cilk_init_builtins): Likewise.
12176 (gimplify_cilk_spawn): Likewise.
12177 (c_cilk_install_body_w_frame_cleanup): Likewise.
12178 (cilk_detect_spawn_and_unwrap): Likewise.
12179 (cilk_set_spawn_marker): Likewise.
12180 (build_cilk_sync): Likewise.
12181 (build_cilk_spawn): Likewise.
12182 * cilk.c: New file.
12183
67348ccc
DM
121842013-10-29 David Malcolm <dmalcolm@redhat.com>
12185
12186 Patch autogenerated by refactor_symtab.py from
12187 https://github.com/davidmalcolm/gcc-refactoring-scripts
12188 revision 58bb219cc090b2f4516a9297d868c245495ee622
12189
12190 * c-gimplify.c (c_genericize): Update for conversion of symtab types
12191 to a true class hierarchy.
12192 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
12193
d570872d
RS
121942013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
12195
12196 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
12197
98906124
JL
121982013-10-26 Jeff Law <law@redhat.com>
12199
adfac8df
JJ
12200 * c-common.c (c_define_builtins): Remove mudflap support.
12201 * c.opt: Ignore and warn for mudflap options.
98906124 12202
d73749df 122032013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
12204
12205 PR other/33426
12206 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
12207 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
12208
3f04b1bb
JM
122092013-10-23 Jason Merrill <jason@redhat.com>
12210
12211 * c-format.c (gcc_cxxdiag_char_table): Add %X.
12212
acf0174b
JJ
122132013-10-11 Jakub Jelinek <jakub@redhat.com>
12214
acd15a28
JJ
12215 * c-common.h (omp_clause_mask::operator !=): New method.
12216 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
12217 instead of if (mask & something) tests everywhere.
12218
acf0174b
JJ
12219 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
12220 201307 instead of 201107.
12221 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
12222 (c_common_attribute_table): Add "omp declare target" and
12223 "omp declare simd" attributes.
12224 (handle_omp_declare_target_attribute,
12225 handle_omp_declare_simd_attribute): New functions.
12226 * c-omp.c: Include c-pragma.h.
12227 (c_finish_omp_taskgroup): New function.
12228 (c_finish_omp_atomic): Add swapped argument, if true,
12229 build the operation first with rhs, lhs arguments and use NOP_EXPR
12230 build_modify_expr.
12231 (c_finish_omp_for): Add code argument, pass it down to make_code.
12232 (c_omp_split_clauses): New function.
12233 (c_split_parallel_clauses): Removed.
12234 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
12235 c_omp_declare_simd_clauses_to_decls): New functions.
12236 * c-common.h (omp_clause_mask): New type.
12237 (OMP_CLAUSE_MASK_1): Define.
12238 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
12239 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
12240 omp_clause_mask::operator |, omp_clause_mask::operator &,
12241 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
12242 omp_clause_mask::operator ==): New methods.
12243 (enum c_omp_clause_split): New.
12244 (c_finish_omp_taskgroup): New prototype.
12245 (c_finish_omp_atomic): Add swapped argument.
12246 (c_finish_omp_for): Add code argument.
12247 (c_omp_split_clauses): New prototype.
12248 (c_split_parallel_clauses): Removed.
12249 (c_omp_declare_simd_clauses_to_numbers,
12250 c_omp_declare_simd_clauses_to_decls): New prototypes.
12251 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
12252 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
12253 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
12254 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
12255 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
12256 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
12257 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
12258 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
12259 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
12260 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
12261 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
12262 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
12263 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
12264 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
12265 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
12266 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
12267 PRAGMA_OMP_CLAUSE_UNIFORM.
12268
826cacfe
MG
122692013-10-09 Marc Glisse <marc.glisse@inria.fr>
12270
12271 PR tree-optimization/20318
12272 * c-common.c (handle_returns_nonnull_attribute): New function.
12273 (c_common_attribute_table): Add returns_nonnull.
12274
2284b034
MG
122752013-10-03 Marc Glisse <marc.glisse@inria.fr>
12276
12277 PR c++/19476
12278 * c.opt (fcheck-new): Move to common.opt.
12279
b56e9788
MP
122802013-09-25 Marek Polacek <polacek@redhat.com>
12281 Jakub Jelinek <jakub@redhat.com>
12282
12283 PR sanitizer/58413
12284 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
12285 an expression if we can prove it is correct.
12286 (ubsan_instrument_division): Likewise. Remove unnecessary
12287 check.
12288
ce6923c5
MP
122892013-09-18 Marek Polacek <polacek@redhat.com>
12290
12291 PR sanitizer/58411
12292 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
12293 Declare it.
12294 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
12295
fb5610fb
IS
122962013-09-14 Iain Sandoe <iain@codesourcery.com>
12297
12298 PR target/48094
12299 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
12300 fobjc-gc, freplace-objc-classes): Accept for LTO.
12301
88b0e79e
JC
123022013-09-13 Jacek Caban <jacek@codeweavers.com>
12303
12304 * c-target.def: New hook
12305
c9b0866a
PC
123062013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
12307
12308 PR c++/43452
12309 * c.opt (Wdelete-incomplete): Add.
12310
0af94e6f
JR
123112013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
12312
12313 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
12314 (vector_types_compatible_elements_p): New function.
12315 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
12316 declaration.
12317 (vector_types_compatible_elements_p): Declare.
12318
7c26172c
GDR
123192013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
12320
12321 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
12322 a virtual member function.
12323 (pp_simple_type_specifier): Remove.
12324 (pp_c_type_specifier): Likewise.
12325 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
12326 Rename from pp_c_type_specifier. Adjust.
12327 (c_pretty_printer::c_pretty_printer): Do not assign to
12328 simple_type_specifier.
12329
20059c8b
GDR
123302013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
12331
12332 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
12333 member function.
12334 (c_pretty_printer::storage_class_specifier): Likewise.
12335 (c_pretty_printer::initializer): Likewise.
12336 (pp_declaration): Remove.
12337 (pp_declaration_specifiers): Likewise.
12338 (pp_abstract_declarator): Likewise.
12339 (pp_declarator): Likewise.
12340 (pp_type_id): Likewise.
12341 (pp_statement): Likewise.
12342 (pp_constant): Likewise.
12343 (pp_id_expression): Likewise.
12344 (pp_primary_expression): Likewise.
12345 (pp_unary_expression): Likewise.
12346 (pp_multiplicative_expression): Likewise.
12347 (pp_conditional_expression): Likewise.
12348 (pp_assignment_expression): Likewise.
12349 (pp_expression): Likewise.
12350 (pp_c_type_id): Likewise.
12351 (pp_c_storage_class_specifier): Likewise.
12352 * c-pretty-print.c (pp_c_type_cast): Tidy.
12353 (pp_c_pointer): Likewise.
12354 (pp_c_type_specifier): Likewise.
12355 (pp_c_parameter_type_list): Likewise.
12356 (pp_c_function_definition): Likewise.
12357 (pp_c_init_declarator): Likewise.
12358 (pp_c_initializer_list): Likewise.
12359 (pp_c_constructor_elts): Likewise.
12360 (c_pretty_printer::direct_abstract_declarator): Likewise.
12361 (c_pretty_printer::declaration_specifiers): Likewise.
12362 (c_pretty_printer::primary_expression): Likewise.
12363 (c_pretty_printer::postfix_expression): Likewise.
12364 (c_pretty_printer::type_id): Rename from pp_c_type_id.
12365 (c_pretty_printer::storage_class_specifier): Rename from
12366 pp_c_storage_class_specifier.
12367 (c_pretty_printer::initializer): Rename from pp_c_initializer.
12368 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
12369 storage_class_specifier, initializer, offset_list, flags.
12370
de5a5fa1
MP
123712013-08-30 Marek Polacek <polacek@redhat.com>
12372
12373 * c-ubsan.c: New file.
12374 * c-ubsan.h: New file.
12375
8f0e4d72
GDR
123762013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
12377
12378 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
12379 member function.
12380 (c_pretty_printer::declaration_specifiers): Likewise.
12381 (c_pretty_printer::declarator): Likewise.
12382 (c_pretty_printer::abstract_declarator): Likewise.
12383 (c_pretty_printer::direct_abstract_declarator): Likewise.
12384 (c_pretty_printer::direct_declarator): Likewise.
12385 (c_pretty_printer::function_specifier): Likewise.
12386 (pp_declaration): Adjust.
12387 (pp_declaration_specifiers): Likewise.
12388 (pp_abstract_declarator): Likewise.
12389 (pp_direct_declarator): Likewise.
12390 (pp_function_specifier): Likewise.
12391 (pp_direct_abstract_declarator): Remove as unused.
12392 (pp_c_declaration): Remove.
12393 (pp_c_declaration_specifiers): Likewise.
12394 (pp_c_declarator): Likewise.
12395 (pp_c_direct_declarator): Likewise.
12396 (pp_c_function_specifier): Likewise.
12397 (pp_c_direct_abstract_declarator): Likewise.
12398 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
12399 from pp_c_abstract_declarator. Adjust.
ab20d992 12400 (c_pretty_printer::direct_abstract_declarator): Rename from
8f0e4d72
GDR
12401 pp_c_direct_abstract_declarator. Adjust.
12402 (c_pretty_printer::function_specifier): Rename from
12403 pp_c_function_specifier. Adjust.
12404 (c_pretty_printer::declaration_specifiers): Rename from
12405 pp_c_declaration_specifiers. Adjust.
12406 (c_pretty_printer::direct_declarator): Rename from
12407 pp_c_direct_declarator. Adjust.
12408 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
12409 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
12410 (c_pretty_printer::c_pretty_printer): Do not assign to
12411 declaration, declaration_specifiers, declarator,
12412 direct_declarator, direct_abstract_declarator, function_specifier.
12413
00d34d3a
GDR
124142013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
12415
12416 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
12417 virtual member function.
12418 (c_pretty_printer::multiplicative_expression): Likewise.
12419 (c_pretty_printer::conditional_expression): Likewise.
12420 (c_pretty_printer::assignment_expression): Likewise.
12421 (c_pretty_printer::expression): Likewise.
12422 (pp_unary_expression): Adjust.
12423 (pp_multiplicative_expression): Likewise.
12424 (pp_assignment_expression): Likewise.
12425 (pp_conditional_expression): Likewise.
12426 (pp_expression): Likewise.
12427 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
12428 from pp_c_unary_expression. Adjust.
12429 (c_pretty_printer::multiplicative_expression): Rename from
12430 pp_c_multiplicative_expression. Adjust.
12431 (c_pretty_printer::conditional_expression): Rename from
12432 pp_c_conditional_expression. Adjust.
12433 (c_pretty_printer::assignment_expression): Rename from
12434 pp_c_assignment_expression. Adjust.
12435 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
12436 (c_pretty_printer::c_pretty_printer): Do not assign to
12437 unary_expression, multiplicative_expression,
12438 conditional_expression, expression.
12439
fb22178f
GDR
124402013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
12441
12442 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
12443 virtual member function.
12444 (pp_postfix_expression): Adjust.
12445 (pp_c_postfix_expression): Remove.
12446 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
12447 from pp_c_postfix_expression. Adjust.
12448 (c_pretty_printer::c_pretty_printer): Do not assign to
12449 postfix_expression.
12450
7ecc2600
GDR
124512013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
12452
12453 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
12454 virtua member function.
12455 (pp_primary_expression): Adjust.
12456 (pp_c_primary_expression): Remove.
12457 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
12458 from pp_c_primary_expression. Adjust.
12459 (pp_c_initializer_list): Use pp_primary_expression.
12460 (c_pretty_printer::c_pretty_printer): Do not assign to
12461 primary_expression.
12462
0691175f
GDR
124632013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
12464
12465 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
12466 * c-pretty-print.c (M_): Remove.
12467 (c_pretty_printer::translate_string): Define.
12468 (pp_c_type_specifier): Use it.
12469 (pp_c_primary_expression): Likewise.
12470 (pp_c_expression): Likewise.
12471
66dfe4c4
GDR
124722013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
12473
12474 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
12475 virtual function.
12476 (pp_c_id_expression): Remove.
12477 (pp_id_expression): Adjust.
12478 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
12479 pp_c_id_expression. Adjust.
12480 (pp_c_postfix_expression): Use pp_id_expression.
12481 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
12482
ca43e9d5
GDR
124832013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
12484
12485 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
12486 member function.
12487 (pp_constant): Adjust.
12488 (pp_c_constant): Remove.
12489 * c-pretty-print.c (c_pretty_printer::constant): Rename from
12490 pp_c_constant. Adjust.
12491 (pp_c_constant)
12492 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
12493 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
12494
da6ca2b5
GDR
124952013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
12496
12497 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
12498 (c_pretty_printer::c_pretty_printer): Declare.
12499 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
12500 c_pretty_printer_init. Adjust.
12501 (print_c_tree): Do not call c_pretty_printer_init.
12502 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
12503
65a372f4
AC
125042013-08-09 Arnaud Charlet <charlet@adacore.com>
12505
12506 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
12507
fd9b0f32
PC
125082013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
12509
12510 PR c++/58080
12511 * c-common.c (pointer_int_sum): Add bool parameter.
12512 * c-common.h (pointer_int_sum): Adjust declaration.
12513
e0aec1e9
GDR
125142013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
12515
12516 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
12517 c_pretty_printer variable.
12518
b066401f
GDR
125192013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
12520
12521 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
12522 (pp_base): Remove.
12523 (pp_c_base): Likewise. Adjust users.
12524 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
12525 (pp_c_whitespace): Do not call pp_base.
12526 (pp_c_left_paren): Likewise.
12527 (pp_c_right_paren): Likewise.
12528 (pp_c_left_brace): Likewise.
12529 (pp_c_right_brace): Likewise.
12530 (pp_c_left_bracket): Likewise.
12531 (pp_c_right_bracket): Likewise.
12532 (pp_c_dot): Likewise.
12533 (pp_c_ampersand): Likewise.
12534 (pp_c_star): Likewise.
12535 (pp_c_arrow): Likewise.
12536 (pp_c_semicolon): Likewise.
12537 (pp_c_complement): Likewise.
12538 (pp_c_exclamation): Likewise.
12539 (pp_c_direct_declarator): Likewise.
12540 (pp_c_ws_string): Likewise.
12541 (pp_c_identifier): Likewise.
12542 (pp_c_statement): Likewise.
12543 (print_c_tree): Likewise.
12544
65e5a578
ESR
125452013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
12546
12547 PR c++/58072
12548 * c-common.c (c_parse_error): Catch user-defined literal tokens and
12549 provide useful error strings.
12550
137a1a27
GDR
125512013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
12552
12553 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
12554 printer functions instead of pp_string or operators and punctuators.
12555 (dump_generic_ada_node): Likewise.
12556 * c-pretty-print.c (pp_c_type_specifier): Likewise.
12557 (pp_c_relational_expression): Likewise.
12558 (pp_c_logical_or_expression): Likewise.
12559
07838b13
GDR
125602013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
12561
12562 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
12563 functions instead of pp_character.
12564 (pp_ada_tree_identifier): Likewise.
12565 (dump_ada_double_name): Likewise.
12566 (dump_ada_function_declaration): Likewise.
12567 (dump_ada_array_domains): Likewise.
12568 (dump_template_types): Likewise.
12569 (dump_generic_ada_node): Likewise.
12570 (print_ada_declaration): Likewise.
12571 (print_ada_struct_decl): Likewise.
12572 * c-pretty-print.c (pp_c_integer_constant): Likewise.
12573
433cc7b0
TT
125742013-07-23 Tom Tromey <tromey@redhat.com>
12575
12576 * c-common.h (enum rid) <RID_GENERIC>: New constant.
12577 * c-common.c (c_common_reswords): Add _Generic.
12578
688010ba
OB
125792013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
12580
12581 * c-common.c: Fix typos.
12582 * c-common.h: Likewise.
12583
2a99e5e6
LL
125842013-07-13 Lubos Lunak <l.lunak@suse.cz>
12585
12586 PR c++/55203
12587 * c-common.c (c_common_attribute_table): Add warn_unused.
12588 (handle_warn_unused_attribute): New.
12589
c26302d5
JJ
125902013-07-10 Jakub Jelinek <jakub@redhat.com>
12591
12592 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
12593 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
12594
dfeadaa0
PC
125952013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
12596
12597 PR c++/57869
12598 * c.opt: Add Wconditionally-supported.
12599
6a2fa4b2
GS
126002013-07-08 Graham Stott <graham.stott@btinternet.com>
12601
adfac8df 12602 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6a2fa4b2
GS
12603 unused variables l_length and l_node.
12604
ecdbd01a 126052013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
12606
12607 PR c/57821
12608 * c-common.c (complete_array_type): Delay folding first index
12609 like other indices. When folding, check for index overflow.
12610
bedc293e
MG
126112013-06-27 Marc Glisse <marc.glisse@inria.fr>
12612
12613 PR c++/57509
12614 * c-common.h (c_build_vec_perm_expr): New complain argument.
12615 * c-common.c (c_build_vec_perm_expr): Likewise.
12616 Use save_expr also in C++.
12617
604b2bfc
GDR
126182013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
12619
12620 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
12621 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
12622 * c-opts.c (c_common_post_options): Likewise.
12623
dfeadaa0 126242013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
713b46fa
BI
12625
12626 * array-notation-common.c (length_mismatch_in_expr): Changed the
12627 parameter type's from a dynamic array to a vec_tree. Also removed
12628 the size parameters.
12629 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
12630 the change above.
12631
2ce86d2e
BI
126322013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
12633
12634 * c-common.h (struct cilkplus_an_parts): New structure.
12635 (struct cilkplus_an_loop_parts): Likewise.
12636 (cilkplus_extract_an_triplets): New prototype.
12637 (fix_sec_implicit_args): Likewise.
12638 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
12639 (fix_sec_implicit_args): Likewise.
604b2bfc 12640
07a6825b
BI
126412013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
12642
12643 * array-notation-common.c (find_inv_trees): Removed an unwanted
12644 typecasting.
12645 * c-common.h (struct inv_list::additional_tcodes): Changed type from
12646 enum rid to enum tree_code.
12647
08346abd
JH
126482013-06-11 Jan Hubicka <jh@suse.cz>
12649
12650 * c-common.c (handle_alias_ifunc_attribute): Do not set
12651 DECL_EXTERNAL for weakref variables.
12652 * c-pragma.c (handle_pragma_weak): Make sure aliases
12653 are not declared as external.
12654
d60f1706
BI
126552013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
12656
12657 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
12658 function from c/c-array-notation.c.
12659 (is_cilkplus_reduce_builtin): Likewise.
12660 (find_rank): Likewise.
12661 (extract_array_notation_exprs): Likewise.
12662 (replace_array_notations): Likewise.
12663 (find_inv_trees): Likewise.
12664 (replace_inv_trees): Likewise.
12665 (contains_array_notation_expr): Likewise.
12666 (find_correct_array_notation_type): Likewise.
12667 * c-common.h (struct inv_list): Moved this struct from the file
12668 c/c-array-notation.c and added a new field called additional tcodes.
12669 (length_mismatch_in_expr_p): New prototype.
12670 (is_cilkplus_reduce_builtin): Likewise.
12671 (find_rank): Likewise.
12672 (extract_array_notation_exprs): Likewise.
12673 (replace_array_notation): Likewise.
12674 (find_inv_trees): Likewise.
12675 (replace_inv_trees): Likewise.
12676 (find_correct_array_notation_type): Likewise.
dfeadaa0 12677
36536d79
BI
126782013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
12679
12680 * c-common.c (c_define_builtins): When cilkplus is enabled, the
12681 function array_notation_init_builtins is called.
12682 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
12683 * c-common.def (ARRAY_NOTATION_REF): New tree.
12684 * c-common.h (build_array_notation_expr): New function declaration.
12685 (build_array_notation_ref): Likewise.
12686 (extract_sec_implicit_index_arg): New extern declaration.
12687 (is_sec_implicit_index_fn): Likewise.
12688 (ARRAY_NOTATION_CHECK): New define.
12689 (ARRAY_NOTATION_ARRAY): Likewise.
12690 (ARRAY_NOTATION_START): Likewise.
12691 (ARRAY_NOTATION_LENGTH): Likewise.
12692 (ARRAY_NOTATION_STRIDE): Likewise.
12693 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
12694 ARRAY_NOTATION_REF.
12695 (pp_c_expression): Likewise.
12696 * c.opt (flag_enable_cilkplus): New flag.
12697 * array-notation-common.c: New file.
12698
f7716d57
JJ
126992013-05-14 Jakub Jelinek <jakub@redhat.com>
12700
12701 PR c++/57274
12702 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
12703
a5e0cd1d
MG
127042013-05-10 Marc Glisse <marc.glisse@inria.fr>
12705
12706 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
12707 vectors.
12708
f6bc1c4a
HS
127092013-05-07 Han Shen <shenhan@google.com>
12710
12711 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
12712
3f12f6e9
SKS
127132013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
12714
12715 * c-common.c (check_user_alignment): Emit error for negative values.
12716
61949153
PC
127172013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
12718
12719 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
12720
e93e18e9
PC
127212013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
12722
12723 * c-cppbuiltin.c (c_cpp_builtins): Do not define
12724 __GXX_EXPERIMENTAL_CXX1Y__.
12725
44d90fe1 127262013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
8e745a17 12727 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
44d90fe1
PC
12728
12729 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
12730 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
12731 to simply use OPT_Wpointer_arith.
12732 (c_sizeof_or_alignof_type): Likewise.
12733
13f39b2e
PC
127342013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
12735
12736 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
12737
4b84d650
JJ
127382013-04-12 Jakub Jelinek <jakub@redhat.com>
12739
12740 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
12741 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
12742 specifiers.
12743
fb037b5d
SB
127442013-04-07 Steven Bosscher <steven@gcc.gnu.org>
12745
12746 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
12747
4e856798
PC
127482013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
12749
12750 * c-common.c (pointer_int_sum): Remove dead code.
12751
4b1baac8
RS
127522013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
12753
12754 PR middle-end/56524
12755 * c-common.c (handle_optimize_attribute): Don't call
12756 save_optabs_if_changed.
12757
0b50e654
JJ
127582013-03-05 Jakub Jelinek <jakub@redhat.com>
12759
12760 PR middle-end/56461
12761 * c-pch.c (pch_init): Free target_validity at the end.
12762
48c41403
JJ
127632013-03-04 Jakub Jelinek <jakub@redhat.com>
12764
12765 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
12766
e664c61c
KS
127672013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
12768 Jakub Jelinek <jakub@redhat.com>
12769
12770 PR sanitizer/56454
12771 * c-common.c (handle_no_sanitize_address_attribute): New function.
12772 (c_common_attribute_table): Add no_sanitize_address attribute.
12773 (handle_no_address_safety_analysis_attribute): Add
12774 no_sanitize_address attribute, not no_address_safety_analysis
12775 attribute.
12776
a475fd3d 127772013-02-18 Aldy Hernandez <aldyh@redhat.com>
135204dd
AH
12778
12779 PR target/52555
12780 * c-common.c (handle_optimize_attribute): Call
12781 save_optabs_if_changed.
12782
f6007d99
JJ
127832013-02-18 Jakub Jelinek <jakub@redhat.com>
12784 Steven Bosscher <steven@gcc.gnu.org>
12785
12786 PR pch/54117
12787 * c-opts.c (c_common_post_options): If debug info is enabled
12788 and non-dwarf*, refuse to load PCH files and when writing PCH
12789 file warn.
12790
cf35e2b1
JJ
127912013-02-05 Jakub Jelinek <jakub@redhat.com>
12792
12793 PR middle-end/56167
12794 * c-common.c (handle_error_attribute): Fix condition.
12795
32887460
JJ
127962013-01-30 Jakub Jelinek <jakub@redhat.com>
12797
12798 PR c++/55742
12799 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
12800
5af057d8
JM
128012013-01-18 Jason Merrill <jason@redhat.com>
12802
12803 PR target/54908
12804 * c.opt (-fextern-tls-init): New.
12805 * c-opts.c (c_common_post_options): Handle it.
12806
cc83c823
JJ
128072013-01-09 Jakub Jelinek <jakub@redhat.com>
12808
12809 PR c/48418
12810 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
12811 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
12812 and is either negative or bigger or equal to type precision
12813 of the first operand.
12814
a859517f
MP
128152012-12-03 Marek Polacek <polacek@redhat.com>
12816
12817 PR c/55570
12818 * c-common.c (check_user_alignment): Swap order of tests,
12819 check TREE_CODE first.
12820
2d7aa578
ESR
128212012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
12822
12823 PR c++/52654
12824 * c-common.h (overflow_type): New enum.
12825 (build_userdef_literal): Add overflow_type argument.
12826 (tree_userdef_literal): Add overflow_type.
12827 (USERDEF_LITERAL_OVERFLOW): New access macro.
12828 * c-common.c (build_userdef_literal): Add overflow_type
12829 argument.
12830 * c-lex.c (c_lex_with_flags): Add overflow_type to
12831 build_userdef_literal calls.
12832 (interpret_integer, interpret_float): Add overflow_type argument.
12833
cc3c4f62
RB
128342012-11-28 Richard Biener <rguenther@suse.de>
12835
12836 PR c/35634
12837 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
12838 here and use a type with proper overflow behavior for types that would
12839 need to be promoted for the arithmetic.
12840
77bc5132
JJ
128412012-11-23 Jakub Jelinek <jakub@redhat.com>
12842
12843 PR sanitizer/55435
12844 * c-common.c (handle_no_address_safety_analysis_attribute): New
12845 function.
12846 (c_common_attribute_table): Add no_address_safety_analysis.
12847
5dc99c46
SB
128482012-11-16 Simon Baldwin <simonb@google.com>
12849
12850 * c.opt: Add f[no-]canonical-system-headers.
12851 * c-opts.c (c_common_handle_option): Handle
12852 OPT_fcanonical_system_headers.
12853
a4a0016d
ESR
128542012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
12855
12856 PR c++/54413
12857 * c-opts.c (c_common_handle_option): Set new flags.
12858 * c.opt: Describe new flags.
12859
7dbb85a7
JM
128602012-11-09 Jason Merrill <jason@redhat.com>
12861
12862 * c.opt (Wabi-tag): New.
12863
ad7bac31
AK
128642012-11-09 Andi Kleen <ak@linux.intel.com>
12865
12866 PR 55139
12867 * c-common.c (get_atomic_generic_size): Mask with
8e745a17 12868 MEMMODEL_MASK
ad7bac31 12869
7332899a
MLI
128702012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
12871
12872 PR c/53063
12873 * c.opt (Wformat): Make it Alias Wformat=1.
12874 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
12875 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
12876 LangEnabledBy.
12877 (Wformat=): RejectNegative. Use LangEnabledBy.
12878 (Wnonnull): Use LangEnabledBy.
12879 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
12880 * c-format.c (set_Wformat): Delete.
12881 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
ab20d992
JJ
12882 (maybe_read_dollar_number): Likewise.
12883 (avoid_dollar_number): Likewise.
12884 (finish_dollar_format_checking): Likewise.
12885 (check_format_info): Likewise.
12886 (check_format_info_main): Likewise.
12887 (check_format_types): Likewise.
12888 (format_type_warning): Likewise.
12889 * c-common.c (int): Likewise.
12890 (check_function_sentinel): Likewise.
8e745a17 12891 * c-common.h (warn_format,set_Wformat): Do not declare here.
7332899a 12892
34a180a6
MLI
128932012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
12894
12895 PR c/53063
12896 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
12897 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
12898 Use LangEnabledBy.
12899 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
12900 common.opt.
12901 (Wvariadic-macros): Init(1).
12902 * c-opts.c (c_common_handle_option): Do not handle them
12903 explicitly.
12904 (c_common_post_options): Likewise.
12905 (sanitize_cpp_opts): warn_unused_macros is now
12906 cpp_warn_unused_macros.
12907 (push_command_line_include): Likewise.
12908 * c-common.c (warn_unknown_pragmas): Do not define.
12909 * c-common.h (warn_unknown_pragmas): Do not declare.
12910
3f46d6a5
MLI
129112012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
12912
12913 PR c/51294
12914 * c-common.c (conversion_warning): Handle conditional expressions.
12915
880661a4
JW
129162012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
12917
12918 PR c++/54930
12919 * c.opt (Wreturn_local_addr): Define new option.
12920
4514a96b
JM
129212012-10-25 Jason Merrill <jason@redhat.com>
12922
f14edc1a
JM
12923 * c.opt (Wvirtual-move-assign): New.
12924
4514a96b
JM
12925 * c.opt (Winherited-variadic-ctor): New.
12926
93100c6b
MG
129272012-10-25 Marc Glisse <marc.glisse@inria.fr>
12928
12929 PR c++/54427
12930 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
12931
1efcb8c6
JM
129322012-10-23 Joseph Myers <joseph@codesourcery.com>
12933
12934 * c-common.h (pch_cpp_save_state): Declare.
12935 * c-target.def (c_preinclude): New hook.
12936 * c-opts.c (done_preinclude): New.
12937 (push_command_line_include): Handle default preincluded header.
12938 (cb_file_change): Call pch_cpp_save_state when calling
12939 push_command_line_include.
12940 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
12941 (pch_cpp_save_state): New.
12942 (pch_init): Call pch_cpp_save_state conditionally, instead of
12943 calling cpp_save_state.
12944
4a0ae68e
MLI
129452012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
12946
12947 PR c/53063
12948 PR c/40989
12949 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
12950 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
12951 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
12952 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
12953 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
12954 * c-opts.c (c_common_handle_option): Remove explicit handling from
12955 here.
12956 (c_common_post_options): Likewise.
12957
67e4210b
EB
129582012-10-18 Eric Botcazou <ebotcazou@adacore.com>
12959
12960 * c-ada-spec.c (LOCATION_COL): Delete.
12961 (compare_location): New function.
12962 (compare_node): Use it.
12963 (compare_comment): Likewise.
12964
65d4f2cd
MLI
129652012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
12966
12967 PR c/53063
12968 PR c/40989
12969 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
12970 * c-opts.c (c_common_handle_option): Do not set them here. Add
12971 comment.
12972 (c_common_post_options): Likewise.
12973
909881cb
EB
129742012-10-16 Eric Botcazou <ebotcazou@adacore.com>
12975
12976 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
12977 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
12978 Remove POINTER_TYPE handling, add large unsigned handling and use
12979 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
12980
3a785c97
JJ
129812012-10-12 Jakub Jelinek <jakub@redhat.com>
12982
12983 PR c/54381
12984 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
12985 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
12986 locs and array of 3 trees instead of just single loc and single
12987 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
12988 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
12989 For *cmp* builtins that take two sources strings report warnings
12990 about first and second source, not about destination and source.
12991
5e54f81d
MG
129922012-10-12 Marc Glisse <marc.glisse@inria.fr>
12993
12994 PR c++/53055
12995 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
12996
f5b02f1e
EB
129972012-10-11 Eric Botcazou <ebotcazou@adacore.com>
12998
12999 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
13000 declaring something coming from another file.
13001
b46dbc6c
AC
130022012-10-10 Arnaud Charlet <charlet@adacore.com>
13003
f5b02f1e 13004 PR ada/54845
b46dbc6c
AC
13005 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
13006
5d9de0d0
PC
130072012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
13008
13009 PR c++/54194
13010 * c-common.c (warn_about_parentheses): Add location_t parameter;
13011 use EXPR_LOC_OR_LOC.
13012 * c-common.h: Update declaration.
13013
a212e43f
MG
130142012-10-09 Marc Glisse <marc.glisse@inria.fr>
13015
13016 PR c++/54427
13017 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
13018 more operations. Make error messages optional.
13019 * c-common.h (enum stv_conv): Moved from c-typeck.c.
13020 (scalar_to_vector): Declare.
13021
b1db7f91
JM
130222012-10-08 Jason Merrill <jason@redhat.com>
13023
13024 * c-common.c (c_common_reswords): Add thread_local.
13025
e28d52cf
DS
130262012-10-08 Dodji Seketeli <dodji@redhat.com>
13027
13028 PR c++/53528 C++11 attribute support
13029 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
13030 new functions.
13031 * c-common.c (check_cxx_fundamental_alignment_constraints): New
13032 static function.
13033 (handle_aligned_attribute): In choose strictest alignment
13034 among many. Use new check_cxx_fundamental_alignment_constraints.
13035 (handle_transparent_union_attribute): In c++11 attribute syntax,
13036 don't look through typedefs.
13037
3b78de56
AC
130382012-10-04 Arnaud Charlet <charlet@adacore.com>
13039
13040 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
13041 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
13042 out of dumpfile.h.
13043
6040bb5f
DC
130442012-09-25 Dehao Chen <dehao@google.com>
13045
13046 PR middle-end/54645
3b78de56 13047 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
6040bb5f
DC
13048 map when read in the pch.
13049
3f8257db 130502012-09-18 Arnaud Charlet <charlet@adacore.com>
0b07a57e
AC
13051
13052 * c-ada-spec.c: Style fixes.
13053
3f8257db 130542012-09-18 Thomas Quinot <quinot@adacore.com>
da5182be
TQ
13055
13056 * c.opt (-fada-spec-parent): Define new command line switch.
13057 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
13058 is specified, generate binding spec as a child of the specified unit.
13059
0ccb505d
PC
130602012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
13061 Manuel López-Ibáñez <manu@gcc.gnu.org>
13062
13063 PR c++/53210
13064 * c.opt ([Winit-self]): Enabled by -Wall in C++.
13065
c583af79
AC
130662012-08-23 Arnaud Charlet <charlet@adacore.com>
13067
13068 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
13069 for pointers, and add missing Convention C pragma.
13070 (print_ada_struct_decl): Add missing aliased keyword.
13071 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
13072
1a4049e7
JJ
130732012-08-17 Jakub Jelinek <jakub@redhat.com>
13074
13075 * c-common.c (sizeof_pointer_memaccess_warning): New function.
13076 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
13077 * c-opts.c (c_common_handle_option): Enable it for -Wall.
13078 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
13079 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
13080
70b5e7dc
RG
130812012-08-10 Richard Guenther <rguenther@suse.de>
13082
13083 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
13084
f8923f7e
SB
130852012-08-07 Steven Bosscher <steven@gcc.gnu.org>
13086
13087 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
13088 instead of separate pp_newline and pp_flush.
13089 (print_c_tree): Likewise.
13090
e45abe1f
RH
130912012-07-26 Richard Henderson <rth@redhat.com>
13092
13093 * c-common.c (handle_hot_attribute): Allow labels.
13094 (handle_cold_attribute): Likewise.
13095
332f1d24
JJ
130962012-07-20 Jakub Jelinek <jakub@redhat.com>
13097
13098 PR c++/28656
13099 * c-common.c (check_function_nonnull): Handle multiple nonnull
13100 attributes properly.
13101
7ee2468b
SB
131022012-07-16 Steven Bosscher <steven@gcc.gnu.org>
13103
13104 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
13105 * c-ada-spec.c: Likewise.
13106 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
13107
ee7b28eb
SB
131082012-07-14 Steven Bosscher <steven@gcc.gnu.org>
13109
13110 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
13111 Remove code conditional on it.
13112
6bdf3519
SB
131132012-07-11 Steven Bosscher <steven@gcc.gnu.org>
13114
13115 * c-gimplify.c: Do not include basic-block.h.
13116 * c-common.c: Do not include linfuncs.h.
13117
532aafad
SB
131182012-07-08 Steven Bosscher <steven@gcc.gnu.org>
13119
13120 * c-common.h: Include tree.h.
13121
8d0d1915
JM
131222012-07-02 Jason Merrill <jason@redhat.com>
13123
13124 PR c++/53524
13125 * c-common.c (get_priority): Call default_conversion.
13126
fbc873ad
UB
131272012-07-01 Uros Bizjak <ubizjak@gmail.com>
13128
13129 * c-pch.c (c_common_write_pch): Remove unused variables.
13130
d4a10d0a
SB
131312012-06-29 Steven Bosscher <steven@gcc.gnu.org>
13132
13133 * cppspec.c: Moved from gcc/ to here.
13134
6f3a2e23
KT
131352012-06-27 Kai Tietz <ktietz@redhat.com>
13136
13137 PR preprocessor/37215
13138 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
13139
8ca92d04
SB
131402012-06-21 Steven Bosscher <steven@gcc.gnu.org>
13141
13142 * c-common.h (c_common_print_pch_checksum): Remove.
13143 * c-pch.c: Do not include output.h.
13144 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
13145 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
13146 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
13147 (struct c_pch_header): Remove.
13148 (get_ident): Update gpch version.
13149 (pch_init): Do not print executable_checksum to asm_out_file.
13150 Do not fail if there is no asm_out_file to read back from. Set
13151 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
13152 (c_common_write_pch): Verify that nothing was written to asm_out_file
13153 since pch_init was called. Do not write a c_pch_header, and do not
13154 copy from asm_out_file to the PCH.
13155 (c_common_read_pch): Do not read a c_pch_header, and do not restore
13156 the content of asm_out_file from the PCH.
13157 (c_common_print_pch_checksum): Remove.
13158 * c-opts.c (c_common_init): Print out executable_checksum directly.
13159
70f42967
SB
131602012-06-19 Steven Bosscher <steven@gcc.gnu.org>
13161
13162 * c-target.def (objc_declare_unresolved_class_reference,
13163 objc_declare_class_definition): Add new hooks.
13164
a8781821
SB
131652012-06-19 Steven Bosscher <steven@gcc.gnu.org>
13166
13167 * c-lex.c: Do not include output.h.
13168 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
13169 Remove uses of ASM_OUTPUT_IDENT.
13170
9e1a8dd1
RR
131712012-06-15 Marc Glisse <marc.glisse@inria.fr>
13172
13173 PR c++/51033
13174 * c-common.h (c_build_vec_perm_expr): Move decl here.
13175 * c-common.c (c_build_vec_perm_expr): Move definition
13176 here.
13177
6f07a821
SB
131782012-06-06 Steven Bosscher <steven@gcc.gnu.org>
13179
13180 * c.opt (fconserve-space): Turn into a no-op.
13181
9faeb493 131822012-06-04 Sterling Augustine <saugustine@google.com>
c265f413
SA
13183
13184 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
13185 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
13186 both the start and end of the function.
13187
a4b7d13c
SB
131882012-06-04 Steven Bosscher <steven@gcc.gnu.org>
13189
13190 * c-common.c: Do not include output.h.
13191 * c-pragma.c: Likewise.
13192
c265f413
SA
131932012-06-04 Steven Bosscher <steven@gcc.gnu.org>
13194
13195 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
13196 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
13197 (lang_decl_name): Handle namespace decls.
13198
be7a421e
SB
131992012-05-31 Steven Bosscher <steven@gcc.gnu.org>
13200
13201 * c-ada-spec.c: Do not include output.h.
13202 * c-semantics.c: Likewise.
13203
65de6659
JM
132042012-05-29 Joseph Myers <joseph@codesourcery.com>
13205
13206 * c-common.c: Fix typo.
13207
ca5f4331
MM
132082012-05-29 Michael Matz <matz@suse.de>
13209
13210 * c-common.h (c_expand_decl): Remove prototype.
13211
4f7f7aca
MLI
132122012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
13213
13214 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
13215 * c-opts.c (c_common_handle_option): Remove code handling
13216 warn_missing_braces.
13217
4a792f9b
PC
132182012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
13219
13220 PR c++/25137
13221 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
13222 -Wmissing_braces.
13223
650dc14a
DS
132242012-05-22 Dodji Seketeli <dodji@redhat.com>
13225
13226 PR c++/53322
13227 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
13228
9b095bf1
MLI
132292012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
13230
13231 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
13232 * c-opts.c (c_common_handle_option): Do not handle explicitly
13233 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
13234
0b2c4be5
DS
132352012-05-16 Dodji Seketeli <dodji@redhat.com>
13236
13237 PR preprocessor/7263
ab20d992 13238 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
0b2c4be5
DS
13239 to cpp_classify_number. For diagnostics, use the precise location
13240 instead of the global input_location.
13241
a1bde5af
PC
132422012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
13243
d02924ef 13244 PR c++/11856
a1bde5af
PC
13245 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
13246
d1ede5f4
BS
132472012-05-14 Bernd Schmidt <bernds@codesourcery.com>
13248
a1bde5af 13249 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
d1ede5f4 13250
f2bc201f
MLI
132512012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
13252
13253 PR 53063
13254 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
13255 Wreorder): Use LangEnabledBy.
13256 * c-opts.c (c_common_handle_option): Do not enable them
13257 explicitly. Call lang-specific generated functions.
13258 (c_common_post_options): Do not set them here.
13259
95744782
MLI
132602012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
13261
13262 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
13263 Wmissing-field-initializers,Wmissing-parameter-type,
13264 Wold-style-declaration,Woverride-init): Use EnabledBy.
13265 * c-opts.c (c_common_post_options): Do not set here explicitly.
13266
7d5a5747
MLI
132672012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
13268
13269 PR 53063
13270 * c-opts.c (c_common_handle_option): Use handle_generated_option
13271 to enable sub-options.
13272
5a3c9cf2
PC
132732012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
13274
13275 PR c++/53158
13276 * c-common.c (warnings_for_convert_and_check): Use warning_at.
13277
3ac8781c
RG
132782012-05-10 Richard Guenther <rguenther@suse.de>
13279
13280 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
13281 adjust commentary about TYPE_IS_SIZETYPE types.
13282
1e537948
MLI
132832012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
13284
13285 PR c++/53261
13286 * c-common.c (warn_logical_operator): Check that argument of
13287 integer_zerop is not NULL.
13288
f2c4a785
MLI
132892012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
13290
13291 PR c/43772
13292 * c-common.c (warn_logical_operator): Do not warn if either side
13293 is already true or false.
13294
50f305ca
MLI
132952012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
13296
13297 PR c/51712
13298 * c-common.c (expr_original_type): New.
13299 (shorten_compare): Do not warn for enumeration types.
13300
0c3641b0
MLI
133012012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
13302
13303 * c.opt (fpermissive): Add Var(flag_permissive).
13304
7edaa4d2
MG
133052012-04-30 Marc Glisse <marc.glisse@inria.fr>
13306
13307 PR c++/51033
13308 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
13309 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
13310
b9c8da34
DS
133112012-04-30 Dodji Seketeli <dodji@redhat.com>
13312
13313 Add -Wvarargs option
ab20d992 13314 * c.opt (Wvarargs): Define new option.
b9c8da34 13315
e6c69da0
MLI
133162012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
13317
13318 * c-common.c (check_function_arguments): Replace
13319 Wmissing-format-attribute with Wsuggest-attribute=format.
13320
90137d8f
MLI
133212012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
13322
13323 * c.opt (Wsuggest-attribute=format): New. Alias of
13324 Wmissing-format-attribute.
13325 * c-format.c (decode_format_type): Replace
13326 Wmissing-format-attribute with Wsuggest-attribute=format.
13327 (check_function_format): Likewise.
13328
9faeb493 133292012-04-27 Ollie Wild <aaw@google.com>
7f5f5f98
OW
13330
13331 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
13332 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
13333 * c.opt: Add Wliteral-suffix.
13334
c1771a20
MLI
133352012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
13336
13337 PR c/44774
13338 * c.opt (Wpedantic): New.
13339 (pedantic): Alias Wpedantic.
13340 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
13341 (c_common_post_options): Likewise.
13342 (sanitize_cpp_opts): Likewise.
13343 * c-lex.c (interpret_float): Likewise.
13344 * c-format.c (check_format_types): Likewise.
13345 * c-common.c (pointer_int_sum): Likewise.
13346 (c_sizeof_or_alignof_type): Likewise.
13347 (c_add_case_label): Likewise.
13348 (c_do_switch_warnings): Likewise.
13349 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
13350
04b391c1
JM
133512012-04-15 Jason Merrill <jason@redhat.com>
13352
13353 PR c++/52818
13354 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
13355 (C_STD_NAME): Distinguish between C++98 and C++11.
13356
ac868f29
EB
133572012-04-11 Eric Botcazou <ebotcazou@adacore.com>
13358
13359 PR target/52624
13360 * c-common.h (uint16_type_node): Rename into...
13361 (c_uint16_type_node): ...this.
13362 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
13363 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
13364
fd4116f4
MLI
133652012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
13366
13367 * c-common.c (warn_if_unused_value): Move definition to here.
13368 * c-common.h (warn_if_unused_value): Move declaration to here.
13369
573ac65e
WB
133702012-03-23 William Bader <williambader@hotmail.com>
13371
13372 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
13373
552b8185
JM
133742012-03-20 Jason Merrill <jason@redhat.com>
13375
13376 * c-common.h (enum cxx_dialect): Add cxx1y.
13377 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
13378 test.
13379 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
13380 * c-opts.c (c_common_post_options): Likewise.
13381 (set_std_cxx1y): New.
13382 (c_common_handle_option): Call it.
13383 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
13384
04398fa8
PC
133852012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
13386
13387 PR c++/14710
13388 * c.opt ([Wuseless-cast]): Add.
13389
d2a12ae7
RG
133902012-03-16 Richard Guenther <rguenther@suse.de>
13391
13392 * c-pretty-print.c (pp_c_initializer_list): Adjust.
13393
a12bf402
MLI
133942012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
13395
13396 PR c++/44783
13397 * c.opt (ftemplate-backtrace-limit) Add.
13398
5c30094f
RO
133992012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13400
13401 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
13402 handling.
13403 * c-pragma.c (handle_pragma_extern_prefix): Remove.
13404 (init_pragma): Don't register extern_prefix.
13405
21fa2faf
RG
134062012-03-12 Richard Guenther <rguenther@suse.de>
13407
13408 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
13409 (builtin_type_for_size): Likewise.
13410
e3793c6f
JJ
134112012-02-13 Jakub Jelinek <jakub@redhat.com>
13412
13413 PR c++/52215
13414 * c-common.c (sync_resolve_params): Don't decide whether to convert
13415 or not based on TYPE_SIZE comparison, convert whenever arg_type
13416 is unsigned INTEGER_TYPE.
13417
93286335
PC
134182012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
13419
13420 PR c/52118
13421 * c.opt ([Wunused-local-typedefs]): Fix description.
13422
7a421706
MS
134232012-01-24 Mike Stump <mikestump@comcast.net>
13424
13425 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
13426 exactly.
13427
ba9b1f11
RG
134282012-01-18 Richard Guenther <rguenther@suse.de>
13429
13430 * c-opts.c (c_common_post_options): Reset LTO flags if
13431 we are about to generate a PCH.
13432
465406be
PC
134332012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
13434
13435 PR c++/51777
13436 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
13437 use pp_unsigned_wide_integer.
13438
aee15221
RG
134392012-01-10 Richard Guenther <rguenther@suse.de>
13440
13441 PR middle-end/51806
13442 * c-opts.c (c_common_handle_option): Move -Werror handling
13443 to language independent code.
13444
5720c0dc
RG
134452012-01-05 Richard Guenther <rguenther@suse.de>
13446
13447 PR middle-end/51764
13448 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
13449 from common.opt.
13450
73ac190a
PC
134512011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
13452
13453 PR c++/51316
13454 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
13455 of array types with an unknown bound.
13456
48b0b196
JM
134572011-12-20 Joseph Myers <joseph@codesourcery.com>
13458
13459 * c-common.c (flag_isoc99): Update comment to refer to C11.
13460 (flag_isoc1x): Change to flag_isoc11.
13461 * c-common.h (flag_isoc99): Update comment to refer to C11.
13462 (flag_isoc1x): Change to flag_isoc11.
13463 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
13464 C11.
13465 * c-opts.c (set_std_c1x): Change to set_std_c11.
13466 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
13467 Call set_std_c11.
13468 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
13469 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
13470 * c.opt (std=c1x): Change to std=c11. Document as non-draft
13471 standard.
13472 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
13473 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
13474 (std=gnu1x): Make alias of std=gnu11.
13475
d58d6eb5
JM
134762011-12-19 Jason Merrill <jason@redhat.com>
13477
13478 PR c++/51228
13479 * c-common.c (handle_transparent_union_attribute): Check the first
13480 field if the type is complete.
13481
b3908fcc
JW
134822011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
13483
13484 PR libstdc++/51365
13485 * c-common.c (RID_IS_FINAL): Add.
13486 * c-common.h (RID_IS_FINAL): Add.
13487
fea3ca91
IS
134882011-11-30 Iain Sandoe <iains@gcc.gnu.org>
13489
13490 * c.opt (fgnu-runtime): Provide full description.
13491 (fnext-runtime): Likewise.
13492 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
13493
62bad7cd
AM
134942011-11-28 Andrew MacLeod <amacleod@redhat.com>
13495
13496 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
13497 predefines in one place. Add LOCK_FREE predefines.
13498 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
13499 new func.
13500
c466c4ff
AM
135012011-11-24 Andrew MacLeod <amacleod@redhat.com>
13502
13503 PR c/51256
9faeb493 13504 * c-common.c (get_atomic_generic_size): Check for various error
c466c4ff 13505 conditions
9faeb493
UB
13506 (resolve_overloaded_atomic_exchange,
13507 resolve_overloaded_atomic_compare_exchange,
c466c4ff
AM
13508 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
13509 error_mark_node for error conditions.
9faeb493 13510
a5952633
RG
135112011-11-08 Richard Guenther <rguenther@suse.de>
13512
13513 PR middle-end/51010
ab20d992 13514 * c-pretty-print.c (pp_c_expression): Handle SSA_NAMEs.
a5952633 13515
0a35513e
AH
135162011-11-07 Richard Henderson <rth@redhat.com>
13517 Aldy Hernandez <aldyh@redhat.com>
13518 Torvald Riegel <triegel@redhat.com>
13519
13520 Merged from transactional-memory.
13521
13522 * c-common.c (handle_tm_wrap_attribute,
13523 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
13524 (struct c_common_reswords): Added __transaction* keywords.
13525 (struct c_common_attribute_table): Added transaction* and tm_regparm
13526 attributes.
13527 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
13528 masks.
13529 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
13530 find_tm_attribute): Declare.
13531
6d87092d
JM
135322011-11-07 Jason Merrill <jason@redhat.com>
13533
13534 PR c++/35688
13535 * c-common.c, c-common.h: Revert yesterday's changes.
13536
8e7860a1
JM
135372011-11-06 Jason Merrill <jason@redhat.com>
13538
13539 PR c++/35688
13540 * c-common.c (decl_has_visibility_attr): Split out from...
13541 (c_determine_visibility): ...here.
13542 * c-common.h: Declare it.
13543
d19fa6b5
JM
135442011-11-06 Joseph Myers <joseph@codesourcery.com>
13545
13546 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
13547 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
13548 type.
13549 (check_user_alignment): New. Split out of
13550 handle_aligned_attribute. Disallow integer constants with
13551 noninteger types. Conditionally allow zero.
13552 (handle_aligned_attribute): Use check_user_alignment.
13553 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
13554
86951993
AM
135552011-11-06 Andrew MacLeod <amacleod@redhat.com>
13556 Richard Henderson <rth@redhat.com>
13557
13558 Merged from cxx-mem-model.
13559
13560 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
9faeb493 13561 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
86951993
AM
13562 parameters that are the same type size.
13563 (get_atomic_generic_size): New. Find size of generic
13564 atomic function parameters and do typechecking.
13565 (add_atomic_size_parameter): New. Insert size into parameter list.
13566 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
13567 either __atomic_exchange_n or external library call.
9faeb493 13568 (resolve_overloaded_atomic_compare_exchange): Restructure
86951993 13569 __atomic_compare_exchange to either _n variant or external library call.
9faeb493 13570 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
86951993
AM
13571 __atomic_load_n or an external library call.
13572 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
13573 __atomic_store_n or an external library call.
13574 (resolve_overloaded_builtin): Handle new __atomic builtins.
13575
cf9e9959
EB
135762011-11-04 Eric Botcazou <ebotcazou@adacore.com>
13577
13578 PR c++/50608
13579 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
13580 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
13581 <INDIRECT_REF>: Return the argument.
13582 <ARRAY_REF>: Remove special code for negative offset.
13583 Call fold_build_pointer_plus instead of size_binop.
13584 (fold_offsetof): Remove STOP_REF argument and adjust.
13585 * c-common.h (fold_offsetof_1): Declare.
13586 (fold_offsetof): Remove STOP_REF argument.
13587
25339f10
JM
135882011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
13589
13590 PR c++/50810
13591 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
13592 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
13593 Wnarrowing for C++0x and C++98.
13594 * c.opt ([Wnarrowing]): Update.
13595
89401152
PC
135962011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
13597
13598 PR c++/44277
13599 * c.opt: Add Wzero-as-null-pointer-constant.
13600
97e3ad20
JM
136012011-10-31 Jason Merrill <jason@redhat.com>
13602
15694fdd
JM
13603 * c.opt (-fdeduce-init-list): Off by default.
13604
97e3ad20
JM
13605 PR c++/50920
13606 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
13607 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
13608 and -Wc++11-compat.
13609 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
13610
fb9120e3
RAV
136112011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
13612
13613 PR c++/30066
13614 * c.opt (fvisibility-inlines-hidden): Description change.
13615
3ce4f9e4
ESR
136162011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
13617
13618 Implement C++11 user-defined literals.
13619 * c-common.c (build_userdef_literal): New.
13620 * c-common.def: New tree code.
13621 * c-common.h (tree_userdef_literal): New tree struct and accessors.
13622 * c-lex.c (interpret_float): Add suffix parm.
13623 (c_lex_with_flags): Build literal tokens.
13624
5f53c243
PC
136252011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
13626
13627 PR c++/50841
13628 Revert:
13629 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
13630
13631 PR c++/50810
13632 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
13633 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
13634 Wnarrowing for C++0x and C++98.
13635 * c.opt ([Wnarrowing]): Update.
13636
263734e1
PC
136372011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
13638
13639 PR c++/50810
13640 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
13641 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
13642 Wnarrowing for C++0x and C++98.
13643 * c.opt ([Wnarrowing]): Update.
13644
d2e312d7
PC
136452011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
13646
13647 PR c++/45385
13648 * c-common.c (conversion_warning): Remove code looking for
13649 artificial operands.
13650
d17687f6
DS
136512011-10-18 Dodji Seketeli <dodji@redhat.com>
13652
13653 PR bootstrap/50760
13654 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
9faeb493 13655 !NO_IMPLICIT_EXTERN_C.
d17687f6 13656
fc8396e9
PC
136572011-10-17 Michael Spertus <mike_spertus@symantec.com>
13658
13659 * c-common.c (c_common_reswords): Add __bases,
13660 __direct_bases.
13661 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
13662
136632011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
13664
13665 PR c++/50757
13666 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
13667
847e697a
TT
136682011-10-15 Tom Tromey <tromey@redhat.com>
13669 Dodji Seketeli <dodji@redhat.com>
13670
13671 * c.opt (fdebug-cpp): New option.
13672 * c-opts.c (c_common_handle_option): Handle the option.
13673 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
13674 output stream in parameter. Factorized from ...
13675 (maybe_print_line): ... this. Dump location debug information when
13676 -fdebug-cpp is in effect.
13677 (print_line_1): New static function. Takes an output stream in
13678 parameter. Factorized from ...
13679 (print_line): ... here. Dump location information when -fdebug-cpp
13680 is in effect.
13681 (scan_translation_unit): Dump location information when
13682 -fdebug-cpp is in effect.
13683
92582b75
TT
136842011-10-15 Tom Tromey <tromey@redhat.com>
13685 Dodji Seketeli <dodji@redhat.com>
13686
13687 * c.opt (ftrack-macro-expansion): New option. Handle it with and
13688 without argument.
13689 * c-opts.c (c_common_handle_option)<case
13690 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
13691 cases. Handle -ftrack-macro-expansion with and without argument.
13692
46427374
TT
136932011-10-15 Tom Tromey <tromey@redhat.com>
13694 Dodji Seketeli <dodji@redhat.com>
13695
13696 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
13697 (print_line, cb_define, do_line_change): Adjust to avoid touching
13698 the internals of struct line_map. Use the public API instead.
13699 * c-pch.c (c_common_read_pch): Likewise.
13700 * c-lex.c (fe_file_change): Likewise.
13701
fc8396e9
PC
137022011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
13703
13704 PR c++/17212
13705 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
13706
137072011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
13708
13709 PR c++/33067
13710 * c-pretty-print.c (pp_c_floating_constant): Output
13711 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
13712
e79983f4
MM
137132011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
13714
13715 * c-common.c (def_builtin_1): Delete old interface with two
13716 parallel arrays to hold standard builtin declarations, and replace
13717 it with a function based interface that can support creating
13718 builtins on the fly in the future. Change all uses, and poison
13719 the old names. Make sure 0 is not a legitimate builtin index.
13720 * c-omp.c (c_finish_omp_barrier): Ditto.
13721 (c_finish_omp_taskwait): Ditto.
13722 (c_finish_omp_flush): Ditto.
13723
6637388f
TG
137242011-10-11 Tristan Gingold <gingold@adacore.com>
13725
13726 * c.opt: (fallow-parameterless-variadic-functions): New.
13727
3797cb21
DS
137282011-09-08 Dodji Seketeli <dodji@redhat.com>
13729
13730 PR c++/33255 - Support -Wunused-local-typedefs warning
13731 * c-common.h (struct c_language_function::local_typedefs): New
13732 field.
9faeb493
UB
13733 (record_locally_defined_typedef, maybe_record_typedef_use)
13734 (maybe_warn_unused_local_typedefs): Declare new functions.
3797cb21 13735 * c-common.c (record_locally_defined_typedef)
9faeb493
UB
13736 (maybe_record_typedef_use)
13737 (maybe_warn_unused_local_typedefs): Define new functions.
3797cb21
DS
13738 * c.opt: Declare new -Wunused-local-typedefs flag.
13739
693ddb1b
EB
137402011-09-06 Eric Botcazou <ebotcazou@adacore.com>
13741
13742 PR middle-end/50266
13743 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
13744 computations.
13745
830c740f
RG
137462011-09-05 Richard Guenther <rguenther@suse.de>
13747
13748 * c-common.c (complete_array_type): Use ssize_int (-1) instead
13749 of integer_minus_one_node for empty array upper bounds.
13750
892a371f
DS
137512011-08-28 Dodji Seketeli <dodji@redhat.com>
13752
13753 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
13754 it's the first time it's being called on this main TU.
13755
0e3fdb48
RB
137562011-08-24 Richard Guenther <rguenther@suse.de>
13757
13758 PR c/49396
13759 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
13760
137612011-08-22 Gabriel Charette <gchare@google.com>
e3dfef44
GC
13762
13763 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
13764 defined in cpp_init_builtins and c_cpp_builtins.
13765
d4a83c10
JM
137662011-08-19 Joseph Myers <joseph@codesourcery.com>
13767
13768 * c-common.c (c_common_reswords): Add __builtin_complex.
13769 * c-common.h (RID_BUILTIN_COMPLEX): New.
13770
bbceee64
JM
137712011-08-18 Joseph Myers <joseph@codesourcery.com>
13772
13773 * c-common.c (c_common_reswords): Add _Noreturn.
13774 (keyword_is_function_specifier): Handle RID_NORETURN.
13775 * c-common.h (RID_NORETURN): New.
13776
3f8257db 137772011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
0e3a99ae
AS
13778
13779 * c-common.c (unsafe_conversion_p): New function. Check if it is
13780 unsafe to convert an expression to the type.
13781 (conversion_warning): Adjust, use unsafe_conversion_p.
13782 * c-common.h (unsafe_conversion_p): New function declaration.
13783
20906c66
JJ
137842011-08-02 Jakub Jelinek <jakub@redhat.com>
13785
13786 * c-common.h (c_finish_omp_atomic): Adjust prototype.
13787 (c_finish_omp_taskyield): New prototype.
13788 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
13789 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
13790 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
13791 or RHS1 have side-effects, evaluate those too in the right spot,
13792 if it is a decl and LHS is also a decl, error out if they
13793 aren't the same.
13794 (c_finish_omp_taskyield): New function.
13795 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
13796 * c-pragma.c (omp_pragmas): Add taskyield.
13797 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
13798 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
13799 PRAGMA_OMP_CLAUSE_MERGEABLE.
13800
770e5a2e
DS
138012011-07-25 Dodji Seketeli <dodji@redhat.com>
13802
13803 * c-common.h (set_underlying_type): Remove parm name from
13804 declaration.
13805
1baae426
RG
138062011-07-25 Romain Geissler <romain.geissler@gmail.com>
13807
13808 * c-pretty-print.h: Search c-common.h in c-family.
9faeb493 13809
fcb21722
JM
138102011-07-22 Jason Merrill <jason@redhat.com>
13811
76f86d00
JM
13812 PR c++/49793
13813 * c.opt (Wnarrowing): New.
13814
3a636414
JM
13815 PR c++/30112
13816 * c-common.h: Declare c_linkage_bindings.
13817 * c-pragma.c (handle_pragma_redefine_extname): Use it.
13818
fcb21722
JM
13819 PR c++/49813
13820 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
13821 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
13822 as flag_isoc99 for 'restrict'.
13823 (pp_c_specifier_qualifier_list): Likewise for _Complex.
13824
02614448
ILT
138252011-07-21 Ian Lance Taylor <iant@google.com>
13826
13827 PR middle-end/49705
13828 * c-common.c (c_disable_warnings): New static function.
13829 (c_enable_warnings): New static function.
13830 (c_fully_fold_internal): Change local unused_p to bool. Call
13831 c_disable_warnings and c_enable_warnings rather than change
13832 c_inhibit_evaluation_warnings.
13833
34429675
JM
138342011-07-20 Jason Merrill <jason@redhat.com>
13835
13836 PR c++/6709 (DR 743)
13837 PR c++/42603 (DR 950)
13838 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
13839 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
13840 (CPP_DECLTYPE): New.
13841 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
13842
5d49b6a7
RG
138432011-07-19 Richard Guenther <rguenther@suse.de>
13844
13845 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
13846 * c-omp.c (c_finish_omp_for): Likewise.
13847
e84a58ff
EB
138482011-07-12 Eric Botcazou <ebotcazou@adacore.com>
13849
13850 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
13851 body on the next line.
13852
329af3c7
JM
138532011-07-08 Jason Merrill <jason@redhat.com>
13854
4063e61b
JM
13855 PR c++/45437
13856 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
13857
329af3c7
JM
13858 PR c++/49673
13859 * c-common.c (c_apply_type_quals_to_decl): Don't check
13860 TYPE_NEEDS_CONSTRUCTING.
13861
1a072294
RG
138622011-07-06 Richard Guenther <rguenther@suse.de>
13863
13864 * c-common.c (c_common_nodes_and_builtins):
13865 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
13866
fce5dddd
RG
138672011-07-05 Richard Guenther <rguenther@suse.de>
13868
13869 * c-common.c (c_common_nodes_and_builtins): Build all common
13870 tree nodes first.
13871
45d439ac
JJ
138722011-06-27 Jakub Jelinek <jakub@redhat.com>
13873
56300785
JJ
13874 * c-common.h (c_tree_chain_next): New static inline function.
13875
45d439ac
JJ
13876 * c-common.c (check_builtin_function_arguments): Handle
13877 BUILT_IN_ASSUME_ALIGNED.
13878
e0a8ecf2
AM
138792011-06-21 Andrew MacLeod <amacleod@redhat.com>
13880
13881 * c-common.c: Add sync_ or SYNC__ to builtin names.
13882 * c-omp.c: Add sync_ or SYNC__ to builtin names.
dfb43cd5
PV
13883
138842011-06-20 Pierre Vittet <piervit@pvittet.com>
13885
13886 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
13887 handler.
13888 (gen_pragma_handler): New union.
13889 (internal_pragma_handler): New type.
13890 (c_register_pragma_with_data)
13891 (c_register_pragma_with_expansion_and_data): New functions.
13892
13893 * c-pragma.c (registered_pragmas, c_register_pragma_1)
13894 (c_register_pragma, c_register_pragma_with_expansion)
13895 (c_invoke_pragma_handler): Changed to work with
13896 internal_pragma_handler.
13897 (c_register_pragma_with_data)
13898 (c_register_pragma_with_expansion_and_data): New functions.
13899
677f3fa8
JM
139002011-06-14 Joseph Myers <joseph@codesourcery.com>
13901
13902 * c-common.c: Include common/common-target.h.
13903 (handle_section_attribute): Use
13904 targetm_common.have_named_sections.
13905 * c-cppbuiltin.c: Include common/common-target.h.
13906 (c_cpp_builtins): Use targetm_common.except_unwind_info.
13907
d7fc8c14
RG
139082011-06-10 Richard Guenther <rguenther@suse.de>
13909
13910 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
13911 to print a IDENTIFIER_NODE.
13912
10e48e39
RO
139132011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13914 Joseph Myers <joseph@codesourcery.com>
13915
13916 * c.opt (fbuilding-libgcc): New option.
13917 * c-cppbuiltin.c (c_cpp_builtins): Define
13918 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
13919
6976ae51
JM
139202011-06-07 Jason Merrill <jason@redhat.com>
13921
3ff60975
JM
13922 * c-common.c (max_tinst_depth): Lower default to 900.
13923
6976ae51
JM
13924 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
13925
009db074
RG
139262011-06-07 Richard Guenther <rguenther@suse.de>
13927
13928 * c-common.c (c_common_nodes_and_builtins): Do not set
13929 size_type_node or call set_sizetype.
13930
b4592b92
DS
139312011-06-07 Dodji Seketeli <dodji@redhat.com>
13932
13933 PR debug/49130
13934 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
9faeb493 13935 type when using pointer comparison to compare types.
b4592b92 13936
014ab419
JW
139372011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
13938
13939 * c.opt: Add -Wdelete-non-virtual-dtor.
13940 * c-opts.c (c_common_handle_option): Include it in -Wall.
13941
4f60111f
NF
139422011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
13943
13944 PR bootstrap/49190
13945
13946 Revert:
13947 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
13948
13949 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
13950 not tree_common.
13951
4cc4f2f4
JJ
139522011-05-27 Jakub Jelinek <jakub@redhat.com>
13953
13954 PR c++/49165
13955 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
13956 C++ don't call c_common_truthvalue_conversion on void type arms.
13957
38e01f9e
NF
139582011-05-27 Nathan Froyd <froydnj@codesourcery.com>
13959
13960 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
13961 (stmt_list_stack): Define.
13962 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
13963 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
13964
92e948a8
NF
139652011-05-26 Nathan Froyd <froydnj@codesourcery.com>
13966
13967 * c-common.c (warning_candidate_p): Check for BLOCKs.
13968
a2fc3e63
NF
139692011-05-26 Nathan Froyd <froydnj@codesourcery.com>
13970
13971 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
13972 not tree_common.
13973
0957c029
JJ
139742011-05-25 Jakub Jelinek <jakub@redhat.com>
13975
13976 * c-common.c (def_fn_type): Remove extra va_end.
13977
828fb3ba
JM
139782011-05-23 Jason Merrill <jason@redhat.com>
13979
13980 PR c++/48106
13981 * c-common.c (c_common_get_narrower): New.
13982 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
13983
dde05067
NF
139842011-05-23 Nathan Froyd <froydnj@codesourcery.com>
13985
13986 * c-common.h (check_function_arguments): Tweak prototype of
13987 check_function_arguments.
13988 * c-common.c (check_function_arguments): Likewise. Adjust
13989 calls to check_function_nonnull, check_function_format, and
13990 check_function_sentinel.
13991 (check_function_sentinel): Take a FUNCTION_TYPE rather than
13992 separate attributes and typelist arguments. Use
13993 FOREACH_FUNCTION_ARGS to iterate over argument types.
13994
3c0d13bf
PC
139952011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
13996
13997 * c-common.c (c_common_reswords): Reorder.
13998 * c-common.h (rid): Likewise.
13999
8242dd04
NF
140002011-05-10 Nathan Froyd <froydnj@codesourcery.com>
14001
14002 * c-common.c (def_fn_type): Don't call build_function_type, call
14003 build_function_type_array or build_varargs_function_type_array
14004 instead.
14005 (c_common_nodes_and_builtins): Likewise.
14006
3d528853
NF
140072011-05-05 Nathan Froyd <froydnj@codesourcery.com>
14008
14009 * c-common.c (c_add_case_label): Omit the loc argument to
14010 build_case_label.
14011 * c-common.h (build_case_label): Remove.
14012 * c-semantics.c (build_case_label): Remove.
14013
a04a722b
JM
140142011-05-05 Joseph Myers <joseph@codesourcery.com>
14015
14016 * c-objc.h (objc_start_method_definition): Update prototype.
14017 * stub-objc.c (objc_start_method_definition): Add extra parameter.
14018
e19a18d4
NF
140192011-05-04 Nathan Froyd <froydnj@codesourcery.com>
14020
14021 * c-common.c (check_main_parameter_types): Reindent. Don't use
14022 TYPE_ARG_TYPES directly.
14023 (handle_nonnull_attribute): Likewise.
14024 (sync_resolve_params): Likewise.
14025 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
14026 to check_format_string.
14027 (handle_format_attribute): Likewise.
14028 (check_format_string): Take a function type to examine instead of
14029 a type list. Use a function_arg_iterator to step through argument
14030 types.
14031
c62c040f
RG
140322011-05-04 Richard Guenther <rguenther@suse.de>
14033
14034 * c-common.c (fix_string_type): Use size_int for index type bounds.
14035 (start_fname_decls): Do not pass NULL to build_int_cst.
14036 (c_init_attributes): Likewise.
14037 * c-lex.c (c_lex_with_flags): Likewise.
14038
c12ff9d8
JM
140392011-04-27 Jason Merrill <jason@redhat.com>
14040
14041 * c-common.c (make_tree_vector_from_list): New.
14042 * c-common.h: Declare it.
14043
304dfbe3
RG
140442011-04-26 Richard Guenther <rguenther@suse.de>
14045
14046 PR preprocessor/48248
14047 * c-ppoutput.c (maybe_print_line): Always optimize newlines
14048 for output size with -P.
14049
3c0d13bf
PC
140502011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
14051
14052 * c-common.c (struct c_common_resword): Add __underlying_type.
14053 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
14054
04695783
JM
140552011-04-20 Jim Meyering <meyering@redhat.com>
14056
14057 * c-format.c (init_dollar_format_checking): Remove useless
14058 if-before-free.
14059
0dc33c3c
NP
140602011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
14061
14062 * c-objc.h (objc_get_interface_ivars): Removed.
3c0d13bf 14063 (objc_detect_field_duplicates): New.
0dc33c3c 14064 * stub-objc.c: Likewise.
3c0d13bf 14065
c59633d9
NP
140662011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
14067
14068 * stub-objc.c (objc_declare_protocols): Renamed to
14069 objc_declare_protocol.
14070 * c-objc.h: Likewise.
3c0d13bf 14071
32dabdaf
NP
140722011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
14073
14074 * stub-objc.c (objc_declare_class): Updated argument name.
14075
81f653d6
NF
140762011-04-12 Nathan Froyd <froydnj@codesourcery.com>
14077
14078 * c-common.h (c_common_init_ts): Declare.
14079 * c-common.c (c_common_init_ts): Define.
14080
eb345401
NP
140812011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
14082
14083 * c-objc.h (objc_build_message_expr): Updated prototype.
14084 * stub-objc.c (objc_build_message_expr): Likewise.
9faeb493 14085
a358e188
MJ
140862011-04-12 Martin Jambor <mjambor@suse.cz>
14087
14088 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
14089 of cgraph_node.
14090
e6313a78
RG
140912011-04-11 Richard Guenther <rguenther@suse.de>
14092
14093 * c-common.c (complete_array_type): Build a range type of
14094 proper type.
14095
dcf0c47e
NF
140962011-04-08 Nathan Froyd <froydnj@codesourcery.com>
14097
14098 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
14099 (handle_type_generic_attribute): Likewise.
14100
1ee44b26
JM
141012011-04-07 Jason Merrill <jason@redhat.com>
14102
14103 PR c++/48450
14104 * c-common.c (c_common_truthvalue_conversion): Don't ignore
14105 conversion from C++0x scoped enum.
14106
acce4e77
JM
141072011-04-06 Joseph Myers <joseph@codesourcery.com>
14108
14109 * c-target-def.h: New file.
14110 * c-target.def: New file.
14111 * c-target.h: New file.
14112 * c-common.c (targetcm): Don't define here.
14113 * c-common.h (default_handle_c_option): Declare.
14114 * c-format.c: Include c-target.h instead of target.h.
14115 * c-opts.c: Include c-target.h instead of target.h. Explicitly
14116 include tm.h.
14117 (default_handle_c_option): Move from targhooks.c.
14118
e2eefb55
JJ
141192011-03-29 Jakub Jelinek <jakub@redhat.com>
14120
14121 PR preprocessor/48248
14122 * c-ppoutput.c (print): Add src_file field.
14123 (init_pp_output): Initialize it.
14124 (maybe_print_line): Don't optimize by adding up to 8 newlines
14125 if map->to_file and print.src_file are different file.
14126 (print_line): Update print.src_file.
14127
ba78087b
KT
141282011-03-25 Kai Tietz <ktietz@redhat.com>
14129
14130 * c-ada-spec.c (compare_comment): Use filename_cmp
14131 instead of strcmp for filename.
14132
0edf1bb2
JL
141332011-03-25 Jeff Law <law@redhat.com>
14134
adfac8df 14135 * c-common.c (def_fn_type): Add missing va_end.
0edf1bb2 14136
c7dc8804
JM
141372011-03-25 Jason Merrill <jason@redhat.com>
14138
14139 * c.opt: Add -std=c++03.
14140
d1d879b1
EB
141412011-03-22 Eric Botcazou <ebotcazou@adacore.com>
14142
14143 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
14144
3f8257db 141452011-03-17 Kai Tietz <ktietz@redhat.com>
62d784f7
KT
14146
14147 PR target/12171
5050afdf
KT
14148 * c-pretty-print.c (pp_c_specifier_qualifier_list):
14149 Display allowed attributes for function pointer types.
14150 (pp_c_attributes_display): New function to display
14151 attributes having affects_type_identity flag set to true.
14152 * c-pretty-print.h (pp_c_attributes_display): New prototype.
14153
62d784f7
KT
14154 * c-common.c (c_common_attribute_table):
14155 Add new element.
14156 (c_common_format_attribute_table): Likewise.
14157
82d37118
JM
141582011-03-18 Jason Merrill <jason@redhat.com>
14159
49a000c3
JM
14160 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
14161 * c-common.h: Don't declare it here.
14162 * c-common.c: Or define it here.
14163 * c-opts.c (c_common_handle_option): Or set it here.
14164
82d37118
JM
14165 PR c++/35315
14166 * c-common.c (handle_transparent_union_attribute): Don't
14167 make a duplicate type in C++.
14168
17bc631c
JM
141692011-03-15 Jason Merrill <jason@redhat.com>
14170
14171 * c-common.c (max_constexpr_depth): New.
14172 * c-common.h: Declare it.
14173 * c-opts.c (c_common_handle_option): Set it.
14174 * c.opt (fconstexpr-depth): New option.
14175
1b9b91a6
JM
141762011-03-11 Jason Merrill <jason@redhat.com>
14177
f231b5ff
JM
14178 * c-common.c (attribute_takes_identifier_p): Add missing const.
14179
1b9b91a6
JM
14180 PR c++/46803
14181 * c-common.c (attribute_takes_identifier_p): Assume that an
14182 unknown attribute takes an identifier.
14183
a19e4d44
NF
141842011-03-07 Nathan Froyd <froydnj@codesourcery.com>
14185
14186 PR c/47786
14187 * c-common.c (c_type_hash): Call list_length instead of iterating
14188 through DECL_CHAIN. Rename 'i' to 'n_elements'.
14189
982d62f6
JJ
141902011-02-19 Jakub Jelinek <jakub@redhat.com>
14191
14192 PR c/47809
14193 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
14194
0a256240
NP
141952011-02-17 Iain Sandoe <iains@gcc.gnu.org>
14196
14197 * c.opt (fobjc-abi-version=) New.
14198 (fobjc-nilcheck): New.
14199
ba9e6dd5
NF
142002011-02-03 Nathan Froyd <froydnj@codesourcery.com>
14201
14202 PR c++/46890
14203 * c-common.h (keyword_is_decl_specifier): Declare.
14204 * c-common.c (keyword_is_decl_specifier): Define.
14205 (keyword_is_function_specifier): New function.
14206
7273813a
JJ
142072011-01-26 Jakub Jelinek <jakub@redhat.com>
14208
14209 PR c/47473
14210 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
14211 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
14212 REAL_TYPE.
14213
908ef79b
AC
142142011-01-26 Arnaud Charlet <charlet@adacore.com>
14215
14216 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
14217
237e9384
JJ
142182011-01-26 Jakub Jelinek <jakub@redhat.com>
14219
14220 PR pch/47430
14221 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
14222 after init_c_lex if pch_file is set.
14223
47ea1edf
DK
142242011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
14225
d4dba752 14226 PR c++/43601
47ea1edf
DK
14227 * c.opt (-fkeep-inline-dllexport): New switch.
14228
2aa9c6ae
RG
142292011-01-12 Richard Guenther <rguenther@suse.de>
14230
14231 PR middle-end/32511
14232 * c-common.c (handle_weak_attribute): Warn instead of error
14233 on declaring an inline function weak.
14234
7bd11157
TT
142352011-01-05 Tom Tromey <tromey@redhat.com>
14236
14237 * c-common.h (lvalue_error): Update.
14238 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
14239 not error.
14240
0e66e494 142412010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
9faeb493 14242
b4f588c4
NP
14243 PR objc/47075
14244 * c-objc.h (objc_finish_message_expr): Added argument to
14245 prototype.
14246
f4da8dce
NF
142472010-12-22 Nathan Froyd <froydnj@codesourcery.com>
14248
14249 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
14250 Use prototype_p.
14251
46270f14
NP
142522010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
14253
14254 * c-objc.h (objc_maybe_warn_exceptions): New.
9faeb493 14255 * stub-objc.c (objc_maybe_warn_exceptions): New.
46270f14 14256
4816c593
NF
142572010-12-10 Nathan Froyd <froydnj@codesourcery.com>
14258
14259 * c-common.h (readonly_error): Declare.
14260 * c-common.c (readonly_error): Define.
14261
7a6daeb0
NF
142622010-12-09 Nathan Froyd <froydnj@codesourcery.com>
14263
14264 * c-common.h (invalid_indirection_error): Declare.
14265 * c-common.c (invalid_indirection_error): Define.
14266
892f6119
RG
142672010-12-03 Richard Guenther <rguenther@suse.de>
14268
14269 PR c/46745
14270 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
14271 (pp_c_unary_expression): Likewise.
14272 (pp_c_expression): Likewise.
14273
6c39e757
NP
142742010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
14275
14276 * c-common.h (objc_finish_function): New.
14277 (objc_non_volatilized_type): Removed.
14278 (objc_type_quals_match): Removed.
14279 * stub-objc.c (objc_finish_function): New.
14280 (objc_non_volatilized_type): Removed.
14281 (objc_type_quals_match): Removed.
9faeb493 14282
7c475d11
JM
142832010-11-30 Joseph Myers <joseph@codesourcery.com>
14284
14285 * c-common.h (parse_optimize_options): Declare.
14286 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
14287 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
14288
71f3e391
JM
142892010-11-29 Joseph Myers <joseph@codesourcery.com>
14290
14291 * c-opts.c (check_deps_environment_vars): Use getenv instead of
14292 GET_ENVIRONMENT.
14293 * c-pch.c (O_BINARY): Don't define here.
14294 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
14295
d5fabb58
JM
142962010-11-25 Joseph Myers <joseph@codesourcery.com>
14297
14298 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
14299 targetm.except_unwind_info.
14300
299404a1
JM
143012010-11-23 Joseph Myers <joseph@codesourcery.com>
14302
14303 * c-opts.c (c_common_handle_option): Pass location to
14304 set_struct_debug_option.
14305
c98cd5bf
JM
143062010-11-23 Joseph Myers <joseph@codesourcery.com>
14307
14308 * c-common.c (visibility_options): Move from ../opts.c.
14309 * c-common.h (struct visibility_flags, visibility_options):
14310 Declare here.
14311 * c-opts.c (finish_options): Rename to c_finish_options.
14312 (c_common_init): Update call to finish_options.
14313
a9546771
NP
143142010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
14315
14316 PR objc/34033
14317 * c-lex.c (lex_string): Check that each string in an Objective-C
14318 string concat sequence starts with either one or zero '@', and
14319 that there are no spurious '@' signs at the end.
14320
24a57808
JM
143212010-11-20 Joseph Myers <joseph@codesourcery.com>
14322
14323 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
14324 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
14325 HANDLE_PRAGMA_VISIBILITY.
14326 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
14327 HANDLE_PRAGMA_VISIBILITY): Don't define.
14328 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
14329
a9aa2c3a
NF
143302010-11-20 Nathan Froyd <froydnj@codesourcery.com>
14331
14332 PR c++/16189
14333 PR c++/36888
14334 PR c++/45331
14335 * c-common.h (keyword_begins_type_specifier): Declare.
14336 (keyword_is_storage_class_specifier): Declare.
14337 (keyword_is_type_qualifier): Declare.
14338 * c-common.c (keyword_begins_type_specifier): New function.
14339 (keyword_is_storage_class_specifier): New function.
14340 (keyword_is_type_qualifier): Declare.
14341
5386338c
JM
143422010-11-19 Joseph Myers <joseph@codesourcery.com>
14343
14344 PR c/46547
14345 * c-common.c (in_late_binary_op): Define.
14346 (c_common_truthvalue_conversion): Check in_late_binary_op before
14347 calling c_save_expr.
14348 * c-common.h (in_late_binary_op): Declare.
14349
69ccdddb
JM
143502010-11-19 Joseph Myers <joseph@codesourcery.com>
14351
14352 * c-opts.c (c_common_handle_option): Update calls to
14353 set_struct_debug_option.
14354
6b192a09
NP
143552010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
14356
14357 * c-common.h (objc_declare_protocols): Added additional argument.
14358 * stub-objc.c (objc_declare_protocol): Same change.
9faeb493 14359
fb52b50a
NF
143602010-11-18 Nathan Froyd <froydnj@codesourcery.com>
14361
14362 PR c/33193
14363 * c-common.h (build_real_imag_expr): Declare.
14364 * c-semantics.c (build_real_imag_expr): Define.
14365
b37421c6
JM
143662010-11-17 Joseph Myers <joseph@codesourcery.com>
14367
14368 * c-opts.c (c_common_parse_file): Take no arguments.
14369 * c-common.h (c_common_parse_file): Update prototype.
14370
07078664
JJ
143712010-11-16 Jakub Jelinek <jakub@redhat.com>
14372
14373 PR c++/46401
14374 * c-common.c (warning_candidate_p): Don't track non-const calls
14375 or STRING_CSTs.
14376
c6a13190
ILT
143772010-11-15 Ian Lance Taylor <iant@google.com>
14378
14379 * c-lex.c (init_c_lex): Set macro debug callbacks if
14380 flag_dump_go_spec is set.
14381
925e8657
NP
143822010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
14383
14384 * c-common.h (objc_build_incr_expr_for_property_ref): New.
14385 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
14386
bb0a9581
NF
143872010-11-15 Nathan Froyd <froydnj@codesourcery.com>
14388
14389 PR preprocessor/45038
14390 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
14391 dialects.
14392
c5fa0890
JM
143932010-11-12 Joseph Myers <joseph@codesourcery.com>
14394
14395 * c-common.h (c_family_lang_mask): Declare.
14396 * c-opts.c (c_family_lang_mask): Make extern.
14397 * c-pragma.c (handle_pragma_diagnostic): Use
14398 control_warning_option.
14399
a4d8c676
JM
144002010-11-12 Joseph Myers <joseph@codesourcery.com>
14401
14402 * c-common.c (parse_optimize_options): Update call to
14403 decode_options.
14404 * c-common.h (c_common_handle_option): Update prototype.
14405 * c-opts.c (c_common_handle_option): Take location_t parameter and
14406 pass it to other functions.
14407
f954bd2c
JM
144082010-11-11 Joseph Myers <joseph@codesourcery.com>
14409
14410 * c-opts.c (warning_as_error_callback): Remove.
14411 (c_common_initialize_diagnostics): Don't call
14412 register_warning_as_error_callback.
14413 (c_common_handle_option): Handle -Werror=normalized= here.
14414
d8a07487
JM
144152010-11-10 Joseph Myers <joseph@codesourcery.com>
14416
14417 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
14418 in diagnostic.
14419 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
14420 letter.
14421 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
14422 Remove trailing '.' from diagnostics.
14423 * c.opt (Wwrite-strings_: Avoid '`' in help text.
14424
d5478783
JM
144252010-11-10 Joseph Myers <joseph@codesourcery.com>
14426
14427 * c-common.c (parse_optimize_options): Pass global_dc to
14428 decode_options.
14429 * c-opts.c (c_common_handle_option): Pass &global_options to
14430 set_Wstrict_aliasing.
14431 * c.opt (v): Don't mark Common or document here.
14432
91ebb981
IS
144332010-11-06 Iain Sandoe <iains@gcc.gnu.org>
14434
14435 PR target/44981
14436 * c-format.c (format_type): New type gcc_objc_string_format_type.
14437 (valid_stringptr_type_p): New.
14438 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
9faeb493 14439 (check_format_string): Pass expected type, use
91ebb981
IS
14440 valid_stringptr_type_p (), check that the format string types are
14441 consistent with the format specification.
14442 (decode_format_attr): Warn if NSString is used outside objective-c.
14443 (format_types_orig): Add NSString.
14444 (format_name): New.
14445 (format_flags): New.
14446 (check_format_arg): Handle format strings requiring an external parser.
14447 first_target_format_type: New variable.
14448 (handle_format_attribute): Set up first_target_format_type, pass the
14449 expected format arg string type to check_format_string().
ab20d992 14450 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
91ebb981
IS
14451 * stub-objc.c (objc_string_ref_type_p): New.
14452 (objc_check_format_arg): New.
14453
bede2adc
NP
144542010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
14455
9faeb493 14456 Fixed using the Objective-C 2.0 dot-syntax with class names.
bede2adc
NP
14457 * c-common.h (objc_build_class_component_ref): New.
14458 * stub-objc.c (objc_build_class_component_ref): New.
14459
9a179d01
NP
144602010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
14461
14462 * c.opt (Wproperty-assign-default): New option.
14463
22d8d616
NP
144642010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
14465
14466 Implemented -fobjc-std=objc1 flag.
14467 * c.opt (fobjc-std=objc1): New option.
14468
2debdb4f
NP
144692010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
14470
14471 Implemented format and noreturn attributes for Objective-C methods.
14472 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
14473 attribute for Objective-C methods.
14474
ec52b111
JM
144752010-10-31 Jason Merrill <jason@redhat.com>
14476
14477 * c-common.c (conversion_warning, warn_for_collisions_1): Use
14478 EXPR_LOC_OR_HERE.
14479
46a88c12
NP
144802010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
14481
14482 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
14483 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
14484 (objc_add_property_declaration): Removed arguments for copies and
14485 ivar.
14486 (objc_build_getter_call): Renamed to
14487 objc_maybe_build_component_ref.
14488 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
14489 (objc_is_property_ref): New.
14490 * c-common.c (c_common_reswords): Removed copies and ivar.
14491 * stub-objc.c (objc_add_property_declaration): Removed arguments
14492 for copies and ivar.
14493 (objc_build_getter_call): Renamed to
14494 objc_maybe_build_component_ref.
14495 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
14496 (objc_is_property_ref): New.
9faeb493 14497
1e4bf85b
AC
144982010-10-29 Arnaud Charlet <charlet@adacore.com>
14499 Matthew Gingell <gingell@adacore.com>
14500
14501 * c-ada-spec.c (separate_class_package): New function.
14502 (pp_ada_tree_identifier): Prefix references to C++ classes with the
14503 name of their enclosing package.
14504 (print_ada_declaration): Use separate_class_package.
14505
81f0bab2
JM
145062010-10-27 Jason Merrill <jason@redhat.com>
14507
2b08f2c5
JM
14508 * c-common.c (c_common_reswords): Add __is_literal_type.
14509 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
14510
81f0bab2
JM
14511 * c-common.c (check_case_value): Remove special C++ code.
14512
200290f2
NP
145132010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
14514
14515 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
14516 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
14517 and RID_LAST_PATTR.
14518 (objc_add_property_declaration): Added additional arguments.
14519 (objc_property_attribute_kind): Removed.
14520 (objc_set_property_attr): Removed.
14521 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
14522 copy and nonatomic.
14523 * stub-objc.c (objc_add_property_declaration): Added additional
14524 arguments.
14525 (objc_set_property_attr): Removed.
9faeb493 14526
f614132b
NP
145272010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
14528
14529 * c-common.h (objc_add_property_variable): Renamed to
14530 objc_add_property_declaration. Added location argument.
14531 * stub-objc.c (objc_add_property_variable): Same change.
b1726d6c 14532
b8a18805
NP
145332010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
14534
14535 * c-common.h (objc_maybe_printable_name): New.
14536 * stub-objc.c (objc_maybe_printable_name): New.
14537
3f8257db
JJ
145382010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
14539 Andrew Pinski <pinskia@gmail.com>
30cd1c5d
AS
14540
14541 * c-common.h (c_common_mark_addressable_vec): Declare.
14542 * c-common.c (c_common_mark_addressable_vec): New function.
14543
249a82c4
NP
145442010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
14545
14546 * c-common.h (objc_set_method_type): Removed.
14547 (objc_add_method_declaration): Added boolean argument.
14548 (objc_start_method_definition): Same change.
14549 (objc_build_method_signature): Same change.
14550 * stub-objc.c (objc_set_method_type): Removed.
14551 (objc_add_method_declaration): Added boolean argument.
14552 (objc_start_method_definition): Same change.
14553 (objc_build_method_signature): Same change.
14554
977e30bc
NP
145552010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
14556
14557 * c-common.h (finish_file): Removed.
14558 (objc_write_global_declarations): New.
14559 * c-opts.c (c_common_parse_file): Do not call finish_file.
14560 * stub-objc.c (objc_write_global_declarations): New.
9faeb493 14561
da57d1b9
NP
145622010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
14563
14564 Implemented parsing @synthesize and @dynamic for
14565 Objective-C/Objective-C++.
14566 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
14567 (objc_add_synthesize_declaration): New.
14568 (objc_add_dynamic_declaration): New.
14569 * c-common.c (c_common_reswords): Add synthesize and dynamic.
14570 * stub-objc.c (objc_add_synthesize_declaration): New.
14571 (objc_add_dynamic_declaration): New.
9faeb493 14572
0069111f
MM
145732010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
14574
14575 PR target/46041
14576 * c-cppbuiltin.c (mode_has_fma): Move function here from
14577 builtins.c. Don't use the fma optab, instead just use the
14578 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
14579 using -save-temps.
14580
e426b47b
NP
145812010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
14582
14583 Merge from 'apple/trunk' branch on FSF servers.
0069111f 14584
3f8257db 14585 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
e426b47b 14586
9faeb493 14587 Radar 4330422
e426b47b
NP
14588 * c-common.h (objc_non_volatilized_type): New declaration
14589 * stub-objc.c (objc_non_volatilized_type): New stub.
14590
90fbfdc3
NP
145912010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
14592
e426b47b 14593 Merge from 'apple/trunk' branch on FSF servers.
90fbfdc3 14594
ab20d992 14595 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
90fbfdc3 14596
9faeb493 14597 Radar 4133425
90fbfdc3 14598 * c-common.h (objc_diagnose_private_ivar): New decl.
0069111f 14599 * stub-objc.c (objc_diagnose_private_ivar): New stub.
90fbfdc3 14600
c37d8c30
IS
146012010-10-17 Iain Sandoe <iains@gcc.gnu.org>
14602
14603 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
14604 * c-common.h (enum rid): Add RID_AT_PACKAGE.
14605 (objc_ivar_visibility_kind): New enum.
14606 (objc_set_visibility): Adjust prototype to use visibility enum.
0069111f 14607 * stub-objc.c (objc_set_visibility): Adjust stub to use
c37d8c30
IS
14608 visibility enum.
14609
1b1562a5
MM
146102010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
14611
14612 * c-cppbuiltin.c (builtin_define_float_constants): Emit
14613 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
14614 has the appropriate fma builtins.
14615 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
14616
668ea4b1
IS
146172010-10-14 Iain Sandoe <iains@gcc.gnu.org>
14618
1b1562a5 14619 merge from FSF apple 'trunk' branch.
3f8257db 14620 2006 Fariborz Jahanian <fjahanian@apple.com>
1b1562a5 14621
668ea4b1
IS
14622 Radars 4436866, 4505126, 4506903, 4517826
14623 * c-common.c (c_common_resword): Define @property and its attributes.
14624 * c-common.h: Define property attribute enum entries.
14625 (OBJC_IS_PATTR_KEYWORD): New.
14626 (objc_property_attribute_kind): New enum.
14627 Declare objc_set_property_attr (), objc_add_property_variable (),
14628 objc_build_getter_call () and objc_build_setter_call ().
14629 * stub-objc.c (objc_set_property_attr): New stub.
14630 (objc_add_property_variable): Likewise.
14631 (objc_build_getter_call): Likewise.
14632 (objc_build_setter_call) Likewise.
1b1562a5 14633
a1178b30
IS
146342010-10-13 Iain Sandoe <iains@gcc.gnu.org>
14635
1b1562a5 14636 merge from FSF apple 'trunk' branch.
ab20d992 14637 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
a1178b30
IS
14638
14639 Radar 3803157 (method attributes)
14640 * c-common.c (handle_deprecated_attribute): Recognize
14641 objc methods as valid declarations.
14642 * c-common.h: Declare objc_method_decl ().
1b1562a5 14643 * stub-objc.c (objc_method_decl): New stub.
a1178b30 14644
a75bfaa6
JM
146452010-10-08 Joseph Myers <joseph@codesourcery.com>
14646
14647 * c-common.c (parse_optimize_options): Call
14648 decode_cmdline_options_to_array_default_mask before
14649 decode_options. Update arguments to decode_options.
14650 * c-common.h (c_common_init_options_struct): Declare.
14651 * c-opts.c (c_common_init_options_struct): New. Split out from
14652 c_common_init_options.
14653
f05b9d93
NP
146542010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
14655
14656 Implemented fast enumeration for Objective-C.
14657 * c-common.h (objc_finish_foreach_loop): New.
14658 * stub-objc.c (objc_finish_foreach_loop): New.
14659
1ebe4b4f
JM
146602010-10-05 Joseph Myers <joseph@codesourcery.com>
14661
14662 * c-common.h (struct diagnostic_context): Don't declare here.
14663 (c_common_initialize_diagnostics): Declare using
14664 diagnostic_context typedef.
14665 * c-opts.c (c_common_handle_option): Pass global_dc to
14666 handle_generated_option.
14667
d4d24ba4
JM
146682010-10-04 Joseph Myers <joseph@codesourcery.com>
14669
14670 * c-opts.c (c_common_handle_option): Pass &global_options_set to
14671 handle_generated_option.
14672
478a1c5b
ILT
146732010-10-03 Ian Lance Taylor <iant@google.com>
14674
14675 * c.opt (-fplan9-extensions): New option.
14676
82a1c2fe
FXC
146772010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
14678
14679 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
14680 Remove.
14681 (c_cpp_builtins): Call functions from cppbuiltin.c instead
14682 of duplicating code.
14683
92902b1b
IS
146842010-09-30 Iain Sandoe <iains@gcc.gnu.org>
14685
14686 * c-common.c: Add two new entries for @optional
14687 and @required keywords.
14688
14689 merge from FSF 'apple/trunk' branch.
3f8257db 14690 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
92902b1b
IS
14691
14692 Radar 4386773
14693 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
14694 objective-c keywords.
14695 (objc_set_method_opt): New declaration.
14696 * stub-objc.c (objc_set_method_opt): New stub.
9faeb493 14697
46625112
JM
146982010-09-30 Joseph Myers <joseph@codesourcery.com>
14699
14700 * c-common.c (handle_optimize_attribute): Pass &global_options to
14701 cl_optimization_save and cl_optimization_restore.
14702 * c-opts.c (c_common_handle_option): Pass &global_options to
14703 handle_generated_option.
14704 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
14705 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
14706 &global_options to cl_optimization_restore.
14707
49b91f05
NP
147082010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
14709
14710 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
14711 Objective-C/Objective-C++ keywords.
14712
13ed556f 147132010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
a6341d57 14714
9faeb493
UB
14715 Merge from 'apple/trunk' branch on FSF servers.
14716
3f8257db 14717 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
a6341d57
NP
14718
14719 Radar 4281748
14720 * c-common.h (objc_check_global_decl): New declaration.
14721 * stub-objc.c (objc_check_global_decl): New stub.
14722
f0036cca
JM
147232010-09-29 Joseph Myers <joseph@codesourcery.com>
14724
14725 * c.opt: Don't use VarExists.
14726
e3339d0f
JM
147272010-09-29 Joseph Myers <joseph@codesourcery.com>
14728
14729 * c-common.c (c_cpp_error): Update names of diagnostic_context
14730 members.
14731 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
14732 cl_optimization members.
14733 * c-opts.c (warning_as_error_callback, c_common_handle_option,
14734 sanitize_cpp_opts, finish_options): Update names of cpp_options
14735 members.
14736
1973201f
NP
147372010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
14738
14739 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
14740 (objc_is_reserved_word): Removed.
14741 * c-common.c: Updated comments.
14742 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
14743 objc_is_reserved_word.
14744 * stub-objc.c (objc_is_reserved_word): Removed.
14745
f7e71da5
IS
147462010-09-28 Iain Sandoe <iains@gcc.gnu.org>
14747
9faeb493 14748 * c-common.h (objc_add_method_declaration): Adjust prototype to
f7e71da5
IS
14749 include attributes.
14750 (objc_start_method_definition): Likewise.
14751 (objc_build_keyword_decl): Likewise.
14752 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
14753 (objc_start_method_definition): Likewise.
14754 (objc_build_keyword_decl): Likewise.
14755
c165dca7
IS
147562010-09-28 Iain Sandoe <iains@gcc.gnu.org>
14757
14758 * c-common.h (objc_start_class_interface): Adjust prototype.
14759 (objc_start_category_interface): Likewise.
14760 (objc_start_protocol): Likewise.
14761 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
14762 (objc_start_class_interface): Likewise.
14763 (objc_start_category_interface): Likewise.
14764
7458026b
ILT
147652010-09-27 Ian Lance Taylor <iant@google.com>
14766
14767 * c-common.c (c_common_attribute_table): Add no_split_stack.
14768 (handle_no_split_stack_attribute): New static function.
14769
b581b85b
NP
147702010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
14771
9faeb493 14772 Merge from 'apple/trunk' branch on FSF servers.
b581b85b 14773
3f8257db 14774 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
b581b85b 14775
9faeb493 14776 Radar 4229905
b581b85b
NP
14777 * c-common.h (objc_have_common_type): New declaration.
14778 * stub-objc.c (objc_have_common_type): New stub.
14779
14780 2005-06-22 Ziemowit Laski <zlaski@apple.com>
14781
14782 Radar 4154928
14783 * c-common.h (objc_common_type): New prototype.
9faeb493 14784 * stub-objc.c (objc_common_type): New stub.
b581b85b 14785
46a4da10
JH
147862010-09-24 Jan Hubicka <jh@suse.cz>
14787
14788 * c-common.c (handle_leaf_attribute): New function.
14789 (struct attribute_spec c_common_att): Add leaf.
14790
e200444e
JM
147912010-09-22 Joseph Myers <joseph@codesourcery.com>
14792
14793 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
14794 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
14795 -dump, -dump=, -imacros, -imacros=, -include, -include=,
14796 -include-barrier, -include-directory, -include-directory=,
14797 -include-directory-after, -include-directory-after=,
14798 -include-prefix, -include-prefix=, -include-with-prefix,
14799 -include-with-prefix=, -include-with-prefix-after,
14800 -include-with-prefix-after=, -include-with-prefix-before,
14801 -include-with-prefix-before=, -no-integrated-cpp,
14802 -no-line-commands, -no-standard-includes, -no-warnings, -output,
14803 -output=, -pedantic, -pedantic-errors, -preprocess,
14804 -print-missing-file-dependencies, -trace-includes, -traditional,
14805 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
14806 -user-dependencies, -verbose, -write-dependencies,
14807 -write-user-dependencies, no-integrated-cpp, traditional): New.
14808
29a80ea6
NP
148092010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
14810
14811 PR objc/23710
ac1fc2fc
NP
14812 * c-common.h (objc_start_method_definition): Return bool instead
14813 of void.
14814 * stub-objc.c (objc_start_method_definition): Return bool instead
14815 of void.
14816
148172010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
14818
14819 PR objc/25965
14820 * c-common.h (objc_get_interface_ivars): New declaration.
14821 * stub-objc.c (objc_get_interface_ivars): New stub.
29a80ea6 14822
de621752
ILT
148232010-09-15 Ian Lance Taylor <iant@google.com>
14824
14825 * c-common.c (parse_optimize_options): Do not capitalize warning
06730c5d 14826 messages. Remove period at end of warning message.
de621752 14827
ba885ec5
NS
148282010-09-09 Nathan Sidwell <nathan@codesourcery.com>
14829
14830 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
14831 (handle_alias_attribute): ... here.
14832 (handle_ifunc_attribute): New.
14833
c5ee1358
MM
148342010-09-06 Mark Mitchell <mark@codesourcery.com>
14835
14836 * c-common.h (do_warn_double_promotion): Declare.
14837 * c-common.c (do_warn_double_promotion): Define.
14838
0a0b3574
MM
148392010-09-05 Mark Mitchell <mark@codesourcery.com>
14840
14841 * c.opt (Wdouble-promotion): New.
14842
d1779886
JM
148432010-09-02 Joseph Myers <joseph@codesourcery.com>
14844
14845 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
14846 fvtable-thunks, fxref): Mark no longer supported in help text.
14847
2d2bd949
JM
148482010-09-02 Joseph Myers <joseph@codesourcery.com>
14849
14850 * c.opt (Wimport, fall-virtual, falt-external-templates,
14851 fdefault-inline, fenum-int-equiv, fexternal-templates,
14852 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
14853 fname-mangling-version-, fnew-abi, fnonnull-objects,
14854 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
14855 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
14856 applicable.
14857 (fhandle-exceptions): Mark with Alias and Warn.
14858 * c-opts.c (c_common_handle_option): Don't handle options marked
14859 as ignored.
14860
5de8299c
JM
148612010-09-02 Joseph Myers <joseph@codesourcery.com>
14862
14863 * c.opt (Wcomments, Werror-implicit-function-declaration,
14864 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
14865 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
14866 aliases.
14867 * c-common.c (option_codes): Use OPT_Wcomment instead of
14868 OPT_Wcomments.
14869 * c-opts.c (warning_as_error_callback, c_common_handle_option):
14870 Don't handle options marked as aliases.
14871
0ceb0201
RG
148722010-08-25 Richard Guenther <rguenther@suse.de>
14873
14874 * c-common.c (c_common_get_alias_set): Remove special
14875 handling for pointers.
14876
ac47786e
NF
148772010-08-20 Nathan Froyd <froydnj@codesourcery.com>
14878
14879 * c-common.c: Use FOR_EACH_VEC_ELT.
14880 * c-gimplify.c: Likewise.
14881 * c-pragma.c: Likewise.
14882
c878765b
JM
148832010-08-16 Joseph Myers <joseph@codesourcery.com>
14884
14885 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
14886 RejectDriver.
14887 (MMDX): Change back to MMD. Mark NoDriverArg instead of
14888 RejectDriver.
14889 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
14890 instead of OPT_MDX and OPT_MMDX.
14891
603349bf
JM
148922010-08-16 Joseph Myers <joseph@codesourcery.com>
14893
14894 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
14895
644fa7ac
JM
148962010-08-12 Joseph Myers <joseph@codesourcery.com>
14897
14898 * c.opt (MD, MMD): Change to MDX and MMDX.
14899 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
14900
481e1176
JM
149012010-08-11 Joseph Myers <joseph@codesourcery.com>
14902
14903 * c-opts.c (c_common_handle_option): Call handle_generated_option
14904 instead of handle_option.
14905
ac8dc9f7
NF
149062010-08-08 Nathan Froyd <froydnj@codesourcery.com>
14907
14908 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
14909 (maybe_apply_renaming_pragma): Delete unneeded declarations.
14910
4f8c876d
NF
149112010-08-08 Nathan Froyd <froydnj@codesourcery.com>
14912
14913 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
14914 (pending_redefine_extname): Change type to a VEC.
14915 (add_to_renaming_pragma_list): Update for new type of
14916 pending_redefine_extname.
ac8dc9f7 14917 (maybe_apply_renaming_pragma): Likewise.
4f8c876d 14918
3b0c690e
AC
149192010-08-04 Arnaud Charlet <charlet@adacore.com>
14920
14921 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
14922 visited.
14923 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
14924 decide whether a type has already been declared/seen.
14925 Do not go to the original type.
14926 (dump_nested_types): New parameter forward.
14927 Generate forward declaration if needed and mark type as visited.
14928 (print_ada_declaration): Call dump_nested_types if not already done.
14929 Mark types as visited.
14930
1890bccc
JM
149312010-08-03 Joseph Myers <joseph@codesourcery.com>
14932
14933 * c.opt (-print-pch-checksum): Remove option.
14934 * c-opts.c (c_common_handle_option): Don't handle
14935 OPT_print_pch_checksum.
14936
5f20c657
JM
149372010-07-27 Joseph Myers <joseph@codesourcery.com>
14938
14939 * c-common.h (c_common_handle_option): Update prototype and return
14940 value type.
14941 * c-opts.c (c_common_handle_option): Update prototype and return
14942 value type. Update calls to handle_option and
14943 enable_warning_as_error.
14944
f551f80c
JJ
149452010-07-27 Jakub Jelinek <jakub@redhat.com>
14946
14947 PR c/45079
14948 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
14949
61ff2bdc
JM
149502010-07-27 Joseph Myers <joseph@codesourcery.com>
14951
14952 * c-common.h (c_common_missing_argument): Remove.
14953 * c-opts.c (c_common_missing_argument): Remove.
14954 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
14955 idirafter, imacros, include, isysroot, isystem, iquote): Add
14956 MissingArgError.
14957 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
14958
7a9bf9a4
JM
149592010-07-27 Joseph Myers <joseph@codesourcery.com>
14960
14961 * c-common.h (c_common_option_lang_mask,
14962 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
14963 New.
14964 (c_common_init_options): Update prototype.
14965 * c-opts.c (c_common_option_lang_mask): New.
14966 (c_common_initialize_diagnostics): Split out of
14967 c_common_init_options.
14968 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
14969 New.
14970 (c_common_init_options): Update prototype. Use decoded options in
14971 search for -lang-asm.
14972
910ad8de
NF
149732010-07-15 Nathan Froyd <froydnj@codesourcery.com>
14974
14975 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
14976 * c-format.c: Likewise.
14977
718f9c0f
MLI
149782010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
14979
14980 * c-common.h: Include diagnostic-core.h. Error if already
14981 included.
14982 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
14983
4d451982
MLI
149842010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
14985
adfac8df 14986 * c-common.c (IN_GCC_FRONTEND): Do not undef.
4d451982
MLI
14987 Do not include expr.h
14988 (vector_mode_valid_p): Move here.
14989
119fe915
SB
149902010-06-21 DJ Delorie <dj@redhat.com>
14991
14992 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
14993 allow these pragmas anywhere.
14994
149952010-06-14 Jakub Jelinek <jakub@redhat.com>
14996
14997 PR bootstrap/44509
14998 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
14999 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
15000 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
15001 ggc_strdup instead of xstrdup.
15002
150032010-06-10 Jakub Jelinek <jakub@redhat.com>
15004
15005 * c-cppbuiltin.c: Include cpp-id-data.h.
15006 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
15007 (lazy_hex_fp_value): New function.
15008 (builtin_define_with_hex_fp_value): Provide definitions lazily.
15009
6662d794
MLI
150102010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
15011
15012 * c-gimplify.c: Do not include tree-flow.h
15013
38f8b050
JR
150142010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
15015
15016 PR other/44034
15017 * c-common.c: Rename targetm member:
15018 targetm.enum_va_list -> targetm.enum_va_list_p
15019
9589f23e
AS
150202010-06-28 Anatoly Sokolov <aesok@post.ru>
15021
15022 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
15023
3b06d379
SB
150242010-06-28 Steven Bosscher <steven@gcc.gnu.org>
15025
15026 * c-cppbuiltin.c: Do not include except.h.
15027
d166d4c3
AK
150282010-06-24 Andi Kleen <ak@linux.intel.com>
15029
9faeb493
UB
15030 * c-common.c (warn_for_omitted_condop): New.
15031 * c-common.h (warn_for_omitted_condop): Add prototype.
d166d4c3 15032
70cb8be6
JM
150332010-06-21 Joseph Myers <joseph@codesourcery.com>
15034
15035 * c.opt (lang-objc): Remove.
15036 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
15037
a4c97feb
JR
150382010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
15039
15040 * c-opts.c: Include "tm_p.h".
15041
6e2f1956
JM
150422010-06-20 Joseph Myers <joseph@codesourcery.com>
15043
15044 * c-common.c (parse_optimize_options): Update call to
15045 decode_options.
15046
bc87224e
NF
150472010-06-18 Nathan Froyd <froydnj@codesourcery.com>
15048
15049 * c-common.c (record_types_used_by_current_var_decl): Adjust for
15050 new type of types_used_by_cur_var_decl.
15051
b49cf425
JR
150522010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
15053
15054 PR bootstrap/44512
15055 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
15056 for C++ standard compliance.
15057
59f9c2ed
JM
150582010-06-16 Jason Merrill <jason@redhat.com>
15059
15060 * c.opt: Add -Wnoexcept.
15061
33766b66
RG
150622010-06-16 Richard Guenther <rguenther@suse.de>
15063
15064 PR c/44555
15065 * c-common.c (c_common_truthvalue_conversion): Remove
15066 premature and wrong optimization concering ADDR_EXPRs.
15067
eff7e30c
AC
150682010-06-15 Arnaud Charlet <charlet@adacore.com>
15069
15070 * c-ada-spec.c (dump_sloc): Remove column info.
15071 (is_simple_enum): New function.
15072 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
15073 enum types when relevant.
15074
6312e84d
MLI
150752010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
15076
9faeb493 15077 * c-common.c (conversion_warning): Warn at expression
6312e84d
MLI
15078 location.
15079
1cb42611
JM
150802010-06-10 Joseph Myers <joseph@codesourcery.com>
15081
15082 * c-opts.c (c_common_handle_option): Don't handle
15083 OPT_fshow_column.
15084
a9429e29
LB
150852010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
15086
15087 * c-pragma.c (push_alignment): Use typed GC allocation.
15088 (handle_pragma_push_options): Likewise.
15089
15090 * c-common.c (parse_optimize_options): Likewise.
15091
15092 * c-common.h (struct sorted_fields_type): Add variable_size GTY
15093 option.
15094
5498f011
JM
150952010-06-07 Joseph Myers <joseph@codesourcery.com>
15096
15097 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
15098 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
15099 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
15100 flag_signed_bitfields, warn_strict_null_sentinel,
15101 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
15102 flag_gen_declaration, flag_no_gnu_keywords,
15103 flag_implement_inlines, flag_implicit_templates,
15104 flag_implicit_inline_templates, flag_optional_diags,
15105 flag_elide_constructors, flag_default_inline, flag_rtti,
15106 flag_conserve_space, flag_access_control, flag_check_new,
15107 flag_new_for_scope, flag_weak, flag_working_directory,
15108 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
15109 flag_enforce_eh_specs, flag_threadsafe_statics,
15110 flag_pretty_templates): Remove.
15111 * c-common.h (flag_preprocess_only, flag_nil_receivers,
15112 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
15113 flag_replace_objc_classes, flag_undef, flag_no_builtin,
15114 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
15115 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
15116 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
15117 flag_no_gnu_keywords, flag_implement_inlines,
15118 flag_implicit_templates, flag_implicit_inline_templates,
15119 flag_optional_diags, flag_elide_constructors, flag_default_inline,
15120 flag_rtti, flag_conserve_space, flag_access_control,
15121 flag_check_new, flag_new_for_scope, flag_weak,
15122 flag_working_directory, flag_use_cxa_atexit,
15123 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
15124 flag_threadsafe_statics, flag_pretty_templates,
15125 warn_strict_null_sentinel): Remove.
15126 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
15127 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
15128 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
15129 fimplicit-inline-templates, fimplicit-templates,
15130 flax-vector-conversions, fms-extensions, fnil-receivers,
15131 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
15132 frtti, fshort-double, fshort-enums, fshort-wchar,
15133 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
15134 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
15135 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
15136 gen-decls, undef): Use Var.
15137 (fdefault-inline, foptional-diags): Document as doing nothing.
15138 * c-opts.c (c_common_handle_option): Remove cases for options now
15139 using Var. Mark ignored options as such.
15140
39dabefd
SB
151412010-06-05 Steven Bosscher <steven@gcc.gnu.org>
15142
9faeb493 15143 * c-common.c: Moved to here from parent directory.
39dabefd
SB
15144 * c-common.def: Likewise.
15145 * c-common.h: Likewise.
15146 * c-cppbuiltin.c: Likewise.
15147 * c-dump.c: Likewise.
15148 * c-format.c: Likewise.
15149 * c-format.h : Likewise.
15150 * c-gimplify.c: Likewise.
15151 * c-lex.c: Likewise.
15152 * c-omp.c: Likewise.
15153 * c.opt: Likewise.
15154 * c-opts.c: Likewise.
15155 * c-pch.c: Likewise.
15156 * c-ppoutput.c: Likewise.
15157 * c-pragma.c: Likewise.
15158 * c-pragma.h: Likewise.
15159 * c-pretty-print.c: Likewise.
15160 * c-pretty-print.h: Likewise.
15161 * c-semantics.c: Likewise.
15162 * stub-objc.c: Likewise.
15163
15164 * c-common.c: Include gt-c-family-c-common.h.
15165 * c-pragma.c: Include gt-c-family-c-pragma.h.
15166\f
6a720d41 15167Copyright (C) 2010-2024 Free Software Foundation, Inc.
39dabefd
SB
15168
15169Copying and distribution of this file, with or without modification,
15170are permitted in any medium without royalty provided the copyright
15171notice and this notice are preserved.
This page took 5.391959 seconds and 6 git commands to generate.