]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c-family/ChangeLog
tree-iterator: C++11 range-for and tree_stmt_iterator
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
CommitLineData
2bc6dace
GA
12021-05-25 Martin Liska <mliska@suse.cz>
2
3 PR tree-optimization/92860
4 PR target/99592
5 * c-attribs.c (handle_optimize_attribute): Save target node
6 before calling parse_optimize_options and save it in case
7 it changes.
8 * c-pragma.c (handle_pragma_target): Similarly for pragma.
9 (handle_pragma_pop_options): Likewise here.
10
112021-05-25 Martin Liska <mliska@suse.cz>
12
13 * c-attribs.c (handle_no_sanitize_coverage_attribute): New.
14
152021-05-25 Jakub Jelinek <jakub@redhat.com>
16
17 PR middle-end/99928
18 * c-omp.c (c_omp_split_clauses): Copy reduction to teams when teams is
19 combined with simd and not with taskloop or for.
20
2832d51b
GA
212021-05-21 Jakub Jelinek <jakub@redhat.com>
22
23 PR middle-end/99928
24 * c-omp.c (c_omp_split_clauses): Set OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT
25 on firstprivate clause copy going to target construct, and for
26 target simd set also OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT_TARGET bit.
27
ea34e2ed
GA
282021-05-20 Jonathan Wakely <jwakely@redhat.com>
29
30 * c.opt (Wc++11-extensions, Wc++14-extensions)
31 (Wc++17-extensions, Wc++20-extensions, Wc++23-extensions): New
32 options.
33
342021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
35
36 * c-lex.c (init_c_lex): Use dwarf_debuginfo_p.
37
382021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
39
40 * c-opts.c (c_common_post_options): Adjust access to debug_type_names.
41 * c-pch.c (struct c_pch_validity): Use type uint32_t.
42 (pch_init): Renamed member.
43 (c_common_valid_pch): Adjust access to debug_type_names.
44
65f32e5d
GA
452021-05-19 Martin Sebor <msebor@redhat.com>
46
47 PR c/100619
48 * c-attribs.c (build_attr_access_from_parms): Handle arbitrarily many
49 bounds.
50
a8daf9a1
GA
512021-05-18 Richard Biener <rguenther@suse.de>
52
53 PR c/100547
54 * c-attribs.c (type_valid_for_vector_size): Reject too large nunits.
55 Reword existing nunit diagnostic.
56
a7ffc1ef
GA
572021-05-17 Joern Rennecke <joern.rennecke@embecosm.com>
58
59 * c-common.c (braced_list_to_string): Return CTOR unchanged
60 if host and target character sizes don't match.
61
87a7d10c
GA
622021-05-14 Martin Liska <mliska@suse.cz>
63
64 * c.opt: Add Warning keyword for 2 options.
65
f9af11c7
GA
662021-05-13 Martin Liska <mliska@suse.cz>
67
68 PR middle-end/100504
69 * c-attribs.c (handle_target_clones_attribute): Expect a string
70 argument to target_clone argument.
71
037e3661
GA
722021-05-11 Joseph Myers <joseph@codesourcery.com>
73
74 * c-lex.c (interpret_float): Handle digit separators for C2X.
75
aa891c56
GA
762021-05-10 Martin Liska <mliska@suse.cz>
77
78 * c-ada-spec.c (print_destructor): Use startswith
79 function instead of strncmp.
80 (dump_ada_declaration): Likewise.
81 * c-common.c (disable_builtin_function): Likewise.
82 (def_builtin_1): Likewise.
83 * c-format.c (check_tokens): Likewise.
84 (check_plain): Likewise.
85 (convert_format_name_to_system_name): Likewise.
86
e4ff4ffb
GA
872021-04-28 Patrick McGehearty <patrick.mcgehearty@oracle.com>
88
89 * c-cppbuiltin.c (c_cpp_builtins): Add supporting macros for new
90 complex divide
91
c0fa3f2f
GA
922021-04-26 Thomas Schwinge <thomas@codesourcery.com>
93 Nathan Sidwell <nathan@codesourcery.com>
94 Tom de Vries <vries@codesourcery.com>
95 Julian Brown <julian@codesourcery.com>
96 Kwok Cheung Yeung <kcy@codesourcery.com>
97
98 * c.opt (Wopenacc-parallelism): New.
99
6e81e015
GA
1002021-04-19 Thomas Schwinge <thomas@codesourcery.com>
101
102 * c.opt (fopenacc-kernels=): Remove.
103
019a9220
GA
1042021-04-08 Jakub Jelinek <jakub@redhat.com>
105
106 * c-warn.c (do_warn_double_promotion): Fix comment typo,
107 occured -> occurred.
108 (check_alignment_of_packed_member): Fix a comment typo,
109 memeber -> member.
110 (warn_parm_ptrarray_mismatch): Fix comment typos, os -> of
111 and onless -> unless.
112 (warn_parm_array_mismatch): Fix comment typos, declaratation
113 -> declaration and woud -> would. Fix up comment indentation.
114
1152021-04-08 Martin Sebor <msebor@redhat.com>
116
117 PR middle-end/99883
118 * c.opt (Wmismatched-new-delete): Correct spelling.
119
b1da9916
GA
1202021-04-05 Eric Botcazou <ebotcazou@adacore.com>
121
122 * c-ada-spec.c (is_simple_enum): Minor tweaks.
123 (dump_ada_enum_type): Add TYPE and PARENT parameters. For non-simple
124 enumeral types use again the type name for the enumeration constants.
125 (dump_ada_node): Adjust call to dump_ada_enum_type.
126 (dump_nested_type): Likewise.
127
f1607029
GA
1282021-04-01 Jason Merrill <jason@redhat.com>
129
130 PR c++/98481
131 * c-opts.c (c_common_post_options): Bump latest_abi_version.
132
4493b1c1
GA
1332021-03-25 Jakub Jelinek <jakub@redhat.com>
134
135 PR c++/99565
136 * c-warn.c (do_warn_duplicated_branches): Pass also
137 OEP_ADDRESS_OF_SAME_FIELD to operand_equal_p.
138
6af7b307
GA
1392021-03-20 Jakub Jelinek <jakub@redhat.com>
140
141 PR debug/99230
142 * c-gimplify.c (c_genericize_control_stmt): Handle STATEMENT_LIST.
143
ceae9533
GA
1442021-03-05 Eric Botcazou <ebotcazou@adacore.com>
145
146 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Dump nested types
147 after entering the separate class package, if any.
148
67f10d28
GA
1492021-03-04 Richard Biener <rguenther@suse.de>
150
151 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator):
152 Handle ERROR_MARK.
153
1542021-03-04 Jakub Jelinek <jakub@redhat.com>
155
156 PR c/99325
157 * c-ppoutput.c (print): Change src_line type from int to unsigned.
158 (token_streamer::stream) Likewise.
159 (maybe_print_line_1): Likewise. Don't strcmp src_file if src_loc is
160 UNKNOWN_LOCATION.
161
f3641ac7
GA
1622021-03-03 Jakub Jelinek <jakub@redhat.com>
163
164 PR c/99324
165 * c-common.c (build_va_arg): Call c_common_mark_addressable_vec
166 instead of mark_addressable. Fix a comment typo -
167 neutrallly -> neutrally.
168
2c83c3fb
GA
1692021-02-28 Jakub Jelinek <jakub@redhat.com>
170
171 PR c/99304
172 * c-attribs.c (handle_malloc_attribute): Fix a typo in inform
173 message - refernced -> referenced. Remove superfluous space before
174 closing paren of function calls.
175
daa68844
GA
1762021-02-25 Nathan Sidwell <nathan@acm.org>
177
178 PR c++/99166
179 * c.opt (-flang-info-module-cmi): Renamed option.
180
50352c6c
GA
1812021-02-19 Nathan Sidwell <nathan@acm.org>
182
183 * c.opt (flang-info-module-read, flang-info-module-read=): New.
184
bf81237e
GA
1852021-02-18 H.J. Lu <hjl.tools@gmail.com>
186
187 PR target/99113
188 * c-attribs.c (c_common_attribute_table): Add the "retain"
189 attribute.
190 (handle_retain_attribute): New function.
191
0e804ce3
GA
1922021-02-16 Marek Polacek <polacek@redhat.com>
193
194 PR c++/99062
195 * c-attribs.c (handle_assume_aligned_attribute): Check that the
196 alignment argument is non-negative. Tweak a warning message.
197
fab095da
GA
1982021-02-12 Martin Sebor <msebor@redhat.com>
199
200 PR c/99055
201 * c-warn.c (warn_parm_array_mismatch): Free strings returned from
202 print_generic_expr_to_str.
203
4b37c3ea
GA
2042021-02-10 Richard Biener <rguenther@suse.de>
205
206 * c-common.c (parse_optimize_options): Free decoded_options.
207
a19dd5e6
GA
2082021-02-04 emsr <3dw4rd@verizon.net>
209
210 * c-cppbuiltin.c (c_cpp_builtins): __cpp_size_t_suffix=202011L.
211
9faaa807
GA
2122021-02-03 Ed Smith-Rowland <3dw4rd@verizon.net>
213
214 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_size_t_suffix.
215 * c-lex.c (interpret_integer): Set node type for size literal.
216
85d04a2e
GA
2172021-01-28 Jakub Jelinek <jakub@redhat.com>
218
219 * c.opt (-std=c++2a, -std=c++20, -std=gnu++2a, -std=gnu++20): Remove
220 draft from description.
221 (-std=c++2b): Fix a pasto, 2020 -> 2023.
222
e62bb7f0
GA
2232021-01-26 Paul Fee <paul.f.fee@gmail.com>
224
225 * c-common.h (cxx_dialect): Add cxx23 as a dialect.
226 * c.opt: Add options for -std=c++23, std=c++2b, -std=gnu++23
227 and -std=gnu++2b
228 * c-opts.c (set_std_cxx23): New.
229 (c_common_handle_option): Set options when -std=c++23 is enabled.
230 (c_common_post_options): Adjust comments.
231 (set_std_cxx20): Likewise.
232
161e4c08
GA
2332021-01-25 Martin Sebor <msebor@redhat.com>
234
235 PR c++/98646
236 * c-common.c (check_nonnull_arg): Adjust warning text.
237
4c9bcd5c
GA
2382021-01-17 Martin Sebor <msebor@redhat.com>
239
240 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
241 assume SSA_NAME_IDENTIFIER evaluates to nonzero.
242
59cf67d1
GA
2432021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
244
245 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DETACH.
246 Redefine PRAGMA_OACC_CLAUSE_DETACH.
247
2f7f0d32
GA
2482021-01-15 Jakub Jelinek <jakub@redhat.com>
249
250 PR tree-optimization/98597
251 * c-pretty-print.c: Include options.h.
252 (c_fold_indirect_ref_for_warn): New function.
253 (print_mem_ref): Use it. If it returns something that has compatible
254 type and is TBAA compatible with zero offset, print it and return,
255 otherwise print it using offsetof syntax or array ref syntax. Fix up
256 printing if MEM_REFs first operand is ADDR_EXPR, or when the first
257 argument has pointer to array type. Print pointers using the standard
258 formatting.
259
6851dda2
GA
2602021-01-12 Martin Sebor <msebor@redhat.com>
261
262 PR c/98597
263 PR c/98592
264 * c-pretty-print.c (print_mem_ref): Avoid assuming MEM_REF operand
265 has pointer type. Remove redundant code. Avoid calling
266 gimple_canonical_types_compatible_p.
267
7d187e4f
GA
2682021-01-07 Martin Sebor <msebor@redhat.com>
269
270 PR middle-end/98578
271 * c-pretty-print.c (print_mem_ref): Strip array from access type.
272 Avoid assuming acces type's size is constant. Correct condition
273 guarding the printing of a parenthesis.
274
942ae5be
GA
2752021-01-06 Martin Sebor <msebor@redhat.com>
276
277 PR c++/95768
278 * c-pretty-print.c (c_pretty_printer::primary_expression): For
279 SSA_NAMEs print VLA names and GIMPLE defining statements.
280 (print_mem_ref): New function.
281 (c_pretty_printer::unary_expression): Call it.
282
2832021-01-06 Richard Biener <rguenther@suse.de>
284
285 PR tree-optimization/95582
286 * c-attribs.c (c_common_attribute_table): Add entry for
287 signed_bool_precision.
288 (handle_signed_bool_precision_attribute): New.
289
8daa719b
GA
2902020-12-24 Iain Sandoe <iain@sandoe.co.uk>
291
292 * c.opt: Add -stdlib= option and enumerations for
293 libstdc++ and libc++.
294
eefe499f
GA
2952020-12-16 Martin Liska <mliska@suse.cz>
296
297 * c.opt: Remove usage of Report.
298
d52945ce
GA
2992020-12-14 Martin Sebor <msebor@redhat.com>
300
301 PR middle-end/98166
302 PR c++/57111
303 PR middle-end/98160
304 * c-attribs.c (maybe_add_noinline): New function.
305 (handle_malloc_attribute): Call it. Use ATTR_FLAG_INTERNAL.
306 Implicitly add attribute noinline to functions not declared inline
307 and warn on those.
308
ca2bd949
GA
3092020-12-09 Tobias Burnus <tobias@codesourcery.com>
310
311 * c-pragma.c (omp_pragmas): Add 'allocate'.
312 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ALLOCATE.
313
f6e8e279
GA
3142020-12-08 Jakub Jelinek <jakub@redhat.com>
315
316 PR c++/98187
317 * c-pragma.c (omp_pragmas): Remove "master".
318 (omp_pragmas_simd): Add "master".
319
bc8a7013
GA
3202020-12-07 Marek Polacek <polacek@redhat.com>
321
322 PR c++/98126
323 * c-common.c (verify_tree_lim_r): New function.
324 (verify_sequence_points): Use it. Use nullptr instead of 0.
325
b8dd0ef7
GA
3262020-12-03 Martin Sebor <msebor@redhat.com>
327
328 PR c++/90629
329 PR middle-end/94527
330 * c-attribs.c (handle_dealloc_attribute): New function.
331 (handle_malloc_attribute): Handle argument forms of attribute.
332 * c.opt (-Wmismatched-dealloc): New option.
333 (-Wmismatched-new-delete): New option.
334
3352020-12-03 Jakub Jelinek <jakub@redhat.com>
336
337 PR libstdc++/93121
338 * c-common.h (enum rid): Add RID_BUILTIN_BIT_CAST.
339 * c-common.c (c_common_reswords): Add __builtin_bit_cast.
340
e0f5e792
GA
3412020-12-01 JeanHeyd Meneide <phdofthehouse@gmail.com>
342
343 * c-cppbuiltin.c (c_cpp_builtins): Add predefined
344 {__GNUC_EXECUTION_CHARSET_NAME} and
345 _WIDE_EXECUTION_CHARSET_NAME} macros.
346
3472020-12-01 Nathan Sidwell <nathan@acm.org>
348
349 * c-common.c (module, import, export): New internal tokens (with
350 trailing space).
351 * c-common.h (RID__MODULE, RID__IMPORT & RID__EXPORT): Enumerate
352 them.
353 (D_CXX_MODULES, D_CXX_MODULES_FLAGS): Enable them.
354 * c-cppbuiltin.c (c_cpp_builtins): Feature macro.
355
3562020-12-01 Nathan Sidwell <nathan@acm.org>
357
358 * c-opts.c (c_common_init_options): Ask for module dependencies.
359 (c_common_handle_option): Handle -Mmodules -Mno-modules.
360 * c-pch.c (c_common_valid_pch): ... does not play with C++
361 modules.
362 * c.opt (Mmodules, Mno-modules): New preprocessor dependency
363 options.
364 (fmodules-ts, fmodule-header, fmodule-implicit-inline)
365 (fmodule-only, fmodule-mapper, fmodule-lazy)
366 (fmodule-version-ignore, Winvalid-imported-macros)
367 (flang-info-include-translate, flang-info-include-translate-not):
368 New options
369
5fbf0ecb
GA
3702020-11-28 Eric Botcazou <ebotcazou@adacore.com>
371
372 * c-ada-spec.c (dump_nested_type) <RECORD_TYPE>: Remove obsolete code.
373 (dump_ada_structure): Also deal with convention, unchecked union and
374 bit-field for nested types. In the latter case, print an Alignment
375 aspect along with the Pack aspect.
376
360258da
GA
3772020-11-25 Martin Sebor <msebor@redhat.com>
378
379 PR bootstrap/94982
380 * c-attribs.c (handle_patchable_function_entry_attribute): Avoid
381 -Wformat-diag.
382
1e2c9a27
GA
3832020-11-24 Martin Sebor <msebor@redhat.com>
384
385 * c-warn.c (warn_parm_array_mismatch): Avoid invalid redeclarations.
386
8e6198d0
GA
3872020-11-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
388
389 * c-attribs.c (handle_special_var_sec_attribute): New.
390 (handle_noinit_attribute): Remove.
391 (attr_noinit_exclusions): Rename to...
392 (attr_section_exclusions): ...this, and add "persistent" attribute
393 exclusion.
394 (c_common_attribute_table): Add "persistent" attribute.
395
7a97e2fc
GA
3962020-11-21 Aaron Sawdey <acsawdey@linux.ibm.com>
397
398 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
399 Treat opaque types like other types.
400 (c_pretty_printer::direct_abstract_declarator): Opaque types are
401 supported types.
402
82e5048e
GA
4032020-11-20 Martin Sebor <msebor@redhat.com>
404
405 * c-warn.c (warn_parm_array_mismatch): Bail on invalid redeclarations
406 with fewer arguments.
407
4082020-11-20 Martin Sebor <msebor@redhat.com>
409
410 PR middle-end/97879
411 * c-attribs.c (handle_access_attribute): Handle ATTR_FLAG_INTERNAL.
412 Error out on invalid modes.
413
4142020-11-20 Jakub Jelinek <jakub@redhat.com>
415
416 PR libstdc++/88101
417 * c-common.c (check_builtin_function_arguments): Handle
418 BUILT_IN_CLEAR_PADDING.
419
25bb75f8
GA
4202020-11-18 Nathan Sidwell <nathan@acm.org>
421
422 * c-lex.c (c_lex_with_flags): CPP_HEADER_NAMEs can now be seen.
423
4dabb037
GA
4242020-11-17 Nathan Sidwell <nathan@acm.org>
425
426 * c-common.h (enum c_tree_index): Reorder to place lazy fields
427 after newly-added CTI_MODULE_HWM.
428
4292020-11-17 Joseph Myers <joseph@codesourcery.com>
430
431 * c-cppbuiltin.c (builtin_define_float_constants): Define
432 "*_IS_IEC_60559__" macros.
433
4342020-11-17 Nathan Sidwell <nathan@acm.org>
435
436 * c-lex.c: #include "langhooks.h".
437 (cb_undef): Maybe call preprocess_undef lang hook.
438 * c-opts.c (c_common_post_options): Maybe call preprocess_options
439 lang hook.
440 (push_command_line_include): Maybe call preprocess_main_file lang
441 hook.
442 (cb_file_change): Likewise.
443 * c-ppoutput.c: #include "langhooks.h.
444 (scan_translation_unit): Maybe call preprocess_token lang hook.
445 (class do_streamer): New, derive from token_streamer.
446 (directives_only_cb): Data pointer is do_streamer, call
447 preprocess_token lang hook.
448 (scan_translation_unit_directives_only): Use do_streamer.
449 (print_line_1): Move src_line recording to after string output.
450 (cb_undef): Maybe call preprocess_undef lang hook.
451
4522020-11-17 Nathan Sidwell <nathan@acm.org>
453
454 * c-ppoutput.c (scan_translation_unit): Use token_streamer, remove
455 code duplicating that functionality.
456
4572020-11-17 Jakub Jelinek <jakub@redhat.com>
458
459 PR c/90628
460 * c-common.c (check_builtin_function_arguments)
461 <case BUILT_IN_ADD_OVERFLOW>: Diagnose when last argument is pointer
462 to _Atomic. For the TYPE_READONLY case, adjust message to be usable
463 for more builtins and argument positions.
464
29c5d9ce
GA
4652020-11-16 Iain Sandoe <iain@sandoe.co.uk>
466
467 PR objc/97854
468 * stub-objc.c: Include c-common.h to declare enum rid.
469
77f67db2
GA
4702020-11-13 Jakub Jelinek <jakub@redhat.com>
471
472 PR c++/63287
473 * c-cppbuiltin.c: Include configargs.h.
474 (c_cpp_builtins): For C++11 and later if THREAD_MODEL_SPEC is not
475 defined, predefine __STDCPP_THREADS__ to 1 unless thread_model is
476 "single".
477
4782020-11-13 Gergö Barany <gergo@codesourcery.com>
479 Thomas Schwinge <thomas@codesourcery.com>
480
481 * c.opt (fopenacc-kernels): Add.
482
4832020-11-13 Jason Merrill <jason@redhat.com>
484
485 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_using_enum.
486
4872020-11-13 Piotr H. Dabrowski <phd@phd.re>
488
489 PR c++/91318
490 * c-cppbuiltin.c: c_cpp_builtins_optimize_pragma(): use cpp_define_unused()
491
4922020-11-13 Martin Liska <mliska@suse.cz>
493
494 * c-attribs.c (build_attr_access_from_parms): Format properly.
495
4962020-11-13 Iain Sandoe <iain@sandoe.co.uk>
497
498 PR objc/90707
499 * c-common.c (c_common_reswords): null_unspecified, nullable,
500 nonnull, null_resettable: New keywords.
501 * c-common.h (enum rid): RID_NULL_UNSPECIFIED, RID_NULLABLE,
502 RID_NONNULL, RID_NULL_RESETTABLE: New.
503 (OBJC_IS_PATTR_KEYWORD): Include nullability keywords in the
504 ranges accepted for property attributes.
505 * c-attribs.c (handle_objc_nullability_attribute): New.
506 * c-objc.h (enum objc_property_attribute_group): Add
507 OBJC_PROPATTR_GROUP_NULLABLE.
508 (enum objc_property_attribute_kind):Add
509 OBJC_PROPERTY_ATTR_NULL_UNSPECIFIED, OBJC_PROPERTY_ATTR_NULLABLE,
510 OBJC_PROPERTY_ATTR_NONNULL, OBJC_PROPERTY_ATTR_NULL_RESETTABLE.
511
5122020-11-13 Iain Sandoe <iain@sandoe.co.uk>
513
514 PR objc/77404
515 * c-attribs.c (handle_objc_root_class_attribute): New
516 * c-objc.h (objc_start_class_interface): Add a location
517 value for the position of the class name.
518 * c.opt: Add Wobjc-root-class.
519 * stub-objc.c (objc_start_class_interface): Add a location
520 value for the position of the class name.
521
a5a11525
GA
5222020-11-12 Joseph Myers <joseph@codesourcery.com>
523
524 * c-lex.c (c_common_has_attribute): Take argument std_syntax.
525 Allow scope for C. Handle standard attributes for C. Do not
526 accept unscoped attributes if std_syntax and not handled as
527 standard attributes.
528 * c-common.h (c_common_has_attribute): Update prototype.
529
5302020-11-12 Nicholas Guriev <guriev-ns@ya.ru>
531
532 PR pch/86674
533 * c-pch.c (c_common_valid_pch): Use cpp_warning with CPP_W_INVALID_PCH
534 reason to fix -Werror=invalid-pch and -Wno-error=invalid-pch switches.
535
0f5f9ed5
GA
5362020-11-11 Patrick Palka <ppalka@redhat.com>
537
538 PR c++/88115
539 * c-opts.c (c_common_post_options): Update latest_abi_version.
540
bb622641
GA
5412020-11-10 Jakub Jelinek <jakub@redhat.com>
542
543 PR c/97748
544 * c-common.h (warn_if_unused_value): Add quiet argument defaulted
545 to false.
546 * c-warn.c (warn_if_unused_value): Likewise. Pass it down
547 recursively and just return true instead of warning if it is true.
548 Handle COMPLEX_EXPR.
549
5502020-11-10 Chung-Lin Tang <cltang@codesourcery.com>
551
552 * c-common.h (c_omp_adjust_map_clauses): New declaration.
553 * c-omp.c (struct map_clause): Helper type for c_omp_adjust_map_clauses.
554 (c_omp_adjust_map_clauses): New function.
555
2bee28dd
GA
5562020-11-09 Marek Polacek <polacek@redhat.com>
557
558 DR 1914
559 * c-common.c (attribute_fallthrough_p): Tweak the warning
560 message.
561
5622020-11-09 Patrick Palka <ppalka@redhat.com>
563
564 * c-pragma.c (handle_pragma_diagnostic): Split the
565 unknown-option -Wpragmas diagnostic into a warning and a
566 subsequent note containing a spelling suggestion. Avoid
567 computing the suggestion if -Wpragmas warnings are being
568 suppressed.
569
5702020-11-09 Patrick Palka <ppalka@redhat.com>
571
572 PR testsuite/97117
573 * c-indentation.c (get_visual_column): Remove location_t
574 parameter. Move the column-tracking diagnostic code from here
575 to ...
576 (should_warn_for_misleading_indentation): ... here, before the
577 early exit for when the loci are not all distinct. Don't pass a
578 location_t argument to get_visual_column.
579 (assert_get_visual_column_succeeds): Don't pass a location_t
580 argument to get_visual_column.
581 (assert_get_visual_column_fails): Likewise.
582
fb95de7a
GA
5832020-11-08 Iain Sandoe <iain@sandoe.co.uk>
584
585 * c-common.h (OBJC_IS_PATTR_KEYWORD): Add class to the list
586 of keywords accepted in @property attribute contexts.
587 * c-objc.h (enum objc_property_attribute_group): Add
588 OBJC_PROPATTR_GROUP_CLASS.
589 (enum objc_property_attribute_kind): Add
590 OBJC_PROPERTY_ATTR_CLASS.
591
2da7ee05
GA
5922020-11-07 Iain Sandoe <iain@sandoe.co.uk>
593
594 * c-common.c (c_common_reswords): Add 'atomic' property
595 attribute.
596 * c-common.h (enum rid): Add RID_PROPATOMIC for atomic
597 property attributes.
598
5992020-11-07 Iain Sandoe <iain@sandoe.co.uk>
600
601 * c-attribs.c (handle_nsobject_attribute): New.
602 * c.opt: Add WNSObject-attribute.
603
44cab2d8
GA
6042020-11-06 Iain Sandoe <iain@sandoe.co.uk>
605
606 * c-objc.h (enum objc_property_attribute_group): New
607 (enum objc_property_attribute_kind): New.
608 (OBJC_PROPATTR_GROUP_MASK): New.
609 (struct property_attribute_info): Small class encapsulating
610 parser output from property attributes.
611 (objc_prop_attr_kind_for_rid): New
612 (objc_add_property_declaration): Simplify interface.
613 * stub-objc.c (enum rid): Dummy type.
614 (objc_add_property_declaration): Simplify interface.
615 (objc_prop_attr_kind_for_rid): New.
616
6172020-11-06 Nathan Sidwell <nathan@acm.org>
618
619 * c-ada-spec.c (collect_ada_nodes): Rename
620 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
621 (collect_ada_node): Likewise.
622 (dump_forward_type): Likewise.
623 * c-common.c (set_underlying_type): Rename
624 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
625 (user_facing_original_type, c_common_finalize_early_debug): Likewise.
626
6272020-11-06 Jakub Jelinek <jakub@redhat.com>
628
629 * c-common.c (verify_sequence_points): Remove DEBUG_FUNCTION.
630
0cfd9109
GA
6312020-11-05 Marek Polacek <polacek@redhat.com>
632
633 PR c++/97675
634 * c.opt (Wexceptions): New option.
635
6362020-11-05 Marek Polacek <polacek@redhat.com>
637
638 PR c++/25814
639 * c.opt (Wvexing-parse): New option.
640
35c125cb
GA
6412020-11-04 Jakub Jelinek <jakub@redhat.com>
642
643 PR c++/97670
644 * c-omp.c (c_omp_split_clauses): Look through array reductions to find
645 underlying decl to clear in the allocate_head bitmap.
646
6472020-11-04 Iain Sandoe <iain@sandoe.co.uk>
648
649 * c-objc.h (objc_non_constant_expr_p): New.
650 * stub-objc.c (objc_non_constant_expr_p): New.
651
fd2325ea
GA
6522020-11-03 Nathan Sidwell <nathan@acm.org>
653
654 * c.opt (MQ,MT): Reword description to be make-agnostic.
655
88ce3d5f
GA
6562020-11-02 Nathan Sidwell <nathan@acm.org>
657
658 * c-opts.c (c_common_post_options): Move var decl to its
659 initialization point.
660
6612020-11-01 Iain Sandoe <iain@sandoe.co.uk>
662
663 * c-lex.c (c_lex_with_flags): When combining '@' with a
664 keyword for Objective-C, combine the location ranges too.
665
6662020-10-30 Qing Zhao <qing.zhao@oracle.com>
667 H.J.Lu <hjl.tools@gmail.com>
668
669 * c-attribs.c (c_common_attribute_table): Add new attribute
670 zero_call_used_regs.
671 (handle_zero_call_used_regs_attribute): New function.
672
e93aae4a
GA
6732020-10-28 Marek Polacek <polacek@redhat.com>
674
675 PR c++/97573
676 * c-opts.c (c_common_post_options): In C++20, turn on
677 -Wdeprecated-enum-enum-conversion and
678 -Wdeprecated-enum-float-conversion.
679 * c.opt (Wdeprecated-enum-enum-conversion,
680 Wdeprecated-enum-float-conversion): New options.
681 (Wenum-conversion): Allow for C++ too.
682
6832020-10-28 Jakub Jelinek <jakub@redhat.com>
684
685 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALLOCATE.
686 * c-omp.c: Include bitmap.h.
687 (c_omp_split_clauses): Handle OMP_CLAUSE_ALLOCATE.
688
f19e7c8d
GA
6892020-10-26 Ville Voutilainen <ville.voutilainen@gmail.com>
690
691 * c-common.c (__is_nothrow_assignable): New.
692 (__is_nothrow_constructible): Likewise.
693 * c-common.h (RID_IS_NOTHROW_ASSIGNABLE): New.
694 (RID_IS_NOTHROW_CONSTRUCTIBLE): Likewise.
695
efe71fcc
GA
6962020-10-23 Jan Hubicka <hubicka@ucw.cz>
697
698 * c-common.c (c_common_finalize_early_debug): Update for new thunk api.
699
7002020-10-23 Marek Polacek <polacek@redhat.com>
701
702 PR c++/91741
703 * c-common.c (verify_tree): Handle PAREN_SIZEOF_EXPR.
704 (c_common_init_ts): Likewise.
705 * c-common.def (PAREN_SIZEOF_EXPR): New tree code.
706 * c-common.h (maybe_warn_sizeof_array_div): Declare.
707 * c-warn.c (sizeof_pointer_memaccess_warning): Unwrap NOP_EXPRs.
708 (maybe_warn_sizeof_array_div): New function.
709 * c.opt (Wsizeof-array-div): New option.
710
7112020-10-23 Martin Sebor <msebor@redhat.com>
712
713 PR c/97463
714 * c-warn.c (warn_parm_ptrarray_mismatch): Move null test earlier.
715
56ddd5e2
GA
7162020-10-22 Martin Liska <mliska@suse.cz>
717
718 PR c/94722
719 * c-attribs.c (handle_no_stack_protect_function_attribute): New.
720 (handle_stack_protect_attribute): Add error message for a
721 no_stack_protector function.
722
7232020-10-22 Martin Liska <mliska@suse.cz>
724
725 * c-cppbuiltin.c (c_cpp_builtins): Use the stack_protector enum.
726
7272020-10-22 Jan Hubicka <hubicka@ucw.cz>
728
729 * c-gimplify.c: Include tree-nested.h
730 (c_genericize): Update for new nested function info.
731
b2698c21
GA
7322020-10-14 Martin Sebor <msebor@redhat.com>
733
734 PR c/97413
735 * c-attribs.c (build_attr_access_from_parms): Wrap chain of VLA
736 bounds in an extra list.
737
7e9282ae
GA
7382020-10-05 Richard Biener <rguenther@suse.de>
739 Jakub Jelinek <jakub@redhat.com>
740
741 PR c++/97197
742 * c-pretty-print.c: Include langhooks.h.
743 (c_pretty_printer::postfix_expression): Handle TARGET_MEM_REF as
744 expression.
745 (c_pretty_printer::expression): Handle TARGET_MEM_REF as
746 unary_expression.
747 (c_pretty_printer::unary_expression): Handle TARGET_MEM_REF.
748
660bfe61
GA
7492020-09-30 Martin Sebor <msebor@redhat.com>
750
751 PR middle-end/97189
752 * c-attribs.c (append_access_attr): Use the function declaration
753 location for a warning about an attribute access argument.
754
93bca37c
GA
7552020-09-29 Marek Polacek <polacek@redhat.com>
756
757 PR c++/94695
758 * c.opt (Wrange-loop-construct): New option.
759
82b77dee
GA
7602020-09-23 Martin Sebor <msebor@redhat.com>
761
762 PR c/97131
763 * c-warn.c (warn_parm_ptrarray_mismatch): Handle more invalid input.
764
7652020-09-23 Marek Polacek <polacek@redhat.com>
766
767 PR c/97125
768 * c-gimplify.c (c_genericize): Only call do_warn_duplicated_branches_r
769 after loops and other structured control constructs have been lowered.
770
521d2711
GA
7712020-09-22 Jakub Jelinek <jakub@redhat.com>
772
773 * c.opt (Wbuiltin-declaration-mismatch): Fix typo in variable name:
774 warn_builtin_declaraion_mismatch -> warn_builtin_declaration_mismatch.
775
44135373
GA
7762020-09-21 Marek Polacek <polacek@redhat.com>
777
778 * c.opt (Wctad-maybe-unsupported): New option.
779
2fe5b7d1
GA
7802020-09-19 Martin Sebor <msebor@redhat.com>
781
782 PR c/50584
783 * c-common.h (warn_parm_array_mismatch): Declare new function.
784 (has_attribute): Move declaration of an existing function.
785 (build_attr_access_from_parms): Declare new function.
786 * c-warn.c (parm_array_as_string): Define new function.
787 (plus_one): Define new function.
788 (warn_parm_ptrarray_mismatch): Define new function.
789 (warn_parm_array_mismatch): Define new function.
790 (vla_bound_parm_decl): New function.
791 * c.opt (-Warray-parameter, -Wvla-parameter): New options.
792 * c-pretty-print.c (pp_c_type_qualifier_list): Don't print array type
793 qualifiers here...
794 (c_pretty_printer::direct_abstract_declarator): ...but instead print
795 them in brackets here. Also print [static]. Strip extraneous
796 expressions from VLA bounds.
797
7982020-09-19 Martin Sebor <msebor@redhat.com>
799
800 PR c/50584
801 * c-attribs.c (c_common_attribute_table): Add "arg spec" attribute.
802 (handle_argspec_attribute): New function.
803 (get_argument, get_argument_type): New functions.
804 (append_access_attrs): Add overload. Handle internal attribute
805 representation in addition to external.
806 (handle_access_attribute): Handle internal attribute representation
807 in addition to external.
808 (build_attr_access_from_parms): New function.
809
8102020-09-19 Sandra Loosemore <sandra@codesourcery.com>
811
812 * c-gimplify.c (genericize_c_loop): Rewrite to match
813 c_finish_loop in c-typeck.c.
814
8152020-09-19 Sandra Loosemore <sandra@codesourcery.com>
816
817 * c-common.c (c_block_may_fallthrough): New, split from
818 cxx_block_may_fallthrough in the cp front end.
819 (c_common_init_ts): Move handling of loop and switch-related
820 statements here from the cp front end.
821 * c-common.def (FOR_STMT, WHILE_STMT, DO_STMT): Move here from
822 cp front end.
823 (BREAK_STMT, CONTINUE_STMT, SWITCH_STMT): Likewise.
824 * c-common.h (c_block_may_fallthru): Declare.
825 (bc_state_t): Move here from cp front end.
826 (save_bc_state, restore_bc_state): Declare.
827 (c_genericize_control_stmt): Declare.
828 (WHILE_COND, WHILE_BODY): Likewise.
829 (DO_COND, DO_BODY): Likewise.
830 (FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY, FOR_SCOPE): Likewise.
831 (SWITCH_STMT_COND, SWITCH_STMT_BODY): Likewise.
832 (SWITCH_STMT_TYPE, SWITCH_STMT_SCOPE): Likewise.
833 (SWITCH_STMT_ALL_CASES_P, SWITCH_STMT_NO_BREAK_P): Likewise.
834 (LABEL_DECL_BREAK, LABEL_DECL_CONTINUE): Likewise.
835 * c-dump.c (dump_stmt): Copy from cp front end.
836 (c_dump_tree): Move code to handle structured loop and switch
837 tree nodes here from cp front end.
838 * c-gimplify.c: Adjust includes.
839 (enum bc_t, bc_label, begin_bc_block, finish_bc_block): Move from
840 cp front end.
841 (save_bc_state, restore_bc_state): New functions using old code
842 from cp front end.
843 (get_bc_label, expr_loc_or_loc): Move from cp front end.
844 (genericize_c_loop): Move from cp front end.
845 (genericize_for_stmt, genericize_while_stmt): Likewise.
846 (genericize_do_stmt, genericize_switch_stmt): Likewise.
847 (genericize_continue_stmt, genericize_break_stmt): Likewise.
848 (genericize_omp_for_stmt): Likewise.
849 (c_genericize_control_stmt): New function using code split from
850 cp front end.
851 (c_genericize_control_r): New.
852 (c_genericize): Call walk_tree with c_genericize_control_r.
853 * c-pretty-print.c (c_pretty_printer::statement): Move code to handle
854 structured loop and switch tree nodes here from cp front end.
855
2aad20c0
GA
8562020-09-17 Patrick Palka <ppalka@redhat.com>
857
858 PR c/80076
859 * c-indentation.c (should_warn_for_misleading_indentation): Move
860 declarations of local variables closer to their first use.
861 Handle virtual token locations by resolving them to their
862 respective macro expansion points. If all three tokens are
863 produced from the same macro expansion, then instead use their
864 loci within the macro definition.
865
ecde1b0a
GA
8662020-09-16 Martin Sebor <msebor@redhat.com>
867
868 PR c/78666
869 PR c/96126
870 * c-attribs.c (validate_attr_args): New function.
871 (validate_attr_arg): Same.
872 (handle_section_attribute): Call it. Introduce a local variable.
873 (handle_alloc_size_attribute): Same.
874 (handle_alloc_align_attribute): Same.
875
50a71cd0
GA
8762020-09-14 Jakub Jelinek <jakub@redhat.com>
877
878 * c-attribs.c (handle_optimize_attribute): Adjust
879 cl_optimization_save, cl_optimization_restore and
880 build_optimization_node callers.
881 * c-pragma.c (handle_pragma_optimize): Adjust
882 build_optimization_node caller.
883 (handle_pragma_push_options): Adjust
884 build_optimization_node and build_target_option_node callers.
885 (handle_pragma_pop_options, handle_pragma_reset_options):
886 Adjust cl_optimization_restore callers.
887
8f7ea26a
GA
8882020-08-28 Martin Sebor <msebor@redhat.com>
889
890 * c.opt (Wstringop-overread): New option.
891
a6493809
GA
8922020-08-11 Jakub Jelinek <jakub@redhat.com>
893
894 PR c/96545
895 * c-common.c (get_atomic_generic_size): Require that first argument's
896 type points to a complete type and use tree_fits_uhwi_p instead of
897 just INTEGER_CST TREE_CODE check for the TYPE_SIZE_UNIT.
898
48cc2e46
GA
8992020-07-31 Martin Sebor <msebor@redhat.com>
900
901 PR c++/96003
902 * c-common.c (check_function_arguments_recurse): Return early when
903 no-warning bit is set.
904
9052020-07-31 Richard Biener <rguenther@suse.de>
906
907 PR debug/96383
908 * c-common.h (c_common_finalize_early_debug): Declare.
909 * c-common.c: Include debug.h.
910 (c_common_finalize_early_debug): finalize_early_debug langhook
911 implementation generating debug for extern declarations.
912
e71dab87
GA
9132020-07-27 Nathan Sidwell <nathan@acm.org>
914
915 * c-common.c (try_to_locate_new_include_insertion_point): Use
916 strcmp, not pointer equality.
917
ae2e0bc1
GA
9182020-07-25 Martin Sebor <msebor@redhat.com>
919
920 PR c++/96310
921 * c-common.c (check_nonnull_arg): Print note only when warning was
922 issued.
923
3ea9abca
GA
9242020-07-22 Tobias Burnus <tobias@codesourcery.com>
925
926 * c-omp.c (c_finish_omp_critical): Check for no name but
927 nonzero hint provided.
928
0933f508
GA
9292020-07-20 Jason Merrill <jason@redhat.com>
930
931 * c-cppbuiltin.c (c_cpp_builtins): Update
932 __cpp_nontype_template_args for C++20.
933
9342020-07-20 Martin Sebor <msebor@redhat.com>
935
936 PR c/96249
937 * c.opt: Remove stray text.
938
8ca07a30
GA
9392020-07-14 Lewis Hyatt <lhyatt@gmail.com>
940
941 PR other/86904
942 * c-indentation.c (should_warn_for_misleading_indentation): Get
943 global tabstop from the new source.
944 * c-opts.c (c_common_handle_option): Remove handling of -ftabstop, which
945 is now a common option.
946 * c.opt: Likewise.
947
a82c4c4c 9482020-07-08 Eric Botcazou <ebotcazou@adacore.com>
50873cc5
GA
949
950 * c.opt (Wscalar-storage-order): Add explicit variable.
951
f60ee68d
GA
9522020-07-07 Nathan Sidwell <nathan@acm.org>
953
954 * c-opts.c (c_common_post_options): Add 'injecting' arg to
955 cpp_read_main_file.
956 (c_finish_options): Add linemap_line_start calls for builtin and cmd
957 maps. Force token position to line_table's highest line.
958 * c-ppoutput.c (print_line_1): Refactor, print line zero.
959 (cb_define): Always increment source line.
960
4077d74c
GA
9612020-07-06 Martin Sebor <msebor@redhat.com>
962
963 PR c++/95984
964 * c-common.c (check_function_nonnull): Avoid checking syntesized calls
965 to stub lambda objects with null this pointer.
966 (check_nonnull_arg): Handle C++ nullptr.
967
b5f24739
GA
9682020-07-02 Jason Merrill <jason@redhat.com>
969 Jakub Jelinek <jakub@redhat.com>
970
971 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_consteval.
972
46fbb6c6
GA
9732020-06-30 Jakub Jelinek <jakub@redhat.com>
974
975 PR c++/95963
976 * c-common.c (check_function_arguments_recurse): Don't crash on
977 calls to internal functions.
978
69273534
GA
9792020-06-28 Martin Sebor <msebor@redhat.com>
980
981 PR c++/86568
982 * c-common.c (struct nonnull_arg_ctx): Add members.
983 (check_function_nonnull): Use nonnull_arg_ctx as argument. Handle
984 C++ member functions specially. Consider the this pointer implicitly
985 nonnull.
986 (check_nonnull_arg): Use location of argument when available.
987 (check_function_arguments): Use nonnull_arg_ctx as argument.
988
9a33c41f
GA
9892020-06-27 Jakub Jelinek <jakub@redhat.com>
990
991 PR middle-end/95903
992 * c-common.c (pointer_int_sum): Use TYPE_OVERFLOW_UNDEFINED instead of
993 !TYPE_UNSIGNED check to see if we can apply distributive law and handle
994 smaller precision intop operands separately.
995
c9c05f73
GA
9962020-06-26 Marek Polacek <polacek@redhat.com>
997
998 * c-opts.c (c_common_init_options): Default to gnu++17.
999
aff95ee7
GA
10002020-06-17 Jonathan Wakely <jwakely@redhat.com>
1001
bd0a89dc 1002 PR c/95378
aff95ee7
GA
1003 * c-common.c (get_atomic_generic_size): Check cv-qualifiers in
1004 pointer arguments.
1005
56638b9b
GA
10062020-06-16 Jakub Jelinek <jakub@redhat.com>
1007
1008 * c-common.h (c_omp_check_loop_iv_exprs): Add an int argument.
1009 * c-omp.c (struct c_omp_check_loop_iv_data): Add maybe_nonrect and
1010 idx members.
1011 (c_omp_is_loop_iterator): New function.
1012 (c_omp_check_loop_iv_r): Use it. Add support for silent scanning
1013 if outer loop iterator is present. Perform duplicate checking through
1014 hash_set in the function rather than expecting caller to do that.
1015 Pass NULL instead of d->ppset to walk_tree_1.
1016 (c_omp_check_nonrect_loop_iv): New function.
1017 (c_omp_check_loop_iv): Use it. Fill in new members, allow
1018 non-rectangular loop forms, diagnose multiple associated loops with
1019 the same iterator. Pass NULL instead of &pset to walk_tree_1.
1020 (c_omp_check_loop_iv_exprs): Likewise.
1021
ec6ffbb9
GA
10222020-06-10 Martin Liska <mliska@suse.cz>
1023
1024 PR tree-optimization/92860
1025 * c-attribs.c (handle_optimize_attribute):
1026 Save global options and compare it after parsing of function
1027 attribute.
1028 * c-pragma.c (opt_stack::saved_global_options): New field.
1029 (handle_pragma_push_options): Save global_options.
1030 (handle_pragma_pop_options): Compare them after pop.
1031
b952c2cf
GA
10322020-06-09 Jakub Jelinek <jakub@redhat.com>
1033
1034 PR c/95580
1035 * c-pretty-print.c (c_pretty_printer::unary_expression): Handle the
1036 case when MEM_REF's first argument has type pointer to incomplete type.
1037
1a59f3db
GA
10382020-06-05 Jason Merrill <jason@redhat.com>
1039
1040 * c-pretty-print.c (pp_c_additive_expression): Handle negative
1041 operand to POINTER_PLUS_EXPR.
1042
3add3425
GA
10432020-06-04 Martin Sebor <msebor@redhat.com>
1044
1045 PR middle-end/10138
1046 PR middle-end/95136
1047 * c-attribs.c (append_access_attrs): Handle attr_access::none.
1048 (handle_access_attribute): Same.
1049
9a5b7438
GA
10502020-06-03 Mark Wielaard <mark@klomp.org>
1051
1052 * known-headers.cc (get_cp_stdlib_header_for_string_macro_name):
1053 New function.
1054 * known-headers.h (get_cp_stdlib_header_for_string_macro_name):
1055 New function declaration.
1056
10572020-06-03 Mark Wielaard <mark@klomp.org>
1058
1059 * known-headers.cc (get_string_macro_hint): New function.
1060 (get_stdlib_header_for_name): Use get_string_macro_hint.
1061 (get_c_stdlib_header_for_string_macro_name): New function.
1062 * known-headers.h (get_c_stdlib_header_for_string_macro_name):
1063 New function declaration.
1064
10652020-06-03 Tobias Burnus <tobias@codesourcery.com>
1066
1067 * c-common.h (c_omp_predetermined_mapping): Declare.
1068 * c-omp.c (c_omp_predetermined_mapping): New.
1069
af114c38
MW
10702020-05-22 Mark Wielaard <mark@klomp.org>
1071
1072 * known-headers.cc (get_stdlib_header_for_name): Add a new
1073 stdlib_hint array for stdbool and stdint.
1074
45c50b6a
MW
10752020-05-22 Mark Wielaard <mark@klomp.org>
1076
1077 * known-headers.cc (get_stdlib_header_for_name): Return
1078 "<stdbool.h>" for "bool", "true" or "false" when STDLIB_C and
1079 flag_isoc99.
1080
c22027a0
NS
10812020-05-20 Nathan Sidwell <nathan@acm.org>
1082
38a4db21
NS
1083 * c-common.c (try_to_locate_new_include_insertion_point): Revert change.
1084
c22027a0
NS
1085 * c-common.c (try_to_locate_new_include_insertion_point): Use
1086 strcmp to compare filenames.
1087 * c-lex.c (init_c_lex): Move declaration to initialization.
1088 * c-opts.c (handle_deferred_opts): Move cpp_get_deps call into
1089 deferred count loop.
1090
29f0e90d
JM
10912020-05-15 Jason Merrill <jason@redhat.com>
1092
1093 * c-opts.c (set_std_cxx20): Set flag_coroutines.
1094
b04445d4
JM
10952020-05-13 Jason Merrill <jason@redhat.com>
1096
1097 * c.opt (std=c++20): Make c++2a the alias.
1098 (std=gnu++20): Likewise.
1099 * c-common.h (cxx_dialect): Change cxx2a to cxx20.
1100 * c-opts.c: Adjust.
1101 * c-cppbuiltin.c: Adjust.
1102 * c-ubsan.c: Adjust.
1103 * c-warn.c: Adjust.
1104
11dd3be5
EB
11052020-05-12 Eric Botcazou <ebotcazou@adacore.com>
1106
1107 * c-ada-spec.c (dump_ads): Output pragma Warnings ("U"); on entry.
1108
b224c376
NS
11092020-05-08 Nathan Sidwell <nathan@acm.org>
1110
1111 Reimplement directives only processing.
1112 * c-ppoutput.c (token_streamer): Ne.
1113 (directives_only_cb): New. Swallow ...
1114 (print_lines_directives_only): ... this.
1115 (scan_translation_unit_directives_only): Reimplment using the
1116 published interface.
1117
f1d94677
MP
11182020-05-07 Marek Polacek <polacek@redhat.com>
1119
1120 * c-format.c (badwords): Add "nonstatic".
1121
9b95bb52
JJ
1122202-05-07 Jakub Jelinek <jakub@redhat.com>
1123
1124 PR c/94968
1125 * c-common.c (speculation_safe_value_resolve_params): Return false if
1126 error_operand_p (val2).
1127 (resolve_overloaded_builtin) <case BUILT_IN_SPECULATION_SAFE_VALUE_N>:
1128 Remove extraneous semicolon.
1129
530b4409 11302020-05-06 qing zhao <qing.zhao@oracle.com>
1131
1132 PR c/94230
1133 * c-indentation.c (get_visual_column): Add a hint to use the new
1134 -flarge-source-files option.
1135
b776bdca
SSF
11362020-05-05 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
1137
1138 * c-attribs.c (handle_vector_size_attribute): Add attribute
1139 nonnull for argument args in order to silence warning of
1140 uninitialized variable usage. Since this is local to the
1141 compilation unit and thus cannot be checked at call sides by the
1142 compiler, added an assert statement in order to verify this.
1143
6607bdd9
L
11442020-05-01 H.J. Lu <hongjiu.lu@intel.com>
1145
1146 PR target/93492
1147 * c-attribs.c (handle_patchable_function_entry_attribute): Limit
1148 value to USHRT_MAX (65535).
1149
691eeb65
JJ
11502020-04-29 Jakub Jelinek <jakub@redhat.com>
1151
1152 * c-format.c (PP_FORMAT_CHAR_TABLE): Add %{ and %}.
1153
26d76be7
JJ
11542020-04-27 Jakub Jelinek <jakub@redhat.com>
1155
1156 PR c/94755
1157 * c-common.c (resolve_overloaded_builtin): Return error_mark_node for
1158 fncode == BUILT_IN_NONE before initialization of first_param.
1159
7291b2ed
MP
11602020-04-23 Marek Polacek <polacek@redhat.com>
1161
1162 PR c++/94733
1163 * c-attribs.c (find_tm_attribute): Use get_attribute_name instead of
1164 TREE_PURPOSE.
1165
58a29af8
PP
11662020-04-14 Patrick Palka <ppalka@redhat.com>
1167
1168 PR c++/85278
1169 * c-pretty-print.c (pp_c_pointer) <case REFERENCE_TYPE>: Print a double
1170 ampersand if it's an rvalue reference type.
1171
09f04139
MS
11722020-04-13 Martin Sebor <msebor@redhat.com>
1173
1174 PR c/92326
1175 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator): Avoid
1176 printing array bound for flexible array members.
1177
ee26baf4
IS
11782020-04-13 Iain Sandoe <iain@sandoe.co.uk>
1179
1180 * c-cppbuiltin.c (c_cpp_builtins): Update coroutines builtin
1181 define, per n4861.
1182
75efe9cb
RB
11832020-04-02 Richard Biener <rguenther@suse.de>
1184
1185 PR c/94392
1186 * c-opts.c (c_common_post_options): Enable -ffinite-loops
1187 for -O2 and C++11 or newer.
1188
75defde9
PP
11892020-03-28 Patrick Palka <ppalka@redhat.com>
1190
1191 * c.opt: Add -fconcepts-diagnostics-depth.
1192
52f24a9e
MS
11932020-03-27 Martin Sebor <msebor@redhat.com>
1194
1195 PR c++/94346
1196 * c-attribs.c (handle_copy_attribute): Avoid passing expressions
1197 to decl_attributes. Make handling of different kinds of entities
1198 more robust.
1199
ccacf77b
MS
12002020-03-27 Martin Sebor <msebor@redhat.com>
1201
1202 PR c++/94098
1203 * c-attribs.c (handle_access_attribute): Avoid setting TYPE_ATTRIBUTES
1204 here.
1205
ca6c7225
JJ
12062020-03-23 Jakub Jelinek <jakub@redhat.com>
1207
1208 PR c++/91993
1209 * c-warn.c (warnings_for_convert_and_check): For expr and/or
1210 result being COMPOUND_EXPRs, skip to ultimate rhs.
1211
1aa22b19
RS
12122020-03-20 Richard Sandiford <richard.sandiford@arm.com>
1213
1214 PR middle-end/94072
1215 * c-common.c (c_common_type_for_mode): Before using a registered
1216 built-in type, check that the vectorness of the type matches
1217 the vectorness of the mode.
1218
700d4cb0
JJ
12192020-03-17 Jakub Jelinek <jakub@redhat.com>
1220
1221 * c-common.c (resolve_overloaded_builtin): Fix up duplicated word
1222 issue in a diagnostic message.
1223
b408e010
LH
12242020-03-15 Lewis Hyatt <lhyatt@gmail.com>
1225
1226 * c.opt: Avoid redundancy in the help text.
1227
e78e50d5
MP
12282020-03-02 Marek Polacek <polacek@redhat.com>
1229
1230 PR c++/93958 - add missing -std=gnu++20.
1231 * c.opt: Add -std=gnu++20.
1232
649e1741
MS
12332020-03-01 Martin Sebor <msebor@redhat.com>
1234
1235 PR c++/92721
1236 * c-attribs.c (append_access_attrs): Correctly handle attribute.
1237 (handle_access_attribute): Same.
1238
7b60f3ba
JJ
12392020-02-25 Jakub Jelinek <jakub@redhat.com>
1240
1241 PR c/93858
1242 * c-pragma.c (handle_pragma_diagnostic): Add missing ? after
1243 "did you mean" hint in diagnostics.
1244
fb260504
JM
12452020-02-15 Jason Merrill <jason@redhat.com>
1246
1247 * c.opt: Add -std=c++20.
1248
1d757b09
EB
12492020-02-14 Eric Botcazou <ebotcazou@adacore.com>
1250
1251 * c-ada-spec.c: Include bitmap.h.
1252 (dump_ada_double_name): Rename into...
1253 (dump_anonymous_type_name): ...this. Always use the TYPE_UID.
1254 (dump_ada_array_type): Adjust to above renaming. Robustify.
1255 (dump_nested_types_1): New function copied from... Add dumped_types
1256 parameter and pass it down to dump_nested_type.
1257 (dump_nested_types): ...this. Remove parent parameter. Just call
1258 dump_nested_types_1 on an automatic bitmap.
1259 (dump_nested_type): Add dumped_types parameter.
1260 <ARRAY_TYPE>: Do not dump it if already present in dumped_types.
1261 Adjust recursive calls and adjust to above renaming.
1262 (dump_ada_declaration): Adjust call to dump_nested_types.
1263 Tidy up and adjust to above renaming.
1264 (dump_ada_specs): Initialize and release bitmap obstack.
1265
0cc575e4
MS
12662020-02-10 Martin Sebor <msebor@redhat.com>
1267
1268 PR c/93640
1269 * c-attribs.c (handle_access_attribute): Correct off-by-one mistakes.
1270
a59aa302
JJ
12712020-02-10 Jakub Jelinek <jakub@redhat.com>
1272
1273 PR other/93641
1274 * c-format.c (check_plain): Fix up last argument of strncasecmp.
1275 Remove useless extra test.
1276
e464fc90
TB
12772020-02-03 Julian Brown <julian@codesourcery.com>
1278 Tobias Burnus <tobias@codesourcery.com>
1279
1280 * c-cppbuiltin.c (c_cpp_builtins): Update _OPENACC define to 201711.
1281
e3b6c052
JM
12822020-01-29 Jason Merrill <jason@redhat.com>
1283
1284 PR c++/89357
1285 * c-attribs.c (check_cxx_fundamental_alignment_constraints): Remove.
1286
6d00f052
JM
12872020-01-23 Jason Merrill <jason@redhat.com>
1288
1289 * c-warn.c (conversion_warning): Change -Wsign-conversion handling.
1290
8a990ffa
MS
12912020-01-23 Martin Sebor <msebor@redhat.com>
1292
1293 PR c/84919
1294 * c-common.c (check_function_arguments): Avoid overlap checking
1295 of sprintf functions.
1296
55b7df8b
JM
12972020-01-22 Jason Merrill <jason@redhat.com>
1298
1299 PR testsuite/93391 - PR 40752 test fails with unsigned plain char.
1300 PR c++/40752
1301 * c-warn.c (conversion_warning): Check operands only after checking
1302 the whole expression. Don't check second operand of + for sign.
1303
c77074d0
JM
13042020-01-21 Jason Merrill <jason@redhat.com>
1305 Manuel López-Ibáñez <manu@gcc.gnu.org>
1306
1307 PR c++/40752 - useless -Wconversion with short +=.
1308 * c.opt (-Warith-conversion): New.
1309 * c-warn.c (conversion_warning): Recurse for operands of
1310 operators. Only warn about the whole expression with
1311 -Warith-conversion.
1312
731dbfc3
JM
13132020-01-21 Jason Merrill <jason@redhat.com>
1314
1315 * c-common.c (unsafe_conversion_p): Don't warn, return UNSAFE_SIGN.
1316 * c-warn.c (conversion_warning): Warn about UNSAFE_SIGN.
1317
ad1a3914
NS
13182020-01-20 Nathan Sidwell <nathan@acm.org>
1319
1320 PR preprocessor/80005
1321 * c-cppbuiltins.c (c_cpp_builtins): Don't define __has_include{,_next}.
1322
49789fd0
IS
13232020-01-18 Iain Sandoe <iain@sandoe.co.uk>
1324
1325 * c-common.c (co_await, co_yield, co_return): New.
1326 * c-common.h (RID_CO_AWAIT, RID_CO_YIELD,
1327 RID_CO_RETURN): New enumeration values.
1328 (D_CXX_COROUTINES): Bit to identify coroutines are active.
1329 (D_CXX_COROUTINES_FLAGS): Guard for coroutine keywords.
1330 * c-cppbuiltin.c (__cpp_coroutines): New cpp define.
1331 * c.opt (fcoroutines): New command-line switch.
1332
4bc1899b
DM
13332020-01-10 David Malcolm <dmalcolm@redhat.com>
1334
1335 * c-format.c (local_event_ptr_node): New.
1336 (PP_FORMAT_CHAR_TABLE): Add entry for "%@".
1337 (init_dynamic_diag_info): Initialize local_event_ptr_node.
1338 * c-format.h (T_EVENT_PTR): New define.
1339
f25e33fa
MS
13402020-01-10 Martin Sebor <msebor@redhat.com>
1341
1342 PR c/93132
1343 * c-attribs.c (append_access_attrs): Validate against the translated
1344 access string rather than the human-readable representation.
1345
8d9254fc
JJ
13462020-01-01 Jakub Jelinek <jakub@redhat.com>
1347
1348 Update copyright years.
1349
39292e25
EB
13502019-12-20 Eric Botcazou <ebotcazou@adacore.com>
1351
1352 * c-ada-spec.h (decl_sloc): Delete.
1353 * c-ada-spec.c (decl_sloc): Make static.
1354
519d7496
JB
13552019-12-19 Julian Brown <julian@codesourcery.com>
1356
1357 * c-common.h (c_omp_map_clause_name): Add prototype.
1358 * c-omp.c (c_omp_map_clause_name): New function.
1359 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ATTACH and
1360 PRAGMA_OACC_CLAUSE_DETACH.
1361
a6163563
JB
13622019-12-19 Julian Brown <julian@codesourcery.com>
1363 Maciej W. Rozycki <macro@codesourcery.com>
1364 Tobias Burnus <tobias@codesourcery.com>
1365 Thomas Schwinge <thomas@codesourcery.com>
1366
1367 * c-pragma.h (pragma_omp_clause): Add
1368 PRAGMA_OACC_CLAUSE_NO_CREATE.
1369
e8f1ade2
MS
13702019-12-17 Martin Sebor <msebor@redhat.com>
1371
1372 PR c++/61339
1373 * c.opt (-Wmismatched-tags, -Wredundant-tags): New options.
1374
368877a1
DM
13752019-12-11 David Malcolm <dmalcolm@redhat.com>
1376
1377 * c-pretty-print.c (c_pretty_printer::clone): New vfunc
1378 implementation.
1379 * c-pretty-print.h (c_pretty_printer::clone): New vfunc decl.
1380
d68f5d45
DM
13812019-12-09 David Malcolm <dmalcolm@redhat.com>
1382
1383 * c-format.c (range_label_for_format_type_mismatch::get_text):
1384 Replace label_text ctor called with true with label_text::take.
1385
d3e28653
DM
13862019-12-09 David Malcolm <dmalcolm@redhat.com>
1387
1388 * c-format.c (selftest::test_type_mismatch_range_labels): Remove
1389 initial newline from expected outputs.
1390 * c-opts.c (c_diagnostic_finalizer): Add pp_newline call before
1391 call to diagnostic_show_locus.
1392
abd6d8cc
JJ
13932019-12-06 Jakub Jelinek <jakub@redhat.com>
1394
1395 * c-cppbuiltin.c (c_cpp_builtins): Don't define __cpp_consteval for
1396 now.
1397
7906797e
MP
13982019-12-05 Marek Polacek <polacek@redhat.com>
1399 Jakub Jelinek <jakub@redhat.com>
1400
1401 PR c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.
1402 * c-cppbuiltin.c (c_cpp_builtins): Adjust the value of __cpp_constexpr.
1403
5c04da88
MP
14042019-12-05 Marek Polacek <polacek@redhat.com>
1405
1406 PR c++/92271 - make __is_same alias for __is_same_as.
1407 * c-common.c: Add __is_same, an alias for __is_same_as.
1408
43aae289
MP
14092019-12-03 Marek Polacek <polacek@redhat.com>
1410
1411 PR c++/91363 - P0960R3: Parenthesized initialization of aggregates.
1412 * c-cppbuiltin.c (c_cpp_builtins): Predefine
1413 __cpp_aggregate_paren_init=201902 for -std=c++2a.
1414
d7ddfbcb
JH
14152019-11-30 Jan Hubicka <hubicka@ucw.cz>
1416
1417 * c-attribs.c (handle_symver_attribute): New function
1418 (c_common_attributes): Add symver.
1419
65ef05d0
RS
14202019-11-30 Richard Sandiford <richard.sandiford@arm.com>
1421
1422 * c-common.c (pointer_int_sum): Use verify_type_context to check
1423 whether the target allows pointer arithmetic for the types involved.
1424 (c_sizeof_or_alignof_type, c_alignof_expr): Use verify_type_context
1425 to check whether the target allows sizeof and alignof operations
1426 for the types involved.
1427
1a291106
JM
14282019-11-27 Jason Merrill <jason@redhat.com>
1429
1430 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
1431
05d6cb1a
JJ
14322019-11-26 Jakub Jelinek <jakub@redhat.com>
1433
1434 PR c++/61414
1435 * c-attribs.c (handle_mode_attribute): Add mode attribute to
1436 ENUMERAL_TYPEs.
1437
5b8d9367
JM
14382019-11-25 Joseph Myers <joseph@codesourcery.com>
1439
1440 PR c/91985
1441 * c-common.c (c_common_type_for_mode): Handle decimal
1442 floating-point types being NULL_TREE.
1443 * c-format.c (get_format_for_type_1): Handle specified types being
1444 NULL_TREE.
1445 * c-lex.c (interpret_float): Give an error for decimal
1446 floating-point constants when decimal floating-point not
1447 supported.
1448
1fbf51cb
JJ
14492019-11-23 Jakub Jelinek <jakub@redhat.com>
1450
1451 PR middle-end/83859
1452 * c-attribs.c (append_access_attrs): Avoid buffer overflow. Avoid
1453 memory leak. Use XNEWVEC macro. Use auto_diagnostic_group to
1454 group warning with inform together.
1455 (handle_access_attribute): Formatting fix.
1456
761df906
JJ
14572019-11-22 Jakub Jelinek <jakub@redhat.com>
1458
bdaf8be1
JJ
1459 PR c/90677
1460 * c-common.h (identifier_global_tag): Declare.
1461 * c-format.c (get_pointer_to_named_type): Renamed to ...
1462 (get_named_type): ... this. Use identifier_global_tag instead of
1463 identifier_global_value, handle the return value being a TYPE_P.
1464 (init_dynamic_diag_info): Adjust get_pointer_to_named_type callers
1465 to call get_named_type instead. Formatting fixes.
1466
c2ecce6d 1467 Implement P1902R1, Missing feature-test macros 2017-2019.
761df906
JJ
1468 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_init_captures
1469 and __cpp_generic_lambdas for -std=c++2a. Define
1470 __cpp_designated_initializers, __cpp_constexpr_in_decltype and
1471 __cpp_consteval for -std=c++2a. Remove a FIXME comment about
1472 __cpp_concepts for -std=c++2a.
1473
54aa6b58
MS
14742019-11-22 Martin Sebor <msebor@redhat.com>
1475
1476 PR middle-end/83859
1477 * c-attribs.c (handle_access_attribute): New function.
1478 (c_common_attribute_table): Add new attribute.
1479 (get_argument_type): New function.
1480 (append_access_attrs): New function.
1481 (get_nonnull_operand): Rename...
1482 (get_attribute_operand): ...to this.
1483 * c-common.c (get_nonnull_operand): Rename...
1484 (get_attribute_operand): ...to this.
1485
6c80b1b5
JM
14862019-11-21 Joseph Myers <joseph@codesourcery.com>
1487
1488 * c-attribs.c (handle_fallthrough_attribute): Use pedwarn instead
1489 of warning.
1490
192961ff
JM
14912019-11-19 Joseph Myers <joseph@codesourcery.com>
1492
1493 * c-common.c (attribute_fallthrough_p): In C, use pedwarn not
1494 warning for standard attributes mixed with fallthrough attributes.
1495
f8aea5e3
JM
14962019-11-15 Joseph Myers <joseph@codesourcery.com>
1497
1498 * c-attribs.c (handle_fallthrough_attribute): Remove static.
1499 * c-common.h (handle_fallthrough_attribute): Declare.
1500
2cc94aa8
JM
15012019-11-15 Joseph Myers <joseph@codesourcery.com>
1502
1503 * c-attribs.c (handle_deprecated_attribute): Remove static.
1504 * c-common.h (handle_deprecated_attribute): Declare.
1505
7c5890cc
JM
15062019-11-14 Joseph Myers <joseph@codesourcery.com>
1507
1508 * c-lex.c (lex_charconst): Make CPP_UTF8CHAR constants unsigned
1509 char for C.
1510
b2417b59
JJ
15112019-11-14 Jakub Jelinek <jakub@redhat.com>
1512
d0ec7c93
JJ
1513 * c-omp.c (c_omp_check_context_selector): Add nvidia to the list of
1514 valid vendors.
1515
b2417b59
JJ
1516 * c-omp.c (c_omp_check_context_selector): Handle name lists
1517 containing string literals. Don't diagnose atomic_default_mem_order
1518 with multiple props.
1519
00be2a5f
JM
15202019-11-13 Joseph Myers <joseph@codesourcery.com>
1521
1522 * c-cppbuiltin.c (builtin_define_float_constants): Also define
1523 NORM_MAX constants. Update call to get_max_float.
1524 (LAZY_HEX_FP_VALUES_CNT): Update value to include NORM_MAX
1525 constants.
1526
2dbad62d
EB
15272019-11-13 Eric Botcazou <ebotcazou@adacore.com>
1528
1529 * c-ada-spec.c (get_underlying_decl): Do not look through typedefs.
1530 (dump_forward_type): Do not generate a declaration for function types.
1531 (dump_nested_type) <ARRAY_TYPE>: Do not generate a nested declaration
1532 of the component type if it is declared in another file.
1533
6ed76044
ML
15342019-11-12 Martin Liska <mliska@suse.cz>
1535
1536 * c-opts.c (c_common_post_options):
1537 Use SET_OPTION_IF_UNSET.
1538
62aee289
MR
15392019-11-12 Maciej W. Rozycki <macro@codesourcery.com>
1540 Frederik Harwath <frederik@codesourcery.com>
1541
1542 gcc/c-family/
1543 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_SERIAL enumeration
1544 constant.
1545 * c-pragma.c (oacc_pragmas): Add "serial" entry.
1546
f486280c
RS
15472019-11-08 Richard Sandiford <richard.sandiford@arm.com>
1548
1549 * c-common.h (gnu_vector_type_p): New function.
1550 * c-common.c (c_build_vec_perm_expr): Require __builtin_shuffle
1551 vectors to satisfy gnu_vector_type_p.
1552 (c_build_vec_convert): Likewise __builtin_convertvector.
1553 (convert_vector_to_array_for_subscript): Likewise when applying
1554 implicit vector to array conversion.
1555 (scalar_to_vector): Likewise when converting vector-scalar
1556 operations to vector-vector operations.
1557
017c6491
JM
15582019-11-08 Joseph Myers <joseph@codesourcery.com>
1559
1560 * c.opt (Wold-style-definition): Initialize to -1.
1561 * c-opts.c (c_common_post_options): Set warn_old_style_definition
1562 to flag_isoc2x if not set explicitly.
1563
c01bd174
JM
15642019-11-07 Joseph Myers <joseph@codesourcery.com>
1565
1566 * c-attribs.c (parse_tm_stmt_attr): Handle scoped attributes.
1567
0df65305
JM
15682019-11-05 Jason Merrill <jason@redhat.com>
1569
1570 * c-opts.c (c_common_post_options): -fconcepts-ts implies
1571 -fconcepts.
1572
e0c866dd
KK
15732019-11-04 Kamlesh Kumar <kamleshbhalui@gmail.com>
1574
1575 * c-opts.c (c_common_post_options): Update
1576 latest_abi_version.
1577
f968ef9b
JJ
15782019-11-02 Jakub Jelinek <jakub@redhat.com>
1579
d0c464d2
JJ
1580 * c-common.h (c_omp_get_context_selector): Remove.
1581 * c-omp.c (c_omp_get_context_selector): Moved to omp-general.c
1582 and renamed to omp_get_context_selector.
1583
917dd789
JJ
1584 * c-omp.c (c_omp_mark_declare_variant): Use
1585 omp_context_selector_set_compare.
1586
f968ef9b
JJ
1587 PR c++/88335 - Implement P1073R3: Immediate functions
1588 * c-common.h (enum rid): Add RID_CONSTEVAL.
1589 * c-common.c (c_common_reswords): Add consteval.
1590
5f6705b7
JJ
15912019-11-01 Martin Sebor <msebor@redhat.com>
1592
1593 PR middle-end/91679
1594 PR middle-end/91647
1595 PR middle-end/91463
1596 PR middle-end/92312
1597 * c-pretty-print.c (direct_abstract_declarator): Print
1598 bound in zero-length arrays.
1599 * c.opt (-Wzero-length-bounds): New option.
1600
43f1814c
NS
16012019-10-30 Nathan Sidwell <nathan@acm.org>
1602
1603 * c-cppbuiltin.c (c_cpp_builtins): Add 'L' suffix to feature
1604 macros.
1605
ad1539d5
MS
16062019-10-28 Martin Sebor <msebor@redhat.com>
1607
1608 PR c/66970
1609 * c-common.c (c_common_nodes_and_builtins): Call c_define_builtins
1610 even when only preprocessing.
1611 * c-common.h (names_builtin_p): Declare new function.
1612 * c-lex.c (init_c_lex): Set has_builtin.
1613 (c_common_has_builtin): Define a new function.
1614 * c-ppoutput.c (init_pp_output): Set has_builtin.
1615
135df52c
JJ
16162019-10-24 Jakub Jelinek <jakub@redhat.com>
1617
1618 * c-common.h (c_omp_context_selector_matches): Remove.
1619 * c-omp.c (c_omp_context_selector_matches): Remove.
1620 * c-attribs.c (c_common_attribute_table): Add
1621 "omp declare target {host,nohost,block}" attributes.
1622
8ad0c477
JM
16232019-10-17 JeanHeyd Meneide <phdofthehouse@gmail.com>
1624
1625 * c-lex.c (c_common_has_attribute): Update nodiscard value.
1626
56898e43
RS
16272019-10-14 Richard Sandiford <richard.sandiford@arm.com>
1628
1629 * c-common.h (user_facing_original_type_p): Declare.
1630 * c-common.c: Include c-spellcheck.h.
1631 (user_facing_original_type_p): New function.
1632
20de9568
JJ
16332019-10-12 Jakub Jelinek <jakub@redhat.com>
1634
1635 * c-common.h (c_omp_mark_declare_variant,
1636 c_omp_context_selector_matches): Declare.
1637 * c-omp.c: Include attribs.h, gimplify.h, cgraph.h, symbol-summary.h
1638 and hsa-common.h.
1639 (c_omp_get_context_selector): Support second argument NULL.
1640 (c_omp_mark_declare_variant, c_omp_context_selector_matches): New
1641 functions.
1642 * c-attribs.c (c_common_attribute_table): Remove "omp declare variant"
1643 attribute, add "omp declare variant base" and
1644 "omp declare variant variant" attributes.
1645
175a85b2
JM
16462019-10-11 Joseph Myers <joseph@codesourcery.com>
1647
1648 * c.opt (Wc11-c2x-compat): Add CPP(cpp_warn_c11_c2x_compat)
1649 CppReason(CPP_W_C11_C2X_COMPAT).
1650
fe2bc27c
JM
16512019-10-11 Joseph Myers <joseph@codesourcery.com>
1652
1653 * c-common.c (c_common_reswords): Do not use D_EXT for _Decimal32,
1654 _Decimal64 and _Decimal128.
1655
27dfdc0f
JM
16562019-10-10 Joseph Myers <joseph@codesourcery.com>
1657
1658 * c-cppbuiltin.c (c_cpp_builtins): Do not define macros for DFP
1659 types if DFP not supported.
1660
94e7f906
JJ
16612019-10-10 Jakub Jelinek <jakub@redhat.com>
1662
1663 * c-common.h (c_omp_check_context_selector,
1664 c_omp_get_context_selector): Declare.
1665 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): Fix spelling
1666 in diagnostic message.
1667 (c_omp_check_context_selector, c_omp_get_context_selector): New
1668 functions.
1669 * c-attribs.c (c_common_attribute_table): Add "omp declare variant"
1670 attribute.
1671 (handle_omp_declare_variant_attribute): New function.
1672
a7160771
MS
16732019-10-09 Martin Sebor <msebor@redhat.com>
1674
1675 PR tree-optimization/90879
1676 * c.opt (-Wstring-compare): New option.
1677
cb57504a
JM
16782019-10-08 Andrew Sutton <asutton@lock3software.com>
1679 Jason Merrill <jason@redhat.com>
1680
1681 Update the concepts implementation to conform to the C++20
1682 specification, improve compile times, and generally clean up
1683 the implementation.
1684
1685 * c-cppbuiltin.c (c_cpp_builtins): Use new feature test values for
1686 concepts when -std=c++2a. Bump __cpp_concepts to 201907.
1687 * c.opt: Add -Wconcepts-ts.
1688 * c-opts.c (c_common_post_options): Warn when -fconcepts is used
1689 with -std=c++2a. Disable warning for -fconcepts in C++20 mode.
1690 (set_std_cxx2a): Enable concepts by default.
1691
fbb2a6dc
JM
16922019-10-08 Joseph Myers <joseph@codesourcery.com>
1693
1694 * c-opts.c (c_common_post_options): Set
1695 -fno-fp-int-builtin-inexact for C2X.
1696
8e007055
JJ
16972019-10-05 Jakub Jelinek <jakub@redhat.com>
1698
1699 PR c++/91369 - Implement P0784R7: constexpr new
1700 * c-cppbuiltin.c (c_cpp_builtins): Predefine
1701 __cpp_constexpr_dynamic_alloc=201907 for -std=c++2a.
1702
843f104d
JM
17032019-10-04 Joseph Myers <joseph@codesourcery.com>
1704
1705 PR c/82752
1706 * c-format.c (C_STD_VER): Handle C2x.
1707 (C_STD_NAME): Likewise.
1708 (strftime_flag_specs): Add 'O' modifier with 'p' flag.
1709 (time_char_table): Use separate entry for 'B' and 'b', with 'O'
1710 modifier allowed and 'p' flag.
1711 * c-format.h (enum format_std_version): Add STD_C2X.
1712 (struct format_char_info): Mention 'p' in comment on flags2.
1713
e9c9a142
DM
17142019-10-01 David Malcolm <dmalcolm@redhat.com>
1715
1716 * c-opts.c (c_diagnostic_finalizer): Temporarily clear prefix when
1717 calling diagnostic_show_locus, rather than destroying it afterwards.
1718
7552c36a
JJ
17192019-10-01 Jakub Jelinek <jakub@redhat.com>
1720
1721 PR c++/91925
1722 * c-warn.c (check_alignment_of_packed_member): Ignore FIELD_DECLs
1723 with NULL DECL_FIELD_OFFSET.
1724
8209db25
RS
17252019-10-01 Richard Sandiford <richard.sandiford@arm.com>
1726
1727 * c-pretty-print.c (pp_c_specifier_qualifier_list): If a vector type
1728 has a type name, use it in preference to the __vector syntax.
1729
9343bf99
RS
17302019-09-30 Richard Sandiford <richard.sandiford@arm.com>
1731
1732 * c-pretty-print.c (pp_c_parameter_type_list): Avoid printing
1733 two spaces between a comma and "...".
1734
59bc434a
JJ
17352019-09-27 Jakub Jelinek <jakub@redhat.com>
1736
1737 PR c++/88203
1738 * c-common.h (c_omp_predefined_variable): Declare.
1739 * c-omp.c (c_omp_predefined_variable): New function.
1740 (c_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
1741 for predefined variables.
1742
c6447c20
RS
17432019-09-27 Richard Sandiford <richard.sandiford@arm.com>
1744
1745 * c-common.h (build_function_call_vec): Take the original
1746 function decl as an optional final parameter.
1747 (check_builtin_function_arguments): Take the original function decl.
1748 * c-common.c (check_builtin_function_arguments): Likewise.
1749 Handle all built-in functions, not just BUILT_IN_NORMAL ones.
1750 Use targetm.check_builtin_call to check BUILT_IN_MD functions.
1751
c4438114
JM
17522019-09-15 Jason Merrill <jason@redhat.com>
1753
1754 * c-warn.c (warn_logical_operator): Strip location wrappers. Don't
1755 fold_for_warn in "|| mask" warning.
1756
68a57628
ML
17572019-09-10 Martin Liska <mliska@suse.cz>
1758
1759 * c.opt: Use newly added WarnRemoved.
1760
f48ef52e
ML
17612019-09-09 Martin Liska <mliska@suse.cz>
1762
1763 * c.opt: Update comment of removed
1764 options that are preserved only for backward
1765 compatibility.
1766
67f6e649
ML
17672019-09-06 Martin Liska <mliska@suse.cz>
1768
1769 PR c++/91125
1770 * c-common.c: Remove definition of flag_use_repository.
1771 * c-common.h: Likewise.
1772 * c-opts.c (c_common_handle_option):
1773 Do not handle OPT_frepo option.
1774 * c.opt: Mark the option with Deprecated.
1775
db9d2274
MP
17762019-09-04 Marek Polacek <polacek@redhat.com>
1777
1778 * c.opt (fdeduce-init-list): Ignored.
1779
68e2c199
PK
17802019-09-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1781
1782 PR c/78736
1783 * c.opt (Wenum-conversion): New option.
1784
7a4418a5
JL
17852019-09-03 Jozef Lawrynowicz <jozef.l@mittosystems.com>
1786
1787 * c-attribs.c (handle_section_attribute): Call the
1788 handle_generic_attribute target hook after performing target
1789 independent processing.
1790 (handle_noinit_attribute): Likewise.
1791
5f76ab15
ILT
17922019-09-03 Ian Lance Taylor <iant@golang.org>
1793
1794 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Always expand
1795 when using -fgo-dump-spec.
1796
ae0d3f6a
ML
17972019-09-02 Martin Liska <mliska@suse.cz>
1798
1799 PR c++/91155
1800 * c-common.c (fname_as_string): Use cxx_printable_name for
1801 __PRETTY_FUNCTION__ same as was used before r265711.
1802
8a902edb
MP
18032019-08-28 Marek Polacek <polacek@redhat.com>
1804
1805 Implement P1152R4: Deprecating some uses of volatile.
1806 PR c++/91361
1807 * c-opts.c (c_common_post_options): Enable -Wvolatile by
1808 default for C++2a, unless -Wno-deprecated.
1809 * c.opt (Wvolatile): New warning.
1810
4742dbe7
MP
18112019-08-28 Marek Polacek <polacek@redhat.com>
1812
1813 PR c++/91360 - Implement C++20 P1143R2: constinit.
1814 * c-common.c (c_common_reswords): Add constinit and __constinit.
1815 (keyword_is_decl_specifier): Handle RID_CONSTINIT.
1816 * c-common.h (enum rid): Add RID_CONSTINIT, RID_FIRST_CXX20, and
1817 RID_LAST_CXX20.
1818 (D_CXX20): Define.
1819 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_constinit.
1820 * c-format.c (cxx_keywords): Add "constinit".
1821 * c.opt (Wc++2a-compat, Wc++20-compat): New options.
1822
6a074892
JJ
18232019-08-27 Jakub Jelinek <jakub@redhat.com>
1824
1825 PR c++/91415
1826 * c-common.c (verify_tree): For LSHIFT_EXPR, RSHIFT_EXPR,
1827 COMPONENT_REF and ARRAY_REF in cxx_dialect >= cxx17 mode handle it
1828 like COMPOUND_EXPR rather than normal expression.
1829
22f8849d
IS
18302019-08-23 Iain Sandoe <iain@sandoe.co.uk>
1831
1832 PR pch/61250
1833 * c-lex.c (c_lex_with_flags): Don't call
1834 c_common_no_more_pch () from here.
1835
df375b03
JJ
18362019-08-23 Jakub Jelinek <jakub@redhat.com>
1837
1838 PR middle-end/91283
1839 * c-common.c (c_ts18661_flt_eval_method): Use flag_excess_precision
1840 instead of flag_excess_precision_cmdline.
1841 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): Likewise.
1842 * c-opts.c (c_common_post_options): Likewise.
1843
14b7950f
MS
18442019-08-22 Martin Sebor <msebor@redhat.com>
1845
1846 PR middle-end/91490
1847 * c-common.c (braced_list_to_string): Add argument and overload.
1848 Handle flexible length arrays and unions.
1849
8bb2ee59
EB
18502019-08-21 Eric Botcazou <ebotcazou@adacore.com>
1851
1852 * c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
1853 function declarations where arguments are missing. Rename variables.
1854
21c1e205
RB
18552019-08-15 Richard Biener <rguenther@suse.de>
1856
1857 * c-common.c (c_stddef_cpp_builtins): When the GIMPLE FE is
1858 enabled, define __SIZETYPE__.
1859
f0033821
CL
18602019-08-14 Christophe Lyon <christophe.lyon@linaro.org>
1861
1862 * c-attribs.c (c_common_attribute_table): Add "noinit" entry. Add
1863 exclusion with "section" attribute.
1864 (attr_noinit_exclusions): New table.
1865 (handle_noinit_attribute): New function.
1866
4d732405
RS
18672019-08-13 Richard Sandiford <richard.sandiford@arm.com>
1868
1869 PR middle-end/91421
1870 * c-common.c (resolve_overloaded_builtin): Use
1871 copy_decl_built_in_function.
1872
51ad8481
MS
18732019-08-13 Martin Sebor <msebor@redhat.com>
1874
1875 PR c/80619
1876 * c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
1877 (asm_fprintf_length_spec): Same.
1878 * c-format.h (format_lengths): Add FMT_LEN_w.
1879
77eb117f
JJ
18802019-08-10 Jakub Jelinek <jakub@redhat.com>
1881
1882 * c-pragma.h (enum pragma_omp_clause): Add
1883 PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
1884
398e3feb
JJ
18852019-08-07 Jakub Jelinek <jakub@redhat.com>
1886
1887 * c-pragma.h (enum pragma_omp_clause): Add
1888 PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. Set PRAGMA_OACC_CLAUSE_USE_DEVICE
1889 equal to PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR instead of being a separate
1890 enumeration value.
1891
ab574db6
MP
18922019-08-05 Marek Polacek <polacek@redhat.com>
1893
1894 PR c++/91338 - Implement P1161R3: Deprecate a[b,c].
1895 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
1896 default for C++2a, unless -Wno-deprecated.
1897 * c.opt (Wcomma-subscript): New warning.
1898
554a530f
JJ
18992019-07-20 Jakub Jelinek <jakub@redhat.com>
1900
1901 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_LOOP.
1902 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_BIND.
1903 * c-pragma.c (omp_pragmas_simd): Add PRAGMA_OMP_LOOP entry.
1904 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_LOOP.
1905 * c-omp.c (c_omp_split_clauses): Add support for 4 new combined
1906 constructs with the loop construct.
1907
1a888209
JJ
19082019-07-13 Jakub Jelinek <jakub@redhat.com>
1909
1910 PR c/91149
1911 * c-omp.c (c_omp_split_clauses): Fix a pasto in
1912 OMP_CLAUSE_REDUCTION_TASK handling.
1913
1fdd6f04
JJ
19142019-07-12 Jakub Jelinek <jakub@redhat.com>
1915
1916 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ORDER.
1917 * c-omp.c (c_omp_split_clauses): Handle splitting of OMP_CLAUSE_ORDER.
1918
99b1c316
MS
19192019-07-09 Martin Sebor <msebor@redhat.com>
1920
1921 PR c++/61339
1fdd6f04 1922 * c-opts.c (handle_deferred_opts): Change class-key of PODs to struct
99b1c316
MS
1923 and others to class.
1924 * c-pretty-print.h: Same.
1925
6c1dae73
MS
19262019-07-09 Martin Sebor <msebor@redhat.com>
1927
1928 PR c++/61339
1929 * c-format.c (check_argument_type): Change class-key from class to
1930 struct and vice versa to match convention and avoid -Wclass-is-pod
1931 and -Wstruct-no-pod.
1932 * c-pretty-print.h: Same.
1933
8ba6ea87
ML
19342019-07-03 Martin Liska <mliska@suse.cz>
1935
1936 * c-common.c (try_to_locate_new_include_insertion_point): Remove
1937 dead assignemts.
1938
83eb9522
JJ
19392019-07-03 Jakub Jelinek <jakub@redhat.com>
1940
1941 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_REDUCTION_INSCAN
1942 clauses on OMP_FOR rather than OMP_PARALLEL when OMP_FOR is combined
1943 with OMP_PARALLEL.
1944
1c6ffbab
QZ
19452019-07-02 qing zhao <qing.zhao@oracle.com>
1946
1947 PR preprocessor/90581
1948 * c-opts.c (c_common_handle_option): Handle -fmax-include-depth.
1949 * c.opt: Add new option -fmax-include-depth.
1950
7ffc7de5
JM
19512019-06-26 Jason Merrill <jason@redhat.com>
1952
1953 PR c++/55442 - memory-hog with highly recursive constexpr.
1954 * c.opt (fconstexpr-loop-limit): New.
1955
361af3e4
JJ
19562019-06-25 Jakub Jelinek <jakub@redhat.com>
1957
1958 PR sanitizer/90954
1959 * c-omp.c (c_finish_omp_atomic): Allow tree_invariant_p in addition
1960 to SAVE_EXPR in first operand of a COMPOUND_EXPR.
1961
ab20d992
JJ
19622019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
1963
1964 * c-common.c (c_common_nodes_and_builtins): Define
1965 alternate "__intN__" name for "__intN" types.
1966
f4af4019
JH
19672019-06-24 Jan Hubicka <jh@suse.cz>
1968
1969 * c-common.c (braced_lists_to_strings): Check that
1970 type is array or integer prior checking string flag.
1971
da9e9b57
MB
19722019-06-21 Matthew Beliveau <mbelivea@redhat.com>
1973
1974 PR c++/90875 - added -Wswitch-outside-range option
1975 * c.opt (Wswitch-outside-range): Added new option.
1976 * c-warn.c (c_do_switch_warnings): Use OPT_Wswitch-outside-range.
1977
3f3d6a6f
MP
19782019-06-21 Marek Polacek <polacek@redhat.com>
1979
1980 PR c++/90953 - ICE with -Wmissing-format-attribute.
1981 * c-common.c (check_function_arguments_recurse): Use
1982 get_attribute_name.
1983 (check_missing_format_attribute): Likewise.
1984
1bf32c11
MP
19852019-06-19 Marek Polacek <polacek@redhat.com>
1986
1987 PR c++/60364 - noreturn after first decl not diagnosed.
1988 * c-attribs.c (handle_noreturn_attribute): No longer static.
1989 * c-common.h (handle_noreturn_attribute, attr_noreturn_exclusions):
1990 Declare.
1991 * c-format.c (check_function_format): Use get_attribute_name.
1992
a04c0734
MS
19932019-06-19 Martin Sebor <msebor@redhat.com>
1994
1995 PR translation/90156
1996 * c-format.c (function_format_info::format_type): Adjust type.
1997 (function_format_info::is_raw): New member.
1998 (decode_format_type): Adjust signature. Handle "raw" diag attributes.
1999 (decode_format_attr): Adjust call to decode_format_type.
2000 Avoid a redundant call to convert_format_name_to_system_name.
2001 Avoid abbreviating the word "arguments" in a diagnostic.
2002 (format_warning_substr): New function.
2003 (avoid_dollar_number): Quote dollar sign in a diagnostic.
2004 (finish_dollar_format_checking): Same.
2005 (check_format_info): Same.
2006 (struct baltoks_t): New.
2007 (c_opers, c_keywords, cxx_keywords, badwords, contrs): New arrays.
2008 (maybe_diag_unbalanced_tokens, check_tokens, check_plain): New
2009 functions.
2010 (check_format_info_main): Call check_plain. Use baltoks_t. Call
2011 maybe_diag_unbalanced_tokens.
2012 (handle_format_attribute): Spell out the word "arguments" in
2013 a diagnostic.
2014
d3786ebb
MB
20152019-06-11 Matthew Beliveau <mbelivea@redhat.com>
2016
2017 PR c++/90449 - add -Winaccessible-base option.
2018 * c.opt (Winaccessible-base): New option.
2019
bf38f7e9
JJ
20202019-06-10 Jakub Jelinek <jakub@redhat.com>
2021
2022 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCAN.
2023 * c-pragma.c (omp_pragmas_simd): Add #pragma omp scan.
2024 * c-omp.c (c_omp_split_clauses): Diagnose inscan reductions on
2025 combined/composite constructs where it is not allowed. Copy over
2026 OMP_CLAUSE_REDUCTION_INSCAN.
2027
0ecf545c
MS
20282019-06-05 Martin Sebor <msebor@redhat.com>
2029
2030 * c-attribs.c (handle_mode_attribute): Adjust quoting and hyphenation.
2031 (handle_alias_ifunc_attribute): Same.
2032 (handle_copy_attribute): Same.
2033 (handle_weakref_attribute): Same.
2034 (handle_nonnull_attribute): Same.
2035 * c-warn.c (warn_for_sign_compare): Same.
2036 (warn_for_restrict): Same.
2037 * c.opt: Same.
2038
36b34127
MS
20392019-06-05 Martin Sebor <msebor@redhat.com>
2040
2041 * c-pragma.c (handle_pragma_weak): Adjust quoting in a diagnostic.
2042 * c.opt (-Wformat-diag): Remove a spurious period.
2043
357a352f
JJ
20442019-05-29 Jakub Jelinek <jakub@redhat.com>
2045
2046 PR c/90628
2047 * c-common.c (check_builtin_function_arguments)
2048 <case BUILTIN_*_OVERFLOW>: Diagnose pointer to const qualified integer
2049 as last argument.
2050
2b8235ea
EB
20512019-05-23 Eric Botcazou <ebotcazou@adacore.com>
2052
2053 * c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
2054
6d86ddc4
ML
20552019-05-22 Martin Liska <mliska@suse.cz>
2056
2057 PR lto/90500
2058 * c-attribs.c (handle_copy_attribute): Do not copy
2059 target_clones attribute.
2060
419ba5b9
EB
20612019-05-21 Eric Botcazou <ebotcazou@adacore.com>
2062
2063 * c-ada-spec.h (enum cpp_operation): Add IS_ASSIGNMENT_OPERATOR.
2064 * c-ada-spec.c (print_assignment_operator): New function.
2065 (dump_ada_declaration) <FUNCTION_DECL>: Call it do dump explicit copy
2066 assignment operators declared as methods and filter out the others.
2067
e03436e7
TS
20682019-05-17 Thomas Schwinge <thomas@codesourcery.com>
2069
2070 PR c/89433
2071 * c-attribs.c (c_common_attribute_table): Set min_len to -1 for
2072 "omp declare target".
2073
a9c697b8
MS
20742019-05-16 Martin Sebor <msebor@redhat.com>
2075
ab20d992
JJ
2076 * c-attribs.c (handle_no_sanitize_attribute): Quote identifiers,
2077 keywords, operators, and types in diagnostics.
2078 (handle_scalar_storage_order_attribute): Same.
2079 (handle_mode_attribute): Same.
2080 (handle_visibility_attribute): Same.
2081 (handle_assume_aligned_attribute): Same.
2082 (handle_no_split_stack_attribute): Same.
2083 * c-common.c (shorten_compare): Same.
2084 (c_common_truthvalue_conversion): Same.
2085 (cb_get_source_date_epoch): Same.
2086 * c-lex.c (cb_def_pragma): Quote keywords, operators, and types
2087 in diagnostics.
2088 (interpret_float): Same.
2089 * c-omp.c (c_finish_omp_for): Same.
2090 * c-opts.c (c_common_post_options): Same.
2091 * c-pch.c (c_common_pch_pragma): Same.
2092 * c-pragma.c (pop_alignment): Same.
2093 (handle_pragma_pack): Same.
2094 (apply_pragma_weak): Same.
2095 (handle_pragma_weak): Same.
2096 (handle_pragma_scalar_storage_order): Same.
2097 (handle_pragma_redefine_extname): Same.
2098 (add_to_renaming_pragma_list): Same.
2099 (maybe_apply_renaming_pragma): Same.
2100 (push_visibility): Same.
2101 (handle_pragma_visibility): Same.
2102 (handle_pragma_optimize): Same.
2103 (handle_pragma_message): Same.
2104 * c-warn.c (warn_for_omitted_condop): Same.
2105 (lvalue_error): Same.
a9c697b8 2106
6b943512
RB
21072019-05-15 Richard Biener <rguenther@suse.de>
2108
2109 PR c/90474
2110 * c-common.c (c_common_mark_addressable_vec): Also mark
2111 a COMPOUND_LITERAL_EXPR_DECL addressable similar to
2112 c_mark_addressable.
ab20d992 2113
b744fc85
NS
21142019-05-06 Nathan Sidwell <nathan@acm.org>
2115
2116 * c-opts.c (handle_defered_opts): Rename struct deps to struc mkdeps.
2117
598f50d7
NS
21182019-04-30 Nathan Sidwell <nathan@acm.org>
2119
2120 * c-common.c (c_common_init_ts): Use MARK_TS_EXP. Mark SIZEOF_EXPR.
2121
5bcc5a3b
ML
21222019-04-30 Martin Liska <mliska@suse.cz>
2123
2124 * c-pragma.c (handle_pragma_diagnostic): Provide hints
2125 for unknown options.
2126
e78a87f7
RS
21272019-04-26 Richard Sandiford <richard.sandiford@arm.com>
2128
2129 * c-warn.c (strict_aliasing_warning): Apply COMPLETE_TYPE_P to
2130 the pointer target rather than the pointer itself.
2131
c280b7ee
JJ
21322019-04-19 Jakub Jelinek <jakub@redhat.com>
2133
2134 PR c/89888
2135 * c-common.h (c_add_case_label): Remove orig_type and outside_range_p
2136 arguments.
2137 (c_do_switch_warnings): Remove outside_range_p argument.
2138 * c-common.c (check_case_bounds): Removed.
2139 (c_add_case_label): Remove orig_type and outside_range_p arguments.
2140 Don't call check_case_bounds. Fold low_value as well as high_value.
2141 * c-warn.c (c_do_switch_warnings): Remove outside_range_p argument.
2142 Check for case labels outside of range of original type here and
2143 adjust them.
2144
8e8225e6
JJ
21452019-04-12 Jakub Jelinek <jakub@redhat.com>
2146
63b8a166
JJ
2147 PR translation/90041
2148 * c.opt (-fhandle-exceptions): Use %< and %> around option names
2149 in the Warn diagnostics.
2150
8e8225e6
JJ
2151 PR c/89946
2152 * c-attribs.c (handle_patchable_function_entry_attribute): Add
2153 function comment. Warn if arguments of the attribute are not positive
2154 integer constants.
2155
53a3f614
EB
21562019-04-09 Eric Botcazou <ebotcazou@adacore.com>
2157
2158 * c-ada-spec.c (print_destructor): Deal with deleting destructors.
2159 (dump_ada_declaration) <FUNCTION_DECL>: Likewise.
2160
22be5873
EB
21612019-04-07 Eric Botcazou <ebotcazou@adacore.com>
2162
2163 * c-ada-spec.c (is_float128): New predicate extracted from...
2164 (dump_ada_node) <COMPLEX_TYPE>: Use it to recognize __cfloat128.
2165 <REAL_TYPE>: ...here. Call it.
2166
34facf20
DM
21672019-04-05 David Malcolm <dmalcolm@redhat.com>
2168
2169 PR c/89985
2170 * c-warn.c (check_address_or_pointer_of_packed_member): Add
2171 auto_diagnostic_group. Guard inform calls by result of
2172 warning_at call.
2173
05564120
MP
21742019-04-05 Marek Polacek <polacek@redhat.com>
2175
ab20d992 2176 PR c++/89973 - -Waddress-of-packed-member ICE with invalid conversion.
05564120
MP
2177 * c-warn.c (check_address_or_pointer_of_packed_member): Check the type
2178 of RHS.
2179
7a506c3c
JM
21802019-04-03 Jason Merrill <jason@redhat.com>
2181
2182 PR c++/86586 - -fcompare-debug=-Wsign-compare.
2183 * c-warn.c (warn_for_sign_compare): Call fold_for_warn.
2184
ddeae8c8
MS
21852019-04-01 Martin Sebor <msebor@redhat.com>
2186
2187 PR c/89685
2188 * c-attribs.c (handle_copy_attribute): Handle references and
2189 non-constant expressions.
2190
a15ffa22
JJ
21912019-03-22 Jakub Jelinek <jakub@redhat.com>
2192
2193 PR c++/87481
2194 * c.opt (-fconstexpr-ops-limit=): New option.
2195
36a3a7a3
JJ
21962019-03-21 Jakub Jelinek <jakub@redhat.com>
2197
2198 * c-common.c (per_file_includes_t): Use false as Lazy in hash_set
2199 template param.
2200
bec1da64
MS
22012019-03-19 Martin Sebor <msebor@redhat.com>
2202
2203 PR tree-optimization/89688
2204 * c-common.c (braced_list_to_string): Make static.
2205 (braced_lists_to_strings): Define new function.
2206 * c-common.h (braced_list_to_string): Remove.
2207 (braced_lists_to_strings): Declare.
2208
1fe61adf
ML
22092019-03-12 Martin Liska <mliska@suse.cz>
2210
2211 * c-opts.c (c_common_handle_option): Wrap option with %< and %>.
2212
93964ebd
ML
22132019-03-11 Martin Liska <mliska@suse.cz>
2214
2215 * c-opts.c (c_common_post_options): Wrap apostrophes
2216 in gcc internal format with %'.
2217
a3f9f006
ML
22182019-03-11 Martin Liska <mliska@suse.cz>
2219
2220 * c-attribs.c (handle_nocf_check_attribute): Wrap an option name
2221 in a string format message and fix GNU coding style.
2222 * c-common.c (vector_types_convertible_p): Likewise.
2223 (c_build_vec_perm_expr): Likewise.
2224 * c-indentation.c (get_visual_column): Likewise.
2225 * c-opts.c (c_common_handle_option): Likewise.
2226 (c_common_post_options): Likewise.
2227 (sanitize_cpp_opts): Likewise.
2228 * c-pch.c (c_common_pch_pragma): Likewise.
2229 * c-pragma.c (handle_pragma_pack): Likewise.
2230
1db01ff9
JJ
22312019-03-08 Jakub Jelinek <jakub@redhat.com>
2232
2233 PR tree-optimization/89550
2234 * c-common.c (c_common_truthvalue_conversion): Only set
2235 TREE_NO_WARNING if warning_at returned true.
2236 * c-warn.c (overflow_warning, warn_logical_operator): Likewise.
2237
ba790e6f
JJ
22382019-02-25 Sandra Loosemore <sandra@codesourcery.com>
2239 Martin Sebor <msebor@gmail.com>
2240
2241 * c.opt (Wmissing-attributes): Clean up doc string.
2242
7da73ba7
JJ
22432019-02-25 Jakub Jelinek <jakub@redhat.com>
2244
2245 PR c/89495
2246 * c-format.c (maybe_read_dollar_number): Compute nargnum in
2247 HOST_WIDE_INT type to avoid overflows and change overflow_flag
2248 checking.
2249
921bb9d1
RB
22502019-02-22 Richard Biener <rguenther@suse.de>
2251
2252 * c-pch.c (no_checksum): Remove.
2253 (pch_init): Remove assertion that executable_checksum is not
2254 all zero.
2255 (c_common_valid_pch): Likewise.
2256
e2ebb05c
MS
22572019-02-18 Martin Sebor <msebor@redhat.com>
2258
2259 PR middle-end/89294
2260 * c-common.c (invalid_array_size_error): Handle cst_size_not_constant.
2261
3fe53000
DM
22622019-02-16 David Malcolm <dmalcolm@redhat.com>
2263
2264 PR c++/88680
2265 * c-common.c (shorten_compare): Call fold_for_warn on op0 when
2266 implementing -Wtype-limits.
2267
28a8cef1
MS
22682019-02-11 Martin Sebor <msebor@redhat.com>
2269
2270 PR c++/87996
2271 * c-common.c (invalid_array_size_error): New function.
2272 (valid_array_size_p): Call it. Handle size as well as type.
2273 * c-common.h (valid_constant_size_p): New function.
2274 (enum cst_size_error): New type.
2275
ec2be203
DM
22762019-01-31 David Malcolm <dmalcolm@redhat.com>
2277
2278 PR c/89122
2279 * known-headers.cc (get_stdlib_header_for_name): Add
2280 {FLT|DBL|LDBL}_{MAX|MIN} to "hints" array.
2281
8936f047
JJ
22822019-01-31 Jakub Jelinek <jakub@redhat.com>
2283
2284 PR libstdc++/88170
2285 * c-pretty-print.c (pp_c_enumeration_constant): Print always as
2286 a C cast in pp_c_flag_gnu_v3 mode.
2287
6a335b96
JJ
22882019-01-29 Jakub Jelinek <jakub@redhat.com>
2289
2290 PR c/86125
2291 * c-common.c (c_common_nodes_and_builtins): Build type variants for
2292 builtin_structptr_types types even for C.
2293
2a06eba5
BE
22942019-01-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
2295
2296 * c-warn.c (check_address_or_pointer_of_packed_member): Handle the case
2297 when rhs is of array type correctly. Fix handling of nested structures.
2298 Fix handling of indirect_ref together with nop_expr and/or addr_expr.
2299 (check_and_warn_address_or_pointer_of_packed_member): Fix handling of
2300 type casts within nested compound expressions.
2301
18a23298
JJ
23022019-01-22 Jakub Jelinek <jakub@redhat.com>
2303
2304 PR middle-end/88968
2305 * c-omp.c (c_finish_omp_atomic): For bitfield atomics, update type
2306 variable after using BIT_FIELD_REF.
2307
420183d9
L
23082019-01-18 H.J. Lu <hongjiu.lu@intel.com>
2309
2310 PR c/51628
2311 PR c/88664
2312 * c-common.h (warn_for_address_or_pointer_of_packed_member):
2313 Remove the boolean argument.
2314 * c-warn.c (check_address_of_packed_member): Renamed to ...
2315 (check_address_or_pointer_of_packed_member): This. Also
2316 warn pointer conversion.
2317 (check_and_warn_address_of_packed_member): Renamed to ...
2318 (check_and_warn_address_or_pointer_of_packed_member): This.
2319 Also warn pointer conversion.
2320 (warn_for_address_or_pointer_of_packed_member): Remove the
2321 boolean argument. Don't check pointer conversion here.
2322
99063eee
RS
23232019-01-15 Richard Sandiford <richard.sandiford@arm.com>
2324
2325 PR inline-asm/52813
2326 * c.opt (Wdeprecated): Move documentation and variable to common.opt.
2327
a30d0196
JJ
23282019-01-14 Jakub Jelinek <jakub@redhat.com>
2329
2330 * c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
2331 and __cpp_nontype_template_parameter_auto. Add a comment that
2332 __cpp_template_auto is deprecated.
2333
2d91f79d
TH
23342019-01-14 Tom Honermann <tom@honermann.net>
2335
2336 Implement P0482R5, char8_t: A type for UTF-8 characters and strings
2337 * c-common.c (c_common_reswords): Add char8_t.
2338 (fix_string_type): Use char8_t for the type of u8 string literals.
2339 (c_common_get_alias_set): char8_t doesn't alias.
2340 (c_common_nodes_and_builtins): Define char8_t as a builtin type in
2341 C++.
2342 (c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
2343 (keyword_begins_type_specifier): Add RID_CHAR8.
2344 * c-common.h (rid): Add RID_CHAR8.
2345 (c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
2346 Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
2347 Define char8_type_node and char8_array_type_node.
2348 * c-cppbuiltin.c (cpp_atomic_builtins): Predefine
2349 __GCC_ATOMIC_CHAR8_T_LOCK_FREE.
2350 (c_cpp_builtins): Predefine __cpp_char8_t.
2351 * c-lex.c (lex_string): Use char8_array_type_node as the type of
2352 CPP_UTF8STRING.
2353 (lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
2354 * c-opts.c: If not otherwise specified, enable -fchar8_t when
2355 targeting C++2a.
2356 * c.opt: Add the -fchar8_t command line option.
2357
23db6ced
MS
23582019-01-14 Martin Sebor <msebor@redhat.com>
2359
2360 PR target/88638
2361 * c-attribs.c (positional_argument): Call valid_format_string_type_p
2362 and issue errors if it fails.
2363 * c-common.h (valid_format_string_type_p): Declare.
2364 * c-format.c (valid_stringptr_type_p): Rename...
2365 (valid_format_string_type_p): ...to this and make extern.
2366 (handle_format_arg_attribute): Adjust to new name.
2367 (check_format_string): Same.
2368
234c3818
L
23692019-01-13 H.J. Lu <hongjiu.lu@intel.com>
2370
2371 * c-warn.c (warn_for_address_or_pointer_of_packed_member):
2372 Replace "may may" with "may" in warning message.
2373
d8fcab68
JJ
23742019-01-07 Jakub Jelinek <jakub@redhat.com>
2375
2376 PR c++/85052
2377 * c-common.h (enum rid): Add RID_BUILTIN_CONVERTVECTOR.
2378 (c_build_vec_convert): Declare.
2379 * c-common.c (c_build_vec_convert): New function.
2380
29d24852
MS
23812019-01-04 Martin Sebor <msebor@redhat.com>
2382
2383 PR c/88546
2384 * c-attribs.c (handle_copy_attribute): Avoid copying attribute leaf.
2385 Handle C++ empty throw specification and C11 _Noreturn.
2386 (has_attribute): Also handle C11 _Noreturn.
2387
9069a4c9
MS
23882019-01-04 Martin Sebor <msebor@redhat.com>
2389
2390 PR c/88363
2391 * c-attribs.c (positional_argument): Also accept enumerated types.
2392
a5544970
JJ
23932019-01-01 Jakub Jelinek <jakub@redhat.com>
2394
2395 Update copyright years.
2396
da77eace
L
23972018-12-20 H.J. Lu <hongjiu.lu@intel.com>
2398
2399 PR c/51628
2400 * c-common.h (warn_for_address_or_pointer_of_packed_member): New.
2401 * c-warn.c (check_alignment_of_packed_member): New function.
2402 (check_address_of_packed_member): Likewise.
2403 (check_and_warn_address_of_packed_member): Likewise.
2404 (warn_for_address_or_pointer_of_packed_member): Likewise.
2405 * c.opt: Add -Wno-address-of-packed-member.
2406
573767d4
DM
24072018-12-20 David Malcolm <dmalcolm@redhat.com>
2408
2409 PR c++/87504
2410 * c-warn.c (get_outermost_macro_expansion): New function.
2411 (spelled_the_same_p): Use it to unwind the macro expansions, and
2412 compare the outermost macro in each nested expansion, rather than
2413 the innermost.
2414
a14feb3c
DM
24152018-12-19 David Malcolm <dmalcolm@redhat.com>
2416
2417 PR c++/87504
2418 * c-common.h (warn_tautological_cmp): Convert 1st param from
2419 location_t to const op_location_t &.
2420 * c-warn.c (find_array_ref_with_const_idx_r): Call fold_for_warn
2421 when testing for INTEGER_CST.
2422 (warn_tautological_bitwise_comparison): Convert 1st param from
2423 location_t to const op_location_t &; use it to build a
2424 binary_op_rich_location, and use this.
2425 (spelled_the_same_p): New function.
2426 (warn_tautological_cmp): Convert 1st param from location_t to
2427 const op_location_t &. Warn for macro expansions if
2428 spelled_the_same_p. Use binary_op_rich_location.
2429
dfd7fdca
DM
24302018-12-19 David Malcolm <dmalcolm@redhat.com>
2431
2432 PR c++/43064
2433 PR c++/43486
2434 * c-common.c (unsafe_conversion_p): Fold any location wrapper.
2435 (verify_tree): Handle location wrappers.
2436 (c_common_truthvalue_conversion): Strip any location wrapper.
2437 Handle CONST_DECL.
2438 (fold_offsetof): Strip any location wrapper.
2439 (complete_array_type): Likewise for initial_value.
2440 (convert_vector_to_array_for_subscript): Call fold_for_warn on the
2441 index before checking for INTEGER_CST.
2442 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
2443 print parentheses around location wrappers.
2444 * c-warn.c (warn_logical_operator): Call fold_for_warn on op_right
2445 before checking for INTEGER_CST.
2446 (warn_tautological_bitwise_comparison): Call
2447 tree_strip_any_location_wrapper on lhs, rhs, and bitop's operand
2448 before checking for INTEGER_CST.
2449 (readonly_error): Strip any location wrapper.
2450 (warn_array_subscript_with_type_char): Strip location wrappers
2451 before checking for INTEGER_CST. Use the location of the index if
2452 available.
2453
5c8b3702
JM
24542018-12-06 Jason Merrill <jason@redhat.com>
2455
2456 PR c++/88136 - -Wdeprecated-copy false positives
2457 * c.opt (Wdeprecated-copy-dtor): New.
2458 (Wdeprecated-copy): Move to -Wextra.
2459
673670da
MS
24602018-11-29 Martin Sebor <msebor@redhat.com>
2461
2462 PR c/88172
2463 PR testsuite/88208
2464 * c-attribs.c (common_handle_aligned_attribute): Silently avoid setting
2465 alignments to values less than the target requires.
2466 (has_attribute): For attribute aligned consider both the attribute
2467 and the alignment bits.
2468 * c-common.c (c_init_attributes): Optionally issue a warning for
2469 zero alignment.
2470
04864ec8
MS
24712018-11-28 Martin Sebor <msebor@redhat.com>
2472
2473 PR c/88065
2474 PR c/87297
2475 * c-warn.c (sizeof_pointer_memaccess_warning): Bail if source
2476 or destination is an error.
2477
ace83db0
JJ
24782018-11-28 Jakub Jelinek <jakub@redhat.com>
2479
2480 PR c++/88215
2481 * c-ubsan.c: Include langhooks.h.
2482 (ubsan_instrument_division): Change gcc_assert that main variants
2483 of op0 and op1 types are equal to gcc_checking_assert that the
2484 main variants are compatible types.
2485
da193a27
EB
24862018-11-27 Eric Botcazou <ebotcazou@adacore.com>
2487
2488 * c-ada-spec.c: Include stringpool.h.
2489 (has_static_fields): Return false for incomplete types.
2490 (is_tagged_type): Likewise.
2491 (has_nontrivial_methods): Likewise.
2492 (dump_ada_node) <INTEGER_TYPE>: Deal specifically with __int128.
2493 (struct overloaded_name_hash): New structure.
2494 (struct overloaded_name_hasher): Likewise.
2495 (overloaded_names): New global variable.
2496 (init_overloaded_names): New static function.
2497 (overloaded_name_p): New predicate.
2498 (dump_ada_declaration) <TYPE_DECL>: Tidy up and set TREE_VISITED
2499 on the TYPE_STUB_DECL of the original type of a typedef, if any.
2500 <FUNCTION_DECL>: Bail out for an unsupported overloaded name.
2501 Remove always-true condition and dump forward types.
2502 (dump_ada_specs): Delete overloaded_names.
2503
98f08eb8
MS
25042018-11-20 Martin Sebor <msebor@redhat.com>
2505
2506 * c-attribs.c (type_for_vector_size): New function.
2507 (type_valid_for_vector_size): Same.
2508 (handle_vector_size_attribute): Move code to the functions above
2509 and call them.
2510 (validate_attribute, has_attribute): New functions.
2511 * c-common.h (has_attribute): Declare.
2512 (rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
2513 * c-common.c (c_common_resword): Same.
2514
2674fa47
JM
25152018-11-16 Jason Merrill <jason@redhat.com>
2516
2517 * c-lex.c (c_common_has_attribute): Handle likely/unlikely.
2518 * c-attribs.c (attr_cold_hot_exclusions): Make public.
2519
258b3854
JJ
25202018-11-16 Jakub Jelinek <jakub@redhat.com>
2521
2522 PR middle-end/87854
2523 * c-common.c (fix_string_type): Reject string literals larger than
2524 TYPE_MAX_VALUE (ssizetype) bytes.
2525
1d249509
MS
25262018-11-15 Martin Sebor <msebor@redhat.com>
2527
2528 PR c++/87541
2529 PR c++/87542
2530 * c-attribs.c (positional_argument): New function.
2531 (handle_alloc_size_attribute): Use it and simplify.
2532 (handle_alloc_align_attribute): Same.
2533 (handle_assume_aligned_attribute): Same.
2534 (handle_nonnull_attribute): Same.
2535 * c-common.c (check_function_arguments): Pass fntype to
2536 check_function_format.
2537 * c-common.h (check_function_format): Add an argument.
2538 (PosArgFlags, positional_argument): Declare new type and function.
2539 * c-format.c (decode_format_attr): Add arguments.
2540 (check_format_string, get_constant): Same.
2541 (convert_format_name_to_system_name): Adjust.
2542
478dd60d
DM
25432018-11-15 David Malcolm <dmalcolm@redhat.com>
2544
2545 PR other/19165
2546 * c-opts.c (c_diagnostic_finalizer): Add diagnostic_t param.
2547
8cca0163
JJ
25482018-11-14 Jakub Jelinek <jakub@redhat.com>
2549
8ee09943
JJ
2550 P1236R1 - Signed integers are two's complement
2551 * c-warn.c (maybe_warn_shift_overflow): Don't warn for c++2a.
2552 * c-ubsan.c (ubsan_instrument_shift): Make signed shifts
2553 with in-range second operand well defined for -std=c++2a.
2554
8cca0163
JJ
2555 PR other/88007
2556 * c-common.c (parse_optimize_options): Allocate option string from
2557 opts_obstack rather than as GC memory. Move the allocation after
2558 warning for invalid option.
2559
620e594b
DM
25602018-11-13 David Malcolm <dmalcolm@redhat.com>
2561
2562 * c-common.c (c_get_substring_location): Update for renaming of
2563 get_source_location_for_substring to get_location_within_string.
2564 * c-lex.c: Replace "source_location" with "location_t".
2565 * c-opts.c: Likewise.
2566 * c-ppoutput.c: Likewise.
2567
f9731de3
MS
25682018-11-13 Martin Sebor <msebor@redhat.com>
2569
2570 PR middle-end/81824
2571 * c-attribs.c (handle_copy_attribute): Exclude inlining attributes.
2572 (handle_tls_model_attribute): Improve diagnostics.
2573
e4bd6d5e
JM
25742018-11-12 Jason Merrill <jason@redhat.com>
2575
a6bb6b07
JM
2576 * c-cppbuiltin.c (c_cpp_builtins): Define
2577 __cpp_impl_destroying_delete.
2578
e4bd6d5e
JM
2579 * c-cppbuiltin.c (c_cpp_builtins): Change __cpp_explicit_bool to
2580 __cpp_conditional_explicit.
2581
79a2c428
MS
25822018-11-09 Martin Sebor <msebor@redhat.com>
2583
2584 PR middle-end/81824
2585 * c-attribs.c (handle_copy_attribute): New function.
2586
4c7bd361
MS
25872018-11-09 Martin Sebor <msebor@redhat.com>
2588
2589 PR c/87795
2590 * c-common.c (check_user_alignment): Use MAX_OFILE_ALIGNMENT.
2591
28567c40
JJ
25922018-11-08 Jakub Jelinek <jakub@redhat.com>
2593
2594 * c-common.h (c_finish_omp_taskgroup): Add CLAUSES argument.
2595 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
2596 enum omp_memory_order MEMORY_ORDER.
2597 (c_finish_omp_flush): Add MO argument.
2598 (c_omp_depend_t_p, c_finish_omp_depobj): Declare.
2599 (c_finish_omp_for): Add FINAL_P argument.
2600 * c-omp.c: Include memmodel.h.
2601 (c_finish_omp_taskgroup): Add CLAUSES argument. Set
2602 OMP_TASKGROUP_CLAUSES to it.
2603 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
2604 enum omp_memory_order MEMORY_ORDER. Set OMP_ATOMIC_MEMORY_ORDER
2605 instead of OMP_ATOMIC_SEQ_CST.
2606 (c_omp_depend_t_p, c_finish_omp_depobj): New functions.
2607 (c_finish_omp_flush): Add MO argument, if not MEMMODEL_LAST, emit
2608 __atomic_thread_fence call with the given value.
2609 (check_omp_for_incr_expr): Formatting fixes.
2610 (c_finish_omp_for): Add FINAL_P argument. Allow NE_EXPR
2611 even in OpenMP loops, diagnose if NE_EXPR and incr expression
2612 is not constant expression 1 or -1. Transform NE_EXPR loops
2613 with iterators pointers to VLA into LT_EXPR or GT_EXPR loops.
2614 (c_omp_check_loop_iv_r): Look for orig decl of C++ range for
2615 loops too.
2616 (c_omp_split_clauses): Add support for combined
2617 #pragma omp parallel master and
2618 #pragma omp {,parallel }master taskloop{, simd} constructs.
2619 Handle OMP_CLAUSE_IN_REDUCTION. Handle OMP_CLAUSE_REDUCTION_TASK.
2620 Handle OMP_CLAUSE_NONTEMPORAL. Handle splitting OMP_CLAUSE_IF
2621 also to OMP_SIMD. Copy OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
2622 (c_omp_predetermined_sharing): Don't return
2623 OMP_CLAUSE_DEFAULT_SHARED for const qualified decls.
2624 * c-pragma.c (omp_pragmas): Add PRAGMA_OMP_DEPOBJ and
2625 PRAGMA_OMP_REQUIRES.
2626 * c-pragma.h (enum pragma_kind): Likewise.
2627 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_NONTEMPORAL
2628 and PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
2629
204839e7
DM
26302018-11-08 David Malcolm <dmalcolm@redhat.com>
2631
2632 * c-format.c (gcc_dump_printf_char_table): Add entry for %f.
2633
d8010ee4
DM
26342018-11-08 David Malcolm <dmalcolm@redhat.com>
2635
2636 * c-format.c (local_cgraph_node_ptr_node): New variable.
2637 (gcc_dump_printf_char_table): Add entry for %C.
2638 (get_pointer_to_named_type): New function, taken from the handling
2639 code for "gimple *" from...
2640 (init_dynamic_diag_info): ...here. Add handling for
2641 "cgraph_node *".
2642 * c-format.h (T_CGRAPH_NODE): New.
2643
4be5c72c
JM
26442018-10-19 Jason Merrill <jason@redhat.com>
2645
2646 * c-cppbuiltin.c (c_cpp_builtins): Add
2647 __cpp_nontype_template_parameter_class.
2648
f3f6029d
NS
26492018-10-31 Nathan Sidwell <nathan@acm.org>
2650
ab5324fb
NS
2651 * c-opts.c (c_finish_options): Force command line macro
2652 location. Refactor to avoid repeating main debug hook.
2653 (push_command_line_include): Clarify comment.
2654
f3f6029d
NS
2655 * c-opts.c (c_finish_options): Adjust cpp_force_token_locations call.
2656
91e3ec29
MS
26572018-10-30 Martin Sebor <msebor@redhat.com>
2658
2659 PR middle-end/87041
2660 * c-format.c (check_format_types): Avoid diagnosing null pointer
2661 arguments to printf-family of functions.
2662
b5ff4f5c
MP
26632018-10-30 Marek Polacek <polacek@redhat.com>
2664
2665 Implement P0892R2, explicit(bool).
2666 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
2667
7e2de6df
DM
26682018-10-29 David Malcolm <dmalcolm@redhat.com>
2669
2670 * name-hint.h (name_hint::take_deferred): New member function.
2671
b2bf438c
DM
26722018-10-29 David Malcolm <dmalcolm@redhat.com>
2673
2674 PR c++/56856
2675 * c-common.c (check_function_sentinel): Call fold_for_warn on the
2676 argument.
2677 (check_function_restrict): Rename param "argarray" to
2678 "unfolded_argarray", and make a copy named "argarray", calling
2679 fold_for_warn on each argument.
2680 (check_function_arguments): Add note about responsibility for
2681 folding the arguments.
2682
9f936c86
JM
26832018-10-17 Joseph Myers <joseph@codesourcery.com>
2684
2685 * c-common.c (flag_isoc2x): New variable.
2686 * c-common.h (clk_c): Update comment to reference C2X.
2687 (flag_isoc99, flag_isoc11): Update comments to reference future
2688 standard versions in general.
2689 (flag_isoc2x): Declare.
2690 * c-opts.c (set_std_c2x): New function.
2691 (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
2692 (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
2693 flag_isoc2x to 0.
2694 * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
2695
7a8a92c4
JM
26962018-10-17 Joseph Myers <joseph@codesourcery.com>
2697
2698 * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
2699 (std=iso9899:2018): Document C17 as published in 2018.
2700
4dc003ff
CL
27012018-10-12 Christophe Lyon <christophe.lyon@linaro.org>
2702
2703 PR c++/87364
2704 * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
2705
79371671
WW
27062018-10-11 Will Wray <wjwray@gmail.com>
2707
2708 PR c++/87364
2709 * c-pretty-print.h (pp_c_type_cast): Prototype.
2710 (pp_c_integer_constant): Likewise.
2711 * c-pretty-print.c (pp_c_type_cast): No longer static.
2712 (pp_c_integer_constant): Likewise.
2713 (pp_c_enumeration_constant): Fix loop termination when finding
2714 name of constant. No longer returns a value. Call
2715 pp_c_integer_constant.
2716 (c_pretty_printer::constant): Update for changes to
2717 pp_c_enumeration_constant.
2718
46c62690
JJ
27192018-10-11 Jakub Jelinek <jakub@redhat.com>
2720
2721 * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
2722 for no_unique_address.
2723
c24300ba
DM
27242018-10-09 David Malcolm <dmalcolm@redhat.com>
2725
2726 * c-common.c (c_option_controlling_cpp_error): Rename to...
2727 (c_option_controlling_cpp_diagnostic): ...this, and convert
2728 "reason" from int to enum.
2729 (c_cpp_error): Rename to...
2730 (c_cpp_diagnostic): ...this, converting level and reason to enums.
2731 * c-common.h (c_cpp_error): Rename to...
2732 (c_cpp_diagnostic): ...this, converting level and reason to enums.
2733 * c-opts.c (c_common_init_options): Update for renaming.
2734
8656dafa
RS
27352018-10-08 Richard Sandiford <richard.sandiford@arm.com>
2736
2737 PR c/87286
2738 * c-common.c (vector_types_compatible_elements_p): Use
2739 INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
2740
8cff0652
VK
27412018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
2742
2743 * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
2744 to generate constructor destructor priority warning.
2745 * c.opt (-Wprio-ctor-dtor): New option.
2746
bedf03a2
JM
27472018-10-01 Jason Merrill <jason@redhat.com>
2748
2749 * c-lex.c (c_common_has_attribute): Add no_unique_address.
2750
6cc430c1
EB
27512018-10-01 Eric Botcazou <ebotcazou@adacore.com>
2752
2753 * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
2754 (dump_ada_node): Add const keyword.
2755
87677ac7
ML
27562018-09-25 Martin Liska <mliska@suse.cz>
2757
2758 * c-common.c (c_common_truthvalue_conversion):
2759 Remove Pascal from documentation.
2760
518196cb
EB
27612018-09-21 Eric Botcazou <ebotcazou@adacore.com>
2762
2763 * c-ada-spec.c: Include diagnostic.h.
2764 (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
2765
a599af84
MP
27662018-09-19 Marek Polacek <polacek@redhat.com>
2767
2768 * c.opt (Wclass-conversion): New.
2769
9c4a4b3c
DM
27702018-09-17 David Malcolm <dmalcolm@redhat.com>
2771
2772 * c-format.c (range_label_for_format_type_mismatch::get_text):
2773 Update for new param.
2774
c896ecfe
DM
27752018-09-17 David Malcolm <dmalcolm@redhat.com>
2776
2777 * c-format.c (format_warning_at_char): Update for introduction of
2778 format_string_diagnostic_t.
2779 (format_type_warning): Likewise.
2780
80c6d1f4
MJ
27812018-09-17 Martin Jambor <mjambor@suse.cz>
2782
2783 PR c/63886
2784 * c.opt (Wabsolute-value): New.
2785
6d900107
BE
27862018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
2787
2788 * c-common.c (complete_flexible_array_elts): New helper function.
2789 * c-common.h (complete_flexible_array_elts): Declare.
2790
b5764229
BE
27912018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
2792
2793 * c-common.c (braced_list_to_string): Remove eval parameter.
2794 Add some more checks. Always create zero-terminated STRING_CST.
2795 * c-common.h (braced_list_to_string): Adjust prototype.
2796
85204e23
DM
27972018-08-27 David Malcolm <dmalcolm@redhat.com>
2798
2799 PR 87091
2800 * c-common.c (c_cpp_error): Update for conversion of show_caret_p
2801 to a tri-state.
2802 (maybe_suggest_missing_token_insertion): Likewise.
2803 (maybe_add_include_fixit): Add param "override_location". If set,
2804 and source-printing is enabled, then override the rich_location's
2805 primary location with that of the insertion point for the fix-it
2806 hint, marking it with SHOW_LINES_WITHOUT_RANGE.
2807 * c-common.h (extern void maybe_add_include_fixit): Add bool
2808 param.
2809 * c-format.c (selftest::test_type_mismatch_range_labels): Update
2810 for conversion of show_caret_p to a tri-state.
2811 * c-warn.c (warn_for_restrict): Likewise.
2812 * known-headers.cc
2813 (suggest_missing_header::~suggest_missing_header): Update call to
2814 maybe_add_include_fixit to suggest overriding the location, as it
2815 is for a note.
2816
3d78e008
ML
28172018-08-27 Martin Liska <mliska@suse.cz>
2818
2819 * c-common.c (check_function_restrict): Use new function
92a285c1
ML
2820 fndecl_built_in_p and remove check for FUNCTION_DECL if
2821 possible.
3d78e008
ML
2822 (check_builtin_function_arguments): Likewise.
2823 (reject_gcc_builtin): Likewise.
2824 * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
2825
b5be6d0c
MP
28262018-08-26 Marek Polacek <polacek@redhat.com>
2827
2828 PR c++/87029, Implement -Wredundant-move.
2829 * c.opt (Wredundant-move): New option.
2830
79ca9c35
MP
28312018-08-21 Marek Polacek <polacek@redhat.com>
2832
2833 PR c++/86981, Implement -Wpessimizing-move.
2834 * c.opt (Wpessimizing-move): New option.
2835
097f82ec
DM
28362018-08-20 David Malcolm <dmalcolm@redhat.com>
2837
2838 PR other/84889
2839 * c-attribs.c (common_handle_aligned_attribute): Add
2840 auto_diagnostic_group instance.
2841 * c-indentation.c (warn_for_misleading_indentation): Likewise.
2842 * c-opts.c (c_common_post_options): Likewise.
2843 * c-warn.c (warn_logical_not_parentheses): Likewise.
2844 (warn_duplicated_cond_add_or_warn): Likewise.
2845 (warn_for_multistatement_macros): Likewise.
2846
3fb558b1
NS
28472018-08-20 Nathan Sidwell <nathan@acm.org>
2848
2849 * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
2850 access.
2851
800c0e98
NS
28522018-08-17 Nathan Sidwell <nathan@acm.org>
2853
2854 * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
2855 field.
2856 (laxy_hex_fp_value_count): Make unsigned.
2857 (lazy_hex_fp_value): Provided with macro & lazy number. Directly
2858 manipulate the macro.
2859 (builtin_defin_with_hex_fp_value): Adjust callback name, use
2860 cpp_define_lazily.
2861
6f795a92
DM
28622018-08-17 David Malcolm <dmalcolm@redhat.com>
2863
2864 * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
2865 (gcc_dump_printf_length_specs): New.
2866 (gcc_dump_printf_flag_pairs): New.
2867 (gcc_dump_printf_flag_specs): New.
2868 (gcc_dump_printf_char_table): New.
2869 (format_types_orig): Add entry for "gcc_dump_printf".
2870 (init_dynamic_diag_info): Set up length_char_specs and
2871 conversion_specs for gcc_dump_printf_format_type.
2872 (handle_format_attribute): Handle gcc_dump_printf_format_type.
2873
c5d725c0
NS
28742018-08-17 Nathan Sidwell <nathan@acm.org>
2875
10f04917
NS
2876 * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
2877
c5d725c0
NS
2878 * c-ada-spec.c: Don't #include "cpp-id-data.h"
2879 * c-cppbuiltin.c: Likewise.
2880
c0c12356
ML
28812018-08-17 Martin Liska <mliska@suse.cz>
2882
2883 * c.opt: Remove Warn, Init and Report for options with
92a285c1
ML
2884 Ignore/Deprecated flag. Warning is done automatically for
2885 Deprecated flags.
c0c12356 2886
10fcc142
DM
28872018-08-16 David Malcolm <dmalcolm@redhat.com>
2888
2889 PR c++/70693
2890 * c-common.c (selftest::c_family_tests): Call
2891 selftest::c_indentation_c_tests.
2892 * c-common.h (selftest::c_indentation_c_tests): New decl.
2893 * c-indentation.c: Include "selftest.h".
2894 (next_tab_stop): Add "tab_width" param, rather than accessing
2895 cpp_opts.
2896 (get_visual_column): Likewise. Clarify comment. Bulletproof
2897 against reading past the end of the line.
2898 (get_first_nws_vis_column): Add "tab_width" param.
2899 (detect_intervening_unindent): Likewise.
2900 (should_warn_for_misleading_indentation): Read tab width from
2901 cpp_opts and pass around.
2902 (selftest::test_next_tab_stop): New test.
2903 (selftest::assert_get_visual_column_succeeds): New function.
2904 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
2905 (selftest::assert_get_visual_column_fails): New function.
2906 (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
2907 (selftest::test_get_visual_column): New test.
2908 (selftest::c_indentation_c_tests): New function.
2909
3f6677f4
NS
29102018-08-16 Nathan Sidwell <nathan@acm.org>
2911
2912 * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
2913 (store_ada_macro): Likewise.
2914 * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
2915 * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
2916
96e6ae57
DM
29172018-08-15 David Malcolm <dmalcolm@redhat.com>
2918
2919 * c-format.c: Include "selftest-diagnostic.h" and
2920 "gcc-rich-location.h".
2921 (format_warning_at_char): Pass NULL for new label params of
2922 format_warning_va.
2923 (class indirection_suffix): New class.
2924 (class range_label_for_format_type_mismatch): New class.
2925 (format_type_warning): Move logic for generating "*" suffix to
2926 class indirection_suffix. Create "fmt_label" and "param_label"
2927 to show their types, and pass them to the
2928 format_warning_at_substring calls.
2929 (selftest::test_type_mismatch_range_labels): New test.
2930 (selftest::c_format_c_tests): Call it.
2931
23aa9f7c
MS
29322018-08-13 Martin Sebor <msebor@redhat.com>
2933
2934 PR tree-optimization/71625
2935 * c-common.c (braced_list_to_string): New function.
2936 * c-common.h (braced_list_to_string): Declare it.
2937
f10a9135
NS
29382018-08-08 Nathan Sidwell <nathan@acm.org>
2939
2940 * c-common.c (try_to_locate_new_include_inertion_point): Use
2941 linemap_included_from_linemap.
2942 * c-lex.c (fe_file_change): Use linemap_included_from.
2943 * c-ppoutput.c (pp_file_change): Likewise.
2944
8a45b051
MS
29452018-08-01 Martin Sebor <msebor@redhat.com>
2946
2947 PR tree-optimization/86650
ab20d992 2948 * c-format.c (gcc_tdiag_char_table): Update comment for "%G".
8a45b051
MS
2949 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
2950 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
2951 * c-format.h (T89_G): Update to be "gimple *" rather than
2952 "gcall *".
2953 (local_gcall_ptr_node): Rename...
2954 (local_gimple_ptr_node): ...to this.
2955
e540ccc0
DM
29562018-07-31 David Malcolm <dmalcolm@redhat.com>
2957
2958 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
2959 table entries for gcc_diag_char_table, and the 'Z' entry from
2960 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
2961 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
2962 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
2963 adding missing "Z" for this table. Remove erroneous "G" and "K"
2964 entries.
2965 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
2966 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
2967 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
2968
425fc685
RE
29692018-07-31 Richard Earnshaw <rearnsha@arm.com>
2970
2971 * c-common.c (speculation_safe_resolve_call): New function.
2972 (speculation_safe_resolve_params): New function.
2973 (speculation_safe_resolve_return): New function.
2974 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
2975 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
2976 __HAVE_SPECULATION_SAFE_VALUE.
2977
181463c2
DM
29782018-07-20 David Malcolm <dmalcolm@redhat.com>
2979
2980 * c-common.c (c_cpp_error): Remove redundant "line_table"
2981 parameter from call to rich_location::set_range.
2982 (maybe_suggest_missing_token_insertion): Likewise.
2983
0d7f9065
MS
29842018-07-20 Martin Sebor <msebor@redhat.com>
2985
2986 PR middle-end/82063
ab20d992 2987 * c.opt (-Warray-bounds): Remove redundant -Wall.
0d7f9065 2988
00abf86c
MS
29892018-07-20 Martin Sebor <msebor@redhat.com>
2990
2991 PR middle-end/82063
2992 * c-common.h (c_common_handle_option): Change function argument
2993 to HOST_WIDE_INT.
2994 * c-opts.c (c_common_init_options): Same.
2995 (c_common_handle_option): Same. Remove special handling of
2996 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
2997 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
2998 options to take a HOST_WIDE_INT argument and accept a byte-size
2999 suffix. Initialize.
3000 (-Wvla-larger-than): Same.
3001 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
3002 (-Wno-vla-larger-than): Same.
3003
9b452033
JJ
30042018-07-12 Jakub Jelinek <jakub@redhat.com>
3005
3006 * c-attribs.c (c_common_attribute_table): Add
3007 "omp declare target implicit" attribute.
3008
cd0762f3
RB
30092018-07-12 Richard Biener <rguenther@suse.de>
3010
3011 PR c/86453
3012 * c-attribs.c (handle_packed_attribute): Do not build a variant
3013 type with TYPE_PACKED, instead ignore the attribute if we may
3014 not apply to the original type.
3015
0b27c3ed
JJ
30162018-07-10 Jakub Jelinek <jakub@redhat.com>
3017
3018 PR c++/86443
3019 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
3020 to contain TREE_LIST for both the original class iterator and the
3021 "last" helper var.
3022
e730a0ef
EB
30232018-07-07 Eric Botcazou <ebotcazou@adacore.com>
3024
3025 * c-ada-spec.c (to_ada_name): Remove index parameter.
3026 (pp_ada_tree_identifier): Likewise.
3027 (dump_ada_macros): Adjust call to to_ada_name.
3028 (struct overloaded_name_hash): Delete.
3029 (struct overloaded_name_hasher): Likewise.
3030 (overloaded_names): Likewise.
3031 (compute_overloading_index): Likewise.
3032 (dump_ada_decl_name): Do not call compute_overloading_index and
3033 adjust calls to pp_ada_tree_identifier.
3034 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
3035 (dump_ada_import): Add spc parameter and switch to aspect syntax.
3036 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
3037 (dump_ada_enum_type): Remove type and display_convention parameters.
3038 Adjust calls to pp_ada_tree_identifier.
3039 (dump_ada_node): Likewise and for dump_ada_structure.
3040 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
3041 and tidy up.
3042 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
3043 syntax.
3044 (print_constructor): Adjust call to pp_ada_tree_identifier.
3045 (print_destructor): Likewise.
3046 (dump_ada_declaration): Switch to aspect syntax.
3047 (dump_ada_structure): Likewise and tidy up. Replace display_convention
3048 parameter with nested parameter.
3049 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
3050 (dump_ada_specs): Do not delete overloaded_names table.
3051
8de583fc
PB
30522018-07-06 Peter Bergner <bergner@linux.ibm.com>
3053
3054 PR target/86324
e730a0ef 3055 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
8de583fc
PB
3056 target hook.
3057
09cff37b
NS
30582018-07-05 Nathan Sidwell <nathan@acm.org>
3059
3060 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
3061 NO_IMPLICIT_EXTERN_C.
3062
98086b2b
ML
30632018-06-28 Martin Liska <mliska@suse.cz>
3064
3065 * cppspec.c: Include opt-suggestions.h.
3066
ab20d992
JJ
30672018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
3068 Thomas Schwinge <thomas@codesourcery.com>
829c6349
CLT
3069 Cesar Philippidis <cesar@codesourcery.com>
3070
3071 * c-pragma.h (enum pragma_omp_clause): Add
3072 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
3073 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
3074
f41b7612
JJ
30752018-06-20 Jakub Jelinek <jakub@redhat.com>
3076
3077 PR c++/86210
3078 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
3079 comment.
3080
4252ccd7
MS
30812018-06-18 Martin Sebor <msebor@redhat.com>
3082
3083 PR middle-end/85602
3084 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
3085 nonstring.
3086
e197e64e
KV
30872018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
3088
3089 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
3090
34a7a230
JM
30912018-06-13 Jason Merrill <jason@redhat.com>
3092
5cef3733
JM
3093 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
3094 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
3095 handling.
3096
34a7a230
JM
3097 PR c++/86094 - wrong code with defaulted move ctor.
3098 * c-opts.c (c_common_post_options): Bump the current ABI version to
3099 13. Set warn_abi_version and flag_abi_compat_version to the current
3100 version rather than 0. Fix defaulting flag_abi_compat_version from
3101 warn_abi_version.
3102
bb0f14ae
MS
31032018-06-12 Martin Sebor <msebor@redhat.com>
3104
3105 PR c/85931
3106 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
3107 sizeof source and destination yields the same value.
3108
3713f2e2
ML
31092018-06-12 Martin Liska <mliska@suse.cz>
3110
3111 * c.opt: Make MPX-related options as Deprecated.
3112
4af78ef8
DM
31132018-06-08 David Malcolm <dmalcolm@redhat.com>
3114
3115 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
3116 rather than 0.
3117
31db0fe0
ML
31182018-06-08 Martin Liska <mliska@suse.cz>
3119
3120 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
3121 for MPX (macros, related functions, fields in cgraph_node, ...).
3122 (handle_bnd_legacy): Likewise.
3123 (handle_bnd_instrument): Likewise.
3124 * c.opt: Likewise.
3125
fe16acf2
JJ
31262018-06-06 Jakub Jelinek <jakub@redhat.com>
3127
3128 PR c++/86068
3129 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
3130 __cpp_transactional_memory to 201500 instead of 210500.
3131
4dbdb49b
JM
31322018-06-06 Jason Merrill <jason@redhat.com>
3133
3134 PR c++/85710 - ICE with -Wmemset-elt-size.
3135 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
3136
f8ad043f
JM
31372018-06-01 Jason Merrill <jason@redhat.com>
3138
3139 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
3140 201703.
3141
abc24d93
EB
31422018-06-01 Eric Botcazou <ebotcazou@adacore.com>
3143
3144 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
3145 declaration for a typedef independently of whether the declaration of
3146 the subtype is generated.
3147
d258f4aa
MS
31482018-05-31 Martin Sebor <msebor@redhat.com>
3149
3150 PR c/82063
3151 * c.opt (-Wno-alloc-size-larger-than): New option.
3152
b67b9225
DP
31532018-04-22 David Pagan <dave.pagan@oracle.com>
3154
3155 PR c/55976
3156 * c-opts.c (c_common_post_options): Set default for warn_return_type
ab20d992 3157 for C++/C++ with ObjC extensions only. For C, makes it possible to
b67b9225
DP
3158 differentiate between default (no option), -Wreturn-type, and
3159 -Wno-return-type.
3160
04eb9c55
JM
31612018-05-29 Jason Merrill <jason@redhat.com>
3162
3163 * c.opt (Winit-list-lifetime): New flag.
3164
b0c31bc6
BE
31652018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
3166
3167 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
3168 splay_tree_delete_pointers.
3169
44284983
JJ
31702018-05-26 Jakub Jelinek <jakub@redhat.com>
3171
3172 PR bootstrap/85921
3173 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
3174 noinline variable to workaround broken kernel headers.
3175
b46b715d
JM
31762018-05-18 Jason Merrill <jason@redhat.com>
3177
3178 * c.opt (Wdeprecated-copy): New flag.
3179
40659769
ML
31802018-05-17 Martin Liska <mliska@suse.cz>
3181
3182 * c-warn.c (overflow_warning): Do not use
3183 space in between 'G_' and '('.
3184
403962ea
JM
31852018-05-09 Jason Merrill <jason@redhat.com>
3186
3187 * c-common.c (valid_array_size_p): Add complain parameter.
3188 * c-common.h: ...which defaults to true.
3189
1c9ee609
JJ
31902018-05-11 Jakub Jelinek <jakub@redhat.com>
3191
3192 PR c/85696
3193 * c-omp.c (c_omp_predetermined_sharing): Return
3194 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
3195
19916065
ML
31962018-05-11 Martin Liska <mliska@suse.cz>
3197
92a285c1 3198 PR sanitizer/85556
19916065
ML
3199 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
3200 TREE_LIST values.
3201
79e7b1fe
JJ
32022018-05-10 Jakub Jelinek <jakub@redhat.com>
3203
3204 PR c++/85662
3205 * c-common.h (fold_offsetof_1): Removed.
3206 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
3207 CTX argument defaulted to ERROR_MARK.
3208 * c-common.c (fold_offsetof_1): Renamed to ...
3209 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
3210 argument, convert the pointer constant to TYPE and use size_binop
3211 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
3212 a pointer type. Adjust recursive calls.
3213
86c12f76
EB
32142018-05-10 Eric Botcazou <ebotcazou@adacore.com>
3215
3216 PR c++/85400
3217 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
3218
ee336e84
NS
32192018-05-07 Nathan Sidwell <nathan@acm.org>
3220
3221 * c.opt (ffor-scope): Remove functionality, issue warning.
3222
6c072e21
NS
32232018-05-03 Nathan Sidwell <nathan@acm.org>
3224
3225 * c.opt (ffriend-injection): Remove functionality, issue warning.
3226
2cc7d3a7
DM
32272018-05-01 David Malcolm <dmalcolm@redhat.com>
3228
3229 PR c/84258
3230 * c-format.c (struct format_check_results): Add field
3231 "number_non_char".
3232 (check_format_info): Initialize it, and warn if encountered.
3233 (check_format_arg): Distinguish between wide char and
3234 everything else when detecting arrays of non-char.
3235
7761dfbe
DM
32362018-04-30 David Malcolm <dmalcolm@redhat.com>
3237
3238 * c-format.c (get_corrected_substring): Update for
3239 location_get_source_line returning a char_span. Use a char_span
3240 when handling the prefix of the correction.
3241 * c-indentation.c (get_visual_column): Update for
3242 location_get_source_line returning a char_span.
3243 (get_first_nws_vis_column): Likewise.
3244
62e98ef1
DM
32452018-03-29 David Malcolm <dmalcolm@redhat.com>
3246
3247 PR c++/84269
3248 * known-headers.cc (get_stdlib_header_for_name): Add various names
3249 from <assert.h>, <string.h>, and <memory.h>; add more names from
3250 <stdio.h>.
3251
a7dea617
JJ
32522018-03-27 Jakub Jelinek <jakub@redhat.com>
3253
3254 PR c++/85061
3255 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
3256 get_base_address of the second operand is a VAR_P, rather than the
3257 operand itself, and use gcc_checking_assert instead of gcc_assert.
3258
889a3a30
MP
32592018-03-23 Marek Polacek <polacek@redhat.com>
3260
3261 PR c++/85045
3262 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
3263 <case RDIV_EXPR>: Tweak condition.
3264
452154b9
EB
32652018-03-20 Eric Botcazou <ebotcazou@adacore.com>
3266
3267 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
3268
63ecb626
JJ
32692018-03-16 Jakub Jelinek <jakub@redhat.com>
3270
ce811fc4
JJ
3271 PR c/84909
3272 * c-warn.c (conversion_warning): Replace "to to" with "to" in
3273 diagnostics.
3274
63ecb626
JJ
3275 PR c/84910
3276 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
3277 diagnostics.
3278
a1295eec
RB
32792018-03-16 Richard Biener <rguenther@suse.de>
3280
3281 PR c/84873
3282 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
3283 unshare the possibly folded expression.
3284
919674fb
RB
32852018-03-15 Richard Biener <rguenther@suse.de>
3286
3287 PR c/84873
3288 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
3289
f99309b2
MS
32902018-03-13 Martin Sebor <msebor@redhat.com>
3291
3292 PR tree-optimization/84725
3293 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
3294 with all three narrow character types, including their qualified forms.
3295
e9b9fa4c
MS
32962018-03-12 Martin Sebor <msebor@redhat.com>
3297
3298 PR tree-optimization/83456
ab20d992 3299 * c-common.c (check_function_restrict): Return bool.
e9b9fa4c
MS
3300 Restore checking of bounded built-in functions.
3301 (check_function_arguments): Also return the result
3302 of warn_for_restrict.
ab20d992
JJ
3303 * c-common.c (check_function_restrict): Return bool.
3304 * c-warn.c (warn_for_restrict): Return bool.
e9b9fa4c 3305
0805d020
MP
33062018-03-02 Marek Polacek <polacek@redhat.com>
3307
3308 PR c++/84171
3309 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
3310 is erroneous.
3311
ed2a2f08
TS
33122018-03-02 Thomas Schwinge <thomas@codesourcery.com>
3313
3314 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
3315 function".
3316
90abdde0
MP
33172018-03-01 Marek Polacek <polacek@redhat.com>
3318
3319 PR c++/84639
3320 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
3321 alignment in computation.
3322
c6db43fa
EB
33232018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3324
3325 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
3326 <REAL_TYPE>: Deal specifically with _Float128/__float128.
3327
9e25c7ed
EB
33282018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3329
3330 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
3331 (is_char_array): Take a type instead of a declaration.
3332 (dump_ada_array_type): Likewise.
3333 (is_simple_enum): Minor tweak.
3334 (dump_ada_enum_type): New function extracted from...
3335 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
3336 <INTEGER_TYPE>: Remove unreachable code.
3337 <RECORD_TYPE>: Likewise. Minor tweaks.
3338 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
3339 <ENUMERAL_TYPE>: New case.
3340 <RECORD_TYPE>: Factor out common code.
3341 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
3342 Minor tweaks. Deal with enumeral types.
3343 (dump_ada_structure): Minor tweaks.
3344
09de3550
EB
33452018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3346
3347 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
3348 address for incomplete structures.
3349 (dump_forward_type): Do not bail out for incomplete structures.
3350 (dump_ada_declaration): Do not special-case incomplete structures
3351 for subtypes. Dump them as null records for types.
3352
095d8d4b
EB
33532018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3354
3355 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
3356 (is_char_array): Fix formatting.
3357 (dump_template_types): Likewise.
3358 (dump_generic_ada_node): Rename into...
3359 (dump_ada_node): ...this.
3360 <POINTER_TYPE>: Remove superfluous space. Use generic address for
3361 incomplete structures and not for empty structures. Do not use it
3362 when forward declarations are needed.
3363 (dump_forward_type): New function.
3364 (dump_nested_types): Remove FORWARD parameter. Do not consider
3365 TREE_VISITED and do not generate a forward declaration. Only dump
3366 original nested types for nested declaration.
3367 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
3368 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
3369 <RECORD_TYPE>: Do not consider TREE_VISITED.
3370 (dump_ada_declaration): Use booleans and fix formatting throughout.
3371 <TYPE_DECL>: Skip incomplete structures and not empty structures.
3372 Call dump_forward_type instead of dump_nested_types for a typedef.
3373 Remove superfluous check and adjust call to dump_nested_types.
3374 <POINTER_TYPE>: Call dump_forward_type and fall through.
3375 (dump_ada_struct_decl): Rename into...
3376 (dump_ada_structure): ...this. Do not special-case empty structures.
3377
d4cfd486
MS
33782018-02-27 Martin Sebor <msebor@redhat.com>
3379
3380 PR c++/83871
3381 * c.opt (-Wmissing-attributes): New option.
3382
b22dbd03
ML
33832018-02-21 Martin Liska <mliska@suse.cz>
3384
3385 * c.opt (Wcatch-value=): Add IntegerRange.
3386
883dfe2a
JM
33872018-02-15 Jason Merrill <jason@redhat.com>
3388
3389 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
3390
0444aa9c
NS
33912018-02-09 Nathan Sidwell <nathan@acm.org>
3392
3393 PR c/84293
3394 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
3395 arg.
3396 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
3397 arg. Adjust.
3398
cea71f0a
MS
33992018-02-09 Martin Sebor <msebor@redhat.com>
3400
3401 PR lto/84212
3402 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
3403 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
3404 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
3405 (-Wstrict-overflow, -Wsuggest-attribute): Same.
3406 (-Wuninitialized): Same.
3407
8c8b7be5
EB
34082018-02-09 Eric Botcazou <ebotcazou@adacore.com>
3409
3410 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
3411 keyword for components.
3412
7c30b12a
PC
34132018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
3414
3415 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
3416
eece7fe5
JK
34172018-02-02 Julia Koval <julia.koval@intel.com>
3418
3419 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
3420
7d07a93a
MP
34212018-01-29 Marek Polacek <polacek@redhat.com>
3422
3423 PR c/83966
3424 * c-format.c (check_function_format): Check current_function_decl.
3425
53723269
JJ
34262018-01-27 Jakub Jelinek <jakub@redhat.com>
3427
3428 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
3429 argument.
3430 (LAZY_HEX_FP_VALUES_CNT): Define.
3431 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
3432 values rather than just 12.
3433 (builtin_define_with_hex_fp_value): Likewise.
3434
7365279f
BK
34352018-01-18 Boris Kolpackov <boris@codesynthesis.com>
3436
92a285c1
ML
3437 PR other/70268
3438 * c.opt (-fmacro-prefix-map): New option.
3439 * c-opts.c (c_common_handle_option): Handle it.
3440 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
3441 * c-ppoutput.c (init_pp_output): Likewise.
7365279f 3442
bb9869d5
DM
34432018-01-17 David Malcolm <dmalcolm@redhat.com>
3444
3445 PR c++/83814
3446 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
3447
68dc87c3
EB
34482018-01-10 Eric Botcazou <ebotcazou@adacore.com>
3449
3450 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
3451 Skip 'f' and 'F' characters if it is true.
3452 (store_ada_macro): Minor tweak.
3453 (dump_ada_macros) <CPP_COMMENT>: Likewise.
3454 <CPP_WSTRING>: Likewise.
3455 <CPP_STRING>: Output '&' in the buffer if not the first string.
3456 <CPP_NUMBER>: Adjust calls to dump_number.
3457
9a004410
DM
34582018-01-10 David Malcolm <dmalcolm@redhat.com>
3459
3460 PR c++/43486
3461 * c-common.c: Include "selftest.h".
3462 (get_atomic_generic_size): Perform the test for integral type
3463 before the range test for any integer constant, fixing indentation
3464 of braces. Call fold_for_warn before testing for an INTEGER_CST.
3465 (reject_gcc_builtin): Strip any location wrapper from EXPR.
3466 (selftest::test_fold_for_warn): New function.
3467 (selftest::c_common_c_tests): New function.
3468 (selftest::c_family_tests): Call it, and
3469 selftest::c_pretty_print_c_tests.
3470 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
3471 * c-format.c (check_format_arg): Convert VAR_P check to a
3472 fold_for_warn.
3473 * c-pretty-print.c: Include "selftest.h".
3474 (pp_c_cast_expression): Don't print casts for location wrappers.
3475 (selftest::assert_c_pretty_printer_output): New function.
3476 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
3477 (selftest::test_location_wrappers): New function.
3478 (selftest::c_pretty_print_c_tests): New function.
3479 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
3480
5c0caeb3
RS
34812018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
3482 Alan Hayward <alan.hayward@arm.com>
3483 David Sherwood <david.sherwood@arm.com>
3484
3485 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
3486
73a699ae
RS
34872018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
3488 Alan Hayward <alan.hayward@arm.com>
3489 David Sherwood <david.sherwood@arm.com>
3490
3491 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
3492 as polynomial.
3493
928686b1
RS
34942018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
3495 Alan Hayward <alan.hayward@arm.com>
3496 David Sherwood <david.sherwood@arm.com>
3497
3498 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
3499 (convert_vector_to_array_for_subscript): Handle polynomial
3500 TYPE_VECTOR_SUBPARTS.
3501 (c_common_type_for_mode): Check valid_vector_subparts_p.
3502 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
3503 VECTOR_CST_NELTS.
3504
85ec4feb
JJ
35052018-01-03 Jakub Jelinek <jakub@redhat.com>
3506
3507 Update copyright years.
3508
170a8bd6 35092017-12-22 Mike Stump <mikestump@comcast.net>
92a285c1 3510 Eric Botcazou <ebotcazou@adacore.com>
170a8bd6
EB
3511
3512 * c-pragma.c (init_pragma): Register pragma GCC unroll.
3513 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
3514
ab20d992 35152017-12-22 Alexandre Oliva <aoliva@redhat.com>
18408e96
AO
3516
3517 PR debug/83527
3518 PR debug/83419
3519 * c-semantics.c (only_debug_stmts_after_p): New.
3520 (pop_stmt_list): Clear side effects in debug-only stmt list.
3521 Check for single nondebug stmt followed by debug stmts only.
3522
c12d20d4
AO
35232017-12-21 Alexandre Oliva <aoliva@redhat.com>
3524
3525 PR debug/83419
3526 * c-semantics.c (pop_stmt_list): Propagate side effects from
3527 single nondebug stmt to container list.
3528
01512446
JJ
35292017-12-19 Jakub Jelinek <jakub@redhat.com>
3530
3531 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
3532 conditions with typical order conditions.
3533
82cfbd01
MP
35342017-12-18 Marek Polacek <polacek@redhat.com>
3535
3536 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
3537 not in effect.
3538
99da11ec
MS
35392017-12-17 Martin Sebor <msebor@redhat.com>
3540
3541 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
3542 an error for attribute warn_if_not_aligned.
3543
cc8bea0a
MS
35442017-12-16 Martin Sebor <msebor@redhat.com>
3545
3546 PR tree-optimization/78918
3547 * c-common.c (check_function_restrict): Avoid checking built-ins.
3548 * c.opt (-Wrestrict): Include in -Wall.
3549
4849deb1
JJ
35502017-12-15 Jakub Jelinek <jakub@redhat.com>
3551
3552 * c-attribs.c (c_common_attribute_table,
3553 c_common_format_attribute_table): Swap affects_type_identity
3554 and handler fields, adjust comments.
3555
c65e18d3
BE
35562017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
3557
3558 * c.opt (Wcast-function-type): New warning option.
3559 * c-lex.c (get_fileinfo): Avoid warning.
3560 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
3561
2004617a
QZ
35622017-12-14 Qing Zhao <qing.zhao@oracle.com>
3563
7365279f 3564 PR middle_end/79538
2004617a
QZ
3565 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
3566 Adjust the size of buf1 and buf2, add a new buf to avoid
3567 format-overflow warning.
3568
ab20d992 35692017-12-12 Alexandre Oliva <aoliva@redhat.com>
96a95ac1
AO
3570
3571 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
3572 subsequent statement list.
3573
5d9ae53d
MS
35742017-12-07 Martin Sebor <msebor@redhat.com>
3575
3576 PR c/81544
3577 PR c/81566
3578 * c-attribs.c (attr_aligned_exclusions): New array.
3579 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
3580 (attr_common_exclusions, attr_const_pure_exclusions): Same.
3581 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
3582 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
3583 (attr_warn_unused_result_exclusions): Same.
3584 (handle_hot_attribute, handle_cold_attribute): Simplify.
3585 (handle_const_attribute): Warn on function returning void.
3586 (handle_pure_attribute): Same.
3587 (handle_aligned_attribute): Diagnose conflicting attribute
3588 specifications.
3589 * c-warn.c (diagnose_mismatched_attributes): Simplify.
3590
c79144f8
DM
35912017-12-06 David Malcolm <dmalcolm@redhat.com>
3592
3593 PR c/83236
3594 * c-common.c (selftest::c_family_tests): Call
3595 selftest::c_spellcheck_cc_tests.
3596 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
3597 * c-spellcheck.cc: Include "selftest.h".
3598 (name_reserved_for_implementation_p): New function.
3599 (should_suggest_as_macro_p): New function.
3600 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
3601 should_suggest_as_macro_p and call it.
3602 (selftest::test_name_reserved_for_implementation_p): New function.
3603 (selftest::c_spellcheck_cc_tests): New function.
3604 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
3605
613bc14f
DM
36062017-12-06 David Malcolm <dmalcolm@redhat.com>
3607
3608 * c-spellcheck.cc: New file, taken from macro-handling code in
3609 spellcheck-tree.c.
3610 * c-spellcheck.h: New file, taken from macro-handling code in
3611 spellcheck-tree.h.
3612
e76c7157
JJ
36132017-12-01 Jakub Jelinek <jakub@redhat.com>
3614
3615 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
3616 attribute.
3617 (handle_simd_attribute): Don't check for "cilk simd function"
3618 attribute. Reindent, formatting changes.
3619
b0da4034
JK
36202017-11-30 Julia Koval <julia.koval@intel.com>
3621
3622 * c-common.h (inv_list): Remove.
3623
058f0b9e
JJ
36242017-11-28 Jakub Jelinek <jakub@redhat.com>
3625
3626 PR sanitizer/81275
3627 * c-common.c (c_switch_covers_all_cases_p_1,
3628 c_switch_covers_all_cases_p): New functions.
3629 * c-common.h (c_switch_covers_all_cases_p): Declare.
3630
5e9d6aa4 36312017-11-28 Julia Koval <julia.koval@intel.com>
92a285c1 3632 Sebastian Peryt <sebastian.peryt@intel.com>
5e9d6aa4
JK
3633
3634 * array-notation-common.c: Delete.
3635 * c-cilkplus.c: Ditto.
3636 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
3637 * c-common.def (ARRAY_NOTATION_REF): Remove.
3638 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
3639 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
3640 c_validate_cilk_plus_loop, cilkplus_an_parts,
3641 cilk_ignorable_spawn_rhs_op,
3642 cilk_recognize_spawn): Remove.
3643 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
3644 * c-omp.c: Remove CILK_SIMD check.
3645 * c-pragma.c: Ditto.
3646 * c-pragma.h: Remove CILK related pragmas.
3647 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
3648 ARRAY_NOTATION_REF condition.
3649 (c_pretty_printer::expression): Ditto.
3650 * c.opt (fcilkplus): Remove.
3651 * cilk.c: Delete.
3652
1af4ebf5
MG
36532017-11-21 Marc Glisse <marc.glisse@inria.fr>
3654
3655 * c-pretty-print.c (pp_c_additive_expression,
3656 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
3657
d44ed508
JJ
36582017-11-21 Jakub Jelinek <jakub@redhat.com>
3659
7d2f0f9b
JJ
3660 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
3661
d44ed508
JJ
3662 PR c++/83059
3663 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
3664 instead of tree_to_uhwi, formatting fix.
3665
26edace6
DM
36662017-11-20 David Malcolm <dmalcolm@redhat.com>
3667
3668 PR c/81404
3669 * known-headers.cc: New file, based on material from c/c-decl.c.
3670 (suggest_missing_header): Copied as-is.
3671 (get_stdlib_header_for_name): New, based on get_c_name_hint but
3672 heavily edited to add C++ support. Add some knowledge about
3673 <limits.h>, <stdint.h>, and <wchar.h>.
3674 * known-headers.h: Likewise.
3675
6c7a259b
DM
36762017-11-20 David Malcolm <dmalcolm@redhat.com>
3677
3678 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
3679 (lookup_name_fuzzy): Likewise. Convert return type from
3680 const char * to name_hint. Add location_t param.
3681 * name-hint.h: New header.
3682
f9c59f7e
JJ
36832017-11-19 Jakub Jelinek <jakub@redhat.com>
3684
3685 PR c/66618
3686 PR c/69960
3687 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
3688
1e39313a
JM
36892017-11-16 Joseph Myers <joseph@codesourcery.com>
3690
3691 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
3692 expected publication date of C17.
3693 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
3694
3ca0dc60
JM
36952017-11-15 Joseph Myers <joseph@codesourcery.com>
3696
3697 PR c/81156
3698 * c-common.c (c_common_reswords): Add __builtin_tgmath.
3699 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
3700
025d57f0
MS
37012017-11-10 Martin Sebor <msebor@redhat.com>
3702
3703 PR c/81117
3704 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
3705 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
3706 * c.opt (-Wstringop-truncation): New option.
3707
1b6fa695
ML
37082017-11-06 Martin Liska <mliska@suse.cz>
3709
3710 PR middle-end/82404
3711 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
3712 FE.
3713 * c.opt: Set default value of warn_return_type.
3714
64a5912c
DM
37152017-10-31 David Malcolm <dmalcolm@redhat.com>
3716
3717 * c-common.c (binary_op_error): Update for renaming of
3718 error_at_rich_loc.
3719 (c_parse_error): Likewise.
3720 * c-warn.c (warn_logical_not_parentheses): Likewise for
3721 renaming of inform_at_rich_loc.
3722 (warn_for_restrict): Likewise for renaming of
3723 warning_at_rich_loc_n.
3724
c76dc9c3
JM
37252017-10-30 Joseph Myers <joseph@codesourcery.com>
3726
3727 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
3728 * c-opts.c (set_std_c17): New function.
3729 (c_common_init_options): Use gnu17 as default C version.
3730 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
3731
ee5fd23a
MM
37322017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
3733
3734 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
3735 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
3736 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
3737 __FP_FAST_FMA<N>X.
3738
d1047465
MP
37392017-10-23 Marek Polacek <polacek@redhat.com>
3740
3741 PR c/82681
3742 * c-warn.c (warnings_for_convert_and_check): Fix typos.
3743
9e878cf1
EB
37442017-10-19 Eric Botcazou <ebotcazou@adacore.com>
3745
3746 * c-common.c (check_builtin_function_arguments): Also check arguments
3747 of __builtin_alloca_with_align_and_max.
3748
89b6abbb
DM
37492017-10-17 David Malcolm <dmalcolm@redhat.com>
3750
3751 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
3752 rather than NULL to format_warning_va.
3753 (check_format_types): Likewise when calling format_type_warning.
3754 Remove code to extract source_ranges and source_range * in favor
3755 of just a location_t.
3756 (format_type_warning): Convert source_range * param to a
3757 location_t.
3758
39382c09
JJ
37592017-10-13 Jakub Jelinek <jakub@redhat.com>
3760
3761 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
3762 [LR]SHIFT_EXPR.
3763
62e1c678
DM
37642017-10-12 David Malcolm <dmalcolm@redhat.com>
3765
3766 * c-common.c (enum missing_token_insertion_kind): New enum.
3767 (get_missing_token_insertion_kind): New function.
3768 (maybe_suggest_missing_token_insertion): New function.
3769 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
3770
b90c9338
NS
37712017-10-11 Nathan Sidwell <nathan@acm.org>
3772
3773 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
3774 (c_common_handle_option): Update incpath_kind names.
3775
3a266bcd
ML
37762017-10-11 Martin Liska <mliska@suse.cz>
3777
3778 PR sanitizer/82490
3779 * c-attribs.c (handle_no_sanitize_attribute): Report directly
3780 Wattributes warning.
3781
8e6cdc90
RS
37822017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
3783
3784 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
3785 operating on trees as wide_ints.
3786 * c-common.c (pointer_int_sum): Likewise.
3787 * c-pretty-print.c (pp_c_integer_constant): Likewise.
3788 * c-warn.c (match_case_to_enum_1): Likewise.
3789 (c_do_switch_warnings): Likewise.
3790 (maybe_warn_shift_overflow): Likewise.
3791
802b38c9
JJ
37922017-10-10 Jakub Jelinek <jakub@redhat.com>
3793
3794 PR c/82437
3795 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
3796 instead of wide_int::from.
3797
4e34b338
JJ
37982017-10-06 Jakub Jelinek <jakub@redhat.com>
3799
3800 PR c/82437
3801 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
3802 using to_widest use wide_int with the larger of the two precisions.
3803
4bc4b2b4
BE
38042017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
3805
3806 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
3807 functions.
3808
a1488398
RS
38092017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
3810
3811 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
3812 when combining the original unconverted comparison operands.
3813
01c9fb68
JJ
38142017-09-29 Jakub Jelinek <jakub@redhat.com>
3815
3816 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
3817 attribute.
3818
6e3e8419
EB
38192017-09-29 Eric Botcazou <ebotcazou@adacore.com>
3820
3821 * c-ada-spec.c (to_ada_name): Add index parameter.
3822 (pp_ada_tree_identifier): Likewise.
3823 (dump_ada_macros): Adjust call to to_ada_name.
3824 (struct overloaded_name_hash): New type.
3825 (struct overloaded_name_hasher): Likewise.
3826 (overloaded_names): New hash table.
3827 (compute_overloading_index): New function.
3828 (dump_ada_decl_name): Call it and pass the result to
3829 pp_ada_tree_identifier.
3830 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
3831 (dump_ada_function_declaration): Likewise.
3832 (dump_generic_ada_node): Likewise.
3833 (print_constructor): Likewise.
3834 (print_destructor): Likewise.
3835 (dump_ada_specs): Delete overloaded_names table.
3836
79310774
EB
38372017-09-29 Eric Botcazou <ebotcazou@adacore.com>
3838
3839 * c-ada-spec.c (max_ada_macros): Move around.
3840 (store_ada_macro_index): Likewise.
3841 (source_file): Rename into...
3842 (macro_source_file): ...this.
3843 (count_ada_macro): Move around.
3844 (store_ada_macro): Likewise.
3845 (compare_macro): Likewise.
3846 (print_ada_macros): Merge in...
3847 (dump_ada_macros): ...this.
3848 (source_file_base): Rename into...
3849 (current_source_file): ...this.
3850 (print_comment): Move around.
3851 (dump_ada_nodes): Call dump_ada_declaration directly.
3852 (struct with): Change type of limited field to bool.
3853 (append_withs): Change type of limited_access parameter to bool.
3854 (pp_ada_tree_identifie): Likewise.
3855 (dump_ada_decl_nam): Likewise.
3856 (dump_generic_ada_node): Likewise. Do not print the return type.
3857 (to_ada_name): Change type of space_found parameter to bool.
3858 (dump_ada_function_declaration): Return void and change type of
3859 parameters to bool. Also print the return type for a function.
3860 (print_ada_methods): Rename into...
3861 (dump_ada_methods): ...this.
3862 (print_ada_declaration): Rename into ...
3863 (dump_ada_declaration): ...this. Do not print the return type.
3864 (print_ada_struct_decl): Rename into...
3865 (dump_ada_struct_decl): ...this.
3866
7d386d45
JJ
38672017-09-29 Jakub Jelinek <jakub@redhat.com>
3868
3869 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
3870 rather than DECL_INITIAL.
3871 (common_handle_aligned_attribute): Likewise.
3872
ab20d992 38732017-09-20 Alexandre Oliva <aoliva@redhat.com>
9ed32e27
AO
3874
3875 * c.opt (gen-decls): Add RejectNegative.
3876
026a79f7
AS
38772017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
3878 Jakub Jelinek <jakub@redhat.com>
3879
3880 Add support for -std=c++2a.
3881 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
3882 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
3883 * c-opts.c (set_std_cxx2a): New.
3884 (c_common_handle_option): Set options when -std=c++2a is enabled.
3885 (c_common_post_options): Adjust comments.
3886 (set_std_cxx14, set_std_cxx17): Likewise.
3887
4a8ca690
EB
38882017-09-15 Eric Botcazou <ebotcazou@adacore.com>
3889
3890 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
3891 message for non-uniform endianness and issue a warning in C++.
3892
7b936140
JJ
38932017-09-15 Jakub Jelinek <jakub@redhat.com>
3894
3895 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
3896 (Wc++17-compat): Change from undocumented alias to option.
3897 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
3898 change C++1z to C++17 in description.
3899 (std=c++1z, std=gnu++1z): Change from option to undocumented
3900 deprecated alias.
3901 (std=c++17, std=gnu++17): Change from undocumented alias to option.
3902 Adjust description.
3903 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
3904 * c-opts.c (set_std_cxx1z): Rename to ...
3905 (set_std_cxx17): ... this.
3906 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
3907 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
7365279f 3908 caller.
7b936140
JJ
3909 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
3910 comments.
3911
12263f13
L
39122017-09-12 H.J. Lu <hongjiu.lu@intel.com>
3913
3914 * c-attribs.c (common_handle_aligned_attribute): Don't warn
3915 function alignment if warn_if_not_aligned_p is true.
3916
6836632e
NS
39172017-09-12 Nathan Sidwell <nathan@acm.org>
3918
3919 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
3920 resort_sorted_fields): Move to c/c-decl.c.
3921 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
3922 (struct sorted_fields_type): Move to c/c-lang.h.
3923
019bf9ad
JW
39242017-09-09 Jonathan Wakely <jwakely@redhat.com>
3925
3926 PR c++/81852
3927 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
3928
bc7fe952
MP
39292017-09-04 Marek Polacek <polacek@redhat.com>
3930
3931 PR c/81783
3932 * c-warn.c (warn_tautological_bitwise_comparison): New function.
3933 (warn_tautological_cmp): Call it.
3934
ab20d992 39352017-09-01 Boris Kolpackov <boris@codesynthesis.com>
de7c2c6a
BK
3936
3937 * c-opts.c (c_common_finish): Write dependency information even if
3938 there are errors.
3939
d2e05fcb
JJ
39402017-09-01 Jakub Jelinek <jakub@redhat.com>
3941
3942 PR c/81887
3943 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
3944 (omp_pragmas_simd): ... here.
3945 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
3946 create new clauses list containing just simd clause.
3947
18e2a8b8
RS
39482017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3949 Alan Hayward <alan.hayward@arm.com>
3950 David Sherwood <david.sherwood@arm.com>
3951
3952 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
3953 into scalar_mode_supported_p call.
3954 (handle_mode_attribute): Update call to scalar_mode_supported_p.
3955
16d22000
RS
39562017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3957 Alan Hayward <alan.hayward@arm.com>
3958 David Sherwood <david.sherwood@arm.com>
3959
3960 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
3961 for the mode iterator.
3962
b397965c
RS
39632017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3964 Alan Hayward <alan.hayward@arm.com>
3965 David Sherwood <david.sherwood@arm.com>
3966
3967 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
3968 * c-common.c (c_build_vec_perm_expr): Likewise.
3969
357b7604
RS
39702017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3971 Alan Hayward <alan.hayward@arm.com>
3972 David Sherwood <david.sherwood@arm.com>
3973
3974 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
3975
e05c94ba
RS
39762017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3977 Alan Hayward <alan.hayward@arm.com>
3978 David Sherwood <david.sherwood@arm.com>
3979
3980 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
3981 before calling targetm.addr_space.valid_pointer_mode.
3982
5c20c4af
RS
39832017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3984 Alan Hayward <alan.hayward@arm.com>
3985 David Sherwood <david.sherwood@arm.com>
3986
3987 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
3988
c94843d2 39892017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
92a285c1
ML
3990 Alan Hayward <alan.hayward@arm.com>
3991 David Sherwood <david.sherwood@arm.com>
c94843d2
RS
3992
3993 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
3994 iterators.
3995 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
3996
4e10a5a7
RS
39972017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3998 Alan Hayward <alan.hayward@arm.com>
3999 David Sherwood <david.sherwood@arm.com>
4000
4001 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
4002 case statements.
4003
130fcab0
ML
40042017-08-29 Martin Liska <mliska@suse.cz>
4005
4006 PR other/39851
4007 * c-common.c (parse_optimize_options): Add argument to function
4008 call.
4009 * c-pragma.c (handle_pragma_diagnostic): Likewise.
4010
14e18d71
DM
40112017-08-24 David Malcolm <dmalcolm@redhat.com>
4012
4013 * c-lex.c (interpret_float): Use token location
4014 when building an EXCESS_PRECISION_EXPR.
4015
2f687306
DM
40162017-08-21 David Malcolm <dmalcolm@redhat.com>
4017
4018 * c-common.c (check_function_arguments): Add "arglogs" param; pass
4019 it to check_function_format.
4020 * c-common.h (check_function_arguments): Add vec<location_t> *
4021 param.
4022 (check_function_format): Likewise.
4023 * c-format.c (struct format_check_context): Add field "arglocs".
4024 (check_function_format): Add param "arglocs"; pass it to
4025 check_format_info.
ab20d992 4026 (check_format_info): Add param "arglocs"; use it to initialize
2f687306
DM
4027 new field of format_ctx.
4028 (check_format_arg): Pass format_ctx->arglocs to new param of
4029 check_format_info_main.
4030 (class argument_parser): New field "arglocs".
4031 (argument_parser::argument_parser): Add "arglocs_" param and use
4032 it to initialize new field.
4033 (argument_parser::check_argument_type): Pass new arglocs field to
4034 check_format_types.
4035 (check_format_info_main): Add param "arglocs", and use it when
4036 constructing arg_parser.
4037 (check_format_types): Add param "arglocs"; use it if non-NULL when
4038 !EXPR_HAS_LOCATION (cur_param) to get at location information.
4039
00aa1fa2
L
40402017-08-18 H.J. Lu <hongjiu.lu@intel.com>
4041
4042 PR c/53037
4043 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
4044 (c_common_attribute_table): Add warn_if_not_aligned.
4045 (handle_aligned_attribute): Renamed to ...
4046 (common_handle_aligned_attribute): Remove argument, name, and add
4047 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
4048 (handle_aligned_attribute): New.
4049 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
4050
27be025d
MS
40512017-08-14 Martin Sebor <msebor@redhat.com>
4052
4053 PR c/81117
4054 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
4055 (handle_nonstring_attribute): New function.
4056
da67acb9
MS
40572017-08-14 Martin Sebor <msebor@redhat.com>
4058
4059 PR c/81117
4060 * c-format.h (T89_G): New macro.
4061 * c-format.c (local_gcall_ptr_node): New variable.
4062 (init_dynamic_diag_info): Initialize it.
4063
a8b522b4
ML
40642017-08-11 Martin Liska <mliska@suse.cz>
4065
4066 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
4067 TARGET_SUPPORTS_ALIASES.
4068
32129a17
DM
40692017-08-10 David Malcolm <dmalcolm@redhat.com>
4070
4071 * c-common.c (c_parse_error): Add rich_location * param, using it
4072 rather implicitly using input_location.
4073 * c-common.h (c_parse_error): Add rich_location * param.
4074
30af3a2b
MP
40752017-08-09 Marek Polacek <polacek@redhat.com>
4076
4077 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
4078 (c_common_truthvalue_conversion): Likewise.
4079 * c-omp.c (c_finish_omp_atomic): Likewise.
4080 * c-common.h (build_binary_op): Update declaration.
4081
314e6352
ML
40822017-08-08 Martin Liska <mliska@suse.cz>
4083
4084 * c-ada-spec.c: Include header files.
4085 * c-ubsan.c: Likewise.
4086 * c-warn.c: Likewise.
4087
56b5041c
JJ
40882017-08-07 Jakub Jelinek <jakub@redhat.com>
4089
4090 PR c/69389
4091 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
4092
db440138
EB
40932017-08-07 Eric Botcazou <ebotcazou@adacore.com>
4094
4095 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
4096 (print_ada_methods): Likewise.
4097 (print_ada_declaration): Likewise.
4098
577eec56
ML
40992017-08-07 Martin Liska <mliska@suse.cz>
4100
4101 * array-notation-common.c: Add new includes.
4102 * c-format.c( handle_format_attribute): Canonicalize a format
4103 function name.
4104 * c-lex.c (c_common_has_attribute): Canonicalize name of an
4105 attribute.
4106 * c-pretty-print.c: Add new include.
4107
b854df3c
EB
41082017-08-05 Eric Botcazou <ebotcazou@adacore.com>
4109
4110 * c-ada-spec.c (has_static_fields): Look only into variables.
4111 (print_constructor): Add TYPE parameter and use it for the name.
4112 (print_destructor): Likewise.
4113 (print_ada_declaration): Adjust to new constructor/destructor names.
4114 Adjust calls to print_constructor and print_destructor.
4115 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
4116 Look only into variables in the final loop.
4117
9f2cb25e
EB
41182017-08-01 Eric Botcazou <ebotcazou@adacore.com>
4119
4120 * c-ada-spec.c (has_static_fields): Look only into fields.
4121 (dump_generic_ada_node): Small tweak.
4122 (dump_nested_types): Look only into fields.
4123 (print_ada_declaration): Look only into methods. Small tweak.
4124 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
4125
f4bcd9eb
EB
41262017-08-01 Eric Botcazou <ebotcazou@adacore.com>
4127
4128 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
4129 (dump_ada_function_declaration): Likewise.
4130 (dump_generic_ada_node): Likewise.
4131 (print_ada_declaration): Add support for const-qualified variables.
4132
f34ebeb2
ML
41332017-07-31 Martin Liska <mliska@suse.cz>
4134
4135 PR sanitize/81530
4136 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
4137 Guard condition with flag_sanitize_p also with current_function_decl
4138 non-null equality.
4139 (ubsan_maybe_instrument_reference_or_call): Likewise.
4140
218e5d04
UB
41412017-07-30 Uros Bizjak <ubizjak@gmail.com>
4142
4143 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
4144
942047f2
EB
41452017-07-29 Eric Botcazou <ebotcazou@adacore.com>
4146
4147 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
4148 for enumeral types.
4149 (print_ada_declaration): Add missing guard for record types.
4150
a40ff0ae
JJ
41512017-07-27 Jakub Jelinek <jakub@redhat.com>
4152
4153 PR c/45784
4154 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
4155 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
4156 new COMPOUND_EXPRs around the rhs of the comparison.
4157
06bd22f6
MP
41582017-07-27 Marek Polacek <polacek@redhat.com>
4159
4160 PR c/81417
4161 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
4162 the types.
4163
036ea399
JJ
41642017-07-27 Jakub Jelinek <jakub@redhat.com>
4165
4166 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
4167 (handle_noipa_attribute): New function.
4168
417ca011
TD
41692017-07-07 Torsten Duwe <duwe@suse.de>
4170
4171 * c-attribs.c (c_common_attribute_table): Add entry for
4172 "patchable_function_entry".
4173
5aaa8fb4
NS
41742017-07-20 Nathan Sidwell <nathan@acm.org>
4175
4176 Remove TYPE_METHODS.
4177 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
4178 dump_ada_template, print_ada_methods,
4179 print_ada_declaration): Member fns are on TYPE_FIELDS.
4180
ff22eb12
NS
41812017-07-18 Nathan Sidwell <nathan@acm.org>
4182
4183 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
4184
eea77d1f
DM
41852017-07-14 David Malcolm <dmalcolm@redhat.com>
4186
4187 * c-common.c (try_to_locate_new_include_insertion_point): New
4188 function.
4189 (per_file_includes_t): New typedef.
4190 (added_includes_t): New typedef.
4191 (added_includes): New variable.
4192 (maybe_add_include_fixit): New function.
4193 * c-common.h (maybe_add_include_fixit): New decl.
4194
281ac396
MS
41952017-07-10 Martin Sebor <msebor@redhat.com>
4196
4197 PR other/81345
4198 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
4199
b6f43128
DM
42002017-07-06 David Malcolm <dmalcolm@redhat.com>
4201
4202 * c-common.c (selftest::c_family_tests): New.
4203 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
4204 (selftest::c_family_tests): New decl.
4205
efbf55b0
MP
42062017-07-04 Marek Polacek <polacek@redhat.com>
4207
4208 PR c/81231
4209 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
4210 types.
4211
6c86bd88
MP
42122017-07-04 Marek Polacek <polacek@redhat.com>
4213
4214 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
4215
17a7218b
ML
42162017-06-28 Martin Liska <mliska@suse.cz>
4217
4218 PR ipa/81128
4219 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
4220 to a function declaration.
4221
63010089
ML
42222017-06-28 Martin Liska <mliska@suse.cz>
4223
4224 PR driver/79659
4225 * c.opt: Add IntegerRange to various options.
4226
3e2becc4
MP
42272017-06-26 Marek Polacek <polacek@redhat.com>
4228
4229 PR c/80116
4230 * c-common.h (warn_for_multistatement_macros): Declare.
4231 * c-warn.c: Include "c-family/c-indentation.h".
4232 (warn_for_multistatement_macros): New function.
4233 * c.opt (Wmultistatement-macros): New option.
4234 * c-indentation.c (guard_tinfo_to_string): No longer static.
4235 Change the parameter type to "enum rid". Handle RID_SWITCH.
4236 * c-indentation.h (guard_tinfo_to_string): Declare.
4237
2db9b7cd
MG
42382017-06-23 Marc Glisse <marc.glisse@inria.fr>
4239
4240 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
4241
c3684b7b
MS
42422017-06-15 Martin Sebor <msebor@redhat.com>
4243
4244 PR c++/80560
4245 * c.opt (-Wclass-memaccess): New option.
4246
e72c4afd
BK
42472017-06-14 Boris Kolpackov <boris@codesynthesis.com>
4248
4249 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
4250
8a516588
MP
42512017-06-13 Marek Polacek <polacek@redhat.com>
4252
4253 PR objc/80949
4254 * c-warn.c (do_warn_duplicated_branches): Return if any of the
4255 branches is null.
4256
45b2222a
ML
42572017-06-13 Martin Liska <mliska@suse.cz>
4258
4259 PR sanitize/78204
4260 * c-attribs.c (add_no_sanitize_value): New function.
4261 (handle_no_sanitize_attribute): Likewise.
4262 (handle_no_sanitize_address_attribute): Use the function.
4263 (handle_no_sanitize_thread_attribute): New function.
4264 (handle_no_address_safety_analysis_attribute): Use
4265 add_no_sanitize_value.
4266 (handle_no_sanitize_undefined_attribute): Likewise.
4267 * c-common.h: Declare new functions.
4268 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
4269 (ubsan_instrument_shift): Likewise.
4270 (ubsan_instrument_bounds): Likewise.
4271 (ubsan_maybe_instrument_array_ref): Likewise.
4272 (ubsan_maybe_instrument_reference_or_call): Likewise.
4273
a01f151f
JM
42742017-06-11 Jason Merrill <jason@redhat.com>
4275
4276 * c-ada-spec.c, c-pragma.c: Use id_equal.
4277
3de4ac6d
MP
42782017-06-04 Marek Polacek <polacek@redhat.com>
4279
4280 PR c/80919
4281 * c-format.c (matching_type_p): Return false if any of the types
4282 requires structural equality.
4283
2474f48f
MS
42842017-06-02 Martin Sebor <msebor@redhat.com>
4285
4286 PR c/80892
4287 * c-warn.c (conversion_warning): Use -Wconversion for integer
4288 conversion and -Wfloat-conversion for floating one.
4289
40ffd95f
BE
42902017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
4291
4292 * c.opt (Wsizeof-pointer-div): New warning option.
4293
3fa4634c
VR
42942017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
4295
4296 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
4297 (Wcatch-value=1): Enable by -Wall.
4298
f012c8ef
DM
42992017-05-30 David Malcolm <dmalcolm@redhat.com>
4300
4301 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
4302 format_chars.
4303 * c.opt (fdiagnostics-show-template-tree): New option.
4304 (felide-type): New option.
4305
63dbcd13
VR
43062017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
4307
4308 * c.opt (Wcatch-value=): New C++ warning flag.
4309
be136b5c
NS
43102017-05-24 Nathan Sidwell <nathan@acm.org>
4311
4312 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
4313 const casts to avoid warning.
4314
3cd211af
MS
43152017-05-24 Martin Sebor <msebor@redhat.com>
4316
4317 PR c/80731
4318 * c-common.h (unsafe_conversion_p): Add a function argument.
4319 * c-common.c (unsafe_conversion_p): Same.
4320 Add type names and values to diagnostics.
4321 (scalar_to_vector): Adjust.
4322 * c-warn.c (constant_expression_error): Add a function argument.
4323 Add type names and values to diagnostics.
4324 (conversion_warning): Add a function argument.
4325 Add type names and values to diagnostics.
4326 (warnings_for_convert_and_check): Same.
4327
1ff7be5a
JM
43282017-05-19 Jason Merrill <jason@redhat.com>
4329
4330 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
4331 enumerators.
4332
ff502317
BE
43332017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
4334
4335 * c-format.c (locus): Move out of function scope,
4336 add GTY attribute.
4337
2a8a8d7b
NS
43382017-05-19 Nathan Sidwell <nathan@acm.org>
4339
4340 * c-opts.c (class_dump_file, class_dump_flags): Delete.
4341 (c_common_parse_file): Remove class dump handling.
4342 (get_dump_info): Likewise.
4343
39aac208
RB
43442017-05-19 Richard Biener <rguenther@suse.de>
4345
4346 PR c++/80593
4347 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
4348 to alias-set zero memory.
4349
6ecd2339
BE
43502017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
4351
4352 * c-format.c (local_tree_type_node): Add GTY attribute.
4353
6574d78e
MP
43542017-05-18 Marek Polacek <polacek@redhat.com>
4355
4356 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
4357 (c_common_fixed_point_type_for_size): Likewise.
4358 (c_common_type_for_mode): Likewise.
4359 (shorten_compare): Likewise.
4360 (c_promoting_integer_type_p): Use false/true instead of 0/1.
4361 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
4362
e3455240
MP
43632017-05-18 Marek Polacek <polacek@redhat.com>
4364
4365 * c-common.c (self_promoting_args_p): Change the return type to bool.
4366 Use false/true instead of 0/1.
4367 * c-common.h (self_promoting_args_p): Update.
4368
3fa8871b
MP
43692017-05-17 Marek Polacek <polacek@redhat.com>
4370
4371 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
4372 * c-warn.c: Likewise.
4373
b42cc3ca
VV
43742017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
4375
4376 Implement new C++ intrinsics __is_assignable and __is_constructible.
4377 * c-common.c (__is_assignable, __is_constructible): New.
4378 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
4379
1a817418
ML
43802017-05-17 Martin Liska <mliska@suse.cz>
4381
4382 * c-common.h: Introduce dump_flags_t type and
4383 use it instead of int type.
4384 * c-gimplify.c (c_genericize): Likewise.
4385 * c-opts.c: Likewise.
4386
b2fa0a8b
MP
43872017-05-17 Marek Polacek <polacek@redhat.com>
4388
4389 * c-common.c (c_save_expr): Remove.
4390 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
4391 * c-common.h (c_save_expr): Remove declaration.
4392
31c2d57d
VR
43932017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
4394
4395 PR c/35441
4396 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
4397 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
4398 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
4399 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
4400 RDIV_EXPR.
4401 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
4402
684f84de
MP
44032017-05-09 Marek Polacek <polacek@redhat.com>
4404
4405 PR c/80525
4406 * c-warn.c (unwrap_c_maybe_const): New.
4407 (warn_logical_operator): Call it.
4408
641da50a
NS
44092017-05-09 Nathan Sidwell <nathan@acm.org>
4410
4411 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
4412 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
4413
631238ac
MS
44142017-05-08 Martin Sebor <msebor@redhat.com>
4415
4416 PR translation/80280
4417 * c-format.h (struct format_flag_spec): Add new member.
4418 (T89_T): New macro.
4419 * c-format.c (local_tree_type_node): New global.
4420 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
4421 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
4422 (strfmon_flag_specs): Likewise.
4423 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
4424 with distinct quoting properties.
4425 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
4426 (flag_chars_t::validate): Add argument and handle bad quoting.
4427 (check_format_info_main): Handle quoting problems.
4428 (init_dynamic_diag_info): Simplify.
4429
49f0c04c
JM
44302017-05-08 Jason Merrill <jason@redhat.com>
4431
4432 * c-opts.c (c_common_post_options): Update defaults for
4433 flag_abi_version and flag_abi_compat_version.
4434
56d35585
DM
44352017-05-05 David Malcolm <dmalcolm@redhat.com>
4436
4437 * c-common.c (c_cpp_error): Replace report_diagnostic
4438 with diagnostic_report_diagnostic.
4439
0f2c4a8f
MS
44402017-05-04 Martin Sebor <msebor@redhat.com>
4441
4442 PR translation/80280
4443 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
4444 (handle_weakref_attribute): Same.
4445
6fe63fb4
NS
44462017-05-03 Nathan Sidwell <nathan@acm.org>
4447
4448 Canonicalize canonical type hashing
4449 * c-common.c (complete_array_type): Use type_hash_canon.
4450
815d9cc6
XR
44512017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
4452
92a285c1 4453 PR c++/80038
815d9cc6
XR
4454 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
4455 prototype.
4456 (cilk_install_body_pedigree_operations): Likewise.
4457 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
4458 detatched.
4459 (cilk_gimplify_call_params_in_spawned_fn): Remove.
4460 (cilk_install_body_pedigree_operations): Likewise.
4461 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
4462 unwrapping.
4463
f8a36447
JJ
44642017-04-27 Jakub Jelinek <jakub@redhat.com>
4465
4466 PR c++/80534
4467 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
4468 flag on non-aggregate element types.
4469
7c145456
BE
44702017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
4471
4472 * c-common.c (c_type_hasher, type_hash_table): Remove.
4473 (c_common_get_alias_set): Remove unreachable code.
4474 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
4475
c3cbcd45
VR
44762017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
4477
4478 * c.opt (Wextra-semi): New C++ warning flag.
4479
8a59d466
JJ
44802017-04-20 Jakub Jelinek <jakub@redhat.com>
4481
4482 PR middle-end/80423
4483 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
4484
8487c9a5
JJ
44852017-04-18 Jakub Jelinek <jakub@redhat.com>
4486
4487 PR middle-end/79788
4488 PR middle-end/80375
4489 * c-common.c (c_common_type_for_mode): Don't handle
4490 widest_*_literal_type_node here.
4491 c_common_signed_or_unsigned_type): Likewise.
4492 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
4493 to *intTI_type_node or *intDI_type_node depending on whether
4494 TImode is supported by the target or not.
4495
3ee0fb02
ML
44962017-04-10 Martin Liska <mliska@suse.cz>
4497
4498 PR sanitizer/80350
4499 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
4500 doing an UBSAN check.
4501
5764ee3c
JW
45022017-04-03 Jonathan Wakely <jwakely@redhat.com>
4503
4504 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
4505
6f3af356
JJ
45062017-03-31 Jakub Jelinek <jakub@redhat.com>
4507
4508 PR c++/79572
4509 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
4510 tree *.
4511 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
4512 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
4513 REFERENCE_TYPE.
4514
f6a7a9d5
DM
45152017-03-31 David Malcolm <dmalcolm@redhat.com>
4516
4517 PR documentation/78732
4518 * c.opt (Wendif-labels): Fix description to refer to
4519 #else rather than #elif.
4520
af88f557
JJ
45212017-03-31 Jakub Jelinek <jakub@redhat.com>
4522
4523 PR libstdc++/80251
4524 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
4525 * c-common.c (c_common_reswords): Add __is_aggregate trait.
4526
a9e4a1a5
JJ
45272017-03-27 Jakub Jelinek <jakub@redhat.com>
4528
4529 PR middle-end/80162
4530 * c-common.c (c_common_mark_addressable_vec): Don't set
4531 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
4532
3f01b620
MS
45332017-03-21 Martin Sebor <msebor@redhat.com>
4534
4535 PR c++/79548
4536 * c-common.c (set_underlying_type): Mark type used only when
4537 original del is declared unused.
4538
2f6f187a
DM
45392017-03-10 David Malcolm <dmalcolm@redhat.com>
4540
4541 PR translation/79848
4542 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
4543 "%qs".
4544
a02fa805
DM
45452017-03-10 David Malcolm <dmalcolm@redhat.com>
4546
4547 PR c/79921
4548 * c-indentation.c (warn_for_misleading_indentation): Remove parens
4549 from inform's message, so that xgettext can locate it.
4550
822a132c
MP
45512017-03-09 Marek Polacek <polacek@redhat.com>
4552
4553 PR c++/79962
4554 PR c++/79984
4555 * c-attribs.c (handle_nonnull_attribute): Save the result of default
4556 conversion to the attribute list.
4557
bba81f1c
ML
45582017-03-09 Martin Liska <mliska@suse.cz>
4559
4560 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
4561
108154ff
JM
45622017-03-03 Jason Merrill <jason@redhat.com>
4563
4564 * c.opt (Wnoexcept-type): New.
4565
eb0e7c34
RB
45662017-03-02 Richard Biener <rguenther@suse.de>
4567
4568 PR c/79756
4569 * c-common.c (c_common_mark_addressable_vec): Look through
4570 C_MAYBE_CONST_EXPR.
4571
9453ba0a
ML
45722017-02-28 Martin Liska <mliska@suse.cz>
4573
4574 * c.opt: Replace space with tabular for options of <number>
4575 type.
4576
6a825afe
ML
45772017-02-28 Martin Liska <mliska@suse.cz>
4578
4579 * c.opt: Fix --help=option -Q for options which are of
4580 an enum type.
4581
4227c9ad
JJ
45822017-02-24 Jakub Jelinek <jakub@redhat.com>
4583
4584 PR c++/79588
4585 * c-common.c (check_function_restrict): New function.
4586 (check_function_arguments): Add FNDECL argument. Call
4587 check_function_restrict if -Wrestrict.
4588 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
4589 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
4590 * c-common.h (check_function_arguments): Add FNDECL argument.
4591 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
4592
59909673
EB
45932017-02-24 Eric Botcazou <ebotcazou@adacore.com>
4594
4595 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
4596 treatment of parameters with pointer-to-tagged type and tidy up.
4597 (print_ada_methods): Remove the special treatment of C++ static member
4598 functions.
4599
54dcd526
ML
46002017-02-22 Martin Liska <mliska@suse.cz>
4601
4602 * c.opt: Replace inequality signs with square brackets
4603 for -Wnornalized.
4604
00bc9de3
JJ
46052017-02-21 Jakub Jelinek <jakub@redhat.com>
4606
4607 PR c++/79641
4608 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
4609 preserve quals.
4610
97fcf744
JM
46112017-02-17 Joseph Myers <joseph@codesourcery.com>
4612
4613 * c-cppbuiltin.c (builtin_define_float_constants): Define
4614 __DECIMAL_DIG__ to the value for long double.
4615
c7545f1c
MP
46162017-02-15 Marek Polacek <polacek@redhat.com>
4617
4618 PR c/79515
4619 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
4620 conversion has occured.
4621
c2e84327
DM
46222017-01-24 David Malcolm <dmalcolm@redhat.com>
4623
4624 * c-common.c (c_common_reswords): Add "__RTL".
4625 * c-common.h (enum rid): Add RID_RTL.
4626
2ebd93e1
MP
46272017-01-20 Marek Polacek <polacek@redhat.com>
4628
4629 PR c/64279
4630 * c-common.h (do_warn_duplicated_branches_r): Declare.
4631 * c-gimplify.c (c_genericize): Walk the function tree calling
4632 do_warn_duplicated_branches_r.
4633 * c-warn.c (expr_from_macro_expansion_r): New.
4634 (do_warn_duplicated_branches): New.
4635 (do_warn_duplicated_branches_r): New.
4636 * c.opt (Wduplicated-branches): New option.
4637
0d80ab91
DM
46382017-01-17 David Malcolm <dmalcolm@redhat.com>
4639
4640 PR c++/71497
4641 * c-indentation.c (warn_for_misleading_indentation): Use the past
4642 subjunctive in the note.
4643
7f991c36
AH
46442017-01-17 Aldy Hernandez <aldyh@redhat.com>
4645
4646 PR c/79116
4647 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
4648 start type to integer_type.
4649
1c70261c
JJ
46502017-01-16 Jakub Jelinek <jakub@redhat.com>
4651
4652 PR driver/49726
4653 * c.opt (gen-decls): Add Driver flag.
4654
1ddca3f3
PC
46552017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
4656
4657 Revert:
4658 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
4659
4660 PR c++/71737
4661 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
4662
7d2f3f1d
PC
46632017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
4664
4665 PR c++/71737
4666 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
4667
bce6f760
MS
46682017-01-12 Martin Sebor <msebor@redhat.com>
4669
4670 (-Wformat-overflow): ...to this.
4671
bf5fbf46
MS
46722017-01-11 Martin Sebor <msebor@redhat.com>
4673
4674 PR c/78768
4675 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
4676 Also enable for LTO.
4677
e363df3f
JM
46782017-01-10 Jason Merrill <jason@redhat.com>
4679
4680 Implement P0195R2, C++17 variadic using.
4681 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
4682
bd2c6270
JJ
46832017-01-09 Jakub Jelinek <jakub@redhat.com>
4684
4685 PR translation/79019
4686 PR translation/79020
4687 * c.opt (Wnormalized=): Fix typo in description.
4688
efcc8d38
MS
46892017-01-08 Martin Sebor <msebor@redhat.com>
4690
4691 PR middle-end/77708
4692 * c.opt (-Wformat-truncation): New option.
4693
ab20d992 46942017-01-06 Alexandre Oliva <aoliva@redhat.com>
435f3f7a
AO
4695
4696 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
4697 value to unsigned short to fit in 4 hex digits without
4698 warnings.
4699
4e89adf9
EB
47002017-01-05 Eric Botcazou <ebotcazou@adacore.com>
4701
4702 * c.opt (fsso-struct): Add 'native' value.
4703
cd445b54
ML
47042017-01-05 Martin Liska <mliska@suse.cz>
4705
4706 PR pch/78970
4707 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
4708 header.
4709
a9342885
MP
47102017-01-04 Marek Polacek <polacek@redhat.com>
4711
4712 PR c++/64767
4713 * c.opt (Wpointer-compare): New option.
4714
fc73e60c
JJ
47152017-01-04 Jakub Jelinek <jakub@redhat.com>
4716
4717 PR driver/78957
4718 * c.opt (fsso-struct=): Add RejectNegative.
4719
cbe34bb5
JJ
47202017-01-01 Jakub Jelinek <jakub@redhat.com>
4721
4722 Update copyright years.
4723
d4a6c0ea
ML
47242016-12-29 Martin Liska <mliska@suse.cz>
4725
4726 PR c/78933
4727 * c.opt (strong-eval-order): Add RejectNegative keyword.
4728
67a5ad7c
JM
47292016-12-22 Jason Merrill <jason@redhat.com>
4730
4731 Implement P0522R0, matching of template template arguments.
4732 * c-cppbuiltin.c (c_cpp_builtins): Define
4733 __cpp_template_template_args.
4734
0dba7960
JJ
47352016-12-21 Jakub Jelinek <jakub@redhat.com>
4736
4737 PR bootstrap/78817
4738 * c-common.c (struct nonnull_arg_ctx): New type.
4739 (check_function_nonnull): Return bool instead of void. Use
4740 nonnull_arg_ctx as context rather than just location_t.
4741 (check_nonnull_arg): Adjust for the new context type, set
4742 warned_p to true if a warning has been diagnosed.
4743 (check_function_arguments): Return bool instead of void.
4744 * c-common.h (check_function_arguments): Adjust prototype.
4745
31bfc9b9
JM
47462016-12-21 Jason Merrill <jason@redhat.com>
4747
4748 * c.opt (-fnew-ttp-matching): New flag.
4749 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
4750
629b3d75
MJ
47512016-12-14 Martin Jambor <mjambor@suse.cz>
4752
4753 * c-omp.c: Include omp-general.h instead of omp-low.h.
4754 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
4755 name.
4756
474da67e
MS
47572016-12-14 Martin Sebor <msebor@redhat.com>
4758
4759 PR c/17308
4760 * c-common.c (check_nonnull_arg): Disable when optimization
4761 is enabled.
4762
fe366b87
MP
47632016-12-12 Marek Polacek <polacek@redhat.com>
4764
4765 PR c++/78647
4766 * c-common.c (attribute_fallthrough_p): Return false for
4767 error_mark_node.
4768
8bd9f164
MS
47692016-12-08 Martin Sebor <msebor@redhat.com>
4770
4771 PR c/78284
4772 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
4773
060162e0
MS
47742016-12-08 Martin Sebor <msebor@redhat.com>
4775
4776 PR c/78165
92a285c1
ML
4777 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
4778 suffix.
060162e0 4779
ee92e7ba
MS
47802016-12-07 Martin Sebor <msebor@redhat.com>
4781
4782 PR c/53562
4783 PR middle-end/77784
4784 PR middle-end/78149
4785 PR middle-end/78138
4786 * c.opt (-Wstringop-overflow): New option.
4787
84b0769e
MO
47882016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
4789
4790 * c-attribs.c (asan odr indicator): New attribute.
4791 (handle_asan_odr_indicator_attribute): New function.
4792
7fa6a965
PK
47932016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4794
4795 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
4796 ptrdiff_type_node;
4797
56d8ffc1
JG
47982016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
4799
4800 * c-common.c (excess_precision_mode_join): New.
4801 (c_ts18661_flt_eval_method): New.
4802 (c_c11_flt_eval_method): Likewise.
4803 (c_flt_eval_method): Likewise.
4804 * c-common.h (excess_precision_mode_join): New.
4805 (c_flt_eval_method): Likewise.
4806 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
4807 (cpp_iec_559_value): Call it.
4808 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
4809 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
4810 __FLT_EVAL_METHOD_TS_18661_3__.
4811
04f0fcf7
JG
48122016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
4813
4814 * c-opts.c (c_common_post_options): Add logic to handle the default
4815 case for -fpermitted-flt-eval-methods.
4816
fb2675cb
PB
48172016-11-23 Paolo Bonzini <bonzini@gnu.org>
4818
4819 * c.opt (Wexpansion-to-defined): New.
4820
ec1c5694
JJ
48212016-11-23 Jakub Jelinek <jakub@redhat.com>
4822
4823 PR target/78451
4824 * c-pragma.c (handle_pragma_target): Don't replace
4825 current_target_pragma, but chainon the new args to the current one.
4826
730c9e75
NS
48272016-11-22 Nathan Sidwell <nathan@acm.org>
4828
4829 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
cacd29be 4830 indentation and formatting.
730c9e75 4831
89990732
MS
48322016-11-21 Martin Sebor <msebor@redhat.com>
4833
4834 * c.opt (-fprintf-return-value): Enable by default.
4835
48330c93
BE
48362016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
4837
4838 PR c++/71973
4839 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
4840 * c-common.c (c_common_nodes_and_builtins): Initialize
4841 const_tm_ptr_type_node.
4842
0d939c95
MP
48432016-11-16 Marek Polacek <polacek@redhat.com>
4844
4845 PR c/78285
4846 * c-common.c (c_add_case_label): Turn error_at calls into inform.
4847
8e745a17
JJ
48482016-11-14 Jakub Jelinek <jakub@redhat.com>
4849
4850 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
4851
1ee62b92 48522016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
8e745a17
JJ
4853 Richard Biener <rguenther@suse.de>
4854
4855 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
4856 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
4857 * c.opt (fgimple): New option.
1ee62b92 4858
22b15758
UB
48592016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4860
4861 PR c/35503
4862 * c-common.h (warn_for_restrict): Declare.
4863 * c-warn.c: Include gcc-rich-location.h.
4864 (warn_for_restrict): New function.
4865 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
4866 (gcc_cdiag_char_table): Likewise.
4867 (gcc_cxxdiag_char_table): Likewise.
4868 * c.opt (Wrestrict): New option.
4869
4be719cd
EB
48702016-11-13 Eric Botcazou <ebotcazou@adacore.com>
4871
4872 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
4873 for nested types only if the type is a record or union and dump SLOC.
4874
4a826ca6
JM
48752016-11-09 Jason Merrill <jason@redhat.com>
4876
4877 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
4878
2e955d50
JJ
48792016-11-09 Jakub Jelinek <jakub@redhat.com>
4880
4881 * c-ubsan.c (ubsan_instrument_shift): Handle split
4882 -fsanitize=shift-base and -fsanitize=shift-exponent.
4883
51dc6603
JM
48842016-11-07 Jason Merrill <jason@redhat.com>
4885
4886 * c.opt (Wc++1z-compat): New.
4887 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
4888
6dc4a604
ML
48892016-11-07 Martin Liska <mliska@suse.cz>
4890
4891 * c-warn.c (warn_for_unused_label): Save all labels used
4892 in goto or in &label.
4893
b302001e
JM
48942016-11-03 Jason Merrill <jason@redhat.com>
4895
4896 * c-cppbuiltin.c (c_cpp_builtins): Correct
4897 __cpp_inheriting_constructors.
4898
31f7f784
JM
48992016-11-01 Jason Merrill <jason@redhat.com>
4900
2bc78e3c
JM
4901 * c-cppbuiltin.c (c_cpp_builtins): Update
4902 __cpp_inheriting_constructors.
4903
31f7f784
JM
4904 * c.opt (-fnew-inheriting-ctors): New.
4905 * c-opts.c: Default to on for ABI 11+.
4906
dcb466ec
JJ
49072016-10-31 Jakub Jelinek <jakub@redhat.com>
4908
4909 PR c++/77948
4910 * c.opt (fext-numeric-literals): Add Var and Init.
4911 * c-opts.c (c_common_handle_option): Don't clear
4912 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
4913 (c_common_post_options): Clear it here if not set
4914 explicitly.
4915
52e1b91e
AH
49162016-10-28 Aldy Hernandez <aldyh@redhat.com>
4917
4918 PR debug/77773
4919 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
4920 if NULL.
4921
e16f1cc7
JJ
49222016-10-25 Jakub Jelinek <jakub@redhat.com>
4923
4924 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
4925 * c-common.c (c_common_reswords): Add __builtin_launder.
4926
f8348061
BE
49272016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
4928
4929 * c-common.c (c_common_truthvalue_conversion): Warn for
4930 multiplications in boolean context. Fix the quoting of '<<' and '<'
4931 in the shift warning.
4932
eff89e01
BE
49332016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
4934
4935 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
4936
24bc7bf4
JM
49372016-10-20 Jason Merrill <jason@redhat.com>
4938
4939 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
4940
4c712374
BE
49412016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
4942
4943 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
4944 integer shift ops in boolean context.
4945
49462016-10-18 Aldy Hernandez <aldyh@redhat.com>
adc577c5
AH
4947
4948 * c.opt (Walloca): New.
4949 (Walloca-larger-than=): New.
4950 (Wvla-larger-than=): New.
4951
8fa18c06
MP
49522016-10-17 Marek Polacek <polacek@redhat.com>
4953
4954 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
4955 Return immediately when finding a match.
4956 (warn_tautological_cmp): Remove a boolean variable that is no longer
4957 needed.
4958
b12b1915
MP
49592016-10-17 Marek Polacek <polacek@redhat.com>
4960
4961 * c-attribs.c: New file.
4962 * c-common.c: Move attributes handling to c-attribs.c.
4963 (get_nonnull_operand): No longer static.
4964 * c-common.h: Move the declarations from c-attribs.c to its own section.
4965
2045acd9
JM
49662016-10-14 Jason Merrill <jason@redhat.com>
4967
4968 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
4969 and __cpp_deduction_guides.
4970
14a2c9aa
JM
49712016-10-13 Jason Merrill <jason@redhat.com>
4972
4973 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
4974
4d0cdd0c
TP
49752016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
4976
4977 * c-cppbuiltin.c: Include memmodel.h.
4978 * c-opts.c: Likewise.
4979 * c-pragma.c: Likewise.
4980 * c-warn.c: Likewise.
4981
70f6d5e1
JJ
49822016-10-12 Jakub Jelinek <jakub@redhat.com>
4983
4984 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
4985 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
4986 * c-opts.c (sanitize_cpp_opts): Initialize
4987 cpp_opts->cpp_warn_implicit_fallthrough.
4988
78f61294
MP
49892016-10-11 Marek Polacek <polacek@redhat.com>
4990
4991 * c-common.c (warning_candidate_p): Change the return type to bool
4992 and return true/false instead of 1/0.
4993 (vector_mode_valid_p): Likewise.
4994
038b5cc0
MP
49952016-10-11 Marek Polacek <polacek@redhat.com>
4996
4997 * c-common.c (fold_for_warn): No longer static.
4998 (bool_promoted_to_int_p): Likewise.
4999 (c_common_get_narrower): Likewise.
5000 (constant_expression_warning): Move to c-warn.c.
5001 (constant_expression_error): Likewise.
5002 (overflow_warning): Likewise.
5003 (warn_logical_operator): Likewise.
5004 (find_array_ref_with_const_idx_r): Likewise.
5005 (warn_tautological_cmp): Likewise.
5006 (expr_has_boolean_operands_p): Likewise.
5007 (warn_logical_not_parentheses): Likewise.
5008 (warn_if_unused_value): Likewise.
5009 (strict_aliasing_warning): Likewise.
5010 (sizeof_pointer_memaccess_warning): Likewise.
5011 (check_main_parameter_types): Likewise.
5012 (conversion_warning): Likewise.
5013 (warnings_for_convert_and_check): Likewise.
5014 (match_case_to_enum_1): Likewise.
5015 (match_case_to_enum): Likewise.
5016 (c_do_switch_warnings): Likewise.
5017 (warn_for_omitted_condop): Likewise.
5018 (readonly_error): Likewise.
5019 (lvalue_error): Likewise.
5020 (invalid_indirection_error): Likewise.
5021 (warn_array_subscript_with_type_char): Likewise.
5022 (warn_about_parentheses): Likewise.
5023 (warn_for_unused_label): Likewise.
5024 (warn_for_div_by_zero): Likewise.
5025 (warn_for_memset): Likewise.
5026 (warn_for_sign_compare): Likewise.
5027 (do_warn_double_promotion): Likewise.
5028 (do_warn_unused_parameter): Likewise.
5029 (record_locally_defined_typedef): Likewise.
5030 (maybe_record_typedef_use): Likewise.
5031 (maybe_warn_unused_local_typedefs): Likewise.
5032 (maybe_warn_bool_compare): Likewise.
5033 (maybe_warn_shift_overflow): Likewise.
5034 (warn_duplicated_cond_add_or_warn): Likewise.
5035 (diagnose_mismatched_attributes): Likewise.
5036 * c-common.h: Move the declarations from c-warn.c to its own section.
5037 * c-warn.c: New file.
5038
627be19f
JM
50392016-10-08 Jason Merrill <jason@redhat.com>
5040
5041 * c-common.c (c_common_truthvalue_conversion): Don't distribute
5042 into COND_EXPR in C++.
5043
7bad794a
JJ
50442016-10-08 Jakub Jelinek <jakub@redhat.com>
5045
5046 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
5047 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
5048 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
5049
be845b04
JJ
50502016-10-07 Jakub Jelinek <jakub@redhat.com>
5051
5052 Implement LWG2296 helper intrinsic
5053 * c-common.h (enum rid): Add RID_ADDRESSOF.
5054 * c-common.c (c_common_reswords): Add __builtin_addressof.
5055
c09c4992
BE
50562016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
5057
5058 PR c++/77700
5059 * c-common.c (c_common_truthvalue_conversion): Warn also for
5060 suspicious enum values in boolean context.
5061
342cfb3e
JJ
50622016-10-06 Jakub Jelinek <jakub@redhat.com>
5063
5064 Implement P0258R2 - helper for C++17
5065 std::has_unique_object_representations trait
5066 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
5067 * c-common.c (c_common_reswords): Add
5068 __has_unique_object_representations.
5069
2e69f143
JJ
50702016-10-05 Jakub Jelinek <jakub@redhat.com>
5071
5072 PR sanitizer/66343
5073 * c-ubsan.c (ubsan_instrument_return): Don't call
5074 initialize_sanitizer_builtins here.
5075
700fff34
BE
50762016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
5077
5078 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
5079 conditional expression in boolean context when only one arm is
5080 non-boolean.
5081
9563bfcd
JJ
50822016-10-05 Jakub Jelinek <jakub@redhat.com>
5083
04a32443
JJ
5084 PR sanitizer/77823
5085 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
5086 is not integral.
5087
9563bfcd
JJ
5088 * c-common.c (c_common_reswords): Update comment for C++11.
5089
f1644724
JM
50902016-10-04 Jason Merrill <jason@redhat.com>
5091
5092 * c-common.c (make_tree_vector_from_ctor): New.
5093 * c-common.h: Declare it.
5094
5a79befb
JJ
50952016-10-04 Jakub Jelinek <jakub@redhat.com>
5096
5097 * c-cppbuiltin.c (c_cpp_builtins): Don't define
5098 __LIBGCC_JCR_SECTION_NAME__.
5099
1633d3b9
BE
51002016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
5101
5102 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
5103 left shift in boolean context.
5104
a2c6e7f2
JJ
51052016-09-29 Jakub Jelinek <jakub@redhat.com>
5106
5107 Implement P0001R1 - C++17 removal of register storage class specifier
5108 * c.opt (Wregister): New warning.
5109 * c-opts.c (c_common_post_options): Enable -Wregister by
5110 default for C++17.
5111
75304c87
JG
51122016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
5113
5114 * c-opts.c (c_common_post_options): Remove special case for
5115 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
5116 in C++.
5117
bbfac6da
JJ
51182016-09-27 Jakub Jelinek <jakub@redhat.com>
5119
6e39060a
JJ
5120 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
5121 -std=c++1z.
5122
bbfac6da
JJ
5123 * c-ada-spec.c (print_ada_declaration): Remove break after return.
5124
e73cf9a2
TP
51252016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
5126
5127 * c-common.c: Include memmodel.h.
5128
c6147dc4
MP
51292016-09-26 Marek Polacek <polacek@redhat.com>
5130
5131 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
5132
81fea426
MP
51332016-09-26 Marek Polacek <polacek@redhat.com>
5134
5135 PR c/7652
5136 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
5137 (handle_fallthrough_attribute): New function.
5138 (attribute_fallthrough_p): New function.
5139 * c-common.h (attribute_fallthrough_p): Declare.
5140
9a2300e9
MP
51412016-09-24 Marek Polacek <polacek@redhat.com>
5142
5143 PR c/77490
5144 * c.opt (Wbool-operation): New.
5145
a09e9e35
BE
51462016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
5147
5148 * c-common.c (c_common_truthvalue_conversion): Inhibit
5149 Wint-in-bool-context warning with from_macro_definition_at.
5150 Mention the expression will always evaluate to true.
5151
d43b4ccc
MS
51522016-09-21 Martin Sebor <msebor@redhat.com>
5153
5154 PR bootstrap/77676
5155 * c.opt (fprintf-return-value): Temporarily initialize to zero
5156 to unblock bootstrap failures.
5157
2e1c20b1
JJ
51582016-09-21 Jakub Jelinek <jakub@redhat.com>
5159
5160 PR c++/77651
5161 * c.opt (Waligned-new=): Add RejectNegative.
5162 (faligned-new=): Likewise. Spelling fix - change
5163 aligned_new_threshhold to aligned_new_threshold.
5164 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
5165 to aligned_new_threshold.
5166
88d0c3f0
MS
51672016-09-20 Martin Sebor <msebor@redhat.com>
5168
5169 PR middle-end/49905
5170 * c.opt: Add -Wformat-length and -fprintf-return-value.
5171
144a96e4
BE
51722016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
5173
5174 PR c++/77434
5175 * c.opt (Wint-in-bool-context): New warning.
5176 * c-common.c (c_common_truthvalue_conversion): Warn on integer
5177 constants in boolean context.
5178
63012d9a
JM
51792016-09-19 Joseph Myers <joseph@codesourcery.com>
5180
5181 * c-common.c (max_align_t_align): Also consider alignment of
5182 float128_type_node.
5183
931388ce
JM
51842016-09-15 Jason Merrill <jason@redhat.com>
5185
5186 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
5187 DECL_EXTERNAL.
5188
38711381
JM
51892016-09-14 Jason Merrill <jason@redhat.com>
5190
5191 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
5192 limit FIELD_DECL, either.
5193
e51fbec3
MP
51942016-09-14 Marek Polacek <polacek@redhat.com>
5195
5196 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
5197 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
5198 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
5199
254830ba
DM
52002016-09-13 David Malcolm <dmalcolm@redhat.com>
5201
5202 * c-common.c (warn_logical_not_parentheses): Replace
5203 rich_location::add_fixit_insert calls with add_fixit_insert_before
5204 and add_fixit_insert_after, eliminating the "next_loc" calculation.
5205
42763690
JM
52062016-09-13 Jason Merrill <jason@redhat.com>
5207 Tom de Vries <tom@codesourcery.com>
5208
5209 PR c++/77427
5210 * c-common.c (set_underlying_type): Don't treat array as builtin type.
5211
9453eee9
JM
52122016-09-13 Jason Merrill <jason@redhat.com>
5213
5214 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
5215 limit types at all.
5216
e96809e3
JM
52172016-09-12 Jason Merrill <jason@redhat.com>
5218
5219 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
5220 bit/byte confusion, allow large alignment for types.
5221
54dcdb88
BE
52222016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
5223
5224 PR c++/77496
5225 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
5226
d1463eb9
DM
52272016-09-12 David Malcolm <dmalcolm@redhat.com>
5228
5229 PR c/72858
5230 * c-format.c (argument_parser::check_argument_type): Add params
5231 "type_start" and "conversion_char". Use the former to generate
5232 offset_to_type_start and pass it and conversion_char to
5233 check_format_types.
5234 (check_format_info_main): Capture the start of the type
5235 information as "type_start", and pass it an format_char
5236 to arg_parser.check_argument_type.
5237 (check_format_types): Provide an example in the leading comment.
5238 Add params "offset_to_type_start" and "conversion_char"; pass
5239 them to format_type_warning calls.
5240 (test_get_modifier_for_format_len): Likewise.
5241 (matching_type_p): New function.
5242 (get_format_for_type): Add param "conversion_char" and move
5243 implementation into...
5244 (get_format_for_type_1): ...new function, called twice.
5245 Use new function matching_type_p rather than checking for
5246 TYPE_CANONICAL equality.
5247 (get_corrected_substring): New function.
5248 (format_type_warning): Provide an example in the leading comment.
5249 Add params "offset_to_type_start" and "conversion_char". Replace
5250 call to get_format_for_type with call to get_corrected_substring
5251 and move rejection of hints for widths/precisions there.
5252 (assert_format_for_type_streq): Add param "conversion_char".
5253 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
5254 (test_get_format_for_type_printf): Add conversion chars to the
5255 tests, adding coverage for various combinations of integer
5256 vs double conversions, and for preserving octal and hexadecimal
5257 conversions.
5258 (test_get_format_for_type_scanf): Add conversion chars to the
5259 tests.
5260
5b28efbb
TV
52612016-09-10 Tom de Vries <tom@codesourcery.com>
5262
5263 PR C/71602
5264 * c-common.c (build_va_arg): Handle more strict
5265 targetm.canonical_va_list_type. Replace first argument type error with
5266 assert.
5267
3f0177e7
MS
52682016-09-09 Martin Sebor <msebor@redhat.com>
5269
5270 PR c/77520
5271 PR c/77521
5272 * c-format.c (argument_parser::find_format_char_info): Use %qc
5273 format directive unconditionally.
5274
af63ba4b
JM
52752016-09-09 Jason Merrill <jason@redhat.com>
5276
5277 Implement C++17 new of over-aligned types.
5278 * c.opt: Add -faligned-new and -Waligned-new.
5279 * c-common.c (max_align_t_align): Split out from...
5280 (cxx_fundamental_alignment_p): ...here.
5281 * c-common.h: Declare it.
5282 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
5283
c65248cb
JM
52842016-09-09 Joseph Myers <joseph@codesourcery.com>
5285
5286 * c-cppbuiltin.c (builtin_define_type_width): New function.
5287 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
5288 macros.
5289
e5106e27
DM
52902016-09-07 David Malcolm <dmalcolm@redhat.com>
5291
5292 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
5293 a POINTER_TYPE.
5294 (substring_loc::get_location): Move to substring-locations.c,
5295 keeping implementation as...
5296 (c_get_substring_location): New function, from the above, reworked
5297 to use accessors rather than member lookup.
5298 * c-common.h (class substring_loc): Move to substring-locations.h,
5299 replacing with a forward decl.
5300 (c_get_substring_location): New decl.
5301 * c-format.c: Include "substring-locations.h".
5302 (format_warning_va): Move to substring-locations.c.
5303 (format_warning_at_substring): Likewise.
5304
ab20d992 53052016-09-06 Martin Sebor <msebor@redhat.com>
a42e7952
MS
5306
5307 PR c/77336
5308 * c-format.c (check_function_format): Avoid issuing warnings for
5309 functions unless they call format functions with non-constant
5310 format strings.
5311
b772a565
RB
53122016-09-06 Richard Biener <rguenther@suse.de>
5313
5314 PR c/77450
5315 * c-common.c (c_common_mark_addressable_vec): Handle
5316 COMPOUND_LITERAL_EXPR.
5317
25ff5dd3
MP
53182016-09-05 Marek Polacek <polacek@redhat.com>
5319
5320 PR c/77423
5321 * c-common.c (bool_promoted_to_int_p): New function.
5322 (expr_has_boolean_operands_p): New function.
5323 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
5324 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
5325
21234eb5
TV
53262016-09-04 Tom de Vries <tom@codesourcery.com>
5327
5328 revert:
5329 2016-08-29 Tom de Vries <tom@codesourcery.com>
5330
5331 * c-common.c (build_va_arg): Replace first argument type error
5332 with assert.
5333
9dc5773f
JJ
53342016-09-02 Jakub Jelinek <jakub@redhat.com>
5335
5336 PR c/65467
5337 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
5338 (c_finish_omp_for): Reject _Atomic qualified iterators.
5339
53402016-09-01 Martin Sebor <msebor@redhat.com>
3d7b83b6
MS
5341
5342 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
5343 size to guarantee it fits the output of the formatted function
5344 regardless of its arguments.
5345
295844f6
MP
53462016-09-01 Marek Polacek <polacek@redhat.com>
5347
5348 PR c/7652
5349 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
5350 FALLTHRU comments.
5351
3d06b6f2
MP
53522016-08-29 Marek Polacek <polacek@redhat.com>
5353
5354 PR c/77292
5355 * c-common.c (warn_logical_not_parentheses): Don't warn for
5356 a comparison or a logical operator.
5357
34cedad5
TV
53582016-08-29 Tom de Vries <tom@codesourcery.com>
5359
5360 * c-common.c (build_va_arg): Fix type comparison assert.
5361
f162d717
TV
53622016-08-29 Tom de Vries <tom@codesourcery.com>
5363
5364 * c-common.c (build_va_arg): Replace first argument type error
5365 with assert.
5366
ba9bbd6f
TV
53672016-08-29 Tom de Vries <tom@codesourcery.com>
5368
5369 PR c/77398
5370 * c-common.c (build_va_arg): Add first argument error. Build va_arg
5371 with error_mark_node as va_list instead of with illegal va_list.
5372
ebef225f
MP
53732016-08-25 Marek Polacek <polacek@redhat.com>
5374 David Malcolm <dmalcolm@redhat.com>
5375
5376 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
5377 * c-common.h (warn_logical_not_parentheses): Update declaration.
5378
b00e6e75
MP
53792016-08-22 Marek Polacek <polacek@redhat.com>
5380
5381 PR c++/77321
5382 * c-common.c (warn_for_memset): Check type for null.
5383
6dc198e3
JM
53842016-08-22 Joseph Myers <joseph@codesourcery.com>
5385
14ec014e 5386 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
6dc198e3
JM
5387 _FloatNx types for suffixes for built-in functions.
5388
c65699ef
JM
53892016-08-19 Joseph Myers <joseph@codesourcery.com>
5390
5391 PR c/32187
5392 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
5393 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
5394 (RID_FLOAT128X): New enum rid values.
5395 (CASE_RID_FLOATN_NX): New macro.
5396 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
5397 keywords.
5398 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
5399 corresponding complex types.
5400 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
5401 _FloatNx and corresponding complex types.
5402 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
5403 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
5404 and _FloatNx types for the widest type for determining
5405 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
5406 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
5407 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
5408 and _FloatNx types.
5409 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
5410 constants.
5411 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
5412 _FloatNx types.
5413
cc015f3a
DM
54142016-08-18 David Malcolm <dmalcolm@redhat.com>
5415
5416 * c-opts.c (c_diagnostic_finalizer): Update for change to
5417 diagnostic_show_locus.
5418
cb18fd07
DM
54192016-08-18 David Malcolm <dmalcolm@redhat.com>
5420
5421 * c-common.c: Include "spellcheck.h".
5422 (cb_get_suggestion): New function.
5423 * c-common.h (cb_get_suggestion): New decl.
5424 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
5425 cb_get_suggestion.
5426
a76989dc
MP
54272016-08-18 Marek Polacek <polacek@redhat.com>
5428
5429 PR c/71514
5430 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
5431 and pointer-to-VLA.
5432
65e736c0
DM
54332016-08-16 David Malcolm <dmalcolm@redhat.com>
5434
5435 PR c/72857
5436 * c-common.c (substring_loc::get_range): Rename to...
5437 (substring_loc::get_location): ...this, converting param from a
5438 source_range * to a location_t *. Call
5439 get_source_location_for_substring rather than
5440 get_source_range_for_substring, and pass in m_caret_idx.
5441 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
5442 (substring_loc::get_range): Replace with...
5443 (substring_loc::get_location): ...this.
5444 (substring_loc::set_caret_index): New method.
5445 (substring_loc): Add field m_caret_idx.
5446 * c-format.c (format_warning_va): Update for above changes.
5447 Rename local "substring_loc" to "fmt_substring_loc" to avoid
5448 clashing with type name.
5449 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
5450 (check_argument_type): Likewise.
5451 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
5452 Use a copy when emitting warnings, setting the caret index from TYPE.
5453
7e1dde14 54542016-08-16 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 5455 Arnaud Charlet <charlet@adacore.com>
7e1dde14
EB
5456
5457 * c-ada-spec.c (dump_number): New function.
5458 (handle_escape_character): Likewise.
5459 (print_ada_macros): Add handling of constant integers and strings.
5460
191816a3
MP
54612016-08-12 Marek Polacek <polacek@redhat.com>
5462
5463 PR c/7652
5464 * c-common.c (scalar_to_vector): Adjust fall through comment.
5465 * c-opts.c (c_common_handle_option): Likewise.
5466 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
5467 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
5468 fall through comment.
5469 * cilk.c (extract_free_variables): Add FALLTHRU.
5470
452df4a4
JM
54712016-08-10 Jason Merrill <jason@redhat.com>
5472
5473 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
5474
f3365c12
JM
54752016-08-09 Jason Merrill <jason@redhat.com>
5476
5477 * c-common.c (c_common_attribute_table): vector_size affects type
5478 identity.
5479
f0bc3323
MP
54802016-08-09 Marek Polacek <polacek@redhat.com>
5481
5482 PR c/7652
5483 * c-ada-spec.c (dump_generic_ada_node): Add return.
5484
98e5a19a
JM
54852016-08-09 Jason Merrill <jason@redhat.com>
5486
5487 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
5488 C++17 constexpr lambdas.
5489
895aa8e1
DM
54902016-08-08 David Malcolm <dmalcolm@redhat.com>
5491
5492 PR c/64955
5493 * c-common.h (selftest::c_format_c_tests): New declaration.
5494 (selftest::run_c_tests): New declaration.
5495 * c-format.c: Include "selftest.h.
5496 (format_warning_va): Add param "corrected_substring" and use
5497 it to add a replacement fix-it hint.
5498 (format_warning_at_substring): Likewise.
5499 (format_warning_at_char): Update for new param of
5500 format_warning_va.
5501 (argument_parser::check_argument_type): Pass "fki" to
5502 check_format_types.
5503 (check_format_types): Add param "fki" and pass it to
5504 format_type_warning.
5505 (deref_n_times): New function.
5506 (get_modifier_for_format_len): New function.
5507 (selftest::test_get_modifier_for_format_len): New function.
5508 (get_format_for_type): New function.
5509 (format_type_warning): Add param "fki" and use it to attempt
5510 to provide hints for argument types when calling
5511 format_warning_at_substring.
5512 (selftest::get_info): New function.
5513 (selftest::assert_format_for_type_streq): New function.
5514 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
5515 (selftest::test_get_format_for_type_printf): New function.
5516 (selftest::test_get_format_for_type_scanf): New function.
5517 (selftest::c_format_c_tests): New function.
5518
e52ed3fe
DM
55192016-08-08 David Malcolm <dmalcolm@redhat.com>
5520
5521 PR c/52952
5522 * c-format.c: Include "diagnostic.h".
5523 (location_column_from_byte_offset): Delete.
5524 (location_from_offset): Delete.
5525 (format_warning_va): New function.
5526 (format_warning_at_substring): New function.
5527 (format_warning_at_char): New function.
5528 (check_format_arg): Capture location of format_tree and pass to
5529 check_format_info_main.
5530 (argument_parser): Add fields "start_of_this_format" and
5531 "format_string_cst".
5532 (flag_chars_t::validate): Add param "format_string_cst". Convert
5533 warning_at call using location_from_offset to call to
5534 format_warning_at_char.
5535 (argument_parser::argument_parser): Add param "format_string_cst_"
5536 and use use it to initialize field "format_string_cst".
5537 Initialize new field "start_of_this_format".
5538 (argument_parser::read_format_flags): Convert warning_at call
5539 using location_from_offset to a call to format_warning_at_char.
5540 (argument_parser::read_any_format_left_precision): Likewise.
5541 (argument_parser::read_any_format_precision): Likewise.
5542 (argument_parser::read_any_other_modifier): Likewise.
5543 (argument_parser::find_format_char_info): Likewise, in three places.
5544 (argument_parser::parse_any_scan_set): Likewise, in one place.
5545 (argument_parser::handle_conversions): Likewise, in two places.
5546 (argument_parser::check_argument_type): Add param "fmt_param_loc"
5547 and use it to make a substring_loc. Pass the latter to
5548 check_format_types.
5549 (check_format_info_main): Add params "fmt_param_loc" and
5550 "format_string_cst". Convert warning_at calls using
5551 location_from_offset to calls to format_warning_at_char. Pass the
5552 new params to the arg_parser ctor. Pass "format_string_cst" to
5553 flag_chars.validate. Pass "fmt_param_loc" to
5554 arg_parser.check_argument_type.
5555 (check_format_types): Convert first param from a location_t
5556 to a const substring_loc & and rename to "fmt_loc". Attempt
5557 to extract the range of the relevant parameter and pass it
5558 to format_type_warning.
5559 (format_type_warning): Convert first param from a location_t
5560 to a const substring_loc & and rename to "fmt_loc". Add
5561 params "param_range" and "type". Replace calls to warning_at
5562 with calls to format_warning_at_substring.
5563
1c4d457e
DM
55642016-08-08 David Malcolm <dmalcolm@redhat.com>
5565
5566 * c-format.c (class flag_chars_t): New class.
5567 (struct length_modifier): New struct.
5568 (class argument_parser): New class.
5569 (flag_chars_t::flag_chars_t): New ctor.
5570 (flag_chars_t::has_char_p): New method.
5571 (flag_chars_t::add_char): New method.
5572 (flag_chars_t::validate): New method.
5573 (flag_chars_t::get_alloc_flag): New method.
5574 (flag_chars_t::assignment_suppression_p): New method.
5575 (argument_parser::argument_parser): New ctor.
5576 (argument_parser::read_any_dollar): New method.
5577 (argument_parser::read_format_flags): New method.
5578 (argument_parser::read_any_format_width): New method.
5579 (argument_parser::read_any_format_left_precision): New method.
5580 (argument_parser::read_any_format_precision): New method.
5581 (argument_parser::handle_alloc_chars): New method.
5582 (argument_parser::read_any_length_modifier): New method.
5583 (argument_parser::read_any_other_modifier): New method.
5584 (argument_parser::find_format_char_info): New method.
5585 (argument_parser::validate_flag_pairs): New method.
5586 (argument_parser::give_y2k_warnings): New method.
5587 (argument_parser::parse_any_scan_set): New method.
5588 (argument_parser::handle_conversions): New method.
5589 (argument_parser::check_argument_type): New method.
5590 (check_format_info_main): Introduce classes argument_parser
5591 and flag_chars_t, moving the code within the loop into methods
5592 of these classes. Make various locals "const".
5593
88fa5555
DM
55942016-08-05 David Malcolm <dmalcolm@redhat.com>
5595
5596 * c-common.c: Include "substring-locations.h".
5597 (get_cpp_ttype_from_string_type): New function.
5598 (g_string_concat_db): New global.
5599 (substring_loc::get_range): New method.
5600 * c-common.h (g_string_concat_db): New declaration.
5601 (class substring_loc): New class.
5602 * c-lex.c (lex_string): When concatenating strings, capture the
5603 locations of all tokens using a new obstack, and record the
5604 concatenation locations within g_string_concat_db.
5605 * c-opts.c (c_common_init_options): Construct g_string_concat_db
5606 on the ggc-heap.
5607
78169471
MP
56082016-07-29 Marek Polacek <polacek@redhat.com>
5609
638fc14f
MP
5610 PR c/71926
5611 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
5612 parentheses warning.
5613
78169471
MP
5614 PR c/71574
5615 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
5616
1225d6b1
ML
56172016-07-28 Martin Liska <mliska@suse.cz>
5618
5619 PR gcov-profile/68025
5620 * c-common.c (handle_no_profile_instrument_function_attribute):
5621
ec1e2a40
BE
56222016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
5623
5624 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
5625 BITS_PER_UNIT_LOG.
5626
5ec2cd9f
JM
56272016-07-25 Jason Merrill <jason@redhat.com>
5628
5629 PR c++/65970
5630 * c.opt (fconstexpr-loop-limit): New.
5631
9dc5773f 56322016-07-22 Martin Sebor <msebor@redhat.com>
2e6b45af
MS
5633
5634 PR c++/71675
5635 * c-common.c (resolve_overloaded_builtin): Avoid converting
5636 __atomic_compare_exchange_n return type to that of what its
5637 first argument points to.
5638
e3fe09c1
UB
56392016-07-22 Uros Bizjak <ubizjak@gmail.com>
5640
5641 * c-common.c: Use HOST_WIDE_INT_M1U instead of
5642 ~(unsigned HOST_WIDE_INT) 0.
5643
bc91c436
ML
56442016-07-22 Martin Liska <mliska@suse.cz>
5645
5646 PR gcov-profile/69028
5647 PR gcov-profile/62047
5648 * cilk.c (create_cilk_helper_decl): Set location of a new decl
5649 to the current_function_decl.
5650
451dcc66
JM
56512016-07-21 Jason Merrill <jason@redhat.com>
5652
5653 PR c++/65168
5654 * c-common.c (c_common_truthvalue_conversion): Check
5655 c_inhibit_evaluation_warnings for warning about address of
5656 reference.
5657
de6a69ee
DM
56582016-07-20 David Malcolm <dmalcolm@redhat.com>
5659
5660 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
5661 const char *.
5662
d022c55a
JM
56632016-07-15 Jason Merrill <jason@redhat.com>
5664
5665 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
5666
ddbbcb19
JJ
56672016-07-15 Jakub Jelinek <jakub@redhat.com>
5668
5669 PR c/71858
5670 * c-common.h (enum lookup_name_fuzzy_kind): Add
5671 FUZZY_LOOKUP_FUNCTION_NAME.
5672
d0cf395a
JM
56732016-07-08 Jason Merrill <jason@redhat.com>
5674
5675 P0145: Refining Expression Order for C++.
5676 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
5677 * c-opts.c: Adjust.
5678
98d44e93
MT
56792016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
5680
5681 PR c++/71214
5682 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
5683
f9d8d994
TS
56842016-06-29 Thomas Schwinge <thomas@codesourcery.com>
5685
5686 * c-pragma.h (enum pragma_kind): Rename
5687 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
5688 users.
5689
4aa83879
RB
56902016-06-29 Richard Biener <rguenther@suse.de>
5691
5692 PR middle-end/71002
5693 * c-common.c (c_common_get_alias_set): Remove union type punning case.
5694
a25bd9e6
JM
56952016-06-24 Jason Merrill <jason@redhat.com>
5696
5697 P0145R2: Refining Expression Order for C++.
5698 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
5699 MODIFY_EXPR.
5700
a86451b9
JJ
57012016-06-24 Jakub Jelinek <jakub@redhat.com>
5702
5703 * c-common.c (check_builtin_function_arguments): Require last
5704 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
5705 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
5706 if the last argument is pointer to enumerated or boolean type.
5707
1a4f11c8
DM
57082016-06-22 David Malcolm <dmalcolm@redhat.com>
5709
5710 PR c/70339
5711 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
5712 (lookup_name_fuzzy): New prototype.
5713
fe55692c
JDA
57142016-06-21 John David Anglin <danglin@gcc.gnu.org>
5715
5716 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
5717
4eb24e01
JM
57182016-06-14 Jason Merrill <jason@redhat.com>
5719
5720 P0145R2: Refining Expression Order for C++.
5721 * c.opt (fargs-in-order): New.
5722 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
5723
ef7cf206
JJ
57242016-06-13 Jakub Jelinek <jakub@redhat.com>
5725
0dda258b
JJ
5726 PR sanitizer/71498
5727 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
5728 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
5729
ef7cf206
JJ
5730 PR preprocessor/71183
5731 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
5732 to cb_get_source_date_epoch.
5733
50b15873
JJ
57342016-06-10 Jakub Jelinek <jakub@redhat.com>
5735
5736 PR c/68657
5737 * c.opt (Wpsabi): Add Warning flag.
5738
4d926e34
MS
57392016-06-10 Martin Sebor <msebor@redhat.com>
5740
5741 PR c/71392
14ec014e 5742 * c-common.c (handle_nonnull_attribute): Accept
4d926e34
MS
5743 the nonnull attribute in type-generic builtins.
5744
e01b4e16
MS
57452016-06-09 Martin Sebor <msebor@redhat.com>
5746
5747 PR c/70883
5748 * c-common.c (builtin_function_validate_nargs): Make text of error
5749 message consistent with others like it.
5750
44a845ca
MS
57512016-06-08 Martin Sebor <msebor@redhat.com>
5752 Jakub Jelinek <jakub@redhat.com>
5753
5754 PR c++/70507
5755 PR c/68120
5756 * c-common.c (check_builtin_function_arguments): Handle
5757 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
5758
a80a7051
RB
57592016-06-08 Richard Biener <rguenther@suse.de>
5760
5761 * c-common.c (parse_optimize_options): Improve diagnostic messages.
5762
bfd67b47
RB
57632016-06-07 Richard Biener <rguenther@suse.de>
5764
5765 PR c/61564
5766 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
5767 options and warn about others.
5768
15c98b2e
ES
57692016-06-01 Eduard Sanou <dhole@openmailbox.org>
5770
5771 * c-common.c (get_source_date_epoch): Rename to
5772 cb_get_source_date_epoch.
5773 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
5774 message when the parsing fails. Use error_at instead of fatal_error.
5775 * c-common.h (get_source_date_epoch): Rename to
5776 cb_get_source_date_epoch.
5777 * c-common.h (cb_get_source_date_epoch): Prototype.
5778 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
5779 * c-common.h (c_omp_region_type): Remove trailing comma.
5780 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
5781 * c-lex.c (c_lex_with_flags): Remove initialization of
5782 pfile->source_date_epoch.
5783
00631022
JJ
57842016-05-30 Jakub Jelinek <jakub@redhat.com>
5785
5786 PR c++/71349
5787 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
5788 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
5789 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
5790 instead of C_OMP_CLAUSE_SPLIT_FOR.
5791
f17a223d
RB
57922016-05-24 Richard Biener <rguenther@suse.de>
5793
5794 PR middle-end/70434
5795 PR c/69504
5796 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
5797 (convert_vector_to_array_for_subscript): ... this.
5798 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
5799 VIEW_CONVERT_EXPR to an array type. Rename to ...
5800 (convert_vector_to_array_for_subscript): ... this.
5801
4f2e1536
MP
58022016-05-12 Marek Polacek <polacek@redhat.com>
5803
5804 PR c/70756
5805 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
5806 size_in_bytes and pass LOC to it.
5807
d6e83a8d
MM
58082016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
5809
5810 PR c/43651
5811 * c.opt (Wduplicate-decl-specifier): New option.
5812
5c3a10fb
MP
58132016-05-11 Marek Polacek <polacek@redhat.com>
5814
5815 PR c++/71024
5816 * c-common.c (diagnose_mismatched_attributes): New function.
5817 * c-common.h (diagnose_mismatched_attributes): Declare.
5818
deef7113
MP
58192016-05-04 Marek Polacek <polacek@redhat.com>
5820
5821 * c.opt (Wdangling-else): New option.
5822
79ce98bc
MP
58232016-05-03 Marek Polacek <polacek@redhat.com>
5824
5825 PR c/70859
5826 * c-common.c (builtin_function_validate_nargs): Add location
5827 parameter. Use it.
5828 (check_builtin_function_arguments): Add location and arguments
5829 parameters. Use them.
5830 * c-common.h (check_builtin_function_arguments): Update declaration.
5831
381cdae4
RB
58322016-05-03 Richard Biener <rguenther@suse.de>
5833
5834 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
5835 allow call args to gimplify to SSA names.
5836
1d793c34
MP
58372016-05-03 Marek Polacek <polacek@redhat.com>
5838
5839 * c-common.h (enum c_omp_region_type): Remove stray comma.
5840
77886428
CP
58412016-05-02 Cesar Philippidis <cesar@codesourcery.com>
5842
5843 * c-common.h (enum c_omp_region_type): Define.
5844
697e0b28
RS
58452016-05-02 Richard Sandiford <richard.sandiford@arm.com>
5846
5847 * c-common.c (shorten_compare): Use wi::to_wide.
5848
e7ff0319
CP
58492016-04-29 Cesar Philippidis <cesar@codesourcery.com>
5850
5851 PR middle-end/70626
5852 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
5853 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
5854 reduction clauses in acc parallel loops.
5855
2fff3db8
MP
58562016-04-29 Marek Polacek <polacek@redhat.com>
5857
5858 PR c/70852
5859 * c-common.c (warn_for_memset): Check domain before accessing it.
5860
509063eb
DV
58612016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
5862
5863 PR/69089
5864 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
5865 "aligned" attribute.
5866
b632761d
JM
58672016-04-28 Jason Merrill <jason@redhat.com>
5868
5869 * c-lex.c (c_common_has_attribute): Handle nodiscard.
5870
174f6622
ES
58712016-04-28 Eduard Sanou <dhole@openmailbox.org>
5872 Matthias Klose <doko@debian.org>
5873
5874 * c-common.c (get_source_date_epoch): New function, gets the environment
7365279f 5875 variable SOURCE_DATE_EPOCH and parses it as long long with error
174f6622
ES
5876 handling.
5877 * c-common.h (get_source_date_epoch): Prototype.
5878 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
5879
6bc2bb18
RB
58802015-04-27 Ryan Burn <contact@rnburn.com>
5881
5882 PR c++/69024
5883 PR c++/68997
5884 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
5885 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
5886 external linkage.
5887 (cilk_detect_and_unwrap): Corresponding changes.
5888 (extract_free_variables): Don't extract free variables from
5889 AGGR_INIT_EXPR slot.
5890 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
5891 (cilk_recognize_spawn): Likewise.
5892
c1e1f433
BS
58932016-04-27 Bernd Schmidt <bschmidt@redhat.com>
5894
5895 * c.opt (Wmemset-elt-size): New option.
5896 * c-common.c (warn_for_memset): New function.
5897 * c-common.h (warn_for_memset): Declare.
5898
d067e05f
JM
58992016-04-25 Jason Merrill <jason@redhat.com>
5900
5901 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
5902 No longer static.
5903 * c-common.h: Declare it.
5904 * c-lex.c (c_common_has_attribute): Add maybe_unused.
5905
9aa36ae5
JM
59062016-04-22 Jason Merrill <jason@redhat.com>
5907
5908 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
5909
477d4906
IV
59102016-04-20 Ilya Verbin <ilya.verbin@intel.com>
5911
5912 PR c++/69363
5913 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
5914 * c-common.h (c_finish_cilk_clauses): Remove declaration.
5915
fe37c7af
MM
59162016-04-18 Michael Matz <matz@suse.de>
5917
5918 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
5919 and SET_DECL_ALIGN.
5920
23f2660f
EB
59212016-04-17 Eric Botcazou <ebotcazou@adacore.com>
5922
5923 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
5924 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
5925 to incomplete types.
5926 (dump_nested_type): Remove redundant tests and tidy up.
5927 (print_ada_declaration): Also set TREE_VISITED on the declaration of
5928 a type which is the typedef of an original type.
5929
1e77281b
MP
59302016-04-15 Marek Polacek <polacek@redhat.com>
5931
5932 PR c/70651
5933 * c-common.c (build_va_arg): Change two asserts into errors and return
5934 error_mark_node.
5935
b3a77f21
MP
59362016-04-13 Marek Polacek <polacek@redhat.com>
5937
5938 PR c++/70639
5939 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
5940 for switch statements, too.
5941
322b8466
JM
59422016-03-28 Jason Merrill <jason@redhat.com>
5943
5944 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
5945
fbdb6baf
MP
59462016-03-23 Marek Polacek <polacek@redhat.com>
5947
5948 PR c++/69884
5949 * c.opt (Wignored-attributes): New option.
5950
5c240f4d
DM
59512016-03-22 David Malcolm <dmalcolm@redhat.com>
5952
5953 PR c/69993
5954 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
5955 diagnostic text, reversing the order of the warning and note so
5956 that they appear in source order.
5957
14ba7b28
MP
59582016-03-17 Marek Polacek <polacek@redhat.com>
5959
5960 PR c/69407
5961 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
5962 operations.
5963
08a1cadc
JM
59642016-03-14 Jason Merrill <jason@redhat.com>
5965
2aaeea19
JM
5966 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
5967
08a1cadc
JM
5968 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
5969
c06d25bb
RB
59702016-03-09 Richard Biener <rguenther@suse.de>
5971
5972 PR c/70143
5973 * c-common.c (strict_aliasing_warning): Add back
5974 alias_sets_conflict_p check.
5975
80aac5c8
JM
59762016-03-08 Jason Merrill <jason@redhat.com>
5977
5978 * c-opts.c (set_std_cxx1z): Don't enable concepts.
5979
64b23c13
DM
59802016-03-04 David Malcolm <dmalcolm@redhat.com>
5981
5982 PR c/68187
5983 * c-indentation.c (get_visual_column): Move code to determine next
5984 tab stop to...
5985 (next_tab_stop): ...this new function.
5986 (line_contains_hash_if): Delete function.
5987 (detect_preprocessor_logic): Delete function.
5988 (get_first_nws_vis_column): New function.
5989 (detect_intervening_unindent): New function.
5990 (should_warn_for_misleading_indentation): Replace call to
5991 detect_preprocessor_logic with a call to
5992 detect_intervening_unindent.
5993
729526f5
DM
59942016-03-04 David Malcolm <dmalcolm@redhat.com>
5995
5996 PR c/68187
5997 * c-indentation.c (should_warn_for_misleading_indentation): When
5998 suppressing warnings about cases where the guard and body are on
5999 the same column, only use the first non-whitespace column in place
6000 of the guard token column when dealing with "else" clauses.
6001 When rejecting aligned BODY and NEXT, loosen the requirement
6002 from equality with the first non-whitespace of guard to simply
6003 that they not be indented relative to it.
6004
e9a35493
RB
60052016-03-04 Richard Biener <rguenther@suse.de>
6006
6007 PR c++/70054
6008 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
6009 instead of alias_sets_conflict_p.
6010
1be56bc5
MP
60112016-03-01 Marek Polacek <polacek@redhat.com>
6012
6013 PR c++/69795
6014 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
6015 any DECL.
6016
35886f0b
MS
60172016-02-22 Martin Sebor <msebor@redhat.com>
6018
6019 PR middle-end/69780
6020 * c-common.c (check_builtin_function_arguments): Validate and
6021 reject invalid arguments to __builtin_alloca_with_align.
6022
4246c8da
MW
60232016-02-20 Mark Wielaard <mjw@redhat.com>
6024
6025 PR c/28901
6026 * c.opt (Wunused-const-variable): Turn into Alias for...
6027 (Wunused-const-variable=): New option.
6028
268be88c
BE
60292016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
6030
6031 PR c++/69865
6032 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
6033 here...
6034 (c_common_init_options): ...to here.
6035 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
6036
871b3f47
JJ
60372016-02-19 Jakub Jelinek <jakub@redhat.com>
6038
6039 PR c++/69826
6040 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
6041 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
6042 flag_preprocess_only.
6043
bf14eba2
JJ
60442016-02-16 Jakub Jelinek <jakub@redhat.com>
6045
6046 PR c/69835
6047 * c.opt (Wnonnull-compare): Enable for -Wall.
6048
ba6b3795
JJ
60492016-02-15 Jakub Jelinek <jakub@redhat.com>
6050
6051 PR c++/69797
6052 * c-common.c (sync_resolve_size): Diagnose too few arguments
6053 even when params is non-NULL empty vector.
6054
a011cd92
BS
60552016-02-08 Bernd Schmidt <bschmidt@redhat.com>
6056
6057 PR target/60410
6058 * c.opt (fshort-double): Remove.
6059
46cb9332
MS
60602016-02-05 Martin Sebor <msebor@redhat.com>
6061
6062 PR c++/69662
6063 * c.opt (Warning options): Update -Wplacement-new to take
6064 an optional argument.
6065
e1b81f2b
JJ
60662016-02-01 Jakub Jelinek <jakub@redhat.com>
6067
6068 PR preprocessor/69543
6069 PR c/69558
6070 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
6071 instead of loc to control_warning_option.
6072
b6adbb9f
NS
60732016-02-01 Nathan Sidwell <nathan@codesourcery.com>
6074
6075 * c.opt (fopenacc-dim=): New option.
6076
5d70666e
RB
60772016-01-27 Ryan Burn <contact@rnburn.com>
6078
6079 PR cilkplus/69267
6080 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
6081 gimplify_arg. Removed superfluous post_p argument.
6082 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
6083 superfluous post_p argument.
6084 * c-gimplify.c (c_gimplify_expr): Likewise.
6085
01e1dea3
DM
60862016-01-26 David Malcolm <dmalcolm@redhat.com>
6087
6088 PR other/69006
6089 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
6090 pp_newline_and_flush with pp_flush.
6091
9f04a53e
MS
60922016-01-20 Martin Sebor <msebor@redhat.com>
6093
6094 PR c/69405
6095 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
6096 an incompatible argument when the argument isn't a valid tree node.
6097
7f26f7df
JM
60982016-01-18 Jason Merrill <jason@redhat.com>
6099
6100 PR c++/68767
6101 * c-common.c (check_function_arguments_recurse): Fold the whole
6102 COND_EXPR, not just the condition.
6103
f62bf092
TV
61042016-01-18 Tom de Vries <tom@codesourcery.com>
6105
6106 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
6107 classify as loop clause.
6108
e0a575ff
JJ
61092016-01-15 Jakub Jelinek <jakub@redhat.com>
6110
6111 PR bootstrap/68271
6112 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
6113 C++ FE no longer has limit on number of pragmas.
6114
61152015-01-14 Ryan Burn <contact@rnburn.com>
b6e3db06
RB
6116
6117 PR c++/69048
6118 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
c47eaca6 6119 to add missing cleanup point.
b6e3db06 6120
c7df95d8
DM
61212016-01-14 David Malcolm <dmalcolm@redhat.com>
6122
6123 PR c++/68819
6124 * c-indentation.c (get_visual_column): Add location_t param.
6125 Handle the column number being zero by effectively disabling the
6126 warning, with an "inform".
6127 (should_warn_for_misleading_indentation): Add location_t argument
6128 for all uses of get_visual_column.
6129
21efdd80
PP
61302016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
6131
6132 PR c++/69029
6133 * c-indentation.c (should_warn_for_misleading_indentation):
6134 Don't warn about do-while statements.
6135
7a127fa7
MS
61362016-01-07 Martin Sebor <msebor@redhat.com>
6137
6138 PR c/68966
6139 * c-common.c (sync_resolve_size): Reject first argument when it's
6140 a pointer to _Bool.
6141
c589e975
DM
61422016-01-05 David Malcolm <dmalcolm@redhat.com>
6143
6144 PR c/69122
6145 * c-indentation.c (get_visual_column): Remove default argument.
6146 (should_warn_for_misleading_indentation): For the multiline case,
6147 update call to get_visual_column for next_stmt_exploc so that it
6148 captures the location of the first non-whitespace character in the
6149 relevant line. Don't issue warnings if there is non-whitespace
6150 before the next statement.
6151
818ab71a
JJ
61522016-01-04 Jakub Jelinek <jakub@redhat.com>
6153
6154 Update copyright years.
6155
745e411d
DM
61562015-12-21 David Malcolm <dmalcolm@redhat.com>
6157
6158 * c-common.c (binary_op_error): Convert first param from
6159 location_t to rich_location * and use it when emitting an error.
6160 * c-common.h (binary_op_error): Convert first param from
6161 location_t to rich_location *.
6162
de67c4c3
DM
61632015-12-16 David Malcolm <dmalcolm@redhat.com>
6164
6165 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
6166 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
6167
4a38b02b
IV
61682015-12-15 Ilya Verbin <ilya.verbin@intel.com>
6169
6170 * c-common.c (c_common_attribute_table): Handle "omp declare target
6171 link" attribute.
6172
54d62f51
JJ
61732015-12-14 Jakub Jelinek <jakub@redhat.com>
6174
6175 PR c/68833
6176 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
6177
8d4227c8
TB
61782014-12-12 Tobias Burnus <burnus@net-b.de>
6179
6180 PR fortran/68815
6181 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
6182 specifiers (%d, %i,%u and %c).
6183
f6069ccc
DM
61842015-12-10 David Malcolm <dmalcolm@redhat.com>
6185
6186 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
6187
63bbf46d
JJ
61882015-12-08 Jakub Jelinek <jakub@redhat.com>
6189
6190 PR c/48088
6191 PR c/68657
6192 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
6193 * c-pragma.c (handle_pragma_diagnostic): Adjust
6194 control_warning_option caller.
6195
f79520bb
DM
61962015-12-07 David Malcolm <dmalcolm@redhat.com>
6197
6198 * c-common.c (c_cpp_error): Update for change to
6199 rich_location::set_range.
6200
b3d5bc62
JJ
62012015-12-04 Paolo Bonzini <bonzini@gnu.org>
6202
6203 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
6204 shifting 1 out of the sign bit.
6205
62062015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
6207
6208 * c-common.c (c_common_attribute_table[]): Update max arguments
6209 count for "simd" attribute.
6210 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
6211
6eb4a537
JJ
62122015-12-03 Jakub Jelinek <jakub@redhat.com>
6213
6214 PR preprocessor/57580
6215 * c-ppoutput.c (print): Change printed field to bool.
6216 Move src_file last for smaller padding.
6217 (init_pp_output): Set print.printed to false instead of 0.
6218 (scan_translation_unit): Fix up formatting. Set print.printed
6219 to true after printing something other than newline.
6220 (scan_translation_unit_trad): Set print.printed to true instead of 1.
6221 (maybe_print_line_1): Set print.printed to false instead of 0.
6222 (print_line_1): Likewise.
6223 (do_line_change): Set print.printed to true instead of 1.
6224 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
6225 dump_macro): Set print.printed to false after printing newline.
6226
4250754e
JM
62272015-12-02 Jason Merrill <jason@redhat.com>
6228
f479b43d
JM
6229 * c-common.c (fold_for_warn): New.
6230 (warn_logical_operator, warn_tautological_cmp)
6231 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
6232
4250754e
JM
6233 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
6234 (c_fully_fold_internal, decl_constant_value_for_optimization):
6235 Move to c/c-fold.c.
6236 * c-common.h: Don't declare decl_constant_value_for_optimization.
6237
e9e32ee6
JM
62382015-12-02 Joseph Myers <joseph@codesourcery.com>
6239
6240 PR c/68162
6241 * c-common.h (c_build_qualified_type): Add extra default
6242 arguments.
6243
37d5ad46
JB
62442015-12-01 Julian Brown <julian@codesourcery.com>
6245 Cesar Philippidis <cesar@codesourcery.com>
6246 James Norris <James_Norris@mentor.com>
6247
6248 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
6249 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
6250 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
6251
f07862c7
EB
62522015-11-30 Eric Botcazou <ebotcazou@adacore.com>
6253
6254 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
6255 (decl_sloc_common): Delete and move bulk of processing to...
6256 (decl_sloc): ...here.
6257 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
6258 (dump_ada_double_name): Remove S parameter and compute the suffix.
6259 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
6260 element type and deal with an anonymous one.
6261 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
6262 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
6263 and remove reference to QUAL_UNION_TYPE.
6264 (dump_nested_types): Make 2 passes on the fields and move bulk to...
6265 (dump_nested_type): ...here. New function extracted from above.
6266 Generate a full declaration for anonymous element type of arrays.
6267 (print_ada_declaration): Really skip anonymous declarations. Remove
6268 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
6269 Clean up processing of declarations of array types and objects.
6270 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
6271 Remove obsolete code and tidy up.
6272
75c8aac3
JH
62732015-11-29 Jan Hubicka <hubicka@ucw.cz>
6274
6275 PR c/67581
6276 * c-common.c (handle_transparent_union_attribute): Update
6277 also type variants.
6278
b58d3df2
ML
62792015-11-27 Martin Liska <mliska@suse.cz>
6280
6281 PR c++/68312
6282 * array-notation-common.c (cilkplus_extract_an_triplets):
6283 Release vector of vectors.
6284 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
6285
89a01fcf
EB
62862015-11-26 Eric Botcazou <ebotcazou@adacore.com>
6287
6288 PR c++/68527
6289 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
6290 (print_ada_struct_decl): Likewise.
6291
cc5c5226
IZ
62922015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
6293
6294 PR c++/68001
6295 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
6296 * cilk.c (recognize_spawn): Determine location in a more precise
6297 way.
6298
269adb9d
JM
62992015-11-19 Jason Merrill <jason@redhat.com>
6300
6301 * c-common.c (shorten_compare): But look through macros from
6302 system headers.
6303
d0eccfcd
JM
63042015-11-18 Jason Merrill <jason@redhat.com>
6305
6306 * c-common.c (shorten_compare): Don't -Wtype-limits if the
6307 non-constant operand comes from a macro.
6308
3e44547c
JM
63092015-11-17 Jason Merrill <jason@redhat.com>
6310
6311 PR bootstrap/68346
6312 * c-common.c (warn_tautological_cmp): Fold before checking for
6313 constants.
6314
0f62c7a0
MP
63152015-11-16 Marek Polacek <polacek@redhat.com>
6316
6317 PR c++/68362
6318 * c-common.c (check_case_bounds): Fold low and high cases.
6319
a868811e
MP
63202015-11-16 Marek Polacek <polacek@redhat.com>
6321
6322 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
6323 * c-common.c (c_common_get_alias_set): Likewise.
6324 (handle_visibility_attribute): Likewise.
6325
fff77217
KY
63262015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
6327
6328 * c-common.c (handle_simd_attribute): New.
6329 (struct attribute_spec): Add entry for "simd".
6330 (handle_simd_attribute): New.
6331
269e63b7
KT
63322015-11-13 Kai Tietz <ktietz70@googlemail.com>
6333
6334 * c-lex.c (interpret_float): Use fold_convert.
6335
ebedc9a3
DM
63362015-11-13 David Malcolm <dmalcolm@redhat.com>
6337
6338 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
6339 and store it on the result.
6340 * c-opts.c (c_common_init_options): Set
6341 global_dc->colorize_source_p.
6342
6e232ba4
JN
63432015-11-12 James Norris <jnorris@codesourcery.com>
6344 Joseph Myers <joseph@codesourcery.com>
6345
7365279f 6346 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
6e232ba4
JN
6347 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
6348 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
6349 PRAGMA_OACC_CLAUSE_LINK.
6350
e78bede6
MP
63512015-11-11 Marek Polacek <polacek@redhat.com>
6352
6353 PR c/68107
6354 PR c++/68266
6355 * c-common.c (valid_array_size_p): New function.
6356 * c-common.h (valid_array_size_p): Declare.
6357
3f8257db 63582015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4ac93c7c
DH
6359
6360 PR bootstrap/68271
6361 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
6362
69f293c9
AM
63632015-11-11 Andrew MacLeod <amacleod@redhat.com>
6364
6365 * array-notation-common.c: Remove unused header files.
6366 * c-ada-spec.c: Likewise.
6367 * c-cilkplus.c: Likewise.
6368 * c-common.c: Likewise.
6369 * c-cppbuiltin.c: Likewise.
6370 * c-dump.c: Likewise.
6371 * c-format.c: Likewise.
6372 * c-gimplify.c: Likewise.
6373 * c-indentation.c: Likewise.
6374 * c-lex.c: Likewise.
6375 * c-omp.c: Likewise.
6376 * c-opts.c: Likewise.
6377 * c-pch.c: Likewise.
6378 * c-ppoutput.c: Likewise.
6379 * c-pragma.c: Likewise.
6380 * c-pretty-print.c: Likewise.
6381 * c-semantics.c: Likewise.
6382 * c-ubsan.c: Likewise.
6383 * cilk.c: Likewise.
6384 * stub-objc.c: Likewise.
6385
3a40d81d
NS
63862015-11-09 Thomas Schwinge <thomas@codesourcery.com>
6387 Cesar Philippidis <cesar@codesourcery.com>
6388 James Norris <jnorris@codesourcery.com>
6389 Julian Brown <julian@codesourcery.com>
6390 Nathan Sidwell <nathan@codesourcery.com>
6391
6392 * c-pragma.c (oacc_pragmas): Add "routine".
6393 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
6394
ee45a32d
EB
63952015-11-08 Eric Botcazou <ebotcazou@adacore.com>
6396
6397 * c-common.c (c_common_attributes): Add scalar_storage_order.
6398 (handle_scalar_storage_order_attribute): New function.
6399 * c-pragma.c (global_sso): New variable.
6400 (maybe_apply_pragma_scalar_storage_order): New function.
6401 (handle_pragma_scalar_storage_order): Likewise.
6402 (init_pragma): Register scalar_storage_order.
6403 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
6404 * c.opt (Wscalar-storage-order): New warning.
6405 (fsso-struct=): New option.
6406
eb11eb15
MS
64072015-11-08 Martin Sebor <msebor@redhat.com>
6408
6409 * c.opt (Wplacement-new): Add a period to the end of a sentence.
6410
0aad0198
RS
64112015-11-07 Richard Sandiford <richard.sandiford@arm.com>
6412
6413 * c-common.c: Don't undef DEF_BUILTIN.
6414
8a645150
DM
64152015-11-06 David Malcolm <dmalcolm@redhat.com>
6416
6417 * c-common.c (c_cpp_error): Convert parameter from location_t to
6418 rich_location *. Eliminate the "column_override" parameter and
6419 the call to diagnostic_override_column.
6420 Update the "done_lexing" clause to set range 0
6421 on the rich_location, rather than overwriting a location_t.
6422 * c-common.h (c_cpp_error): Convert parameter from location_t to
6423 rich_location *. Eliminate the "column_override" parameter.
6424
7a5e4956
CP
64252015-11-05 Cesar Philippidis <cesar@codesourcery.com>
6426 Thomas Schwinge <thomas@codesourcery.com>
6427 James Norris <jnorris@codesourcery.com>
6428
6429 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
6430 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
6431 clauses with parallel and kernels and loops.
6432 * c-pragma.h (enum pragma_omp_clause): Add entries for
6433 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
6434 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
6435 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
6436 INDEPENDENT,SEQ}.
6437 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
6438
e2f5cc96
MS
64392015-11-05 Martin Sebor <msebor@redhat.com>
6440
6441 PR c++/67942
6442 * c.opt (-Wplacement-new): New option.
6443
e01d41e5
JJ
64442015-11-05 Jakub Jelinek <jakub@redhat.com>
6445
6446 * c-common.h (c_finish_omp_atomic): Add TEST argument.
6447 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
6448 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
6449 save_expr or create_tmp_var* if TEST is true.
6450 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
6451 Don't call add_stmt here.
6452 (struct c_omp_check_loop_iv_data): New type.
6453 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
6454 c_omp_check_loop_iv_exprs): New functions.
6455 (c_omp_split_clauses): Adjust for lastprivate being allowed on
6456 distribute.
6457 (c_omp_declare_simd_clauses_to_numbers): Change
6458 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
6459 (c_omp_declare_simd_clauses_to_decls): Similarly change those
6460 from numbers to PARM_DECLs.
6461
595278be
MM
64622015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
6463
6464 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
6465 flag_checking.
6466
3f8257db 64672015-11-03 Bernd Schmidt <bschmidt@redhat.com>
c85158de
MS
6468
6469 PR c++-common/67882
b3d5bc62
JJ
6470 * c-common.h (fold_offsetof_1): Add argument.
6471 * c-common.c (fold_offsetof_1): Diagnose more invalid
c85158de
MS
6472 offsetof expressions that reference elements past the end of
6473 an array.
6474
4bf9e5a8
TS
64752015-11-03 Thomas Schwinge <thomas@codesourcery.com>
6476 Chung-Lin Tang <cltang@codesourcery.com>
6477
6478 * c-pragma.c (oacc_pragmas): Add "atomic".
6479 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
6480
3b1661a9
ES
64812015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
6482
6483 * c-common.c (handle_target_clones_attribute): New.
6484 (c_common_attribute_table): Add handle_target_clones_attribute.
6485 (handle_always_inline_attribute): Add check on target_clones attribute.
6486 (handle_target_attribute): Ditto.
6487
2adfab87
AM
64882015-10-29 Andrew MacLeod <amacleod@redhat.com>
6489
6490 * array-notation-common.c: Reorder #include's and remove duplicates.
6491 * c-ada-spec.c: Likewise.
6492 * c-cilkplus.c: Likewise.
6493 * c-common.c: Likewise.
6494 * c-cppbuiltin.c: Likewise.
6495 * c-dump.c: Likewise.
6496 * c-format.c: Likewise.
6497 * c-gimplify.c: Likewise.
6498 * c-indentation.c: Likewise.
6499 * c-lex.c: Likewise.
6500 * c-omp.c: Likewise.
6501 * c-opts.c: Likewise.
6502 * c-pch.c: Likewise.
6503 * c-ppoutput.c: Likewise.
6504 * c-pragma.c: Likewise.
6505 * c-pretty-print.c: Likewise.
6506 * c-semantics.c: Likewise.
6507 * c-ubsan.c: Likewise.
6508 * cilk.c: Likewise.
6509 * stub-objc.c: Likewise.
6510
d90ec4f2
JM
65112015-10-28 Jason Merrill <jason@redhat.com>
6512
6513 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
6514
88bae6f4
TS
65152015-10-27 Thomas Schwinge <thomas@codesourcery.com>
6516 James Norris <jnorris@codesourcery.com>
6517 Cesar Philippidis <cesar@codesourcery.com>
6518
6519 PR c/64765
6520 PR c/64880
6521 * c-common.h (c_oacc_split_loop_clauses): Declare function.
6522 * c-omp.c (c_oacc_split_loop_clauses): New function.
6523
b1726d6c
MS
65242015-10-21 Martin Sebor <msebor@redhat.com>
6525
6526 PR driver/68043
6527 * c.opt: End each sentence that describes an option with a period.
6528
fa60eeb9
MP
65292015-10-20 Marek Polacek <polacek@redhat.com>
6530
6531 * array-notation-common.c (is_cilkplus_vector_p): Define.
6532 * c-common.h (is_cilkplus_vector_p): Declare.
6533
95979049
MP
65342015-10-20 Marek Polacek <polacek@redhat.com>
6535
6536 * c.opt (std=gnu++11): Do not describe as experimental.
6537 (std=gnu++14): Likewise.
6538
2a9fb712
JM
65392015-10-19 Jason Merrill <jason@redhat.com>
6540
6541 * c-cppbuiltin.c (c_cpp_builtins): Define
6542 __cpp_nontype_template_args.
6543
13b380a3
JM
65442015-10-19 Jason Merrill <jason@redhat.com>
6545
6546 * c-cppbuiltin.c (c_cpp_builtins): Define
6547 __cpp_enumerator_attributes, __cpp_fold_expressions,
6548 __cpp_unicode_characters.
6549
d9a6bd32
JJ
65502015-10-13 Jakub Jelinek <jakub@redhat.com>
6551 Aldy Hernandez <aldyh@redhat.com>
6552
6553 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
6554 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
6555 (c_define_builtins): Likewise.
6556 * c-common.h (enum c_omp_clause_split): Add
6557 C_OMP_CLAUSE_SPLIT_TASKLOOP.
6558 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
6559 (c_finish_omp_for): Add ORIG_DECLV argument.
6560 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
6561 201511 instead of 201307.
6562 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
6563 OMP_CRITICAL_CLAUSES to it.
6564 (c_finish_omp_ordered): Add CLAUSES argument, set
6565 OMP_ORDERED_CLAUSES to it.
6566 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
6567 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
6568 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
6569 constructs and new OpenMP 4.5 clauses. Clear
6570 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
6571 verification code.
6572 * c-pragma.c (omp_pragmas_simd): Add taskloop.
6573 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
6574 (enum pragma_omp_clause): Add
6575 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
6576 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
6577
624d31fe
RS
65782015-10-05 Richard Sandiford <richard.sandiford@arm.com>
6579
6580 * c-lex.c (interpret_float): Use real_equal instead of
6581 REAL_VALUES_EQUAL.
6582
b8fd7909
JM
65832015-10-04 Jason Merrill <jason@redhat.com>
6584
6585 Implement N4514, C++ Extensions for Transactional Memory.
6586 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
6587 (c_common_attribute_table): Add transaction_safe_dynamic.
6588 transaction_safe now affects type identity.
6589 (handle_tm_attribute): Handle transaction_safe_dynamic.
6590 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
6591 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
6592 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
6593 (D_TRANSMEM): New.
6594 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
6595 * c-pretty-print.c (pp_c_attributes_display): Don't print
6596 transaction_safe in C++.
6597
12651878
MP
65982015-10-02 Marek Polacek <polacek@redhat.com>
6599
6600 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
6601
3e3b8d63
MP
66022015-10-02 Marek Polacek <polacek@redhat.com>
6603
6604 PR c/64249
6605 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
6606 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
6607 * c.opt (Wduplicated-cond): New option.
6608
0d1a8f75
JM
66092015-10-01 Joseph Myers <joseph@codesourcery.com>
6610
6611 * c.opt (std=c11): Do not describe as experimental.
6612 (std=gnu11): Likewise.
6613 (std=iso9899:2011): Likewise.
6614
3e32ee19
NS
66152015-09-28 Nathan Sidwell <nathan@codesourcery.com>
6616
6617 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
6618 (DEF_FUNCTION_TYPE_VAR_11): Delete.
6619
974348ee
MP
66202015-09-25 Marek Polacek <polacek@redhat.com>
6621
6622 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
6623 (ubsan_instrument_shift): Likewise.
6624
15dbc1a6
MP
66252015-09-25 Marek Polacek <polacek@redhat.com>
6626
6627 PR sanitizer/64906
6628 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
6629
6b95d7cc
PP
66302015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
6631
6632 * c-indentation.c (should_warn_for_misleading_indentation):
6633 Compare next_stmt_vis_column with guard_line_first_nws instead
6634 of with guard_line_vis_column.
6635
c1822f9c
MLI
66362015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
6637
6638 PR c/49654
6639 PR c/49655
6640 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
6641 options and options not valid for the current language.
6642
d5398058
PP
66432015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
6644
6645 * c-indentation.c (should_warn_for_misleading_indentation):
6646 Float out and consolidate the calls to get_visual_column that
6647 are passed guard_exploc as an argument. Compare
6648 next_stmt_vis_column with guard_line_first_nws instead of with
6649 body_line_first_nws.
6650
6b333269
NS
66512015-09-22 Nathan Sidwell <nathan@codesourcery.com>
6652
6653 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
6654 Wnamespaces): New C++ warnings.
6655
a75f1574
JM
66562015-09-22 Jason Merrill <jason@redhat.com>
6657
6658 * c-common.h (abi_compat_version_crosses): New.
6659 (warn_abi_version): Declare.
6660 * c-common.c: Define it.
6661 * c-opts.c (c_common_post_options): Handle it.
6662 flag_abi_compat_version defaults to 8.
6663
bdaaa8b7
VV
66642015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
6665
6666 Complete the implementation of N4230, Nested namespace definition.
6667 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
6668 __cpp_nested_namespace_definitions.
6669
eaa797e8
MLI
66702015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
6671
6672 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
6673
c4914de6
MLI
66742015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
6675
6676 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
6677 when warning.
6678 * c-pragma.h (pragma_lex): Add optional loc argument.
6679
fcb87c50
MM
66802015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
6681
6682 * c-format.c (check_format_arg): Adjust to use common block size in all
6683 object pools.
6684
31bdd08a
DM
66852015-09-15 David Malcolm <dmalcolm@redhat.com>
6686
6687 * c-format.c (location_from_offset): Update for change in
6688 signature of location_get_source_line.
6689 * c-indentation.c (get_visual_column): Likewise.
6690 (line_contains_hash_if): Likewise.
6691
aa9f4b4c
MP
66922015-09-14 Marek Polacek <polacek@redhat.com>
6693
6694 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
6695 setting various warnings.
6696
aa256c4a
MP
66972015-09-14 Marek Polacek <polacek@redhat.com>
6698
6699 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
6700 a negative value.
6701
0f876f22
MW
67022015-09-11 Mark Wielaard <mjw@redhat.com>
6703
6704 PR c/28901
6705 * c.opt (Wunused-variable): Option from common.opt.
6706 (Wunused-const-variable): New option.
6707
273aa49e
PC
67082015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
6709
6710 PR c++/53184
6711 * c.opt ([Wsubobject-linkage]): Add.
6712
1807ffc1
MS
67132015-09-03 Martin Sebor <msebor@redhat.com>
6714
6715 PR c/66516
6716 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
6717 functions.
6718 * c-common.c (reject_gcc_builtin): Define.
6719
38942840
BI
67202015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
6721
6722 PR middle-end/60586
6723 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
6724 prototype.
6725 * c-gimplify.c (c_gimplify_expr): Added a call to the function
6726 cilk_gimplify_call_params_in_spawned_fn.
6727 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
6728 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
6729 unwrapping.
6730
c316b5e4
MP
67312015-08-25 Marek Polacek <polacek@redhat.com>
6732
6733 PR middle-end/67330
6734 * c-common.c (handle_weak_attribute): Don't check whether the
6735 visibility can be changed here.
6736
584a7c46
MLI
67372015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
6738
6739 * c-lex.c (c_lex_with_flags): Use explicit locations.
6740
a79683d5
TS
67412015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
6742
6743 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
6744 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
6745
61717a45
FXC
67462015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
6747
6748 PR middle-end/36757
6749 * c-common.c (check_builtin_function_arguments): Add check
6750 for BUILT_IN_SIGNBIT argument.
6751
329524f5
PC
67522015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
6753
6754 PR c++/67160
6755 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
6756 in c++1z mode.
6757
4ee55665
MP
67582015-08-17 Marek Polacek <polacek@redhat.com>
6759
6760 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
6761 with whitespaces before qualifier names.
6762
b893e375
MP
67632015-08-12 Marek Polacek <polacek@redhat.com>
6764
6765 PR c++/55095
6766 * c-common.c (maybe_warn_shift_overflow): Properly handle
6767 left-shifting 1 into the sign bit.
6768
c2d89095
MLI
67692015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
6770
6771 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
6772
971e17ff
AS
67732015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
6774 Braden Obrzut <admin@maniacsvault.net>
6775 Jason Merrill <jason@redhat.com>
6776
6777 Add C++ Concepts TS support.
6778 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
6779 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
6780 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
6781 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
6782 * c-opts.c (set_std_cxx1z): Set flag_concepts.
6783 * c.opt (fconcepts): New.
6784
b3d5bc62
JJ
67852015-08-02 Martin Sebor <msebor@redhat.com>
6786
6787 * c.opt (-Wframe-address): New warning option.
6788
8ebca419
PP
67892015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
6790
6791 * c-indentation.c (should_warn_for_misleading_indentation):
6792 Improve heuristics.
6793
1a1e101f
PP
67942015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
6795
6796 * c-indentation.c (get_visual_column): Add parameter first_nws,
6797 use it. Update comment documenting the function.
6798 (is_first_nonwhitespace_on_line): Remove.
6799 (should_warn_for_misleading_indentation): Replace usage of
6800 of is_first_nonwhitespace_on_line with get_visual_column.
6801
992118a1
PP
68022015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
6803
6804 * c-indentation.h (struct token_indent_info): Define.
6805 (get_token_indent_info): Define.
6806 (warn_for_misleading_information): Declare.
6807 * c-common.h (warn_for_misleading_information): Remove.
6808 * c-identation.c (warn_for_misleading_indentation):
6809 Change declaration to take three token_indent_infos. Adjust
6810 accordingly.
6811 * c-identation.c (should_warn_for_misleading_indentation):
6812 Likewise. Bail out early if the body is a compound statement.
6813 (guard_tinfo_to_string): Define.
6814
e8fa3817
JM
68152015-07-30 Jason Merrill <jason@redhat.com>
6816
6817 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
6818 '*' for reference decay.
6819
173864e8
MP
68202015-07-30 Marek Polacek <polacek@redhat.com>
6821
6822 * c-common.c (warn_tautological_cmp): Bail for float types.
6823
f2afe6dd
MP
68242015-07-27 Marek Polacek <polacek@redhat.com>
6825
6826 PR bootstrap/67030
6827 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
6828
05b28fd6
MP
68292015-07-27 Marek Polacek <polacek@redhat.com>
6830
6831 PR c++/66555
6832 PR c/54979
6833 * c-common.c (find_array_ref_with_const_idx_r): New function.
6834 (warn_tautological_cmp): New function.
6835 * c-common.h (warn_tautological_cmp): Declare.
6836 * c.opt (Wtautological-compare): New option.
6837
5a5062b8
MP
68382015-07-23 Marek Polacek <polacek@redhat.com>
6839
6840 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
6841 (ubsan_instrument_shift): Likewise.
6842
dc891fe7
MP
68432015-07-23 Marek Polacek <polacek@redhat.com>
6844
6845 PR sanitizer/66908
6846 * c-ubsan.c: Include gimplify.h.
6847 (ubsan_instrument_division): Unshare OP0 and OP1.
6848 (ubsan_instrument_shift): Likewise.
6849
451b5e48
MP
68502015-07-20 Marek Polacek <polacek@redhat.com>
6851 Richard Sandiford <richard.sandiford@arm.com>
6852
6853 PR c++/55095
6854 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
6855 Use EXPR_LOC_OR_LOC.
6856 (maybe_warn_shift_overflow): New function.
6857 * c-common.h (maybe_warn_shift_overflow): Declare.
6858 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
6859 * c.opt (Wshift-overflow): New option.
6860
fb0b2914
ML
68612015-07-16 Martin Liska <mliska@suse.cz>
6862
6863 * c-format.c (static void check_format_info_main): Use
6864 object_allocator instead of pool_allocator.
6865 (check_format_arg): Likewise.
6866 (check_format_info_main): Likewise.
6867
903f5c23
AM
68682015-07-15 Andrew MacLeod <amacleod@redhat.com>
6869
6870 * c-opts.c: Remove multiline #include comment.
6871
026c3cfd
AH
68722015-07-12 Aldy Hernandez <aldyh@redhat.com>
6873
6874 * c-common.c: Fix double word typos.
6875
bb49ee66
EB
68762015-07-10 Eric Botcazou <ebotcazou@adacore.com>
6877
6878 * c-ada-spec.h (cpp_operation): Revert latest change.
6879 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
6880 constructors and destructors.
6881
1916bcb5
AM
68822015-07-09 Andrew MacLeod <amacleod@redhat.com>
6883
6884 * c-common.h: Adjust includes for flags.h changes.
6885 * stub-objc.c: Likewise.
026c3cfd 6886
a9dcd529
EB
68872015-07-08 Eric Botcazou <ebotcazou@adacore.com>
6888
6889 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
6890 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
6891
b03b462f
JJ
68922015-07-08 Jakub Jelinek <jakub@redhat.com>
6893
6894 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
6895 are to be removed, return NULL rather than original clauses list.
6896
c7131fb2
AM
68972015-07-07 Andrew MacLeod <amacleod@redhat.com>
6898
6899 * array-notation-common.c: Adjust includes.
6900 * c-ada-spec.c: Likewise.
6901 * c-cilkplus.c: Likewise.
6902 * c-common.h: Likewise.
6903 * c-cppbuiltin.c: Likewise.
6904 * c-dump.c: Likewise.
6905 * c-format.c: Likewise.
6906 * c-gimplify.c: Likewise.
6907 * c-indentation.c: Likewise.
6908 * c-lex.c: Likewise.
6909 * c-omp.c: Likewise.
6910 * c-opts.c: Likewise.
6911 * c-pch.c: Likewise.
6912 * c-ppoutput.c: Likewise.
6913 * c-pragma.c: Likewise.
6914 * c-pretty-print.c: Likewise.
6915 * c-semantics.c: Likewise.
6916 * c-ubsan.c: Likewise.
6917 * cilk.c: Likewise.
6918 * stub-objc.c: Likewise.
6919
2a7fb83f
EB
69202015-07-07 Eric Botcazou <ebotcazou@adacore.com>
6921
6922 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
6923 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
6924
a03c9bf1
JM
69252015-07-01 Jason Merrill <jason@redhat.com>
6926
36a85135
JM
6927 * c-common.h (D_CXX11): Rename from D_CXX0X.
6928 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
6929 * c-common.c: Adjust.
6930
e7fa68d5
JM
6931 * c-opts.c (c_common_post_options): Default to C++14.
6932
a03c9bf1
JM
6933 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
6934
fe95b036
ESR
69352015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
6936
6937 Implement N4197 - Adding u8 character literals
b3d5bc62 6938 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
a64be36b 6939 CPP_CHAR.
b3d5bc62 6940 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
a64be36b 6941 CPP_UTF8CHAR_USERDEF tokens.
b3d5bc62 6942 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
a64be36b
EB
6943 and CPP_UTF8CHAR tokens.
6944 (lex_charconst): Treat CPP_UTF8CHAR token.
fe95b036 6945
da2e71c9
MLI
69462015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
6947
6948 PR fortran/66605
6949 * c-common.c (do_warn_unused_parameter): Move here.
6950 * c-common.h (do_warn_unused_parameter): Declare.
6951
b155cfd9
MP
69522015-06-29 Marek Polacek <polacek@redhat.com>
6953
6954 PR c/66322
6955 * c-common.c (check_case_bounds): Add bool * parameter. Set
6956 OUTSIDE_RANGE_P.
6957 (c_add_case_label): Add bool * parameter. Pass it down to
6958 check_case_bounds.
6959 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
6960 warning here.
6961 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
6962 declarations.
6963
31521951
MP
69642015-06-27 Marek Polacek <polacek@redhat.com>
6965
6966 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
6967 or VECTOR_INTEGER_TYPE_P throughout.
6968 * c-gimplify.c: Likewise.
6969
22d03525
MP
69702015-06-26 Marek Polacek <polacek@redhat.com>
6971
6972 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
6973 * c-common.c (c_fully_fold_internal): Likewise.
6974 (c_alignof_expr): Likewise.
6975 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
6976 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
b1726d6c 6977 * cilk.c (create_parm_list): Likewise.
22d03525 6978
af05e6e5
MP
69792015-06-26 Marek Polacek <polacek@redhat.com>
6980
6981 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
6982
f0889939
AM
69832015-06-25 Andrew MacLeod <amacleod@redhat.com>
6984
6985 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
6986 * c-gimplify.c: Likewise.
6987 * c-pragma.c: Likewise.
6988 * c-ubsan.c: Likewise.
6989 * cilk.c: Likewise.
6990
ca752f39
RS
69912015-06-25 Richard Sandiford <richard.sandiford@arm.com>
6992
6993 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
6994 ggc_hasher.
6995
16a16ec7
AM
69962015-06-25 Andrew MacLeod <amacleod@redhat.com>
6997
6998 * cilk.c: Move calls.h after tm.h in the include chain.
6999
0ae9bd27
MP
70002015-06-25 Marek Polacek <polacek@redhat.com>
7001
7002 * array-notation-common.c: Use VAR_P throughout.
7003 * c-ada-spec.c: Likewise.
7004 * c-common.c: Likewise.
7005 * c-format.c: Likewise.
7006 * c-gimplify.c: Likewise.
7007 * c-omp.c: Likewise.
7008 * c-pragma.c: Likewise.
7009 * c-pretty-print.c: Likewise.
7010 * cilk.c: Likewise.
7011
62f9079a
MP
70122015-06-25 Marek Polacek <polacek@redhat.com>
7013
7014 * cilk.c (extract_free_variables): Use is_global_var.
7015
0fa16060
RS
70162015-06-23 Richard Sandiford <richard.sandiford@arm.com>
7017
7018 * c-common.c: Don't include target-def.h.
7019
a68ae2e1
MP
70202015-06-23 Marek Polacek <polacek@redhat.com>
7021
7022 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
7023 when comparing INTEGER_CSTs.
7024
c6a2f2d9
PMR
70252015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
7026
7027 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
7028 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
7029 (dump_ada_template): Skip partially specialized types.
7030
6b4db501
MM
70312015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
7032
7033 * c-common.c (scalar_to_vector): Use std::swap instead of manually
7034 swapping.
7035
abb226c9
AM
70362015-06-17 Andrew MacLeod <amacleod@redhat.com>
7037
7038 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
7039 * c-ada-spec.c: Likewise.
7040 * c-cilkplus.c: Likewise.
7041 * c-common.c: Likewise.
7042 * c-common.h: Likewise.
7043 * c-cppbuiltin.c: Likewise.
7044 * c-dump.c: Likewise.
7045 * c-format.c: Likewise.
7046 * c-gimplify.c: Likewise.
7047 * c-indentation.c: Likewise.
7048 * c-lex.c: Likewise.
7049 * c-omp.c: Likewise.
7050 * c-opts.c: Likewise.
7051 * c-pch.c: Likewise.
7052 * c-ppoutput.c: Likewise.
7053 * c-pragma.c: Likewise.
7054 * c-pretty-print.c: Likewise.
7055 * c-semantics.c: Likewise.
7056 * c-ubsan.c: Likewise.
7057 * cilk.c: Likewise.
7058 * stub-objc.c: Likewise.
7059
076fecad
PP
70602015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
7061
7062 PR c++/65168
7063 * c-common.c (c_common_truthvalue_conversion): Warn when
7064 converting an address of a reference to a truth value.
7065
13fdf2e2
AM
70662015-06-08 Andrew MacLeod <amacleod@redhat.com>
7067
7068 * array-notation-common.c : Adjust include files.
7069 * c-ada-spec.c : Likewise.
7070 * c-cilkplus.c : Likewise.
7071 * c-common.c : Likewise.
7072 * c-common.h : Likewise.
7073 * c-cppbuiltin.c : Likewise.
7074 * c-dump.c : Likewise.
7075 * c-format.c : Likewise.
7076 * c-gimplify.c : Likewise.
7077 * c-indentation.c : Likewise.
7078 * c-lex.c : Likewise.
7079 * c-omp.c : Likewise.
7080 * c-opts.c : Likewise.
7081 * c-pch.c : Likewise.
7082 * c-ppoutput.c : Likewise.
7083 * c-pragma.c : Likewise.
7084 * c-pretty-print.c : Likewise.
7085 * c-semantics.c : Likewise.
7086 * c-ubsan.c : Likewise.
7087 * cilk.c : Likewise.
7088 * stub-objc.c : Likewise.
7089
a1661b90
MP
70902015-06-08 Marek Polacek <polacek@redhat.com>
7091
7092 PR c/66415
7093 * c-format.c (location_from_offset): Return LOC if LINE is null.
7094
d7438551
AH
70952015-06-05 Aldy Hernandez <aldyh@redhat.com>
7096
7097 * c-common.h (c_parse_final_cleanups): New prototype.
7098 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
7099
b3d5bc62
JJ
71002015-06-04 Sriraman Tallam <tmsriram@google.com>
7101
7102 * c-common.c (noplt): New attribute.
7103 (handle_noplt_attribute): New handler.
7104
ecb9f223
AM
71052015-06-04 Andrew MacLeod <amacleod@redhat.com>
7106
7107 * array-notation-common.c: Adjust includes for restructured coretypes.h.
7108 * c-ada-spec.c: Likewise.
7109 * c-cilkplus.c: Likewise.
7110 * c-common.c: Likewise.
7111 * c-common.h: Likewise.
7112 * c-cppbuiltin.c: Likewise.
7113 * c-dump.c: Likewise.
7114 * c-format.c: Likewise.
7115 * c-gimplify.c: Likewise.
7116 * c-indentation.c: Likewise.
7117 * c-lex.c: Likewise.
7118 * c-omp.c: Likewise.
7119 * c-opts.c: Likewise.
7120 * c-pch.c: Likewise.
7121 * c-ppoutput.c: Likewise.
7122 * c-pragma.c: Likewise.
7123 * c-pretty-print.c: Likewise.
7124 * c-semantics.c: Likewise.
7125 * c-ubsan.c: Likewise.
7126 * cilk.c: Likewise.
7127 * stub-objc.c: Likewise.
7128
6ac48155
DM
71292015-06-02 David Malcolm <dmalcolm@redhat.com>
7130
7131 PR c/66220:
7132 * c-indentation.c (should_warn_for_misleading_indentation): Use
7133 expand_location rather than expand_location_to_spelling_point.
7134 Don't warn if the guarding statement is more indented than the
7135 next/body stmts.
7136
773ce42e
DM
71372015-06-02 David Malcolm <dmalcolm@redhat.com>
7138
7139 * c-indentation.c (warn_for_misleading_indentation): Bail out
7140 immediately if -Wmisleading-indentation isn't enabled.
7141
4fef8379
ML
71422015-06-01 Martin Liska <mliska@suse.cz>
7143
7144 * c-format.c (check_format_arg):Use new type-based pool allocator.
7145 (check_format_info_main) Likewise.
7146
1edfb384
EB
71472015-05-31 Eric Botcazou <ebotcazou@adacore.com>
7148
7149 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
7150 (has_nontrivial_methods): Likewise.
7151
9677ef52
MP
71522015-05-25 Marek Polacek <polacek@redhat.com>
7153
7154 * c-ubsan.c (ubsan_instrument_shift): Use type0.
7155
fd5c817a
MP
71562015-05-22 Marek Polacek <polacek@redhat.com>
7157
7158 PR c/47043
7159 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
7160
a2f45fe6 71612015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
581edfa3
TS
7162
7163 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
7164 STACK_GROWS_DOWNWARD.
7165
a2f45fe6 71662015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
62f9f30b
TS
7167
7168 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
7169 STACK_GROWS_DOWNWARD rather than if it is defined.
7170
0fee2ac2 71712015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
b1726d6c 7172
0fee2ac2
MLI
7173 PR c/52952
7174 * c-format.c (location_column_from_byte_offset): New.
7175 (location_from_offset): New.
7176 (struct format_wanted_type): Add offset_loc field.
7177 (check_format_info): Move handling of location for extra arguments
7178 closer to the point of warning.
7179 (check_format_info_main): Pass the result of location_from_offset
7180 to warning_at.
7181 (format_type_warning): Pass the result of location_from_offset
7182 to warning_at.
7183
cf4ef6f7
MP
71842015-05-20 Marek Polacek <polacek@redhat.com>
7185
7186 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
7187
3a65ee74
MP
71882015-05-20 Marek Polacek <polacek@redhat.com>
7189
7190 * c-ada-spec.c (dump_sloc): Use DECL_P.
7191
21b634ae
MP
71922015-05-20 Marek Polacek <polacek@redhat.com>
7193
7194 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
7195 * c-common.c: Likewise.
7196
0e50b624
DM
71972015-05-19 David Malcolm <dmalcolm@redhat.com>
7198
7199 * c-common.h (fe_file_change): Strengthen param from
7200 const line_map * to const line_map_ordinary *.
7201 (pp_file_change): Likewise.
7202 * c-lex.c (fe_file_change): Likewise.
7203 (cb_define): Use linemap_check_ordinary when invoking
7204 SOURCE_LINE.
7205 (cb_undef): Likewise.
7206 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
7207 invoking cb_file_change.
7208 (c_finish_options): Likewise.
7209 (push_command_line_include): Likewise.
7210 (cb_file_change): Strengthen param "new_map" from
7211 const line_map * to const line_map_ordinary *.
7212 * c-ppoutput.c (cb_define): Likewise for local "map".
7213 (pp_file_change): Likewise for param "map" and local "from".
7214
fab27f52
MM
72152015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
7216
7217 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
7218
2fe1d762
TV
72192015-05-18 Tom de Vries <tom@codesourcery.com>
7220
7221 * c-common.c (build_va_arg_1): New function.
7222 (build_va_arg): Add address operator to va_list operand if necessary.
7223
7a37fa90
MM
72242015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
7225
7226 PR c/48956
7227 * c-common.c (int_safely_convertible_to_real_p): Define.
7228 (unsafe_conversion_p): Check conversions involving complex types.
7229 (conversion_warning): Add new warning message for conversions which
7230 discard imaginary component.
7231 * c-common.h: (enum conversion_safety): Add new enumerator for such
7232 conversions.
7233
3aa3c9fc
MP
72342015-05-14 Marek Polacek <polacek@redhat.com>
7235
7236 PR c/66066
7237 PR c/66127
7238 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
7239 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
7240 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
7241 use it. If FOR_INT_CONST, require that all evaluated operands be
7242 INTEGER_CSTs.
7243
c3388e62
DM
72442015-05-12 David Malcolm <dmalcolm@redhat.com>
7245
7246 * c-common.h (warn_for_misleading_indentation): New prototype.
7247 * c-indentation.c: New file.
7248 * c.opt (Wmisleading-indentation): New option.
7249
c7b38fd5
TV
72502015-05-12 Tom de Vries <tom@codesourcery.com>
7251
7252 PR tree-optimization/66010
7253 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
7254
381bf11e
JM
72552015-05-09 Jason Merrill <jason@redhat.com>
7256
edff0c06
JM
7257 * c-opts.c (c_common_post_options): Also clear
7258 cpp_opts->cpp_warn_cxx11_compat.
7259
129211bc
JM
7260 * c-common.h (enum cxx_dialect): Add cxx_unset.
7261 * c-common.c (cxx_dialect): Initialize to cxx_unset.
7262 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
7263
381bf11e
JM
7264 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
7265 (std=gnu++0x): Mark as Undocumented.
7266 (std=gnu++1y): Add deprecated message.
7267
fe191308
JM
72682015-05-08 Jason Merrill <jason@redhat.com>
7269
765189ff
JM
7270 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
7271 * c-opts.c: Adjust.
7272
fe191308
JM
7273 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
7274
755e528f
MP
72752015-05-08 Marek Polacek <polacek@redhat.com>
7276
7277 PR c/64918
7278 * c.opt (Woverride-init-side-effects): New option.
7279
0173bd2a
MP
72802015-05-07 Marek Polacek <polacek@redhat.com>
7281
7282 PR c/65179
7283 * c-common.c (c_fully_fold_internal): Warn when left shifting a
7284 negative value.
7285 * c.opt (Wshift-negative-value): New option.
7286 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
7287 when -Wextra and C99/C++11 mode.
7288
e0f0d3b9
MP
72892015-05-07 Marek Polacek <polacek@redhat.com>
7290 Martin Uecker <uecker@eecs.berkeley.edu>
7291
7292 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
7293 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
7294
8243e2a9
JM
72952015-05-05 Jason Merrill <jason@redhat.com>
7296
7297 * c.opt (Wterminate): New.
7298
577cd070
MP
72992015-04-30 Marek Polacek <polacek@redhat.com>
7300
7301 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
7302 require that the non-constant be of a boolean type.
7303
0373796b
JT
73042015-04-29 Josh Triplett <josh@joshtriplett.org>
7305
e0f0d3b9
MP
7306 * c-common.c (handle_section_attribute): Refactor to reduce
7307 nesting and distinguish between error cases.
0373796b 7308
716c0ba6
MP
73092015-04-29 Marek Polacek <polacek@redhat.com>
7310
7311 PR c/64610
7312 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
7313 with 0/1.
7314
8848828b
JJ
73152015-04-29 Jakub Jelinek <jakub@redhat.com>
7316
7317 * c-common.h (omp_clause_mask): Unconditionally define as a class.
7318 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
7319 HOST_BITS_PER_WIDE_INT.
7320
ecd0e562
TV
73212015-04-28 Tom de Vries <tom@codesourcery.com>
7322
7323 PR tree-optimization/65887
7324 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
7325
2a877204 73262015-04-28 Eric Botcazou <ebotcazou@adacore.com>
e0f0d3b9 7327 Pierre-Marie de Rodat <derodat@adacore.com>
2a877204
EB
7328
7329 * c-ada-spec.c (in_function): Delete.
7330 (dump_generic_ada_node): Do not change in_function and remove the
7331 redundant code dealing with it.
7332 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
7333 (print_ada_methods): Output the static member functions in a nested
7334 package after the regular methods as well as associated renamings.
7335
4853031e
MP
73362015-04-24 Marek Polacek <polacek@redhat.com>
7337
7338 PR c/65830
7339 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
7340 and OPT_Wshift_count_overflow.
7341
8c2b7f79
MP
7342 PR c/63357
7343 * c-common.c (warn_logical_operator): Warn if the operands have the
7344 same expressions.
7345
b8787813
MP
73462015-04-24 Marek Polacek <polacek@redhat.com>
7347
7348 PR c/61534
7349 * c-common.c (warn_logical_operator): Bail if either operand comes
7350 from a macro expansion.
7351
8fba1830
BRF
73522015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
7353
7354 PR target/55143
7355 * c-common.c (c_default_pointer_mode): Add definition.
7356 * c-common.h (c_default_pointer_mode): Add declaration.
7357
17958621
JJ
73582015-03-11 Jakub Jelinek <jakub@redhat.com>
7359
7360 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
7361 on record_builtin_type argument.
7362
7ccb1a11
JJ
73632015-03-10 Jakub Jelinek <jakub@redhat.com>
7364
7365 PR c/65120
7366 * c-common.c (warn_logical_not_parentheses): Don't warn for
7367 !x == 0 or !x != 0.
7368
04fd785e
MP
73692015-03-07 Marek Polacek <polacek@redhat.com>
7370
7371 PR sanitizer/65280
7372 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
7373 before trying to figure out whether we have a flexible array member.
7374
a4e26206 73752015-03-06 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 7376 Jonathan Wakely <jwakely.gcc@gmail.com>
a4e26206
EB
7377
7378 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
7379
0d2489f4
EB
73802015-03-05 Eric Botcazou <ebotcazou@adacore.com>
7381
7382 PR ada/65319
7383 * c-ada-spec.c (print_destructor): Remove obsolete code.
7384
83ed54d7
EB
73852015-03-01 Eric Botcazou <ebotcazou@adacore.com>
7386
7387 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
7388 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
7389 DECL_TEMPLATE_RESULT emulations.
7390 (dump_ada_template)): Add guard for TYPE_METHODS.
7391
7631f0e2
MP
73922015-02-27 Marek Polacek <polacek@redhat.com>
7393
7394 PR c/65040
7395 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
7396
d1783ae5
KT
73972015-02-27 Kai Tietz <ktietz@redhat.com>
7398
7399 PR c/35330
7400 * c-pragma.c (handle_pragma_weak): Do not try to create
7401 weak/alias of declarations not being function, or variable
7402 declarations.
7403
56a9f6bc
TS
74042015-02-24 Thomas Schwinge <thomas@codesourcery.com>
7405
7406 PR libgomp/64625
7407 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
7408 Remove macros.
7409 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
7410
3d5cb23d
MP
74112015-02-16 Marek Polacek <polacek@redhat.com>
7412
7413 PR c/65066
7414 * c-format.c (check_format_types): Handle null param.
7415
fa008882
MP
74162015-02-13 Marek Polacek <polacek@redhat.com>
7417
7418 PR c/65040
7419 * c-format.c (check_format_types): Don't warn about different
7420 signedness if the original value is in the range of WANTED_TYPE.
7421
785f21af
JM
74222015-02-12 Jason Merrill <jason@redhat.com>
7423
7424 PR c++/64956
7425 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
7426 to the current highest version.
7427 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
7428
4886ec8e
JJ
74292015-02-04 Jakub Jelinek <jakub@redhat.com>
7430
7431 PR c/64824
7432 PR c/64868
7433 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
7434 instead of RDIV_EXPR. Use build_binary_op instead of
7435 build2_loc.
7436
40fecdd6
JM
74372015-01-30 Joseph Myers <joseph@codesourcery.com>
7438
7439 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
7440 to pass input_location as first argument.
7441
a0c88d06
TV
74422015-01-23 Tom de Vries <tom@codesourcery.com>
7443
7444 PR libgomp/64672
7445 * c.opt (fopenacc): Mark as LTO option.
7446
1506ae0e
TV
74472015-01-23 Tom de Vries <tom@codesourcery.com>
7448
7449 PR libgomp/64707
7450 * c.opt (fopenmp): Mark as LTO option.
7451
31be63ab
JJ
74522015-01-21 Jakub Jelinek <jakub@redhat.com>
7453
7454 PR c/63307
b1726d6c 7455 * cilk.c (fill_decls_vec): Only put decls into vector v.
31be63ab
JJ
7456 (compare_decls): Fix up formatting.
7457
74582015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
7459
7460 PR c/63307
7461 * cilk.c: Include vec.h.
7462 (struct cilk_decls): New structure.
7463 (wrapper_parm_cb): Split this function to...
7464 (fill_decls_vec): ...this...
7465 (create_parm_list): ...and this.
7466 (compare_decls): New function.
7467 (for_local_cb): Remove.
7468 (wrapper_local_cb): Ditto.
7469 (build_wrapper_type): For now first traverse and fill vector of
7470 declarations then sort it and then deal with sorted vector.
7471 (cilk_outline): Ditto.
7472 (declare_one_free_variable): Ditto.
7473
6875457f
JM
74742015-01-21 Jason Merrill <jason@redhat.com>
7475
7476 PR c++/64629
7477 * c-format.c (check_format_arg): Call decl_constant_value.
7478
185c9e56
ML
74792015-01-19 Martin Liska <mliska@suse.cz>
7480
7481 * c-common.c (handle_noicf_attribute): New function.
7482
41dbbb37
TS
74832015-01-15 Thomas Schwinge <thomas@codesourcery.com>
7484 Bernd Schmidt <bernds@codesourcery.com>
7485 James Norris <jnorris@codesourcery.com>
7486 Cesar Philippidis <cesar@codesourcery.com>
7487 Ilmir Usmanov <i.usmanov@samsung.com>
7488 Jakub Jelinek <jakub@redhat.com>
7489
7490 * c.opt (fopenacc): New option.
7491 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
7492 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
7493 New macros.
7494 * c-common.h (c_finish_oacc_wait): New prototype.
7495 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
7496 (c_finish_oacc_wait): New function.
7497 * c-pragma.c (oacc_pragmas): New variable.
7498 (c_pp_lookup_pragma, init_pragma): Handle it.
7499 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
7500 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
7501 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
7502 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
7503 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
7504 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
7505 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
7506 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
7507 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
7508 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
7509 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
7510 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
7511 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
7512 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
7513 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
7514 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
7515 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
7516 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
7517 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
7518 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
7519 PRAGMA_OACC_CLAUSE_WORKER.
7520
3f8257db 75212015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
5434dc07
MD
7522
7523 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
7524 for the new option fstack-protector_explicit.
7525 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
7526 (handle_stack_protect_attribute): New function.
7527
3f8257db 75282015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
de1b5c17
MU
7529
7530 * c.opt: New option -Warray-bounds=.
7531
adfac8df
JJ
75322015-01-09 Michael Collison <michael.collison@linaro.org>
7533
7534 * array-notation-common.c: Include hash-set.h, machmode.h,
7535 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7536 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
7537 * c-ada-spec.c: Ditto.
7538 * c-cilkplus.c: Ditto.
7539 * c-common.c: Include input.h due to flattening of tree.h.
7540 Define macro GCC_C_COMMON_C.
7541 * c-common.h: Flatten tree.h header files into c-common.h.
7542 Remove include of tree-core.h.
7543 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
7544 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7545 fold-const.h, wide-int.h, and inchash.h due to
7546 flattening of tree.h.
7547 * c-dump.c: Ditto.
7548 * c-format.c: Flatten tree.h header files into c-common.h.
7549 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
7550 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7551 fold-const.h, wide-int.h, and inchash.h due to
7552 flattening of tree.h.
7553 * c-dump.c: Include hash-set.h, machmode.h,
7554 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7555 fold-const.h, wide-int.h, and inchash.h due to
7556 flattening of tree.h.
7557 * c-format.c: Include hash-set.h, machmode.h,
7558 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7559 fold-const.h, wide-int.h, inchash.h and real.h due to
7560 flattening of tree.h.
7561 * c-gimplify.c: Include hash-set.h, machmode.h,
7562 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7563 fold-const.h, wide-int.h, and inchash.h due to
7564 flattening of tree.h.
7565 * cilk.c: Ditto.
7566 * c-lex.c: Ditto.
7567 * c-omp.c: Ditto.
7568 * c-opts.c: Ditto.
7569 * c-pch.c: Ditto.
7570 * c-ppoutput.c: Ditto.
7571 * c-pragma.c: Ditto.
7572 * c-pretty-print.c: Ditto.
7573 * c-semantics.c: Ditto.
7574 * c-ubsan.c: Ditto.
7575 * stub-objc.c: Ditto.
7576
f5481fc4
JM
75772015-01-08 Jason Merrill <jason@redhat.com>
7578
7579 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
7580 do_ubsan_in_current_function.
7581 (ubsan_maybe_instrument_reference_or_call): Likewise.
7582 * c-ubsan.h: Declare it.
7583
de35aa66
MS
75842015-01-08 Mike Stump <mikestump@comcast.net>
7585
7586 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
7587
4a9a42ab
MP
75882015-01-07 Marek Polacek <polacek@redhat.com>
7589
7590 PR c/64440
7591 * c-common.c (c_fully_fold_internal): Warn for division and modulo
7592 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
7593
2f42e5de
TS
75942015-01-05 Trevor Saunders <tsaunders@mozilla.com>
7595
7596 PR c++/31397
7597 * c.opt (Wsuggest-override): New option.
7598
5624e564
JJ
75992015-01-05 Jakub Jelinek <jakub@redhat.com>
7600
7601 Update copyright years.
7602
5bd012f8
MP
76032015-01-05 Marek Polacek <polacek@redhat.com>
7604
7605 PR c/64423
7606 * c-common.c (warn_array_subscript_with_type_char): Add location_t
7607 parameter. Use it.
7608 * c-common.h (warn_array_subscript_with_type_char): Update
7609 declaration.
7610
a7fa8d18
ESR
76112014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
7612
7613 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
7614 Control macro with flag_sized_deallocation.
7615
3f8257db 76162014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
768952be
MU
7617
7618 * c.opt (Wdiscarded-array-qualifiers): New option.
7619
1f8d3e84
JJ
76202014-12-19 Jakub Jelinek <jakub@redhat.com>
7621
7622 PR preprocessor/63831
7623 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
7624 and __has_cpp_attribute here.
7625 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
7626 c_common_has_attribute.
7627 * c-common.h (c_common_has_attribute): New prototype.
7628 * c-lex.c (init_c_lex): Set cb->has_attribute to
7629 c_common_has_attribute instead of cb_has_attribute.
7630 (get_token_no_padding): New function.
7631 (cb_has_attribute): Renamed to ...
7632 (c_common_has_attribute): ... this. No longer static. Use
7633 get_token_no_padding, require ()s, don't build TREE_LIST
7634 unnecessarily, fix up formatting, adjust diagnostics, call
7635 init_attributes.
7636
20b06add
JM
76372014-12-15 Jason Merrill <jason@redhat.com>
7638
7639 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
7640 (-Wsized-deallocation): New.
7641 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
7642 to on in C++14 and up.
7643
94a073b2
JM
76442014-12-11 Jason Merrill <jason@redhat.com>
7645
acaa5911
JM
7646 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
7647
94a073b2
JM
7648 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
7649 we aren't complaining about VLAs.
7650
7fb66c15
MP
76512014-12-06 Marek Polacek <polacek@redhat.com>
7652
7653 PR tree-optimization/64183
7654 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
7655 shift-expression if it is integer_type_node. Use types_compatible_p.
7656
b731b390
JJ
76572014-11-29 Jakub Jelinek <jakub@redhat.com>
7658
7659 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
7660 last argument from create_tmp_var_raw and create_tmp_var calls.
7661 * cilk.c (gimplify_cilk_spawn): Likewise.
7662 * c-omp.c (c_finish_omp_atomic): Likewise.
7663
6a4da643
MP
76642014-11-28 Marek Polacek <polacek@redhat.com>
7665
7666 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
7667 instead of unsigned_type_node.
7668
541e35a6
MP
76692014-11-28 Marek Polacek <polacek@redhat.com>
7670
7671 PR c/63862
7672 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
7673 to op1_utype.
7674 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
7675 expression to unsigned_type_node.
7676
dcc97066
MW
76772014-11-20 Mark Wielaard <mjw@redhat.com>
7678
7679 PR debug/38757
7680 * c-opts.c (set_std_c89): Set lang_hooks.name.
7681 (set_std_c99): Likewise.
7682 (set_std_c11): Likewise.
7683 (set_std_cxx98): Likewise.
7684 (set_std_cxx11): Likewise.
7685 (set_std_cxx14): Likewise.
7686 (set_std_cxx1z): Likewise.
7687
aa7da51a
JJ
76882014-11-21 Jakub Jelinek <jakub@redhat.com>
7689
7690 PR target/63764
7691 * c-common.h (convert_vector_to_pointer_for_subscript): Change
7692 return type to bool.
009a3480 7693 * c-common.c: Include gimple-expr.h.
aa7da51a
JJ
7694 (convert_vector_to_pointer_for_subscript): Change return type to
7695 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
7696 and copy it into a TARGET_EXPR and use that instead of *vecp
7697 directly.
7698
538dd0b7
DM
76992014-11-19 David Malcolm <dmalcolm@redhat.com>
7700
7701 Merger of git branch "gimple-classes-v2-option-3".
7702 * ChangeLog.gimple-classes: New.
7703 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
7704 from being just a vec<gimple> to a vec<gbind *>.
7705
c39a5e99
JJ
77062014-11-18 Jakub Jelinek <jakub@redhat.com>
7707
7708 PR sanitizer/63813
7709 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
7710 argument to ptype, set type to TREE_TYPE (ptype). Don't call
7711 get_pointer_alignment for non-pointers. Use ptype, or if it is
7712 reference type, corresponding pointer type, as type of kind
7713 argument.
7714 (ubsan_maybe_instrument_reference,
7715 ubsan_maybe_instrument_member_call): Adjust callers.
7716
8537a4a9
MP
77172014-11-15 Marek Polacek <polacek@redhat.com>
7718
7719 PR middle-end/63884
7720 * array-notation-common.c (is_sec_implicit_index_fn): Return false
7721 for NULL fndecl.
7722 (extract_array_notation_exprs): Return for NULL node.
7723
2079956a
JM
77242014-11-12 Joseph Myers <joseph@codesourcery.com>
7725
7726 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
7727 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
7728
1304953e
JJ
77292014-11-12 Jakub Jelinek <jakub@redhat.com>
7730
7731 PR c/59708
7732 * c-common.c (check_builtin_function_arguments): Handle
7733 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
7734
e5e44252
AK
77352014-11-10 Andi Kleen <ak@linux.intel.com>
7736
7737 PR c/60804
7738 * c-common.h (check_no_cilk): Declare.
7739 * cilk.c (get_error_location): New function.
7740 (check_no_cilk): Dito.
7741
e64b984d
AK
77422014-11-10 Andi Kleen <ak@linux.intel.com>
7743
7744 * cilk.c (recognize_spawn): Use expression location
7745 for error message.
7746
13c21655
PC
77472014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
7748
7749 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
7750
42fd12b1
ESR
77512014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
7752
7753 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
7754 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
7755 (__cpp_range_based_for, __cpp_initializer_lists,
7756 __cpp_delegating_constructors, __cpp_nsdmi,
7757 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
7758 for C++11; (__cpp_attribute_deprecated): Remove in favor of
7759 __has_cpp_attribute.
7760 * c-lex.c (cb_has_attribute): New callback CPP function;
7761 (init_c_lex): Set has_attribute callback.
7762
6f450181
RB
77632014-11-04 Richard Biener <rguenther@suse.de>
7764
7765 * c-common.c (shorten_compare): Do not shorten mixed
7766 DFP and non-DFP compares.
7767
26f0e1d6
ESR
77682014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
7769
7770 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
7771 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
7772 Commentary and rearrangement of tests.
7773 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
7774 Commentary and rearrangement of tests.
ab20d992 7775 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
26f0e1d6
ESR
7776 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
7777
ef4bddc2
RS
77782014-10-29 Richard Sandiford <richard.sandiford@arm.com>
7779
7780 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
7781 enum from machine_mode.
7782
c582198b
AM
77832014-10-28 Andrew MacLeod <amacleod@redhat.com>
7784
adfac8df
JJ
7785 * c-common.c: Adjust include files.
7786 * c-gimplify.c: Ditto.
7787 * cilk.c: Ditto.
7788 * c-pragma.c: Ditto.
7789 * c-ubsan.c: Ditto.
c582198b 7790
60393bbc
AM
77912014-10-27 Andrew MacLeod <amacleod@redhat.com>
7792
7793 * c-gimplify.c: Adjust include files.
7794
d723bb7c
MLI
77952014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
7796
7797 PR c++/53061
7798 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
7799 c_common_initialize_diagnostics.
7800 * c-common.h: Likewise.
7801
90f3520e
MP
78022014-10-24 Marek Polacek <polacek@redhat.com>
7803
7804 PR c/56980
7805 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
7806 print "struct"/"union"/"enum" for typedefed names.
7807
59d7607a
MP
78082014-10-23 Marek Polacek <polacek@redhat.com>
7809
7810 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
7811 in unsigned type.
7812
d95a2703
JJ
78132014-10-22 Jakub Jelinek <jakub@redhat.com>
7814 Yury Gribov <y.gribov@samsung.com>
7815
7816 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
7817 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
7818 instead of flag_sanitize_recover as bool flag.
7819
8e6ef852
KY
78202014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
7821
7822 * cilk.c: Revert previous change.
7823
948cf550
IZ
78242014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
7825
7826 PR c/63307
7827 * cilk.c: Include vec.h.
7828 (struct cilk_decls): New structure.
7829 (wrapper_parm_cb): Split this function to...
7830 (fill_decls_vec): ...this...
7831 (create_parm_list): ...and this.
7832 (compare_decls): New function.
7833 (for_local_cb): Remove.
7834 (wrapper_local_cb): Ditto.
7835 (build_wrapper_type): For now first traverse and fill vector of
7836 declarations then sort it and then deal with sorted vector.
7837 (cilk_outline): Ditto.
7838 (declare_one_free_variable): Ditto.
7839
92574c7c
MP
78402014-10-17 Marek Polacek <polacek@redhat.com>
7841
7842 * c-opts.c (c_common_post_options): Set warn_implicit_int.
7843 * c.opt (Wimplicit-int): Initialize to -1.
7844
83685514
AM
78452014-10-16 Andrew MacLeod <amacleod@redhat.com>
7846
7847 * c-pragma.c: Adjust include files.
7848 * c-semantics.c: Likewise.
7849
5b8300ea
DD
78502014-10-16 DJ Delorie <dj@redhat.com>
7851
7852 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
7853 multiples of bytes.
7854
5f83e90b
JM
78552014-10-14 Jason Merrill <jason@redhat.com>
7856
7857 PR c++/63455
7858 * c-common.h (CPP_PREPARSED_EXPR): New.
7859 (N_CP_TTYPES): Adjust.
7860
d73326ca
MP
78612014-10-15 Marek Polacek <polacek@redhat.com>
7862
7863 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
7864
78a7c317
DD
78652014-10-14 DJ Delorie <dj@redhat.com>
7866
7867 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
7868 types, not just __int128.
7869 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
7870 types, not just __int128.
7871 (cpp_atomic_builtins): Round pointer sizes up.
7872 (type_suffix): Use type precision, not specific types.
7873 * c-common.c (c_common_reswords): Remove __int128 special case.
7874 (c_common_type_for_size): Check for all __intN types, not just
7875 __int128.
7876 (c_common_type_for_mode): Likewise.
7877 (c_common_signed_or_unsigned_type): Likewise.
7878 (c_build_bitfield_integer_type): Likewise.
7879 (c_common_nodes_and_builtins): Likewise.
7880 (keyword_begins_type_specifier): Likewise.
7881 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
7882 __intN variants.
7883
2a22f99c
TS
78842014-10-12 Trevor Saunders <tsaunders@mozilla.com>
7885
7886 * c-common.c: Use hash_table instead of hashtab.
7887
2a8ef767
ESR
78882014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
7889
adfac8df 7890 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
2a8ef767
ESR
7891 C++11 section.
7892
3c9aabbd
MG
78932014-10-03 Marc Glisse <marc.glisse@inria.fr>
7894
7895 PR c++/54427
7896 PR c++/57198
7897 PR c++/58845
7898 * c-common.c (warn_logical_operator): Punt for vectors.
7899
a15f7cb8
ESR
79002014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
7901
7902 Implement SD-6: SG10 Feature Test Recommendations
7903 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
7904 macros and the __has_header macro.
7905
8d0cf15e
JM
79062014-09-30 Jason Merrill <jason@redhat.com>
7907
dd5d5481
JM
7908 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
7909 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
7910 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
7911
b752325e
JM
7912 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
7913 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
7914
8d0cf15e
JM
7915 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
7916 * c-common.c (c_common_reswords): Remove __is_convertible_to.
7917
083e891e
MP
79182014-09-24 Marek Polacek <polacek@redhat.com>
7919
7920 PR c/61405
7921 PR c/53874
7922 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
7923
7861b648
AK
79242014-09-23 Andi Kleen <ak@linux.intel.com>
7925
7926 * c-common.c (handle_no_reorder_attribute): New function.
7927 (c_common_attribute_table): Add no_reorder attribute.
7928
9a79452d
JM
79292014-09-22 Joseph Myers <joseph@codesourcery.com>
7930
7931 * c-cppbuiltin.c (c_cpp_builtins): Define
7932 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
7933 modes.
7934
dd69f047
JM
79352014-09-18 Joseph Myers <joseph@codesourcery.com>
7936
7937 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
7938 for supported floating-point modes.
7939
737a4826
MLI
79402014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
7941
7942 * c.opt (Wpsabi): Use LangEnabledBy.
7943 * c-opts.c (c_common_handle_option): Do not handle here.
7944
8cc4b7a2
JM
79452014-09-12 Joseph Myers <joseph@codesourcery.com>
7946
7947 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
7948 macros for floating-point modes.
7949
179b5a55
MG
79502014-09-11 Marc Glisse <marc.glisse@inria.fr>
7951
7952 PR target/58757
7953 * c-cppbuiltin.c (builtin_define_float_constants): Correct
7954 __*_DENORM_MIN__ without denormals.
7955
570a11fe
JJ
79562014-09-10 Jakub Jelinek <jakub@redhat.com>
7957
7958 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
7959 ubsan_instrument_vla, ubsan_instrument_return): Adjust
7960 ubsan_create_data callers.
7961 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
7962 index is constant or BIT_AND_EXPR with constant mask and is
7963 small enough for the bound.
7964 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
7965 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
7966
b559c810
MLI
79672014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
7968
7969 * c.opt: Add CppReason to various flags.
7970 (Wdate-time): Re-sort.
7971 * c-common.c: Include c-common.h earlier.
7972 (struct reason_option_codes_t): Delete.
7973 (c_option_controlling_cpp_error): Prefix global type and struct
7974 with cpp_.
7975
1ef33fd4
MLI
79762014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
7977
7978 * c.opt (Wnormalized): New.
7979 (Wnormalized=): Use Enum and Reject Negative.
7980 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
7981
66bb34c0
JM
79822014-09-08 Joseph Myers <joseph@codesourcery.com>
7983
7984 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
7985 digits of floating-point modes if -fbuilding-libgcc.
7986
53d68b9f
JM
79872014-09-05 Joseph Myers <joseph@codesourcery.com>
7988
7989 * c-cppbuiltin.c (c_cpp_builtins): Also define
7990 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
7991 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
7992 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
7993 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
7994 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
7995 __LIBGCC_STACK_GROWS_DOWNWARD__,
7996 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
7997 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
7998 __LIBGCC_DWARF_FRAME_REGISTERS__,
7999 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
8000 __LIBGCC_STACK_POINTER_REGNUM__ and
8001 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
8002 (builtin_define_with_value): Handle backslash-escaping in string
8003 macro values.
8004
f65586dc
RB
80052014-09-05 Richard Biener <rguenther@suse.de>
8006
8007 PR middle-end/63148
8008 * c-format.c (check_format_arg): Properly handle
8009 effectively signed POINTER_PLUS_EXPR offset.
8010
2b71f4a4
MLI
80112014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
8012
8013 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
8014 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
8015 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
8016 and Init.
8017 * c-opts.c (c_common_handle_option): Do not handle here.
8018 (sanitize_cpp_opts): Likewise.
8019 * c-common.c (struct reason_option_codes_t): Handle
8020 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
8021
d2e4feca
MP
80222014-09-03 Marek Polacek <polacek@redhat.com>
8023
8024 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
8025
9a771876
JJ
80262014-09-02 Jakub Jelinek <jakub@redhat.com>
8027 Balaji V. Iyer <balaji.v.iyer@intel.com>
8028 Igor Zamyatin <igor.zamyatin@intel.com>
8029
8030 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
8031 * c-common.c (c_common_reswords): Added _Cilk_for.
8032 * c-common.h (enum rid): Added RID_CILK_FOR.
8033 (cilk_for_number_of_iterations): Add declaration.
8034 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
8035 CILK_FOR.
8036 * c-pragma.c (init_pragma): Register "grainsize" pragma.
8037 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
8038
81b5d104
MLI
80392014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
8040
8041 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
8042 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
8043 Wundef): Use CPP, Var and Init.
8044 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
8045
b753b37b
MLI
80462014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
8047
8048 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
8049 * c-opts.c (c_common_handle_option): Do not handle here.
8050
028aee17
JM
80512014-08-25 Jason Merrill <jason@redhat.com>
8052
8053 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
8054 -std=c++14 and -std=gnu++14, rather than the reverse.
8055 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
8056 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
8057 * c-common.h (cxx_dialect): Remove cxx1y.
8058
e4276ba5
ESR
80592014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
8060
8061 * c-common.h (enum cxx_dialect): Add cxx14.
8062 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
8063 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
8064 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
8065
a545cacd
JM
80662014-08-22 Jason Merrill <jason@redhat.com>
8067
8068 * c.opt (std=gnu++17): Fix alias.
8069
59ea0364
MP
80702014-08-22 Marek Polacek <polacek@redhat.com>
8071
8072 PR c++/62199
8073 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
8074 check for vector types. Drop LHS argument.
8075 * c-common.h (warn_logical_not_parentheses): Adjust.
8076
596e808c
MLI
80772014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
8078
8079 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
8080 (Wmultichar): Likewise.
8081 (Wdate-time): Use C-family languages instead of Common. Use CPP
8082 and Var.
8083 * c-opts.c (c_common_handle_option): Do not handle the above
8084 options here.
8085 (sanitize_cpp_opts): Likewise.
8086
18767f65
MLI
80872014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
8088
8089 PR fortran/44054
8090 * c-opts.c: Include tree-diagnostics.h.
8091 (c_diagnostic_finalizer): New.
8092 (c_common_initialize_diagnostics): Use it.
8093
b4413594
MLI
80942014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
8095
8096 PR preprocessor/51303
8097 * c-common.c (struct reason_option_codes_t option_codes):
8098 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
8099
43f9a13c
MLI
81002014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
8101
8102 PR c/60975
8103 PR c/53063
8104 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
8105 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
8106 (c_common_post_options): Call init_global_opts_from_cpp.
8107 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
8108
04159acf
MP
81092014-08-19 Marek Polacek <polacek@redhat.com>
8110
8111 PR c++/62153
8112 * c-common.c (maybe_warn_bool_compare): New function.
8113 * c-common.h (maybe_warn_bool_compare): Declare.
8114 * c.opt (Wbool-compare): New option.
8115
35aff4fb
MP
81162014-08-19 Marek Polacek <polacek@redhat.com>
8117
8118 * c.opt (Wc99-c11-compat): New option.
8119
177cce46
MP
81202014-08-19 Marek Polacek <polacek@redhat.com>
8121
8122 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
8123 to warn_c90_c99_compat.
8124 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
8125 to -1.
8126
6ae9194f
MLI
81272014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
8128 Steven Bosscher <steven@gcc.gnu.org>
8129
8130 PR c/52952
8131 * c-format.c: Add extra_arg_loc and format_string_loc to struct
8132 format_check_results.
8133 (check_function_format): Use true and add comment for boolean
8134 argument.
8135 (finish_dollar_format_checking): Use explicit location when warning.
8136 (check_format_info): Likewise.
8137 (check_format_arg): Set extra_arg_loc and format_string_loc.
8138 (check_format_info_main): Use explicit location when warning.
8139 (check_format_types): Pass explicit location.
8140 (format_type_warning): Likewise.
8141
8e54f6d3
MLI
81422014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
8143
8144 PR fortran/44054
8145 * c-format.c: Handle Fortran flags.
8146
cd4e76fc
IZ
81472014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
8148
8149 PR other/61962
8150 * array-notation-common.c (find_rank): Added handling for other
8151 types of references.
8152
f3bede71
MP
81532014-08-10 Marek Polacek <polacek@redhat.com>
8154
8155 PR c/51849
8156 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
8157 * c.opt (Wc90-c99-compat): Add option.
8158
9f25a338
TS
81592014-08-07 Trevor Saunders <tsaunders@mozilla.com>
8160
8161 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
8162
62e4eb35
MP
81632014-08-03 Marek Polacek <polacek@redhat.com>
8164
ab20d992 8165 * c-common.c (check_case_value): Add location_t parameter. Use it.
62e4eb35
MP
8166 (c_add_case_label): Pass loc to check_case_value.
8167
b787e7a2
TS
81682014-08-02 Trevor Saunders <tsaunders@mozilla.com>
8169
8170 * cilk.c: Use hash_map instead of pointer_map.
8171
6e2830c3
TS
81722014-08-02 Trevor Saunders <tsaunders@mozilla.com>
8173
8174 * c-gimplify.c: Use hash_set instead of pointer_set.
8175
a7ee52fb
IZ
81762014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
8177
8178 PR middle-end/61455
8179 * array-notation-common.c (extract_array_notation_exprs): Handling
8180 of DECL_EXPR added.
8181
944fa280
JJ
81822014-08-01 Jakub Jelinek <jakub@redhat.com>
8183
8184 * c-common.h (min_align_of_type): Removed prototype.
8185 * c-common.c (min_align_of_type): Removed.
8186 * c-ubsan.h (ubsan_maybe_instrument_reference,
8187 ubsan_maybe_instrument_member_call): New prototypes.
8188 * c-ubsan.c: Include stor-layout.h and builtins.h.
8189 (ubsan_maybe_instrument_reference_or_call,
8190 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
8191 functions.
8192
b4dfdc11
MG
81932014-07-31 Marc Glisse <marc.glisse@inria.fr>
8194
8195 PR c++/60517
8196 * c.opt (-Wreturn-local-addr): Move to common.opt.
8197
a41844e5
JM
81982014-07-30 Jason Merrill <jason@redhat.com>
8199
8200 PR c++/61659
8201 PR c++/61687
8202 Revert:
8203 * c.opt (-fuse-all-virtuals): New.
8204
976d5a22
TT
82052014-07-30 Tom Tromey <tromey@redhat.com>
8206
8207 PR c/59855
8208 * c.opt (Wdesignated-init): New option.
8209 * c-common.c (c_common_attribute_table): Add "designated_init".
8210 (handle_designated_init): New function.
8211
cdc94aca
MP
82122014-07-24 Marek Polacek <polacek@redhat.com>
8213
8214 PR c/57653
8215 * c-opts.c (c_finish_options): If -imacros is in effect, return.
8216
f41373b6
DS
82172014-07-16 Dodji Seketeli <dodji@redhat.com>
8218
8219 PR preprocessor/60723 - missing system-ness marks for macro tokens
8220 * c-ppoutput.c (struct print::prev_was_system_token): New data
8221 member.
8222 (init_pp_output): Initialize it.
8223 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
8224 (do_line_change): Return a flag saying if a line marker was
8225 emitted or not.
8226 (scan_translation_unit): Detect if the system-ness of the token we
8227 are about to emit is different from the one of the previously
8228 emitted token. If so, emit a line marker. Avoid emitting useless
8229 adjacent line markers. Avoid emitting line markers for tokens
8230 originating from the expansion of built-in macros.
8231 (scan_translation_unit_directives_only): Adjust.
8232
4d661eaa
MP
82332014-07-15 Marek Polacek <polacek@redhat.com>
8234
8235 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
8236 TYPE_MAX_VALUE is NULL.
8237
b108f48f
JJ
82382014-07-14 Jakub Jelinek <jakub@redhat.com>
8239
8240 PR middle-end/61294
8241 * c.opt (Wmemset-transposed-args): New warning.
8242
c0221884
JM
82432014-07-10 Jason Merrill <jason@redhat.com>
8244
8245 PR c++/61659
8246 PR c++/61687
8247 * c.opt (-fuse-all-virtuals): New.
8248
63dfbb95
RB
82492014-07-09 Richard Biener <rguenther@suse.de>
8250
8251 PR c-family/61741
8252 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
8253 using unsigned arithmetic if overflow does not wrap instead of
8254 if overflow is undefined.
8255
773ec47f
MP
82562014-07-06 Marek Polacek <polacek@redhat.com>
8257
8258 PR c/6940
8259 * c.opt (Wsizeof-array-argument): New option.
8260
00a7ba58
JJ
82612014-07-03 Jakub Jelinek <jakub@redhat.com>
8262
b1726d6c 8263 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
00a7ba58
JJ
8264 comments->count <= 1, as comments->entries might be NULL.
8265
52ec0ea3
MP
82662014-07-01 Marek Polacek <polacek@redhat.com>
8267
8268 * c.opt (Wint-conversion): New option.
8269
d5c3d343
MP
82702014-07-01 Marek Polacek <polacek@redhat.com>
8271
8272 PR c/58286
8273 * c.opt (Wincompatible-pointer-types): New option.
8274
6e7ceb17
PC
82752014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
8276
8277 PR c++/51400
8278 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
8279 Do not discard TYPE_QUALS of type.
8280
da73100b
JM
82812014-06-26 Jason Merrill <jason@redhat.com>
8282
8283 * c-common.h (enum cxx_dialect): Add cxx1z.
8284 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
8285 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
8286
08eedf75
TJ
82872014-06-26 Teresa Johnson <tejohnson@google.com>
8288
8289 * c-common.h (get_dump_info): Declare.
8290 * c-gimplify.c (c_genericize): Use saved dump files.
8291 * c-opts.c (c_common_parse_file): Begin and end dumps
8292 once around parsing invocation.
8293 (get_dump_info): New function.
8294
7b56b2f8
MP
82952014-06-23 Marek Polacek <polacek@redhat.com>
8296 Andrew MacLeod <amacleod@redhat.com>
8297
8298 PR c/61553
8299 * c-common.c (get_atomic_generic_size): Don't segfault if the
8300 type doesn't have a size.
8301
0e37a2f3
MP
83022014-06-20 Marek Polacek <polacek@redhat.com>
8303
8304 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
8305 (ubsan_walk_array_refs_r): New function.
8306 (c_genericize): Instrument array bounds.
8307 * c-ubsan.c: Include "internal-fn.h".
8308 (ubsan_instrument_division): Mark instrumented arrays as having
8309 side effects. Adjust ubsan_type_descriptor call.
8310 (ubsan_instrument_shift): Likewise.
8311 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
8312 (ubsan_instrument_bounds): New function.
8313 (ubsan_array_ref_instrumented_p): New function.
8314 (ubsan_maybe_instrument_array_ref): New function.
8315 * c-ubsan.h (ubsan_instrument_bounds): Declare.
8316 (ubsan_array_ref_instrumented_p): Declare.
8317 (ubsan_maybe_instrument_array_ref): Declare.
8318
83192014-06-20 Hale Wang <hale.wang@arm.com>
dd6fe7d4
HW
8320
8321 PR lto/61123
8322 * c.opt (fshort-enums): Add to LTO.
8323 * c.opt (fshort-wchar): Likewise.
8324
5c3d09f7
MP
83252014-06-16 Marek Polacek <polacek@redhat.com>
8326
8327 PR c/60439
8328 * c.opt (Wswitch-bool): Add Var.
8329
9cf32741
JJ
83302014-06-12 Jakub Jelinek <jakub@redhat.com>
8331
8332 PR middle-end/61486
8333 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
8334 #pragma omp target teams or
8335 #pragma omp {,target }teams distribute simd.
8336
62984918
JM
83372014-06-12 Jason Merrill <jason@redhat.com>
8338
8339 * c.opt (Wabi=, fabi-compat-version): New.
8340 * c-opts.c (c_common_handle_option): Handle -Wabi=.
8341 (c_common_post_options): Handle flag_abi_compat_version default.
8342 Disallow -fabi-compat-version=1.
8343 * c-common.h (abi_version_crosses): New.
8344
f961457f
JH
83452014-06-11 Jan Hubicka <hubicka@ucw.cz>
8346
adfac8df 8347 * c-common.c (handle_section_attribute): Update handling for
f961457f
JH
8348 section names that are no longer trees.
8349
92d28cbb
JJ
83502014-06-10 Jakub Jelinek <jakub@redhat.com>
8351
8352 PR fortran/60928
8353 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
8354 (omp_pragmas): ... back here.
8355
742938c9
MP
83562014-06-05 Marek Polacek <polacek@redhat.com>
8357
8358 PR c/49706
8359 * c-common.c (warn_logical_not_parentheses): New function.
8360 * c-common.h (warn_logical_not_parentheses): Declare.
8361 * c.opt (Wlogical-not-parentheses): New option.
8362
9d548dfb
MP
83632014-06-04 Marek Polacek <polacek@redhat.com>
8364
8365 PR c/30020
8366 * c-common.c (check_case_bounds): Add location parameter.
8367 Use it.
8368 (c_add_case_label): Pass loc to check_case_bounds.
8369
fedfecef
MP
83702014-06-03 Marek Polacek <polacek@redhat.com>
8371
8372 PR c/60439
8373 * c.opt (Wswitch-bool): New option.
8374
f6a7cffc
TS
83752014-05-22 Thomas Schwinge <thomas@codesourcery.com>
8376
040d18b6
TS
8377 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
8378 Remove prototypes.
8379 (record_types_used_by_current_var_decl): Move prototype to where
8380 it belongs.
8381
f6a7cffc
TS
8382 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
8383 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
8384 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
8385
632f2871
RS
83862014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
8387
8388 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
8389 * c-common.c (c_common_nodes_and_builtins): Don't initialize
8390 void_zero_node.
8391 * c-pretty-print.c (pp_c_void_constant): New function.
8392 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
8393 (c_pretty_printer::expression): Handle VOID_CST.
8394 * cilk.c (extract_free_variables): Likewise.
8395 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
8396 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
8397
766090c2
TS
83982014-05-17 Trevor Saunders <tsaunders@mozilla.com>
8399
8400 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
8401 * c-pragma.c (push_alignment): Adjust.
8402 (handle_pragma_push_options): Likewise.
8403
661a0813
MP
84042014-05-09 Marek Polacek <polacek@redhat.com>
8405
8406 PR c/50459
8407 * c-common.c (check_user_alignment): Return -1 if alignment is error
8408 node.
8409 (handle_aligned_attribute): Don't call default_conversion on
8410 FUNCTION_DECLs.
8411 (handle_vector_size_attribute): Likewise.
8412 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
8413 (handle_sentinel_attribute): Call default_conversion and allow even
8414 integral types as an argument.
8415
2793eeab
MP
84162014-05-08 Marek Polacek <polacek@redhat.com>
8417
8418 PR c/61053
8419 * c-common.c (min_align_of_type): New function factored out from...
8420 (c_sizeof_or_alignof_type): ...here.
8421 * c-common.h (min_align_of_type): Declare.
8422
f827930a
MP
84232014-05-08 Marek Polacek <polacek@redhat.com>
8424
8425 PR c/61077
8426 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
8427 parameter type of main.
8428
ca49b74e
DD
84292014-05-07 DJ Delorie <dj@redhat.com>
8430
8431 * c-cppbuiltin.c (print_bits_of_hex): New.
8432 (builtin_define_type_minmax): Print values using hex so as not to
8433 require a pre-computed list of string values.
8434
1d60af08
KZ
84352014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
8436 Mike Stump <mikestump@comcast.net>
8437 Richard Sandiford <rdsandiford@googlemail.com>
8438
8439 * c-ada-spec.c: Include wide-int.h.
8440 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
8441 (dump_generic_ada_node): Use wide-int interfaces.
8442 * c-common.c: Include wide-int-print.h.
8443 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
8444 (pointer_int_sum): Use wide-int interfaces.
8445 (c_common_nodes_and_builtins): Use make_int_cst.
8446 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
8447 (handle_alloc_size_attribute): Use wide-int interfaces.
8448 (get_nonnull_operand): Likewise.
8449 * c-format.c (get_constant): Use tree_fits_uhwi_p.
8450 * c-lex.c: Include wide-int.h.
8451 (narrowest_unsigned_type): Take a widest_int rather than two
8452 HOST_WIDE_INTs.
8453 (narrowest_signed_type): Likewise.
8454 (interpret_integer): Update accordingly. Use wide-int interfaces.
8455 (lex_charconst): Use wide-int interfaces.
8456 * c-pretty-print.c: Include wide-int.h.
8457 (pp_c_integer_constant): Use wide-int interfaces.
8458 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
8459 INT_CST_LT_UNSIGNED.
8460
b15458be
RB
84612014-05-06 Richard Biener <rguenther@suse.de>
8462
8463 * c-opts.c (c_common_post_options): For -freestanding,
8464 -fno-hosted and -fno-builtin disable pattern recognition
8465 if not enabled explicitely.
8466
6577374e
MP
84672014-05-02 Marek Polacek <polacek@redhat.com>
8468
8469 * c.opt (Wsizeof-pointer-memaccess): Describe option.
8470
d00887e8
MP
84712014-05-01 Marek Polacek <polacek@redhat.com>
8472
8473 PR c/43245
8474 * c.opt (Wdiscarded-qualifiers): Add.
8475
f8ed5150
MP
84762014-04-30 Marek Polacek <polacek@redhat.com>
8477
8478 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
8479 INT_MIN / -1 sanitization only for integer types.
8480
45484dcf
MP
84812014-04-25 Marek Polacek <polacek@redhat.com>
8482
8483 PR c/18079
8484 * c-common.c (handle_noinline_attribute): Warn if the attribute
8485 conflicts with always_inline attribute.
8486 (handle_always_inline_attribute): Warn if the attribute conflicts
8487 with noinline attribute.
8488
38e514c0
MP
84892014-04-25 Marek Polacek <polacek@redhat.com>
8490
8491 PR c/60156
8492 * c-common.c (check_main_parameter_types): Warn about variadic main.
8493
44875f92
MS
84942014-04-24 Mike Stump <mikestump@comcast.net>
8495
8496 * c.opt (Wshadow-ivar): Default to on.
8497
dcaaa5a0
DP
84982014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
8499
8500 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
8501
c07d7c02
MP
85022014-04-23 Marek Polacek <polacek@redhat.com>
8503
8504 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
8505
1c33c9b7
JJ
85062014-04-22 Jakub Jelinek <jakub@redhat.com>
8507
8508 PR sanitizer/60275
8509 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
8510 if flag_sanitize_undefined_trap_on_error.
8511 (ubsan_instrument_division, ubsan_instrument_shift,
8512 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
8513 if !flag_sanitize_recover.
8514
793c625f
MG
85152014-04-22 Marc Glisse <marc.glisse@inria.fr>
8516
8517 PR libstdc++/43622
8518 * c-common.c (registered_builtin_types): Make non-static.
8519 * c-common.h (registered_builtin_types): Declare.
8520
b0f1bf36 85212014-04-14 Richard Biener <rguenther@suse.de>
ab20d992 8522 Marc Glisse <marc.glisse@inria.fr>
b0f1bf36
RB
8523
8524 PR c/60819
8525 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
8526 apply may-alias the scalar pointer type when applicable.
8527
3b07fa4a
IZ
85282014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
8529
8530 PR middle-end/60467
8531 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
8532 as possible argument for Cilk_spawn.
8533
cbbd2b1c
TB
85342014-04-11 Tobias Burnus <burnus@net-b.de>
8535
8536 PR c/60194
8537 * c.opt (Wformat-signedness): Add
8538 * c-format.c(check_format_types): Use it.
8539
6415bd5d
JM
85402014-04-11 Jason Merrill <jason@redhat.com>
8541
8542 PR c++/57926
8543 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
8544 default_conversion for an array argument.
8545
6525783a
MP
85462014-04-08 Marek Polacek <polacek@redhat.com>
8547
8548 PR sanitizer/60745
8549 * c-ubsan.c: Include asan.h.
8550 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
8551
880a467b
NS
85522014-04-03 Nathan Sidwell <nathan@codesourcery.com>
8553
8554 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
8555
7b59ff2d
MP
85562014-04-02 Marek Polacek <polacek@redhat.com>
8557
8558 * c-common.h (c_expand_expr): Remove declaration.
8559
8edbfaa6
JJ
85602014-03-28 Jakub Jelinek <jakub@redhat.com>
8561
8562 PR c++/60689
8563 * c-common.c (add_atomic_size_parameter): When creating new
8564 params vector, push the size argument first.
8565
07d72e1d
JJ
85662014-03-26 Jakub Jelinek <jakub@redhat.com>
8567
8568 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
8569 ubsan_instrument_vla, ubsan_instrument_return): Adjust
8570 ubsan_create_data callers.
8571
b35e0fa0
JJ
85722014-03-22 Jakub Jelinek <jakub@redhat.com>
8573
8574 PR debug/60603
8575 * c-opts.c (c_finish_options): Restore cb_file_change call to
8576 <built-in>.
8577
39a1ebb3
JJ
85782014-03-13 Jakub Jelinek <jakub@redhat.com>
8579
8580 PR middle-end/36282
8581 * c-pragma.c (apply_pragma_weak): Only look at
8582 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
8583 DECL_ASSEMBLER_NAME_SET_P (decl).
8584 (maybe_apply_pending_pragma_weaks): Exit early if
8585 vec_safe_is_empty (pending_weaks) rather than only when
8586 !pending_weaks.
8587 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
8588 set assembler name back to NULL afterwards.
8589
a07f6ed2
JM
85902014-03-11 Jason Merrill <jason@redhat.com>
8591
8592 * c.opt: Add -std=gnu++14.
8593
75b107f5
IB
85942014-03-11 Ian Bolton <ian.bolton@arm.com>
8595
8596 * c-opts.c (c_common_post_options): Don't override
8597 -ffp-contract=fast if unsafe-math-optimizations is on.
8598
f42c637e
PM
85992014-03-08 Paulo Matos <paulo@matos-sorge.com>
8600
22b15758 8601 * c.opt: Enable LTO FE for fshort-double.
f42c637e 8602
70e24808
JM
86032014-03-07 Jason Merrill <jason@redhat.com>
8604
8605 * c.opt: Add -std=c++14.
8606
3af9c5e9
MP
86072014-03-06 Marek Polacek <polacek@redhat.com>
8608
8609 PR c/60197
8610 * cilk.c (contains_cilk_spawn_stmt): New function.
8611 (contains_cilk_spawn_stmt_walker): Likewise.
8612 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
8613 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
8614
b3bdf019
JJ
86152014-03-03 Jakub Jelinek <jakub@redhat.com>
8616
8617 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
8618 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
8619 even when flag_preprocess_only.
8620
ca7e759d
JM
86212014-02-26 Jason Merrill <jason@redhat.com>
8622
8623 PR c++/59231
8624 PR c++/11586
8625 * c-common.c (shorten_compare): Don't check
8626 c_inhibit_evaluation_warnings.
8627
28e41874
JJ
86282014-02-19 Jakub Jelinek <jakub@redhat.com>
8629
cca615af
JJ
8630 PR c/37743
8631 * c-common.c (c_common_nodes_and_builtins): When initializing
8632 c_uint{16,32,64}_type_node, also set corresponding
8633 uint{16,32,64}_type_node to the same value.
8634
28e41874
JJ
8635 PR c++/60267
8636 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
8637 for PRAGMA_IVDEP if flag_preprocess_only.
8638
c2bf53a1
JJ
86392014-02-12 Jakub Jelinek <jakub@redhat.com>
8640
8641 PR c/60101
8642 * c-common.c (merge_tlist): If copy is true, call new_tlist,
8643 if false, add ADD itself, rather than vice versa.
8644 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
8645 copy. For SAVE_EXPR, only call merge_tlist once.
8646
8fcbce72
JJ
86472014-02-08 Jakub Jelinek <jakub@redhat.com>
8648
8649 PR middle-end/60092
8650 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
8651 and tree_to_uhwi.
8652 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
8653 functions.
8654 (c_common_attribute_table): Add alloc_align and assume_aligned
8655 attributes.
8656
0a756a3f
MP
86572014-02-06 Marek Polacek <polacek@redhat.com>
8658
8659 PR c/60087
8660 * c-common.c (warn_for_sign_compare): Call warning_at with location
8661 instead of warning.
8662
7ec4847a
MP
86632014-02-05 Marek Polacek <polacek@redhat.com>
8664
8665 PR c/53123
8666 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
8667 statement.
8668
66f20604
MP
86692014-02-04 Marek Polacek <polacek@redhat.com>
8670
8671 PR c/60036
8672 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
8673 SAVE_EXPR.
8674
5d77fb19
MG
86752014-02-03 Marc Glisse <marc.glisse@inria.fr>
8676
8677 PR c++/53017
8678 PR c++/59211
8679 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
8680 handle_vector_size_attribute, handle_nonnull_attribute): Call
8681 default_conversion on the attribute argument.
8682 (handle_nonnull_attribute): Increment the argument number.
8683
81e5eca8
MP
86842014-01-31 Marek Polacek <polacek@redhat.com>
8685
8686 PR c/59963
8687 * c-common.c (add_atomic_size_parameter): Pass vNULL to
8688 build_function_call_vec.
8689 (resolve_overloaded_builtin): Likewise.
8690 * c-common.h (build_function_call_vec): Adjust declaration.
8691
68fca595
MP
86922014-01-30 Marek Polacek <polacek@redhat.com>
8693
8694 PR c/59940
8695 * c-common.h (unsafe_conversion_p): Adjust declaration.
8696 (warnings_for_convert_and_check): Likewise.
8697 (convert_and_check): Likewise.
8698 * c-common.c (unsafe_conversion_p): Add location parameter. Call
8699 expansion_point_location_if_in_system_header on it.
8700 (warnings_for_convert_and_check): Add location parameter. Call
8701 expansion_point_location_if_in_system_header on it. Use it.
8702 (convert_and_check): Add location parameter. Use it.
8703 (conversion_warning): Likewise.
8704 (c_add_case_label): Adjust convert_and_check calls.
8705 (scalar_to_vector): Adjust unsafe_conversion_p calls.
8706
b72271b9
BI
87072014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
8708
8709 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
8710 flag_cilkplus.
8711 * c-pragma.c (init_pragma): Likewise.
8712 * c.opt: Likewise.
8713
393e8e8b
MP
87142014-01-23 Marek Polacek <polacek@redhat.com>
8715
8716 PR c/59846
8717 * c-common.c (shorten_compare): Add location_t parameter.
8718 * c-common.h (shorten_binary_op): Adjust declaration.
8719
f04dda30
MP
87202014-01-23 Marek Polacek <polacek@redhat.com>
8721
8722 PR c/58346
8723 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
8724 * c-common.h: Declare it.
8725
621955cb
EB
87262014-01-20 Eric Botcazou <ebotcazou@adacore.com>
8727
8728 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
8729 * c-ada-spec.c (dump_ads): Likewise.
8730 (cpp_check): Likewise.
8731 (dump_ada_specs): Likewise.
8732
87332014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
67bf2939
LA
8734
8735 PR c++/49718
8736 * c-common.c (handle_no_instrument_function_attribute): Allow
8737 no_instrument_function attribute in class member
8738 definition/declaration.
8739
241f845a
JJ
87402014-01-15 Jakub Jelinek <jakub@redhat.com>
8741
8742 PR c/58943
8743 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
8744 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
8745 being COMPOUND_EXPR.
8746 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
8747 operand a SAVE_EXPR and second MODIFY_EXPR.
8748
e83b8e2e
JJ
87492014-01-09 Jakub Jelinek <jakub@redhat.com>
8750
8751 PR target/58115
8752 * c-pch.c (c_common_write_pch): Call
8753 prepare_target_option_nodes_for_pch.
8754
23a5b65a
RS
87552014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
8756
8757 Update copyright years
8758
f9030485
RS
87592014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
8760
8761 * array-notation-common.c, c-cilkplus.c: Use the standard form for
8762 the copyright notice.
8763
f2aa696b
EB
87642013-12-28 Eric Botcazou <ebotcazou@adacore.com>
8765
8766 * c-ada-spec.c (print_constructor): New function.
8767 (print_destructor): Retrieve the origin of the destructor.
8768 (print_ada_declaration): Revamp handling of constructors/destructors.
8769
3f8257db 87702013-12-23 Stuart Hastings <stuart@apple.com>
1f26ac87
JM
8771 Bill Maddox <maddox@google.com>
8772 Jason Merrill <jason@redhat.com>
8773
8774 * c.opt: Add -fdeclone-ctor-dtor.
8775 * c-opts.c (c_common_post_options): Default to on iff -Os.
8776
41958c28
BI
87772013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
8778
8779 * c-common.c (c_common_attribute_table): Added "cilk simd function"
8780 attribute.
8781 * c-pragma.h (enum pragma_cilk_clause): Remove.
ab20d992 8782 (enum pragma_omp_clause): Added the following fields:
41958c28
BI
8783 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
8784 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
8785 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
8786 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
8787 PRAGMA_CILK_CLAUSE_UNIFORM.
8788
b1726d6c 8789
12893402
BI
87902013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
8791
8792 * cilk.c (cilk_outline): Made this function non-static.
8793 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
8794 (create_cilk_wrapper): Added a new parameter: a function pointer.
8795 (c_install_body_w_frame_cleanup): Remove
8796 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
8797 * c-common.h (cilk_outline): New prototype.
8798 (gimplify_cilk_spawn): Removed two parameters.
8799 (cilk_install_body_with_frame_cleanup): New prototype.
8800 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
8801 CILK_SPAWN_STMT case.
8802
085b42ed
BS
88032013-12-11 Bernd Schmidt <bernds@codesourcery.com>
8804
2ce064c3
BS
8805 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
8806
085b42ed
BS
8807 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
8808 (int_array_type_node): Remove.
8809 * c-common.c (c_common_nodes_and_builtins): Don't build it.
8810
9e36c9ed
MP
88112013-12-05 Marek Polacek <polacek@redhat.com>
8812
8813 PR c/52023
8814 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
8815 [ADJUST_FIELD_ALIGN].
8816
296674db
JM
88172013-12-04 Joseph Myers <joseph@codesourcery.com>
8818
8819 PR c/52023
8820 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
8821 and check field alignment if set.
8822 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
8823 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
8824
b1726d6c 88252013-12-04 Jakub Jelinek <jakub@redhat.com>
31e071ae
MP
8826 Marek Polacek <polacek@redhat.com>
8827
8828 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
8829 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
8830
d7947e19
L
88312013-11-29 H.J. Lu <hongjiu.lu@intel.com>
8832
8833 PR c/59309
8834 * cilk.c (gimplify_cilk_spawn): Properly handle function without
8835 arguments.
8836
fad7652e
JJ
88372013-11-29 Jakub Jelinek <jakub@redhat.com>
8838
8839 PR c/59280
8840 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
8841 goto invalid. If it is error_mark_node, don't issue further
8842 diagnostics.
8843
8b5e1202
SO
88442013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
8845
8846 * c.opt (Wopenmp-simd): New.
8847
0a508bb6
JJ
88482013-11-22 Jakub Jelinek <jakub@redhat.com>
8849
8850 * c-ubsan.h (ubsan_instrument_return): New prototype.
8851 * c-ubsan.c (ubsan_instrument_return): New function.
8852
2fb9a547
AM
88532013-11-22 Andrew MacLeod <amacleod@redhat.com>
8854
8855 * c-common.c: Add required include files from gimple.h.
ab20d992
JJ
8856 * c-gimplify.c: Likewise.
8857 * cilk.c: Likewise.
2fb9a547 8858
8400e75e
DM
88592013-11-22 David Malcolm <dmalcolm@redhat.com>
8860
8861 * c-common.c (unsafe_conversion_p): Remove use of
8862 EXPR_LOC_OR_HERE macro.
8863 (conversion_warning): Likewise.
8864 (warnings_for_convert_and_check): Likewise.
8865 (warn_for_collisions_1): Likewise.
8866 (shorten_compare): Likewise, and remove use of in_system_header
8867 macro, using the location from the former.
8868 * c-lex.c (dump_one_header): Remove use of input_filename macro.
8869 (cb_def_pragma): Remove use of in_system_header macro.
8870 (lex_string): Likewise.
8871 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
8872
eb1ce453
KZ
88732013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
8874 Mike Stump <mikestump@comcast.net>
8875 Richard Sandiford <rdsandiford@googlemail.com>
8876
8877 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
8878 instead of TREE_INT_CST_LOW, in cases where there is a protecting
8879 tree_fits_shwi_p or tree_fits_uhwi_p.
8880 (dump_generic_ada_node): Likewise.
8881 * c-format.c (check_format_arg): Likewise.
8882 * c-pretty-print.c (pp_c_integer_constant): Likewise.
8883
6b3b8c27
KZ
88842013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
8885
8886 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
8887
49b0aa18
JC
88882013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
8889
8890 PR c/53001
8891 * c-common.c (unsafe_conversion_p): Make this function
8892 return an enumeration with more detail.
8893 (conversion_warning): Use the new return type of
8894 unsafe_conversion_p to separately warn either about conversions
8895 that lower floating point number precision or about the other
8896 kinds of conversions.
8897 * c-common.h (enum conversion_safety): New enumeration.
8e745a17
JJ
8898 (unsafe_conversion_p): switching return type to
8899 conversion_safety enumeration.
49b0aa18
JC
8900 * c.opt: Adding new warning -Wfloat-conversion and
8901 enabling it with -Wconversion.
8902
b826515a
BS
89032013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
8904
8e745a17
JJ
8905 * c-opts.c: Include plugin.h.
8906 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
b826515a 8907
b9a55b13
MP
89082013-11-19 Marek Polacek <polacek@redhat.com>
8909
8910 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
8911 call.
8912 (ubsan_instrument_shift): Likewise.
8913 (ubsan_instrument_vla): Likewise.
8914
7d362f6c
RS
89152013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8916
8917 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
8918 cast to unsigned type.
8919
386b1f1f
RS
89202013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8921
8922 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
8923 tree_low_cst.
8924 (complete_array_type): Update comment to refer to tree_to_[su]hwi
8925 rather than tree_low_cst.
8926
ae7e9ddd
RS
89272013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8928
8929 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
8930 tree_to_uhwi throughout.
8931
9439e9a1
RS
89322013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8933
8934 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
8935 tree_low_cst (..., 0) with tree_to_shwi throughout.
8936
cc269bb6
RS
89372013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8938
8939 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
8940 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
8941
9541ffee
RS
89422013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8943
8944 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
8945 host_integerp (..., 0) with tree_fits_shwi_p throughout.
8946
c02065fc
AH
89472013-11-15 Aldy Hernandez <aldyh@redhat.com>
8948
8949 * c-cilkplus.c: New file.
8950 * c-common.c (readonly_error): Add location argument.
8951 * c-common.h (readonly_error): Same.
8952 (c_finish_cilk_clauses): Protoize.
8953 (c_check_cilk_loop): Same.
8954 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
8955 Do not fail on error_mark_node.
8956 Abstract increment canonicalization to here...
8957 (c_omp_for_incr_canonicalize_ptr): New.
8958 c-pragma.c (init_pragma): Register "simd" pragma.
8959 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
8960 (enum pragma_cilk_clause): New.
8961
9cc65f15
RS
89622013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
8963
8964 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
8965 wchar_type and host_integerp checks.
8966
18f429e2
AM
89672013-11-14 Andrew MacLeod <amacleod@redhat.com>
8968
8969 * c-common.c: Likewise.
8970 * c-gimplify.c: Likewise.
8971 * cilk.c: Likewise.
8972
d8a2d370
DN
89732013-11-14 Diego Novillo <dnovillo@google.com>
8974
8975 * c-common.c: Include fold-const.h.
8976 Include stor-layout.h.
8977 Include calls.h.
8978 Include stringpool.h.
8979 Include attribs.h.
8980 Include varasm.h.
8981 Include trans-mem.h.
8982 * c-cppbuiltin.c: Include stor-layout.h.
8983 Include stringpool.h.
8984 * c-format.c: Include stringpool.h.
8985 * c-lex.c: Include stringpool.h.
8986 Include stor-layout.h.
8987 * c-pragma.c: Include stringpool.h.
8988 Include attribs.h.
8989 Include varasm.h.
8990 Include gcc-symtab.h.
8991 * c-pretty-print.c: Include stor-layout.h.
8992 Include attribs.h.
8993 * cilk.c: Include stringpool.h.
8994 Include calls.h.
8995
38b7bc7f
JM
89962013-11-13 Joseph Myers <joseph@codesourcery.com>
8997
8998 * c-common.h (enum rid): Add RID_AUTO_TYPE.
8999 * c-common.c (c_common_reswords): Add __auto_type.
9000 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
9001
45b0be94
AM
90022013-11-12 Andrew MacLeod <amacleod@redhat.com>
9003
18f429e2
AM
9004 * c-common.c: Include gimplify.h.
9005 * c-gimplify.c: Likewise.
9006 * cilk.c: Likewise.
9007 * c-omp.c: Include gimple-expr.h instead of gimple.h.
9008 * c-ubsan.c: Don't include gimple.h.
45b0be94 9009
582d9b50
JM
90102013-11-12 Joseph Myers <joseph@codesourcery.com>
9011
9012 * c-common.c (c_common_reswords): Add _Thread_local.
9013
6b28e197
JM
90142013-11-09 Joseph Myers <joseph@codesourcery.com>
9015
9016 * c-common.c (atomic_size_supported_p): New function.
9017 (resolve_overloaded_atomic_exchange)
9018 (resolve_overloaded_atomic_compare_exchange)
9019 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
9020 Use it instead of comparing size with a local list of sizes.
9021
267bac10
JM
90222013-11-07 Andrew MacLeod <amacleod@redhat.com>
9023 Joseph Myers <joseph@codesourcery.com>
9024
9025 * c-common.h (enum rid): Add RID_ATOMIC.
9026 * c-common.c (c_common_reswords): Add _Atomic.
9027 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
9028 (keyword_is_type_qualifier): Accept RID_ATOMIC.
9029 * c-format.c (check_format_types): Check for extra _Atomic
9030 qualifiers in format argument.
9031 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
9032 (pp_c_type_qualifier_list): Mention _Atomic in comment.
9033
5157b91e
TB
90342013-11-06 Tobias Burnus <burnus@net-b.de>
9035
9036 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
9037
6dbe0958
JM
90382013-11-06 Joseph Myers <joseph@codesourcery.com>
9039
9040 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
9041 standards modes.
9042 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
9043 to mean lack of IEEE 754 support.
9044
e8ff5196
TB
90452013-11-05 Tobias Burnus <burnus@net-b.de>
9046
9047 * c.opt (-Wdate-time): New option
9048 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
9049
254a0760
JM
90502013-11-05 Joseph Myers <joseph@codesourcery.com>
9051
9052 * c-cppbuiltin.c (cpp_iec_559_value): Test
9053 flag_excess_precision_cmdline not flag_excess_precision.
9054
6d7f7e0a
TB
90552013-11-05 Tobias Burnus <burnus@net-b.de>
9056
9057 * c.opt (fopenmp-simd): New option.
9058 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
9059 (omp_pragmas): ... this new struct.
9060 (c_pp_lookup_pragma): Also walk omp_pragmas.
9061 (init_pragma): Init pragmas for -fopenmp-simd.
9062
55a7f02f
MP
90632013-11-04 Marek Polacek <polacek@redhat.com>
9064
9065 PR c++/58979
9066 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
9067
9193fb05
JM
90682013-11-04 Joseph Myers <joseph@codesourcery.com>
9069
9070 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
9071 New functions.
9072 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
9073
94159ecf
EB
90742013-11-04 Eric Botcazou <ebotcazou@adacore.com>
9075
9076 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
9077 (dump_ada_specs): Adjust prototype of second callback.
9078 * c-ada-spec.c (cpp_check): New global variable.
9079 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
9080 (print_generic_ada_decl): Likewise.
9081 (has_static_fields): Change return type to bool and add guard.
9082 (has_nontrivial_methods): New predicate.
9083 (is_tagged_type): Change return type to bool.
9084 (separate_class_package): Call has_nontrivial_methods.
9085 (pp_ada_tree_identifier): Minor tweaks.
9086 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
9087 (dump_ada_array_domains): Likewise.
9088 (dump_ada_array_type): Likewise.
9089 (dump_template_types): Remove cpp_check parameter and do not pass it to
9090 dump_generic_ada_node.
9091 (dump_ada_template): Likewise.
9092 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
9093 recursively.
9094 (print_ada_methods): Change return type to integer. Remove cpp_check
9095 parameter and do not pass it down.
9096 (dump_nested_types): Remove cpp_check parameter and do not pass it to
9097 dump_generic_ada_node.
9098 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
9099 accessing methods.
9100 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
9101 down. Use has_nontrivial_methods to recognize C++ classes. Use return
9102 value of print_ada_methods.
9103 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
9104 Set cpp_check to it before invoking dump_ada_nodes.
9105 (dump_ada_specs): Likewise.
9106
b906f4ca
MP
91072013-11-03 Marek Polacek <polacek@redhat.com>
9108
9109 * c-ubsan.c: Don't include hash-table.h.
9110 (ubsan_instrument_vla): New function.
9111 * c-ubsan.h: Declare it.
9112
5e20cdc9
DM
91132013-10-31 David Malcolm <dmalcolm@redhat.com>
9114
9115 Automated part of renaming of symtab_node_base to symtab_node.
9116
9117 Patch autogenerated by rename_symtab.py from
9118 https://github.com/davidmalcolm/gcc-refactoring-scripts
9119 revision 58bb219cc090b2f4516a9297d868c245495ee622
9120
9121 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
9122 symtab_node_base to symtab_node.
9123
7057e645
ESR
91242013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
9125
8e745a17 9126 Implement C++14 digit separators.
7057e645
ESR
9127 * c-lex.c (interpret_float): Remove digit separators from scratch string
9128 before building real literal.
9129
193ea7bc
JJ
91302013-10-30 Jakub Jelinek <jakub@redhat.com>
9131
9132 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
9133
939b37da
BI
91342013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
9135
9136 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
9137 fields.
9138 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
9139 enabled.
9140 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
9141 (insert_cilk_frame): New prototype.
9142 (cilk_init_builtins): Likewise.
9143 (gimplify_cilk_spawn): Likewise.
9144 (c_cilk_install_body_w_frame_cleanup): Likewise.
9145 (cilk_detect_spawn_and_unwrap): Likewise.
9146 (cilk_set_spawn_marker): Likewise.
9147 (build_cilk_sync): Likewise.
9148 (build_cilk_spawn): Likewise.
9149 * cilk.c: New file.
9150
67348ccc
DM
91512013-10-29 David Malcolm <dmalcolm@redhat.com>
9152
9153 Patch autogenerated by refactor_symtab.py from
9154 https://github.com/davidmalcolm/gcc-refactoring-scripts
9155 revision 58bb219cc090b2f4516a9297d868c245495ee622
9156
9157 * c-gimplify.c (c_genericize): Update for conversion of symtab types
9158 to a true class hierarchy.
9159 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
9160
d570872d
RS
91612013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
9162
9163 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
9164
98906124
JL
91652013-10-26 Jeff Law <law@redhat.com>
9166
adfac8df
JJ
9167 * c-common.c (c_define_builtins): Remove mudflap support.
9168 * c.opt: Ignore and warn for mudflap options.
98906124 9169
d73749df 91702013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
9171
9172 PR other/33426
9173 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
9174 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
9175
3f04b1bb
JM
91762013-10-23 Jason Merrill <jason@redhat.com>
9177
9178 * c-format.c (gcc_cxxdiag_char_table): Add %X.
9179
acf0174b
JJ
91802013-10-11 Jakub Jelinek <jakub@redhat.com>
9181
acd15a28
JJ
9182 * c-common.h (omp_clause_mask::operator !=): New method.
9183 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
9184 instead of if (mask & something) tests everywhere.
9185
acf0174b
JJ
9186 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
9187 201307 instead of 201107.
9188 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
9189 (c_common_attribute_table): Add "omp declare target" and
9190 "omp declare simd" attributes.
9191 (handle_omp_declare_target_attribute,
9192 handle_omp_declare_simd_attribute): New functions.
9193 * c-omp.c: Include c-pragma.h.
9194 (c_finish_omp_taskgroup): New function.
9195 (c_finish_omp_atomic): Add swapped argument, if true,
9196 build the operation first with rhs, lhs arguments and use NOP_EXPR
9197 build_modify_expr.
9198 (c_finish_omp_for): Add code argument, pass it down to make_code.
9199 (c_omp_split_clauses): New function.
9200 (c_split_parallel_clauses): Removed.
9201 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
9202 c_omp_declare_simd_clauses_to_decls): New functions.
9203 * c-common.h (omp_clause_mask): New type.
9204 (OMP_CLAUSE_MASK_1): Define.
9205 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
9206 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
9207 omp_clause_mask::operator |, omp_clause_mask::operator &,
9208 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
9209 omp_clause_mask::operator ==): New methods.
9210 (enum c_omp_clause_split): New.
9211 (c_finish_omp_taskgroup): New prototype.
9212 (c_finish_omp_atomic): Add swapped argument.
9213 (c_finish_omp_for): Add code argument.
9214 (c_omp_split_clauses): New prototype.
9215 (c_split_parallel_clauses): Removed.
9216 (c_omp_declare_simd_clauses_to_numbers,
9217 c_omp_declare_simd_clauses_to_decls): New prototypes.
9218 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
9219 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
9220 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
9221 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
9222 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
9223 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
9224 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
9225 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
9226 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
9227 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
9228 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
9229 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
9230 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
9231 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
9232 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
9233 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
9234 PRAGMA_OMP_CLAUSE_UNIFORM.
9235
826cacfe
MG
92362013-10-09 Marc Glisse <marc.glisse@inria.fr>
9237
9238 PR tree-optimization/20318
9239 * c-common.c (handle_returns_nonnull_attribute): New function.
9240 (c_common_attribute_table): Add returns_nonnull.
9241
2284b034
MG
92422013-10-03 Marc Glisse <marc.glisse@inria.fr>
9243
9244 PR c++/19476
9245 * c.opt (fcheck-new): Move to common.opt.
9246
b56e9788
MP
92472013-09-25 Marek Polacek <polacek@redhat.com>
9248 Jakub Jelinek <jakub@redhat.com>
9249
9250 PR sanitizer/58413
9251 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
9252 an expression if we can prove it is correct.
9253 (ubsan_instrument_division): Likewise. Remove unnecessary
9254 check.
9255
ce6923c5
MP
92562013-09-18 Marek Polacek <polacek@redhat.com>
9257
9258 PR sanitizer/58411
9259 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
9260 Declare it.
9261 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
9262
fb5610fb
IS
92632013-09-14 Iain Sandoe <iain@codesourcery.com>
9264
9265 PR target/48094
9266 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
9267 fobjc-gc, freplace-objc-classes): Accept for LTO.
9268
88b0e79e
JC
92692013-09-13 Jacek Caban <jacek@codeweavers.com>
9270
9271 * c-target.def: New hook
9272
c9b0866a
PC
92732013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
9274
9275 PR c++/43452
9276 * c.opt (Wdelete-incomplete): Add.
9277
0af94e6f
JR
92782013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
9279
9280 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
9281 (vector_types_compatible_elements_p): New function.
9282 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
9283 declaration.
9284 (vector_types_compatible_elements_p): Declare.
9285
7c26172c
GDR
92862013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
9287
9288 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
9289 a virtual member function.
9290 (pp_simple_type_specifier): Remove.
9291 (pp_c_type_specifier): Likewise.
9292 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
9293 Rename from pp_c_type_specifier. Adjust.
9294 (c_pretty_printer::c_pretty_printer): Do not assign to
9295 simple_type_specifier.
9296
20059c8b
GDR
92972013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
9298
9299 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
9300 member function.
9301 (c_pretty_printer::storage_class_specifier): Likewise.
9302 (c_pretty_printer::initializer): Likewise.
9303 (pp_declaration): Remove.
9304 (pp_declaration_specifiers): Likewise.
9305 (pp_abstract_declarator): Likewise.
9306 (pp_declarator): Likewise.
9307 (pp_type_id): Likewise.
9308 (pp_statement): Likewise.
9309 (pp_constant): Likewise.
9310 (pp_id_expression): Likewise.
9311 (pp_primary_expression): Likewise.
9312 (pp_unary_expression): Likewise.
9313 (pp_multiplicative_expression): Likewise.
9314 (pp_conditional_expression): Likewise.
9315 (pp_assignment_expression): Likewise.
9316 (pp_expression): Likewise.
9317 (pp_c_type_id): Likewise.
9318 (pp_c_storage_class_specifier): Likewise.
9319 * c-pretty-print.c (pp_c_type_cast): Tidy.
9320 (pp_c_pointer): Likewise.
9321 (pp_c_type_specifier): Likewise.
9322 (pp_c_parameter_type_list): Likewise.
9323 (pp_c_function_definition): Likewise.
9324 (pp_c_init_declarator): Likewise.
9325 (pp_c_initializer_list): Likewise.
9326 (pp_c_constructor_elts): Likewise.
9327 (c_pretty_printer::direct_abstract_declarator): Likewise.
9328 (c_pretty_printer::declaration_specifiers): Likewise.
9329 (c_pretty_printer::primary_expression): Likewise.
9330 (c_pretty_printer::postfix_expression): Likewise.
9331 (c_pretty_printer::type_id): Rename from pp_c_type_id.
9332 (c_pretty_printer::storage_class_specifier): Rename from
9333 pp_c_storage_class_specifier.
9334 (c_pretty_printer::initializer): Rename from pp_c_initializer.
9335 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
9336 storage_class_specifier, initializer, offset_list, flags.
9337
de5a5fa1
MP
93382013-08-30 Marek Polacek <polacek@redhat.com>
9339
9340 * c-ubsan.c: New file.
9341 * c-ubsan.h: New file.
9342
8f0e4d72
GDR
93432013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
9344
9345 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
9346 member function.
9347 (c_pretty_printer::declaration_specifiers): Likewise.
9348 (c_pretty_printer::declarator): Likewise.
9349 (c_pretty_printer::abstract_declarator): Likewise.
9350 (c_pretty_printer::direct_abstract_declarator): Likewise.
9351 (c_pretty_printer::direct_declarator): Likewise.
9352 (c_pretty_printer::function_specifier): Likewise.
9353 (pp_declaration): Adjust.
9354 (pp_declaration_specifiers): Likewise.
9355 (pp_abstract_declarator): Likewise.
9356 (pp_direct_declarator): Likewise.
9357 (pp_function_specifier): Likewise.
9358 (pp_direct_abstract_declarator): Remove as unused.
9359 (pp_c_declaration): Remove.
9360 (pp_c_declaration_specifiers): Likewise.
9361 (pp_c_declarator): Likewise.
9362 (pp_c_direct_declarator): Likewise.
9363 (pp_c_function_specifier): Likewise.
9364 (pp_c_direct_abstract_declarator): Likewise.
9365 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
9366 from pp_c_abstract_declarator. Adjust.
ab20d992 9367 (c_pretty_printer::direct_abstract_declarator): Rename from
8f0e4d72
GDR
9368 pp_c_direct_abstract_declarator. Adjust.
9369 (c_pretty_printer::function_specifier): Rename from
9370 pp_c_function_specifier. Adjust.
9371 (c_pretty_printer::declaration_specifiers): Rename from
9372 pp_c_declaration_specifiers. Adjust.
9373 (c_pretty_printer::direct_declarator): Rename from
9374 pp_c_direct_declarator. Adjust.
9375 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
9376 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
9377 (c_pretty_printer::c_pretty_printer): Do not assign to
9378 declaration, declaration_specifiers, declarator,
9379 direct_declarator, direct_abstract_declarator, function_specifier.
9380
00d34d3a
GDR
93812013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
9382
9383 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
9384 virtual member function.
9385 (c_pretty_printer::multiplicative_expression): Likewise.
9386 (c_pretty_printer::conditional_expression): Likewise.
9387 (c_pretty_printer::assignment_expression): Likewise.
9388 (c_pretty_printer::expression): Likewise.
9389 (pp_unary_expression): Adjust.
9390 (pp_multiplicative_expression): Likewise.
9391 (pp_assignment_expression): Likewise.
9392 (pp_conditional_expression): Likewise.
9393 (pp_expression): Likewise.
9394 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
9395 from pp_c_unary_expression. Adjust.
9396 (c_pretty_printer::multiplicative_expression): Rename from
9397 pp_c_multiplicative_expression. Adjust.
9398 (c_pretty_printer::conditional_expression): Rename from
9399 pp_c_conditional_expression. Adjust.
9400 (c_pretty_printer::assignment_expression): Rename from
9401 pp_c_assignment_expression. Adjust.
9402 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
9403 (c_pretty_printer::c_pretty_printer): Do not assign to
9404 unary_expression, multiplicative_expression,
9405 conditional_expression, expression.
9406
fb22178f
GDR
94072013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
9408
9409 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
9410 virtual member function.
9411 (pp_postfix_expression): Adjust.
9412 (pp_c_postfix_expression): Remove.
9413 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
9414 from pp_c_postfix_expression. Adjust.
9415 (c_pretty_printer::c_pretty_printer): Do not assign to
9416 postfix_expression.
9417
7ecc2600
GDR
94182013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
9419
9420 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
9421 virtua member function.
9422 (pp_primary_expression): Adjust.
9423 (pp_c_primary_expression): Remove.
9424 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
9425 from pp_c_primary_expression. Adjust.
9426 (pp_c_initializer_list): Use pp_primary_expression.
9427 (c_pretty_printer::c_pretty_printer): Do not assign to
9428 primary_expression.
9429
0691175f
GDR
94302013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
9431
9432 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
9433 * c-pretty-print.c (M_): Remove.
9434 (c_pretty_printer::translate_string): Define.
9435 (pp_c_type_specifier): Use it.
9436 (pp_c_primary_expression): Likewise.
9437 (pp_c_expression): Likewise.
9438
66dfe4c4
GDR
94392013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
9440
9441 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
9442 virtual function.
9443 (pp_c_id_expression): Remove.
9444 (pp_id_expression): Adjust.
9445 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
9446 pp_c_id_expression. Adjust.
9447 (pp_c_postfix_expression): Use pp_id_expression.
9448 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
9449
ca43e9d5
GDR
94502013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
9451
9452 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
9453 member function.
9454 (pp_constant): Adjust.
9455 (pp_c_constant): Remove.
9456 * c-pretty-print.c (c_pretty_printer::constant): Rename from
9457 pp_c_constant. Adjust.
9458 (pp_c_constant)
9459 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
9460 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
9461
da6ca2b5
GDR
94622013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
9463
9464 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
9465 (c_pretty_printer::c_pretty_printer): Declare.
9466 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
9467 c_pretty_printer_init. Adjust.
9468 (print_c_tree): Do not call c_pretty_printer_init.
9469 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
9470
65a372f4
AC
94712013-08-09 Arnaud Charlet <charlet@adacore.com>
9472
9473 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
9474
fd9b0f32
PC
94752013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
9476
9477 PR c++/58080
9478 * c-common.c (pointer_int_sum): Add bool parameter.
9479 * c-common.h (pointer_int_sum): Adjust declaration.
9480
e0aec1e9
GDR
94812013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
9482
9483 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
9484 c_pretty_printer variable.
9485
b066401f
GDR
94862013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
9487
9488 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
9489 (pp_base): Remove.
9490 (pp_c_base): Likewise. Adjust users.
9491 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
9492 (pp_c_whitespace): Do not call pp_base.
9493 (pp_c_left_paren): Likewise.
9494 (pp_c_right_paren): Likewise.
9495 (pp_c_left_brace): Likewise.
9496 (pp_c_right_brace): Likewise.
9497 (pp_c_left_bracket): Likewise.
9498 (pp_c_right_bracket): Likewise.
9499 (pp_c_dot): Likewise.
9500 (pp_c_ampersand): Likewise.
9501 (pp_c_star): Likewise.
9502 (pp_c_arrow): Likewise.
9503 (pp_c_semicolon): Likewise.
9504 (pp_c_complement): Likewise.
9505 (pp_c_exclamation): Likewise.
9506 (pp_c_direct_declarator): Likewise.
9507 (pp_c_ws_string): Likewise.
9508 (pp_c_identifier): Likewise.
9509 (pp_c_statement): Likewise.
9510 (print_c_tree): Likewise.
9511
65e5a578
ESR
95122013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
9513
9514 PR c++/58072
9515 * c-common.c (c_parse_error): Catch user-defined literal tokens and
9516 provide useful error strings.
9517
137a1a27
GDR
95182013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
9519
9520 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
9521 printer functions instead of pp_string or operators and punctuators.
9522 (dump_generic_ada_node): Likewise.
9523 * c-pretty-print.c (pp_c_type_specifier): Likewise.
9524 (pp_c_relational_expression): Likewise.
9525 (pp_c_logical_or_expression): Likewise.
9526
07838b13
GDR
95272013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
9528
9529 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
9530 functions instead of pp_character.
9531 (pp_ada_tree_identifier): Likewise.
9532 (dump_ada_double_name): Likewise.
9533 (dump_ada_function_declaration): Likewise.
9534 (dump_ada_array_domains): Likewise.
9535 (dump_template_types): Likewise.
9536 (dump_generic_ada_node): Likewise.
9537 (print_ada_declaration): Likewise.
9538 (print_ada_struct_decl): Likewise.
9539 * c-pretty-print.c (pp_c_integer_constant): Likewise.
9540
433cc7b0
TT
95412013-07-23 Tom Tromey <tromey@redhat.com>
9542
9543 * c-common.h (enum rid) <RID_GENERIC>: New constant.
9544 * c-common.c (c_common_reswords): Add _Generic.
9545
688010ba
OB
95462013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
9547
9548 * c-common.c: Fix typos.
9549 * c-common.h: Likewise.
9550
2a99e5e6
LL
95512013-07-13 Lubos Lunak <l.lunak@suse.cz>
9552
9553 PR c++/55203
9554 * c-common.c (c_common_attribute_table): Add warn_unused.
9555 (handle_warn_unused_attribute): New.
9556
c26302d5
JJ
95572013-07-10 Jakub Jelinek <jakub@redhat.com>
9558
9559 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
9560 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
9561
dfeadaa0
PC
95622013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
9563
9564 PR c++/57869
9565 * c.opt: Add Wconditionally-supported.
9566
6a2fa4b2
GS
95672013-07-08 Graham Stott <graham.stott@btinternet.com>
9568
adfac8df 9569 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6a2fa4b2
GS
9570 unused variables l_length and l_node.
9571
ecdbd01a 95722013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
9573
9574 PR c/57821
9575 * c-common.c (complete_array_type): Delay folding first index
9576 like other indices. When folding, check for index overflow.
9577
bedc293e
MG
95782013-06-27 Marc Glisse <marc.glisse@inria.fr>
9579
9580 PR c++/57509
9581 * c-common.h (c_build_vec_perm_expr): New complain argument.
9582 * c-common.c (c_build_vec_perm_expr): Likewise.
9583 Use save_expr also in C++.
9584
604b2bfc
GDR
95852013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
9586
9587 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
9588 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
9589 * c-opts.c (c_common_post_options): Likewise.
9590
dfeadaa0 95912013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
713b46fa
BI
9592
9593 * array-notation-common.c (length_mismatch_in_expr): Changed the
9594 parameter type's from a dynamic array to a vec_tree. Also removed
9595 the size parameters.
9596 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
9597 the change above.
9598
2ce86d2e
BI
95992013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
9600
9601 * c-common.h (struct cilkplus_an_parts): New structure.
9602 (struct cilkplus_an_loop_parts): Likewise.
9603 (cilkplus_extract_an_triplets): New prototype.
9604 (fix_sec_implicit_args): Likewise.
9605 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
9606 (fix_sec_implicit_args): Likewise.
604b2bfc 9607
07a6825b
BI
96082013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
9609
9610 * array-notation-common.c (find_inv_trees): Removed an unwanted
9611 typecasting.
9612 * c-common.h (struct inv_list::additional_tcodes): Changed type from
9613 enum rid to enum tree_code.
9614
08346abd
JH
96152013-06-11 Jan Hubicka <jh@suse.cz>
9616
9617 * c-common.c (handle_alias_ifunc_attribute): Do not set
9618 DECL_EXTERNAL for weakref variables.
9619 * c-pragma.c (handle_pragma_weak): Make sure aliases
9620 are not declared as external.
9621
d60f1706
BI
96222013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
9623
9624 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
9625 function from c/c-array-notation.c.
9626 (is_cilkplus_reduce_builtin): Likewise.
9627 (find_rank): Likewise.
9628 (extract_array_notation_exprs): Likewise.
9629 (replace_array_notations): Likewise.
9630 (find_inv_trees): Likewise.
9631 (replace_inv_trees): Likewise.
9632 (contains_array_notation_expr): Likewise.
9633 (find_correct_array_notation_type): Likewise.
9634 * c-common.h (struct inv_list): Moved this struct from the file
9635 c/c-array-notation.c and added a new field called additional tcodes.
9636 (length_mismatch_in_expr_p): New prototype.
9637 (is_cilkplus_reduce_builtin): Likewise.
9638 (find_rank): Likewise.
9639 (extract_array_notation_exprs): Likewise.
9640 (replace_array_notation): Likewise.
9641 (find_inv_trees): Likewise.
9642 (replace_inv_trees): Likewise.
9643 (find_correct_array_notation_type): Likewise.
dfeadaa0 9644
36536d79
BI
96452013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
9646
9647 * c-common.c (c_define_builtins): When cilkplus is enabled, the
9648 function array_notation_init_builtins is called.
9649 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
9650 * c-common.def (ARRAY_NOTATION_REF): New tree.
9651 * c-common.h (build_array_notation_expr): New function declaration.
9652 (build_array_notation_ref): Likewise.
9653 (extract_sec_implicit_index_arg): New extern declaration.
9654 (is_sec_implicit_index_fn): Likewise.
9655 (ARRAY_NOTATION_CHECK): New define.
9656 (ARRAY_NOTATION_ARRAY): Likewise.
9657 (ARRAY_NOTATION_START): Likewise.
9658 (ARRAY_NOTATION_LENGTH): Likewise.
9659 (ARRAY_NOTATION_STRIDE): Likewise.
9660 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
9661 ARRAY_NOTATION_REF.
9662 (pp_c_expression): Likewise.
9663 * c.opt (flag_enable_cilkplus): New flag.
9664 * array-notation-common.c: New file.
9665
f7716d57
JJ
96662013-05-14 Jakub Jelinek <jakub@redhat.com>
9667
9668 PR c++/57274
9669 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
9670
a5e0cd1d
MG
96712013-05-10 Marc Glisse <marc.glisse@inria.fr>
9672
9673 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
9674 vectors.
9675
f6bc1c4a
HS
96762013-05-07 Han Shen <shenhan@google.com>
9677
9678 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
9679
3f12f6e9
SKS
96802013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
9681
9682 * c-common.c (check_user_alignment): Emit error for negative values.
9683
61949153
PC
96842013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
9685
9686 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
9687
e93e18e9
PC
96882013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
9689
9690 * c-cppbuiltin.c (c_cpp_builtins): Do not define
9691 __GXX_EXPERIMENTAL_CXX1Y__.
9692
44d90fe1 96932013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
8e745a17 9694 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
44d90fe1
PC
9695
9696 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
9697 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
9698 to simply use OPT_Wpointer_arith.
9699 (c_sizeof_or_alignof_type): Likewise.
9700
13f39b2e
PC
97012013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
9702
9703 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
9704
4b84d650
JJ
97052013-04-12 Jakub Jelinek <jakub@redhat.com>
9706
9707 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
9708 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
9709 specifiers.
9710
fb037b5d
SB
97112013-04-07 Steven Bosscher <steven@gcc.gnu.org>
9712
9713 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
9714
4e856798
PC
97152013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
9716
9717 * c-common.c (pointer_int_sum): Remove dead code.
9718
4b1baac8
RS
97192013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
9720
9721 PR middle-end/56524
9722 * c-common.c (handle_optimize_attribute): Don't call
9723 save_optabs_if_changed.
9724
0b50e654
JJ
97252013-03-05 Jakub Jelinek <jakub@redhat.com>
9726
9727 PR middle-end/56461
9728 * c-pch.c (pch_init): Free target_validity at the end.
9729
48c41403
JJ
97302013-03-04 Jakub Jelinek <jakub@redhat.com>
9731
9732 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
9733
e664c61c
KS
97342013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
9735 Jakub Jelinek <jakub@redhat.com>
9736
9737 PR sanitizer/56454
9738 * c-common.c (handle_no_sanitize_address_attribute): New function.
9739 (c_common_attribute_table): Add no_sanitize_address attribute.
9740 (handle_no_address_safety_analysis_attribute): Add
9741 no_sanitize_address attribute, not no_address_safety_analysis
9742 attribute.
9743
a475fd3d 97442013-02-18 Aldy Hernandez <aldyh@redhat.com>
135204dd
AH
9745
9746 PR target/52555
9747 * c-common.c (handle_optimize_attribute): Call
9748 save_optabs_if_changed.
9749
f6007d99
JJ
97502013-02-18 Jakub Jelinek <jakub@redhat.com>
9751 Steven Bosscher <steven@gcc.gnu.org>
9752
9753 PR pch/54117
9754 * c-opts.c (c_common_post_options): If debug info is enabled
9755 and non-dwarf*, refuse to load PCH files and when writing PCH
9756 file warn.
9757
cf35e2b1
JJ
97582013-02-05 Jakub Jelinek <jakub@redhat.com>
9759
9760 PR middle-end/56167
9761 * c-common.c (handle_error_attribute): Fix condition.
9762
32887460
JJ
97632013-01-30 Jakub Jelinek <jakub@redhat.com>
9764
9765 PR c++/55742
9766 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
9767
5af057d8
JM
97682013-01-18 Jason Merrill <jason@redhat.com>
9769
9770 PR target/54908
9771 * c.opt (-fextern-tls-init): New.
9772 * c-opts.c (c_common_post_options): Handle it.
9773
cc83c823
JJ
97742013-01-09 Jakub Jelinek <jakub@redhat.com>
9775
9776 PR c/48418
9777 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
9778 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
9779 and is either negative or bigger or equal to type precision
9780 of the first operand.
9781
a859517f
MP
97822012-12-03 Marek Polacek <polacek@redhat.com>
9783
9784 PR c/55570
9785 * c-common.c (check_user_alignment): Swap order of tests,
9786 check TREE_CODE first.
9787
2d7aa578
ESR
97882012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
9789
9790 PR c++/52654
9791 * c-common.h (overflow_type): New enum.
9792 (build_userdef_literal): Add overflow_type argument.
9793 (tree_userdef_literal): Add overflow_type.
9794 (USERDEF_LITERAL_OVERFLOW): New access macro.
9795 * c-common.c (build_userdef_literal): Add overflow_type
9796 argument.
9797 * c-lex.c (c_lex_with_flags): Add overflow_type to
9798 build_userdef_literal calls.
9799 (interpret_integer, interpret_float): Add overflow_type argument.
9800
cc3c4f62
RB
98012012-11-28 Richard Biener <rguenther@suse.de>
9802
9803 PR c/35634
9804 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
9805 here and use a type with proper overflow behavior for types that would
9806 need to be promoted for the arithmetic.
9807
77bc5132
JJ
98082012-11-23 Jakub Jelinek <jakub@redhat.com>
9809
9810 PR sanitizer/55435
9811 * c-common.c (handle_no_address_safety_analysis_attribute): New
9812 function.
9813 (c_common_attribute_table): Add no_address_safety_analysis.
9814
5dc99c46
SB
98152012-11-16 Simon Baldwin <simonb@google.com>
9816
9817 * c.opt: Add f[no-]canonical-system-headers.
9818 * c-opts.c (c_common_handle_option): Handle
9819 OPT_fcanonical_system_headers.
9820
a4a0016d
ESR
98212012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
9822
9823 PR c++/54413
9824 * c-opts.c (c_common_handle_option): Set new flags.
9825 * c.opt: Describe new flags.
9826
7dbb85a7
JM
98272012-11-09 Jason Merrill <jason@redhat.com>
9828
9829 * c.opt (Wabi-tag): New.
9830
ad7bac31
AK
98312012-11-09 Andi Kleen <ak@linux.intel.com>
9832
9833 PR 55139
9834 * c-common.c (get_atomic_generic_size): Mask with
8e745a17 9835 MEMMODEL_MASK
ad7bac31 9836
7332899a
MLI
98372012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
9838
9839 PR c/53063
9840 * c.opt (Wformat): Make it Alias Wformat=1.
9841 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
9842 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
9843 LangEnabledBy.
9844 (Wformat=): RejectNegative. Use LangEnabledBy.
9845 (Wnonnull): Use LangEnabledBy.
9846 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
9847 * c-format.c (set_Wformat): Delete.
9848 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
ab20d992
JJ
9849 (maybe_read_dollar_number): Likewise.
9850 (avoid_dollar_number): Likewise.
9851 (finish_dollar_format_checking): Likewise.
9852 (check_format_info): Likewise.
9853 (check_format_info_main): Likewise.
9854 (check_format_types): Likewise.
9855 (format_type_warning): Likewise.
9856 * c-common.c (int): Likewise.
9857 (check_function_sentinel): Likewise.
8e745a17 9858 * c-common.h (warn_format,set_Wformat): Do not declare here.
7332899a 9859
34a180a6
MLI
98602012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
9861
9862 PR c/53063
9863 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
9864 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
9865 Use LangEnabledBy.
9866 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
9867 common.opt.
9868 (Wvariadic-macros): Init(1).
9869 * c-opts.c (c_common_handle_option): Do not handle them
9870 explicitly.
9871 (c_common_post_options): Likewise.
9872 (sanitize_cpp_opts): warn_unused_macros is now
9873 cpp_warn_unused_macros.
9874 (push_command_line_include): Likewise.
9875 * c-common.c (warn_unknown_pragmas): Do not define.
9876 * c-common.h (warn_unknown_pragmas): Do not declare.
9877
3f46d6a5
MLI
98782012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
9879
9880 PR c/51294
9881 * c-common.c (conversion_warning): Handle conditional expressions.
9882
880661a4
JW
98832012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
9884
9885 PR c++/54930
9886 * c.opt (Wreturn_local_addr): Define new option.
9887
4514a96b
JM
98882012-10-25 Jason Merrill <jason@redhat.com>
9889
f14edc1a
JM
9890 * c.opt (Wvirtual-move-assign): New.
9891
4514a96b
JM
9892 * c.opt (Winherited-variadic-ctor): New.
9893
93100c6b
MG
98942012-10-25 Marc Glisse <marc.glisse@inria.fr>
9895
9896 PR c++/54427
9897 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
9898
1efcb8c6
JM
98992012-10-23 Joseph Myers <joseph@codesourcery.com>
9900
9901 * c-common.h (pch_cpp_save_state): Declare.
9902 * c-target.def (c_preinclude): New hook.
9903 * c-opts.c (done_preinclude): New.
9904 (push_command_line_include): Handle default preincluded header.
9905 (cb_file_change): Call pch_cpp_save_state when calling
9906 push_command_line_include.
9907 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
9908 (pch_cpp_save_state): New.
9909 (pch_init): Call pch_cpp_save_state conditionally, instead of
9910 calling cpp_save_state.
9911
4a0ae68e
MLI
99122012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
9913
9914 PR c/53063
9915 PR c/40989
9916 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
9917 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
9918 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
9919 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
9920 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
9921 * c-opts.c (c_common_handle_option): Remove explicit handling from
9922 here.
9923 (c_common_post_options): Likewise.
9924
67e4210b
EB
99252012-10-18 Eric Botcazou <ebotcazou@adacore.com>
9926
9927 * c-ada-spec.c (LOCATION_COL): Delete.
9928 (compare_location): New function.
9929 (compare_node): Use it.
9930 (compare_comment): Likewise.
9931
65d4f2cd
MLI
99322012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
9933
9934 PR c/53063
9935 PR c/40989
9936 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
9937 * c-opts.c (c_common_handle_option): Do not set them here. Add
9938 comment.
9939 (c_common_post_options): Likewise.
9940
909881cb
EB
99412012-10-16 Eric Botcazou <ebotcazou@adacore.com>
9942
9943 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
9944 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
9945 Remove POINTER_TYPE handling, add large unsigned handling and use
9946 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
9947
3a785c97
JJ
99482012-10-12 Jakub Jelinek <jakub@redhat.com>
9949
9950 PR c/54381
9951 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
9952 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
9953 locs and array of 3 trees instead of just single loc and single
9954 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
9955 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
9956 For *cmp* builtins that take two sources strings report warnings
9957 about first and second source, not about destination and source.
9958
5e54f81d
MG
99592012-10-12 Marc Glisse <marc.glisse@inria.fr>
9960
9961 PR c++/53055
9962 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
9963
f5b02f1e
EB
99642012-10-11 Eric Botcazou <ebotcazou@adacore.com>
9965
9966 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
9967 declaring something coming from another file.
9968
b46dbc6c
AC
99692012-10-10 Arnaud Charlet <charlet@adacore.com>
9970
f5b02f1e 9971 PR ada/54845
b46dbc6c
AC
9972 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
9973
5d9de0d0
PC
99742012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
9975
9976 PR c++/54194
9977 * c-common.c (warn_about_parentheses): Add location_t parameter;
9978 use EXPR_LOC_OR_LOC.
9979 * c-common.h: Update declaration.
9980
a212e43f
MG
99812012-10-09 Marc Glisse <marc.glisse@inria.fr>
9982
9983 PR c++/54427
9984 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
9985 more operations. Make error messages optional.
9986 * c-common.h (enum stv_conv): Moved from c-typeck.c.
9987 (scalar_to_vector): Declare.
9988
b1db7f91
JM
99892012-10-08 Jason Merrill <jason@redhat.com>
9990
9991 * c-common.c (c_common_reswords): Add thread_local.
9992
e28d52cf
DS
99932012-10-08 Dodji Seketeli <dodji@redhat.com>
9994
9995 PR c++/53528 C++11 attribute support
9996 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
9997 new functions.
9998 * c-common.c (check_cxx_fundamental_alignment_constraints): New
9999 static function.
10000 (handle_aligned_attribute): In choose strictest alignment
10001 among many. Use new check_cxx_fundamental_alignment_constraints.
10002 (handle_transparent_union_attribute): In c++11 attribute syntax,
10003 don't look through typedefs.
10004
3b78de56
AC
100052012-10-04 Arnaud Charlet <charlet@adacore.com>
10006
10007 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
10008 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
10009 out of dumpfile.h.
10010
6040bb5f
DC
100112012-09-25 Dehao Chen <dehao@google.com>
10012
10013 PR middle-end/54645
3b78de56 10014 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
6040bb5f
DC
10015 map when read in the pch.
10016
3f8257db 100172012-09-18 Arnaud Charlet <charlet@adacore.com>
0b07a57e
AC
10018
10019 * c-ada-spec.c: Style fixes.
10020
3f8257db 100212012-09-18 Thomas Quinot <quinot@adacore.com>
da5182be
TQ
10022
10023 * c.opt (-fada-spec-parent): Define new command line switch.
10024 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
10025 is specified, generate binding spec as a child of the specified unit.
10026
0ccb505d
PC
100272012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
10028 Manuel López-Ibáñez <manu@gcc.gnu.org>
10029
10030 PR c++/53210
10031 * c.opt ([Winit-self]): Enabled by -Wall in C++.
10032
c583af79
AC
100332012-08-23 Arnaud Charlet <charlet@adacore.com>
10034
10035 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
10036 for pointers, and add missing Convention C pragma.
10037 (print_ada_struct_decl): Add missing aliased keyword.
10038 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
10039
1a4049e7
JJ
100402012-08-17 Jakub Jelinek <jakub@redhat.com>
10041
10042 * c-common.c (sizeof_pointer_memaccess_warning): New function.
10043 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
10044 * c-opts.c (c_common_handle_option): Enable it for -Wall.
10045 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
10046 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
10047
70b5e7dc
RG
100482012-08-10 Richard Guenther <rguenther@suse.de>
10049
10050 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
10051
f8923f7e
SB
100522012-08-07 Steven Bosscher <steven@gcc.gnu.org>
10053
10054 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
10055 instead of separate pp_newline and pp_flush.
10056 (print_c_tree): Likewise.
10057
e45abe1f
RH
100582012-07-26 Richard Henderson <rth@redhat.com>
10059
10060 * c-common.c (handle_hot_attribute): Allow labels.
10061 (handle_cold_attribute): Likewise.
10062
332f1d24
JJ
100632012-07-20 Jakub Jelinek <jakub@redhat.com>
10064
10065 PR c++/28656
10066 * c-common.c (check_function_nonnull): Handle multiple nonnull
10067 attributes properly.
10068
7ee2468b
SB
100692012-07-16 Steven Bosscher <steven@gcc.gnu.org>
10070
10071 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
10072 * c-ada-spec.c: Likewise.
10073 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
10074
ee7b28eb
SB
100752012-07-14 Steven Bosscher <steven@gcc.gnu.org>
10076
10077 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
10078 Remove code conditional on it.
10079
6bdf3519
SB
100802012-07-11 Steven Bosscher <steven@gcc.gnu.org>
10081
10082 * c-gimplify.c: Do not include basic-block.h.
10083 * c-common.c: Do not include linfuncs.h.
10084
532aafad
SB
100852012-07-08 Steven Bosscher <steven@gcc.gnu.org>
10086
10087 * c-common.h: Include tree.h.
10088
8d0d1915
JM
100892012-07-02 Jason Merrill <jason@redhat.com>
10090
10091 PR c++/53524
10092 * c-common.c (get_priority): Call default_conversion.
10093
fbc873ad
UB
100942012-07-01 Uros Bizjak <ubizjak@gmail.com>
10095
10096 * c-pch.c (c_common_write_pch): Remove unused variables.
10097
d4a10d0a
SB
100982012-06-29 Steven Bosscher <steven@gcc.gnu.org>
10099
10100 * cppspec.c: Moved from gcc/ to here.
10101
6f3a2e23
KT
101022012-06-27 Kai Tietz <ktietz@redhat.com>
10103
10104 PR preprocessor/37215
10105 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
10106
8ca92d04
SB
101072012-06-21 Steven Bosscher <steven@gcc.gnu.org>
10108
10109 * c-common.h (c_common_print_pch_checksum): Remove.
10110 * c-pch.c: Do not include output.h.
10111 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
10112 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
10113 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
10114 (struct c_pch_header): Remove.
10115 (get_ident): Update gpch version.
10116 (pch_init): Do not print executable_checksum to asm_out_file.
10117 Do not fail if there is no asm_out_file to read back from. Set
10118 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
10119 (c_common_write_pch): Verify that nothing was written to asm_out_file
10120 since pch_init was called. Do not write a c_pch_header, and do not
10121 copy from asm_out_file to the PCH.
10122 (c_common_read_pch): Do not read a c_pch_header, and do not restore
10123 the content of asm_out_file from the PCH.
10124 (c_common_print_pch_checksum): Remove.
10125 * c-opts.c (c_common_init): Print out executable_checksum directly.
10126
70f42967
SB
101272012-06-19 Steven Bosscher <steven@gcc.gnu.org>
10128
10129 * c-target.def (objc_declare_unresolved_class_reference,
10130 objc_declare_class_definition): Add new hooks.
10131
a8781821
SB
101322012-06-19 Steven Bosscher <steven@gcc.gnu.org>
10133
10134 * c-lex.c: Do not include output.h.
10135 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
10136 Remove uses of ASM_OUTPUT_IDENT.
10137
9e1a8dd1
RR
101382012-06-15 Marc Glisse <marc.glisse@inria.fr>
10139
10140 PR c++/51033
10141 * c-common.h (c_build_vec_perm_expr): Move decl here.
10142 * c-common.c (c_build_vec_perm_expr): Move definition
10143 here.
10144
6f07a821
SB
101452012-06-06 Steven Bosscher <steven@gcc.gnu.org>
10146
10147 * c.opt (fconserve-space): Turn into a no-op.
10148
9faeb493 101492012-06-04 Sterling Augustine <saugustine@google.com>
c265f413
SA
10150
10151 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
10152 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
10153 both the start and end of the function.
10154
a4b7d13c
SB
101552012-06-04 Steven Bosscher <steven@gcc.gnu.org>
10156
10157 * c-common.c: Do not include output.h.
10158 * c-pragma.c: Likewise.
10159
c265f413
SA
101602012-06-04 Steven Bosscher <steven@gcc.gnu.org>
10161
10162 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
10163 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
10164 (lang_decl_name): Handle namespace decls.
10165
be7a421e
SB
101662012-05-31 Steven Bosscher <steven@gcc.gnu.org>
10167
10168 * c-ada-spec.c: Do not include output.h.
10169 * c-semantics.c: Likewise.
10170
65de6659
JM
101712012-05-29 Joseph Myers <joseph@codesourcery.com>
10172
10173 * c-common.c: Fix typo.
10174
ca5f4331
MM
101752012-05-29 Michael Matz <matz@suse.de>
10176
10177 * c-common.h (c_expand_decl): Remove prototype.
10178
4f7f7aca
MLI
101792012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
10180
10181 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
10182 * c-opts.c (c_common_handle_option): Remove code handling
10183 warn_missing_braces.
10184
4a792f9b
PC
101852012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
10186
10187 PR c++/25137
10188 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
10189 -Wmissing_braces.
10190
650dc14a
DS
101912012-05-22 Dodji Seketeli <dodji@redhat.com>
10192
10193 PR c++/53322
10194 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
10195
9b095bf1
MLI
101962012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
10197
10198 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
10199 * c-opts.c (c_common_handle_option): Do not handle explicitly
10200 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
10201
0b2c4be5
DS
102022012-05-16 Dodji Seketeli <dodji@redhat.com>
10203
10204 PR preprocessor/7263
ab20d992 10205 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
0b2c4be5
DS
10206 to cpp_classify_number. For diagnostics, use the precise location
10207 instead of the global input_location.
10208
a1bde5af
PC
102092012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
10210
d02924ef 10211 PR c++/11856
a1bde5af
PC
10212 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
10213
d1ede5f4
BS
102142012-05-14 Bernd Schmidt <bernds@codesourcery.com>
10215
a1bde5af 10216 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
d1ede5f4 10217
f2bc201f
MLI
102182012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
10219
10220 PR 53063
10221 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
10222 Wreorder): Use LangEnabledBy.
10223 * c-opts.c (c_common_handle_option): Do not enable them
10224 explicitly. Call lang-specific generated functions.
10225 (c_common_post_options): Do not set them here.
10226
95744782
MLI
102272012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
10228
10229 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
10230 Wmissing-field-initializers,Wmissing-parameter-type,
10231 Wold-style-declaration,Woverride-init): Use EnabledBy.
10232 * c-opts.c (c_common_post_options): Do not set here explicitly.
10233
7d5a5747
MLI
102342012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
10235
10236 PR 53063
10237 * c-opts.c (c_common_handle_option): Use handle_generated_option
10238 to enable sub-options.
10239
5a3c9cf2
PC
102402012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
10241
10242 PR c++/53158
10243 * c-common.c (warnings_for_convert_and_check): Use warning_at.
10244
3ac8781c
RG
102452012-05-10 Richard Guenther <rguenther@suse.de>
10246
10247 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
10248 adjust commentary about TYPE_IS_SIZETYPE types.
10249
1e537948
MLI
102502012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
10251
10252 PR c++/53261
10253 * c-common.c (warn_logical_operator): Check that argument of
10254 integer_zerop is not NULL.
10255
f2c4a785
MLI
102562012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
10257
10258 PR c/43772
10259 * c-common.c (warn_logical_operator): Do not warn if either side
10260 is already true or false.
10261
50f305ca
MLI
102622012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
10263
10264 PR c/51712
10265 * c-common.c (expr_original_type): New.
10266 (shorten_compare): Do not warn for enumeration types.
10267
0c3641b0
MLI
102682012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
10269
10270 * c.opt (fpermissive): Add Var(flag_permissive).
10271
7edaa4d2
MG
102722012-04-30 Marc Glisse <marc.glisse@inria.fr>
10273
10274 PR c++/51033
10275 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
10276 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
10277
b9c8da34
DS
102782012-04-30 Dodji Seketeli <dodji@redhat.com>
10279
10280 Add -Wvarargs option
ab20d992 10281 * c.opt (Wvarargs): Define new option.
b9c8da34 10282
e6c69da0
MLI
102832012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
10284
10285 * c-common.c (check_function_arguments): Replace
10286 Wmissing-format-attribute with Wsuggest-attribute=format.
10287
90137d8f
MLI
102882012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
10289
10290 * c.opt (Wsuggest-attribute=format): New. Alias of
10291 Wmissing-format-attribute.
10292 * c-format.c (decode_format_type): Replace
10293 Wmissing-format-attribute with Wsuggest-attribute=format.
10294 (check_function_format): Likewise.
10295
9faeb493 102962012-04-27 Ollie Wild <aaw@google.com>
7f5f5f98
OW
10297
10298 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
10299 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
10300 * c.opt: Add Wliteral-suffix.
10301
c1771a20
MLI
103022012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
10303
10304 PR c/44774
10305 * c.opt (Wpedantic): New.
10306 (pedantic): Alias Wpedantic.
10307 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
10308 (c_common_post_options): Likewise.
10309 (sanitize_cpp_opts): Likewise.
10310 * c-lex.c (interpret_float): Likewise.
10311 * c-format.c (check_format_types): Likewise.
10312 * c-common.c (pointer_int_sum): Likewise.
10313 (c_sizeof_or_alignof_type): Likewise.
10314 (c_add_case_label): Likewise.
10315 (c_do_switch_warnings): Likewise.
10316 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
10317
04b391c1
JM
103182012-04-15 Jason Merrill <jason@redhat.com>
10319
10320 PR c++/52818
10321 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
10322 (C_STD_NAME): Distinguish between C++98 and C++11.
10323
ac868f29
EB
103242012-04-11 Eric Botcazou <ebotcazou@adacore.com>
10325
10326 PR target/52624
10327 * c-common.h (uint16_type_node): Rename into...
10328 (c_uint16_type_node): ...this.
10329 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
10330 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
10331
fd4116f4
MLI
103322012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
10333
10334 * c-common.c (warn_if_unused_value): Move definition to here.
10335 * c-common.h (warn_if_unused_value): Move declaration to here.
10336
573ac65e
WB
103372012-03-23 William Bader <williambader@hotmail.com>
10338
10339 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
10340
552b8185
JM
103412012-03-20 Jason Merrill <jason@redhat.com>
10342
10343 * c-common.h (enum cxx_dialect): Add cxx1y.
10344 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
10345 test.
10346 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
10347 * c-opts.c (c_common_post_options): Likewise.
10348 (set_std_cxx1y): New.
10349 (c_common_handle_option): Call it.
10350 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
10351
04398fa8
PC
103522012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
10353
10354 PR c++/14710
10355 * c.opt ([Wuseless-cast]): Add.
10356
d2a12ae7
RG
103572012-03-16 Richard Guenther <rguenther@suse.de>
10358
10359 * c-pretty-print.c (pp_c_initializer_list): Adjust.
10360
a12bf402
MLI
103612012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
10362
10363 PR c++/44783
10364 * c.opt (ftemplate-backtrace-limit) Add.
10365
5c30094f
RO
103662012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10367
10368 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
10369 handling.
10370 * c-pragma.c (handle_pragma_extern_prefix): Remove.
10371 (init_pragma): Don't register extern_prefix.
10372
21fa2faf
RG
103732012-03-12 Richard Guenther <rguenther@suse.de>
10374
10375 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
10376 (builtin_type_for_size): Likewise.
10377
e3793c6f
JJ
103782012-02-13 Jakub Jelinek <jakub@redhat.com>
10379
10380 PR c++/52215
10381 * c-common.c (sync_resolve_params): Don't decide whether to convert
10382 or not based on TYPE_SIZE comparison, convert whenever arg_type
10383 is unsigned INTEGER_TYPE.
10384
93286335
PC
103852012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
10386
10387 PR c/52118
10388 * c.opt ([Wunused-local-typedefs]): Fix description.
10389
7a421706
MS
103902012-01-24 Mike Stump <mikestump@comcast.net>
10391
10392 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
10393 exactly.
10394
ba9b1f11
RG
103952012-01-18 Richard Guenther <rguenther@suse.de>
10396
10397 * c-opts.c (c_common_post_options): Reset LTO flags if
10398 we are about to generate a PCH.
10399
465406be
PC
104002012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
10401
10402 PR c++/51777
10403 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
10404 use pp_unsigned_wide_integer.
10405
aee15221
RG
104062012-01-10 Richard Guenther <rguenther@suse.de>
10407
10408 PR middle-end/51806
10409 * c-opts.c (c_common_handle_option): Move -Werror handling
10410 to language independent code.
10411
5720c0dc
RG
104122012-01-05 Richard Guenther <rguenther@suse.de>
10413
10414 PR middle-end/51764
10415 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
10416 from common.opt.
10417
73ac190a
PC
104182011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
10419
10420 PR c++/51316
10421 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
10422 of array types with an unknown bound.
10423
48b0b196
JM
104242011-12-20 Joseph Myers <joseph@codesourcery.com>
10425
10426 * c-common.c (flag_isoc99): Update comment to refer to C11.
10427 (flag_isoc1x): Change to flag_isoc11.
10428 * c-common.h (flag_isoc99): Update comment to refer to C11.
10429 (flag_isoc1x): Change to flag_isoc11.
10430 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
10431 C11.
10432 * c-opts.c (set_std_c1x): Change to set_std_c11.
10433 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
10434 Call set_std_c11.
10435 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
10436 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
10437 * c.opt (std=c1x): Change to std=c11. Document as non-draft
10438 standard.
10439 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
10440 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
10441 (std=gnu1x): Make alias of std=gnu11.
10442
d58d6eb5
JM
104432011-12-19 Jason Merrill <jason@redhat.com>
10444
10445 PR c++/51228
10446 * c-common.c (handle_transparent_union_attribute): Check the first
10447 field if the type is complete.
10448
b3908fcc
JW
104492011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
10450
10451 PR libstdc++/51365
10452 * c-common.c (RID_IS_FINAL): Add.
10453 * c-common.h (RID_IS_FINAL): Add.
10454
fea3ca91
IS
104552011-11-30 Iain Sandoe <iains@gcc.gnu.org>
10456
10457 * c.opt (fgnu-runtime): Provide full description.
10458 (fnext-runtime): Likewise.
10459 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
10460
62bad7cd
AM
104612011-11-28 Andrew MacLeod <amacleod@redhat.com>
10462
10463 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
10464 predefines in one place. Add LOCK_FREE predefines.
10465 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
10466 new func.
10467
c466c4ff
AM
104682011-11-24 Andrew MacLeod <amacleod@redhat.com>
10469
10470 PR c/51256
9faeb493 10471 * c-common.c (get_atomic_generic_size): Check for various error
c466c4ff 10472 conditions
9faeb493
UB
10473 (resolve_overloaded_atomic_exchange,
10474 resolve_overloaded_atomic_compare_exchange,
c466c4ff
AM
10475 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
10476 error_mark_node for error conditions.
9faeb493 10477
a5952633
RG
104782011-11-08 Richard Guenther <rguenther@suse.de>
10479
10480 PR middle-end/51010
ab20d992 10481 * c-pretty-print.c (pp_c_expression): Handle SSA_NAMEs.
a5952633 10482
0a35513e
AH
104832011-11-07 Richard Henderson <rth@redhat.com>
10484 Aldy Hernandez <aldyh@redhat.com>
10485 Torvald Riegel <triegel@redhat.com>
10486
10487 Merged from transactional-memory.
10488
10489 * c-common.c (handle_tm_wrap_attribute,
10490 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
10491 (struct c_common_reswords): Added __transaction* keywords.
10492 (struct c_common_attribute_table): Added transaction* and tm_regparm
10493 attributes.
10494 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
10495 masks.
10496 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
10497 find_tm_attribute): Declare.
10498
6d87092d
JM
104992011-11-07 Jason Merrill <jason@redhat.com>
10500
10501 PR c++/35688
10502 * c-common.c, c-common.h: Revert yesterday's changes.
10503
8e7860a1
JM
105042011-11-06 Jason Merrill <jason@redhat.com>
10505
10506 PR c++/35688
10507 * c-common.c (decl_has_visibility_attr): Split out from...
10508 (c_determine_visibility): ...here.
10509 * c-common.h: Declare it.
10510
d19fa6b5
JM
105112011-11-06 Joseph Myers <joseph@codesourcery.com>
10512
10513 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
10514 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
10515 type.
10516 (check_user_alignment): New. Split out of
10517 handle_aligned_attribute. Disallow integer constants with
10518 noninteger types. Conditionally allow zero.
10519 (handle_aligned_attribute): Use check_user_alignment.
10520 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
10521
86951993
AM
105222011-11-06 Andrew MacLeod <amacleod@redhat.com>
10523 Richard Henderson <rth@redhat.com>
10524
10525 Merged from cxx-mem-model.
10526
10527 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
9faeb493 10528 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
86951993
AM
10529 parameters that are the same type size.
10530 (get_atomic_generic_size): New. Find size of generic
10531 atomic function parameters and do typechecking.
10532 (add_atomic_size_parameter): New. Insert size into parameter list.
10533 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
10534 either __atomic_exchange_n or external library call.
9faeb493 10535 (resolve_overloaded_atomic_compare_exchange): Restructure
86951993 10536 __atomic_compare_exchange to either _n variant or external library call.
9faeb493 10537 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
86951993
AM
10538 __atomic_load_n or an external library call.
10539 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
10540 __atomic_store_n or an external library call.
10541 (resolve_overloaded_builtin): Handle new __atomic builtins.
10542
cf9e9959
EB
105432011-11-04 Eric Botcazou <ebotcazou@adacore.com>
10544
10545 PR c++/50608
10546 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
10547 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
10548 <INDIRECT_REF>: Return the argument.
10549 <ARRAY_REF>: Remove special code for negative offset.
10550 Call fold_build_pointer_plus instead of size_binop.
10551 (fold_offsetof): Remove STOP_REF argument and adjust.
10552 * c-common.h (fold_offsetof_1): Declare.
10553 (fold_offsetof): Remove STOP_REF argument.
10554
25339f10
JM
105552011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
10556
10557 PR c++/50810
10558 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
10559 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
10560 Wnarrowing for C++0x and C++98.
10561 * c.opt ([Wnarrowing]): Update.
10562
89401152
PC
105632011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
10564
10565 PR c++/44277
10566 * c.opt: Add Wzero-as-null-pointer-constant.
10567
97e3ad20
JM
105682011-10-31 Jason Merrill <jason@redhat.com>
10569
15694fdd
JM
10570 * c.opt (-fdeduce-init-list): Off by default.
10571
97e3ad20
JM
10572 PR c++/50920
10573 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
10574 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
10575 and -Wc++11-compat.
10576 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
10577
fb9120e3
RAV
105782011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
10579
10580 PR c++/30066
10581 * c.opt (fvisibility-inlines-hidden): Description change.
10582
3ce4f9e4
ESR
105832011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
10584
10585 Implement C++11 user-defined literals.
10586 * c-common.c (build_userdef_literal): New.
10587 * c-common.def: New tree code.
10588 * c-common.h (tree_userdef_literal): New tree struct and accessors.
10589 * c-lex.c (interpret_float): Add suffix parm.
10590 (c_lex_with_flags): Build literal tokens.
10591
5f53c243
PC
105922011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
10593
10594 PR c++/50841
10595 Revert:
10596 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
10597
10598 PR c++/50810
10599 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
10600 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
10601 Wnarrowing for C++0x and C++98.
10602 * c.opt ([Wnarrowing]): Update.
10603
263734e1
PC
106042011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
10605
10606 PR c++/50810
10607 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
10608 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
10609 Wnarrowing for C++0x and C++98.
10610 * c.opt ([Wnarrowing]): Update.
10611
d2e312d7
PC
106122011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
10613
10614 PR c++/45385
10615 * c-common.c (conversion_warning): Remove code looking for
10616 artificial operands.
10617
d17687f6
DS
106182011-10-18 Dodji Seketeli <dodji@redhat.com>
10619
10620 PR bootstrap/50760
10621 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
9faeb493 10622 !NO_IMPLICIT_EXTERN_C.
d17687f6 10623
fc8396e9
PC
106242011-10-17 Michael Spertus <mike_spertus@symantec.com>
10625
10626 * c-common.c (c_common_reswords): Add __bases,
10627 __direct_bases.
10628 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
10629
106302011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
10631
10632 PR c++/50757
10633 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
10634
847e697a
TT
106352011-10-15 Tom Tromey <tromey@redhat.com>
10636 Dodji Seketeli <dodji@redhat.com>
10637
10638 * c.opt (fdebug-cpp): New option.
10639 * c-opts.c (c_common_handle_option): Handle the option.
10640 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
10641 output stream in parameter. Factorized from ...
10642 (maybe_print_line): ... this. Dump location debug information when
10643 -fdebug-cpp is in effect.
10644 (print_line_1): New static function. Takes an output stream in
10645 parameter. Factorized from ...
10646 (print_line): ... here. Dump location information when -fdebug-cpp
10647 is in effect.
10648 (scan_translation_unit): Dump location information when
10649 -fdebug-cpp is in effect.
10650
92582b75
TT
106512011-10-15 Tom Tromey <tromey@redhat.com>
10652 Dodji Seketeli <dodji@redhat.com>
10653
10654 * c.opt (ftrack-macro-expansion): New option. Handle it with and
10655 without argument.
10656 * c-opts.c (c_common_handle_option)<case
10657 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
10658 cases. Handle -ftrack-macro-expansion with and without argument.
10659
46427374
TT
106602011-10-15 Tom Tromey <tromey@redhat.com>
10661 Dodji Seketeli <dodji@redhat.com>
10662
10663 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
10664 (print_line, cb_define, do_line_change): Adjust to avoid touching
10665 the internals of struct line_map. Use the public API instead.
10666 * c-pch.c (c_common_read_pch): Likewise.
10667 * c-lex.c (fe_file_change): Likewise.
10668
fc8396e9
PC
106692011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
10670
10671 PR c++/17212
10672 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
10673
106742011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
10675
10676 PR c++/33067
10677 * c-pretty-print.c (pp_c_floating_constant): Output
10678 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
10679
e79983f4
MM
106802011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
10681
10682 * c-common.c (def_builtin_1): Delete old interface with two
10683 parallel arrays to hold standard builtin declarations, and replace
10684 it with a function based interface that can support creating
10685 builtins on the fly in the future. Change all uses, and poison
10686 the old names. Make sure 0 is not a legitimate builtin index.
10687 * c-omp.c (c_finish_omp_barrier): Ditto.
10688 (c_finish_omp_taskwait): Ditto.
10689 (c_finish_omp_flush): Ditto.
10690
6637388f
TG
106912011-10-11 Tristan Gingold <gingold@adacore.com>
10692
10693 * c.opt: (fallow-parameterless-variadic-functions): New.
10694
3797cb21
DS
106952011-09-08 Dodji Seketeli <dodji@redhat.com>
10696
10697 PR c++/33255 - Support -Wunused-local-typedefs warning
10698 * c-common.h (struct c_language_function::local_typedefs): New
10699 field.
9faeb493
UB
10700 (record_locally_defined_typedef, maybe_record_typedef_use)
10701 (maybe_warn_unused_local_typedefs): Declare new functions.
3797cb21 10702 * c-common.c (record_locally_defined_typedef)
9faeb493
UB
10703 (maybe_record_typedef_use)
10704 (maybe_warn_unused_local_typedefs): Define new functions.
3797cb21
DS
10705 * c.opt: Declare new -Wunused-local-typedefs flag.
10706
693ddb1b
EB
107072011-09-06 Eric Botcazou <ebotcazou@adacore.com>
10708
10709 PR middle-end/50266
10710 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
10711 computations.
10712
830c740f
RG
107132011-09-05 Richard Guenther <rguenther@suse.de>
10714
10715 * c-common.c (complete_array_type): Use ssize_int (-1) instead
10716 of integer_minus_one_node for empty array upper bounds.
10717
892a371f
DS
107182011-08-28 Dodji Seketeli <dodji@redhat.com>
10719
10720 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
10721 it's the first time it's being called on this main TU.
10722
0e3fdb48
RB
107232011-08-24 Richard Guenther <rguenther@suse.de>
10724
10725 PR c/49396
10726 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
10727
107282011-08-22 Gabriel Charette <gchare@google.com>
e3dfef44
GC
10729
10730 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
10731 defined in cpp_init_builtins and c_cpp_builtins.
10732
d4a83c10
JM
107332011-08-19 Joseph Myers <joseph@codesourcery.com>
10734
10735 * c-common.c (c_common_reswords): Add __builtin_complex.
10736 * c-common.h (RID_BUILTIN_COMPLEX): New.
10737
bbceee64
JM
107382011-08-18 Joseph Myers <joseph@codesourcery.com>
10739
10740 * c-common.c (c_common_reswords): Add _Noreturn.
10741 (keyword_is_function_specifier): Handle RID_NORETURN.
10742 * c-common.h (RID_NORETURN): New.
10743
3f8257db 107442011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
0e3a99ae
AS
10745
10746 * c-common.c (unsafe_conversion_p): New function. Check if it is
10747 unsafe to convert an expression to the type.
10748 (conversion_warning): Adjust, use unsafe_conversion_p.
10749 * c-common.h (unsafe_conversion_p): New function declaration.
10750
20906c66
JJ
107512011-08-02 Jakub Jelinek <jakub@redhat.com>
10752
10753 * c-common.h (c_finish_omp_atomic): Adjust prototype.
10754 (c_finish_omp_taskyield): New prototype.
10755 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
10756 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
10757 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
10758 or RHS1 have side-effects, evaluate those too in the right spot,
10759 if it is a decl and LHS is also a decl, error out if they
10760 aren't the same.
10761 (c_finish_omp_taskyield): New function.
10762 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
10763 * c-pragma.c (omp_pragmas): Add taskyield.
10764 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
10765 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
10766 PRAGMA_OMP_CLAUSE_MERGEABLE.
10767
770e5a2e
DS
107682011-07-25 Dodji Seketeli <dodji@redhat.com>
10769
10770 * c-common.h (set_underlying_type): Remove parm name from
10771 declaration.
10772
1baae426
RG
107732011-07-25 Romain Geissler <romain.geissler@gmail.com>
10774
10775 * c-pretty-print.h: Search c-common.h in c-family.
9faeb493 10776
fcb21722
JM
107772011-07-22 Jason Merrill <jason@redhat.com>
10778
76f86d00
JM
10779 PR c++/49793
10780 * c.opt (Wnarrowing): New.
10781
3a636414
JM
10782 PR c++/30112
10783 * c-common.h: Declare c_linkage_bindings.
10784 * c-pragma.c (handle_pragma_redefine_extname): Use it.
10785
fcb21722
JM
10786 PR c++/49813
10787 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
10788 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
10789 as flag_isoc99 for 'restrict'.
10790 (pp_c_specifier_qualifier_list): Likewise for _Complex.
10791
02614448
ILT
107922011-07-21 Ian Lance Taylor <iant@google.com>
10793
10794 PR middle-end/49705
10795 * c-common.c (c_disable_warnings): New static function.
10796 (c_enable_warnings): New static function.
10797 (c_fully_fold_internal): Change local unused_p to bool. Call
10798 c_disable_warnings and c_enable_warnings rather than change
10799 c_inhibit_evaluation_warnings.
10800
34429675
JM
108012011-07-20 Jason Merrill <jason@redhat.com>
10802
10803 PR c++/6709 (DR 743)
10804 PR c++/42603 (DR 950)
10805 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
10806 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
10807 (CPP_DECLTYPE): New.
10808 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
10809
5d49b6a7
RG
108102011-07-19 Richard Guenther <rguenther@suse.de>
10811
10812 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
10813 * c-omp.c (c_finish_omp_for): Likewise.
10814
e84a58ff
EB
108152011-07-12 Eric Botcazou <ebotcazou@adacore.com>
10816
10817 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
10818 body on the next line.
10819
329af3c7
JM
108202011-07-08 Jason Merrill <jason@redhat.com>
10821
4063e61b
JM
10822 PR c++/45437
10823 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
10824
329af3c7
JM
10825 PR c++/49673
10826 * c-common.c (c_apply_type_quals_to_decl): Don't check
10827 TYPE_NEEDS_CONSTRUCTING.
10828
1a072294
RG
108292011-07-06 Richard Guenther <rguenther@suse.de>
10830
10831 * c-common.c (c_common_nodes_and_builtins):
10832 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
10833
fce5dddd
RG
108342011-07-05 Richard Guenther <rguenther@suse.de>
10835
10836 * c-common.c (c_common_nodes_and_builtins): Build all common
10837 tree nodes first.
10838
45d439ac
JJ
108392011-06-27 Jakub Jelinek <jakub@redhat.com>
10840
56300785
JJ
10841 * c-common.h (c_tree_chain_next): New static inline function.
10842
45d439ac
JJ
10843 * c-common.c (check_builtin_function_arguments): Handle
10844 BUILT_IN_ASSUME_ALIGNED.
10845
e0a8ecf2
AM
108462011-06-21 Andrew MacLeod <amacleod@redhat.com>
10847
10848 * c-common.c: Add sync_ or SYNC__ to builtin names.
10849 * c-omp.c: Add sync_ or SYNC__ to builtin names.
dfb43cd5
PV
10850
108512011-06-20 Pierre Vittet <piervit@pvittet.com>
10852
10853 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
10854 handler.
10855 (gen_pragma_handler): New union.
10856 (internal_pragma_handler): New type.
10857 (c_register_pragma_with_data)
10858 (c_register_pragma_with_expansion_and_data): New functions.
10859
10860 * c-pragma.c (registered_pragmas, c_register_pragma_1)
10861 (c_register_pragma, c_register_pragma_with_expansion)
10862 (c_invoke_pragma_handler): Changed to work with
10863 internal_pragma_handler.
10864 (c_register_pragma_with_data)
10865 (c_register_pragma_with_expansion_and_data): New functions.
10866
677f3fa8
JM
108672011-06-14 Joseph Myers <joseph@codesourcery.com>
10868
10869 * c-common.c: Include common/common-target.h.
10870 (handle_section_attribute): Use
10871 targetm_common.have_named_sections.
10872 * c-cppbuiltin.c: Include common/common-target.h.
10873 (c_cpp_builtins): Use targetm_common.except_unwind_info.
10874
d7fc8c14
RG
108752011-06-10 Richard Guenther <rguenther@suse.de>
10876
10877 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
10878 to print a IDENTIFIER_NODE.
10879
10e48e39
RO
108802011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10881 Joseph Myers <joseph@codesourcery.com>
10882
10883 * c.opt (fbuilding-libgcc): New option.
10884 * c-cppbuiltin.c (c_cpp_builtins): Define
10885 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
10886
6976ae51
JM
108872011-06-07 Jason Merrill <jason@redhat.com>
10888
3ff60975
JM
10889 * c-common.c (max_tinst_depth): Lower default to 900.
10890
6976ae51
JM
10891 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
10892
009db074
RG
108932011-06-07 Richard Guenther <rguenther@suse.de>
10894
10895 * c-common.c (c_common_nodes_and_builtins): Do not set
10896 size_type_node or call set_sizetype.
10897
b4592b92
DS
108982011-06-07 Dodji Seketeli <dodji@redhat.com>
10899
10900 PR debug/49130
10901 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
9faeb493 10902 type when using pointer comparison to compare types.
b4592b92 10903
014ab419
JW
109042011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
10905
10906 * c.opt: Add -Wdelete-non-virtual-dtor.
10907 * c-opts.c (c_common_handle_option): Include it in -Wall.
10908
4f60111f
NF
109092011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
10910
10911 PR bootstrap/49190
10912
10913 Revert:
10914 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
10915
10916 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
10917 not tree_common.
10918
4cc4f2f4
JJ
109192011-05-27 Jakub Jelinek <jakub@redhat.com>
10920
10921 PR c++/49165
10922 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
10923 C++ don't call c_common_truthvalue_conversion on void type arms.
10924
38e01f9e
NF
109252011-05-27 Nathan Froyd <froydnj@codesourcery.com>
10926
10927 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
10928 (stmt_list_stack): Define.
10929 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
10930 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
10931
92e948a8
NF
109322011-05-26 Nathan Froyd <froydnj@codesourcery.com>
10933
10934 * c-common.c (warning_candidate_p): Check for BLOCKs.
10935
a2fc3e63
NF
109362011-05-26 Nathan Froyd <froydnj@codesourcery.com>
10937
10938 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
10939 not tree_common.
10940
0957c029
JJ
109412011-05-25 Jakub Jelinek <jakub@redhat.com>
10942
10943 * c-common.c (def_fn_type): Remove extra va_end.
10944
828fb3ba
JM
109452011-05-23 Jason Merrill <jason@redhat.com>
10946
10947 PR c++/48106
10948 * c-common.c (c_common_get_narrower): New.
10949 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
10950
dde05067
NF
109512011-05-23 Nathan Froyd <froydnj@codesourcery.com>
10952
10953 * c-common.h (check_function_arguments): Tweak prototype of
10954 check_function_arguments.
10955 * c-common.c (check_function_arguments): Likewise. Adjust
10956 calls to check_function_nonnull, check_function_format, and
10957 check_function_sentinel.
10958 (check_function_sentinel): Take a FUNCTION_TYPE rather than
10959 separate attributes and typelist arguments. Use
10960 FOREACH_FUNCTION_ARGS to iterate over argument types.
10961
3c0d13bf
PC
109622011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
10963
10964 * c-common.c (c_common_reswords): Reorder.
10965 * c-common.h (rid): Likewise.
10966
8242dd04
NF
109672011-05-10 Nathan Froyd <froydnj@codesourcery.com>
10968
10969 * c-common.c (def_fn_type): Don't call build_function_type, call
10970 build_function_type_array or build_varargs_function_type_array
10971 instead.
10972 (c_common_nodes_and_builtins): Likewise.
10973
3d528853
NF
109742011-05-05 Nathan Froyd <froydnj@codesourcery.com>
10975
10976 * c-common.c (c_add_case_label): Omit the loc argument to
10977 build_case_label.
10978 * c-common.h (build_case_label): Remove.
10979 * c-semantics.c (build_case_label): Remove.
10980
a04a722b
JM
109812011-05-05 Joseph Myers <joseph@codesourcery.com>
10982
10983 * c-objc.h (objc_start_method_definition): Update prototype.
10984 * stub-objc.c (objc_start_method_definition): Add extra parameter.
10985
e19a18d4
NF
109862011-05-04 Nathan Froyd <froydnj@codesourcery.com>
10987
10988 * c-common.c (check_main_parameter_types): Reindent. Don't use
10989 TYPE_ARG_TYPES directly.
10990 (handle_nonnull_attribute): Likewise.
10991 (sync_resolve_params): Likewise.
10992 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
10993 to check_format_string.
10994 (handle_format_attribute): Likewise.
10995 (check_format_string): Take a function type to examine instead of
10996 a type list. Use a function_arg_iterator to step through argument
10997 types.
10998
c62c040f
RG
109992011-05-04 Richard Guenther <rguenther@suse.de>
11000
11001 * c-common.c (fix_string_type): Use size_int for index type bounds.
11002 (start_fname_decls): Do not pass NULL to build_int_cst.
11003 (c_init_attributes): Likewise.
11004 * c-lex.c (c_lex_with_flags): Likewise.
11005
c12ff9d8
JM
110062011-04-27 Jason Merrill <jason@redhat.com>
11007
11008 * c-common.c (make_tree_vector_from_list): New.
11009 * c-common.h: Declare it.
11010
304dfbe3
RG
110112011-04-26 Richard Guenther <rguenther@suse.de>
11012
11013 PR preprocessor/48248
11014 * c-ppoutput.c (maybe_print_line): Always optimize newlines
11015 for output size with -P.
11016
3c0d13bf
PC
110172011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
11018
11019 * c-common.c (struct c_common_resword): Add __underlying_type.
11020 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
11021
04695783
JM
110222011-04-20 Jim Meyering <meyering@redhat.com>
11023
11024 * c-format.c (init_dollar_format_checking): Remove useless
11025 if-before-free.
11026
0dc33c3c
NP
110272011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
11028
11029 * c-objc.h (objc_get_interface_ivars): Removed.
3c0d13bf 11030 (objc_detect_field_duplicates): New.
0dc33c3c 11031 * stub-objc.c: Likewise.
3c0d13bf 11032
c59633d9
NP
110332011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
11034
11035 * stub-objc.c (objc_declare_protocols): Renamed to
11036 objc_declare_protocol.
11037 * c-objc.h: Likewise.
3c0d13bf 11038
32dabdaf
NP
110392011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
11040
11041 * stub-objc.c (objc_declare_class): Updated argument name.
11042
81f653d6
NF
110432011-04-12 Nathan Froyd <froydnj@codesourcery.com>
11044
11045 * c-common.h (c_common_init_ts): Declare.
11046 * c-common.c (c_common_init_ts): Define.
11047
eb345401
NP
110482011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
11049
11050 * c-objc.h (objc_build_message_expr): Updated prototype.
11051 * stub-objc.c (objc_build_message_expr): Likewise.
9faeb493 11052
a358e188
MJ
110532011-04-12 Martin Jambor <mjambor@suse.cz>
11054
11055 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
11056 of cgraph_node.
11057
e6313a78
RG
110582011-04-11 Richard Guenther <rguenther@suse.de>
11059
11060 * c-common.c (complete_array_type): Build a range type of
11061 proper type.
11062
dcf0c47e
NF
110632011-04-08 Nathan Froyd <froydnj@codesourcery.com>
11064
11065 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
11066 (handle_type_generic_attribute): Likewise.
11067
1ee44b26
JM
110682011-04-07 Jason Merrill <jason@redhat.com>
11069
11070 PR c++/48450
11071 * c-common.c (c_common_truthvalue_conversion): Don't ignore
11072 conversion from C++0x scoped enum.
11073
acce4e77
JM
110742011-04-06 Joseph Myers <joseph@codesourcery.com>
11075
11076 * c-target-def.h: New file.
11077 * c-target.def: New file.
11078 * c-target.h: New file.
11079 * c-common.c (targetcm): Don't define here.
11080 * c-common.h (default_handle_c_option): Declare.
11081 * c-format.c: Include c-target.h instead of target.h.
11082 * c-opts.c: Include c-target.h instead of target.h. Explicitly
11083 include tm.h.
11084 (default_handle_c_option): Move from targhooks.c.
11085
e2eefb55
JJ
110862011-03-29 Jakub Jelinek <jakub@redhat.com>
11087
11088 PR preprocessor/48248
11089 * c-ppoutput.c (print): Add src_file field.
11090 (init_pp_output): Initialize it.
11091 (maybe_print_line): Don't optimize by adding up to 8 newlines
11092 if map->to_file and print.src_file are different file.
11093 (print_line): Update print.src_file.
11094
ba78087b
KT
110952011-03-25 Kai Tietz <ktietz@redhat.com>
11096
11097 * c-ada-spec.c (compare_comment): Use filename_cmp
11098 instead of strcmp for filename.
11099
0edf1bb2
JL
111002011-03-25 Jeff Law <law@redhat.com>
11101
adfac8df 11102 * c-common.c (def_fn_type): Add missing va_end.
0edf1bb2 11103
c7dc8804
JM
111042011-03-25 Jason Merrill <jason@redhat.com>
11105
11106 * c.opt: Add -std=c++03.
11107
d1d879b1
EB
111082011-03-22 Eric Botcazou <ebotcazou@adacore.com>
11109
11110 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
11111
3f8257db 111122011-03-17 Kai Tietz <ktietz@redhat.com>
62d784f7
KT
11113
11114 PR target/12171
5050afdf
KT
11115 * c-pretty-print.c (pp_c_specifier_qualifier_list):
11116 Display allowed attributes for function pointer types.
11117 (pp_c_attributes_display): New function to display
11118 attributes having affects_type_identity flag set to true.
11119 * c-pretty-print.h (pp_c_attributes_display): New prototype.
11120
62d784f7
KT
11121 * c-common.c (c_common_attribute_table):
11122 Add new element.
11123 (c_common_format_attribute_table): Likewise.
11124
82d37118
JM
111252011-03-18 Jason Merrill <jason@redhat.com>
11126
49a000c3
JM
11127 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
11128 * c-common.h: Don't declare it here.
11129 * c-common.c: Or define it here.
11130 * c-opts.c (c_common_handle_option): Or set it here.
11131
82d37118
JM
11132 PR c++/35315
11133 * c-common.c (handle_transparent_union_attribute): Don't
11134 make a duplicate type in C++.
11135
17bc631c
JM
111362011-03-15 Jason Merrill <jason@redhat.com>
11137
11138 * c-common.c (max_constexpr_depth): New.
11139 * c-common.h: Declare it.
11140 * c-opts.c (c_common_handle_option): Set it.
11141 * c.opt (fconstexpr-depth): New option.
11142
1b9b91a6
JM
111432011-03-11 Jason Merrill <jason@redhat.com>
11144
f231b5ff
JM
11145 * c-common.c (attribute_takes_identifier_p): Add missing const.
11146
1b9b91a6
JM
11147 PR c++/46803
11148 * c-common.c (attribute_takes_identifier_p): Assume that an
11149 unknown attribute takes an identifier.
11150
a19e4d44
NF
111512011-03-07 Nathan Froyd <froydnj@codesourcery.com>
11152
11153 PR c/47786
11154 * c-common.c (c_type_hash): Call list_length instead of iterating
11155 through DECL_CHAIN. Rename 'i' to 'n_elements'.
11156
982d62f6
JJ
111572011-02-19 Jakub Jelinek <jakub@redhat.com>
11158
11159 PR c/47809
11160 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
11161
0a256240
NP
111622011-02-17 Iain Sandoe <iains@gcc.gnu.org>
11163
11164 * c.opt (fobjc-abi-version=) New.
11165 (fobjc-nilcheck): New.
11166
ba9e6dd5
NF
111672011-02-03 Nathan Froyd <froydnj@codesourcery.com>
11168
11169 PR c++/46890
11170 * c-common.h (keyword_is_decl_specifier): Declare.
11171 * c-common.c (keyword_is_decl_specifier): Define.
11172 (keyword_is_function_specifier): New function.
11173
7273813a
JJ
111742011-01-26 Jakub Jelinek <jakub@redhat.com>
11175
11176 PR c/47473
11177 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
11178 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
11179 REAL_TYPE.
11180
908ef79b
AC
111812011-01-26 Arnaud Charlet <charlet@adacore.com>
11182
11183 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
11184
237e9384
JJ
111852011-01-26 Jakub Jelinek <jakub@redhat.com>
11186
11187 PR pch/47430
11188 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
11189 after init_c_lex if pch_file is set.
11190
47ea1edf
DK
111912011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
11192
d4dba752 11193 PR c++/43601
47ea1edf
DK
11194 * c.opt (-fkeep-inline-dllexport): New switch.
11195
2aa9c6ae
RG
111962011-01-12 Richard Guenther <rguenther@suse.de>
11197
11198 PR middle-end/32511
11199 * c-common.c (handle_weak_attribute): Warn instead of error
11200 on declaring an inline function weak.
11201
7bd11157
TT
112022011-01-05 Tom Tromey <tromey@redhat.com>
11203
11204 * c-common.h (lvalue_error): Update.
11205 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
11206 not error.
11207
0e66e494 112082010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
9faeb493 11209
b4f588c4
NP
11210 PR objc/47075
11211 * c-objc.h (objc_finish_message_expr): Added argument to
11212 prototype.
11213
f4da8dce
NF
112142010-12-22 Nathan Froyd <froydnj@codesourcery.com>
11215
11216 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
11217 Use prototype_p.
11218
46270f14
NP
112192010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
11220
11221 * c-objc.h (objc_maybe_warn_exceptions): New.
9faeb493 11222 * stub-objc.c (objc_maybe_warn_exceptions): New.
46270f14 11223
4816c593
NF
112242010-12-10 Nathan Froyd <froydnj@codesourcery.com>
11225
11226 * c-common.h (readonly_error): Declare.
11227 * c-common.c (readonly_error): Define.
11228
7a6daeb0
NF
112292010-12-09 Nathan Froyd <froydnj@codesourcery.com>
11230
11231 * c-common.h (invalid_indirection_error): Declare.
11232 * c-common.c (invalid_indirection_error): Define.
11233
892f6119
RG
112342010-12-03 Richard Guenther <rguenther@suse.de>
11235
11236 PR c/46745
11237 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
11238 (pp_c_unary_expression): Likewise.
11239 (pp_c_expression): Likewise.
11240
6c39e757
NP
112412010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
11242
11243 * c-common.h (objc_finish_function): New.
11244 (objc_non_volatilized_type): Removed.
11245 (objc_type_quals_match): Removed.
11246 * stub-objc.c (objc_finish_function): New.
11247 (objc_non_volatilized_type): Removed.
11248 (objc_type_quals_match): Removed.
9faeb493 11249
7c475d11
JM
112502010-11-30 Joseph Myers <joseph@codesourcery.com>
11251
11252 * c-common.h (parse_optimize_options): Declare.
11253 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
11254 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
11255
71f3e391
JM
112562010-11-29 Joseph Myers <joseph@codesourcery.com>
11257
11258 * c-opts.c (check_deps_environment_vars): Use getenv instead of
11259 GET_ENVIRONMENT.
11260 * c-pch.c (O_BINARY): Don't define here.
11261 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
11262
d5fabb58
JM
112632010-11-25 Joseph Myers <joseph@codesourcery.com>
11264
11265 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
11266 targetm.except_unwind_info.
11267
299404a1
JM
112682010-11-23 Joseph Myers <joseph@codesourcery.com>
11269
11270 * c-opts.c (c_common_handle_option): Pass location to
11271 set_struct_debug_option.
11272
c98cd5bf
JM
112732010-11-23 Joseph Myers <joseph@codesourcery.com>
11274
11275 * c-common.c (visibility_options): Move from ../opts.c.
11276 * c-common.h (struct visibility_flags, visibility_options):
11277 Declare here.
11278 * c-opts.c (finish_options): Rename to c_finish_options.
11279 (c_common_init): Update call to finish_options.
11280
a9546771
NP
112812010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
11282
11283 PR objc/34033
11284 * c-lex.c (lex_string): Check that each string in an Objective-C
11285 string concat sequence starts with either one or zero '@', and
11286 that there are no spurious '@' signs at the end.
11287
24a57808
JM
112882010-11-20 Joseph Myers <joseph@codesourcery.com>
11289
11290 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
11291 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
11292 HANDLE_PRAGMA_VISIBILITY.
11293 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
11294 HANDLE_PRAGMA_VISIBILITY): Don't define.
11295 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
11296
a9aa2c3a
NF
112972010-11-20 Nathan Froyd <froydnj@codesourcery.com>
11298
11299 PR c++/16189
11300 PR c++/36888
11301 PR c++/45331
11302 * c-common.h (keyword_begins_type_specifier): Declare.
11303 (keyword_is_storage_class_specifier): Declare.
11304 (keyword_is_type_qualifier): Declare.
11305 * c-common.c (keyword_begins_type_specifier): New function.
11306 (keyword_is_storage_class_specifier): New function.
11307 (keyword_is_type_qualifier): Declare.
11308
5386338c
JM
113092010-11-19 Joseph Myers <joseph@codesourcery.com>
11310
11311 PR c/46547
11312 * c-common.c (in_late_binary_op): Define.
11313 (c_common_truthvalue_conversion): Check in_late_binary_op before
11314 calling c_save_expr.
11315 * c-common.h (in_late_binary_op): Declare.
11316
69ccdddb
JM
113172010-11-19 Joseph Myers <joseph@codesourcery.com>
11318
11319 * c-opts.c (c_common_handle_option): Update calls to
11320 set_struct_debug_option.
11321
6b192a09
NP
113222010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
11323
11324 * c-common.h (objc_declare_protocols): Added additional argument.
11325 * stub-objc.c (objc_declare_protocol): Same change.
9faeb493 11326
fb52b50a
NF
113272010-11-18 Nathan Froyd <froydnj@codesourcery.com>
11328
11329 PR c/33193
11330 * c-common.h (build_real_imag_expr): Declare.
11331 * c-semantics.c (build_real_imag_expr): Define.
11332
b37421c6
JM
113332010-11-17 Joseph Myers <joseph@codesourcery.com>
11334
11335 * c-opts.c (c_common_parse_file): Take no arguments.
11336 * c-common.h (c_common_parse_file): Update prototype.
11337
07078664
JJ
113382010-11-16 Jakub Jelinek <jakub@redhat.com>
11339
11340 PR c++/46401
11341 * c-common.c (warning_candidate_p): Don't track non-const calls
11342 or STRING_CSTs.
11343
c6a13190
ILT
113442010-11-15 Ian Lance Taylor <iant@google.com>
11345
11346 * c-lex.c (init_c_lex): Set macro debug callbacks if
11347 flag_dump_go_spec is set.
11348
925e8657
NP
113492010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
11350
11351 * c-common.h (objc_build_incr_expr_for_property_ref): New.
11352 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
11353
bb0a9581
NF
113542010-11-15 Nathan Froyd <froydnj@codesourcery.com>
11355
11356 PR preprocessor/45038
11357 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
11358 dialects.
11359
c5fa0890
JM
113602010-11-12 Joseph Myers <joseph@codesourcery.com>
11361
11362 * c-common.h (c_family_lang_mask): Declare.
11363 * c-opts.c (c_family_lang_mask): Make extern.
11364 * c-pragma.c (handle_pragma_diagnostic): Use
11365 control_warning_option.
11366
a4d8c676
JM
113672010-11-12 Joseph Myers <joseph@codesourcery.com>
11368
11369 * c-common.c (parse_optimize_options): Update call to
11370 decode_options.
11371 * c-common.h (c_common_handle_option): Update prototype.
11372 * c-opts.c (c_common_handle_option): Take location_t parameter and
11373 pass it to other functions.
11374
f954bd2c
JM
113752010-11-11 Joseph Myers <joseph@codesourcery.com>
11376
11377 * c-opts.c (warning_as_error_callback): Remove.
11378 (c_common_initialize_diagnostics): Don't call
11379 register_warning_as_error_callback.
11380 (c_common_handle_option): Handle -Werror=normalized= here.
11381
d8a07487
JM
113822010-11-10 Joseph Myers <joseph@codesourcery.com>
11383
11384 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
11385 in diagnostic.
11386 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
11387 letter.
11388 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
11389 Remove trailing '.' from diagnostics.
11390 * c.opt (Wwrite-strings_: Avoid '`' in help text.
11391
d5478783
JM
113922010-11-10 Joseph Myers <joseph@codesourcery.com>
11393
11394 * c-common.c (parse_optimize_options): Pass global_dc to
11395 decode_options.
11396 * c-opts.c (c_common_handle_option): Pass &global_options to
11397 set_Wstrict_aliasing.
11398 * c.opt (v): Don't mark Common or document here.
11399
91ebb981
IS
114002010-11-06 Iain Sandoe <iains@gcc.gnu.org>
11401
11402 PR target/44981
11403 * c-format.c (format_type): New type gcc_objc_string_format_type.
11404 (valid_stringptr_type_p): New.
11405 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
9faeb493 11406 (check_format_string): Pass expected type, use
91ebb981
IS
11407 valid_stringptr_type_p (), check that the format string types are
11408 consistent with the format specification.
11409 (decode_format_attr): Warn if NSString is used outside objective-c.
11410 (format_types_orig): Add NSString.
11411 (format_name): New.
11412 (format_flags): New.
11413 (check_format_arg): Handle format strings requiring an external parser.
11414 first_target_format_type: New variable.
11415 (handle_format_attribute): Set up first_target_format_type, pass the
11416 expected format arg string type to check_format_string().
ab20d992 11417 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
91ebb981
IS
11418 * stub-objc.c (objc_string_ref_type_p): New.
11419 (objc_check_format_arg): New.
11420
bede2adc
NP
114212010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
11422
9faeb493 11423 Fixed using the Objective-C 2.0 dot-syntax with class names.
bede2adc
NP
11424 * c-common.h (objc_build_class_component_ref): New.
11425 * stub-objc.c (objc_build_class_component_ref): New.
11426
9a179d01
NP
114272010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
11428
11429 * c.opt (Wproperty-assign-default): New option.
11430
22d8d616
NP
114312010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
11432
11433 Implemented -fobjc-std=objc1 flag.
11434 * c.opt (fobjc-std=objc1): New option.
11435
2debdb4f
NP
114362010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
11437
11438 Implemented format and noreturn attributes for Objective-C methods.
11439 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
11440 attribute for Objective-C methods.
11441
ec52b111
JM
114422010-10-31 Jason Merrill <jason@redhat.com>
11443
11444 * c-common.c (conversion_warning, warn_for_collisions_1): Use
11445 EXPR_LOC_OR_HERE.
11446
46a88c12
NP
114472010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
11448
11449 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
11450 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
11451 (objc_add_property_declaration): Removed arguments for copies and
11452 ivar.
11453 (objc_build_getter_call): Renamed to
11454 objc_maybe_build_component_ref.
11455 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
11456 (objc_is_property_ref): New.
11457 * c-common.c (c_common_reswords): Removed copies and ivar.
11458 * stub-objc.c (objc_add_property_declaration): Removed arguments
11459 for copies and ivar.
11460 (objc_build_getter_call): Renamed to
11461 objc_maybe_build_component_ref.
11462 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
11463 (objc_is_property_ref): New.
9faeb493 11464
1e4bf85b
AC
114652010-10-29 Arnaud Charlet <charlet@adacore.com>
11466 Matthew Gingell <gingell@adacore.com>
11467
11468 * c-ada-spec.c (separate_class_package): New function.
11469 (pp_ada_tree_identifier): Prefix references to C++ classes with the
11470 name of their enclosing package.
11471 (print_ada_declaration): Use separate_class_package.
11472
81f0bab2
JM
114732010-10-27 Jason Merrill <jason@redhat.com>
11474
2b08f2c5
JM
11475 * c-common.c (c_common_reswords): Add __is_literal_type.
11476 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
11477
81f0bab2
JM
11478 * c-common.c (check_case_value): Remove special C++ code.
11479
200290f2
NP
114802010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
11481
11482 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
11483 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
11484 and RID_LAST_PATTR.
11485 (objc_add_property_declaration): Added additional arguments.
11486 (objc_property_attribute_kind): Removed.
11487 (objc_set_property_attr): Removed.
11488 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
11489 copy and nonatomic.
11490 * stub-objc.c (objc_add_property_declaration): Added additional
11491 arguments.
11492 (objc_set_property_attr): Removed.
9faeb493 11493
f614132b
NP
114942010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
11495
11496 * c-common.h (objc_add_property_variable): Renamed to
11497 objc_add_property_declaration. Added location argument.
11498 * stub-objc.c (objc_add_property_variable): Same change.
b1726d6c 11499
b8a18805
NP
115002010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
11501
11502 * c-common.h (objc_maybe_printable_name): New.
11503 * stub-objc.c (objc_maybe_printable_name): New.
11504
3f8257db
JJ
115052010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
11506 Andrew Pinski <pinskia@gmail.com>
30cd1c5d
AS
11507
11508 * c-common.h (c_common_mark_addressable_vec): Declare.
11509 * c-common.c (c_common_mark_addressable_vec): New function.
11510
249a82c4
NP
115112010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
11512
11513 * c-common.h (objc_set_method_type): Removed.
11514 (objc_add_method_declaration): Added boolean argument.
11515 (objc_start_method_definition): Same change.
11516 (objc_build_method_signature): Same change.
11517 * stub-objc.c (objc_set_method_type): Removed.
11518 (objc_add_method_declaration): Added boolean argument.
11519 (objc_start_method_definition): Same change.
11520 (objc_build_method_signature): Same change.
11521
977e30bc
NP
115222010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
11523
11524 * c-common.h (finish_file): Removed.
11525 (objc_write_global_declarations): New.
11526 * c-opts.c (c_common_parse_file): Do not call finish_file.
11527 * stub-objc.c (objc_write_global_declarations): New.
9faeb493 11528
da57d1b9
NP
115292010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
11530
11531 Implemented parsing @synthesize and @dynamic for
11532 Objective-C/Objective-C++.
11533 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
11534 (objc_add_synthesize_declaration): New.
11535 (objc_add_dynamic_declaration): New.
11536 * c-common.c (c_common_reswords): Add synthesize and dynamic.
11537 * stub-objc.c (objc_add_synthesize_declaration): New.
11538 (objc_add_dynamic_declaration): New.
9faeb493 11539
0069111f
MM
115402010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
11541
11542 PR target/46041
11543 * c-cppbuiltin.c (mode_has_fma): Move function here from
11544 builtins.c. Don't use the fma optab, instead just use the
11545 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
11546 using -save-temps.
11547
e426b47b
NP
115482010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
11549
11550 Merge from 'apple/trunk' branch on FSF servers.
0069111f 11551
3f8257db 11552 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
e426b47b 11553
9faeb493 11554 Radar 4330422
e426b47b
NP
11555 * c-common.h (objc_non_volatilized_type): New declaration
11556 * stub-objc.c (objc_non_volatilized_type): New stub.
11557
90fbfdc3
NP
115582010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
11559
e426b47b 11560 Merge from 'apple/trunk' branch on FSF servers.
90fbfdc3 11561
ab20d992 11562 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
90fbfdc3 11563
9faeb493 11564 Radar 4133425
90fbfdc3 11565 * c-common.h (objc_diagnose_private_ivar): New decl.
0069111f 11566 * stub-objc.c (objc_diagnose_private_ivar): New stub.
90fbfdc3 11567
c37d8c30
IS
115682010-10-17 Iain Sandoe <iains@gcc.gnu.org>
11569
11570 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
11571 * c-common.h (enum rid): Add RID_AT_PACKAGE.
11572 (objc_ivar_visibility_kind): New enum.
11573 (objc_set_visibility): Adjust prototype to use visibility enum.
0069111f 11574 * stub-objc.c (objc_set_visibility): Adjust stub to use
c37d8c30
IS
11575 visibility enum.
11576
1b1562a5
MM
115772010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
11578
11579 * c-cppbuiltin.c (builtin_define_float_constants): Emit
11580 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
11581 has the appropriate fma builtins.
11582 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
11583
668ea4b1
IS
115842010-10-14 Iain Sandoe <iains@gcc.gnu.org>
11585
1b1562a5 11586 merge from FSF apple 'trunk' branch.
3f8257db 11587 2006 Fariborz Jahanian <fjahanian@apple.com>
1b1562a5 11588
668ea4b1
IS
11589 Radars 4436866, 4505126, 4506903, 4517826
11590 * c-common.c (c_common_resword): Define @property and its attributes.
11591 * c-common.h: Define property attribute enum entries.
11592 (OBJC_IS_PATTR_KEYWORD): New.
11593 (objc_property_attribute_kind): New enum.
11594 Declare objc_set_property_attr (), objc_add_property_variable (),
11595 objc_build_getter_call () and objc_build_setter_call ().
11596 * stub-objc.c (objc_set_property_attr): New stub.
11597 (objc_add_property_variable): Likewise.
11598 (objc_build_getter_call): Likewise.
11599 (objc_build_setter_call) Likewise.
1b1562a5 11600
a1178b30
IS
116012010-10-13 Iain Sandoe <iains@gcc.gnu.org>
11602
1b1562a5 11603 merge from FSF apple 'trunk' branch.
ab20d992 11604 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
a1178b30
IS
11605
11606 Radar 3803157 (method attributes)
11607 * c-common.c (handle_deprecated_attribute): Recognize
11608 objc methods as valid declarations.
11609 * c-common.h: Declare objc_method_decl ().
1b1562a5 11610 * stub-objc.c (objc_method_decl): New stub.
a1178b30 11611
a75bfaa6
JM
116122010-10-08 Joseph Myers <joseph@codesourcery.com>
11613
11614 * c-common.c (parse_optimize_options): Call
11615 decode_cmdline_options_to_array_default_mask before
11616 decode_options. Update arguments to decode_options.
11617 * c-common.h (c_common_init_options_struct): Declare.
11618 * c-opts.c (c_common_init_options_struct): New. Split out from
11619 c_common_init_options.
11620
f05b9d93
NP
116212010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
11622
11623 Implemented fast enumeration for Objective-C.
11624 * c-common.h (objc_finish_foreach_loop): New.
11625 * stub-objc.c (objc_finish_foreach_loop): New.
11626
1ebe4b4f
JM
116272010-10-05 Joseph Myers <joseph@codesourcery.com>
11628
11629 * c-common.h (struct diagnostic_context): Don't declare here.
11630 (c_common_initialize_diagnostics): Declare using
11631 diagnostic_context typedef.
11632 * c-opts.c (c_common_handle_option): Pass global_dc to
11633 handle_generated_option.
11634
d4d24ba4
JM
116352010-10-04 Joseph Myers <joseph@codesourcery.com>
11636
11637 * c-opts.c (c_common_handle_option): Pass &global_options_set to
11638 handle_generated_option.
11639
478a1c5b
ILT
116402010-10-03 Ian Lance Taylor <iant@google.com>
11641
11642 * c.opt (-fplan9-extensions): New option.
11643
82a1c2fe
FXC
116442010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
11645
11646 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
11647 Remove.
11648 (c_cpp_builtins): Call functions from cppbuiltin.c instead
11649 of duplicating code.
11650
92902b1b
IS
116512010-09-30 Iain Sandoe <iains@gcc.gnu.org>
11652
11653 * c-common.c: Add two new entries for @optional
11654 and @required keywords.
11655
11656 merge from FSF 'apple/trunk' branch.
3f8257db 11657 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
92902b1b
IS
11658
11659 Radar 4386773
11660 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
11661 objective-c keywords.
11662 (objc_set_method_opt): New declaration.
11663 * stub-objc.c (objc_set_method_opt): New stub.
9faeb493 11664
46625112
JM
116652010-09-30 Joseph Myers <joseph@codesourcery.com>
11666
11667 * c-common.c (handle_optimize_attribute): Pass &global_options to
11668 cl_optimization_save and cl_optimization_restore.
11669 * c-opts.c (c_common_handle_option): Pass &global_options to
11670 handle_generated_option.
11671 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
11672 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
11673 &global_options to cl_optimization_restore.
11674
49b91f05
NP
116752010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
11676
11677 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
11678 Objective-C/Objective-C++ keywords.
11679
13ed556f 116802010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
a6341d57 11681
9faeb493
UB
11682 Merge from 'apple/trunk' branch on FSF servers.
11683
3f8257db 11684 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
a6341d57
NP
11685
11686 Radar 4281748
11687 * c-common.h (objc_check_global_decl): New declaration.
11688 * stub-objc.c (objc_check_global_decl): New stub.
11689
f0036cca
JM
116902010-09-29 Joseph Myers <joseph@codesourcery.com>
11691
11692 * c.opt: Don't use VarExists.
11693
e3339d0f
JM
116942010-09-29 Joseph Myers <joseph@codesourcery.com>
11695
11696 * c-common.c (c_cpp_error): Update names of diagnostic_context
11697 members.
11698 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
11699 cl_optimization members.
11700 * c-opts.c (warning_as_error_callback, c_common_handle_option,
11701 sanitize_cpp_opts, finish_options): Update names of cpp_options
11702 members.
11703
1973201f
NP
117042010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
11705
11706 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
11707 (objc_is_reserved_word): Removed.
11708 * c-common.c: Updated comments.
11709 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
11710 objc_is_reserved_word.
11711 * stub-objc.c (objc_is_reserved_word): Removed.
11712
f7e71da5
IS
117132010-09-28 Iain Sandoe <iains@gcc.gnu.org>
11714
9faeb493 11715 * c-common.h (objc_add_method_declaration): Adjust prototype to
f7e71da5
IS
11716 include attributes.
11717 (objc_start_method_definition): Likewise.
11718 (objc_build_keyword_decl): Likewise.
11719 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
11720 (objc_start_method_definition): Likewise.
11721 (objc_build_keyword_decl): Likewise.
11722
c165dca7
IS
117232010-09-28 Iain Sandoe <iains@gcc.gnu.org>
11724
11725 * c-common.h (objc_start_class_interface): Adjust prototype.
11726 (objc_start_category_interface): Likewise.
11727 (objc_start_protocol): Likewise.
11728 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
11729 (objc_start_class_interface): Likewise.
11730 (objc_start_category_interface): Likewise.
11731
7458026b
ILT
117322010-09-27 Ian Lance Taylor <iant@google.com>
11733
11734 * c-common.c (c_common_attribute_table): Add no_split_stack.
11735 (handle_no_split_stack_attribute): New static function.
11736
b581b85b
NP
117372010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
11738
9faeb493 11739 Merge from 'apple/trunk' branch on FSF servers.
b581b85b 11740
3f8257db 11741 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
b581b85b 11742
9faeb493 11743 Radar 4229905
b581b85b
NP
11744 * c-common.h (objc_have_common_type): New declaration.
11745 * stub-objc.c (objc_have_common_type): New stub.
11746
11747 2005-06-22 Ziemowit Laski <zlaski@apple.com>
11748
11749 Radar 4154928
11750 * c-common.h (objc_common_type): New prototype.
9faeb493 11751 * stub-objc.c (objc_common_type): New stub.
b581b85b 11752
46a4da10
JH
117532010-09-24 Jan Hubicka <jh@suse.cz>
11754
11755 * c-common.c (handle_leaf_attribute): New function.
11756 (struct attribute_spec c_common_att): Add leaf.
11757
e200444e
JM
117582010-09-22 Joseph Myers <joseph@codesourcery.com>
11759
11760 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
11761 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
11762 -dump, -dump=, -imacros, -imacros=, -include, -include=,
11763 -include-barrier, -include-directory, -include-directory=,
11764 -include-directory-after, -include-directory-after=,
11765 -include-prefix, -include-prefix=, -include-with-prefix,
11766 -include-with-prefix=, -include-with-prefix-after,
11767 -include-with-prefix-after=, -include-with-prefix-before,
11768 -include-with-prefix-before=, -no-integrated-cpp,
11769 -no-line-commands, -no-standard-includes, -no-warnings, -output,
11770 -output=, -pedantic, -pedantic-errors, -preprocess,
11771 -print-missing-file-dependencies, -trace-includes, -traditional,
11772 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
11773 -user-dependencies, -verbose, -write-dependencies,
11774 -write-user-dependencies, no-integrated-cpp, traditional): New.
11775
29a80ea6
NP
117762010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
11777
11778 PR objc/23710
ac1fc2fc
NP
11779 * c-common.h (objc_start_method_definition): Return bool instead
11780 of void.
11781 * stub-objc.c (objc_start_method_definition): Return bool instead
11782 of void.
11783
117842010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
11785
11786 PR objc/25965
11787 * c-common.h (objc_get_interface_ivars): New declaration.
11788 * stub-objc.c (objc_get_interface_ivars): New stub.
29a80ea6 11789
de621752
ILT
117902010-09-15 Ian Lance Taylor <iant@google.com>
11791
11792 * c-common.c (parse_optimize_options): Do not capitalize warning
06730c5d 11793 messages. Remove period at end of warning message.
de621752 11794
ba885ec5
NS
117952010-09-09 Nathan Sidwell <nathan@codesourcery.com>
11796
11797 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
11798 (handle_alias_attribute): ... here.
11799 (handle_ifunc_attribute): New.
11800
c5ee1358
MM
118012010-09-06 Mark Mitchell <mark@codesourcery.com>
11802
11803 * c-common.h (do_warn_double_promotion): Declare.
11804 * c-common.c (do_warn_double_promotion): Define.
11805
0a0b3574
MM
118062010-09-05 Mark Mitchell <mark@codesourcery.com>
11807
11808 * c.opt (Wdouble-promotion): New.
11809
d1779886
JM
118102010-09-02 Joseph Myers <joseph@codesourcery.com>
11811
11812 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
11813 fvtable-thunks, fxref): Mark no longer supported in help text.
11814
2d2bd949
JM
118152010-09-02 Joseph Myers <joseph@codesourcery.com>
11816
11817 * c.opt (Wimport, fall-virtual, falt-external-templates,
11818 fdefault-inline, fenum-int-equiv, fexternal-templates,
11819 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
11820 fname-mangling-version-, fnew-abi, fnonnull-objects,
11821 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
11822 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
11823 applicable.
11824 (fhandle-exceptions): Mark with Alias and Warn.
11825 * c-opts.c (c_common_handle_option): Don't handle options marked
11826 as ignored.
11827
5de8299c
JM
118282010-09-02 Joseph Myers <joseph@codesourcery.com>
11829
11830 * c.opt (Wcomments, Werror-implicit-function-declaration,
11831 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
11832 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
11833 aliases.
11834 * c-common.c (option_codes): Use OPT_Wcomment instead of
11835 OPT_Wcomments.
11836 * c-opts.c (warning_as_error_callback, c_common_handle_option):
11837 Don't handle options marked as aliases.
11838
0ceb0201
RG
118392010-08-25 Richard Guenther <rguenther@suse.de>
11840
11841 * c-common.c (c_common_get_alias_set): Remove special
11842 handling for pointers.
11843
ac47786e
NF
118442010-08-20 Nathan Froyd <froydnj@codesourcery.com>
11845
11846 * c-common.c: Use FOR_EACH_VEC_ELT.
11847 * c-gimplify.c: Likewise.
11848 * c-pragma.c: Likewise.
11849
c878765b
JM
118502010-08-16 Joseph Myers <joseph@codesourcery.com>
11851
11852 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
11853 RejectDriver.
11854 (MMDX): Change back to MMD. Mark NoDriverArg instead of
11855 RejectDriver.
11856 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
11857 instead of OPT_MDX and OPT_MMDX.
11858
603349bf
JM
118592010-08-16 Joseph Myers <joseph@codesourcery.com>
11860
11861 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
11862
644fa7ac
JM
118632010-08-12 Joseph Myers <joseph@codesourcery.com>
11864
11865 * c.opt (MD, MMD): Change to MDX and MMDX.
11866 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
11867
481e1176
JM
118682010-08-11 Joseph Myers <joseph@codesourcery.com>
11869
11870 * c-opts.c (c_common_handle_option): Call handle_generated_option
11871 instead of handle_option.
11872
ac8dc9f7
NF
118732010-08-08 Nathan Froyd <froydnj@codesourcery.com>
11874
11875 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
11876 (maybe_apply_renaming_pragma): Delete unneeded declarations.
11877
4f8c876d
NF
118782010-08-08 Nathan Froyd <froydnj@codesourcery.com>
11879
11880 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
11881 (pending_redefine_extname): Change type to a VEC.
11882 (add_to_renaming_pragma_list): Update for new type of
11883 pending_redefine_extname.
ac8dc9f7 11884 (maybe_apply_renaming_pragma): Likewise.
4f8c876d 11885
3b0c690e
AC
118862010-08-04 Arnaud Charlet <charlet@adacore.com>
11887
11888 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
11889 visited.
11890 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
11891 decide whether a type has already been declared/seen.
11892 Do not go to the original type.
11893 (dump_nested_types): New parameter forward.
11894 Generate forward declaration if needed and mark type as visited.
11895 (print_ada_declaration): Call dump_nested_types if not already done.
11896 Mark types as visited.
11897
1890bccc
JM
118982010-08-03 Joseph Myers <joseph@codesourcery.com>
11899
11900 * c.opt (-print-pch-checksum): Remove option.
11901 * c-opts.c (c_common_handle_option): Don't handle
11902 OPT_print_pch_checksum.
11903
5f20c657
JM
119042010-07-27 Joseph Myers <joseph@codesourcery.com>
11905
11906 * c-common.h (c_common_handle_option): Update prototype and return
11907 value type.
11908 * c-opts.c (c_common_handle_option): Update prototype and return
11909 value type. Update calls to handle_option and
11910 enable_warning_as_error.
11911
f551f80c
JJ
119122010-07-27 Jakub Jelinek <jakub@redhat.com>
11913
11914 PR c/45079
11915 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
11916
61ff2bdc
JM
119172010-07-27 Joseph Myers <joseph@codesourcery.com>
11918
11919 * c-common.h (c_common_missing_argument): Remove.
11920 * c-opts.c (c_common_missing_argument): Remove.
11921 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
11922 idirafter, imacros, include, isysroot, isystem, iquote): Add
11923 MissingArgError.
11924 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
11925
7a9bf9a4
JM
119262010-07-27 Joseph Myers <joseph@codesourcery.com>
11927
11928 * c-common.h (c_common_option_lang_mask,
11929 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
11930 New.
11931 (c_common_init_options): Update prototype.
11932 * c-opts.c (c_common_option_lang_mask): New.
11933 (c_common_initialize_diagnostics): Split out of
11934 c_common_init_options.
11935 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
11936 New.
11937 (c_common_init_options): Update prototype. Use decoded options in
11938 search for -lang-asm.
11939
910ad8de
NF
119402010-07-15 Nathan Froyd <froydnj@codesourcery.com>
11941
11942 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
11943 * c-format.c: Likewise.
11944
718f9c0f
MLI
119452010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
11946
11947 * c-common.h: Include diagnostic-core.h. Error if already
11948 included.
11949 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
11950
4d451982
MLI
119512010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
11952
adfac8df 11953 * c-common.c (IN_GCC_FRONTEND): Do not undef.
4d451982
MLI
11954 Do not include expr.h
11955 (vector_mode_valid_p): Move here.
11956
119fe915
SB
119572010-06-21 DJ Delorie <dj@redhat.com>
11958
11959 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
11960 allow these pragmas anywhere.
11961
119622010-06-14 Jakub Jelinek <jakub@redhat.com>
11963
11964 PR bootstrap/44509
11965 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
11966 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
11967 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
11968 ggc_strdup instead of xstrdup.
11969
119702010-06-10 Jakub Jelinek <jakub@redhat.com>
11971
11972 * c-cppbuiltin.c: Include cpp-id-data.h.
11973 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
11974 (lazy_hex_fp_value): New function.
11975 (builtin_define_with_hex_fp_value): Provide definitions lazily.
11976
6662d794
MLI
119772010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
11978
11979 * c-gimplify.c: Do not include tree-flow.h
11980
38f8b050
JR
119812010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
11982
11983 PR other/44034
11984 * c-common.c: Rename targetm member:
11985 targetm.enum_va_list -> targetm.enum_va_list_p
11986
9589f23e
AS
119872010-06-28 Anatoly Sokolov <aesok@post.ru>
11988
11989 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
11990
3b06d379
SB
119912010-06-28 Steven Bosscher <steven@gcc.gnu.org>
11992
11993 * c-cppbuiltin.c: Do not include except.h.
11994
d166d4c3
AK
119952010-06-24 Andi Kleen <ak@linux.intel.com>
11996
9faeb493
UB
11997 * c-common.c (warn_for_omitted_condop): New.
11998 * c-common.h (warn_for_omitted_condop): Add prototype.
d166d4c3 11999
70cb8be6
JM
120002010-06-21 Joseph Myers <joseph@codesourcery.com>
12001
12002 * c.opt (lang-objc): Remove.
12003 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
12004
a4c97feb
JR
120052010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
12006
12007 * c-opts.c: Include "tm_p.h".
12008
6e2f1956
JM
120092010-06-20 Joseph Myers <joseph@codesourcery.com>
12010
12011 * c-common.c (parse_optimize_options): Update call to
12012 decode_options.
12013
bc87224e
NF
120142010-06-18 Nathan Froyd <froydnj@codesourcery.com>
12015
12016 * c-common.c (record_types_used_by_current_var_decl): Adjust for
12017 new type of types_used_by_cur_var_decl.
12018
b49cf425
JR
120192010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
12020
12021 PR bootstrap/44512
12022 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
12023 for C++ standard compliance.
12024
59f9c2ed
JM
120252010-06-16 Jason Merrill <jason@redhat.com>
12026
12027 * c.opt: Add -Wnoexcept.
12028
33766b66
RG
120292010-06-16 Richard Guenther <rguenther@suse.de>
12030
12031 PR c/44555
12032 * c-common.c (c_common_truthvalue_conversion): Remove
12033 premature and wrong optimization concering ADDR_EXPRs.
12034
eff7e30c
AC
120352010-06-15 Arnaud Charlet <charlet@adacore.com>
12036
12037 * c-ada-spec.c (dump_sloc): Remove column info.
12038 (is_simple_enum): New function.
12039 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
12040 enum types when relevant.
12041
6312e84d
MLI
120422010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
12043
9faeb493 12044 * c-common.c (conversion_warning): Warn at expression
6312e84d
MLI
12045 location.
12046
1cb42611
JM
120472010-06-10 Joseph Myers <joseph@codesourcery.com>
12048
12049 * c-opts.c (c_common_handle_option): Don't handle
12050 OPT_fshow_column.
12051
a9429e29
LB
120522010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
12053
12054 * c-pragma.c (push_alignment): Use typed GC allocation.
12055 (handle_pragma_push_options): Likewise.
12056
12057 * c-common.c (parse_optimize_options): Likewise.
12058
12059 * c-common.h (struct sorted_fields_type): Add variable_size GTY
12060 option.
12061
5498f011
JM
120622010-06-07 Joseph Myers <joseph@codesourcery.com>
12063
12064 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
12065 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
12066 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
12067 flag_signed_bitfields, warn_strict_null_sentinel,
12068 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
12069 flag_gen_declaration, flag_no_gnu_keywords,
12070 flag_implement_inlines, flag_implicit_templates,
12071 flag_implicit_inline_templates, flag_optional_diags,
12072 flag_elide_constructors, flag_default_inline, flag_rtti,
12073 flag_conserve_space, flag_access_control, flag_check_new,
12074 flag_new_for_scope, flag_weak, flag_working_directory,
12075 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
12076 flag_enforce_eh_specs, flag_threadsafe_statics,
12077 flag_pretty_templates): Remove.
12078 * c-common.h (flag_preprocess_only, flag_nil_receivers,
12079 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
12080 flag_replace_objc_classes, flag_undef, flag_no_builtin,
12081 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
12082 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
12083 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
12084 flag_no_gnu_keywords, flag_implement_inlines,
12085 flag_implicit_templates, flag_implicit_inline_templates,
12086 flag_optional_diags, flag_elide_constructors, flag_default_inline,
12087 flag_rtti, flag_conserve_space, flag_access_control,
12088 flag_check_new, flag_new_for_scope, flag_weak,
12089 flag_working_directory, flag_use_cxa_atexit,
12090 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
12091 flag_threadsafe_statics, flag_pretty_templates,
12092 warn_strict_null_sentinel): Remove.
12093 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
12094 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
12095 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
12096 fimplicit-inline-templates, fimplicit-templates,
12097 flax-vector-conversions, fms-extensions, fnil-receivers,
12098 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
12099 frtti, fshort-double, fshort-enums, fshort-wchar,
12100 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
12101 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
12102 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
12103 gen-decls, undef): Use Var.
12104 (fdefault-inline, foptional-diags): Document as doing nothing.
12105 * c-opts.c (c_common_handle_option): Remove cases for options now
12106 using Var. Mark ignored options as such.
12107
39dabefd
SB
121082010-06-05 Steven Bosscher <steven@gcc.gnu.org>
12109
9faeb493 12110 * c-common.c: Moved to here from parent directory.
39dabefd
SB
12111 * c-common.def: Likewise.
12112 * c-common.h: Likewise.
12113 * c-cppbuiltin.c: Likewise.
12114 * c-dump.c: Likewise.
12115 * c-format.c: Likewise.
12116 * c-format.h : Likewise.
12117 * c-gimplify.c: Likewise.
12118 * c-lex.c: Likewise.
12119 * c-omp.c: Likewise.
12120 * c.opt: Likewise.
12121 * c-opts.c: Likewise.
12122 * c-pch.c: Likewise.
12123 * c-ppoutput.c: Likewise.
12124 * c-pragma.c: Likewise.
12125 * c-pragma.h: Likewise.
12126 * c-pretty-print.c: Likewise.
12127 * c-pretty-print.h: Likewise.
12128 * c-semantics.c: Likewise.
12129 * stub-objc.c: Likewise.
12130
12131 * c-common.c: Include gt-c-family-c-common.h.
12132 * c-pragma.c: Include gt-c-family-c-pragma.h.
12133\f
c48514be 12134Copyright (C) 2010-2021 Free Software Foundation, Inc.
39dabefd
SB
12135
12136Copying and distribution of this file, with or without modification,
12137are permitted in any medium without royalty provided the copyright
12138notice and this notice are preserved.