]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c-family/ChangeLog
Daily bump.
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
CommitLineData
59cf67d1
GA
12021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
2
3 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DETACH.
4 Redefine PRAGMA_OACC_CLAUSE_DETACH.
5
2f7f0d32
GA
62021-01-15 Jakub Jelinek <jakub@redhat.com>
7
8 PR tree-optimization/98597
9 * c-pretty-print.c: Include options.h.
10 (c_fold_indirect_ref_for_warn): New function.
11 (print_mem_ref): Use it. If it returns something that has compatible
12 type and is TBAA compatible with zero offset, print it and return,
13 otherwise print it using offsetof syntax or array ref syntax. Fix up
14 printing if MEM_REFs first operand is ADDR_EXPR, or when the first
15 argument has pointer to array type. Print pointers using the standard
16 formatting.
17
6851dda2
GA
182021-01-12 Martin Sebor <msebor@redhat.com>
19
20 PR c/98597
21 PR c/98592
22 * c-pretty-print.c (print_mem_ref): Avoid assuming MEM_REF operand
23 has pointer type. Remove redundant code. Avoid calling
24 gimple_canonical_types_compatible_p.
25
7d187e4f
GA
262021-01-07 Martin Sebor <msebor@redhat.com>
27
28 PR middle-end/98578
29 * c-pretty-print.c (print_mem_ref): Strip array from access type.
30 Avoid assuming acces type's size is constant. Correct condition
31 guarding the printing of a parenthesis.
32
942ae5be
GA
332021-01-06 Martin Sebor <msebor@redhat.com>
34
35 PR c++/95768
36 * c-pretty-print.c (c_pretty_printer::primary_expression): For
37 SSA_NAMEs print VLA names and GIMPLE defining statements.
38 (print_mem_ref): New function.
39 (c_pretty_printer::unary_expression): Call it.
40
412021-01-06 Richard Biener <rguenther@suse.de>
42
43 PR tree-optimization/95582
44 * c-attribs.c (c_common_attribute_table): Add entry for
45 signed_bool_precision.
46 (handle_signed_bool_precision_attribute): New.
47
8daa719b
GA
482020-12-24 Iain Sandoe <iain@sandoe.co.uk>
49
50 * c.opt: Add -stdlib= option and enumerations for
51 libstdc++ and libc++.
52
eefe499f
GA
532020-12-16 Martin Liska <mliska@suse.cz>
54
55 * c.opt: Remove usage of Report.
56
d52945ce
GA
572020-12-14 Martin Sebor <msebor@redhat.com>
58
59 PR middle-end/98166
60 PR c++/57111
61 PR middle-end/98160
62 * c-attribs.c (maybe_add_noinline): New function.
63 (handle_malloc_attribute): Call it. Use ATTR_FLAG_INTERNAL.
64 Implicitly add attribute noinline to functions not declared inline
65 and warn on those.
66
ca2bd949
GA
672020-12-09 Tobias Burnus <tobias@codesourcery.com>
68
69 * c-pragma.c (omp_pragmas): Add 'allocate'.
70 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ALLOCATE.
71
f6e8e279
GA
722020-12-08 Jakub Jelinek <jakub@redhat.com>
73
74 PR c++/98187
75 * c-pragma.c (omp_pragmas): Remove "master".
76 (omp_pragmas_simd): Add "master".
77
bc8a7013
GA
782020-12-07 Marek Polacek <polacek@redhat.com>
79
80 PR c++/98126
81 * c-common.c (verify_tree_lim_r): New function.
82 (verify_sequence_points): Use it. Use nullptr instead of 0.
83
b8dd0ef7
GA
842020-12-03 Martin Sebor <msebor@redhat.com>
85
86 PR c++/90629
87 PR middle-end/94527
88 * c-attribs.c (handle_dealloc_attribute): New function.
89 (handle_malloc_attribute): Handle argument forms of attribute.
90 * c.opt (-Wmismatched-dealloc): New option.
91 (-Wmismatched-new-delete): New option.
92
932020-12-03 Jakub Jelinek <jakub@redhat.com>
94
95 PR libstdc++/93121
96 * c-common.h (enum rid): Add RID_BUILTIN_BIT_CAST.
97 * c-common.c (c_common_reswords): Add __builtin_bit_cast.
98
e0f5e792
GA
992020-12-01 JeanHeyd Meneide <phdofthehouse@gmail.com>
100
101 * c-cppbuiltin.c (c_cpp_builtins): Add predefined
102 {__GNUC_EXECUTION_CHARSET_NAME} and
103 _WIDE_EXECUTION_CHARSET_NAME} macros.
104
1052020-12-01 Nathan Sidwell <nathan@acm.org>
106
107 * c-common.c (module, import, export): New internal tokens (with
108 trailing space).
109 * c-common.h (RID__MODULE, RID__IMPORT & RID__EXPORT): Enumerate
110 them.
111 (D_CXX_MODULES, D_CXX_MODULES_FLAGS): Enable them.
112 * c-cppbuiltin.c (c_cpp_builtins): Feature macro.
113
1142020-12-01 Nathan Sidwell <nathan@acm.org>
115
116 * c-opts.c (c_common_init_options): Ask for module dependencies.
117 (c_common_handle_option): Handle -Mmodules -Mno-modules.
118 * c-pch.c (c_common_valid_pch): ... does not play with C++
119 modules.
120 * c.opt (Mmodules, Mno-modules): New preprocessor dependency
121 options.
122 (fmodules-ts, fmodule-header, fmodule-implicit-inline)
123 (fmodule-only, fmodule-mapper, fmodule-lazy)
124 (fmodule-version-ignore, Winvalid-imported-macros)
125 (flang-info-include-translate, flang-info-include-translate-not):
126 New options
127
5fbf0ecb
GA
1282020-11-28 Eric Botcazou <ebotcazou@adacore.com>
129
130 * c-ada-spec.c (dump_nested_type) <RECORD_TYPE>: Remove obsolete code.
131 (dump_ada_structure): Also deal with convention, unchecked union and
132 bit-field for nested types. In the latter case, print an Alignment
133 aspect along with the Pack aspect.
134
360258da
GA
1352020-11-25 Martin Sebor <msebor@redhat.com>
136
137 PR bootstrap/94982
138 * c-attribs.c (handle_patchable_function_entry_attribute): Avoid
139 -Wformat-diag.
140
1e2c9a27
GA
1412020-11-24 Martin Sebor <msebor@redhat.com>
142
143 * c-warn.c (warn_parm_array_mismatch): Avoid invalid redeclarations.
144
8e6198d0
GA
1452020-11-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
146
147 * c-attribs.c (handle_special_var_sec_attribute): New.
148 (handle_noinit_attribute): Remove.
149 (attr_noinit_exclusions): Rename to...
150 (attr_section_exclusions): ...this, and add "persistent" attribute
151 exclusion.
152 (c_common_attribute_table): Add "persistent" attribute.
153
7a97e2fc
GA
1542020-11-21 Aaron Sawdey <acsawdey@linux.ibm.com>
155
156 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
157 Treat opaque types like other types.
158 (c_pretty_printer::direct_abstract_declarator): Opaque types are
159 supported types.
160
82e5048e
GA
1612020-11-20 Martin Sebor <msebor@redhat.com>
162
163 * c-warn.c (warn_parm_array_mismatch): Bail on invalid redeclarations
164 with fewer arguments.
165
1662020-11-20 Martin Sebor <msebor@redhat.com>
167
168 PR middle-end/97879
169 * c-attribs.c (handle_access_attribute): Handle ATTR_FLAG_INTERNAL.
170 Error out on invalid modes.
171
1722020-11-20 Jakub Jelinek <jakub@redhat.com>
173
174 PR libstdc++/88101
175 * c-common.c (check_builtin_function_arguments): Handle
176 BUILT_IN_CLEAR_PADDING.
177
25bb75f8
GA
1782020-11-18 Nathan Sidwell <nathan@acm.org>
179
180 * c-lex.c (c_lex_with_flags): CPP_HEADER_NAMEs can now be seen.
181
4dabb037
GA
1822020-11-17 Nathan Sidwell <nathan@acm.org>
183
184 * c-common.h (enum c_tree_index): Reorder to place lazy fields
185 after newly-added CTI_MODULE_HWM.
186
1872020-11-17 Joseph Myers <joseph@codesourcery.com>
188
189 * c-cppbuiltin.c (builtin_define_float_constants): Define
190 "*_IS_IEC_60559__" macros.
191
1922020-11-17 Nathan Sidwell <nathan@acm.org>
193
194 * c-lex.c: #include "langhooks.h".
195 (cb_undef): Maybe call preprocess_undef lang hook.
196 * c-opts.c (c_common_post_options): Maybe call preprocess_options
197 lang hook.
198 (push_command_line_include): Maybe call preprocess_main_file lang
199 hook.
200 (cb_file_change): Likewise.
201 * c-ppoutput.c: #include "langhooks.h.
202 (scan_translation_unit): Maybe call preprocess_token lang hook.
203 (class do_streamer): New, derive from token_streamer.
204 (directives_only_cb): Data pointer is do_streamer, call
205 preprocess_token lang hook.
206 (scan_translation_unit_directives_only): Use do_streamer.
207 (print_line_1): Move src_line recording to after string output.
208 (cb_undef): Maybe call preprocess_undef lang hook.
209
2102020-11-17 Nathan Sidwell <nathan@acm.org>
211
212 * c-ppoutput.c (scan_translation_unit): Use token_streamer, remove
213 code duplicating that functionality.
214
2152020-11-17 Jakub Jelinek <jakub@redhat.com>
216
217 PR c/90628
218 * c-common.c (check_builtin_function_arguments)
219 <case BUILT_IN_ADD_OVERFLOW>: Diagnose when last argument is pointer
220 to _Atomic. For the TYPE_READONLY case, adjust message to be usable
221 for more builtins and argument positions.
222
29c5d9ce
GA
2232020-11-16 Iain Sandoe <iain@sandoe.co.uk>
224
225 PR objc/97854
226 * stub-objc.c: Include c-common.h to declare enum rid.
227
77f67db2
GA
2282020-11-13 Jakub Jelinek <jakub@redhat.com>
229
230 PR c++/63287
231 * c-cppbuiltin.c: Include configargs.h.
232 (c_cpp_builtins): For C++11 and later if THREAD_MODEL_SPEC is not
233 defined, predefine __STDCPP_THREADS__ to 1 unless thread_model is
234 "single".
235
2362020-11-13 Gergö Barany <gergo@codesourcery.com>
237 Thomas Schwinge <thomas@codesourcery.com>
238
239 * c.opt (fopenacc-kernels): Add.
240
2412020-11-13 Jason Merrill <jason@redhat.com>
242
243 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_using_enum.
244
2452020-11-13 Piotr H. Dabrowski <phd@phd.re>
246
247 PR c++/91318
248 * c-cppbuiltin.c: c_cpp_builtins_optimize_pragma(): use cpp_define_unused()
249
2502020-11-13 Martin Liska <mliska@suse.cz>
251
252 * c-attribs.c (build_attr_access_from_parms): Format properly.
253
2542020-11-13 Iain Sandoe <iain@sandoe.co.uk>
255
256 PR objc/90707
257 * c-common.c (c_common_reswords): null_unspecified, nullable,
258 nonnull, null_resettable: New keywords.
259 * c-common.h (enum rid): RID_NULL_UNSPECIFIED, RID_NULLABLE,
260 RID_NONNULL, RID_NULL_RESETTABLE: New.
261 (OBJC_IS_PATTR_KEYWORD): Include nullability keywords in the
262 ranges accepted for property attributes.
263 * c-attribs.c (handle_objc_nullability_attribute): New.
264 * c-objc.h (enum objc_property_attribute_group): Add
265 OBJC_PROPATTR_GROUP_NULLABLE.
266 (enum objc_property_attribute_kind):Add
267 OBJC_PROPERTY_ATTR_NULL_UNSPECIFIED, OBJC_PROPERTY_ATTR_NULLABLE,
268 OBJC_PROPERTY_ATTR_NONNULL, OBJC_PROPERTY_ATTR_NULL_RESETTABLE.
269
2702020-11-13 Iain Sandoe <iain@sandoe.co.uk>
271
272 PR objc/77404
273 * c-attribs.c (handle_objc_root_class_attribute): New
274 * c-objc.h (objc_start_class_interface): Add a location
275 value for the position of the class name.
276 * c.opt: Add Wobjc-root-class.
277 * stub-objc.c (objc_start_class_interface): Add a location
278 value for the position of the class name.
279
a5a11525
GA
2802020-11-12 Joseph Myers <joseph@codesourcery.com>
281
282 * c-lex.c (c_common_has_attribute): Take argument std_syntax.
283 Allow scope for C. Handle standard attributes for C. Do not
284 accept unscoped attributes if std_syntax and not handled as
285 standard attributes.
286 * c-common.h (c_common_has_attribute): Update prototype.
287
2882020-11-12 Nicholas Guriev <guriev-ns@ya.ru>
289
290 PR pch/86674
291 * c-pch.c (c_common_valid_pch): Use cpp_warning with CPP_W_INVALID_PCH
292 reason to fix -Werror=invalid-pch and -Wno-error=invalid-pch switches.
293
0f5f9ed5
GA
2942020-11-11 Patrick Palka <ppalka@redhat.com>
295
296 PR c++/88115
297 * c-opts.c (c_common_post_options): Update latest_abi_version.
298
bb622641
GA
2992020-11-10 Jakub Jelinek <jakub@redhat.com>
300
301 PR c/97748
302 * c-common.h (warn_if_unused_value): Add quiet argument defaulted
303 to false.
304 * c-warn.c (warn_if_unused_value): Likewise. Pass it down
305 recursively and just return true instead of warning if it is true.
306 Handle COMPLEX_EXPR.
307
3082020-11-10 Chung-Lin Tang <cltang@codesourcery.com>
309
310 * c-common.h (c_omp_adjust_map_clauses): New declaration.
311 * c-omp.c (struct map_clause): Helper type for c_omp_adjust_map_clauses.
312 (c_omp_adjust_map_clauses): New function.
313
2bee28dd
GA
3142020-11-09 Marek Polacek <polacek@redhat.com>
315
316 DR 1914
317 * c-common.c (attribute_fallthrough_p): Tweak the warning
318 message.
319
3202020-11-09 Patrick Palka <ppalka@redhat.com>
321
322 * c-pragma.c (handle_pragma_diagnostic): Split the
323 unknown-option -Wpragmas diagnostic into a warning and a
324 subsequent note containing a spelling suggestion. Avoid
325 computing the suggestion if -Wpragmas warnings are being
326 suppressed.
327
3282020-11-09 Patrick Palka <ppalka@redhat.com>
329
330 PR testsuite/97117
331 * c-indentation.c (get_visual_column): Remove location_t
332 parameter. Move the column-tracking diagnostic code from here
333 to ...
334 (should_warn_for_misleading_indentation): ... here, before the
335 early exit for when the loci are not all distinct. Don't pass a
336 location_t argument to get_visual_column.
337 (assert_get_visual_column_succeeds): Don't pass a location_t
338 argument to get_visual_column.
339 (assert_get_visual_column_fails): Likewise.
340
fb95de7a
GA
3412020-11-08 Iain Sandoe <iain@sandoe.co.uk>
342
343 * c-common.h (OBJC_IS_PATTR_KEYWORD): Add class to the list
344 of keywords accepted in @property attribute contexts.
345 * c-objc.h (enum objc_property_attribute_group): Add
346 OBJC_PROPATTR_GROUP_CLASS.
347 (enum objc_property_attribute_kind): Add
348 OBJC_PROPERTY_ATTR_CLASS.
349
2da7ee05
GA
3502020-11-07 Iain Sandoe <iain@sandoe.co.uk>
351
352 * c-common.c (c_common_reswords): Add 'atomic' property
353 attribute.
354 * c-common.h (enum rid): Add RID_PROPATOMIC for atomic
355 property attributes.
356
3572020-11-07 Iain Sandoe <iain@sandoe.co.uk>
358
359 * c-attribs.c (handle_nsobject_attribute): New.
360 * c.opt: Add WNSObject-attribute.
361
44cab2d8
GA
3622020-11-06 Iain Sandoe <iain@sandoe.co.uk>
363
364 * c-objc.h (enum objc_property_attribute_group): New
365 (enum objc_property_attribute_kind): New.
366 (OBJC_PROPATTR_GROUP_MASK): New.
367 (struct property_attribute_info): Small class encapsulating
368 parser output from property attributes.
369 (objc_prop_attr_kind_for_rid): New
370 (objc_add_property_declaration): Simplify interface.
371 * stub-objc.c (enum rid): Dummy type.
372 (objc_add_property_declaration): Simplify interface.
373 (objc_prop_attr_kind_for_rid): New.
374
3752020-11-06 Nathan Sidwell <nathan@acm.org>
376
377 * c-ada-spec.c (collect_ada_nodes): Rename
378 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
379 (collect_ada_node): Likewise.
380 (dump_forward_type): Likewise.
381 * c-common.c (set_underlying_type): Rename
382 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
383 (user_facing_original_type, c_common_finalize_early_debug): Likewise.
384
3852020-11-06 Jakub Jelinek <jakub@redhat.com>
386
387 * c-common.c (verify_sequence_points): Remove DEBUG_FUNCTION.
388
0cfd9109
GA
3892020-11-05 Marek Polacek <polacek@redhat.com>
390
391 PR c++/97675
392 * c.opt (Wexceptions): New option.
393
3942020-11-05 Marek Polacek <polacek@redhat.com>
395
396 PR c++/25814
397 * c.opt (Wvexing-parse): New option.
398
35c125cb
GA
3992020-11-04 Jakub Jelinek <jakub@redhat.com>
400
401 PR c++/97670
402 * c-omp.c (c_omp_split_clauses): Look through array reductions to find
403 underlying decl to clear in the allocate_head bitmap.
404
4052020-11-04 Iain Sandoe <iain@sandoe.co.uk>
406
407 * c-objc.h (objc_non_constant_expr_p): New.
408 * stub-objc.c (objc_non_constant_expr_p): New.
409
fd2325ea
GA
4102020-11-03 Nathan Sidwell <nathan@acm.org>
411
412 * c.opt (MQ,MT): Reword description to be make-agnostic.
413
88ce3d5f
GA
4142020-11-02 Nathan Sidwell <nathan@acm.org>
415
416 * c-opts.c (c_common_post_options): Move var decl to its
417 initialization point.
418
4192020-11-01 Iain Sandoe <iain@sandoe.co.uk>
420
421 * c-lex.c (c_lex_with_flags): When combining '@' with a
422 keyword for Objective-C, combine the location ranges too.
423
4242020-10-30 Qing Zhao <qing.zhao@oracle.com>
425 H.J.Lu <hjl.tools@gmail.com>
426
427 * c-attribs.c (c_common_attribute_table): Add new attribute
428 zero_call_used_regs.
429 (handle_zero_call_used_regs_attribute): New function.
430
e93aae4a
GA
4312020-10-28 Marek Polacek <polacek@redhat.com>
432
433 PR c++/97573
434 * c-opts.c (c_common_post_options): In C++20, turn on
435 -Wdeprecated-enum-enum-conversion and
436 -Wdeprecated-enum-float-conversion.
437 * c.opt (Wdeprecated-enum-enum-conversion,
438 Wdeprecated-enum-float-conversion): New options.
439 (Wenum-conversion): Allow for C++ too.
440
4412020-10-28 Jakub Jelinek <jakub@redhat.com>
442
443 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALLOCATE.
444 * c-omp.c: Include bitmap.h.
445 (c_omp_split_clauses): Handle OMP_CLAUSE_ALLOCATE.
446
f19e7c8d
GA
4472020-10-26 Ville Voutilainen <ville.voutilainen@gmail.com>
448
449 * c-common.c (__is_nothrow_assignable): New.
450 (__is_nothrow_constructible): Likewise.
451 * c-common.h (RID_IS_NOTHROW_ASSIGNABLE): New.
452 (RID_IS_NOTHROW_CONSTRUCTIBLE): Likewise.
453
efe71fcc
GA
4542020-10-23 Jan Hubicka <hubicka@ucw.cz>
455
456 * c-common.c (c_common_finalize_early_debug): Update for new thunk api.
457
4582020-10-23 Marek Polacek <polacek@redhat.com>
459
460 PR c++/91741
461 * c-common.c (verify_tree): Handle PAREN_SIZEOF_EXPR.
462 (c_common_init_ts): Likewise.
463 * c-common.def (PAREN_SIZEOF_EXPR): New tree code.
464 * c-common.h (maybe_warn_sizeof_array_div): Declare.
465 * c-warn.c (sizeof_pointer_memaccess_warning): Unwrap NOP_EXPRs.
466 (maybe_warn_sizeof_array_div): New function.
467 * c.opt (Wsizeof-array-div): New option.
468
4692020-10-23 Martin Sebor <msebor@redhat.com>
470
471 PR c/97463
472 * c-warn.c (warn_parm_ptrarray_mismatch): Move null test earlier.
473
56ddd5e2
GA
4742020-10-22 Martin Liska <mliska@suse.cz>
475
476 PR c/94722
477 * c-attribs.c (handle_no_stack_protect_function_attribute): New.
478 (handle_stack_protect_attribute): Add error message for a
479 no_stack_protector function.
480
4812020-10-22 Martin Liska <mliska@suse.cz>
482
483 * c-cppbuiltin.c (c_cpp_builtins): Use the stack_protector enum.
484
4852020-10-22 Jan Hubicka <hubicka@ucw.cz>
486
487 * c-gimplify.c: Include tree-nested.h
488 (c_genericize): Update for new nested function info.
489
b2698c21
GA
4902020-10-14 Martin Sebor <msebor@redhat.com>
491
492 PR c/97413
493 * c-attribs.c (build_attr_access_from_parms): Wrap chain of VLA
494 bounds in an extra list.
495
7e9282ae
GA
4962020-10-05 Richard Biener <rguenther@suse.de>
497 Jakub Jelinek <jakub@redhat.com>
498
499 PR c++/97197
500 * c-pretty-print.c: Include langhooks.h.
501 (c_pretty_printer::postfix_expression): Handle TARGET_MEM_REF as
502 expression.
503 (c_pretty_printer::expression): Handle TARGET_MEM_REF as
504 unary_expression.
505 (c_pretty_printer::unary_expression): Handle TARGET_MEM_REF.
506
660bfe61
GA
5072020-09-30 Martin Sebor <msebor@redhat.com>
508
509 PR middle-end/97189
510 * c-attribs.c (append_access_attr): Use the function declaration
511 location for a warning about an attribute access argument.
512
93bca37c
GA
5132020-09-29 Marek Polacek <polacek@redhat.com>
514
515 PR c++/94695
516 * c.opt (Wrange-loop-construct): New option.
517
82b77dee
GA
5182020-09-23 Martin Sebor <msebor@redhat.com>
519
520 PR c/97131
521 * c-warn.c (warn_parm_ptrarray_mismatch): Handle more invalid input.
522
5232020-09-23 Marek Polacek <polacek@redhat.com>
524
525 PR c/97125
526 * c-gimplify.c (c_genericize): Only call do_warn_duplicated_branches_r
527 after loops and other structured control constructs have been lowered.
528
521d2711
GA
5292020-09-22 Jakub Jelinek <jakub@redhat.com>
530
531 * c.opt (Wbuiltin-declaration-mismatch): Fix typo in variable name:
532 warn_builtin_declaraion_mismatch -> warn_builtin_declaration_mismatch.
533
44135373
GA
5342020-09-21 Marek Polacek <polacek@redhat.com>
535
536 * c.opt (Wctad-maybe-unsupported): New option.
537
2fe5b7d1
GA
5382020-09-19 Martin Sebor <msebor@redhat.com>
539
540 PR c/50584
541 * c-common.h (warn_parm_array_mismatch): Declare new function.
542 (has_attribute): Move declaration of an existing function.
543 (build_attr_access_from_parms): Declare new function.
544 * c-warn.c (parm_array_as_string): Define new function.
545 (plus_one): Define new function.
546 (warn_parm_ptrarray_mismatch): Define new function.
547 (warn_parm_array_mismatch): Define new function.
548 (vla_bound_parm_decl): New function.
549 * c.opt (-Warray-parameter, -Wvla-parameter): New options.
550 * c-pretty-print.c (pp_c_type_qualifier_list): Don't print array type
551 qualifiers here...
552 (c_pretty_printer::direct_abstract_declarator): ...but instead print
553 them in brackets here. Also print [static]. Strip extraneous
554 expressions from VLA bounds.
555
5562020-09-19 Martin Sebor <msebor@redhat.com>
557
558 PR c/50584
559 * c-attribs.c (c_common_attribute_table): Add "arg spec" attribute.
560 (handle_argspec_attribute): New function.
561 (get_argument, get_argument_type): New functions.
562 (append_access_attrs): Add overload. Handle internal attribute
563 representation in addition to external.
564 (handle_access_attribute): Handle internal attribute representation
565 in addition to external.
566 (build_attr_access_from_parms): New function.
567
5682020-09-19 Sandra Loosemore <sandra@codesourcery.com>
569
570 * c-gimplify.c (genericize_c_loop): Rewrite to match
571 c_finish_loop in c-typeck.c.
572
5732020-09-19 Sandra Loosemore <sandra@codesourcery.com>
574
575 * c-common.c (c_block_may_fallthrough): New, split from
576 cxx_block_may_fallthrough in the cp front end.
577 (c_common_init_ts): Move handling of loop and switch-related
578 statements here from the cp front end.
579 * c-common.def (FOR_STMT, WHILE_STMT, DO_STMT): Move here from
580 cp front end.
581 (BREAK_STMT, CONTINUE_STMT, SWITCH_STMT): Likewise.
582 * c-common.h (c_block_may_fallthru): Declare.
583 (bc_state_t): Move here from cp front end.
584 (save_bc_state, restore_bc_state): Declare.
585 (c_genericize_control_stmt): Declare.
586 (WHILE_COND, WHILE_BODY): Likewise.
587 (DO_COND, DO_BODY): Likewise.
588 (FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY, FOR_SCOPE): Likewise.
589 (SWITCH_STMT_COND, SWITCH_STMT_BODY): Likewise.
590 (SWITCH_STMT_TYPE, SWITCH_STMT_SCOPE): Likewise.
591 (SWITCH_STMT_ALL_CASES_P, SWITCH_STMT_NO_BREAK_P): Likewise.
592 (LABEL_DECL_BREAK, LABEL_DECL_CONTINUE): Likewise.
593 * c-dump.c (dump_stmt): Copy from cp front end.
594 (c_dump_tree): Move code to handle structured loop and switch
595 tree nodes here from cp front end.
596 * c-gimplify.c: Adjust includes.
597 (enum bc_t, bc_label, begin_bc_block, finish_bc_block): Move from
598 cp front end.
599 (save_bc_state, restore_bc_state): New functions using old code
600 from cp front end.
601 (get_bc_label, expr_loc_or_loc): Move from cp front end.
602 (genericize_c_loop): Move from cp front end.
603 (genericize_for_stmt, genericize_while_stmt): Likewise.
604 (genericize_do_stmt, genericize_switch_stmt): Likewise.
605 (genericize_continue_stmt, genericize_break_stmt): Likewise.
606 (genericize_omp_for_stmt): Likewise.
607 (c_genericize_control_stmt): New function using code split from
608 cp front end.
609 (c_genericize_control_r): New.
610 (c_genericize): Call walk_tree with c_genericize_control_r.
611 * c-pretty-print.c (c_pretty_printer::statement): Move code to handle
612 structured loop and switch tree nodes here from cp front end.
613
2aad20c0
GA
6142020-09-17 Patrick Palka <ppalka@redhat.com>
615
616 PR c/80076
617 * c-indentation.c (should_warn_for_misleading_indentation): Move
618 declarations of local variables closer to their first use.
619 Handle virtual token locations by resolving them to their
620 respective macro expansion points. If all three tokens are
621 produced from the same macro expansion, then instead use their
622 loci within the macro definition.
623
ecde1b0a
GA
6242020-09-16 Martin Sebor <msebor@redhat.com>
625
626 PR c/78666
627 PR c/96126
628 * c-attribs.c (validate_attr_args): New function.
629 (validate_attr_arg): Same.
630 (handle_section_attribute): Call it. Introduce a local variable.
631 (handle_alloc_size_attribute): Same.
632 (handle_alloc_align_attribute): Same.
633
50a71cd0
GA
6342020-09-14 Jakub Jelinek <jakub@redhat.com>
635
636 * c-attribs.c (handle_optimize_attribute): Adjust
637 cl_optimization_save, cl_optimization_restore and
638 build_optimization_node callers.
639 * c-pragma.c (handle_pragma_optimize): Adjust
640 build_optimization_node caller.
641 (handle_pragma_push_options): Adjust
642 build_optimization_node and build_target_option_node callers.
643 (handle_pragma_pop_options, handle_pragma_reset_options):
644 Adjust cl_optimization_restore callers.
645
8f7ea26a
GA
6462020-08-28 Martin Sebor <msebor@redhat.com>
647
648 * c.opt (Wstringop-overread): New option.
649
a6493809
GA
6502020-08-11 Jakub Jelinek <jakub@redhat.com>
651
652 PR c/96545
653 * c-common.c (get_atomic_generic_size): Require that first argument's
654 type points to a complete type and use tree_fits_uhwi_p instead of
655 just INTEGER_CST TREE_CODE check for the TYPE_SIZE_UNIT.
656
48cc2e46
GA
6572020-07-31 Martin Sebor <msebor@redhat.com>
658
659 PR c++/96003
660 * c-common.c (check_function_arguments_recurse): Return early when
661 no-warning bit is set.
662
6632020-07-31 Richard Biener <rguenther@suse.de>
664
665 PR debug/96383
666 * c-common.h (c_common_finalize_early_debug): Declare.
667 * c-common.c: Include debug.h.
668 (c_common_finalize_early_debug): finalize_early_debug langhook
669 implementation generating debug for extern declarations.
670
e71dab87
GA
6712020-07-27 Nathan Sidwell <nathan@acm.org>
672
673 * c-common.c (try_to_locate_new_include_insertion_point): Use
674 strcmp, not pointer equality.
675
ae2e0bc1
GA
6762020-07-25 Martin Sebor <msebor@redhat.com>
677
678 PR c++/96310
679 * c-common.c (check_nonnull_arg): Print note only when warning was
680 issued.
681
3ea9abca
GA
6822020-07-22 Tobias Burnus <tobias@codesourcery.com>
683
684 * c-omp.c (c_finish_omp_critical): Check for no name but
685 nonzero hint provided.
686
0933f508
GA
6872020-07-20 Jason Merrill <jason@redhat.com>
688
689 * c-cppbuiltin.c (c_cpp_builtins): Update
690 __cpp_nontype_template_args for C++20.
691
6922020-07-20 Martin Sebor <msebor@redhat.com>
693
694 PR c/96249
695 * c.opt: Remove stray text.
696
8ca07a30
GA
6972020-07-14 Lewis Hyatt <lhyatt@gmail.com>
698
699 PR other/86904
700 * c-indentation.c (should_warn_for_misleading_indentation): Get
701 global tabstop from the new source.
702 * c-opts.c (c_common_handle_option): Remove handling of -ftabstop, which
703 is now a common option.
704 * c.opt: Likewise.
705
a82c4c4c 7062020-07-08 Eric Botcazou <ebotcazou@adacore.com>
50873cc5
GA
707
708 * c.opt (Wscalar-storage-order): Add explicit variable.
709
f60ee68d
GA
7102020-07-07 Nathan Sidwell <nathan@acm.org>
711
712 * c-opts.c (c_common_post_options): Add 'injecting' arg to
713 cpp_read_main_file.
714 (c_finish_options): Add linemap_line_start calls for builtin and cmd
715 maps. Force token position to line_table's highest line.
716 * c-ppoutput.c (print_line_1): Refactor, print line zero.
717 (cb_define): Always increment source line.
718
4077d74c
GA
7192020-07-06 Martin Sebor <msebor@redhat.com>
720
721 PR c++/95984
722 * c-common.c (check_function_nonnull): Avoid checking syntesized calls
723 to stub lambda objects with null this pointer.
724 (check_nonnull_arg): Handle C++ nullptr.
725
b5f24739
GA
7262020-07-02 Jason Merrill <jason@redhat.com>
727 Jakub Jelinek <jakub@redhat.com>
728
729 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_consteval.
730
46fbb6c6
GA
7312020-06-30 Jakub Jelinek <jakub@redhat.com>
732
733 PR c++/95963
734 * c-common.c (check_function_arguments_recurse): Don't crash on
735 calls to internal functions.
736
69273534
GA
7372020-06-28 Martin Sebor <msebor@redhat.com>
738
739 PR c++/86568
740 * c-common.c (struct nonnull_arg_ctx): Add members.
741 (check_function_nonnull): Use nonnull_arg_ctx as argument. Handle
742 C++ member functions specially. Consider the this pointer implicitly
743 nonnull.
744 (check_nonnull_arg): Use location of argument when available.
745 (check_function_arguments): Use nonnull_arg_ctx as argument.
746
9a33c41f
GA
7472020-06-27 Jakub Jelinek <jakub@redhat.com>
748
749 PR middle-end/95903
750 * c-common.c (pointer_int_sum): Use TYPE_OVERFLOW_UNDEFINED instead of
751 !TYPE_UNSIGNED check to see if we can apply distributive law and handle
752 smaller precision intop operands separately.
753
c9c05f73
GA
7542020-06-26 Marek Polacek <polacek@redhat.com>
755
756 * c-opts.c (c_common_init_options): Default to gnu++17.
757
aff95ee7
GA
7582020-06-17 Jonathan Wakely <jwakely@redhat.com>
759
bd0a89dc 760 PR c/95378
aff95ee7
GA
761 * c-common.c (get_atomic_generic_size): Check cv-qualifiers in
762 pointer arguments.
763
56638b9b
GA
7642020-06-16 Jakub Jelinek <jakub@redhat.com>
765
766 * c-common.h (c_omp_check_loop_iv_exprs): Add an int argument.
767 * c-omp.c (struct c_omp_check_loop_iv_data): Add maybe_nonrect and
768 idx members.
769 (c_omp_is_loop_iterator): New function.
770 (c_omp_check_loop_iv_r): Use it. Add support for silent scanning
771 if outer loop iterator is present. Perform duplicate checking through
772 hash_set in the function rather than expecting caller to do that.
773 Pass NULL instead of d->ppset to walk_tree_1.
774 (c_omp_check_nonrect_loop_iv): New function.
775 (c_omp_check_loop_iv): Use it. Fill in new members, allow
776 non-rectangular loop forms, diagnose multiple associated loops with
777 the same iterator. Pass NULL instead of &pset to walk_tree_1.
778 (c_omp_check_loop_iv_exprs): Likewise.
779
ec6ffbb9
GA
7802020-06-10 Martin Liska <mliska@suse.cz>
781
782 PR tree-optimization/92860
783 * c-attribs.c (handle_optimize_attribute):
784 Save global options and compare it after parsing of function
785 attribute.
786 * c-pragma.c (opt_stack::saved_global_options): New field.
787 (handle_pragma_push_options): Save global_options.
788 (handle_pragma_pop_options): Compare them after pop.
789
b952c2cf
GA
7902020-06-09 Jakub Jelinek <jakub@redhat.com>
791
792 PR c/95580
793 * c-pretty-print.c (c_pretty_printer::unary_expression): Handle the
794 case when MEM_REF's first argument has type pointer to incomplete type.
795
1a59f3db
GA
7962020-06-05 Jason Merrill <jason@redhat.com>
797
798 * c-pretty-print.c (pp_c_additive_expression): Handle negative
799 operand to POINTER_PLUS_EXPR.
800
3add3425
GA
8012020-06-04 Martin Sebor <msebor@redhat.com>
802
803 PR middle-end/10138
804 PR middle-end/95136
805 * c-attribs.c (append_access_attrs): Handle attr_access::none.
806 (handle_access_attribute): Same.
807
9a5b7438
GA
8082020-06-03 Mark Wielaard <mark@klomp.org>
809
810 * known-headers.cc (get_cp_stdlib_header_for_string_macro_name):
811 New function.
812 * known-headers.h (get_cp_stdlib_header_for_string_macro_name):
813 New function declaration.
814
8152020-06-03 Mark Wielaard <mark@klomp.org>
816
817 * known-headers.cc (get_string_macro_hint): New function.
818 (get_stdlib_header_for_name): Use get_string_macro_hint.
819 (get_c_stdlib_header_for_string_macro_name): New function.
820 * known-headers.h (get_c_stdlib_header_for_string_macro_name):
821 New function declaration.
822
8232020-06-03 Tobias Burnus <tobias@codesourcery.com>
824
825 * c-common.h (c_omp_predetermined_mapping): Declare.
826 * c-omp.c (c_omp_predetermined_mapping): New.
827
af114c38
MW
8282020-05-22 Mark Wielaard <mark@klomp.org>
829
830 * known-headers.cc (get_stdlib_header_for_name): Add a new
831 stdlib_hint array for stdbool and stdint.
832
45c50b6a
MW
8332020-05-22 Mark Wielaard <mark@klomp.org>
834
835 * known-headers.cc (get_stdlib_header_for_name): Return
836 "<stdbool.h>" for "bool", "true" or "false" when STDLIB_C and
837 flag_isoc99.
838
c22027a0
NS
8392020-05-20 Nathan Sidwell <nathan@acm.org>
840
38a4db21
NS
841 * c-common.c (try_to_locate_new_include_insertion_point): Revert change.
842
c22027a0
NS
843 * c-common.c (try_to_locate_new_include_insertion_point): Use
844 strcmp to compare filenames.
845 * c-lex.c (init_c_lex): Move declaration to initialization.
846 * c-opts.c (handle_deferred_opts): Move cpp_get_deps call into
847 deferred count loop.
848
29f0e90d
JM
8492020-05-15 Jason Merrill <jason@redhat.com>
850
851 * c-opts.c (set_std_cxx20): Set flag_coroutines.
852
b04445d4
JM
8532020-05-13 Jason Merrill <jason@redhat.com>
854
855 * c.opt (std=c++20): Make c++2a the alias.
856 (std=gnu++20): Likewise.
857 * c-common.h (cxx_dialect): Change cxx2a to cxx20.
858 * c-opts.c: Adjust.
859 * c-cppbuiltin.c: Adjust.
860 * c-ubsan.c: Adjust.
861 * c-warn.c: Adjust.
862
11dd3be5
EB
8632020-05-12 Eric Botcazou <ebotcazou@adacore.com>
864
865 * c-ada-spec.c (dump_ads): Output pragma Warnings ("U"); on entry.
866
b224c376
NS
8672020-05-08 Nathan Sidwell <nathan@acm.org>
868
869 Reimplement directives only processing.
870 * c-ppoutput.c (token_streamer): Ne.
871 (directives_only_cb): New. Swallow ...
872 (print_lines_directives_only): ... this.
873 (scan_translation_unit_directives_only): Reimplment using the
874 published interface.
875
f1d94677
MP
8762020-05-07 Marek Polacek <polacek@redhat.com>
877
878 * c-format.c (badwords): Add "nonstatic".
879
9b95bb52
JJ
880202-05-07 Jakub Jelinek <jakub@redhat.com>
881
882 PR c/94968
883 * c-common.c (speculation_safe_value_resolve_params): Return false if
884 error_operand_p (val2).
885 (resolve_overloaded_builtin) <case BUILT_IN_SPECULATION_SAFE_VALUE_N>:
886 Remove extraneous semicolon.
887
530b4409 8882020-05-06 qing zhao <qing.zhao@oracle.com>
889
890 PR c/94230
891 * c-indentation.c (get_visual_column): Add a hint to use the new
892 -flarge-source-files option.
893
b776bdca
SSF
8942020-05-05 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
895
896 * c-attribs.c (handle_vector_size_attribute): Add attribute
897 nonnull for argument args in order to silence warning of
898 uninitialized variable usage. Since this is local to the
899 compilation unit and thus cannot be checked at call sides by the
900 compiler, added an assert statement in order to verify this.
901
6607bdd9
L
9022020-05-01 H.J. Lu <hongjiu.lu@intel.com>
903
904 PR target/93492
905 * c-attribs.c (handle_patchable_function_entry_attribute): Limit
906 value to USHRT_MAX (65535).
907
691eeb65
JJ
9082020-04-29 Jakub Jelinek <jakub@redhat.com>
909
910 * c-format.c (PP_FORMAT_CHAR_TABLE): Add %{ and %}.
911
26d76be7
JJ
9122020-04-27 Jakub Jelinek <jakub@redhat.com>
913
914 PR c/94755
915 * c-common.c (resolve_overloaded_builtin): Return error_mark_node for
916 fncode == BUILT_IN_NONE before initialization of first_param.
917
7291b2ed
MP
9182020-04-23 Marek Polacek <polacek@redhat.com>
919
920 PR c++/94733
921 * c-attribs.c (find_tm_attribute): Use get_attribute_name instead of
922 TREE_PURPOSE.
923
58a29af8
PP
9242020-04-14 Patrick Palka <ppalka@redhat.com>
925
926 PR c++/85278
927 * c-pretty-print.c (pp_c_pointer) <case REFERENCE_TYPE>: Print a double
928 ampersand if it's an rvalue reference type.
929
09f04139
MS
9302020-04-13 Martin Sebor <msebor@redhat.com>
931
932 PR c/92326
933 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator): Avoid
934 printing array bound for flexible array members.
935
ee26baf4
IS
9362020-04-13 Iain Sandoe <iain@sandoe.co.uk>
937
938 * c-cppbuiltin.c (c_cpp_builtins): Update coroutines builtin
939 define, per n4861.
940
75efe9cb
RB
9412020-04-02 Richard Biener <rguenther@suse.de>
942
943 PR c/94392
944 * c-opts.c (c_common_post_options): Enable -ffinite-loops
945 for -O2 and C++11 or newer.
946
75defde9
PP
9472020-03-28 Patrick Palka <ppalka@redhat.com>
948
949 * c.opt: Add -fconcepts-diagnostics-depth.
950
52f24a9e
MS
9512020-03-27 Martin Sebor <msebor@redhat.com>
952
953 PR c++/94346
954 * c-attribs.c (handle_copy_attribute): Avoid passing expressions
955 to decl_attributes. Make handling of different kinds of entities
956 more robust.
957
ccacf77b
MS
9582020-03-27 Martin Sebor <msebor@redhat.com>
959
960 PR c++/94098
961 * c-attribs.c (handle_access_attribute): Avoid setting TYPE_ATTRIBUTES
962 here.
963
ca6c7225
JJ
9642020-03-23 Jakub Jelinek <jakub@redhat.com>
965
966 PR c++/91993
967 * c-warn.c (warnings_for_convert_and_check): For expr and/or
968 result being COMPOUND_EXPRs, skip to ultimate rhs.
969
1aa22b19
RS
9702020-03-20 Richard Sandiford <richard.sandiford@arm.com>
971
972 PR middle-end/94072
973 * c-common.c (c_common_type_for_mode): Before using a registered
974 built-in type, check that the vectorness of the type matches
975 the vectorness of the mode.
976
700d4cb0
JJ
9772020-03-17 Jakub Jelinek <jakub@redhat.com>
978
979 * c-common.c (resolve_overloaded_builtin): Fix up duplicated word
980 issue in a diagnostic message.
981
b408e010
LH
9822020-03-15 Lewis Hyatt <lhyatt@gmail.com>
983
984 * c.opt: Avoid redundancy in the help text.
985
e78e50d5
MP
9862020-03-02 Marek Polacek <polacek@redhat.com>
987
988 PR c++/93958 - add missing -std=gnu++20.
989 * c.opt: Add -std=gnu++20.
990
649e1741
MS
9912020-03-01 Martin Sebor <msebor@redhat.com>
992
993 PR c++/92721
994 * c-attribs.c (append_access_attrs): Correctly handle attribute.
995 (handle_access_attribute): Same.
996
7b60f3ba
JJ
9972020-02-25 Jakub Jelinek <jakub@redhat.com>
998
999 PR c/93858
1000 * c-pragma.c (handle_pragma_diagnostic): Add missing ? after
1001 "did you mean" hint in diagnostics.
1002
fb260504
JM
10032020-02-15 Jason Merrill <jason@redhat.com>
1004
1005 * c.opt: Add -std=c++20.
1006
1d757b09
EB
10072020-02-14 Eric Botcazou <ebotcazou@adacore.com>
1008
1009 * c-ada-spec.c: Include bitmap.h.
1010 (dump_ada_double_name): Rename into...
1011 (dump_anonymous_type_name): ...this. Always use the TYPE_UID.
1012 (dump_ada_array_type): Adjust to above renaming. Robustify.
1013 (dump_nested_types_1): New function copied from... Add dumped_types
1014 parameter and pass it down to dump_nested_type.
1015 (dump_nested_types): ...this. Remove parent parameter. Just call
1016 dump_nested_types_1 on an automatic bitmap.
1017 (dump_nested_type): Add dumped_types parameter.
1018 <ARRAY_TYPE>: Do not dump it if already present in dumped_types.
1019 Adjust recursive calls and adjust to above renaming.
1020 (dump_ada_declaration): Adjust call to dump_nested_types.
1021 Tidy up and adjust to above renaming.
1022 (dump_ada_specs): Initialize and release bitmap obstack.
1023
0cc575e4
MS
10242020-02-10 Martin Sebor <msebor@redhat.com>
1025
1026 PR c/93640
1027 * c-attribs.c (handle_access_attribute): Correct off-by-one mistakes.
1028
a59aa302
JJ
10292020-02-10 Jakub Jelinek <jakub@redhat.com>
1030
1031 PR other/93641
1032 * c-format.c (check_plain): Fix up last argument of strncasecmp.
1033 Remove useless extra test.
1034
e464fc90
TB
10352020-02-03 Julian Brown <julian@codesourcery.com>
1036 Tobias Burnus <tobias@codesourcery.com>
1037
1038 * c-cppbuiltin.c (c_cpp_builtins): Update _OPENACC define to 201711.
1039
e3b6c052
JM
10402020-01-29 Jason Merrill <jason@redhat.com>
1041
1042 PR c++/89357
1043 * c-attribs.c (check_cxx_fundamental_alignment_constraints): Remove.
1044
6d00f052
JM
10452020-01-23 Jason Merrill <jason@redhat.com>
1046
1047 * c-warn.c (conversion_warning): Change -Wsign-conversion handling.
1048
8a990ffa
MS
10492020-01-23 Martin Sebor <msebor@redhat.com>
1050
1051 PR c/84919
1052 * c-common.c (check_function_arguments): Avoid overlap checking
1053 of sprintf functions.
1054
55b7df8b
JM
10552020-01-22 Jason Merrill <jason@redhat.com>
1056
1057 PR testsuite/93391 - PR 40752 test fails with unsigned plain char.
1058 PR c++/40752
1059 * c-warn.c (conversion_warning): Check operands only after checking
1060 the whole expression. Don't check second operand of + for sign.
1061
c77074d0
JM
10622020-01-21 Jason Merrill <jason@redhat.com>
1063 Manuel López-Ibáñez <manu@gcc.gnu.org>
1064
1065 PR c++/40752 - useless -Wconversion with short +=.
1066 * c.opt (-Warith-conversion): New.
1067 * c-warn.c (conversion_warning): Recurse for operands of
1068 operators. Only warn about the whole expression with
1069 -Warith-conversion.
1070
731dbfc3
JM
10712020-01-21 Jason Merrill <jason@redhat.com>
1072
1073 * c-common.c (unsafe_conversion_p): Don't warn, return UNSAFE_SIGN.
1074 * c-warn.c (conversion_warning): Warn about UNSAFE_SIGN.
1075
ad1a3914
NS
10762020-01-20 Nathan Sidwell <nathan@acm.org>
1077
1078 PR preprocessor/80005
1079 * c-cppbuiltins.c (c_cpp_builtins): Don't define __has_include{,_next}.
1080
49789fd0
IS
10812020-01-18 Iain Sandoe <iain@sandoe.co.uk>
1082
1083 * c-common.c (co_await, co_yield, co_return): New.
1084 * c-common.h (RID_CO_AWAIT, RID_CO_YIELD,
1085 RID_CO_RETURN): New enumeration values.
1086 (D_CXX_COROUTINES): Bit to identify coroutines are active.
1087 (D_CXX_COROUTINES_FLAGS): Guard for coroutine keywords.
1088 * c-cppbuiltin.c (__cpp_coroutines): New cpp define.
1089 * c.opt (fcoroutines): New command-line switch.
1090
4bc1899b
DM
10912020-01-10 David Malcolm <dmalcolm@redhat.com>
1092
1093 * c-format.c (local_event_ptr_node): New.
1094 (PP_FORMAT_CHAR_TABLE): Add entry for "%@".
1095 (init_dynamic_diag_info): Initialize local_event_ptr_node.
1096 * c-format.h (T_EVENT_PTR): New define.
1097
f25e33fa
MS
10982020-01-10 Martin Sebor <msebor@redhat.com>
1099
1100 PR c/93132
1101 * c-attribs.c (append_access_attrs): Validate against the translated
1102 access string rather than the human-readable representation.
1103
8d9254fc
JJ
11042020-01-01 Jakub Jelinek <jakub@redhat.com>
1105
1106 Update copyright years.
1107
39292e25
EB
11082019-12-20 Eric Botcazou <ebotcazou@adacore.com>
1109
1110 * c-ada-spec.h (decl_sloc): Delete.
1111 * c-ada-spec.c (decl_sloc): Make static.
1112
519d7496
JB
11132019-12-19 Julian Brown <julian@codesourcery.com>
1114
1115 * c-common.h (c_omp_map_clause_name): Add prototype.
1116 * c-omp.c (c_omp_map_clause_name): New function.
1117 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ATTACH and
1118 PRAGMA_OACC_CLAUSE_DETACH.
1119
a6163563
JB
11202019-12-19 Julian Brown <julian@codesourcery.com>
1121 Maciej W. Rozycki <macro@codesourcery.com>
1122 Tobias Burnus <tobias@codesourcery.com>
1123 Thomas Schwinge <thomas@codesourcery.com>
1124
1125 * c-pragma.h (pragma_omp_clause): Add
1126 PRAGMA_OACC_CLAUSE_NO_CREATE.
1127
e8f1ade2
MS
11282019-12-17 Martin Sebor <msebor@redhat.com>
1129
1130 PR c++/61339
1131 * c.opt (-Wmismatched-tags, -Wredundant-tags): New options.
1132
368877a1
DM
11332019-12-11 David Malcolm <dmalcolm@redhat.com>
1134
1135 * c-pretty-print.c (c_pretty_printer::clone): New vfunc
1136 implementation.
1137 * c-pretty-print.h (c_pretty_printer::clone): New vfunc decl.
1138
d68f5d45
DM
11392019-12-09 David Malcolm <dmalcolm@redhat.com>
1140
1141 * c-format.c (range_label_for_format_type_mismatch::get_text):
1142 Replace label_text ctor called with true with label_text::take.
1143
d3e28653
DM
11442019-12-09 David Malcolm <dmalcolm@redhat.com>
1145
1146 * c-format.c (selftest::test_type_mismatch_range_labels): Remove
1147 initial newline from expected outputs.
1148 * c-opts.c (c_diagnostic_finalizer): Add pp_newline call before
1149 call to diagnostic_show_locus.
1150
abd6d8cc
JJ
11512019-12-06 Jakub Jelinek <jakub@redhat.com>
1152
1153 * c-cppbuiltin.c (c_cpp_builtins): Don't define __cpp_consteval for
1154 now.
1155
7906797e
MP
11562019-12-05 Marek Polacek <polacek@redhat.com>
1157 Jakub Jelinek <jakub@redhat.com>
1158
1159 PR c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.
1160 * c-cppbuiltin.c (c_cpp_builtins): Adjust the value of __cpp_constexpr.
1161
5c04da88
MP
11622019-12-05 Marek Polacek <polacek@redhat.com>
1163
1164 PR c++/92271 - make __is_same alias for __is_same_as.
1165 * c-common.c: Add __is_same, an alias for __is_same_as.
1166
43aae289
MP
11672019-12-03 Marek Polacek <polacek@redhat.com>
1168
1169 PR c++/91363 - P0960R3: Parenthesized initialization of aggregates.
1170 * c-cppbuiltin.c (c_cpp_builtins): Predefine
1171 __cpp_aggregate_paren_init=201902 for -std=c++2a.
1172
d7ddfbcb
JH
11732019-11-30 Jan Hubicka <hubicka@ucw.cz>
1174
1175 * c-attribs.c (handle_symver_attribute): New function
1176 (c_common_attributes): Add symver.
1177
65ef05d0
RS
11782019-11-30 Richard Sandiford <richard.sandiford@arm.com>
1179
1180 * c-common.c (pointer_int_sum): Use verify_type_context to check
1181 whether the target allows pointer arithmetic for the types involved.
1182 (c_sizeof_or_alignof_type, c_alignof_expr): Use verify_type_context
1183 to check whether the target allows sizeof and alignof operations
1184 for the types involved.
1185
1a291106
JM
11862019-11-27 Jason Merrill <jason@redhat.com>
1187
1188 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
1189
05d6cb1a
JJ
11902019-11-26 Jakub Jelinek <jakub@redhat.com>
1191
1192 PR c++/61414
1193 * c-attribs.c (handle_mode_attribute): Add mode attribute to
1194 ENUMERAL_TYPEs.
1195
5b8d9367
JM
11962019-11-25 Joseph Myers <joseph@codesourcery.com>
1197
1198 PR c/91985
1199 * c-common.c (c_common_type_for_mode): Handle decimal
1200 floating-point types being NULL_TREE.
1201 * c-format.c (get_format_for_type_1): Handle specified types being
1202 NULL_TREE.
1203 * c-lex.c (interpret_float): Give an error for decimal
1204 floating-point constants when decimal floating-point not
1205 supported.
1206
1fbf51cb
JJ
12072019-11-23 Jakub Jelinek <jakub@redhat.com>
1208
1209 PR middle-end/83859
1210 * c-attribs.c (append_access_attrs): Avoid buffer overflow. Avoid
1211 memory leak. Use XNEWVEC macro. Use auto_diagnostic_group to
1212 group warning with inform together.
1213 (handle_access_attribute): Formatting fix.
1214
761df906
JJ
12152019-11-22 Jakub Jelinek <jakub@redhat.com>
1216
bdaf8be1
JJ
1217 PR c/90677
1218 * c-common.h (identifier_global_tag): Declare.
1219 * c-format.c (get_pointer_to_named_type): Renamed to ...
1220 (get_named_type): ... this. Use identifier_global_tag instead of
1221 identifier_global_value, handle the return value being a TYPE_P.
1222 (init_dynamic_diag_info): Adjust get_pointer_to_named_type callers
1223 to call get_named_type instead. Formatting fixes.
1224
c2ecce6d 1225 Implement P1902R1, Missing feature-test macros 2017-2019.
761df906
JJ
1226 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_init_captures
1227 and __cpp_generic_lambdas for -std=c++2a. Define
1228 __cpp_designated_initializers, __cpp_constexpr_in_decltype and
1229 __cpp_consteval for -std=c++2a. Remove a FIXME comment about
1230 __cpp_concepts for -std=c++2a.
1231
54aa6b58
MS
12322019-11-22 Martin Sebor <msebor@redhat.com>
1233
1234 PR middle-end/83859
1235 * c-attribs.c (handle_access_attribute): New function.
1236 (c_common_attribute_table): Add new attribute.
1237 (get_argument_type): New function.
1238 (append_access_attrs): New function.
1239 (get_nonnull_operand): Rename...
1240 (get_attribute_operand): ...to this.
1241 * c-common.c (get_nonnull_operand): Rename...
1242 (get_attribute_operand): ...to this.
1243
6c80b1b5
JM
12442019-11-21 Joseph Myers <joseph@codesourcery.com>
1245
1246 * c-attribs.c (handle_fallthrough_attribute): Use pedwarn instead
1247 of warning.
1248
192961ff
JM
12492019-11-19 Joseph Myers <joseph@codesourcery.com>
1250
1251 * c-common.c (attribute_fallthrough_p): In C, use pedwarn not
1252 warning for standard attributes mixed with fallthrough attributes.
1253
f8aea5e3
JM
12542019-11-15 Joseph Myers <joseph@codesourcery.com>
1255
1256 * c-attribs.c (handle_fallthrough_attribute): Remove static.
1257 * c-common.h (handle_fallthrough_attribute): Declare.
1258
2cc94aa8
JM
12592019-11-15 Joseph Myers <joseph@codesourcery.com>
1260
1261 * c-attribs.c (handle_deprecated_attribute): Remove static.
1262 * c-common.h (handle_deprecated_attribute): Declare.
1263
7c5890cc
JM
12642019-11-14 Joseph Myers <joseph@codesourcery.com>
1265
1266 * c-lex.c (lex_charconst): Make CPP_UTF8CHAR constants unsigned
1267 char for C.
1268
b2417b59
JJ
12692019-11-14 Jakub Jelinek <jakub@redhat.com>
1270
d0ec7c93
JJ
1271 * c-omp.c (c_omp_check_context_selector): Add nvidia to the list of
1272 valid vendors.
1273
b2417b59
JJ
1274 * c-omp.c (c_omp_check_context_selector): Handle name lists
1275 containing string literals. Don't diagnose atomic_default_mem_order
1276 with multiple props.
1277
00be2a5f
JM
12782019-11-13 Joseph Myers <joseph@codesourcery.com>
1279
1280 * c-cppbuiltin.c (builtin_define_float_constants): Also define
1281 NORM_MAX constants. Update call to get_max_float.
1282 (LAZY_HEX_FP_VALUES_CNT): Update value to include NORM_MAX
1283 constants.
1284
2dbad62d
EB
12852019-11-13 Eric Botcazou <ebotcazou@adacore.com>
1286
1287 * c-ada-spec.c (get_underlying_decl): Do not look through typedefs.
1288 (dump_forward_type): Do not generate a declaration for function types.
1289 (dump_nested_type) <ARRAY_TYPE>: Do not generate a nested declaration
1290 of the component type if it is declared in another file.
1291
6ed76044
ML
12922019-11-12 Martin Liska <mliska@suse.cz>
1293
1294 * c-opts.c (c_common_post_options):
1295 Use SET_OPTION_IF_UNSET.
1296
62aee289
MR
12972019-11-12 Maciej W. Rozycki <macro@codesourcery.com>
1298 Frederik Harwath <frederik@codesourcery.com>
1299
1300 gcc/c-family/
1301 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_SERIAL enumeration
1302 constant.
1303 * c-pragma.c (oacc_pragmas): Add "serial" entry.
1304
f486280c
RS
13052019-11-08 Richard Sandiford <richard.sandiford@arm.com>
1306
1307 * c-common.h (gnu_vector_type_p): New function.
1308 * c-common.c (c_build_vec_perm_expr): Require __builtin_shuffle
1309 vectors to satisfy gnu_vector_type_p.
1310 (c_build_vec_convert): Likewise __builtin_convertvector.
1311 (convert_vector_to_array_for_subscript): Likewise when applying
1312 implicit vector to array conversion.
1313 (scalar_to_vector): Likewise when converting vector-scalar
1314 operations to vector-vector operations.
1315
017c6491
JM
13162019-11-08 Joseph Myers <joseph@codesourcery.com>
1317
1318 * c.opt (Wold-style-definition): Initialize to -1.
1319 * c-opts.c (c_common_post_options): Set warn_old_style_definition
1320 to flag_isoc2x if not set explicitly.
1321
c01bd174
JM
13222019-11-07 Joseph Myers <joseph@codesourcery.com>
1323
1324 * c-attribs.c (parse_tm_stmt_attr): Handle scoped attributes.
1325
0df65305
JM
13262019-11-05 Jason Merrill <jason@redhat.com>
1327
1328 * c-opts.c (c_common_post_options): -fconcepts-ts implies
1329 -fconcepts.
1330
e0c866dd
KK
13312019-11-04 Kamlesh Kumar <kamleshbhalui@gmail.com>
1332
1333 * c-opts.c (c_common_post_options): Update
1334 latest_abi_version.
1335
f968ef9b
JJ
13362019-11-02 Jakub Jelinek <jakub@redhat.com>
1337
d0c464d2
JJ
1338 * c-common.h (c_omp_get_context_selector): Remove.
1339 * c-omp.c (c_omp_get_context_selector): Moved to omp-general.c
1340 and renamed to omp_get_context_selector.
1341
917dd789
JJ
1342 * c-omp.c (c_omp_mark_declare_variant): Use
1343 omp_context_selector_set_compare.
1344
f968ef9b
JJ
1345 PR c++/88335 - Implement P1073R3: Immediate functions
1346 * c-common.h (enum rid): Add RID_CONSTEVAL.
1347 * c-common.c (c_common_reswords): Add consteval.
1348
5f6705b7
JJ
13492019-11-01 Martin Sebor <msebor@redhat.com>
1350
1351 PR middle-end/91679
1352 PR middle-end/91647
1353 PR middle-end/91463
1354 PR middle-end/92312
1355 * c-pretty-print.c (direct_abstract_declarator): Print
1356 bound in zero-length arrays.
1357 * c.opt (-Wzero-length-bounds): New option.
1358
43f1814c
NS
13592019-10-30 Nathan Sidwell <nathan@acm.org>
1360
1361 * c-cppbuiltin.c (c_cpp_builtins): Add 'L' suffix to feature
1362 macros.
1363
ad1539d5
MS
13642019-10-28 Martin Sebor <msebor@redhat.com>
1365
1366 PR c/66970
1367 * c-common.c (c_common_nodes_and_builtins): Call c_define_builtins
1368 even when only preprocessing.
1369 * c-common.h (names_builtin_p): Declare new function.
1370 * c-lex.c (init_c_lex): Set has_builtin.
1371 (c_common_has_builtin): Define a new function.
1372 * c-ppoutput.c (init_pp_output): Set has_builtin.
1373
135df52c
JJ
13742019-10-24 Jakub Jelinek <jakub@redhat.com>
1375
1376 * c-common.h (c_omp_context_selector_matches): Remove.
1377 * c-omp.c (c_omp_context_selector_matches): Remove.
1378 * c-attribs.c (c_common_attribute_table): Add
1379 "omp declare target {host,nohost,block}" attributes.
1380
8ad0c477
JM
13812019-10-17 JeanHeyd Meneide <phdofthehouse@gmail.com>
1382
1383 * c-lex.c (c_common_has_attribute): Update nodiscard value.
1384
56898e43
RS
13852019-10-14 Richard Sandiford <richard.sandiford@arm.com>
1386
1387 * c-common.h (user_facing_original_type_p): Declare.
1388 * c-common.c: Include c-spellcheck.h.
1389 (user_facing_original_type_p): New function.
1390
20de9568
JJ
13912019-10-12 Jakub Jelinek <jakub@redhat.com>
1392
1393 * c-common.h (c_omp_mark_declare_variant,
1394 c_omp_context_selector_matches): Declare.
1395 * c-omp.c: Include attribs.h, gimplify.h, cgraph.h, symbol-summary.h
1396 and hsa-common.h.
1397 (c_omp_get_context_selector): Support second argument NULL.
1398 (c_omp_mark_declare_variant, c_omp_context_selector_matches): New
1399 functions.
1400 * c-attribs.c (c_common_attribute_table): Remove "omp declare variant"
1401 attribute, add "omp declare variant base" and
1402 "omp declare variant variant" attributes.
1403
175a85b2
JM
14042019-10-11 Joseph Myers <joseph@codesourcery.com>
1405
1406 * c.opt (Wc11-c2x-compat): Add CPP(cpp_warn_c11_c2x_compat)
1407 CppReason(CPP_W_C11_C2X_COMPAT).
1408
fe2bc27c
JM
14092019-10-11 Joseph Myers <joseph@codesourcery.com>
1410
1411 * c-common.c (c_common_reswords): Do not use D_EXT for _Decimal32,
1412 _Decimal64 and _Decimal128.
1413
27dfdc0f
JM
14142019-10-10 Joseph Myers <joseph@codesourcery.com>
1415
1416 * c-cppbuiltin.c (c_cpp_builtins): Do not define macros for DFP
1417 types if DFP not supported.
1418
94e7f906
JJ
14192019-10-10 Jakub Jelinek <jakub@redhat.com>
1420
1421 * c-common.h (c_omp_check_context_selector,
1422 c_omp_get_context_selector): Declare.
1423 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): Fix spelling
1424 in diagnostic message.
1425 (c_omp_check_context_selector, c_omp_get_context_selector): New
1426 functions.
1427 * c-attribs.c (c_common_attribute_table): Add "omp declare variant"
1428 attribute.
1429 (handle_omp_declare_variant_attribute): New function.
1430
a7160771
MS
14312019-10-09 Martin Sebor <msebor@redhat.com>
1432
1433 PR tree-optimization/90879
1434 * c.opt (-Wstring-compare): New option.
1435
cb57504a
JM
14362019-10-08 Andrew Sutton <asutton@lock3software.com>
1437 Jason Merrill <jason@redhat.com>
1438
1439 Update the concepts implementation to conform to the C++20
1440 specification, improve compile times, and generally clean up
1441 the implementation.
1442
1443 * c-cppbuiltin.c (c_cpp_builtins): Use new feature test values for
1444 concepts when -std=c++2a. Bump __cpp_concepts to 201907.
1445 * c.opt: Add -Wconcepts-ts.
1446 * c-opts.c (c_common_post_options): Warn when -fconcepts is used
1447 with -std=c++2a. Disable warning for -fconcepts in C++20 mode.
1448 (set_std_cxx2a): Enable concepts by default.
1449
fbb2a6dc
JM
14502019-10-08 Joseph Myers <joseph@codesourcery.com>
1451
1452 * c-opts.c (c_common_post_options): Set
1453 -fno-fp-int-builtin-inexact for C2X.
1454
8e007055
JJ
14552019-10-05 Jakub Jelinek <jakub@redhat.com>
1456
1457 PR c++/91369 - Implement P0784R7: constexpr new
1458 * c-cppbuiltin.c (c_cpp_builtins): Predefine
1459 __cpp_constexpr_dynamic_alloc=201907 for -std=c++2a.
1460
843f104d
JM
14612019-10-04 Joseph Myers <joseph@codesourcery.com>
1462
1463 PR c/82752
1464 * c-format.c (C_STD_VER): Handle C2x.
1465 (C_STD_NAME): Likewise.
1466 (strftime_flag_specs): Add 'O' modifier with 'p' flag.
1467 (time_char_table): Use separate entry for 'B' and 'b', with 'O'
1468 modifier allowed and 'p' flag.
1469 * c-format.h (enum format_std_version): Add STD_C2X.
1470 (struct format_char_info): Mention 'p' in comment on flags2.
1471
e9c9a142
DM
14722019-10-01 David Malcolm <dmalcolm@redhat.com>
1473
1474 * c-opts.c (c_diagnostic_finalizer): Temporarily clear prefix when
1475 calling diagnostic_show_locus, rather than destroying it afterwards.
1476
7552c36a
JJ
14772019-10-01 Jakub Jelinek <jakub@redhat.com>
1478
1479 PR c++/91925
1480 * c-warn.c (check_alignment_of_packed_member): Ignore FIELD_DECLs
1481 with NULL DECL_FIELD_OFFSET.
1482
8209db25
RS
14832019-10-01 Richard Sandiford <richard.sandiford@arm.com>
1484
1485 * c-pretty-print.c (pp_c_specifier_qualifier_list): If a vector type
1486 has a type name, use it in preference to the __vector syntax.
1487
9343bf99
RS
14882019-09-30 Richard Sandiford <richard.sandiford@arm.com>
1489
1490 * c-pretty-print.c (pp_c_parameter_type_list): Avoid printing
1491 two spaces between a comma and "...".
1492
59bc434a
JJ
14932019-09-27 Jakub Jelinek <jakub@redhat.com>
1494
1495 PR c++/88203
1496 * c-common.h (c_omp_predefined_variable): Declare.
1497 * c-omp.c (c_omp_predefined_variable): New function.
1498 (c_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
1499 for predefined variables.
1500
c6447c20
RS
15012019-09-27 Richard Sandiford <richard.sandiford@arm.com>
1502
1503 * c-common.h (build_function_call_vec): Take the original
1504 function decl as an optional final parameter.
1505 (check_builtin_function_arguments): Take the original function decl.
1506 * c-common.c (check_builtin_function_arguments): Likewise.
1507 Handle all built-in functions, not just BUILT_IN_NORMAL ones.
1508 Use targetm.check_builtin_call to check BUILT_IN_MD functions.
1509
c4438114
JM
15102019-09-15 Jason Merrill <jason@redhat.com>
1511
1512 * c-warn.c (warn_logical_operator): Strip location wrappers. Don't
1513 fold_for_warn in "|| mask" warning.
1514
68a57628
ML
15152019-09-10 Martin Liska <mliska@suse.cz>
1516
1517 * c.opt: Use newly added WarnRemoved.
1518
f48ef52e
ML
15192019-09-09 Martin Liska <mliska@suse.cz>
1520
1521 * c.opt: Update comment of removed
1522 options that are preserved only for backward
1523 compatibility.
1524
67f6e649
ML
15252019-09-06 Martin Liska <mliska@suse.cz>
1526
1527 PR c++/91125
1528 * c-common.c: Remove definition of flag_use_repository.
1529 * c-common.h: Likewise.
1530 * c-opts.c (c_common_handle_option):
1531 Do not handle OPT_frepo option.
1532 * c.opt: Mark the option with Deprecated.
1533
db9d2274
MP
15342019-09-04 Marek Polacek <polacek@redhat.com>
1535
1536 * c.opt (fdeduce-init-list): Ignored.
1537
68e2c199
PK
15382019-09-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1539
1540 PR c/78736
1541 * c.opt (Wenum-conversion): New option.
1542
7a4418a5
JL
15432019-09-03 Jozef Lawrynowicz <jozef.l@mittosystems.com>
1544
1545 * c-attribs.c (handle_section_attribute): Call the
1546 handle_generic_attribute target hook after performing target
1547 independent processing.
1548 (handle_noinit_attribute): Likewise.
1549
5f76ab15
ILT
15502019-09-03 Ian Lance Taylor <iant@golang.org>
1551
1552 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Always expand
1553 when using -fgo-dump-spec.
1554
ae0d3f6a
ML
15552019-09-02 Martin Liska <mliska@suse.cz>
1556
1557 PR c++/91155
1558 * c-common.c (fname_as_string): Use cxx_printable_name for
1559 __PRETTY_FUNCTION__ same as was used before r265711.
1560
8a902edb
MP
15612019-08-28 Marek Polacek <polacek@redhat.com>
1562
1563 Implement P1152R4: Deprecating some uses of volatile.
1564 PR c++/91361
1565 * c-opts.c (c_common_post_options): Enable -Wvolatile by
1566 default for C++2a, unless -Wno-deprecated.
1567 * c.opt (Wvolatile): New warning.
1568
4742dbe7
MP
15692019-08-28 Marek Polacek <polacek@redhat.com>
1570
1571 PR c++/91360 - Implement C++20 P1143R2: constinit.
1572 * c-common.c (c_common_reswords): Add constinit and __constinit.
1573 (keyword_is_decl_specifier): Handle RID_CONSTINIT.
1574 * c-common.h (enum rid): Add RID_CONSTINIT, RID_FIRST_CXX20, and
1575 RID_LAST_CXX20.
1576 (D_CXX20): Define.
1577 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_constinit.
1578 * c-format.c (cxx_keywords): Add "constinit".
1579 * c.opt (Wc++2a-compat, Wc++20-compat): New options.
1580
6a074892
JJ
15812019-08-27 Jakub Jelinek <jakub@redhat.com>
1582
1583 PR c++/91415
1584 * c-common.c (verify_tree): For LSHIFT_EXPR, RSHIFT_EXPR,
1585 COMPONENT_REF and ARRAY_REF in cxx_dialect >= cxx17 mode handle it
1586 like COMPOUND_EXPR rather than normal expression.
1587
22f8849d
IS
15882019-08-23 Iain Sandoe <iain@sandoe.co.uk>
1589
1590 PR pch/61250
1591 * c-lex.c (c_lex_with_flags): Don't call
1592 c_common_no_more_pch () from here.
1593
df375b03
JJ
15942019-08-23 Jakub Jelinek <jakub@redhat.com>
1595
1596 PR middle-end/91283
1597 * c-common.c (c_ts18661_flt_eval_method): Use flag_excess_precision
1598 instead of flag_excess_precision_cmdline.
1599 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): Likewise.
1600 * c-opts.c (c_common_post_options): Likewise.
1601
14b7950f
MS
16022019-08-22 Martin Sebor <msebor@redhat.com>
1603
1604 PR middle-end/91490
1605 * c-common.c (braced_list_to_string): Add argument and overload.
1606 Handle flexible length arrays and unions.
1607
8bb2ee59
EB
16082019-08-21 Eric Botcazou <ebotcazou@adacore.com>
1609
1610 * c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
1611 function declarations where arguments are missing. Rename variables.
1612
21c1e205
RB
16132019-08-15 Richard Biener <rguenther@suse.de>
1614
1615 * c-common.c (c_stddef_cpp_builtins): When the GIMPLE FE is
1616 enabled, define __SIZETYPE__.
1617
f0033821
CL
16182019-08-14 Christophe Lyon <christophe.lyon@linaro.org>
1619
1620 * c-attribs.c (c_common_attribute_table): Add "noinit" entry. Add
1621 exclusion with "section" attribute.
1622 (attr_noinit_exclusions): New table.
1623 (handle_noinit_attribute): New function.
1624
4d732405
RS
16252019-08-13 Richard Sandiford <richard.sandiford@arm.com>
1626
1627 PR middle-end/91421
1628 * c-common.c (resolve_overloaded_builtin): Use
1629 copy_decl_built_in_function.
1630
51ad8481
MS
16312019-08-13 Martin Sebor <msebor@redhat.com>
1632
1633 PR c/80619
1634 * c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
1635 (asm_fprintf_length_spec): Same.
1636 * c-format.h (format_lengths): Add FMT_LEN_w.
1637
77eb117f
JJ
16382019-08-10 Jakub Jelinek <jakub@redhat.com>
1639
1640 * c-pragma.h (enum pragma_omp_clause): Add
1641 PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
1642
398e3feb
JJ
16432019-08-07 Jakub Jelinek <jakub@redhat.com>
1644
1645 * c-pragma.h (enum pragma_omp_clause): Add
1646 PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. Set PRAGMA_OACC_CLAUSE_USE_DEVICE
1647 equal to PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR instead of being a separate
1648 enumeration value.
1649
ab574db6
MP
16502019-08-05 Marek Polacek <polacek@redhat.com>
1651
1652 PR c++/91338 - Implement P1161R3: Deprecate a[b,c].
1653 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
1654 default for C++2a, unless -Wno-deprecated.
1655 * c.opt (Wcomma-subscript): New warning.
1656
554a530f
JJ
16572019-07-20 Jakub Jelinek <jakub@redhat.com>
1658
1659 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_LOOP.
1660 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_BIND.
1661 * c-pragma.c (omp_pragmas_simd): Add PRAGMA_OMP_LOOP entry.
1662 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_LOOP.
1663 * c-omp.c (c_omp_split_clauses): Add support for 4 new combined
1664 constructs with the loop construct.
1665
1a888209
JJ
16662019-07-13 Jakub Jelinek <jakub@redhat.com>
1667
1668 PR c/91149
1669 * c-omp.c (c_omp_split_clauses): Fix a pasto in
1670 OMP_CLAUSE_REDUCTION_TASK handling.
1671
1fdd6f04
JJ
16722019-07-12 Jakub Jelinek <jakub@redhat.com>
1673
1674 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ORDER.
1675 * c-omp.c (c_omp_split_clauses): Handle splitting of OMP_CLAUSE_ORDER.
1676
99b1c316
MS
16772019-07-09 Martin Sebor <msebor@redhat.com>
1678
1679 PR c++/61339
1fdd6f04 1680 * c-opts.c (handle_deferred_opts): Change class-key of PODs to struct
99b1c316
MS
1681 and others to class.
1682 * c-pretty-print.h: Same.
1683
6c1dae73
MS
16842019-07-09 Martin Sebor <msebor@redhat.com>
1685
1686 PR c++/61339
1687 * c-format.c (check_argument_type): Change class-key from class to
1688 struct and vice versa to match convention and avoid -Wclass-is-pod
1689 and -Wstruct-no-pod.
1690 * c-pretty-print.h: Same.
1691
8ba6ea87
ML
16922019-07-03 Martin Liska <mliska@suse.cz>
1693
1694 * c-common.c (try_to_locate_new_include_insertion_point): Remove
1695 dead assignemts.
1696
83eb9522
JJ
16972019-07-03 Jakub Jelinek <jakub@redhat.com>
1698
1699 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_REDUCTION_INSCAN
1700 clauses on OMP_FOR rather than OMP_PARALLEL when OMP_FOR is combined
1701 with OMP_PARALLEL.
1702
1c6ffbab
QZ
17032019-07-02 qing zhao <qing.zhao@oracle.com>
1704
1705 PR preprocessor/90581
1706 * c-opts.c (c_common_handle_option): Handle -fmax-include-depth.
1707 * c.opt: Add new option -fmax-include-depth.
1708
7ffc7de5
JM
17092019-06-26 Jason Merrill <jason@redhat.com>
1710
1711 PR c++/55442 - memory-hog with highly recursive constexpr.
1712 * c.opt (fconstexpr-loop-limit): New.
1713
361af3e4
JJ
17142019-06-25 Jakub Jelinek <jakub@redhat.com>
1715
1716 PR sanitizer/90954
1717 * c-omp.c (c_finish_omp_atomic): Allow tree_invariant_p in addition
1718 to SAVE_EXPR in first operand of a COMPOUND_EXPR.
1719
ab20d992
JJ
17202019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
1721
1722 * c-common.c (c_common_nodes_and_builtins): Define
1723 alternate "__intN__" name for "__intN" types.
1724
f4af4019
JH
17252019-06-24 Jan Hubicka <jh@suse.cz>
1726
1727 * c-common.c (braced_lists_to_strings): Check that
1728 type is array or integer prior checking string flag.
1729
da9e9b57
MB
17302019-06-21 Matthew Beliveau <mbelivea@redhat.com>
1731
1732 PR c++/90875 - added -Wswitch-outside-range option
1733 * c.opt (Wswitch-outside-range): Added new option.
1734 * c-warn.c (c_do_switch_warnings): Use OPT_Wswitch-outside-range.
1735
3f3d6a6f
MP
17362019-06-21 Marek Polacek <polacek@redhat.com>
1737
1738 PR c++/90953 - ICE with -Wmissing-format-attribute.
1739 * c-common.c (check_function_arguments_recurse): Use
1740 get_attribute_name.
1741 (check_missing_format_attribute): Likewise.
1742
1bf32c11
MP
17432019-06-19 Marek Polacek <polacek@redhat.com>
1744
1745 PR c++/60364 - noreturn after first decl not diagnosed.
1746 * c-attribs.c (handle_noreturn_attribute): No longer static.
1747 * c-common.h (handle_noreturn_attribute, attr_noreturn_exclusions):
1748 Declare.
1749 * c-format.c (check_function_format): Use get_attribute_name.
1750
a04c0734
MS
17512019-06-19 Martin Sebor <msebor@redhat.com>
1752
1753 PR translation/90156
1754 * c-format.c (function_format_info::format_type): Adjust type.
1755 (function_format_info::is_raw): New member.
1756 (decode_format_type): Adjust signature. Handle "raw" diag attributes.
1757 (decode_format_attr): Adjust call to decode_format_type.
1758 Avoid a redundant call to convert_format_name_to_system_name.
1759 Avoid abbreviating the word "arguments" in a diagnostic.
1760 (format_warning_substr): New function.
1761 (avoid_dollar_number): Quote dollar sign in a diagnostic.
1762 (finish_dollar_format_checking): Same.
1763 (check_format_info): Same.
1764 (struct baltoks_t): New.
1765 (c_opers, c_keywords, cxx_keywords, badwords, contrs): New arrays.
1766 (maybe_diag_unbalanced_tokens, check_tokens, check_plain): New
1767 functions.
1768 (check_format_info_main): Call check_plain. Use baltoks_t. Call
1769 maybe_diag_unbalanced_tokens.
1770 (handle_format_attribute): Spell out the word "arguments" in
1771 a diagnostic.
1772
d3786ebb
MB
17732019-06-11 Matthew Beliveau <mbelivea@redhat.com>
1774
1775 PR c++/90449 - add -Winaccessible-base option.
1776 * c.opt (Winaccessible-base): New option.
1777
bf38f7e9
JJ
17782019-06-10 Jakub Jelinek <jakub@redhat.com>
1779
1780 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCAN.
1781 * c-pragma.c (omp_pragmas_simd): Add #pragma omp scan.
1782 * c-omp.c (c_omp_split_clauses): Diagnose inscan reductions on
1783 combined/composite constructs where it is not allowed. Copy over
1784 OMP_CLAUSE_REDUCTION_INSCAN.
1785
0ecf545c
MS
17862019-06-05 Martin Sebor <msebor@redhat.com>
1787
1788 * c-attribs.c (handle_mode_attribute): Adjust quoting and hyphenation.
1789 (handle_alias_ifunc_attribute): Same.
1790 (handle_copy_attribute): Same.
1791 (handle_weakref_attribute): Same.
1792 (handle_nonnull_attribute): Same.
1793 * c-warn.c (warn_for_sign_compare): Same.
1794 (warn_for_restrict): Same.
1795 * c.opt: Same.
1796
36b34127
MS
17972019-06-05 Martin Sebor <msebor@redhat.com>
1798
1799 * c-pragma.c (handle_pragma_weak): Adjust quoting in a diagnostic.
1800 * c.opt (-Wformat-diag): Remove a spurious period.
1801
357a352f
JJ
18022019-05-29 Jakub Jelinek <jakub@redhat.com>
1803
1804 PR c/90628
1805 * c-common.c (check_builtin_function_arguments)
1806 <case BUILTIN_*_OVERFLOW>: Diagnose pointer to const qualified integer
1807 as last argument.
1808
2b8235ea
EB
18092019-05-23 Eric Botcazou <ebotcazou@adacore.com>
1810
1811 * c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
1812
6d86ddc4
ML
18132019-05-22 Martin Liska <mliska@suse.cz>
1814
1815 PR lto/90500
1816 * c-attribs.c (handle_copy_attribute): Do not copy
1817 target_clones attribute.
1818
419ba5b9
EB
18192019-05-21 Eric Botcazou <ebotcazou@adacore.com>
1820
1821 * c-ada-spec.h (enum cpp_operation): Add IS_ASSIGNMENT_OPERATOR.
1822 * c-ada-spec.c (print_assignment_operator): New function.
1823 (dump_ada_declaration) <FUNCTION_DECL>: Call it do dump explicit copy
1824 assignment operators declared as methods and filter out the others.
1825
e03436e7
TS
18262019-05-17 Thomas Schwinge <thomas@codesourcery.com>
1827
1828 PR c/89433
1829 * c-attribs.c (c_common_attribute_table): Set min_len to -1 for
1830 "omp declare target".
1831
a9c697b8
MS
18322019-05-16 Martin Sebor <msebor@redhat.com>
1833
ab20d992
JJ
1834 * c-attribs.c (handle_no_sanitize_attribute): Quote identifiers,
1835 keywords, operators, and types in diagnostics.
1836 (handle_scalar_storage_order_attribute): Same.
1837 (handle_mode_attribute): Same.
1838 (handle_visibility_attribute): Same.
1839 (handle_assume_aligned_attribute): Same.
1840 (handle_no_split_stack_attribute): Same.
1841 * c-common.c (shorten_compare): Same.
1842 (c_common_truthvalue_conversion): Same.
1843 (cb_get_source_date_epoch): Same.
1844 * c-lex.c (cb_def_pragma): Quote keywords, operators, and types
1845 in diagnostics.
1846 (interpret_float): Same.
1847 * c-omp.c (c_finish_omp_for): Same.
1848 * c-opts.c (c_common_post_options): Same.
1849 * c-pch.c (c_common_pch_pragma): Same.
1850 * c-pragma.c (pop_alignment): Same.
1851 (handle_pragma_pack): Same.
1852 (apply_pragma_weak): Same.
1853 (handle_pragma_weak): Same.
1854 (handle_pragma_scalar_storage_order): Same.
1855 (handle_pragma_redefine_extname): Same.
1856 (add_to_renaming_pragma_list): Same.
1857 (maybe_apply_renaming_pragma): Same.
1858 (push_visibility): Same.
1859 (handle_pragma_visibility): Same.
1860 (handle_pragma_optimize): Same.
1861 (handle_pragma_message): Same.
1862 * c-warn.c (warn_for_omitted_condop): Same.
1863 (lvalue_error): Same.
a9c697b8 1864
6b943512
RB
18652019-05-15 Richard Biener <rguenther@suse.de>
1866
1867 PR c/90474
1868 * c-common.c (c_common_mark_addressable_vec): Also mark
1869 a COMPOUND_LITERAL_EXPR_DECL addressable similar to
1870 c_mark_addressable.
ab20d992 1871
b744fc85
NS
18722019-05-06 Nathan Sidwell <nathan@acm.org>
1873
1874 * c-opts.c (handle_defered_opts): Rename struct deps to struc mkdeps.
1875
598f50d7
NS
18762019-04-30 Nathan Sidwell <nathan@acm.org>
1877
1878 * c-common.c (c_common_init_ts): Use MARK_TS_EXP. Mark SIZEOF_EXPR.
1879
5bcc5a3b
ML
18802019-04-30 Martin Liska <mliska@suse.cz>
1881
1882 * c-pragma.c (handle_pragma_diagnostic): Provide hints
1883 for unknown options.
1884
e78a87f7
RS
18852019-04-26 Richard Sandiford <richard.sandiford@arm.com>
1886
1887 * c-warn.c (strict_aliasing_warning): Apply COMPLETE_TYPE_P to
1888 the pointer target rather than the pointer itself.
1889
c280b7ee
JJ
18902019-04-19 Jakub Jelinek <jakub@redhat.com>
1891
1892 PR c/89888
1893 * c-common.h (c_add_case_label): Remove orig_type and outside_range_p
1894 arguments.
1895 (c_do_switch_warnings): Remove outside_range_p argument.
1896 * c-common.c (check_case_bounds): Removed.
1897 (c_add_case_label): Remove orig_type and outside_range_p arguments.
1898 Don't call check_case_bounds. Fold low_value as well as high_value.
1899 * c-warn.c (c_do_switch_warnings): Remove outside_range_p argument.
1900 Check for case labels outside of range of original type here and
1901 adjust them.
1902
8e8225e6
JJ
19032019-04-12 Jakub Jelinek <jakub@redhat.com>
1904
63b8a166
JJ
1905 PR translation/90041
1906 * c.opt (-fhandle-exceptions): Use %< and %> around option names
1907 in the Warn diagnostics.
1908
8e8225e6
JJ
1909 PR c/89946
1910 * c-attribs.c (handle_patchable_function_entry_attribute): Add
1911 function comment. Warn if arguments of the attribute are not positive
1912 integer constants.
1913
53a3f614
EB
19142019-04-09 Eric Botcazou <ebotcazou@adacore.com>
1915
1916 * c-ada-spec.c (print_destructor): Deal with deleting destructors.
1917 (dump_ada_declaration) <FUNCTION_DECL>: Likewise.
1918
22be5873
EB
19192019-04-07 Eric Botcazou <ebotcazou@adacore.com>
1920
1921 * c-ada-spec.c (is_float128): New predicate extracted from...
1922 (dump_ada_node) <COMPLEX_TYPE>: Use it to recognize __cfloat128.
1923 <REAL_TYPE>: ...here. Call it.
1924
34facf20
DM
19252019-04-05 David Malcolm <dmalcolm@redhat.com>
1926
1927 PR c/89985
1928 * c-warn.c (check_address_or_pointer_of_packed_member): Add
1929 auto_diagnostic_group. Guard inform calls by result of
1930 warning_at call.
1931
05564120
MP
19322019-04-05 Marek Polacek <polacek@redhat.com>
1933
ab20d992 1934 PR c++/89973 - -Waddress-of-packed-member ICE with invalid conversion.
05564120
MP
1935 * c-warn.c (check_address_or_pointer_of_packed_member): Check the type
1936 of RHS.
1937
7a506c3c
JM
19382019-04-03 Jason Merrill <jason@redhat.com>
1939
1940 PR c++/86586 - -fcompare-debug=-Wsign-compare.
1941 * c-warn.c (warn_for_sign_compare): Call fold_for_warn.
1942
ddeae8c8
MS
19432019-04-01 Martin Sebor <msebor@redhat.com>
1944
1945 PR c/89685
1946 * c-attribs.c (handle_copy_attribute): Handle references and
1947 non-constant expressions.
1948
a15ffa22
JJ
19492019-03-22 Jakub Jelinek <jakub@redhat.com>
1950
1951 PR c++/87481
1952 * c.opt (-fconstexpr-ops-limit=): New option.
1953
36a3a7a3
JJ
19542019-03-21 Jakub Jelinek <jakub@redhat.com>
1955
1956 * c-common.c (per_file_includes_t): Use false as Lazy in hash_set
1957 template param.
1958
bec1da64
MS
19592019-03-19 Martin Sebor <msebor@redhat.com>
1960
1961 PR tree-optimization/89688
1962 * c-common.c (braced_list_to_string): Make static.
1963 (braced_lists_to_strings): Define new function.
1964 * c-common.h (braced_list_to_string): Remove.
1965 (braced_lists_to_strings): Declare.
1966
1fe61adf
ML
19672019-03-12 Martin Liska <mliska@suse.cz>
1968
1969 * c-opts.c (c_common_handle_option): Wrap option with %< and %>.
1970
93964ebd
ML
19712019-03-11 Martin Liska <mliska@suse.cz>
1972
1973 * c-opts.c (c_common_post_options): Wrap apostrophes
1974 in gcc internal format with %'.
1975
a3f9f006
ML
19762019-03-11 Martin Liska <mliska@suse.cz>
1977
1978 * c-attribs.c (handle_nocf_check_attribute): Wrap an option name
1979 in a string format message and fix GNU coding style.
1980 * c-common.c (vector_types_convertible_p): Likewise.
1981 (c_build_vec_perm_expr): Likewise.
1982 * c-indentation.c (get_visual_column): Likewise.
1983 * c-opts.c (c_common_handle_option): Likewise.
1984 (c_common_post_options): Likewise.
1985 (sanitize_cpp_opts): Likewise.
1986 * c-pch.c (c_common_pch_pragma): Likewise.
1987 * c-pragma.c (handle_pragma_pack): Likewise.
1988
1db01ff9
JJ
19892019-03-08 Jakub Jelinek <jakub@redhat.com>
1990
1991 PR tree-optimization/89550
1992 * c-common.c (c_common_truthvalue_conversion): Only set
1993 TREE_NO_WARNING if warning_at returned true.
1994 * c-warn.c (overflow_warning, warn_logical_operator): Likewise.
1995
ba790e6f
JJ
19962019-02-25 Sandra Loosemore <sandra@codesourcery.com>
1997 Martin Sebor <msebor@gmail.com>
1998
1999 * c.opt (Wmissing-attributes): Clean up doc string.
2000
7da73ba7
JJ
20012019-02-25 Jakub Jelinek <jakub@redhat.com>
2002
2003 PR c/89495
2004 * c-format.c (maybe_read_dollar_number): Compute nargnum in
2005 HOST_WIDE_INT type to avoid overflows and change overflow_flag
2006 checking.
2007
921bb9d1
RB
20082019-02-22 Richard Biener <rguenther@suse.de>
2009
2010 * c-pch.c (no_checksum): Remove.
2011 (pch_init): Remove assertion that executable_checksum is not
2012 all zero.
2013 (c_common_valid_pch): Likewise.
2014
e2ebb05c
MS
20152019-02-18 Martin Sebor <msebor@redhat.com>
2016
2017 PR middle-end/89294
2018 * c-common.c (invalid_array_size_error): Handle cst_size_not_constant.
2019
3fe53000
DM
20202019-02-16 David Malcolm <dmalcolm@redhat.com>
2021
2022 PR c++/88680
2023 * c-common.c (shorten_compare): Call fold_for_warn on op0 when
2024 implementing -Wtype-limits.
2025
28a8cef1
MS
20262019-02-11 Martin Sebor <msebor@redhat.com>
2027
2028 PR c++/87996
2029 * c-common.c (invalid_array_size_error): New function.
2030 (valid_array_size_p): Call it. Handle size as well as type.
2031 * c-common.h (valid_constant_size_p): New function.
2032 (enum cst_size_error): New type.
2033
ec2be203
DM
20342019-01-31 David Malcolm <dmalcolm@redhat.com>
2035
2036 PR c/89122
2037 * known-headers.cc (get_stdlib_header_for_name): Add
2038 {FLT|DBL|LDBL}_{MAX|MIN} to "hints" array.
2039
8936f047
JJ
20402019-01-31 Jakub Jelinek <jakub@redhat.com>
2041
2042 PR libstdc++/88170
2043 * c-pretty-print.c (pp_c_enumeration_constant): Print always as
2044 a C cast in pp_c_flag_gnu_v3 mode.
2045
6a335b96
JJ
20462019-01-29 Jakub Jelinek <jakub@redhat.com>
2047
2048 PR c/86125
2049 * c-common.c (c_common_nodes_and_builtins): Build type variants for
2050 builtin_structptr_types types even for C.
2051
2a06eba5
BE
20522019-01-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
2053
2054 * c-warn.c (check_address_or_pointer_of_packed_member): Handle the case
2055 when rhs is of array type correctly. Fix handling of nested structures.
2056 Fix handling of indirect_ref together with nop_expr and/or addr_expr.
2057 (check_and_warn_address_or_pointer_of_packed_member): Fix handling of
2058 type casts within nested compound expressions.
2059
18a23298
JJ
20602019-01-22 Jakub Jelinek <jakub@redhat.com>
2061
2062 PR middle-end/88968
2063 * c-omp.c (c_finish_omp_atomic): For bitfield atomics, update type
2064 variable after using BIT_FIELD_REF.
2065
420183d9
L
20662019-01-18 H.J. Lu <hongjiu.lu@intel.com>
2067
2068 PR c/51628
2069 PR c/88664
2070 * c-common.h (warn_for_address_or_pointer_of_packed_member):
2071 Remove the boolean argument.
2072 * c-warn.c (check_address_of_packed_member): Renamed to ...
2073 (check_address_or_pointer_of_packed_member): This. Also
2074 warn pointer conversion.
2075 (check_and_warn_address_of_packed_member): Renamed to ...
2076 (check_and_warn_address_or_pointer_of_packed_member): This.
2077 Also warn pointer conversion.
2078 (warn_for_address_or_pointer_of_packed_member): Remove the
2079 boolean argument. Don't check pointer conversion here.
2080
99063eee
RS
20812019-01-15 Richard Sandiford <richard.sandiford@arm.com>
2082
2083 PR inline-asm/52813
2084 * c.opt (Wdeprecated): Move documentation and variable to common.opt.
2085
a30d0196
JJ
20862019-01-14 Jakub Jelinek <jakub@redhat.com>
2087
2088 * c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
2089 and __cpp_nontype_template_parameter_auto. Add a comment that
2090 __cpp_template_auto is deprecated.
2091
2d91f79d
TH
20922019-01-14 Tom Honermann <tom@honermann.net>
2093
2094 Implement P0482R5, char8_t: A type for UTF-8 characters and strings
2095 * c-common.c (c_common_reswords): Add char8_t.
2096 (fix_string_type): Use char8_t for the type of u8 string literals.
2097 (c_common_get_alias_set): char8_t doesn't alias.
2098 (c_common_nodes_and_builtins): Define char8_t as a builtin type in
2099 C++.
2100 (c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
2101 (keyword_begins_type_specifier): Add RID_CHAR8.
2102 * c-common.h (rid): Add RID_CHAR8.
2103 (c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
2104 Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
2105 Define char8_type_node and char8_array_type_node.
2106 * c-cppbuiltin.c (cpp_atomic_builtins): Predefine
2107 __GCC_ATOMIC_CHAR8_T_LOCK_FREE.
2108 (c_cpp_builtins): Predefine __cpp_char8_t.
2109 * c-lex.c (lex_string): Use char8_array_type_node as the type of
2110 CPP_UTF8STRING.
2111 (lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
2112 * c-opts.c: If not otherwise specified, enable -fchar8_t when
2113 targeting C++2a.
2114 * c.opt: Add the -fchar8_t command line option.
2115
23db6ced
MS
21162019-01-14 Martin Sebor <msebor@redhat.com>
2117
2118 PR target/88638
2119 * c-attribs.c (positional_argument): Call valid_format_string_type_p
2120 and issue errors if it fails.
2121 * c-common.h (valid_format_string_type_p): Declare.
2122 * c-format.c (valid_stringptr_type_p): Rename...
2123 (valid_format_string_type_p): ...to this and make extern.
2124 (handle_format_arg_attribute): Adjust to new name.
2125 (check_format_string): Same.
2126
234c3818
L
21272019-01-13 H.J. Lu <hongjiu.lu@intel.com>
2128
2129 * c-warn.c (warn_for_address_or_pointer_of_packed_member):
2130 Replace "may may" with "may" in warning message.
2131
d8fcab68
JJ
21322019-01-07 Jakub Jelinek <jakub@redhat.com>
2133
2134 PR c++/85052
2135 * c-common.h (enum rid): Add RID_BUILTIN_CONVERTVECTOR.
2136 (c_build_vec_convert): Declare.
2137 * c-common.c (c_build_vec_convert): New function.
2138
29d24852
MS
21392019-01-04 Martin Sebor <msebor@redhat.com>
2140
2141 PR c/88546
2142 * c-attribs.c (handle_copy_attribute): Avoid copying attribute leaf.
2143 Handle C++ empty throw specification and C11 _Noreturn.
2144 (has_attribute): Also handle C11 _Noreturn.
2145
9069a4c9
MS
21462019-01-04 Martin Sebor <msebor@redhat.com>
2147
2148 PR c/88363
2149 * c-attribs.c (positional_argument): Also accept enumerated types.
2150
a5544970
JJ
21512019-01-01 Jakub Jelinek <jakub@redhat.com>
2152
2153 Update copyright years.
2154
da77eace
L
21552018-12-20 H.J. Lu <hongjiu.lu@intel.com>
2156
2157 PR c/51628
2158 * c-common.h (warn_for_address_or_pointer_of_packed_member): New.
2159 * c-warn.c (check_alignment_of_packed_member): New function.
2160 (check_address_of_packed_member): Likewise.
2161 (check_and_warn_address_of_packed_member): Likewise.
2162 (warn_for_address_or_pointer_of_packed_member): Likewise.
2163 * c.opt: Add -Wno-address-of-packed-member.
2164
573767d4
DM
21652018-12-20 David Malcolm <dmalcolm@redhat.com>
2166
2167 PR c++/87504
2168 * c-warn.c (get_outermost_macro_expansion): New function.
2169 (spelled_the_same_p): Use it to unwind the macro expansions, and
2170 compare the outermost macro in each nested expansion, rather than
2171 the innermost.
2172
a14feb3c
DM
21732018-12-19 David Malcolm <dmalcolm@redhat.com>
2174
2175 PR c++/87504
2176 * c-common.h (warn_tautological_cmp): Convert 1st param from
2177 location_t to const op_location_t &.
2178 * c-warn.c (find_array_ref_with_const_idx_r): Call fold_for_warn
2179 when testing for INTEGER_CST.
2180 (warn_tautological_bitwise_comparison): Convert 1st param from
2181 location_t to const op_location_t &; use it to build a
2182 binary_op_rich_location, and use this.
2183 (spelled_the_same_p): New function.
2184 (warn_tautological_cmp): Convert 1st param from location_t to
2185 const op_location_t &. Warn for macro expansions if
2186 spelled_the_same_p. Use binary_op_rich_location.
2187
dfd7fdca
DM
21882018-12-19 David Malcolm <dmalcolm@redhat.com>
2189
2190 PR c++/43064
2191 PR c++/43486
2192 * c-common.c (unsafe_conversion_p): Fold any location wrapper.
2193 (verify_tree): Handle location wrappers.
2194 (c_common_truthvalue_conversion): Strip any location wrapper.
2195 Handle CONST_DECL.
2196 (fold_offsetof): Strip any location wrapper.
2197 (complete_array_type): Likewise for initial_value.
2198 (convert_vector_to_array_for_subscript): Call fold_for_warn on the
2199 index before checking for INTEGER_CST.
2200 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
2201 print parentheses around location wrappers.
2202 * c-warn.c (warn_logical_operator): Call fold_for_warn on op_right
2203 before checking for INTEGER_CST.
2204 (warn_tautological_bitwise_comparison): Call
2205 tree_strip_any_location_wrapper on lhs, rhs, and bitop's operand
2206 before checking for INTEGER_CST.
2207 (readonly_error): Strip any location wrapper.
2208 (warn_array_subscript_with_type_char): Strip location wrappers
2209 before checking for INTEGER_CST. Use the location of the index if
2210 available.
2211
5c8b3702
JM
22122018-12-06 Jason Merrill <jason@redhat.com>
2213
2214 PR c++/88136 - -Wdeprecated-copy false positives
2215 * c.opt (Wdeprecated-copy-dtor): New.
2216 (Wdeprecated-copy): Move to -Wextra.
2217
673670da
MS
22182018-11-29 Martin Sebor <msebor@redhat.com>
2219
2220 PR c/88172
2221 PR testsuite/88208
2222 * c-attribs.c (common_handle_aligned_attribute): Silently avoid setting
2223 alignments to values less than the target requires.
2224 (has_attribute): For attribute aligned consider both the attribute
2225 and the alignment bits.
2226 * c-common.c (c_init_attributes): Optionally issue a warning for
2227 zero alignment.
2228
04864ec8
MS
22292018-11-28 Martin Sebor <msebor@redhat.com>
2230
2231 PR c/88065
2232 PR c/87297
2233 * c-warn.c (sizeof_pointer_memaccess_warning): Bail if source
2234 or destination is an error.
2235
ace83db0
JJ
22362018-11-28 Jakub Jelinek <jakub@redhat.com>
2237
2238 PR c++/88215
2239 * c-ubsan.c: Include langhooks.h.
2240 (ubsan_instrument_division): Change gcc_assert that main variants
2241 of op0 and op1 types are equal to gcc_checking_assert that the
2242 main variants are compatible types.
2243
da193a27
EB
22442018-11-27 Eric Botcazou <ebotcazou@adacore.com>
2245
2246 * c-ada-spec.c: Include stringpool.h.
2247 (has_static_fields): Return false for incomplete types.
2248 (is_tagged_type): Likewise.
2249 (has_nontrivial_methods): Likewise.
2250 (dump_ada_node) <INTEGER_TYPE>: Deal specifically with __int128.
2251 (struct overloaded_name_hash): New structure.
2252 (struct overloaded_name_hasher): Likewise.
2253 (overloaded_names): New global variable.
2254 (init_overloaded_names): New static function.
2255 (overloaded_name_p): New predicate.
2256 (dump_ada_declaration) <TYPE_DECL>: Tidy up and set TREE_VISITED
2257 on the TYPE_STUB_DECL of the original type of a typedef, if any.
2258 <FUNCTION_DECL>: Bail out for an unsupported overloaded name.
2259 Remove always-true condition and dump forward types.
2260 (dump_ada_specs): Delete overloaded_names.
2261
98f08eb8
MS
22622018-11-20 Martin Sebor <msebor@redhat.com>
2263
2264 * c-attribs.c (type_for_vector_size): New function.
2265 (type_valid_for_vector_size): Same.
2266 (handle_vector_size_attribute): Move code to the functions above
2267 and call them.
2268 (validate_attribute, has_attribute): New functions.
2269 * c-common.h (has_attribute): Declare.
2270 (rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
2271 * c-common.c (c_common_resword): Same.
2272
2674fa47
JM
22732018-11-16 Jason Merrill <jason@redhat.com>
2274
2275 * c-lex.c (c_common_has_attribute): Handle likely/unlikely.
2276 * c-attribs.c (attr_cold_hot_exclusions): Make public.
2277
258b3854
JJ
22782018-11-16 Jakub Jelinek <jakub@redhat.com>
2279
2280 PR middle-end/87854
2281 * c-common.c (fix_string_type): Reject string literals larger than
2282 TYPE_MAX_VALUE (ssizetype) bytes.
2283
1d249509
MS
22842018-11-15 Martin Sebor <msebor@redhat.com>
2285
2286 PR c++/87541
2287 PR c++/87542
2288 * c-attribs.c (positional_argument): New function.
2289 (handle_alloc_size_attribute): Use it and simplify.
2290 (handle_alloc_align_attribute): Same.
2291 (handle_assume_aligned_attribute): Same.
2292 (handle_nonnull_attribute): Same.
2293 * c-common.c (check_function_arguments): Pass fntype to
2294 check_function_format.
2295 * c-common.h (check_function_format): Add an argument.
2296 (PosArgFlags, positional_argument): Declare new type and function.
2297 * c-format.c (decode_format_attr): Add arguments.
2298 (check_format_string, get_constant): Same.
2299 (convert_format_name_to_system_name): Adjust.
2300
478dd60d
DM
23012018-11-15 David Malcolm <dmalcolm@redhat.com>
2302
2303 PR other/19165
2304 * c-opts.c (c_diagnostic_finalizer): Add diagnostic_t param.
2305
8cca0163
JJ
23062018-11-14 Jakub Jelinek <jakub@redhat.com>
2307
8ee09943
JJ
2308 P1236R1 - Signed integers are two's complement
2309 * c-warn.c (maybe_warn_shift_overflow): Don't warn for c++2a.
2310 * c-ubsan.c (ubsan_instrument_shift): Make signed shifts
2311 with in-range second operand well defined for -std=c++2a.
2312
8cca0163
JJ
2313 PR other/88007
2314 * c-common.c (parse_optimize_options): Allocate option string from
2315 opts_obstack rather than as GC memory. Move the allocation after
2316 warning for invalid option.
2317
620e594b
DM
23182018-11-13 David Malcolm <dmalcolm@redhat.com>
2319
2320 * c-common.c (c_get_substring_location): Update for renaming of
2321 get_source_location_for_substring to get_location_within_string.
2322 * c-lex.c: Replace "source_location" with "location_t".
2323 * c-opts.c: Likewise.
2324 * c-ppoutput.c: Likewise.
2325
f9731de3
MS
23262018-11-13 Martin Sebor <msebor@redhat.com>
2327
2328 PR middle-end/81824
2329 * c-attribs.c (handle_copy_attribute): Exclude inlining attributes.
2330 (handle_tls_model_attribute): Improve diagnostics.
2331
e4bd6d5e
JM
23322018-11-12 Jason Merrill <jason@redhat.com>
2333
a6bb6b07
JM
2334 * c-cppbuiltin.c (c_cpp_builtins): Define
2335 __cpp_impl_destroying_delete.
2336
e4bd6d5e
JM
2337 * c-cppbuiltin.c (c_cpp_builtins): Change __cpp_explicit_bool to
2338 __cpp_conditional_explicit.
2339
79a2c428
MS
23402018-11-09 Martin Sebor <msebor@redhat.com>
2341
2342 PR middle-end/81824
2343 * c-attribs.c (handle_copy_attribute): New function.
2344
4c7bd361
MS
23452018-11-09 Martin Sebor <msebor@redhat.com>
2346
2347 PR c/87795
2348 * c-common.c (check_user_alignment): Use MAX_OFILE_ALIGNMENT.
2349
28567c40
JJ
23502018-11-08 Jakub Jelinek <jakub@redhat.com>
2351
2352 * c-common.h (c_finish_omp_taskgroup): Add CLAUSES argument.
2353 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
2354 enum omp_memory_order MEMORY_ORDER.
2355 (c_finish_omp_flush): Add MO argument.
2356 (c_omp_depend_t_p, c_finish_omp_depobj): Declare.
2357 (c_finish_omp_for): Add FINAL_P argument.
2358 * c-omp.c: Include memmodel.h.
2359 (c_finish_omp_taskgroup): Add CLAUSES argument. Set
2360 OMP_TASKGROUP_CLAUSES to it.
2361 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
2362 enum omp_memory_order MEMORY_ORDER. Set OMP_ATOMIC_MEMORY_ORDER
2363 instead of OMP_ATOMIC_SEQ_CST.
2364 (c_omp_depend_t_p, c_finish_omp_depobj): New functions.
2365 (c_finish_omp_flush): Add MO argument, if not MEMMODEL_LAST, emit
2366 __atomic_thread_fence call with the given value.
2367 (check_omp_for_incr_expr): Formatting fixes.
2368 (c_finish_omp_for): Add FINAL_P argument. Allow NE_EXPR
2369 even in OpenMP loops, diagnose if NE_EXPR and incr expression
2370 is not constant expression 1 or -1. Transform NE_EXPR loops
2371 with iterators pointers to VLA into LT_EXPR or GT_EXPR loops.
2372 (c_omp_check_loop_iv_r): Look for orig decl of C++ range for
2373 loops too.
2374 (c_omp_split_clauses): Add support for combined
2375 #pragma omp parallel master and
2376 #pragma omp {,parallel }master taskloop{, simd} constructs.
2377 Handle OMP_CLAUSE_IN_REDUCTION. Handle OMP_CLAUSE_REDUCTION_TASK.
2378 Handle OMP_CLAUSE_NONTEMPORAL. Handle splitting OMP_CLAUSE_IF
2379 also to OMP_SIMD. Copy OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
2380 (c_omp_predetermined_sharing): Don't return
2381 OMP_CLAUSE_DEFAULT_SHARED for const qualified decls.
2382 * c-pragma.c (omp_pragmas): Add PRAGMA_OMP_DEPOBJ and
2383 PRAGMA_OMP_REQUIRES.
2384 * c-pragma.h (enum pragma_kind): Likewise.
2385 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_NONTEMPORAL
2386 and PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
2387
204839e7
DM
23882018-11-08 David Malcolm <dmalcolm@redhat.com>
2389
2390 * c-format.c (gcc_dump_printf_char_table): Add entry for %f.
2391
d8010ee4
DM
23922018-11-08 David Malcolm <dmalcolm@redhat.com>
2393
2394 * c-format.c (local_cgraph_node_ptr_node): New variable.
2395 (gcc_dump_printf_char_table): Add entry for %C.
2396 (get_pointer_to_named_type): New function, taken from the handling
2397 code for "gimple *" from...
2398 (init_dynamic_diag_info): ...here. Add handling for
2399 "cgraph_node *".
2400 * c-format.h (T_CGRAPH_NODE): New.
2401
4be5c72c
JM
24022018-10-19 Jason Merrill <jason@redhat.com>
2403
2404 * c-cppbuiltin.c (c_cpp_builtins): Add
2405 __cpp_nontype_template_parameter_class.
2406
f3f6029d
NS
24072018-10-31 Nathan Sidwell <nathan@acm.org>
2408
ab5324fb
NS
2409 * c-opts.c (c_finish_options): Force command line macro
2410 location. Refactor to avoid repeating main debug hook.
2411 (push_command_line_include): Clarify comment.
2412
f3f6029d
NS
2413 * c-opts.c (c_finish_options): Adjust cpp_force_token_locations call.
2414
91e3ec29
MS
24152018-10-30 Martin Sebor <msebor@redhat.com>
2416
2417 PR middle-end/87041
2418 * c-format.c (check_format_types): Avoid diagnosing null pointer
2419 arguments to printf-family of functions.
2420
b5ff4f5c
MP
24212018-10-30 Marek Polacek <polacek@redhat.com>
2422
2423 Implement P0892R2, explicit(bool).
2424 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
2425
7e2de6df
DM
24262018-10-29 David Malcolm <dmalcolm@redhat.com>
2427
2428 * name-hint.h (name_hint::take_deferred): New member function.
2429
b2bf438c
DM
24302018-10-29 David Malcolm <dmalcolm@redhat.com>
2431
2432 PR c++/56856
2433 * c-common.c (check_function_sentinel): Call fold_for_warn on the
2434 argument.
2435 (check_function_restrict): Rename param "argarray" to
2436 "unfolded_argarray", and make a copy named "argarray", calling
2437 fold_for_warn on each argument.
2438 (check_function_arguments): Add note about responsibility for
2439 folding the arguments.
2440
9f936c86
JM
24412018-10-17 Joseph Myers <joseph@codesourcery.com>
2442
2443 * c-common.c (flag_isoc2x): New variable.
2444 * c-common.h (clk_c): Update comment to reference C2X.
2445 (flag_isoc99, flag_isoc11): Update comments to reference future
2446 standard versions in general.
2447 (flag_isoc2x): Declare.
2448 * c-opts.c (set_std_c2x): New function.
2449 (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
2450 (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
2451 flag_isoc2x to 0.
2452 * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
2453
7a8a92c4
JM
24542018-10-17 Joseph Myers <joseph@codesourcery.com>
2455
2456 * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
2457 (std=iso9899:2018): Document C17 as published in 2018.
2458
4dc003ff
CL
24592018-10-12 Christophe Lyon <christophe.lyon@linaro.org>
2460
2461 PR c++/87364
2462 * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
2463
79371671
WW
24642018-10-11 Will Wray <wjwray@gmail.com>
2465
2466 PR c++/87364
2467 * c-pretty-print.h (pp_c_type_cast): Prototype.
2468 (pp_c_integer_constant): Likewise.
2469 * c-pretty-print.c (pp_c_type_cast): No longer static.
2470 (pp_c_integer_constant): Likewise.
2471 (pp_c_enumeration_constant): Fix loop termination when finding
2472 name of constant. No longer returns a value. Call
2473 pp_c_integer_constant.
2474 (c_pretty_printer::constant): Update for changes to
2475 pp_c_enumeration_constant.
2476
46c62690
JJ
24772018-10-11 Jakub Jelinek <jakub@redhat.com>
2478
2479 * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
2480 for no_unique_address.
2481
c24300ba
DM
24822018-10-09 David Malcolm <dmalcolm@redhat.com>
2483
2484 * c-common.c (c_option_controlling_cpp_error): Rename to...
2485 (c_option_controlling_cpp_diagnostic): ...this, and convert
2486 "reason" from int to enum.
2487 (c_cpp_error): Rename to...
2488 (c_cpp_diagnostic): ...this, converting level and reason to enums.
2489 * c-common.h (c_cpp_error): Rename to...
2490 (c_cpp_diagnostic): ...this, converting level and reason to enums.
2491 * c-opts.c (c_common_init_options): Update for renaming.
2492
8656dafa
RS
24932018-10-08 Richard Sandiford <richard.sandiford@arm.com>
2494
2495 PR c/87286
2496 * c-common.c (vector_types_compatible_elements_p): Use
2497 INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
2498
8cff0652
VK
24992018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
2500
2501 * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
2502 to generate constructor destructor priority warning.
2503 * c.opt (-Wprio-ctor-dtor): New option.
2504
bedf03a2
JM
25052018-10-01 Jason Merrill <jason@redhat.com>
2506
2507 * c-lex.c (c_common_has_attribute): Add no_unique_address.
2508
6cc430c1
EB
25092018-10-01 Eric Botcazou <ebotcazou@adacore.com>
2510
2511 * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
2512 (dump_ada_node): Add const keyword.
2513
87677ac7
ML
25142018-09-25 Martin Liska <mliska@suse.cz>
2515
2516 * c-common.c (c_common_truthvalue_conversion):
2517 Remove Pascal from documentation.
2518
518196cb
EB
25192018-09-21 Eric Botcazou <ebotcazou@adacore.com>
2520
2521 * c-ada-spec.c: Include diagnostic.h.
2522 (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
2523
a599af84
MP
25242018-09-19 Marek Polacek <polacek@redhat.com>
2525
2526 * c.opt (Wclass-conversion): New.
2527
9c4a4b3c
DM
25282018-09-17 David Malcolm <dmalcolm@redhat.com>
2529
2530 * c-format.c (range_label_for_format_type_mismatch::get_text):
2531 Update for new param.
2532
c896ecfe
DM
25332018-09-17 David Malcolm <dmalcolm@redhat.com>
2534
2535 * c-format.c (format_warning_at_char): Update for introduction of
2536 format_string_diagnostic_t.
2537 (format_type_warning): Likewise.
2538
80c6d1f4
MJ
25392018-09-17 Martin Jambor <mjambor@suse.cz>
2540
2541 PR c/63886
2542 * c.opt (Wabsolute-value): New.
2543
6d900107
BE
25442018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
2545
2546 * c-common.c (complete_flexible_array_elts): New helper function.
2547 * c-common.h (complete_flexible_array_elts): Declare.
2548
b5764229
BE
25492018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
2550
2551 * c-common.c (braced_list_to_string): Remove eval parameter.
2552 Add some more checks. Always create zero-terminated STRING_CST.
2553 * c-common.h (braced_list_to_string): Adjust prototype.
2554
85204e23
DM
25552018-08-27 David Malcolm <dmalcolm@redhat.com>
2556
2557 PR 87091
2558 * c-common.c (c_cpp_error): Update for conversion of show_caret_p
2559 to a tri-state.
2560 (maybe_suggest_missing_token_insertion): Likewise.
2561 (maybe_add_include_fixit): Add param "override_location". If set,
2562 and source-printing is enabled, then override the rich_location's
2563 primary location with that of the insertion point for the fix-it
2564 hint, marking it with SHOW_LINES_WITHOUT_RANGE.
2565 * c-common.h (extern void maybe_add_include_fixit): Add bool
2566 param.
2567 * c-format.c (selftest::test_type_mismatch_range_labels): Update
2568 for conversion of show_caret_p to a tri-state.
2569 * c-warn.c (warn_for_restrict): Likewise.
2570 * known-headers.cc
2571 (suggest_missing_header::~suggest_missing_header): Update call to
2572 maybe_add_include_fixit to suggest overriding the location, as it
2573 is for a note.
2574
3d78e008
ML
25752018-08-27 Martin Liska <mliska@suse.cz>
2576
2577 * c-common.c (check_function_restrict): Use new function
92a285c1
ML
2578 fndecl_built_in_p and remove check for FUNCTION_DECL if
2579 possible.
3d78e008
ML
2580 (check_builtin_function_arguments): Likewise.
2581 (reject_gcc_builtin): Likewise.
2582 * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
2583
b5be6d0c
MP
25842018-08-26 Marek Polacek <polacek@redhat.com>
2585
2586 PR c++/87029, Implement -Wredundant-move.
2587 * c.opt (Wredundant-move): New option.
2588
79ca9c35
MP
25892018-08-21 Marek Polacek <polacek@redhat.com>
2590
2591 PR c++/86981, Implement -Wpessimizing-move.
2592 * c.opt (Wpessimizing-move): New option.
2593
097f82ec
DM
25942018-08-20 David Malcolm <dmalcolm@redhat.com>
2595
2596 PR other/84889
2597 * c-attribs.c (common_handle_aligned_attribute): Add
2598 auto_diagnostic_group instance.
2599 * c-indentation.c (warn_for_misleading_indentation): Likewise.
2600 * c-opts.c (c_common_post_options): Likewise.
2601 * c-warn.c (warn_logical_not_parentheses): Likewise.
2602 (warn_duplicated_cond_add_or_warn): Likewise.
2603 (warn_for_multistatement_macros): Likewise.
2604
3fb558b1
NS
26052018-08-20 Nathan Sidwell <nathan@acm.org>
2606
2607 * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
2608 access.
2609
800c0e98
NS
26102018-08-17 Nathan Sidwell <nathan@acm.org>
2611
2612 * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
2613 field.
2614 (laxy_hex_fp_value_count): Make unsigned.
2615 (lazy_hex_fp_value): Provided with macro & lazy number. Directly
2616 manipulate the macro.
2617 (builtin_defin_with_hex_fp_value): Adjust callback name, use
2618 cpp_define_lazily.
2619
6f795a92
DM
26202018-08-17 David Malcolm <dmalcolm@redhat.com>
2621
2622 * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
2623 (gcc_dump_printf_length_specs): New.
2624 (gcc_dump_printf_flag_pairs): New.
2625 (gcc_dump_printf_flag_specs): New.
2626 (gcc_dump_printf_char_table): New.
2627 (format_types_orig): Add entry for "gcc_dump_printf".
2628 (init_dynamic_diag_info): Set up length_char_specs and
2629 conversion_specs for gcc_dump_printf_format_type.
2630 (handle_format_attribute): Handle gcc_dump_printf_format_type.
2631
c5d725c0
NS
26322018-08-17 Nathan Sidwell <nathan@acm.org>
2633
10f04917
NS
2634 * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
2635
c5d725c0
NS
2636 * c-ada-spec.c: Don't #include "cpp-id-data.h"
2637 * c-cppbuiltin.c: Likewise.
2638
c0c12356
ML
26392018-08-17 Martin Liska <mliska@suse.cz>
2640
2641 * c.opt: Remove Warn, Init and Report for options with
92a285c1
ML
2642 Ignore/Deprecated flag. Warning is done automatically for
2643 Deprecated flags.
c0c12356 2644
10fcc142
DM
26452018-08-16 David Malcolm <dmalcolm@redhat.com>
2646
2647 PR c++/70693
2648 * c-common.c (selftest::c_family_tests): Call
2649 selftest::c_indentation_c_tests.
2650 * c-common.h (selftest::c_indentation_c_tests): New decl.
2651 * c-indentation.c: Include "selftest.h".
2652 (next_tab_stop): Add "tab_width" param, rather than accessing
2653 cpp_opts.
2654 (get_visual_column): Likewise. Clarify comment. Bulletproof
2655 against reading past the end of the line.
2656 (get_first_nws_vis_column): Add "tab_width" param.
2657 (detect_intervening_unindent): Likewise.
2658 (should_warn_for_misleading_indentation): Read tab width from
2659 cpp_opts and pass around.
2660 (selftest::test_next_tab_stop): New test.
2661 (selftest::assert_get_visual_column_succeeds): New function.
2662 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
2663 (selftest::assert_get_visual_column_fails): New function.
2664 (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
2665 (selftest::test_get_visual_column): New test.
2666 (selftest::c_indentation_c_tests): New function.
2667
3f6677f4
NS
26682018-08-16 Nathan Sidwell <nathan@acm.org>
2669
2670 * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
2671 (store_ada_macro): Likewise.
2672 * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
2673 * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
2674
96e6ae57
DM
26752018-08-15 David Malcolm <dmalcolm@redhat.com>
2676
2677 * c-format.c: Include "selftest-diagnostic.h" and
2678 "gcc-rich-location.h".
2679 (format_warning_at_char): Pass NULL for new label params of
2680 format_warning_va.
2681 (class indirection_suffix): New class.
2682 (class range_label_for_format_type_mismatch): New class.
2683 (format_type_warning): Move logic for generating "*" suffix to
2684 class indirection_suffix. Create "fmt_label" and "param_label"
2685 to show their types, and pass them to the
2686 format_warning_at_substring calls.
2687 (selftest::test_type_mismatch_range_labels): New test.
2688 (selftest::c_format_c_tests): Call it.
2689
23aa9f7c
MS
26902018-08-13 Martin Sebor <msebor@redhat.com>
2691
2692 PR tree-optimization/71625
2693 * c-common.c (braced_list_to_string): New function.
2694 * c-common.h (braced_list_to_string): Declare it.
2695
f10a9135
NS
26962018-08-08 Nathan Sidwell <nathan@acm.org>
2697
2698 * c-common.c (try_to_locate_new_include_inertion_point): Use
2699 linemap_included_from_linemap.
2700 * c-lex.c (fe_file_change): Use linemap_included_from.
2701 * c-ppoutput.c (pp_file_change): Likewise.
2702
8a45b051
MS
27032018-08-01 Martin Sebor <msebor@redhat.com>
2704
2705 PR tree-optimization/86650
ab20d992 2706 * c-format.c (gcc_tdiag_char_table): Update comment for "%G".
8a45b051
MS
2707 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
2708 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
2709 * c-format.h (T89_G): Update to be "gimple *" rather than
2710 "gcall *".
2711 (local_gcall_ptr_node): Rename...
2712 (local_gimple_ptr_node): ...to this.
2713
e540ccc0
DM
27142018-07-31 David Malcolm <dmalcolm@redhat.com>
2715
2716 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
2717 table entries for gcc_diag_char_table, and the 'Z' entry from
2718 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
2719 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
2720 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
2721 adding missing "Z" for this table. Remove erroneous "G" and "K"
2722 entries.
2723 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
2724 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
2725 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
2726
425fc685
RE
27272018-07-31 Richard Earnshaw <rearnsha@arm.com>
2728
2729 * c-common.c (speculation_safe_resolve_call): New function.
2730 (speculation_safe_resolve_params): New function.
2731 (speculation_safe_resolve_return): New function.
2732 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
2733 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
2734 __HAVE_SPECULATION_SAFE_VALUE.
2735
181463c2
DM
27362018-07-20 David Malcolm <dmalcolm@redhat.com>
2737
2738 * c-common.c (c_cpp_error): Remove redundant "line_table"
2739 parameter from call to rich_location::set_range.
2740 (maybe_suggest_missing_token_insertion): Likewise.
2741
0d7f9065
MS
27422018-07-20 Martin Sebor <msebor@redhat.com>
2743
2744 PR middle-end/82063
ab20d992 2745 * c.opt (-Warray-bounds): Remove redundant -Wall.
0d7f9065 2746
00abf86c
MS
27472018-07-20 Martin Sebor <msebor@redhat.com>
2748
2749 PR middle-end/82063
2750 * c-common.h (c_common_handle_option): Change function argument
2751 to HOST_WIDE_INT.
2752 * c-opts.c (c_common_init_options): Same.
2753 (c_common_handle_option): Same. Remove special handling of
2754 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
2755 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
2756 options to take a HOST_WIDE_INT argument and accept a byte-size
2757 suffix. Initialize.
2758 (-Wvla-larger-than): Same.
2759 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
2760 (-Wno-vla-larger-than): Same.
2761
9b452033
JJ
27622018-07-12 Jakub Jelinek <jakub@redhat.com>
2763
2764 * c-attribs.c (c_common_attribute_table): Add
2765 "omp declare target implicit" attribute.
2766
cd0762f3
RB
27672018-07-12 Richard Biener <rguenther@suse.de>
2768
2769 PR c/86453
2770 * c-attribs.c (handle_packed_attribute): Do not build a variant
2771 type with TYPE_PACKED, instead ignore the attribute if we may
2772 not apply to the original type.
2773
0b27c3ed
JJ
27742018-07-10 Jakub Jelinek <jakub@redhat.com>
2775
2776 PR c++/86443
2777 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
2778 to contain TREE_LIST for both the original class iterator and the
2779 "last" helper var.
2780
e730a0ef
EB
27812018-07-07 Eric Botcazou <ebotcazou@adacore.com>
2782
2783 * c-ada-spec.c (to_ada_name): Remove index parameter.
2784 (pp_ada_tree_identifier): Likewise.
2785 (dump_ada_macros): Adjust call to to_ada_name.
2786 (struct overloaded_name_hash): Delete.
2787 (struct overloaded_name_hasher): Likewise.
2788 (overloaded_names): Likewise.
2789 (compute_overloading_index): Likewise.
2790 (dump_ada_decl_name): Do not call compute_overloading_index and
2791 adjust calls to pp_ada_tree_identifier.
2792 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
2793 (dump_ada_import): Add spc parameter and switch to aspect syntax.
2794 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
2795 (dump_ada_enum_type): Remove type and display_convention parameters.
2796 Adjust calls to pp_ada_tree_identifier.
2797 (dump_ada_node): Likewise and for dump_ada_structure.
2798 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
2799 and tidy up.
2800 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
2801 syntax.
2802 (print_constructor): Adjust call to pp_ada_tree_identifier.
2803 (print_destructor): Likewise.
2804 (dump_ada_declaration): Switch to aspect syntax.
2805 (dump_ada_structure): Likewise and tidy up. Replace display_convention
2806 parameter with nested parameter.
2807 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
2808 (dump_ada_specs): Do not delete overloaded_names table.
2809
8de583fc
PB
28102018-07-06 Peter Bergner <bergner@linux.ibm.com>
2811
2812 PR target/86324
e730a0ef 2813 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
8de583fc
PB
2814 target hook.
2815
09cff37b
NS
28162018-07-05 Nathan Sidwell <nathan@acm.org>
2817
2818 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
2819 NO_IMPLICIT_EXTERN_C.
2820
98086b2b
ML
28212018-06-28 Martin Liska <mliska@suse.cz>
2822
2823 * cppspec.c: Include opt-suggestions.h.
2824
ab20d992
JJ
28252018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
2826 Thomas Schwinge <thomas@codesourcery.com>
829c6349
CLT
2827 Cesar Philippidis <cesar@codesourcery.com>
2828
2829 * c-pragma.h (enum pragma_omp_clause): Add
2830 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
2831 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
2832
f41b7612
JJ
28332018-06-20 Jakub Jelinek <jakub@redhat.com>
2834
2835 PR c++/86210
2836 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
2837 comment.
2838
4252ccd7
MS
28392018-06-18 Martin Sebor <msebor@redhat.com>
2840
2841 PR middle-end/85602
2842 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
2843 nonstring.
2844
e197e64e
KV
28452018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
2846
2847 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
2848
34a7a230
JM
28492018-06-13 Jason Merrill <jason@redhat.com>
2850
5cef3733
JM
2851 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
2852 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
2853 handling.
2854
34a7a230
JM
2855 PR c++/86094 - wrong code with defaulted move ctor.
2856 * c-opts.c (c_common_post_options): Bump the current ABI version to
2857 13. Set warn_abi_version and flag_abi_compat_version to the current
2858 version rather than 0. Fix defaulting flag_abi_compat_version from
2859 warn_abi_version.
2860
bb0f14ae
MS
28612018-06-12 Martin Sebor <msebor@redhat.com>
2862
2863 PR c/85931
2864 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
2865 sizeof source and destination yields the same value.
2866
3713f2e2
ML
28672018-06-12 Martin Liska <mliska@suse.cz>
2868
2869 * c.opt: Make MPX-related options as Deprecated.
2870
4af78ef8
DM
28712018-06-08 David Malcolm <dmalcolm@redhat.com>
2872
2873 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
2874 rather than 0.
2875
31db0fe0
ML
28762018-06-08 Martin Liska <mliska@suse.cz>
2877
2878 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
2879 for MPX (macros, related functions, fields in cgraph_node, ...).
2880 (handle_bnd_legacy): Likewise.
2881 (handle_bnd_instrument): Likewise.
2882 * c.opt: Likewise.
2883
fe16acf2
JJ
28842018-06-06 Jakub Jelinek <jakub@redhat.com>
2885
2886 PR c++/86068
2887 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
2888 __cpp_transactional_memory to 201500 instead of 210500.
2889
4dbdb49b
JM
28902018-06-06 Jason Merrill <jason@redhat.com>
2891
2892 PR c++/85710 - ICE with -Wmemset-elt-size.
2893 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
2894
f8ad043f
JM
28952018-06-01 Jason Merrill <jason@redhat.com>
2896
2897 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
2898 201703.
2899
abc24d93
EB
29002018-06-01 Eric Botcazou <ebotcazou@adacore.com>
2901
2902 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
2903 declaration for a typedef independently of whether the declaration of
2904 the subtype is generated.
2905
d258f4aa
MS
29062018-05-31 Martin Sebor <msebor@redhat.com>
2907
2908 PR c/82063
2909 * c.opt (-Wno-alloc-size-larger-than): New option.
2910
b67b9225
DP
29112018-04-22 David Pagan <dave.pagan@oracle.com>
2912
2913 PR c/55976
2914 * c-opts.c (c_common_post_options): Set default for warn_return_type
ab20d992 2915 for C++/C++ with ObjC extensions only. For C, makes it possible to
b67b9225
DP
2916 differentiate between default (no option), -Wreturn-type, and
2917 -Wno-return-type.
2918
04eb9c55
JM
29192018-05-29 Jason Merrill <jason@redhat.com>
2920
2921 * c.opt (Winit-list-lifetime): New flag.
2922
b0c31bc6
BE
29232018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
2924
2925 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
2926 splay_tree_delete_pointers.
2927
44284983
JJ
29282018-05-26 Jakub Jelinek <jakub@redhat.com>
2929
2930 PR bootstrap/85921
2931 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
2932 noinline variable to workaround broken kernel headers.
2933
b46b715d
JM
29342018-05-18 Jason Merrill <jason@redhat.com>
2935
2936 * c.opt (Wdeprecated-copy): New flag.
2937
40659769
ML
29382018-05-17 Martin Liska <mliska@suse.cz>
2939
2940 * c-warn.c (overflow_warning): Do not use
2941 space in between 'G_' and '('.
2942
403962ea
JM
29432018-05-09 Jason Merrill <jason@redhat.com>
2944
2945 * c-common.c (valid_array_size_p): Add complain parameter.
2946 * c-common.h: ...which defaults to true.
2947
1c9ee609
JJ
29482018-05-11 Jakub Jelinek <jakub@redhat.com>
2949
2950 PR c/85696
2951 * c-omp.c (c_omp_predetermined_sharing): Return
2952 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
2953
19916065
ML
29542018-05-11 Martin Liska <mliska@suse.cz>
2955
92a285c1 2956 PR sanitizer/85556
19916065
ML
2957 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
2958 TREE_LIST values.
2959
79e7b1fe
JJ
29602018-05-10 Jakub Jelinek <jakub@redhat.com>
2961
2962 PR c++/85662
2963 * c-common.h (fold_offsetof_1): Removed.
2964 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
2965 CTX argument defaulted to ERROR_MARK.
2966 * c-common.c (fold_offsetof_1): Renamed to ...
2967 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
2968 argument, convert the pointer constant to TYPE and use size_binop
2969 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
2970 a pointer type. Adjust recursive calls.
2971
86c12f76
EB
29722018-05-10 Eric Botcazou <ebotcazou@adacore.com>
2973
2974 PR c++/85400
2975 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
2976
ee336e84
NS
29772018-05-07 Nathan Sidwell <nathan@acm.org>
2978
2979 * c.opt (ffor-scope): Remove functionality, issue warning.
2980
6c072e21
NS
29812018-05-03 Nathan Sidwell <nathan@acm.org>
2982
2983 * c.opt (ffriend-injection): Remove functionality, issue warning.
2984
2cc7d3a7
DM
29852018-05-01 David Malcolm <dmalcolm@redhat.com>
2986
2987 PR c/84258
2988 * c-format.c (struct format_check_results): Add field
2989 "number_non_char".
2990 (check_format_info): Initialize it, and warn if encountered.
2991 (check_format_arg): Distinguish between wide char and
2992 everything else when detecting arrays of non-char.
2993
7761dfbe
DM
29942018-04-30 David Malcolm <dmalcolm@redhat.com>
2995
2996 * c-format.c (get_corrected_substring): Update for
2997 location_get_source_line returning a char_span. Use a char_span
2998 when handling the prefix of the correction.
2999 * c-indentation.c (get_visual_column): Update for
3000 location_get_source_line returning a char_span.
3001 (get_first_nws_vis_column): Likewise.
3002
62e98ef1
DM
30032018-03-29 David Malcolm <dmalcolm@redhat.com>
3004
3005 PR c++/84269
3006 * known-headers.cc (get_stdlib_header_for_name): Add various names
3007 from <assert.h>, <string.h>, and <memory.h>; add more names from
3008 <stdio.h>.
3009
a7dea617
JJ
30102018-03-27 Jakub Jelinek <jakub@redhat.com>
3011
3012 PR c++/85061
3013 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
3014 get_base_address of the second operand is a VAR_P, rather than the
3015 operand itself, and use gcc_checking_assert instead of gcc_assert.
3016
889a3a30
MP
30172018-03-23 Marek Polacek <polacek@redhat.com>
3018
3019 PR c++/85045
3020 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
3021 <case RDIV_EXPR>: Tweak condition.
3022
452154b9
EB
30232018-03-20 Eric Botcazou <ebotcazou@adacore.com>
3024
3025 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
3026
63ecb626
JJ
30272018-03-16 Jakub Jelinek <jakub@redhat.com>
3028
ce811fc4
JJ
3029 PR c/84909
3030 * c-warn.c (conversion_warning): Replace "to to" with "to" in
3031 diagnostics.
3032
63ecb626
JJ
3033 PR c/84910
3034 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
3035 diagnostics.
3036
a1295eec
RB
30372018-03-16 Richard Biener <rguenther@suse.de>
3038
3039 PR c/84873
3040 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
3041 unshare the possibly folded expression.
3042
919674fb
RB
30432018-03-15 Richard Biener <rguenther@suse.de>
3044
3045 PR c/84873
3046 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
3047
f99309b2
MS
30482018-03-13 Martin Sebor <msebor@redhat.com>
3049
3050 PR tree-optimization/84725
3051 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
3052 with all three narrow character types, including their qualified forms.
3053
e9b9fa4c
MS
30542018-03-12 Martin Sebor <msebor@redhat.com>
3055
3056 PR tree-optimization/83456
ab20d992 3057 * c-common.c (check_function_restrict): Return bool.
e9b9fa4c
MS
3058 Restore checking of bounded built-in functions.
3059 (check_function_arguments): Also return the result
3060 of warn_for_restrict.
ab20d992
JJ
3061 * c-common.c (check_function_restrict): Return bool.
3062 * c-warn.c (warn_for_restrict): Return bool.
e9b9fa4c 3063
0805d020
MP
30642018-03-02 Marek Polacek <polacek@redhat.com>
3065
3066 PR c++/84171
3067 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
3068 is erroneous.
3069
ed2a2f08
TS
30702018-03-02 Thomas Schwinge <thomas@codesourcery.com>
3071
3072 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
3073 function".
3074
90abdde0
MP
30752018-03-01 Marek Polacek <polacek@redhat.com>
3076
3077 PR c++/84639
3078 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
3079 alignment in computation.
3080
c6db43fa
EB
30812018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3082
3083 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
3084 <REAL_TYPE>: Deal specifically with _Float128/__float128.
3085
9e25c7ed
EB
30862018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3087
3088 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
3089 (is_char_array): Take a type instead of a declaration.
3090 (dump_ada_array_type): Likewise.
3091 (is_simple_enum): Minor tweak.
3092 (dump_ada_enum_type): New function extracted from...
3093 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
3094 <INTEGER_TYPE>: Remove unreachable code.
3095 <RECORD_TYPE>: Likewise. Minor tweaks.
3096 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
3097 <ENUMERAL_TYPE>: New case.
3098 <RECORD_TYPE>: Factor out common code.
3099 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
3100 Minor tweaks. Deal with enumeral types.
3101 (dump_ada_structure): Minor tweaks.
3102
09de3550
EB
31032018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3104
3105 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
3106 address for incomplete structures.
3107 (dump_forward_type): Do not bail out for incomplete structures.
3108 (dump_ada_declaration): Do not special-case incomplete structures
3109 for subtypes. Dump them as null records for types.
3110
095d8d4b
EB
31112018-02-28 Eric Botcazou <ebotcazou@adacore.com>
3112
3113 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
3114 (is_char_array): Fix formatting.
3115 (dump_template_types): Likewise.
3116 (dump_generic_ada_node): Rename into...
3117 (dump_ada_node): ...this.
3118 <POINTER_TYPE>: Remove superfluous space. Use generic address for
3119 incomplete structures and not for empty structures. Do not use it
3120 when forward declarations are needed.
3121 (dump_forward_type): New function.
3122 (dump_nested_types): Remove FORWARD parameter. Do not consider
3123 TREE_VISITED and do not generate a forward declaration. Only dump
3124 original nested types for nested declaration.
3125 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
3126 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
3127 <RECORD_TYPE>: Do not consider TREE_VISITED.
3128 (dump_ada_declaration): Use booleans and fix formatting throughout.
3129 <TYPE_DECL>: Skip incomplete structures and not empty structures.
3130 Call dump_forward_type instead of dump_nested_types for a typedef.
3131 Remove superfluous check and adjust call to dump_nested_types.
3132 <POINTER_TYPE>: Call dump_forward_type and fall through.
3133 (dump_ada_struct_decl): Rename into...
3134 (dump_ada_structure): ...this. Do not special-case empty structures.
3135
d4cfd486
MS
31362018-02-27 Martin Sebor <msebor@redhat.com>
3137
3138 PR c++/83871
3139 * c.opt (-Wmissing-attributes): New option.
3140
b22dbd03
ML
31412018-02-21 Martin Liska <mliska@suse.cz>
3142
3143 * c.opt (Wcatch-value=): Add IntegerRange.
3144
883dfe2a
JM
31452018-02-15 Jason Merrill <jason@redhat.com>
3146
3147 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
3148
0444aa9c
NS
31492018-02-09 Nathan Sidwell <nathan@acm.org>
3150
3151 PR c/84293
3152 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
3153 arg.
3154 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
3155 arg. Adjust.
3156
cea71f0a
MS
31572018-02-09 Martin Sebor <msebor@redhat.com>
3158
3159 PR lto/84212
3160 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
3161 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
3162 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
3163 (-Wstrict-overflow, -Wsuggest-attribute): Same.
3164 (-Wuninitialized): Same.
3165
8c8b7be5
EB
31662018-02-09 Eric Botcazou <ebotcazou@adacore.com>
3167
3168 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
3169 keyword for components.
3170
7c30b12a
PC
31712018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
3172
3173 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
3174
eece7fe5
JK
31752018-02-02 Julia Koval <julia.koval@intel.com>
3176
3177 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
3178
7d07a93a
MP
31792018-01-29 Marek Polacek <polacek@redhat.com>
3180
3181 PR c/83966
3182 * c-format.c (check_function_format): Check current_function_decl.
3183
53723269
JJ
31842018-01-27 Jakub Jelinek <jakub@redhat.com>
3185
3186 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
3187 argument.
3188 (LAZY_HEX_FP_VALUES_CNT): Define.
3189 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
3190 values rather than just 12.
3191 (builtin_define_with_hex_fp_value): Likewise.
3192
7365279f
BK
31932018-01-18 Boris Kolpackov <boris@codesynthesis.com>
3194
92a285c1
ML
3195 PR other/70268
3196 * c.opt (-fmacro-prefix-map): New option.
3197 * c-opts.c (c_common_handle_option): Handle it.
3198 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
3199 * c-ppoutput.c (init_pp_output): Likewise.
7365279f 3200
bb9869d5
DM
32012018-01-17 David Malcolm <dmalcolm@redhat.com>
3202
3203 PR c++/83814
3204 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
3205
68dc87c3
EB
32062018-01-10 Eric Botcazou <ebotcazou@adacore.com>
3207
3208 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
3209 Skip 'f' and 'F' characters if it is true.
3210 (store_ada_macro): Minor tweak.
3211 (dump_ada_macros) <CPP_COMMENT>: Likewise.
3212 <CPP_WSTRING>: Likewise.
3213 <CPP_STRING>: Output '&' in the buffer if not the first string.
3214 <CPP_NUMBER>: Adjust calls to dump_number.
3215
9a004410
DM
32162018-01-10 David Malcolm <dmalcolm@redhat.com>
3217
3218 PR c++/43486
3219 * c-common.c: Include "selftest.h".
3220 (get_atomic_generic_size): Perform the test for integral type
3221 before the range test for any integer constant, fixing indentation
3222 of braces. Call fold_for_warn before testing for an INTEGER_CST.
3223 (reject_gcc_builtin): Strip any location wrapper from EXPR.
3224 (selftest::test_fold_for_warn): New function.
3225 (selftest::c_common_c_tests): New function.
3226 (selftest::c_family_tests): Call it, and
3227 selftest::c_pretty_print_c_tests.
3228 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
3229 * c-format.c (check_format_arg): Convert VAR_P check to a
3230 fold_for_warn.
3231 * c-pretty-print.c: Include "selftest.h".
3232 (pp_c_cast_expression): Don't print casts for location wrappers.
3233 (selftest::assert_c_pretty_printer_output): New function.
3234 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
3235 (selftest::test_location_wrappers): New function.
3236 (selftest::c_pretty_print_c_tests): New function.
3237 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
3238
5c0caeb3
RS
32392018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
3240 Alan Hayward <alan.hayward@arm.com>
3241 David Sherwood <david.sherwood@arm.com>
3242
3243 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
3244
73a699ae
RS
32452018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
3246 Alan Hayward <alan.hayward@arm.com>
3247 David Sherwood <david.sherwood@arm.com>
3248
3249 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
3250 as polynomial.
3251
928686b1
RS
32522018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
3253 Alan Hayward <alan.hayward@arm.com>
3254 David Sherwood <david.sherwood@arm.com>
3255
3256 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
3257 (convert_vector_to_array_for_subscript): Handle polynomial
3258 TYPE_VECTOR_SUBPARTS.
3259 (c_common_type_for_mode): Check valid_vector_subparts_p.
3260 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
3261 VECTOR_CST_NELTS.
3262
85ec4feb
JJ
32632018-01-03 Jakub Jelinek <jakub@redhat.com>
3264
3265 Update copyright years.
3266
170a8bd6 32672017-12-22 Mike Stump <mikestump@comcast.net>
92a285c1 3268 Eric Botcazou <ebotcazou@adacore.com>
170a8bd6
EB
3269
3270 * c-pragma.c (init_pragma): Register pragma GCC unroll.
3271 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
3272
ab20d992 32732017-12-22 Alexandre Oliva <aoliva@redhat.com>
18408e96
AO
3274
3275 PR debug/83527
3276 PR debug/83419
3277 * c-semantics.c (only_debug_stmts_after_p): New.
3278 (pop_stmt_list): Clear side effects in debug-only stmt list.
3279 Check for single nondebug stmt followed by debug stmts only.
3280
c12d20d4
AO
32812017-12-21 Alexandre Oliva <aoliva@redhat.com>
3282
3283 PR debug/83419
3284 * c-semantics.c (pop_stmt_list): Propagate side effects from
3285 single nondebug stmt to container list.
3286
01512446
JJ
32872017-12-19 Jakub Jelinek <jakub@redhat.com>
3288
3289 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
3290 conditions with typical order conditions.
3291
82cfbd01
MP
32922017-12-18 Marek Polacek <polacek@redhat.com>
3293
3294 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
3295 not in effect.
3296
99da11ec
MS
32972017-12-17 Martin Sebor <msebor@redhat.com>
3298
3299 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
3300 an error for attribute warn_if_not_aligned.
3301
cc8bea0a
MS
33022017-12-16 Martin Sebor <msebor@redhat.com>
3303
3304 PR tree-optimization/78918
3305 * c-common.c (check_function_restrict): Avoid checking built-ins.
3306 * c.opt (-Wrestrict): Include in -Wall.
3307
4849deb1
JJ
33082017-12-15 Jakub Jelinek <jakub@redhat.com>
3309
3310 * c-attribs.c (c_common_attribute_table,
3311 c_common_format_attribute_table): Swap affects_type_identity
3312 and handler fields, adjust comments.
3313
c65e18d3
BE
33142017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
3315
3316 * c.opt (Wcast-function-type): New warning option.
3317 * c-lex.c (get_fileinfo): Avoid warning.
3318 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
3319
2004617a
QZ
33202017-12-14 Qing Zhao <qing.zhao@oracle.com>
3321
7365279f 3322 PR middle_end/79538
2004617a
QZ
3323 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
3324 Adjust the size of buf1 and buf2, add a new buf to avoid
3325 format-overflow warning.
3326
ab20d992 33272017-12-12 Alexandre Oliva <aoliva@redhat.com>
96a95ac1
AO
3328
3329 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
3330 subsequent statement list.
3331
5d9ae53d
MS
33322017-12-07 Martin Sebor <msebor@redhat.com>
3333
3334 PR c/81544
3335 PR c/81566
3336 * c-attribs.c (attr_aligned_exclusions): New array.
3337 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
3338 (attr_common_exclusions, attr_const_pure_exclusions): Same.
3339 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
3340 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
3341 (attr_warn_unused_result_exclusions): Same.
3342 (handle_hot_attribute, handle_cold_attribute): Simplify.
3343 (handle_const_attribute): Warn on function returning void.
3344 (handle_pure_attribute): Same.
3345 (handle_aligned_attribute): Diagnose conflicting attribute
3346 specifications.
3347 * c-warn.c (diagnose_mismatched_attributes): Simplify.
3348
c79144f8
DM
33492017-12-06 David Malcolm <dmalcolm@redhat.com>
3350
3351 PR c/83236
3352 * c-common.c (selftest::c_family_tests): Call
3353 selftest::c_spellcheck_cc_tests.
3354 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
3355 * c-spellcheck.cc: Include "selftest.h".
3356 (name_reserved_for_implementation_p): New function.
3357 (should_suggest_as_macro_p): New function.
3358 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
3359 should_suggest_as_macro_p and call it.
3360 (selftest::test_name_reserved_for_implementation_p): New function.
3361 (selftest::c_spellcheck_cc_tests): New function.
3362 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
3363
613bc14f
DM
33642017-12-06 David Malcolm <dmalcolm@redhat.com>
3365
3366 * c-spellcheck.cc: New file, taken from macro-handling code in
3367 spellcheck-tree.c.
3368 * c-spellcheck.h: New file, taken from macro-handling code in
3369 spellcheck-tree.h.
3370
e76c7157
JJ
33712017-12-01 Jakub Jelinek <jakub@redhat.com>
3372
3373 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
3374 attribute.
3375 (handle_simd_attribute): Don't check for "cilk simd function"
3376 attribute. Reindent, formatting changes.
3377
b0da4034
JK
33782017-11-30 Julia Koval <julia.koval@intel.com>
3379
3380 * c-common.h (inv_list): Remove.
3381
058f0b9e
JJ
33822017-11-28 Jakub Jelinek <jakub@redhat.com>
3383
3384 PR sanitizer/81275
3385 * c-common.c (c_switch_covers_all_cases_p_1,
3386 c_switch_covers_all_cases_p): New functions.
3387 * c-common.h (c_switch_covers_all_cases_p): Declare.
3388
5e9d6aa4 33892017-11-28 Julia Koval <julia.koval@intel.com>
92a285c1 3390 Sebastian Peryt <sebastian.peryt@intel.com>
5e9d6aa4
JK
3391
3392 * array-notation-common.c: Delete.
3393 * c-cilkplus.c: Ditto.
3394 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
3395 * c-common.def (ARRAY_NOTATION_REF): Remove.
3396 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
3397 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
3398 c_validate_cilk_plus_loop, cilkplus_an_parts,
3399 cilk_ignorable_spawn_rhs_op,
3400 cilk_recognize_spawn): Remove.
3401 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
3402 * c-omp.c: Remove CILK_SIMD check.
3403 * c-pragma.c: Ditto.
3404 * c-pragma.h: Remove CILK related pragmas.
3405 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
3406 ARRAY_NOTATION_REF condition.
3407 (c_pretty_printer::expression): Ditto.
3408 * c.opt (fcilkplus): Remove.
3409 * cilk.c: Delete.
3410
1af4ebf5
MG
34112017-11-21 Marc Glisse <marc.glisse@inria.fr>
3412
3413 * c-pretty-print.c (pp_c_additive_expression,
3414 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
3415
d44ed508
JJ
34162017-11-21 Jakub Jelinek <jakub@redhat.com>
3417
7d2f0f9b
JJ
3418 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
3419
d44ed508
JJ
3420 PR c++/83059
3421 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
3422 instead of tree_to_uhwi, formatting fix.
3423
26edace6
DM
34242017-11-20 David Malcolm <dmalcolm@redhat.com>
3425
3426 PR c/81404
3427 * known-headers.cc: New file, based on material from c/c-decl.c.
3428 (suggest_missing_header): Copied as-is.
3429 (get_stdlib_header_for_name): New, based on get_c_name_hint but
3430 heavily edited to add C++ support. Add some knowledge about
3431 <limits.h>, <stdint.h>, and <wchar.h>.
3432 * known-headers.h: Likewise.
3433
6c7a259b
DM
34342017-11-20 David Malcolm <dmalcolm@redhat.com>
3435
3436 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
3437 (lookup_name_fuzzy): Likewise. Convert return type from
3438 const char * to name_hint. Add location_t param.
3439 * name-hint.h: New header.
3440
f9c59f7e
JJ
34412017-11-19 Jakub Jelinek <jakub@redhat.com>
3442
3443 PR c/66618
3444 PR c/69960
3445 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
3446
1e39313a
JM
34472017-11-16 Joseph Myers <joseph@codesourcery.com>
3448
3449 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
3450 expected publication date of C17.
3451 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
3452
3ca0dc60
JM
34532017-11-15 Joseph Myers <joseph@codesourcery.com>
3454
3455 PR c/81156
3456 * c-common.c (c_common_reswords): Add __builtin_tgmath.
3457 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
3458
025d57f0
MS
34592017-11-10 Martin Sebor <msebor@redhat.com>
3460
3461 PR c/81117
3462 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
3463 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
3464 * c.opt (-Wstringop-truncation): New option.
3465
1b6fa695
ML
34662017-11-06 Martin Liska <mliska@suse.cz>
3467
3468 PR middle-end/82404
3469 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
3470 FE.
3471 * c.opt: Set default value of warn_return_type.
3472
64a5912c
DM
34732017-10-31 David Malcolm <dmalcolm@redhat.com>
3474
3475 * c-common.c (binary_op_error): Update for renaming of
3476 error_at_rich_loc.
3477 (c_parse_error): Likewise.
3478 * c-warn.c (warn_logical_not_parentheses): Likewise for
3479 renaming of inform_at_rich_loc.
3480 (warn_for_restrict): Likewise for renaming of
3481 warning_at_rich_loc_n.
3482
c76dc9c3
JM
34832017-10-30 Joseph Myers <joseph@codesourcery.com>
3484
3485 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
3486 * c-opts.c (set_std_c17): New function.
3487 (c_common_init_options): Use gnu17 as default C version.
3488 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
3489
ee5fd23a
MM
34902017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
3491
3492 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
3493 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
3494 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
3495 __FP_FAST_FMA<N>X.
3496
d1047465
MP
34972017-10-23 Marek Polacek <polacek@redhat.com>
3498
3499 PR c/82681
3500 * c-warn.c (warnings_for_convert_and_check): Fix typos.
3501
9e878cf1
EB
35022017-10-19 Eric Botcazou <ebotcazou@adacore.com>
3503
3504 * c-common.c (check_builtin_function_arguments): Also check arguments
3505 of __builtin_alloca_with_align_and_max.
3506
89b6abbb
DM
35072017-10-17 David Malcolm <dmalcolm@redhat.com>
3508
3509 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
3510 rather than NULL to format_warning_va.
3511 (check_format_types): Likewise when calling format_type_warning.
3512 Remove code to extract source_ranges and source_range * in favor
3513 of just a location_t.
3514 (format_type_warning): Convert source_range * param to a
3515 location_t.
3516
39382c09
JJ
35172017-10-13 Jakub Jelinek <jakub@redhat.com>
3518
3519 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
3520 [LR]SHIFT_EXPR.
3521
62e1c678
DM
35222017-10-12 David Malcolm <dmalcolm@redhat.com>
3523
3524 * c-common.c (enum missing_token_insertion_kind): New enum.
3525 (get_missing_token_insertion_kind): New function.
3526 (maybe_suggest_missing_token_insertion): New function.
3527 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
3528
b90c9338
NS
35292017-10-11 Nathan Sidwell <nathan@acm.org>
3530
3531 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
3532 (c_common_handle_option): Update incpath_kind names.
3533
3a266bcd
ML
35342017-10-11 Martin Liska <mliska@suse.cz>
3535
3536 PR sanitizer/82490
3537 * c-attribs.c (handle_no_sanitize_attribute): Report directly
3538 Wattributes warning.
3539
8e6cdc90
RS
35402017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
3541
3542 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
3543 operating on trees as wide_ints.
3544 * c-common.c (pointer_int_sum): Likewise.
3545 * c-pretty-print.c (pp_c_integer_constant): Likewise.
3546 * c-warn.c (match_case_to_enum_1): Likewise.
3547 (c_do_switch_warnings): Likewise.
3548 (maybe_warn_shift_overflow): Likewise.
3549
802b38c9
JJ
35502017-10-10 Jakub Jelinek <jakub@redhat.com>
3551
3552 PR c/82437
3553 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
3554 instead of wide_int::from.
3555
4e34b338
JJ
35562017-10-06 Jakub Jelinek <jakub@redhat.com>
3557
3558 PR c/82437
3559 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
3560 using to_widest use wide_int with the larger of the two precisions.
3561
4bc4b2b4
BE
35622017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
3563
3564 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
3565 functions.
3566
a1488398
RS
35672017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
3568
3569 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
3570 when combining the original unconverted comparison operands.
3571
01c9fb68
JJ
35722017-09-29 Jakub Jelinek <jakub@redhat.com>
3573
3574 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
3575 attribute.
3576
6e3e8419
EB
35772017-09-29 Eric Botcazou <ebotcazou@adacore.com>
3578
3579 * c-ada-spec.c (to_ada_name): Add index parameter.
3580 (pp_ada_tree_identifier): Likewise.
3581 (dump_ada_macros): Adjust call to to_ada_name.
3582 (struct overloaded_name_hash): New type.
3583 (struct overloaded_name_hasher): Likewise.
3584 (overloaded_names): New hash table.
3585 (compute_overloading_index): New function.
3586 (dump_ada_decl_name): Call it and pass the result to
3587 pp_ada_tree_identifier.
3588 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
3589 (dump_ada_function_declaration): Likewise.
3590 (dump_generic_ada_node): Likewise.
3591 (print_constructor): Likewise.
3592 (print_destructor): Likewise.
3593 (dump_ada_specs): Delete overloaded_names table.
3594
79310774
EB
35952017-09-29 Eric Botcazou <ebotcazou@adacore.com>
3596
3597 * c-ada-spec.c (max_ada_macros): Move around.
3598 (store_ada_macro_index): Likewise.
3599 (source_file): Rename into...
3600 (macro_source_file): ...this.
3601 (count_ada_macro): Move around.
3602 (store_ada_macro): Likewise.
3603 (compare_macro): Likewise.
3604 (print_ada_macros): Merge in...
3605 (dump_ada_macros): ...this.
3606 (source_file_base): Rename into...
3607 (current_source_file): ...this.
3608 (print_comment): Move around.
3609 (dump_ada_nodes): Call dump_ada_declaration directly.
3610 (struct with): Change type of limited field to bool.
3611 (append_withs): Change type of limited_access parameter to bool.
3612 (pp_ada_tree_identifie): Likewise.
3613 (dump_ada_decl_nam): Likewise.
3614 (dump_generic_ada_node): Likewise. Do not print the return type.
3615 (to_ada_name): Change type of space_found parameter to bool.
3616 (dump_ada_function_declaration): Return void and change type of
3617 parameters to bool. Also print the return type for a function.
3618 (print_ada_methods): Rename into...
3619 (dump_ada_methods): ...this.
3620 (print_ada_declaration): Rename into ...
3621 (dump_ada_declaration): ...this. Do not print the return type.
3622 (print_ada_struct_decl): Rename into...
3623 (dump_ada_struct_decl): ...this.
3624
7d386d45
JJ
36252017-09-29 Jakub Jelinek <jakub@redhat.com>
3626
3627 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
3628 rather than DECL_INITIAL.
3629 (common_handle_aligned_attribute): Likewise.
3630
ab20d992 36312017-09-20 Alexandre Oliva <aoliva@redhat.com>
9ed32e27
AO
3632
3633 * c.opt (gen-decls): Add RejectNegative.
3634
026a79f7
AS
36352017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
3636 Jakub Jelinek <jakub@redhat.com>
3637
3638 Add support for -std=c++2a.
3639 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
3640 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
3641 * c-opts.c (set_std_cxx2a): New.
3642 (c_common_handle_option): Set options when -std=c++2a is enabled.
3643 (c_common_post_options): Adjust comments.
3644 (set_std_cxx14, set_std_cxx17): Likewise.
3645
4a8ca690
EB
36462017-09-15 Eric Botcazou <ebotcazou@adacore.com>
3647
3648 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
3649 message for non-uniform endianness and issue a warning in C++.
3650
7b936140
JJ
36512017-09-15 Jakub Jelinek <jakub@redhat.com>
3652
3653 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
3654 (Wc++17-compat): Change from undocumented alias to option.
3655 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
3656 change C++1z to C++17 in description.
3657 (std=c++1z, std=gnu++1z): Change from option to undocumented
3658 deprecated alias.
3659 (std=c++17, std=gnu++17): Change from undocumented alias to option.
3660 Adjust description.
3661 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
3662 * c-opts.c (set_std_cxx1z): Rename to ...
3663 (set_std_cxx17): ... this.
3664 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
3665 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
7365279f 3666 caller.
7b936140
JJ
3667 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
3668 comments.
3669
12263f13
L
36702017-09-12 H.J. Lu <hongjiu.lu@intel.com>
3671
3672 * c-attribs.c (common_handle_aligned_attribute): Don't warn
3673 function alignment if warn_if_not_aligned_p is true.
3674
6836632e
NS
36752017-09-12 Nathan Sidwell <nathan@acm.org>
3676
3677 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
3678 resort_sorted_fields): Move to c/c-decl.c.
3679 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
3680 (struct sorted_fields_type): Move to c/c-lang.h.
3681
019bf9ad
JW
36822017-09-09 Jonathan Wakely <jwakely@redhat.com>
3683
3684 PR c++/81852
3685 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
3686
bc7fe952
MP
36872017-09-04 Marek Polacek <polacek@redhat.com>
3688
3689 PR c/81783
3690 * c-warn.c (warn_tautological_bitwise_comparison): New function.
3691 (warn_tautological_cmp): Call it.
3692
ab20d992 36932017-09-01 Boris Kolpackov <boris@codesynthesis.com>
de7c2c6a
BK
3694
3695 * c-opts.c (c_common_finish): Write dependency information even if
3696 there are errors.
3697
d2e05fcb
JJ
36982017-09-01 Jakub Jelinek <jakub@redhat.com>
3699
3700 PR c/81887
3701 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
3702 (omp_pragmas_simd): ... here.
3703 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
3704 create new clauses list containing just simd clause.
3705
18e2a8b8
RS
37062017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3707 Alan Hayward <alan.hayward@arm.com>
3708 David Sherwood <david.sherwood@arm.com>
3709
3710 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
3711 into scalar_mode_supported_p call.
3712 (handle_mode_attribute): Update call to scalar_mode_supported_p.
3713
16d22000
RS
37142017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3715 Alan Hayward <alan.hayward@arm.com>
3716 David Sherwood <david.sherwood@arm.com>
3717
3718 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
3719 for the mode iterator.
3720
b397965c
RS
37212017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3722 Alan Hayward <alan.hayward@arm.com>
3723 David Sherwood <david.sherwood@arm.com>
3724
3725 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
3726 * c-common.c (c_build_vec_perm_expr): Likewise.
3727
357b7604
RS
37282017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3729 Alan Hayward <alan.hayward@arm.com>
3730 David Sherwood <david.sherwood@arm.com>
3731
3732 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
3733
e05c94ba
RS
37342017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3735 Alan Hayward <alan.hayward@arm.com>
3736 David Sherwood <david.sherwood@arm.com>
3737
3738 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
3739 before calling targetm.addr_space.valid_pointer_mode.
3740
5c20c4af
RS
37412017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3742 Alan Hayward <alan.hayward@arm.com>
3743 David Sherwood <david.sherwood@arm.com>
3744
3745 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
3746
c94843d2 37472017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
92a285c1
ML
3748 Alan Hayward <alan.hayward@arm.com>
3749 David Sherwood <david.sherwood@arm.com>
c94843d2
RS
3750
3751 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
3752 iterators.
3753 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
3754
4e10a5a7
RS
37552017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
3756 Alan Hayward <alan.hayward@arm.com>
3757 David Sherwood <david.sherwood@arm.com>
3758
3759 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
3760 case statements.
3761
130fcab0
ML
37622017-08-29 Martin Liska <mliska@suse.cz>
3763
3764 PR other/39851
3765 * c-common.c (parse_optimize_options): Add argument to function
3766 call.
3767 * c-pragma.c (handle_pragma_diagnostic): Likewise.
3768
14e18d71
DM
37692017-08-24 David Malcolm <dmalcolm@redhat.com>
3770
3771 * c-lex.c (interpret_float): Use token location
3772 when building an EXCESS_PRECISION_EXPR.
3773
2f687306
DM
37742017-08-21 David Malcolm <dmalcolm@redhat.com>
3775
3776 * c-common.c (check_function_arguments): Add "arglogs" param; pass
3777 it to check_function_format.
3778 * c-common.h (check_function_arguments): Add vec<location_t> *
3779 param.
3780 (check_function_format): Likewise.
3781 * c-format.c (struct format_check_context): Add field "arglocs".
3782 (check_function_format): Add param "arglocs"; pass it to
3783 check_format_info.
ab20d992 3784 (check_format_info): Add param "arglocs"; use it to initialize
2f687306
DM
3785 new field of format_ctx.
3786 (check_format_arg): Pass format_ctx->arglocs to new param of
3787 check_format_info_main.
3788 (class argument_parser): New field "arglocs".
3789 (argument_parser::argument_parser): Add "arglocs_" param and use
3790 it to initialize new field.
3791 (argument_parser::check_argument_type): Pass new arglocs field to
3792 check_format_types.
3793 (check_format_info_main): Add param "arglocs", and use it when
3794 constructing arg_parser.
3795 (check_format_types): Add param "arglocs"; use it if non-NULL when
3796 !EXPR_HAS_LOCATION (cur_param) to get at location information.
3797
00aa1fa2
L
37982017-08-18 H.J. Lu <hongjiu.lu@intel.com>
3799
3800 PR c/53037
3801 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
3802 (c_common_attribute_table): Add warn_if_not_aligned.
3803 (handle_aligned_attribute): Renamed to ...
3804 (common_handle_aligned_attribute): Remove argument, name, and add
3805 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
3806 (handle_aligned_attribute): New.
3807 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
3808
27be025d
MS
38092017-08-14 Martin Sebor <msebor@redhat.com>
3810
3811 PR c/81117
3812 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
3813 (handle_nonstring_attribute): New function.
3814
da67acb9
MS
38152017-08-14 Martin Sebor <msebor@redhat.com>
3816
3817 PR c/81117
3818 * c-format.h (T89_G): New macro.
3819 * c-format.c (local_gcall_ptr_node): New variable.
3820 (init_dynamic_diag_info): Initialize it.
3821
a8b522b4
ML
38222017-08-11 Martin Liska <mliska@suse.cz>
3823
3824 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
3825 TARGET_SUPPORTS_ALIASES.
3826
32129a17
DM
38272017-08-10 David Malcolm <dmalcolm@redhat.com>
3828
3829 * c-common.c (c_parse_error): Add rich_location * param, using it
3830 rather implicitly using input_location.
3831 * c-common.h (c_parse_error): Add rich_location * param.
3832
30af3a2b
MP
38332017-08-09 Marek Polacek <polacek@redhat.com>
3834
3835 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
3836 (c_common_truthvalue_conversion): Likewise.
3837 * c-omp.c (c_finish_omp_atomic): Likewise.
3838 * c-common.h (build_binary_op): Update declaration.
3839
314e6352
ML
38402017-08-08 Martin Liska <mliska@suse.cz>
3841
3842 * c-ada-spec.c: Include header files.
3843 * c-ubsan.c: Likewise.
3844 * c-warn.c: Likewise.
3845
56b5041c
JJ
38462017-08-07 Jakub Jelinek <jakub@redhat.com>
3847
3848 PR c/69389
3849 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
3850
db440138
EB
38512017-08-07 Eric Botcazou <ebotcazou@adacore.com>
3852
3853 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
3854 (print_ada_methods): Likewise.
3855 (print_ada_declaration): Likewise.
3856
577eec56
ML
38572017-08-07 Martin Liska <mliska@suse.cz>
3858
3859 * array-notation-common.c: Add new includes.
3860 * c-format.c( handle_format_attribute): Canonicalize a format
3861 function name.
3862 * c-lex.c (c_common_has_attribute): Canonicalize name of an
3863 attribute.
3864 * c-pretty-print.c: Add new include.
3865
b854df3c
EB
38662017-08-05 Eric Botcazou <ebotcazou@adacore.com>
3867
3868 * c-ada-spec.c (has_static_fields): Look only into variables.
3869 (print_constructor): Add TYPE parameter and use it for the name.
3870 (print_destructor): Likewise.
3871 (print_ada_declaration): Adjust to new constructor/destructor names.
3872 Adjust calls to print_constructor and print_destructor.
3873 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
3874 Look only into variables in the final loop.
3875
9f2cb25e
EB
38762017-08-01 Eric Botcazou <ebotcazou@adacore.com>
3877
3878 * c-ada-spec.c (has_static_fields): Look only into fields.
3879 (dump_generic_ada_node): Small tweak.
3880 (dump_nested_types): Look only into fields.
3881 (print_ada_declaration): Look only into methods. Small tweak.
3882 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
3883
f4bcd9eb
EB
38842017-08-01 Eric Botcazou <ebotcazou@adacore.com>
3885
3886 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
3887 (dump_ada_function_declaration): Likewise.
3888 (dump_generic_ada_node): Likewise.
3889 (print_ada_declaration): Add support for const-qualified variables.
3890
f34ebeb2
ML
38912017-07-31 Martin Liska <mliska@suse.cz>
3892
3893 PR sanitize/81530
3894 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
3895 Guard condition with flag_sanitize_p also with current_function_decl
3896 non-null equality.
3897 (ubsan_maybe_instrument_reference_or_call): Likewise.
3898
218e5d04
UB
38992017-07-30 Uros Bizjak <ubizjak@gmail.com>
3900
3901 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
3902
942047f2
EB
39032017-07-29 Eric Botcazou <ebotcazou@adacore.com>
3904
3905 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
3906 for enumeral types.
3907 (print_ada_declaration): Add missing guard for record types.
3908
a40ff0ae
JJ
39092017-07-27 Jakub Jelinek <jakub@redhat.com>
3910
3911 PR c/45784
3912 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
3913 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
3914 new COMPOUND_EXPRs around the rhs of the comparison.
3915
06bd22f6
MP
39162017-07-27 Marek Polacek <polacek@redhat.com>
3917
3918 PR c/81417
3919 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
3920 the types.
3921
036ea399
JJ
39222017-07-27 Jakub Jelinek <jakub@redhat.com>
3923
3924 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
3925 (handle_noipa_attribute): New function.
3926
417ca011
TD
39272017-07-07 Torsten Duwe <duwe@suse.de>
3928
3929 * c-attribs.c (c_common_attribute_table): Add entry for
3930 "patchable_function_entry".
3931
5aaa8fb4
NS
39322017-07-20 Nathan Sidwell <nathan@acm.org>
3933
3934 Remove TYPE_METHODS.
3935 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
3936 dump_ada_template, print_ada_methods,
3937 print_ada_declaration): Member fns are on TYPE_FIELDS.
3938
ff22eb12
NS
39392017-07-18 Nathan Sidwell <nathan@acm.org>
3940
3941 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
3942
eea77d1f
DM
39432017-07-14 David Malcolm <dmalcolm@redhat.com>
3944
3945 * c-common.c (try_to_locate_new_include_insertion_point): New
3946 function.
3947 (per_file_includes_t): New typedef.
3948 (added_includes_t): New typedef.
3949 (added_includes): New variable.
3950 (maybe_add_include_fixit): New function.
3951 * c-common.h (maybe_add_include_fixit): New decl.
3952
281ac396
MS
39532017-07-10 Martin Sebor <msebor@redhat.com>
3954
3955 PR other/81345
3956 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
3957
b6f43128
DM
39582017-07-06 David Malcolm <dmalcolm@redhat.com>
3959
3960 * c-common.c (selftest::c_family_tests): New.
3961 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
3962 (selftest::c_family_tests): New decl.
3963
efbf55b0
MP
39642017-07-04 Marek Polacek <polacek@redhat.com>
3965
3966 PR c/81231
3967 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
3968 types.
3969
6c86bd88
MP
39702017-07-04 Marek Polacek <polacek@redhat.com>
3971
3972 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
3973
17a7218b
ML
39742017-06-28 Martin Liska <mliska@suse.cz>
3975
3976 PR ipa/81128
3977 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
3978 to a function declaration.
3979
63010089
ML
39802017-06-28 Martin Liska <mliska@suse.cz>
3981
3982 PR driver/79659
3983 * c.opt: Add IntegerRange to various options.
3984
3e2becc4
MP
39852017-06-26 Marek Polacek <polacek@redhat.com>
3986
3987 PR c/80116
3988 * c-common.h (warn_for_multistatement_macros): Declare.
3989 * c-warn.c: Include "c-family/c-indentation.h".
3990 (warn_for_multistatement_macros): New function.
3991 * c.opt (Wmultistatement-macros): New option.
3992 * c-indentation.c (guard_tinfo_to_string): No longer static.
3993 Change the parameter type to "enum rid". Handle RID_SWITCH.
3994 * c-indentation.h (guard_tinfo_to_string): Declare.
3995
2db9b7cd
MG
39962017-06-23 Marc Glisse <marc.glisse@inria.fr>
3997
3998 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
3999
c3684b7b
MS
40002017-06-15 Martin Sebor <msebor@redhat.com>
4001
4002 PR c++/80560
4003 * c.opt (-Wclass-memaccess): New option.
4004
e72c4afd
BK
40052017-06-14 Boris Kolpackov <boris@codesynthesis.com>
4006
4007 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
4008
8a516588
MP
40092017-06-13 Marek Polacek <polacek@redhat.com>
4010
4011 PR objc/80949
4012 * c-warn.c (do_warn_duplicated_branches): Return if any of the
4013 branches is null.
4014
45b2222a
ML
40152017-06-13 Martin Liska <mliska@suse.cz>
4016
4017 PR sanitize/78204
4018 * c-attribs.c (add_no_sanitize_value): New function.
4019 (handle_no_sanitize_attribute): Likewise.
4020 (handle_no_sanitize_address_attribute): Use the function.
4021 (handle_no_sanitize_thread_attribute): New function.
4022 (handle_no_address_safety_analysis_attribute): Use
4023 add_no_sanitize_value.
4024 (handle_no_sanitize_undefined_attribute): Likewise.
4025 * c-common.h: Declare new functions.
4026 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
4027 (ubsan_instrument_shift): Likewise.
4028 (ubsan_instrument_bounds): Likewise.
4029 (ubsan_maybe_instrument_array_ref): Likewise.
4030 (ubsan_maybe_instrument_reference_or_call): Likewise.
4031
a01f151f
JM
40322017-06-11 Jason Merrill <jason@redhat.com>
4033
4034 * c-ada-spec.c, c-pragma.c: Use id_equal.
4035
3de4ac6d
MP
40362017-06-04 Marek Polacek <polacek@redhat.com>
4037
4038 PR c/80919
4039 * c-format.c (matching_type_p): Return false if any of the types
4040 requires structural equality.
4041
2474f48f
MS
40422017-06-02 Martin Sebor <msebor@redhat.com>
4043
4044 PR c/80892
4045 * c-warn.c (conversion_warning): Use -Wconversion for integer
4046 conversion and -Wfloat-conversion for floating one.
4047
40ffd95f
BE
40482017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
4049
4050 * c.opt (Wsizeof-pointer-div): New warning option.
4051
3fa4634c
VR
40522017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
4053
4054 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
4055 (Wcatch-value=1): Enable by -Wall.
4056
f012c8ef
DM
40572017-05-30 David Malcolm <dmalcolm@redhat.com>
4058
4059 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
4060 format_chars.
4061 * c.opt (fdiagnostics-show-template-tree): New option.
4062 (felide-type): New option.
4063
63dbcd13
VR
40642017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
4065
4066 * c.opt (Wcatch-value=): New C++ warning flag.
4067
be136b5c
NS
40682017-05-24 Nathan Sidwell <nathan@acm.org>
4069
4070 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
4071 const casts to avoid warning.
4072
3cd211af
MS
40732017-05-24 Martin Sebor <msebor@redhat.com>
4074
4075 PR c/80731
4076 * c-common.h (unsafe_conversion_p): Add a function argument.
4077 * c-common.c (unsafe_conversion_p): Same.
4078 Add type names and values to diagnostics.
4079 (scalar_to_vector): Adjust.
4080 * c-warn.c (constant_expression_error): Add a function argument.
4081 Add type names and values to diagnostics.
4082 (conversion_warning): Add a function argument.
4083 Add type names and values to diagnostics.
4084 (warnings_for_convert_and_check): Same.
4085
1ff7be5a
JM
40862017-05-19 Jason Merrill <jason@redhat.com>
4087
4088 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
4089 enumerators.
4090
ff502317
BE
40912017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
4092
4093 * c-format.c (locus): Move out of function scope,
4094 add GTY attribute.
4095
2a8a8d7b
NS
40962017-05-19 Nathan Sidwell <nathan@acm.org>
4097
4098 * c-opts.c (class_dump_file, class_dump_flags): Delete.
4099 (c_common_parse_file): Remove class dump handling.
4100 (get_dump_info): Likewise.
4101
39aac208
RB
41022017-05-19 Richard Biener <rguenther@suse.de>
4103
4104 PR c++/80593
4105 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
4106 to alias-set zero memory.
4107
6ecd2339
BE
41082017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
4109
4110 * c-format.c (local_tree_type_node): Add GTY attribute.
4111
6574d78e
MP
41122017-05-18 Marek Polacek <polacek@redhat.com>
4113
4114 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
4115 (c_common_fixed_point_type_for_size): Likewise.
4116 (c_common_type_for_mode): Likewise.
4117 (shorten_compare): Likewise.
4118 (c_promoting_integer_type_p): Use false/true instead of 0/1.
4119 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
4120
e3455240
MP
41212017-05-18 Marek Polacek <polacek@redhat.com>
4122
4123 * c-common.c (self_promoting_args_p): Change the return type to bool.
4124 Use false/true instead of 0/1.
4125 * c-common.h (self_promoting_args_p): Update.
4126
3fa8871b
MP
41272017-05-17 Marek Polacek <polacek@redhat.com>
4128
4129 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
4130 * c-warn.c: Likewise.
4131
b42cc3ca
VV
41322017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
4133
4134 Implement new C++ intrinsics __is_assignable and __is_constructible.
4135 * c-common.c (__is_assignable, __is_constructible): New.
4136 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
4137
1a817418
ML
41382017-05-17 Martin Liska <mliska@suse.cz>
4139
4140 * c-common.h: Introduce dump_flags_t type and
4141 use it instead of int type.
4142 * c-gimplify.c (c_genericize): Likewise.
4143 * c-opts.c: Likewise.
4144
b2fa0a8b
MP
41452017-05-17 Marek Polacek <polacek@redhat.com>
4146
4147 * c-common.c (c_save_expr): Remove.
4148 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
4149 * c-common.h (c_save_expr): Remove declaration.
4150
31c2d57d
VR
41512017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
4152
4153 PR c/35441
4154 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
4155 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
4156 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
4157 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
4158 RDIV_EXPR.
4159 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
4160
684f84de
MP
41612017-05-09 Marek Polacek <polacek@redhat.com>
4162
4163 PR c/80525
4164 * c-warn.c (unwrap_c_maybe_const): New.
4165 (warn_logical_operator): Call it.
4166
641da50a
NS
41672017-05-09 Nathan Sidwell <nathan@acm.org>
4168
4169 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
4170 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
4171
631238ac
MS
41722017-05-08 Martin Sebor <msebor@redhat.com>
4173
4174 PR translation/80280
4175 * c-format.h (struct format_flag_spec): Add new member.
4176 (T89_T): New macro.
4177 * c-format.c (local_tree_type_node): New global.
4178 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
4179 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
4180 (strfmon_flag_specs): Likewise.
4181 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
4182 with distinct quoting properties.
4183 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
4184 (flag_chars_t::validate): Add argument and handle bad quoting.
4185 (check_format_info_main): Handle quoting problems.
4186 (init_dynamic_diag_info): Simplify.
4187
49f0c04c
JM
41882017-05-08 Jason Merrill <jason@redhat.com>
4189
4190 * c-opts.c (c_common_post_options): Update defaults for
4191 flag_abi_version and flag_abi_compat_version.
4192
56d35585
DM
41932017-05-05 David Malcolm <dmalcolm@redhat.com>
4194
4195 * c-common.c (c_cpp_error): Replace report_diagnostic
4196 with diagnostic_report_diagnostic.
4197
0f2c4a8f
MS
41982017-05-04 Martin Sebor <msebor@redhat.com>
4199
4200 PR translation/80280
4201 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
4202 (handle_weakref_attribute): Same.
4203
6fe63fb4
NS
42042017-05-03 Nathan Sidwell <nathan@acm.org>
4205
4206 Canonicalize canonical type hashing
4207 * c-common.c (complete_array_type): Use type_hash_canon.
4208
815d9cc6
XR
42092017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
4210
92a285c1 4211 PR c++/80038
815d9cc6
XR
4212 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
4213 prototype.
4214 (cilk_install_body_pedigree_operations): Likewise.
4215 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
4216 detatched.
4217 (cilk_gimplify_call_params_in_spawned_fn): Remove.
4218 (cilk_install_body_pedigree_operations): Likewise.
4219 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
4220 unwrapping.
4221
f8a36447
JJ
42222017-04-27 Jakub Jelinek <jakub@redhat.com>
4223
4224 PR c++/80534
4225 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
4226 flag on non-aggregate element types.
4227
7c145456
BE
42282017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
4229
4230 * c-common.c (c_type_hasher, type_hash_table): Remove.
4231 (c_common_get_alias_set): Remove unreachable code.
4232 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
4233
c3cbcd45
VR
42342017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
4235
4236 * c.opt (Wextra-semi): New C++ warning flag.
4237
8a59d466
JJ
42382017-04-20 Jakub Jelinek <jakub@redhat.com>
4239
4240 PR middle-end/80423
4241 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
4242
8487c9a5
JJ
42432017-04-18 Jakub Jelinek <jakub@redhat.com>
4244
4245 PR middle-end/79788
4246 PR middle-end/80375
4247 * c-common.c (c_common_type_for_mode): Don't handle
4248 widest_*_literal_type_node here.
4249 c_common_signed_or_unsigned_type): Likewise.
4250 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
4251 to *intTI_type_node or *intDI_type_node depending on whether
4252 TImode is supported by the target or not.
4253
3ee0fb02
ML
42542017-04-10 Martin Liska <mliska@suse.cz>
4255
4256 PR sanitizer/80350
4257 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
4258 doing an UBSAN check.
4259
5764ee3c
JW
42602017-04-03 Jonathan Wakely <jwakely@redhat.com>
4261
4262 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
4263
6f3af356
JJ
42642017-03-31 Jakub Jelinek <jakub@redhat.com>
4265
4266 PR c++/79572
4267 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
4268 tree *.
4269 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
4270 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
4271 REFERENCE_TYPE.
4272
f6a7a9d5
DM
42732017-03-31 David Malcolm <dmalcolm@redhat.com>
4274
4275 PR documentation/78732
4276 * c.opt (Wendif-labels): Fix description to refer to
4277 #else rather than #elif.
4278
af88f557
JJ
42792017-03-31 Jakub Jelinek <jakub@redhat.com>
4280
4281 PR libstdc++/80251
4282 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
4283 * c-common.c (c_common_reswords): Add __is_aggregate trait.
4284
a9e4a1a5
JJ
42852017-03-27 Jakub Jelinek <jakub@redhat.com>
4286
4287 PR middle-end/80162
4288 * c-common.c (c_common_mark_addressable_vec): Don't set
4289 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
4290
3f01b620
MS
42912017-03-21 Martin Sebor <msebor@redhat.com>
4292
4293 PR c++/79548
4294 * c-common.c (set_underlying_type): Mark type used only when
4295 original del is declared unused.
4296
2f6f187a
DM
42972017-03-10 David Malcolm <dmalcolm@redhat.com>
4298
4299 PR translation/79848
4300 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
4301 "%qs".
4302
a02fa805
DM
43032017-03-10 David Malcolm <dmalcolm@redhat.com>
4304
4305 PR c/79921
4306 * c-indentation.c (warn_for_misleading_indentation): Remove parens
4307 from inform's message, so that xgettext can locate it.
4308
822a132c
MP
43092017-03-09 Marek Polacek <polacek@redhat.com>
4310
4311 PR c++/79962
4312 PR c++/79984
4313 * c-attribs.c (handle_nonnull_attribute): Save the result of default
4314 conversion to the attribute list.
4315
bba81f1c
ML
43162017-03-09 Martin Liska <mliska@suse.cz>
4317
4318 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
4319
108154ff
JM
43202017-03-03 Jason Merrill <jason@redhat.com>
4321
4322 * c.opt (Wnoexcept-type): New.
4323
eb0e7c34
RB
43242017-03-02 Richard Biener <rguenther@suse.de>
4325
4326 PR c/79756
4327 * c-common.c (c_common_mark_addressable_vec): Look through
4328 C_MAYBE_CONST_EXPR.
4329
9453ba0a
ML
43302017-02-28 Martin Liska <mliska@suse.cz>
4331
4332 * c.opt: Replace space with tabular for options of <number>
4333 type.
4334
6a825afe
ML
43352017-02-28 Martin Liska <mliska@suse.cz>
4336
4337 * c.opt: Fix --help=option -Q for options which are of
4338 an enum type.
4339
4227c9ad
JJ
43402017-02-24 Jakub Jelinek <jakub@redhat.com>
4341
4342 PR c++/79588
4343 * c-common.c (check_function_restrict): New function.
4344 (check_function_arguments): Add FNDECL argument. Call
4345 check_function_restrict if -Wrestrict.
4346 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
4347 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
4348 * c-common.h (check_function_arguments): Add FNDECL argument.
4349 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
4350
59909673
EB
43512017-02-24 Eric Botcazou <ebotcazou@adacore.com>
4352
4353 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
4354 treatment of parameters with pointer-to-tagged type and tidy up.
4355 (print_ada_methods): Remove the special treatment of C++ static member
4356 functions.
4357
54dcd526
ML
43582017-02-22 Martin Liska <mliska@suse.cz>
4359
4360 * c.opt: Replace inequality signs with square brackets
4361 for -Wnornalized.
4362
00bc9de3
JJ
43632017-02-21 Jakub Jelinek <jakub@redhat.com>
4364
4365 PR c++/79641
4366 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
4367 preserve quals.
4368
97fcf744
JM
43692017-02-17 Joseph Myers <joseph@codesourcery.com>
4370
4371 * c-cppbuiltin.c (builtin_define_float_constants): Define
4372 __DECIMAL_DIG__ to the value for long double.
4373
c7545f1c
MP
43742017-02-15 Marek Polacek <polacek@redhat.com>
4375
4376 PR c/79515
4377 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
4378 conversion has occured.
4379
c2e84327
DM
43802017-01-24 David Malcolm <dmalcolm@redhat.com>
4381
4382 * c-common.c (c_common_reswords): Add "__RTL".
4383 * c-common.h (enum rid): Add RID_RTL.
4384
2ebd93e1
MP
43852017-01-20 Marek Polacek <polacek@redhat.com>
4386
4387 PR c/64279
4388 * c-common.h (do_warn_duplicated_branches_r): Declare.
4389 * c-gimplify.c (c_genericize): Walk the function tree calling
4390 do_warn_duplicated_branches_r.
4391 * c-warn.c (expr_from_macro_expansion_r): New.
4392 (do_warn_duplicated_branches): New.
4393 (do_warn_duplicated_branches_r): New.
4394 * c.opt (Wduplicated-branches): New option.
4395
0d80ab91
DM
43962017-01-17 David Malcolm <dmalcolm@redhat.com>
4397
4398 PR c++/71497
4399 * c-indentation.c (warn_for_misleading_indentation): Use the past
4400 subjunctive in the note.
4401
7f991c36
AH
44022017-01-17 Aldy Hernandez <aldyh@redhat.com>
4403
4404 PR c/79116
4405 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
4406 start type to integer_type.
4407
1c70261c
JJ
44082017-01-16 Jakub Jelinek <jakub@redhat.com>
4409
4410 PR driver/49726
4411 * c.opt (gen-decls): Add Driver flag.
4412
1ddca3f3
PC
44132017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
4414
4415 Revert:
4416 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
4417
4418 PR c++/71737
4419 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
4420
7d2f3f1d
PC
44212017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
4422
4423 PR c++/71737
4424 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
4425
bce6f760
MS
44262017-01-12 Martin Sebor <msebor@redhat.com>
4427
4428 (-Wformat-overflow): ...to this.
4429
bf5fbf46
MS
44302017-01-11 Martin Sebor <msebor@redhat.com>
4431
4432 PR c/78768
4433 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
4434 Also enable for LTO.
4435
e363df3f
JM
44362017-01-10 Jason Merrill <jason@redhat.com>
4437
4438 Implement P0195R2, C++17 variadic using.
4439 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
4440
bd2c6270
JJ
44412017-01-09 Jakub Jelinek <jakub@redhat.com>
4442
4443 PR translation/79019
4444 PR translation/79020
4445 * c.opt (Wnormalized=): Fix typo in description.
4446
efcc8d38
MS
44472017-01-08 Martin Sebor <msebor@redhat.com>
4448
4449 PR middle-end/77708
4450 * c.opt (-Wformat-truncation): New option.
4451
ab20d992 44522017-01-06 Alexandre Oliva <aoliva@redhat.com>
435f3f7a
AO
4453
4454 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
4455 value to unsigned short to fit in 4 hex digits without
4456 warnings.
4457
4e89adf9
EB
44582017-01-05 Eric Botcazou <ebotcazou@adacore.com>
4459
4460 * c.opt (fsso-struct): Add 'native' value.
4461
cd445b54
ML
44622017-01-05 Martin Liska <mliska@suse.cz>
4463
4464 PR pch/78970
4465 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
4466 header.
4467
a9342885
MP
44682017-01-04 Marek Polacek <polacek@redhat.com>
4469
4470 PR c++/64767
4471 * c.opt (Wpointer-compare): New option.
4472
fc73e60c
JJ
44732017-01-04 Jakub Jelinek <jakub@redhat.com>
4474
4475 PR driver/78957
4476 * c.opt (fsso-struct=): Add RejectNegative.
4477
cbe34bb5
JJ
44782017-01-01 Jakub Jelinek <jakub@redhat.com>
4479
4480 Update copyright years.
4481
d4a6c0ea
ML
44822016-12-29 Martin Liska <mliska@suse.cz>
4483
4484 PR c/78933
4485 * c.opt (strong-eval-order): Add RejectNegative keyword.
4486
67a5ad7c
JM
44872016-12-22 Jason Merrill <jason@redhat.com>
4488
4489 Implement P0522R0, matching of template template arguments.
4490 * c-cppbuiltin.c (c_cpp_builtins): Define
4491 __cpp_template_template_args.
4492
0dba7960
JJ
44932016-12-21 Jakub Jelinek <jakub@redhat.com>
4494
4495 PR bootstrap/78817
4496 * c-common.c (struct nonnull_arg_ctx): New type.
4497 (check_function_nonnull): Return bool instead of void. Use
4498 nonnull_arg_ctx as context rather than just location_t.
4499 (check_nonnull_arg): Adjust for the new context type, set
4500 warned_p to true if a warning has been diagnosed.
4501 (check_function_arguments): Return bool instead of void.
4502 * c-common.h (check_function_arguments): Adjust prototype.
4503
31bfc9b9
JM
45042016-12-21 Jason Merrill <jason@redhat.com>
4505
4506 * c.opt (-fnew-ttp-matching): New flag.
4507 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
4508
629b3d75
MJ
45092016-12-14 Martin Jambor <mjambor@suse.cz>
4510
4511 * c-omp.c: Include omp-general.h instead of omp-low.h.
4512 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
4513 name.
4514
474da67e
MS
45152016-12-14 Martin Sebor <msebor@redhat.com>
4516
4517 PR c/17308
4518 * c-common.c (check_nonnull_arg): Disable when optimization
4519 is enabled.
4520
fe366b87
MP
45212016-12-12 Marek Polacek <polacek@redhat.com>
4522
4523 PR c++/78647
4524 * c-common.c (attribute_fallthrough_p): Return false for
4525 error_mark_node.
4526
8bd9f164
MS
45272016-12-08 Martin Sebor <msebor@redhat.com>
4528
4529 PR c/78284
4530 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
4531
060162e0
MS
45322016-12-08 Martin Sebor <msebor@redhat.com>
4533
4534 PR c/78165
92a285c1
ML
4535 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
4536 suffix.
060162e0 4537
ee92e7ba
MS
45382016-12-07 Martin Sebor <msebor@redhat.com>
4539
4540 PR c/53562
4541 PR middle-end/77784
4542 PR middle-end/78149
4543 PR middle-end/78138
4544 * c.opt (-Wstringop-overflow): New option.
4545
84b0769e
MO
45462016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
4547
4548 * c-attribs.c (asan odr indicator): New attribute.
4549 (handle_asan_odr_indicator_attribute): New function.
4550
7fa6a965
PK
45512016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4552
4553 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
4554 ptrdiff_type_node;
4555
56d8ffc1
JG
45562016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
4557
4558 * c-common.c (excess_precision_mode_join): New.
4559 (c_ts18661_flt_eval_method): New.
4560 (c_c11_flt_eval_method): Likewise.
4561 (c_flt_eval_method): Likewise.
4562 * c-common.h (excess_precision_mode_join): New.
4563 (c_flt_eval_method): Likewise.
4564 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
4565 (cpp_iec_559_value): Call it.
4566 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
4567 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
4568 __FLT_EVAL_METHOD_TS_18661_3__.
4569
04f0fcf7
JG
45702016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
4571
4572 * c-opts.c (c_common_post_options): Add logic to handle the default
4573 case for -fpermitted-flt-eval-methods.
4574
fb2675cb
PB
45752016-11-23 Paolo Bonzini <bonzini@gnu.org>
4576
4577 * c.opt (Wexpansion-to-defined): New.
4578
ec1c5694
JJ
45792016-11-23 Jakub Jelinek <jakub@redhat.com>
4580
4581 PR target/78451
4582 * c-pragma.c (handle_pragma_target): Don't replace
4583 current_target_pragma, but chainon the new args to the current one.
4584
730c9e75
NS
45852016-11-22 Nathan Sidwell <nathan@acm.org>
4586
4587 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
cacd29be 4588 indentation and formatting.
730c9e75 4589
89990732
MS
45902016-11-21 Martin Sebor <msebor@redhat.com>
4591
4592 * c.opt (-fprintf-return-value): Enable by default.
4593
48330c93
BE
45942016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
4595
4596 PR c++/71973
4597 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
4598 * c-common.c (c_common_nodes_and_builtins): Initialize
4599 const_tm_ptr_type_node.
4600
0d939c95
MP
46012016-11-16 Marek Polacek <polacek@redhat.com>
4602
4603 PR c/78285
4604 * c-common.c (c_add_case_label): Turn error_at calls into inform.
4605
8e745a17
JJ
46062016-11-14 Jakub Jelinek <jakub@redhat.com>
4607
4608 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
4609
1ee62b92 46102016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
8e745a17
JJ
4611 Richard Biener <rguenther@suse.de>
4612
4613 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
4614 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
4615 * c.opt (fgimple): New option.
1ee62b92 4616
22b15758
UB
46172016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4618
4619 PR c/35503
4620 * c-common.h (warn_for_restrict): Declare.
4621 * c-warn.c: Include gcc-rich-location.h.
4622 (warn_for_restrict): New function.
4623 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
4624 (gcc_cdiag_char_table): Likewise.
4625 (gcc_cxxdiag_char_table): Likewise.
4626 * c.opt (Wrestrict): New option.
4627
4be719cd
EB
46282016-11-13 Eric Botcazou <ebotcazou@adacore.com>
4629
4630 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
4631 for nested types only if the type is a record or union and dump SLOC.
4632
4a826ca6
JM
46332016-11-09 Jason Merrill <jason@redhat.com>
4634
4635 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
4636
2e955d50
JJ
46372016-11-09 Jakub Jelinek <jakub@redhat.com>
4638
4639 * c-ubsan.c (ubsan_instrument_shift): Handle split
4640 -fsanitize=shift-base and -fsanitize=shift-exponent.
4641
51dc6603
JM
46422016-11-07 Jason Merrill <jason@redhat.com>
4643
4644 * c.opt (Wc++1z-compat): New.
4645 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
4646
6dc4a604
ML
46472016-11-07 Martin Liska <mliska@suse.cz>
4648
4649 * c-warn.c (warn_for_unused_label): Save all labels used
4650 in goto or in &label.
4651
b302001e
JM
46522016-11-03 Jason Merrill <jason@redhat.com>
4653
4654 * c-cppbuiltin.c (c_cpp_builtins): Correct
4655 __cpp_inheriting_constructors.
4656
31f7f784
JM
46572016-11-01 Jason Merrill <jason@redhat.com>
4658
2bc78e3c
JM
4659 * c-cppbuiltin.c (c_cpp_builtins): Update
4660 __cpp_inheriting_constructors.
4661
31f7f784
JM
4662 * c.opt (-fnew-inheriting-ctors): New.
4663 * c-opts.c: Default to on for ABI 11+.
4664
dcb466ec
JJ
46652016-10-31 Jakub Jelinek <jakub@redhat.com>
4666
4667 PR c++/77948
4668 * c.opt (fext-numeric-literals): Add Var and Init.
4669 * c-opts.c (c_common_handle_option): Don't clear
4670 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
4671 (c_common_post_options): Clear it here if not set
4672 explicitly.
4673
52e1b91e
AH
46742016-10-28 Aldy Hernandez <aldyh@redhat.com>
4675
4676 PR debug/77773
4677 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
4678 if NULL.
4679
e16f1cc7
JJ
46802016-10-25 Jakub Jelinek <jakub@redhat.com>
4681
4682 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
4683 * c-common.c (c_common_reswords): Add __builtin_launder.
4684
f8348061
BE
46852016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
4686
4687 * c-common.c (c_common_truthvalue_conversion): Warn for
4688 multiplications in boolean context. Fix the quoting of '<<' and '<'
4689 in the shift warning.
4690
eff89e01
BE
46912016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
4692
4693 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
4694
24bc7bf4
JM
46952016-10-20 Jason Merrill <jason@redhat.com>
4696
4697 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
4698
4c712374
BE
46992016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
4700
4701 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
4702 integer shift ops in boolean context.
4703
47042016-10-18 Aldy Hernandez <aldyh@redhat.com>
adc577c5
AH
4705
4706 * c.opt (Walloca): New.
4707 (Walloca-larger-than=): New.
4708 (Wvla-larger-than=): New.
4709
8fa18c06
MP
47102016-10-17 Marek Polacek <polacek@redhat.com>
4711
4712 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
4713 Return immediately when finding a match.
4714 (warn_tautological_cmp): Remove a boolean variable that is no longer
4715 needed.
4716
b12b1915
MP
47172016-10-17 Marek Polacek <polacek@redhat.com>
4718
4719 * c-attribs.c: New file.
4720 * c-common.c: Move attributes handling to c-attribs.c.
4721 (get_nonnull_operand): No longer static.
4722 * c-common.h: Move the declarations from c-attribs.c to its own section.
4723
2045acd9
JM
47242016-10-14 Jason Merrill <jason@redhat.com>
4725
4726 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
4727 and __cpp_deduction_guides.
4728
14a2c9aa
JM
47292016-10-13 Jason Merrill <jason@redhat.com>
4730
4731 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
4732
4d0cdd0c
TP
47332016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
4734
4735 * c-cppbuiltin.c: Include memmodel.h.
4736 * c-opts.c: Likewise.
4737 * c-pragma.c: Likewise.
4738 * c-warn.c: Likewise.
4739
70f6d5e1
JJ
47402016-10-12 Jakub Jelinek <jakub@redhat.com>
4741
4742 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
4743 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
4744 * c-opts.c (sanitize_cpp_opts): Initialize
4745 cpp_opts->cpp_warn_implicit_fallthrough.
4746
78f61294
MP
47472016-10-11 Marek Polacek <polacek@redhat.com>
4748
4749 * c-common.c (warning_candidate_p): Change the return type to bool
4750 and return true/false instead of 1/0.
4751 (vector_mode_valid_p): Likewise.
4752
038b5cc0
MP
47532016-10-11 Marek Polacek <polacek@redhat.com>
4754
4755 * c-common.c (fold_for_warn): No longer static.
4756 (bool_promoted_to_int_p): Likewise.
4757 (c_common_get_narrower): Likewise.
4758 (constant_expression_warning): Move to c-warn.c.
4759 (constant_expression_error): Likewise.
4760 (overflow_warning): Likewise.
4761 (warn_logical_operator): Likewise.
4762 (find_array_ref_with_const_idx_r): Likewise.
4763 (warn_tautological_cmp): Likewise.
4764 (expr_has_boolean_operands_p): Likewise.
4765 (warn_logical_not_parentheses): Likewise.
4766 (warn_if_unused_value): Likewise.
4767 (strict_aliasing_warning): Likewise.
4768 (sizeof_pointer_memaccess_warning): Likewise.
4769 (check_main_parameter_types): Likewise.
4770 (conversion_warning): Likewise.
4771 (warnings_for_convert_and_check): Likewise.
4772 (match_case_to_enum_1): Likewise.
4773 (match_case_to_enum): Likewise.
4774 (c_do_switch_warnings): Likewise.
4775 (warn_for_omitted_condop): Likewise.
4776 (readonly_error): Likewise.
4777 (lvalue_error): Likewise.
4778 (invalid_indirection_error): Likewise.
4779 (warn_array_subscript_with_type_char): Likewise.
4780 (warn_about_parentheses): Likewise.
4781 (warn_for_unused_label): Likewise.
4782 (warn_for_div_by_zero): Likewise.
4783 (warn_for_memset): Likewise.
4784 (warn_for_sign_compare): Likewise.
4785 (do_warn_double_promotion): Likewise.
4786 (do_warn_unused_parameter): Likewise.
4787 (record_locally_defined_typedef): Likewise.
4788 (maybe_record_typedef_use): Likewise.
4789 (maybe_warn_unused_local_typedefs): Likewise.
4790 (maybe_warn_bool_compare): Likewise.
4791 (maybe_warn_shift_overflow): Likewise.
4792 (warn_duplicated_cond_add_or_warn): Likewise.
4793 (diagnose_mismatched_attributes): Likewise.
4794 * c-common.h: Move the declarations from c-warn.c to its own section.
4795 * c-warn.c: New file.
4796
627be19f
JM
47972016-10-08 Jason Merrill <jason@redhat.com>
4798
4799 * c-common.c (c_common_truthvalue_conversion): Don't distribute
4800 into COND_EXPR in C++.
4801
7bad794a
JJ
48022016-10-08 Jakub Jelinek <jakub@redhat.com>
4803
4804 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
4805 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
4806 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
4807
be845b04
JJ
48082016-10-07 Jakub Jelinek <jakub@redhat.com>
4809
4810 Implement LWG2296 helper intrinsic
4811 * c-common.h (enum rid): Add RID_ADDRESSOF.
4812 * c-common.c (c_common_reswords): Add __builtin_addressof.
4813
c09c4992
BE
48142016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
4815
4816 PR c++/77700
4817 * c-common.c (c_common_truthvalue_conversion): Warn also for
4818 suspicious enum values in boolean context.
4819
342cfb3e
JJ
48202016-10-06 Jakub Jelinek <jakub@redhat.com>
4821
4822 Implement P0258R2 - helper for C++17
4823 std::has_unique_object_representations trait
4824 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
4825 * c-common.c (c_common_reswords): Add
4826 __has_unique_object_representations.
4827
2e69f143
JJ
48282016-10-05 Jakub Jelinek <jakub@redhat.com>
4829
4830 PR sanitizer/66343
4831 * c-ubsan.c (ubsan_instrument_return): Don't call
4832 initialize_sanitizer_builtins here.
4833
700fff34
BE
48342016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
4835
4836 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
4837 conditional expression in boolean context when only one arm is
4838 non-boolean.
4839
9563bfcd
JJ
48402016-10-05 Jakub Jelinek <jakub@redhat.com>
4841
04a32443
JJ
4842 PR sanitizer/77823
4843 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
4844 is not integral.
4845
9563bfcd
JJ
4846 * c-common.c (c_common_reswords): Update comment for C++11.
4847
f1644724
JM
48482016-10-04 Jason Merrill <jason@redhat.com>
4849
4850 * c-common.c (make_tree_vector_from_ctor): New.
4851 * c-common.h: Declare it.
4852
5a79befb
JJ
48532016-10-04 Jakub Jelinek <jakub@redhat.com>
4854
4855 * c-cppbuiltin.c (c_cpp_builtins): Don't define
4856 __LIBGCC_JCR_SECTION_NAME__.
4857
1633d3b9
BE
48582016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
4859
4860 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
4861 left shift in boolean context.
4862
a2c6e7f2
JJ
48632016-09-29 Jakub Jelinek <jakub@redhat.com>
4864
4865 Implement P0001R1 - C++17 removal of register storage class specifier
4866 * c.opt (Wregister): New warning.
4867 * c-opts.c (c_common_post_options): Enable -Wregister by
4868 default for C++17.
4869
75304c87
JG
48702016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
4871
4872 * c-opts.c (c_common_post_options): Remove special case for
4873 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
4874 in C++.
4875
bbfac6da
JJ
48762016-09-27 Jakub Jelinek <jakub@redhat.com>
4877
6e39060a
JJ
4878 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
4879 -std=c++1z.
4880
bbfac6da
JJ
4881 * c-ada-spec.c (print_ada_declaration): Remove break after return.
4882
e73cf9a2
TP
48832016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
4884
4885 * c-common.c: Include memmodel.h.
4886
c6147dc4
MP
48872016-09-26 Marek Polacek <polacek@redhat.com>
4888
4889 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
4890
81fea426
MP
48912016-09-26 Marek Polacek <polacek@redhat.com>
4892
4893 PR c/7652
4894 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
4895 (handle_fallthrough_attribute): New function.
4896 (attribute_fallthrough_p): New function.
4897 * c-common.h (attribute_fallthrough_p): Declare.
4898
9a2300e9
MP
48992016-09-24 Marek Polacek <polacek@redhat.com>
4900
4901 PR c/77490
4902 * c.opt (Wbool-operation): New.
4903
a09e9e35
BE
49042016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
4905
4906 * c-common.c (c_common_truthvalue_conversion): Inhibit
4907 Wint-in-bool-context warning with from_macro_definition_at.
4908 Mention the expression will always evaluate to true.
4909
d43b4ccc
MS
49102016-09-21 Martin Sebor <msebor@redhat.com>
4911
4912 PR bootstrap/77676
4913 * c.opt (fprintf-return-value): Temporarily initialize to zero
4914 to unblock bootstrap failures.
4915
2e1c20b1
JJ
49162016-09-21 Jakub Jelinek <jakub@redhat.com>
4917
4918 PR c++/77651
4919 * c.opt (Waligned-new=): Add RejectNegative.
4920 (faligned-new=): Likewise. Spelling fix - change
4921 aligned_new_threshhold to aligned_new_threshold.
4922 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
4923 to aligned_new_threshold.
4924
88d0c3f0
MS
49252016-09-20 Martin Sebor <msebor@redhat.com>
4926
4927 PR middle-end/49905
4928 * c.opt: Add -Wformat-length and -fprintf-return-value.
4929
144a96e4
BE
49302016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
4931
4932 PR c++/77434
4933 * c.opt (Wint-in-bool-context): New warning.
4934 * c-common.c (c_common_truthvalue_conversion): Warn on integer
4935 constants in boolean context.
4936
63012d9a
JM
49372016-09-19 Joseph Myers <joseph@codesourcery.com>
4938
4939 * c-common.c (max_align_t_align): Also consider alignment of
4940 float128_type_node.
4941
931388ce
JM
49422016-09-15 Jason Merrill <jason@redhat.com>
4943
4944 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
4945 DECL_EXTERNAL.
4946
38711381
JM
49472016-09-14 Jason Merrill <jason@redhat.com>
4948
4949 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
4950 limit FIELD_DECL, either.
4951
e51fbec3
MP
49522016-09-14 Marek Polacek <polacek@redhat.com>
4953
4954 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
4955 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
4956 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
4957
254830ba
DM
49582016-09-13 David Malcolm <dmalcolm@redhat.com>
4959
4960 * c-common.c (warn_logical_not_parentheses): Replace
4961 rich_location::add_fixit_insert calls with add_fixit_insert_before
4962 and add_fixit_insert_after, eliminating the "next_loc" calculation.
4963
42763690
JM
49642016-09-13 Jason Merrill <jason@redhat.com>
4965 Tom de Vries <tom@codesourcery.com>
4966
4967 PR c++/77427
4968 * c-common.c (set_underlying_type): Don't treat array as builtin type.
4969
9453eee9
JM
49702016-09-13 Jason Merrill <jason@redhat.com>
4971
4972 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
4973 limit types at all.
4974
e96809e3
JM
49752016-09-12 Jason Merrill <jason@redhat.com>
4976
4977 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
4978 bit/byte confusion, allow large alignment for types.
4979
54dcdb88
BE
49802016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
4981
4982 PR c++/77496
4983 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
4984
d1463eb9
DM
49852016-09-12 David Malcolm <dmalcolm@redhat.com>
4986
4987 PR c/72858
4988 * c-format.c (argument_parser::check_argument_type): Add params
4989 "type_start" and "conversion_char". Use the former to generate
4990 offset_to_type_start and pass it and conversion_char to
4991 check_format_types.
4992 (check_format_info_main): Capture the start of the type
4993 information as "type_start", and pass it an format_char
4994 to arg_parser.check_argument_type.
4995 (check_format_types): Provide an example in the leading comment.
4996 Add params "offset_to_type_start" and "conversion_char"; pass
4997 them to format_type_warning calls.
4998 (test_get_modifier_for_format_len): Likewise.
4999 (matching_type_p): New function.
5000 (get_format_for_type): Add param "conversion_char" and move
5001 implementation into...
5002 (get_format_for_type_1): ...new function, called twice.
5003 Use new function matching_type_p rather than checking for
5004 TYPE_CANONICAL equality.
5005 (get_corrected_substring): New function.
5006 (format_type_warning): Provide an example in the leading comment.
5007 Add params "offset_to_type_start" and "conversion_char". Replace
5008 call to get_format_for_type with call to get_corrected_substring
5009 and move rejection of hints for widths/precisions there.
5010 (assert_format_for_type_streq): Add param "conversion_char".
5011 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
5012 (test_get_format_for_type_printf): Add conversion chars to the
5013 tests, adding coverage for various combinations of integer
5014 vs double conversions, and for preserving octal and hexadecimal
5015 conversions.
5016 (test_get_format_for_type_scanf): Add conversion chars to the
5017 tests.
5018
5b28efbb
TV
50192016-09-10 Tom de Vries <tom@codesourcery.com>
5020
5021 PR C/71602
5022 * c-common.c (build_va_arg): Handle more strict
5023 targetm.canonical_va_list_type. Replace first argument type error with
5024 assert.
5025
3f0177e7
MS
50262016-09-09 Martin Sebor <msebor@redhat.com>
5027
5028 PR c/77520
5029 PR c/77521
5030 * c-format.c (argument_parser::find_format_char_info): Use %qc
5031 format directive unconditionally.
5032
af63ba4b
JM
50332016-09-09 Jason Merrill <jason@redhat.com>
5034
5035 Implement C++17 new of over-aligned types.
5036 * c.opt: Add -faligned-new and -Waligned-new.
5037 * c-common.c (max_align_t_align): Split out from...
5038 (cxx_fundamental_alignment_p): ...here.
5039 * c-common.h: Declare it.
5040 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
5041
c65248cb
JM
50422016-09-09 Joseph Myers <joseph@codesourcery.com>
5043
5044 * c-cppbuiltin.c (builtin_define_type_width): New function.
5045 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
5046 macros.
5047
e5106e27
DM
50482016-09-07 David Malcolm <dmalcolm@redhat.com>
5049
5050 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
5051 a POINTER_TYPE.
5052 (substring_loc::get_location): Move to substring-locations.c,
5053 keeping implementation as...
5054 (c_get_substring_location): New function, from the above, reworked
5055 to use accessors rather than member lookup.
5056 * c-common.h (class substring_loc): Move to substring-locations.h,
5057 replacing with a forward decl.
5058 (c_get_substring_location): New decl.
5059 * c-format.c: Include "substring-locations.h".
5060 (format_warning_va): Move to substring-locations.c.
5061 (format_warning_at_substring): Likewise.
5062
ab20d992 50632016-09-06 Martin Sebor <msebor@redhat.com>
a42e7952
MS
5064
5065 PR c/77336
5066 * c-format.c (check_function_format): Avoid issuing warnings for
5067 functions unless they call format functions with non-constant
5068 format strings.
5069
b772a565
RB
50702016-09-06 Richard Biener <rguenther@suse.de>
5071
5072 PR c/77450
5073 * c-common.c (c_common_mark_addressable_vec): Handle
5074 COMPOUND_LITERAL_EXPR.
5075
25ff5dd3
MP
50762016-09-05 Marek Polacek <polacek@redhat.com>
5077
5078 PR c/77423
5079 * c-common.c (bool_promoted_to_int_p): New function.
5080 (expr_has_boolean_operands_p): New function.
5081 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
5082 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
5083
21234eb5
TV
50842016-09-04 Tom de Vries <tom@codesourcery.com>
5085
5086 revert:
5087 2016-08-29 Tom de Vries <tom@codesourcery.com>
5088
5089 * c-common.c (build_va_arg): Replace first argument type error
5090 with assert.
5091
9dc5773f
JJ
50922016-09-02 Jakub Jelinek <jakub@redhat.com>
5093
5094 PR c/65467
5095 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
5096 (c_finish_omp_for): Reject _Atomic qualified iterators.
5097
50982016-09-01 Martin Sebor <msebor@redhat.com>
3d7b83b6
MS
5099
5100 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
5101 size to guarantee it fits the output of the formatted function
5102 regardless of its arguments.
5103
295844f6
MP
51042016-09-01 Marek Polacek <polacek@redhat.com>
5105
5106 PR c/7652
5107 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
5108 FALLTHRU comments.
5109
3d06b6f2
MP
51102016-08-29 Marek Polacek <polacek@redhat.com>
5111
5112 PR c/77292
5113 * c-common.c (warn_logical_not_parentheses): Don't warn for
5114 a comparison or a logical operator.
5115
34cedad5
TV
51162016-08-29 Tom de Vries <tom@codesourcery.com>
5117
5118 * c-common.c (build_va_arg): Fix type comparison assert.
5119
f162d717
TV
51202016-08-29 Tom de Vries <tom@codesourcery.com>
5121
5122 * c-common.c (build_va_arg): Replace first argument type error
5123 with assert.
5124
ba9bbd6f
TV
51252016-08-29 Tom de Vries <tom@codesourcery.com>
5126
5127 PR c/77398
5128 * c-common.c (build_va_arg): Add first argument error. Build va_arg
5129 with error_mark_node as va_list instead of with illegal va_list.
5130
ebef225f
MP
51312016-08-25 Marek Polacek <polacek@redhat.com>
5132 David Malcolm <dmalcolm@redhat.com>
5133
5134 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
5135 * c-common.h (warn_logical_not_parentheses): Update declaration.
5136
b00e6e75
MP
51372016-08-22 Marek Polacek <polacek@redhat.com>
5138
5139 PR c++/77321
5140 * c-common.c (warn_for_memset): Check type for null.
5141
6dc198e3
JM
51422016-08-22 Joseph Myers <joseph@codesourcery.com>
5143
14ec014e 5144 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
6dc198e3
JM
5145 _FloatNx types for suffixes for built-in functions.
5146
c65699ef
JM
51472016-08-19 Joseph Myers <joseph@codesourcery.com>
5148
5149 PR c/32187
5150 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
5151 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
5152 (RID_FLOAT128X): New enum rid values.
5153 (CASE_RID_FLOATN_NX): New macro.
5154 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
5155 keywords.
5156 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
5157 corresponding complex types.
5158 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
5159 _FloatNx and corresponding complex types.
5160 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
5161 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
5162 and _FloatNx types for the widest type for determining
5163 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
5164 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
5165 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
5166 and _FloatNx types.
5167 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
5168 constants.
5169 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
5170 _FloatNx types.
5171
cc015f3a
DM
51722016-08-18 David Malcolm <dmalcolm@redhat.com>
5173
5174 * c-opts.c (c_diagnostic_finalizer): Update for change to
5175 diagnostic_show_locus.
5176
cb18fd07
DM
51772016-08-18 David Malcolm <dmalcolm@redhat.com>
5178
5179 * c-common.c: Include "spellcheck.h".
5180 (cb_get_suggestion): New function.
5181 * c-common.h (cb_get_suggestion): New decl.
5182 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
5183 cb_get_suggestion.
5184
a76989dc
MP
51852016-08-18 Marek Polacek <polacek@redhat.com>
5186
5187 PR c/71514
5188 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
5189 and pointer-to-VLA.
5190
65e736c0
DM
51912016-08-16 David Malcolm <dmalcolm@redhat.com>
5192
5193 PR c/72857
5194 * c-common.c (substring_loc::get_range): Rename to...
5195 (substring_loc::get_location): ...this, converting param from a
5196 source_range * to a location_t *. Call
5197 get_source_location_for_substring rather than
5198 get_source_range_for_substring, and pass in m_caret_idx.
5199 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
5200 (substring_loc::get_range): Replace with...
5201 (substring_loc::get_location): ...this.
5202 (substring_loc::set_caret_index): New method.
5203 (substring_loc): Add field m_caret_idx.
5204 * c-format.c (format_warning_va): Update for above changes.
5205 Rename local "substring_loc" to "fmt_substring_loc" to avoid
5206 clashing with type name.
5207 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
5208 (check_argument_type): Likewise.
5209 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
5210 Use a copy when emitting warnings, setting the caret index from TYPE.
5211
7e1dde14 52122016-08-16 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 5213 Arnaud Charlet <charlet@adacore.com>
7e1dde14
EB
5214
5215 * c-ada-spec.c (dump_number): New function.
5216 (handle_escape_character): Likewise.
5217 (print_ada_macros): Add handling of constant integers and strings.
5218
191816a3
MP
52192016-08-12 Marek Polacek <polacek@redhat.com>
5220
5221 PR c/7652
5222 * c-common.c (scalar_to_vector): Adjust fall through comment.
5223 * c-opts.c (c_common_handle_option): Likewise.
5224 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
5225 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
5226 fall through comment.
5227 * cilk.c (extract_free_variables): Add FALLTHRU.
5228
452df4a4
JM
52292016-08-10 Jason Merrill <jason@redhat.com>
5230
5231 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
5232
f3365c12
JM
52332016-08-09 Jason Merrill <jason@redhat.com>
5234
5235 * c-common.c (c_common_attribute_table): vector_size affects type
5236 identity.
5237
f0bc3323
MP
52382016-08-09 Marek Polacek <polacek@redhat.com>
5239
5240 PR c/7652
5241 * c-ada-spec.c (dump_generic_ada_node): Add return.
5242
98e5a19a
JM
52432016-08-09 Jason Merrill <jason@redhat.com>
5244
5245 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
5246 C++17 constexpr lambdas.
5247
895aa8e1
DM
52482016-08-08 David Malcolm <dmalcolm@redhat.com>
5249
5250 PR c/64955
5251 * c-common.h (selftest::c_format_c_tests): New declaration.
5252 (selftest::run_c_tests): New declaration.
5253 * c-format.c: Include "selftest.h.
5254 (format_warning_va): Add param "corrected_substring" and use
5255 it to add a replacement fix-it hint.
5256 (format_warning_at_substring): Likewise.
5257 (format_warning_at_char): Update for new param of
5258 format_warning_va.
5259 (argument_parser::check_argument_type): Pass "fki" to
5260 check_format_types.
5261 (check_format_types): Add param "fki" and pass it to
5262 format_type_warning.
5263 (deref_n_times): New function.
5264 (get_modifier_for_format_len): New function.
5265 (selftest::test_get_modifier_for_format_len): New function.
5266 (get_format_for_type): New function.
5267 (format_type_warning): Add param "fki" and use it to attempt
5268 to provide hints for argument types when calling
5269 format_warning_at_substring.
5270 (selftest::get_info): New function.
5271 (selftest::assert_format_for_type_streq): New function.
5272 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
5273 (selftest::test_get_format_for_type_printf): New function.
5274 (selftest::test_get_format_for_type_scanf): New function.
5275 (selftest::c_format_c_tests): New function.
5276
e52ed3fe
DM
52772016-08-08 David Malcolm <dmalcolm@redhat.com>
5278
5279 PR c/52952
5280 * c-format.c: Include "diagnostic.h".
5281 (location_column_from_byte_offset): Delete.
5282 (location_from_offset): Delete.
5283 (format_warning_va): New function.
5284 (format_warning_at_substring): New function.
5285 (format_warning_at_char): New function.
5286 (check_format_arg): Capture location of format_tree and pass to
5287 check_format_info_main.
5288 (argument_parser): Add fields "start_of_this_format" and
5289 "format_string_cst".
5290 (flag_chars_t::validate): Add param "format_string_cst". Convert
5291 warning_at call using location_from_offset to call to
5292 format_warning_at_char.
5293 (argument_parser::argument_parser): Add param "format_string_cst_"
5294 and use use it to initialize field "format_string_cst".
5295 Initialize new field "start_of_this_format".
5296 (argument_parser::read_format_flags): Convert warning_at call
5297 using location_from_offset to a call to format_warning_at_char.
5298 (argument_parser::read_any_format_left_precision): Likewise.
5299 (argument_parser::read_any_format_precision): Likewise.
5300 (argument_parser::read_any_other_modifier): Likewise.
5301 (argument_parser::find_format_char_info): Likewise, in three places.
5302 (argument_parser::parse_any_scan_set): Likewise, in one place.
5303 (argument_parser::handle_conversions): Likewise, in two places.
5304 (argument_parser::check_argument_type): Add param "fmt_param_loc"
5305 and use it to make a substring_loc. Pass the latter to
5306 check_format_types.
5307 (check_format_info_main): Add params "fmt_param_loc" and
5308 "format_string_cst". Convert warning_at calls using
5309 location_from_offset to calls to format_warning_at_char. Pass the
5310 new params to the arg_parser ctor. Pass "format_string_cst" to
5311 flag_chars.validate. Pass "fmt_param_loc" to
5312 arg_parser.check_argument_type.
5313 (check_format_types): Convert first param from a location_t
5314 to a const substring_loc & and rename to "fmt_loc". Attempt
5315 to extract the range of the relevant parameter and pass it
5316 to format_type_warning.
5317 (format_type_warning): Convert first param from a location_t
5318 to a const substring_loc & and rename to "fmt_loc". Add
5319 params "param_range" and "type". Replace calls to warning_at
5320 with calls to format_warning_at_substring.
5321
1c4d457e
DM
53222016-08-08 David Malcolm <dmalcolm@redhat.com>
5323
5324 * c-format.c (class flag_chars_t): New class.
5325 (struct length_modifier): New struct.
5326 (class argument_parser): New class.
5327 (flag_chars_t::flag_chars_t): New ctor.
5328 (flag_chars_t::has_char_p): New method.
5329 (flag_chars_t::add_char): New method.
5330 (flag_chars_t::validate): New method.
5331 (flag_chars_t::get_alloc_flag): New method.
5332 (flag_chars_t::assignment_suppression_p): New method.
5333 (argument_parser::argument_parser): New ctor.
5334 (argument_parser::read_any_dollar): New method.
5335 (argument_parser::read_format_flags): New method.
5336 (argument_parser::read_any_format_width): New method.
5337 (argument_parser::read_any_format_left_precision): New method.
5338 (argument_parser::read_any_format_precision): New method.
5339 (argument_parser::handle_alloc_chars): New method.
5340 (argument_parser::read_any_length_modifier): New method.
5341 (argument_parser::read_any_other_modifier): New method.
5342 (argument_parser::find_format_char_info): New method.
5343 (argument_parser::validate_flag_pairs): New method.
5344 (argument_parser::give_y2k_warnings): New method.
5345 (argument_parser::parse_any_scan_set): New method.
5346 (argument_parser::handle_conversions): New method.
5347 (argument_parser::check_argument_type): New method.
5348 (check_format_info_main): Introduce classes argument_parser
5349 and flag_chars_t, moving the code within the loop into methods
5350 of these classes. Make various locals "const".
5351
88fa5555
DM
53522016-08-05 David Malcolm <dmalcolm@redhat.com>
5353
5354 * c-common.c: Include "substring-locations.h".
5355 (get_cpp_ttype_from_string_type): New function.
5356 (g_string_concat_db): New global.
5357 (substring_loc::get_range): New method.
5358 * c-common.h (g_string_concat_db): New declaration.
5359 (class substring_loc): New class.
5360 * c-lex.c (lex_string): When concatenating strings, capture the
5361 locations of all tokens using a new obstack, and record the
5362 concatenation locations within g_string_concat_db.
5363 * c-opts.c (c_common_init_options): Construct g_string_concat_db
5364 on the ggc-heap.
5365
78169471
MP
53662016-07-29 Marek Polacek <polacek@redhat.com>
5367
638fc14f
MP
5368 PR c/71926
5369 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
5370 parentheses warning.
5371
78169471
MP
5372 PR c/71574
5373 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
5374
1225d6b1
ML
53752016-07-28 Martin Liska <mliska@suse.cz>
5376
5377 PR gcov-profile/68025
5378 * c-common.c (handle_no_profile_instrument_function_attribute):
5379
ec1e2a40
BE
53802016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
5381
5382 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
5383 BITS_PER_UNIT_LOG.
5384
5ec2cd9f
JM
53852016-07-25 Jason Merrill <jason@redhat.com>
5386
5387 PR c++/65970
5388 * c.opt (fconstexpr-loop-limit): New.
5389
9dc5773f 53902016-07-22 Martin Sebor <msebor@redhat.com>
2e6b45af
MS
5391
5392 PR c++/71675
5393 * c-common.c (resolve_overloaded_builtin): Avoid converting
5394 __atomic_compare_exchange_n return type to that of what its
5395 first argument points to.
5396
e3fe09c1
UB
53972016-07-22 Uros Bizjak <ubizjak@gmail.com>
5398
5399 * c-common.c: Use HOST_WIDE_INT_M1U instead of
5400 ~(unsigned HOST_WIDE_INT) 0.
5401
bc91c436
ML
54022016-07-22 Martin Liska <mliska@suse.cz>
5403
5404 PR gcov-profile/69028
5405 PR gcov-profile/62047
5406 * cilk.c (create_cilk_helper_decl): Set location of a new decl
5407 to the current_function_decl.
5408
451dcc66
JM
54092016-07-21 Jason Merrill <jason@redhat.com>
5410
5411 PR c++/65168
5412 * c-common.c (c_common_truthvalue_conversion): Check
5413 c_inhibit_evaluation_warnings for warning about address of
5414 reference.
5415
de6a69ee
DM
54162016-07-20 David Malcolm <dmalcolm@redhat.com>
5417
5418 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
5419 const char *.
5420
d022c55a
JM
54212016-07-15 Jason Merrill <jason@redhat.com>
5422
5423 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
5424
ddbbcb19
JJ
54252016-07-15 Jakub Jelinek <jakub@redhat.com>
5426
5427 PR c/71858
5428 * c-common.h (enum lookup_name_fuzzy_kind): Add
5429 FUZZY_LOOKUP_FUNCTION_NAME.
5430
d0cf395a
JM
54312016-07-08 Jason Merrill <jason@redhat.com>
5432
5433 P0145: Refining Expression Order for C++.
5434 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
5435 * c-opts.c: Adjust.
5436
98d44e93
MT
54372016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
5438
5439 PR c++/71214
5440 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
5441
f9d8d994
TS
54422016-06-29 Thomas Schwinge <thomas@codesourcery.com>
5443
5444 * c-pragma.h (enum pragma_kind): Rename
5445 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
5446 users.
5447
4aa83879
RB
54482016-06-29 Richard Biener <rguenther@suse.de>
5449
5450 PR middle-end/71002
5451 * c-common.c (c_common_get_alias_set): Remove union type punning case.
5452
a25bd9e6
JM
54532016-06-24 Jason Merrill <jason@redhat.com>
5454
5455 P0145R2: Refining Expression Order for C++.
5456 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
5457 MODIFY_EXPR.
5458
a86451b9
JJ
54592016-06-24 Jakub Jelinek <jakub@redhat.com>
5460
5461 * c-common.c (check_builtin_function_arguments): Require last
5462 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
5463 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
5464 if the last argument is pointer to enumerated or boolean type.
5465
1a4f11c8
DM
54662016-06-22 David Malcolm <dmalcolm@redhat.com>
5467
5468 PR c/70339
5469 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
5470 (lookup_name_fuzzy): New prototype.
5471
fe55692c
JDA
54722016-06-21 John David Anglin <danglin@gcc.gnu.org>
5473
5474 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
5475
4eb24e01
JM
54762016-06-14 Jason Merrill <jason@redhat.com>
5477
5478 P0145R2: Refining Expression Order for C++.
5479 * c.opt (fargs-in-order): New.
5480 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
5481
ef7cf206
JJ
54822016-06-13 Jakub Jelinek <jakub@redhat.com>
5483
0dda258b
JJ
5484 PR sanitizer/71498
5485 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
5486 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
5487
ef7cf206
JJ
5488 PR preprocessor/71183
5489 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
5490 to cb_get_source_date_epoch.
5491
50b15873
JJ
54922016-06-10 Jakub Jelinek <jakub@redhat.com>
5493
5494 PR c/68657
5495 * c.opt (Wpsabi): Add Warning flag.
5496
4d926e34
MS
54972016-06-10 Martin Sebor <msebor@redhat.com>
5498
5499 PR c/71392
14ec014e 5500 * c-common.c (handle_nonnull_attribute): Accept
4d926e34
MS
5501 the nonnull attribute in type-generic builtins.
5502
e01b4e16
MS
55032016-06-09 Martin Sebor <msebor@redhat.com>
5504
5505 PR c/70883
5506 * c-common.c (builtin_function_validate_nargs): Make text of error
5507 message consistent with others like it.
5508
44a845ca
MS
55092016-06-08 Martin Sebor <msebor@redhat.com>
5510 Jakub Jelinek <jakub@redhat.com>
5511
5512 PR c++/70507
5513 PR c/68120
5514 * c-common.c (check_builtin_function_arguments): Handle
5515 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
5516
a80a7051
RB
55172016-06-08 Richard Biener <rguenther@suse.de>
5518
5519 * c-common.c (parse_optimize_options): Improve diagnostic messages.
5520
bfd67b47
RB
55212016-06-07 Richard Biener <rguenther@suse.de>
5522
5523 PR c/61564
5524 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
5525 options and warn about others.
5526
15c98b2e
ES
55272016-06-01 Eduard Sanou <dhole@openmailbox.org>
5528
5529 * c-common.c (get_source_date_epoch): Rename to
5530 cb_get_source_date_epoch.
5531 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
5532 message when the parsing fails. Use error_at instead of fatal_error.
5533 * c-common.h (get_source_date_epoch): Rename to
5534 cb_get_source_date_epoch.
5535 * c-common.h (cb_get_source_date_epoch): Prototype.
5536 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
5537 * c-common.h (c_omp_region_type): Remove trailing comma.
5538 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
5539 * c-lex.c (c_lex_with_flags): Remove initialization of
5540 pfile->source_date_epoch.
5541
00631022
JJ
55422016-05-30 Jakub Jelinek <jakub@redhat.com>
5543
5544 PR c++/71349
5545 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
5546 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
5547 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
5548 instead of C_OMP_CLAUSE_SPLIT_FOR.
5549
f17a223d
RB
55502016-05-24 Richard Biener <rguenther@suse.de>
5551
5552 PR middle-end/70434
5553 PR c/69504
5554 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
5555 (convert_vector_to_array_for_subscript): ... this.
5556 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
5557 VIEW_CONVERT_EXPR to an array type. Rename to ...
5558 (convert_vector_to_array_for_subscript): ... this.
5559
4f2e1536
MP
55602016-05-12 Marek Polacek <polacek@redhat.com>
5561
5562 PR c/70756
5563 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
5564 size_in_bytes and pass LOC to it.
5565
d6e83a8d
MM
55662016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
5567
5568 PR c/43651
5569 * c.opt (Wduplicate-decl-specifier): New option.
5570
5c3a10fb
MP
55712016-05-11 Marek Polacek <polacek@redhat.com>
5572
5573 PR c++/71024
5574 * c-common.c (diagnose_mismatched_attributes): New function.
5575 * c-common.h (diagnose_mismatched_attributes): Declare.
5576
deef7113
MP
55772016-05-04 Marek Polacek <polacek@redhat.com>
5578
5579 * c.opt (Wdangling-else): New option.
5580
79ce98bc
MP
55812016-05-03 Marek Polacek <polacek@redhat.com>
5582
5583 PR c/70859
5584 * c-common.c (builtin_function_validate_nargs): Add location
5585 parameter. Use it.
5586 (check_builtin_function_arguments): Add location and arguments
5587 parameters. Use them.
5588 * c-common.h (check_builtin_function_arguments): Update declaration.
5589
381cdae4
RB
55902016-05-03 Richard Biener <rguenther@suse.de>
5591
5592 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
5593 allow call args to gimplify to SSA names.
5594
1d793c34
MP
55952016-05-03 Marek Polacek <polacek@redhat.com>
5596
5597 * c-common.h (enum c_omp_region_type): Remove stray comma.
5598
77886428
CP
55992016-05-02 Cesar Philippidis <cesar@codesourcery.com>
5600
5601 * c-common.h (enum c_omp_region_type): Define.
5602
697e0b28
RS
56032016-05-02 Richard Sandiford <richard.sandiford@arm.com>
5604
5605 * c-common.c (shorten_compare): Use wi::to_wide.
5606
e7ff0319
CP
56072016-04-29 Cesar Philippidis <cesar@codesourcery.com>
5608
5609 PR middle-end/70626
5610 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
5611 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
5612 reduction clauses in acc parallel loops.
5613
2fff3db8
MP
56142016-04-29 Marek Polacek <polacek@redhat.com>
5615
5616 PR c/70852
5617 * c-common.c (warn_for_memset): Check domain before accessing it.
5618
509063eb
DV
56192016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
5620
5621 PR/69089
5622 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
5623 "aligned" attribute.
5624
b632761d
JM
56252016-04-28 Jason Merrill <jason@redhat.com>
5626
5627 * c-lex.c (c_common_has_attribute): Handle nodiscard.
5628
174f6622
ES
56292016-04-28 Eduard Sanou <dhole@openmailbox.org>
5630 Matthias Klose <doko@debian.org>
5631
5632 * c-common.c (get_source_date_epoch): New function, gets the environment
7365279f 5633 variable SOURCE_DATE_EPOCH and parses it as long long with error
174f6622
ES
5634 handling.
5635 * c-common.h (get_source_date_epoch): Prototype.
5636 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
5637
6bc2bb18
RB
56382015-04-27 Ryan Burn <contact@rnburn.com>
5639
5640 PR c++/69024
5641 PR c++/68997
5642 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
5643 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
5644 external linkage.
5645 (cilk_detect_and_unwrap): Corresponding changes.
5646 (extract_free_variables): Don't extract free variables from
5647 AGGR_INIT_EXPR slot.
5648 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
5649 (cilk_recognize_spawn): Likewise.
5650
c1e1f433
BS
56512016-04-27 Bernd Schmidt <bschmidt@redhat.com>
5652
5653 * c.opt (Wmemset-elt-size): New option.
5654 * c-common.c (warn_for_memset): New function.
5655 * c-common.h (warn_for_memset): Declare.
5656
d067e05f
JM
56572016-04-25 Jason Merrill <jason@redhat.com>
5658
5659 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
5660 No longer static.
5661 * c-common.h: Declare it.
5662 * c-lex.c (c_common_has_attribute): Add maybe_unused.
5663
9aa36ae5
JM
56642016-04-22 Jason Merrill <jason@redhat.com>
5665
5666 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
5667
477d4906
IV
56682016-04-20 Ilya Verbin <ilya.verbin@intel.com>
5669
5670 PR c++/69363
5671 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
5672 * c-common.h (c_finish_cilk_clauses): Remove declaration.
5673
fe37c7af
MM
56742016-04-18 Michael Matz <matz@suse.de>
5675
5676 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
5677 and SET_DECL_ALIGN.
5678
23f2660f
EB
56792016-04-17 Eric Botcazou <ebotcazou@adacore.com>
5680
5681 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
5682 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
5683 to incomplete types.
5684 (dump_nested_type): Remove redundant tests and tidy up.
5685 (print_ada_declaration): Also set TREE_VISITED on the declaration of
5686 a type which is the typedef of an original type.
5687
1e77281b
MP
56882016-04-15 Marek Polacek <polacek@redhat.com>
5689
5690 PR c/70651
5691 * c-common.c (build_va_arg): Change two asserts into errors and return
5692 error_mark_node.
5693
b3a77f21
MP
56942016-04-13 Marek Polacek <polacek@redhat.com>
5695
5696 PR c++/70639
5697 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
5698 for switch statements, too.
5699
322b8466
JM
57002016-03-28 Jason Merrill <jason@redhat.com>
5701
5702 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
5703
fbdb6baf
MP
57042016-03-23 Marek Polacek <polacek@redhat.com>
5705
5706 PR c++/69884
5707 * c.opt (Wignored-attributes): New option.
5708
5c240f4d
DM
57092016-03-22 David Malcolm <dmalcolm@redhat.com>
5710
5711 PR c/69993
5712 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
5713 diagnostic text, reversing the order of the warning and note so
5714 that they appear in source order.
5715
14ba7b28
MP
57162016-03-17 Marek Polacek <polacek@redhat.com>
5717
5718 PR c/69407
5719 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
5720 operations.
5721
08a1cadc
JM
57222016-03-14 Jason Merrill <jason@redhat.com>
5723
2aaeea19
JM
5724 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
5725
08a1cadc
JM
5726 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
5727
c06d25bb
RB
57282016-03-09 Richard Biener <rguenther@suse.de>
5729
5730 PR c/70143
5731 * c-common.c (strict_aliasing_warning): Add back
5732 alias_sets_conflict_p check.
5733
80aac5c8
JM
57342016-03-08 Jason Merrill <jason@redhat.com>
5735
5736 * c-opts.c (set_std_cxx1z): Don't enable concepts.
5737
64b23c13
DM
57382016-03-04 David Malcolm <dmalcolm@redhat.com>
5739
5740 PR c/68187
5741 * c-indentation.c (get_visual_column): Move code to determine next
5742 tab stop to...
5743 (next_tab_stop): ...this new function.
5744 (line_contains_hash_if): Delete function.
5745 (detect_preprocessor_logic): Delete function.
5746 (get_first_nws_vis_column): New function.
5747 (detect_intervening_unindent): New function.
5748 (should_warn_for_misleading_indentation): Replace call to
5749 detect_preprocessor_logic with a call to
5750 detect_intervening_unindent.
5751
729526f5
DM
57522016-03-04 David Malcolm <dmalcolm@redhat.com>
5753
5754 PR c/68187
5755 * c-indentation.c (should_warn_for_misleading_indentation): When
5756 suppressing warnings about cases where the guard and body are on
5757 the same column, only use the first non-whitespace column in place
5758 of the guard token column when dealing with "else" clauses.
5759 When rejecting aligned BODY and NEXT, loosen the requirement
5760 from equality with the first non-whitespace of guard to simply
5761 that they not be indented relative to it.
5762
e9a35493
RB
57632016-03-04 Richard Biener <rguenther@suse.de>
5764
5765 PR c++/70054
5766 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
5767 instead of alias_sets_conflict_p.
5768
1be56bc5
MP
57692016-03-01 Marek Polacek <polacek@redhat.com>
5770
5771 PR c++/69795
5772 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
5773 any DECL.
5774
35886f0b
MS
57752016-02-22 Martin Sebor <msebor@redhat.com>
5776
5777 PR middle-end/69780
5778 * c-common.c (check_builtin_function_arguments): Validate and
5779 reject invalid arguments to __builtin_alloca_with_align.
5780
4246c8da
MW
57812016-02-20 Mark Wielaard <mjw@redhat.com>
5782
5783 PR c/28901
5784 * c.opt (Wunused-const-variable): Turn into Alias for...
5785 (Wunused-const-variable=): New option.
5786
268be88c
BE
57872016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
5788
5789 PR c++/69865
5790 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
5791 here...
5792 (c_common_init_options): ...to here.
5793 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
5794
871b3f47
JJ
57952016-02-19 Jakub Jelinek <jakub@redhat.com>
5796
5797 PR c++/69826
5798 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
5799 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
5800 flag_preprocess_only.
5801
bf14eba2
JJ
58022016-02-16 Jakub Jelinek <jakub@redhat.com>
5803
5804 PR c/69835
5805 * c.opt (Wnonnull-compare): Enable for -Wall.
5806
ba6b3795
JJ
58072016-02-15 Jakub Jelinek <jakub@redhat.com>
5808
5809 PR c++/69797
5810 * c-common.c (sync_resolve_size): Diagnose too few arguments
5811 even when params is non-NULL empty vector.
5812
a011cd92
BS
58132016-02-08 Bernd Schmidt <bschmidt@redhat.com>
5814
5815 PR target/60410
5816 * c.opt (fshort-double): Remove.
5817
46cb9332
MS
58182016-02-05 Martin Sebor <msebor@redhat.com>
5819
5820 PR c++/69662
5821 * c.opt (Warning options): Update -Wplacement-new to take
5822 an optional argument.
5823
e1b81f2b
JJ
58242016-02-01 Jakub Jelinek <jakub@redhat.com>
5825
5826 PR preprocessor/69543
5827 PR c/69558
5828 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
5829 instead of loc to control_warning_option.
5830
b6adbb9f
NS
58312016-02-01 Nathan Sidwell <nathan@codesourcery.com>
5832
5833 * c.opt (fopenacc-dim=): New option.
5834
5d70666e
RB
58352016-01-27 Ryan Burn <contact@rnburn.com>
5836
5837 PR cilkplus/69267
5838 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
5839 gimplify_arg. Removed superfluous post_p argument.
5840 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
5841 superfluous post_p argument.
5842 * c-gimplify.c (c_gimplify_expr): Likewise.
5843
01e1dea3
DM
58442016-01-26 David Malcolm <dmalcolm@redhat.com>
5845
5846 PR other/69006
5847 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
5848 pp_newline_and_flush with pp_flush.
5849
9f04a53e
MS
58502016-01-20 Martin Sebor <msebor@redhat.com>
5851
5852 PR c/69405
5853 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
5854 an incompatible argument when the argument isn't a valid tree node.
5855
7f26f7df
JM
58562016-01-18 Jason Merrill <jason@redhat.com>
5857
5858 PR c++/68767
5859 * c-common.c (check_function_arguments_recurse): Fold the whole
5860 COND_EXPR, not just the condition.
5861
f62bf092
TV
58622016-01-18 Tom de Vries <tom@codesourcery.com>
5863
5864 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
5865 classify as loop clause.
5866
e0a575ff
JJ
58672016-01-15 Jakub Jelinek <jakub@redhat.com>
5868
5869 PR bootstrap/68271
5870 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
5871 C++ FE no longer has limit on number of pragmas.
5872
58732015-01-14 Ryan Burn <contact@rnburn.com>
b6e3db06
RB
5874
5875 PR c++/69048
5876 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
c47eaca6 5877 to add missing cleanup point.
b6e3db06 5878
c7df95d8
DM
58792016-01-14 David Malcolm <dmalcolm@redhat.com>
5880
5881 PR c++/68819
5882 * c-indentation.c (get_visual_column): Add location_t param.
5883 Handle the column number being zero by effectively disabling the
5884 warning, with an "inform".
5885 (should_warn_for_misleading_indentation): Add location_t argument
5886 for all uses of get_visual_column.
5887
21efdd80
PP
58882016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
5889
5890 PR c++/69029
5891 * c-indentation.c (should_warn_for_misleading_indentation):
5892 Don't warn about do-while statements.
5893
7a127fa7
MS
58942016-01-07 Martin Sebor <msebor@redhat.com>
5895
5896 PR c/68966
5897 * c-common.c (sync_resolve_size): Reject first argument when it's
5898 a pointer to _Bool.
5899
c589e975
DM
59002016-01-05 David Malcolm <dmalcolm@redhat.com>
5901
5902 PR c/69122
5903 * c-indentation.c (get_visual_column): Remove default argument.
5904 (should_warn_for_misleading_indentation): For the multiline case,
5905 update call to get_visual_column for next_stmt_exploc so that it
5906 captures the location of the first non-whitespace character in the
5907 relevant line. Don't issue warnings if there is non-whitespace
5908 before the next statement.
5909
818ab71a
JJ
59102016-01-04 Jakub Jelinek <jakub@redhat.com>
5911
5912 Update copyright years.
5913
745e411d
DM
59142015-12-21 David Malcolm <dmalcolm@redhat.com>
5915
5916 * c-common.c (binary_op_error): Convert first param from
5917 location_t to rich_location * and use it when emitting an error.
5918 * c-common.h (binary_op_error): Convert first param from
5919 location_t to rich_location *.
5920
de67c4c3
DM
59212015-12-16 David Malcolm <dmalcolm@redhat.com>
5922
5923 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
5924 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
5925
4a38b02b
IV
59262015-12-15 Ilya Verbin <ilya.verbin@intel.com>
5927
5928 * c-common.c (c_common_attribute_table): Handle "omp declare target
5929 link" attribute.
5930
54d62f51
JJ
59312015-12-14 Jakub Jelinek <jakub@redhat.com>
5932
5933 PR c/68833
5934 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
5935
8d4227c8
TB
59362014-12-12 Tobias Burnus <burnus@net-b.de>
5937
5938 PR fortran/68815
5939 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
5940 specifiers (%d, %i,%u and %c).
5941
f6069ccc
DM
59422015-12-10 David Malcolm <dmalcolm@redhat.com>
5943
5944 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
5945
63bbf46d
JJ
59462015-12-08 Jakub Jelinek <jakub@redhat.com>
5947
5948 PR c/48088
5949 PR c/68657
5950 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
5951 * c-pragma.c (handle_pragma_diagnostic): Adjust
5952 control_warning_option caller.
5953
f79520bb
DM
59542015-12-07 David Malcolm <dmalcolm@redhat.com>
5955
5956 * c-common.c (c_cpp_error): Update for change to
5957 rich_location::set_range.
5958
b3d5bc62
JJ
59592015-12-04 Paolo Bonzini <bonzini@gnu.org>
5960
5961 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
5962 shifting 1 out of the sign bit.
5963
59642015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
5965
5966 * c-common.c (c_common_attribute_table[]): Update max arguments
5967 count for "simd" attribute.
5968 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
5969
6eb4a537
JJ
59702015-12-03 Jakub Jelinek <jakub@redhat.com>
5971
5972 PR preprocessor/57580
5973 * c-ppoutput.c (print): Change printed field to bool.
5974 Move src_file last for smaller padding.
5975 (init_pp_output): Set print.printed to false instead of 0.
5976 (scan_translation_unit): Fix up formatting. Set print.printed
5977 to true after printing something other than newline.
5978 (scan_translation_unit_trad): Set print.printed to true instead of 1.
5979 (maybe_print_line_1): Set print.printed to false instead of 0.
5980 (print_line_1): Likewise.
5981 (do_line_change): Set print.printed to true instead of 1.
5982 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
5983 dump_macro): Set print.printed to false after printing newline.
5984
4250754e
JM
59852015-12-02 Jason Merrill <jason@redhat.com>
5986
f479b43d
JM
5987 * c-common.c (fold_for_warn): New.
5988 (warn_logical_operator, warn_tautological_cmp)
5989 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
5990
4250754e
JM
5991 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
5992 (c_fully_fold_internal, decl_constant_value_for_optimization):
5993 Move to c/c-fold.c.
5994 * c-common.h: Don't declare decl_constant_value_for_optimization.
5995
e9e32ee6
JM
59962015-12-02 Joseph Myers <joseph@codesourcery.com>
5997
5998 PR c/68162
5999 * c-common.h (c_build_qualified_type): Add extra default
6000 arguments.
6001
37d5ad46
JB
60022015-12-01 Julian Brown <julian@codesourcery.com>
6003 Cesar Philippidis <cesar@codesourcery.com>
6004 James Norris <James_Norris@mentor.com>
6005
6006 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
6007 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
6008 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
6009
f07862c7
EB
60102015-11-30 Eric Botcazou <ebotcazou@adacore.com>
6011
6012 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
6013 (decl_sloc_common): Delete and move bulk of processing to...
6014 (decl_sloc): ...here.
6015 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
6016 (dump_ada_double_name): Remove S parameter and compute the suffix.
6017 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
6018 element type and deal with an anonymous one.
6019 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
6020 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
6021 and remove reference to QUAL_UNION_TYPE.
6022 (dump_nested_types): Make 2 passes on the fields and move bulk to...
6023 (dump_nested_type): ...here. New function extracted from above.
6024 Generate a full declaration for anonymous element type of arrays.
6025 (print_ada_declaration): Really skip anonymous declarations. Remove
6026 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
6027 Clean up processing of declarations of array types and objects.
6028 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
6029 Remove obsolete code and tidy up.
6030
75c8aac3
JH
60312015-11-29 Jan Hubicka <hubicka@ucw.cz>
6032
6033 PR c/67581
6034 * c-common.c (handle_transparent_union_attribute): Update
6035 also type variants.
6036
b58d3df2
ML
60372015-11-27 Martin Liska <mliska@suse.cz>
6038
6039 PR c++/68312
6040 * array-notation-common.c (cilkplus_extract_an_triplets):
6041 Release vector of vectors.
6042 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
6043
89a01fcf
EB
60442015-11-26 Eric Botcazou <ebotcazou@adacore.com>
6045
6046 PR c++/68527
6047 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
6048 (print_ada_struct_decl): Likewise.
6049
cc5c5226
IZ
60502015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
6051
6052 PR c++/68001
6053 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
6054 * cilk.c (recognize_spawn): Determine location in a more precise
6055 way.
6056
269adb9d
JM
60572015-11-19 Jason Merrill <jason@redhat.com>
6058
6059 * c-common.c (shorten_compare): But look through macros from
6060 system headers.
6061
d0eccfcd
JM
60622015-11-18 Jason Merrill <jason@redhat.com>
6063
6064 * c-common.c (shorten_compare): Don't -Wtype-limits if the
6065 non-constant operand comes from a macro.
6066
3e44547c
JM
60672015-11-17 Jason Merrill <jason@redhat.com>
6068
6069 PR bootstrap/68346
6070 * c-common.c (warn_tautological_cmp): Fold before checking for
6071 constants.
6072
0f62c7a0
MP
60732015-11-16 Marek Polacek <polacek@redhat.com>
6074
6075 PR c++/68362
6076 * c-common.c (check_case_bounds): Fold low and high cases.
6077
a868811e
MP
60782015-11-16 Marek Polacek <polacek@redhat.com>
6079
6080 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
6081 * c-common.c (c_common_get_alias_set): Likewise.
6082 (handle_visibility_attribute): Likewise.
6083
fff77217
KY
60842015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
6085
6086 * c-common.c (handle_simd_attribute): New.
6087 (struct attribute_spec): Add entry for "simd".
6088 (handle_simd_attribute): New.
6089
269e63b7
KT
60902015-11-13 Kai Tietz <ktietz70@googlemail.com>
6091
6092 * c-lex.c (interpret_float): Use fold_convert.
6093
ebedc9a3
DM
60942015-11-13 David Malcolm <dmalcolm@redhat.com>
6095
6096 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
6097 and store it on the result.
6098 * c-opts.c (c_common_init_options): Set
6099 global_dc->colorize_source_p.
6100
6e232ba4
JN
61012015-11-12 James Norris <jnorris@codesourcery.com>
6102 Joseph Myers <joseph@codesourcery.com>
6103
7365279f 6104 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
6e232ba4
JN
6105 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
6106 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
6107 PRAGMA_OACC_CLAUSE_LINK.
6108
e78bede6
MP
61092015-11-11 Marek Polacek <polacek@redhat.com>
6110
6111 PR c/68107
6112 PR c++/68266
6113 * c-common.c (valid_array_size_p): New function.
6114 * c-common.h (valid_array_size_p): Declare.
6115
3f8257db 61162015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4ac93c7c
DH
6117
6118 PR bootstrap/68271
6119 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
6120
69f293c9
AM
61212015-11-11 Andrew MacLeod <amacleod@redhat.com>
6122
6123 * array-notation-common.c: Remove unused header files.
6124 * c-ada-spec.c: Likewise.
6125 * c-cilkplus.c: Likewise.
6126 * c-common.c: Likewise.
6127 * c-cppbuiltin.c: Likewise.
6128 * c-dump.c: Likewise.
6129 * c-format.c: Likewise.
6130 * c-gimplify.c: Likewise.
6131 * c-indentation.c: Likewise.
6132 * c-lex.c: Likewise.
6133 * c-omp.c: Likewise.
6134 * c-opts.c: Likewise.
6135 * c-pch.c: Likewise.
6136 * c-ppoutput.c: Likewise.
6137 * c-pragma.c: Likewise.
6138 * c-pretty-print.c: Likewise.
6139 * c-semantics.c: Likewise.
6140 * c-ubsan.c: Likewise.
6141 * cilk.c: Likewise.
6142 * stub-objc.c: Likewise.
6143
3a40d81d
NS
61442015-11-09 Thomas Schwinge <thomas@codesourcery.com>
6145 Cesar Philippidis <cesar@codesourcery.com>
6146 James Norris <jnorris@codesourcery.com>
6147 Julian Brown <julian@codesourcery.com>
6148 Nathan Sidwell <nathan@codesourcery.com>
6149
6150 * c-pragma.c (oacc_pragmas): Add "routine".
6151 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
6152
ee45a32d
EB
61532015-11-08 Eric Botcazou <ebotcazou@adacore.com>
6154
6155 * c-common.c (c_common_attributes): Add scalar_storage_order.
6156 (handle_scalar_storage_order_attribute): New function.
6157 * c-pragma.c (global_sso): New variable.
6158 (maybe_apply_pragma_scalar_storage_order): New function.
6159 (handle_pragma_scalar_storage_order): Likewise.
6160 (init_pragma): Register scalar_storage_order.
6161 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
6162 * c.opt (Wscalar-storage-order): New warning.
6163 (fsso-struct=): New option.
6164
eb11eb15
MS
61652015-11-08 Martin Sebor <msebor@redhat.com>
6166
6167 * c.opt (Wplacement-new): Add a period to the end of a sentence.
6168
0aad0198
RS
61692015-11-07 Richard Sandiford <richard.sandiford@arm.com>
6170
6171 * c-common.c: Don't undef DEF_BUILTIN.
6172
8a645150
DM
61732015-11-06 David Malcolm <dmalcolm@redhat.com>
6174
6175 * c-common.c (c_cpp_error): Convert parameter from location_t to
6176 rich_location *. Eliminate the "column_override" parameter and
6177 the call to diagnostic_override_column.
6178 Update the "done_lexing" clause to set range 0
6179 on the rich_location, rather than overwriting a location_t.
6180 * c-common.h (c_cpp_error): Convert parameter from location_t to
6181 rich_location *. Eliminate the "column_override" parameter.
6182
7a5e4956
CP
61832015-11-05 Cesar Philippidis <cesar@codesourcery.com>
6184 Thomas Schwinge <thomas@codesourcery.com>
6185 James Norris <jnorris@codesourcery.com>
6186
6187 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
6188 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
6189 clauses with parallel and kernels and loops.
6190 * c-pragma.h (enum pragma_omp_clause): Add entries for
6191 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
6192 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
6193 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
6194 INDEPENDENT,SEQ}.
6195 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
6196
e2f5cc96
MS
61972015-11-05 Martin Sebor <msebor@redhat.com>
6198
6199 PR c++/67942
6200 * c.opt (-Wplacement-new): New option.
6201
e01d41e5
JJ
62022015-11-05 Jakub Jelinek <jakub@redhat.com>
6203
6204 * c-common.h (c_finish_omp_atomic): Add TEST argument.
6205 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
6206 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
6207 save_expr or create_tmp_var* if TEST is true.
6208 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
6209 Don't call add_stmt here.
6210 (struct c_omp_check_loop_iv_data): New type.
6211 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
6212 c_omp_check_loop_iv_exprs): New functions.
6213 (c_omp_split_clauses): Adjust for lastprivate being allowed on
6214 distribute.
6215 (c_omp_declare_simd_clauses_to_numbers): Change
6216 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
6217 (c_omp_declare_simd_clauses_to_decls): Similarly change those
6218 from numbers to PARM_DECLs.
6219
595278be
MM
62202015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
6221
6222 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
6223 flag_checking.
6224
3f8257db 62252015-11-03 Bernd Schmidt <bschmidt@redhat.com>
c85158de
MS
6226
6227 PR c++-common/67882
b3d5bc62
JJ
6228 * c-common.h (fold_offsetof_1): Add argument.
6229 * c-common.c (fold_offsetof_1): Diagnose more invalid
c85158de
MS
6230 offsetof expressions that reference elements past the end of
6231 an array.
6232
4bf9e5a8
TS
62332015-11-03 Thomas Schwinge <thomas@codesourcery.com>
6234 Chung-Lin Tang <cltang@codesourcery.com>
6235
6236 * c-pragma.c (oacc_pragmas): Add "atomic".
6237 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
6238
3b1661a9
ES
62392015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
6240
6241 * c-common.c (handle_target_clones_attribute): New.
6242 (c_common_attribute_table): Add handle_target_clones_attribute.
6243 (handle_always_inline_attribute): Add check on target_clones attribute.
6244 (handle_target_attribute): Ditto.
6245
2adfab87
AM
62462015-10-29 Andrew MacLeod <amacleod@redhat.com>
6247
6248 * array-notation-common.c: Reorder #include's and remove duplicates.
6249 * c-ada-spec.c: Likewise.
6250 * c-cilkplus.c: Likewise.
6251 * c-common.c: Likewise.
6252 * c-cppbuiltin.c: Likewise.
6253 * c-dump.c: Likewise.
6254 * c-format.c: Likewise.
6255 * c-gimplify.c: Likewise.
6256 * c-indentation.c: Likewise.
6257 * c-lex.c: Likewise.
6258 * c-omp.c: Likewise.
6259 * c-opts.c: Likewise.
6260 * c-pch.c: Likewise.
6261 * c-ppoutput.c: Likewise.
6262 * c-pragma.c: Likewise.
6263 * c-pretty-print.c: Likewise.
6264 * c-semantics.c: Likewise.
6265 * c-ubsan.c: Likewise.
6266 * cilk.c: Likewise.
6267 * stub-objc.c: Likewise.
6268
d90ec4f2
JM
62692015-10-28 Jason Merrill <jason@redhat.com>
6270
6271 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
6272
88bae6f4
TS
62732015-10-27 Thomas Schwinge <thomas@codesourcery.com>
6274 James Norris <jnorris@codesourcery.com>
6275 Cesar Philippidis <cesar@codesourcery.com>
6276
6277 PR c/64765
6278 PR c/64880
6279 * c-common.h (c_oacc_split_loop_clauses): Declare function.
6280 * c-omp.c (c_oacc_split_loop_clauses): New function.
6281
b1726d6c
MS
62822015-10-21 Martin Sebor <msebor@redhat.com>
6283
6284 PR driver/68043
6285 * c.opt: End each sentence that describes an option with a period.
6286
fa60eeb9
MP
62872015-10-20 Marek Polacek <polacek@redhat.com>
6288
6289 * array-notation-common.c (is_cilkplus_vector_p): Define.
6290 * c-common.h (is_cilkplus_vector_p): Declare.
6291
95979049
MP
62922015-10-20 Marek Polacek <polacek@redhat.com>
6293
6294 * c.opt (std=gnu++11): Do not describe as experimental.
6295 (std=gnu++14): Likewise.
6296
2a9fb712
JM
62972015-10-19 Jason Merrill <jason@redhat.com>
6298
6299 * c-cppbuiltin.c (c_cpp_builtins): Define
6300 __cpp_nontype_template_args.
6301
13b380a3
JM
63022015-10-19 Jason Merrill <jason@redhat.com>
6303
6304 * c-cppbuiltin.c (c_cpp_builtins): Define
6305 __cpp_enumerator_attributes, __cpp_fold_expressions,
6306 __cpp_unicode_characters.
6307
d9a6bd32
JJ
63082015-10-13 Jakub Jelinek <jakub@redhat.com>
6309 Aldy Hernandez <aldyh@redhat.com>
6310
6311 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
6312 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
6313 (c_define_builtins): Likewise.
6314 * c-common.h (enum c_omp_clause_split): Add
6315 C_OMP_CLAUSE_SPLIT_TASKLOOP.
6316 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
6317 (c_finish_omp_for): Add ORIG_DECLV argument.
6318 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
6319 201511 instead of 201307.
6320 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
6321 OMP_CRITICAL_CLAUSES to it.
6322 (c_finish_omp_ordered): Add CLAUSES argument, set
6323 OMP_ORDERED_CLAUSES to it.
6324 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
6325 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
6326 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
6327 constructs and new OpenMP 4.5 clauses. Clear
6328 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
6329 verification code.
6330 * c-pragma.c (omp_pragmas_simd): Add taskloop.
6331 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
6332 (enum pragma_omp_clause): Add
6333 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
6334 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
6335
624d31fe
RS
63362015-10-05 Richard Sandiford <richard.sandiford@arm.com>
6337
6338 * c-lex.c (interpret_float): Use real_equal instead of
6339 REAL_VALUES_EQUAL.
6340
b8fd7909
JM
63412015-10-04 Jason Merrill <jason@redhat.com>
6342
6343 Implement N4514, C++ Extensions for Transactional Memory.
6344 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
6345 (c_common_attribute_table): Add transaction_safe_dynamic.
6346 transaction_safe now affects type identity.
6347 (handle_tm_attribute): Handle transaction_safe_dynamic.
6348 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
6349 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
6350 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
6351 (D_TRANSMEM): New.
6352 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
6353 * c-pretty-print.c (pp_c_attributes_display): Don't print
6354 transaction_safe in C++.
6355
12651878
MP
63562015-10-02 Marek Polacek <polacek@redhat.com>
6357
6358 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
6359
3e3b8d63
MP
63602015-10-02 Marek Polacek <polacek@redhat.com>
6361
6362 PR c/64249
6363 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
6364 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
6365 * c.opt (Wduplicated-cond): New option.
6366
0d1a8f75
JM
63672015-10-01 Joseph Myers <joseph@codesourcery.com>
6368
6369 * c.opt (std=c11): Do not describe as experimental.
6370 (std=gnu11): Likewise.
6371 (std=iso9899:2011): Likewise.
6372
3e32ee19
NS
63732015-09-28 Nathan Sidwell <nathan@codesourcery.com>
6374
6375 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
6376 (DEF_FUNCTION_TYPE_VAR_11): Delete.
6377
974348ee
MP
63782015-09-25 Marek Polacek <polacek@redhat.com>
6379
6380 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
6381 (ubsan_instrument_shift): Likewise.
6382
15dbc1a6
MP
63832015-09-25 Marek Polacek <polacek@redhat.com>
6384
6385 PR sanitizer/64906
6386 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
6387
6b95d7cc
PP
63882015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
6389
6390 * c-indentation.c (should_warn_for_misleading_indentation):
6391 Compare next_stmt_vis_column with guard_line_first_nws instead
6392 of with guard_line_vis_column.
6393
c1822f9c
MLI
63942015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
6395
6396 PR c/49654
6397 PR c/49655
6398 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
6399 options and options not valid for the current language.
6400
d5398058
PP
64012015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
6402
6403 * c-indentation.c (should_warn_for_misleading_indentation):
6404 Float out and consolidate the calls to get_visual_column that
6405 are passed guard_exploc as an argument. Compare
6406 next_stmt_vis_column with guard_line_first_nws instead of with
6407 body_line_first_nws.
6408
6b333269
NS
64092015-09-22 Nathan Sidwell <nathan@codesourcery.com>
6410
6411 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
6412 Wnamespaces): New C++ warnings.
6413
a75f1574
JM
64142015-09-22 Jason Merrill <jason@redhat.com>
6415
6416 * c-common.h (abi_compat_version_crosses): New.
6417 (warn_abi_version): Declare.
6418 * c-common.c: Define it.
6419 * c-opts.c (c_common_post_options): Handle it.
6420 flag_abi_compat_version defaults to 8.
6421
bdaaa8b7
VV
64222015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
6423
6424 Complete the implementation of N4230, Nested namespace definition.
6425 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
6426 __cpp_nested_namespace_definitions.
6427
eaa797e8
MLI
64282015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
6429
6430 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
6431
c4914de6
MLI
64322015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
6433
6434 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
6435 when warning.
6436 * c-pragma.h (pragma_lex): Add optional loc argument.
6437
fcb87c50
MM
64382015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
6439
6440 * c-format.c (check_format_arg): Adjust to use common block size in all
6441 object pools.
6442
31bdd08a
DM
64432015-09-15 David Malcolm <dmalcolm@redhat.com>
6444
6445 * c-format.c (location_from_offset): Update for change in
6446 signature of location_get_source_line.
6447 * c-indentation.c (get_visual_column): Likewise.
6448 (line_contains_hash_if): Likewise.
6449
aa9f4b4c
MP
64502015-09-14 Marek Polacek <polacek@redhat.com>
6451
6452 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
6453 setting various warnings.
6454
aa256c4a
MP
64552015-09-14 Marek Polacek <polacek@redhat.com>
6456
6457 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
6458 a negative value.
6459
0f876f22
MW
64602015-09-11 Mark Wielaard <mjw@redhat.com>
6461
6462 PR c/28901
6463 * c.opt (Wunused-variable): Option from common.opt.
6464 (Wunused-const-variable): New option.
6465
273aa49e
PC
64662015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
6467
6468 PR c++/53184
6469 * c.opt ([Wsubobject-linkage]): Add.
6470
1807ffc1
MS
64712015-09-03 Martin Sebor <msebor@redhat.com>
6472
6473 PR c/66516
6474 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
6475 functions.
6476 * c-common.c (reject_gcc_builtin): Define.
6477
38942840
BI
64782015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
6479
6480 PR middle-end/60586
6481 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
6482 prototype.
6483 * c-gimplify.c (c_gimplify_expr): Added a call to the function
6484 cilk_gimplify_call_params_in_spawned_fn.
6485 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
6486 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
6487 unwrapping.
6488
c316b5e4
MP
64892015-08-25 Marek Polacek <polacek@redhat.com>
6490
6491 PR middle-end/67330
6492 * c-common.c (handle_weak_attribute): Don't check whether the
6493 visibility can be changed here.
6494
584a7c46
MLI
64952015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
6496
6497 * c-lex.c (c_lex_with_flags): Use explicit locations.
6498
a79683d5
TS
64992015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
6500
6501 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
6502 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
6503
61717a45
FXC
65042015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
6505
6506 PR middle-end/36757
6507 * c-common.c (check_builtin_function_arguments): Add check
6508 for BUILT_IN_SIGNBIT argument.
6509
329524f5
PC
65102015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
6511
6512 PR c++/67160
6513 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
6514 in c++1z mode.
6515
4ee55665
MP
65162015-08-17 Marek Polacek <polacek@redhat.com>
6517
6518 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
6519 with whitespaces before qualifier names.
6520
b893e375
MP
65212015-08-12 Marek Polacek <polacek@redhat.com>
6522
6523 PR c++/55095
6524 * c-common.c (maybe_warn_shift_overflow): Properly handle
6525 left-shifting 1 into the sign bit.
6526
c2d89095
MLI
65272015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
6528
6529 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
6530
971e17ff
AS
65312015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
6532 Braden Obrzut <admin@maniacsvault.net>
6533 Jason Merrill <jason@redhat.com>
6534
6535 Add C++ Concepts TS support.
6536 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
6537 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
6538 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
6539 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
6540 * c-opts.c (set_std_cxx1z): Set flag_concepts.
6541 * c.opt (fconcepts): New.
6542
b3d5bc62
JJ
65432015-08-02 Martin Sebor <msebor@redhat.com>
6544
6545 * c.opt (-Wframe-address): New warning option.
6546
8ebca419
PP
65472015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
6548
6549 * c-indentation.c (should_warn_for_misleading_indentation):
6550 Improve heuristics.
6551
1a1e101f
PP
65522015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
6553
6554 * c-indentation.c (get_visual_column): Add parameter first_nws,
6555 use it. Update comment documenting the function.
6556 (is_first_nonwhitespace_on_line): Remove.
6557 (should_warn_for_misleading_indentation): Replace usage of
6558 of is_first_nonwhitespace_on_line with get_visual_column.
6559
992118a1
PP
65602015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
6561
6562 * c-indentation.h (struct token_indent_info): Define.
6563 (get_token_indent_info): Define.
6564 (warn_for_misleading_information): Declare.
6565 * c-common.h (warn_for_misleading_information): Remove.
6566 * c-identation.c (warn_for_misleading_indentation):
6567 Change declaration to take three token_indent_infos. Adjust
6568 accordingly.
6569 * c-identation.c (should_warn_for_misleading_indentation):
6570 Likewise. Bail out early if the body is a compound statement.
6571 (guard_tinfo_to_string): Define.
6572
e8fa3817
JM
65732015-07-30 Jason Merrill <jason@redhat.com>
6574
6575 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
6576 '*' for reference decay.
6577
173864e8
MP
65782015-07-30 Marek Polacek <polacek@redhat.com>
6579
6580 * c-common.c (warn_tautological_cmp): Bail for float types.
6581
f2afe6dd
MP
65822015-07-27 Marek Polacek <polacek@redhat.com>
6583
6584 PR bootstrap/67030
6585 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
6586
05b28fd6
MP
65872015-07-27 Marek Polacek <polacek@redhat.com>
6588
6589 PR c++/66555
6590 PR c/54979
6591 * c-common.c (find_array_ref_with_const_idx_r): New function.
6592 (warn_tautological_cmp): New function.
6593 * c-common.h (warn_tautological_cmp): Declare.
6594 * c.opt (Wtautological-compare): New option.
6595
5a5062b8
MP
65962015-07-23 Marek Polacek <polacek@redhat.com>
6597
6598 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
6599 (ubsan_instrument_shift): Likewise.
6600
dc891fe7
MP
66012015-07-23 Marek Polacek <polacek@redhat.com>
6602
6603 PR sanitizer/66908
6604 * c-ubsan.c: Include gimplify.h.
6605 (ubsan_instrument_division): Unshare OP0 and OP1.
6606 (ubsan_instrument_shift): Likewise.
6607
451b5e48
MP
66082015-07-20 Marek Polacek <polacek@redhat.com>
6609 Richard Sandiford <richard.sandiford@arm.com>
6610
6611 PR c++/55095
6612 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
6613 Use EXPR_LOC_OR_LOC.
6614 (maybe_warn_shift_overflow): New function.
6615 * c-common.h (maybe_warn_shift_overflow): Declare.
6616 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
6617 * c.opt (Wshift-overflow): New option.
6618
fb0b2914
ML
66192015-07-16 Martin Liska <mliska@suse.cz>
6620
6621 * c-format.c (static void check_format_info_main): Use
6622 object_allocator instead of pool_allocator.
6623 (check_format_arg): Likewise.
6624 (check_format_info_main): Likewise.
6625
903f5c23
AM
66262015-07-15 Andrew MacLeod <amacleod@redhat.com>
6627
6628 * c-opts.c: Remove multiline #include comment.
6629
026c3cfd
AH
66302015-07-12 Aldy Hernandez <aldyh@redhat.com>
6631
6632 * c-common.c: Fix double word typos.
6633
bb49ee66
EB
66342015-07-10 Eric Botcazou <ebotcazou@adacore.com>
6635
6636 * c-ada-spec.h (cpp_operation): Revert latest change.
6637 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
6638 constructors and destructors.
6639
1916bcb5
AM
66402015-07-09 Andrew MacLeod <amacleod@redhat.com>
6641
6642 * c-common.h: Adjust includes for flags.h changes.
6643 * stub-objc.c: Likewise.
026c3cfd 6644
a9dcd529
EB
66452015-07-08 Eric Botcazou <ebotcazou@adacore.com>
6646
6647 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
6648 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
6649
b03b462f
JJ
66502015-07-08 Jakub Jelinek <jakub@redhat.com>
6651
6652 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
6653 are to be removed, return NULL rather than original clauses list.
6654
c7131fb2
AM
66552015-07-07 Andrew MacLeod <amacleod@redhat.com>
6656
6657 * array-notation-common.c: Adjust includes.
6658 * c-ada-spec.c: Likewise.
6659 * c-cilkplus.c: Likewise.
6660 * c-common.h: Likewise.
6661 * c-cppbuiltin.c: Likewise.
6662 * c-dump.c: Likewise.
6663 * c-format.c: Likewise.
6664 * c-gimplify.c: Likewise.
6665 * c-indentation.c: Likewise.
6666 * c-lex.c: Likewise.
6667 * c-omp.c: Likewise.
6668 * c-opts.c: Likewise.
6669 * c-pch.c: Likewise.
6670 * c-ppoutput.c: Likewise.
6671 * c-pragma.c: Likewise.
6672 * c-pretty-print.c: Likewise.
6673 * c-semantics.c: Likewise.
6674 * c-ubsan.c: Likewise.
6675 * cilk.c: Likewise.
6676 * stub-objc.c: Likewise.
6677
2a7fb83f
EB
66782015-07-07 Eric Botcazou <ebotcazou@adacore.com>
6679
6680 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
6681 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
6682
a03c9bf1
JM
66832015-07-01 Jason Merrill <jason@redhat.com>
6684
36a85135
JM
6685 * c-common.h (D_CXX11): Rename from D_CXX0X.
6686 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
6687 * c-common.c: Adjust.
6688
e7fa68d5
JM
6689 * c-opts.c (c_common_post_options): Default to C++14.
6690
a03c9bf1
JM
6691 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
6692
fe95b036
ESR
66932015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
6694
6695 Implement N4197 - Adding u8 character literals
b3d5bc62 6696 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
a64be36b 6697 CPP_CHAR.
b3d5bc62 6698 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
a64be36b 6699 CPP_UTF8CHAR_USERDEF tokens.
b3d5bc62 6700 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
a64be36b
EB
6701 and CPP_UTF8CHAR tokens.
6702 (lex_charconst): Treat CPP_UTF8CHAR token.
fe95b036 6703
da2e71c9
MLI
67042015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
6705
6706 PR fortran/66605
6707 * c-common.c (do_warn_unused_parameter): Move here.
6708 * c-common.h (do_warn_unused_parameter): Declare.
6709
b155cfd9
MP
67102015-06-29 Marek Polacek <polacek@redhat.com>
6711
6712 PR c/66322
6713 * c-common.c (check_case_bounds): Add bool * parameter. Set
6714 OUTSIDE_RANGE_P.
6715 (c_add_case_label): Add bool * parameter. Pass it down to
6716 check_case_bounds.
6717 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
6718 warning here.
6719 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
6720 declarations.
6721
31521951
MP
67222015-06-27 Marek Polacek <polacek@redhat.com>
6723
6724 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
6725 or VECTOR_INTEGER_TYPE_P throughout.
6726 * c-gimplify.c: Likewise.
6727
22d03525
MP
67282015-06-26 Marek Polacek <polacek@redhat.com>
6729
6730 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
6731 * c-common.c (c_fully_fold_internal): Likewise.
6732 (c_alignof_expr): Likewise.
6733 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
6734 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
b1726d6c 6735 * cilk.c (create_parm_list): Likewise.
22d03525 6736
af05e6e5
MP
67372015-06-26 Marek Polacek <polacek@redhat.com>
6738
6739 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
6740
f0889939
AM
67412015-06-25 Andrew MacLeod <amacleod@redhat.com>
6742
6743 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
6744 * c-gimplify.c: Likewise.
6745 * c-pragma.c: Likewise.
6746 * c-ubsan.c: Likewise.
6747 * cilk.c: Likewise.
6748
ca752f39
RS
67492015-06-25 Richard Sandiford <richard.sandiford@arm.com>
6750
6751 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
6752 ggc_hasher.
6753
16a16ec7
AM
67542015-06-25 Andrew MacLeod <amacleod@redhat.com>
6755
6756 * cilk.c: Move calls.h after tm.h in the include chain.
6757
0ae9bd27
MP
67582015-06-25 Marek Polacek <polacek@redhat.com>
6759
6760 * array-notation-common.c: Use VAR_P throughout.
6761 * c-ada-spec.c: Likewise.
6762 * c-common.c: Likewise.
6763 * c-format.c: Likewise.
6764 * c-gimplify.c: Likewise.
6765 * c-omp.c: Likewise.
6766 * c-pragma.c: Likewise.
6767 * c-pretty-print.c: Likewise.
6768 * cilk.c: Likewise.
6769
62f9079a
MP
67702015-06-25 Marek Polacek <polacek@redhat.com>
6771
6772 * cilk.c (extract_free_variables): Use is_global_var.
6773
0fa16060
RS
67742015-06-23 Richard Sandiford <richard.sandiford@arm.com>
6775
6776 * c-common.c: Don't include target-def.h.
6777
a68ae2e1
MP
67782015-06-23 Marek Polacek <polacek@redhat.com>
6779
6780 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
6781 when comparing INTEGER_CSTs.
6782
c6a2f2d9
PMR
67832015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
6784
6785 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
6786 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
6787 (dump_ada_template): Skip partially specialized types.
6788
6b4db501
MM
67892015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
6790
6791 * c-common.c (scalar_to_vector): Use std::swap instead of manually
6792 swapping.
6793
abb226c9
AM
67942015-06-17 Andrew MacLeod <amacleod@redhat.com>
6795
6796 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
6797 * c-ada-spec.c: Likewise.
6798 * c-cilkplus.c: Likewise.
6799 * c-common.c: Likewise.
6800 * c-common.h: Likewise.
6801 * c-cppbuiltin.c: Likewise.
6802 * c-dump.c: Likewise.
6803 * c-format.c: Likewise.
6804 * c-gimplify.c: Likewise.
6805 * c-indentation.c: Likewise.
6806 * c-lex.c: Likewise.
6807 * c-omp.c: Likewise.
6808 * c-opts.c: Likewise.
6809 * c-pch.c: Likewise.
6810 * c-ppoutput.c: Likewise.
6811 * c-pragma.c: Likewise.
6812 * c-pretty-print.c: Likewise.
6813 * c-semantics.c: Likewise.
6814 * c-ubsan.c: Likewise.
6815 * cilk.c: Likewise.
6816 * stub-objc.c: Likewise.
6817
076fecad
PP
68182015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
6819
6820 PR c++/65168
6821 * c-common.c (c_common_truthvalue_conversion): Warn when
6822 converting an address of a reference to a truth value.
6823
13fdf2e2
AM
68242015-06-08 Andrew MacLeod <amacleod@redhat.com>
6825
6826 * array-notation-common.c : Adjust include files.
6827 * c-ada-spec.c : Likewise.
6828 * c-cilkplus.c : Likewise.
6829 * c-common.c : Likewise.
6830 * c-common.h : Likewise.
6831 * c-cppbuiltin.c : Likewise.
6832 * c-dump.c : Likewise.
6833 * c-format.c : Likewise.
6834 * c-gimplify.c : Likewise.
6835 * c-indentation.c : Likewise.
6836 * c-lex.c : Likewise.
6837 * c-omp.c : Likewise.
6838 * c-opts.c : Likewise.
6839 * c-pch.c : Likewise.
6840 * c-ppoutput.c : Likewise.
6841 * c-pragma.c : Likewise.
6842 * c-pretty-print.c : Likewise.
6843 * c-semantics.c : Likewise.
6844 * c-ubsan.c : Likewise.
6845 * cilk.c : Likewise.
6846 * stub-objc.c : Likewise.
6847
a1661b90
MP
68482015-06-08 Marek Polacek <polacek@redhat.com>
6849
6850 PR c/66415
6851 * c-format.c (location_from_offset): Return LOC if LINE is null.
6852
d7438551
AH
68532015-06-05 Aldy Hernandez <aldyh@redhat.com>
6854
6855 * c-common.h (c_parse_final_cleanups): New prototype.
6856 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
6857
b3d5bc62
JJ
68582015-06-04 Sriraman Tallam <tmsriram@google.com>
6859
6860 * c-common.c (noplt): New attribute.
6861 (handle_noplt_attribute): New handler.
6862
ecb9f223
AM
68632015-06-04 Andrew MacLeod <amacleod@redhat.com>
6864
6865 * array-notation-common.c: Adjust includes for restructured coretypes.h.
6866 * c-ada-spec.c: Likewise.
6867 * c-cilkplus.c: Likewise.
6868 * c-common.c: Likewise.
6869 * c-common.h: Likewise.
6870 * c-cppbuiltin.c: Likewise.
6871 * c-dump.c: Likewise.
6872 * c-format.c: Likewise.
6873 * c-gimplify.c: Likewise.
6874 * c-indentation.c: Likewise.
6875 * c-lex.c: Likewise.
6876 * c-omp.c: Likewise.
6877 * c-opts.c: Likewise.
6878 * c-pch.c: Likewise.
6879 * c-ppoutput.c: Likewise.
6880 * c-pragma.c: Likewise.
6881 * c-pretty-print.c: Likewise.
6882 * c-semantics.c: Likewise.
6883 * c-ubsan.c: Likewise.
6884 * cilk.c: Likewise.
6885 * stub-objc.c: Likewise.
6886
6ac48155
DM
68872015-06-02 David Malcolm <dmalcolm@redhat.com>
6888
6889 PR c/66220:
6890 * c-indentation.c (should_warn_for_misleading_indentation): Use
6891 expand_location rather than expand_location_to_spelling_point.
6892 Don't warn if the guarding statement is more indented than the
6893 next/body stmts.
6894
773ce42e
DM
68952015-06-02 David Malcolm <dmalcolm@redhat.com>
6896
6897 * c-indentation.c (warn_for_misleading_indentation): Bail out
6898 immediately if -Wmisleading-indentation isn't enabled.
6899
4fef8379
ML
69002015-06-01 Martin Liska <mliska@suse.cz>
6901
6902 * c-format.c (check_format_arg):Use new type-based pool allocator.
6903 (check_format_info_main) Likewise.
6904
1edfb384
EB
69052015-05-31 Eric Botcazou <ebotcazou@adacore.com>
6906
6907 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
6908 (has_nontrivial_methods): Likewise.
6909
9677ef52
MP
69102015-05-25 Marek Polacek <polacek@redhat.com>
6911
6912 * c-ubsan.c (ubsan_instrument_shift): Use type0.
6913
fd5c817a
MP
69142015-05-22 Marek Polacek <polacek@redhat.com>
6915
6916 PR c/47043
6917 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
6918
a2f45fe6 69192015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
581edfa3
TS
6920
6921 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
6922 STACK_GROWS_DOWNWARD.
6923
a2f45fe6 69242015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
62f9f30b
TS
6925
6926 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
6927 STACK_GROWS_DOWNWARD rather than if it is defined.
6928
0fee2ac2 69292015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
b1726d6c 6930
0fee2ac2
MLI
6931 PR c/52952
6932 * c-format.c (location_column_from_byte_offset): New.
6933 (location_from_offset): New.
6934 (struct format_wanted_type): Add offset_loc field.
6935 (check_format_info): Move handling of location for extra arguments
6936 closer to the point of warning.
6937 (check_format_info_main): Pass the result of location_from_offset
6938 to warning_at.
6939 (format_type_warning): Pass the result of location_from_offset
6940 to warning_at.
6941
cf4ef6f7
MP
69422015-05-20 Marek Polacek <polacek@redhat.com>
6943
6944 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
6945
3a65ee74
MP
69462015-05-20 Marek Polacek <polacek@redhat.com>
6947
6948 * c-ada-spec.c (dump_sloc): Use DECL_P.
6949
21b634ae
MP
69502015-05-20 Marek Polacek <polacek@redhat.com>
6951
6952 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
6953 * c-common.c: Likewise.
6954
0e50b624
DM
69552015-05-19 David Malcolm <dmalcolm@redhat.com>
6956
6957 * c-common.h (fe_file_change): Strengthen param from
6958 const line_map * to const line_map_ordinary *.
6959 (pp_file_change): Likewise.
6960 * c-lex.c (fe_file_change): Likewise.
6961 (cb_define): Use linemap_check_ordinary when invoking
6962 SOURCE_LINE.
6963 (cb_undef): Likewise.
6964 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
6965 invoking cb_file_change.
6966 (c_finish_options): Likewise.
6967 (push_command_line_include): Likewise.
6968 (cb_file_change): Strengthen param "new_map" from
6969 const line_map * to const line_map_ordinary *.
6970 * c-ppoutput.c (cb_define): Likewise for local "map".
6971 (pp_file_change): Likewise for param "map" and local "from".
6972
fab27f52
MM
69732015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
6974
6975 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
6976
2fe1d762
TV
69772015-05-18 Tom de Vries <tom@codesourcery.com>
6978
6979 * c-common.c (build_va_arg_1): New function.
6980 (build_va_arg): Add address operator to va_list operand if necessary.
6981
7a37fa90
MM
69822015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
6983
6984 PR c/48956
6985 * c-common.c (int_safely_convertible_to_real_p): Define.
6986 (unsafe_conversion_p): Check conversions involving complex types.
6987 (conversion_warning): Add new warning message for conversions which
6988 discard imaginary component.
6989 * c-common.h: (enum conversion_safety): Add new enumerator for such
6990 conversions.
6991
3aa3c9fc
MP
69922015-05-14 Marek Polacek <polacek@redhat.com>
6993
6994 PR c/66066
6995 PR c/66127
6996 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
6997 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
6998 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
6999 use it. If FOR_INT_CONST, require that all evaluated operands be
7000 INTEGER_CSTs.
7001
c3388e62
DM
70022015-05-12 David Malcolm <dmalcolm@redhat.com>
7003
7004 * c-common.h (warn_for_misleading_indentation): New prototype.
7005 * c-indentation.c: New file.
7006 * c.opt (Wmisleading-indentation): New option.
7007
c7b38fd5
TV
70082015-05-12 Tom de Vries <tom@codesourcery.com>
7009
7010 PR tree-optimization/66010
7011 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
7012
381bf11e
JM
70132015-05-09 Jason Merrill <jason@redhat.com>
7014
edff0c06
JM
7015 * c-opts.c (c_common_post_options): Also clear
7016 cpp_opts->cpp_warn_cxx11_compat.
7017
129211bc
JM
7018 * c-common.h (enum cxx_dialect): Add cxx_unset.
7019 * c-common.c (cxx_dialect): Initialize to cxx_unset.
7020 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
7021
381bf11e
JM
7022 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
7023 (std=gnu++0x): Mark as Undocumented.
7024 (std=gnu++1y): Add deprecated message.
7025
fe191308
JM
70262015-05-08 Jason Merrill <jason@redhat.com>
7027
765189ff
JM
7028 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
7029 * c-opts.c: Adjust.
7030
fe191308
JM
7031 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
7032
755e528f
MP
70332015-05-08 Marek Polacek <polacek@redhat.com>
7034
7035 PR c/64918
7036 * c.opt (Woverride-init-side-effects): New option.
7037
0173bd2a
MP
70382015-05-07 Marek Polacek <polacek@redhat.com>
7039
7040 PR c/65179
7041 * c-common.c (c_fully_fold_internal): Warn when left shifting a
7042 negative value.
7043 * c.opt (Wshift-negative-value): New option.
7044 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
7045 when -Wextra and C99/C++11 mode.
7046
e0f0d3b9
MP
70472015-05-07 Marek Polacek <polacek@redhat.com>
7048 Martin Uecker <uecker@eecs.berkeley.edu>
7049
7050 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
7051 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
7052
8243e2a9
JM
70532015-05-05 Jason Merrill <jason@redhat.com>
7054
7055 * c.opt (Wterminate): New.
7056
577cd070
MP
70572015-04-30 Marek Polacek <polacek@redhat.com>
7058
7059 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
7060 require that the non-constant be of a boolean type.
7061
0373796b
JT
70622015-04-29 Josh Triplett <josh@joshtriplett.org>
7063
e0f0d3b9
MP
7064 * c-common.c (handle_section_attribute): Refactor to reduce
7065 nesting and distinguish between error cases.
0373796b 7066
716c0ba6
MP
70672015-04-29 Marek Polacek <polacek@redhat.com>
7068
7069 PR c/64610
7070 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
7071 with 0/1.
7072
8848828b
JJ
70732015-04-29 Jakub Jelinek <jakub@redhat.com>
7074
7075 * c-common.h (omp_clause_mask): Unconditionally define as a class.
7076 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
7077 HOST_BITS_PER_WIDE_INT.
7078
ecd0e562
TV
70792015-04-28 Tom de Vries <tom@codesourcery.com>
7080
7081 PR tree-optimization/65887
7082 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
7083
2a877204 70842015-04-28 Eric Botcazou <ebotcazou@adacore.com>
e0f0d3b9 7085 Pierre-Marie de Rodat <derodat@adacore.com>
2a877204
EB
7086
7087 * c-ada-spec.c (in_function): Delete.
7088 (dump_generic_ada_node): Do not change in_function and remove the
7089 redundant code dealing with it.
7090 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
7091 (print_ada_methods): Output the static member functions in a nested
7092 package after the regular methods as well as associated renamings.
7093
4853031e
MP
70942015-04-24 Marek Polacek <polacek@redhat.com>
7095
7096 PR c/65830
7097 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
7098 and OPT_Wshift_count_overflow.
7099
8c2b7f79
MP
7100 PR c/63357
7101 * c-common.c (warn_logical_operator): Warn if the operands have the
7102 same expressions.
7103
b8787813
MP
71042015-04-24 Marek Polacek <polacek@redhat.com>
7105
7106 PR c/61534
7107 * c-common.c (warn_logical_operator): Bail if either operand comes
7108 from a macro expansion.
7109
8fba1830
BRF
71102015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
7111
7112 PR target/55143
7113 * c-common.c (c_default_pointer_mode): Add definition.
7114 * c-common.h (c_default_pointer_mode): Add declaration.
7115
17958621
JJ
71162015-03-11 Jakub Jelinek <jakub@redhat.com>
7117
7118 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
7119 on record_builtin_type argument.
7120
7ccb1a11
JJ
71212015-03-10 Jakub Jelinek <jakub@redhat.com>
7122
7123 PR c/65120
7124 * c-common.c (warn_logical_not_parentheses): Don't warn for
7125 !x == 0 or !x != 0.
7126
04fd785e
MP
71272015-03-07 Marek Polacek <polacek@redhat.com>
7128
7129 PR sanitizer/65280
7130 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
7131 before trying to figure out whether we have a flexible array member.
7132
a4e26206 71332015-03-06 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 7134 Jonathan Wakely <jwakely.gcc@gmail.com>
a4e26206
EB
7135
7136 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
7137
0d2489f4
EB
71382015-03-05 Eric Botcazou <ebotcazou@adacore.com>
7139
7140 PR ada/65319
7141 * c-ada-spec.c (print_destructor): Remove obsolete code.
7142
83ed54d7
EB
71432015-03-01 Eric Botcazou <ebotcazou@adacore.com>
7144
7145 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
7146 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
7147 DECL_TEMPLATE_RESULT emulations.
7148 (dump_ada_template)): Add guard for TYPE_METHODS.
7149
7631f0e2
MP
71502015-02-27 Marek Polacek <polacek@redhat.com>
7151
7152 PR c/65040
7153 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
7154
d1783ae5
KT
71552015-02-27 Kai Tietz <ktietz@redhat.com>
7156
7157 PR c/35330
7158 * c-pragma.c (handle_pragma_weak): Do not try to create
7159 weak/alias of declarations not being function, or variable
7160 declarations.
7161
56a9f6bc
TS
71622015-02-24 Thomas Schwinge <thomas@codesourcery.com>
7163
7164 PR libgomp/64625
7165 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
7166 Remove macros.
7167 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
7168
3d5cb23d
MP
71692015-02-16 Marek Polacek <polacek@redhat.com>
7170
7171 PR c/65066
7172 * c-format.c (check_format_types): Handle null param.
7173
fa008882
MP
71742015-02-13 Marek Polacek <polacek@redhat.com>
7175
7176 PR c/65040
7177 * c-format.c (check_format_types): Don't warn about different
7178 signedness if the original value is in the range of WANTED_TYPE.
7179
785f21af
JM
71802015-02-12 Jason Merrill <jason@redhat.com>
7181
7182 PR c++/64956
7183 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
7184 to the current highest version.
7185 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
7186
4886ec8e
JJ
71872015-02-04 Jakub Jelinek <jakub@redhat.com>
7188
7189 PR c/64824
7190 PR c/64868
7191 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
7192 instead of RDIV_EXPR. Use build_binary_op instead of
7193 build2_loc.
7194
40fecdd6
JM
71952015-01-30 Joseph Myers <joseph@codesourcery.com>
7196
7197 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
7198 to pass input_location as first argument.
7199
a0c88d06
TV
72002015-01-23 Tom de Vries <tom@codesourcery.com>
7201
7202 PR libgomp/64672
7203 * c.opt (fopenacc): Mark as LTO option.
7204
1506ae0e
TV
72052015-01-23 Tom de Vries <tom@codesourcery.com>
7206
7207 PR libgomp/64707
7208 * c.opt (fopenmp): Mark as LTO option.
7209
31be63ab
JJ
72102015-01-21 Jakub Jelinek <jakub@redhat.com>
7211
7212 PR c/63307
b1726d6c 7213 * cilk.c (fill_decls_vec): Only put decls into vector v.
31be63ab
JJ
7214 (compare_decls): Fix up formatting.
7215
72162015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
7217
7218 PR c/63307
7219 * cilk.c: Include vec.h.
7220 (struct cilk_decls): New structure.
7221 (wrapper_parm_cb): Split this function to...
7222 (fill_decls_vec): ...this...
7223 (create_parm_list): ...and this.
7224 (compare_decls): New function.
7225 (for_local_cb): Remove.
7226 (wrapper_local_cb): Ditto.
7227 (build_wrapper_type): For now first traverse and fill vector of
7228 declarations then sort it and then deal with sorted vector.
7229 (cilk_outline): Ditto.
7230 (declare_one_free_variable): Ditto.
7231
6875457f
JM
72322015-01-21 Jason Merrill <jason@redhat.com>
7233
7234 PR c++/64629
7235 * c-format.c (check_format_arg): Call decl_constant_value.
7236
185c9e56
ML
72372015-01-19 Martin Liska <mliska@suse.cz>
7238
7239 * c-common.c (handle_noicf_attribute): New function.
7240
41dbbb37
TS
72412015-01-15 Thomas Schwinge <thomas@codesourcery.com>
7242 Bernd Schmidt <bernds@codesourcery.com>
7243 James Norris <jnorris@codesourcery.com>
7244 Cesar Philippidis <cesar@codesourcery.com>
7245 Ilmir Usmanov <i.usmanov@samsung.com>
7246 Jakub Jelinek <jakub@redhat.com>
7247
7248 * c.opt (fopenacc): New option.
7249 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
7250 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
7251 New macros.
7252 * c-common.h (c_finish_oacc_wait): New prototype.
7253 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
7254 (c_finish_oacc_wait): New function.
7255 * c-pragma.c (oacc_pragmas): New variable.
7256 (c_pp_lookup_pragma, init_pragma): Handle it.
7257 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
7258 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
7259 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
7260 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
7261 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
7262 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
7263 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
7264 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
7265 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
7266 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
7267 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
7268 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
7269 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
7270 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
7271 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
7272 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
7273 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
7274 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
7275 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
7276 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
7277 PRAGMA_OACC_CLAUSE_WORKER.
7278
3f8257db 72792015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
5434dc07
MD
7280
7281 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
7282 for the new option fstack-protector_explicit.
7283 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
7284 (handle_stack_protect_attribute): New function.
7285
3f8257db 72862015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
de1b5c17
MU
7287
7288 * c.opt: New option -Warray-bounds=.
7289
adfac8df
JJ
72902015-01-09 Michael Collison <michael.collison@linaro.org>
7291
7292 * array-notation-common.c: Include hash-set.h, machmode.h,
7293 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7294 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
7295 * c-ada-spec.c: Ditto.
7296 * c-cilkplus.c: Ditto.
7297 * c-common.c: Include input.h due to flattening of tree.h.
7298 Define macro GCC_C_COMMON_C.
7299 * c-common.h: Flatten tree.h header files into c-common.h.
7300 Remove include of tree-core.h.
7301 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
7302 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7303 fold-const.h, wide-int.h, and inchash.h due to
7304 flattening of tree.h.
7305 * c-dump.c: Ditto.
7306 * c-format.c: Flatten tree.h header files into c-common.h.
7307 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
7308 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7309 fold-const.h, wide-int.h, and inchash.h due to
7310 flattening of tree.h.
7311 * c-dump.c: Include hash-set.h, machmode.h,
7312 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7313 fold-const.h, wide-int.h, and inchash.h due to
7314 flattening of tree.h.
7315 * c-format.c: Include hash-set.h, machmode.h,
7316 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7317 fold-const.h, wide-int.h, inchash.h and real.h due to
7318 flattening of tree.h.
7319 * c-gimplify.c: Include hash-set.h, machmode.h,
7320 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
7321 fold-const.h, wide-int.h, and inchash.h due to
7322 flattening of tree.h.
7323 * cilk.c: Ditto.
7324 * c-lex.c: Ditto.
7325 * c-omp.c: Ditto.
7326 * c-opts.c: Ditto.
7327 * c-pch.c: Ditto.
7328 * c-ppoutput.c: Ditto.
7329 * c-pragma.c: Ditto.
7330 * c-pretty-print.c: Ditto.
7331 * c-semantics.c: Ditto.
7332 * c-ubsan.c: Ditto.
7333 * stub-objc.c: Ditto.
7334
f5481fc4
JM
73352015-01-08 Jason Merrill <jason@redhat.com>
7336
7337 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
7338 do_ubsan_in_current_function.
7339 (ubsan_maybe_instrument_reference_or_call): Likewise.
7340 * c-ubsan.h: Declare it.
7341
de35aa66
MS
73422015-01-08 Mike Stump <mikestump@comcast.net>
7343
7344 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
7345
4a9a42ab
MP
73462015-01-07 Marek Polacek <polacek@redhat.com>
7347
7348 PR c/64440
7349 * c-common.c (c_fully_fold_internal): Warn for division and modulo
7350 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
7351
2f42e5de
TS
73522015-01-05 Trevor Saunders <tsaunders@mozilla.com>
7353
7354 PR c++/31397
7355 * c.opt (Wsuggest-override): New option.
7356
5624e564
JJ
73572015-01-05 Jakub Jelinek <jakub@redhat.com>
7358
7359 Update copyright years.
7360
5bd012f8
MP
73612015-01-05 Marek Polacek <polacek@redhat.com>
7362
7363 PR c/64423
7364 * c-common.c (warn_array_subscript_with_type_char): Add location_t
7365 parameter. Use it.
7366 * c-common.h (warn_array_subscript_with_type_char): Update
7367 declaration.
7368
a7fa8d18
ESR
73692014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
7370
7371 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
7372 Control macro with flag_sized_deallocation.
7373
3f8257db 73742014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
768952be
MU
7375
7376 * c.opt (Wdiscarded-array-qualifiers): New option.
7377
1f8d3e84
JJ
73782014-12-19 Jakub Jelinek <jakub@redhat.com>
7379
7380 PR preprocessor/63831
7381 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
7382 and __has_cpp_attribute here.
7383 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
7384 c_common_has_attribute.
7385 * c-common.h (c_common_has_attribute): New prototype.
7386 * c-lex.c (init_c_lex): Set cb->has_attribute to
7387 c_common_has_attribute instead of cb_has_attribute.
7388 (get_token_no_padding): New function.
7389 (cb_has_attribute): Renamed to ...
7390 (c_common_has_attribute): ... this. No longer static. Use
7391 get_token_no_padding, require ()s, don't build TREE_LIST
7392 unnecessarily, fix up formatting, adjust diagnostics, call
7393 init_attributes.
7394
20b06add
JM
73952014-12-15 Jason Merrill <jason@redhat.com>
7396
7397 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
7398 (-Wsized-deallocation): New.
7399 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
7400 to on in C++14 and up.
7401
94a073b2
JM
74022014-12-11 Jason Merrill <jason@redhat.com>
7403
acaa5911
JM
7404 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
7405
94a073b2
JM
7406 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
7407 we aren't complaining about VLAs.
7408
7fb66c15
MP
74092014-12-06 Marek Polacek <polacek@redhat.com>
7410
7411 PR tree-optimization/64183
7412 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
7413 shift-expression if it is integer_type_node. Use types_compatible_p.
7414
b731b390
JJ
74152014-11-29 Jakub Jelinek <jakub@redhat.com>
7416
7417 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
7418 last argument from create_tmp_var_raw and create_tmp_var calls.
7419 * cilk.c (gimplify_cilk_spawn): Likewise.
7420 * c-omp.c (c_finish_omp_atomic): Likewise.
7421
6a4da643
MP
74222014-11-28 Marek Polacek <polacek@redhat.com>
7423
7424 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
7425 instead of unsigned_type_node.
7426
541e35a6
MP
74272014-11-28 Marek Polacek <polacek@redhat.com>
7428
7429 PR c/63862
7430 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
7431 to op1_utype.
7432 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
7433 expression to unsigned_type_node.
7434
dcc97066
MW
74352014-11-20 Mark Wielaard <mjw@redhat.com>
7436
7437 PR debug/38757
7438 * c-opts.c (set_std_c89): Set lang_hooks.name.
7439 (set_std_c99): Likewise.
7440 (set_std_c11): Likewise.
7441 (set_std_cxx98): Likewise.
7442 (set_std_cxx11): Likewise.
7443 (set_std_cxx14): Likewise.
7444 (set_std_cxx1z): Likewise.
7445
aa7da51a
JJ
74462014-11-21 Jakub Jelinek <jakub@redhat.com>
7447
7448 PR target/63764
7449 * c-common.h (convert_vector_to_pointer_for_subscript): Change
7450 return type to bool.
009a3480 7451 * c-common.c: Include gimple-expr.h.
aa7da51a
JJ
7452 (convert_vector_to_pointer_for_subscript): Change return type to
7453 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
7454 and copy it into a TARGET_EXPR and use that instead of *vecp
7455 directly.
7456
538dd0b7
DM
74572014-11-19 David Malcolm <dmalcolm@redhat.com>
7458
7459 Merger of git branch "gimple-classes-v2-option-3".
7460 * ChangeLog.gimple-classes: New.
7461 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
7462 from being just a vec<gimple> to a vec<gbind *>.
7463
c39a5e99
JJ
74642014-11-18 Jakub Jelinek <jakub@redhat.com>
7465
7466 PR sanitizer/63813
7467 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
7468 argument to ptype, set type to TREE_TYPE (ptype). Don't call
7469 get_pointer_alignment for non-pointers. Use ptype, or if it is
7470 reference type, corresponding pointer type, as type of kind
7471 argument.
7472 (ubsan_maybe_instrument_reference,
7473 ubsan_maybe_instrument_member_call): Adjust callers.
7474
8537a4a9
MP
74752014-11-15 Marek Polacek <polacek@redhat.com>
7476
7477 PR middle-end/63884
7478 * array-notation-common.c (is_sec_implicit_index_fn): Return false
7479 for NULL fndecl.
7480 (extract_array_notation_exprs): Return for NULL node.
7481
2079956a
JM
74822014-11-12 Joseph Myers <joseph@codesourcery.com>
7483
7484 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
7485 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
7486
1304953e
JJ
74872014-11-12 Jakub Jelinek <jakub@redhat.com>
7488
7489 PR c/59708
7490 * c-common.c (check_builtin_function_arguments): Handle
7491 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
7492
e5e44252
AK
74932014-11-10 Andi Kleen <ak@linux.intel.com>
7494
7495 PR c/60804
7496 * c-common.h (check_no_cilk): Declare.
7497 * cilk.c (get_error_location): New function.
7498 (check_no_cilk): Dito.
7499
e64b984d
AK
75002014-11-10 Andi Kleen <ak@linux.intel.com>
7501
7502 * cilk.c (recognize_spawn): Use expression location
7503 for error message.
7504
13c21655
PC
75052014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
7506
7507 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
7508
42fd12b1
ESR
75092014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
7510
7511 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
7512 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
7513 (__cpp_range_based_for, __cpp_initializer_lists,
7514 __cpp_delegating_constructors, __cpp_nsdmi,
7515 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
7516 for C++11; (__cpp_attribute_deprecated): Remove in favor of
7517 __has_cpp_attribute.
7518 * c-lex.c (cb_has_attribute): New callback CPP function;
7519 (init_c_lex): Set has_attribute callback.
7520
6f450181
RB
75212014-11-04 Richard Biener <rguenther@suse.de>
7522
7523 * c-common.c (shorten_compare): Do not shorten mixed
7524 DFP and non-DFP compares.
7525
26f0e1d6
ESR
75262014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
7527
7528 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
7529 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
7530 Commentary and rearrangement of tests.
7531 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
7532 Commentary and rearrangement of tests.
ab20d992 7533 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
26f0e1d6
ESR
7534 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
7535
ef4bddc2
RS
75362014-10-29 Richard Sandiford <richard.sandiford@arm.com>
7537
7538 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
7539 enum from machine_mode.
7540
c582198b
AM
75412014-10-28 Andrew MacLeod <amacleod@redhat.com>
7542
adfac8df
JJ
7543 * c-common.c: Adjust include files.
7544 * c-gimplify.c: Ditto.
7545 * cilk.c: Ditto.
7546 * c-pragma.c: Ditto.
7547 * c-ubsan.c: Ditto.
c582198b 7548
60393bbc
AM
75492014-10-27 Andrew MacLeod <amacleod@redhat.com>
7550
7551 * c-gimplify.c: Adjust include files.
7552
d723bb7c
MLI
75532014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
7554
7555 PR c++/53061
7556 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
7557 c_common_initialize_diagnostics.
7558 * c-common.h: Likewise.
7559
90f3520e
MP
75602014-10-24 Marek Polacek <polacek@redhat.com>
7561
7562 PR c/56980
7563 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
7564 print "struct"/"union"/"enum" for typedefed names.
7565
59d7607a
MP
75662014-10-23 Marek Polacek <polacek@redhat.com>
7567
7568 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
7569 in unsigned type.
7570
d95a2703
JJ
75712014-10-22 Jakub Jelinek <jakub@redhat.com>
7572 Yury Gribov <y.gribov@samsung.com>
7573
7574 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
7575 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
7576 instead of flag_sanitize_recover as bool flag.
7577
8e6ef852
KY
75782014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
7579
7580 * cilk.c: Revert previous change.
7581
948cf550
IZ
75822014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
7583
7584 PR c/63307
7585 * cilk.c: Include vec.h.
7586 (struct cilk_decls): New structure.
7587 (wrapper_parm_cb): Split this function to...
7588 (fill_decls_vec): ...this...
7589 (create_parm_list): ...and this.
7590 (compare_decls): New function.
7591 (for_local_cb): Remove.
7592 (wrapper_local_cb): Ditto.
7593 (build_wrapper_type): For now first traverse and fill vector of
7594 declarations then sort it and then deal with sorted vector.
7595 (cilk_outline): Ditto.
7596 (declare_one_free_variable): Ditto.
7597
92574c7c
MP
75982014-10-17 Marek Polacek <polacek@redhat.com>
7599
7600 * c-opts.c (c_common_post_options): Set warn_implicit_int.
7601 * c.opt (Wimplicit-int): Initialize to -1.
7602
83685514
AM
76032014-10-16 Andrew MacLeod <amacleod@redhat.com>
7604
7605 * c-pragma.c: Adjust include files.
7606 * c-semantics.c: Likewise.
7607
5b8300ea
DD
76082014-10-16 DJ Delorie <dj@redhat.com>
7609
7610 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
7611 multiples of bytes.
7612
5f83e90b
JM
76132014-10-14 Jason Merrill <jason@redhat.com>
7614
7615 PR c++/63455
7616 * c-common.h (CPP_PREPARSED_EXPR): New.
7617 (N_CP_TTYPES): Adjust.
7618
d73326ca
MP
76192014-10-15 Marek Polacek <polacek@redhat.com>
7620
7621 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
7622
78a7c317
DD
76232014-10-14 DJ Delorie <dj@redhat.com>
7624
7625 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
7626 types, not just __int128.
7627 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
7628 types, not just __int128.
7629 (cpp_atomic_builtins): Round pointer sizes up.
7630 (type_suffix): Use type precision, not specific types.
7631 * c-common.c (c_common_reswords): Remove __int128 special case.
7632 (c_common_type_for_size): Check for all __intN types, not just
7633 __int128.
7634 (c_common_type_for_mode): Likewise.
7635 (c_common_signed_or_unsigned_type): Likewise.
7636 (c_build_bitfield_integer_type): Likewise.
7637 (c_common_nodes_and_builtins): Likewise.
7638 (keyword_begins_type_specifier): Likewise.
7639 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
7640 __intN variants.
7641
2a22f99c
TS
76422014-10-12 Trevor Saunders <tsaunders@mozilla.com>
7643
7644 * c-common.c: Use hash_table instead of hashtab.
7645
2a8ef767
ESR
76462014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
7647
adfac8df 7648 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
2a8ef767
ESR
7649 C++11 section.
7650
3c9aabbd
MG
76512014-10-03 Marc Glisse <marc.glisse@inria.fr>
7652
7653 PR c++/54427
7654 PR c++/57198
7655 PR c++/58845
7656 * c-common.c (warn_logical_operator): Punt for vectors.
7657
a15f7cb8
ESR
76582014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
7659
7660 Implement SD-6: SG10 Feature Test Recommendations
7661 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
7662 macros and the __has_header macro.
7663
8d0cf15e
JM
76642014-09-30 Jason Merrill <jason@redhat.com>
7665
dd5d5481
JM
7666 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
7667 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
7668 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
7669
b752325e
JM
7670 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
7671 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
7672
8d0cf15e
JM
7673 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
7674 * c-common.c (c_common_reswords): Remove __is_convertible_to.
7675
083e891e
MP
76762014-09-24 Marek Polacek <polacek@redhat.com>
7677
7678 PR c/61405
7679 PR c/53874
7680 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
7681
7861b648
AK
76822014-09-23 Andi Kleen <ak@linux.intel.com>
7683
7684 * c-common.c (handle_no_reorder_attribute): New function.
7685 (c_common_attribute_table): Add no_reorder attribute.
7686
9a79452d
JM
76872014-09-22 Joseph Myers <joseph@codesourcery.com>
7688
7689 * c-cppbuiltin.c (c_cpp_builtins): Define
7690 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
7691 modes.
7692
dd69f047
JM
76932014-09-18 Joseph Myers <joseph@codesourcery.com>
7694
7695 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
7696 for supported floating-point modes.
7697
737a4826
MLI
76982014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
7699
7700 * c.opt (Wpsabi): Use LangEnabledBy.
7701 * c-opts.c (c_common_handle_option): Do not handle here.
7702
8cc4b7a2
JM
77032014-09-12 Joseph Myers <joseph@codesourcery.com>
7704
7705 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
7706 macros for floating-point modes.
7707
179b5a55
MG
77082014-09-11 Marc Glisse <marc.glisse@inria.fr>
7709
7710 PR target/58757
7711 * c-cppbuiltin.c (builtin_define_float_constants): Correct
7712 __*_DENORM_MIN__ without denormals.
7713
570a11fe
JJ
77142014-09-10 Jakub Jelinek <jakub@redhat.com>
7715
7716 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
7717 ubsan_instrument_vla, ubsan_instrument_return): Adjust
7718 ubsan_create_data callers.
7719 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
7720 index is constant or BIT_AND_EXPR with constant mask and is
7721 small enough for the bound.
7722 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
7723 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
7724
b559c810
MLI
77252014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
7726
7727 * c.opt: Add CppReason to various flags.
7728 (Wdate-time): Re-sort.
7729 * c-common.c: Include c-common.h earlier.
7730 (struct reason_option_codes_t): Delete.
7731 (c_option_controlling_cpp_error): Prefix global type and struct
7732 with cpp_.
7733
1ef33fd4
MLI
77342014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
7735
7736 * c.opt (Wnormalized): New.
7737 (Wnormalized=): Use Enum and Reject Negative.
7738 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
7739
66bb34c0
JM
77402014-09-08 Joseph Myers <joseph@codesourcery.com>
7741
7742 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
7743 digits of floating-point modes if -fbuilding-libgcc.
7744
53d68b9f
JM
77452014-09-05 Joseph Myers <joseph@codesourcery.com>
7746
7747 * c-cppbuiltin.c (c_cpp_builtins): Also define
7748 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
7749 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
7750 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
7751 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
7752 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
7753 __LIBGCC_STACK_GROWS_DOWNWARD__,
7754 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
7755 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
7756 __LIBGCC_DWARF_FRAME_REGISTERS__,
7757 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
7758 __LIBGCC_STACK_POINTER_REGNUM__ and
7759 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
7760 (builtin_define_with_value): Handle backslash-escaping in string
7761 macro values.
7762
f65586dc
RB
77632014-09-05 Richard Biener <rguenther@suse.de>
7764
7765 PR middle-end/63148
7766 * c-format.c (check_format_arg): Properly handle
7767 effectively signed POINTER_PLUS_EXPR offset.
7768
2b71f4a4
MLI
77692014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
7770
7771 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
7772 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
7773 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
7774 and Init.
7775 * c-opts.c (c_common_handle_option): Do not handle here.
7776 (sanitize_cpp_opts): Likewise.
7777 * c-common.c (struct reason_option_codes_t): Handle
7778 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
7779
d2e4feca
MP
77802014-09-03 Marek Polacek <polacek@redhat.com>
7781
7782 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
7783
9a771876
JJ
77842014-09-02 Jakub Jelinek <jakub@redhat.com>
7785 Balaji V. Iyer <balaji.v.iyer@intel.com>
7786 Igor Zamyatin <igor.zamyatin@intel.com>
7787
7788 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
7789 * c-common.c (c_common_reswords): Added _Cilk_for.
7790 * c-common.h (enum rid): Added RID_CILK_FOR.
7791 (cilk_for_number_of_iterations): Add declaration.
7792 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
7793 CILK_FOR.
7794 * c-pragma.c (init_pragma): Register "grainsize" pragma.
7795 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
7796
81b5d104
MLI
77972014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
7798
7799 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
7800 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
7801 Wundef): Use CPP, Var and Init.
7802 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
7803
b753b37b
MLI
78042014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
7805
7806 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
7807 * c-opts.c (c_common_handle_option): Do not handle here.
7808
028aee17
JM
78092014-08-25 Jason Merrill <jason@redhat.com>
7810
7811 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
7812 -std=c++14 and -std=gnu++14, rather than the reverse.
7813 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
7814 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
7815 * c-common.h (cxx_dialect): Remove cxx1y.
7816
e4276ba5
ESR
78172014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
7818
7819 * c-common.h (enum cxx_dialect): Add cxx14.
7820 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
7821 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
7822 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
7823
a545cacd
JM
78242014-08-22 Jason Merrill <jason@redhat.com>
7825
7826 * c.opt (std=gnu++17): Fix alias.
7827
59ea0364
MP
78282014-08-22 Marek Polacek <polacek@redhat.com>
7829
7830 PR c++/62199
7831 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
7832 check for vector types. Drop LHS argument.
7833 * c-common.h (warn_logical_not_parentheses): Adjust.
7834
596e808c
MLI
78352014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
7836
7837 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
7838 (Wmultichar): Likewise.
7839 (Wdate-time): Use C-family languages instead of Common. Use CPP
7840 and Var.
7841 * c-opts.c (c_common_handle_option): Do not handle the above
7842 options here.
7843 (sanitize_cpp_opts): Likewise.
7844
18767f65
MLI
78452014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
7846
7847 PR fortran/44054
7848 * c-opts.c: Include tree-diagnostics.h.
7849 (c_diagnostic_finalizer): New.
7850 (c_common_initialize_diagnostics): Use it.
7851
b4413594
MLI
78522014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
7853
7854 PR preprocessor/51303
7855 * c-common.c (struct reason_option_codes_t option_codes):
7856 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
7857
43f9a13c
MLI
78582014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
7859
7860 PR c/60975
7861 PR c/53063
7862 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
7863 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
7864 (c_common_post_options): Call init_global_opts_from_cpp.
7865 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
7866
04159acf
MP
78672014-08-19 Marek Polacek <polacek@redhat.com>
7868
7869 PR c++/62153
7870 * c-common.c (maybe_warn_bool_compare): New function.
7871 * c-common.h (maybe_warn_bool_compare): Declare.
7872 * c.opt (Wbool-compare): New option.
7873
35aff4fb
MP
78742014-08-19 Marek Polacek <polacek@redhat.com>
7875
7876 * c.opt (Wc99-c11-compat): New option.
7877
177cce46
MP
78782014-08-19 Marek Polacek <polacek@redhat.com>
7879
7880 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
7881 to warn_c90_c99_compat.
7882 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
7883 to -1.
7884
6ae9194f
MLI
78852014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
7886 Steven Bosscher <steven@gcc.gnu.org>
7887
7888 PR c/52952
7889 * c-format.c: Add extra_arg_loc and format_string_loc to struct
7890 format_check_results.
7891 (check_function_format): Use true and add comment for boolean
7892 argument.
7893 (finish_dollar_format_checking): Use explicit location when warning.
7894 (check_format_info): Likewise.
7895 (check_format_arg): Set extra_arg_loc and format_string_loc.
7896 (check_format_info_main): Use explicit location when warning.
7897 (check_format_types): Pass explicit location.
7898 (format_type_warning): Likewise.
7899
8e54f6d3
MLI
79002014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
7901
7902 PR fortran/44054
7903 * c-format.c: Handle Fortran flags.
7904
cd4e76fc
IZ
79052014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
7906
7907 PR other/61962
7908 * array-notation-common.c (find_rank): Added handling for other
7909 types of references.
7910
f3bede71
MP
79112014-08-10 Marek Polacek <polacek@redhat.com>
7912
7913 PR c/51849
7914 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
7915 * c.opt (Wc90-c99-compat): Add option.
7916
9f25a338
TS
79172014-08-07 Trevor Saunders <tsaunders@mozilla.com>
7918
7919 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
7920
62e4eb35
MP
79212014-08-03 Marek Polacek <polacek@redhat.com>
7922
ab20d992 7923 * c-common.c (check_case_value): Add location_t parameter. Use it.
62e4eb35
MP
7924 (c_add_case_label): Pass loc to check_case_value.
7925
b787e7a2
TS
79262014-08-02 Trevor Saunders <tsaunders@mozilla.com>
7927
7928 * cilk.c: Use hash_map instead of pointer_map.
7929
6e2830c3
TS
79302014-08-02 Trevor Saunders <tsaunders@mozilla.com>
7931
7932 * c-gimplify.c: Use hash_set instead of pointer_set.
7933
a7ee52fb
IZ
79342014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
7935
7936 PR middle-end/61455
7937 * array-notation-common.c (extract_array_notation_exprs): Handling
7938 of DECL_EXPR added.
7939
944fa280
JJ
79402014-08-01 Jakub Jelinek <jakub@redhat.com>
7941
7942 * c-common.h (min_align_of_type): Removed prototype.
7943 * c-common.c (min_align_of_type): Removed.
7944 * c-ubsan.h (ubsan_maybe_instrument_reference,
7945 ubsan_maybe_instrument_member_call): New prototypes.
7946 * c-ubsan.c: Include stor-layout.h and builtins.h.
7947 (ubsan_maybe_instrument_reference_or_call,
7948 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
7949 functions.
7950
b4dfdc11
MG
79512014-07-31 Marc Glisse <marc.glisse@inria.fr>
7952
7953 PR c++/60517
7954 * c.opt (-Wreturn-local-addr): Move to common.opt.
7955
a41844e5
JM
79562014-07-30 Jason Merrill <jason@redhat.com>
7957
7958 PR c++/61659
7959 PR c++/61687
7960 Revert:
7961 * c.opt (-fuse-all-virtuals): New.
7962
976d5a22
TT
79632014-07-30 Tom Tromey <tromey@redhat.com>
7964
7965 PR c/59855
7966 * c.opt (Wdesignated-init): New option.
7967 * c-common.c (c_common_attribute_table): Add "designated_init".
7968 (handle_designated_init): New function.
7969
cdc94aca
MP
79702014-07-24 Marek Polacek <polacek@redhat.com>
7971
7972 PR c/57653
7973 * c-opts.c (c_finish_options): If -imacros is in effect, return.
7974
f41373b6
DS
79752014-07-16 Dodji Seketeli <dodji@redhat.com>
7976
7977 PR preprocessor/60723 - missing system-ness marks for macro tokens
7978 * c-ppoutput.c (struct print::prev_was_system_token): New data
7979 member.
7980 (init_pp_output): Initialize it.
7981 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
7982 (do_line_change): Return a flag saying if a line marker was
7983 emitted or not.
7984 (scan_translation_unit): Detect if the system-ness of the token we
7985 are about to emit is different from the one of the previously
7986 emitted token. If so, emit a line marker. Avoid emitting useless
7987 adjacent line markers. Avoid emitting line markers for tokens
7988 originating from the expansion of built-in macros.
7989 (scan_translation_unit_directives_only): Adjust.
7990
4d661eaa
MP
79912014-07-15 Marek Polacek <polacek@redhat.com>
7992
7993 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
7994 TYPE_MAX_VALUE is NULL.
7995
b108f48f
JJ
79962014-07-14 Jakub Jelinek <jakub@redhat.com>
7997
7998 PR middle-end/61294
7999 * c.opt (Wmemset-transposed-args): New warning.
8000
c0221884
JM
80012014-07-10 Jason Merrill <jason@redhat.com>
8002
8003 PR c++/61659
8004 PR c++/61687
8005 * c.opt (-fuse-all-virtuals): New.
8006
63dfbb95
RB
80072014-07-09 Richard Biener <rguenther@suse.de>
8008
8009 PR c-family/61741
8010 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
8011 using unsigned arithmetic if overflow does not wrap instead of
8012 if overflow is undefined.
8013
773ec47f
MP
80142014-07-06 Marek Polacek <polacek@redhat.com>
8015
8016 PR c/6940
8017 * c.opt (Wsizeof-array-argument): New option.
8018
00a7ba58
JJ
80192014-07-03 Jakub Jelinek <jakub@redhat.com>
8020
b1726d6c 8021 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
00a7ba58
JJ
8022 comments->count <= 1, as comments->entries might be NULL.
8023
52ec0ea3
MP
80242014-07-01 Marek Polacek <polacek@redhat.com>
8025
8026 * c.opt (Wint-conversion): New option.
8027
d5c3d343
MP
80282014-07-01 Marek Polacek <polacek@redhat.com>
8029
8030 PR c/58286
8031 * c.opt (Wincompatible-pointer-types): New option.
8032
6e7ceb17
PC
80332014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
8034
8035 PR c++/51400
8036 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
8037 Do not discard TYPE_QUALS of type.
8038
da73100b
JM
80392014-06-26 Jason Merrill <jason@redhat.com>
8040
8041 * c-common.h (enum cxx_dialect): Add cxx1z.
8042 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
8043 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
8044
08eedf75
TJ
80452014-06-26 Teresa Johnson <tejohnson@google.com>
8046
8047 * c-common.h (get_dump_info): Declare.
8048 * c-gimplify.c (c_genericize): Use saved dump files.
8049 * c-opts.c (c_common_parse_file): Begin and end dumps
8050 once around parsing invocation.
8051 (get_dump_info): New function.
8052
7b56b2f8
MP
80532014-06-23 Marek Polacek <polacek@redhat.com>
8054 Andrew MacLeod <amacleod@redhat.com>
8055
8056 PR c/61553
8057 * c-common.c (get_atomic_generic_size): Don't segfault if the
8058 type doesn't have a size.
8059
0e37a2f3
MP
80602014-06-20 Marek Polacek <polacek@redhat.com>
8061
8062 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
8063 (ubsan_walk_array_refs_r): New function.
8064 (c_genericize): Instrument array bounds.
8065 * c-ubsan.c: Include "internal-fn.h".
8066 (ubsan_instrument_division): Mark instrumented arrays as having
8067 side effects. Adjust ubsan_type_descriptor call.
8068 (ubsan_instrument_shift): Likewise.
8069 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
8070 (ubsan_instrument_bounds): New function.
8071 (ubsan_array_ref_instrumented_p): New function.
8072 (ubsan_maybe_instrument_array_ref): New function.
8073 * c-ubsan.h (ubsan_instrument_bounds): Declare.
8074 (ubsan_array_ref_instrumented_p): Declare.
8075 (ubsan_maybe_instrument_array_ref): Declare.
8076
80772014-06-20 Hale Wang <hale.wang@arm.com>
dd6fe7d4
HW
8078
8079 PR lto/61123
8080 * c.opt (fshort-enums): Add to LTO.
8081 * c.opt (fshort-wchar): Likewise.
8082
5c3d09f7
MP
80832014-06-16 Marek Polacek <polacek@redhat.com>
8084
8085 PR c/60439
8086 * c.opt (Wswitch-bool): Add Var.
8087
9cf32741
JJ
80882014-06-12 Jakub Jelinek <jakub@redhat.com>
8089
8090 PR middle-end/61486
8091 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
8092 #pragma omp target teams or
8093 #pragma omp {,target }teams distribute simd.
8094
62984918
JM
80952014-06-12 Jason Merrill <jason@redhat.com>
8096
8097 * c.opt (Wabi=, fabi-compat-version): New.
8098 * c-opts.c (c_common_handle_option): Handle -Wabi=.
8099 (c_common_post_options): Handle flag_abi_compat_version default.
8100 Disallow -fabi-compat-version=1.
8101 * c-common.h (abi_version_crosses): New.
8102
f961457f
JH
81032014-06-11 Jan Hubicka <hubicka@ucw.cz>
8104
adfac8df 8105 * c-common.c (handle_section_attribute): Update handling for
f961457f
JH
8106 section names that are no longer trees.
8107
92d28cbb
JJ
81082014-06-10 Jakub Jelinek <jakub@redhat.com>
8109
8110 PR fortran/60928
8111 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
8112 (omp_pragmas): ... back here.
8113
742938c9
MP
81142014-06-05 Marek Polacek <polacek@redhat.com>
8115
8116 PR c/49706
8117 * c-common.c (warn_logical_not_parentheses): New function.
8118 * c-common.h (warn_logical_not_parentheses): Declare.
8119 * c.opt (Wlogical-not-parentheses): New option.
8120
9d548dfb
MP
81212014-06-04 Marek Polacek <polacek@redhat.com>
8122
8123 PR c/30020
8124 * c-common.c (check_case_bounds): Add location parameter.
8125 Use it.
8126 (c_add_case_label): Pass loc to check_case_bounds.
8127
fedfecef
MP
81282014-06-03 Marek Polacek <polacek@redhat.com>
8129
8130 PR c/60439
8131 * c.opt (Wswitch-bool): New option.
8132
f6a7cffc
TS
81332014-05-22 Thomas Schwinge <thomas@codesourcery.com>
8134
040d18b6
TS
8135 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
8136 Remove prototypes.
8137 (record_types_used_by_current_var_decl): Move prototype to where
8138 it belongs.
8139
f6a7cffc
TS
8140 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
8141 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
8142 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
8143
632f2871
RS
81442014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
8145
8146 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
8147 * c-common.c (c_common_nodes_and_builtins): Don't initialize
8148 void_zero_node.
8149 * c-pretty-print.c (pp_c_void_constant): New function.
8150 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
8151 (c_pretty_printer::expression): Handle VOID_CST.
8152 * cilk.c (extract_free_variables): Likewise.
8153 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
8154 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
8155
766090c2
TS
81562014-05-17 Trevor Saunders <tsaunders@mozilla.com>
8157
8158 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
8159 * c-pragma.c (push_alignment): Adjust.
8160 (handle_pragma_push_options): Likewise.
8161
661a0813
MP
81622014-05-09 Marek Polacek <polacek@redhat.com>
8163
8164 PR c/50459
8165 * c-common.c (check_user_alignment): Return -1 if alignment is error
8166 node.
8167 (handle_aligned_attribute): Don't call default_conversion on
8168 FUNCTION_DECLs.
8169 (handle_vector_size_attribute): Likewise.
8170 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
8171 (handle_sentinel_attribute): Call default_conversion and allow even
8172 integral types as an argument.
8173
2793eeab
MP
81742014-05-08 Marek Polacek <polacek@redhat.com>
8175
8176 PR c/61053
8177 * c-common.c (min_align_of_type): New function factored out from...
8178 (c_sizeof_or_alignof_type): ...here.
8179 * c-common.h (min_align_of_type): Declare.
8180
f827930a
MP
81812014-05-08 Marek Polacek <polacek@redhat.com>
8182
8183 PR c/61077
8184 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
8185 parameter type of main.
8186
ca49b74e
DD
81872014-05-07 DJ Delorie <dj@redhat.com>
8188
8189 * c-cppbuiltin.c (print_bits_of_hex): New.
8190 (builtin_define_type_minmax): Print values using hex so as not to
8191 require a pre-computed list of string values.
8192
1d60af08
KZ
81932014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
8194 Mike Stump <mikestump@comcast.net>
8195 Richard Sandiford <rdsandiford@googlemail.com>
8196
8197 * c-ada-spec.c: Include wide-int.h.
8198 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
8199 (dump_generic_ada_node): Use wide-int interfaces.
8200 * c-common.c: Include wide-int-print.h.
8201 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
8202 (pointer_int_sum): Use wide-int interfaces.
8203 (c_common_nodes_and_builtins): Use make_int_cst.
8204 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
8205 (handle_alloc_size_attribute): Use wide-int interfaces.
8206 (get_nonnull_operand): Likewise.
8207 * c-format.c (get_constant): Use tree_fits_uhwi_p.
8208 * c-lex.c: Include wide-int.h.
8209 (narrowest_unsigned_type): Take a widest_int rather than two
8210 HOST_WIDE_INTs.
8211 (narrowest_signed_type): Likewise.
8212 (interpret_integer): Update accordingly. Use wide-int interfaces.
8213 (lex_charconst): Use wide-int interfaces.
8214 * c-pretty-print.c: Include wide-int.h.
8215 (pp_c_integer_constant): Use wide-int interfaces.
8216 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
8217 INT_CST_LT_UNSIGNED.
8218
b15458be
RB
82192014-05-06 Richard Biener <rguenther@suse.de>
8220
8221 * c-opts.c (c_common_post_options): For -freestanding,
8222 -fno-hosted and -fno-builtin disable pattern recognition
8223 if not enabled explicitely.
8224
6577374e
MP
82252014-05-02 Marek Polacek <polacek@redhat.com>
8226
8227 * c.opt (Wsizeof-pointer-memaccess): Describe option.
8228
d00887e8
MP
82292014-05-01 Marek Polacek <polacek@redhat.com>
8230
8231 PR c/43245
8232 * c.opt (Wdiscarded-qualifiers): Add.
8233
f8ed5150
MP
82342014-04-30 Marek Polacek <polacek@redhat.com>
8235
8236 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
8237 INT_MIN / -1 sanitization only for integer types.
8238
45484dcf
MP
82392014-04-25 Marek Polacek <polacek@redhat.com>
8240
8241 PR c/18079
8242 * c-common.c (handle_noinline_attribute): Warn if the attribute
8243 conflicts with always_inline attribute.
8244 (handle_always_inline_attribute): Warn if the attribute conflicts
8245 with noinline attribute.
8246
38e514c0
MP
82472014-04-25 Marek Polacek <polacek@redhat.com>
8248
8249 PR c/60156
8250 * c-common.c (check_main_parameter_types): Warn about variadic main.
8251
44875f92
MS
82522014-04-24 Mike Stump <mikestump@comcast.net>
8253
8254 * c.opt (Wshadow-ivar): Default to on.
8255
dcaaa5a0
DP
82562014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
8257
8258 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
8259
c07d7c02
MP
82602014-04-23 Marek Polacek <polacek@redhat.com>
8261
8262 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
8263
1c33c9b7
JJ
82642014-04-22 Jakub Jelinek <jakub@redhat.com>
8265
8266 PR sanitizer/60275
8267 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
8268 if flag_sanitize_undefined_trap_on_error.
8269 (ubsan_instrument_division, ubsan_instrument_shift,
8270 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
8271 if !flag_sanitize_recover.
8272
793c625f
MG
82732014-04-22 Marc Glisse <marc.glisse@inria.fr>
8274
8275 PR libstdc++/43622
8276 * c-common.c (registered_builtin_types): Make non-static.
8277 * c-common.h (registered_builtin_types): Declare.
8278
b0f1bf36 82792014-04-14 Richard Biener <rguenther@suse.de>
ab20d992 8280 Marc Glisse <marc.glisse@inria.fr>
b0f1bf36
RB
8281
8282 PR c/60819
8283 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
8284 apply may-alias the scalar pointer type when applicable.
8285
3b07fa4a
IZ
82862014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
8287
8288 PR middle-end/60467
8289 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
8290 as possible argument for Cilk_spawn.
8291
cbbd2b1c
TB
82922014-04-11 Tobias Burnus <burnus@net-b.de>
8293
8294 PR c/60194
8295 * c.opt (Wformat-signedness): Add
8296 * c-format.c(check_format_types): Use it.
8297
6415bd5d
JM
82982014-04-11 Jason Merrill <jason@redhat.com>
8299
8300 PR c++/57926
8301 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
8302 default_conversion for an array argument.
8303
6525783a
MP
83042014-04-08 Marek Polacek <polacek@redhat.com>
8305
8306 PR sanitizer/60745
8307 * c-ubsan.c: Include asan.h.
8308 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
8309
880a467b
NS
83102014-04-03 Nathan Sidwell <nathan@codesourcery.com>
8311
8312 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
8313
7b59ff2d
MP
83142014-04-02 Marek Polacek <polacek@redhat.com>
8315
8316 * c-common.h (c_expand_expr): Remove declaration.
8317
8edbfaa6
JJ
83182014-03-28 Jakub Jelinek <jakub@redhat.com>
8319
8320 PR c++/60689
8321 * c-common.c (add_atomic_size_parameter): When creating new
8322 params vector, push the size argument first.
8323
07d72e1d
JJ
83242014-03-26 Jakub Jelinek <jakub@redhat.com>
8325
8326 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
8327 ubsan_instrument_vla, ubsan_instrument_return): Adjust
8328 ubsan_create_data callers.
8329
b35e0fa0
JJ
83302014-03-22 Jakub Jelinek <jakub@redhat.com>
8331
8332 PR debug/60603
8333 * c-opts.c (c_finish_options): Restore cb_file_change call to
8334 <built-in>.
8335
39a1ebb3
JJ
83362014-03-13 Jakub Jelinek <jakub@redhat.com>
8337
8338 PR middle-end/36282
8339 * c-pragma.c (apply_pragma_weak): Only look at
8340 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
8341 DECL_ASSEMBLER_NAME_SET_P (decl).
8342 (maybe_apply_pending_pragma_weaks): Exit early if
8343 vec_safe_is_empty (pending_weaks) rather than only when
8344 !pending_weaks.
8345 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
8346 set assembler name back to NULL afterwards.
8347
a07f6ed2
JM
83482014-03-11 Jason Merrill <jason@redhat.com>
8349
8350 * c.opt: Add -std=gnu++14.
8351
75b107f5
IB
83522014-03-11 Ian Bolton <ian.bolton@arm.com>
8353
8354 * c-opts.c (c_common_post_options): Don't override
8355 -ffp-contract=fast if unsafe-math-optimizations is on.
8356
f42c637e
PM
83572014-03-08 Paulo Matos <paulo@matos-sorge.com>
8358
22b15758 8359 * c.opt: Enable LTO FE for fshort-double.
f42c637e 8360
70e24808
JM
83612014-03-07 Jason Merrill <jason@redhat.com>
8362
8363 * c.opt: Add -std=c++14.
8364
3af9c5e9
MP
83652014-03-06 Marek Polacek <polacek@redhat.com>
8366
8367 PR c/60197
8368 * cilk.c (contains_cilk_spawn_stmt): New function.
8369 (contains_cilk_spawn_stmt_walker): Likewise.
8370 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
8371 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
8372
b3bdf019
JJ
83732014-03-03 Jakub Jelinek <jakub@redhat.com>
8374
8375 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
8376 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
8377 even when flag_preprocess_only.
8378
ca7e759d
JM
83792014-02-26 Jason Merrill <jason@redhat.com>
8380
8381 PR c++/59231
8382 PR c++/11586
8383 * c-common.c (shorten_compare): Don't check
8384 c_inhibit_evaluation_warnings.
8385
28e41874
JJ
83862014-02-19 Jakub Jelinek <jakub@redhat.com>
8387
cca615af
JJ
8388 PR c/37743
8389 * c-common.c (c_common_nodes_and_builtins): When initializing
8390 c_uint{16,32,64}_type_node, also set corresponding
8391 uint{16,32,64}_type_node to the same value.
8392
28e41874
JJ
8393 PR c++/60267
8394 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
8395 for PRAGMA_IVDEP if flag_preprocess_only.
8396
c2bf53a1
JJ
83972014-02-12 Jakub Jelinek <jakub@redhat.com>
8398
8399 PR c/60101
8400 * c-common.c (merge_tlist): If copy is true, call new_tlist,
8401 if false, add ADD itself, rather than vice versa.
8402 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
8403 copy. For SAVE_EXPR, only call merge_tlist once.
8404
8fcbce72
JJ
84052014-02-08 Jakub Jelinek <jakub@redhat.com>
8406
8407 PR middle-end/60092
8408 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
8409 and tree_to_uhwi.
8410 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
8411 functions.
8412 (c_common_attribute_table): Add alloc_align and assume_aligned
8413 attributes.
8414
0a756a3f
MP
84152014-02-06 Marek Polacek <polacek@redhat.com>
8416
8417 PR c/60087
8418 * c-common.c (warn_for_sign_compare): Call warning_at with location
8419 instead of warning.
8420
7ec4847a
MP
84212014-02-05 Marek Polacek <polacek@redhat.com>
8422
8423 PR c/53123
8424 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
8425 statement.
8426
66f20604
MP
84272014-02-04 Marek Polacek <polacek@redhat.com>
8428
8429 PR c/60036
8430 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
8431 SAVE_EXPR.
8432
5d77fb19
MG
84332014-02-03 Marc Glisse <marc.glisse@inria.fr>
8434
8435 PR c++/53017
8436 PR c++/59211
8437 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
8438 handle_vector_size_attribute, handle_nonnull_attribute): Call
8439 default_conversion on the attribute argument.
8440 (handle_nonnull_attribute): Increment the argument number.
8441
81e5eca8
MP
84422014-01-31 Marek Polacek <polacek@redhat.com>
8443
8444 PR c/59963
8445 * c-common.c (add_atomic_size_parameter): Pass vNULL to
8446 build_function_call_vec.
8447 (resolve_overloaded_builtin): Likewise.
8448 * c-common.h (build_function_call_vec): Adjust declaration.
8449
68fca595
MP
84502014-01-30 Marek Polacek <polacek@redhat.com>
8451
8452 PR c/59940
8453 * c-common.h (unsafe_conversion_p): Adjust declaration.
8454 (warnings_for_convert_and_check): Likewise.
8455 (convert_and_check): Likewise.
8456 * c-common.c (unsafe_conversion_p): Add location parameter. Call
8457 expansion_point_location_if_in_system_header on it.
8458 (warnings_for_convert_and_check): Add location parameter. Call
8459 expansion_point_location_if_in_system_header on it. Use it.
8460 (convert_and_check): Add location parameter. Use it.
8461 (conversion_warning): Likewise.
8462 (c_add_case_label): Adjust convert_and_check calls.
8463 (scalar_to_vector): Adjust unsafe_conversion_p calls.
8464
b72271b9
BI
84652014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
8466
8467 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
8468 flag_cilkplus.
8469 * c-pragma.c (init_pragma): Likewise.
8470 * c.opt: Likewise.
8471
393e8e8b
MP
84722014-01-23 Marek Polacek <polacek@redhat.com>
8473
8474 PR c/59846
8475 * c-common.c (shorten_compare): Add location_t parameter.
8476 * c-common.h (shorten_binary_op): Adjust declaration.
8477
f04dda30
MP
84782014-01-23 Marek Polacek <polacek@redhat.com>
8479
8480 PR c/58346
8481 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
8482 * c-common.h: Declare it.
8483
621955cb
EB
84842014-01-20 Eric Botcazou <ebotcazou@adacore.com>
8485
8486 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
8487 * c-ada-spec.c (dump_ads): Likewise.
8488 (cpp_check): Likewise.
8489 (dump_ada_specs): Likewise.
8490
84912014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
67bf2939
LA
8492
8493 PR c++/49718
8494 * c-common.c (handle_no_instrument_function_attribute): Allow
8495 no_instrument_function attribute in class member
8496 definition/declaration.
8497
241f845a
JJ
84982014-01-15 Jakub Jelinek <jakub@redhat.com>
8499
8500 PR c/58943
8501 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
8502 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
8503 being COMPOUND_EXPR.
8504 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
8505 operand a SAVE_EXPR and second MODIFY_EXPR.
8506
e83b8e2e
JJ
85072014-01-09 Jakub Jelinek <jakub@redhat.com>
8508
8509 PR target/58115
8510 * c-pch.c (c_common_write_pch): Call
8511 prepare_target_option_nodes_for_pch.
8512
23a5b65a
RS
85132014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
8514
8515 Update copyright years
8516
f9030485
RS
85172014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
8518
8519 * array-notation-common.c, c-cilkplus.c: Use the standard form for
8520 the copyright notice.
8521
f2aa696b
EB
85222013-12-28 Eric Botcazou <ebotcazou@adacore.com>
8523
8524 * c-ada-spec.c (print_constructor): New function.
8525 (print_destructor): Retrieve the origin of the destructor.
8526 (print_ada_declaration): Revamp handling of constructors/destructors.
8527
3f8257db 85282013-12-23 Stuart Hastings <stuart@apple.com>
1f26ac87
JM
8529 Bill Maddox <maddox@google.com>
8530 Jason Merrill <jason@redhat.com>
8531
8532 * c.opt: Add -fdeclone-ctor-dtor.
8533 * c-opts.c (c_common_post_options): Default to on iff -Os.
8534
41958c28
BI
85352013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
8536
8537 * c-common.c (c_common_attribute_table): Added "cilk simd function"
8538 attribute.
8539 * c-pragma.h (enum pragma_cilk_clause): Remove.
ab20d992 8540 (enum pragma_omp_clause): Added the following fields:
41958c28
BI
8541 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
8542 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
8543 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
8544 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
8545 PRAGMA_CILK_CLAUSE_UNIFORM.
8546
b1726d6c 8547
12893402
BI
85482013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
8549
8550 * cilk.c (cilk_outline): Made this function non-static.
8551 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
8552 (create_cilk_wrapper): Added a new parameter: a function pointer.
8553 (c_install_body_w_frame_cleanup): Remove
8554 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
8555 * c-common.h (cilk_outline): New prototype.
8556 (gimplify_cilk_spawn): Removed two parameters.
8557 (cilk_install_body_with_frame_cleanup): New prototype.
8558 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
8559 CILK_SPAWN_STMT case.
8560
085b42ed
BS
85612013-12-11 Bernd Schmidt <bernds@codesourcery.com>
8562
2ce064c3
BS
8563 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
8564
085b42ed
BS
8565 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
8566 (int_array_type_node): Remove.
8567 * c-common.c (c_common_nodes_and_builtins): Don't build it.
8568
9e36c9ed
MP
85692013-12-05 Marek Polacek <polacek@redhat.com>
8570
8571 PR c/52023
8572 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
8573 [ADJUST_FIELD_ALIGN].
8574
296674db
JM
85752013-12-04 Joseph Myers <joseph@codesourcery.com>
8576
8577 PR c/52023
8578 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
8579 and check field alignment if set.
8580 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
8581 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
8582
b1726d6c 85832013-12-04 Jakub Jelinek <jakub@redhat.com>
31e071ae
MP
8584 Marek Polacek <polacek@redhat.com>
8585
8586 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
8587 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
8588
d7947e19
L
85892013-11-29 H.J. Lu <hongjiu.lu@intel.com>
8590
8591 PR c/59309
8592 * cilk.c (gimplify_cilk_spawn): Properly handle function without
8593 arguments.
8594
fad7652e
JJ
85952013-11-29 Jakub Jelinek <jakub@redhat.com>
8596
8597 PR c/59280
8598 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
8599 goto invalid. If it is error_mark_node, don't issue further
8600 diagnostics.
8601
8b5e1202
SO
86022013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
8603
8604 * c.opt (Wopenmp-simd): New.
8605
0a508bb6
JJ
86062013-11-22 Jakub Jelinek <jakub@redhat.com>
8607
8608 * c-ubsan.h (ubsan_instrument_return): New prototype.
8609 * c-ubsan.c (ubsan_instrument_return): New function.
8610
2fb9a547
AM
86112013-11-22 Andrew MacLeod <amacleod@redhat.com>
8612
8613 * c-common.c: Add required include files from gimple.h.
ab20d992
JJ
8614 * c-gimplify.c: Likewise.
8615 * cilk.c: Likewise.
2fb9a547 8616
8400e75e
DM
86172013-11-22 David Malcolm <dmalcolm@redhat.com>
8618
8619 * c-common.c (unsafe_conversion_p): Remove use of
8620 EXPR_LOC_OR_HERE macro.
8621 (conversion_warning): Likewise.
8622 (warnings_for_convert_and_check): Likewise.
8623 (warn_for_collisions_1): Likewise.
8624 (shorten_compare): Likewise, and remove use of in_system_header
8625 macro, using the location from the former.
8626 * c-lex.c (dump_one_header): Remove use of input_filename macro.
8627 (cb_def_pragma): Remove use of in_system_header macro.
8628 (lex_string): Likewise.
8629 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
8630
eb1ce453
KZ
86312013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
8632 Mike Stump <mikestump@comcast.net>
8633 Richard Sandiford <rdsandiford@googlemail.com>
8634
8635 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
8636 instead of TREE_INT_CST_LOW, in cases where there is a protecting
8637 tree_fits_shwi_p or tree_fits_uhwi_p.
8638 (dump_generic_ada_node): Likewise.
8639 * c-format.c (check_format_arg): Likewise.
8640 * c-pretty-print.c (pp_c_integer_constant): Likewise.
8641
6b3b8c27
KZ
86422013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
8643
8644 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
8645
49b0aa18
JC
86462013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
8647
8648 PR c/53001
8649 * c-common.c (unsafe_conversion_p): Make this function
8650 return an enumeration with more detail.
8651 (conversion_warning): Use the new return type of
8652 unsafe_conversion_p to separately warn either about conversions
8653 that lower floating point number precision or about the other
8654 kinds of conversions.
8655 * c-common.h (enum conversion_safety): New enumeration.
8e745a17
JJ
8656 (unsafe_conversion_p): switching return type to
8657 conversion_safety enumeration.
49b0aa18
JC
8658 * c.opt: Adding new warning -Wfloat-conversion and
8659 enabling it with -Wconversion.
8660
b826515a
BS
86612013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
8662
8e745a17
JJ
8663 * c-opts.c: Include plugin.h.
8664 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
b826515a 8665
b9a55b13
MP
86662013-11-19 Marek Polacek <polacek@redhat.com>
8667
8668 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
8669 call.
8670 (ubsan_instrument_shift): Likewise.
8671 (ubsan_instrument_vla): Likewise.
8672
7d362f6c
RS
86732013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8674
8675 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
8676 cast to unsigned type.
8677
386b1f1f
RS
86782013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8679
8680 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
8681 tree_low_cst.
8682 (complete_array_type): Update comment to refer to tree_to_[su]hwi
8683 rather than tree_low_cst.
8684
ae7e9ddd
RS
86852013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8686
8687 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
8688 tree_to_uhwi throughout.
8689
9439e9a1
RS
86902013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8691
8692 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
8693 tree_low_cst (..., 0) with tree_to_shwi throughout.
8694
cc269bb6
RS
86952013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8696
8697 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
8698 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
8699
9541ffee
RS
87002013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
8701
8702 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
8703 host_integerp (..., 0) with tree_fits_shwi_p throughout.
8704
c02065fc
AH
87052013-11-15 Aldy Hernandez <aldyh@redhat.com>
8706
8707 * c-cilkplus.c: New file.
8708 * c-common.c (readonly_error): Add location argument.
8709 * c-common.h (readonly_error): Same.
8710 (c_finish_cilk_clauses): Protoize.
8711 (c_check_cilk_loop): Same.
8712 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
8713 Do not fail on error_mark_node.
8714 Abstract increment canonicalization to here...
8715 (c_omp_for_incr_canonicalize_ptr): New.
8716 c-pragma.c (init_pragma): Register "simd" pragma.
8717 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
8718 (enum pragma_cilk_clause): New.
8719
9cc65f15
RS
87202013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
8721
8722 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
8723 wchar_type and host_integerp checks.
8724
18f429e2
AM
87252013-11-14 Andrew MacLeod <amacleod@redhat.com>
8726
8727 * c-common.c: Likewise.
8728 * c-gimplify.c: Likewise.
8729 * cilk.c: Likewise.
8730
d8a2d370
DN
87312013-11-14 Diego Novillo <dnovillo@google.com>
8732
8733 * c-common.c: Include fold-const.h.
8734 Include stor-layout.h.
8735 Include calls.h.
8736 Include stringpool.h.
8737 Include attribs.h.
8738 Include varasm.h.
8739 Include trans-mem.h.
8740 * c-cppbuiltin.c: Include stor-layout.h.
8741 Include stringpool.h.
8742 * c-format.c: Include stringpool.h.
8743 * c-lex.c: Include stringpool.h.
8744 Include stor-layout.h.
8745 * c-pragma.c: Include stringpool.h.
8746 Include attribs.h.
8747 Include varasm.h.
8748 Include gcc-symtab.h.
8749 * c-pretty-print.c: Include stor-layout.h.
8750 Include attribs.h.
8751 * cilk.c: Include stringpool.h.
8752 Include calls.h.
8753
38b7bc7f
JM
87542013-11-13 Joseph Myers <joseph@codesourcery.com>
8755
8756 * c-common.h (enum rid): Add RID_AUTO_TYPE.
8757 * c-common.c (c_common_reswords): Add __auto_type.
8758 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
8759
45b0be94
AM
87602013-11-12 Andrew MacLeod <amacleod@redhat.com>
8761
18f429e2
AM
8762 * c-common.c: Include gimplify.h.
8763 * c-gimplify.c: Likewise.
8764 * cilk.c: Likewise.
8765 * c-omp.c: Include gimple-expr.h instead of gimple.h.
8766 * c-ubsan.c: Don't include gimple.h.
45b0be94 8767
582d9b50
JM
87682013-11-12 Joseph Myers <joseph@codesourcery.com>
8769
8770 * c-common.c (c_common_reswords): Add _Thread_local.
8771
6b28e197
JM
87722013-11-09 Joseph Myers <joseph@codesourcery.com>
8773
8774 * c-common.c (atomic_size_supported_p): New function.
8775 (resolve_overloaded_atomic_exchange)
8776 (resolve_overloaded_atomic_compare_exchange)
8777 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
8778 Use it instead of comparing size with a local list of sizes.
8779
267bac10
JM
87802013-11-07 Andrew MacLeod <amacleod@redhat.com>
8781 Joseph Myers <joseph@codesourcery.com>
8782
8783 * c-common.h (enum rid): Add RID_ATOMIC.
8784 * c-common.c (c_common_reswords): Add _Atomic.
8785 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
8786 (keyword_is_type_qualifier): Accept RID_ATOMIC.
8787 * c-format.c (check_format_types): Check for extra _Atomic
8788 qualifiers in format argument.
8789 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
8790 (pp_c_type_qualifier_list): Mention _Atomic in comment.
8791
5157b91e
TB
87922013-11-06 Tobias Burnus <burnus@net-b.de>
8793
8794 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
8795
6dbe0958
JM
87962013-11-06 Joseph Myers <joseph@codesourcery.com>
8797
8798 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
8799 standards modes.
8800 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
8801 to mean lack of IEEE 754 support.
8802
e8ff5196
TB
88032013-11-05 Tobias Burnus <burnus@net-b.de>
8804
8805 * c.opt (-Wdate-time): New option
8806 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
8807
254a0760
JM
88082013-11-05 Joseph Myers <joseph@codesourcery.com>
8809
8810 * c-cppbuiltin.c (cpp_iec_559_value): Test
8811 flag_excess_precision_cmdline not flag_excess_precision.
8812
6d7f7e0a
TB
88132013-11-05 Tobias Burnus <burnus@net-b.de>
8814
8815 * c.opt (fopenmp-simd): New option.
8816 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
8817 (omp_pragmas): ... this new struct.
8818 (c_pp_lookup_pragma): Also walk omp_pragmas.
8819 (init_pragma): Init pragmas for -fopenmp-simd.
8820
55a7f02f
MP
88212013-11-04 Marek Polacek <polacek@redhat.com>
8822
8823 PR c++/58979
8824 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
8825
9193fb05
JM
88262013-11-04 Joseph Myers <joseph@codesourcery.com>
8827
8828 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
8829 New functions.
8830 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
8831
94159ecf
EB
88322013-11-04 Eric Botcazou <ebotcazou@adacore.com>
8833
8834 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
8835 (dump_ada_specs): Adjust prototype of second callback.
8836 * c-ada-spec.c (cpp_check): New global variable.
8837 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
8838 (print_generic_ada_decl): Likewise.
8839 (has_static_fields): Change return type to bool and add guard.
8840 (has_nontrivial_methods): New predicate.
8841 (is_tagged_type): Change return type to bool.
8842 (separate_class_package): Call has_nontrivial_methods.
8843 (pp_ada_tree_identifier): Minor tweaks.
8844 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
8845 (dump_ada_array_domains): Likewise.
8846 (dump_ada_array_type): Likewise.
8847 (dump_template_types): Remove cpp_check parameter and do not pass it to
8848 dump_generic_ada_node.
8849 (dump_ada_template): Likewise.
8850 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
8851 recursively.
8852 (print_ada_methods): Change return type to integer. Remove cpp_check
8853 parameter and do not pass it down.
8854 (dump_nested_types): Remove cpp_check parameter and do not pass it to
8855 dump_generic_ada_node.
8856 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
8857 accessing methods.
8858 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
8859 down. Use has_nontrivial_methods to recognize C++ classes. Use return
8860 value of print_ada_methods.
8861 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
8862 Set cpp_check to it before invoking dump_ada_nodes.
8863 (dump_ada_specs): Likewise.
8864
b906f4ca
MP
88652013-11-03 Marek Polacek <polacek@redhat.com>
8866
8867 * c-ubsan.c: Don't include hash-table.h.
8868 (ubsan_instrument_vla): New function.
8869 * c-ubsan.h: Declare it.
8870
5e20cdc9
DM
88712013-10-31 David Malcolm <dmalcolm@redhat.com>
8872
8873 Automated part of renaming of symtab_node_base to symtab_node.
8874
8875 Patch autogenerated by rename_symtab.py from
8876 https://github.com/davidmalcolm/gcc-refactoring-scripts
8877 revision 58bb219cc090b2f4516a9297d868c245495ee622
8878
8879 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
8880 symtab_node_base to symtab_node.
8881
7057e645
ESR
88822013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
8883
8e745a17 8884 Implement C++14 digit separators.
7057e645
ESR
8885 * c-lex.c (interpret_float): Remove digit separators from scratch string
8886 before building real literal.
8887
193ea7bc
JJ
88882013-10-30 Jakub Jelinek <jakub@redhat.com>
8889
8890 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
8891
939b37da
BI
88922013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
8893
8894 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
8895 fields.
8896 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
8897 enabled.
8898 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
8899 (insert_cilk_frame): New prototype.
8900 (cilk_init_builtins): Likewise.
8901 (gimplify_cilk_spawn): Likewise.
8902 (c_cilk_install_body_w_frame_cleanup): Likewise.
8903 (cilk_detect_spawn_and_unwrap): Likewise.
8904 (cilk_set_spawn_marker): Likewise.
8905 (build_cilk_sync): Likewise.
8906 (build_cilk_spawn): Likewise.
8907 * cilk.c: New file.
8908
67348ccc
DM
89092013-10-29 David Malcolm <dmalcolm@redhat.com>
8910
8911 Patch autogenerated by refactor_symtab.py from
8912 https://github.com/davidmalcolm/gcc-refactoring-scripts
8913 revision 58bb219cc090b2f4516a9297d868c245495ee622
8914
8915 * c-gimplify.c (c_genericize): Update for conversion of symtab types
8916 to a true class hierarchy.
8917 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
8918
d570872d
RS
89192013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
8920
8921 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
8922
98906124
JL
89232013-10-26 Jeff Law <law@redhat.com>
8924
adfac8df
JJ
8925 * c-common.c (c_define_builtins): Remove mudflap support.
8926 * c.opt: Ignore and warn for mudflap options.
98906124 8927
d73749df 89282013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
8929
8930 PR other/33426
8931 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
8932 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
8933
3f04b1bb
JM
89342013-10-23 Jason Merrill <jason@redhat.com>
8935
8936 * c-format.c (gcc_cxxdiag_char_table): Add %X.
8937
acf0174b
JJ
89382013-10-11 Jakub Jelinek <jakub@redhat.com>
8939
acd15a28
JJ
8940 * c-common.h (omp_clause_mask::operator !=): New method.
8941 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
8942 instead of if (mask & something) tests everywhere.
8943
acf0174b
JJ
8944 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
8945 201307 instead of 201107.
8946 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
8947 (c_common_attribute_table): Add "omp declare target" and
8948 "omp declare simd" attributes.
8949 (handle_omp_declare_target_attribute,
8950 handle_omp_declare_simd_attribute): New functions.
8951 * c-omp.c: Include c-pragma.h.
8952 (c_finish_omp_taskgroup): New function.
8953 (c_finish_omp_atomic): Add swapped argument, if true,
8954 build the operation first with rhs, lhs arguments and use NOP_EXPR
8955 build_modify_expr.
8956 (c_finish_omp_for): Add code argument, pass it down to make_code.
8957 (c_omp_split_clauses): New function.
8958 (c_split_parallel_clauses): Removed.
8959 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
8960 c_omp_declare_simd_clauses_to_decls): New functions.
8961 * c-common.h (omp_clause_mask): New type.
8962 (OMP_CLAUSE_MASK_1): Define.
8963 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
8964 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
8965 omp_clause_mask::operator |, omp_clause_mask::operator &,
8966 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
8967 omp_clause_mask::operator ==): New methods.
8968 (enum c_omp_clause_split): New.
8969 (c_finish_omp_taskgroup): New prototype.
8970 (c_finish_omp_atomic): Add swapped argument.
8971 (c_finish_omp_for): Add code argument.
8972 (c_omp_split_clauses): New prototype.
8973 (c_split_parallel_clauses): Removed.
8974 (c_omp_declare_simd_clauses_to_numbers,
8975 c_omp_declare_simd_clauses_to_decls): New prototypes.
8976 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
8977 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
8978 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
8979 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
8980 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
8981 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
8982 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
8983 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
8984 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
8985 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
8986 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
8987 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
8988 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
8989 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
8990 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
8991 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
8992 PRAGMA_OMP_CLAUSE_UNIFORM.
8993
826cacfe
MG
89942013-10-09 Marc Glisse <marc.glisse@inria.fr>
8995
8996 PR tree-optimization/20318
8997 * c-common.c (handle_returns_nonnull_attribute): New function.
8998 (c_common_attribute_table): Add returns_nonnull.
8999
2284b034
MG
90002013-10-03 Marc Glisse <marc.glisse@inria.fr>
9001
9002 PR c++/19476
9003 * c.opt (fcheck-new): Move to common.opt.
9004
b56e9788
MP
90052013-09-25 Marek Polacek <polacek@redhat.com>
9006 Jakub Jelinek <jakub@redhat.com>
9007
9008 PR sanitizer/58413
9009 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
9010 an expression if we can prove it is correct.
9011 (ubsan_instrument_division): Likewise. Remove unnecessary
9012 check.
9013
ce6923c5
MP
90142013-09-18 Marek Polacek <polacek@redhat.com>
9015
9016 PR sanitizer/58411
9017 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
9018 Declare it.
9019 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
9020
fb5610fb
IS
90212013-09-14 Iain Sandoe <iain@codesourcery.com>
9022
9023 PR target/48094
9024 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
9025 fobjc-gc, freplace-objc-classes): Accept for LTO.
9026
88b0e79e
JC
90272013-09-13 Jacek Caban <jacek@codeweavers.com>
9028
9029 * c-target.def: New hook
9030
c9b0866a
PC
90312013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
9032
9033 PR c++/43452
9034 * c.opt (Wdelete-incomplete): Add.
9035
0af94e6f
JR
90362013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
9037
9038 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
9039 (vector_types_compatible_elements_p): New function.
9040 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
9041 declaration.
9042 (vector_types_compatible_elements_p): Declare.
9043
7c26172c
GDR
90442013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
9045
9046 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
9047 a virtual member function.
9048 (pp_simple_type_specifier): Remove.
9049 (pp_c_type_specifier): Likewise.
9050 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
9051 Rename from pp_c_type_specifier. Adjust.
9052 (c_pretty_printer::c_pretty_printer): Do not assign to
9053 simple_type_specifier.
9054
20059c8b
GDR
90552013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
9056
9057 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
9058 member function.
9059 (c_pretty_printer::storage_class_specifier): Likewise.
9060 (c_pretty_printer::initializer): Likewise.
9061 (pp_declaration): Remove.
9062 (pp_declaration_specifiers): Likewise.
9063 (pp_abstract_declarator): Likewise.
9064 (pp_declarator): Likewise.
9065 (pp_type_id): Likewise.
9066 (pp_statement): Likewise.
9067 (pp_constant): Likewise.
9068 (pp_id_expression): Likewise.
9069 (pp_primary_expression): Likewise.
9070 (pp_unary_expression): Likewise.
9071 (pp_multiplicative_expression): Likewise.
9072 (pp_conditional_expression): Likewise.
9073 (pp_assignment_expression): Likewise.
9074 (pp_expression): Likewise.
9075 (pp_c_type_id): Likewise.
9076 (pp_c_storage_class_specifier): Likewise.
9077 * c-pretty-print.c (pp_c_type_cast): Tidy.
9078 (pp_c_pointer): Likewise.
9079 (pp_c_type_specifier): Likewise.
9080 (pp_c_parameter_type_list): Likewise.
9081 (pp_c_function_definition): Likewise.
9082 (pp_c_init_declarator): Likewise.
9083 (pp_c_initializer_list): Likewise.
9084 (pp_c_constructor_elts): Likewise.
9085 (c_pretty_printer::direct_abstract_declarator): Likewise.
9086 (c_pretty_printer::declaration_specifiers): Likewise.
9087 (c_pretty_printer::primary_expression): Likewise.
9088 (c_pretty_printer::postfix_expression): Likewise.
9089 (c_pretty_printer::type_id): Rename from pp_c_type_id.
9090 (c_pretty_printer::storage_class_specifier): Rename from
9091 pp_c_storage_class_specifier.
9092 (c_pretty_printer::initializer): Rename from pp_c_initializer.
9093 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
9094 storage_class_specifier, initializer, offset_list, flags.
9095
de5a5fa1
MP
90962013-08-30 Marek Polacek <polacek@redhat.com>
9097
9098 * c-ubsan.c: New file.
9099 * c-ubsan.h: New file.
9100
8f0e4d72
GDR
91012013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
9102
9103 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
9104 member function.
9105 (c_pretty_printer::declaration_specifiers): Likewise.
9106 (c_pretty_printer::declarator): Likewise.
9107 (c_pretty_printer::abstract_declarator): Likewise.
9108 (c_pretty_printer::direct_abstract_declarator): Likewise.
9109 (c_pretty_printer::direct_declarator): Likewise.
9110 (c_pretty_printer::function_specifier): Likewise.
9111 (pp_declaration): Adjust.
9112 (pp_declaration_specifiers): Likewise.
9113 (pp_abstract_declarator): Likewise.
9114 (pp_direct_declarator): Likewise.
9115 (pp_function_specifier): Likewise.
9116 (pp_direct_abstract_declarator): Remove as unused.
9117 (pp_c_declaration): Remove.
9118 (pp_c_declaration_specifiers): Likewise.
9119 (pp_c_declarator): Likewise.
9120 (pp_c_direct_declarator): Likewise.
9121 (pp_c_function_specifier): Likewise.
9122 (pp_c_direct_abstract_declarator): Likewise.
9123 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
9124 from pp_c_abstract_declarator. Adjust.
ab20d992 9125 (c_pretty_printer::direct_abstract_declarator): Rename from
8f0e4d72
GDR
9126 pp_c_direct_abstract_declarator. Adjust.
9127 (c_pretty_printer::function_specifier): Rename from
9128 pp_c_function_specifier. Adjust.
9129 (c_pretty_printer::declaration_specifiers): Rename from
9130 pp_c_declaration_specifiers. Adjust.
9131 (c_pretty_printer::direct_declarator): Rename from
9132 pp_c_direct_declarator. Adjust.
9133 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
9134 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
9135 (c_pretty_printer::c_pretty_printer): Do not assign to
9136 declaration, declaration_specifiers, declarator,
9137 direct_declarator, direct_abstract_declarator, function_specifier.
9138
00d34d3a
GDR
91392013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
9140
9141 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
9142 virtual member function.
9143 (c_pretty_printer::multiplicative_expression): Likewise.
9144 (c_pretty_printer::conditional_expression): Likewise.
9145 (c_pretty_printer::assignment_expression): Likewise.
9146 (c_pretty_printer::expression): Likewise.
9147 (pp_unary_expression): Adjust.
9148 (pp_multiplicative_expression): Likewise.
9149 (pp_assignment_expression): Likewise.
9150 (pp_conditional_expression): Likewise.
9151 (pp_expression): Likewise.
9152 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
9153 from pp_c_unary_expression. Adjust.
9154 (c_pretty_printer::multiplicative_expression): Rename from
9155 pp_c_multiplicative_expression. Adjust.
9156 (c_pretty_printer::conditional_expression): Rename from
9157 pp_c_conditional_expression. Adjust.
9158 (c_pretty_printer::assignment_expression): Rename from
9159 pp_c_assignment_expression. Adjust.
9160 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
9161 (c_pretty_printer::c_pretty_printer): Do not assign to
9162 unary_expression, multiplicative_expression,
9163 conditional_expression, expression.
9164
fb22178f
GDR
91652013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
9166
9167 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
9168 virtual member function.
9169 (pp_postfix_expression): Adjust.
9170 (pp_c_postfix_expression): Remove.
9171 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
9172 from pp_c_postfix_expression. Adjust.
9173 (c_pretty_printer::c_pretty_printer): Do not assign to
9174 postfix_expression.
9175
7ecc2600
GDR
91762013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
9177
9178 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
9179 virtua member function.
9180 (pp_primary_expression): Adjust.
9181 (pp_c_primary_expression): Remove.
9182 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
9183 from pp_c_primary_expression. Adjust.
9184 (pp_c_initializer_list): Use pp_primary_expression.
9185 (c_pretty_printer::c_pretty_printer): Do not assign to
9186 primary_expression.
9187
0691175f
GDR
91882013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
9189
9190 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
9191 * c-pretty-print.c (M_): Remove.
9192 (c_pretty_printer::translate_string): Define.
9193 (pp_c_type_specifier): Use it.
9194 (pp_c_primary_expression): Likewise.
9195 (pp_c_expression): Likewise.
9196
66dfe4c4
GDR
91972013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
9198
9199 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
9200 virtual function.
9201 (pp_c_id_expression): Remove.
9202 (pp_id_expression): Adjust.
9203 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
9204 pp_c_id_expression. Adjust.
9205 (pp_c_postfix_expression): Use pp_id_expression.
9206 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
9207
ca43e9d5
GDR
92082013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
9209
9210 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
9211 member function.
9212 (pp_constant): Adjust.
9213 (pp_c_constant): Remove.
9214 * c-pretty-print.c (c_pretty_printer::constant): Rename from
9215 pp_c_constant. Adjust.
9216 (pp_c_constant)
9217 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
9218 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
9219
da6ca2b5
GDR
92202013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
9221
9222 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
9223 (c_pretty_printer::c_pretty_printer): Declare.
9224 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
9225 c_pretty_printer_init. Adjust.
9226 (print_c_tree): Do not call c_pretty_printer_init.
9227 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
9228
65a372f4
AC
92292013-08-09 Arnaud Charlet <charlet@adacore.com>
9230
9231 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
9232
fd9b0f32
PC
92332013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
9234
9235 PR c++/58080
9236 * c-common.c (pointer_int_sum): Add bool parameter.
9237 * c-common.h (pointer_int_sum): Adjust declaration.
9238
e0aec1e9
GDR
92392013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
9240
9241 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
9242 c_pretty_printer variable.
9243
b066401f
GDR
92442013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
9245
9246 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
9247 (pp_base): Remove.
9248 (pp_c_base): Likewise. Adjust users.
9249 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
9250 (pp_c_whitespace): Do not call pp_base.
9251 (pp_c_left_paren): Likewise.
9252 (pp_c_right_paren): Likewise.
9253 (pp_c_left_brace): Likewise.
9254 (pp_c_right_brace): Likewise.
9255 (pp_c_left_bracket): Likewise.
9256 (pp_c_right_bracket): Likewise.
9257 (pp_c_dot): Likewise.
9258 (pp_c_ampersand): Likewise.
9259 (pp_c_star): Likewise.
9260 (pp_c_arrow): Likewise.
9261 (pp_c_semicolon): Likewise.
9262 (pp_c_complement): Likewise.
9263 (pp_c_exclamation): Likewise.
9264 (pp_c_direct_declarator): Likewise.
9265 (pp_c_ws_string): Likewise.
9266 (pp_c_identifier): Likewise.
9267 (pp_c_statement): Likewise.
9268 (print_c_tree): Likewise.
9269
65e5a578
ESR
92702013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
9271
9272 PR c++/58072
9273 * c-common.c (c_parse_error): Catch user-defined literal tokens and
9274 provide useful error strings.
9275
137a1a27
GDR
92762013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
9277
9278 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
9279 printer functions instead of pp_string or operators and punctuators.
9280 (dump_generic_ada_node): Likewise.
9281 * c-pretty-print.c (pp_c_type_specifier): Likewise.
9282 (pp_c_relational_expression): Likewise.
9283 (pp_c_logical_or_expression): Likewise.
9284
07838b13
GDR
92852013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
9286
9287 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
9288 functions instead of pp_character.
9289 (pp_ada_tree_identifier): Likewise.
9290 (dump_ada_double_name): Likewise.
9291 (dump_ada_function_declaration): Likewise.
9292 (dump_ada_array_domains): Likewise.
9293 (dump_template_types): Likewise.
9294 (dump_generic_ada_node): Likewise.
9295 (print_ada_declaration): Likewise.
9296 (print_ada_struct_decl): Likewise.
9297 * c-pretty-print.c (pp_c_integer_constant): Likewise.
9298
433cc7b0
TT
92992013-07-23 Tom Tromey <tromey@redhat.com>
9300
9301 * c-common.h (enum rid) <RID_GENERIC>: New constant.
9302 * c-common.c (c_common_reswords): Add _Generic.
9303
688010ba
OB
93042013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
9305
9306 * c-common.c: Fix typos.
9307 * c-common.h: Likewise.
9308
2a99e5e6
LL
93092013-07-13 Lubos Lunak <l.lunak@suse.cz>
9310
9311 PR c++/55203
9312 * c-common.c (c_common_attribute_table): Add warn_unused.
9313 (handle_warn_unused_attribute): New.
9314
c26302d5
JJ
93152013-07-10 Jakub Jelinek <jakub@redhat.com>
9316
9317 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
9318 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
9319
dfeadaa0
PC
93202013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
9321
9322 PR c++/57869
9323 * c.opt: Add Wconditionally-supported.
9324
6a2fa4b2
GS
93252013-07-08 Graham Stott <graham.stott@btinternet.com>
9326
adfac8df 9327 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6a2fa4b2
GS
9328 unused variables l_length and l_node.
9329
ecdbd01a 93302013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
9331
9332 PR c/57821
9333 * c-common.c (complete_array_type): Delay folding first index
9334 like other indices. When folding, check for index overflow.
9335
bedc293e
MG
93362013-06-27 Marc Glisse <marc.glisse@inria.fr>
9337
9338 PR c++/57509
9339 * c-common.h (c_build_vec_perm_expr): New complain argument.
9340 * c-common.c (c_build_vec_perm_expr): Likewise.
9341 Use save_expr also in C++.
9342
604b2bfc
GDR
93432013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
9344
9345 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
9346 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
9347 * c-opts.c (c_common_post_options): Likewise.
9348
dfeadaa0 93492013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
713b46fa
BI
9350
9351 * array-notation-common.c (length_mismatch_in_expr): Changed the
9352 parameter type's from a dynamic array to a vec_tree. Also removed
9353 the size parameters.
9354 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
9355 the change above.
9356
2ce86d2e
BI
93572013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
9358
9359 * c-common.h (struct cilkplus_an_parts): New structure.
9360 (struct cilkplus_an_loop_parts): Likewise.
9361 (cilkplus_extract_an_triplets): New prototype.
9362 (fix_sec_implicit_args): Likewise.
9363 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
9364 (fix_sec_implicit_args): Likewise.
604b2bfc 9365
07a6825b
BI
93662013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
9367
9368 * array-notation-common.c (find_inv_trees): Removed an unwanted
9369 typecasting.
9370 * c-common.h (struct inv_list::additional_tcodes): Changed type from
9371 enum rid to enum tree_code.
9372
08346abd
JH
93732013-06-11 Jan Hubicka <jh@suse.cz>
9374
9375 * c-common.c (handle_alias_ifunc_attribute): Do not set
9376 DECL_EXTERNAL for weakref variables.
9377 * c-pragma.c (handle_pragma_weak): Make sure aliases
9378 are not declared as external.
9379
d60f1706
BI
93802013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
9381
9382 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
9383 function from c/c-array-notation.c.
9384 (is_cilkplus_reduce_builtin): Likewise.
9385 (find_rank): Likewise.
9386 (extract_array_notation_exprs): Likewise.
9387 (replace_array_notations): Likewise.
9388 (find_inv_trees): Likewise.
9389 (replace_inv_trees): Likewise.
9390 (contains_array_notation_expr): Likewise.
9391 (find_correct_array_notation_type): Likewise.
9392 * c-common.h (struct inv_list): Moved this struct from the file
9393 c/c-array-notation.c and added a new field called additional tcodes.
9394 (length_mismatch_in_expr_p): New prototype.
9395 (is_cilkplus_reduce_builtin): Likewise.
9396 (find_rank): Likewise.
9397 (extract_array_notation_exprs): Likewise.
9398 (replace_array_notation): Likewise.
9399 (find_inv_trees): Likewise.
9400 (replace_inv_trees): Likewise.
9401 (find_correct_array_notation_type): Likewise.
dfeadaa0 9402
36536d79
BI
94032013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
9404
9405 * c-common.c (c_define_builtins): When cilkplus is enabled, the
9406 function array_notation_init_builtins is called.
9407 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
9408 * c-common.def (ARRAY_NOTATION_REF): New tree.
9409 * c-common.h (build_array_notation_expr): New function declaration.
9410 (build_array_notation_ref): Likewise.
9411 (extract_sec_implicit_index_arg): New extern declaration.
9412 (is_sec_implicit_index_fn): Likewise.
9413 (ARRAY_NOTATION_CHECK): New define.
9414 (ARRAY_NOTATION_ARRAY): Likewise.
9415 (ARRAY_NOTATION_START): Likewise.
9416 (ARRAY_NOTATION_LENGTH): Likewise.
9417 (ARRAY_NOTATION_STRIDE): Likewise.
9418 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
9419 ARRAY_NOTATION_REF.
9420 (pp_c_expression): Likewise.
9421 * c.opt (flag_enable_cilkplus): New flag.
9422 * array-notation-common.c: New file.
9423
f7716d57
JJ
94242013-05-14 Jakub Jelinek <jakub@redhat.com>
9425
9426 PR c++/57274
9427 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
9428
a5e0cd1d
MG
94292013-05-10 Marc Glisse <marc.glisse@inria.fr>
9430
9431 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
9432 vectors.
9433
f6bc1c4a
HS
94342013-05-07 Han Shen <shenhan@google.com>
9435
9436 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
9437
3f12f6e9
SKS
94382013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
9439
9440 * c-common.c (check_user_alignment): Emit error for negative values.
9441
61949153
PC
94422013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
9443
9444 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
9445
e93e18e9
PC
94462013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
9447
9448 * c-cppbuiltin.c (c_cpp_builtins): Do not define
9449 __GXX_EXPERIMENTAL_CXX1Y__.
9450
44d90fe1 94512013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
8e745a17 9452 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
44d90fe1
PC
9453
9454 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
9455 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
9456 to simply use OPT_Wpointer_arith.
9457 (c_sizeof_or_alignof_type): Likewise.
9458
13f39b2e
PC
94592013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
9460
9461 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
9462
4b84d650
JJ
94632013-04-12 Jakub Jelinek <jakub@redhat.com>
9464
9465 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
9466 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
9467 specifiers.
9468
fb037b5d
SB
94692013-04-07 Steven Bosscher <steven@gcc.gnu.org>
9470
9471 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
9472
4e856798
PC
94732013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
9474
9475 * c-common.c (pointer_int_sum): Remove dead code.
9476
4b1baac8
RS
94772013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
9478
9479 PR middle-end/56524
9480 * c-common.c (handle_optimize_attribute): Don't call
9481 save_optabs_if_changed.
9482
0b50e654
JJ
94832013-03-05 Jakub Jelinek <jakub@redhat.com>
9484
9485 PR middle-end/56461
9486 * c-pch.c (pch_init): Free target_validity at the end.
9487
48c41403
JJ
94882013-03-04 Jakub Jelinek <jakub@redhat.com>
9489
9490 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
9491
e664c61c
KS
94922013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
9493 Jakub Jelinek <jakub@redhat.com>
9494
9495 PR sanitizer/56454
9496 * c-common.c (handle_no_sanitize_address_attribute): New function.
9497 (c_common_attribute_table): Add no_sanitize_address attribute.
9498 (handle_no_address_safety_analysis_attribute): Add
9499 no_sanitize_address attribute, not no_address_safety_analysis
9500 attribute.
9501
a475fd3d 95022013-02-18 Aldy Hernandez <aldyh@redhat.com>
135204dd
AH
9503
9504 PR target/52555
9505 * c-common.c (handle_optimize_attribute): Call
9506 save_optabs_if_changed.
9507
f6007d99
JJ
95082013-02-18 Jakub Jelinek <jakub@redhat.com>
9509 Steven Bosscher <steven@gcc.gnu.org>
9510
9511 PR pch/54117
9512 * c-opts.c (c_common_post_options): If debug info is enabled
9513 and non-dwarf*, refuse to load PCH files and when writing PCH
9514 file warn.
9515
cf35e2b1
JJ
95162013-02-05 Jakub Jelinek <jakub@redhat.com>
9517
9518 PR middle-end/56167
9519 * c-common.c (handle_error_attribute): Fix condition.
9520
32887460
JJ
95212013-01-30 Jakub Jelinek <jakub@redhat.com>
9522
9523 PR c++/55742
9524 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
9525
5af057d8
JM
95262013-01-18 Jason Merrill <jason@redhat.com>
9527
9528 PR target/54908
9529 * c.opt (-fextern-tls-init): New.
9530 * c-opts.c (c_common_post_options): Handle it.
9531
cc83c823
JJ
95322013-01-09 Jakub Jelinek <jakub@redhat.com>
9533
9534 PR c/48418
9535 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
9536 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
9537 and is either negative or bigger or equal to type precision
9538 of the first operand.
9539
a859517f
MP
95402012-12-03 Marek Polacek <polacek@redhat.com>
9541
9542 PR c/55570
9543 * c-common.c (check_user_alignment): Swap order of tests,
9544 check TREE_CODE first.
9545
2d7aa578
ESR
95462012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
9547
9548 PR c++/52654
9549 * c-common.h (overflow_type): New enum.
9550 (build_userdef_literal): Add overflow_type argument.
9551 (tree_userdef_literal): Add overflow_type.
9552 (USERDEF_LITERAL_OVERFLOW): New access macro.
9553 * c-common.c (build_userdef_literal): Add overflow_type
9554 argument.
9555 * c-lex.c (c_lex_with_flags): Add overflow_type to
9556 build_userdef_literal calls.
9557 (interpret_integer, interpret_float): Add overflow_type argument.
9558
cc3c4f62
RB
95592012-11-28 Richard Biener <rguenther@suse.de>
9560
9561 PR c/35634
9562 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
9563 here and use a type with proper overflow behavior for types that would
9564 need to be promoted for the arithmetic.
9565
77bc5132
JJ
95662012-11-23 Jakub Jelinek <jakub@redhat.com>
9567
9568 PR sanitizer/55435
9569 * c-common.c (handle_no_address_safety_analysis_attribute): New
9570 function.
9571 (c_common_attribute_table): Add no_address_safety_analysis.
9572
5dc99c46
SB
95732012-11-16 Simon Baldwin <simonb@google.com>
9574
9575 * c.opt: Add f[no-]canonical-system-headers.
9576 * c-opts.c (c_common_handle_option): Handle
9577 OPT_fcanonical_system_headers.
9578
a4a0016d
ESR
95792012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
9580
9581 PR c++/54413
9582 * c-opts.c (c_common_handle_option): Set new flags.
9583 * c.opt: Describe new flags.
9584
7dbb85a7
JM
95852012-11-09 Jason Merrill <jason@redhat.com>
9586
9587 * c.opt (Wabi-tag): New.
9588
ad7bac31
AK
95892012-11-09 Andi Kleen <ak@linux.intel.com>
9590
9591 PR 55139
9592 * c-common.c (get_atomic_generic_size): Mask with
8e745a17 9593 MEMMODEL_MASK
ad7bac31 9594
7332899a
MLI
95952012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
9596
9597 PR c/53063
9598 * c.opt (Wformat): Make it Alias Wformat=1.
9599 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
9600 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
9601 LangEnabledBy.
9602 (Wformat=): RejectNegative. Use LangEnabledBy.
9603 (Wnonnull): Use LangEnabledBy.
9604 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
9605 * c-format.c (set_Wformat): Delete.
9606 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
ab20d992
JJ
9607 (maybe_read_dollar_number): Likewise.
9608 (avoid_dollar_number): Likewise.
9609 (finish_dollar_format_checking): Likewise.
9610 (check_format_info): Likewise.
9611 (check_format_info_main): Likewise.
9612 (check_format_types): Likewise.
9613 (format_type_warning): Likewise.
9614 * c-common.c (int): Likewise.
9615 (check_function_sentinel): Likewise.
8e745a17 9616 * c-common.h (warn_format,set_Wformat): Do not declare here.
7332899a 9617
34a180a6
MLI
96182012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
9619
9620 PR c/53063
9621 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
9622 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
9623 Use LangEnabledBy.
9624 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
9625 common.opt.
9626 (Wvariadic-macros): Init(1).
9627 * c-opts.c (c_common_handle_option): Do not handle them
9628 explicitly.
9629 (c_common_post_options): Likewise.
9630 (sanitize_cpp_opts): warn_unused_macros is now
9631 cpp_warn_unused_macros.
9632 (push_command_line_include): Likewise.
9633 * c-common.c (warn_unknown_pragmas): Do not define.
9634 * c-common.h (warn_unknown_pragmas): Do not declare.
9635
3f46d6a5
MLI
96362012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
9637
9638 PR c/51294
9639 * c-common.c (conversion_warning): Handle conditional expressions.
9640
880661a4
JW
96412012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
9642
9643 PR c++/54930
9644 * c.opt (Wreturn_local_addr): Define new option.
9645
4514a96b
JM
96462012-10-25 Jason Merrill <jason@redhat.com>
9647
f14edc1a
JM
9648 * c.opt (Wvirtual-move-assign): New.
9649
4514a96b
JM
9650 * c.opt (Winherited-variadic-ctor): New.
9651
93100c6b
MG
96522012-10-25 Marc Glisse <marc.glisse@inria.fr>
9653
9654 PR c++/54427
9655 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
9656
1efcb8c6
JM
96572012-10-23 Joseph Myers <joseph@codesourcery.com>
9658
9659 * c-common.h (pch_cpp_save_state): Declare.
9660 * c-target.def (c_preinclude): New hook.
9661 * c-opts.c (done_preinclude): New.
9662 (push_command_line_include): Handle default preincluded header.
9663 (cb_file_change): Call pch_cpp_save_state when calling
9664 push_command_line_include.
9665 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
9666 (pch_cpp_save_state): New.
9667 (pch_init): Call pch_cpp_save_state conditionally, instead of
9668 calling cpp_save_state.
9669
4a0ae68e
MLI
96702012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
9671
9672 PR c/53063
9673 PR c/40989
9674 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
9675 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
9676 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
9677 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
9678 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
9679 * c-opts.c (c_common_handle_option): Remove explicit handling from
9680 here.
9681 (c_common_post_options): Likewise.
9682
67e4210b
EB
96832012-10-18 Eric Botcazou <ebotcazou@adacore.com>
9684
9685 * c-ada-spec.c (LOCATION_COL): Delete.
9686 (compare_location): New function.
9687 (compare_node): Use it.
9688 (compare_comment): Likewise.
9689
65d4f2cd
MLI
96902012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
9691
9692 PR c/53063
9693 PR c/40989
9694 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
9695 * c-opts.c (c_common_handle_option): Do not set them here. Add
9696 comment.
9697 (c_common_post_options): Likewise.
9698
909881cb
EB
96992012-10-16 Eric Botcazou <ebotcazou@adacore.com>
9700
9701 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
9702 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
9703 Remove POINTER_TYPE handling, add large unsigned handling and use
9704 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
9705
3a785c97
JJ
97062012-10-12 Jakub Jelinek <jakub@redhat.com>
9707
9708 PR c/54381
9709 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
9710 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
9711 locs and array of 3 trees instead of just single loc and single
9712 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
9713 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
9714 For *cmp* builtins that take two sources strings report warnings
9715 about first and second source, not about destination and source.
9716
5e54f81d
MG
97172012-10-12 Marc Glisse <marc.glisse@inria.fr>
9718
9719 PR c++/53055
9720 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
9721
f5b02f1e
EB
97222012-10-11 Eric Botcazou <ebotcazou@adacore.com>
9723
9724 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
9725 declaring something coming from another file.
9726
b46dbc6c
AC
97272012-10-10 Arnaud Charlet <charlet@adacore.com>
9728
f5b02f1e 9729 PR ada/54845
b46dbc6c
AC
9730 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
9731
5d9de0d0
PC
97322012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
9733
9734 PR c++/54194
9735 * c-common.c (warn_about_parentheses): Add location_t parameter;
9736 use EXPR_LOC_OR_LOC.
9737 * c-common.h: Update declaration.
9738
a212e43f
MG
97392012-10-09 Marc Glisse <marc.glisse@inria.fr>
9740
9741 PR c++/54427
9742 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
9743 more operations. Make error messages optional.
9744 * c-common.h (enum stv_conv): Moved from c-typeck.c.
9745 (scalar_to_vector): Declare.
9746
b1db7f91
JM
97472012-10-08 Jason Merrill <jason@redhat.com>
9748
9749 * c-common.c (c_common_reswords): Add thread_local.
9750
e28d52cf
DS
97512012-10-08 Dodji Seketeli <dodji@redhat.com>
9752
9753 PR c++/53528 C++11 attribute support
9754 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
9755 new functions.
9756 * c-common.c (check_cxx_fundamental_alignment_constraints): New
9757 static function.
9758 (handle_aligned_attribute): In choose strictest alignment
9759 among many. Use new check_cxx_fundamental_alignment_constraints.
9760 (handle_transparent_union_attribute): In c++11 attribute syntax,
9761 don't look through typedefs.
9762
3b78de56
AC
97632012-10-04 Arnaud Charlet <charlet@adacore.com>
9764
9765 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
9766 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
9767 out of dumpfile.h.
9768
6040bb5f
DC
97692012-09-25 Dehao Chen <dehao@google.com>
9770
9771 PR middle-end/54645
3b78de56 9772 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
6040bb5f
DC
9773 map when read in the pch.
9774
3f8257db 97752012-09-18 Arnaud Charlet <charlet@adacore.com>
0b07a57e
AC
9776
9777 * c-ada-spec.c: Style fixes.
9778
3f8257db 97792012-09-18 Thomas Quinot <quinot@adacore.com>
da5182be
TQ
9780
9781 * c.opt (-fada-spec-parent): Define new command line switch.
9782 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
9783 is specified, generate binding spec as a child of the specified unit.
9784
0ccb505d
PC
97852012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
9786 Manuel López-Ibáñez <manu@gcc.gnu.org>
9787
9788 PR c++/53210
9789 * c.opt ([Winit-self]): Enabled by -Wall in C++.
9790
c583af79
AC
97912012-08-23 Arnaud Charlet <charlet@adacore.com>
9792
9793 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
9794 for pointers, and add missing Convention C pragma.
9795 (print_ada_struct_decl): Add missing aliased keyword.
9796 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
9797
1a4049e7
JJ
97982012-08-17 Jakub Jelinek <jakub@redhat.com>
9799
9800 * c-common.c (sizeof_pointer_memaccess_warning): New function.
9801 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
9802 * c-opts.c (c_common_handle_option): Enable it for -Wall.
9803 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
9804 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
9805
70b5e7dc
RG
98062012-08-10 Richard Guenther <rguenther@suse.de>
9807
9808 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
9809
f8923f7e
SB
98102012-08-07 Steven Bosscher <steven@gcc.gnu.org>
9811
9812 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
9813 instead of separate pp_newline and pp_flush.
9814 (print_c_tree): Likewise.
9815
e45abe1f
RH
98162012-07-26 Richard Henderson <rth@redhat.com>
9817
9818 * c-common.c (handle_hot_attribute): Allow labels.
9819 (handle_cold_attribute): Likewise.
9820
332f1d24
JJ
98212012-07-20 Jakub Jelinek <jakub@redhat.com>
9822
9823 PR c++/28656
9824 * c-common.c (check_function_nonnull): Handle multiple nonnull
9825 attributes properly.
9826
7ee2468b
SB
98272012-07-16 Steven Bosscher <steven@gcc.gnu.org>
9828
9829 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
9830 * c-ada-spec.c: Likewise.
9831 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
9832
ee7b28eb
SB
98332012-07-14 Steven Bosscher <steven@gcc.gnu.org>
9834
9835 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
9836 Remove code conditional on it.
9837
6bdf3519
SB
98382012-07-11 Steven Bosscher <steven@gcc.gnu.org>
9839
9840 * c-gimplify.c: Do not include basic-block.h.
9841 * c-common.c: Do not include linfuncs.h.
9842
532aafad
SB
98432012-07-08 Steven Bosscher <steven@gcc.gnu.org>
9844
9845 * c-common.h: Include tree.h.
9846
8d0d1915
JM
98472012-07-02 Jason Merrill <jason@redhat.com>
9848
9849 PR c++/53524
9850 * c-common.c (get_priority): Call default_conversion.
9851
fbc873ad
UB
98522012-07-01 Uros Bizjak <ubizjak@gmail.com>
9853
9854 * c-pch.c (c_common_write_pch): Remove unused variables.
9855
d4a10d0a
SB
98562012-06-29 Steven Bosscher <steven@gcc.gnu.org>
9857
9858 * cppspec.c: Moved from gcc/ to here.
9859
6f3a2e23
KT
98602012-06-27 Kai Tietz <ktietz@redhat.com>
9861
9862 PR preprocessor/37215
9863 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
9864
8ca92d04
SB
98652012-06-21 Steven Bosscher <steven@gcc.gnu.org>
9866
9867 * c-common.h (c_common_print_pch_checksum): Remove.
9868 * c-pch.c: Do not include output.h.
9869 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
9870 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
9871 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
9872 (struct c_pch_header): Remove.
9873 (get_ident): Update gpch version.
9874 (pch_init): Do not print executable_checksum to asm_out_file.
9875 Do not fail if there is no asm_out_file to read back from. Set
9876 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
9877 (c_common_write_pch): Verify that nothing was written to asm_out_file
9878 since pch_init was called. Do not write a c_pch_header, and do not
9879 copy from asm_out_file to the PCH.
9880 (c_common_read_pch): Do not read a c_pch_header, and do not restore
9881 the content of asm_out_file from the PCH.
9882 (c_common_print_pch_checksum): Remove.
9883 * c-opts.c (c_common_init): Print out executable_checksum directly.
9884
70f42967
SB
98852012-06-19 Steven Bosscher <steven@gcc.gnu.org>
9886
9887 * c-target.def (objc_declare_unresolved_class_reference,
9888 objc_declare_class_definition): Add new hooks.
9889
a8781821
SB
98902012-06-19 Steven Bosscher <steven@gcc.gnu.org>
9891
9892 * c-lex.c: Do not include output.h.
9893 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
9894 Remove uses of ASM_OUTPUT_IDENT.
9895
9e1a8dd1
RR
98962012-06-15 Marc Glisse <marc.glisse@inria.fr>
9897
9898 PR c++/51033
9899 * c-common.h (c_build_vec_perm_expr): Move decl here.
9900 * c-common.c (c_build_vec_perm_expr): Move definition
9901 here.
9902
6f07a821
SB
99032012-06-06 Steven Bosscher <steven@gcc.gnu.org>
9904
9905 * c.opt (fconserve-space): Turn into a no-op.
9906
9faeb493 99072012-06-04 Sterling Augustine <saugustine@google.com>
c265f413
SA
9908
9909 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
9910 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
9911 both the start and end of the function.
9912
a4b7d13c
SB
99132012-06-04 Steven Bosscher <steven@gcc.gnu.org>
9914
9915 * c-common.c: Do not include output.h.
9916 * c-pragma.c: Likewise.
9917
c265f413
SA
99182012-06-04 Steven Bosscher <steven@gcc.gnu.org>
9919
9920 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
9921 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
9922 (lang_decl_name): Handle namespace decls.
9923
be7a421e
SB
99242012-05-31 Steven Bosscher <steven@gcc.gnu.org>
9925
9926 * c-ada-spec.c: Do not include output.h.
9927 * c-semantics.c: Likewise.
9928
65de6659
JM
99292012-05-29 Joseph Myers <joseph@codesourcery.com>
9930
9931 * c-common.c: Fix typo.
9932
ca5f4331
MM
99332012-05-29 Michael Matz <matz@suse.de>
9934
9935 * c-common.h (c_expand_decl): Remove prototype.
9936
4f7f7aca
MLI
99372012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
9938
9939 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
9940 * c-opts.c (c_common_handle_option): Remove code handling
9941 warn_missing_braces.
9942
4a792f9b
PC
99432012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
9944
9945 PR c++/25137
9946 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
9947 -Wmissing_braces.
9948
650dc14a
DS
99492012-05-22 Dodji Seketeli <dodji@redhat.com>
9950
9951 PR c++/53322
9952 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
9953
9b095bf1
MLI
99542012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
9955
9956 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
9957 * c-opts.c (c_common_handle_option): Do not handle explicitly
9958 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
9959
0b2c4be5
DS
99602012-05-16 Dodji Seketeli <dodji@redhat.com>
9961
9962 PR preprocessor/7263
ab20d992 9963 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
0b2c4be5
DS
9964 to cpp_classify_number. For diagnostics, use the precise location
9965 instead of the global input_location.
9966
a1bde5af
PC
99672012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
9968
d02924ef 9969 PR c++/11856
a1bde5af
PC
9970 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
9971
d1ede5f4
BS
99722012-05-14 Bernd Schmidt <bernds@codesourcery.com>
9973
a1bde5af 9974 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
d1ede5f4 9975
f2bc201f
MLI
99762012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
9977
9978 PR 53063
9979 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
9980 Wreorder): Use LangEnabledBy.
9981 * c-opts.c (c_common_handle_option): Do not enable them
9982 explicitly. Call lang-specific generated functions.
9983 (c_common_post_options): Do not set them here.
9984
95744782
MLI
99852012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
9986
9987 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
9988 Wmissing-field-initializers,Wmissing-parameter-type,
9989 Wold-style-declaration,Woverride-init): Use EnabledBy.
9990 * c-opts.c (c_common_post_options): Do not set here explicitly.
9991
7d5a5747
MLI
99922012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
9993
9994 PR 53063
9995 * c-opts.c (c_common_handle_option): Use handle_generated_option
9996 to enable sub-options.
9997
5a3c9cf2
PC
99982012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
9999
10000 PR c++/53158
10001 * c-common.c (warnings_for_convert_and_check): Use warning_at.
10002
3ac8781c
RG
100032012-05-10 Richard Guenther <rguenther@suse.de>
10004
10005 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
10006 adjust commentary about TYPE_IS_SIZETYPE types.
10007
1e537948
MLI
100082012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
10009
10010 PR c++/53261
10011 * c-common.c (warn_logical_operator): Check that argument of
10012 integer_zerop is not NULL.
10013
f2c4a785
MLI
100142012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
10015
10016 PR c/43772
10017 * c-common.c (warn_logical_operator): Do not warn if either side
10018 is already true or false.
10019
50f305ca
MLI
100202012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
10021
10022 PR c/51712
10023 * c-common.c (expr_original_type): New.
10024 (shorten_compare): Do not warn for enumeration types.
10025
0c3641b0
MLI
100262012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
10027
10028 * c.opt (fpermissive): Add Var(flag_permissive).
10029
7edaa4d2
MG
100302012-04-30 Marc Glisse <marc.glisse@inria.fr>
10031
10032 PR c++/51033
10033 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
10034 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
10035
b9c8da34
DS
100362012-04-30 Dodji Seketeli <dodji@redhat.com>
10037
10038 Add -Wvarargs option
ab20d992 10039 * c.opt (Wvarargs): Define new option.
b9c8da34 10040
e6c69da0
MLI
100412012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
10042
10043 * c-common.c (check_function_arguments): Replace
10044 Wmissing-format-attribute with Wsuggest-attribute=format.
10045
90137d8f
MLI
100462012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
10047
10048 * c.opt (Wsuggest-attribute=format): New. Alias of
10049 Wmissing-format-attribute.
10050 * c-format.c (decode_format_type): Replace
10051 Wmissing-format-attribute with Wsuggest-attribute=format.
10052 (check_function_format): Likewise.
10053
9faeb493 100542012-04-27 Ollie Wild <aaw@google.com>
7f5f5f98
OW
10055
10056 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
10057 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
10058 * c.opt: Add Wliteral-suffix.
10059
c1771a20
MLI
100602012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
10061
10062 PR c/44774
10063 * c.opt (Wpedantic): New.
10064 (pedantic): Alias Wpedantic.
10065 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
10066 (c_common_post_options): Likewise.
10067 (sanitize_cpp_opts): Likewise.
10068 * c-lex.c (interpret_float): Likewise.
10069 * c-format.c (check_format_types): Likewise.
10070 * c-common.c (pointer_int_sum): Likewise.
10071 (c_sizeof_or_alignof_type): Likewise.
10072 (c_add_case_label): Likewise.
10073 (c_do_switch_warnings): Likewise.
10074 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
10075
04b391c1
JM
100762012-04-15 Jason Merrill <jason@redhat.com>
10077
10078 PR c++/52818
10079 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
10080 (C_STD_NAME): Distinguish between C++98 and C++11.
10081
ac868f29
EB
100822012-04-11 Eric Botcazou <ebotcazou@adacore.com>
10083
10084 PR target/52624
10085 * c-common.h (uint16_type_node): Rename into...
10086 (c_uint16_type_node): ...this.
10087 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
10088 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
10089
fd4116f4
MLI
100902012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
10091
10092 * c-common.c (warn_if_unused_value): Move definition to here.
10093 * c-common.h (warn_if_unused_value): Move declaration to here.
10094
573ac65e
WB
100952012-03-23 William Bader <williambader@hotmail.com>
10096
10097 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
10098
552b8185
JM
100992012-03-20 Jason Merrill <jason@redhat.com>
10100
10101 * c-common.h (enum cxx_dialect): Add cxx1y.
10102 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
10103 test.
10104 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
10105 * c-opts.c (c_common_post_options): Likewise.
10106 (set_std_cxx1y): New.
10107 (c_common_handle_option): Call it.
10108 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
10109
04398fa8
PC
101102012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
10111
10112 PR c++/14710
10113 * c.opt ([Wuseless-cast]): Add.
10114
d2a12ae7
RG
101152012-03-16 Richard Guenther <rguenther@suse.de>
10116
10117 * c-pretty-print.c (pp_c_initializer_list): Adjust.
10118
a12bf402
MLI
101192012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
10120
10121 PR c++/44783
10122 * c.opt (ftemplate-backtrace-limit) Add.
10123
5c30094f
RO
101242012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10125
10126 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
10127 handling.
10128 * c-pragma.c (handle_pragma_extern_prefix): Remove.
10129 (init_pragma): Don't register extern_prefix.
10130
21fa2faf
RG
101312012-03-12 Richard Guenther <rguenther@suse.de>
10132
10133 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
10134 (builtin_type_for_size): Likewise.
10135
e3793c6f
JJ
101362012-02-13 Jakub Jelinek <jakub@redhat.com>
10137
10138 PR c++/52215
10139 * c-common.c (sync_resolve_params): Don't decide whether to convert
10140 or not based on TYPE_SIZE comparison, convert whenever arg_type
10141 is unsigned INTEGER_TYPE.
10142
93286335
PC
101432012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
10144
10145 PR c/52118
10146 * c.opt ([Wunused-local-typedefs]): Fix description.
10147
7a421706
MS
101482012-01-24 Mike Stump <mikestump@comcast.net>
10149
10150 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
10151 exactly.
10152
ba9b1f11
RG
101532012-01-18 Richard Guenther <rguenther@suse.de>
10154
10155 * c-opts.c (c_common_post_options): Reset LTO flags if
10156 we are about to generate a PCH.
10157
465406be
PC
101582012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
10159
10160 PR c++/51777
10161 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
10162 use pp_unsigned_wide_integer.
10163
aee15221
RG
101642012-01-10 Richard Guenther <rguenther@suse.de>
10165
10166 PR middle-end/51806
10167 * c-opts.c (c_common_handle_option): Move -Werror handling
10168 to language independent code.
10169
5720c0dc
RG
101702012-01-05 Richard Guenther <rguenther@suse.de>
10171
10172 PR middle-end/51764
10173 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
10174 from common.opt.
10175
73ac190a
PC
101762011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
10177
10178 PR c++/51316
10179 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
10180 of array types with an unknown bound.
10181
48b0b196
JM
101822011-12-20 Joseph Myers <joseph@codesourcery.com>
10183
10184 * c-common.c (flag_isoc99): Update comment to refer to C11.
10185 (flag_isoc1x): Change to flag_isoc11.
10186 * c-common.h (flag_isoc99): Update comment to refer to C11.
10187 (flag_isoc1x): Change to flag_isoc11.
10188 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
10189 C11.
10190 * c-opts.c (set_std_c1x): Change to set_std_c11.
10191 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
10192 Call set_std_c11.
10193 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
10194 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
10195 * c.opt (std=c1x): Change to std=c11. Document as non-draft
10196 standard.
10197 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
10198 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
10199 (std=gnu1x): Make alias of std=gnu11.
10200
d58d6eb5
JM
102012011-12-19 Jason Merrill <jason@redhat.com>
10202
10203 PR c++/51228
10204 * c-common.c (handle_transparent_union_attribute): Check the first
10205 field if the type is complete.
10206
b3908fcc
JW
102072011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
10208
10209 PR libstdc++/51365
10210 * c-common.c (RID_IS_FINAL): Add.
10211 * c-common.h (RID_IS_FINAL): Add.
10212
fea3ca91
IS
102132011-11-30 Iain Sandoe <iains@gcc.gnu.org>
10214
10215 * c.opt (fgnu-runtime): Provide full description.
10216 (fnext-runtime): Likewise.
10217 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
10218
62bad7cd
AM
102192011-11-28 Andrew MacLeod <amacleod@redhat.com>
10220
10221 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
10222 predefines in one place. Add LOCK_FREE predefines.
10223 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
10224 new func.
10225
c466c4ff
AM
102262011-11-24 Andrew MacLeod <amacleod@redhat.com>
10227
10228 PR c/51256
9faeb493 10229 * c-common.c (get_atomic_generic_size): Check for various error
c466c4ff 10230 conditions
9faeb493
UB
10231 (resolve_overloaded_atomic_exchange,
10232 resolve_overloaded_atomic_compare_exchange,
c466c4ff
AM
10233 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
10234 error_mark_node for error conditions.
9faeb493 10235
a5952633
RG
102362011-11-08 Richard Guenther <rguenther@suse.de>
10237
10238 PR middle-end/51010
ab20d992 10239 * c-pretty-print.c (pp_c_expression): Handle SSA_NAMEs.
a5952633 10240
0a35513e
AH
102412011-11-07 Richard Henderson <rth@redhat.com>
10242 Aldy Hernandez <aldyh@redhat.com>
10243 Torvald Riegel <triegel@redhat.com>
10244
10245 Merged from transactional-memory.
10246
10247 * c-common.c (handle_tm_wrap_attribute,
10248 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
10249 (struct c_common_reswords): Added __transaction* keywords.
10250 (struct c_common_attribute_table): Added transaction* and tm_regparm
10251 attributes.
10252 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
10253 masks.
10254 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
10255 find_tm_attribute): Declare.
10256
6d87092d
JM
102572011-11-07 Jason Merrill <jason@redhat.com>
10258
10259 PR c++/35688
10260 * c-common.c, c-common.h: Revert yesterday's changes.
10261
8e7860a1
JM
102622011-11-06 Jason Merrill <jason@redhat.com>
10263
10264 PR c++/35688
10265 * c-common.c (decl_has_visibility_attr): Split out from...
10266 (c_determine_visibility): ...here.
10267 * c-common.h: Declare it.
10268
d19fa6b5
JM
102692011-11-06 Joseph Myers <joseph@codesourcery.com>
10270
10271 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
10272 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
10273 type.
10274 (check_user_alignment): New. Split out of
10275 handle_aligned_attribute. Disallow integer constants with
10276 noninteger types. Conditionally allow zero.
10277 (handle_aligned_attribute): Use check_user_alignment.
10278 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
10279
86951993
AM
102802011-11-06 Andrew MacLeod <amacleod@redhat.com>
10281 Richard Henderson <rth@redhat.com>
10282
10283 Merged from cxx-mem-model.
10284
10285 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
9faeb493 10286 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
86951993
AM
10287 parameters that are the same type size.
10288 (get_atomic_generic_size): New. Find size of generic
10289 atomic function parameters and do typechecking.
10290 (add_atomic_size_parameter): New. Insert size into parameter list.
10291 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
10292 either __atomic_exchange_n or external library call.
9faeb493 10293 (resolve_overloaded_atomic_compare_exchange): Restructure
86951993 10294 __atomic_compare_exchange to either _n variant or external library call.
9faeb493 10295 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
86951993
AM
10296 __atomic_load_n or an external library call.
10297 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
10298 __atomic_store_n or an external library call.
10299 (resolve_overloaded_builtin): Handle new __atomic builtins.
10300
cf9e9959
EB
103012011-11-04 Eric Botcazou <ebotcazou@adacore.com>
10302
10303 PR c++/50608
10304 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
10305 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
10306 <INDIRECT_REF>: Return the argument.
10307 <ARRAY_REF>: Remove special code for negative offset.
10308 Call fold_build_pointer_plus instead of size_binop.
10309 (fold_offsetof): Remove STOP_REF argument and adjust.
10310 * c-common.h (fold_offsetof_1): Declare.
10311 (fold_offsetof): Remove STOP_REF argument.
10312
25339f10
JM
103132011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
10314
10315 PR c++/50810
10316 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
10317 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
10318 Wnarrowing for C++0x and C++98.
10319 * c.opt ([Wnarrowing]): Update.
10320
89401152
PC
103212011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
10322
10323 PR c++/44277
10324 * c.opt: Add Wzero-as-null-pointer-constant.
10325
97e3ad20
JM
103262011-10-31 Jason Merrill <jason@redhat.com>
10327
15694fdd
JM
10328 * c.opt (-fdeduce-init-list): Off by default.
10329
97e3ad20
JM
10330 PR c++/50920
10331 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
10332 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
10333 and -Wc++11-compat.
10334 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
10335
fb9120e3
RAV
103362011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
10337
10338 PR c++/30066
10339 * c.opt (fvisibility-inlines-hidden): Description change.
10340
3ce4f9e4
ESR
103412011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
10342
10343 Implement C++11 user-defined literals.
10344 * c-common.c (build_userdef_literal): New.
10345 * c-common.def: New tree code.
10346 * c-common.h (tree_userdef_literal): New tree struct and accessors.
10347 * c-lex.c (interpret_float): Add suffix parm.
10348 (c_lex_with_flags): Build literal tokens.
10349
5f53c243
PC
103502011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
10351
10352 PR c++/50841
10353 Revert:
10354 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
10355
10356 PR c++/50810
10357 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
10358 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
10359 Wnarrowing for C++0x and C++98.
10360 * c.opt ([Wnarrowing]): Update.
10361
263734e1
PC
103622011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
10363
10364 PR c++/50810
10365 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
10366 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
10367 Wnarrowing for C++0x and C++98.
10368 * c.opt ([Wnarrowing]): Update.
10369
d2e312d7
PC
103702011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
10371
10372 PR c++/45385
10373 * c-common.c (conversion_warning): Remove code looking for
10374 artificial operands.
10375
d17687f6
DS
103762011-10-18 Dodji Seketeli <dodji@redhat.com>
10377
10378 PR bootstrap/50760
10379 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
9faeb493 10380 !NO_IMPLICIT_EXTERN_C.
d17687f6 10381
fc8396e9
PC
103822011-10-17 Michael Spertus <mike_spertus@symantec.com>
10383
10384 * c-common.c (c_common_reswords): Add __bases,
10385 __direct_bases.
10386 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
10387
103882011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
10389
10390 PR c++/50757
10391 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
10392
847e697a
TT
103932011-10-15 Tom Tromey <tromey@redhat.com>
10394 Dodji Seketeli <dodji@redhat.com>
10395
10396 * c.opt (fdebug-cpp): New option.
10397 * c-opts.c (c_common_handle_option): Handle the option.
10398 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
10399 output stream in parameter. Factorized from ...
10400 (maybe_print_line): ... this. Dump location debug information when
10401 -fdebug-cpp is in effect.
10402 (print_line_1): New static function. Takes an output stream in
10403 parameter. Factorized from ...
10404 (print_line): ... here. Dump location information when -fdebug-cpp
10405 is in effect.
10406 (scan_translation_unit): Dump location information when
10407 -fdebug-cpp is in effect.
10408
92582b75
TT
104092011-10-15 Tom Tromey <tromey@redhat.com>
10410 Dodji Seketeli <dodji@redhat.com>
10411
10412 * c.opt (ftrack-macro-expansion): New option. Handle it with and
10413 without argument.
10414 * c-opts.c (c_common_handle_option)<case
10415 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
10416 cases. Handle -ftrack-macro-expansion with and without argument.
10417
46427374
TT
104182011-10-15 Tom Tromey <tromey@redhat.com>
10419 Dodji Seketeli <dodji@redhat.com>
10420
10421 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
10422 (print_line, cb_define, do_line_change): Adjust to avoid touching
10423 the internals of struct line_map. Use the public API instead.
10424 * c-pch.c (c_common_read_pch): Likewise.
10425 * c-lex.c (fe_file_change): Likewise.
10426
fc8396e9
PC
104272011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
10428
10429 PR c++/17212
10430 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
10431
104322011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
10433
10434 PR c++/33067
10435 * c-pretty-print.c (pp_c_floating_constant): Output
10436 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
10437
e79983f4
MM
104382011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
10439
10440 * c-common.c (def_builtin_1): Delete old interface with two
10441 parallel arrays to hold standard builtin declarations, and replace
10442 it with a function based interface that can support creating
10443 builtins on the fly in the future. Change all uses, and poison
10444 the old names. Make sure 0 is not a legitimate builtin index.
10445 * c-omp.c (c_finish_omp_barrier): Ditto.
10446 (c_finish_omp_taskwait): Ditto.
10447 (c_finish_omp_flush): Ditto.
10448
6637388f
TG
104492011-10-11 Tristan Gingold <gingold@adacore.com>
10450
10451 * c.opt: (fallow-parameterless-variadic-functions): New.
10452
3797cb21
DS
104532011-09-08 Dodji Seketeli <dodji@redhat.com>
10454
10455 PR c++/33255 - Support -Wunused-local-typedefs warning
10456 * c-common.h (struct c_language_function::local_typedefs): New
10457 field.
9faeb493
UB
10458 (record_locally_defined_typedef, maybe_record_typedef_use)
10459 (maybe_warn_unused_local_typedefs): Declare new functions.
3797cb21 10460 * c-common.c (record_locally_defined_typedef)
9faeb493
UB
10461 (maybe_record_typedef_use)
10462 (maybe_warn_unused_local_typedefs): Define new functions.
3797cb21
DS
10463 * c.opt: Declare new -Wunused-local-typedefs flag.
10464
693ddb1b
EB
104652011-09-06 Eric Botcazou <ebotcazou@adacore.com>
10466
10467 PR middle-end/50266
10468 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
10469 computations.
10470
830c740f
RG
104712011-09-05 Richard Guenther <rguenther@suse.de>
10472
10473 * c-common.c (complete_array_type): Use ssize_int (-1) instead
10474 of integer_minus_one_node for empty array upper bounds.
10475
892a371f
DS
104762011-08-28 Dodji Seketeli <dodji@redhat.com>
10477
10478 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
10479 it's the first time it's being called on this main TU.
10480
0e3fdb48
RB
104812011-08-24 Richard Guenther <rguenther@suse.de>
10482
10483 PR c/49396
10484 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
10485
104862011-08-22 Gabriel Charette <gchare@google.com>
e3dfef44
GC
10487
10488 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
10489 defined in cpp_init_builtins and c_cpp_builtins.
10490
d4a83c10
JM
104912011-08-19 Joseph Myers <joseph@codesourcery.com>
10492
10493 * c-common.c (c_common_reswords): Add __builtin_complex.
10494 * c-common.h (RID_BUILTIN_COMPLEX): New.
10495
bbceee64
JM
104962011-08-18 Joseph Myers <joseph@codesourcery.com>
10497
10498 * c-common.c (c_common_reswords): Add _Noreturn.
10499 (keyword_is_function_specifier): Handle RID_NORETURN.
10500 * c-common.h (RID_NORETURN): New.
10501
3f8257db 105022011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
0e3a99ae
AS
10503
10504 * c-common.c (unsafe_conversion_p): New function. Check if it is
10505 unsafe to convert an expression to the type.
10506 (conversion_warning): Adjust, use unsafe_conversion_p.
10507 * c-common.h (unsafe_conversion_p): New function declaration.
10508
20906c66
JJ
105092011-08-02 Jakub Jelinek <jakub@redhat.com>
10510
10511 * c-common.h (c_finish_omp_atomic): Adjust prototype.
10512 (c_finish_omp_taskyield): New prototype.
10513 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
10514 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
10515 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
10516 or RHS1 have side-effects, evaluate those too in the right spot,
10517 if it is a decl and LHS is also a decl, error out if they
10518 aren't the same.
10519 (c_finish_omp_taskyield): New function.
10520 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
10521 * c-pragma.c (omp_pragmas): Add taskyield.
10522 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
10523 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
10524 PRAGMA_OMP_CLAUSE_MERGEABLE.
10525
770e5a2e
DS
105262011-07-25 Dodji Seketeli <dodji@redhat.com>
10527
10528 * c-common.h (set_underlying_type): Remove parm name from
10529 declaration.
10530
1baae426
RG
105312011-07-25 Romain Geissler <romain.geissler@gmail.com>
10532
10533 * c-pretty-print.h: Search c-common.h in c-family.
9faeb493 10534
fcb21722
JM
105352011-07-22 Jason Merrill <jason@redhat.com>
10536
76f86d00
JM
10537 PR c++/49793
10538 * c.opt (Wnarrowing): New.
10539
3a636414
JM
10540 PR c++/30112
10541 * c-common.h: Declare c_linkage_bindings.
10542 * c-pragma.c (handle_pragma_redefine_extname): Use it.
10543
fcb21722
JM
10544 PR c++/49813
10545 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
10546 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
10547 as flag_isoc99 for 'restrict'.
10548 (pp_c_specifier_qualifier_list): Likewise for _Complex.
10549
02614448
ILT
105502011-07-21 Ian Lance Taylor <iant@google.com>
10551
10552 PR middle-end/49705
10553 * c-common.c (c_disable_warnings): New static function.
10554 (c_enable_warnings): New static function.
10555 (c_fully_fold_internal): Change local unused_p to bool. Call
10556 c_disable_warnings and c_enable_warnings rather than change
10557 c_inhibit_evaluation_warnings.
10558
34429675
JM
105592011-07-20 Jason Merrill <jason@redhat.com>
10560
10561 PR c++/6709 (DR 743)
10562 PR c++/42603 (DR 950)
10563 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
10564 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
10565 (CPP_DECLTYPE): New.
10566 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
10567
5d49b6a7
RG
105682011-07-19 Richard Guenther <rguenther@suse.de>
10569
10570 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
10571 * c-omp.c (c_finish_omp_for): Likewise.
10572
e84a58ff
EB
105732011-07-12 Eric Botcazou <ebotcazou@adacore.com>
10574
10575 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
10576 body on the next line.
10577
329af3c7
JM
105782011-07-08 Jason Merrill <jason@redhat.com>
10579
4063e61b
JM
10580 PR c++/45437
10581 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
10582
329af3c7
JM
10583 PR c++/49673
10584 * c-common.c (c_apply_type_quals_to_decl): Don't check
10585 TYPE_NEEDS_CONSTRUCTING.
10586
1a072294
RG
105872011-07-06 Richard Guenther <rguenther@suse.de>
10588
10589 * c-common.c (c_common_nodes_and_builtins):
10590 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
10591
fce5dddd
RG
105922011-07-05 Richard Guenther <rguenther@suse.de>
10593
10594 * c-common.c (c_common_nodes_and_builtins): Build all common
10595 tree nodes first.
10596
45d439ac
JJ
105972011-06-27 Jakub Jelinek <jakub@redhat.com>
10598
56300785
JJ
10599 * c-common.h (c_tree_chain_next): New static inline function.
10600
45d439ac
JJ
10601 * c-common.c (check_builtin_function_arguments): Handle
10602 BUILT_IN_ASSUME_ALIGNED.
10603
e0a8ecf2
AM
106042011-06-21 Andrew MacLeod <amacleod@redhat.com>
10605
10606 * c-common.c: Add sync_ or SYNC__ to builtin names.
10607 * c-omp.c: Add sync_ or SYNC__ to builtin names.
dfb43cd5
PV
10608
106092011-06-20 Pierre Vittet <piervit@pvittet.com>
10610
10611 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
10612 handler.
10613 (gen_pragma_handler): New union.
10614 (internal_pragma_handler): New type.
10615 (c_register_pragma_with_data)
10616 (c_register_pragma_with_expansion_and_data): New functions.
10617
10618 * c-pragma.c (registered_pragmas, c_register_pragma_1)
10619 (c_register_pragma, c_register_pragma_with_expansion)
10620 (c_invoke_pragma_handler): Changed to work with
10621 internal_pragma_handler.
10622 (c_register_pragma_with_data)
10623 (c_register_pragma_with_expansion_and_data): New functions.
10624
677f3fa8
JM
106252011-06-14 Joseph Myers <joseph@codesourcery.com>
10626
10627 * c-common.c: Include common/common-target.h.
10628 (handle_section_attribute): Use
10629 targetm_common.have_named_sections.
10630 * c-cppbuiltin.c: Include common/common-target.h.
10631 (c_cpp_builtins): Use targetm_common.except_unwind_info.
10632
d7fc8c14
RG
106332011-06-10 Richard Guenther <rguenther@suse.de>
10634
10635 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
10636 to print a IDENTIFIER_NODE.
10637
10e48e39
RO
106382011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10639 Joseph Myers <joseph@codesourcery.com>
10640
10641 * c.opt (fbuilding-libgcc): New option.
10642 * c-cppbuiltin.c (c_cpp_builtins): Define
10643 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
10644
6976ae51
JM
106452011-06-07 Jason Merrill <jason@redhat.com>
10646
3ff60975
JM
10647 * c-common.c (max_tinst_depth): Lower default to 900.
10648
6976ae51
JM
10649 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
10650
009db074
RG
106512011-06-07 Richard Guenther <rguenther@suse.de>
10652
10653 * c-common.c (c_common_nodes_and_builtins): Do not set
10654 size_type_node or call set_sizetype.
10655
b4592b92
DS
106562011-06-07 Dodji Seketeli <dodji@redhat.com>
10657
10658 PR debug/49130
10659 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
9faeb493 10660 type when using pointer comparison to compare types.
b4592b92 10661
014ab419
JW
106622011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
10663
10664 * c.opt: Add -Wdelete-non-virtual-dtor.
10665 * c-opts.c (c_common_handle_option): Include it in -Wall.
10666
4f60111f
NF
106672011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
10668
10669 PR bootstrap/49190
10670
10671 Revert:
10672 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
10673
10674 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
10675 not tree_common.
10676
4cc4f2f4
JJ
106772011-05-27 Jakub Jelinek <jakub@redhat.com>
10678
10679 PR c++/49165
10680 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
10681 C++ don't call c_common_truthvalue_conversion on void type arms.
10682
38e01f9e
NF
106832011-05-27 Nathan Froyd <froydnj@codesourcery.com>
10684
10685 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
10686 (stmt_list_stack): Define.
10687 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
10688 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
10689
92e948a8
NF
106902011-05-26 Nathan Froyd <froydnj@codesourcery.com>
10691
10692 * c-common.c (warning_candidate_p): Check for BLOCKs.
10693
a2fc3e63
NF
106942011-05-26 Nathan Froyd <froydnj@codesourcery.com>
10695
10696 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
10697 not tree_common.
10698
0957c029
JJ
106992011-05-25 Jakub Jelinek <jakub@redhat.com>
10700
10701 * c-common.c (def_fn_type): Remove extra va_end.
10702
828fb3ba
JM
107032011-05-23 Jason Merrill <jason@redhat.com>
10704
10705 PR c++/48106
10706 * c-common.c (c_common_get_narrower): New.
10707 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
10708
dde05067
NF
107092011-05-23 Nathan Froyd <froydnj@codesourcery.com>
10710
10711 * c-common.h (check_function_arguments): Tweak prototype of
10712 check_function_arguments.
10713 * c-common.c (check_function_arguments): Likewise. Adjust
10714 calls to check_function_nonnull, check_function_format, and
10715 check_function_sentinel.
10716 (check_function_sentinel): Take a FUNCTION_TYPE rather than
10717 separate attributes and typelist arguments. Use
10718 FOREACH_FUNCTION_ARGS to iterate over argument types.
10719
3c0d13bf
PC
107202011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
10721
10722 * c-common.c (c_common_reswords): Reorder.
10723 * c-common.h (rid): Likewise.
10724
8242dd04
NF
107252011-05-10 Nathan Froyd <froydnj@codesourcery.com>
10726
10727 * c-common.c (def_fn_type): Don't call build_function_type, call
10728 build_function_type_array or build_varargs_function_type_array
10729 instead.
10730 (c_common_nodes_and_builtins): Likewise.
10731
3d528853
NF
107322011-05-05 Nathan Froyd <froydnj@codesourcery.com>
10733
10734 * c-common.c (c_add_case_label): Omit the loc argument to
10735 build_case_label.
10736 * c-common.h (build_case_label): Remove.
10737 * c-semantics.c (build_case_label): Remove.
10738
a04a722b
JM
107392011-05-05 Joseph Myers <joseph@codesourcery.com>
10740
10741 * c-objc.h (objc_start_method_definition): Update prototype.
10742 * stub-objc.c (objc_start_method_definition): Add extra parameter.
10743
e19a18d4
NF
107442011-05-04 Nathan Froyd <froydnj@codesourcery.com>
10745
10746 * c-common.c (check_main_parameter_types): Reindent. Don't use
10747 TYPE_ARG_TYPES directly.
10748 (handle_nonnull_attribute): Likewise.
10749 (sync_resolve_params): Likewise.
10750 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
10751 to check_format_string.
10752 (handle_format_attribute): Likewise.
10753 (check_format_string): Take a function type to examine instead of
10754 a type list. Use a function_arg_iterator to step through argument
10755 types.
10756
c62c040f
RG
107572011-05-04 Richard Guenther <rguenther@suse.de>
10758
10759 * c-common.c (fix_string_type): Use size_int for index type bounds.
10760 (start_fname_decls): Do not pass NULL to build_int_cst.
10761 (c_init_attributes): Likewise.
10762 * c-lex.c (c_lex_with_flags): Likewise.
10763
c12ff9d8
JM
107642011-04-27 Jason Merrill <jason@redhat.com>
10765
10766 * c-common.c (make_tree_vector_from_list): New.
10767 * c-common.h: Declare it.
10768
304dfbe3
RG
107692011-04-26 Richard Guenther <rguenther@suse.de>
10770
10771 PR preprocessor/48248
10772 * c-ppoutput.c (maybe_print_line): Always optimize newlines
10773 for output size with -P.
10774
3c0d13bf
PC
107752011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
10776
10777 * c-common.c (struct c_common_resword): Add __underlying_type.
10778 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
10779
04695783
JM
107802011-04-20 Jim Meyering <meyering@redhat.com>
10781
10782 * c-format.c (init_dollar_format_checking): Remove useless
10783 if-before-free.
10784
0dc33c3c
NP
107852011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
10786
10787 * c-objc.h (objc_get_interface_ivars): Removed.
3c0d13bf 10788 (objc_detect_field_duplicates): New.
0dc33c3c 10789 * stub-objc.c: Likewise.
3c0d13bf 10790
c59633d9
NP
107912011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
10792
10793 * stub-objc.c (objc_declare_protocols): Renamed to
10794 objc_declare_protocol.
10795 * c-objc.h: Likewise.
3c0d13bf 10796
32dabdaf
NP
107972011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
10798
10799 * stub-objc.c (objc_declare_class): Updated argument name.
10800
81f653d6
NF
108012011-04-12 Nathan Froyd <froydnj@codesourcery.com>
10802
10803 * c-common.h (c_common_init_ts): Declare.
10804 * c-common.c (c_common_init_ts): Define.
10805
eb345401
NP
108062011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
10807
10808 * c-objc.h (objc_build_message_expr): Updated prototype.
10809 * stub-objc.c (objc_build_message_expr): Likewise.
9faeb493 10810
a358e188
MJ
108112011-04-12 Martin Jambor <mjambor@suse.cz>
10812
10813 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
10814 of cgraph_node.
10815
e6313a78
RG
108162011-04-11 Richard Guenther <rguenther@suse.de>
10817
10818 * c-common.c (complete_array_type): Build a range type of
10819 proper type.
10820
dcf0c47e
NF
108212011-04-08 Nathan Froyd <froydnj@codesourcery.com>
10822
10823 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
10824 (handle_type_generic_attribute): Likewise.
10825
1ee44b26
JM
108262011-04-07 Jason Merrill <jason@redhat.com>
10827
10828 PR c++/48450
10829 * c-common.c (c_common_truthvalue_conversion): Don't ignore
10830 conversion from C++0x scoped enum.
10831
acce4e77
JM
108322011-04-06 Joseph Myers <joseph@codesourcery.com>
10833
10834 * c-target-def.h: New file.
10835 * c-target.def: New file.
10836 * c-target.h: New file.
10837 * c-common.c (targetcm): Don't define here.
10838 * c-common.h (default_handle_c_option): Declare.
10839 * c-format.c: Include c-target.h instead of target.h.
10840 * c-opts.c: Include c-target.h instead of target.h. Explicitly
10841 include tm.h.
10842 (default_handle_c_option): Move from targhooks.c.
10843
e2eefb55
JJ
108442011-03-29 Jakub Jelinek <jakub@redhat.com>
10845
10846 PR preprocessor/48248
10847 * c-ppoutput.c (print): Add src_file field.
10848 (init_pp_output): Initialize it.
10849 (maybe_print_line): Don't optimize by adding up to 8 newlines
10850 if map->to_file and print.src_file are different file.
10851 (print_line): Update print.src_file.
10852
ba78087b
KT
108532011-03-25 Kai Tietz <ktietz@redhat.com>
10854
10855 * c-ada-spec.c (compare_comment): Use filename_cmp
10856 instead of strcmp for filename.
10857
0edf1bb2
JL
108582011-03-25 Jeff Law <law@redhat.com>
10859
adfac8df 10860 * c-common.c (def_fn_type): Add missing va_end.
0edf1bb2 10861
c7dc8804
JM
108622011-03-25 Jason Merrill <jason@redhat.com>
10863
10864 * c.opt: Add -std=c++03.
10865
d1d879b1
EB
108662011-03-22 Eric Botcazou <ebotcazou@adacore.com>
10867
10868 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
10869
3f8257db 108702011-03-17 Kai Tietz <ktietz@redhat.com>
62d784f7
KT
10871
10872 PR target/12171
5050afdf
KT
10873 * c-pretty-print.c (pp_c_specifier_qualifier_list):
10874 Display allowed attributes for function pointer types.
10875 (pp_c_attributes_display): New function to display
10876 attributes having affects_type_identity flag set to true.
10877 * c-pretty-print.h (pp_c_attributes_display): New prototype.
10878
62d784f7
KT
10879 * c-common.c (c_common_attribute_table):
10880 Add new element.
10881 (c_common_format_attribute_table): Likewise.
10882
82d37118
JM
108832011-03-18 Jason Merrill <jason@redhat.com>
10884
49a000c3
JM
10885 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
10886 * c-common.h: Don't declare it here.
10887 * c-common.c: Or define it here.
10888 * c-opts.c (c_common_handle_option): Or set it here.
10889
82d37118
JM
10890 PR c++/35315
10891 * c-common.c (handle_transparent_union_attribute): Don't
10892 make a duplicate type in C++.
10893
17bc631c
JM
108942011-03-15 Jason Merrill <jason@redhat.com>
10895
10896 * c-common.c (max_constexpr_depth): New.
10897 * c-common.h: Declare it.
10898 * c-opts.c (c_common_handle_option): Set it.
10899 * c.opt (fconstexpr-depth): New option.
10900
1b9b91a6
JM
109012011-03-11 Jason Merrill <jason@redhat.com>
10902
f231b5ff
JM
10903 * c-common.c (attribute_takes_identifier_p): Add missing const.
10904
1b9b91a6
JM
10905 PR c++/46803
10906 * c-common.c (attribute_takes_identifier_p): Assume that an
10907 unknown attribute takes an identifier.
10908
a19e4d44
NF
109092011-03-07 Nathan Froyd <froydnj@codesourcery.com>
10910
10911 PR c/47786
10912 * c-common.c (c_type_hash): Call list_length instead of iterating
10913 through DECL_CHAIN. Rename 'i' to 'n_elements'.
10914
982d62f6
JJ
109152011-02-19 Jakub Jelinek <jakub@redhat.com>
10916
10917 PR c/47809
10918 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
10919
0a256240
NP
109202011-02-17 Iain Sandoe <iains@gcc.gnu.org>
10921
10922 * c.opt (fobjc-abi-version=) New.
10923 (fobjc-nilcheck): New.
10924
ba9e6dd5
NF
109252011-02-03 Nathan Froyd <froydnj@codesourcery.com>
10926
10927 PR c++/46890
10928 * c-common.h (keyword_is_decl_specifier): Declare.
10929 * c-common.c (keyword_is_decl_specifier): Define.
10930 (keyword_is_function_specifier): New function.
10931
7273813a
JJ
109322011-01-26 Jakub Jelinek <jakub@redhat.com>
10933
10934 PR c/47473
10935 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
10936 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
10937 REAL_TYPE.
10938
908ef79b
AC
109392011-01-26 Arnaud Charlet <charlet@adacore.com>
10940
10941 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
10942
237e9384
JJ
109432011-01-26 Jakub Jelinek <jakub@redhat.com>
10944
10945 PR pch/47430
10946 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
10947 after init_c_lex if pch_file is set.
10948
47ea1edf
DK
109492011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
10950
d4dba752 10951 PR c++/43601
47ea1edf
DK
10952 * c.opt (-fkeep-inline-dllexport): New switch.
10953
2aa9c6ae
RG
109542011-01-12 Richard Guenther <rguenther@suse.de>
10955
10956 PR middle-end/32511
10957 * c-common.c (handle_weak_attribute): Warn instead of error
10958 on declaring an inline function weak.
10959
7bd11157
TT
109602011-01-05 Tom Tromey <tromey@redhat.com>
10961
10962 * c-common.h (lvalue_error): Update.
10963 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
10964 not error.
10965
0e66e494 109662010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
9faeb493 10967
b4f588c4
NP
10968 PR objc/47075
10969 * c-objc.h (objc_finish_message_expr): Added argument to
10970 prototype.
10971
f4da8dce
NF
109722010-12-22 Nathan Froyd <froydnj@codesourcery.com>
10973
10974 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
10975 Use prototype_p.
10976
46270f14
NP
109772010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
10978
10979 * c-objc.h (objc_maybe_warn_exceptions): New.
9faeb493 10980 * stub-objc.c (objc_maybe_warn_exceptions): New.
46270f14 10981
4816c593
NF
109822010-12-10 Nathan Froyd <froydnj@codesourcery.com>
10983
10984 * c-common.h (readonly_error): Declare.
10985 * c-common.c (readonly_error): Define.
10986
7a6daeb0
NF
109872010-12-09 Nathan Froyd <froydnj@codesourcery.com>
10988
10989 * c-common.h (invalid_indirection_error): Declare.
10990 * c-common.c (invalid_indirection_error): Define.
10991
892f6119
RG
109922010-12-03 Richard Guenther <rguenther@suse.de>
10993
10994 PR c/46745
10995 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
10996 (pp_c_unary_expression): Likewise.
10997 (pp_c_expression): Likewise.
10998
6c39e757
NP
109992010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
11000
11001 * c-common.h (objc_finish_function): New.
11002 (objc_non_volatilized_type): Removed.
11003 (objc_type_quals_match): Removed.
11004 * stub-objc.c (objc_finish_function): New.
11005 (objc_non_volatilized_type): Removed.
11006 (objc_type_quals_match): Removed.
9faeb493 11007
7c475d11
JM
110082010-11-30 Joseph Myers <joseph@codesourcery.com>
11009
11010 * c-common.h (parse_optimize_options): Declare.
11011 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
11012 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
11013
71f3e391
JM
110142010-11-29 Joseph Myers <joseph@codesourcery.com>
11015
11016 * c-opts.c (check_deps_environment_vars): Use getenv instead of
11017 GET_ENVIRONMENT.
11018 * c-pch.c (O_BINARY): Don't define here.
11019 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
11020
d5fabb58
JM
110212010-11-25 Joseph Myers <joseph@codesourcery.com>
11022
11023 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
11024 targetm.except_unwind_info.
11025
299404a1
JM
110262010-11-23 Joseph Myers <joseph@codesourcery.com>
11027
11028 * c-opts.c (c_common_handle_option): Pass location to
11029 set_struct_debug_option.
11030
c98cd5bf
JM
110312010-11-23 Joseph Myers <joseph@codesourcery.com>
11032
11033 * c-common.c (visibility_options): Move from ../opts.c.
11034 * c-common.h (struct visibility_flags, visibility_options):
11035 Declare here.
11036 * c-opts.c (finish_options): Rename to c_finish_options.
11037 (c_common_init): Update call to finish_options.
11038
a9546771
NP
110392010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
11040
11041 PR objc/34033
11042 * c-lex.c (lex_string): Check that each string in an Objective-C
11043 string concat sequence starts with either one or zero '@', and
11044 that there are no spurious '@' signs at the end.
11045
24a57808
JM
110462010-11-20 Joseph Myers <joseph@codesourcery.com>
11047
11048 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
11049 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
11050 HANDLE_PRAGMA_VISIBILITY.
11051 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
11052 HANDLE_PRAGMA_VISIBILITY): Don't define.
11053 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
11054
a9aa2c3a
NF
110552010-11-20 Nathan Froyd <froydnj@codesourcery.com>
11056
11057 PR c++/16189
11058 PR c++/36888
11059 PR c++/45331
11060 * c-common.h (keyword_begins_type_specifier): Declare.
11061 (keyword_is_storage_class_specifier): Declare.
11062 (keyword_is_type_qualifier): Declare.
11063 * c-common.c (keyword_begins_type_specifier): New function.
11064 (keyword_is_storage_class_specifier): New function.
11065 (keyword_is_type_qualifier): Declare.
11066
5386338c
JM
110672010-11-19 Joseph Myers <joseph@codesourcery.com>
11068
11069 PR c/46547
11070 * c-common.c (in_late_binary_op): Define.
11071 (c_common_truthvalue_conversion): Check in_late_binary_op before
11072 calling c_save_expr.
11073 * c-common.h (in_late_binary_op): Declare.
11074
69ccdddb
JM
110752010-11-19 Joseph Myers <joseph@codesourcery.com>
11076
11077 * c-opts.c (c_common_handle_option): Update calls to
11078 set_struct_debug_option.
11079
6b192a09
NP
110802010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
11081
11082 * c-common.h (objc_declare_protocols): Added additional argument.
11083 * stub-objc.c (objc_declare_protocol): Same change.
9faeb493 11084
fb52b50a
NF
110852010-11-18 Nathan Froyd <froydnj@codesourcery.com>
11086
11087 PR c/33193
11088 * c-common.h (build_real_imag_expr): Declare.
11089 * c-semantics.c (build_real_imag_expr): Define.
11090
b37421c6
JM
110912010-11-17 Joseph Myers <joseph@codesourcery.com>
11092
11093 * c-opts.c (c_common_parse_file): Take no arguments.
11094 * c-common.h (c_common_parse_file): Update prototype.
11095
07078664
JJ
110962010-11-16 Jakub Jelinek <jakub@redhat.com>
11097
11098 PR c++/46401
11099 * c-common.c (warning_candidate_p): Don't track non-const calls
11100 or STRING_CSTs.
11101
c6a13190
ILT
111022010-11-15 Ian Lance Taylor <iant@google.com>
11103
11104 * c-lex.c (init_c_lex): Set macro debug callbacks if
11105 flag_dump_go_spec is set.
11106
925e8657
NP
111072010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
11108
11109 * c-common.h (objc_build_incr_expr_for_property_ref): New.
11110 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
11111
bb0a9581
NF
111122010-11-15 Nathan Froyd <froydnj@codesourcery.com>
11113
11114 PR preprocessor/45038
11115 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
11116 dialects.
11117
c5fa0890
JM
111182010-11-12 Joseph Myers <joseph@codesourcery.com>
11119
11120 * c-common.h (c_family_lang_mask): Declare.
11121 * c-opts.c (c_family_lang_mask): Make extern.
11122 * c-pragma.c (handle_pragma_diagnostic): Use
11123 control_warning_option.
11124
a4d8c676
JM
111252010-11-12 Joseph Myers <joseph@codesourcery.com>
11126
11127 * c-common.c (parse_optimize_options): Update call to
11128 decode_options.
11129 * c-common.h (c_common_handle_option): Update prototype.
11130 * c-opts.c (c_common_handle_option): Take location_t parameter and
11131 pass it to other functions.
11132
f954bd2c
JM
111332010-11-11 Joseph Myers <joseph@codesourcery.com>
11134
11135 * c-opts.c (warning_as_error_callback): Remove.
11136 (c_common_initialize_diagnostics): Don't call
11137 register_warning_as_error_callback.
11138 (c_common_handle_option): Handle -Werror=normalized= here.
11139
d8a07487
JM
111402010-11-10 Joseph Myers <joseph@codesourcery.com>
11141
11142 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
11143 in diagnostic.
11144 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
11145 letter.
11146 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
11147 Remove trailing '.' from diagnostics.
11148 * c.opt (Wwrite-strings_: Avoid '`' in help text.
11149
d5478783
JM
111502010-11-10 Joseph Myers <joseph@codesourcery.com>
11151
11152 * c-common.c (parse_optimize_options): Pass global_dc to
11153 decode_options.
11154 * c-opts.c (c_common_handle_option): Pass &global_options to
11155 set_Wstrict_aliasing.
11156 * c.opt (v): Don't mark Common or document here.
11157
91ebb981
IS
111582010-11-06 Iain Sandoe <iains@gcc.gnu.org>
11159
11160 PR target/44981
11161 * c-format.c (format_type): New type gcc_objc_string_format_type.
11162 (valid_stringptr_type_p): New.
11163 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
9faeb493 11164 (check_format_string): Pass expected type, use
91ebb981
IS
11165 valid_stringptr_type_p (), check that the format string types are
11166 consistent with the format specification.
11167 (decode_format_attr): Warn if NSString is used outside objective-c.
11168 (format_types_orig): Add NSString.
11169 (format_name): New.
11170 (format_flags): New.
11171 (check_format_arg): Handle format strings requiring an external parser.
11172 first_target_format_type: New variable.
11173 (handle_format_attribute): Set up first_target_format_type, pass the
11174 expected format arg string type to check_format_string().
ab20d992 11175 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
91ebb981
IS
11176 * stub-objc.c (objc_string_ref_type_p): New.
11177 (objc_check_format_arg): New.
11178
bede2adc
NP
111792010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
11180
9faeb493 11181 Fixed using the Objective-C 2.0 dot-syntax with class names.
bede2adc
NP
11182 * c-common.h (objc_build_class_component_ref): New.
11183 * stub-objc.c (objc_build_class_component_ref): New.
11184
9a179d01
NP
111852010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
11186
11187 * c.opt (Wproperty-assign-default): New option.
11188
22d8d616
NP
111892010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
11190
11191 Implemented -fobjc-std=objc1 flag.
11192 * c.opt (fobjc-std=objc1): New option.
11193
2debdb4f
NP
111942010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
11195
11196 Implemented format and noreturn attributes for Objective-C methods.
11197 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
11198 attribute for Objective-C methods.
11199
ec52b111
JM
112002010-10-31 Jason Merrill <jason@redhat.com>
11201
11202 * c-common.c (conversion_warning, warn_for_collisions_1): Use
11203 EXPR_LOC_OR_HERE.
11204
46a88c12
NP
112052010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
11206
11207 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
11208 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
11209 (objc_add_property_declaration): Removed arguments for copies and
11210 ivar.
11211 (objc_build_getter_call): Renamed to
11212 objc_maybe_build_component_ref.
11213 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
11214 (objc_is_property_ref): New.
11215 * c-common.c (c_common_reswords): Removed copies and ivar.
11216 * stub-objc.c (objc_add_property_declaration): Removed arguments
11217 for copies and ivar.
11218 (objc_build_getter_call): Renamed to
11219 objc_maybe_build_component_ref.
11220 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
11221 (objc_is_property_ref): New.
9faeb493 11222
1e4bf85b
AC
112232010-10-29 Arnaud Charlet <charlet@adacore.com>
11224 Matthew Gingell <gingell@adacore.com>
11225
11226 * c-ada-spec.c (separate_class_package): New function.
11227 (pp_ada_tree_identifier): Prefix references to C++ classes with the
11228 name of their enclosing package.
11229 (print_ada_declaration): Use separate_class_package.
11230
81f0bab2
JM
112312010-10-27 Jason Merrill <jason@redhat.com>
11232
2b08f2c5
JM
11233 * c-common.c (c_common_reswords): Add __is_literal_type.
11234 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
11235
81f0bab2
JM
11236 * c-common.c (check_case_value): Remove special C++ code.
11237
200290f2
NP
112382010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
11239
11240 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
11241 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
11242 and RID_LAST_PATTR.
11243 (objc_add_property_declaration): Added additional arguments.
11244 (objc_property_attribute_kind): Removed.
11245 (objc_set_property_attr): Removed.
11246 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
11247 copy and nonatomic.
11248 * stub-objc.c (objc_add_property_declaration): Added additional
11249 arguments.
11250 (objc_set_property_attr): Removed.
9faeb493 11251
f614132b
NP
112522010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
11253
11254 * c-common.h (objc_add_property_variable): Renamed to
11255 objc_add_property_declaration. Added location argument.
11256 * stub-objc.c (objc_add_property_variable): Same change.
b1726d6c 11257
b8a18805
NP
112582010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
11259
11260 * c-common.h (objc_maybe_printable_name): New.
11261 * stub-objc.c (objc_maybe_printable_name): New.
11262
3f8257db
JJ
112632010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
11264 Andrew Pinski <pinskia@gmail.com>
30cd1c5d
AS
11265
11266 * c-common.h (c_common_mark_addressable_vec): Declare.
11267 * c-common.c (c_common_mark_addressable_vec): New function.
11268
249a82c4
NP
112692010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
11270
11271 * c-common.h (objc_set_method_type): Removed.
11272 (objc_add_method_declaration): Added boolean argument.
11273 (objc_start_method_definition): Same change.
11274 (objc_build_method_signature): Same change.
11275 * stub-objc.c (objc_set_method_type): Removed.
11276 (objc_add_method_declaration): Added boolean argument.
11277 (objc_start_method_definition): Same change.
11278 (objc_build_method_signature): Same change.
11279
977e30bc
NP
112802010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
11281
11282 * c-common.h (finish_file): Removed.
11283 (objc_write_global_declarations): New.
11284 * c-opts.c (c_common_parse_file): Do not call finish_file.
11285 * stub-objc.c (objc_write_global_declarations): New.
9faeb493 11286
da57d1b9
NP
112872010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
11288
11289 Implemented parsing @synthesize and @dynamic for
11290 Objective-C/Objective-C++.
11291 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
11292 (objc_add_synthesize_declaration): New.
11293 (objc_add_dynamic_declaration): New.
11294 * c-common.c (c_common_reswords): Add synthesize and dynamic.
11295 * stub-objc.c (objc_add_synthesize_declaration): New.
11296 (objc_add_dynamic_declaration): New.
9faeb493 11297
0069111f
MM
112982010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
11299
11300 PR target/46041
11301 * c-cppbuiltin.c (mode_has_fma): Move function here from
11302 builtins.c. Don't use the fma optab, instead just use the
11303 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
11304 using -save-temps.
11305
e426b47b
NP
113062010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
11307
11308 Merge from 'apple/trunk' branch on FSF servers.
0069111f 11309
3f8257db 11310 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
e426b47b 11311
9faeb493 11312 Radar 4330422
e426b47b
NP
11313 * c-common.h (objc_non_volatilized_type): New declaration
11314 * stub-objc.c (objc_non_volatilized_type): New stub.
11315
90fbfdc3
NP
113162010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
11317
e426b47b 11318 Merge from 'apple/trunk' branch on FSF servers.
90fbfdc3 11319
ab20d992 11320 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
90fbfdc3 11321
9faeb493 11322 Radar 4133425
90fbfdc3 11323 * c-common.h (objc_diagnose_private_ivar): New decl.
0069111f 11324 * stub-objc.c (objc_diagnose_private_ivar): New stub.
90fbfdc3 11325
c37d8c30
IS
113262010-10-17 Iain Sandoe <iains@gcc.gnu.org>
11327
11328 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
11329 * c-common.h (enum rid): Add RID_AT_PACKAGE.
11330 (objc_ivar_visibility_kind): New enum.
11331 (objc_set_visibility): Adjust prototype to use visibility enum.
0069111f 11332 * stub-objc.c (objc_set_visibility): Adjust stub to use
c37d8c30
IS
11333 visibility enum.
11334
1b1562a5
MM
113352010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
11336
11337 * c-cppbuiltin.c (builtin_define_float_constants): Emit
11338 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
11339 has the appropriate fma builtins.
11340 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
11341
668ea4b1
IS
113422010-10-14 Iain Sandoe <iains@gcc.gnu.org>
11343
1b1562a5 11344 merge from FSF apple 'trunk' branch.
3f8257db 11345 2006 Fariborz Jahanian <fjahanian@apple.com>
1b1562a5 11346
668ea4b1
IS
11347 Radars 4436866, 4505126, 4506903, 4517826
11348 * c-common.c (c_common_resword): Define @property and its attributes.
11349 * c-common.h: Define property attribute enum entries.
11350 (OBJC_IS_PATTR_KEYWORD): New.
11351 (objc_property_attribute_kind): New enum.
11352 Declare objc_set_property_attr (), objc_add_property_variable (),
11353 objc_build_getter_call () and objc_build_setter_call ().
11354 * stub-objc.c (objc_set_property_attr): New stub.
11355 (objc_add_property_variable): Likewise.
11356 (objc_build_getter_call): Likewise.
11357 (objc_build_setter_call) Likewise.
1b1562a5 11358
a1178b30
IS
113592010-10-13 Iain Sandoe <iains@gcc.gnu.org>
11360
1b1562a5 11361 merge from FSF apple 'trunk' branch.
ab20d992 11362 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
a1178b30
IS
11363
11364 Radar 3803157 (method attributes)
11365 * c-common.c (handle_deprecated_attribute): Recognize
11366 objc methods as valid declarations.
11367 * c-common.h: Declare objc_method_decl ().
1b1562a5 11368 * stub-objc.c (objc_method_decl): New stub.
a1178b30 11369
a75bfaa6
JM
113702010-10-08 Joseph Myers <joseph@codesourcery.com>
11371
11372 * c-common.c (parse_optimize_options): Call
11373 decode_cmdline_options_to_array_default_mask before
11374 decode_options. Update arguments to decode_options.
11375 * c-common.h (c_common_init_options_struct): Declare.
11376 * c-opts.c (c_common_init_options_struct): New. Split out from
11377 c_common_init_options.
11378
f05b9d93
NP
113792010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
11380
11381 Implemented fast enumeration for Objective-C.
11382 * c-common.h (objc_finish_foreach_loop): New.
11383 * stub-objc.c (objc_finish_foreach_loop): New.
11384
1ebe4b4f
JM
113852010-10-05 Joseph Myers <joseph@codesourcery.com>
11386
11387 * c-common.h (struct diagnostic_context): Don't declare here.
11388 (c_common_initialize_diagnostics): Declare using
11389 diagnostic_context typedef.
11390 * c-opts.c (c_common_handle_option): Pass global_dc to
11391 handle_generated_option.
11392
d4d24ba4
JM
113932010-10-04 Joseph Myers <joseph@codesourcery.com>
11394
11395 * c-opts.c (c_common_handle_option): Pass &global_options_set to
11396 handle_generated_option.
11397
478a1c5b
ILT
113982010-10-03 Ian Lance Taylor <iant@google.com>
11399
11400 * c.opt (-fplan9-extensions): New option.
11401
82a1c2fe
FXC
114022010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
11403
11404 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
11405 Remove.
11406 (c_cpp_builtins): Call functions from cppbuiltin.c instead
11407 of duplicating code.
11408
92902b1b
IS
114092010-09-30 Iain Sandoe <iains@gcc.gnu.org>
11410
11411 * c-common.c: Add two new entries for @optional
11412 and @required keywords.
11413
11414 merge from FSF 'apple/trunk' branch.
3f8257db 11415 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
92902b1b
IS
11416
11417 Radar 4386773
11418 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
11419 objective-c keywords.
11420 (objc_set_method_opt): New declaration.
11421 * stub-objc.c (objc_set_method_opt): New stub.
9faeb493 11422
46625112
JM
114232010-09-30 Joseph Myers <joseph@codesourcery.com>
11424
11425 * c-common.c (handle_optimize_attribute): Pass &global_options to
11426 cl_optimization_save and cl_optimization_restore.
11427 * c-opts.c (c_common_handle_option): Pass &global_options to
11428 handle_generated_option.
11429 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
11430 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
11431 &global_options to cl_optimization_restore.
11432
49b91f05
NP
114332010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
11434
11435 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
11436 Objective-C/Objective-C++ keywords.
11437
13ed556f 114382010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
a6341d57 11439
9faeb493
UB
11440 Merge from 'apple/trunk' branch on FSF servers.
11441
3f8257db 11442 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
a6341d57
NP
11443
11444 Radar 4281748
11445 * c-common.h (objc_check_global_decl): New declaration.
11446 * stub-objc.c (objc_check_global_decl): New stub.
11447
f0036cca
JM
114482010-09-29 Joseph Myers <joseph@codesourcery.com>
11449
11450 * c.opt: Don't use VarExists.
11451
e3339d0f
JM
114522010-09-29 Joseph Myers <joseph@codesourcery.com>
11453
11454 * c-common.c (c_cpp_error): Update names of diagnostic_context
11455 members.
11456 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
11457 cl_optimization members.
11458 * c-opts.c (warning_as_error_callback, c_common_handle_option,
11459 sanitize_cpp_opts, finish_options): Update names of cpp_options
11460 members.
11461
1973201f
NP
114622010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
11463
11464 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
11465 (objc_is_reserved_word): Removed.
11466 * c-common.c: Updated comments.
11467 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
11468 objc_is_reserved_word.
11469 * stub-objc.c (objc_is_reserved_word): Removed.
11470
f7e71da5
IS
114712010-09-28 Iain Sandoe <iains@gcc.gnu.org>
11472
9faeb493 11473 * c-common.h (objc_add_method_declaration): Adjust prototype to
f7e71da5
IS
11474 include attributes.
11475 (objc_start_method_definition): Likewise.
11476 (objc_build_keyword_decl): Likewise.
11477 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
11478 (objc_start_method_definition): Likewise.
11479 (objc_build_keyword_decl): Likewise.
11480
c165dca7
IS
114812010-09-28 Iain Sandoe <iains@gcc.gnu.org>
11482
11483 * c-common.h (objc_start_class_interface): Adjust prototype.
11484 (objc_start_category_interface): Likewise.
11485 (objc_start_protocol): Likewise.
11486 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
11487 (objc_start_class_interface): Likewise.
11488 (objc_start_category_interface): Likewise.
11489
7458026b
ILT
114902010-09-27 Ian Lance Taylor <iant@google.com>
11491
11492 * c-common.c (c_common_attribute_table): Add no_split_stack.
11493 (handle_no_split_stack_attribute): New static function.
11494
b581b85b
NP
114952010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
11496
9faeb493 11497 Merge from 'apple/trunk' branch on FSF servers.
b581b85b 11498
3f8257db 11499 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
b581b85b 11500
9faeb493 11501 Radar 4229905
b581b85b
NP
11502 * c-common.h (objc_have_common_type): New declaration.
11503 * stub-objc.c (objc_have_common_type): New stub.
11504
11505 2005-06-22 Ziemowit Laski <zlaski@apple.com>
11506
11507 Radar 4154928
11508 * c-common.h (objc_common_type): New prototype.
9faeb493 11509 * stub-objc.c (objc_common_type): New stub.
b581b85b 11510
46a4da10
JH
115112010-09-24 Jan Hubicka <jh@suse.cz>
11512
11513 * c-common.c (handle_leaf_attribute): New function.
11514 (struct attribute_spec c_common_att): Add leaf.
11515
e200444e
JM
115162010-09-22 Joseph Myers <joseph@codesourcery.com>
11517
11518 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
11519 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
11520 -dump, -dump=, -imacros, -imacros=, -include, -include=,
11521 -include-barrier, -include-directory, -include-directory=,
11522 -include-directory-after, -include-directory-after=,
11523 -include-prefix, -include-prefix=, -include-with-prefix,
11524 -include-with-prefix=, -include-with-prefix-after,
11525 -include-with-prefix-after=, -include-with-prefix-before,
11526 -include-with-prefix-before=, -no-integrated-cpp,
11527 -no-line-commands, -no-standard-includes, -no-warnings, -output,
11528 -output=, -pedantic, -pedantic-errors, -preprocess,
11529 -print-missing-file-dependencies, -trace-includes, -traditional,
11530 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
11531 -user-dependencies, -verbose, -write-dependencies,
11532 -write-user-dependencies, no-integrated-cpp, traditional): New.
11533
29a80ea6
NP
115342010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
11535
11536 PR objc/23710
ac1fc2fc
NP
11537 * c-common.h (objc_start_method_definition): Return bool instead
11538 of void.
11539 * stub-objc.c (objc_start_method_definition): Return bool instead
11540 of void.
11541
115422010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
11543
11544 PR objc/25965
11545 * c-common.h (objc_get_interface_ivars): New declaration.
11546 * stub-objc.c (objc_get_interface_ivars): New stub.
29a80ea6 11547
de621752
ILT
115482010-09-15 Ian Lance Taylor <iant@google.com>
11549
11550 * c-common.c (parse_optimize_options): Do not capitalize warning
06730c5d 11551 messages. Remove period at end of warning message.
de621752 11552
ba885ec5
NS
115532010-09-09 Nathan Sidwell <nathan@codesourcery.com>
11554
11555 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
11556 (handle_alias_attribute): ... here.
11557 (handle_ifunc_attribute): New.
11558
c5ee1358
MM
115592010-09-06 Mark Mitchell <mark@codesourcery.com>
11560
11561 * c-common.h (do_warn_double_promotion): Declare.
11562 * c-common.c (do_warn_double_promotion): Define.
11563
0a0b3574
MM
115642010-09-05 Mark Mitchell <mark@codesourcery.com>
11565
11566 * c.opt (Wdouble-promotion): New.
11567
d1779886
JM
115682010-09-02 Joseph Myers <joseph@codesourcery.com>
11569
11570 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
11571 fvtable-thunks, fxref): Mark no longer supported in help text.
11572
2d2bd949
JM
115732010-09-02 Joseph Myers <joseph@codesourcery.com>
11574
11575 * c.opt (Wimport, fall-virtual, falt-external-templates,
11576 fdefault-inline, fenum-int-equiv, fexternal-templates,
11577 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
11578 fname-mangling-version-, fnew-abi, fnonnull-objects,
11579 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
11580 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
11581 applicable.
11582 (fhandle-exceptions): Mark with Alias and Warn.
11583 * c-opts.c (c_common_handle_option): Don't handle options marked
11584 as ignored.
11585
5de8299c
JM
115862010-09-02 Joseph Myers <joseph@codesourcery.com>
11587
11588 * c.opt (Wcomments, Werror-implicit-function-declaration,
11589 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
11590 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
11591 aliases.
11592 * c-common.c (option_codes): Use OPT_Wcomment instead of
11593 OPT_Wcomments.
11594 * c-opts.c (warning_as_error_callback, c_common_handle_option):
11595 Don't handle options marked as aliases.
11596
0ceb0201
RG
115972010-08-25 Richard Guenther <rguenther@suse.de>
11598
11599 * c-common.c (c_common_get_alias_set): Remove special
11600 handling for pointers.
11601
ac47786e
NF
116022010-08-20 Nathan Froyd <froydnj@codesourcery.com>
11603
11604 * c-common.c: Use FOR_EACH_VEC_ELT.
11605 * c-gimplify.c: Likewise.
11606 * c-pragma.c: Likewise.
11607
c878765b
JM
116082010-08-16 Joseph Myers <joseph@codesourcery.com>
11609
11610 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
11611 RejectDriver.
11612 (MMDX): Change back to MMD. Mark NoDriverArg instead of
11613 RejectDriver.
11614 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
11615 instead of OPT_MDX and OPT_MMDX.
11616
603349bf
JM
116172010-08-16 Joseph Myers <joseph@codesourcery.com>
11618
11619 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
11620
644fa7ac
JM
116212010-08-12 Joseph Myers <joseph@codesourcery.com>
11622
11623 * c.opt (MD, MMD): Change to MDX and MMDX.
11624 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
11625
481e1176
JM
116262010-08-11 Joseph Myers <joseph@codesourcery.com>
11627
11628 * c-opts.c (c_common_handle_option): Call handle_generated_option
11629 instead of handle_option.
11630
ac8dc9f7
NF
116312010-08-08 Nathan Froyd <froydnj@codesourcery.com>
11632
11633 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
11634 (maybe_apply_renaming_pragma): Delete unneeded declarations.
11635
4f8c876d
NF
116362010-08-08 Nathan Froyd <froydnj@codesourcery.com>
11637
11638 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
11639 (pending_redefine_extname): Change type to a VEC.
11640 (add_to_renaming_pragma_list): Update for new type of
11641 pending_redefine_extname.
ac8dc9f7 11642 (maybe_apply_renaming_pragma): Likewise.
4f8c876d 11643
3b0c690e
AC
116442010-08-04 Arnaud Charlet <charlet@adacore.com>
11645
11646 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
11647 visited.
11648 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
11649 decide whether a type has already been declared/seen.
11650 Do not go to the original type.
11651 (dump_nested_types): New parameter forward.
11652 Generate forward declaration if needed and mark type as visited.
11653 (print_ada_declaration): Call dump_nested_types if not already done.
11654 Mark types as visited.
11655
1890bccc
JM
116562010-08-03 Joseph Myers <joseph@codesourcery.com>
11657
11658 * c.opt (-print-pch-checksum): Remove option.
11659 * c-opts.c (c_common_handle_option): Don't handle
11660 OPT_print_pch_checksum.
11661
5f20c657
JM
116622010-07-27 Joseph Myers <joseph@codesourcery.com>
11663
11664 * c-common.h (c_common_handle_option): Update prototype and return
11665 value type.
11666 * c-opts.c (c_common_handle_option): Update prototype and return
11667 value type. Update calls to handle_option and
11668 enable_warning_as_error.
11669
f551f80c
JJ
116702010-07-27 Jakub Jelinek <jakub@redhat.com>
11671
11672 PR c/45079
11673 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
11674
61ff2bdc
JM
116752010-07-27 Joseph Myers <joseph@codesourcery.com>
11676
11677 * c-common.h (c_common_missing_argument): Remove.
11678 * c-opts.c (c_common_missing_argument): Remove.
11679 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
11680 idirafter, imacros, include, isysroot, isystem, iquote): Add
11681 MissingArgError.
11682 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
11683
7a9bf9a4
JM
116842010-07-27 Joseph Myers <joseph@codesourcery.com>
11685
11686 * c-common.h (c_common_option_lang_mask,
11687 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
11688 New.
11689 (c_common_init_options): Update prototype.
11690 * c-opts.c (c_common_option_lang_mask): New.
11691 (c_common_initialize_diagnostics): Split out of
11692 c_common_init_options.
11693 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
11694 New.
11695 (c_common_init_options): Update prototype. Use decoded options in
11696 search for -lang-asm.
11697
910ad8de
NF
116982010-07-15 Nathan Froyd <froydnj@codesourcery.com>
11699
11700 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
11701 * c-format.c: Likewise.
11702
718f9c0f
MLI
117032010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
11704
11705 * c-common.h: Include diagnostic-core.h. Error if already
11706 included.
11707 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
11708
4d451982
MLI
117092010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
11710
adfac8df 11711 * c-common.c (IN_GCC_FRONTEND): Do not undef.
4d451982
MLI
11712 Do not include expr.h
11713 (vector_mode_valid_p): Move here.
11714
119fe915
SB
117152010-06-21 DJ Delorie <dj@redhat.com>
11716
11717 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
11718 allow these pragmas anywhere.
11719
117202010-06-14 Jakub Jelinek <jakub@redhat.com>
11721
11722 PR bootstrap/44509
11723 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
11724 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
11725 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
11726 ggc_strdup instead of xstrdup.
11727
117282010-06-10 Jakub Jelinek <jakub@redhat.com>
11729
11730 * c-cppbuiltin.c: Include cpp-id-data.h.
11731 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
11732 (lazy_hex_fp_value): New function.
11733 (builtin_define_with_hex_fp_value): Provide definitions lazily.
11734
6662d794
MLI
117352010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
11736
11737 * c-gimplify.c: Do not include tree-flow.h
11738
38f8b050
JR
117392010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
11740
11741 PR other/44034
11742 * c-common.c: Rename targetm member:
11743 targetm.enum_va_list -> targetm.enum_va_list_p
11744
9589f23e
AS
117452010-06-28 Anatoly Sokolov <aesok@post.ru>
11746
11747 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
11748
3b06d379
SB
117492010-06-28 Steven Bosscher <steven@gcc.gnu.org>
11750
11751 * c-cppbuiltin.c: Do not include except.h.
11752
d166d4c3
AK
117532010-06-24 Andi Kleen <ak@linux.intel.com>
11754
9faeb493
UB
11755 * c-common.c (warn_for_omitted_condop): New.
11756 * c-common.h (warn_for_omitted_condop): Add prototype.
d166d4c3 11757
70cb8be6
JM
117582010-06-21 Joseph Myers <joseph@codesourcery.com>
11759
11760 * c.opt (lang-objc): Remove.
11761 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
11762
a4c97feb
JR
117632010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
11764
11765 * c-opts.c: Include "tm_p.h".
11766
6e2f1956
JM
117672010-06-20 Joseph Myers <joseph@codesourcery.com>
11768
11769 * c-common.c (parse_optimize_options): Update call to
11770 decode_options.
11771
bc87224e
NF
117722010-06-18 Nathan Froyd <froydnj@codesourcery.com>
11773
11774 * c-common.c (record_types_used_by_current_var_decl): Adjust for
11775 new type of types_used_by_cur_var_decl.
11776
b49cf425
JR
117772010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
11778
11779 PR bootstrap/44512
11780 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
11781 for C++ standard compliance.
11782
59f9c2ed
JM
117832010-06-16 Jason Merrill <jason@redhat.com>
11784
11785 * c.opt: Add -Wnoexcept.
11786
33766b66
RG
117872010-06-16 Richard Guenther <rguenther@suse.de>
11788
11789 PR c/44555
11790 * c-common.c (c_common_truthvalue_conversion): Remove
11791 premature and wrong optimization concering ADDR_EXPRs.
11792
eff7e30c
AC
117932010-06-15 Arnaud Charlet <charlet@adacore.com>
11794
11795 * c-ada-spec.c (dump_sloc): Remove column info.
11796 (is_simple_enum): New function.
11797 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
11798 enum types when relevant.
11799
6312e84d
MLI
118002010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
11801
9faeb493 11802 * c-common.c (conversion_warning): Warn at expression
6312e84d
MLI
11803 location.
11804
1cb42611
JM
118052010-06-10 Joseph Myers <joseph@codesourcery.com>
11806
11807 * c-opts.c (c_common_handle_option): Don't handle
11808 OPT_fshow_column.
11809
a9429e29
LB
118102010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
11811
11812 * c-pragma.c (push_alignment): Use typed GC allocation.
11813 (handle_pragma_push_options): Likewise.
11814
11815 * c-common.c (parse_optimize_options): Likewise.
11816
11817 * c-common.h (struct sorted_fields_type): Add variable_size GTY
11818 option.
11819
5498f011
JM
118202010-06-07 Joseph Myers <joseph@codesourcery.com>
11821
11822 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
11823 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
11824 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
11825 flag_signed_bitfields, warn_strict_null_sentinel,
11826 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
11827 flag_gen_declaration, flag_no_gnu_keywords,
11828 flag_implement_inlines, flag_implicit_templates,
11829 flag_implicit_inline_templates, flag_optional_diags,
11830 flag_elide_constructors, flag_default_inline, flag_rtti,
11831 flag_conserve_space, flag_access_control, flag_check_new,
11832 flag_new_for_scope, flag_weak, flag_working_directory,
11833 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
11834 flag_enforce_eh_specs, flag_threadsafe_statics,
11835 flag_pretty_templates): Remove.
11836 * c-common.h (flag_preprocess_only, flag_nil_receivers,
11837 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
11838 flag_replace_objc_classes, flag_undef, flag_no_builtin,
11839 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
11840 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
11841 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
11842 flag_no_gnu_keywords, flag_implement_inlines,
11843 flag_implicit_templates, flag_implicit_inline_templates,
11844 flag_optional_diags, flag_elide_constructors, flag_default_inline,
11845 flag_rtti, flag_conserve_space, flag_access_control,
11846 flag_check_new, flag_new_for_scope, flag_weak,
11847 flag_working_directory, flag_use_cxa_atexit,
11848 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
11849 flag_threadsafe_statics, flag_pretty_templates,
11850 warn_strict_null_sentinel): Remove.
11851 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
11852 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
11853 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
11854 fimplicit-inline-templates, fimplicit-templates,
11855 flax-vector-conversions, fms-extensions, fnil-receivers,
11856 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
11857 frtti, fshort-double, fshort-enums, fshort-wchar,
11858 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
11859 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
11860 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
11861 gen-decls, undef): Use Var.
11862 (fdefault-inline, foptional-diags): Document as doing nothing.
11863 * c-opts.c (c_common_handle_option): Remove cases for options now
11864 using Var. Mark ignored options as such.
11865
39dabefd
SB
118662010-06-05 Steven Bosscher <steven@gcc.gnu.org>
11867
9faeb493 11868 * c-common.c: Moved to here from parent directory.
39dabefd
SB
11869 * c-common.def: Likewise.
11870 * c-common.h: Likewise.
11871 * c-cppbuiltin.c: Likewise.
11872 * c-dump.c: Likewise.
11873 * c-format.c: Likewise.
11874 * c-format.h : Likewise.
11875 * c-gimplify.c: Likewise.
11876 * c-lex.c: Likewise.
11877 * c-omp.c: Likewise.
11878 * c.opt: Likewise.
11879 * c-opts.c: Likewise.
11880 * c-pch.c: Likewise.
11881 * c-ppoutput.c: Likewise.
11882 * c-pragma.c: Likewise.
11883 * c-pragma.h: Likewise.
11884 * c-pretty-print.c: Likewise.
11885 * c-pretty-print.h: Likewise.
11886 * c-semantics.c: Likewise.
11887 * stub-objc.c: Likewise.
11888
11889 * c-common.c: Include gt-c-family-c-common.h.
11890 * c-pragma.c: Include gt-c-family-c-pragma.h.
11891\f
c48514be 11892Copyright (C) 2010-2021 Free Software Foundation, Inc.
39dabefd
SB
11893
11894Copying and distribution of this file, with or without modification,
11895are permitted in any medium without royalty provided the copyright
11896notice and this notice are preserved.