]> gcc.gnu.org Git - gcc.git/blame - gcc/c-family/ChangeLog
PR modula2/110161 Comparing a typed procedure variable to 0 gives ICE or assertion
[gcc.git] / gcc / c-family / ChangeLog
CommitLineData
a2f31d79
GA
12023-07-31 Hamza Mahfooz <someguy@effective-light.com>
2
3 PR c/65213
4 * c.opt (-Wmissing-variable-declarations): New option.
5
e2bf82d5
GA
62023-07-20 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
7
8 PR middle-end/77928
9 * c-common.cc (check_builtin_function_arguments):
10 Handle BUILT_IN_ISEQSIG.
11
5158918a
GA
122023-07-05 Robin Dapp <rdapp@ventanamicro.com>
13 Juzhe-Zhong <juzhe.zhong@rivai.ai>
14
15 * c-common.cc (c_common_type_for_mode): Use GET_MODE_PRECISION.
16
14bfda60
GA
172023-06-29 Qing Zhao <qing.zhao@oracle.com>
18
19 PR c/77650
20 * c.opt: New option -Wflex-array-member-not-at-end.
21
5f590ee3
GA
222023-06-28 Jason Merrill <jason@redhat.com>
23
24 PR c++/110344
25 * c-cppbuiltin.cc (c_cpp_builtins): Update __cpp_constexpr.
26
267e1fea
GA
272023-06-26 Richard Biener <rguenther@suse.de>
28
29 * c-common.cc (shorten_binary_op): Exit early for VECTOR_TYPE
30 operations.
31
6f78df4c
GA
322023-06-23 Marek Polacek <polacek@redhat.com>
33
34 * c-common.h (cxx_dialect): Add cxx26 as a dialect.
35 * c-opts.cc (set_std_cxx26): New.
36 (c_common_handle_option): Set options when -std={c,gnu}++2{c,6} is
37 enabled.
38 (c_common_post_options): Adjust comments.
39 * c.opt: Add options for -std=c++26, std=c++2c, -std=gnu++26,
40 and -std=gnu++2c.
41 (std=c++2b): Mark as Undocumented.
42 (std=c++23): No longer Undocumented.
43
80e9ca0e
GA
442023-06-21 Alexander Monakov <amonakov@ispras.ru>
45
46 * c-gimplify.cc (fma_supported_p): New helper.
47 (c_gimplify_expr) [PLUS_EXPR, MINUS_EXPR]: Implement FMA
48 contraction.
49
f10a4ce0
GA
502023-06-16 Alex Coplan <alex.coplan@arm.com>
51
52 * c.opt (Welaborated-enum-base): New.
53
532fb120
GA
542023-06-13 David Malcolm <dmalcolm@redhat.com>
55
56 PR c/84890
57 * known-headers.cc
58 (suggest_missing_header::~suggest_missing_header): Reword note to
59 avoid negative tone of "forgetting".
60
8c5b1365
GA
612023-06-07 Jason Merrill <jason@redhat.com>
62
63 PR c++/58487
64 * c.opt: Add -Wnrvo.
65
6e6bb373
GA
662023-05-26 Martin Uecker <uecker@tugraz.at>
67
68 * c-attribs.cc (build_attr_access_from_parms): Split loop to first
69 record all parameters.
70
b2776076
GA
712023-05-18 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
72
73 * c-ada-spec.cc (has_static_fields): Use _P() defines from tree.h.
74 (dump_ada_declaration): Ditto.
75 (dump_ada_structure): Ditto.
76 * c-common.cc (unsafe_conversion_p): Ditto.
77 (shorten_compare): Ditto.
78 (pointer_int_sum): Ditto.
79 (c_common_truthvalue_conversion): Ditto.
80 (scalar_to_vector): Ditto.
81 * c-common.h (gnu_vector_type_p): Ditto.
82 * c-omp.cc (c_omp_depend_t_p): Ditto.
83 (c_omp_split_clauses): Ditto.
84 * c-ubsan.cc (ubsan_instrument_division): Ditto.
85 * c-warn.cc (conversion_warning): Ditto.
86 (warnings_for_convert_and_check): Ditto.
87
ff2dcddf
GA
882023-05-18 Joseph Myers <joseph@codesourcery.com>
89
90 * c-format.cc (print_char_table): Handle %B like %b.
91
3427b51b
GA
922023-05-15 Joseph Myers <joseph@codesourcery.com>
93
94 * c-lex.cc (c_common_has_attribute): Use 202311 as
95 __has_c_attribute return for all C2x attributes.
96
972023-05-15 Patrick Palka <ppalka@redhat.com>
98
99 * c-cppbuiltin.cc (c_cpp_builtins): Predefine __cpp_auto_cast
100 for C++23.
101
1fc8da95
GA
1022023-05-01 Marek Polacek <polacek@redhat.com>
103
104 * c-ubsan.cc (ubsan_maybe_instrument_array_ref): Don't copy_node.
105
579cdc1e
GA
1062023-03-28 David Malcolm <dmalcolm@redhat.com>
107
108 PR c/107002
109 * c-common.h (check_for_xor_used_as_pow): Add "rhs_loc" param.
110 * c-warn.cc (check_for_xor_used_as_pow): Add "rhs_loc" param.
111 Reject cases where involving macro expansions.
112
1132023-03-28 Jason Merrill <jason@redhat.com>
114
115 PR c++/107163
116 * c-common.cc (verify_tree): Don't use sequenced handling
117 for COMPONENT_REF.
118
454a4d50
GA
1192023-03-17 Jakub Jelinek <jakub@redhat.com>
120
121 PR c/109151
122 * c-ubsan.cc (ubsan_instrument_division): Handle all scalar integral
123 types rather than just INTEGER_TYPE.
124
c8065441
GA
1252023-03-10 Marek Polacek <polacek@redhat.com>
126
127 PR sanitizer/108060
128 PR sanitizer/109050
129 * c-gimplify.cc (ubsan_walk_array_refs_r): For a MODIFY_EXPR, instrument
130 the RHS before the LHS.
131
2858bf16
GA
1322023-03-04 Jakub Jelinek <jakub@redhat.com>
133
134 PR c/107465
135 * c-warn.cc (warn_for_sign_compare): Don't warn for unset bits
136 above innermost zero extension of BIT_NOT_EXPR result.
137
1382023-03-04 Jakub Jelinek <jakub@redhat.com>
139
140 PR c/107465
141 * c-warn.cc (warn_for_sign_compare): If c_common_get_narrower
142 doesn't return a narrower result, use TYPE_UNSIGNED to set unsignedp0
143 and unsignedp1. For the one BIT_NOT_EXPR case vs. one without,
144 only check for constant in the non-BIT_NOT_EXPR operand, use std::swap
145 to simplify the code, only warn if BIT_NOT_EXPR operand is extended
146 from narrower unsigned, fix up computation of mask for the constant
147 cases and for unsigned other operand case handle differently
148 BIT_NOT_EXPR result being sign vs. zero extended.
149
1502023-03-04 Jakub Jelinek <jakub@redhat.com>
151
152 PR c/107846
153 * c-warn.cc: Include langhooks.h.
154 (maybe_warn_shift_overflow): Set type0 to what TREE_TYPE (op0)
155 promotes to rather than TREE_TYPE (op0) itself, if TREE_TYPE (op0)
156 is narrower than type0 and unsigned, use wi::min_precision with
157 UNSIGNED and fold_convert op0 to type0 before emitting the warning.
158
2aa6673e
GA
1592023-03-03 Alexandre Oliva <oliva@adacore.com>
160
161 * c-common.cc (c_common_nodes_and_builtins): Take
162 wchar_type_node for wint_type_node when aliased.
163 (c_stddef_cpp_builtins): Define __WINT_TYPE__, when aliased to
164 wchar_t, to the underlying type rather than wchar_t in
165 non-C++.
166 * c-cppbuiltin.cc (type_suffix): Handle wchar_type_node.
167
6f9e2f14
GA
1682023-02-28 Marek Polacek <polacek@redhat.com>
169
170 PR c++/107938
171 * c-warn.cc (check_address_or_pointer_of_packed_member): Check
172 POINTER_TYPE_P.
173
1742023-02-28 Jakub Jelinek <jakub@redhat.com>
175
176 PR sanitizer/108894
177 * c-common.h (c_strict_flex_array_level_of): Declare.
178 * c-common.cc (c_strict_flex_array_level_of): New function,
179 moved and renamed from c-decl.cc's strict_flex_array_level_of.
180 * c-ubsan.cc (ubsan_instrument_bounds): Fix comment typo. For
181 C check c_strict_flex_array_level_of whether a trailing array
182 should be treated as flexible member like. Handle C [0] arrays.
183 Add 1 + index_off_by_one rather than index_off_by_one to bounds
184 and use tree_int_cst_lt rather than tree_int_cst_le for idx vs.
185 bounds comparison.
186
e2b20ed3
GA
1872023-02-23 Jakub Jelinek <jakub@redhat.com>
188
189 PR translation/108890
190 * c.opt (fcontracts): Fix description.
191
b6f98991
GA
1922023-02-22 Marek Polacek <polacek@redhat.com>
193
194 PR c/108880
195 * c-gimplify.cc (c_genericize_control_stmt) <case STATEMENT_LIST>: Pass
196 pset to walk_tree_1.
197 (c_genericize): Call walk_tree with an explicit pset.
198
0263e9d5
GA
1992023-02-18 Martin Uecker <uecker@tugraz.at>
200
201 PR c/105660
202 * c-attribs.cc (append_access_attr): Use order of arguments when
203 construction string.
204 (append_access_attr_idxs): Rename and make static.
205 * c-warn.cc (warn_parm_array_mismatch): Add assertion.
206
88cc4495
GA
2072023-02-16 Patrick Palka <ppalka@redhat.com>
208
209 * c-common.h: Mechanically drop static from static inline
210 functions via s/^static inline/inline/g.
211
0a251e74
GA
2122023-02-01 Jason Merrill <jason@redhat.com>
213
214 * c.opt: Add -Wno-changes-meaning.
215
317525b0
GA
2162023-01-31 Marek Polacek <polacek@redhat.com>
217
218 PR c++/107593
219 PR c++/108597
220 * c-common.h (instantiation_dependent_expression_p): Declare.
221 * c-warn.cc (warn_duplicated_cond_add_or_warn): If the condition
222 is dependent, invalidate the chain.
223
2371d100
GA
2242023-01-26 Marek Polacek <polacek@redhat.com>
225
226 PR c++/105300
227 * c-pragma.cc (handle_pragma_message): Warn for CPP_STRING_USERDEF.
228
9f98cfa5
GA
2292023-01-18 Marek Polacek <polacek@redhat.com>
230
231 PR c/108424
232 * c-common.cc (check_case_value): Check INTEGRAL_TYPE_P.
233
5013c3bb
GA
2342023-01-14 Jakub Jelinek <jakub@redhat.com>
235
236 PR c++/108365
237 * c-common.h (may_shorten_divmod): New static inline function.
238
2392023-01-13 Eric Botcazou <ebotcazou@adacore.com>
240
241 * c-ada-spec.cc (is_float32): New function.
242 (is_float64): Likewise.
243 (is_float128): Tweak.
244 (dump_ada_node) <REAL_TYPE>: Call them to recognize more types.
245
81ed98bc
GA
2462023-01-12 Lewis Hyatt <lhyatt@gmail.com>
247
248 PR preprocessor/108244
249 * c-pragma.cc (c_register_pragma_1): Don't attempt to register any
250 deferred pragmas if -fdirectives-only.
251 (init_pragma): Likewise.
252
84723aca
GA
2532023-01-09 Martin Liska <mliska@suse.cz>
254
255 PR c/107993
256 * c-attribs.cc (handle_target_clones_attribute): Check for
257 string constant for all target_clone attribute values.
258
0f8fbb57
GA
2592023-01-03 Florian Weimer <fweimer@redhat.com>
260
261 * c-cppbuiltin.cc (c_cpp_builtins): Define
262 __LIBGCC_DWARF_CIE_DATA_ALIGNMENT__.
263
2642023-01-03 Florian Weimer <fweimer@redhat.com>
265
266 Revert:
267 2023-01-03 Florian Weimer <fweimer@redhat.com>
268
269 * c-cppbuiltin.cc (__LIBGCC_DWARF_REG_SIZES_CONSTANT__):
270 Define if constant is known.
271
2722023-01-03 Florian Weimer <fweimer@redhat.com>
273
274 Revert:
275 2023-01-02 Florian Weimer <fweimer@redhat.com>
276
277 * c-cppbuiltin.cc (c_cpp_builtins): Define
278 __LIBGCC_DWARF_CIE_DATA_ALIGNMENT__.
279
fee53a31
GA
2802023-01-02 Florian Weimer <fweimer@redhat.com>
281
282 * c-cppbuiltin.cc (c_cpp_builtins): Define
283 __LIBGCC_DWARF_CIE_DATA_ALIGNMENT__.
284
2852023-01-02 Florian Weimer <fweimer@redhat.com>
286
287 * c-cppbuiltin.cc (__LIBGCC_DWARF_REG_SIZES_CONSTANT__):
288 Define if constant is known.
289
d2ef2327
GA
2902022-12-19 Marek Polacek <polacek@redhat.com>
291
292 PR c/98487
293 * c-format.cc (check_function_format): Use get_attribute_name.
294
5fb1e674
GA
2952022-12-16 Qing Zhao <qing.zhao@oracle.com>
296
297 * c.opt (Wstrict-flex-arrays): New option.
298
596dbfff
GA
2992022-12-02 Andrew MacLeod <amacleod@redhat.com>
300
301 * c-attribs.cc (handle_deprecated_attribute): Use type when
302 using TYPE_NAME.
303
b35680ec
GA
3042022-12-02 Jakub Jelinek <jakub@redhat.com>
305
306 PR c++/84469
307 * c-omp.cc (c_omp_is_loop_iterator): For range for with structured
308 binding return TREE_VEC_LENGTH (d->declv) even if decl is equal
309 to any of the structured binding decls.
310
6eea85a9
GA
3112022-11-30 Iskander Shakirzyanov <iskander@ispras.ru>
312 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
313
314 PR driver/107787
315 * c-common.cc (fold_offsetof,
316 convert_vector_to_array_for_subscript): Use OPT_Warray_bounds_
317 instead of OPT_Warray_bounds.
318
9a1b4f1d
GA
3192022-11-24 Jakub Jelinek <jakub@redhat.com>
320
321 * c.opt (fcontract-role=, fcontract-semantic=): Terminate descriptions
322 with a dot.
323
8761284f
GA
3242022-11-23 Andrew Pinski <apinski@marvell.com>
325 Jakub Jelinek <jakub@redhat.com>
326
327 PR c/107127
328 * c-gimplify.cc (c_genericize): Use walk_tree_without_duplicates
329 instead of walk_tree for c_genericize_control_r.
330
3312022-11-23 Jakub Jelinek <jakub@redhat.com>
332
333 * c.opt (fcontract-assumption-mode=, fcontract-continuation-mode=,
334 fcontract-role=, fcontract-semantic=): Add RejectNegative.
335 (fcontract-build-level=): Terminate description with dot.
336
fb98ede8
GA
3372022-11-19 Jakub Jelinek <jakub@redhat.com>
338
339 * c-cppbuiltin.cc (c_cpp_builtins): Bump __cpp_constexpr
340 value from 202207L to 202211L.
341
3422022-11-19 Jeff Chapman II <jchapman@lock3software.com>
343 Andrew Sutton <asutton@lock3software.com>
344 Andrew Marmaduke <amarmaduke@lock3software.com>
345 Michael Lopez <mlopez@lock3software.com>
346 Jason Merrill <jason@redhat.com>
347
348 * c.opt: Add contracts flags.
349 * c-cppbuiltin.cc (c_cpp_builtins): Add contracts feature-test
350 macros.
351
80909529
GA
3522022-11-16 Marek Polacek <polacek@redhat.com>
353
354 PR c++/106649
355 * c-cppbuiltin.cc (c_cpp_builtins): Update value of __cpp_constexpr for
356 C++23.
357 * c-opts.cc (c_common_post_options): Set warn_invalid_constexpr
358 depending on cxx_dialect.
359 * c.opt (Winvalid-constexpr): New option.
360
3612022-11-16 Jakub Jelinek <jakub@redhat.com>
362
363 * c-common.def (CONCEPT_DECL): New tree, moved here from
364 cp-tree.def.
365 * c-common.cc (c_common_init_ts): Handle CONCEPT_DECL.
366 * c-attribs.cc (handle_deprecated_attribute): Allow deprecated
367 attribute on CONCEPT_DECL.
368
cdc34229
GA
3692022-11-15 Lewis Hyatt <lhyatt@gmail.com>
370
371 * c-opts.cc (c_finish_options): Use special_fname_builtin () rather
372 than a hard-coded string.
373
83d400bd
GA
3742022-11-15 Jakub Jelinek <jakub@redhat.com>
375
376 * c-cppbuiltin.cc (c_cpp_builtins): Bump C++23
377 __cpp_multidimensional_subscript macro value to 202211L.
378
3792022-11-15 Patrick Palka <ppalka@redhat.com>
380
381 PR c++/107638
382 * c-lex.cc (c_common_has_attribute): Return 1 for init_priority
383 iff SUPPORTS_INIT_PRIORITY.
384
3852022-11-14 Martin Liska <mliska@suse.cz>
386
387 Revert:
388 2022-11-09 Martin Liska <mliska@suse.cz>
389
390 * c-target.def: Port to RST.
391
30d77d49
GA
3922022-11-12 Joseph Myers <joseph@codesourcery.com>
393
394 * c-common.cc (c_common_reswords): Use D_C2X instead of D_CXXONLY.
395
5b6ce16a
GA
3962022-11-11 Jonathan Wakely <jwakely@redhat.com>
397
398 PR c/85487
399 * c-pragma.cc (handle_pragma_ignore): New function.
400 (init_pragma): Register region and endregion pragmas.
401
1cdfd0e5
GA
4022022-11-09 Martin Liska <mliska@suse.cz>
403
404 * c-target.def: Port to RST.
405
05788e9b
GA
4062022-11-05 Lewis Hyatt <lhyatt@gmail.com>
407
408 PR preprocessor/55971
409 * c-ppoutput.cc (adjust_for_newlines): Update comment.
410
d29260ce
GA
4112022-11-03 Jason Merrill <jason@redhat.com>
412
413 * c-opts.cc (c_common_post_options): -fconcepts no longer implies
414 -fconcepts-ts before C++20.
415
3055829a
GA
4162022-10-28 Joseph Myers <joseph@codesourcery.com>
417
418 * c-common.cc (def_fn_type): Call build_function_type for
419 zero-argument variable-argument function.
420 (c_common_nodes_and_builtins): Build default_function_type with
421 build_function_type.
422 * c.opt (fallow-parameterless-variadic-functions): Mark as ignored
423 option.
424
4252022-10-28 Joseph Myers <joseph@codesourcery.com>
426
427 PR c/61469
428 * c-common.h (ENUM_UNDERLYING_TYPE, ENUM_FIXED_UNDERLYING_TYPE_P):
429 New. Moved from cp/cp-tree.h.
430 * c-warn.cc (warnings_for_convert_and_check): Do not consider
431 conversions to enum with underlying type bool to overflow.
432
486a5037
GA
4332022-10-26 Marek Polacek <polacek@redhat.com>
434
435 PR c++/106393
436 * c.opt (Wdangling-reference): New.
437
87f9c4a4
GA
4382022-10-19 Joseph Myers <joseph@codesourcery.com>
439
440 * c-format.h (enum format_lengths): Add FMT_LEN_w8, FMT_LEN_w16,
441 FMT_LEN_w32, FMT_LEN_w64, FMT_LEN_wf8, FMT_LEN_wf16, FMT_LEN_wf32
442 and FMT_LEN_wf64.
443 (NOARGUMENTS, NOLENGTHS): Update definitions.
444 (T_I8, T2X_I8, T_I16, T2X_I16, T_I32, T2X_I32, T_I64, T2X_I64)
445 (T_U8, T2X_U8, T_U16, T2X_U16, T_U32, T2X_U32, T_U64, T2X_U64)
446 (T_IF8, T2X_IF8, T_IF16, T2X_IF16, T_IF32, T2X_IF32, T_IF64)
447 (T2X_IF64, T_UF8, T2X_UF8, T_UF16, T2X_UF16, T_UF32, T2X_UF32)
448 (T_UF64, T2X_UF64): New macros.
449 * c-format.cc (printf_length_specs, scanf_length_specs): Add wN
450 and wfN length modifiers.
451 (print_char_table, scan_char_table): Add entries using wN and wfN
452 length modifiers.
453
21de009f
GA
4542022-10-18 Joseph Myers <joseph@codesourcery.com>
455
456 PR c/36113
457 * c-common.cc (c_common_type_for_size): Add fallback to
458 widest_unsigned_literal_type_node or
459 widest_integer_literal_type_node for precision that may not
460 exactly match the precision of those types.
461
baeec7cc
GA
4622022-10-14 Jakub Jelinek <jakub@redhat.com>
463
464 * c-cppbuiltin.cc (c_cpp_builtins): If bfloat16_type_node,
465 predefine __BFLT16_*__ macros and for C++23 also
466 __STDCPP_BFLOAT16_T__. Predefine bfloat16_type_node related
467 macros for -fbuilding-libgcc.
468 * c-lex.cc (interpret_float): Handle CPP_N_BFLOAT16.
469
4702022-10-14 Jakub Jelinek <jakub@redhat.com>
471
472 PR middle-end/323
473 PR c++/107097
474 * c-common.def (EXCESS_PRECISION_EXPR): Remove comment part about
475 the tree being specific to C/ObjC.
476 * c-opts.cc (c_common_post_options): Handle flag_excess_precision
477 in C++ the same as in C.
478 * c-lex.cc (interpret_float): Set const_type to excess_precision ()
479 even for C++.
480
621a911d
GA
4812022-10-13 Joseph Myers <joseph@codesourcery.com>
482
483 * c-cppbuiltin.cc (builtin_define_float_constants): Do not use
484 value 2 for *_IS_IEC_60559.
485
781f477a
GA
4862022-10-12 Lewis Hyatt <lhyatt@gmail.com>
487
488 PR preprocessor/60014
489 PR preprocessor/60723
490 * c-ppoutput.cc (class token_streamer): Remove member
491 line_marker_emitted to...
492 (token_streamer::stream): ...a local variable here. Set
493 print.prev_was_system_token on all code paths.
494
27bfe54e
GA
4952022-10-10 Nathan Sidwell <nathan@acm.org>
496
497 * c-opts.cc (c_common_post_options): Bump abi to 18.
498
4992022-10-10 Marek Polacek <polacek@redhat.com>
500
501 PR c++/106937
502 * c-pretty-print.cc (pp_c_specifier_qualifier_list): Print only GNU
503 attributes here.
504 (c_pretty_printer::direct_abstract_declarator): Print the standard [[]]
505 attributes here.
506 (pp_c_attributes): Remove.
507 (pp_c_attributes_display): Print the [[]] form if appropriate. Use
508 get_attribute_name. Don't print a trailing space when printing the
509 [[]] form.
510 * c-pretty-print.h (pp_c_attributes): Remove.
511
9ff6c33e
GA
5122022-10-07 Qing Zhao <qing.zhao@oracle.com>
513
514 * c-attribs.cc (handle_strict_flex_array_attribute): New function.
515 (c_common_attribute_table): New item for strict_flex_array.
516 * c.opt: (fstrict-flex-arrays): New option.
517 (fstrict-flex-arrays=): New option.
518
5192022-10-07 Martin Liska <mliska@suse.cz>
520
521 * name-hint.h: Use std::move.
522
5232022-10-07 Jakub Jelinek <jakub@redhat.com>
524
525 * c-common.cc (attribute_fallthrough_p): Lookup fallthrough attribute
526 only in gnu namespace or as standard attribute, treat fallthrough
527 attributes in other namespaces like any other unknown attribute.
528
629d04d3
GA
5292022-10-06 Joseph Myers <joseph@codesourcery.com>
530
531 * c-common.cc (c_common_reswords): Mark typeof as D_EXT11. Add
532 typeof_unqual.
533 * c-common.h (enum rid): Add RID_TYPEOF_UNQUAL.
534 (D_EXT11): New macro. Values of subsequent macros updated.
535
5362022-10-06 Jakub Jelinek <jakub@redhat.com>
537
538 PR c++/106654
539 * c-attribs.cc (handle_assume_attribute): New function.
540 (c_common_attribute_table): Add entry for assume attribute.
541 * c-lex.cc (c_common_has_attribute): Handle
542 __have_cpp_attribute (assume).
543
85872a69
GA
5442022-10-04 Jakub Jelinek <jakub@redhat.com>
545
546 * c-omp.cc (c_omp_directives): Uncomment begin declare target
547 entry.
548
69fd6dcc
GA
5492022-10-03 Patrick Palka <ppalka@redhat.com>
550
551 * c-common.cc (c_common_reswords): Use RID_IS_SAME instead of
552 RID_IS_SAME_AS.
553
5542022-10-03 Joseph Myers <joseph@codesourcery.com>
555
556 * c-cppbuiltin.cc (builtin_define_float_constants): Do not
557 special-case __*_EPSILON__ setting for IBM long double for C2x.
558
3a221b73
GA
5592022-09-30 Patrick Palka <ppalka@redhat.com>
560
561 * c-common.cc (c_common_reswords): Use cp/cp-trait.def to handle
562 C++ traits.
563 * c-common.h (enum rid): Likewise.
564
bbdcdf5c
GA
5652022-09-29 Joseph Myers <joseph@codesourcery.com>
566
567 * c-lex.cc (c_common_has_attribute): Handle noreturn attribute for
568 C.
569
5702022-09-29 Patrick Palka <ppalka@redhat.com>
571
572 * c-common.cc (c_common_reswords): Add __remove_cv,
573 __remove_reference and __remove_cvref.
574 * c-common.h (enum rid): Add RID_REMOVE_CV, RID_REMOVE_REFERENCE
575 and RID_REMOVE_CVREF.
576
1f16a020
GA
5772022-09-27 Marek Polacek <polacek@redhat.com>
578
579 PR c++/101165
580 PR c++/106882
581 * c-cppbuiltin.cc (c_cpp_builtins): Define __cpp_implicit_move.
582
5832022-09-27 Marek Polacek <polacek@redhat.com>
584
585 * c-format.cc (c_keywords): Drop nothrow.
586
5872022-09-27 Jakub Jelinek <jakub@redhat.com>
588
589 PR c++/106651
590 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
591 __cpp_static_call_operator=202207L for C++23.
592
5932022-09-27 Jakub Jelinek <jakub@redhat.com>
594
595 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ASSUME,
596 PRAGMA_OMP_ASSUMES and PRAGMA_OMP_BEGIN. Rename
597 PRAGMA_OMP_END_DECLARE_TARGET to PRAGMA_OMP_END.
598 * c-pragma.cc (omp_pragmas): Add assumes and begin.
599 For end rename PRAGMA_OMP_END_DECLARE_TARGET to PRAGMA_OMP_END.
600 (omp_pragmas_simd): Add assume.
601 * c-common.h (c_omp_directives): Declare.
602 * c-omp.cc (omp_directives): Rename to ...
603 (c_omp_directives): ... this. No longer static. Uncomment
604 assume, assumes, begin assumes and end assumes entries.
605 In end declare target entry rename PRAGMA_OMP_END_DECLARE_TARGET
606 to PRAGMA_OMP_END.
607 (c_omp_categorize_directive): Adjust for omp_directives to
608 c_omp_directives renaming.
609
6102022-09-27 Jakub Jelinek <jakub@redhat.com>
611
612 PR c++/106652
613 PR c++/85518
614 * c-common.cc (c_common_reswords): Change _Float{16,32,64,128} and
615 _Float{32,64,128}x flags from D_CONLY to 0.
616 (shorten_binary_op): Punt if common_type returns error_mark_node.
617 (shorten_compare): Likewise.
618 (c_common_nodes_and_builtins): For C++ record _Float{16,32,64,128}
619 and _Float{32,64,128}x builtin types if available. For C++
620 clear float128t_type_node.
621 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
622 __STDCPP_FLOAT{16,32,64,128}_T__ for C++23 if supported.
623 * c-lex.cc (interpret_float): For q/Q suffixes prefer
624 float128t_type_node over float128_type_node. Allow
625 {f,F}{16,32,64,128} suffixes for C++ if supported with pedwarn
626 for C++20 and older. Allow {f,F}{32,64,128}x suffixes for C++
627 with pedwarn. Don't call excess_precision_type for C++.
628
220c4d8e
GA
6292022-09-26 Marek Polacek <polacek@redhat.com>
630
631 PR c++/106656
632 * c-cppbuiltin.cc (c_cpp_builtins): Update value of __cpp_char8_t
633 for C++20.
634
4afaeaab
GA
6352022-09-23 Marek Polacek <polacek@redhat.com>
636
637 PR c++/106784
638 * c-common.cc (c_common_reswords): Add __is_convertible and
639 __is_nothrow_convertible.
640 * c-common.h (enum rid): Add RID_IS_CONVERTIBLE and
641 RID_IS_NOTHROW_CONVERTIBLE.
642
279c6715
GA
6432022-09-22 David Malcolm <dmalcolm@redhat.com>
644
645 PR c/106830
646 * c-warn.cc (check_for_xor_used_as_pow): Don't try checking
647 values that don't fit in uhwi.
648
d0fc05e8
GA
6492022-09-15 Richard Biener <rguenther@suse.de>
650
651 * c-common.h (build_void_list_node): Remove.
652 * c-common.cc (c_common_nodes_and_builtins): Do not initialize
653 void_list_node.
654
861d1a11
GA
6552022-09-09 Jan-Benedict Glaw <jbglaw@lug-owl.de>
656
657 * c-format.cc (convert_format_name_to_system_name): Fix warning.
658
fe2a8ce9
GA
6592022-09-07 Joseph Myers <joseph@codesourcery.com>
660
661 * c-common.cc (c_common_reswords): Use D_C2X instead of D_CXXONLY
662 for alignas, alignof, bool, false, static_assert, thread_local and
663 true.
664
6652022-09-07 Jakub Jelinek <jakub@redhat.com>
666
667 * c.opt (Winvalid-utf8): Use ObjC instead of objC. Remove
668 " in comments" from description.
669 (Wunicode): New option.
670
25aeb922
GA
6712022-09-06 Jakub Jelinek <jakub@redhat.com>
672
673 PR c/106836
674 * c-omp.cc (c_omp_split_clauses): Handle OMP_CLAUSE_DOACROSS.
675
83f2f228
GA
6762022-09-03 Jakub Jelinek <jakub@redhat.com>
677
678 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DOACROSS.
679 * c-omp.cc (c_finish_omp_depobj): Check also for OMP_CLAUSE_DOACROSS
680 clause and diagnose it. Don't handle OMP_CLAUSE_DEPEND_SOURCE and
681 OMP_CLAUSE_DEPEND_SINK. Assert kind is not OMP_CLAUSE_DEPEND_INVALID.
682
c64b0947
GA
6832022-09-02 David Malcolm <dmalcolm@redhat.com>
684
685 PR c/90885
686 * c-common.h (check_for_xor_used_as_pow): New decl.
687 * c-lex.cc (c_lex_with_flags): Add DECIMAL_INT to flags as appropriate.
688 * c-warn.cc (check_for_xor_used_as_pow): New.
689 * c.opt (Wxor-used-as-pow): New.
690
bb0a1556
GA
6912022-09-01 Jason Merrill <jason@redhat.com>
692
693 * c-common.cc (c_common_nodes_and_builtins): Set TREE_STRING_FLAG on
694 char8_t.
695 (braced_list_to_string): Check for char-sized elements.
696
6972022-09-01 Jakub Jelinek <jakub@redhat.com>
698
699 PR c++/106655
700 * c.opt (-Winvalid-utf8): New warning.
701 * c-opts.cc (c_common_handle_option) <case OPT_finput_charset_>:
702 Set cpp_opts->cpp_input_charset_explicit.
703 (c_common_post_options): If -finput-charset=UTF-8 is explicit
704 in C++23, enable -Winvalid-utf8 by default and if -pedantic
705 or -pedantic-errors, make it a pedwarn.
706
542c60c4
GA
7072022-08-31 Joseph Myers <joseph@codesourcery.com>
708
709 * c-attribs.cc (handle_deprecated_attribute): Check and pedwarn
710 for LABEL_DECL.
711 * c-common.cc (c_add_case_label): Add argument ATTRS. Call
712 decl_attributes.
713 * c-common.h (do_case, c_add_case_label): Update declarations.
714 * c-lex.cc (c_common_has_attribute): For C, produce a result of
715 201910 for fallthrough and 202106 for maybe_unused.
716
16f542d6
GA
7172022-08-26 Marek Polacek <polacek@redhat.com>
718
719 PR c++/81159
720 * c.opt (Wself-move): New option.
721
7222022-08-26 Jakub Jelinek <jakub@redhat.com>
723
724 * c-common.cc (check_builtin_function_arguments): Handle
725 BUILT_IN_ISSIGNALING.
726
7272022-08-26 Jakub Jelinek <jakub@redhat.com>
728
729 PR c++/106648
730 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
731 __cpp_named_character_escapes to 202207L.
732
5d4389dc
GA
7332022-08-25 Marek Polacek <polacek@redhat.com>
734
735 * c-common.cc (c_common_reswords): Enable nullptr in C2X.
736 (c_common_nodes_and_builtins): Create the built-in node for nullptr.
737 * c-common.h (enum c_tree_index): Add CTI_NULLPTR, CTI_NULLPTR_TYPE.
738 (struct c_common_resword): Resize the disable member.
739 (D_C2X): Add.
740 (nullptr_node): Define.
741 (nullptr_type_node): Define.
742 (NULLPTR_TYPE_P): Define.
743 * c-pretty-print.cc (c_pretty_printer::simple_type_specifier): Handle
744 NULLPTR_TYPE.
745 (c_pretty_printer::direct_abstract_declarator): Likewise.
746 (c_pretty_printer::constant): Likewise.
747
47a61e65
GA
7482022-08-16 Tom Honermann <tom@honermann.net>
749
750 PR c++/106423
751 * c-opts.cc (c_common_post_options): Disable -Wc++20-compat
752 diagnostics in C++20 and later.
753 * c.opt (Wc++20-compat): Enable hooks for the preprocessor.
754
5cd525f0
GA
7552022-08-11 Marek Polacek <polacek@redhat.com>
756
757 PR middle-end/102633
758 * c-gimplify.cc (c_gimplify_expr) <case DECL_EXPR>: Don't call
759 suppress_warning here.
760
5f17badb
GA
7612022-08-08 Tom Honermann <tom@honermann.net>
762
763 PR preprocessor/106426
764 * c-opts.cc (c_common_post_options): Assign cpp_opts->unsigned_utf8char
765 subject to -fchar8_t, -fsigned-char, and/or -funsigned-char.
766
7672022-08-08 Tom Honermann <tom@honermann.net>
768
769 * c-lex.cc (lex_string, lex_charconst): Use char8_t as the type
770 of CPP_UTF8CHAR and CPP_UTF8STRING when char8_t support is
771 enabled.
772 * c-opts.cc (c_common_post_options): Set flag_char8_t if
773 targeting C2x.
774
4a7274dd
GA
7752022-07-31 Lewis Hyatt <lhyatt@gmail.com>
776
777 PR c++/66290
778 * c-common.h: Rename global done_lexing to
779 override_libcpp_locations.
780 * c-common.cc (c_cpp_diagnostic): Likewise.
781 * c-opts.cc (c_common_finish): Set override_libcpp_locations
782 (formerly done_lexing) immediately prior to calling cpp_finish ().
783
1e2c5f4c
GA
7842022-07-27 Lewis Hyatt <lhyatt@gmail.com>
785
786 * c-ppoutput.cc (token_streamer::stream): Update input_location
787 prior to streaming each token.
788
0e6fa997
GA
7892022-07-23 Immad Mir <mirimmad@outlook.com>
790
791 * c-attribs.cc: (c_common_attribute_table): add three new attributes
792 namely: fd_arg, fd_arg_read and fd_arg_write.
793 (handle_fd_arg_attribute): New.
794
bdc7b765
GA
7952022-07-15 Marek Polacek <polacek@redhat.com>
796
797 PR c++/104477
798 * c-common.cc (c_common_reswords): Add
799 __reference_constructs_from_temporary and
800 __reference_converts_from_temporary.
801 * c-common.h (enum rid): Add RID_REF_CONSTRUCTS_FROM_TEMPORARY and
802 RID_REF_CONVERTS_FROM_TEMPORARY.
803
8042022-07-15 Jonathan Wakely <jwakely@redhat.com>
805
806 * c-format.cc (class range_label_for_format_type_mismatch):
807 Adjust to new label_text API.
808
c72d4714
GA
8092022-07-11 Lewis Hyatt <lhyatt@gmail.com>
810
811 PR preprocessor/106252
812 * c-pragma.cc (handle_pragma_diagnostic_impl): Don't look up the
813 option argument prior to verifying the option was found.
814
6345c414
GA
8152022-07-07 David Malcolm <dmalcolm@redhat.com>
816
817 * c-format.cc (range_label_for_format_type_mismatch::get_text):
818 Update for removal of label_text::maybe_free in favor of automatic
819 memory management.
820
4bc92c3b
GA
8212022-07-06 Lewis Hyatt <lhyatt@gmail.com>
822
823 PR preprocessor/53920
824 PR c++/53431
825 * c-common.cc (c_option_is_from_cpp_diagnostics): New function.
826 * c-common.h (c_option_is_from_cpp_diagnostics): Declare.
827 (c_pp_stream_token): Declare.
828 * c-ppoutput.cc (init_pp_output): Refactor logic about skipping
829 pragmas to...
830 (should_output_pragmas): ...here. New function.
831 (token_streamer::stream): Support handling early pragmas.
832 (do_line_change): Likewise.
833 (c_pp_stream_token): New function.
834 * c-pragma.cc (struct pragma_diagnostic_data): New helper class.
835 (pragma_diagnostic_lex_normal): New function. Moved logic for
836 interpreting GCC diagnostic pragmas here.
837 (pragma_diagnostic_lex_pp): New function for parsing diagnostic pragmas
838 directly from libcpp.
839 (handle_pragma_diagnostic): Refactor into helper function...
840 (handle_pragma_diagnostic_impl): ...here. New function.
841 (handle_pragma_diagnostic_early): New function.
842 (handle_pragma_diagnostic_early_pp): New function.
843 (struct pragma_ns_name): Renamed to...
844 (struct pragma_pp_data): ...this. Add new "early_handler" member.
845 (c_register_pragma_1): Support early pragmas in the preprocessor.
846 (c_register_pragma_with_early_handler): New function.
847 (c_register_pragma): Support the new early handlers in struct
848 internal_pragma_handler.
849 (c_register_pragma_with_data): Likewise.
850 (c_register_pragma_with_expansion): Likewise.
851 (c_register_pragma_with_expansion_and_data): Likewise.
852 (c_invoke_early_pragma_handler): New function.
853 (c_pp_invoke_early_pragma_handler): New function.
854 (init_pragma): Add early pragma support for diagnostic pragmas.
855 * c-pragma.h (struct internal_pragma_handler): Add new early handler
856 members.
857 (c_register_pragma_with_early_handler): Declare.
858 (c_invoke_early_pragma_handler): Declare.
859 (c_pp_invoke_early_pragma_handler): Declare.
860
d1f3a3ff
GA
8612022-07-05 Marek Polacek <polacek@redhat.com>
862
863 PR c++/105626
864 * c-format.cc (check_format_arg): Don't emit -Wformat warnings with
865 u8 strings.
866
ed974488
GA
8672022-07-01 Marek Polacek <polacek@redhat.com>
868
869 PR c++/106111
870 * c-common.h (enum rid): Update RID_LAST_CXX20.
871
976196b3
GA
8722022-06-30 Jonathan Wakely <jwakely@redhat.com>
873
874 * known-headers.cc (get_stdlib_header_for_name): Add <time.h>
875 names.
876
84c2131d
GA
8772022-06-24 Jason Merrill <jason@redhat.com>
878
879 PR c++/87729
880 PR c++/20423
881 * c.opt (Woverloaded-virtual): Add levels, include in -Wall.
882
4390e7bf
GA
8832022-06-18 Jakub Jelinek <jakub@redhat.com>
884
885 * c-ubsan.cc (ubsan_instrument_division, ubsan_instrument_shift):
886 Use flag_sanitize_trap & SANITIZE_??? instead of
887 flag_sanitize_undefined_trap_on_error. If 2 sanitizers are involved
888 and flag_sanitize_trap differs for them, emit __builtin_trap only
889 for the comparison where trap is requested.
890 (ubsan_instrument_vla, ubsan_instrument_return): Use
891 lag_sanitize_trap & SANITIZE_??? instead of
892 flag_sanitize_undefined_trap_on_error.
893
c3642271
GA
8942022-06-13 Jason Merrill <jason@redhat.com>
895
896 * c-ubsan.cc (ubsan_instrument_return): Use BUILTINS_LOCATION.
897
d9176e64
GA
8982022-05-27 Marek Polacek <polacek@redhat.com>
899
900 PR c/90658
901 * c-attribs.cc (get_priority): Check FUNCTION_DECL.
902
9032022-05-27 Jakub Jelinek <jakub@redhat.com>
904
905 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ENTER.
906
57f2ce6a
GA
9072022-05-20 David Malcolm <dmalcolm@redhat.com>
908
909 * c-format.cc: Replace uses of "FINAL" and "OVERRIDE" with "final"
910 and "override".
911 * c-pretty-print.h: Likewise.
912
1cda629f
GA
9132022-05-18 Marek Polacek <polacek@redhat.com>
914
915 PR c/105131
916 * c.opt (Wenum-int-mismatch): New.
917
9182022-05-18 Marek Polacek <polacek@redhat.com>
919
920 PR c++/105497
921 * c-warn.cc (c_do_switch_warnings): Don't warn about unhandled
922 enumerator when it was marked with attribute unused.
923
9242022-05-18 Eric Botcazou <ebotcazou@adacore.com>
925
926 * c-ada-spec.cc (dump_ada_node) <COMPLEX_TYPE>: Deal with usual
927 floating-point complex types.
928 <POINTER_TYPE>: Do not use limited_with clause if the designated
929 type is a scalar type.
930
3d9439b1
GA
9312022-05-17 Jakub Jelinek <jakub@redhat.com>
932
933 * c-omp.cc (c_finish_omp_depobj): Handle
934 OMP_CLAUSE_DEPEND_INOUTSET.
935
702bd11f
GA
9362022-05-16 Jason Merrill <jason@redhat.com>
937
938 PR c/105492
939 * c-attribs.cc (handle_mode_attribute): Don't fix broken typedefs
940 here.
941
9422022-05-16 Martin Liska <mliska@suse.cz>
943
944 * c-common.cc (ARRAY_SIZE): Use ARRAY_SIZE.
945 (c_common_nodes_and_builtins): Likewise.
946 * c-format.cc (check_tokens): Likewise.
947 (check_plain): Likewise.
948 * c-pragma.cc (c_pp_lookup_pragma): Likewise.
949 (init_pragma): Likewise.
950 * known-headers.cc (get_string_macro_hint): Likewise.
951 (get_stdlib_header_for_name): Likewise.
952 * c-attribs.cc: Likewise.
953
9df4ffe4
GA
9542022-05-13 Richard Biener <rguenther@suse.de>
955
956 * c-omp.cc: Remove gimple-fold.h include.
957
49ace834
GA
9582022-05-12 Jakub Jelinek <jakub@redhat.com>
959
960 * c-common.h (enum rid): Add RID_OMP_ALL_MEMORY.
961 * c-omp.cc (c_finish_omp_depobj): Don't build_fold_addr_expr
962 if null_pointer_node.
963
d0d513b5
GA
9642022-05-11 Martin Liska <mliska@suse.cz>
965
966 PR target/105355
967 * c-opts.cc (c_common_handle_option): Change option name.
968 * c.opt: Remove Joined and use Separate option.
969
bd022ff9
GA
9702022-05-09 Alex Coplan <alex.coplan@arm.com>
971
972 * c-common.h (get_dump_info): Delete.
973 * c-gimplify.cc (c_genericize): Get TDI_original dump file info
974 from the global dump_manager instead of the (now obsolete)
975 get_dump_info.
976 * c-opts.cc (original_dump_file): Delete.
977 (original_dump_flags): Delete.
978 (c_common_parse_file): Switch to using global dump_manager to
979 manage the original dump file; fix leak of dump file.
980 (get_dump_info): Delete.
981
a1947c92
GA
9822022-05-07 Marek Polacek <polacek@redhat.com>
983
984 PR c++/101833
985 PR c++/47634
986 * c-attribs.cc (positional_argument): Pass POS by reference. Deal
987 with FN being either a function declaration or function type. Use
988 maybe_adjust_arg_pos_for_attribute.
989 * c-common.cc (check_function_arguments): Maybe pass FNDECL down to
990 check_function_format.
991 * c-common.h (maybe_adjust_arg_pos_for_attribute): Declare.
992 (positional_argument): Adjust.
993 * c-format.cc (get_constant): Rename to ...
994 (validate_constant): ... this. Take EXPR by reference. Return bool
995 instead of tree.
996 (handle_format_arg_attribute): Don't overwrite FORMAT_NUM_EXPR by the
997 return value of validate_constant.
998 (decode_format_attr): Don't overwrite FORMAT_NUM_EXPR and
999 FIRST_ARG_NUM_EXPR by the return value of validate_constant.
1000 (check_function_format): Adjust a parameter name.
1001 (handle_format_attribute): Maybe pass FNDECL down to decode_format_attr.
1002
3e7db517
GA
10032022-05-04 Marek Polacek <polacek@redhat.com>
1004
1005 * c-warn.cc (warnings_for_convert_and_check): Convert constants of type
1006 char to int.
1007
95874f95
GA
10082022-04-30 Jason Merrill <jason@redhat.com>
1009
1010 PR c/100545
1011 * c-attribs.cc (handle_mode_attribute): Copy attributes, aligned,
1012 and typedef.
1013 * c-common.cc (set_underlying_type): Add assert.
1014
01ad093b
GA
10152022-04-26 Patrick Palka <ppalka@redhat.com>
1016
1017 PR c++/105304
1018 * c-common.cc (verify_tree) [restart]: Move up to before the
1019 NULL test.
1020
da066c42
GA
10212022-04-11 Jakub Jelinek <jakub@redhat.com>
1022
1023 PR c++/105186
1024 * c-common.cc (c_common_nodes_and_builtins): After registering __int%d
1025 and __int%d__ builtin types, initialize corresponding ridpointers
1026 entry.
1027
150ab50f
GA
10282022-03-30 Marek Polacek <polacek@redhat.com>
1029
1030 PR c++/101030
1031 * c-warn.cc (conversion_warning) <case COND_EXPR>: Don't call
1032 conversion_warning when OP1 is null.
1033
10342022-03-30 Thomas Schwinge <thomas@codesourcery.com>
1035
1036 * c.opt (Wc++11-extensions, Wc++14-extensions, Wc++17-extensions)
1037 (Wc++20-extensions, Wc++23-extensions): Remove 'LangEnabledBy'
1038 option properties.
1039
10402022-03-30 Thomas Schwinge <thomas@codesourcery.com>
1041
1042 * c.opt (Wuse-after-free): Remove.
1043
10442022-03-30 Thomas Schwinge <thomas@codesourcery.com>
1045
1046 * c.opt (Warray-bounds): Remove.
1047
d2906412
GA
10482022-03-26 Thomas Schwinge <thomas@codesourcery.com>
1049
1050 * c.opt: Properly quote comment.
1051
31e989a2
GA
10522022-03-25 Eric Botcazou <ebotcazou@adacore.com>
1053
1054 * c-ada-spec.cc (dump_ada_import): Deal with the "section" attribute
1055 (dump_ada_node) <POINTER_TYPE>: Do not modify and pass the name, but
1056 the referenced type instead. Deal with the anonymous original type
1057 of a typedef'ed type. In the actual access case, follow the chain
1058 of external subtypes.
1059 <TYPE_DECL>: Tidy up control flow.
1060
d156bb87
GA
10612022-03-21 Qian Jianhua <qianjh@cn.fujitsu.com>
1062
1063 * c-ada-spec.cc: Change array length
1064
d7f00da1
GA
10652022-03-19 Arthur Cohen <arthur.cohen@embecosm.com>
1066
1067 * c-common.cc (c_family_tests): Call the new tests.
1068 * c-common.h (c_diagnostic_tests): Declare.
1069 (c_opt_problem_cc_tests): Likewise.
1070
10712022-03-19 Jakub Jelinek <jakub@redhat.com>
1072
1073 PR c++/101515
1074 * c-pretty-print.cc (c_fold_indirect_ref_for_warn): For C++ don't
1075 return COMPONENT_REFs with FIELD_DECLs whose containing scope can't
1076 be printed.
1077
9fc8f278
GA
10782022-03-16 Christophe Lyon <christophe.lyon@arm.com>
1079 Roger Sayle <roger@nextmovesoftware.com>
1080
1081 PR c/98198
1082 * c-attribs.cc (decl_or_type_attrs): Add error_mark_node check.
1083
10842022-03-16 Patrick Palka <ppalka@redhat.com>
1085
1086 PR c++/96780
1087 * c.opt: Add -ffold-simple-inlines.
1088
b9756c08
GA
10892022-03-13 Tobias Burnus <tobias@codesourcery.com>
1090
1091 * c-target.def (check_string_object_format_arg): Fix description typo.
1092
57eeedda
GA
10932022-03-12 Thomas Schwinge <thomas@codesourcery.com>
1094
1095 PR other/65095
1096 * c-common.h (c_omp_map_clause_name): Remove.
1097 * c-omp.cc (c_omp_map_clause_name): Remove.
1098
8cc4f9cd
GA
10992022-03-09 Jakub Jelinek <jakub@redhat.com>
1100
1101 PR c/104711
1102 * c-opts.cc (c_common_post_options): Don't enable
1103 -Wshift-negative-value from -Wextra for C++20 or later.
1104 * c-ubsan.cc (ubsan_instrument_shift): Adjust comments.
1105 * c-warn.cc (maybe_warn_shift_overflow): Use TYPE_OVERFLOW_WRAPS
1106 instead of TYPE_UNSIGNED.
1107
e6533e2e
GA
11082022-03-07 Jakub Jelinek <jakub@redhat.com>
1109
1110 * c-attribs.cc: Fix up duplicated word issue in a comment.
1111
12d4552e
GA
11122022-03-01 Martin Liska <mliska@suse.cz>
1113
1114 PR ipa/104533
1115 * c-attribs.cc (handle_target_clones_attribute): Use
1116 get_target_clone_attr_len and report warning soon.
1117
0bdb0498
GA
11182022-02-17 Jonathan Wakely <jwakely@redhat.com>
1119
1120 * c-pragma.cc (handle_pragma_pack): Remove parameter name.
1121 (handle_pragma_weak): Likewise.
1122 (handle_pragma_scalar_storage_order): Likewise.
1123 (handle_pragma_redefine_extname): Likewise.
1124 (handle_pragma_visibility): Likewise.
1125 (handle_pragma_diagnostic): Likewise.
1126 (handle_pragma_target): Likewise.
1127 (handle_pragma_optimize): Likewise.
1128 (handle_pragma_push_options): Likewise.
1129 (handle_pragma_pop_options): Likewise.
1130 (handle_pragma_reset_options): Likewise.
1131 (handle_pragma_message): Likewise.
1132 (handle_pragma_float_const_decimal64): Likewise.
1133
cb3afcd2
GA
11342022-02-16 Jakub Jelinek <jakub@redhat.com>
1135
1136 PR c/104531
1137 * c-omp.cc (c_finish_omp_atomic): For MIN_EXPR/MAX_EXPR, try first
1138 build_binary_op with LT_EXPR and only if that doesn't return
1139 error_mark_node call build_modify_expr.
1140
11412022-02-16 Jakub Jelinek <jakub@redhat.com>
1142
1143 PR c/104510
1144 * c-common.cc (shorten_compare): Convert original arguments to
1145 the original *restype_ptr when mixing binary and decimal float.
1146
1f8a09d2
GA
11472022-02-14 Richard Biener <rguenther@suse.de>
1148
1149 PR c/104505
1150 * c-pretty-print.cc (c_pretty_printer::postfix_expression): Handle
1151 internal function calls.
1152
e8d68f0a
GA
11532022-02-11 Richard Biener <rguenther@suse.de>
1154
1155 * c-attribs.cc (c_common_attribute_table): Add entry for
1156 vector_mask.
1157 (handle_vector_mask_attribute): New.
1158
a645583d
GA
11592022-02-10 Marcel Vollweiler <marcel@codesourcery.com>
1160
1161 * c-omp.cc (c_omp_split_clauses): Added OMP_CLAUSE_HAS_DEVICE_ADDR case.
1162 * c-pragma.h (enum pragma_kind): Added 5.1 in comment.
1163 (enum pragma_omp_clause): Added PRAGMA_OMP_CLAUSE_HAS_DEVICE_ADDR.
1164
3adf509f
GA
11652022-02-09 Jason Merrill <jason@redhat.com>
1166
1167 * c-cppbuiltin.cc (c_cpp_builtins): Update values
1168 of __cpp_constexpr and __cpp_concepts for C++20.
1169
bb99171b
GA
11702022-01-24 Marek Polacek <polacek@redhat.com>
1171
1172 PR preprocessor/104030
1173 * c.opt (Wbidi-chars): Mark as EnumSet. Also accept =ucn.
1174
9dd44357
GA
11752022-01-21 Jakub Jelinek <jakub@redhat.com>
1176
1177 PR c++/104148
1178 * c-common.h (check_function_arguments_recurse): Add for_format
1179 arg.
1180 * c-common.cc (check_function_nonnull): Pass false to
1181 check_function_arguments_recurse's last argument.
1182 (check_function_arguments_recurse): Add for_format argument,
1183 if true, don't stop on warning_suppressed_p.
1184 * c-format.cc (check_format_info): Pass true to
1185 check_function_arguments_recurse's last argument.
1186
fe1ad141
GA
11872022-01-19 David Malcolm <dmalcolm@redhat.com>
1188
1189 * c-common.cc (c_common_c_tests): Rename to...
1190 (c_common_cc_tests): ...this.
1191 (c_family_tests): Update calls for .c to .cc renaming.
1192 * c-common.h (c_format_c_tests): Rename to...
1193 (c_format_cc_tests): ...this.
1194 (c_indentation_c_tests): Rename to...
1195 (c_indentation_cc_tests): ...this.
1196 (c_pretty_print_c_tests): Rename to...
1197 (c_pretty_print_cc_tests): ...this.
1198 * c-format.cc (c_format_c_tests): Rename to...
1199 (c_format_cc_tests): ...this.
1200 * c-indentation.cc (c_indentation_c_tests): Rename to...
1201 (c_indentation_cc_tests): ...this.
1202 * c-pretty-print.cc (c_pretty_print_c_tests): Rename to...
1203 (c_pretty_print_cc_tests): ...this.
1204
fc829782
GA
12052022-01-17 Martin Liska <mliska@suse.cz>
1206
1207 * c-ada-spec.cc: Rename .c names to .cc.
1208 * c-ada-spec.h: Likewise.
1209 * c-common.cc (c_build_vec_convert): Likewise.
1210 (warning_candidate_p): Likewise.
1211 * c-common.h (enum rid): Likewise.
1212 (build_real_imag_expr): Likewise.
1213 (finish_label_address_expr): Likewise.
1214 (c_get_substring_location): Likewise.
1215 (c_build_bind_expr): Likewise.
1216 (conflict_marker_get_final_tok_kind): Likewise.
1217 (c_parse_error): Likewise.
1218 (check_missing_format_attribute): Likewise.
1219 (invalid_array_size_error): Likewise.
1220 (warn_for_multistatement_macros): Likewise.
1221 (build_attr_access_from_parms): Likewise.
1222 * c-cppbuiltin.cc (c_cpp_builtins): Likewise.
1223 * c-format.cc: Likewise.
1224 * c-gimplify.cc (c_gimplify_expr): Likewise.
1225 * c-indentation.h: Likewise.
1226 * c-objc.h (objc_prop_attr_kind_for_rid): Likewise.
1227 * c-omp.cc (c_omp_predetermined_mapping): Likewise.
1228 * c-opts.cc (c_common_post_options): Likewise.
1229 (set_std_cxx23): Likewise.
1230 * c-pragma.cc (handle_pragma_redefine_extname): Likewise.
1231 * c-pretty-print.h: Likewise.
1232
12332022-01-17 Martin Liska <mliska@suse.cz>
1234
1235 * c-ada-spec.c: Moved to...
1236 * c-ada-spec.cc: ...here.
1237 * c-attribs.c: Moved to...
1238 * c-attribs.cc: ...here.
1239 * c-common.c: Moved to...
1240 * c-common.cc: ...here.
1241 * c-cppbuiltin.c: Moved to...
1242 * c-cppbuiltin.cc: ...here.
1243 * c-dump.c: Moved to...
1244 * c-dump.cc: ...here.
1245 * c-format.c: Moved to...
1246 * c-format.cc: ...here.
1247 * c-gimplify.c: Moved to...
1248 * c-gimplify.cc: ...here.
1249 * c-indentation.c: Moved to...
1250 * c-indentation.cc: ...here.
1251 * c-lex.c: Moved to...
1252 * c-lex.cc: ...here.
1253 * c-omp.c: Moved to...
1254 * c-omp.cc: ...here.
1255 * c-opts.c: Moved to...
1256 * c-opts.cc: ...here.
1257 * c-pch.c: Moved to...
1258 * c-pch.cc: ...here.
1259 * c-ppoutput.c: Moved to...
1260 * c-ppoutput.cc: ...here.
1261 * c-pragma.c: Moved to...
1262 * c-pragma.cc: ...here.
1263 * c-pretty-print.c: Moved to...
1264 * c-pretty-print.cc: ...here.
1265 * c-semantics.c: Moved to...
1266 * c-semantics.cc: ...here.
1267 * c-ubsan.c: Moved to...
1268 * c-ubsan.cc: ...here.
1269 * c-warn.c: Moved to...
1270 * c-warn.cc: ...here.
1271 * cppspec.c: Moved to...
1272 * cppspec.cc: ...here.
1273 * stub-objc.c: Moved to...
1274 * stub-objc.cc: ...here.
1275
9248ee41
GA
12762022-01-15 Martin Sebor <msebor@redhat.com>
1277
1278 PR c/63272
1279 * c.opt (-Wdangling-pointer): New option.
1280
12812022-01-15 Martin Sebor <msebor@redhat.com>
1282
1283 PR tree-optimization/80532
1284 * c.opt (-Wuse-after-free): New options.
1285
617db51d
GA
12862022-01-14 David Malcolm <dmalcolm@redhat.com>
1287
1288 * c-attribs.c (c_common_attribute_table): Add "tainted_args".
1289 (handle_tainted_args_attribute): New.
1290
ad3f0d08
GA
12912022-01-13 Anthony Sharp <anthonysharp15@gmail.com>
1292 Jason Merrill <jason@redhat.com>
1293
1294 PR c++/70417
1295 * c.opt: Added -Wmissing-template-keyword.
1296
12972022-01-13 Richard Biener <rguenther@suse.de>
1298
1299 PR c/104002
1300 * c-common.c (c_common_mark_addressable_vec): Handle TARGET_EXPR.
1301
02a8a01b
GA
13022022-01-12 Martin Liska <mliska@suse.cz>
1303
1304 PR target/103804
1305 * c-attribs.c (handle_optimize_attribute): Do not call
1306 cl_optimization_compare if we seen an error.
1307
01a254e3
GA
13082022-01-11 Jakub Jelinek <jakub@redhat.com>
1309
1310 PR c/101537
1311 PR c/103881
1312 * c-warn.c (conversion_warning): Handle BIT_AND_EXPR, BIT_IOR_EXPR
1313 and BIT_XOR_EXPR.
1314
d9450aa0
GA
13152022-01-10 Richard Biener <rguenther@suse.de>
1316
1317 PR middle-end/101530
1318 * c-common.c (c_build_shufflevector): Wrap the BIT_FIELD_REF
1319 in a TARGET_EXPR to force a temporary.
1320
11ce8d04
GA
13212022-01-06 Marek Polacek <polacek@redhat.com>
1322
1323 PR c++/103758
1324 * c-pragma.c (handle_pragma_scalar_storage_order): Use %< %> in
1325 diagnostic messages.
1326 (handle_pragma_diagnostic): Likewise.
1327
a4ae8c37
GA
13282022-01-03 Marek Polacek <polacek@redhat.com>
1329
1330 PR c++/103758
1331 * c-format.c (check_tokens): Accept "decl-specifier*".
1332
13332022-01-03 Jakub Jelinek <jakub@redhat.com>
1334
1335 PR c++/103600
1336 * c-attribs.c (handle_non_overlapping_attribute): New function.
1337 (c_common_attribute_table): Add "non overlapping" attribute.
1338
84790a9d
GA
13392021-12-30 Jakub Jelinek <jakub@redhat.com>
1340
1341 PR c++/103012
1342 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Perform
1343 cpp_define_unused/cpp_undef calls with forced token locations
1344 BUILTINS_LOCATION.
1345
d1e111da
GA
13462021-12-27 Patrick Palka <ppalka@redhat.com>
1347
1348 PR c++/103700
1349 * c-common.c (pointer_int_sum): When quiet, return
1350 error_mark_node for an incomplete pointed-to type and don't
1351 call size_in_bytes_loc.
1352
2554e2da
GA
13532021-12-17 Jason Merrill <jason@redhat.com>
1354
1355 PR c++/103681
1356 * c-opts.c (c_common_post_options): Update defaults.
1357
774269aa
GA
13582021-12-16 Martin Liska <mliska@suse.cz>
1359
1360 PR target/103709
1361 * c-pragma.c (handle_pragma_pop_options): Do not check
1362 global options modification when an error is seen in parsing
1363 of options (pragmas or attributes).
1364
c8dcf64b
GA
13652021-12-12 Jonathan Wakely <jwakely@redhat.com>
1366
1367 * known-headers.cc: Define INCLUDE_MEMORY instead of
1368 INCLUDE_UNIQUE_PTR.
1369 * name-hint.h: Likewise.
1370 (class name_hint): Use std::unique_ptr instead of gnu::unique_ptr.
1371
4b4839e3
GA
13722021-12-09 Jakub Jelinek <jakub@redhat.com>
1373
1374 PR pch/71934
1375 * c-pch.c (c_common_no_more_pch): Pass a temporary void * var
1376 with NULL value instead of NULL to host_hooks.gt_pch_use_address.
1377
03a9bd05
GA
13782021-12-03 Jakub Jelinek <jakub@redhat.com>
1379
1380 PR pch/71934
1381 * c-pch.c (struct c_pch_validity): Remove pch_init member.
1382 (pch_init): Don't initialize v.pch_init.
1383 (c_common_valid_pch): Don't warn and punt if .text addresses change.
1384
40fa651e
GA
13852021-12-01 Jason Merrill <jason@redhat.com>
1386
1387 PR c++/103310
1388 * c.opt: Add -fconstexpr-fp-except.
1389
87cd82c8
GA
13902021-11-29 Richard Biener <rguenther@suse.de>
1391
1392 * c-format.c (check_format_string): Remove spurious
1393 gcc_unreachable.
1394
13952021-11-29 Richard Biener <rguenther@suse.de>
1396
1397 * c-opts.c (c_common_post_options): Remove unreachable return.
1398 * c-pragma.c (handle_pragma_target): Likewise.
1399 (handle_pragma_optimize): Likewise.
1400
091ccc06
GA
14012021-11-25 Jakub Jelinek <jakub@redhat.com>
1402
1403 PR c++/102611
1404 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
1405 default for C++23 regardless of warn_deprecated.
1406 * c-cppbuiltin.c (c_cpp_builtins): Predefine
1407 __cpp_multidimensional_subscript=202110L for C++23.
1408
e1d43592
GA
14092021-11-23 Martin Sebor <msebor@redhat.com>
1410
1411 PR middle-end/88232
1412 * c.opt: Add -Winfinite-recursion.
1413
9c077398
GA
14142021-11-19 Martin Sebor <msebor@redhat.com>
1415
1416 PR c++/33925
1417 PR c/102867
1418 * c-common.c (decl_with_nonnull_addr_p): Call maybe_nonzero_address
1419 and improve handling tof defined symbols.
1420
14212021-11-19 Martin Liska <mliska@suse.cz>
1422
1423 Revert:
1424 2021-11-18 Martin Liska <mliska@suse.cz>
1425
1426 * c-gimplify.c (genericize_c_loop): Use option directly.
1427
483092d3
GA
14282021-11-18 Matthias Kretz <m.kretz@gsi.de>
1429
1430 * c-common.c (c_common_reswords): Add __builtin_assoc_barrier.
1431 * c-common.h (enum rid): Add RID_BUILTIN_ASSOC_BARRIER.
1432
14332021-11-18 Martin Liska <mliska@suse.cz>
1434
1435 * c-gimplify.c (genericize_c_loop): Use option directly.
1436
280d2838
GA
14372021-11-17 Martin Uecker <uecker@gcc.gnu.org>
1438
1439 PR c/91038
1440 PR c/29970
1441 * c-common.c (pointer_int_sum): Make sure pointer expressions
1442 are evaluated first when the size expression depends on for
1443 variably-modified types.
1444
14452021-11-17 Marek Polacek <polacek@redhat.com>
1446
1447 PR preprocessor/103026
1448 * c.opt (Wbidi-chars, Wbidi-chars=): New option.
1449
6b1695f4
GA
14502021-11-16 Jason Merrill <jason@redhat.com>
1451
1452 * c-common.c (release_tree_vector): Only cache vecs smaller than
1453 16 elements.
1454
e2b57363
GA
14552021-11-15 Jason Merrill <jason@redhat.com>
1456
1457 * c.opt: Add -fimplicit-constexpr.
1458 * c-cppbuiltin.c: Define __cpp_implicit_constexpr.
1459 * c-opts.c (c_common_post_options): Disable below C++14.
1460
14612021-11-15 Jakub Jelinek <jakub@redhat.com>
1462
1463 * c-omp.c (c_omp_split_clauses) <case OMP_CLAUSE_THREAD_LIMIT>:
1464 Duplicate to both OMP_TARGET and OMP_TEAMS.
1465
8d36a0d2
GA
14662021-11-10 Marek Polacek <polacek@redhat.com>
1467
1468 PR c++/101940
1469 * c-pragma.c (handle_pragma_diagnostic): Handle #pragma GCC diagnostic
1470 ignored_attributes.
1471
c9b1334e
GA
14722021-11-09 David Malcolm <dmalcolm@redhat.com>
1473
1474 * c-pragma.c (GCC_BAD_AT): New macro.
1475 (GCC_BAD2_AT): New macro.
1476 (handle_pragma_pack): Use the location of the pertinent token when
1477 issuing diagnostics about invalid constants/actions, and trailing
1478 junk.
1479 (handle_pragma_target): Likewise for non-string "GCC option".
1480 (handle_pragma_message): Likewise for trailing junk.
1481
18ae471f
GA
14822021-11-03 Joseph Myers <joseph@codesourcery.com>
1483
1484 PR c/103031
1485 * c-common.c (convert_and_check): Add argument init_const. Call
1486 convert_init if init_const.
1487 * c-common.h (convert_and_check): Update prototype.
1488 (convert_init): New prototype.
1489
cf82e8d9
GA
14902021-11-01 David Malcolm <dmalcolm@redhat.com>
1491
1492 * c-lex.c (c_lex_with_flags): When complaining about non-printable
1493 CPP_OTHER tokens, set the "escape on output" flag.
1494
04a2cf3f
GA
14952021-10-27 Jakub Jelinek <jakub@redhat.com>
1496
1497 * c-omp.c (c_omp_check_loop_iv_r): Don't clear 3rd bit for
1498 POINTER_PLUS_EXPR.
1499 (c_omp_check_nonrect_loop_iv): Handle POINTER_PLUS_EXPR.
1500 (c_omp_check_loop_iv): Set kind even if the iterator is non-integral.
1501
15022021-10-27 Jakub Jelinek <jakub@redhat.com>
1503
1504 PR c++/102854
1505 * c-common.h (c_omp_check_loop_iv_exprs): Add enum tree_code argument.
1506 * c-omp.c (c_omp_check_loop_iv_r): For trees other than decls,
1507 TREE_VEC, PLUS_EXPR, MINUS_EXPR, MULT_EXPR, POINTER_PLUS_EXPR or
1508 conversions temporarily clear the 3rd bit from d->kind while walking
1509 subtrees.
1510 (c_omp_check_loop_iv_exprs): Add CODE argument. Or in 4 into data.kind
1511 if possibly non-rectangular.
1512
ae5c5406
GA
15132021-10-21 Jakub Jelinek <jakub@redhat.com>
1514
1515 PR middle-end/64888
1516 * c-omp.c (c_omp_predefined_variable): Return true also for
1517 ubsan_create_data created artificial variables.
1518
5d5885c9
GA
15192021-10-14 Joseph Myers <joseph@codesourcery.com>
1520
1521 * c-format.c (printf_length_specs, scanf_length_specs)
1522 (print_char_table, scan_char_table): Support DFP formats for C2X.
1523 * c-format.h (TEX_D32, TEX_D64, TEX_D128): Remove.
1524 (T2X_D32, T2X_D64, T2X_D128): New macros.
1525
15262021-10-14 Kwok Cheung Yeung <kcy@codesourcery.com>
1527
1528 * c-omp.c (c_omp_check_context_selector): Rename to
1529 omp_check_context_selector and move to omp-general.c.
1530 (c_omp_mark_declare_variant): Rename to omp_mark_declare_variant and
1531 move to omp-general.c.
1532
52055987
GA
15332021-10-12 Joseph Myers <joseph@codesourcery.com>
1534
1535 * c-format.c (print_char_table): Add %b and %B formats.
1536 (scan_char_table): Add %b format.
1537 * c-format.h (T2X_UI, T2X_UL, T2X_ULL, T2X_US, T2X_UC, T2X_ST)
1538 (T2X_UPD, T2X_UIM): New macros.
1539
15402021-10-12 Jakub Jelinek <jakub@redhat.com>
1541
1542 * c-omp.c (c_finish_omp_atomic): Use
1543 clear_padding_type_may_have_padding_p.
1544
ce6eec39
GA
15452021-10-08 Martin Liska <mliska@suse.cz>
1546
1547 * c-opts.c (c_common_post_options): Use new macro
1548 OPTION_SET_P.
1549
50e20ee6
GA
15502021-10-07 Martin Liska <mliska@suse.cz>
1551
1552 * c-common.c (parse_optimize_options): Make
1553 save_opt_decoded_options a pointer type.
1554
57c7ec62
GA
15552021-10-06 Jakub Jelinek <jakub@redhat.com>
1556
1557 PR tree-optimization/102571
1558 * c-omp.c (c_finish_omp_atomic): Optimize the case where type has
1559 padding, but the non-padding bits are contiguous set of bytes
1560 by adjusting the memcmp call arguments instead of emitting
1561 __builtin_clear_padding and then comparing all the type's bytes.
1562
15632021-10-06 Jakub Jelinek <jakub@redhat.com>
1564
1565 PR c++/102612
1566 * c-cppbuiltin.c (c_cpp_builtins): For -std=c++23 predefine
1567 __cpp_constexpr to 202110L rather than 201907L.
1568
da9c5f78
GA
15692021-10-04 Marek Polacek <polacek@redhat.com>
1570
1571 PR c++/97573
1572 * c-common.h (do_warn_array_compare): Declare.
1573 * c-warn.c (do_warn_array_compare): New.
1574 * c.opt (Warray-compare): New option.
1575
e3e07b89
GA
15762021-10-02 Iain Sandoe <iain@sandoe.co.uk>
1577
1578 * c-format.c: Remove a test of TARGET_FORMAT_TYPES with
1579 NULL, this is not needed.
1580
9d116bcc
GA
15812021-10-01 Martin Sebor <msebor@redhat.com>
1582
1583 PR c/102103
1584 * c-common.c (decl_with_nonnull_addr_p): Handle members.
1585 Check and perform warning suppression.
1586 (c_common_truthvalue_conversion): Enhance warning suppression.
1587
15882021-10-01 Martin Liska <mliska@suse.cz>
1589
1590 PR target/102552
1591 * c-common.c (parse_optimize_options): decoded_options[0] is
3d3b561f
ML
1592 used for program name, so merged_decoded_options should also
1593 respect that.
9d116bcc
GA
1594
15952021-10-01 Jakub Jelinek <jakub@redhat.com>
1596 Richard Biener <rguenther@suse.de>
1597
1598 PR sanitizer/102515
1599 * c-ubsan.c (ubsan_instrument_division): Check the right
1600 flag_sanitize_recover bit, depending on which sanitization
1601 is done. Sanitize INT_MIN / -1 under SANITIZE_SI_OVERFLOW
1602 rather than SANITIZE_DIVIDE. If both SANITIZE_SI_OVERFLOW
1603 and SANITIZE_DIVIDE is enabled, neither check is known
1604 to be false and flag_sanitize_recover bits for those two
1605 aren't the same, emit both __ubsan_handle_divrem_overflow
1606 and __ubsan_handle_divrem_overflow_abort calls.
1607
16082021-10-01 Martin Liska <mliska@suse.cz>
1609
1610 * c-common.c (parse_optimize_options): Combine optimize
1611 options with what was provided on the command line.
1612
16132021-10-01 Jakub Jelinek <jakub@redhat.com>
1614
1615 * c-omp.c (c_omp_split_clauses): Also copy
1616 OMP_CLAUSE_ORDER_REPRODUCIBLE.
1617
cf966403
GA
16182021-09-27 Martin Liska <mliska@suse.cz>
1619
1620 * c-opts.c (c_common_init_options_struct): Set also
3d3b561f 1621 x_flag_default_complex_method.
cf966403 1622
e4777439
GA
16232021-09-22 Jakub Jelinek <jakub@redhat.com>
1624
1625 * c-omp.c (c_omp_split_clauses): Copy over OMP_CLAUSE_ALLOCATE_ALIGN.
1626
62498024
GA
16272021-09-20 Matthias Kretz <m.kretz@gsi.de>
1628
1629 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define or
1630 undefine __RECIPROCAL_MATH__, __NO_SIGNED_ZEROS__,
1631 __NO_TRAPPING_MATH__, __ASSOCIATIVE_MATH__, and
1632 __ROUNDING_MATH__ according to the new optimization flags.
1633
cf74e7b5
GA
16342021-09-18 Jakub Jelinek <jakub@redhat.com>
1635
1636 * c-omp.c (c_omp_split_clauses): Split order clause also to
1637 distribute construct. Copy over OMP_CLAUSE_ORDER_UNCONSTRAINED.
1638
0a4cb439
GA
16392021-09-17 Jakub Jelinek <jakub@redhat.com>
1640
1641 * c-omp.c (c_finish_omp_atomic): Avoid creating
1642 TARGET_EXPR if test is true, use create_tmp_var_raw instead of
1643 create_tmp_var and add a zero initializer to TARGET_EXPRs that
1644 had NULL initializer. When omitting operands after v = x,
1645 use type of v rather than type of x. Fix type of vtmp
1646 TARGET_EXPR.
1647
07985c47
GA
16482021-09-13 Jason Merrill <jason@redhat.com>
1649
1650 * c.opt: Add -Winterference-size.
1651 * c-cppbuiltin.c (cpp_atomic_builtins): Add __GCC_DESTRUCTIVE_SIZE
1652 and __GCC_CONSTRUCTIVE_SIZE.
1653
a26206ec
GA
16542021-09-10 Jakub Jelinek <jakub@redhat.com>
1655
1656 * c-common.h (c_finish_omp_atomic): Add r and weak arguments.
1657 * c-omp.c: Include gimple-fold.h.
1658 (c_finish_omp_atomic): Add r and weak arguments. Add support for
1659 OpenMP 5.1 atomics.
1660
f84e2f0b
GA
16612021-09-09 qing zhao <qing.zhao@oracle.com>
1662
1663 * c-attribs.c (handle_uninitialized_attribute): New function.
1664 (c_common_attribute_table): Add "uninitialized" attribute.
1665
b6db7cd4
GA
16662021-09-08 liuhongt <hongtao.liu@intel.com>
1667
1668 * c-common.c (excess_precision_mode_join): Update below comments.
1669 (c_ts18661_flt_eval_method): Set excess_precision_type to
1670 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
1671 * c-cppbuiltin.c (cpp_atomic_builtins): Update below comments.
1672 (c_cpp_flt_eval_method_iec_559): Set excess_precision_type to
1673 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
1674
b2748138
GA
16752021-09-07 Marcel Vollweiler <marcel@codesourcery.com>
1676
1677 * c-omp.c (c_finish_omp_flush): Handle MEMMODEL_SEQ_CST.
1678
7b739540
GA
16792021-09-03 Eric Botcazou <ebotcazou@adacore.com>
1680
1681 * c-ada-spec.c (dump_ads): Generate pragmas to disable style checks
1682 and -gnatwu warning for the package specification.
1683
e11c6046
GA
16842021-09-01 Iain Sandoe <iain@sandoe.co.uk>
1685
1686 * c-attribs.c (handle_unavailable_attribute): New.
1687
1e2f030b
GA
16882021-08-30 Jason Merrill <jason@redhat.com>
1689
1690 * c.opt: Add -Wmissing-requires.
1691
85d77ac4
GA
16922021-08-25 Lewis Hyatt <lhyatt@gmail.com>
1693
1694 PR other/93067
1695 * c-opts.c (c_common_input_charset_cb): New function.
1696 (c_common_post_options): Call new function
1697 diagnostic_initialize_input_context().
1698
7c9e1645
GA
16992021-08-20 Tobias Burnus <tobias@codesourcery.com>
1700
1701 * c-format.c (gcc_gfc_length_specs): Add 'll' and 'w'.
1702 (gcc_gfc_char_table): Add T9L_LL and T9L_ULL to
1703 "di" and "u", respecitively; fill with BADLEN to match
1704 size of 'types'.
1705 (get_init_dynamic_hwi): Split off from ...
1706 (init_dynamic_diag_info): ... here. Call it.
1707 (init_dynamic_gfc_info): Call it.
1708
17092021-08-20 Jakub Jelinek <jakub@redhat.com>
1710
1711 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ERROR.
1712 * c-pragma.c (omp_pragmas): Add error directive.
1713 * c-omp.c (omp_directives): Uncomment error directive entry.
1714
6e529985
GA
17152021-08-18 Jakub Jelinek <jakub@redhat.com>
1716
1717 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_NOTHING.
1718 * c-pragma.c (omp_pragmas): Add nothing directive.
1719 * c-omp.c (omp_directives): Uncomment nothing directive entry.
1720
2d14d64b
GA
17212021-08-17 Jakub Jelinek <jakub@redhat.com>
1722
1723 PR c++/101539
1724 * c-common.h (enum rid): Add RID_IS_LAYOUT_COMPATIBLE.
1725 * c-common.c (c_common_reswords): Add __is_layout_compatible.
1726
17272021-08-17 Matt Jacobson <mhjacobson@me.com>
1728
1729 * c-opts.c (c_common_post_options): Default to
1730 flag_objc_sjlj_exceptions = 1 only when flag_objc_abi < 2.
1731
17322021-08-17 Jakub Jelinek <jakub@redhat.com>
1733
1734 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCOPE.
1735 * c-pragma.c (omp_pragmas): Add scope construct.
1736 * c-omp.c (omp_directives): Uncomment scope directive entry.
1737
9d1d9fc8
GA
17382021-08-16 Sebastian Huber <sebastian.huber@embedded-brains.de>
1739
1740 * c-cppbuiltin.c (c_cpp_builtins): Define
1741 __LIBGCC_GCOV_TYPE_SIZE if flag_building_libgcc is true.
1742
72be20e2
GA
17432021-08-12 Jakub Jelinek <jakub@redhat.com>
1744
1745 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_MASKED.
1746 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FILTER.
1747 * c-pragma.c (omp_pragmas_simd): Add masked construct.
1748 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_MASKED
1749 enumerator.
1750 (c_finish_omp_masked): Declare.
1751 * c-omp.c (c_finish_omp_masked): New function.
1752 (c_omp_split_clauses): Handle combined masked constructs.
1753
4d17ca1b
GA
17542021-07-30 Jakub Jelinek <jakub@redhat.com>
1755
1756 PR c++/101539
1757 * c-common.h (enum rid): Add RID_IS_POINTER_INTERCONVERTIBLE_BASE_OF.
1758 * c-common.c (c_common_reswords): Add
1759 __is_pointer_interconvertible_base_of.
1760
17612021-07-29 Richard Biener <rguenther@suse.de>
1762
1763 PR c/101512
1764 * c-common.c (c_common_mark_addressable_vec): Look through
1765 C_MAYBE_CONST_EXPR even if not at the toplevel.
1766
af3f12e6
GA
17672021-07-27 Martin Sebor <msebor@redhat.com>
1768
1769 PR c/101585
1770 * c-warn.c (warn_parm_ptrarray_mismatch): Use OEP_DECL_NAME.
1771
ead235f6
GA
17722021-07-23 Jakub Jelinek <jakub@redhat.com>
1773
1774 * c-lex.c (c_common_has_attribute): Call canonicalize_attr_name also
1775 on attr_id. Return 1 for omp::directive or omp::sequence in C++11
1776 and later.
1777
17782021-07-23 Jakub Jelinek <jakub@redhat.com>
1779
1780 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP__START_ and
1781 PRAGMA_OMP__LAST_ enumerators.
1782
419c6c68
GA
17832021-07-21 Thomas Schwinge <thomas@codesourcery.com>
1784 Joseph Myers <joseph@codesourcery.com>
1785 Cesar Philippidis <cesar@codesourcery.com>
1786
1787 * c-pragma.h (pragma_omp_clause): Add 'PRAGMA_OACC_CLAUSE_NOHOST'.
1788
92d45509
GA
17892021-07-20 Martin Sebor <msebor@redhat.com>
1790
1791 * c-common.c (c_build_shufflevector): Adjust by-value argument to
1792 by-const-reference.
1793 * c-common.h (c_build_shufflevector): Same.
1794
87277b6a
GA
17952021-07-16 Andrew Pinski <apinski@marvell.com>
1796
1797 PR c/101453
1798 * c-common.c (parse_optimize_options): Use the correct
1799 size for buffer.
1800
d97d71a1
GA
18012021-07-15 Martin Sebor <msebor@redhat.com>
1802
1803 PR c/101289
1804 PR c/97548
1805 * c-warn.c (warn_parm_array_mismatch): Use OEP_DECL_NAME.
1806
c4fee1c6
GA
18072021-07-14 Jason Merrill <jason@redhat.com>
1808
1809 * c-opts.c (c_common_post_options): Set -fdelete-dead-exceptions.
1810
6fba0eea
GA
18112021-07-06 Martin Sebor <msebor@redhat.com>
1812
1813 * c-format.c (gcc_tdiag_char_table): Remove support for %G and %K.
3d3b561f
ML
1814 (gcc_cdiag_char_table): Same.
1815 (gcc_cxxdiag_char_table): Same.
6fba0eea 1816
7a60a6e8
GA
18172021-07-02 Jakub Jelinek <jakub@redhat.com>
1818
1819 * c-common.h (enum c_omp_directive_kind): New enum.
1820 (struct c_omp_directive): New type.
1821 (c_omp_categorize_directive): Declare.
1822 * c-omp.c (omp_directives): New variable.
1823 (c_omp_categorize_directive): New function.
1824
bea7c16a
GA
18252021-07-01 Eric Botcazou <ebotcazou@adacore.com>
1826
1827 * c-ada-spec.c (packed_layout): New global variable.
1828 (dump_ada_declaration): Set it upon seeing a packed record type.
1829 Do not put the "aliased" keyword if it is set.
1830 (dump_ada_structure): Add Pack aspect if it is set and clear it.
1831
18322021-07-01 Eric Botcazou <ebotcazou@adacore.com>
1833
1834 * c-ada-spec.c (check_name): Rename into...
1835 (check_type_name_conflict): ...this. Minor tweak.
1836 (dump_ada_function_declaration): Adjust to above renaming.
1837 (dump_ada_array_domains): Fix oversight.
1838 (dump_ada_declaration): Call check_type_name_conflict for variables.
1839
90708f87
GA
18402021-06-25 Martin Sebor <msebor@redhat.com>
1841
1842 * c-common.c (c_wrap_maybe_const): Remove TREE_NO_WARNING.
1843 (c_common_truthvalue_conversion): Replace direct uses of
1844 TREE_NO_WARNING with warning_suppressed_p, suppress_warning, and
1845 copy_no_warning.
1846 (check_function_arguments_recurse): Same.
1847 * c-gimplify.c (c_gimplify_expr): Same.
1848 * c-warn.c (overflow_warning): Same.
1849 (warn_logical_operator): Same.
1850 (warn_if_unused_value): Same.
1851 (do_warn_unused_parameter): Same.
1852
9aa8327e
GA
18532021-06-24 Jakub Jelinek <jakub@redhat.com>
1854
1855 * c-common.h (enum c_omp_region_type): Add C_ORT_TARGET and
1856 C_ORT_OMP_TARGET.
1857 * c-omp.c (c_omp_split_clauses): For OMP_CLAUSE_IN_REDUCTION on
1858 combined target constructs also add map (always, tofrom:) clause.
1859
ede6c356
GA
18602021-06-15 Robin Dapp <rdapp@linux.ibm.com>
1861
1862 * c-attribs.c (common_handle_aligned_attribute): Remove short
1863 circuit and dead code.
1864
8dc48181
GA
18652021-06-14 Jonathan Wakely <jwakely@redhat.com>
1866
1867 PR c++/101052
1868 * known-headers.cc (get_stdlib_header_for_name): Add known
1869 headers for EXIT_FAILURE, EXIT_SUCCESS, abort, atexit, calloc,
1870 exit, and getenv.
1871
8b8c3912
GA
18722021-06-12 Jason Merrill <jason@redhat.com>
1873
1874 * c-attribs.c (handle_unused_attribute): Handle FIELD_DECL.
1875
f16f65f8
GA
18762021-06-11 Jakub Jelinek <jakub@redhat.com>
1877
1878 PR c++/100974
1879 * c-cppbuiltin.c (c_cpp_builtins): Predefine __cpp_if_consteval for
1880 -std=c++2b for P1938R3 consteval if support.
1881
4f625f47
GA
18822021-06-09 Jason Merrill <jason@redhat.com>
1883
1884 PR c++/100879
1885 * c-warn.c (warn_for_sign_compare): Remove C++ enum mismatch
1886 warning.
1887
438aac59
GA
18882021-06-07 Martin Liska <mliska@suse.cz>
1889
1890 * c-target.def: Split long lines and replace them
1891 with '\n\'.
1892
600f90cb
GA
18932021-06-04 Martin Sebor <msebor@redhat.com>
1894
1895 PR c/100783
1896 * c-attribs.c (positional_argument): Bail on erroneous types.
1897
18982021-06-04 Martin Sebor <msebor@redhat.com>
1899
1900 * c-warn.c (warn_parm_array_mismatch): Check TREE_PURPOSE to test
1901 for element presence.
1902
440c8a0a
GA
19032021-06-03 Eric Botcazou <ebotcazou@adacore.com>
1904
1905 * c-ada-spec.c (dump_ada_macros): Minor tweaks.
1906 (dump_ada_decl_name): Likewise.
1907 (dump_anonymous_type_name): Remove parent parameter and adjust.
1908 (dump_sloc): Minor tweak.
1909 (dump_ada_array_type): Remove type parameter and adjust.
1910 (dump_ada_enum_type): Remove parent parameter and adjust.
1911 (dump_ada_node): Adjust calls to above functions.
1912 (dumped_anonymous_types): New global variable.
1913 (dump_nested_types_1): Rename into...
1914 (dump_nested_types): ...this.
1915 (dump_nested_type): Remove parent and dumped_types parameters.
1916 <ARRAY_TYPE>: Replace dumped_types with dumped_anonymous_types.
1917 Adjust calls to dump_anonymous_type_name and dump_ada_array_type.
1918 (dump_ada_specs): Initialize and free dumped_anonymous_types.
1919
19202021-06-03 Eric Botcazou <ebotcazou@adacore.com>
1921
1922 * c-ada-spec.c (pp_ada_tree_identifier): Tidy up.
1923 (dump_ada_node) <POINTER_TYPE>: Deal specially with external subtypes.
1924
19252021-06-03 Eric Botcazou <ebotcazou@adacore.com>
1926
1927 * c-ada-spec.c (dump_ada_enum_type): Dump a prefix for constants.
1928 (htable_t): New typedef.
1929 (overloaded_names): Use it.
1930 (add_name): New function.
1931 (init_overloaded_names): Use add_name to populate the table and add
1932 special cases for sigaction and stat.
1933 (overloaded_name_p): Rename into...
1934 (overloading_index): ...this. Do not initialize overloaded_names table
1935 here. Return the index or zero.
1936 (dump_ada_declaration): Minor tweaks. Do not skip overloaded functions
1937 but add an overloading suffix instead.
1938 (dump_ada_specs): Initialize overloaded_names tables here.
1939
b75978d1
GA
19402021-06-01 Martin Liska <mliska@suse.cz>
1941
1942 PR other/100759
1943 * c-attribs.c (handle_optimize_attribute): Limit sanity check
1944 to a situation where we are not in processing of an optimize
1945 pragma.
1946 * c-pragma.c (handle_pragma_pop_options): Restore target
1947 options.
1948
ee682192
GA
19492021-05-31 Indu Bhagat <indu.bhagat@oracle.com>
1950
1951 PR testsuite/100749
1952 * c-pch.c (c_common_valid_pch): Use xstrdup for debug format set names.
1953
19542021-05-31 Richard Biener <rguenther@suse.de>
1955
1956 PR c++/88601
1957 * c-common.c: Include tree-vector-builder.h and
1958 vec-perm-indices.h.
1959 (c_common_reswords): Add __builtin_shufflevector.
1960 (c_build_shufflevector): New funtion.
1961 * c-common.h (enum rid): Add RID_BUILTIN_SHUFFLEVECTOR.
1962 (c_build_shufflevector): Declare.
1963
48166757
GA
19642021-05-28 Jakub Jelinek <jakub@redhat.com>
1965
1966 PR middle-end/99928
1967 * c-omp.c (c_omp_split_clauses): For reduction clause if combined with
1968 target add a map tofrom clause with OMP_CLAUSE_MAP_IMPLICIT.
1969
19702021-05-28 Tobias Burnus <tobias@codesourcery.com>
1971
1972 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_AFFINITY.
1973
2bc6dace
GA
19742021-05-25 Martin Liska <mliska@suse.cz>
1975
1976 PR tree-optimization/92860
1977 PR target/99592
1978 * c-attribs.c (handle_optimize_attribute): Save target node
1979 before calling parse_optimize_options and save it in case
1980 it changes.
1981 * c-pragma.c (handle_pragma_target): Similarly for pragma.
1982 (handle_pragma_pop_options): Likewise here.
1983
19842021-05-25 Martin Liska <mliska@suse.cz>
1985
1986 * c-attribs.c (handle_no_sanitize_coverage_attribute): New.
1987
19882021-05-25 Jakub Jelinek <jakub@redhat.com>
1989
1990 PR middle-end/99928
1991 * c-omp.c (c_omp_split_clauses): Copy reduction to teams when teams is
1992 combined with simd and not with taskloop or for.
1993
2832d51b
GA
19942021-05-21 Jakub Jelinek <jakub@redhat.com>
1995
1996 PR middle-end/99928
1997 * c-omp.c (c_omp_split_clauses): Set OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT
1998 on firstprivate clause copy going to target construct, and for
1999 target simd set also OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT_TARGET bit.
2000
ea34e2ed
GA
20012021-05-20 Jonathan Wakely <jwakely@redhat.com>
2002
2003 * c.opt (Wc++11-extensions, Wc++14-extensions)
2004 (Wc++17-extensions, Wc++20-extensions, Wc++23-extensions): New
2005 options.
2006
20072021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
2008
2009 * c-lex.c (init_c_lex): Use dwarf_debuginfo_p.
2010
20112021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
2012
2013 * c-opts.c (c_common_post_options): Adjust access to debug_type_names.
2014 * c-pch.c (struct c_pch_validity): Use type uint32_t.
2015 (pch_init): Renamed member.
2016 (c_common_valid_pch): Adjust access to debug_type_names.
2017
65f32e5d
GA
20182021-05-19 Martin Sebor <msebor@redhat.com>
2019
2020 PR c/100619
2021 * c-attribs.c (build_attr_access_from_parms): Handle arbitrarily many
2022 bounds.
2023
a8daf9a1
GA
20242021-05-18 Richard Biener <rguenther@suse.de>
2025
2026 PR c/100547
2027 * c-attribs.c (type_valid_for_vector_size): Reject too large nunits.
2028 Reword existing nunit diagnostic.
2029
a7ffc1ef
GA
20302021-05-17 Joern Rennecke <joern.rennecke@embecosm.com>
2031
2032 * c-common.c (braced_list_to_string): Return CTOR unchanged
2033 if host and target character sizes don't match.
2034
87a7d10c
GA
20352021-05-14 Martin Liska <mliska@suse.cz>
2036
2037 * c.opt: Add Warning keyword for 2 options.
2038
f9af11c7
GA
20392021-05-13 Martin Liska <mliska@suse.cz>
2040
2041 PR middle-end/100504
2042 * c-attribs.c (handle_target_clones_attribute): Expect a string
2043 argument to target_clone argument.
2044
037e3661
GA
20452021-05-11 Joseph Myers <joseph@codesourcery.com>
2046
2047 * c-lex.c (interpret_float): Handle digit separators for C2X.
2048
aa891c56
GA
20492021-05-10 Martin Liska <mliska@suse.cz>
2050
2051 * c-ada-spec.c (print_destructor): Use startswith
2052 function instead of strncmp.
2053 (dump_ada_declaration): Likewise.
2054 * c-common.c (disable_builtin_function): Likewise.
2055 (def_builtin_1): Likewise.
2056 * c-format.c (check_tokens): Likewise.
2057 (check_plain): Likewise.
2058 (convert_format_name_to_system_name): Likewise.
2059
e4ff4ffb
GA
20602021-04-28 Patrick McGehearty <patrick.mcgehearty@oracle.com>
2061
2062 * c-cppbuiltin.c (c_cpp_builtins): Add supporting macros for new
2063 complex divide
2064
c0fa3f2f
GA
20652021-04-26 Thomas Schwinge <thomas@codesourcery.com>
2066 Nathan Sidwell <nathan@codesourcery.com>
2067 Tom de Vries <vries@codesourcery.com>
2068 Julian Brown <julian@codesourcery.com>
2069 Kwok Cheung Yeung <kcy@codesourcery.com>
2070
2071 * c.opt (Wopenacc-parallelism): New.
2072
6e81e015
GA
20732021-04-19 Thomas Schwinge <thomas@codesourcery.com>
2074
2075 * c.opt (fopenacc-kernels=): Remove.
2076
019a9220
GA
20772021-04-08 Jakub Jelinek <jakub@redhat.com>
2078
2079 * c-warn.c (do_warn_double_promotion): Fix comment typo,
2080 occured -> occurred.
2081 (check_alignment_of_packed_member): Fix a comment typo,
2082 memeber -> member.
2083 (warn_parm_ptrarray_mismatch): Fix comment typos, os -> of
2084 and onless -> unless.
2085 (warn_parm_array_mismatch): Fix comment typos, declaratation
2086 -> declaration and woud -> would. Fix up comment indentation.
2087
20882021-04-08 Martin Sebor <msebor@redhat.com>
2089
2090 PR middle-end/99883
2091 * c.opt (Wmismatched-new-delete): Correct spelling.
2092
b1da9916
GA
20932021-04-05 Eric Botcazou <ebotcazou@adacore.com>
2094
2095 * c-ada-spec.c (is_simple_enum): Minor tweaks.
2096 (dump_ada_enum_type): Add TYPE and PARENT parameters. For non-simple
2097 enumeral types use again the type name for the enumeration constants.
2098 (dump_ada_node): Adjust call to dump_ada_enum_type.
2099 (dump_nested_type): Likewise.
2100
f1607029
GA
21012021-04-01 Jason Merrill <jason@redhat.com>
2102
2103 PR c++/98481
2104 * c-opts.c (c_common_post_options): Bump latest_abi_version.
2105
4493b1c1
GA
21062021-03-25 Jakub Jelinek <jakub@redhat.com>
2107
2108 PR c++/99565
2109 * c-warn.c (do_warn_duplicated_branches): Pass also
2110 OEP_ADDRESS_OF_SAME_FIELD to operand_equal_p.
2111
6af7b307
GA
21122021-03-20 Jakub Jelinek <jakub@redhat.com>
2113
2114 PR debug/99230
2115 * c-gimplify.c (c_genericize_control_stmt): Handle STATEMENT_LIST.
2116
ceae9533
GA
21172021-03-05 Eric Botcazou <ebotcazou@adacore.com>
2118
2119 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Dump nested types
2120 after entering the separate class package, if any.
2121
67f10d28
GA
21222021-03-04 Richard Biener <rguenther@suse.de>
2123
2124 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator):
2125 Handle ERROR_MARK.
2126
21272021-03-04 Jakub Jelinek <jakub@redhat.com>
2128
2129 PR c/99325
2130 * c-ppoutput.c (print): Change src_line type from int to unsigned.
2131 (token_streamer::stream) Likewise.
2132 (maybe_print_line_1): Likewise. Don't strcmp src_file if src_loc is
2133 UNKNOWN_LOCATION.
2134
f3641ac7
GA
21352021-03-03 Jakub Jelinek <jakub@redhat.com>
2136
2137 PR c/99324
2138 * c-common.c (build_va_arg): Call c_common_mark_addressable_vec
2139 instead of mark_addressable. Fix a comment typo -
2140 neutrallly -> neutrally.
2141
2c83c3fb
GA
21422021-02-28 Jakub Jelinek <jakub@redhat.com>
2143
2144 PR c/99304
2145 * c-attribs.c (handle_malloc_attribute): Fix a typo in inform
2146 message - refernced -> referenced. Remove superfluous space before
2147 closing paren of function calls.
2148
daa68844
GA
21492021-02-25 Nathan Sidwell <nathan@acm.org>
2150
2151 PR c++/99166
2152 * c.opt (-flang-info-module-cmi): Renamed option.
2153
50352c6c
GA
21542021-02-19 Nathan Sidwell <nathan@acm.org>
2155
2156 * c.opt (flang-info-module-read, flang-info-module-read=): New.
2157
bf81237e
GA
21582021-02-18 H.J. Lu <hjl.tools@gmail.com>
2159
2160 PR target/99113
2161 * c-attribs.c (c_common_attribute_table): Add the "retain"
2162 attribute.
2163 (handle_retain_attribute): New function.
2164
0e804ce3
GA
21652021-02-16 Marek Polacek <polacek@redhat.com>
2166
2167 PR c++/99062
2168 * c-attribs.c (handle_assume_aligned_attribute): Check that the
2169 alignment argument is non-negative. Tweak a warning message.
2170
fab095da
GA
21712021-02-12 Martin Sebor <msebor@redhat.com>
2172
2173 PR c/99055
2174 * c-warn.c (warn_parm_array_mismatch): Free strings returned from
2175 print_generic_expr_to_str.
2176
4b37c3ea
GA
21772021-02-10 Richard Biener <rguenther@suse.de>
2178
2179 * c-common.c (parse_optimize_options): Free decoded_options.
2180
a19dd5e6
GA
21812021-02-04 emsr <3dw4rd@verizon.net>
2182
2183 * c-cppbuiltin.c (c_cpp_builtins): __cpp_size_t_suffix=202011L.
2184
9faaa807
GA
21852021-02-03 Ed Smith-Rowland <3dw4rd@verizon.net>
2186
2187 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_size_t_suffix.
2188 * c-lex.c (interpret_integer): Set node type for size literal.
2189
85d04a2e
GA
21902021-01-28 Jakub Jelinek <jakub@redhat.com>
2191
2192 * c.opt (-std=c++2a, -std=c++20, -std=gnu++2a, -std=gnu++20): Remove
2193 draft from description.
2194 (-std=c++2b): Fix a pasto, 2020 -> 2023.
2195
e62bb7f0
GA
21962021-01-26 Paul Fee <paul.f.fee@gmail.com>
2197
2198 * c-common.h (cxx_dialect): Add cxx23 as a dialect.
2199 * c.opt: Add options for -std=c++23, std=c++2b, -std=gnu++23
2200 and -std=gnu++2b
2201 * c-opts.c (set_std_cxx23): New.
2202 (c_common_handle_option): Set options when -std=c++23 is enabled.
2203 (c_common_post_options): Adjust comments.
2204 (set_std_cxx20): Likewise.
2205
161e4c08
GA
22062021-01-25 Martin Sebor <msebor@redhat.com>
2207
2208 PR c++/98646
2209 * c-common.c (check_nonnull_arg): Adjust warning text.
2210
4c9bcd5c
GA
22112021-01-17 Martin Sebor <msebor@redhat.com>
2212
2213 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
2214 assume SSA_NAME_IDENTIFIER evaluates to nonzero.
2215
59cf67d1
GA
22162021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
2217
2218 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DETACH.
2219 Redefine PRAGMA_OACC_CLAUSE_DETACH.
2220
2f7f0d32
GA
22212021-01-15 Jakub Jelinek <jakub@redhat.com>
2222
2223 PR tree-optimization/98597
2224 * c-pretty-print.c: Include options.h.
2225 (c_fold_indirect_ref_for_warn): New function.
2226 (print_mem_ref): Use it. If it returns something that has compatible
2227 type and is TBAA compatible with zero offset, print it and return,
2228 otherwise print it using offsetof syntax or array ref syntax. Fix up
2229 printing if MEM_REFs first operand is ADDR_EXPR, or when the first
2230 argument has pointer to array type. Print pointers using the standard
2231 formatting.
2232
6851dda2
GA
22332021-01-12 Martin Sebor <msebor@redhat.com>
2234
2235 PR c/98597
2236 PR c/98592
2237 * c-pretty-print.c (print_mem_ref): Avoid assuming MEM_REF operand
2238 has pointer type. Remove redundant code. Avoid calling
2239 gimple_canonical_types_compatible_p.
2240
7d187e4f
GA
22412021-01-07 Martin Sebor <msebor@redhat.com>
2242
2243 PR middle-end/98578
2244 * c-pretty-print.c (print_mem_ref): Strip array from access type.
2245 Avoid assuming acces type's size is constant. Correct condition
2246 guarding the printing of a parenthesis.
2247
942ae5be
GA
22482021-01-06 Martin Sebor <msebor@redhat.com>
2249
2250 PR c++/95768
2251 * c-pretty-print.c (c_pretty_printer::primary_expression): For
2252 SSA_NAMEs print VLA names and GIMPLE defining statements.
2253 (print_mem_ref): New function.
2254 (c_pretty_printer::unary_expression): Call it.
2255
22562021-01-06 Richard Biener <rguenther@suse.de>
2257
2258 PR tree-optimization/95582
2259 * c-attribs.c (c_common_attribute_table): Add entry for
2260 signed_bool_precision.
2261 (handle_signed_bool_precision_attribute): New.
2262
8daa719b
GA
22632020-12-24 Iain Sandoe <iain@sandoe.co.uk>
2264
2265 * c.opt: Add -stdlib= option and enumerations for
2266 libstdc++ and libc++.
2267
eefe499f
GA
22682020-12-16 Martin Liska <mliska@suse.cz>
2269
2270 * c.opt: Remove usage of Report.
2271
d52945ce
GA
22722020-12-14 Martin Sebor <msebor@redhat.com>
2273
2274 PR middle-end/98166
2275 PR c++/57111
2276 PR middle-end/98160
2277 * c-attribs.c (maybe_add_noinline): New function.
2278 (handle_malloc_attribute): Call it. Use ATTR_FLAG_INTERNAL.
2279 Implicitly add attribute noinline to functions not declared inline
2280 and warn on those.
2281
ca2bd949
GA
22822020-12-09 Tobias Burnus <tobias@codesourcery.com>
2283
2284 * c-pragma.c (omp_pragmas): Add 'allocate'.
2285 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ALLOCATE.
2286
f6e8e279
GA
22872020-12-08 Jakub Jelinek <jakub@redhat.com>
2288
2289 PR c++/98187
2290 * c-pragma.c (omp_pragmas): Remove "master".
2291 (omp_pragmas_simd): Add "master".
2292
bc8a7013
GA
22932020-12-07 Marek Polacek <polacek@redhat.com>
2294
2295 PR c++/98126
2296 * c-common.c (verify_tree_lim_r): New function.
2297 (verify_sequence_points): Use it. Use nullptr instead of 0.
2298
b8dd0ef7
GA
22992020-12-03 Martin Sebor <msebor@redhat.com>
2300
2301 PR c++/90629
2302 PR middle-end/94527
2303 * c-attribs.c (handle_dealloc_attribute): New function.
2304 (handle_malloc_attribute): Handle argument forms of attribute.
2305 * c.opt (-Wmismatched-dealloc): New option.
2306 (-Wmismatched-new-delete): New option.
2307
23082020-12-03 Jakub Jelinek <jakub@redhat.com>
2309
2310 PR libstdc++/93121
2311 * c-common.h (enum rid): Add RID_BUILTIN_BIT_CAST.
2312 * c-common.c (c_common_reswords): Add __builtin_bit_cast.
2313
e0f5e792
GA
23142020-12-01 JeanHeyd Meneide <phdofthehouse@gmail.com>
2315
2316 * c-cppbuiltin.c (c_cpp_builtins): Add predefined
2317 {__GNUC_EXECUTION_CHARSET_NAME} and
2318 _WIDE_EXECUTION_CHARSET_NAME} macros.
2319
23202020-12-01 Nathan Sidwell <nathan@acm.org>
2321
2322 * c-common.c (module, import, export): New internal tokens (with
2323 trailing space).
2324 * c-common.h (RID__MODULE, RID__IMPORT & RID__EXPORT): Enumerate
2325 them.
2326 (D_CXX_MODULES, D_CXX_MODULES_FLAGS): Enable them.
2327 * c-cppbuiltin.c (c_cpp_builtins): Feature macro.
2328
23292020-12-01 Nathan Sidwell <nathan@acm.org>
2330
2331 * c-opts.c (c_common_init_options): Ask for module dependencies.
2332 (c_common_handle_option): Handle -Mmodules -Mno-modules.
2333 * c-pch.c (c_common_valid_pch): ... does not play with C++
2334 modules.
2335 * c.opt (Mmodules, Mno-modules): New preprocessor dependency
2336 options.
2337 (fmodules-ts, fmodule-header, fmodule-implicit-inline)
2338 (fmodule-only, fmodule-mapper, fmodule-lazy)
2339 (fmodule-version-ignore, Winvalid-imported-macros)
2340 (flang-info-include-translate, flang-info-include-translate-not):
2341 New options
2342
5fbf0ecb
GA
23432020-11-28 Eric Botcazou <ebotcazou@adacore.com>
2344
2345 * c-ada-spec.c (dump_nested_type) <RECORD_TYPE>: Remove obsolete code.
2346 (dump_ada_structure): Also deal with convention, unchecked union and
2347 bit-field for nested types. In the latter case, print an Alignment
2348 aspect along with the Pack aspect.
2349
360258da
GA
23502020-11-25 Martin Sebor <msebor@redhat.com>
2351
2352 PR bootstrap/94982
2353 * c-attribs.c (handle_patchable_function_entry_attribute): Avoid
2354 -Wformat-diag.
2355
1e2c9a27
GA
23562020-11-24 Martin Sebor <msebor@redhat.com>
2357
2358 * c-warn.c (warn_parm_array_mismatch): Avoid invalid redeclarations.
2359
8e6198d0
GA
23602020-11-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2361
2362 * c-attribs.c (handle_special_var_sec_attribute): New.
2363 (handle_noinit_attribute): Remove.
2364 (attr_noinit_exclusions): Rename to...
2365 (attr_section_exclusions): ...this, and add "persistent" attribute
2366 exclusion.
2367 (c_common_attribute_table): Add "persistent" attribute.
2368
7a97e2fc
GA
23692020-11-21 Aaron Sawdey <acsawdey@linux.ibm.com>
2370
2371 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
2372 Treat opaque types like other types.
2373 (c_pretty_printer::direct_abstract_declarator): Opaque types are
2374 supported types.
2375
82e5048e
GA
23762020-11-20 Martin Sebor <msebor@redhat.com>
2377
2378 * c-warn.c (warn_parm_array_mismatch): Bail on invalid redeclarations
2379 with fewer arguments.
2380
23812020-11-20 Martin Sebor <msebor@redhat.com>
2382
2383 PR middle-end/97879
2384 * c-attribs.c (handle_access_attribute): Handle ATTR_FLAG_INTERNAL.
2385 Error out on invalid modes.
2386
23872020-11-20 Jakub Jelinek <jakub@redhat.com>
2388
2389 PR libstdc++/88101
2390 * c-common.c (check_builtin_function_arguments): Handle
2391 BUILT_IN_CLEAR_PADDING.
2392
25bb75f8
GA
23932020-11-18 Nathan Sidwell <nathan@acm.org>
2394
2395 * c-lex.c (c_lex_with_flags): CPP_HEADER_NAMEs can now be seen.
2396
4dabb037
GA
23972020-11-17 Nathan Sidwell <nathan@acm.org>
2398
2399 * c-common.h (enum c_tree_index): Reorder to place lazy fields
2400 after newly-added CTI_MODULE_HWM.
2401
24022020-11-17 Joseph Myers <joseph@codesourcery.com>
2403
2404 * c-cppbuiltin.c (builtin_define_float_constants): Define
2405 "*_IS_IEC_60559__" macros.
2406
24072020-11-17 Nathan Sidwell <nathan@acm.org>
2408
2409 * c-lex.c: #include "langhooks.h".
2410 (cb_undef): Maybe call preprocess_undef lang hook.
2411 * c-opts.c (c_common_post_options): Maybe call preprocess_options
2412 lang hook.
2413 (push_command_line_include): Maybe call preprocess_main_file lang
2414 hook.
2415 (cb_file_change): Likewise.
2416 * c-ppoutput.c: #include "langhooks.h.
2417 (scan_translation_unit): Maybe call preprocess_token lang hook.
2418 (class do_streamer): New, derive from token_streamer.
2419 (directives_only_cb): Data pointer is do_streamer, call
2420 preprocess_token lang hook.
2421 (scan_translation_unit_directives_only): Use do_streamer.
2422 (print_line_1): Move src_line recording to after string output.
2423 (cb_undef): Maybe call preprocess_undef lang hook.
2424
24252020-11-17 Nathan Sidwell <nathan@acm.org>
2426
2427 * c-ppoutput.c (scan_translation_unit): Use token_streamer, remove
2428 code duplicating that functionality.
2429
24302020-11-17 Jakub Jelinek <jakub@redhat.com>
2431
2432 PR c/90628
2433 * c-common.c (check_builtin_function_arguments)
2434 <case BUILT_IN_ADD_OVERFLOW>: Diagnose when last argument is pointer
2435 to _Atomic. For the TYPE_READONLY case, adjust message to be usable
2436 for more builtins and argument positions.
2437
29c5d9ce
GA
24382020-11-16 Iain Sandoe <iain@sandoe.co.uk>
2439
2440 PR objc/97854
2441 * stub-objc.c: Include c-common.h to declare enum rid.
2442
77f67db2
GA
24432020-11-13 Jakub Jelinek <jakub@redhat.com>
2444
2445 PR c++/63287
2446 * c-cppbuiltin.c: Include configargs.h.
2447 (c_cpp_builtins): For C++11 and later if THREAD_MODEL_SPEC is not
2448 defined, predefine __STDCPP_THREADS__ to 1 unless thread_model is
2449 "single".
2450
24512020-11-13 Gergö Barany <gergo@codesourcery.com>
2452 Thomas Schwinge <thomas@codesourcery.com>
2453
2454 * c.opt (fopenacc-kernels): Add.
2455
24562020-11-13 Jason Merrill <jason@redhat.com>
2457
2458 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_using_enum.
2459
24602020-11-13 Piotr H. Dabrowski <phd@phd.re>
2461
2462 PR c++/91318
2463 * c-cppbuiltin.c: c_cpp_builtins_optimize_pragma(): use cpp_define_unused()
2464
24652020-11-13 Martin Liska <mliska@suse.cz>
2466
2467 * c-attribs.c (build_attr_access_from_parms): Format properly.
2468
24692020-11-13 Iain Sandoe <iain@sandoe.co.uk>
2470
2471 PR objc/90707
2472 * c-common.c (c_common_reswords): null_unspecified, nullable,
2473 nonnull, null_resettable: New keywords.
2474 * c-common.h (enum rid): RID_NULL_UNSPECIFIED, RID_NULLABLE,
2475 RID_NONNULL, RID_NULL_RESETTABLE: New.
2476 (OBJC_IS_PATTR_KEYWORD): Include nullability keywords in the
2477 ranges accepted for property attributes.
2478 * c-attribs.c (handle_objc_nullability_attribute): New.
2479 * c-objc.h (enum objc_property_attribute_group): Add
2480 OBJC_PROPATTR_GROUP_NULLABLE.
2481 (enum objc_property_attribute_kind):Add
2482 OBJC_PROPERTY_ATTR_NULL_UNSPECIFIED, OBJC_PROPERTY_ATTR_NULLABLE,
2483 OBJC_PROPERTY_ATTR_NONNULL, OBJC_PROPERTY_ATTR_NULL_RESETTABLE.
2484
24852020-11-13 Iain Sandoe <iain@sandoe.co.uk>
2486
2487 PR objc/77404
2488 * c-attribs.c (handle_objc_root_class_attribute): New
2489 * c-objc.h (objc_start_class_interface): Add a location
2490 value for the position of the class name.
2491 * c.opt: Add Wobjc-root-class.
2492 * stub-objc.c (objc_start_class_interface): Add a location
2493 value for the position of the class name.
2494
a5a11525
GA
24952020-11-12 Joseph Myers <joseph@codesourcery.com>
2496
2497 * c-lex.c (c_common_has_attribute): Take argument std_syntax.
2498 Allow scope for C. Handle standard attributes for C. Do not
2499 accept unscoped attributes if std_syntax and not handled as
2500 standard attributes.
2501 * c-common.h (c_common_has_attribute): Update prototype.
2502
25032020-11-12 Nicholas Guriev <guriev-ns@ya.ru>
2504
2505 PR pch/86674
2506 * c-pch.c (c_common_valid_pch): Use cpp_warning with CPP_W_INVALID_PCH
2507 reason to fix -Werror=invalid-pch and -Wno-error=invalid-pch switches.
2508
0f5f9ed5
GA
25092020-11-11 Patrick Palka <ppalka@redhat.com>
2510
2511 PR c++/88115
2512 * c-opts.c (c_common_post_options): Update latest_abi_version.
2513
bb622641
GA
25142020-11-10 Jakub Jelinek <jakub@redhat.com>
2515
2516 PR c/97748
2517 * c-common.h (warn_if_unused_value): Add quiet argument defaulted
2518 to false.
2519 * c-warn.c (warn_if_unused_value): Likewise. Pass it down
2520 recursively and just return true instead of warning if it is true.
2521 Handle COMPLEX_EXPR.
2522
25232020-11-10 Chung-Lin Tang <cltang@codesourcery.com>
2524
2525 * c-common.h (c_omp_adjust_map_clauses): New declaration.
2526 * c-omp.c (struct map_clause): Helper type for c_omp_adjust_map_clauses.
2527 (c_omp_adjust_map_clauses): New function.
2528
2bee28dd
GA
25292020-11-09 Marek Polacek <polacek@redhat.com>
2530
2531 DR 1914
2532 * c-common.c (attribute_fallthrough_p): Tweak the warning
2533 message.
2534
25352020-11-09 Patrick Palka <ppalka@redhat.com>
2536
2537 * c-pragma.c (handle_pragma_diagnostic): Split the
2538 unknown-option -Wpragmas diagnostic into a warning and a
2539 subsequent note containing a spelling suggestion. Avoid
2540 computing the suggestion if -Wpragmas warnings are being
2541 suppressed.
2542
25432020-11-09 Patrick Palka <ppalka@redhat.com>
2544
2545 PR testsuite/97117
2546 * c-indentation.c (get_visual_column): Remove location_t
2547 parameter. Move the column-tracking diagnostic code from here
2548 to ...
2549 (should_warn_for_misleading_indentation): ... here, before the
2550 early exit for when the loci are not all distinct. Don't pass a
2551 location_t argument to get_visual_column.
2552 (assert_get_visual_column_succeeds): Don't pass a location_t
2553 argument to get_visual_column.
2554 (assert_get_visual_column_fails): Likewise.
2555
fb95de7a
GA
25562020-11-08 Iain Sandoe <iain@sandoe.co.uk>
2557
2558 * c-common.h (OBJC_IS_PATTR_KEYWORD): Add class to the list
2559 of keywords accepted in @property attribute contexts.
2560 * c-objc.h (enum objc_property_attribute_group): Add
2561 OBJC_PROPATTR_GROUP_CLASS.
2562 (enum objc_property_attribute_kind): Add
2563 OBJC_PROPERTY_ATTR_CLASS.
2564
2da7ee05
GA
25652020-11-07 Iain Sandoe <iain@sandoe.co.uk>
2566
2567 * c-common.c (c_common_reswords): Add 'atomic' property
2568 attribute.
2569 * c-common.h (enum rid): Add RID_PROPATOMIC for atomic
2570 property attributes.
2571
25722020-11-07 Iain Sandoe <iain@sandoe.co.uk>
2573
2574 * c-attribs.c (handle_nsobject_attribute): New.
2575 * c.opt: Add WNSObject-attribute.
2576
44cab2d8
GA
25772020-11-06 Iain Sandoe <iain@sandoe.co.uk>
2578
2579 * c-objc.h (enum objc_property_attribute_group): New
2580 (enum objc_property_attribute_kind): New.
2581 (OBJC_PROPATTR_GROUP_MASK): New.
2582 (struct property_attribute_info): Small class encapsulating
2583 parser output from property attributes.
2584 (objc_prop_attr_kind_for_rid): New
2585 (objc_add_property_declaration): Simplify interface.
2586 * stub-objc.c (enum rid): Dummy type.
2587 (objc_add_property_declaration): Simplify interface.
2588 (objc_prop_attr_kind_for_rid): New.
2589
25902020-11-06 Nathan Sidwell <nathan@acm.org>
2591
2592 * c-ada-spec.c (collect_ada_nodes): Rename
2593 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
2594 (collect_ada_node): Likewise.
2595 (dump_forward_type): Likewise.
2596 * c-common.c (set_underlying_type): Rename
2597 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
2598 (user_facing_original_type, c_common_finalize_early_debug): Likewise.
2599
26002020-11-06 Jakub Jelinek <jakub@redhat.com>
2601
2602 * c-common.c (verify_sequence_points): Remove DEBUG_FUNCTION.
2603
0cfd9109
GA
26042020-11-05 Marek Polacek <polacek@redhat.com>
2605
2606 PR c++/97675
2607 * c.opt (Wexceptions): New option.
2608
26092020-11-05 Marek Polacek <polacek@redhat.com>
2610
2611 PR c++/25814
2612 * c.opt (Wvexing-parse): New option.
2613
35c125cb
GA
26142020-11-04 Jakub Jelinek <jakub@redhat.com>
2615
2616 PR c++/97670
2617 * c-omp.c (c_omp_split_clauses): Look through array reductions to find
2618 underlying decl to clear in the allocate_head bitmap.
2619
26202020-11-04 Iain Sandoe <iain@sandoe.co.uk>
2621
2622 * c-objc.h (objc_non_constant_expr_p): New.
2623 * stub-objc.c (objc_non_constant_expr_p): New.
2624
fd2325ea
GA
26252020-11-03 Nathan Sidwell <nathan@acm.org>
2626
2627 * c.opt (MQ,MT): Reword description to be make-agnostic.
2628
88ce3d5f
GA
26292020-11-02 Nathan Sidwell <nathan@acm.org>
2630
2631 * c-opts.c (c_common_post_options): Move var decl to its
2632 initialization point.
2633
26342020-11-01 Iain Sandoe <iain@sandoe.co.uk>
2635
2636 * c-lex.c (c_lex_with_flags): When combining '@' with a
2637 keyword for Objective-C, combine the location ranges too.
2638
26392020-10-30 Qing Zhao <qing.zhao@oracle.com>
2640 H.J.Lu <hjl.tools@gmail.com>
2641
2642 * c-attribs.c (c_common_attribute_table): Add new attribute
2643 zero_call_used_regs.
2644 (handle_zero_call_used_regs_attribute): New function.
2645
e93aae4a
GA
26462020-10-28 Marek Polacek <polacek@redhat.com>
2647
2648 PR c++/97573
2649 * c-opts.c (c_common_post_options): In C++20, turn on
2650 -Wdeprecated-enum-enum-conversion and
2651 -Wdeprecated-enum-float-conversion.
2652 * c.opt (Wdeprecated-enum-enum-conversion,
2653 Wdeprecated-enum-float-conversion): New options.
2654 (Wenum-conversion): Allow for C++ too.
2655
26562020-10-28 Jakub Jelinek <jakub@redhat.com>
2657
2658 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALLOCATE.
2659 * c-omp.c: Include bitmap.h.
2660 (c_omp_split_clauses): Handle OMP_CLAUSE_ALLOCATE.
2661
f19e7c8d
GA
26622020-10-26 Ville Voutilainen <ville.voutilainen@gmail.com>
2663
2664 * c-common.c (__is_nothrow_assignable): New.
2665 (__is_nothrow_constructible): Likewise.
2666 * c-common.h (RID_IS_NOTHROW_ASSIGNABLE): New.
2667 (RID_IS_NOTHROW_CONSTRUCTIBLE): Likewise.
2668
efe71fcc
GA
26692020-10-23 Jan Hubicka <hubicka@ucw.cz>
2670
2671 * c-common.c (c_common_finalize_early_debug): Update for new thunk api.
2672
26732020-10-23 Marek Polacek <polacek@redhat.com>
2674
2675 PR c++/91741
2676 * c-common.c (verify_tree): Handle PAREN_SIZEOF_EXPR.
2677 (c_common_init_ts): Likewise.
2678 * c-common.def (PAREN_SIZEOF_EXPR): New tree code.
2679 * c-common.h (maybe_warn_sizeof_array_div): Declare.
2680 * c-warn.c (sizeof_pointer_memaccess_warning): Unwrap NOP_EXPRs.
2681 (maybe_warn_sizeof_array_div): New function.
2682 * c.opt (Wsizeof-array-div): New option.
2683
26842020-10-23 Martin Sebor <msebor@redhat.com>
2685
2686 PR c/97463
2687 * c-warn.c (warn_parm_ptrarray_mismatch): Move null test earlier.
2688
56ddd5e2
GA
26892020-10-22 Martin Liska <mliska@suse.cz>
2690
2691 PR c/94722
2692 * c-attribs.c (handle_no_stack_protect_function_attribute): New.
2693 (handle_stack_protect_attribute): Add error message for a
2694 no_stack_protector function.
2695
26962020-10-22 Martin Liska <mliska@suse.cz>
2697
2698 * c-cppbuiltin.c (c_cpp_builtins): Use the stack_protector enum.
2699
27002020-10-22 Jan Hubicka <hubicka@ucw.cz>
2701
2702 * c-gimplify.c: Include tree-nested.h
2703 (c_genericize): Update for new nested function info.
2704
b2698c21
GA
27052020-10-14 Martin Sebor <msebor@redhat.com>
2706
2707 PR c/97413
2708 * c-attribs.c (build_attr_access_from_parms): Wrap chain of VLA
2709 bounds in an extra list.
2710
7e9282ae
GA
27112020-10-05 Richard Biener <rguenther@suse.de>
2712 Jakub Jelinek <jakub@redhat.com>
2713
2714 PR c++/97197
2715 * c-pretty-print.c: Include langhooks.h.
2716 (c_pretty_printer::postfix_expression): Handle TARGET_MEM_REF as
2717 expression.
2718 (c_pretty_printer::expression): Handle TARGET_MEM_REF as
2719 unary_expression.
2720 (c_pretty_printer::unary_expression): Handle TARGET_MEM_REF.
2721
660bfe61
GA
27222020-09-30 Martin Sebor <msebor@redhat.com>
2723
2724 PR middle-end/97189
2725 * c-attribs.c (append_access_attr): Use the function declaration
2726 location for a warning about an attribute access argument.
2727
93bca37c
GA
27282020-09-29 Marek Polacek <polacek@redhat.com>
2729
2730 PR c++/94695
2731 * c.opt (Wrange-loop-construct): New option.
2732
82b77dee
GA
27332020-09-23 Martin Sebor <msebor@redhat.com>
2734
2735 PR c/97131
2736 * c-warn.c (warn_parm_ptrarray_mismatch): Handle more invalid input.
2737
27382020-09-23 Marek Polacek <polacek@redhat.com>
2739
2740 PR c/97125
2741 * c-gimplify.c (c_genericize): Only call do_warn_duplicated_branches_r
2742 after loops and other structured control constructs have been lowered.
2743
521d2711
GA
27442020-09-22 Jakub Jelinek <jakub@redhat.com>
2745
2746 * c.opt (Wbuiltin-declaration-mismatch): Fix typo in variable name:
2747 warn_builtin_declaraion_mismatch -> warn_builtin_declaration_mismatch.
2748
44135373
GA
27492020-09-21 Marek Polacek <polacek@redhat.com>
2750
2751 * c.opt (Wctad-maybe-unsupported): New option.
2752
2fe5b7d1
GA
27532020-09-19 Martin Sebor <msebor@redhat.com>
2754
2755 PR c/50584
2756 * c-common.h (warn_parm_array_mismatch): Declare new function.
2757 (has_attribute): Move declaration of an existing function.
2758 (build_attr_access_from_parms): Declare new function.
2759 * c-warn.c (parm_array_as_string): Define new function.
2760 (plus_one): Define new function.
2761 (warn_parm_ptrarray_mismatch): Define new function.
2762 (warn_parm_array_mismatch): Define new function.
2763 (vla_bound_parm_decl): New function.
2764 * c.opt (-Warray-parameter, -Wvla-parameter): New options.
2765 * c-pretty-print.c (pp_c_type_qualifier_list): Don't print array type
2766 qualifiers here...
2767 (c_pretty_printer::direct_abstract_declarator): ...but instead print
2768 them in brackets here. Also print [static]. Strip extraneous
2769 expressions from VLA bounds.
2770
27712020-09-19 Martin Sebor <msebor@redhat.com>
2772
2773 PR c/50584
2774 * c-attribs.c (c_common_attribute_table): Add "arg spec" attribute.
2775 (handle_argspec_attribute): New function.
2776 (get_argument, get_argument_type): New functions.
2777 (append_access_attrs): Add overload. Handle internal attribute
2778 representation in addition to external.
2779 (handle_access_attribute): Handle internal attribute representation
2780 in addition to external.
2781 (build_attr_access_from_parms): New function.
2782
27832020-09-19 Sandra Loosemore <sandra@codesourcery.com>
2784
2785 * c-gimplify.c (genericize_c_loop): Rewrite to match
2786 c_finish_loop in c-typeck.c.
2787
27882020-09-19 Sandra Loosemore <sandra@codesourcery.com>
2789
2790 * c-common.c (c_block_may_fallthrough): New, split from
2791 cxx_block_may_fallthrough in the cp front end.
2792 (c_common_init_ts): Move handling of loop and switch-related
2793 statements here from the cp front end.
2794 * c-common.def (FOR_STMT, WHILE_STMT, DO_STMT): Move here from
2795 cp front end.
2796 (BREAK_STMT, CONTINUE_STMT, SWITCH_STMT): Likewise.
2797 * c-common.h (c_block_may_fallthru): Declare.
2798 (bc_state_t): Move here from cp front end.
2799 (save_bc_state, restore_bc_state): Declare.
2800 (c_genericize_control_stmt): Declare.
2801 (WHILE_COND, WHILE_BODY): Likewise.
2802 (DO_COND, DO_BODY): Likewise.
2803 (FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY, FOR_SCOPE): Likewise.
2804 (SWITCH_STMT_COND, SWITCH_STMT_BODY): Likewise.
2805 (SWITCH_STMT_TYPE, SWITCH_STMT_SCOPE): Likewise.
2806 (SWITCH_STMT_ALL_CASES_P, SWITCH_STMT_NO_BREAK_P): Likewise.
2807 (LABEL_DECL_BREAK, LABEL_DECL_CONTINUE): Likewise.
2808 * c-dump.c (dump_stmt): Copy from cp front end.
2809 (c_dump_tree): Move code to handle structured loop and switch
2810 tree nodes here from cp front end.
2811 * c-gimplify.c: Adjust includes.
2812 (enum bc_t, bc_label, begin_bc_block, finish_bc_block): Move from
2813 cp front end.
2814 (save_bc_state, restore_bc_state): New functions using old code
2815 from cp front end.
2816 (get_bc_label, expr_loc_or_loc): Move from cp front end.
2817 (genericize_c_loop): Move from cp front end.
2818 (genericize_for_stmt, genericize_while_stmt): Likewise.
2819 (genericize_do_stmt, genericize_switch_stmt): Likewise.
2820 (genericize_continue_stmt, genericize_break_stmt): Likewise.
2821 (genericize_omp_for_stmt): Likewise.
2822 (c_genericize_control_stmt): New function using code split from
2823 cp front end.
2824 (c_genericize_control_r): New.
2825 (c_genericize): Call walk_tree with c_genericize_control_r.
2826 * c-pretty-print.c (c_pretty_printer::statement): Move code to handle
2827 structured loop and switch tree nodes here from cp front end.
2828
2aad20c0
GA
28292020-09-17 Patrick Palka <ppalka@redhat.com>
2830
2831 PR c/80076
2832 * c-indentation.c (should_warn_for_misleading_indentation): Move
2833 declarations of local variables closer to their first use.
2834 Handle virtual token locations by resolving them to their
2835 respective macro expansion points. If all three tokens are
2836 produced from the same macro expansion, then instead use their
2837 loci within the macro definition.
2838
ecde1b0a
GA
28392020-09-16 Martin Sebor <msebor@redhat.com>
2840
2841 PR c/78666
2842 PR c/96126
2843 * c-attribs.c (validate_attr_args): New function.
2844 (validate_attr_arg): Same.
2845 (handle_section_attribute): Call it. Introduce a local variable.
2846 (handle_alloc_size_attribute): Same.
2847 (handle_alloc_align_attribute): Same.
2848
50a71cd0
GA
28492020-09-14 Jakub Jelinek <jakub@redhat.com>
2850
2851 * c-attribs.c (handle_optimize_attribute): Adjust
2852 cl_optimization_save, cl_optimization_restore and
2853 build_optimization_node callers.
2854 * c-pragma.c (handle_pragma_optimize): Adjust
2855 build_optimization_node caller.
2856 (handle_pragma_push_options): Adjust
2857 build_optimization_node and build_target_option_node callers.
2858 (handle_pragma_pop_options, handle_pragma_reset_options):
2859 Adjust cl_optimization_restore callers.
2860
8f7ea26a
GA
28612020-08-28 Martin Sebor <msebor@redhat.com>
2862
2863 * c.opt (Wstringop-overread): New option.
2864
a6493809
GA
28652020-08-11 Jakub Jelinek <jakub@redhat.com>
2866
2867 PR c/96545
2868 * c-common.c (get_atomic_generic_size): Require that first argument's
2869 type points to a complete type and use tree_fits_uhwi_p instead of
2870 just INTEGER_CST TREE_CODE check for the TYPE_SIZE_UNIT.
2871
48cc2e46
GA
28722020-07-31 Martin Sebor <msebor@redhat.com>
2873
2874 PR c++/96003
2875 * c-common.c (check_function_arguments_recurse): Return early when
2876 no-warning bit is set.
2877
28782020-07-31 Richard Biener <rguenther@suse.de>
2879
2880 PR debug/96383
2881 * c-common.h (c_common_finalize_early_debug): Declare.
2882 * c-common.c: Include debug.h.
2883 (c_common_finalize_early_debug): finalize_early_debug langhook
2884 implementation generating debug for extern declarations.
2885
e71dab87
GA
28862020-07-27 Nathan Sidwell <nathan@acm.org>
2887
2888 * c-common.c (try_to_locate_new_include_insertion_point): Use
2889 strcmp, not pointer equality.
2890
ae2e0bc1
GA
28912020-07-25 Martin Sebor <msebor@redhat.com>
2892
2893 PR c++/96310
2894 * c-common.c (check_nonnull_arg): Print note only when warning was
2895 issued.
2896
3ea9abca
GA
28972020-07-22 Tobias Burnus <tobias@codesourcery.com>
2898
2899 * c-omp.c (c_finish_omp_critical): Check for no name but
2900 nonzero hint provided.
2901
0933f508
GA
29022020-07-20 Jason Merrill <jason@redhat.com>
2903
2904 * c-cppbuiltin.c (c_cpp_builtins): Update
2905 __cpp_nontype_template_args for C++20.
2906
29072020-07-20 Martin Sebor <msebor@redhat.com>
2908
2909 PR c/96249
2910 * c.opt: Remove stray text.
2911
8ca07a30
GA
29122020-07-14 Lewis Hyatt <lhyatt@gmail.com>
2913
2914 PR other/86904
2915 * c-indentation.c (should_warn_for_misleading_indentation): Get
2916 global tabstop from the new source.
2917 * c-opts.c (c_common_handle_option): Remove handling of -ftabstop, which
2918 is now a common option.
2919 * c.opt: Likewise.
2920
a82c4c4c 29212020-07-08 Eric Botcazou <ebotcazou@adacore.com>
50873cc5
GA
2922
2923 * c.opt (Wscalar-storage-order): Add explicit variable.
2924
f60ee68d
GA
29252020-07-07 Nathan Sidwell <nathan@acm.org>
2926
2927 * c-opts.c (c_common_post_options): Add 'injecting' arg to
2928 cpp_read_main_file.
2929 (c_finish_options): Add linemap_line_start calls for builtin and cmd
2930 maps. Force token position to line_table's highest line.
2931 * c-ppoutput.c (print_line_1): Refactor, print line zero.
2932 (cb_define): Always increment source line.
2933
4077d74c
GA
29342020-07-06 Martin Sebor <msebor@redhat.com>
2935
2936 PR c++/95984
2937 * c-common.c (check_function_nonnull): Avoid checking syntesized calls
2938 to stub lambda objects with null this pointer.
2939 (check_nonnull_arg): Handle C++ nullptr.
2940
b5f24739
GA
29412020-07-02 Jason Merrill <jason@redhat.com>
2942 Jakub Jelinek <jakub@redhat.com>
2943
2944 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_consteval.
2945
46fbb6c6
GA
29462020-06-30 Jakub Jelinek <jakub@redhat.com>
2947
2948 PR c++/95963
2949 * c-common.c (check_function_arguments_recurse): Don't crash on
2950 calls to internal functions.
2951
69273534
GA
29522020-06-28 Martin Sebor <msebor@redhat.com>
2953
2954 PR c++/86568
2955 * c-common.c (struct nonnull_arg_ctx): Add members.
2956 (check_function_nonnull): Use nonnull_arg_ctx as argument. Handle
2957 C++ member functions specially. Consider the this pointer implicitly
2958 nonnull.
2959 (check_nonnull_arg): Use location of argument when available.
2960 (check_function_arguments): Use nonnull_arg_ctx as argument.
2961
9a33c41f
GA
29622020-06-27 Jakub Jelinek <jakub@redhat.com>
2963
2964 PR middle-end/95903
2965 * c-common.c (pointer_int_sum): Use TYPE_OVERFLOW_UNDEFINED instead of
2966 !TYPE_UNSIGNED check to see if we can apply distributive law and handle
2967 smaller precision intop operands separately.
2968
c9c05f73
GA
29692020-06-26 Marek Polacek <polacek@redhat.com>
2970
2971 * c-opts.c (c_common_init_options): Default to gnu++17.
2972
aff95ee7
GA
29732020-06-17 Jonathan Wakely <jwakely@redhat.com>
2974
bd0a89dc 2975 PR c/95378
aff95ee7
GA
2976 * c-common.c (get_atomic_generic_size): Check cv-qualifiers in
2977 pointer arguments.
2978
56638b9b
GA
29792020-06-16 Jakub Jelinek <jakub@redhat.com>
2980
2981 * c-common.h (c_omp_check_loop_iv_exprs): Add an int argument.
2982 * c-omp.c (struct c_omp_check_loop_iv_data): Add maybe_nonrect and
2983 idx members.
2984 (c_omp_is_loop_iterator): New function.
2985 (c_omp_check_loop_iv_r): Use it. Add support for silent scanning
2986 if outer loop iterator is present. Perform duplicate checking through
2987 hash_set in the function rather than expecting caller to do that.
2988 Pass NULL instead of d->ppset to walk_tree_1.
2989 (c_omp_check_nonrect_loop_iv): New function.
2990 (c_omp_check_loop_iv): Use it. Fill in new members, allow
2991 non-rectangular loop forms, diagnose multiple associated loops with
2992 the same iterator. Pass NULL instead of &pset to walk_tree_1.
2993 (c_omp_check_loop_iv_exprs): Likewise.
2994
ec6ffbb9
GA
29952020-06-10 Martin Liska <mliska@suse.cz>
2996
2997 PR tree-optimization/92860
2998 * c-attribs.c (handle_optimize_attribute):
2999 Save global options and compare it after parsing of function
3000 attribute.
3001 * c-pragma.c (opt_stack::saved_global_options): New field.
3002 (handle_pragma_push_options): Save global_options.
3003 (handle_pragma_pop_options): Compare them after pop.
3004
b952c2cf
GA
30052020-06-09 Jakub Jelinek <jakub@redhat.com>
3006
3007 PR c/95580
3008 * c-pretty-print.c (c_pretty_printer::unary_expression): Handle the
3009 case when MEM_REF's first argument has type pointer to incomplete type.
3010
1a59f3db
GA
30112020-06-05 Jason Merrill <jason@redhat.com>
3012
3013 * c-pretty-print.c (pp_c_additive_expression): Handle negative
3014 operand to POINTER_PLUS_EXPR.
3015
3add3425
GA
30162020-06-04 Martin Sebor <msebor@redhat.com>
3017
3018 PR middle-end/10138
3019 PR middle-end/95136
3020 * c-attribs.c (append_access_attrs): Handle attr_access::none.
3021 (handle_access_attribute): Same.
3022
9a5b7438
GA
30232020-06-03 Mark Wielaard <mark@klomp.org>
3024
3025 * known-headers.cc (get_cp_stdlib_header_for_string_macro_name):
3026 New function.
3027 * known-headers.h (get_cp_stdlib_header_for_string_macro_name):
3028 New function declaration.
3029
30302020-06-03 Mark Wielaard <mark@klomp.org>
3031
3032 * known-headers.cc (get_string_macro_hint): New function.
3033 (get_stdlib_header_for_name): Use get_string_macro_hint.
3034 (get_c_stdlib_header_for_string_macro_name): New function.
3035 * known-headers.h (get_c_stdlib_header_for_string_macro_name):
3036 New function declaration.
3037
30382020-06-03 Tobias Burnus <tobias@codesourcery.com>
3039
3040 * c-common.h (c_omp_predetermined_mapping): Declare.
3041 * c-omp.c (c_omp_predetermined_mapping): New.
3042
af114c38
MW
30432020-05-22 Mark Wielaard <mark@klomp.org>
3044
3045 * known-headers.cc (get_stdlib_header_for_name): Add a new
3046 stdlib_hint array for stdbool and stdint.
3047
45c50b6a
MW
30482020-05-22 Mark Wielaard <mark@klomp.org>
3049
3050 * known-headers.cc (get_stdlib_header_for_name): Return
3051 "<stdbool.h>" for "bool", "true" or "false" when STDLIB_C and
3052 flag_isoc99.
3053
c22027a0
NS
30542020-05-20 Nathan Sidwell <nathan@acm.org>
3055
38a4db21
NS
3056 * c-common.c (try_to_locate_new_include_insertion_point): Revert change.
3057
c22027a0
NS
3058 * c-common.c (try_to_locate_new_include_insertion_point): Use
3059 strcmp to compare filenames.
3060 * c-lex.c (init_c_lex): Move declaration to initialization.
3061 * c-opts.c (handle_deferred_opts): Move cpp_get_deps call into
3062 deferred count loop.
3063
29f0e90d
JM
30642020-05-15 Jason Merrill <jason@redhat.com>
3065
3066 * c-opts.c (set_std_cxx20): Set flag_coroutines.
3067
b04445d4
JM
30682020-05-13 Jason Merrill <jason@redhat.com>
3069
3070 * c.opt (std=c++20): Make c++2a the alias.
3071 (std=gnu++20): Likewise.
3072 * c-common.h (cxx_dialect): Change cxx2a to cxx20.
3073 * c-opts.c: Adjust.
3074 * c-cppbuiltin.c: Adjust.
3075 * c-ubsan.c: Adjust.
3076 * c-warn.c: Adjust.
3077
11dd3be5
EB
30782020-05-12 Eric Botcazou <ebotcazou@adacore.com>
3079
3080 * c-ada-spec.c (dump_ads): Output pragma Warnings ("U"); on entry.
3081
b224c376
NS
30822020-05-08 Nathan Sidwell <nathan@acm.org>
3083
3084 Reimplement directives only processing.
3085 * c-ppoutput.c (token_streamer): Ne.
3086 (directives_only_cb): New. Swallow ...
3087 (print_lines_directives_only): ... this.
3088 (scan_translation_unit_directives_only): Reimplment using the
3089 published interface.
3090
f1d94677
MP
30912020-05-07 Marek Polacek <polacek@redhat.com>
3092
3093 * c-format.c (badwords): Add "nonstatic".
3094
9b95bb52
JJ
3095202-05-07 Jakub Jelinek <jakub@redhat.com>
3096
3097 PR c/94968
3098 * c-common.c (speculation_safe_value_resolve_params): Return false if
3099 error_operand_p (val2).
3100 (resolve_overloaded_builtin) <case BUILT_IN_SPECULATION_SAFE_VALUE_N>:
3101 Remove extraneous semicolon.
3102
530b4409 31032020-05-06 qing zhao <qing.zhao@oracle.com>
3104
3105 PR c/94230
3106 * c-indentation.c (get_visual_column): Add a hint to use the new
3107 -flarge-source-files option.
3108
b776bdca
SSF
31092020-05-05 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
3110
3111 * c-attribs.c (handle_vector_size_attribute): Add attribute
3112 nonnull for argument args in order to silence warning of
3113 uninitialized variable usage. Since this is local to the
3114 compilation unit and thus cannot be checked at call sides by the
3115 compiler, added an assert statement in order to verify this.
3116
6607bdd9
L
31172020-05-01 H.J. Lu <hongjiu.lu@intel.com>
3118
3119 PR target/93492
3120 * c-attribs.c (handle_patchable_function_entry_attribute): Limit
3121 value to USHRT_MAX (65535).
3122
691eeb65
JJ
31232020-04-29 Jakub Jelinek <jakub@redhat.com>
3124
3125 * c-format.c (PP_FORMAT_CHAR_TABLE): Add %{ and %}.
3126
26d76be7
JJ
31272020-04-27 Jakub Jelinek <jakub@redhat.com>
3128
3129 PR c/94755
3130 * c-common.c (resolve_overloaded_builtin): Return error_mark_node for
3131 fncode == BUILT_IN_NONE before initialization of first_param.
3132
7291b2ed
MP
31332020-04-23 Marek Polacek <polacek@redhat.com>
3134
3135 PR c++/94733
3136 * c-attribs.c (find_tm_attribute): Use get_attribute_name instead of
3137 TREE_PURPOSE.
3138
58a29af8
PP
31392020-04-14 Patrick Palka <ppalka@redhat.com>
3140
3141 PR c++/85278
3142 * c-pretty-print.c (pp_c_pointer) <case REFERENCE_TYPE>: Print a double
3143 ampersand if it's an rvalue reference type.
3144
09f04139
MS
31452020-04-13 Martin Sebor <msebor@redhat.com>
3146
3147 PR c/92326
3148 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator): Avoid
3149 printing array bound for flexible array members.
3150
ee26baf4
IS
31512020-04-13 Iain Sandoe <iain@sandoe.co.uk>
3152
3153 * c-cppbuiltin.c (c_cpp_builtins): Update coroutines builtin
3154 define, per n4861.
3155
75efe9cb
RB
31562020-04-02 Richard Biener <rguenther@suse.de>
3157
3158 PR c/94392
3159 * c-opts.c (c_common_post_options): Enable -ffinite-loops
3160 for -O2 and C++11 or newer.
3161
75defde9
PP
31622020-03-28 Patrick Palka <ppalka@redhat.com>
3163
3164 * c.opt: Add -fconcepts-diagnostics-depth.
3165
52f24a9e
MS
31662020-03-27 Martin Sebor <msebor@redhat.com>
3167
3168 PR c++/94346
3169 * c-attribs.c (handle_copy_attribute): Avoid passing expressions
3170 to decl_attributes. Make handling of different kinds of entities
3171 more robust.
3172
ccacf77b
MS
31732020-03-27 Martin Sebor <msebor@redhat.com>
3174
3175 PR c++/94098
3176 * c-attribs.c (handle_access_attribute): Avoid setting TYPE_ATTRIBUTES
3177 here.
3178
ca6c7225
JJ
31792020-03-23 Jakub Jelinek <jakub@redhat.com>
3180
3181 PR c++/91993
3182 * c-warn.c (warnings_for_convert_and_check): For expr and/or
3183 result being COMPOUND_EXPRs, skip to ultimate rhs.
3184
1aa22b19
RS
31852020-03-20 Richard Sandiford <richard.sandiford@arm.com>
3186
3187 PR middle-end/94072
3188 * c-common.c (c_common_type_for_mode): Before using a registered
3189 built-in type, check that the vectorness of the type matches
3190 the vectorness of the mode.
3191
700d4cb0
JJ
31922020-03-17 Jakub Jelinek <jakub@redhat.com>
3193
3194 * c-common.c (resolve_overloaded_builtin): Fix up duplicated word
3195 issue in a diagnostic message.
3196
b408e010
LH
31972020-03-15 Lewis Hyatt <lhyatt@gmail.com>
3198
3199 * c.opt: Avoid redundancy in the help text.
3200
e78e50d5
MP
32012020-03-02 Marek Polacek <polacek@redhat.com>
3202
3203 PR c++/93958 - add missing -std=gnu++20.
3204 * c.opt: Add -std=gnu++20.
3205
649e1741
MS
32062020-03-01 Martin Sebor <msebor@redhat.com>
3207
3208 PR c++/92721
3209 * c-attribs.c (append_access_attrs): Correctly handle attribute.
3210 (handle_access_attribute): Same.
3211
7b60f3ba
JJ
32122020-02-25 Jakub Jelinek <jakub@redhat.com>
3213
3214 PR c/93858
3215 * c-pragma.c (handle_pragma_diagnostic): Add missing ? after
3216 "did you mean" hint in diagnostics.
3217
fb260504
JM
32182020-02-15 Jason Merrill <jason@redhat.com>
3219
3220 * c.opt: Add -std=c++20.
3221
1d757b09
EB
32222020-02-14 Eric Botcazou <ebotcazou@adacore.com>
3223
3224 * c-ada-spec.c: Include bitmap.h.
3225 (dump_ada_double_name): Rename into...
3226 (dump_anonymous_type_name): ...this. Always use the TYPE_UID.
3227 (dump_ada_array_type): Adjust to above renaming. Robustify.
3228 (dump_nested_types_1): New function copied from... Add dumped_types
3229 parameter and pass it down to dump_nested_type.
3230 (dump_nested_types): ...this. Remove parent parameter. Just call
3231 dump_nested_types_1 on an automatic bitmap.
3232 (dump_nested_type): Add dumped_types parameter.
3233 <ARRAY_TYPE>: Do not dump it if already present in dumped_types.
3234 Adjust recursive calls and adjust to above renaming.
3235 (dump_ada_declaration): Adjust call to dump_nested_types.
3236 Tidy up and adjust to above renaming.
3237 (dump_ada_specs): Initialize and release bitmap obstack.
3238
0cc575e4
MS
32392020-02-10 Martin Sebor <msebor@redhat.com>
3240
3241 PR c/93640
3242 * c-attribs.c (handle_access_attribute): Correct off-by-one mistakes.
3243
a59aa302
JJ
32442020-02-10 Jakub Jelinek <jakub@redhat.com>
3245
3246 PR other/93641
3247 * c-format.c (check_plain): Fix up last argument of strncasecmp.
3248 Remove useless extra test.
3249
e464fc90
TB
32502020-02-03 Julian Brown <julian@codesourcery.com>
3251 Tobias Burnus <tobias@codesourcery.com>
3252
3253 * c-cppbuiltin.c (c_cpp_builtins): Update _OPENACC define to 201711.
3254
e3b6c052
JM
32552020-01-29 Jason Merrill <jason@redhat.com>
3256
3257 PR c++/89357
3258 * c-attribs.c (check_cxx_fundamental_alignment_constraints): Remove.
3259
6d00f052
JM
32602020-01-23 Jason Merrill <jason@redhat.com>
3261
3262 * c-warn.c (conversion_warning): Change -Wsign-conversion handling.
3263
8a990ffa
MS
32642020-01-23 Martin Sebor <msebor@redhat.com>
3265
3266 PR c/84919
3267 * c-common.c (check_function_arguments): Avoid overlap checking
3268 of sprintf functions.
3269
55b7df8b
JM
32702020-01-22 Jason Merrill <jason@redhat.com>
3271
3272 PR testsuite/93391 - PR 40752 test fails with unsigned plain char.
3273 PR c++/40752
3274 * c-warn.c (conversion_warning): Check operands only after checking
3275 the whole expression. Don't check second operand of + for sign.
3276
c77074d0
JM
32772020-01-21 Jason Merrill <jason@redhat.com>
3278 Manuel López-Ibáñez <manu@gcc.gnu.org>
3279
3280 PR c++/40752 - useless -Wconversion with short +=.
3281 * c.opt (-Warith-conversion): New.
3282 * c-warn.c (conversion_warning): Recurse for operands of
3283 operators. Only warn about the whole expression with
3284 -Warith-conversion.
3285
731dbfc3
JM
32862020-01-21 Jason Merrill <jason@redhat.com>
3287
3288 * c-common.c (unsafe_conversion_p): Don't warn, return UNSAFE_SIGN.
3289 * c-warn.c (conversion_warning): Warn about UNSAFE_SIGN.
3290
ad1a3914
NS
32912020-01-20 Nathan Sidwell <nathan@acm.org>
3292
3293 PR preprocessor/80005
3294 * c-cppbuiltins.c (c_cpp_builtins): Don't define __has_include{,_next}.
3295
49789fd0
IS
32962020-01-18 Iain Sandoe <iain@sandoe.co.uk>
3297
3298 * c-common.c (co_await, co_yield, co_return): New.
3299 * c-common.h (RID_CO_AWAIT, RID_CO_YIELD,
3300 RID_CO_RETURN): New enumeration values.
3301 (D_CXX_COROUTINES): Bit to identify coroutines are active.
3302 (D_CXX_COROUTINES_FLAGS): Guard for coroutine keywords.
3303 * c-cppbuiltin.c (__cpp_coroutines): New cpp define.
3304 * c.opt (fcoroutines): New command-line switch.
3305
4bc1899b
DM
33062020-01-10 David Malcolm <dmalcolm@redhat.com>
3307
3308 * c-format.c (local_event_ptr_node): New.
3309 (PP_FORMAT_CHAR_TABLE): Add entry for "%@".
3310 (init_dynamic_diag_info): Initialize local_event_ptr_node.
3311 * c-format.h (T_EVENT_PTR): New define.
3312
f25e33fa
MS
33132020-01-10 Martin Sebor <msebor@redhat.com>
3314
3315 PR c/93132
3316 * c-attribs.c (append_access_attrs): Validate against the translated
3317 access string rather than the human-readable representation.
3318
8d9254fc
JJ
33192020-01-01 Jakub Jelinek <jakub@redhat.com>
3320
3321 Update copyright years.
3322
39292e25
EB
33232019-12-20 Eric Botcazou <ebotcazou@adacore.com>
3324
3325 * c-ada-spec.h (decl_sloc): Delete.
3326 * c-ada-spec.c (decl_sloc): Make static.
3327
519d7496
JB
33282019-12-19 Julian Brown <julian@codesourcery.com>
3329
3330 * c-common.h (c_omp_map_clause_name): Add prototype.
3331 * c-omp.c (c_omp_map_clause_name): New function.
3332 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ATTACH and
3333 PRAGMA_OACC_CLAUSE_DETACH.
3334
a6163563
JB
33352019-12-19 Julian Brown <julian@codesourcery.com>
3336 Maciej W. Rozycki <macro@codesourcery.com>
3337 Tobias Burnus <tobias@codesourcery.com>
3338 Thomas Schwinge <thomas@codesourcery.com>
3339
3340 * c-pragma.h (pragma_omp_clause): Add
3341 PRAGMA_OACC_CLAUSE_NO_CREATE.
3342
e8f1ade2
MS
33432019-12-17 Martin Sebor <msebor@redhat.com>
3344
3345 PR c++/61339
3346 * c.opt (-Wmismatched-tags, -Wredundant-tags): New options.
3347
368877a1
DM
33482019-12-11 David Malcolm <dmalcolm@redhat.com>
3349
3350 * c-pretty-print.c (c_pretty_printer::clone): New vfunc
3351 implementation.
3352 * c-pretty-print.h (c_pretty_printer::clone): New vfunc decl.
3353
d68f5d45
DM
33542019-12-09 David Malcolm <dmalcolm@redhat.com>
3355
3356 * c-format.c (range_label_for_format_type_mismatch::get_text):
3357 Replace label_text ctor called with true with label_text::take.
3358
d3e28653
DM
33592019-12-09 David Malcolm <dmalcolm@redhat.com>
3360
3361 * c-format.c (selftest::test_type_mismatch_range_labels): Remove
3362 initial newline from expected outputs.
3363 * c-opts.c (c_diagnostic_finalizer): Add pp_newline call before
3364 call to diagnostic_show_locus.
3365
abd6d8cc
JJ
33662019-12-06 Jakub Jelinek <jakub@redhat.com>
3367
3368 * c-cppbuiltin.c (c_cpp_builtins): Don't define __cpp_consteval for
3369 now.
3370
7906797e
MP
33712019-12-05 Marek Polacek <polacek@redhat.com>
3372 Jakub Jelinek <jakub@redhat.com>
3373
3374 PR c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.
3375 * c-cppbuiltin.c (c_cpp_builtins): Adjust the value of __cpp_constexpr.
3376
5c04da88
MP
33772019-12-05 Marek Polacek <polacek@redhat.com>
3378
3379 PR c++/92271 - make __is_same alias for __is_same_as.
3380 * c-common.c: Add __is_same, an alias for __is_same_as.
3381
43aae289
MP
33822019-12-03 Marek Polacek <polacek@redhat.com>
3383
3384 PR c++/91363 - P0960R3: Parenthesized initialization of aggregates.
3385 * c-cppbuiltin.c (c_cpp_builtins): Predefine
3386 __cpp_aggregate_paren_init=201902 for -std=c++2a.
3387
d7ddfbcb
JH
33882019-11-30 Jan Hubicka <hubicka@ucw.cz>
3389
3390 * c-attribs.c (handle_symver_attribute): New function
3391 (c_common_attributes): Add symver.
3392
65ef05d0
RS
33932019-11-30 Richard Sandiford <richard.sandiford@arm.com>
3394
3395 * c-common.c (pointer_int_sum): Use verify_type_context to check
3396 whether the target allows pointer arithmetic for the types involved.
3397 (c_sizeof_or_alignof_type, c_alignof_expr): Use verify_type_context
3398 to check whether the target allows sizeof and alignof operations
3399 for the types involved.
3400
1a291106
JM
34012019-11-27 Jason Merrill <jason@redhat.com>
3402
3403 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
3404
05d6cb1a
JJ
34052019-11-26 Jakub Jelinek <jakub@redhat.com>
3406
3407 PR c++/61414
3408 * c-attribs.c (handle_mode_attribute): Add mode attribute to
3409 ENUMERAL_TYPEs.
3410
5b8d9367
JM
34112019-11-25 Joseph Myers <joseph@codesourcery.com>
3412
3413 PR c/91985
3414 * c-common.c (c_common_type_for_mode): Handle decimal
3415 floating-point types being NULL_TREE.
3416 * c-format.c (get_format_for_type_1): Handle specified types being
3417 NULL_TREE.
3418 * c-lex.c (interpret_float): Give an error for decimal
3419 floating-point constants when decimal floating-point not
3420 supported.
3421
1fbf51cb
JJ
34222019-11-23 Jakub Jelinek <jakub@redhat.com>
3423
3424 PR middle-end/83859
3425 * c-attribs.c (append_access_attrs): Avoid buffer overflow. Avoid
3426 memory leak. Use XNEWVEC macro. Use auto_diagnostic_group to
3427 group warning with inform together.
3428 (handle_access_attribute): Formatting fix.
3429
761df906
JJ
34302019-11-22 Jakub Jelinek <jakub@redhat.com>
3431
bdaf8be1
JJ
3432 PR c/90677
3433 * c-common.h (identifier_global_tag): Declare.
3434 * c-format.c (get_pointer_to_named_type): Renamed to ...
3435 (get_named_type): ... this. Use identifier_global_tag instead of
3436 identifier_global_value, handle the return value being a TYPE_P.
3437 (init_dynamic_diag_info): Adjust get_pointer_to_named_type callers
3438 to call get_named_type instead. Formatting fixes.
3439
c2ecce6d 3440 Implement P1902R1, Missing feature-test macros 2017-2019.
761df906
JJ
3441 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_init_captures
3442 and __cpp_generic_lambdas for -std=c++2a. Define
3443 __cpp_designated_initializers, __cpp_constexpr_in_decltype and
3444 __cpp_consteval for -std=c++2a. Remove a FIXME comment about
3445 __cpp_concepts for -std=c++2a.
3446
54aa6b58
MS
34472019-11-22 Martin Sebor <msebor@redhat.com>
3448
3449 PR middle-end/83859
3450 * c-attribs.c (handle_access_attribute): New function.
3451 (c_common_attribute_table): Add new attribute.
3452 (get_argument_type): New function.
3453 (append_access_attrs): New function.
3454 (get_nonnull_operand): Rename...
3455 (get_attribute_operand): ...to this.
3456 * c-common.c (get_nonnull_operand): Rename...
3457 (get_attribute_operand): ...to this.
3458
6c80b1b5
JM
34592019-11-21 Joseph Myers <joseph@codesourcery.com>
3460
3461 * c-attribs.c (handle_fallthrough_attribute): Use pedwarn instead
3462 of warning.
3463
192961ff
JM
34642019-11-19 Joseph Myers <joseph@codesourcery.com>
3465
3466 * c-common.c (attribute_fallthrough_p): In C, use pedwarn not
3467 warning for standard attributes mixed with fallthrough attributes.
3468
f8aea5e3
JM
34692019-11-15 Joseph Myers <joseph@codesourcery.com>
3470
3471 * c-attribs.c (handle_fallthrough_attribute): Remove static.
3472 * c-common.h (handle_fallthrough_attribute): Declare.
3473
2cc94aa8
JM
34742019-11-15 Joseph Myers <joseph@codesourcery.com>
3475
3476 * c-attribs.c (handle_deprecated_attribute): Remove static.
3477 * c-common.h (handle_deprecated_attribute): Declare.
3478
7c5890cc
JM
34792019-11-14 Joseph Myers <joseph@codesourcery.com>
3480
3481 * c-lex.c (lex_charconst): Make CPP_UTF8CHAR constants unsigned
3482 char for C.
3483
b2417b59
JJ
34842019-11-14 Jakub Jelinek <jakub@redhat.com>
3485
d0ec7c93
JJ
3486 * c-omp.c (c_omp_check_context_selector): Add nvidia to the list of
3487 valid vendors.
3488
b2417b59
JJ
3489 * c-omp.c (c_omp_check_context_selector): Handle name lists
3490 containing string literals. Don't diagnose atomic_default_mem_order
3491 with multiple props.
3492
00be2a5f
JM
34932019-11-13 Joseph Myers <joseph@codesourcery.com>
3494
3495 * c-cppbuiltin.c (builtin_define_float_constants): Also define
3496 NORM_MAX constants. Update call to get_max_float.
3497 (LAZY_HEX_FP_VALUES_CNT): Update value to include NORM_MAX
3498 constants.
3499
2dbad62d
EB
35002019-11-13 Eric Botcazou <ebotcazou@adacore.com>
3501
3502 * c-ada-spec.c (get_underlying_decl): Do not look through typedefs.
3503 (dump_forward_type): Do not generate a declaration for function types.
3504 (dump_nested_type) <ARRAY_TYPE>: Do not generate a nested declaration
3505 of the component type if it is declared in another file.
3506
6ed76044
ML
35072019-11-12 Martin Liska <mliska@suse.cz>
3508
3509 * c-opts.c (c_common_post_options):
3510 Use SET_OPTION_IF_UNSET.
3511
62aee289
MR
35122019-11-12 Maciej W. Rozycki <macro@codesourcery.com>
3513 Frederik Harwath <frederik@codesourcery.com>
3514
3515 gcc/c-family/
3516 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_SERIAL enumeration
3517 constant.
3518 * c-pragma.c (oacc_pragmas): Add "serial" entry.
3519
f486280c
RS
35202019-11-08 Richard Sandiford <richard.sandiford@arm.com>
3521
3522 * c-common.h (gnu_vector_type_p): New function.
3523 * c-common.c (c_build_vec_perm_expr): Require __builtin_shuffle
3524 vectors to satisfy gnu_vector_type_p.
3525 (c_build_vec_convert): Likewise __builtin_convertvector.
3526 (convert_vector_to_array_for_subscript): Likewise when applying
3527 implicit vector to array conversion.
3528 (scalar_to_vector): Likewise when converting vector-scalar
3529 operations to vector-vector operations.
3530
017c6491
JM
35312019-11-08 Joseph Myers <joseph@codesourcery.com>
3532
3533 * c.opt (Wold-style-definition): Initialize to -1.
3534 * c-opts.c (c_common_post_options): Set warn_old_style_definition
3535 to flag_isoc2x if not set explicitly.
3536
c01bd174
JM
35372019-11-07 Joseph Myers <joseph@codesourcery.com>
3538
3539 * c-attribs.c (parse_tm_stmt_attr): Handle scoped attributes.
3540
0df65305
JM
35412019-11-05 Jason Merrill <jason@redhat.com>
3542
3543 * c-opts.c (c_common_post_options): -fconcepts-ts implies
3544 -fconcepts.
3545
e0c866dd
KK
35462019-11-04 Kamlesh Kumar <kamleshbhalui@gmail.com>
3547
3548 * c-opts.c (c_common_post_options): Update
3549 latest_abi_version.
3550
f968ef9b
JJ
35512019-11-02 Jakub Jelinek <jakub@redhat.com>
3552
d0c464d2
JJ
3553 * c-common.h (c_omp_get_context_selector): Remove.
3554 * c-omp.c (c_omp_get_context_selector): Moved to omp-general.c
3555 and renamed to omp_get_context_selector.
3556
917dd789
JJ
3557 * c-omp.c (c_omp_mark_declare_variant): Use
3558 omp_context_selector_set_compare.
3559
f968ef9b
JJ
3560 PR c++/88335 - Implement P1073R3: Immediate functions
3561 * c-common.h (enum rid): Add RID_CONSTEVAL.
3562 * c-common.c (c_common_reswords): Add consteval.
3563
5f6705b7
JJ
35642019-11-01 Martin Sebor <msebor@redhat.com>
3565
3566 PR middle-end/91679
3567 PR middle-end/91647
3568 PR middle-end/91463
3569 PR middle-end/92312
3570 * c-pretty-print.c (direct_abstract_declarator): Print
3571 bound in zero-length arrays.
3572 * c.opt (-Wzero-length-bounds): New option.
3573
43f1814c
NS
35742019-10-30 Nathan Sidwell <nathan@acm.org>
3575
3576 * c-cppbuiltin.c (c_cpp_builtins): Add 'L' suffix to feature
3577 macros.
3578
ad1539d5
MS
35792019-10-28 Martin Sebor <msebor@redhat.com>
3580
3581 PR c/66970
3582 * c-common.c (c_common_nodes_and_builtins): Call c_define_builtins
3583 even when only preprocessing.
3584 * c-common.h (names_builtin_p): Declare new function.
3585 * c-lex.c (init_c_lex): Set has_builtin.
3586 (c_common_has_builtin): Define a new function.
3587 * c-ppoutput.c (init_pp_output): Set has_builtin.
3588
135df52c
JJ
35892019-10-24 Jakub Jelinek <jakub@redhat.com>
3590
3591 * c-common.h (c_omp_context_selector_matches): Remove.
3592 * c-omp.c (c_omp_context_selector_matches): Remove.
3593 * c-attribs.c (c_common_attribute_table): Add
3594 "omp declare target {host,nohost,block}" attributes.
3595
8ad0c477
JM
35962019-10-17 JeanHeyd Meneide <phdofthehouse@gmail.com>
3597
3598 * c-lex.c (c_common_has_attribute): Update nodiscard value.
3599
56898e43
RS
36002019-10-14 Richard Sandiford <richard.sandiford@arm.com>
3601
3602 * c-common.h (user_facing_original_type_p): Declare.
3603 * c-common.c: Include c-spellcheck.h.
3604 (user_facing_original_type_p): New function.
3605
20de9568
JJ
36062019-10-12 Jakub Jelinek <jakub@redhat.com>
3607
3608 * c-common.h (c_omp_mark_declare_variant,
3609 c_omp_context_selector_matches): Declare.
3610 * c-omp.c: Include attribs.h, gimplify.h, cgraph.h, symbol-summary.h
3611 and hsa-common.h.
3612 (c_omp_get_context_selector): Support second argument NULL.
3613 (c_omp_mark_declare_variant, c_omp_context_selector_matches): New
3614 functions.
3615 * c-attribs.c (c_common_attribute_table): Remove "omp declare variant"
3616 attribute, add "omp declare variant base" and
3617 "omp declare variant variant" attributes.
3618
175a85b2
JM
36192019-10-11 Joseph Myers <joseph@codesourcery.com>
3620
3621 * c.opt (Wc11-c2x-compat): Add CPP(cpp_warn_c11_c2x_compat)
3622 CppReason(CPP_W_C11_C2X_COMPAT).
3623
fe2bc27c
JM
36242019-10-11 Joseph Myers <joseph@codesourcery.com>
3625
3626 * c-common.c (c_common_reswords): Do not use D_EXT for _Decimal32,
3627 _Decimal64 and _Decimal128.
3628
27dfdc0f
JM
36292019-10-10 Joseph Myers <joseph@codesourcery.com>
3630
3631 * c-cppbuiltin.c (c_cpp_builtins): Do not define macros for DFP
3632 types if DFP not supported.
3633
94e7f906
JJ
36342019-10-10 Jakub Jelinek <jakub@redhat.com>
3635
3636 * c-common.h (c_omp_check_context_selector,
3637 c_omp_get_context_selector): Declare.
3638 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): Fix spelling
3639 in diagnostic message.
3640 (c_omp_check_context_selector, c_omp_get_context_selector): New
3641 functions.
3642 * c-attribs.c (c_common_attribute_table): Add "omp declare variant"
3643 attribute.
3644 (handle_omp_declare_variant_attribute): New function.
3645
a7160771
MS
36462019-10-09 Martin Sebor <msebor@redhat.com>
3647
3648 PR tree-optimization/90879
3649 * c.opt (-Wstring-compare): New option.
3650
cb57504a
JM
36512019-10-08 Andrew Sutton <asutton@lock3software.com>
3652 Jason Merrill <jason@redhat.com>
3653
3654 Update the concepts implementation to conform to the C++20
3655 specification, improve compile times, and generally clean up
3656 the implementation.
3657
3658 * c-cppbuiltin.c (c_cpp_builtins): Use new feature test values for
3659 concepts when -std=c++2a. Bump __cpp_concepts to 201907.
3660 * c.opt: Add -Wconcepts-ts.
3661 * c-opts.c (c_common_post_options): Warn when -fconcepts is used
3662 with -std=c++2a. Disable warning for -fconcepts in C++20 mode.
3663 (set_std_cxx2a): Enable concepts by default.
3664
fbb2a6dc
JM
36652019-10-08 Joseph Myers <joseph@codesourcery.com>
3666
3667 * c-opts.c (c_common_post_options): Set
3668 -fno-fp-int-builtin-inexact for C2X.
3669
8e007055
JJ
36702019-10-05 Jakub Jelinek <jakub@redhat.com>
3671
3672 PR c++/91369 - Implement P0784R7: constexpr new
3673 * c-cppbuiltin.c (c_cpp_builtins): Predefine
3674 __cpp_constexpr_dynamic_alloc=201907 for -std=c++2a.
3675
843f104d
JM
36762019-10-04 Joseph Myers <joseph@codesourcery.com>
3677
3678 PR c/82752
3679 * c-format.c (C_STD_VER): Handle C2x.
3680 (C_STD_NAME): Likewise.
3681 (strftime_flag_specs): Add 'O' modifier with 'p' flag.
3682 (time_char_table): Use separate entry for 'B' and 'b', with 'O'
3683 modifier allowed and 'p' flag.
3684 * c-format.h (enum format_std_version): Add STD_C2X.
3685 (struct format_char_info): Mention 'p' in comment on flags2.
3686
e9c9a142
DM
36872019-10-01 David Malcolm <dmalcolm@redhat.com>
3688
3689 * c-opts.c (c_diagnostic_finalizer): Temporarily clear prefix when
3690 calling diagnostic_show_locus, rather than destroying it afterwards.
3691
7552c36a
JJ
36922019-10-01 Jakub Jelinek <jakub@redhat.com>
3693
3694 PR c++/91925
3695 * c-warn.c (check_alignment_of_packed_member): Ignore FIELD_DECLs
3696 with NULL DECL_FIELD_OFFSET.
3697
8209db25
RS
36982019-10-01 Richard Sandiford <richard.sandiford@arm.com>
3699
3700 * c-pretty-print.c (pp_c_specifier_qualifier_list): If a vector type
3701 has a type name, use it in preference to the __vector syntax.
3702
9343bf99
RS
37032019-09-30 Richard Sandiford <richard.sandiford@arm.com>
3704
3705 * c-pretty-print.c (pp_c_parameter_type_list): Avoid printing
3706 two spaces between a comma and "...".
3707
59bc434a
JJ
37082019-09-27 Jakub Jelinek <jakub@redhat.com>
3709
3710 PR c++/88203
3711 * c-common.h (c_omp_predefined_variable): Declare.
3712 * c-omp.c (c_omp_predefined_variable): New function.
3713 (c_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
3714 for predefined variables.
3715
c6447c20
RS
37162019-09-27 Richard Sandiford <richard.sandiford@arm.com>
3717
3718 * c-common.h (build_function_call_vec): Take the original
3719 function decl as an optional final parameter.
3720 (check_builtin_function_arguments): Take the original function decl.
3721 * c-common.c (check_builtin_function_arguments): Likewise.
3722 Handle all built-in functions, not just BUILT_IN_NORMAL ones.
3723 Use targetm.check_builtin_call to check BUILT_IN_MD functions.
3724
c4438114
JM
37252019-09-15 Jason Merrill <jason@redhat.com>
3726
3727 * c-warn.c (warn_logical_operator): Strip location wrappers. Don't
3728 fold_for_warn in "|| mask" warning.
3729
68a57628
ML
37302019-09-10 Martin Liska <mliska@suse.cz>
3731
3732 * c.opt: Use newly added WarnRemoved.
3733
f48ef52e
ML
37342019-09-09 Martin Liska <mliska@suse.cz>
3735
3736 * c.opt: Update comment of removed
3737 options that are preserved only for backward
3738 compatibility.
3739
67f6e649
ML
37402019-09-06 Martin Liska <mliska@suse.cz>
3741
3742 PR c++/91125
3743 * c-common.c: Remove definition of flag_use_repository.
3744 * c-common.h: Likewise.
3745 * c-opts.c (c_common_handle_option):
3746 Do not handle OPT_frepo option.
3747 * c.opt: Mark the option with Deprecated.
3748
db9d2274
MP
37492019-09-04 Marek Polacek <polacek@redhat.com>
3750
3751 * c.opt (fdeduce-init-list): Ignored.
3752
68e2c199
PK
37532019-09-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
3754
3755 PR c/78736
3756 * c.opt (Wenum-conversion): New option.
3757
7a4418a5
JL
37582019-09-03 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3759
3760 * c-attribs.c (handle_section_attribute): Call the
3761 handle_generic_attribute target hook after performing target
3762 independent processing.
3763 (handle_noinit_attribute): Likewise.
3764
5f76ab15
ILT
37652019-09-03 Ian Lance Taylor <iant@golang.org>
3766
3767 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Always expand
3768 when using -fgo-dump-spec.
3769
ae0d3f6a
ML
37702019-09-02 Martin Liska <mliska@suse.cz>
3771
3772 PR c++/91155
3773 * c-common.c (fname_as_string): Use cxx_printable_name for
3774 __PRETTY_FUNCTION__ same as was used before r265711.
3775
8a902edb
MP
37762019-08-28 Marek Polacek <polacek@redhat.com>
3777
3778 Implement P1152R4: Deprecating some uses of volatile.
3779 PR c++/91361
3780 * c-opts.c (c_common_post_options): Enable -Wvolatile by
3781 default for C++2a, unless -Wno-deprecated.
3782 * c.opt (Wvolatile): New warning.
3783
4742dbe7
MP
37842019-08-28 Marek Polacek <polacek@redhat.com>
3785
3786 PR c++/91360 - Implement C++20 P1143R2: constinit.
3787 * c-common.c (c_common_reswords): Add constinit and __constinit.
3788 (keyword_is_decl_specifier): Handle RID_CONSTINIT.
3789 * c-common.h (enum rid): Add RID_CONSTINIT, RID_FIRST_CXX20, and
3790 RID_LAST_CXX20.
3791 (D_CXX20): Define.
3792 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_constinit.
3793 * c-format.c (cxx_keywords): Add "constinit".
3794 * c.opt (Wc++2a-compat, Wc++20-compat): New options.
3795
6a074892
JJ
37962019-08-27 Jakub Jelinek <jakub@redhat.com>
3797
3798 PR c++/91415
3799 * c-common.c (verify_tree): For LSHIFT_EXPR, RSHIFT_EXPR,
3800 COMPONENT_REF and ARRAY_REF in cxx_dialect >= cxx17 mode handle it
3801 like COMPOUND_EXPR rather than normal expression.
3802
22f8849d
IS
38032019-08-23 Iain Sandoe <iain@sandoe.co.uk>
3804
3805 PR pch/61250
3806 * c-lex.c (c_lex_with_flags): Don't call
3807 c_common_no_more_pch () from here.
3808
df375b03
JJ
38092019-08-23 Jakub Jelinek <jakub@redhat.com>
3810
3811 PR middle-end/91283
3812 * c-common.c (c_ts18661_flt_eval_method): Use flag_excess_precision
3813 instead of flag_excess_precision_cmdline.
3814 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): Likewise.
3815 * c-opts.c (c_common_post_options): Likewise.
3816
14b7950f
MS
38172019-08-22 Martin Sebor <msebor@redhat.com>
3818
3819 PR middle-end/91490
3820 * c-common.c (braced_list_to_string): Add argument and overload.
3821 Handle flexible length arrays and unions.
3822
8bb2ee59
EB
38232019-08-21 Eric Botcazou <ebotcazou@adacore.com>
3824
3825 * c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
3826 function declarations where arguments are missing. Rename variables.
3827
21c1e205
RB
38282019-08-15 Richard Biener <rguenther@suse.de>
3829
3830 * c-common.c (c_stddef_cpp_builtins): When the GIMPLE FE is
3831 enabled, define __SIZETYPE__.
3832
f0033821
CL
38332019-08-14 Christophe Lyon <christophe.lyon@linaro.org>
3834
3835 * c-attribs.c (c_common_attribute_table): Add "noinit" entry. Add
3836 exclusion with "section" attribute.
3837 (attr_noinit_exclusions): New table.
3838 (handle_noinit_attribute): New function.
3839
4d732405
RS
38402019-08-13 Richard Sandiford <richard.sandiford@arm.com>
3841
3842 PR middle-end/91421
3843 * c-common.c (resolve_overloaded_builtin): Use
3844 copy_decl_built_in_function.
3845
51ad8481
MS
38462019-08-13 Martin Sebor <msebor@redhat.com>
3847
3848 PR c/80619
3849 * c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
3850 (asm_fprintf_length_spec): Same.
3851 * c-format.h (format_lengths): Add FMT_LEN_w.
3852
77eb117f
JJ
38532019-08-10 Jakub Jelinek <jakub@redhat.com>
3854
3855 * c-pragma.h (enum pragma_omp_clause): Add
3856 PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
3857
398e3feb
JJ
38582019-08-07 Jakub Jelinek <jakub@redhat.com>
3859
3860 * c-pragma.h (enum pragma_omp_clause): Add
3861 PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. Set PRAGMA_OACC_CLAUSE_USE_DEVICE
3862 equal to PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR instead of being a separate
3863 enumeration value.
3864
ab574db6
MP
38652019-08-05 Marek Polacek <polacek@redhat.com>
3866
3867 PR c++/91338 - Implement P1161R3: Deprecate a[b,c].
3868 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
3869 default for C++2a, unless -Wno-deprecated.
3870 * c.opt (Wcomma-subscript): New warning.
3871
554a530f
JJ
38722019-07-20 Jakub Jelinek <jakub@redhat.com>
3873
3874 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_LOOP.
3875 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_BIND.
3876 * c-pragma.c (omp_pragmas_simd): Add PRAGMA_OMP_LOOP entry.
3877 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_LOOP.
3878 * c-omp.c (c_omp_split_clauses): Add support for 4 new combined
3879 constructs with the loop construct.
3880
1a888209
JJ
38812019-07-13 Jakub Jelinek <jakub@redhat.com>
3882
3883 PR c/91149
3884 * c-omp.c (c_omp_split_clauses): Fix a pasto in
3885 OMP_CLAUSE_REDUCTION_TASK handling.
3886
1fdd6f04
JJ
38872019-07-12 Jakub Jelinek <jakub@redhat.com>
3888
3889 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ORDER.
3890 * c-omp.c (c_omp_split_clauses): Handle splitting of OMP_CLAUSE_ORDER.
3891
99b1c316
MS
38922019-07-09 Martin Sebor <msebor@redhat.com>
3893
3894 PR c++/61339
1fdd6f04 3895 * c-opts.c (handle_deferred_opts): Change class-key of PODs to struct
99b1c316
MS
3896 and others to class.
3897 * c-pretty-print.h: Same.
3898
6c1dae73
MS
38992019-07-09 Martin Sebor <msebor@redhat.com>
3900
3901 PR c++/61339
3902 * c-format.c (check_argument_type): Change class-key from class to
3903 struct and vice versa to match convention and avoid -Wclass-is-pod
3904 and -Wstruct-no-pod.
3905 * c-pretty-print.h: Same.
3906
8ba6ea87
ML
39072019-07-03 Martin Liska <mliska@suse.cz>
3908
3909 * c-common.c (try_to_locate_new_include_insertion_point): Remove
3910 dead assignemts.
3911
83eb9522
JJ
39122019-07-03 Jakub Jelinek <jakub@redhat.com>
3913
3914 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_REDUCTION_INSCAN
3915 clauses on OMP_FOR rather than OMP_PARALLEL when OMP_FOR is combined
3916 with OMP_PARALLEL.
3917
1c6ffbab
QZ
39182019-07-02 qing zhao <qing.zhao@oracle.com>
3919
3920 PR preprocessor/90581
3921 * c-opts.c (c_common_handle_option): Handle -fmax-include-depth.
3922 * c.opt: Add new option -fmax-include-depth.
3923
7ffc7de5
JM
39242019-06-26 Jason Merrill <jason@redhat.com>
3925
3926 PR c++/55442 - memory-hog with highly recursive constexpr.
3927 * c.opt (fconstexpr-loop-limit): New.
3928
361af3e4
JJ
39292019-06-25 Jakub Jelinek <jakub@redhat.com>
3930
3931 PR sanitizer/90954
3932 * c-omp.c (c_finish_omp_atomic): Allow tree_invariant_p in addition
3933 to SAVE_EXPR in first operand of a COMPOUND_EXPR.
3934
ab20d992
JJ
39352019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3936
3937 * c-common.c (c_common_nodes_and_builtins): Define
3938 alternate "__intN__" name for "__intN" types.
3939
f4af4019
JH
39402019-06-24 Jan Hubicka <jh@suse.cz>
3941
3942 * c-common.c (braced_lists_to_strings): Check that
3943 type is array or integer prior checking string flag.
3944
da9e9b57
MB
39452019-06-21 Matthew Beliveau <mbelivea@redhat.com>
3946
3947 PR c++/90875 - added -Wswitch-outside-range option
3948 * c.opt (Wswitch-outside-range): Added new option.
3949 * c-warn.c (c_do_switch_warnings): Use OPT_Wswitch-outside-range.
3950
3f3d6a6f
MP
39512019-06-21 Marek Polacek <polacek@redhat.com>
3952
3953 PR c++/90953 - ICE with -Wmissing-format-attribute.
3954 * c-common.c (check_function_arguments_recurse): Use
3955 get_attribute_name.
3956 (check_missing_format_attribute): Likewise.
3957
1bf32c11
MP
39582019-06-19 Marek Polacek <polacek@redhat.com>
3959
3960 PR c++/60364 - noreturn after first decl not diagnosed.
3961 * c-attribs.c (handle_noreturn_attribute): No longer static.
3962 * c-common.h (handle_noreturn_attribute, attr_noreturn_exclusions):
3963 Declare.
3964 * c-format.c (check_function_format): Use get_attribute_name.
3965
a04c0734
MS
39662019-06-19 Martin Sebor <msebor@redhat.com>
3967
3968 PR translation/90156
3969 * c-format.c (function_format_info::format_type): Adjust type.
3970 (function_format_info::is_raw): New member.
3971 (decode_format_type): Adjust signature. Handle "raw" diag attributes.
3972 (decode_format_attr): Adjust call to decode_format_type.
3973 Avoid a redundant call to convert_format_name_to_system_name.
3974 Avoid abbreviating the word "arguments" in a diagnostic.
3975 (format_warning_substr): New function.
3976 (avoid_dollar_number): Quote dollar sign in a diagnostic.
3977 (finish_dollar_format_checking): Same.
3978 (check_format_info): Same.
3979 (struct baltoks_t): New.
3980 (c_opers, c_keywords, cxx_keywords, badwords, contrs): New arrays.
3981 (maybe_diag_unbalanced_tokens, check_tokens, check_plain): New
3982 functions.
3983 (check_format_info_main): Call check_plain. Use baltoks_t. Call
3984 maybe_diag_unbalanced_tokens.
3985 (handle_format_attribute): Spell out the word "arguments" in
3986 a diagnostic.
3987
d3786ebb
MB
39882019-06-11 Matthew Beliveau <mbelivea@redhat.com>
3989
3990 PR c++/90449 - add -Winaccessible-base option.
3991 * c.opt (Winaccessible-base): New option.
3992
bf38f7e9
JJ
39932019-06-10 Jakub Jelinek <jakub@redhat.com>
3994
3995 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCAN.
3996 * c-pragma.c (omp_pragmas_simd): Add #pragma omp scan.
3997 * c-omp.c (c_omp_split_clauses): Diagnose inscan reductions on
3998 combined/composite constructs where it is not allowed. Copy over
3999 OMP_CLAUSE_REDUCTION_INSCAN.
4000
0ecf545c
MS
40012019-06-05 Martin Sebor <msebor@redhat.com>
4002
4003 * c-attribs.c (handle_mode_attribute): Adjust quoting and hyphenation.
4004 (handle_alias_ifunc_attribute): Same.
4005 (handle_copy_attribute): Same.
4006 (handle_weakref_attribute): Same.
4007 (handle_nonnull_attribute): Same.
4008 * c-warn.c (warn_for_sign_compare): Same.
4009 (warn_for_restrict): Same.
4010 * c.opt: Same.
4011
36b34127
MS
40122019-06-05 Martin Sebor <msebor@redhat.com>
4013
4014 * c-pragma.c (handle_pragma_weak): Adjust quoting in a diagnostic.
4015 * c.opt (-Wformat-diag): Remove a spurious period.
4016
357a352f
JJ
40172019-05-29 Jakub Jelinek <jakub@redhat.com>
4018
4019 PR c/90628
4020 * c-common.c (check_builtin_function_arguments)
4021 <case BUILTIN_*_OVERFLOW>: Diagnose pointer to const qualified integer
4022 as last argument.
4023
2b8235ea
EB
40242019-05-23 Eric Botcazou <ebotcazou@adacore.com>
4025
4026 * c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
4027
6d86ddc4
ML
40282019-05-22 Martin Liska <mliska@suse.cz>
4029
4030 PR lto/90500
4031 * c-attribs.c (handle_copy_attribute): Do not copy
4032 target_clones attribute.
4033
419ba5b9
EB
40342019-05-21 Eric Botcazou <ebotcazou@adacore.com>
4035
4036 * c-ada-spec.h (enum cpp_operation): Add IS_ASSIGNMENT_OPERATOR.
4037 * c-ada-spec.c (print_assignment_operator): New function.
4038 (dump_ada_declaration) <FUNCTION_DECL>: Call it do dump explicit copy
4039 assignment operators declared as methods and filter out the others.
4040
e03436e7
TS
40412019-05-17 Thomas Schwinge <thomas@codesourcery.com>
4042
4043 PR c/89433
4044 * c-attribs.c (c_common_attribute_table): Set min_len to -1 for
4045 "omp declare target".
4046
a9c697b8
MS
40472019-05-16 Martin Sebor <msebor@redhat.com>
4048
ab20d992
JJ
4049 * c-attribs.c (handle_no_sanitize_attribute): Quote identifiers,
4050 keywords, operators, and types in diagnostics.
4051 (handle_scalar_storage_order_attribute): Same.
4052 (handle_mode_attribute): Same.
4053 (handle_visibility_attribute): Same.
4054 (handle_assume_aligned_attribute): Same.
4055 (handle_no_split_stack_attribute): Same.
4056 * c-common.c (shorten_compare): Same.
4057 (c_common_truthvalue_conversion): Same.
4058 (cb_get_source_date_epoch): Same.
4059 * c-lex.c (cb_def_pragma): Quote keywords, operators, and types
4060 in diagnostics.
4061 (interpret_float): Same.
4062 * c-omp.c (c_finish_omp_for): Same.
4063 * c-opts.c (c_common_post_options): Same.
4064 * c-pch.c (c_common_pch_pragma): Same.
4065 * c-pragma.c (pop_alignment): Same.
4066 (handle_pragma_pack): Same.
4067 (apply_pragma_weak): Same.
4068 (handle_pragma_weak): Same.
4069 (handle_pragma_scalar_storage_order): Same.
4070 (handle_pragma_redefine_extname): Same.
4071 (add_to_renaming_pragma_list): Same.
4072 (maybe_apply_renaming_pragma): Same.
4073 (push_visibility): Same.
4074 (handle_pragma_visibility): Same.
4075 (handle_pragma_optimize): Same.
4076 (handle_pragma_message): Same.
4077 * c-warn.c (warn_for_omitted_condop): Same.
4078 (lvalue_error): Same.
a9c697b8 4079
6b943512
RB
40802019-05-15 Richard Biener <rguenther@suse.de>
4081
4082 PR c/90474
4083 * c-common.c (c_common_mark_addressable_vec): Also mark
4084 a COMPOUND_LITERAL_EXPR_DECL addressable similar to
4085 c_mark_addressable.
ab20d992 4086
b744fc85
NS
40872019-05-06 Nathan Sidwell <nathan@acm.org>
4088
4089 * c-opts.c (handle_defered_opts): Rename struct deps to struc mkdeps.
4090
598f50d7
NS
40912019-04-30 Nathan Sidwell <nathan@acm.org>
4092
4093 * c-common.c (c_common_init_ts): Use MARK_TS_EXP. Mark SIZEOF_EXPR.
4094
5bcc5a3b
ML
40952019-04-30 Martin Liska <mliska@suse.cz>
4096
4097 * c-pragma.c (handle_pragma_diagnostic): Provide hints
4098 for unknown options.
4099
e78a87f7
RS
41002019-04-26 Richard Sandiford <richard.sandiford@arm.com>
4101
4102 * c-warn.c (strict_aliasing_warning): Apply COMPLETE_TYPE_P to
4103 the pointer target rather than the pointer itself.
4104
c280b7ee
JJ
41052019-04-19 Jakub Jelinek <jakub@redhat.com>
4106
4107 PR c/89888
4108 * c-common.h (c_add_case_label): Remove orig_type and outside_range_p
4109 arguments.
4110 (c_do_switch_warnings): Remove outside_range_p argument.
4111 * c-common.c (check_case_bounds): Removed.
4112 (c_add_case_label): Remove orig_type and outside_range_p arguments.
4113 Don't call check_case_bounds. Fold low_value as well as high_value.
4114 * c-warn.c (c_do_switch_warnings): Remove outside_range_p argument.
4115 Check for case labels outside of range of original type here and
4116 adjust them.
4117
8e8225e6
JJ
41182019-04-12 Jakub Jelinek <jakub@redhat.com>
4119
63b8a166
JJ
4120 PR translation/90041
4121 * c.opt (-fhandle-exceptions): Use %< and %> around option names
4122 in the Warn diagnostics.
4123
8e8225e6
JJ
4124 PR c/89946
4125 * c-attribs.c (handle_patchable_function_entry_attribute): Add
4126 function comment. Warn if arguments of the attribute are not positive
4127 integer constants.
4128
53a3f614
EB
41292019-04-09 Eric Botcazou <ebotcazou@adacore.com>
4130
4131 * c-ada-spec.c (print_destructor): Deal with deleting destructors.
4132 (dump_ada_declaration) <FUNCTION_DECL>: Likewise.
4133
22be5873
EB
41342019-04-07 Eric Botcazou <ebotcazou@adacore.com>
4135
4136 * c-ada-spec.c (is_float128): New predicate extracted from...
4137 (dump_ada_node) <COMPLEX_TYPE>: Use it to recognize __cfloat128.
4138 <REAL_TYPE>: ...here. Call it.
4139
34facf20
DM
41402019-04-05 David Malcolm <dmalcolm@redhat.com>
4141
4142 PR c/89985
4143 * c-warn.c (check_address_or_pointer_of_packed_member): Add
4144 auto_diagnostic_group. Guard inform calls by result of
4145 warning_at call.
4146
05564120
MP
41472019-04-05 Marek Polacek <polacek@redhat.com>
4148
ab20d992 4149 PR c++/89973 - -Waddress-of-packed-member ICE with invalid conversion.
05564120
MP
4150 * c-warn.c (check_address_or_pointer_of_packed_member): Check the type
4151 of RHS.
4152
7a506c3c
JM
41532019-04-03 Jason Merrill <jason@redhat.com>
4154
4155 PR c++/86586 - -fcompare-debug=-Wsign-compare.
4156 * c-warn.c (warn_for_sign_compare): Call fold_for_warn.
4157
ddeae8c8
MS
41582019-04-01 Martin Sebor <msebor@redhat.com>
4159
4160 PR c/89685
4161 * c-attribs.c (handle_copy_attribute): Handle references and
4162 non-constant expressions.
4163
a15ffa22
JJ
41642019-03-22 Jakub Jelinek <jakub@redhat.com>
4165
4166 PR c++/87481
4167 * c.opt (-fconstexpr-ops-limit=): New option.
4168
36a3a7a3
JJ
41692019-03-21 Jakub Jelinek <jakub@redhat.com>
4170
4171 * c-common.c (per_file_includes_t): Use false as Lazy in hash_set
4172 template param.
4173
bec1da64
MS
41742019-03-19 Martin Sebor <msebor@redhat.com>
4175
4176 PR tree-optimization/89688
4177 * c-common.c (braced_list_to_string): Make static.
4178 (braced_lists_to_strings): Define new function.
4179 * c-common.h (braced_list_to_string): Remove.
4180 (braced_lists_to_strings): Declare.
4181
1fe61adf
ML
41822019-03-12 Martin Liska <mliska@suse.cz>
4183
4184 * c-opts.c (c_common_handle_option): Wrap option with %< and %>.
4185
93964ebd
ML
41862019-03-11 Martin Liska <mliska@suse.cz>
4187
4188 * c-opts.c (c_common_post_options): Wrap apostrophes
4189 in gcc internal format with %'.
4190
a3f9f006
ML
41912019-03-11 Martin Liska <mliska@suse.cz>
4192
4193 * c-attribs.c (handle_nocf_check_attribute): Wrap an option name
4194 in a string format message and fix GNU coding style.
4195 * c-common.c (vector_types_convertible_p): Likewise.
4196 (c_build_vec_perm_expr): Likewise.
4197 * c-indentation.c (get_visual_column): Likewise.
4198 * c-opts.c (c_common_handle_option): Likewise.
4199 (c_common_post_options): Likewise.
4200 (sanitize_cpp_opts): Likewise.
4201 * c-pch.c (c_common_pch_pragma): Likewise.
4202 * c-pragma.c (handle_pragma_pack): Likewise.
4203
1db01ff9
JJ
42042019-03-08 Jakub Jelinek <jakub@redhat.com>
4205
4206 PR tree-optimization/89550
4207 * c-common.c (c_common_truthvalue_conversion): Only set
4208 TREE_NO_WARNING if warning_at returned true.
4209 * c-warn.c (overflow_warning, warn_logical_operator): Likewise.
4210
ba790e6f
JJ
42112019-02-25 Sandra Loosemore <sandra@codesourcery.com>
4212 Martin Sebor <msebor@gmail.com>
4213
4214 * c.opt (Wmissing-attributes): Clean up doc string.
4215
7da73ba7
JJ
42162019-02-25 Jakub Jelinek <jakub@redhat.com>
4217
4218 PR c/89495
4219 * c-format.c (maybe_read_dollar_number): Compute nargnum in
4220 HOST_WIDE_INT type to avoid overflows and change overflow_flag
4221 checking.
4222
921bb9d1
RB
42232019-02-22 Richard Biener <rguenther@suse.de>
4224
4225 * c-pch.c (no_checksum): Remove.
4226 (pch_init): Remove assertion that executable_checksum is not
4227 all zero.
4228 (c_common_valid_pch): Likewise.
4229
e2ebb05c
MS
42302019-02-18 Martin Sebor <msebor@redhat.com>
4231
4232 PR middle-end/89294
4233 * c-common.c (invalid_array_size_error): Handle cst_size_not_constant.
4234
3fe53000
DM
42352019-02-16 David Malcolm <dmalcolm@redhat.com>
4236
4237 PR c++/88680
4238 * c-common.c (shorten_compare): Call fold_for_warn on op0 when
4239 implementing -Wtype-limits.
4240
28a8cef1
MS
42412019-02-11 Martin Sebor <msebor@redhat.com>
4242
4243 PR c++/87996
4244 * c-common.c (invalid_array_size_error): New function.
4245 (valid_array_size_p): Call it. Handle size as well as type.
4246 * c-common.h (valid_constant_size_p): New function.
4247 (enum cst_size_error): New type.
4248
ec2be203
DM
42492019-01-31 David Malcolm <dmalcolm@redhat.com>
4250
4251 PR c/89122
4252 * known-headers.cc (get_stdlib_header_for_name): Add
4253 {FLT|DBL|LDBL}_{MAX|MIN} to "hints" array.
4254
8936f047
JJ
42552019-01-31 Jakub Jelinek <jakub@redhat.com>
4256
4257 PR libstdc++/88170
4258 * c-pretty-print.c (pp_c_enumeration_constant): Print always as
4259 a C cast in pp_c_flag_gnu_v3 mode.
4260
6a335b96
JJ
42612019-01-29 Jakub Jelinek <jakub@redhat.com>
4262
4263 PR c/86125
4264 * c-common.c (c_common_nodes_and_builtins): Build type variants for
4265 builtin_structptr_types types even for C.
4266
2a06eba5
BE
42672019-01-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
4268
4269 * c-warn.c (check_address_or_pointer_of_packed_member): Handle the case
4270 when rhs is of array type correctly. Fix handling of nested structures.
4271 Fix handling of indirect_ref together with nop_expr and/or addr_expr.
4272 (check_and_warn_address_or_pointer_of_packed_member): Fix handling of
4273 type casts within nested compound expressions.
4274
18a23298
JJ
42752019-01-22 Jakub Jelinek <jakub@redhat.com>
4276
4277 PR middle-end/88968
4278 * c-omp.c (c_finish_omp_atomic): For bitfield atomics, update type
4279 variable after using BIT_FIELD_REF.
4280
420183d9
L
42812019-01-18 H.J. Lu <hongjiu.lu@intel.com>
4282
4283 PR c/51628
4284 PR c/88664
4285 * c-common.h (warn_for_address_or_pointer_of_packed_member):
4286 Remove the boolean argument.
4287 * c-warn.c (check_address_of_packed_member): Renamed to ...
4288 (check_address_or_pointer_of_packed_member): This. Also
4289 warn pointer conversion.
4290 (check_and_warn_address_of_packed_member): Renamed to ...
4291 (check_and_warn_address_or_pointer_of_packed_member): This.
4292 Also warn pointer conversion.
4293 (warn_for_address_or_pointer_of_packed_member): Remove the
4294 boolean argument. Don't check pointer conversion here.
4295
99063eee
RS
42962019-01-15 Richard Sandiford <richard.sandiford@arm.com>
4297
4298 PR inline-asm/52813
4299 * c.opt (Wdeprecated): Move documentation and variable to common.opt.
4300
a30d0196
JJ
43012019-01-14 Jakub Jelinek <jakub@redhat.com>
4302
4303 * c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
4304 and __cpp_nontype_template_parameter_auto. Add a comment that
4305 __cpp_template_auto is deprecated.
4306
2d91f79d
TH
43072019-01-14 Tom Honermann <tom@honermann.net>
4308
4309 Implement P0482R5, char8_t: A type for UTF-8 characters and strings
4310 * c-common.c (c_common_reswords): Add char8_t.
4311 (fix_string_type): Use char8_t for the type of u8 string literals.
4312 (c_common_get_alias_set): char8_t doesn't alias.
4313 (c_common_nodes_and_builtins): Define char8_t as a builtin type in
4314 C++.
4315 (c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
4316 (keyword_begins_type_specifier): Add RID_CHAR8.
4317 * c-common.h (rid): Add RID_CHAR8.
4318 (c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
4319 Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
4320 Define char8_type_node and char8_array_type_node.
4321 * c-cppbuiltin.c (cpp_atomic_builtins): Predefine
4322 __GCC_ATOMIC_CHAR8_T_LOCK_FREE.
4323 (c_cpp_builtins): Predefine __cpp_char8_t.
4324 * c-lex.c (lex_string): Use char8_array_type_node as the type of
4325 CPP_UTF8STRING.
4326 (lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
4327 * c-opts.c: If not otherwise specified, enable -fchar8_t when
4328 targeting C++2a.
4329 * c.opt: Add the -fchar8_t command line option.
4330
23db6ced
MS
43312019-01-14 Martin Sebor <msebor@redhat.com>
4332
4333 PR target/88638
4334 * c-attribs.c (positional_argument): Call valid_format_string_type_p
4335 and issue errors if it fails.
4336 * c-common.h (valid_format_string_type_p): Declare.
4337 * c-format.c (valid_stringptr_type_p): Rename...
4338 (valid_format_string_type_p): ...to this and make extern.
4339 (handle_format_arg_attribute): Adjust to new name.
4340 (check_format_string): Same.
4341
234c3818
L
43422019-01-13 H.J. Lu <hongjiu.lu@intel.com>
4343
4344 * c-warn.c (warn_for_address_or_pointer_of_packed_member):
4345 Replace "may may" with "may" in warning message.
4346
d8fcab68
JJ
43472019-01-07 Jakub Jelinek <jakub@redhat.com>
4348
4349 PR c++/85052
4350 * c-common.h (enum rid): Add RID_BUILTIN_CONVERTVECTOR.
4351 (c_build_vec_convert): Declare.
4352 * c-common.c (c_build_vec_convert): New function.
4353
29d24852
MS
43542019-01-04 Martin Sebor <msebor@redhat.com>
4355
4356 PR c/88546
4357 * c-attribs.c (handle_copy_attribute): Avoid copying attribute leaf.
4358 Handle C++ empty throw specification and C11 _Noreturn.
4359 (has_attribute): Also handle C11 _Noreturn.
4360
9069a4c9
MS
43612019-01-04 Martin Sebor <msebor@redhat.com>
4362
4363 PR c/88363
4364 * c-attribs.c (positional_argument): Also accept enumerated types.
4365
a5544970
JJ
43662019-01-01 Jakub Jelinek <jakub@redhat.com>
4367
4368 Update copyright years.
4369
da77eace
L
43702018-12-20 H.J. Lu <hongjiu.lu@intel.com>
4371
4372 PR c/51628
4373 * c-common.h (warn_for_address_or_pointer_of_packed_member): New.
4374 * c-warn.c (check_alignment_of_packed_member): New function.
4375 (check_address_of_packed_member): Likewise.
4376 (check_and_warn_address_of_packed_member): Likewise.
4377 (warn_for_address_or_pointer_of_packed_member): Likewise.
4378 * c.opt: Add -Wno-address-of-packed-member.
4379
573767d4
DM
43802018-12-20 David Malcolm <dmalcolm@redhat.com>
4381
4382 PR c++/87504
4383 * c-warn.c (get_outermost_macro_expansion): New function.
4384 (spelled_the_same_p): Use it to unwind the macro expansions, and
4385 compare the outermost macro in each nested expansion, rather than
4386 the innermost.
4387
a14feb3c
DM
43882018-12-19 David Malcolm <dmalcolm@redhat.com>
4389
4390 PR c++/87504
4391 * c-common.h (warn_tautological_cmp): Convert 1st param from
4392 location_t to const op_location_t &.
4393 * c-warn.c (find_array_ref_with_const_idx_r): Call fold_for_warn
4394 when testing for INTEGER_CST.
4395 (warn_tautological_bitwise_comparison): Convert 1st param from
4396 location_t to const op_location_t &; use it to build a
4397 binary_op_rich_location, and use this.
4398 (spelled_the_same_p): New function.
4399 (warn_tautological_cmp): Convert 1st param from location_t to
4400 const op_location_t &. Warn for macro expansions if
4401 spelled_the_same_p. Use binary_op_rich_location.
4402
dfd7fdca
DM
44032018-12-19 David Malcolm <dmalcolm@redhat.com>
4404
4405 PR c++/43064
4406 PR c++/43486
4407 * c-common.c (unsafe_conversion_p): Fold any location wrapper.
4408 (verify_tree): Handle location wrappers.
4409 (c_common_truthvalue_conversion): Strip any location wrapper.
4410 Handle CONST_DECL.
4411 (fold_offsetof): Strip any location wrapper.
4412 (complete_array_type): Likewise for initial_value.
4413 (convert_vector_to_array_for_subscript): Call fold_for_warn on the
4414 index before checking for INTEGER_CST.
4415 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
4416 print parentheses around location wrappers.
4417 * c-warn.c (warn_logical_operator): Call fold_for_warn on op_right
4418 before checking for INTEGER_CST.
4419 (warn_tautological_bitwise_comparison): Call
4420 tree_strip_any_location_wrapper on lhs, rhs, and bitop's operand
4421 before checking for INTEGER_CST.
4422 (readonly_error): Strip any location wrapper.
4423 (warn_array_subscript_with_type_char): Strip location wrappers
4424 before checking for INTEGER_CST. Use the location of the index if
4425 available.
4426
5c8b3702
JM
44272018-12-06 Jason Merrill <jason@redhat.com>
4428
4429 PR c++/88136 - -Wdeprecated-copy false positives
4430 * c.opt (Wdeprecated-copy-dtor): New.
4431 (Wdeprecated-copy): Move to -Wextra.
4432
673670da
MS
44332018-11-29 Martin Sebor <msebor@redhat.com>
4434
4435 PR c/88172
4436 PR testsuite/88208
4437 * c-attribs.c (common_handle_aligned_attribute): Silently avoid setting
4438 alignments to values less than the target requires.
4439 (has_attribute): For attribute aligned consider both the attribute
4440 and the alignment bits.
4441 * c-common.c (c_init_attributes): Optionally issue a warning for
4442 zero alignment.
4443
04864ec8
MS
44442018-11-28 Martin Sebor <msebor@redhat.com>
4445
4446 PR c/88065
4447 PR c/87297
4448 * c-warn.c (sizeof_pointer_memaccess_warning): Bail if source
4449 or destination is an error.
4450
ace83db0
JJ
44512018-11-28 Jakub Jelinek <jakub@redhat.com>
4452
4453 PR c++/88215
4454 * c-ubsan.c: Include langhooks.h.
4455 (ubsan_instrument_division): Change gcc_assert that main variants
4456 of op0 and op1 types are equal to gcc_checking_assert that the
4457 main variants are compatible types.
4458
da193a27
EB
44592018-11-27 Eric Botcazou <ebotcazou@adacore.com>
4460
4461 * c-ada-spec.c: Include stringpool.h.
4462 (has_static_fields): Return false for incomplete types.
4463 (is_tagged_type): Likewise.
4464 (has_nontrivial_methods): Likewise.
4465 (dump_ada_node) <INTEGER_TYPE>: Deal specifically with __int128.
4466 (struct overloaded_name_hash): New structure.
4467 (struct overloaded_name_hasher): Likewise.
4468 (overloaded_names): New global variable.
4469 (init_overloaded_names): New static function.
4470 (overloaded_name_p): New predicate.
4471 (dump_ada_declaration) <TYPE_DECL>: Tidy up and set TREE_VISITED
4472 on the TYPE_STUB_DECL of the original type of a typedef, if any.
4473 <FUNCTION_DECL>: Bail out for an unsupported overloaded name.
4474 Remove always-true condition and dump forward types.
4475 (dump_ada_specs): Delete overloaded_names.
4476
98f08eb8
MS
44772018-11-20 Martin Sebor <msebor@redhat.com>
4478
4479 * c-attribs.c (type_for_vector_size): New function.
4480 (type_valid_for_vector_size): Same.
4481 (handle_vector_size_attribute): Move code to the functions above
4482 and call them.
4483 (validate_attribute, has_attribute): New functions.
4484 * c-common.h (has_attribute): Declare.
4485 (rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
4486 * c-common.c (c_common_resword): Same.
4487
2674fa47
JM
44882018-11-16 Jason Merrill <jason@redhat.com>
4489
4490 * c-lex.c (c_common_has_attribute): Handle likely/unlikely.
4491 * c-attribs.c (attr_cold_hot_exclusions): Make public.
4492
258b3854
JJ
44932018-11-16 Jakub Jelinek <jakub@redhat.com>
4494
4495 PR middle-end/87854
4496 * c-common.c (fix_string_type): Reject string literals larger than
4497 TYPE_MAX_VALUE (ssizetype) bytes.
4498
1d249509
MS
44992018-11-15 Martin Sebor <msebor@redhat.com>
4500
4501 PR c++/87541
4502 PR c++/87542
4503 * c-attribs.c (positional_argument): New function.
4504 (handle_alloc_size_attribute): Use it and simplify.
4505 (handle_alloc_align_attribute): Same.
4506 (handle_assume_aligned_attribute): Same.
4507 (handle_nonnull_attribute): Same.
4508 * c-common.c (check_function_arguments): Pass fntype to
4509 check_function_format.
4510 * c-common.h (check_function_format): Add an argument.
4511 (PosArgFlags, positional_argument): Declare new type and function.
4512 * c-format.c (decode_format_attr): Add arguments.
4513 (check_format_string, get_constant): Same.
4514 (convert_format_name_to_system_name): Adjust.
4515
478dd60d
DM
45162018-11-15 David Malcolm <dmalcolm@redhat.com>
4517
4518 PR other/19165
4519 * c-opts.c (c_diagnostic_finalizer): Add diagnostic_t param.
4520
8cca0163
JJ
45212018-11-14 Jakub Jelinek <jakub@redhat.com>
4522
8ee09943
JJ
4523 P1236R1 - Signed integers are two's complement
4524 * c-warn.c (maybe_warn_shift_overflow): Don't warn for c++2a.
4525 * c-ubsan.c (ubsan_instrument_shift): Make signed shifts
4526 with in-range second operand well defined for -std=c++2a.
4527
8cca0163
JJ
4528 PR other/88007
4529 * c-common.c (parse_optimize_options): Allocate option string from
4530 opts_obstack rather than as GC memory. Move the allocation after
4531 warning for invalid option.
4532
620e594b
DM
45332018-11-13 David Malcolm <dmalcolm@redhat.com>
4534
4535 * c-common.c (c_get_substring_location): Update for renaming of
4536 get_source_location_for_substring to get_location_within_string.
4537 * c-lex.c: Replace "source_location" with "location_t".
4538 * c-opts.c: Likewise.
4539 * c-ppoutput.c: Likewise.
4540
f9731de3
MS
45412018-11-13 Martin Sebor <msebor@redhat.com>
4542
4543 PR middle-end/81824
4544 * c-attribs.c (handle_copy_attribute): Exclude inlining attributes.
4545 (handle_tls_model_attribute): Improve diagnostics.
4546
e4bd6d5e
JM
45472018-11-12 Jason Merrill <jason@redhat.com>
4548
a6bb6b07
JM
4549 * c-cppbuiltin.c (c_cpp_builtins): Define
4550 __cpp_impl_destroying_delete.
4551
e4bd6d5e
JM
4552 * c-cppbuiltin.c (c_cpp_builtins): Change __cpp_explicit_bool to
4553 __cpp_conditional_explicit.
4554
79a2c428
MS
45552018-11-09 Martin Sebor <msebor@redhat.com>
4556
4557 PR middle-end/81824
4558 * c-attribs.c (handle_copy_attribute): New function.
4559
4c7bd361
MS
45602018-11-09 Martin Sebor <msebor@redhat.com>
4561
4562 PR c/87795
4563 * c-common.c (check_user_alignment): Use MAX_OFILE_ALIGNMENT.
4564
28567c40
JJ
45652018-11-08 Jakub Jelinek <jakub@redhat.com>
4566
4567 * c-common.h (c_finish_omp_taskgroup): Add CLAUSES argument.
4568 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
4569 enum omp_memory_order MEMORY_ORDER.
4570 (c_finish_omp_flush): Add MO argument.
4571 (c_omp_depend_t_p, c_finish_omp_depobj): Declare.
4572 (c_finish_omp_for): Add FINAL_P argument.
4573 * c-omp.c: Include memmodel.h.
4574 (c_finish_omp_taskgroup): Add CLAUSES argument. Set
4575 OMP_TASKGROUP_CLAUSES to it.
4576 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
4577 enum omp_memory_order MEMORY_ORDER. Set OMP_ATOMIC_MEMORY_ORDER
4578 instead of OMP_ATOMIC_SEQ_CST.
4579 (c_omp_depend_t_p, c_finish_omp_depobj): New functions.
4580 (c_finish_omp_flush): Add MO argument, if not MEMMODEL_LAST, emit
4581 __atomic_thread_fence call with the given value.
4582 (check_omp_for_incr_expr): Formatting fixes.
4583 (c_finish_omp_for): Add FINAL_P argument. Allow NE_EXPR
4584 even in OpenMP loops, diagnose if NE_EXPR and incr expression
4585 is not constant expression 1 or -1. Transform NE_EXPR loops
4586 with iterators pointers to VLA into LT_EXPR or GT_EXPR loops.
4587 (c_omp_check_loop_iv_r): Look for orig decl of C++ range for
4588 loops too.
4589 (c_omp_split_clauses): Add support for combined
4590 #pragma omp parallel master and
4591 #pragma omp {,parallel }master taskloop{, simd} constructs.
4592 Handle OMP_CLAUSE_IN_REDUCTION. Handle OMP_CLAUSE_REDUCTION_TASK.
4593 Handle OMP_CLAUSE_NONTEMPORAL. Handle splitting OMP_CLAUSE_IF
4594 also to OMP_SIMD. Copy OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
4595 (c_omp_predetermined_sharing): Don't return
4596 OMP_CLAUSE_DEFAULT_SHARED for const qualified decls.
4597 * c-pragma.c (omp_pragmas): Add PRAGMA_OMP_DEPOBJ and
4598 PRAGMA_OMP_REQUIRES.
4599 * c-pragma.h (enum pragma_kind): Likewise.
4600 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_NONTEMPORAL
4601 and PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
4602
204839e7
DM
46032018-11-08 David Malcolm <dmalcolm@redhat.com>
4604
4605 * c-format.c (gcc_dump_printf_char_table): Add entry for %f.
4606
d8010ee4
DM
46072018-11-08 David Malcolm <dmalcolm@redhat.com>
4608
4609 * c-format.c (local_cgraph_node_ptr_node): New variable.
4610 (gcc_dump_printf_char_table): Add entry for %C.
4611 (get_pointer_to_named_type): New function, taken from the handling
4612 code for "gimple *" from...
4613 (init_dynamic_diag_info): ...here. Add handling for
4614 "cgraph_node *".
4615 * c-format.h (T_CGRAPH_NODE): New.
4616
4be5c72c
JM
46172018-10-19 Jason Merrill <jason@redhat.com>
4618
4619 * c-cppbuiltin.c (c_cpp_builtins): Add
4620 __cpp_nontype_template_parameter_class.
4621
f3f6029d
NS
46222018-10-31 Nathan Sidwell <nathan@acm.org>
4623
ab5324fb
NS
4624 * c-opts.c (c_finish_options): Force command line macro
4625 location. Refactor to avoid repeating main debug hook.
4626 (push_command_line_include): Clarify comment.
4627
f3f6029d
NS
4628 * c-opts.c (c_finish_options): Adjust cpp_force_token_locations call.
4629
91e3ec29
MS
46302018-10-30 Martin Sebor <msebor@redhat.com>
4631
4632 PR middle-end/87041
4633 * c-format.c (check_format_types): Avoid diagnosing null pointer
4634 arguments to printf-family of functions.
4635
b5ff4f5c
MP
46362018-10-30 Marek Polacek <polacek@redhat.com>
4637
4638 Implement P0892R2, explicit(bool).
4639 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
4640
7e2de6df
DM
46412018-10-29 David Malcolm <dmalcolm@redhat.com>
4642
4643 * name-hint.h (name_hint::take_deferred): New member function.
4644
b2bf438c
DM
46452018-10-29 David Malcolm <dmalcolm@redhat.com>
4646
4647 PR c++/56856
4648 * c-common.c (check_function_sentinel): Call fold_for_warn on the
4649 argument.
4650 (check_function_restrict): Rename param "argarray" to
4651 "unfolded_argarray", and make a copy named "argarray", calling
4652 fold_for_warn on each argument.
4653 (check_function_arguments): Add note about responsibility for
4654 folding the arguments.
4655
9f936c86
JM
46562018-10-17 Joseph Myers <joseph@codesourcery.com>
4657
4658 * c-common.c (flag_isoc2x): New variable.
4659 * c-common.h (clk_c): Update comment to reference C2X.
4660 (flag_isoc99, flag_isoc11): Update comments to reference future
4661 standard versions in general.
4662 (flag_isoc2x): Declare.
4663 * c-opts.c (set_std_c2x): New function.
4664 (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
4665 (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
4666 flag_isoc2x to 0.
4667 * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
4668
7a8a92c4
JM
46692018-10-17 Joseph Myers <joseph@codesourcery.com>
4670
4671 * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
4672 (std=iso9899:2018): Document C17 as published in 2018.
4673
4dc003ff
CL
46742018-10-12 Christophe Lyon <christophe.lyon@linaro.org>
4675
4676 PR c++/87364
4677 * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
4678
79371671
WW
46792018-10-11 Will Wray <wjwray@gmail.com>
4680
4681 PR c++/87364
4682 * c-pretty-print.h (pp_c_type_cast): Prototype.
4683 (pp_c_integer_constant): Likewise.
4684 * c-pretty-print.c (pp_c_type_cast): No longer static.
4685 (pp_c_integer_constant): Likewise.
4686 (pp_c_enumeration_constant): Fix loop termination when finding
4687 name of constant. No longer returns a value. Call
4688 pp_c_integer_constant.
4689 (c_pretty_printer::constant): Update for changes to
4690 pp_c_enumeration_constant.
4691
46c62690
JJ
46922018-10-11 Jakub Jelinek <jakub@redhat.com>
4693
4694 * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
4695 for no_unique_address.
4696
c24300ba
DM
46972018-10-09 David Malcolm <dmalcolm@redhat.com>
4698
4699 * c-common.c (c_option_controlling_cpp_error): Rename to...
4700 (c_option_controlling_cpp_diagnostic): ...this, and convert
4701 "reason" from int to enum.
4702 (c_cpp_error): Rename to...
4703 (c_cpp_diagnostic): ...this, converting level and reason to enums.
4704 * c-common.h (c_cpp_error): Rename to...
4705 (c_cpp_diagnostic): ...this, converting level and reason to enums.
4706 * c-opts.c (c_common_init_options): Update for renaming.
4707
8656dafa
RS
47082018-10-08 Richard Sandiford <richard.sandiford@arm.com>
4709
4710 PR c/87286
4711 * c-common.c (vector_types_compatible_elements_p): Use
4712 INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
4713
8cff0652
VK
47142018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
4715
4716 * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
4717 to generate constructor destructor priority warning.
4718 * c.opt (-Wprio-ctor-dtor): New option.
4719
bedf03a2
JM
47202018-10-01 Jason Merrill <jason@redhat.com>
4721
4722 * c-lex.c (c_common_has_attribute): Add no_unique_address.
4723
6cc430c1
EB
47242018-10-01 Eric Botcazou <ebotcazou@adacore.com>
4725
4726 * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
4727 (dump_ada_node): Add const keyword.
4728
87677ac7
ML
47292018-09-25 Martin Liska <mliska@suse.cz>
4730
4731 * c-common.c (c_common_truthvalue_conversion):
4732 Remove Pascal from documentation.
4733
518196cb
EB
47342018-09-21 Eric Botcazou <ebotcazou@adacore.com>
4735
4736 * c-ada-spec.c: Include diagnostic.h.
4737 (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
4738
a599af84
MP
47392018-09-19 Marek Polacek <polacek@redhat.com>
4740
4741 * c.opt (Wclass-conversion): New.
4742
9c4a4b3c
DM
47432018-09-17 David Malcolm <dmalcolm@redhat.com>
4744
4745 * c-format.c (range_label_for_format_type_mismatch::get_text):
4746 Update for new param.
4747
c896ecfe
DM
47482018-09-17 David Malcolm <dmalcolm@redhat.com>
4749
4750 * c-format.c (format_warning_at_char): Update for introduction of
4751 format_string_diagnostic_t.
4752 (format_type_warning): Likewise.
4753
80c6d1f4
MJ
47542018-09-17 Martin Jambor <mjambor@suse.cz>
4755
4756 PR c/63886
4757 * c.opt (Wabsolute-value): New.
4758
6d900107
BE
47592018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
4760
4761 * c-common.c (complete_flexible_array_elts): New helper function.
4762 * c-common.h (complete_flexible_array_elts): Declare.
4763
b5764229
BE
47642018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
4765
4766 * c-common.c (braced_list_to_string): Remove eval parameter.
4767 Add some more checks. Always create zero-terminated STRING_CST.
4768 * c-common.h (braced_list_to_string): Adjust prototype.
4769
85204e23
DM
47702018-08-27 David Malcolm <dmalcolm@redhat.com>
4771
4772 PR 87091
4773 * c-common.c (c_cpp_error): Update for conversion of show_caret_p
4774 to a tri-state.
4775 (maybe_suggest_missing_token_insertion): Likewise.
4776 (maybe_add_include_fixit): Add param "override_location". If set,
4777 and source-printing is enabled, then override the rich_location's
4778 primary location with that of the insertion point for the fix-it
4779 hint, marking it with SHOW_LINES_WITHOUT_RANGE.
4780 * c-common.h (extern void maybe_add_include_fixit): Add bool
4781 param.
4782 * c-format.c (selftest::test_type_mismatch_range_labels): Update
4783 for conversion of show_caret_p to a tri-state.
4784 * c-warn.c (warn_for_restrict): Likewise.
4785 * known-headers.cc
4786 (suggest_missing_header::~suggest_missing_header): Update call to
4787 maybe_add_include_fixit to suggest overriding the location, as it
4788 is for a note.
4789
3d78e008
ML
47902018-08-27 Martin Liska <mliska@suse.cz>
4791
4792 * c-common.c (check_function_restrict): Use new function
92a285c1
ML
4793 fndecl_built_in_p and remove check for FUNCTION_DECL if
4794 possible.
3d78e008
ML
4795 (check_builtin_function_arguments): Likewise.
4796 (reject_gcc_builtin): Likewise.
4797 * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
4798
b5be6d0c
MP
47992018-08-26 Marek Polacek <polacek@redhat.com>
4800
4801 PR c++/87029, Implement -Wredundant-move.
4802 * c.opt (Wredundant-move): New option.
4803
79ca9c35
MP
48042018-08-21 Marek Polacek <polacek@redhat.com>
4805
4806 PR c++/86981, Implement -Wpessimizing-move.
4807 * c.opt (Wpessimizing-move): New option.
4808
097f82ec
DM
48092018-08-20 David Malcolm <dmalcolm@redhat.com>
4810
4811 PR other/84889
4812 * c-attribs.c (common_handle_aligned_attribute): Add
4813 auto_diagnostic_group instance.
4814 * c-indentation.c (warn_for_misleading_indentation): Likewise.
4815 * c-opts.c (c_common_post_options): Likewise.
4816 * c-warn.c (warn_logical_not_parentheses): Likewise.
4817 (warn_duplicated_cond_add_or_warn): Likewise.
4818 (warn_for_multistatement_macros): Likewise.
4819
3fb558b1
NS
48202018-08-20 Nathan Sidwell <nathan@acm.org>
4821
4822 * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
4823 access.
4824
800c0e98
NS
48252018-08-17 Nathan Sidwell <nathan@acm.org>
4826
4827 * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
4828 field.
4829 (laxy_hex_fp_value_count): Make unsigned.
4830 (lazy_hex_fp_value): Provided with macro & lazy number. Directly
4831 manipulate the macro.
4832 (builtin_defin_with_hex_fp_value): Adjust callback name, use
4833 cpp_define_lazily.
4834
6f795a92
DM
48352018-08-17 David Malcolm <dmalcolm@redhat.com>
4836
4837 * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
4838 (gcc_dump_printf_length_specs): New.
4839 (gcc_dump_printf_flag_pairs): New.
4840 (gcc_dump_printf_flag_specs): New.
4841 (gcc_dump_printf_char_table): New.
4842 (format_types_orig): Add entry for "gcc_dump_printf".
4843 (init_dynamic_diag_info): Set up length_char_specs and
4844 conversion_specs for gcc_dump_printf_format_type.
4845 (handle_format_attribute): Handle gcc_dump_printf_format_type.
4846
c5d725c0
NS
48472018-08-17 Nathan Sidwell <nathan@acm.org>
4848
10f04917
NS
4849 * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
4850
c5d725c0
NS
4851 * c-ada-spec.c: Don't #include "cpp-id-data.h"
4852 * c-cppbuiltin.c: Likewise.
4853
c0c12356
ML
48542018-08-17 Martin Liska <mliska@suse.cz>
4855
4856 * c.opt: Remove Warn, Init and Report for options with
92a285c1
ML
4857 Ignore/Deprecated flag. Warning is done automatically for
4858 Deprecated flags.
c0c12356 4859
10fcc142
DM
48602018-08-16 David Malcolm <dmalcolm@redhat.com>
4861
4862 PR c++/70693
4863 * c-common.c (selftest::c_family_tests): Call
4864 selftest::c_indentation_c_tests.
4865 * c-common.h (selftest::c_indentation_c_tests): New decl.
4866 * c-indentation.c: Include "selftest.h".
4867 (next_tab_stop): Add "tab_width" param, rather than accessing
4868 cpp_opts.
4869 (get_visual_column): Likewise. Clarify comment. Bulletproof
4870 against reading past the end of the line.
4871 (get_first_nws_vis_column): Add "tab_width" param.
4872 (detect_intervening_unindent): Likewise.
4873 (should_warn_for_misleading_indentation): Read tab width from
4874 cpp_opts and pass around.
4875 (selftest::test_next_tab_stop): New test.
4876 (selftest::assert_get_visual_column_succeeds): New function.
4877 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
4878 (selftest::assert_get_visual_column_fails): New function.
4879 (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
4880 (selftest::test_get_visual_column): New test.
4881 (selftest::c_indentation_c_tests): New function.
4882
3f6677f4
NS
48832018-08-16 Nathan Sidwell <nathan@acm.org>
4884
4885 * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
4886 (store_ada_macro): Likewise.
4887 * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
4888 * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
4889
96e6ae57
DM
48902018-08-15 David Malcolm <dmalcolm@redhat.com>
4891
4892 * c-format.c: Include "selftest-diagnostic.h" and
4893 "gcc-rich-location.h".
4894 (format_warning_at_char): Pass NULL for new label params of
4895 format_warning_va.
4896 (class indirection_suffix): New class.
4897 (class range_label_for_format_type_mismatch): New class.
4898 (format_type_warning): Move logic for generating "*" suffix to
4899 class indirection_suffix. Create "fmt_label" and "param_label"
4900 to show their types, and pass them to the
4901 format_warning_at_substring calls.
4902 (selftest::test_type_mismatch_range_labels): New test.
4903 (selftest::c_format_c_tests): Call it.
4904
23aa9f7c
MS
49052018-08-13 Martin Sebor <msebor@redhat.com>
4906
4907 PR tree-optimization/71625
4908 * c-common.c (braced_list_to_string): New function.
4909 * c-common.h (braced_list_to_string): Declare it.
4910
f10a9135
NS
49112018-08-08 Nathan Sidwell <nathan@acm.org>
4912
4913 * c-common.c (try_to_locate_new_include_inertion_point): Use
4914 linemap_included_from_linemap.
4915 * c-lex.c (fe_file_change): Use linemap_included_from.
4916 * c-ppoutput.c (pp_file_change): Likewise.
4917
8a45b051
MS
49182018-08-01 Martin Sebor <msebor@redhat.com>
4919
4920 PR tree-optimization/86650
ab20d992 4921 * c-format.c (gcc_tdiag_char_table): Update comment for "%G".
8a45b051
MS
4922 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
4923 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
4924 * c-format.h (T89_G): Update to be "gimple *" rather than
4925 "gcall *".
4926 (local_gcall_ptr_node): Rename...
4927 (local_gimple_ptr_node): ...to this.
4928
e540ccc0
DM
49292018-07-31 David Malcolm <dmalcolm@redhat.com>
4930
4931 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
4932 table entries for gcc_diag_char_table, and the 'Z' entry from
4933 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
4934 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
4935 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
4936 adding missing "Z" for this table. Remove erroneous "G" and "K"
4937 entries.
4938 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
4939 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
4940 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
4941
425fc685
RE
49422018-07-31 Richard Earnshaw <rearnsha@arm.com>
4943
4944 * c-common.c (speculation_safe_resolve_call): New function.
4945 (speculation_safe_resolve_params): New function.
4946 (speculation_safe_resolve_return): New function.
4947 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
4948 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
4949 __HAVE_SPECULATION_SAFE_VALUE.
4950
181463c2
DM
49512018-07-20 David Malcolm <dmalcolm@redhat.com>
4952
4953 * c-common.c (c_cpp_error): Remove redundant "line_table"
4954 parameter from call to rich_location::set_range.
4955 (maybe_suggest_missing_token_insertion): Likewise.
4956
0d7f9065
MS
49572018-07-20 Martin Sebor <msebor@redhat.com>
4958
4959 PR middle-end/82063
ab20d992 4960 * c.opt (-Warray-bounds): Remove redundant -Wall.
0d7f9065 4961
00abf86c
MS
49622018-07-20 Martin Sebor <msebor@redhat.com>
4963
4964 PR middle-end/82063
4965 * c-common.h (c_common_handle_option): Change function argument
4966 to HOST_WIDE_INT.
4967 * c-opts.c (c_common_init_options): Same.
4968 (c_common_handle_option): Same. Remove special handling of
4969 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
4970 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
4971 options to take a HOST_WIDE_INT argument and accept a byte-size
4972 suffix. Initialize.
4973 (-Wvla-larger-than): Same.
4974 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
4975 (-Wno-vla-larger-than): Same.
4976
9b452033
JJ
49772018-07-12 Jakub Jelinek <jakub@redhat.com>
4978
4979 * c-attribs.c (c_common_attribute_table): Add
4980 "omp declare target implicit" attribute.
4981
cd0762f3
RB
49822018-07-12 Richard Biener <rguenther@suse.de>
4983
4984 PR c/86453
4985 * c-attribs.c (handle_packed_attribute): Do not build a variant
4986 type with TYPE_PACKED, instead ignore the attribute if we may
4987 not apply to the original type.
4988
0b27c3ed
JJ
49892018-07-10 Jakub Jelinek <jakub@redhat.com>
4990
4991 PR c++/86443
4992 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
4993 to contain TREE_LIST for both the original class iterator and the
4994 "last" helper var.
4995
e730a0ef
EB
49962018-07-07 Eric Botcazou <ebotcazou@adacore.com>
4997
4998 * c-ada-spec.c (to_ada_name): Remove index parameter.
4999 (pp_ada_tree_identifier): Likewise.
5000 (dump_ada_macros): Adjust call to to_ada_name.
5001 (struct overloaded_name_hash): Delete.
5002 (struct overloaded_name_hasher): Likewise.
5003 (overloaded_names): Likewise.
5004 (compute_overloading_index): Likewise.
5005 (dump_ada_decl_name): Do not call compute_overloading_index and
5006 adjust calls to pp_ada_tree_identifier.
5007 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
5008 (dump_ada_import): Add spc parameter and switch to aspect syntax.
5009 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
5010 (dump_ada_enum_type): Remove type and display_convention parameters.
5011 Adjust calls to pp_ada_tree_identifier.
5012 (dump_ada_node): Likewise and for dump_ada_structure.
5013 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
5014 and tidy up.
5015 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
5016 syntax.
5017 (print_constructor): Adjust call to pp_ada_tree_identifier.
5018 (print_destructor): Likewise.
5019 (dump_ada_declaration): Switch to aspect syntax.
5020 (dump_ada_structure): Likewise and tidy up. Replace display_convention
5021 parameter with nested parameter.
5022 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
5023 (dump_ada_specs): Do not delete overloaded_names table.
5024
8de583fc
PB
50252018-07-06 Peter Bergner <bergner@linux.ibm.com>
5026
5027 PR target/86324
e730a0ef 5028 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
8de583fc
PB
5029 target hook.
5030
09cff37b
NS
50312018-07-05 Nathan Sidwell <nathan@acm.org>
5032
5033 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
5034 NO_IMPLICIT_EXTERN_C.
5035
98086b2b
ML
50362018-06-28 Martin Liska <mliska@suse.cz>
5037
5038 * cppspec.c: Include opt-suggestions.h.
5039
ab20d992
JJ
50402018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
5041 Thomas Schwinge <thomas@codesourcery.com>
829c6349
CLT
5042 Cesar Philippidis <cesar@codesourcery.com>
5043
5044 * c-pragma.h (enum pragma_omp_clause): Add
5045 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
5046 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
5047
f41b7612
JJ
50482018-06-20 Jakub Jelinek <jakub@redhat.com>
5049
5050 PR c++/86210
5051 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
5052 comment.
5053
4252ccd7
MS
50542018-06-18 Martin Sebor <msebor@redhat.com>
5055
5056 PR middle-end/85602
5057 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
5058 nonstring.
5059
e197e64e
KV
50602018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
5061
5062 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
5063
34a7a230
JM
50642018-06-13 Jason Merrill <jason@redhat.com>
5065
5cef3733
JM
5066 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
5067 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
5068 handling.
5069
34a7a230
JM
5070 PR c++/86094 - wrong code with defaulted move ctor.
5071 * c-opts.c (c_common_post_options): Bump the current ABI version to
5072 13. Set warn_abi_version and flag_abi_compat_version to the current
5073 version rather than 0. Fix defaulting flag_abi_compat_version from
5074 warn_abi_version.
5075
bb0f14ae
MS
50762018-06-12 Martin Sebor <msebor@redhat.com>
5077
5078 PR c/85931
5079 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
5080 sizeof source and destination yields the same value.
5081
3713f2e2
ML
50822018-06-12 Martin Liska <mliska@suse.cz>
5083
5084 * c.opt: Make MPX-related options as Deprecated.
5085
4af78ef8
DM
50862018-06-08 David Malcolm <dmalcolm@redhat.com>
5087
5088 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
5089 rather than 0.
5090
31db0fe0
ML
50912018-06-08 Martin Liska <mliska@suse.cz>
5092
5093 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
5094 for MPX (macros, related functions, fields in cgraph_node, ...).
5095 (handle_bnd_legacy): Likewise.
5096 (handle_bnd_instrument): Likewise.
5097 * c.opt: Likewise.
5098
fe16acf2
JJ
50992018-06-06 Jakub Jelinek <jakub@redhat.com>
5100
5101 PR c++/86068
5102 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
5103 __cpp_transactional_memory to 201500 instead of 210500.
5104
4dbdb49b
JM
51052018-06-06 Jason Merrill <jason@redhat.com>
5106
5107 PR c++/85710 - ICE with -Wmemset-elt-size.
5108 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
5109
f8ad043f
JM
51102018-06-01 Jason Merrill <jason@redhat.com>
5111
5112 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
5113 201703.
5114
abc24d93
EB
51152018-06-01 Eric Botcazou <ebotcazou@adacore.com>
5116
5117 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
5118 declaration for a typedef independently of whether the declaration of
5119 the subtype is generated.
5120
d258f4aa
MS
51212018-05-31 Martin Sebor <msebor@redhat.com>
5122
5123 PR c/82063
5124 * c.opt (-Wno-alloc-size-larger-than): New option.
5125
b67b9225
DP
51262018-04-22 David Pagan <dave.pagan@oracle.com>
5127
5128 PR c/55976
5129 * c-opts.c (c_common_post_options): Set default for warn_return_type
ab20d992 5130 for C++/C++ with ObjC extensions only. For C, makes it possible to
b67b9225
DP
5131 differentiate between default (no option), -Wreturn-type, and
5132 -Wno-return-type.
5133
04eb9c55
JM
51342018-05-29 Jason Merrill <jason@redhat.com>
5135
5136 * c.opt (Winit-list-lifetime): New flag.
5137
b0c31bc6
BE
51382018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
5139
5140 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
5141 splay_tree_delete_pointers.
5142
44284983
JJ
51432018-05-26 Jakub Jelinek <jakub@redhat.com>
5144
5145 PR bootstrap/85921
5146 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
5147 noinline variable to workaround broken kernel headers.
5148
b46b715d
JM
51492018-05-18 Jason Merrill <jason@redhat.com>
5150
5151 * c.opt (Wdeprecated-copy): New flag.
5152
40659769
ML
51532018-05-17 Martin Liska <mliska@suse.cz>
5154
5155 * c-warn.c (overflow_warning): Do not use
5156 space in between 'G_' and '('.
5157
403962ea
JM
51582018-05-09 Jason Merrill <jason@redhat.com>
5159
5160 * c-common.c (valid_array_size_p): Add complain parameter.
5161 * c-common.h: ...which defaults to true.
5162
1c9ee609
JJ
51632018-05-11 Jakub Jelinek <jakub@redhat.com>
5164
5165 PR c/85696
5166 * c-omp.c (c_omp_predetermined_sharing): Return
5167 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
5168
19916065
ML
51692018-05-11 Martin Liska <mliska@suse.cz>
5170
92a285c1 5171 PR sanitizer/85556
19916065
ML
5172 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
5173 TREE_LIST values.
5174
79e7b1fe
JJ
51752018-05-10 Jakub Jelinek <jakub@redhat.com>
5176
5177 PR c++/85662
5178 * c-common.h (fold_offsetof_1): Removed.
5179 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
5180 CTX argument defaulted to ERROR_MARK.
5181 * c-common.c (fold_offsetof_1): Renamed to ...
5182 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
5183 argument, convert the pointer constant to TYPE and use size_binop
5184 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
5185 a pointer type. Adjust recursive calls.
5186
86c12f76
EB
51872018-05-10 Eric Botcazou <ebotcazou@adacore.com>
5188
5189 PR c++/85400
5190 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
5191
ee336e84
NS
51922018-05-07 Nathan Sidwell <nathan@acm.org>
5193
5194 * c.opt (ffor-scope): Remove functionality, issue warning.
5195
6c072e21
NS
51962018-05-03 Nathan Sidwell <nathan@acm.org>
5197
5198 * c.opt (ffriend-injection): Remove functionality, issue warning.
5199
2cc7d3a7
DM
52002018-05-01 David Malcolm <dmalcolm@redhat.com>
5201
5202 PR c/84258
5203 * c-format.c (struct format_check_results): Add field
5204 "number_non_char".
5205 (check_format_info): Initialize it, and warn if encountered.
5206 (check_format_arg): Distinguish between wide char and
5207 everything else when detecting arrays of non-char.
5208
7761dfbe
DM
52092018-04-30 David Malcolm <dmalcolm@redhat.com>
5210
5211 * c-format.c (get_corrected_substring): Update for
5212 location_get_source_line returning a char_span. Use a char_span
5213 when handling the prefix of the correction.
5214 * c-indentation.c (get_visual_column): Update for
5215 location_get_source_line returning a char_span.
5216 (get_first_nws_vis_column): Likewise.
5217
62e98ef1
DM
52182018-03-29 David Malcolm <dmalcolm@redhat.com>
5219
5220 PR c++/84269
5221 * known-headers.cc (get_stdlib_header_for_name): Add various names
5222 from <assert.h>, <string.h>, and <memory.h>; add more names from
5223 <stdio.h>.
5224
a7dea617
JJ
52252018-03-27 Jakub Jelinek <jakub@redhat.com>
5226
5227 PR c++/85061
5228 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
5229 get_base_address of the second operand is a VAR_P, rather than the
5230 operand itself, and use gcc_checking_assert instead of gcc_assert.
5231
889a3a30
MP
52322018-03-23 Marek Polacek <polacek@redhat.com>
5233
5234 PR c++/85045
5235 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
5236 <case RDIV_EXPR>: Tweak condition.
5237
452154b9
EB
52382018-03-20 Eric Botcazou <ebotcazou@adacore.com>
5239
5240 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
5241
63ecb626
JJ
52422018-03-16 Jakub Jelinek <jakub@redhat.com>
5243
ce811fc4
JJ
5244 PR c/84909
5245 * c-warn.c (conversion_warning): Replace "to to" with "to" in
5246 diagnostics.
5247
63ecb626
JJ
5248 PR c/84910
5249 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
5250 diagnostics.
5251
a1295eec
RB
52522018-03-16 Richard Biener <rguenther@suse.de>
5253
5254 PR c/84873
5255 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
5256 unshare the possibly folded expression.
5257
919674fb
RB
52582018-03-15 Richard Biener <rguenther@suse.de>
5259
5260 PR c/84873
5261 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
5262
f99309b2
MS
52632018-03-13 Martin Sebor <msebor@redhat.com>
5264
5265 PR tree-optimization/84725
5266 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
5267 with all three narrow character types, including their qualified forms.
5268
e9b9fa4c
MS
52692018-03-12 Martin Sebor <msebor@redhat.com>
5270
5271 PR tree-optimization/83456
ab20d992 5272 * c-common.c (check_function_restrict): Return bool.
e9b9fa4c
MS
5273 Restore checking of bounded built-in functions.
5274 (check_function_arguments): Also return the result
5275 of warn_for_restrict.
ab20d992
JJ
5276 * c-common.c (check_function_restrict): Return bool.
5277 * c-warn.c (warn_for_restrict): Return bool.
e9b9fa4c 5278
0805d020
MP
52792018-03-02 Marek Polacek <polacek@redhat.com>
5280
5281 PR c++/84171
5282 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
5283 is erroneous.
5284
ed2a2f08
TS
52852018-03-02 Thomas Schwinge <thomas@codesourcery.com>
5286
5287 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
5288 function".
5289
90abdde0
MP
52902018-03-01 Marek Polacek <polacek@redhat.com>
5291
5292 PR c++/84639
5293 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
5294 alignment in computation.
5295
c6db43fa
EB
52962018-02-28 Eric Botcazou <ebotcazou@adacore.com>
5297
5298 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
5299 <REAL_TYPE>: Deal specifically with _Float128/__float128.
5300
9e25c7ed
EB
53012018-02-28 Eric Botcazou <ebotcazou@adacore.com>
5302
5303 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
5304 (is_char_array): Take a type instead of a declaration.
5305 (dump_ada_array_type): Likewise.
5306 (is_simple_enum): Minor tweak.
5307 (dump_ada_enum_type): New function extracted from...
5308 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
5309 <INTEGER_TYPE>: Remove unreachable code.
5310 <RECORD_TYPE>: Likewise. Minor tweaks.
5311 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
5312 <ENUMERAL_TYPE>: New case.
5313 <RECORD_TYPE>: Factor out common code.
5314 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
5315 Minor tweaks. Deal with enumeral types.
5316 (dump_ada_structure): Minor tweaks.
5317
09de3550
EB
53182018-02-28 Eric Botcazou <ebotcazou@adacore.com>
5319
5320 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
5321 address for incomplete structures.
5322 (dump_forward_type): Do not bail out for incomplete structures.
5323 (dump_ada_declaration): Do not special-case incomplete structures
5324 for subtypes. Dump them as null records for types.
5325
095d8d4b
EB
53262018-02-28 Eric Botcazou <ebotcazou@adacore.com>
5327
5328 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
5329 (is_char_array): Fix formatting.
5330 (dump_template_types): Likewise.
5331 (dump_generic_ada_node): Rename into...
5332 (dump_ada_node): ...this.
5333 <POINTER_TYPE>: Remove superfluous space. Use generic address for
5334 incomplete structures and not for empty structures. Do not use it
5335 when forward declarations are needed.
5336 (dump_forward_type): New function.
5337 (dump_nested_types): Remove FORWARD parameter. Do not consider
5338 TREE_VISITED and do not generate a forward declaration. Only dump
5339 original nested types for nested declaration.
5340 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
5341 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
5342 <RECORD_TYPE>: Do not consider TREE_VISITED.
5343 (dump_ada_declaration): Use booleans and fix formatting throughout.
5344 <TYPE_DECL>: Skip incomplete structures and not empty structures.
5345 Call dump_forward_type instead of dump_nested_types for a typedef.
5346 Remove superfluous check and adjust call to dump_nested_types.
5347 <POINTER_TYPE>: Call dump_forward_type and fall through.
5348 (dump_ada_struct_decl): Rename into...
5349 (dump_ada_structure): ...this. Do not special-case empty structures.
5350
d4cfd486
MS
53512018-02-27 Martin Sebor <msebor@redhat.com>
5352
5353 PR c++/83871
5354 * c.opt (-Wmissing-attributes): New option.
5355
b22dbd03
ML
53562018-02-21 Martin Liska <mliska@suse.cz>
5357
5358 * c.opt (Wcatch-value=): Add IntegerRange.
5359
883dfe2a
JM
53602018-02-15 Jason Merrill <jason@redhat.com>
5361
5362 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
5363
0444aa9c
NS
53642018-02-09 Nathan Sidwell <nathan@acm.org>
5365
5366 PR c/84293
5367 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
5368 arg.
5369 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
5370 arg. Adjust.
5371
cea71f0a
MS
53722018-02-09 Martin Sebor <msebor@redhat.com>
5373
5374 PR lto/84212
5375 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
5376 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
5377 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
5378 (-Wstrict-overflow, -Wsuggest-attribute): Same.
5379 (-Wuninitialized): Same.
5380
8c8b7be5
EB
53812018-02-09 Eric Botcazou <ebotcazou@adacore.com>
5382
5383 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
5384 keyword for components.
5385
7c30b12a
PC
53862018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
5387
5388 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
5389
eece7fe5
JK
53902018-02-02 Julia Koval <julia.koval@intel.com>
5391
5392 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
5393
7d07a93a
MP
53942018-01-29 Marek Polacek <polacek@redhat.com>
5395
5396 PR c/83966
5397 * c-format.c (check_function_format): Check current_function_decl.
5398
53723269
JJ
53992018-01-27 Jakub Jelinek <jakub@redhat.com>
5400
5401 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
5402 argument.
5403 (LAZY_HEX_FP_VALUES_CNT): Define.
5404 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
5405 values rather than just 12.
5406 (builtin_define_with_hex_fp_value): Likewise.
5407
7365279f
BK
54082018-01-18 Boris Kolpackov <boris@codesynthesis.com>
5409
92a285c1
ML
5410 PR other/70268
5411 * c.opt (-fmacro-prefix-map): New option.
5412 * c-opts.c (c_common_handle_option): Handle it.
5413 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
5414 * c-ppoutput.c (init_pp_output): Likewise.
7365279f 5415
bb9869d5
DM
54162018-01-17 David Malcolm <dmalcolm@redhat.com>
5417
5418 PR c++/83814
5419 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
5420
68dc87c3
EB
54212018-01-10 Eric Botcazou <ebotcazou@adacore.com>
5422
5423 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
5424 Skip 'f' and 'F' characters if it is true.
5425 (store_ada_macro): Minor tweak.
5426 (dump_ada_macros) <CPP_COMMENT>: Likewise.
5427 <CPP_WSTRING>: Likewise.
5428 <CPP_STRING>: Output '&' in the buffer if not the first string.
5429 <CPP_NUMBER>: Adjust calls to dump_number.
5430
9a004410
DM
54312018-01-10 David Malcolm <dmalcolm@redhat.com>
5432
5433 PR c++/43486
5434 * c-common.c: Include "selftest.h".
5435 (get_atomic_generic_size): Perform the test for integral type
5436 before the range test for any integer constant, fixing indentation
5437 of braces. Call fold_for_warn before testing for an INTEGER_CST.
5438 (reject_gcc_builtin): Strip any location wrapper from EXPR.
5439 (selftest::test_fold_for_warn): New function.
5440 (selftest::c_common_c_tests): New function.
5441 (selftest::c_family_tests): Call it, and
5442 selftest::c_pretty_print_c_tests.
5443 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
5444 * c-format.c (check_format_arg): Convert VAR_P check to a
5445 fold_for_warn.
5446 * c-pretty-print.c: Include "selftest.h".
5447 (pp_c_cast_expression): Don't print casts for location wrappers.
5448 (selftest::assert_c_pretty_printer_output): New function.
5449 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
5450 (selftest::test_location_wrappers): New function.
5451 (selftest::c_pretty_print_c_tests): New function.
5452 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
5453
5c0caeb3
RS
54542018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
5455 Alan Hayward <alan.hayward@arm.com>
5456 David Sherwood <david.sherwood@arm.com>
5457
5458 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
5459
73a699ae
RS
54602018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
5461 Alan Hayward <alan.hayward@arm.com>
5462 David Sherwood <david.sherwood@arm.com>
5463
5464 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
5465 as polynomial.
5466
928686b1
RS
54672018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
5468 Alan Hayward <alan.hayward@arm.com>
5469 David Sherwood <david.sherwood@arm.com>
5470
5471 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
5472 (convert_vector_to_array_for_subscript): Handle polynomial
5473 TYPE_VECTOR_SUBPARTS.
5474 (c_common_type_for_mode): Check valid_vector_subparts_p.
5475 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
5476 VECTOR_CST_NELTS.
5477
85ec4feb
JJ
54782018-01-03 Jakub Jelinek <jakub@redhat.com>
5479
5480 Update copyright years.
5481
170a8bd6 54822017-12-22 Mike Stump <mikestump@comcast.net>
92a285c1 5483 Eric Botcazou <ebotcazou@adacore.com>
170a8bd6
EB
5484
5485 * c-pragma.c (init_pragma): Register pragma GCC unroll.
5486 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
5487
ab20d992 54882017-12-22 Alexandre Oliva <aoliva@redhat.com>
18408e96
AO
5489
5490 PR debug/83527
5491 PR debug/83419
5492 * c-semantics.c (only_debug_stmts_after_p): New.
5493 (pop_stmt_list): Clear side effects in debug-only stmt list.
5494 Check for single nondebug stmt followed by debug stmts only.
5495
c12d20d4
AO
54962017-12-21 Alexandre Oliva <aoliva@redhat.com>
5497
5498 PR debug/83419
5499 * c-semantics.c (pop_stmt_list): Propagate side effects from
5500 single nondebug stmt to container list.
5501
01512446
JJ
55022017-12-19 Jakub Jelinek <jakub@redhat.com>
5503
5504 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
5505 conditions with typical order conditions.
5506
82cfbd01
MP
55072017-12-18 Marek Polacek <polacek@redhat.com>
5508
5509 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
5510 not in effect.
5511
99da11ec
MS
55122017-12-17 Martin Sebor <msebor@redhat.com>
5513
5514 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
5515 an error for attribute warn_if_not_aligned.
5516
cc8bea0a
MS
55172017-12-16 Martin Sebor <msebor@redhat.com>
5518
5519 PR tree-optimization/78918
5520 * c-common.c (check_function_restrict): Avoid checking built-ins.
5521 * c.opt (-Wrestrict): Include in -Wall.
5522
4849deb1
JJ
55232017-12-15 Jakub Jelinek <jakub@redhat.com>
5524
5525 * c-attribs.c (c_common_attribute_table,
5526 c_common_format_attribute_table): Swap affects_type_identity
5527 and handler fields, adjust comments.
5528
c65e18d3
BE
55292017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
5530
5531 * c.opt (Wcast-function-type): New warning option.
5532 * c-lex.c (get_fileinfo): Avoid warning.
5533 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
5534
2004617a
QZ
55352017-12-14 Qing Zhao <qing.zhao@oracle.com>
5536
7365279f 5537 PR middle_end/79538
2004617a
QZ
5538 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
5539 Adjust the size of buf1 and buf2, add a new buf to avoid
5540 format-overflow warning.
5541
ab20d992 55422017-12-12 Alexandre Oliva <aoliva@redhat.com>
96a95ac1
AO
5543
5544 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
5545 subsequent statement list.
5546
5d9ae53d
MS
55472017-12-07 Martin Sebor <msebor@redhat.com>
5548
5549 PR c/81544
5550 PR c/81566
5551 * c-attribs.c (attr_aligned_exclusions): New array.
5552 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
5553 (attr_common_exclusions, attr_const_pure_exclusions): Same.
5554 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
5555 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
5556 (attr_warn_unused_result_exclusions): Same.
5557 (handle_hot_attribute, handle_cold_attribute): Simplify.
5558 (handle_const_attribute): Warn on function returning void.
5559 (handle_pure_attribute): Same.
5560 (handle_aligned_attribute): Diagnose conflicting attribute
5561 specifications.
5562 * c-warn.c (diagnose_mismatched_attributes): Simplify.
5563
c79144f8
DM
55642017-12-06 David Malcolm <dmalcolm@redhat.com>
5565
5566 PR c/83236
5567 * c-common.c (selftest::c_family_tests): Call
5568 selftest::c_spellcheck_cc_tests.
5569 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
5570 * c-spellcheck.cc: Include "selftest.h".
5571 (name_reserved_for_implementation_p): New function.
5572 (should_suggest_as_macro_p): New function.
5573 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
5574 should_suggest_as_macro_p and call it.
5575 (selftest::test_name_reserved_for_implementation_p): New function.
5576 (selftest::c_spellcheck_cc_tests): New function.
5577 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
5578
613bc14f
DM
55792017-12-06 David Malcolm <dmalcolm@redhat.com>
5580
5581 * c-spellcheck.cc: New file, taken from macro-handling code in
5582 spellcheck-tree.c.
5583 * c-spellcheck.h: New file, taken from macro-handling code in
5584 spellcheck-tree.h.
5585
e76c7157
JJ
55862017-12-01 Jakub Jelinek <jakub@redhat.com>
5587
5588 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
5589 attribute.
5590 (handle_simd_attribute): Don't check for "cilk simd function"
5591 attribute. Reindent, formatting changes.
5592
b0da4034
JK
55932017-11-30 Julia Koval <julia.koval@intel.com>
5594
5595 * c-common.h (inv_list): Remove.
5596
058f0b9e
JJ
55972017-11-28 Jakub Jelinek <jakub@redhat.com>
5598
5599 PR sanitizer/81275
5600 * c-common.c (c_switch_covers_all_cases_p_1,
5601 c_switch_covers_all_cases_p): New functions.
5602 * c-common.h (c_switch_covers_all_cases_p): Declare.
5603
5e9d6aa4 56042017-11-28 Julia Koval <julia.koval@intel.com>
92a285c1 5605 Sebastian Peryt <sebastian.peryt@intel.com>
5e9d6aa4
JK
5606
5607 * array-notation-common.c: Delete.
5608 * c-cilkplus.c: Ditto.
5609 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
5610 * c-common.def (ARRAY_NOTATION_REF): Remove.
5611 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
5612 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
5613 c_validate_cilk_plus_loop, cilkplus_an_parts,
5614 cilk_ignorable_spawn_rhs_op,
5615 cilk_recognize_spawn): Remove.
5616 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
5617 * c-omp.c: Remove CILK_SIMD check.
5618 * c-pragma.c: Ditto.
5619 * c-pragma.h: Remove CILK related pragmas.
5620 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
5621 ARRAY_NOTATION_REF condition.
5622 (c_pretty_printer::expression): Ditto.
5623 * c.opt (fcilkplus): Remove.
5624 * cilk.c: Delete.
5625
1af4ebf5
MG
56262017-11-21 Marc Glisse <marc.glisse@inria.fr>
5627
5628 * c-pretty-print.c (pp_c_additive_expression,
5629 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
5630
d44ed508
JJ
56312017-11-21 Jakub Jelinek <jakub@redhat.com>
5632
7d2f0f9b
JJ
5633 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
5634
d44ed508
JJ
5635 PR c++/83059
5636 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
5637 instead of tree_to_uhwi, formatting fix.
5638
26edace6
DM
56392017-11-20 David Malcolm <dmalcolm@redhat.com>
5640
5641 PR c/81404
5642 * known-headers.cc: New file, based on material from c/c-decl.c.
5643 (suggest_missing_header): Copied as-is.
5644 (get_stdlib_header_for_name): New, based on get_c_name_hint but
5645 heavily edited to add C++ support. Add some knowledge about
5646 <limits.h>, <stdint.h>, and <wchar.h>.
5647 * known-headers.h: Likewise.
5648
6c7a259b
DM
56492017-11-20 David Malcolm <dmalcolm@redhat.com>
5650
5651 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
5652 (lookup_name_fuzzy): Likewise. Convert return type from
5653 const char * to name_hint. Add location_t param.
5654 * name-hint.h: New header.
5655
f9c59f7e
JJ
56562017-11-19 Jakub Jelinek <jakub@redhat.com>
5657
5658 PR c/66618
5659 PR c/69960
5660 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
5661
1e39313a
JM
56622017-11-16 Joseph Myers <joseph@codesourcery.com>
5663
5664 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
5665 expected publication date of C17.
5666 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
5667
3ca0dc60
JM
56682017-11-15 Joseph Myers <joseph@codesourcery.com>
5669
5670 PR c/81156
5671 * c-common.c (c_common_reswords): Add __builtin_tgmath.
5672 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
5673
025d57f0
MS
56742017-11-10 Martin Sebor <msebor@redhat.com>
5675
5676 PR c/81117
5677 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
5678 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
5679 * c.opt (-Wstringop-truncation): New option.
5680
1b6fa695
ML
56812017-11-06 Martin Liska <mliska@suse.cz>
5682
5683 PR middle-end/82404
5684 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
5685 FE.
5686 * c.opt: Set default value of warn_return_type.
5687
64a5912c
DM
56882017-10-31 David Malcolm <dmalcolm@redhat.com>
5689
5690 * c-common.c (binary_op_error): Update for renaming of
5691 error_at_rich_loc.
5692 (c_parse_error): Likewise.
5693 * c-warn.c (warn_logical_not_parentheses): Likewise for
5694 renaming of inform_at_rich_loc.
5695 (warn_for_restrict): Likewise for renaming of
5696 warning_at_rich_loc_n.
5697
c76dc9c3
JM
56982017-10-30 Joseph Myers <joseph@codesourcery.com>
5699
5700 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
5701 * c-opts.c (set_std_c17): New function.
5702 (c_common_init_options): Use gnu17 as default C version.
5703 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
5704
ee5fd23a
MM
57052017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
5706
5707 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
5708 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
5709 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
5710 __FP_FAST_FMA<N>X.
5711
d1047465
MP
57122017-10-23 Marek Polacek <polacek@redhat.com>
5713
5714 PR c/82681
5715 * c-warn.c (warnings_for_convert_and_check): Fix typos.
5716
9e878cf1
EB
57172017-10-19 Eric Botcazou <ebotcazou@adacore.com>
5718
5719 * c-common.c (check_builtin_function_arguments): Also check arguments
5720 of __builtin_alloca_with_align_and_max.
5721
89b6abbb
DM
57222017-10-17 David Malcolm <dmalcolm@redhat.com>
5723
5724 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
5725 rather than NULL to format_warning_va.
5726 (check_format_types): Likewise when calling format_type_warning.
5727 Remove code to extract source_ranges and source_range * in favor
5728 of just a location_t.
5729 (format_type_warning): Convert source_range * param to a
5730 location_t.
5731
39382c09
JJ
57322017-10-13 Jakub Jelinek <jakub@redhat.com>
5733
5734 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
5735 [LR]SHIFT_EXPR.
5736
62e1c678
DM
57372017-10-12 David Malcolm <dmalcolm@redhat.com>
5738
5739 * c-common.c (enum missing_token_insertion_kind): New enum.
5740 (get_missing_token_insertion_kind): New function.
5741 (maybe_suggest_missing_token_insertion): New function.
5742 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
5743
b90c9338
NS
57442017-10-11 Nathan Sidwell <nathan@acm.org>
5745
5746 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
5747 (c_common_handle_option): Update incpath_kind names.
5748
3a266bcd
ML
57492017-10-11 Martin Liska <mliska@suse.cz>
5750
5751 PR sanitizer/82490
5752 * c-attribs.c (handle_no_sanitize_attribute): Report directly
5753 Wattributes warning.
5754
8e6cdc90
RS
57552017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
5756
5757 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
5758 operating on trees as wide_ints.
5759 * c-common.c (pointer_int_sum): Likewise.
5760 * c-pretty-print.c (pp_c_integer_constant): Likewise.
5761 * c-warn.c (match_case_to_enum_1): Likewise.
5762 (c_do_switch_warnings): Likewise.
5763 (maybe_warn_shift_overflow): Likewise.
5764
802b38c9
JJ
57652017-10-10 Jakub Jelinek <jakub@redhat.com>
5766
5767 PR c/82437
5768 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
5769 instead of wide_int::from.
5770
4e34b338
JJ
57712017-10-06 Jakub Jelinek <jakub@redhat.com>
5772
5773 PR c/82437
5774 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
5775 using to_widest use wide_int with the larger of the two precisions.
5776
4bc4b2b4
BE
57772017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
5778
5779 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
5780 functions.
5781
a1488398
RS
57822017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
5783
5784 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
5785 when combining the original unconverted comparison operands.
5786
01c9fb68
JJ
57872017-09-29 Jakub Jelinek <jakub@redhat.com>
5788
5789 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
5790 attribute.
5791
6e3e8419
EB
57922017-09-29 Eric Botcazou <ebotcazou@adacore.com>
5793
5794 * c-ada-spec.c (to_ada_name): Add index parameter.
5795 (pp_ada_tree_identifier): Likewise.
5796 (dump_ada_macros): Adjust call to to_ada_name.
5797 (struct overloaded_name_hash): New type.
5798 (struct overloaded_name_hasher): Likewise.
5799 (overloaded_names): New hash table.
5800 (compute_overloading_index): New function.
5801 (dump_ada_decl_name): Call it and pass the result to
5802 pp_ada_tree_identifier.
5803 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
5804 (dump_ada_function_declaration): Likewise.
5805 (dump_generic_ada_node): Likewise.
5806 (print_constructor): Likewise.
5807 (print_destructor): Likewise.
5808 (dump_ada_specs): Delete overloaded_names table.
5809
79310774
EB
58102017-09-29 Eric Botcazou <ebotcazou@adacore.com>
5811
5812 * c-ada-spec.c (max_ada_macros): Move around.
5813 (store_ada_macro_index): Likewise.
5814 (source_file): Rename into...
5815 (macro_source_file): ...this.
5816 (count_ada_macro): Move around.
5817 (store_ada_macro): Likewise.
5818 (compare_macro): Likewise.
5819 (print_ada_macros): Merge in...
5820 (dump_ada_macros): ...this.
5821 (source_file_base): Rename into...
5822 (current_source_file): ...this.
5823 (print_comment): Move around.
5824 (dump_ada_nodes): Call dump_ada_declaration directly.
5825 (struct with): Change type of limited field to bool.
5826 (append_withs): Change type of limited_access parameter to bool.
5827 (pp_ada_tree_identifie): Likewise.
5828 (dump_ada_decl_nam): Likewise.
5829 (dump_generic_ada_node): Likewise. Do not print the return type.
5830 (to_ada_name): Change type of space_found parameter to bool.
5831 (dump_ada_function_declaration): Return void and change type of
5832 parameters to bool. Also print the return type for a function.
5833 (print_ada_methods): Rename into...
5834 (dump_ada_methods): ...this.
5835 (print_ada_declaration): Rename into ...
5836 (dump_ada_declaration): ...this. Do not print the return type.
5837 (print_ada_struct_decl): Rename into...
5838 (dump_ada_struct_decl): ...this.
5839
7d386d45
JJ
58402017-09-29 Jakub Jelinek <jakub@redhat.com>
5841
5842 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
5843 rather than DECL_INITIAL.
5844 (common_handle_aligned_attribute): Likewise.
5845
ab20d992 58462017-09-20 Alexandre Oliva <aoliva@redhat.com>
9ed32e27
AO
5847
5848 * c.opt (gen-decls): Add RejectNegative.
5849
026a79f7
AS
58502017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
5851 Jakub Jelinek <jakub@redhat.com>
5852
5853 Add support for -std=c++2a.
5854 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
5855 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
5856 * c-opts.c (set_std_cxx2a): New.
5857 (c_common_handle_option): Set options when -std=c++2a is enabled.
5858 (c_common_post_options): Adjust comments.
5859 (set_std_cxx14, set_std_cxx17): Likewise.
5860
4a8ca690
EB
58612017-09-15 Eric Botcazou <ebotcazou@adacore.com>
5862
5863 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
5864 message for non-uniform endianness and issue a warning in C++.
5865
7b936140
JJ
58662017-09-15 Jakub Jelinek <jakub@redhat.com>
5867
5868 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
5869 (Wc++17-compat): Change from undocumented alias to option.
5870 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
5871 change C++1z to C++17 in description.
5872 (std=c++1z, std=gnu++1z): Change from option to undocumented
5873 deprecated alias.
5874 (std=c++17, std=gnu++17): Change from undocumented alias to option.
5875 Adjust description.
5876 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
5877 * c-opts.c (set_std_cxx1z): Rename to ...
5878 (set_std_cxx17): ... this.
5879 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
5880 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
7365279f 5881 caller.
7b936140
JJ
5882 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
5883 comments.
5884
12263f13
L
58852017-09-12 H.J. Lu <hongjiu.lu@intel.com>
5886
5887 * c-attribs.c (common_handle_aligned_attribute): Don't warn
5888 function alignment if warn_if_not_aligned_p is true.
5889
6836632e
NS
58902017-09-12 Nathan Sidwell <nathan@acm.org>
5891
5892 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
5893 resort_sorted_fields): Move to c/c-decl.c.
5894 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
5895 (struct sorted_fields_type): Move to c/c-lang.h.
5896
019bf9ad
JW
58972017-09-09 Jonathan Wakely <jwakely@redhat.com>
5898
5899 PR c++/81852
5900 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
5901
bc7fe952
MP
59022017-09-04 Marek Polacek <polacek@redhat.com>
5903
5904 PR c/81783
5905 * c-warn.c (warn_tautological_bitwise_comparison): New function.
5906 (warn_tautological_cmp): Call it.
5907
ab20d992 59082017-09-01 Boris Kolpackov <boris@codesynthesis.com>
de7c2c6a
BK
5909
5910 * c-opts.c (c_common_finish): Write dependency information even if
5911 there are errors.
5912
d2e05fcb
JJ
59132017-09-01 Jakub Jelinek <jakub@redhat.com>
5914
5915 PR c/81887
5916 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
5917 (omp_pragmas_simd): ... here.
5918 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
5919 create new clauses list containing just simd clause.
5920
18e2a8b8
RS
59212017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5922 Alan Hayward <alan.hayward@arm.com>
5923 David Sherwood <david.sherwood@arm.com>
5924
5925 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
5926 into scalar_mode_supported_p call.
5927 (handle_mode_attribute): Update call to scalar_mode_supported_p.
5928
16d22000
RS
59292017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5930 Alan Hayward <alan.hayward@arm.com>
5931 David Sherwood <david.sherwood@arm.com>
5932
5933 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
5934 for the mode iterator.
5935
b397965c
RS
59362017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5937 Alan Hayward <alan.hayward@arm.com>
5938 David Sherwood <david.sherwood@arm.com>
5939
5940 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
5941 * c-common.c (c_build_vec_perm_expr): Likewise.
5942
357b7604
RS
59432017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5944 Alan Hayward <alan.hayward@arm.com>
5945 David Sherwood <david.sherwood@arm.com>
5946
5947 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
5948
e05c94ba
RS
59492017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5950 Alan Hayward <alan.hayward@arm.com>
5951 David Sherwood <david.sherwood@arm.com>
5952
5953 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
5954 before calling targetm.addr_space.valid_pointer_mode.
5955
5c20c4af
RS
59562017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5957 Alan Hayward <alan.hayward@arm.com>
5958 David Sherwood <david.sherwood@arm.com>
5959
5960 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
5961
c94843d2 59622017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
92a285c1
ML
5963 Alan Hayward <alan.hayward@arm.com>
5964 David Sherwood <david.sherwood@arm.com>
c94843d2
RS
5965
5966 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
5967 iterators.
5968 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
5969
4e10a5a7
RS
59702017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5971 Alan Hayward <alan.hayward@arm.com>
5972 David Sherwood <david.sherwood@arm.com>
5973
5974 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
5975 case statements.
5976
130fcab0
ML
59772017-08-29 Martin Liska <mliska@suse.cz>
5978
5979 PR other/39851
5980 * c-common.c (parse_optimize_options): Add argument to function
5981 call.
5982 * c-pragma.c (handle_pragma_diagnostic): Likewise.
5983
14e18d71
DM
59842017-08-24 David Malcolm <dmalcolm@redhat.com>
5985
5986 * c-lex.c (interpret_float): Use token location
5987 when building an EXCESS_PRECISION_EXPR.
5988
2f687306
DM
59892017-08-21 David Malcolm <dmalcolm@redhat.com>
5990
5991 * c-common.c (check_function_arguments): Add "arglogs" param; pass
5992 it to check_function_format.
5993 * c-common.h (check_function_arguments): Add vec<location_t> *
5994 param.
5995 (check_function_format): Likewise.
5996 * c-format.c (struct format_check_context): Add field "arglocs".
5997 (check_function_format): Add param "arglocs"; pass it to
5998 check_format_info.
ab20d992 5999 (check_format_info): Add param "arglocs"; use it to initialize
2f687306
DM
6000 new field of format_ctx.
6001 (check_format_arg): Pass format_ctx->arglocs to new param of
6002 check_format_info_main.
6003 (class argument_parser): New field "arglocs".
6004 (argument_parser::argument_parser): Add "arglocs_" param and use
6005 it to initialize new field.
6006 (argument_parser::check_argument_type): Pass new arglocs field to
6007 check_format_types.
6008 (check_format_info_main): Add param "arglocs", and use it when
6009 constructing arg_parser.
6010 (check_format_types): Add param "arglocs"; use it if non-NULL when
6011 !EXPR_HAS_LOCATION (cur_param) to get at location information.
6012
00aa1fa2
L
60132017-08-18 H.J. Lu <hongjiu.lu@intel.com>
6014
6015 PR c/53037
6016 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
6017 (c_common_attribute_table): Add warn_if_not_aligned.
6018 (handle_aligned_attribute): Renamed to ...
6019 (common_handle_aligned_attribute): Remove argument, name, and add
6020 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
6021 (handle_aligned_attribute): New.
6022 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
6023
27be025d
MS
60242017-08-14 Martin Sebor <msebor@redhat.com>
6025
6026 PR c/81117
6027 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
6028 (handle_nonstring_attribute): New function.
6029
da67acb9
MS
60302017-08-14 Martin Sebor <msebor@redhat.com>
6031
6032 PR c/81117
6033 * c-format.h (T89_G): New macro.
6034 * c-format.c (local_gcall_ptr_node): New variable.
6035 (init_dynamic_diag_info): Initialize it.
6036
a8b522b4
ML
60372017-08-11 Martin Liska <mliska@suse.cz>
6038
6039 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
6040 TARGET_SUPPORTS_ALIASES.
6041
32129a17
DM
60422017-08-10 David Malcolm <dmalcolm@redhat.com>
6043
6044 * c-common.c (c_parse_error): Add rich_location * param, using it
6045 rather implicitly using input_location.
6046 * c-common.h (c_parse_error): Add rich_location * param.
6047
30af3a2b
MP
60482017-08-09 Marek Polacek <polacek@redhat.com>
6049
6050 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
6051 (c_common_truthvalue_conversion): Likewise.
6052 * c-omp.c (c_finish_omp_atomic): Likewise.
6053 * c-common.h (build_binary_op): Update declaration.
6054
314e6352
ML
60552017-08-08 Martin Liska <mliska@suse.cz>
6056
6057 * c-ada-spec.c: Include header files.
6058 * c-ubsan.c: Likewise.
6059 * c-warn.c: Likewise.
6060
56b5041c
JJ
60612017-08-07 Jakub Jelinek <jakub@redhat.com>
6062
6063 PR c/69389
6064 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
6065
db440138
EB
60662017-08-07 Eric Botcazou <ebotcazou@adacore.com>
6067
6068 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
6069 (print_ada_methods): Likewise.
6070 (print_ada_declaration): Likewise.
6071
577eec56
ML
60722017-08-07 Martin Liska <mliska@suse.cz>
6073
6074 * array-notation-common.c: Add new includes.
6075 * c-format.c( handle_format_attribute): Canonicalize a format
6076 function name.
6077 * c-lex.c (c_common_has_attribute): Canonicalize name of an
6078 attribute.
6079 * c-pretty-print.c: Add new include.
6080
b854df3c
EB
60812017-08-05 Eric Botcazou <ebotcazou@adacore.com>
6082
6083 * c-ada-spec.c (has_static_fields): Look only into variables.
6084 (print_constructor): Add TYPE parameter and use it for the name.
6085 (print_destructor): Likewise.
6086 (print_ada_declaration): Adjust to new constructor/destructor names.
6087 Adjust calls to print_constructor and print_destructor.
6088 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
6089 Look only into variables in the final loop.
6090
9f2cb25e
EB
60912017-08-01 Eric Botcazou <ebotcazou@adacore.com>
6092
6093 * c-ada-spec.c (has_static_fields): Look only into fields.
6094 (dump_generic_ada_node): Small tweak.
6095 (dump_nested_types): Look only into fields.
6096 (print_ada_declaration): Look only into methods. Small tweak.
6097 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
6098
f4bcd9eb
EB
60992017-08-01 Eric Botcazou <ebotcazou@adacore.com>
6100
6101 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
6102 (dump_ada_function_declaration): Likewise.
6103 (dump_generic_ada_node): Likewise.
6104 (print_ada_declaration): Add support for const-qualified variables.
6105
f34ebeb2
ML
61062017-07-31 Martin Liska <mliska@suse.cz>
6107
6108 PR sanitize/81530
6109 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
6110 Guard condition with flag_sanitize_p also with current_function_decl
6111 non-null equality.
6112 (ubsan_maybe_instrument_reference_or_call): Likewise.
6113
218e5d04
UB
61142017-07-30 Uros Bizjak <ubizjak@gmail.com>
6115
6116 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
6117
942047f2
EB
61182017-07-29 Eric Botcazou <ebotcazou@adacore.com>
6119
6120 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
6121 for enumeral types.
6122 (print_ada_declaration): Add missing guard for record types.
6123
a40ff0ae
JJ
61242017-07-27 Jakub Jelinek <jakub@redhat.com>
6125
6126 PR c/45784
6127 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
6128 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
6129 new COMPOUND_EXPRs around the rhs of the comparison.
6130
06bd22f6
MP
61312017-07-27 Marek Polacek <polacek@redhat.com>
6132
6133 PR c/81417
6134 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
6135 the types.
6136
036ea399
JJ
61372017-07-27 Jakub Jelinek <jakub@redhat.com>
6138
6139 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
6140 (handle_noipa_attribute): New function.
6141
417ca011
TD
61422017-07-07 Torsten Duwe <duwe@suse.de>
6143
6144 * c-attribs.c (c_common_attribute_table): Add entry for
6145 "patchable_function_entry".
6146
5aaa8fb4
NS
61472017-07-20 Nathan Sidwell <nathan@acm.org>
6148
6149 Remove TYPE_METHODS.
6150 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
6151 dump_ada_template, print_ada_methods,
6152 print_ada_declaration): Member fns are on TYPE_FIELDS.
6153
ff22eb12
NS
61542017-07-18 Nathan Sidwell <nathan@acm.org>
6155
6156 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
6157
eea77d1f
DM
61582017-07-14 David Malcolm <dmalcolm@redhat.com>
6159
6160 * c-common.c (try_to_locate_new_include_insertion_point): New
6161 function.
6162 (per_file_includes_t): New typedef.
6163 (added_includes_t): New typedef.
6164 (added_includes): New variable.
6165 (maybe_add_include_fixit): New function.
6166 * c-common.h (maybe_add_include_fixit): New decl.
6167
281ac396
MS
61682017-07-10 Martin Sebor <msebor@redhat.com>
6169
6170 PR other/81345
6171 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
6172
b6f43128
DM
61732017-07-06 David Malcolm <dmalcolm@redhat.com>
6174
6175 * c-common.c (selftest::c_family_tests): New.
6176 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
6177 (selftest::c_family_tests): New decl.
6178
efbf55b0
MP
61792017-07-04 Marek Polacek <polacek@redhat.com>
6180
6181 PR c/81231
6182 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
6183 types.
6184
6c86bd88
MP
61852017-07-04 Marek Polacek <polacek@redhat.com>
6186
6187 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
6188
17a7218b
ML
61892017-06-28 Martin Liska <mliska@suse.cz>
6190
6191 PR ipa/81128
6192 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
6193 to a function declaration.
6194
63010089
ML
61952017-06-28 Martin Liska <mliska@suse.cz>
6196
6197 PR driver/79659
6198 * c.opt: Add IntegerRange to various options.
6199
3e2becc4
MP
62002017-06-26 Marek Polacek <polacek@redhat.com>
6201
6202 PR c/80116
6203 * c-common.h (warn_for_multistatement_macros): Declare.
6204 * c-warn.c: Include "c-family/c-indentation.h".
6205 (warn_for_multistatement_macros): New function.
6206 * c.opt (Wmultistatement-macros): New option.
6207 * c-indentation.c (guard_tinfo_to_string): No longer static.
6208 Change the parameter type to "enum rid". Handle RID_SWITCH.
6209 * c-indentation.h (guard_tinfo_to_string): Declare.
6210
2db9b7cd
MG
62112017-06-23 Marc Glisse <marc.glisse@inria.fr>
6212
6213 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
6214
c3684b7b
MS
62152017-06-15 Martin Sebor <msebor@redhat.com>
6216
6217 PR c++/80560
6218 * c.opt (-Wclass-memaccess): New option.
6219
e72c4afd
BK
62202017-06-14 Boris Kolpackov <boris@codesynthesis.com>
6221
6222 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
6223
8a516588
MP
62242017-06-13 Marek Polacek <polacek@redhat.com>
6225
6226 PR objc/80949
6227 * c-warn.c (do_warn_duplicated_branches): Return if any of the
6228 branches is null.
6229
45b2222a
ML
62302017-06-13 Martin Liska <mliska@suse.cz>
6231
6232 PR sanitize/78204
6233 * c-attribs.c (add_no_sanitize_value): New function.
6234 (handle_no_sanitize_attribute): Likewise.
6235 (handle_no_sanitize_address_attribute): Use the function.
6236 (handle_no_sanitize_thread_attribute): New function.
6237 (handle_no_address_safety_analysis_attribute): Use
6238 add_no_sanitize_value.
6239 (handle_no_sanitize_undefined_attribute): Likewise.
6240 * c-common.h: Declare new functions.
6241 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
6242 (ubsan_instrument_shift): Likewise.
6243 (ubsan_instrument_bounds): Likewise.
6244 (ubsan_maybe_instrument_array_ref): Likewise.
6245 (ubsan_maybe_instrument_reference_or_call): Likewise.
6246
a01f151f
JM
62472017-06-11 Jason Merrill <jason@redhat.com>
6248
6249 * c-ada-spec.c, c-pragma.c: Use id_equal.
6250
3de4ac6d
MP
62512017-06-04 Marek Polacek <polacek@redhat.com>
6252
6253 PR c/80919
6254 * c-format.c (matching_type_p): Return false if any of the types
6255 requires structural equality.
6256
2474f48f
MS
62572017-06-02 Martin Sebor <msebor@redhat.com>
6258
6259 PR c/80892
6260 * c-warn.c (conversion_warning): Use -Wconversion for integer
6261 conversion and -Wfloat-conversion for floating one.
6262
40ffd95f
BE
62632017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
6264
6265 * c.opt (Wsizeof-pointer-div): New warning option.
6266
3fa4634c
VR
62672017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
6268
6269 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
6270 (Wcatch-value=1): Enable by -Wall.
6271
f012c8ef
DM
62722017-05-30 David Malcolm <dmalcolm@redhat.com>
6273
6274 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
6275 format_chars.
6276 * c.opt (fdiagnostics-show-template-tree): New option.
6277 (felide-type): New option.
6278
63dbcd13
VR
62792017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
6280
6281 * c.opt (Wcatch-value=): New C++ warning flag.
6282
be136b5c
NS
62832017-05-24 Nathan Sidwell <nathan@acm.org>
6284
6285 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
6286 const casts to avoid warning.
6287
3cd211af
MS
62882017-05-24 Martin Sebor <msebor@redhat.com>
6289
6290 PR c/80731
6291 * c-common.h (unsafe_conversion_p): Add a function argument.
6292 * c-common.c (unsafe_conversion_p): Same.
6293 Add type names and values to diagnostics.
6294 (scalar_to_vector): Adjust.
6295 * c-warn.c (constant_expression_error): Add a function argument.
6296 Add type names and values to diagnostics.
6297 (conversion_warning): Add a function argument.
6298 Add type names and values to diagnostics.
6299 (warnings_for_convert_and_check): Same.
6300
1ff7be5a
JM
63012017-05-19 Jason Merrill <jason@redhat.com>
6302
6303 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
6304 enumerators.
6305
ff502317
BE
63062017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
6307
6308 * c-format.c (locus): Move out of function scope,
6309 add GTY attribute.
6310
2a8a8d7b
NS
63112017-05-19 Nathan Sidwell <nathan@acm.org>
6312
6313 * c-opts.c (class_dump_file, class_dump_flags): Delete.
6314 (c_common_parse_file): Remove class dump handling.
6315 (get_dump_info): Likewise.
6316
39aac208
RB
63172017-05-19 Richard Biener <rguenther@suse.de>
6318
6319 PR c++/80593
6320 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
6321 to alias-set zero memory.
6322
6ecd2339
BE
63232017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
6324
6325 * c-format.c (local_tree_type_node): Add GTY attribute.
6326
6574d78e
MP
63272017-05-18 Marek Polacek <polacek@redhat.com>
6328
6329 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
6330 (c_common_fixed_point_type_for_size): Likewise.
6331 (c_common_type_for_mode): Likewise.
6332 (shorten_compare): Likewise.
6333 (c_promoting_integer_type_p): Use false/true instead of 0/1.
6334 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
6335
e3455240
MP
63362017-05-18 Marek Polacek <polacek@redhat.com>
6337
6338 * c-common.c (self_promoting_args_p): Change the return type to bool.
6339 Use false/true instead of 0/1.
6340 * c-common.h (self_promoting_args_p): Update.
6341
3fa8871b
MP
63422017-05-17 Marek Polacek <polacek@redhat.com>
6343
6344 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
6345 * c-warn.c: Likewise.
6346
b42cc3ca
VV
63472017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
6348
6349 Implement new C++ intrinsics __is_assignable and __is_constructible.
6350 * c-common.c (__is_assignable, __is_constructible): New.
6351 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
6352
1a817418
ML
63532017-05-17 Martin Liska <mliska@suse.cz>
6354
6355 * c-common.h: Introduce dump_flags_t type and
6356 use it instead of int type.
6357 * c-gimplify.c (c_genericize): Likewise.
6358 * c-opts.c: Likewise.
6359
b2fa0a8b
MP
63602017-05-17 Marek Polacek <polacek@redhat.com>
6361
6362 * c-common.c (c_save_expr): Remove.
6363 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
6364 * c-common.h (c_save_expr): Remove declaration.
6365
31c2d57d
VR
63662017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
6367
6368 PR c/35441
6369 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
6370 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
6371 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
6372 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
6373 RDIV_EXPR.
6374 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
6375
684f84de
MP
63762017-05-09 Marek Polacek <polacek@redhat.com>
6377
6378 PR c/80525
6379 * c-warn.c (unwrap_c_maybe_const): New.
6380 (warn_logical_operator): Call it.
6381
641da50a
NS
63822017-05-09 Nathan Sidwell <nathan@acm.org>
6383
6384 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
6385 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
6386
631238ac
MS
63872017-05-08 Martin Sebor <msebor@redhat.com>
6388
6389 PR translation/80280
6390 * c-format.h (struct format_flag_spec): Add new member.
6391 (T89_T): New macro.
6392 * c-format.c (local_tree_type_node): New global.
6393 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
6394 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
6395 (strfmon_flag_specs): Likewise.
6396 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
6397 with distinct quoting properties.
6398 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
6399 (flag_chars_t::validate): Add argument and handle bad quoting.
6400 (check_format_info_main): Handle quoting problems.
6401 (init_dynamic_diag_info): Simplify.
6402
49f0c04c
JM
64032017-05-08 Jason Merrill <jason@redhat.com>
6404
6405 * c-opts.c (c_common_post_options): Update defaults for
6406 flag_abi_version and flag_abi_compat_version.
6407
56d35585
DM
64082017-05-05 David Malcolm <dmalcolm@redhat.com>
6409
6410 * c-common.c (c_cpp_error): Replace report_diagnostic
6411 with diagnostic_report_diagnostic.
6412
0f2c4a8f
MS
64132017-05-04 Martin Sebor <msebor@redhat.com>
6414
6415 PR translation/80280
6416 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
6417 (handle_weakref_attribute): Same.
6418
6fe63fb4
NS
64192017-05-03 Nathan Sidwell <nathan@acm.org>
6420
6421 Canonicalize canonical type hashing
6422 * c-common.c (complete_array_type): Use type_hash_canon.
6423
815d9cc6
XR
64242017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
6425
92a285c1 6426 PR c++/80038
815d9cc6
XR
6427 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
6428 prototype.
6429 (cilk_install_body_pedigree_operations): Likewise.
6430 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
6431 detatched.
6432 (cilk_gimplify_call_params_in_spawned_fn): Remove.
6433 (cilk_install_body_pedigree_operations): Likewise.
6434 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
6435 unwrapping.
6436
f8a36447
JJ
64372017-04-27 Jakub Jelinek <jakub@redhat.com>
6438
6439 PR c++/80534
6440 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
6441 flag on non-aggregate element types.
6442
7c145456
BE
64432017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
6444
6445 * c-common.c (c_type_hasher, type_hash_table): Remove.
6446 (c_common_get_alias_set): Remove unreachable code.
6447 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
6448
c3cbcd45
VR
64492017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
6450
6451 * c.opt (Wextra-semi): New C++ warning flag.
6452
8a59d466
JJ
64532017-04-20 Jakub Jelinek <jakub@redhat.com>
6454
6455 PR middle-end/80423
6456 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
6457
8487c9a5
JJ
64582017-04-18 Jakub Jelinek <jakub@redhat.com>
6459
6460 PR middle-end/79788
6461 PR middle-end/80375
6462 * c-common.c (c_common_type_for_mode): Don't handle
6463 widest_*_literal_type_node here.
6464 c_common_signed_or_unsigned_type): Likewise.
6465 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
6466 to *intTI_type_node or *intDI_type_node depending on whether
6467 TImode is supported by the target or not.
6468
3ee0fb02
ML
64692017-04-10 Martin Liska <mliska@suse.cz>
6470
6471 PR sanitizer/80350
6472 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
6473 doing an UBSAN check.
6474
5764ee3c
JW
64752017-04-03 Jonathan Wakely <jwakely@redhat.com>
6476
6477 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
6478
6f3af356
JJ
64792017-03-31 Jakub Jelinek <jakub@redhat.com>
6480
6481 PR c++/79572
6482 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
6483 tree *.
6484 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
6485 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
6486 REFERENCE_TYPE.
6487
f6a7a9d5
DM
64882017-03-31 David Malcolm <dmalcolm@redhat.com>
6489
6490 PR documentation/78732
6491 * c.opt (Wendif-labels): Fix description to refer to
6492 #else rather than #elif.
6493
af88f557
JJ
64942017-03-31 Jakub Jelinek <jakub@redhat.com>
6495
6496 PR libstdc++/80251
6497 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
6498 * c-common.c (c_common_reswords): Add __is_aggregate trait.
6499
a9e4a1a5
JJ
65002017-03-27 Jakub Jelinek <jakub@redhat.com>
6501
6502 PR middle-end/80162
6503 * c-common.c (c_common_mark_addressable_vec): Don't set
6504 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
6505
3f01b620
MS
65062017-03-21 Martin Sebor <msebor@redhat.com>
6507
6508 PR c++/79548
6509 * c-common.c (set_underlying_type): Mark type used only when
6510 original del is declared unused.
6511
2f6f187a
DM
65122017-03-10 David Malcolm <dmalcolm@redhat.com>
6513
6514 PR translation/79848
6515 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
6516 "%qs".
6517
a02fa805
DM
65182017-03-10 David Malcolm <dmalcolm@redhat.com>
6519
6520 PR c/79921
6521 * c-indentation.c (warn_for_misleading_indentation): Remove parens
6522 from inform's message, so that xgettext can locate it.
6523
822a132c
MP
65242017-03-09 Marek Polacek <polacek@redhat.com>
6525
6526 PR c++/79962
6527 PR c++/79984
6528 * c-attribs.c (handle_nonnull_attribute): Save the result of default
6529 conversion to the attribute list.
6530
bba81f1c
ML
65312017-03-09 Martin Liska <mliska@suse.cz>
6532
6533 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
6534
108154ff
JM
65352017-03-03 Jason Merrill <jason@redhat.com>
6536
6537 * c.opt (Wnoexcept-type): New.
6538
eb0e7c34
RB
65392017-03-02 Richard Biener <rguenther@suse.de>
6540
6541 PR c/79756
6542 * c-common.c (c_common_mark_addressable_vec): Look through
6543 C_MAYBE_CONST_EXPR.
6544
9453ba0a
ML
65452017-02-28 Martin Liska <mliska@suse.cz>
6546
6547 * c.opt: Replace space with tabular for options of <number>
6548 type.
6549
6a825afe
ML
65502017-02-28 Martin Liska <mliska@suse.cz>
6551
6552 * c.opt: Fix --help=option -Q for options which are of
6553 an enum type.
6554
4227c9ad
JJ
65552017-02-24 Jakub Jelinek <jakub@redhat.com>
6556
6557 PR c++/79588
6558 * c-common.c (check_function_restrict): New function.
6559 (check_function_arguments): Add FNDECL argument. Call
6560 check_function_restrict if -Wrestrict.
6561 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
6562 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
6563 * c-common.h (check_function_arguments): Add FNDECL argument.
6564 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
6565
59909673
EB
65662017-02-24 Eric Botcazou <ebotcazou@adacore.com>
6567
6568 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
6569 treatment of parameters with pointer-to-tagged type and tidy up.
6570 (print_ada_methods): Remove the special treatment of C++ static member
6571 functions.
6572
54dcd526
ML
65732017-02-22 Martin Liska <mliska@suse.cz>
6574
6575 * c.opt: Replace inequality signs with square brackets
6576 for -Wnornalized.
6577
00bc9de3
JJ
65782017-02-21 Jakub Jelinek <jakub@redhat.com>
6579
6580 PR c++/79641
6581 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
6582 preserve quals.
6583
97fcf744
JM
65842017-02-17 Joseph Myers <joseph@codesourcery.com>
6585
6586 * c-cppbuiltin.c (builtin_define_float_constants): Define
6587 __DECIMAL_DIG__ to the value for long double.
6588
c7545f1c
MP
65892017-02-15 Marek Polacek <polacek@redhat.com>
6590
6591 PR c/79515
6592 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
6593 conversion has occured.
6594
c2e84327
DM
65952017-01-24 David Malcolm <dmalcolm@redhat.com>
6596
6597 * c-common.c (c_common_reswords): Add "__RTL".
6598 * c-common.h (enum rid): Add RID_RTL.
6599
2ebd93e1
MP
66002017-01-20 Marek Polacek <polacek@redhat.com>
6601
6602 PR c/64279
6603 * c-common.h (do_warn_duplicated_branches_r): Declare.
6604 * c-gimplify.c (c_genericize): Walk the function tree calling
6605 do_warn_duplicated_branches_r.
6606 * c-warn.c (expr_from_macro_expansion_r): New.
6607 (do_warn_duplicated_branches): New.
6608 (do_warn_duplicated_branches_r): New.
6609 * c.opt (Wduplicated-branches): New option.
6610
0d80ab91
DM
66112017-01-17 David Malcolm <dmalcolm@redhat.com>
6612
6613 PR c++/71497
6614 * c-indentation.c (warn_for_misleading_indentation): Use the past
6615 subjunctive in the note.
6616
7f991c36
AH
66172017-01-17 Aldy Hernandez <aldyh@redhat.com>
6618
6619 PR c/79116
6620 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
6621 start type to integer_type.
6622
1c70261c
JJ
66232017-01-16 Jakub Jelinek <jakub@redhat.com>
6624
6625 PR driver/49726
6626 * c.opt (gen-decls): Add Driver flag.
6627
1ddca3f3
PC
66282017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
6629
6630 Revert:
6631 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
6632
6633 PR c++/71737
6634 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
6635
7d2f3f1d
PC
66362017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
6637
6638 PR c++/71737
6639 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
6640
bce6f760
MS
66412017-01-12 Martin Sebor <msebor@redhat.com>
6642
6643 (-Wformat-overflow): ...to this.
6644
bf5fbf46
MS
66452017-01-11 Martin Sebor <msebor@redhat.com>
6646
6647 PR c/78768
6648 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
6649 Also enable for LTO.
6650
e363df3f
JM
66512017-01-10 Jason Merrill <jason@redhat.com>
6652
6653 Implement P0195R2, C++17 variadic using.
6654 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
6655
bd2c6270
JJ
66562017-01-09 Jakub Jelinek <jakub@redhat.com>
6657
6658 PR translation/79019
6659 PR translation/79020
6660 * c.opt (Wnormalized=): Fix typo in description.
6661
efcc8d38
MS
66622017-01-08 Martin Sebor <msebor@redhat.com>
6663
6664 PR middle-end/77708
6665 * c.opt (-Wformat-truncation): New option.
6666
ab20d992 66672017-01-06 Alexandre Oliva <aoliva@redhat.com>
435f3f7a
AO
6668
6669 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
6670 value to unsigned short to fit in 4 hex digits without
6671 warnings.
6672
4e89adf9
EB
66732017-01-05 Eric Botcazou <ebotcazou@adacore.com>
6674
6675 * c.opt (fsso-struct): Add 'native' value.
6676
cd445b54
ML
66772017-01-05 Martin Liska <mliska@suse.cz>
6678
6679 PR pch/78970
6680 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
6681 header.
6682
a9342885
MP
66832017-01-04 Marek Polacek <polacek@redhat.com>
6684
6685 PR c++/64767
6686 * c.opt (Wpointer-compare): New option.
6687
fc73e60c
JJ
66882017-01-04 Jakub Jelinek <jakub@redhat.com>
6689
6690 PR driver/78957
6691 * c.opt (fsso-struct=): Add RejectNegative.
6692
cbe34bb5
JJ
66932017-01-01 Jakub Jelinek <jakub@redhat.com>
6694
6695 Update copyright years.
6696
d4a6c0ea
ML
66972016-12-29 Martin Liska <mliska@suse.cz>
6698
6699 PR c/78933
6700 * c.opt (strong-eval-order): Add RejectNegative keyword.
6701
67a5ad7c
JM
67022016-12-22 Jason Merrill <jason@redhat.com>
6703
6704 Implement P0522R0, matching of template template arguments.
6705 * c-cppbuiltin.c (c_cpp_builtins): Define
6706 __cpp_template_template_args.
6707
0dba7960
JJ
67082016-12-21 Jakub Jelinek <jakub@redhat.com>
6709
6710 PR bootstrap/78817
6711 * c-common.c (struct nonnull_arg_ctx): New type.
6712 (check_function_nonnull): Return bool instead of void. Use
6713 nonnull_arg_ctx as context rather than just location_t.
6714 (check_nonnull_arg): Adjust for the new context type, set
6715 warned_p to true if a warning has been diagnosed.
6716 (check_function_arguments): Return bool instead of void.
6717 * c-common.h (check_function_arguments): Adjust prototype.
6718
31bfc9b9
JM
67192016-12-21 Jason Merrill <jason@redhat.com>
6720
6721 * c.opt (-fnew-ttp-matching): New flag.
6722 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
6723
629b3d75
MJ
67242016-12-14 Martin Jambor <mjambor@suse.cz>
6725
6726 * c-omp.c: Include omp-general.h instead of omp-low.h.
6727 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
6728 name.
6729
474da67e
MS
67302016-12-14 Martin Sebor <msebor@redhat.com>
6731
6732 PR c/17308
6733 * c-common.c (check_nonnull_arg): Disable when optimization
6734 is enabled.
6735
fe366b87
MP
67362016-12-12 Marek Polacek <polacek@redhat.com>
6737
6738 PR c++/78647
6739 * c-common.c (attribute_fallthrough_p): Return false for
6740 error_mark_node.
6741
8bd9f164
MS
67422016-12-08 Martin Sebor <msebor@redhat.com>
6743
6744 PR c/78284
6745 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
6746
060162e0
MS
67472016-12-08 Martin Sebor <msebor@redhat.com>
6748
6749 PR c/78165
92a285c1
ML
6750 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
6751 suffix.
060162e0 6752
ee92e7ba
MS
67532016-12-07 Martin Sebor <msebor@redhat.com>
6754
6755 PR c/53562
6756 PR middle-end/77784
6757 PR middle-end/78149
6758 PR middle-end/78138
6759 * c.opt (-Wstringop-overflow): New option.
6760
84b0769e
MO
67612016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
6762
6763 * c-attribs.c (asan odr indicator): New attribute.
6764 (handle_asan_odr_indicator_attribute): New function.
6765
7fa6a965
PK
67662016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
6767
6768 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
6769 ptrdiff_type_node;
6770
56d8ffc1
JG
67712016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
6772
6773 * c-common.c (excess_precision_mode_join): New.
6774 (c_ts18661_flt_eval_method): New.
6775 (c_c11_flt_eval_method): Likewise.
6776 (c_flt_eval_method): Likewise.
6777 * c-common.h (excess_precision_mode_join): New.
6778 (c_flt_eval_method): Likewise.
6779 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
6780 (cpp_iec_559_value): Call it.
6781 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
6782 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
6783 __FLT_EVAL_METHOD_TS_18661_3__.
6784
04f0fcf7
JG
67852016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
6786
6787 * c-opts.c (c_common_post_options): Add logic to handle the default
6788 case for -fpermitted-flt-eval-methods.
6789
fb2675cb
PB
67902016-11-23 Paolo Bonzini <bonzini@gnu.org>
6791
6792 * c.opt (Wexpansion-to-defined): New.
6793
ec1c5694
JJ
67942016-11-23 Jakub Jelinek <jakub@redhat.com>
6795
6796 PR target/78451
6797 * c-pragma.c (handle_pragma_target): Don't replace
6798 current_target_pragma, but chainon the new args to the current one.
6799
730c9e75
NS
68002016-11-22 Nathan Sidwell <nathan@acm.org>
6801
6802 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
cacd29be 6803 indentation and formatting.
730c9e75 6804
89990732
MS
68052016-11-21 Martin Sebor <msebor@redhat.com>
6806
6807 * c.opt (-fprintf-return-value): Enable by default.
6808
48330c93
BE
68092016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
6810
6811 PR c++/71973
6812 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
6813 * c-common.c (c_common_nodes_and_builtins): Initialize
6814 const_tm_ptr_type_node.
6815
0d939c95
MP
68162016-11-16 Marek Polacek <polacek@redhat.com>
6817
6818 PR c/78285
6819 * c-common.c (c_add_case_label): Turn error_at calls into inform.
6820
8e745a17
JJ
68212016-11-14 Jakub Jelinek <jakub@redhat.com>
6822
6823 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
6824
1ee62b92 68252016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
8e745a17
JJ
6826 Richard Biener <rguenther@suse.de>
6827
6828 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
6829 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
6830 * c.opt (fgimple): New option.
1ee62b92 6831
22b15758
UB
68322016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
6833
6834 PR c/35503
6835 * c-common.h (warn_for_restrict): Declare.
6836 * c-warn.c: Include gcc-rich-location.h.
6837 (warn_for_restrict): New function.
6838 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
6839 (gcc_cdiag_char_table): Likewise.
6840 (gcc_cxxdiag_char_table): Likewise.
6841 * c.opt (Wrestrict): New option.
6842
4be719cd
EB
68432016-11-13 Eric Botcazou <ebotcazou@adacore.com>
6844
6845 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
6846 for nested types only if the type is a record or union and dump SLOC.
6847
4a826ca6
JM
68482016-11-09 Jason Merrill <jason@redhat.com>
6849
6850 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
6851
2e955d50
JJ
68522016-11-09 Jakub Jelinek <jakub@redhat.com>
6853
6854 * c-ubsan.c (ubsan_instrument_shift): Handle split
6855 -fsanitize=shift-base and -fsanitize=shift-exponent.
6856
51dc6603
JM
68572016-11-07 Jason Merrill <jason@redhat.com>
6858
6859 * c.opt (Wc++1z-compat): New.
6860 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
6861
6dc4a604
ML
68622016-11-07 Martin Liska <mliska@suse.cz>
6863
6864 * c-warn.c (warn_for_unused_label): Save all labels used
6865 in goto or in &label.
6866
b302001e
JM
68672016-11-03 Jason Merrill <jason@redhat.com>
6868
6869 * c-cppbuiltin.c (c_cpp_builtins): Correct
6870 __cpp_inheriting_constructors.
6871
31f7f784
JM
68722016-11-01 Jason Merrill <jason@redhat.com>
6873
2bc78e3c
JM
6874 * c-cppbuiltin.c (c_cpp_builtins): Update
6875 __cpp_inheriting_constructors.
6876
31f7f784
JM
6877 * c.opt (-fnew-inheriting-ctors): New.
6878 * c-opts.c: Default to on for ABI 11+.
6879
dcb466ec
JJ
68802016-10-31 Jakub Jelinek <jakub@redhat.com>
6881
6882 PR c++/77948
6883 * c.opt (fext-numeric-literals): Add Var and Init.
6884 * c-opts.c (c_common_handle_option): Don't clear
6885 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
6886 (c_common_post_options): Clear it here if not set
6887 explicitly.
6888
52e1b91e
AH
68892016-10-28 Aldy Hernandez <aldyh@redhat.com>
6890
6891 PR debug/77773
6892 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
6893 if NULL.
6894
e16f1cc7
JJ
68952016-10-25 Jakub Jelinek <jakub@redhat.com>
6896
6897 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
6898 * c-common.c (c_common_reswords): Add __builtin_launder.
6899
f8348061
BE
69002016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
6901
6902 * c-common.c (c_common_truthvalue_conversion): Warn for
6903 multiplications in boolean context. Fix the quoting of '<<' and '<'
6904 in the shift warning.
6905
eff89e01
BE
69062016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
6907
6908 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
6909
24bc7bf4
JM
69102016-10-20 Jason Merrill <jason@redhat.com>
6911
6912 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
6913
4c712374
BE
69142016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
6915
6916 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
6917 integer shift ops in boolean context.
6918
69192016-10-18 Aldy Hernandez <aldyh@redhat.com>
adc577c5
AH
6920
6921 * c.opt (Walloca): New.
6922 (Walloca-larger-than=): New.
6923 (Wvla-larger-than=): New.
6924
8fa18c06
MP
69252016-10-17 Marek Polacek <polacek@redhat.com>
6926
6927 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
6928 Return immediately when finding a match.
6929 (warn_tautological_cmp): Remove a boolean variable that is no longer
6930 needed.
6931
b12b1915
MP
69322016-10-17 Marek Polacek <polacek@redhat.com>
6933
6934 * c-attribs.c: New file.
6935 * c-common.c: Move attributes handling to c-attribs.c.
6936 (get_nonnull_operand): No longer static.
6937 * c-common.h: Move the declarations from c-attribs.c to its own section.
6938
2045acd9
JM
69392016-10-14 Jason Merrill <jason@redhat.com>
6940
6941 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
6942 and __cpp_deduction_guides.
6943
14a2c9aa
JM
69442016-10-13 Jason Merrill <jason@redhat.com>
6945
6946 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
6947
4d0cdd0c
TP
69482016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
6949
6950 * c-cppbuiltin.c: Include memmodel.h.
6951 * c-opts.c: Likewise.
6952 * c-pragma.c: Likewise.
6953 * c-warn.c: Likewise.
6954
70f6d5e1
JJ
69552016-10-12 Jakub Jelinek <jakub@redhat.com>
6956
6957 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
6958 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
6959 * c-opts.c (sanitize_cpp_opts): Initialize
6960 cpp_opts->cpp_warn_implicit_fallthrough.
6961
78f61294
MP
69622016-10-11 Marek Polacek <polacek@redhat.com>
6963
6964 * c-common.c (warning_candidate_p): Change the return type to bool
6965 and return true/false instead of 1/0.
6966 (vector_mode_valid_p): Likewise.
6967
038b5cc0
MP
69682016-10-11 Marek Polacek <polacek@redhat.com>
6969
6970 * c-common.c (fold_for_warn): No longer static.
6971 (bool_promoted_to_int_p): Likewise.
6972 (c_common_get_narrower): Likewise.
6973 (constant_expression_warning): Move to c-warn.c.
6974 (constant_expression_error): Likewise.
6975 (overflow_warning): Likewise.
6976 (warn_logical_operator): Likewise.
6977 (find_array_ref_with_const_idx_r): Likewise.
6978 (warn_tautological_cmp): Likewise.
6979 (expr_has_boolean_operands_p): Likewise.
6980 (warn_logical_not_parentheses): Likewise.
6981 (warn_if_unused_value): Likewise.
6982 (strict_aliasing_warning): Likewise.
6983 (sizeof_pointer_memaccess_warning): Likewise.
6984 (check_main_parameter_types): Likewise.
6985 (conversion_warning): Likewise.
6986 (warnings_for_convert_and_check): Likewise.
6987 (match_case_to_enum_1): Likewise.
6988 (match_case_to_enum): Likewise.
6989 (c_do_switch_warnings): Likewise.
6990 (warn_for_omitted_condop): Likewise.
6991 (readonly_error): Likewise.
6992 (lvalue_error): Likewise.
6993 (invalid_indirection_error): Likewise.
6994 (warn_array_subscript_with_type_char): Likewise.
6995 (warn_about_parentheses): Likewise.
6996 (warn_for_unused_label): Likewise.
6997 (warn_for_div_by_zero): Likewise.
6998 (warn_for_memset): Likewise.
6999 (warn_for_sign_compare): Likewise.
7000 (do_warn_double_promotion): Likewise.
7001 (do_warn_unused_parameter): Likewise.
7002 (record_locally_defined_typedef): Likewise.
7003 (maybe_record_typedef_use): Likewise.
7004 (maybe_warn_unused_local_typedefs): Likewise.
7005 (maybe_warn_bool_compare): Likewise.
7006 (maybe_warn_shift_overflow): Likewise.
7007 (warn_duplicated_cond_add_or_warn): Likewise.
7008 (diagnose_mismatched_attributes): Likewise.
7009 * c-common.h: Move the declarations from c-warn.c to its own section.
7010 * c-warn.c: New file.
7011
627be19f
JM
70122016-10-08 Jason Merrill <jason@redhat.com>
7013
7014 * c-common.c (c_common_truthvalue_conversion): Don't distribute
7015 into COND_EXPR in C++.
7016
7bad794a
JJ
70172016-10-08 Jakub Jelinek <jakub@redhat.com>
7018
7019 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
7020 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
7021 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
7022
be845b04
JJ
70232016-10-07 Jakub Jelinek <jakub@redhat.com>
7024
7025 Implement LWG2296 helper intrinsic
7026 * c-common.h (enum rid): Add RID_ADDRESSOF.
7027 * c-common.c (c_common_reswords): Add __builtin_addressof.
7028
c09c4992
BE
70292016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
7030
7031 PR c++/77700
7032 * c-common.c (c_common_truthvalue_conversion): Warn also for
7033 suspicious enum values in boolean context.
7034
342cfb3e
JJ
70352016-10-06 Jakub Jelinek <jakub@redhat.com>
7036
7037 Implement P0258R2 - helper for C++17
7038 std::has_unique_object_representations trait
7039 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
7040 * c-common.c (c_common_reswords): Add
7041 __has_unique_object_representations.
7042
2e69f143
JJ
70432016-10-05 Jakub Jelinek <jakub@redhat.com>
7044
7045 PR sanitizer/66343
7046 * c-ubsan.c (ubsan_instrument_return): Don't call
7047 initialize_sanitizer_builtins here.
7048
700fff34
BE
70492016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
7050
7051 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
7052 conditional expression in boolean context when only one arm is
7053 non-boolean.
7054
9563bfcd
JJ
70552016-10-05 Jakub Jelinek <jakub@redhat.com>
7056
04a32443
JJ
7057 PR sanitizer/77823
7058 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
7059 is not integral.
7060
9563bfcd
JJ
7061 * c-common.c (c_common_reswords): Update comment for C++11.
7062
f1644724
JM
70632016-10-04 Jason Merrill <jason@redhat.com>
7064
7065 * c-common.c (make_tree_vector_from_ctor): New.
7066 * c-common.h: Declare it.
7067
5a79befb
JJ
70682016-10-04 Jakub Jelinek <jakub@redhat.com>
7069
7070 * c-cppbuiltin.c (c_cpp_builtins): Don't define
7071 __LIBGCC_JCR_SECTION_NAME__.
7072
1633d3b9
BE
70732016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
7074
7075 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
7076 left shift in boolean context.
7077
a2c6e7f2
JJ
70782016-09-29 Jakub Jelinek <jakub@redhat.com>
7079
7080 Implement P0001R1 - C++17 removal of register storage class specifier
7081 * c.opt (Wregister): New warning.
7082 * c-opts.c (c_common_post_options): Enable -Wregister by
7083 default for C++17.
7084
75304c87
JG
70852016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
7086
7087 * c-opts.c (c_common_post_options): Remove special case for
7088 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
7089 in C++.
7090
bbfac6da
JJ
70912016-09-27 Jakub Jelinek <jakub@redhat.com>
7092
6e39060a
JJ
7093 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
7094 -std=c++1z.
7095
bbfac6da
JJ
7096 * c-ada-spec.c (print_ada_declaration): Remove break after return.
7097
e73cf9a2
TP
70982016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
7099
7100 * c-common.c: Include memmodel.h.
7101
c6147dc4
MP
71022016-09-26 Marek Polacek <polacek@redhat.com>
7103
7104 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
7105
81fea426
MP
71062016-09-26 Marek Polacek <polacek@redhat.com>
7107
7108 PR c/7652
7109 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
7110 (handle_fallthrough_attribute): New function.
7111 (attribute_fallthrough_p): New function.
7112 * c-common.h (attribute_fallthrough_p): Declare.
7113
9a2300e9
MP
71142016-09-24 Marek Polacek <polacek@redhat.com>
7115
7116 PR c/77490
7117 * c.opt (Wbool-operation): New.
7118
a09e9e35
BE
71192016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
7120
7121 * c-common.c (c_common_truthvalue_conversion): Inhibit
7122 Wint-in-bool-context warning with from_macro_definition_at.
7123 Mention the expression will always evaluate to true.
7124
d43b4ccc
MS
71252016-09-21 Martin Sebor <msebor@redhat.com>
7126
7127 PR bootstrap/77676
7128 * c.opt (fprintf-return-value): Temporarily initialize to zero
7129 to unblock bootstrap failures.
7130
2e1c20b1
JJ
71312016-09-21 Jakub Jelinek <jakub@redhat.com>
7132
7133 PR c++/77651
7134 * c.opt (Waligned-new=): Add RejectNegative.
7135 (faligned-new=): Likewise. Spelling fix - change
7136 aligned_new_threshhold to aligned_new_threshold.
7137 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
7138 to aligned_new_threshold.
7139
88d0c3f0
MS
71402016-09-20 Martin Sebor <msebor@redhat.com>
7141
7142 PR middle-end/49905
7143 * c.opt: Add -Wformat-length and -fprintf-return-value.
7144
144a96e4
BE
71452016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
7146
7147 PR c++/77434
7148 * c.opt (Wint-in-bool-context): New warning.
7149 * c-common.c (c_common_truthvalue_conversion): Warn on integer
7150 constants in boolean context.
7151
63012d9a
JM
71522016-09-19 Joseph Myers <joseph@codesourcery.com>
7153
7154 * c-common.c (max_align_t_align): Also consider alignment of
7155 float128_type_node.
7156
931388ce
JM
71572016-09-15 Jason Merrill <jason@redhat.com>
7158
7159 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
7160 DECL_EXTERNAL.
7161
38711381
JM
71622016-09-14 Jason Merrill <jason@redhat.com>
7163
7164 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
7165 limit FIELD_DECL, either.
7166
e51fbec3
MP
71672016-09-14 Marek Polacek <polacek@redhat.com>
7168
7169 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
7170 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
7171 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
7172
254830ba
DM
71732016-09-13 David Malcolm <dmalcolm@redhat.com>
7174
7175 * c-common.c (warn_logical_not_parentheses): Replace
7176 rich_location::add_fixit_insert calls with add_fixit_insert_before
7177 and add_fixit_insert_after, eliminating the "next_loc" calculation.
7178
42763690
JM
71792016-09-13 Jason Merrill <jason@redhat.com>
7180 Tom de Vries <tom@codesourcery.com>
7181
7182 PR c++/77427
7183 * c-common.c (set_underlying_type): Don't treat array as builtin type.
7184
9453eee9
JM
71852016-09-13 Jason Merrill <jason@redhat.com>
7186
7187 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
7188 limit types at all.
7189
e96809e3
JM
71902016-09-12 Jason Merrill <jason@redhat.com>
7191
7192 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
7193 bit/byte confusion, allow large alignment for types.
7194
54dcdb88
BE
71952016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
7196
7197 PR c++/77496
7198 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
7199
d1463eb9
DM
72002016-09-12 David Malcolm <dmalcolm@redhat.com>
7201
7202 PR c/72858
7203 * c-format.c (argument_parser::check_argument_type): Add params
7204 "type_start" and "conversion_char". Use the former to generate
7205 offset_to_type_start and pass it and conversion_char to
7206 check_format_types.
7207 (check_format_info_main): Capture the start of the type
7208 information as "type_start", and pass it an format_char
7209 to arg_parser.check_argument_type.
7210 (check_format_types): Provide an example in the leading comment.
7211 Add params "offset_to_type_start" and "conversion_char"; pass
7212 them to format_type_warning calls.
7213 (test_get_modifier_for_format_len): Likewise.
7214 (matching_type_p): New function.
7215 (get_format_for_type): Add param "conversion_char" and move
7216 implementation into...
7217 (get_format_for_type_1): ...new function, called twice.
7218 Use new function matching_type_p rather than checking for
7219 TYPE_CANONICAL equality.
7220 (get_corrected_substring): New function.
7221 (format_type_warning): Provide an example in the leading comment.
7222 Add params "offset_to_type_start" and "conversion_char". Replace
7223 call to get_format_for_type with call to get_corrected_substring
7224 and move rejection of hints for widths/precisions there.
7225 (assert_format_for_type_streq): Add param "conversion_char".
7226 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
7227 (test_get_format_for_type_printf): Add conversion chars to the
7228 tests, adding coverage for various combinations of integer
7229 vs double conversions, and for preserving octal and hexadecimal
7230 conversions.
7231 (test_get_format_for_type_scanf): Add conversion chars to the
7232 tests.
7233
5b28efbb
TV
72342016-09-10 Tom de Vries <tom@codesourcery.com>
7235
7236 PR C/71602
7237 * c-common.c (build_va_arg): Handle more strict
7238 targetm.canonical_va_list_type. Replace first argument type error with
7239 assert.
7240
3f0177e7
MS
72412016-09-09 Martin Sebor <msebor@redhat.com>
7242
7243 PR c/77520
7244 PR c/77521
7245 * c-format.c (argument_parser::find_format_char_info): Use %qc
7246 format directive unconditionally.
7247
af63ba4b
JM
72482016-09-09 Jason Merrill <jason@redhat.com>
7249
7250 Implement C++17 new of over-aligned types.
7251 * c.opt: Add -faligned-new and -Waligned-new.
7252 * c-common.c (max_align_t_align): Split out from...
7253 (cxx_fundamental_alignment_p): ...here.
7254 * c-common.h: Declare it.
7255 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
7256
c65248cb
JM
72572016-09-09 Joseph Myers <joseph@codesourcery.com>
7258
7259 * c-cppbuiltin.c (builtin_define_type_width): New function.
7260 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
7261 macros.
7262
e5106e27
DM
72632016-09-07 David Malcolm <dmalcolm@redhat.com>
7264
7265 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
7266 a POINTER_TYPE.
7267 (substring_loc::get_location): Move to substring-locations.c,
7268 keeping implementation as...
7269 (c_get_substring_location): New function, from the above, reworked
7270 to use accessors rather than member lookup.
7271 * c-common.h (class substring_loc): Move to substring-locations.h,
7272 replacing with a forward decl.
7273 (c_get_substring_location): New decl.
7274 * c-format.c: Include "substring-locations.h".
7275 (format_warning_va): Move to substring-locations.c.
7276 (format_warning_at_substring): Likewise.
7277
ab20d992 72782016-09-06 Martin Sebor <msebor@redhat.com>
a42e7952
MS
7279
7280 PR c/77336
7281 * c-format.c (check_function_format): Avoid issuing warnings for
7282 functions unless they call format functions with non-constant
7283 format strings.
7284
b772a565
RB
72852016-09-06 Richard Biener <rguenther@suse.de>
7286
7287 PR c/77450
7288 * c-common.c (c_common_mark_addressable_vec): Handle
7289 COMPOUND_LITERAL_EXPR.
7290
25ff5dd3
MP
72912016-09-05 Marek Polacek <polacek@redhat.com>
7292
7293 PR c/77423
7294 * c-common.c (bool_promoted_to_int_p): New function.
7295 (expr_has_boolean_operands_p): New function.
7296 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
7297 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
7298
21234eb5
TV
72992016-09-04 Tom de Vries <tom@codesourcery.com>
7300
7301 revert:
7302 2016-08-29 Tom de Vries <tom@codesourcery.com>
7303
7304 * c-common.c (build_va_arg): Replace first argument type error
7305 with assert.
7306
9dc5773f
JJ
73072016-09-02 Jakub Jelinek <jakub@redhat.com>
7308
7309 PR c/65467
7310 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
7311 (c_finish_omp_for): Reject _Atomic qualified iterators.
7312
73132016-09-01 Martin Sebor <msebor@redhat.com>
3d7b83b6
MS
7314
7315 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
7316 size to guarantee it fits the output of the formatted function
7317 regardless of its arguments.
7318
295844f6
MP
73192016-09-01 Marek Polacek <polacek@redhat.com>
7320
7321 PR c/7652
7322 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
7323 FALLTHRU comments.
7324
3d06b6f2
MP
73252016-08-29 Marek Polacek <polacek@redhat.com>
7326
7327 PR c/77292
7328 * c-common.c (warn_logical_not_parentheses): Don't warn for
7329 a comparison or a logical operator.
7330
34cedad5
TV
73312016-08-29 Tom de Vries <tom@codesourcery.com>
7332
7333 * c-common.c (build_va_arg): Fix type comparison assert.
7334
f162d717
TV
73352016-08-29 Tom de Vries <tom@codesourcery.com>
7336
7337 * c-common.c (build_va_arg): Replace first argument type error
7338 with assert.
7339
ba9bbd6f
TV
73402016-08-29 Tom de Vries <tom@codesourcery.com>
7341
7342 PR c/77398
7343 * c-common.c (build_va_arg): Add first argument error. Build va_arg
7344 with error_mark_node as va_list instead of with illegal va_list.
7345
ebef225f
MP
73462016-08-25 Marek Polacek <polacek@redhat.com>
7347 David Malcolm <dmalcolm@redhat.com>
7348
7349 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
7350 * c-common.h (warn_logical_not_parentheses): Update declaration.
7351
b00e6e75
MP
73522016-08-22 Marek Polacek <polacek@redhat.com>
7353
7354 PR c++/77321
7355 * c-common.c (warn_for_memset): Check type for null.
7356
6dc198e3
JM
73572016-08-22 Joseph Myers <joseph@codesourcery.com>
7358
14ec014e 7359 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
6dc198e3
JM
7360 _FloatNx types for suffixes for built-in functions.
7361
c65699ef
JM
73622016-08-19 Joseph Myers <joseph@codesourcery.com>
7363
7364 PR c/32187
7365 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
7366 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
7367 (RID_FLOAT128X): New enum rid values.
7368 (CASE_RID_FLOATN_NX): New macro.
7369 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
7370 keywords.
7371 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
7372 corresponding complex types.
7373 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
7374 _FloatNx and corresponding complex types.
7375 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
7376 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
7377 and _FloatNx types for the widest type for determining
7378 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
7379 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
7380 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
7381 and _FloatNx types.
7382 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
7383 constants.
7384 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
7385 _FloatNx types.
7386
cc015f3a
DM
73872016-08-18 David Malcolm <dmalcolm@redhat.com>
7388
7389 * c-opts.c (c_diagnostic_finalizer): Update for change to
7390 diagnostic_show_locus.
7391
cb18fd07
DM
73922016-08-18 David Malcolm <dmalcolm@redhat.com>
7393
7394 * c-common.c: Include "spellcheck.h".
7395 (cb_get_suggestion): New function.
7396 * c-common.h (cb_get_suggestion): New decl.
7397 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
7398 cb_get_suggestion.
7399
a76989dc
MP
74002016-08-18 Marek Polacek <polacek@redhat.com>
7401
7402 PR c/71514
7403 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
7404 and pointer-to-VLA.
7405
65e736c0
DM
74062016-08-16 David Malcolm <dmalcolm@redhat.com>
7407
7408 PR c/72857
7409 * c-common.c (substring_loc::get_range): Rename to...
7410 (substring_loc::get_location): ...this, converting param from a
7411 source_range * to a location_t *. Call
7412 get_source_location_for_substring rather than
7413 get_source_range_for_substring, and pass in m_caret_idx.
7414 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
7415 (substring_loc::get_range): Replace with...
7416 (substring_loc::get_location): ...this.
7417 (substring_loc::set_caret_index): New method.
7418 (substring_loc): Add field m_caret_idx.
7419 * c-format.c (format_warning_va): Update for above changes.
7420 Rename local "substring_loc" to "fmt_substring_loc" to avoid
7421 clashing with type name.
7422 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
7423 (check_argument_type): Likewise.
7424 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
7425 Use a copy when emitting warnings, setting the caret index from TYPE.
7426
7e1dde14 74272016-08-16 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 7428 Arnaud Charlet <charlet@adacore.com>
7e1dde14
EB
7429
7430 * c-ada-spec.c (dump_number): New function.
7431 (handle_escape_character): Likewise.
7432 (print_ada_macros): Add handling of constant integers and strings.
7433
191816a3
MP
74342016-08-12 Marek Polacek <polacek@redhat.com>
7435
7436 PR c/7652
7437 * c-common.c (scalar_to_vector): Adjust fall through comment.
7438 * c-opts.c (c_common_handle_option): Likewise.
7439 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
7440 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
7441 fall through comment.
7442 * cilk.c (extract_free_variables): Add FALLTHRU.
7443
452df4a4
JM
74442016-08-10 Jason Merrill <jason@redhat.com>
7445
7446 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
7447
f3365c12
JM
74482016-08-09 Jason Merrill <jason@redhat.com>
7449
7450 * c-common.c (c_common_attribute_table): vector_size affects type
7451 identity.
7452
f0bc3323
MP
74532016-08-09 Marek Polacek <polacek@redhat.com>
7454
7455 PR c/7652
7456 * c-ada-spec.c (dump_generic_ada_node): Add return.
7457
98e5a19a
JM
74582016-08-09 Jason Merrill <jason@redhat.com>
7459
7460 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
7461 C++17 constexpr lambdas.
7462
895aa8e1
DM
74632016-08-08 David Malcolm <dmalcolm@redhat.com>
7464
7465 PR c/64955
7466 * c-common.h (selftest::c_format_c_tests): New declaration.
7467 (selftest::run_c_tests): New declaration.
7468 * c-format.c: Include "selftest.h.
7469 (format_warning_va): Add param "corrected_substring" and use
7470 it to add a replacement fix-it hint.
7471 (format_warning_at_substring): Likewise.
7472 (format_warning_at_char): Update for new param of
7473 format_warning_va.
7474 (argument_parser::check_argument_type): Pass "fki" to
7475 check_format_types.
7476 (check_format_types): Add param "fki" and pass it to
7477 format_type_warning.
7478 (deref_n_times): New function.
7479 (get_modifier_for_format_len): New function.
7480 (selftest::test_get_modifier_for_format_len): New function.
7481 (get_format_for_type): New function.
7482 (format_type_warning): Add param "fki" and use it to attempt
7483 to provide hints for argument types when calling
7484 format_warning_at_substring.
7485 (selftest::get_info): New function.
7486 (selftest::assert_format_for_type_streq): New function.
7487 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
7488 (selftest::test_get_format_for_type_printf): New function.
7489 (selftest::test_get_format_for_type_scanf): New function.
7490 (selftest::c_format_c_tests): New function.
7491
e52ed3fe
DM
74922016-08-08 David Malcolm <dmalcolm@redhat.com>
7493
7494 PR c/52952
7495 * c-format.c: Include "diagnostic.h".
7496 (location_column_from_byte_offset): Delete.
7497 (location_from_offset): Delete.
7498 (format_warning_va): New function.
7499 (format_warning_at_substring): New function.
7500 (format_warning_at_char): New function.
7501 (check_format_arg): Capture location of format_tree and pass to
7502 check_format_info_main.
7503 (argument_parser): Add fields "start_of_this_format" and
7504 "format_string_cst".
7505 (flag_chars_t::validate): Add param "format_string_cst". Convert
7506 warning_at call using location_from_offset to call to
7507 format_warning_at_char.
7508 (argument_parser::argument_parser): Add param "format_string_cst_"
7509 and use use it to initialize field "format_string_cst".
7510 Initialize new field "start_of_this_format".
7511 (argument_parser::read_format_flags): Convert warning_at call
7512 using location_from_offset to a call to format_warning_at_char.
7513 (argument_parser::read_any_format_left_precision): Likewise.
7514 (argument_parser::read_any_format_precision): Likewise.
7515 (argument_parser::read_any_other_modifier): Likewise.
7516 (argument_parser::find_format_char_info): Likewise, in three places.
7517 (argument_parser::parse_any_scan_set): Likewise, in one place.
7518 (argument_parser::handle_conversions): Likewise, in two places.
7519 (argument_parser::check_argument_type): Add param "fmt_param_loc"
7520 and use it to make a substring_loc. Pass the latter to
7521 check_format_types.
7522 (check_format_info_main): Add params "fmt_param_loc" and
7523 "format_string_cst". Convert warning_at calls using
7524 location_from_offset to calls to format_warning_at_char. Pass the
7525 new params to the arg_parser ctor. Pass "format_string_cst" to
7526 flag_chars.validate. Pass "fmt_param_loc" to
7527 arg_parser.check_argument_type.
7528 (check_format_types): Convert first param from a location_t
7529 to a const substring_loc & and rename to "fmt_loc". Attempt
7530 to extract the range of the relevant parameter and pass it
7531 to format_type_warning.
7532 (format_type_warning): Convert first param from a location_t
7533 to a const substring_loc & and rename to "fmt_loc". Add
7534 params "param_range" and "type". Replace calls to warning_at
7535 with calls to format_warning_at_substring.
7536
1c4d457e
DM
75372016-08-08 David Malcolm <dmalcolm@redhat.com>
7538
7539 * c-format.c (class flag_chars_t): New class.
7540 (struct length_modifier): New struct.
7541 (class argument_parser): New class.
7542 (flag_chars_t::flag_chars_t): New ctor.
7543 (flag_chars_t::has_char_p): New method.
7544 (flag_chars_t::add_char): New method.
7545 (flag_chars_t::validate): New method.
7546 (flag_chars_t::get_alloc_flag): New method.
7547 (flag_chars_t::assignment_suppression_p): New method.
7548 (argument_parser::argument_parser): New ctor.
7549 (argument_parser::read_any_dollar): New method.
7550 (argument_parser::read_format_flags): New method.
7551 (argument_parser::read_any_format_width): New method.
7552 (argument_parser::read_any_format_left_precision): New method.
7553 (argument_parser::read_any_format_precision): New method.
7554 (argument_parser::handle_alloc_chars): New method.
7555 (argument_parser::read_any_length_modifier): New method.
7556 (argument_parser::read_any_other_modifier): New method.
7557 (argument_parser::find_format_char_info): New method.
7558 (argument_parser::validate_flag_pairs): New method.
7559 (argument_parser::give_y2k_warnings): New method.
7560 (argument_parser::parse_any_scan_set): New method.
7561 (argument_parser::handle_conversions): New method.
7562 (argument_parser::check_argument_type): New method.
7563 (check_format_info_main): Introduce classes argument_parser
7564 and flag_chars_t, moving the code within the loop into methods
7565 of these classes. Make various locals "const".
7566
88fa5555
DM
75672016-08-05 David Malcolm <dmalcolm@redhat.com>
7568
7569 * c-common.c: Include "substring-locations.h".
7570 (get_cpp_ttype_from_string_type): New function.
7571 (g_string_concat_db): New global.
7572 (substring_loc::get_range): New method.
7573 * c-common.h (g_string_concat_db): New declaration.
7574 (class substring_loc): New class.
7575 * c-lex.c (lex_string): When concatenating strings, capture the
7576 locations of all tokens using a new obstack, and record the
7577 concatenation locations within g_string_concat_db.
7578 * c-opts.c (c_common_init_options): Construct g_string_concat_db
7579 on the ggc-heap.
7580
78169471
MP
75812016-07-29 Marek Polacek <polacek@redhat.com>
7582
638fc14f
MP
7583 PR c/71926
7584 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
7585 parentheses warning.
7586
78169471
MP
7587 PR c/71574
7588 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
7589
1225d6b1
ML
75902016-07-28 Martin Liska <mliska@suse.cz>
7591
7592 PR gcov-profile/68025
7593 * c-common.c (handle_no_profile_instrument_function_attribute):
7594
ec1e2a40
BE
75952016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
7596
7597 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
7598 BITS_PER_UNIT_LOG.
7599
5ec2cd9f
JM
76002016-07-25 Jason Merrill <jason@redhat.com>
7601
7602 PR c++/65970
7603 * c.opt (fconstexpr-loop-limit): New.
7604
9dc5773f 76052016-07-22 Martin Sebor <msebor@redhat.com>
2e6b45af
MS
7606
7607 PR c++/71675
7608 * c-common.c (resolve_overloaded_builtin): Avoid converting
7609 __atomic_compare_exchange_n return type to that of what its
7610 first argument points to.
7611
e3fe09c1
UB
76122016-07-22 Uros Bizjak <ubizjak@gmail.com>
7613
7614 * c-common.c: Use HOST_WIDE_INT_M1U instead of
7615 ~(unsigned HOST_WIDE_INT) 0.
7616
bc91c436
ML
76172016-07-22 Martin Liska <mliska@suse.cz>
7618
7619 PR gcov-profile/69028
7620 PR gcov-profile/62047
7621 * cilk.c (create_cilk_helper_decl): Set location of a new decl
7622 to the current_function_decl.
7623
451dcc66
JM
76242016-07-21 Jason Merrill <jason@redhat.com>
7625
7626 PR c++/65168
7627 * c-common.c (c_common_truthvalue_conversion): Check
7628 c_inhibit_evaluation_warnings for warning about address of
7629 reference.
7630
de6a69ee
DM
76312016-07-20 David Malcolm <dmalcolm@redhat.com>
7632
7633 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
7634 const char *.
7635
d022c55a
JM
76362016-07-15 Jason Merrill <jason@redhat.com>
7637
7638 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
7639
ddbbcb19
JJ
76402016-07-15 Jakub Jelinek <jakub@redhat.com>
7641
7642 PR c/71858
7643 * c-common.h (enum lookup_name_fuzzy_kind): Add
7644 FUZZY_LOOKUP_FUNCTION_NAME.
7645
d0cf395a
JM
76462016-07-08 Jason Merrill <jason@redhat.com>
7647
7648 P0145: Refining Expression Order for C++.
7649 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
7650 * c-opts.c: Adjust.
7651
98d44e93
MT
76522016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
7653
7654 PR c++/71214
7655 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
7656
f9d8d994
TS
76572016-06-29 Thomas Schwinge <thomas@codesourcery.com>
7658
7659 * c-pragma.h (enum pragma_kind): Rename
7660 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
7661 users.
7662
4aa83879
RB
76632016-06-29 Richard Biener <rguenther@suse.de>
7664
7665 PR middle-end/71002
7666 * c-common.c (c_common_get_alias_set): Remove union type punning case.
7667
a25bd9e6
JM
76682016-06-24 Jason Merrill <jason@redhat.com>
7669
7670 P0145R2: Refining Expression Order for C++.
7671 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
7672 MODIFY_EXPR.
7673
a86451b9
JJ
76742016-06-24 Jakub Jelinek <jakub@redhat.com>
7675
7676 * c-common.c (check_builtin_function_arguments): Require last
7677 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
7678 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
7679 if the last argument is pointer to enumerated or boolean type.
7680
1a4f11c8
DM
76812016-06-22 David Malcolm <dmalcolm@redhat.com>
7682
7683 PR c/70339
7684 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
7685 (lookup_name_fuzzy): New prototype.
7686
fe55692c
JDA
76872016-06-21 John David Anglin <danglin@gcc.gnu.org>
7688
7689 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
7690
4eb24e01
JM
76912016-06-14 Jason Merrill <jason@redhat.com>
7692
7693 P0145R2: Refining Expression Order for C++.
7694 * c.opt (fargs-in-order): New.
7695 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
7696
ef7cf206
JJ
76972016-06-13 Jakub Jelinek <jakub@redhat.com>
7698
0dda258b
JJ
7699 PR sanitizer/71498
7700 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
7701 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
7702
ef7cf206
JJ
7703 PR preprocessor/71183
7704 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
7705 to cb_get_source_date_epoch.
7706
50b15873
JJ
77072016-06-10 Jakub Jelinek <jakub@redhat.com>
7708
7709 PR c/68657
7710 * c.opt (Wpsabi): Add Warning flag.
7711
4d926e34
MS
77122016-06-10 Martin Sebor <msebor@redhat.com>
7713
7714 PR c/71392
14ec014e 7715 * c-common.c (handle_nonnull_attribute): Accept
4d926e34
MS
7716 the nonnull attribute in type-generic builtins.
7717
e01b4e16
MS
77182016-06-09 Martin Sebor <msebor@redhat.com>
7719
7720 PR c/70883
7721 * c-common.c (builtin_function_validate_nargs): Make text of error
7722 message consistent with others like it.
7723
44a845ca
MS
77242016-06-08 Martin Sebor <msebor@redhat.com>
7725 Jakub Jelinek <jakub@redhat.com>
7726
7727 PR c++/70507
7728 PR c/68120
7729 * c-common.c (check_builtin_function_arguments): Handle
7730 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
7731
a80a7051
RB
77322016-06-08 Richard Biener <rguenther@suse.de>
7733
7734 * c-common.c (parse_optimize_options): Improve diagnostic messages.
7735
bfd67b47
RB
77362016-06-07 Richard Biener <rguenther@suse.de>
7737
7738 PR c/61564
7739 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
7740 options and warn about others.
7741
15c98b2e
ES
77422016-06-01 Eduard Sanou <dhole@openmailbox.org>
7743
7744 * c-common.c (get_source_date_epoch): Rename to
7745 cb_get_source_date_epoch.
7746 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
7747 message when the parsing fails. Use error_at instead of fatal_error.
7748 * c-common.h (get_source_date_epoch): Rename to
7749 cb_get_source_date_epoch.
7750 * c-common.h (cb_get_source_date_epoch): Prototype.
7751 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
7752 * c-common.h (c_omp_region_type): Remove trailing comma.
7753 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
7754 * c-lex.c (c_lex_with_flags): Remove initialization of
7755 pfile->source_date_epoch.
7756
00631022
JJ
77572016-05-30 Jakub Jelinek <jakub@redhat.com>
7758
7759 PR c++/71349
7760 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
7761 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
7762 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
7763 instead of C_OMP_CLAUSE_SPLIT_FOR.
7764
f17a223d
RB
77652016-05-24 Richard Biener <rguenther@suse.de>
7766
7767 PR middle-end/70434
7768 PR c/69504
7769 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
7770 (convert_vector_to_array_for_subscript): ... this.
7771 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
7772 VIEW_CONVERT_EXPR to an array type. Rename to ...
7773 (convert_vector_to_array_for_subscript): ... this.
7774
4f2e1536
MP
77752016-05-12 Marek Polacek <polacek@redhat.com>
7776
7777 PR c/70756
7778 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
7779 size_in_bytes and pass LOC to it.
7780
d6e83a8d
MM
77812016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
7782
7783 PR c/43651
7784 * c.opt (Wduplicate-decl-specifier): New option.
7785
5c3a10fb
MP
77862016-05-11 Marek Polacek <polacek@redhat.com>
7787
7788 PR c++/71024
7789 * c-common.c (diagnose_mismatched_attributes): New function.
7790 * c-common.h (diagnose_mismatched_attributes): Declare.
7791
deef7113
MP
77922016-05-04 Marek Polacek <polacek@redhat.com>
7793
7794 * c.opt (Wdangling-else): New option.
7795
79ce98bc
MP
77962016-05-03 Marek Polacek <polacek@redhat.com>
7797
7798 PR c/70859
7799 * c-common.c (builtin_function_validate_nargs): Add location
7800 parameter. Use it.
7801 (check_builtin_function_arguments): Add location and arguments
7802 parameters. Use them.
7803 * c-common.h (check_builtin_function_arguments): Update declaration.
7804
381cdae4
RB
78052016-05-03 Richard Biener <rguenther@suse.de>
7806
7807 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
7808 allow call args to gimplify to SSA names.
7809
1d793c34
MP
78102016-05-03 Marek Polacek <polacek@redhat.com>
7811
7812 * c-common.h (enum c_omp_region_type): Remove stray comma.
7813
77886428
CP
78142016-05-02 Cesar Philippidis <cesar@codesourcery.com>
7815
7816 * c-common.h (enum c_omp_region_type): Define.
7817
697e0b28
RS
78182016-05-02 Richard Sandiford <richard.sandiford@arm.com>
7819
7820 * c-common.c (shorten_compare): Use wi::to_wide.
7821
e7ff0319
CP
78222016-04-29 Cesar Philippidis <cesar@codesourcery.com>
7823
7824 PR middle-end/70626
7825 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
7826 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
7827 reduction clauses in acc parallel loops.
7828
2fff3db8
MP
78292016-04-29 Marek Polacek <polacek@redhat.com>
7830
7831 PR c/70852
7832 * c-common.c (warn_for_memset): Check domain before accessing it.
7833
509063eb
DV
78342016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
7835
7836 PR/69089
7837 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
7838 "aligned" attribute.
7839
b632761d
JM
78402016-04-28 Jason Merrill <jason@redhat.com>
7841
7842 * c-lex.c (c_common_has_attribute): Handle nodiscard.
7843
174f6622
ES
78442016-04-28 Eduard Sanou <dhole@openmailbox.org>
7845 Matthias Klose <doko@debian.org>
7846
7847 * c-common.c (get_source_date_epoch): New function, gets the environment
7365279f 7848 variable SOURCE_DATE_EPOCH and parses it as long long with error
174f6622
ES
7849 handling.
7850 * c-common.h (get_source_date_epoch): Prototype.
7851 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
7852
6bc2bb18
RB
78532015-04-27 Ryan Burn <contact@rnburn.com>
7854
7855 PR c++/69024
7856 PR c++/68997
7857 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
7858 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
7859 external linkage.
7860 (cilk_detect_and_unwrap): Corresponding changes.
7861 (extract_free_variables): Don't extract free variables from
7862 AGGR_INIT_EXPR slot.
7863 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
7864 (cilk_recognize_spawn): Likewise.
7865
c1e1f433
BS
78662016-04-27 Bernd Schmidt <bschmidt@redhat.com>
7867
7868 * c.opt (Wmemset-elt-size): New option.
7869 * c-common.c (warn_for_memset): New function.
7870 * c-common.h (warn_for_memset): Declare.
7871
d067e05f
JM
78722016-04-25 Jason Merrill <jason@redhat.com>
7873
7874 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
7875 No longer static.
7876 * c-common.h: Declare it.
7877 * c-lex.c (c_common_has_attribute): Add maybe_unused.
7878
9aa36ae5
JM
78792016-04-22 Jason Merrill <jason@redhat.com>
7880
7881 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
7882
477d4906
IV
78832016-04-20 Ilya Verbin <ilya.verbin@intel.com>
7884
7885 PR c++/69363
7886 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
7887 * c-common.h (c_finish_cilk_clauses): Remove declaration.
7888
fe37c7af
MM
78892016-04-18 Michael Matz <matz@suse.de>
7890
7891 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
7892 and SET_DECL_ALIGN.
7893
23f2660f
EB
78942016-04-17 Eric Botcazou <ebotcazou@adacore.com>
7895
7896 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
7897 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
7898 to incomplete types.
7899 (dump_nested_type): Remove redundant tests and tidy up.
7900 (print_ada_declaration): Also set TREE_VISITED on the declaration of
7901 a type which is the typedef of an original type.
7902
1e77281b
MP
79032016-04-15 Marek Polacek <polacek@redhat.com>
7904
7905 PR c/70651
7906 * c-common.c (build_va_arg): Change two asserts into errors and return
7907 error_mark_node.
7908
b3a77f21
MP
79092016-04-13 Marek Polacek <polacek@redhat.com>
7910
7911 PR c++/70639
7912 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
7913 for switch statements, too.
7914
322b8466
JM
79152016-03-28 Jason Merrill <jason@redhat.com>
7916
7917 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
7918
fbdb6baf
MP
79192016-03-23 Marek Polacek <polacek@redhat.com>
7920
7921 PR c++/69884
7922 * c.opt (Wignored-attributes): New option.
7923
5c240f4d
DM
79242016-03-22 David Malcolm <dmalcolm@redhat.com>
7925
7926 PR c/69993
7927 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
7928 diagnostic text, reversing the order of the warning and note so
7929 that they appear in source order.
7930
14ba7b28
MP
79312016-03-17 Marek Polacek <polacek@redhat.com>
7932
7933 PR c/69407
7934 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
7935 operations.
7936
08a1cadc
JM
79372016-03-14 Jason Merrill <jason@redhat.com>
7938
2aaeea19
JM
7939 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
7940
08a1cadc
JM
7941 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
7942
c06d25bb
RB
79432016-03-09 Richard Biener <rguenther@suse.de>
7944
7945 PR c/70143
7946 * c-common.c (strict_aliasing_warning): Add back
7947 alias_sets_conflict_p check.
7948
80aac5c8
JM
79492016-03-08 Jason Merrill <jason@redhat.com>
7950
7951 * c-opts.c (set_std_cxx1z): Don't enable concepts.
7952
64b23c13
DM
79532016-03-04 David Malcolm <dmalcolm@redhat.com>
7954
7955 PR c/68187
7956 * c-indentation.c (get_visual_column): Move code to determine next
7957 tab stop to...
7958 (next_tab_stop): ...this new function.
7959 (line_contains_hash_if): Delete function.
7960 (detect_preprocessor_logic): Delete function.
7961 (get_first_nws_vis_column): New function.
7962 (detect_intervening_unindent): New function.
7963 (should_warn_for_misleading_indentation): Replace call to
7964 detect_preprocessor_logic with a call to
7965 detect_intervening_unindent.
7966
729526f5
DM
79672016-03-04 David Malcolm <dmalcolm@redhat.com>
7968
7969 PR c/68187
7970 * c-indentation.c (should_warn_for_misleading_indentation): When
7971 suppressing warnings about cases where the guard and body are on
7972 the same column, only use the first non-whitespace column in place
7973 of the guard token column when dealing with "else" clauses.
7974 When rejecting aligned BODY and NEXT, loosen the requirement
7975 from equality with the first non-whitespace of guard to simply
7976 that they not be indented relative to it.
7977
e9a35493
RB
79782016-03-04 Richard Biener <rguenther@suse.de>
7979
7980 PR c++/70054
7981 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
7982 instead of alias_sets_conflict_p.
7983
1be56bc5
MP
79842016-03-01 Marek Polacek <polacek@redhat.com>
7985
7986 PR c++/69795
7987 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
7988 any DECL.
7989
35886f0b
MS
79902016-02-22 Martin Sebor <msebor@redhat.com>
7991
7992 PR middle-end/69780
7993 * c-common.c (check_builtin_function_arguments): Validate and
7994 reject invalid arguments to __builtin_alloca_with_align.
7995
4246c8da
MW
79962016-02-20 Mark Wielaard <mjw@redhat.com>
7997
7998 PR c/28901
7999 * c.opt (Wunused-const-variable): Turn into Alias for...
8000 (Wunused-const-variable=): New option.
8001
268be88c
BE
80022016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
8003
8004 PR c++/69865
8005 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
8006 here...
8007 (c_common_init_options): ...to here.
8008 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
8009
871b3f47
JJ
80102016-02-19 Jakub Jelinek <jakub@redhat.com>
8011
8012 PR c++/69826
8013 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
8014 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
8015 flag_preprocess_only.
8016
bf14eba2
JJ
80172016-02-16 Jakub Jelinek <jakub@redhat.com>
8018
8019 PR c/69835
8020 * c.opt (Wnonnull-compare): Enable for -Wall.
8021
ba6b3795
JJ
80222016-02-15 Jakub Jelinek <jakub@redhat.com>
8023
8024 PR c++/69797
8025 * c-common.c (sync_resolve_size): Diagnose too few arguments
8026 even when params is non-NULL empty vector.
8027
a011cd92
BS
80282016-02-08 Bernd Schmidt <bschmidt@redhat.com>
8029
8030 PR target/60410
8031 * c.opt (fshort-double): Remove.
8032
46cb9332
MS
80332016-02-05 Martin Sebor <msebor@redhat.com>
8034
8035 PR c++/69662
8036 * c.opt (Warning options): Update -Wplacement-new to take
8037 an optional argument.
8038
e1b81f2b
JJ
80392016-02-01 Jakub Jelinek <jakub@redhat.com>
8040
8041 PR preprocessor/69543
8042 PR c/69558
8043 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
8044 instead of loc to control_warning_option.
8045
b6adbb9f
NS
80462016-02-01 Nathan Sidwell <nathan@codesourcery.com>
8047
8048 * c.opt (fopenacc-dim=): New option.
8049
5d70666e
RB
80502016-01-27 Ryan Burn <contact@rnburn.com>
8051
8052 PR cilkplus/69267
8053 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
8054 gimplify_arg. Removed superfluous post_p argument.
8055 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
8056 superfluous post_p argument.
8057 * c-gimplify.c (c_gimplify_expr): Likewise.
8058
01e1dea3
DM
80592016-01-26 David Malcolm <dmalcolm@redhat.com>
8060
8061 PR other/69006
8062 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
8063 pp_newline_and_flush with pp_flush.
8064
9f04a53e
MS
80652016-01-20 Martin Sebor <msebor@redhat.com>
8066
8067 PR c/69405
8068 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
8069 an incompatible argument when the argument isn't a valid tree node.
8070
7f26f7df
JM
80712016-01-18 Jason Merrill <jason@redhat.com>
8072
8073 PR c++/68767
8074 * c-common.c (check_function_arguments_recurse): Fold the whole
8075 COND_EXPR, not just the condition.
8076
f62bf092
TV
80772016-01-18 Tom de Vries <tom@codesourcery.com>
8078
8079 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
8080 classify as loop clause.
8081
e0a575ff
JJ
80822016-01-15 Jakub Jelinek <jakub@redhat.com>
8083
8084 PR bootstrap/68271
8085 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
8086 C++ FE no longer has limit on number of pragmas.
8087
80882015-01-14 Ryan Burn <contact@rnburn.com>
b6e3db06
RB
8089
8090 PR c++/69048
8091 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
c47eaca6 8092 to add missing cleanup point.
b6e3db06 8093
c7df95d8
DM
80942016-01-14 David Malcolm <dmalcolm@redhat.com>
8095
8096 PR c++/68819
8097 * c-indentation.c (get_visual_column): Add location_t param.
8098 Handle the column number being zero by effectively disabling the
8099 warning, with an "inform".
8100 (should_warn_for_misleading_indentation): Add location_t argument
8101 for all uses of get_visual_column.
8102
21efdd80
PP
81032016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
8104
8105 PR c++/69029
8106 * c-indentation.c (should_warn_for_misleading_indentation):
8107 Don't warn about do-while statements.
8108
7a127fa7
MS
81092016-01-07 Martin Sebor <msebor@redhat.com>
8110
8111 PR c/68966
8112 * c-common.c (sync_resolve_size): Reject first argument when it's
8113 a pointer to _Bool.
8114
c589e975
DM
81152016-01-05 David Malcolm <dmalcolm@redhat.com>
8116
8117 PR c/69122
8118 * c-indentation.c (get_visual_column): Remove default argument.
8119 (should_warn_for_misleading_indentation): For the multiline case,
8120 update call to get_visual_column for next_stmt_exploc so that it
8121 captures the location of the first non-whitespace character in the
8122 relevant line. Don't issue warnings if there is non-whitespace
8123 before the next statement.
8124
818ab71a
JJ
81252016-01-04 Jakub Jelinek <jakub@redhat.com>
8126
8127 Update copyright years.
8128
745e411d
DM
81292015-12-21 David Malcolm <dmalcolm@redhat.com>
8130
8131 * c-common.c (binary_op_error): Convert first param from
8132 location_t to rich_location * and use it when emitting an error.
8133 * c-common.h (binary_op_error): Convert first param from
8134 location_t to rich_location *.
8135
de67c4c3
DM
81362015-12-16 David Malcolm <dmalcolm@redhat.com>
8137
8138 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
8139 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
8140
4a38b02b
IV
81412015-12-15 Ilya Verbin <ilya.verbin@intel.com>
8142
8143 * c-common.c (c_common_attribute_table): Handle "omp declare target
8144 link" attribute.
8145
54d62f51
JJ
81462015-12-14 Jakub Jelinek <jakub@redhat.com>
8147
8148 PR c/68833
8149 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
8150
8d4227c8
TB
81512014-12-12 Tobias Burnus <burnus@net-b.de>
8152
8153 PR fortran/68815
8154 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
8155 specifiers (%d, %i,%u and %c).
8156
f6069ccc
DM
81572015-12-10 David Malcolm <dmalcolm@redhat.com>
8158
8159 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
8160
63bbf46d
JJ
81612015-12-08 Jakub Jelinek <jakub@redhat.com>
8162
8163 PR c/48088
8164 PR c/68657
8165 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
8166 * c-pragma.c (handle_pragma_diagnostic): Adjust
8167 control_warning_option caller.
8168
f79520bb
DM
81692015-12-07 David Malcolm <dmalcolm@redhat.com>
8170
8171 * c-common.c (c_cpp_error): Update for change to
8172 rich_location::set_range.
8173
b3d5bc62
JJ
81742015-12-04 Paolo Bonzini <bonzini@gnu.org>
8175
8176 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
8177 shifting 1 out of the sign bit.
8178
81792015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
8180
8181 * c-common.c (c_common_attribute_table[]): Update max arguments
8182 count for "simd" attribute.
8183 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
8184
6eb4a537
JJ
81852015-12-03 Jakub Jelinek <jakub@redhat.com>
8186
8187 PR preprocessor/57580
8188 * c-ppoutput.c (print): Change printed field to bool.
8189 Move src_file last for smaller padding.
8190 (init_pp_output): Set print.printed to false instead of 0.
8191 (scan_translation_unit): Fix up formatting. Set print.printed
8192 to true after printing something other than newline.
8193 (scan_translation_unit_trad): Set print.printed to true instead of 1.
8194 (maybe_print_line_1): Set print.printed to false instead of 0.
8195 (print_line_1): Likewise.
8196 (do_line_change): Set print.printed to true instead of 1.
8197 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
8198 dump_macro): Set print.printed to false after printing newline.
8199
4250754e
JM
82002015-12-02 Jason Merrill <jason@redhat.com>
8201
f479b43d
JM
8202 * c-common.c (fold_for_warn): New.
8203 (warn_logical_operator, warn_tautological_cmp)
8204 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
8205
4250754e
JM
8206 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
8207 (c_fully_fold_internal, decl_constant_value_for_optimization):
8208 Move to c/c-fold.c.
8209 * c-common.h: Don't declare decl_constant_value_for_optimization.
8210
e9e32ee6
JM
82112015-12-02 Joseph Myers <joseph@codesourcery.com>
8212
8213 PR c/68162
8214 * c-common.h (c_build_qualified_type): Add extra default
8215 arguments.
8216
37d5ad46
JB
82172015-12-01 Julian Brown <julian@codesourcery.com>
8218 Cesar Philippidis <cesar@codesourcery.com>
8219 James Norris <James_Norris@mentor.com>
8220
8221 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
8222 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
8223 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
8224
f07862c7
EB
82252015-11-30 Eric Botcazou <ebotcazou@adacore.com>
8226
8227 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
8228 (decl_sloc_common): Delete and move bulk of processing to...
8229 (decl_sloc): ...here.
8230 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
8231 (dump_ada_double_name): Remove S parameter and compute the suffix.
8232 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
8233 element type and deal with an anonymous one.
8234 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
8235 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
8236 and remove reference to QUAL_UNION_TYPE.
8237 (dump_nested_types): Make 2 passes on the fields and move bulk to...
8238 (dump_nested_type): ...here. New function extracted from above.
8239 Generate a full declaration for anonymous element type of arrays.
8240 (print_ada_declaration): Really skip anonymous declarations. Remove
8241 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
8242 Clean up processing of declarations of array types and objects.
8243 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
8244 Remove obsolete code and tidy up.
8245
75c8aac3
JH
82462015-11-29 Jan Hubicka <hubicka@ucw.cz>
8247
8248 PR c/67581
8249 * c-common.c (handle_transparent_union_attribute): Update
8250 also type variants.
8251
b58d3df2
ML
82522015-11-27 Martin Liska <mliska@suse.cz>
8253
8254 PR c++/68312
8255 * array-notation-common.c (cilkplus_extract_an_triplets):
8256 Release vector of vectors.
8257 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
8258
89a01fcf
EB
82592015-11-26 Eric Botcazou <ebotcazou@adacore.com>
8260
8261 PR c++/68527
8262 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
8263 (print_ada_struct_decl): Likewise.
8264
cc5c5226
IZ
82652015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
8266
8267 PR c++/68001
8268 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
8269 * cilk.c (recognize_spawn): Determine location in a more precise
8270 way.
8271
269adb9d
JM
82722015-11-19 Jason Merrill <jason@redhat.com>
8273
8274 * c-common.c (shorten_compare): But look through macros from
8275 system headers.
8276
d0eccfcd
JM
82772015-11-18 Jason Merrill <jason@redhat.com>
8278
8279 * c-common.c (shorten_compare): Don't -Wtype-limits if the
8280 non-constant operand comes from a macro.
8281
3e44547c
JM
82822015-11-17 Jason Merrill <jason@redhat.com>
8283
8284 PR bootstrap/68346
8285 * c-common.c (warn_tautological_cmp): Fold before checking for
8286 constants.
8287
0f62c7a0
MP
82882015-11-16 Marek Polacek <polacek@redhat.com>
8289
8290 PR c++/68362
8291 * c-common.c (check_case_bounds): Fold low and high cases.
8292
a868811e
MP
82932015-11-16 Marek Polacek <polacek@redhat.com>
8294
8295 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
8296 * c-common.c (c_common_get_alias_set): Likewise.
8297 (handle_visibility_attribute): Likewise.
8298
fff77217
KY
82992015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
8300
8301 * c-common.c (handle_simd_attribute): New.
8302 (struct attribute_spec): Add entry for "simd".
8303 (handle_simd_attribute): New.
8304
269e63b7
KT
83052015-11-13 Kai Tietz <ktietz70@googlemail.com>
8306
8307 * c-lex.c (interpret_float): Use fold_convert.
8308
ebedc9a3
DM
83092015-11-13 David Malcolm <dmalcolm@redhat.com>
8310
8311 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
8312 and store it on the result.
8313 * c-opts.c (c_common_init_options): Set
8314 global_dc->colorize_source_p.
8315
6e232ba4
JN
83162015-11-12 James Norris <jnorris@codesourcery.com>
8317 Joseph Myers <joseph@codesourcery.com>
8318
7365279f 8319 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
6e232ba4
JN
8320 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
8321 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
8322 PRAGMA_OACC_CLAUSE_LINK.
8323
e78bede6
MP
83242015-11-11 Marek Polacek <polacek@redhat.com>
8325
8326 PR c/68107
8327 PR c++/68266
8328 * c-common.c (valid_array_size_p): New function.
8329 * c-common.h (valid_array_size_p): Declare.
8330
3f8257db 83312015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4ac93c7c
DH
8332
8333 PR bootstrap/68271
8334 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
8335
69f293c9
AM
83362015-11-11 Andrew MacLeod <amacleod@redhat.com>
8337
8338 * array-notation-common.c: Remove unused header files.
8339 * c-ada-spec.c: Likewise.
8340 * c-cilkplus.c: Likewise.
8341 * c-common.c: Likewise.
8342 * c-cppbuiltin.c: Likewise.
8343 * c-dump.c: Likewise.
8344 * c-format.c: Likewise.
8345 * c-gimplify.c: Likewise.
8346 * c-indentation.c: Likewise.
8347 * c-lex.c: Likewise.
8348 * c-omp.c: Likewise.
8349 * c-opts.c: Likewise.
8350 * c-pch.c: Likewise.
8351 * c-ppoutput.c: Likewise.
8352 * c-pragma.c: Likewise.
8353 * c-pretty-print.c: Likewise.
8354 * c-semantics.c: Likewise.
8355 * c-ubsan.c: Likewise.
8356 * cilk.c: Likewise.
8357 * stub-objc.c: Likewise.
8358
3a40d81d
NS
83592015-11-09 Thomas Schwinge <thomas@codesourcery.com>
8360 Cesar Philippidis <cesar@codesourcery.com>
8361 James Norris <jnorris@codesourcery.com>
8362 Julian Brown <julian@codesourcery.com>
8363 Nathan Sidwell <nathan@codesourcery.com>
8364
8365 * c-pragma.c (oacc_pragmas): Add "routine".
8366 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
8367
ee45a32d
EB
83682015-11-08 Eric Botcazou <ebotcazou@adacore.com>
8369
8370 * c-common.c (c_common_attributes): Add scalar_storage_order.
8371 (handle_scalar_storage_order_attribute): New function.
8372 * c-pragma.c (global_sso): New variable.
8373 (maybe_apply_pragma_scalar_storage_order): New function.
8374 (handle_pragma_scalar_storage_order): Likewise.
8375 (init_pragma): Register scalar_storage_order.
8376 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
8377 * c.opt (Wscalar-storage-order): New warning.
8378 (fsso-struct=): New option.
8379
eb11eb15
MS
83802015-11-08 Martin Sebor <msebor@redhat.com>
8381
8382 * c.opt (Wplacement-new): Add a period to the end of a sentence.
8383
0aad0198
RS
83842015-11-07 Richard Sandiford <richard.sandiford@arm.com>
8385
8386 * c-common.c: Don't undef DEF_BUILTIN.
8387
8a645150
DM
83882015-11-06 David Malcolm <dmalcolm@redhat.com>
8389
8390 * c-common.c (c_cpp_error): Convert parameter from location_t to
8391 rich_location *. Eliminate the "column_override" parameter and
8392 the call to diagnostic_override_column.
8393 Update the "done_lexing" clause to set range 0
8394 on the rich_location, rather than overwriting a location_t.
8395 * c-common.h (c_cpp_error): Convert parameter from location_t to
8396 rich_location *. Eliminate the "column_override" parameter.
8397
7a5e4956
CP
83982015-11-05 Cesar Philippidis <cesar@codesourcery.com>
8399 Thomas Schwinge <thomas@codesourcery.com>
8400 James Norris <jnorris@codesourcery.com>
8401
8402 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
8403 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
8404 clauses with parallel and kernels and loops.
8405 * c-pragma.h (enum pragma_omp_clause): Add entries for
8406 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
8407 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
8408 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
8409 INDEPENDENT,SEQ}.
8410 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
8411
e2f5cc96
MS
84122015-11-05 Martin Sebor <msebor@redhat.com>
8413
8414 PR c++/67942
8415 * c.opt (-Wplacement-new): New option.
8416
e01d41e5
JJ
84172015-11-05 Jakub Jelinek <jakub@redhat.com>
8418
8419 * c-common.h (c_finish_omp_atomic): Add TEST argument.
8420 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
8421 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
8422 save_expr or create_tmp_var* if TEST is true.
8423 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
8424 Don't call add_stmt here.
8425 (struct c_omp_check_loop_iv_data): New type.
8426 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
8427 c_omp_check_loop_iv_exprs): New functions.
8428 (c_omp_split_clauses): Adjust for lastprivate being allowed on
8429 distribute.
8430 (c_omp_declare_simd_clauses_to_numbers): Change
8431 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
8432 (c_omp_declare_simd_clauses_to_decls): Similarly change those
8433 from numbers to PARM_DECLs.
8434
595278be
MM
84352015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
8436
8437 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
8438 flag_checking.
8439
3f8257db 84402015-11-03 Bernd Schmidt <bschmidt@redhat.com>
c85158de
MS
8441
8442 PR c++-common/67882
b3d5bc62
JJ
8443 * c-common.h (fold_offsetof_1): Add argument.
8444 * c-common.c (fold_offsetof_1): Diagnose more invalid
c85158de
MS
8445 offsetof expressions that reference elements past the end of
8446 an array.
8447
4bf9e5a8
TS
84482015-11-03 Thomas Schwinge <thomas@codesourcery.com>
8449 Chung-Lin Tang <cltang@codesourcery.com>
8450
8451 * c-pragma.c (oacc_pragmas): Add "atomic".
8452 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
8453
3b1661a9
ES
84542015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
8455
8456 * c-common.c (handle_target_clones_attribute): New.
8457 (c_common_attribute_table): Add handle_target_clones_attribute.
8458 (handle_always_inline_attribute): Add check on target_clones attribute.
8459 (handle_target_attribute): Ditto.
8460
2adfab87
AM
84612015-10-29 Andrew MacLeod <amacleod@redhat.com>
8462
8463 * array-notation-common.c: Reorder #include's and remove duplicates.
8464 * c-ada-spec.c: Likewise.
8465 * c-cilkplus.c: Likewise.
8466 * c-common.c: Likewise.
8467 * c-cppbuiltin.c: Likewise.
8468 * c-dump.c: Likewise.
8469 * c-format.c: Likewise.
8470 * c-gimplify.c: Likewise.
8471 * c-indentation.c: Likewise.
8472 * c-lex.c: Likewise.
8473 * c-omp.c: Likewise.
8474 * c-opts.c: Likewise.
8475 * c-pch.c: Likewise.
8476 * c-ppoutput.c: Likewise.
8477 * c-pragma.c: Likewise.
8478 * c-pretty-print.c: Likewise.
8479 * c-semantics.c: Likewise.
8480 * c-ubsan.c: Likewise.
8481 * cilk.c: Likewise.
8482 * stub-objc.c: Likewise.
8483
d90ec4f2
JM
84842015-10-28 Jason Merrill <jason@redhat.com>
8485
8486 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
8487
88bae6f4
TS
84882015-10-27 Thomas Schwinge <thomas@codesourcery.com>
8489 James Norris <jnorris@codesourcery.com>
8490 Cesar Philippidis <cesar@codesourcery.com>
8491
8492 PR c/64765
8493 PR c/64880
8494 * c-common.h (c_oacc_split_loop_clauses): Declare function.
8495 * c-omp.c (c_oacc_split_loop_clauses): New function.
8496
b1726d6c
MS
84972015-10-21 Martin Sebor <msebor@redhat.com>
8498
8499 PR driver/68043
8500 * c.opt: End each sentence that describes an option with a period.
8501
fa60eeb9
MP
85022015-10-20 Marek Polacek <polacek@redhat.com>
8503
8504 * array-notation-common.c (is_cilkplus_vector_p): Define.
8505 * c-common.h (is_cilkplus_vector_p): Declare.
8506
95979049
MP
85072015-10-20 Marek Polacek <polacek@redhat.com>
8508
8509 * c.opt (std=gnu++11): Do not describe as experimental.
8510 (std=gnu++14): Likewise.
8511
2a9fb712
JM
85122015-10-19 Jason Merrill <jason@redhat.com>
8513
8514 * c-cppbuiltin.c (c_cpp_builtins): Define
8515 __cpp_nontype_template_args.
8516
13b380a3
JM
85172015-10-19 Jason Merrill <jason@redhat.com>
8518
8519 * c-cppbuiltin.c (c_cpp_builtins): Define
8520 __cpp_enumerator_attributes, __cpp_fold_expressions,
8521 __cpp_unicode_characters.
8522
d9a6bd32
JJ
85232015-10-13 Jakub Jelinek <jakub@redhat.com>
8524 Aldy Hernandez <aldyh@redhat.com>
8525
8526 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
8527 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
8528 (c_define_builtins): Likewise.
8529 * c-common.h (enum c_omp_clause_split): Add
8530 C_OMP_CLAUSE_SPLIT_TASKLOOP.
8531 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
8532 (c_finish_omp_for): Add ORIG_DECLV argument.
8533 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
8534 201511 instead of 201307.
8535 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
8536 OMP_CRITICAL_CLAUSES to it.
8537 (c_finish_omp_ordered): Add CLAUSES argument, set
8538 OMP_ORDERED_CLAUSES to it.
8539 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
8540 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
8541 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
8542 constructs and new OpenMP 4.5 clauses. Clear
8543 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
8544 verification code.
8545 * c-pragma.c (omp_pragmas_simd): Add taskloop.
8546 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
8547 (enum pragma_omp_clause): Add
8548 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
8549 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
8550
624d31fe
RS
85512015-10-05 Richard Sandiford <richard.sandiford@arm.com>
8552
8553 * c-lex.c (interpret_float): Use real_equal instead of
8554 REAL_VALUES_EQUAL.
8555
b8fd7909
JM
85562015-10-04 Jason Merrill <jason@redhat.com>
8557
8558 Implement N4514, C++ Extensions for Transactional Memory.
8559 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
8560 (c_common_attribute_table): Add transaction_safe_dynamic.
8561 transaction_safe now affects type identity.
8562 (handle_tm_attribute): Handle transaction_safe_dynamic.
8563 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
8564 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
8565 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
8566 (D_TRANSMEM): New.
8567 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
8568 * c-pretty-print.c (pp_c_attributes_display): Don't print
8569 transaction_safe in C++.
8570
12651878
MP
85712015-10-02 Marek Polacek <polacek@redhat.com>
8572
8573 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
8574
3e3b8d63
MP
85752015-10-02 Marek Polacek <polacek@redhat.com>
8576
8577 PR c/64249
8578 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
8579 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
8580 * c.opt (Wduplicated-cond): New option.
8581
0d1a8f75
JM
85822015-10-01 Joseph Myers <joseph@codesourcery.com>
8583
8584 * c.opt (std=c11): Do not describe as experimental.
8585 (std=gnu11): Likewise.
8586 (std=iso9899:2011): Likewise.
8587
3e32ee19
NS
85882015-09-28 Nathan Sidwell <nathan@codesourcery.com>
8589
8590 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
8591 (DEF_FUNCTION_TYPE_VAR_11): Delete.
8592
974348ee
MP
85932015-09-25 Marek Polacek <polacek@redhat.com>
8594
8595 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
8596 (ubsan_instrument_shift): Likewise.
8597
15dbc1a6
MP
85982015-09-25 Marek Polacek <polacek@redhat.com>
8599
8600 PR sanitizer/64906
8601 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
8602
6b95d7cc
PP
86032015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
8604
8605 * c-indentation.c (should_warn_for_misleading_indentation):
8606 Compare next_stmt_vis_column with guard_line_first_nws instead
8607 of with guard_line_vis_column.
8608
c1822f9c
MLI
86092015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
8610
8611 PR c/49654
8612 PR c/49655
8613 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
8614 options and options not valid for the current language.
8615
d5398058
PP
86162015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
8617
8618 * c-indentation.c (should_warn_for_misleading_indentation):
8619 Float out and consolidate the calls to get_visual_column that
8620 are passed guard_exploc as an argument. Compare
8621 next_stmt_vis_column with guard_line_first_nws instead of with
8622 body_line_first_nws.
8623
6b333269
NS
86242015-09-22 Nathan Sidwell <nathan@codesourcery.com>
8625
8626 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
8627 Wnamespaces): New C++ warnings.
8628
a75f1574
JM
86292015-09-22 Jason Merrill <jason@redhat.com>
8630
8631 * c-common.h (abi_compat_version_crosses): New.
8632 (warn_abi_version): Declare.
8633 * c-common.c: Define it.
8634 * c-opts.c (c_common_post_options): Handle it.
8635 flag_abi_compat_version defaults to 8.
8636
bdaaa8b7
VV
86372015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
8638
8639 Complete the implementation of N4230, Nested namespace definition.
8640 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
8641 __cpp_nested_namespace_definitions.
8642
eaa797e8
MLI
86432015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
8644
8645 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
8646
c4914de6
MLI
86472015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
8648
8649 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
8650 when warning.
8651 * c-pragma.h (pragma_lex): Add optional loc argument.
8652
fcb87c50
MM
86532015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
8654
8655 * c-format.c (check_format_arg): Adjust to use common block size in all
8656 object pools.
8657
31bdd08a
DM
86582015-09-15 David Malcolm <dmalcolm@redhat.com>
8659
8660 * c-format.c (location_from_offset): Update for change in
8661 signature of location_get_source_line.
8662 * c-indentation.c (get_visual_column): Likewise.
8663 (line_contains_hash_if): Likewise.
8664
aa9f4b4c
MP
86652015-09-14 Marek Polacek <polacek@redhat.com>
8666
8667 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
8668 setting various warnings.
8669
aa256c4a
MP
86702015-09-14 Marek Polacek <polacek@redhat.com>
8671
8672 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
8673 a negative value.
8674
0f876f22
MW
86752015-09-11 Mark Wielaard <mjw@redhat.com>
8676
8677 PR c/28901
8678 * c.opt (Wunused-variable): Option from common.opt.
8679 (Wunused-const-variable): New option.
8680
273aa49e
PC
86812015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
8682
8683 PR c++/53184
8684 * c.opt ([Wsubobject-linkage]): Add.
8685
1807ffc1
MS
86862015-09-03 Martin Sebor <msebor@redhat.com>
8687
8688 PR c/66516
8689 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
8690 functions.
8691 * c-common.c (reject_gcc_builtin): Define.
8692
38942840
BI
86932015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
8694
8695 PR middle-end/60586
8696 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
8697 prototype.
8698 * c-gimplify.c (c_gimplify_expr): Added a call to the function
8699 cilk_gimplify_call_params_in_spawned_fn.
8700 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
8701 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
8702 unwrapping.
8703
c316b5e4
MP
87042015-08-25 Marek Polacek <polacek@redhat.com>
8705
8706 PR middle-end/67330
8707 * c-common.c (handle_weak_attribute): Don't check whether the
8708 visibility can be changed here.
8709
584a7c46
MLI
87102015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
8711
8712 * c-lex.c (c_lex_with_flags): Use explicit locations.
8713
a79683d5
TS
87142015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
8715
8716 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
8717 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
8718
61717a45
FXC
87192015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
8720
8721 PR middle-end/36757
8722 * c-common.c (check_builtin_function_arguments): Add check
8723 for BUILT_IN_SIGNBIT argument.
8724
329524f5
PC
87252015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
8726
8727 PR c++/67160
8728 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
8729 in c++1z mode.
8730
4ee55665
MP
87312015-08-17 Marek Polacek <polacek@redhat.com>
8732
8733 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
8734 with whitespaces before qualifier names.
8735
b893e375
MP
87362015-08-12 Marek Polacek <polacek@redhat.com>
8737
8738 PR c++/55095
8739 * c-common.c (maybe_warn_shift_overflow): Properly handle
8740 left-shifting 1 into the sign bit.
8741
c2d89095
MLI
87422015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
8743
8744 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
8745
971e17ff
AS
87462015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
8747 Braden Obrzut <admin@maniacsvault.net>
8748 Jason Merrill <jason@redhat.com>
8749
8750 Add C++ Concepts TS support.
8751 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
8752 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
8753 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
8754 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
8755 * c-opts.c (set_std_cxx1z): Set flag_concepts.
8756 * c.opt (fconcepts): New.
8757
b3d5bc62
JJ
87582015-08-02 Martin Sebor <msebor@redhat.com>
8759
8760 * c.opt (-Wframe-address): New warning option.
8761
8ebca419
PP
87622015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
8763
8764 * c-indentation.c (should_warn_for_misleading_indentation):
8765 Improve heuristics.
8766
1a1e101f
PP
87672015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
8768
8769 * c-indentation.c (get_visual_column): Add parameter first_nws,
8770 use it. Update comment documenting the function.
8771 (is_first_nonwhitespace_on_line): Remove.
8772 (should_warn_for_misleading_indentation): Replace usage of
8773 of is_first_nonwhitespace_on_line with get_visual_column.
8774
992118a1
PP
87752015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
8776
8777 * c-indentation.h (struct token_indent_info): Define.
8778 (get_token_indent_info): Define.
8779 (warn_for_misleading_information): Declare.
8780 * c-common.h (warn_for_misleading_information): Remove.
8781 * c-identation.c (warn_for_misleading_indentation):
8782 Change declaration to take three token_indent_infos. Adjust
8783 accordingly.
8784 * c-identation.c (should_warn_for_misleading_indentation):
8785 Likewise. Bail out early if the body is a compound statement.
8786 (guard_tinfo_to_string): Define.
8787
e8fa3817
JM
87882015-07-30 Jason Merrill <jason@redhat.com>
8789
8790 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
8791 '*' for reference decay.
8792
173864e8
MP
87932015-07-30 Marek Polacek <polacek@redhat.com>
8794
8795 * c-common.c (warn_tautological_cmp): Bail for float types.
8796
f2afe6dd
MP
87972015-07-27 Marek Polacek <polacek@redhat.com>
8798
8799 PR bootstrap/67030
8800 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
8801
05b28fd6
MP
88022015-07-27 Marek Polacek <polacek@redhat.com>
8803
8804 PR c++/66555
8805 PR c/54979
8806 * c-common.c (find_array_ref_with_const_idx_r): New function.
8807 (warn_tautological_cmp): New function.
8808 * c-common.h (warn_tautological_cmp): Declare.
8809 * c.opt (Wtautological-compare): New option.
8810
5a5062b8
MP
88112015-07-23 Marek Polacek <polacek@redhat.com>
8812
8813 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
8814 (ubsan_instrument_shift): Likewise.
8815
dc891fe7
MP
88162015-07-23 Marek Polacek <polacek@redhat.com>
8817
8818 PR sanitizer/66908
8819 * c-ubsan.c: Include gimplify.h.
8820 (ubsan_instrument_division): Unshare OP0 and OP1.
8821 (ubsan_instrument_shift): Likewise.
8822
451b5e48
MP
88232015-07-20 Marek Polacek <polacek@redhat.com>
8824 Richard Sandiford <richard.sandiford@arm.com>
8825
8826 PR c++/55095
8827 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
8828 Use EXPR_LOC_OR_LOC.
8829 (maybe_warn_shift_overflow): New function.
8830 * c-common.h (maybe_warn_shift_overflow): Declare.
8831 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
8832 * c.opt (Wshift-overflow): New option.
8833
fb0b2914
ML
88342015-07-16 Martin Liska <mliska@suse.cz>
8835
8836 * c-format.c (static void check_format_info_main): Use
8837 object_allocator instead of pool_allocator.
8838 (check_format_arg): Likewise.
8839 (check_format_info_main): Likewise.
8840
903f5c23
AM
88412015-07-15 Andrew MacLeod <amacleod@redhat.com>
8842
8843 * c-opts.c: Remove multiline #include comment.
8844
026c3cfd
AH
88452015-07-12 Aldy Hernandez <aldyh@redhat.com>
8846
8847 * c-common.c: Fix double word typos.
8848
bb49ee66
EB
88492015-07-10 Eric Botcazou <ebotcazou@adacore.com>
8850
8851 * c-ada-spec.h (cpp_operation): Revert latest change.
8852 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
8853 constructors and destructors.
8854
1916bcb5
AM
88552015-07-09 Andrew MacLeod <amacleod@redhat.com>
8856
8857 * c-common.h: Adjust includes for flags.h changes.
8858 * stub-objc.c: Likewise.
026c3cfd 8859
a9dcd529
EB
88602015-07-08 Eric Botcazou <ebotcazou@adacore.com>
8861
8862 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
8863 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
8864
b03b462f
JJ
88652015-07-08 Jakub Jelinek <jakub@redhat.com>
8866
8867 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
8868 are to be removed, return NULL rather than original clauses list.
8869
c7131fb2
AM
88702015-07-07 Andrew MacLeod <amacleod@redhat.com>
8871
8872 * array-notation-common.c: Adjust includes.
8873 * c-ada-spec.c: Likewise.
8874 * c-cilkplus.c: Likewise.
8875 * c-common.h: Likewise.
8876 * c-cppbuiltin.c: Likewise.
8877 * c-dump.c: Likewise.
8878 * c-format.c: Likewise.
8879 * c-gimplify.c: Likewise.
8880 * c-indentation.c: Likewise.
8881 * c-lex.c: Likewise.
8882 * c-omp.c: Likewise.
8883 * c-opts.c: Likewise.
8884 * c-pch.c: Likewise.
8885 * c-ppoutput.c: Likewise.
8886 * c-pragma.c: Likewise.
8887 * c-pretty-print.c: Likewise.
8888 * c-semantics.c: Likewise.
8889 * c-ubsan.c: Likewise.
8890 * cilk.c: Likewise.
8891 * stub-objc.c: Likewise.
8892
2a7fb83f
EB
88932015-07-07 Eric Botcazou <ebotcazou@adacore.com>
8894
8895 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
8896 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
8897
a03c9bf1
JM
88982015-07-01 Jason Merrill <jason@redhat.com>
8899
36a85135
JM
8900 * c-common.h (D_CXX11): Rename from D_CXX0X.
8901 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
8902 * c-common.c: Adjust.
8903
e7fa68d5
JM
8904 * c-opts.c (c_common_post_options): Default to C++14.
8905
a03c9bf1
JM
8906 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
8907
fe95b036
ESR
89082015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
8909
8910 Implement N4197 - Adding u8 character literals
b3d5bc62 8911 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
a64be36b 8912 CPP_CHAR.
b3d5bc62 8913 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
a64be36b 8914 CPP_UTF8CHAR_USERDEF tokens.
b3d5bc62 8915 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
a64be36b
EB
8916 and CPP_UTF8CHAR tokens.
8917 (lex_charconst): Treat CPP_UTF8CHAR token.
fe95b036 8918
da2e71c9
MLI
89192015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
8920
8921 PR fortran/66605
8922 * c-common.c (do_warn_unused_parameter): Move here.
8923 * c-common.h (do_warn_unused_parameter): Declare.
8924
b155cfd9
MP
89252015-06-29 Marek Polacek <polacek@redhat.com>
8926
8927 PR c/66322
8928 * c-common.c (check_case_bounds): Add bool * parameter. Set
8929 OUTSIDE_RANGE_P.
8930 (c_add_case_label): Add bool * parameter. Pass it down to
8931 check_case_bounds.
8932 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
8933 warning here.
8934 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
8935 declarations.
8936
31521951
MP
89372015-06-27 Marek Polacek <polacek@redhat.com>
8938
8939 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
8940 or VECTOR_INTEGER_TYPE_P throughout.
8941 * c-gimplify.c: Likewise.
8942
22d03525
MP
89432015-06-26 Marek Polacek <polacek@redhat.com>
8944
8945 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
8946 * c-common.c (c_fully_fold_internal): Likewise.
8947 (c_alignof_expr): Likewise.
8948 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
8949 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
b1726d6c 8950 * cilk.c (create_parm_list): Likewise.
22d03525 8951
af05e6e5
MP
89522015-06-26 Marek Polacek <polacek@redhat.com>
8953
8954 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
8955
f0889939
AM
89562015-06-25 Andrew MacLeod <amacleod@redhat.com>
8957
8958 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
8959 * c-gimplify.c: Likewise.
8960 * c-pragma.c: Likewise.
8961 * c-ubsan.c: Likewise.
8962 * cilk.c: Likewise.
8963
ca752f39
RS
89642015-06-25 Richard Sandiford <richard.sandiford@arm.com>
8965
8966 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
8967 ggc_hasher.
8968
16a16ec7
AM
89692015-06-25 Andrew MacLeod <amacleod@redhat.com>
8970
8971 * cilk.c: Move calls.h after tm.h in the include chain.
8972
0ae9bd27
MP
89732015-06-25 Marek Polacek <polacek@redhat.com>
8974
8975 * array-notation-common.c: Use VAR_P throughout.
8976 * c-ada-spec.c: Likewise.
8977 * c-common.c: Likewise.
8978 * c-format.c: Likewise.
8979 * c-gimplify.c: Likewise.
8980 * c-omp.c: Likewise.
8981 * c-pragma.c: Likewise.
8982 * c-pretty-print.c: Likewise.
8983 * cilk.c: Likewise.
8984
62f9079a
MP
89852015-06-25 Marek Polacek <polacek@redhat.com>
8986
8987 * cilk.c (extract_free_variables): Use is_global_var.
8988
0fa16060
RS
89892015-06-23 Richard Sandiford <richard.sandiford@arm.com>
8990
8991 * c-common.c: Don't include target-def.h.
8992
a68ae2e1
MP
89932015-06-23 Marek Polacek <polacek@redhat.com>
8994
8995 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
8996 when comparing INTEGER_CSTs.
8997
c6a2f2d9
PMR
89982015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
8999
9000 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
9001 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
9002 (dump_ada_template): Skip partially specialized types.
9003
6b4db501
MM
90042015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
9005
9006 * c-common.c (scalar_to_vector): Use std::swap instead of manually
9007 swapping.
9008
abb226c9
AM
90092015-06-17 Andrew MacLeod <amacleod@redhat.com>
9010
9011 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
9012 * c-ada-spec.c: Likewise.
9013 * c-cilkplus.c: Likewise.
9014 * c-common.c: Likewise.
9015 * c-common.h: Likewise.
9016 * c-cppbuiltin.c: Likewise.
9017 * c-dump.c: Likewise.
9018 * c-format.c: Likewise.
9019 * c-gimplify.c: Likewise.
9020 * c-indentation.c: Likewise.
9021 * c-lex.c: Likewise.
9022 * c-omp.c: Likewise.
9023 * c-opts.c: Likewise.
9024 * c-pch.c: Likewise.
9025 * c-ppoutput.c: Likewise.
9026 * c-pragma.c: Likewise.
9027 * c-pretty-print.c: Likewise.
9028 * c-semantics.c: Likewise.
9029 * c-ubsan.c: Likewise.
9030 * cilk.c: Likewise.
9031 * stub-objc.c: Likewise.
9032
076fecad
PP
90332015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
9034
9035 PR c++/65168
9036 * c-common.c (c_common_truthvalue_conversion): Warn when
9037 converting an address of a reference to a truth value.
9038
13fdf2e2
AM
90392015-06-08 Andrew MacLeod <amacleod@redhat.com>
9040
9041 * array-notation-common.c : Adjust include files.
9042 * c-ada-spec.c : Likewise.
9043 * c-cilkplus.c : Likewise.
9044 * c-common.c : Likewise.
9045 * c-common.h : Likewise.
9046 * c-cppbuiltin.c : Likewise.
9047 * c-dump.c : Likewise.
9048 * c-format.c : Likewise.
9049 * c-gimplify.c : Likewise.
9050 * c-indentation.c : Likewise.
9051 * c-lex.c : Likewise.
9052 * c-omp.c : Likewise.
9053 * c-opts.c : Likewise.
9054 * c-pch.c : Likewise.
9055 * c-ppoutput.c : Likewise.
9056 * c-pragma.c : Likewise.
9057 * c-pretty-print.c : Likewise.
9058 * c-semantics.c : Likewise.
9059 * c-ubsan.c : Likewise.
9060 * cilk.c : Likewise.
9061 * stub-objc.c : Likewise.
9062
a1661b90
MP
90632015-06-08 Marek Polacek <polacek@redhat.com>
9064
9065 PR c/66415
9066 * c-format.c (location_from_offset): Return LOC if LINE is null.
9067
d7438551
AH
90682015-06-05 Aldy Hernandez <aldyh@redhat.com>
9069
9070 * c-common.h (c_parse_final_cleanups): New prototype.
9071 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
9072
b3d5bc62
JJ
90732015-06-04 Sriraman Tallam <tmsriram@google.com>
9074
9075 * c-common.c (noplt): New attribute.
9076 (handle_noplt_attribute): New handler.
9077
ecb9f223
AM
90782015-06-04 Andrew MacLeod <amacleod@redhat.com>
9079
9080 * array-notation-common.c: Adjust includes for restructured coretypes.h.
9081 * c-ada-spec.c: Likewise.
9082 * c-cilkplus.c: Likewise.
9083 * c-common.c: Likewise.
9084 * c-common.h: Likewise.
9085 * c-cppbuiltin.c: Likewise.
9086 * c-dump.c: Likewise.
9087 * c-format.c: Likewise.
9088 * c-gimplify.c: Likewise.
9089 * c-indentation.c: Likewise.
9090 * c-lex.c: Likewise.
9091 * c-omp.c: Likewise.
9092 * c-opts.c: Likewise.
9093 * c-pch.c: Likewise.
9094 * c-ppoutput.c: Likewise.
9095 * c-pragma.c: Likewise.
9096 * c-pretty-print.c: Likewise.
9097 * c-semantics.c: Likewise.
9098 * c-ubsan.c: Likewise.
9099 * cilk.c: Likewise.
9100 * stub-objc.c: Likewise.
9101
6ac48155
DM
91022015-06-02 David Malcolm <dmalcolm@redhat.com>
9103
9104 PR c/66220:
9105 * c-indentation.c (should_warn_for_misleading_indentation): Use
9106 expand_location rather than expand_location_to_spelling_point.
9107 Don't warn if the guarding statement is more indented than the
9108 next/body stmts.
9109
773ce42e
DM
91102015-06-02 David Malcolm <dmalcolm@redhat.com>
9111
9112 * c-indentation.c (warn_for_misleading_indentation): Bail out
9113 immediately if -Wmisleading-indentation isn't enabled.
9114
4fef8379
ML
91152015-06-01 Martin Liska <mliska@suse.cz>
9116
9117 * c-format.c (check_format_arg):Use new type-based pool allocator.
9118 (check_format_info_main) Likewise.
9119
1edfb384
EB
91202015-05-31 Eric Botcazou <ebotcazou@adacore.com>
9121
9122 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
9123 (has_nontrivial_methods): Likewise.
9124
9677ef52
MP
91252015-05-25 Marek Polacek <polacek@redhat.com>
9126
9127 * c-ubsan.c (ubsan_instrument_shift): Use type0.
9128
fd5c817a
MP
91292015-05-22 Marek Polacek <polacek@redhat.com>
9130
9131 PR c/47043
9132 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
9133
a2f45fe6 91342015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
581edfa3
TS
9135
9136 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
9137 STACK_GROWS_DOWNWARD.
9138
a2f45fe6 91392015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
62f9f30b
TS
9140
9141 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
9142 STACK_GROWS_DOWNWARD rather than if it is defined.
9143
0fee2ac2 91442015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
b1726d6c 9145
0fee2ac2
MLI
9146 PR c/52952
9147 * c-format.c (location_column_from_byte_offset): New.
9148 (location_from_offset): New.
9149 (struct format_wanted_type): Add offset_loc field.
9150 (check_format_info): Move handling of location for extra arguments
9151 closer to the point of warning.
9152 (check_format_info_main): Pass the result of location_from_offset
9153 to warning_at.
9154 (format_type_warning): Pass the result of location_from_offset
9155 to warning_at.
9156
cf4ef6f7
MP
91572015-05-20 Marek Polacek <polacek@redhat.com>
9158
9159 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
9160
3a65ee74
MP
91612015-05-20 Marek Polacek <polacek@redhat.com>
9162
9163 * c-ada-spec.c (dump_sloc): Use DECL_P.
9164
21b634ae
MP
91652015-05-20 Marek Polacek <polacek@redhat.com>
9166
9167 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
9168 * c-common.c: Likewise.
9169
0e50b624
DM
91702015-05-19 David Malcolm <dmalcolm@redhat.com>
9171
9172 * c-common.h (fe_file_change): Strengthen param from
9173 const line_map * to const line_map_ordinary *.
9174 (pp_file_change): Likewise.
9175 * c-lex.c (fe_file_change): Likewise.
9176 (cb_define): Use linemap_check_ordinary when invoking
9177 SOURCE_LINE.
9178 (cb_undef): Likewise.
9179 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
9180 invoking cb_file_change.
9181 (c_finish_options): Likewise.
9182 (push_command_line_include): Likewise.
9183 (cb_file_change): Strengthen param "new_map" from
9184 const line_map * to const line_map_ordinary *.
9185 * c-ppoutput.c (cb_define): Likewise for local "map".
9186 (pp_file_change): Likewise for param "map" and local "from".
9187
fab27f52
MM
91882015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
9189
9190 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
9191
2fe1d762
TV
91922015-05-18 Tom de Vries <tom@codesourcery.com>
9193
9194 * c-common.c (build_va_arg_1): New function.
9195 (build_va_arg): Add address operator to va_list operand if necessary.
9196
7a37fa90
MM
91972015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
9198
9199 PR c/48956
9200 * c-common.c (int_safely_convertible_to_real_p): Define.
9201 (unsafe_conversion_p): Check conversions involving complex types.
9202 (conversion_warning): Add new warning message for conversions which
9203 discard imaginary component.
9204 * c-common.h: (enum conversion_safety): Add new enumerator for such
9205 conversions.
9206
3aa3c9fc
MP
92072015-05-14 Marek Polacek <polacek@redhat.com>
9208
9209 PR c/66066
9210 PR c/66127
9211 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
9212 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
9213 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
9214 use it. If FOR_INT_CONST, require that all evaluated operands be
9215 INTEGER_CSTs.
9216
c3388e62
DM
92172015-05-12 David Malcolm <dmalcolm@redhat.com>
9218
9219 * c-common.h (warn_for_misleading_indentation): New prototype.
9220 * c-indentation.c: New file.
9221 * c.opt (Wmisleading-indentation): New option.
9222
c7b38fd5
TV
92232015-05-12 Tom de Vries <tom@codesourcery.com>
9224
9225 PR tree-optimization/66010
9226 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
9227
381bf11e
JM
92282015-05-09 Jason Merrill <jason@redhat.com>
9229
edff0c06
JM
9230 * c-opts.c (c_common_post_options): Also clear
9231 cpp_opts->cpp_warn_cxx11_compat.
9232
129211bc
JM
9233 * c-common.h (enum cxx_dialect): Add cxx_unset.
9234 * c-common.c (cxx_dialect): Initialize to cxx_unset.
9235 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
9236
381bf11e
JM
9237 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
9238 (std=gnu++0x): Mark as Undocumented.
9239 (std=gnu++1y): Add deprecated message.
9240
fe191308
JM
92412015-05-08 Jason Merrill <jason@redhat.com>
9242
765189ff
JM
9243 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
9244 * c-opts.c: Adjust.
9245
fe191308
JM
9246 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
9247
755e528f
MP
92482015-05-08 Marek Polacek <polacek@redhat.com>
9249
9250 PR c/64918
9251 * c.opt (Woverride-init-side-effects): New option.
9252
0173bd2a
MP
92532015-05-07 Marek Polacek <polacek@redhat.com>
9254
9255 PR c/65179
9256 * c-common.c (c_fully_fold_internal): Warn when left shifting a
9257 negative value.
9258 * c.opt (Wshift-negative-value): New option.
9259 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
9260 when -Wextra and C99/C++11 mode.
9261
e0f0d3b9
MP
92622015-05-07 Marek Polacek <polacek@redhat.com>
9263 Martin Uecker <uecker@eecs.berkeley.edu>
9264
9265 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
9266 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
9267
8243e2a9
JM
92682015-05-05 Jason Merrill <jason@redhat.com>
9269
9270 * c.opt (Wterminate): New.
9271
577cd070
MP
92722015-04-30 Marek Polacek <polacek@redhat.com>
9273
9274 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
9275 require that the non-constant be of a boolean type.
9276
0373796b
JT
92772015-04-29 Josh Triplett <josh@joshtriplett.org>
9278
e0f0d3b9
MP
9279 * c-common.c (handle_section_attribute): Refactor to reduce
9280 nesting and distinguish between error cases.
0373796b 9281
716c0ba6
MP
92822015-04-29 Marek Polacek <polacek@redhat.com>
9283
9284 PR c/64610
9285 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
9286 with 0/1.
9287
8848828b
JJ
92882015-04-29 Jakub Jelinek <jakub@redhat.com>
9289
9290 * c-common.h (omp_clause_mask): Unconditionally define as a class.
9291 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
9292 HOST_BITS_PER_WIDE_INT.
9293
ecd0e562
TV
92942015-04-28 Tom de Vries <tom@codesourcery.com>
9295
9296 PR tree-optimization/65887
9297 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
9298
2a877204 92992015-04-28 Eric Botcazou <ebotcazou@adacore.com>
e0f0d3b9 9300 Pierre-Marie de Rodat <derodat@adacore.com>
2a877204
EB
9301
9302 * c-ada-spec.c (in_function): Delete.
9303 (dump_generic_ada_node): Do not change in_function and remove the
9304 redundant code dealing with it.
9305 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
9306 (print_ada_methods): Output the static member functions in a nested
9307 package after the regular methods as well as associated renamings.
9308
4853031e
MP
93092015-04-24 Marek Polacek <polacek@redhat.com>
9310
9311 PR c/65830
9312 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
9313 and OPT_Wshift_count_overflow.
9314
8c2b7f79
MP
9315 PR c/63357
9316 * c-common.c (warn_logical_operator): Warn if the operands have the
9317 same expressions.
9318
b8787813
MP
93192015-04-24 Marek Polacek <polacek@redhat.com>
9320
9321 PR c/61534
9322 * c-common.c (warn_logical_operator): Bail if either operand comes
9323 from a macro expansion.
9324
8fba1830
BRF
93252015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
9326
9327 PR target/55143
9328 * c-common.c (c_default_pointer_mode): Add definition.
9329 * c-common.h (c_default_pointer_mode): Add declaration.
9330
17958621
JJ
93312015-03-11 Jakub Jelinek <jakub@redhat.com>
9332
9333 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
9334 on record_builtin_type argument.
9335
7ccb1a11
JJ
93362015-03-10 Jakub Jelinek <jakub@redhat.com>
9337
9338 PR c/65120
9339 * c-common.c (warn_logical_not_parentheses): Don't warn for
9340 !x == 0 or !x != 0.
9341
04fd785e
MP
93422015-03-07 Marek Polacek <polacek@redhat.com>
9343
9344 PR sanitizer/65280
9345 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
9346 before trying to figure out whether we have a flexible array member.
9347
a4e26206 93482015-03-06 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 9349 Jonathan Wakely <jwakely.gcc@gmail.com>
a4e26206
EB
9350
9351 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
9352
0d2489f4
EB
93532015-03-05 Eric Botcazou <ebotcazou@adacore.com>
9354
9355 PR ada/65319
9356 * c-ada-spec.c (print_destructor): Remove obsolete code.
9357
83ed54d7
EB
93582015-03-01 Eric Botcazou <ebotcazou@adacore.com>
9359
9360 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
9361 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
9362 DECL_TEMPLATE_RESULT emulations.
9363 (dump_ada_template)): Add guard for TYPE_METHODS.
9364
7631f0e2
MP
93652015-02-27 Marek Polacek <polacek@redhat.com>
9366
9367 PR c/65040
9368 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
9369
d1783ae5
KT
93702015-02-27 Kai Tietz <ktietz@redhat.com>
9371
9372 PR c/35330
9373 * c-pragma.c (handle_pragma_weak): Do not try to create
9374 weak/alias of declarations not being function, or variable
9375 declarations.
9376
56a9f6bc
TS
93772015-02-24 Thomas Schwinge <thomas@codesourcery.com>
9378
9379 PR libgomp/64625
9380 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
9381 Remove macros.
9382 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
9383
3d5cb23d
MP
93842015-02-16 Marek Polacek <polacek@redhat.com>
9385
9386 PR c/65066
9387 * c-format.c (check_format_types): Handle null param.
9388
fa008882
MP
93892015-02-13 Marek Polacek <polacek@redhat.com>
9390
9391 PR c/65040
9392 * c-format.c (check_format_types): Don't warn about different
9393 signedness if the original value is in the range of WANTED_TYPE.
9394
785f21af
JM
93952015-02-12 Jason Merrill <jason@redhat.com>
9396
9397 PR c++/64956
9398 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
9399 to the current highest version.
9400 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
9401
4886ec8e
JJ
94022015-02-04 Jakub Jelinek <jakub@redhat.com>
9403
9404 PR c/64824
9405 PR c/64868
9406 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
9407 instead of RDIV_EXPR. Use build_binary_op instead of
9408 build2_loc.
9409
40fecdd6
JM
94102015-01-30 Joseph Myers <joseph@codesourcery.com>
9411
9412 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
9413 to pass input_location as first argument.
9414
a0c88d06
TV
94152015-01-23 Tom de Vries <tom@codesourcery.com>
9416
9417 PR libgomp/64672
9418 * c.opt (fopenacc): Mark as LTO option.
9419
1506ae0e
TV
94202015-01-23 Tom de Vries <tom@codesourcery.com>
9421
9422 PR libgomp/64707
9423 * c.opt (fopenmp): Mark as LTO option.
9424
31be63ab
JJ
94252015-01-21 Jakub Jelinek <jakub@redhat.com>
9426
9427 PR c/63307
b1726d6c 9428 * cilk.c (fill_decls_vec): Only put decls into vector v.
31be63ab
JJ
9429 (compare_decls): Fix up formatting.
9430
94312015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
9432
9433 PR c/63307
9434 * cilk.c: Include vec.h.
9435 (struct cilk_decls): New structure.
9436 (wrapper_parm_cb): Split this function to...
9437 (fill_decls_vec): ...this...
9438 (create_parm_list): ...and this.
9439 (compare_decls): New function.
9440 (for_local_cb): Remove.
9441 (wrapper_local_cb): Ditto.
9442 (build_wrapper_type): For now first traverse and fill vector of
9443 declarations then sort it and then deal with sorted vector.
9444 (cilk_outline): Ditto.
9445 (declare_one_free_variable): Ditto.
9446
6875457f
JM
94472015-01-21 Jason Merrill <jason@redhat.com>
9448
9449 PR c++/64629
9450 * c-format.c (check_format_arg): Call decl_constant_value.
9451
185c9e56
ML
94522015-01-19 Martin Liska <mliska@suse.cz>
9453
9454 * c-common.c (handle_noicf_attribute): New function.
9455
41dbbb37
TS
94562015-01-15 Thomas Schwinge <thomas@codesourcery.com>
9457 Bernd Schmidt <bernds@codesourcery.com>
9458 James Norris <jnorris@codesourcery.com>
9459 Cesar Philippidis <cesar@codesourcery.com>
9460 Ilmir Usmanov <i.usmanov@samsung.com>
9461 Jakub Jelinek <jakub@redhat.com>
9462
9463 * c.opt (fopenacc): New option.
9464 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
9465 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
9466 New macros.
9467 * c-common.h (c_finish_oacc_wait): New prototype.
9468 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
9469 (c_finish_oacc_wait): New function.
9470 * c-pragma.c (oacc_pragmas): New variable.
9471 (c_pp_lookup_pragma, init_pragma): Handle it.
9472 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
9473 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
9474 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
9475 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
9476 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
9477 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
9478 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
9479 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
9480 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
9481 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
9482 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
9483 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
9484 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
9485 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
9486 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
9487 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
9488 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
9489 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
9490 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
9491 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
9492 PRAGMA_OACC_CLAUSE_WORKER.
9493
3f8257db 94942015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
5434dc07
MD
9495
9496 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
9497 for the new option fstack-protector_explicit.
9498 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
9499 (handle_stack_protect_attribute): New function.
9500
3f8257db 95012015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
de1b5c17
MU
9502
9503 * c.opt: New option -Warray-bounds=.
9504
adfac8df
JJ
95052015-01-09 Michael Collison <michael.collison@linaro.org>
9506
9507 * array-notation-common.c: Include hash-set.h, machmode.h,
9508 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9509 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
9510 * c-ada-spec.c: Ditto.
9511 * c-cilkplus.c: Ditto.
9512 * c-common.c: Include input.h due to flattening of tree.h.
9513 Define macro GCC_C_COMMON_C.
9514 * c-common.h: Flatten tree.h header files into c-common.h.
9515 Remove include of tree-core.h.
9516 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
9517 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9518 fold-const.h, wide-int.h, and inchash.h due to
9519 flattening of tree.h.
9520 * c-dump.c: Ditto.
9521 * c-format.c: Flatten tree.h header files into c-common.h.
9522 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
9523 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9524 fold-const.h, wide-int.h, and inchash.h due to
9525 flattening of tree.h.
9526 * c-dump.c: Include hash-set.h, machmode.h,
9527 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9528 fold-const.h, wide-int.h, and inchash.h due to
9529 flattening of tree.h.
9530 * c-format.c: Include hash-set.h, machmode.h,
9531 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9532 fold-const.h, wide-int.h, inchash.h and real.h due to
9533 flattening of tree.h.
9534 * c-gimplify.c: Include hash-set.h, machmode.h,
9535 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9536 fold-const.h, wide-int.h, and inchash.h due to
9537 flattening of tree.h.
9538 * cilk.c: Ditto.
9539 * c-lex.c: Ditto.
9540 * c-omp.c: Ditto.
9541 * c-opts.c: Ditto.
9542 * c-pch.c: Ditto.
9543 * c-ppoutput.c: Ditto.
9544 * c-pragma.c: Ditto.
9545 * c-pretty-print.c: Ditto.
9546 * c-semantics.c: Ditto.
9547 * c-ubsan.c: Ditto.
9548 * stub-objc.c: Ditto.
9549
f5481fc4
JM
95502015-01-08 Jason Merrill <jason@redhat.com>
9551
9552 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
9553 do_ubsan_in_current_function.
9554 (ubsan_maybe_instrument_reference_or_call): Likewise.
9555 * c-ubsan.h: Declare it.
9556
de35aa66
MS
95572015-01-08 Mike Stump <mikestump@comcast.net>
9558
9559 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
9560
4a9a42ab
MP
95612015-01-07 Marek Polacek <polacek@redhat.com>
9562
9563 PR c/64440
9564 * c-common.c (c_fully_fold_internal): Warn for division and modulo
9565 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
9566
2f42e5de
TS
95672015-01-05 Trevor Saunders <tsaunders@mozilla.com>
9568
9569 PR c++/31397
9570 * c.opt (Wsuggest-override): New option.
9571
5624e564
JJ
95722015-01-05 Jakub Jelinek <jakub@redhat.com>
9573
9574 Update copyright years.
9575
5bd012f8
MP
95762015-01-05 Marek Polacek <polacek@redhat.com>
9577
9578 PR c/64423
9579 * c-common.c (warn_array_subscript_with_type_char): Add location_t
9580 parameter. Use it.
9581 * c-common.h (warn_array_subscript_with_type_char): Update
9582 declaration.
9583
a7fa8d18
ESR
95842014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
9585
9586 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
9587 Control macro with flag_sized_deallocation.
9588
3f8257db 95892014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
768952be
MU
9590
9591 * c.opt (Wdiscarded-array-qualifiers): New option.
9592
1f8d3e84
JJ
95932014-12-19 Jakub Jelinek <jakub@redhat.com>
9594
9595 PR preprocessor/63831
9596 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
9597 and __has_cpp_attribute here.
9598 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
9599 c_common_has_attribute.
9600 * c-common.h (c_common_has_attribute): New prototype.
9601 * c-lex.c (init_c_lex): Set cb->has_attribute to
9602 c_common_has_attribute instead of cb_has_attribute.
9603 (get_token_no_padding): New function.
9604 (cb_has_attribute): Renamed to ...
9605 (c_common_has_attribute): ... this. No longer static. Use
9606 get_token_no_padding, require ()s, don't build TREE_LIST
9607 unnecessarily, fix up formatting, adjust diagnostics, call
9608 init_attributes.
9609
20b06add
JM
96102014-12-15 Jason Merrill <jason@redhat.com>
9611
9612 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
9613 (-Wsized-deallocation): New.
9614 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
9615 to on in C++14 and up.
9616
94a073b2
JM
96172014-12-11 Jason Merrill <jason@redhat.com>
9618
acaa5911
JM
9619 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
9620
94a073b2
JM
9621 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
9622 we aren't complaining about VLAs.
9623
7fb66c15
MP
96242014-12-06 Marek Polacek <polacek@redhat.com>
9625
9626 PR tree-optimization/64183
9627 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
9628 shift-expression if it is integer_type_node. Use types_compatible_p.
9629
b731b390
JJ
96302014-11-29 Jakub Jelinek <jakub@redhat.com>
9631
9632 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
9633 last argument from create_tmp_var_raw and create_tmp_var calls.
9634 * cilk.c (gimplify_cilk_spawn): Likewise.
9635 * c-omp.c (c_finish_omp_atomic): Likewise.
9636
6a4da643
MP
96372014-11-28 Marek Polacek <polacek@redhat.com>
9638
9639 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
9640 instead of unsigned_type_node.
9641
541e35a6
MP
96422014-11-28 Marek Polacek <polacek@redhat.com>
9643
9644 PR c/63862
9645 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
9646 to op1_utype.
9647 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
9648 expression to unsigned_type_node.
9649
dcc97066
MW
96502014-11-20 Mark Wielaard <mjw@redhat.com>
9651
9652 PR debug/38757
9653 * c-opts.c (set_std_c89): Set lang_hooks.name.
9654 (set_std_c99): Likewise.
9655 (set_std_c11): Likewise.
9656 (set_std_cxx98): Likewise.
9657 (set_std_cxx11): Likewise.
9658 (set_std_cxx14): Likewise.
9659 (set_std_cxx1z): Likewise.
9660
aa7da51a
JJ
96612014-11-21 Jakub Jelinek <jakub@redhat.com>
9662
9663 PR target/63764
9664 * c-common.h (convert_vector_to_pointer_for_subscript): Change
9665 return type to bool.
009a3480 9666 * c-common.c: Include gimple-expr.h.
aa7da51a
JJ
9667 (convert_vector_to_pointer_for_subscript): Change return type to
9668 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
9669 and copy it into a TARGET_EXPR and use that instead of *vecp
9670 directly.
9671
538dd0b7
DM
96722014-11-19 David Malcolm <dmalcolm@redhat.com>
9673
9674 Merger of git branch "gimple-classes-v2-option-3".
9675 * ChangeLog.gimple-classes: New.
9676 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
9677 from being just a vec<gimple> to a vec<gbind *>.
9678
c39a5e99
JJ
96792014-11-18 Jakub Jelinek <jakub@redhat.com>
9680
9681 PR sanitizer/63813
9682 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
9683 argument to ptype, set type to TREE_TYPE (ptype). Don't call
9684 get_pointer_alignment for non-pointers. Use ptype, or if it is
9685 reference type, corresponding pointer type, as type of kind
9686 argument.
9687 (ubsan_maybe_instrument_reference,
9688 ubsan_maybe_instrument_member_call): Adjust callers.
9689
8537a4a9
MP
96902014-11-15 Marek Polacek <polacek@redhat.com>
9691
9692 PR middle-end/63884
9693 * array-notation-common.c (is_sec_implicit_index_fn): Return false
9694 for NULL fndecl.
9695 (extract_array_notation_exprs): Return for NULL node.
9696
2079956a
JM
96972014-11-12 Joseph Myers <joseph@codesourcery.com>
9698
9699 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
9700 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
9701
1304953e
JJ
97022014-11-12 Jakub Jelinek <jakub@redhat.com>
9703
9704 PR c/59708
9705 * c-common.c (check_builtin_function_arguments): Handle
9706 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
9707
e5e44252
AK
97082014-11-10 Andi Kleen <ak@linux.intel.com>
9709
9710 PR c/60804
9711 * c-common.h (check_no_cilk): Declare.
9712 * cilk.c (get_error_location): New function.
9713 (check_no_cilk): Dito.
9714
e64b984d
AK
97152014-11-10 Andi Kleen <ak@linux.intel.com>
9716
9717 * cilk.c (recognize_spawn): Use expression location
9718 for error message.
9719
13c21655
PC
97202014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
9721
9722 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
9723
42fd12b1
ESR
97242014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
9725
9726 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
9727 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
9728 (__cpp_range_based_for, __cpp_initializer_lists,
9729 __cpp_delegating_constructors, __cpp_nsdmi,
9730 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
9731 for C++11; (__cpp_attribute_deprecated): Remove in favor of
9732 __has_cpp_attribute.
9733 * c-lex.c (cb_has_attribute): New callback CPP function;
9734 (init_c_lex): Set has_attribute callback.
9735
6f450181
RB
97362014-11-04 Richard Biener <rguenther@suse.de>
9737
9738 * c-common.c (shorten_compare): Do not shorten mixed
9739 DFP and non-DFP compares.
9740
26f0e1d6
ESR
97412014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
9742
9743 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
9744 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
9745 Commentary and rearrangement of tests.
9746 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
9747 Commentary and rearrangement of tests.
ab20d992 9748 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
26f0e1d6
ESR
9749 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
9750
ef4bddc2
RS
97512014-10-29 Richard Sandiford <richard.sandiford@arm.com>
9752
9753 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
9754 enum from machine_mode.
9755
c582198b
AM
97562014-10-28 Andrew MacLeod <amacleod@redhat.com>
9757
adfac8df
JJ
9758 * c-common.c: Adjust include files.
9759 * c-gimplify.c: Ditto.
9760 * cilk.c: Ditto.
9761 * c-pragma.c: Ditto.
9762 * c-ubsan.c: Ditto.
c582198b 9763
60393bbc
AM
97642014-10-27 Andrew MacLeod <amacleod@redhat.com>
9765
9766 * c-gimplify.c: Adjust include files.
9767
d723bb7c
MLI
97682014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
9769
9770 PR c++/53061
9771 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
9772 c_common_initialize_diagnostics.
9773 * c-common.h: Likewise.
9774
90f3520e
MP
97752014-10-24 Marek Polacek <polacek@redhat.com>
9776
9777 PR c/56980
9778 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
9779 print "struct"/"union"/"enum" for typedefed names.
9780
59d7607a
MP
97812014-10-23 Marek Polacek <polacek@redhat.com>
9782
9783 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
9784 in unsigned type.
9785
d95a2703
JJ
97862014-10-22 Jakub Jelinek <jakub@redhat.com>
9787 Yury Gribov <y.gribov@samsung.com>
9788
9789 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
9790 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
9791 instead of flag_sanitize_recover as bool flag.
9792
8e6ef852
KY
97932014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
9794
9795 * cilk.c: Revert previous change.
9796
948cf550
IZ
97972014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
9798
9799 PR c/63307
9800 * cilk.c: Include vec.h.
9801 (struct cilk_decls): New structure.
9802 (wrapper_parm_cb): Split this function to...
9803 (fill_decls_vec): ...this...
9804 (create_parm_list): ...and this.
9805 (compare_decls): New function.
9806 (for_local_cb): Remove.
9807 (wrapper_local_cb): Ditto.
9808 (build_wrapper_type): For now first traverse and fill vector of
9809 declarations then sort it and then deal with sorted vector.
9810 (cilk_outline): Ditto.
9811 (declare_one_free_variable): Ditto.
9812
92574c7c
MP
98132014-10-17 Marek Polacek <polacek@redhat.com>
9814
9815 * c-opts.c (c_common_post_options): Set warn_implicit_int.
9816 * c.opt (Wimplicit-int): Initialize to -1.
9817
83685514
AM
98182014-10-16 Andrew MacLeod <amacleod@redhat.com>
9819
9820 * c-pragma.c: Adjust include files.
9821 * c-semantics.c: Likewise.
9822
5b8300ea
DD
98232014-10-16 DJ Delorie <dj@redhat.com>
9824
9825 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
9826 multiples of bytes.
9827
5f83e90b
JM
98282014-10-14 Jason Merrill <jason@redhat.com>
9829
9830 PR c++/63455
9831 * c-common.h (CPP_PREPARSED_EXPR): New.
9832 (N_CP_TTYPES): Adjust.
9833
d73326ca
MP
98342014-10-15 Marek Polacek <polacek@redhat.com>
9835
9836 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
9837
78a7c317
DD
98382014-10-14 DJ Delorie <dj@redhat.com>
9839
9840 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
9841 types, not just __int128.
9842 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
9843 types, not just __int128.
9844 (cpp_atomic_builtins): Round pointer sizes up.
9845 (type_suffix): Use type precision, not specific types.
9846 * c-common.c (c_common_reswords): Remove __int128 special case.
9847 (c_common_type_for_size): Check for all __intN types, not just
9848 __int128.
9849 (c_common_type_for_mode): Likewise.
9850 (c_common_signed_or_unsigned_type): Likewise.
9851 (c_build_bitfield_integer_type): Likewise.
9852 (c_common_nodes_and_builtins): Likewise.
9853 (keyword_begins_type_specifier): Likewise.
9854 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
9855 __intN variants.
9856
2a22f99c
TS
98572014-10-12 Trevor Saunders <tsaunders@mozilla.com>
9858
9859 * c-common.c: Use hash_table instead of hashtab.
9860
2a8ef767
ESR
98612014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
9862
adfac8df 9863 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
2a8ef767
ESR
9864 C++11 section.
9865
3c9aabbd
MG
98662014-10-03 Marc Glisse <marc.glisse@inria.fr>
9867
9868 PR c++/54427
9869 PR c++/57198
9870 PR c++/58845
9871 * c-common.c (warn_logical_operator): Punt for vectors.
9872
a15f7cb8
ESR
98732014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
9874
9875 Implement SD-6: SG10 Feature Test Recommendations
9876 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
9877 macros and the __has_header macro.
9878
8d0cf15e
JM
98792014-09-30 Jason Merrill <jason@redhat.com>
9880
dd5d5481
JM
9881 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
9882 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
9883 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
9884
b752325e
JM
9885 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
9886 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
9887
8d0cf15e
JM
9888 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
9889 * c-common.c (c_common_reswords): Remove __is_convertible_to.
9890
083e891e
MP
98912014-09-24 Marek Polacek <polacek@redhat.com>
9892
9893 PR c/61405
9894 PR c/53874
9895 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
9896
7861b648
AK
98972014-09-23 Andi Kleen <ak@linux.intel.com>
9898
9899 * c-common.c (handle_no_reorder_attribute): New function.
9900 (c_common_attribute_table): Add no_reorder attribute.
9901
9a79452d
JM
99022014-09-22 Joseph Myers <joseph@codesourcery.com>
9903
9904 * c-cppbuiltin.c (c_cpp_builtins): Define
9905 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
9906 modes.
9907
dd69f047
JM
99082014-09-18 Joseph Myers <joseph@codesourcery.com>
9909
9910 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
9911 for supported floating-point modes.
9912
737a4826
MLI
99132014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
9914
9915 * c.opt (Wpsabi): Use LangEnabledBy.
9916 * c-opts.c (c_common_handle_option): Do not handle here.
9917
8cc4b7a2
JM
99182014-09-12 Joseph Myers <joseph@codesourcery.com>
9919
9920 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
9921 macros for floating-point modes.
9922
179b5a55
MG
99232014-09-11 Marc Glisse <marc.glisse@inria.fr>
9924
9925 PR target/58757
9926 * c-cppbuiltin.c (builtin_define_float_constants): Correct
9927 __*_DENORM_MIN__ without denormals.
9928
570a11fe
JJ
99292014-09-10 Jakub Jelinek <jakub@redhat.com>
9930
9931 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
9932 ubsan_instrument_vla, ubsan_instrument_return): Adjust
9933 ubsan_create_data callers.
9934 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
9935 index is constant or BIT_AND_EXPR with constant mask and is
9936 small enough for the bound.
9937 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
9938 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
9939
b559c810
MLI
99402014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
9941
9942 * c.opt: Add CppReason to various flags.
9943 (Wdate-time): Re-sort.
9944 * c-common.c: Include c-common.h earlier.
9945 (struct reason_option_codes_t): Delete.
9946 (c_option_controlling_cpp_error): Prefix global type and struct
9947 with cpp_.
9948
1ef33fd4
MLI
99492014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
9950
9951 * c.opt (Wnormalized): New.
9952 (Wnormalized=): Use Enum and Reject Negative.
9953 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
9954
66bb34c0
JM
99552014-09-08 Joseph Myers <joseph@codesourcery.com>
9956
9957 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
9958 digits of floating-point modes if -fbuilding-libgcc.
9959
53d68b9f
JM
99602014-09-05 Joseph Myers <joseph@codesourcery.com>
9961
9962 * c-cppbuiltin.c (c_cpp_builtins): Also define
9963 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
9964 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
9965 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
9966 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
9967 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
9968 __LIBGCC_STACK_GROWS_DOWNWARD__,
9969 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
9970 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
9971 __LIBGCC_DWARF_FRAME_REGISTERS__,
9972 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
9973 __LIBGCC_STACK_POINTER_REGNUM__ and
9974 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
9975 (builtin_define_with_value): Handle backslash-escaping in string
9976 macro values.
9977
f65586dc
RB
99782014-09-05 Richard Biener <rguenther@suse.de>
9979
9980 PR middle-end/63148
9981 * c-format.c (check_format_arg): Properly handle
9982 effectively signed POINTER_PLUS_EXPR offset.
9983
2b71f4a4
MLI
99842014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
9985
9986 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
9987 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
9988 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
9989 and Init.
9990 * c-opts.c (c_common_handle_option): Do not handle here.
9991 (sanitize_cpp_opts): Likewise.
9992 * c-common.c (struct reason_option_codes_t): Handle
9993 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
9994
d2e4feca
MP
99952014-09-03 Marek Polacek <polacek@redhat.com>
9996
9997 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
9998
9a771876
JJ
99992014-09-02 Jakub Jelinek <jakub@redhat.com>
10000 Balaji V. Iyer <balaji.v.iyer@intel.com>
10001 Igor Zamyatin <igor.zamyatin@intel.com>
10002
10003 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
10004 * c-common.c (c_common_reswords): Added _Cilk_for.
10005 * c-common.h (enum rid): Added RID_CILK_FOR.
10006 (cilk_for_number_of_iterations): Add declaration.
10007 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
10008 CILK_FOR.
10009 * c-pragma.c (init_pragma): Register "grainsize" pragma.
10010 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
10011
81b5d104
MLI
100122014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
10013
10014 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
10015 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
10016 Wundef): Use CPP, Var and Init.
10017 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
10018
b753b37b
MLI
100192014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
10020
10021 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
10022 * c-opts.c (c_common_handle_option): Do not handle here.
10023
028aee17
JM
100242014-08-25 Jason Merrill <jason@redhat.com>
10025
10026 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
10027 -std=c++14 and -std=gnu++14, rather than the reverse.
10028 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
10029 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
10030 * c-common.h (cxx_dialect): Remove cxx1y.
10031
e4276ba5
ESR
100322014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
10033
10034 * c-common.h (enum cxx_dialect): Add cxx14.
10035 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
10036 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
10037 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
10038
a545cacd
JM
100392014-08-22 Jason Merrill <jason@redhat.com>
10040
10041 * c.opt (std=gnu++17): Fix alias.
10042
59ea0364
MP
100432014-08-22 Marek Polacek <polacek@redhat.com>
10044
10045 PR c++/62199
10046 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
10047 check for vector types. Drop LHS argument.
10048 * c-common.h (warn_logical_not_parentheses): Adjust.
10049
596e808c
MLI
100502014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
10051
10052 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
10053 (Wmultichar): Likewise.
10054 (Wdate-time): Use C-family languages instead of Common. Use CPP
10055 and Var.
10056 * c-opts.c (c_common_handle_option): Do not handle the above
10057 options here.
10058 (sanitize_cpp_opts): Likewise.
10059
18767f65
MLI
100602014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
10061
10062 PR fortran/44054
10063 * c-opts.c: Include tree-diagnostics.h.
10064 (c_diagnostic_finalizer): New.
10065 (c_common_initialize_diagnostics): Use it.
10066
b4413594
MLI
100672014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
10068
10069 PR preprocessor/51303
10070 * c-common.c (struct reason_option_codes_t option_codes):
10071 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
10072
43f9a13c
MLI
100732014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
10074
10075 PR c/60975
10076 PR c/53063
10077 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
10078 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
10079 (c_common_post_options): Call init_global_opts_from_cpp.
10080 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
10081
04159acf
MP
100822014-08-19 Marek Polacek <polacek@redhat.com>
10083
10084 PR c++/62153
10085 * c-common.c (maybe_warn_bool_compare): New function.
10086 * c-common.h (maybe_warn_bool_compare): Declare.
10087 * c.opt (Wbool-compare): New option.
10088
35aff4fb
MP
100892014-08-19 Marek Polacek <polacek@redhat.com>
10090
10091 * c.opt (Wc99-c11-compat): New option.
10092
177cce46
MP
100932014-08-19 Marek Polacek <polacek@redhat.com>
10094
10095 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
10096 to warn_c90_c99_compat.
10097 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
10098 to -1.
10099
6ae9194f
MLI
101002014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
10101 Steven Bosscher <steven@gcc.gnu.org>
10102
10103 PR c/52952
10104 * c-format.c: Add extra_arg_loc and format_string_loc to struct
10105 format_check_results.
10106 (check_function_format): Use true and add comment for boolean
10107 argument.
10108 (finish_dollar_format_checking): Use explicit location when warning.
10109 (check_format_info): Likewise.
10110 (check_format_arg): Set extra_arg_loc and format_string_loc.
10111 (check_format_info_main): Use explicit location when warning.
10112 (check_format_types): Pass explicit location.
10113 (format_type_warning): Likewise.
10114
8e54f6d3
MLI
101152014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
10116
10117 PR fortran/44054
10118 * c-format.c: Handle Fortran flags.
10119
cd4e76fc
IZ
101202014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
10121
10122 PR other/61962
10123 * array-notation-common.c (find_rank): Added handling for other
10124 types of references.
10125
f3bede71
MP
101262014-08-10 Marek Polacek <polacek@redhat.com>
10127
10128 PR c/51849
10129 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
10130 * c.opt (Wc90-c99-compat): Add option.
10131
9f25a338
TS
101322014-08-07 Trevor Saunders <tsaunders@mozilla.com>
10133
10134 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
10135
62e4eb35
MP
101362014-08-03 Marek Polacek <polacek@redhat.com>
10137
ab20d992 10138 * c-common.c (check_case_value): Add location_t parameter. Use it.
62e4eb35
MP
10139 (c_add_case_label): Pass loc to check_case_value.
10140
b787e7a2
TS
101412014-08-02 Trevor Saunders <tsaunders@mozilla.com>
10142
10143 * cilk.c: Use hash_map instead of pointer_map.
10144
6e2830c3
TS
101452014-08-02 Trevor Saunders <tsaunders@mozilla.com>
10146
10147 * c-gimplify.c: Use hash_set instead of pointer_set.
10148
a7ee52fb
IZ
101492014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
10150
10151 PR middle-end/61455
10152 * array-notation-common.c (extract_array_notation_exprs): Handling
10153 of DECL_EXPR added.
10154
944fa280
JJ
101552014-08-01 Jakub Jelinek <jakub@redhat.com>
10156
10157 * c-common.h (min_align_of_type): Removed prototype.
10158 * c-common.c (min_align_of_type): Removed.
10159 * c-ubsan.h (ubsan_maybe_instrument_reference,
10160 ubsan_maybe_instrument_member_call): New prototypes.
10161 * c-ubsan.c: Include stor-layout.h and builtins.h.
10162 (ubsan_maybe_instrument_reference_or_call,
10163 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
10164 functions.
10165
b4dfdc11
MG
101662014-07-31 Marc Glisse <marc.glisse@inria.fr>
10167
10168 PR c++/60517
10169 * c.opt (-Wreturn-local-addr): Move to common.opt.
10170
a41844e5
JM
101712014-07-30 Jason Merrill <jason@redhat.com>
10172
10173 PR c++/61659
10174 PR c++/61687
10175 Revert:
10176 * c.opt (-fuse-all-virtuals): New.
10177
976d5a22
TT
101782014-07-30 Tom Tromey <tromey@redhat.com>
10179
10180 PR c/59855
10181 * c.opt (Wdesignated-init): New option.
10182 * c-common.c (c_common_attribute_table): Add "designated_init".
10183 (handle_designated_init): New function.
10184
cdc94aca
MP
101852014-07-24 Marek Polacek <polacek@redhat.com>
10186
10187 PR c/57653
10188 * c-opts.c (c_finish_options): If -imacros is in effect, return.
10189
f41373b6
DS
101902014-07-16 Dodji Seketeli <dodji@redhat.com>
10191
10192 PR preprocessor/60723 - missing system-ness marks for macro tokens
10193 * c-ppoutput.c (struct print::prev_was_system_token): New data
10194 member.
10195 (init_pp_output): Initialize it.
10196 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
10197 (do_line_change): Return a flag saying if a line marker was
10198 emitted or not.
10199 (scan_translation_unit): Detect if the system-ness of the token we
10200 are about to emit is different from the one of the previously
10201 emitted token. If so, emit a line marker. Avoid emitting useless
10202 adjacent line markers. Avoid emitting line markers for tokens
10203 originating from the expansion of built-in macros.
10204 (scan_translation_unit_directives_only): Adjust.
10205
4d661eaa
MP
102062014-07-15 Marek Polacek <polacek@redhat.com>
10207
10208 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
10209 TYPE_MAX_VALUE is NULL.
10210
b108f48f
JJ
102112014-07-14 Jakub Jelinek <jakub@redhat.com>
10212
10213 PR middle-end/61294
10214 * c.opt (Wmemset-transposed-args): New warning.
10215
c0221884
JM
102162014-07-10 Jason Merrill <jason@redhat.com>
10217
10218 PR c++/61659
10219 PR c++/61687
10220 * c.opt (-fuse-all-virtuals): New.
10221
63dfbb95
RB
102222014-07-09 Richard Biener <rguenther@suse.de>
10223
10224 PR c-family/61741
10225 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
10226 using unsigned arithmetic if overflow does not wrap instead of
10227 if overflow is undefined.
10228
773ec47f
MP
102292014-07-06 Marek Polacek <polacek@redhat.com>
10230
10231 PR c/6940
10232 * c.opt (Wsizeof-array-argument): New option.
10233
00a7ba58
JJ
102342014-07-03 Jakub Jelinek <jakub@redhat.com>
10235
b1726d6c 10236 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
00a7ba58
JJ
10237 comments->count <= 1, as comments->entries might be NULL.
10238
52ec0ea3
MP
102392014-07-01 Marek Polacek <polacek@redhat.com>
10240
10241 * c.opt (Wint-conversion): New option.
10242
d5c3d343
MP
102432014-07-01 Marek Polacek <polacek@redhat.com>
10244
10245 PR c/58286
10246 * c.opt (Wincompatible-pointer-types): New option.
10247
6e7ceb17
PC
102482014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
10249
10250 PR c++/51400
10251 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
10252 Do not discard TYPE_QUALS of type.
10253
da73100b
JM
102542014-06-26 Jason Merrill <jason@redhat.com>
10255
10256 * c-common.h (enum cxx_dialect): Add cxx1z.
10257 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
10258 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
10259
08eedf75
TJ
102602014-06-26 Teresa Johnson <tejohnson@google.com>
10261
10262 * c-common.h (get_dump_info): Declare.
10263 * c-gimplify.c (c_genericize): Use saved dump files.
10264 * c-opts.c (c_common_parse_file): Begin and end dumps
10265 once around parsing invocation.
10266 (get_dump_info): New function.
10267
7b56b2f8
MP
102682014-06-23 Marek Polacek <polacek@redhat.com>
10269 Andrew MacLeod <amacleod@redhat.com>
10270
10271 PR c/61553
10272 * c-common.c (get_atomic_generic_size): Don't segfault if the
10273 type doesn't have a size.
10274
0e37a2f3
MP
102752014-06-20 Marek Polacek <polacek@redhat.com>
10276
10277 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
10278 (ubsan_walk_array_refs_r): New function.
10279 (c_genericize): Instrument array bounds.
10280 * c-ubsan.c: Include "internal-fn.h".
10281 (ubsan_instrument_division): Mark instrumented arrays as having
10282 side effects. Adjust ubsan_type_descriptor call.
10283 (ubsan_instrument_shift): Likewise.
10284 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
10285 (ubsan_instrument_bounds): New function.
10286 (ubsan_array_ref_instrumented_p): New function.
10287 (ubsan_maybe_instrument_array_ref): New function.
10288 * c-ubsan.h (ubsan_instrument_bounds): Declare.
10289 (ubsan_array_ref_instrumented_p): Declare.
10290 (ubsan_maybe_instrument_array_ref): Declare.
10291
102922014-06-20 Hale Wang <hale.wang@arm.com>
dd6fe7d4
HW
10293
10294 PR lto/61123
10295 * c.opt (fshort-enums): Add to LTO.
10296 * c.opt (fshort-wchar): Likewise.
10297
5c3d09f7
MP
102982014-06-16 Marek Polacek <polacek@redhat.com>
10299
10300 PR c/60439
10301 * c.opt (Wswitch-bool): Add Var.
10302
9cf32741
JJ
103032014-06-12 Jakub Jelinek <jakub@redhat.com>
10304
10305 PR middle-end/61486
10306 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
10307 #pragma omp target teams or
10308 #pragma omp {,target }teams distribute simd.
10309
62984918
JM
103102014-06-12 Jason Merrill <jason@redhat.com>
10311
10312 * c.opt (Wabi=, fabi-compat-version): New.
10313 * c-opts.c (c_common_handle_option): Handle -Wabi=.
10314 (c_common_post_options): Handle flag_abi_compat_version default.
10315 Disallow -fabi-compat-version=1.
10316 * c-common.h (abi_version_crosses): New.
10317
f961457f
JH
103182014-06-11 Jan Hubicka <hubicka@ucw.cz>
10319
adfac8df 10320 * c-common.c (handle_section_attribute): Update handling for
f961457f
JH
10321 section names that are no longer trees.
10322
92d28cbb
JJ
103232014-06-10 Jakub Jelinek <jakub@redhat.com>
10324
10325 PR fortran/60928
10326 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
10327 (omp_pragmas): ... back here.
10328
742938c9
MP
103292014-06-05 Marek Polacek <polacek@redhat.com>
10330
10331 PR c/49706
10332 * c-common.c (warn_logical_not_parentheses): New function.
10333 * c-common.h (warn_logical_not_parentheses): Declare.
10334 * c.opt (Wlogical-not-parentheses): New option.
10335
9d548dfb
MP
103362014-06-04 Marek Polacek <polacek@redhat.com>
10337
10338 PR c/30020
10339 * c-common.c (check_case_bounds): Add location parameter.
10340 Use it.
10341 (c_add_case_label): Pass loc to check_case_bounds.
10342
fedfecef
MP
103432014-06-03 Marek Polacek <polacek@redhat.com>
10344
10345 PR c/60439
10346 * c.opt (Wswitch-bool): New option.
10347
f6a7cffc
TS
103482014-05-22 Thomas Schwinge <thomas@codesourcery.com>
10349
040d18b6
TS
10350 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
10351 Remove prototypes.
10352 (record_types_used_by_current_var_decl): Move prototype to where
10353 it belongs.
10354
f6a7cffc
TS
10355 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
10356 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
10357 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
10358
632f2871
RS
103592014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
10360
10361 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
10362 * c-common.c (c_common_nodes_and_builtins): Don't initialize
10363 void_zero_node.
10364 * c-pretty-print.c (pp_c_void_constant): New function.
10365 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
10366 (c_pretty_printer::expression): Handle VOID_CST.
10367 * cilk.c (extract_free_variables): Likewise.
10368 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
10369 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
10370
766090c2
TS
103712014-05-17 Trevor Saunders <tsaunders@mozilla.com>
10372
10373 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
10374 * c-pragma.c (push_alignment): Adjust.
10375 (handle_pragma_push_options): Likewise.
10376
661a0813
MP
103772014-05-09 Marek Polacek <polacek@redhat.com>
10378
10379 PR c/50459
10380 * c-common.c (check_user_alignment): Return -1 if alignment is error
10381 node.
10382 (handle_aligned_attribute): Don't call default_conversion on
10383 FUNCTION_DECLs.
10384 (handle_vector_size_attribute): Likewise.
10385 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
10386 (handle_sentinel_attribute): Call default_conversion and allow even
10387 integral types as an argument.
10388
2793eeab
MP
103892014-05-08 Marek Polacek <polacek@redhat.com>
10390
10391 PR c/61053
10392 * c-common.c (min_align_of_type): New function factored out from...
10393 (c_sizeof_or_alignof_type): ...here.
10394 * c-common.h (min_align_of_type): Declare.
10395
f827930a
MP
103962014-05-08 Marek Polacek <polacek@redhat.com>
10397
10398 PR c/61077
10399 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
10400 parameter type of main.
10401
ca49b74e
DD
104022014-05-07 DJ Delorie <dj@redhat.com>
10403
10404 * c-cppbuiltin.c (print_bits_of_hex): New.
10405 (builtin_define_type_minmax): Print values using hex so as not to
10406 require a pre-computed list of string values.
10407
1d60af08
KZ
104082014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
10409 Mike Stump <mikestump@comcast.net>
10410 Richard Sandiford <rdsandiford@googlemail.com>
10411
10412 * c-ada-spec.c: Include wide-int.h.
10413 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
10414 (dump_generic_ada_node): Use wide-int interfaces.
10415 * c-common.c: Include wide-int-print.h.
10416 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
10417 (pointer_int_sum): Use wide-int interfaces.
10418 (c_common_nodes_and_builtins): Use make_int_cst.
10419 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
10420 (handle_alloc_size_attribute): Use wide-int interfaces.
10421 (get_nonnull_operand): Likewise.
10422 * c-format.c (get_constant): Use tree_fits_uhwi_p.
10423 * c-lex.c: Include wide-int.h.
10424 (narrowest_unsigned_type): Take a widest_int rather than two
10425 HOST_WIDE_INTs.
10426 (narrowest_signed_type): Likewise.
10427 (interpret_integer): Update accordingly. Use wide-int interfaces.
10428 (lex_charconst): Use wide-int interfaces.
10429 * c-pretty-print.c: Include wide-int.h.
10430 (pp_c_integer_constant): Use wide-int interfaces.
10431 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
10432 INT_CST_LT_UNSIGNED.
10433
b15458be
RB
104342014-05-06 Richard Biener <rguenther@suse.de>
10435
10436 * c-opts.c (c_common_post_options): For -freestanding,
10437 -fno-hosted and -fno-builtin disable pattern recognition
10438 if not enabled explicitely.
10439
6577374e
MP
104402014-05-02 Marek Polacek <polacek@redhat.com>
10441
10442 * c.opt (Wsizeof-pointer-memaccess): Describe option.
10443
d00887e8
MP
104442014-05-01 Marek Polacek <polacek@redhat.com>
10445
10446 PR c/43245
10447 * c.opt (Wdiscarded-qualifiers): Add.
10448
f8ed5150
MP
104492014-04-30 Marek Polacek <polacek@redhat.com>
10450
10451 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
10452 INT_MIN / -1 sanitization only for integer types.
10453
45484dcf
MP
104542014-04-25 Marek Polacek <polacek@redhat.com>
10455
10456 PR c/18079
10457 * c-common.c (handle_noinline_attribute): Warn if the attribute
10458 conflicts with always_inline attribute.
10459 (handle_always_inline_attribute): Warn if the attribute conflicts
10460 with noinline attribute.
10461
38e514c0
MP
104622014-04-25 Marek Polacek <polacek@redhat.com>
10463
10464 PR c/60156
10465 * c-common.c (check_main_parameter_types): Warn about variadic main.
10466
44875f92
MS
104672014-04-24 Mike Stump <mikestump@comcast.net>
10468
10469 * c.opt (Wshadow-ivar): Default to on.
10470
dcaaa5a0
DP
104712014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
10472
10473 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
10474
c07d7c02
MP
104752014-04-23 Marek Polacek <polacek@redhat.com>
10476
10477 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
10478
1c33c9b7
JJ
104792014-04-22 Jakub Jelinek <jakub@redhat.com>
10480
10481 PR sanitizer/60275
10482 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
10483 if flag_sanitize_undefined_trap_on_error.
10484 (ubsan_instrument_division, ubsan_instrument_shift,
10485 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
10486 if !flag_sanitize_recover.
10487
793c625f
MG
104882014-04-22 Marc Glisse <marc.glisse@inria.fr>
10489
10490 PR libstdc++/43622
10491 * c-common.c (registered_builtin_types): Make non-static.
10492 * c-common.h (registered_builtin_types): Declare.
10493
b0f1bf36 104942014-04-14 Richard Biener <rguenther@suse.de>
ab20d992 10495 Marc Glisse <marc.glisse@inria.fr>
b0f1bf36
RB
10496
10497 PR c/60819
10498 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
10499 apply may-alias the scalar pointer type when applicable.
10500
3b07fa4a
IZ
105012014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
10502
10503 PR middle-end/60467
10504 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
10505 as possible argument for Cilk_spawn.
10506
cbbd2b1c
TB
105072014-04-11 Tobias Burnus <burnus@net-b.de>
10508
10509 PR c/60194
10510 * c.opt (Wformat-signedness): Add
10511 * c-format.c(check_format_types): Use it.
10512
6415bd5d
JM
105132014-04-11 Jason Merrill <jason@redhat.com>
10514
10515 PR c++/57926
10516 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
10517 default_conversion for an array argument.
10518
6525783a
MP
105192014-04-08 Marek Polacek <polacek@redhat.com>
10520
10521 PR sanitizer/60745
10522 * c-ubsan.c: Include asan.h.
10523 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
10524
880a467b
NS
105252014-04-03 Nathan Sidwell <nathan@codesourcery.com>
10526
10527 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
10528
7b59ff2d
MP
105292014-04-02 Marek Polacek <polacek@redhat.com>
10530
10531 * c-common.h (c_expand_expr): Remove declaration.
10532
8edbfaa6
JJ
105332014-03-28 Jakub Jelinek <jakub@redhat.com>
10534
10535 PR c++/60689
10536 * c-common.c (add_atomic_size_parameter): When creating new
10537 params vector, push the size argument first.
10538
07d72e1d
JJ
105392014-03-26 Jakub Jelinek <jakub@redhat.com>
10540
10541 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
10542 ubsan_instrument_vla, ubsan_instrument_return): Adjust
10543 ubsan_create_data callers.
10544
b35e0fa0
JJ
105452014-03-22 Jakub Jelinek <jakub@redhat.com>
10546
10547 PR debug/60603
10548 * c-opts.c (c_finish_options): Restore cb_file_change call to
10549 <built-in>.
10550
39a1ebb3
JJ
105512014-03-13 Jakub Jelinek <jakub@redhat.com>
10552
10553 PR middle-end/36282
10554 * c-pragma.c (apply_pragma_weak): Only look at
10555 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
10556 DECL_ASSEMBLER_NAME_SET_P (decl).
10557 (maybe_apply_pending_pragma_weaks): Exit early if
10558 vec_safe_is_empty (pending_weaks) rather than only when
10559 !pending_weaks.
10560 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
10561 set assembler name back to NULL afterwards.
10562
a07f6ed2
JM
105632014-03-11 Jason Merrill <jason@redhat.com>
10564
10565 * c.opt: Add -std=gnu++14.
10566
75b107f5
IB
105672014-03-11 Ian Bolton <ian.bolton@arm.com>
10568
10569 * c-opts.c (c_common_post_options): Don't override
10570 -ffp-contract=fast if unsafe-math-optimizations is on.
10571
f42c637e
PM
105722014-03-08 Paulo Matos <paulo@matos-sorge.com>
10573
22b15758 10574 * c.opt: Enable LTO FE for fshort-double.
f42c637e 10575
70e24808
JM
105762014-03-07 Jason Merrill <jason@redhat.com>
10577
10578 * c.opt: Add -std=c++14.
10579
3af9c5e9
MP
105802014-03-06 Marek Polacek <polacek@redhat.com>
10581
10582 PR c/60197
10583 * cilk.c (contains_cilk_spawn_stmt): New function.
10584 (contains_cilk_spawn_stmt_walker): Likewise.
10585 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
10586 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
10587
b3bdf019
JJ
105882014-03-03 Jakub Jelinek <jakub@redhat.com>
10589
10590 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
10591 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
10592 even when flag_preprocess_only.
10593
ca7e759d
JM
105942014-02-26 Jason Merrill <jason@redhat.com>
10595
10596 PR c++/59231
10597 PR c++/11586
10598 * c-common.c (shorten_compare): Don't check
10599 c_inhibit_evaluation_warnings.
10600
28e41874
JJ
106012014-02-19 Jakub Jelinek <jakub@redhat.com>
10602
cca615af
JJ
10603 PR c/37743
10604 * c-common.c (c_common_nodes_and_builtins): When initializing
10605 c_uint{16,32,64}_type_node, also set corresponding
10606 uint{16,32,64}_type_node to the same value.
10607
28e41874
JJ
10608 PR c++/60267
10609 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
10610 for PRAGMA_IVDEP if flag_preprocess_only.
10611
c2bf53a1
JJ
106122014-02-12 Jakub Jelinek <jakub@redhat.com>
10613
10614 PR c/60101
10615 * c-common.c (merge_tlist): If copy is true, call new_tlist,
10616 if false, add ADD itself, rather than vice versa.
10617 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
10618 copy. For SAVE_EXPR, only call merge_tlist once.
10619
8fcbce72
JJ
106202014-02-08 Jakub Jelinek <jakub@redhat.com>
10621
10622 PR middle-end/60092
10623 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
10624 and tree_to_uhwi.
10625 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
10626 functions.
10627 (c_common_attribute_table): Add alloc_align and assume_aligned
10628 attributes.
10629
0a756a3f
MP
106302014-02-06 Marek Polacek <polacek@redhat.com>
10631
10632 PR c/60087
10633 * c-common.c (warn_for_sign_compare): Call warning_at with location
10634 instead of warning.
10635
7ec4847a
MP
106362014-02-05 Marek Polacek <polacek@redhat.com>
10637
10638 PR c/53123
10639 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
10640 statement.
10641
66f20604
MP
106422014-02-04 Marek Polacek <polacek@redhat.com>
10643
10644 PR c/60036
10645 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
10646 SAVE_EXPR.
10647
5d77fb19
MG
106482014-02-03 Marc Glisse <marc.glisse@inria.fr>
10649
10650 PR c++/53017
10651 PR c++/59211
10652 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
10653 handle_vector_size_attribute, handle_nonnull_attribute): Call
10654 default_conversion on the attribute argument.
10655 (handle_nonnull_attribute): Increment the argument number.
10656
81e5eca8
MP
106572014-01-31 Marek Polacek <polacek@redhat.com>
10658
10659 PR c/59963
10660 * c-common.c (add_atomic_size_parameter): Pass vNULL to
10661 build_function_call_vec.
10662 (resolve_overloaded_builtin): Likewise.
10663 * c-common.h (build_function_call_vec): Adjust declaration.
10664
68fca595
MP
106652014-01-30 Marek Polacek <polacek@redhat.com>
10666
10667 PR c/59940
10668 * c-common.h (unsafe_conversion_p): Adjust declaration.
10669 (warnings_for_convert_and_check): Likewise.
10670 (convert_and_check): Likewise.
10671 * c-common.c (unsafe_conversion_p): Add location parameter. Call
10672 expansion_point_location_if_in_system_header on it.
10673 (warnings_for_convert_and_check): Add location parameter. Call
10674 expansion_point_location_if_in_system_header on it. Use it.
10675 (convert_and_check): Add location parameter. Use it.
10676 (conversion_warning): Likewise.
10677 (c_add_case_label): Adjust convert_and_check calls.
10678 (scalar_to_vector): Adjust unsafe_conversion_p calls.
10679
b72271b9
BI
106802014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
10681
10682 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
10683 flag_cilkplus.
10684 * c-pragma.c (init_pragma): Likewise.
10685 * c.opt: Likewise.
10686
393e8e8b
MP
106872014-01-23 Marek Polacek <polacek@redhat.com>
10688
10689 PR c/59846
10690 * c-common.c (shorten_compare): Add location_t parameter.
10691 * c-common.h (shorten_binary_op): Adjust declaration.
10692
f04dda30
MP
106932014-01-23 Marek Polacek <polacek@redhat.com>
10694
10695 PR c/58346
10696 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
10697 * c-common.h: Declare it.
10698
621955cb
EB
106992014-01-20 Eric Botcazou <ebotcazou@adacore.com>
10700
10701 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
10702 * c-ada-spec.c (dump_ads): Likewise.
10703 (cpp_check): Likewise.
10704 (dump_ada_specs): Likewise.
10705
107062014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
67bf2939
LA
10707
10708 PR c++/49718
10709 * c-common.c (handle_no_instrument_function_attribute): Allow
10710 no_instrument_function attribute in class member
10711 definition/declaration.
10712
241f845a
JJ
107132014-01-15 Jakub Jelinek <jakub@redhat.com>
10714
10715 PR c/58943
10716 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
10717 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
10718 being COMPOUND_EXPR.
10719 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
10720 operand a SAVE_EXPR and second MODIFY_EXPR.
10721
e83b8e2e
JJ
107222014-01-09 Jakub Jelinek <jakub@redhat.com>
10723
10724 PR target/58115
10725 * c-pch.c (c_common_write_pch): Call
10726 prepare_target_option_nodes_for_pch.
10727
23a5b65a
RS
107282014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
10729
10730 Update copyright years
10731
f9030485
RS
107322014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
10733
10734 * array-notation-common.c, c-cilkplus.c: Use the standard form for
10735 the copyright notice.
10736
f2aa696b
EB
107372013-12-28 Eric Botcazou <ebotcazou@adacore.com>
10738
10739 * c-ada-spec.c (print_constructor): New function.
10740 (print_destructor): Retrieve the origin of the destructor.
10741 (print_ada_declaration): Revamp handling of constructors/destructors.
10742
3f8257db 107432013-12-23 Stuart Hastings <stuart@apple.com>
1f26ac87
JM
10744 Bill Maddox <maddox@google.com>
10745 Jason Merrill <jason@redhat.com>
10746
10747 * c.opt: Add -fdeclone-ctor-dtor.
10748 * c-opts.c (c_common_post_options): Default to on iff -Os.
10749
41958c28
BI
107502013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
10751
10752 * c-common.c (c_common_attribute_table): Added "cilk simd function"
10753 attribute.
10754 * c-pragma.h (enum pragma_cilk_clause): Remove.
ab20d992 10755 (enum pragma_omp_clause): Added the following fields:
41958c28
BI
10756 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
10757 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
10758 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
10759 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
10760 PRAGMA_CILK_CLAUSE_UNIFORM.
10761
b1726d6c 10762
12893402
BI
107632013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
10764
10765 * cilk.c (cilk_outline): Made this function non-static.
10766 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
10767 (create_cilk_wrapper): Added a new parameter: a function pointer.
10768 (c_install_body_w_frame_cleanup): Remove
10769 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
10770 * c-common.h (cilk_outline): New prototype.
10771 (gimplify_cilk_spawn): Removed two parameters.
10772 (cilk_install_body_with_frame_cleanup): New prototype.
10773 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
10774 CILK_SPAWN_STMT case.
10775
085b42ed
BS
107762013-12-11 Bernd Schmidt <bernds@codesourcery.com>
10777
2ce064c3
BS
10778 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
10779
085b42ed
BS
10780 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
10781 (int_array_type_node): Remove.
10782 * c-common.c (c_common_nodes_and_builtins): Don't build it.
10783
9e36c9ed
MP
107842013-12-05 Marek Polacek <polacek@redhat.com>
10785
10786 PR c/52023
10787 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
10788 [ADJUST_FIELD_ALIGN].
10789
296674db
JM
107902013-12-04 Joseph Myers <joseph@codesourcery.com>
10791
10792 PR c/52023
10793 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
10794 and check field alignment if set.
10795 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
10796 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
10797
b1726d6c 107982013-12-04 Jakub Jelinek <jakub@redhat.com>
31e071ae
MP
10799 Marek Polacek <polacek@redhat.com>
10800
10801 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
10802 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
10803
d7947e19
L
108042013-11-29 H.J. Lu <hongjiu.lu@intel.com>
10805
10806 PR c/59309
10807 * cilk.c (gimplify_cilk_spawn): Properly handle function without
10808 arguments.
10809
fad7652e
JJ
108102013-11-29 Jakub Jelinek <jakub@redhat.com>
10811
10812 PR c/59280
10813 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
10814 goto invalid. If it is error_mark_node, don't issue further
10815 diagnostics.
10816
8b5e1202
SO
108172013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
10818
10819 * c.opt (Wopenmp-simd): New.
10820
0a508bb6
JJ
108212013-11-22 Jakub Jelinek <jakub@redhat.com>
10822
10823 * c-ubsan.h (ubsan_instrument_return): New prototype.
10824 * c-ubsan.c (ubsan_instrument_return): New function.
10825
2fb9a547
AM
108262013-11-22 Andrew MacLeod <amacleod@redhat.com>
10827
10828 * c-common.c: Add required include files from gimple.h.
ab20d992
JJ
10829 * c-gimplify.c: Likewise.
10830 * cilk.c: Likewise.
2fb9a547 10831
8400e75e
DM
108322013-11-22 David Malcolm <dmalcolm@redhat.com>
10833
10834 * c-common.c (unsafe_conversion_p): Remove use of
10835 EXPR_LOC_OR_HERE macro.
10836 (conversion_warning): Likewise.
10837 (warnings_for_convert_and_check): Likewise.
10838 (warn_for_collisions_1): Likewise.
10839 (shorten_compare): Likewise, and remove use of in_system_header
10840 macro, using the location from the former.
10841 * c-lex.c (dump_one_header): Remove use of input_filename macro.
10842 (cb_def_pragma): Remove use of in_system_header macro.
10843 (lex_string): Likewise.
10844 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
10845
eb1ce453
KZ
108462013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
10847 Mike Stump <mikestump@comcast.net>
10848 Richard Sandiford <rdsandiford@googlemail.com>
10849
10850 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
10851 instead of TREE_INT_CST_LOW, in cases where there is a protecting
10852 tree_fits_shwi_p or tree_fits_uhwi_p.
10853 (dump_generic_ada_node): Likewise.
10854 * c-format.c (check_format_arg): Likewise.
10855 * c-pretty-print.c (pp_c_integer_constant): Likewise.
10856
6b3b8c27
KZ
108572013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
10858
10859 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
10860
49b0aa18
JC
108612013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
10862
10863 PR c/53001
10864 * c-common.c (unsafe_conversion_p): Make this function
10865 return an enumeration with more detail.
10866 (conversion_warning): Use the new return type of
10867 unsafe_conversion_p to separately warn either about conversions
10868 that lower floating point number precision or about the other
10869 kinds of conversions.
10870 * c-common.h (enum conversion_safety): New enumeration.
8e745a17
JJ
10871 (unsafe_conversion_p): switching return type to
10872 conversion_safety enumeration.
49b0aa18
JC
10873 * c.opt: Adding new warning -Wfloat-conversion and
10874 enabling it with -Wconversion.
10875
b826515a
BS
108762013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
10877
8e745a17
JJ
10878 * c-opts.c: Include plugin.h.
10879 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
b826515a 10880
b9a55b13
MP
108812013-11-19 Marek Polacek <polacek@redhat.com>
10882
10883 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
10884 call.
10885 (ubsan_instrument_shift): Likewise.
10886 (ubsan_instrument_vla): Likewise.
10887
7d362f6c
RS
108882013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10889
10890 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
10891 cast to unsigned type.
10892
386b1f1f
RS
108932013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10894
10895 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
10896 tree_low_cst.
10897 (complete_array_type): Update comment to refer to tree_to_[su]hwi
10898 rather than tree_low_cst.
10899
ae7e9ddd
RS
109002013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10901
10902 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
10903 tree_to_uhwi throughout.
10904
9439e9a1
RS
109052013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10906
10907 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
10908 tree_low_cst (..., 0) with tree_to_shwi throughout.
10909
cc269bb6
RS
109102013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10911
10912 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
10913 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
10914
9541ffee
RS
109152013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10916
10917 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
10918 host_integerp (..., 0) with tree_fits_shwi_p throughout.
10919
c02065fc
AH
109202013-11-15 Aldy Hernandez <aldyh@redhat.com>
10921
10922 * c-cilkplus.c: New file.
10923 * c-common.c (readonly_error): Add location argument.
10924 * c-common.h (readonly_error): Same.
10925 (c_finish_cilk_clauses): Protoize.
10926 (c_check_cilk_loop): Same.
10927 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
10928 Do not fail on error_mark_node.
10929 Abstract increment canonicalization to here...
10930 (c_omp_for_incr_canonicalize_ptr): New.
10931 c-pragma.c (init_pragma): Register "simd" pragma.
10932 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
10933 (enum pragma_cilk_clause): New.
10934
9cc65f15
RS
109352013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
10936
10937 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
10938 wchar_type and host_integerp checks.
10939
18f429e2
AM
109402013-11-14 Andrew MacLeod <amacleod@redhat.com>
10941
10942 * c-common.c: Likewise.
10943 * c-gimplify.c: Likewise.
10944 * cilk.c: Likewise.
10945
d8a2d370
DN
109462013-11-14 Diego Novillo <dnovillo@google.com>
10947
10948 * c-common.c: Include fold-const.h.
10949 Include stor-layout.h.
10950 Include calls.h.
10951 Include stringpool.h.
10952 Include attribs.h.
10953 Include varasm.h.
10954 Include trans-mem.h.
10955 * c-cppbuiltin.c: Include stor-layout.h.
10956 Include stringpool.h.
10957 * c-format.c: Include stringpool.h.
10958 * c-lex.c: Include stringpool.h.
10959 Include stor-layout.h.
10960 * c-pragma.c: Include stringpool.h.
10961 Include attribs.h.
10962 Include varasm.h.
10963 Include gcc-symtab.h.
10964 * c-pretty-print.c: Include stor-layout.h.
10965 Include attribs.h.
10966 * cilk.c: Include stringpool.h.
10967 Include calls.h.
10968
38b7bc7f
JM
109692013-11-13 Joseph Myers <joseph@codesourcery.com>
10970
10971 * c-common.h (enum rid): Add RID_AUTO_TYPE.
10972 * c-common.c (c_common_reswords): Add __auto_type.
10973 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
10974
45b0be94
AM
109752013-11-12 Andrew MacLeod <amacleod@redhat.com>
10976
18f429e2
AM
10977 * c-common.c: Include gimplify.h.
10978 * c-gimplify.c: Likewise.
10979 * cilk.c: Likewise.
10980 * c-omp.c: Include gimple-expr.h instead of gimple.h.
10981 * c-ubsan.c: Don't include gimple.h.
45b0be94 10982
582d9b50
JM
109832013-11-12 Joseph Myers <joseph@codesourcery.com>
10984
10985 * c-common.c (c_common_reswords): Add _Thread_local.
10986
6b28e197
JM
109872013-11-09 Joseph Myers <joseph@codesourcery.com>
10988
10989 * c-common.c (atomic_size_supported_p): New function.
10990 (resolve_overloaded_atomic_exchange)
10991 (resolve_overloaded_atomic_compare_exchange)
10992 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
10993 Use it instead of comparing size with a local list of sizes.
10994
267bac10
JM
109952013-11-07 Andrew MacLeod <amacleod@redhat.com>
10996 Joseph Myers <joseph@codesourcery.com>
10997
10998 * c-common.h (enum rid): Add RID_ATOMIC.
10999 * c-common.c (c_common_reswords): Add _Atomic.
11000 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
11001 (keyword_is_type_qualifier): Accept RID_ATOMIC.
11002 * c-format.c (check_format_types): Check for extra _Atomic
11003 qualifiers in format argument.
11004 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
11005 (pp_c_type_qualifier_list): Mention _Atomic in comment.
11006
5157b91e
TB
110072013-11-06 Tobias Burnus <burnus@net-b.de>
11008
11009 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
11010
6dbe0958
JM
110112013-11-06 Joseph Myers <joseph@codesourcery.com>
11012
11013 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
11014 standards modes.
11015 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
11016 to mean lack of IEEE 754 support.
11017
e8ff5196
TB
110182013-11-05 Tobias Burnus <burnus@net-b.de>
11019
11020 * c.opt (-Wdate-time): New option
11021 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
11022
254a0760
JM
110232013-11-05 Joseph Myers <joseph@codesourcery.com>
11024
11025 * c-cppbuiltin.c (cpp_iec_559_value): Test
11026 flag_excess_precision_cmdline not flag_excess_precision.
11027
6d7f7e0a
TB
110282013-11-05 Tobias Burnus <burnus@net-b.de>
11029
11030 * c.opt (fopenmp-simd): New option.
11031 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
11032 (omp_pragmas): ... this new struct.
11033 (c_pp_lookup_pragma): Also walk omp_pragmas.
11034 (init_pragma): Init pragmas for -fopenmp-simd.
11035
55a7f02f
MP
110362013-11-04 Marek Polacek <polacek@redhat.com>
11037
11038 PR c++/58979
11039 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
11040
9193fb05
JM
110412013-11-04 Joseph Myers <joseph@codesourcery.com>
11042
11043 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
11044 New functions.
11045 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
11046
94159ecf
EB
110472013-11-04 Eric Botcazou <ebotcazou@adacore.com>
11048
11049 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
11050 (dump_ada_specs): Adjust prototype of second callback.
11051 * c-ada-spec.c (cpp_check): New global variable.
11052 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
11053 (print_generic_ada_decl): Likewise.
11054 (has_static_fields): Change return type to bool and add guard.
11055 (has_nontrivial_methods): New predicate.
11056 (is_tagged_type): Change return type to bool.
11057 (separate_class_package): Call has_nontrivial_methods.
11058 (pp_ada_tree_identifier): Minor tweaks.
11059 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
11060 (dump_ada_array_domains): Likewise.
11061 (dump_ada_array_type): Likewise.
11062 (dump_template_types): Remove cpp_check parameter and do not pass it to
11063 dump_generic_ada_node.
11064 (dump_ada_template): Likewise.
11065 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
11066 recursively.
11067 (print_ada_methods): Change return type to integer. Remove cpp_check
11068 parameter and do not pass it down.
11069 (dump_nested_types): Remove cpp_check parameter and do not pass it to
11070 dump_generic_ada_node.
11071 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
11072 accessing methods.
11073 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
11074 down. Use has_nontrivial_methods to recognize C++ classes. Use return
11075 value of print_ada_methods.
11076 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
11077 Set cpp_check to it before invoking dump_ada_nodes.
11078 (dump_ada_specs): Likewise.
11079
b906f4ca
MP
110802013-11-03 Marek Polacek <polacek@redhat.com>
11081
11082 * c-ubsan.c: Don't include hash-table.h.
11083 (ubsan_instrument_vla): New function.
11084 * c-ubsan.h: Declare it.
11085
5e20cdc9
DM
110862013-10-31 David Malcolm <dmalcolm@redhat.com>
11087
11088 Automated part of renaming of symtab_node_base to symtab_node.
11089
11090 Patch autogenerated by rename_symtab.py from
11091 https://github.com/davidmalcolm/gcc-refactoring-scripts
11092 revision 58bb219cc090b2f4516a9297d868c245495ee622
11093
11094 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
11095 symtab_node_base to symtab_node.
11096
7057e645
ESR
110972013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
11098
8e745a17 11099 Implement C++14 digit separators.
7057e645
ESR
11100 * c-lex.c (interpret_float): Remove digit separators from scratch string
11101 before building real literal.
11102
193ea7bc
JJ
111032013-10-30 Jakub Jelinek <jakub@redhat.com>
11104
11105 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
11106
939b37da
BI
111072013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
11108
11109 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
11110 fields.
11111 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
11112 enabled.
11113 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
11114 (insert_cilk_frame): New prototype.
11115 (cilk_init_builtins): Likewise.
11116 (gimplify_cilk_spawn): Likewise.
11117 (c_cilk_install_body_w_frame_cleanup): Likewise.
11118 (cilk_detect_spawn_and_unwrap): Likewise.
11119 (cilk_set_spawn_marker): Likewise.
11120 (build_cilk_sync): Likewise.
11121 (build_cilk_spawn): Likewise.
11122 * cilk.c: New file.
11123
67348ccc
DM
111242013-10-29 David Malcolm <dmalcolm@redhat.com>
11125
11126 Patch autogenerated by refactor_symtab.py from
11127 https://github.com/davidmalcolm/gcc-refactoring-scripts
11128 revision 58bb219cc090b2f4516a9297d868c245495ee622
11129
11130 * c-gimplify.c (c_genericize): Update for conversion of symtab types
11131 to a true class hierarchy.
11132 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
11133
d570872d
RS
111342013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
11135
11136 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
11137
98906124
JL
111382013-10-26 Jeff Law <law@redhat.com>
11139
adfac8df
JJ
11140 * c-common.c (c_define_builtins): Remove mudflap support.
11141 * c.opt: Ignore and warn for mudflap options.
98906124 11142
d73749df 111432013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
11144
11145 PR other/33426
11146 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
11147 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
11148
3f04b1bb
JM
111492013-10-23 Jason Merrill <jason@redhat.com>
11150
11151 * c-format.c (gcc_cxxdiag_char_table): Add %X.
11152
acf0174b
JJ
111532013-10-11 Jakub Jelinek <jakub@redhat.com>
11154
acd15a28
JJ
11155 * c-common.h (omp_clause_mask::operator !=): New method.
11156 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
11157 instead of if (mask & something) tests everywhere.
11158
acf0174b
JJ
11159 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
11160 201307 instead of 201107.
11161 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
11162 (c_common_attribute_table): Add "omp declare target" and
11163 "omp declare simd" attributes.
11164 (handle_omp_declare_target_attribute,
11165 handle_omp_declare_simd_attribute): New functions.
11166 * c-omp.c: Include c-pragma.h.
11167 (c_finish_omp_taskgroup): New function.
11168 (c_finish_omp_atomic): Add swapped argument, if true,
11169 build the operation first with rhs, lhs arguments and use NOP_EXPR
11170 build_modify_expr.
11171 (c_finish_omp_for): Add code argument, pass it down to make_code.
11172 (c_omp_split_clauses): New function.
11173 (c_split_parallel_clauses): Removed.
11174 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
11175 c_omp_declare_simd_clauses_to_decls): New functions.
11176 * c-common.h (omp_clause_mask): New type.
11177 (OMP_CLAUSE_MASK_1): Define.
11178 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
11179 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
11180 omp_clause_mask::operator |, omp_clause_mask::operator &,
11181 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
11182 omp_clause_mask::operator ==): New methods.
11183 (enum c_omp_clause_split): New.
11184 (c_finish_omp_taskgroup): New prototype.
11185 (c_finish_omp_atomic): Add swapped argument.
11186 (c_finish_omp_for): Add code argument.
11187 (c_omp_split_clauses): New prototype.
11188 (c_split_parallel_clauses): Removed.
11189 (c_omp_declare_simd_clauses_to_numbers,
11190 c_omp_declare_simd_clauses_to_decls): New prototypes.
11191 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
11192 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
11193 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
11194 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
11195 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
11196 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
11197 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
11198 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
11199 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
11200 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
11201 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
11202 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
11203 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
11204 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
11205 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
11206 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
11207 PRAGMA_OMP_CLAUSE_UNIFORM.
11208
826cacfe
MG
112092013-10-09 Marc Glisse <marc.glisse@inria.fr>
11210
11211 PR tree-optimization/20318
11212 * c-common.c (handle_returns_nonnull_attribute): New function.
11213 (c_common_attribute_table): Add returns_nonnull.
11214
2284b034
MG
112152013-10-03 Marc Glisse <marc.glisse@inria.fr>
11216
11217 PR c++/19476
11218 * c.opt (fcheck-new): Move to common.opt.
11219
b56e9788
MP
112202013-09-25 Marek Polacek <polacek@redhat.com>
11221 Jakub Jelinek <jakub@redhat.com>
11222
11223 PR sanitizer/58413
11224 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
11225 an expression if we can prove it is correct.
11226 (ubsan_instrument_division): Likewise. Remove unnecessary
11227 check.
11228
ce6923c5
MP
112292013-09-18 Marek Polacek <polacek@redhat.com>
11230
11231 PR sanitizer/58411
11232 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
11233 Declare it.
11234 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
11235
fb5610fb
IS
112362013-09-14 Iain Sandoe <iain@codesourcery.com>
11237
11238 PR target/48094
11239 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
11240 fobjc-gc, freplace-objc-classes): Accept for LTO.
11241
88b0e79e
JC
112422013-09-13 Jacek Caban <jacek@codeweavers.com>
11243
11244 * c-target.def: New hook
11245
c9b0866a
PC
112462013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
11247
11248 PR c++/43452
11249 * c.opt (Wdelete-incomplete): Add.
11250
0af94e6f
JR
112512013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
11252
11253 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
11254 (vector_types_compatible_elements_p): New function.
11255 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
11256 declaration.
11257 (vector_types_compatible_elements_p): Declare.
11258
7c26172c
GDR
112592013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
11260
11261 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
11262 a virtual member function.
11263 (pp_simple_type_specifier): Remove.
11264 (pp_c_type_specifier): Likewise.
11265 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
11266 Rename from pp_c_type_specifier. Adjust.
11267 (c_pretty_printer::c_pretty_printer): Do not assign to
11268 simple_type_specifier.
11269
20059c8b
GDR
112702013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
11271
11272 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
11273 member function.
11274 (c_pretty_printer::storage_class_specifier): Likewise.
11275 (c_pretty_printer::initializer): Likewise.
11276 (pp_declaration): Remove.
11277 (pp_declaration_specifiers): Likewise.
11278 (pp_abstract_declarator): Likewise.
11279 (pp_declarator): Likewise.
11280 (pp_type_id): Likewise.
11281 (pp_statement): Likewise.
11282 (pp_constant): Likewise.
11283 (pp_id_expression): Likewise.
11284 (pp_primary_expression): Likewise.
11285 (pp_unary_expression): Likewise.
11286 (pp_multiplicative_expression): Likewise.
11287 (pp_conditional_expression): Likewise.
11288 (pp_assignment_expression): Likewise.
11289 (pp_expression): Likewise.
11290 (pp_c_type_id): Likewise.
11291 (pp_c_storage_class_specifier): Likewise.
11292 * c-pretty-print.c (pp_c_type_cast): Tidy.
11293 (pp_c_pointer): Likewise.
11294 (pp_c_type_specifier): Likewise.
11295 (pp_c_parameter_type_list): Likewise.
11296 (pp_c_function_definition): Likewise.
11297 (pp_c_init_declarator): Likewise.
11298 (pp_c_initializer_list): Likewise.
11299 (pp_c_constructor_elts): Likewise.
11300 (c_pretty_printer::direct_abstract_declarator): Likewise.
11301 (c_pretty_printer::declaration_specifiers): Likewise.
11302 (c_pretty_printer::primary_expression): Likewise.
11303 (c_pretty_printer::postfix_expression): Likewise.
11304 (c_pretty_printer::type_id): Rename from pp_c_type_id.
11305 (c_pretty_printer::storage_class_specifier): Rename from
11306 pp_c_storage_class_specifier.
11307 (c_pretty_printer::initializer): Rename from pp_c_initializer.
11308 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
11309 storage_class_specifier, initializer, offset_list, flags.
11310
de5a5fa1
MP
113112013-08-30 Marek Polacek <polacek@redhat.com>
11312
11313 * c-ubsan.c: New file.
11314 * c-ubsan.h: New file.
11315
8f0e4d72
GDR
113162013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
11317
11318 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
11319 member function.
11320 (c_pretty_printer::declaration_specifiers): Likewise.
11321 (c_pretty_printer::declarator): Likewise.
11322 (c_pretty_printer::abstract_declarator): Likewise.
11323 (c_pretty_printer::direct_abstract_declarator): Likewise.
11324 (c_pretty_printer::direct_declarator): Likewise.
11325 (c_pretty_printer::function_specifier): Likewise.
11326 (pp_declaration): Adjust.
11327 (pp_declaration_specifiers): Likewise.
11328 (pp_abstract_declarator): Likewise.
11329 (pp_direct_declarator): Likewise.
11330 (pp_function_specifier): Likewise.
11331 (pp_direct_abstract_declarator): Remove as unused.
11332 (pp_c_declaration): Remove.
11333 (pp_c_declaration_specifiers): Likewise.
11334 (pp_c_declarator): Likewise.
11335 (pp_c_direct_declarator): Likewise.
11336 (pp_c_function_specifier): Likewise.
11337 (pp_c_direct_abstract_declarator): Likewise.
11338 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
11339 from pp_c_abstract_declarator. Adjust.
ab20d992 11340 (c_pretty_printer::direct_abstract_declarator): Rename from
8f0e4d72
GDR
11341 pp_c_direct_abstract_declarator. Adjust.
11342 (c_pretty_printer::function_specifier): Rename from
11343 pp_c_function_specifier. Adjust.
11344 (c_pretty_printer::declaration_specifiers): Rename from
11345 pp_c_declaration_specifiers. Adjust.
11346 (c_pretty_printer::direct_declarator): Rename from
11347 pp_c_direct_declarator. Adjust.
11348 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
11349 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
11350 (c_pretty_printer::c_pretty_printer): Do not assign to
11351 declaration, declaration_specifiers, declarator,
11352 direct_declarator, direct_abstract_declarator, function_specifier.
11353
00d34d3a
GDR
113542013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
11355
11356 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
11357 virtual member function.
11358 (c_pretty_printer::multiplicative_expression): Likewise.
11359 (c_pretty_printer::conditional_expression): Likewise.
11360 (c_pretty_printer::assignment_expression): Likewise.
11361 (c_pretty_printer::expression): Likewise.
11362 (pp_unary_expression): Adjust.
11363 (pp_multiplicative_expression): Likewise.
11364 (pp_assignment_expression): Likewise.
11365 (pp_conditional_expression): Likewise.
11366 (pp_expression): Likewise.
11367 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
11368 from pp_c_unary_expression. Adjust.
11369 (c_pretty_printer::multiplicative_expression): Rename from
11370 pp_c_multiplicative_expression. Adjust.
11371 (c_pretty_printer::conditional_expression): Rename from
11372 pp_c_conditional_expression. Adjust.
11373 (c_pretty_printer::assignment_expression): Rename from
11374 pp_c_assignment_expression. Adjust.
11375 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
11376 (c_pretty_printer::c_pretty_printer): Do not assign to
11377 unary_expression, multiplicative_expression,
11378 conditional_expression, expression.
11379
fb22178f
GDR
113802013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
11381
11382 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
11383 virtual member function.
11384 (pp_postfix_expression): Adjust.
11385 (pp_c_postfix_expression): Remove.
11386 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
11387 from pp_c_postfix_expression. Adjust.
11388 (c_pretty_printer::c_pretty_printer): Do not assign to
11389 postfix_expression.
11390
7ecc2600
GDR
113912013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
11392
11393 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
11394 virtua member function.
11395 (pp_primary_expression): Adjust.
11396 (pp_c_primary_expression): Remove.
11397 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
11398 from pp_c_primary_expression. Adjust.
11399 (pp_c_initializer_list): Use pp_primary_expression.
11400 (c_pretty_printer::c_pretty_printer): Do not assign to
11401 primary_expression.
11402
0691175f
GDR
114032013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
11404
11405 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
11406 * c-pretty-print.c (M_): Remove.
11407 (c_pretty_printer::translate_string): Define.
11408 (pp_c_type_specifier): Use it.
11409 (pp_c_primary_expression): Likewise.
11410 (pp_c_expression): Likewise.
11411
66dfe4c4
GDR
114122013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
11413
11414 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
11415 virtual function.
11416 (pp_c_id_expression): Remove.
11417 (pp_id_expression): Adjust.
11418 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
11419 pp_c_id_expression. Adjust.
11420 (pp_c_postfix_expression): Use pp_id_expression.
11421 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
11422
ca43e9d5
GDR
114232013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
11424
11425 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
11426 member function.
11427 (pp_constant): Adjust.
11428 (pp_c_constant): Remove.
11429 * c-pretty-print.c (c_pretty_printer::constant): Rename from
11430 pp_c_constant. Adjust.
11431 (pp_c_constant)
11432 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
11433 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
11434
da6ca2b5
GDR
114352013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
11436
11437 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
11438 (c_pretty_printer::c_pretty_printer): Declare.
11439 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
11440 c_pretty_printer_init. Adjust.
11441 (print_c_tree): Do not call c_pretty_printer_init.
11442 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
11443
65a372f4
AC
114442013-08-09 Arnaud Charlet <charlet@adacore.com>
11445
11446 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
11447
fd9b0f32
PC
114482013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
11449
11450 PR c++/58080
11451 * c-common.c (pointer_int_sum): Add bool parameter.
11452 * c-common.h (pointer_int_sum): Adjust declaration.
11453
e0aec1e9
GDR
114542013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
11455
11456 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
11457 c_pretty_printer variable.
11458
b066401f
GDR
114592013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
11460
11461 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
11462 (pp_base): Remove.
11463 (pp_c_base): Likewise. Adjust users.
11464 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
11465 (pp_c_whitespace): Do not call pp_base.
11466 (pp_c_left_paren): Likewise.
11467 (pp_c_right_paren): Likewise.
11468 (pp_c_left_brace): Likewise.
11469 (pp_c_right_brace): Likewise.
11470 (pp_c_left_bracket): Likewise.
11471 (pp_c_right_bracket): Likewise.
11472 (pp_c_dot): Likewise.
11473 (pp_c_ampersand): Likewise.
11474 (pp_c_star): Likewise.
11475 (pp_c_arrow): Likewise.
11476 (pp_c_semicolon): Likewise.
11477 (pp_c_complement): Likewise.
11478 (pp_c_exclamation): Likewise.
11479 (pp_c_direct_declarator): Likewise.
11480 (pp_c_ws_string): Likewise.
11481 (pp_c_identifier): Likewise.
11482 (pp_c_statement): Likewise.
11483 (print_c_tree): Likewise.
11484
65e5a578
ESR
114852013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
11486
11487 PR c++/58072
11488 * c-common.c (c_parse_error): Catch user-defined literal tokens and
11489 provide useful error strings.
11490
137a1a27
GDR
114912013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
11492
11493 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
11494 printer functions instead of pp_string or operators and punctuators.
11495 (dump_generic_ada_node): Likewise.
11496 * c-pretty-print.c (pp_c_type_specifier): Likewise.
11497 (pp_c_relational_expression): Likewise.
11498 (pp_c_logical_or_expression): Likewise.
11499
07838b13
GDR
115002013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
11501
11502 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
11503 functions instead of pp_character.
11504 (pp_ada_tree_identifier): Likewise.
11505 (dump_ada_double_name): Likewise.
11506 (dump_ada_function_declaration): Likewise.
11507 (dump_ada_array_domains): Likewise.
11508 (dump_template_types): Likewise.
11509 (dump_generic_ada_node): Likewise.
11510 (print_ada_declaration): Likewise.
11511 (print_ada_struct_decl): Likewise.
11512 * c-pretty-print.c (pp_c_integer_constant): Likewise.
11513
433cc7b0
TT
115142013-07-23 Tom Tromey <tromey@redhat.com>
11515
11516 * c-common.h (enum rid) <RID_GENERIC>: New constant.
11517 * c-common.c (c_common_reswords): Add _Generic.
11518
688010ba
OB
115192013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
11520
11521 * c-common.c: Fix typos.
11522 * c-common.h: Likewise.
11523
2a99e5e6
LL
115242013-07-13 Lubos Lunak <l.lunak@suse.cz>
11525
11526 PR c++/55203
11527 * c-common.c (c_common_attribute_table): Add warn_unused.
11528 (handle_warn_unused_attribute): New.
11529
c26302d5
JJ
115302013-07-10 Jakub Jelinek <jakub@redhat.com>
11531
11532 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
11533 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
11534
dfeadaa0
PC
115352013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
11536
11537 PR c++/57869
11538 * c.opt: Add Wconditionally-supported.
11539
6a2fa4b2
GS
115402013-07-08 Graham Stott <graham.stott@btinternet.com>
11541
adfac8df 11542 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6a2fa4b2
GS
11543 unused variables l_length and l_node.
11544
ecdbd01a 115452013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
11546
11547 PR c/57821
11548 * c-common.c (complete_array_type): Delay folding first index
11549 like other indices. When folding, check for index overflow.
11550
bedc293e
MG
115512013-06-27 Marc Glisse <marc.glisse@inria.fr>
11552
11553 PR c++/57509
11554 * c-common.h (c_build_vec_perm_expr): New complain argument.
11555 * c-common.c (c_build_vec_perm_expr): Likewise.
11556 Use save_expr also in C++.
11557
604b2bfc
GDR
115582013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
11559
11560 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
11561 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
11562 * c-opts.c (c_common_post_options): Likewise.
11563
dfeadaa0 115642013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
713b46fa
BI
11565
11566 * array-notation-common.c (length_mismatch_in_expr): Changed the
11567 parameter type's from a dynamic array to a vec_tree. Also removed
11568 the size parameters.
11569 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
11570 the change above.
11571
2ce86d2e
BI
115722013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
11573
11574 * c-common.h (struct cilkplus_an_parts): New structure.
11575 (struct cilkplus_an_loop_parts): Likewise.
11576 (cilkplus_extract_an_triplets): New prototype.
11577 (fix_sec_implicit_args): Likewise.
11578 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
11579 (fix_sec_implicit_args): Likewise.
604b2bfc 11580
07a6825b
BI
115812013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
11582
11583 * array-notation-common.c (find_inv_trees): Removed an unwanted
11584 typecasting.
11585 * c-common.h (struct inv_list::additional_tcodes): Changed type from
11586 enum rid to enum tree_code.
11587
08346abd
JH
115882013-06-11 Jan Hubicka <jh@suse.cz>
11589
11590 * c-common.c (handle_alias_ifunc_attribute): Do not set
11591 DECL_EXTERNAL for weakref variables.
11592 * c-pragma.c (handle_pragma_weak): Make sure aliases
11593 are not declared as external.
11594
d60f1706
BI
115952013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
11596
11597 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
11598 function from c/c-array-notation.c.
11599 (is_cilkplus_reduce_builtin): Likewise.
11600 (find_rank): Likewise.
11601 (extract_array_notation_exprs): Likewise.
11602 (replace_array_notations): Likewise.
11603 (find_inv_trees): Likewise.
11604 (replace_inv_trees): Likewise.
11605 (contains_array_notation_expr): Likewise.
11606 (find_correct_array_notation_type): Likewise.
11607 * c-common.h (struct inv_list): Moved this struct from the file
11608 c/c-array-notation.c and added a new field called additional tcodes.
11609 (length_mismatch_in_expr_p): New prototype.
11610 (is_cilkplus_reduce_builtin): Likewise.
11611 (find_rank): Likewise.
11612 (extract_array_notation_exprs): Likewise.
11613 (replace_array_notation): Likewise.
11614 (find_inv_trees): Likewise.
11615 (replace_inv_trees): Likewise.
11616 (find_correct_array_notation_type): Likewise.
dfeadaa0 11617
36536d79
BI
116182013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
11619
11620 * c-common.c (c_define_builtins): When cilkplus is enabled, the
11621 function array_notation_init_builtins is called.
11622 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
11623 * c-common.def (ARRAY_NOTATION_REF): New tree.
11624 * c-common.h (build_array_notation_expr): New function declaration.
11625 (build_array_notation_ref): Likewise.
11626 (extract_sec_implicit_index_arg): New extern declaration.
11627 (is_sec_implicit_index_fn): Likewise.
11628 (ARRAY_NOTATION_CHECK): New define.
11629 (ARRAY_NOTATION_ARRAY): Likewise.
11630 (ARRAY_NOTATION_START): Likewise.
11631 (ARRAY_NOTATION_LENGTH): Likewise.
11632 (ARRAY_NOTATION_STRIDE): Likewise.
11633 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
11634 ARRAY_NOTATION_REF.
11635 (pp_c_expression): Likewise.
11636 * c.opt (flag_enable_cilkplus): New flag.
11637 * array-notation-common.c: New file.
11638
f7716d57
JJ
116392013-05-14 Jakub Jelinek <jakub@redhat.com>
11640
11641 PR c++/57274
11642 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
11643
a5e0cd1d
MG
116442013-05-10 Marc Glisse <marc.glisse@inria.fr>
11645
11646 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
11647 vectors.
11648
f6bc1c4a
HS
116492013-05-07 Han Shen <shenhan@google.com>
11650
11651 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
11652
3f12f6e9
SKS
116532013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
11654
11655 * c-common.c (check_user_alignment): Emit error for negative values.
11656
61949153
PC
116572013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
11658
11659 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
11660
e93e18e9
PC
116612013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
11662
11663 * c-cppbuiltin.c (c_cpp_builtins): Do not define
11664 __GXX_EXPERIMENTAL_CXX1Y__.
11665
44d90fe1 116662013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
8e745a17 11667 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
44d90fe1
PC
11668
11669 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
11670 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
11671 to simply use OPT_Wpointer_arith.
11672 (c_sizeof_or_alignof_type): Likewise.
11673
13f39b2e
PC
116742013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
11675
11676 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
11677
4b84d650
JJ
116782013-04-12 Jakub Jelinek <jakub@redhat.com>
11679
11680 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
11681 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
11682 specifiers.
11683
fb037b5d
SB
116842013-04-07 Steven Bosscher <steven@gcc.gnu.org>
11685
11686 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
11687
4e856798
PC
116882013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
11689
11690 * c-common.c (pointer_int_sum): Remove dead code.
11691
4b1baac8
RS
116922013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
11693
11694 PR middle-end/56524
11695 * c-common.c (handle_optimize_attribute): Don't call
11696 save_optabs_if_changed.
11697
0b50e654
JJ
116982013-03-05 Jakub Jelinek <jakub@redhat.com>
11699
11700 PR middle-end/56461
11701 * c-pch.c (pch_init): Free target_validity at the end.
11702
48c41403
JJ
117032013-03-04 Jakub Jelinek <jakub@redhat.com>
11704
11705 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
11706
e664c61c
KS
117072013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
11708 Jakub Jelinek <jakub@redhat.com>
11709
11710 PR sanitizer/56454
11711 * c-common.c (handle_no_sanitize_address_attribute): New function.
11712 (c_common_attribute_table): Add no_sanitize_address attribute.
11713 (handle_no_address_safety_analysis_attribute): Add
11714 no_sanitize_address attribute, not no_address_safety_analysis
11715 attribute.
11716
a475fd3d 117172013-02-18 Aldy Hernandez <aldyh@redhat.com>
135204dd
AH
11718
11719 PR target/52555
11720 * c-common.c (handle_optimize_attribute): Call
11721 save_optabs_if_changed.
11722
f6007d99
JJ
117232013-02-18 Jakub Jelinek <jakub@redhat.com>
11724 Steven Bosscher <steven@gcc.gnu.org>
11725
11726 PR pch/54117
11727 * c-opts.c (c_common_post_options): If debug info is enabled
11728 and non-dwarf*, refuse to load PCH files and when writing PCH
11729 file warn.
11730
cf35e2b1
JJ
117312013-02-05 Jakub Jelinek <jakub@redhat.com>
11732
11733 PR middle-end/56167
11734 * c-common.c (handle_error_attribute): Fix condition.
11735
32887460
JJ
117362013-01-30 Jakub Jelinek <jakub@redhat.com>
11737
11738 PR c++/55742
11739 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
11740
5af057d8
JM
117412013-01-18 Jason Merrill <jason@redhat.com>
11742
11743 PR target/54908
11744 * c.opt (-fextern-tls-init): New.
11745 * c-opts.c (c_common_post_options): Handle it.
11746
cc83c823
JJ
117472013-01-09 Jakub Jelinek <jakub@redhat.com>
11748
11749 PR c/48418
11750 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
11751 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
11752 and is either negative or bigger or equal to type precision
11753 of the first operand.
11754
a859517f
MP
117552012-12-03 Marek Polacek <polacek@redhat.com>
11756
11757 PR c/55570
11758 * c-common.c (check_user_alignment): Swap order of tests,
11759 check TREE_CODE first.
11760
2d7aa578
ESR
117612012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
11762
11763 PR c++/52654
11764 * c-common.h (overflow_type): New enum.
11765 (build_userdef_literal): Add overflow_type argument.
11766 (tree_userdef_literal): Add overflow_type.
11767 (USERDEF_LITERAL_OVERFLOW): New access macro.
11768 * c-common.c (build_userdef_literal): Add overflow_type
11769 argument.
11770 * c-lex.c (c_lex_with_flags): Add overflow_type to
11771 build_userdef_literal calls.
11772 (interpret_integer, interpret_float): Add overflow_type argument.
11773
cc3c4f62
RB
117742012-11-28 Richard Biener <rguenther@suse.de>
11775
11776 PR c/35634
11777 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
11778 here and use a type with proper overflow behavior for types that would
11779 need to be promoted for the arithmetic.
11780
77bc5132
JJ
117812012-11-23 Jakub Jelinek <jakub@redhat.com>
11782
11783 PR sanitizer/55435
11784 * c-common.c (handle_no_address_safety_analysis_attribute): New
11785 function.
11786 (c_common_attribute_table): Add no_address_safety_analysis.
11787
5dc99c46
SB
117882012-11-16 Simon Baldwin <simonb@google.com>
11789
11790 * c.opt: Add f[no-]canonical-system-headers.
11791 * c-opts.c (c_common_handle_option): Handle
11792 OPT_fcanonical_system_headers.
11793
a4a0016d
ESR
117942012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
11795
11796 PR c++/54413
11797 * c-opts.c (c_common_handle_option): Set new flags.
11798 * c.opt: Describe new flags.
11799
7dbb85a7
JM
118002012-11-09 Jason Merrill <jason@redhat.com>
11801
11802 * c.opt (Wabi-tag): New.
11803
ad7bac31
AK
118042012-11-09 Andi Kleen <ak@linux.intel.com>
11805
11806 PR 55139
11807 * c-common.c (get_atomic_generic_size): Mask with
8e745a17 11808 MEMMODEL_MASK
ad7bac31 11809
7332899a
MLI
118102012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
11811
11812 PR c/53063
11813 * c.opt (Wformat): Make it Alias Wformat=1.
11814 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
11815 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
11816 LangEnabledBy.
11817 (Wformat=): RejectNegative. Use LangEnabledBy.
11818 (Wnonnull): Use LangEnabledBy.
11819 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
11820 * c-format.c (set_Wformat): Delete.
11821 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
ab20d992
JJ
11822 (maybe_read_dollar_number): Likewise.
11823 (avoid_dollar_number): Likewise.
11824 (finish_dollar_format_checking): Likewise.
11825 (check_format_info): Likewise.
11826 (check_format_info_main): Likewise.
11827 (check_format_types): Likewise.
11828 (format_type_warning): Likewise.
11829 * c-common.c (int): Likewise.
11830 (check_function_sentinel): Likewise.
8e745a17 11831 * c-common.h (warn_format,set_Wformat): Do not declare here.
7332899a 11832
34a180a6
MLI
118332012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
11834
11835 PR c/53063
11836 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
11837 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
11838 Use LangEnabledBy.
11839 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
11840 common.opt.
11841 (Wvariadic-macros): Init(1).
11842 * c-opts.c (c_common_handle_option): Do not handle them
11843 explicitly.
11844 (c_common_post_options): Likewise.
11845 (sanitize_cpp_opts): warn_unused_macros is now
11846 cpp_warn_unused_macros.
11847 (push_command_line_include): Likewise.
11848 * c-common.c (warn_unknown_pragmas): Do not define.
11849 * c-common.h (warn_unknown_pragmas): Do not declare.
11850
3f46d6a5
MLI
118512012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
11852
11853 PR c/51294
11854 * c-common.c (conversion_warning): Handle conditional expressions.
11855
880661a4
JW
118562012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
11857
11858 PR c++/54930
11859 * c.opt (Wreturn_local_addr): Define new option.
11860
4514a96b
JM
118612012-10-25 Jason Merrill <jason@redhat.com>
11862
f14edc1a
JM
11863 * c.opt (Wvirtual-move-assign): New.
11864
4514a96b
JM
11865 * c.opt (Winherited-variadic-ctor): New.
11866
93100c6b
MG
118672012-10-25 Marc Glisse <marc.glisse@inria.fr>
11868
11869 PR c++/54427
11870 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
11871
1efcb8c6
JM
118722012-10-23 Joseph Myers <joseph@codesourcery.com>
11873
11874 * c-common.h (pch_cpp_save_state): Declare.
11875 * c-target.def (c_preinclude): New hook.
11876 * c-opts.c (done_preinclude): New.
11877 (push_command_line_include): Handle default preincluded header.
11878 (cb_file_change): Call pch_cpp_save_state when calling
11879 push_command_line_include.
11880 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
11881 (pch_cpp_save_state): New.
11882 (pch_init): Call pch_cpp_save_state conditionally, instead of
11883 calling cpp_save_state.
11884
4a0ae68e
MLI
118852012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
11886
11887 PR c/53063
11888 PR c/40989
11889 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
11890 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
11891 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
11892 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
11893 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
11894 * c-opts.c (c_common_handle_option): Remove explicit handling from
11895 here.
11896 (c_common_post_options): Likewise.
11897
67e4210b
EB
118982012-10-18 Eric Botcazou <ebotcazou@adacore.com>
11899
11900 * c-ada-spec.c (LOCATION_COL): Delete.
11901 (compare_location): New function.
11902 (compare_node): Use it.
11903 (compare_comment): Likewise.
11904
65d4f2cd
MLI
119052012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
11906
11907 PR c/53063
11908 PR c/40989
11909 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
11910 * c-opts.c (c_common_handle_option): Do not set them here. Add
11911 comment.
11912 (c_common_post_options): Likewise.
11913
909881cb
EB
119142012-10-16 Eric Botcazou <ebotcazou@adacore.com>
11915
11916 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
11917 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
11918 Remove POINTER_TYPE handling, add large unsigned handling and use
11919 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
11920
3a785c97
JJ
119212012-10-12 Jakub Jelinek <jakub@redhat.com>
11922
11923 PR c/54381
11924 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
11925 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
11926 locs and array of 3 trees instead of just single loc and single
11927 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
11928 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
11929 For *cmp* builtins that take two sources strings report warnings
11930 about first and second source, not about destination and source.
11931
5e54f81d
MG
119322012-10-12 Marc Glisse <marc.glisse@inria.fr>
11933
11934 PR c++/53055
11935 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
11936
f5b02f1e
EB
119372012-10-11 Eric Botcazou <ebotcazou@adacore.com>
11938
11939 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
11940 declaring something coming from another file.
11941
b46dbc6c
AC
119422012-10-10 Arnaud Charlet <charlet@adacore.com>
11943
f5b02f1e 11944 PR ada/54845
b46dbc6c
AC
11945 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
11946
5d9de0d0
PC
119472012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
11948
11949 PR c++/54194
11950 * c-common.c (warn_about_parentheses): Add location_t parameter;
11951 use EXPR_LOC_OR_LOC.
11952 * c-common.h: Update declaration.
11953
a212e43f
MG
119542012-10-09 Marc Glisse <marc.glisse@inria.fr>
11955
11956 PR c++/54427
11957 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
11958 more operations. Make error messages optional.
11959 * c-common.h (enum stv_conv): Moved from c-typeck.c.
11960 (scalar_to_vector): Declare.
11961
b1db7f91
JM
119622012-10-08 Jason Merrill <jason@redhat.com>
11963
11964 * c-common.c (c_common_reswords): Add thread_local.
11965
e28d52cf
DS
119662012-10-08 Dodji Seketeli <dodji@redhat.com>
11967
11968 PR c++/53528 C++11 attribute support
11969 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
11970 new functions.
11971 * c-common.c (check_cxx_fundamental_alignment_constraints): New
11972 static function.
11973 (handle_aligned_attribute): In choose strictest alignment
11974 among many. Use new check_cxx_fundamental_alignment_constraints.
11975 (handle_transparent_union_attribute): In c++11 attribute syntax,
11976 don't look through typedefs.
11977
3b78de56
AC
119782012-10-04 Arnaud Charlet <charlet@adacore.com>
11979
11980 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
11981 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
11982 out of dumpfile.h.
11983
6040bb5f
DC
119842012-09-25 Dehao Chen <dehao@google.com>
11985
11986 PR middle-end/54645
3b78de56 11987 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
6040bb5f
DC
11988 map when read in the pch.
11989
3f8257db 119902012-09-18 Arnaud Charlet <charlet@adacore.com>
0b07a57e
AC
11991
11992 * c-ada-spec.c: Style fixes.
11993
3f8257db 119942012-09-18 Thomas Quinot <quinot@adacore.com>
da5182be
TQ
11995
11996 * c.opt (-fada-spec-parent): Define new command line switch.
11997 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
11998 is specified, generate binding spec as a child of the specified unit.
11999
0ccb505d
PC
120002012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
12001 Manuel López-Ibáñez <manu@gcc.gnu.org>
12002
12003 PR c++/53210
12004 * c.opt ([Winit-self]): Enabled by -Wall in C++.
12005
c583af79
AC
120062012-08-23 Arnaud Charlet <charlet@adacore.com>
12007
12008 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
12009 for pointers, and add missing Convention C pragma.
12010 (print_ada_struct_decl): Add missing aliased keyword.
12011 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
12012
1a4049e7
JJ
120132012-08-17 Jakub Jelinek <jakub@redhat.com>
12014
12015 * c-common.c (sizeof_pointer_memaccess_warning): New function.
12016 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
12017 * c-opts.c (c_common_handle_option): Enable it for -Wall.
12018 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
12019 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
12020
70b5e7dc
RG
120212012-08-10 Richard Guenther <rguenther@suse.de>
12022
12023 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
12024
f8923f7e
SB
120252012-08-07 Steven Bosscher <steven@gcc.gnu.org>
12026
12027 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
12028 instead of separate pp_newline and pp_flush.
12029 (print_c_tree): Likewise.
12030
e45abe1f
RH
120312012-07-26 Richard Henderson <rth@redhat.com>
12032
12033 * c-common.c (handle_hot_attribute): Allow labels.
12034 (handle_cold_attribute): Likewise.
12035
332f1d24
JJ
120362012-07-20 Jakub Jelinek <jakub@redhat.com>
12037
12038 PR c++/28656
12039 * c-common.c (check_function_nonnull): Handle multiple nonnull
12040 attributes properly.
12041
7ee2468b
SB
120422012-07-16 Steven Bosscher <steven@gcc.gnu.org>
12043
12044 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
12045 * c-ada-spec.c: Likewise.
12046 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
12047
ee7b28eb
SB
120482012-07-14 Steven Bosscher <steven@gcc.gnu.org>
12049
12050 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
12051 Remove code conditional on it.
12052
6bdf3519
SB
120532012-07-11 Steven Bosscher <steven@gcc.gnu.org>
12054
12055 * c-gimplify.c: Do not include basic-block.h.
12056 * c-common.c: Do not include linfuncs.h.
12057
532aafad
SB
120582012-07-08 Steven Bosscher <steven@gcc.gnu.org>
12059
12060 * c-common.h: Include tree.h.
12061
8d0d1915
JM
120622012-07-02 Jason Merrill <jason@redhat.com>
12063
12064 PR c++/53524
12065 * c-common.c (get_priority): Call default_conversion.
12066
fbc873ad
UB
120672012-07-01 Uros Bizjak <ubizjak@gmail.com>
12068
12069 * c-pch.c (c_common_write_pch): Remove unused variables.
12070
d4a10d0a
SB
120712012-06-29 Steven Bosscher <steven@gcc.gnu.org>
12072
12073 * cppspec.c: Moved from gcc/ to here.
12074
6f3a2e23
KT
120752012-06-27 Kai Tietz <ktietz@redhat.com>
12076
12077 PR preprocessor/37215
12078 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
12079
8ca92d04
SB
120802012-06-21 Steven Bosscher <steven@gcc.gnu.org>
12081
12082 * c-common.h (c_common_print_pch_checksum): Remove.
12083 * c-pch.c: Do not include output.h.
12084 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
12085 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
12086 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
12087 (struct c_pch_header): Remove.
12088 (get_ident): Update gpch version.
12089 (pch_init): Do not print executable_checksum to asm_out_file.
12090 Do not fail if there is no asm_out_file to read back from. Set
12091 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
12092 (c_common_write_pch): Verify that nothing was written to asm_out_file
12093 since pch_init was called. Do not write a c_pch_header, and do not
12094 copy from asm_out_file to the PCH.
12095 (c_common_read_pch): Do not read a c_pch_header, and do not restore
12096 the content of asm_out_file from the PCH.
12097 (c_common_print_pch_checksum): Remove.
12098 * c-opts.c (c_common_init): Print out executable_checksum directly.
12099
70f42967
SB
121002012-06-19 Steven Bosscher <steven@gcc.gnu.org>
12101
12102 * c-target.def (objc_declare_unresolved_class_reference,
12103 objc_declare_class_definition): Add new hooks.
12104
a8781821
SB
121052012-06-19 Steven Bosscher <steven@gcc.gnu.org>
12106
12107 * c-lex.c: Do not include output.h.
12108 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
12109 Remove uses of ASM_OUTPUT_IDENT.
12110
9e1a8dd1
RR
121112012-06-15 Marc Glisse <marc.glisse@inria.fr>
12112
12113 PR c++/51033
12114 * c-common.h (c_build_vec_perm_expr): Move decl here.
12115 * c-common.c (c_build_vec_perm_expr): Move definition
12116 here.
12117
6f07a821
SB
121182012-06-06 Steven Bosscher <steven@gcc.gnu.org>
12119
12120 * c.opt (fconserve-space): Turn into a no-op.
12121
9faeb493 121222012-06-04 Sterling Augustine <saugustine@google.com>
c265f413
SA
12123
12124 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
12125 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
12126 both the start and end of the function.
12127
a4b7d13c
SB
121282012-06-04 Steven Bosscher <steven@gcc.gnu.org>
12129
12130 * c-common.c: Do not include output.h.
12131 * c-pragma.c: Likewise.
12132
c265f413
SA
121332012-06-04 Steven Bosscher <steven@gcc.gnu.org>
12134
12135 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
12136 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
12137 (lang_decl_name): Handle namespace decls.
12138
be7a421e
SB
121392012-05-31 Steven Bosscher <steven@gcc.gnu.org>
12140
12141 * c-ada-spec.c: Do not include output.h.
12142 * c-semantics.c: Likewise.
12143
65de6659
JM
121442012-05-29 Joseph Myers <joseph@codesourcery.com>
12145
12146 * c-common.c: Fix typo.
12147
ca5f4331
MM
121482012-05-29 Michael Matz <matz@suse.de>
12149
12150 * c-common.h (c_expand_decl): Remove prototype.
12151
4f7f7aca
MLI
121522012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
12153
12154 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
12155 * c-opts.c (c_common_handle_option): Remove code handling
12156 warn_missing_braces.
12157
4a792f9b
PC
121582012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
12159
12160 PR c++/25137
12161 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
12162 -Wmissing_braces.
12163
650dc14a
DS
121642012-05-22 Dodji Seketeli <dodji@redhat.com>
12165
12166 PR c++/53322
12167 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
12168
9b095bf1
MLI
121692012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
12170
12171 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
12172 * c-opts.c (c_common_handle_option): Do not handle explicitly
12173 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
12174
0b2c4be5
DS
121752012-05-16 Dodji Seketeli <dodji@redhat.com>
12176
12177 PR preprocessor/7263
ab20d992 12178 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
0b2c4be5
DS
12179 to cpp_classify_number. For diagnostics, use the precise location
12180 instead of the global input_location.
12181
a1bde5af
PC
121822012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
12183
d02924ef 12184 PR c++/11856
a1bde5af
PC
12185 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
12186
d1ede5f4
BS
121872012-05-14 Bernd Schmidt <bernds@codesourcery.com>
12188
a1bde5af 12189 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
d1ede5f4 12190
f2bc201f
MLI
121912012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
12192
12193 PR 53063
12194 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
12195 Wreorder): Use LangEnabledBy.
12196 * c-opts.c (c_common_handle_option): Do not enable them
12197 explicitly. Call lang-specific generated functions.
12198 (c_common_post_options): Do not set them here.
12199
95744782
MLI
122002012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
12201
12202 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
12203 Wmissing-field-initializers,Wmissing-parameter-type,
12204 Wold-style-declaration,Woverride-init): Use EnabledBy.
12205 * c-opts.c (c_common_post_options): Do not set here explicitly.
12206
7d5a5747
MLI
122072012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
12208
12209 PR 53063
12210 * c-opts.c (c_common_handle_option): Use handle_generated_option
12211 to enable sub-options.
12212
5a3c9cf2
PC
122132012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
12214
12215 PR c++/53158
12216 * c-common.c (warnings_for_convert_and_check): Use warning_at.
12217
3ac8781c
RG
122182012-05-10 Richard Guenther <rguenther@suse.de>
12219
12220 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
12221 adjust commentary about TYPE_IS_SIZETYPE types.
12222
1e537948
MLI
122232012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
12224
12225 PR c++/53261
12226 * c-common.c (warn_logical_operator): Check that argument of
12227 integer_zerop is not NULL.
12228
f2c4a785
MLI
122292012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
12230
12231 PR c/43772
12232 * c-common.c (warn_logical_operator): Do not warn if either side
12233 is already true or false.
12234
50f305ca
MLI
122352012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
12236
12237 PR c/51712
12238 * c-common.c (expr_original_type): New.
12239 (shorten_compare): Do not warn for enumeration types.
12240
0c3641b0
MLI
122412012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
12242
12243 * c.opt (fpermissive): Add Var(flag_permissive).
12244
7edaa4d2
MG
122452012-04-30 Marc Glisse <marc.glisse@inria.fr>
12246
12247 PR c++/51033
12248 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
12249 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
12250
b9c8da34
DS
122512012-04-30 Dodji Seketeli <dodji@redhat.com>
12252
12253 Add -Wvarargs option
ab20d992 12254 * c.opt (Wvarargs): Define new option.
b9c8da34 12255
e6c69da0
MLI
122562012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
12257
12258 * c-common.c (check_function_arguments): Replace
12259 Wmissing-format-attribute with Wsuggest-attribute=format.
12260
90137d8f
MLI
122612012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
12262
12263 * c.opt (Wsuggest-attribute=format): New. Alias of
12264 Wmissing-format-attribute.
12265 * c-format.c (decode_format_type): Replace
12266 Wmissing-format-attribute with Wsuggest-attribute=format.
12267 (check_function_format): Likewise.
12268
9faeb493 122692012-04-27 Ollie Wild <aaw@google.com>
7f5f5f98
OW
12270
12271 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
12272 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
12273 * c.opt: Add Wliteral-suffix.
12274
c1771a20
MLI
122752012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
12276
12277 PR c/44774
12278 * c.opt (Wpedantic): New.
12279 (pedantic): Alias Wpedantic.
12280 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
12281 (c_common_post_options): Likewise.
12282 (sanitize_cpp_opts): Likewise.
12283 * c-lex.c (interpret_float): Likewise.
12284 * c-format.c (check_format_types): Likewise.
12285 * c-common.c (pointer_int_sum): Likewise.
12286 (c_sizeof_or_alignof_type): Likewise.
12287 (c_add_case_label): Likewise.
12288 (c_do_switch_warnings): Likewise.
12289 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
12290
04b391c1
JM
122912012-04-15 Jason Merrill <jason@redhat.com>
12292
12293 PR c++/52818
12294 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
12295 (C_STD_NAME): Distinguish between C++98 and C++11.
12296
ac868f29
EB
122972012-04-11 Eric Botcazou <ebotcazou@adacore.com>
12298
12299 PR target/52624
12300 * c-common.h (uint16_type_node): Rename into...
12301 (c_uint16_type_node): ...this.
12302 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
12303 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
12304
fd4116f4
MLI
123052012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
12306
12307 * c-common.c (warn_if_unused_value): Move definition to here.
12308 * c-common.h (warn_if_unused_value): Move declaration to here.
12309
573ac65e
WB
123102012-03-23 William Bader <williambader@hotmail.com>
12311
12312 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
12313
552b8185
JM
123142012-03-20 Jason Merrill <jason@redhat.com>
12315
12316 * c-common.h (enum cxx_dialect): Add cxx1y.
12317 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
12318 test.
12319 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
12320 * c-opts.c (c_common_post_options): Likewise.
12321 (set_std_cxx1y): New.
12322 (c_common_handle_option): Call it.
12323 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
12324
04398fa8
PC
123252012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
12326
12327 PR c++/14710
12328 * c.opt ([Wuseless-cast]): Add.
12329
d2a12ae7
RG
123302012-03-16 Richard Guenther <rguenther@suse.de>
12331
12332 * c-pretty-print.c (pp_c_initializer_list): Adjust.
12333
a12bf402
MLI
123342012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
12335
12336 PR c++/44783
12337 * c.opt (ftemplate-backtrace-limit) Add.
12338
5c30094f
RO
123392012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12340
12341 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
12342 handling.
12343 * c-pragma.c (handle_pragma_extern_prefix): Remove.
12344 (init_pragma): Don't register extern_prefix.
12345
21fa2faf
RG
123462012-03-12 Richard Guenther <rguenther@suse.de>
12347
12348 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
12349 (builtin_type_for_size): Likewise.
12350
e3793c6f
JJ
123512012-02-13 Jakub Jelinek <jakub@redhat.com>
12352
12353 PR c++/52215
12354 * c-common.c (sync_resolve_params): Don't decide whether to convert
12355 or not based on TYPE_SIZE comparison, convert whenever arg_type
12356 is unsigned INTEGER_TYPE.
12357
93286335
PC
123582012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
12359
12360 PR c/52118
12361 * c.opt ([Wunused-local-typedefs]): Fix description.
12362
7a421706
MS
123632012-01-24 Mike Stump <mikestump@comcast.net>
12364
12365 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
12366 exactly.
12367
ba9b1f11
RG
123682012-01-18 Richard Guenther <rguenther@suse.de>
12369
12370 * c-opts.c (c_common_post_options): Reset LTO flags if
12371 we are about to generate a PCH.
12372
465406be
PC
123732012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
12374
12375 PR c++/51777
12376 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
12377 use pp_unsigned_wide_integer.
12378
aee15221
RG
123792012-01-10 Richard Guenther <rguenther@suse.de>
12380
12381 PR middle-end/51806
12382 * c-opts.c (c_common_handle_option): Move -Werror handling
12383 to language independent code.
12384
5720c0dc
RG
123852012-01-05 Richard Guenther <rguenther@suse.de>
12386
12387 PR middle-end/51764
12388 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
12389 from common.opt.
12390
73ac190a
PC
123912011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
12392
12393 PR c++/51316
12394 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
12395 of array types with an unknown bound.
12396
48b0b196
JM
123972011-12-20 Joseph Myers <joseph@codesourcery.com>
12398
12399 * c-common.c (flag_isoc99): Update comment to refer to C11.
12400 (flag_isoc1x): Change to flag_isoc11.
12401 * c-common.h (flag_isoc99): Update comment to refer to C11.
12402 (flag_isoc1x): Change to flag_isoc11.
12403 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
12404 C11.
12405 * c-opts.c (set_std_c1x): Change to set_std_c11.
12406 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
12407 Call set_std_c11.
12408 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
12409 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
12410 * c.opt (std=c1x): Change to std=c11. Document as non-draft
12411 standard.
12412 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
12413 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
12414 (std=gnu1x): Make alias of std=gnu11.
12415
d58d6eb5
JM
124162011-12-19 Jason Merrill <jason@redhat.com>
12417
12418 PR c++/51228
12419 * c-common.c (handle_transparent_union_attribute): Check the first
12420 field if the type is complete.
12421
b3908fcc
JW
124222011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
12423
12424 PR libstdc++/51365
12425 * c-common.c (RID_IS_FINAL): Add.
12426 * c-common.h (RID_IS_FINAL): Add.
12427
fea3ca91
IS
124282011-11-30 Iain Sandoe <iains@gcc.gnu.org>
12429
12430 * c.opt (fgnu-runtime): Provide full description.
12431 (fnext-runtime): Likewise.
12432 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
12433
62bad7cd
AM
124342011-11-28 Andrew MacLeod <amacleod@redhat.com>
12435
12436 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
12437 predefines in one place. Add LOCK_FREE predefines.
12438 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
12439 new func.
12440
c466c4ff
AM
124412011-11-24 Andrew MacLeod <amacleod@redhat.com>
12442
12443 PR c/51256
9faeb493 12444 * c-common.c (get_atomic_generic_size): Check for various error
c466c4ff 12445 conditions
9faeb493
UB
12446 (resolve_overloaded_atomic_exchange,
12447 resolve_overloaded_atomic_compare_exchange,
c466c4ff
AM
12448 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
12449 error_mark_node for error conditions.
9faeb493 12450
a5952633
RG
124512011-11-08 Richard Guenther <rguenther@suse.de>
12452
12453 PR middle-end/51010
ab20d992 12454 * c-pretty-print.c (pp_c_expression): Handle SSA_NAMEs.
a5952633 12455
0a35513e
AH
124562011-11-07 Richard Henderson <rth@redhat.com>
12457 Aldy Hernandez <aldyh@redhat.com>
12458 Torvald Riegel <triegel@redhat.com>
12459
12460 Merged from transactional-memory.
12461
12462 * c-common.c (handle_tm_wrap_attribute,
12463 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
12464 (struct c_common_reswords): Added __transaction* keywords.
12465 (struct c_common_attribute_table): Added transaction* and tm_regparm
12466 attributes.
12467 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
12468 masks.
12469 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
12470 find_tm_attribute): Declare.
12471
6d87092d
JM
124722011-11-07 Jason Merrill <jason@redhat.com>
12473
12474 PR c++/35688
12475 * c-common.c, c-common.h: Revert yesterday's changes.
12476
8e7860a1
JM
124772011-11-06 Jason Merrill <jason@redhat.com>
12478
12479 PR c++/35688
12480 * c-common.c (decl_has_visibility_attr): Split out from...
12481 (c_determine_visibility): ...here.
12482 * c-common.h: Declare it.
12483
d19fa6b5
JM
124842011-11-06 Joseph Myers <joseph@codesourcery.com>
12485
12486 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
12487 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
12488 type.
12489 (check_user_alignment): New. Split out of
12490 handle_aligned_attribute. Disallow integer constants with
12491 noninteger types. Conditionally allow zero.
12492 (handle_aligned_attribute): Use check_user_alignment.
12493 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
12494
86951993
AM
124952011-11-06 Andrew MacLeod <amacleod@redhat.com>
12496 Richard Henderson <rth@redhat.com>
12497
12498 Merged from cxx-mem-model.
12499
12500 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
9faeb493 12501 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
86951993
AM
12502 parameters that are the same type size.
12503 (get_atomic_generic_size): New. Find size of generic
12504 atomic function parameters and do typechecking.
12505 (add_atomic_size_parameter): New. Insert size into parameter list.
12506 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
12507 either __atomic_exchange_n or external library call.
9faeb493 12508 (resolve_overloaded_atomic_compare_exchange): Restructure
86951993 12509 __atomic_compare_exchange to either _n variant or external library call.
9faeb493 12510 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
86951993
AM
12511 __atomic_load_n or an external library call.
12512 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
12513 __atomic_store_n or an external library call.
12514 (resolve_overloaded_builtin): Handle new __atomic builtins.
12515
cf9e9959
EB
125162011-11-04 Eric Botcazou <ebotcazou@adacore.com>
12517
12518 PR c++/50608
12519 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
12520 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
12521 <INDIRECT_REF>: Return the argument.
12522 <ARRAY_REF>: Remove special code for negative offset.
12523 Call fold_build_pointer_plus instead of size_binop.
12524 (fold_offsetof): Remove STOP_REF argument and adjust.
12525 * c-common.h (fold_offsetof_1): Declare.
12526 (fold_offsetof): Remove STOP_REF argument.
12527
25339f10
JM
125282011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
12529
12530 PR c++/50810
12531 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
12532 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
12533 Wnarrowing for C++0x and C++98.
12534 * c.opt ([Wnarrowing]): Update.
12535
89401152
PC
125362011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
12537
12538 PR c++/44277
12539 * c.opt: Add Wzero-as-null-pointer-constant.
12540
97e3ad20
JM
125412011-10-31 Jason Merrill <jason@redhat.com>
12542
15694fdd
JM
12543 * c.opt (-fdeduce-init-list): Off by default.
12544
97e3ad20
JM
12545 PR c++/50920
12546 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
12547 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
12548 and -Wc++11-compat.
12549 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
12550
fb9120e3
RAV
125512011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
12552
12553 PR c++/30066
12554 * c.opt (fvisibility-inlines-hidden): Description change.
12555
3ce4f9e4
ESR
125562011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
12557
12558 Implement C++11 user-defined literals.
12559 * c-common.c (build_userdef_literal): New.
12560 * c-common.def: New tree code.
12561 * c-common.h (tree_userdef_literal): New tree struct and accessors.
12562 * c-lex.c (interpret_float): Add suffix parm.
12563 (c_lex_with_flags): Build literal tokens.
12564
5f53c243
PC
125652011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
12566
12567 PR c++/50841
12568 Revert:
12569 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
12570
12571 PR c++/50810
12572 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
12573 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
12574 Wnarrowing for C++0x and C++98.
12575 * c.opt ([Wnarrowing]): Update.
12576
263734e1
PC
125772011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
12578
12579 PR c++/50810
12580 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
12581 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
12582 Wnarrowing for C++0x and C++98.
12583 * c.opt ([Wnarrowing]): Update.
12584
d2e312d7
PC
125852011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
12586
12587 PR c++/45385
12588 * c-common.c (conversion_warning): Remove code looking for
12589 artificial operands.
12590
d17687f6
DS
125912011-10-18 Dodji Seketeli <dodji@redhat.com>
12592
12593 PR bootstrap/50760
12594 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
9faeb493 12595 !NO_IMPLICIT_EXTERN_C.
d17687f6 12596
fc8396e9
PC
125972011-10-17 Michael Spertus <mike_spertus@symantec.com>
12598
12599 * c-common.c (c_common_reswords): Add __bases,
12600 __direct_bases.
12601 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
12602
126032011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
12604
12605 PR c++/50757
12606 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
12607
847e697a
TT
126082011-10-15 Tom Tromey <tromey@redhat.com>
12609 Dodji Seketeli <dodji@redhat.com>
12610
12611 * c.opt (fdebug-cpp): New option.
12612 * c-opts.c (c_common_handle_option): Handle the option.
12613 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
12614 output stream in parameter. Factorized from ...
12615 (maybe_print_line): ... this. Dump location debug information when
12616 -fdebug-cpp is in effect.
12617 (print_line_1): New static function. Takes an output stream in
12618 parameter. Factorized from ...
12619 (print_line): ... here. Dump location information when -fdebug-cpp
12620 is in effect.
12621 (scan_translation_unit): Dump location information when
12622 -fdebug-cpp is in effect.
12623
92582b75
TT
126242011-10-15 Tom Tromey <tromey@redhat.com>
12625 Dodji Seketeli <dodji@redhat.com>
12626
12627 * c.opt (ftrack-macro-expansion): New option. Handle it with and
12628 without argument.
12629 * c-opts.c (c_common_handle_option)<case
12630 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
12631 cases. Handle -ftrack-macro-expansion with and without argument.
12632
46427374
TT
126332011-10-15 Tom Tromey <tromey@redhat.com>
12634 Dodji Seketeli <dodji@redhat.com>
12635
12636 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
12637 (print_line, cb_define, do_line_change): Adjust to avoid touching
12638 the internals of struct line_map. Use the public API instead.
12639 * c-pch.c (c_common_read_pch): Likewise.
12640 * c-lex.c (fe_file_change): Likewise.
12641
fc8396e9
PC
126422011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
12643
12644 PR c++/17212
12645 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
12646
126472011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
12648
12649 PR c++/33067
12650 * c-pretty-print.c (pp_c_floating_constant): Output
12651 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
12652
e79983f4
MM
126532011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
12654
12655 * c-common.c (def_builtin_1): Delete old interface with two
12656 parallel arrays to hold standard builtin declarations, and replace
12657 it with a function based interface that can support creating
12658 builtins on the fly in the future. Change all uses, and poison
12659 the old names. Make sure 0 is not a legitimate builtin index.
12660 * c-omp.c (c_finish_omp_barrier): Ditto.
12661 (c_finish_omp_taskwait): Ditto.
12662 (c_finish_omp_flush): Ditto.
12663
6637388f
TG
126642011-10-11 Tristan Gingold <gingold@adacore.com>
12665
12666 * c.opt: (fallow-parameterless-variadic-functions): New.
12667
3797cb21
DS
126682011-09-08 Dodji Seketeli <dodji@redhat.com>
12669
12670 PR c++/33255 - Support -Wunused-local-typedefs warning
12671 * c-common.h (struct c_language_function::local_typedefs): New
12672 field.
9faeb493
UB
12673 (record_locally_defined_typedef, maybe_record_typedef_use)
12674 (maybe_warn_unused_local_typedefs): Declare new functions.
3797cb21 12675 * c-common.c (record_locally_defined_typedef)
9faeb493
UB
12676 (maybe_record_typedef_use)
12677 (maybe_warn_unused_local_typedefs): Define new functions.
3797cb21
DS
12678 * c.opt: Declare new -Wunused-local-typedefs flag.
12679
693ddb1b
EB
126802011-09-06 Eric Botcazou <ebotcazou@adacore.com>
12681
12682 PR middle-end/50266
12683 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
12684 computations.
12685
830c740f
RG
126862011-09-05 Richard Guenther <rguenther@suse.de>
12687
12688 * c-common.c (complete_array_type): Use ssize_int (-1) instead
12689 of integer_minus_one_node for empty array upper bounds.
12690
892a371f
DS
126912011-08-28 Dodji Seketeli <dodji@redhat.com>
12692
12693 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
12694 it's the first time it's being called on this main TU.
12695
0e3fdb48
RB
126962011-08-24 Richard Guenther <rguenther@suse.de>
12697
12698 PR c/49396
12699 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
12700
127012011-08-22 Gabriel Charette <gchare@google.com>
e3dfef44
GC
12702
12703 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
12704 defined in cpp_init_builtins and c_cpp_builtins.
12705
d4a83c10
JM
127062011-08-19 Joseph Myers <joseph@codesourcery.com>
12707
12708 * c-common.c (c_common_reswords): Add __builtin_complex.
12709 * c-common.h (RID_BUILTIN_COMPLEX): New.
12710
bbceee64
JM
127112011-08-18 Joseph Myers <joseph@codesourcery.com>
12712
12713 * c-common.c (c_common_reswords): Add _Noreturn.
12714 (keyword_is_function_specifier): Handle RID_NORETURN.
12715 * c-common.h (RID_NORETURN): New.
12716
3f8257db 127172011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
0e3a99ae
AS
12718
12719 * c-common.c (unsafe_conversion_p): New function. Check if it is
12720 unsafe to convert an expression to the type.
12721 (conversion_warning): Adjust, use unsafe_conversion_p.
12722 * c-common.h (unsafe_conversion_p): New function declaration.
12723
20906c66
JJ
127242011-08-02 Jakub Jelinek <jakub@redhat.com>
12725
12726 * c-common.h (c_finish_omp_atomic): Adjust prototype.
12727 (c_finish_omp_taskyield): New prototype.
12728 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
12729 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
12730 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
12731 or RHS1 have side-effects, evaluate those too in the right spot,
12732 if it is a decl and LHS is also a decl, error out if they
12733 aren't the same.
12734 (c_finish_omp_taskyield): New function.
12735 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
12736 * c-pragma.c (omp_pragmas): Add taskyield.
12737 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
12738 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
12739 PRAGMA_OMP_CLAUSE_MERGEABLE.
12740
770e5a2e
DS
127412011-07-25 Dodji Seketeli <dodji@redhat.com>
12742
12743 * c-common.h (set_underlying_type): Remove parm name from
12744 declaration.
12745
1baae426
RG
127462011-07-25 Romain Geissler <romain.geissler@gmail.com>
12747
12748 * c-pretty-print.h: Search c-common.h in c-family.
9faeb493 12749
fcb21722
JM
127502011-07-22 Jason Merrill <jason@redhat.com>
12751
76f86d00
JM
12752 PR c++/49793
12753 * c.opt (Wnarrowing): New.
12754
3a636414
JM
12755 PR c++/30112
12756 * c-common.h: Declare c_linkage_bindings.
12757 * c-pragma.c (handle_pragma_redefine_extname): Use it.
12758
fcb21722
JM
12759 PR c++/49813
12760 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
12761 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
12762 as flag_isoc99 for 'restrict'.
12763 (pp_c_specifier_qualifier_list): Likewise for _Complex.
12764
02614448
ILT
127652011-07-21 Ian Lance Taylor <iant@google.com>
12766
12767 PR middle-end/49705
12768 * c-common.c (c_disable_warnings): New static function.
12769 (c_enable_warnings): New static function.
12770 (c_fully_fold_internal): Change local unused_p to bool. Call
12771 c_disable_warnings and c_enable_warnings rather than change
12772 c_inhibit_evaluation_warnings.
12773
34429675
JM
127742011-07-20 Jason Merrill <jason@redhat.com>
12775
12776 PR c++/6709 (DR 743)
12777 PR c++/42603 (DR 950)
12778 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
12779 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
12780 (CPP_DECLTYPE): New.
12781 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
12782
5d49b6a7
RG
127832011-07-19 Richard Guenther <rguenther@suse.de>
12784
12785 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
12786 * c-omp.c (c_finish_omp_for): Likewise.
12787
e84a58ff
EB
127882011-07-12 Eric Botcazou <ebotcazou@adacore.com>
12789
12790 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
12791 body on the next line.
12792
329af3c7
JM
127932011-07-08 Jason Merrill <jason@redhat.com>
12794
4063e61b
JM
12795 PR c++/45437
12796 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
12797
329af3c7
JM
12798 PR c++/49673
12799 * c-common.c (c_apply_type_quals_to_decl): Don't check
12800 TYPE_NEEDS_CONSTRUCTING.
12801
1a072294
RG
128022011-07-06 Richard Guenther <rguenther@suse.de>
12803
12804 * c-common.c (c_common_nodes_and_builtins):
12805 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
12806
fce5dddd
RG
128072011-07-05 Richard Guenther <rguenther@suse.de>
12808
12809 * c-common.c (c_common_nodes_and_builtins): Build all common
12810 tree nodes first.
12811
45d439ac
JJ
128122011-06-27 Jakub Jelinek <jakub@redhat.com>
12813
56300785
JJ
12814 * c-common.h (c_tree_chain_next): New static inline function.
12815
45d439ac
JJ
12816 * c-common.c (check_builtin_function_arguments): Handle
12817 BUILT_IN_ASSUME_ALIGNED.
12818
e0a8ecf2
AM
128192011-06-21 Andrew MacLeod <amacleod@redhat.com>
12820
12821 * c-common.c: Add sync_ or SYNC__ to builtin names.
12822 * c-omp.c: Add sync_ or SYNC__ to builtin names.
dfb43cd5
PV
12823
128242011-06-20 Pierre Vittet <piervit@pvittet.com>
12825
12826 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
12827 handler.
12828 (gen_pragma_handler): New union.
12829 (internal_pragma_handler): New type.
12830 (c_register_pragma_with_data)
12831 (c_register_pragma_with_expansion_and_data): New functions.
12832
12833 * c-pragma.c (registered_pragmas, c_register_pragma_1)
12834 (c_register_pragma, c_register_pragma_with_expansion)
12835 (c_invoke_pragma_handler): Changed to work with
12836 internal_pragma_handler.
12837 (c_register_pragma_with_data)
12838 (c_register_pragma_with_expansion_and_data): New functions.
12839
677f3fa8
JM
128402011-06-14 Joseph Myers <joseph@codesourcery.com>
12841
12842 * c-common.c: Include common/common-target.h.
12843 (handle_section_attribute): Use
12844 targetm_common.have_named_sections.
12845 * c-cppbuiltin.c: Include common/common-target.h.
12846 (c_cpp_builtins): Use targetm_common.except_unwind_info.
12847
d7fc8c14
RG
128482011-06-10 Richard Guenther <rguenther@suse.de>
12849
12850 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
12851 to print a IDENTIFIER_NODE.
12852
10e48e39
RO
128532011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12854 Joseph Myers <joseph@codesourcery.com>
12855
12856 * c.opt (fbuilding-libgcc): New option.
12857 * c-cppbuiltin.c (c_cpp_builtins): Define
12858 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
12859
6976ae51
JM
128602011-06-07 Jason Merrill <jason@redhat.com>
12861
3ff60975
JM
12862 * c-common.c (max_tinst_depth): Lower default to 900.
12863
6976ae51
JM
12864 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
12865
009db074
RG
128662011-06-07 Richard Guenther <rguenther@suse.de>
12867
12868 * c-common.c (c_common_nodes_and_builtins): Do not set
12869 size_type_node or call set_sizetype.
12870
b4592b92
DS
128712011-06-07 Dodji Seketeli <dodji@redhat.com>
12872
12873 PR debug/49130
12874 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
9faeb493 12875 type when using pointer comparison to compare types.
b4592b92 12876
014ab419
JW
128772011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
12878
12879 * c.opt: Add -Wdelete-non-virtual-dtor.
12880 * c-opts.c (c_common_handle_option): Include it in -Wall.
12881
4f60111f
NF
128822011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
12883
12884 PR bootstrap/49190
12885
12886 Revert:
12887 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
12888
12889 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
12890 not tree_common.
12891
4cc4f2f4
JJ
128922011-05-27 Jakub Jelinek <jakub@redhat.com>
12893
12894 PR c++/49165
12895 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
12896 C++ don't call c_common_truthvalue_conversion on void type arms.
12897
38e01f9e
NF
128982011-05-27 Nathan Froyd <froydnj@codesourcery.com>
12899
12900 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
12901 (stmt_list_stack): Define.
12902 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
12903 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
12904
92e948a8
NF
129052011-05-26 Nathan Froyd <froydnj@codesourcery.com>
12906
12907 * c-common.c (warning_candidate_p): Check for BLOCKs.
12908
a2fc3e63
NF
129092011-05-26 Nathan Froyd <froydnj@codesourcery.com>
12910
12911 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
12912 not tree_common.
12913
0957c029
JJ
129142011-05-25 Jakub Jelinek <jakub@redhat.com>
12915
12916 * c-common.c (def_fn_type): Remove extra va_end.
12917
828fb3ba
JM
129182011-05-23 Jason Merrill <jason@redhat.com>
12919
12920 PR c++/48106
12921 * c-common.c (c_common_get_narrower): New.
12922 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
12923
dde05067
NF
129242011-05-23 Nathan Froyd <froydnj@codesourcery.com>
12925
12926 * c-common.h (check_function_arguments): Tweak prototype of
12927 check_function_arguments.
12928 * c-common.c (check_function_arguments): Likewise. Adjust
12929 calls to check_function_nonnull, check_function_format, and
12930 check_function_sentinel.
12931 (check_function_sentinel): Take a FUNCTION_TYPE rather than
12932 separate attributes and typelist arguments. Use
12933 FOREACH_FUNCTION_ARGS to iterate over argument types.
12934
3c0d13bf
PC
129352011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
12936
12937 * c-common.c (c_common_reswords): Reorder.
12938 * c-common.h (rid): Likewise.
12939
8242dd04
NF
129402011-05-10 Nathan Froyd <froydnj@codesourcery.com>
12941
12942 * c-common.c (def_fn_type): Don't call build_function_type, call
12943 build_function_type_array or build_varargs_function_type_array
12944 instead.
12945 (c_common_nodes_and_builtins): Likewise.
12946
3d528853
NF
129472011-05-05 Nathan Froyd <froydnj@codesourcery.com>
12948
12949 * c-common.c (c_add_case_label): Omit the loc argument to
12950 build_case_label.
12951 * c-common.h (build_case_label): Remove.
12952 * c-semantics.c (build_case_label): Remove.
12953
a04a722b
JM
129542011-05-05 Joseph Myers <joseph@codesourcery.com>
12955
12956 * c-objc.h (objc_start_method_definition): Update prototype.
12957 * stub-objc.c (objc_start_method_definition): Add extra parameter.
12958
e19a18d4
NF
129592011-05-04 Nathan Froyd <froydnj@codesourcery.com>
12960
12961 * c-common.c (check_main_parameter_types): Reindent. Don't use
12962 TYPE_ARG_TYPES directly.
12963 (handle_nonnull_attribute): Likewise.
12964 (sync_resolve_params): Likewise.
12965 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
12966 to check_format_string.
12967 (handle_format_attribute): Likewise.
12968 (check_format_string): Take a function type to examine instead of
12969 a type list. Use a function_arg_iterator to step through argument
12970 types.
12971
c62c040f
RG
129722011-05-04 Richard Guenther <rguenther@suse.de>
12973
12974 * c-common.c (fix_string_type): Use size_int for index type bounds.
12975 (start_fname_decls): Do not pass NULL to build_int_cst.
12976 (c_init_attributes): Likewise.
12977 * c-lex.c (c_lex_with_flags): Likewise.
12978
c12ff9d8
JM
129792011-04-27 Jason Merrill <jason@redhat.com>
12980
12981 * c-common.c (make_tree_vector_from_list): New.
12982 * c-common.h: Declare it.
12983
304dfbe3
RG
129842011-04-26 Richard Guenther <rguenther@suse.de>
12985
12986 PR preprocessor/48248
12987 * c-ppoutput.c (maybe_print_line): Always optimize newlines
12988 for output size with -P.
12989
3c0d13bf
PC
129902011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
12991
12992 * c-common.c (struct c_common_resword): Add __underlying_type.
12993 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
12994
04695783
JM
129952011-04-20 Jim Meyering <meyering@redhat.com>
12996
12997 * c-format.c (init_dollar_format_checking): Remove useless
12998 if-before-free.
12999
0dc33c3c
NP
130002011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
13001
13002 * c-objc.h (objc_get_interface_ivars): Removed.
3c0d13bf 13003 (objc_detect_field_duplicates): New.
0dc33c3c 13004 * stub-objc.c: Likewise.
3c0d13bf 13005
c59633d9
NP
130062011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
13007
13008 * stub-objc.c (objc_declare_protocols): Renamed to
13009 objc_declare_protocol.
13010 * c-objc.h: Likewise.
3c0d13bf 13011
32dabdaf
NP
130122011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
13013
13014 * stub-objc.c (objc_declare_class): Updated argument name.
13015
81f653d6
NF
130162011-04-12 Nathan Froyd <froydnj@codesourcery.com>
13017
13018 * c-common.h (c_common_init_ts): Declare.
13019 * c-common.c (c_common_init_ts): Define.
13020
eb345401
NP
130212011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
13022
13023 * c-objc.h (objc_build_message_expr): Updated prototype.
13024 * stub-objc.c (objc_build_message_expr): Likewise.
9faeb493 13025
a358e188
MJ
130262011-04-12 Martin Jambor <mjambor@suse.cz>
13027
13028 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
13029 of cgraph_node.
13030
e6313a78
RG
130312011-04-11 Richard Guenther <rguenther@suse.de>
13032
13033 * c-common.c (complete_array_type): Build a range type of
13034 proper type.
13035
dcf0c47e
NF
130362011-04-08 Nathan Froyd <froydnj@codesourcery.com>
13037
13038 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
13039 (handle_type_generic_attribute): Likewise.
13040
1ee44b26
JM
130412011-04-07 Jason Merrill <jason@redhat.com>
13042
13043 PR c++/48450
13044 * c-common.c (c_common_truthvalue_conversion): Don't ignore
13045 conversion from C++0x scoped enum.
13046
acce4e77
JM
130472011-04-06 Joseph Myers <joseph@codesourcery.com>
13048
13049 * c-target-def.h: New file.
13050 * c-target.def: New file.
13051 * c-target.h: New file.
13052 * c-common.c (targetcm): Don't define here.
13053 * c-common.h (default_handle_c_option): Declare.
13054 * c-format.c: Include c-target.h instead of target.h.
13055 * c-opts.c: Include c-target.h instead of target.h. Explicitly
13056 include tm.h.
13057 (default_handle_c_option): Move from targhooks.c.
13058
e2eefb55
JJ
130592011-03-29 Jakub Jelinek <jakub@redhat.com>
13060
13061 PR preprocessor/48248
13062 * c-ppoutput.c (print): Add src_file field.
13063 (init_pp_output): Initialize it.
13064 (maybe_print_line): Don't optimize by adding up to 8 newlines
13065 if map->to_file and print.src_file are different file.
13066 (print_line): Update print.src_file.
13067
ba78087b
KT
130682011-03-25 Kai Tietz <ktietz@redhat.com>
13069
13070 * c-ada-spec.c (compare_comment): Use filename_cmp
13071 instead of strcmp for filename.
13072
0edf1bb2
JL
130732011-03-25 Jeff Law <law@redhat.com>
13074
adfac8df 13075 * c-common.c (def_fn_type): Add missing va_end.
0edf1bb2 13076
c7dc8804
JM
130772011-03-25 Jason Merrill <jason@redhat.com>
13078
13079 * c.opt: Add -std=c++03.
13080
d1d879b1
EB
130812011-03-22 Eric Botcazou <ebotcazou@adacore.com>
13082
13083 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
13084
3f8257db 130852011-03-17 Kai Tietz <ktietz@redhat.com>
62d784f7
KT
13086
13087 PR target/12171
5050afdf
KT
13088 * c-pretty-print.c (pp_c_specifier_qualifier_list):
13089 Display allowed attributes for function pointer types.
13090 (pp_c_attributes_display): New function to display
13091 attributes having affects_type_identity flag set to true.
13092 * c-pretty-print.h (pp_c_attributes_display): New prototype.
13093
62d784f7
KT
13094 * c-common.c (c_common_attribute_table):
13095 Add new element.
13096 (c_common_format_attribute_table): Likewise.
13097
82d37118
JM
130982011-03-18 Jason Merrill <jason@redhat.com>
13099
49a000c3
JM
13100 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
13101 * c-common.h: Don't declare it here.
13102 * c-common.c: Or define it here.
13103 * c-opts.c (c_common_handle_option): Or set it here.
13104
82d37118
JM
13105 PR c++/35315
13106 * c-common.c (handle_transparent_union_attribute): Don't
13107 make a duplicate type in C++.
13108
17bc631c
JM
131092011-03-15 Jason Merrill <jason@redhat.com>
13110
13111 * c-common.c (max_constexpr_depth): New.
13112 * c-common.h: Declare it.
13113 * c-opts.c (c_common_handle_option): Set it.
13114 * c.opt (fconstexpr-depth): New option.
13115
1b9b91a6
JM
131162011-03-11 Jason Merrill <jason@redhat.com>
13117
f231b5ff
JM
13118 * c-common.c (attribute_takes_identifier_p): Add missing const.
13119
1b9b91a6
JM
13120 PR c++/46803
13121 * c-common.c (attribute_takes_identifier_p): Assume that an
13122 unknown attribute takes an identifier.
13123
a19e4d44
NF
131242011-03-07 Nathan Froyd <froydnj@codesourcery.com>
13125
13126 PR c/47786
13127 * c-common.c (c_type_hash): Call list_length instead of iterating
13128 through DECL_CHAIN. Rename 'i' to 'n_elements'.
13129
982d62f6
JJ
131302011-02-19 Jakub Jelinek <jakub@redhat.com>
13131
13132 PR c/47809
13133 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
13134
0a256240
NP
131352011-02-17 Iain Sandoe <iains@gcc.gnu.org>
13136
13137 * c.opt (fobjc-abi-version=) New.
13138 (fobjc-nilcheck): New.
13139
ba9e6dd5
NF
131402011-02-03 Nathan Froyd <froydnj@codesourcery.com>
13141
13142 PR c++/46890
13143 * c-common.h (keyword_is_decl_specifier): Declare.
13144 * c-common.c (keyword_is_decl_specifier): Define.
13145 (keyword_is_function_specifier): New function.
13146
7273813a
JJ
131472011-01-26 Jakub Jelinek <jakub@redhat.com>
13148
13149 PR c/47473
13150 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
13151 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
13152 REAL_TYPE.
13153
908ef79b
AC
131542011-01-26 Arnaud Charlet <charlet@adacore.com>
13155
13156 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
13157
237e9384
JJ
131582011-01-26 Jakub Jelinek <jakub@redhat.com>
13159
13160 PR pch/47430
13161 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
13162 after init_c_lex if pch_file is set.
13163
47ea1edf
DK
131642011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
13165
d4dba752 13166 PR c++/43601
47ea1edf
DK
13167 * c.opt (-fkeep-inline-dllexport): New switch.
13168
2aa9c6ae
RG
131692011-01-12 Richard Guenther <rguenther@suse.de>
13170
13171 PR middle-end/32511
13172 * c-common.c (handle_weak_attribute): Warn instead of error
13173 on declaring an inline function weak.
13174
7bd11157
TT
131752011-01-05 Tom Tromey <tromey@redhat.com>
13176
13177 * c-common.h (lvalue_error): Update.
13178 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
13179 not error.
13180
0e66e494 131812010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
9faeb493 13182
b4f588c4
NP
13183 PR objc/47075
13184 * c-objc.h (objc_finish_message_expr): Added argument to
13185 prototype.
13186
f4da8dce
NF
131872010-12-22 Nathan Froyd <froydnj@codesourcery.com>
13188
13189 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
13190 Use prototype_p.
13191
46270f14
NP
131922010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
13193
13194 * c-objc.h (objc_maybe_warn_exceptions): New.
9faeb493 13195 * stub-objc.c (objc_maybe_warn_exceptions): New.
46270f14 13196
4816c593
NF
131972010-12-10 Nathan Froyd <froydnj@codesourcery.com>
13198
13199 * c-common.h (readonly_error): Declare.
13200 * c-common.c (readonly_error): Define.
13201
7a6daeb0
NF
132022010-12-09 Nathan Froyd <froydnj@codesourcery.com>
13203
13204 * c-common.h (invalid_indirection_error): Declare.
13205 * c-common.c (invalid_indirection_error): Define.
13206
892f6119
RG
132072010-12-03 Richard Guenther <rguenther@suse.de>
13208
13209 PR c/46745
13210 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
13211 (pp_c_unary_expression): Likewise.
13212 (pp_c_expression): Likewise.
13213
6c39e757
NP
132142010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
13215
13216 * c-common.h (objc_finish_function): New.
13217 (objc_non_volatilized_type): Removed.
13218 (objc_type_quals_match): Removed.
13219 * stub-objc.c (objc_finish_function): New.
13220 (objc_non_volatilized_type): Removed.
13221 (objc_type_quals_match): Removed.
9faeb493 13222
7c475d11
JM
132232010-11-30 Joseph Myers <joseph@codesourcery.com>
13224
13225 * c-common.h (parse_optimize_options): Declare.
13226 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
13227 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
13228
71f3e391
JM
132292010-11-29 Joseph Myers <joseph@codesourcery.com>
13230
13231 * c-opts.c (check_deps_environment_vars): Use getenv instead of
13232 GET_ENVIRONMENT.
13233 * c-pch.c (O_BINARY): Don't define here.
13234 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
13235
d5fabb58
JM
132362010-11-25 Joseph Myers <joseph@codesourcery.com>
13237
13238 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
13239 targetm.except_unwind_info.
13240
299404a1
JM
132412010-11-23 Joseph Myers <joseph@codesourcery.com>
13242
13243 * c-opts.c (c_common_handle_option): Pass location to
13244 set_struct_debug_option.
13245
c98cd5bf
JM
132462010-11-23 Joseph Myers <joseph@codesourcery.com>
13247
13248 * c-common.c (visibility_options): Move from ../opts.c.
13249 * c-common.h (struct visibility_flags, visibility_options):
13250 Declare here.
13251 * c-opts.c (finish_options): Rename to c_finish_options.
13252 (c_common_init): Update call to finish_options.
13253
a9546771
NP
132542010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
13255
13256 PR objc/34033
13257 * c-lex.c (lex_string): Check that each string in an Objective-C
13258 string concat sequence starts with either one or zero '@', and
13259 that there are no spurious '@' signs at the end.
13260
24a57808
JM
132612010-11-20 Joseph Myers <joseph@codesourcery.com>
13262
13263 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
13264 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
13265 HANDLE_PRAGMA_VISIBILITY.
13266 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
13267 HANDLE_PRAGMA_VISIBILITY): Don't define.
13268 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
13269
a9aa2c3a
NF
132702010-11-20 Nathan Froyd <froydnj@codesourcery.com>
13271
13272 PR c++/16189
13273 PR c++/36888
13274 PR c++/45331
13275 * c-common.h (keyword_begins_type_specifier): Declare.
13276 (keyword_is_storage_class_specifier): Declare.
13277 (keyword_is_type_qualifier): Declare.
13278 * c-common.c (keyword_begins_type_specifier): New function.
13279 (keyword_is_storage_class_specifier): New function.
13280 (keyword_is_type_qualifier): Declare.
13281
5386338c
JM
132822010-11-19 Joseph Myers <joseph@codesourcery.com>
13283
13284 PR c/46547
13285 * c-common.c (in_late_binary_op): Define.
13286 (c_common_truthvalue_conversion): Check in_late_binary_op before
13287 calling c_save_expr.
13288 * c-common.h (in_late_binary_op): Declare.
13289
69ccdddb
JM
132902010-11-19 Joseph Myers <joseph@codesourcery.com>
13291
13292 * c-opts.c (c_common_handle_option): Update calls to
13293 set_struct_debug_option.
13294
6b192a09
NP
132952010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
13296
13297 * c-common.h (objc_declare_protocols): Added additional argument.
13298 * stub-objc.c (objc_declare_protocol): Same change.
9faeb493 13299
fb52b50a
NF
133002010-11-18 Nathan Froyd <froydnj@codesourcery.com>
13301
13302 PR c/33193
13303 * c-common.h (build_real_imag_expr): Declare.
13304 * c-semantics.c (build_real_imag_expr): Define.
13305
b37421c6
JM
133062010-11-17 Joseph Myers <joseph@codesourcery.com>
13307
13308 * c-opts.c (c_common_parse_file): Take no arguments.
13309 * c-common.h (c_common_parse_file): Update prototype.
13310
07078664
JJ
133112010-11-16 Jakub Jelinek <jakub@redhat.com>
13312
13313 PR c++/46401
13314 * c-common.c (warning_candidate_p): Don't track non-const calls
13315 or STRING_CSTs.
13316
c6a13190
ILT
133172010-11-15 Ian Lance Taylor <iant@google.com>
13318
13319 * c-lex.c (init_c_lex): Set macro debug callbacks if
13320 flag_dump_go_spec is set.
13321
925e8657
NP
133222010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
13323
13324 * c-common.h (objc_build_incr_expr_for_property_ref): New.
13325 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
13326
bb0a9581
NF
133272010-11-15 Nathan Froyd <froydnj@codesourcery.com>
13328
13329 PR preprocessor/45038
13330 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
13331 dialects.
13332
c5fa0890
JM
133332010-11-12 Joseph Myers <joseph@codesourcery.com>
13334
13335 * c-common.h (c_family_lang_mask): Declare.
13336 * c-opts.c (c_family_lang_mask): Make extern.
13337 * c-pragma.c (handle_pragma_diagnostic): Use
13338 control_warning_option.
13339
a4d8c676
JM
133402010-11-12 Joseph Myers <joseph@codesourcery.com>
13341
13342 * c-common.c (parse_optimize_options): Update call to
13343 decode_options.
13344 * c-common.h (c_common_handle_option): Update prototype.
13345 * c-opts.c (c_common_handle_option): Take location_t parameter and
13346 pass it to other functions.
13347
f954bd2c
JM
133482010-11-11 Joseph Myers <joseph@codesourcery.com>
13349
13350 * c-opts.c (warning_as_error_callback): Remove.
13351 (c_common_initialize_diagnostics): Don't call
13352 register_warning_as_error_callback.
13353 (c_common_handle_option): Handle -Werror=normalized= here.
13354
d8a07487
JM
133552010-11-10 Joseph Myers <joseph@codesourcery.com>
13356
13357 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
13358 in diagnostic.
13359 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
13360 letter.
13361 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
13362 Remove trailing '.' from diagnostics.
13363 * c.opt (Wwrite-strings_: Avoid '`' in help text.
13364
d5478783
JM
133652010-11-10 Joseph Myers <joseph@codesourcery.com>
13366
13367 * c-common.c (parse_optimize_options): Pass global_dc to
13368 decode_options.
13369 * c-opts.c (c_common_handle_option): Pass &global_options to
13370 set_Wstrict_aliasing.
13371 * c.opt (v): Don't mark Common or document here.
13372
91ebb981
IS
133732010-11-06 Iain Sandoe <iains@gcc.gnu.org>
13374
13375 PR target/44981
13376 * c-format.c (format_type): New type gcc_objc_string_format_type.
13377 (valid_stringptr_type_p): New.
13378 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
9faeb493 13379 (check_format_string): Pass expected type, use
91ebb981
IS
13380 valid_stringptr_type_p (), check that the format string types are
13381 consistent with the format specification.
13382 (decode_format_attr): Warn if NSString is used outside objective-c.
13383 (format_types_orig): Add NSString.
13384 (format_name): New.
13385 (format_flags): New.
13386 (check_format_arg): Handle format strings requiring an external parser.
13387 first_target_format_type: New variable.
13388 (handle_format_attribute): Set up first_target_format_type, pass the
13389 expected format arg string type to check_format_string().
ab20d992 13390 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
91ebb981
IS
13391 * stub-objc.c (objc_string_ref_type_p): New.
13392 (objc_check_format_arg): New.
13393
bede2adc
NP
133942010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
13395
9faeb493 13396 Fixed using the Objective-C 2.0 dot-syntax with class names.
bede2adc
NP
13397 * c-common.h (objc_build_class_component_ref): New.
13398 * stub-objc.c (objc_build_class_component_ref): New.
13399
9a179d01
NP
134002010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
13401
13402 * c.opt (Wproperty-assign-default): New option.
13403
22d8d616
NP
134042010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
13405
13406 Implemented -fobjc-std=objc1 flag.
13407 * c.opt (fobjc-std=objc1): New option.
13408
2debdb4f
NP
134092010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
13410
13411 Implemented format and noreturn attributes for Objective-C methods.
13412 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
13413 attribute for Objective-C methods.
13414
ec52b111
JM
134152010-10-31 Jason Merrill <jason@redhat.com>
13416
13417 * c-common.c (conversion_warning, warn_for_collisions_1): Use
13418 EXPR_LOC_OR_HERE.
13419
46a88c12
NP
134202010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
13421
13422 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
13423 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
13424 (objc_add_property_declaration): Removed arguments for copies and
13425 ivar.
13426 (objc_build_getter_call): Renamed to
13427 objc_maybe_build_component_ref.
13428 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
13429 (objc_is_property_ref): New.
13430 * c-common.c (c_common_reswords): Removed copies and ivar.
13431 * stub-objc.c (objc_add_property_declaration): Removed arguments
13432 for copies and ivar.
13433 (objc_build_getter_call): Renamed to
13434 objc_maybe_build_component_ref.
13435 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
13436 (objc_is_property_ref): New.
9faeb493 13437
1e4bf85b
AC
134382010-10-29 Arnaud Charlet <charlet@adacore.com>
13439 Matthew Gingell <gingell@adacore.com>
13440
13441 * c-ada-spec.c (separate_class_package): New function.
13442 (pp_ada_tree_identifier): Prefix references to C++ classes with the
13443 name of their enclosing package.
13444 (print_ada_declaration): Use separate_class_package.
13445
81f0bab2
JM
134462010-10-27 Jason Merrill <jason@redhat.com>
13447
2b08f2c5
JM
13448 * c-common.c (c_common_reswords): Add __is_literal_type.
13449 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
13450
81f0bab2
JM
13451 * c-common.c (check_case_value): Remove special C++ code.
13452
200290f2
NP
134532010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
13454
13455 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
13456 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
13457 and RID_LAST_PATTR.
13458 (objc_add_property_declaration): Added additional arguments.
13459 (objc_property_attribute_kind): Removed.
13460 (objc_set_property_attr): Removed.
13461 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
13462 copy and nonatomic.
13463 * stub-objc.c (objc_add_property_declaration): Added additional
13464 arguments.
13465 (objc_set_property_attr): Removed.
9faeb493 13466
f614132b
NP
134672010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
13468
13469 * c-common.h (objc_add_property_variable): Renamed to
13470 objc_add_property_declaration. Added location argument.
13471 * stub-objc.c (objc_add_property_variable): Same change.
b1726d6c 13472
b8a18805
NP
134732010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
13474
13475 * c-common.h (objc_maybe_printable_name): New.
13476 * stub-objc.c (objc_maybe_printable_name): New.
13477
3f8257db
JJ
134782010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
13479 Andrew Pinski <pinskia@gmail.com>
30cd1c5d
AS
13480
13481 * c-common.h (c_common_mark_addressable_vec): Declare.
13482 * c-common.c (c_common_mark_addressable_vec): New function.
13483
249a82c4
NP
134842010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
13485
13486 * c-common.h (objc_set_method_type): Removed.
13487 (objc_add_method_declaration): Added boolean argument.
13488 (objc_start_method_definition): Same change.
13489 (objc_build_method_signature): Same change.
13490 * stub-objc.c (objc_set_method_type): Removed.
13491 (objc_add_method_declaration): Added boolean argument.
13492 (objc_start_method_definition): Same change.
13493 (objc_build_method_signature): Same change.
13494
977e30bc
NP
134952010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
13496
13497 * c-common.h (finish_file): Removed.
13498 (objc_write_global_declarations): New.
13499 * c-opts.c (c_common_parse_file): Do not call finish_file.
13500 * stub-objc.c (objc_write_global_declarations): New.
9faeb493 13501
da57d1b9
NP
135022010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
13503
13504 Implemented parsing @synthesize and @dynamic for
13505 Objective-C/Objective-C++.
13506 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
13507 (objc_add_synthesize_declaration): New.
13508 (objc_add_dynamic_declaration): New.
13509 * c-common.c (c_common_reswords): Add synthesize and dynamic.
13510 * stub-objc.c (objc_add_synthesize_declaration): New.
13511 (objc_add_dynamic_declaration): New.
9faeb493 13512
0069111f
MM
135132010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
13514
13515 PR target/46041
13516 * c-cppbuiltin.c (mode_has_fma): Move function here from
13517 builtins.c. Don't use the fma optab, instead just use the
13518 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
13519 using -save-temps.
13520
e426b47b
NP
135212010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
13522
13523 Merge from 'apple/trunk' branch on FSF servers.
0069111f 13524
3f8257db 13525 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
e426b47b 13526
9faeb493 13527 Radar 4330422
e426b47b
NP
13528 * c-common.h (objc_non_volatilized_type): New declaration
13529 * stub-objc.c (objc_non_volatilized_type): New stub.
13530
90fbfdc3
NP
135312010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
13532
e426b47b 13533 Merge from 'apple/trunk' branch on FSF servers.
90fbfdc3 13534
ab20d992 13535 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
90fbfdc3 13536
9faeb493 13537 Radar 4133425
90fbfdc3 13538 * c-common.h (objc_diagnose_private_ivar): New decl.
0069111f 13539 * stub-objc.c (objc_diagnose_private_ivar): New stub.
90fbfdc3 13540
c37d8c30
IS
135412010-10-17 Iain Sandoe <iains@gcc.gnu.org>
13542
13543 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
13544 * c-common.h (enum rid): Add RID_AT_PACKAGE.
13545 (objc_ivar_visibility_kind): New enum.
13546 (objc_set_visibility): Adjust prototype to use visibility enum.
0069111f 13547 * stub-objc.c (objc_set_visibility): Adjust stub to use
c37d8c30
IS
13548 visibility enum.
13549
1b1562a5
MM
135502010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
13551
13552 * c-cppbuiltin.c (builtin_define_float_constants): Emit
13553 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
13554 has the appropriate fma builtins.
13555 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
13556
668ea4b1
IS
135572010-10-14 Iain Sandoe <iains@gcc.gnu.org>
13558
1b1562a5 13559 merge from FSF apple 'trunk' branch.
3f8257db 13560 2006 Fariborz Jahanian <fjahanian@apple.com>
1b1562a5 13561
668ea4b1
IS
13562 Radars 4436866, 4505126, 4506903, 4517826
13563 * c-common.c (c_common_resword): Define @property and its attributes.
13564 * c-common.h: Define property attribute enum entries.
13565 (OBJC_IS_PATTR_KEYWORD): New.
13566 (objc_property_attribute_kind): New enum.
13567 Declare objc_set_property_attr (), objc_add_property_variable (),
13568 objc_build_getter_call () and objc_build_setter_call ().
13569 * stub-objc.c (objc_set_property_attr): New stub.
13570 (objc_add_property_variable): Likewise.
13571 (objc_build_getter_call): Likewise.
13572 (objc_build_setter_call) Likewise.
1b1562a5 13573
a1178b30
IS
135742010-10-13 Iain Sandoe <iains@gcc.gnu.org>
13575
1b1562a5 13576 merge from FSF apple 'trunk' branch.
ab20d992 13577 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
a1178b30
IS
13578
13579 Radar 3803157 (method attributes)
13580 * c-common.c (handle_deprecated_attribute): Recognize
13581 objc methods as valid declarations.
13582 * c-common.h: Declare objc_method_decl ().
1b1562a5 13583 * stub-objc.c (objc_method_decl): New stub.
a1178b30 13584
a75bfaa6
JM
135852010-10-08 Joseph Myers <joseph@codesourcery.com>
13586
13587 * c-common.c (parse_optimize_options): Call
13588 decode_cmdline_options_to_array_default_mask before
13589 decode_options. Update arguments to decode_options.
13590 * c-common.h (c_common_init_options_struct): Declare.
13591 * c-opts.c (c_common_init_options_struct): New. Split out from
13592 c_common_init_options.
13593
f05b9d93
NP
135942010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
13595
13596 Implemented fast enumeration for Objective-C.
13597 * c-common.h (objc_finish_foreach_loop): New.
13598 * stub-objc.c (objc_finish_foreach_loop): New.
13599
1ebe4b4f
JM
136002010-10-05 Joseph Myers <joseph@codesourcery.com>
13601
13602 * c-common.h (struct diagnostic_context): Don't declare here.
13603 (c_common_initialize_diagnostics): Declare using
13604 diagnostic_context typedef.
13605 * c-opts.c (c_common_handle_option): Pass global_dc to
13606 handle_generated_option.
13607
d4d24ba4
JM
136082010-10-04 Joseph Myers <joseph@codesourcery.com>
13609
13610 * c-opts.c (c_common_handle_option): Pass &global_options_set to
13611 handle_generated_option.
13612
478a1c5b
ILT
136132010-10-03 Ian Lance Taylor <iant@google.com>
13614
13615 * c.opt (-fplan9-extensions): New option.
13616
82a1c2fe
FXC
136172010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
13618
13619 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
13620 Remove.
13621 (c_cpp_builtins): Call functions from cppbuiltin.c instead
13622 of duplicating code.
13623
92902b1b
IS
136242010-09-30 Iain Sandoe <iains@gcc.gnu.org>
13625
13626 * c-common.c: Add two new entries for @optional
13627 and @required keywords.
13628
13629 merge from FSF 'apple/trunk' branch.
3f8257db 13630 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
92902b1b
IS
13631
13632 Radar 4386773
13633 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
13634 objective-c keywords.
13635 (objc_set_method_opt): New declaration.
13636 * stub-objc.c (objc_set_method_opt): New stub.
9faeb493 13637
46625112
JM
136382010-09-30 Joseph Myers <joseph@codesourcery.com>
13639
13640 * c-common.c (handle_optimize_attribute): Pass &global_options to
13641 cl_optimization_save and cl_optimization_restore.
13642 * c-opts.c (c_common_handle_option): Pass &global_options to
13643 handle_generated_option.
13644 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
13645 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
13646 &global_options to cl_optimization_restore.
13647
49b91f05
NP
136482010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
13649
13650 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
13651 Objective-C/Objective-C++ keywords.
13652
13ed556f 136532010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
a6341d57 13654
9faeb493
UB
13655 Merge from 'apple/trunk' branch on FSF servers.
13656
3f8257db 13657 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
a6341d57
NP
13658
13659 Radar 4281748
13660 * c-common.h (objc_check_global_decl): New declaration.
13661 * stub-objc.c (objc_check_global_decl): New stub.
13662
f0036cca
JM
136632010-09-29 Joseph Myers <joseph@codesourcery.com>
13664
13665 * c.opt: Don't use VarExists.
13666
e3339d0f
JM
136672010-09-29 Joseph Myers <joseph@codesourcery.com>
13668
13669 * c-common.c (c_cpp_error): Update names of diagnostic_context
13670 members.
13671 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
13672 cl_optimization members.
13673 * c-opts.c (warning_as_error_callback, c_common_handle_option,
13674 sanitize_cpp_opts, finish_options): Update names of cpp_options
13675 members.
13676
1973201f
NP
136772010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
13678
13679 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
13680 (objc_is_reserved_word): Removed.
13681 * c-common.c: Updated comments.
13682 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
13683 objc_is_reserved_word.
13684 * stub-objc.c (objc_is_reserved_word): Removed.
13685
f7e71da5
IS
136862010-09-28 Iain Sandoe <iains@gcc.gnu.org>
13687
9faeb493 13688 * c-common.h (objc_add_method_declaration): Adjust prototype to
f7e71da5
IS
13689 include attributes.
13690 (objc_start_method_definition): Likewise.
13691 (objc_build_keyword_decl): Likewise.
13692 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
13693 (objc_start_method_definition): Likewise.
13694 (objc_build_keyword_decl): Likewise.
13695
c165dca7
IS
136962010-09-28 Iain Sandoe <iains@gcc.gnu.org>
13697
13698 * c-common.h (objc_start_class_interface): Adjust prototype.
13699 (objc_start_category_interface): Likewise.
13700 (objc_start_protocol): Likewise.
13701 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
13702 (objc_start_class_interface): Likewise.
13703 (objc_start_category_interface): Likewise.
13704
7458026b
ILT
137052010-09-27 Ian Lance Taylor <iant@google.com>
13706
13707 * c-common.c (c_common_attribute_table): Add no_split_stack.
13708 (handle_no_split_stack_attribute): New static function.
13709
b581b85b
NP
137102010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
13711
9faeb493 13712 Merge from 'apple/trunk' branch on FSF servers.
b581b85b 13713
3f8257db 13714 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
b581b85b 13715
9faeb493 13716 Radar 4229905
b581b85b
NP
13717 * c-common.h (objc_have_common_type): New declaration.
13718 * stub-objc.c (objc_have_common_type): New stub.
13719
13720 2005-06-22 Ziemowit Laski <zlaski@apple.com>
13721
13722 Radar 4154928
13723 * c-common.h (objc_common_type): New prototype.
9faeb493 13724 * stub-objc.c (objc_common_type): New stub.
b581b85b 13725
46a4da10
JH
137262010-09-24 Jan Hubicka <jh@suse.cz>
13727
13728 * c-common.c (handle_leaf_attribute): New function.
13729 (struct attribute_spec c_common_att): Add leaf.
13730
e200444e
JM
137312010-09-22 Joseph Myers <joseph@codesourcery.com>
13732
13733 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
13734 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
13735 -dump, -dump=, -imacros, -imacros=, -include, -include=,
13736 -include-barrier, -include-directory, -include-directory=,
13737 -include-directory-after, -include-directory-after=,
13738 -include-prefix, -include-prefix=, -include-with-prefix,
13739 -include-with-prefix=, -include-with-prefix-after,
13740 -include-with-prefix-after=, -include-with-prefix-before,
13741 -include-with-prefix-before=, -no-integrated-cpp,
13742 -no-line-commands, -no-standard-includes, -no-warnings, -output,
13743 -output=, -pedantic, -pedantic-errors, -preprocess,
13744 -print-missing-file-dependencies, -trace-includes, -traditional,
13745 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
13746 -user-dependencies, -verbose, -write-dependencies,
13747 -write-user-dependencies, no-integrated-cpp, traditional): New.
13748
29a80ea6
NP
137492010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
13750
13751 PR objc/23710
ac1fc2fc
NP
13752 * c-common.h (objc_start_method_definition): Return bool instead
13753 of void.
13754 * stub-objc.c (objc_start_method_definition): Return bool instead
13755 of void.
13756
137572010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
13758
13759 PR objc/25965
13760 * c-common.h (objc_get_interface_ivars): New declaration.
13761 * stub-objc.c (objc_get_interface_ivars): New stub.
29a80ea6 13762
de621752
ILT
137632010-09-15 Ian Lance Taylor <iant@google.com>
13764
13765 * c-common.c (parse_optimize_options): Do not capitalize warning
06730c5d 13766 messages. Remove period at end of warning message.
de621752 13767
ba885ec5
NS
137682010-09-09 Nathan Sidwell <nathan@codesourcery.com>
13769
13770 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
13771 (handle_alias_attribute): ... here.
13772 (handle_ifunc_attribute): New.
13773
c5ee1358
MM
137742010-09-06 Mark Mitchell <mark@codesourcery.com>
13775
13776 * c-common.h (do_warn_double_promotion): Declare.
13777 * c-common.c (do_warn_double_promotion): Define.
13778
0a0b3574
MM
137792010-09-05 Mark Mitchell <mark@codesourcery.com>
13780
13781 * c.opt (Wdouble-promotion): New.
13782
d1779886
JM
137832010-09-02 Joseph Myers <joseph@codesourcery.com>
13784
13785 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
13786 fvtable-thunks, fxref): Mark no longer supported in help text.
13787
2d2bd949
JM
137882010-09-02 Joseph Myers <joseph@codesourcery.com>
13789
13790 * c.opt (Wimport, fall-virtual, falt-external-templates,
13791 fdefault-inline, fenum-int-equiv, fexternal-templates,
13792 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
13793 fname-mangling-version-, fnew-abi, fnonnull-objects,
13794 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
13795 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
13796 applicable.
13797 (fhandle-exceptions): Mark with Alias and Warn.
13798 * c-opts.c (c_common_handle_option): Don't handle options marked
13799 as ignored.
13800
5de8299c
JM
138012010-09-02 Joseph Myers <joseph@codesourcery.com>
13802
13803 * c.opt (Wcomments, Werror-implicit-function-declaration,
13804 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
13805 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
13806 aliases.
13807 * c-common.c (option_codes): Use OPT_Wcomment instead of
13808 OPT_Wcomments.
13809 * c-opts.c (warning_as_error_callback, c_common_handle_option):
13810 Don't handle options marked as aliases.
13811
0ceb0201
RG
138122010-08-25 Richard Guenther <rguenther@suse.de>
13813
13814 * c-common.c (c_common_get_alias_set): Remove special
13815 handling for pointers.
13816
ac47786e
NF
138172010-08-20 Nathan Froyd <froydnj@codesourcery.com>
13818
13819 * c-common.c: Use FOR_EACH_VEC_ELT.
13820 * c-gimplify.c: Likewise.
13821 * c-pragma.c: Likewise.
13822
c878765b
JM
138232010-08-16 Joseph Myers <joseph@codesourcery.com>
13824
13825 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
13826 RejectDriver.
13827 (MMDX): Change back to MMD. Mark NoDriverArg instead of
13828 RejectDriver.
13829 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
13830 instead of OPT_MDX and OPT_MMDX.
13831
603349bf
JM
138322010-08-16 Joseph Myers <joseph@codesourcery.com>
13833
13834 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
13835
644fa7ac
JM
138362010-08-12 Joseph Myers <joseph@codesourcery.com>
13837
13838 * c.opt (MD, MMD): Change to MDX and MMDX.
13839 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
13840
481e1176
JM
138412010-08-11 Joseph Myers <joseph@codesourcery.com>
13842
13843 * c-opts.c (c_common_handle_option): Call handle_generated_option
13844 instead of handle_option.
13845
ac8dc9f7
NF
138462010-08-08 Nathan Froyd <froydnj@codesourcery.com>
13847
13848 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
13849 (maybe_apply_renaming_pragma): Delete unneeded declarations.
13850
4f8c876d
NF
138512010-08-08 Nathan Froyd <froydnj@codesourcery.com>
13852
13853 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
13854 (pending_redefine_extname): Change type to a VEC.
13855 (add_to_renaming_pragma_list): Update for new type of
13856 pending_redefine_extname.
ac8dc9f7 13857 (maybe_apply_renaming_pragma): Likewise.
4f8c876d 13858
3b0c690e
AC
138592010-08-04 Arnaud Charlet <charlet@adacore.com>
13860
13861 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
13862 visited.
13863 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
13864 decide whether a type has already been declared/seen.
13865 Do not go to the original type.
13866 (dump_nested_types): New parameter forward.
13867 Generate forward declaration if needed and mark type as visited.
13868 (print_ada_declaration): Call dump_nested_types if not already done.
13869 Mark types as visited.
13870
1890bccc
JM
138712010-08-03 Joseph Myers <joseph@codesourcery.com>
13872
13873 * c.opt (-print-pch-checksum): Remove option.
13874 * c-opts.c (c_common_handle_option): Don't handle
13875 OPT_print_pch_checksum.
13876
5f20c657
JM
138772010-07-27 Joseph Myers <joseph@codesourcery.com>
13878
13879 * c-common.h (c_common_handle_option): Update prototype and return
13880 value type.
13881 * c-opts.c (c_common_handle_option): Update prototype and return
13882 value type. Update calls to handle_option and
13883 enable_warning_as_error.
13884
f551f80c
JJ
138852010-07-27 Jakub Jelinek <jakub@redhat.com>
13886
13887 PR c/45079
13888 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
13889
61ff2bdc
JM
138902010-07-27 Joseph Myers <joseph@codesourcery.com>
13891
13892 * c-common.h (c_common_missing_argument): Remove.
13893 * c-opts.c (c_common_missing_argument): Remove.
13894 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
13895 idirafter, imacros, include, isysroot, isystem, iquote): Add
13896 MissingArgError.
13897 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
13898
7a9bf9a4
JM
138992010-07-27 Joseph Myers <joseph@codesourcery.com>
13900
13901 * c-common.h (c_common_option_lang_mask,
13902 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
13903 New.
13904 (c_common_init_options): Update prototype.
13905 * c-opts.c (c_common_option_lang_mask): New.
13906 (c_common_initialize_diagnostics): Split out of
13907 c_common_init_options.
13908 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
13909 New.
13910 (c_common_init_options): Update prototype. Use decoded options in
13911 search for -lang-asm.
13912
910ad8de
NF
139132010-07-15 Nathan Froyd <froydnj@codesourcery.com>
13914
13915 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
13916 * c-format.c: Likewise.
13917
718f9c0f
MLI
139182010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
13919
13920 * c-common.h: Include diagnostic-core.h. Error if already
13921 included.
13922 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
13923
4d451982
MLI
139242010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
13925
adfac8df 13926 * c-common.c (IN_GCC_FRONTEND): Do not undef.
4d451982
MLI
13927 Do not include expr.h
13928 (vector_mode_valid_p): Move here.
13929
119fe915
SB
139302010-06-21 DJ Delorie <dj@redhat.com>
13931
13932 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
13933 allow these pragmas anywhere.
13934
139352010-06-14 Jakub Jelinek <jakub@redhat.com>
13936
13937 PR bootstrap/44509
13938 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
13939 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
13940 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
13941 ggc_strdup instead of xstrdup.
13942
139432010-06-10 Jakub Jelinek <jakub@redhat.com>
13944
13945 * c-cppbuiltin.c: Include cpp-id-data.h.
13946 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
13947 (lazy_hex_fp_value): New function.
13948 (builtin_define_with_hex_fp_value): Provide definitions lazily.
13949
6662d794
MLI
139502010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
13951
13952 * c-gimplify.c: Do not include tree-flow.h
13953
38f8b050
JR
139542010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
13955
13956 PR other/44034
13957 * c-common.c: Rename targetm member:
13958 targetm.enum_va_list -> targetm.enum_va_list_p
13959
9589f23e
AS
139602010-06-28 Anatoly Sokolov <aesok@post.ru>
13961
13962 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
13963
3b06d379
SB
139642010-06-28 Steven Bosscher <steven@gcc.gnu.org>
13965
13966 * c-cppbuiltin.c: Do not include except.h.
13967
d166d4c3
AK
139682010-06-24 Andi Kleen <ak@linux.intel.com>
13969
9faeb493
UB
13970 * c-common.c (warn_for_omitted_condop): New.
13971 * c-common.h (warn_for_omitted_condop): Add prototype.
d166d4c3 13972
70cb8be6
JM
139732010-06-21 Joseph Myers <joseph@codesourcery.com>
13974
13975 * c.opt (lang-objc): Remove.
13976 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
13977
a4c97feb
JR
139782010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
13979
13980 * c-opts.c: Include "tm_p.h".
13981
6e2f1956
JM
139822010-06-20 Joseph Myers <joseph@codesourcery.com>
13983
13984 * c-common.c (parse_optimize_options): Update call to
13985 decode_options.
13986
bc87224e
NF
139872010-06-18 Nathan Froyd <froydnj@codesourcery.com>
13988
13989 * c-common.c (record_types_used_by_current_var_decl): Adjust for
13990 new type of types_used_by_cur_var_decl.
13991
b49cf425
JR
139922010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
13993
13994 PR bootstrap/44512
13995 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
13996 for C++ standard compliance.
13997
59f9c2ed
JM
139982010-06-16 Jason Merrill <jason@redhat.com>
13999
14000 * c.opt: Add -Wnoexcept.
14001
33766b66
RG
140022010-06-16 Richard Guenther <rguenther@suse.de>
14003
14004 PR c/44555
14005 * c-common.c (c_common_truthvalue_conversion): Remove
14006 premature and wrong optimization concering ADDR_EXPRs.
14007
eff7e30c
AC
140082010-06-15 Arnaud Charlet <charlet@adacore.com>
14009
14010 * c-ada-spec.c (dump_sloc): Remove column info.
14011 (is_simple_enum): New function.
14012 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
14013 enum types when relevant.
14014
6312e84d
MLI
140152010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
14016
9faeb493 14017 * c-common.c (conversion_warning): Warn at expression
6312e84d
MLI
14018 location.
14019
1cb42611
JM
140202010-06-10 Joseph Myers <joseph@codesourcery.com>
14021
14022 * c-opts.c (c_common_handle_option): Don't handle
14023 OPT_fshow_column.
14024
a9429e29
LB
140252010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
14026
14027 * c-pragma.c (push_alignment): Use typed GC allocation.
14028 (handle_pragma_push_options): Likewise.
14029
14030 * c-common.c (parse_optimize_options): Likewise.
14031
14032 * c-common.h (struct sorted_fields_type): Add variable_size GTY
14033 option.
14034
5498f011
JM
140352010-06-07 Joseph Myers <joseph@codesourcery.com>
14036
14037 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
14038 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
14039 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
14040 flag_signed_bitfields, warn_strict_null_sentinel,
14041 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
14042 flag_gen_declaration, flag_no_gnu_keywords,
14043 flag_implement_inlines, flag_implicit_templates,
14044 flag_implicit_inline_templates, flag_optional_diags,
14045 flag_elide_constructors, flag_default_inline, flag_rtti,
14046 flag_conserve_space, flag_access_control, flag_check_new,
14047 flag_new_for_scope, flag_weak, flag_working_directory,
14048 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
14049 flag_enforce_eh_specs, flag_threadsafe_statics,
14050 flag_pretty_templates): Remove.
14051 * c-common.h (flag_preprocess_only, flag_nil_receivers,
14052 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
14053 flag_replace_objc_classes, flag_undef, flag_no_builtin,
14054 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
14055 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
14056 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
14057 flag_no_gnu_keywords, flag_implement_inlines,
14058 flag_implicit_templates, flag_implicit_inline_templates,
14059 flag_optional_diags, flag_elide_constructors, flag_default_inline,
14060 flag_rtti, flag_conserve_space, flag_access_control,
14061 flag_check_new, flag_new_for_scope, flag_weak,
14062 flag_working_directory, flag_use_cxa_atexit,
14063 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
14064 flag_threadsafe_statics, flag_pretty_templates,
14065 warn_strict_null_sentinel): Remove.
14066 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
14067 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
14068 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
14069 fimplicit-inline-templates, fimplicit-templates,
14070 flax-vector-conversions, fms-extensions, fnil-receivers,
14071 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
14072 frtti, fshort-double, fshort-enums, fshort-wchar,
14073 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
14074 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
14075 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
14076 gen-decls, undef): Use Var.
14077 (fdefault-inline, foptional-diags): Document as doing nothing.
14078 * c-opts.c (c_common_handle_option): Remove cases for options now
14079 using Var. Mark ignored options as such.
14080
39dabefd
SB
140812010-06-05 Steven Bosscher <steven@gcc.gnu.org>
14082
9faeb493 14083 * c-common.c: Moved to here from parent directory.
39dabefd
SB
14084 * c-common.def: Likewise.
14085 * c-common.h: Likewise.
14086 * c-cppbuiltin.c: Likewise.
14087 * c-dump.c: Likewise.
14088 * c-format.c: Likewise.
14089 * c-format.h : Likewise.
14090 * c-gimplify.c: Likewise.
14091 * c-lex.c: Likewise.
14092 * c-omp.c: Likewise.
14093 * c.opt: Likewise.
14094 * c-opts.c: Likewise.
14095 * c-pch.c: Likewise.
14096 * c-ppoutput.c: Likewise.
14097 * c-pragma.c: Likewise.
14098 * c-pragma.h: Likewise.
14099 * c-pretty-print.c: Likewise.
14100 * c-pretty-print.h: Likewise.
14101 * c-semantics.c: Likewise.
14102 * stub-objc.c: Likewise.
14103
14104 * c-common.c: Include gt-c-family-c-common.h.
14105 * c-pragma.c: Include gt-c-family-c-pragma.h.
14106\f
68127a8e 14107Copyright (C) 2010-2023 Free Software Foundation, Inc.
39dabefd
SB
14108
14109Copying and distribution of this file, with or without modification,
14110are permitted in any medium without royalty provided the copyright
14111notice and this notice are preserved.
This page took 4.924577 seconds and 5 git commands to generate.