]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/c-family/ChangeLog
Daily bump.
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
1 2022-01-17 Martin Liska <mliska@suse.cz>
2
3 * c-ada-spec.cc: Rename .c names to .cc.
4 * c-ada-spec.h: Likewise.
5 * c-common.cc (c_build_vec_convert): Likewise.
6 (warning_candidate_p): Likewise.
7 * c-common.h (enum rid): Likewise.
8 (build_real_imag_expr): Likewise.
9 (finish_label_address_expr): Likewise.
10 (c_get_substring_location): Likewise.
11 (c_build_bind_expr): Likewise.
12 (conflict_marker_get_final_tok_kind): Likewise.
13 (c_parse_error): Likewise.
14 (check_missing_format_attribute): Likewise.
15 (invalid_array_size_error): Likewise.
16 (warn_for_multistatement_macros): Likewise.
17 (build_attr_access_from_parms): Likewise.
18 * c-cppbuiltin.cc (c_cpp_builtins): Likewise.
19 * c-format.cc: Likewise.
20 * c-gimplify.cc (c_gimplify_expr): Likewise.
21 * c-indentation.h: Likewise.
22 * c-objc.h (objc_prop_attr_kind_for_rid): Likewise.
23 * c-omp.cc (c_omp_predetermined_mapping): Likewise.
24 * c-opts.cc (c_common_post_options): Likewise.
25 (set_std_cxx23): Likewise.
26 * c-pragma.cc (handle_pragma_redefine_extname): Likewise.
27 * c-pretty-print.h: Likewise.
28
29 2022-01-17 Martin Liska <mliska@suse.cz>
30
31 * c-ada-spec.c: Moved to...
32 * c-ada-spec.cc: ...here.
33 * c-attribs.c: Moved to...
34 * c-attribs.cc: ...here.
35 * c-common.c: Moved to...
36 * c-common.cc: ...here.
37 * c-cppbuiltin.c: Moved to...
38 * c-cppbuiltin.cc: ...here.
39 * c-dump.c: Moved to...
40 * c-dump.cc: ...here.
41 * c-format.c: Moved to...
42 * c-format.cc: ...here.
43 * c-gimplify.c: Moved to...
44 * c-gimplify.cc: ...here.
45 * c-indentation.c: Moved to...
46 * c-indentation.cc: ...here.
47 * c-lex.c: Moved to...
48 * c-lex.cc: ...here.
49 * c-omp.c: Moved to...
50 * c-omp.cc: ...here.
51 * c-opts.c: Moved to...
52 * c-opts.cc: ...here.
53 * c-pch.c: Moved to...
54 * c-pch.cc: ...here.
55 * c-ppoutput.c: Moved to...
56 * c-ppoutput.cc: ...here.
57 * c-pragma.c: Moved to...
58 * c-pragma.cc: ...here.
59 * c-pretty-print.c: Moved to...
60 * c-pretty-print.cc: ...here.
61 * c-semantics.c: Moved to...
62 * c-semantics.cc: ...here.
63 * c-ubsan.c: Moved to...
64 * c-ubsan.cc: ...here.
65 * c-warn.c: Moved to...
66 * c-warn.cc: ...here.
67 * cppspec.c: Moved to...
68 * cppspec.cc: ...here.
69 * stub-objc.c: Moved to...
70 * stub-objc.cc: ...here.
71
72 2022-01-15 Martin Sebor <msebor@redhat.com>
73
74 PR c/63272
75 * c.opt (-Wdangling-pointer): New option.
76
77 2022-01-15 Martin Sebor <msebor@redhat.com>
78
79 PR tree-optimization/80532
80 * c.opt (-Wuse-after-free): New options.
81
82 2022-01-14 David Malcolm <dmalcolm@redhat.com>
83
84 * c-attribs.c (c_common_attribute_table): Add "tainted_args".
85 (handle_tainted_args_attribute): New.
86
87 2022-01-13 Anthony Sharp <anthonysharp15@gmail.com>
88 Jason Merrill <jason@redhat.com>
89
90 PR c++/70417
91 * c.opt: Added -Wmissing-template-keyword.
92
93 2022-01-13 Richard Biener <rguenther@suse.de>
94
95 PR c/104002
96 * c-common.c (c_common_mark_addressable_vec): Handle TARGET_EXPR.
97
98 2022-01-12 Martin Liska <mliska@suse.cz>
99
100 PR target/103804
101 * c-attribs.c (handle_optimize_attribute): Do not call
102 cl_optimization_compare if we seen an error.
103
104 2022-01-11 Jakub Jelinek <jakub@redhat.com>
105
106 PR c/101537
107 PR c/103881
108 * c-warn.c (conversion_warning): Handle BIT_AND_EXPR, BIT_IOR_EXPR
109 and BIT_XOR_EXPR.
110
111 2022-01-10 Richard Biener <rguenther@suse.de>
112
113 PR middle-end/101530
114 * c-common.c (c_build_shufflevector): Wrap the BIT_FIELD_REF
115 in a TARGET_EXPR to force a temporary.
116
117 2022-01-06 Marek Polacek <polacek@redhat.com>
118
119 PR c++/103758
120 * c-pragma.c (handle_pragma_scalar_storage_order): Use %< %> in
121 diagnostic messages.
122 (handle_pragma_diagnostic): Likewise.
123
124 2022-01-03 Marek Polacek <polacek@redhat.com>
125
126 PR c++/103758
127 * c-format.c (check_tokens): Accept "decl-specifier*".
128
129 2022-01-03 Jakub Jelinek <jakub@redhat.com>
130
131 PR c++/103600
132 * c-attribs.c (handle_non_overlapping_attribute): New function.
133 (c_common_attribute_table): Add "non overlapping" attribute.
134
135 2021-12-30 Jakub Jelinek <jakub@redhat.com>
136
137 PR c++/103012
138 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Perform
139 cpp_define_unused/cpp_undef calls with forced token locations
140 BUILTINS_LOCATION.
141
142 2021-12-27 Patrick Palka <ppalka@redhat.com>
143
144 PR c++/103700
145 * c-common.c (pointer_int_sum): When quiet, return
146 error_mark_node for an incomplete pointed-to type and don't
147 call size_in_bytes_loc.
148
149 2021-12-17 Jason Merrill <jason@redhat.com>
150
151 PR c++/103681
152 * c-opts.c (c_common_post_options): Update defaults.
153
154 2021-12-16 Martin Liska <mliska@suse.cz>
155
156 PR target/103709
157 * c-pragma.c (handle_pragma_pop_options): Do not check
158 global options modification when an error is seen in parsing
159 of options (pragmas or attributes).
160
161 2021-12-12 Jonathan Wakely <jwakely@redhat.com>
162
163 * known-headers.cc: Define INCLUDE_MEMORY instead of
164 INCLUDE_UNIQUE_PTR.
165 * name-hint.h: Likewise.
166 (class name_hint): Use std::unique_ptr instead of gnu::unique_ptr.
167
168 2021-12-09 Jakub Jelinek <jakub@redhat.com>
169
170 PR pch/71934
171 * c-pch.c (c_common_no_more_pch): Pass a temporary void * var
172 with NULL value instead of NULL to host_hooks.gt_pch_use_address.
173
174 2021-12-03 Jakub Jelinek <jakub@redhat.com>
175
176 PR pch/71934
177 * c-pch.c (struct c_pch_validity): Remove pch_init member.
178 (pch_init): Don't initialize v.pch_init.
179 (c_common_valid_pch): Don't warn and punt if .text addresses change.
180
181 2021-12-01 Jason Merrill <jason@redhat.com>
182
183 PR c++/103310
184 * c.opt: Add -fconstexpr-fp-except.
185
186 2021-11-29 Richard Biener <rguenther@suse.de>
187
188 * c-format.c (check_format_string): Remove spurious
189 gcc_unreachable.
190
191 2021-11-29 Richard Biener <rguenther@suse.de>
192
193 * c-opts.c (c_common_post_options): Remove unreachable return.
194 * c-pragma.c (handle_pragma_target): Likewise.
195 (handle_pragma_optimize): Likewise.
196
197 2021-11-25 Jakub Jelinek <jakub@redhat.com>
198
199 PR c++/102611
200 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
201 default for C++23 regardless of warn_deprecated.
202 * c-cppbuiltin.c (c_cpp_builtins): Predefine
203 __cpp_multidimensional_subscript=202110L for C++23.
204
205 2021-11-23 Martin Sebor <msebor@redhat.com>
206
207 PR middle-end/88232
208 * c.opt: Add -Winfinite-recursion.
209
210 2021-11-19 Martin Sebor <msebor@redhat.com>
211
212 PR c++/33925
213 PR c/102867
214 * c-common.c (decl_with_nonnull_addr_p): Call maybe_nonzero_address
215 and improve handling tof defined symbols.
216
217 2021-11-19 Martin Liska <mliska@suse.cz>
218
219 Revert:
220 2021-11-18 Martin Liska <mliska@suse.cz>
221
222 * c-gimplify.c (genericize_c_loop): Use option directly.
223
224 2021-11-18 Matthias Kretz <m.kretz@gsi.de>
225
226 * c-common.c (c_common_reswords): Add __builtin_assoc_barrier.
227 * c-common.h (enum rid): Add RID_BUILTIN_ASSOC_BARRIER.
228
229 2021-11-18 Martin Liska <mliska@suse.cz>
230
231 * c-gimplify.c (genericize_c_loop): Use option directly.
232
233 2021-11-17 Martin Uecker <uecker@gcc.gnu.org>
234
235 PR c/91038
236 PR c/29970
237 * c-common.c (pointer_int_sum): Make sure pointer expressions
238 are evaluated first when the size expression depends on for
239 variably-modified types.
240
241 2021-11-17 Marek Polacek <polacek@redhat.com>
242
243 PR preprocessor/103026
244 * c.opt (Wbidi-chars, Wbidi-chars=): New option.
245
246 2021-11-16 Jason Merrill <jason@redhat.com>
247
248 * c-common.c (release_tree_vector): Only cache vecs smaller than
249 16 elements.
250
251 2021-11-15 Jason Merrill <jason@redhat.com>
252
253 * c.opt: Add -fimplicit-constexpr.
254 * c-cppbuiltin.c: Define __cpp_implicit_constexpr.
255 * c-opts.c (c_common_post_options): Disable below C++14.
256
257 2021-11-15 Jakub Jelinek <jakub@redhat.com>
258
259 * c-omp.c (c_omp_split_clauses) <case OMP_CLAUSE_THREAD_LIMIT>:
260 Duplicate to both OMP_TARGET and OMP_TEAMS.
261
262 2021-11-10 Marek Polacek <polacek@redhat.com>
263
264 PR c++/101940
265 * c-pragma.c (handle_pragma_diagnostic): Handle #pragma GCC diagnostic
266 ignored_attributes.
267
268 2021-11-09 David Malcolm <dmalcolm@redhat.com>
269
270 * c-pragma.c (GCC_BAD_AT): New macro.
271 (GCC_BAD2_AT): New macro.
272 (handle_pragma_pack): Use the location of the pertinent token when
273 issuing diagnostics about invalid constants/actions, and trailing
274 junk.
275 (handle_pragma_target): Likewise for non-string "GCC option".
276 (handle_pragma_message): Likewise for trailing junk.
277
278 2021-11-03 Joseph Myers <joseph@codesourcery.com>
279
280 PR c/103031
281 * c-common.c (convert_and_check): Add argument init_const. Call
282 convert_init if init_const.
283 * c-common.h (convert_and_check): Update prototype.
284 (convert_init): New prototype.
285
286 2021-11-01 David Malcolm <dmalcolm@redhat.com>
287
288 * c-lex.c (c_lex_with_flags): When complaining about non-printable
289 CPP_OTHER tokens, set the "escape on output" flag.
290
291 2021-10-27 Jakub Jelinek <jakub@redhat.com>
292
293 * c-omp.c (c_omp_check_loop_iv_r): Don't clear 3rd bit for
294 POINTER_PLUS_EXPR.
295 (c_omp_check_nonrect_loop_iv): Handle POINTER_PLUS_EXPR.
296 (c_omp_check_loop_iv): Set kind even if the iterator is non-integral.
297
298 2021-10-27 Jakub Jelinek <jakub@redhat.com>
299
300 PR c++/102854
301 * c-common.h (c_omp_check_loop_iv_exprs): Add enum tree_code argument.
302 * c-omp.c (c_omp_check_loop_iv_r): For trees other than decls,
303 TREE_VEC, PLUS_EXPR, MINUS_EXPR, MULT_EXPR, POINTER_PLUS_EXPR or
304 conversions temporarily clear the 3rd bit from d->kind while walking
305 subtrees.
306 (c_omp_check_loop_iv_exprs): Add CODE argument. Or in 4 into data.kind
307 if possibly non-rectangular.
308
309 2021-10-21 Jakub Jelinek <jakub@redhat.com>
310
311 PR middle-end/64888
312 * c-omp.c (c_omp_predefined_variable): Return true also for
313 ubsan_create_data created artificial variables.
314
315 2021-10-14 Joseph Myers <joseph@codesourcery.com>
316
317 * c-format.c (printf_length_specs, scanf_length_specs)
318 (print_char_table, scan_char_table): Support DFP formats for C2X.
319 * c-format.h (TEX_D32, TEX_D64, TEX_D128): Remove.
320 (T2X_D32, T2X_D64, T2X_D128): New macros.
321
322 2021-10-14 Kwok Cheung Yeung <kcy@codesourcery.com>
323
324 * c-omp.c (c_omp_check_context_selector): Rename to
325 omp_check_context_selector and move to omp-general.c.
326 (c_omp_mark_declare_variant): Rename to omp_mark_declare_variant and
327 move to omp-general.c.
328
329 2021-10-12 Joseph Myers <joseph@codesourcery.com>
330
331 * c-format.c (print_char_table): Add %b and %B formats.
332 (scan_char_table): Add %b format.
333 * c-format.h (T2X_UI, T2X_UL, T2X_ULL, T2X_US, T2X_UC, T2X_ST)
334 (T2X_UPD, T2X_UIM): New macros.
335
336 2021-10-12 Jakub Jelinek <jakub@redhat.com>
337
338 * c-omp.c (c_finish_omp_atomic): Use
339 clear_padding_type_may_have_padding_p.
340
341 2021-10-08 Martin Liska <mliska@suse.cz>
342
343 * c-opts.c (c_common_post_options): Use new macro
344 OPTION_SET_P.
345
346 2021-10-07 Martin Liska <mliska@suse.cz>
347
348 * c-common.c (parse_optimize_options): Make
349 save_opt_decoded_options a pointer type.
350
351 2021-10-06 Jakub Jelinek <jakub@redhat.com>
352
353 PR tree-optimization/102571
354 * c-omp.c (c_finish_omp_atomic): Optimize the case where type has
355 padding, but the non-padding bits are contiguous set of bytes
356 by adjusting the memcmp call arguments instead of emitting
357 __builtin_clear_padding and then comparing all the type's bytes.
358
359 2021-10-06 Jakub Jelinek <jakub@redhat.com>
360
361 PR c++/102612
362 * c-cppbuiltin.c (c_cpp_builtins): For -std=c++23 predefine
363 __cpp_constexpr to 202110L rather than 201907L.
364
365 2021-10-04 Marek Polacek <polacek@redhat.com>
366
367 PR c++/97573
368 * c-common.h (do_warn_array_compare): Declare.
369 * c-warn.c (do_warn_array_compare): New.
370 * c.opt (Warray-compare): New option.
371
372 2021-10-02 Iain Sandoe <iain@sandoe.co.uk>
373
374 * c-format.c: Remove a test of TARGET_FORMAT_TYPES with
375 NULL, this is not needed.
376
377 2021-10-01 Martin Sebor <msebor@redhat.com>
378
379 PR c/102103
380 * c-common.c (decl_with_nonnull_addr_p): Handle members.
381 Check and perform warning suppression.
382 (c_common_truthvalue_conversion): Enhance warning suppression.
383
384 2021-10-01 Martin Liska <mliska@suse.cz>
385
386 PR target/102552
387 * c-common.c (parse_optimize_options): decoded_options[0] is
388 used for program name, so merged_decoded_options should also
389 respect that.
390
391 2021-10-01 Jakub Jelinek <jakub@redhat.com>
392 Richard Biener <rguenther@suse.de>
393
394 PR sanitizer/102515
395 * c-ubsan.c (ubsan_instrument_division): Check the right
396 flag_sanitize_recover bit, depending on which sanitization
397 is done. Sanitize INT_MIN / -1 under SANITIZE_SI_OVERFLOW
398 rather than SANITIZE_DIVIDE. If both SANITIZE_SI_OVERFLOW
399 and SANITIZE_DIVIDE is enabled, neither check is known
400 to be false and flag_sanitize_recover bits for those two
401 aren't the same, emit both __ubsan_handle_divrem_overflow
402 and __ubsan_handle_divrem_overflow_abort calls.
403
404 2021-10-01 Martin Liska <mliska@suse.cz>
405
406 * c-common.c (parse_optimize_options): Combine optimize
407 options with what was provided on the command line.
408
409 2021-10-01 Jakub Jelinek <jakub@redhat.com>
410
411 * c-omp.c (c_omp_split_clauses): Also copy
412 OMP_CLAUSE_ORDER_REPRODUCIBLE.
413
414 2021-09-27 Martin Liska <mliska@suse.cz>
415
416 * c-opts.c (c_common_init_options_struct): Set also
417 x_flag_default_complex_method.
418
419 2021-09-22 Jakub Jelinek <jakub@redhat.com>
420
421 * c-omp.c (c_omp_split_clauses): Copy over OMP_CLAUSE_ALLOCATE_ALIGN.
422
423 2021-09-20 Matthias Kretz <m.kretz@gsi.de>
424
425 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define or
426 undefine __RECIPROCAL_MATH__, __NO_SIGNED_ZEROS__,
427 __NO_TRAPPING_MATH__, __ASSOCIATIVE_MATH__, and
428 __ROUNDING_MATH__ according to the new optimization flags.
429
430 2021-09-18 Jakub Jelinek <jakub@redhat.com>
431
432 * c-omp.c (c_omp_split_clauses): Split order clause also to
433 distribute construct. Copy over OMP_CLAUSE_ORDER_UNCONSTRAINED.
434
435 2021-09-17 Jakub Jelinek <jakub@redhat.com>
436
437 * c-omp.c (c_finish_omp_atomic): Avoid creating
438 TARGET_EXPR if test is true, use create_tmp_var_raw instead of
439 create_tmp_var and add a zero initializer to TARGET_EXPRs that
440 had NULL initializer. When omitting operands after v = x,
441 use type of v rather than type of x. Fix type of vtmp
442 TARGET_EXPR.
443
444 2021-09-13 Jason Merrill <jason@redhat.com>
445
446 * c.opt: Add -Winterference-size.
447 * c-cppbuiltin.c (cpp_atomic_builtins): Add __GCC_DESTRUCTIVE_SIZE
448 and __GCC_CONSTRUCTIVE_SIZE.
449
450 2021-09-10 Jakub Jelinek <jakub@redhat.com>
451
452 * c-common.h (c_finish_omp_atomic): Add r and weak arguments.
453 * c-omp.c: Include gimple-fold.h.
454 (c_finish_omp_atomic): Add r and weak arguments. Add support for
455 OpenMP 5.1 atomics.
456
457 2021-09-09 qing zhao <qing.zhao@oracle.com>
458
459 * c-attribs.c (handle_uninitialized_attribute): New function.
460 (c_common_attribute_table): Add "uninitialized" attribute.
461
462 2021-09-08 liuhongt <hongtao.liu@intel.com>
463
464 * c-common.c (excess_precision_mode_join): Update below comments.
465 (c_ts18661_flt_eval_method): Set excess_precision_type to
466 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
467 * c-cppbuiltin.c (cpp_atomic_builtins): Update below comments.
468 (c_cpp_flt_eval_method_iec_559): Set excess_precision_type to
469 EXCESS_PRECISION_TYPE_FLOAT16 when -fexcess-precision=16.
470
471 2021-09-07 Marcel Vollweiler <marcel@codesourcery.com>
472
473 * c-omp.c (c_finish_omp_flush): Handle MEMMODEL_SEQ_CST.
474
475 2021-09-03 Eric Botcazou <ebotcazou@adacore.com>
476
477 * c-ada-spec.c (dump_ads): Generate pragmas to disable style checks
478 and -gnatwu warning for the package specification.
479
480 2021-09-01 Iain Sandoe <iain@sandoe.co.uk>
481
482 * c-attribs.c (handle_unavailable_attribute): New.
483
484 2021-08-30 Jason Merrill <jason@redhat.com>
485
486 * c.opt: Add -Wmissing-requires.
487
488 2021-08-25 Lewis Hyatt <lhyatt@gmail.com>
489
490 PR other/93067
491 * c-opts.c (c_common_input_charset_cb): New function.
492 (c_common_post_options): Call new function
493 diagnostic_initialize_input_context().
494
495 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
496
497 * c-format.c (gcc_gfc_length_specs): Add 'll' and 'w'.
498 (gcc_gfc_char_table): Add T9L_LL and T9L_ULL to
499 "di" and "u", respecitively; fill with BADLEN to match
500 size of 'types'.
501 (get_init_dynamic_hwi): Split off from ...
502 (init_dynamic_diag_info): ... here. Call it.
503 (init_dynamic_gfc_info): Call it.
504
505 2021-08-20 Jakub Jelinek <jakub@redhat.com>
506
507 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ERROR.
508 * c-pragma.c (omp_pragmas): Add error directive.
509 * c-omp.c (omp_directives): Uncomment error directive entry.
510
511 2021-08-18 Jakub Jelinek <jakub@redhat.com>
512
513 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_NOTHING.
514 * c-pragma.c (omp_pragmas): Add nothing directive.
515 * c-omp.c (omp_directives): Uncomment nothing directive entry.
516
517 2021-08-17 Jakub Jelinek <jakub@redhat.com>
518
519 PR c++/101539
520 * c-common.h (enum rid): Add RID_IS_LAYOUT_COMPATIBLE.
521 * c-common.c (c_common_reswords): Add __is_layout_compatible.
522
523 2021-08-17 Matt Jacobson <mhjacobson@me.com>
524
525 * c-opts.c (c_common_post_options): Default to
526 flag_objc_sjlj_exceptions = 1 only when flag_objc_abi < 2.
527
528 2021-08-17 Jakub Jelinek <jakub@redhat.com>
529
530 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCOPE.
531 * c-pragma.c (omp_pragmas): Add scope construct.
532 * c-omp.c (omp_directives): Uncomment scope directive entry.
533
534 2021-08-16 Sebastian Huber <sebastian.huber@embedded-brains.de>
535
536 * c-cppbuiltin.c (c_cpp_builtins): Define
537 __LIBGCC_GCOV_TYPE_SIZE if flag_building_libgcc is true.
538
539 2021-08-12 Jakub Jelinek <jakub@redhat.com>
540
541 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_MASKED.
542 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FILTER.
543 * c-pragma.c (omp_pragmas_simd): Add masked construct.
544 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_MASKED
545 enumerator.
546 (c_finish_omp_masked): Declare.
547 * c-omp.c (c_finish_omp_masked): New function.
548 (c_omp_split_clauses): Handle combined masked constructs.
549
550 2021-07-30 Jakub Jelinek <jakub@redhat.com>
551
552 PR c++/101539
553 * c-common.h (enum rid): Add RID_IS_POINTER_INTERCONVERTIBLE_BASE_OF.
554 * c-common.c (c_common_reswords): Add
555 __is_pointer_interconvertible_base_of.
556
557 2021-07-29 Richard Biener <rguenther@suse.de>
558
559 PR c/101512
560 * c-common.c (c_common_mark_addressable_vec): Look through
561 C_MAYBE_CONST_EXPR even if not at the toplevel.
562
563 2021-07-27 Martin Sebor <msebor@redhat.com>
564
565 PR c/101585
566 * c-warn.c (warn_parm_ptrarray_mismatch): Use OEP_DECL_NAME.
567
568 2021-07-23 Jakub Jelinek <jakub@redhat.com>
569
570 * c-lex.c (c_common_has_attribute): Call canonicalize_attr_name also
571 on attr_id. Return 1 for omp::directive or omp::sequence in C++11
572 and later.
573
574 2021-07-23 Jakub Jelinek <jakub@redhat.com>
575
576 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP__START_ and
577 PRAGMA_OMP__LAST_ enumerators.
578
579 2021-07-21 Thomas Schwinge <thomas@codesourcery.com>
580 Joseph Myers <joseph@codesourcery.com>
581 Cesar Philippidis <cesar@codesourcery.com>
582
583 * c-pragma.h (pragma_omp_clause): Add 'PRAGMA_OACC_CLAUSE_NOHOST'.
584
585 2021-07-20 Martin Sebor <msebor@redhat.com>
586
587 * c-common.c (c_build_shufflevector): Adjust by-value argument to
588 by-const-reference.
589 * c-common.h (c_build_shufflevector): Same.
590
591 2021-07-16 Andrew Pinski <apinski@marvell.com>
592
593 PR c/101453
594 * c-common.c (parse_optimize_options): Use the correct
595 size for buffer.
596
597 2021-07-15 Martin Sebor <msebor@redhat.com>
598
599 PR c/101289
600 PR c/97548
601 * c-warn.c (warn_parm_array_mismatch): Use OEP_DECL_NAME.
602
603 2021-07-14 Jason Merrill <jason@redhat.com>
604
605 * c-opts.c (c_common_post_options): Set -fdelete-dead-exceptions.
606
607 2021-07-06 Martin Sebor <msebor@redhat.com>
608
609 * c-format.c (gcc_tdiag_char_table): Remove support for %G and %K.
610 (gcc_cdiag_char_table): Same.
611 (gcc_cxxdiag_char_table): Same.
612
613 2021-07-02 Jakub Jelinek <jakub@redhat.com>
614
615 * c-common.h (enum c_omp_directive_kind): New enum.
616 (struct c_omp_directive): New type.
617 (c_omp_categorize_directive): Declare.
618 * c-omp.c (omp_directives): New variable.
619 (c_omp_categorize_directive): New function.
620
621 2021-07-01 Eric Botcazou <ebotcazou@adacore.com>
622
623 * c-ada-spec.c (packed_layout): New global variable.
624 (dump_ada_declaration): Set it upon seeing a packed record type.
625 Do not put the "aliased" keyword if it is set.
626 (dump_ada_structure): Add Pack aspect if it is set and clear it.
627
628 2021-07-01 Eric Botcazou <ebotcazou@adacore.com>
629
630 * c-ada-spec.c (check_name): Rename into...
631 (check_type_name_conflict): ...this. Minor tweak.
632 (dump_ada_function_declaration): Adjust to above renaming.
633 (dump_ada_array_domains): Fix oversight.
634 (dump_ada_declaration): Call check_type_name_conflict for variables.
635
636 2021-06-25 Martin Sebor <msebor@redhat.com>
637
638 * c-common.c (c_wrap_maybe_const): Remove TREE_NO_WARNING.
639 (c_common_truthvalue_conversion): Replace direct uses of
640 TREE_NO_WARNING with warning_suppressed_p, suppress_warning, and
641 copy_no_warning.
642 (check_function_arguments_recurse): Same.
643 * c-gimplify.c (c_gimplify_expr): Same.
644 * c-warn.c (overflow_warning): Same.
645 (warn_logical_operator): Same.
646 (warn_if_unused_value): Same.
647 (do_warn_unused_parameter): Same.
648
649 2021-06-24 Jakub Jelinek <jakub@redhat.com>
650
651 * c-common.h (enum c_omp_region_type): Add C_ORT_TARGET and
652 C_ORT_OMP_TARGET.
653 * c-omp.c (c_omp_split_clauses): For OMP_CLAUSE_IN_REDUCTION on
654 combined target constructs also add map (always, tofrom:) clause.
655
656 2021-06-15 Robin Dapp <rdapp@linux.ibm.com>
657
658 * c-attribs.c (common_handle_aligned_attribute): Remove short
659 circuit and dead code.
660
661 2021-06-14 Jonathan Wakely <jwakely@redhat.com>
662
663 PR c++/101052
664 * known-headers.cc (get_stdlib_header_for_name): Add known
665 headers for EXIT_FAILURE, EXIT_SUCCESS, abort, atexit, calloc,
666 exit, and getenv.
667
668 2021-06-12 Jason Merrill <jason@redhat.com>
669
670 * c-attribs.c (handle_unused_attribute): Handle FIELD_DECL.
671
672 2021-06-11 Jakub Jelinek <jakub@redhat.com>
673
674 PR c++/100974
675 * c-cppbuiltin.c (c_cpp_builtins): Predefine __cpp_if_consteval for
676 -std=c++2b for P1938R3 consteval if support.
677
678 2021-06-09 Jason Merrill <jason@redhat.com>
679
680 PR c++/100879
681 * c-warn.c (warn_for_sign_compare): Remove C++ enum mismatch
682 warning.
683
684 2021-06-07 Martin Liska <mliska@suse.cz>
685
686 * c-target.def: Split long lines and replace them
687 with '\n\'.
688
689 2021-06-04 Martin Sebor <msebor@redhat.com>
690
691 PR c/100783
692 * c-attribs.c (positional_argument): Bail on erroneous types.
693
694 2021-06-04 Martin Sebor <msebor@redhat.com>
695
696 * c-warn.c (warn_parm_array_mismatch): Check TREE_PURPOSE to test
697 for element presence.
698
699 2021-06-03 Eric Botcazou <ebotcazou@adacore.com>
700
701 * c-ada-spec.c (dump_ada_macros): Minor tweaks.
702 (dump_ada_decl_name): Likewise.
703 (dump_anonymous_type_name): Remove parent parameter and adjust.
704 (dump_sloc): Minor tweak.
705 (dump_ada_array_type): Remove type parameter and adjust.
706 (dump_ada_enum_type): Remove parent parameter and adjust.
707 (dump_ada_node): Adjust calls to above functions.
708 (dumped_anonymous_types): New global variable.
709 (dump_nested_types_1): Rename into...
710 (dump_nested_types): ...this.
711 (dump_nested_type): Remove parent and dumped_types parameters.
712 <ARRAY_TYPE>: Replace dumped_types with dumped_anonymous_types.
713 Adjust calls to dump_anonymous_type_name and dump_ada_array_type.
714 (dump_ada_specs): Initialize and free dumped_anonymous_types.
715
716 2021-06-03 Eric Botcazou <ebotcazou@adacore.com>
717
718 * c-ada-spec.c (pp_ada_tree_identifier): Tidy up.
719 (dump_ada_node) <POINTER_TYPE>: Deal specially with external subtypes.
720
721 2021-06-03 Eric Botcazou <ebotcazou@adacore.com>
722
723 * c-ada-spec.c (dump_ada_enum_type): Dump a prefix for constants.
724 (htable_t): New typedef.
725 (overloaded_names): Use it.
726 (add_name): New function.
727 (init_overloaded_names): Use add_name to populate the table and add
728 special cases for sigaction and stat.
729 (overloaded_name_p): Rename into...
730 (overloading_index): ...this. Do not initialize overloaded_names table
731 here. Return the index or zero.
732 (dump_ada_declaration): Minor tweaks. Do not skip overloaded functions
733 but add an overloading suffix instead.
734 (dump_ada_specs): Initialize overloaded_names tables here.
735
736 2021-06-01 Martin Liska <mliska@suse.cz>
737
738 PR other/100759
739 * c-attribs.c (handle_optimize_attribute): Limit sanity check
740 to a situation where we are not in processing of an optimize
741 pragma.
742 * c-pragma.c (handle_pragma_pop_options): Restore target
743 options.
744
745 2021-05-31 Indu Bhagat <indu.bhagat@oracle.com>
746
747 PR testsuite/100749
748 * c-pch.c (c_common_valid_pch): Use xstrdup for debug format set names.
749
750 2021-05-31 Richard Biener <rguenther@suse.de>
751
752 PR c++/88601
753 * c-common.c: Include tree-vector-builder.h and
754 vec-perm-indices.h.
755 (c_common_reswords): Add __builtin_shufflevector.
756 (c_build_shufflevector): New funtion.
757 * c-common.h (enum rid): Add RID_BUILTIN_SHUFFLEVECTOR.
758 (c_build_shufflevector): Declare.
759
760 2021-05-28 Jakub Jelinek <jakub@redhat.com>
761
762 PR middle-end/99928
763 * c-omp.c (c_omp_split_clauses): For reduction clause if combined with
764 target add a map tofrom clause with OMP_CLAUSE_MAP_IMPLICIT.
765
766 2021-05-28 Tobias Burnus <tobias@codesourcery.com>
767
768 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_AFFINITY.
769
770 2021-05-25 Martin Liska <mliska@suse.cz>
771
772 PR tree-optimization/92860
773 PR target/99592
774 * c-attribs.c (handle_optimize_attribute): Save target node
775 before calling parse_optimize_options and save it in case
776 it changes.
777 * c-pragma.c (handle_pragma_target): Similarly for pragma.
778 (handle_pragma_pop_options): Likewise here.
779
780 2021-05-25 Martin Liska <mliska@suse.cz>
781
782 * c-attribs.c (handle_no_sanitize_coverage_attribute): New.
783
784 2021-05-25 Jakub Jelinek <jakub@redhat.com>
785
786 PR middle-end/99928
787 * c-omp.c (c_omp_split_clauses): Copy reduction to teams when teams is
788 combined with simd and not with taskloop or for.
789
790 2021-05-21 Jakub Jelinek <jakub@redhat.com>
791
792 PR middle-end/99928
793 * c-omp.c (c_omp_split_clauses): Set OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT
794 on firstprivate clause copy going to target construct, and for
795 target simd set also OMP_CLAUSE_FIRSTPRIVATE_IMPLICIT_TARGET bit.
796
797 2021-05-20 Jonathan Wakely <jwakely@redhat.com>
798
799 * c.opt (Wc++11-extensions, Wc++14-extensions)
800 (Wc++17-extensions, Wc++20-extensions, Wc++23-extensions): New
801 options.
802
803 2021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
804
805 * c-lex.c (init_c_lex): Use dwarf_debuginfo_p.
806
807 2021-05-20 Indu Bhagat <indu.bhagat@oracle.com>
808
809 * c-opts.c (c_common_post_options): Adjust access to debug_type_names.
810 * c-pch.c (struct c_pch_validity): Use type uint32_t.
811 (pch_init): Renamed member.
812 (c_common_valid_pch): Adjust access to debug_type_names.
813
814 2021-05-19 Martin Sebor <msebor@redhat.com>
815
816 PR c/100619
817 * c-attribs.c (build_attr_access_from_parms): Handle arbitrarily many
818 bounds.
819
820 2021-05-18 Richard Biener <rguenther@suse.de>
821
822 PR c/100547
823 * c-attribs.c (type_valid_for_vector_size): Reject too large nunits.
824 Reword existing nunit diagnostic.
825
826 2021-05-17 Joern Rennecke <joern.rennecke@embecosm.com>
827
828 * c-common.c (braced_list_to_string): Return CTOR unchanged
829 if host and target character sizes don't match.
830
831 2021-05-14 Martin Liska <mliska@suse.cz>
832
833 * c.opt: Add Warning keyword for 2 options.
834
835 2021-05-13 Martin Liska <mliska@suse.cz>
836
837 PR middle-end/100504
838 * c-attribs.c (handle_target_clones_attribute): Expect a string
839 argument to target_clone argument.
840
841 2021-05-11 Joseph Myers <joseph@codesourcery.com>
842
843 * c-lex.c (interpret_float): Handle digit separators for C2X.
844
845 2021-05-10 Martin Liska <mliska@suse.cz>
846
847 * c-ada-spec.c (print_destructor): Use startswith
848 function instead of strncmp.
849 (dump_ada_declaration): Likewise.
850 * c-common.c (disable_builtin_function): Likewise.
851 (def_builtin_1): Likewise.
852 * c-format.c (check_tokens): Likewise.
853 (check_plain): Likewise.
854 (convert_format_name_to_system_name): Likewise.
855
856 2021-04-28 Patrick McGehearty <patrick.mcgehearty@oracle.com>
857
858 * c-cppbuiltin.c (c_cpp_builtins): Add supporting macros for new
859 complex divide
860
861 2021-04-26 Thomas Schwinge <thomas@codesourcery.com>
862 Nathan Sidwell <nathan@codesourcery.com>
863 Tom de Vries <vries@codesourcery.com>
864 Julian Brown <julian@codesourcery.com>
865 Kwok Cheung Yeung <kcy@codesourcery.com>
866
867 * c.opt (Wopenacc-parallelism): New.
868
869 2021-04-19 Thomas Schwinge <thomas@codesourcery.com>
870
871 * c.opt (fopenacc-kernels=): Remove.
872
873 2021-04-08 Jakub Jelinek <jakub@redhat.com>
874
875 * c-warn.c (do_warn_double_promotion): Fix comment typo,
876 occured -> occurred.
877 (check_alignment_of_packed_member): Fix a comment typo,
878 memeber -> member.
879 (warn_parm_ptrarray_mismatch): Fix comment typos, os -> of
880 and onless -> unless.
881 (warn_parm_array_mismatch): Fix comment typos, declaratation
882 -> declaration and woud -> would. Fix up comment indentation.
883
884 2021-04-08 Martin Sebor <msebor@redhat.com>
885
886 PR middle-end/99883
887 * c.opt (Wmismatched-new-delete): Correct spelling.
888
889 2021-04-05 Eric Botcazou <ebotcazou@adacore.com>
890
891 * c-ada-spec.c (is_simple_enum): Minor tweaks.
892 (dump_ada_enum_type): Add TYPE and PARENT parameters. For non-simple
893 enumeral types use again the type name for the enumeration constants.
894 (dump_ada_node): Adjust call to dump_ada_enum_type.
895 (dump_nested_type): Likewise.
896
897 2021-04-01 Jason Merrill <jason@redhat.com>
898
899 PR c++/98481
900 * c-opts.c (c_common_post_options): Bump latest_abi_version.
901
902 2021-03-25 Jakub Jelinek <jakub@redhat.com>
903
904 PR c++/99565
905 * c-warn.c (do_warn_duplicated_branches): Pass also
906 OEP_ADDRESS_OF_SAME_FIELD to operand_equal_p.
907
908 2021-03-20 Jakub Jelinek <jakub@redhat.com>
909
910 PR debug/99230
911 * c-gimplify.c (c_genericize_control_stmt): Handle STATEMENT_LIST.
912
913 2021-03-05 Eric Botcazou <ebotcazou@adacore.com>
914
915 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Dump nested types
916 after entering the separate class package, if any.
917
918 2021-03-04 Richard Biener <rguenther@suse.de>
919
920 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator):
921 Handle ERROR_MARK.
922
923 2021-03-04 Jakub Jelinek <jakub@redhat.com>
924
925 PR c/99325
926 * c-ppoutput.c (print): Change src_line type from int to unsigned.
927 (token_streamer::stream) Likewise.
928 (maybe_print_line_1): Likewise. Don't strcmp src_file if src_loc is
929 UNKNOWN_LOCATION.
930
931 2021-03-03 Jakub Jelinek <jakub@redhat.com>
932
933 PR c/99324
934 * c-common.c (build_va_arg): Call c_common_mark_addressable_vec
935 instead of mark_addressable. Fix a comment typo -
936 neutrallly -> neutrally.
937
938 2021-02-28 Jakub Jelinek <jakub@redhat.com>
939
940 PR c/99304
941 * c-attribs.c (handle_malloc_attribute): Fix a typo in inform
942 message - refernced -> referenced. Remove superfluous space before
943 closing paren of function calls.
944
945 2021-02-25 Nathan Sidwell <nathan@acm.org>
946
947 PR c++/99166
948 * c.opt (-flang-info-module-cmi): Renamed option.
949
950 2021-02-19 Nathan Sidwell <nathan@acm.org>
951
952 * c.opt (flang-info-module-read, flang-info-module-read=): New.
953
954 2021-02-18 H.J. Lu <hjl.tools@gmail.com>
955
956 PR target/99113
957 * c-attribs.c (c_common_attribute_table): Add the "retain"
958 attribute.
959 (handle_retain_attribute): New function.
960
961 2021-02-16 Marek Polacek <polacek@redhat.com>
962
963 PR c++/99062
964 * c-attribs.c (handle_assume_aligned_attribute): Check that the
965 alignment argument is non-negative. Tweak a warning message.
966
967 2021-02-12 Martin Sebor <msebor@redhat.com>
968
969 PR c/99055
970 * c-warn.c (warn_parm_array_mismatch): Free strings returned from
971 print_generic_expr_to_str.
972
973 2021-02-10 Richard Biener <rguenther@suse.de>
974
975 * c-common.c (parse_optimize_options): Free decoded_options.
976
977 2021-02-04 emsr <3dw4rd@verizon.net>
978
979 * c-cppbuiltin.c (c_cpp_builtins): __cpp_size_t_suffix=202011L.
980
981 2021-02-03 Ed Smith-Rowland <3dw4rd@verizon.net>
982
983 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_size_t_suffix.
984 * c-lex.c (interpret_integer): Set node type for size literal.
985
986 2021-01-28 Jakub Jelinek <jakub@redhat.com>
987
988 * c.opt (-std=c++2a, -std=c++20, -std=gnu++2a, -std=gnu++20): Remove
989 draft from description.
990 (-std=c++2b): Fix a pasto, 2020 -> 2023.
991
992 2021-01-26 Paul Fee <paul.f.fee@gmail.com>
993
994 * c-common.h (cxx_dialect): Add cxx23 as a dialect.
995 * c.opt: Add options for -std=c++23, std=c++2b, -std=gnu++23
996 and -std=gnu++2b
997 * c-opts.c (set_std_cxx23): New.
998 (c_common_handle_option): Set options when -std=c++23 is enabled.
999 (c_common_post_options): Adjust comments.
1000 (set_std_cxx20): Likewise.
1001
1002 2021-01-25 Martin Sebor <msebor@redhat.com>
1003
1004 PR c++/98646
1005 * c-common.c (check_nonnull_arg): Adjust warning text.
1006
1007 2021-01-17 Martin Sebor <msebor@redhat.com>
1008
1009 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
1010 assume SSA_NAME_IDENTIFIER evaluates to nonzero.
1011
1012 2021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
1013
1014 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_DETACH.
1015 Redefine PRAGMA_OACC_CLAUSE_DETACH.
1016
1017 2021-01-15 Jakub Jelinek <jakub@redhat.com>
1018
1019 PR tree-optimization/98597
1020 * c-pretty-print.c: Include options.h.
1021 (c_fold_indirect_ref_for_warn): New function.
1022 (print_mem_ref): Use it. If it returns something that has compatible
1023 type and is TBAA compatible with zero offset, print it and return,
1024 otherwise print it using offsetof syntax or array ref syntax. Fix up
1025 printing if MEM_REFs first operand is ADDR_EXPR, or when the first
1026 argument has pointer to array type. Print pointers using the standard
1027 formatting.
1028
1029 2021-01-12 Martin Sebor <msebor@redhat.com>
1030
1031 PR c/98597
1032 PR c/98592
1033 * c-pretty-print.c (print_mem_ref): Avoid assuming MEM_REF operand
1034 has pointer type. Remove redundant code. Avoid calling
1035 gimple_canonical_types_compatible_p.
1036
1037 2021-01-07 Martin Sebor <msebor@redhat.com>
1038
1039 PR middle-end/98578
1040 * c-pretty-print.c (print_mem_ref): Strip array from access type.
1041 Avoid assuming acces type's size is constant. Correct condition
1042 guarding the printing of a parenthesis.
1043
1044 2021-01-06 Martin Sebor <msebor@redhat.com>
1045
1046 PR c++/95768
1047 * c-pretty-print.c (c_pretty_printer::primary_expression): For
1048 SSA_NAMEs print VLA names and GIMPLE defining statements.
1049 (print_mem_ref): New function.
1050 (c_pretty_printer::unary_expression): Call it.
1051
1052 2021-01-06 Richard Biener <rguenther@suse.de>
1053
1054 PR tree-optimization/95582
1055 * c-attribs.c (c_common_attribute_table): Add entry for
1056 signed_bool_precision.
1057 (handle_signed_bool_precision_attribute): New.
1058
1059 2020-12-24 Iain Sandoe <iain@sandoe.co.uk>
1060
1061 * c.opt: Add -stdlib= option and enumerations for
1062 libstdc++ and libc++.
1063
1064 2020-12-16 Martin Liska <mliska@suse.cz>
1065
1066 * c.opt: Remove usage of Report.
1067
1068 2020-12-14 Martin Sebor <msebor@redhat.com>
1069
1070 PR middle-end/98166
1071 PR c++/57111
1072 PR middle-end/98160
1073 * c-attribs.c (maybe_add_noinline): New function.
1074 (handle_malloc_attribute): Call it. Use ATTR_FLAG_INTERNAL.
1075 Implicitly add attribute noinline to functions not declared inline
1076 and warn on those.
1077
1078 2020-12-09 Tobias Burnus <tobias@codesourcery.com>
1079
1080 * c-pragma.c (omp_pragmas): Add 'allocate'.
1081 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_ALLOCATE.
1082
1083 2020-12-08 Jakub Jelinek <jakub@redhat.com>
1084
1085 PR c++/98187
1086 * c-pragma.c (omp_pragmas): Remove "master".
1087 (omp_pragmas_simd): Add "master".
1088
1089 2020-12-07 Marek Polacek <polacek@redhat.com>
1090
1091 PR c++/98126
1092 * c-common.c (verify_tree_lim_r): New function.
1093 (verify_sequence_points): Use it. Use nullptr instead of 0.
1094
1095 2020-12-03 Martin Sebor <msebor@redhat.com>
1096
1097 PR c++/90629
1098 PR middle-end/94527
1099 * c-attribs.c (handle_dealloc_attribute): New function.
1100 (handle_malloc_attribute): Handle argument forms of attribute.
1101 * c.opt (-Wmismatched-dealloc): New option.
1102 (-Wmismatched-new-delete): New option.
1103
1104 2020-12-03 Jakub Jelinek <jakub@redhat.com>
1105
1106 PR libstdc++/93121
1107 * c-common.h (enum rid): Add RID_BUILTIN_BIT_CAST.
1108 * c-common.c (c_common_reswords): Add __builtin_bit_cast.
1109
1110 2020-12-01 JeanHeyd Meneide <phdofthehouse@gmail.com>
1111
1112 * c-cppbuiltin.c (c_cpp_builtins): Add predefined
1113 {__GNUC_EXECUTION_CHARSET_NAME} and
1114 _WIDE_EXECUTION_CHARSET_NAME} macros.
1115
1116 2020-12-01 Nathan Sidwell <nathan@acm.org>
1117
1118 * c-common.c (module, import, export): New internal tokens (with
1119 trailing space).
1120 * c-common.h (RID__MODULE, RID__IMPORT & RID__EXPORT): Enumerate
1121 them.
1122 (D_CXX_MODULES, D_CXX_MODULES_FLAGS): Enable them.
1123 * c-cppbuiltin.c (c_cpp_builtins): Feature macro.
1124
1125 2020-12-01 Nathan Sidwell <nathan@acm.org>
1126
1127 * c-opts.c (c_common_init_options): Ask for module dependencies.
1128 (c_common_handle_option): Handle -Mmodules -Mno-modules.
1129 * c-pch.c (c_common_valid_pch): ... does not play with C++
1130 modules.
1131 * c.opt (Mmodules, Mno-modules): New preprocessor dependency
1132 options.
1133 (fmodules-ts, fmodule-header, fmodule-implicit-inline)
1134 (fmodule-only, fmodule-mapper, fmodule-lazy)
1135 (fmodule-version-ignore, Winvalid-imported-macros)
1136 (flang-info-include-translate, flang-info-include-translate-not):
1137 New options
1138
1139 2020-11-28 Eric Botcazou <ebotcazou@adacore.com>
1140
1141 * c-ada-spec.c (dump_nested_type) <RECORD_TYPE>: Remove obsolete code.
1142 (dump_ada_structure): Also deal with convention, unchecked union and
1143 bit-field for nested types. In the latter case, print an Alignment
1144 aspect along with the Pack aspect.
1145
1146 2020-11-25 Martin Sebor <msebor@redhat.com>
1147
1148 PR bootstrap/94982
1149 * c-attribs.c (handle_patchable_function_entry_attribute): Avoid
1150 -Wformat-diag.
1151
1152 2020-11-24 Martin Sebor <msebor@redhat.com>
1153
1154 * c-warn.c (warn_parm_array_mismatch): Avoid invalid redeclarations.
1155
1156 2020-11-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
1157
1158 * c-attribs.c (handle_special_var_sec_attribute): New.
1159 (handle_noinit_attribute): Remove.
1160 (attr_noinit_exclusions): Rename to...
1161 (attr_section_exclusions): ...this, and add "persistent" attribute
1162 exclusion.
1163 (c_common_attribute_table): Add "persistent" attribute.
1164
1165 2020-11-21 Aaron Sawdey <acsawdey@linux.ibm.com>
1166
1167 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
1168 Treat opaque types like other types.
1169 (c_pretty_printer::direct_abstract_declarator): Opaque types are
1170 supported types.
1171
1172 2020-11-20 Martin Sebor <msebor@redhat.com>
1173
1174 * c-warn.c (warn_parm_array_mismatch): Bail on invalid redeclarations
1175 with fewer arguments.
1176
1177 2020-11-20 Martin Sebor <msebor@redhat.com>
1178
1179 PR middle-end/97879
1180 * c-attribs.c (handle_access_attribute): Handle ATTR_FLAG_INTERNAL.
1181 Error out on invalid modes.
1182
1183 2020-11-20 Jakub Jelinek <jakub@redhat.com>
1184
1185 PR libstdc++/88101
1186 * c-common.c (check_builtin_function_arguments): Handle
1187 BUILT_IN_CLEAR_PADDING.
1188
1189 2020-11-18 Nathan Sidwell <nathan@acm.org>
1190
1191 * c-lex.c (c_lex_with_flags): CPP_HEADER_NAMEs can now be seen.
1192
1193 2020-11-17 Nathan Sidwell <nathan@acm.org>
1194
1195 * c-common.h (enum c_tree_index): Reorder to place lazy fields
1196 after newly-added CTI_MODULE_HWM.
1197
1198 2020-11-17 Joseph Myers <joseph@codesourcery.com>
1199
1200 * c-cppbuiltin.c (builtin_define_float_constants): Define
1201 "*_IS_IEC_60559__" macros.
1202
1203 2020-11-17 Nathan Sidwell <nathan@acm.org>
1204
1205 * c-lex.c: #include "langhooks.h".
1206 (cb_undef): Maybe call preprocess_undef lang hook.
1207 * c-opts.c (c_common_post_options): Maybe call preprocess_options
1208 lang hook.
1209 (push_command_line_include): Maybe call preprocess_main_file lang
1210 hook.
1211 (cb_file_change): Likewise.
1212 * c-ppoutput.c: #include "langhooks.h.
1213 (scan_translation_unit): Maybe call preprocess_token lang hook.
1214 (class do_streamer): New, derive from token_streamer.
1215 (directives_only_cb): Data pointer is do_streamer, call
1216 preprocess_token lang hook.
1217 (scan_translation_unit_directives_only): Use do_streamer.
1218 (print_line_1): Move src_line recording to after string output.
1219 (cb_undef): Maybe call preprocess_undef lang hook.
1220
1221 2020-11-17 Nathan Sidwell <nathan@acm.org>
1222
1223 * c-ppoutput.c (scan_translation_unit): Use token_streamer, remove
1224 code duplicating that functionality.
1225
1226 2020-11-17 Jakub Jelinek <jakub@redhat.com>
1227
1228 PR c/90628
1229 * c-common.c (check_builtin_function_arguments)
1230 <case BUILT_IN_ADD_OVERFLOW>: Diagnose when last argument is pointer
1231 to _Atomic. For the TYPE_READONLY case, adjust message to be usable
1232 for more builtins and argument positions.
1233
1234 2020-11-16 Iain Sandoe <iain@sandoe.co.uk>
1235
1236 PR objc/97854
1237 * stub-objc.c: Include c-common.h to declare enum rid.
1238
1239 2020-11-13 Jakub Jelinek <jakub@redhat.com>
1240
1241 PR c++/63287
1242 * c-cppbuiltin.c: Include configargs.h.
1243 (c_cpp_builtins): For C++11 and later if THREAD_MODEL_SPEC is not
1244 defined, predefine __STDCPP_THREADS__ to 1 unless thread_model is
1245 "single".
1246
1247 2020-11-13 Gergö Barany <gergo@codesourcery.com>
1248 Thomas Schwinge <thomas@codesourcery.com>
1249
1250 * c.opt (fopenacc-kernels): Add.
1251
1252 2020-11-13 Jason Merrill <jason@redhat.com>
1253
1254 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_using_enum.
1255
1256 2020-11-13 Piotr H. Dabrowski <phd@phd.re>
1257
1258 PR c++/91318
1259 * c-cppbuiltin.c: c_cpp_builtins_optimize_pragma(): use cpp_define_unused()
1260
1261 2020-11-13 Martin Liska <mliska@suse.cz>
1262
1263 * c-attribs.c (build_attr_access_from_parms): Format properly.
1264
1265 2020-11-13 Iain Sandoe <iain@sandoe.co.uk>
1266
1267 PR objc/90707
1268 * c-common.c (c_common_reswords): null_unspecified, nullable,
1269 nonnull, null_resettable: New keywords.
1270 * c-common.h (enum rid): RID_NULL_UNSPECIFIED, RID_NULLABLE,
1271 RID_NONNULL, RID_NULL_RESETTABLE: New.
1272 (OBJC_IS_PATTR_KEYWORD): Include nullability keywords in the
1273 ranges accepted for property attributes.
1274 * c-attribs.c (handle_objc_nullability_attribute): New.
1275 * c-objc.h (enum objc_property_attribute_group): Add
1276 OBJC_PROPATTR_GROUP_NULLABLE.
1277 (enum objc_property_attribute_kind):Add
1278 OBJC_PROPERTY_ATTR_NULL_UNSPECIFIED, OBJC_PROPERTY_ATTR_NULLABLE,
1279 OBJC_PROPERTY_ATTR_NONNULL, OBJC_PROPERTY_ATTR_NULL_RESETTABLE.
1280
1281 2020-11-13 Iain Sandoe <iain@sandoe.co.uk>
1282
1283 PR objc/77404
1284 * c-attribs.c (handle_objc_root_class_attribute): New
1285 * c-objc.h (objc_start_class_interface): Add a location
1286 value for the position of the class name.
1287 * c.opt: Add Wobjc-root-class.
1288 * stub-objc.c (objc_start_class_interface): Add a location
1289 value for the position of the class name.
1290
1291 2020-11-12 Joseph Myers <joseph@codesourcery.com>
1292
1293 * c-lex.c (c_common_has_attribute): Take argument std_syntax.
1294 Allow scope for C. Handle standard attributes for C. Do not
1295 accept unscoped attributes if std_syntax and not handled as
1296 standard attributes.
1297 * c-common.h (c_common_has_attribute): Update prototype.
1298
1299 2020-11-12 Nicholas Guriev <guriev-ns@ya.ru>
1300
1301 PR pch/86674
1302 * c-pch.c (c_common_valid_pch): Use cpp_warning with CPP_W_INVALID_PCH
1303 reason to fix -Werror=invalid-pch and -Wno-error=invalid-pch switches.
1304
1305 2020-11-11 Patrick Palka <ppalka@redhat.com>
1306
1307 PR c++/88115
1308 * c-opts.c (c_common_post_options): Update latest_abi_version.
1309
1310 2020-11-10 Jakub Jelinek <jakub@redhat.com>
1311
1312 PR c/97748
1313 * c-common.h (warn_if_unused_value): Add quiet argument defaulted
1314 to false.
1315 * c-warn.c (warn_if_unused_value): Likewise. Pass it down
1316 recursively and just return true instead of warning if it is true.
1317 Handle COMPLEX_EXPR.
1318
1319 2020-11-10 Chung-Lin Tang <cltang@codesourcery.com>
1320
1321 * c-common.h (c_omp_adjust_map_clauses): New declaration.
1322 * c-omp.c (struct map_clause): Helper type for c_omp_adjust_map_clauses.
1323 (c_omp_adjust_map_clauses): New function.
1324
1325 2020-11-09 Marek Polacek <polacek@redhat.com>
1326
1327 DR 1914
1328 * c-common.c (attribute_fallthrough_p): Tweak the warning
1329 message.
1330
1331 2020-11-09 Patrick Palka <ppalka@redhat.com>
1332
1333 * c-pragma.c (handle_pragma_diagnostic): Split the
1334 unknown-option -Wpragmas diagnostic into a warning and a
1335 subsequent note containing a spelling suggestion. Avoid
1336 computing the suggestion if -Wpragmas warnings are being
1337 suppressed.
1338
1339 2020-11-09 Patrick Palka <ppalka@redhat.com>
1340
1341 PR testsuite/97117
1342 * c-indentation.c (get_visual_column): Remove location_t
1343 parameter. Move the column-tracking diagnostic code from here
1344 to ...
1345 (should_warn_for_misleading_indentation): ... here, before the
1346 early exit for when the loci are not all distinct. Don't pass a
1347 location_t argument to get_visual_column.
1348 (assert_get_visual_column_succeeds): Don't pass a location_t
1349 argument to get_visual_column.
1350 (assert_get_visual_column_fails): Likewise.
1351
1352 2020-11-08 Iain Sandoe <iain@sandoe.co.uk>
1353
1354 * c-common.h (OBJC_IS_PATTR_KEYWORD): Add class to the list
1355 of keywords accepted in @property attribute contexts.
1356 * c-objc.h (enum objc_property_attribute_group): Add
1357 OBJC_PROPATTR_GROUP_CLASS.
1358 (enum objc_property_attribute_kind): Add
1359 OBJC_PROPERTY_ATTR_CLASS.
1360
1361 2020-11-07 Iain Sandoe <iain@sandoe.co.uk>
1362
1363 * c-common.c (c_common_reswords): Add 'atomic' property
1364 attribute.
1365 * c-common.h (enum rid): Add RID_PROPATOMIC for atomic
1366 property attributes.
1367
1368 2020-11-07 Iain Sandoe <iain@sandoe.co.uk>
1369
1370 * c-attribs.c (handle_nsobject_attribute): New.
1371 * c.opt: Add WNSObject-attribute.
1372
1373 2020-11-06 Iain Sandoe <iain@sandoe.co.uk>
1374
1375 * c-objc.h (enum objc_property_attribute_group): New
1376 (enum objc_property_attribute_kind): New.
1377 (OBJC_PROPATTR_GROUP_MASK): New.
1378 (struct property_attribute_info): Small class encapsulating
1379 parser output from property attributes.
1380 (objc_prop_attr_kind_for_rid): New
1381 (objc_add_property_declaration): Simplify interface.
1382 * stub-objc.c (enum rid): Dummy type.
1383 (objc_add_property_declaration): Simplify interface.
1384 (objc_prop_attr_kind_for_rid): New.
1385
1386 2020-11-06 Nathan Sidwell <nathan@acm.org>
1387
1388 * c-ada-spec.c (collect_ada_nodes): Rename
1389 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
1390 (collect_ada_node): Likewise.
1391 (dump_forward_type): Likewise.
1392 * c-common.c (set_underlying_type): Rename
1393 DECL_IS_BUILTIN->DECL_IS_UNDECLARED_BUILTIN.
1394 (user_facing_original_type, c_common_finalize_early_debug): Likewise.
1395
1396 2020-11-06 Jakub Jelinek <jakub@redhat.com>
1397
1398 * c-common.c (verify_sequence_points): Remove DEBUG_FUNCTION.
1399
1400 2020-11-05 Marek Polacek <polacek@redhat.com>
1401
1402 PR c++/97675
1403 * c.opt (Wexceptions): New option.
1404
1405 2020-11-05 Marek Polacek <polacek@redhat.com>
1406
1407 PR c++/25814
1408 * c.opt (Wvexing-parse): New option.
1409
1410 2020-11-04 Jakub Jelinek <jakub@redhat.com>
1411
1412 PR c++/97670
1413 * c-omp.c (c_omp_split_clauses): Look through array reductions to find
1414 underlying decl to clear in the allocate_head bitmap.
1415
1416 2020-11-04 Iain Sandoe <iain@sandoe.co.uk>
1417
1418 * c-objc.h (objc_non_constant_expr_p): New.
1419 * stub-objc.c (objc_non_constant_expr_p): New.
1420
1421 2020-11-03 Nathan Sidwell <nathan@acm.org>
1422
1423 * c.opt (MQ,MT): Reword description to be make-agnostic.
1424
1425 2020-11-02 Nathan Sidwell <nathan@acm.org>
1426
1427 * c-opts.c (c_common_post_options): Move var decl to its
1428 initialization point.
1429
1430 2020-11-01 Iain Sandoe <iain@sandoe.co.uk>
1431
1432 * c-lex.c (c_lex_with_flags): When combining '@' with a
1433 keyword for Objective-C, combine the location ranges too.
1434
1435 2020-10-30 Qing Zhao <qing.zhao@oracle.com>
1436 H.J.Lu <hjl.tools@gmail.com>
1437
1438 * c-attribs.c (c_common_attribute_table): Add new attribute
1439 zero_call_used_regs.
1440 (handle_zero_call_used_regs_attribute): New function.
1441
1442 2020-10-28 Marek Polacek <polacek@redhat.com>
1443
1444 PR c++/97573
1445 * c-opts.c (c_common_post_options): In C++20, turn on
1446 -Wdeprecated-enum-enum-conversion and
1447 -Wdeprecated-enum-float-conversion.
1448 * c.opt (Wdeprecated-enum-enum-conversion,
1449 Wdeprecated-enum-float-conversion): New options.
1450 (Wenum-conversion): Allow for C++ too.
1451
1452 2020-10-28 Jakub Jelinek <jakub@redhat.com>
1453
1454 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALLOCATE.
1455 * c-omp.c: Include bitmap.h.
1456 (c_omp_split_clauses): Handle OMP_CLAUSE_ALLOCATE.
1457
1458 2020-10-26 Ville Voutilainen <ville.voutilainen@gmail.com>
1459
1460 * c-common.c (__is_nothrow_assignable): New.
1461 (__is_nothrow_constructible): Likewise.
1462 * c-common.h (RID_IS_NOTHROW_ASSIGNABLE): New.
1463 (RID_IS_NOTHROW_CONSTRUCTIBLE): Likewise.
1464
1465 2020-10-23 Jan Hubicka <hubicka@ucw.cz>
1466
1467 * c-common.c (c_common_finalize_early_debug): Update for new thunk api.
1468
1469 2020-10-23 Marek Polacek <polacek@redhat.com>
1470
1471 PR c++/91741
1472 * c-common.c (verify_tree): Handle PAREN_SIZEOF_EXPR.
1473 (c_common_init_ts): Likewise.
1474 * c-common.def (PAREN_SIZEOF_EXPR): New tree code.
1475 * c-common.h (maybe_warn_sizeof_array_div): Declare.
1476 * c-warn.c (sizeof_pointer_memaccess_warning): Unwrap NOP_EXPRs.
1477 (maybe_warn_sizeof_array_div): New function.
1478 * c.opt (Wsizeof-array-div): New option.
1479
1480 2020-10-23 Martin Sebor <msebor@redhat.com>
1481
1482 PR c/97463
1483 * c-warn.c (warn_parm_ptrarray_mismatch): Move null test earlier.
1484
1485 2020-10-22 Martin Liska <mliska@suse.cz>
1486
1487 PR c/94722
1488 * c-attribs.c (handle_no_stack_protect_function_attribute): New.
1489 (handle_stack_protect_attribute): Add error message for a
1490 no_stack_protector function.
1491
1492 2020-10-22 Martin Liska <mliska@suse.cz>
1493
1494 * c-cppbuiltin.c (c_cpp_builtins): Use the stack_protector enum.
1495
1496 2020-10-22 Jan Hubicka <hubicka@ucw.cz>
1497
1498 * c-gimplify.c: Include tree-nested.h
1499 (c_genericize): Update for new nested function info.
1500
1501 2020-10-14 Martin Sebor <msebor@redhat.com>
1502
1503 PR c/97413
1504 * c-attribs.c (build_attr_access_from_parms): Wrap chain of VLA
1505 bounds in an extra list.
1506
1507 2020-10-05 Richard Biener <rguenther@suse.de>
1508 Jakub Jelinek <jakub@redhat.com>
1509
1510 PR c++/97197
1511 * c-pretty-print.c: Include langhooks.h.
1512 (c_pretty_printer::postfix_expression): Handle TARGET_MEM_REF as
1513 expression.
1514 (c_pretty_printer::expression): Handle TARGET_MEM_REF as
1515 unary_expression.
1516 (c_pretty_printer::unary_expression): Handle TARGET_MEM_REF.
1517
1518 2020-09-30 Martin Sebor <msebor@redhat.com>
1519
1520 PR middle-end/97189
1521 * c-attribs.c (append_access_attr): Use the function declaration
1522 location for a warning about an attribute access argument.
1523
1524 2020-09-29 Marek Polacek <polacek@redhat.com>
1525
1526 PR c++/94695
1527 * c.opt (Wrange-loop-construct): New option.
1528
1529 2020-09-23 Martin Sebor <msebor@redhat.com>
1530
1531 PR c/97131
1532 * c-warn.c (warn_parm_ptrarray_mismatch): Handle more invalid input.
1533
1534 2020-09-23 Marek Polacek <polacek@redhat.com>
1535
1536 PR c/97125
1537 * c-gimplify.c (c_genericize): Only call do_warn_duplicated_branches_r
1538 after loops and other structured control constructs have been lowered.
1539
1540 2020-09-22 Jakub Jelinek <jakub@redhat.com>
1541
1542 * c.opt (Wbuiltin-declaration-mismatch): Fix typo in variable name:
1543 warn_builtin_declaraion_mismatch -> warn_builtin_declaration_mismatch.
1544
1545 2020-09-21 Marek Polacek <polacek@redhat.com>
1546
1547 * c.opt (Wctad-maybe-unsupported): New option.
1548
1549 2020-09-19 Martin Sebor <msebor@redhat.com>
1550
1551 PR c/50584
1552 * c-common.h (warn_parm_array_mismatch): Declare new function.
1553 (has_attribute): Move declaration of an existing function.
1554 (build_attr_access_from_parms): Declare new function.
1555 * c-warn.c (parm_array_as_string): Define new function.
1556 (plus_one): Define new function.
1557 (warn_parm_ptrarray_mismatch): Define new function.
1558 (warn_parm_array_mismatch): Define new function.
1559 (vla_bound_parm_decl): New function.
1560 * c.opt (-Warray-parameter, -Wvla-parameter): New options.
1561 * c-pretty-print.c (pp_c_type_qualifier_list): Don't print array type
1562 qualifiers here...
1563 (c_pretty_printer::direct_abstract_declarator): ...but instead print
1564 them in brackets here. Also print [static]. Strip extraneous
1565 expressions from VLA bounds.
1566
1567 2020-09-19 Martin Sebor <msebor@redhat.com>
1568
1569 PR c/50584
1570 * c-attribs.c (c_common_attribute_table): Add "arg spec" attribute.
1571 (handle_argspec_attribute): New function.
1572 (get_argument, get_argument_type): New functions.
1573 (append_access_attrs): Add overload. Handle internal attribute
1574 representation in addition to external.
1575 (handle_access_attribute): Handle internal attribute representation
1576 in addition to external.
1577 (build_attr_access_from_parms): New function.
1578
1579 2020-09-19 Sandra Loosemore <sandra@codesourcery.com>
1580
1581 * c-gimplify.c (genericize_c_loop): Rewrite to match
1582 c_finish_loop in c-typeck.c.
1583
1584 2020-09-19 Sandra Loosemore <sandra@codesourcery.com>
1585
1586 * c-common.c (c_block_may_fallthrough): New, split from
1587 cxx_block_may_fallthrough in the cp front end.
1588 (c_common_init_ts): Move handling of loop and switch-related
1589 statements here from the cp front end.
1590 * c-common.def (FOR_STMT, WHILE_STMT, DO_STMT): Move here from
1591 cp front end.
1592 (BREAK_STMT, CONTINUE_STMT, SWITCH_STMT): Likewise.
1593 * c-common.h (c_block_may_fallthru): Declare.
1594 (bc_state_t): Move here from cp front end.
1595 (save_bc_state, restore_bc_state): Declare.
1596 (c_genericize_control_stmt): Declare.
1597 (WHILE_COND, WHILE_BODY): Likewise.
1598 (DO_COND, DO_BODY): Likewise.
1599 (FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY, FOR_SCOPE): Likewise.
1600 (SWITCH_STMT_COND, SWITCH_STMT_BODY): Likewise.
1601 (SWITCH_STMT_TYPE, SWITCH_STMT_SCOPE): Likewise.
1602 (SWITCH_STMT_ALL_CASES_P, SWITCH_STMT_NO_BREAK_P): Likewise.
1603 (LABEL_DECL_BREAK, LABEL_DECL_CONTINUE): Likewise.
1604 * c-dump.c (dump_stmt): Copy from cp front end.
1605 (c_dump_tree): Move code to handle structured loop and switch
1606 tree nodes here from cp front end.
1607 * c-gimplify.c: Adjust includes.
1608 (enum bc_t, bc_label, begin_bc_block, finish_bc_block): Move from
1609 cp front end.
1610 (save_bc_state, restore_bc_state): New functions using old code
1611 from cp front end.
1612 (get_bc_label, expr_loc_or_loc): Move from cp front end.
1613 (genericize_c_loop): Move from cp front end.
1614 (genericize_for_stmt, genericize_while_stmt): Likewise.
1615 (genericize_do_stmt, genericize_switch_stmt): Likewise.
1616 (genericize_continue_stmt, genericize_break_stmt): Likewise.
1617 (genericize_omp_for_stmt): Likewise.
1618 (c_genericize_control_stmt): New function using code split from
1619 cp front end.
1620 (c_genericize_control_r): New.
1621 (c_genericize): Call walk_tree with c_genericize_control_r.
1622 * c-pretty-print.c (c_pretty_printer::statement): Move code to handle
1623 structured loop and switch tree nodes here from cp front end.
1624
1625 2020-09-17 Patrick Palka <ppalka@redhat.com>
1626
1627 PR c/80076
1628 * c-indentation.c (should_warn_for_misleading_indentation): Move
1629 declarations of local variables closer to their first use.
1630 Handle virtual token locations by resolving them to their
1631 respective macro expansion points. If all three tokens are
1632 produced from the same macro expansion, then instead use their
1633 loci within the macro definition.
1634
1635 2020-09-16 Martin Sebor <msebor@redhat.com>
1636
1637 PR c/78666
1638 PR c/96126
1639 * c-attribs.c (validate_attr_args): New function.
1640 (validate_attr_arg): Same.
1641 (handle_section_attribute): Call it. Introduce a local variable.
1642 (handle_alloc_size_attribute): Same.
1643 (handle_alloc_align_attribute): Same.
1644
1645 2020-09-14 Jakub Jelinek <jakub@redhat.com>
1646
1647 * c-attribs.c (handle_optimize_attribute): Adjust
1648 cl_optimization_save, cl_optimization_restore and
1649 build_optimization_node callers.
1650 * c-pragma.c (handle_pragma_optimize): Adjust
1651 build_optimization_node caller.
1652 (handle_pragma_push_options): Adjust
1653 build_optimization_node and build_target_option_node callers.
1654 (handle_pragma_pop_options, handle_pragma_reset_options):
1655 Adjust cl_optimization_restore callers.
1656
1657 2020-08-28 Martin Sebor <msebor@redhat.com>
1658
1659 * c.opt (Wstringop-overread): New option.
1660
1661 2020-08-11 Jakub Jelinek <jakub@redhat.com>
1662
1663 PR c/96545
1664 * c-common.c (get_atomic_generic_size): Require that first argument's
1665 type points to a complete type and use tree_fits_uhwi_p instead of
1666 just INTEGER_CST TREE_CODE check for the TYPE_SIZE_UNIT.
1667
1668 2020-07-31 Martin Sebor <msebor@redhat.com>
1669
1670 PR c++/96003
1671 * c-common.c (check_function_arguments_recurse): Return early when
1672 no-warning bit is set.
1673
1674 2020-07-31 Richard Biener <rguenther@suse.de>
1675
1676 PR debug/96383
1677 * c-common.h (c_common_finalize_early_debug): Declare.
1678 * c-common.c: Include debug.h.
1679 (c_common_finalize_early_debug): finalize_early_debug langhook
1680 implementation generating debug for extern declarations.
1681
1682 2020-07-27 Nathan Sidwell <nathan@acm.org>
1683
1684 * c-common.c (try_to_locate_new_include_insertion_point): Use
1685 strcmp, not pointer equality.
1686
1687 2020-07-25 Martin Sebor <msebor@redhat.com>
1688
1689 PR c++/96310
1690 * c-common.c (check_nonnull_arg): Print note only when warning was
1691 issued.
1692
1693 2020-07-22 Tobias Burnus <tobias@codesourcery.com>
1694
1695 * c-omp.c (c_finish_omp_critical): Check for no name but
1696 nonzero hint provided.
1697
1698 2020-07-20 Jason Merrill <jason@redhat.com>
1699
1700 * c-cppbuiltin.c (c_cpp_builtins): Update
1701 __cpp_nontype_template_args for C++20.
1702
1703 2020-07-20 Martin Sebor <msebor@redhat.com>
1704
1705 PR c/96249
1706 * c.opt: Remove stray text.
1707
1708 2020-07-14 Lewis Hyatt <lhyatt@gmail.com>
1709
1710 PR other/86904
1711 * c-indentation.c (should_warn_for_misleading_indentation): Get
1712 global tabstop from the new source.
1713 * c-opts.c (c_common_handle_option): Remove handling of -ftabstop, which
1714 is now a common option.
1715 * c.opt: Likewise.
1716
1717 2020-07-08 Eric Botcazou <ebotcazou@adacore.com>
1718
1719 * c.opt (Wscalar-storage-order): Add explicit variable.
1720
1721 2020-07-07 Nathan Sidwell <nathan@acm.org>
1722
1723 * c-opts.c (c_common_post_options): Add 'injecting' arg to
1724 cpp_read_main_file.
1725 (c_finish_options): Add linemap_line_start calls for builtin and cmd
1726 maps. Force token position to line_table's highest line.
1727 * c-ppoutput.c (print_line_1): Refactor, print line zero.
1728 (cb_define): Always increment source line.
1729
1730 2020-07-06 Martin Sebor <msebor@redhat.com>
1731
1732 PR c++/95984
1733 * c-common.c (check_function_nonnull): Avoid checking syntesized calls
1734 to stub lambda objects with null this pointer.
1735 (check_nonnull_arg): Handle C++ nullptr.
1736
1737 2020-07-02 Jason Merrill <jason@redhat.com>
1738 Jakub Jelinek <jakub@redhat.com>
1739
1740 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_consteval.
1741
1742 2020-06-30 Jakub Jelinek <jakub@redhat.com>
1743
1744 PR c++/95963
1745 * c-common.c (check_function_arguments_recurse): Don't crash on
1746 calls to internal functions.
1747
1748 2020-06-28 Martin Sebor <msebor@redhat.com>
1749
1750 PR c++/86568
1751 * c-common.c (struct nonnull_arg_ctx): Add members.
1752 (check_function_nonnull): Use nonnull_arg_ctx as argument. Handle
1753 C++ member functions specially. Consider the this pointer implicitly
1754 nonnull.
1755 (check_nonnull_arg): Use location of argument when available.
1756 (check_function_arguments): Use nonnull_arg_ctx as argument.
1757
1758 2020-06-27 Jakub Jelinek <jakub@redhat.com>
1759
1760 PR middle-end/95903
1761 * c-common.c (pointer_int_sum): Use TYPE_OVERFLOW_UNDEFINED instead of
1762 !TYPE_UNSIGNED check to see if we can apply distributive law and handle
1763 smaller precision intop operands separately.
1764
1765 2020-06-26 Marek Polacek <polacek@redhat.com>
1766
1767 * c-opts.c (c_common_init_options): Default to gnu++17.
1768
1769 2020-06-17 Jonathan Wakely <jwakely@redhat.com>
1770
1771 PR c/95378
1772 * c-common.c (get_atomic_generic_size): Check cv-qualifiers in
1773 pointer arguments.
1774
1775 2020-06-16 Jakub Jelinek <jakub@redhat.com>
1776
1777 * c-common.h (c_omp_check_loop_iv_exprs): Add an int argument.
1778 * c-omp.c (struct c_omp_check_loop_iv_data): Add maybe_nonrect and
1779 idx members.
1780 (c_omp_is_loop_iterator): New function.
1781 (c_omp_check_loop_iv_r): Use it. Add support for silent scanning
1782 if outer loop iterator is present. Perform duplicate checking through
1783 hash_set in the function rather than expecting caller to do that.
1784 Pass NULL instead of d->ppset to walk_tree_1.
1785 (c_omp_check_nonrect_loop_iv): New function.
1786 (c_omp_check_loop_iv): Use it. Fill in new members, allow
1787 non-rectangular loop forms, diagnose multiple associated loops with
1788 the same iterator. Pass NULL instead of &pset to walk_tree_1.
1789 (c_omp_check_loop_iv_exprs): Likewise.
1790
1791 2020-06-10 Martin Liska <mliska@suse.cz>
1792
1793 PR tree-optimization/92860
1794 * c-attribs.c (handle_optimize_attribute):
1795 Save global options and compare it after parsing of function
1796 attribute.
1797 * c-pragma.c (opt_stack::saved_global_options): New field.
1798 (handle_pragma_push_options): Save global_options.
1799 (handle_pragma_pop_options): Compare them after pop.
1800
1801 2020-06-09 Jakub Jelinek <jakub@redhat.com>
1802
1803 PR c/95580
1804 * c-pretty-print.c (c_pretty_printer::unary_expression): Handle the
1805 case when MEM_REF's first argument has type pointer to incomplete type.
1806
1807 2020-06-05 Jason Merrill <jason@redhat.com>
1808
1809 * c-pretty-print.c (pp_c_additive_expression): Handle negative
1810 operand to POINTER_PLUS_EXPR.
1811
1812 2020-06-04 Martin Sebor <msebor@redhat.com>
1813
1814 PR middle-end/10138
1815 PR middle-end/95136
1816 * c-attribs.c (append_access_attrs): Handle attr_access::none.
1817 (handle_access_attribute): Same.
1818
1819 2020-06-03 Mark Wielaard <mark@klomp.org>
1820
1821 * known-headers.cc (get_cp_stdlib_header_for_string_macro_name):
1822 New function.
1823 * known-headers.h (get_cp_stdlib_header_for_string_macro_name):
1824 New function declaration.
1825
1826 2020-06-03 Mark Wielaard <mark@klomp.org>
1827
1828 * known-headers.cc (get_string_macro_hint): New function.
1829 (get_stdlib_header_for_name): Use get_string_macro_hint.
1830 (get_c_stdlib_header_for_string_macro_name): New function.
1831 * known-headers.h (get_c_stdlib_header_for_string_macro_name):
1832 New function declaration.
1833
1834 2020-06-03 Tobias Burnus <tobias@codesourcery.com>
1835
1836 * c-common.h (c_omp_predetermined_mapping): Declare.
1837 * c-omp.c (c_omp_predetermined_mapping): New.
1838
1839 2020-05-22 Mark Wielaard <mark@klomp.org>
1840
1841 * known-headers.cc (get_stdlib_header_for_name): Add a new
1842 stdlib_hint array for stdbool and stdint.
1843
1844 2020-05-22 Mark Wielaard <mark@klomp.org>
1845
1846 * known-headers.cc (get_stdlib_header_for_name): Return
1847 "<stdbool.h>" for "bool", "true" or "false" when STDLIB_C and
1848 flag_isoc99.
1849
1850 2020-05-20 Nathan Sidwell <nathan@acm.org>
1851
1852 * c-common.c (try_to_locate_new_include_insertion_point): Revert change.
1853
1854 * c-common.c (try_to_locate_new_include_insertion_point): Use
1855 strcmp to compare filenames.
1856 * c-lex.c (init_c_lex): Move declaration to initialization.
1857 * c-opts.c (handle_deferred_opts): Move cpp_get_deps call into
1858 deferred count loop.
1859
1860 2020-05-15 Jason Merrill <jason@redhat.com>
1861
1862 * c-opts.c (set_std_cxx20): Set flag_coroutines.
1863
1864 2020-05-13 Jason Merrill <jason@redhat.com>
1865
1866 * c.opt (std=c++20): Make c++2a the alias.
1867 (std=gnu++20): Likewise.
1868 * c-common.h (cxx_dialect): Change cxx2a to cxx20.
1869 * c-opts.c: Adjust.
1870 * c-cppbuiltin.c: Adjust.
1871 * c-ubsan.c: Adjust.
1872 * c-warn.c: Adjust.
1873
1874 2020-05-12 Eric Botcazou <ebotcazou@adacore.com>
1875
1876 * c-ada-spec.c (dump_ads): Output pragma Warnings ("U"); on entry.
1877
1878 2020-05-08 Nathan Sidwell <nathan@acm.org>
1879
1880 Reimplement directives only processing.
1881 * c-ppoutput.c (token_streamer): Ne.
1882 (directives_only_cb): New. Swallow ...
1883 (print_lines_directives_only): ... this.
1884 (scan_translation_unit_directives_only): Reimplment using the
1885 published interface.
1886
1887 2020-05-07 Marek Polacek <polacek@redhat.com>
1888
1889 * c-format.c (badwords): Add "nonstatic".
1890
1891 202-05-07 Jakub Jelinek <jakub@redhat.com>
1892
1893 PR c/94968
1894 * c-common.c (speculation_safe_value_resolve_params): Return false if
1895 error_operand_p (val2).
1896 (resolve_overloaded_builtin) <case BUILT_IN_SPECULATION_SAFE_VALUE_N>:
1897 Remove extraneous semicolon.
1898
1899 2020-05-06 qing zhao <qing.zhao@oracle.com>
1900
1901 PR c/94230
1902 * c-indentation.c (get_visual_column): Add a hint to use the new
1903 -flarge-source-files option.
1904
1905 2020-05-05 Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
1906
1907 * c-attribs.c (handle_vector_size_attribute): Add attribute
1908 nonnull for argument args in order to silence warning of
1909 uninitialized variable usage. Since this is local to the
1910 compilation unit and thus cannot be checked at call sides by the
1911 compiler, added an assert statement in order to verify this.
1912
1913 2020-05-01 H.J. Lu <hongjiu.lu@intel.com>
1914
1915 PR target/93492
1916 * c-attribs.c (handle_patchable_function_entry_attribute): Limit
1917 value to USHRT_MAX (65535).
1918
1919 2020-04-29 Jakub Jelinek <jakub@redhat.com>
1920
1921 * c-format.c (PP_FORMAT_CHAR_TABLE): Add %{ and %}.
1922
1923 2020-04-27 Jakub Jelinek <jakub@redhat.com>
1924
1925 PR c/94755
1926 * c-common.c (resolve_overloaded_builtin): Return error_mark_node for
1927 fncode == BUILT_IN_NONE before initialization of first_param.
1928
1929 2020-04-23 Marek Polacek <polacek@redhat.com>
1930
1931 PR c++/94733
1932 * c-attribs.c (find_tm_attribute): Use get_attribute_name instead of
1933 TREE_PURPOSE.
1934
1935 2020-04-14 Patrick Palka <ppalka@redhat.com>
1936
1937 PR c++/85278
1938 * c-pretty-print.c (pp_c_pointer) <case REFERENCE_TYPE>: Print a double
1939 ampersand if it's an rvalue reference type.
1940
1941 2020-04-13 Martin Sebor <msebor@redhat.com>
1942
1943 PR c/92326
1944 * c-pretty-print.c (c_pretty_printer::direct_abstract_declarator): Avoid
1945 printing array bound for flexible array members.
1946
1947 2020-04-13 Iain Sandoe <iain@sandoe.co.uk>
1948
1949 * c-cppbuiltin.c (c_cpp_builtins): Update coroutines builtin
1950 define, per n4861.
1951
1952 2020-04-02 Richard Biener <rguenther@suse.de>
1953
1954 PR c/94392
1955 * c-opts.c (c_common_post_options): Enable -ffinite-loops
1956 for -O2 and C++11 or newer.
1957
1958 2020-03-28 Patrick Palka <ppalka@redhat.com>
1959
1960 * c.opt: Add -fconcepts-diagnostics-depth.
1961
1962 2020-03-27 Martin Sebor <msebor@redhat.com>
1963
1964 PR c++/94346
1965 * c-attribs.c (handle_copy_attribute): Avoid passing expressions
1966 to decl_attributes. Make handling of different kinds of entities
1967 more robust.
1968
1969 2020-03-27 Martin Sebor <msebor@redhat.com>
1970
1971 PR c++/94098
1972 * c-attribs.c (handle_access_attribute): Avoid setting TYPE_ATTRIBUTES
1973 here.
1974
1975 2020-03-23 Jakub Jelinek <jakub@redhat.com>
1976
1977 PR c++/91993
1978 * c-warn.c (warnings_for_convert_and_check): For expr and/or
1979 result being COMPOUND_EXPRs, skip to ultimate rhs.
1980
1981 2020-03-20 Richard Sandiford <richard.sandiford@arm.com>
1982
1983 PR middle-end/94072
1984 * c-common.c (c_common_type_for_mode): Before using a registered
1985 built-in type, check that the vectorness of the type matches
1986 the vectorness of the mode.
1987
1988 2020-03-17 Jakub Jelinek <jakub@redhat.com>
1989
1990 * c-common.c (resolve_overloaded_builtin): Fix up duplicated word
1991 issue in a diagnostic message.
1992
1993 2020-03-15 Lewis Hyatt <lhyatt@gmail.com>
1994
1995 * c.opt: Avoid redundancy in the help text.
1996
1997 2020-03-02 Marek Polacek <polacek@redhat.com>
1998
1999 PR c++/93958 - add missing -std=gnu++20.
2000 * c.opt: Add -std=gnu++20.
2001
2002 2020-03-01 Martin Sebor <msebor@redhat.com>
2003
2004 PR c++/92721
2005 * c-attribs.c (append_access_attrs): Correctly handle attribute.
2006 (handle_access_attribute): Same.
2007
2008 2020-02-25 Jakub Jelinek <jakub@redhat.com>
2009
2010 PR c/93858
2011 * c-pragma.c (handle_pragma_diagnostic): Add missing ? after
2012 "did you mean" hint in diagnostics.
2013
2014 2020-02-15 Jason Merrill <jason@redhat.com>
2015
2016 * c.opt: Add -std=c++20.
2017
2018 2020-02-14 Eric Botcazou <ebotcazou@adacore.com>
2019
2020 * c-ada-spec.c: Include bitmap.h.
2021 (dump_ada_double_name): Rename into...
2022 (dump_anonymous_type_name): ...this. Always use the TYPE_UID.
2023 (dump_ada_array_type): Adjust to above renaming. Robustify.
2024 (dump_nested_types_1): New function copied from... Add dumped_types
2025 parameter and pass it down to dump_nested_type.
2026 (dump_nested_types): ...this. Remove parent parameter. Just call
2027 dump_nested_types_1 on an automatic bitmap.
2028 (dump_nested_type): Add dumped_types parameter.
2029 <ARRAY_TYPE>: Do not dump it if already present in dumped_types.
2030 Adjust recursive calls and adjust to above renaming.
2031 (dump_ada_declaration): Adjust call to dump_nested_types.
2032 Tidy up and adjust to above renaming.
2033 (dump_ada_specs): Initialize and release bitmap obstack.
2034
2035 2020-02-10 Martin Sebor <msebor@redhat.com>
2036
2037 PR c/93640
2038 * c-attribs.c (handle_access_attribute): Correct off-by-one mistakes.
2039
2040 2020-02-10 Jakub Jelinek <jakub@redhat.com>
2041
2042 PR other/93641
2043 * c-format.c (check_plain): Fix up last argument of strncasecmp.
2044 Remove useless extra test.
2045
2046 2020-02-03 Julian Brown <julian@codesourcery.com>
2047 Tobias Burnus <tobias@codesourcery.com>
2048
2049 * c-cppbuiltin.c (c_cpp_builtins): Update _OPENACC define to 201711.
2050
2051 2020-01-29 Jason Merrill <jason@redhat.com>
2052
2053 PR c++/89357
2054 * c-attribs.c (check_cxx_fundamental_alignment_constraints): Remove.
2055
2056 2020-01-23 Jason Merrill <jason@redhat.com>
2057
2058 * c-warn.c (conversion_warning): Change -Wsign-conversion handling.
2059
2060 2020-01-23 Martin Sebor <msebor@redhat.com>
2061
2062 PR c/84919
2063 * c-common.c (check_function_arguments): Avoid overlap checking
2064 of sprintf functions.
2065
2066 2020-01-22 Jason Merrill <jason@redhat.com>
2067
2068 PR testsuite/93391 - PR 40752 test fails with unsigned plain char.
2069 PR c++/40752
2070 * c-warn.c (conversion_warning): Check operands only after checking
2071 the whole expression. Don't check second operand of + for sign.
2072
2073 2020-01-21 Jason Merrill <jason@redhat.com>
2074 Manuel López-Ibáñez <manu@gcc.gnu.org>
2075
2076 PR c++/40752 - useless -Wconversion with short +=.
2077 * c.opt (-Warith-conversion): New.
2078 * c-warn.c (conversion_warning): Recurse for operands of
2079 operators. Only warn about the whole expression with
2080 -Warith-conversion.
2081
2082 2020-01-21 Jason Merrill <jason@redhat.com>
2083
2084 * c-common.c (unsafe_conversion_p): Don't warn, return UNSAFE_SIGN.
2085 * c-warn.c (conversion_warning): Warn about UNSAFE_SIGN.
2086
2087 2020-01-20 Nathan Sidwell <nathan@acm.org>
2088
2089 PR preprocessor/80005
2090 * c-cppbuiltins.c (c_cpp_builtins): Don't define __has_include{,_next}.
2091
2092 2020-01-18 Iain Sandoe <iain@sandoe.co.uk>
2093
2094 * c-common.c (co_await, co_yield, co_return): New.
2095 * c-common.h (RID_CO_AWAIT, RID_CO_YIELD,
2096 RID_CO_RETURN): New enumeration values.
2097 (D_CXX_COROUTINES): Bit to identify coroutines are active.
2098 (D_CXX_COROUTINES_FLAGS): Guard for coroutine keywords.
2099 * c-cppbuiltin.c (__cpp_coroutines): New cpp define.
2100 * c.opt (fcoroutines): New command-line switch.
2101
2102 2020-01-10 David Malcolm <dmalcolm@redhat.com>
2103
2104 * c-format.c (local_event_ptr_node): New.
2105 (PP_FORMAT_CHAR_TABLE): Add entry for "%@".
2106 (init_dynamic_diag_info): Initialize local_event_ptr_node.
2107 * c-format.h (T_EVENT_PTR): New define.
2108
2109 2020-01-10 Martin Sebor <msebor@redhat.com>
2110
2111 PR c/93132
2112 * c-attribs.c (append_access_attrs): Validate against the translated
2113 access string rather than the human-readable representation.
2114
2115 2020-01-01 Jakub Jelinek <jakub@redhat.com>
2116
2117 Update copyright years.
2118
2119 2019-12-20 Eric Botcazou <ebotcazou@adacore.com>
2120
2121 * c-ada-spec.h (decl_sloc): Delete.
2122 * c-ada-spec.c (decl_sloc): Make static.
2123
2124 2019-12-19 Julian Brown <julian@codesourcery.com>
2125
2126 * c-common.h (c_omp_map_clause_name): Add prototype.
2127 * c-omp.c (c_omp_map_clause_name): New function.
2128 * c-pragma.h (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ATTACH and
2129 PRAGMA_OACC_CLAUSE_DETACH.
2130
2131 2019-12-19 Julian Brown <julian@codesourcery.com>
2132 Maciej W. Rozycki <macro@codesourcery.com>
2133 Tobias Burnus <tobias@codesourcery.com>
2134 Thomas Schwinge <thomas@codesourcery.com>
2135
2136 * c-pragma.h (pragma_omp_clause): Add
2137 PRAGMA_OACC_CLAUSE_NO_CREATE.
2138
2139 2019-12-17 Martin Sebor <msebor@redhat.com>
2140
2141 PR c++/61339
2142 * c.opt (-Wmismatched-tags, -Wredundant-tags): New options.
2143
2144 2019-12-11 David Malcolm <dmalcolm@redhat.com>
2145
2146 * c-pretty-print.c (c_pretty_printer::clone): New vfunc
2147 implementation.
2148 * c-pretty-print.h (c_pretty_printer::clone): New vfunc decl.
2149
2150 2019-12-09 David Malcolm <dmalcolm@redhat.com>
2151
2152 * c-format.c (range_label_for_format_type_mismatch::get_text):
2153 Replace label_text ctor called with true with label_text::take.
2154
2155 2019-12-09 David Malcolm <dmalcolm@redhat.com>
2156
2157 * c-format.c (selftest::test_type_mismatch_range_labels): Remove
2158 initial newline from expected outputs.
2159 * c-opts.c (c_diagnostic_finalizer): Add pp_newline call before
2160 call to diagnostic_show_locus.
2161
2162 2019-12-06 Jakub Jelinek <jakub@redhat.com>
2163
2164 * c-cppbuiltin.c (c_cpp_builtins): Don't define __cpp_consteval for
2165 now.
2166
2167 2019-12-05 Marek Polacek <polacek@redhat.com>
2168 Jakub Jelinek <jakub@redhat.com>
2169
2170 PR c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.
2171 * c-cppbuiltin.c (c_cpp_builtins): Adjust the value of __cpp_constexpr.
2172
2173 2019-12-05 Marek Polacek <polacek@redhat.com>
2174
2175 PR c++/92271 - make __is_same alias for __is_same_as.
2176 * c-common.c: Add __is_same, an alias for __is_same_as.
2177
2178 2019-12-03 Marek Polacek <polacek@redhat.com>
2179
2180 PR c++/91363 - P0960R3: Parenthesized initialization of aggregates.
2181 * c-cppbuiltin.c (c_cpp_builtins): Predefine
2182 __cpp_aggregate_paren_init=201902 for -std=c++2a.
2183
2184 2019-11-30 Jan Hubicka <hubicka@ucw.cz>
2185
2186 * c-attribs.c (handle_symver_attribute): New function
2187 (c_common_attributes): Add symver.
2188
2189 2019-11-30 Richard Sandiford <richard.sandiford@arm.com>
2190
2191 * c-common.c (pointer_int_sum): Use verify_type_context to check
2192 whether the target allows pointer arithmetic for the types involved.
2193 (c_sizeof_or_alignof_type, c_alignof_expr): Use verify_type_context
2194 to check whether the target allows sizeof and alignof operations
2195 for the types involved.
2196
2197 2019-11-27 Jason Merrill <jason@redhat.com>
2198
2199 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
2200
2201 2019-11-26 Jakub Jelinek <jakub@redhat.com>
2202
2203 PR c++/61414
2204 * c-attribs.c (handle_mode_attribute): Add mode attribute to
2205 ENUMERAL_TYPEs.
2206
2207 2019-11-25 Joseph Myers <joseph@codesourcery.com>
2208
2209 PR c/91985
2210 * c-common.c (c_common_type_for_mode): Handle decimal
2211 floating-point types being NULL_TREE.
2212 * c-format.c (get_format_for_type_1): Handle specified types being
2213 NULL_TREE.
2214 * c-lex.c (interpret_float): Give an error for decimal
2215 floating-point constants when decimal floating-point not
2216 supported.
2217
2218 2019-11-23 Jakub Jelinek <jakub@redhat.com>
2219
2220 PR middle-end/83859
2221 * c-attribs.c (append_access_attrs): Avoid buffer overflow. Avoid
2222 memory leak. Use XNEWVEC macro. Use auto_diagnostic_group to
2223 group warning with inform together.
2224 (handle_access_attribute): Formatting fix.
2225
2226 2019-11-22 Jakub Jelinek <jakub@redhat.com>
2227
2228 PR c/90677
2229 * c-common.h (identifier_global_tag): Declare.
2230 * c-format.c (get_pointer_to_named_type): Renamed to ...
2231 (get_named_type): ... this. Use identifier_global_tag instead of
2232 identifier_global_value, handle the return value being a TYPE_P.
2233 (init_dynamic_diag_info): Adjust get_pointer_to_named_type callers
2234 to call get_named_type instead. Formatting fixes.
2235
2236 Implement P1902R1, Missing feature-test macros 2017-2019.
2237 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_init_captures
2238 and __cpp_generic_lambdas for -std=c++2a. Define
2239 __cpp_designated_initializers, __cpp_constexpr_in_decltype and
2240 __cpp_consteval for -std=c++2a. Remove a FIXME comment about
2241 __cpp_concepts for -std=c++2a.
2242
2243 2019-11-22 Martin Sebor <msebor@redhat.com>
2244
2245 PR middle-end/83859
2246 * c-attribs.c (handle_access_attribute): New function.
2247 (c_common_attribute_table): Add new attribute.
2248 (get_argument_type): New function.
2249 (append_access_attrs): New function.
2250 (get_nonnull_operand): Rename...
2251 (get_attribute_operand): ...to this.
2252 * c-common.c (get_nonnull_operand): Rename...
2253 (get_attribute_operand): ...to this.
2254
2255 2019-11-21 Joseph Myers <joseph@codesourcery.com>
2256
2257 * c-attribs.c (handle_fallthrough_attribute): Use pedwarn instead
2258 of warning.
2259
2260 2019-11-19 Joseph Myers <joseph@codesourcery.com>
2261
2262 * c-common.c (attribute_fallthrough_p): In C, use pedwarn not
2263 warning for standard attributes mixed with fallthrough attributes.
2264
2265 2019-11-15 Joseph Myers <joseph@codesourcery.com>
2266
2267 * c-attribs.c (handle_fallthrough_attribute): Remove static.
2268 * c-common.h (handle_fallthrough_attribute): Declare.
2269
2270 2019-11-15 Joseph Myers <joseph@codesourcery.com>
2271
2272 * c-attribs.c (handle_deprecated_attribute): Remove static.
2273 * c-common.h (handle_deprecated_attribute): Declare.
2274
2275 2019-11-14 Joseph Myers <joseph@codesourcery.com>
2276
2277 * c-lex.c (lex_charconst): Make CPP_UTF8CHAR constants unsigned
2278 char for C.
2279
2280 2019-11-14 Jakub Jelinek <jakub@redhat.com>
2281
2282 * c-omp.c (c_omp_check_context_selector): Add nvidia to the list of
2283 valid vendors.
2284
2285 * c-omp.c (c_omp_check_context_selector): Handle name lists
2286 containing string literals. Don't diagnose atomic_default_mem_order
2287 with multiple props.
2288
2289 2019-11-13 Joseph Myers <joseph@codesourcery.com>
2290
2291 * c-cppbuiltin.c (builtin_define_float_constants): Also define
2292 NORM_MAX constants. Update call to get_max_float.
2293 (LAZY_HEX_FP_VALUES_CNT): Update value to include NORM_MAX
2294 constants.
2295
2296 2019-11-13 Eric Botcazou <ebotcazou@adacore.com>
2297
2298 * c-ada-spec.c (get_underlying_decl): Do not look through typedefs.
2299 (dump_forward_type): Do not generate a declaration for function types.
2300 (dump_nested_type) <ARRAY_TYPE>: Do not generate a nested declaration
2301 of the component type if it is declared in another file.
2302
2303 2019-11-12 Martin Liska <mliska@suse.cz>
2304
2305 * c-opts.c (c_common_post_options):
2306 Use SET_OPTION_IF_UNSET.
2307
2308 2019-11-12 Maciej W. Rozycki <macro@codesourcery.com>
2309 Frederik Harwath <frederik@codesourcery.com>
2310
2311 gcc/c-family/
2312 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_SERIAL enumeration
2313 constant.
2314 * c-pragma.c (oacc_pragmas): Add "serial" entry.
2315
2316 2019-11-08 Richard Sandiford <richard.sandiford@arm.com>
2317
2318 * c-common.h (gnu_vector_type_p): New function.
2319 * c-common.c (c_build_vec_perm_expr): Require __builtin_shuffle
2320 vectors to satisfy gnu_vector_type_p.
2321 (c_build_vec_convert): Likewise __builtin_convertvector.
2322 (convert_vector_to_array_for_subscript): Likewise when applying
2323 implicit vector to array conversion.
2324 (scalar_to_vector): Likewise when converting vector-scalar
2325 operations to vector-vector operations.
2326
2327 2019-11-08 Joseph Myers <joseph@codesourcery.com>
2328
2329 * c.opt (Wold-style-definition): Initialize to -1.
2330 * c-opts.c (c_common_post_options): Set warn_old_style_definition
2331 to flag_isoc2x if not set explicitly.
2332
2333 2019-11-07 Joseph Myers <joseph@codesourcery.com>
2334
2335 * c-attribs.c (parse_tm_stmt_attr): Handle scoped attributes.
2336
2337 2019-11-05 Jason Merrill <jason@redhat.com>
2338
2339 * c-opts.c (c_common_post_options): -fconcepts-ts implies
2340 -fconcepts.
2341
2342 2019-11-04 Kamlesh Kumar <kamleshbhalui@gmail.com>
2343
2344 * c-opts.c (c_common_post_options): Update
2345 latest_abi_version.
2346
2347 2019-11-02 Jakub Jelinek <jakub@redhat.com>
2348
2349 * c-common.h (c_omp_get_context_selector): Remove.
2350 * c-omp.c (c_omp_get_context_selector): Moved to omp-general.c
2351 and renamed to omp_get_context_selector.
2352
2353 * c-omp.c (c_omp_mark_declare_variant): Use
2354 omp_context_selector_set_compare.
2355
2356 PR c++/88335 - Implement P1073R3: Immediate functions
2357 * c-common.h (enum rid): Add RID_CONSTEVAL.
2358 * c-common.c (c_common_reswords): Add consteval.
2359
2360 2019-11-01 Martin Sebor <msebor@redhat.com>
2361
2362 PR middle-end/91679
2363 PR middle-end/91647
2364 PR middle-end/91463
2365 PR middle-end/92312
2366 * c-pretty-print.c (direct_abstract_declarator): Print
2367 bound in zero-length arrays.
2368 * c.opt (-Wzero-length-bounds): New option.
2369
2370 2019-10-30 Nathan Sidwell <nathan@acm.org>
2371
2372 * c-cppbuiltin.c (c_cpp_builtins): Add 'L' suffix to feature
2373 macros.
2374
2375 2019-10-28 Martin Sebor <msebor@redhat.com>
2376
2377 PR c/66970
2378 * c-common.c (c_common_nodes_and_builtins): Call c_define_builtins
2379 even when only preprocessing.
2380 * c-common.h (names_builtin_p): Declare new function.
2381 * c-lex.c (init_c_lex): Set has_builtin.
2382 (c_common_has_builtin): Define a new function.
2383 * c-ppoutput.c (init_pp_output): Set has_builtin.
2384
2385 2019-10-24 Jakub Jelinek <jakub@redhat.com>
2386
2387 * c-common.h (c_omp_context_selector_matches): Remove.
2388 * c-omp.c (c_omp_context_selector_matches): Remove.
2389 * c-attribs.c (c_common_attribute_table): Add
2390 "omp declare target {host,nohost,block}" attributes.
2391
2392 2019-10-17 JeanHeyd Meneide <phdofthehouse@gmail.com>
2393
2394 * c-lex.c (c_common_has_attribute): Update nodiscard value.
2395
2396 2019-10-14 Richard Sandiford <richard.sandiford@arm.com>
2397
2398 * c-common.h (user_facing_original_type_p): Declare.
2399 * c-common.c: Include c-spellcheck.h.
2400 (user_facing_original_type_p): New function.
2401
2402 2019-10-12 Jakub Jelinek <jakub@redhat.com>
2403
2404 * c-common.h (c_omp_mark_declare_variant,
2405 c_omp_context_selector_matches): Declare.
2406 * c-omp.c: Include attribs.h, gimplify.h, cgraph.h, symbol-summary.h
2407 and hsa-common.h.
2408 (c_omp_get_context_selector): Support second argument NULL.
2409 (c_omp_mark_declare_variant, c_omp_context_selector_matches): New
2410 functions.
2411 * c-attribs.c (c_common_attribute_table): Remove "omp declare variant"
2412 attribute, add "omp declare variant base" and
2413 "omp declare variant variant" attributes.
2414
2415 2019-10-11 Joseph Myers <joseph@codesourcery.com>
2416
2417 * c.opt (Wc11-c2x-compat): Add CPP(cpp_warn_c11_c2x_compat)
2418 CppReason(CPP_W_C11_C2X_COMPAT).
2419
2420 2019-10-11 Joseph Myers <joseph@codesourcery.com>
2421
2422 * c-common.c (c_common_reswords): Do not use D_EXT for _Decimal32,
2423 _Decimal64 and _Decimal128.
2424
2425 2019-10-10 Joseph Myers <joseph@codesourcery.com>
2426
2427 * c-cppbuiltin.c (c_cpp_builtins): Do not define macros for DFP
2428 types if DFP not supported.
2429
2430 2019-10-10 Jakub Jelinek <jakub@redhat.com>
2431
2432 * c-common.h (c_omp_check_context_selector,
2433 c_omp_get_context_selector): Declare.
2434 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): Fix spelling
2435 in diagnostic message.
2436 (c_omp_check_context_selector, c_omp_get_context_selector): New
2437 functions.
2438 * c-attribs.c (c_common_attribute_table): Add "omp declare variant"
2439 attribute.
2440 (handle_omp_declare_variant_attribute): New function.
2441
2442 2019-10-09 Martin Sebor <msebor@redhat.com>
2443
2444 PR tree-optimization/90879
2445 * c.opt (-Wstring-compare): New option.
2446
2447 2019-10-08 Andrew Sutton <asutton@lock3software.com>
2448 Jason Merrill <jason@redhat.com>
2449
2450 Update the concepts implementation to conform to the C++20
2451 specification, improve compile times, and generally clean up
2452 the implementation.
2453
2454 * c-cppbuiltin.c (c_cpp_builtins): Use new feature test values for
2455 concepts when -std=c++2a. Bump __cpp_concepts to 201907.
2456 * c.opt: Add -Wconcepts-ts.
2457 * c-opts.c (c_common_post_options): Warn when -fconcepts is used
2458 with -std=c++2a. Disable warning for -fconcepts in C++20 mode.
2459 (set_std_cxx2a): Enable concepts by default.
2460
2461 2019-10-08 Joseph Myers <joseph@codesourcery.com>
2462
2463 * c-opts.c (c_common_post_options): Set
2464 -fno-fp-int-builtin-inexact for C2X.
2465
2466 2019-10-05 Jakub Jelinek <jakub@redhat.com>
2467
2468 PR c++/91369 - Implement P0784R7: constexpr new
2469 * c-cppbuiltin.c (c_cpp_builtins): Predefine
2470 __cpp_constexpr_dynamic_alloc=201907 for -std=c++2a.
2471
2472 2019-10-04 Joseph Myers <joseph@codesourcery.com>
2473
2474 PR c/82752
2475 * c-format.c (C_STD_VER): Handle C2x.
2476 (C_STD_NAME): Likewise.
2477 (strftime_flag_specs): Add 'O' modifier with 'p' flag.
2478 (time_char_table): Use separate entry for 'B' and 'b', with 'O'
2479 modifier allowed and 'p' flag.
2480 * c-format.h (enum format_std_version): Add STD_C2X.
2481 (struct format_char_info): Mention 'p' in comment on flags2.
2482
2483 2019-10-01 David Malcolm <dmalcolm@redhat.com>
2484
2485 * c-opts.c (c_diagnostic_finalizer): Temporarily clear prefix when
2486 calling diagnostic_show_locus, rather than destroying it afterwards.
2487
2488 2019-10-01 Jakub Jelinek <jakub@redhat.com>
2489
2490 PR c++/91925
2491 * c-warn.c (check_alignment_of_packed_member): Ignore FIELD_DECLs
2492 with NULL DECL_FIELD_OFFSET.
2493
2494 2019-10-01 Richard Sandiford <richard.sandiford@arm.com>
2495
2496 * c-pretty-print.c (pp_c_specifier_qualifier_list): If a vector type
2497 has a type name, use it in preference to the __vector syntax.
2498
2499 2019-09-30 Richard Sandiford <richard.sandiford@arm.com>
2500
2501 * c-pretty-print.c (pp_c_parameter_type_list): Avoid printing
2502 two spaces between a comma and "...".
2503
2504 2019-09-27 Jakub Jelinek <jakub@redhat.com>
2505
2506 PR c++/88203
2507 * c-common.h (c_omp_predefined_variable): Declare.
2508 * c-omp.c (c_omp_predefined_variable): New function.
2509 (c_omp_predetermined_sharing): Return OMP_CLAUSE_DEFAULT_SHARED
2510 for predefined variables.
2511
2512 2019-09-27 Richard Sandiford <richard.sandiford@arm.com>
2513
2514 * c-common.h (build_function_call_vec): Take the original
2515 function decl as an optional final parameter.
2516 (check_builtin_function_arguments): Take the original function decl.
2517 * c-common.c (check_builtin_function_arguments): Likewise.
2518 Handle all built-in functions, not just BUILT_IN_NORMAL ones.
2519 Use targetm.check_builtin_call to check BUILT_IN_MD functions.
2520
2521 2019-09-15 Jason Merrill <jason@redhat.com>
2522
2523 * c-warn.c (warn_logical_operator): Strip location wrappers. Don't
2524 fold_for_warn in "|| mask" warning.
2525
2526 2019-09-10 Martin Liska <mliska@suse.cz>
2527
2528 * c.opt: Use newly added WarnRemoved.
2529
2530 2019-09-09 Martin Liska <mliska@suse.cz>
2531
2532 * c.opt: Update comment of removed
2533 options that are preserved only for backward
2534 compatibility.
2535
2536 2019-09-06 Martin Liska <mliska@suse.cz>
2537
2538 PR c++/91125
2539 * c-common.c: Remove definition of flag_use_repository.
2540 * c-common.h: Likewise.
2541 * c-opts.c (c_common_handle_option):
2542 Do not handle OPT_frepo option.
2543 * c.opt: Mark the option with Deprecated.
2544
2545 2019-09-04 Marek Polacek <polacek@redhat.com>
2546
2547 * c.opt (fdeduce-init-list): Ignored.
2548
2549 2019-09-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2550
2551 PR c/78736
2552 * c.opt (Wenum-conversion): New option.
2553
2554 2019-09-03 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2555
2556 * c-attribs.c (handle_section_attribute): Call the
2557 handle_generic_attribute target hook after performing target
2558 independent processing.
2559 (handle_noinit_attribute): Likewise.
2560
2561 2019-09-03 Ian Lance Taylor <iant@golang.org>
2562
2563 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Always expand
2564 when using -fgo-dump-spec.
2565
2566 2019-09-02 Martin Liska <mliska@suse.cz>
2567
2568 PR c++/91155
2569 * c-common.c (fname_as_string): Use cxx_printable_name for
2570 __PRETTY_FUNCTION__ same as was used before r265711.
2571
2572 2019-08-28 Marek Polacek <polacek@redhat.com>
2573
2574 Implement P1152R4: Deprecating some uses of volatile.
2575 PR c++/91361
2576 * c-opts.c (c_common_post_options): Enable -Wvolatile by
2577 default for C++2a, unless -Wno-deprecated.
2578 * c.opt (Wvolatile): New warning.
2579
2580 2019-08-28 Marek Polacek <polacek@redhat.com>
2581
2582 PR c++/91360 - Implement C++20 P1143R2: constinit.
2583 * c-common.c (c_common_reswords): Add constinit and __constinit.
2584 (keyword_is_decl_specifier): Handle RID_CONSTINIT.
2585 * c-common.h (enum rid): Add RID_CONSTINIT, RID_FIRST_CXX20, and
2586 RID_LAST_CXX20.
2587 (D_CXX20): Define.
2588 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_constinit.
2589 * c-format.c (cxx_keywords): Add "constinit".
2590 * c.opt (Wc++2a-compat, Wc++20-compat): New options.
2591
2592 2019-08-27 Jakub Jelinek <jakub@redhat.com>
2593
2594 PR c++/91415
2595 * c-common.c (verify_tree): For LSHIFT_EXPR, RSHIFT_EXPR,
2596 COMPONENT_REF and ARRAY_REF in cxx_dialect >= cxx17 mode handle it
2597 like COMPOUND_EXPR rather than normal expression.
2598
2599 2019-08-23 Iain Sandoe <iain@sandoe.co.uk>
2600
2601 PR pch/61250
2602 * c-lex.c (c_lex_with_flags): Don't call
2603 c_common_no_more_pch () from here.
2604
2605 2019-08-23 Jakub Jelinek <jakub@redhat.com>
2606
2607 PR middle-end/91283
2608 * c-common.c (c_ts18661_flt_eval_method): Use flag_excess_precision
2609 instead of flag_excess_precision_cmdline.
2610 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): Likewise.
2611 * c-opts.c (c_common_post_options): Likewise.
2612
2613 2019-08-22 Martin Sebor <msebor@redhat.com>
2614
2615 PR middle-end/91490
2616 * c-common.c (braced_list_to_string): Add argument and overload.
2617 Handle flexible length arrays and unions.
2618
2619 2019-08-21 Eric Botcazou <ebotcazou@adacore.com>
2620
2621 * c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
2622 function declarations where arguments are missing. Rename variables.
2623
2624 2019-08-15 Richard Biener <rguenther@suse.de>
2625
2626 * c-common.c (c_stddef_cpp_builtins): When the GIMPLE FE is
2627 enabled, define __SIZETYPE__.
2628
2629 2019-08-14 Christophe Lyon <christophe.lyon@linaro.org>
2630
2631 * c-attribs.c (c_common_attribute_table): Add "noinit" entry. Add
2632 exclusion with "section" attribute.
2633 (attr_noinit_exclusions): New table.
2634 (handle_noinit_attribute): New function.
2635
2636 2019-08-13 Richard Sandiford <richard.sandiford@arm.com>
2637
2638 PR middle-end/91421
2639 * c-common.c (resolve_overloaded_builtin): Use
2640 copy_decl_built_in_function.
2641
2642 2019-08-13 Martin Sebor <msebor@redhat.com>
2643
2644 PR c/80619
2645 * c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
2646 (asm_fprintf_length_spec): Same.
2647 * c-format.h (format_lengths): Add FMT_LEN_w.
2648
2649 2019-08-10 Jakub Jelinek <jakub@redhat.com>
2650
2651 * c-pragma.h (enum pragma_omp_clause): Add
2652 PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
2653
2654 2019-08-07 Jakub Jelinek <jakub@redhat.com>
2655
2656 * c-pragma.h (enum pragma_omp_clause): Add
2657 PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. Set PRAGMA_OACC_CLAUSE_USE_DEVICE
2658 equal to PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR instead of being a separate
2659 enumeration value.
2660
2661 2019-08-05 Marek Polacek <polacek@redhat.com>
2662
2663 PR c++/91338 - Implement P1161R3: Deprecate a[b,c].
2664 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
2665 default for C++2a, unless -Wno-deprecated.
2666 * c.opt (Wcomma-subscript): New warning.
2667
2668 2019-07-20 Jakub Jelinek <jakub@redhat.com>
2669
2670 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_LOOP.
2671 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_BIND.
2672 * c-pragma.c (omp_pragmas_simd): Add PRAGMA_OMP_LOOP entry.
2673 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_LOOP.
2674 * c-omp.c (c_omp_split_clauses): Add support for 4 new combined
2675 constructs with the loop construct.
2676
2677 2019-07-13 Jakub Jelinek <jakub@redhat.com>
2678
2679 PR c/91149
2680 * c-omp.c (c_omp_split_clauses): Fix a pasto in
2681 OMP_CLAUSE_REDUCTION_TASK handling.
2682
2683 2019-07-12 Jakub Jelinek <jakub@redhat.com>
2684
2685 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ORDER.
2686 * c-omp.c (c_omp_split_clauses): Handle splitting of OMP_CLAUSE_ORDER.
2687
2688 2019-07-09 Martin Sebor <msebor@redhat.com>
2689
2690 PR c++/61339
2691 * c-opts.c (handle_deferred_opts): Change class-key of PODs to struct
2692 and others to class.
2693 * c-pretty-print.h: Same.
2694
2695 2019-07-09 Martin Sebor <msebor@redhat.com>
2696
2697 PR c++/61339
2698 * c-format.c (check_argument_type): Change class-key from class to
2699 struct and vice versa to match convention and avoid -Wclass-is-pod
2700 and -Wstruct-no-pod.
2701 * c-pretty-print.h: Same.
2702
2703 2019-07-03 Martin Liska <mliska@suse.cz>
2704
2705 * c-common.c (try_to_locate_new_include_insertion_point): Remove
2706 dead assignemts.
2707
2708 2019-07-03 Jakub Jelinek <jakub@redhat.com>
2709
2710 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_REDUCTION_INSCAN
2711 clauses on OMP_FOR rather than OMP_PARALLEL when OMP_FOR is combined
2712 with OMP_PARALLEL.
2713
2714 2019-07-02 qing zhao <qing.zhao@oracle.com>
2715
2716 PR preprocessor/90581
2717 * c-opts.c (c_common_handle_option): Handle -fmax-include-depth.
2718 * c.opt: Add new option -fmax-include-depth.
2719
2720 2019-06-26 Jason Merrill <jason@redhat.com>
2721
2722 PR c++/55442 - memory-hog with highly recursive constexpr.
2723 * c.opt (fconstexpr-loop-limit): New.
2724
2725 2019-06-25 Jakub Jelinek <jakub@redhat.com>
2726
2727 PR sanitizer/90954
2728 * c-omp.c (c_finish_omp_atomic): Allow tree_invariant_p in addition
2729 to SAVE_EXPR in first operand of a COMPOUND_EXPR.
2730
2731 2019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2732
2733 * c-common.c (c_common_nodes_and_builtins): Define
2734 alternate "__intN__" name for "__intN" types.
2735
2736 2019-06-24 Jan Hubicka <jh@suse.cz>
2737
2738 * c-common.c (braced_lists_to_strings): Check that
2739 type is array or integer prior checking string flag.
2740
2741 2019-06-21 Matthew Beliveau <mbelivea@redhat.com>
2742
2743 PR c++/90875 - added -Wswitch-outside-range option
2744 * c.opt (Wswitch-outside-range): Added new option.
2745 * c-warn.c (c_do_switch_warnings): Use OPT_Wswitch-outside-range.
2746
2747 2019-06-21 Marek Polacek <polacek@redhat.com>
2748
2749 PR c++/90953 - ICE with -Wmissing-format-attribute.
2750 * c-common.c (check_function_arguments_recurse): Use
2751 get_attribute_name.
2752 (check_missing_format_attribute): Likewise.
2753
2754 2019-06-19 Marek Polacek <polacek@redhat.com>
2755
2756 PR c++/60364 - noreturn after first decl not diagnosed.
2757 * c-attribs.c (handle_noreturn_attribute): No longer static.
2758 * c-common.h (handle_noreturn_attribute, attr_noreturn_exclusions):
2759 Declare.
2760 * c-format.c (check_function_format): Use get_attribute_name.
2761
2762 2019-06-19 Martin Sebor <msebor@redhat.com>
2763
2764 PR translation/90156
2765 * c-format.c (function_format_info::format_type): Adjust type.
2766 (function_format_info::is_raw): New member.
2767 (decode_format_type): Adjust signature. Handle "raw" diag attributes.
2768 (decode_format_attr): Adjust call to decode_format_type.
2769 Avoid a redundant call to convert_format_name_to_system_name.
2770 Avoid abbreviating the word "arguments" in a diagnostic.
2771 (format_warning_substr): New function.
2772 (avoid_dollar_number): Quote dollar sign in a diagnostic.
2773 (finish_dollar_format_checking): Same.
2774 (check_format_info): Same.
2775 (struct baltoks_t): New.
2776 (c_opers, c_keywords, cxx_keywords, badwords, contrs): New arrays.
2777 (maybe_diag_unbalanced_tokens, check_tokens, check_plain): New
2778 functions.
2779 (check_format_info_main): Call check_plain. Use baltoks_t. Call
2780 maybe_diag_unbalanced_tokens.
2781 (handle_format_attribute): Spell out the word "arguments" in
2782 a diagnostic.
2783
2784 2019-06-11 Matthew Beliveau <mbelivea@redhat.com>
2785
2786 PR c++/90449 - add -Winaccessible-base option.
2787 * c.opt (Winaccessible-base): New option.
2788
2789 2019-06-10 Jakub Jelinek <jakub@redhat.com>
2790
2791 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCAN.
2792 * c-pragma.c (omp_pragmas_simd): Add #pragma omp scan.
2793 * c-omp.c (c_omp_split_clauses): Diagnose inscan reductions on
2794 combined/composite constructs where it is not allowed. Copy over
2795 OMP_CLAUSE_REDUCTION_INSCAN.
2796
2797 2019-06-05 Martin Sebor <msebor@redhat.com>
2798
2799 * c-attribs.c (handle_mode_attribute): Adjust quoting and hyphenation.
2800 (handle_alias_ifunc_attribute): Same.
2801 (handle_copy_attribute): Same.
2802 (handle_weakref_attribute): Same.
2803 (handle_nonnull_attribute): Same.
2804 * c-warn.c (warn_for_sign_compare): Same.
2805 (warn_for_restrict): Same.
2806 * c.opt: Same.
2807
2808 2019-06-05 Martin Sebor <msebor@redhat.com>
2809
2810 * c-pragma.c (handle_pragma_weak): Adjust quoting in a diagnostic.
2811 * c.opt (-Wformat-diag): Remove a spurious period.
2812
2813 2019-05-29 Jakub Jelinek <jakub@redhat.com>
2814
2815 PR c/90628
2816 * c-common.c (check_builtin_function_arguments)
2817 <case BUILTIN_*_OVERFLOW>: Diagnose pointer to const qualified integer
2818 as last argument.
2819
2820 2019-05-23 Eric Botcazou <ebotcazou@adacore.com>
2821
2822 * c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
2823
2824 2019-05-22 Martin Liska <mliska@suse.cz>
2825
2826 PR lto/90500
2827 * c-attribs.c (handle_copy_attribute): Do not copy
2828 target_clones attribute.
2829
2830 2019-05-21 Eric Botcazou <ebotcazou@adacore.com>
2831
2832 * c-ada-spec.h (enum cpp_operation): Add IS_ASSIGNMENT_OPERATOR.
2833 * c-ada-spec.c (print_assignment_operator): New function.
2834 (dump_ada_declaration) <FUNCTION_DECL>: Call it do dump explicit copy
2835 assignment operators declared as methods and filter out the others.
2836
2837 2019-05-17 Thomas Schwinge <thomas@codesourcery.com>
2838
2839 PR c/89433
2840 * c-attribs.c (c_common_attribute_table): Set min_len to -1 for
2841 "omp declare target".
2842
2843 2019-05-16 Martin Sebor <msebor@redhat.com>
2844
2845 * c-attribs.c (handle_no_sanitize_attribute): Quote identifiers,
2846 keywords, operators, and types in diagnostics.
2847 (handle_scalar_storage_order_attribute): Same.
2848 (handle_mode_attribute): Same.
2849 (handle_visibility_attribute): Same.
2850 (handle_assume_aligned_attribute): Same.
2851 (handle_no_split_stack_attribute): Same.
2852 * c-common.c (shorten_compare): Same.
2853 (c_common_truthvalue_conversion): Same.
2854 (cb_get_source_date_epoch): Same.
2855 * c-lex.c (cb_def_pragma): Quote keywords, operators, and types
2856 in diagnostics.
2857 (interpret_float): Same.
2858 * c-omp.c (c_finish_omp_for): Same.
2859 * c-opts.c (c_common_post_options): Same.
2860 * c-pch.c (c_common_pch_pragma): Same.
2861 * c-pragma.c (pop_alignment): Same.
2862 (handle_pragma_pack): Same.
2863 (apply_pragma_weak): Same.
2864 (handle_pragma_weak): Same.
2865 (handle_pragma_scalar_storage_order): Same.
2866 (handle_pragma_redefine_extname): Same.
2867 (add_to_renaming_pragma_list): Same.
2868 (maybe_apply_renaming_pragma): Same.
2869 (push_visibility): Same.
2870 (handle_pragma_visibility): Same.
2871 (handle_pragma_optimize): Same.
2872 (handle_pragma_message): Same.
2873 * c-warn.c (warn_for_omitted_condop): Same.
2874 (lvalue_error): Same.
2875
2876 2019-05-15 Richard Biener <rguenther@suse.de>
2877
2878 PR c/90474
2879 * c-common.c (c_common_mark_addressable_vec): Also mark
2880 a COMPOUND_LITERAL_EXPR_DECL addressable similar to
2881 c_mark_addressable.
2882
2883 2019-05-06 Nathan Sidwell <nathan@acm.org>
2884
2885 * c-opts.c (handle_defered_opts): Rename struct deps to struc mkdeps.
2886
2887 2019-04-30 Nathan Sidwell <nathan@acm.org>
2888
2889 * c-common.c (c_common_init_ts): Use MARK_TS_EXP. Mark SIZEOF_EXPR.
2890
2891 2019-04-30 Martin Liska <mliska@suse.cz>
2892
2893 * c-pragma.c (handle_pragma_diagnostic): Provide hints
2894 for unknown options.
2895
2896 2019-04-26 Richard Sandiford <richard.sandiford@arm.com>
2897
2898 * c-warn.c (strict_aliasing_warning): Apply COMPLETE_TYPE_P to
2899 the pointer target rather than the pointer itself.
2900
2901 2019-04-19 Jakub Jelinek <jakub@redhat.com>
2902
2903 PR c/89888
2904 * c-common.h (c_add_case_label): Remove orig_type and outside_range_p
2905 arguments.
2906 (c_do_switch_warnings): Remove outside_range_p argument.
2907 * c-common.c (check_case_bounds): Removed.
2908 (c_add_case_label): Remove orig_type and outside_range_p arguments.
2909 Don't call check_case_bounds. Fold low_value as well as high_value.
2910 * c-warn.c (c_do_switch_warnings): Remove outside_range_p argument.
2911 Check for case labels outside of range of original type here and
2912 adjust them.
2913
2914 2019-04-12 Jakub Jelinek <jakub@redhat.com>
2915
2916 PR translation/90041
2917 * c.opt (-fhandle-exceptions): Use %< and %> around option names
2918 in the Warn diagnostics.
2919
2920 PR c/89946
2921 * c-attribs.c (handle_patchable_function_entry_attribute): Add
2922 function comment. Warn if arguments of the attribute are not positive
2923 integer constants.
2924
2925 2019-04-09 Eric Botcazou <ebotcazou@adacore.com>
2926
2927 * c-ada-spec.c (print_destructor): Deal with deleting destructors.
2928 (dump_ada_declaration) <FUNCTION_DECL>: Likewise.
2929
2930 2019-04-07 Eric Botcazou <ebotcazou@adacore.com>
2931
2932 * c-ada-spec.c (is_float128): New predicate extracted from...
2933 (dump_ada_node) <COMPLEX_TYPE>: Use it to recognize __cfloat128.
2934 <REAL_TYPE>: ...here. Call it.
2935
2936 2019-04-05 David Malcolm <dmalcolm@redhat.com>
2937
2938 PR c/89985
2939 * c-warn.c (check_address_or_pointer_of_packed_member): Add
2940 auto_diagnostic_group. Guard inform calls by result of
2941 warning_at call.
2942
2943 2019-04-05 Marek Polacek <polacek@redhat.com>
2944
2945 PR c++/89973 - -Waddress-of-packed-member ICE with invalid conversion.
2946 * c-warn.c (check_address_or_pointer_of_packed_member): Check the type
2947 of RHS.
2948
2949 2019-04-03 Jason Merrill <jason@redhat.com>
2950
2951 PR c++/86586 - -fcompare-debug=-Wsign-compare.
2952 * c-warn.c (warn_for_sign_compare): Call fold_for_warn.
2953
2954 2019-04-01 Martin Sebor <msebor@redhat.com>
2955
2956 PR c/89685
2957 * c-attribs.c (handle_copy_attribute): Handle references and
2958 non-constant expressions.
2959
2960 2019-03-22 Jakub Jelinek <jakub@redhat.com>
2961
2962 PR c++/87481
2963 * c.opt (-fconstexpr-ops-limit=): New option.
2964
2965 2019-03-21 Jakub Jelinek <jakub@redhat.com>
2966
2967 * c-common.c (per_file_includes_t): Use false as Lazy in hash_set
2968 template param.
2969
2970 2019-03-19 Martin Sebor <msebor@redhat.com>
2971
2972 PR tree-optimization/89688
2973 * c-common.c (braced_list_to_string): Make static.
2974 (braced_lists_to_strings): Define new function.
2975 * c-common.h (braced_list_to_string): Remove.
2976 (braced_lists_to_strings): Declare.
2977
2978 2019-03-12 Martin Liska <mliska@suse.cz>
2979
2980 * c-opts.c (c_common_handle_option): Wrap option with %< and %>.
2981
2982 2019-03-11 Martin Liska <mliska@suse.cz>
2983
2984 * c-opts.c (c_common_post_options): Wrap apostrophes
2985 in gcc internal format with %'.
2986
2987 2019-03-11 Martin Liska <mliska@suse.cz>
2988
2989 * c-attribs.c (handle_nocf_check_attribute): Wrap an option name
2990 in a string format message and fix GNU coding style.
2991 * c-common.c (vector_types_convertible_p): Likewise.
2992 (c_build_vec_perm_expr): Likewise.
2993 * c-indentation.c (get_visual_column): Likewise.
2994 * c-opts.c (c_common_handle_option): Likewise.
2995 (c_common_post_options): Likewise.
2996 (sanitize_cpp_opts): Likewise.
2997 * c-pch.c (c_common_pch_pragma): Likewise.
2998 * c-pragma.c (handle_pragma_pack): Likewise.
2999
3000 2019-03-08 Jakub Jelinek <jakub@redhat.com>
3001
3002 PR tree-optimization/89550
3003 * c-common.c (c_common_truthvalue_conversion): Only set
3004 TREE_NO_WARNING if warning_at returned true.
3005 * c-warn.c (overflow_warning, warn_logical_operator): Likewise.
3006
3007 2019-02-25 Sandra Loosemore <sandra@codesourcery.com>
3008 Martin Sebor <msebor@gmail.com>
3009
3010 * c.opt (Wmissing-attributes): Clean up doc string.
3011
3012 2019-02-25 Jakub Jelinek <jakub@redhat.com>
3013
3014 PR c/89495
3015 * c-format.c (maybe_read_dollar_number): Compute nargnum in
3016 HOST_WIDE_INT type to avoid overflows and change overflow_flag
3017 checking.
3018
3019 2019-02-22 Richard Biener <rguenther@suse.de>
3020
3021 * c-pch.c (no_checksum): Remove.
3022 (pch_init): Remove assertion that executable_checksum is not
3023 all zero.
3024 (c_common_valid_pch): Likewise.
3025
3026 2019-02-18 Martin Sebor <msebor@redhat.com>
3027
3028 PR middle-end/89294
3029 * c-common.c (invalid_array_size_error): Handle cst_size_not_constant.
3030
3031 2019-02-16 David Malcolm <dmalcolm@redhat.com>
3032
3033 PR c++/88680
3034 * c-common.c (shorten_compare): Call fold_for_warn on op0 when
3035 implementing -Wtype-limits.
3036
3037 2019-02-11 Martin Sebor <msebor@redhat.com>
3038
3039 PR c++/87996
3040 * c-common.c (invalid_array_size_error): New function.
3041 (valid_array_size_p): Call it. Handle size as well as type.
3042 * c-common.h (valid_constant_size_p): New function.
3043 (enum cst_size_error): New type.
3044
3045 2019-01-31 David Malcolm <dmalcolm@redhat.com>
3046
3047 PR c/89122
3048 * known-headers.cc (get_stdlib_header_for_name): Add
3049 {FLT|DBL|LDBL}_{MAX|MIN} to "hints" array.
3050
3051 2019-01-31 Jakub Jelinek <jakub@redhat.com>
3052
3053 PR libstdc++/88170
3054 * c-pretty-print.c (pp_c_enumeration_constant): Print always as
3055 a C cast in pp_c_flag_gnu_v3 mode.
3056
3057 2019-01-29 Jakub Jelinek <jakub@redhat.com>
3058
3059 PR c/86125
3060 * c-common.c (c_common_nodes_and_builtins): Build type variants for
3061 builtin_structptr_types types even for C.
3062
3063 2019-01-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
3064
3065 * c-warn.c (check_address_or_pointer_of_packed_member): Handle the case
3066 when rhs is of array type correctly. Fix handling of nested structures.
3067 Fix handling of indirect_ref together with nop_expr and/or addr_expr.
3068 (check_and_warn_address_or_pointer_of_packed_member): Fix handling of
3069 type casts within nested compound expressions.
3070
3071 2019-01-22 Jakub Jelinek <jakub@redhat.com>
3072
3073 PR middle-end/88968
3074 * c-omp.c (c_finish_omp_atomic): For bitfield atomics, update type
3075 variable after using BIT_FIELD_REF.
3076
3077 2019-01-18 H.J. Lu <hongjiu.lu@intel.com>
3078
3079 PR c/51628
3080 PR c/88664
3081 * c-common.h (warn_for_address_or_pointer_of_packed_member):
3082 Remove the boolean argument.
3083 * c-warn.c (check_address_of_packed_member): Renamed to ...
3084 (check_address_or_pointer_of_packed_member): This. Also
3085 warn pointer conversion.
3086 (check_and_warn_address_of_packed_member): Renamed to ...
3087 (check_and_warn_address_or_pointer_of_packed_member): This.
3088 Also warn pointer conversion.
3089 (warn_for_address_or_pointer_of_packed_member): Remove the
3090 boolean argument. Don't check pointer conversion here.
3091
3092 2019-01-15 Richard Sandiford <richard.sandiford@arm.com>
3093
3094 PR inline-asm/52813
3095 * c.opt (Wdeprecated): Move documentation and variable to common.opt.
3096
3097 2019-01-14 Jakub Jelinek <jakub@redhat.com>
3098
3099 * c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
3100 and __cpp_nontype_template_parameter_auto. Add a comment that
3101 __cpp_template_auto is deprecated.
3102
3103 2019-01-14 Tom Honermann <tom@honermann.net>
3104
3105 Implement P0482R5, char8_t: A type for UTF-8 characters and strings
3106 * c-common.c (c_common_reswords): Add char8_t.
3107 (fix_string_type): Use char8_t for the type of u8 string literals.
3108 (c_common_get_alias_set): char8_t doesn't alias.
3109 (c_common_nodes_and_builtins): Define char8_t as a builtin type in
3110 C++.
3111 (c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
3112 (keyword_begins_type_specifier): Add RID_CHAR8.
3113 * c-common.h (rid): Add RID_CHAR8.
3114 (c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
3115 Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
3116 Define char8_type_node and char8_array_type_node.
3117 * c-cppbuiltin.c (cpp_atomic_builtins): Predefine
3118 __GCC_ATOMIC_CHAR8_T_LOCK_FREE.
3119 (c_cpp_builtins): Predefine __cpp_char8_t.
3120 * c-lex.c (lex_string): Use char8_array_type_node as the type of
3121 CPP_UTF8STRING.
3122 (lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
3123 * c-opts.c: If not otherwise specified, enable -fchar8_t when
3124 targeting C++2a.
3125 * c.opt: Add the -fchar8_t command line option.
3126
3127 2019-01-14 Martin Sebor <msebor@redhat.com>
3128
3129 PR target/88638
3130 * c-attribs.c (positional_argument): Call valid_format_string_type_p
3131 and issue errors if it fails.
3132 * c-common.h (valid_format_string_type_p): Declare.
3133 * c-format.c (valid_stringptr_type_p): Rename...
3134 (valid_format_string_type_p): ...to this and make extern.
3135 (handle_format_arg_attribute): Adjust to new name.
3136 (check_format_string): Same.
3137
3138 2019-01-13 H.J. Lu <hongjiu.lu@intel.com>
3139
3140 * c-warn.c (warn_for_address_or_pointer_of_packed_member):
3141 Replace "may may" with "may" in warning message.
3142
3143 2019-01-07 Jakub Jelinek <jakub@redhat.com>
3144
3145 PR c++/85052
3146 * c-common.h (enum rid): Add RID_BUILTIN_CONVERTVECTOR.
3147 (c_build_vec_convert): Declare.
3148 * c-common.c (c_build_vec_convert): New function.
3149
3150 2019-01-04 Martin Sebor <msebor@redhat.com>
3151
3152 PR c/88546
3153 * c-attribs.c (handle_copy_attribute): Avoid copying attribute leaf.
3154 Handle C++ empty throw specification and C11 _Noreturn.
3155 (has_attribute): Also handle C11 _Noreturn.
3156
3157 2019-01-04 Martin Sebor <msebor@redhat.com>
3158
3159 PR c/88363
3160 * c-attribs.c (positional_argument): Also accept enumerated types.
3161
3162 2019-01-01 Jakub Jelinek <jakub@redhat.com>
3163
3164 Update copyright years.
3165
3166 2018-12-20 H.J. Lu <hongjiu.lu@intel.com>
3167
3168 PR c/51628
3169 * c-common.h (warn_for_address_or_pointer_of_packed_member): New.
3170 * c-warn.c (check_alignment_of_packed_member): New function.
3171 (check_address_of_packed_member): Likewise.
3172 (check_and_warn_address_of_packed_member): Likewise.
3173 (warn_for_address_or_pointer_of_packed_member): Likewise.
3174 * c.opt: Add -Wno-address-of-packed-member.
3175
3176 2018-12-20 David Malcolm <dmalcolm@redhat.com>
3177
3178 PR c++/87504
3179 * c-warn.c (get_outermost_macro_expansion): New function.
3180 (spelled_the_same_p): Use it to unwind the macro expansions, and
3181 compare the outermost macro in each nested expansion, rather than
3182 the innermost.
3183
3184 2018-12-19 David Malcolm <dmalcolm@redhat.com>
3185
3186 PR c++/87504
3187 * c-common.h (warn_tautological_cmp): Convert 1st param from
3188 location_t to const op_location_t &.
3189 * c-warn.c (find_array_ref_with_const_idx_r): Call fold_for_warn
3190 when testing for INTEGER_CST.
3191 (warn_tautological_bitwise_comparison): Convert 1st param from
3192 location_t to const op_location_t &; use it to build a
3193 binary_op_rich_location, and use this.
3194 (spelled_the_same_p): New function.
3195 (warn_tautological_cmp): Convert 1st param from location_t to
3196 const op_location_t &. Warn for macro expansions if
3197 spelled_the_same_p. Use binary_op_rich_location.
3198
3199 2018-12-19 David Malcolm <dmalcolm@redhat.com>
3200
3201 PR c++/43064
3202 PR c++/43486
3203 * c-common.c (unsafe_conversion_p): Fold any location wrapper.
3204 (verify_tree): Handle location wrappers.
3205 (c_common_truthvalue_conversion): Strip any location wrapper.
3206 Handle CONST_DECL.
3207 (fold_offsetof): Strip any location wrapper.
3208 (complete_array_type): Likewise for initial_value.
3209 (convert_vector_to_array_for_subscript): Call fold_for_warn on the
3210 index before checking for INTEGER_CST.
3211 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
3212 print parentheses around location wrappers.
3213 * c-warn.c (warn_logical_operator): Call fold_for_warn on op_right
3214 before checking for INTEGER_CST.
3215 (warn_tautological_bitwise_comparison): Call
3216 tree_strip_any_location_wrapper on lhs, rhs, and bitop's operand
3217 before checking for INTEGER_CST.
3218 (readonly_error): Strip any location wrapper.
3219 (warn_array_subscript_with_type_char): Strip location wrappers
3220 before checking for INTEGER_CST. Use the location of the index if
3221 available.
3222
3223 2018-12-06 Jason Merrill <jason@redhat.com>
3224
3225 PR c++/88136 - -Wdeprecated-copy false positives
3226 * c.opt (Wdeprecated-copy-dtor): New.
3227 (Wdeprecated-copy): Move to -Wextra.
3228
3229 2018-11-29 Martin Sebor <msebor@redhat.com>
3230
3231 PR c/88172
3232 PR testsuite/88208
3233 * c-attribs.c (common_handle_aligned_attribute): Silently avoid setting
3234 alignments to values less than the target requires.
3235 (has_attribute): For attribute aligned consider both the attribute
3236 and the alignment bits.
3237 * c-common.c (c_init_attributes): Optionally issue a warning for
3238 zero alignment.
3239
3240 2018-11-28 Martin Sebor <msebor@redhat.com>
3241
3242 PR c/88065
3243 PR c/87297
3244 * c-warn.c (sizeof_pointer_memaccess_warning): Bail if source
3245 or destination is an error.
3246
3247 2018-11-28 Jakub Jelinek <jakub@redhat.com>
3248
3249 PR c++/88215
3250 * c-ubsan.c: Include langhooks.h.
3251 (ubsan_instrument_division): Change gcc_assert that main variants
3252 of op0 and op1 types are equal to gcc_checking_assert that the
3253 main variants are compatible types.
3254
3255 2018-11-27 Eric Botcazou <ebotcazou@adacore.com>
3256
3257 * c-ada-spec.c: Include stringpool.h.
3258 (has_static_fields): Return false for incomplete types.
3259 (is_tagged_type): Likewise.
3260 (has_nontrivial_methods): Likewise.
3261 (dump_ada_node) <INTEGER_TYPE>: Deal specifically with __int128.
3262 (struct overloaded_name_hash): New structure.
3263 (struct overloaded_name_hasher): Likewise.
3264 (overloaded_names): New global variable.
3265 (init_overloaded_names): New static function.
3266 (overloaded_name_p): New predicate.
3267 (dump_ada_declaration) <TYPE_DECL>: Tidy up and set TREE_VISITED
3268 on the TYPE_STUB_DECL of the original type of a typedef, if any.
3269 <FUNCTION_DECL>: Bail out for an unsupported overloaded name.
3270 Remove always-true condition and dump forward types.
3271 (dump_ada_specs): Delete overloaded_names.
3272
3273 2018-11-20 Martin Sebor <msebor@redhat.com>
3274
3275 * c-attribs.c (type_for_vector_size): New function.
3276 (type_valid_for_vector_size): Same.
3277 (handle_vector_size_attribute): Move code to the functions above
3278 and call them.
3279 (validate_attribute, has_attribute): New functions.
3280 * c-common.h (has_attribute): Declare.
3281 (rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
3282 * c-common.c (c_common_resword): Same.
3283
3284 2018-11-16 Jason Merrill <jason@redhat.com>
3285
3286 * c-lex.c (c_common_has_attribute): Handle likely/unlikely.
3287 * c-attribs.c (attr_cold_hot_exclusions): Make public.
3288
3289 2018-11-16 Jakub Jelinek <jakub@redhat.com>
3290
3291 PR middle-end/87854
3292 * c-common.c (fix_string_type): Reject string literals larger than
3293 TYPE_MAX_VALUE (ssizetype) bytes.
3294
3295 2018-11-15 Martin Sebor <msebor@redhat.com>
3296
3297 PR c++/87541
3298 PR c++/87542
3299 * c-attribs.c (positional_argument): New function.
3300 (handle_alloc_size_attribute): Use it and simplify.
3301 (handle_alloc_align_attribute): Same.
3302 (handle_assume_aligned_attribute): Same.
3303 (handle_nonnull_attribute): Same.
3304 * c-common.c (check_function_arguments): Pass fntype to
3305 check_function_format.
3306 * c-common.h (check_function_format): Add an argument.
3307 (PosArgFlags, positional_argument): Declare new type and function.
3308 * c-format.c (decode_format_attr): Add arguments.
3309 (check_format_string, get_constant): Same.
3310 (convert_format_name_to_system_name): Adjust.
3311
3312 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3313
3314 PR other/19165
3315 * c-opts.c (c_diagnostic_finalizer): Add diagnostic_t param.
3316
3317 2018-11-14 Jakub Jelinek <jakub@redhat.com>
3318
3319 P1236R1 - Signed integers are two's complement
3320 * c-warn.c (maybe_warn_shift_overflow): Don't warn for c++2a.
3321 * c-ubsan.c (ubsan_instrument_shift): Make signed shifts
3322 with in-range second operand well defined for -std=c++2a.
3323
3324 PR other/88007
3325 * c-common.c (parse_optimize_options): Allocate option string from
3326 opts_obstack rather than as GC memory. Move the allocation after
3327 warning for invalid option.
3328
3329 2018-11-13 David Malcolm <dmalcolm@redhat.com>
3330
3331 * c-common.c (c_get_substring_location): Update for renaming of
3332 get_source_location_for_substring to get_location_within_string.
3333 * c-lex.c: Replace "source_location" with "location_t".
3334 * c-opts.c: Likewise.
3335 * c-ppoutput.c: Likewise.
3336
3337 2018-11-13 Martin Sebor <msebor@redhat.com>
3338
3339 PR middle-end/81824
3340 * c-attribs.c (handle_copy_attribute): Exclude inlining attributes.
3341 (handle_tls_model_attribute): Improve diagnostics.
3342
3343 2018-11-12 Jason Merrill <jason@redhat.com>
3344
3345 * c-cppbuiltin.c (c_cpp_builtins): Define
3346 __cpp_impl_destroying_delete.
3347
3348 * c-cppbuiltin.c (c_cpp_builtins): Change __cpp_explicit_bool to
3349 __cpp_conditional_explicit.
3350
3351 2018-11-09 Martin Sebor <msebor@redhat.com>
3352
3353 PR middle-end/81824
3354 * c-attribs.c (handle_copy_attribute): New function.
3355
3356 2018-11-09 Martin Sebor <msebor@redhat.com>
3357
3358 PR c/87795
3359 * c-common.c (check_user_alignment): Use MAX_OFILE_ALIGNMENT.
3360
3361 2018-11-08 Jakub Jelinek <jakub@redhat.com>
3362
3363 * c-common.h (c_finish_omp_taskgroup): Add CLAUSES argument.
3364 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
3365 enum omp_memory_order MEMORY_ORDER.
3366 (c_finish_omp_flush): Add MO argument.
3367 (c_omp_depend_t_p, c_finish_omp_depobj): Declare.
3368 (c_finish_omp_for): Add FINAL_P argument.
3369 * c-omp.c: Include memmodel.h.
3370 (c_finish_omp_taskgroup): Add CLAUSES argument. Set
3371 OMP_TASKGROUP_CLAUSES to it.
3372 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
3373 enum omp_memory_order MEMORY_ORDER. Set OMP_ATOMIC_MEMORY_ORDER
3374 instead of OMP_ATOMIC_SEQ_CST.
3375 (c_omp_depend_t_p, c_finish_omp_depobj): New functions.
3376 (c_finish_omp_flush): Add MO argument, if not MEMMODEL_LAST, emit
3377 __atomic_thread_fence call with the given value.
3378 (check_omp_for_incr_expr): Formatting fixes.
3379 (c_finish_omp_for): Add FINAL_P argument. Allow NE_EXPR
3380 even in OpenMP loops, diagnose if NE_EXPR and incr expression
3381 is not constant expression 1 or -1. Transform NE_EXPR loops
3382 with iterators pointers to VLA into LT_EXPR or GT_EXPR loops.
3383 (c_omp_check_loop_iv_r): Look for orig decl of C++ range for
3384 loops too.
3385 (c_omp_split_clauses): Add support for combined
3386 #pragma omp parallel master and
3387 #pragma omp {,parallel }master taskloop{, simd} constructs.
3388 Handle OMP_CLAUSE_IN_REDUCTION. Handle OMP_CLAUSE_REDUCTION_TASK.
3389 Handle OMP_CLAUSE_NONTEMPORAL. Handle splitting OMP_CLAUSE_IF
3390 also to OMP_SIMD. Copy OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
3391 (c_omp_predetermined_sharing): Don't return
3392 OMP_CLAUSE_DEFAULT_SHARED for const qualified decls.
3393 * c-pragma.c (omp_pragmas): Add PRAGMA_OMP_DEPOBJ and
3394 PRAGMA_OMP_REQUIRES.
3395 * c-pragma.h (enum pragma_kind): Likewise.
3396 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_NONTEMPORAL
3397 and PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
3398
3399 2018-11-08 David Malcolm <dmalcolm@redhat.com>
3400
3401 * c-format.c (gcc_dump_printf_char_table): Add entry for %f.
3402
3403 2018-11-08 David Malcolm <dmalcolm@redhat.com>
3404
3405 * c-format.c (local_cgraph_node_ptr_node): New variable.
3406 (gcc_dump_printf_char_table): Add entry for %C.
3407 (get_pointer_to_named_type): New function, taken from the handling
3408 code for "gimple *" from...
3409 (init_dynamic_diag_info): ...here. Add handling for
3410 "cgraph_node *".
3411 * c-format.h (T_CGRAPH_NODE): New.
3412
3413 2018-10-19 Jason Merrill <jason@redhat.com>
3414
3415 * c-cppbuiltin.c (c_cpp_builtins): Add
3416 __cpp_nontype_template_parameter_class.
3417
3418 2018-10-31 Nathan Sidwell <nathan@acm.org>
3419
3420 * c-opts.c (c_finish_options): Force command line macro
3421 location. Refactor to avoid repeating main debug hook.
3422 (push_command_line_include): Clarify comment.
3423
3424 * c-opts.c (c_finish_options): Adjust cpp_force_token_locations call.
3425
3426 2018-10-30 Martin Sebor <msebor@redhat.com>
3427
3428 PR middle-end/87041
3429 * c-format.c (check_format_types): Avoid diagnosing null pointer
3430 arguments to printf-family of functions.
3431
3432 2018-10-30 Marek Polacek <polacek@redhat.com>
3433
3434 Implement P0892R2, explicit(bool).
3435 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
3436
3437 2018-10-29 David Malcolm <dmalcolm@redhat.com>
3438
3439 * name-hint.h (name_hint::take_deferred): New member function.
3440
3441 2018-10-29 David Malcolm <dmalcolm@redhat.com>
3442
3443 PR c++/56856
3444 * c-common.c (check_function_sentinel): Call fold_for_warn on the
3445 argument.
3446 (check_function_restrict): Rename param "argarray" to
3447 "unfolded_argarray", and make a copy named "argarray", calling
3448 fold_for_warn on each argument.
3449 (check_function_arguments): Add note about responsibility for
3450 folding the arguments.
3451
3452 2018-10-17 Joseph Myers <joseph@codesourcery.com>
3453
3454 * c-common.c (flag_isoc2x): New variable.
3455 * c-common.h (clk_c): Update comment to reference C2X.
3456 (flag_isoc99, flag_isoc11): Update comments to reference future
3457 standard versions in general.
3458 (flag_isoc2x): Declare.
3459 * c-opts.c (set_std_c2x): New function.
3460 (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
3461 (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
3462 flag_isoc2x to 0.
3463 * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
3464
3465 2018-10-17 Joseph Myers <joseph@codesourcery.com>
3466
3467 * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
3468 (std=iso9899:2018): Document C17 as published in 2018.
3469
3470 2018-10-12 Christophe Lyon <christophe.lyon@linaro.org>
3471
3472 PR c++/87364
3473 * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
3474
3475 2018-10-11 Will Wray <wjwray@gmail.com>
3476
3477 PR c++/87364
3478 * c-pretty-print.h (pp_c_type_cast): Prototype.
3479 (pp_c_integer_constant): Likewise.
3480 * c-pretty-print.c (pp_c_type_cast): No longer static.
3481 (pp_c_integer_constant): Likewise.
3482 (pp_c_enumeration_constant): Fix loop termination when finding
3483 name of constant. No longer returns a value. Call
3484 pp_c_integer_constant.
3485 (c_pretty_printer::constant): Update for changes to
3486 pp_c_enumeration_constant.
3487
3488 2018-10-11 Jakub Jelinek <jakub@redhat.com>
3489
3490 * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
3491 for no_unique_address.
3492
3493 2018-10-09 David Malcolm <dmalcolm@redhat.com>
3494
3495 * c-common.c (c_option_controlling_cpp_error): Rename to...
3496 (c_option_controlling_cpp_diagnostic): ...this, and convert
3497 "reason" from int to enum.
3498 (c_cpp_error): Rename to...
3499 (c_cpp_diagnostic): ...this, converting level and reason to enums.
3500 * c-common.h (c_cpp_error): Rename to...
3501 (c_cpp_diagnostic): ...this, converting level and reason to enums.
3502 * c-opts.c (c_common_init_options): Update for renaming.
3503
3504 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
3505
3506 PR c/87286
3507 * c-common.c (vector_types_compatible_elements_p): Use
3508 INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
3509
3510 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
3511
3512 * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
3513 to generate constructor destructor priority warning.
3514 * c.opt (-Wprio-ctor-dtor): New option.
3515
3516 2018-10-01 Jason Merrill <jason@redhat.com>
3517
3518 * c-lex.c (c_common_has_attribute): Add no_unique_address.
3519
3520 2018-10-01 Eric Botcazou <ebotcazou@adacore.com>
3521
3522 * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
3523 (dump_ada_node): Add const keyword.
3524
3525 2018-09-25 Martin Liska <mliska@suse.cz>
3526
3527 * c-common.c (c_common_truthvalue_conversion):
3528 Remove Pascal from documentation.
3529
3530 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
3531
3532 * c-ada-spec.c: Include diagnostic.h.
3533 (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
3534
3535 2018-09-19 Marek Polacek <polacek@redhat.com>
3536
3537 * c.opt (Wclass-conversion): New.
3538
3539 2018-09-17 David Malcolm <dmalcolm@redhat.com>
3540
3541 * c-format.c (range_label_for_format_type_mismatch::get_text):
3542 Update for new param.
3543
3544 2018-09-17 David Malcolm <dmalcolm@redhat.com>
3545
3546 * c-format.c (format_warning_at_char): Update for introduction of
3547 format_string_diagnostic_t.
3548 (format_type_warning): Likewise.
3549
3550 2018-09-17 Martin Jambor <mjambor@suse.cz>
3551
3552 PR c/63886
3553 * c.opt (Wabsolute-value): New.
3554
3555 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
3556
3557 * c-common.c (complete_flexible_array_elts): New helper function.
3558 * c-common.h (complete_flexible_array_elts): Declare.
3559
3560 2018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
3561
3562 * c-common.c (braced_list_to_string): Remove eval parameter.
3563 Add some more checks. Always create zero-terminated STRING_CST.
3564 * c-common.h (braced_list_to_string): Adjust prototype.
3565
3566 2018-08-27 David Malcolm <dmalcolm@redhat.com>
3567
3568 PR 87091
3569 * c-common.c (c_cpp_error): Update for conversion of show_caret_p
3570 to a tri-state.
3571 (maybe_suggest_missing_token_insertion): Likewise.
3572 (maybe_add_include_fixit): Add param "override_location". If set,
3573 and source-printing is enabled, then override the rich_location's
3574 primary location with that of the insertion point for the fix-it
3575 hint, marking it with SHOW_LINES_WITHOUT_RANGE.
3576 * c-common.h (extern void maybe_add_include_fixit): Add bool
3577 param.
3578 * c-format.c (selftest::test_type_mismatch_range_labels): Update
3579 for conversion of show_caret_p to a tri-state.
3580 * c-warn.c (warn_for_restrict): Likewise.
3581 * known-headers.cc
3582 (suggest_missing_header::~suggest_missing_header): Update call to
3583 maybe_add_include_fixit to suggest overriding the location, as it
3584 is for a note.
3585
3586 2018-08-27 Martin Liska <mliska@suse.cz>
3587
3588 * c-common.c (check_function_restrict): Use new function
3589 fndecl_built_in_p and remove check for FUNCTION_DECL if
3590 possible.
3591 (check_builtin_function_arguments): Likewise.
3592 (reject_gcc_builtin): Likewise.
3593 * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
3594
3595 2018-08-26 Marek Polacek <polacek@redhat.com>
3596
3597 PR c++/87029, Implement -Wredundant-move.
3598 * c.opt (Wredundant-move): New option.
3599
3600 2018-08-21 Marek Polacek <polacek@redhat.com>
3601
3602 PR c++/86981, Implement -Wpessimizing-move.
3603 * c.opt (Wpessimizing-move): New option.
3604
3605 2018-08-20 David Malcolm <dmalcolm@redhat.com>
3606
3607 PR other/84889
3608 * c-attribs.c (common_handle_aligned_attribute): Add
3609 auto_diagnostic_group instance.
3610 * c-indentation.c (warn_for_misleading_indentation): Likewise.
3611 * c-opts.c (c_common_post_options): Likewise.
3612 * c-warn.c (warn_logical_not_parentheses): Likewise.
3613 (warn_duplicated_cond_add_or_warn): Likewise.
3614 (warn_for_multistatement_macros): Likewise.
3615
3616 2018-08-20 Nathan Sidwell <nathan@acm.org>
3617
3618 * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
3619 access.
3620
3621 2018-08-17 Nathan Sidwell <nathan@acm.org>
3622
3623 * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
3624 field.
3625 (laxy_hex_fp_value_count): Make unsigned.
3626 (lazy_hex_fp_value): Provided with macro & lazy number. Directly
3627 manipulate the macro.
3628 (builtin_defin_with_hex_fp_value): Adjust callback name, use
3629 cpp_define_lazily.
3630
3631 2018-08-17 David Malcolm <dmalcolm@redhat.com>
3632
3633 * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
3634 (gcc_dump_printf_length_specs): New.
3635 (gcc_dump_printf_flag_pairs): New.
3636 (gcc_dump_printf_flag_specs): New.
3637 (gcc_dump_printf_char_table): New.
3638 (format_types_orig): Add entry for "gcc_dump_printf".
3639 (init_dynamic_diag_info): Set up length_char_specs and
3640 conversion_specs for gcc_dump_printf_format_type.
3641 (handle_format_attribute): Handle gcc_dump_printf_format_type.
3642
3643 2018-08-17 Nathan Sidwell <nathan@acm.org>
3644
3645 * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
3646
3647 * c-ada-spec.c: Don't #include "cpp-id-data.h"
3648 * c-cppbuiltin.c: Likewise.
3649
3650 2018-08-17 Martin Liska <mliska@suse.cz>
3651
3652 * c.opt: Remove Warn, Init and Report for options with
3653 Ignore/Deprecated flag. Warning is done automatically for
3654 Deprecated flags.
3655
3656 2018-08-16 David Malcolm <dmalcolm@redhat.com>
3657
3658 PR c++/70693
3659 * c-common.c (selftest::c_family_tests): Call
3660 selftest::c_indentation_c_tests.
3661 * c-common.h (selftest::c_indentation_c_tests): New decl.
3662 * c-indentation.c: Include "selftest.h".
3663 (next_tab_stop): Add "tab_width" param, rather than accessing
3664 cpp_opts.
3665 (get_visual_column): Likewise. Clarify comment. Bulletproof
3666 against reading past the end of the line.
3667 (get_first_nws_vis_column): Add "tab_width" param.
3668 (detect_intervening_unindent): Likewise.
3669 (should_warn_for_misleading_indentation): Read tab width from
3670 cpp_opts and pass around.
3671 (selftest::test_next_tab_stop): New test.
3672 (selftest::assert_get_visual_column_succeeds): New function.
3673 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
3674 (selftest::assert_get_visual_column_fails): New function.
3675 (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
3676 (selftest::test_get_visual_column): New test.
3677 (selftest::c_indentation_c_tests): New function.
3678
3679 2018-08-16 Nathan Sidwell <nathan@acm.org>
3680
3681 * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
3682 (store_ada_macro): Likewise.
3683 * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
3684 * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
3685
3686 2018-08-15 David Malcolm <dmalcolm@redhat.com>
3687
3688 * c-format.c: Include "selftest-diagnostic.h" and
3689 "gcc-rich-location.h".
3690 (format_warning_at_char): Pass NULL for new label params of
3691 format_warning_va.
3692 (class indirection_suffix): New class.
3693 (class range_label_for_format_type_mismatch): New class.
3694 (format_type_warning): Move logic for generating "*" suffix to
3695 class indirection_suffix. Create "fmt_label" and "param_label"
3696 to show their types, and pass them to the
3697 format_warning_at_substring calls.
3698 (selftest::test_type_mismatch_range_labels): New test.
3699 (selftest::c_format_c_tests): Call it.
3700
3701 2018-08-13 Martin Sebor <msebor@redhat.com>
3702
3703 PR tree-optimization/71625
3704 * c-common.c (braced_list_to_string): New function.
3705 * c-common.h (braced_list_to_string): Declare it.
3706
3707 2018-08-08 Nathan Sidwell <nathan@acm.org>
3708
3709 * c-common.c (try_to_locate_new_include_inertion_point): Use
3710 linemap_included_from_linemap.
3711 * c-lex.c (fe_file_change): Use linemap_included_from.
3712 * c-ppoutput.c (pp_file_change): Likewise.
3713
3714 2018-08-01 Martin Sebor <msebor@redhat.com>
3715
3716 PR tree-optimization/86650
3717 * c-format.c (gcc_tdiag_char_table): Update comment for "%G".
3718 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
3719 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
3720 * c-format.h (T89_G): Update to be "gimple *" rather than
3721 "gcall *".
3722 (local_gcall_ptr_node): Rename...
3723 (local_gimple_ptr_node): ...to this.
3724
3725 2018-07-31 David Malcolm <dmalcolm@redhat.com>
3726
3727 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
3728 table entries for gcc_diag_char_table, and the 'Z' entry from
3729 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
3730 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
3731 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
3732 adding missing "Z" for this table. Remove erroneous "G" and "K"
3733 entries.
3734 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
3735 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
3736 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
3737
3738 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
3739
3740 * c-common.c (speculation_safe_resolve_call): New function.
3741 (speculation_safe_resolve_params): New function.
3742 (speculation_safe_resolve_return): New function.
3743 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
3744 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
3745 __HAVE_SPECULATION_SAFE_VALUE.
3746
3747 2018-07-20 David Malcolm <dmalcolm@redhat.com>
3748
3749 * c-common.c (c_cpp_error): Remove redundant "line_table"
3750 parameter from call to rich_location::set_range.
3751 (maybe_suggest_missing_token_insertion): Likewise.
3752
3753 2018-07-20 Martin Sebor <msebor@redhat.com>
3754
3755 PR middle-end/82063
3756 * c.opt (-Warray-bounds): Remove redundant -Wall.
3757
3758 2018-07-20 Martin Sebor <msebor@redhat.com>
3759
3760 PR middle-end/82063
3761 * c-common.h (c_common_handle_option): Change function argument
3762 to HOST_WIDE_INT.
3763 * c-opts.c (c_common_init_options): Same.
3764 (c_common_handle_option): Same. Remove special handling of
3765 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
3766 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
3767 options to take a HOST_WIDE_INT argument and accept a byte-size
3768 suffix. Initialize.
3769 (-Wvla-larger-than): Same.
3770 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
3771 (-Wno-vla-larger-than): Same.
3772
3773 2018-07-12 Jakub Jelinek <jakub@redhat.com>
3774
3775 * c-attribs.c (c_common_attribute_table): Add
3776 "omp declare target implicit" attribute.
3777
3778 2018-07-12 Richard Biener <rguenther@suse.de>
3779
3780 PR c/86453
3781 * c-attribs.c (handle_packed_attribute): Do not build a variant
3782 type with TYPE_PACKED, instead ignore the attribute if we may
3783 not apply to the original type.
3784
3785 2018-07-10 Jakub Jelinek <jakub@redhat.com>
3786
3787 PR c++/86443
3788 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
3789 to contain TREE_LIST for both the original class iterator and the
3790 "last" helper var.
3791
3792 2018-07-07 Eric Botcazou <ebotcazou@adacore.com>
3793
3794 * c-ada-spec.c (to_ada_name): Remove index parameter.
3795 (pp_ada_tree_identifier): Likewise.
3796 (dump_ada_macros): Adjust call to to_ada_name.
3797 (struct overloaded_name_hash): Delete.
3798 (struct overloaded_name_hasher): Likewise.
3799 (overloaded_names): Likewise.
3800 (compute_overloading_index): Likewise.
3801 (dump_ada_decl_name): Do not call compute_overloading_index and
3802 adjust calls to pp_ada_tree_identifier.
3803 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
3804 (dump_ada_import): Add spc parameter and switch to aspect syntax.
3805 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
3806 (dump_ada_enum_type): Remove type and display_convention parameters.
3807 Adjust calls to pp_ada_tree_identifier.
3808 (dump_ada_node): Likewise and for dump_ada_structure.
3809 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
3810 and tidy up.
3811 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
3812 syntax.
3813 (print_constructor): Adjust call to pp_ada_tree_identifier.
3814 (print_destructor): Likewise.
3815 (dump_ada_declaration): Switch to aspect syntax.
3816 (dump_ada_structure): Likewise and tidy up. Replace display_convention
3817 parameter with nested parameter.
3818 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
3819 (dump_ada_specs): Do not delete overloaded_names table.
3820
3821 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
3822
3823 PR target/86324
3824 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
3825 target hook.
3826
3827 2018-07-05 Nathan Sidwell <nathan@acm.org>
3828
3829 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
3830 NO_IMPLICIT_EXTERN_C.
3831
3832 2018-06-28 Martin Liska <mliska@suse.cz>
3833
3834 * cppspec.c: Include opt-suggestions.h.
3835
3836 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
3837 Thomas Schwinge <thomas@codesourcery.com>
3838 Cesar Philippidis <cesar@codesourcery.com>
3839
3840 * c-pragma.h (enum pragma_omp_clause): Add
3841 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
3842 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
3843
3844 2018-06-20 Jakub Jelinek <jakub@redhat.com>
3845
3846 PR c++/86210
3847 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
3848 comment.
3849
3850 2018-06-18 Martin Sebor <msebor@redhat.com>
3851
3852 PR middle-end/85602
3853 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
3854 nonstring.
3855
3856 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
3857
3858 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
3859
3860 2018-06-13 Jason Merrill <jason@redhat.com>
3861
3862 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
3863 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
3864 handling.
3865
3866 PR c++/86094 - wrong code with defaulted move ctor.
3867 * c-opts.c (c_common_post_options): Bump the current ABI version to
3868 13. Set warn_abi_version and flag_abi_compat_version to the current
3869 version rather than 0. Fix defaulting flag_abi_compat_version from
3870 warn_abi_version.
3871
3872 2018-06-12 Martin Sebor <msebor@redhat.com>
3873
3874 PR c/85931
3875 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
3876 sizeof source and destination yields the same value.
3877
3878 2018-06-12 Martin Liska <mliska@suse.cz>
3879
3880 * c.opt: Make MPX-related options as Deprecated.
3881
3882 2018-06-08 David Malcolm <dmalcolm@redhat.com>
3883
3884 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
3885 rather than 0.
3886
3887 2018-06-08 Martin Liska <mliska@suse.cz>
3888
3889 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
3890 for MPX (macros, related functions, fields in cgraph_node, ...).
3891 (handle_bnd_legacy): Likewise.
3892 (handle_bnd_instrument): Likewise.
3893 * c.opt: Likewise.
3894
3895 2018-06-06 Jakub Jelinek <jakub@redhat.com>
3896
3897 PR c++/86068
3898 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
3899 __cpp_transactional_memory to 201500 instead of 210500.
3900
3901 2018-06-06 Jason Merrill <jason@redhat.com>
3902
3903 PR c++/85710 - ICE with -Wmemset-elt-size.
3904 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
3905
3906 2018-06-01 Jason Merrill <jason@redhat.com>
3907
3908 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
3909 201703.
3910
3911 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
3912
3913 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
3914 declaration for a typedef independently of whether the declaration of
3915 the subtype is generated.
3916
3917 2018-05-31 Martin Sebor <msebor@redhat.com>
3918
3919 PR c/82063
3920 * c.opt (-Wno-alloc-size-larger-than): New option.
3921
3922 2018-04-22 David Pagan <dave.pagan@oracle.com>
3923
3924 PR c/55976
3925 * c-opts.c (c_common_post_options): Set default for warn_return_type
3926 for C++/C++ with ObjC extensions only. For C, makes it possible to
3927 differentiate between default (no option), -Wreturn-type, and
3928 -Wno-return-type.
3929
3930 2018-05-29 Jason Merrill <jason@redhat.com>
3931
3932 * c.opt (Winit-list-lifetime): New flag.
3933
3934 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
3935
3936 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
3937 splay_tree_delete_pointers.
3938
3939 2018-05-26 Jakub Jelinek <jakub@redhat.com>
3940
3941 PR bootstrap/85921
3942 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
3943 noinline variable to workaround broken kernel headers.
3944
3945 2018-05-18 Jason Merrill <jason@redhat.com>
3946
3947 * c.opt (Wdeprecated-copy): New flag.
3948
3949 2018-05-17 Martin Liska <mliska@suse.cz>
3950
3951 * c-warn.c (overflow_warning): Do not use
3952 space in between 'G_' and '('.
3953
3954 2018-05-09 Jason Merrill <jason@redhat.com>
3955
3956 * c-common.c (valid_array_size_p): Add complain parameter.
3957 * c-common.h: ...which defaults to true.
3958
3959 2018-05-11 Jakub Jelinek <jakub@redhat.com>
3960
3961 PR c/85696
3962 * c-omp.c (c_omp_predetermined_sharing): Return
3963 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
3964
3965 2018-05-11 Martin Liska <mliska@suse.cz>
3966
3967 PR sanitizer/85556
3968 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
3969 TREE_LIST values.
3970
3971 2018-05-10 Jakub Jelinek <jakub@redhat.com>
3972
3973 PR c++/85662
3974 * c-common.h (fold_offsetof_1): Removed.
3975 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
3976 CTX argument defaulted to ERROR_MARK.
3977 * c-common.c (fold_offsetof_1): Renamed to ...
3978 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
3979 argument, convert the pointer constant to TYPE and use size_binop
3980 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
3981 a pointer type. Adjust recursive calls.
3982
3983 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
3984
3985 PR c++/85400
3986 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
3987
3988 2018-05-07 Nathan Sidwell <nathan@acm.org>
3989
3990 * c.opt (ffor-scope): Remove functionality, issue warning.
3991
3992 2018-05-03 Nathan Sidwell <nathan@acm.org>
3993
3994 * c.opt (ffriend-injection): Remove functionality, issue warning.
3995
3996 2018-05-01 David Malcolm <dmalcolm@redhat.com>
3997
3998 PR c/84258
3999 * c-format.c (struct format_check_results): Add field
4000 "number_non_char".
4001 (check_format_info): Initialize it, and warn if encountered.
4002 (check_format_arg): Distinguish between wide char and
4003 everything else when detecting arrays of non-char.
4004
4005 2018-04-30 David Malcolm <dmalcolm@redhat.com>
4006
4007 * c-format.c (get_corrected_substring): Update for
4008 location_get_source_line returning a char_span. Use a char_span
4009 when handling the prefix of the correction.
4010 * c-indentation.c (get_visual_column): Update for
4011 location_get_source_line returning a char_span.
4012 (get_first_nws_vis_column): Likewise.
4013
4014 2018-03-29 David Malcolm <dmalcolm@redhat.com>
4015
4016 PR c++/84269
4017 * known-headers.cc (get_stdlib_header_for_name): Add various names
4018 from <assert.h>, <string.h>, and <memory.h>; add more names from
4019 <stdio.h>.
4020
4021 2018-03-27 Jakub Jelinek <jakub@redhat.com>
4022
4023 PR c++/85061
4024 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
4025 get_base_address of the second operand is a VAR_P, rather than the
4026 operand itself, and use gcc_checking_assert instead of gcc_assert.
4027
4028 2018-03-23 Marek Polacek <polacek@redhat.com>
4029
4030 PR c++/85045
4031 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
4032 <case RDIV_EXPR>: Tweak condition.
4033
4034 2018-03-20 Eric Botcazou <ebotcazou@adacore.com>
4035
4036 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
4037
4038 2018-03-16 Jakub Jelinek <jakub@redhat.com>
4039
4040 PR c/84909
4041 * c-warn.c (conversion_warning): Replace "to to" with "to" in
4042 diagnostics.
4043
4044 PR c/84910
4045 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
4046 diagnostics.
4047
4048 2018-03-16 Richard Biener <rguenther@suse.de>
4049
4050 PR c/84873
4051 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
4052 unshare the possibly folded expression.
4053
4054 2018-03-15 Richard Biener <rguenther@suse.de>
4055
4056 PR c/84873
4057 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
4058
4059 2018-03-13 Martin Sebor <msebor@redhat.com>
4060
4061 PR tree-optimization/84725
4062 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
4063 with all three narrow character types, including their qualified forms.
4064
4065 2018-03-12 Martin Sebor <msebor@redhat.com>
4066
4067 PR tree-optimization/83456
4068 * c-common.c (check_function_restrict): Return bool.
4069 Restore checking of bounded built-in functions.
4070 (check_function_arguments): Also return the result
4071 of warn_for_restrict.
4072 * c-common.c (check_function_restrict): Return bool.
4073 * c-warn.c (warn_for_restrict): Return bool.
4074
4075 2018-03-02 Marek Polacek <polacek@redhat.com>
4076
4077 PR c++/84171
4078 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
4079 is erroneous.
4080
4081 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
4082
4083 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
4084 function".
4085
4086 2018-03-01 Marek Polacek <polacek@redhat.com>
4087
4088 PR c++/84639
4089 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
4090 alignment in computation.
4091
4092 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
4093
4094 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
4095 <REAL_TYPE>: Deal specifically with _Float128/__float128.
4096
4097 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
4098
4099 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
4100 (is_char_array): Take a type instead of a declaration.
4101 (dump_ada_array_type): Likewise.
4102 (is_simple_enum): Minor tweak.
4103 (dump_ada_enum_type): New function extracted from...
4104 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
4105 <INTEGER_TYPE>: Remove unreachable code.
4106 <RECORD_TYPE>: Likewise. Minor tweaks.
4107 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
4108 <ENUMERAL_TYPE>: New case.
4109 <RECORD_TYPE>: Factor out common code.
4110 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
4111 Minor tweaks. Deal with enumeral types.
4112 (dump_ada_structure): Minor tweaks.
4113
4114 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
4115
4116 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
4117 address for incomplete structures.
4118 (dump_forward_type): Do not bail out for incomplete structures.
4119 (dump_ada_declaration): Do not special-case incomplete structures
4120 for subtypes. Dump them as null records for types.
4121
4122 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
4123
4124 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
4125 (is_char_array): Fix formatting.
4126 (dump_template_types): Likewise.
4127 (dump_generic_ada_node): Rename into...
4128 (dump_ada_node): ...this.
4129 <POINTER_TYPE>: Remove superfluous space. Use generic address for
4130 incomplete structures and not for empty structures. Do not use it
4131 when forward declarations are needed.
4132 (dump_forward_type): New function.
4133 (dump_nested_types): Remove FORWARD parameter. Do not consider
4134 TREE_VISITED and do not generate a forward declaration. Only dump
4135 original nested types for nested declaration.
4136 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
4137 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
4138 <RECORD_TYPE>: Do not consider TREE_VISITED.
4139 (dump_ada_declaration): Use booleans and fix formatting throughout.
4140 <TYPE_DECL>: Skip incomplete structures and not empty structures.
4141 Call dump_forward_type instead of dump_nested_types for a typedef.
4142 Remove superfluous check and adjust call to dump_nested_types.
4143 <POINTER_TYPE>: Call dump_forward_type and fall through.
4144 (dump_ada_struct_decl): Rename into...
4145 (dump_ada_structure): ...this. Do not special-case empty structures.
4146
4147 2018-02-27 Martin Sebor <msebor@redhat.com>
4148
4149 PR c++/83871
4150 * c.opt (-Wmissing-attributes): New option.
4151
4152 2018-02-21 Martin Liska <mliska@suse.cz>
4153
4154 * c.opt (Wcatch-value=): Add IntegerRange.
4155
4156 2018-02-15 Jason Merrill <jason@redhat.com>
4157
4158 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
4159
4160 2018-02-09 Nathan Sidwell <nathan@acm.org>
4161
4162 PR c/84293
4163 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
4164 arg.
4165 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
4166 arg. Adjust.
4167
4168 2018-02-09 Martin Sebor <msebor@redhat.com>
4169
4170 PR lto/84212
4171 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
4172 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
4173 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
4174 (-Wstrict-overflow, -Wsuggest-attribute): Same.
4175 (-Wuninitialized): Same.
4176
4177 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
4178
4179 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
4180 keyword for components.
4181
4182 2018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
4183
4184 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
4185
4186 2018-02-02 Julia Koval <julia.koval@intel.com>
4187
4188 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
4189
4190 2018-01-29 Marek Polacek <polacek@redhat.com>
4191
4192 PR c/83966
4193 * c-format.c (check_function_format): Check current_function_decl.
4194
4195 2018-01-27 Jakub Jelinek <jakub@redhat.com>
4196
4197 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
4198 argument.
4199 (LAZY_HEX_FP_VALUES_CNT): Define.
4200 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
4201 values rather than just 12.
4202 (builtin_define_with_hex_fp_value): Likewise.
4203
4204 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
4205
4206 PR other/70268
4207 * c.opt (-fmacro-prefix-map): New option.
4208 * c-opts.c (c_common_handle_option): Handle it.
4209 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
4210 * c-ppoutput.c (init_pp_output): Likewise.
4211
4212 2018-01-17 David Malcolm <dmalcolm@redhat.com>
4213
4214 PR c++/83814
4215 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
4216
4217 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
4218
4219 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
4220 Skip 'f' and 'F' characters if it is true.
4221 (store_ada_macro): Minor tweak.
4222 (dump_ada_macros) <CPP_COMMENT>: Likewise.
4223 <CPP_WSTRING>: Likewise.
4224 <CPP_STRING>: Output '&' in the buffer if not the first string.
4225 <CPP_NUMBER>: Adjust calls to dump_number.
4226
4227 2018-01-10 David Malcolm <dmalcolm@redhat.com>
4228
4229 PR c++/43486
4230 * c-common.c: Include "selftest.h".
4231 (get_atomic_generic_size): Perform the test for integral type
4232 before the range test for any integer constant, fixing indentation
4233 of braces. Call fold_for_warn before testing for an INTEGER_CST.
4234 (reject_gcc_builtin): Strip any location wrapper from EXPR.
4235 (selftest::test_fold_for_warn): New function.
4236 (selftest::c_common_c_tests): New function.
4237 (selftest::c_family_tests): Call it, and
4238 selftest::c_pretty_print_c_tests.
4239 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
4240 * c-format.c (check_format_arg): Convert VAR_P check to a
4241 fold_for_warn.
4242 * c-pretty-print.c: Include "selftest.h".
4243 (pp_c_cast_expression): Don't print casts for location wrappers.
4244 (selftest::assert_c_pretty_printer_output): New function.
4245 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
4246 (selftest::test_location_wrappers): New function.
4247 (selftest::c_pretty_print_c_tests): New function.
4248 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
4249
4250 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
4251 Alan Hayward <alan.hayward@arm.com>
4252 David Sherwood <david.sherwood@arm.com>
4253
4254 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
4255
4256 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
4257 Alan Hayward <alan.hayward@arm.com>
4258 David Sherwood <david.sherwood@arm.com>
4259
4260 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
4261 as polynomial.
4262
4263 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
4264 Alan Hayward <alan.hayward@arm.com>
4265 David Sherwood <david.sherwood@arm.com>
4266
4267 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
4268 (convert_vector_to_array_for_subscript): Handle polynomial
4269 TYPE_VECTOR_SUBPARTS.
4270 (c_common_type_for_mode): Check valid_vector_subparts_p.
4271 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
4272 VECTOR_CST_NELTS.
4273
4274 2018-01-03 Jakub Jelinek <jakub@redhat.com>
4275
4276 Update copyright years.
4277
4278 2017-12-22 Mike Stump <mikestump@comcast.net>
4279 Eric Botcazou <ebotcazou@adacore.com>
4280
4281 * c-pragma.c (init_pragma): Register pragma GCC unroll.
4282 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
4283
4284 2017-12-22 Alexandre Oliva <aoliva@redhat.com>
4285
4286 PR debug/83527
4287 PR debug/83419
4288 * c-semantics.c (only_debug_stmts_after_p): New.
4289 (pop_stmt_list): Clear side effects in debug-only stmt list.
4290 Check for single nondebug stmt followed by debug stmts only.
4291
4292 2017-12-21 Alexandre Oliva <aoliva@redhat.com>
4293
4294 PR debug/83419
4295 * c-semantics.c (pop_stmt_list): Propagate side effects from
4296 single nondebug stmt to container list.
4297
4298 2017-12-19 Jakub Jelinek <jakub@redhat.com>
4299
4300 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
4301 conditions with typical order conditions.
4302
4303 2017-12-18 Marek Polacek <polacek@redhat.com>
4304
4305 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
4306 not in effect.
4307
4308 2017-12-17 Martin Sebor <msebor@redhat.com>
4309
4310 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
4311 an error for attribute warn_if_not_aligned.
4312
4313 2017-12-16 Martin Sebor <msebor@redhat.com>
4314
4315 PR tree-optimization/78918
4316 * c-common.c (check_function_restrict): Avoid checking built-ins.
4317 * c.opt (-Wrestrict): Include in -Wall.
4318
4319 2017-12-15 Jakub Jelinek <jakub@redhat.com>
4320
4321 * c-attribs.c (c_common_attribute_table,
4322 c_common_format_attribute_table): Swap affects_type_identity
4323 and handler fields, adjust comments.
4324
4325 2017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
4326
4327 * c.opt (Wcast-function-type): New warning option.
4328 * c-lex.c (get_fileinfo): Avoid warning.
4329 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
4330
4331 2017-12-14 Qing Zhao <qing.zhao@oracle.com>
4332
4333 PR middle_end/79538
4334 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
4335 Adjust the size of buf1 and buf2, add a new buf to avoid
4336 format-overflow warning.
4337
4338 2017-12-12 Alexandre Oliva <aoliva@redhat.com>
4339
4340 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
4341 subsequent statement list.
4342
4343 2017-12-07 Martin Sebor <msebor@redhat.com>
4344
4345 PR c/81544
4346 PR c/81566
4347 * c-attribs.c (attr_aligned_exclusions): New array.
4348 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
4349 (attr_common_exclusions, attr_const_pure_exclusions): Same.
4350 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
4351 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
4352 (attr_warn_unused_result_exclusions): Same.
4353 (handle_hot_attribute, handle_cold_attribute): Simplify.
4354 (handle_const_attribute): Warn on function returning void.
4355 (handle_pure_attribute): Same.
4356 (handle_aligned_attribute): Diagnose conflicting attribute
4357 specifications.
4358 * c-warn.c (diagnose_mismatched_attributes): Simplify.
4359
4360 2017-12-06 David Malcolm <dmalcolm@redhat.com>
4361
4362 PR c/83236
4363 * c-common.c (selftest::c_family_tests): Call
4364 selftest::c_spellcheck_cc_tests.
4365 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
4366 * c-spellcheck.cc: Include "selftest.h".
4367 (name_reserved_for_implementation_p): New function.
4368 (should_suggest_as_macro_p): New function.
4369 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
4370 should_suggest_as_macro_p and call it.
4371 (selftest::test_name_reserved_for_implementation_p): New function.
4372 (selftest::c_spellcheck_cc_tests): New function.
4373 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
4374
4375 2017-12-06 David Malcolm <dmalcolm@redhat.com>
4376
4377 * c-spellcheck.cc: New file, taken from macro-handling code in
4378 spellcheck-tree.c.
4379 * c-spellcheck.h: New file, taken from macro-handling code in
4380 spellcheck-tree.h.
4381
4382 2017-12-01 Jakub Jelinek <jakub@redhat.com>
4383
4384 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
4385 attribute.
4386 (handle_simd_attribute): Don't check for "cilk simd function"
4387 attribute. Reindent, formatting changes.
4388
4389 2017-11-30 Julia Koval <julia.koval@intel.com>
4390
4391 * c-common.h (inv_list): Remove.
4392
4393 2017-11-28 Jakub Jelinek <jakub@redhat.com>
4394
4395 PR sanitizer/81275
4396 * c-common.c (c_switch_covers_all_cases_p_1,
4397 c_switch_covers_all_cases_p): New functions.
4398 * c-common.h (c_switch_covers_all_cases_p): Declare.
4399
4400 2017-11-28 Julia Koval <julia.koval@intel.com>
4401 Sebastian Peryt <sebastian.peryt@intel.com>
4402
4403 * array-notation-common.c: Delete.
4404 * c-cilkplus.c: Ditto.
4405 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
4406 * c-common.def (ARRAY_NOTATION_REF): Remove.
4407 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
4408 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
4409 c_validate_cilk_plus_loop, cilkplus_an_parts,
4410 cilk_ignorable_spawn_rhs_op,
4411 cilk_recognize_spawn): Remove.
4412 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
4413 * c-omp.c: Remove CILK_SIMD check.
4414 * c-pragma.c: Ditto.
4415 * c-pragma.h: Remove CILK related pragmas.
4416 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
4417 ARRAY_NOTATION_REF condition.
4418 (c_pretty_printer::expression): Ditto.
4419 * c.opt (fcilkplus): Remove.
4420 * cilk.c: Delete.
4421
4422 2017-11-21 Marc Glisse <marc.glisse@inria.fr>
4423
4424 * c-pretty-print.c (pp_c_additive_expression,
4425 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
4426
4427 2017-11-21 Jakub Jelinek <jakub@redhat.com>
4428
4429 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
4430
4431 PR c++/83059
4432 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
4433 instead of tree_to_uhwi, formatting fix.
4434
4435 2017-11-20 David Malcolm <dmalcolm@redhat.com>
4436
4437 PR c/81404
4438 * known-headers.cc: New file, based on material from c/c-decl.c.
4439 (suggest_missing_header): Copied as-is.
4440 (get_stdlib_header_for_name): New, based on get_c_name_hint but
4441 heavily edited to add C++ support. Add some knowledge about
4442 <limits.h>, <stdint.h>, and <wchar.h>.
4443 * known-headers.h: Likewise.
4444
4445 2017-11-20 David Malcolm <dmalcolm@redhat.com>
4446
4447 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
4448 (lookup_name_fuzzy): Likewise. Convert return type from
4449 const char * to name_hint. Add location_t param.
4450 * name-hint.h: New header.
4451
4452 2017-11-19 Jakub Jelinek <jakub@redhat.com>
4453
4454 PR c/66618
4455 PR c/69960
4456 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
4457
4458 2017-11-16 Joseph Myers <joseph@codesourcery.com>
4459
4460 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
4461 expected publication date of C17.
4462 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
4463
4464 2017-11-15 Joseph Myers <joseph@codesourcery.com>
4465
4466 PR c/81156
4467 * c-common.c (c_common_reswords): Add __builtin_tgmath.
4468 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
4469
4470 2017-11-10 Martin Sebor <msebor@redhat.com>
4471
4472 PR c/81117
4473 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
4474 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
4475 * c.opt (-Wstringop-truncation): New option.
4476
4477 2017-11-06 Martin Liska <mliska@suse.cz>
4478
4479 PR middle-end/82404
4480 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
4481 FE.
4482 * c.opt: Set default value of warn_return_type.
4483
4484 2017-10-31 David Malcolm <dmalcolm@redhat.com>
4485
4486 * c-common.c (binary_op_error): Update for renaming of
4487 error_at_rich_loc.
4488 (c_parse_error): Likewise.
4489 * c-warn.c (warn_logical_not_parentheses): Likewise for
4490 renaming of inform_at_rich_loc.
4491 (warn_for_restrict): Likewise for renaming of
4492 warning_at_rich_loc_n.
4493
4494 2017-10-30 Joseph Myers <joseph@codesourcery.com>
4495
4496 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
4497 * c-opts.c (set_std_c17): New function.
4498 (c_common_init_options): Use gnu17 as default C version.
4499 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
4500
4501 2017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
4502
4503 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
4504 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
4505 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
4506 __FP_FAST_FMA<N>X.
4507
4508 2017-10-23 Marek Polacek <polacek@redhat.com>
4509
4510 PR c/82681
4511 * c-warn.c (warnings_for_convert_and_check): Fix typos.
4512
4513 2017-10-19 Eric Botcazou <ebotcazou@adacore.com>
4514
4515 * c-common.c (check_builtin_function_arguments): Also check arguments
4516 of __builtin_alloca_with_align_and_max.
4517
4518 2017-10-17 David Malcolm <dmalcolm@redhat.com>
4519
4520 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
4521 rather than NULL to format_warning_va.
4522 (check_format_types): Likewise when calling format_type_warning.
4523 Remove code to extract source_ranges and source_range * in favor
4524 of just a location_t.
4525 (format_type_warning): Convert source_range * param to a
4526 location_t.
4527
4528 2017-10-13 Jakub Jelinek <jakub@redhat.com>
4529
4530 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
4531 [LR]SHIFT_EXPR.
4532
4533 2017-10-12 David Malcolm <dmalcolm@redhat.com>
4534
4535 * c-common.c (enum missing_token_insertion_kind): New enum.
4536 (get_missing_token_insertion_kind): New function.
4537 (maybe_suggest_missing_token_insertion): New function.
4538 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
4539
4540 2017-10-11 Nathan Sidwell <nathan@acm.org>
4541
4542 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
4543 (c_common_handle_option): Update incpath_kind names.
4544
4545 2017-10-11 Martin Liska <mliska@suse.cz>
4546
4547 PR sanitizer/82490
4548 * c-attribs.c (handle_no_sanitize_attribute): Report directly
4549 Wattributes warning.
4550
4551 2017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
4552
4553 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
4554 operating on trees as wide_ints.
4555 * c-common.c (pointer_int_sum): Likewise.
4556 * c-pretty-print.c (pp_c_integer_constant): Likewise.
4557 * c-warn.c (match_case_to_enum_1): Likewise.
4558 (c_do_switch_warnings): Likewise.
4559 (maybe_warn_shift_overflow): Likewise.
4560
4561 2017-10-10 Jakub Jelinek <jakub@redhat.com>
4562
4563 PR c/82437
4564 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
4565 instead of wide_int::from.
4566
4567 2017-10-06 Jakub Jelinek <jakub@redhat.com>
4568
4569 PR c/82437
4570 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
4571 using to_widest use wide_int with the larger of the two precisions.
4572
4573 2017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
4574
4575 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
4576 functions.
4577
4578 2017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
4579
4580 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
4581 when combining the original unconverted comparison operands.
4582
4583 2017-09-29 Jakub Jelinek <jakub@redhat.com>
4584
4585 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
4586 attribute.
4587
4588 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
4589
4590 * c-ada-spec.c (to_ada_name): Add index parameter.
4591 (pp_ada_tree_identifier): Likewise.
4592 (dump_ada_macros): Adjust call to to_ada_name.
4593 (struct overloaded_name_hash): New type.
4594 (struct overloaded_name_hasher): Likewise.
4595 (overloaded_names): New hash table.
4596 (compute_overloading_index): New function.
4597 (dump_ada_decl_name): Call it and pass the result to
4598 pp_ada_tree_identifier.
4599 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
4600 (dump_ada_function_declaration): Likewise.
4601 (dump_generic_ada_node): Likewise.
4602 (print_constructor): Likewise.
4603 (print_destructor): Likewise.
4604 (dump_ada_specs): Delete overloaded_names table.
4605
4606 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
4607
4608 * c-ada-spec.c (max_ada_macros): Move around.
4609 (store_ada_macro_index): Likewise.
4610 (source_file): Rename into...
4611 (macro_source_file): ...this.
4612 (count_ada_macro): Move around.
4613 (store_ada_macro): Likewise.
4614 (compare_macro): Likewise.
4615 (print_ada_macros): Merge in...
4616 (dump_ada_macros): ...this.
4617 (source_file_base): Rename into...
4618 (current_source_file): ...this.
4619 (print_comment): Move around.
4620 (dump_ada_nodes): Call dump_ada_declaration directly.
4621 (struct with): Change type of limited field to bool.
4622 (append_withs): Change type of limited_access parameter to bool.
4623 (pp_ada_tree_identifie): Likewise.
4624 (dump_ada_decl_nam): Likewise.
4625 (dump_generic_ada_node): Likewise. Do not print the return type.
4626 (to_ada_name): Change type of space_found parameter to bool.
4627 (dump_ada_function_declaration): Return void and change type of
4628 parameters to bool. Also print the return type for a function.
4629 (print_ada_methods): Rename into...
4630 (dump_ada_methods): ...this.
4631 (print_ada_declaration): Rename into ...
4632 (dump_ada_declaration): ...this. Do not print the return type.
4633 (print_ada_struct_decl): Rename into...
4634 (dump_ada_struct_decl): ...this.
4635
4636 2017-09-29 Jakub Jelinek <jakub@redhat.com>
4637
4638 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
4639 rather than DECL_INITIAL.
4640 (common_handle_aligned_attribute): Likewise.
4641
4642 2017-09-20 Alexandre Oliva <aoliva@redhat.com>
4643
4644 * c.opt (gen-decls): Add RejectNegative.
4645
4646 2017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
4647 Jakub Jelinek <jakub@redhat.com>
4648
4649 Add support for -std=c++2a.
4650 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
4651 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
4652 * c-opts.c (set_std_cxx2a): New.
4653 (c_common_handle_option): Set options when -std=c++2a is enabled.
4654 (c_common_post_options): Adjust comments.
4655 (set_std_cxx14, set_std_cxx17): Likewise.
4656
4657 2017-09-15 Eric Botcazou <ebotcazou@adacore.com>
4658
4659 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
4660 message for non-uniform endianness and issue a warning in C++.
4661
4662 2017-09-15 Jakub Jelinek <jakub@redhat.com>
4663
4664 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
4665 (Wc++17-compat): Change from undocumented alias to option.
4666 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
4667 change C++1z to C++17 in description.
4668 (std=c++1z, std=gnu++1z): Change from option to undocumented
4669 deprecated alias.
4670 (std=c++17, std=gnu++17): Change from undocumented alias to option.
4671 Adjust description.
4672 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
4673 * c-opts.c (set_std_cxx1z): Rename to ...
4674 (set_std_cxx17): ... this.
4675 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
4676 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
4677 caller.
4678 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
4679 comments.
4680
4681 2017-09-12 H.J. Lu <hongjiu.lu@intel.com>
4682
4683 * c-attribs.c (common_handle_aligned_attribute): Don't warn
4684 function alignment if warn_if_not_aligned_p is true.
4685
4686 2017-09-12 Nathan Sidwell <nathan@acm.org>
4687
4688 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
4689 resort_sorted_fields): Move to c/c-decl.c.
4690 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
4691 (struct sorted_fields_type): Move to c/c-lang.h.
4692
4693 2017-09-09 Jonathan Wakely <jwakely@redhat.com>
4694
4695 PR c++/81852
4696 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
4697
4698 2017-09-04 Marek Polacek <polacek@redhat.com>
4699
4700 PR c/81783
4701 * c-warn.c (warn_tautological_bitwise_comparison): New function.
4702 (warn_tautological_cmp): Call it.
4703
4704 2017-09-01 Boris Kolpackov <boris@codesynthesis.com>
4705
4706 * c-opts.c (c_common_finish): Write dependency information even if
4707 there are errors.
4708
4709 2017-09-01 Jakub Jelinek <jakub@redhat.com>
4710
4711 PR c/81887
4712 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
4713 (omp_pragmas_simd): ... here.
4714 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
4715 create new clauses list containing just simd clause.
4716
4717 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4718 Alan Hayward <alan.hayward@arm.com>
4719 David Sherwood <david.sherwood@arm.com>
4720
4721 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
4722 into scalar_mode_supported_p call.
4723 (handle_mode_attribute): Update call to scalar_mode_supported_p.
4724
4725 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4726 Alan Hayward <alan.hayward@arm.com>
4727 David Sherwood <david.sherwood@arm.com>
4728
4729 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
4730 for the mode iterator.
4731
4732 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4733 Alan Hayward <alan.hayward@arm.com>
4734 David Sherwood <david.sherwood@arm.com>
4735
4736 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
4737 * c-common.c (c_build_vec_perm_expr): Likewise.
4738
4739 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4740 Alan Hayward <alan.hayward@arm.com>
4741 David Sherwood <david.sherwood@arm.com>
4742
4743 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
4744
4745 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4746 Alan Hayward <alan.hayward@arm.com>
4747 David Sherwood <david.sherwood@arm.com>
4748
4749 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
4750 before calling targetm.addr_space.valid_pointer_mode.
4751
4752 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4753 Alan Hayward <alan.hayward@arm.com>
4754 David Sherwood <david.sherwood@arm.com>
4755
4756 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
4757
4758 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4759 Alan Hayward <alan.hayward@arm.com>
4760 David Sherwood <david.sherwood@arm.com>
4761
4762 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
4763 iterators.
4764 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
4765
4766 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
4767 Alan Hayward <alan.hayward@arm.com>
4768 David Sherwood <david.sherwood@arm.com>
4769
4770 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
4771 case statements.
4772
4773 2017-08-29 Martin Liska <mliska@suse.cz>
4774
4775 PR other/39851
4776 * c-common.c (parse_optimize_options): Add argument to function
4777 call.
4778 * c-pragma.c (handle_pragma_diagnostic): Likewise.
4779
4780 2017-08-24 David Malcolm <dmalcolm@redhat.com>
4781
4782 * c-lex.c (interpret_float): Use token location
4783 when building an EXCESS_PRECISION_EXPR.
4784
4785 2017-08-21 David Malcolm <dmalcolm@redhat.com>
4786
4787 * c-common.c (check_function_arguments): Add "arglogs" param; pass
4788 it to check_function_format.
4789 * c-common.h (check_function_arguments): Add vec<location_t> *
4790 param.
4791 (check_function_format): Likewise.
4792 * c-format.c (struct format_check_context): Add field "arglocs".
4793 (check_function_format): Add param "arglocs"; pass it to
4794 check_format_info.
4795 (check_format_info): Add param "arglocs"; use it to initialize
4796 new field of format_ctx.
4797 (check_format_arg): Pass format_ctx->arglocs to new param of
4798 check_format_info_main.
4799 (class argument_parser): New field "arglocs".
4800 (argument_parser::argument_parser): Add "arglocs_" param and use
4801 it to initialize new field.
4802 (argument_parser::check_argument_type): Pass new arglocs field to
4803 check_format_types.
4804 (check_format_info_main): Add param "arglocs", and use it when
4805 constructing arg_parser.
4806 (check_format_types): Add param "arglocs"; use it if non-NULL when
4807 !EXPR_HAS_LOCATION (cur_param) to get at location information.
4808
4809 2017-08-18 H.J. Lu <hongjiu.lu@intel.com>
4810
4811 PR c/53037
4812 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
4813 (c_common_attribute_table): Add warn_if_not_aligned.
4814 (handle_aligned_attribute): Renamed to ...
4815 (common_handle_aligned_attribute): Remove argument, name, and add
4816 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
4817 (handle_aligned_attribute): New.
4818 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
4819
4820 2017-08-14 Martin Sebor <msebor@redhat.com>
4821
4822 PR c/81117
4823 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
4824 (handle_nonstring_attribute): New function.
4825
4826 2017-08-14 Martin Sebor <msebor@redhat.com>
4827
4828 PR c/81117
4829 * c-format.h (T89_G): New macro.
4830 * c-format.c (local_gcall_ptr_node): New variable.
4831 (init_dynamic_diag_info): Initialize it.
4832
4833 2017-08-11 Martin Liska <mliska@suse.cz>
4834
4835 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
4836 TARGET_SUPPORTS_ALIASES.
4837
4838 2017-08-10 David Malcolm <dmalcolm@redhat.com>
4839
4840 * c-common.c (c_parse_error): Add rich_location * param, using it
4841 rather implicitly using input_location.
4842 * c-common.h (c_parse_error): Add rich_location * param.
4843
4844 2017-08-09 Marek Polacek <polacek@redhat.com>
4845
4846 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
4847 (c_common_truthvalue_conversion): Likewise.
4848 * c-omp.c (c_finish_omp_atomic): Likewise.
4849 * c-common.h (build_binary_op): Update declaration.
4850
4851 2017-08-08 Martin Liska <mliska@suse.cz>
4852
4853 * c-ada-spec.c: Include header files.
4854 * c-ubsan.c: Likewise.
4855 * c-warn.c: Likewise.
4856
4857 2017-08-07 Jakub Jelinek <jakub@redhat.com>
4858
4859 PR c/69389
4860 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
4861
4862 2017-08-07 Eric Botcazou <ebotcazou@adacore.com>
4863
4864 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
4865 (print_ada_methods): Likewise.
4866 (print_ada_declaration): Likewise.
4867
4868 2017-08-07 Martin Liska <mliska@suse.cz>
4869
4870 * array-notation-common.c: Add new includes.
4871 * c-format.c( handle_format_attribute): Canonicalize a format
4872 function name.
4873 * c-lex.c (c_common_has_attribute): Canonicalize name of an
4874 attribute.
4875 * c-pretty-print.c: Add new include.
4876
4877 2017-08-05 Eric Botcazou <ebotcazou@adacore.com>
4878
4879 * c-ada-spec.c (has_static_fields): Look only into variables.
4880 (print_constructor): Add TYPE parameter and use it for the name.
4881 (print_destructor): Likewise.
4882 (print_ada_declaration): Adjust to new constructor/destructor names.
4883 Adjust calls to print_constructor and print_destructor.
4884 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
4885 Look only into variables in the final loop.
4886
4887 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
4888
4889 * c-ada-spec.c (has_static_fields): Look only into fields.
4890 (dump_generic_ada_node): Small tweak.
4891 (dump_nested_types): Look only into fields.
4892 (print_ada_declaration): Look only into methods. Small tweak.
4893 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
4894
4895 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
4896
4897 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
4898 (dump_ada_function_declaration): Likewise.
4899 (dump_generic_ada_node): Likewise.
4900 (print_ada_declaration): Add support for const-qualified variables.
4901
4902 2017-07-31 Martin Liska <mliska@suse.cz>
4903
4904 PR sanitize/81530
4905 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
4906 Guard condition with flag_sanitize_p also with current_function_decl
4907 non-null equality.
4908 (ubsan_maybe_instrument_reference_or_call): Likewise.
4909
4910 2017-07-30 Uros Bizjak <ubizjak@gmail.com>
4911
4912 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
4913
4914 2017-07-29 Eric Botcazou <ebotcazou@adacore.com>
4915
4916 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
4917 for enumeral types.
4918 (print_ada_declaration): Add missing guard for record types.
4919
4920 2017-07-27 Jakub Jelinek <jakub@redhat.com>
4921
4922 PR c/45784
4923 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
4924 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
4925 new COMPOUND_EXPRs around the rhs of the comparison.
4926
4927 2017-07-27 Marek Polacek <polacek@redhat.com>
4928
4929 PR c/81417
4930 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
4931 the types.
4932
4933 2017-07-27 Jakub Jelinek <jakub@redhat.com>
4934
4935 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
4936 (handle_noipa_attribute): New function.
4937
4938 2017-07-07 Torsten Duwe <duwe@suse.de>
4939
4940 * c-attribs.c (c_common_attribute_table): Add entry for
4941 "patchable_function_entry".
4942
4943 2017-07-20 Nathan Sidwell <nathan@acm.org>
4944
4945 Remove TYPE_METHODS.
4946 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
4947 dump_ada_template, print_ada_methods,
4948 print_ada_declaration): Member fns are on TYPE_FIELDS.
4949
4950 2017-07-18 Nathan Sidwell <nathan@acm.org>
4951
4952 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
4953
4954 2017-07-14 David Malcolm <dmalcolm@redhat.com>
4955
4956 * c-common.c (try_to_locate_new_include_insertion_point): New
4957 function.
4958 (per_file_includes_t): New typedef.
4959 (added_includes_t): New typedef.
4960 (added_includes): New variable.
4961 (maybe_add_include_fixit): New function.
4962 * c-common.h (maybe_add_include_fixit): New decl.
4963
4964 2017-07-10 Martin Sebor <msebor@redhat.com>
4965
4966 PR other/81345
4967 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
4968
4969 2017-07-06 David Malcolm <dmalcolm@redhat.com>
4970
4971 * c-common.c (selftest::c_family_tests): New.
4972 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
4973 (selftest::c_family_tests): New decl.
4974
4975 2017-07-04 Marek Polacek <polacek@redhat.com>
4976
4977 PR c/81231
4978 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
4979 types.
4980
4981 2017-07-04 Marek Polacek <polacek@redhat.com>
4982
4983 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
4984
4985 2017-06-28 Martin Liska <mliska@suse.cz>
4986
4987 PR ipa/81128
4988 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
4989 to a function declaration.
4990
4991 2017-06-28 Martin Liska <mliska@suse.cz>
4992
4993 PR driver/79659
4994 * c.opt: Add IntegerRange to various options.
4995
4996 2017-06-26 Marek Polacek <polacek@redhat.com>
4997
4998 PR c/80116
4999 * c-common.h (warn_for_multistatement_macros): Declare.
5000 * c-warn.c: Include "c-family/c-indentation.h".
5001 (warn_for_multistatement_macros): New function.
5002 * c.opt (Wmultistatement-macros): New option.
5003 * c-indentation.c (guard_tinfo_to_string): No longer static.
5004 Change the parameter type to "enum rid". Handle RID_SWITCH.
5005 * c-indentation.h (guard_tinfo_to_string): Declare.
5006
5007 2017-06-23 Marc Glisse <marc.glisse@inria.fr>
5008
5009 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
5010
5011 2017-06-15 Martin Sebor <msebor@redhat.com>
5012
5013 PR c++/80560
5014 * c.opt (-Wclass-memaccess): New option.
5015
5016 2017-06-14 Boris Kolpackov <boris@codesynthesis.com>
5017
5018 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
5019
5020 2017-06-13 Marek Polacek <polacek@redhat.com>
5021
5022 PR objc/80949
5023 * c-warn.c (do_warn_duplicated_branches): Return if any of the
5024 branches is null.
5025
5026 2017-06-13 Martin Liska <mliska@suse.cz>
5027
5028 PR sanitize/78204
5029 * c-attribs.c (add_no_sanitize_value): New function.
5030 (handle_no_sanitize_attribute): Likewise.
5031 (handle_no_sanitize_address_attribute): Use the function.
5032 (handle_no_sanitize_thread_attribute): New function.
5033 (handle_no_address_safety_analysis_attribute): Use
5034 add_no_sanitize_value.
5035 (handle_no_sanitize_undefined_attribute): Likewise.
5036 * c-common.h: Declare new functions.
5037 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
5038 (ubsan_instrument_shift): Likewise.
5039 (ubsan_instrument_bounds): Likewise.
5040 (ubsan_maybe_instrument_array_ref): Likewise.
5041 (ubsan_maybe_instrument_reference_or_call): Likewise.
5042
5043 2017-06-11 Jason Merrill <jason@redhat.com>
5044
5045 * c-ada-spec.c, c-pragma.c: Use id_equal.
5046
5047 2017-06-04 Marek Polacek <polacek@redhat.com>
5048
5049 PR c/80919
5050 * c-format.c (matching_type_p): Return false if any of the types
5051 requires structural equality.
5052
5053 2017-06-02 Martin Sebor <msebor@redhat.com>
5054
5055 PR c/80892
5056 * c-warn.c (conversion_warning): Use -Wconversion for integer
5057 conversion and -Wfloat-conversion for floating one.
5058
5059 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
5060
5061 * c.opt (Wsizeof-pointer-div): New warning option.
5062
5063 2017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
5064
5065 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
5066 (Wcatch-value=1): Enable by -Wall.
5067
5068 2017-05-30 David Malcolm <dmalcolm@redhat.com>
5069
5070 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
5071 format_chars.
5072 * c.opt (fdiagnostics-show-template-tree): New option.
5073 (felide-type): New option.
5074
5075 2017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
5076
5077 * c.opt (Wcatch-value=): New C++ warning flag.
5078
5079 2017-05-24 Nathan Sidwell <nathan@acm.org>
5080
5081 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
5082 const casts to avoid warning.
5083
5084 2017-05-24 Martin Sebor <msebor@redhat.com>
5085
5086 PR c/80731
5087 * c-common.h (unsafe_conversion_p): Add a function argument.
5088 * c-common.c (unsafe_conversion_p): Same.
5089 Add type names and values to diagnostics.
5090 (scalar_to_vector): Adjust.
5091 * c-warn.c (constant_expression_error): Add a function argument.
5092 Add type names and values to diagnostics.
5093 (conversion_warning): Add a function argument.
5094 Add type names and values to diagnostics.
5095 (warnings_for_convert_and_check): Same.
5096
5097 2017-05-19 Jason Merrill <jason@redhat.com>
5098
5099 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
5100 enumerators.
5101
5102 2017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
5103
5104 * c-format.c (locus): Move out of function scope,
5105 add GTY attribute.
5106
5107 2017-05-19 Nathan Sidwell <nathan@acm.org>
5108
5109 * c-opts.c (class_dump_file, class_dump_flags): Delete.
5110 (c_common_parse_file): Remove class dump handling.
5111 (get_dump_info): Likewise.
5112
5113 2017-05-19 Richard Biener <rguenther@suse.de>
5114
5115 PR c++/80593
5116 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
5117 to alias-set zero memory.
5118
5119 2017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
5120
5121 * c-format.c (local_tree_type_node): Add GTY attribute.
5122
5123 2017-05-18 Marek Polacek <polacek@redhat.com>
5124
5125 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
5126 (c_common_fixed_point_type_for_size): Likewise.
5127 (c_common_type_for_mode): Likewise.
5128 (shorten_compare): Likewise.
5129 (c_promoting_integer_type_p): Use false/true instead of 0/1.
5130 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
5131
5132 2017-05-18 Marek Polacek <polacek@redhat.com>
5133
5134 * c-common.c (self_promoting_args_p): Change the return type to bool.
5135 Use false/true instead of 0/1.
5136 * c-common.h (self_promoting_args_p): Update.
5137
5138 2017-05-17 Marek Polacek <polacek@redhat.com>
5139
5140 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
5141 * c-warn.c: Likewise.
5142
5143 2017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
5144
5145 Implement new C++ intrinsics __is_assignable and __is_constructible.
5146 * c-common.c (__is_assignable, __is_constructible): New.
5147 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
5148
5149 2017-05-17 Martin Liska <mliska@suse.cz>
5150
5151 * c-common.h: Introduce dump_flags_t type and
5152 use it instead of int type.
5153 * c-gimplify.c (c_genericize): Likewise.
5154 * c-opts.c: Likewise.
5155
5156 2017-05-17 Marek Polacek <polacek@redhat.com>
5157
5158 * c-common.c (c_save_expr): Remove.
5159 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
5160 * c-common.h (c_save_expr): Remove declaration.
5161
5162 2017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
5163
5164 PR c/35441
5165 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
5166 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
5167 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
5168 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
5169 RDIV_EXPR.
5170 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
5171
5172 2017-05-09 Marek Polacek <polacek@redhat.com>
5173
5174 PR c/80525
5175 * c-warn.c (unwrap_c_maybe_const): New.
5176 (warn_logical_operator): Call it.
5177
5178 2017-05-09 Nathan Sidwell <nathan@acm.org>
5179
5180 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
5181 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
5182
5183 2017-05-08 Martin Sebor <msebor@redhat.com>
5184
5185 PR translation/80280
5186 * c-format.h (struct format_flag_spec): Add new member.
5187 (T89_T): New macro.
5188 * c-format.c (local_tree_type_node): New global.
5189 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
5190 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
5191 (strfmon_flag_specs): Likewise.
5192 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
5193 with distinct quoting properties.
5194 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
5195 (flag_chars_t::validate): Add argument and handle bad quoting.
5196 (check_format_info_main): Handle quoting problems.
5197 (init_dynamic_diag_info): Simplify.
5198
5199 2017-05-08 Jason Merrill <jason@redhat.com>
5200
5201 * c-opts.c (c_common_post_options): Update defaults for
5202 flag_abi_version and flag_abi_compat_version.
5203
5204 2017-05-05 David Malcolm <dmalcolm@redhat.com>
5205
5206 * c-common.c (c_cpp_error): Replace report_diagnostic
5207 with diagnostic_report_diagnostic.
5208
5209 2017-05-04 Martin Sebor <msebor@redhat.com>
5210
5211 PR translation/80280
5212 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
5213 (handle_weakref_attribute): Same.
5214
5215 2017-05-03 Nathan Sidwell <nathan@acm.org>
5216
5217 Canonicalize canonical type hashing
5218 * c-common.c (complete_array_type): Use type_hash_canon.
5219
5220 2017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
5221
5222 PR c++/80038
5223 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
5224 prototype.
5225 (cilk_install_body_pedigree_operations): Likewise.
5226 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
5227 detatched.
5228 (cilk_gimplify_call_params_in_spawned_fn): Remove.
5229 (cilk_install_body_pedigree_operations): Likewise.
5230 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
5231 unwrapping.
5232
5233 2017-04-27 Jakub Jelinek <jakub@redhat.com>
5234
5235 PR c++/80534
5236 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
5237 flag on non-aggregate element types.
5238
5239 2017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
5240
5241 * c-common.c (c_type_hasher, type_hash_table): Remove.
5242 (c_common_get_alias_set): Remove unreachable code.
5243 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
5244
5245 2017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
5246
5247 * c.opt (Wextra-semi): New C++ warning flag.
5248
5249 2017-04-20 Jakub Jelinek <jakub@redhat.com>
5250
5251 PR middle-end/80423
5252 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
5253
5254 2017-04-18 Jakub Jelinek <jakub@redhat.com>
5255
5256 PR middle-end/79788
5257 PR middle-end/80375
5258 * c-common.c (c_common_type_for_mode): Don't handle
5259 widest_*_literal_type_node here.
5260 c_common_signed_or_unsigned_type): Likewise.
5261 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
5262 to *intTI_type_node or *intDI_type_node depending on whether
5263 TImode is supported by the target or not.
5264
5265 2017-04-10 Martin Liska <mliska@suse.cz>
5266
5267 PR sanitizer/80350
5268 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
5269 doing an UBSAN check.
5270
5271 2017-04-03 Jonathan Wakely <jwakely@redhat.com>
5272
5273 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
5274
5275 2017-03-31 Jakub Jelinek <jakub@redhat.com>
5276
5277 PR c++/79572
5278 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
5279 tree *.
5280 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
5281 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
5282 REFERENCE_TYPE.
5283
5284 2017-03-31 David Malcolm <dmalcolm@redhat.com>
5285
5286 PR documentation/78732
5287 * c.opt (Wendif-labels): Fix description to refer to
5288 #else rather than #elif.
5289
5290 2017-03-31 Jakub Jelinek <jakub@redhat.com>
5291
5292 PR libstdc++/80251
5293 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
5294 * c-common.c (c_common_reswords): Add __is_aggregate trait.
5295
5296 2017-03-27 Jakub Jelinek <jakub@redhat.com>
5297
5298 PR middle-end/80162
5299 * c-common.c (c_common_mark_addressable_vec): Don't set
5300 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
5301
5302 2017-03-21 Martin Sebor <msebor@redhat.com>
5303
5304 PR c++/79548
5305 * c-common.c (set_underlying_type): Mark type used only when
5306 original del is declared unused.
5307
5308 2017-03-10 David Malcolm <dmalcolm@redhat.com>
5309
5310 PR translation/79848
5311 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
5312 "%qs".
5313
5314 2017-03-10 David Malcolm <dmalcolm@redhat.com>
5315
5316 PR c/79921
5317 * c-indentation.c (warn_for_misleading_indentation): Remove parens
5318 from inform's message, so that xgettext can locate it.
5319
5320 2017-03-09 Marek Polacek <polacek@redhat.com>
5321
5322 PR c++/79962
5323 PR c++/79984
5324 * c-attribs.c (handle_nonnull_attribute): Save the result of default
5325 conversion to the attribute list.
5326
5327 2017-03-09 Martin Liska <mliska@suse.cz>
5328
5329 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
5330
5331 2017-03-03 Jason Merrill <jason@redhat.com>
5332
5333 * c.opt (Wnoexcept-type): New.
5334
5335 2017-03-02 Richard Biener <rguenther@suse.de>
5336
5337 PR c/79756
5338 * c-common.c (c_common_mark_addressable_vec): Look through
5339 C_MAYBE_CONST_EXPR.
5340
5341 2017-02-28 Martin Liska <mliska@suse.cz>
5342
5343 * c.opt: Replace space with tabular for options of <number>
5344 type.
5345
5346 2017-02-28 Martin Liska <mliska@suse.cz>
5347
5348 * c.opt: Fix --help=option -Q for options which are of
5349 an enum type.
5350
5351 2017-02-24 Jakub Jelinek <jakub@redhat.com>
5352
5353 PR c++/79588
5354 * c-common.c (check_function_restrict): New function.
5355 (check_function_arguments): Add FNDECL argument. Call
5356 check_function_restrict if -Wrestrict.
5357 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
5358 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
5359 * c-common.h (check_function_arguments): Add FNDECL argument.
5360 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
5361
5362 2017-02-24 Eric Botcazou <ebotcazou@adacore.com>
5363
5364 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
5365 treatment of parameters with pointer-to-tagged type and tidy up.
5366 (print_ada_methods): Remove the special treatment of C++ static member
5367 functions.
5368
5369 2017-02-22 Martin Liska <mliska@suse.cz>
5370
5371 * c.opt: Replace inequality signs with square brackets
5372 for -Wnornalized.
5373
5374 2017-02-21 Jakub Jelinek <jakub@redhat.com>
5375
5376 PR c++/79641
5377 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
5378 preserve quals.
5379
5380 2017-02-17 Joseph Myers <joseph@codesourcery.com>
5381
5382 * c-cppbuiltin.c (builtin_define_float_constants): Define
5383 __DECIMAL_DIG__ to the value for long double.
5384
5385 2017-02-15 Marek Polacek <polacek@redhat.com>
5386
5387 PR c/79515
5388 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
5389 conversion has occured.
5390
5391 2017-01-24 David Malcolm <dmalcolm@redhat.com>
5392
5393 * c-common.c (c_common_reswords): Add "__RTL".
5394 * c-common.h (enum rid): Add RID_RTL.
5395
5396 2017-01-20 Marek Polacek <polacek@redhat.com>
5397
5398 PR c/64279
5399 * c-common.h (do_warn_duplicated_branches_r): Declare.
5400 * c-gimplify.c (c_genericize): Walk the function tree calling
5401 do_warn_duplicated_branches_r.
5402 * c-warn.c (expr_from_macro_expansion_r): New.
5403 (do_warn_duplicated_branches): New.
5404 (do_warn_duplicated_branches_r): New.
5405 * c.opt (Wduplicated-branches): New option.
5406
5407 2017-01-17 David Malcolm <dmalcolm@redhat.com>
5408
5409 PR c++/71497
5410 * c-indentation.c (warn_for_misleading_indentation): Use the past
5411 subjunctive in the note.
5412
5413 2017-01-17 Aldy Hernandez <aldyh@redhat.com>
5414
5415 PR c/79116
5416 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
5417 start type to integer_type.
5418
5419 2017-01-16 Jakub Jelinek <jakub@redhat.com>
5420
5421 PR driver/49726
5422 * c.opt (gen-decls): Add Driver flag.
5423
5424 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
5425
5426 Revert:
5427 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
5428
5429 PR c++/71737
5430 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
5431
5432 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
5433
5434 PR c++/71737
5435 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
5436
5437 2017-01-12 Martin Sebor <msebor@redhat.com>
5438
5439 (-Wformat-overflow): ...to this.
5440
5441 2017-01-11 Martin Sebor <msebor@redhat.com>
5442
5443 PR c/78768
5444 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
5445 Also enable for LTO.
5446
5447 2017-01-10 Jason Merrill <jason@redhat.com>
5448
5449 Implement P0195R2, C++17 variadic using.
5450 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
5451
5452 2017-01-09 Jakub Jelinek <jakub@redhat.com>
5453
5454 PR translation/79019
5455 PR translation/79020
5456 * c.opt (Wnormalized=): Fix typo in description.
5457
5458 2017-01-08 Martin Sebor <msebor@redhat.com>
5459
5460 PR middle-end/77708
5461 * c.opt (-Wformat-truncation): New option.
5462
5463 2017-01-06 Alexandre Oliva <aoliva@redhat.com>
5464
5465 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
5466 value to unsigned short to fit in 4 hex digits without
5467 warnings.
5468
5469 2017-01-05 Eric Botcazou <ebotcazou@adacore.com>
5470
5471 * c.opt (fsso-struct): Add 'native' value.
5472
5473 2017-01-05 Martin Liska <mliska@suse.cz>
5474
5475 PR pch/78970
5476 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
5477 header.
5478
5479 2017-01-04 Marek Polacek <polacek@redhat.com>
5480
5481 PR c++/64767
5482 * c.opt (Wpointer-compare): New option.
5483
5484 2017-01-04 Jakub Jelinek <jakub@redhat.com>
5485
5486 PR driver/78957
5487 * c.opt (fsso-struct=): Add RejectNegative.
5488
5489 2017-01-01 Jakub Jelinek <jakub@redhat.com>
5490
5491 Update copyright years.
5492
5493 2016-12-29 Martin Liska <mliska@suse.cz>
5494
5495 PR c/78933
5496 * c.opt (strong-eval-order): Add RejectNegative keyword.
5497
5498 2016-12-22 Jason Merrill <jason@redhat.com>
5499
5500 Implement P0522R0, matching of template template arguments.
5501 * c-cppbuiltin.c (c_cpp_builtins): Define
5502 __cpp_template_template_args.
5503
5504 2016-12-21 Jakub Jelinek <jakub@redhat.com>
5505
5506 PR bootstrap/78817
5507 * c-common.c (struct nonnull_arg_ctx): New type.
5508 (check_function_nonnull): Return bool instead of void. Use
5509 nonnull_arg_ctx as context rather than just location_t.
5510 (check_nonnull_arg): Adjust for the new context type, set
5511 warned_p to true if a warning has been diagnosed.
5512 (check_function_arguments): Return bool instead of void.
5513 * c-common.h (check_function_arguments): Adjust prototype.
5514
5515 2016-12-21 Jason Merrill <jason@redhat.com>
5516
5517 * c.opt (-fnew-ttp-matching): New flag.
5518 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
5519
5520 2016-12-14 Martin Jambor <mjambor@suse.cz>
5521
5522 * c-omp.c: Include omp-general.h instead of omp-low.h.
5523 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
5524 name.
5525
5526 2016-12-14 Martin Sebor <msebor@redhat.com>
5527
5528 PR c/17308
5529 * c-common.c (check_nonnull_arg): Disable when optimization
5530 is enabled.
5531
5532 2016-12-12 Marek Polacek <polacek@redhat.com>
5533
5534 PR c++/78647
5535 * c-common.c (attribute_fallthrough_p): Return false for
5536 error_mark_node.
5537
5538 2016-12-08 Martin Sebor <msebor@redhat.com>
5539
5540 PR c/78284
5541 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
5542
5543 2016-12-08 Martin Sebor <msebor@redhat.com>
5544
5545 PR c/78165
5546 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
5547 suffix.
5548
5549 2016-12-07 Martin Sebor <msebor@redhat.com>
5550
5551 PR c/53562
5552 PR middle-end/77784
5553 PR middle-end/78149
5554 PR middle-end/78138
5555 * c.opt (-Wstringop-overflow): New option.
5556
5557 2016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
5558
5559 * c-attribs.c (asan odr indicator): New attribute.
5560 (handle_asan_odr_indicator_attribute): New function.
5561
5562 2016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
5563
5564 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
5565 ptrdiff_type_node;
5566
5567 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
5568
5569 * c-common.c (excess_precision_mode_join): New.
5570 (c_ts18661_flt_eval_method): New.
5571 (c_c11_flt_eval_method): Likewise.
5572 (c_flt_eval_method): Likewise.
5573 * c-common.h (excess_precision_mode_join): New.
5574 (c_flt_eval_method): Likewise.
5575 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
5576 (cpp_iec_559_value): Call it.
5577 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
5578 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
5579 __FLT_EVAL_METHOD_TS_18661_3__.
5580
5581 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
5582
5583 * c-opts.c (c_common_post_options): Add logic to handle the default
5584 case for -fpermitted-flt-eval-methods.
5585
5586 2016-11-23 Paolo Bonzini <bonzini@gnu.org>
5587
5588 * c.opt (Wexpansion-to-defined): New.
5589
5590 2016-11-23 Jakub Jelinek <jakub@redhat.com>
5591
5592 PR target/78451
5593 * c-pragma.c (handle_pragma_target): Don't replace
5594 current_target_pragma, but chainon the new args to the current one.
5595
5596 2016-11-22 Nathan Sidwell <nathan@acm.org>
5597
5598 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
5599 indentation and formatting.
5600
5601 2016-11-21 Martin Sebor <msebor@redhat.com>
5602
5603 * c.opt (-fprintf-return-value): Enable by default.
5604
5605 2016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
5606
5607 PR c++/71973
5608 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
5609 * c-common.c (c_common_nodes_and_builtins): Initialize
5610 const_tm_ptr_type_node.
5611
5612 2016-11-16 Marek Polacek <polacek@redhat.com>
5613
5614 PR c/78285
5615 * c-common.c (c_add_case_label): Turn error_at calls into inform.
5616
5617 2016-11-14 Jakub Jelinek <jakub@redhat.com>
5618
5619 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
5620
5621 2016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
5622 Richard Biener <rguenther@suse.de>
5623
5624 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
5625 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
5626 * c.opt (fgimple): New option.
5627
5628 2016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
5629
5630 PR c/35503
5631 * c-common.h (warn_for_restrict): Declare.
5632 * c-warn.c: Include gcc-rich-location.h.
5633 (warn_for_restrict): New function.
5634 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
5635 (gcc_cdiag_char_table): Likewise.
5636 (gcc_cxxdiag_char_table): Likewise.
5637 * c.opt (Wrestrict): New option.
5638
5639 2016-11-13 Eric Botcazou <ebotcazou@adacore.com>
5640
5641 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
5642 for nested types only if the type is a record or union and dump SLOC.
5643
5644 2016-11-09 Jason Merrill <jason@redhat.com>
5645
5646 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
5647
5648 2016-11-09 Jakub Jelinek <jakub@redhat.com>
5649
5650 * c-ubsan.c (ubsan_instrument_shift): Handle split
5651 -fsanitize=shift-base and -fsanitize=shift-exponent.
5652
5653 2016-11-07 Jason Merrill <jason@redhat.com>
5654
5655 * c.opt (Wc++1z-compat): New.
5656 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
5657
5658 2016-11-07 Martin Liska <mliska@suse.cz>
5659
5660 * c-warn.c (warn_for_unused_label): Save all labels used
5661 in goto or in &label.
5662
5663 2016-11-03 Jason Merrill <jason@redhat.com>
5664
5665 * c-cppbuiltin.c (c_cpp_builtins): Correct
5666 __cpp_inheriting_constructors.
5667
5668 2016-11-01 Jason Merrill <jason@redhat.com>
5669
5670 * c-cppbuiltin.c (c_cpp_builtins): Update
5671 __cpp_inheriting_constructors.
5672
5673 * c.opt (-fnew-inheriting-ctors): New.
5674 * c-opts.c: Default to on for ABI 11+.
5675
5676 2016-10-31 Jakub Jelinek <jakub@redhat.com>
5677
5678 PR c++/77948
5679 * c.opt (fext-numeric-literals): Add Var and Init.
5680 * c-opts.c (c_common_handle_option): Don't clear
5681 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
5682 (c_common_post_options): Clear it here if not set
5683 explicitly.
5684
5685 2016-10-28 Aldy Hernandez <aldyh@redhat.com>
5686
5687 PR debug/77773
5688 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
5689 if NULL.
5690
5691 2016-10-25 Jakub Jelinek <jakub@redhat.com>
5692
5693 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
5694 * c-common.c (c_common_reswords): Add __builtin_launder.
5695
5696 2016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
5697
5698 * c-common.c (c_common_truthvalue_conversion): Warn for
5699 multiplications in boolean context. Fix the quoting of '<<' and '<'
5700 in the shift warning.
5701
5702 2016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
5703
5704 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
5705
5706 2016-10-20 Jason Merrill <jason@redhat.com>
5707
5708 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
5709
5710 2016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
5711
5712 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
5713 integer shift ops in boolean context.
5714
5715 2016-10-18 Aldy Hernandez <aldyh@redhat.com>
5716
5717 * c.opt (Walloca): New.
5718 (Walloca-larger-than=): New.
5719 (Wvla-larger-than=): New.
5720
5721 2016-10-17 Marek Polacek <polacek@redhat.com>
5722
5723 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
5724 Return immediately when finding a match.
5725 (warn_tautological_cmp): Remove a boolean variable that is no longer
5726 needed.
5727
5728 2016-10-17 Marek Polacek <polacek@redhat.com>
5729
5730 * c-attribs.c: New file.
5731 * c-common.c: Move attributes handling to c-attribs.c.
5732 (get_nonnull_operand): No longer static.
5733 * c-common.h: Move the declarations from c-attribs.c to its own section.
5734
5735 2016-10-14 Jason Merrill <jason@redhat.com>
5736
5737 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
5738 and __cpp_deduction_guides.
5739
5740 2016-10-13 Jason Merrill <jason@redhat.com>
5741
5742 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
5743
5744 2016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
5745
5746 * c-cppbuiltin.c: Include memmodel.h.
5747 * c-opts.c: Likewise.
5748 * c-pragma.c: Likewise.
5749 * c-warn.c: Likewise.
5750
5751 2016-10-12 Jakub Jelinek <jakub@redhat.com>
5752
5753 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
5754 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
5755 * c-opts.c (sanitize_cpp_opts): Initialize
5756 cpp_opts->cpp_warn_implicit_fallthrough.
5757
5758 2016-10-11 Marek Polacek <polacek@redhat.com>
5759
5760 * c-common.c (warning_candidate_p): Change the return type to bool
5761 and return true/false instead of 1/0.
5762 (vector_mode_valid_p): Likewise.
5763
5764 2016-10-11 Marek Polacek <polacek@redhat.com>
5765
5766 * c-common.c (fold_for_warn): No longer static.
5767 (bool_promoted_to_int_p): Likewise.
5768 (c_common_get_narrower): Likewise.
5769 (constant_expression_warning): Move to c-warn.c.
5770 (constant_expression_error): Likewise.
5771 (overflow_warning): Likewise.
5772 (warn_logical_operator): Likewise.
5773 (find_array_ref_with_const_idx_r): Likewise.
5774 (warn_tautological_cmp): Likewise.
5775 (expr_has_boolean_operands_p): Likewise.
5776 (warn_logical_not_parentheses): Likewise.
5777 (warn_if_unused_value): Likewise.
5778 (strict_aliasing_warning): Likewise.
5779 (sizeof_pointer_memaccess_warning): Likewise.
5780 (check_main_parameter_types): Likewise.
5781 (conversion_warning): Likewise.
5782 (warnings_for_convert_and_check): Likewise.
5783 (match_case_to_enum_1): Likewise.
5784 (match_case_to_enum): Likewise.
5785 (c_do_switch_warnings): Likewise.
5786 (warn_for_omitted_condop): Likewise.
5787 (readonly_error): Likewise.
5788 (lvalue_error): Likewise.
5789 (invalid_indirection_error): Likewise.
5790 (warn_array_subscript_with_type_char): Likewise.
5791 (warn_about_parentheses): Likewise.
5792 (warn_for_unused_label): Likewise.
5793 (warn_for_div_by_zero): Likewise.
5794 (warn_for_memset): Likewise.
5795 (warn_for_sign_compare): Likewise.
5796 (do_warn_double_promotion): Likewise.
5797 (do_warn_unused_parameter): Likewise.
5798 (record_locally_defined_typedef): Likewise.
5799 (maybe_record_typedef_use): Likewise.
5800 (maybe_warn_unused_local_typedefs): Likewise.
5801 (maybe_warn_bool_compare): Likewise.
5802 (maybe_warn_shift_overflow): Likewise.
5803 (warn_duplicated_cond_add_or_warn): Likewise.
5804 (diagnose_mismatched_attributes): Likewise.
5805 * c-common.h: Move the declarations from c-warn.c to its own section.
5806 * c-warn.c: New file.
5807
5808 2016-10-08 Jason Merrill <jason@redhat.com>
5809
5810 * c-common.c (c_common_truthvalue_conversion): Don't distribute
5811 into COND_EXPR in C++.
5812
5813 2016-10-08 Jakub Jelinek <jakub@redhat.com>
5814
5815 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
5816 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
5817 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
5818
5819 2016-10-07 Jakub Jelinek <jakub@redhat.com>
5820
5821 Implement LWG2296 helper intrinsic
5822 * c-common.h (enum rid): Add RID_ADDRESSOF.
5823 * c-common.c (c_common_reswords): Add __builtin_addressof.
5824
5825 2016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
5826
5827 PR c++/77700
5828 * c-common.c (c_common_truthvalue_conversion): Warn also for
5829 suspicious enum values in boolean context.
5830
5831 2016-10-06 Jakub Jelinek <jakub@redhat.com>
5832
5833 Implement P0258R2 - helper for C++17
5834 std::has_unique_object_representations trait
5835 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
5836 * c-common.c (c_common_reswords): Add
5837 __has_unique_object_representations.
5838
5839 2016-10-05 Jakub Jelinek <jakub@redhat.com>
5840
5841 PR sanitizer/66343
5842 * c-ubsan.c (ubsan_instrument_return): Don't call
5843 initialize_sanitizer_builtins here.
5844
5845 2016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
5846
5847 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
5848 conditional expression in boolean context when only one arm is
5849 non-boolean.
5850
5851 2016-10-05 Jakub Jelinek <jakub@redhat.com>
5852
5853 PR sanitizer/77823
5854 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
5855 is not integral.
5856
5857 * c-common.c (c_common_reswords): Update comment for C++11.
5858
5859 2016-10-04 Jason Merrill <jason@redhat.com>
5860
5861 * c-common.c (make_tree_vector_from_ctor): New.
5862 * c-common.h: Declare it.
5863
5864 2016-10-04 Jakub Jelinek <jakub@redhat.com>
5865
5866 * c-cppbuiltin.c (c_cpp_builtins): Don't define
5867 __LIBGCC_JCR_SECTION_NAME__.
5868
5869 2016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
5870
5871 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
5872 left shift in boolean context.
5873
5874 2016-09-29 Jakub Jelinek <jakub@redhat.com>
5875
5876 Implement P0001R1 - C++17 removal of register storage class specifier
5877 * c.opt (Wregister): New warning.
5878 * c-opts.c (c_common_post_options): Enable -Wregister by
5879 default for C++17.
5880
5881 2016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
5882
5883 * c-opts.c (c_common_post_options): Remove special case for
5884 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
5885 in C++.
5886
5887 2016-09-27 Jakub Jelinek <jakub@redhat.com>
5888
5889 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
5890 -std=c++1z.
5891
5892 * c-ada-spec.c (print_ada_declaration): Remove break after return.
5893
5894 2016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
5895
5896 * c-common.c: Include memmodel.h.
5897
5898 2016-09-26 Marek Polacek <polacek@redhat.com>
5899
5900 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
5901
5902 2016-09-26 Marek Polacek <polacek@redhat.com>
5903
5904 PR c/7652
5905 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
5906 (handle_fallthrough_attribute): New function.
5907 (attribute_fallthrough_p): New function.
5908 * c-common.h (attribute_fallthrough_p): Declare.
5909
5910 2016-09-24 Marek Polacek <polacek@redhat.com>
5911
5912 PR c/77490
5913 * c.opt (Wbool-operation): New.
5914
5915 2016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
5916
5917 * c-common.c (c_common_truthvalue_conversion): Inhibit
5918 Wint-in-bool-context warning with from_macro_definition_at.
5919 Mention the expression will always evaluate to true.
5920
5921 2016-09-21 Martin Sebor <msebor@redhat.com>
5922
5923 PR bootstrap/77676
5924 * c.opt (fprintf-return-value): Temporarily initialize to zero
5925 to unblock bootstrap failures.
5926
5927 2016-09-21 Jakub Jelinek <jakub@redhat.com>
5928
5929 PR c++/77651
5930 * c.opt (Waligned-new=): Add RejectNegative.
5931 (faligned-new=): Likewise. Spelling fix - change
5932 aligned_new_threshhold to aligned_new_threshold.
5933 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
5934 to aligned_new_threshold.
5935
5936 2016-09-20 Martin Sebor <msebor@redhat.com>
5937
5938 PR middle-end/49905
5939 * c.opt: Add -Wformat-length and -fprintf-return-value.
5940
5941 2016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
5942
5943 PR c++/77434
5944 * c.opt (Wint-in-bool-context): New warning.
5945 * c-common.c (c_common_truthvalue_conversion): Warn on integer
5946 constants in boolean context.
5947
5948 2016-09-19 Joseph Myers <joseph@codesourcery.com>
5949
5950 * c-common.c (max_align_t_align): Also consider alignment of
5951 float128_type_node.
5952
5953 2016-09-15 Jason Merrill <jason@redhat.com>
5954
5955 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
5956 DECL_EXTERNAL.
5957
5958 2016-09-14 Jason Merrill <jason@redhat.com>
5959
5960 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
5961 limit FIELD_DECL, either.
5962
5963 2016-09-14 Marek Polacek <polacek@redhat.com>
5964
5965 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
5966 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
5967 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
5968
5969 2016-09-13 David Malcolm <dmalcolm@redhat.com>
5970
5971 * c-common.c (warn_logical_not_parentheses): Replace
5972 rich_location::add_fixit_insert calls with add_fixit_insert_before
5973 and add_fixit_insert_after, eliminating the "next_loc" calculation.
5974
5975 2016-09-13 Jason Merrill <jason@redhat.com>
5976 Tom de Vries <tom@codesourcery.com>
5977
5978 PR c++/77427
5979 * c-common.c (set_underlying_type): Don't treat array as builtin type.
5980
5981 2016-09-13 Jason Merrill <jason@redhat.com>
5982
5983 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
5984 limit types at all.
5985
5986 2016-09-12 Jason Merrill <jason@redhat.com>
5987
5988 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
5989 bit/byte confusion, allow large alignment for types.
5990
5991 2016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
5992
5993 PR c++/77496
5994 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
5995
5996 2016-09-12 David Malcolm <dmalcolm@redhat.com>
5997
5998 PR c/72858
5999 * c-format.c (argument_parser::check_argument_type): Add params
6000 "type_start" and "conversion_char". Use the former to generate
6001 offset_to_type_start and pass it and conversion_char to
6002 check_format_types.
6003 (check_format_info_main): Capture the start of the type
6004 information as "type_start", and pass it an format_char
6005 to arg_parser.check_argument_type.
6006 (check_format_types): Provide an example in the leading comment.
6007 Add params "offset_to_type_start" and "conversion_char"; pass
6008 them to format_type_warning calls.
6009 (test_get_modifier_for_format_len): Likewise.
6010 (matching_type_p): New function.
6011 (get_format_for_type): Add param "conversion_char" and move
6012 implementation into...
6013 (get_format_for_type_1): ...new function, called twice.
6014 Use new function matching_type_p rather than checking for
6015 TYPE_CANONICAL equality.
6016 (get_corrected_substring): New function.
6017 (format_type_warning): Provide an example in the leading comment.
6018 Add params "offset_to_type_start" and "conversion_char". Replace
6019 call to get_format_for_type with call to get_corrected_substring
6020 and move rejection of hints for widths/precisions there.
6021 (assert_format_for_type_streq): Add param "conversion_char".
6022 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
6023 (test_get_format_for_type_printf): Add conversion chars to the
6024 tests, adding coverage for various combinations of integer
6025 vs double conversions, and for preserving octal and hexadecimal
6026 conversions.
6027 (test_get_format_for_type_scanf): Add conversion chars to the
6028 tests.
6029
6030 2016-09-10 Tom de Vries <tom@codesourcery.com>
6031
6032 PR C/71602
6033 * c-common.c (build_va_arg): Handle more strict
6034 targetm.canonical_va_list_type. Replace first argument type error with
6035 assert.
6036
6037 2016-09-09 Martin Sebor <msebor@redhat.com>
6038
6039 PR c/77520
6040 PR c/77521
6041 * c-format.c (argument_parser::find_format_char_info): Use %qc
6042 format directive unconditionally.
6043
6044 2016-09-09 Jason Merrill <jason@redhat.com>
6045
6046 Implement C++17 new of over-aligned types.
6047 * c.opt: Add -faligned-new and -Waligned-new.
6048 * c-common.c (max_align_t_align): Split out from...
6049 (cxx_fundamental_alignment_p): ...here.
6050 * c-common.h: Declare it.
6051 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
6052
6053 2016-09-09 Joseph Myers <joseph@codesourcery.com>
6054
6055 * c-cppbuiltin.c (builtin_define_type_width): New function.
6056 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
6057 macros.
6058
6059 2016-09-07 David Malcolm <dmalcolm@redhat.com>
6060
6061 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
6062 a POINTER_TYPE.
6063 (substring_loc::get_location): Move to substring-locations.c,
6064 keeping implementation as...
6065 (c_get_substring_location): New function, from the above, reworked
6066 to use accessors rather than member lookup.
6067 * c-common.h (class substring_loc): Move to substring-locations.h,
6068 replacing with a forward decl.
6069 (c_get_substring_location): New decl.
6070 * c-format.c: Include "substring-locations.h".
6071 (format_warning_va): Move to substring-locations.c.
6072 (format_warning_at_substring): Likewise.
6073
6074 2016-09-06 Martin Sebor <msebor@redhat.com>
6075
6076 PR c/77336
6077 * c-format.c (check_function_format): Avoid issuing warnings for
6078 functions unless they call format functions with non-constant
6079 format strings.
6080
6081 2016-09-06 Richard Biener <rguenther@suse.de>
6082
6083 PR c/77450
6084 * c-common.c (c_common_mark_addressable_vec): Handle
6085 COMPOUND_LITERAL_EXPR.
6086
6087 2016-09-05 Marek Polacek <polacek@redhat.com>
6088
6089 PR c/77423
6090 * c-common.c (bool_promoted_to_int_p): New function.
6091 (expr_has_boolean_operands_p): New function.
6092 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
6093 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
6094
6095 2016-09-04 Tom de Vries <tom@codesourcery.com>
6096
6097 revert:
6098 2016-08-29 Tom de Vries <tom@codesourcery.com>
6099
6100 * c-common.c (build_va_arg): Replace first argument type error
6101 with assert.
6102
6103 2016-09-02 Jakub Jelinek <jakub@redhat.com>
6104
6105 PR c/65467
6106 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
6107 (c_finish_omp_for): Reject _Atomic qualified iterators.
6108
6109 2016-09-01 Martin Sebor <msebor@redhat.com>
6110
6111 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
6112 size to guarantee it fits the output of the formatted function
6113 regardless of its arguments.
6114
6115 2016-09-01 Marek Polacek <polacek@redhat.com>
6116
6117 PR c/7652
6118 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
6119 FALLTHRU comments.
6120
6121 2016-08-29 Marek Polacek <polacek@redhat.com>
6122
6123 PR c/77292
6124 * c-common.c (warn_logical_not_parentheses): Don't warn for
6125 a comparison or a logical operator.
6126
6127 2016-08-29 Tom de Vries <tom@codesourcery.com>
6128
6129 * c-common.c (build_va_arg): Fix type comparison assert.
6130
6131 2016-08-29 Tom de Vries <tom@codesourcery.com>
6132
6133 * c-common.c (build_va_arg): Replace first argument type error
6134 with assert.
6135
6136 2016-08-29 Tom de Vries <tom@codesourcery.com>
6137
6138 PR c/77398
6139 * c-common.c (build_va_arg): Add first argument error. Build va_arg
6140 with error_mark_node as va_list instead of with illegal va_list.
6141
6142 2016-08-25 Marek Polacek <polacek@redhat.com>
6143 David Malcolm <dmalcolm@redhat.com>
6144
6145 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
6146 * c-common.h (warn_logical_not_parentheses): Update declaration.
6147
6148 2016-08-22 Marek Polacek <polacek@redhat.com>
6149
6150 PR c++/77321
6151 * c-common.c (warn_for_memset): Check type for null.
6152
6153 2016-08-22 Joseph Myers <joseph@codesourcery.com>
6154
6155 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
6156 _FloatNx types for suffixes for built-in functions.
6157
6158 2016-08-19 Joseph Myers <joseph@codesourcery.com>
6159
6160 PR c/32187
6161 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
6162 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
6163 (RID_FLOAT128X): New enum rid values.
6164 (CASE_RID_FLOATN_NX): New macro.
6165 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
6166 keywords.
6167 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
6168 corresponding complex types.
6169 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
6170 _FloatNx and corresponding complex types.
6171 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
6172 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
6173 and _FloatNx types for the widest type for determining
6174 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
6175 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
6176 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
6177 and _FloatNx types.
6178 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
6179 constants.
6180 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
6181 _FloatNx types.
6182
6183 2016-08-18 David Malcolm <dmalcolm@redhat.com>
6184
6185 * c-opts.c (c_diagnostic_finalizer): Update for change to
6186 diagnostic_show_locus.
6187
6188 2016-08-18 David Malcolm <dmalcolm@redhat.com>
6189
6190 * c-common.c: Include "spellcheck.h".
6191 (cb_get_suggestion): New function.
6192 * c-common.h (cb_get_suggestion): New decl.
6193 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
6194 cb_get_suggestion.
6195
6196 2016-08-18 Marek Polacek <polacek@redhat.com>
6197
6198 PR c/71514
6199 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
6200 and pointer-to-VLA.
6201
6202 2016-08-16 David Malcolm <dmalcolm@redhat.com>
6203
6204 PR c/72857
6205 * c-common.c (substring_loc::get_range): Rename to...
6206 (substring_loc::get_location): ...this, converting param from a
6207 source_range * to a location_t *. Call
6208 get_source_location_for_substring rather than
6209 get_source_range_for_substring, and pass in m_caret_idx.
6210 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
6211 (substring_loc::get_range): Replace with...
6212 (substring_loc::get_location): ...this.
6213 (substring_loc::set_caret_index): New method.
6214 (substring_loc): Add field m_caret_idx.
6215 * c-format.c (format_warning_va): Update for above changes.
6216 Rename local "substring_loc" to "fmt_substring_loc" to avoid
6217 clashing with type name.
6218 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
6219 (check_argument_type): Likewise.
6220 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
6221 Use a copy when emitting warnings, setting the caret index from TYPE.
6222
6223 2016-08-16 Eric Botcazou <ebotcazou@adacore.com>
6224 Arnaud Charlet <charlet@adacore.com>
6225
6226 * c-ada-spec.c (dump_number): New function.
6227 (handle_escape_character): Likewise.
6228 (print_ada_macros): Add handling of constant integers and strings.
6229
6230 2016-08-12 Marek Polacek <polacek@redhat.com>
6231
6232 PR c/7652
6233 * c-common.c (scalar_to_vector): Adjust fall through comment.
6234 * c-opts.c (c_common_handle_option): Likewise.
6235 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
6236 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
6237 fall through comment.
6238 * cilk.c (extract_free_variables): Add FALLTHRU.
6239
6240 2016-08-10 Jason Merrill <jason@redhat.com>
6241
6242 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
6243
6244 2016-08-09 Jason Merrill <jason@redhat.com>
6245
6246 * c-common.c (c_common_attribute_table): vector_size affects type
6247 identity.
6248
6249 2016-08-09 Marek Polacek <polacek@redhat.com>
6250
6251 PR c/7652
6252 * c-ada-spec.c (dump_generic_ada_node): Add return.
6253
6254 2016-08-09 Jason Merrill <jason@redhat.com>
6255
6256 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
6257 C++17 constexpr lambdas.
6258
6259 2016-08-08 David Malcolm <dmalcolm@redhat.com>
6260
6261 PR c/64955
6262 * c-common.h (selftest::c_format_c_tests): New declaration.
6263 (selftest::run_c_tests): New declaration.
6264 * c-format.c: Include "selftest.h.
6265 (format_warning_va): Add param "corrected_substring" and use
6266 it to add a replacement fix-it hint.
6267 (format_warning_at_substring): Likewise.
6268 (format_warning_at_char): Update for new param of
6269 format_warning_va.
6270 (argument_parser::check_argument_type): Pass "fki" to
6271 check_format_types.
6272 (check_format_types): Add param "fki" and pass it to
6273 format_type_warning.
6274 (deref_n_times): New function.
6275 (get_modifier_for_format_len): New function.
6276 (selftest::test_get_modifier_for_format_len): New function.
6277 (get_format_for_type): New function.
6278 (format_type_warning): Add param "fki" and use it to attempt
6279 to provide hints for argument types when calling
6280 format_warning_at_substring.
6281 (selftest::get_info): New function.
6282 (selftest::assert_format_for_type_streq): New function.
6283 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
6284 (selftest::test_get_format_for_type_printf): New function.
6285 (selftest::test_get_format_for_type_scanf): New function.
6286 (selftest::c_format_c_tests): New function.
6287
6288 2016-08-08 David Malcolm <dmalcolm@redhat.com>
6289
6290 PR c/52952
6291 * c-format.c: Include "diagnostic.h".
6292 (location_column_from_byte_offset): Delete.
6293 (location_from_offset): Delete.
6294 (format_warning_va): New function.
6295 (format_warning_at_substring): New function.
6296 (format_warning_at_char): New function.
6297 (check_format_arg): Capture location of format_tree and pass to
6298 check_format_info_main.
6299 (argument_parser): Add fields "start_of_this_format" and
6300 "format_string_cst".
6301 (flag_chars_t::validate): Add param "format_string_cst". Convert
6302 warning_at call using location_from_offset to call to
6303 format_warning_at_char.
6304 (argument_parser::argument_parser): Add param "format_string_cst_"
6305 and use use it to initialize field "format_string_cst".
6306 Initialize new field "start_of_this_format".
6307 (argument_parser::read_format_flags): Convert warning_at call
6308 using location_from_offset to a call to format_warning_at_char.
6309 (argument_parser::read_any_format_left_precision): Likewise.
6310 (argument_parser::read_any_format_precision): Likewise.
6311 (argument_parser::read_any_other_modifier): Likewise.
6312 (argument_parser::find_format_char_info): Likewise, in three places.
6313 (argument_parser::parse_any_scan_set): Likewise, in one place.
6314 (argument_parser::handle_conversions): Likewise, in two places.
6315 (argument_parser::check_argument_type): Add param "fmt_param_loc"
6316 and use it to make a substring_loc. Pass the latter to
6317 check_format_types.
6318 (check_format_info_main): Add params "fmt_param_loc" and
6319 "format_string_cst". Convert warning_at calls using
6320 location_from_offset to calls to format_warning_at_char. Pass the
6321 new params to the arg_parser ctor. Pass "format_string_cst" to
6322 flag_chars.validate. Pass "fmt_param_loc" to
6323 arg_parser.check_argument_type.
6324 (check_format_types): Convert first param from a location_t
6325 to a const substring_loc & and rename to "fmt_loc". Attempt
6326 to extract the range of the relevant parameter and pass it
6327 to format_type_warning.
6328 (format_type_warning): Convert first param from a location_t
6329 to a const substring_loc & and rename to "fmt_loc". Add
6330 params "param_range" and "type". Replace calls to warning_at
6331 with calls to format_warning_at_substring.
6332
6333 2016-08-08 David Malcolm <dmalcolm@redhat.com>
6334
6335 * c-format.c (class flag_chars_t): New class.
6336 (struct length_modifier): New struct.
6337 (class argument_parser): New class.
6338 (flag_chars_t::flag_chars_t): New ctor.
6339 (flag_chars_t::has_char_p): New method.
6340 (flag_chars_t::add_char): New method.
6341 (flag_chars_t::validate): New method.
6342 (flag_chars_t::get_alloc_flag): New method.
6343 (flag_chars_t::assignment_suppression_p): New method.
6344 (argument_parser::argument_parser): New ctor.
6345 (argument_parser::read_any_dollar): New method.
6346 (argument_parser::read_format_flags): New method.
6347 (argument_parser::read_any_format_width): New method.
6348 (argument_parser::read_any_format_left_precision): New method.
6349 (argument_parser::read_any_format_precision): New method.
6350 (argument_parser::handle_alloc_chars): New method.
6351 (argument_parser::read_any_length_modifier): New method.
6352 (argument_parser::read_any_other_modifier): New method.
6353 (argument_parser::find_format_char_info): New method.
6354 (argument_parser::validate_flag_pairs): New method.
6355 (argument_parser::give_y2k_warnings): New method.
6356 (argument_parser::parse_any_scan_set): New method.
6357 (argument_parser::handle_conversions): New method.
6358 (argument_parser::check_argument_type): New method.
6359 (check_format_info_main): Introduce classes argument_parser
6360 and flag_chars_t, moving the code within the loop into methods
6361 of these classes. Make various locals "const".
6362
6363 2016-08-05 David Malcolm <dmalcolm@redhat.com>
6364
6365 * c-common.c: Include "substring-locations.h".
6366 (get_cpp_ttype_from_string_type): New function.
6367 (g_string_concat_db): New global.
6368 (substring_loc::get_range): New method.
6369 * c-common.h (g_string_concat_db): New declaration.
6370 (class substring_loc): New class.
6371 * c-lex.c (lex_string): When concatenating strings, capture the
6372 locations of all tokens using a new obstack, and record the
6373 concatenation locations within g_string_concat_db.
6374 * c-opts.c (c_common_init_options): Construct g_string_concat_db
6375 on the ggc-heap.
6376
6377 2016-07-29 Marek Polacek <polacek@redhat.com>
6378
6379 PR c/71926
6380 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
6381 parentheses warning.
6382
6383 PR c/71574
6384 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
6385
6386 2016-07-28 Martin Liska <mliska@suse.cz>
6387
6388 PR gcov-profile/68025
6389 * c-common.c (handle_no_profile_instrument_function_attribute):
6390
6391 2016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
6392
6393 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
6394 BITS_PER_UNIT_LOG.
6395
6396 2016-07-25 Jason Merrill <jason@redhat.com>
6397
6398 PR c++/65970
6399 * c.opt (fconstexpr-loop-limit): New.
6400
6401 2016-07-22 Martin Sebor <msebor@redhat.com>
6402
6403 PR c++/71675
6404 * c-common.c (resolve_overloaded_builtin): Avoid converting
6405 __atomic_compare_exchange_n return type to that of what its
6406 first argument points to.
6407
6408 2016-07-22 Uros Bizjak <ubizjak@gmail.com>
6409
6410 * c-common.c: Use HOST_WIDE_INT_M1U instead of
6411 ~(unsigned HOST_WIDE_INT) 0.
6412
6413 2016-07-22 Martin Liska <mliska@suse.cz>
6414
6415 PR gcov-profile/69028
6416 PR gcov-profile/62047
6417 * cilk.c (create_cilk_helper_decl): Set location of a new decl
6418 to the current_function_decl.
6419
6420 2016-07-21 Jason Merrill <jason@redhat.com>
6421
6422 PR c++/65168
6423 * c-common.c (c_common_truthvalue_conversion): Check
6424 c_inhibit_evaluation_warnings for warning about address of
6425 reference.
6426
6427 2016-07-20 David Malcolm <dmalcolm@redhat.com>
6428
6429 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
6430 const char *.
6431
6432 2016-07-15 Jason Merrill <jason@redhat.com>
6433
6434 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
6435
6436 2016-07-15 Jakub Jelinek <jakub@redhat.com>
6437
6438 PR c/71858
6439 * c-common.h (enum lookup_name_fuzzy_kind): Add
6440 FUZZY_LOOKUP_FUNCTION_NAME.
6441
6442 2016-07-08 Jason Merrill <jason@redhat.com>
6443
6444 P0145: Refining Expression Order for C++.
6445 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
6446 * c-opts.c: Adjust.
6447
6448 2016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
6449
6450 PR c++/71214
6451 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
6452
6453 2016-06-29 Thomas Schwinge <thomas@codesourcery.com>
6454
6455 * c-pragma.h (enum pragma_kind): Rename
6456 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
6457 users.
6458
6459 2016-06-29 Richard Biener <rguenther@suse.de>
6460
6461 PR middle-end/71002
6462 * c-common.c (c_common_get_alias_set): Remove union type punning case.
6463
6464 2016-06-24 Jason Merrill <jason@redhat.com>
6465
6466 P0145R2: Refining Expression Order for C++.
6467 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
6468 MODIFY_EXPR.
6469
6470 2016-06-24 Jakub Jelinek <jakub@redhat.com>
6471
6472 * c-common.c (check_builtin_function_arguments): Require last
6473 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
6474 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
6475 if the last argument is pointer to enumerated or boolean type.
6476
6477 2016-06-22 David Malcolm <dmalcolm@redhat.com>
6478
6479 PR c/70339
6480 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
6481 (lookup_name_fuzzy): New prototype.
6482
6483 2016-06-21 John David Anglin <danglin@gcc.gnu.org>
6484
6485 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
6486
6487 2016-06-14 Jason Merrill <jason@redhat.com>
6488
6489 P0145R2: Refining Expression Order for C++.
6490 * c.opt (fargs-in-order): New.
6491 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
6492
6493 2016-06-13 Jakub Jelinek <jakub@redhat.com>
6494
6495 PR sanitizer/71498
6496 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
6497 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
6498
6499 PR preprocessor/71183
6500 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
6501 to cb_get_source_date_epoch.
6502
6503 2016-06-10 Jakub Jelinek <jakub@redhat.com>
6504
6505 PR c/68657
6506 * c.opt (Wpsabi): Add Warning flag.
6507
6508 2016-06-10 Martin Sebor <msebor@redhat.com>
6509
6510 PR c/71392
6511 * c-common.c (handle_nonnull_attribute): Accept
6512 the nonnull attribute in type-generic builtins.
6513
6514 2016-06-09 Martin Sebor <msebor@redhat.com>
6515
6516 PR c/70883
6517 * c-common.c (builtin_function_validate_nargs): Make text of error
6518 message consistent with others like it.
6519
6520 2016-06-08 Martin Sebor <msebor@redhat.com>
6521 Jakub Jelinek <jakub@redhat.com>
6522
6523 PR c++/70507
6524 PR c/68120
6525 * c-common.c (check_builtin_function_arguments): Handle
6526 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
6527
6528 2016-06-08 Richard Biener <rguenther@suse.de>
6529
6530 * c-common.c (parse_optimize_options): Improve diagnostic messages.
6531
6532 2016-06-07 Richard Biener <rguenther@suse.de>
6533
6534 PR c/61564
6535 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
6536 options and warn about others.
6537
6538 2016-06-01 Eduard Sanou <dhole@openmailbox.org>
6539
6540 * c-common.c (get_source_date_epoch): Rename to
6541 cb_get_source_date_epoch.
6542 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
6543 message when the parsing fails. Use error_at instead of fatal_error.
6544 * c-common.h (get_source_date_epoch): Rename to
6545 cb_get_source_date_epoch.
6546 * c-common.h (cb_get_source_date_epoch): Prototype.
6547 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
6548 * c-common.h (c_omp_region_type): Remove trailing comma.
6549 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
6550 * c-lex.c (c_lex_with_flags): Remove initialization of
6551 pfile->source_date_epoch.
6552
6553 2016-05-30 Jakub Jelinek <jakub@redhat.com>
6554
6555 PR c++/71349
6556 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
6557 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
6558 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
6559 instead of C_OMP_CLAUSE_SPLIT_FOR.
6560
6561 2016-05-24 Richard Biener <rguenther@suse.de>
6562
6563 PR middle-end/70434
6564 PR c/69504
6565 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
6566 (convert_vector_to_array_for_subscript): ... this.
6567 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
6568 VIEW_CONVERT_EXPR to an array type. Rename to ...
6569 (convert_vector_to_array_for_subscript): ... this.
6570
6571 2016-05-12 Marek Polacek <polacek@redhat.com>
6572
6573 PR c/70756
6574 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
6575 size_in_bytes and pass LOC to it.
6576
6577 2016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
6578
6579 PR c/43651
6580 * c.opt (Wduplicate-decl-specifier): New option.
6581
6582 2016-05-11 Marek Polacek <polacek@redhat.com>
6583
6584 PR c++/71024
6585 * c-common.c (diagnose_mismatched_attributes): New function.
6586 * c-common.h (diagnose_mismatched_attributes): Declare.
6587
6588 2016-05-04 Marek Polacek <polacek@redhat.com>
6589
6590 * c.opt (Wdangling-else): New option.
6591
6592 2016-05-03 Marek Polacek <polacek@redhat.com>
6593
6594 PR c/70859
6595 * c-common.c (builtin_function_validate_nargs): Add location
6596 parameter. Use it.
6597 (check_builtin_function_arguments): Add location and arguments
6598 parameters. Use them.
6599 * c-common.h (check_builtin_function_arguments): Update declaration.
6600
6601 2016-05-03 Richard Biener <rguenther@suse.de>
6602
6603 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
6604 allow call args to gimplify to SSA names.
6605
6606 2016-05-03 Marek Polacek <polacek@redhat.com>
6607
6608 * c-common.h (enum c_omp_region_type): Remove stray comma.
6609
6610 2016-05-02 Cesar Philippidis <cesar@codesourcery.com>
6611
6612 * c-common.h (enum c_omp_region_type): Define.
6613
6614 2016-05-02 Richard Sandiford <richard.sandiford@arm.com>
6615
6616 * c-common.c (shorten_compare): Use wi::to_wide.
6617
6618 2016-04-29 Cesar Philippidis <cesar@codesourcery.com>
6619
6620 PR middle-end/70626
6621 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
6622 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
6623 reduction clauses in acc parallel loops.
6624
6625 2016-04-29 Marek Polacek <polacek@redhat.com>
6626
6627 PR c/70852
6628 * c-common.c (warn_for_memset): Check domain before accessing it.
6629
6630 2016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
6631
6632 PR/69089
6633 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
6634 "aligned" attribute.
6635
6636 2016-04-28 Jason Merrill <jason@redhat.com>
6637
6638 * c-lex.c (c_common_has_attribute): Handle nodiscard.
6639
6640 2016-04-28 Eduard Sanou <dhole@openmailbox.org>
6641 Matthias Klose <doko@debian.org>
6642
6643 * c-common.c (get_source_date_epoch): New function, gets the environment
6644 variable SOURCE_DATE_EPOCH and parses it as long long with error
6645 handling.
6646 * c-common.h (get_source_date_epoch): Prototype.
6647 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
6648
6649 2015-04-27 Ryan Burn <contact@rnburn.com>
6650
6651 PR c++/69024
6652 PR c++/68997
6653 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
6654 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
6655 external linkage.
6656 (cilk_detect_and_unwrap): Corresponding changes.
6657 (extract_free_variables): Don't extract free variables from
6658 AGGR_INIT_EXPR slot.
6659 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
6660 (cilk_recognize_spawn): Likewise.
6661
6662 2016-04-27 Bernd Schmidt <bschmidt@redhat.com>
6663
6664 * c.opt (Wmemset-elt-size): New option.
6665 * c-common.c (warn_for_memset): New function.
6666 * c-common.h (warn_for_memset): Declare.
6667
6668 2016-04-25 Jason Merrill <jason@redhat.com>
6669
6670 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
6671 No longer static.
6672 * c-common.h: Declare it.
6673 * c-lex.c (c_common_has_attribute): Add maybe_unused.
6674
6675 2016-04-22 Jason Merrill <jason@redhat.com>
6676
6677 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
6678
6679 2016-04-20 Ilya Verbin <ilya.verbin@intel.com>
6680
6681 PR c++/69363
6682 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
6683 * c-common.h (c_finish_cilk_clauses): Remove declaration.
6684
6685 2016-04-18 Michael Matz <matz@suse.de>
6686
6687 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
6688 and SET_DECL_ALIGN.
6689
6690 2016-04-17 Eric Botcazou <ebotcazou@adacore.com>
6691
6692 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
6693 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
6694 to incomplete types.
6695 (dump_nested_type): Remove redundant tests and tidy up.
6696 (print_ada_declaration): Also set TREE_VISITED on the declaration of
6697 a type which is the typedef of an original type.
6698
6699 2016-04-15 Marek Polacek <polacek@redhat.com>
6700
6701 PR c/70651
6702 * c-common.c (build_va_arg): Change two asserts into errors and return
6703 error_mark_node.
6704
6705 2016-04-13 Marek Polacek <polacek@redhat.com>
6706
6707 PR c++/70639
6708 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
6709 for switch statements, too.
6710
6711 2016-03-28 Jason Merrill <jason@redhat.com>
6712
6713 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
6714
6715 2016-03-23 Marek Polacek <polacek@redhat.com>
6716
6717 PR c++/69884
6718 * c.opt (Wignored-attributes): New option.
6719
6720 2016-03-22 David Malcolm <dmalcolm@redhat.com>
6721
6722 PR c/69993
6723 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
6724 diagnostic text, reversing the order of the warning and note so
6725 that they appear in source order.
6726
6727 2016-03-17 Marek Polacek <polacek@redhat.com>
6728
6729 PR c/69407
6730 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
6731 operations.
6732
6733 2016-03-14 Jason Merrill <jason@redhat.com>
6734
6735 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
6736
6737 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
6738
6739 2016-03-09 Richard Biener <rguenther@suse.de>
6740
6741 PR c/70143
6742 * c-common.c (strict_aliasing_warning): Add back
6743 alias_sets_conflict_p check.
6744
6745 2016-03-08 Jason Merrill <jason@redhat.com>
6746
6747 * c-opts.c (set_std_cxx1z): Don't enable concepts.
6748
6749 2016-03-04 David Malcolm <dmalcolm@redhat.com>
6750
6751 PR c/68187
6752 * c-indentation.c (get_visual_column): Move code to determine next
6753 tab stop to...
6754 (next_tab_stop): ...this new function.
6755 (line_contains_hash_if): Delete function.
6756 (detect_preprocessor_logic): Delete function.
6757 (get_first_nws_vis_column): New function.
6758 (detect_intervening_unindent): New function.
6759 (should_warn_for_misleading_indentation): Replace call to
6760 detect_preprocessor_logic with a call to
6761 detect_intervening_unindent.
6762
6763 2016-03-04 David Malcolm <dmalcolm@redhat.com>
6764
6765 PR c/68187
6766 * c-indentation.c (should_warn_for_misleading_indentation): When
6767 suppressing warnings about cases where the guard and body are on
6768 the same column, only use the first non-whitespace column in place
6769 of the guard token column when dealing with "else" clauses.
6770 When rejecting aligned BODY and NEXT, loosen the requirement
6771 from equality with the first non-whitespace of guard to simply
6772 that they not be indented relative to it.
6773
6774 2016-03-04 Richard Biener <rguenther@suse.de>
6775
6776 PR c++/70054
6777 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
6778 instead of alias_sets_conflict_p.
6779
6780 2016-03-01 Marek Polacek <polacek@redhat.com>
6781
6782 PR c++/69795
6783 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
6784 any DECL.
6785
6786 2016-02-22 Martin Sebor <msebor@redhat.com>
6787
6788 PR middle-end/69780
6789 * c-common.c (check_builtin_function_arguments): Validate and
6790 reject invalid arguments to __builtin_alloca_with_align.
6791
6792 2016-02-20 Mark Wielaard <mjw@redhat.com>
6793
6794 PR c/28901
6795 * c.opt (Wunused-const-variable): Turn into Alias for...
6796 (Wunused-const-variable=): New option.
6797
6798 2016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
6799
6800 PR c++/69865
6801 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
6802 here...
6803 (c_common_init_options): ...to here.
6804 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
6805
6806 2016-02-19 Jakub Jelinek <jakub@redhat.com>
6807
6808 PR c++/69826
6809 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
6810 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
6811 flag_preprocess_only.
6812
6813 2016-02-16 Jakub Jelinek <jakub@redhat.com>
6814
6815 PR c/69835
6816 * c.opt (Wnonnull-compare): Enable for -Wall.
6817
6818 2016-02-15 Jakub Jelinek <jakub@redhat.com>
6819
6820 PR c++/69797
6821 * c-common.c (sync_resolve_size): Diagnose too few arguments
6822 even when params is non-NULL empty vector.
6823
6824 2016-02-08 Bernd Schmidt <bschmidt@redhat.com>
6825
6826 PR target/60410
6827 * c.opt (fshort-double): Remove.
6828
6829 2016-02-05 Martin Sebor <msebor@redhat.com>
6830
6831 PR c++/69662
6832 * c.opt (Warning options): Update -Wplacement-new to take
6833 an optional argument.
6834
6835 2016-02-01 Jakub Jelinek <jakub@redhat.com>
6836
6837 PR preprocessor/69543
6838 PR c/69558
6839 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
6840 instead of loc to control_warning_option.
6841
6842 2016-02-01 Nathan Sidwell <nathan@codesourcery.com>
6843
6844 * c.opt (fopenacc-dim=): New option.
6845
6846 2016-01-27 Ryan Burn <contact@rnburn.com>
6847
6848 PR cilkplus/69267
6849 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
6850 gimplify_arg. Removed superfluous post_p argument.
6851 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
6852 superfluous post_p argument.
6853 * c-gimplify.c (c_gimplify_expr): Likewise.
6854
6855 2016-01-26 David Malcolm <dmalcolm@redhat.com>
6856
6857 PR other/69006
6858 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
6859 pp_newline_and_flush with pp_flush.
6860
6861 2016-01-20 Martin Sebor <msebor@redhat.com>
6862
6863 PR c/69405
6864 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
6865 an incompatible argument when the argument isn't a valid tree node.
6866
6867 2016-01-18 Jason Merrill <jason@redhat.com>
6868
6869 PR c++/68767
6870 * c-common.c (check_function_arguments_recurse): Fold the whole
6871 COND_EXPR, not just the condition.
6872
6873 2016-01-18 Tom de Vries <tom@codesourcery.com>
6874
6875 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
6876 classify as loop clause.
6877
6878 2016-01-15 Jakub Jelinek <jakub@redhat.com>
6879
6880 PR bootstrap/68271
6881 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
6882 C++ FE no longer has limit on number of pragmas.
6883
6884 2015-01-14 Ryan Burn <contact@rnburn.com>
6885
6886 PR c++/69048
6887 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
6888 to add missing cleanup point.
6889
6890 2016-01-14 David Malcolm <dmalcolm@redhat.com>
6891
6892 PR c++/68819
6893 * c-indentation.c (get_visual_column): Add location_t param.
6894 Handle the column number being zero by effectively disabling the
6895 warning, with an "inform".
6896 (should_warn_for_misleading_indentation): Add location_t argument
6897 for all uses of get_visual_column.
6898
6899 2016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
6900
6901 PR c++/69029
6902 * c-indentation.c (should_warn_for_misleading_indentation):
6903 Don't warn about do-while statements.
6904
6905 2016-01-07 Martin Sebor <msebor@redhat.com>
6906
6907 PR c/68966
6908 * c-common.c (sync_resolve_size): Reject first argument when it's
6909 a pointer to _Bool.
6910
6911 2016-01-05 David Malcolm <dmalcolm@redhat.com>
6912
6913 PR c/69122
6914 * c-indentation.c (get_visual_column): Remove default argument.
6915 (should_warn_for_misleading_indentation): For the multiline case,
6916 update call to get_visual_column for next_stmt_exploc so that it
6917 captures the location of the first non-whitespace character in the
6918 relevant line. Don't issue warnings if there is non-whitespace
6919 before the next statement.
6920
6921 2016-01-04 Jakub Jelinek <jakub@redhat.com>
6922
6923 Update copyright years.
6924
6925 2015-12-21 David Malcolm <dmalcolm@redhat.com>
6926
6927 * c-common.c (binary_op_error): Convert first param from
6928 location_t to rich_location * and use it when emitting an error.
6929 * c-common.h (binary_op_error): Convert first param from
6930 location_t to rich_location *.
6931
6932 2015-12-16 David Malcolm <dmalcolm@redhat.com>
6933
6934 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
6935 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
6936
6937 2015-12-15 Ilya Verbin <ilya.verbin@intel.com>
6938
6939 * c-common.c (c_common_attribute_table): Handle "omp declare target
6940 link" attribute.
6941
6942 2015-12-14 Jakub Jelinek <jakub@redhat.com>
6943
6944 PR c/68833
6945 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
6946
6947 2014-12-12 Tobias Burnus <burnus@net-b.de>
6948
6949 PR fortran/68815
6950 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
6951 specifiers (%d, %i,%u and %c).
6952
6953 2015-12-10 David Malcolm <dmalcolm@redhat.com>
6954
6955 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
6956
6957 2015-12-08 Jakub Jelinek <jakub@redhat.com>
6958
6959 PR c/48088
6960 PR c/68657
6961 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
6962 * c-pragma.c (handle_pragma_diagnostic): Adjust
6963 control_warning_option caller.
6964
6965 2015-12-07 David Malcolm <dmalcolm@redhat.com>
6966
6967 * c-common.c (c_cpp_error): Update for change to
6968 rich_location::set_range.
6969
6970 2015-12-04 Paolo Bonzini <bonzini@gnu.org>
6971
6972 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
6973 shifting 1 out of the sign bit.
6974
6975 2015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
6976
6977 * c-common.c (c_common_attribute_table[]): Update max arguments
6978 count for "simd" attribute.
6979 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
6980
6981 2015-12-03 Jakub Jelinek <jakub@redhat.com>
6982
6983 PR preprocessor/57580
6984 * c-ppoutput.c (print): Change printed field to bool.
6985 Move src_file last for smaller padding.
6986 (init_pp_output): Set print.printed to false instead of 0.
6987 (scan_translation_unit): Fix up formatting. Set print.printed
6988 to true after printing something other than newline.
6989 (scan_translation_unit_trad): Set print.printed to true instead of 1.
6990 (maybe_print_line_1): Set print.printed to false instead of 0.
6991 (print_line_1): Likewise.
6992 (do_line_change): Set print.printed to true instead of 1.
6993 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
6994 dump_macro): Set print.printed to false after printing newline.
6995
6996 2015-12-02 Jason Merrill <jason@redhat.com>
6997
6998 * c-common.c (fold_for_warn): New.
6999 (warn_logical_operator, warn_tautological_cmp)
7000 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
7001
7002 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
7003 (c_fully_fold_internal, decl_constant_value_for_optimization):
7004 Move to c/c-fold.c.
7005 * c-common.h: Don't declare decl_constant_value_for_optimization.
7006
7007 2015-12-02 Joseph Myers <joseph@codesourcery.com>
7008
7009 PR c/68162
7010 * c-common.h (c_build_qualified_type): Add extra default
7011 arguments.
7012
7013 2015-12-01 Julian Brown <julian@codesourcery.com>
7014 Cesar Philippidis <cesar@codesourcery.com>
7015 James Norris <James_Norris@mentor.com>
7016
7017 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
7018 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
7019 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
7020
7021 2015-11-30 Eric Botcazou <ebotcazou@adacore.com>
7022
7023 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
7024 (decl_sloc_common): Delete and move bulk of processing to...
7025 (decl_sloc): ...here.
7026 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
7027 (dump_ada_double_name): Remove S parameter and compute the suffix.
7028 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
7029 element type and deal with an anonymous one.
7030 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
7031 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
7032 and remove reference to QUAL_UNION_TYPE.
7033 (dump_nested_types): Make 2 passes on the fields and move bulk to...
7034 (dump_nested_type): ...here. New function extracted from above.
7035 Generate a full declaration for anonymous element type of arrays.
7036 (print_ada_declaration): Really skip anonymous declarations. Remove
7037 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
7038 Clean up processing of declarations of array types and objects.
7039 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
7040 Remove obsolete code and tidy up.
7041
7042 2015-11-29 Jan Hubicka <hubicka@ucw.cz>
7043
7044 PR c/67581
7045 * c-common.c (handle_transparent_union_attribute): Update
7046 also type variants.
7047
7048 2015-11-27 Martin Liska <mliska@suse.cz>
7049
7050 PR c++/68312
7051 * array-notation-common.c (cilkplus_extract_an_triplets):
7052 Release vector of vectors.
7053 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
7054
7055 2015-11-26 Eric Botcazou <ebotcazou@adacore.com>
7056
7057 PR c++/68527
7058 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
7059 (print_ada_struct_decl): Likewise.
7060
7061 2015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
7062
7063 PR c++/68001
7064 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
7065 * cilk.c (recognize_spawn): Determine location in a more precise
7066 way.
7067
7068 2015-11-19 Jason Merrill <jason@redhat.com>
7069
7070 * c-common.c (shorten_compare): But look through macros from
7071 system headers.
7072
7073 2015-11-18 Jason Merrill <jason@redhat.com>
7074
7075 * c-common.c (shorten_compare): Don't -Wtype-limits if the
7076 non-constant operand comes from a macro.
7077
7078 2015-11-17 Jason Merrill <jason@redhat.com>
7079
7080 PR bootstrap/68346
7081 * c-common.c (warn_tautological_cmp): Fold before checking for
7082 constants.
7083
7084 2015-11-16 Marek Polacek <polacek@redhat.com>
7085
7086 PR c++/68362
7087 * c-common.c (check_case_bounds): Fold low and high cases.
7088
7089 2015-11-16 Marek Polacek <polacek@redhat.com>
7090
7091 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
7092 * c-common.c (c_common_get_alias_set): Likewise.
7093 (handle_visibility_attribute): Likewise.
7094
7095 2015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
7096
7097 * c-common.c (handle_simd_attribute): New.
7098 (struct attribute_spec): Add entry for "simd".
7099 (handle_simd_attribute): New.
7100
7101 2015-11-13 Kai Tietz <ktietz70@googlemail.com>
7102
7103 * c-lex.c (interpret_float): Use fold_convert.
7104
7105 2015-11-13 David Malcolm <dmalcolm@redhat.com>
7106
7107 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
7108 and store it on the result.
7109 * c-opts.c (c_common_init_options): Set
7110 global_dc->colorize_source_p.
7111
7112 2015-11-12 James Norris <jnorris@codesourcery.com>
7113 Joseph Myers <joseph@codesourcery.com>
7114
7115 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
7116 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
7117 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
7118 PRAGMA_OACC_CLAUSE_LINK.
7119
7120 2015-11-11 Marek Polacek <polacek@redhat.com>
7121
7122 PR c/68107
7123 PR c++/68266
7124 * c-common.c (valid_array_size_p): New function.
7125 * c-common.h (valid_array_size_p): Declare.
7126
7127 2015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
7128
7129 PR bootstrap/68271
7130 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
7131
7132 2015-11-11 Andrew MacLeod <amacleod@redhat.com>
7133
7134 * array-notation-common.c: Remove unused header files.
7135 * c-ada-spec.c: Likewise.
7136 * c-cilkplus.c: Likewise.
7137 * c-common.c: Likewise.
7138 * c-cppbuiltin.c: Likewise.
7139 * c-dump.c: Likewise.
7140 * c-format.c: Likewise.
7141 * c-gimplify.c: Likewise.
7142 * c-indentation.c: Likewise.
7143 * c-lex.c: Likewise.
7144 * c-omp.c: Likewise.
7145 * c-opts.c: Likewise.
7146 * c-pch.c: Likewise.
7147 * c-ppoutput.c: Likewise.
7148 * c-pragma.c: Likewise.
7149 * c-pretty-print.c: Likewise.
7150 * c-semantics.c: Likewise.
7151 * c-ubsan.c: Likewise.
7152 * cilk.c: Likewise.
7153 * stub-objc.c: Likewise.
7154
7155 2015-11-09 Thomas Schwinge <thomas@codesourcery.com>
7156 Cesar Philippidis <cesar@codesourcery.com>
7157 James Norris <jnorris@codesourcery.com>
7158 Julian Brown <julian@codesourcery.com>
7159 Nathan Sidwell <nathan@codesourcery.com>
7160
7161 * c-pragma.c (oacc_pragmas): Add "routine".
7162 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
7163
7164 2015-11-08 Eric Botcazou <ebotcazou@adacore.com>
7165
7166 * c-common.c (c_common_attributes): Add scalar_storage_order.
7167 (handle_scalar_storage_order_attribute): New function.
7168 * c-pragma.c (global_sso): New variable.
7169 (maybe_apply_pragma_scalar_storage_order): New function.
7170 (handle_pragma_scalar_storage_order): Likewise.
7171 (init_pragma): Register scalar_storage_order.
7172 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
7173 * c.opt (Wscalar-storage-order): New warning.
7174 (fsso-struct=): New option.
7175
7176 2015-11-08 Martin Sebor <msebor@redhat.com>
7177
7178 * c.opt (Wplacement-new): Add a period to the end of a sentence.
7179
7180 2015-11-07 Richard Sandiford <richard.sandiford@arm.com>
7181
7182 * c-common.c: Don't undef DEF_BUILTIN.
7183
7184 2015-11-06 David Malcolm <dmalcolm@redhat.com>
7185
7186 * c-common.c (c_cpp_error): Convert parameter from location_t to
7187 rich_location *. Eliminate the "column_override" parameter and
7188 the call to diagnostic_override_column.
7189 Update the "done_lexing" clause to set range 0
7190 on the rich_location, rather than overwriting a location_t.
7191 * c-common.h (c_cpp_error): Convert parameter from location_t to
7192 rich_location *. Eliminate the "column_override" parameter.
7193
7194 2015-11-05 Cesar Philippidis <cesar@codesourcery.com>
7195 Thomas Schwinge <thomas@codesourcery.com>
7196 James Norris <jnorris@codesourcery.com>
7197
7198 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
7199 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
7200 clauses with parallel and kernels and loops.
7201 * c-pragma.h (enum pragma_omp_clause): Add entries for
7202 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
7203 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
7204 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
7205 INDEPENDENT,SEQ}.
7206 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
7207
7208 2015-11-05 Martin Sebor <msebor@redhat.com>
7209
7210 PR c++/67942
7211 * c.opt (-Wplacement-new): New option.
7212
7213 2015-11-05 Jakub Jelinek <jakub@redhat.com>
7214
7215 * c-common.h (c_finish_omp_atomic): Add TEST argument.
7216 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
7217 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
7218 save_expr or create_tmp_var* if TEST is true.
7219 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
7220 Don't call add_stmt here.
7221 (struct c_omp_check_loop_iv_data): New type.
7222 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
7223 c_omp_check_loop_iv_exprs): New functions.
7224 (c_omp_split_clauses): Adjust for lastprivate being allowed on
7225 distribute.
7226 (c_omp_declare_simd_clauses_to_numbers): Change
7227 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
7228 (c_omp_declare_simd_clauses_to_decls): Similarly change those
7229 from numbers to PARM_DECLs.
7230
7231 2015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
7232
7233 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
7234 flag_checking.
7235
7236 2015-11-03 Bernd Schmidt <bschmidt@redhat.com>
7237
7238 PR c++-common/67882
7239 * c-common.h (fold_offsetof_1): Add argument.
7240 * c-common.c (fold_offsetof_1): Diagnose more invalid
7241 offsetof expressions that reference elements past the end of
7242 an array.
7243
7244 2015-11-03 Thomas Schwinge <thomas@codesourcery.com>
7245 Chung-Lin Tang <cltang@codesourcery.com>
7246
7247 * c-pragma.c (oacc_pragmas): Add "atomic".
7248 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
7249
7250 2015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
7251
7252 * c-common.c (handle_target_clones_attribute): New.
7253 (c_common_attribute_table): Add handle_target_clones_attribute.
7254 (handle_always_inline_attribute): Add check on target_clones attribute.
7255 (handle_target_attribute): Ditto.
7256
7257 2015-10-29 Andrew MacLeod <amacleod@redhat.com>
7258
7259 * array-notation-common.c: Reorder #include's and remove duplicates.
7260 * c-ada-spec.c: Likewise.
7261 * c-cilkplus.c: Likewise.
7262 * c-common.c: Likewise.
7263 * c-cppbuiltin.c: Likewise.
7264 * c-dump.c: Likewise.
7265 * c-format.c: Likewise.
7266 * c-gimplify.c: Likewise.
7267 * c-indentation.c: Likewise.
7268 * c-lex.c: Likewise.
7269 * c-omp.c: Likewise.
7270 * c-opts.c: Likewise.
7271 * c-pch.c: Likewise.
7272 * c-ppoutput.c: Likewise.
7273 * c-pragma.c: Likewise.
7274 * c-pretty-print.c: Likewise.
7275 * c-semantics.c: Likewise.
7276 * c-ubsan.c: Likewise.
7277 * cilk.c: Likewise.
7278 * stub-objc.c: Likewise.
7279
7280 2015-10-28 Jason Merrill <jason@redhat.com>
7281
7282 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
7283
7284 2015-10-27 Thomas Schwinge <thomas@codesourcery.com>
7285 James Norris <jnorris@codesourcery.com>
7286 Cesar Philippidis <cesar@codesourcery.com>
7287
7288 PR c/64765
7289 PR c/64880
7290 * c-common.h (c_oacc_split_loop_clauses): Declare function.
7291 * c-omp.c (c_oacc_split_loop_clauses): New function.
7292
7293 2015-10-21 Martin Sebor <msebor@redhat.com>
7294
7295 PR driver/68043
7296 * c.opt: End each sentence that describes an option with a period.
7297
7298 2015-10-20 Marek Polacek <polacek@redhat.com>
7299
7300 * array-notation-common.c (is_cilkplus_vector_p): Define.
7301 * c-common.h (is_cilkplus_vector_p): Declare.
7302
7303 2015-10-20 Marek Polacek <polacek@redhat.com>
7304
7305 * c.opt (std=gnu++11): Do not describe as experimental.
7306 (std=gnu++14): Likewise.
7307
7308 2015-10-19 Jason Merrill <jason@redhat.com>
7309
7310 * c-cppbuiltin.c (c_cpp_builtins): Define
7311 __cpp_nontype_template_args.
7312
7313 2015-10-19 Jason Merrill <jason@redhat.com>
7314
7315 * c-cppbuiltin.c (c_cpp_builtins): Define
7316 __cpp_enumerator_attributes, __cpp_fold_expressions,
7317 __cpp_unicode_characters.
7318
7319 2015-10-13 Jakub Jelinek <jakub@redhat.com>
7320 Aldy Hernandez <aldyh@redhat.com>
7321
7322 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
7323 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
7324 (c_define_builtins): Likewise.
7325 * c-common.h (enum c_omp_clause_split): Add
7326 C_OMP_CLAUSE_SPLIT_TASKLOOP.
7327 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
7328 (c_finish_omp_for): Add ORIG_DECLV argument.
7329 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
7330 201511 instead of 201307.
7331 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
7332 OMP_CRITICAL_CLAUSES to it.
7333 (c_finish_omp_ordered): Add CLAUSES argument, set
7334 OMP_ORDERED_CLAUSES to it.
7335 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
7336 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
7337 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
7338 constructs and new OpenMP 4.5 clauses. Clear
7339 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
7340 verification code.
7341 * c-pragma.c (omp_pragmas_simd): Add taskloop.
7342 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
7343 (enum pragma_omp_clause): Add
7344 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
7345 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
7346
7347 2015-10-05 Richard Sandiford <richard.sandiford@arm.com>
7348
7349 * c-lex.c (interpret_float): Use real_equal instead of
7350 REAL_VALUES_EQUAL.
7351
7352 2015-10-04 Jason Merrill <jason@redhat.com>
7353
7354 Implement N4514, C++ Extensions for Transactional Memory.
7355 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
7356 (c_common_attribute_table): Add transaction_safe_dynamic.
7357 transaction_safe now affects type identity.
7358 (handle_tm_attribute): Handle transaction_safe_dynamic.
7359 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
7360 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
7361 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
7362 (D_TRANSMEM): New.
7363 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
7364 * c-pretty-print.c (pp_c_attributes_display): Don't print
7365 transaction_safe in C++.
7366
7367 2015-10-02 Marek Polacek <polacek@redhat.com>
7368
7369 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
7370
7371 2015-10-02 Marek Polacek <polacek@redhat.com>
7372
7373 PR c/64249
7374 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
7375 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
7376 * c.opt (Wduplicated-cond): New option.
7377
7378 2015-10-01 Joseph Myers <joseph@codesourcery.com>
7379
7380 * c.opt (std=c11): Do not describe as experimental.
7381 (std=gnu11): Likewise.
7382 (std=iso9899:2011): Likewise.
7383
7384 2015-09-28 Nathan Sidwell <nathan@codesourcery.com>
7385
7386 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
7387 (DEF_FUNCTION_TYPE_VAR_11): Delete.
7388
7389 2015-09-25 Marek Polacek <polacek@redhat.com>
7390
7391 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
7392 (ubsan_instrument_shift): Likewise.
7393
7394 2015-09-25 Marek Polacek <polacek@redhat.com>
7395
7396 PR sanitizer/64906
7397 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
7398
7399 2015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
7400
7401 * c-indentation.c (should_warn_for_misleading_indentation):
7402 Compare next_stmt_vis_column with guard_line_first_nws instead
7403 of with guard_line_vis_column.
7404
7405 2015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
7406
7407 PR c/49654
7408 PR c/49655
7409 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
7410 options and options not valid for the current language.
7411
7412 2015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
7413
7414 * c-indentation.c (should_warn_for_misleading_indentation):
7415 Float out and consolidate the calls to get_visual_column that
7416 are passed guard_exploc as an argument. Compare
7417 next_stmt_vis_column with guard_line_first_nws instead of with
7418 body_line_first_nws.
7419
7420 2015-09-22 Nathan Sidwell <nathan@codesourcery.com>
7421
7422 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
7423 Wnamespaces): New C++ warnings.
7424
7425 2015-09-22 Jason Merrill <jason@redhat.com>
7426
7427 * c-common.h (abi_compat_version_crosses): New.
7428 (warn_abi_version): Declare.
7429 * c-common.c: Define it.
7430 * c-opts.c (c_common_post_options): Handle it.
7431 flag_abi_compat_version defaults to 8.
7432
7433 2015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
7434
7435 Complete the implementation of N4230, Nested namespace definition.
7436 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
7437 __cpp_nested_namespace_definitions.
7438
7439 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
7440
7441 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
7442
7443 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
7444
7445 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
7446 when warning.
7447 * c-pragma.h (pragma_lex): Add optional loc argument.
7448
7449 2015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
7450
7451 * c-format.c (check_format_arg): Adjust to use common block size in all
7452 object pools.
7453
7454 2015-09-15 David Malcolm <dmalcolm@redhat.com>
7455
7456 * c-format.c (location_from_offset): Update for change in
7457 signature of location_get_source_line.
7458 * c-indentation.c (get_visual_column): Likewise.
7459 (line_contains_hash_if): Likewise.
7460
7461 2015-09-14 Marek Polacek <polacek@redhat.com>
7462
7463 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
7464 setting various warnings.
7465
7466 2015-09-14 Marek Polacek <polacek@redhat.com>
7467
7468 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
7469 a negative value.
7470
7471 2015-09-11 Mark Wielaard <mjw@redhat.com>
7472
7473 PR c/28901
7474 * c.opt (Wunused-variable): Option from common.opt.
7475 (Wunused-const-variable): New option.
7476
7477 2015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
7478
7479 PR c++/53184
7480 * c.opt ([Wsubobject-linkage]): Add.
7481
7482 2015-09-03 Martin Sebor <msebor@redhat.com>
7483
7484 PR c/66516
7485 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
7486 functions.
7487 * c-common.c (reject_gcc_builtin): Define.
7488
7489 2015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
7490
7491 PR middle-end/60586
7492 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
7493 prototype.
7494 * c-gimplify.c (c_gimplify_expr): Added a call to the function
7495 cilk_gimplify_call_params_in_spawned_fn.
7496 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
7497 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
7498 unwrapping.
7499
7500 2015-08-25 Marek Polacek <polacek@redhat.com>
7501
7502 PR middle-end/67330
7503 * c-common.c (handle_weak_attribute): Don't check whether the
7504 visibility can be changed here.
7505
7506 2015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
7507
7508 * c-lex.c (c_lex_with_flags): Use explicit locations.
7509
7510 2015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
7511
7512 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
7513 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
7514
7515 2015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
7516
7517 PR middle-end/36757
7518 * c-common.c (check_builtin_function_arguments): Add check
7519 for BUILT_IN_SIGNBIT argument.
7520
7521 2015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
7522
7523 PR c++/67160
7524 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
7525 in c++1z mode.
7526
7527 2015-08-17 Marek Polacek <polacek@redhat.com>
7528
7529 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
7530 with whitespaces before qualifier names.
7531
7532 2015-08-12 Marek Polacek <polacek@redhat.com>
7533
7534 PR c++/55095
7535 * c-common.c (maybe_warn_shift_overflow): Properly handle
7536 left-shifting 1 into the sign bit.
7537
7538 2015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
7539
7540 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
7541
7542 2015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
7543 Braden Obrzut <admin@maniacsvault.net>
7544 Jason Merrill <jason@redhat.com>
7545
7546 Add C++ Concepts TS support.
7547 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
7548 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
7549 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
7550 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
7551 * c-opts.c (set_std_cxx1z): Set flag_concepts.
7552 * c.opt (fconcepts): New.
7553
7554 2015-08-02 Martin Sebor <msebor@redhat.com>
7555
7556 * c.opt (-Wframe-address): New warning option.
7557
7558 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
7559
7560 * c-indentation.c (should_warn_for_misleading_indentation):
7561 Improve heuristics.
7562
7563 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
7564
7565 * c-indentation.c (get_visual_column): Add parameter first_nws,
7566 use it. Update comment documenting the function.
7567 (is_first_nonwhitespace_on_line): Remove.
7568 (should_warn_for_misleading_indentation): Replace usage of
7569 of is_first_nonwhitespace_on_line with get_visual_column.
7570
7571 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
7572
7573 * c-indentation.h (struct token_indent_info): Define.
7574 (get_token_indent_info): Define.
7575 (warn_for_misleading_information): Declare.
7576 * c-common.h (warn_for_misleading_information): Remove.
7577 * c-identation.c (warn_for_misleading_indentation):
7578 Change declaration to take three token_indent_infos. Adjust
7579 accordingly.
7580 * c-identation.c (should_warn_for_misleading_indentation):
7581 Likewise. Bail out early if the body is a compound statement.
7582 (guard_tinfo_to_string): Define.
7583
7584 2015-07-30 Jason Merrill <jason@redhat.com>
7585
7586 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
7587 '*' for reference decay.
7588
7589 2015-07-30 Marek Polacek <polacek@redhat.com>
7590
7591 * c-common.c (warn_tautological_cmp): Bail for float types.
7592
7593 2015-07-27 Marek Polacek <polacek@redhat.com>
7594
7595 PR bootstrap/67030
7596 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
7597
7598 2015-07-27 Marek Polacek <polacek@redhat.com>
7599
7600 PR c++/66555
7601 PR c/54979
7602 * c-common.c (find_array_ref_with_const_idx_r): New function.
7603 (warn_tautological_cmp): New function.
7604 * c-common.h (warn_tautological_cmp): Declare.
7605 * c.opt (Wtautological-compare): New option.
7606
7607 2015-07-23 Marek Polacek <polacek@redhat.com>
7608
7609 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
7610 (ubsan_instrument_shift): Likewise.
7611
7612 2015-07-23 Marek Polacek <polacek@redhat.com>
7613
7614 PR sanitizer/66908
7615 * c-ubsan.c: Include gimplify.h.
7616 (ubsan_instrument_division): Unshare OP0 and OP1.
7617 (ubsan_instrument_shift): Likewise.
7618
7619 2015-07-20 Marek Polacek <polacek@redhat.com>
7620 Richard Sandiford <richard.sandiford@arm.com>
7621
7622 PR c++/55095
7623 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
7624 Use EXPR_LOC_OR_LOC.
7625 (maybe_warn_shift_overflow): New function.
7626 * c-common.h (maybe_warn_shift_overflow): Declare.
7627 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
7628 * c.opt (Wshift-overflow): New option.
7629
7630 2015-07-16 Martin Liska <mliska@suse.cz>
7631
7632 * c-format.c (static void check_format_info_main): Use
7633 object_allocator instead of pool_allocator.
7634 (check_format_arg): Likewise.
7635 (check_format_info_main): Likewise.
7636
7637 2015-07-15 Andrew MacLeod <amacleod@redhat.com>
7638
7639 * c-opts.c: Remove multiline #include comment.
7640
7641 2015-07-12 Aldy Hernandez <aldyh@redhat.com>
7642
7643 * c-common.c: Fix double word typos.
7644
7645 2015-07-10 Eric Botcazou <ebotcazou@adacore.com>
7646
7647 * c-ada-spec.h (cpp_operation): Revert latest change.
7648 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
7649 constructors and destructors.
7650
7651 2015-07-09 Andrew MacLeod <amacleod@redhat.com>
7652
7653 * c-common.h: Adjust includes for flags.h changes.
7654 * stub-objc.c: Likewise.
7655
7656 2015-07-08 Eric Botcazou <ebotcazou@adacore.com>
7657
7658 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
7659 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
7660
7661 2015-07-08 Jakub Jelinek <jakub@redhat.com>
7662
7663 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
7664 are to be removed, return NULL rather than original clauses list.
7665
7666 2015-07-07 Andrew MacLeod <amacleod@redhat.com>
7667
7668 * array-notation-common.c: Adjust includes.
7669 * c-ada-spec.c: Likewise.
7670 * c-cilkplus.c: Likewise.
7671 * c-common.h: Likewise.
7672 * c-cppbuiltin.c: Likewise.
7673 * c-dump.c: Likewise.
7674 * c-format.c: Likewise.
7675 * c-gimplify.c: Likewise.
7676 * c-indentation.c: Likewise.
7677 * c-lex.c: Likewise.
7678 * c-omp.c: Likewise.
7679 * c-opts.c: Likewise.
7680 * c-pch.c: Likewise.
7681 * c-ppoutput.c: Likewise.
7682 * c-pragma.c: Likewise.
7683 * c-pretty-print.c: Likewise.
7684 * c-semantics.c: Likewise.
7685 * c-ubsan.c: Likewise.
7686 * cilk.c: Likewise.
7687 * stub-objc.c: Likewise.
7688
7689 2015-07-07 Eric Botcazou <ebotcazou@adacore.com>
7690
7691 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
7692 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
7693
7694 2015-07-01 Jason Merrill <jason@redhat.com>
7695
7696 * c-common.h (D_CXX11): Rename from D_CXX0X.
7697 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
7698 * c-common.c: Adjust.
7699
7700 * c-opts.c (c_common_post_options): Default to C++14.
7701
7702 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
7703
7704 2015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
7705
7706 Implement N4197 - Adding u8 character literals
7707 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
7708 CPP_CHAR.
7709 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
7710 CPP_UTF8CHAR_USERDEF tokens.
7711 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
7712 and CPP_UTF8CHAR tokens.
7713 (lex_charconst): Treat CPP_UTF8CHAR token.
7714
7715 2015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
7716
7717 PR fortran/66605
7718 * c-common.c (do_warn_unused_parameter): Move here.
7719 * c-common.h (do_warn_unused_parameter): Declare.
7720
7721 2015-06-29 Marek Polacek <polacek@redhat.com>
7722
7723 PR c/66322
7724 * c-common.c (check_case_bounds): Add bool * parameter. Set
7725 OUTSIDE_RANGE_P.
7726 (c_add_case_label): Add bool * parameter. Pass it down to
7727 check_case_bounds.
7728 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
7729 warning here.
7730 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
7731 declarations.
7732
7733 2015-06-27 Marek Polacek <polacek@redhat.com>
7734
7735 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
7736 or VECTOR_INTEGER_TYPE_P throughout.
7737 * c-gimplify.c: Likewise.
7738
7739 2015-06-26 Marek Polacek <polacek@redhat.com>
7740
7741 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
7742 * c-common.c (c_fully_fold_internal): Likewise.
7743 (c_alignof_expr): Likewise.
7744 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
7745 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
7746 * cilk.c (create_parm_list): Likewise.
7747
7748 2015-06-26 Marek Polacek <polacek@redhat.com>
7749
7750 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
7751
7752 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
7753
7754 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
7755 * c-gimplify.c: Likewise.
7756 * c-pragma.c: Likewise.
7757 * c-ubsan.c: Likewise.
7758 * cilk.c: Likewise.
7759
7760 2015-06-25 Richard Sandiford <richard.sandiford@arm.com>
7761
7762 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
7763 ggc_hasher.
7764
7765 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
7766
7767 * cilk.c: Move calls.h after tm.h in the include chain.
7768
7769 2015-06-25 Marek Polacek <polacek@redhat.com>
7770
7771 * array-notation-common.c: Use VAR_P throughout.
7772 * c-ada-spec.c: Likewise.
7773 * c-common.c: Likewise.
7774 * c-format.c: Likewise.
7775 * c-gimplify.c: Likewise.
7776 * c-omp.c: Likewise.
7777 * c-pragma.c: Likewise.
7778 * c-pretty-print.c: Likewise.
7779 * cilk.c: Likewise.
7780
7781 2015-06-25 Marek Polacek <polacek@redhat.com>
7782
7783 * cilk.c (extract_free_variables): Use is_global_var.
7784
7785 2015-06-23 Richard Sandiford <richard.sandiford@arm.com>
7786
7787 * c-common.c: Don't include target-def.h.
7788
7789 2015-06-23 Marek Polacek <polacek@redhat.com>
7790
7791 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
7792 when comparing INTEGER_CSTs.
7793
7794 2015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
7795
7796 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
7797 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
7798 (dump_ada_template): Skip partially specialized types.
7799
7800 2015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
7801
7802 * c-common.c (scalar_to_vector): Use std::swap instead of manually
7803 swapping.
7804
7805 2015-06-17 Andrew MacLeod <amacleod@redhat.com>
7806
7807 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
7808 * c-ada-spec.c: Likewise.
7809 * c-cilkplus.c: Likewise.
7810 * c-common.c: Likewise.
7811 * c-common.h: Likewise.
7812 * c-cppbuiltin.c: Likewise.
7813 * c-dump.c: Likewise.
7814 * c-format.c: Likewise.
7815 * c-gimplify.c: Likewise.
7816 * c-indentation.c: Likewise.
7817 * c-lex.c: Likewise.
7818 * c-omp.c: Likewise.
7819 * c-opts.c: Likewise.
7820 * c-pch.c: Likewise.
7821 * c-ppoutput.c: Likewise.
7822 * c-pragma.c: Likewise.
7823 * c-pretty-print.c: Likewise.
7824 * c-semantics.c: Likewise.
7825 * c-ubsan.c: Likewise.
7826 * cilk.c: Likewise.
7827 * stub-objc.c: Likewise.
7828
7829 2015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
7830
7831 PR c++/65168
7832 * c-common.c (c_common_truthvalue_conversion): Warn when
7833 converting an address of a reference to a truth value.
7834
7835 2015-06-08 Andrew MacLeod <amacleod@redhat.com>
7836
7837 * array-notation-common.c : Adjust include files.
7838 * c-ada-spec.c : Likewise.
7839 * c-cilkplus.c : Likewise.
7840 * c-common.c : Likewise.
7841 * c-common.h : Likewise.
7842 * c-cppbuiltin.c : Likewise.
7843 * c-dump.c : Likewise.
7844 * c-format.c : Likewise.
7845 * c-gimplify.c : Likewise.
7846 * c-indentation.c : Likewise.
7847 * c-lex.c : Likewise.
7848 * c-omp.c : Likewise.
7849 * c-opts.c : Likewise.
7850 * c-pch.c : Likewise.
7851 * c-ppoutput.c : Likewise.
7852 * c-pragma.c : Likewise.
7853 * c-pretty-print.c : Likewise.
7854 * c-semantics.c : Likewise.
7855 * c-ubsan.c : Likewise.
7856 * cilk.c : Likewise.
7857 * stub-objc.c : Likewise.
7858
7859 2015-06-08 Marek Polacek <polacek@redhat.com>
7860
7861 PR c/66415
7862 * c-format.c (location_from_offset): Return LOC if LINE is null.
7863
7864 2015-06-05 Aldy Hernandez <aldyh@redhat.com>
7865
7866 * c-common.h (c_parse_final_cleanups): New prototype.
7867 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
7868
7869 2015-06-04 Sriraman Tallam <tmsriram@google.com>
7870
7871 * c-common.c (noplt): New attribute.
7872 (handle_noplt_attribute): New handler.
7873
7874 2015-06-04 Andrew MacLeod <amacleod@redhat.com>
7875
7876 * array-notation-common.c: Adjust includes for restructured coretypes.h.
7877 * c-ada-spec.c: Likewise.
7878 * c-cilkplus.c: Likewise.
7879 * c-common.c: Likewise.
7880 * c-common.h: Likewise.
7881 * c-cppbuiltin.c: Likewise.
7882 * c-dump.c: Likewise.
7883 * c-format.c: Likewise.
7884 * c-gimplify.c: Likewise.
7885 * c-indentation.c: Likewise.
7886 * c-lex.c: Likewise.
7887 * c-omp.c: Likewise.
7888 * c-opts.c: Likewise.
7889 * c-pch.c: Likewise.
7890 * c-ppoutput.c: Likewise.
7891 * c-pragma.c: Likewise.
7892 * c-pretty-print.c: Likewise.
7893 * c-semantics.c: Likewise.
7894 * c-ubsan.c: Likewise.
7895 * cilk.c: Likewise.
7896 * stub-objc.c: Likewise.
7897
7898 2015-06-02 David Malcolm <dmalcolm@redhat.com>
7899
7900 PR c/66220:
7901 * c-indentation.c (should_warn_for_misleading_indentation): Use
7902 expand_location rather than expand_location_to_spelling_point.
7903 Don't warn if the guarding statement is more indented than the
7904 next/body stmts.
7905
7906 2015-06-02 David Malcolm <dmalcolm@redhat.com>
7907
7908 * c-indentation.c (warn_for_misleading_indentation): Bail out
7909 immediately if -Wmisleading-indentation isn't enabled.
7910
7911 2015-06-01 Martin Liska <mliska@suse.cz>
7912
7913 * c-format.c (check_format_arg):Use new type-based pool allocator.
7914 (check_format_info_main) Likewise.
7915
7916 2015-05-31 Eric Botcazou <ebotcazou@adacore.com>
7917
7918 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
7919 (has_nontrivial_methods): Likewise.
7920
7921 2015-05-25 Marek Polacek <polacek@redhat.com>
7922
7923 * c-ubsan.c (ubsan_instrument_shift): Use type0.
7924
7925 2015-05-22 Marek Polacek <polacek@redhat.com>
7926
7927 PR c/47043
7928 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
7929
7930 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
7931
7932 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
7933 STACK_GROWS_DOWNWARD.
7934
7935 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
7936
7937 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
7938 STACK_GROWS_DOWNWARD rather than if it is defined.
7939
7940 2015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
7941
7942 PR c/52952
7943 * c-format.c (location_column_from_byte_offset): New.
7944 (location_from_offset): New.
7945 (struct format_wanted_type): Add offset_loc field.
7946 (check_format_info): Move handling of location for extra arguments
7947 closer to the point of warning.
7948 (check_format_info_main): Pass the result of location_from_offset
7949 to warning_at.
7950 (format_type_warning): Pass the result of location_from_offset
7951 to warning_at.
7952
7953 2015-05-20 Marek Polacek <polacek@redhat.com>
7954
7955 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
7956
7957 2015-05-20 Marek Polacek <polacek@redhat.com>
7958
7959 * c-ada-spec.c (dump_sloc): Use DECL_P.
7960
7961 2015-05-20 Marek Polacek <polacek@redhat.com>
7962
7963 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
7964 * c-common.c: Likewise.
7965
7966 2015-05-19 David Malcolm <dmalcolm@redhat.com>
7967
7968 * c-common.h (fe_file_change): Strengthen param from
7969 const line_map * to const line_map_ordinary *.
7970 (pp_file_change): Likewise.
7971 * c-lex.c (fe_file_change): Likewise.
7972 (cb_define): Use linemap_check_ordinary when invoking
7973 SOURCE_LINE.
7974 (cb_undef): Likewise.
7975 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
7976 invoking cb_file_change.
7977 (c_finish_options): Likewise.
7978 (push_command_line_include): Likewise.
7979 (cb_file_change): Strengthen param "new_map" from
7980 const line_map * to const line_map_ordinary *.
7981 * c-ppoutput.c (cb_define): Likewise for local "map".
7982 (pp_file_change): Likewise for param "map" and local "from".
7983
7984 2015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
7985
7986 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
7987
7988 2015-05-18 Tom de Vries <tom@codesourcery.com>
7989
7990 * c-common.c (build_va_arg_1): New function.
7991 (build_va_arg): Add address operator to va_list operand if necessary.
7992
7993 2015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
7994
7995 PR c/48956
7996 * c-common.c (int_safely_convertible_to_real_p): Define.
7997 (unsafe_conversion_p): Check conversions involving complex types.
7998 (conversion_warning): Add new warning message for conversions which
7999 discard imaginary component.
8000 * c-common.h: (enum conversion_safety): Add new enumerator for such
8001 conversions.
8002
8003 2015-05-14 Marek Polacek <polacek@redhat.com>
8004
8005 PR c/66066
8006 PR c/66127
8007 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
8008 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
8009 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
8010 use it. If FOR_INT_CONST, require that all evaluated operands be
8011 INTEGER_CSTs.
8012
8013 2015-05-12 David Malcolm <dmalcolm@redhat.com>
8014
8015 * c-common.h (warn_for_misleading_indentation): New prototype.
8016 * c-indentation.c: New file.
8017 * c.opt (Wmisleading-indentation): New option.
8018
8019 2015-05-12 Tom de Vries <tom@codesourcery.com>
8020
8021 PR tree-optimization/66010
8022 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
8023
8024 2015-05-09 Jason Merrill <jason@redhat.com>
8025
8026 * c-opts.c (c_common_post_options): Also clear
8027 cpp_opts->cpp_warn_cxx11_compat.
8028
8029 * c-common.h (enum cxx_dialect): Add cxx_unset.
8030 * c-common.c (cxx_dialect): Initialize to cxx_unset.
8031 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
8032
8033 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
8034 (std=gnu++0x): Mark as Undocumented.
8035 (std=gnu++1y): Add deprecated message.
8036
8037 2015-05-08 Jason Merrill <jason@redhat.com>
8038
8039 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
8040 * c-opts.c: Adjust.
8041
8042 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
8043
8044 2015-05-08 Marek Polacek <polacek@redhat.com>
8045
8046 PR c/64918
8047 * c.opt (Woverride-init-side-effects): New option.
8048
8049 2015-05-07 Marek Polacek <polacek@redhat.com>
8050
8051 PR c/65179
8052 * c-common.c (c_fully_fold_internal): Warn when left shifting a
8053 negative value.
8054 * c.opt (Wshift-negative-value): New option.
8055 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
8056 when -Wextra and C99/C++11 mode.
8057
8058 2015-05-07 Marek Polacek <polacek@redhat.com>
8059 Martin Uecker <uecker@eecs.berkeley.edu>
8060
8061 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
8062 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
8063
8064 2015-05-05 Jason Merrill <jason@redhat.com>
8065
8066 * c.opt (Wterminate): New.
8067
8068 2015-04-30 Marek Polacek <polacek@redhat.com>
8069
8070 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
8071 require that the non-constant be of a boolean type.
8072
8073 2015-04-29 Josh Triplett <josh@joshtriplett.org>
8074
8075 * c-common.c (handle_section_attribute): Refactor to reduce
8076 nesting and distinguish between error cases.
8077
8078 2015-04-29 Marek Polacek <polacek@redhat.com>
8079
8080 PR c/64610
8081 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
8082 with 0/1.
8083
8084 2015-04-29 Jakub Jelinek <jakub@redhat.com>
8085
8086 * c-common.h (omp_clause_mask): Unconditionally define as a class.
8087 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
8088 HOST_BITS_PER_WIDE_INT.
8089
8090 2015-04-28 Tom de Vries <tom@codesourcery.com>
8091
8092 PR tree-optimization/65887
8093 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
8094
8095 2015-04-28 Eric Botcazou <ebotcazou@adacore.com>
8096 Pierre-Marie de Rodat <derodat@adacore.com>
8097
8098 * c-ada-spec.c (in_function): Delete.
8099 (dump_generic_ada_node): Do not change in_function and remove the
8100 redundant code dealing with it.
8101 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
8102 (print_ada_methods): Output the static member functions in a nested
8103 package after the regular methods as well as associated renamings.
8104
8105 2015-04-24 Marek Polacek <polacek@redhat.com>
8106
8107 PR c/65830
8108 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
8109 and OPT_Wshift_count_overflow.
8110
8111 PR c/63357
8112 * c-common.c (warn_logical_operator): Warn if the operands have the
8113 same expressions.
8114
8115 2015-04-24 Marek Polacek <polacek@redhat.com>
8116
8117 PR c/61534
8118 * c-common.c (warn_logical_operator): Bail if either operand comes
8119 from a macro expansion.
8120
8121 2015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
8122
8123 PR target/55143
8124 * c-common.c (c_default_pointer_mode): Add definition.
8125 * c-common.h (c_default_pointer_mode): Add declaration.
8126
8127 2015-03-11 Jakub Jelinek <jakub@redhat.com>
8128
8129 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
8130 on record_builtin_type argument.
8131
8132 2015-03-10 Jakub Jelinek <jakub@redhat.com>
8133
8134 PR c/65120
8135 * c-common.c (warn_logical_not_parentheses): Don't warn for
8136 !x == 0 or !x != 0.
8137
8138 2015-03-07 Marek Polacek <polacek@redhat.com>
8139
8140 PR sanitizer/65280
8141 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
8142 before trying to figure out whether we have a flexible array member.
8143
8144 2015-03-06 Eric Botcazou <ebotcazou@adacore.com>
8145 Jonathan Wakely <jwakely.gcc@gmail.com>
8146
8147 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
8148
8149 2015-03-05 Eric Botcazou <ebotcazou@adacore.com>
8150
8151 PR ada/65319
8152 * c-ada-spec.c (print_destructor): Remove obsolete code.
8153
8154 2015-03-01 Eric Botcazou <ebotcazou@adacore.com>
8155
8156 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
8157 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
8158 DECL_TEMPLATE_RESULT emulations.
8159 (dump_ada_template)): Add guard for TYPE_METHODS.
8160
8161 2015-02-27 Marek Polacek <polacek@redhat.com>
8162
8163 PR c/65040
8164 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
8165
8166 2015-02-27 Kai Tietz <ktietz@redhat.com>
8167
8168 PR c/35330
8169 * c-pragma.c (handle_pragma_weak): Do not try to create
8170 weak/alias of declarations not being function, or variable
8171 declarations.
8172
8173 2015-02-24 Thomas Schwinge <thomas@codesourcery.com>
8174
8175 PR libgomp/64625
8176 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
8177 Remove macros.
8178 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
8179
8180 2015-02-16 Marek Polacek <polacek@redhat.com>
8181
8182 PR c/65066
8183 * c-format.c (check_format_types): Handle null param.
8184
8185 2015-02-13 Marek Polacek <polacek@redhat.com>
8186
8187 PR c/65040
8188 * c-format.c (check_format_types): Don't warn about different
8189 signedness if the original value is in the range of WANTED_TYPE.
8190
8191 2015-02-12 Jason Merrill <jason@redhat.com>
8192
8193 PR c++/64956
8194 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
8195 to the current highest version.
8196 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
8197
8198 2015-02-04 Jakub Jelinek <jakub@redhat.com>
8199
8200 PR c/64824
8201 PR c/64868
8202 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
8203 instead of RDIV_EXPR. Use build_binary_op instead of
8204 build2_loc.
8205
8206 2015-01-30 Joseph Myers <joseph@codesourcery.com>
8207
8208 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
8209 to pass input_location as first argument.
8210
8211 2015-01-23 Tom de Vries <tom@codesourcery.com>
8212
8213 PR libgomp/64672
8214 * c.opt (fopenacc): Mark as LTO option.
8215
8216 2015-01-23 Tom de Vries <tom@codesourcery.com>
8217
8218 PR libgomp/64707
8219 * c.opt (fopenmp): Mark as LTO option.
8220
8221 2015-01-21 Jakub Jelinek <jakub@redhat.com>
8222
8223 PR c/63307
8224 * cilk.c (fill_decls_vec): Only put decls into vector v.
8225 (compare_decls): Fix up formatting.
8226
8227 2015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
8228
8229 PR c/63307
8230 * cilk.c: Include vec.h.
8231 (struct cilk_decls): New structure.
8232 (wrapper_parm_cb): Split this function to...
8233 (fill_decls_vec): ...this...
8234 (create_parm_list): ...and this.
8235 (compare_decls): New function.
8236 (for_local_cb): Remove.
8237 (wrapper_local_cb): Ditto.
8238 (build_wrapper_type): For now first traverse and fill vector of
8239 declarations then sort it and then deal with sorted vector.
8240 (cilk_outline): Ditto.
8241 (declare_one_free_variable): Ditto.
8242
8243 2015-01-21 Jason Merrill <jason@redhat.com>
8244
8245 PR c++/64629
8246 * c-format.c (check_format_arg): Call decl_constant_value.
8247
8248 2015-01-19 Martin Liska <mliska@suse.cz>
8249
8250 * c-common.c (handle_noicf_attribute): New function.
8251
8252 2015-01-15 Thomas Schwinge <thomas@codesourcery.com>
8253 Bernd Schmidt <bernds@codesourcery.com>
8254 James Norris <jnorris@codesourcery.com>
8255 Cesar Philippidis <cesar@codesourcery.com>
8256 Ilmir Usmanov <i.usmanov@samsung.com>
8257 Jakub Jelinek <jakub@redhat.com>
8258
8259 * c.opt (fopenacc): New option.
8260 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
8261 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
8262 New macros.
8263 * c-common.h (c_finish_oacc_wait): New prototype.
8264 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
8265 (c_finish_oacc_wait): New function.
8266 * c-pragma.c (oacc_pragmas): New variable.
8267 (c_pp_lookup_pragma, init_pragma): Handle it.
8268 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
8269 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
8270 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
8271 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
8272 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
8273 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
8274 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
8275 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
8276 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
8277 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
8278 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
8279 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
8280 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
8281 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
8282 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
8283 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
8284 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
8285 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
8286 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
8287 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
8288 PRAGMA_OACC_CLAUSE_WORKER.
8289
8290 2015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
8291
8292 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
8293 for the new option fstack-protector_explicit.
8294 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
8295 (handle_stack_protect_attribute): New function.
8296
8297 2015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
8298
8299 * c.opt: New option -Warray-bounds=.
8300
8301 2015-01-09 Michael Collison <michael.collison@linaro.org>
8302
8303 * array-notation-common.c: Include hash-set.h, machmode.h,
8304 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
8305 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
8306 * c-ada-spec.c: Ditto.
8307 * c-cilkplus.c: Ditto.
8308 * c-common.c: Include input.h due to flattening of tree.h.
8309 Define macro GCC_C_COMMON_C.
8310 * c-common.h: Flatten tree.h header files into c-common.h.
8311 Remove include of tree-core.h.
8312 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
8313 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
8314 fold-const.h, wide-int.h, and inchash.h due to
8315 flattening of tree.h.
8316 * c-dump.c: Ditto.
8317 * c-format.c: Flatten tree.h header files into c-common.h.
8318 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
8319 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
8320 fold-const.h, wide-int.h, and inchash.h due to
8321 flattening of tree.h.
8322 * c-dump.c: Include hash-set.h, machmode.h,
8323 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
8324 fold-const.h, wide-int.h, and inchash.h due to
8325 flattening of tree.h.
8326 * c-format.c: Include hash-set.h, machmode.h,
8327 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
8328 fold-const.h, wide-int.h, inchash.h and real.h due to
8329 flattening of tree.h.
8330 * c-gimplify.c: Include hash-set.h, machmode.h,
8331 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
8332 fold-const.h, wide-int.h, and inchash.h due to
8333 flattening of tree.h.
8334 * cilk.c: Ditto.
8335 * c-lex.c: Ditto.
8336 * c-omp.c: Ditto.
8337 * c-opts.c: Ditto.
8338 * c-pch.c: Ditto.
8339 * c-ppoutput.c: Ditto.
8340 * c-pragma.c: Ditto.
8341 * c-pretty-print.c: Ditto.
8342 * c-semantics.c: Ditto.
8343 * c-ubsan.c: Ditto.
8344 * stub-objc.c: Ditto.
8345
8346 2015-01-08 Jason Merrill <jason@redhat.com>
8347
8348 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
8349 do_ubsan_in_current_function.
8350 (ubsan_maybe_instrument_reference_or_call): Likewise.
8351 * c-ubsan.h: Declare it.
8352
8353 2015-01-08 Mike Stump <mikestump@comcast.net>
8354
8355 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
8356
8357 2015-01-07 Marek Polacek <polacek@redhat.com>
8358
8359 PR c/64440
8360 * c-common.c (c_fully_fold_internal): Warn for division and modulo
8361 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
8362
8363 2015-01-05 Trevor Saunders <tsaunders@mozilla.com>
8364
8365 PR c++/31397
8366 * c.opt (Wsuggest-override): New option.
8367
8368 2015-01-05 Jakub Jelinek <jakub@redhat.com>
8369
8370 Update copyright years.
8371
8372 2015-01-05 Marek Polacek <polacek@redhat.com>
8373
8374 PR c/64423
8375 * c-common.c (warn_array_subscript_with_type_char): Add location_t
8376 parameter. Use it.
8377 * c-common.h (warn_array_subscript_with_type_char): Update
8378 declaration.
8379
8380 2014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
8381
8382 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
8383 Control macro with flag_sized_deallocation.
8384
8385 2014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
8386
8387 * c.opt (Wdiscarded-array-qualifiers): New option.
8388
8389 2014-12-19 Jakub Jelinek <jakub@redhat.com>
8390
8391 PR preprocessor/63831
8392 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
8393 and __has_cpp_attribute here.
8394 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
8395 c_common_has_attribute.
8396 * c-common.h (c_common_has_attribute): New prototype.
8397 * c-lex.c (init_c_lex): Set cb->has_attribute to
8398 c_common_has_attribute instead of cb_has_attribute.
8399 (get_token_no_padding): New function.
8400 (cb_has_attribute): Renamed to ...
8401 (c_common_has_attribute): ... this. No longer static. Use
8402 get_token_no_padding, require ()s, don't build TREE_LIST
8403 unnecessarily, fix up formatting, adjust diagnostics, call
8404 init_attributes.
8405
8406 2014-12-15 Jason Merrill <jason@redhat.com>
8407
8408 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
8409 (-Wsized-deallocation): New.
8410 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
8411 to on in C++14 and up.
8412
8413 2014-12-11 Jason Merrill <jason@redhat.com>
8414
8415 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
8416
8417 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
8418 we aren't complaining about VLAs.
8419
8420 2014-12-06 Marek Polacek <polacek@redhat.com>
8421
8422 PR tree-optimization/64183
8423 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
8424 shift-expression if it is integer_type_node. Use types_compatible_p.
8425
8426 2014-11-29 Jakub Jelinek <jakub@redhat.com>
8427
8428 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
8429 last argument from create_tmp_var_raw and create_tmp_var calls.
8430 * cilk.c (gimplify_cilk_spawn): Likewise.
8431 * c-omp.c (c_finish_omp_atomic): Likewise.
8432
8433 2014-11-28 Marek Polacek <polacek@redhat.com>
8434
8435 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
8436 instead of unsigned_type_node.
8437
8438 2014-11-28 Marek Polacek <polacek@redhat.com>
8439
8440 PR c/63862
8441 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
8442 to op1_utype.
8443 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
8444 expression to unsigned_type_node.
8445
8446 2014-11-20 Mark Wielaard <mjw@redhat.com>
8447
8448 PR debug/38757
8449 * c-opts.c (set_std_c89): Set lang_hooks.name.
8450 (set_std_c99): Likewise.
8451 (set_std_c11): Likewise.
8452 (set_std_cxx98): Likewise.
8453 (set_std_cxx11): Likewise.
8454 (set_std_cxx14): Likewise.
8455 (set_std_cxx1z): Likewise.
8456
8457 2014-11-21 Jakub Jelinek <jakub@redhat.com>
8458
8459 PR target/63764
8460 * c-common.h (convert_vector_to_pointer_for_subscript): Change
8461 return type to bool.
8462 * c-common.c: Include gimple-expr.h.
8463 (convert_vector_to_pointer_for_subscript): Change return type to
8464 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
8465 and copy it into a TARGET_EXPR and use that instead of *vecp
8466 directly.
8467
8468 2014-11-19 David Malcolm <dmalcolm@redhat.com>
8469
8470 Merger of git branch "gimple-classes-v2-option-3".
8471 * ChangeLog.gimple-classes: New.
8472 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
8473 from being just a vec<gimple> to a vec<gbind *>.
8474
8475 2014-11-18 Jakub Jelinek <jakub@redhat.com>
8476
8477 PR sanitizer/63813
8478 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
8479 argument to ptype, set type to TREE_TYPE (ptype). Don't call
8480 get_pointer_alignment for non-pointers. Use ptype, or if it is
8481 reference type, corresponding pointer type, as type of kind
8482 argument.
8483 (ubsan_maybe_instrument_reference,
8484 ubsan_maybe_instrument_member_call): Adjust callers.
8485
8486 2014-11-15 Marek Polacek <polacek@redhat.com>
8487
8488 PR middle-end/63884
8489 * array-notation-common.c (is_sec_implicit_index_fn): Return false
8490 for NULL fndecl.
8491 (extract_array_notation_exprs): Return for NULL node.
8492
8493 2014-11-12 Joseph Myers <joseph@codesourcery.com>
8494
8495 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
8496 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
8497
8498 2014-11-12 Jakub Jelinek <jakub@redhat.com>
8499
8500 PR c/59708
8501 * c-common.c (check_builtin_function_arguments): Handle
8502 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
8503
8504 2014-11-10 Andi Kleen <ak@linux.intel.com>
8505
8506 PR c/60804
8507 * c-common.h (check_no_cilk): Declare.
8508 * cilk.c (get_error_location): New function.
8509 (check_no_cilk): Dito.
8510
8511 2014-11-10 Andi Kleen <ak@linux.intel.com>
8512
8513 * cilk.c (recognize_spawn): Use expression location
8514 for error message.
8515
8516 2014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
8517
8518 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
8519
8520 2014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
8521
8522 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
8523 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
8524 (__cpp_range_based_for, __cpp_initializer_lists,
8525 __cpp_delegating_constructors, __cpp_nsdmi,
8526 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
8527 for C++11; (__cpp_attribute_deprecated): Remove in favor of
8528 __has_cpp_attribute.
8529 * c-lex.c (cb_has_attribute): New callback CPP function;
8530 (init_c_lex): Set has_attribute callback.
8531
8532 2014-11-04 Richard Biener <rguenther@suse.de>
8533
8534 * c-common.c (shorten_compare): Do not shorten mixed
8535 DFP and non-DFP compares.
8536
8537 2014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
8538
8539 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
8540 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
8541 Commentary and rearrangement of tests.
8542 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
8543 Commentary and rearrangement of tests.
8544 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
8545 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
8546
8547 2014-10-29 Richard Sandiford <richard.sandiford@arm.com>
8548
8549 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
8550 enum from machine_mode.
8551
8552 2014-10-28 Andrew MacLeod <amacleod@redhat.com>
8553
8554 * c-common.c: Adjust include files.
8555 * c-gimplify.c: Ditto.
8556 * cilk.c: Ditto.
8557 * c-pragma.c: Ditto.
8558 * c-ubsan.c: Ditto.
8559
8560 2014-10-27 Andrew MacLeod <amacleod@redhat.com>
8561
8562 * c-gimplify.c: Adjust include files.
8563
8564 2014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
8565
8566 PR c++/53061
8567 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
8568 c_common_initialize_diagnostics.
8569 * c-common.h: Likewise.
8570
8571 2014-10-24 Marek Polacek <polacek@redhat.com>
8572
8573 PR c/56980
8574 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
8575 print "struct"/"union"/"enum" for typedefed names.
8576
8577 2014-10-23 Marek Polacek <polacek@redhat.com>
8578
8579 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
8580 in unsigned type.
8581
8582 2014-10-22 Jakub Jelinek <jakub@redhat.com>
8583 Yury Gribov <y.gribov@samsung.com>
8584
8585 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
8586 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
8587 instead of flag_sanitize_recover as bool flag.
8588
8589 2014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
8590
8591 * cilk.c: Revert previous change.
8592
8593 2014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
8594
8595 PR c/63307
8596 * cilk.c: Include vec.h.
8597 (struct cilk_decls): New structure.
8598 (wrapper_parm_cb): Split this function to...
8599 (fill_decls_vec): ...this...
8600 (create_parm_list): ...and this.
8601 (compare_decls): New function.
8602 (for_local_cb): Remove.
8603 (wrapper_local_cb): Ditto.
8604 (build_wrapper_type): For now first traverse and fill vector of
8605 declarations then sort it and then deal with sorted vector.
8606 (cilk_outline): Ditto.
8607 (declare_one_free_variable): Ditto.
8608
8609 2014-10-17 Marek Polacek <polacek@redhat.com>
8610
8611 * c-opts.c (c_common_post_options): Set warn_implicit_int.
8612 * c.opt (Wimplicit-int): Initialize to -1.
8613
8614 2014-10-16 Andrew MacLeod <amacleod@redhat.com>
8615
8616 * c-pragma.c: Adjust include files.
8617 * c-semantics.c: Likewise.
8618
8619 2014-10-16 DJ Delorie <dj@redhat.com>
8620
8621 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
8622 multiples of bytes.
8623
8624 2014-10-14 Jason Merrill <jason@redhat.com>
8625
8626 PR c++/63455
8627 * c-common.h (CPP_PREPARSED_EXPR): New.
8628 (N_CP_TTYPES): Adjust.
8629
8630 2014-10-15 Marek Polacek <polacek@redhat.com>
8631
8632 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
8633
8634 2014-10-14 DJ Delorie <dj@redhat.com>
8635
8636 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
8637 types, not just __int128.
8638 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
8639 types, not just __int128.
8640 (cpp_atomic_builtins): Round pointer sizes up.
8641 (type_suffix): Use type precision, not specific types.
8642 * c-common.c (c_common_reswords): Remove __int128 special case.
8643 (c_common_type_for_size): Check for all __intN types, not just
8644 __int128.
8645 (c_common_type_for_mode): Likewise.
8646 (c_common_signed_or_unsigned_type): Likewise.
8647 (c_build_bitfield_integer_type): Likewise.
8648 (c_common_nodes_and_builtins): Likewise.
8649 (keyword_begins_type_specifier): Likewise.
8650 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
8651 __intN variants.
8652
8653 2014-10-12 Trevor Saunders <tsaunders@mozilla.com>
8654
8655 * c-common.c: Use hash_table instead of hashtab.
8656
8657 2014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
8658
8659 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
8660 C++11 section.
8661
8662 2014-10-03 Marc Glisse <marc.glisse@inria.fr>
8663
8664 PR c++/54427
8665 PR c++/57198
8666 PR c++/58845
8667 * c-common.c (warn_logical_operator): Punt for vectors.
8668
8669 2014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
8670
8671 Implement SD-6: SG10 Feature Test Recommendations
8672 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
8673 macros and the __has_header macro.
8674
8675 2014-09-30 Jason Merrill <jason@redhat.com>
8676
8677 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
8678 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
8679 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
8680
8681 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
8682 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
8683
8684 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
8685 * c-common.c (c_common_reswords): Remove __is_convertible_to.
8686
8687 2014-09-24 Marek Polacek <polacek@redhat.com>
8688
8689 PR c/61405
8690 PR c/53874
8691 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
8692
8693 2014-09-23 Andi Kleen <ak@linux.intel.com>
8694
8695 * c-common.c (handle_no_reorder_attribute): New function.
8696 (c_common_attribute_table): Add no_reorder attribute.
8697
8698 2014-09-22 Joseph Myers <joseph@codesourcery.com>
8699
8700 * c-cppbuiltin.c (c_cpp_builtins): Define
8701 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
8702 modes.
8703
8704 2014-09-18 Joseph Myers <joseph@codesourcery.com>
8705
8706 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
8707 for supported floating-point modes.
8708
8709 2014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
8710
8711 * c.opt (Wpsabi): Use LangEnabledBy.
8712 * c-opts.c (c_common_handle_option): Do not handle here.
8713
8714 2014-09-12 Joseph Myers <joseph@codesourcery.com>
8715
8716 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
8717 macros for floating-point modes.
8718
8719 2014-09-11 Marc Glisse <marc.glisse@inria.fr>
8720
8721 PR target/58757
8722 * c-cppbuiltin.c (builtin_define_float_constants): Correct
8723 __*_DENORM_MIN__ without denormals.
8724
8725 2014-09-10 Jakub Jelinek <jakub@redhat.com>
8726
8727 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
8728 ubsan_instrument_vla, ubsan_instrument_return): Adjust
8729 ubsan_create_data callers.
8730 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
8731 index is constant or BIT_AND_EXPR with constant mask and is
8732 small enough for the bound.
8733 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
8734 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
8735
8736 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
8737
8738 * c.opt: Add CppReason to various flags.
8739 (Wdate-time): Re-sort.
8740 * c-common.c: Include c-common.h earlier.
8741 (struct reason_option_codes_t): Delete.
8742 (c_option_controlling_cpp_error): Prefix global type and struct
8743 with cpp_.
8744
8745 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
8746
8747 * c.opt (Wnormalized): New.
8748 (Wnormalized=): Use Enum and Reject Negative.
8749 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
8750
8751 2014-09-08 Joseph Myers <joseph@codesourcery.com>
8752
8753 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
8754 digits of floating-point modes if -fbuilding-libgcc.
8755
8756 2014-09-05 Joseph Myers <joseph@codesourcery.com>
8757
8758 * c-cppbuiltin.c (c_cpp_builtins): Also define
8759 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
8760 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
8761 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
8762 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
8763 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
8764 __LIBGCC_STACK_GROWS_DOWNWARD__,
8765 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
8766 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
8767 __LIBGCC_DWARF_FRAME_REGISTERS__,
8768 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
8769 __LIBGCC_STACK_POINTER_REGNUM__ and
8770 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
8771 (builtin_define_with_value): Handle backslash-escaping in string
8772 macro values.
8773
8774 2014-09-05 Richard Biener <rguenther@suse.de>
8775
8776 PR middle-end/63148
8777 * c-format.c (check_format_arg): Properly handle
8778 effectively signed POINTER_PLUS_EXPR offset.
8779
8780 2014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
8781
8782 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
8783 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
8784 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
8785 and Init.
8786 * c-opts.c (c_common_handle_option): Do not handle here.
8787 (sanitize_cpp_opts): Likewise.
8788 * c-common.c (struct reason_option_codes_t): Handle
8789 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
8790
8791 2014-09-03 Marek Polacek <polacek@redhat.com>
8792
8793 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
8794
8795 2014-09-02 Jakub Jelinek <jakub@redhat.com>
8796 Balaji V. Iyer <balaji.v.iyer@intel.com>
8797 Igor Zamyatin <igor.zamyatin@intel.com>
8798
8799 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
8800 * c-common.c (c_common_reswords): Added _Cilk_for.
8801 * c-common.h (enum rid): Added RID_CILK_FOR.
8802 (cilk_for_number_of_iterations): Add declaration.
8803 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
8804 CILK_FOR.
8805 * c-pragma.c (init_pragma): Register "grainsize" pragma.
8806 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
8807
8808 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
8809
8810 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
8811 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
8812 Wundef): Use CPP, Var and Init.
8813 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
8814
8815 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
8816
8817 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
8818 * c-opts.c (c_common_handle_option): Do not handle here.
8819
8820 2014-08-25 Jason Merrill <jason@redhat.com>
8821
8822 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
8823 -std=c++14 and -std=gnu++14, rather than the reverse.
8824 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
8825 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
8826 * c-common.h (cxx_dialect): Remove cxx1y.
8827
8828 2014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
8829
8830 * c-common.h (enum cxx_dialect): Add cxx14.
8831 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
8832 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
8833 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
8834
8835 2014-08-22 Jason Merrill <jason@redhat.com>
8836
8837 * c.opt (std=gnu++17): Fix alias.
8838
8839 2014-08-22 Marek Polacek <polacek@redhat.com>
8840
8841 PR c++/62199
8842 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
8843 check for vector types. Drop LHS argument.
8844 * c-common.h (warn_logical_not_parentheses): Adjust.
8845
8846 2014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
8847
8848 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
8849 (Wmultichar): Likewise.
8850 (Wdate-time): Use C-family languages instead of Common. Use CPP
8851 and Var.
8852 * c-opts.c (c_common_handle_option): Do not handle the above
8853 options here.
8854 (sanitize_cpp_opts): Likewise.
8855
8856 2014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
8857
8858 PR fortran/44054
8859 * c-opts.c: Include tree-diagnostics.h.
8860 (c_diagnostic_finalizer): New.
8861 (c_common_initialize_diagnostics): Use it.
8862
8863 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
8864
8865 PR preprocessor/51303
8866 * c-common.c (struct reason_option_codes_t option_codes):
8867 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
8868
8869 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
8870
8871 PR c/60975
8872 PR c/53063
8873 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
8874 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
8875 (c_common_post_options): Call init_global_opts_from_cpp.
8876 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
8877
8878 2014-08-19 Marek Polacek <polacek@redhat.com>
8879
8880 PR c++/62153
8881 * c-common.c (maybe_warn_bool_compare): New function.
8882 * c-common.h (maybe_warn_bool_compare): Declare.
8883 * c.opt (Wbool-compare): New option.
8884
8885 2014-08-19 Marek Polacek <polacek@redhat.com>
8886
8887 * c.opt (Wc99-c11-compat): New option.
8888
8889 2014-08-19 Marek Polacek <polacek@redhat.com>
8890
8891 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
8892 to warn_c90_c99_compat.
8893 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
8894 to -1.
8895
8896 2014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
8897 Steven Bosscher <steven@gcc.gnu.org>
8898
8899 PR c/52952
8900 * c-format.c: Add extra_arg_loc and format_string_loc to struct
8901 format_check_results.
8902 (check_function_format): Use true and add comment for boolean
8903 argument.
8904 (finish_dollar_format_checking): Use explicit location when warning.
8905 (check_format_info): Likewise.
8906 (check_format_arg): Set extra_arg_loc and format_string_loc.
8907 (check_format_info_main): Use explicit location when warning.
8908 (check_format_types): Pass explicit location.
8909 (format_type_warning): Likewise.
8910
8911 2014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
8912
8913 PR fortran/44054
8914 * c-format.c: Handle Fortran flags.
8915
8916 2014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
8917
8918 PR other/61962
8919 * array-notation-common.c (find_rank): Added handling for other
8920 types of references.
8921
8922 2014-08-10 Marek Polacek <polacek@redhat.com>
8923
8924 PR c/51849
8925 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
8926 * c.opt (Wc90-c99-compat): Add option.
8927
8928 2014-08-07 Trevor Saunders <tsaunders@mozilla.com>
8929
8930 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
8931
8932 2014-08-03 Marek Polacek <polacek@redhat.com>
8933
8934 * c-common.c (check_case_value): Add location_t parameter. Use it.
8935 (c_add_case_label): Pass loc to check_case_value.
8936
8937 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
8938
8939 * cilk.c: Use hash_map instead of pointer_map.
8940
8941 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
8942
8943 * c-gimplify.c: Use hash_set instead of pointer_set.
8944
8945 2014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
8946
8947 PR middle-end/61455
8948 * array-notation-common.c (extract_array_notation_exprs): Handling
8949 of DECL_EXPR added.
8950
8951 2014-08-01 Jakub Jelinek <jakub@redhat.com>
8952
8953 * c-common.h (min_align_of_type): Removed prototype.
8954 * c-common.c (min_align_of_type): Removed.
8955 * c-ubsan.h (ubsan_maybe_instrument_reference,
8956 ubsan_maybe_instrument_member_call): New prototypes.
8957 * c-ubsan.c: Include stor-layout.h and builtins.h.
8958 (ubsan_maybe_instrument_reference_or_call,
8959 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
8960 functions.
8961
8962 2014-07-31 Marc Glisse <marc.glisse@inria.fr>
8963
8964 PR c++/60517
8965 * c.opt (-Wreturn-local-addr): Move to common.opt.
8966
8967 2014-07-30 Jason Merrill <jason@redhat.com>
8968
8969 PR c++/61659
8970 PR c++/61687
8971 Revert:
8972 * c.opt (-fuse-all-virtuals): New.
8973
8974 2014-07-30 Tom Tromey <tromey@redhat.com>
8975
8976 PR c/59855
8977 * c.opt (Wdesignated-init): New option.
8978 * c-common.c (c_common_attribute_table): Add "designated_init".
8979 (handle_designated_init): New function.
8980
8981 2014-07-24 Marek Polacek <polacek@redhat.com>
8982
8983 PR c/57653
8984 * c-opts.c (c_finish_options): If -imacros is in effect, return.
8985
8986 2014-07-16 Dodji Seketeli <dodji@redhat.com>
8987
8988 PR preprocessor/60723 - missing system-ness marks for macro tokens
8989 * c-ppoutput.c (struct print::prev_was_system_token): New data
8990 member.
8991 (init_pp_output): Initialize it.
8992 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
8993 (do_line_change): Return a flag saying if a line marker was
8994 emitted or not.
8995 (scan_translation_unit): Detect if the system-ness of the token we
8996 are about to emit is different from the one of the previously
8997 emitted token. If so, emit a line marker. Avoid emitting useless
8998 adjacent line markers. Avoid emitting line markers for tokens
8999 originating from the expansion of built-in macros.
9000 (scan_translation_unit_directives_only): Adjust.
9001
9002 2014-07-15 Marek Polacek <polacek@redhat.com>
9003
9004 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
9005 TYPE_MAX_VALUE is NULL.
9006
9007 2014-07-14 Jakub Jelinek <jakub@redhat.com>
9008
9009 PR middle-end/61294
9010 * c.opt (Wmemset-transposed-args): New warning.
9011
9012 2014-07-10 Jason Merrill <jason@redhat.com>
9013
9014 PR c++/61659
9015 PR c++/61687
9016 * c.opt (-fuse-all-virtuals): New.
9017
9018 2014-07-09 Richard Biener <rguenther@suse.de>
9019
9020 PR c-family/61741
9021 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
9022 using unsigned arithmetic if overflow does not wrap instead of
9023 if overflow is undefined.
9024
9025 2014-07-06 Marek Polacek <polacek@redhat.com>
9026
9027 PR c/6940
9028 * c.opt (Wsizeof-array-argument): New option.
9029
9030 2014-07-03 Jakub Jelinek <jakub@redhat.com>
9031
9032 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
9033 comments->count <= 1, as comments->entries might be NULL.
9034
9035 2014-07-01 Marek Polacek <polacek@redhat.com>
9036
9037 * c.opt (Wint-conversion): New option.
9038
9039 2014-07-01 Marek Polacek <polacek@redhat.com>
9040
9041 PR c/58286
9042 * c.opt (Wincompatible-pointer-types): New option.
9043
9044 2014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
9045
9046 PR c++/51400
9047 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
9048 Do not discard TYPE_QUALS of type.
9049
9050 2014-06-26 Jason Merrill <jason@redhat.com>
9051
9052 * c-common.h (enum cxx_dialect): Add cxx1z.
9053 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
9054 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
9055
9056 2014-06-26 Teresa Johnson <tejohnson@google.com>
9057
9058 * c-common.h (get_dump_info): Declare.
9059 * c-gimplify.c (c_genericize): Use saved dump files.
9060 * c-opts.c (c_common_parse_file): Begin and end dumps
9061 once around parsing invocation.
9062 (get_dump_info): New function.
9063
9064 2014-06-23 Marek Polacek <polacek@redhat.com>
9065 Andrew MacLeod <amacleod@redhat.com>
9066
9067 PR c/61553
9068 * c-common.c (get_atomic_generic_size): Don't segfault if the
9069 type doesn't have a size.
9070
9071 2014-06-20 Marek Polacek <polacek@redhat.com>
9072
9073 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
9074 (ubsan_walk_array_refs_r): New function.
9075 (c_genericize): Instrument array bounds.
9076 * c-ubsan.c: Include "internal-fn.h".
9077 (ubsan_instrument_division): Mark instrumented arrays as having
9078 side effects. Adjust ubsan_type_descriptor call.
9079 (ubsan_instrument_shift): Likewise.
9080 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
9081 (ubsan_instrument_bounds): New function.
9082 (ubsan_array_ref_instrumented_p): New function.
9083 (ubsan_maybe_instrument_array_ref): New function.
9084 * c-ubsan.h (ubsan_instrument_bounds): Declare.
9085 (ubsan_array_ref_instrumented_p): Declare.
9086 (ubsan_maybe_instrument_array_ref): Declare.
9087
9088 2014-06-20 Hale Wang <hale.wang@arm.com>
9089
9090 PR lto/61123
9091 * c.opt (fshort-enums): Add to LTO.
9092 * c.opt (fshort-wchar): Likewise.
9093
9094 2014-06-16 Marek Polacek <polacek@redhat.com>
9095
9096 PR c/60439
9097 * c.opt (Wswitch-bool): Add Var.
9098
9099 2014-06-12 Jakub Jelinek <jakub@redhat.com>
9100
9101 PR middle-end/61486
9102 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
9103 #pragma omp target teams or
9104 #pragma omp {,target }teams distribute simd.
9105
9106 2014-06-12 Jason Merrill <jason@redhat.com>
9107
9108 * c.opt (Wabi=, fabi-compat-version): New.
9109 * c-opts.c (c_common_handle_option): Handle -Wabi=.
9110 (c_common_post_options): Handle flag_abi_compat_version default.
9111 Disallow -fabi-compat-version=1.
9112 * c-common.h (abi_version_crosses): New.
9113
9114 2014-06-11 Jan Hubicka <hubicka@ucw.cz>
9115
9116 * c-common.c (handle_section_attribute): Update handling for
9117 section names that are no longer trees.
9118
9119 2014-06-10 Jakub Jelinek <jakub@redhat.com>
9120
9121 PR fortran/60928
9122 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
9123 (omp_pragmas): ... back here.
9124
9125 2014-06-05 Marek Polacek <polacek@redhat.com>
9126
9127 PR c/49706
9128 * c-common.c (warn_logical_not_parentheses): New function.
9129 * c-common.h (warn_logical_not_parentheses): Declare.
9130 * c.opt (Wlogical-not-parentheses): New option.
9131
9132 2014-06-04 Marek Polacek <polacek@redhat.com>
9133
9134 PR c/30020
9135 * c-common.c (check_case_bounds): Add location parameter.
9136 Use it.
9137 (c_add_case_label): Pass loc to check_case_bounds.
9138
9139 2014-06-03 Marek Polacek <polacek@redhat.com>
9140
9141 PR c/60439
9142 * c.opt (Wswitch-bool): New option.
9143
9144 2014-05-22 Thomas Schwinge <thomas@codesourcery.com>
9145
9146 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
9147 Remove prototypes.
9148 (record_types_used_by_current_var_decl): Move prototype to where
9149 it belongs.
9150
9151 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
9152 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
9153 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
9154
9155 2014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
9156
9157 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
9158 * c-common.c (c_common_nodes_and_builtins): Don't initialize
9159 void_zero_node.
9160 * c-pretty-print.c (pp_c_void_constant): New function.
9161 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
9162 (c_pretty_printer::expression): Handle VOID_CST.
9163 * cilk.c (extract_free_variables): Likewise.
9164 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
9165 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
9166
9167 2014-05-17 Trevor Saunders <tsaunders@mozilla.com>
9168
9169 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
9170 * c-pragma.c (push_alignment): Adjust.
9171 (handle_pragma_push_options): Likewise.
9172
9173 2014-05-09 Marek Polacek <polacek@redhat.com>
9174
9175 PR c/50459
9176 * c-common.c (check_user_alignment): Return -1 if alignment is error
9177 node.
9178 (handle_aligned_attribute): Don't call default_conversion on
9179 FUNCTION_DECLs.
9180 (handle_vector_size_attribute): Likewise.
9181 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
9182 (handle_sentinel_attribute): Call default_conversion and allow even
9183 integral types as an argument.
9184
9185 2014-05-08 Marek Polacek <polacek@redhat.com>
9186
9187 PR c/61053
9188 * c-common.c (min_align_of_type): New function factored out from...
9189 (c_sizeof_or_alignof_type): ...here.
9190 * c-common.h (min_align_of_type): Declare.
9191
9192 2014-05-08 Marek Polacek <polacek@redhat.com>
9193
9194 PR c/61077
9195 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
9196 parameter type of main.
9197
9198 2014-05-07 DJ Delorie <dj@redhat.com>
9199
9200 * c-cppbuiltin.c (print_bits_of_hex): New.
9201 (builtin_define_type_minmax): Print values using hex so as not to
9202 require a pre-computed list of string values.
9203
9204 2014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
9205 Mike Stump <mikestump@comcast.net>
9206 Richard Sandiford <rdsandiford@googlemail.com>
9207
9208 * c-ada-spec.c: Include wide-int.h.
9209 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
9210 (dump_generic_ada_node): Use wide-int interfaces.
9211 * c-common.c: Include wide-int-print.h.
9212 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
9213 (pointer_int_sum): Use wide-int interfaces.
9214 (c_common_nodes_and_builtins): Use make_int_cst.
9215 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
9216 (handle_alloc_size_attribute): Use wide-int interfaces.
9217 (get_nonnull_operand): Likewise.
9218 * c-format.c (get_constant): Use tree_fits_uhwi_p.
9219 * c-lex.c: Include wide-int.h.
9220 (narrowest_unsigned_type): Take a widest_int rather than two
9221 HOST_WIDE_INTs.
9222 (narrowest_signed_type): Likewise.
9223 (interpret_integer): Update accordingly. Use wide-int interfaces.
9224 (lex_charconst): Use wide-int interfaces.
9225 * c-pretty-print.c: Include wide-int.h.
9226 (pp_c_integer_constant): Use wide-int interfaces.
9227 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
9228 INT_CST_LT_UNSIGNED.
9229
9230 2014-05-06 Richard Biener <rguenther@suse.de>
9231
9232 * c-opts.c (c_common_post_options): For -freestanding,
9233 -fno-hosted and -fno-builtin disable pattern recognition
9234 if not enabled explicitely.
9235
9236 2014-05-02 Marek Polacek <polacek@redhat.com>
9237
9238 * c.opt (Wsizeof-pointer-memaccess): Describe option.
9239
9240 2014-05-01 Marek Polacek <polacek@redhat.com>
9241
9242 PR c/43245
9243 * c.opt (Wdiscarded-qualifiers): Add.
9244
9245 2014-04-30 Marek Polacek <polacek@redhat.com>
9246
9247 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
9248 INT_MIN / -1 sanitization only for integer types.
9249
9250 2014-04-25 Marek Polacek <polacek@redhat.com>
9251
9252 PR c/18079
9253 * c-common.c (handle_noinline_attribute): Warn if the attribute
9254 conflicts with always_inline attribute.
9255 (handle_always_inline_attribute): Warn if the attribute conflicts
9256 with noinline attribute.
9257
9258 2014-04-25 Marek Polacek <polacek@redhat.com>
9259
9260 PR c/60156
9261 * c-common.c (check_main_parameter_types): Warn about variadic main.
9262
9263 2014-04-24 Mike Stump <mikestump@comcast.net>
9264
9265 * c.opt (Wshadow-ivar): Default to on.
9266
9267 2014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
9268
9269 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
9270
9271 2014-04-23 Marek Polacek <polacek@redhat.com>
9272
9273 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
9274
9275 2014-04-22 Jakub Jelinek <jakub@redhat.com>
9276
9277 PR sanitizer/60275
9278 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
9279 if flag_sanitize_undefined_trap_on_error.
9280 (ubsan_instrument_division, ubsan_instrument_shift,
9281 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
9282 if !flag_sanitize_recover.
9283
9284 2014-04-22 Marc Glisse <marc.glisse@inria.fr>
9285
9286 PR libstdc++/43622
9287 * c-common.c (registered_builtin_types): Make non-static.
9288 * c-common.h (registered_builtin_types): Declare.
9289
9290 2014-04-14 Richard Biener <rguenther@suse.de>
9291 Marc Glisse <marc.glisse@inria.fr>
9292
9293 PR c/60819
9294 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
9295 apply may-alias the scalar pointer type when applicable.
9296
9297 2014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
9298
9299 PR middle-end/60467
9300 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
9301 as possible argument for Cilk_spawn.
9302
9303 2014-04-11 Tobias Burnus <burnus@net-b.de>
9304
9305 PR c/60194
9306 * c.opt (Wformat-signedness): Add
9307 * c-format.c(check_format_types): Use it.
9308
9309 2014-04-11 Jason Merrill <jason@redhat.com>
9310
9311 PR c++/57926
9312 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
9313 default_conversion for an array argument.
9314
9315 2014-04-08 Marek Polacek <polacek@redhat.com>
9316
9317 PR sanitizer/60745
9318 * c-ubsan.c: Include asan.h.
9319 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
9320
9321 2014-04-03 Nathan Sidwell <nathan@codesourcery.com>
9322
9323 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
9324
9325 2014-04-02 Marek Polacek <polacek@redhat.com>
9326
9327 * c-common.h (c_expand_expr): Remove declaration.
9328
9329 2014-03-28 Jakub Jelinek <jakub@redhat.com>
9330
9331 PR c++/60689
9332 * c-common.c (add_atomic_size_parameter): When creating new
9333 params vector, push the size argument first.
9334
9335 2014-03-26 Jakub Jelinek <jakub@redhat.com>
9336
9337 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
9338 ubsan_instrument_vla, ubsan_instrument_return): Adjust
9339 ubsan_create_data callers.
9340
9341 2014-03-22 Jakub Jelinek <jakub@redhat.com>
9342
9343 PR debug/60603
9344 * c-opts.c (c_finish_options): Restore cb_file_change call to
9345 <built-in>.
9346
9347 2014-03-13 Jakub Jelinek <jakub@redhat.com>
9348
9349 PR middle-end/36282
9350 * c-pragma.c (apply_pragma_weak): Only look at
9351 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
9352 DECL_ASSEMBLER_NAME_SET_P (decl).
9353 (maybe_apply_pending_pragma_weaks): Exit early if
9354 vec_safe_is_empty (pending_weaks) rather than only when
9355 !pending_weaks.
9356 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
9357 set assembler name back to NULL afterwards.
9358
9359 2014-03-11 Jason Merrill <jason@redhat.com>
9360
9361 * c.opt: Add -std=gnu++14.
9362
9363 2014-03-11 Ian Bolton <ian.bolton@arm.com>
9364
9365 * c-opts.c (c_common_post_options): Don't override
9366 -ffp-contract=fast if unsafe-math-optimizations is on.
9367
9368 2014-03-08 Paulo Matos <paulo@matos-sorge.com>
9369
9370 * c.opt: Enable LTO FE for fshort-double.
9371
9372 2014-03-07 Jason Merrill <jason@redhat.com>
9373
9374 * c.opt: Add -std=c++14.
9375
9376 2014-03-06 Marek Polacek <polacek@redhat.com>
9377
9378 PR c/60197
9379 * cilk.c (contains_cilk_spawn_stmt): New function.
9380 (contains_cilk_spawn_stmt_walker): Likewise.
9381 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
9382 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
9383
9384 2014-03-03 Jakub Jelinek <jakub@redhat.com>
9385
9386 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
9387 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
9388 even when flag_preprocess_only.
9389
9390 2014-02-26 Jason Merrill <jason@redhat.com>
9391
9392 PR c++/59231
9393 PR c++/11586
9394 * c-common.c (shorten_compare): Don't check
9395 c_inhibit_evaluation_warnings.
9396
9397 2014-02-19 Jakub Jelinek <jakub@redhat.com>
9398
9399 PR c/37743
9400 * c-common.c (c_common_nodes_and_builtins): When initializing
9401 c_uint{16,32,64}_type_node, also set corresponding
9402 uint{16,32,64}_type_node to the same value.
9403
9404 PR c++/60267
9405 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
9406 for PRAGMA_IVDEP if flag_preprocess_only.
9407
9408 2014-02-12 Jakub Jelinek <jakub@redhat.com>
9409
9410 PR c/60101
9411 * c-common.c (merge_tlist): If copy is true, call new_tlist,
9412 if false, add ADD itself, rather than vice versa.
9413 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
9414 copy. For SAVE_EXPR, only call merge_tlist once.
9415
9416 2014-02-08 Jakub Jelinek <jakub@redhat.com>
9417
9418 PR middle-end/60092
9419 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
9420 and tree_to_uhwi.
9421 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
9422 functions.
9423 (c_common_attribute_table): Add alloc_align and assume_aligned
9424 attributes.
9425
9426 2014-02-06 Marek Polacek <polacek@redhat.com>
9427
9428 PR c/60087
9429 * c-common.c (warn_for_sign_compare): Call warning_at with location
9430 instead of warning.
9431
9432 2014-02-05 Marek Polacek <polacek@redhat.com>
9433
9434 PR c/53123
9435 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
9436 statement.
9437
9438 2014-02-04 Marek Polacek <polacek@redhat.com>
9439
9440 PR c/60036
9441 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
9442 SAVE_EXPR.
9443
9444 2014-02-03 Marc Glisse <marc.glisse@inria.fr>
9445
9446 PR c++/53017
9447 PR c++/59211
9448 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
9449 handle_vector_size_attribute, handle_nonnull_attribute): Call
9450 default_conversion on the attribute argument.
9451 (handle_nonnull_attribute): Increment the argument number.
9452
9453 2014-01-31 Marek Polacek <polacek@redhat.com>
9454
9455 PR c/59963
9456 * c-common.c (add_atomic_size_parameter): Pass vNULL to
9457 build_function_call_vec.
9458 (resolve_overloaded_builtin): Likewise.
9459 * c-common.h (build_function_call_vec): Adjust declaration.
9460
9461 2014-01-30 Marek Polacek <polacek@redhat.com>
9462
9463 PR c/59940
9464 * c-common.h (unsafe_conversion_p): Adjust declaration.
9465 (warnings_for_convert_and_check): Likewise.
9466 (convert_and_check): Likewise.
9467 * c-common.c (unsafe_conversion_p): Add location parameter. Call
9468 expansion_point_location_if_in_system_header on it.
9469 (warnings_for_convert_and_check): Add location parameter. Call
9470 expansion_point_location_if_in_system_header on it. Use it.
9471 (convert_and_check): Add location parameter. Use it.
9472 (conversion_warning): Likewise.
9473 (c_add_case_label): Adjust convert_and_check calls.
9474 (scalar_to_vector): Adjust unsafe_conversion_p calls.
9475
9476 2014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
9477
9478 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
9479 flag_cilkplus.
9480 * c-pragma.c (init_pragma): Likewise.
9481 * c.opt: Likewise.
9482
9483 2014-01-23 Marek Polacek <polacek@redhat.com>
9484
9485 PR c/59846
9486 * c-common.c (shorten_compare): Add location_t parameter.
9487 * c-common.h (shorten_binary_op): Adjust declaration.
9488
9489 2014-01-23 Marek Polacek <polacek@redhat.com>
9490
9491 PR c/58346
9492 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
9493 * c-common.h: Declare it.
9494
9495 2014-01-20 Eric Botcazou <ebotcazou@adacore.com>
9496
9497 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
9498 * c-ada-spec.c (dump_ads): Likewise.
9499 (cpp_check): Likewise.
9500 (dump_ada_specs): Likewise.
9501
9502 2014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
9503
9504 PR c++/49718
9505 * c-common.c (handle_no_instrument_function_attribute): Allow
9506 no_instrument_function attribute in class member
9507 definition/declaration.
9508
9509 2014-01-15 Jakub Jelinek <jakub@redhat.com>
9510
9511 PR c/58943
9512 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
9513 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
9514 being COMPOUND_EXPR.
9515 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
9516 operand a SAVE_EXPR and second MODIFY_EXPR.
9517
9518 2014-01-09 Jakub Jelinek <jakub@redhat.com>
9519
9520 PR target/58115
9521 * c-pch.c (c_common_write_pch): Call
9522 prepare_target_option_nodes_for_pch.
9523
9524 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
9525
9526 Update copyright years
9527
9528 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
9529
9530 * array-notation-common.c, c-cilkplus.c: Use the standard form for
9531 the copyright notice.
9532
9533 2013-12-28 Eric Botcazou <ebotcazou@adacore.com>
9534
9535 * c-ada-spec.c (print_constructor): New function.
9536 (print_destructor): Retrieve the origin of the destructor.
9537 (print_ada_declaration): Revamp handling of constructors/destructors.
9538
9539 2013-12-23 Stuart Hastings <stuart@apple.com>
9540 Bill Maddox <maddox@google.com>
9541 Jason Merrill <jason@redhat.com>
9542
9543 * c.opt: Add -fdeclone-ctor-dtor.
9544 * c-opts.c (c_common_post_options): Default to on iff -Os.
9545
9546 2013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
9547
9548 * c-common.c (c_common_attribute_table): Added "cilk simd function"
9549 attribute.
9550 * c-pragma.h (enum pragma_cilk_clause): Remove.
9551 (enum pragma_omp_clause): Added the following fields:
9552 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
9553 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
9554 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
9555 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
9556 PRAGMA_CILK_CLAUSE_UNIFORM.
9557
9558
9559 2013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
9560
9561 * cilk.c (cilk_outline): Made this function non-static.
9562 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
9563 (create_cilk_wrapper): Added a new parameter: a function pointer.
9564 (c_install_body_w_frame_cleanup): Remove
9565 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
9566 * c-common.h (cilk_outline): New prototype.
9567 (gimplify_cilk_spawn): Removed two parameters.
9568 (cilk_install_body_with_frame_cleanup): New prototype.
9569 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
9570 CILK_SPAWN_STMT case.
9571
9572 2013-12-11 Bernd Schmidt <bernds@codesourcery.com>
9573
9574 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
9575
9576 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
9577 (int_array_type_node): Remove.
9578 * c-common.c (c_common_nodes_and_builtins): Don't build it.
9579
9580 2013-12-05 Marek Polacek <polacek@redhat.com>
9581
9582 PR c/52023
9583 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
9584 [ADJUST_FIELD_ALIGN].
9585
9586 2013-12-04 Joseph Myers <joseph@codesourcery.com>
9587
9588 PR c/52023
9589 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
9590 and check field alignment if set.
9591 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
9592 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
9593
9594 2013-12-04 Jakub Jelinek <jakub@redhat.com>
9595 Marek Polacek <polacek@redhat.com>
9596
9597 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
9598 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
9599
9600 2013-11-29 H.J. Lu <hongjiu.lu@intel.com>
9601
9602 PR c/59309
9603 * cilk.c (gimplify_cilk_spawn): Properly handle function without
9604 arguments.
9605
9606 2013-11-29 Jakub Jelinek <jakub@redhat.com>
9607
9608 PR c/59280
9609 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
9610 goto invalid. If it is error_mark_node, don't issue further
9611 diagnostics.
9612
9613 2013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
9614
9615 * c.opt (Wopenmp-simd): New.
9616
9617 2013-11-22 Jakub Jelinek <jakub@redhat.com>
9618
9619 * c-ubsan.h (ubsan_instrument_return): New prototype.
9620 * c-ubsan.c (ubsan_instrument_return): New function.
9621
9622 2013-11-22 Andrew MacLeod <amacleod@redhat.com>
9623
9624 * c-common.c: Add required include files from gimple.h.
9625 * c-gimplify.c: Likewise.
9626 * cilk.c: Likewise.
9627
9628 2013-11-22 David Malcolm <dmalcolm@redhat.com>
9629
9630 * c-common.c (unsafe_conversion_p): Remove use of
9631 EXPR_LOC_OR_HERE macro.
9632 (conversion_warning): Likewise.
9633 (warnings_for_convert_and_check): Likewise.
9634 (warn_for_collisions_1): Likewise.
9635 (shorten_compare): Likewise, and remove use of in_system_header
9636 macro, using the location from the former.
9637 * c-lex.c (dump_one_header): Remove use of input_filename macro.
9638 (cb_def_pragma): Remove use of in_system_header macro.
9639 (lex_string): Likewise.
9640 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
9641
9642 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
9643 Mike Stump <mikestump@comcast.net>
9644 Richard Sandiford <rdsandiford@googlemail.com>
9645
9646 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
9647 instead of TREE_INT_CST_LOW, in cases where there is a protecting
9648 tree_fits_shwi_p or tree_fits_uhwi_p.
9649 (dump_generic_ada_node): Likewise.
9650 * c-format.c (check_format_arg): Likewise.
9651 * c-pretty-print.c (pp_c_integer_constant): Likewise.
9652
9653 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
9654
9655 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
9656
9657 2013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
9658
9659 PR c/53001
9660 * c-common.c (unsafe_conversion_p): Make this function
9661 return an enumeration with more detail.
9662 (conversion_warning): Use the new return type of
9663 unsafe_conversion_p to separately warn either about conversions
9664 that lower floating point number precision or about the other
9665 kinds of conversions.
9666 * c-common.h (enum conversion_safety): New enumeration.
9667 (unsafe_conversion_p): switching return type to
9668 conversion_safety enumeration.
9669 * c.opt: Adding new warning -Wfloat-conversion and
9670 enabling it with -Wconversion.
9671
9672 2013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
9673
9674 * c-opts.c: Include plugin.h.
9675 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
9676
9677 2013-11-19 Marek Polacek <polacek@redhat.com>
9678
9679 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
9680 call.
9681 (ubsan_instrument_shift): Likewise.
9682 (ubsan_instrument_vla): Likewise.
9683
9684 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9685
9686 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
9687 cast to unsigned type.
9688
9689 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9690
9691 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
9692 tree_low_cst.
9693 (complete_array_type): Update comment to refer to tree_to_[su]hwi
9694 rather than tree_low_cst.
9695
9696 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9697
9698 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
9699 tree_to_uhwi throughout.
9700
9701 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9702
9703 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
9704 tree_low_cst (..., 0) with tree_to_shwi throughout.
9705
9706 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9707
9708 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
9709 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
9710
9711 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
9712
9713 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
9714 host_integerp (..., 0) with tree_fits_shwi_p throughout.
9715
9716 2013-11-15 Aldy Hernandez <aldyh@redhat.com>
9717
9718 * c-cilkplus.c: New file.
9719 * c-common.c (readonly_error): Add location argument.
9720 * c-common.h (readonly_error): Same.
9721 (c_finish_cilk_clauses): Protoize.
9722 (c_check_cilk_loop): Same.
9723 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
9724 Do not fail on error_mark_node.
9725 Abstract increment canonicalization to here...
9726 (c_omp_for_incr_canonicalize_ptr): New.
9727 c-pragma.c (init_pragma): Register "simd" pragma.
9728 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
9729 (enum pragma_cilk_clause): New.
9730
9731 2013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
9732
9733 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
9734 wchar_type and host_integerp checks.
9735
9736 2013-11-14 Andrew MacLeod <amacleod@redhat.com>
9737
9738 * c-common.c: Likewise.
9739 * c-gimplify.c: Likewise.
9740 * cilk.c: Likewise.
9741
9742 2013-11-14 Diego Novillo <dnovillo@google.com>
9743
9744 * c-common.c: Include fold-const.h.
9745 Include stor-layout.h.
9746 Include calls.h.
9747 Include stringpool.h.
9748 Include attribs.h.
9749 Include varasm.h.
9750 Include trans-mem.h.
9751 * c-cppbuiltin.c: Include stor-layout.h.
9752 Include stringpool.h.
9753 * c-format.c: Include stringpool.h.
9754 * c-lex.c: Include stringpool.h.
9755 Include stor-layout.h.
9756 * c-pragma.c: Include stringpool.h.
9757 Include attribs.h.
9758 Include varasm.h.
9759 Include gcc-symtab.h.
9760 * c-pretty-print.c: Include stor-layout.h.
9761 Include attribs.h.
9762 * cilk.c: Include stringpool.h.
9763 Include calls.h.
9764
9765 2013-11-13 Joseph Myers <joseph@codesourcery.com>
9766
9767 * c-common.h (enum rid): Add RID_AUTO_TYPE.
9768 * c-common.c (c_common_reswords): Add __auto_type.
9769 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
9770
9771 2013-11-12 Andrew MacLeod <amacleod@redhat.com>
9772
9773 * c-common.c: Include gimplify.h.
9774 * c-gimplify.c: Likewise.
9775 * cilk.c: Likewise.
9776 * c-omp.c: Include gimple-expr.h instead of gimple.h.
9777 * c-ubsan.c: Don't include gimple.h.
9778
9779 2013-11-12 Joseph Myers <joseph@codesourcery.com>
9780
9781 * c-common.c (c_common_reswords): Add _Thread_local.
9782
9783 2013-11-09 Joseph Myers <joseph@codesourcery.com>
9784
9785 * c-common.c (atomic_size_supported_p): New function.
9786 (resolve_overloaded_atomic_exchange)
9787 (resolve_overloaded_atomic_compare_exchange)
9788 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
9789 Use it instead of comparing size with a local list of sizes.
9790
9791 2013-11-07 Andrew MacLeod <amacleod@redhat.com>
9792 Joseph Myers <joseph@codesourcery.com>
9793
9794 * c-common.h (enum rid): Add RID_ATOMIC.
9795 * c-common.c (c_common_reswords): Add _Atomic.
9796 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
9797 (keyword_is_type_qualifier): Accept RID_ATOMIC.
9798 * c-format.c (check_format_types): Check for extra _Atomic
9799 qualifiers in format argument.
9800 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
9801 (pp_c_type_qualifier_list): Mention _Atomic in comment.
9802
9803 2013-11-06 Tobias Burnus <burnus@net-b.de>
9804
9805 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
9806
9807 2013-11-06 Joseph Myers <joseph@codesourcery.com>
9808
9809 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
9810 standards modes.
9811 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
9812 to mean lack of IEEE 754 support.
9813
9814 2013-11-05 Tobias Burnus <burnus@net-b.de>
9815
9816 * c.opt (-Wdate-time): New option
9817 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
9818
9819 2013-11-05 Joseph Myers <joseph@codesourcery.com>
9820
9821 * c-cppbuiltin.c (cpp_iec_559_value): Test
9822 flag_excess_precision_cmdline not flag_excess_precision.
9823
9824 2013-11-05 Tobias Burnus <burnus@net-b.de>
9825
9826 * c.opt (fopenmp-simd): New option.
9827 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
9828 (omp_pragmas): ... this new struct.
9829 (c_pp_lookup_pragma): Also walk omp_pragmas.
9830 (init_pragma): Init pragmas for -fopenmp-simd.
9831
9832 2013-11-04 Marek Polacek <polacek@redhat.com>
9833
9834 PR c++/58979
9835 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
9836
9837 2013-11-04 Joseph Myers <joseph@codesourcery.com>
9838
9839 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
9840 New functions.
9841 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
9842
9843 2013-11-04 Eric Botcazou <ebotcazou@adacore.com>
9844
9845 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
9846 (dump_ada_specs): Adjust prototype of second callback.
9847 * c-ada-spec.c (cpp_check): New global variable.
9848 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
9849 (print_generic_ada_decl): Likewise.
9850 (has_static_fields): Change return type to bool and add guard.
9851 (has_nontrivial_methods): New predicate.
9852 (is_tagged_type): Change return type to bool.
9853 (separate_class_package): Call has_nontrivial_methods.
9854 (pp_ada_tree_identifier): Minor tweaks.
9855 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
9856 (dump_ada_array_domains): Likewise.
9857 (dump_ada_array_type): Likewise.
9858 (dump_template_types): Remove cpp_check parameter and do not pass it to
9859 dump_generic_ada_node.
9860 (dump_ada_template): Likewise.
9861 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
9862 recursively.
9863 (print_ada_methods): Change return type to integer. Remove cpp_check
9864 parameter and do not pass it down.
9865 (dump_nested_types): Remove cpp_check parameter and do not pass it to
9866 dump_generic_ada_node.
9867 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
9868 accessing methods.
9869 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
9870 down. Use has_nontrivial_methods to recognize C++ classes. Use return
9871 value of print_ada_methods.
9872 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
9873 Set cpp_check to it before invoking dump_ada_nodes.
9874 (dump_ada_specs): Likewise.
9875
9876 2013-11-03 Marek Polacek <polacek@redhat.com>
9877
9878 * c-ubsan.c: Don't include hash-table.h.
9879 (ubsan_instrument_vla): New function.
9880 * c-ubsan.h: Declare it.
9881
9882 2013-10-31 David Malcolm <dmalcolm@redhat.com>
9883
9884 Automated part of renaming of symtab_node_base to symtab_node.
9885
9886 Patch autogenerated by rename_symtab.py from
9887 https://github.com/davidmalcolm/gcc-refactoring-scripts
9888 revision 58bb219cc090b2f4516a9297d868c245495ee622
9889
9890 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
9891 symtab_node_base to symtab_node.
9892
9893 2013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
9894
9895 Implement C++14 digit separators.
9896 * c-lex.c (interpret_float): Remove digit separators from scratch string
9897 before building real literal.
9898
9899 2013-10-30 Jakub Jelinek <jakub@redhat.com>
9900
9901 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
9902
9903 2013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
9904
9905 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
9906 fields.
9907 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
9908 enabled.
9909 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
9910 (insert_cilk_frame): New prototype.
9911 (cilk_init_builtins): Likewise.
9912 (gimplify_cilk_spawn): Likewise.
9913 (c_cilk_install_body_w_frame_cleanup): Likewise.
9914 (cilk_detect_spawn_and_unwrap): Likewise.
9915 (cilk_set_spawn_marker): Likewise.
9916 (build_cilk_sync): Likewise.
9917 (build_cilk_spawn): Likewise.
9918 * cilk.c: New file.
9919
9920 2013-10-29 David Malcolm <dmalcolm@redhat.com>
9921
9922 Patch autogenerated by refactor_symtab.py from
9923 https://github.com/davidmalcolm/gcc-refactoring-scripts
9924 revision 58bb219cc090b2f4516a9297d868c245495ee622
9925
9926 * c-gimplify.c (c_genericize): Update for conversion of symtab types
9927 to a true class hierarchy.
9928 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
9929
9930 2013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
9931
9932 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
9933
9934 2013-10-26 Jeff Law <law@redhat.com>
9935
9936 * c-common.c (c_define_builtins): Remove mudflap support.
9937 * c.opt: Ignore and warn for mudflap options.
9938
9939 2013-10-24 Tobias Burnus <burnus@net-b.de>
9940
9941 PR other/33426
9942 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
9943 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
9944
9945 2013-10-23 Jason Merrill <jason@redhat.com>
9946
9947 * c-format.c (gcc_cxxdiag_char_table): Add %X.
9948
9949 2013-10-11 Jakub Jelinek <jakub@redhat.com>
9950
9951 * c-common.h (omp_clause_mask::operator !=): New method.
9952 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
9953 instead of if (mask & something) tests everywhere.
9954
9955 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
9956 201307 instead of 201107.
9957 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
9958 (c_common_attribute_table): Add "omp declare target" and
9959 "omp declare simd" attributes.
9960 (handle_omp_declare_target_attribute,
9961 handle_omp_declare_simd_attribute): New functions.
9962 * c-omp.c: Include c-pragma.h.
9963 (c_finish_omp_taskgroup): New function.
9964 (c_finish_omp_atomic): Add swapped argument, if true,
9965 build the operation first with rhs, lhs arguments and use NOP_EXPR
9966 build_modify_expr.
9967 (c_finish_omp_for): Add code argument, pass it down to make_code.
9968 (c_omp_split_clauses): New function.
9969 (c_split_parallel_clauses): Removed.
9970 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
9971 c_omp_declare_simd_clauses_to_decls): New functions.
9972 * c-common.h (omp_clause_mask): New type.
9973 (OMP_CLAUSE_MASK_1): Define.
9974 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
9975 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
9976 omp_clause_mask::operator |, omp_clause_mask::operator &,
9977 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
9978 omp_clause_mask::operator ==): New methods.
9979 (enum c_omp_clause_split): New.
9980 (c_finish_omp_taskgroup): New prototype.
9981 (c_finish_omp_atomic): Add swapped argument.
9982 (c_finish_omp_for): Add code argument.
9983 (c_omp_split_clauses): New prototype.
9984 (c_split_parallel_clauses): Removed.
9985 (c_omp_declare_simd_clauses_to_numbers,
9986 c_omp_declare_simd_clauses_to_decls): New prototypes.
9987 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
9988 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
9989 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
9990 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
9991 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
9992 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
9993 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
9994 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
9995 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
9996 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
9997 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
9998 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
9999 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
10000 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
10001 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
10002 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
10003 PRAGMA_OMP_CLAUSE_UNIFORM.
10004
10005 2013-10-09 Marc Glisse <marc.glisse@inria.fr>
10006
10007 PR tree-optimization/20318
10008 * c-common.c (handle_returns_nonnull_attribute): New function.
10009 (c_common_attribute_table): Add returns_nonnull.
10010
10011 2013-10-03 Marc Glisse <marc.glisse@inria.fr>
10012
10013 PR c++/19476
10014 * c.opt (fcheck-new): Move to common.opt.
10015
10016 2013-09-25 Marek Polacek <polacek@redhat.com>
10017 Jakub Jelinek <jakub@redhat.com>
10018
10019 PR sanitizer/58413
10020 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
10021 an expression if we can prove it is correct.
10022 (ubsan_instrument_division): Likewise. Remove unnecessary
10023 check.
10024
10025 2013-09-18 Marek Polacek <polacek@redhat.com>
10026
10027 PR sanitizer/58411
10028 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
10029 Declare it.
10030 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
10031
10032 2013-09-14 Iain Sandoe <iain@codesourcery.com>
10033
10034 PR target/48094
10035 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
10036 fobjc-gc, freplace-objc-classes): Accept for LTO.
10037
10038 2013-09-13 Jacek Caban <jacek@codeweavers.com>
10039
10040 * c-target.def: New hook
10041
10042 2013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
10043
10044 PR c++/43452
10045 * c.opt (Wdelete-incomplete): Add.
10046
10047 2013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
10048
10049 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
10050 (vector_types_compatible_elements_p): New function.
10051 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
10052 declaration.
10053 (vector_types_compatible_elements_p): Declare.
10054
10055 2013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
10056
10057 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
10058 a virtual member function.
10059 (pp_simple_type_specifier): Remove.
10060 (pp_c_type_specifier): Likewise.
10061 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
10062 Rename from pp_c_type_specifier. Adjust.
10063 (c_pretty_printer::c_pretty_printer): Do not assign to
10064 simple_type_specifier.
10065
10066 2013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
10067
10068 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
10069 member function.
10070 (c_pretty_printer::storage_class_specifier): Likewise.
10071 (c_pretty_printer::initializer): Likewise.
10072 (pp_declaration): Remove.
10073 (pp_declaration_specifiers): Likewise.
10074 (pp_abstract_declarator): Likewise.
10075 (pp_declarator): Likewise.
10076 (pp_type_id): Likewise.
10077 (pp_statement): Likewise.
10078 (pp_constant): Likewise.
10079 (pp_id_expression): Likewise.
10080 (pp_primary_expression): Likewise.
10081 (pp_unary_expression): Likewise.
10082 (pp_multiplicative_expression): Likewise.
10083 (pp_conditional_expression): Likewise.
10084 (pp_assignment_expression): Likewise.
10085 (pp_expression): Likewise.
10086 (pp_c_type_id): Likewise.
10087 (pp_c_storage_class_specifier): Likewise.
10088 * c-pretty-print.c (pp_c_type_cast): Tidy.
10089 (pp_c_pointer): Likewise.
10090 (pp_c_type_specifier): Likewise.
10091 (pp_c_parameter_type_list): Likewise.
10092 (pp_c_function_definition): Likewise.
10093 (pp_c_init_declarator): Likewise.
10094 (pp_c_initializer_list): Likewise.
10095 (pp_c_constructor_elts): Likewise.
10096 (c_pretty_printer::direct_abstract_declarator): Likewise.
10097 (c_pretty_printer::declaration_specifiers): Likewise.
10098 (c_pretty_printer::primary_expression): Likewise.
10099 (c_pretty_printer::postfix_expression): Likewise.
10100 (c_pretty_printer::type_id): Rename from pp_c_type_id.
10101 (c_pretty_printer::storage_class_specifier): Rename from
10102 pp_c_storage_class_specifier.
10103 (c_pretty_printer::initializer): Rename from pp_c_initializer.
10104 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
10105 storage_class_specifier, initializer, offset_list, flags.
10106
10107 2013-08-30 Marek Polacek <polacek@redhat.com>
10108
10109 * c-ubsan.c: New file.
10110 * c-ubsan.h: New file.
10111
10112 2013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
10113
10114 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
10115 member function.
10116 (c_pretty_printer::declaration_specifiers): Likewise.
10117 (c_pretty_printer::declarator): Likewise.
10118 (c_pretty_printer::abstract_declarator): Likewise.
10119 (c_pretty_printer::direct_abstract_declarator): Likewise.
10120 (c_pretty_printer::direct_declarator): Likewise.
10121 (c_pretty_printer::function_specifier): Likewise.
10122 (pp_declaration): Adjust.
10123 (pp_declaration_specifiers): Likewise.
10124 (pp_abstract_declarator): Likewise.
10125 (pp_direct_declarator): Likewise.
10126 (pp_function_specifier): Likewise.
10127 (pp_direct_abstract_declarator): Remove as unused.
10128 (pp_c_declaration): Remove.
10129 (pp_c_declaration_specifiers): Likewise.
10130 (pp_c_declarator): Likewise.
10131 (pp_c_direct_declarator): Likewise.
10132 (pp_c_function_specifier): Likewise.
10133 (pp_c_direct_abstract_declarator): Likewise.
10134 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
10135 from pp_c_abstract_declarator. Adjust.
10136 (c_pretty_printer::direct_abstract_declarator): Rename from
10137 pp_c_direct_abstract_declarator. Adjust.
10138 (c_pretty_printer::function_specifier): Rename from
10139 pp_c_function_specifier. Adjust.
10140 (c_pretty_printer::declaration_specifiers): Rename from
10141 pp_c_declaration_specifiers. Adjust.
10142 (c_pretty_printer::direct_declarator): Rename from
10143 pp_c_direct_declarator. Adjust.
10144 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
10145 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
10146 (c_pretty_printer::c_pretty_printer): Do not assign to
10147 declaration, declaration_specifiers, declarator,
10148 direct_declarator, direct_abstract_declarator, function_specifier.
10149
10150 2013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
10151
10152 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
10153 virtual member function.
10154 (c_pretty_printer::multiplicative_expression): Likewise.
10155 (c_pretty_printer::conditional_expression): Likewise.
10156 (c_pretty_printer::assignment_expression): Likewise.
10157 (c_pretty_printer::expression): Likewise.
10158 (pp_unary_expression): Adjust.
10159 (pp_multiplicative_expression): Likewise.
10160 (pp_assignment_expression): Likewise.
10161 (pp_conditional_expression): Likewise.
10162 (pp_expression): Likewise.
10163 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
10164 from pp_c_unary_expression. Adjust.
10165 (c_pretty_printer::multiplicative_expression): Rename from
10166 pp_c_multiplicative_expression. Adjust.
10167 (c_pretty_printer::conditional_expression): Rename from
10168 pp_c_conditional_expression. Adjust.
10169 (c_pretty_printer::assignment_expression): Rename from
10170 pp_c_assignment_expression. Adjust.
10171 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
10172 (c_pretty_printer::c_pretty_printer): Do not assign to
10173 unary_expression, multiplicative_expression,
10174 conditional_expression, expression.
10175
10176 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
10177
10178 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
10179 virtual member function.
10180 (pp_postfix_expression): Adjust.
10181 (pp_c_postfix_expression): Remove.
10182 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
10183 from pp_c_postfix_expression. Adjust.
10184 (c_pretty_printer::c_pretty_printer): Do not assign to
10185 postfix_expression.
10186
10187 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
10188
10189 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
10190 virtua member function.
10191 (pp_primary_expression): Adjust.
10192 (pp_c_primary_expression): Remove.
10193 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
10194 from pp_c_primary_expression. Adjust.
10195 (pp_c_initializer_list): Use pp_primary_expression.
10196 (c_pretty_printer::c_pretty_printer): Do not assign to
10197 primary_expression.
10198
10199 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
10200
10201 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
10202 * c-pretty-print.c (M_): Remove.
10203 (c_pretty_printer::translate_string): Define.
10204 (pp_c_type_specifier): Use it.
10205 (pp_c_primary_expression): Likewise.
10206 (pp_c_expression): Likewise.
10207
10208 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
10209
10210 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
10211 virtual function.
10212 (pp_c_id_expression): Remove.
10213 (pp_id_expression): Adjust.
10214 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
10215 pp_c_id_expression. Adjust.
10216 (pp_c_postfix_expression): Use pp_id_expression.
10217 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
10218
10219 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
10220
10221 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
10222 member function.
10223 (pp_constant): Adjust.
10224 (pp_c_constant): Remove.
10225 * c-pretty-print.c (c_pretty_printer::constant): Rename from
10226 pp_c_constant. Adjust.
10227 (pp_c_constant)
10228 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
10229 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
10230
10231 2013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
10232
10233 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
10234 (c_pretty_printer::c_pretty_printer): Declare.
10235 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
10236 c_pretty_printer_init. Adjust.
10237 (print_c_tree): Do not call c_pretty_printer_init.
10238 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
10239
10240 2013-08-09 Arnaud Charlet <charlet@adacore.com>
10241
10242 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
10243
10244 2013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
10245
10246 PR c++/58080
10247 * c-common.c (pointer_int_sum): Add bool parameter.
10248 * c-common.h (pointer_int_sum): Adjust declaration.
10249
10250 2013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
10251
10252 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
10253 c_pretty_printer variable.
10254
10255 2013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
10256
10257 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
10258 (pp_base): Remove.
10259 (pp_c_base): Likewise. Adjust users.
10260 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
10261 (pp_c_whitespace): Do not call pp_base.
10262 (pp_c_left_paren): Likewise.
10263 (pp_c_right_paren): Likewise.
10264 (pp_c_left_brace): Likewise.
10265 (pp_c_right_brace): Likewise.
10266 (pp_c_left_bracket): Likewise.
10267 (pp_c_right_bracket): Likewise.
10268 (pp_c_dot): Likewise.
10269 (pp_c_ampersand): Likewise.
10270 (pp_c_star): Likewise.
10271 (pp_c_arrow): Likewise.
10272 (pp_c_semicolon): Likewise.
10273 (pp_c_complement): Likewise.
10274 (pp_c_exclamation): Likewise.
10275 (pp_c_direct_declarator): Likewise.
10276 (pp_c_ws_string): Likewise.
10277 (pp_c_identifier): Likewise.
10278 (pp_c_statement): Likewise.
10279 (print_c_tree): Likewise.
10280
10281 2013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
10282
10283 PR c++/58072
10284 * c-common.c (c_parse_error): Catch user-defined literal tokens and
10285 provide useful error strings.
10286
10287 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
10288
10289 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
10290 printer functions instead of pp_string or operators and punctuators.
10291 (dump_generic_ada_node): Likewise.
10292 * c-pretty-print.c (pp_c_type_specifier): Likewise.
10293 (pp_c_relational_expression): Likewise.
10294 (pp_c_logical_or_expression): Likewise.
10295
10296 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
10297
10298 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
10299 functions instead of pp_character.
10300 (pp_ada_tree_identifier): Likewise.
10301 (dump_ada_double_name): Likewise.
10302 (dump_ada_function_declaration): Likewise.
10303 (dump_ada_array_domains): Likewise.
10304 (dump_template_types): Likewise.
10305 (dump_generic_ada_node): Likewise.
10306 (print_ada_declaration): Likewise.
10307 (print_ada_struct_decl): Likewise.
10308 * c-pretty-print.c (pp_c_integer_constant): Likewise.
10309
10310 2013-07-23 Tom Tromey <tromey@redhat.com>
10311
10312 * c-common.h (enum rid) <RID_GENERIC>: New constant.
10313 * c-common.c (c_common_reswords): Add _Generic.
10314
10315 2013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
10316
10317 * c-common.c: Fix typos.
10318 * c-common.h: Likewise.
10319
10320 2013-07-13 Lubos Lunak <l.lunak@suse.cz>
10321
10322 PR c++/55203
10323 * c-common.c (c_common_attribute_table): Add warn_unused.
10324 (handle_warn_unused_attribute): New.
10325
10326 2013-07-10 Jakub Jelinek <jakub@redhat.com>
10327
10328 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
10329 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
10330
10331 2013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
10332
10333 PR c++/57869
10334 * c.opt: Add Wconditionally-supported.
10335
10336 2013-07-08 Graham Stott <graham.stott@btinternet.com>
10337
10338 * array-notation-common.c (length_mismatch_in_expr_p): Delete
10339 unused variables l_length and l_node.
10340
10341 2013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
10342
10343 PR c/57821
10344 * c-common.c (complete_array_type): Delay folding first index
10345 like other indices. When folding, check for index overflow.
10346
10347 2013-06-27 Marc Glisse <marc.glisse@inria.fr>
10348
10349 PR c++/57509
10350 * c-common.h (c_build_vec_perm_expr): New complain argument.
10351 * c-common.c (c_build_vec_perm_expr): Likewise.
10352 Use save_expr also in C++.
10353
10354 2013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
10355
10356 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
10357 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
10358 * c-opts.c (c_common_post_options): Likewise.
10359
10360 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
10361
10362 * array-notation-common.c (length_mismatch_in_expr): Changed the
10363 parameter type's from a dynamic array to a vec_tree. Also removed
10364 the size parameters.
10365 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
10366 the change above.
10367
10368 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
10369
10370 * c-common.h (struct cilkplus_an_parts): New structure.
10371 (struct cilkplus_an_loop_parts): Likewise.
10372 (cilkplus_extract_an_triplets): New prototype.
10373 (fix_sec_implicit_args): Likewise.
10374 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
10375 (fix_sec_implicit_args): Likewise.
10376
10377 2013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
10378
10379 * array-notation-common.c (find_inv_trees): Removed an unwanted
10380 typecasting.
10381 * c-common.h (struct inv_list::additional_tcodes): Changed type from
10382 enum rid to enum tree_code.
10383
10384 2013-06-11 Jan Hubicka <jh@suse.cz>
10385
10386 * c-common.c (handle_alias_ifunc_attribute): Do not set
10387 DECL_EXTERNAL for weakref variables.
10388 * c-pragma.c (handle_pragma_weak): Make sure aliases
10389 are not declared as external.
10390
10391 2013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
10392
10393 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
10394 function from c/c-array-notation.c.
10395 (is_cilkplus_reduce_builtin): Likewise.
10396 (find_rank): Likewise.
10397 (extract_array_notation_exprs): Likewise.
10398 (replace_array_notations): Likewise.
10399 (find_inv_trees): Likewise.
10400 (replace_inv_trees): Likewise.
10401 (contains_array_notation_expr): Likewise.
10402 (find_correct_array_notation_type): Likewise.
10403 * c-common.h (struct inv_list): Moved this struct from the file
10404 c/c-array-notation.c and added a new field called additional tcodes.
10405 (length_mismatch_in_expr_p): New prototype.
10406 (is_cilkplus_reduce_builtin): Likewise.
10407 (find_rank): Likewise.
10408 (extract_array_notation_exprs): Likewise.
10409 (replace_array_notation): Likewise.
10410 (find_inv_trees): Likewise.
10411 (replace_inv_trees): Likewise.
10412 (find_correct_array_notation_type): Likewise.
10413
10414 2013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
10415
10416 * c-common.c (c_define_builtins): When cilkplus is enabled, the
10417 function array_notation_init_builtins is called.
10418 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
10419 * c-common.def (ARRAY_NOTATION_REF): New tree.
10420 * c-common.h (build_array_notation_expr): New function declaration.
10421 (build_array_notation_ref): Likewise.
10422 (extract_sec_implicit_index_arg): New extern declaration.
10423 (is_sec_implicit_index_fn): Likewise.
10424 (ARRAY_NOTATION_CHECK): New define.
10425 (ARRAY_NOTATION_ARRAY): Likewise.
10426 (ARRAY_NOTATION_START): Likewise.
10427 (ARRAY_NOTATION_LENGTH): Likewise.
10428 (ARRAY_NOTATION_STRIDE): Likewise.
10429 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
10430 ARRAY_NOTATION_REF.
10431 (pp_c_expression): Likewise.
10432 * c.opt (flag_enable_cilkplus): New flag.
10433 * array-notation-common.c: New file.
10434
10435 2013-05-14 Jakub Jelinek <jakub@redhat.com>
10436
10437 PR c++/57274
10438 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
10439
10440 2013-05-10 Marc Glisse <marc.glisse@inria.fr>
10441
10442 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
10443 vectors.
10444
10445 2013-05-07 Han Shen <shenhan@google.com>
10446
10447 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
10448
10449 2013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
10450
10451 * c-common.c (check_user_alignment): Emit error for negative values.
10452
10453 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
10454
10455 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
10456
10457 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
10458
10459 * c-cppbuiltin.c (c_cpp_builtins): Do not define
10460 __GXX_EXPERIMENTAL_CXX1Y__.
10461
10462 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
10463 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
10464
10465 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
10466 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
10467 to simply use OPT_Wpointer_arith.
10468 (c_sizeof_or_alignof_type): Likewise.
10469
10470 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
10471
10472 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
10473
10474 2013-04-12 Jakub Jelinek <jakub@redhat.com>
10475
10476 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
10477 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
10478 specifiers.
10479
10480 2013-04-07 Steven Bosscher <steven@gcc.gnu.org>
10481
10482 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
10483
10484 2013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
10485
10486 * c-common.c (pointer_int_sum): Remove dead code.
10487
10488 2013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
10489
10490 PR middle-end/56524
10491 * c-common.c (handle_optimize_attribute): Don't call
10492 save_optabs_if_changed.
10493
10494 2013-03-05 Jakub Jelinek <jakub@redhat.com>
10495
10496 PR middle-end/56461
10497 * c-pch.c (pch_init): Free target_validity at the end.
10498
10499 2013-03-04 Jakub Jelinek <jakub@redhat.com>
10500
10501 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
10502
10503 2013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
10504 Jakub Jelinek <jakub@redhat.com>
10505
10506 PR sanitizer/56454
10507 * c-common.c (handle_no_sanitize_address_attribute): New function.
10508 (c_common_attribute_table): Add no_sanitize_address attribute.
10509 (handle_no_address_safety_analysis_attribute): Add
10510 no_sanitize_address attribute, not no_address_safety_analysis
10511 attribute.
10512
10513 2013-02-18 Aldy Hernandez <aldyh@redhat.com>
10514
10515 PR target/52555
10516 * c-common.c (handle_optimize_attribute): Call
10517 save_optabs_if_changed.
10518
10519 2013-02-18 Jakub Jelinek <jakub@redhat.com>
10520 Steven Bosscher <steven@gcc.gnu.org>
10521
10522 PR pch/54117
10523 * c-opts.c (c_common_post_options): If debug info is enabled
10524 and non-dwarf*, refuse to load PCH files and when writing PCH
10525 file warn.
10526
10527 2013-02-05 Jakub Jelinek <jakub@redhat.com>
10528
10529 PR middle-end/56167
10530 * c-common.c (handle_error_attribute): Fix condition.
10531
10532 2013-01-30 Jakub Jelinek <jakub@redhat.com>
10533
10534 PR c++/55742
10535 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
10536
10537 2013-01-18 Jason Merrill <jason@redhat.com>
10538
10539 PR target/54908
10540 * c.opt (-fextern-tls-init): New.
10541 * c-opts.c (c_common_post_options): Handle it.
10542
10543 2013-01-09 Jakub Jelinek <jakub@redhat.com>
10544
10545 PR c/48418
10546 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
10547 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
10548 and is either negative or bigger or equal to type precision
10549 of the first operand.
10550
10551 2012-12-03 Marek Polacek <polacek@redhat.com>
10552
10553 PR c/55570
10554 * c-common.c (check_user_alignment): Swap order of tests,
10555 check TREE_CODE first.
10556
10557 2012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
10558
10559 PR c++/52654
10560 * c-common.h (overflow_type): New enum.
10561 (build_userdef_literal): Add overflow_type argument.
10562 (tree_userdef_literal): Add overflow_type.
10563 (USERDEF_LITERAL_OVERFLOW): New access macro.
10564 * c-common.c (build_userdef_literal): Add overflow_type
10565 argument.
10566 * c-lex.c (c_lex_with_flags): Add overflow_type to
10567 build_userdef_literal calls.
10568 (interpret_integer, interpret_float): Add overflow_type argument.
10569
10570 2012-11-28 Richard Biener <rguenther@suse.de>
10571
10572 PR c/35634
10573 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
10574 here and use a type with proper overflow behavior for types that would
10575 need to be promoted for the arithmetic.
10576
10577 2012-11-23 Jakub Jelinek <jakub@redhat.com>
10578
10579 PR sanitizer/55435
10580 * c-common.c (handle_no_address_safety_analysis_attribute): New
10581 function.
10582 (c_common_attribute_table): Add no_address_safety_analysis.
10583
10584 2012-11-16 Simon Baldwin <simonb@google.com>
10585
10586 * c.opt: Add f[no-]canonical-system-headers.
10587 * c-opts.c (c_common_handle_option): Handle
10588 OPT_fcanonical_system_headers.
10589
10590 2012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
10591
10592 PR c++/54413
10593 * c-opts.c (c_common_handle_option): Set new flags.
10594 * c.opt: Describe new flags.
10595
10596 2012-11-09 Jason Merrill <jason@redhat.com>
10597
10598 * c.opt (Wabi-tag): New.
10599
10600 2012-11-09 Andi Kleen <ak@linux.intel.com>
10601
10602 PR 55139
10603 * c-common.c (get_atomic_generic_size): Mask with
10604 MEMMODEL_MASK
10605
10606 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
10607
10608 PR c/53063
10609 * c.opt (Wformat): Make it Alias Wformat=1.
10610 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
10611 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
10612 LangEnabledBy.
10613 (Wformat=): RejectNegative. Use LangEnabledBy.
10614 (Wnonnull): Use LangEnabledBy.
10615 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
10616 * c-format.c (set_Wformat): Delete.
10617 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
10618 (maybe_read_dollar_number): Likewise.
10619 (avoid_dollar_number): Likewise.
10620 (finish_dollar_format_checking): Likewise.
10621 (check_format_info): Likewise.
10622 (check_format_info_main): Likewise.
10623 (check_format_types): Likewise.
10624 (format_type_warning): Likewise.
10625 * c-common.c (int): Likewise.
10626 (check_function_sentinel): Likewise.
10627 * c-common.h (warn_format,set_Wformat): Do not declare here.
10628
10629 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
10630
10631 PR c/53063
10632 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
10633 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
10634 Use LangEnabledBy.
10635 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
10636 common.opt.
10637 (Wvariadic-macros): Init(1).
10638 * c-opts.c (c_common_handle_option): Do not handle them
10639 explicitly.
10640 (c_common_post_options): Likewise.
10641 (sanitize_cpp_opts): warn_unused_macros is now
10642 cpp_warn_unused_macros.
10643 (push_command_line_include): Likewise.
10644 * c-common.c (warn_unknown_pragmas): Do not define.
10645 * c-common.h (warn_unknown_pragmas): Do not declare.
10646
10647 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
10648
10649 PR c/51294
10650 * c-common.c (conversion_warning): Handle conditional expressions.
10651
10652 2012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
10653
10654 PR c++/54930
10655 * c.opt (Wreturn_local_addr): Define new option.
10656
10657 2012-10-25 Jason Merrill <jason@redhat.com>
10658
10659 * c.opt (Wvirtual-move-assign): New.
10660
10661 * c.opt (Winherited-variadic-ctor): New.
10662
10663 2012-10-25 Marc Glisse <marc.glisse@inria.fr>
10664
10665 PR c++/54427
10666 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
10667
10668 2012-10-23 Joseph Myers <joseph@codesourcery.com>
10669
10670 * c-common.h (pch_cpp_save_state): Declare.
10671 * c-target.def (c_preinclude): New hook.
10672 * c-opts.c (done_preinclude): New.
10673 (push_command_line_include): Handle default preincluded header.
10674 (cb_file_change): Call pch_cpp_save_state when calling
10675 push_command_line_include.
10676 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
10677 (pch_cpp_save_state): New.
10678 (pch_init): Call pch_cpp_save_state conditionally, instead of
10679 calling cpp_save_state.
10680
10681 2012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
10682
10683 PR c/53063
10684 PR c/40989
10685 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
10686 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
10687 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
10688 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
10689 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
10690 * c-opts.c (c_common_handle_option): Remove explicit handling from
10691 here.
10692 (c_common_post_options): Likewise.
10693
10694 2012-10-18 Eric Botcazou <ebotcazou@adacore.com>
10695
10696 * c-ada-spec.c (LOCATION_COL): Delete.
10697 (compare_location): New function.
10698 (compare_node): Use it.
10699 (compare_comment): Likewise.
10700
10701 2012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
10702
10703 PR c/53063
10704 PR c/40989
10705 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
10706 * c-opts.c (c_common_handle_option): Do not set them here. Add
10707 comment.
10708 (c_common_post_options): Likewise.
10709
10710 2012-10-16 Eric Botcazou <ebotcazou@adacore.com>
10711
10712 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
10713 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
10714 Remove POINTER_TYPE handling, add large unsigned handling and use
10715 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
10716
10717 2012-10-12 Jakub Jelinek <jakub@redhat.com>
10718
10719 PR c/54381
10720 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
10721 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
10722 locs and array of 3 trees instead of just single loc and single
10723 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
10724 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
10725 For *cmp* builtins that take two sources strings report warnings
10726 about first and second source, not about destination and source.
10727
10728 2012-10-12 Marc Glisse <marc.glisse@inria.fr>
10729
10730 PR c++/53055
10731 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
10732
10733 2012-10-11 Eric Botcazou <ebotcazou@adacore.com>
10734
10735 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
10736 declaring something coming from another file.
10737
10738 2012-10-10 Arnaud Charlet <charlet@adacore.com>
10739
10740 PR ada/54845
10741 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
10742
10743 2012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
10744
10745 PR c++/54194
10746 * c-common.c (warn_about_parentheses): Add location_t parameter;
10747 use EXPR_LOC_OR_LOC.
10748 * c-common.h: Update declaration.
10749
10750 2012-10-09 Marc Glisse <marc.glisse@inria.fr>
10751
10752 PR c++/54427
10753 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
10754 more operations. Make error messages optional.
10755 * c-common.h (enum stv_conv): Moved from c-typeck.c.
10756 (scalar_to_vector): Declare.
10757
10758 2012-10-08 Jason Merrill <jason@redhat.com>
10759
10760 * c-common.c (c_common_reswords): Add thread_local.
10761
10762 2012-10-08 Dodji Seketeli <dodji@redhat.com>
10763
10764 PR c++/53528 C++11 attribute support
10765 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
10766 new functions.
10767 * c-common.c (check_cxx_fundamental_alignment_constraints): New
10768 static function.
10769 (handle_aligned_attribute): In choose strictest alignment
10770 among many. Use new check_cxx_fundamental_alignment_constraints.
10771 (handle_transparent_union_attribute): In c++11 attribute syntax,
10772 don't look through typedefs.
10773
10774 2012-10-04 Arnaud Charlet <charlet@adacore.com>
10775
10776 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
10777 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
10778 out of dumpfile.h.
10779
10780 2012-09-25 Dehao Chen <dehao@google.com>
10781
10782 PR middle-end/54645
10783 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
10784 map when read in the pch.
10785
10786 2012-09-18 Arnaud Charlet <charlet@adacore.com>
10787
10788 * c-ada-spec.c: Style fixes.
10789
10790 2012-09-18 Thomas Quinot <quinot@adacore.com>
10791
10792 * c.opt (-fada-spec-parent): Define new command line switch.
10793 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
10794 is specified, generate binding spec as a child of the specified unit.
10795
10796 2012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
10797 Manuel López-Ibáñez <manu@gcc.gnu.org>
10798
10799 PR c++/53210
10800 * c.opt ([Winit-self]): Enabled by -Wall in C++.
10801
10802 2012-08-23 Arnaud Charlet <charlet@adacore.com>
10803
10804 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
10805 for pointers, and add missing Convention C pragma.
10806 (print_ada_struct_decl): Add missing aliased keyword.
10807 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
10808
10809 2012-08-17 Jakub Jelinek <jakub@redhat.com>
10810
10811 * c-common.c (sizeof_pointer_memaccess_warning): New function.
10812 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
10813 * c-opts.c (c_common_handle_option): Enable it for -Wall.
10814 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
10815 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
10816
10817 2012-08-10 Richard Guenther <rguenther@suse.de>
10818
10819 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
10820
10821 2012-08-07 Steven Bosscher <steven@gcc.gnu.org>
10822
10823 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
10824 instead of separate pp_newline and pp_flush.
10825 (print_c_tree): Likewise.
10826
10827 2012-07-26 Richard Henderson <rth@redhat.com>
10828
10829 * c-common.c (handle_hot_attribute): Allow labels.
10830 (handle_cold_attribute): Likewise.
10831
10832 2012-07-20 Jakub Jelinek <jakub@redhat.com>
10833
10834 PR c++/28656
10835 * c-common.c (check_function_nonnull): Handle multiple nonnull
10836 attributes properly.
10837
10838 2012-07-16 Steven Bosscher <steven@gcc.gnu.org>
10839
10840 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
10841 * c-ada-spec.c: Likewise.
10842 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
10843
10844 2012-07-14 Steven Bosscher <steven@gcc.gnu.org>
10845
10846 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
10847 Remove code conditional on it.
10848
10849 2012-07-11 Steven Bosscher <steven@gcc.gnu.org>
10850
10851 * c-gimplify.c: Do not include basic-block.h.
10852 * c-common.c: Do not include linfuncs.h.
10853
10854 2012-07-08 Steven Bosscher <steven@gcc.gnu.org>
10855
10856 * c-common.h: Include tree.h.
10857
10858 2012-07-02 Jason Merrill <jason@redhat.com>
10859
10860 PR c++/53524
10861 * c-common.c (get_priority): Call default_conversion.
10862
10863 2012-07-01 Uros Bizjak <ubizjak@gmail.com>
10864
10865 * c-pch.c (c_common_write_pch): Remove unused variables.
10866
10867 2012-06-29 Steven Bosscher <steven@gcc.gnu.org>
10868
10869 * cppspec.c: Moved from gcc/ to here.
10870
10871 2012-06-27 Kai Tietz <ktietz@redhat.com>
10872
10873 PR preprocessor/37215
10874 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
10875
10876 2012-06-21 Steven Bosscher <steven@gcc.gnu.org>
10877
10878 * c-common.h (c_common_print_pch_checksum): Remove.
10879 * c-pch.c: Do not include output.h.
10880 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
10881 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
10882 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
10883 (struct c_pch_header): Remove.
10884 (get_ident): Update gpch version.
10885 (pch_init): Do not print executable_checksum to asm_out_file.
10886 Do not fail if there is no asm_out_file to read back from. Set
10887 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
10888 (c_common_write_pch): Verify that nothing was written to asm_out_file
10889 since pch_init was called. Do not write a c_pch_header, and do not
10890 copy from asm_out_file to the PCH.
10891 (c_common_read_pch): Do not read a c_pch_header, and do not restore
10892 the content of asm_out_file from the PCH.
10893 (c_common_print_pch_checksum): Remove.
10894 * c-opts.c (c_common_init): Print out executable_checksum directly.
10895
10896 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
10897
10898 * c-target.def (objc_declare_unresolved_class_reference,
10899 objc_declare_class_definition): Add new hooks.
10900
10901 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
10902
10903 * c-lex.c: Do not include output.h.
10904 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
10905 Remove uses of ASM_OUTPUT_IDENT.
10906
10907 2012-06-15 Marc Glisse <marc.glisse@inria.fr>
10908
10909 PR c++/51033
10910 * c-common.h (c_build_vec_perm_expr): Move decl here.
10911 * c-common.c (c_build_vec_perm_expr): Move definition
10912 here.
10913
10914 2012-06-06 Steven Bosscher <steven@gcc.gnu.org>
10915
10916 * c.opt (fconserve-space): Turn into a no-op.
10917
10918 2012-06-04 Sterling Augustine <saugustine@google.com>
10919
10920 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
10921 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
10922 both the start and end of the function.
10923
10924 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
10925
10926 * c-common.c: Do not include output.h.
10927 * c-pragma.c: Likewise.
10928
10929 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
10930
10931 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
10932 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
10933 (lang_decl_name): Handle namespace decls.
10934
10935 2012-05-31 Steven Bosscher <steven@gcc.gnu.org>
10936
10937 * c-ada-spec.c: Do not include output.h.
10938 * c-semantics.c: Likewise.
10939
10940 2012-05-29 Joseph Myers <joseph@codesourcery.com>
10941
10942 * c-common.c: Fix typo.
10943
10944 2012-05-29 Michael Matz <matz@suse.de>
10945
10946 * c-common.h (c_expand_decl): Remove prototype.
10947
10948 2012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
10949
10950 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
10951 * c-opts.c (c_common_handle_option): Remove code handling
10952 warn_missing_braces.
10953
10954 2012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
10955
10956 PR c++/25137
10957 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
10958 -Wmissing_braces.
10959
10960 2012-05-22 Dodji Seketeli <dodji@redhat.com>
10961
10962 PR c++/53322
10963 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
10964
10965 2012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
10966
10967 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
10968 * c-opts.c (c_common_handle_option): Do not handle explicitly
10969 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
10970
10971 2012-05-16 Dodji Seketeli <dodji@redhat.com>
10972
10973 PR preprocessor/7263
10974 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
10975 to cpp_classify_number. For diagnostics, use the precise location
10976 instead of the global input_location.
10977
10978 2012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
10979
10980 PR c++/11856
10981 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
10982
10983 2012-05-14 Bernd Schmidt <bernds@codesourcery.com>
10984
10985 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
10986
10987 2012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
10988
10989 PR 53063
10990 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
10991 Wreorder): Use LangEnabledBy.
10992 * c-opts.c (c_common_handle_option): Do not enable them
10993 explicitly. Call lang-specific generated functions.
10994 (c_common_post_options): Do not set them here.
10995
10996 2012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
10997
10998 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
10999 Wmissing-field-initializers,Wmissing-parameter-type,
11000 Wold-style-declaration,Woverride-init): Use EnabledBy.
11001 * c-opts.c (c_common_post_options): Do not set here explicitly.
11002
11003 2012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
11004
11005 PR 53063
11006 * c-opts.c (c_common_handle_option): Use handle_generated_option
11007 to enable sub-options.
11008
11009 2012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
11010
11011 PR c++/53158
11012 * c-common.c (warnings_for_convert_and_check): Use warning_at.
11013
11014 2012-05-10 Richard Guenther <rguenther@suse.de>
11015
11016 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
11017 adjust commentary about TYPE_IS_SIZETYPE types.
11018
11019 2012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
11020
11021 PR c++/53261
11022 * c-common.c (warn_logical_operator): Check that argument of
11023 integer_zerop is not NULL.
11024
11025 2012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
11026
11027 PR c/43772
11028 * c-common.c (warn_logical_operator): Do not warn if either side
11029 is already true or false.
11030
11031 2012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
11032
11033 PR c/51712
11034 * c-common.c (expr_original_type): New.
11035 (shorten_compare): Do not warn for enumeration types.
11036
11037 2012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
11038
11039 * c.opt (fpermissive): Add Var(flag_permissive).
11040
11041 2012-04-30 Marc Glisse <marc.glisse@inria.fr>
11042
11043 PR c++/51033
11044 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
11045 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
11046
11047 2012-04-30 Dodji Seketeli <dodji@redhat.com>
11048
11049 Add -Wvarargs option
11050 * c.opt (Wvarargs): Define new option.
11051
11052 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
11053
11054 * c-common.c (check_function_arguments): Replace
11055 Wmissing-format-attribute with Wsuggest-attribute=format.
11056
11057 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
11058
11059 * c.opt (Wsuggest-attribute=format): New. Alias of
11060 Wmissing-format-attribute.
11061 * c-format.c (decode_format_type): Replace
11062 Wmissing-format-attribute with Wsuggest-attribute=format.
11063 (check_function_format): Likewise.
11064
11065 2012-04-27 Ollie Wild <aaw@google.com>
11066
11067 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
11068 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
11069 * c.opt: Add Wliteral-suffix.
11070
11071 2012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
11072
11073 PR c/44774
11074 * c.opt (Wpedantic): New.
11075 (pedantic): Alias Wpedantic.
11076 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
11077 (c_common_post_options): Likewise.
11078 (sanitize_cpp_opts): Likewise.
11079 * c-lex.c (interpret_float): Likewise.
11080 * c-format.c (check_format_types): Likewise.
11081 * c-common.c (pointer_int_sum): Likewise.
11082 (c_sizeof_or_alignof_type): Likewise.
11083 (c_add_case_label): Likewise.
11084 (c_do_switch_warnings): Likewise.
11085 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
11086
11087 2012-04-15 Jason Merrill <jason@redhat.com>
11088
11089 PR c++/52818
11090 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
11091 (C_STD_NAME): Distinguish between C++98 and C++11.
11092
11093 2012-04-11 Eric Botcazou <ebotcazou@adacore.com>
11094
11095 PR target/52624
11096 * c-common.h (uint16_type_node): Rename into...
11097 (c_uint16_type_node): ...this.
11098 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
11099 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
11100
11101 2012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
11102
11103 * c-common.c (warn_if_unused_value): Move definition to here.
11104 * c-common.h (warn_if_unused_value): Move declaration to here.
11105
11106 2012-03-23 William Bader <williambader@hotmail.com>
11107
11108 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
11109
11110 2012-03-20 Jason Merrill <jason@redhat.com>
11111
11112 * c-common.h (enum cxx_dialect): Add cxx1y.
11113 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
11114 test.
11115 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
11116 * c-opts.c (c_common_post_options): Likewise.
11117 (set_std_cxx1y): New.
11118 (c_common_handle_option): Call it.
11119 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
11120
11121 2012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
11122
11123 PR c++/14710
11124 * c.opt ([Wuseless-cast]): Add.
11125
11126 2012-03-16 Richard Guenther <rguenther@suse.de>
11127
11128 * c-pretty-print.c (pp_c_initializer_list): Adjust.
11129
11130 2012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
11131
11132 PR c++/44783
11133 * c.opt (ftemplate-backtrace-limit) Add.
11134
11135 2012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11136
11137 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
11138 handling.
11139 * c-pragma.c (handle_pragma_extern_prefix): Remove.
11140 (init_pragma): Don't register extern_prefix.
11141
11142 2012-03-12 Richard Guenther <rguenther@suse.de>
11143
11144 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
11145 (builtin_type_for_size): Likewise.
11146
11147 2012-02-13 Jakub Jelinek <jakub@redhat.com>
11148
11149 PR c++/52215
11150 * c-common.c (sync_resolve_params): Don't decide whether to convert
11151 or not based on TYPE_SIZE comparison, convert whenever arg_type
11152 is unsigned INTEGER_TYPE.
11153
11154 2012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
11155
11156 PR c/52118
11157 * c.opt ([Wunused-local-typedefs]): Fix description.
11158
11159 2012-01-24 Mike Stump <mikestump@comcast.net>
11160
11161 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
11162 exactly.
11163
11164 2012-01-18 Richard Guenther <rguenther@suse.de>
11165
11166 * c-opts.c (c_common_post_options): Reset LTO flags if
11167 we are about to generate a PCH.
11168
11169 2012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
11170
11171 PR c++/51777
11172 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
11173 use pp_unsigned_wide_integer.
11174
11175 2012-01-10 Richard Guenther <rguenther@suse.de>
11176
11177 PR middle-end/51806
11178 * c-opts.c (c_common_handle_option): Move -Werror handling
11179 to language independent code.
11180
11181 2012-01-05 Richard Guenther <rguenther@suse.de>
11182
11183 PR middle-end/51764
11184 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
11185 from common.opt.
11186
11187 2011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
11188
11189 PR c++/51316
11190 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
11191 of array types with an unknown bound.
11192
11193 2011-12-20 Joseph Myers <joseph@codesourcery.com>
11194
11195 * c-common.c (flag_isoc99): Update comment to refer to C11.
11196 (flag_isoc1x): Change to flag_isoc11.
11197 * c-common.h (flag_isoc99): Update comment to refer to C11.
11198 (flag_isoc1x): Change to flag_isoc11.
11199 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
11200 C11.
11201 * c-opts.c (set_std_c1x): Change to set_std_c11.
11202 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
11203 Call set_std_c11.
11204 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
11205 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
11206 * c.opt (std=c1x): Change to std=c11. Document as non-draft
11207 standard.
11208 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
11209 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
11210 (std=gnu1x): Make alias of std=gnu11.
11211
11212 2011-12-19 Jason Merrill <jason@redhat.com>
11213
11214 PR c++/51228
11215 * c-common.c (handle_transparent_union_attribute): Check the first
11216 field if the type is complete.
11217
11218 2011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
11219
11220 PR libstdc++/51365
11221 * c-common.c (RID_IS_FINAL): Add.
11222 * c-common.h (RID_IS_FINAL): Add.
11223
11224 2011-11-30 Iain Sandoe <iains@gcc.gnu.org>
11225
11226 * c.opt (fgnu-runtime): Provide full description.
11227 (fnext-runtime): Likewise.
11228 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
11229
11230 2011-11-28 Andrew MacLeod <amacleod@redhat.com>
11231
11232 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
11233 predefines in one place. Add LOCK_FREE predefines.
11234 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
11235 new func.
11236
11237 2011-11-24 Andrew MacLeod <amacleod@redhat.com>
11238
11239 PR c/51256
11240 * c-common.c (get_atomic_generic_size): Check for various error
11241 conditions
11242 (resolve_overloaded_atomic_exchange,
11243 resolve_overloaded_atomic_compare_exchange,
11244 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
11245 error_mark_node for error conditions.
11246
11247 2011-11-08 Richard Guenther <rguenther@suse.de>
11248
11249 PR middle-end/51010
11250 * c-pretty-print.c (pp_c_expression): Handle SSA_NAMEs.
11251
11252 2011-11-07 Richard Henderson <rth@redhat.com>
11253 Aldy Hernandez <aldyh@redhat.com>
11254 Torvald Riegel <triegel@redhat.com>
11255
11256 Merged from transactional-memory.
11257
11258 * c-common.c (handle_tm_wrap_attribute,
11259 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
11260 (struct c_common_reswords): Added __transaction* keywords.
11261 (struct c_common_attribute_table): Added transaction* and tm_regparm
11262 attributes.
11263 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
11264 masks.
11265 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
11266 find_tm_attribute): Declare.
11267
11268 2011-11-07 Jason Merrill <jason@redhat.com>
11269
11270 PR c++/35688
11271 * c-common.c, c-common.h: Revert yesterday's changes.
11272
11273 2011-11-06 Jason Merrill <jason@redhat.com>
11274
11275 PR c++/35688
11276 * c-common.c (decl_has_visibility_attr): Split out from...
11277 (c_determine_visibility): ...here.
11278 * c-common.h: Declare it.
11279
11280 2011-11-06 Joseph Myers <joseph@codesourcery.com>
11281
11282 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
11283 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
11284 type.
11285 (check_user_alignment): New. Split out of
11286 handle_aligned_attribute. Disallow integer constants with
11287 noninteger types. Conditionally allow zero.
11288 (handle_aligned_attribute): Use check_user_alignment.
11289 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
11290
11291 2011-11-06 Andrew MacLeod <amacleod@redhat.com>
11292 Richard Henderson <rth@redhat.com>
11293
11294 Merged from cxx-mem-model.
11295
11296 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
11297 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
11298 parameters that are the same type size.
11299 (get_atomic_generic_size): New. Find size of generic
11300 atomic function parameters and do typechecking.
11301 (add_atomic_size_parameter): New. Insert size into parameter list.
11302 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
11303 either __atomic_exchange_n or external library call.
11304 (resolve_overloaded_atomic_compare_exchange): Restructure
11305 __atomic_compare_exchange to either _n variant or external library call.
11306 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
11307 __atomic_load_n or an external library call.
11308 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
11309 __atomic_store_n or an external library call.
11310 (resolve_overloaded_builtin): Handle new __atomic builtins.
11311
11312 2011-11-04 Eric Botcazou <ebotcazou@adacore.com>
11313
11314 PR c++/50608
11315 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
11316 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
11317 <INDIRECT_REF>: Return the argument.
11318 <ARRAY_REF>: Remove special code for negative offset.
11319 Call fold_build_pointer_plus instead of size_binop.
11320 (fold_offsetof): Remove STOP_REF argument and adjust.
11321 * c-common.h (fold_offsetof_1): Declare.
11322 (fold_offsetof): Remove STOP_REF argument.
11323
11324 2011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
11325
11326 PR c++/50810
11327 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
11328 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
11329 Wnarrowing for C++0x and C++98.
11330 * c.opt ([Wnarrowing]): Update.
11331
11332 2011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
11333
11334 PR c++/44277
11335 * c.opt: Add Wzero-as-null-pointer-constant.
11336
11337 2011-10-31 Jason Merrill <jason@redhat.com>
11338
11339 * c.opt (-fdeduce-init-list): Off by default.
11340
11341 PR c++/50920
11342 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
11343 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
11344 and -Wc++11-compat.
11345 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
11346
11347 2011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
11348
11349 PR c++/30066
11350 * c.opt (fvisibility-inlines-hidden): Description change.
11351
11352 2011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
11353
11354 Implement C++11 user-defined literals.
11355 * c-common.c (build_userdef_literal): New.
11356 * c-common.def: New tree code.
11357 * c-common.h (tree_userdef_literal): New tree struct and accessors.
11358 * c-lex.c (interpret_float): Add suffix parm.
11359 (c_lex_with_flags): Build literal tokens.
11360
11361 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
11362
11363 PR c++/50841
11364 Revert:
11365 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
11366
11367 PR c++/50810
11368 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
11369 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
11370 Wnarrowing for C++0x and C++98.
11371 * c.opt ([Wnarrowing]): Update.
11372
11373 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
11374
11375 PR c++/50810
11376 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
11377 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
11378 Wnarrowing for C++0x and C++98.
11379 * c.opt ([Wnarrowing]): Update.
11380
11381 2011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
11382
11383 PR c++/45385
11384 * c-common.c (conversion_warning): Remove code looking for
11385 artificial operands.
11386
11387 2011-10-18 Dodji Seketeli <dodji@redhat.com>
11388
11389 PR bootstrap/50760
11390 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
11391 !NO_IMPLICIT_EXTERN_C.
11392
11393 2011-10-17 Michael Spertus <mike_spertus@symantec.com>
11394
11395 * c-common.c (c_common_reswords): Add __bases,
11396 __direct_bases.
11397 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
11398
11399 2011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
11400
11401 PR c++/50757
11402 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
11403
11404 2011-10-15 Tom Tromey <tromey@redhat.com>
11405 Dodji Seketeli <dodji@redhat.com>
11406
11407 * c.opt (fdebug-cpp): New option.
11408 * c-opts.c (c_common_handle_option): Handle the option.
11409 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
11410 output stream in parameter. Factorized from ...
11411 (maybe_print_line): ... this. Dump location debug information when
11412 -fdebug-cpp is in effect.
11413 (print_line_1): New static function. Takes an output stream in
11414 parameter. Factorized from ...
11415 (print_line): ... here. Dump location information when -fdebug-cpp
11416 is in effect.
11417 (scan_translation_unit): Dump location information when
11418 -fdebug-cpp is in effect.
11419
11420 2011-10-15 Tom Tromey <tromey@redhat.com>
11421 Dodji Seketeli <dodji@redhat.com>
11422
11423 * c.opt (ftrack-macro-expansion): New option. Handle it with and
11424 without argument.
11425 * c-opts.c (c_common_handle_option)<case
11426 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
11427 cases. Handle -ftrack-macro-expansion with and without argument.
11428
11429 2011-10-15 Tom Tromey <tromey@redhat.com>
11430 Dodji Seketeli <dodji@redhat.com>
11431
11432 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
11433 (print_line, cb_define, do_line_change): Adjust to avoid touching
11434 the internals of struct line_map. Use the public API instead.
11435 * c-pch.c (c_common_read_pch): Likewise.
11436 * c-lex.c (fe_file_change): Likewise.
11437
11438 2011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
11439
11440 PR c++/17212
11441 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
11442
11443 2011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
11444
11445 PR c++/33067
11446 * c-pretty-print.c (pp_c_floating_constant): Output
11447 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
11448
11449 2011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
11450
11451 * c-common.c (def_builtin_1): Delete old interface with two
11452 parallel arrays to hold standard builtin declarations, and replace
11453 it with a function based interface that can support creating
11454 builtins on the fly in the future. Change all uses, and poison
11455 the old names. Make sure 0 is not a legitimate builtin index.
11456 * c-omp.c (c_finish_omp_barrier): Ditto.
11457 (c_finish_omp_taskwait): Ditto.
11458 (c_finish_omp_flush): Ditto.
11459
11460 2011-10-11 Tristan Gingold <gingold@adacore.com>
11461
11462 * c.opt: (fallow-parameterless-variadic-functions): New.
11463
11464 2011-09-08 Dodji Seketeli <dodji@redhat.com>
11465
11466 PR c++/33255 - Support -Wunused-local-typedefs warning
11467 * c-common.h (struct c_language_function::local_typedefs): New
11468 field.
11469 (record_locally_defined_typedef, maybe_record_typedef_use)
11470 (maybe_warn_unused_local_typedefs): Declare new functions.
11471 * c-common.c (record_locally_defined_typedef)
11472 (maybe_record_typedef_use)
11473 (maybe_warn_unused_local_typedefs): Define new functions.
11474 * c.opt: Declare new -Wunused-local-typedefs flag.
11475
11476 2011-09-06 Eric Botcazou <ebotcazou@adacore.com>
11477
11478 PR middle-end/50266
11479 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
11480 computations.
11481
11482 2011-09-05 Richard Guenther <rguenther@suse.de>
11483
11484 * c-common.c (complete_array_type): Use ssize_int (-1) instead
11485 of integer_minus_one_node for empty array upper bounds.
11486
11487 2011-08-28 Dodji Seketeli <dodji@redhat.com>
11488
11489 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
11490 it's the first time it's being called on this main TU.
11491
11492 2011-08-24 Richard Guenther <rguenther@suse.de>
11493
11494 PR c/49396
11495 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
11496
11497 2011-08-22 Gabriel Charette <gchare@google.com>
11498
11499 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
11500 defined in cpp_init_builtins and c_cpp_builtins.
11501
11502 2011-08-19 Joseph Myers <joseph@codesourcery.com>
11503
11504 * c-common.c (c_common_reswords): Add __builtin_complex.
11505 * c-common.h (RID_BUILTIN_COMPLEX): New.
11506
11507 2011-08-18 Joseph Myers <joseph@codesourcery.com>
11508
11509 * c-common.c (c_common_reswords): Add _Noreturn.
11510 (keyword_is_function_specifier): Handle RID_NORETURN.
11511 * c-common.h (RID_NORETURN): New.
11512
11513 2011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
11514
11515 * c-common.c (unsafe_conversion_p): New function. Check if it is
11516 unsafe to convert an expression to the type.
11517 (conversion_warning): Adjust, use unsafe_conversion_p.
11518 * c-common.h (unsafe_conversion_p): New function declaration.
11519
11520 2011-08-02 Jakub Jelinek <jakub@redhat.com>
11521
11522 * c-common.h (c_finish_omp_atomic): Adjust prototype.
11523 (c_finish_omp_taskyield): New prototype.
11524 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
11525 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
11526 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
11527 or RHS1 have side-effects, evaluate those too in the right spot,
11528 if it is a decl and LHS is also a decl, error out if they
11529 aren't the same.
11530 (c_finish_omp_taskyield): New function.
11531 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
11532 * c-pragma.c (omp_pragmas): Add taskyield.
11533 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
11534 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
11535 PRAGMA_OMP_CLAUSE_MERGEABLE.
11536
11537 2011-07-25 Dodji Seketeli <dodji@redhat.com>
11538
11539 * c-common.h (set_underlying_type): Remove parm name from
11540 declaration.
11541
11542 2011-07-25 Romain Geissler <romain.geissler@gmail.com>
11543
11544 * c-pretty-print.h: Search c-common.h in c-family.
11545
11546 2011-07-22 Jason Merrill <jason@redhat.com>
11547
11548 PR c++/49793
11549 * c.opt (Wnarrowing): New.
11550
11551 PR c++/30112
11552 * c-common.h: Declare c_linkage_bindings.
11553 * c-pragma.c (handle_pragma_redefine_extname): Use it.
11554
11555 PR c++/49813
11556 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
11557 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
11558 as flag_isoc99 for 'restrict'.
11559 (pp_c_specifier_qualifier_list): Likewise for _Complex.
11560
11561 2011-07-21 Ian Lance Taylor <iant@google.com>
11562
11563 PR middle-end/49705
11564 * c-common.c (c_disable_warnings): New static function.
11565 (c_enable_warnings): New static function.
11566 (c_fully_fold_internal): Change local unused_p to bool. Call
11567 c_disable_warnings and c_enable_warnings rather than change
11568 c_inhibit_evaluation_warnings.
11569
11570 2011-07-20 Jason Merrill <jason@redhat.com>
11571
11572 PR c++/6709 (DR 743)
11573 PR c++/42603 (DR 950)
11574 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
11575 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
11576 (CPP_DECLTYPE): New.
11577 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
11578
11579 2011-07-19 Richard Guenther <rguenther@suse.de>
11580
11581 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
11582 * c-omp.c (c_finish_omp_for): Likewise.
11583
11584 2011-07-12 Eric Botcazou <ebotcazou@adacore.com>
11585
11586 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
11587 body on the next line.
11588
11589 2011-07-08 Jason Merrill <jason@redhat.com>
11590
11591 PR c++/45437
11592 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
11593
11594 PR c++/49673
11595 * c-common.c (c_apply_type_quals_to_decl): Don't check
11596 TYPE_NEEDS_CONSTRUCTING.
11597
11598 2011-07-06 Richard Guenther <rguenther@suse.de>
11599
11600 * c-common.c (c_common_nodes_and_builtins):
11601 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
11602
11603 2011-07-05 Richard Guenther <rguenther@suse.de>
11604
11605 * c-common.c (c_common_nodes_and_builtins): Build all common
11606 tree nodes first.
11607
11608 2011-06-27 Jakub Jelinek <jakub@redhat.com>
11609
11610 * c-common.h (c_tree_chain_next): New static inline function.
11611
11612 * c-common.c (check_builtin_function_arguments): Handle
11613 BUILT_IN_ASSUME_ALIGNED.
11614
11615 2011-06-21 Andrew MacLeod <amacleod@redhat.com>
11616
11617 * c-common.c: Add sync_ or SYNC__ to builtin names.
11618 * c-omp.c: Add sync_ or SYNC__ to builtin names.
11619
11620 2011-06-20 Pierre Vittet <piervit@pvittet.com>
11621
11622 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
11623 handler.
11624 (gen_pragma_handler): New union.
11625 (internal_pragma_handler): New type.
11626 (c_register_pragma_with_data)
11627 (c_register_pragma_with_expansion_and_data): New functions.
11628
11629 * c-pragma.c (registered_pragmas, c_register_pragma_1)
11630 (c_register_pragma, c_register_pragma_with_expansion)
11631 (c_invoke_pragma_handler): Changed to work with
11632 internal_pragma_handler.
11633 (c_register_pragma_with_data)
11634 (c_register_pragma_with_expansion_and_data): New functions.
11635
11636 2011-06-14 Joseph Myers <joseph@codesourcery.com>
11637
11638 * c-common.c: Include common/common-target.h.
11639 (handle_section_attribute): Use
11640 targetm_common.have_named_sections.
11641 * c-cppbuiltin.c: Include common/common-target.h.
11642 (c_cpp_builtins): Use targetm_common.except_unwind_info.
11643
11644 2011-06-10 Richard Guenther <rguenther@suse.de>
11645
11646 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
11647 to print a IDENTIFIER_NODE.
11648
11649 2011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11650 Joseph Myers <joseph@codesourcery.com>
11651
11652 * c.opt (fbuilding-libgcc): New option.
11653 * c-cppbuiltin.c (c_cpp_builtins): Define
11654 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
11655
11656 2011-06-07 Jason Merrill <jason@redhat.com>
11657
11658 * c-common.c (max_tinst_depth): Lower default to 900.
11659
11660 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
11661
11662 2011-06-07 Richard Guenther <rguenther@suse.de>
11663
11664 * c-common.c (c_common_nodes_and_builtins): Do not set
11665 size_type_node or call set_sizetype.
11666
11667 2011-06-07 Dodji Seketeli <dodji@redhat.com>
11668
11669 PR debug/49130
11670 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
11671 type when using pointer comparison to compare types.
11672
11673 2011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
11674
11675 * c.opt: Add -Wdelete-non-virtual-dtor.
11676 * c-opts.c (c_common_handle_option): Include it in -Wall.
11677
11678 2011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
11679
11680 PR bootstrap/49190
11681
11682 Revert:
11683 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
11684
11685 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
11686 not tree_common.
11687
11688 2011-05-27 Jakub Jelinek <jakub@redhat.com>
11689
11690 PR c++/49165
11691 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
11692 C++ don't call c_common_truthvalue_conversion on void type arms.
11693
11694 2011-05-27 Nathan Froyd <froydnj@codesourcery.com>
11695
11696 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
11697 (stmt_list_stack): Define.
11698 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
11699 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
11700
11701 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
11702
11703 * c-common.c (warning_candidate_p): Check for BLOCKs.
11704
11705 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
11706
11707 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
11708 not tree_common.
11709
11710 2011-05-25 Jakub Jelinek <jakub@redhat.com>
11711
11712 * c-common.c (def_fn_type): Remove extra va_end.
11713
11714 2011-05-23 Jason Merrill <jason@redhat.com>
11715
11716 PR c++/48106
11717 * c-common.c (c_common_get_narrower): New.
11718 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
11719
11720 2011-05-23 Nathan Froyd <froydnj@codesourcery.com>
11721
11722 * c-common.h (check_function_arguments): Tweak prototype of
11723 check_function_arguments.
11724 * c-common.c (check_function_arguments): Likewise. Adjust
11725 calls to check_function_nonnull, check_function_format, and
11726 check_function_sentinel.
11727 (check_function_sentinel): Take a FUNCTION_TYPE rather than
11728 separate attributes and typelist arguments. Use
11729 FOREACH_FUNCTION_ARGS to iterate over argument types.
11730
11731 2011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
11732
11733 * c-common.c (c_common_reswords): Reorder.
11734 * c-common.h (rid): Likewise.
11735
11736 2011-05-10 Nathan Froyd <froydnj@codesourcery.com>
11737
11738 * c-common.c (def_fn_type): Don't call build_function_type, call
11739 build_function_type_array or build_varargs_function_type_array
11740 instead.
11741 (c_common_nodes_and_builtins): Likewise.
11742
11743 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
11744
11745 * c-common.c (c_add_case_label): Omit the loc argument to
11746 build_case_label.
11747 * c-common.h (build_case_label): Remove.
11748 * c-semantics.c (build_case_label): Remove.
11749
11750 2011-05-05 Joseph Myers <joseph@codesourcery.com>
11751
11752 * c-objc.h (objc_start_method_definition): Update prototype.
11753 * stub-objc.c (objc_start_method_definition): Add extra parameter.
11754
11755 2011-05-04 Nathan Froyd <froydnj@codesourcery.com>
11756
11757 * c-common.c (check_main_parameter_types): Reindent. Don't use
11758 TYPE_ARG_TYPES directly.
11759 (handle_nonnull_attribute): Likewise.
11760 (sync_resolve_params): Likewise.
11761 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
11762 to check_format_string.
11763 (handle_format_attribute): Likewise.
11764 (check_format_string): Take a function type to examine instead of
11765 a type list. Use a function_arg_iterator to step through argument
11766 types.
11767
11768 2011-05-04 Richard Guenther <rguenther@suse.de>
11769
11770 * c-common.c (fix_string_type): Use size_int for index type bounds.
11771 (start_fname_decls): Do not pass NULL to build_int_cst.
11772 (c_init_attributes): Likewise.
11773 * c-lex.c (c_lex_with_flags): Likewise.
11774
11775 2011-04-27 Jason Merrill <jason@redhat.com>
11776
11777 * c-common.c (make_tree_vector_from_list): New.
11778 * c-common.h: Declare it.
11779
11780 2011-04-26 Richard Guenther <rguenther@suse.de>
11781
11782 PR preprocessor/48248
11783 * c-ppoutput.c (maybe_print_line): Always optimize newlines
11784 for output size with -P.
11785
11786 2011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
11787
11788 * c-common.c (struct c_common_resword): Add __underlying_type.
11789 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
11790
11791 2011-04-20 Jim Meyering <meyering@redhat.com>
11792
11793 * c-format.c (init_dollar_format_checking): Remove useless
11794 if-before-free.
11795
11796 2011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
11797
11798 * c-objc.h (objc_get_interface_ivars): Removed.
11799 (objc_detect_field_duplicates): New.
11800 * stub-objc.c: Likewise.
11801
11802 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
11803
11804 * stub-objc.c (objc_declare_protocols): Renamed to
11805 objc_declare_protocol.
11806 * c-objc.h: Likewise.
11807
11808 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
11809
11810 * stub-objc.c (objc_declare_class): Updated argument name.
11811
11812 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
11813
11814 * c-common.h (c_common_init_ts): Declare.
11815 * c-common.c (c_common_init_ts): Define.
11816
11817 2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
11818
11819 * c-objc.h (objc_build_message_expr): Updated prototype.
11820 * stub-objc.c (objc_build_message_expr): Likewise.
11821
11822 2011-04-12 Martin Jambor <mjambor@suse.cz>
11823
11824 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
11825 of cgraph_node.
11826
11827 2011-04-11 Richard Guenther <rguenther@suse.de>
11828
11829 * c-common.c (complete_array_type): Build a range type of
11830 proper type.
11831
11832 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
11833
11834 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
11835 (handle_type_generic_attribute): Likewise.
11836
11837 2011-04-07 Jason Merrill <jason@redhat.com>
11838
11839 PR c++/48450
11840 * c-common.c (c_common_truthvalue_conversion): Don't ignore
11841 conversion from C++0x scoped enum.
11842
11843 2011-04-06 Joseph Myers <joseph@codesourcery.com>
11844
11845 * c-target-def.h: New file.
11846 * c-target.def: New file.
11847 * c-target.h: New file.
11848 * c-common.c (targetcm): Don't define here.
11849 * c-common.h (default_handle_c_option): Declare.
11850 * c-format.c: Include c-target.h instead of target.h.
11851 * c-opts.c: Include c-target.h instead of target.h. Explicitly
11852 include tm.h.
11853 (default_handle_c_option): Move from targhooks.c.
11854
11855 2011-03-29 Jakub Jelinek <jakub@redhat.com>
11856
11857 PR preprocessor/48248
11858 * c-ppoutput.c (print): Add src_file field.
11859 (init_pp_output): Initialize it.
11860 (maybe_print_line): Don't optimize by adding up to 8 newlines
11861 if map->to_file and print.src_file are different file.
11862 (print_line): Update print.src_file.
11863
11864 2011-03-25 Kai Tietz <ktietz@redhat.com>
11865
11866 * c-ada-spec.c (compare_comment): Use filename_cmp
11867 instead of strcmp for filename.
11868
11869 2011-03-25 Jeff Law <law@redhat.com>
11870
11871 * c-common.c (def_fn_type): Add missing va_end.
11872
11873 2011-03-25 Jason Merrill <jason@redhat.com>
11874
11875 * c.opt: Add -std=c++03.
11876
11877 2011-03-22 Eric Botcazou <ebotcazou@adacore.com>
11878
11879 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
11880
11881 2011-03-17 Kai Tietz <ktietz@redhat.com>
11882
11883 PR target/12171
11884 * c-pretty-print.c (pp_c_specifier_qualifier_list):
11885 Display allowed attributes for function pointer types.
11886 (pp_c_attributes_display): New function to display
11887 attributes having affects_type_identity flag set to true.
11888 * c-pretty-print.h (pp_c_attributes_display): New prototype.
11889
11890 * c-common.c (c_common_attribute_table):
11891 Add new element.
11892 (c_common_format_attribute_table): Likewise.
11893
11894 2011-03-18 Jason Merrill <jason@redhat.com>
11895
11896 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
11897 * c-common.h: Don't declare it here.
11898 * c-common.c: Or define it here.
11899 * c-opts.c (c_common_handle_option): Or set it here.
11900
11901 PR c++/35315
11902 * c-common.c (handle_transparent_union_attribute): Don't
11903 make a duplicate type in C++.
11904
11905 2011-03-15 Jason Merrill <jason@redhat.com>
11906
11907 * c-common.c (max_constexpr_depth): New.
11908 * c-common.h: Declare it.
11909 * c-opts.c (c_common_handle_option): Set it.
11910 * c.opt (fconstexpr-depth): New option.
11911
11912 2011-03-11 Jason Merrill <jason@redhat.com>
11913
11914 * c-common.c (attribute_takes_identifier_p): Add missing const.
11915
11916 PR c++/46803
11917 * c-common.c (attribute_takes_identifier_p): Assume that an
11918 unknown attribute takes an identifier.
11919
11920 2011-03-07 Nathan Froyd <froydnj@codesourcery.com>
11921
11922 PR c/47786
11923 * c-common.c (c_type_hash): Call list_length instead of iterating
11924 through DECL_CHAIN. Rename 'i' to 'n_elements'.
11925
11926 2011-02-19 Jakub Jelinek <jakub@redhat.com>
11927
11928 PR c/47809
11929 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
11930
11931 2011-02-17 Iain Sandoe <iains@gcc.gnu.org>
11932
11933 * c.opt (fobjc-abi-version=) New.
11934 (fobjc-nilcheck): New.
11935
11936 2011-02-03 Nathan Froyd <froydnj@codesourcery.com>
11937
11938 PR c++/46890
11939 * c-common.h (keyword_is_decl_specifier): Declare.
11940 * c-common.c (keyword_is_decl_specifier): Define.
11941 (keyword_is_function_specifier): New function.
11942
11943 2011-01-26 Jakub Jelinek <jakub@redhat.com>
11944
11945 PR c/47473
11946 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
11947 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
11948 REAL_TYPE.
11949
11950 2011-01-26 Arnaud Charlet <charlet@adacore.com>
11951
11952 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
11953
11954 2011-01-26 Jakub Jelinek <jakub@redhat.com>
11955
11956 PR pch/47430
11957 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
11958 after init_c_lex if pch_file is set.
11959
11960 2011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
11961
11962 PR c++/43601
11963 * c.opt (-fkeep-inline-dllexport): New switch.
11964
11965 2011-01-12 Richard Guenther <rguenther@suse.de>
11966
11967 PR middle-end/32511
11968 * c-common.c (handle_weak_attribute): Warn instead of error
11969 on declaring an inline function weak.
11970
11971 2011-01-05 Tom Tromey <tromey@redhat.com>
11972
11973 * c-common.h (lvalue_error): Update.
11974 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
11975 not error.
11976
11977 2010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
11978
11979 PR objc/47075
11980 * c-objc.h (objc_finish_message_expr): Added argument to
11981 prototype.
11982
11983 2010-12-22 Nathan Froyd <froydnj@codesourcery.com>
11984
11985 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
11986 Use prototype_p.
11987
11988 2010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
11989
11990 * c-objc.h (objc_maybe_warn_exceptions): New.
11991 * stub-objc.c (objc_maybe_warn_exceptions): New.
11992
11993 2010-12-10 Nathan Froyd <froydnj@codesourcery.com>
11994
11995 * c-common.h (readonly_error): Declare.
11996 * c-common.c (readonly_error): Define.
11997
11998 2010-12-09 Nathan Froyd <froydnj@codesourcery.com>
11999
12000 * c-common.h (invalid_indirection_error): Declare.
12001 * c-common.c (invalid_indirection_error): Define.
12002
12003 2010-12-03 Richard Guenther <rguenther@suse.de>
12004
12005 PR c/46745
12006 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
12007 (pp_c_unary_expression): Likewise.
12008 (pp_c_expression): Likewise.
12009
12010 2010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
12011
12012 * c-common.h (objc_finish_function): New.
12013 (objc_non_volatilized_type): Removed.
12014 (objc_type_quals_match): Removed.
12015 * stub-objc.c (objc_finish_function): New.
12016 (objc_non_volatilized_type): Removed.
12017 (objc_type_quals_match): Removed.
12018
12019 2010-11-30 Joseph Myers <joseph@codesourcery.com>
12020
12021 * c-common.h (parse_optimize_options): Declare.
12022 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
12023 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
12024
12025 2010-11-29 Joseph Myers <joseph@codesourcery.com>
12026
12027 * c-opts.c (check_deps_environment_vars): Use getenv instead of
12028 GET_ENVIRONMENT.
12029 * c-pch.c (O_BINARY): Don't define here.
12030 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
12031
12032 2010-11-25 Joseph Myers <joseph@codesourcery.com>
12033
12034 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
12035 targetm.except_unwind_info.
12036
12037 2010-11-23 Joseph Myers <joseph@codesourcery.com>
12038
12039 * c-opts.c (c_common_handle_option): Pass location to
12040 set_struct_debug_option.
12041
12042 2010-11-23 Joseph Myers <joseph@codesourcery.com>
12043
12044 * c-common.c (visibility_options): Move from ../opts.c.
12045 * c-common.h (struct visibility_flags, visibility_options):
12046 Declare here.
12047 * c-opts.c (finish_options): Rename to c_finish_options.
12048 (c_common_init): Update call to finish_options.
12049
12050 2010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
12051
12052 PR objc/34033
12053 * c-lex.c (lex_string): Check that each string in an Objective-C
12054 string concat sequence starts with either one or zero '@', and
12055 that there are no spurious '@' signs at the end.
12056
12057 2010-11-20 Joseph Myers <joseph@codesourcery.com>
12058
12059 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
12060 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
12061 HANDLE_PRAGMA_VISIBILITY.
12062 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
12063 HANDLE_PRAGMA_VISIBILITY): Don't define.
12064 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
12065
12066 2010-11-20 Nathan Froyd <froydnj@codesourcery.com>
12067
12068 PR c++/16189
12069 PR c++/36888
12070 PR c++/45331
12071 * c-common.h (keyword_begins_type_specifier): Declare.
12072 (keyword_is_storage_class_specifier): Declare.
12073 (keyword_is_type_qualifier): Declare.
12074 * c-common.c (keyword_begins_type_specifier): New function.
12075 (keyword_is_storage_class_specifier): New function.
12076 (keyword_is_type_qualifier): Declare.
12077
12078 2010-11-19 Joseph Myers <joseph@codesourcery.com>
12079
12080 PR c/46547
12081 * c-common.c (in_late_binary_op): Define.
12082 (c_common_truthvalue_conversion): Check in_late_binary_op before
12083 calling c_save_expr.
12084 * c-common.h (in_late_binary_op): Declare.
12085
12086 2010-11-19 Joseph Myers <joseph@codesourcery.com>
12087
12088 * c-opts.c (c_common_handle_option): Update calls to
12089 set_struct_debug_option.
12090
12091 2010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
12092
12093 * c-common.h (objc_declare_protocols): Added additional argument.
12094 * stub-objc.c (objc_declare_protocol): Same change.
12095
12096 2010-11-18 Nathan Froyd <froydnj@codesourcery.com>
12097
12098 PR c/33193
12099 * c-common.h (build_real_imag_expr): Declare.
12100 * c-semantics.c (build_real_imag_expr): Define.
12101
12102 2010-11-17 Joseph Myers <joseph@codesourcery.com>
12103
12104 * c-opts.c (c_common_parse_file): Take no arguments.
12105 * c-common.h (c_common_parse_file): Update prototype.
12106
12107 2010-11-16 Jakub Jelinek <jakub@redhat.com>
12108
12109 PR c++/46401
12110 * c-common.c (warning_candidate_p): Don't track non-const calls
12111 or STRING_CSTs.
12112
12113 2010-11-15 Ian Lance Taylor <iant@google.com>
12114
12115 * c-lex.c (init_c_lex): Set macro debug callbacks if
12116 flag_dump_go_spec is set.
12117
12118 2010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
12119
12120 * c-common.h (objc_build_incr_expr_for_property_ref): New.
12121 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
12122
12123 2010-11-15 Nathan Froyd <froydnj@codesourcery.com>
12124
12125 PR preprocessor/45038
12126 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
12127 dialects.
12128
12129 2010-11-12 Joseph Myers <joseph@codesourcery.com>
12130
12131 * c-common.h (c_family_lang_mask): Declare.
12132 * c-opts.c (c_family_lang_mask): Make extern.
12133 * c-pragma.c (handle_pragma_diagnostic): Use
12134 control_warning_option.
12135
12136 2010-11-12 Joseph Myers <joseph@codesourcery.com>
12137
12138 * c-common.c (parse_optimize_options): Update call to
12139 decode_options.
12140 * c-common.h (c_common_handle_option): Update prototype.
12141 * c-opts.c (c_common_handle_option): Take location_t parameter and
12142 pass it to other functions.
12143
12144 2010-11-11 Joseph Myers <joseph@codesourcery.com>
12145
12146 * c-opts.c (warning_as_error_callback): Remove.
12147 (c_common_initialize_diagnostics): Don't call
12148 register_warning_as_error_callback.
12149 (c_common_handle_option): Handle -Werror=normalized= here.
12150
12151 2010-11-10 Joseph Myers <joseph@codesourcery.com>
12152
12153 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
12154 in diagnostic.
12155 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
12156 letter.
12157 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
12158 Remove trailing '.' from diagnostics.
12159 * c.opt (Wwrite-strings_: Avoid '`' in help text.
12160
12161 2010-11-10 Joseph Myers <joseph@codesourcery.com>
12162
12163 * c-common.c (parse_optimize_options): Pass global_dc to
12164 decode_options.
12165 * c-opts.c (c_common_handle_option): Pass &global_options to
12166 set_Wstrict_aliasing.
12167 * c.opt (v): Don't mark Common or document here.
12168
12169 2010-11-06 Iain Sandoe <iains@gcc.gnu.org>
12170
12171 PR target/44981
12172 * c-format.c (format_type): New type gcc_objc_string_format_type.
12173 (valid_stringptr_type_p): New.
12174 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
12175 (check_format_string): Pass expected type, use
12176 valid_stringptr_type_p (), check that the format string types are
12177 consistent with the format specification.
12178 (decode_format_attr): Warn if NSString is used outside objective-c.
12179 (format_types_orig): Add NSString.
12180 (format_name): New.
12181 (format_flags): New.
12182 (check_format_arg): Handle format strings requiring an external parser.
12183 first_target_format_type: New variable.
12184 (handle_format_attribute): Set up first_target_format_type, pass the
12185 expected format arg string type to check_format_string().
12186 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
12187 * stub-objc.c (objc_string_ref_type_p): New.
12188 (objc_check_format_arg): New.
12189
12190 2010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
12191
12192 Fixed using the Objective-C 2.0 dot-syntax with class names.
12193 * c-common.h (objc_build_class_component_ref): New.
12194 * stub-objc.c (objc_build_class_component_ref): New.
12195
12196 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
12197
12198 * c.opt (Wproperty-assign-default): New option.
12199
12200 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
12201
12202 Implemented -fobjc-std=objc1 flag.
12203 * c.opt (fobjc-std=objc1): New option.
12204
12205 2010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
12206
12207 Implemented format and noreturn attributes for Objective-C methods.
12208 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
12209 attribute for Objective-C methods.
12210
12211 2010-10-31 Jason Merrill <jason@redhat.com>
12212
12213 * c-common.c (conversion_warning, warn_for_collisions_1): Use
12214 EXPR_LOC_OR_HERE.
12215
12216 2010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
12217
12218 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
12219 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
12220 (objc_add_property_declaration): Removed arguments for copies and
12221 ivar.
12222 (objc_build_getter_call): Renamed to
12223 objc_maybe_build_component_ref.
12224 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
12225 (objc_is_property_ref): New.
12226 * c-common.c (c_common_reswords): Removed copies and ivar.
12227 * stub-objc.c (objc_add_property_declaration): Removed arguments
12228 for copies and ivar.
12229 (objc_build_getter_call): Renamed to
12230 objc_maybe_build_component_ref.
12231 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
12232 (objc_is_property_ref): New.
12233
12234 2010-10-29 Arnaud Charlet <charlet@adacore.com>
12235 Matthew Gingell <gingell@adacore.com>
12236
12237 * c-ada-spec.c (separate_class_package): New function.
12238 (pp_ada_tree_identifier): Prefix references to C++ classes with the
12239 name of their enclosing package.
12240 (print_ada_declaration): Use separate_class_package.
12241
12242 2010-10-27 Jason Merrill <jason@redhat.com>
12243
12244 * c-common.c (c_common_reswords): Add __is_literal_type.
12245 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
12246
12247 * c-common.c (check_case_value): Remove special C++ code.
12248
12249 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
12250
12251 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
12252 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
12253 and RID_LAST_PATTR.
12254 (objc_add_property_declaration): Added additional arguments.
12255 (objc_property_attribute_kind): Removed.
12256 (objc_set_property_attr): Removed.
12257 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
12258 copy and nonatomic.
12259 * stub-objc.c (objc_add_property_declaration): Added additional
12260 arguments.
12261 (objc_set_property_attr): Removed.
12262
12263 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
12264
12265 * c-common.h (objc_add_property_variable): Renamed to
12266 objc_add_property_declaration. Added location argument.
12267 * stub-objc.c (objc_add_property_variable): Same change.
12268
12269 2010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
12270
12271 * c-common.h (objc_maybe_printable_name): New.
12272 * stub-objc.c (objc_maybe_printable_name): New.
12273
12274 2010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
12275 Andrew Pinski <pinskia@gmail.com>
12276
12277 * c-common.h (c_common_mark_addressable_vec): Declare.
12278 * c-common.c (c_common_mark_addressable_vec): New function.
12279
12280 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
12281
12282 * c-common.h (objc_set_method_type): Removed.
12283 (objc_add_method_declaration): Added boolean argument.
12284 (objc_start_method_definition): Same change.
12285 (objc_build_method_signature): Same change.
12286 * stub-objc.c (objc_set_method_type): Removed.
12287 (objc_add_method_declaration): Added boolean argument.
12288 (objc_start_method_definition): Same change.
12289 (objc_build_method_signature): Same change.
12290
12291 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
12292
12293 * c-common.h (finish_file): Removed.
12294 (objc_write_global_declarations): New.
12295 * c-opts.c (c_common_parse_file): Do not call finish_file.
12296 * stub-objc.c (objc_write_global_declarations): New.
12297
12298 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
12299
12300 Implemented parsing @synthesize and @dynamic for
12301 Objective-C/Objective-C++.
12302 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
12303 (objc_add_synthesize_declaration): New.
12304 (objc_add_dynamic_declaration): New.
12305 * c-common.c (c_common_reswords): Add synthesize and dynamic.
12306 * stub-objc.c (objc_add_synthesize_declaration): New.
12307 (objc_add_dynamic_declaration): New.
12308
12309 2010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
12310
12311 PR target/46041
12312 * c-cppbuiltin.c (mode_has_fma): Move function here from
12313 builtins.c. Don't use the fma optab, instead just use the
12314 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
12315 using -save-temps.
12316
12317 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
12318
12319 Merge from 'apple/trunk' branch on FSF servers.
12320
12321 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
12322
12323 Radar 4330422
12324 * c-common.h (objc_non_volatilized_type): New declaration
12325 * stub-objc.c (objc_non_volatilized_type): New stub.
12326
12327 2010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
12328
12329 Merge from 'apple/trunk' branch on FSF servers.
12330
12331 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
12332
12333 Radar 4133425
12334 * c-common.h (objc_diagnose_private_ivar): New decl.
12335 * stub-objc.c (objc_diagnose_private_ivar): New stub.
12336
12337 2010-10-17 Iain Sandoe <iains@gcc.gnu.org>
12338
12339 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
12340 * c-common.h (enum rid): Add RID_AT_PACKAGE.
12341 (objc_ivar_visibility_kind): New enum.
12342 (objc_set_visibility): Adjust prototype to use visibility enum.
12343 * stub-objc.c (objc_set_visibility): Adjust stub to use
12344 visibility enum.
12345
12346 2010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
12347
12348 * c-cppbuiltin.c (builtin_define_float_constants): Emit
12349 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
12350 has the appropriate fma builtins.
12351 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
12352
12353 2010-10-14 Iain Sandoe <iains@gcc.gnu.org>
12354
12355 merge from FSF apple 'trunk' branch.
12356 2006 Fariborz Jahanian <fjahanian@apple.com>
12357
12358 Radars 4436866, 4505126, 4506903, 4517826
12359 * c-common.c (c_common_resword): Define @property and its attributes.
12360 * c-common.h: Define property attribute enum entries.
12361 (OBJC_IS_PATTR_KEYWORD): New.
12362 (objc_property_attribute_kind): New enum.
12363 Declare objc_set_property_attr (), objc_add_property_variable (),
12364 objc_build_getter_call () and objc_build_setter_call ().
12365 * stub-objc.c (objc_set_property_attr): New stub.
12366 (objc_add_property_variable): Likewise.
12367 (objc_build_getter_call): Likewise.
12368 (objc_build_setter_call) Likewise.
12369
12370 2010-10-13 Iain Sandoe <iains@gcc.gnu.org>
12371
12372 merge from FSF apple 'trunk' branch.
12373 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
12374
12375 Radar 3803157 (method attributes)
12376 * c-common.c (handle_deprecated_attribute): Recognize
12377 objc methods as valid declarations.
12378 * c-common.h: Declare objc_method_decl ().
12379 * stub-objc.c (objc_method_decl): New stub.
12380
12381 2010-10-08 Joseph Myers <joseph@codesourcery.com>
12382
12383 * c-common.c (parse_optimize_options): Call
12384 decode_cmdline_options_to_array_default_mask before
12385 decode_options. Update arguments to decode_options.
12386 * c-common.h (c_common_init_options_struct): Declare.
12387 * c-opts.c (c_common_init_options_struct): New. Split out from
12388 c_common_init_options.
12389
12390 2010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
12391
12392 Implemented fast enumeration for Objective-C.
12393 * c-common.h (objc_finish_foreach_loop): New.
12394 * stub-objc.c (objc_finish_foreach_loop): New.
12395
12396 2010-10-05 Joseph Myers <joseph@codesourcery.com>
12397
12398 * c-common.h (struct diagnostic_context): Don't declare here.
12399 (c_common_initialize_diagnostics): Declare using
12400 diagnostic_context typedef.
12401 * c-opts.c (c_common_handle_option): Pass global_dc to
12402 handle_generated_option.
12403
12404 2010-10-04 Joseph Myers <joseph@codesourcery.com>
12405
12406 * c-opts.c (c_common_handle_option): Pass &global_options_set to
12407 handle_generated_option.
12408
12409 2010-10-03 Ian Lance Taylor <iant@google.com>
12410
12411 * c.opt (-fplan9-extensions): New option.
12412
12413 2010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
12414
12415 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
12416 Remove.
12417 (c_cpp_builtins): Call functions from cppbuiltin.c instead
12418 of duplicating code.
12419
12420 2010-09-30 Iain Sandoe <iains@gcc.gnu.org>
12421
12422 * c-common.c: Add two new entries for @optional
12423 and @required keywords.
12424
12425 merge from FSF 'apple/trunk' branch.
12426 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
12427
12428 Radar 4386773
12429 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
12430 objective-c keywords.
12431 (objc_set_method_opt): New declaration.
12432 * stub-objc.c (objc_set_method_opt): New stub.
12433
12434 2010-09-30 Joseph Myers <joseph@codesourcery.com>
12435
12436 * c-common.c (handle_optimize_attribute): Pass &global_options to
12437 cl_optimization_save and cl_optimization_restore.
12438 * c-opts.c (c_common_handle_option): Pass &global_options to
12439 handle_generated_option.
12440 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
12441 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
12442 &global_options to cl_optimization_restore.
12443
12444 2010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
12445
12446 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
12447 Objective-C/Objective-C++ keywords.
12448
12449 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
12450
12451 Merge from 'apple/trunk' branch on FSF servers.
12452
12453 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
12454
12455 Radar 4281748
12456 * c-common.h (objc_check_global_decl): New declaration.
12457 * stub-objc.c (objc_check_global_decl): New stub.
12458
12459 2010-09-29 Joseph Myers <joseph@codesourcery.com>
12460
12461 * c.opt: Don't use VarExists.
12462
12463 2010-09-29 Joseph Myers <joseph@codesourcery.com>
12464
12465 * c-common.c (c_cpp_error): Update names of diagnostic_context
12466 members.
12467 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
12468 cl_optimization members.
12469 * c-opts.c (warning_as_error_callback, c_common_handle_option,
12470 sanitize_cpp_opts, finish_options): Update names of cpp_options
12471 members.
12472
12473 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
12474
12475 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
12476 (objc_is_reserved_word): Removed.
12477 * c-common.c: Updated comments.
12478 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
12479 objc_is_reserved_word.
12480 * stub-objc.c (objc_is_reserved_word): Removed.
12481
12482 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
12483
12484 * c-common.h (objc_add_method_declaration): Adjust prototype to
12485 include attributes.
12486 (objc_start_method_definition): Likewise.
12487 (objc_build_keyword_decl): Likewise.
12488 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
12489 (objc_start_method_definition): Likewise.
12490 (objc_build_keyword_decl): Likewise.
12491
12492 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
12493
12494 * c-common.h (objc_start_class_interface): Adjust prototype.
12495 (objc_start_category_interface): Likewise.
12496 (objc_start_protocol): Likewise.
12497 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
12498 (objc_start_class_interface): Likewise.
12499 (objc_start_category_interface): Likewise.
12500
12501 2010-09-27 Ian Lance Taylor <iant@google.com>
12502
12503 * c-common.c (c_common_attribute_table): Add no_split_stack.
12504 (handle_no_split_stack_attribute): New static function.
12505
12506 2010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
12507
12508 Merge from 'apple/trunk' branch on FSF servers.
12509
12510 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
12511
12512 Radar 4229905
12513 * c-common.h (objc_have_common_type): New declaration.
12514 * stub-objc.c (objc_have_common_type): New stub.
12515
12516 2005-06-22 Ziemowit Laski <zlaski@apple.com>
12517
12518 Radar 4154928
12519 * c-common.h (objc_common_type): New prototype.
12520 * stub-objc.c (objc_common_type): New stub.
12521
12522 2010-09-24 Jan Hubicka <jh@suse.cz>
12523
12524 * c-common.c (handle_leaf_attribute): New function.
12525 (struct attribute_spec c_common_att): Add leaf.
12526
12527 2010-09-22 Joseph Myers <joseph@codesourcery.com>
12528
12529 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
12530 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
12531 -dump, -dump=, -imacros, -imacros=, -include, -include=,
12532 -include-barrier, -include-directory, -include-directory=,
12533 -include-directory-after, -include-directory-after=,
12534 -include-prefix, -include-prefix=, -include-with-prefix,
12535 -include-with-prefix=, -include-with-prefix-after,
12536 -include-with-prefix-after=, -include-with-prefix-before,
12537 -include-with-prefix-before=, -no-integrated-cpp,
12538 -no-line-commands, -no-standard-includes, -no-warnings, -output,
12539 -output=, -pedantic, -pedantic-errors, -preprocess,
12540 -print-missing-file-dependencies, -trace-includes, -traditional,
12541 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
12542 -user-dependencies, -verbose, -write-dependencies,
12543 -write-user-dependencies, no-integrated-cpp, traditional): New.
12544
12545 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
12546
12547 PR objc/23710
12548 * c-common.h (objc_start_method_definition): Return bool instead
12549 of void.
12550 * stub-objc.c (objc_start_method_definition): Return bool instead
12551 of void.
12552
12553 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
12554
12555 PR objc/25965
12556 * c-common.h (objc_get_interface_ivars): New declaration.
12557 * stub-objc.c (objc_get_interface_ivars): New stub.
12558
12559 2010-09-15 Ian Lance Taylor <iant@google.com>
12560
12561 * c-common.c (parse_optimize_options): Do not capitalize warning
12562 messages. Remove period at end of warning message.
12563
12564 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12565
12566 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
12567 (handle_alias_attribute): ... here.
12568 (handle_ifunc_attribute): New.
12569
12570 2010-09-06 Mark Mitchell <mark@codesourcery.com>
12571
12572 * c-common.h (do_warn_double_promotion): Declare.
12573 * c-common.c (do_warn_double_promotion): Define.
12574
12575 2010-09-05 Mark Mitchell <mark@codesourcery.com>
12576
12577 * c.opt (Wdouble-promotion): New.
12578
12579 2010-09-02 Joseph Myers <joseph@codesourcery.com>
12580
12581 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
12582 fvtable-thunks, fxref): Mark no longer supported in help text.
12583
12584 2010-09-02 Joseph Myers <joseph@codesourcery.com>
12585
12586 * c.opt (Wimport, fall-virtual, falt-external-templates,
12587 fdefault-inline, fenum-int-equiv, fexternal-templates,
12588 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
12589 fname-mangling-version-, fnew-abi, fnonnull-objects,
12590 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
12591 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
12592 applicable.
12593 (fhandle-exceptions): Mark with Alias and Warn.
12594 * c-opts.c (c_common_handle_option): Don't handle options marked
12595 as ignored.
12596
12597 2010-09-02 Joseph Myers <joseph@codesourcery.com>
12598
12599 * c.opt (Wcomments, Werror-implicit-function-declaration,
12600 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
12601 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
12602 aliases.
12603 * c-common.c (option_codes): Use OPT_Wcomment instead of
12604 OPT_Wcomments.
12605 * c-opts.c (warning_as_error_callback, c_common_handle_option):
12606 Don't handle options marked as aliases.
12607
12608 2010-08-25 Richard Guenther <rguenther@suse.de>
12609
12610 * c-common.c (c_common_get_alias_set): Remove special
12611 handling for pointers.
12612
12613 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
12614
12615 * c-common.c: Use FOR_EACH_VEC_ELT.
12616 * c-gimplify.c: Likewise.
12617 * c-pragma.c: Likewise.
12618
12619 2010-08-16 Joseph Myers <joseph@codesourcery.com>
12620
12621 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
12622 RejectDriver.
12623 (MMDX): Change back to MMD. Mark NoDriverArg instead of
12624 RejectDriver.
12625 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
12626 instead of OPT_MDX and OPT_MMDX.
12627
12628 2010-08-16 Joseph Myers <joseph@codesourcery.com>
12629
12630 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
12631
12632 2010-08-12 Joseph Myers <joseph@codesourcery.com>
12633
12634 * c.opt (MD, MMD): Change to MDX and MMDX.
12635 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
12636
12637 2010-08-11 Joseph Myers <joseph@codesourcery.com>
12638
12639 * c-opts.c (c_common_handle_option): Call handle_generated_option
12640 instead of handle_option.
12641
12642 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
12643
12644 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
12645 (maybe_apply_renaming_pragma): Delete unneeded declarations.
12646
12647 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
12648
12649 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
12650 (pending_redefine_extname): Change type to a VEC.
12651 (add_to_renaming_pragma_list): Update for new type of
12652 pending_redefine_extname.
12653 (maybe_apply_renaming_pragma): Likewise.
12654
12655 2010-08-04 Arnaud Charlet <charlet@adacore.com>
12656
12657 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
12658 visited.
12659 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
12660 decide whether a type has already been declared/seen.
12661 Do not go to the original type.
12662 (dump_nested_types): New parameter forward.
12663 Generate forward declaration if needed and mark type as visited.
12664 (print_ada_declaration): Call dump_nested_types if not already done.
12665 Mark types as visited.
12666
12667 2010-08-03 Joseph Myers <joseph@codesourcery.com>
12668
12669 * c.opt (-print-pch-checksum): Remove option.
12670 * c-opts.c (c_common_handle_option): Don't handle
12671 OPT_print_pch_checksum.
12672
12673 2010-07-27 Joseph Myers <joseph@codesourcery.com>
12674
12675 * c-common.h (c_common_handle_option): Update prototype and return
12676 value type.
12677 * c-opts.c (c_common_handle_option): Update prototype and return
12678 value type. Update calls to handle_option and
12679 enable_warning_as_error.
12680
12681 2010-07-27 Jakub Jelinek <jakub@redhat.com>
12682
12683 PR c/45079
12684 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
12685
12686 2010-07-27 Joseph Myers <joseph@codesourcery.com>
12687
12688 * c-common.h (c_common_missing_argument): Remove.
12689 * c-opts.c (c_common_missing_argument): Remove.
12690 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
12691 idirafter, imacros, include, isysroot, isystem, iquote): Add
12692 MissingArgError.
12693 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
12694
12695 2010-07-27 Joseph Myers <joseph@codesourcery.com>
12696
12697 * c-common.h (c_common_option_lang_mask,
12698 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
12699 New.
12700 (c_common_init_options): Update prototype.
12701 * c-opts.c (c_common_option_lang_mask): New.
12702 (c_common_initialize_diagnostics): Split out of
12703 c_common_init_options.
12704 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
12705 New.
12706 (c_common_init_options): Update prototype. Use decoded options in
12707 search for -lang-asm.
12708
12709 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
12710
12711 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
12712 * c-format.c: Likewise.
12713
12714 2010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
12715
12716 * c-common.h: Include diagnostic-core.h. Error if already
12717 included.
12718 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
12719
12720 2010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
12721
12722 * c-common.c (IN_GCC_FRONTEND): Do not undef.
12723 Do not include expr.h
12724 (vector_mode_valid_p): Move here.
12725
12726 2010-06-21 DJ Delorie <dj@redhat.com>
12727
12728 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
12729 allow these pragmas anywhere.
12730
12731 2010-06-14 Jakub Jelinek <jakub@redhat.com>
12732
12733 PR bootstrap/44509
12734 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
12735 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
12736 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
12737 ggc_strdup instead of xstrdup.
12738
12739 2010-06-10 Jakub Jelinek <jakub@redhat.com>
12740
12741 * c-cppbuiltin.c: Include cpp-id-data.h.
12742 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
12743 (lazy_hex_fp_value): New function.
12744 (builtin_define_with_hex_fp_value): Provide definitions lazily.
12745
12746 2010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
12747
12748 * c-gimplify.c: Do not include tree-flow.h
12749
12750 2010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
12751
12752 PR other/44034
12753 * c-common.c: Rename targetm member:
12754 targetm.enum_va_list -> targetm.enum_va_list_p
12755
12756 2010-06-28 Anatoly Sokolov <aesok@post.ru>
12757
12758 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
12759
12760 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
12761
12762 * c-cppbuiltin.c: Do not include except.h.
12763
12764 2010-06-24 Andi Kleen <ak@linux.intel.com>
12765
12766 * c-common.c (warn_for_omitted_condop): New.
12767 * c-common.h (warn_for_omitted_condop): Add prototype.
12768
12769 2010-06-21 Joseph Myers <joseph@codesourcery.com>
12770
12771 * c.opt (lang-objc): Remove.
12772 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
12773
12774 2010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
12775
12776 * c-opts.c: Include "tm_p.h".
12777
12778 2010-06-20 Joseph Myers <joseph@codesourcery.com>
12779
12780 * c-common.c (parse_optimize_options): Update call to
12781 decode_options.
12782
12783 2010-06-18 Nathan Froyd <froydnj@codesourcery.com>
12784
12785 * c-common.c (record_types_used_by_current_var_decl): Adjust for
12786 new type of types_used_by_cur_var_decl.
12787
12788 2010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
12789
12790 PR bootstrap/44512
12791 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
12792 for C++ standard compliance.
12793
12794 2010-06-16 Jason Merrill <jason@redhat.com>
12795
12796 * c.opt: Add -Wnoexcept.
12797
12798 2010-06-16 Richard Guenther <rguenther@suse.de>
12799
12800 PR c/44555
12801 * c-common.c (c_common_truthvalue_conversion): Remove
12802 premature and wrong optimization concering ADDR_EXPRs.
12803
12804 2010-06-15 Arnaud Charlet <charlet@adacore.com>
12805
12806 * c-ada-spec.c (dump_sloc): Remove column info.
12807 (is_simple_enum): New function.
12808 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
12809 enum types when relevant.
12810
12811 2010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
12812
12813 * c-common.c (conversion_warning): Warn at expression
12814 location.
12815
12816 2010-06-10 Joseph Myers <joseph@codesourcery.com>
12817
12818 * c-opts.c (c_common_handle_option): Don't handle
12819 OPT_fshow_column.
12820
12821 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
12822
12823 * c-pragma.c (push_alignment): Use typed GC allocation.
12824 (handle_pragma_push_options): Likewise.
12825
12826 * c-common.c (parse_optimize_options): Likewise.
12827
12828 * c-common.h (struct sorted_fields_type): Add variable_size GTY
12829 option.
12830
12831 2010-06-07 Joseph Myers <joseph@codesourcery.com>
12832
12833 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
12834 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
12835 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
12836 flag_signed_bitfields, warn_strict_null_sentinel,
12837 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
12838 flag_gen_declaration, flag_no_gnu_keywords,
12839 flag_implement_inlines, flag_implicit_templates,
12840 flag_implicit_inline_templates, flag_optional_diags,
12841 flag_elide_constructors, flag_default_inline, flag_rtti,
12842 flag_conserve_space, flag_access_control, flag_check_new,
12843 flag_new_for_scope, flag_weak, flag_working_directory,
12844 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
12845 flag_enforce_eh_specs, flag_threadsafe_statics,
12846 flag_pretty_templates): Remove.
12847 * c-common.h (flag_preprocess_only, flag_nil_receivers,
12848 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
12849 flag_replace_objc_classes, flag_undef, flag_no_builtin,
12850 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
12851 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
12852 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
12853 flag_no_gnu_keywords, flag_implement_inlines,
12854 flag_implicit_templates, flag_implicit_inline_templates,
12855 flag_optional_diags, flag_elide_constructors, flag_default_inline,
12856 flag_rtti, flag_conserve_space, flag_access_control,
12857 flag_check_new, flag_new_for_scope, flag_weak,
12858 flag_working_directory, flag_use_cxa_atexit,
12859 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
12860 flag_threadsafe_statics, flag_pretty_templates,
12861 warn_strict_null_sentinel): Remove.
12862 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
12863 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
12864 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
12865 fimplicit-inline-templates, fimplicit-templates,
12866 flax-vector-conversions, fms-extensions, fnil-receivers,
12867 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
12868 frtti, fshort-double, fshort-enums, fshort-wchar,
12869 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
12870 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
12871 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
12872 gen-decls, undef): Use Var.
12873 (fdefault-inline, foptional-diags): Document as doing nothing.
12874 * c-opts.c (c_common_handle_option): Remove cases for options now
12875 using Var. Mark ignored options as such.
12876
12877 2010-06-05 Steven Bosscher <steven@gcc.gnu.org>
12878
12879 * c-common.c: Moved to here from parent directory.
12880 * c-common.def: Likewise.
12881 * c-common.h: Likewise.
12882 * c-cppbuiltin.c: Likewise.
12883 * c-dump.c: Likewise.
12884 * c-format.c: Likewise.
12885 * c-format.h : Likewise.
12886 * c-gimplify.c: Likewise.
12887 * c-lex.c: Likewise.
12888 * c-omp.c: Likewise.
12889 * c.opt: Likewise.
12890 * c-opts.c: Likewise.
12891 * c-pch.c: Likewise.
12892 * c-ppoutput.c: Likewise.
12893 * c-pragma.c: Likewise.
12894 * c-pragma.h: Likewise.
12895 * c-pretty-print.c: Likewise.
12896 * c-pretty-print.h: Likewise.
12897 * c-semantics.c: Likewise.
12898 * stub-objc.c: Likewise.
12899
12900 * c-common.c: Include gt-c-family-c-common.h.
12901 * c-pragma.c: Include gt-c-family-c-pragma.h.
12902 \f
12903 Copyright (C) 2010-2022 Free Software Foundation, Inc.
12904
12905 Copying and distribution of this file, with or without modification,
12906 are permitted in any medium without royalty provided the copyright
12907 notice and this notice are preserved.