]> gcc.gnu.org Git - gcc.git/blame - gcc/c-family/ChangeLog
Add cpplib ro.po
[gcc.git] / gcc / c-family / ChangeLog
CommitLineData
9ff6c33e
GA
12022-10-07 Qing Zhao <qing.zhao@oracle.com>
2
3 * c-attribs.cc (handle_strict_flex_array_attribute): New function.
4 (c_common_attribute_table): New item for strict_flex_array.
5 * c.opt: (fstrict-flex-arrays): New option.
6 (fstrict-flex-arrays=): New option.
7
82022-10-07 Martin Liska <mliska@suse.cz>
9
10 * name-hint.h: Use std::move.
11
122022-10-07 Jakub Jelinek <jakub@redhat.com>
13
14 * c-common.cc (attribute_fallthrough_p): Lookup fallthrough attribute
15 only in gnu namespace or as standard attribute, treat fallthrough
16 attributes in other namespaces like any other unknown attribute.
17
629d04d3
GA
182022-10-06 Joseph Myers <joseph@codesourcery.com>
19
20 * c-common.cc (c_common_reswords): Mark typeof as D_EXT11. Add
21 typeof_unqual.
22 * c-common.h (enum rid): Add RID_TYPEOF_UNQUAL.
23 (D_EXT11): New macro. Values of subsequent macros updated.
24
252022-10-06 Jakub Jelinek <jakub@redhat.com>
26
27 PR c++/106654
28 * c-attribs.cc (handle_assume_attribute): New function.
29 (c_common_attribute_table): Add entry for assume attribute.
30 * c-lex.cc (c_common_has_attribute): Handle
31 __have_cpp_attribute (assume).
32
85872a69
GA
332022-10-04 Jakub Jelinek <jakub@redhat.com>
34
35 * c-omp.cc (c_omp_directives): Uncomment begin declare target
36 entry.
37
69fd6dcc
GA
382022-10-03 Patrick Palka <ppalka@redhat.com>
39
40 * c-common.cc (c_common_reswords): Use RID_IS_SAME instead of
41 RID_IS_SAME_AS.
42
432022-10-03 Joseph Myers <joseph@codesourcery.com>
44
45 * c-cppbuiltin.cc (builtin_define_float_constants): Do not
46 special-case __*_EPSILON__ setting for IBM long double for C2x.
47
3a221b73
GA
482022-09-30 Patrick Palka <ppalka@redhat.com>
49
50 * c-common.cc (c_common_reswords): Use cp/cp-trait.def to handle
51 C++ traits.
52 * c-common.h (enum rid): Likewise.
53
bbdcdf5c
GA
542022-09-29 Joseph Myers <joseph@codesourcery.com>
55
56 * c-lex.cc (c_common_has_attribute): Handle noreturn attribute for
57 C.
58
592022-09-29 Patrick Palka <ppalka@redhat.com>
60
61 * c-common.cc (c_common_reswords): Add __remove_cv,
62 __remove_reference and __remove_cvref.
63 * c-common.h (enum rid): Add RID_REMOVE_CV, RID_REMOVE_REFERENCE
64 and RID_REMOVE_CVREF.
65
1f16a020
GA
662022-09-27 Marek Polacek <polacek@redhat.com>
67
68 PR c++/101165
69 PR c++/106882
70 * c-cppbuiltin.cc (c_cpp_builtins): Define __cpp_implicit_move.
71
722022-09-27 Marek Polacek <polacek@redhat.com>
73
74 * c-format.cc (c_keywords): Drop nothrow.
75
762022-09-27 Jakub Jelinek <jakub@redhat.com>
77
78 PR c++/106651
79 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
80 __cpp_static_call_operator=202207L for C++23.
81
822022-09-27 Jakub Jelinek <jakub@redhat.com>
83
84 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ASSUME,
85 PRAGMA_OMP_ASSUMES and PRAGMA_OMP_BEGIN. Rename
86 PRAGMA_OMP_END_DECLARE_TARGET to PRAGMA_OMP_END.
87 * c-pragma.cc (omp_pragmas): Add assumes and begin.
88 For end rename PRAGMA_OMP_END_DECLARE_TARGET to PRAGMA_OMP_END.
89 (omp_pragmas_simd): Add assume.
90 * c-common.h (c_omp_directives): Declare.
91 * c-omp.cc (omp_directives): Rename to ...
92 (c_omp_directives): ... this. No longer static. Uncomment
93 assume, assumes, begin assumes and end assumes entries.
94 In end declare target entry rename PRAGMA_OMP_END_DECLARE_TARGET
95 to PRAGMA_OMP_END.
96 (c_omp_categorize_directive): Adjust for omp_directives to
97 c_omp_directives renaming.
98
992022-09-27 Jakub Jelinek <jakub@redhat.com>
100
101 PR c++/106652
102 PR c++/85518
103 * c-common.cc (c_common_reswords): Change _Float{16,32,64,128} and
104 _Float{32,64,128}x flags from D_CONLY to 0.
105 (shorten_binary_op): Punt if common_type returns error_mark_node.
106 (shorten_compare): Likewise.
107 (c_common_nodes_and_builtins): For C++ record _Float{16,32,64,128}
108 and _Float{32,64,128}x builtin types if available. For C++
109 clear float128t_type_node.
110 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
111 __STDCPP_FLOAT{16,32,64,128}_T__ for C++23 if supported.
112 * c-lex.cc (interpret_float): For q/Q suffixes prefer
113 float128t_type_node over float128_type_node. Allow
114 {f,F}{16,32,64,128} suffixes for C++ if supported with pedwarn
115 for C++20 and older. Allow {f,F}{32,64,128}x suffixes for C++
116 with pedwarn. Don't call excess_precision_type for C++.
117
220c4d8e
GA
1182022-09-26 Marek Polacek <polacek@redhat.com>
119
120 PR c++/106656
121 * c-cppbuiltin.cc (c_cpp_builtins): Update value of __cpp_char8_t
122 for C++20.
123
4afaeaab
GA
1242022-09-23 Marek Polacek <polacek@redhat.com>
125
126 PR c++/106784
127 * c-common.cc (c_common_reswords): Add __is_convertible and
128 __is_nothrow_convertible.
129 * c-common.h (enum rid): Add RID_IS_CONVERTIBLE and
130 RID_IS_NOTHROW_CONVERTIBLE.
131
279c6715
GA
1322022-09-22 David Malcolm <dmalcolm@redhat.com>
133
134 PR c/106830
135 * c-warn.cc (check_for_xor_used_as_pow): Don't try checking
136 values that don't fit in uhwi.
137
d0fc05e8
GA
1382022-09-15 Richard Biener <rguenther@suse.de>
139
140 * c-common.h (build_void_list_node): Remove.
141 * c-common.cc (c_common_nodes_and_builtins): Do not initialize
142 void_list_node.
143
861d1a11
GA
1442022-09-09 Jan-Benedict Glaw <jbglaw@lug-owl.de>
145
146 * c-format.cc (convert_format_name_to_system_name): Fix warning.
147
fe2a8ce9
GA
1482022-09-07 Joseph Myers <joseph@codesourcery.com>
149
150 * c-common.cc (c_common_reswords): Use D_C2X instead of D_CXXONLY
151 for alignas, alignof, bool, false, static_assert, thread_local and
152 true.
153
1542022-09-07 Jakub Jelinek <jakub@redhat.com>
155
156 * c.opt (Winvalid-utf8): Use ObjC instead of objC. Remove
157 " in comments" from description.
158 (Wunicode): New option.
159
25aeb922
GA
1602022-09-06 Jakub Jelinek <jakub@redhat.com>
161
162 PR c/106836
163 * c-omp.cc (c_omp_split_clauses): Handle OMP_CLAUSE_DOACROSS.
164
83f2f228
GA
1652022-09-03 Jakub Jelinek <jakub@redhat.com>
166
167 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DOACROSS.
168 * c-omp.cc (c_finish_omp_depobj): Check also for OMP_CLAUSE_DOACROSS
169 clause and diagnose it. Don't handle OMP_CLAUSE_DEPEND_SOURCE and
170 OMP_CLAUSE_DEPEND_SINK. Assert kind is not OMP_CLAUSE_DEPEND_INVALID.
171
c64b0947
GA
1722022-09-02 David Malcolm <dmalcolm@redhat.com>
173
174 PR c/90885
175 * c-common.h (check_for_xor_used_as_pow): New decl.
176 * c-lex.cc (c_lex_with_flags): Add DECIMAL_INT to flags as appropriate.
177 * c-warn.cc (check_for_xor_used_as_pow): New.
178 * c.opt (Wxor-used-as-pow): New.
179
bb0a1556
GA
1802022-09-01 Jason Merrill <jason@redhat.com>
181
182 * c-common.cc (c_common_nodes_and_builtins): Set TREE_STRING_FLAG on
183 char8_t.
184 (braced_list_to_string): Check for char-sized elements.
185
1862022-09-01 Jakub Jelinek <jakub@redhat.com>
187
188 PR c++/106655
189 * c.opt (-Winvalid-utf8): New warning.
190 * c-opts.cc (c_common_handle_option) <case OPT_finput_charset_>:
191 Set cpp_opts->cpp_input_charset_explicit.
192 (c_common_post_options): If -finput-charset=UTF-8 is explicit
193 in C++23, enable -Winvalid-utf8 by default and if -pedantic
194 or -pedantic-errors, make it a pedwarn.
195
542c60c4
GA
1962022-08-31 Joseph Myers <joseph@codesourcery.com>
197
198 * c-attribs.cc (handle_deprecated_attribute): Check and pedwarn
199 for LABEL_DECL.
200 * c-common.cc (c_add_case_label): Add argument ATTRS. Call
201 decl_attributes.
202 * c-common.h (do_case, c_add_case_label): Update declarations.
203 * c-lex.cc (c_common_has_attribute): For C, produce a result of
204 201910 for fallthrough and 202106 for maybe_unused.
205
16f542d6
GA
2062022-08-26 Marek Polacek <polacek@redhat.com>
207
208 PR c++/81159
209 * c.opt (Wself-move): New option.
210
2112022-08-26 Jakub Jelinek <jakub@redhat.com>
212
213 * c-common.cc (check_builtin_function_arguments): Handle
214 BUILT_IN_ISSIGNALING.
215
2162022-08-26 Jakub Jelinek <jakub@redhat.com>
217
218 PR c++/106648
219 * c-cppbuiltin.cc (c_cpp_builtins): Predefine
220 __cpp_named_character_escapes to 202207L.
221
5d4389dc
GA
2222022-08-25 Marek Polacek <polacek@redhat.com>
223
224 * c-common.cc (c_common_reswords): Enable nullptr in C2X.
225 (c_common_nodes_and_builtins): Create the built-in node for nullptr.
226 * c-common.h (enum c_tree_index): Add CTI_NULLPTR, CTI_NULLPTR_TYPE.
227 (struct c_common_resword): Resize the disable member.
228 (D_C2X): Add.
229 (nullptr_node): Define.
230 (nullptr_type_node): Define.
231 (NULLPTR_TYPE_P): Define.
232 * c-pretty-print.cc (c_pretty_printer::simple_type_specifier): Handle
233 NULLPTR_TYPE.
234 (c_pretty_printer::direct_abstract_declarator): Likewise.
235 (c_pretty_printer::constant): Likewise.
236
47a61e65
GA
2372022-08-16 Tom Honermann <tom@honermann.net>
238
239 PR c++/106423
240 * c-opts.cc (c_common_post_options): Disable -Wc++20-compat
241 diagnostics in C++20 and later.
242 * c.opt (Wc++20-compat): Enable hooks for the preprocessor.
243
5cd525f0
GA
2442022-08-11 Marek Polacek <polacek@redhat.com>
245
246 PR middle-end/102633
247 * c-gimplify.cc (c_gimplify_expr) <case DECL_EXPR>: Don't call
248 suppress_warning here.
249
5f17badb
GA
2502022-08-08 Tom Honermann <tom@honermann.net>
251
252 PR preprocessor/106426
253 * c-opts.cc (c_common_post_options): Assign cpp_opts->unsigned_utf8char
254 subject to -fchar8_t, -fsigned-char, and/or -funsigned-char.
255
2562022-08-08 Tom Honermann <tom@honermann.net>
257
258 * c-lex.cc (lex_string, lex_charconst): Use char8_t as the type
259 of CPP_UTF8CHAR and CPP_UTF8STRING when char8_t support is
260 enabled.
261 * c-opts.cc (c_common_post_options): Set flag_char8_t if
262 targeting C2x.
263
4a7274dd
GA
2642022-07-31 Lewis Hyatt <lhyatt@gmail.com>
265
266 PR c++/66290
267 * c-common.h: Rename global done_lexing to
268 override_libcpp_locations.
269 * c-common.cc (c_cpp_diagnostic): Likewise.
270 * c-opts.cc (c_common_finish): Set override_libcpp_locations
271 (formerly done_lexing) immediately prior to calling cpp_finish ().
272
1e2c5f4c
GA
2732022-07-27 Lewis Hyatt <lhyatt@gmail.com>
274
275 * c-ppoutput.cc (token_streamer::stream): Update input_location
276 prior to streaming each token.
277
0e6fa997
GA
2782022-07-23 Immad Mir <mirimmad@outlook.com>
279
280 * c-attribs.cc: (c_common_attribute_table): add three new attributes
281 namely: fd_arg, fd_arg_read and fd_arg_write.
282 (handle_fd_arg_attribute): New.
283
bdc7b765
GA
2842022-07-15 Marek Polacek <polacek@redhat.com>
285
286 PR c++/104477
287 * c-common.cc (c_common_reswords): Add
288 __reference_constructs_from_temporary and
289 __reference_converts_from_temporary.
290 * c-common.h (enum rid): Add RID_REF_CONSTRUCTS_FROM_TEMPORARY and
291 RID_REF_CONVERTS_FROM_TEMPORARY.
292
2932022-07-15 Jonathan Wakely <jwakely@redhat.com>
294
295 * c-format.cc (class range_label_for_format_type_mismatch):
296 Adjust to new label_text API.
297
c72d4714
GA
2982022-07-11 Lewis Hyatt <lhyatt@gmail.com>
299
300 PR preprocessor/106252
301 * c-pragma.cc (handle_pragma_diagnostic_impl): Don't look up the
302 option argument prior to verifying the option was found.
303
6345c414
GA
3042022-07-07 David Malcolm <dmalcolm@redhat.com>
305
306 * c-format.cc (range_label_for_format_type_mismatch::get_text):
307 Update for removal of label_text::maybe_free in favor of automatic
308 memory management.
309
4bc92c3b
GA
3102022-07-06 Lewis Hyatt <lhyatt@gmail.com>
311
312 PR preprocessor/53920
313 PR c++/53431
314 * c-common.cc (c_option_is_from_cpp_diagnostics): New function.
315 * c-common.h (c_option_is_from_cpp_diagnostics): Declare.
316 (c_pp_stream_token): Declare.
317 * c-ppoutput.cc (init_pp_output): Refactor logic about skipping
318 pragmas to...
319 (should_output_pragmas): ...here. New function.
320 (token_streamer::stream): Support handling early pragmas.
321 (do_line_change): Likewise.
322 (c_pp_stream_token): New function.
323 * c-pragma.cc (struct pragma_diagnostic_data): New helper class.
324 (pragma_diagnostic_lex_normal): New function. Moved logic for
325 interpreting GCC diagnostic pragmas here.
326 (pragma_diagnostic_lex_pp): New function for parsing diagnostic pragmas
327 directly from libcpp.
328 (handle_pragma_diagnostic): Refactor into helper function...
329 (handle_pragma_diagnostic_impl): ...here. New function.
330 (handle_pragma_diagnostic_early): New function.
331 (handle_pragma_diagnostic_early_pp): New function.
332 (struct pragma_ns_name): Renamed to...
333 (struct pragma_pp_data): ...this. Add new "early_handler" member.
334 (c_register_pragma_1): Support early pragmas in the preprocessor.
335 (c_register_pragma_with_early_handler): New function.
336 (c_register_pragma): Support the new early handlers in struct
337 internal_pragma_handler.
338 (c_register_pragma_with_data): Likewise.
339 (c_register_pragma_with_expansion): Likewise.
340 (c_register_pragma_with_expansion_and_data): Likewise.
341 (c_invoke_early_pragma_handler): New function.
342 (c_pp_invoke_early_pragma_handler): New function.
343 (init_pragma): Add early pragma support for diagnostic pragmas.
344 * c-pragma.h (struct internal_pragma_handler): Add new early handler
345 members.
346 (c_register_pragma_with_early_handler): Declare.
347 (c_invoke_early_pragma_handler): Declare.
348 (c_pp_invoke_early_pragma_handler): Declare.
349
d1f3a3ff
GA
3502022-07-05 Marek Polacek <polacek@redhat.com>
351
352 PR c++/105626
353 * c-format.cc (check_format_arg): Don't emit -Wformat warnings with
354 u8 strings.
355
ed974488
GA
3562022-07-01 Marek Polacek <polacek@redhat.com>
357
358 PR c++/106111
359 * c-common.h (enum rid): Update RID_LAST_CXX20.
360
976196b3
GA
3612022-06-30 Jonathan Wakely <jwakely@redhat.com>
362
363 * known-headers.cc (get_stdlib_header_for_name): Add <time.h>
364 names.
365
84c2131d
GA
3662022-06-24 Jason Merrill <jason@redhat.com>
367
368 PR c++/87729
369 PR c++/20423
370 * c.opt (Woverloaded-virtual): Add levels, include in -Wall.
371
4390e7bf
GA
3722022-06-18 Jakub Jelinek <jakub@redhat.com>
373
374 * c-ubsan.cc (ubsan_instrument_division, ubsan_instrument_shift):
375 Use flag_sanitize_trap & SANITIZE_??? instead of
376 flag_sanitize_undefined_trap_on_error. If 2 sanitizers are involved
377 and flag_sanitize_trap differs for them, emit __builtin_trap only
378 for the comparison where trap is requested.
379 (ubsan_instrument_vla, ubsan_instrument_return): Use
380 lag_sanitize_trap & SANITIZE_??? instead of
381 flag_sanitize_undefined_trap_on_error.
382
c3642271
GA
3832022-06-13 Jason Merrill <jason@redhat.com>
384
385 * c-ubsan.cc (ubsan_instrument_return): Use BUILTINS_LOCATION.
386
d9176e64
GA
3872022-05-27 Marek Polacek <polacek@redhat.com>
388
389 PR c/90658
390 * c-attribs.cc (get_priority): Check FUNCTION_DECL.
391
3922022-05-27 Jakub Jelinek <jakub@redhat.com>
393
394 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ENTER.
395
57f2ce6a
GA
3962022-05-20 David Malcolm <dmalcolm@redhat.com>
397
398 * c-format.cc: Replace uses of "FINAL" and "OVERRIDE" with "final"
399 and "override".
400 * c-pretty-print.h: Likewise.
401
1cda629f
GA
4022022-05-18 Marek Polacek <polacek@redhat.com>
403
404 PR c/105131
405 * c.opt (Wenum-int-mismatch): New.
406
4072022-05-18 Marek Polacek <polacek@redhat.com>
408
409 PR c++/105497
410 * c-warn.cc (c_do_switch_warnings): Don't warn about unhandled
411 enumerator when it was marked with attribute unused.
412
4132022-05-18 Eric Botcazou <ebotcazou@adacore.com>
414
415 * c-ada-spec.cc (dump_ada_node) <COMPLEX_TYPE>: Deal with usual
416 floating-point complex types.
417 <POINTER_TYPE>: Do not use limited_with clause if the designated
418 type is a scalar type.
419
3d9439b1
GA
4202022-05-17 Jakub Jelinek <jakub@redhat.com>
421
422 * c-omp.cc (c_finish_omp_depobj): Handle
423 OMP_CLAUSE_DEPEND_INOUTSET.
424
702bd11f
GA
4252022-05-16 Jason Merrill <jason@redhat.com>
426
427 PR c/105492
428 * c-attribs.cc (handle_mode_attribute): Don't fix broken typedefs
429 here.
430
4312022-05-16 Martin Liska <mliska@suse.cz>
432
433 * c-common.cc (ARRAY_SIZE): Use ARRAY_SIZE.
434 (c_common_nodes_and_builtins): Likewise.
435 * c-format.cc (check_tokens): Likewise.
436 (check_plain): Likewise.
437 * c-pragma.cc (c_pp_lookup_pragma): Likewise.
438 (init_pragma): Likewise.
439 * known-headers.cc (get_string_macro_hint): Likewise.
440 (get_stdlib_header_for_name): Likewise.
441 * c-attribs.cc: Likewise.
442
9df4ffe4
GA
4432022-05-13 Richard Biener <rguenther@suse.de>
444
445 * c-omp.cc: Remove gimple-fold.h include.
446
49ace834
GA
4472022-05-12 Jakub Jelinek <jakub@redhat.com>
448
449 * c-common.h (enum rid): Add RID_OMP_ALL_MEMORY.
450 * c-omp.cc (c_finish_omp_depobj): Don't build_fold_addr_expr
451 if null_pointer_node.
452
d0d513b5
GA
4532022-05-11 Martin Liska <mliska@suse.cz>
454
455 PR target/105355
456 * c-opts.cc (c_common_handle_option): Change option name.
457 * c.opt: Remove Joined and use Separate option.
458
bd022ff9
GA
4592022-05-09 Alex Coplan <alex.coplan@arm.com>
460
461 * c-common.h (get_dump_info): Delete.
462 * c-gimplify.cc (c_genericize): Get TDI_original dump file info
463 from the global dump_manager instead of the (now obsolete)
464 get_dump_info.
465 * c-opts.cc (original_dump_file): Delete.
466 (original_dump_flags): Delete.
467 (c_common_parse_file): Switch to using global dump_manager to
468 manage the original dump file; fix leak of dump file.
469 (get_dump_info): Delete.
470
a1947c92
GA
4712022-05-07 Marek Polacek <polacek@redhat.com>
472
473 PR c++/101833
474 PR c++/47634
475 * c-attribs.cc (positional_argument): Pass POS by reference. Deal
476 with FN being either a function declaration or function type. Use
477 maybe_adjust_arg_pos_for_attribute.
478 * c-common.cc (check_function_arguments): Maybe pass FNDECL down to
479 check_function_format.
480 * c-common.h (maybe_adjust_arg_pos_for_attribute): Declare.
481 (positional_argument): Adjust.
482 * c-format.cc (get_constant): Rename to ...
483 (validate_constant): ... this. Take EXPR by reference. Return bool
484 instead of tree.
485 (handle_format_arg_attribute): Don't overwrite FORMAT_NUM_EXPR by the
486 return value of validate_constant.
487 (decode_format_attr): Don't overwrite FORMAT_NUM_EXPR and
488 FIRST_ARG_NUM_EXPR by the return value of validate_constant.
489 (check_function_format): Adjust a parameter name.
490 (handle_format_attribute): Maybe pass FNDECL down to decode_format_attr.
491
3e7db517
GA
4922022-05-04 Marek Polacek <polacek@redhat.com>
493
494 * c-warn.cc (warnings_for_convert_and_check): Convert constants of type
495 char to int.
496
95874f95
GA
4972022-04-30 Jason Merrill <jason@redhat.com>
498
499 PR c/100545
500 * c-attribs.cc (handle_mode_attribute): Copy attributes, aligned,
501 and typedef.
502 * c-common.cc (set_underlying_type): Add assert.
503
01ad093b
GA
5042022-04-26 Patrick Palka <ppalka@redhat.com>
505
506 PR c++/105304
507 * c-common.cc (verify_tree) [restart]: Move up to before the
508 NULL test.
509
da066c42
GA
5102022-04-11 Jakub Jelinek <jakub@redhat.com>
511
512 PR c++/105186
513 * c-common.cc (c_common_nodes_and_builtins): After registering __int%d
514 and __int%d__ builtin types, initialize corresponding ridpointers
515 entry.
516
150ab50f
GA
5172022-03-30 Marek Polacek <polacek@redhat.com>
518
519 PR c++/101030
520 * c-warn.cc (conversion_warning) <case COND_EXPR>: Don't call
521 conversion_warning when OP1 is null.
522
5232022-03-30 Thomas Schwinge <thomas@codesourcery.com>
524
525 * c.opt (Wc++11-extensions, Wc++14-extensions, Wc++17-extensions)
526 (Wc++20-extensions, Wc++23-extensions): Remove 'LangEnabledBy'
527 option properties.
528
5292022-03-30 Thomas Schwinge <thomas@codesourcery.com>
530
531 * c.opt (Wuse-after-free): Remove.
532
5332022-03-30 Thomas Schwinge <thomas@codesourcery.com>
534
535 * c.opt (Warray-bounds): Remove.
536
d2906412
GA
5372022-03-26 Thomas Schwinge <thomas@codesourcery.com>
538
539 * c.opt: Properly quote comment.
540
31e989a2
GA
5412022-03-25 Eric Botcazou <ebotcazou@adacore.com>
542
543 * c-ada-spec.cc (dump_ada_import): Deal with the "section" attribute
544 (dump_ada_node) <POINTER_TYPE>: Do not modify and pass the name, but
545 the referenced type instead. Deal with the anonymous original type
546 of a typedef'ed type. In the actual access case, follow the chain
547 of external subtypes.
548 <TYPE_DECL>: Tidy up control flow.
549
d156bb87
GA
5502022-03-21 Qian Jianhua <qianjh@cn.fujitsu.com>
551
552 * c-ada-spec.cc: Change array length
553
d7f00da1
GA
5542022-03-19 Arthur Cohen <arthur.cohen@embecosm.com>
555
556 * c-common.cc (c_family_tests): Call the new tests.
557 * c-common.h (c_diagnostic_tests): Declare.
558 (c_opt_problem_cc_tests): Likewise.
559
5602022-03-19 Jakub Jelinek <jakub@redhat.com>
561
562 PR c++/101515
563 * c-pretty-print.cc (c_fold_indirect_ref_for_warn): For C++ don't
564 return COMPONENT_REFs with FIELD_DECLs whose containing scope can't
565 be printed.
566
9fc8f278
GA
5672022-03-16 Christophe Lyon <christophe.lyon@arm.com>
568 Roger Sayle <roger@nextmovesoftware.com>
569
570 PR c/98198
571 * c-attribs.cc (decl_or_type_attrs): Add error_mark_node check.
572
5732022-03-16 Patrick Palka <ppalka@redhat.com>
574
575 PR c++/96780
576 * c.opt: Add -ffold-simple-inlines.
577
b9756c08
GA
5782022-03-13 Tobias Burnus <tobias@codesourcery.com>
579
580 * c-target.def (check_string_object_format_arg): Fix description typo.
581
57eeedda
GA
5822022-03-12 Thomas Schwinge <thomas@codesourcery.com>
583
584 PR other/65095
585 * c-common.h (c_omp_map_clause_name): Remove.
586 * c-omp.cc (c_omp_map_clause_name): Remove.
587
8cc4f9cd
GA
5882022-03-09 Jakub Jelinek <jakub@redhat.com>
589
590 PR c/104711
591 * c-opts.cc (c_common_post_options): Don't enable
592 -Wshift-negative-value from -Wextra for C++20 or later.
593 * c-ubsan.cc (ubsan_instrument_shift): Adjust comments.
594 * c-warn.cc (maybe_warn_shift_overflow): Use TYPE_OVERFLOW_WRAPS
595 instead of TYPE_UNSIGNED.
596
e6533e2e
GA
5972022-03-07 Jakub Jelinek <jakub@redhat.com>
598
599 * c-attribs.cc: Fix up duplicated word issue in a comment.
600
12d4552e
GA
6012022-03-01 Martin Liska <mliska@suse.cz>
602
603 PR ipa/104533
604 * c-attribs.cc (handle_target_clones_attribute): Use
605 get_target_clone_attr_len and report warning soon.
606
0bdb0498
GA
6072022-02-17 Jonathan Wakely <jwakely@redhat.com>
608
609 * c-pragma.cc (handle_pragma_pack): Remove parameter name.
610 (handle_pragma_weak): Likewise.
611 (handle_pragma_scalar_storage_order): Likewise.
612 (handle_pragma_redefine_extname): Likewise.
613 (handle_pragma_visibility): Likewise.
614 (handle_pragma_diagnostic): Likewise.
615 (handle_pragma_target): Likewise.
616 (handle_pragma_optimize): Likewise.
617 (handle_pragma_push_options): Likewise.
618 (handle_pragma_pop_options): Likewise.
619 (handle_pragma_reset_options): Likewise.
620 (handle_pragma_message): Likewise.
621 (handle_pragma_float_const_decimal64): Likewise.
622
cb3afcd2
GA
6232022-02-16 Jakub Jelinek <jakub@redhat.com>
624
625 PR c/104531
626 * c-omp.cc (c_finish_omp_atomic): For MIN_EXPR/MAX_EXPR, try first
627 build_binary_op with LT_EXPR and only if that doesn't return
628 error_mark_node call build_modify_expr.
629
6302022-02-16 Jakub Jelinek <jakub@redhat.com>
631
632 PR c/104510
633 * c-common.cc (shorten_compare): Convert original arguments to
634 the original *restype_ptr when mixing binary and decimal float.
635
1f8a09d2
GA
6362022-02-14 Richard Biener <rguenther@suse.de>
637
638 PR c/104505
639 * c-pretty-print.cc (c_pretty_printer::postfix_expression): Handle
640 internal function calls.
641
e8d68f0a
GA
6422022-02-11 Richard Biener <rguenther@suse.de>
643
644 * c-attribs.cc (c_common_attribute_table): Add entry for
645 vector_mask.
646 (handle_vector_mask_attribute): New.
647
a645583d
GA
6482022-02-10 Marcel Vollweiler <marcel@codesourcery.com>
649
650 * c-omp.cc (c_omp_split_clauses): Added OMP_CLAUSE_HAS_DEVICE_ADDR case.
651 * c-pragma.h (enum pragma_kind): Added 5.1 in comment.
652 (enum pragma_omp_clause): Added PRAGMA_OMP_CLAUSE_HAS_DEVICE_ADDR.
653
3adf509f
GA
6542022-02-09 Jason Merrill <jason@redhat.com>
655
656 * c-cppbuiltin.cc (c_cpp_builtins): Update values
657 of __cpp_constexpr and __cpp_concepts for C++20.
658
bb99171b
GA
6592022-01-24 Marek Polacek <polacek@redhat.com>
660
661 PR preprocessor/104030
662 * c.opt (Wbidi-chars): Mark as EnumSet. Also accept =ucn.
663
9dd44357
GA
6642022-01-21 Jakub Jelinek <jakub@redhat.com>
665
666 PR c++/104148
667 * c-common.h (check_function_arguments_recurse): Add for_format
668 arg.
669 * c-common.cc (check_function_nonnull): Pass false to
670 check_function_arguments_recurse's last argument.
671 (check_function_arguments_recurse): Add for_format argument,
672 if true, don't stop on warning_suppressed_p.
673 * c-format.cc (check_format_info): Pass true to
674 check_function_arguments_recurse's last argument.
675
fe1ad141
GA
6762022-01-19 David Malcolm <dmalcolm@redhat.com>
677
678 * c-common.cc (c_common_c_tests): Rename to...
679 (c_common_cc_tests): ...this.
680 (c_family_tests): Update calls for .c to .cc renaming.
681 * c-common.h (c_format_c_tests): Rename to...
682 (c_format_cc_tests): ...this.
683 (c_indentation_c_tests): Rename to...
684 (c_indentation_cc_tests): ...this.
685 (c_pretty_print_c_tests): Rename to...
686 (c_pretty_print_cc_tests): ...this.
687 * c-format.cc (c_format_c_tests): Rename to...
688 (c_format_cc_tests): ...this.
689 * c-indentation.cc (c_indentation_c_tests): Rename to...
690 (c_indentation_cc_tests): ...this.
691 * c-pretty-print.cc (c_pretty_print_c_tests): Rename to...
692 (c_pretty_print_cc_tests): ...this.
693
fc829782
GA
6942022-01-17 Martin Liska <mliska@suse.cz>
695
696 * c-ada-spec.cc: Rename .c names to .cc.
697 * c-ada-spec.h: Likewise.
698 * c-common.cc (c_build_vec_convert): Likewise.
699 (warning_candidate_p): Likewise.
700 * c-common.h (enum rid): Likewise.
701 (build_real_imag_expr): Likewise.
702 (finish_label_address_expr): Likewise.
703 (c_get_substring_location): Likewise.
704 (c_build_bind_expr): Likewise.
705 (conflict_marker_get_final_tok_kind): Likewise.
706 (c_parse_error): Likewise.
707 (check_missing_format_attribute): Likewise.
708 (invalid_array_size_error): Likewise.
709 (warn_for_multistatement_macros): Likewise.
710 (build_attr_access_from_parms): Likewise.
711 * c-cppbuiltin.cc (c_cpp_builtins): Likewise.
712 * c-format.cc: Likewise.
713 * c-gimplify.cc (c_gimplify_expr): Likewise.
714 * c-indentation.h: Likewise.
715 * c-objc.h (objc_prop_attr_kind_for_rid): Likewise.
716 * c-omp.cc (c_omp_predetermined_mapping): Likewise.
717 * c-opts.cc (c_common_post_options): Likewise.
718 (set_std_cxx23): Likewise.
719 * c-pragma.cc (handle_pragma_redefine_extname): Likewise.
720 * c-pretty-print.h: Likewise.
721
7222022-01-17 Martin Liska <mliska@suse.cz>
723
724 * c-ada-spec.c: Moved to...
725 * c-ada-spec.cc: ...here.
726 * c-attribs.c: Moved to...
727 * c-attribs.cc: ...here.
728 * c-common.c: Moved to...
729 * c-common.cc: ...here.
730 * c-cppbuiltin.c: Moved to...
731 * c-cppbuiltin.cc: ...here.
732 * c-dump.c: Moved to...
733 * c-dump.cc: ...here.
734 * c-format.c: Moved to...
735 * c-format.cc: ...here.
736 * c-gimplify.c: Moved to...
737 * c-gimplify.cc: ...here.
738 * c-indentation.c: Moved to...
739 * c-indentation.cc: ...here.
740 * c-lex.c: Moved to...
741 * c-lex.cc: ...here.
742 * c-omp.c: Moved to...
743 * c-omp.cc: ...here.
744 * c-opts.c: Moved to...
745 * c-opts.cc: ...here.
746 * c-pch.c: Moved to...
747 * c-pch.cc: ...here.
748 * c-ppoutput.c: Moved to...
749 * c-ppoutput.cc: ...here.
750 * c-pragma.c: Moved to...
751 * c-pragma.cc: ...here.
752 * c-pretty-print.c: Moved to...
753 * c-pretty-print.cc: ...here.
754 * c-semantics.c: Moved to...
755 * c-semantics.cc: ...here.
756 * c-ubsan.c: Moved to...
757 * c-ubsan.cc: ...here.
758 * c-warn.c: Moved to...
759 * c-warn.cc: ...here.
760 * cppspec.c: Moved to...
761 * cppspec.cc: ...here.
762 * stub-objc.c: Moved to...
763 * stub-objc.cc: ...here.
764
9248ee41
GA
7652022-01-15 Martin Sebor <msebor@redhat.com>
766
767 PR c/63272
768 * c.opt (-Wdangling-pointer): New option.
769
7702022-01-15 Martin Sebor <msebor@redhat.com>
771
772 PR tree-optimization/80532
773 * c.opt (-Wuse-after-free): New options.
774
617db51d
GA
7752022-01-14 David Malcolm <dmalcolm@redhat.com>
776
777 * c-attribs.c (c_common_attribute_table): Add "tainted_args".
778 (handle_tainted_args_attribute): New.
779
ad3f0d08
GA
7802022-01-13 Anthony Sharp <anthonysharp15@gmail.com>
781 Jason Merrill <jason@redhat.com>
782
783 PR c++/70417
784 * c.opt: Added -Wmissing-template-keyword.
785
7862022-01-13 Richard Biener <rguenther@suse.de>
787
788 PR c/104002
789 * c-common.c (c_common_mark_addressable_vec): Handle TARGET_EXPR.
790
02a8a01b
GA
7912022-01-12 Martin Liska <mliska@suse.cz>
792
793 PR target/103804
794 * c-attribs.c (handle_optimize_attribute): Do not call
795 cl_optimization_compare if we seen an error.
796
01a254e3
GA
7972022-01-11 Jakub Jelinek <jakub@redhat.com>
798
799 PR c/101537
800 PR c/103881
801 * c-warn.c (conversion_warning): Handle BIT_AND_EXPR, BIT_IOR_EXPR
802 and BIT_XOR_EXPR.
803
d9450aa0
GA
8042022-01-10 Richard Biener <rguenther@suse.de>
805
806 PR middle-end/101530
807 * c-common.c (c_build_shufflevector): Wrap the BIT_FIELD_REF
808 in a TARGET_EXPR to force a temporary.
809
11ce8d04
GA
8102022-01-06 Marek Polacek <polacek@redhat.com>
811
812 PR c++/103758
813 * c-pragma.c (handle_pragma_scalar_storage_order): Use %< %> in
814 diagnostic messages.
815 (handle_pragma_diagnostic): Likewise.
816
a4ae8c37
GA
8172022-01-03 Marek Polacek <polacek@redhat.com>
818
819 PR c++/103758
820 * c-format.c (check_tokens): Accept "decl-specifier*".
821
8222022-01-03 Jakub Jelinek <jakub@redhat.com>
823
824 PR c++/103600
825 * c-attribs.c (handle_non_overlapping_attribute): New function.
826 (c_common_attribute_table): Add "non overlapping" attribute.
827
84790a9d
GA
8282021-12-30 Jakub Jelinek <jakub@redhat.com>
829
830 PR c++/103012
831 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Perform
832 cpp_define_unused/cpp_undef calls with forced token locations
833 BUILTINS_LOCATION.
834
d1e111da
GA
8352021-12-27 Patrick Palka <ppalka@redhat.com>
836
837 PR c++/103700
838 * c-common.c (pointer_int_sum): When quiet, return
839 error_mark_node for an incomplete pointed-to type and don't
840 call size_in_bytes_loc.
841
2554e2da
GA
8422021-12-17 Jason Merrill <jason@redhat.com>
843
844 PR c++/103681
845 * c-opts.c (c_common_post_options): Update defaults.
846
774269aa
GA
8472021-12-16 Martin Liska <mliska@suse.cz>
848
849 PR target/103709
850 * c-pragma.c (handle_pragma_pop_options): Do not check
851 global options modification when an error is seen in parsing
852 of options (pragmas or attributes).
853
c8dcf64b
GA
8542021-12-12 Jonathan Wakely <jwakely@redhat.com>
855
856 * known-headers.cc: Define INCLUDE_MEMORY instead of
857 INCLUDE_UNIQUE_PTR.
858 * name-hint.h: Likewise.
859 (class name_hint): Use std::unique_ptr instead of gnu::unique_ptr.
860
4b4839e3
GA
8612021-12-09 Jakub Jelinek <jakub@redhat.com>
862
863 PR pch/71934
864 * c-pch.c (c_common_no_more_pch): Pass a temporary void * var
865 with NULL value instead of NULL to host_hooks.gt_pch_use_address.
866
03a9bd05
GA
8672021-12-03 Jakub Jelinek <jakub@redhat.com>
868
869 PR pch/71934
870 * c-pch.c (struct c_pch_validity): Remove pch_init member.
871 (pch_init): Don't initialize v.pch_init.
872 (c_common_valid_pch): Don't warn and punt if .text addresses change.
873
40fa651e
GA
8742021-12-01 Jason Merrill <jason@redhat.com>
875
876 PR c++/103310
877 * c.opt: Add -fconstexpr-fp-except.
878
87cd82c8
GA
8792021-11-29 Richard Biener <rguenther@suse.de>
880
881 * c-format.c (check_format_string): Remove spurious
882 gcc_unreachable.
883
8842021-11-29 Richard Biener <rguenther@suse.de>
885
886 * c-opts.c (c_common_post_options): Remove unreachable return.
887 * c-pragma.c (handle_pragma_target): Likewise.
888 (handle_pragma_optimize): Likewise.
889
091ccc06
GA
8902021-11-25 Jakub Jelinek <jakub@redhat.com>
891
892 PR c++/102611
893 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
894 default for C++23 regardless of warn_deprecated.
895 * c-cppbuiltin.c (c_cpp_builtins): Predefine
896 __cpp_multidimensional_subscript=202110L for C++23.
897
e1d43592
GA
8982021-11-23 Martin Sebor <msebor@redhat.com>
899
900 PR middle-end/88232
901 * c.opt: Add -Winfinite-recursion.
902
9c077398
GA
9032021-11-19 Martin Sebor <msebor@redhat.com>
904
905 PR c++/33925
906 PR c/102867
907 * c-common.c (decl_with_nonnull_addr_p): Call maybe_nonzero_address
908 and improve handling tof defined symbols.
909
9102021-11-19 Martin Liska <mliska@suse.cz>
911
912 Revert:
913 2021-11-18 Martin Liska <mliska@suse.cz>
914
915 * c-gimplify.c (genericize_c_loop): Use option directly.
916
483092d3
GA
9172021-11-18 Matthias Kretz <m.kretz@gsi.de>
918
919 * c-common.c (c_common_reswords): Add __builtin_assoc_barrier.
920 * c-common.h (enum rid): Add RID_BUILTIN_ASSOC_BARRIER.
921
9222021-11-18 Martin Liska <mliska@suse.cz>
923
924 * c-gimplify.c (genericize_c_loop): Use option directly.
925
280d2838
GA
9262021-11-17 Martin Uecker <uecker@gcc.gnu.org>
927
928 PR c/91038
929 PR c/29970
930 * c-common.c (pointer_int_sum): Make sure pointer expressions
931 are evaluated first when the size expression depends on for
932 variably-modified types.
933
9342021-11-17 Marek Polacek <polacek@redhat.com>
935
936 PR preprocessor/103026
937 * c.opt (Wbidi-chars, Wbidi-chars=): New option.
938
6b1695f4
GA
9392021-11-16 Jason Merrill <jason@redhat.com>
940
941 * c-common.c (release_tree_vector): Only cache vecs smaller than
942 16 elements.
943
e2b57363
GA
9442021-11-15 Jason Merrill <jason@redhat.com>
945
946 * c.opt: Add -fimplicit-constexpr.
947 * c-cppbuiltin.c: Define __cpp_implicit_constexpr.
948 * c-opts.c (c_common_post_options): Disable below C++14.
949
9502021-11-15 Jakub Jelinek <jakub@redhat.com>
951
952 * c-omp.c (c_omp_split_clauses) <case OMP_CLAUSE_THREAD_LIMIT>:
953 Duplicate to both OMP_TARGET and OMP_TEAMS.
954
8d36a0d2
GA
9552021-11-10 Marek Polacek <polacek@redhat.com>
956
957 PR c++/101940
958 * c-pragma.c (handle_pragma_diagnostic): Handle #pragma GCC diagnostic
959 ignored_attributes.
960
c9b1334e
GA
9612021-11-09 David Malcolm <dmalcolm@redhat.com>
962
963 * c-pragma.c (GCC_BAD_AT): New macro.
964 (GCC_BAD2_AT): New macro.
965 (handle_pragma_pack): Use the location of the pertinent token when
966 issuing diagnostics about invalid constants/actions, and trailing
967 junk.
968 (handle_pragma_target): Likewise for non-string "GCC option".
969 (handle_pragma_message): Likewise for trailing junk.
970
18ae471f
GA
9712021-11-03 Joseph Myers <joseph@codesourcery.com>
972
973 PR c/103031
974 * c-common.c (convert_and_check): Add argument init_const. Call
975 convert_init if init_const.
976 * c-common.h (convert_and_check): Update prototype.
977 (convert_init): New prototype.
978
cf82e8d9
GA
9792021-11-01 David Malcolm <dmalcolm@redhat.com>
980
981 * c-lex.c (c_lex_with_flags): When complaining about non-printable
982 CPP_OTHER tokens, set the "escape on output" flag.
983
04a2cf3f
GA
9842021-10-27 Jakub Jelinek <jakub@redhat.com>
985
986 * c-omp.c (c_omp_check_loop_iv_r): Don't clear 3rd bit for
987 POINTER_PLUS_EXPR.
988 (c_omp_check_nonrect_loop_iv): Handle POINTER_PLUS_EXPR.
989 (c_omp_check_loop_iv): Set kind even if the iterator is non-integral.
990
9912021-10-27 Jakub Jelinek <jakub@redhat.com>
992
993 PR c++/102854
994 * c-common.h (c_omp_check_loop_iv_exprs): Add enum tree_code argument.
995 * c-omp.c (c_omp_check_loop_iv_r): For trees other than decls,
996 TREE_VEC, PLUS_EXPR, MINUS_EXPR, MULT_EXPR, POINTER_PLUS_EXPR or
997 conversions temporarily clear the 3rd bit from d->kind while walking
998 subtrees.
999 (c_omp_check_loop_iv_exprs): Add CODE argument. Or in 4 into data.kind
1000 if possibly non-rectangular.
1001
ae5c5406
GA
10022021-10-21 Jakub Jelinek <jakub@redhat.com>
1003
1004 PR middle-end/64888
1005 * c-omp.c (c_omp_predefined_variable): Return true also for
1006 ubsan_create_data created artificial variables.
1007
5d5885c9
GA
10082021-10-14 Joseph Myers <joseph@codesourcery.com>
1009
1010 * c-format.c (printf_length_specs, scanf_length_specs)
1011 (print_char_table, scan_char_table): Support DFP formats for C2X.
1012 * c-format.h (TEX_D32, TEX_D64, TEX_D128): Remove.
1013 (T2X_D32, T2X_D64, T2X_D128): New macros.
1014
10152021-10-14 Kwok Cheung Yeung <kcy@codesourcery.com>
1016
1017 * c-omp.c (c_omp_check_context_selector): Rename to
1018 omp_check_context_selector and move to omp-general.c.
1019 (c_omp_mark_declare_variant): Rename to omp_mark_declare_variant and
1020 move to omp-general.c.
1021
52055987
GA
10222021-10-12 Joseph Myers <joseph@codesourcery.com>
1023
1024 * c-format.c (print_char_table): Add %b and %B formats.
1025 (scan_char_table): Add %b format.
1026 * c-format.h (T2X_UI, T2X_UL, T2X_ULL, T2X_US, T2X_UC, T2X_ST)
1027 (T2X_UPD, T2X_UIM): New macros.
1028
10292021-10-12 Jakub Jelinek <jakub@redhat.com>
1030
1031 * c-omp.c (c_finish_omp_atomic): Use
1032 clear_padding_type_may_have_padding_p.
1033
ce6eec39
GA
10342021-10-08 Martin Liska <mliska@suse.cz>
1035
1036 * c-opts.c (c_common_post_options): Use new macro
1037 OPTION_SET_P.
1038
50e20ee6
GA
10392021-10-07 Martin Liska <mliska@suse.cz>
1040
1041 * c-common.c (parse_optimize_options): Make
1042 save_opt_decoded_options a pointer type.
1043
57c7ec62
GA
10442021-10-06 Jakub Jelinek <jakub@redhat.com>
1045
1046 PR tree-optimization/102571
1047 * c-omp.c (c_finish_omp_atomic): Optimize the case where type has
1048 padding, but the non-padding bits are contiguous set of bytes
1049 by adjusting the memcmp call arguments instead of emitting
1050 __builtin_clear_padding and then comparing all the type's bytes.
1051
10522021-10-06 Jakub Jelinek <jakub@redhat.com>
1053
1054 PR c++/102612
1055 * c-cppbuiltin.c (c_cpp_builtins): For -std=c++23 predefine
1056 __cpp_constexpr to 202110L rather than 201907L.
1057
da9c5f78
GA
10582021-10-04 Marek Polacek <polacek@redhat.com>
1059
1060 PR c++/97573
1061 * c-common.h (do_warn_array_compare): Declare.
1062 * c-warn.c (do_warn_array_compare): New.
1063 * c.opt (Warray-compare): New option.
1064
e3e07b89
GA
10652021-10-02 Iain Sandoe <iain@sandoe.co.uk>
1066
1067 * c-format.c: Remove a test of TARGET_FORMAT_TYPES with
1068 NULL, this is not needed.
1069
9d116bcc
GA
10702021-10-01 Martin Sebor <msebor@redhat.com>
1071
1072 PR c/102103
1073 * c-common.c (decl_with_nonnull_addr_p): Handle members.
1074 Check and perform warning suppression.
1075 (c_common_truthvalue_conversion): Enhance warning suppression.
1076
10772021-10-01 Martin Liska <mliska@suse.cz>
1078
1079 PR target/102552
1080 * c-common.c (parse_optimize_options): decoded_options[0] is
1081 used for program name, so merged_decoded_options should also
1082 respect that.
1083
10842021-10-01 Jakub Jelinek <jakub@redhat.com>
1085 Richard Biener <rguenther@suse.de>
1086
1087 PR sanitizer/102515
1088 * c-ubsan.c (ubsan_instrument_division): Check the right
1089 flag_sanitize_recover bit, depending on which sanitization
1090 is done. Sanitize INT_MIN / -1 under SANITIZE_SI_OVERFLOW
1091 rather than SANITIZE_DIVIDE. If both SANITIZE_SI_OVERFLOW
1092 and SANITIZE_DIVIDE is enabled, neither check is known
1093 to be false and flag_sanitize_recover bits for those two
1094 aren't the same, emit both __ubsan_handle_divrem_overflow
1095 and __ubsan_handle_divrem_overflow_abort calls.
1096
10972021-10-01 Martin Liska <mliska@suse.cz>
1098
1099 * c-common.c (parse_optimize_options): Combine optimize
1100 options with what was provided on the command line.
1101
11022021-10-01 Jakub Jelinek <jakub@redhat.com>
1103
1104 * c-omp.c (c_omp_split_clauses): Also copy
1105 OMP_CLAUSE_ORDER_REPRODUCIBLE.
1106
cf966403
GA
11072021-09-27 Martin Liska <mliska@suse.cz>
1108
1109 * c-opts.c (c_common_init_options_struct): Set also
1110 x_flag_default_complex_method.
1111
e4777439
GA
11122021-09-22 Jakub Jelinek <jakub@redhat.com>
1113
1114 * c-omp.c (c_omp_split_clauses): Copy over OMP_CLAUSE_ALLOCATE_ALIGN.
1115
62498024
GA
11162021-09-20 Matthias Kretz <m.kretz@gsi.de>
1117
1118 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define or
1119 undefine __RECIPROCAL_MATH__, __NO_SIGNED_ZEROS__,
1120 __NO_TRAPPING_MATH__, __ASSOCIATIVE_MATH__, and
1121 __ROUNDING_MATH__ according to the new optimization flags.
1122
cf74e7b5
GA
11232021-09-18 Jakub Jelinek <jakub@redhat.com>
1124
1125 * c-omp.c (c_omp_split_clauses): Split order clause also to
1126 distribute construct. Copy over OMP_CLAUSE_ORDER_UNCONSTRAINED.
1127
0a4cb439
GA
11282021-09-17 Jakub Jelinek <jakub@redhat.com>
1129
1130 * c-omp.c (c_finish_omp_atomic): Avoid creating
1131 TARGET_EXPR if test is true, use create_tmp_var_raw instead of
1132 create_tmp_var and add a zero initializer to TARGET_EXPRs that
1133 had NULL initializer. When omitting operands after v = x,
1134 use type of v rather than type of x. Fix type of vtmp
1135 TARGET_EXPR.
1136
07985c47
GA
11372021-09-13 Jason Merrill <jason@redhat.com>
1138
1139 * c.opt: Add -Winterference-size.
1140 * c-cppbuiltin.c (cpp_atomic_builtins): Add __GCC_DESTRUCTIVE_SIZE
1141 and __GCC_CONSTRUCTIVE_SIZE.
1142
a26206ec
GA
11432021-09-10 Jakub Jelinek <jakub@redhat.com>
1144
1145 * c-common.h (c_finish_omp_atomic): Add r and weak arguments.
1146 * c-omp.c: Include gimple-fold.h.
1147 (c_finish_omp_atomic): Add r and weak arguments. Add support for
1148 OpenMP 5.1 atomics.
1149
f84e2f0b
GA
11502021-09-09 qing zhao <qing.zhao@oracle.com>
1151
1152 * c-attribs.c (handle_uninitialized_attribute): New function.
1153 (c_common_attribute_table): Add "uninitialized" attribute.
1154
b6db7cd4
GA
11552021-09-08 liuhongt <hongtao.liu@intel.com>
1156
1157 * c-common.c (excess_precision_mode_join): Update below comments.
1158 (c_ts18661_flt_eval_method): Set excess_precision_type to
1159 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
1160 * c-cppbuiltin.c (cpp_atomic_builtins): Update below comments.
1161 (c_cpp_flt_eval_method_iec_559): Set excess_precision_type to
1162 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
1163
b2748138
GA
11642021-09-07 Marcel Vollweiler <marcel@codesourcery.com>
1165
1166 * c-omp.c (c_finish_omp_flush): Handle MEMMODEL_SEQ_CST.
1167
7b739540
GA
11682021-09-03 Eric Botcazou <ebotcazou@adacore.com>
1169
1170 * c-ada-spec.c (dump_ads): Generate pragmas to disable style checks
1171 and -gnatwu warning for the package specification.
1172
e11c6046
GA
11732021-09-01 Iain Sandoe <iain@sandoe.co.uk>
1174
1175 * c-attribs.c (handle_unavailable_attribute): New.
1176
1e2f030b
GA
11772021-08-30 Jason Merrill <jason@redhat.com>
1178
1179 * c.opt: Add -Wmissing-requires.
1180
85d77ac4
GA
11812021-08-25 Lewis Hyatt <lhyatt@gmail.com>
1182
1183 PR other/93067
1184 * c-opts.c (c_common_input_charset_cb): New function.
1185 (c_common_post_options): Call new function
1186 diagnostic_initialize_input_context().
1187
7c9e1645
GA
11882021-08-20 Tobias Burnus <tobias@codesourcery.com>
1189
1190 * c-format.c (gcc_gfc_length_specs): Add 'll' and 'w'.
1191 (gcc_gfc_char_table): Add T9L_LL and T9L_ULL to
1192 "di" and "u", respecitively; fill with BADLEN to match
1193 size of 'types'.
1194 (get_init_dynamic_hwi): Split off from ...
1195 (init_dynamic_diag_info): ... here. Call it.
1196 (init_dynamic_gfc_info): Call it.
1197
11982021-08-20 Jakub Jelinek <jakub@redhat.com>
1199
1200 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ERROR.
1201 * c-pragma.c (omp_pragmas): Add error directive.
1202 * c-omp.c (omp_directives): Uncomment error directive entry.
1203
6e529985
GA
12042021-08-18 Jakub Jelinek <jakub@redhat.com>
1205
1206 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_NOTHING.
1207 * c-pragma.c (omp_pragmas): Add nothing directive.
1208 * c-omp.c (omp_directives): Uncomment nothing directive entry.
1209
2d14d64b
GA
12102021-08-17 Jakub Jelinek <jakub@redhat.com>
1211
1212 PR c++/101539
1213 * c-common.h (enum rid): Add RID_IS_LAYOUT_COMPATIBLE.
1214 * c-common.c (c_common_reswords): Add __is_layout_compatible.
1215
12162021-08-17 Matt Jacobson <mhjacobson@me.com>
1217
1218 * c-opts.c (c_common_post_options): Default to
1219 flag_objc_sjlj_exceptions = 1 only when flag_objc_abi < 2.
1220
12212021-08-17 Jakub Jelinek <jakub@redhat.com>
1222
1223 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCOPE.
1224 * c-pragma.c (omp_pragmas): Add scope construct.
1225 * c-omp.c (omp_directives): Uncomment scope directive entry.
1226
9d1d9fc8
GA
12272021-08-16 Sebastian Huber <sebastian.huber@embedded-brains.de>
1228
1229 * c-cppbuiltin.c (c_cpp_builtins): Define
1230 __LIBGCC_GCOV_TYPE_SIZE if flag_building_libgcc is true.
1231
72be20e2
GA
12322021-08-12 Jakub Jelinek <jakub@redhat.com>
1233
1234 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_MASKED.
1235 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FILTER.
1236 * c-pragma.c (omp_pragmas_simd): Add masked construct.
1237 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_MASKED
1238 enumerator.
1239 (c_finish_omp_masked): Declare.
1240 * c-omp.c (c_finish_omp_masked): New function.
1241 (c_omp_split_clauses): Handle combined masked constructs.
1242
4d17ca1b
GA
12432021-07-30 Jakub Jelinek <jakub@redhat.com>
1244
1245 PR c++/101539
1246 * c-common.h (enum rid): Add RID_IS_POINTER_INTERCONVERTIBLE_BASE_OF.
1247 * c-common.c (c_common_reswords): Add
1248 __is_pointer_interconvertible_base_of.
1249
12502021-07-29 Richard Biener <rguenther@suse.de>
1251
1252 PR c/101512
1253 * c-common.c (c_common_mark_addressable_vec): Look through
1254 C_MAYBE_CONST_EXPR even if not at the toplevel.
1255
af3f12e6
GA
12562021-07-27 Martin Sebor <msebor@redhat.com>
1257
1258 PR c/101585
1259 * c-warn.c (warn_parm_ptrarray_mismatch): Use OEP_DECL_NAME.
1260
ead235f6
GA
12612021-07-23 Jakub Jelinek <jakub@redhat.com>
1262
1263 * c-lex.c (c_common_has_attribute): Call canonicalize_attr_name also
1264 on attr_id. Return 1 for omp::directive or omp::sequence in C++11
1265 and later.
1266
12672021-07-23 Jakub Jelinek <jakub@redhat.com>
1268
1269 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP__START_ and
1270 PRAGMA_OMP__LAST_ enumerators.
1271
419c6c68
GA
12722021-07-21 Thomas Schwinge <thomas@codesourcery.com>
1273 Joseph Myers <joseph@codesourcery.com>
1274 Cesar Philippidis <cesar@codesourcery.com>
1275
1276 * c-pragma.h (pragma_omp_clause): Add 'PRAGMA_OACC_CLAUSE_NOHOST'.
1277
92d45509
GA
12782021-07-20 Martin Sebor <msebor@redhat.com>
1279
1280 * c-common.c (c_build_shufflevector): Adjust by-value argument to
1281 by-const-reference.
1282 * c-common.h (c_build_shufflevector): Same.
1283
87277b6a
GA
12842021-07-16 Andrew Pinski <apinski@marvell.com>
1285
1286 PR c/101453
1287 * c-common.c (parse_optimize_options): Use the correct
1288 size for buffer.
1289
d97d71a1
GA
12902021-07-15 Martin Sebor <msebor@redhat.com>
1291
1292 PR c/101289
1293 PR c/97548
1294 * c-warn.c (warn_parm_array_mismatch): Use OEP_DECL_NAME.
1295
c4fee1c6
GA
12962021-07-14 Jason Merrill <jason@redhat.com>
1297
1298 * c-opts.c (c_common_post_options): Set -fdelete-dead-exceptions.
1299
6fba0eea
GA
13002021-07-06 Martin Sebor <msebor@redhat.com>
1301
1302 * c-format.c (gcc_tdiag_char_table): Remove support for %G and %K.
1303 (gcc_cdiag_char_table): Same.
1304 (gcc_cxxdiag_char_table): Same.
1305
7a60a6e8
GA
13062021-07-02 Jakub Jelinek <jakub@redhat.com>
1307
1308 * c-common.h (enum c_omp_directive_kind): New enum.
1309 (struct c_omp_directive): New type.
1310 (c_omp_categorize_directive): Declare.
1311 * c-omp.c (omp_directives): New variable.
1312 (c_omp_categorize_directive): New function.
1313
bea7c16a
GA
13142021-07-01 Eric Botcazou <ebotcazou@adacore.com>
1315
1316 * c-ada-spec.c (packed_layout): New global variable.
1317 (dump_ada_declaration): Set it upon seeing a packed record type.
1318 Do not put the "aliased" keyword if it is set.
1319 (dump_ada_structure): Add Pack aspect if it is set and clear it.
1320
13212021-07-01 Eric Botcazou <ebotcazou@adacore.com>
1322
1323 * c-ada-spec.c (check_name): Rename into...
1324 (check_type_name_conflict): ...this. Minor tweak.
1325 (dump_ada_function_declaration): Adjust to above renaming.
1326 (dump_ada_array_domains): Fix oversight.
1327 (dump_ada_declaration): Call check_type_name_conflict for variables.
1328
90708f87
GA
13292021-06-25 Martin Sebor <msebor@redhat.com>
1330
1331 * c-common.c (c_wrap_maybe_const): Remove TREE_NO_WARNING.
1332 (c_common_truthvalue_conversion): Replace direct uses of
1333 TREE_NO_WARNING with warning_suppressed_p, suppress_warning, and
1334 copy_no_warning.
1335 (check_function_arguments_recurse): Same.
1336 * c-gimplify.c (c_gimplify_expr): Same.
1337 * c-warn.c (overflow_warning): Same.
1338 (warn_logical_operator): Same.
1339 (warn_if_unused_value): Same.
1340 (do_warn_unused_parameter): Same.
1341
9aa8327e
GA
13422021-06-24 Jakub Jelinek <jakub@redhat.com>
1343
1344 * c-common.h (enum c_omp_region_type): Add C_ORT_TARGET and
1345 C_ORT_OMP_TARGET.
1346 * c-omp.c (c_omp_split_clauses): For OMP_CLAUSE_IN_REDUCTION on
1347 combined target constructs also add map (always, tofrom:) clause.
1348
ede6c356
GA
13492021-06-15 Robin Dapp <rdapp@linux.ibm.com>
1350
1351 * c-attribs.c (common_handle_aligned_attribute): Remove short
1352 circuit and dead code.
1353
8dc48181
GA
13542021-06-14 Jonathan Wakely <jwakely@redhat.com>
1355
1356 PR c++/101052
1357 * known-headers.cc (get_stdlib_header_for_name): Add known
1358 headers for EXIT_FAILURE, EXIT_SUCCESS, abort, atexit, calloc,
1359 exit, and getenv.
1360
8b8c3912
GA
13612021-06-12 Jason Merrill <jason@redhat.com>
1362
1363 * c-attribs.c (handle_unused_attribute): Handle FIELD_DECL.
1364
f16f65f8
GA
13652021-06-11 Jakub Jelinek <jakub@redhat.com>
1366
1367 PR c++/100974
1368 * c-cppbuiltin.c (c_cpp_builtins): Predefine __cpp_if_consteval for
1369 -std=c++2b for P1938R3 consteval if support.
1370
4f625f47
GA
13712021-06-09 Jason Merrill <jason@redhat.com>
1372
1373 PR c++/100879
1374 * c-warn.c (warn_for_sign_compare): Remove C++ enum mismatch
1375 warning.
1376
438aac59
GA
13772021-06-07 Martin Liska <mliska@suse.cz>
1378
1379 * c-target.def: Split long lines and replace them
1380 with '\n\'.
1381
600f90cb
GA
13822021-06-04 Martin Sebor <msebor@redhat.com>
1383
1384 PR c/100783
1385 * c-attribs.c (positional_argument): Bail on erroneous types.
1386
13872021-06-04 Martin Sebor <msebor@redhat.com>
1388
1389 * c-warn.c (warn_parm_array_mismatch): Check TREE_PURPOSE to test
1390 for element presence.
1391
440c8a0a
GA
13922021-06-03 Eric Botcazou <ebotcazou@adacore.com>
1393
1394 * c-ada-spec.c (dump_ada_macros): Minor tweaks.
1395 (dump_ada_decl_name): Likewise.
1396 (dump_anonymous_type_name): Remove parent parameter and adjust.
1397 (dump_sloc): Minor tweak.
1398 (dump_ada_array_type): Remove type parameter and adjust.
1399 (dump_ada_enum_type): Remove parent parameter and adjust.
1400 (dump_ada_node): Adjust calls to above functions.
1401 (dumped_anonymous_types): New global variable.
1402 (dump_nested_types_1): Rename into...
1403 (dump_nested_types): ...this.
1404 (dump_nested_type): Remove parent and dumped_types parameters.
1405 <ARRAY_TYPE>: Replace dumped_types with dumped_anonymous_types.
1406 Adjust calls to dump_anonymous_type_name and dump_ada_array_type.
1407 (dump_ada_specs): Initialize and free dumped_anonymous_types.
1408
14092021-06-03 Eric Botcazou <ebotcazou@adacore.com>
1410
1411 * c-ada-spec.c (pp_ada_tree_identifier): Tidy up.
1412 (dump_ada_node) <POINTER_TYPE>: Deal specially with external subtypes.
1413
14142021-06-03 Eric Botcazou <ebotcazou@adacore.com>
1415
1416 * c-ada-spec.c (dump_ada_enum_type): Dump a prefix for constants.
1417 (htable_t): New typedef.
1418 (overloaded_names): Use it.
1419 (add_name): New function.
1420 (init_overloaded_names): Use add_name to populate the table and add
1421 special cases for sigaction and stat.
1422 (overloaded_name_p): Rename into...
1423 (overloading_index): ...this. Do not initialize overloaded_names table
1424 here. Return the index or zero.
1425 (dump_ada_declaration): Minor tweaks. Do not skip overloaded functions
1426 but add an overloading suffix instead.
1427 (dump_ada_specs): Initialize overloaded_names tables here.
1428
b75978d1
GA
14292021-06-01 Martin Liska <mliska@suse.cz>
1430
1431 PR other/100759
1432 * c-attribs.c (handle_optimize_attribute): Limit sanity check
1433 to a situation where we are not in processing of an optimize
1434 pragma.
1435 * c-pragma.c (handle_pragma_pop_options): Restore target
1436 options.
1437
ee682192
GA
14382021-05-31 Indu Bhagat <indu.bhagat@oracle.com>
1439
1440 PR testsuite/100749
1441 * c-pch.c (c_common_valid_pch): Use xstrdup for debug format set names.
1442
14432021-05-31 Richard Biener <rguenther@suse.de>
1444
1445 PR c++/88601
1446 * c-common.c: Include tree-vector-builder.h and
1447 vec-perm-indices.h.
1448 (c_common_reswords): Add __builtin_shufflevector.
1449 (c_build_shufflevector): New funtion.
1450 * c-common.h (enum rid): Add RID_BUILTIN_SHUFFLEVECTOR.
1451 (c_build_shufflevector): Declare.
1452
48166757
GA
14532021-05-28 Jakub Jelinek <jakub@redhat.com>
1454
1455 PR middle-end/99928
1456 * c-omp.c (c_omp_split_clauses): For reduction clause if combined with
1457 target add a map tofrom clause with OMP_CLAUSE_MAP_IMPLICIT.
1458
14592021-05-28 Tobias Burnus <tobias@codesourcery.com>
1460
1461 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_AFFINITY.
1462
2bc6dace
GA
14632021-05-25 Martin Liska <mliska@suse.cz>
1464
1465 PR tree-optimization/92860
1466 PR target/99592
1467 * c-attribs.c (handle_optimize_attribute): Save target node
1468 before calling parse_optimize_options and save it in case
1469 it changes.
1470 * c-pragma.c (handle_pragma_target): Similarly for pragma.
1471 (handle_pragma_pop_options): Likewise here.
1472
14732021-05-25 Martin Liska <mliska@suse.cz>
1474
1475 * c-attribs.c (handle_no_sanitize_coverage_attribute): New.
1476
14772021-05-25 Jakub Jelinek <jakub@redhat.com>
1478
1479 PR middle-end/99928
1480 * c-omp.c (c_omp_split_clauses): Copy reduction to teams when teams is
1481 combined with simd and not with taskloop or for.
1482
2832d51b
GA
14832021-05-21 Jakub Jelinek <jakub@redhat.com>
1484
1485 PR middle-end/99928
1486 * c-omp.c (c_omp_split_clauses): Set OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT
1487 on firstprivate clause copy going to target construct, and for
1488 target simd set also OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT_TARGET bit.
1489
ea34e2ed
GA
14902021-05-20 Jonathan Wakely <jwakely@redhat.com>
1491
1492 * c.opt (Wc++11-extensions, Wc++14-extensions)
1493 (Wc++17-extensions, Wc++20-extensions, Wc++23-extensions): New
1494 options.
1495
14962021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
1497
1498 * c-lex.c (init_c_lex): Use dwarf_debuginfo_p.
1499
15002021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
1501
1502 * c-opts.c (c_common_post_options): Adjust access to debug_type_names.
1503 * c-pch.c (struct c_pch_validity): Use type uint32_t.
1504 (pch_init): Renamed member.
1505 (c_common_valid_pch): Adjust access to debug_type_names.
1506
65f32e5d
GA
15072021-05-19 Martin Sebor <msebor@redhat.com>
1508
1509 PR c/100619
1510 * c-attribs.c (build_attr_access_from_parms): Handle arbitrarily many
1511 bounds.
1512
a8daf9a1
GA
15132021-05-18 Richard Biener <rguenther@suse.de>
1514
1515 PR c/100547
1516 * c-attribs.c (type_valid_for_vector_size): Reject too large nunits.
1517 Reword existing nunit diagnostic.
1518
a7ffc1ef
GA
15192021-05-17 Joern Rennecke <joern.rennecke@embecosm.com>
1520
1521 * c-common.c (braced_list_to_string): Return CTOR unchanged
1522 if host and target character sizes don't match.
1523
87a7d10c
GA
15242021-05-14 Martin Liska <mliska@suse.cz>
1525
1526 * c.opt: Add Warning keyword for 2 options.
1527
f9af11c7
GA
15282021-05-13 Martin Liska <mliska@suse.cz>
1529
1530 PR middle-end/100504
1531 * c-attribs.c (handle_target_clones_attribute): Expect a string
1532 argument to target_clone argument.
1533
037e3661
GA
15342021-05-11 Joseph Myers <joseph@codesourcery.com>
1535
1536 * c-lex.c (interpret_float): Handle digit separators for C2X.
1537
aa891c56
GA
15382021-05-10 Martin Liska <mliska@suse.cz>
1539
1540 * c-ada-spec.c (print_destructor): Use startswith
1541 function instead of strncmp.
1542 (dump_ada_declaration): Likewise.
1543 * c-common.c (disable_builtin_function): Likewise.
1544 (def_builtin_1): Likewise.
1545 * c-format.c (check_tokens): Likewise.
1546 (check_plain): Likewise.
1547 (convert_format_name_to_system_name): Likewise.
1548
e4ff4ffb
GA
15492021-04-28 Patrick McGehearty <patrick.mcgehearty@oracle.com>
1550
1551 * c-cppbuiltin.c (c_cpp_builtins): Add supporting macros for new
1552 complex divide
1553
c0fa3f2f
GA
15542021-04-26 Thomas Schwinge <thomas@codesourcery.com>
1555 Nathan Sidwell <nathan@codesourcery.com>
1556 Tom de Vries <vries@codesourcery.com>
1557 Julian Brown <julian@codesourcery.com>
1558 Kwok Cheung Yeung <kcy@codesourcery.com>
1559
1560 * c.opt (Wopenacc-parallelism): New.
1561
6e81e015
GA
15622021-04-19 Thomas Schwinge <thomas@codesourcery.com>
1563
1564 * c.opt (fopenacc-kernels=): Remove.
1565
019a9220
GA
15662021-04-08 Jakub Jelinek <jakub@redhat.com>
1567
1568 * c-warn.c (do_warn_double_promotion): Fix comment typo,
1569 occured -> occurred.
1570 (check_alignment_of_packed_member): Fix a comment typo,
1571 memeber -> member.
1572 (warn_parm_ptrarray_mismatch): Fix comment typos, os -> of
1573 and onless -> unless.
1574 (warn_parm_array_mismatch): Fix comment typos, declaratation
1575 -> declaration and woud -> would. Fix up comment indentation.
1576
15772021-04-08 Martin Sebor <msebor@redhat.com>
1578
1579 PR middle-end/99883
1580 * c.opt (Wmismatched-new-delete): Correct spelling.
1581
b1da9916
GA
15822021-04-05 Eric Botcazou <ebotcazou@adacore.com>
1583
1584 * c-ada-spec.c (is_simple_enum): Minor tweaks.
1585 (dump_ada_enum_type): Add TYPE and PARENT parameters. For non-simple
1586 enumeral types use again the type name for the enumeration constants.
1587 (dump_ada_node): Adjust call to dump_ada_enum_type.
1588 (dump_nested_type): Likewise.
1589
f1607029
GA
15902021-04-01 Jason Merrill <jason@redhat.com>
1591
1592 PR c++/98481
1593 * c-opts.c (c_common_post_options): Bump latest_abi_version.
1594
4493b1c1
GA
15952021-03-25 Jakub Jelinek <jakub@redhat.com>
1596
1597 PR c++/99565
1598 * c-warn.c (do_warn_duplicated_branches): Pass also
1599 OEP_ADDRESS_OF_SAME_FIELD to operand_equal_p.
1600
6af7b307
GA
16012021-03-20 Jakub Jelinek <jakub@redhat.com>
1602
1603 PR debug/99230
1604 * c-gimplify.c (c_genericize_control_stmt): Handle STATEMENT_LIST.
1605
ceae9533
GA
16062021-03-05 Eric Botcazou <ebotcazou@adacore.com>
1607
1608 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Dump nested types
1609 after entering the separate class package, if any.
1610
67f10d28
GA
16112021-03-04 Richard Biener <rguenther@suse.de>
1612
1613 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator):
1614 Handle ERROR_MARK.
1615
16162021-03-04 Jakub Jelinek <jakub@redhat.com>
1617
1618 PR c/99325
1619 * c-ppoutput.c (print): Change src_line type from int to unsigned.
1620 (token_streamer::stream) Likewise.
1621 (maybe_print_line_1): Likewise. Don't strcmp src_file if src_loc is
1622 UNKNOWN_LOCATION.
1623
f3641ac7
GA
16242021-03-03 Jakub Jelinek <jakub@redhat.com>
1625
1626 PR c/99324
1627 * c-common.c (build_va_arg): Call c_common_mark_addressable_vec
1628 instead of mark_addressable. Fix a comment typo -
1629 neutrallly -> neutrally.
1630
2c83c3fb
GA
16312021-02-28 Jakub Jelinek <jakub@redhat.com>
1632
1633 PR c/99304
1634 * c-attribs.c (handle_malloc_attribute): Fix a typo in inform
1635 message - refernced -> referenced. Remove superfluous space before
1636 closing paren of function calls.
1637
daa68844
GA
16382021-02-25 Nathan Sidwell <nathan@acm.org>
1639
1640 PR c++/99166
1641 * c.opt (-flang-info-module-cmi): Renamed option.
1642
50352c6c
GA
16432021-02-19 Nathan Sidwell <nathan@acm.org>
1644
1645 * c.opt (flang-info-module-read, flang-info-module-read=): New.
1646
bf81237e
GA
16472021-02-18 H.J. Lu <hjl.tools@gmail.com>
1648
1649 PR target/99113
1650 * c-attribs.c (c_common_attribute_table): Add the "retain"
1651 attribute.
1652 (handle_retain_attribute): New function.
1653
0e804ce3
GA
16542021-02-16 Marek Polacek <polacek@redhat.com>
1655
1656 PR c++/99062
1657 * c-attribs.c (handle_assume_aligned_attribute): Check that the
1658 alignment argument is non-negative. Tweak a warning message.
1659
fab095da
GA
16602021-02-12 Martin Sebor <msebor@redhat.com>
1661
1662 PR c/99055
1663 * c-warn.c (warn_parm_array_mismatch): Free strings returned from
1664 print_generic_expr_to_str.
1665
4b37c3ea
GA
16662021-02-10 Richard Biener <rguenther@suse.de>
1667
1668 * c-common.c (parse_optimize_options): Free decoded_options.
1669
a19dd5e6
GA
16702021-02-04 emsr <3dw4rd@verizon.net>
1671
1672 * c-cppbuiltin.c (c_cpp_builtins): __cpp_size_t_suffix=202011L.
1673
9faaa807
GA
16742021-02-03 Ed Smith-Rowland <3dw4rd@verizon.net>
1675
1676 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_size_t_suffix.
1677 * c-lex.c (interpret_integer): Set node type for size literal.
1678
85d04a2e
GA
16792021-01-28 Jakub Jelinek <jakub@redhat.com>
1680
1681 * c.opt (-std=c++2a, -std=c++20, -std=gnu++2a, -std=gnu++20): Remove
1682 draft from description.
1683 (-std=c++2b): Fix a pasto, 2020 -> 2023.
1684
e62bb7f0
GA
16852021-01-26 Paul Fee <paul.f.fee@gmail.com>
1686
1687 * c-common.h (cxx_dialect): Add cxx23 as a dialect.
1688 * c.opt: Add options for -std=c++23, std=c++2b, -std=gnu++23
1689 and -std=gnu++2b
1690 * c-opts.c (set_std_cxx23): New.
1691 (c_common_handle_option): Set options when -std=c++23 is enabled.
1692 (c_common_post_options): Adjust comments.
1693 (set_std_cxx20): Likewise.
1694
161e4c08
GA
16952021-01-25 Martin Sebor <msebor@redhat.com>
1696
1697 PR c++/98646
1698 * c-common.c (check_nonnull_arg): Adjust warning text.
1699
4c9bcd5c
GA
17002021-01-17 Martin Sebor <msebor@redhat.com>
1701
1702 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
1703 assume SSA_NAME_IDENTIFIER evaluates to nonzero.
1704
59cf67d1
GA
17052021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
1706
1707 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DETACH.
1708 Redefine PRAGMA_OACC_CLAUSE_DETACH.
1709
2f7f0d32
GA
17102021-01-15 Jakub Jelinek <jakub@redhat.com>
1711
1712 PR tree-optimization/98597
1713 * c-pretty-print.c: Include options.h.
1714 (c_fold_indirect_ref_for_warn): New function.
1715 (print_mem_ref): Use it. If it returns something that has compatible
1716 type and is TBAA compatible with zero offset, print it and return,
1717 otherwise print it using offsetof syntax or array ref syntax. Fix up
1718 printing if MEM_REFs first operand is ADDR_EXPR, or when the first
1719 argument has pointer to array type. Print pointers using the standard
1720 formatting.
1721
6851dda2
GA
17222021-01-12 Martin Sebor <msebor@redhat.com>
1723
1724 PR c/98597
1725 PR c/98592
1726 * c-pretty-print.c (print_mem_ref): Avoid assuming MEM_REF operand
1727 has pointer type. Remove redundant code. Avoid calling
1728 gimple_canonical_types_compatible_p.
1729
7d187e4f
GA
17302021-01-07 Martin Sebor <msebor@redhat.com>
1731
1732 PR middle-end/98578
1733 * c-pretty-print.c (print_mem_ref): Strip array from access type.
1734 Avoid assuming acces type's size is constant. Correct condition
1735 guarding the printing of a parenthesis.
1736
942ae5be
GA
17372021-01-06 Martin Sebor <msebor@redhat.com>
1738
1739 PR c++/95768
1740 * c-pretty-print.c (c_pretty_printer::primary_expression): For
1741 SSA_NAMEs print VLA names and GIMPLE defining statements.
1742 (print_mem_ref): New function.
1743 (c_pretty_printer::unary_expression): Call it.
1744
17452021-01-06 Richard Biener <rguenther@suse.de>
1746
1747 PR tree-optimization/95582
1748 * c-attribs.c (c_common_attribute_table): Add entry for
1749 signed_bool_precision.
1750 (handle_signed_bool_precision_attribute): New.
1751
8daa719b
GA
17522020-12-24 Iain Sandoe <iain@sandoe.co.uk>
1753
1754 * c.opt: Add -stdlib= option and enumerations for
1755 libstdc++ and libc++.
1756
eefe499f
GA
17572020-12-16 Martin Liska <mliska@suse.cz>
1758
1759 * c.opt: Remove usage of Report.
1760
d52945ce
GA
17612020-12-14 Martin Sebor <msebor@redhat.com>
1762
1763 PR middle-end/98166
1764 PR c++/57111
1765 PR middle-end/98160
1766 * c-attribs.c (maybe_add_noinline): New function.
1767 (handle_malloc_attribute): Call it. Use ATTR_FLAG_INTERNAL.
1768 Implicitly add attribute noinline to functions not declared inline
1769 and warn on those.
1770
ca2bd949
GA
17712020-12-09 Tobias Burnus <tobias@codesourcery.com>
1772
1773 * c-pragma.c (omp_pragmas): Add 'allocate'.
1774 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ALLOCATE.
1775
f6e8e279
GA
17762020-12-08 Jakub Jelinek <jakub@redhat.com>
1777
1778 PR c++/98187
1779 * c-pragma.c (omp_pragmas): Remove "master".
1780 (omp_pragmas_simd): Add "master".
1781
bc8a7013
GA
17822020-12-07 Marek Polacek <polacek@redhat.com>
1783
1784 PR c++/98126
1785 * c-common.c (verify_tree_lim_r): New function.
1786 (verify_sequence_points): Use it. Use nullptr instead of 0.
1787
b8dd0ef7
GA
17882020-12-03 Martin Sebor <msebor@redhat.com>
1789
1790 PR c++/90629
1791 PR middle-end/94527
1792 * c-attribs.c (handle_dealloc_attribute): New function.
1793 (handle_malloc_attribute): Handle argument forms of attribute.
1794 * c.opt (-Wmismatched-dealloc): New option.
1795 (-Wmismatched-new-delete): New option.
1796
17972020-12-03 Jakub Jelinek <jakub@redhat.com>
1798
1799 PR libstdc++/93121
1800 * c-common.h (enum rid): Add RID_BUILTIN_BIT_CAST.
1801 * c-common.c (c_common_reswords): Add __builtin_bit_cast.
1802
e0f5e792
GA
18032020-12-01 JeanHeyd Meneide <phdofthehouse@gmail.com>
1804
1805 * c-cppbuiltin.c (c_cpp_builtins): Add predefined
1806 {__GNUC_EXECUTION_CHARSET_NAME} and
1807 _WIDE_EXECUTION_CHARSET_NAME} macros.
1808
18092020-12-01 Nathan Sidwell <nathan@acm.org>
1810
1811 * c-common.c (module, import, export): New internal tokens (with
1812 trailing space).
1813 * c-common.h (RID__MODULE, RID__IMPORT & RID__EXPORT): Enumerate
1814 them.
1815 (D_CXX_MODULES, D_CXX_MODULES_FLAGS): Enable them.
1816 * c-cppbuiltin.c (c_cpp_builtins): Feature macro.
1817
18182020-12-01 Nathan Sidwell <nathan@acm.org>
1819
1820 * c-opts.c (c_common_init_options): Ask for module dependencies.
1821 (c_common_handle_option): Handle -Mmodules -Mno-modules.
1822 * c-pch.c (c_common_valid_pch): ... does not play with C++
1823 modules.
1824 * c.opt (Mmodules, Mno-modules): New preprocessor dependency
1825 options.
1826 (fmodules-ts, fmodule-header, fmodule-implicit-inline)
1827 (fmodule-only, fmodule-mapper, fmodule-lazy)
1828 (fmodule-version-ignore, Winvalid-imported-macros)
1829 (flang-info-include-translate, flang-info-include-translate-not):
1830 New options
1831
5fbf0ecb
GA
18322020-11-28 Eric Botcazou <ebotcazou@adacore.com>
1833
1834 * c-ada-spec.c (dump_nested_type) <RECORD_TYPE>: Remove obsolete code.
1835 (dump_ada_structure): Also deal with convention, unchecked union and
1836 bit-field for nested types. In the latter case, print an Alignment
1837 aspect along with the Pack aspect.
1838
360258da
GA
18392020-11-25 Martin Sebor <msebor@redhat.com>
1840
1841 PR bootstrap/94982
1842 * c-attribs.c (handle_patchable_function_entry_attribute): Avoid
1843 -Wformat-diag.
1844
1e2c9a27
GA
18452020-11-24 Martin Sebor <msebor@redhat.com>
1846
1847 * c-warn.c (warn_parm_array_mismatch): Avoid invalid redeclarations.
1848
8e6198d0
GA
18492020-11-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
1850
1851 * c-attribs.c (handle_special_var_sec_attribute): New.
1852 (handle_noinit_attribute): Remove.
1853 (attr_noinit_exclusions): Rename to...
1854 (attr_section_exclusions): ...this, and add "persistent" attribute
1855 exclusion.
1856 (c_common_attribute_table): Add "persistent" attribute.
1857
7a97e2fc
GA
18582020-11-21 Aaron Sawdey <acsawdey@linux.ibm.com>
1859
1860 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
1861 Treat opaque types like other types.
1862 (c_pretty_printer::direct_abstract_declarator): Opaque types are
1863 supported types.
1864
82e5048e
GA
18652020-11-20 Martin Sebor <msebor@redhat.com>
1866
1867 * c-warn.c (warn_parm_array_mismatch): Bail on invalid redeclarations
1868 with fewer arguments.
1869
18702020-11-20 Martin Sebor <msebor@redhat.com>
1871
1872 PR middle-end/97879
1873 * c-attribs.c (handle_access_attribute): Handle ATTR_FLAG_INTERNAL.
1874 Error out on invalid modes.
1875
18762020-11-20 Jakub Jelinek <jakub@redhat.com>
1877
1878 PR libstdc++/88101
1879 * c-common.c (check_builtin_function_arguments): Handle
1880 BUILT_IN_CLEAR_PADDING.
1881
25bb75f8
GA
18822020-11-18 Nathan Sidwell <nathan@acm.org>
1883
1884 * c-lex.c (c_lex_with_flags): CPP_HEADER_NAMEs can now be seen.
1885
4dabb037
GA
18862020-11-17 Nathan Sidwell <nathan@acm.org>
1887
1888 * c-common.h (enum c_tree_index): Reorder to place lazy fields
1889 after newly-added CTI_MODULE_HWM.
1890
18912020-11-17 Joseph Myers <joseph@codesourcery.com>
1892
1893 * c-cppbuiltin.c (builtin_define_float_constants): Define
1894 "*_IS_IEC_60559__" macros.
1895
18962020-11-17 Nathan Sidwell <nathan@acm.org>
1897
1898 * c-lex.c: #include "langhooks.h".
1899 (cb_undef): Maybe call preprocess_undef lang hook.
1900 * c-opts.c (c_common_post_options): Maybe call preprocess_options
1901 lang hook.
1902 (push_command_line_include): Maybe call preprocess_main_file lang
1903 hook.
1904 (cb_file_change): Likewise.
1905 * c-ppoutput.c: #include "langhooks.h.
1906 (scan_translation_unit): Maybe call preprocess_token lang hook.
1907 (class do_streamer): New, derive from token_streamer.
1908 (directives_only_cb): Data pointer is do_streamer, call
1909 preprocess_token lang hook.
1910 (scan_translation_unit_directives_only): Use do_streamer.
1911 (print_line_1): Move src_line recording to after string output.
1912 (cb_undef): Maybe call preprocess_undef lang hook.
1913
19142020-11-17 Nathan Sidwell <nathan@acm.org>
1915
1916 * c-ppoutput.c (scan_translation_unit): Use token_streamer, remove
1917 code duplicating that functionality.
1918
19192020-11-17 Jakub Jelinek <jakub@redhat.com>
1920
1921 PR c/90628
1922 * c-common.c (check_builtin_function_arguments)
1923 <case BUILT_IN_ADD_OVERFLOW>: Diagnose when last argument is pointer
1924 to _Atomic. For the TYPE_READONLY case, adjust message to be usable
1925 for more builtins and argument positions.
1926
29c5d9ce
GA
19272020-11-16 Iain Sandoe <iain@sandoe.co.uk>
1928
1929 PR objc/97854
1930 * stub-objc.c: Include c-common.h to declare enum rid.
1931
77f67db2
GA
19322020-11-13 Jakub Jelinek <jakub@redhat.com>
1933
1934 PR c++/63287
1935 * c-cppbuiltin.c: Include configargs.h.
1936 (c_cpp_builtins): For C++11 and later if THREAD_MODEL_SPEC is not
1937 defined, predefine __STDCPP_THREADS__ to 1 unless thread_model is
1938 "single".
1939
19402020-11-13 Gergö Barany <gergo@codesourcery.com>
1941 Thomas Schwinge <thomas@codesourcery.com>
1942
1943 * c.opt (fopenacc-kernels): Add.
1944
19452020-11-13 Jason Merrill <jason@redhat.com>
1946
1947 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_using_enum.
1948
19492020-11-13 Piotr H. Dabrowski <phd@phd.re>
1950
1951 PR c++/91318
1952 * c-cppbuiltin.c: c_cpp_builtins_optimize_pragma(): use cpp_define_unused()
1953
19542020-11-13 Martin Liska <mliska@suse.cz>
1955
1956 * c-attribs.c (build_attr_access_from_parms): Format properly.
1957
19582020-11-13 Iain Sandoe <iain@sandoe.co.uk>
1959
1960 PR objc/90707
1961 * c-common.c (c_common_reswords): null_unspecified, nullable,
1962 nonnull, null_resettable: New keywords.
1963 * c-common.h (enum rid): RID_NULL_UNSPECIFIED, RID_NULLABLE,
1964 RID_NONNULL, RID_NULL_RESETTABLE: New.
1965 (OBJC_IS_PATTR_KEYWORD): Include nullability keywords in the
1966 ranges accepted for property attributes.
1967 * c-attribs.c (handle_objc_nullability_attribute): New.
1968 * c-objc.h (enum objc_property_attribute_group): Add
1969 OBJC_PROPATTR_GROUP_NULLABLE.
1970 (enum objc_property_attribute_kind):Add
1971 OBJC_PROPERTY_ATTR_NULL_UNSPECIFIED, OBJC_PROPERTY_ATTR_NULLABLE,
1972 OBJC_PROPERTY_ATTR_NONNULL, OBJC_PROPERTY_ATTR_NULL_RESETTABLE.
1973
19742020-11-13 Iain Sandoe <iain@sandoe.co.uk>
1975
1976 PR objc/77404
1977 * c-attribs.c (handle_objc_root_class_attribute): New
1978 * c-objc.h (objc_start_class_interface): Add a location
1979 value for the position of the class name.
1980 * c.opt: Add Wobjc-root-class.
1981 * stub-objc.c (objc_start_class_interface): Add a location
1982 value for the position of the class name.
1983
a5a11525
GA
19842020-11-12 Joseph Myers <joseph@codesourcery.com>
1985
1986 * c-lex.c (c_common_has_attribute): Take argument std_syntax.
1987 Allow scope for C. Handle standard attributes for C. Do not
1988 accept unscoped attributes if std_syntax and not handled as
1989 standard attributes.
1990 * c-common.h (c_common_has_attribute): Update prototype.
1991
19922020-11-12 Nicholas Guriev <guriev-ns@ya.ru>
1993
1994 PR pch/86674
1995 * c-pch.c (c_common_valid_pch): Use cpp_warning with CPP_W_INVALID_PCH
1996 reason to fix -Werror=invalid-pch and -Wno-error=invalid-pch switches.
1997
0f5f9ed5
GA
19982020-11-11 Patrick Palka <ppalka@redhat.com>
1999
2000 PR c++/88115
2001 * c-opts.c (c_common_post_options): Update latest_abi_version.
2002
bb622641
GA
20032020-11-10 Jakub Jelinek <jakub@redhat.com>
2004
2005 PR c/97748
2006 * c-common.h (warn_if_unused_value): Add quiet argument defaulted
2007 to false.
2008 * c-warn.c (warn_if_unused_value): Likewise. Pass it down
2009 recursively and just return true instead of warning if it is true.
2010 Handle COMPLEX_EXPR.
2011
20122020-11-10 Chung-Lin Tang <cltang@codesourcery.com>
2013
2014 * c-common.h (c_omp_adjust_map_clauses): New declaration.
2015 * c-omp.c (struct map_clause): Helper type for c_omp_adjust_map_clauses.
2016 (c_omp_adjust_map_clauses): New function.
2017
2bee28dd
GA
20182020-11-09 Marek Polacek <polacek@redhat.com>
2019
2020 DR 1914
2021 * c-common.c (attribute_fallthrough_p): Tweak the warning
2022 message.
2023
20242020-11-09 Patrick Palka <ppalka@redhat.com>
2025
2026 * c-pragma.c (handle_pragma_diagnostic): Split the
2027 unknown-option -Wpragmas diagnostic into a warning and a
2028 subsequent note containing a spelling suggestion. Avoid
2029 computing the suggestion if -Wpragmas warnings are being
2030 suppressed.
2031
20322020-11-09 Patrick Palka <ppalka@redhat.com>
2033
2034 PR testsuite/97117
2035 * c-indentation.c (get_visual_column): Remove location_t
2036 parameter. Move the column-tracking diagnostic code from here
2037 to ...
2038 (should_warn_for_misleading_indentation): ... here, before the
2039 early exit for when the loci are not all distinct. Don't pass a
2040 location_t argument to get_visual_column.
2041 (assert_get_visual_column_succeeds): Don't pass a location_t
2042 argument to get_visual_column.
2043 (assert_get_visual_column_fails): Likewise.
2044
fb95de7a
GA
20452020-11-08 Iain Sandoe <iain@sandoe.co.uk>
2046
2047 * c-common.h (OBJC_IS_PATTR_KEYWORD): Add class to the list
2048 of keywords accepted in @property attribute contexts.
2049 * c-objc.h (enum objc_property_attribute_group): Add
2050 OBJC_PROPATTR_GROUP_CLASS.
2051 (enum objc_property_attribute_kind): Add
2052 OBJC_PROPERTY_ATTR_CLASS.
2053
2da7ee05
GA
20542020-11-07 Iain Sandoe <iain@sandoe.co.uk>
2055
2056 * c-common.c (c_common_reswords): Add 'atomic' property
2057 attribute.
2058 * c-common.h (enum rid): Add RID_PROPATOMIC for atomic
2059 property attributes.
2060
20612020-11-07 Iain Sandoe <iain@sandoe.co.uk>
2062
2063 * c-attribs.c (handle_nsobject_attribute): New.
2064 * c.opt: Add WNSObject-attribute.
2065
44cab2d8
GA
20662020-11-06 Iain Sandoe <iain@sandoe.co.uk>
2067
2068 * c-objc.h (enum objc_property_attribute_group): New
2069 (enum objc_property_attribute_kind): New.
2070 (OBJC_PROPATTR_GROUP_MASK): New.
2071 (struct property_attribute_info): Small class encapsulating
2072 parser output from property attributes.
2073 (objc_prop_attr_kind_for_rid): New
2074 (objc_add_property_declaration): Simplify interface.
2075 * stub-objc.c (enum rid): Dummy type.
2076 (objc_add_property_declaration): Simplify interface.
2077 (objc_prop_attr_kind_for_rid): New.
2078
20792020-11-06 Nathan Sidwell <nathan@acm.org>
2080
2081 * c-ada-spec.c (collect_ada_nodes): Rename
2082 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
2083 (collect_ada_node): Likewise.
2084 (dump_forward_type): Likewise.
2085 * c-common.c (set_underlying_type): Rename
2086 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
2087 (user_facing_original_type, c_common_finalize_early_debug): Likewise.
2088
20892020-11-06 Jakub Jelinek <jakub@redhat.com>
2090
2091 * c-common.c (verify_sequence_points): Remove DEBUG_FUNCTION.
2092
0cfd9109
GA
20932020-11-05 Marek Polacek <polacek@redhat.com>
2094
2095 PR c++/97675
2096 * c.opt (Wexceptions): New option.
2097
20982020-11-05 Marek Polacek <polacek@redhat.com>
2099
2100 PR c++/25814
2101 * c.opt (Wvexing-parse): New option.
2102
35c125cb
GA
21032020-11-04 Jakub Jelinek <jakub@redhat.com>
2104
2105 PR c++/97670
2106 * c-omp.c (c_omp_split_clauses): Look through array reductions to find
2107 underlying decl to clear in the allocate_head bitmap.
2108
21092020-11-04 Iain Sandoe <iain@sandoe.co.uk>
2110
2111 * c-objc.h (objc_non_constant_expr_p): New.
2112 * stub-objc.c (objc_non_constant_expr_p): New.
2113
fd2325ea
GA
21142020-11-03 Nathan Sidwell <nathan@acm.org>
2115
2116 * c.opt (MQ,MT): Reword description to be make-agnostic.
2117
88ce3d5f
GA
21182020-11-02 Nathan Sidwell <nathan@acm.org>
2119
2120 * c-opts.c (c_common_post_options): Move var decl to its
2121 initialization point.
2122
21232020-11-01 Iain Sandoe <iain@sandoe.co.uk>
2124
2125 * c-lex.c (c_lex_with_flags): When combining '@' with a
2126 keyword for Objective-C, combine the location ranges too.
2127
21282020-10-30 Qing Zhao <qing.zhao@oracle.com>
2129 H.J.Lu <hjl.tools@gmail.com>
2130
2131 * c-attribs.c (c_common_attribute_table): Add new attribute
2132 zero_call_used_regs.
2133 (handle_zero_call_used_regs_attribute): New function.
2134
e93aae4a
GA
21352020-10-28 Marek Polacek <polacek@redhat.com>
2136
2137 PR c++/97573
2138 * c-opts.c (c_common_post_options): In C++20, turn on
2139 -Wdeprecated-enum-enum-conversion and
2140 -Wdeprecated-enum-float-conversion.
2141 * c.opt (Wdeprecated-enum-enum-conversion,
2142 Wdeprecated-enum-float-conversion): New options.
2143 (Wenum-conversion): Allow for C++ too.
2144
21452020-10-28 Jakub Jelinek <jakub@redhat.com>
2146
2147 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALLOCATE.
2148 * c-omp.c: Include bitmap.h.
2149 (c_omp_split_clauses): Handle OMP_CLAUSE_ALLOCATE.
2150
f19e7c8d
GA
21512020-10-26 Ville Voutilainen <ville.voutilainen@gmail.com>
2152
2153 * c-common.c (__is_nothrow_assignable): New.
2154 (__is_nothrow_constructible): Likewise.
2155 * c-common.h (RID_IS_NOTHROW_ASSIGNABLE): New.
2156 (RID_IS_NOTHROW_CONSTRUCTIBLE): Likewise.
2157
efe71fcc
GA
21582020-10-23 Jan Hubicka <hubicka@ucw.cz>
2159
2160 * c-common.c (c_common_finalize_early_debug): Update for new thunk api.
2161
21622020-10-23 Marek Polacek <polacek@redhat.com>
2163
2164 PR c++/91741
2165 * c-common.c (verify_tree): Handle PAREN_SIZEOF_EXPR.
2166 (c_common_init_ts): Likewise.
2167 * c-common.def (PAREN_SIZEOF_EXPR): New tree code.
2168 * c-common.h (maybe_warn_sizeof_array_div): Declare.
2169 * c-warn.c (sizeof_pointer_memaccess_warning): Unwrap NOP_EXPRs.
2170 (maybe_warn_sizeof_array_div): New function.
2171 * c.opt (Wsizeof-array-div): New option.
2172
21732020-10-23 Martin Sebor <msebor@redhat.com>
2174
2175 PR c/97463
2176 * c-warn.c (warn_parm_ptrarray_mismatch): Move null test earlier.
2177
56ddd5e2
GA
21782020-10-22 Martin Liska <mliska@suse.cz>
2179
2180 PR c/94722
2181 * c-attribs.c (handle_no_stack_protect_function_attribute): New.
2182 (handle_stack_protect_attribute): Add error message for a
2183 no_stack_protector function.
2184
21852020-10-22 Martin Liska <mliska@suse.cz>
2186
2187 * c-cppbuiltin.c (c_cpp_builtins): Use the stack_protector enum.
2188
21892020-10-22 Jan Hubicka <hubicka@ucw.cz>
2190
2191 * c-gimplify.c: Include tree-nested.h
2192 (c_genericize): Update for new nested function info.
2193
b2698c21
GA
21942020-10-14 Martin Sebor <msebor@redhat.com>
2195
2196 PR c/97413
2197 * c-attribs.c (build_attr_access_from_parms): Wrap chain of VLA
2198 bounds in an extra list.
2199
7e9282ae
GA
22002020-10-05 Richard Biener <rguenther@suse.de>
2201 Jakub Jelinek <jakub@redhat.com>
2202
2203 PR c++/97197
2204 * c-pretty-print.c: Include langhooks.h.
2205 (c_pretty_printer::postfix_expression): Handle TARGET_MEM_REF as
2206 expression.
2207 (c_pretty_printer::expression): Handle TARGET_MEM_REF as
2208 unary_expression.
2209 (c_pretty_printer::unary_expression): Handle TARGET_MEM_REF.
2210
660bfe61
GA
22112020-09-30 Martin Sebor <msebor@redhat.com>
2212
2213 PR middle-end/97189
2214 * c-attribs.c (append_access_attr): Use the function declaration
2215 location for a warning about an attribute access argument.
2216
93bca37c
GA
22172020-09-29 Marek Polacek <polacek@redhat.com>
2218
2219 PR c++/94695
2220 * c.opt (Wrange-loop-construct): New option.
2221
82b77dee
GA
22222020-09-23 Martin Sebor <msebor@redhat.com>
2223
2224 PR c/97131
2225 * c-warn.c (warn_parm_ptrarray_mismatch): Handle more invalid input.
2226
22272020-09-23 Marek Polacek <polacek@redhat.com>
2228
2229 PR c/97125
2230 * c-gimplify.c (c_genericize): Only call do_warn_duplicated_branches_r
2231 after loops and other structured control constructs have been lowered.
2232
521d2711
GA
22332020-09-22 Jakub Jelinek <jakub@redhat.com>
2234
2235 * c.opt (Wbuiltin-declaration-mismatch): Fix typo in variable name:
2236 warn_builtin_declaraion_mismatch -> warn_builtin_declaration_mismatch.
2237
44135373
GA
22382020-09-21 Marek Polacek <polacek@redhat.com>
2239
2240 * c.opt (Wctad-maybe-unsupported): New option.
2241
2fe5b7d1
GA
22422020-09-19 Martin Sebor <msebor@redhat.com>
2243
2244 PR c/50584
2245 * c-common.h (warn_parm_array_mismatch): Declare new function.
2246 (has_attribute): Move declaration of an existing function.
2247 (build_attr_access_from_parms): Declare new function.
2248 * c-warn.c (parm_array_as_string): Define new function.
2249 (plus_one): Define new function.
2250 (warn_parm_ptrarray_mismatch): Define new function.
2251 (warn_parm_array_mismatch): Define new function.
2252 (vla_bound_parm_decl): New function.
2253 * c.opt (-Warray-parameter, -Wvla-parameter): New options.
2254 * c-pretty-print.c (pp_c_type_qualifier_list): Don't print array type
2255 qualifiers here...
2256 (c_pretty_printer::direct_abstract_declarator): ...but instead print
2257 them in brackets here. Also print [static]. Strip extraneous
2258 expressions from VLA bounds.
2259
22602020-09-19 Martin Sebor <msebor@redhat.com>
2261
2262 PR c/50584
2263 * c-attribs.c (c_common_attribute_table): Add "arg spec" attribute.
2264 (handle_argspec_attribute): New function.
2265 (get_argument, get_argument_type): New functions.
2266 (append_access_attrs): Add overload. Handle internal attribute
2267 representation in addition to external.
2268 (handle_access_attribute): Handle internal attribute representation
2269 in addition to external.
2270 (build_attr_access_from_parms): New function.
2271
22722020-09-19 Sandra Loosemore <sandra@codesourcery.com>
2273
2274 * c-gimplify.c (genericize_c_loop): Rewrite to match
2275 c_finish_loop in c-typeck.c.
2276
22772020-09-19 Sandra Loosemore <sandra@codesourcery.com>
2278
2279 * c-common.c (c_block_may_fallthrough): New, split from
2280 cxx_block_may_fallthrough in the cp front end.
2281 (c_common_init_ts): Move handling of loop and switch-related
2282 statements here from the cp front end.
2283 * c-common.def (FOR_STMT, WHILE_STMT, DO_STMT): Move here from
2284 cp front end.
2285 (BREAK_STMT, CONTINUE_STMT, SWITCH_STMT): Likewise.
2286 * c-common.h (c_block_may_fallthru): Declare.
2287 (bc_state_t): Move here from cp front end.
2288 (save_bc_state, restore_bc_state): Declare.
2289 (c_genericize_control_stmt): Declare.
2290 (WHILE_COND, WHILE_BODY): Likewise.
2291 (DO_COND, DO_BODY): Likewise.
2292 (FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY, FOR_SCOPE): Likewise.
2293 (SWITCH_STMT_COND, SWITCH_STMT_BODY): Likewise.
2294 (SWITCH_STMT_TYPE, SWITCH_STMT_SCOPE): Likewise.
2295 (SWITCH_STMT_ALL_CASES_P, SWITCH_STMT_NO_BREAK_P): Likewise.
2296 (LABEL_DECL_BREAK, LABEL_DECL_CONTINUE): Likewise.
2297 * c-dump.c (dump_stmt): Copy from cp front end.
2298 (c_dump_tree): Move code to handle structured loop and switch
2299 tree nodes here from cp front end.
2300 * c-gimplify.c: Adjust includes.
2301 (enum bc_t, bc_label, begin_bc_block, finish_bc_block): Move from
2302 cp front end.
2303 (save_bc_state, restore_bc_state): New functions using old code
2304 from cp front end.
2305 (get_bc_label, expr_loc_or_loc): Move from cp front end.
2306 (genericize_c_loop): Move from cp front end.
2307 (genericize_for_stmt, genericize_while_stmt): Likewise.
2308 (genericize_do_stmt, genericize_switch_stmt): Likewise.
2309 (genericize_continue_stmt, genericize_break_stmt): Likewise.
2310 (genericize_omp_for_stmt): Likewise.
2311 (c_genericize_control_stmt): New function using code split from
2312 cp front end.
2313 (c_genericize_control_r): New.
2314 (c_genericize): Call walk_tree with c_genericize_control_r.
2315 * c-pretty-print.c (c_pretty_printer::statement): Move code to handle
2316 structured loop and switch tree nodes here from cp front end.
2317
2aad20c0
GA
23182020-09-17 Patrick Palka <ppalka@redhat.com>
2319
2320 PR c/80076
2321 * c-indentation.c (should_warn_for_misleading_indentation): Move
2322 declarations of local variables closer to their first use.
2323 Handle virtual token locations by resolving them to their
2324 respective macro expansion points. If all three tokens are
2325 produced from the same macro expansion, then instead use their
2326 loci within the macro definition.
2327
ecde1b0a
GA
23282020-09-16 Martin Sebor <msebor@redhat.com>
2329
2330 PR c/78666
2331 PR c/96126
2332 * c-attribs.c (validate_attr_args): New function.
2333 (validate_attr_arg): Same.
2334 (handle_section_attribute): Call it. Introduce a local variable.
2335 (handle_alloc_size_attribute): Same.
2336 (handle_alloc_align_attribute): Same.
2337
50a71cd0
GA
23382020-09-14 Jakub Jelinek <jakub@redhat.com>
2339
2340 * c-attribs.c (handle_optimize_attribute): Adjust
2341 cl_optimization_save, cl_optimization_restore and
2342 build_optimization_node callers.
2343 * c-pragma.c (handle_pragma_optimize): Adjust
2344 build_optimization_node caller.
2345 (handle_pragma_push_options): Adjust
2346 build_optimization_node and build_target_option_node callers.
2347 (handle_pragma_pop_options, handle_pragma_reset_options):
2348 Adjust cl_optimization_restore callers.
2349
8f7ea26a
GA
23502020-08-28 Martin Sebor <msebor@redhat.com>
2351
2352 * c.opt (Wstringop-overread): New option.
2353
a6493809
GA
23542020-08-11 Jakub Jelinek <jakub@redhat.com>
2355
2356 PR c/96545
2357 * c-common.c (get_atomic_generic_size): Require that first argument's
2358 type points to a complete type and use tree_fits_uhwi_p instead of
2359 just INTEGER_CST TREE_CODE check for the TYPE_SIZE_UNIT.
2360
48cc2e46
GA
23612020-07-31 Martin Sebor <msebor@redhat.com>
2362
2363 PR c++/96003
2364 * c-common.c (check_function_arguments_recurse): Return early when
2365 no-warning bit is set.
2366
23672020-07-31 Richard Biener <rguenther@suse.de>
2368
2369 PR debug/96383
2370 * c-common.h (c_common_finalize_early_debug): Declare.
2371 * c-common.c: Include debug.h.
2372 (c_common_finalize_early_debug): finalize_early_debug langhook
2373 implementation generating debug for extern declarations.
2374
e71dab87
GA
23752020-07-27 Nathan Sidwell <nathan@acm.org>
2376
2377 * c-common.c (try_to_locate_new_include_insertion_point): Use
2378 strcmp, not pointer equality.
2379
ae2e0bc1
GA
23802020-07-25 Martin Sebor <msebor@redhat.com>
2381
2382 PR c++/96310
2383 * c-common.c (check_nonnull_arg): Print note only when warning was
2384 issued.
2385
3ea9abca
GA
23862020-07-22 Tobias Burnus <tobias@codesourcery.com>
2387
2388 * c-omp.c (c_finish_omp_critical): Check for no name but
2389 nonzero hint provided.
2390
0933f508
GA
23912020-07-20 Jason Merrill <jason@redhat.com>
2392
2393 * c-cppbuiltin.c (c_cpp_builtins): Update
2394 __cpp_nontype_template_args for C++20.
2395
23962020-07-20 Martin Sebor <msebor@redhat.com>
2397
2398 PR c/96249
2399 * c.opt: Remove stray text.
2400
8ca07a30
GA
24012020-07-14 Lewis Hyatt <lhyatt@gmail.com>
2402
2403 PR other/86904
2404 * c-indentation.c (should_warn_for_misleading_indentation): Get
2405 global tabstop from the new source.
2406 * c-opts.c (c_common_handle_option): Remove handling of -ftabstop, which
2407 is now a common option.
2408 * c.opt: Likewise.
2409
a82c4c4c 24102020-07-08 Eric Botcazou <ebotcazou@adacore.com>
50873cc5
GA
2411
2412 * c.opt (Wscalar-storage-order): Add explicit variable.
2413
f60ee68d
GA
24142020-07-07 Nathan Sidwell <nathan@acm.org>
2415
2416 * c-opts.c (c_common_post_options): Add 'injecting' arg to
2417 cpp_read_main_file.
2418 (c_finish_options): Add linemap_line_start calls for builtin and cmd
2419 maps. Force token position to line_table's highest line.
2420 * c-ppoutput.c (print_line_1): Refactor, print line zero.
2421 (cb_define): Always increment source line.
2422
4077d74c
GA
24232020-07-06 Martin Sebor <msebor@redhat.com>
2424
2425 PR c++/95984
2426 * c-common.c (check_function_nonnull): Avoid checking syntesized calls
2427 to stub lambda objects with null this pointer.
2428 (check_nonnull_arg): Handle C++ nullptr.
2429
b5f24739
GA
24302020-07-02 Jason Merrill <jason@redhat.com>
2431 Jakub Jelinek <jakub@redhat.com>
2432
2433 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_consteval.
2434
46fbb6c6
GA
24352020-06-30 Jakub Jelinek <jakub@redhat.com>
2436
2437 PR c++/95963
2438 * c-common.c (check_function_arguments_recurse): Don't crash on
2439 calls to internal functions.
2440
69273534
GA
24412020-06-28 Martin Sebor <msebor@redhat.com>
2442
2443 PR c++/86568
2444 * c-common.c (struct nonnull_arg_ctx): Add members.
2445 (check_function_nonnull): Use nonnull_arg_ctx as argument. Handle
2446 C++ member functions specially. Consider the this pointer implicitly
2447 nonnull.
2448 (check_nonnull_arg): Use location of argument when available.
2449 (check_function_arguments): Use nonnull_arg_ctx as argument.
2450
9a33c41f
GA
24512020-06-27 Jakub Jelinek <jakub@redhat.com>
2452
2453 PR middle-end/95903
2454 * c-common.c (pointer_int_sum): Use TYPE_OVERFLOW_UNDEFINED instead of
2455 !TYPE_UNSIGNED check to see if we can apply distributive law and handle
2456 smaller precision intop operands separately.
2457
c9c05f73
GA
24582020-06-26 Marek Polacek <polacek@redhat.com>
2459
2460 * c-opts.c (c_common_init_options): Default to gnu++17.
2461
aff95ee7
GA
24622020-06-17 Jonathan Wakely <jwakely@redhat.com>
2463
bd0a89dc 2464 PR c/95378
aff95ee7
GA
2465 * c-common.c (get_atomic_generic_size): Check cv-qualifiers in
2466 pointer arguments.
2467
56638b9b
GA
24682020-06-16 Jakub Jelinek <jakub@redhat.com>
2469
2470 * c-common.h (c_omp_check_loop_iv_exprs): Add an int argument.
2471 * c-omp.c (struct c_omp_check_loop_iv_data): Add maybe_nonrect and
2472 idx members.
2473 (c_omp_is_loop_iterator): New function.
2474 (c_omp_check_loop_iv_r): Use it. Add support for silent scanning
2475 if outer loop iterator is present. Perform duplicate checking through
2476 hash_set in the function rather than expecting caller to do that.
2477 Pass NULL instead of d->ppset to walk_tree_1.
2478 (c_omp_check_nonrect_loop_iv): New function.
2479 (c_omp_check_loop_iv): Use it. Fill in new members, allow
2480 non-rectangular loop forms, diagnose multiple associated loops with
2481 the same iterator. Pass NULL instead of &pset to walk_tree_1.
2482 (c_omp_check_loop_iv_exprs): Likewise.
2483
ec6ffbb9
GA
24842020-06-10 Martin Liska <mliska@suse.cz>
2485
2486 PR tree-optimization/92860
2487 * c-attribs.c (handle_optimize_attribute):
2488 Save global options and compare it after parsing of function
2489 attribute.
2490 * c-pragma.c (opt_stack::saved_global_options): New field.
2491 (handle_pragma_push_options): Save global_options.
2492 (handle_pragma_pop_options): Compare them after pop.
2493
b952c2cf
GA
24942020-06-09 Jakub Jelinek <jakub@redhat.com>
2495
2496 PR c/95580
2497 * c-pretty-print.c (c_pretty_printer::unary_expression): Handle the
2498 case when MEM_REF's first argument has type pointer to incomplete type.
2499
1a59f3db
GA
25002020-06-05 Jason Merrill <jason@redhat.com>
2501
2502 * c-pretty-print.c (pp_c_additive_expression): Handle negative
2503 operand to POINTER_PLUS_EXPR.
2504
3add3425
GA
25052020-06-04 Martin Sebor <msebor@redhat.com>
2506
2507 PR middle-end/10138
2508 PR middle-end/95136
2509 * c-attribs.c (append_access_attrs): Handle attr_access::none.
2510 (handle_access_attribute): Same.
2511
9a5b7438
GA
25122020-06-03 Mark Wielaard <mark@klomp.org>
2513
2514 * known-headers.cc (get_cp_stdlib_header_for_string_macro_name):
2515 New function.
2516 * known-headers.h (get_cp_stdlib_header_for_string_macro_name):
2517 New function declaration.
2518
25192020-06-03 Mark Wielaard <mark@klomp.org>
2520
2521 * known-headers.cc (get_string_macro_hint): New function.
2522 (get_stdlib_header_for_name): Use get_string_macro_hint.
2523 (get_c_stdlib_header_for_string_macro_name): New function.
2524 * known-headers.h (get_c_stdlib_header_for_string_macro_name):
2525 New function declaration.
2526
25272020-06-03 Tobias Burnus <tobias@codesourcery.com>
2528
2529 * c-common.h (c_omp_predetermined_mapping): Declare.
2530 * c-omp.c (c_omp_predetermined_mapping): New.
2531
af114c38
MW
25322020-05-22 Mark Wielaard <mark@klomp.org>
2533
2534 * known-headers.cc (get_stdlib_header_for_name): Add a new
2535 stdlib_hint array for stdbool and stdint.
2536
45c50b6a
MW
25372020-05-22 Mark Wielaard <mark@klomp.org>
2538
2539 * known-headers.cc (get_stdlib_header_for_name): Return
2540 "<stdbool.h>" for "bool", "true" or "false" when STDLIB_C and
2541 flag_isoc99.
2542
c22027a0
NS
25432020-05-20 Nathan Sidwell <nathan@acm.org>
2544
38a4db21
NS
2545 * c-common.c (try_to_locate_new_include_insertion_point): Revert change.
2546
c22027a0
NS
2547 * c-common.c (try_to_locate_new_include_insertion_point): Use
2548 strcmp to compare filenames.
2549 * c-lex.c (init_c_lex): Move declaration to initialization.
2550 * c-opts.c (handle_deferred_opts): Move cpp_get_deps call into
2551 deferred count loop.
2552
29f0e90d
JM
25532020-05-15 Jason Merrill <jason@redhat.com>
2554
2555 * c-opts.c (set_std_cxx20): Set flag_coroutines.
2556
b04445d4
JM
25572020-05-13 Jason Merrill <jason@redhat.com>
2558
2559 * c.opt (std=c++20): Make c++2a the alias.
2560 (std=gnu++20): Likewise.
2561 * c-common.h (cxx_dialect): Change cxx2a to cxx20.
2562 * c-opts.c: Adjust.
2563 * c-cppbuiltin.c: Adjust.
2564 * c-ubsan.c: Adjust.
2565 * c-warn.c: Adjust.
2566
11dd3be5
EB
25672020-05-12 Eric Botcazou <ebotcazou@adacore.com>
2568
2569 * c-ada-spec.c (dump_ads): Output pragma Warnings ("U"); on entry.
2570
b224c376
NS
25712020-05-08 Nathan Sidwell <nathan@acm.org>
2572
2573 Reimplement directives only processing.
2574 * c-ppoutput.c (token_streamer): Ne.
2575 (directives_only_cb): New. Swallow ...
2576 (print_lines_directives_only): ... this.
2577 (scan_translation_unit_directives_only): Reimplment using the
2578 published interface.
2579
f1d94677
MP
25802020-05-07 Marek Polacek <polacek@redhat.com>
2581
2582 * c-format.c (badwords): Add "nonstatic".
2583
9b95bb52
JJ
2584202-05-07 Jakub Jelinek <jakub@redhat.com>
2585
2586 PR c/94968
2587 * c-common.c (speculation_safe_value_resolve_params): Return false if
2588 error_operand_p (val2).
2589 (resolve_overloaded_builtin) <case BUILT_IN_SPECULATION_SAFE_VALUE_N>:
2590 Remove extraneous semicolon.
2591
530b4409 25922020-05-06 qing zhao <qing.zhao@oracle.com>
2593
2594 PR c/94230
2595 * c-indentation.c (get_visual_column): Add a hint to use the new
2596 -flarge-source-files option.
2597
b776bdca
SSF
25982020-05-05 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
2599
2600 * c-attribs.c (handle_vector_size_attribute): Add attribute
2601 nonnull for argument args in order to silence warning of
2602 uninitialized variable usage. Since this is local to the
2603 compilation unit and thus cannot be checked at call sides by the
2604 compiler, added an assert statement in order to verify this.
2605
6607bdd9
L
26062020-05-01 H.J. Lu <hongjiu.lu@intel.com>
2607
2608 PR target/93492
2609 * c-attribs.c (handle_patchable_function_entry_attribute): Limit
2610 value to USHRT_MAX (65535).
2611
691eeb65
JJ
26122020-04-29 Jakub Jelinek <jakub@redhat.com>
2613
2614 * c-format.c (PP_FORMAT_CHAR_TABLE): Add %{ and %}.
2615
26d76be7
JJ
26162020-04-27 Jakub Jelinek <jakub@redhat.com>
2617
2618 PR c/94755
2619 * c-common.c (resolve_overloaded_builtin): Return error_mark_node for
2620 fncode == BUILT_IN_NONE before initialization of first_param.
2621
7291b2ed
MP
26222020-04-23 Marek Polacek <polacek@redhat.com>
2623
2624 PR c++/94733
2625 * c-attribs.c (find_tm_attribute): Use get_attribute_name instead of
2626 TREE_PURPOSE.
2627
58a29af8
PP
26282020-04-14 Patrick Palka <ppalka@redhat.com>
2629
2630 PR c++/85278
2631 * c-pretty-print.c (pp_c_pointer) <case REFERENCE_TYPE>: Print a double
2632 ampersand if it's an rvalue reference type.
2633
09f04139
MS
26342020-04-13 Martin Sebor <msebor@redhat.com>
2635
2636 PR c/92326
2637 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator): Avoid
2638 printing array bound for flexible array members.
2639
ee26baf4
IS
26402020-04-13 Iain Sandoe <iain@sandoe.co.uk>
2641
2642 * c-cppbuiltin.c (c_cpp_builtins): Update coroutines builtin
2643 define, per n4861.
2644
75efe9cb
RB
26452020-04-02 Richard Biener <rguenther@suse.de>
2646
2647 PR c/94392
2648 * c-opts.c (c_common_post_options): Enable -ffinite-loops
2649 for -O2 and C++11 or newer.
2650
75defde9
PP
26512020-03-28 Patrick Palka <ppalka@redhat.com>
2652
2653 * c.opt: Add -fconcepts-diagnostics-depth.
2654
52f24a9e
MS
26552020-03-27 Martin Sebor <msebor@redhat.com>
2656
2657 PR c++/94346
2658 * c-attribs.c (handle_copy_attribute): Avoid passing expressions
2659 to decl_attributes. Make handling of different kinds of entities
2660 more robust.
2661
ccacf77b
MS
26622020-03-27 Martin Sebor <msebor@redhat.com>
2663
2664 PR c++/94098
2665 * c-attribs.c (handle_access_attribute): Avoid setting TYPE_ATTRIBUTES
2666 here.
2667
ca6c7225
JJ
26682020-03-23 Jakub Jelinek <jakub@redhat.com>
2669
2670 PR c++/91993
2671 * c-warn.c (warnings_for_convert_and_check): For expr and/or
2672 result being COMPOUND_EXPRs, skip to ultimate rhs.
2673
1aa22b19
RS
26742020-03-20 Richard Sandiford <richard.sandiford@arm.com>
2675
2676 PR middle-end/94072
2677 * c-common.c (c_common_type_for_mode): Before using a registered
2678 built-in type, check that the vectorness of the type matches
2679 the vectorness of the mode.
2680
700d4cb0
JJ
26812020-03-17 Jakub Jelinek <jakub@redhat.com>
2682
2683 * c-common.c (resolve_overloaded_builtin): Fix up duplicated word
2684 issue in a diagnostic message.
2685
b408e010
LH
26862020-03-15 Lewis Hyatt <lhyatt@gmail.com>
2687
2688 * c.opt: Avoid redundancy in the help text.
2689
e78e50d5
MP
26902020-03-02 Marek Polacek <polacek@redhat.com>
2691
2692 PR c++/93958 - add missing -std=gnu++20.
2693 * c.opt: Add -std=gnu++20.
2694
649e1741
MS
26952020-03-01 Martin Sebor <msebor@redhat.com>
2696
2697 PR c++/92721
2698 * c-attribs.c (append_access_attrs): Correctly handle attribute.
2699 (handle_access_attribute): Same.
2700
7b60f3ba
JJ
27012020-02-25 Jakub Jelinek <jakub@redhat.com>
2702
2703 PR c/93858
2704 * c-pragma.c (handle_pragma_diagnostic): Add missing ? after
2705 "did you mean" hint in diagnostics.
2706
fb260504
JM
27072020-02-15 Jason Merrill <jason@redhat.com>
2708
2709 * c.opt: Add -std=c++20.
2710
1d757b09
EB
27112020-02-14 Eric Botcazou <ebotcazou@adacore.com>
2712
2713 * c-ada-spec.c: Include bitmap.h.
2714 (dump_ada_double_name): Rename into...
2715 (dump_anonymous_type_name): ...this. Always use the TYPE_UID.
2716 (dump_ada_array_type): Adjust to above renaming. Robustify.
2717 (dump_nested_types_1): New function copied from... Add dumped_types
2718 parameter and pass it down to dump_nested_type.
2719 (dump_nested_types): ...this. Remove parent parameter. Just call
2720 dump_nested_types_1 on an automatic bitmap.
2721 (dump_nested_type): Add dumped_types parameter.
2722 <ARRAY_TYPE>: Do not dump it if already present in dumped_types.
2723 Adjust recursive calls and adjust to above renaming.
2724 (dump_ada_declaration): Adjust call to dump_nested_types.
2725 Tidy up and adjust to above renaming.
2726 (dump_ada_specs): Initialize and release bitmap obstack.
2727
0cc575e4
MS
27282020-02-10 Martin Sebor <msebor@redhat.com>
2729
2730 PR c/93640
2731 * c-attribs.c (handle_access_attribute): Correct off-by-one mistakes.
2732
a59aa302
JJ
27332020-02-10 Jakub Jelinek <jakub@redhat.com>
2734
2735 PR other/93641
2736 * c-format.c (check_plain): Fix up last argument of strncasecmp.
2737 Remove useless extra test.
2738
e464fc90
TB
27392020-02-03 Julian Brown <julian@codesourcery.com>
2740 Tobias Burnus <tobias@codesourcery.com>
2741
2742 * c-cppbuiltin.c (c_cpp_builtins): Update _OPENACC define to 201711.
2743
e3b6c052
JM
27442020-01-29 Jason Merrill <jason@redhat.com>
2745
2746 PR c++/89357
2747 * c-attribs.c (check_cxx_fundamental_alignment_constraints): Remove.
2748
6d00f052
JM
27492020-01-23 Jason Merrill <jason@redhat.com>
2750
2751 * c-warn.c (conversion_warning): Change -Wsign-conversion handling.
2752
8a990ffa
MS
27532020-01-23 Martin Sebor <msebor@redhat.com>
2754
2755 PR c/84919
2756 * c-common.c (check_function_arguments): Avoid overlap checking
2757 of sprintf functions.
2758
55b7df8b
JM
27592020-01-22 Jason Merrill <jason@redhat.com>
2760
2761 PR testsuite/93391 - PR 40752 test fails with unsigned plain char.
2762 PR c++/40752
2763 * c-warn.c (conversion_warning): Check operands only after checking
2764 the whole expression. Don't check second operand of + for sign.
2765
c77074d0
JM
27662020-01-21 Jason Merrill <jason@redhat.com>
2767 Manuel López-Ibáñez <manu@gcc.gnu.org>
2768
2769 PR c++/40752 - useless -Wconversion with short +=.
2770 * c.opt (-Warith-conversion): New.
2771 * c-warn.c (conversion_warning): Recurse for operands of
2772 operators. Only warn about the whole expression with
2773 -Warith-conversion.
2774
731dbfc3
JM
27752020-01-21 Jason Merrill <jason@redhat.com>
2776
2777 * c-common.c (unsafe_conversion_p): Don't warn, return UNSAFE_SIGN.
2778 * c-warn.c (conversion_warning): Warn about UNSAFE_SIGN.
2779
ad1a3914
NS
27802020-01-20 Nathan Sidwell <nathan@acm.org>
2781
2782 PR preprocessor/80005
2783 * c-cppbuiltins.c (c_cpp_builtins): Don't define __has_include{,_next}.
2784
49789fd0
IS
27852020-01-18 Iain Sandoe <iain@sandoe.co.uk>
2786
2787 * c-common.c (co_await, co_yield, co_return): New.
2788 * c-common.h (RID_CO_AWAIT, RID_CO_YIELD,
2789 RID_CO_RETURN): New enumeration values.
2790 (D_CXX_COROUTINES): Bit to identify coroutines are active.
2791 (D_CXX_COROUTINES_FLAGS): Guard for coroutine keywords.
2792 * c-cppbuiltin.c (__cpp_coroutines): New cpp define.
2793 * c.opt (fcoroutines): New command-line switch.
2794
4bc1899b
DM
27952020-01-10 David Malcolm <dmalcolm@redhat.com>
2796
2797 * c-format.c (local_event_ptr_node): New.
2798 (PP_FORMAT_CHAR_TABLE): Add entry for "%@".
2799 (init_dynamic_diag_info): Initialize local_event_ptr_node.
2800 * c-format.h (T_EVENT_PTR): New define.
2801
f25e33fa
MS
28022020-01-10 Martin Sebor <msebor@redhat.com>
2803
2804 PR c/93132
2805 * c-attribs.c (append_access_attrs): Validate against the translated
2806 access string rather than the human-readable representation.
2807
8d9254fc
JJ
28082020-01-01 Jakub Jelinek <jakub@redhat.com>
2809
2810 Update copyright years.
2811
39292e25
EB
28122019-12-20 Eric Botcazou <ebotcazou@adacore.com>
2813
2814 * c-ada-spec.h (decl_sloc): Delete.
2815 * c-ada-spec.c (decl_sloc): Make static.
2816
519d7496
JB
28172019-12-19 Julian Brown <julian@codesourcery.com>
2818
2819 * c-common.h (c_omp_map_clause_name): Add prototype.
2820 * c-omp.c (c_omp_map_clause_name): New function.
2821 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ATTACH and
2822 PRAGMA_OACC_CLAUSE_DETACH.
2823
a6163563
JB
28242019-12-19 Julian Brown <julian@codesourcery.com>
2825 Maciej W. Rozycki <macro@codesourcery.com>
2826 Tobias Burnus <tobias@codesourcery.com>
2827 Thomas Schwinge <thomas@codesourcery.com>
2828
2829 * c-pragma.h (pragma_omp_clause): Add
2830 PRAGMA_OACC_CLAUSE_NO_CREATE.
2831
e8f1ade2
MS
28322019-12-17 Martin Sebor <msebor@redhat.com>
2833
2834 PR c++/61339
2835 * c.opt (-Wmismatched-tags, -Wredundant-tags): New options.
2836
368877a1
DM
28372019-12-11 David Malcolm <dmalcolm@redhat.com>
2838
2839 * c-pretty-print.c (c_pretty_printer::clone): New vfunc
2840 implementation.
2841 * c-pretty-print.h (c_pretty_printer::clone): New vfunc decl.
2842
d68f5d45
DM
28432019-12-09 David Malcolm <dmalcolm@redhat.com>
2844
2845 * c-format.c (range_label_for_format_type_mismatch::get_text):
2846 Replace label_text ctor called with true with label_text::take.
2847
d3e28653
DM
28482019-12-09 David Malcolm <dmalcolm@redhat.com>
2849
2850 * c-format.c (selftest::test_type_mismatch_range_labels): Remove
2851 initial newline from expected outputs.
2852 * c-opts.c (c_diagnostic_finalizer): Add pp_newline call before
2853 call to diagnostic_show_locus.
2854
abd6d8cc
JJ
28552019-12-06 Jakub Jelinek <jakub@redhat.com>
2856
2857 * c-cppbuiltin.c (c_cpp_builtins): Don't define __cpp_consteval for
2858 now.
2859
7906797e
MP
28602019-12-05 Marek Polacek <polacek@redhat.com>
2861 Jakub Jelinek <jakub@redhat.com>
2862
2863 PR c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.
2864 * c-cppbuiltin.c (c_cpp_builtins): Adjust the value of __cpp_constexpr.
2865
5c04da88
MP
28662019-12-05 Marek Polacek <polacek@redhat.com>
2867
2868 PR c++/92271 - make __is_same alias for __is_same_as.
2869 * c-common.c: Add __is_same, an alias for __is_same_as.
2870
43aae289
MP
28712019-12-03 Marek Polacek <polacek@redhat.com>
2872
2873 PR c++/91363 - P0960R3: Parenthesized initialization of aggregates.
2874 * c-cppbuiltin.c (c_cpp_builtins): Predefine
2875 __cpp_aggregate_paren_init=201902 for -std=c++2a.
2876
d7ddfbcb
JH
28772019-11-30 Jan Hubicka <hubicka@ucw.cz>
2878
2879 * c-attribs.c (handle_symver_attribute): New function
2880 (c_common_attributes): Add symver.
2881
65ef05d0
RS
28822019-11-30 Richard Sandiford <richard.sandiford@arm.com>
2883
2884 * c-common.c (pointer_int_sum): Use verify_type_context to check
2885 whether the target allows pointer arithmetic for the types involved.
2886 (c_sizeof_or_alignof_type, c_alignof_expr): Use verify_type_context
2887 to check whether the target allows sizeof and alignof operations
2888 for the types involved.
2889
1a291106
JM
28902019-11-27 Jason Merrill <jason@redhat.com>
2891
2892 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
2893
05d6cb1a
JJ
28942019-11-26 Jakub Jelinek <jakub@redhat.com>
2895
2896 PR c++/61414
2897 * c-attribs.c (handle_mode_attribute): Add mode attribute to
2898 ENUMERAL_TYPEs.
2899
5b8d9367
JM
29002019-11-25 Joseph Myers <joseph@codesourcery.com>
2901
2902 PR c/91985
2903 * c-common.c (c_common_type_for_mode): Handle decimal
2904 floating-point types being NULL_TREE.
2905 * c-format.c (get_format_for_type_1): Handle specified types being
2906 NULL_TREE.
2907 * c-lex.c (interpret_float): Give an error for decimal
2908 floating-point constants when decimal floating-point not
2909 supported.
2910
1fbf51cb
JJ
29112019-11-23 Jakub Jelinek <jakub@redhat.com>
2912
2913 PR middle-end/83859
2914 * c-attribs.c (append_access_attrs): Avoid buffer overflow. Avoid
2915 memory leak. Use XNEWVEC macro. Use auto_diagnostic_group to
2916 group warning with inform together.
2917 (handle_access_attribute): Formatting fix.
2918
761df906
JJ
29192019-11-22 Jakub Jelinek <jakub@redhat.com>
2920
bdaf8be1
JJ
2921 PR c/90677
2922 * c-common.h (identifier_global_tag): Declare.
2923 * c-format.c (get_pointer_to_named_type): Renamed to ...
2924 (get_named_type): ... this. Use identifier_global_tag instead of
2925 identifier_global_value, handle the return value being a TYPE_P.
2926 (init_dynamic_diag_info): Adjust get_pointer_to_named_type callers
2927 to call get_named_type instead. Formatting fixes.
2928
c2ecce6d 2929 Implement P1902R1, Missing feature-test macros 2017-2019.
761df906
JJ
2930 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_init_captures
2931 and __cpp_generic_lambdas for -std=c++2a. Define
2932 __cpp_designated_initializers, __cpp_constexpr_in_decltype and
2933 __cpp_consteval for -std=c++2a. Remove a FIXME comment about
2934 __cpp_concepts for -std=c++2a.
2935
54aa6b58
MS
29362019-11-22 Martin Sebor <msebor@redhat.com>
2937
2938 PR middle-end/83859
2939 * c-attribs.c (handle_access_attribute): New function.
2940 (c_common_attribute_table): Add new attribute.
2941 (get_argument_type): New function.
2942 (append_access_attrs): New function.
2943 (get_nonnull_operand): Rename...
2944 (get_attribute_operand): ...to this.
2945 * c-common.c (get_nonnull_operand): Rename...
2946 (get_attribute_operand): ...to this.
2947
6c80b1b5
JM
29482019-11-21 Joseph Myers <joseph@codesourcery.com>
2949
2950 * c-attribs.c (handle_fallthrough_attribute): Use pedwarn instead
2951 of warning.
2952
192961ff
JM
29532019-11-19 Joseph Myers <joseph@codesourcery.com>
2954
2955 * c-common.c (attribute_fallthrough_p): In C, use pedwarn not
2956 warning for standard attributes mixed with fallthrough attributes.
2957
f8aea5e3
JM
29582019-11-15 Joseph Myers <joseph@codesourcery.com>
2959
2960 * c-attribs.c (handle_fallthrough_attribute): Remove static.
2961 * c-common.h (handle_fallthrough_attribute): Declare.
2962
2cc94aa8
JM
29632019-11-15 Joseph Myers <joseph@codesourcery.com>
2964
2965 * c-attribs.c (handle_deprecated_attribute): Remove static.
2966 * c-common.h (handle_deprecated_attribute): Declare.
2967
7c5890cc
JM
29682019-11-14 Joseph Myers <joseph@codesourcery.com>
2969
2970 * c-lex.c (lex_charconst): Make CPP_UTF8CHAR constants unsigned
2971 char for C.
2972
b2417b59
JJ
29732019-11-14 Jakub Jelinek <jakub@redhat.com>
2974
d0ec7c93
JJ
2975 * c-omp.c (c_omp_check_context_selector): Add nvidia to the list of
2976 valid vendors.
2977
b2417b59
JJ
2978 * c-omp.c (c_omp_check_context_selector): Handle name lists
2979 containing string literals. Don't diagnose atomic_default_mem_order
2980 with multiple props.
2981
00be2a5f
JM
29822019-11-13 Joseph Myers <joseph@codesourcery.com>
2983
2984 * c-cppbuiltin.c (builtin_define_float_constants): Also define
2985 NORM_MAX constants. Update call to get_max_float.
2986 (LAZY_HEX_FP_VALUES_CNT): Update value to include NORM_MAX
2987 constants.
2988
2dbad62d
EB
29892019-11-13 Eric Botcazou <ebotcazou@adacore.com>
2990
2991 * c-ada-spec.c (get_underlying_decl): Do not look through typedefs.
2992 (dump_forward_type): Do not generate a declaration for function types.
2993 (dump_nested_type) <ARRAY_TYPE>: Do not generate a nested declaration
2994 of the component type if it is declared in another file.
2995
6ed76044
ML
29962019-11-12 Martin Liska <mliska@suse.cz>
2997
2998 * c-opts.c (c_common_post_options):
2999 Use SET_OPTION_IF_UNSET.
3000
62aee289
MR
30012019-11-12 Maciej W. Rozycki <macro@codesourcery.com>
3002 Frederik Harwath <frederik@codesourcery.com>
3003
3004 gcc/c-family/
3005 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_SERIAL enumeration
3006 constant.
3007 * c-pragma.c (oacc_pragmas): Add "serial" entry.
3008
f486280c
RS
30092019-11-08 Richard Sandiford <richard.sandiford@arm.com>
3010
3011 * c-common.h (gnu_vector_type_p): New function.
3012 * c-common.c (c_build_vec_perm_expr): Require __builtin_shuffle
3013 vectors to satisfy gnu_vector_type_p.
3014 (c_build_vec_convert): Likewise __builtin_convertvector.
3015 (convert_vector_to_array_for_subscript): Likewise when applying
3016 implicit vector to array conversion.
3017 (scalar_to_vector): Likewise when converting vector-scalar
3018 operations to vector-vector operations.
3019
017c6491
JM
30202019-11-08 Joseph Myers <joseph@codesourcery.com>
3021
3022 * c.opt (Wold-style-definition): Initialize to -1.
3023 * c-opts.c (c_common_post_options): Set warn_old_style_definition
3024 to flag_isoc2x if not set explicitly.
3025
c01bd174
JM
30262019-11-07 Joseph Myers <joseph@codesourcery.com>
3027
3028 * c-attribs.c (parse_tm_stmt_attr): Handle scoped attributes.
3029
0df65305
JM
30302019-11-05 Jason Merrill <jason@redhat.com>
3031
3032 * c-opts.c (c_common_post_options): -fconcepts-ts implies
3033 -fconcepts.
3034
e0c866dd
KK
30352019-11-04 Kamlesh Kumar <kamleshbhalui@gmail.com>
3036
3037 * c-opts.c (c_common_post_options): Update
3038 latest_abi_version.
3039
f968ef9b
JJ
30402019-11-02 Jakub Jelinek <jakub@redhat.com>
3041
d0c464d2
JJ
3042 * c-common.h (c_omp_get_context_selector): Remove.
3043 * c-omp.c (c_omp_get_context_selector): Moved to omp-general.c
3044 and renamed to omp_get_context_selector.
3045
917dd789
JJ
3046 * c-omp.c (c_omp_mark_declare_variant): Use
3047 omp_context_selector_set_compare.
3048
f968ef9b
JJ
3049 PR c++/88335 - Implement P1073R3: Immediate functions
3050 * c-common.h (enum rid): Add RID_CONSTEVAL.
3051 * c-common.c (c_common_reswords): Add consteval.
3052
5f6705b7
JJ
30532019-11-01 Martin Sebor <msebor@redhat.com>
3054
3055 PR middle-end/91679
3056 PR middle-end/91647
3057 PR middle-end/91463
3058 PR middle-end/92312
3059 * c-pretty-print.c (direct_abstract_declarator): Print
3060 bound in zero-length arrays.
3061 * c.opt (-Wzero-length-bounds): New option.
3062
43f1814c
NS
30632019-10-30 Nathan Sidwell <nathan@acm.org>
3064
3065 * c-cppbuiltin.c (c_cpp_builtins): Add 'L' suffix to feature
3066 macros.
3067
ad1539d5
MS
30682019-10-28 Martin Sebor <msebor@redhat.com>
3069
3070 PR c/66970
3071 * c-common.c (c_common_nodes_and_builtins): Call c_define_builtins
3072 even when only preprocessing.
3073 * c-common.h (names_builtin_p): Declare new function.
3074 * c-lex.c (init_c_lex): Set has_builtin.
3075 (c_common_has_builtin): Define a new function.
3076 * c-ppoutput.c (init_pp_output): Set has_builtin.
3077
135df52c
JJ
30782019-10-24 Jakub Jelinek <jakub@redhat.com>
3079
3080 * c-common.h (c_omp_context_selector_matches): Remove.
3081 * c-omp.c (c_omp_context_selector_matches): Remove.
3082 * c-attribs.c (c_common_attribute_table): Add
3083 "omp declare target {host,nohost,block}" attributes.
3084
8ad0c477
JM
30852019-10-17 JeanHeyd Meneide <phdofthehouse@gmail.com>
3086
3087 * c-lex.c (c_common_has_attribute): Update nodiscard value.
3088
56898e43
RS
30892019-10-14 Richard Sandiford <richard.sandiford@arm.com>
3090
3091 * c-common.h (user_facing_original_type_p): Declare.
3092 * c-common.c: Include c-spellcheck.h.
3093 (user_facing_original_type_p): New function.
3094
20de9568
JJ
30952019-10-12 Jakub Jelinek <jakub@redhat.com>
3096
3097 * c-common.h (c_omp_mark_declare_variant,
3098 c_omp_context_selector_matches): Declare.
3099 * c-omp.c: Include attribs.h, gimplify.h, cgraph.h, symbol-summary.h
3100 and hsa-common.h.
3101 (c_omp_get_context_selector): Support second argument NULL.
3102 (c_omp_mark_declare_variant, c_omp_context_selector_matches): New
3103 functions.
3104 * c-attribs.c (c_common_attribute_table): Remove "omp declare variant"
3105 attribute, add "omp declare variant base" and
3106 "omp declare variant variant" attributes.
3107
175a85b2
JM
31082019-10-11 Joseph Myers <joseph@codesourcery.com>
3109
3110 * c.opt (Wc11-c2x-compat): Add CPP(cpp_warn_c11_c2x_compat)
3111 CppReason(CPP_W_C11_C2X_COMPAT).
3112
fe2bc27c
JM
31132019-10-11 Joseph Myers <joseph@codesourcery.com>
3114
3115 * c-common.c (c_common_reswords): Do not use D_EXT for _Decimal32,
3116 _Decimal64 and _Decimal128.
3117
27dfdc0f
JM
31182019-10-10 Joseph Myers <joseph@codesourcery.com>
3119
3120 * c-cppbuiltin.c (c_cpp_builtins): Do not define macros for DFP
3121 types if DFP not supported.
3122
94e7f906
JJ
31232019-10-10 Jakub Jelinek <jakub@redhat.com>
3124
3125 * c-common.h (c_omp_check_context_selector,
3126 c_omp_get_context_selector): Declare.
3127 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): Fix spelling
3128 in diagnostic message.
3129 (c_omp_check_context_selector, c_omp_get_context_selector): New
3130 functions.
3131 * c-attribs.c (c_common_attribute_table): Add "omp declare variant"
3132 attribute.
3133 (handle_omp_declare_variant_attribute): New function.
3134
a7160771
MS
31352019-10-09 Martin Sebor <msebor@redhat.com>
3136
3137 PR tree-optimization/90879
3138 * c.opt (-Wstring-compare): New option.
3139
cb57504a
JM
31402019-10-08 Andrew Sutton <asutton@lock3software.com>
3141 Jason Merrill <jason@redhat.com>
3142
3143 Update the concepts implementation to conform to the C++20
3144 specification, improve compile times, and generally clean up
3145 the implementation.
3146
3147 * c-cppbuiltin.c (c_cpp_builtins): Use new feature test values for
3148 concepts when -std=c++2a. Bump __cpp_concepts to 201907.
3149 * c.opt: Add -Wconcepts-ts.
3150 * c-opts.c (c_common_post_options): Warn when -fconcepts is used
3151 with -std=c++2a. Disable warning for -fconcepts in C++20 mode.
3152 (set_std_cxx2a): Enable concepts by default.
3153
fbb2a6dc
JM
31542019-10-08 Joseph Myers <joseph@codesourcery.com>
3155
3156 * c-opts.c (c_common_post_options): Set
3157 -fno-fp-int-builtin-inexact for C2X.
3158
8e007055
JJ
31592019-10-05 Jakub Jelinek <jakub@redhat.com>
3160
3161 PR c++/91369 - Implement P0784R7: constexpr new
3162 * c-cppbuiltin.c (c_cpp_builtins): Predefine
3163 __cpp_constexpr_dynamic_alloc=201907 for -std=c++2a.
3164
843f104d
JM
31652019-10-04 Joseph Myers <joseph@codesourcery.com>
3166
3167 PR c/82752
3168 * c-format.c (C_STD_VER): Handle C2x.
3169 (C_STD_NAME): Likewise.
3170 (strftime_flag_specs): Add 'O' modifier with 'p' flag.
3171 (time_char_table): Use separate entry for 'B' and 'b', with 'O'
3172 modifier allowed and 'p' flag.
3173 * c-format.h (enum format_std_version): Add STD_C2X.
3174 (struct format_char_info): Mention 'p' in comment on flags2.
3175
e9c9a142
DM
31762019-10-01 David Malcolm <dmalcolm@redhat.com>
3177
3178 * c-opts.c (c_diagnostic_finalizer): Temporarily clear prefix when
3179 calling diagnostic_show_locus, rather than destroying it afterwards.
3180
7552c36a
JJ
31812019-10-01 Jakub Jelinek <jakub@redhat.com>
3182
3183 PR c++/91925
3184 * c-warn.c (check_alignment_of_packed_member): Ignore FIELD_DECLs
3185 with NULL DECL_FIELD_OFFSET.
3186
8209db25
RS
31872019-10-01 Richard Sandiford <richard.sandiford@arm.com>
3188
3189 * c-pretty-print.c (pp_c_specifier_qualifier_list): If a vector type
3190 has a type name, use it in preference to the __vector syntax.
3191
9343bf99
RS
31922019-09-30 Richard Sandiford <richard.sandiford@arm.com>
3193
3194 * c-pretty-print.c (pp_c_parameter_type_list): Avoid printing
3195 two spaces between a comma and "...".
3196
59bc434a
JJ
31972019-09-27 Jakub Jelinek <jakub@redhat.com>
3198
3199 PR c++/88203
3200 * c-common.h (c_omp_predefined_variable): Declare.
3201 * c-omp.c (c_omp_predefined_variable): New function.
3202 (c_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
3203 for predefined variables.
3204
c6447c20
RS
32052019-09-27 Richard Sandiford <richard.sandiford@arm.com>
3206
3207 * c-common.h (build_function_call_vec): Take the original
3208 function decl as an optional final parameter.
3209 (check_builtin_function_arguments): Take the original function decl.
3210 * c-common.c (check_builtin_function_arguments): Likewise.
3211 Handle all built-in functions, not just BUILT_IN_NORMAL ones.
3212 Use targetm.check_builtin_call to check BUILT_IN_MD functions.
3213
c4438114
JM
32142019-09-15 Jason Merrill <jason@redhat.com>
3215
3216 * c-warn.c (warn_logical_operator): Strip location wrappers. Don't
3217 fold_for_warn in "|| mask" warning.
3218
68a57628
ML
32192019-09-10 Martin Liska <mliska@suse.cz>
3220
3221 * c.opt: Use newly added WarnRemoved.
3222
f48ef52e
ML
32232019-09-09 Martin Liska <mliska@suse.cz>
3224
3225 * c.opt: Update comment of removed
3226 options that are preserved only for backward
3227 compatibility.
3228
67f6e649
ML
32292019-09-06 Martin Liska <mliska@suse.cz>
3230
3231 PR c++/91125
3232 * c-common.c: Remove definition of flag_use_repository.
3233 * c-common.h: Likewise.
3234 * c-opts.c (c_common_handle_option):
3235 Do not handle OPT_frepo option.
3236 * c.opt: Mark the option with Deprecated.
3237
db9d2274
MP
32382019-09-04 Marek Polacek <polacek@redhat.com>
3239
3240 * c.opt (fdeduce-init-list): Ignored.
3241
68e2c199
PK
32422019-09-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
3243
3244 PR c/78736
3245 * c.opt (Wenum-conversion): New option.
3246
7a4418a5
JL
32472019-09-03 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3248
3249 * c-attribs.c (handle_section_attribute): Call the
3250 handle_generic_attribute target hook after performing target
3251 independent processing.
3252 (handle_noinit_attribute): Likewise.
3253
5f76ab15
ILT
32542019-09-03 Ian Lance Taylor <iant@golang.org>
3255
3256 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Always expand
3257 when using -fgo-dump-spec.
3258
ae0d3f6a
ML
32592019-09-02 Martin Liska <mliska@suse.cz>
3260
3261 PR c++/91155
3262 * c-common.c (fname_as_string): Use cxx_printable_name for
3263 __PRETTY_FUNCTION__ same as was used before r265711.
3264
8a902edb
MP
32652019-08-28 Marek Polacek <polacek@redhat.com>
3266
3267 Implement P1152R4: Deprecating some uses of volatile.
3268 PR c++/91361
3269 * c-opts.c (c_common_post_options): Enable -Wvolatile by
3270 default for C++2a, unless -Wno-deprecated.
3271 * c.opt (Wvolatile): New warning.
3272
4742dbe7
MP
32732019-08-28 Marek Polacek <polacek@redhat.com>
3274
3275 PR c++/91360 - Implement C++20 P1143R2: constinit.
3276 * c-common.c (c_common_reswords): Add constinit and __constinit.
3277 (keyword_is_decl_specifier): Handle RID_CONSTINIT.
3278 * c-common.h (enum rid): Add RID_CONSTINIT, RID_FIRST_CXX20, and
3279 RID_LAST_CXX20.
3280 (D_CXX20): Define.
3281 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_constinit.
3282 * c-format.c (cxx_keywords): Add "constinit".
3283 * c.opt (Wc++2a-compat, Wc++20-compat): New options.
3284
6a074892
JJ
32852019-08-27 Jakub Jelinek <jakub@redhat.com>
3286
3287 PR c++/91415
3288 * c-common.c (verify_tree): For LSHIFT_EXPR, RSHIFT_EXPR,
3289 COMPONENT_REF and ARRAY_REF in cxx_dialect >= cxx17 mode handle it
3290 like COMPOUND_EXPR rather than normal expression.
3291
22f8849d
IS
32922019-08-23 Iain Sandoe <iain@sandoe.co.uk>
3293
3294 PR pch/61250
3295 * c-lex.c (c_lex_with_flags): Don't call
3296 c_common_no_more_pch () from here.
3297
df375b03
JJ
32982019-08-23 Jakub Jelinek <jakub@redhat.com>
3299
3300 PR middle-end/91283
3301 * c-common.c (c_ts18661_flt_eval_method): Use flag_excess_precision
3302 instead of flag_excess_precision_cmdline.
3303 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): Likewise.
3304 * c-opts.c (c_common_post_options): Likewise.
3305
14b7950f
MS
33062019-08-22 Martin Sebor <msebor@redhat.com>
3307
3308 PR middle-end/91490
3309 * c-common.c (braced_list_to_string): Add argument and overload.
3310 Handle flexible length arrays and unions.
3311
8bb2ee59
EB
33122019-08-21 Eric Botcazou <ebotcazou@adacore.com>
3313
3314 * c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
3315 function declarations where arguments are missing. Rename variables.
3316
21c1e205
RB
33172019-08-15 Richard Biener <rguenther@suse.de>
3318
3319 * c-common.c (c_stddef_cpp_builtins): When the GIMPLE FE is
3320 enabled, define __SIZETYPE__.
3321
f0033821
CL
33222019-08-14 Christophe Lyon <christophe.lyon@linaro.org>
3323
3324 * c-attribs.c (c_common_attribute_table): Add "noinit" entry. Add
3325 exclusion with "section" attribute.
3326 (attr_noinit_exclusions): New table.
3327 (handle_noinit_attribute): New function.
3328
4d732405
RS
33292019-08-13 Richard Sandiford <richard.sandiford@arm.com>
3330
3331 PR middle-end/91421
3332 * c-common.c (resolve_overloaded_builtin): Use
3333 copy_decl_built_in_function.
3334
51ad8481
MS
33352019-08-13 Martin Sebor <msebor@redhat.com>
3336
3337 PR c/80619
3338 * c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
3339 (asm_fprintf_length_spec): Same.
3340 * c-format.h (format_lengths): Add FMT_LEN_w.
3341
77eb117f
JJ
33422019-08-10 Jakub Jelinek <jakub@redhat.com>
3343
3344 * c-pragma.h (enum pragma_omp_clause): Add
3345 PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
3346
398e3feb
JJ
33472019-08-07 Jakub Jelinek <jakub@redhat.com>
3348
3349 * c-pragma.h (enum pragma_omp_clause): Add
3350 PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. Set PRAGMA_OACC_CLAUSE_USE_DEVICE
3351 equal to PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR instead of being a separate
3352 enumeration value.
3353
ab574db6
MP
33542019-08-05 Marek Polacek <polacek@redhat.com>
3355
3356 PR c++/91338 - Implement P1161R3: Deprecate a[b,c].
3357 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
3358 default for C++2a, unless -Wno-deprecated.
3359 * c.opt (Wcomma-subscript): New warning.
3360
554a530f
JJ
33612019-07-20 Jakub Jelinek <jakub@redhat.com>
3362
3363 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_LOOP.
3364 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_BIND.
3365 * c-pragma.c (omp_pragmas_simd): Add PRAGMA_OMP_LOOP entry.
3366 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_LOOP.
3367 * c-omp.c (c_omp_split_clauses): Add support for 4 new combined
3368 constructs with the loop construct.
3369
1a888209
JJ
33702019-07-13 Jakub Jelinek <jakub@redhat.com>
3371
3372 PR c/91149
3373 * c-omp.c (c_omp_split_clauses): Fix a pasto in
3374 OMP_CLAUSE_REDUCTION_TASK handling.
3375
1fdd6f04
JJ
33762019-07-12 Jakub Jelinek <jakub@redhat.com>
3377
3378 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ORDER.
3379 * c-omp.c (c_omp_split_clauses): Handle splitting of OMP_CLAUSE_ORDER.
3380
99b1c316
MS
33812019-07-09 Martin Sebor <msebor@redhat.com>
3382
3383 PR c++/61339
1fdd6f04 3384 * c-opts.c (handle_deferred_opts): Change class-key of PODs to struct
99b1c316
MS
3385 and others to class.
3386 * c-pretty-print.h: Same.
3387
6c1dae73
MS
33882019-07-09 Martin Sebor <msebor@redhat.com>
3389
3390 PR c++/61339
3391 * c-format.c (check_argument_type): Change class-key from class to
3392 struct and vice versa to match convention and avoid -Wclass-is-pod
3393 and -Wstruct-no-pod.
3394 * c-pretty-print.h: Same.
3395
8ba6ea87
ML
33962019-07-03 Martin Liska <mliska@suse.cz>
3397
3398 * c-common.c (try_to_locate_new_include_insertion_point): Remove
3399 dead assignemts.
3400
83eb9522
JJ
34012019-07-03 Jakub Jelinek <jakub@redhat.com>
3402
3403 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_REDUCTION_INSCAN
3404 clauses on OMP_FOR rather than OMP_PARALLEL when OMP_FOR is combined
3405 with OMP_PARALLEL.
3406
1c6ffbab
QZ
34072019-07-02 qing zhao <qing.zhao@oracle.com>
3408
3409 PR preprocessor/90581
3410 * c-opts.c (c_common_handle_option): Handle -fmax-include-depth.
3411 * c.opt: Add new option -fmax-include-depth.
3412
7ffc7de5
JM
34132019-06-26 Jason Merrill <jason@redhat.com>
3414
3415 PR c++/55442 - memory-hog with highly recursive constexpr.
3416 * c.opt (fconstexpr-loop-limit): New.
3417
361af3e4
JJ
34182019-06-25 Jakub Jelinek <jakub@redhat.com>
3419
3420 PR sanitizer/90954
3421 * c-omp.c (c_finish_omp_atomic): Allow tree_invariant_p in addition
3422 to SAVE_EXPR in first operand of a COMPOUND_EXPR.
3423
ab20d992
JJ
34242019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3425
3426 * c-common.c (c_common_nodes_and_builtins): Define
3427 alternate "__intN__" name for "__intN" types.
3428
f4af4019
JH
34292019-06-24 Jan Hubicka <jh@suse.cz>
3430
3431 * c-common.c (braced_lists_to_strings): Check that
3432 type is array or integer prior checking string flag.
3433
da9e9b57
MB
34342019-06-21 Matthew Beliveau <mbelivea@redhat.com>
3435
3436 PR c++/90875 - added -Wswitch-outside-range option
3437 * c.opt (Wswitch-outside-range): Added new option.
3438 * c-warn.c (c_do_switch_warnings): Use OPT_Wswitch-outside-range.
3439
3f3d6a6f
MP
34402019-06-21 Marek Polacek <polacek@redhat.com>
3441
3442 PR c++/90953 - ICE with -Wmissing-format-attribute.
3443 * c-common.c (check_function_arguments_recurse): Use
3444 get_attribute_name.
3445 (check_missing_format_attribute): Likewise.
3446
1bf32c11
MP
34472019-06-19 Marek Polacek <polacek@redhat.com>
3448
3449 PR c++/60364 - noreturn after first decl not diagnosed.
3450 * c-attribs.c (handle_noreturn_attribute): No longer static.
3451 * c-common.h (handle_noreturn_attribute, attr_noreturn_exclusions):
3452 Declare.
3453 * c-format.c (check_function_format): Use get_attribute_name.
3454
a04c0734
MS
34552019-06-19 Martin Sebor <msebor@redhat.com>
3456
3457 PR translation/90156
3458 * c-format.c (function_format_info::format_type): Adjust type.
3459 (function_format_info::is_raw): New member.
3460 (decode_format_type): Adjust signature. Handle "raw" diag attributes.
3461 (decode_format_attr): Adjust call to decode_format_type.
3462 Avoid a redundant call to convert_format_name_to_system_name.
3463 Avoid abbreviating the word "arguments" in a diagnostic.
3464 (format_warning_substr): New function.
3465 (avoid_dollar_number): Quote dollar sign in a diagnostic.
3466 (finish_dollar_format_checking): Same.
3467 (check_format_info): Same.
3468 (struct baltoks_t): New.
3469 (c_opers, c_keywords, cxx_keywords, badwords, contrs): New arrays.
3470 (maybe_diag_unbalanced_tokens, check_tokens, check_plain): New
3471 functions.
3472 (check_format_info_main): Call check_plain. Use baltoks_t. Call
3473 maybe_diag_unbalanced_tokens.
3474 (handle_format_attribute): Spell out the word "arguments" in
3475 a diagnostic.
3476
d3786ebb
MB
34772019-06-11 Matthew Beliveau <mbelivea@redhat.com>
3478
3479 PR c++/90449 - add -Winaccessible-base option.
3480 * c.opt (Winaccessible-base): New option.
3481
bf38f7e9
JJ
34822019-06-10 Jakub Jelinek <jakub@redhat.com>
3483
3484 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCAN.
3485 * c-pragma.c (omp_pragmas_simd): Add #pragma omp scan.
3486 * c-omp.c (c_omp_split_clauses): Diagnose inscan reductions on
3487 combined/composite constructs where it is not allowed. Copy over
3488 OMP_CLAUSE_REDUCTION_INSCAN.
3489
0ecf545c
MS
34902019-06-05 Martin Sebor <msebor@redhat.com>
3491
3492 * c-attribs.c (handle_mode_attribute): Adjust quoting and hyphenation.
3493 (handle_alias_ifunc_attribute): Same.
3494 (handle_copy_attribute): Same.
3495 (handle_weakref_attribute): Same.
3496 (handle_nonnull_attribute): Same.
3497 * c-warn.c (warn_for_sign_compare): Same.
3498 (warn_for_restrict): Same.
3499 * c.opt: Same.
3500
36b34127
MS
35012019-06-05 Martin Sebor <msebor@redhat.com>
3502
3503 * c-pragma.c (handle_pragma_weak): Adjust quoting in a diagnostic.
3504 * c.opt (-Wformat-diag): Remove a spurious period.
3505
357a352f
JJ
35062019-05-29 Jakub Jelinek <jakub@redhat.com>
3507
3508 PR c/90628
3509 * c-common.c (check_builtin_function_arguments)
3510 <case BUILTIN_*_OVERFLOW>: Diagnose pointer to const qualified integer
3511 as last argument.
3512
2b8235ea
EB
35132019-05-23 Eric Botcazou <ebotcazou@adacore.com>
3514
3515 * c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
3516
6d86ddc4
ML
35172019-05-22 Martin Liska <mliska@suse.cz>
3518
3519 PR lto/90500
3520 * c-attribs.c (handle_copy_attribute): Do not copy
3521 target_clones attribute.
3522
419ba5b9
EB
35232019-05-21 Eric Botcazou <ebotcazou@adacore.com>
3524
3525 * c-ada-spec.h (enum cpp_operation): Add IS_ASSIGNMENT_OPERATOR.
3526 * c-ada-spec.c (print_assignment_operator): New function.
3527 (dump_ada_declaration) <FUNCTION_DECL>: Call it do dump explicit copy
3528 assignment operators declared as methods and filter out the others.
3529
e03436e7
TS
35302019-05-17 Thomas Schwinge <thomas@codesourcery.com>
3531
3532 PR c/89433
3533 * c-attribs.c (c_common_attribute_table): Set min_len to -1 for
3534 "omp declare target".
3535
a9c697b8
MS
35362019-05-16 Martin Sebor <msebor@redhat.com>
3537
ab20d992
JJ
3538 * c-attribs.c (handle_no_sanitize_attribute): Quote identifiers,
3539 keywords, operators, and types in diagnostics.
3540 (handle_scalar_storage_order_attribute): Same.
3541 (handle_mode_attribute): Same.
3542 (handle_visibility_attribute): Same.
3543 (handle_assume_aligned_attribute): Same.
3544 (handle_no_split_stack_attribute): Same.
3545 * c-common.c (shorten_compare): Same.
3546 (c_common_truthvalue_conversion): Same.
3547 (cb_get_source_date_epoch): Same.
3548 * c-lex.c (cb_def_pragma): Quote keywords, operators, and types
3549 in diagnostics.
3550 (interpret_float): Same.
3551 * c-omp.c (c_finish_omp_for): Same.
3552 * c-opts.c (c_common_post_options): Same.
3553 * c-pch.c (c_common_pch_pragma): Same.
3554 * c-pragma.c (pop_alignment): Same.
3555 (handle_pragma_pack): Same.
3556 (apply_pragma_weak): Same.
3557 (handle_pragma_weak): Same.
3558 (handle_pragma_scalar_storage_order): Same.
3559 (handle_pragma_redefine_extname): Same.
3560 (add_to_renaming_pragma_list): Same.
3561 (maybe_apply_renaming_pragma): Same.
3562 (push_visibility): Same.
3563 (handle_pragma_visibility): Same.
3564 (handle_pragma_optimize): Same.
3565 (handle_pragma_message): Same.
3566 * c-warn.c (warn_for_omitted_condop): Same.
3567 (lvalue_error): Same.
a9c697b8 3568
6b943512
RB
35692019-05-15 Richard Biener <rguenther@suse.de>
3570
3571 PR c/90474
3572 * c-common.c (c_common_mark_addressable_vec): Also mark
3573 a COMPOUND_LITERAL_EXPR_DECL addressable similar to
3574 c_mark_addressable.
ab20d992 3575
b744fc85
NS
35762019-05-06 Nathan Sidwell <nathan@acm.org>
3577
3578 * c-opts.c (handle_defered_opts): Rename struct deps to struc mkdeps.
3579
598f50d7
NS
35802019-04-30 Nathan Sidwell <nathan@acm.org>
3581
3582 * c-common.c (c_common_init_ts): Use MARK_TS_EXP. Mark SIZEOF_EXPR.
3583
5bcc5a3b
ML
35842019-04-30 Martin Liska <mliska@suse.cz>
3585
3586 * c-pragma.c (handle_pragma_diagnostic): Provide hints
3587 for unknown options.
3588
e78a87f7
RS
35892019-04-26 Richard Sandiford <richard.sandiford@arm.com>
3590
3591 * c-warn.c (strict_aliasing_warning): Apply COMPLETE_TYPE_P to
3592 the pointer target rather than the pointer itself.
3593
c280b7ee
JJ
35942019-04-19 Jakub Jelinek <jakub@redhat.com>
3595
3596 PR c/89888
3597 * c-common.h (c_add_case_label): Remove orig_type and outside_range_p
3598 arguments.
3599 (c_do_switch_warnings): Remove outside_range_p argument.
3600 * c-common.c (check_case_bounds): Removed.
3601 (c_add_case_label): Remove orig_type and outside_range_p arguments.
3602 Don't call check_case_bounds. Fold low_value as well as high_value.
3603 * c-warn.c (c_do_switch_warnings): Remove outside_range_p argument.
3604 Check for case labels outside of range of original type here and
3605 adjust them.
3606
8e8225e6
JJ
36072019-04-12 Jakub Jelinek <jakub@redhat.com>
3608
63b8a166
JJ
3609 PR translation/90041
3610 * c.opt (-fhandle-exceptions): Use %< and %> around option names
3611 in the Warn diagnostics.
3612
8e8225e6
JJ
3613 PR c/89946
3614 * c-attribs.c (handle_patchable_function_entry_attribute): Add
3615 function comment. Warn if arguments of the attribute are not positive
3616 integer constants.
3617
53a3f614
EB
36182019-04-09 Eric Botcazou <ebotcazou@adacore.com>
3619
3620 * c-ada-spec.c (print_destructor): Deal with deleting destructors.
3621 (dump_ada_declaration) <FUNCTION_DECL>: Likewise.
3622
22be5873
EB
36232019-04-07 Eric Botcazou <ebotcazou@adacore.com>
3624
3625 * c-ada-spec.c (is_float128): New predicate extracted from...
3626 (dump_ada_node) <COMPLEX_TYPE>: Use it to recognize __cfloat128.
3627 <REAL_TYPE>: ...here. Call it.
3628
34facf20
DM
36292019-04-05 David Malcolm <dmalcolm@redhat.com>
3630
3631 PR c/89985
3632 * c-warn.c (check_address_or_pointer_of_packed_member): Add
3633 auto_diagnostic_group. Guard inform calls by result of
3634 warning_at call.
3635
05564120
MP
36362019-04-05 Marek Polacek <polacek@redhat.com>
3637
ab20d992 3638 PR c++/89973 - -Waddress-of-packed-member ICE with invalid conversion.
05564120
MP
3639 * c-warn.c (check_address_or_pointer_of_packed_member): Check the type
3640 of RHS.
3641
7a506c3c
JM
36422019-04-03 Jason Merrill <jason@redhat.com>
3643
3644 PR c++/86586 - -fcompare-debug=-Wsign-compare.
3645 * c-warn.c (warn_for_sign_compare): Call fold_for_warn.
3646
ddeae8c8
MS
36472019-04-01 Martin Sebor <msebor@redhat.com>
3648
3649 PR c/89685
3650 * c-attribs.c (handle_copy_attribute): Handle references and
3651 non-constant expressions.
3652
a15ffa22
JJ
36532019-03-22 Jakub Jelinek <jakub@redhat.com>
3654
3655 PR c++/87481
3656 * c.opt (-fconstexpr-ops-limit=): New option.
3657
36a3a7a3
JJ
36582019-03-21 Jakub Jelinek <jakub@redhat.com>
3659
3660 * c-common.c (per_file_includes_t): Use false as Lazy in hash_set
3661 template param.
3662
bec1da64
MS
36632019-03-19 Martin Sebor <msebor@redhat.com>
3664
3665 PR tree-optimization/89688
3666 * c-common.c (braced_list_to_string): Make static.
3667 (braced_lists_to_strings): Define new function.
3668 * c-common.h (braced_list_to_string): Remove.
3669 (braced_lists_to_strings): Declare.
3670
1fe61adf
ML
36712019-03-12 Martin Liska <mliska@suse.cz>
3672
3673 * c-opts.c (c_common_handle_option): Wrap option with %< and %>.
3674
93964ebd
ML
36752019-03-11 Martin Liska <mliska@suse.cz>
3676
3677 * c-opts.c (c_common_post_options): Wrap apostrophes
3678 in gcc internal format with %'.
3679
a3f9f006
ML
36802019-03-11 Martin Liska <mliska@suse.cz>
3681
3682 * c-attribs.c (handle_nocf_check_attribute): Wrap an option name
3683 in a string format message and fix GNU coding style.
3684 * c-common.c (vector_types_convertible_p): Likewise.
3685 (c_build_vec_perm_expr): Likewise.
3686 * c-indentation.c (get_visual_column): Likewise.
3687 * c-opts.c (c_common_handle_option): Likewise.
3688 (c_common_post_options): Likewise.
3689 (sanitize_cpp_opts): Likewise.
3690 * c-pch.c (c_common_pch_pragma): Likewise.
3691 * c-pragma.c (handle_pragma_pack): Likewise.
3692
1db01ff9
JJ
36932019-03-08 Jakub Jelinek <jakub@redhat.com>
3694
3695 PR tree-optimization/89550
3696 * c-common.c (c_common_truthvalue_conversion): Only set
3697 TREE_NO_WARNING if warning_at returned true.
3698 * c-warn.c (overflow_warning, warn_logical_operator): Likewise.
3699
ba790e6f
JJ
37002019-02-25 Sandra Loosemore <sandra@codesourcery.com>
3701 Martin Sebor <msebor@gmail.com>
3702
3703 * c.opt (Wmissing-attributes): Clean up doc string.
3704
7da73ba7
JJ
37052019-02-25 Jakub Jelinek <jakub@redhat.com>
3706
3707 PR c/89495
3708 * c-format.c (maybe_read_dollar_number): Compute nargnum in
3709 HOST_WIDE_INT type to avoid overflows and change overflow_flag
3710 checking.
3711
921bb9d1
RB
37122019-02-22 Richard Biener <rguenther@suse.de>
3713
3714 * c-pch.c (no_checksum): Remove.
3715 (pch_init): Remove assertion that executable_checksum is not
3716 all zero.
3717 (c_common_valid_pch): Likewise.
3718
e2ebb05c
MS
37192019-02-18 Martin Sebor <msebor@redhat.com>
3720
3721 PR middle-end/89294
3722 * c-common.c (invalid_array_size_error): Handle cst_size_not_constant.
3723
3fe53000
DM
37242019-02-16 David Malcolm <dmalcolm@redhat.com>
3725
3726 PR c++/88680
3727 * c-common.c (shorten_compare): Call fold_for_warn on op0 when
3728 implementing -Wtype-limits.
3729
28a8cef1
MS
37302019-02-11 Martin Sebor <msebor@redhat.com>
3731
3732 PR c++/87996
3733 * c-common.c (invalid_array_size_error): New function.
3734 (valid_array_size_p): Call it. Handle size as well as type.
3735 * c-common.h (valid_constant_size_p): New function.
3736 (enum cst_size_error): New type.
3737
ec2be203
DM
37382019-01-31 David Malcolm <dmalcolm@redhat.com>
3739
3740 PR c/89122
3741 * known-headers.cc (get_stdlib_header_for_name): Add
3742 {FLT|DBL|LDBL}_{MAX|MIN} to "hints" array.
3743
8936f047
JJ
37442019-01-31 Jakub Jelinek <jakub@redhat.com>
3745
3746 PR libstdc++/88170
3747 * c-pretty-print.c (pp_c_enumeration_constant): Print always as
3748 a C cast in pp_c_flag_gnu_v3 mode.
3749
6a335b96
JJ
37502019-01-29 Jakub Jelinek <jakub@redhat.com>
3751
3752 PR c/86125
3753 * c-common.c (c_common_nodes_and_builtins): Build type variants for
3754 builtin_structptr_types types even for C.
3755
2a06eba5
BE
37562019-01-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
3757
3758 * c-warn.c (check_address_or_pointer_of_packed_member): Handle the case
3759 when rhs is of array type correctly. Fix handling of nested structures.
3760 Fix handling of indirect_ref together with nop_expr and/or addr_expr.
3761 (check_and_warn_address_or_pointer_of_packed_member): Fix handling of
3762 type casts within nested compound expressions.
3763
18a23298
JJ
37642019-01-22 Jakub Jelinek <jakub@redhat.com>
3765
3766 PR middle-end/88968
3767 * c-omp.c (c_finish_omp_atomic): For bitfield atomics, update type
3768 variable after using BIT_FIELD_REF.
3769
420183d9
L
37702019-01-18 H.J. Lu <hongjiu.lu@intel.com>
3771
3772 PR c/51628
3773 PR c/88664
3774 * c-common.h (warn_for_address_or_pointer_of_packed_member):
3775 Remove the boolean argument.
3776 * c-warn.c (check_address_of_packed_member): Renamed to ...
3777 (check_address_or_pointer_of_packed_member): This. Also
3778 warn pointer conversion.
3779 (check_and_warn_address_of_packed_member): Renamed to ...
3780 (check_and_warn_address_or_pointer_of_packed_member): This.
3781 Also warn pointer conversion.
3782 (warn_for_address_or_pointer_of_packed_member): Remove the
3783 boolean argument. Don't check pointer conversion here.
3784
99063eee
RS
37852019-01-15 Richard Sandiford <richard.sandiford@arm.com>
3786
3787 PR inline-asm/52813
3788 * c.opt (Wdeprecated): Move documentation and variable to common.opt.
3789
a30d0196
JJ
37902019-01-14 Jakub Jelinek <jakub@redhat.com>
3791
3792 * c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
3793 and __cpp_nontype_template_parameter_auto. Add a comment that
3794 __cpp_template_auto is deprecated.
3795
2d91f79d
TH
37962019-01-14 Tom Honermann <tom@honermann.net>
3797
3798 Implement P0482R5, char8_t: A type for UTF-8 characters and strings
3799 * c-common.c (c_common_reswords): Add char8_t.
3800 (fix_string_type): Use char8_t for the type of u8 string literals.
3801 (c_common_get_alias_set): char8_t doesn't alias.
3802 (c_common_nodes_and_builtins): Define char8_t as a builtin type in
3803 C++.
3804 (c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
3805 (keyword_begins_type_specifier): Add RID_CHAR8.
3806 * c-common.h (rid): Add RID_CHAR8.
3807 (c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
3808 Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
3809 Define char8_type_node and char8_array_type_node.
3810 * c-cppbuiltin.c (cpp_atomic_builtins): Predefine
3811 __GCC_ATOMIC_CHAR8_T_LOCK_FREE.
3812 (c_cpp_builtins): Predefine __cpp_char8_t.
3813 * c-lex.c (lex_string): Use char8_array_type_node as the type of
3814 CPP_UTF8STRING.
3815 (lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
3816 * c-opts.c: If not otherwise specified, enable -fchar8_t when
3817 targeting C++2a.
3818 * c.opt: Add the -fchar8_t command line option.
3819
23db6ced
MS
38202019-01-14 Martin Sebor <msebor@redhat.com>
3821
3822 PR target/88638
3823 * c-attribs.c (positional_argument): Call valid_format_string_type_p
3824 and issue errors if it fails.
3825 * c-common.h (valid_format_string_type_p): Declare.
3826 * c-format.c (valid_stringptr_type_p): Rename...
3827 (valid_format_string_type_p): ...to this and make extern.
3828 (handle_format_arg_attribute): Adjust to new name.
3829 (check_format_string): Same.
3830
234c3818
L
38312019-01-13 H.J. Lu <hongjiu.lu@intel.com>
3832
3833 * c-warn.c (warn_for_address_or_pointer_of_packed_member):
3834 Replace "may may" with "may" in warning message.
3835
d8fcab68
JJ
38362019-01-07 Jakub Jelinek <jakub@redhat.com>
3837
3838 PR c++/85052
3839 * c-common.h (enum rid): Add RID_BUILTIN_CONVERTVECTOR.
3840 (c_build_vec_convert): Declare.
3841 * c-common.c (c_build_vec_convert): New function.
3842
29d24852
MS
38432019-01-04 Martin Sebor <msebor@redhat.com>
3844
3845 PR c/88546
3846 * c-attribs.c (handle_copy_attribute): Avoid copying attribute leaf.
3847 Handle C++ empty throw specification and C11 _Noreturn.
3848 (has_attribute): Also handle C11 _Noreturn.
3849
9069a4c9
MS
38502019-01-04 Martin Sebor <msebor@redhat.com>
3851
3852 PR c/88363
3853 * c-attribs.c (positional_argument): Also accept enumerated types.
3854
a5544970
JJ
38552019-01-01 Jakub Jelinek <jakub@redhat.com>
3856
3857 Update copyright years.
3858
da77eace
L
38592018-12-20 H.J. Lu <hongjiu.lu@intel.com>
3860
3861 PR c/51628
3862 * c-common.h (warn_for_address_or_pointer_of_packed_member): New.
3863 * c-warn.c (check_alignment_of_packed_member): New function.
3864 (check_address_of_packed_member): Likewise.
3865 (check_and_warn_address_of_packed_member): Likewise.
3866 (warn_for_address_or_pointer_of_packed_member): Likewise.
3867 * c.opt: Add -Wno-address-of-packed-member.
3868
573767d4
DM
38692018-12-20 David Malcolm <dmalcolm@redhat.com>
3870
3871 PR c++/87504
3872 * c-warn.c (get_outermost_macro_expansion): New function.
3873 (spelled_the_same_p): Use it to unwind the macro expansions, and
3874 compare the outermost macro in each nested expansion, rather than
3875 the innermost.
3876
a14feb3c
DM
38772018-12-19 David Malcolm <dmalcolm@redhat.com>
3878
3879 PR c++/87504
3880 * c-common.h (warn_tautological_cmp): Convert 1st param from
3881 location_t to const op_location_t &.
3882 * c-warn.c (find_array_ref_with_const_idx_r): Call fold_for_warn
3883 when testing for INTEGER_CST.
3884 (warn_tautological_bitwise_comparison): Convert 1st param from
3885 location_t to const op_location_t &; use it to build a
3886 binary_op_rich_location, and use this.
3887 (spelled_the_same_p): New function.
3888 (warn_tautological_cmp): Convert 1st param from location_t to
3889 const op_location_t &. Warn for macro expansions if
3890 spelled_the_same_p. Use binary_op_rich_location.
3891
dfd7fdca
DM
38922018-12-19 David Malcolm <dmalcolm@redhat.com>
3893
3894 PR c++/43064
3895 PR c++/43486
3896 * c-common.c (unsafe_conversion_p): Fold any location wrapper.
3897 (verify_tree): Handle location wrappers.
3898 (c_common_truthvalue_conversion): Strip any location wrapper.
3899 Handle CONST_DECL.
3900 (fold_offsetof): Strip any location wrapper.
3901 (complete_array_type): Likewise for initial_value.
3902 (convert_vector_to_array_for_subscript): Call fold_for_warn on the
3903 index before checking for INTEGER_CST.
3904 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
3905 print parentheses around location wrappers.
3906 * c-warn.c (warn_logical_operator): Call fold_for_warn on op_right
3907 before checking for INTEGER_CST.
3908 (warn_tautological_bitwise_comparison): Call
3909 tree_strip_any_location_wrapper on lhs, rhs, and bitop's operand
3910 before checking for INTEGER_CST.
3911 (readonly_error): Strip any location wrapper.
3912 (warn_array_subscript_with_type_char): Strip location wrappers
3913 before checking for INTEGER_CST. Use the location of the index if
3914 available.
3915
5c8b3702
JM
39162018-12-06 Jason Merrill <jason@redhat.com>
3917
3918 PR c++/88136 - -Wdeprecated-copy false positives
3919 * c.opt (Wdeprecated-copy-dtor): New.
3920 (Wdeprecated-copy): Move to -Wextra.
3921
673670da
MS
39222018-11-29 Martin Sebor <msebor@redhat.com>
3923
3924 PR c/88172
3925 PR testsuite/88208
3926 * c-attribs.c (common_handle_aligned_attribute): Silently avoid setting
3927 alignments to values less than the target requires.
3928 (has_attribute): For attribute aligned consider both the attribute
3929 and the alignment bits.
3930 * c-common.c (c_init_attributes): Optionally issue a warning for
3931 zero alignment.
3932
04864ec8
MS
39332018-11-28 Martin Sebor <msebor@redhat.com>
3934
3935 PR c/88065
3936 PR c/87297
3937 * c-warn.c (sizeof_pointer_memaccess_warning): Bail if source
3938 or destination is an error.
3939
ace83db0
JJ
39402018-11-28 Jakub Jelinek <jakub@redhat.com>
3941
3942 PR c++/88215
3943 * c-ubsan.c: Include langhooks.h.
3944 (ubsan_instrument_division): Change gcc_assert that main variants
3945 of op0 and op1 types are equal to gcc_checking_assert that the
3946 main variants are compatible types.
3947
da193a27
EB
39482018-11-27 Eric Botcazou <ebotcazou@adacore.com>
3949
3950 * c-ada-spec.c: Include stringpool.h.
3951 (has_static_fields): Return false for incomplete types.
3952 (is_tagged_type): Likewise.
3953 (has_nontrivial_methods): Likewise.
3954 (dump_ada_node) <INTEGER_TYPE>: Deal specifically with __int128.
3955 (struct overloaded_name_hash): New structure.
3956 (struct overloaded_name_hasher): Likewise.
3957 (overloaded_names): New global variable.
3958 (init_overloaded_names): New static function.
3959 (overloaded_name_p): New predicate.
3960 (dump_ada_declaration) <TYPE_DECL>: Tidy up and set TREE_VISITED
3961 on the TYPE_STUB_DECL of the original type of a typedef, if any.
3962 <FUNCTION_DECL>: Bail out for an unsupported overloaded name.
3963 Remove always-true condition and dump forward types.
3964 (dump_ada_specs): Delete overloaded_names.
3965
98f08eb8
MS
39662018-11-20 Martin Sebor <msebor@redhat.com>
3967
3968 * c-attribs.c (type_for_vector_size): New function.
3969 (type_valid_for_vector_size): Same.
3970 (handle_vector_size_attribute): Move code to the functions above
3971 and call them.
3972 (validate_attribute, has_attribute): New functions.
3973 * c-common.h (has_attribute): Declare.
3974 (rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
3975 * c-common.c (c_common_resword): Same.
3976
2674fa47
JM
39772018-11-16 Jason Merrill <jason@redhat.com>
3978
3979 * c-lex.c (c_common_has_attribute): Handle likely/unlikely.
3980 * c-attribs.c (attr_cold_hot_exclusions): Make public.
3981
258b3854
JJ
39822018-11-16 Jakub Jelinek <jakub@redhat.com>
3983
3984 PR middle-end/87854
3985 * c-common.c (fix_string_type): Reject string literals larger than
3986 TYPE_MAX_VALUE (ssizetype) bytes.
3987
1d249509
MS
39882018-11-15 Martin Sebor <msebor@redhat.com>
3989
3990 PR c++/87541
3991 PR c++/87542
3992 * c-attribs.c (positional_argument): New function.
3993 (handle_alloc_size_attribute): Use it and simplify.
3994 (handle_alloc_align_attribute): Same.
3995 (handle_assume_aligned_attribute): Same.
3996 (handle_nonnull_attribute): Same.
3997 * c-common.c (check_function_arguments): Pass fntype to
3998 check_function_format.
3999 * c-common.h (check_function_format): Add an argument.
4000 (PosArgFlags, positional_argument): Declare new type and function.
4001 * c-format.c (decode_format_attr): Add arguments.
4002 (check_format_string, get_constant): Same.
4003 (convert_format_name_to_system_name): Adjust.
4004
478dd60d
DM
40052018-11-15 David Malcolm <dmalcolm@redhat.com>
4006
4007 PR other/19165
4008 * c-opts.c (c_diagnostic_finalizer): Add diagnostic_t param.
4009
8cca0163
JJ
40102018-11-14 Jakub Jelinek <jakub@redhat.com>
4011
8ee09943
JJ
4012 P1236R1 - Signed integers are two's complement
4013 * c-warn.c (maybe_warn_shift_overflow): Don't warn for c++2a.
4014 * c-ubsan.c (ubsan_instrument_shift): Make signed shifts
4015 with in-range second operand well defined for -std=c++2a.
4016
8cca0163
JJ
4017 PR other/88007
4018 * c-common.c (parse_optimize_options): Allocate option string from
4019 opts_obstack rather than as GC memory. Move the allocation after
4020 warning for invalid option.
4021
620e594b
DM
40222018-11-13 David Malcolm <dmalcolm@redhat.com>
4023
4024 * c-common.c (c_get_substring_location): Update for renaming of
4025 get_source_location_for_substring to get_location_within_string.
4026 * c-lex.c: Replace "source_location" with "location_t".
4027 * c-opts.c: Likewise.
4028 * c-ppoutput.c: Likewise.
4029
f9731de3
MS
40302018-11-13 Martin Sebor <msebor@redhat.com>
4031
4032 PR middle-end/81824
4033 * c-attribs.c (handle_copy_attribute): Exclude inlining attributes.
4034 (handle_tls_model_attribute): Improve diagnostics.
4035
e4bd6d5e
JM
40362018-11-12 Jason Merrill <jason@redhat.com>
4037
a6bb6b07
JM
4038 * c-cppbuiltin.c (c_cpp_builtins): Define
4039 __cpp_impl_destroying_delete.
4040
e4bd6d5e
JM
4041 * c-cppbuiltin.c (c_cpp_builtins): Change __cpp_explicit_bool to
4042 __cpp_conditional_explicit.
4043
79a2c428
MS
40442018-11-09 Martin Sebor <msebor@redhat.com>
4045
4046 PR middle-end/81824
4047 * c-attribs.c (handle_copy_attribute): New function.
4048
4c7bd361
MS
40492018-11-09 Martin Sebor <msebor@redhat.com>
4050
4051 PR c/87795
4052 * c-common.c (check_user_alignment): Use MAX_OFILE_ALIGNMENT.
4053
28567c40
JJ
40542018-11-08 Jakub Jelinek <jakub@redhat.com>
4055
4056 * c-common.h (c_finish_omp_taskgroup): Add CLAUSES argument.
4057 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
4058 enum omp_memory_order MEMORY_ORDER.
4059 (c_finish_omp_flush): Add MO argument.
4060 (c_omp_depend_t_p, c_finish_omp_depobj): Declare.
4061 (c_finish_omp_for): Add FINAL_P argument.
4062 * c-omp.c: Include memmodel.h.
4063 (c_finish_omp_taskgroup): Add CLAUSES argument. Set
4064 OMP_TASKGROUP_CLAUSES to it.
4065 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
4066 enum omp_memory_order MEMORY_ORDER. Set OMP_ATOMIC_MEMORY_ORDER
4067 instead of OMP_ATOMIC_SEQ_CST.
4068 (c_omp_depend_t_p, c_finish_omp_depobj): New functions.
4069 (c_finish_omp_flush): Add MO argument, if not MEMMODEL_LAST, emit
4070 __atomic_thread_fence call with the given value.
4071 (check_omp_for_incr_expr): Formatting fixes.
4072 (c_finish_omp_for): Add FINAL_P argument. Allow NE_EXPR
4073 even in OpenMP loops, diagnose if NE_EXPR and incr expression
4074 is not constant expression 1 or -1. Transform NE_EXPR loops
4075 with iterators pointers to VLA into LT_EXPR or GT_EXPR loops.
4076 (c_omp_check_loop_iv_r): Look for orig decl of C++ range for
4077 loops too.
4078 (c_omp_split_clauses): Add support for combined
4079 #pragma omp parallel master and
4080 #pragma omp {,parallel }master taskloop{, simd} constructs.
4081 Handle OMP_CLAUSE_IN_REDUCTION. Handle OMP_CLAUSE_REDUCTION_TASK.
4082 Handle OMP_CLAUSE_NONTEMPORAL. Handle splitting OMP_CLAUSE_IF
4083 also to OMP_SIMD. Copy OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
4084 (c_omp_predetermined_sharing): Don't return
4085 OMP_CLAUSE_DEFAULT_SHARED for const qualified decls.
4086 * c-pragma.c (omp_pragmas): Add PRAGMA_OMP_DEPOBJ and
4087 PRAGMA_OMP_REQUIRES.
4088 * c-pragma.h (enum pragma_kind): Likewise.
4089 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_NONTEMPORAL
4090 and PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
4091
204839e7
DM
40922018-11-08 David Malcolm <dmalcolm@redhat.com>
4093
4094 * c-format.c (gcc_dump_printf_char_table): Add entry for %f.
4095
d8010ee4
DM
40962018-11-08 David Malcolm <dmalcolm@redhat.com>
4097
4098 * c-format.c (local_cgraph_node_ptr_node): New variable.
4099 (gcc_dump_printf_char_table): Add entry for %C.
4100 (get_pointer_to_named_type): New function, taken from the handling
4101 code for "gimple *" from...
4102 (init_dynamic_diag_info): ...here. Add handling for
4103 "cgraph_node *".
4104 * c-format.h (T_CGRAPH_NODE): New.
4105
4be5c72c
JM
41062018-10-19 Jason Merrill <jason@redhat.com>
4107
4108 * c-cppbuiltin.c (c_cpp_builtins): Add
4109 __cpp_nontype_template_parameter_class.
4110
f3f6029d
NS
41112018-10-31 Nathan Sidwell <nathan@acm.org>
4112
ab5324fb
NS
4113 * c-opts.c (c_finish_options): Force command line macro
4114 location. Refactor to avoid repeating main debug hook.
4115 (push_command_line_include): Clarify comment.
4116
f3f6029d
NS
4117 * c-opts.c (c_finish_options): Adjust cpp_force_token_locations call.
4118
91e3ec29
MS
41192018-10-30 Martin Sebor <msebor@redhat.com>
4120
4121 PR middle-end/87041
4122 * c-format.c (check_format_types): Avoid diagnosing null pointer
4123 arguments to printf-family of functions.
4124
b5ff4f5c
MP
41252018-10-30 Marek Polacek <polacek@redhat.com>
4126
4127 Implement P0892R2, explicit(bool).
4128 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
4129
7e2de6df
DM
41302018-10-29 David Malcolm <dmalcolm@redhat.com>
4131
4132 * name-hint.h (name_hint::take_deferred): New member function.
4133
b2bf438c
DM
41342018-10-29 David Malcolm <dmalcolm@redhat.com>
4135
4136 PR c++/56856
4137 * c-common.c (check_function_sentinel): Call fold_for_warn on the
4138 argument.
4139 (check_function_restrict): Rename param "argarray" to
4140 "unfolded_argarray", and make a copy named "argarray", calling
4141 fold_for_warn on each argument.
4142 (check_function_arguments): Add note about responsibility for
4143 folding the arguments.
4144
9f936c86
JM
41452018-10-17 Joseph Myers <joseph@codesourcery.com>
4146
4147 * c-common.c (flag_isoc2x): New variable.
4148 * c-common.h (clk_c): Update comment to reference C2X.
4149 (flag_isoc99, flag_isoc11): Update comments to reference future
4150 standard versions in general.
4151 (flag_isoc2x): Declare.
4152 * c-opts.c (set_std_c2x): New function.
4153 (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
4154 (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
4155 flag_isoc2x to 0.
4156 * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
4157
7a8a92c4
JM
41582018-10-17 Joseph Myers <joseph@codesourcery.com>
4159
4160 * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
4161 (std=iso9899:2018): Document C17 as published in 2018.
4162
4dc003ff
CL
41632018-10-12 Christophe Lyon <christophe.lyon@linaro.org>
4164
4165 PR c++/87364
4166 * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
4167
79371671
WW
41682018-10-11 Will Wray <wjwray@gmail.com>
4169
4170 PR c++/87364
4171 * c-pretty-print.h (pp_c_type_cast): Prototype.
4172 (pp_c_integer_constant): Likewise.
4173 * c-pretty-print.c (pp_c_type_cast): No longer static.
4174 (pp_c_integer_constant): Likewise.
4175 (pp_c_enumeration_constant): Fix loop termination when finding
4176 name of constant. No longer returns a value. Call
4177 pp_c_integer_constant.
4178 (c_pretty_printer::constant): Update for changes to
4179 pp_c_enumeration_constant.
4180
46c62690
JJ
41812018-10-11 Jakub Jelinek <jakub@redhat.com>
4182
4183 * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
4184 for no_unique_address.
4185
c24300ba
DM
41862018-10-09 David Malcolm <dmalcolm@redhat.com>
4187
4188 * c-common.c (c_option_controlling_cpp_error): Rename to...
4189 (c_option_controlling_cpp_diagnostic): ...this, and convert
4190 "reason" from int to enum.
4191 (c_cpp_error): Rename to...
4192 (c_cpp_diagnostic): ...this, converting level and reason to enums.
4193 * c-common.h (c_cpp_error): Rename to...
4194 (c_cpp_diagnostic): ...this, converting level and reason to enums.
4195 * c-opts.c (c_common_init_options): Update for renaming.
4196
8656dafa
RS
41972018-10-08 Richard Sandiford <richard.sandiford@arm.com>
4198
4199 PR c/87286
4200 * c-common.c (vector_types_compatible_elements_p): Use
4201 INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
4202
8cff0652
VK
42032018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
4204
4205 * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
4206 to generate constructor destructor priority warning.
4207 * c.opt (-Wprio-ctor-dtor): New option.
4208
bedf03a2
JM
42092018-10-01 Jason Merrill <jason@redhat.com>
4210
4211 * c-lex.c (c_common_has_attribute): Add no_unique_address.
4212
6cc430c1
EB
42132018-10-01 Eric Botcazou <ebotcazou@adacore.com>
4214
4215 * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
4216 (dump_ada_node): Add const keyword.
4217
87677ac7
ML
42182018-09-25 Martin Liska <mliska@suse.cz>
4219
4220 * c-common.c (c_common_truthvalue_conversion):
4221 Remove Pascal from documentation.
4222
518196cb
EB
42232018-09-21 Eric Botcazou <ebotcazou@adacore.com>
4224
4225 * c-ada-spec.c: Include diagnostic.h.
4226 (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
4227
a599af84
MP
42282018-09-19 Marek Polacek <polacek@redhat.com>
4229
4230 * c.opt (Wclass-conversion): New.
4231
9c4a4b3c
DM
42322018-09-17 David Malcolm <dmalcolm@redhat.com>
4233
4234 * c-format.c (range_label_for_format_type_mismatch::get_text):
4235 Update for new param.
4236
c896ecfe
DM
42372018-09-17 David Malcolm <dmalcolm@redhat.com>
4238
4239 * c-format.c (format_warning_at_char): Update for introduction of
4240 format_string_diagnostic_t.
4241 (format_type_warning): Likewise.
4242
80c6d1f4
MJ
42432018-09-17 Martin Jambor <mjambor@suse.cz>
4244
4245 PR c/63886
4246 * c.opt (Wabsolute-value): New.
4247
6d900107
BE
42482018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
4249
4250 * c-common.c (complete_flexible_array_elts): New helper function.
4251 * c-common.h (complete_flexible_array_elts): Declare.
4252
b5764229
BE
42532018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
4254
4255 * c-common.c (braced_list_to_string): Remove eval parameter.
4256 Add some more checks. Always create zero-terminated STRING_CST.
4257 * c-common.h (braced_list_to_string): Adjust prototype.
4258
85204e23
DM
42592018-08-27 David Malcolm <dmalcolm@redhat.com>
4260
4261 PR 87091
4262 * c-common.c (c_cpp_error): Update for conversion of show_caret_p
4263 to a tri-state.
4264 (maybe_suggest_missing_token_insertion): Likewise.
4265 (maybe_add_include_fixit): Add param "override_location". If set,
4266 and source-printing is enabled, then override the rich_location's
4267 primary location with that of the insertion point for the fix-it
4268 hint, marking it with SHOW_LINES_WITHOUT_RANGE.
4269 * c-common.h (extern void maybe_add_include_fixit): Add bool
4270 param.
4271 * c-format.c (selftest::test_type_mismatch_range_labels): Update
4272 for conversion of show_caret_p to a tri-state.
4273 * c-warn.c (warn_for_restrict): Likewise.
4274 * known-headers.cc
4275 (suggest_missing_header::~suggest_missing_header): Update call to
4276 maybe_add_include_fixit to suggest overriding the location, as it
4277 is for a note.
4278
3d78e008
ML
42792018-08-27 Martin Liska <mliska@suse.cz>
4280
4281 * c-common.c (check_function_restrict): Use new function
92a285c1
ML
4282 fndecl_built_in_p and remove check for FUNCTION_DECL if
4283 possible.
3d78e008
ML
4284 (check_builtin_function_arguments): Likewise.
4285 (reject_gcc_builtin): Likewise.
4286 * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
4287
b5be6d0c
MP
42882018-08-26 Marek Polacek <polacek@redhat.com>
4289
4290 PR c++/87029, Implement -Wredundant-move.
4291 * c.opt (Wredundant-move): New option.
4292
79ca9c35
MP
42932018-08-21 Marek Polacek <polacek@redhat.com>
4294
4295 PR c++/86981, Implement -Wpessimizing-move.
4296 * c.opt (Wpessimizing-move): New option.
4297
097f82ec
DM
42982018-08-20 David Malcolm <dmalcolm@redhat.com>
4299
4300 PR other/84889
4301 * c-attribs.c (common_handle_aligned_attribute): Add
4302 auto_diagnostic_group instance.
4303 * c-indentation.c (warn_for_misleading_indentation): Likewise.
4304 * c-opts.c (c_common_post_options): Likewise.
4305 * c-warn.c (warn_logical_not_parentheses): Likewise.
4306 (warn_duplicated_cond_add_or_warn): Likewise.
4307 (warn_for_multistatement_macros): Likewise.
4308
3fb558b1
NS
43092018-08-20 Nathan Sidwell <nathan@acm.org>
4310
4311 * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
4312 access.
4313
800c0e98
NS
43142018-08-17 Nathan Sidwell <nathan@acm.org>
4315
4316 * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
4317 field.
4318 (laxy_hex_fp_value_count): Make unsigned.
4319 (lazy_hex_fp_value): Provided with macro & lazy number. Directly
4320 manipulate the macro.
4321 (builtin_defin_with_hex_fp_value): Adjust callback name, use
4322 cpp_define_lazily.
4323
6f795a92
DM
43242018-08-17 David Malcolm <dmalcolm@redhat.com>
4325
4326 * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
4327 (gcc_dump_printf_length_specs): New.
4328 (gcc_dump_printf_flag_pairs): New.
4329 (gcc_dump_printf_flag_specs): New.
4330 (gcc_dump_printf_char_table): New.
4331 (format_types_orig): Add entry for "gcc_dump_printf".
4332 (init_dynamic_diag_info): Set up length_char_specs and
4333 conversion_specs for gcc_dump_printf_format_type.
4334 (handle_format_attribute): Handle gcc_dump_printf_format_type.
4335
c5d725c0
NS
43362018-08-17 Nathan Sidwell <nathan@acm.org>
4337
10f04917
NS
4338 * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
4339
c5d725c0
NS
4340 * c-ada-spec.c: Don't #include "cpp-id-data.h"
4341 * c-cppbuiltin.c: Likewise.
4342
c0c12356
ML
43432018-08-17 Martin Liska <mliska@suse.cz>
4344
4345 * c.opt: Remove Warn, Init and Report for options with
92a285c1
ML
4346 Ignore/Deprecated flag. Warning is done automatically for
4347 Deprecated flags.
c0c12356 4348
10fcc142
DM
43492018-08-16 David Malcolm <dmalcolm@redhat.com>
4350
4351 PR c++/70693
4352 * c-common.c (selftest::c_family_tests): Call
4353 selftest::c_indentation_c_tests.
4354 * c-common.h (selftest::c_indentation_c_tests): New decl.
4355 * c-indentation.c: Include "selftest.h".
4356 (next_tab_stop): Add "tab_width" param, rather than accessing
4357 cpp_opts.
4358 (get_visual_column): Likewise. Clarify comment. Bulletproof
4359 against reading past the end of the line.
4360 (get_first_nws_vis_column): Add "tab_width" param.
4361 (detect_intervening_unindent): Likewise.
4362 (should_warn_for_misleading_indentation): Read tab width from
4363 cpp_opts and pass around.
4364 (selftest::test_next_tab_stop): New test.
4365 (selftest::assert_get_visual_column_succeeds): New function.
4366 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
4367 (selftest::assert_get_visual_column_fails): New function.
4368 (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
4369 (selftest::test_get_visual_column): New test.
4370 (selftest::c_indentation_c_tests): New function.
4371
3f6677f4
NS
43722018-08-16 Nathan Sidwell <nathan@acm.org>
4373
4374 * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
4375 (store_ada_macro): Likewise.
4376 * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
4377 * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
4378
96e6ae57
DM
43792018-08-15 David Malcolm <dmalcolm@redhat.com>
4380
4381 * c-format.c: Include "selftest-diagnostic.h" and
4382 "gcc-rich-location.h".
4383 (format_warning_at_char): Pass NULL for new label params of
4384 format_warning_va.
4385 (class indirection_suffix): New class.
4386 (class range_label_for_format_type_mismatch): New class.
4387 (format_type_warning): Move logic for generating "*" suffix to
4388 class indirection_suffix. Create "fmt_label" and "param_label"
4389 to show their types, and pass them to the
4390 format_warning_at_substring calls.
4391 (selftest::test_type_mismatch_range_labels): New test.
4392 (selftest::c_format_c_tests): Call it.
4393
23aa9f7c
MS
43942018-08-13 Martin Sebor <msebor@redhat.com>
4395
4396 PR tree-optimization/71625
4397 * c-common.c (braced_list_to_string): New function.
4398 * c-common.h (braced_list_to_string): Declare it.
4399
f10a9135
NS
44002018-08-08 Nathan Sidwell <nathan@acm.org>
4401
4402 * c-common.c (try_to_locate_new_include_inertion_point): Use
4403 linemap_included_from_linemap.
4404 * c-lex.c (fe_file_change): Use linemap_included_from.
4405 * c-ppoutput.c (pp_file_change): Likewise.
4406
8a45b051
MS
44072018-08-01 Martin Sebor <msebor@redhat.com>
4408
4409 PR tree-optimization/86650
ab20d992 4410 * c-format.c (gcc_tdiag_char_table): Update comment for "%G".
8a45b051
MS
4411 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
4412 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
4413 * c-format.h (T89_G): Update to be "gimple *" rather than
4414 "gcall *".
4415 (local_gcall_ptr_node): Rename...
4416 (local_gimple_ptr_node): ...to this.
4417
e540ccc0
DM
44182018-07-31 David Malcolm <dmalcolm@redhat.com>
4419
4420 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
4421 table entries for gcc_diag_char_table, and the 'Z' entry from
4422 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
4423 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
4424 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
4425 adding missing "Z" for this table. Remove erroneous "G" and "K"
4426 entries.
4427 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
4428 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
4429 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
4430
425fc685
RE
44312018-07-31 Richard Earnshaw <rearnsha@arm.com>
4432
4433 * c-common.c (speculation_safe_resolve_call): New function.
4434 (speculation_safe_resolve_params): New function.
4435 (speculation_safe_resolve_return): New function.
4436 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
4437 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
4438 __HAVE_SPECULATION_SAFE_VALUE.
4439
181463c2
DM
44402018-07-20 David Malcolm <dmalcolm@redhat.com>
4441
4442 * c-common.c (c_cpp_error): Remove redundant "line_table"
4443 parameter from call to rich_location::set_range.
4444 (maybe_suggest_missing_token_insertion): Likewise.
4445
0d7f9065
MS
44462018-07-20 Martin Sebor <msebor@redhat.com>
4447
4448 PR middle-end/82063
ab20d992 4449 * c.opt (-Warray-bounds): Remove redundant -Wall.
0d7f9065 4450
00abf86c
MS
44512018-07-20 Martin Sebor <msebor@redhat.com>
4452
4453 PR middle-end/82063
4454 * c-common.h (c_common_handle_option): Change function argument
4455 to HOST_WIDE_INT.
4456 * c-opts.c (c_common_init_options): Same.
4457 (c_common_handle_option): Same. Remove special handling of
4458 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
4459 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
4460 options to take a HOST_WIDE_INT argument and accept a byte-size
4461 suffix. Initialize.
4462 (-Wvla-larger-than): Same.
4463 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
4464 (-Wno-vla-larger-than): Same.
4465
9b452033
JJ
44662018-07-12 Jakub Jelinek <jakub@redhat.com>
4467
4468 * c-attribs.c (c_common_attribute_table): Add
4469 "omp declare target implicit" attribute.
4470
cd0762f3
RB
44712018-07-12 Richard Biener <rguenther@suse.de>
4472
4473 PR c/86453
4474 * c-attribs.c (handle_packed_attribute): Do not build a variant
4475 type with TYPE_PACKED, instead ignore the attribute if we may
4476 not apply to the original type.
4477
0b27c3ed
JJ
44782018-07-10 Jakub Jelinek <jakub@redhat.com>
4479
4480 PR c++/86443
4481 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
4482 to contain TREE_LIST for both the original class iterator and the
4483 "last" helper var.
4484
e730a0ef
EB
44852018-07-07 Eric Botcazou <ebotcazou@adacore.com>
4486
4487 * c-ada-spec.c (to_ada_name): Remove index parameter.
4488 (pp_ada_tree_identifier): Likewise.
4489 (dump_ada_macros): Adjust call to to_ada_name.
4490 (struct overloaded_name_hash): Delete.
4491 (struct overloaded_name_hasher): Likewise.
4492 (overloaded_names): Likewise.
4493 (compute_overloading_index): Likewise.
4494 (dump_ada_decl_name): Do not call compute_overloading_index and
4495 adjust calls to pp_ada_tree_identifier.
4496 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
4497 (dump_ada_import): Add spc parameter and switch to aspect syntax.
4498 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
4499 (dump_ada_enum_type): Remove type and display_convention parameters.
4500 Adjust calls to pp_ada_tree_identifier.
4501 (dump_ada_node): Likewise and for dump_ada_structure.
4502 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
4503 and tidy up.
4504 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
4505 syntax.
4506 (print_constructor): Adjust call to pp_ada_tree_identifier.
4507 (print_destructor): Likewise.
4508 (dump_ada_declaration): Switch to aspect syntax.
4509 (dump_ada_structure): Likewise and tidy up. Replace display_convention
4510 parameter with nested parameter.
4511 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
4512 (dump_ada_specs): Do not delete overloaded_names table.
4513
8de583fc
PB
45142018-07-06 Peter Bergner <bergner@linux.ibm.com>
4515
4516 PR target/86324
e730a0ef 4517 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
8de583fc
PB
4518 target hook.
4519
09cff37b
NS
45202018-07-05 Nathan Sidwell <nathan@acm.org>
4521
4522 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
4523 NO_IMPLICIT_EXTERN_C.
4524
98086b2b
ML
45252018-06-28 Martin Liska <mliska@suse.cz>
4526
4527 * cppspec.c: Include opt-suggestions.h.
4528
ab20d992
JJ
45292018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
4530 Thomas Schwinge <thomas@codesourcery.com>
829c6349
CLT
4531 Cesar Philippidis <cesar@codesourcery.com>
4532
4533 * c-pragma.h (enum pragma_omp_clause): Add
4534 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
4535 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
4536
f41b7612
JJ
45372018-06-20 Jakub Jelinek <jakub@redhat.com>
4538
4539 PR c++/86210
4540 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
4541 comment.
4542
4252ccd7
MS
45432018-06-18 Martin Sebor <msebor@redhat.com>
4544
4545 PR middle-end/85602
4546 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
4547 nonstring.
4548
e197e64e
KV
45492018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
4550
4551 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
4552
34a7a230
JM
45532018-06-13 Jason Merrill <jason@redhat.com>
4554
5cef3733
JM
4555 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
4556 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
4557 handling.
4558
34a7a230
JM
4559 PR c++/86094 - wrong code with defaulted move ctor.
4560 * c-opts.c (c_common_post_options): Bump the current ABI version to
4561 13. Set warn_abi_version and flag_abi_compat_version to the current
4562 version rather than 0. Fix defaulting flag_abi_compat_version from
4563 warn_abi_version.
4564
bb0f14ae
MS
45652018-06-12 Martin Sebor <msebor@redhat.com>
4566
4567 PR c/85931
4568 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
4569 sizeof source and destination yields the same value.
4570
3713f2e2
ML
45712018-06-12 Martin Liska <mliska@suse.cz>
4572
4573 * c.opt: Make MPX-related options as Deprecated.
4574
4af78ef8
DM
45752018-06-08 David Malcolm <dmalcolm@redhat.com>
4576
4577 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
4578 rather than 0.
4579
31db0fe0
ML
45802018-06-08 Martin Liska <mliska@suse.cz>
4581
4582 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
4583 for MPX (macros, related functions, fields in cgraph_node, ...).
4584 (handle_bnd_legacy): Likewise.
4585 (handle_bnd_instrument): Likewise.
4586 * c.opt: Likewise.
4587
fe16acf2
JJ
45882018-06-06 Jakub Jelinek <jakub@redhat.com>
4589
4590 PR c++/86068
4591 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
4592 __cpp_transactional_memory to 201500 instead of 210500.
4593
4dbdb49b
JM
45942018-06-06 Jason Merrill <jason@redhat.com>
4595
4596 PR c++/85710 - ICE with -Wmemset-elt-size.
4597 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
4598
f8ad043f
JM
45992018-06-01 Jason Merrill <jason@redhat.com>
4600
4601 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
4602 201703.
4603
abc24d93
EB
46042018-06-01 Eric Botcazou <ebotcazou@adacore.com>
4605
4606 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
4607 declaration for a typedef independently of whether the declaration of
4608 the subtype is generated.
4609
d258f4aa
MS
46102018-05-31 Martin Sebor <msebor@redhat.com>
4611
4612 PR c/82063
4613 * c.opt (-Wno-alloc-size-larger-than): New option.
4614
b67b9225
DP
46152018-04-22 David Pagan <dave.pagan@oracle.com>
4616
4617 PR c/55976
4618 * c-opts.c (c_common_post_options): Set default for warn_return_type
ab20d992 4619 for C++/C++ with ObjC extensions only. For C, makes it possible to
b67b9225
DP
4620 differentiate between default (no option), -Wreturn-type, and
4621 -Wno-return-type.
4622
04eb9c55
JM
46232018-05-29 Jason Merrill <jason@redhat.com>
4624
4625 * c.opt (Winit-list-lifetime): New flag.
4626
b0c31bc6
BE
46272018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
4628
4629 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
4630 splay_tree_delete_pointers.
4631
44284983
JJ
46322018-05-26 Jakub Jelinek <jakub@redhat.com>
4633
4634 PR bootstrap/85921
4635 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
4636 noinline variable to workaround broken kernel headers.
4637
b46b715d
JM
46382018-05-18 Jason Merrill <jason@redhat.com>
4639
4640 * c.opt (Wdeprecated-copy): New flag.
4641
40659769
ML
46422018-05-17 Martin Liska <mliska@suse.cz>
4643
4644 * c-warn.c (overflow_warning): Do not use
4645 space in between 'G_' and '('.
4646
403962ea
JM
46472018-05-09 Jason Merrill <jason@redhat.com>
4648
4649 * c-common.c (valid_array_size_p): Add complain parameter.
4650 * c-common.h: ...which defaults to true.
4651
1c9ee609
JJ
46522018-05-11 Jakub Jelinek <jakub@redhat.com>
4653
4654 PR c/85696
4655 * c-omp.c (c_omp_predetermined_sharing): Return
4656 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
4657
19916065
ML
46582018-05-11 Martin Liska <mliska@suse.cz>
4659
92a285c1 4660 PR sanitizer/85556
19916065
ML
4661 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
4662 TREE_LIST values.
4663
79e7b1fe
JJ
46642018-05-10 Jakub Jelinek <jakub@redhat.com>
4665
4666 PR c++/85662
4667 * c-common.h (fold_offsetof_1): Removed.
4668 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
4669 CTX argument defaulted to ERROR_MARK.
4670 * c-common.c (fold_offsetof_1): Renamed to ...
4671 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
4672 argument, convert the pointer constant to TYPE and use size_binop
4673 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
4674 a pointer type. Adjust recursive calls.
4675
86c12f76
EB
46762018-05-10 Eric Botcazou <ebotcazou@adacore.com>
4677
4678 PR c++/85400
4679 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
4680
ee336e84
NS
46812018-05-07 Nathan Sidwell <nathan@acm.org>
4682
4683 * c.opt (ffor-scope): Remove functionality, issue warning.
4684
6c072e21
NS
46852018-05-03 Nathan Sidwell <nathan@acm.org>
4686
4687 * c.opt (ffriend-injection): Remove functionality, issue warning.
4688
2cc7d3a7
DM
46892018-05-01 David Malcolm <dmalcolm@redhat.com>
4690
4691 PR c/84258
4692 * c-format.c (struct format_check_results): Add field
4693 "number_non_char".
4694 (check_format_info): Initialize it, and warn if encountered.
4695 (check_format_arg): Distinguish between wide char and
4696 everything else when detecting arrays of non-char.
4697
7761dfbe
DM
46982018-04-30 David Malcolm <dmalcolm@redhat.com>
4699
4700 * c-format.c (get_corrected_substring): Update for
4701 location_get_source_line returning a char_span. Use a char_span
4702 when handling the prefix of the correction.
4703 * c-indentation.c (get_visual_column): Update for
4704 location_get_source_line returning a char_span.
4705 (get_first_nws_vis_column): Likewise.
4706
62e98ef1
DM
47072018-03-29 David Malcolm <dmalcolm@redhat.com>
4708
4709 PR c++/84269
4710 * known-headers.cc (get_stdlib_header_for_name): Add various names
4711 from <assert.h>, <string.h>, and <memory.h>; add more names from
4712 <stdio.h>.
4713
a7dea617
JJ
47142018-03-27 Jakub Jelinek <jakub@redhat.com>
4715
4716 PR c++/85061
4717 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
4718 get_base_address of the second operand is a VAR_P, rather than the
4719 operand itself, and use gcc_checking_assert instead of gcc_assert.
4720
889a3a30
MP
47212018-03-23 Marek Polacek <polacek@redhat.com>
4722
4723 PR c++/85045
4724 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
4725 <case RDIV_EXPR>: Tweak condition.
4726
452154b9
EB
47272018-03-20 Eric Botcazou <ebotcazou@adacore.com>
4728
4729 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
4730
63ecb626
JJ
47312018-03-16 Jakub Jelinek <jakub@redhat.com>
4732
ce811fc4
JJ
4733 PR c/84909
4734 * c-warn.c (conversion_warning): Replace "to to" with "to" in
4735 diagnostics.
4736
63ecb626
JJ
4737 PR c/84910
4738 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
4739 diagnostics.
4740
a1295eec
RB
47412018-03-16 Richard Biener <rguenther@suse.de>
4742
4743 PR c/84873
4744 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
4745 unshare the possibly folded expression.
4746
919674fb
RB
47472018-03-15 Richard Biener <rguenther@suse.de>
4748
4749 PR c/84873
4750 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
4751
f99309b2
MS
47522018-03-13 Martin Sebor <msebor@redhat.com>
4753
4754 PR tree-optimization/84725
4755 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
4756 with all three narrow character types, including their qualified forms.
4757
e9b9fa4c
MS
47582018-03-12 Martin Sebor <msebor@redhat.com>
4759
4760 PR tree-optimization/83456
ab20d992 4761 * c-common.c (check_function_restrict): Return bool.
e9b9fa4c
MS
4762 Restore checking of bounded built-in functions.
4763 (check_function_arguments): Also return the result
4764 of warn_for_restrict.
ab20d992
JJ
4765 * c-common.c (check_function_restrict): Return bool.
4766 * c-warn.c (warn_for_restrict): Return bool.
e9b9fa4c 4767
0805d020
MP
47682018-03-02 Marek Polacek <polacek@redhat.com>
4769
4770 PR c++/84171
4771 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
4772 is erroneous.
4773
ed2a2f08
TS
47742018-03-02 Thomas Schwinge <thomas@codesourcery.com>
4775
4776 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
4777 function".
4778
90abdde0
MP
47792018-03-01 Marek Polacek <polacek@redhat.com>
4780
4781 PR c++/84639
4782 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
4783 alignment in computation.
4784
c6db43fa
EB
47852018-02-28 Eric Botcazou <ebotcazou@adacore.com>
4786
4787 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
4788 <REAL_TYPE>: Deal specifically with _Float128/__float128.
4789
9e25c7ed
EB
47902018-02-28 Eric Botcazou <ebotcazou@adacore.com>
4791
4792 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
4793 (is_char_array): Take a type instead of a declaration.
4794 (dump_ada_array_type): Likewise.
4795 (is_simple_enum): Minor tweak.
4796 (dump_ada_enum_type): New function extracted from...
4797 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
4798 <INTEGER_TYPE>: Remove unreachable code.
4799 <RECORD_TYPE>: Likewise. Minor tweaks.
4800 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
4801 <ENUMERAL_TYPE>: New case.
4802 <RECORD_TYPE>: Factor out common code.
4803 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
4804 Minor tweaks. Deal with enumeral types.
4805 (dump_ada_structure): Minor tweaks.
4806
09de3550
EB
48072018-02-28 Eric Botcazou <ebotcazou@adacore.com>
4808
4809 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
4810 address for incomplete structures.
4811 (dump_forward_type): Do not bail out for incomplete structures.
4812 (dump_ada_declaration): Do not special-case incomplete structures
4813 for subtypes. Dump them as null records for types.
4814
095d8d4b
EB
48152018-02-28 Eric Botcazou <ebotcazou@adacore.com>
4816
4817 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
4818 (is_char_array): Fix formatting.
4819 (dump_template_types): Likewise.
4820 (dump_generic_ada_node): Rename into...
4821 (dump_ada_node): ...this.
4822 <POINTER_TYPE>: Remove superfluous space. Use generic address for
4823 incomplete structures and not for empty structures. Do not use it
4824 when forward declarations are needed.
4825 (dump_forward_type): New function.
4826 (dump_nested_types): Remove FORWARD parameter. Do not consider
4827 TREE_VISITED and do not generate a forward declaration. Only dump
4828 original nested types for nested declaration.
4829 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
4830 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
4831 <RECORD_TYPE>: Do not consider TREE_VISITED.
4832 (dump_ada_declaration): Use booleans and fix formatting throughout.
4833 <TYPE_DECL>: Skip incomplete structures and not empty structures.
4834 Call dump_forward_type instead of dump_nested_types for a typedef.
4835 Remove superfluous check and adjust call to dump_nested_types.
4836 <POINTER_TYPE>: Call dump_forward_type and fall through.
4837 (dump_ada_struct_decl): Rename into...
4838 (dump_ada_structure): ...this. Do not special-case empty structures.
4839
d4cfd486
MS
48402018-02-27 Martin Sebor <msebor@redhat.com>
4841
4842 PR c++/83871
4843 * c.opt (-Wmissing-attributes): New option.
4844
b22dbd03
ML
48452018-02-21 Martin Liska <mliska@suse.cz>
4846
4847 * c.opt (Wcatch-value=): Add IntegerRange.
4848
883dfe2a
JM
48492018-02-15 Jason Merrill <jason@redhat.com>
4850
4851 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
4852
0444aa9c
NS
48532018-02-09 Nathan Sidwell <nathan@acm.org>
4854
4855 PR c/84293
4856 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
4857 arg.
4858 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
4859 arg. Adjust.
4860
cea71f0a
MS
48612018-02-09 Martin Sebor <msebor@redhat.com>
4862
4863 PR lto/84212
4864 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
4865 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
4866 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
4867 (-Wstrict-overflow, -Wsuggest-attribute): Same.
4868 (-Wuninitialized): Same.
4869
8c8b7be5
EB
48702018-02-09 Eric Botcazou <ebotcazou@adacore.com>
4871
4872 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
4873 keyword for components.
4874
7c30b12a
PC
48752018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
4876
4877 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
4878
eece7fe5
JK
48792018-02-02 Julia Koval <julia.koval@intel.com>
4880
4881 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
4882
7d07a93a
MP
48832018-01-29 Marek Polacek <polacek@redhat.com>
4884
4885 PR c/83966
4886 * c-format.c (check_function_format): Check current_function_decl.
4887
53723269
JJ
48882018-01-27 Jakub Jelinek <jakub@redhat.com>
4889
4890 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
4891 argument.
4892 (LAZY_HEX_FP_VALUES_CNT): Define.
4893 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
4894 values rather than just 12.
4895 (builtin_define_with_hex_fp_value): Likewise.
4896
7365279f
BK
48972018-01-18 Boris Kolpackov <boris@codesynthesis.com>
4898
92a285c1
ML
4899 PR other/70268
4900 * c.opt (-fmacro-prefix-map): New option.
4901 * c-opts.c (c_common_handle_option): Handle it.
4902 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
4903 * c-ppoutput.c (init_pp_output): Likewise.
7365279f 4904
bb9869d5
DM
49052018-01-17 David Malcolm <dmalcolm@redhat.com>
4906
4907 PR c++/83814
4908 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
4909
68dc87c3
EB
49102018-01-10 Eric Botcazou <ebotcazou@adacore.com>
4911
4912 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
4913 Skip 'f' and 'F' characters if it is true.
4914 (store_ada_macro): Minor tweak.
4915 (dump_ada_macros) <CPP_COMMENT>: Likewise.
4916 <CPP_WSTRING>: Likewise.
4917 <CPP_STRING>: Output '&' in the buffer if not the first string.
4918 <CPP_NUMBER>: Adjust calls to dump_number.
4919
9a004410
DM
49202018-01-10 David Malcolm <dmalcolm@redhat.com>
4921
4922 PR c++/43486
4923 * c-common.c: Include "selftest.h".
4924 (get_atomic_generic_size): Perform the test for integral type
4925 before the range test for any integer constant, fixing indentation
4926 of braces. Call fold_for_warn before testing for an INTEGER_CST.
4927 (reject_gcc_builtin): Strip any location wrapper from EXPR.
4928 (selftest::test_fold_for_warn): New function.
4929 (selftest::c_common_c_tests): New function.
4930 (selftest::c_family_tests): Call it, and
4931 selftest::c_pretty_print_c_tests.
4932 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
4933 * c-format.c (check_format_arg): Convert VAR_P check to a
4934 fold_for_warn.
4935 * c-pretty-print.c: Include "selftest.h".
4936 (pp_c_cast_expression): Don't print casts for location wrappers.
4937 (selftest::assert_c_pretty_printer_output): New function.
4938 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
4939 (selftest::test_location_wrappers): New function.
4940 (selftest::c_pretty_print_c_tests): New function.
4941 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
4942
5c0caeb3
RS
49432018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
4944 Alan Hayward <alan.hayward@arm.com>
4945 David Sherwood <david.sherwood@arm.com>
4946
4947 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
4948
73a699ae
RS
49492018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
4950 Alan Hayward <alan.hayward@arm.com>
4951 David Sherwood <david.sherwood@arm.com>
4952
4953 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
4954 as polynomial.
4955
928686b1
RS
49562018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
4957 Alan Hayward <alan.hayward@arm.com>
4958 David Sherwood <david.sherwood@arm.com>
4959
4960 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
4961 (convert_vector_to_array_for_subscript): Handle polynomial
4962 TYPE_VECTOR_SUBPARTS.
4963 (c_common_type_for_mode): Check valid_vector_subparts_p.
4964 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
4965 VECTOR_CST_NELTS.
4966
85ec4feb
JJ
49672018-01-03 Jakub Jelinek <jakub@redhat.com>
4968
4969 Update copyright years.
4970
170a8bd6 49712017-12-22 Mike Stump <mikestump@comcast.net>
92a285c1 4972 Eric Botcazou <ebotcazou@adacore.com>
170a8bd6
EB
4973
4974 * c-pragma.c (init_pragma): Register pragma GCC unroll.
4975 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
4976
ab20d992 49772017-12-22 Alexandre Oliva <aoliva@redhat.com>
18408e96
AO
4978
4979 PR debug/83527
4980 PR debug/83419
4981 * c-semantics.c (only_debug_stmts_after_p): New.
4982 (pop_stmt_list): Clear side effects in debug-only stmt list.
4983 Check for single nondebug stmt followed by debug stmts only.
4984
c12d20d4
AO
49852017-12-21 Alexandre Oliva <aoliva@redhat.com>
4986
4987 PR debug/83419
4988 * c-semantics.c (pop_stmt_list): Propagate side effects from
4989 single nondebug stmt to container list.
4990
01512446
JJ
49912017-12-19 Jakub Jelinek <jakub@redhat.com>
4992
4993 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
4994 conditions with typical order conditions.
4995
82cfbd01
MP
49962017-12-18 Marek Polacek <polacek@redhat.com>
4997
4998 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
4999 not in effect.
5000
99da11ec
MS
50012017-12-17 Martin Sebor <msebor@redhat.com>
5002
5003 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
5004 an error for attribute warn_if_not_aligned.
5005
cc8bea0a
MS
50062017-12-16 Martin Sebor <msebor@redhat.com>
5007
5008 PR tree-optimization/78918
5009 * c-common.c (check_function_restrict): Avoid checking built-ins.
5010 * c.opt (-Wrestrict): Include in -Wall.
5011
4849deb1
JJ
50122017-12-15 Jakub Jelinek <jakub@redhat.com>
5013
5014 * c-attribs.c (c_common_attribute_table,
5015 c_common_format_attribute_table): Swap affects_type_identity
5016 and handler fields, adjust comments.
5017
c65e18d3
BE
50182017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
5019
5020 * c.opt (Wcast-function-type): New warning option.
5021 * c-lex.c (get_fileinfo): Avoid warning.
5022 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
5023
2004617a
QZ
50242017-12-14 Qing Zhao <qing.zhao@oracle.com>
5025
7365279f 5026 PR middle_end/79538
2004617a
QZ
5027 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
5028 Adjust the size of buf1 and buf2, add a new buf to avoid
5029 format-overflow warning.
5030
ab20d992 50312017-12-12 Alexandre Oliva <aoliva@redhat.com>
96a95ac1
AO
5032
5033 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
5034 subsequent statement list.
5035
5d9ae53d
MS
50362017-12-07 Martin Sebor <msebor@redhat.com>
5037
5038 PR c/81544
5039 PR c/81566
5040 * c-attribs.c (attr_aligned_exclusions): New array.
5041 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
5042 (attr_common_exclusions, attr_const_pure_exclusions): Same.
5043 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
5044 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
5045 (attr_warn_unused_result_exclusions): Same.
5046 (handle_hot_attribute, handle_cold_attribute): Simplify.
5047 (handle_const_attribute): Warn on function returning void.
5048 (handle_pure_attribute): Same.
5049 (handle_aligned_attribute): Diagnose conflicting attribute
5050 specifications.
5051 * c-warn.c (diagnose_mismatched_attributes): Simplify.
5052
c79144f8
DM
50532017-12-06 David Malcolm <dmalcolm@redhat.com>
5054
5055 PR c/83236
5056 * c-common.c (selftest::c_family_tests): Call
5057 selftest::c_spellcheck_cc_tests.
5058 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
5059 * c-spellcheck.cc: Include "selftest.h".
5060 (name_reserved_for_implementation_p): New function.
5061 (should_suggest_as_macro_p): New function.
5062 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
5063 should_suggest_as_macro_p and call it.
5064 (selftest::test_name_reserved_for_implementation_p): New function.
5065 (selftest::c_spellcheck_cc_tests): New function.
5066 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
5067
613bc14f
DM
50682017-12-06 David Malcolm <dmalcolm@redhat.com>
5069
5070 * c-spellcheck.cc: New file, taken from macro-handling code in
5071 spellcheck-tree.c.
5072 * c-spellcheck.h: New file, taken from macro-handling code in
5073 spellcheck-tree.h.
5074
e76c7157
JJ
50752017-12-01 Jakub Jelinek <jakub@redhat.com>
5076
5077 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
5078 attribute.
5079 (handle_simd_attribute): Don't check for "cilk simd function"
5080 attribute. Reindent, formatting changes.
5081
b0da4034
JK
50822017-11-30 Julia Koval <julia.koval@intel.com>
5083
5084 * c-common.h (inv_list): Remove.
5085
058f0b9e
JJ
50862017-11-28 Jakub Jelinek <jakub@redhat.com>
5087
5088 PR sanitizer/81275
5089 * c-common.c (c_switch_covers_all_cases_p_1,
5090 c_switch_covers_all_cases_p): New functions.
5091 * c-common.h (c_switch_covers_all_cases_p): Declare.
5092
5e9d6aa4 50932017-11-28 Julia Koval <julia.koval@intel.com>
92a285c1 5094 Sebastian Peryt <sebastian.peryt@intel.com>
5e9d6aa4
JK
5095
5096 * array-notation-common.c: Delete.
5097 * c-cilkplus.c: Ditto.
5098 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
5099 * c-common.def (ARRAY_NOTATION_REF): Remove.
5100 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
5101 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
5102 c_validate_cilk_plus_loop, cilkplus_an_parts,
5103 cilk_ignorable_spawn_rhs_op,
5104 cilk_recognize_spawn): Remove.
5105 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
5106 * c-omp.c: Remove CILK_SIMD check.
5107 * c-pragma.c: Ditto.
5108 * c-pragma.h: Remove CILK related pragmas.
5109 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
5110 ARRAY_NOTATION_REF condition.
5111 (c_pretty_printer::expression): Ditto.
5112 * c.opt (fcilkplus): Remove.
5113 * cilk.c: Delete.
5114
1af4ebf5
MG
51152017-11-21 Marc Glisse <marc.glisse@inria.fr>
5116
5117 * c-pretty-print.c (pp_c_additive_expression,
5118 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
5119
d44ed508
JJ
51202017-11-21 Jakub Jelinek <jakub@redhat.com>
5121
7d2f0f9b
JJ
5122 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
5123
d44ed508
JJ
5124 PR c++/83059
5125 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
5126 instead of tree_to_uhwi, formatting fix.
5127
26edace6
DM
51282017-11-20 David Malcolm <dmalcolm@redhat.com>
5129
5130 PR c/81404
5131 * known-headers.cc: New file, based on material from c/c-decl.c.
5132 (suggest_missing_header): Copied as-is.
5133 (get_stdlib_header_for_name): New, based on get_c_name_hint but
5134 heavily edited to add C++ support. Add some knowledge about
5135 <limits.h>, <stdint.h>, and <wchar.h>.
5136 * known-headers.h: Likewise.
5137
6c7a259b
DM
51382017-11-20 David Malcolm <dmalcolm@redhat.com>
5139
5140 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
5141 (lookup_name_fuzzy): Likewise. Convert return type from
5142 const char * to name_hint. Add location_t param.
5143 * name-hint.h: New header.
5144
f9c59f7e
JJ
51452017-11-19 Jakub Jelinek <jakub@redhat.com>
5146
5147 PR c/66618
5148 PR c/69960
5149 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
5150
1e39313a
JM
51512017-11-16 Joseph Myers <joseph@codesourcery.com>
5152
5153 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
5154 expected publication date of C17.
5155 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
5156
3ca0dc60
JM
51572017-11-15 Joseph Myers <joseph@codesourcery.com>
5158
5159 PR c/81156
5160 * c-common.c (c_common_reswords): Add __builtin_tgmath.
5161 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
5162
025d57f0
MS
51632017-11-10 Martin Sebor <msebor@redhat.com>
5164
5165 PR c/81117
5166 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
5167 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
5168 * c.opt (-Wstringop-truncation): New option.
5169
1b6fa695
ML
51702017-11-06 Martin Liska <mliska@suse.cz>
5171
5172 PR middle-end/82404
5173 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
5174 FE.
5175 * c.opt: Set default value of warn_return_type.
5176
64a5912c
DM
51772017-10-31 David Malcolm <dmalcolm@redhat.com>
5178
5179 * c-common.c (binary_op_error): Update for renaming of
5180 error_at_rich_loc.
5181 (c_parse_error): Likewise.
5182 * c-warn.c (warn_logical_not_parentheses): Likewise for
5183 renaming of inform_at_rich_loc.
5184 (warn_for_restrict): Likewise for renaming of
5185 warning_at_rich_loc_n.
5186
c76dc9c3
JM
51872017-10-30 Joseph Myers <joseph@codesourcery.com>
5188
5189 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
5190 * c-opts.c (set_std_c17): New function.
5191 (c_common_init_options): Use gnu17 as default C version.
5192 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
5193
ee5fd23a
MM
51942017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
5195
5196 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
5197 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
5198 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
5199 __FP_FAST_FMA<N>X.
5200
d1047465
MP
52012017-10-23 Marek Polacek <polacek@redhat.com>
5202
5203 PR c/82681
5204 * c-warn.c (warnings_for_convert_and_check): Fix typos.
5205
9e878cf1
EB
52062017-10-19 Eric Botcazou <ebotcazou@adacore.com>
5207
5208 * c-common.c (check_builtin_function_arguments): Also check arguments
5209 of __builtin_alloca_with_align_and_max.
5210
89b6abbb
DM
52112017-10-17 David Malcolm <dmalcolm@redhat.com>
5212
5213 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
5214 rather than NULL to format_warning_va.
5215 (check_format_types): Likewise when calling format_type_warning.
5216 Remove code to extract source_ranges and source_range * in favor
5217 of just a location_t.
5218 (format_type_warning): Convert source_range * param to a
5219 location_t.
5220
39382c09
JJ
52212017-10-13 Jakub Jelinek <jakub@redhat.com>
5222
5223 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
5224 [LR]SHIFT_EXPR.
5225
62e1c678
DM
52262017-10-12 David Malcolm <dmalcolm@redhat.com>
5227
5228 * c-common.c (enum missing_token_insertion_kind): New enum.
5229 (get_missing_token_insertion_kind): New function.
5230 (maybe_suggest_missing_token_insertion): New function.
5231 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
5232
b90c9338
NS
52332017-10-11 Nathan Sidwell <nathan@acm.org>
5234
5235 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
5236 (c_common_handle_option): Update incpath_kind names.
5237
3a266bcd
ML
52382017-10-11 Martin Liska <mliska@suse.cz>
5239
5240 PR sanitizer/82490
5241 * c-attribs.c (handle_no_sanitize_attribute): Report directly
5242 Wattributes warning.
5243
8e6cdc90
RS
52442017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
5245
5246 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
5247 operating on trees as wide_ints.
5248 * c-common.c (pointer_int_sum): Likewise.
5249 * c-pretty-print.c (pp_c_integer_constant): Likewise.
5250 * c-warn.c (match_case_to_enum_1): Likewise.
5251 (c_do_switch_warnings): Likewise.
5252 (maybe_warn_shift_overflow): Likewise.
5253
802b38c9
JJ
52542017-10-10 Jakub Jelinek <jakub@redhat.com>
5255
5256 PR c/82437
5257 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
5258 instead of wide_int::from.
5259
4e34b338
JJ
52602017-10-06 Jakub Jelinek <jakub@redhat.com>
5261
5262 PR c/82437
5263 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
5264 using to_widest use wide_int with the larger of the two precisions.
5265
4bc4b2b4
BE
52662017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
5267
5268 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
5269 functions.
5270
a1488398
RS
52712017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
5272
5273 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
5274 when combining the original unconverted comparison operands.
5275
01c9fb68
JJ
52762017-09-29 Jakub Jelinek <jakub@redhat.com>
5277
5278 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
5279 attribute.
5280
6e3e8419
EB
52812017-09-29 Eric Botcazou <ebotcazou@adacore.com>
5282
5283 * c-ada-spec.c (to_ada_name): Add index parameter.
5284 (pp_ada_tree_identifier): Likewise.
5285 (dump_ada_macros): Adjust call to to_ada_name.
5286 (struct overloaded_name_hash): New type.
5287 (struct overloaded_name_hasher): Likewise.
5288 (overloaded_names): New hash table.
5289 (compute_overloading_index): New function.
5290 (dump_ada_decl_name): Call it and pass the result to
5291 pp_ada_tree_identifier.
5292 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
5293 (dump_ada_function_declaration): Likewise.
5294 (dump_generic_ada_node): Likewise.
5295 (print_constructor): Likewise.
5296 (print_destructor): Likewise.
5297 (dump_ada_specs): Delete overloaded_names table.
5298
79310774
EB
52992017-09-29 Eric Botcazou <ebotcazou@adacore.com>
5300
5301 * c-ada-spec.c (max_ada_macros): Move around.
5302 (store_ada_macro_index): Likewise.
5303 (source_file): Rename into...
5304 (macro_source_file): ...this.
5305 (count_ada_macro): Move around.
5306 (store_ada_macro): Likewise.
5307 (compare_macro): Likewise.
5308 (print_ada_macros): Merge in...
5309 (dump_ada_macros): ...this.
5310 (source_file_base): Rename into...
5311 (current_source_file): ...this.
5312 (print_comment): Move around.
5313 (dump_ada_nodes): Call dump_ada_declaration directly.
5314 (struct with): Change type of limited field to bool.
5315 (append_withs): Change type of limited_access parameter to bool.
5316 (pp_ada_tree_identifie): Likewise.
5317 (dump_ada_decl_nam): Likewise.
5318 (dump_generic_ada_node): Likewise. Do not print the return type.
5319 (to_ada_name): Change type of space_found parameter to bool.
5320 (dump_ada_function_declaration): Return void and change type of
5321 parameters to bool. Also print the return type for a function.
5322 (print_ada_methods): Rename into...
5323 (dump_ada_methods): ...this.
5324 (print_ada_declaration): Rename into ...
5325 (dump_ada_declaration): ...this. Do not print the return type.
5326 (print_ada_struct_decl): Rename into...
5327 (dump_ada_struct_decl): ...this.
5328
7d386d45
JJ
53292017-09-29 Jakub Jelinek <jakub@redhat.com>
5330
5331 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
5332 rather than DECL_INITIAL.
5333 (common_handle_aligned_attribute): Likewise.
5334
ab20d992 53352017-09-20 Alexandre Oliva <aoliva@redhat.com>
9ed32e27
AO
5336
5337 * c.opt (gen-decls): Add RejectNegative.
5338
026a79f7
AS
53392017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
5340 Jakub Jelinek <jakub@redhat.com>
5341
5342 Add support for -std=c++2a.
5343 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
5344 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
5345 * c-opts.c (set_std_cxx2a): New.
5346 (c_common_handle_option): Set options when -std=c++2a is enabled.
5347 (c_common_post_options): Adjust comments.
5348 (set_std_cxx14, set_std_cxx17): Likewise.
5349
4a8ca690
EB
53502017-09-15 Eric Botcazou <ebotcazou@adacore.com>
5351
5352 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
5353 message for non-uniform endianness and issue a warning in C++.
5354
7b936140
JJ
53552017-09-15 Jakub Jelinek <jakub@redhat.com>
5356
5357 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
5358 (Wc++17-compat): Change from undocumented alias to option.
5359 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
5360 change C++1z to C++17 in description.
5361 (std=c++1z, std=gnu++1z): Change from option to undocumented
5362 deprecated alias.
5363 (std=c++17, std=gnu++17): Change from undocumented alias to option.
5364 Adjust description.
5365 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
5366 * c-opts.c (set_std_cxx1z): Rename to ...
5367 (set_std_cxx17): ... this.
5368 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
5369 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
7365279f 5370 caller.
7b936140
JJ
5371 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
5372 comments.
5373
12263f13
L
53742017-09-12 H.J. Lu <hongjiu.lu@intel.com>
5375
5376 * c-attribs.c (common_handle_aligned_attribute): Don't warn
5377 function alignment if warn_if_not_aligned_p is true.
5378
6836632e
NS
53792017-09-12 Nathan Sidwell <nathan@acm.org>
5380
5381 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
5382 resort_sorted_fields): Move to c/c-decl.c.
5383 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
5384 (struct sorted_fields_type): Move to c/c-lang.h.
5385
019bf9ad
JW
53862017-09-09 Jonathan Wakely <jwakely@redhat.com>
5387
5388 PR c++/81852
5389 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
5390
bc7fe952
MP
53912017-09-04 Marek Polacek <polacek@redhat.com>
5392
5393 PR c/81783
5394 * c-warn.c (warn_tautological_bitwise_comparison): New function.
5395 (warn_tautological_cmp): Call it.
5396
ab20d992 53972017-09-01 Boris Kolpackov <boris@codesynthesis.com>
de7c2c6a
BK
5398
5399 * c-opts.c (c_common_finish): Write dependency information even if
5400 there are errors.
5401
d2e05fcb
JJ
54022017-09-01 Jakub Jelinek <jakub@redhat.com>
5403
5404 PR c/81887
5405 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
5406 (omp_pragmas_simd): ... here.
5407 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
5408 create new clauses list containing just simd clause.
5409
18e2a8b8
RS
54102017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5411 Alan Hayward <alan.hayward@arm.com>
5412 David Sherwood <david.sherwood@arm.com>
5413
5414 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
5415 into scalar_mode_supported_p call.
5416 (handle_mode_attribute): Update call to scalar_mode_supported_p.
5417
16d22000
RS
54182017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5419 Alan Hayward <alan.hayward@arm.com>
5420 David Sherwood <david.sherwood@arm.com>
5421
5422 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
5423 for the mode iterator.
5424
b397965c
RS
54252017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5426 Alan Hayward <alan.hayward@arm.com>
5427 David Sherwood <david.sherwood@arm.com>
5428
5429 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
5430 * c-common.c (c_build_vec_perm_expr): Likewise.
5431
357b7604
RS
54322017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5433 Alan Hayward <alan.hayward@arm.com>
5434 David Sherwood <david.sherwood@arm.com>
5435
5436 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
5437
e05c94ba
RS
54382017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5439 Alan Hayward <alan.hayward@arm.com>
5440 David Sherwood <david.sherwood@arm.com>
5441
5442 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
5443 before calling targetm.addr_space.valid_pointer_mode.
5444
5c20c4af
RS
54452017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5446 Alan Hayward <alan.hayward@arm.com>
5447 David Sherwood <david.sherwood@arm.com>
5448
5449 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
5450
c94843d2 54512017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
92a285c1
ML
5452 Alan Hayward <alan.hayward@arm.com>
5453 David Sherwood <david.sherwood@arm.com>
c94843d2
RS
5454
5455 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
5456 iterators.
5457 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
5458
4e10a5a7
RS
54592017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
5460 Alan Hayward <alan.hayward@arm.com>
5461 David Sherwood <david.sherwood@arm.com>
5462
5463 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
5464 case statements.
5465
130fcab0
ML
54662017-08-29 Martin Liska <mliska@suse.cz>
5467
5468 PR other/39851
5469 * c-common.c (parse_optimize_options): Add argument to function
5470 call.
5471 * c-pragma.c (handle_pragma_diagnostic): Likewise.
5472
14e18d71
DM
54732017-08-24 David Malcolm <dmalcolm@redhat.com>
5474
5475 * c-lex.c (interpret_float): Use token location
5476 when building an EXCESS_PRECISION_EXPR.
5477
2f687306
DM
54782017-08-21 David Malcolm <dmalcolm@redhat.com>
5479
5480 * c-common.c (check_function_arguments): Add "arglogs" param; pass
5481 it to check_function_format.
5482 * c-common.h (check_function_arguments): Add vec<location_t> *
5483 param.
5484 (check_function_format): Likewise.
5485 * c-format.c (struct format_check_context): Add field "arglocs".
5486 (check_function_format): Add param "arglocs"; pass it to
5487 check_format_info.
ab20d992 5488 (check_format_info): Add param "arglocs"; use it to initialize
2f687306
DM
5489 new field of format_ctx.
5490 (check_format_arg): Pass format_ctx->arglocs to new param of
5491 check_format_info_main.
5492 (class argument_parser): New field "arglocs".
5493 (argument_parser::argument_parser): Add "arglocs_" param and use
5494 it to initialize new field.
5495 (argument_parser::check_argument_type): Pass new arglocs field to
5496 check_format_types.
5497 (check_format_info_main): Add param "arglocs", and use it when
5498 constructing arg_parser.
5499 (check_format_types): Add param "arglocs"; use it if non-NULL when
5500 !EXPR_HAS_LOCATION (cur_param) to get at location information.
5501
00aa1fa2
L
55022017-08-18 H.J. Lu <hongjiu.lu@intel.com>
5503
5504 PR c/53037
5505 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
5506 (c_common_attribute_table): Add warn_if_not_aligned.
5507 (handle_aligned_attribute): Renamed to ...
5508 (common_handle_aligned_attribute): Remove argument, name, and add
5509 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
5510 (handle_aligned_attribute): New.
5511 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
5512
27be025d
MS
55132017-08-14 Martin Sebor <msebor@redhat.com>
5514
5515 PR c/81117
5516 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
5517 (handle_nonstring_attribute): New function.
5518
da67acb9
MS
55192017-08-14 Martin Sebor <msebor@redhat.com>
5520
5521 PR c/81117
5522 * c-format.h (T89_G): New macro.
5523 * c-format.c (local_gcall_ptr_node): New variable.
5524 (init_dynamic_diag_info): Initialize it.
5525
a8b522b4
ML
55262017-08-11 Martin Liska <mliska@suse.cz>
5527
5528 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
5529 TARGET_SUPPORTS_ALIASES.
5530
32129a17
DM
55312017-08-10 David Malcolm <dmalcolm@redhat.com>
5532
5533 * c-common.c (c_parse_error): Add rich_location * param, using it
5534 rather implicitly using input_location.
5535 * c-common.h (c_parse_error): Add rich_location * param.
5536
30af3a2b
MP
55372017-08-09 Marek Polacek <polacek@redhat.com>
5538
5539 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
5540 (c_common_truthvalue_conversion): Likewise.
5541 * c-omp.c (c_finish_omp_atomic): Likewise.
5542 * c-common.h (build_binary_op): Update declaration.
5543
314e6352
ML
55442017-08-08 Martin Liska <mliska@suse.cz>
5545
5546 * c-ada-spec.c: Include header files.
5547 * c-ubsan.c: Likewise.
5548 * c-warn.c: Likewise.
5549
56b5041c
JJ
55502017-08-07 Jakub Jelinek <jakub@redhat.com>
5551
5552 PR c/69389
5553 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
5554
db440138
EB
55552017-08-07 Eric Botcazou <ebotcazou@adacore.com>
5556
5557 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
5558 (print_ada_methods): Likewise.
5559 (print_ada_declaration): Likewise.
5560
577eec56
ML
55612017-08-07 Martin Liska <mliska@suse.cz>
5562
5563 * array-notation-common.c: Add new includes.
5564 * c-format.c( handle_format_attribute): Canonicalize a format
5565 function name.
5566 * c-lex.c (c_common_has_attribute): Canonicalize name of an
5567 attribute.
5568 * c-pretty-print.c: Add new include.
5569
b854df3c
EB
55702017-08-05 Eric Botcazou <ebotcazou@adacore.com>
5571
5572 * c-ada-spec.c (has_static_fields): Look only into variables.
5573 (print_constructor): Add TYPE parameter and use it for the name.
5574 (print_destructor): Likewise.
5575 (print_ada_declaration): Adjust to new constructor/destructor names.
5576 Adjust calls to print_constructor and print_destructor.
5577 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
5578 Look only into variables in the final loop.
5579
9f2cb25e
EB
55802017-08-01 Eric Botcazou <ebotcazou@adacore.com>
5581
5582 * c-ada-spec.c (has_static_fields): Look only into fields.
5583 (dump_generic_ada_node): Small tweak.
5584 (dump_nested_types): Look only into fields.
5585 (print_ada_declaration): Look only into methods. Small tweak.
5586 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
5587
f4bcd9eb
EB
55882017-08-01 Eric Botcazou <ebotcazou@adacore.com>
5589
5590 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
5591 (dump_ada_function_declaration): Likewise.
5592 (dump_generic_ada_node): Likewise.
5593 (print_ada_declaration): Add support for const-qualified variables.
5594
f34ebeb2
ML
55952017-07-31 Martin Liska <mliska@suse.cz>
5596
5597 PR sanitize/81530
5598 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
5599 Guard condition with flag_sanitize_p also with current_function_decl
5600 non-null equality.
5601 (ubsan_maybe_instrument_reference_or_call): Likewise.
5602
218e5d04
UB
56032017-07-30 Uros Bizjak <ubizjak@gmail.com>
5604
5605 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
5606
942047f2
EB
56072017-07-29 Eric Botcazou <ebotcazou@adacore.com>
5608
5609 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
5610 for enumeral types.
5611 (print_ada_declaration): Add missing guard for record types.
5612
a40ff0ae
JJ
56132017-07-27 Jakub Jelinek <jakub@redhat.com>
5614
5615 PR c/45784
5616 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
5617 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
5618 new COMPOUND_EXPRs around the rhs of the comparison.
5619
06bd22f6
MP
56202017-07-27 Marek Polacek <polacek@redhat.com>
5621
5622 PR c/81417
5623 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
5624 the types.
5625
036ea399
JJ
56262017-07-27 Jakub Jelinek <jakub@redhat.com>
5627
5628 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
5629 (handle_noipa_attribute): New function.
5630
417ca011
TD
56312017-07-07 Torsten Duwe <duwe@suse.de>
5632
5633 * c-attribs.c (c_common_attribute_table): Add entry for
5634 "patchable_function_entry".
5635
5aaa8fb4
NS
56362017-07-20 Nathan Sidwell <nathan@acm.org>
5637
5638 Remove TYPE_METHODS.
5639 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
5640 dump_ada_template, print_ada_methods,
5641 print_ada_declaration): Member fns are on TYPE_FIELDS.
5642
ff22eb12
NS
56432017-07-18 Nathan Sidwell <nathan@acm.org>
5644
5645 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
5646
eea77d1f
DM
56472017-07-14 David Malcolm <dmalcolm@redhat.com>
5648
5649 * c-common.c (try_to_locate_new_include_insertion_point): New
5650 function.
5651 (per_file_includes_t): New typedef.
5652 (added_includes_t): New typedef.
5653 (added_includes): New variable.
5654 (maybe_add_include_fixit): New function.
5655 * c-common.h (maybe_add_include_fixit): New decl.
5656
281ac396
MS
56572017-07-10 Martin Sebor <msebor@redhat.com>
5658
5659 PR other/81345
5660 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
5661
b6f43128
DM
56622017-07-06 David Malcolm <dmalcolm@redhat.com>
5663
5664 * c-common.c (selftest::c_family_tests): New.
5665 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
5666 (selftest::c_family_tests): New decl.
5667
efbf55b0
MP
56682017-07-04 Marek Polacek <polacek@redhat.com>
5669
5670 PR c/81231
5671 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
5672 types.
5673
6c86bd88
MP
56742017-07-04 Marek Polacek <polacek@redhat.com>
5675
5676 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
5677
17a7218b
ML
56782017-06-28 Martin Liska <mliska@suse.cz>
5679
5680 PR ipa/81128
5681 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
5682 to a function declaration.
5683
63010089
ML
56842017-06-28 Martin Liska <mliska@suse.cz>
5685
5686 PR driver/79659
5687 * c.opt: Add IntegerRange to various options.
5688
3e2becc4
MP
56892017-06-26 Marek Polacek <polacek@redhat.com>
5690
5691 PR c/80116
5692 * c-common.h (warn_for_multistatement_macros): Declare.
5693 * c-warn.c: Include "c-family/c-indentation.h".
5694 (warn_for_multistatement_macros): New function.
5695 * c.opt (Wmultistatement-macros): New option.
5696 * c-indentation.c (guard_tinfo_to_string): No longer static.
5697 Change the parameter type to "enum rid". Handle RID_SWITCH.
5698 * c-indentation.h (guard_tinfo_to_string): Declare.
5699
2db9b7cd
MG
57002017-06-23 Marc Glisse <marc.glisse@inria.fr>
5701
5702 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
5703
c3684b7b
MS
57042017-06-15 Martin Sebor <msebor@redhat.com>
5705
5706 PR c++/80560
5707 * c.opt (-Wclass-memaccess): New option.
5708
e72c4afd
BK
57092017-06-14 Boris Kolpackov <boris@codesynthesis.com>
5710
5711 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
5712
8a516588
MP
57132017-06-13 Marek Polacek <polacek@redhat.com>
5714
5715 PR objc/80949
5716 * c-warn.c (do_warn_duplicated_branches): Return if any of the
5717 branches is null.
5718
45b2222a
ML
57192017-06-13 Martin Liska <mliska@suse.cz>
5720
5721 PR sanitize/78204
5722 * c-attribs.c (add_no_sanitize_value): New function.
5723 (handle_no_sanitize_attribute): Likewise.
5724 (handle_no_sanitize_address_attribute): Use the function.
5725 (handle_no_sanitize_thread_attribute): New function.
5726 (handle_no_address_safety_analysis_attribute): Use
5727 add_no_sanitize_value.
5728 (handle_no_sanitize_undefined_attribute): Likewise.
5729 * c-common.h: Declare new functions.
5730 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
5731 (ubsan_instrument_shift): Likewise.
5732 (ubsan_instrument_bounds): Likewise.
5733 (ubsan_maybe_instrument_array_ref): Likewise.
5734 (ubsan_maybe_instrument_reference_or_call): Likewise.
5735
a01f151f
JM
57362017-06-11 Jason Merrill <jason@redhat.com>
5737
5738 * c-ada-spec.c, c-pragma.c: Use id_equal.
5739
3de4ac6d
MP
57402017-06-04 Marek Polacek <polacek@redhat.com>
5741
5742 PR c/80919
5743 * c-format.c (matching_type_p): Return false if any of the types
5744 requires structural equality.
5745
2474f48f
MS
57462017-06-02 Martin Sebor <msebor@redhat.com>
5747
5748 PR c/80892
5749 * c-warn.c (conversion_warning): Use -Wconversion for integer
5750 conversion and -Wfloat-conversion for floating one.
5751
40ffd95f
BE
57522017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
5753
5754 * c.opt (Wsizeof-pointer-div): New warning option.
5755
3fa4634c
VR
57562017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
5757
5758 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
5759 (Wcatch-value=1): Enable by -Wall.
5760
f012c8ef
DM
57612017-05-30 David Malcolm <dmalcolm@redhat.com>
5762
5763 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
5764 format_chars.
5765 * c.opt (fdiagnostics-show-template-tree): New option.
5766 (felide-type): New option.
5767
63dbcd13
VR
57682017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
5769
5770 * c.opt (Wcatch-value=): New C++ warning flag.
5771
be136b5c
NS
57722017-05-24 Nathan Sidwell <nathan@acm.org>
5773
5774 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
5775 const casts to avoid warning.
5776
3cd211af
MS
57772017-05-24 Martin Sebor <msebor@redhat.com>
5778
5779 PR c/80731
5780 * c-common.h (unsafe_conversion_p): Add a function argument.
5781 * c-common.c (unsafe_conversion_p): Same.
5782 Add type names and values to diagnostics.
5783 (scalar_to_vector): Adjust.
5784 * c-warn.c (constant_expression_error): Add a function argument.
5785 Add type names and values to diagnostics.
5786 (conversion_warning): Add a function argument.
5787 Add type names and values to diagnostics.
5788 (warnings_for_convert_and_check): Same.
5789
1ff7be5a
JM
57902017-05-19 Jason Merrill <jason@redhat.com>
5791
5792 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
5793 enumerators.
5794
ff502317
BE
57952017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
5796
5797 * c-format.c (locus): Move out of function scope,
5798 add GTY attribute.
5799
2a8a8d7b
NS
58002017-05-19 Nathan Sidwell <nathan@acm.org>
5801
5802 * c-opts.c (class_dump_file, class_dump_flags): Delete.
5803 (c_common_parse_file): Remove class dump handling.
5804 (get_dump_info): Likewise.
5805
39aac208
RB
58062017-05-19 Richard Biener <rguenther@suse.de>
5807
5808 PR c++/80593
5809 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
5810 to alias-set zero memory.
5811
6ecd2339
BE
58122017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
5813
5814 * c-format.c (local_tree_type_node): Add GTY attribute.
5815
6574d78e
MP
58162017-05-18 Marek Polacek <polacek@redhat.com>
5817
5818 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
5819 (c_common_fixed_point_type_for_size): Likewise.
5820 (c_common_type_for_mode): Likewise.
5821 (shorten_compare): Likewise.
5822 (c_promoting_integer_type_p): Use false/true instead of 0/1.
5823 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
5824
e3455240
MP
58252017-05-18 Marek Polacek <polacek@redhat.com>
5826
5827 * c-common.c (self_promoting_args_p): Change the return type to bool.
5828 Use false/true instead of 0/1.
5829 * c-common.h (self_promoting_args_p): Update.
5830
3fa8871b
MP
58312017-05-17 Marek Polacek <polacek@redhat.com>
5832
5833 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
5834 * c-warn.c: Likewise.
5835
b42cc3ca
VV
58362017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
5837
5838 Implement new C++ intrinsics __is_assignable and __is_constructible.
5839 * c-common.c (__is_assignable, __is_constructible): New.
5840 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
5841
1a817418
ML
58422017-05-17 Martin Liska <mliska@suse.cz>
5843
5844 * c-common.h: Introduce dump_flags_t type and
5845 use it instead of int type.
5846 * c-gimplify.c (c_genericize): Likewise.
5847 * c-opts.c: Likewise.
5848
b2fa0a8b
MP
58492017-05-17 Marek Polacek <polacek@redhat.com>
5850
5851 * c-common.c (c_save_expr): Remove.
5852 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
5853 * c-common.h (c_save_expr): Remove declaration.
5854
31c2d57d
VR
58552017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
5856
5857 PR c/35441
5858 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
5859 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
5860 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
5861 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
5862 RDIV_EXPR.
5863 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
5864
684f84de
MP
58652017-05-09 Marek Polacek <polacek@redhat.com>
5866
5867 PR c/80525
5868 * c-warn.c (unwrap_c_maybe_const): New.
5869 (warn_logical_operator): Call it.
5870
641da50a
NS
58712017-05-09 Nathan Sidwell <nathan@acm.org>
5872
5873 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
5874 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
5875
631238ac
MS
58762017-05-08 Martin Sebor <msebor@redhat.com>
5877
5878 PR translation/80280
5879 * c-format.h (struct format_flag_spec): Add new member.
5880 (T89_T): New macro.
5881 * c-format.c (local_tree_type_node): New global.
5882 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
5883 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
5884 (strfmon_flag_specs): Likewise.
5885 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
5886 with distinct quoting properties.
5887 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
5888 (flag_chars_t::validate): Add argument and handle bad quoting.
5889 (check_format_info_main): Handle quoting problems.
5890 (init_dynamic_diag_info): Simplify.
5891
49f0c04c
JM
58922017-05-08 Jason Merrill <jason@redhat.com>
5893
5894 * c-opts.c (c_common_post_options): Update defaults for
5895 flag_abi_version and flag_abi_compat_version.
5896
56d35585
DM
58972017-05-05 David Malcolm <dmalcolm@redhat.com>
5898
5899 * c-common.c (c_cpp_error): Replace report_diagnostic
5900 with diagnostic_report_diagnostic.
5901
0f2c4a8f
MS
59022017-05-04 Martin Sebor <msebor@redhat.com>
5903
5904 PR translation/80280
5905 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
5906 (handle_weakref_attribute): Same.
5907
6fe63fb4
NS
59082017-05-03 Nathan Sidwell <nathan@acm.org>
5909
5910 Canonicalize canonical type hashing
5911 * c-common.c (complete_array_type): Use type_hash_canon.
5912
815d9cc6
XR
59132017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
5914
92a285c1 5915 PR c++/80038
815d9cc6
XR
5916 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
5917 prototype.
5918 (cilk_install_body_pedigree_operations): Likewise.
5919 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
5920 detatched.
5921 (cilk_gimplify_call_params_in_spawned_fn): Remove.
5922 (cilk_install_body_pedigree_operations): Likewise.
5923 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
5924 unwrapping.
5925
f8a36447
JJ
59262017-04-27 Jakub Jelinek <jakub@redhat.com>
5927
5928 PR c++/80534
5929 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
5930 flag on non-aggregate element types.
5931
7c145456
BE
59322017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
5933
5934 * c-common.c (c_type_hasher, type_hash_table): Remove.
5935 (c_common_get_alias_set): Remove unreachable code.
5936 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
5937
c3cbcd45
VR
59382017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
5939
5940 * c.opt (Wextra-semi): New C++ warning flag.
5941
8a59d466
JJ
59422017-04-20 Jakub Jelinek <jakub@redhat.com>
5943
5944 PR middle-end/80423
5945 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
5946
8487c9a5
JJ
59472017-04-18 Jakub Jelinek <jakub@redhat.com>
5948
5949 PR middle-end/79788
5950 PR middle-end/80375
5951 * c-common.c (c_common_type_for_mode): Don't handle
5952 widest_*_literal_type_node here.
5953 c_common_signed_or_unsigned_type): Likewise.
5954 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
5955 to *intTI_type_node or *intDI_type_node depending on whether
5956 TImode is supported by the target or not.
5957
3ee0fb02
ML
59582017-04-10 Martin Liska <mliska@suse.cz>
5959
5960 PR sanitizer/80350
5961 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
5962 doing an UBSAN check.
5963
5764ee3c
JW
59642017-04-03 Jonathan Wakely <jwakely@redhat.com>
5965
5966 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
5967
6f3af356
JJ
59682017-03-31 Jakub Jelinek <jakub@redhat.com>
5969
5970 PR c++/79572
5971 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
5972 tree *.
5973 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
5974 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
5975 REFERENCE_TYPE.
5976
f6a7a9d5
DM
59772017-03-31 David Malcolm <dmalcolm@redhat.com>
5978
5979 PR documentation/78732
5980 * c.opt (Wendif-labels): Fix description to refer to
5981 #else rather than #elif.
5982
af88f557
JJ
59832017-03-31 Jakub Jelinek <jakub@redhat.com>
5984
5985 PR libstdc++/80251
5986 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
5987 * c-common.c (c_common_reswords): Add __is_aggregate trait.
5988
a9e4a1a5
JJ
59892017-03-27 Jakub Jelinek <jakub@redhat.com>
5990
5991 PR middle-end/80162
5992 * c-common.c (c_common_mark_addressable_vec): Don't set
5993 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
5994
3f01b620
MS
59952017-03-21 Martin Sebor <msebor@redhat.com>
5996
5997 PR c++/79548
5998 * c-common.c (set_underlying_type): Mark type used only when
5999 original del is declared unused.
6000
2f6f187a
DM
60012017-03-10 David Malcolm <dmalcolm@redhat.com>
6002
6003 PR translation/79848
6004 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
6005 "%qs".
6006
a02fa805
DM
60072017-03-10 David Malcolm <dmalcolm@redhat.com>
6008
6009 PR c/79921
6010 * c-indentation.c (warn_for_misleading_indentation): Remove parens
6011 from inform's message, so that xgettext can locate it.
6012
822a132c
MP
60132017-03-09 Marek Polacek <polacek@redhat.com>
6014
6015 PR c++/79962
6016 PR c++/79984
6017 * c-attribs.c (handle_nonnull_attribute): Save the result of default
6018 conversion to the attribute list.
6019
bba81f1c
ML
60202017-03-09 Martin Liska <mliska@suse.cz>
6021
6022 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
6023
108154ff
JM
60242017-03-03 Jason Merrill <jason@redhat.com>
6025
6026 * c.opt (Wnoexcept-type): New.
6027
eb0e7c34
RB
60282017-03-02 Richard Biener <rguenther@suse.de>
6029
6030 PR c/79756
6031 * c-common.c (c_common_mark_addressable_vec): Look through
6032 C_MAYBE_CONST_EXPR.
6033
9453ba0a
ML
60342017-02-28 Martin Liska <mliska@suse.cz>
6035
6036 * c.opt: Replace space with tabular for options of <number>
6037 type.
6038
6a825afe
ML
60392017-02-28 Martin Liska <mliska@suse.cz>
6040
6041 * c.opt: Fix --help=option -Q for options which are of
6042 an enum type.
6043
4227c9ad
JJ
60442017-02-24 Jakub Jelinek <jakub@redhat.com>
6045
6046 PR c++/79588
6047 * c-common.c (check_function_restrict): New function.
6048 (check_function_arguments): Add FNDECL argument. Call
6049 check_function_restrict if -Wrestrict.
6050 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
6051 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
6052 * c-common.h (check_function_arguments): Add FNDECL argument.
6053 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
6054
59909673
EB
60552017-02-24 Eric Botcazou <ebotcazou@adacore.com>
6056
6057 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
6058 treatment of parameters with pointer-to-tagged type and tidy up.
6059 (print_ada_methods): Remove the special treatment of C++ static member
6060 functions.
6061
54dcd526
ML
60622017-02-22 Martin Liska <mliska@suse.cz>
6063
6064 * c.opt: Replace inequality signs with square brackets
6065 for -Wnornalized.
6066
00bc9de3
JJ
60672017-02-21 Jakub Jelinek <jakub@redhat.com>
6068
6069 PR c++/79641
6070 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
6071 preserve quals.
6072
97fcf744
JM
60732017-02-17 Joseph Myers <joseph@codesourcery.com>
6074
6075 * c-cppbuiltin.c (builtin_define_float_constants): Define
6076 __DECIMAL_DIG__ to the value for long double.
6077
c7545f1c
MP
60782017-02-15 Marek Polacek <polacek@redhat.com>
6079
6080 PR c/79515
6081 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
6082 conversion has occured.
6083
c2e84327
DM
60842017-01-24 David Malcolm <dmalcolm@redhat.com>
6085
6086 * c-common.c (c_common_reswords): Add "__RTL".
6087 * c-common.h (enum rid): Add RID_RTL.
6088
2ebd93e1
MP
60892017-01-20 Marek Polacek <polacek@redhat.com>
6090
6091 PR c/64279
6092 * c-common.h (do_warn_duplicated_branches_r): Declare.
6093 * c-gimplify.c (c_genericize): Walk the function tree calling
6094 do_warn_duplicated_branches_r.
6095 * c-warn.c (expr_from_macro_expansion_r): New.
6096 (do_warn_duplicated_branches): New.
6097 (do_warn_duplicated_branches_r): New.
6098 * c.opt (Wduplicated-branches): New option.
6099
0d80ab91
DM
61002017-01-17 David Malcolm <dmalcolm@redhat.com>
6101
6102 PR c++/71497
6103 * c-indentation.c (warn_for_misleading_indentation): Use the past
6104 subjunctive in the note.
6105
7f991c36
AH
61062017-01-17 Aldy Hernandez <aldyh@redhat.com>
6107
6108 PR c/79116
6109 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
6110 start type to integer_type.
6111
1c70261c
JJ
61122017-01-16 Jakub Jelinek <jakub@redhat.com>
6113
6114 PR driver/49726
6115 * c.opt (gen-decls): Add Driver flag.
6116
1ddca3f3
PC
61172017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
6118
6119 Revert:
6120 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
6121
6122 PR c++/71737
6123 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
6124
7d2f3f1d
PC
61252017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
6126
6127 PR c++/71737
6128 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
6129
bce6f760
MS
61302017-01-12 Martin Sebor <msebor@redhat.com>
6131
6132 (-Wformat-overflow): ...to this.
6133
bf5fbf46
MS
61342017-01-11 Martin Sebor <msebor@redhat.com>
6135
6136 PR c/78768
6137 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
6138 Also enable for LTO.
6139
e363df3f
JM
61402017-01-10 Jason Merrill <jason@redhat.com>
6141
6142 Implement P0195R2, C++17 variadic using.
6143 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
6144
bd2c6270
JJ
61452017-01-09 Jakub Jelinek <jakub@redhat.com>
6146
6147 PR translation/79019
6148 PR translation/79020
6149 * c.opt (Wnormalized=): Fix typo in description.
6150
efcc8d38
MS
61512017-01-08 Martin Sebor <msebor@redhat.com>
6152
6153 PR middle-end/77708
6154 * c.opt (-Wformat-truncation): New option.
6155
ab20d992 61562017-01-06 Alexandre Oliva <aoliva@redhat.com>
435f3f7a
AO
6157
6158 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
6159 value to unsigned short to fit in 4 hex digits without
6160 warnings.
6161
4e89adf9
EB
61622017-01-05 Eric Botcazou <ebotcazou@adacore.com>
6163
6164 * c.opt (fsso-struct): Add 'native' value.
6165
cd445b54
ML
61662017-01-05 Martin Liska <mliska@suse.cz>
6167
6168 PR pch/78970
6169 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
6170 header.
6171
a9342885
MP
61722017-01-04 Marek Polacek <polacek@redhat.com>
6173
6174 PR c++/64767
6175 * c.opt (Wpointer-compare): New option.
6176
fc73e60c
JJ
61772017-01-04 Jakub Jelinek <jakub@redhat.com>
6178
6179 PR driver/78957
6180 * c.opt (fsso-struct=): Add RejectNegative.
6181
cbe34bb5
JJ
61822017-01-01 Jakub Jelinek <jakub@redhat.com>
6183
6184 Update copyright years.
6185
d4a6c0ea
ML
61862016-12-29 Martin Liska <mliska@suse.cz>
6187
6188 PR c/78933
6189 * c.opt (strong-eval-order): Add RejectNegative keyword.
6190
67a5ad7c
JM
61912016-12-22 Jason Merrill <jason@redhat.com>
6192
6193 Implement P0522R0, matching of template template arguments.
6194 * c-cppbuiltin.c (c_cpp_builtins): Define
6195 __cpp_template_template_args.
6196
0dba7960
JJ
61972016-12-21 Jakub Jelinek <jakub@redhat.com>
6198
6199 PR bootstrap/78817
6200 * c-common.c (struct nonnull_arg_ctx): New type.
6201 (check_function_nonnull): Return bool instead of void. Use
6202 nonnull_arg_ctx as context rather than just location_t.
6203 (check_nonnull_arg): Adjust for the new context type, set
6204 warned_p to true if a warning has been diagnosed.
6205 (check_function_arguments): Return bool instead of void.
6206 * c-common.h (check_function_arguments): Adjust prototype.
6207
31bfc9b9
JM
62082016-12-21 Jason Merrill <jason@redhat.com>
6209
6210 * c.opt (-fnew-ttp-matching): New flag.
6211 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
6212
629b3d75
MJ
62132016-12-14 Martin Jambor <mjambor@suse.cz>
6214
6215 * c-omp.c: Include omp-general.h instead of omp-low.h.
6216 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
6217 name.
6218
474da67e
MS
62192016-12-14 Martin Sebor <msebor@redhat.com>
6220
6221 PR c/17308
6222 * c-common.c (check_nonnull_arg): Disable when optimization
6223 is enabled.
6224
fe366b87
MP
62252016-12-12 Marek Polacek <polacek@redhat.com>
6226
6227 PR c++/78647
6228 * c-common.c (attribute_fallthrough_p): Return false for
6229 error_mark_node.
6230
8bd9f164
MS
62312016-12-08 Martin Sebor <msebor@redhat.com>
6232
6233 PR c/78284
6234 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
6235
060162e0
MS
62362016-12-08 Martin Sebor <msebor@redhat.com>
6237
6238 PR c/78165
92a285c1
ML
6239 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
6240 suffix.
060162e0 6241
ee92e7ba
MS
62422016-12-07 Martin Sebor <msebor@redhat.com>
6243
6244 PR c/53562
6245 PR middle-end/77784
6246 PR middle-end/78149
6247 PR middle-end/78138
6248 * c.opt (-Wstringop-overflow): New option.
6249
84b0769e
MO
62502016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
6251
6252 * c-attribs.c (asan odr indicator): New attribute.
6253 (handle_asan_odr_indicator_attribute): New function.
6254
7fa6a965
PK
62552016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
6256
6257 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
6258 ptrdiff_type_node;
6259
56d8ffc1
JG
62602016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
6261
6262 * c-common.c (excess_precision_mode_join): New.
6263 (c_ts18661_flt_eval_method): New.
6264 (c_c11_flt_eval_method): Likewise.
6265 (c_flt_eval_method): Likewise.
6266 * c-common.h (excess_precision_mode_join): New.
6267 (c_flt_eval_method): Likewise.
6268 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
6269 (cpp_iec_559_value): Call it.
6270 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
6271 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
6272 __FLT_EVAL_METHOD_TS_18661_3__.
6273
04f0fcf7
JG
62742016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
6275
6276 * c-opts.c (c_common_post_options): Add logic to handle the default
6277 case for -fpermitted-flt-eval-methods.
6278
fb2675cb
PB
62792016-11-23 Paolo Bonzini <bonzini@gnu.org>
6280
6281 * c.opt (Wexpansion-to-defined): New.
6282
ec1c5694
JJ
62832016-11-23 Jakub Jelinek <jakub@redhat.com>
6284
6285 PR target/78451
6286 * c-pragma.c (handle_pragma_target): Don't replace
6287 current_target_pragma, but chainon the new args to the current one.
6288
730c9e75
NS
62892016-11-22 Nathan Sidwell <nathan@acm.org>
6290
6291 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
cacd29be 6292 indentation and formatting.
730c9e75 6293
89990732
MS
62942016-11-21 Martin Sebor <msebor@redhat.com>
6295
6296 * c.opt (-fprintf-return-value): Enable by default.
6297
48330c93
BE
62982016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
6299
6300 PR c++/71973
6301 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
6302 * c-common.c (c_common_nodes_and_builtins): Initialize
6303 const_tm_ptr_type_node.
6304
0d939c95
MP
63052016-11-16 Marek Polacek <polacek@redhat.com>
6306
6307 PR c/78285
6308 * c-common.c (c_add_case_label): Turn error_at calls into inform.
6309
8e745a17
JJ
63102016-11-14 Jakub Jelinek <jakub@redhat.com>
6311
6312 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
6313
1ee62b92 63142016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
8e745a17
JJ
6315 Richard Biener <rguenther@suse.de>
6316
6317 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
6318 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
6319 * c.opt (fgimple): New option.
1ee62b92 6320
22b15758
UB
63212016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
6322
6323 PR c/35503
6324 * c-common.h (warn_for_restrict): Declare.
6325 * c-warn.c: Include gcc-rich-location.h.
6326 (warn_for_restrict): New function.
6327 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
6328 (gcc_cdiag_char_table): Likewise.
6329 (gcc_cxxdiag_char_table): Likewise.
6330 * c.opt (Wrestrict): New option.
6331
4be719cd
EB
63322016-11-13 Eric Botcazou <ebotcazou@adacore.com>
6333
6334 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
6335 for nested types only if the type is a record or union and dump SLOC.
6336
4a826ca6
JM
63372016-11-09 Jason Merrill <jason@redhat.com>
6338
6339 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
6340
2e955d50
JJ
63412016-11-09 Jakub Jelinek <jakub@redhat.com>
6342
6343 * c-ubsan.c (ubsan_instrument_shift): Handle split
6344 -fsanitize=shift-base and -fsanitize=shift-exponent.
6345
51dc6603
JM
63462016-11-07 Jason Merrill <jason@redhat.com>
6347
6348 * c.opt (Wc++1z-compat): New.
6349 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
6350
6dc4a604
ML
63512016-11-07 Martin Liska <mliska@suse.cz>
6352
6353 * c-warn.c (warn_for_unused_label): Save all labels used
6354 in goto or in &label.
6355
b302001e
JM
63562016-11-03 Jason Merrill <jason@redhat.com>
6357
6358 * c-cppbuiltin.c (c_cpp_builtins): Correct
6359 __cpp_inheriting_constructors.
6360
31f7f784
JM
63612016-11-01 Jason Merrill <jason@redhat.com>
6362
2bc78e3c
JM
6363 * c-cppbuiltin.c (c_cpp_builtins): Update
6364 __cpp_inheriting_constructors.
6365
31f7f784
JM
6366 * c.opt (-fnew-inheriting-ctors): New.
6367 * c-opts.c: Default to on for ABI 11+.
6368
dcb466ec
JJ
63692016-10-31 Jakub Jelinek <jakub@redhat.com>
6370
6371 PR c++/77948
6372 * c.opt (fext-numeric-literals): Add Var and Init.
6373 * c-opts.c (c_common_handle_option): Don't clear
6374 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
6375 (c_common_post_options): Clear it here if not set
6376 explicitly.
6377
52e1b91e
AH
63782016-10-28 Aldy Hernandez <aldyh@redhat.com>
6379
6380 PR debug/77773
6381 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
6382 if NULL.
6383
e16f1cc7
JJ
63842016-10-25 Jakub Jelinek <jakub@redhat.com>
6385
6386 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
6387 * c-common.c (c_common_reswords): Add __builtin_launder.
6388
f8348061
BE
63892016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
6390
6391 * c-common.c (c_common_truthvalue_conversion): Warn for
6392 multiplications in boolean context. Fix the quoting of '<<' and '<'
6393 in the shift warning.
6394
eff89e01
BE
63952016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
6396
6397 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
6398
24bc7bf4
JM
63992016-10-20 Jason Merrill <jason@redhat.com>
6400
6401 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
6402
4c712374
BE
64032016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
6404
6405 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
6406 integer shift ops in boolean context.
6407
64082016-10-18 Aldy Hernandez <aldyh@redhat.com>
adc577c5
AH
6409
6410 * c.opt (Walloca): New.
6411 (Walloca-larger-than=): New.
6412 (Wvla-larger-than=): New.
6413
8fa18c06
MP
64142016-10-17 Marek Polacek <polacek@redhat.com>
6415
6416 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
6417 Return immediately when finding a match.
6418 (warn_tautological_cmp): Remove a boolean variable that is no longer
6419 needed.
6420
b12b1915
MP
64212016-10-17 Marek Polacek <polacek@redhat.com>
6422
6423 * c-attribs.c: New file.
6424 * c-common.c: Move attributes handling to c-attribs.c.
6425 (get_nonnull_operand): No longer static.
6426 * c-common.h: Move the declarations from c-attribs.c to its own section.
6427
2045acd9
JM
64282016-10-14 Jason Merrill <jason@redhat.com>
6429
6430 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
6431 and __cpp_deduction_guides.
6432
14a2c9aa
JM
64332016-10-13 Jason Merrill <jason@redhat.com>
6434
6435 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
6436
4d0cdd0c
TP
64372016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
6438
6439 * c-cppbuiltin.c: Include memmodel.h.
6440 * c-opts.c: Likewise.
6441 * c-pragma.c: Likewise.
6442 * c-warn.c: Likewise.
6443
70f6d5e1
JJ
64442016-10-12 Jakub Jelinek <jakub@redhat.com>
6445
6446 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
6447 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
6448 * c-opts.c (sanitize_cpp_opts): Initialize
6449 cpp_opts->cpp_warn_implicit_fallthrough.
6450
78f61294
MP
64512016-10-11 Marek Polacek <polacek@redhat.com>
6452
6453 * c-common.c (warning_candidate_p): Change the return type to bool
6454 and return true/false instead of 1/0.
6455 (vector_mode_valid_p): Likewise.
6456
038b5cc0
MP
64572016-10-11 Marek Polacek <polacek@redhat.com>
6458
6459 * c-common.c (fold_for_warn): No longer static.
6460 (bool_promoted_to_int_p): Likewise.
6461 (c_common_get_narrower): Likewise.
6462 (constant_expression_warning): Move to c-warn.c.
6463 (constant_expression_error): Likewise.
6464 (overflow_warning): Likewise.
6465 (warn_logical_operator): Likewise.
6466 (find_array_ref_with_const_idx_r): Likewise.
6467 (warn_tautological_cmp): Likewise.
6468 (expr_has_boolean_operands_p): Likewise.
6469 (warn_logical_not_parentheses): Likewise.
6470 (warn_if_unused_value): Likewise.
6471 (strict_aliasing_warning): Likewise.
6472 (sizeof_pointer_memaccess_warning): Likewise.
6473 (check_main_parameter_types): Likewise.
6474 (conversion_warning): Likewise.
6475 (warnings_for_convert_and_check): Likewise.
6476 (match_case_to_enum_1): Likewise.
6477 (match_case_to_enum): Likewise.
6478 (c_do_switch_warnings): Likewise.
6479 (warn_for_omitted_condop): Likewise.
6480 (readonly_error): Likewise.
6481 (lvalue_error): Likewise.
6482 (invalid_indirection_error): Likewise.
6483 (warn_array_subscript_with_type_char): Likewise.
6484 (warn_about_parentheses): Likewise.
6485 (warn_for_unused_label): Likewise.
6486 (warn_for_div_by_zero): Likewise.
6487 (warn_for_memset): Likewise.
6488 (warn_for_sign_compare): Likewise.
6489 (do_warn_double_promotion): Likewise.
6490 (do_warn_unused_parameter): Likewise.
6491 (record_locally_defined_typedef): Likewise.
6492 (maybe_record_typedef_use): Likewise.
6493 (maybe_warn_unused_local_typedefs): Likewise.
6494 (maybe_warn_bool_compare): Likewise.
6495 (maybe_warn_shift_overflow): Likewise.
6496 (warn_duplicated_cond_add_or_warn): Likewise.
6497 (diagnose_mismatched_attributes): Likewise.
6498 * c-common.h: Move the declarations from c-warn.c to its own section.
6499 * c-warn.c: New file.
6500
627be19f
JM
65012016-10-08 Jason Merrill <jason@redhat.com>
6502
6503 * c-common.c (c_common_truthvalue_conversion): Don't distribute
6504 into COND_EXPR in C++.
6505
7bad794a
JJ
65062016-10-08 Jakub Jelinek <jakub@redhat.com>
6507
6508 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
6509 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
6510 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
6511
be845b04
JJ
65122016-10-07 Jakub Jelinek <jakub@redhat.com>
6513
6514 Implement LWG2296 helper intrinsic
6515 * c-common.h (enum rid): Add RID_ADDRESSOF.
6516 * c-common.c (c_common_reswords): Add __builtin_addressof.
6517
c09c4992
BE
65182016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
6519
6520 PR c++/77700
6521 * c-common.c (c_common_truthvalue_conversion): Warn also for
6522 suspicious enum values in boolean context.
6523
342cfb3e
JJ
65242016-10-06 Jakub Jelinek <jakub@redhat.com>
6525
6526 Implement P0258R2 - helper for C++17
6527 std::has_unique_object_representations trait
6528 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
6529 * c-common.c (c_common_reswords): Add
6530 __has_unique_object_representations.
6531
2e69f143
JJ
65322016-10-05 Jakub Jelinek <jakub@redhat.com>
6533
6534 PR sanitizer/66343
6535 * c-ubsan.c (ubsan_instrument_return): Don't call
6536 initialize_sanitizer_builtins here.
6537
700fff34
BE
65382016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
6539
6540 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
6541 conditional expression in boolean context when only one arm is
6542 non-boolean.
6543
9563bfcd
JJ
65442016-10-05 Jakub Jelinek <jakub@redhat.com>
6545
04a32443
JJ
6546 PR sanitizer/77823
6547 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
6548 is not integral.
6549
9563bfcd
JJ
6550 * c-common.c (c_common_reswords): Update comment for C++11.
6551
f1644724
JM
65522016-10-04 Jason Merrill <jason@redhat.com>
6553
6554 * c-common.c (make_tree_vector_from_ctor): New.
6555 * c-common.h: Declare it.
6556
5a79befb
JJ
65572016-10-04 Jakub Jelinek <jakub@redhat.com>
6558
6559 * c-cppbuiltin.c (c_cpp_builtins): Don't define
6560 __LIBGCC_JCR_SECTION_NAME__.
6561
1633d3b9
BE
65622016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
6563
6564 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
6565 left shift in boolean context.
6566
a2c6e7f2
JJ
65672016-09-29 Jakub Jelinek <jakub@redhat.com>
6568
6569 Implement P0001R1 - C++17 removal of register storage class specifier
6570 * c.opt (Wregister): New warning.
6571 * c-opts.c (c_common_post_options): Enable -Wregister by
6572 default for C++17.
6573
75304c87
JG
65742016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
6575
6576 * c-opts.c (c_common_post_options): Remove special case for
6577 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
6578 in C++.
6579
bbfac6da
JJ
65802016-09-27 Jakub Jelinek <jakub@redhat.com>
6581
6e39060a
JJ
6582 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
6583 -std=c++1z.
6584
bbfac6da
JJ
6585 * c-ada-spec.c (print_ada_declaration): Remove break after return.
6586
e73cf9a2
TP
65872016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
6588
6589 * c-common.c: Include memmodel.h.
6590
c6147dc4
MP
65912016-09-26 Marek Polacek <polacek@redhat.com>
6592
6593 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
6594
81fea426
MP
65952016-09-26 Marek Polacek <polacek@redhat.com>
6596
6597 PR c/7652
6598 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
6599 (handle_fallthrough_attribute): New function.
6600 (attribute_fallthrough_p): New function.
6601 * c-common.h (attribute_fallthrough_p): Declare.
6602
9a2300e9
MP
66032016-09-24 Marek Polacek <polacek@redhat.com>
6604
6605 PR c/77490
6606 * c.opt (Wbool-operation): New.
6607
a09e9e35
BE
66082016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
6609
6610 * c-common.c (c_common_truthvalue_conversion): Inhibit
6611 Wint-in-bool-context warning with from_macro_definition_at.
6612 Mention the expression will always evaluate to true.
6613
d43b4ccc
MS
66142016-09-21 Martin Sebor <msebor@redhat.com>
6615
6616 PR bootstrap/77676
6617 * c.opt (fprintf-return-value): Temporarily initialize to zero
6618 to unblock bootstrap failures.
6619
2e1c20b1
JJ
66202016-09-21 Jakub Jelinek <jakub@redhat.com>
6621
6622 PR c++/77651
6623 * c.opt (Waligned-new=): Add RejectNegative.
6624 (faligned-new=): Likewise. Spelling fix - change
6625 aligned_new_threshhold to aligned_new_threshold.
6626 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
6627 to aligned_new_threshold.
6628
88d0c3f0
MS
66292016-09-20 Martin Sebor <msebor@redhat.com>
6630
6631 PR middle-end/49905
6632 * c.opt: Add -Wformat-length and -fprintf-return-value.
6633
144a96e4
BE
66342016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
6635
6636 PR c++/77434
6637 * c.opt (Wint-in-bool-context): New warning.
6638 * c-common.c (c_common_truthvalue_conversion): Warn on integer
6639 constants in boolean context.
6640
63012d9a
JM
66412016-09-19 Joseph Myers <joseph@codesourcery.com>
6642
6643 * c-common.c (max_align_t_align): Also consider alignment of
6644 float128_type_node.
6645
931388ce
JM
66462016-09-15 Jason Merrill <jason@redhat.com>
6647
6648 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
6649 DECL_EXTERNAL.
6650
38711381
JM
66512016-09-14 Jason Merrill <jason@redhat.com>
6652
6653 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
6654 limit FIELD_DECL, either.
6655
e51fbec3
MP
66562016-09-14 Marek Polacek <polacek@redhat.com>
6657
6658 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
6659 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
6660 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
6661
254830ba
DM
66622016-09-13 David Malcolm <dmalcolm@redhat.com>
6663
6664 * c-common.c (warn_logical_not_parentheses): Replace
6665 rich_location::add_fixit_insert calls with add_fixit_insert_before
6666 and add_fixit_insert_after, eliminating the "next_loc" calculation.
6667
42763690
JM
66682016-09-13 Jason Merrill <jason@redhat.com>
6669 Tom de Vries <tom@codesourcery.com>
6670
6671 PR c++/77427
6672 * c-common.c (set_underlying_type): Don't treat array as builtin type.
6673
9453eee9
JM
66742016-09-13 Jason Merrill <jason@redhat.com>
6675
6676 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
6677 limit types at all.
6678
e96809e3
JM
66792016-09-12 Jason Merrill <jason@redhat.com>
6680
6681 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
6682 bit/byte confusion, allow large alignment for types.
6683
54dcdb88
BE
66842016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
6685
6686 PR c++/77496
6687 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
6688
d1463eb9
DM
66892016-09-12 David Malcolm <dmalcolm@redhat.com>
6690
6691 PR c/72858
6692 * c-format.c (argument_parser::check_argument_type): Add params
6693 "type_start" and "conversion_char". Use the former to generate
6694 offset_to_type_start and pass it and conversion_char to
6695 check_format_types.
6696 (check_format_info_main): Capture the start of the type
6697 information as "type_start", and pass it an format_char
6698 to arg_parser.check_argument_type.
6699 (check_format_types): Provide an example in the leading comment.
6700 Add params "offset_to_type_start" and "conversion_char"; pass
6701 them to format_type_warning calls.
6702 (test_get_modifier_for_format_len): Likewise.
6703 (matching_type_p): New function.
6704 (get_format_for_type): Add param "conversion_char" and move
6705 implementation into...
6706 (get_format_for_type_1): ...new function, called twice.
6707 Use new function matching_type_p rather than checking for
6708 TYPE_CANONICAL equality.
6709 (get_corrected_substring): New function.
6710 (format_type_warning): Provide an example in the leading comment.
6711 Add params "offset_to_type_start" and "conversion_char". Replace
6712 call to get_format_for_type with call to get_corrected_substring
6713 and move rejection of hints for widths/precisions there.
6714 (assert_format_for_type_streq): Add param "conversion_char".
6715 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
6716 (test_get_format_for_type_printf): Add conversion chars to the
6717 tests, adding coverage for various combinations of integer
6718 vs double conversions, and for preserving octal and hexadecimal
6719 conversions.
6720 (test_get_format_for_type_scanf): Add conversion chars to the
6721 tests.
6722
5b28efbb
TV
67232016-09-10 Tom de Vries <tom@codesourcery.com>
6724
6725 PR C/71602
6726 * c-common.c (build_va_arg): Handle more strict
6727 targetm.canonical_va_list_type. Replace first argument type error with
6728 assert.
6729
3f0177e7
MS
67302016-09-09 Martin Sebor <msebor@redhat.com>
6731
6732 PR c/77520
6733 PR c/77521
6734 * c-format.c (argument_parser::find_format_char_info): Use %qc
6735 format directive unconditionally.
6736
af63ba4b
JM
67372016-09-09 Jason Merrill <jason@redhat.com>
6738
6739 Implement C++17 new of over-aligned types.
6740 * c.opt: Add -faligned-new and -Waligned-new.
6741 * c-common.c (max_align_t_align): Split out from...
6742 (cxx_fundamental_alignment_p): ...here.
6743 * c-common.h: Declare it.
6744 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
6745
c65248cb
JM
67462016-09-09 Joseph Myers <joseph@codesourcery.com>
6747
6748 * c-cppbuiltin.c (builtin_define_type_width): New function.
6749 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
6750 macros.
6751
e5106e27
DM
67522016-09-07 David Malcolm <dmalcolm@redhat.com>
6753
6754 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
6755 a POINTER_TYPE.
6756 (substring_loc::get_location): Move to substring-locations.c,
6757 keeping implementation as...
6758 (c_get_substring_location): New function, from the above, reworked
6759 to use accessors rather than member lookup.
6760 * c-common.h (class substring_loc): Move to substring-locations.h,
6761 replacing with a forward decl.
6762 (c_get_substring_location): New decl.
6763 * c-format.c: Include "substring-locations.h".
6764 (format_warning_va): Move to substring-locations.c.
6765 (format_warning_at_substring): Likewise.
6766
ab20d992 67672016-09-06 Martin Sebor <msebor@redhat.com>
a42e7952
MS
6768
6769 PR c/77336
6770 * c-format.c (check_function_format): Avoid issuing warnings for
6771 functions unless they call format functions with non-constant
6772 format strings.
6773
b772a565
RB
67742016-09-06 Richard Biener <rguenther@suse.de>
6775
6776 PR c/77450
6777 * c-common.c (c_common_mark_addressable_vec): Handle
6778 COMPOUND_LITERAL_EXPR.
6779
25ff5dd3
MP
67802016-09-05 Marek Polacek <polacek@redhat.com>
6781
6782 PR c/77423
6783 * c-common.c (bool_promoted_to_int_p): New function.
6784 (expr_has_boolean_operands_p): New function.
6785 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
6786 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
6787
21234eb5
TV
67882016-09-04 Tom de Vries <tom@codesourcery.com>
6789
6790 revert:
6791 2016-08-29 Tom de Vries <tom@codesourcery.com>
6792
6793 * c-common.c (build_va_arg): Replace first argument type error
6794 with assert.
6795
9dc5773f
JJ
67962016-09-02 Jakub Jelinek <jakub@redhat.com>
6797
6798 PR c/65467
6799 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
6800 (c_finish_omp_for): Reject _Atomic qualified iterators.
6801
68022016-09-01 Martin Sebor <msebor@redhat.com>
3d7b83b6
MS
6803
6804 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
6805 size to guarantee it fits the output of the formatted function
6806 regardless of its arguments.
6807
295844f6
MP
68082016-09-01 Marek Polacek <polacek@redhat.com>
6809
6810 PR c/7652
6811 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
6812 FALLTHRU comments.
6813
3d06b6f2
MP
68142016-08-29 Marek Polacek <polacek@redhat.com>
6815
6816 PR c/77292
6817 * c-common.c (warn_logical_not_parentheses): Don't warn for
6818 a comparison or a logical operator.
6819
34cedad5
TV
68202016-08-29 Tom de Vries <tom@codesourcery.com>
6821
6822 * c-common.c (build_va_arg): Fix type comparison assert.
6823
f162d717
TV
68242016-08-29 Tom de Vries <tom@codesourcery.com>
6825
6826 * c-common.c (build_va_arg): Replace first argument type error
6827 with assert.
6828
ba9bbd6f
TV
68292016-08-29 Tom de Vries <tom@codesourcery.com>
6830
6831 PR c/77398
6832 * c-common.c (build_va_arg): Add first argument error. Build va_arg
6833 with error_mark_node as va_list instead of with illegal va_list.
6834
ebef225f
MP
68352016-08-25 Marek Polacek <polacek@redhat.com>
6836 David Malcolm <dmalcolm@redhat.com>
6837
6838 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
6839 * c-common.h (warn_logical_not_parentheses): Update declaration.
6840
b00e6e75
MP
68412016-08-22 Marek Polacek <polacek@redhat.com>
6842
6843 PR c++/77321
6844 * c-common.c (warn_for_memset): Check type for null.
6845
6dc198e3
JM
68462016-08-22 Joseph Myers <joseph@codesourcery.com>
6847
14ec014e 6848 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
6dc198e3
JM
6849 _FloatNx types for suffixes for built-in functions.
6850
c65699ef
JM
68512016-08-19 Joseph Myers <joseph@codesourcery.com>
6852
6853 PR c/32187
6854 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
6855 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
6856 (RID_FLOAT128X): New enum rid values.
6857 (CASE_RID_FLOATN_NX): New macro.
6858 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
6859 keywords.
6860 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
6861 corresponding complex types.
6862 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
6863 _FloatNx and corresponding complex types.
6864 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
6865 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
6866 and _FloatNx types for the widest type for determining
6867 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
6868 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
6869 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
6870 and _FloatNx types.
6871 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
6872 constants.
6873 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
6874 _FloatNx types.
6875
cc015f3a
DM
68762016-08-18 David Malcolm <dmalcolm@redhat.com>
6877
6878 * c-opts.c (c_diagnostic_finalizer): Update for change to
6879 diagnostic_show_locus.
6880
cb18fd07
DM
68812016-08-18 David Malcolm <dmalcolm@redhat.com>
6882
6883 * c-common.c: Include "spellcheck.h".
6884 (cb_get_suggestion): New function.
6885 * c-common.h (cb_get_suggestion): New decl.
6886 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
6887 cb_get_suggestion.
6888
a76989dc
MP
68892016-08-18 Marek Polacek <polacek@redhat.com>
6890
6891 PR c/71514
6892 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
6893 and pointer-to-VLA.
6894
65e736c0
DM
68952016-08-16 David Malcolm <dmalcolm@redhat.com>
6896
6897 PR c/72857
6898 * c-common.c (substring_loc::get_range): Rename to...
6899 (substring_loc::get_location): ...this, converting param from a
6900 source_range * to a location_t *. Call
6901 get_source_location_for_substring rather than
6902 get_source_range_for_substring, and pass in m_caret_idx.
6903 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
6904 (substring_loc::get_range): Replace with...
6905 (substring_loc::get_location): ...this.
6906 (substring_loc::set_caret_index): New method.
6907 (substring_loc): Add field m_caret_idx.
6908 * c-format.c (format_warning_va): Update for above changes.
6909 Rename local "substring_loc" to "fmt_substring_loc" to avoid
6910 clashing with type name.
6911 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
6912 (check_argument_type): Likewise.
6913 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
6914 Use a copy when emitting warnings, setting the caret index from TYPE.
6915
7e1dde14 69162016-08-16 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 6917 Arnaud Charlet <charlet@adacore.com>
7e1dde14
EB
6918
6919 * c-ada-spec.c (dump_number): New function.
6920 (handle_escape_character): Likewise.
6921 (print_ada_macros): Add handling of constant integers and strings.
6922
191816a3
MP
69232016-08-12 Marek Polacek <polacek@redhat.com>
6924
6925 PR c/7652
6926 * c-common.c (scalar_to_vector): Adjust fall through comment.
6927 * c-opts.c (c_common_handle_option): Likewise.
6928 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
6929 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
6930 fall through comment.
6931 * cilk.c (extract_free_variables): Add FALLTHRU.
6932
452df4a4
JM
69332016-08-10 Jason Merrill <jason@redhat.com>
6934
6935 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
6936
f3365c12
JM
69372016-08-09 Jason Merrill <jason@redhat.com>
6938
6939 * c-common.c (c_common_attribute_table): vector_size affects type
6940 identity.
6941
f0bc3323
MP
69422016-08-09 Marek Polacek <polacek@redhat.com>
6943
6944 PR c/7652
6945 * c-ada-spec.c (dump_generic_ada_node): Add return.
6946
98e5a19a
JM
69472016-08-09 Jason Merrill <jason@redhat.com>
6948
6949 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
6950 C++17 constexpr lambdas.
6951
895aa8e1
DM
69522016-08-08 David Malcolm <dmalcolm@redhat.com>
6953
6954 PR c/64955
6955 * c-common.h (selftest::c_format_c_tests): New declaration.
6956 (selftest::run_c_tests): New declaration.
6957 * c-format.c: Include "selftest.h.
6958 (format_warning_va): Add param "corrected_substring" and use
6959 it to add a replacement fix-it hint.
6960 (format_warning_at_substring): Likewise.
6961 (format_warning_at_char): Update for new param of
6962 format_warning_va.
6963 (argument_parser::check_argument_type): Pass "fki" to
6964 check_format_types.
6965 (check_format_types): Add param "fki" and pass it to
6966 format_type_warning.
6967 (deref_n_times): New function.
6968 (get_modifier_for_format_len): New function.
6969 (selftest::test_get_modifier_for_format_len): New function.
6970 (get_format_for_type): New function.
6971 (format_type_warning): Add param "fki" and use it to attempt
6972 to provide hints for argument types when calling
6973 format_warning_at_substring.
6974 (selftest::get_info): New function.
6975 (selftest::assert_format_for_type_streq): New function.
6976 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
6977 (selftest::test_get_format_for_type_printf): New function.
6978 (selftest::test_get_format_for_type_scanf): New function.
6979 (selftest::c_format_c_tests): New function.
6980
e52ed3fe
DM
69812016-08-08 David Malcolm <dmalcolm@redhat.com>
6982
6983 PR c/52952
6984 * c-format.c: Include "diagnostic.h".
6985 (location_column_from_byte_offset): Delete.
6986 (location_from_offset): Delete.
6987 (format_warning_va): New function.
6988 (format_warning_at_substring): New function.
6989 (format_warning_at_char): New function.
6990 (check_format_arg): Capture location of format_tree and pass to
6991 check_format_info_main.
6992 (argument_parser): Add fields "start_of_this_format" and
6993 "format_string_cst".
6994 (flag_chars_t::validate): Add param "format_string_cst". Convert
6995 warning_at call using location_from_offset to call to
6996 format_warning_at_char.
6997 (argument_parser::argument_parser): Add param "format_string_cst_"
6998 and use use it to initialize field "format_string_cst".
6999 Initialize new field "start_of_this_format".
7000 (argument_parser::read_format_flags): Convert warning_at call
7001 using location_from_offset to a call to format_warning_at_char.
7002 (argument_parser::read_any_format_left_precision): Likewise.
7003 (argument_parser::read_any_format_precision): Likewise.
7004 (argument_parser::read_any_other_modifier): Likewise.
7005 (argument_parser::find_format_char_info): Likewise, in three places.
7006 (argument_parser::parse_any_scan_set): Likewise, in one place.
7007 (argument_parser::handle_conversions): Likewise, in two places.
7008 (argument_parser::check_argument_type): Add param "fmt_param_loc"
7009 and use it to make a substring_loc. Pass the latter to
7010 check_format_types.
7011 (check_format_info_main): Add params "fmt_param_loc" and
7012 "format_string_cst". Convert warning_at calls using
7013 location_from_offset to calls to format_warning_at_char. Pass the
7014 new params to the arg_parser ctor. Pass "format_string_cst" to
7015 flag_chars.validate. Pass "fmt_param_loc" to
7016 arg_parser.check_argument_type.
7017 (check_format_types): Convert first param from a location_t
7018 to a const substring_loc & and rename to "fmt_loc". Attempt
7019 to extract the range of the relevant parameter and pass it
7020 to format_type_warning.
7021 (format_type_warning): Convert first param from a location_t
7022 to a const substring_loc & and rename to "fmt_loc". Add
7023 params "param_range" and "type". Replace calls to warning_at
7024 with calls to format_warning_at_substring.
7025
1c4d457e
DM
70262016-08-08 David Malcolm <dmalcolm@redhat.com>
7027
7028 * c-format.c (class flag_chars_t): New class.
7029 (struct length_modifier): New struct.
7030 (class argument_parser): New class.
7031 (flag_chars_t::flag_chars_t): New ctor.
7032 (flag_chars_t::has_char_p): New method.
7033 (flag_chars_t::add_char): New method.
7034 (flag_chars_t::validate): New method.
7035 (flag_chars_t::get_alloc_flag): New method.
7036 (flag_chars_t::assignment_suppression_p): New method.
7037 (argument_parser::argument_parser): New ctor.
7038 (argument_parser::read_any_dollar): New method.
7039 (argument_parser::read_format_flags): New method.
7040 (argument_parser::read_any_format_width): New method.
7041 (argument_parser::read_any_format_left_precision): New method.
7042 (argument_parser::read_any_format_precision): New method.
7043 (argument_parser::handle_alloc_chars): New method.
7044 (argument_parser::read_any_length_modifier): New method.
7045 (argument_parser::read_any_other_modifier): New method.
7046 (argument_parser::find_format_char_info): New method.
7047 (argument_parser::validate_flag_pairs): New method.
7048 (argument_parser::give_y2k_warnings): New method.
7049 (argument_parser::parse_any_scan_set): New method.
7050 (argument_parser::handle_conversions): New method.
7051 (argument_parser::check_argument_type): New method.
7052 (check_format_info_main): Introduce classes argument_parser
7053 and flag_chars_t, moving the code within the loop into methods
7054 of these classes. Make various locals "const".
7055
88fa5555
DM
70562016-08-05 David Malcolm <dmalcolm@redhat.com>
7057
7058 * c-common.c: Include "substring-locations.h".
7059 (get_cpp_ttype_from_string_type): New function.
7060 (g_string_concat_db): New global.
7061 (substring_loc::get_range): New method.
7062 * c-common.h (g_string_concat_db): New declaration.
7063 (class substring_loc): New class.
7064 * c-lex.c (lex_string): When concatenating strings, capture the
7065 locations of all tokens using a new obstack, and record the
7066 concatenation locations within g_string_concat_db.
7067 * c-opts.c (c_common_init_options): Construct g_string_concat_db
7068 on the ggc-heap.
7069
78169471
MP
70702016-07-29 Marek Polacek <polacek@redhat.com>
7071
638fc14f
MP
7072 PR c/71926
7073 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
7074 parentheses warning.
7075
78169471
MP
7076 PR c/71574
7077 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
7078
1225d6b1
ML
70792016-07-28 Martin Liska <mliska@suse.cz>
7080
7081 PR gcov-profile/68025
7082 * c-common.c (handle_no_profile_instrument_function_attribute):
7083
ec1e2a40
BE
70842016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
7085
7086 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
7087 BITS_PER_UNIT_LOG.
7088
5ec2cd9f
JM
70892016-07-25 Jason Merrill <jason@redhat.com>
7090
7091 PR c++/65970
7092 * c.opt (fconstexpr-loop-limit): New.
7093
9dc5773f 70942016-07-22 Martin Sebor <msebor@redhat.com>
2e6b45af
MS
7095
7096 PR c++/71675
7097 * c-common.c (resolve_overloaded_builtin): Avoid converting
7098 __atomic_compare_exchange_n return type to that of what its
7099 first argument points to.
7100
e3fe09c1
UB
71012016-07-22 Uros Bizjak <ubizjak@gmail.com>
7102
7103 * c-common.c: Use HOST_WIDE_INT_M1U instead of
7104 ~(unsigned HOST_WIDE_INT) 0.
7105
bc91c436
ML
71062016-07-22 Martin Liska <mliska@suse.cz>
7107
7108 PR gcov-profile/69028
7109 PR gcov-profile/62047
7110 * cilk.c (create_cilk_helper_decl): Set location of a new decl
7111 to the current_function_decl.
7112
451dcc66
JM
71132016-07-21 Jason Merrill <jason@redhat.com>
7114
7115 PR c++/65168
7116 * c-common.c (c_common_truthvalue_conversion): Check
7117 c_inhibit_evaluation_warnings for warning about address of
7118 reference.
7119
de6a69ee
DM
71202016-07-20 David Malcolm <dmalcolm@redhat.com>
7121
7122 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
7123 const char *.
7124
d022c55a
JM
71252016-07-15 Jason Merrill <jason@redhat.com>
7126
7127 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
7128
ddbbcb19
JJ
71292016-07-15 Jakub Jelinek <jakub@redhat.com>
7130
7131 PR c/71858
7132 * c-common.h (enum lookup_name_fuzzy_kind): Add
7133 FUZZY_LOOKUP_FUNCTION_NAME.
7134
d0cf395a
JM
71352016-07-08 Jason Merrill <jason@redhat.com>
7136
7137 P0145: Refining Expression Order for C++.
7138 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
7139 * c-opts.c: Adjust.
7140
98d44e93
MT
71412016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
7142
7143 PR c++/71214
7144 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
7145
f9d8d994
TS
71462016-06-29 Thomas Schwinge <thomas@codesourcery.com>
7147
7148 * c-pragma.h (enum pragma_kind): Rename
7149 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
7150 users.
7151
4aa83879
RB
71522016-06-29 Richard Biener <rguenther@suse.de>
7153
7154 PR middle-end/71002
7155 * c-common.c (c_common_get_alias_set): Remove union type punning case.
7156
a25bd9e6
JM
71572016-06-24 Jason Merrill <jason@redhat.com>
7158
7159 P0145R2: Refining Expression Order for C++.
7160 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
7161 MODIFY_EXPR.
7162
a86451b9
JJ
71632016-06-24 Jakub Jelinek <jakub@redhat.com>
7164
7165 * c-common.c (check_builtin_function_arguments): Require last
7166 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
7167 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
7168 if the last argument is pointer to enumerated or boolean type.
7169
1a4f11c8
DM
71702016-06-22 David Malcolm <dmalcolm@redhat.com>
7171
7172 PR c/70339
7173 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
7174 (lookup_name_fuzzy): New prototype.
7175
fe55692c
JDA
71762016-06-21 John David Anglin <danglin@gcc.gnu.org>
7177
7178 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
7179
4eb24e01
JM
71802016-06-14 Jason Merrill <jason@redhat.com>
7181
7182 P0145R2: Refining Expression Order for C++.
7183 * c.opt (fargs-in-order): New.
7184 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
7185
ef7cf206
JJ
71862016-06-13 Jakub Jelinek <jakub@redhat.com>
7187
0dda258b
JJ
7188 PR sanitizer/71498
7189 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
7190 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
7191
ef7cf206
JJ
7192 PR preprocessor/71183
7193 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
7194 to cb_get_source_date_epoch.
7195
50b15873
JJ
71962016-06-10 Jakub Jelinek <jakub@redhat.com>
7197
7198 PR c/68657
7199 * c.opt (Wpsabi): Add Warning flag.
7200
4d926e34
MS
72012016-06-10 Martin Sebor <msebor@redhat.com>
7202
7203 PR c/71392
14ec014e 7204 * c-common.c (handle_nonnull_attribute): Accept
4d926e34
MS
7205 the nonnull attribute in type-generic builtins.
7206
e01b4e16
MS
72072016-06-09 Martin Sebor <msebor@redhat.com>
7208
7209 PR c/70883
7210 * c-common.c (builtin_function_validate_nargs): Make text of error
7211 message consistent with others like it.
7212
44a845ca
MS
72132016-06-08 Martin Sebor <msebor@redhat.com>
7214 Jakub Jelinek <jakub@redhat.com>
7215
7216 PR c++/70507
7217 PR c/68120
7218 * c-common.c (check_builtin_function_arguments): Handle
7219 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
7220
a80a7051
RB
72212016-06-08 Richard Biener <rguenther@suse.de>
7222
7223 * c-common.c (parse_optimize_options): Improve diagnostic messages.
7224
bfd67b47
RB
72252016-06-07 Richard Biener <rguenther@suse.de>
7226
7227 PR c/61564
7228 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
7229 options and warn about others.
7230
15c98b2e
ES
72312016-06-01 Eduard Sanou <dhole@openmailbox.org>
7232
7233 * c-common.c (get_source_date_epoch): Rename to
7234 cb_get_source_date_epoch.
7235 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
7236 message when the parsing fails. Use error_at instead of fatal_error.
7237 * c-common.h (get_source_date_epoch): Rename to
7238 cb_get_source_date_epoch.
7239 * c-common.h (cb_get_source_date_epoch): Prototype.
7240 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
7241 * c-common.h (c_omp_region_type): Remove trailing comma.
7242 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
7243 * c-lex.c (c_lex_with_flags): Remove initialization of
7244 pfile->source_date_epoch.
7245
00631022
JJ
72462016-05-30 Jakub Jelinek <jakub@redhat.com>
7247
7248 PR c++/71349
7249 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
7250 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
7251 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
7252 instead of C_OMP_CLAUSE_SPLIT_FOR.
7253
f17a223d
RB
72542016-05-24 Richard Biener <rguenther@suse.de>
7255
7256 PR middle-end/70434
7257 PR c/69504
7258 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
7259 (convert_vector_to_array_for_subscript): ... this.
7260 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
7261 VIEW_CONVERT_EXPR to an array type. Rename to ...
7262 (convert_vector_to_array_for_subscript): ... this.
7263
4f2e1536
MP
72642016-05-12 Marek Polacek <polacek@redhat.com>
7265
7266 PR c/70756
7267 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
7268 size_in_bytes and pass LOC to it.
7269
d6e83a8d
MM
72702016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
7271
7272 PR c/43651
7273 * c.opt (Wduplicate-decl-specifier): New option.
7274
5c3a10fb
MP
72752016-05-11 Marek Polacek <polacek@redhat.com>
7276
7277 PR c++/71024
7278 * c-common.c (diagnose_mismatched_attributes): New function.
7279 * c-common.h (diagnose_mismatched_attributes): Declare.
7280
deef7113
MP
72812016-05-04 Marek Polacek <polacek@redhat.com>
7282
7283 * c.opt (Wdangling-else): New option.
7284
79ce98bc
MP
72852016-05-03 Marek Polacek <polacek@redhat.com>
7286
7287 PR c/70859
7288 * c-common.c (builtin_function_validate_nargs): Add location
7289 parameter. Use it.
7290 (check_builtin_function_arguments): Add location and arguments
7291 parameters. Use them.
7292 * c-common.h (check_builtin_function_arguments): Update declaration.
7293
381cdae4
RB
72942016-05-03 Richard Biener <rguenther@suse.de>
7295
7296 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
7297 allow call args to gimplify to SSA names.
7298
1d793c34
MP
72992016-05-03 Marek Polacek <polacek@redhat.com>
7300
7301 * c-common.h (enum c_omp_region_type): Remove stray comma.
7302
77886428
CP
73032016-05-02 Cesar Philippidis <cesar@codesourcery.com>
7304
7305 * c-common.h (enum c_omp_region_type): Define.
7306
697e0b28
RS
73072016-05-02 Richard Sandiford <richard.sandiford@arm.com>
7308
7309 * c-common.c (shorten_compare): Use wi::to_wide.
7310
e7ff0319
CP
73112016-04-29 Cesar Philippidis <cesar@codesourcery.com>
7312
7313 PR middle-end/70626
7314 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
7315 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
7316 reduction clauses in acc parallel loops.
7317
2fff3db8
MP
73182016-04-29 Marek Polacek <polacek@redhat.com>
7319
7320 PR c/70852
7321 * c-common.c (warn_for_memset): Check domain before accessing it.
7322
509063eb
DV
73232016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
7324
7325 PR/69089
7326 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
7327 "aligned" attribute.
7328
b632761d
JM
73292016-04-28 Jason Merrill <jason@redhat.com>
7330
7331 * c-lex.c (c_common_has_attribute): Handle nodiscard.
7332
174f6622
ES
73332016-04-28 Eduard Sanou <dhole@openmailbox.org>
7334 Matthias Klose <doko@debian.org>
7335
7336 * c-common.c (get_source_date_epoch): New function, gets the environment
7365279f 7337 variable SOURCE_DATE_EPOCH and parses it as long long with error
174f6622
ES
7338 handling.
7339 * c-common.h (get_source_date_epoch): Prototype.
7340 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
7341
6bc2bb18
RB
73422015-04-27 Ryan Burn <contact@rnburn.com>
7343
7344 PR c++/69024
7345 PR c++/68997
7346 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
7347 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
7348 external linkage.
7349 (cilk_detect_and_unwrap): Corresponding changes.
7350 (extract_free_variables): Don't extract free variables from
7351 AGGR_INIT_EXPR slot.
7352 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
7353 (cilk_recognize_spawn): Likewise.
7354
c1e1f433
BS
73552016-04-27 Bernd Schmidt <bschmidt@redhat.com>
7356
7357 * c.opt (Wmemset-elt-size): New option.
7358 * c-common.c (warn_for_memset): New function.
7359 * c-common.h (warn_for_memset): Declare.
7360
d067e05f
JM
73612016-04-25 Jason Merrill <jason@redhat.com>
7362
7363 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
7364 No longer static.
7365 * c-common.h: Declare it.
7366 * c-lex.c (c_common_has_attribute): Add maybe_unused.
7367
9aa36ae5
JM
73682016-04-22 Jason Merrill <jason@redhat.com>
7369
7370 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
7371
477d4906
IV
73722016-04-20 Ilya Verbin <ilya.verbin@intel.com>
7373
7374 PR c++/69363
7375 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
7376 * c-common.h (c_finish_cilk_clauses): Remove declaration.
7377
fe37c7af
MM
73782016-04-18 Michael Matz <matz@suse.de>
7379
7380 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
7381 and SET_DECL_ALIGN.
7382
23f2660f
EB
73832016-04-17 Eric Botcazou <ebotcazou@adacore.com>
7384
7385 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
7386 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
7387 to incomplete types.
7388 (dump_nested_type): Remove redundant tests and tidy up.
7389 (print_ada_declaration): Also set TREE_VISITED on the declaration of
7390 a type which is the typedef of an original type.
7391
1e77281b
MP
73922016-04-15 Marek Polacek <polacek@redhat.com>
7393
7394 PR c/70651
7395 * c-common.c (build_va_arg): Change two asserts into errors and return
7396 error_mark_node.
7397
b3a77f21
MP
73982016-04-13 Marek Polacek <polacek@redhat.com>
7399
7400 PR c++/70639
7401 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
7402 for switch statements, too.
7403
322b8466
JM
74042016-03-28 Jason Merrill <jason@redhat.com>
7405
7406 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
7407
fbdb6baf
MP
74082016-03-23 Marek Polacek <polacek@redhat.com>
7409
7410 PR c++/69884
7411 * c.opt (Wignored-attributes): New option.
7412
5c240f4d
DM
74132016-03-22 David Malcolm <dmalcolm@redhat.com>
7414
7415 PR c/69993
7416 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
7417 diagnostic text, reversing the order of the warning and note so
7418 that they appear in source order.
7419
14ba7b28
MP
74202016-03-17 Marek Polacek <polacek@redhat.com>
7421
7422 PR c/69407
7423 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
7424 operations.
7425
08a1cadc
JM
74262016-03-14 Jason Merrill <jason@redhat.com>
7427
2aaeea19
JM
7428 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
7429
08a1cadc
JM
7430 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
7431
c06d25bb
RB
74322016-03-09 Richard Biener <rguenther@suse.de>
7433
7434 PR c/70143
7435 * c-common.c (strict_aliasing_warning): Add back
7436 alias_sets_conflict_p check.
7437
80aac5c8
JM
74382016-03-08 Jason Merrill <jason@redhat.com>
7439
7440 * c-opts.c (set_std_cxx1z): Don't enable concepts.
7441
64b23c13
DM
74422016-03-04 David Malcolm <dmalcolm@redhat.com>
7443
7444 PR c/68187
7445 * c-indentation.c (get_visual_column): Move code to determine next
7446 tab stop to...
7447 (next_tab_stop): ...this new function.
7448 (line_contains_hash_if): Delete function.
7449 (detect_preprocessor_logic): Delete function.
7450 (get_first_nws_vis_column): New function.
7451 (detect_intervening_unindent): New function.
7452 (should_warn_for_misleading_indentation): Replace call to
7453 detect_preprocessor_logic with a call to
7454 detect_intervening_unindent.
7455
729526f5
DM
74562016-03-04 David Malcolm <dmalcolm@redhat.com>
7457
7458 PR c/68187
7459 * c-indentation.c (should_warn_for_misleading_indentation): When
7460 suppressing warnings about cases where the guard and body are on
7461 the same column, only use the first non-whitespace column in place
7462 of the guard token column when dealing with "else" clauses.
7463 When rejecting aligned BODY and NEXT, loosen the requirement
7464 from equality with the first non-whitespace of guard to simply
7465 that they not be indented relative to it.
7466
e9a35493
RB
74672016-03-04 Richard Biener <rguenther@suse.de>
7468
7469 PR c++/70054
7470 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
7471 instead of alias_sets_conflict_p.
7472
1be56bc5
MP
74732016-03-01 Marek Polacek <polacek@redhat.com>
7474
7475 PR c++/69795
7476 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
7477 any DECL.
7478
35886f0b
MS
74792016-02-22 Martin Sebor <msebor@redhat.com>
7480
7481 PR middle-end/69780
7482 * c-common.c (check_builtin_function_arguments): Validate and
7483 reject invalid arguments to __builtin_alloca_with_align.
7484
4246c8da
MW
74852016-02-20 Mark Wielaard <mjw@redhat.com>
7486
7487 PR c/28901
7488 * c.opt (Wunused-const-variable): Turn into Alias for...
7489 (Wunused-const-variable=): New option.
7490
268be88c
BE
74912016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
7492
7493 PR c++/69865
7494 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
7495 here...
7496 (c_common_init_options): ...to here.
7497 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
7498
871b3f47
JJ
74992016-02-19 Jakub Jelinek <jakub@redhat.com>
7500
7501 PR c++/69826
7502 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
7503 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
7504 flag_preprocess_only.
7505
bf14eba2
JJ
75062016-02-16 Jakub Jelinek <jakub@redhat.com>
7507
7508 PR c/69835
7509 * c.opt (Wnonnull-compare): Enable for -Wall.
7510
ba6b3795
JJ
75112016-02-15 Jakub Jelinek <jakub@redhat.com>
7512
7513 PR c++/69797
7514 * c-common.c (sync_resolve_size): Diagnose too few arguments
7515 even when params is non-NULL empty vector.
7516
a011cd92
BS
75172016-02-08 Bernd Schmidt <bschmidt@redhat.com>
7518
7519 PR target/60410
7520 * c.opt (fshort-double): Remove.
7521
46cb9332
MS
75222016-02-05 Martin Sebor <msebor@redhat.com>
7523
7524 PR c++/69662
7525 * c.opt (Warning options): Update -Wplacement-new to take
7526 an optional argument.
7527
e1b81f2b
JJ
75282016-02-01 Jakub Jelinek <jakub@redhat.com>
7529
7530 PR preprocessor/69543
7531 PR c/69558
7532 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
7533 instead of loc to control_warning_option.
7534
b6adbb9f
NS
75352016-02-01 Nathan Sidwell <nathan@codesourcery.com>
7536
7537 * c.opt (fopenacc-dim=): New option.
7538
5d70666e
RB
75392016-01-27 Ryan Burn <contact@rnburn.com>
7540
7541 PR cilkplus/69267
7542 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
7543 gimplify_arg. Removed superfluous post_p argument.
7544 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
7545 superfluous post_p argument.
7546 * c-gimplify.c (c_gimplify_expr): Likewise.
7547
01e1dea3
DM
75482016-01-26 David Malcolm <dmalcolm@redhat.com>
7549
7550 PR other/69006
7551 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
7552 pp_newline_and_flush with pp_flush.
7553
9f04a53e
MS
75542016-01-20 Martin Sebor <msebor@redhat.com>
7555
7556 PR c/69405
7557 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
7558 an incompatible argument when the argument isn't a valid tree node.
7559
7f26f7df
JM
75602016-01-18 Jason Merrill <jason@redhat.com>
7561
7562 PR c++/68767
7563 * c-common.c (check_function_arguments_recurse): Fold the whole
7564 COND_EXPR, not just the condition.
7565
f62bf092
TV
75662016-01-18 Tom de Vries <tom@codesourcery.com>
7567
7568 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
7569 classify as loop clause.
7570
e0a575ff
JJ
75712016-01-15 Jakub Jelinek <jakub@redhat.com>
7572
7573 PR bootstrap/68271
7574 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
7575 C++ FE no longer has limit on number of pragmas.
7576
75772015-01-14 Ryan Burn <contact@rnburn.com>
b6e3db06
RB
7578
7579 PR c++/69048
7580 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
c47eaca6 7581 to add missing cleanup point.
b6e3db06 7582
c7df95d8
DM
75832016-01-14 David Malcolm <dmalcolm@redhat.com>
7584
7585 PR c++/68819
7586 * c-indentation.c (get_visual_column): Add location_t param.
7587 Handle the column number being zero by effectively disabling the
7588 warning, with an "inform".
7589 (should_warn_for_misleading_indentation): Add location_t argument
7590 for all uses of get_visual_column.
7591
21efdd80
PP
75922016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
7593
7594 PR c++/69029
7595 * c-indentation.c (should_warn_for_misleading_indentation):
7596 Don't warn about do-while statements.
7597
7a127fa7
MS
75982016-01-07 Martin Sebor <msebor@redhat.com>
7599
7600 PR c/68966
7601 * c-common.c (sync_resolve_size): Reject first argument when it's
7602 a pointer to _Bool.
7603
c589e975
DM
76042016-01-05 David Malcolm <dmalcolm@redhat.com>
7605
7606 PR c/69122
7607 * c-indentation.c (get_visual_column): Remove default argument.
7608 (should_warn_for_misleading_indentation): For the multiline case,
7609 update call to get_visual_column for next_stmt_exploc so that it
7610 captures the location of the first non-whitespace character in the
7611 relevant line. Don't issue warnings if there is non-whitespace
7612 before the next statement.
7613
818ab71a
JJ
76142016-01-04 Jakub Jelinek <jakub@redhat.com>
7615
7616 Update copyright years.
7617
745e411d
DM
76182015-12-21 David Malcolm <dmalcolm@redhat.com>
7619
7620 * c-common.c (binary_op_error): Convert first param from
7621 location_t to rich_location * and use it when emitting an error.
7622 * c-common.h (binary_op_error): Convert first param from
7623 location_t to rich_location *.
7624
de67c4c3
DM
76252015-12-16 David Malcolm <dmalcolm@redhat.com>
7626
7627 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
7628 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
7629
4a38b02b
IV
76302015-12-15 Ilya Verbin <ilya.verbin@intel.com>
7631
7632 * c-common.c (c_common_attribute_table): Handle "omp declare target
7633 link" attribute.
7634
54d62f51
JJ
76352015-12-14 Jakub Jelinek <jakub@redhat.com>
7636
7637 PR c/68833
7638 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
7639
8d4227c8
TB
76402014-12-12 Tobias Burnus <burnus@net-b.de>
7641
7642 PR fortran/68815
7643 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
7644 specifiers (%d, %i,%u and %c).
7645
f6069ccc
DM
76462015-12-10 David Malcolm <dmalcolm@redhat.com>
7647
7648 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
7649
63bbf46d
JJ
76502015-12-08 Jakub Jelinek <jakub@redhat.com>
7651
7652 PR c/48088
7653 PR c/68657
7654 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
7655 * c-pragma.c (handle_pragma_diagnostic): Adjust
7656 control_warning_option caller.
7657
f79520bb
DM
76582015-12-07 David Malcolm <dmalcolm@redhat.com>
7659
7660 * c-common.c (c_cpp_error): Update for change to
7661 rich_location::set_range.
7662
b3d5bc62
JJ
76632015-12-04 Paolo Bonzini <bonzini@gnu.org>
7664
7665 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
7666 shifting 1 out of the sign bit.
7667
76682015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
7669
7670 * c-common.c (c_common_attribute_table[]): Update max arguments
7671 count for "simd" attribute.
7672 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
7673
6eb4a537
JJ
76742015-12-03 Jakub Jelinek <jakub@redhat.com>
7675
7676 PR preprocessor/57580
7677 * c-ppoutput.c (print): Change printed field to bool.
7678 Move src_file last for smaller padding.
7679 (init_pp_output): Set print.printed to false instead of 0.
7680 (scan_translation_unit): Fix up formatting. Set print.printed
7681 to true after printing something other than newline.
7682 (scan_translation_unit_trad): Set print.printed to true instead of 1.
7683 (maybe_print_line_1): Set print.printed to false instead of 0.
7684 (print_line_1): Likewise.
7685 (do_line_change): Set print.printed to true instead of 1.
7686 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
7687 dump_macro): Set print.printed to false after printing newline.
7688
4250754e
JM
76892015-12-02 Jason Merrill <jason@redhat.com>
7690
f479b43d
JM
7691 * c-common.c (fold_for_warn): New.
7692 (warn_logical_operator, warn_tautological_cmp)
7693 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
7694
4250754e
JM
7695 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
7696 (c_fully_fold_internal, decl_constant_value_for_optimization):
7697 Move to c/c-fold.c.
7698 * c-common.h: Don't declare decl_constant_value_for_optimization.
7699
e9e32ee6
JM
77002015-12-02 Joseph Myers <joseph@codesourcery.com>
7701
7702 PR c/68162
7703 * c-common.h (c_build_qualified_type): Add extra default
7704 arguments.
7705
37d5ad46
JB
77062015-12-01 Julian Brown <julian@codesourcery.com>
7707 Cesar Philippidis <cesar@codesourcery.com>
7708 James Norris <James_Norris@mentor.com>
7709
7710 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
7711 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
7712 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
7713
f07862c7
EB
77142015-11-30 Eric Botcazou <ebotcazou@adacore.com>
7715
7716 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
7717 (decl_sloc_common): Delete and move bulk of processing to...
7718 (decl_sloc): ...here.
7719 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
7720 (dump_ada_double_name): Remove S parameter and compute the suffix.
7721 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
7722 element type and deal with an anonymous one.
7723 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
7724 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
7725 and remove reference to QUAL_UNION_TYPE.
7726 (dump_nested_types): Make 2 passes on the fields and move bulk to...
7727 (dump_nested_type): ...here. New function extracted from above.
7728 Generate a full declaration for anonymous element type of arrays.
7729 (print_ada_declaration): Really skip anonymous declarations. Remove
7730 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
7731 Clean up processing of declarations of array types and objects.
7732 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
7733 Remove obsolete code and tidy up.
7734
75c8aac3
JH
77352015-11-29 Jan Hubicka <hubicka@ucw.cz>
7736
7737 PR c/67581
7738 * c-common.c (handle_transparent_union_attribute): Update
7739 also type variants.
7740
b58d3df2
ML
77412015-11-27 Martin Liska <mliska@suse.cz>
7742
7743 PR c++/68312
7744 * array-notation-common.c (cilkplus_extract_an_triplets):
7745 Release vector of vectors.
7746 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
7747
89a01fcf
EB
77482015-11-26 Eric Botcazou <ebotcazou@adacore.com>
7749
7750 PR c++/68527
7751 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
7752 (print_ada_struct_decl): Likewise.
7753
cc5c5226
IZ
77542015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
7755
7756 PR c++/68001
7757 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
7758 * cilk.c (recognize_spawn): Determine location in a more precise
7759 way.
7760
269adb9d
JM
77612015-11-19 Jason Merrill <jason@redhat.com>
7762
7763 * c-common.c (shorten_compare): But look through macros from
7764 system headers.
7765
d0eccfcd
JM
77662015-11-18 Jason Merrill <jason@redhat.com>
7767
7768 * c-common.c (shorten_compare): Don't -Wtype-limits if the
7769 non-constant operand comes from a macro.
7770
3e44547c
JM
77712015-11-17 Jason Merrill <jason@redhat.com>
7772
7773 PR bootstrap/68346
7774 * c-common.c (warn_tautological_cmp): Fold before checking for
7775 constants.
7776
0f62c7a0
MP
77772015-11-16 Marek Polacek <polacek@redhat.com>
7778
7779 PR c++/68362
7780 * c-common.c (check_case_bounds): Fold low and high cases.
7781
a868811e
MP
77822015-11-16 Marek Polacek <polacek@redhat.com>
7783
7784 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
7785 * c-common.c (c_common_get_alias_set): Likewise.
7786 (handle_visibility_attribute): Likewise.
7787
fff77217
KY
77882015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
7789
7790 * c-common.c (handle_simd_attribute): New.
7791 (struct attribute_spec): Add entry for "simd".
7792 (handle_simd_attribute): New.
7793
269e63b7
KT
77942015-11-13 Kai Tietz <ktietz70@googlemail.com>
7795
7796 * c-lex.c (interpret_float): Use fold_convert.
7797
ebedc9a3
DM
77982015-11-13 David Malcolm <dmalcolm@redhat.com>
7799
7800 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
7801 and store it on the result.
7802 * c-opts.c (c_common_init_options): Set
7803 global_dc->colorize_source_p.
7804
6e232ba4
JN
78052015-11-12 James Norris <jnorris@codesourcery.com>
7806 Joseph Myers <joseph@codesourcery.com>
7807
7365279f 7808 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
6e232ba4
JN
7809 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
7810 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
7811 PRAGMA_OACC_CLAUSE_LINK.
7812
e78bede6
MP
78132015-11-11 Marek Polacek <polacek@redhat.com>
7814
7815 PR c/68107
7816 PR c++/68266
7817 * c-common.c (valid_array_size_p): New function.
7818 * c-common.h (valid_array_size_p): Declare.
7819
3f8257db 78202015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4ac93c7c
DH
7821
7822 PR bootstrap/68271
7823 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
7824
69f293c9
AM
78252015-11-11 Andrew MacLeod <amacleod@redhat.com>
7826
7827 * array-notation-common.c: Remove unused header files.
7828 * c-ada-spec.c: Likewise.
7829 * c-cilkplus.c: Likewise.
7830 * c-common.c: Likewise.
7831 * c-cppbuiltin.c: Likewise.
7832 * c-dump.c: Likewise.
7833 * c-format.c: Likewise.
7834 * c-gimplify.c: Likewise.
7835 * c-indentation.c: Likewise.
7836 * c-lex.c: Likewise.
7837 * c-omp.c: Likewise.
7838 * c-opts.c: Likewise.
7839 * c-pch.c: Likewise.
7840 * c-ppoutput.c: Likewise.
7841 * c-pragma.c: Likewise.
7842 * c-pretty-print.c: Likewise.
7843 * c-semantics.c: Likewise.
7844 * c-ubsan.c: Likewise.
7845 * cilk.c: Likewise.
7846 * stub-objc.c: Likewise.
7847
3a40d81d
NS
78482015-11-09 Thomas Schwinge <thomas@codesourcery.com>
7849 Cesar Philippidis <cesar@codesourcery.com>
7850 James Norris <jnorris@codesourcery.com>
7851 Julian Brown <julian@codesourcery.com>
7852 Nathan Sidwell <nathan@codesourcery.com>
7853
7854 * c-pragma.c (oacc_pragmas): Add "routine".
7855 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
7856
ee45a32d
EB
78572015-11-08 Eric Botcazou <ebotcazou@adacore.com>
7858
7859 * c-common.c (c_common_attributes): Add scalar_storage_order.
7860 (handle_scalar_storage_order_attribute): New function.
7861 * c-pragma.c (global_sso): New variable.
7862 (maybe_apply_pragma_scalar_storage_order): New function.
7863 (handle_pragma_scalar_storage_order): Likewise.
7864 (init_pragma): Register scalar_storage_order.
7865 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
7866 * c.opt (Wscalar-storage-order): New warning.
7867 (fsso-struct=): New option.
7868
eb11eb15
MS
78692015-11-08 Martin Sebor <msebor@redhat.com>
7870
7871 * c.opt (Wplacement-new): Add a period to the end of a sentence.
7872
0aad0198
RS
78732015-11-07 Richard Sandiford <richard.sandiford@arm.com>
7874
7875 * c-common.c: Don't undef DEF_BUILTIN.
7876
8a645150
DM
78772015-11-06 David Malcolm <dmalcolm@redhat.com>
7878
7879 * c-common.c (c_cpp_error): Convert parameter from location_t to
7880 rich_location *. Eliminate the "column_override" parameter and
7881 the call to diagnostic_override_column.
7882 Update the "done_lexing" clause to set range 0
7883 on the rich_location, rather than overwriting a location_t.
7884 * c-common.h (c_cpp_error): Convert parameter from location_t to
7885 rich_location *. Eliminate the "column_override" parameter.
7886
7a5e4956
CP
78872015-11-05 Cesar Philippidis <cesar@codesourcery.com>
7888 Thomas Schwinge <thomas@codesourcery.com>
7889 James Norris <jnorris@codesourcery.com>
7890
7891 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
7892 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
7893 clauses with parallel and kernels and loops.
7894 * c-pragma.h (enum pragma_omp_clause): Add entries for
7895 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
7896 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
7897 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
7898 INDEPENDENT,SEQ}.
7899 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
7900
e2f5cc96
MS
79012015-11-05 Martin Sebor <msebor@redhat.com>
7902
7903 PR c++/67942
7904 * c.opt (-Wplacement-new): New option.
7905
e01d41e5
JJ
79062015-11-05 Jakub Jelinek <jakub@redhat.com>
7907
7908 * c-common.h (c_finish_omp_atomic): Add TEST argument.
7909 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
7910 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
7911 save_expr or create_tmp_var* if TEST is true.
7912 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
7913 Don't call add_stmt here.
7914 (struct c_omp_check_loop_iv_data): New type.
7915 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
7916 c_omp_check_loop_iv_exprs): New functions.
7917 (c_omp_split_clauses): Adjust for lastprivate being allowed on
7918 distribute.
7919 (c_omp_declare_simd_clauses_to_numbers): Change
7920 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
7921 (c_omp_declare_simd_clauses_to_decls): Similarly change those
7922 from numbers to PARM_DECLs.
7923
595278be
MM
79242015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
7925
7926 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
7927 flag_checking.
7928
3f8257db 79292015-11-03 Bernd Schmidt <bschmidt@redhat.com>
c85158de
MS
7930
7931 PR c++-common/67882
b3d5bc62
JJ
7932 * c-common.h (fold_offsetof_1): Add argument.
7933 * c-common.c (fold_offsetof_1): Diagnose more invalid
c85158de
MS
7934 offsetof expressions that reference elements past the end of
7935 an array.
7936
4bf9e5a8
TS
79372015-11-03 Thomas Schwinge <thomas@codesourcery.com>
7938 Chung-Lin Tang <cltang@codesourcery.com>
7939
7940 * c-pragma.c (oacc_pragmas): Add "atomic".
7941 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
7942
3b1661a9
ES
79432015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
7944
7945 * c-common.c (handle_target_clones_attribute): New.
7946 (c_common_attribute_table): Add handle_target_clones_attribute.
7947 (handle_always_inline_attribute): Add check on target_clones attribute.
7948 (handle_target_attribute): Ditto.
7949
2adfab87
AM
79502015-10-29 Andrew MacLeod <amacleod@redhat.com>
7951
7952 * array-notation-common.c: Reorder #include's and remove duplicates.
7953 * c-ada-spec.c: Likewise.
7954 * c-cilkplus.c: Likewise.
7955 * c-common.c: Likewise.
7956 * c-cppbuiltin.c: Likewise.
7957 * c-dump.c: Likewise.
7958 * c-format.c: Likewise.
7959 * c-gimplify.c: Likewise.
7960 * c-indentation.c: Likewise.
7961 * c-lex.c: Likewise.
7962 * c-omp.c: Likewise.
7963 * c-opts.c: Likewise.
7964 * c-pch.c: Likewise.
7965 * c-ppoutput.c: Likewise.
7966 * c-pragma.c: Likewise.
7967 * c-pretty-print.c: Likewise.
7968 * c-semantics.c: Likewise.
7969 * c-ubsan.c: Likewise.
7970 * cilk.c: Likewise.
7971 * stub-objc.c: Likewise.
7972
d90ec4f2
JM
79732015-10-28 Jason Merrill <jason@redhat.com>
7974
7975 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
7976
88bae6f4
TS
79772015-10-27 Thomas Schwinge <thomas@codesourcery.com>
7978 James Norris <jnorris@codesourcery.com>
7979 Cesar Philippidis <cesar@codesourcery.com>
7980
7981 PR c/64765
7982 PR c/64880
7983 * c-common.h (c_oacc_split_loop_clauses): Declare function.
7984 * c-omp.c (c_oacc_split_loop_clauses): New function.
7985
b1726d6c
MS
79862015-10-21 Martin Sebor <msebor@redhat.com>
7987
7988 PR driver/68043
7989 * c.opt: End each sentence that describes an option with a period.
7990
fa60eeb9
MP
79912015-10-20 Marek Polacek <polacek@redhat.com>
7992
7993 * array-notation-common.c (is_cilkplus_vector_p): Define.
7994 * c-common.h (is_cilkplus_vector_p): Declare.
7995
95979049
MP
79962015-10-20 Marek Polacek <polacek@redhat.com>
7997
7998 * c.opt (std=gnu++11): Do not describe as experimental.
7999 (std=gnu++14): Likewise.
8000
2a9fb712
JM
80012015-10-19 Jason Merrill <jason@redhat.com>
8002
8003 * c-cppbuiltin.c (c_cpp_builtins): Define
8004 __cpp_nontype_template_args.
8005
13b380a3
JM
80062015-10-19 Jason Merrill <jason@redhat.com>
8007
8008 * c-cppbuiltin.c (c_cpp_builtins): Define
8009 __cpp_enumerator_attributes, __cpp_fold_expressions,
8010 __cpp_unicode_characters.
8011
d9a6bd32
JJ
80122015-10-13 Jakub Jelinek <jakub@redhat.com>
8013 Aldy Hernandez <aldyh@redhat.com>
8014
8015 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
8016 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
8017 (c_define_builtins): Likewise.
8018 * c-common.h (enum c_omp_clause_split): Add
8019 C_OMP_CLAUSE_SPLIT_TASKLOOP.
8020 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
8021 (c_finish_omp_for): Add ORIG_DECLV argument.
8022 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
8023 201511 instead of 201307.
8024 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
8025 OMP_CRITICAL_CLAUSES to it.
8026 (c_finish_omp_ordered): Add CLAUSES argument, set
8027 OMP_ORDERED_CLAUSES to it.
8028 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
8029 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
8030 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
8031 constructs and new OpenMP 4.5 clauses. Clear
8032 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
8033 verification code.
8034 * c-pragma.c (omp_pragmas_simd): Add taskloop.
8035 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
8036 (enum pragma_omp_clause): Add
8037 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
8038 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
8039
624d31fe
RS
80402015-10-05 Richard Sandiford <richard.sandiford@arm.com>
8041
8042 * c-lex.c (interpret_float): Use real_equal instead of
8043 REAL_VALUES_EQUAL.
8044
b8fd7909
JM
80452015-10-04 Jason Merrill <jason@redhat.com>
8046
8047 Implement N4514, C++ Extensions for Transactional Memory.
8048 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
8049 (c_common_attribute_table): Add transaction_safe_dynamic.
8050 transaction_safe now affects type identity.
8051 (handle_tm_attribute): Handle transaction_safe_dynamic.
8052 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
8053 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
8054 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
8055 (D_TRANSMEM): New.
8056 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
8057 * c-pretty-print.c (pp_c_attributes_display): Don't print
8058 transaction_safe in C++.
8059
12651878
MP
80602015-10-02 Marek Polacek <polacek@redhat.com>
8061
8062 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
8063
3e3b8d63
MP
80642015-10-02 Marek Polacek <polacek@redhat.com>
8065
8066 PR c/64249
8067 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
8068 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
8069 * c.opt (Wduplicated-cond): New option.
8070
0d1a8f75
JM
80712015-10-01 Joseph Myers <joseph@codesourcery.com>
8072
8073 * c.opt (std=c11): Do not describe as experimental.
8074 (std=gnu11): Likewise.
8075 (std=iso9899:2011): Likewise.
8076
3e32ee19
NS
80772015-09-28 Nathan Sidwell <nathan@codesourcery.com>
8078
8079 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
8080 (DEF_FUNCTION_TYPE_VAR_11): Delete.
8081
974348ee
MP
80822015-09-25 Marek Polacek <polacek@redhat.com>
8083
8084 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
8085 (ubsan_instrument_shift): Likewise.
8086
15dbc1a6
MP
80872015-09-25 Marek Polacek <polacek@redhat.com>
8088
8089 PR sanitizer/64906
8090 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
8091
6b95d7cc
PP
80922015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
8093
8094 * c-indentation.c (should_warn_for_misleading_indentation):
8095 Compare next_stmt_vis_column with guard_line_first_nws instead
8096 of with guard_line_vis_column.
8097
c1822f9c
MLI
80982015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
8099
8100 PR c/49654
8101 PR c/49655
8102 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
8103 options and options not valid for the current language.
8104
d5398058
PP
81052015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
8106
8107 * c-indentation.c (should_warn_for_misleading_indentation):
8108 Float out and consolidate the calls to get_visual_column that
8109 are passed guard_exploc as an argument. Compare
8110 next_stmt_vis_column with guard_line_first_nws instead of with
8111 body_line_first_nws.
8112
6b333269
NS
81132015-09-22 Nathan Sidwell <nathan@codesourcery.com>
8114
8115 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
8116 Wnamespaces): New C++ warnings.
8117
a75f1574
JM
81182015-09-22 Jason Merrill <jason@redhat.com>
8119
8120 * c-common.h (abi_compat_version_crosses): New.
8121 (warn_abi_version): Declare.
8122 * c-common.c: Define it.
8123 * c-opts.c (c_common_post_options): Handle it.
8124 flag_abi_compat_version defaults to 8.
8125
bdaaa8b7
VV
81262015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
8127
8128 Complete the implementation of N4230, Nested namespace definition.
8129 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
8130 __cpp_nested_namespace_definitions.
8131
eaa797e8
MLI
81322015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
8133
8134 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
8135
c4914de6
MLI
81362015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
8137
8138 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
8139 when warning.
8140 * c-pragma.h (pragma_lex): Add optional loc argument.
8141
fcb87c50
MM
81422015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
8143
8144 * c-format.c (check_format_arg): Adjust to use common block size in all
8145 object pools.
8146
31bdd08a
DM
81472015-09-15 David Malcolm <dmalcolm@redhat.com>
8148
8149 * c-format.c (location_from_offset): Update for change in
8150 signature of location_get_source_line.
8151 * c-indentation.c (get_visual_column): Likewise.
8152 (line_contains_hash_if): Likewise.
8153
aa9f4b4c
MP
81542015-09-14 Marek Polacek <polacek@redhat.com>
8155
8156 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
8157 setting various warnings.
8158
aa256c4a
MP
81592015-09-14 Marek Polacek <polacek@redhat.com>
8160
8161 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
8162 a negative value.
8163
0f876f22
MW
81642015-09-11 Mark Wielaard <mjw@redhat.com>
8165
8166 PR c/28901
8167 * c.opt (Wunused-variable): Option from common.opt.
8168 (Wunused-const-variable): New option.
8169
273aa49e
PC
81702015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
8171
8172 PR c++/53184
8173 * c.opt ([Wsubobject-linkage]): Add.
8174
1807ffc1
MS
81752015-09-03 Martin Sebor <msebor@redhat.com>
8176
8177 PR c/66516
8178 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
8179 functions.
8180 * c-common.c (reject_gcc_builtin): Define.
8181
38942840
BI
81822015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
8183
8184 PR middle-end/60586
8185 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
8186 prototype.
8187 * c-gimplify.c (c_gimplify_expr): Added a call to the function
8188 cilk_gimplify_call_params_in_spawned_fn.
8189 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
8190 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
8191 unwrapping.
8192
c316b5e4
MP
81932015-08-25 Marek Polacek <polacek@redhat.com>
8194
8195 PR middle-end/67330
8196 * c-common.c (handle_weak_attribute): Don't check whether the
8197 visibility can be changed here.
8198
584a7c46
MLI
81992015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
8200
8201 * c-lex.c (c_lex_with_flags): Use explicit locations.
8202
a79683d5
TS
82032015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
8204
8205 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
8206 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
8207
61717a45
FXC
82082015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
8209
8210 PR middle-end/36757
8211 * c-common.c (check_builtin_function_arguments): Add check
8212 for BUILT_IN_SIGNBIT argument.
8213
329524f5
PC
82142015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
8215
8216 PR c++/67160
8217 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
8218 in c++1z mode.
8219
4ee55665
MP
82202015-08-17 Marek Polacek <polacek@redhat.com>
8221
8222 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
8223 with whitespaces before qualifier names.
8224
b893e375
MP
82252015-08-12 Marek Polacek <polacek@redhat.com>
8226
8227 PR c++/55095
8228 * c-common.c (maybe_warn_shift_overflow): Properly handle
8229 left-shifting 1 into the sign bit.
8230
c2d89095
MLI
82312015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
8232
8233 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
8234
971e17ff
AS
82352015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
8236 Braden Obrzut <admin@maniacsvault.net>
8237 Jason Merrill <jason@redhat.com>
8238
8239 Add C++ Concepts TS support.
8240 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
8241 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
8242 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
8243 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
8244 * c-opts.c (set_std_cxx1z): Set flag_concepts.
8245 * c.opt (fconcepts): New.
8246
b3d5bc62
JJ
82472015-08-02 Martin Sebor <msebor@redhat.com>
8248
8249 * c.opt (-Wframe-address): New warning option.
8250
8ebca419
PP
82512015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
8252
8253 * c-indentation.c (should_warn_for_misleading_indentation):
8254 Improve heuristics.
8255
1a1e101f
PP
82562015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
8257
8258 * c-indentation.c (get_visual_column): Add parameter first_nws,
8259 use it. Update comment documenting the function.
8260 (is_first_nonwhitespace_on_line): Remove.
8261 (should_warn_for_misleading_indentation): Replace usage of
8262 of is_first_nonwhitespace_on_line with get_visual_column.
8263
992118a1
PP
82642015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
8265
8266 * c-indentation.h (struct token_indent_info): Define.
8267 (get_token_indent_info): Define.
8268 (warn_for_misleading_information): Declare.
8269 * c-common.h (warn_for_misleading_information): Remove.
8270 * c-identation.c (warn_for_misleading_indentation):
8271 Change declaration to take three token_indent_infos. Adjust
8272 accordingly.
8273 * c-identation.c (should_warn_for_misleading_indentation):
8274 Likewise. Bail out early if the body is a compound statement.
8275 (guard_tinfo_to_string): Define.
8276
e8fa3817
JM
82772015-07-30 Jason Merrill <jason@redhat.com>
8278
8279 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
8280 '*' for reference decay.
8281
173864e8
MP
82822015-07-30 Marek Polacek <polacek@redhat.com>
8283
8284 * c-common.c (warn_tautological_cmp): Bail for float types.
8285
f2afe6dd
MP
82862015-07-27 Marek Polacek <polacek@redhat.com>
8287
8288 PR bootstrap/67030
8289 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
8290
05b28fd6
MP
82912015-07-27 Marek Polacek <polacek@redhat.com>
8292
8293 PR c++/66555
8294 PR c/54979
8295 * c-common.c (find_array_ref_with_const_idx_r): New function.
8296 (warn_tautological_cmp): New function.
8297 * c-common.h (warn_tautological_cmp): Declare.
8298 * c.opt (Wtautological-compare): New option.
8299
5a5062b8
MP
83002015-07-23 Marek Polacek <polacek@redhat.com>
8301
8302 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
8303 (ubsan_instrument_shift): Likewise.
8304
dc891fe7
MP
83052015-07-23 Marek Polacek <polacek@redhat.com>
8306
8307 PR sanitizer/66908
8308 * c-ubsan.c: Include gimplify.h.
8309 (ubsan_instrument_division): Unshare OP0 and OP1.
8310 (ubsan_instrument_shift): Likewise.
8311
451b5e48
MP
83122015-07-20 Marek Polacek <polacek@redhat.com>
8313 Richard Sandiford <richard.sandiford@arm.com>
8314
8315 PR c++/55095
8316 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
8317 Use EXPR_LOC_OR_LOC.
8318 (maybe_warn_shift_overflow): New function.
8319 * c-common.h (maybe_warn_shift_overflow): Declare.
8320 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
8321 * c.opt (Wshift-overflow): New option.
8322
fb0b2914
ML
83232015-07-16 Martin Liska <mliska@suse.cz>
8324
8325 * c-format.c (static void check_format_info_main): Use
8326 object_allocator instead of pool_allocator.
8327 (check_format_arg): Likewise.
8328 (check_format_info_main): Likewise.
8329
903f5c23
AM
83302015-07-15 Andrew MacLeod <amacleod@redhat.com>
8331
8332 * c-opts.c: Remove multiline #include comment.
8333
026c3cfd
AH
83342015-07-12 Aldy Hernandez <aldyh@redhat.com>
8335
8336 * c-common.c: Fix double word typos.
8337
bb49ee66
EB
83382015-07-10 Eric Botcazou <ebotcazou@adacore.com>
8339
8340 * c-ada-spec.h (cpp_operation): Revert latest change.
8341 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
8342 constructors and destructors.
8343
1916bcb5
AM
83442015-07-09 Andrew MacLeod <amacleod@redhat.com>
8345
8346 * c-common.h: Adjust includes for flags.h changes.
8347 * stub-objc.c: Likewise.
026c3cfd 8348
a9dcd529
EB
83492015-07-08 Eric Botcazou <ebotcazou@adacore.com>
8350
8351 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
8352 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
8353
b03b462f
JJ
83542015-07-08 Jakub Jelinek <jakub@redhat.com>
8355
8356 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
8357 are to be removed, return NULL rather than original clauses list.
8358
c7131fb2
AM
83592015-07-07 Andrew MacLeod <amacleod@redhat.com>
8360
8361 * array-notation-common.c: Adjust includes.
8362 * c-ada-spec.c: Likewise.
8363 * c-cilkplus.c: Likewise.
8364 * c-common.h: Likewise.
8365 * c-cppbuiltin.c: Likewise.
8366 * c-dump.c: Likewise.
8367 * c-format.c: Likewise.
8368 * c-gimplify.c: Likewise.
8369 * c-indentation.c: Likewise.
8370 * c-lex.c: Likewise.
8371 * c-omp.c: Likewise.
8372 * c-opts.c: Likewise.
8373 * c-pch.c: Likewise.
8374 * c-ppoutput.c: Likewise.
8375 * c-pragma.c: Likewise.
8376 * c-pretty-print.c: Likewise.
8377 * c-semantics.c: Likewise.
8378 * c-ubsan.c: Likewise.
8379 * cilk.c: Likewise.
8380 * stub-objc.c: Likewise.
8381
2a7fb83f
EB
83822015-07-07 Eric Botcazou <ebotcazou@adacore.com>
8383
8384 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
8385 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
8386
a03c9bf1
JM
83872015-07-01 Jason Merrill <jason@redhat.com>
8388
36a85135
JM
8389 * c-common.h (D_CXX11): Rename from D_CXX0X.
8390 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
8391 * c-common.c: Adjust.
8392
e7fa68d5
JM
8393 * c-opts.c (c_common_post_options): Default to C++14.
8394
a03c9bf1
JM
8395 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
8396
fe95b036
ESR
83972015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
8398
8399 Implement N4197 - Adding u8 character literals
b3d5bc62 8400 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
a64be36b 8401 CPP_CHAR.
b3d5bc62 8402 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
a64be36b 8403 CPP_UTF8CHAR_USERDEF tokens.
b3d5bc62 8404 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
a64be36b
EB
8405 and CPP_UTF8CHAR tokens.
8406 (lex_charconst): Treat CPP_UTF8CHAR token.
fe95b036 8407
da2e71c9
MLI
84082015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
8409
8410 PR fortran/66605
8411 * c-common.c (do_warn_unused_parameter): Move here.
8412 * c-common.h (do_warn_unused_parameter): Declare.
8413
b155cfd9
MP
84142015-06-29 Marek Polacek <polacek@redhat.com>
8415
8416 PR c/66322
8417 * c-common.c (check_case_bounds): Add bool * parameter. Set
8418 OUTSIDE_RANGE_P.
8419 (c_add_case_label): Add bool * parameter. Pass it down to
8420 check_case_bounds.
8421 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
8422 warning here.
8423 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
8424 declarations.
8425
31521951
MP
84262015-06-27 Marek Polacek <polacek@redhat.com>
8427
8428 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
8429 or VECTOR_INTEGER_TYPE_P throughout.
8430 * c-gimplify.c: Likewise.
8431
22d03525
MP
84322015-06-26 Marek Polacek <polacek@redhat.com>
8433
8434 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
8435 * c-common.c (c_fully_fold_internal): Likewise.
8436 (c_alignof_expr): Likewise.
8437 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
8438 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
b1726d6c 8439 * cilk.c (create_parm_list): Likewise.
22d03525 8440
af05e6e5
MP
84412015-06-26 Marek Polacek <polacek@redhat.com>
8442
8443 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
8444
f0889939
AM
84452015-06-25 Andrew MacLeod <amacleod@redhat.com>
8446
8447 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
8448 * c-gimplify.c: Likewise.
8449 * c-pragma.c: Likewise.
8450 * c-ubsan.c: Likewise.
8451 * cilk.c: Likewise.
8452
ca752f39
RS
84532015-06-25 Richard Sandiford <richard.sandiford@arm.com>
8454
8455 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
8456 ggc_hasher.
8457
16a16ec7
AM
84582015-06-25 Andrew MacLeod <amacleod@redhat.com>
8459
8460 * cilk.c: Move calls.h after tm.h in the include chain.
8461
0ae9bd27
MP
84622015-06-25 Marek Polacek <polacek@redhat.com>
8463
8464 * array-notation-common.c: Use VAR_P throughout.
8465 * c-ada-spec.c: Likewise.
8466 * c-common.c: Likewise.
8467 * c-format.c: Likewise.
8468 * c-gimplify.c: Likewise.
8469 * c-omp.c: Likewise.
8470 * c-pragma.c: Likewise.
8471 * c-pretty-print.c: Likewise.
8472 * cilk.c: Likewise.
8473
62f9079a
MP
84742015-06-25 Marek Polacek <polacek@redhat.com>
8475
8476 * cilk.c (extract_free_variables): Use is_global_var.
8477
0fa16060
RS
84782015-06-23 Richard Sandiford <richard.sandiford@arm.com>
8479
8480 * c-common.c: Don't include target-def.h.
8481
a68ae2e1
MP
84822015-06-23 Marek Polacek <polacek@redhat.com>
8483
8484 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
8485 when comparing INTEGER_CSTs.
8486
c6a2f2d9
PMR
84872015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
8488
8489 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
8490 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
8491 (dump_ada_template): Skip partially specialized types.
8492
6b4db501
MM
84932015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
8494
8495 * c-common.c (scalar_to_vector): Use std::swap instead of manually
8496 swapping.
8497
abb226c9
AM
84982015-06-17 Andrew MacLeod <amacleod@redhat.com>
8499
8500 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
8501 * c-ada-spec.c: Likewise.
8502 * c-cilkplus.c: Likewise.
8503 * c-common.c: Likewise.
8504 * c-common.h: Likewise.
8505 * c-cppbuiltin.c: Likewise.
8506 * c-dump.c: Likewise.
8507 * c-format.c: Likewise.
8508 * c-gimplify.c: Likewise.
8509 * c-indentation.c: Likewise.
8510 * c-lex.c: Likewise.
8511 * c-omp.c: Likewise.
8512 * c-opts.c: Likewise.
8513 * c-pch.c: Likewise.
8514 * c-ppoutput.c: Likewise.
8515 * c-pragma.c: Likewise.
8516 * c-pretty-print.c: Likewise.
8517 * c-semantics.c: Likewise.
8518 * c-ubsan.c: Likewise.
8519 * cilk.c: Likewise.
8520 * stub-objc.c: Likewise.
8521
076fecad
PP
85222015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
8523
8524 PR c++/65168
8525 * c-common.c (c_common_truthvalue_conversion): Warn when
8526 converting an address of a reference to a truth value.
8527
13fdf2e2
AM
85282015-06-08 Andrew MacLeod <amacleod@redhat.com>
8529
8530 * array-notation-common.c : Adjust include files.
8531 * c-ada-spec.c : Likewise.
8532 * c-cilkplus.c : Likewise.
8533 * c-common.c : Likewise.
8534 * c-common.h : Likewise.
8535 * c-cppbuiltin.c : Likewise.
8536 * c-dump.c : Likewise.
8537 * c-format.c : Likewise.
8538 * c-gimplify.c : Likewise.
8539 * c-indentation.c : Likewise.
8540 * c-lex.c : Likewise.
8541 * c-omp.c : Likewise.
8542 * c-opts.c : Likewise.
8543 * c-pch.c : Likewise.
8544 * c-ppoutput.c : Likewise.
8545 * c-pragma.c : Likewise.
8546 * c-pretty-print.c : Likewise.
8547 * c-semantics.c : Likewise.
8548 * c-ubsan.c : Likewise.
8549 * cilk.c : Likewise.
8550 * stub-objc.c : Likewise.
8551
a1661b90
MP
85522015-06-08 Marek Polacek <polacek@redhat.com>
8553
8554 PR c/66415
8555 * c-format.c (location_from_offset): Return LOC if LINE is null.
8556
d7438551
AH
85572015-06-05 Aldy Hernandez <aldyh@redhat.com>
8558
8559 * c-common.h (c_parse_final_cleanups): New prototype.
8560 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
8561
b3d5bc62
JJ
85622015-06-04 Sriraman Tallam <tmsriram@google.com>
8563
8564 * c-common.c (noplt): New attribute.
8565 (handle_noplt_attribute): New handler.
8566
ecb9f223
AM
85672015-06-04 Andrew MacLeod <amacleod@redhat.com>
8568
8569 * array-notation-common.c: Adjust includes for restructured coretypes.h.
8570 * c-ada-spec.c: Likewise.
8571 * c-cilkplus.c: Likewise.
8572 * c-common.c: Likewise.
8573 * c-common.h: Likewise.
8574 * c-cppbuiltin.c: Likewise.
8575 * c-dump.c: Likewise.
8576 * c-format.c: Likewise.
8577 * c-gimplify.c: Likewise.
8578 * c-indentation.c: Likewise.
8579 * c-lex.c: Likewise.
8580 * c-omp.c: Likewise.
8581 * c-opts.c: Likewise.
8582 * c-pch.c: Likewise.
8583 * c-ppoutput.c: Likewise.
8584 * c-pragma.c: Likewise.
8585 * c-pretty-print.c: Likewise.
8586 * c-semantics.c: Likewise.
8587 * c-ubsan.c: Likewise.
8588 * cilk.c: Likewise.
8589 * stub-objc.c: Likewise.
8590
6ac48155
DM
85912015-06-02 David Malcolm <dmalcolm@redhat.com>
8592
8593 PR c/66220:
8594 * c-indentation.c (should_warn_for_misleading_indentation): Use
8595 expand_location rather than expand_location_to_spelling_point.
8596 Don't warn if the guarding statement is more indented than the
8597 next/body stmts.
8598
773ce42e
DM
85992015-06-02 David Malcolm <dmalcolm@redhat.com>
8600
8601 * c-indentation.c (warn_for_misleading_indentation): Bail out
8602 immediately if -Wmisleading-indentation isn't enabled.
8603
4fef8379
ML
86042015-06-01 Martin Liska <mliska@suse.cz>
8605
8606 * c-format.c (check_format_arg):Use new type-based pool allocator.
8607 (check_format_info_main) Likewise.
8608
1edfb384
EB
86092015-05-31 Eric Botcazou <ebotcazou@adacore.com>
8610
8611 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
8612 (has_nontrivial_methods): Likewise.
8613
9677ef52
MP
86142015-05-25 Marek Polacek <polacek@redhat.com>
8615
8616 * c-ubsan.c (ubsan_instrument_shift): Use type0.
8617
fd5c817a
MP
86182015-05-22 Marek Polacek <polacek@redhat.com>
8619
8620 PR c/47043
8621 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
8622
a2f45fe6 86232015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
581edfa3
TS
8624
8625 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
8626 STACK_GROWS_DOWNWARD.
8627
a2f45fe6 86282015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
62f9f30b
TS
8629
8630 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
8631 STACK_GROWS_DOWNWARD rather than if it is defined.
8632
0fee2ac2 86332015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
b1726d6c 8634
0fee2ac2
MLI
8635 PR c/52952
8636 * c-format.c (location_column_from_byte_offset): New.
8637 (location_from_offset): New.
8638 (struct format_wanted_type): Add offset_loc field.
8639 (check_format_info): Move handling of location for extra arguments
8640 closer to the point of warning.
8641 (check_format_info_main): Pass the result of location_from_offset
8642 to warning_at.
8643 (format_type_warning): Pass the result of location_from_offset
8644 to warning_at.
8645
cf4ef6f7
MP
86462015-05-20 Marek Polacek <polacek@redhat.com>
8647
8648 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
8649
3a65ee74
MP
86502015-05-20 Marek Polacek <polacek@redhat.com>
8651
8652 * c-ada-spec.c (dump_sloc): Use DECL_P.
8653
21b634ae
MP
86542015-05-20 Marek Polacek <polacek@redhat.com>
8655
8656 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
8657 * c-common.c: Likewise.
8658
0e50b624
DM
86592015-05-19 David Malcolm <dmalcolm@redhat.com>
8660
8661 * c-common.h (fe_file_change): Strengthen param from
8662 const line_map * to const line_map_ordinary *.
8663 (pp_file_change): Likewise.
8664 * c-lex.c (fe_file_change): Likewise.
8665 (cb_define): Use linemap_check_ordinary when invoking
8666 SOURCE_LINE.
8667 (cb_undef): Likewise.
8668 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
8669 invoking cb_file_change.
8670 (c_finish_options): Likewise.
8671 (push_command_line_include): Likewise.
8672 (cb_file_change): Strengthen param "new_map" from
8673 const line_map * to const line_map_ordinary *.
8674 * c-ppoutput.c (cb_define): Likewise for local "map".
8675 (pp_file_change): Likewise for param "map" and local "from".
8676
fab27f52
MM
86772015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
8678
8679 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
8680
2fe1d762
TV
86812015-05-18 Tom de Vries <tom@codesourcery.com>
8682
8683 * c-common.c (build_va_arg_1): New function.
8684 (build_va_arg): Add address operator to va_list operand if necessary.
8685
7a37fa90
MM
86862015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
8687
8688 PR c/48956
8689 * c-common.c (int_safely_convertible_to_real_p): Define.
8690 (unsafe_conversion_p): Check conversions involving complex types.
8691 (conversion_warning): Add new warning message for conversions which
8692 discard imaginary component.
8693 * c-common.h: (enum conversion_safety): Add new enumerator for such
8694 conversions.
8695
3aa3c9fc
MP
86962015-05-14 Marek Polacek <polacek@redhat.com>
8697
8698 PR c/66066
8699 PR c/66127
8700 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
8701 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
8702 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
8703 use it. If FOR_INT_CONST, require that all evaluated operands be
8704 INTEGER_CSTs.
8705
c3388e62
DM
87062015-05-12 David Malcolm <dmalcolm@redhat.com>
8707
8708 * c-common.h (warn_for_misleading_indentation): New prototype.
8709 * c-indentation.c: New file.
8710 * c.opt (Wmisleading-indentation): New option.
8711
c7b38fd5
TV
87122015-05-12 Tom de Vries <tom@codesourcery.com>
8713
8714 PR tree-optimization/66010
8715 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
8716
381bf11e
JM
87172015-05-09 Jason Merrill <jason@redhat.com>
8718
edff0c06
JM
8719 * c-opts.c (c_common_post_options): Also clear
8720 cpp_opts->cpp_warn_cxx11_compat.
8721
129211bc
JM
8722 * c-common.h (enum cxx_dialect): Add cxx_unset.
8723 * c-common.c (cxx_dialect): Initialize to cxx_unset.
8724 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
8725
381bf11e
JM
8726 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
8727 (std=gnu++0x): Mark as Undocumented.
8728 (std=gnu++1y): Add deprecated message.
8729
fe191308
JM
87302015-05-08 Jason Merrill <jason@redhat.com>
8731
765189ff
JM
8732 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
8733 * c-opts.c: Adjust.
8734
fe191308
JM
8735 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
8736
755e528f
MP
87372015-05-08 Marek Polacek <polacek@redhat.com>
8738
8739 PR c/64918
8740 * c.opt (Woverride-init-side-effects): New option.
8741
0173bd2a
MP
87422015-05-07 Marek Polacek <polacek@redhat.com>
8743
8744 PR c/65179
8745 * c-common.c (c_fully_fold_internal): Warn when left shifting a
8746 negative value.
8747 * c.opt (Wshift-negative-value): New option.
8748 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
8749 when -Wextra and C99/C++11 mode.
8750
e0f0d3b9
MP
87512015-05-07 Marek Polacek <polacek@redhat.com>
8752 Martin Uecker <uecker@eecs.berkeley.edu>
8753
8754 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
8755 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
8756
8243e2a9
JM
87572015-05-05 Jason Merrill <jason@redhat.com>
8758
8759 * c.opt (Wterminate): New.
8760
577cd070
MP
87612015-04-30 Marek Polacek <polacek@redhat.com>
8762
8763 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
8764 require that the non-constant be of a boolean type.
8765
0373796b
JT
87662015-04-29 Josh Triplett <josh@joshtriplett.org>
8767
e0f0d3b9
MP
8768 * c-common.c (handle_section_attribute): Refactor to reduce
8769 nesting and distinguish between error cases.
0373796b 8770
716c0ba6
MP
87712015-04-29 Marek Polacek <polacek@redhat.com>
8772
8773 PR c/64610
8774 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
8775 with 0/1.
8776
8848828b
JJ
87772015-04-29 Jakub Jelinek <jakub@redhat.com>
8778
8779 * c-common.h (omp_clause_mask): Unconditionally define as a class.
8780 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
8781 HOST_BITS_PER_WIDE_INT.
8782
ecd0e562
TV
87832015-04-28 Tom de Vries <tom@codesourcery.com>
8784
8785 PR tree-optimization/65887
8786 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
8787
2a877204 87882015-04-28 Eric Botcazou <ebotcazou@adacore.com>
e0f0d3b9 8789 Pierre-Marie de Rodat <derodat@adacore.com>
2a877204
EB
8790
8791 * c-ada-spec.c (in_function): Delete.
8792 (dump_generic_ada_node): Do not change in_function and remove the
8793 redundant code dealing with it.
8794 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
8795 (print_ada_methods): Output the static member functions in a nested
8796 package after the regular methods as well as associated renamings.
8797
4853031e
MP
87982015-04-24 Marek Polacek <polacek@redhat.com>
8799
8800 PR c/65830
8801 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
8802 and OPT_Wshift_count_overflow.
8803
8c2b7f79
MP
8804 PR c/63357
8805 * c-common.c (warn_logical_operator): Warn if the operands have the
8806 same expressions.
8807
b8787813
MP
88082015-04-24 Marek Polacek <polacek@redhat.com>
8809
8810 PR c/61534
8811 * c-common.c (warn_logical_operator): Bail if either operand comes
8812 from a macro expansion.
8813
8fba1830
BRF
88142015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
8815
8816 PR target/55143
8817 * c-common.c (c_default_pointer_mode): Add definition.
8818 * c-common.h (c_default_pointer_mode): Add declaration.
8819
17958621
JJ
88202015-03-11 Jakub Jelinek <jakub@redhat.com>
8821
8822 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
8823 on record_builtin_type argument.
8824
7ccb1a11
JJ
88252015-03-10 Jakub Jelinek <jakub@redhat.com>
8826
8827 PR c/65120
8828 * c-common.c (warn_logical_not_parentheses): Don't warn for
8829 !x == 0 or !x != 0.
8830
04fd785e
MP
88312015-03-07 Marek Polacek <polacek@redhat.com>
8832
8833 PR sanitizer/65280
8834 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
8835 before trying to figure out whether we have a flexible array member.
8836
a4e26206 88372015-03-06 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 8838 Jonathan Wakely <jwakely.gcc@gmail.com>
a4e26206
EB
8839
8840 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
8841
0d2489f4
EB
88422015-03-05 Eric Botcazou <ebotcazou@adacore.com>
8843
8844 PR ada/65319
8845 * c-ada-spec.c (print_destructor): Remove obsolete code.
8846
83ed54d7
EB
88472015-03-01 Eric Botcazou <ebotcazou@adacore.com>
8848
8849 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
8850 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
8851 DECL_TEMPLATE_RESULT emulations.
8852 (dump_ada_template)): Add guard for TYPE_METHODS.
8853
7631f0e2
MP
88542015-02-27 Marek Polacek <polacek@redhat.com>
8855
8856 PR c/65040
8857 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
8858
d1783ae5
KT
88592015-02-27 Kai Tietz <ktietz@redhat.com>
8860
8861 PR c/35330
8862 * c-pragma.c (handle_pragma_weak): Do not try to create
8863 weak/alias of declarations not being function, or variable
8864 declarations.
8865
56a9f6bc
TS
88662015-02-24 Thomas Schwinge <thomas@codesourcery.com>
8867
8868 PR libgomp/64625
8869 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
8870 Remove macros.
8871 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
8872
3d5cb23d
MP
88732015-02-16 Marek Polacek <polacek@redhat.com>
8874
8875 PR c/65066
8876 * c-format.c (check_format_types): Handle null param.
8877
fa008882
MP
88782015-02-13 Marek Polacek <polacek@redhat.com>
8879
8880 PR c/65040
8881 * c-format.c (check_format_types): Don't warn about different
8882 signedness if the original value is in the range of WANTED_TYPE.
8883
785f21af
JM
88842015-02-12 Jason Merrill <jason@redhat.com>
8885
8886 PR c++/64956
8887 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
8888 to the current highest version.
8889 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
8890
4886ec8e
JJ
88912015-02-04 Jakub Jelinek <jakub@redhat.com>
8892
8893 PR c/64824
8894 PR c/64868
8895 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
8896 instead of RDIV_EXPR. Use build_binary_op instead of
8897 build2_loc.
8898
40fecdd6
JM
88992015-01-30 Joseph Myers <joseph@codesourcery.com>
8900
8901 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
8902 to pass input_location as first argument.
8903
a0c88d06
TV
89042015-01-23 Tom de Vries <tom@codesourcery.com>
8905
8906 PR libgomp/64672
8907 * c.opt (fopenacc): Mark as LTO option.
8908
1506ae0e
TV
89092015-01-23 Tom de Vries <tom@codesourcery.com>
8910
8911 PR libgomp/64707
8912 * c.opt (fopenmp): Mark as LTO option.
8913
31be63ab
JJ
89142015-01-21 Jakub Jelinek <jakub@redhat.com>
8915
8916 PR c/63307
b1726d6c 8917 * cilk.c (fill_decls_vec): Only put decls into vector v.
31be63ab
JJ
8918 (compare_decls): Fix up formatting.
8919
89202015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
8921
8922 PR c/63307
8923 * cilk.c: Include vec.h.
8924 (struct cilk_decls): New structure.
8925 (wrapper_parm_cb): Split this function to...
8926 (fill_decls_vec): ...this...
8927 (create_parm_list): ...and this.
8928 (compare_decls): New function.
8929 (for_local_cb): Remove.
8930 (wrapper_local_cb): Ditto.
8931 (build_wrapper_type): For now first traverse and fill vector of
8932 declarations then sort it and then deal with sorted vector.
8933 (cilk_outline): Ditto.
8934 (declare_one_free_variable): Ditto.
8935
6875457f
JM
89362015-01-21 Jason Merrill <jason@redhat.com>
8937
8938 PR c++/64629
8939 * c-format.c (check_format_arg): Call decl_constant_value.
8940
185c9e56
ML
89412015-01-19 Martin Liska <mliska@suse.cz>
8942
8943 * c-common.c (handle_noicf_attribute): New function.
8944
41dbbb37
TS
89452015-01-15 Thomas Schwinge <thomas@codesourcery.com>
8946 Bernd Schmidt <bernds@codesourcery.com>
8947 James Norris <jnorris@codesourcery.com>
8948 Cesar Philippidis <cesar@codesourcery.com>
8949 Ilmir Usmanov <i.usmanov@samsung.com>
8950 Jakub Jelinek <jakub@redhat.com>
8951
8952 * c.opt (fopenacc): New option.
8953 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
8954 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
8955 New macros.
8956 * c-common.h (c_finish_oacc_wait): New prototype.
8957 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
8958 (c_finish_oacc_wait): New function.
8959 * c-pragma.c (oacc_pragmas): New variable.
8960 (c_pp_lookup_pragma, init_pragma): Handle it.
8961 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
8962 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
8963 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
8964 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
8965 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
8966 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
8967 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
8968 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
8969 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
8970 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
8971 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
8972 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
8973 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
8974 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
8975 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
8976 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
8977 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
8978 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
8979 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
8980 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
8981 PRAGMA_OACC_CLAUSE_WORKER.
8982
3f8257db 89832015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
5434dc07
MD
8984
8985 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
8986 for the new option fstack-protector_explicit.
8987 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
8988 (handle_stack_protect_attribute): New function.
8989
3f8257db 89902015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
de1b5c17
MU
8991
8992 * c.opt: New option -Warray-bounds=.
8993
adfac8df
JJ
89942015-01-09 Michael Collison <michael.collison@linaro.org>
8995
8996 * array-notation-common.c: Include hash-set.h, machmode.h,
8997 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
8998 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
8999 * c-ada-spec.c: Ditto.
9000 * c-cilkplus.c: Ditto.
9001 * c-common.c: Include input.h due to flattening of tree.h.
9002 Define macro GCC_C_COMMON_C.
9003 * c-common.h: Flatten tree.h header files into c-common.h.
9004 Remove include of tree-core.h.
9005 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
9006 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9007 fold-const.h, wide-int.h, and inchash.h due to
9008 flattening of tree.h.
9009 * c-dump.c: Ditto.
9010 * c-format.c: Flatten tree.h header files into c-common.h.
9011 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
9012 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9013 fold-const.h, wide-int.h, and inchash.h due to
9014 flattening of tree.h.
9015 * c-dump.c: Include hash-set.h, machmode.h,
9016 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9017 fold-const.h, wide-int.h, and inchash.h due to
9018 flattening of tree.h.
9019 * c-format.c: Include hash-set.h, machmode.h,
9020 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9021 fold-const.h, wide-int.h, inchash.h and real.h due to
9022 flattening of tree.h.
9023 * c-gimplify.c: Include hash-set.h, machmode.h,
9024 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
9025 fold-const.h, wide-int.h, and inchash.h due to
9026 flattening of tree.h.
9027 * cilk.c: Ditto.
9028 * c-lex.c: Ditto.
9029 * c-omp.c: Ditto.
9030 * c-opts.c: Ditto.
9031 * c-pch.c: Ditto.
9032 * c-ppoutput.c: Ditto.
9033 * c-pragma.c: Ditto.
9034 * c-pretty-print.c: Ditto.
9035 * c-semantics.c: Ditto.
9036 * c-ubsan.c: Ditto.
9037 * stub-objc.c: Ditto.
9038
f5481fc4
JM
90392015-01-08 Jason Merrill <jason@redhat.com>
9040
9041 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
9042 do_ubsan_in_current_function.
9043 (ubsan_maybe_instrument_reference_or_call): Likewise.
9044 * c-ubsan.h: Declare it.
9045
de35aa66
MS
90462015-01-08 Mike Stump <mikestump@comcast.net>
9047
9048 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
9049
4a9a42ab
MP
90502015-01-07 Marek Polacek <polacek@redhat.com>
9051
9052 PR c/64440
9053 * c-common.c (c_fully_fold_internal): Warn for division and modulo
9054 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
9055
2f42e5de
TS
90562015-01-05 Trevor Saunders <tsaunders@mozilla.com>
9057
9058 PR c++/31397
9059 * c.opt (Wsuggest-override): New option.
9060
5624e564
JJ
90612015-01-05 Jakub Jelinek <jakub@redhat.com>
9062
9063 Update copyright years.
9064
5bd012f8
MP
90652015-01-05 Marek Polacek <polacek@redhat.com>
9066
9067 PR c/64423
9068 * c-common.c (warn_array_subscript_with_type_char): Add location_t
9069 parameter. Use it.
9070 * c-common.h (warn_array_subscript_with_type_char): Update
9071 declaration.
9072
a7fa8d18
ESR
90732014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
9074
9075 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
9076 Control macro with flag_sized_deallocation.
9077
3f8257db 90782014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
768952be
MU
9079
9080 * c.opt (Wdiscarded-array-qualifiers): New option.
9081
1f8d3e84
JJ
90822014-12-19 Jakub Jelinek <jakub@redhat.com>
9083
9084 PR preprocessor/63831
9085 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
9086 and __has_cpp_attribute here.
9087 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
9088 c_common_has_attribute.
9089 * c-common.h (c_common_has_attribute): New prototype.
9090 * c-lex.c (init_c_lex): Set cb->has_attribute to
9091 c_common_has_attribute instead of cb_has_attribute.
9092 (get_token_no_padding): New function.
9093 (cb_has_attribute): Renamed to ...
9094 (c_common_has_attribute): ... this. No longer static. Use
9095 get_token_no_padding, require ()s, don't build TREE_LIST
9096 unnecessarily, fix up formatting, adjust diagnostics, call
9097 init_attributes.
9098
20b06add
JM
90992014-12-15 Jason Merrill <jason@redhat.com>
9100
9101 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
9102 (-Wsized-deallocation): New.
9103 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
9104 to on in C++14 and up.
9105
94a073b2
JM
91062014-12-11 Jason Merrill <jason@redhat.com>
9107
acaa5911
JM
9108 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
9109
94a073b2
JM
9110 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
9111 we aren't complaining about VLAs.
9112
7fb66c15
MP
91132014-12-06 Marek Polacek <polacek@redhat.com>
9114
9115 PR tree-optimization/64183
9116 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
9117 shift-expression if it is integer_type_node. Use types_compatible_p.
9118
b731b390
JJ
91192014-11-29 Jakub Jelinek <jakub@redhat.com>
9120
9121 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
9122 last argument from create_tmp_var_raw and create_tmp_var calls.
9123 * cilk.c (gimplify_cilk_spawn): Likewise.
9124 * c-omp.c (c_finish_omp_atomic): Likewise.
9125
6a4da643
MP
91262014-11-28 Marek Polacek <polacek@redhat.com>
9127
9128 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
9129 instead of unsigned_type_node.
9130
541e35a6
MP
91312014-11-28 Marek Polacek <polacek@redhat.com>
9132
9133 PR c/63862
9134 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
9135 to op1_utype.
9136 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
9137 expression to unsigned_type_node.
9138
dcc97066
MW
91392014-11-20 Mark Wielaard <mjw@redhat.com>
9140
9141 PR debug/38757
9142 * c-opts.c (set_std_c89): Set lang_hooks.name.
9143 (set_std_c99): Likewise.
9144 (set_std_c11): Likewise.
9145 (set_std_cxx98): Likewise.
9146 (set_std_cxx11): Likewise.
9147 (set_std_cxx14): Likewise.
9148 (set_std_cxx1z): Likewise.
9149
aa7da51a
JJ
91502014-11-21 Jakub Jelinek <jakub@redhat.com>
9151
9152 PR target/63764
9153 * c-common.h (convert_vector_to_pointer_for_subscript): Change
9154 return type to bool.
009a3480 9155 * c-common.c: Include gimple-expr.h.
aa7da51a
JJ
9156 (convert_vector_to_pointer_for_subscript): Change return type to
9157 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
9158 and copy it into a TARGET_EXPR and use that instead of *vecp
9159 directly.
9160
538dd0b7
DM
91612014-11-19 David Malcolm <dmalcolm@redhat.com>
9162
9163 Merger of git branch "gimple-classes-v2-option-3".
9164 * ChangeLog.gimple-classes: New.
9165 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
9166 from being just a vec<gimple> to a vec<gbind *>.
9167
c39a5e99
JJ
91682014-11-18 Jakub Jelinek <jakub@redhat.com>
9169
9170 PR sanitizer/63813
9171 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
9172 argument to ptype, set type to TREE_TYPE (ptype). Don't call
9173 get_pointer_alignment for non-pointers. Use ptype, or if it is
9174 reference type, corresponding pointer type, as type of kind
9175 argument.
9176 (ubsan_maybe_instrument_reference,
9177 ubsan_maybe_instrument_member_call): Adjust callers.
9178
8537a4a9
MP
91792014-11-15 Marek Polacek <polacek@redhat.com>
9180
9181 PR middle-end/63884
9182 * array-notation-common.c (is_sec_implicit_index_fn): Return false
9183 for NULL fndecl.
9184 (extract_array_notation_exprs): Return for NULL node.
9185
2079956a
JM
91862014-11-12 Joseph Myers <joseph@codesourcery.com>
9187
9188 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
9189 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
9190
1304953e
JJ
91912014-11-12 Jakub Jelinek <jakub@redhat.com>
9192
9193 PR c/59708
9194 * c-common.c (check_builtin_function_arguments): Handle
9195 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
9196
e5e44252
AK
91972014-11-10 Andi Kleen <ak@linux.intel.com>
9198
9199 PR c/60804
9200 * c-common.h (check_no_cilk): Declare.
9201 * cilk.c (get_error_location): New function.
9202 (check_no_cilk): Dito.
9203
e64b984d
AK
92042014-11-10 Andi Kleen <ak@linux.intel.com>
9205
9206 * cilk.c (recognize_spawn): Use expression location
9207 for error message.
9208
13c21655
PC
92092014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
9210
9211 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
9212
42fd12b1
ESR
92132014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
9214
9215 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
9216 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
9217 (__cpp_range_based_for, __cpp_initializer_lists,
9218 __cpp_delegating_constructors, __cpp_nsdmi,
9219 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
9220 for C++11; (__cpp_attribute_deprecated): Remove in favor of
9221 __has_cpp_attribute.
9222 * c-lex.c (cb_has_attribute): New callback CPP function;
9223 (init_c_lex): Set has_attribute callback.
9224
6f450181
RB
92252014-11-04 Richard Biener <rguenther@suse.de>
9226
9227 * c-common.c (shorten_compare): Do not shorten mixed
9228 DFP and non-DFP compares.
9229
26f0e1d6
ESR
92302014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
9231
9232 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
9233 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
9234 Commentary and rearrangement of tests.
9235 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
9236 Commentary and rearrangement of tests.
ab20d992 9237 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
26f0e1d6
ESR
9238 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
9239
ef4bddc2
RS
92402014-10-29 Richard Sandiford <richard.sandiford@arm.com>
9241
9242 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
9243 enum from machine_mode.
9244
c582198b
AM
92452014-10-28 Andrew MacLeod <amacleod@redhat.com>
9246
adfac8df
JJ
9247 * c-common.c: Adjust include files.
9248 * c-gimplify.c: Ditto.
9249 * cilk.c: Ditto.
9250 * c-pragma.c: Ditto.
9251 * c-ubsan.c: Ditto.
c582198b 9252
60393bbc
AM
92532014-10-27 Andrew MacLeod <amacleod@redhat.com>
9254
9255 * c-gimplify.c: Adjust include files.
9256
d723bb7c
MLI
92572014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
9258
9259 PR c++/53061
9260 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
9261 c_common_initialize_diagnostics.
9262 * c-common.h: Likewise.
9263
90f3520e
MP
92642014-10-24 Marek Polacek <polacek@redhat.com>
9265
9266 PR c/56980
9267 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
9268 print "struct"/"union"/"enum" for typedefed names.
9269
59d7607a
MP
92702014-10-23 Marek Polacek <polacek@redhat.com>
9271
9272 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
9273 in unsigned type.
9274
d95a2703
JJ
92752014-10-22 Jakub Jelinek <jakub@redhat.com>
9276 Yury Gribov <y.gribov@samsung.com>
9277
9278 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
9279 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
9280 instead of flag_sanitize_recover as bool flag.
9281
8e6ef852
KY
92822014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
9283
9284 * cilk.c: Revert previous change.
9285
948cf550
IZ
92862014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
9287
9288 PR c/63307
9289 * cilk.c: Include vec.h.
9290 (struct cilk_decls): New structure.
9291 (wrapper_parm_cb): Split this function to...
9292 (fill_decls_vec): ...this...
9293 (create_parm_list): ...and this.
9294 (compare_decls): New function.
9295 (for_local_cb): Remove.
9296 (wrapper_local_cb): Ditto.
9297 (build_wrapper_type): For now first traverse and fill vector of
9298 declarations then sort it and then deal with sorted vector.
9299 (cilk_outline): Ditto.
9300 (declare_one_free_variable): Ditto.
9301
92574c7c
MP
93022014-10-17 Marek Polacek <polacek@redhat.com>
9303
9304 * c-opts.c (c_common_post_options): Set warn_implicit_int.
9305 * c.opt (Wimplicit-int): Initialize to -1.
9306
83685514
AM
93072014-10-16 Andrew MacLeod <amacleod@redhat.com>
9308
9309 * c-pragma.c: Adjust include files.
9310 * c-semantics.c: Likewise.
9311
5b8300ea
DD
93122014-10-16 DJ Delorie <dj@redhat.com>
9313
9314 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
9315 multiples of bytes.
9316
5f83e90b
JM
93172014-10-14 Jason Merrill <jason@redhat.com>
9318
9319 PR c++/63455
9320 * c-common.h (CPP_PREPARSED_EXPR): New.
9321 (N_CP_TTYPES): Adjust.
9322
d73326ca
MP
93232014-10-15 Marek Polacek <polacek@redhat.com>
9324
9325 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
9326
78a7c317
DD
93272014-10-14 DJ Delorie <dj@redhat.com>
9328
9329 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
9330 types, not just __int128.
9331 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
9332 types, not just __int128.
9333 (cpp_atomic_builtins): Round pointer sizes up.
9334 (type_suffix): Use type precision, not specific types.
9335 * c-common.c (c_common_reswords): Remove __int128 special case.
9336 (c_common_type_for_size): Check for all __intN types, not just
9337 __int128.
9338 (c_common_type_for_mode): Likewise.
9339 (c_common_signed_or_unsigned_type): Likewise.
9340 (c_build_bitfield_integer_type): Likewise.
9341 (c_common_nodes_and_builtins): Likewise.
9342 (keyword_begins_type_specifier): Likewise.
9343 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
9344 __intN variants.
9345
2a22f99c
TS
93462014-10-12 Trevor Saunders <tsaunders@mozilla.com>
9347
9348 * c-common.c: Use hash_table instead of hashtab.
9349
2a8ef767
ESR
93502014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
9351
adfac8df 9352 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
2a8ef767
ESR
9353 C++11 section.
9354
3c9aabbd
MG
93552014-10-03 Marc Glisse <marc.glisse@inria.fr>
9356
9357 PR c++/54427
9358 PR c++/57198
9359 PR c++/58845
9360 * c-common.c (warn_logical_operator): Punt for vectors.
9361
a15f7cb8
ESR
93622014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
9363
9364 Implement SD-6: SG10 Feature Test Recommendations
9365 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
9366 macros and the __has_header macro.
9367
8d0cf15e
JM
93682014-09-30 Jason Merrill <jason@redhat.com>
9369
dd5d5481
JM
9370 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
9371 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
9372 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
9373
b752325e
JM
9374 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
9375 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
9376
8d0cf15e
JM
9377 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
9378 * c-common.c (c_common_reswords): Remove __is_convertible_to.
9379
083e891e
MP
93802014-09-24 Marek Polacek <polacek@redhat.com>
9381
9382 PR c/61405
9383 PR c/53874
9384 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
9385
7861b648
AK
93862014-09-23 Andi Kleen <ak@linux.intel.com>
9387
9388 * c-common.c (handle_no_reorder_attribute): New function.
9389 (c_common_attribute_table): Add no_reorder attribute.
9390
9a79452d
JM
93912014-09-22 Joseph Myers <joseph@codesourcery.com>
9392
9393 * c-cppbuiltin.c (c_cpp_builtins): Define
9394 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
9395 modes.
9396
dd69f047
JM
93972014-09-18 Joseph Myers <joseph@codesourcery.com>
9398
9399 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
9400 for supported floating-point modes.
9401
737a4826
MLI
94022014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
9403
9404 * c.opt (Wpsabi): Use LangEnabledBy.
9405 * c-opts.c (c_common_handle_option): Do not handle here.
9406
8cc4b7a2
JM
94072014-09-12 Joseph Myers <joseph@codesourcery.com>
9408
9409 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
9410 macros for floating-point modes.
9411
179b5a55
MG
94122014-09-11 Marc Glisse <marc.glisse@inria.fr>
9413
9414 PR target/58757
9415 * c-cppbuiltin.c (builtin_define_float_constants): Correct
9416 __*_DENORM_MIN__ without denormals.
9417
570a11fe
JJ
94182014-09-10 Jakub Jelinek <jakub@redhat.com>
9419
9420 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
9421 ubsan_instrument_vla, ubsan_instrument_return): Adjust
9422 ubsan_create_data callers.
9423 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
9424 index is constant or BIT_AND_EXPR with constant mask and is
9425 small enough for the bound.
9426 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
9427 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
9428
b559c810
MLI
94292014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
9430
9431 * c.opt: Add CppReason to various flags.
9432 (Wdate-time): Re-sort.
9433 * c-common.c: Include c-common.h earlier.
9434 (struct reason_option_codes_t): Delete.
9435 (c_option_controlling_cpp_error): Prefix global type and struct
9436 with cpp_.
9437
1ef33fd4
MLI
94382014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
9439
9440 * c.opt (Wnormalized): New.
9441 (Wnormalized=): Use Enum and Reject Negative.
9442 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
9443
66bb34c0
JM
94442014-09-08 Joseph Myers <joseph@codesourcery.com>
9445
9446 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
9447 digits of floating-point modes if -fbuilding-libgcc.
9448
53d68b9f
JM
94492014-09-05 Joseph Myers <joseph@codesourcery.com>
9450
9451 * c-cppbuiltin.c (c_cpp_builtins): Also define
9452 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
9453 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
9454 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
9455 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
9456 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
9457 __LIBGCC_STACK_GROWS_DOWNWARD__,
9458 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
9459 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
9460 __LIBGCC_DWARF_FRAME_REGISTERS__,
9461 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
9462 __LIBGCC_STACK_POINTER_REGNUM__ and
9463 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
9464 (builtin_define_with_value): Handle backslash-escaping in string
9465 macro values.
9466
f65586dc
RB
94672014-09-05 Richard Biener <rguenther@suse.de>
9468
9469 PR middle-end/63148
9470 * c-format.c (check_format_arg): Properly handle
9471 effectively signed POINTER_PLUS_EXPR offset.
9472
2b71f4a4
MLI
94732014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
9474
9475 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
9476 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
9477 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
9478 and Init.
9479 * c-opts.c (c_common_handle_option): Do not handle here.
9480 (sanitize_cpp_opts): Likewise.
9481 * c-common.c (struct reason_option_codes_t): Handle
9482 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
9483
d2e4feca
MP
94842014-09-03 Marek Polacek <polacek@redhat.com>
9485
9486 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
9487
9a771876
JJ
94882014-09-02 Jakub Jelinek <jakub@redhat.com>
9489 Balaji V. Iyer <balaji.v.iyer@intel.com>
9490 Igor Zamyatin <igor.zamyatin@intel.com>
9491
9492 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
9493 * c-common.c (c_common_reswords): Added _Cilk_for.
9494 * c-common.h (enum rid): Added RID_CILK_FOR.
9495 (cilk_for_number_of_iterations): Add declaration.
9496 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
9497 CILK_FOR.
9498 * c-pragma.c (init_pragma): Register "grainsize" pragma.
9499 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
9500
81b5d104
MLI
95012014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
9502
9503 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
9504 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
9505 Wundef): Use CPP, Var and Init.
9506 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
9507
b753b37b
MLI
95082014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
9509
9510 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
9511 * c-opts.c (c_common_handle_option): Do not handle here.
9512
028aee17
JM
95132014-08-25 Jason Merrill <jason@redhat.com>
9514
9515 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
9516 -std=c++14 and -std=gnu++14, rather than the reverse.
9517 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
9518 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
9519 * c-common.h (cxx_dialect): Remove cxx1y.
9520
e4276ba5
ESR
95212014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
9522
9523 * c-common.h (enum cxx_dialect): Add cxx14.
9524 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
9525 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
9526 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
9527
a545cacd
JM
95282014-08-22 Jason Merrill <jason@redhat.com>
9529
9530 * c.opt (std=gnu++17): Fix alias.
9531
59ea0364
MP
95322014-08-22 Marek Polacek <polacek@redhat.com>
9533
9534 PR c++/62199
9535 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
9536 check for vector types. Drop LHS argument.
9537 * c-common.h (warn_logical_not_parentheses): Adjust.
9538
596e808c
MLI
95392014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
9540
9541 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
9542 (Wmultichar): Likewise.
9543 (Wdate-time): Use C-family languages instead of Common. Use CPP
9544 and Var.
9545 * c-opts.c (c_common_handle_option): Do not handle the above
9546 options here.
9547 (sanitize_cpp_opts): Likewise.
9548
18767f65
MLI
95492014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
9550
9551 PR fortran/44054
9552 * c-opts.c: Include tree-diagnostics.h.
9553 (c_diagnostic_finalizer): New.
9554 (c_common_initialize_diagnostics): Use it.
9555
b4413594
MLI
95562014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
9557
9558 PR preprocessor/51303
9559 * c-common.c (struct reason_option_codes_t option_codes):
9560 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
9561
43f9a13c
MLI
95622014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
9563
9564 PR c/60975
9565 PR c/53063
9566 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
9567 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
9568 (c_common_post_options): Call init_global_opts_from_cpp.
9569 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
9570
04159acf
MP
95712014-08-19 Marek Polacek <polacek@redhat.com>
9572
9573 PR c++/62153
9574 * c-common.c (maybe_warn_bool_compare): New function.
9575 * c-common.h (maybe_warn_bool_compare): Declare.
9576 * c.opt (Wbool-compare): New option.
9577
35aff4fb
MP
95782014-08-19 Marek Polacek <polacek@redhat.com>
9579
9580 * c.opt (Wc99-c11-compat): New option.
9581
177cce46
MP
95822014-08-19 Marek Polacek <polacek@redhat.com>
9583
9584 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
9585 to warn_c90_c99_compat.
9586 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
9587 to -1.
9588
6ae9194f
MLI
95892014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
9590 Steven Bosscher <steven@gcc.gnu.org>
9591
9592 PR c/52952
9593 * c-format.c: Add extra_arg_loc and format_string_loc to struct
9594 format_check_results.
9595 (check_function_format): Use true and add comment for boolean
9596 argument.
9597 (finish_dollar_format_checking): Use explicit location when warning.
9598 (check_format_info): Likewise.
9599 (check_format_arg): Set extra_arg_loc and format_string_loc.
9600 (check_format_info_main): Use explicit location when warning.
9601 (check_format_types): Pass explicit location.
9602 (format_type_warning): Likewise.
9603
8e54f6d3
MLI
96042014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
9605
9606 PR fortran/44054
9607 * c-format.c: Handle Fortran flags.
9608
cd4e76fc
IZ
96092014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
9610
9611 PR other/61962
9612 * array-notation-common.c (find_rank): Added handling for other
9613 types of references.
9614
f3bede71
MP
96152014-08-10 Marek Polacek <polacek@redhat.com>
9616
9617 PR c/51849
9618 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
9619 * c.opt (Wc90-c99-compat): Add option.
9620
9f25a338
TS
96212014-08-07 Trevor Saunders <tsaunders@mozilla.com>
9622
9623 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
9624
62e4eb35
MP
96252014-08-03 Marek Polacek <polacek@redhat.com>
9626
ab20d992 9627 * c-common.c (check_case_value): Add location_t parameter. Use it.
62e4eb35
MP
9628 (c_add_case_label): Pass loc to check_case_value.
9629
b787e7a2
TS
96302014-08-02 Trevor Saunders <tsaunders@mozilla.com>
9631
9632 * cilk.c: Use hash_map instead of pointer_map.
9633
6e2830c3
TS
96342014-08-02 Trevor Saunders <tsaunders@mozilla.com>
9635
9636 * c-gimplify.c: Use hash_set instead of pointer_set.
9637
a7ee52fb
IZ
96382014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
9639
9640 PR middle-end/61455
9641 * array-notation-common.c (extract_array_notation_exprs): Handling
9642 of DECL_EXPR added.
9643
944fa280
JJ
96442014-08-01 Jakub Jelinek <jakub@redhat.com>
9645
9646 * c-common.h (min_align_of_type): Removed prototype.
9647 * c-common.c (min_align_of_type): Removed.
9648 * c-ubsan.h (ubsan_maybe_instrument_reference,
9649 ubsan_maybe_instrument_member_call): New prototypes.
9650 * c-ubsan.c: Include stor-layout.h and builtins.h.
9651 (ubsan_maybe_instrument_reference_or_call,
9652 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
9653 functions.
9654
b4dfdc11
MG
96552014-07-31 Marc Glisse <marc.glisse@inria.fr>
9656
9657 PR c++/60517
9658 * c.opt (-Wreturn-local-addr): Move to common.opt.
9659
a41844e5
JM
96602014-07-30 Jason Merrill <jason@redhat.com>
9661
9662 PR c++/61659
9663 PR c++/61687
9664 Revert:
9665 * c.opt (-fuse-all-virtuals): New.
9666
976d5a22
TT
96672014-07-30 Tom Tromey <tromey@redhat.com>
9668
9669 PR c/59855
9670 * c.opt (Wdesignated-init): New option.
9671 * c-common.c (c_common_attribute_table): Add "designated_init".
9672 (handle_designated_init): New function.
9673
cdc94aca
MP
96742014-07-24 Marek Polacek <polacek@redhat.com>
9675
9676 PR c/57653
9677 * c-opts.c (c_finish_options): If -imacros is in effect, return.
9678
f41373b6
DS
96792014-07-16 Dodji Seketeli <dodji@redhat.com>
9680
9681 PR preprocessor/60723 - missing system-ness marks for macro tokens
9682 * c-ppoutput.c (struct print::prev_was_system_token): New data
9683 member.
9684 (init_pp_output): Initialize it.
9685 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
9686 (do_line_change): Return a flag saying if a line marker was
9687 emitted or not.
9688 (scan_translation_unit): Detect if the system-ness of the token we
9689 are about to emit is different from the one of the previously
9690 emitted token. If so, emit a line marker. Avoid emitting useless
9691 adjacent line markers. Avoid emitting line markers for tokens
9692 originating from the expansion of built-in macros.
9693 (scan_translation_unit_directives_only): Adjust.
9694
4d661eaa
MP
96952014-07-15 Marek Polacek <polacek@redhat.com>
9696
9697 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
9698 TYPE_MAX_VALUE is NULL.
9699
b108f48f
JJ
97002014-07-14 Jakub Jelinek <jakub@redhat.com>
9701
9702 PR middle-end/61294
9703 * c.opt (Wmemset-transposed-args): New warning.
9704
c0221884
JM
97052014-07-10 Jason Merrill <jason@redhat.com>
9706
9707 PR c++/61659
9708 PR c++/61687
9709 * c.opt (-fuse-all-virtuals): New.
9710
63dfbb95
RB
97112014-07-09 Richard Biener <rguenther@suse.de>
9712
9713 PR c-family/61741
9714 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
9715 using unsigned arithmetic if overflow does not wrap instead of
9716 if overflow is undefined.
9717
773ec47f
MP
97182014-07-06 Marek Polacek <polacek@redhat.com>
9719
9720 PR c/6940
9721 * c.opt (Wsizeof-array-argument): New option.
9722
00a7ba58
JJ
97232014-07-03 Jakub Jelinek <jakub@redhat.com>
9724
b1726d6c 9725 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
00a7ba58
JJ
9726 comments->count <= 1, as comments->entries might be NULL.
9727
52ec0ea3
MP
97282014-07-01 Marek Polacek <polacek@redhat.com>
9729
9730 * c.opt (Wint-conversion): New option.
9731
d5c3d343
MP
97322014-07-01 Marek Polacek <polacek@redhat.com>
9733
9734 PR c/58286
9735 * c.opt (Wincompatible-pointer-types): New option.
9736
6e7ceb17
PC
97372014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
9738
9739 PR c++/51400
9740 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
9741 Do not discard TYPE_QUALS of type.
9742
da73100b
JM
97432014-06-26 Jason Merrill <jason@redhat.com>
9744
9745 * c-common.h (enum cxx_dialect): Add cxx1z.
9746 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
9747 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
9748
08eedf75
TJ
97492014-06-26 Teresa Johnson <tejohnson@google.com>
9750
9751 * c-common.h (get_dump_info): Declare.
9752 * c-gimplify.c (c_genericize): Use saved dump files.
9753 * c-opts.c (c_common_parse_file): Begin and end dumps
9754 once around parsing invocation.
9755 (get_dump_info): New function.
9756
7b56b2f8
MP
97572014-06-23 Marek Polacek <polacek@redhat.com>
9758 Andrew MacLeod <amacleod@redhat.com>
9759
9760 PR c/61553
9761 * c-common.c (get_atomic_generic_size): Don't segfault if the
9762 type doesn't have a size.
9763
0e37a2f3
MP
97642014-06-20 Marek Polacek <polacek@redhat.com>
9765
9766 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
9767 (ubsan_walk_array_refs_r): New function.
9768 (c_genericize): Instrument array bounds.
9769 * c-ubsan.c: Include "internal-fn.h".
9770 (ubsan_instrument_division): Mark instrumented arrays as having
9771 side effects. Adjust ubsan_type_descriptor call.
9772 (ubsan_instrument_shift): Likewise.
9773 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
9774 (ubsan_instrument_bounds): New function.
9775 (ubsan_array_ref_instrumented_p): New function.
9776 (ubsan_maybe_instrument_array_ref): New function.
9777 * c-ubsan.h (ubsan_instrument_bounds): Declare.
9778 (ubsan_array_ref_instrumented_p): Declare.
9779 (ubsan_maybe_instrument_array_ref): Declare.
9780
97812014-06-20 Hale Wang <hale.wang@arm.com>
dd6fe7d4
HW
9782
9783 PR lto/61123
9784 * c.opt (fshort-enums): Add to LTO.
9785 * c.opt (fshort-wchar): Likewise.
9786
5c3d09f7
MP
97872014-06-16 Marek Polacek <polacek@redhat.com>
9788
9789 PR c/60439
9790 * c.opt (Wswitch-bool): Add Var.
9791
9cf32741
JJ
97922014-06-12 Jakub Jelinek <jakub@redhat.com>
9793
9794 PR middle-end/61486
9795 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
9796 #pragma omp target teams or
9797 #pragma omp {,target }teams distribute simd.
9798
62984918
JM
97992014-06-12 Jason Merrill <jason@redhat.com>
9800
9801 * c.opt (Wabi=, fabi-compat-version): New.
9802 * c-opts.c (c_common_handle_option): Handle -Wabi=.
9803 (c_common_post_options): Handle flag_abi_compat_version default.
9804 Disallow -fabi-compat-version=1.
9805 * c-common.h (abi_version_crosses): New.
9806
f961457f
JH
98072014-06-11 Jan Hubicka <hubicka@ucw.cz>
9808
adfac8df 9809 * c-common.c (handle_section_attribute): Update handling for
f961457f
JH
9810 section names that are no longer trees.
9811
92d28cbb
JJ
98122014-06-10 Jakub Jelinek <jakub@redhat.com>
9813
9814 PR fortran/60928
9815 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
9816 (omp_pragmas): ... back here.
9817
742938c9
MP
98182014-06-05 Marek Polacek <polacek@redhat.com>
9819
9820 PR c/49706
9821 * c-common.c (warn_logical_not_parentheses): New function.
9822 * c-common.h (warn_logical_not_parentheses): Declare.
9823 * c.opt (Wlogical-not-parentheses): New option.
9824
9d548dfb
MP
98252014-06-04 Marek Polacek <polacek@redhat.com>
9826
9827 PR c/30020
9828 * c-common.c (check_case_bounds): Add location parameter.
9829 Use it.
9830 (c_add_case_label): Pass loc to check_case_bounds.
9831
fedfecef
MP
98322014-06-03 Marek Polacek <polacek@redhat.com>
9833
9834 PR c/60439
9835 * c.opt (Wswitch-bool): New option.
9836
f6a7cffc
TS
98372014-05-22 Thomas Schwinge <thomas@codesourcery.com>
9838
040d18b6
TS
9839 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
9840 Remove prototypes.
9841 (record_types_used_by_current_var_decl): Move prototype to where
9842 it belongs.
9843
f6a7cffc
TS
9844 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
9845 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
9846 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
9847
632f2871
RS
98482014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
9849
9850 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
9851 * c-common.c (c_common_nodes_and_builtins): Don't initialize
9852 void_zero_node.
9853 * c-pretty-print.c (pp_c_void_constant): New function.
9854 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
9855 (c_pretty_printer::expression): Handle VOID_CST.
9856 * cilk.c (extract_free_variables): Likewise.
9857 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
9858 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
9859
766090c2
TS
98602014-05-17 Trevor Saunders <tsaunders@mozilla.com>
9861
9862 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
9863 * c-pragma.c (push_alignment): Adjust.
9864 (handle_pragma_push_options): Likewise.
9865
661a0813
MP
98662014-05-09 Marek Polacek <polacek@redhat.com>
9867
9868 PR c/50459
9869 * c-common.c (check_user_alignment): Return -1 if alignment is error
9870 node.
9871 (handle_aligned_attribute): Don't call default_conversion on
9872 FUNCTION_DECLs.
9873 (handle_vector_size_attribute): Likewise.
9874 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
9875 (handle_sentinel_attribute): Call default_conversion and allow even
9876 integral types as an argument.
9877
2793eeab
MP
98782014-05-08 Marek Polacek <polacek@redhat.com>
9879
9880 PR c/61053
9881 * c-common.c (min_align_of_type): New function factored out from...
9882 (c_sizeof_or_alignof_type): ...here.
9883 * c-common.h (min_align_of_type): Declare.
9884
f827930a
MP
98852014-05-08 Marek Polacek <polacek@redhat.com>
9886
9887 PR c/61077
9888 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
9889 parameter type of main.
9890
ca49b74e
DD
98912014-05-07 DJ Delorie <dj@redhat.com>
9892
9893 * c-cppbuiltin.c (print_bits_of_hex): New.
9894 (builtin_define_type_minmax): Print values using hex so as not to
9895 require a pre-computed list of string values.
9896
1d60af08
KZ
98972014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
9898 Mike Stump <mikestump@comcast.net>
9899 Richard Sandiford <rdsandiford@googlemail.com>
9900
9901 * c-ada-spec.c: Include wide-int.h.
9902 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
9903 (dump_generic_ada_node): Use wide-int interfaces.
9904 * c-common.c: Include wide-int-print.h.
9905 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
9906 (pointer_int_sum): Use wide-int interfaces.
9907 (c_common_nodes_and_builtins): Use make_int_cst.
9908 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
9909 (handle_alloc_size_attribute): Use wide-int interfaces.
9910 (get_nonnull_operand): Likewise.
9911 * c-format.c (get_constant): Use tree_fits_uhwi_p.
9912 * c-lex.c: Include wide-int.h.
9913 (narrowest_unsigned_type): Take a widest_int rather than two
9914 HOST_WIDE_INTs.
9915 (narrowest_signed_type): Likewise.
9916 (interpret_integer): Update accordingly. Use wide-int interfaces.
9917 (lex_charconst): Use wide-int interfaces.
9918 * c-pretty-print.c: Include wide-int.h.
9919 (pp_c_integer_constant): Use wide-int interfaces.
9920 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
9921 INT_CST_LT_UNSIGNED.
9922
b15458be
RB
99232014-05-06 Richard Biener <rguenther@suse.de>
9924
9925 * c-opts.c (c_common_post_options): For -freestanding,
9926 -fno-hosted and -fno-builtin disable pattern recognition
9927 if not enabled explicitely.
9928
6577374e
MP
99292014-05-02 Marek Polacek <polacek@redhat.com>
9930
9931 * c.opt (Wsizeof-pointer-memaccess): Describe option.
9932
d00887e8
MP
99332014-05-01 Marek Polacek <polacek@redhat.com>
9934
9935 PR c/43245
9936 * c.opt (Wdiscarded-qualifiers): Add.
9937
f8ed5150
MP
99382014-04-30 Marek Polacek <polacek@redhat.com>
9939
9940 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
9941 INT_MIN / -1 sanitization only for integer types.
9942
45484dcf
MP
99432014-04-25 Marek Polacek <polacek@redhat.com>
9944
9945 PR c/18079
9946 * c-common.c (handle_noinline_attribute): Warn if the attribute
9947 conflicts with always_inline attribute.
9948 (handle_always_inline_attribute): Warn if the attribute conflicts
9949 with noinline attribute.
9950
38e514c0
MP
99512014-04-25 Marek Polacek <polacek@redhat.com>
9952
9953 PR c/60156
9954 * c-common.c (check_main_parameter_types): Warn about variadic main.
9955
44875f92
MS
99562014-04-24 Mike Stump <mikestump@comcast.net>
9957
9958 * c.opt (Wshadow-ivar): Default to on.
9959
dcaaa5a0
DP
99602014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
9961
9962 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
9963
c07d7c02
MP
99642014-04-23 Marek Polacek <polacek@redhat.com>
9965
9966 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
9967
1c33c9b7
JJ
99682014-04-22 Jakub Jelinek <jakub@redhat.com>
9969
9970 PR sanitizer/60275
9971 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
9972 if flag_sanitize_undefined_trap_on_error.
9973 (ubsan_instrument_division, ubsan_instrument_shift,
9974 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
9975 if !flag_sanitize_recover.
9976
793c625f
MG
99772014-04-22 Marc Glisse <marc.glisse@inria.fr>
9978
9979 PR libstdc++/43622
9980 * c-common.c (registered_builtin_types): Make non-static.
9981 * c-common.h (registered_builtin_types): Declare.
9982
b0f1bf36 99832014-04-14 Richard Biener <rguenther@suse.de>
ab20d992 9984 Marc Glisse <marc.glisse@inria.fr>
b0f1bf36
RB
9985
9986 PR c/60819
9987 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
9988 apply may-alias the scalar pointer type when applicable.
9989
3b07fa4a
IZ
99902014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
9991
9992 PR middle-end/60467
9993 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
9994 as possible argument for Cilk_spawn.
9995
cbbd2b1c
TB
99962014-04-11 Tobias Burnus <burnus@net-b.de>
9997
9998 PR c/60194
9999 * c.opt (Wformat-signedness): Add
10000 * c-format.c(check_format_types): Use it.
10001
6415bd5d
JM
100022014-04-11 Jason Merrill <jason@redhat.com>
10003
10004 PR c++/57926
10005 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
10006 default_conversion for an array argument.
10007
6525783a
MP
100082014-04-08 Marek Polacek <polacek@redhat.com>
10009
10010 PR sanitizer/60745
10011 * c-ubsan.c: Include asan.h.
10012 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
10013
880a467b
NS
100142014-04-03 Nathan Sidwell <nathan@codesourcery.com>
10015
10016 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
10017
7b59ff2d
MP
100182014-04-02 Marek Polacek <polacek@redhat.com>
10019
10020 * c-common.h (c_expand_expr): Remove declaration.
10021
8edbfaa6
JJ
100222014-03-28 Jakub Jelinek <jakub@redhat.com>
10023
10024 PR c++/60689
10025 * c-common.c (add_atomic_size_parameter): When creating new
10026 params vector, push the size argument first.
10027
07d72e1d
JJ
100282014-03-26 Jakub Jelinek <jakub@redhat.com>
10029
10030 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
10031 ubsan_instrument_vla, ubsan_instrument_return): Adjust
10032 ubsan_create_data callers.
10033
b35e0fa0
JJ
100342014-03-22 Jakub Jelinek <jakub@redhat.com>
10035
10036 PR debug/60603
10037 * c-opts.c (c_finish_options): Restore cb_file_change call to
10038 <built-in>.
10039
39a1ebb3
JJ
100402014-03-13 Jakub Jelinek <jakub@redhat.com>
10041
10042 PR middle-end/36282
10043 * c-pragma.c (apply_pragma_weak): Only look at
10044 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
10045 DECL_ASSEMBLER_NAME_SET_P (decl).
10046 (maybe_apply_pending_pragma_weaks): Exit early if
10047 vec_safe_is_empty (pending_weaks) rather than only when
10048 !pending_weaks.
10049 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
10050 set assembler name back to NULL afterwards.
10051
a07f6ed2
JM
100522014-03-11 Jason Merrill <jason@redhat.com>
10053
10054 * c.opt: Add -std=gnu++14.
10055
75b107f5
IB
100562014-03-11 Ian Bolton <ian.bolton@arm.com>
10057
10058 * c-opts.c (c_common_post_options): Don't override
10059 -ffp-contract=fast if unsafe-math-optimizations is on.
10060
f42c637e
PM
100612014-03-08 Paulo Matos <paulo@matos-sorge.com>
10062
22b15758 10063 * c.opt: Enable LTO FE for fshort-double.
f42c637e 10064
70e24808
JM
100652014-03-07 Jason Merrill <jason@redhat.com>
10066
10067 * c.opt: Add -std=c++14.
10068
3af9c5e9
MP
100692014-03-06 Marek Polacek <polacek@redhat.com>
10070
10071 PR c/60197
10072 * cilk.c (contains_cilk_spawn_stmt): New function.
10073 (contains_cilk_spawn_stmt_walker): Likewise.
10074 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
10075 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
10076
b3bdf019
JJ
100772014-03-03 Jakub Jelinek <jakub@redhat.com>
10078
10079 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
10080 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
10081 even when flag_preprocess_only.
10082
ca7e759d
JM
100832014-02-26 Jason Merrill <jason@redhat.com>
10084
10085 PR c++/59231
10086 PR c++/11586
10087 * c-common.c (shorten_compare): Don't check
10088 c_inhibit_evaluation_warnings.
10089
28e41874
JJ
100902014-02-19 Jakub Jelinek <jakub@redhat.com>
10091
cca615af
JJ
10092 PR c/37743
10093 * c-common.c (c_common_nodes_and_builtins): When initializing
10094 c_uint{16,32,64}_type_node, also set corresponding
10095 uint{16,32,64}_type_node to the same value.
10096
28e41874
JJ
10097 PR c++/60267
10098 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
10099 for PRAGMA_IVDEP if flag_preprocess_only.
10100
c2bf53a1
JJ
101012014-02-12 Jakub Jelinek <jakub@redhat.com>
10102
10103 PR c/60101
10104 * c-common.c (merge_tlist): If copy is true, call new_tlist,
10105 if false, add ADD itself, rather than vice versa.
10106 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
10107 copy. For SAVE_EXPR, only call merge_tlist once.
10108
8fcbce72
JJ
101092014-02-08 Jakub Jelinek <jakub@redhat.com>
10110
10111 PR middle-end/60092
10112 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
10113 and tree_to_uhwi.
10114 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
10115 functions.
10116 (c_common_attribute_table): Add alloc_align and assume_aligned
10117 attributes.
10118
0a756a3f
MP
101192014-02-06 Marek Polacek <polacek@redhat.com>
10120
10121 PR c/60087
10122 * c-common.c (warn_for_sign_compare): Call warning_at with location
10123 instead of warning.
10124
7ec4847a
MP
101252014-02-05 Marek Polacek <polacek@redhat.com>
10126
10127 PR c/53123
10128 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
10129 statement.
10130
66f20604
MP
101312014-02-04 Marek Polacek <polacek@redhat.com>
10132
10133 PR c/60036
10134 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
10135 SAVE_EXPR.
10136
5d77fb19
MG
101372014-02-03 Marc Glisse <marc.glisse@inria.fr>
10138
10139 PR c++/53017
10140 PR c++/59211
10141 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
10142 handle_vector_size_attribute, handle_nonnull_attribute): Call
10143 default_conversion on the attribute argument.
10144 (handle_nonnull_attribute): Increment the argument number.
10145
81e5eca8
MP
101462014-01-31 Marek Polacek <polacek@redhat.com>
10147
10148 PR c/59963
10149 * c-common.c (add_atomic_size_parameter): Pass vNULL to
10150 build_function_call_vec.
10151 (resolve_overloaded_builtin): Likewise.
10152 * c-common.h (build_function_call_vec): Adjust declaration.
10153
68fca595
MP
101542014-01-30 Marek Polacek <polacek@redhat.com>
10155
10156 PR c/59940
10157 * c-common.h (unsafe_conversion_p): Adjust declaration.
10158 (warnings_for_convert_and_check): Likewise.
10159 (convert_and_check): Likewise.
10160 * c-common.c (unsafe_conversion_p): Add location parameter. Call
10161 expansion_point_location_if_in_system_header on it.
10162 (warnings_for_convert_and_check): Add location parameter. Call
10163 expansion_point_location_if_in_system_header on it. Use it.
10164 (convert_and_check): Add location parameter. Use it.
10165 (conversion_warning): Likewise.
10166 (c_add_case_label): Adjust convert_and_check calls.
10167 (scalar_to_vector): Adjust unsafe_conversion_p calls.
10168
b72271b9
BI
101692014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
10170
10171 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
10172 flag_cilkplus.
10173 * c-pragma.c (init_pragma): Likewise.
10174 * c.opt: Likewise.
10175
393e8e8b
MP
101762014-01-23 Marek Polacek <polacek@redhat.com>
10177
10178 PR c/59846
10179 * c-common.c (shorten_compare): Add location_t parameter.
10180 * c-common.h (shorten_binary_op): Adjust declaration.
10181
f04dda30
MP
101822014-01-23 Marek Polacek <polacek@redhat.com>
10183
10184 PR c/58346
10185 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
10186 * c-common.h: Declare it.
10187
621955cb
EB
101882014-01-20 Eric Botcazou <ebotcazou@adacore.com>
10189
10190 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
10191 * c-ada-spec.c (dump_ads): Likewise.
10192 (cpp_check): Likewise.
10193 (dump_ada_specs): Likewise.
10194
101952014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
67bf2939
LA
10196
10197 PR c++/49718
10198 * c-common.c (handle_no_instrument_function_attribute): Allow
10199 no_instrument_function attribute in class member
10200 definition/declaration.
10201
241f845a
JJ
102022014-01-15 Jakub Jelinek <jakub@redhat.com>
10203
10204 PR c/58943
10205 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
10206 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
10207 being COMPOUND_EXPR.
10208 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
10209 operand a SAVE_EXPR and second MODIFY_EXPR.
10210
e83b8e2e
JJ
102112014-01-09 Jakub Jelinek <jakub@redhat.com>
10212
10213 PR target/58115
10214 * c-pch.c (c_common_write_pch): Call
10215 prepare_target_option_nodes_for_pch.
10216
23a5b65a
RS
102172014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
10218
10219 Update copyright years
10220
f9030485
RS
102212014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
10222
10223 * array-notation-common.c, c-cilkplus.c: Use the standard form for
10224 the copyright notice.
10225
f2aa696b
EB
102262013-12-28 Eric Botcazou <ebotcazou@adacore.com>
10227
10228 * c-ada-spec.c (print_constructor): New function.
10229 (print_destructor): Retrieve the origin of the destructor.
10230 (print_ada_declaration): Revamp handling of constructors/destructors.
10231
3f8257db 102322013-12-23 Stuart Hastings <stuart@apple.com>
1f26ac87
JM
10233 Bill Maddox <maddox@google.com>
10234 Jason Merrill <jason@redhat.com>
10235
10236 * c.opt: Add -fdeclone-ctor-dtor.
10237 * c-opts.c (c_common_post_options): Default to on iff -Os.
10238
41958c28
BI
102392013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
10240
10241 * c-common.c (c_common_attribute_table): Added "cilk simd function"
10242 attribute.
10243 * c-pragma.h (enum pragma_cilk_clause): Remove.
ab20d992 10244 (enum pragma_omp_clause): Added the following fields:
41958c28
BI
10245 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
10246 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
10247 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
10248 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
10249 PRAGMA_CILK_CLAUSE_UNIFORM.
10250
b1726d6c 10251
12893402
BI
102522013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
10253
10254 * cilk.c (cilk_outline): Made this function non-static.
10255 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
10256 (create_cilk_wrapper): Added a new parameter: a function pointer.
10257 (c_install_body_w_frame_cleanup): Remove
10258 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
10259 * c-common.h (cilk_outline): New prototype.
10260 (gimplify_cilk_spawn): Removed two parameters.
10261 (cilk_install_body_with_frame_cleanup): New prototype.
10262 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
10263 CILK_SPAWN_STMT case.
10264
085b42ed
BS
102652013-12-11 Bernd Schmidt <bernds@codesourcery.com>
10266
2ce064c3
BS
10267 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
10268
085b42ed
BS
10269 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
10270 (int_array_type_node): Remove.
10271 * c-common.c (c_common_nodes_and_builtins): Don't build it.
10272
9e36c9ed
MP
102732013-12-05 Marek Polacek <polacek@redhat.com>
10274
10275 PR c/52023
10276 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
10277 [ADJUST_FIELD_ALIGN].
10278
296674db
JM
102792013-12-04 Joseph Myers <joseph@codesourcery.com>
10280
10281 PR c/52023
10282 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
10283 and check field alignment if set.
10284 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
10285 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
10286
b1726d6c 102872013-12-04 Jakub Jelinek <jakub@redhat.com>
31e071ae
MP
10288 Marek Polacek <polacek@redhat.com>
10289
10290 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
10291 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
10292
d7947e19
L
102932013-11-29 H.J. Lu <hongjiu.lu@intel.com>
10294
10295 PR c/59309
10296 * cilk.c (gimplify_cilk_spawn): Properly handle function without
10297 arguments.
10298
fad7652e
JJ
102992013-11-29 Jakub Jelinek <jakub@redhat.com>
10300
10301 PR c/59280
10302 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
10303 goto invalid. If it is error_mark_node, don't issue further
10304 diagnostics.
10305
8b5e1202
SO
103062013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
10307
10308 * c.opt (Wopenmp-simd): New.
10309
0a508bb6
JJ
103102013-11-22 Jakub Jelinek <jakub@redhat.com>
10311
10312 * c-ubsan.h (ubsan_instrument_return): New prototype.
10313 * c-ubsan.c (ubsan_instrument_return): New function.
10314
2fb9a547
AM
103152013-11-22 Andrew MacLeod <amacleod@redhat.com>
10316
10317 * c-common.c: Add required include files from gimple.h.
ab20d992
JJ
10318 * c-gimplify.c: Likewise.
10319 * cilk.c: Likewise.
2fb9a547 10320
8400e75e
DM
103212013-11-22 David Malcolm <dmalcolm@redhat.com>
10322
10323 * c-common.c (unsafe_conversion_p): Remove use of
10324 EXPR_LOC_OR_HERE macro.
10325 (conversion_warning): Likewise.
10326 (warnings_for_convert_and_check): Likewise.
10327 (warn_for_collisions_1): Likewise.
10328 (shorten_compare): Likewise, and remove use of in_system_header
10329 macro, using the location from the former.
10330 * c-lex.c (dump_one_header): Remove use of input_filename macro.
10331 (cb_def_pragma): Remove use of in_system_header macro.
10332 (lex_string): Likewise.
10333 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
10334
eb1ce453
KZ
103352013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
10336 Mike Stump <mikestump@comcast.net>
10337 Richard Sandiford <rdsandiford@googlemail.com>
10338
10339 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
10340 instead of TREE_INT_CST_LOW, in cases where there is a protecting
10341 tree_fits_shwi_p or tree_fits_uhwi_p.
10342 (dump_generic_ada_node): Likewise.
10343 * c-format.c (check_format_arg): Likewise.
10344 * c-pretty-print.c (pp_c_integer_constant): Likewise.
10345
6b3b8c27
KZ
103462013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
10347
10348 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
10349
49b0aa18
JC
103502013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
10351
10352 PR c/53001
10353 * c-common.c (unsafe_conversion_p): Make this function
10354 return an enumeration with more detail.
10355 (conversion_warning): Use the new return type of
10356 unsafe_conversion_p to separately warn either about conversions
10357 that lower floating point number precision or about the other
10358 kinds of conversions.
10359 * c-common.h (enum conversion_safety): New enumeration.
8e745a17
JJ
10360 (unsafe_conversion_p): switching return type to
10361 conversion_safety enumeration.
49b0aa18
JC
10362 * c.opt: Adding new warning -Wfloat-conversion and
10363 enabling it with -Wconversion.
10364
b826515a
BS
103652013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
10366
8e745a17
JJ
10367 * c-opts.c: Include plugin.h.
10368 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
b826515a 10369
b9a55b13
MP
103702013-11-19 Marek Polacek <polacek@redhat.com>
10371
10372 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
10373 call.
10374 (ubsan_instrument_shift): Likewise.
10375 (ubsan_instrument_vla): Likewise.
10376
7d362f6c
RS
103772013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10378
10379 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
10380 cast to unsigned type.
10381
386b1f1f
RS
103822013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10383
10384 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
10385 tree_low_cst.
10386 (complete_array_type): Update comment to refer to tree_to_[su]hwi
10387 rather than tree_low_cst.
10388
ae7e9ddd
RS
103892013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10390
10391 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
10392 tree_to_uhwi throughout.
10393
9439e9a1
RS
103942013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10395
10396 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
10397 tree_low_cst (..., 0) with tree_to_shwi throughout.
10398
cc269bb6
RS
103992013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10400
10401 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
10402 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
10403
9541ffee
RS
104042013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
10405
10406 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
10407 host_integerp (..., 0) with tree_fits_shwi_p throughout.
10408
c02065fc
AH
104092013-11-15 Aldy Hernandez <aldyh@redhat.com>
10410
10411 * c-cilkplus.c: New file.
10412 * c-common.c (readonly_error): Add location argument.
10413 * c-common.h (readonly_error): Same.
10414 (c_finish_cilk_clauses): Protoize.
10415 (c_check_cilk_loop): Same.
10416 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
10417 Do not fail on error_mark_node.
10418 Abstract increment canonicalization to here...
10419 (c_omp_for_incr_canonicalize_ptr): New.
10420 c-pragma.c (init_pragma): Register "simd" pragma.
10421 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
10422 (enum pragma_cilk_clause): New.
10423
9cc65f15
RS
104242013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
10425
10426 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
10427 wchar_type and host_integerp checks.
10428
18f429e2
AM
104292013-11-14 Andrew MacLeod <amacleod@redhat.com>
10430
10431 * c-common.c: Likewise.
10432 * c-gimplify.c: Likewise.
10433 * cilk.c: Likewise.
10434
d8a2d370
DN
104352013-11-14 Diego Novillo <dnovillo@google.com>
10436
10437 * c-common.c: Include fold-const.h.
10438 Include stor-layout.h.
10439 Include calls.h.
10440 Include stringpool.h.
10441 Include attribs.h.
10442 Include varasm.h.
10443 Include trans-mem.h.
10444 * c-cppbuiltin.c: Include stor-layout.h.
10445 Include stringpool.h.
10446 * c-format.c: Include stringpool.h.
10447 * c-lex.c: Include stringpool.h.
10448 Include stor-layout.h.
10449 * c-pragma.c: Include stringpool.h.
10450 Include attribs.h.
10451 Include varasm.h.
10452 Include gcc-symtab.h.
10453 * c-pretty-print.c: Include stor-layout.h.
10454 Include attribs.h.
10455 * cilk.c: Include stringpool.h.
10456 Include calls.h.
10457
38b7bc7f
JM
104582013-11-13 Joseph Myers <joseph@codesourcery.com>
10459
10460 * c-common.h (enum rid): Add RID_AUTO_TYPE.
10461 * c-common.c (c_common_reswords): Add __auto_type.
10462 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
10463
45b0be94
AM
104642013-11-12 Andrew MacLeod <amacleod@redhat.com>
10465
18f429e2
AM
10466 * c-common.c: Include gimplify.h.
10467 * c-gimplify.c: Likewise.
10468 * cilk.c: Likewise.
10469 * c-omp.c: Include gimple-expr.h instead of gimple.h.
10470 * c-ubsan.c: Don't include gimple.h.
45b0be94 10471
582d9b50
JM
104722013-11-12 Joseph Myers <joseph@codesourcery.com>
10473
10474 * c-common.c (c_common_reswords): Add _Thread_local.
10475
6b28e197
JM
104762013-11-09 Joseph Myers <joseph@codesourcery.com>
10477
10478 * c-common.c (atomic_size_supported_p): New function.
10479 (resolve_overloaded_atomic_exchange)
10480 (resolve_overloaded_atomic_compare_exchange)
10481 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
10482 Use it instead of comparing size with a local list of sizes.
10483
267bac10
JM
104842013-11-07 Andrew MacLeod <amacleod@redhat.com>
10485 Joseph Myers <joseph@codesourcery.com>
10486
10487 * c-common.h (enum rid): Add RID_ATOMIC.
10488 * c-common.c (c_common_reswords): Add _Atomic.
10489 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
10490 (keyword_is_type_qualifier): Accept RID_ATOMIC.
10491 * c-format.c (check_format_types): Check for extra _Atomic
10492 qualifiers in format argument.
10493 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
10494 (pp_c_type_qualifier_list): Mention _Atomic in comment.
10495
5157b91e
TB
104962013-11-06 Tobias Burnus <burnus@net-b.de>
10497
10498 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
10499
6dbe0958
JM
105002013-11-06 Joseph Myers <joseph@codesourcery.com>
10501
10502 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
10503 standards modes.
10504 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
10505 to mean lack of IEEE 754 support.
10506
e8ff5196
TB
105072013-11-05 Tobias Burnus <burnus@net-b.de>
10508
10509 * c.opt (-Wdate-time): New option
10510 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
10511
254a0760
JM
105122013-11-05 Joseph Myers <joseph@codesourcery.com>
10513
10514 * c-cppbuiltin.c (cpp_iec_559_value): Test
10515 flag_excess_precision_cmdline not flag_excess_precision.
10516
6d7f7e0a
TB
105172013-11-05 Tobias Burnus <burnus@net-b.de>
10518
10519 * c.opt (fopenmp-simd): New option.
10520 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
10521 (omp_pragmas): ... this new struct.
10522 (c_pp_lookup_pragma): Also walk omp_pragmas.
10523 (init_pragma): Init pragmas for -fopenmp-simd.
10524
55a7f02f
MP
105252013-11-04 Marek Polacek <polacek@redhat.com>
10526
10527 PR c++/58979
10528 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
10529
9193fb05
JM
105302013-11-04 Joseph Myers <joseph@codesourcery.com>
10531
10532 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
10533 New functions.
10534 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
10535
94159ecf
EB
105362013-11-04 Eric Botcazou <ebotcazou@adacore.com>
10537
10538 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
10539 (dump_ada_specs): Adjust prototype of second callback.
10540 * c-ada-spec.c (cpp_check): New global variable.
10541 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
10542 (print_generic_ada_decl): Likewise.
10543 (has_static_fields): Change return type to bool and add guard.
10544 (has_nontrivial_methods): New predicate.
10545 (is_tagged_type): Change return type to bool.
10546 (separate_class_package): Call has_nontrivial_methods.
10547 (pp_ada_tree_identifier): Minor tweaks.
10548 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
10549 (dump_ada_array_domains): Likewise.
10550 (dump_ada_array_type): Likewise.
10551 (dump_template_types): Remove cpp_check parameter and do not pass it to
10552 dump_generic_ada_node.
10553 (dump_ada_template): Likewise.
10554 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
10555 recursively.
10556 (print_ada_methods): Change return type to integer. Remove cpp_check
10557 parameter and do not pass it down.
10558 (dump_nested_types): Remove cpp_check parameter and do not pass it to
10559 dump_generic_ada_node.
10560 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
10561 accessing methods.
10562 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
10563 down. Use has_nontrivial_methods to recognize C++ classes. Use return
10564 value of print_ada_methods.
10565 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
10566 Set cpp_check to it before invoking dump_ada_nodes.
10567 (dump_ada_specs): Likewise.
10568
b906f4ca
MP
105692013-11-03 Marek Polacek <polacek@redhat.com>
10570
10571 * c-ubsan.c: Don't include hash-table.h.
10572 (ubsan_instrument_vla): New function.
10573 * c-ubsan.h: Declare it.
10574
5e20cdc9
DM
105752013-10-31 David Malcolm <dmalcolm@redhat.com>
10576
10577 Automated part of renaming of symtab_node_base to symtab_node.
10578
10579 Patch autogenerated by rename_symtab.py from
10580 https://github.com/davidmalcolm/gcc-refactoring-scripts
10581 revision 58bb219cc090b2f4516a9297d868c245495ee622
10582
10583 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
10584 symtab_node_base to symtab_node.
10585
7057e645
ESR
105862013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
10587
8e745a17 10588 Implement C++14 digit separators.
7057e645
ESR
10589 * c-lex.c (interpret_float): Remove digit separators from scratch string
10590 before building real literal.
10591
193ea7bc
JJ
105922013-10-30 Jakub Jelinek <jakub@redhat.com>
10593
10594 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
10595
939b37da
BI
105962013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
10597
10598 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
10599 fields.
10600 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
10601 enabled.
10602 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
10603 (insert_cilk_frame): New prototype.
10604 (cilk_init_builtins): Likewise.
10605 (gimplify_cilk_spawn): Likewise.
10606 (c_cilk_install_body_w_frame_cleanup): Likewise.
10607 (cilk_detect_spawn_and_unwrap): Likewise.
10608 (cilk_set_spawn_marker): Likewise.
10609 (build_cilk_sync): Likewise.
10610 (build_cilk_spawn): Likewise.
10611 * cilk.c: New file.
10612
67348ccc
DM
106132013-10-29 David Malcolm <dmalcolm@redhat.com>
10614
10615 Patch autogenerated by refactor_symtab.py from
10616 https://github.com/davidmalcolm/gcc-refactoring-scripts
10617 revision 58bb219cc090b2f4516a9297d868c245495ee622
10618
10619 * c-gimplify.c (c_genericize): Update for conversion of symtab types
10620 to a true class hierarchy.
10621 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
10622
d570872d
RS
106232013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
10624
10625 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
10626
98906124
JL
106272013-10-26 Jeff Law <law@redhat.com>
10628
adfac8df
JJ
10629 * c-common.c (c_define_builtins): Remove mudflap support.
10630 * c.opt: Ignore and warn for mudflap options.
98906124 10631
d73749df 106322013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
10633
10634 PR other/33426
10635 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
10636 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
10637
3f04b1bb
JM
106382013-10-23 Jason Merrill <jason@redhat.com>
10639
10640 * c-format.c (gcc_cxxdiag_char_table): Add %X.
10641
acf0174b
JJ
106422013-10-11 Jakub Jelinek <jakub@redhat.com>
10643
acd15a28
JJ
10644 * c-common.h (omp_clause_mask::operator !=): New method.
10645 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
10646 instead of if (mask & something) tests everywhere.
10647
acf0174b
JJ
10648 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
10649 201307 instead of 201107.
10650 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
10651 (c_common_attribute_table): Add "omp declare target" and
10652 "omp declare simd" attributes.
10653 (handle_omp_declare_target_attribute,
10654 handle_omp_declare_simd_attribute): New functions.
10655 * c-omp.c: Include c-pragma.h.
10656 (c_finish_omp_taskgroup): New function.
10657 (c_finish_omp_atomic): Add swapped argument, if true,
10658 build the operation first with rhs, lhs arguments and use NOP_EXPR
10659 build_modify_expr.
10660 (c_finish_omp_for): Add code argument, pass it down to make_code.
10661 (c_omp_split_clauses): New function.
10662 (c_split_parallel_clauses): Removed.
10663 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
10664 c_omp_declare_simd_clauses_to_decls): New functions.
10665 * c-common.h (omp_clause_mask): New type.
10666 (OMP_CLAUSE_MASK_1): Define.
10667 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
10668 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
10669 omp_clause_mask::operator |, omp_clause_mask::operator &,
10670 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
10671 omp_clause_mask::operator ==): New methods.
10672 (enum c_omp_clause_split): New.
10673 (c_finish_omp_taskgroup): New prototype.
10674 (c_finish_omp_atomic): Add swapped argument.
10675 (c_finish_omp_for): Add code argument.
10676 (c_omp_split_clauses): New prototype.
10677 (c_split_parallel_clauses): Removed.
10678 (c_omp_declare_simd_clauses_to_numbers,
10679 c_omp_declare_simd_clauses_to_decls): New prototypes.
10680 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
10681 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
10682 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
10683 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
10684 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
10685 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
10686 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
10687 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
10688 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
10689 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
10690 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
10691 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
10692 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
10693 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
10694 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
10695 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
10696 PRAGMA_OMP_CLAUSE_UNIFORM.
10697
826cacfe
MG
106982013-10-09 Marc Glisse <marc.glisse@inria.fr>
10699
10700 PR tree-optimization/20318
10701 * c-common.c (handle_returns_nonnull_attribute): New function.
10702 (c_common_attribute_table): Add returns_nonnull.
10703
2284b034
MG
107042013-10-03 Marc Glisse <marc.glisse@inria.fr>
10705
10706 PR c++/19476
10707 * c.opt (fcheck-new): Move to common.opt.
10708
b56e9788
MP
107092013-09-25 Marek Polacek <polacek@redhat.com>
10710 Jakub Jelinek <jakub@redhat.com>
10711
10712 PR sanitizer/58413
10713 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
10714 an expression if we can prove it is correct.
10715 (ubsan_instrument_division): Likewise. Remove unnecessary
10716 check.
10717
ce6923c5
MP
107182013-09-18 Marek Polacek <polacek@redhat.com>
10719
10720 PR sanitizer/58411
10721 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
10722 Declare it.
10723 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
10724
fb5610fb
IS
107252013-09-14 Iain Sandoe <iain@codesourcery.com>
10726
10727 PR target/48094
10728 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
10729 fobjc-gc, freplace-objc-classes): Accept for LTO.
10730
88b0e79e
JC
107312013-09-13 Jacek Caban <jacek@codeweavers.com>
10732
10733 * c-target.def: New hook
10734
c9b0866a
PC
107352013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
10736
10737 PR c++/43452
10738 * c.opt (Wdelete-incomplete): Add.
10739
0af94e6f
JR
107402013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
10741
10742 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
10743 (vector_types_compatible_elements_p): New function.
10744 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
10745 declaration.
10746 (vector_types_compatible_elements_p): Declare.
10747
7c26172c
GDR
107482013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
10749
10750 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
10751 a virtual member function.
10752 (pp_simple_type_specifier): Remove.
10753 (pp_c_type_specifier): Likewise.
10754 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
10755 Rename from pp_c_type_specifier. Adjust.
10756 (c_pretty_printer::c_pretty_printer): Do not assign to
10757 simple_type_specifier.
10758
20059c8b
GDR
107592013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
10760
10761 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
10762 member function.
10763 (c_pretty_printer::storage_class_specifier): Likewise.
10764 (c_pretty_printer::initializer): Likewise.
10765 (pp_declaration): Remove.
10766 (pp_declaration_specifiers): Likewise.
10767 (pp_abstract_declarator): Likewise.
10768 (pp_declarator): Likewise.
10769 (pp_type_id): Likewise.
10770 (pp_statement): Likewise.
10771 (pp_constant): Likewise.
10772 (pp_id_expression): Likewise.
10773 (pp_primary_expression): Likewise.
10774 (pp_unary_expression): Likewise.
10775 (pp_multiplicative_expression): Likewise.
10776 (pp_conditional_expression): Likewise.
10777 (pp_assignment_expression): Likewise.
10778 (pp_expression): Likewise.
10779 (pp_c_type_id): Likewise.
10780 (pp_c_storage_class_specifier): Likewise.
10781 * c-pretty-print.c (pp_c_type_cast): Tidy.
10782 (pp_c_pointer): Likewise.
10783 (pp_c_type_specifier): Likewise.
10784 (pp_c_parameter_type_list): Likewise.
10785 (pp_c_function_definition): Likewise.
10786 (pp_c_init_declarator): Likewise.
10787 (pp_c_initializer_list): Likewise.
10788 (pp_c_constructor_elts): Likewise.
10789 (c_pretty_printer::direct_abstract_declarator): Likewise.
10790 (c_pretty_printer::declaration_specifiers): Likewise.
10791 (c_pretty_printer::primary_expression): Likewise.
10792 (c_pretty_printer::postfix_expression): Likewise.
10793 (c_pretty_printer::type_id): Rename from pp_c_type_id.
10794 (c_pretty_printer::storage_class_specifier): Rename from
10795 pp_c_storage_class_specifier.
10796 (c_pretty_printer::initializer): Rename from pp_c_initializer.
10797 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
10798 storage_class_specifier, initializer, offset_list, flags.
10799
de5a5fa1
MP
108002013-08-30 Marek Polacek <polacek@redhat.com>
10801
10802 * c-ubsan.c: New file.
10803 * c-ubsan.h: New file.
10804
8f0e4d72
GDR
108052013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
10806
10807 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
10808 member function.
10809 (c_pretty_printer::declaration_specifiers): Likewise.
10810 (c_pretty_printer::declarator): Likewise.
10811 (c_pretty_printer::abstract_declarator): Likewise.
10812 (c_pretty_printer::direct_abstract_declarator): Likewise.
10813 (c_pretty_printer::direct_declarator): Likewise.
10814 (c_pretty_printer::function_specifier): Likewise.
10815 (pp_declaration): Adjust.
10816 (pp_declaration_specifiers): Likewise.
10817 (pp_abstract_declarator): Likewise.
10818 (pp_direct_declarator): Likewise.
10819 (pp_function_specifier): Likewise.
10820 (pp_direct_abstract_declarator): Remove as unused.
10821 (pp_c_declaration): Remove.
10822 (pp_c_declaration_specifiers): Likewise.
10823 (pp_c_declarator): Likewise.
10824 (pp_c_direct_declarator): Likewise.
10825 (pp_c_function_specifier): Likewise.
10826 (pp_c_direct_abstract_declarator): Likewise.
10827 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
10828 from pp_c_abstract_declarator. Adjust.
ab20d992 10829 (c_pretty_printer::direct_abstract_declarator): Rename from
8f0e4d72
GDR
10830 pp_c_direct_abstract_declarator. Adjust.
10831 (c_pretty_printer::function_specifier): Rename from
10832 pp_c_function_specifier. Adjust.
10833 (c_pretty_printer::declaration_specifiers): Rename from
10834 pp_c_declaration_specifiers. Adjust.
10835 (c_pretty_printer::direct_declarator): Rename from
10836 pp_c_direct_declarator. Adjust.
10837 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
10838 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
10839 (c_pretty_printer::c_pretty_printer): Do not assign to
10840 declaration, declaration_specifiers, declarator,
10841 direct_declarator, direct_abstract_declarator, function_specifier.
10842
00d34d3a
GDR
108432013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
10844
10845 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
10846 virtual member function.
10847 (c_pretty_printer::multiplicative_expression): Likewise.
10848 (c_pretty_printer::conditional_expression): Likewise.
10849 (c_pretty_printer::assignment_expression): Likewise.
10850 (c_pretty_printer::expression): Likewise.
10851 (pp_unary_expression): Adjust.
10852 (pp_multiplicative_expression): Likewise.
10853 (pp_assignment_expression): Likewise.
10854 (pp_conditional_expression): Likewise.
10855 (pp_expression): Likewise.
10856 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
10857 from pp_c_unary_expression. Adjust.
10858 (c_pretty_printer::multiplicative_expression): Rename from
10859 pp_c_multiplicative_expression. Adjust.
10860 (c_pretty_printer::conditional_expression): Rename from
10861 pp_c_conditional_expression. Adjust.
10862 (c_pretty_printer::assignment_expression): Rename from
10863 pp_c_assignment_expression. Adjust.
10864 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
10865 (c_pretty_printer::c_pretty_printer): Do not assign to
10866 unary_expression, multiplicative_expression,
10867 conditional_expression, expression.
10868
fb22178f
GDR
108692013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
10870
10871 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
10872 virtual member function.
10873 (pp_postfix_expression): Adjust.
10874 (pp_c_postfix_expression): Remove.
10875 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
10876 from pp_c_postfix_expression. Adjust.
10877 (c_pretty_printer::c_pretty_printer): Do not assign to
10878 postfix_expression.
10879
7ecc2600
GDR
108802013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
10881
10882 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
10883 virtua member function.
10884 (pp_primary_expression): Adjust.
10885 (pp_c_primary_expression): Remove.
10886 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
10887 from pp_c_primary_expression. Adjust.
10888 (pp_c_initializer_list): Use pp_primary_expression.
10889 (c_pretty_printer::c_pretty_printer): Do not assign to
10890 primary_expression.
10891
0691175f
GDR
108922013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
10893
10894 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
10895 * c-pretty-print.c (M_): Remove.
10896 (c_pretty_printer::translate_string): Define.
10897 (pp_c_type_specifier): Use it.
10898 (pp_c_primary_expression): Likewise.
10899 (pp_c_expression): Likewise.
10900
66dfe4c4
GDR
109012013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
10902
10903 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
10904 virtual function.
10905 (pp_c_id_expression): Remove.
10906 (pp_id_expression): Adjust.
10907 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
10908 pp_c_id_expression. Adjust.
10909 (pp_c_postfix_expression): Use pp_id_expression.
10910 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
10911
ca43e9d5
GDR
109122013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
10913
10914 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
10915 member function.
10916 (pp_constant): Adjust.
10917 (pp_c_constant): Remove.
10918 * c-pretty-print.c (c_pretty_printer::constant): Rename from
10919 pp_c_constant. Adjust.
10920 (pp_c_constant)
10921 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
10922 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
10923
da6ca2b5
GDR
109242013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
10925
10926 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
10927 (c_pretty_printer::c_pretty_printer): Declare.
10928 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
10929 c_pretty_printer_init. Adjust.
10930 (print_c_tree): Do not call c_pretty_printer_init.
10931 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
10932
65a372f4
AC
109332013-08-09 Arnaud Charlet <charlet@adacore.com>
10934
10935 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
10936
fd9b0f32
PC
109372013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
10938
10939 PR c++/58080
10940 * c-common.c (pointer_int_sum): Add bool parameter.
10941 * c-common.h (pointer_int_sum): Adjust declaration.
10942
e0aec1e9
GDR
109432013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
10944
10945 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
10946 c_pretty_printer variable.
10947
b066401f
GDR
109482013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
10949
10950 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
10951 (pp_base): Remove.
10952 (pp_c_base): Likewise. Adjust users.
10953 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
10954 (pp_c_whitespace): Do not call pp_base.
10955 (pp_c_left_paren): Likewise.
10956 (pp_c_right_paren): Likewise.
10957 (pp_c_left_brace): Likewise.
10958 (pp_c_right_brace): Likewise.
10959 (pp_c_left_bracket): Likewise.
10960 (pp_c_right_bracket): Likewise.
10961 (pp_c_dot): Likewise.
10962 (pp_c_ampersand): Likewise.
10963 (pp_c_star): Likewise.
10964 (pp_c_arrow): Likewise.
10965 (pp_c_semicolon): Likewise.
10966 (pp_c_complement): Likewise.
10967 (pp_c_exclamation): Likewise.
10968 (pp_c_direct_declarator): Likewise.
10969 (pp_c_ws_string): Likewise.
10970 (pp_c_identifier): Likewise.
10971 (pp_c_statement): Likewise.
10972 (print_c_tree): Likewise.
10973
65e5a578
ESR
109742013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
10975
10976 PR c++/58072
10977 * c-common.c (c_parse_error): Catch user-defined literal tokens and
10978 provide useful error strings.
10979
137a1a27
GDR
109802013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
10981
10982 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
10983 printer functions instead of pp_string or operators and punctuators.
10984 (dump_generic_ada_node): Likewise.
10985 * c-pretty-print.c (pp_c_type_specifier): Likewise.
10986 (pp_c_relational_expression): Likewise.
10987 (pp_c_logical_or_expression): Likewise.
10988
07838b13
GDR
109892013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
10990
10991 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
10992 functions instead of pp_character.
10993 (pp_ada_tree_identifier): Likewise.
10994 (dump_ada_double_name): Likewise.
10995 (dump_ada_function_declaration): Likewise.
10996 (dump_ada_array_domains): Likewise.
10997 (dump_template_types): Likewise.
10998 (dump_generic_ada_node): Likewise.
10999 (print_ada_declaration): Likewise.
11000 (print_ada_struct_decl): Likewise.
11001 * c-pretty-print.c (pp_c_integer_constant): Likewise.
11002
433cc7b0
TT
110032013-07-23 Tom Tromey <tromey@redhat.com>
11004
11005 * c-common.h (enum rid) <RID_GENERIC>: New constant.
11006 * c-common.c (c_common_reswords): Add _Generic.
11007
688010ba
OB
110082013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
11009
11010 * c-common.c: Fix typos.
11011 * c-common.h: Likewise.
11012
2a99e5e6
LL
110132013-07-13 Lubos Lunak <l.lunak@suse.cz>
11014
11015 PR c++/55203
11016 * c-common.c (c_common_attribute_table): Add warn_unused.
11017 (handle_warn_unused_attribute): New.
11018
c26302d5
JJ
110192013-07-10 Jakub Jelinek <jakub@redhat.com>
11020
11021 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
11022 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
11023
dfeadaa0
PC
110242013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
11025
11026 PR c++/57869
11027 * c.opt: Add Wconditionally-supported.
11028
6a2fa4b2
GS
110292013-07-08 Graham Stott <graham.stott@btinternet.com>
11030
adfac8df 11031 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6a2fa4b2
GS
11032 unused variables l_length and l_node.
11033
ecdbd01a 110342013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
11035
11036 PR c/57821
11037 * c-common.c (complete_array_type): Delay folding first index
11038 like other indices. When folding, check for index overflow.
11039
bedc293e
MG
110402013-06-27 Marc Glisse <marc.glisse@inria.fr>
11041
11042 PR c++/57509
11043 * c-common.h (c_build_vec_perm_expr): New complain argument.
11044 * c-common.c (c_build_vec_perm_expr): Likewise.
11045 Use save_expr also in C++.
11046
604b2bfc
GDR
110472013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
11048
11049 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
11050 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
11051 * c-opts.c (c_common_post_options): Likewise.
11052
dfeadaa0 110532013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
713b46fa
BI
11054
11055 * array-notation-common.c (length_mismatch_in_expr): Changed the
11056 parameter type's from a dynamic array to a vec_tree. Also removed
11057 the size parameters.
11058 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
11059 the change above.
11060
2ce86d2e
BI
110612013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
11062
11063 * c-common.h (struct cilkplus_an_parts): New structure.
11064 (struct cilkplus_an_loop_parts): Likewise.
11065 (cilkplus_extract_an_triplets): New prototype.
11066 (fix_sec_implicit_args): Likewise.
11067 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
11068 (fix_sec_implicit_args): Likewise.
604b2bfc 11069
07a6825b
BI
110702013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
11071
11072 * array-notation-common.c (find_inv_trees): Removed an unwanted
11073 typecasting.
11074 * c-common.h (struct inv_list::additional_tcodes): Changed type from
11075 enum rid to enum tree_code.
11076
08346abd
JH
110772013-06-11 Jan Hubicka <jh@suse.cz>
11078
11079 * c-common.c (handle_alias_ifunc_attribute): Do not set
11080 DECL_EXTERNAL for weakref variables.
11081 * c-pragma.c (handle_pragma_weak): Make sure aliases
11082 are not declared as external.
11083
d60f1706
BI
110842013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
11085
11086 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
11087 function from c/c-array-notation.c.
11088 (is_cilkplus_reduce_builtin): Likewise.
11089 (find_rank): Likewise.
11090 (extract_array_notation_exprs): Likewise.
11091 (replace_array_notations): Likewise.
11092 (find_inv_trees): Likewise.
11093 (replace_inv_trees): Likewise.
11094 (contains_array_notation_expr): Likewise.
11095 (find_correct_array_notation_type): Likewise.
11096 * c-common.h (struct inv_list): Moved this struct from the file
11097 c/c-array-notation.c and added a new field called additional tcodes.
11098 (length_mismatch_in_expr_p): New prototype.
11099 (is_cilkplus_reduce_builtin): Likewise.
11100 (find_rank): Likewise.
11101 (extract_array_notation_exprs): Likewise.
11102 (replace_array_notation): Likewise.
11103 (find_inv_trees): Likewise.
11104 (replace_inv_trees): Likewise.
11105 (find_correct_array_notation_type): Likewise.
dfeadaa0 11106
36536d79
BI
111072013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
11108
11109 * c-common.c (c_define_builtins): When cilkplus is enabled, the
11110 function array_notation_init_builtins is called.
11111 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
11112 * c-common.def (ARRAY_NOTATION_REF): New tree.
11113 * c-common.h (build_array_notation_expr): New function declaration.
11114 (build_array_notation_ref): Likewise.
11115 (extract_sec_implicit_index_arg): New extern declaration.
11116 (is_sec_implicit_index_fn): Likewise.
11117 (ARRAY_NOTATION_CHECK): New define.
11118 (ARRAY_NOTATION_ARRAY): Likewise.
11119 (ARRAY_NOTATION_START): Likewise.
11120 (ARRAY_NOTATION_LENGTH): Likewise.
11121 (ARRAY_NOTATION_STRIDE): Likewise.
11122 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
11123 ARRAY_NOTATION_REF.
11124 (pp_c_expression): Likewise.
11125 * c.opt (flag_enable_cilkplus): New flag.
11126 * array-notation-common.c: New file.
11127
f7716d57
JJ
111282013-05-14 Jakub Jelinek <jakub@redhat.com>
11129
11130 PR c++/57274
11131 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
11132
a5e0cd1d
MG
111332013-05-10 Marc Glisse <marc.glisse@inria.fr>
11134
11135 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
11136 vectors.
11137
f6bc1c4a
HS
111382013-05-07 Han Shen <shenhan@google.com>
11139
11140 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
11141
3f12f6e9
SKS
111422013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
11143
11144 * c-common.c (check_user_alignment): Emit error for negative values.
11145
61949153
PC
111462013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
11147
11148 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
11149
e93e18e9
PC
111502013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
11151
11152 * c-cppbuiltin.c (c_cpp_builtins): Do not define
11153 __GXX_EXPERIMENTAL_CXX1Y__.
11154
44d90fe1 111552013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
8e745a17 11156 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
44d90fe1
PC
11157
11158 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
11159 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
11160 to simply use OPT_Wpointer_arith.
11161 (c_sizeof_or_alignof_type): Likewise.
11162
13f39b2e
PC
111632013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
11164
11165 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
11166
4b84d650
JJ
111672013-04-12 Jakub Jelinek <jakub@redhat.com>
11168
11169 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
11170 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
11171 specifiers.
11172
fb037b5d
SB
111732013-04-07 Steven Bosscher <steven@gcc.gnu.org>
11174
11175 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
11176
4e856798
PC
111772013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
11178
11179 * c-common.c (pointer_int_sum): Remove dead code.
11180
4b1baac8
RS
111812013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
11182
11183 PR middle-end/56524
11184 * c-common.c (handle_optimize_attribute): Don't call
11185 save_optabs_if_changed.
11186
0b50e654
JJ
111872013-03-05 Jakub Jelinek <jakub@redhat.com>
11188
11189 PR middle-end/56461
11190 * c-pch.c (pch_init): Free target_validity at the end.
11191
48c41403
JJ
111922013-03-04 Jakub Jelinek <jakub@redhat.com>
11193
11194 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
11195
e664c61c
KS
111962013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
11197 Jakub Jelinek <jakub@redhat.com>
11198
11199 PR sanitizer/56454
11200 * c-common.c (handle_no_sanitize_address_attribute): New function.
11201 (c_common_attribute_table): Add no_sanitize_address attribute.
11202 (handle_no_address_safety_analysis_attribute): Add
11203 no_sanitize_address attribute, not no_address_safety_analysis
11204 attribute.
11205
a475fd3d 112062013-02-18 Aldy Hernandez <aldyh@redhat.com>
135204dd
AH
11207
11208 PR target/52555
11209 * c-common.c (handle_optimize_attribute): Call
11210 save_optabs_if_changed.
11211
f6007d99
JJ
112122013-02-18 Jakub Jelinek <jakub@redhat.com>
11213 Steven Bosscher <steven@gcc.gnu.org>
11214
11215 PR pch/54117
11216 * c-opts.c (c_common_post_options): If debug info is enabled
11217 and non-dwarf*, refuse to load PCH files and when writing PCH
11218 file warn.
11219
cf35e2b1
JJ
112202013-02-05 Jakub Jelinek <jakub@redhat.com>
11221
11222 PR middle-end/56167
11223 * c-common.c (handle_error_attribute): Fix condition.
11224
32887460
JJ
112252013-01-30 Jakub Jelinek <jakub@redhat.com>
11226
11227 PR c++/55742
11228 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
11229
5af057d8
JM
112302013-01-18 Jason Merrill <jason@redhat.com>
11231
11232 PR target/54908
11233 * c.opt (-fextern-tls-init): New.
11234 * c-opts.c (c_common_post_options): Handle it.
11235
cc83c823
JJ
112362013-01-09 Jakub Jelinek <jakub@redhat.com>
11237
11238 PR c/48418
11239 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
11240 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
11241 and is either negative or bigger or equal to type precision
11242 of the first operand.
11243
a859517f
MP
112442012-12-03 Marek Polacek <polacek@redhat.com>
11245
11246 PR c/55570
11247 * c-common.c (check_user_alignment): Swap order of tests,
11248 check TREE_CODE first.
11249
2d7aa578
ESR
112502012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
11251
11252 PR c++/52654
11253 * c-common.h (overflow_type): New enum.
11254 (build_userdef_literal): Add overflow_type argument.
11255 (tree_userdef_literal): Add overflow_type.
11256 (USERDEF_LITERAL_OVERFLOW): New access macro.
11257 * c-common.c (build_userdef_literal): Add overflow_type
11258 argument.
11259 * c-lex.c (c_lex_with_flags): Add overflow_type to
11260 build_userdef_literal calls.
11261 (interpret_integer, interpret_float): Add overflow_type argument.
11262
cc3c4f62
RB
112632012-11-28 Richard Biener <rguenther@suse.de>
11264
11265 PR c/35634
11266 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
11267 here and use a type with proper overflow behavior for types that would
11268 need to be promoted for the arithmetic.
11269
77bc5132
JJ
112702012-11-23 Jakub Jelinek <jakub@redhat.com>
11271
11272 PR sanitizer/55435
11273 * c-common.c (handle_no_address_safety_analysis_attribute): New
11274 function.
11275 (c_common_attribute_table): Add no_address_safety_analysis.
11276
5dc99c46
SB
112772012-11-16 Simon Baldwin <simonb@google.com>
11278
11279 * c.opt: Add f[no-]canonical-system-headers.
11280 * c-opts.c (c_common_handle_option): Handle
11281 OPT_fcanonical_system_headers.
11282
a4a0016d
ESR
112832012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
11284
11285 PR c++/54413
11286 * c-opts.c (c_common_handle_option): Set new flags.
11287 * c.opt: Describe new flags.
11288
7dbb85a7
JM
112892012-11-09 Jason Merrill <jason@redhat.com>
11290
11291 * c.opt (Wabi-tag): New.
11292
ad7bac31
AK
112932012-11-09 Andi Kleen <ak@linux.intel.com>
11294
11295 PR 55139
11296 * c-common.c (get_atomic_generic_size): Mask with
8e745a17 11297 MEMMODEL_MASK
ad7bac31 11298
7332899a
MLI
112992012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
11300
11301 PR c/53063
11302 * c.opt (Wformat): Make it Alias Wformat=1.
11303 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
11304 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
11305 LangEnabledBy.
11306 (Wformat=): RejectNegative. Use LangEnabledBy.
11307 (Wnonnull): Use LangEnabledBy.
11308 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
11309 * c-format.c (set_Wformat): Delete.
11310 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
ab20d992
JJ
11311 (maybe_read_dollar_number): Likewise.
11312 (avoid_dollar_number): Likewise.
11313 (finish_dollar_format_checking): Likewise.
11314 (check_format_info): Likewise.
11315 (check_format_info_main): Likewise.
11316 (check_format_types): Likewise.
11317 (format_type_warning): Likewise.
11318 * c-common.c (int): Likewise.
11319 (check_function_sentinel): Likewise.
8e745a17 11320 * c-common.h (warn_format,set_Wformat): Do not declare here.
7332899a 11321
34a180a6
MLI
113222012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
11323
11324 PR c/53063
11325 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
11326 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
11327 Use LangEnabledBy.
11328 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
11329 common.opt.
11330 (Wvariadic-macros): Init(1).
11331 * c-opts.c (c_common_handle_option): Do not handle them
11332 explicitly.
11333 (c_common_post_options): Likewise.
11334 (sanitize_cpp_opts): warn_unused_macros is now
11335 cpp_warn_unused_macros.
11336 (push_command_line_include): Likewise.
11337 * c-common.c (warn_unknown_pragmas): Do not define.
11338 * c-common.h (warn_unknown_pragmas): Do not declare.
11339
3f46d6a5
MLI
113402012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
11341
11342 PR c/51294
11343 * c-common.c (conversion_warning): Handle conditional expressions.
11344
880661a4
JW
113452012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
11346
11347 PR c++/54930
11348 * c.opt (Wreturn_local_addr): Define new option.
11349
4514a96b
JM
113502012-10-25 Jason Merrill <jason@redhat.com>
11351
f14edc1a
JM
11352 * c.opt (Wvirtual-move-assign): New.
11353
4514a96b
JM
11354 * c.opt (Winherited-variadic-ctor): New.
11355
93100c6b
MG
113562012-10-25 Marc Glisse <marc.glisse@inria.fr>
11357
11358 PR c++/54427
11359 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
11360
1efcb8c6
JM
113612012-10-23 Joseph Myers <joseph@codesourcery.com>
11362
11363 * c-common.h (pch_cpp_save_state): Declare.
11364 * c-target.def (c_preinclude): New hook.
11365 * c-opts.c (done_preinclude): New.
11366 (push_command_line_include): Handle default preincluded header.
11367 (cb_file_change): Call pch_cpp_save_state when calling
11368 push_command_line_include.
11369 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
11370 (pch_cpp_save_state): New.
11371 (pch_init): Call pch_cpp_save_state conditionally, instead of
11372 calling cpp_save_state.
11373
4a0ae68e
MLI
113742012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
11375
11376 PR c/53063
11377 PR c/40989
11378 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
11379 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
11380 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
11381 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
11382 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
11383 * c-opts.c (c_common_handle_option): Remove explicit handling from
11384 here.
11385 (c_common_post_options): Likewise.
11386
67e4210b
EB
113872012-10-18 Eric Botcazou <ebotcazou@adacore.com>
11388
11389 * c-ada-spec.c (LOCATION_COL): Delete.
11390 (compare_location): New function.
11391 (compare_node): Use it.
11392 (compare_comment): Likewise.
11393
65d4f2cd
MLI
113942012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
11395
11396 PR c/53063
11397 PR c/40989
11398 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
11399 * c-opts.c (c_common_handle_option): Do not set them here. Add
11400 comment.
11401 (c_common_post_options): Likewise.
11402
909881cb
EB
114032012-10-16 Eric Botcazou <ebotcazou@adacore.com>
11404
11405 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
11406 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
11407 Remove POINTER_TYPE handling, add large unsigned handling and use
11408 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
11409
3a785c97
JJ
114102012-10-12 Jakub Jelinek <jakub@redhat.com>
11411
11412 PR c/54381
11413 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
11414 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
11415 locs and array of 3 trees instead of just single loc and single
11416 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
11417 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
11418 For *cmp* builtins that take two sources strings report warnings
11419 about first and second source, not about destination and source.
11420
5e54f81d
MG
114212012-10-12 Marc Glisse <marc.glisse@inria.fr>
11422
11423 PR c++/53055
11424 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
11425
f5b02f1e
EB
114262012-10-11 Eric Botcazou <ebotcazou@adacore.com>
11427
11428 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
11429 declaring something coming from another file.
11430
b46dbc6c
AC
114312012-10-10 Arnaud Charlet <charlet@adacore.com>
11432
f5b02f1e 11433 PR ada/54845
b46dbc6c
AC
11434 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
11435
5d9de0d0
PC
114362012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
11437
11438 PR c++/54194
11439 * c-common.c (warn_about_parentheses): Add location_t parameter;
11440 use EXPR_LOC_OR_LOC.
11441 * c-common.h: Update declaration.
11442
a212e43f
MG
114432012-10-09 Marc Glisse <marc.glisse@inria.fr>
11444
11445 PR c++/54427
11446 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
11447 more operations. Make error messages optional.
11448 * c-common.h (enum stv_conv): Moved from c-typeck.c.
11449 (scalar_to_vector): Declare.
11450
b1db7f91
JM
114512012-10-08 Jason Merrill <jason@redhat.com>
11452
11453 * c-common.c (c_common_reswords): Add thread_local.
11454
e28d52cf
DS
114552012-10-08 Dodji Seketeli <dodji@redhat.com>
11456
11457 PR c++/53528 C++11 attribute support
11458 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
11459 new functions.
11460 * c-common.c (check_cxx_fundamental_alignment_constraints): New
11461 static function.
11462 (handle_aligned_attribute): In choose strictest alignment
11463 among many. Use new check_cxx_fundamental_alignment_constraints.
11464 (handle_transparent_union_attribute): In c++11 attribute syntax,
11465 don't look through typedefs.
11466
3b78de56
AC
114672012-10-04 Arnaud Charlet <charlet@adacore.com>
11468
11469 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
11470 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
11471 out of dumpfile.h.
11472
6040bb5f
DC
114732012-09-25 Dehao Chen <dehao@google.com>
11474
11475 PR middle-end/54645
3b78de56 11476 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
6040bb5f
DC
11477 map when read in the pch.
11478
3f8257db 114792012-09-18 Arnaud Charlet <charlet@adacore.com>
0b07a57e
AC
11480
11481 * c-ada-spec.c: Style fixes.
11482
3f8257db 114832012-09-18 Thomas Quinot <quinot@adacore.com>
da5182be
TQ
11484
11485 * c.opt (-fada-spec-parent): Define new command line switch.
11486 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
11487 is specified, generate binding spec as a child of the specified unit.
11488
0ccb505d
PC
114892012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
11490 Manuel López-Ibáñez <manu@gcc.gnu.org>
11491
11492 PR c++/53210
11493 * c.opt ([Winit-self]): Enabled by -Wall in C++.
11494
c583af79
AC
114952012-08-23 Arnaud Charlet <charlet@adacore.com>
11496
11497 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
11498 for pointers, and add missing Convention C pragma.
11499 (print_ada_struct_decl): Add missing aliased keyword.
11500 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
11501
1a4049e7
JJ
115022012-08-17 Jakub Jelinek <jakub@redhat.com>
11503
11504 * c-common.c (sizeof_pointer_memaccess_warning): New function.
11505 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
11506 * c-opts.c (c_common_handle_option): Enable it for -Wall.
11507 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
11508 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
11509
70b5e7dc
RG
115102012-08-10 Richard Guenther <rguenther@suse.de>
11511
11512 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
11513
f8923f7e
SB
115142012-08-07 Steven Bosscher <steven@gcc.gnu.org>
11515
11516 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
11517 instead of separate pp_newline and pp_flush.
11518 (print_c_tree): Likewise.
11519
e45abe1f
RH
115202012-07-26 Richard Henderson <rth@redhat.com>
11521
11522 * c-common.c (handle_hot_attribute): Allow labels.
11523 (handle_cold_attribute): Likewise.
11524
332f1d24
JJ
115252012-07-20 Jakub Jelinek <jakub@redhat.com>
11526
11527 PR c++/28656
11528 * c-common.c (check_function_nonnull): Handle multiple nonnull
11529 attributes properly.
11530
7ee2468b
SB
115312012-07-16 Steven Bosscher <steven@gcc.gnu.org>
11532
11533 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
11534 * c-ada-spec.c: Likewise.
11535 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
11536
ee7b28eb
SB
115372012-07-14 Steven Bosscher <steven@gcc.gnu.org>
11538
11539 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
11540 Remove code conditional on it.
11541
6bdf3519
SB
115422012-07-11 Steven Bosscher <steven@gcc.gnu.org>
11543
11544 * c-gimplify.c: Do not include basic-block.h.
11545 * c-common.c: Do not include linfuncs.h.
11546
532aafad
SB
115472012-07-08 Steven Bosscher <steven@gcc.gnu.org>
11548
11549 * c-common.h: Include tree.h.
11550
8d0d1915
JM
115512012-07-02 Jason Merrill <jason@redhat.com>
11552
11553 PR c++/53524
11554 * c-common.c (get_priority): Call default_conversion.
11555
fbc873ad
UB
115562012-07-01 Uros Bizjak <ubizjak@gmail.com>
11557
11558 * c-pch.c (c_common_write_pch): Remove unused variables.
11559
d4a10d0a
SB
115602012-06-29 Steven Bosscher <steven@gcc.gnu.org>
11561
11562 * cppspec.c: Moved from gcc/ to here.
11563
6f3a2e23
KT
115642012-06-27 Kai Tietz <ktietz@redhat.com>
11565
11566 PR preprocessor/37215
11567 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
11568
8ca92d04
SB
115692012-06-21 Steven Bosscher <steven@gcc.gnu.org>
11570
11571 * c-common.h (c_common_print_pch_checksum): Remove.
11572 * c-pch.c: Do not include output.h.
11573 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
11574 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
11575 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
11576 (struct c_pch_header): Remove.
11577 (get_ident): Update gpch version.
11578 (pch_init): Do not print executable_checksum to asm_out_file.
11579 Do not fail if there is no asm_out_file to read back from. Set
11580 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
11581 (c_common_write_pch): Verify that nothing was written to asm_out_file
11582 since pch_init was called. Do not write a c_pch_header, and do not
11583 copy from asm_out_file to the PCH.
11584 (c_common_read_pch): Do not read a c_pch_header, and do not restore
11585 the content of asm_out_file from the PCH.
11586 (c_common_print_pch_checksum): Remove.
11587 * c-opts.c (c_common_init): Print out executable_checksum directly.
11588
70f42967
SB
115892012-06-19 Steven Bosscher <steven@gcc.gnu.org>
11590
11591 * c-target.def (objc_declare_unresolved_class_reference,
11592 objc_declare_class_definition): Add new hooks.
11593
a8781821
SB
115942012-06-19 Steven Bosscher <steven@gcc.gnu.org>
11595
11596 * c-lex.c: Do not include output.h.
11597 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
11598 Remove uses of ASM_OUTPUT_IDENT.
11599
9e1a8dd1
RR
116002012-06-15 Marc Glisse <marc.glisse@inria.fr>
11601
11602 PR c++/51033
11603 * c-common.h (c_build_vec_perm_expr): Move decl here.
11604 * c-common.c (c_build_vec_perm_expr): Move definition
11605 here.
11606
6f07a821
SB
116072012-06-06 Steven Bosscher <steven@gcc.gnu.org>
11608
11609 * c.opt (fconserve-space): Turn into a no-op.
11610
9faeb493 116112012-06-04 Sterling Augustine <saugustine@google.com>
c265f413
SA
11612
11613 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
11614 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
11615 both the start and end of the function.
11616
a4b7d13c
SB
116172012-06-04 Steven Bosscher <steven@gcc.gnu.org>
11618
11619 * c-common.c: Do not include output.h.
11620 * c-pragma.c: Likewise.
11621
c265f413
SA
116222012-06-04 Steven Bosscher <steven@gcc.gnu.org>
11623
11624 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
11625 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
11626 (lang_decl_name): Handle namespace decls.
11627
be7a421e
SB
116282012-05-31 Steven Bosscher <steven@gcc.gnu.org>
11629
11630 * c-ada-spec.c: Do not include output.h.
11631 * c-semantics.c: Likewise.
11632
65de6659
JM
116332012-05-29 Joseph Myers <joseph@codesourcery.com>
11634
11635 * c-common.c: Fix typo.
11636
ca5f4331
MM
116372012-05-29 Michael Matz <matz@suse.de>
11638
11639 * c-common.h (c_expand_decl): Remove prototype.
11640
4f7f7aca
MLI
116412012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
11642
11643 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
11644 * c-opts.c (c_common_handle_option): Remove code handling
11645 warn_missing_braces.
11646
4a792f9b
PC
116472012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
11648
11649 PR c++/25137
11650 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
11651 -Wmissing_braces.
11652
650dc14a
DS
116532012-05-22 Dodji Seketeli <dodji@redhat.com>
11654
11655 PR c++/53322
11656 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
11657
9b095bf1
MLI
116582012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
11659
11660 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
11661 * c-opts.c (c_common_handle_option): Do not handle explicitly
11662 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
11663
0b2c4be5
DS
116642012-05-16 Dodji Seketeli <dodji@redhat.com>
11665
11666 PR preprocessor/7263
ab20d992 11667 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
0b2c4be5
DS
11668 to cpp_classify_number. For diagnostics, use the precise location
11669 instead of the global input_location.
11670
a1bde5af
PC
116712012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
11672
d02924ef 11673 PR c++/11856
a1bde5af
PC
11674 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
11675
d1ede5f4
BS
116762012-05-14 Bernd Schmidt <bernds@codesourcery.com>
11677
a1bde5af 11678 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
d1ede5f4 11679
f2bc201f
MLI
116802012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
11681
11682 PR 53063
11683 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
11684 Wreorder): Use LangEnabledBy.
11685 * c-opts.c (c_common_handle_option): Do not enable them
11686 explicitly. Call lang-specific generated functions.
11687 (c_common_post_options): Do not set them here.
11688
95744782
MLI
116892012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
11690
11691 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
11692 Wmissing-field-initializers,Wmissing-parameter-type,
11693 Wold-style-declaration,Woverride-init): Use EnabledBy.
11694 * c-opts.c (c_common_post_options): Do not set here explicitly.
11695
7d5a5747
MLI
116962012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
11697
11698 PR 53063
11699 * c-opts.c (c_common_handle_option): Use handle_generated_option
11700 to enable sub-options.
11701
5a3c9cf2
PC
117022012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
11703
11704 PR c++/53158
11705 * c-common.c (warnings_for_convert_and_check): Use warning_at.
11706
3ac8781c
RG
117072012-05-10 Richard Guenther <rguenther@suse.de>
11708
11709 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
11710 adjust commentary about TYPE_IS_SIZETYPE types.
11711
1e537948
MLI
117122012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
11713
11714 PR c++/53261
11715 * c-common.c (warn_logical_operator): Check that argument of
11716 integer_zerop is not NULL.
11717
f2c4a785
MLI
117182012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
11719
11720 PR c/43772
11721 * c-common.c (warn_logical_operator): Do not warn if either side
11722 is already true or false.
11723
50f305ca
MLI
117242012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
11725
11726 PR c/51712
11727 * c-common.c (expr_original_type): New.
11728 (shorten_compare): Do not warn for enumeration types.
11729
0c3641b0
MLI
117302012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
11731
11732 * c.opt (fpermissive): Add Var(flag_permissive).
11733
7edaa4d2
MG
117342012-04-30 Marc Glisse <marc.glisse@inria.fr>
11735
11736 PR c++/51033
11737 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
11738 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
11739
b9c8da34
DS
117402012-04-30 Dodji Seketeli <dodji@redhat.com>
11741
11742 Add -Wvarargs option
ab20d992 11743 * c.opt (Wvarargs): Define new option.
b9c8da34 11744
e6c69da0
MLI
117452012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
11746
11747 * c-common.c (check_function_arguments): Replace
11748 Wmissing-format-attribute with Wsuggest-attribute=format.
11749
90137d8f
MLI
117502012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
11751
11752 * c.opt (Wsuggest-attribute=format): New. Alias of
11753 Wmissing-format-attribute.
11754 * c-format.c (decode_format_type): Replace
11755 Wmissing-format-attribute with Wsuggest-attribute=format.
11756 (check_function_format): Likewise.
11757
9faeb493 117582012-04-27 Ollie Wild <aaw@google.com>
7f5f5f98
OW
11759
11760 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
11761 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
11762 * c.opt: Add Wliteral-suffix.
11763
c1771a20
MLI
117642012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
11765
11766 PR c/44774
11767 * c.opt (Wpedantic): New.
11768 (pedantic): Alias Wpedantic.
11769 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
11770 (c_common_post_options): Likewise.
11771 (sanitize_cpp_opts): Likewise.
11772 * c-lex.c (interpret_float): Likewise.
11773 * c-format.c (check_format_types): Likewise.
11774 * c-common.c (pointer_int_sum): Likewise.
11775 (c_sizeof_or_alignof_type): Likewise.
11776 (c_add_case_label): Likewise.
11777 (c_do_switch_warnings): Likewise.
11778 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
11779
04b391c1
JM
117802012-04-15 Jason Merrill <jason@redhat.com>
11781
11782 PR c++/52818
11783 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
11784 (C_STD_NAME): Distinguish between C++98 and C++11.
11785
ac868f29
EB
117862012-04-11 Eric Botcazou <ebotcazou@adacore.com>
11787
11788 PR target/52624
11789 * c-common.h (uint16_type_node): Rename into...
11790 (c_uint16_type_node): ...this.
11791 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
11792 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
11793
fd4116f4
MLI
117942012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
11795
11796 * c-common.c (warn_if_unused_value): Move definition to here.
11797 * c-common.h (warn_if_unused_value): Move declaration to here.
11798
573ac65e
WB
117992012-03-23 William Bader <williambader@hotmail.com>
11800
11801 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
11802
552b8185
JM
118032012-03-20 Jason Merrill <jason@redhat.com>
11804
11805 * c-common.h (enum cxx_dialect): Add cxx1y.
11806 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
11807 test.
11808 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
11809 * c-opts.c (c_common_post_options): Likewise.
11810 (set_std_cxx1y): New.
11811 (c_common_handle_option): Call it.
11812 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
11813
04398fa8
PC
118142012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
11815
11816 PR c++/14710
11817 * c.opt ([Wuseless-cast]): Add.
11818
d2a12ae7
RG
118192012-03-16 Richard Guenther <rguenther@suse.de>
11820
11821 * c-pretty-print.c (pp_c_initializer_list): Adjust.
11822
a12bf402
MLI
118232012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
11824
11825 PR c++/44783
11826 * c.opt (ftemplate-backtrace-limit) Add.
11827
5c30094f
RO
118282012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11829
11830 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
11831 handling.
11832 * c-pragma.c (handle_pragma_extern_prefix): Remove.
11833 (init_pragma): Don't register extern_prefix.
11834
21fa2faf
RG
118352012-03-12 Richard Guenther <rguenther@suse.de>
11836
11837 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
11838 (builtin_type_for_size): Likewise.
11839
e3793c6f
JJ
118402012-02-13 Jakub Jelinek <jakub@redhat.com>
11841
11842 PR c++/52215
11843 * c-common.c (sync_resolve_params): Don't decide whether to convert
11844 or not based on TYPE_SIZE comparison, convert whenever arg_type
11845 is unsigned INTEGER_TYPE.
11846
93286335
PC
118472012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
11848
11849 PR c/52118
11850 * c.opt ([Wunused-local-typedefs]): Fix description.
11851
7a421706
MS
118522012-01-24 Mike Stump <mikestump@comcast.net>
11853
11854 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
11855 exactly.
11856
ba9b1f11
RG
118572012-01-18 Richard Guenther <rguenther@suse.de>
11858
11859 * c-opts.c (c_common_post_options): Reset LTO flags if
11860 we are about to generate a PCH.
11861
465406be
PC
118622012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
11863
11864 PR c++/51777
11865 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
11866 use pp_unsigned_wide_integer.
11867
aee15221
RG
118682012-01-10 Richard Guenther <rguenther@suse.de>
11869
11870 PR middle-end/51806
11871 * c-opts.c (c_common_handle_option): Move -Werror handling
11872 to language independent code.
11873
5720c0dc
RG
118742012-01-05 Richard Guenther <rguenther@suse.de>
11875
11876 PR middle-end/51764
11877 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
11878 from common.opt.
11879
73ac190a
PC
118802011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
11881
11882 PR c++/51316
11883 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
11884 of array types with an unknown bound.
11885
48b0b196
JM
118862011-12-20 Joseph Myers <joseph@codesourcery.com>
11887
11888 * c-common.c (flag_isoc99): Update comment to refer to C11.
11889 (flag_isoc1x): Change to flag_isoc11.
11890 * c-common.h (flag_isoc99): Update comment to refer to C11.
11891 (flag_isoc1x): Change to flag_isoc11.
11892 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
11893 C11.
11894 * c-opts.c (set_std_c1x): Change to set_std_c11.
11895 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
11896 Call set_std_c11.
11897 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
11898 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
11899 * c.opt (std=c1x): Change to std=c11. Document as non-draft
11900 standard.
11901 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
11902 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
11903 (std=gnu1x): Make alias of std=gnu11.
11904
d58d6eb5
JM
119052011-12-19 Jason Merrill <jason@redhat.com>
11906
11907 PR c++/51228
11908 * c-common.c (handle_transparent_union_attribute): Check the first
11909 field if the type is complete.
11910
b3908fcc
JW
119112011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
11912
11913 PR libstdc++/51365
11914 * c-common.c (RID_IS_FINAL): Add.
11915 * c-common.h (RID_IS_FINAL): Add.
11916
fea3ca91
IS
119172011-11-30 Iain Sandoe <iains@gcc.gnu.org>
11918
11919 * c.opt (fgnu-runtime): Provide full description.
11920 (fnext-runtime): Likewise.
11921 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
11922
62bad7cd
AM
119232011-11-28 Andrew MacLeod <amacleod@redhat.com>
11924
11925 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
11926 predefines in one place. Add LOCK_FREE predefines.
11927 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
11928 new func.
11929
c466c4ff
AM
119302011-11-24 Andrew MacLeod <amacleod@redhat.com>
11931
11932 PR c/51256
9faeb493 11933 * c-common.c (get_atomic_generic_size): Check for various error
c466c4ff 11934 conditions
9faeb493
UB
11935 (resolve_overloaded_atomic_exchange,
11936 resolve_overloaded_atomic_compare_exchange,
c466c4ff
AM
11937 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
11938 error_mark_node for error conditions.
9faeb493 11939
a5952633
RG
119402011-11-08 Richard Guenther <rguenther@suse.de>
11941
11942 PR middle-end/51010
ab20d992 11943 * c-pretty-print.c (pp_c_expression): Handle SSA_NAMEs.
a5952633 11944
0a35513e
AH
119452011-11-07 Richard Henderson <rth@redhat.com>
11946 Aldy Hernandez <aldyh@redhat.com>
11947 Torvald Riegel <triegel@redhat.com>
11948
11949 Merged from transactional-memory.
11950
11951 * c-common.c (handle_tm_wrap_attribute,
11952 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
11953 (struct c_common_reswords): Added __transaction* keywords.
11954 (struct c_common_attribute_table): Added transaction* and tm_regparm
11955 attributes.
11956 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
11957 masks.
11958 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
11959 find_tm_attribute): Declare.
11960
6d87092d
JM
119612011-11-07 Jason Merrill <jason@redhat.com>
11962
11963 PR c++/35688
11964 * c-common.c, c-common.h: Revert yesterday's changes.
11965
8e7860a1
JM
119662011-11-06 Jason Merrill <jason@redhat.com>
11967
11968 PR c++/35688
11969 * c-common.c (decl_has_visibility_attr): Split out from...
11970 (c_determine_visibility): ...here.
11971 * c-common.h: Declare it.
11972
d19fa6b5
JM
119732011-11-06 Joseph Myers <joseph@codesourcery.com>
11974
11975 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
11976 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
11977 type.
11978 (check_user_alignment): New. Split out of
11979 handle_aligned_attribute. Disallow integer constants with
11980 noninteger types. Conditionally allow zero.
11981 (handle_aligned_attribute): Use check_user_alignment.
11982 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
11983
86951993
AM
119842011-11-06 Andrew MacLeod <amacleod@redhat.com>
11985 Richard Henderson <rth@redhat.com>
11986
11987 Merged from cxx-mem-model.
11988
11989 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
9faeb493 11990 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
86951993
AM
11991 parameters that are the same type size.
11992 (get_atomic_generic_size): New. Find size of generic
11993 atomic function parameters and do typechecking.
11994 (add_atomic_size_parameter): New. Insert size into parameter list.
11995 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
11996 either __atomic_exchange_n or external library call.
9faeb493 11997 (resolve_overloaded_atomic_compare_exchange): Restructure
86951993 11998 __atomic_compare_exchange to either _n variant or external library call.
9faeb493 11999 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
86951993
AM
12000 __atomic_load_n or an external library call.
12001 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
12002 __atomic_store_n or an external library call.
12003 (resolve_overloaded_builtin): Handle new __atomic builtins.
12004
cf9e9959
EB
120052011-11-04 Eric Botcazou <ebotcazou@adacore.com>
12006
12007 PR c++/50608
12008 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
12009 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
12010 <INDIRECT_REF>: Return the argument.
12011 <ARRAY_REF>: Remove special code for negative offset.
12012 Call fold_build_pointer_plus instead of size_binop.
12013 (fold_offsetof): Remove STOP_REF argument and adjust.
12014 * c-common.h (fold_offsetof_1): Declare.
12015 (fold_offsetof): Remove STOP_REF argument.
12016
25339f10
JM
120172011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
12018
12019 PR c++/50810
12020 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
12021 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
12022 Wnarrowing for C++0x and C++98.
12023 * c.opt ([Wnarrowing]): Update.
12024
89401152
PC
120252011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
12026
12027 PR c++/44277
12028 * c.opt: Add Wzero-as-null-pointer-constant.
12029
97e3ad20
JM
120302011-10-31 Jason Merrill <jason@redhat.com>
12031
15694fdd
JM
12032 * c.opt (-fdeduce-init-list): Off by default.
12033
97e3ad20
JM
12034 PR c++/50920
12035 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
12036 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
12037 and -Wc++11-compat.
12038 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
12039
fb9120e3
RAV
120402011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
12041
12042 PR c++/30066
12043 * c.opt (fvisibility-inlines-hidden): Description change.
12044
3ce4f9e4
ESR
120452011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
12046
12047 Implement C++11 user-defined literals.
12048 * c-common.c (build_userdef_literal): New.
12049 * c-common.def: New tree code.
12050 * c-common.h (tree_userdef_literal): New tree struct and accessors.
12051 * c-lex.c (interpret_float): Add suffix parm.
12052 (c_lex_with_flags): Build literal tokens.
12053
5f53c243
PC
120542011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
12055
12056 PR c++/50841
12057 Revert:
12058 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
12059
12060 PR c++/50810
12061 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
12062 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
12063 Wnarrowing for C++0x and C++98.
12064 * c.opt ([Wnarrowing]): Update.
12065
263734e1
PC
120662011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
12067
12068 PR c++/50810
12069 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
12070 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
12071 Wnarrowing for C++0x and C++98.
12072 * c.opt ([Wnarrowing]): Update.
12073
d2e312d7
PC
120742011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
12075
12076 PR c++/45385
12077 * c-common.c (conversion_warning): Remove code looking for
12078 artificial operands.
12079
d17687f6
DS
120802011-10-18 Dodji Seketeli <dodji@redhat.com>
12081
12082 PR bootstrap/50760
12083 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
9faeb493 12084 !NO_IMPLICIT_EXTERN_C.
d17687f6 12085
fc8396e9
PC
120862011-10-17 Michael Spertus <mike_spertus@symantec.com>
12087
12088 * c-common.c (c_common_reswords): Add __bases,
12089 __direct_bases.
12090 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
12091
120922011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
12093
12094 PR c++/50757
12095 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
12096
847e697a
TT
120972011-10-15 Tom Tromey <tromey@redhat.com>
12098 Dodji Seketeli <dodji@redhat.com>
12099
12100 * c.opt (fdebug-cpp): New option.
12101 * c-opts.c (c_common_handle_option): Handle the option.
12102 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
12103 output stream in parameter. Factorized from ...
12104 (maybe_print_line): ... this. Dump location debug information when
12105 -fdebug-cpp is in effect.
12106 (print_line_1): New static function. Takes an output stream in
12107 parameter. Factorized from ...
12108 (print_line): ... here. Dump location information when -fdebug-cpp
12109 is in effect.
12110 (scan_translation_unit): Dump location information when
12111 -fdebug-cpp is in effect.
12112
92582b75
TT
121132011-10-15 Tom Tromey <tromey@redhat.com>
12114 Dodji Seketeli <dodji@redhat.com>
12115
12116 * c.opt (ftrack-macro-expansion): New option. Handle it with and
12117 without argument.
12118 * c-opts.c (c_common_handle_option)<case
12119 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
12120 cases. Handle -ftrack-macro-expansion with and without argument.
12121
46427374
TT
121222011-10-15 Tom Tromey <tromey@redhat.com>
12123 Dodji Seketeli <dodji@redhat.com>
12124
12125 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
12126 (print_line, cb_define, do_line_change): Adjust to avoid touching
12127 the internals of struct line_map. Use the public API instead.
12128 * c-pch.c (c_common_read_pch): Likewise.
12129 * c-lex.c (fe_file_change): Likewise.
12130
fc8396e9
PC
121312011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
12132
12133 PR c++/17212
12134 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
12135
121362011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
12137
12138 PR c++/33067
12139 * c-pretty-print.c (pp_c_floating_constant): Output
12140 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
12141
e79983f4
MM
121422011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
12143
12144 * c-common.c (def_builtin_1): Delete old interface with two
12145 parallel arrays to hold standard builtin declarations, and replace
12146 it with a function based interface that can support creating
12147 builtins on the fly in the future. Change all uses, and poison
12148 the old names. Make sure 0 is not a legitimate builtin index.
12149 * c-omp.c (c_finish_omp_barrier): Ditto.
12150 (c_finish_omp_taskwait): Ditto.
12151 (c_finish_omp_flush): Ditto.
12152
6637388f
TG
121532011-10-11 Tristan Gingold <gingold@adacore.com>
12154
12155 * c.opt: (fallow-parameterless-variadic-functions): New.
12156
3797cb21
DS
121572011-09-08 Dodji Seketeli <dodji@redhat.com>
12158
12159 PR c++/33255 - Support -Wunused-local-typedefs warning
12160 * c-common.h (struct c_language_function::local_typedefs): New
12161 field.
9faeb493
UB
12162 (record_locally_defined_typedef, maybe_record_typedef_use)
12163 (maybe_warn_unused_local_typedefs): Declare new functions.
3797cb21 12164 * c-common.c (record_locally_defined_typedef)
9faeb493
UB
12165 (maybe_record_typedef_use)
12166 (maybe_warn_unused_local_typedefs): Define new functions.
3797cb21
DS
12167 * c.opt: Declare new -Wunused-local-typedefs flag.
12168
693ddb1b
EB
121692011-09-06 Eric Botcazou <ebotcazou@adacore.com>
12170
12171 PR middle-end/50266
12172 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
12173 computations.
12174
830c740f
RG
121752011-09-05 Richard Guenther <rguenther@suse.de>
12176
12177 * c-common.c (complete_array_type): Use ssize_int (-1) instead
12178 of integer_minus_one_node for empty array upper bounds.
12179
892a371f
DS
121802011-08-28 Dodji Seketeli <dodji@redhat.com>
12181
12182 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
12183 it's the first time it's being called on this main TU.
12184
0e3fdb48
RB
121852011-08-24 Richard Guenther <rguenther@suse.de>
12186
12187 PR c/49396
12188 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
12189
121902011-08-22 Gabriel Charette <gchare@google.com>
e3dfef44
GC
12191
12192 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
12193 defined in cpp_init_builtins and c_cpp_builtins.
12194
d4a83c10
JM
121952011-08-19 Joseph Myers <joseph@codesourcery.com>
12196
12197 * c-common.c (c_common_reswords): Add __builtin_complex.
12198 * c-common.h (RID_BUILTIN_COMPLEX): New.
12199
bbceee64
JM
122002011-08-18 Joseph Myers <joseph@codesourcery.com>
12201
12202 * c-common.c (c_common_reswords): Add _Noreturn.
12203 (keyword_is_function_specifier): Handle RID_NORETURN.
12204 * c-common.h (RID_NORETURN): New.
12205
3f8257db 122062011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
0e3a99ae
AS
12207
12208 * c-common.c (unsafe_conversion_p): New function. Check if it is
12209 unsafe to convert an expression to the type.
12210 (conversion_warning): Adjust, use unsafe_conversion_p.
12211 * c-common.h (unsafe_conversion_p): New function declaration.
12212
20906c66
JJ
122132011-08-02 Jakub Jelinek <jakub@redhat.com>
12214
12215 * c-common.h (c_finish_omp_atomic): Adjust prototype.
12216 (c_finish_omp_taskyield): New prototype.
12217 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
12218 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
12219 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
12220 or RHS1 have side-effects, evaluate those too in the right spot,
12221 if it is a decl and LHS is also a decl, error out if they
12222 aren't the same.
12223 (c_finish_omp_taskyield): New function.
12224 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
12225 * c-pragma.c (omp_pragmas): Add taskyield.
12226 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
12227 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
12228 PRAGMA_OMP_CLAUSE_MERGEABLE.
12229
770e5a2e
DS
122302011-07-25 Dodji Seketeli <dodji@redhat.com>
12231
12232 * c-common.h (set_underlying_type): Remove parm name from
12233 declaration.
12234
1baae426
RG
122352011-07-25 Romain Geissler <romain.geissler@gmail.com>
12236
12237 * c-pretty-print.h: Search c-common.h in c-family.
9faeb493 12238
fcb21722
JM
122392011-07-22 Jason Merrill <jason@redhat.com>
12240
76f86d00
JM
12241 PR c++/49793
12242 * c.opt (Wnarrowing): New.
12243
3a636414
JM
12244 PR c++/30112
12245 * c-common.h: Declare c_linkage_bindings.
12246 * c-pragma.c (handle_pragma_redefine_extname): Use it.
12247
fcb21722
JM
12248 PR c++/49813
12249 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
12250 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
12251 as flag_isoc99 for 'restrict'.
12252 (pp_c_specifier_qualifier_list): Likewise for _Complex.
12253
02614448
ILT
122542011-07-21 Ian Lance Taylor <iant@google.com>
12255
12256 PR middle-end/49705
12257 * c-common.c (c_disable_warnings): New static function.
12258 (c_enable_warnings): New static function.
12259 (c_fully_fold_internal): Change local unused_p to bool. Call
12260 c_disable_warnings and c_enable_warnings rather than change
12261 c_inhibit_evaluation_warnings.
12262
34429675
JM
122632011-07-20 Jason Merrill <jason@redhat.com>
12264
12265 PR c++/6709 (DR 743)
12266 PR c++/42603 (DR 950)
12267 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
12268 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
12269 (CPP_DECLTYPE): New.
12270 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
12271
5d49b6a7
RG
122722011-07-19 Richard Guenther <rguenther@suse.de>
12273
12274 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
12275 * c-omp.c (c_finish_omp_for): Likewise.
12276
e84a58ff
EB
122772011-07-12 Eric Botcazou <ebotcazou@adacore.com>
12278
12279 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
12280 body on the next line.
12281
329af3c7
JM
122822011-07-08 Jason Merrill <jason@redhat.com>
12283
4063e61b
JM
12284 PR c++/45437
12285 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
12286
329af3c7
JM
12287 PR c++/49673
12288 * c-common.c (c_apply_type_quals_to_decl): Don't check
12289 TYPE_NEEDS_CONSTRUCTING.
12290
1a072294
RG
122912011-07-06 Richard Guenther <rguenther@suse.de>
12292
12293 * c-common.c (c_common_nodes_and_builtins):
12294 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
12295
fce5dddd
RG
122962011-07-05 Richard Guenther <rguenther@suse.de>
12297
12298 * c-common.c (c_common_nodes_and_builtins): Build all common
12299 tree nodes first.
12300
45d439ac
JJ
123012011-06-27 Jakub Jelinek <jakub@redhat.com>
12302
56300785
JJ
12303 * c-common.h (c_tree_chain_next): New static inline function.
12304
45d439ac
JJ
12305 * c-common.c (check_builtin_function_arguments): Handle
12306 BUILT_IN_ASSUME_ALIGNED.
12307
e0a8ecf2
AM
123082011-06-21 Andrew MacLeod <amacleod@redhat.com>
12309
12310 * c-common.c: Add sync_ or SYNC__ to builtin names.
12311 * c-omp.c: Add sync_ or SYNC__ to builtin names.
dfb43cd5
PV
12312
123132011-06-20 Pierre Vittet <piervit@pvittet.com>
12314
12315 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
12316 handler.
12317 (gen_pragma_handler): New union.
12318 (internal_pragma_handler): New type.
12319 (c_register_pragma_with_data)
12320 (c_register_pragma_with_expansion_and_data): New functions.
12321
12322 * c-pragma.c (registered_pragmas, c_register_pragma_1)
12323 (c_register_pragma, c_register_pragma_with_expansion)
12324 (c_invoke_pragma_handler): Changed to work with
12325 internal_pragma_handler.
12326 (c_register_pragma_with_data)
12327 (c_register_pragma_with_expansion_and_data): New functions.
12328
677f3fa8
JM
123292011-06-14 Joseph Myers <joseph@codesourcery.com>
12330
12331 * c-common.c: Include common/common-target.h.
12332 (handle_section_attribute): Use
12333 targetm_common.have_named_sections.
12334 * c-cppbuiltin.c: Include common/common-target.h.
12335 (c_cpp_builtins): Use targetm_common.except_unwind_info.
12336
d7fc8c14
RG
123372011-06-10 Richard Guenther <rguenther@suse.de>
12338
12339 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
12340 to print a IDENTIFIER_NODE.
12341
10e48e39
RO
123422011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12343 Joseph Myers <joseph@codesourcery.com>
12344
12345 * c.opt (fbuilding-libgcc): New option.
12346 * c-cppbuiltin.c (c_cpp_builtins): Define
12347 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
12348
6976ae51
JM
123492011-06-07 Jason Merrill <jason@redhat.com>
12350
3ff60975
JM
12351 * c-common.c (max_tinst_depth): Lower default to 900.
12352
6976ae51
JM
12353 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
12354
009db074
RG
123552011-06-07 Richard Guenther <rguenther@suse.de>
12356
12357 * c-common.c (c_common_nodes_and_builtins): Do not set
12358 size_type_node or call set_sizetype.
12359
b4592b92
DS
123602011-06-07 Dodji Seketeli <dodji@redhat.com>
12361
12362 PR debug/49130
12363 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
9faeb493 12364 type when using pointer comparison to compare types.
b4592b92 12365
014ab419
JW
123662011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
12367
12368 * c.opt: Add -Wdelete-non-virtual-dtor.
12369 * c-opts.c (c_common_handle_option): Include it in -Wall.
12370
4f60111f
NF
123712011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
12372
12373 PR bootstrap/49190
12374
12375 Revert:
12376 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
12377
12378 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
12379 not tree_common.
12380
4cc4f2f4
JJ
123812011-05-27 Jakub Jelinek <jakub@redhat.com>
12382
12383 PR c++/49165
12384 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
12385 C++ don't call c_common_truthvalue_conversion on void type arms.
12386
38e01f9e
NF
123872011-05-27 Nathan Froyd <froydnj@codesourcery.com>
12388
12389 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
12390 (stmt_list_stack): Define.
12391 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
12392 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
12393
92e948a8
NF
123942011-05-26 Nathan Froyd <froydnj@codesourcery.com>
12395
12396 * c-common.c (warning_candidate_p): Check for BLOCKs.
12397
a2fc3e63
NF
123982011-05-26 Nathan Froyd <froydnj@codesourcery.com>
12399
12400 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
12401 not tree_common.
12402
0957c029
JJ
124032011-05-25 Jakub Jelinek <jakub@redhat.com>
12404
12405 * c-common.c (def_fn_type): Remove extra va_end.
12406
828fb3ba
JM
124072011-05-23 Jason Merrill <jason@redhat.com>
12408
12409 PR c++/48106
12410 * c-common.c (c_common_get_narrower): New.
12411 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
12412
dde05067
NF
124132011-05-23 Nathan Froyd <froydnj@codesourcery.com>
12414
12415 * c-common.h (check_function_arguments): Tweak prototype of
12416 check_function_arguments.
12417 * c-common.c (check_function_arguments): Likewise. Adjust
12418 calls to check_function_nonnull, check_function_format, and
12419 check_function_sentinel.
12420 (check_function_sentinel): Take a FUNCTION_TYPE rather than
12421 separate attributes and typelist arguments. Use
12422 FOREACH_FUNCTION_ARGS to iterate over argument types.
12423
3c0d13bf
PC
124242011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
12425
12426 * c-common.c (c_common_reswords): Reorder.
12427 * c-common.h (rid): Likewise.
12428
8242dd04
NF
124292011-05-10 Nathan Froyd <froydnj@codesourcery.com>
12430
12431 * c-common.c (def_fn_type): Don't call build_function_type, call
12432 build_function_type_array or build_varargs_function_type_array
12433 instead.
12434 (c_common_nodes_and_builtins): Likewise.
12435
3d528853
NF
124362011-05-05 Nathan Froyd <froydnj@codesourcery.com>
12437
12438 * c-common.c (c_add_case_label): Omit the loc argument to
12439 build_case_label.
12440 * c-common.h (build_case_label): Remove.
12441 * c-semantics.c (build_case_label): Remove.
12442
a04a722b
JM
124432011-05-05 Joseph Myers <joseph@codesourcery.com>
12444
12445 * c-objc.h (objc_start_method_definition): Update prototype.
12446 * stub-objc.c (objc_start_method_definition): Add extra parameter.
12447
e19a18d4
NF
124482011-05-04 Nathan Froyd <froydnj@codesourcery.com>
12449
12450 * c-common.c (check_main_parameter_types): Reindent. Don't use
12451 TYPE_ARG_TYPES directly.
12452 (handle_nonnull_attribute): Likewise.
12453 (sync_resolve_params): Likewise.
12454 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
12455 to check_format_string.
12456 (handle_format_attribute): Likewise.
12457 (check_format_string): Take a function type to examine instead of
12458 a type list. Use a function_arg_iterator to step through argument
12459 types.
12460
c62c040f
RG
124612011-05-04 Richard Guenther <rguenther@suse.de>
12462
12463 * c-common.c (fix_string_type): Use size_int for index type bounds.
12464 (start_fname_decls): Do not pass NULL to build_int_cst.
12465 (c_init_attributes): Likewise.
12466 * c-lex.c (c_lex_with_flags): Likewise.
12467
c12ff9d8
JM
124682011-04-27 Jason Merrill <jason@redhat.com>
12469
12470 * c-common.c (make_tree_vector_from_list): New.
12471 * c-common.h: Declare it.
12472
304dfbe3
RG
124732011-04-26 Richard Guenther <rguenther@suse.de>
12474
12475 PR preprocessor/48248
12476 * c-ppoutput.c (maybe_print_line): Always optimize newlines
12477 for output size with -P.
12478
3c0d13bf
PC
124792011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
12480
12481 * c-common.c (struct c_common_resword): Add __underlying_type.
12482 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
12483
04695783
JM
124842011-04-20 Jim Meyering <meyering@redhat.com>
12485
12486 * c-format.c (init_dollar_format_checking): Remove useless
12487 if-before-free.
12488
0dc33c3c
NP
124892011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
12490
12491 * c-objc.h (objc_get_interface_ivars): Removed.
3c0d13bf 12492 (objc_detect_field_duplicates): New.
0dc33c3c 12493 * stub-objc.c: Likewise.
3c0d13bf 12494
c59633d9
NP
124952011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
12496
12497 * stub-objc.c (objc_declare_protocols): Renamed to
12498 objc_declare_protocol.
12499 * c-objc.h: Likewise.
3c0d13bf 12500
32dabdaf
NP
125012011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
12502
12503 * stub-objc.c (objc_declare_class): Updated argument name.
12504
81f653d6
NF
125052011-04-12 Nathan Froyd <froydnj@codesourcery.com>
12506
12507 * c-common.h (c_common_init_ts): Declare.
12508 * c-common.c (c_common_init_ts): Define.
12509
eb345401
NP
125102011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
12511
12512 * c-objc.h (objc_build_message_expr): Updated prototype.
12513 * stub-objc.c (objc_build_message_expr): Likewise.
9faeb493 12514
a358e188
MJ
125152011-04-12 Martin Jambor <mjambor@suse.cz>
12516
12517 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
12518 of cgraph_node.
12519
e6313a78
RG
125202011-04-11 Richard Guenther <rguenther@suse.de>
12521
12522 * c-common.c (complete_array_type): Build a range type of
12523 proper type.
12524
dcf0c47e
NF
125252011-04-08 Nathan Froyd <froydnj@codesourcery.com>
12526
12527 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
12528 (handle_type_generic_attribute): Likewise.
12529
1ee44b26
JM
125302011-04-07 Jason Merrill <jason@redhat.com>
12531
12532 PR c++/48450
12533 * c-common.c (c_common_truthvalue_conversion): Don't ignore
12534 conversion from C++0x scoped enum.
12535
acce4e77
JM
125362011-04-06 Joseph Myers <joseph@codesourcery.com>
12537
12538 * c-target-def.h: New file.
12539 * c-target.def: New file.
12540 * c-target.h: New file.
12541 * c-common.c (targetcm): Don't define here.
12542 * c-common.h (default_handle_c_option): Declare.
12543 * c-format.c: Include c-target.h instead of target.h.
12544 * c-opts.c: Include c-target.h instead of target.h. Explicitly
12545 include tm.h.
12546 (default_handle_c_option): Move from targhooks.c.
12547
e2eefb55
JJ
125482011-03-29 Jakub Jelinek <jakub@redhat.com>
12549
12550 PR preprocessor/48248
12551 * c-ppoutput.c (print): Add src_file field.
12552 (init_pp_output): Initialize it.
12553 (maybe_print_line): Don't optimize by adding up to 8 newlines
12554 if map->to_file and print.src_file are different file.
12555 (print_line): Update print.src_file.
12556
ba78087b
KT
125572011-03-25 Kai Tietz <ktietz@redhat.com>
12558
12559 * c-ada-spec.c (compare_comment): Use filename_cmp
12560 instead of strcmp for filename.
12561
0edf1bb2
JL
125622011-03-25 Jeff Law <law@redhat.com>
12563
adfac8df 12564 * c-common.c (def_fn_type): Add missing va_end.
0edf1bb2 12565
c7dc8804
JM
125662011-03-25 Jason Merrill <jason@redhat.com>
12567
12568 * c.opt: Add -std=c++03.
12569
d1d879b1
EB
125702011-03-22 Eric Botcazou <ebotcazou@adacore.com>
12571
12572 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
12573
3f8257db 125742011-03-17 Kai Tietz <ktietz@redhat.com>
62d784f7
KT
12575
12576 PR target/12171
5050afdf
KT
12577 * c-pretty-print.c (pp_c_specifier_qualifier_list):
12578 Display allowed attributes for function pointer types.
12579 (pp_c_attributes_display): New function to display
12580 attributes having affects_type_identity flag set to true.
12581 * c-pretty-print.h (pp_c_attributes_display): New prototype.
12582
62d784f7
KT
12583 * c-common.c (c_common_attribute_table):
12584 Add new element.
12585 (c_common_format_attribute_table): Likewise.
12586
82d37118
JM
125872011-03-18 Jason Merrill <jason@redhat.com>
12588
49a000c3
JM
12589 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
12590 * c-common.h: Don't declare it here.
12591 * c-common.c: Or define it here.
12592 * c-opts.c (c_common_handle_option): Or set it here.
12593
82d37118
JM
12594 PR c++/35315
12595 * c-common.c (handle_transparent_union_attribute): Don't
12596 make a duplicate type in C++.
12597
17bc631c
JM
125982011-03-15 Jason Merrill <jason@redhat.com>
12599
12600 * c-common.c (max_constexpr_depth): New.
12601 * c-common.h: Declare it.
12602 * c-opts.c (c_common_handle_option): Set it.
12603 * c.opt (fconstexpr-depth): New option.
12604
1b9b91a6
JM
126052011-03-11 Jason Merrill <jason@redhat.com>
12606
f231b5ff
JM
12607 * c-common.c (attribute_takes_identifier_p): Add missing const.
12608
1b9b91a6
JM
12609 PR c++/46803
12610 * c-common.c (attribute_takes_identifier_p): Assume that an
12611 unknown attribute takes an identifier.
12612
a19e4d44
NF
126132011-03-07 Nathan Froyd <froydnj@codesourcery.com>
12614
12615 PR c/47786
12616 * c-common.c (c_type_hash): Call list_length instead of iterating
12617 through DECL_CHAIN. Rename 'i' to 'n_elements'.
12618
982d62f6
JJ
126192011-02-19 Jakub Jelinek <jakub@redhat.com>
12620
12621 PR c/47809
12622 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
12623
0a256240
NP
126242011-02-17 Iain Sandoe <iains@gcc.gnu.org>
12625
12626 * c.opt (fobjc-abi-version=) New.
12627 (fobjc-nilcheck): New.
12628
ba9e6dd5
NF
126292011-02-03 Nathan Froyd <froydnj@codesourcery.com>
12630
12631 PR c++/46890
12632 * c-common.h (keyword_is_decl_specifier): Declare.
12633 * c-common.c (keyword_is_decl_specifier): Define.
12634 (keyword_is_function_specifier): New function.
12635
7273813a
JJ
126362011-01-26 Jakub Jelinek <jakub@redhat.com>
12637
12638 PR c/47473
12639 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
12640 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
12641 REAL_TYPE.
12642
908ef79b
AC
126432011-01-26 Arnaud Charlet <charlet@adacore.com>
12644
12645 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
12646
237e9384
JJ
126472011-01-26 Jakub Jelinek <jakub@redhat.com>
12648
12649 PR pch/47430
12650 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
12651 after init_c_lex if pch_file is set.
12652
47ea1edf
DK
126532011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
12654
d4dba752 12655 PR c++/43601
47ea1edf
DK
12656 * c.opt (-fkeep-inline-dllexport): New switch.
12657
2aa9c6ae
RG
126582011-01-12 Richard Guenther <rguenther@suse.de>
12659
12660 PR middle-end/32511
12661 * c-common.c (handle_weak_attribute): Warn instead of error
12662 on declaring an inline function weak.
12663
7bd11157
TT
126642011-01-05 Tom Tromey <tromey@redhat.com>
12665
12666 * c-common.h (lvalue_error): Update.
12667 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
12668 not error.
12669
0e66e494 126702010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
9faeb493 12671
b4f588c4
NP
12672 PR objc/47075
12673 * c-objc.h (objc_finish_message_expr): Added argument to
12674 prototype.
12675
f4da8dce
NF
126762010-12-22 Nathan Froyd <froydnj@codesourcery.com>
12677
12678 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
12679 Use prototype_p.
12680
46270f14
NP
126812010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
12682
12683 * c-objc.h (objc_maybe_warn_exceptions): New.
9faeb493 12684 * stub-objc.c (objc_maybe_warn_exceptions): New.
46270f14 12685
4816c593
NF
126862010-12-10 Nathan Froyd <froydnj@codesourcery.com>
12687
12688 * c-common.h (readonly_error): Declare.
12689 * c-common.c (readonly_error): Define.
12690
7a6daeb0
NF
126912010-12-09 Nathan Froyd <froydnj@codesourcery.com>
12692
12693 * c-common.h (invalid_indirection_error): Declare.
12694 * c-common.c (invalid_indirection_error): Define.
12695
892f6119
RG
126962010-12-03 Richard Guenther <rguenther@suse.de>
12697
12698 PR c/46745
12699 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
12700 (pp_c_unary_expression): Likewise.
12701 (pp_c_expression): Likewise.
12702
6c39e757
NP
127032010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
12704
12705 * c-common.h (objc_finish_function): New.
12706 (objc_non_volatilized_type): Removed.
12707 (objc_type_quals_match): Removed.
12708 * stub-objc.c (objc_finish_function): New.
12709 (objc_non_volatilized_type): Removed.
12710 (objc_type_quals_match): Removed.
9faeb493 12711
7c475d11
JM
127122010-11-30 Joseph Myers <joseph@codesourcery.com>
12713
12714 * c-common.h (parse_optimize_options): Declare.
12715 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
12716 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
12717
71f3e391
JM
127182010-11-29 Joseph Myers <joseph@codesourcery.com>
12719
12720 * c-opts.c (check_deps_environment_vars): Use getenv instead of
12721 GET_ENVIRONMENT.
12722 * c-pch.c (O_BINARY): Don't define here.
12723 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
12724
d5fabb58
JM
127252010-11-25 Joseph Myers <joseph@codesourcery.com>
12726
12727 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
12728 targetm.except_unwind_info.
12729
299404a1
JM
127302010-11-23 Joseph Myers <joseph@codesourcery.com>
12731
12732 * c-opts.c (c_common_handle_option): Pass location to
12733 set_struct_debug_option.
12734
c98cd5bf
JM
127352010-11-23 Joseph Myers <joseph@codesourcery.com>
12736
12737 * c-common.c (visibility_options): Move from ../opts.c.
12738 * c-common.h (struct visibility_flags, visibility_options):
12739 Declare here.
12740 * c-opts.c (finish_options): Rename to c_finish_options.
12741 (c_common_init): Update call to finish_options.
12742
a9546771
NP
127432010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
12744
12745 PR objc/34033
12746 * c-lex.c (lex_string): Check that each string in an Objective-C
12747 string concat sequence starts with either one or zero '@', and
12748 that there are no spurious '@' signs at the end.
12749
24a57808
JM
127502010-11-20 Joseph Myers <joseph@codesourcery.com>
12751
12752 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
12753 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
12754 HANDLE_PRAGMA_VISIBILITY.
12755 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
12756 HANDLE_PRAGMA_VISIBILITY): Don't define.
12757 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
12758
a9aa2c3a
NF
127592010-11-20 Nathan Froyd <froydnj@codesourcery.com>
12760
12761 PR c++/16189
12762 PR c++/36888
12763 PR c++/45331
12764 * c-common.h (keyword_begins_type_specifier): Declare.
12765 (keyword_is_storage_class_specifier): Declare.
12766 (keyword_is_type_qualifier): Declare.
12767 * c-common.c (keyword_begins_type_specifier): New function.
12768 (keyword_is_storage_class_specifier): New function.
12769 (keyword_is_type_qualifier): Declare.
12770
5386338c
JM
127712010-11-19 Joseph Myers <joseph@codesourcery.com>
12772
12773 PR c/46547
12774 * c-common.c (in_late_binary_op): Define.
12775 (c_common_truthvalue_conversion): Check in_late_binary_op before
12776 calling c_save_expr.
12777 * c-common.h (in_late_binary_op): Declare.
12778
69ccdddb
JM
127792010-11-19 Joseph Myers <joseph@codesourcery.com>
12780
12781 * c-opts.c (c_common_handle_option): Update calls to
12782 set_struct_debug_option.
12783
6b192a09
NP
127842010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
12785
12786 * c-common.h (objc_declare_protocols): Added additional argument.
12787 * stub-objc.c (objc_declare_protocol): Same change.
9faeb493 12788
fb52b50a
NF
127892010-11-18 Nathan Froyd <froydnj@codesourcery.com>
12790
12791 PR c/33193
12792 * c-common.h (build_real_imag_expr): Declare.
12793 * c-semantics.c (build_real_imag_expr): Define.
12794
b37421c6
JM
127952010-11-17 Joseph Myers <joseph@codesourcery.com>
12796
12797 * c-opts.c (c_common_parse_file): Take no arguments.
12798 * c-common.h (c_common_parse_file): Update prototype.
12799
07078664
JJ
128002010-11-16 Jakub Jelinek <jakub@redhat.com>
12801
12802 PR c++/46401
12803 * c-common.c (warning_candidate_p): Don't track non-const calls
12804 or STRING_CSTs.
12805
c6a13190
ILT
128062010-11-15 Ian Lance Taylor <iant@google.com>
12807
12808 * c-lex.c (init_c_lex): Set macro debug callbacks if
12809 flag_dump_go_spec is set.
12810
925e8657
NP
128112010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
12812
12813 * c-common.h (objc_build_incr_expr_for_property_ref): New.
12814 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
12815
bb0a9581
NF
128162010-11-15 Nathan Froyd <froydnj@codesourcery.com>
12817
12818 PR preprocessor/45038
12819 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
12820 dialects.
12821
c5fa0890
JM
128222010-11-12 Joseph Myers <joseph@codesourcery.com>
12823
12824 * c-common.h (c_family_lang_mask): Declare.
12825 * c-opts.c (c_family_lang_mask): Make extern.
12826 * c-pragma.c (handle_pragma_diagnostic): Use
12827 control_warning_option.
12828
a4d8c676
JM
128292010-11-12 Joseph Myers <joseph@codesourcery.com>
12830
12831 * c-common.c (parse_optimize_options): Update call to
12832 decode_options.
12833 * c-common.h (c_common_handle_option): Update prototype.
12834 * c-opts.c (c_common_handle_option): Take location_t parameter and
12835 pass it to other functions.
12836
f954bd2c
JM
128372010-11-11 Joseph Myers <joseph@codesourcery.com>
12838
12839 * c-opts.c (warning_as_error_callback): Remove.
12840 (c_common_initialize_diagnostics): Don't call
12841 register_warning_as_error_callback.
12842 (c_common_handle_option): Handle -Werror=normalized= here.
12843
d8a07487
JM
128442010-11-10 Joseph Myers <joseph@codesourcery.com>
12845
12846 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
12847 in diagnostic.
12848 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
12849 letter.
12850 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
12851 Remove trailing '.' from diagnostics.
12852 * c.opt (Wwrite-strings_: Avoid '`' in help text.
12853
d5478783
JM
128542010-11-10 Joseph Myers <joseph@codesourcery.com>
12855
12856 * c-common.c (parse_optimize_options): Pass global_dc to
12857 decode_options.
12858 * c-opts.c (c_common_handle_option): Pass &global_options to
12859 set_Wstrict_aliasing.
12860 * c.opt (v): Don't mark Common or document here.
12861
91ebb981
IS
128622010-11-06 Iain Sandoe <iains@gcc.gnu.org>
12863
12864 PR target/44981
12865 * c-format.c (format_type): New type gcc_objc_string_format_type.
12866 (valid_stringptr_type_p): New.
12867 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
9faeb493 12868 (check_format_string): Pass expected type, use
91ebb981
IS
12869 valid_stringptr_type_p (), check that the format string types are
12870 consistent with the format specification.
12871 (decode_format_attr): Warn if NSString is used outside objective-c.
12872 (format_types_orig): Add NSString.
12873 (format_name): New.
12874 (format_flags): New.
12875 (check_format_arg): Handle format strings requiring an external parser.
12876 first_target_format_type: New variable.
12877 (handle_format_attribute): Set up first_target_format_type, pass the
12878 expected format arg string type to check_format_string().
ab20d992 12879 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
91ebb981
IS
12880 * stub-objc.c (objc_string_ref_type_p): New.
12881 (objc_check_format_arg): New.
12882
bede2adc
NP
128832010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
12884
9faeb493 12885 Fixed using the Objective-C 2.0 dot-syntax with class names.
bede2adc
NP
12886 * c-common.h (objc_build_class_component_ref): New.
12887 * stub-objc.c (objc_build_class_component_ref): New.
12888
9a179d01
NP
128892010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
12890
12891 * c.opt (Wproperty-assign-default): New option.
12892
22d8d616
NP
128932010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
12894
12895 Implemented -fobjc-std=objc1 flag.
12896 * c.opt (fobjc-std=objc1): New option.
12897
2debdb4f
NP
128982010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
12899
12900 Implemented format and noreturn attributes for Objective-C methods.
12901 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
12902 attribute for Objective-C methods.
12903
ec52b111
JM
129042010-10-31 Jason Merrill <jason@redhat.com>
12905
12906 * c-common.c (conversion_warning, warn_for_collisions_1): Use
12907 EXPR_LOC_OR_HERE.
12908
46a88c12
NP
129092010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
12910
12911 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
12912 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
12913 (objc_add_property_declaration): Removed arguments for copies and
12914 ivar.
12915 (objc_build_getter_call): Renamed to
12916 objc_maybe_build_component_ref.
12917 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
12918 (objc_is_property_ref): New.
12919 * c-common.c (c_common_reswords): Removed copies and ivar.
12920 * stub-objc.c (objc_add_property_declaration): Removed arguments
12921 for copies and ivar.
12922 (objc_build_getter_call): Renamed to
12923 objc_maybe_build_component_ref.
12924 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
12925 (objc_is_property_ref): New.
9faeb493 12926
1e4bf85b
AC
129272010-10-29 Arnaud Charlet <charlet@adacore.com>
12928 Matthew Gingell <gingell@adacore.com>
12929
12930 * c-ada-spec.c (separate_class_package): New function.
12931 (pp_ada_tree_identifier): Prefix references to C++ classes with the
12932 name of their enclosing package.
12933 (print_ada_declaration): Use separate_class_package.
12934
81f0bab2
JM
129352010-10-27 Jason Merrill <jason@redhat.com>
12936
2b08f2c5
JM
12937 * c-common.c (c_common_reswords): Add __is_literal_type.
12938 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
12939
81f0bab2
JM
12940 * c-common.c (check_case_value): Remove special C++ code.
12941
200290f2
NP
129422010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
12943
12944 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
12945 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
12946 and RID_LAST_PATTR.
12947 (objc_add_property_declaration): Added additional arguments.
12948 (objc_property_attribute_kind): Removed.
12949 (objc_set_property_attr): Removed.
12950 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
12951 copy and nonatomic.
12952 * stub-objc.c (objc_add_property_declaration): Added additional
12953 arguments.
12954 (objc_set_property_attr): Removed.
9faeb493 12955
f614132b
NP
129562010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
12957
12958 * c-common.h (objc_add_property_variable): Renamed to
12959 objc_add_property_declaration. Added location argument.
12960 * stub-objc.c (objc_add_property_variable): Same change.
b1726d6c 12961
b8a18805
NP
129622010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
12963
12964 * c-common.h (objc_maybe_printable_name): New.
12965 * stub-objc.c (objc_maybe_printable_name): New.
12966
3f8257db
JJ
129672010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
12968 Andrew Pinski <pinskia@gmail.com>
30cd1c5d
AS
12969
12970 * c-common.h (c_common_mark_addressable_vec): Declare.
12971 * c-common.c (c_common_mark_addressable_vec): New function.
12972
249a82c4
NP
129732010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
12974
12975 * c-common.h (objc_set_method_type): Removed.
12976 (objc_add_method_declaration): Added boolean argument.
12977 (objc_start_method_definition): Same change.
12978 (objc_build_method_signature): Same change.
12979 * stub-objc.c (objc_set_method_type): Removed.
12980 (objc_add_method_declaration): Added boolean argument.
12981 (objc_start_method_definition): Same change.
12982 (objc_build_method_signature): Same change.
12983
977e30bc
NP
129842010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
12985
12986 * c-common.h (finish_file): Removed.
12987 (objc_write_global_declarations): New.
12988 * c-opts.c (c_common_parse_file): Do not call finish_file.
12989 * stub-objc.c (objc_write_global_declarations): New.
9faeb493 12990
da57d1b9
NP
129912010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
12992
12993 Implemented parsing @synthesize and @dynamic for
12994 Objective-C/Objective-C++.
12995 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
12996 (objc_add_synthesize_declaration): New.
12997 (objc_add_dynamic_declaration): New.
12998 * c-common.c (c_common_reswords): Add synthesize and dynamic.
12999 * stub-objc.c (objc_add_synthesize_declaration): New.
13000 (objc_add_dynamic_declaration): New.
9faeb493 13001
0069111f
MM
130022010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
13003
13004 PR target/46041
13005 * c-cppbuiltin.c (mode_has_fma): Move function here from
13006 builtins.c. Don't use the fma optab, instead just use the
13007 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
13008 using -save-temps.
13009
e426b47b
NP
130102010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
13011
13012 Merge from 'apple/trunk' branch on FSF servers.
0069111f 13013
3f8257db 13014 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
e426b47b 13015
9faeb493 13016 Radar 4330422
e426b47b
NP
13017 * c-common.h (objc_non_volatilized_type): New declaration
13018 * stub-objc.c (objc_non_volatilized_type): New stub.
13019
90fbfdc3
NP
130202010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
13021
e426b47b 13022 Merge from 'apple/trunk' branch on FSF servers.
90fbfdc3 13023
ab20d992 13024 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
90fbfdc3 13025
9faeb493 13026 Radar 4133425
90fbfdc3 13027 * c-common.h (objc_diagnose_private_ivar): New decl.
0069111f 13028 * stub-objc.c (objc_diagnose_private_ivar): New stub.
90fbfdc3 13029
c37d8c30
IS
130302010-10-17 Iain Sandoe <iains@gcc.gnu.org>
13031
13032 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
13033 * c-common.h (enum rid): Add RID_AT_PACKAGE.
13034 (objc_ivar_visibility_kind): New enum.
13035 (objc_set_visibility): Adjust prototype to use visibility enum.
0069111f 13036 * stub-objc.c (objc_set_visibility): Adjust stub to use
c37d8c30
IS
13037 visibility enum.
13038
1b1562a5
MM
130392010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
13040
13041 * c-cppbuiltin.c (builtin_define_float_constants): Emit
13042 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
13043 has the appropriate fma builtins.
13044 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
13045
668ea4b1
IS
130462010-10-14 Iain Sandoe <iains@gcc.gnu.org>
13047
1b1562a5 13048 merge from FSF apple 'trunk' branch.
3f8257db 13049 2006 Fariborz Jahanian <fjahanian@apple.com>
1b1562a5 13050
668ea4b1
IS
13051 Radars 4436866, 4505126, 4506903, 4517826
13052 * c-common.c (c_common_resword): Define @property and its attributes.
13053 * c-common.h: Define property attribute enum entries.
13054 (OBJC_IS_PATTR_KEYWORD): New.
13055 (objc_property_attribute_kind): New enum.
13056 Declare objc_set_property_attr (), objc_add_property_variable (),
13057 objc_build_getter_call () and objc_build_setter_call ().
13058 * stub-objc.c (objc_set_property_attr): New stub.
13059 (objc_add_property_variable): Likewise.
13060 (objc_build_getter_call): Likewise.
13061 (objc_build_setter_call) Likewise.
1b1562a5 13062
a1178b30
IS
130632010-10-13 Iain Sandoe <iains@gcc.gnu.org>
13064
1b1562a5 13065 merge from FSF apple 'trunk' branch.
ab20d992 13066 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
a1178b30
IS
13067
13068 Radar 3803157 (method attributes)
13069 * c-common.c (handle_deprecated_attribute): Recognize
13070 objc methods as valid declarations.
13071 * c-common.h: Declare objc_method_decl ().
1b1562a5 13072 * stub-objc.c (objc_method_decl): New stub.
a1178b30 13073
a75bfaa6
JM
130742010-10-08 Joseph Myers <joseph@codesourcery.com>
13075
13076 * c-common.c (parse_optimize_options): Call
13077 decode_cmdline_options_to_array_default_mask before
13078 decode_options. Update arguments to decode_options.
13079 * c-common.h (c_common_init_options_struct): Declare.
13080 * c-opts.c (c_common_init_options_struct): New. Split out from
13081 c_common_init_options.
13082
f05b9d93
NP
130832010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
13084
13085 Implemented fast enumeration for Objective-C.
13086 * c-common.h (objc_finish_foreach_loop): New.
13087 * stub-objc.c (objc_finish_foreach_loop): New.
13088
1ebe4b4f
JM
130892010-10-05 Joseph Myers <joseph@codesourcery.com>
13090
13091 * c-common.h (struct diagnostic_context): Don't declare here.
13092 (c_common_initialize_diagnostics): Declare using
13093 diagnostic_context typedef.
13094 * c-opts.c (c_common_handle_option): Pass global_dc to
13095 handle_generated_option.
13096
d4d24ba4
JM
130972010-10-04 Joseph Myers <joseph@codesourcery.com>
13098
13099 * c-opts.c (c_common_handle_option): Pass &global_options_set to
13100 handle_generated_option.
13101
478a1c5b
ILT
131022010-10-03 Ian Lance Taylor <iant@google.com>
13103
13104 * c.opt (-fplan9-extensions): New option.
13105
82a1c2fe
FXC
131062010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
13107
13108 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
13109 Remove.
13110 (c_cpp_builtins): Call functions from cppbuiltin.c instead
13111 of duplicating code.
13112
92902b1b
IS
131132010-09-30 Iain Sandoe <iains@gcc.gnu.org>
13114
13115 * c-common.c: Add two new entries for @optional
13116 and @required keywords.
13117
13118 merge from FSF 'apple/trunk' branch.
3f8257db 13119 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
92902b1b
IS
13120
13121 Radar 4386773
13122 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
13123 objective-c keywords.
13124 (objc_set_method_opt): New declaration.
13125 * stub-objc.c (objc_set_method_opt): New stub.
9faeb493 13126
46625112
JM
131272010-09-30 Joseph Myers <joseph@codesourcery.com>
13128
13129 * c-common.c (handle_optimize_attribute): Pass &global_options to
13130 cl_optimization_save and cl_optimization_restore.
13131 * c-opts.c (c_common_handle_option): Pass &global_options to
13132 handle_generated_option.
13133 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
13134 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
13135 &global_options to cl_optimization_restore.
13136
49b91f05
NP
131372010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
13138
13139 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
13140 Objective-C/Objective-C++ keywords.
13141
13ed556f 131422010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
a6341d57 13143
9faeb493
UB
13144 Merge from 'apple/trunk' branch on FSF servers.
13145
3f8257db 13146 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
a6341d57
NP
13147
13148 Radar 4281748
13149 * c-common.h (objc_check_global_decl): New declaration.
13150 * stub-objc.c (objc_check_global_decl): New stub.
13151
f0036cca
JM
131522010-09-29 Joseph Myers <joseph@codesourcery.com>
13153
13154 * c.opt: Don't use VarExists.
13155
e3339d0f
JM
131562010-09-29 Joseph Myers <joseph@codesourcery.com>
13157
13158 * c-common.c (c_cpp_error): Update names of diagnostic_context
13159 members.
13160 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
13161 cl_optimization members.
13162 * c-opts.c (warning_as_error_callback, c_common_handle_option,
13163 sanitize_cpp_opts, finish_options): Update names of cpp_options
13164 members.
13165
1973201f
NP
131662010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
13167
13168 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
13169 (objc_is_reserved_word): Removed.
13170 * c-common.c: Updated comments.
13171 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
13172 objc_is_reserved_word.
13173 * stub-objc.c (objc_is_reserved_word): Removed.
13174
f7e71da5
IS
131752010-09-28 Iain Sandoe <iains@gcc.gnu.org>
13176
9faeb493 13177 * c-common.h (objc_add_method_declaration): Adjust prototype to
f7e71da5
IS
13178 include attributes.
13179 (objc_start_method_definition): Likewise.
13180 (objc_build_keyword_decl): Likewise.
13181 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
13182 (objc_start_method_definition): Likewise.
13183 (objc_build_keyword_decl): Likewise.
13184
c165dca7
IS
131852010-09-28 Iain Sandoe <iains@gcc.gnu.org>
13186
13187 * c-common.h (objc_start_class_interface): Adjust prototype.
13188 (objc_start_category_interface): Likewise.
13189 (objc_start_protocol): Likewise.
13190 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
13191 (objc_start_class_interface): Likewise.
13192 (objc_start_category_interface): Likewise.
13193
7458026b
ILT
131942010-09-27 Ian Lance Taylor <iant@google.com>
13195
13196 * c-common.c (c_common_attribute_table): Add no_split_stack.
13197 (handle_no_split_stack_attribute): New static function.
13198
b581b85b
NP
131992010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
13200
9faeb493 13201 Merge from 'apple/trunk' branch on FSF servers.
b581b85b 13202
3f8257db 13203 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
b581b85b 13204
9faeb493 13205 Radar 4229905
b581b85b
NP
13206 * c-common.h (objc_have_common_type): New declaration.
13207 * stub-objc.c (objc_have_common_type): New stub.
13208
13209 2005-06-22 Ziemowit Laski <zlaski@apple.com>
13210
13211 Radar 4154928
13212 * c-common.h (objc_common_type): New prototype.
9faeb493 13213 * stub-objc.c (objc_common_type): New stub.
b581b85b 13214
46a4da10
JH
132152010-09-24 Jan Hubicka <jh@suse.cz>
13216
13217 * c-common.c (handle_leaf_attribute): New function.
13218 (struct attribute_spec c_common_att): Add leaf.
13219
e200444e
JM
132202010-09-22 Joseph Myers <joseph@codesourcery.com>
13221
13222 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
13223 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
13224 -dump, -dump=, -imacros, -imacros=, -include, -include=,
13225 -include-barrier, -include-directory, -include-directory=,
13226 -include-directory-after, -include-directory-after=,
13227 -include-prefix, -include-prefix=, -include-with-prefix,
13228 -include-with-prefix=, -include-with-prefix-after,
13229 -include-with-prefix-after=, -include-with-prefix-before,
13230 -include-with-prefix-before=, -no-integrated-cpp,
13231 -no-line-commands, -no-standard-includes, -no-warnings, -output,
13232 -output=, -pedantic, -pedantic-errors, -preprocess,
13233 -print-missing-file-dependencies, -trace-includes, -traditional,
13234 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
13235 -user-dependencies, -verbose, -write-dependencies,
13236 -write-user-dependencies, no-integrated-cpp, traditional): New.
13237
29a80ea6
NP
132382010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
13239
13240 PR objc/23710
ac1fc2fc
NP
13241 * c-common.h (objc_start_method_definition): Return bool instead
13242 of void.
13243 * stub-objc.c (objc_start_method_definition): Return bool instead
13244 of void.
13245
132462010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
13247
13248 PR objc/25965
13249 * c-common.h (objc_get_interface_ivars): New declaration.
13250 * stub-objc.c (objc_get_interface_ivars): New stub.
29a80ea6 13251
de621752
ILT
132522010-09-15 Ian Lance Taylor <iant@google.com>
13253
13254 * c-common.c (parse_optimize_options): Do not capitalize warning
06730c5d 13255 messages. Remove period at end of warning message.
de621752 13256
ba885ec5
NS
132572010-09-09 Nathan Sidwell <nathan@codesourcery.com>
13258
13259 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
13260 (handle_alias_attribute): ... here.
13261 (handle_ifunc_attribute): New.
13262
c5ee1358
MM
132632010-09-06 Mark Mitchell <mark@codesourcery.com>
13264
13265 * c-common.h (do_warn_double_promotion): Declare.
13266 * c-common.c (do_warn_double_promotion): Define.
13267
0a0b3574
MM
132682010-09-05 Mark Mitchell <mark@codesourcery.com>
13269
13270 * c.opt (Wdouble-promotion): New.
13271
d1779886
JM
132722010-09-02 Joseph Myers <joseph@codesourcery.com>
13273
13274 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
13275 fvtable-thunks, fxref): Mark no longer supported in help text.
13276
2d2bd949
JM
132772010-09-02 Joseph Myers <joseph@codesourcery.com>
13278
13279 * c.opt (Wimport, fall-virtual, falt-external-templates,
13280 fdefault-inline, fenum-int-equiv, fexternal-templates,
13281 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
13282 fname-mangling-version-, fnew-abi, fnonnull-objects,
13283 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
13284 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
13285 applicable.
13286 (fhandle-exceptions): Mark with Alias and Warn.
13287 * c-opts.c (c_common_handle_option): Don't handle options marked
13288 as ignored.
13289
5de8299c
JM
132902010-09-02 Joseph Myers <joseph@codesourcery.com>
13291
13292 * c.opt (Wcomments, Werror-implicit-function-declaration,
13293 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
13294 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
13295 aliases.
13296 * c-common.c (option_codes): Use OPT_Wcomment instead of
13297 OPT_Wcomments.
13298 * c-opts.c (warning_as_error_callback, c_common_handle_option):
13299 Don't handle options marked as aliases.
13300
0ceb0201
RG
133012010-08-25 Richard Guenther <rguenther@suse.de>
13302
13303 * c-common.c (c_common_get_alias_set): Remove special
13304 handling for pointers.
13305
ac47786e
NF
133062010-08-20 Nathan Froyd <froydnj@codesourcery.com>
13307
13308 * c-common.c: Use FOR_EACH_VEC_ELT.
13309 * c-gimplify.c: Likewise.
13310 * c-pragma.c: Likewise.
13311
c878765b
JM
133122010-08-16 Joseph Myers <joseph@codesourcery.com>
13313
13314 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
13315 RejectDriver.
13316 (MMDX): Change back to MMD. Mark NoDriverArg instead of
13317 RejectDriver.
13318 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
13319 instead of OPT_MDX and OPT_MMDX.
13320
603349bf
JM
133212010-08-16 Joseph Myers <joseph@codesourcery.com>
13322
13323 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
13324
644fa7ac
JM
133252010-08-12 Joseph Myers <joseph@codesourcery.com>
13326
13327 * c.opt (MD, MMD): Change to MDX and MMDX.
13328 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
13329
481e1176
JM
133302010-08-11 Joseph Myers <joseph@codesourcery.com>
13331
13332 * c-opts.c (c_common_handle_option): Call handle_generated_option
13333 instead of handle_option.
13334
ac8dc9f7
NF
133352010-08-08 Nathan Froyd <froydnj@codesourcery.com>
13336
13337 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
13338 (maybe_apply_renaming_pragma): Delete unneeded declarations.
13339
4f8c876d
NF
133402010-08-08 Nathan Froyd <froydnj@codesourcery.com>
13341
13342 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
13343 (pending_redefine_extname): Change type to a VEC.
13344 (add_to_renaming_pragma_list): Update for new type of
13345 pending_redefine_extname.
ac8dc9f7 13346 (maybe_apply_renaming_pragma): Likewise.
4f8c876d 13347
3b0c690e
AC
133482010-08-04 Arnaud Charlet <charlet@adacore.com>
13349
13350 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
13351 visited.
13352 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
13353 decide whether a type has already been declared/seen.
13354 Do not go to the original type.
13355 (dump_nested_types): New parameter forward.
13356 Generate forward declaration if needed and mark type as visited.
13357 (print_ada_declaration): Call dump_nested_types if not already done.
13358 Mark types as visited.
13359
1890bccc
JM
133602010-08-03 Joseph Myers <joseph@codesourcery.com>
13361
13362 * c.opt (-print-pch-checksum): Remove option.
13363 * c-opts.c (c_common_handle_option): Don't handle
13364 OPT_print_pch_checksum.
13365
5f20c657
JM
133662010-07-27 Joseph Myers <joseph@codesourcery.com>
13367
13368 * c-common.h (c_common_handle_option): Update prototype and return
13369 value type.
13370 * c-opts.c (c_common_handle_option): Update prototype and return
13371 value type. Update calls to handle_option and
13372 enable_warning_as_error.
13373
f551f80c
JJ
133742010-07-27 Jakub Jelinek <jakub@redhat.com>
13375
13376 PR c/45079
13377 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
13378
61ff2bdc
JM
133792010-07-27 Joseph Myers <joseph@codesourcery.com>
13380
13381 * c-common.h (c_common_missing_argument): Remove.
13382 * c-opts.c (c_common_missing_argument): Remove.
13383 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
13384 idirafter, imacros, include, isysroot, isystem, iquote): Add
13385 MissingArgError.
13386 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
13387
7a9bf9a4
JM
133882010-07-27 Joseph Myers <joseph@codesourcery.com>
13389
13390 * c-common.h (c_common_option_lang_mask,
13391 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
13392 New.
13393 (c_common_init_options): Update prototype.
13394 * c-opts.c (c_common_option_lang_mask): New.
13395 (c_common_initialize_diagnostics): Split out of
13396 c_common_init_options.
13397 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
13398 New.
13399 (c_common_init_options): Update prototype. Use decoded options in
13400 search for -lang-asm.
13401
910ad8de
NF
134022010-07-15 Nathan Froyd <froydnj@codesourcery.com>
13403
13404 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
13405 * c-format.c: Likewise.
13406
718f9c0f
MLI
134072010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
13408
13409 * c-common.h: Include diagnostic-core.h. Error if already
13410 included.
13411 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
13412
4d451982
MLI
134132010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
13414
adfac8df 13415 * c-common.c (IN_GCC_FRONTEND): Do not undef.
4d451982
MLI
13416 Do not include expr.h
13417 (vector_mode_valid_p): Move here.
13418
119fe915
SB
134192010-06-21 DJ Delorie <dj@redhat.com>
13420
13421 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
13422 allow these pragmas anywhere.
13423
134242010-06-14 Jakub Jelinek <jakub@redhat.com>
13425
13426 PR bootstrap/44509
13427 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
13428 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
13429 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
13430 ggc_strdup instead of xstrdup.
13431
134322010-06-10 Jakub Jelinek <jakub@redhat.com>
13433
13434 * c-cppbuiltin.c: Include cpp-id-data.h.
13435 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
13436 (lazy_hex_fp_value): New function.
13437 (builtin_define_with_hex_fp_value): Provide definitions lazily.
13438
6662d794
MLI
134392010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
13440
13441 * c-gimplify.c: Do not include tree-flow.h
13442
38f8b050
JR
134432010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
13444
13445 PR other/44034
13446 * c-common.c: Rename targetm member:
13447 targetm.enum_va_list -> targetm.enum_va_list_p
13448
9589f23e
AS
134492010-06-28 Anatoly Sokolov <aesok@post.ru>
13450
13451 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
13452
3b06d379
SB
134532010-06-28 Steven Bosscher <steven@gcc.gnu.org>
13454
13455 * c-cppbuiltin.c: Do not include except.h.
13456
d166d4c3
AK
134572010-06-24 Andi Kleen <ak@linux.intel.com>
13458
9faeb493
UB
13459 * c-common.c (warn_for_omitted_condop): New.
13460 * c-common.h (warn_for_omitted_condop): Add prototype.
d166d4c3 13461
70cb8be6
JM
134622010-06-21 Joseph Myers <joseph@codesourcery.com>
13463
13464 * c.opt (lang-objc): Remove.
13465 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
13466
a4c97feb
JR
134672010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
13468
13469 * c-opts.c: Include "tm_p.h".
13470
6e2f1956
JM
134712010-06-20 Joseph Myers <joseph@codesourcery.com>
13472
13473 * c-common.c (parse_optimize_options): Update call to
13474 decode_options.
13475
bc87224e
NF
134762010-06-18 Nathan Froyd <froydnj@codesourcery.com>
13477
13478 * c-common.c (record_types_used_by_current_var_decl): Adjust for
13479 new type of types_used_by_cur_var_decl.
13480
b49cf425
JR
134812010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
13482
13483 PR bootstrap/44512
13484 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
13485 for C++ standard compliance.
13486
59f9c2ed
JM
134872010-06-16 Jason Merrill <jason@redhat.com>
13488
13489 * c.opt: Add -Wnoexcept.
13490
33766b66
RG
134912010-06-16 Richard Guenther <rguenther@suse.de>
13492
13493 PR c/44555
13494 * c-common.c (c_common_truthvalue_conversion): Remove
13495 premature and wrong optimization concering ADDR_EXPRs.
13496
eff7e30c
AC
134972010-06-15 Arnaud Charlet <charlet@adacore.com>
13498
13499 * c-ada-spec.c (dump_sloc): Remove column info.
13500 (is_simple_enum): New function.
13501 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
13502 enum types when relevant.
13503
6312e84d
MLI
135042010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
13505
9faeb493 13506 * c-common.c (conversion_warning): Warn at expression
6312e84d
MLI
13507 location.
13508
1cb42611
JM
135092010-06-10 Joseph Myers <joseph@codesourcery.com>
13510
13511 * c-opts.c (c_common_handle_option): Don't handle
13512 OPT_fshow_column.
13513
a9429e29
LB
135142010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
13515
13516 * c-pragma.c (push_alignment): Use typed GC allocation.
13517 (handle_pragma_push_options): Likewise.
13518
13519 * c-common.c (parse_optimize_options): Likewise.
13520
13521 * c-common.h (struct sorted_fields_type): Add variable_size GTY
13522 option.
13523
5498f011
JM
135242010-06-07 Joseph Myers <joseph@codesourcery.com>
13525
13526 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
13527 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
13528 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
13529 flag_signed_bitfields, warn_strict_null_sentinel,
13530 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
13531 flag_gen_declaration, flag_no_gnu_keywords,
13532 flag_implement_inlines, flag_implicit_templates,
13533 flag_implicit_inline_templates, flag_optional_diags,
13534 flag_elide_constructors, flag_default_inline, flag_rtti,
13535 flag_conserve_space, flag_access_control, flag_check_new,
13536 flag_new_for_scope, flag_weak, flag_working_directory,
13537 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
13538 flag_enforce_eh_specs, flag_threadsafe_statics,
13539 flag_pretty_templates): Remove.
13540 * c-common.h (flag_preprocess_only, flag_nil_receivers,
13541 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
13542 flag_replace_objc_classes, flag_undef, flag_no_builtin,
13543 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
13544 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
13545 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
13546 flag_no_gnu_keywords, flag_implement_inlines,
13547 flag_implicit_templates, flag_implicit_inline_templates,
13548 flag_optional_diags, flag_elide_constructors, flag_default_inline,
13549 flag_rtti, flag_conserve_space, flag_access_control,
13550 flag_check_new, flag_new_for_scope, flag_weak,
13551 flag_working_directory, flag_use_cxa_atexit,
13552 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
13553 flag_threadsafe_statics, flag_pretty_templates,
13554 warn_strict_null_sentinel): Remove.
13555 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
13556 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
13557 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
13558 fimplicit-inline-templates, fimplicit-templates,
13559 flax-vector-conversions, fms-extensions, fnil-receivers,
13560 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
13561 frtti, fshort-double, fshort-enums, fshort-wchar,
13562 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
13563 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
13564 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
13565 gen-decls, undef): Use Var.
13566 (fdefault-inline, foptional-diags): Document as doing nothing.
13567 * c-opts.c (c_common_handle_option): Remove cases for options now
13568 using Var. Mark ignored options as such.
13569
39dabefd
SB
135702010-06-05 Steven Bosscher <steven@gcc.gnu.org>
13571
9faeb493 13572 * c-common.c: Moved to here from parent directory.
39dabefd
SB
13573 * c-common.def: Likewise.
13574 * c-common.h: Likewise.
13575 * c-cppbuiltin.c: Likewise.
13576 * c-dump.c: Likewise.
13577 * c-format.c: Likewise.
13578 * c-format.h : Likewise.
13579 * c-gimplify.c: Likewise.
13580 * c-lex.c: Likewise.
13581 * c-omp.c: Likewise.
13582 * c.opt: Likewise.
13583 * c-opts.c: Likewise.
13584 * c-pch.c: Likewise.
13585 * c-ppoutput.c: Likewise.
13586 * c-pragma.c: Likewise.
13587 * c-pragma.h: Likewise.
13588 * c-pretty-print.c: Likewise.
13589 * c-pretty-print.h: Likewise.
13590 * c-semantics.c: Likewise.
13591 * stub-objc.c: Likewise.
13592
13593 * c-common.c: Include gt-c-family-c-common.h.
13594 * c-pragma.c: Include gt-c-family-c-pragma.h.
13595\f
877e3c2a 13596Copyright (C) 2010-2022 Free Software Foundation, Inc.
39dabefd
SB
13597
13598Copying and distribution of this file, with or without modification,
13599are permitted in any medium without royalty provided the copyright
13600notice and this notice are preserved.
This page took 4.56393 seconds and 5 git commands to generate.