]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c-family/ChangeLog
* libiberty.h (ASTRDUP): Adjust cast to avoid warning.
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
CommitLineData
645b0f8d 12017-05-24 Martin Sebor <msebor@redhat.com>
2
3 PR c/80731
4 * c-common.h (unsafe_conversion_p): Add a function argument.
5 * c-common.c (unsafe_conversion_p): Same.
6 Add type names and values to diagnostics.
7 (scalar_to_vector): Adjust.
8 * c-warn.c (constant_expression_error): Add a function argument.
9 Add type names and values to diagnostics.
10 (conversion_warning): Add a function argument.
11 Add type names and values to diagnostics.
12 (warnings_for_convert_and_check): Same.
13
65fb3b5b 142017-05-19 Jason Merrill <jason@redhat.com>
15
16 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
17 enumerators.
18
5407f1e9 192017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
20
21 * c-format.c (locus): Move out of function scope,
22 add GTY attribute.
23
0fa326f5 242017-05-19 Nathan Sidwell <nathan@acm.org>
25
26 * c-opts.c (class_dump_file, class_dump_flags): Delete.
27 (c_common_parse_file): Remove class dump handling.
28 (get_dump_info): Likewise.
29
195b31a0 302017-05-19 Richard Biener <rguenther@suse.de>
31
32 PR c++/80593
33 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
34 to alias-set zero memory.
35
1bccae6b 362017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
37
38 * c-format.c (local_tree_type_node): Add GTY attribute.
39
78173203 402017-05-18 Marek Polacek <polacek@redhat.com>
41
42 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
43 (c_common_fixed_point_type_for_size): Likewise.
44 (c_common_type_for_mode): Likewise.
45 (shorten_compare): Likewise.
46 (c_promoting_integer_type_p): Use false/true instead of 0/1.
47 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
48
2823920b 492017-05-18 Marek Polacek <polacek@redhat.com>
50
51 * c-common.c (self_promoting_args_p): Change the return type to bool.
52 Use false/true instead of 0/1.
53 * c-common.h (self_promoting_args_p): Update.
54
72749341 552017-05-17 Marek Polacek <polacek@redhat.com>
56
57 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
58 * c-warn.c: Likewise.
59
b4d90ee2 602017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
61
62 Implement new C++ intrinsics __is_assignable and __is_constructible.
63 * c-common.c (__is_assignable, __is_constructible): New.
64 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
65
3f6e5ced 662017-05-17 Martin Liska <mliska@suse.cz>
67
68 * c-common.h: Introduce dump_flags_t type and
69 use it instead of int type.
70 * c-gimplify.c (c_genericize): Likewise.
71 * c-opts.c: Likewise.
72
d0869ea4 732017-05-17 Marek Polacek <polacek@redhat.com>
74
75 * c-common.c (c_save_expr): Remove.
76 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
77 * c-common.h (c_save_expr): Remove declaration.
78
0d7b4486 792017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
80
81 PR c/35441
82 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
83 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
84 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
85 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
86 RDIV_EXPR.
87 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
88
1a2d3e8e 892017-05-09 Marek Polacek <polacek@redhat.com>
90
91 PR c/80525
92 * c-warn.c (unwrap_c_maybe_const): New.
93 (warn_logical_operator): Call it.
94
cdf05a3f 952017-05-09 Nathan Sidwell <nathan@acm.org>
96
97 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
98 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
99
554efdbb 1002017-05-08 Martin Sebor <msebor@redhat.com>
101
102 PR translation/80280
103 * c-format.h (struct format_flag_spec): Add new member.
104 (T89_T): New macro.
105 * c-format.c (local_tree_type_node): New global.
106 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
107 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
108 (strfmon_flag_specs): Likewise.
109 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
110 with distinct quoting properties.
111 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
112 (flag_chars_t::validate): Add argument and handle bad quoting.
113 (check_format_info_main): Handle quoting problems.
114 (init_dynamic_diag_info): Simplify.
115
7344fb00 1162017-05-08 Jason Merrill <jason@redhat.com>
117
118 * c-opts.c (c_common_post_options): Update defaults for
119 flag_abi_version and flag_abi_compat_version.
120
56b8400f 1212017-05-05 David Malcolm <dmalcolm@redhat.com>
122
123 * c-common.c (c_cpp_error): Replace report_diagnostic
124 with diagnostic_report_diagnostic.
125
8c41abe8 1262017-05-04 Martin Sebor <msebor@redhat.com>
127
128 PR translation/80280
129 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
130 (handle_weakref_attribute): Same.
131
a06321ef 1322017-05-03 Nathan Sidwell <nathan@acm.org>
133
134 Canonicalize canonical type hashing
135 * c-common.c (complete_array_type): Use type_hash_canon.
136
92bc38e7 1372017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
138
139 PR c++/80038
140 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
141 prototype.
142 (cilk_install_body_pedigree_operations): Likewise.
143 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
144 detatched.
145 (cilk_gimplify_call_params_in_spawned_fn): Remove.
146 (cilk_install_body_pedigree_operations): Likewise.
147 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
148 unwrapping.
149
fb8ab1f8 1502017-04-27 Jakub Jelinek <jakub@redhat.com>
151
152 PR c++/80534
153 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
154 flag on non-aggregate element types.
155
31af80fe 1562017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
157
158 * c-common.c (c_type_hasher, type_hash_table): Remove.
159 (c_common_get_alias_set): Remove unreachable code.
160 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
161
dc993150 1622017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
163
164 * c.opt (Wextra-semi): New C++ warning flag.
165
6bac87c3 1662017-04-20 Jakub Jelinek <jakub@redhat.com>
167
168 PR middle-end/80423
169 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
170
7ec2cbc9 1712017-04-18 Jakub Jelinek <jakub@redhat.com>
172
173 PR middle-end/79788
174 PR middle-end/80375
175 * c-common.c (c_common_type_for_mode): Don't handle
176 widest_*_literal_type_node here.
177 c_common_signed_or_unsigned_type): Likewise.
178 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
179 to *intTI_type_node or *intDI_type_node depending on whether
180 TImode is supported by the target or not.
181
65b66772 1822017-04-10 Martin Liska <mliska@suse.cz>
183
184 PR sanitizer/80350
185 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
186 doing an UBSAN check.
187
2fbe7a32 1882017-04-03 Jonathan Wakely <jwakely@redhat.com>
189
190 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
191
3ddb3278 1922017-03-31 Jakub Jelinek <jakub@redhat.com>
193
194 PR c++/79572
195 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
196 tree *.
197 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
198 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
199 REFERENCE_TYPE.
200
9511b9de 2012017-03-31 David Malcolm <dmalcolm@redhat.com>
202
203 PR documentation/78732
204 * c.opt (Wendif-labels): Fix description to refer to
205 #else rather than #elif.
206
ca2af7df 2072017-03-31 Jakub Jelinek <jakub@redhat.com>
208
209 PR libstdc++/80251
210 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
211 * c-common.c (c_common_reswords): Add __is_aggregate trait.
212
3385a573 2132017-03-27 Jakub Jelinek <jakub@redhat.com>
214
215 PR middle-end/80162
216 * c-common.c (c_common_mark_addressable_vec): Don't set
217 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
218
da7a26fc 2192017-03-21 Martin Sebor <msebor@redhat.com>
220
221 PR c++/79548
222 * c-common.c (set_underlying_type): Mark type used only when
223 original del is declared unused.
224
ca1f4c7a 2252017-03-10 David Malcolm <dmalcolm@redhat.com>
226
227 PR translation/79848
228 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
229 "%qs".
230
3b496eb9 2312017-03-10 David Malcolm <dmalcolm@redhat.com>
232
233 PR c/79921
234 * c-indentation.c (warn_for_misleading_indentation): Remove parens
235 from inform's message, so that xgettext can locate it.
236
6a9c24a0 2372017-03-09 Marek Polacek <polacek@redhat.com>
238
239 PR c++/79962
240 PR c++/79984
241 * c-attribs.c (handle_nonnull_attribute): Save the result of default
242 conversion to the attribute list.
243
5383272d 2442017-03-09 Martin Liska <mliska@suse.cz>
245
246 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
247
957a727b 2482017-03-03 Jason Merrill <jason@redhat.com>
249
250 * c.opt (Wnoexcept-type): New.
251
b977a7e3 2522017-03-02 Richard Biener <rguenther@suse.de>
253
254 PR c/79756
255 * c-common.c (c_common_mark_addressable_vec): Look through
256 C_MAYBE_CONST_EXPR.
257
78adba87 2582017-02-28 Martin Liska <mliska@suse.cz>
259
260 * c.opt: Replace space with tabular for options of <number>
261 type.
262
6ac368bb 2632017-02-28 Martin Liska <mliska@suse.cz>
264
265 * c.opt: Fix --help=option -Q for options which are of
266 an enum type.
267
bbd5521e 2682017-02-24 Jakub Jelinek <jakub@redhat.com>
269
270 PR c++/79588
271 * c-common.c (check_function_restrict): New function.
272 (check_function_arguments): Add FNDECL argument. Call
273 check_function_restrict if -Wrestrict.
274 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
275 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
276 * c-common.h (check_function_arguments): Add FNDECL argument.
277 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
278
e967bbfd 2792017-02-24 Eric Botcazou <ebotcazou@adacore.com>
280
281 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
282 treatment of parameters with pointer-to-tagged type and tidy up.
283 (print_ada_methods): Remove the special treatment of C++ static member
284 functions.
285
52ccf715 2862017-02-22 Martin Liska <mliska@suse.cz>
287
288 * c.opt: Replace inequality signs with square brackets
289 for -Wnornalized.
290
a42e4e13 2912017-02-21 Jakub Jelinek <jakub@redhat.com>
292
293 PR c++/79641
294 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
295 preserve quals.
296
f6202e1a 2972017-02-17 Joseph Myers <joseph@codesourcery.com>
298
299 * c-cppbuiltin.c (builtin_define_float_constants): Define
300 __DECIMAL_DIG__ to the value for long double.
301
0396f790 3022017-02-15 Marek Polacek <polacek@redhat.com>
303
304 PR c/79515
305 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
306 conversion has occured.
307
175e0d6b 3082017-01-24 David Malcolm <dmalcolm@redhat.com>
309
310 * c-common.c (c_common_reswords): Add "__RTL".
311 * c-common.h (enum rid): Add RID_RTL.
312
3ef7eab1 3132017-01-20 Marek Polacek <polacek@redhat.com>
314
315 PR c/64279
316 * c-common.h (do_warn_duplicated_branches_r): Declare.
317 * c-gimplify.c (c_genericize): Walk the function tree calling
318 do_warn_duplicated_branches_r.
319 * c-warn.c (expr_from_macro_expansion_r): New.
320 (do_warn_duplicated_branches): New.
321 (do_warn_duplicated_branches_r): New.
322 * c.opt (Wduplicated-branches): New option.
323
32641de7 3242017-01-17 David Malcolm <dmalcolm@redhat.com>
325
326 PR c++/71497
327 * c-indentation.c (warn_for_misleading_indentation): Use the past
328 subjunctive in the note.
329
7e66f344 3302017-01-17 Aldy Hernandez <aldyh@redhat.com>
331
332 PR c/79116
333 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
334 start type to integer_type.
335
14234f77 3362017-01-16 Jakub Jelinek <jakub@redhat.com>
337
338 PR driver/49726
339 * c.opt (gen-decls): Add Driver flag.
340
ba5a0dd7 3412017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
342
343 Revert:
344 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
345
346 PR c++/71737
347 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
348
231589de 3492017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
350
351 PR c++/71737
352 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
353
78cf39ca 3542017-01-12 Martin Sebor <msebor@redhat.com>
355
356 (-Wformat-overflow): ...to this.
357
1a1ce9a6 3582017-01-11 Martin Sebor <msebor@redhat.com>
359
360 PR c/78768
361 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
362 Also enable for LTO.
363
3386344d 3642017-01-10 Jason Merrill <jason@redhat.com>
365
366 Implement P0195R2, C++17 variadic using.
367 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
368
d0abd9e0 3692017-01-09 Jakub Jelinek <jakub@redhat.com>
370
371 PR translation/79019
372 PR translation/79020
373 * c.opt (Wnormalized=): Fix typo in description.
374
aba01341 3752017-01-08 Martin Sebor <msebor@redhat.com>
376
377 PR middle-end/77708
378 * c.opt (-Wformat-truncation): New option.
379
2792c2c7 3802017-01-06 Alexandre Oliva <aoliva@redhat.com>
381
382 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
383 value to unsigned short to fit in 4 hex digits without
384 warnings.
385
3389a464 3862017-01-05 Eric Botcazou <ebotcazou@adacore.com>
387
388 * c.opt (fsso-struct): Add 'native' value.
389
f6deeb21 3902017-01-05 Martin Liska <mliska@suse.cz>
391
392 PR pch/78970
393 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
394 header.
395
6124217c 3962017-01-04 Marek Polacek <polacek@redhat.com>
397
398 PR c++/64767
399 * c.opt (Wpointer-compare): New option.
400
48284845 4012017-01-04 Jakub Jelinek <jakub@redhat.com>
402
403 PR driver/78957
404 * c.opt (fsso-struct=): Add RejectNegative.
405
aad93da1 4062017-01-01 Jakub Jelinek <jakub@redhat.com>
407
408 Update copyright years.
409
7dbe2449 4102016-12-29 Martin Liska <mliska@suse.cz>
411
412 PR c/78933
413 * c.opt (strong-eval-order): Add RejectNegative keyword.
414
23ea3d01 4152016-12-22 Jason Merrill <jason@redhat.com>
416
417 Implement P0522R0, matching of template template arguments.
418 * c-cppbuiltin.c (c_cpp_builtins): Define
419 __cpp_template_template_args.
420
184fac50 4212016-12-21 Jakub Jelinek <jakub@redhat.com>
422
423 PR bootstrap/78817
424 * c-common.c (struct nonnull_arg_ctx): New type.
425 (check_function_nonnull): Return bool instead of void. Use
426 nonnull_arg_ctx as context rather than just location_t.
427 (check_nonnull_arg): Adjust for the new context type, set
428 warned_p to true if a warning has been diagnosed.
429 (check_function_arguments): Return bool instead of void.
430 * c-common.h (check_function_arguments): Adjust prototype.
431
7806e079 4322016-12-21 Jason Merrill <jason@redhat.com>
433
434 * c.opt (-fnew-ttp-matching): New flag.
435 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
436
4954efd4 4372016-12-14 Martin Jambor <mjambor@suse.cz>
438
439 * c-omp.c: Include omp-general.h instead of omp-low.h.
440 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
441 name.
442
5cfa3fc8 4432016-12-14 Martin Sebor <msebor@redhat.com>
444
445 PR c/17308
446 * c-common.c (check_nonnull_arg): Disable when optimization
447 is enabled.
448
bbdce47f 4492016-12-12 Marek Polacek <polacek@redhat.com>
450
451 PR c++/78647
452 * c-common.c (attribute_fallthrough_p): Return false for
453 error_mark_node.
454
370e45b9 4552016-12-08 Martin Sebor <msebor@redhat.com>
456
457 PR c/78284
458 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
459
3bb246b3 4602016-12-08 Martin Sebor <msebor@redhat.com>
461
462 PR c/78165
3199a7fa 463 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
464 suffix.
3bb246b3 465
5aef8938 4662016-12-07 Martin Sebor <msebor@redhat.com>
467
468 PR c/53562
469 PR middle-end/77784
470 PR middle-end/78149
471 PR middle-end/78138
472 * c.opt (-Wstringop-overflow): New option.
473
47c3d0de 4742016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
475
476 * c-attribs.c (asan odr indicator): New attribute.
477 (handle_asan_odr_indicator_attribute): New function.
478
c932c990 4792016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
480
481 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
482 ptrdiff_type_node;
483
c39beb8a 4842016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
485
486 * c-common.c (excess_precision_mode_join): New.
487 (c_ts18661_flt_eval_method): New.
488 (c_c11_flt_eval_method): Likewise.
489 (c_flt_eval_method): Likewise.
490 * c-common.h (excess_precision_mode_join): New.
491 (c_flt_eval_method): Likewise.
492 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
493 (cpp_iec_559_value): Call it.
494 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
495 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
496 __FLT_EVAL_METHOD_TS_18661_3__.
497
a998ac00 4982016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
499
500 * c-opts.c (c_common_post_options): Add logic to handle the default
501 case for -fpermitted-flt-eval-methods.
502
6e47b422 5032016-11-23 Paolo Bonzini <bonzini@gnu.org>
504
505 * c.opt (Wexpansion-to-defined): New.
506
0d65cc6c 5072016-11-23 Jakub Jelinek <jakub@redhat.com>
508
509 PR target/78451
510 * c-pragma.c (handle_pragma_target): Don't replace
511 current_target_pragma, but chainon the new args to the current one.
512
ff6497a3 5132016-11-22 Nathan Sidwell <nathan@acm.org>
514
515 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
bacc5324 516 indentation and formatting.
ff6497a3 517
13341287 5182016-11-21 Martin Sebor <msebor@redhat.com>
519
520 * c.opt (-fprintf-return-value): Enable by default.
521
f1b3e1c9 5222016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
523
524 PR c++/71973
525 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
526 * c-common.c (c_common_nodes_and_builtins): Initialize
527 const_tm_ptr_type_node.
528
6c1f90ee 5292016-11-16 Marek Polacek <polacek@redhat.com>
530
531 PR c/78285
532 * c-common.c (c_add_case_label): Turn error_at calls into inform.
533
a49621cf 5342016-11-14 Jakub Jelinek <jakub@redhat.com>
535
536 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
537
b1f04d34 5382016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
a49621cf 539 Richard Biener <rguenther@suse.de>
540
541 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
542 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
543 * c.opt (fgimple): New option.
b1f04d34 544
9b8f3aa1 5452016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
546
547 PR c/35503
548 * c-common.h (warn_for_restrict): Declare.
549 * c-warn.c: Include gcc-rich-location.h.
550 (warn_for_restrict): New function.
551 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
552 (gcc_cdiag_char_table): Likewise.
553 (gcc_cxxdiag_char_table): Likewise.
554 * c.opt (Wrestrict): New option.
555
7907d43b 5562016-11-13 Eric Botcazou <ebotcazou@adacore.com>
557
558 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
559 for nested types only if the type is a record or union and dump SLOC.
560
b1363399 5612016-11-09 Jason Merrill <jason@redhat.com>
562
563 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
564
58721d0c 5652016-11-09 Jakub Jelinek <jakub@redhat.com>
566
567 * c-ubsan.c (ubsan_instrument_shift): Handle split
568 -fsanitize=shift-base and -fsanitize=shift-exponent.
569
2e9e9363 5702016-11-07 Jason Merrill <jason@redhat.com>
571
572 * c.opt (Wc++1z-compat): New.
573 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
574
629b6abc 5752016-11-07 Martin Liska <mliska@suse.cz>
576
577 * c-warn.c (warn_for_unused_label): Save all labels used
578 in goto or in &label.
579
2f1c4c07 5802016-11-03 Jason Merrill <jason@redhat.com>
581
582 * c-cppbuiltin.c (c_cpp_builtins): Correct
583 __cpp_inheriting_constructors.
584
7896267d 5852016-11-01 Jason Merrill <jason@redhat.com>
586
02a9e65f 587 * c-cppbuiltin.c (c_cpp_builtins): Update
588 __cpp_inheriting_constructors.
589
7896267d 590 * c.opt (-fnew-inheriting-ctors): New.
591 * c-opts.c: Default to on for ABI 11+.
592
f6f44a1d 5932016-10-31 Jakub Jelinek <jakub@redhat.com>
594
595 PR c++/77948
596 * c.opt (fext-numeric-literals): Add Var and Init.
597 * c-opts.c (c_common_handle_option): Don't clear
598 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
599 (c_common_post_options): Clear it here if not set
600 explicitly.
601
d24c4079 6022016-10-28 Aldy Hernandez <aldyh@redhat.com>
603
604 PR debug/77773
605 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
606 if NULL.
607
6e1b2ffb 6082016-10-25 Jakub Jelinek <jakub@redhat.com>
609
610 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
611 * c-common.c (c_common_reswords): Add __builtin_launder.
612
5f64e688 6132016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
614
615 * c-common.c (c_common_truthvalue_conversion): Warn for
616 multiplications in boolean context. Fix the quoting of '<<' and '<'
617 in the shift warning.
618
3645e924 6192016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
620
621 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
622
146cbd63 6232016-10-20 Jason Merrill <jason@redhat.com>
624
625 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
626
5c2ba578 6272016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
628
629 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
630 integer shift ops in boolean context.
631
6322016-10-18 Aldy Hernandez <aldyh@redhat.com>
da6cf191 633
634 * c.opt (Walloca): New.
635 (Walloca-larger-than=): New.
636 (Wvla-larger-than=): New.
637
876d4bc9 6382016-10-17 Marek Polacek <polacek@redhat.com>
639
640 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
641 Return immediately when finding a match.
642 (warn_tautological_cmp): Remove a boolean variable that is no longer
643 needed.
644
b0c98c23 6452016-10-17 Marek Polacek <polacek@redhat.com>
646
647 * c-attribs.c: New file.
648 * c-common.c: Move attributes handling to c-attribs.c.
649 (get_nonnull_operand): No longer static.
650 * c-common.h: Move the declarations from c-attribs.c to its own section.
651
2ab6420c 6522016-10-14 Jason Merrill <jason@redhat.com>
653
654 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
655 and __cpp_deduction_guides.
656
81f19d90 6572016-10-13 Jason Merrill <jason@redhat.com>
658
659 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
660
ad7b10a2 6612016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
662
663 * c-cppbuiltin.c: Include memmodel.h.
664 * c-opts.c: Likewise.
665 * c-pragma.c: Likewise.
666 * c-warn.c: Likewise.
667
12663602 6682016-10-12 Jakub Jelinek <jakub@redhat.com>
669
670 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
671 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
672 * c-opts.c (sanitize_cpp_opts): Initialize
673 cpp_opts->cpp_warn_implicit_fallthrough.
674
424b2d7d 6752016-10-11 Marek Polacek <polacek@redhat.com>
676
677 * c-common.c (warning_candidate_p): Change the return type to bool
678 and return true/false instead of 1/0.
679 (vector_mode_valid_p): Likewise.
680
0f4cea33 6812016-10-11 Marek Polacek <polacek@redhat.com>
682
683 * c-common.c (fold_for_warn): No longer static.
684 (bool_promoted_to_int_p): Likewise.
685 (c_common_get_narrower): Likewise.
686 (constant_expression_warning): Move to c-warn.c.
687 (constant_expression_error): Likewise.
688 (overflow_warning): Likewise.
689 (warn_logical_operator): Likewise.
690 (find_array_ref_with_const_idx_r): Likewise.
691 (warn_tautological_cmp): Likewise.
692 (expr_has_boolean_operands_p): Likewise.
693 (warn_logical_not_parentheses): Likewise.
694 (warn_if_unused_value): Likewise.
695 (strict_aliasing_warning): Likewise.
696 (sizeof_pointer_memaccess_warning): Likewise.
697 (check_main_parameter_types): Likewise.
698 (conversion_warning): Likewise.
699 (warnings_for_convert_and_check): Likewise.
700 (match_case_to_enum_1): Likewise.
701 (match_case_to_enum): Likewise.
702 (c_do_switch_warnings): Likewise.
703 (warn_for_omitted_condop): Likewise.
704 (readonly_error): Likewise.
705 (lvalue_error): Likewise.
706 (invalid_indirection_error): Likewise.
707 (warn_array_subscript_with_type_char): Likewise.
708 (warn_about_parentheses): Likewise.
709 (warn_for_unused_label): Likewise.
710 (warn_for_div_by_zero): Likewise.
711 (warn_for_memset): Likewise.
712 (warn_for_sign_compare): Likewise.
713 (do_warn_double_promotion): Likewise.
714 (do_warn_unused_parameter): Likewise.
715 (record_locally_defined_typedef): Likewise.
716 (maybe_record_typedef_use): Likewise.
717 (maybe_warn_unused_local_typedefs): Likewise.
718 (maybe_warn_bool_compare): Likewise.
719 (maybe_warn_shift_overflow): Likewise.
720 (warn_duplicated_cond_add_or_warn): Likewise.
721 (diagnose_mismatched_attributes): Likewise.
722 * c-common.h: Move the declarations from c-warn.c to its own section.
723 * c-warn.c: New file.
724
7a7ca07c 7252016-10-08 Jason Merrill <jason@redhat.com>
726
727 * c-common.c (c_common_truthvalue_conversion): Don't distribute
728 into COND_EXPR in C++.
729
ad0c1dec 7302016-10-08 Jakub Jelinek <jakub@redhat.com>
731
732 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
733 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
734 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
735
cd45162d 7362016-10-07 Jakub Jelinek <jakub@redhat.com>
737
738 Implement LWG2296 helper intrinsic
739 * c-common.h (enum rid): Add RID_ADDRESSOF.
740 * c-common.c (c_common_reswords): Add __builtin_addressof.
741
0365bfa8 7422016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
743
744 PR c++/77700
745 * c-common.c (c_common_truthvalue_conversion): Warn also for
746 suspicious enum values in boolean context.
747
adeca879 7482016-10-06 Jakub Jelinek <jakub@redhat.com>
749
750 Implement P0258R2 - helper for C++17
751 std::has_unique_object_representations trait
752 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
753 * c-common.c (c_common_reswords): Add
754 __has_unique_object_representations.
755
c6958264 7562016-10-05 Jakub Jelinek <jakub@redhat.com>
757
758 PR sanitizer/66343
759 * c-ubsan.c (ubsan_instrument_return): Don't call
760 initialize_sanitizer_builtins here.
761
2b6903a5 7622016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
763
764 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
765 conditional expression in boolean context when only one arm is
766 non-boolean.
767
5c176ebe 7682016-10-05 Jakub Jelinek <jakub@redhat.com>
769
c7b01e77 770 PR sanitizer/77823
771 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
772 is not integral.
773
5c176ebe 774 * c-common.c (c_common_reswords): Update comment for C++11.
775
492ab670 7762016-10-04 Jason Merrill <jason@redhat.com>
777
778 * c-common.c (make_tree_vector_from_ctor): New.
779 * c-common.h: Declare it.
780
bc6b11a7 7812016-10-04 Jakub Jelinek <jakub@redhat.com>
782
783 * c-cppbuiltin.c (c_cpp_builtins): Don't define
784 __LIBGCC_JCR_SECTION_NAME__.
785
255beb07 7862016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
787
788 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
789 left shift in boolean context.
790
c5d89bae 7912016-09-29 Jakub Jelinek <jakub@redhat.com>
792
793 Implement P0001R1 - C++17 removal of register storage class specifier
794 * c.opt (Wregister): New warning.
795 * c-opts.c (c_common_post_options): Enable -Wregister by
796 default for C++17.
797
4267ed07 7982016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
799
800 * c-opts.c (c_common_post_options): Remove special case for
801 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
802 in C++.
803
0b72b025 8042016-09-27 Jakub Jelinek <jakub@redhat.com>
805
4fd4e9e0 806 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
807 -std=c++1z.
808
0b72b025 809 * c-ada-spec.c (print_ada_declaration): Remove break after return.
810
ea36272b 8112016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
812
813 * c-common.c: Include memmodel.h.
814
e997bd3a 8152016-09-26 Marek Polacek <polacek@redhat.com>
816
817 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
818
3c77f69c 8192016-09-26 Marek Polacek <polacek@redhat.com>
820
821 PR c/7652
822 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
823 (handle_fallthrough_attribute): New function.
824 (attribute_fallthrough_p): New function.
825 * c-common.h (attribute_fallthrough_p): Declare.
826
481ce481 8272016-09-24 Marek Polacek <polacek@redhat.com>
828
829 PR c/77490
830 * c.opt (Wbool-operation): New.
831
a5fe0b37 8322016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
833
834 * c-common.c (c_common_truthvalue_conversion): Inhibit
835 Wint-in-bool-context warning with from_macro_definition_at.
836 Mention the expression will always evaluate to true.
837
90f40f08 8382016-09-21 Martin Sebor <msebor@redhat.com>
839
840 PR bootstrap/77676
841 * c.opt (fprintf-return-value): Temporarily initialize to zero
842 to unblock bootstrap failures.
843
98aa0f57 8442016-09-21 Jakub Jelinek <jakub@redhat.com>
845
846 PR c++/77651
847 * c.opt (Waligned-new=): Add RejectNegative.
848 (faligned-new=): Likewise. Spelling fix - change
849 aligned_new_threshhold to aligned_new_threshold.
850 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
851 to aligned_new_threshold.
852
b9833bfd 8532016-09-20 Martin Sebor <msebor@redhat.com>
854
855 PR middle-end/49905
856 * c.opt: Add -Wformat-length and -fprintf-return-value.
857
bed03df1 8582016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
859
860 PR c++/77434
861 * c.opt (Wint-in-bool-context): New warning.
862 * c-common.c (c_common_truthvalue_conversion): Warn on integer
863 constants in boolean context.
864
9b5c49ef 8652016-09-19 Joseph Myers <joseph@codesourcery.com>
866
867 * c-common.c (max_align_t_align): Also consider alignment of
868 float128_type_node.
869
cc4b5c58 8702016-09-15 Jason Merrill <jason@redhat.com>
871
872 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
873 DECL_EXTERNAL.
874
ef45c4c0 8752016-09-14 Jason Merrill <jason@redhat.com>
876
877 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
878 limit FIELD_DECL, either.
879
b99cc6da 8802016-09-14 Marek Polacek <polacek@redhat.com>
881
882 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
883 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
884 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
885
68ef907c 8862016-09-13 David Malcolm <dmalcolm@redhat.com>
887
888 * c-common.c (warn_logical_not_parentheses): Replace
889 rich_location::add_fixit_insert calls with add_fixit_insert_before
890 and add_fixit_insert_after, eliminating the "next_loc" calculation.
891
2c24fd5e 8922016-09-13 Jason Merrill <jason@redhat.com>
893 Tom de Vries <tom@codesourcery.com>
894
895 PR c++/77427
896 * c-common.c (set_underlying_type): Don't treat array as builtin type.
897
005248bc 8982016-09-13 Jason Merrill <jason@redhat.com>
899
900 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
901 limit types at all.
902
0c893604 9032016-09-12 Jason Merrill <jason@redhat.com>
904
905 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
906 bit/byte confusion, allow large alignment for types.
907
7a21b590 9082016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
909
910 PR c++/77496
911 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
912
00434032 9132016-09-12 David Malcolm <dmalcolm@redhat.com>
914
915 PR c/72858
916 * c-format.c (argument_parser::check_argument_type): Add params
917 "type_start" and "conversion_char". Use the former to generate
918 offset_to_type_start and pass it and conversion_char to
919 check_format_types.
920 (check_format_info_main): Capture the start of the type
921 information as "type_start", and pass it an format_char
922 to arg_parser.check_argument_type.
923 (check_format_types): Provide an example in the leading comment.
924 Add params "offset_to_type_start" and "conversion_char"; pass
925 them to format_type_warning calls.
926 (test_get_modifier_for_format_len): Likewise.
927 (matching_type_p): New function.
928 (get_format_for_type): Add param "conversion_char" and move
929 implementation into...
930 (get_format_for_type_1): ...new function, called twice.
931 Use new function matching_type_p rather than checking for
932 TYPE_CANONICAL equality.
933 (get_corrected_substring): New function.
934 (format_type_warning): Provide an example in the leading comment.
935 Add params "offset_to_type_start" and "conversion_char". Replace
936 call to get_format_for_type with call to get_corrected_substring
937 and move rejection of hints for widths/precisions there.
938 (assert_format_for_type_streq): Add param "conversion_char".
939 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
940 (test_get_format_for_type_printf): Add conversion chars to the
941 tests, adding coverage for various combinations of integer
942 vs double conversions, and for preserving octal and hexadecimal
943 conversions.
944 (test_get_format_for_type_scanf): Add conversion chars to the
945 tests.
946
3bb45f76 9472016-09-10 Tom de Vries <tom@codesourcery.com>
948
949 PR C/71602
950 * c-common.c (build_va_arg): Handle more strict
951 targetm.canonical_va_list_type. Replace first argument type error with
952 assert.
953
911ea34a 9542016-09-09 Martin Sebor <msebor@redhat.com>
955
956 PR c/77520
957 PR c/77521
958 * c-format.c (argument_parser::find_format_char_info): Use %qc
959 format directive unconditionally.
960
db8ffb40 9612016-09-09 Jason Merrill <jason@redhat.com>
962
963 Implement C++17 new of over-aligned types.
964 * c.opt: Add -faligned-new and -Waligned-new.
965 * c-common.c (max_align_t_align): Split out from...
966 (cxx_fundamental_alignment_p): ...here.
967 * c-common.h: Declare it.
968 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
969
c5eddaf9 9702016-09-09 Joseph Myers <joseph@codesourcery.com>
971
972 * c-cppbuiltin.c (builtin_define_type_width): New function.
973 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
974 macros.
975
3da97ff7 9762016-09-07 David Malcolm <dmalcolm@redhat.com>
977
978 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
979 a POINTER_TYPE.
980 (substring_loc::get_location): Move to substring-locations.c,
981 keeping implementation as...
982 (c_get_substring_location): New function, from the above, reworked
983 to use accessors rather than member lookup.
984 * c-common.h (class substring_loc): Move to substring-locations.h,
985 replacing with a forward decl.
986 (c_get_substring_location): New decl.
987 * c-format.c: Include "substring-locations.h".
988 (format_warning_va): Move to substring-locations.c.
989 (format_warning_at_substring): Likewise.
990
f9b3f702 9912016-09-06 Martin Sebor <msebor@redhat.com>
992
993 PR c/77336
994 * c-format.c (check_function_format): Avoid issuing warnings for
995 functions unless they call format functions with non-constant
996 format strings.
997
4c04bcce 9982016-09-06 Richard Biener <rguenther@suse.de>
999
1000 PR c/77450
1001 * c-common.c (c_common_mark_addressable_vec): Handle
1002 COMPOUND_LITERAL_EXPR.
1003
8f8828ba 10042016-09-05 Marek Polacek <polacek@redhat.com>
1005
1006 PR c/77423
1007 * c-common.c (bool_promoted_to_int_p): New function.
1008 (expr_has_boolean_operands_p): New function.
1009 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
1010 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
1011
8ff61e58 10122016-09-04 Tom de Vries <tom@codesourcery.com>
1013
1014 revert:
1015 2016-08-29 Tom de Vries <tom@codesourcery.com>
1016
1017 * c-common.c (build_va_arg): Replace first argument type error
1018 with assert.
1019
0b80c4b2 10202016-09-02 Jakub Jelinek <jakub@redhat.com>
1021
1022 PR c/65467
1023 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
1024 (c_finish_omp_for): Reject _Atomic qualified iterators.
1025
10262016-09-01 Martin Sebor <msebor@redhat.com>
b18dea91 1027
1028 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
1029 size to guarantee it fits the output of the formatted function
1030 regardless of its arguments.
1031
c7afb782 10322016-09-01 Marek Polacek <polacek@redhat.com>
1033
1034 PR c/7652
1035 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
1036 FALLTHRU comments.
1037
f293b7f2 10382016-08-29 Marek Polacek <polacek@redhat.com>
1039
1040 PR c/77292
1041 * c-common.c (warn_logical_not_parentheses): Don't warn for
1042 a comparison or a logical operator.
1043
839e4d28 10442016-08-29 Tom de Vries <tom@codesourcery.com>
1045
1046 * c-common.c (build_va_arg): Fix type comparison assert.
1047
0acb92b8 10482016-08-29 Tom de Vries <tom@codesourcery.com>
1049
1050 * c-common.c (build_va_arg): Replace first argument type error
1051 with assert.
1052
ea2ec8f6 10532016-08-29 Tom de Vries <tom@codesourcery.com>
1054
1055 PR c/77398
1056 * c-common.c (build_va_arg): Add first argument error. Build va_arg
1057 with error_mark_node as va_list instead of with illegal va_list.
1058
c4963714 10592016-08-25 Marek Polacek <polacek@redhat.com>
1060 David Malcolm <dmalcolm@redhat.com>
1061
1062 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
1063 * c-common.h (warn_logical_not_parentheses): Update declaration.
1064
364743f3 10652016-08-22 Marek Polacek <polacek@redhat.com>
1066
1067 PR c++/77321
1068 * c-common.c (warn_for_memset): Check type for null.
1069
012f068a 10702016-08-22 Joseph Myers <joseph@codesourcery.com>
1071
1072 * c-family/c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
1073 _FloatNx types for suffixes for built-in functions.
1074
82c85aba 10752016-08-19 Joseph Myers <joseph@codesourcery.com>
1076
1077 PR c/32187
1078 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
1079 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
1080 (RID_FLOAT128X): New enum rid values.
1081 (CASE_RID_FLOATN_NX): New macro.
1082 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
1083 keywords.
1084 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
1085 corresponding complex types.
1086 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
1087 _FloatNx and corresponding complex types.
1088 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
1089 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
1090 and _FloatNx types for the widest type for determining
1091 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
1092 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
1093 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
1094 and _FloatNx types.
1095 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
1096 constants.
1097 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
1098 _FloatNx types.
1099
48a7392b 11002016-08-18 David Malcolm <dmalcolm@redhat.com>
1101
1102 * c-opts.c (c_diagnostic_finalizer): Update for change to
1103 diagnostic_show_locus.
1104
5c8151fa 11052016-08-18 David Malcolm <dmalcolm@redhat.com>
1106
1107 * c-common.c: Include "spellcheck.h".
1108 (cb_get_suggestion): New function.
1109 * c-common.h (cb_get_suggestion): New decl.
1110 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
1111 cb_get_suggestion.
1112
26040f06 11132016-08-18 Marek Polacek <polacek@redhat.com>
1114
1115 PR c/71514
1116 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
1117 and pointer-to-VLA.
1118
5927e78e 11192016-08-16 David Malcolm <dmalcolm@redhat.com>
1120
1121 PR c/72857
1122 * c-common.c (substring_loc::get_range): Rename to...
1123 (substring_loc::get_location): ...this, converting param from a
1124 source_range * to a location_t *. Call
1125 get_source_location_for_substring rather than
1126 get_source_range_for_substring, and pass in m_caret_idx.
1127 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
1128 (substring_loc::get_range): Replace with...
1129 (substring_loc::get_location): ...this.
1130 (substring_loc::set_caret_index): New method.
1131 (substring_loc): Add field m_caret_idx.
1132 * c-format.c (format_warning_va): Update for above changes.
1133 Rename local "substring_loc" to "fmt_substring_loc" to avoid
1134 clashing with type name.
1135 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
1136 (check_argument_type): Likewise.
1137 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
1138 Use a copy when emitting warnings, setting the caret index from TYPE.
1139
6ce66d38 11402016-08-16 Eric Botcazou <ebotcazou@adacore.com>
a49621cf 1141 Arnaud Charlet <charlet@adacore.com>
6ce66d38 1142
1143 * c-ada-spec.c (dump_number): New function.
1144 (handle_escape_character): Likewise.
1145 (print_ada_macros): Add handling of constant integers and strings.
1146
e3533433 11472016-08-12 Marek Polacek <polacek@redhat.com>
1148
1149 PR c/7652
1150 * c-common.c (scalar_to_vector): Adjust fall through comment.
1151 * c-opts.c (c_common_handle_option): Likewise.
1152 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
1153 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
1154 fall through comment.
1155 * cilk.c (extract_free_variables): Add FALLTHRU.
1156
0f463aec 11572016-08-10 Jason Merrill <jason@redhat.com>
1158
1159 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
1160
80488e20 11612016-08-09 Jason Merrill <jason@redhat.com>
1162
1163 * c-common.c (c_common_attribute_table): vector_size affects type
1164 identity.
1165
a319e7f4 11662016-08-09 Marek Polacek <polacek@redhat.com>
1167
1168 PR c/7652
1169 * c-ada-spec.c (dump_generic_ada_node): Add return.
1170
33603066 11712016-08-09 Jason Merrill <jason@redhat.com>
1172
1173 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
1174 C++17 constexpr lambdas.
1175
7af4d06b 11762016-08-08 David Malcolm <dmalcolm@redhat.com>
1177
1178 PR c/64955
1179 * c-common.h (selftest::c_format_c_tests): New declaration.
1180 (selftest::run_c_tests): New declaration.
1181 * c-format.c: Include "selftest.h.
1182 (format_warning_va): Add param "corrected_substring" and use
1183 it to add a replacement fix-it hint.
1184 (format_warning_at_substring): Likewise.
1185 (format_warning_at_char): Update for new param of
1186 format_warning_va.
1187 (argument_parser::check_argument_type): Pass "fki" to
1188 check_format_types.
1189 (check_format_types): Add param "fki" and pass it to
1190 format_type_warning.
1191 (deref_n_times): New function.
1192 (get_modifier_for_format_len): New function.
1193 (selftest::test_get_modifier_for_format_len): New function.
1194 (get_format_for_type): New function.
1195 (format_type_warning): Add param "fki" and use it to attempt
1196 to provide hints for argument types when calling
1197 format_warning_at_substring.
1198 (selftest::get_info): New function.
1199 (selftest::assert_format_for_type_streq): New function.
1200 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
1201 (selftest::test_get_format_for_type_printf): New function.
1202 (selftest::test_get_format_for_type_scanf): New function.
1203 (selftest::c_format_c_tests): New function.
1204
d189b094 12052016-08-08 David Malcolm <dmalcolm@redhat.com>
1206
1207 PR c/52952
1208 * c-format.c: Include "diagnostic.h".
1209 (location_column_from_byte_offset): Delete.
1210 (location_from_offset): Delete.
1211 (format_warning_va): New function.
1212 (format_warning_at_substring): New function.
1213 (format_warning_at_char): New function.
1214 (check_format_arg): Capture location of format_tree and pass to
1215 check_format_info_main.
1216 (argument_parser): Add fields "start_of_this_format" and
1217 "format_string_cst".
1218 (flag_chars_t::validate): Add param "format_string_cst". Convert
1219 warning_at call using location_from_offset to call to
1220 format_warning_at_char.
1221 (argument_parser::argument_parser): Add param "format_string_cst_"
1222 and use use it to initialize field "format_string_cst".
1223 Initialize new field "start_of_this_format".
1224 (argument_parser::read_format_flags): Convert warning_at call
1225 using location_from_offset to a call to format_warning_at_char.
1226 (argument_parser::read_any_format_left_precision): Likewise.
1227 (argument_parser::read_any_format_precision): Likewise.
1228 (argument_parser::read_any_other_modifier): Likewise.
1229 (argument_parser::find_format_char_info): Likewise, in three places.
1230 (argument_parser::parse_any_scan_set): Likewise, in one place.
1231 (argument_parser::handle_conversions): Likewise, in two places.
1232 (argument_parser::check_argument_type): Add param "fmt_param_loc"
1233 and use it to make a substring_loc. Pass the latter to
1234 check_format_types.
1235 (check_format_info_main): Add params "fmt_param_loc" and
1236 "format_string_cst". Convert warning_at calls using
1237 location_from_offset to calls to format_warning_at_char. Pass the
1238 new params to the arg_parser ctor. Pass "format_string_cst" to
1239 flag_chars.validate. Pass "fmt_param_loc" to
1240 arg_parser.check_argument_type.
1241 (check_format_types): Convert first param from a location_t
1242 to a const substring_loc & and rename to "fmt_loc". Attempt
1243 to extract the range of the relevant parameter and pass it
1244 to format_type_warning.
1245 (format_type_warning): Convert first param from a location_t
1246 to a const substring_loc & and rename to "fmt_loc". Add
1247 params "param_range" and "type". Replace calls to warning_at
1248 with calls to format_warning_at_substring.
1249
0dae5fef 12502016-08-08 David Malcolm <dmalcolm@redhat.com>
1251
1252 * c-format.c (class flag_chars_t): New class.
1253 (struct length_modifier): New struct.
1254 (class argument_parser): New class.
1255 (flag_chars_t::flag_chars_t): New ctor.
1256 (flag_chars_t::has_char_p): New method.
1257 (flag_chars_t::add_char): New method.
1258 (flag_chars_t::validate): New method.
1259 (flag_chars_t::get_alloc_flag): New method.
1260 (flag_chars_t::assignment_suppression_p): New method.
1261 (argument_parser::argument_parser): New ctor.
1262 (argument_parser::read_any_dollar): New method.
1263 (argument_parser::read_format_flags): New method.
1264 (argument_parser::read_any_format_width): New method.
1265 (argument_parser::read_any_format_left_precision): New method.
1266 (argument_parser::read_any_format_precision): New method.
1267 (argument_parser::handle_alloc_chars): New method.
1268 (argument_parser::read_any_length_modifier): New method.
1269 (argument_parser::read_any_other_modifier): New method.
1270 (argument_parser::find_format_char_info): New method.
1271 (argument_parser::validate_flag_pairs): New method.
1272 (argument_parser::give_y2k_warnings): New method.
1273 (argument_parser::parse_any_scan_set): New method.
1274 (argument_parser::handle_conversions): New method.
1275 (argument_parser::check_argument_type): New method.
1276 (check_format_info_main): Introduce classes argument_parser
1277 and flag_chars_t, moving the code within the loop into methods
1278 of these classes. Make various locals "const".
1279
d4166bdc 12802016-08-05 David Malcolm <dmalcolm@redhat.com>
1281
1282 * c-common.c: Include "substring-locations.h".
1283 (get_cpp_ttype_from_string_type): New function.
1284 (g_string_concat_db): New global.
1285 (substring_loc::get_range): New method.
1286 * c-common.h (g_string_concat_db): New declaration.
1287 (class substring_loc): New class.
1288 * c-lex.c (lex_string): When concatenating strings, capture the
1289 locations of all tokens using a new obstack, and record the
1290 concatenation locations within g_string_concat_db.
1291 * c-opts.c (c_common_init_options): Construct g_string_concat_db
1292 on the ggc-heap.
1293
7648c9c7 12942016-07-29 Marek Polacek <polacek@redhat.com>
1295
8ae70602 1296 PR c/71926
1297 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
1298 parentheses warning.
1299
7648c9c7 1300 PR c/71574
1301 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
1302
595e387a 13032016-07-28 Martin Liska <mliska@suse.cz>
1304
1305 PR gcov-profile/68025
1306 * c-common.c (handle_no_profile_instrument_function_attribute):
1307
296103aa 13082016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
1309
1310 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
1311 BITS_PER_UNIT_LOG.
1312
21483ab7 13132016-07-25 Jason Merrill <jason@redhat.com>
1314
1315 PR c++/65970
1316 * c.opt (fconstexpr-loop-limit): New.
1317
0b80c4b2 13182016-07-22 Martin Sebor <msebor@redhat.com>
efa8e86e 1319
1320 PR c++/71675
1321 * c-common.c (resolve_overloaded_builtin): Avoid converting
1322 __atomic_compare_exchange_n return type to that of what its
1323 first argument points to.
1324
59c1507a 13252016-07-22 Uros Bizjak <ubizjak@gmail.com>
1326
1327 * c-common.c: Use HOST_WIDE_INT_M1U instead of
1328 ~(unsigned HOST_WIDE_INT) 0.
1329
45648efe 13302016-07-22 Martin Liska <mliska@suse.cz>
1331
1332 PR gcov-profile/69028
1333 PR gcov-profile/62047
1334 * cilk.c (create_cilk_helper_decl): Set location of a new decl
1335 to the current_function_decl.
1336
0c0f63cb 13372016-07-21 Jason Merrill <jason@redhat.com>
1338
1339 PR c++/65168
1340 * c-common.c (c_common_truthvalue_conversion): Check
1341 c_inhibit_evaluation_warnings for warning about address of
1342 reference.
1343
d208f6e6 13442016-07-20 David Malcolm <dmalcolm@redhat.com>
1345
1346 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
1347 const char *.
1348
0238e35e 13492016-07-15 Jason Merrill <jason@redhat.com>
1350
1351 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
1352
0dd7db3b 13532016-07-15 Jakub Jelinek <jakub@redhat.com>
1354
1355 PR c/71858
1356 * c-common.h (enum lookup_name_fuzzy_kind): Add
1357 FUZZY_LOOKUP_FUNCTION_NAME.
1358
e59cff35 13592016-07-08 Jason Merrill <jason@redhat.com>
1360
1361 P0145: Refining Expression Order for C++.
1362 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
1363 * c-opts.c: Adjust.
1364
faee03ad 13652016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
1366
1367 PR c++/71214
1368 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
1369
a4dd89cb 13702016-06-29 Thomas Schwinge <thomas@codesourcery.com>
1371
1372 * c-pragma.h (enum pragma_kind): Rename
1373 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
1374 users.
1375
b6a4a0f5 13762016-06-29 Richard Biener <rguenther@suse.de>
1377
1378 PR middle-end/71002
1379 * c-common.c (c_common_get_alias_set): Remove union type punning case.
1380
176aa551 13812016-06-24 Jason Merrill <jason@redhat.com>
1382
1383 P0145R2: Refining Expression Order for C++.
1384 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
1385 MODIFY_EXPR.
1386
77104764 13872016-06-24 Jakub Jelinek <jakub@redhat.com>
1388
1389 * c-common.c (check_builtin_function_arguments): Require last
1390 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
1391 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
1392 if the last argument is pointer to enumerated or boolean type.
1393
8469aece 13942016-06-22 David Malcolm <dmalcolm@redhat.com>
1395
1396 PR c/70339
1397 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
1398 (lookup_name_fuzzy): New prototype.
1399
bd08c370 14002016-06-21 John David Anglin <danglin@gcc.gnu.org>
1401
1402 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
1403
06c75b9a 14042016-06-14 Jason Merrill <jason@redhat.com>
1405
1406 P0145R2: Refining Expression Order for C++.
1407 * c.opt (fargs-in-order): New.
1408 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
1409
9720103d 14102016-06-13 Jakub Jelinek <jakub@redhat.com>
1411
12cb8367 1412 PR sanitizer/71498
1413 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
1414 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
1415
9720103d 1416 PR preprocessor/71183
1417 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
1418 to cb_get_source_date_epoch.
1419
8ec29807 14202016-06-10 Jakub Jelinek <jakub@redhat.com>
1421
1422 PR c/68657
1423 * c.opt (Wpsabi): Add Warning flag.
1424
1dc4d519 14252016-06-10 Martin Sebor <msebor@redhat.com>
1426
1427 PR c/71392
1428 * gcc/c-family/c-common.c (handle_nonnull_attribute): Accept
1429 the nonnull attribute in type-generic builtins.
1430
23b101c5 14312016-06-09 Martin Sebor <msebor@redhat.com>
1432
1433 PR c/70883
1434 * c-common.c (builtin_function_validate_nargs): Make text of error
1435 message consistent with others like it.
1436
732905bb 14372016-06-08 Martin Sebor <msebor@redhat.com>
1438 Jakub Jelinek <jakub@redhat.com>
1439
1440 PR c++/70507
1441 PR c/68120
1442 * c-common.c (check_builtin_function_arguments): Handle
1443 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
1444
86a5f91c 14452016-06-08 Richard Biener <rguenther@suse.de>
1446
1447 * c-common.c (parse_optimize_options): Improve diagnostic messages.
1448
b032c4dd 14492016-06-07 Richard Biener <rguenther@suse.de>
1450
1451 PR c/61564
1452 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
1453 options and warn about others.
1454
dfa5c0d3 14552016-06-01 Eduard Sanou <dhole@openmailbox.org>
1456
1457 * c-common.c (get_source_date_epoch): Rename to
1458 cb_get_source_date_epoch.
1459 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
1460 message when the parsing fails. Use error_at instead of fatal_error.
1461 * c-common.h (get_source_date_epoch): Rename to
1462 cb_get_source_date_epoch.
1463 * c-common.h (cb_get_source_date_epoch): Prototype.
1464 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
1465 * c-common.h (c_omp_region_type): Remove trailing comma.
1466 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
1467 * c-lex.c (c_lex_with_flags): Remove initialization of
1468 pfile->source_date_epoch.
1469
b6431756 14702016-05-30 Jakub Jelinek <jakub@redhat.com>
1471
1472 PR c++/71349
1473 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
1474 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
1475 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
1476 instead of C_OMP_CLAUSE_SPLIT_FOR.
1477
7345b977 14782016-05-24 Richard Biener <rguenther@suse.de>
1479
1480 PR middle-end/70434
1481 PR c/69504
1482 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
1483 (convert_vector_to_array_for_subscript): ... this.
1484 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
1485 VIEW_CONVERT_EXPR to an array type. Rename to ...
1486 (convert_vector_to_array_for_subscript): ... this.
1487
22a3f7bd 14882016-05-12 Marek Polacek <polacek@redhat.com>
1489
1490 PR c/70756
1491 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
1492 size_in_bytes and pass LOC to it.
1493
54c4d22e 14942016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
1495
1496 PR c/43651
1497 * c.opt (Wduplicate-decl-specifier): New option.
1498
7f8012a5 14992016-05-11 Marek Polacek <polacek@redhat.com>
1500
1501 PR c++/71024
1502 * c-common.c (diagnose_mismatched_attributes): New function.
1503 * c-common.h (diagnose_mismatched_attributes): Declare.
1504
1d52c456 15052016-05-04 Marek Polacek <polacek@redhat.com>
1506
1507 * c.opt (Wdangling-else): New option.
1508
5d4db8ef 15092016-05-03 Marek Polacek <polacek@redhat.com>
1510
1511 PR c/70859
1512 * c-common.c (builtin_function_validate_nargs): Add location
1513 parameter. Use it.
1514 (check_builtin_function_arguments): Add location and arguments
1515 parameters. Use them.
1516 * c-common.h (check_builtin_function_arguments): Update declaration.
1517
9ae1b28a 15182016-05-03 Richard Biener <rguenther@suse.de>
1519
1520 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
1521 allow call args to gimplify to SSA names.
1522
4341e093 15232016-05-03 Marek Polacek <polacek@redhat.com>
1524
1525 * c-common.h (enum c_omp_region_type): Remove stray comma.
1526
b5e88f74 15272016-05-02 Cesar Philippidis <cesar@codesourcery.com>
1528
1529 * c-common.h (enum c_omp_region_type): Define.
1530
ee31dd3d 15312016-05-02 Richard Sandiford <richard.sandiford@arm.com>
1532
1533 * c-common.c (shorten_compare): Use wi::to_wide.
1534
4d0a8bac 15352016-04-29 Cesar Philippidis <cesar@codesourcery.com>
1536
1537 PR middle-end/70626
1538 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
1539 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
1540 reduction clauses in acc parallel loops.
1541
025dd1e0 15422016-04-29 Marek Polacek <polacek@redhat.com>
1543
1544 PR c/70852
1545 * c-common.c (warn_for_memset): Check domain before accessing it.
1546
eb16928e 15472016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
1548
1549 PR/69089
1550 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
1551 "aligned" attribute.
1552
ddd2a3d4 15532016-04-28 Jason Merrill <jason@redhat.com>
1554
1555 * c-lex.c (c_common_has_attribute): Handle nodiscard.
1556
e3e8c48c 15572016-04-28 Eduard Sanou <dhole@openmailbox.org>
1558 Matthias Klose <doko@debian.org>
1559
1560 * c-common.c (get_source_date_epoch): New function, gets the environment
1561 variable SOURCE_DATE_EPOCH and parses it as long long with error
1562 handling.
1563 * c-common.h (get_source_date_epoch): Prototype.
1564 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
1565
605a4556 15662015-04-27 Ryan Burn <contact@rnburn.com>
1567
1568 PR c++/69024
1569 PR c++/68997
1570 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
1571 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
1572 external linkage.
1573 (cilk_detect_and_unwrap): Corresponding changes.
1574 (extract_free_variables): Don't extract free variables from
1575 AGGR_INIT_EXPR slot.
1576 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
1577 (cilk_recognize_spawn): Likewise.
1578
40385231 15792016-04-27 Bernd Schmidt <bschmidt@redhat.com>
1580
1581 * c.opt (Wmemset-elt-size): New option.
1582 * c-common.c (warn_for_memset): New function.
1583 * c-common.h (warn_for_memset): Declare.
1584
f5d49c14 15852016-04-25 Jason Merrill <jason@redhat.com>
1586
1587 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
1588 No longer static.
1589 * c-common.h: Declare it.
1590 * c-lex.c (c_common_has_attribute): Add maybe_unused.
1591
9c980ab5 15922016-04-22 Jason Merrill <jason@redhat.com>
1593
1594 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
1595
70574e60 15962016-04-20 Ilya Verbin <ilya.verbin@intel.com>
1597
1598 PR c++/69363
1599 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
1600 * c-common.h (c_finish_cilk_clauses): Remove declaration.
1601
5d4b30ea 16022016-04-18 Michael Matz <matz@suse.de>
1603
1604 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
1605 and SET_DECL_ALIGN.
1606
021ad2f3 16072016-04-17 Eric Botcazou <ebotcazou@adacore.com>
1608
1609 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
1610 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
1611 to incomplete types.
1612 (dump_nested_type): Remove redundant tests and tidy up.
1613 (print_ada_declaration): Also set TREE_VISITED on the declaration of
1614 a type which is the typedef of an original type.
1615
926f9422 16162016-04-15 Marek Polacek <polacek@redhat.com>
1617
1618 PR c/70651
1619 * c-common.c (build_va_arg): Change two asserts into errors and return
1620 error_mark_node.
1621
92c53257 16222016-04-13 Marek Polacek <polacek@redhat.com>
1623
1624 PR c++/70639
1625 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
1626 for switch statements, too.
1627
a3ae889f 16282016-03-28 Jason Merrill <jason@redhat.com>
1629
1630 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
1631
62d2a6dc 16322016-03-23 Marek Polacek <polacek@redhat.com>
1633
1634 PR c++/69884
1635 * c.opt (Wignored-attributes): New option.
1636
4baec9f2 16372016-03-22 David Malcolm <dmalcolm@redhat.com>
1638
1639 PR c/69993
1640 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
1641 diagnostic text, reversing the order of the warning and note so
1642 that they appear in source order.
1643
92e7ab1e 16442016-03-17 Marek Polacek <polacek@redhat.com>
1645
1646 PR c/69407
1647 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
1648 operations.
1649
6f895832 16502016-03-14 Jason Merrill <jason@redhat.com>
1651
14c36b14 1652 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
1653
6f895832 1654 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
1655
42bb3bfb 16562016-03-09 Richard Biener <rguenther@suse.de>
1657
1658 PR c/70143
1659 * c-common.c (strict_aliasing_warning): Add back
1660 alias_sets_conflict_p check.
1661
3556aa80 16622016-03-08 Jason Merrill <jason@redhat.com>
1663
1664 * c-opts.c (set_std_cxx1z): Don't enable concepts.
1665
0060768a 16662016-03-04 David Malcolm <dmalcolm@redhat.com>
1667
1668 PR c/68187
1669 * c-indentation.c (get_visual_column): Move code to determine next
1670 tab stop to...
1671 (next_tab_stop): ...this new function.
1672 (line_contains_hash_if): Delete function.
1673 (detect_preprocessor_logic): Delete function.
1674 (get_first_nws_vis_column): New function.
1675 (detect_intervening_unindent): New function.
1676 (should_warn_for_misleading_indentation): Replace call to
1677 detect_preprocessor_logic with a call to
1678 detect_intervening_unindent.
1679
74c6fd40 16802016-03-04 David Malcolm <dmalcolm@redhat.com>
1681
1682 PR c/68187
1683 * c-indentation.c (should_warn_for_misleading_indentation): When
1684 suppressing warnings about cases where the guard and body are on
1685 the same column, only use the first non-whitespace column in place
1686 of the guard token column when dealing with "else" clauses.
1687 When rejecting aligned BODY and NEXT, loosen the requirement
1688 from equality with the first non-whitespace of guard to simply
1689 that they not be indented relative to it.
1690
e692d332 16912016-03-04 Richard Biener <rguenther@suse.de>
1692
1693 PR c++/70054
1694 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
1695 instead of alias_sets_conflict_p.
1696
12cc1225 16972016-03-01 Marek Polacek <polacek@redhat.com>
1698
1699 PR c++/69795
1700 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
1701 any DECL.
1702
8c38d887 17032016-02-22 Martin Sebor <msebor@redhat.com>
1704
1705 PR middle-end/69780
1706 * c-common.c (check_builtin_function_arguments): Validate and
1707 reject invalid arguments to __builtin_alloca_with_align.
1708
e53f41d5 17092016-02-20 Mark Wielaard <mjw@redhat.com>
1710
1711 PR c/28901
1712 * c.opt (Wunused-const-variable): Turn into Alias for...
1713 (Wunused-const-variable=): New option.
1714
9cce8384 17152016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
1716
1717 PR c++/69865
1718 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
1719 here...
1720 (c_common_init_options): ...to here.
1721 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
1722
563d5cb8 17232016-02-19 Jakub Jelinek <jakub@redhat.com>
1724
1725 PR c++/69826
1726 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
1727 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
1728 flag_preprocess_only.
1729
7675e968 17302016-02-16 Jakub Jelinek <jakub@redhat.com>
1731
1732 PR c/69835
1733 * c.opt (Wnonnull-compare): Enable for -Wall.
1734
77454e6e 17352016-02-15 Jakub Jelinek <jakub@redhat.com>
1736
1737 PR c++/69797
1738 * c-common.c (sync_resolve_size): Diagnose too few arguments
1739 even when params is non-NULL empty vector.
1740
600695e0 17412016-02-08 Bernd Schmidt <bschmidt@redhat.com>
1742
1743 PR target/60410
1744 * c.opt (fshort-double): Remove.
1745
a7cc1f94 17462016-02-05 Martin Sebor <msebor@redhat.com>
1747
1748 PR c++/69662
1749 * c.opt (Warning options): Update -Wplacement-new to take
1750 an optional argument.
1751
6f13b088 17522016-02-01 Jakub Jelinek <jakub@redhat.com>
1753
1754 PR preprocessor/69543
1755 PR c/69558
1756 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
1757 instead of loc to control_warning_option.
1758
948eee2f 17592016-02-01 Nathan Sidwell <nathan@codesourcery.com>
1760
1761 * c.opt (fopenacc-dim=): New option.
1762
5fa82c11 17632016-01-27 Ryan Burn <contact@rnburn.com>
1764
1765 PR cilkplus/69267
1766 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
1767 gimplify_arg. Removed superfluous post_p argument.
1768 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
1769 superfluous post_p argument.
1770 * c-gimplify.c (c_gimplify_expr): Likewise.
1771
3752e5b1 17722016-01-26 David Malcolm <dmalcolm@redhat.com>
1773
1774 PR other/69006
1775 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
1776 pp_newline_and_flush with pp_flush.
1777
bbbbe8ab 17782016-01-20 Martin Sebor <msebor@redhat.com>
1779
1780 PR c/69405
1781 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
1782 an incompatible argument when the argument isn't a valid tree node.
1783
f6dfb86a 17842016-01-18 Jason Merrill <jason@redhat.com>
1785
1786 PR c++/68767
1787 * c-common.c (check_function_arguments_recurse): Fold the whole
1788 COND_EXPR, not just the condition.
1789
f672c103 17902016-01-18 Tom de Vries <tom@codesourcery.com>
1791
1792 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
1793 classify as loop clause.
1794
c8ef893c 17952016-01-15 Jakub Jelinek <jakub@redhat.com>
1796
1797 PR bootstrap/68271
1798 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
1799 C++ FE no longer has limit on number of pragmas.
1800
18012015-01-14 Ryan Burn <contact@rnburn.com>
7d600da5 1802
1803 PR c++/69048
1804 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
580357e7 1805 to add missing cleanup point.
7d600da5 1806
a7ed4583 18072016-01-14 David Malcolm <dmalcolm@redhat.com>
1808
1809 PR c++/68819
1810 * c-indentation.c (get_visual_column): Add location_t param.
1811 Handle the column number being zero by effectively disabling the
1812 warning, with an "inform".
1813 (should_warn_for_misleading_indentation): Add location_t argument
1814 for all uses of get_visual_column.
1815
b933e511 18162016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
1817
1818 PR c++/69029
1819 * c-indentation.c (should_warn_for_misleading_indentation):
1820 Don't warn about do-while statements.
1821
517906ff 18222016-01-07 Martin Sebor <msebor@redhat.com>
1823
1824 PR c/68966
1825 * c-common.c (sync_resolve_size): Reject first argument when it's
1826 a pointer to _Bool.
1827
d42aa619 18282016-01-05 David Malcolm <dmalcolm@redhat.com>
1829
1830 PR c/69122
1831 * c-indentation.c (get_visual_column): Remove default argument.
1832 (should_warn_for_misleading_indentation): For the multiline case,
1833 update call to get_visual_column for next_stmt_exploc so that it
1834 captures the location of the first non-whitespace character in the
1835 relevant line. Don't issue warnings if there is non-whitespace
1836 before the next statement.
1837
f1717362 18382016-01-04 Jakub Jelinek <jakub@redhat.com>
1839
1840 Update copyright years.
1841
c0bf500c 18422015-12-21 David Malcolm <dmalcolm@redhat.com>
1843
1844 * c-common.c (binary_op_error): Convert first param from
1845 location_t to rich_location * and use it when emitting an error.
1846 * c-common.h (binary_op_error): Convert first param from
1847 location_t to rich_location *.
1848
dbd79382 18492015-12-16 David Malcolm <dmalcolm@redhat.com>
1850
1851 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
1852 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
1853
c0998828 18542015-12-15 Ilya Verbin <ilya.verbin@intel.com>
1855
1856 * c-common.c (c_common_attribute_table): Handle "omp declare target
1857 link" attribute.
1858
7ca909c6 18592015-12-14 Jakub Jelinek <jakub@redhat.com>
1860
1861 PR c/68833
1862 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
1863
d9102cbe 18642014-12-12 Tobias Burnus <burnus@net-b.de>
1865
1866 PR fortran/68815
1867 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
1868 specifiers (%d, %i,%u and %c).
1869
a515ebdf 18702015-12-10 David Malcolm <dmalcolm@redhat.com>
1871
1872 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
1873
31ba81bd 18742015-12-08 Jakub Jelinek <jakub@redhat.com>
1875
1876 PR c/48088
1877 PR c/68657
1878 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
1879 * c-pragma.c (handle_pragma_diagnostic): Adjust
1880 control_warning_option caller.
1881
d0f713f4 18822015-12-07 David Malcolm <dmalcolm@redhat.com>
1883
1884 * c-common.c (c_cpp_error): Update for change to
1885 rich_location::set_range.
1886
32d050b5 18872015-12-04 Paolo Bonzini <bonzini@gnu.org>
1888
1889 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
1890 shifting 1 out of the sign bit.
1891
18922015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
1893
1894 * c-common.c (c_common_attribute_table[]): Update max arguments
1895 count for "simd" attribute.
1896 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
1897
6a8fbd7a 18982015-12-03 Jakub Jelinek <jakub@redhat.com>
1899
1900 PR preprocessor/57580
1901 * c-ppoutput.c (print): Change printed field to bool.
1902 Move src_file last for smaller padding.
1903 (init_pp_output): Set print.printed to false instead of 0.
1904 (scan_translation_unit): Fix up formatting. Set print.printed
1905 to true after printing something other than newline.
1906 (scan_translation_unit_trad): Set print.printed to true instead of 1.
1907 (maybe_print_line_1): Set print.printed to false instead of 0.
1908 (print_line_1): Likewise.
1909 (do_line_change): Set print.printed to true instead of 1.
1910 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
1911 dump_macro): Set print.printed to false after printing newline.
1912
da562e32 19132015-12-02 Jason Merrill <jason@redhat.com>
1914
9c691dbd 1915 * c-common.c (fold_for_warn): New.
1916 (warn_logical_operator, warn_tautological_cmp)
1917 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
1918
da562e32 1919 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
1920 (c_fully_fold_internal, decl_constant_value_for_optimization):
1921 Move to c/c-fold.c.
1922 * c-common.h: Don't declare decl_constant_value_for_optimization.
1923
89f16034 19242015-12-02 Joseph Myers <joseph@codesourcery.com>
1925
1926 PR c/68162
1927 * c-common.h (c_build_qualified_type): Add extra default
1928 arguments.
1929
571b3486 19302015-12-01 Julian Brown <julian@codesourcery.com>
1931 Cesar Philippidis <cesar@codesourcery.com>
1932 James Norris <James_Norris@mentor.com>
1933
1934 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
1935 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
1936 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
1937
ed92a461 19382015-11-30 Eric Botcazou <ebotcazou@adacore.com>
1939
1940 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
1941 (decl_sloc_common): Delete and move bulk of processing to...
1942 (decl_sloc): ...here.
1943 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
1944 (dump_ada_double_name): Remove S parameter and compute the suffix.
1945 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
1946 element type and deal with an anonymous one.
1947 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
1948 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
1949 and remove reference to QUAL_UNION_TYPE.
1950 (dump_nested_types): Make 2 passes on the fields and move bulk to...
1951 (dump_nested_type): ...here. New function extracted from above.
1952 Generate a full declaration for anonymous element type of arrays.
1953 (print_ada_declaration): Really skip anonymous declarations. Remove
1954 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
1955 Clean up processing of declarations of array types and objects.
1956 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
1957 Remove obsolete code and tidy up.
1958
c25b3e3f 19592015-11-29 Jan Hubicka <hubicka@ucw.cz>
1960
1961 PR c/67581
1962 * c-common.c (handle_transparent_union_attribute): Update
1963 also type variants.
1964
d4e328e9 19652015-11-27 Martin Liska <mliska@suse.cz>
1966
1967 PR c++/68312
1968 * array-notation-common.c (cilkplus_extract_an_triplets):
1969 Release vector of vectors.
1970 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
1971
f63d9c4e 19722015-11-26 Eric Botcazou <ebotcazou@adacore.com>
1973
1974 PR c++/68527
1975 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
1976 (print_ada_struct_decl): Likewise.
1977
8d63c601 19782015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
1979
1980 PR c++/68001
1981 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
1982 * cilk.c (recognize_spawn): Determine location in a more precise
1983 way.
1984
01f11119 19852015-11-19 Jason Merrill <jason@redhat.com>
1986
1987 * c-common.c (shorten_compare): But look through macros from
1988 system headers.
1989
2d3d3af7 19902015-11-18 Jason Merrill <jason@redhat.com>
1991
1992 * c-common.c (shorten_compare): Don't -Wtype-limits if the
1993 non-constant operand comes from a macro.
1994
7991eeee 19952015-11-17 Jason Merrill <jason@redhat.com>
1996
1997 PR bootstrap/68346
1998 * c-common.c (warn_tautological_cmp): Fold before checking for
1999 constants.
2000
73f67931 20012015-11-16 Marek Polacek <polacek@redhat.com>
2002
2003 PR c++/68362
2004 * c-common.c (check_case_bounds): Fold low and high cases.
2005
8e539fdc 20062015-11-16 Marek Polacek <polacek@redhat.com>
2007
2008 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
2009 * c-common.c (c_common_get_alias_set): Likewise.
2010 (handle_visibility_attribute): Likewise.
2011
c58a4cfd 20122015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
2013
2014 * c-common.c (handle_simd_attribute): New.
2015 (struct attribute_spec): Add entry for "simd".
2016 (handle_simd_attribute): New.
2017
bb036391 20182015-11-13 Kai Tietz <ktietz70@googlemail.com>
2019
2020 * c-lex.c (interpret_float): Use fold_convert.
2021
a96cefb2 20222015-11-13 David Malcolm <dmalcolm@redhat.com>
2023
2024 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
2025 and store it on the result.
2026 * c-opts.c (c_common_init_options): Set
2027 global_dc->colorize_source_p.
2028
2fc5e987 20292015-11-12 James Norris <jnorris@codesourcery.com>
2030 Joseph Myers <joseph@codesourcery.com>
2031
2032 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
2033 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
2034 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
2035 PRAGMA_OACC_CLAUSE_LINK.
2036
81b1b2a8 20372015-11-11 Marek Polacek <polacek@redhat.com>
2038
2039 PR c/68107
2040 PR c++/68266
2041 * c-common.c (valid_array_size_p): New function.
2042 * c-common.h (valid_array_size_p): Declare.
2043
92a44a68 20442015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4f3707ca 2045
2046 PR bootstrap/68271
2047 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
2048
6e803544 20492015-11-11 Andrew MacLeod <amacleod@redhat.com>
2050
2051 * array-notation-common.c: Remove unused header files.
2052 * c-ada-spec.c: Likewise.
2053 * c-cilkplus.c: Likewise.
2054 * c-common.c: Likewise.
2055 * c-cppbuiltin.c: Likewise.
2056 * c-dump.c: Likewise.
2057 * c-format.c: Likewise.
2058 * c-gimplify.c: Likewise.
2059 * c-indentation.c: Likewise.
2060 * c-lex.c: Likewise.
2061 * c-omp.c: Likewise.
2062 * c-opts.c: Likewise.
2063 * c-pch.c: Likewise.
2064 * c-ppoutput.c: Likewise.
2065 * c-pragma.c: Likewise.
2066 * c-pretty-print.c: Likewise.
2067 * c-semantics.c: Likewise.
2068 * c-ubsan.c: Likewise.
2069 * cilk.c: Likewise.
2070 * stub-objc.c: Likewise.
2071
a1b7fe4b 20722015-11-09 Thomas Schwinge <thomas@codesourcery.com>
2073 Cesar Philippidis <cesar@codesourcery.com>
2074 James Norris <jnorris@codesourcery.com>
2075 Julian Brown <julian@codesourcery.com>
2076 Nathan Sidwell <nathan@codesourcery.com>
2077
2078 * c-pragma.c (oacc_pragmas): Add "routine".
2079 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
2080
292237f3 20812015-11-08 Eric Botcazou <ebotcazou@adacore.com>
2082
2083 * c-common.c (c_common_attributes): Add scalar_storage_order.
2084 (handle_scalar_storage_order_attribute): New function.
2085 * c-pragma.c (global_sso): New variable.
2086 (maybe_apply_pragma_scalar_storage_order): New function.
2087 (handle_pragma_scalar_storage_order): Likewise.
2088 (init_pragma): Register scalar_storage_order.
2089 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
2090 * c.opt (Wscalar-storage-order): New warning.
2091 (fsso-struct=): New option.
2092
b4a4c5fa 20932015-11-08 Martin Sebor <msebor@redhat.com>
2094
2095 * c.opt (Wplacement-new): Add a period to the end of a sentence.
2096
ac677063 20972015-11-07 Richard Sandiford <richard.sandiford@arm.com>
2098
2099 * c-common.c: Don't undef DEF_BUILTIN.
2100
f0479000 21012015-11-06 David Malcolm <dmalcolm@redhat.com>
2102
2103 * c-common.c (c_cpp_error): Convert parameter from location_t to
2104 rich_location *. Eliminate the "column_override" parameter and
2105 the call to diagnostic_override_column.
2106 Update the "done_lexing" clause to set range 0
2107 on the rich_location, rather than overwriting a location_t.
2108 * c-common.h (c_cpp_error): Convert parameter from location_t to
2109 rich_location *. Eliminate the "column_override" parameter.
2110
ef014f95 21112015-11-05 Cesar Philippidis <cesar@codesourcery.com>
2112 Thomas Schwinge <thomas@codesourcery.com>
2113 James Norris <jnorris@codesourcery.com>
2114
2115 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
2116 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
2117 clauses with parallel and kernels and loops.
2118 * c-pragma.h (enum pragma_omp_clause): Add entries for
2119 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
2120 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
2121 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
2122 INDEPENDENT,SEQ}.
2123 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
2124
e520488c 21252015-11-05 Martin Sebor <msebor@redhat.com>
2126
2127 PR c++/67942
2128 * c.opt (-Wplacement-new): New option.
2129
9561765e 21302015-11-05 Jakub Jelinek <jakub@redhat.com>
2131
2132 * c-common.h (c_finish_omp_atomic): Add TEST argument.
2133 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
2134 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
2135 save_expr or create_tmp_var* if TEST is true.
2136 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
2137 Don't call add_stmt here.
2138 (struct c_omp_check_loop_iv_data): New type.
2139 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
2140 c_omp_check_loop_iv_exprs): New functions.
2141 (c_omp_split_clauses): Adjust for lastprivate being allowed on
2142 distribute.
2143 (c_omp_declare_simd_clauses_to_numbers): Change
2144 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
2145 (c_omp_declare_simd_clauses_to_decls): Similarly change those
2146 from numbers to PARM_DECLs.
2147
5e8689fb 21482015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
2149
2150 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
2151 flag_checking.
2152
92a44a68 21532015-11-03 Bernd Schmidt <bschmidt@redhat.com>
aeaccb75 2154
2155 PR c++-common/67882
32d050b5 2156 * c-common.h (fold_offsetof_1): Add argument.
2157 * c-common.c (fold_offsetof_1): Diagnose more invalid
aeaccb75 2158 offsetof expressions that reference elements past the end of
2159 an array.
2160
9e10bfb7 21612015-11-03 Thomas Schwinge <thomas@codesourcery.com>
2162 Chung-Lin Tang <cltang@codesourcery.com>
2163
2164 * c-pragma.c (oacc_pragmas): Add "atomic".
2165 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
2166
ab50af2a 21672015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
2168
2169 * c-common.c (handle_target_clones_attribute): New.
2170 (c_common_attribute_table): Add handle_target_clones_attribute.
2171 (handle_always_inline_attribute): Add check on target_clones attribute.
2172 (handle_target_attribute): Ditto.
2173
4cba6f60 21742015-10-29 Andrew MacLeod <amacleod@redhat.com>
2175
2176 * array-notation-common.c: Reorder #include's and remove duplicates.
2177 * c-ada-spec.c: Likewise.
2178 * c-cilkplus.c: Likewise.
2179 * c-common.c: Likewise.
2180 * c-cppbuiltin.c: Likewise.
2181 * c-dump.c: Likewise.
2182 * c-format.c: Likewise.
2183 * c-gimplify.c: Likewise.
2184 * c-indentation.c: Likewise.
2185 * c-lex.c: Likewise.
2186 * c-omp.c: Likewise.
2187 * c-opts.c: Likewise.
2188 * c-pch.c: Likewise.
2189 * c-ppoutput.c: Likewise.
2190 * c-pragma.c: Likewise.
2191 * c-pretty-print.c: Likewise.
2192 * c-semantics.c: Likewise.
2193 * c-ubsan.c: Likewise.
2194 * cilk.c: Likewise.
2195 * stub-objc.c: Likewise.
2196
f576a2e4 21972015-10-28 Jason Merrill <jason@redhat.com>
2198
2199 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
2200
2c4c8725 22012015-10-27 Thomas Schwinge <thomas@codesourcery.com>
2202 James Norris <jnorris@codesourcery.com>
2203 Cesar Philippidis <cesar@codesourcery.com>
2204
2205 PR c/64765
2206 PR c/64880
2207 * c-common.h (c_oacc_split_loop_clauses): Declare function.
2208 * c-omp.c (c_oacc_split_loop_clauses): New function.
2209
8204c077 22102015-10-21 Martin Sebor <msebor@redhat.com>
2211
2212 PR driver/68043
2213 * c.opt: End each sentence that describes an option with a period.
2214
8523243e 22152015-10-20 Marek Polacek <polacek@redhat.com>
2216
2217 * array-notation-common.c (is_cilkplus_vector_p): Define.
2218 * c-common.h (is_cilkplus_vector_p): Declare.
2219
08881cb8 22202015-10-20 Marek Polacek <polacek@redhat.com>
2221
2222 * c.opt (std=gnu++11): Do not describe as experimental.
2223 (std=gnu++14): Likewise.
2224
a36e5e5e 22252015-10-19 Jason Merrill <jason@redhat.com>
2226
2227 * c-cppbuiltin.c (c_cpp_builtins): Define
2228 __cpp_nontype_template_args.
2229
a349de0a 22302015-10-19 Jason Merrill <jason@redhat.com>
2231
2232 * c-cppbuiltin.c (c_cpp_builtins): Define
2233 __cpp_enumerator_attributes, __cpp_fold_expressions,
2234 __cpp_unicode_characters.
2235
43895be5 22362015-10-13 Jakub Jelinek <jakub@redhat.com>
2237 Aldy Hernandez <aldyh@redhat.com>
2238
2239 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
2240 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
2241 (c_define_builtins): Likewise.
2242 * c-common.h (enum c_omp_clause_split): Add
2243 C_OMP_CLAUSE_SPLIT_TASKLOOP.
2244 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
2245 (c_finish_omp_for): Add ORIG_DECLV argument.
2246 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
2247 201511 instead of 201307.
2248 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
2249 OMP_CRITICAL_CLAUSES to it.
2250 (c_finish_omp_ordered): Add CLAUSES argument, set
2251 OMP_ORDERED_CLAUSES to it.
2252 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
2253 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
2254 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
2255 constructs and new OpenMP 4.5 clauses. Clear
2256 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
2257 verification code.
2258 * c-pragma.c (omp_pragmas_simd): Add taskloop.
2259 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
2260 (enum pragma_omp_clause): Add
2261 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
2262 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
2263
20cb53c9 22642015-10-05 Richard Sandiford <richard.sandiford@arm.com>
2265
2266 * c-lex.c (interpret_float): Use real_equal instead of
2267 REAL_VALUES_EQUAL.
2268
6d02e6b2 22692015-10-04 Jason Merrill <jason@redhat.com>
2270
2271 Implement N4514, C++ Extensions for Transactional Memory.
2272 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
2273 (c_common_attribute_table): Add transaction_safe_dynamic.
2274 transaction_safe now affects type identity.
2275 (handle_tm_attribute): Handle transaction_safe_dynamic.
2276 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
2277 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
2278 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
2279 (D_TRANSMEM): New.
2280 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
2281 * c-pretty-print.c (pp_c_attributes_display): Don't print
2282 transaction_safe in C++.
2283
c0999a5d 22842015-10-02 Marek Polacek <polacek@redhat.com>
2285
2286 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
2287
ef17a71a 22882015-10-02 Marek Polacek <polacek@redhat.com>
2289
2290 PR c/64249
2291 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
2292 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
2293 * c.opt (Wduplicated-cond): New option.
2294
05b84e7b 22952015-10-01 Joseph Myers <joseph@codesourcery.com>
2296
2297 * c.opt (std=c11): Do not describe as experimental.
2298 (std=gnu11): Likewise.
2299 (std=iso9899:2011): Likewise.
2300
e561d5e1 23012015-09-28 Nathan Sidwell <nathan@codesourcery.com>
2302
2303 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
2304 (DEF_FUNCTION_TYPE_VAR_11): Delete.
2305
bd4b90d2 23062015-09-25 Marek Polacek <polacek@redhat.com>
2307
2308 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
2309 (ubsan_instrument_shift): Likewise.
2310
ac13b2b2 23112015-09-25 Marek Polacek <polacek@redhat.com>
2312
2313 PR sanitizer/64906
2314 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
2315
a3c82f4c 23162015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
2317
2318 * c-indentation.c (should_warn_for_misleading_indentation):
2319 Compare next_stmt_vis_column with guard_line_first_nws instead
2320 of with guard_line_vis_column.
2321
5eef101d 23222015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
2323
2324 PR c/49654
2325 PR c/49655
2326 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
2327 options and options not valid for the current language.
2328
60897493 23292015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
2330
2331 * c-indentation.c (should_warn_for_misleading_indentation):
2332 Float out and consolidate the calls to get_visual_column that
2333 are passed guard_exploc as an argument. Compare
2334 next_stmt_vis_column with guard_line_first_nws instead of with
2335 body_line_first_nws.
2336
85c93154 23372015-09-22 Nathan Sidwell <nathan@codesourcery.com>
2338
2339 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
2340 Wnamespaces): New C++ warnings.
2341
229a58b1 23422015-09-22 Jason Merrill <jason@redhat.com>
2343
2344 * c-common.h (abi_compat_version_crosses): New.
2345 (warn_abi_version): Declare.
2346 * c-common.c: Define it.
2347 * c-opts.c (c_common_post_options): Handle it.
2348 flag_abi_compat_version defaults to 8.
2349
2d2de569 23502015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
2351
2352 Complete the implementation of N4230, Nested namespace definition.
2353 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
2354 __cpp_nested_namespace_definitions.
2355
2b897e68 23562015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
2357
2358 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
2359
ed536208 23602015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
2361
2362 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
2363 when warning.
2364 * c-pragma.h (pragma_lex): Add optional loc argument.
2365
1dc6c44d 23662015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
2367
2368 * c-format.c (check_format_arg): Adjust to use common block size in all
2369 object pools.
2370
be812248 23712015-09-15 David Malcolm <dmalcolm@redhat.com>
2372
2373 * c-format.c (location_from_offset): Update for change in
2374 signature of location_get_source_line.
2375 * c-indentation.c (get_visual_column): Likewise.
2376 (line_contains_hash_if): Likewise.
2377
e4cc057f 23782015-09-14 Marek Polacek <polacek@redhat.com>
2379
2380 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
2381 setting various warnings.
2382
85f5e2ee 23832015-09-14 Marek Polacek <polacek@redhat.com>
2384
2385 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
2386 a negative value.
2387
1bca8cbd 23882015-09-11 Mark Wielaard <mjw@redhat.com>
2389
2390 PR c/28901
2391 * c.opt (Wunused-variable): Option from common.opt.
2392 (Wunused-const-variable): New option.
2393
ee48893a 23942015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
2395
2396 PR c++/53184
2397 * c.opt ([Wsubobject-linkage]): Add.
2398
547c6b1f 23992015-09-03 Martin Sebor <msebor@redhat.com>
2400
2401 PR c/66516
2402 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
2403 functions.
2404 * c-common.c (reject_gcc_builtin): Define.
2405
7e976b10 24062015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
2407
2408 PR middle-end/60586
2409 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
2410 prototype.
2411 * c-gimplify.c (c_gimplify_expr): Added a call to the function
2412 cilk_gimplify_call_params_in_spawned_fn.
2413 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
2414 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
2415 unwrapping.
2416
9e6bcade 24172015-08-25 Marek Polacek <polacek@redhat.com>
2418
2419 PR middle-end/67330
2420 * c-common.c (handle_weak_attribute): Don't check whether the
2421 visibility can be changed here.
2422
af9de21d 24232015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
2424
2425 * c-lex.c (c_lex_with_flags): Use explicit locations.
2426
6dc50383 24272015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
2428
2429 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
2430 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
2431
10902624 24322015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2433
2434 PR middle-end/36757
2435 * c-common.c (check_builtin_function_arguments): Add check
2436 for BUILT_IN_SIGNBIT argument.
2437
a03a71ab 24382015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
2439
2440 PR c++/67160
2441 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
2442 in c++1z mode.
2443
22723c26 24442015-08-17 Marek Polacek <polacek@redhat.com>
2445
2446 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
2447 with whitespaces before qualifier names.
2448
f4809955 24492015-08-12 Marek Polacek <polacek@redhat.com>
2450
2451 PR c++/55095
2452 * c-common.c (maybe_warn_shift_overflow): Properly handle
2453 left-shifting 1 into the sign bit.
2454
5463f502 24552015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
2456
2457 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
2458
56c12fd4 24592015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
2460 Braden Obrzut <admin@maniacsvault.net>
2461 Jason Merrill <jason@redhat.com>
2462
2463 Add C++ Concepts TS support.
2464 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
2465 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
2466 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
2467 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
2468 * c-opts.c (set_std_cxx1z): Set flag_concepts.
2469 * c.opt (fconcepts): New.
2470
32d050b5 24712015-08-02 Martin Sebor <msebor@redhat.com>
2472
2473 * c.opt (-Wframe-address): New warning option.
2474
17afcef6 24752015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
2476
2477 * c-indentation.c (should_warn_for_misleading_indentation):
2478 Improve heuristics.
2479
f95bfdd4 24802015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
2481
2482 * c-indentation.c (get_visual_column): Add parameter first_nws,
2483 use it. Update comment documenting the function.
2484 (is_first_nonwhitespace_on_line): Remove.
2485 (should_warn_for_misleading_indentation): Replace usage of
2486 of is_first_nonwhitespace_on_line with get_visual_column.
2487
9255be07 24882015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
2489
2490 * c-indentation.h (struct token_indent_info): Define.
2491 (get_token_indent_info): Define.
2492 (warn_for_misleading_information): Declare.
2493 * c-common.h (warn_for_misleading_information): Remove.
2494 * c-identation.c (warn_for_misleading_indentation):
2495 Change declaration to take three token_indent_infos. Adjust
2496 accordingly.
2497 * c-identation.c (should_warn_for_misleading_indentation):
2498 Likewise. Bail out early if the body is a compound statement.
2499 (guard_tinfo_to_string): Define.
2500
e880695c 25012015-07-30 Jason Merrill <jason@redhat.com>
2502
2503 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
2504 '*' for reference decay.
2505
f58dd84b 25062015-07-30 Marek Polacek <polacek@redhat.com>
2507
2508 * c-common.c (warn_tautological_cmp): Bail for float types.
2509
d9e4fe27 25102015-07-27 Marek Polacek <polacek@redhat.com>
2511
2512 PR bootstrap/67030
2513 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
2514
6784a472 25152015-07-27 Marek Polacek <polacek@redhat.com>
2516
2517 PR c++/66555
2518 PR c/54979
2519 * c-common.c (find_array_ref_with_const_idx_r): New function.
2520 (warn_tautological_cmp): New function.
2521 * c-common.h (warn_tautological_cmp): Declare.
2522 * c.opt (Wtautological-compare): New option.
2523
08034975 25242015-07-23 Marek Polacek <polacek@redhat.com>
2525
2526 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
2527 (ubsan_instrument_shift): Likewise.
2528
f6f5e49b 25292015-07-23 Marek Polacek <polacek@redhat.com>
2530
2531 PR sanitizer/66908
2532 * c-ubsan.c: Include gimplify.h.
2533 (ubsan_instrument_division): Unshare OP0 and OP1.
2534 (ubsan_instrument_shift): Likewise.
2535
8d669e79 25362015-07-20 Marek Polacek <polacek@redhat.com>
2537 Richard Sandiford <richard.sandiford@arm.com>
2538
2539 PR c++/55095
2540 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
2541 Use EXPR_LOC_OR_LOC.
2542 (maybe_warn_shift_overflow): New function.
2543 * c-common.h (maybe_warn_shift_overflow): Declare.
2544 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
2545 * c.opt (Wshift-overflow): New option.
2546
e16712b1 25472015-07-16 Martin Liska <mliska@suse.cz>
2548
2549 * c-format.c (static void check_format_info_main): Use
2550 object_allocator instead of pool_allocator.
2551 (check_format_arg): Likewise.
2552 (check_format_info_main): Likewise.
2553
e51764ad 25542015-07-15 Andrew MacLeod <amacleod@redhat.com>
2555
2556 * c-opts.c: Remove multiline #include comment.
2557
47ae02b7 25582015-07-12 Aldy Hernandez <aldyh@redhat.com>
2559
2560 * c-common.c: Fix double word typos.
2561
ed2b2eb2 25622015-07-10 Eric Botcazou <ebotcazou@adacore.com>
2563
2564 * c-ada-spec.h (cpp_operation): Revert latest change.
2565 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
2566 constructors and destructors.
2567
1eacc14a 25682015-07-09 Andrew MacLeod <amacleod@redhat.com>
2569
2570 * c-common.h: Adjust includes for flags.h changes.
2571 * stub-objc.c: Likewise.
47ae02b7 2572
0124237f 25732015-07-08 Eric Botcazou <ebotcazou@adacore.com>
2574
2575 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
2576 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
2577
386ef929 25782015-07-08 Jakub Jelinek <jakub@redhat.com>
2579
2580 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
2581 are to be removed, return NULL rather than original clauses list.
2582
9ef16211 25832015-07-07 Andrew MacLeod <amacleod@redhat.com>
2584
2585 * array-notation-common.c: Adjust includes.
2586 * c-ada-spec.c: Likewise.
2587 * c-cilkplus.c: Likewise.
2588 * c-common.h: Likewise.
2589 * c-cppbuiltin.c: Likewise.
2590 * c-dump.c: Likewise.
2591 * c-format.c: Likewise.
2592 * c-gimplify.c: Likewise.
2593 * c-indentation.c: Likewise.
2594 * c-lex.c: Likewise.
2595 * c-omp.c: Likewise.
2596 * c-opts.c: Likewise.
2597 * c-pch.c: Likewise.
2598 * c-ppoutput.c: Likewise.
2599 * c-pragma.c: Likewise.
2600 * c-pretty-print.c: Likewise.
2601 * c-semantics.c: Likewise.
2602 * c-ubsan.c: Likewise.
2603 * cilk.c: Likewise.
2604 * stub-objc.c: Likewise.
2605
67ede3e4 26062015-07-07 Eric Botcazou <ebotcazou@adacore.com>
2607
2608 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
2609 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
2610
42af8c2a 26112015-07-01 Jason Merrill <jason@redhat.com>
2612
fa769cc5 2613 * c-common.h (D_CXX11): Rename from D_CXX0X.
2614 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
2615 * c-common.c: Adjust.
2616
97e9c847 2617 * c-opts.c (c_common_post_options): Default to C++14.
2618
42af8c2a 2619 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
2620
30b1ba42 26212015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
2622
2623 Implement N4197 - Adding u8 character literals
32d050b5 2624 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
95858835 2625 CPP_CHAR.
32d050b5 2626 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
95858835 2627 CPP_UTF8CHAR_USERDEF tokens.
32d050b5 2628 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
95858835 2629 and CPP_UTF8CHAR tokens.
2630 (lex_charconst): Treat CPP_UTF8CHAR token.
30b1ba42 2631
0949f227 26322015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
2633
2634 PR fortran/66605
2635 * c-common.c (do_warn_unused_parameter): Move here.
2636 * c-common.h (do_warn_unused_parameter): Declare.
2637
be23b16f 26382015-06-29 Marek Polacek <polacek@redhat.com>
2639
2640 PR c/66322
2641 * c-common.c (check_case_bounds): Add bool * parameter. Set
2642 OUTSIDE_RANGE_P.
2643 (c_add_case_label): Add bool * parameter. Pass it down to
2644 check_case_bounds.
2645 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
2646 warning here.
2647 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
2648 declarations.
2649
6290f0db 26502015-06-27 Marek Polacek <polacek@redhat.com>
2651
2652 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
2653 or VECTOR_INTEGER_TYPE_P throughout.
2654 * c-gimplify.c: Likewise.
2655
aa3e402e 26562015-06-26 Marek Polacek <polacek@redhat.com>
2657
2658 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
2659 * c-common.c (c_fully_fold_internal): Likewise.
2660 (c_alignof_expr): Likewise.
2661 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
2662 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
8204c077 2663 * cilk.c (create_parm_list): Likewise.
aa3e402e 2664
4e81b384 26652015-06-26 Marek Polacek <polacek@redhat.com>
2666
2667 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
2668
ec2e0095 26692015-06-25 Andrew MacLeod <amacleod@redhat.com>
2670
2671 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
2672 * c-gimplify.c: Likewise.
2673 * c-pragma.c: Likewise.
2674 * c-ubsan.c: Likewise.
2675 * cilk.c: Likewise.
2676
b594087e 26772015-06-25 Richard Sandiford <richard.sandiford@arm.com>
2678
2679 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
2680 ggc_hasher.
2681
a3c76fda 26822015-06-25 Andrew MacLeod <amacleod@redhat.com>
2683
2684 * cilk.c: Move calls.h after tm.h in the include chain.
2685
f48c7f4a 26862015-06-25 Marek Polacek <polacek@redhat.com>
2687
2688 * array-notation-common.c: Use VAR_P throughout.
2689 * c-ada-spec.c: Likewise.
2690 * c-common.c: Likewise.
2691 * c-format.c: Likewise.
2692 * c-gimplify.c: Likewise.
2693 * c-omp.c: Likewise.
2694 * c-pragma.c: Likewise.
2695 * c-pretty-print.c: Likewise.
2696 * cilk.c: Likewise.
2697
ce41e81a 26982015-06-25 Marek Polacek <polacek@redhat.com>
2699
2700 * cilk.c (extract_free_variables): Use is_global_var.
2701
de231ec2 27022015-06-23 Richard Sandiford <richard.sandiford@arm.com>
2703
2704 * c-common.c: Don't include target-def.h.
2705
0200602e 27062015-06-23 Marek Polacek <polacek@redhat.com>
2707
2708 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
2709 when comparing INTEGER_CSTs.
2710
99838ed7 27112015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
2712
2713 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
2714 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
2715 (dump_ada_template): Skip partially specialized types.
2716
a4f59596 27172015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
2718
2719 * c-common.c (scalar_to_vector): Use std::swap instead of manually
2720 swapping.
2721
f2ab3bac 27222015-06-17 Andrew MacLeod <amacleod@redhat.com>
2723
2724 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
2725 * c-ada-spec.c: Likewise.
2726 * c-cilkplus.c: Likewise.
2727 * c-common.c: Likewise.
2728 * c-common.h: Likewise.
2729 * c-cppbuiltin.c: Likewise.
2730 * c-dump.c: Likewise.
2731 * c-format.c: Likewise.
2732 * c-gimplify.c: Likewise.
2733 * c-indentation.c: Likewise.
2734 * c-lex.c: Likewise.
2735 * c-omp.c: Likewise.
2736 * c-opts.c: Likewise.
2737 * c-pch.c: Likewise.
2738 * c-ppoutput.c: Likewise.
2739 * c-pragma.c: Likewise.
2740 * c-pretty-print.c: Likewise.
2741 * c-semantics.c: Likewise.
2742 * c-ubsan.c: Likewise.
2743 * cilk.c: Likewise.
2744 * stub-objc.c: Likewise.
2745
db3d1ffc 27462015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
2747
2748 PR c++/65168
2749 * c-common.c (c_common_truthvalue_conversion): Warn when
2750 converting an address of a reference to a truth value.
2751
64486212 27522015-06-08 Andrew MacLeod <amacleod@redhat.com>
2753
2754 * array-notation-common.c : Adjust include files.
2755 * c-ada-spec.c : Likewise.
2756 * c-cilkplus.c : Likewise.
2757 * c-common.c : Likewise.
2758 * c-common.h : Likewise.
2759 * c-cppbuiltin.c : Likewise.
2760 * c-dump.c : Likewise.
2761 * c-format.c : Likewise.
2762 * c-gimplify.c : Likewise.
2763 * c-indentation.c : Likewise.
2764 * c-lex.c : Likewise.
2765 * c-omp.c : Likewise.
2766 * c-opts.c : Likewise.
2767 * c-pch.c : Likewise.
2768 * c-ppoutput.c : Likewise.
2769 * c-pragma.c : Likewise.
2770 * c-pretty-print.c : Likewise.
2771 * c-semantics.c : Likewise.
2772 * c-ubsan.c : Likewise.
2773 * cilk.c : Likewise.
2774 * stub-objc.c : Likewise.
2775
6e84ccad 27762015-06-08 Marek Polacek <polacek@redhat.com>
2777
2778 PR c/66415
2779 * c-format.c (location_from_offset): Return LOC if LINE is null.
2780
3a1c9df2 27812015-06-05 Aldy Hernandez <aldyh@redhat.com>
2782
2783 * c-common.h (c_parse_final_cleanups): New prototype.
2784 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
2785
32d050b5 27862015-06-04 Sriraman Tallam <tmsriram@google.com>
2787
2788 * c-common.c (noplt): New attribute.
2789 (handle_noplt_attribute): New handler.
2790
f77c0292 27912015-06-04 Andrew MacLeod <amacleod@redhat.com>
2792
2793 * array-notation-common.c: Adjust includes for restructured coretypes.h.
2794 * c-ada-spec.c: Likewise.
2795 * c-cilkplus.c: Likewise.
2796 * c-common.c: Likewise.
2797 * c-common.h: Likewise.
2798 * c-cppbuiltin.c: Likewise.
2799 * c-dump.c: Likewise.
2800 * c-format.c: Likewise.
2801 * c-gimplify.c: Likewise.
2802 * c-indentation.c: Likewise.
2803 * c-lex.c: Likewise.
2804 * c-omp.c: Likewise.
2805 * c-opts.c: Likewise.
2806 * c-pch.c: Likewise.
2807 * c-ppoutput.c: Likewise.
2808 * c-pragma.c: Likewise.
2809 * c-pretty-print.c: Likewise.
2810 * c-semantics.c: Likewise.
2811 * c-ubsan.c: Likewise.
2812 * cilk.c: Likewise.
2813 * stub-objc.c: Likewise.
2814
7c62dfbb 28152015-06-02 David Malcolm <dmalcolm@redhat.com>
2816
2817 PR c/66220:
2818 * c-indentation.c (should_warn_for_misleading_indentation): Use
2819 expand_location rather than expand_location_to_spelling_point.
2820 Don't warn if the guarding statement is more indented than the
2821 next/body stmts.
2822
9af7c176 28232015-06-02 David Malcolm <dmalcolm@redhat.com>
2824
2825 * c-indentation.c (warn_for_misleading_indentation): Bail out
2826 immediately if -Wmisleading-indentation isn't enabled.
2827
eebcf436 28282015-06-01 Martin Liska <mliska@suse.cz>
2829
2830 * c-format.c (check_format_arg):Use new type-based pool allocator.
2831 (check_format_info_main) Likewise.
2832
b0a23e2f 28332015-05-31 Eric Botcazou <ebotcazou@adacore.com>
2834
2835 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
2836 (has_nontrivial_methods): Likewise.
2837
63dc1330 28382015-05-25 Marek Polacek <polacek@redhat.com>
2839
2840 * c-ubsan.c (ubsan_instrument_shift): Use type0.
2841
5a4c69dd 28422015-05-22 Marek Polacek <polacek@redhat.com>
2843
2844 PR c/47043
2845 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
2846
044580bb 28472015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
3764c94e 2848
2849 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
2850 STACK_GROWS_DOWNWARD.
2851
044580bb 28522015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
2b785411 2853
2854 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
2855 STACK_GROWS_DOWNWARD rather than if it is defined.
2856
d5a2ddc7 28572015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
8204c077 2858
d5a2ddc7 2859 PR c/52952
2860 * c-format.c (location_column_from_byte_offset): New.
2861 (location_from_offset): New.
2862 (struct format_wanted_type): Add offset_loc field.
2863 (check_format_info): Move handling of location for extra arguments
2864 closer to the point of warning.
2865 (check_format_info_main): Pass the result of location_from_offset
2866 to warning_at.
2867 (format_type_warning): Pass the result of location_from_offset
2868 to warning_at.
2869
72f8014e 28702015-05-20 Marek Polacek <polacek@redhat.com>
2871
2872 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
2873
74efe522 28742015-05-20 Marek Polacek <polacek@redhat.com>
2875
2876 * c-ada-spec.c (dump_sloc): Use DECL_P.
2877
b443c459 28782015-05-20 Marek Polacek <polacek@redhat.com>
2879
2880 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
2881 * c-common.c: Likewise.
2882
551e34da 28832015-05-19 David Malcolm <dmalcolm@redhat.com>
2884
2885 * c-common.h (fe_file_change): Strengthen param from
2886 const line_map * to const line_map_ordinary *.
2887 (pp_file_change): Likewise.
2888 * c-lex.c (fe_file_change): Likewise.
2889 (cb_define): Use linemap_check_ordinary when invoking
2890 SOURCE_LINE.
2891 (cb_undef): Likewise.
2892 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
2893 invoking cb_file_change.
2894 (c_finish_options): Likewise.
2895 (push_command_line_include): Likewise.
2896 (cb_file_change): Strengthen param "new_map" from
2897 const line_map * to const line_map_ordinary *.
2898 * c-ppoutput.c (cb_define): Likewise for local "map".
2899 (pp_file_change): Likewise for param "map" and local "from".
2900
dfcf26a5 29012015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
2902
2903 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
2904
2e474820 29052015-05-18 Tom de Vries <tom@codesourcery.com>
2906
2907 * c-common.c (build_va_arg_1): New function.
2908 (build_va_arg): Add address operator to va_list operand if necessary.
2909
e53013a8 29102015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
2911
2912 PR c/48956
2913 * c-common.c (int_safely_convertible_to_real_p): Define.
2914 (unsafe_conversion_p): Check conversions involving complex types.
2915 (conversion_warning): Add new warning message for conversions which
2916 discard imaginary component.
2917 * c-common.h: (enum conversion_safety): Add new enumerator for such
2918 conversions.
2919
aac24642 29202015-05-14 Marek Polacek <polacek@redhat.com>
2921
2922 PR c/66066
2923 PR c/66127
2924 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
2925 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
2926 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
2927 use it. If FOR_INT_CONST, require that all evaluated operands be
2928 INTEGER_CSTs.
2929
e5f01cba 29302015-05-12 David Malcolm <dmalcolm@redhat.com>
2931
2932 * c-common.h (warn_for_misleading_indentation): New prototype.
2933 * c-indentation.c: New file.
2934 * c.opt (Wmisleading-indentation): New option.
2935
c37be9ec 29362015-05-12 Tom de Vries <tom@codesourcery.com>
2937
2938 PR tree-optimization/66010
2939 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
2940
7290114b 29412015-05-09 Jason Merrill <jason@redhat.com>
2942
3c665566 2943 * c-opts.c (c_common_post_options): Also clear
2944 cpp_opts->cpp_warn_cxx11_compat.
2945
d875b9d2 2946 * c-common.h (enum cxx_dialect): Add cxx_unset.
2947 * c-common.c (cxx_dialect): Initialize to cxx_unset.
2948 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
2949
7290114b 2950 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
2951 (std=gnu++0x): Mark as Undocumented.
2952 (std=gnu++1y): Add deprecated message.
2953
1b03cc89 29542015-05-08 Jason Merrill <jason@redhat.com>
2955
1c5f7aba 2956 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
2957 * c-opts.c: Adjust.
2958
1b03cc89 2959 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
2960
dc5945dc 29612015-05-08 Marek Polacek <polacek@redhat.com>
2962
2963 PR c/64918
2964 * c.opt (Woverride-init-side-effects): New option.
2965
cdc64059 29662015-05-07 Marek Polacek <polacek@redhat.com>
2967
2968 PR c/65179
2969 * c-common.c (c_fully_fold_internal): Warn when left shifting a
2970 negative value.
2971 * c.opt (Wshift-negative-value): New option.
2972 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
2973 when -Wextra and C99/C++11 mode.
2974
8cafe283 29752015-05-07 Marek Polacek <polacek@redhat.com>
2976 Martin Uecker <uecker@eecs.berkeley.edu>
2977
2978 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
2979 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
2980
cb40a6f7 29812015-05-05 Jason Merrill <jason@redhat.com>
2982
2983 * c.opt (Wterminate): New.
2984
14744a16 29852015-04-30 Marek Polacek <polacek@redhat.com>
2986
2987 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
2988 require that the non-constant be of a boolean type.
2989
9866562d 29902015-04-29 Josh Triplett <josh@joshtriplett.org>
2991
8cafe283 2992 * c-common.c (handle_section_attribute): Refactor to reduce
2993 nesting and distinguish between error cases.
9866562d 2994
a720ab1c 29952015-04-29 Marek Polacek <polacek@redhat.com>
2996
2997 PR c/64610
2998 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
2999 with 0/1.
3000
8c072e52 30012015-04-29 Jakub Jelinek <jakub@redhat.com>
3002
3003 * c-common.h (omp_clause_mask): Unconditionally define as a class.
3004 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
3005 HOST_BITS_PER_WIDE_INT.
3006
f7fec1c7 30072015-04-28 Tom de Vries <tom@codesourcery.com>
3008
3009 PR tree-optimization/65887
3010 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
3011
483b3d26 30122015-04-28 Eric Botcazou <ebotcazou@adacore.com>
8cafe283 3013 Pierre-Marie de Rodat <derodat@adacore.com>
483b3d26 3014
3015 * c-ada-spec.c (in_function): Delete.
3016 (dump_generic_ada_node): Do not change in_function and remove the
3017 redundant code dealing with it.
3018 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
3019 (print_ada_methods): Output the static member functions in a nested
3020 package after the regular methods as well as associated renamings.
3021
f11bdffb 30222015-04-24 Marek Polacek <polacek@redhat.com>
3023
3024 PR c/65830
3025 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
3026 and OPT_Wshift_count_overflow.
3027
485f6b9c 3028 PR c/63357
3029 * c-common.c (warn_logical_operator): Warn if the operands have the
3030 same expressions.
3031
439606a9 30322015-04-24 Marek Polacek <polacek@redhat.com>
3033
3034 PR c/61534
3035 * c-common.c (warn_logical_operator): Bail if either operand comes
3036 from a macro expansion.
3037
de801c28 30382015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
3039
3040 PR target/55143
3041 * c-common.c (c_default_pointer_mode): Add definition.
3042 * c-common.h (c_default_pointer_mode): Add declaration.
3043
76738f56 30442015-03-11 Jakub Jelinek <jakub@redhat.com>
3045
3046 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
3047 on record_builtin_type argument.
3048
16f958b3 30492015-03-10 Jakub Jelinek <jakub@redhat.com>
3050
3051 PR c/65120
3052 * c-common.c (warn_logical_not_parentheses): Don't warn for
3053 !x == 0 or !x != 0.
3054
9b22f73f 30552015-03-07 Marek Polacek <polacek@redhat.com>
3056
3057 PR sanitizer/65280
3058 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
3059 before trying to figure out whether we have a flexible array member.
3060
a864b7d4 30612015-03-06 Eric Botcazou <ebotcazou@adacore.com>
a49621cf 3062 Jonathan Wakely <jwakely.gcc@gmail.com>
a864b7d4 3063
3064 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
3065
9bf8c90b 30662015-03-05 Eric Botcazou <ebotcazou@adacore.com>
3067
3068 PR ada/65319
3069 * c-ada-spec.c (print_destructor): Remove obsolete code.
3070
037ac54f 30712015-03-01 Eric Botcazou <ebotcazou@adacore.com>
3072
3073 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
3074 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
3075 DECL_TEMPLATE_RESULT emulations.
3076 (dump_ada_template)): Add guard for TYPE_METHODS.
3077
495cbfb8 30782015-02-27 Marek Polacek <polacek@redhat.com>
3079
3080 PR c/65040
3081 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
3082
688a864e 30832015-02-27 Kai Tietz <ktietz@redhat.com>
3084
3085 PR c/35330
3086 * c-pragma.c (handle_pragma_weak): Do not try to create
3087 weak/alias of declarations not being function, or variable
3088 declarations.
3089
6349b8cc 30902015-02-24 Thomas Schwinge <thomas@codesourcery.com>
3091
3092 PR libgomp/64625
3093 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
3094 Remove macros.
3095 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
3096
3afd5369 30972015-02-16 Marek Polacek <polacek@redhat.com>
3098
3099 PR c/65066
3100 * c-format.c (check_format_types): Handle null param.
3101
46173d1b 31022015-02-13 Marek Polacek <polacek@redhat.com>
3103
3104 PR c/65040
3105 * c-format.c (check_format_types): Don't warn about different
3106 signedness if the original value is in the range of WANTED_TYPE.
3107
1d524ff7 31082015-02-12 Jason Merrill <jason@redhat.com>
3109
3110 PR c++/64956
3111 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
3112 to the current highest version.
3113 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
3114
bbf8fbec 31152015-02-04 Jakub Jelinek <jakub@redhat.com>
3116
3117 PR c/64824
3118 PR c/64868
3119 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
3120 instead of RDIV_EXPR. Use build_binary_op instead of
3121 build2_loc.
3122
c05be867 31232015-01-30 Joseph Myers <joseph@codesourcery.com>
3124
3125 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
3126 to pass input_location as first argument.
3127
85977647 31282015-01-23 Tom de Vries <tom@codesourcery.com>
3129
3130 PR libgomp/64672
3131 * c.opt (fopenacc): Mark as LTO option.
3132
fa175926 31332015-01-23 Tom de Vries <tom@codesourcery.com>
3134
3135 PR libgomp/64707
3136 * c.opt (fopenmp): Mark as LTO option.
3137
20aad5ba 31382015-01-21 Jakub Jelinek <jakub@redhat.com>
3139
3140 PR c/63307
8204c077 3141 * cilk.c (fill_decls_vec): Only put decls into vector v.
20aad5ba 3142 (compare_decls): Fix up formatting.
3143
31442015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
3145
3146 PR c/63307
3147 * cilk.c: Include vec.h.
3148 (struct cilk_decls): New structure.
3149 (wrapper_parm_cb): Split this function to...
3150 (fill_decls_vec): ...this...
3151 (create_parm_list): ...and this.
3152 (compare_decls): New function.
3153 (for_local_cb): Remove.
3154 (wrapper_local_cb): Ditto.
3155 (build_wrapper_type): For now first traverse and fill vector of
3156 declarations then sort it and then deal with sorted vector.
3157 (cilk_outline): Ditto.
3158 (declare_one_free_variable): Ditto.
3159
60b77e28 31602015-01-21 Jason Merrill <jason@redhat.com>
3161
3162 PR c++/64629
3163 * c-format.c (check_format_arg): Call decl_constant_value.
3164
85fbea97 31652015-01-19 Martin Liska <mliska@suse.cz>
3166
3167 * c-common.c (handle_noicf_attribute): New function.
3168
ca4c3545 31692015-01-15 Thomas Schwinge <thomas@codesourcery.com>
3170 Bernd Schmidt <bernds@codesourcery.com>
3171 James Norris <jnorris@codesourcery.com>
3172 Cesar Philippidis <cesar@codesourcery.com>
3173 Ilmir Usmanov <i.usmanov@samsung.com>
3174 Jakub Jelinek <jakub@redhat.com>
3175
3176 * c.opt (fopenacc): New option.
3177 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
3178 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
3179 New macros.
3180 * c-common.h (c_finish_oacc_wait): New prototype.
3181 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
3182 (c_finish_oacc_wait): New function.
3183 * c-pragma.c (oacc_pragmas): New variable.
3184 (c_pp_lookup_pragma, init_pragma): Handle it.
3185 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
3186 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
3187 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
3188 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
3189 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
3190 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
3191 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
3192 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
3193 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
3194 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
3195 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
3196 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
3197 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
3198 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
3199 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
3200 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
3201 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
3202 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
3203 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
3204 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
3205 PRAGMA_OACC_CLAUSE_WORKER.
3206
92a44a68 32072015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
947aa916 3208
3209 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
3210 for the new option fstack-protector_explicit.
3211 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
3212 (handle_stack_protect_attribute): New function.
3213
92a44a68 32142015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
e4fd7af1 3215
3216 * c.opt: New option -Warray-bounds=.
3217
1f78217c 32182015-01-09 Michael Collison <michael.collison@linaro.org>
3219
3220 * array-notation-common.c: Include hash-set.h, machmode.h,
3221 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3222 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
3223 * c-ada-spec.c: Ditto.
3224 * c-cilkplus.c: Ditto.
3225 * c-common.c: Include input.h due to flattening of tree.h.
3226 Define macro GCC_C_COMMON_C.
3227 * c-common.h: Flatten tree.h header files into c-common.h.
3228 Remove include of tree-core.h.
3229 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
3230 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3231 fold-const.h, wide-int.h, and inchash.h due to
3232 flattening of tree.h.
3233 * c-dump.c: Ditto.
3234 * c-format.c: Flatten tree.h header files into c-common.h.
3235 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
3236 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3237 fold-const.h, wide-int.h, and inchash.h due to
3238 flattening of tree.h.
3239 * c-dump.c: Include hash-set.h, machmode.h,
3240 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3241 fold-const.h, wide-int.h, and inchash.h due to
3242 flattening of tree.h.
3243 * c-format.c: Include hash-set.h, machmode.h,
3244 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3245 fold-const.h, wide-int.h, inchash.h and real.h due to
3246 flattening of tree.h.
3247 * c-gimplify.c: Include hash-set.h, machmode.h,
3248 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3249 fold-const.h, wide-int.h, and inchash.h due to
3250 flattening of tree.h.
3251 * cilk.c: Ditto.
3252 * c-lex.c: Ditto.
3253 * c-omp.c: Ditto.
3254 * c-opts.c: Ditto.
3255 * c-pch.c: Ditto.
3256 * c-ppoutput.c: Ditto.
3257 * c-pragma.c: Ditto.
3258 * c-pretty-print.c: Ditto.
3259 * c-semantics.c: Ditto.
3260 * c-ubsan.c: Ditto.
3261 * stub-objc.c: Ditto.
3262
411b7663 32632015-01-08 Jason Merrill <jason@redhat.com>
3264
3265 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
3266 do_ubsan_in_current_function.
3267 (ubsan_maybe_instrument_reference_or_call): Likewise.
3268 * c-ubsan.h: Declare it.
3269
d1e96383 32702015-01-08 Mike Stump <mikestump@comcast.net>
3271
3272 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
3273
b57910fa 32742015-01-07 Marek Polacek <polacek@redhat.com>
3275
3276 PR c/64440
3277 * c-common.c (c_fully_fold_internal): Warn for division and modulo
3278 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
3279
678a4e3e 32802015-01-05 Trevor Saunders <tsaunders@mozilla.com>
3281
3282 PR c++/31397
3283 * c.opt (Wsuggest-override): New option.
3284
d353bf18 32852015-01-05 Jakub Jelinek <jakub@redhat.com>
3286
3287 Update copyright years.
3288
92b63884 32892015-01-05 Marek Polacek <polacek@redhat.com>
3290
3291 PR c/64423
3292 * c-common.c (warn_array_subscript_with_type_char): Add location_t
3293 parameter. Use it.
3294 * c-common.h (warn_array_subscript_with_type_char): Update
3295 declaration.
3296
83715bc4 32972014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
3298
3299 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
3300 Control macro with flag_sized_deallocation.
3301
92a44a68 33022014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
8a8211df 3303
3304 * c.opt (Wdiscarded-array-qualifiers): New option.
3305
33058239 33062014-12-19 Jakub Jelinek <jakub@redhat.com>
3307
3308 PR preprocessor/63831
3309 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
3310 and __has_cpp_attribute here.
3311 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
3312 c_common_has_attribute.
3313 * c-common.h (c_common_has_attribute): New prototype.
3314 * c-lex.c (init_c_lex): Set cb->has_attribute to
3315 c_common_has_attribute instead of cb_has_attribute.
3316 (get_token_no_padding): New function.
3317 (cb_has_attribute): Renamed to ...
3318 (c_common_has_attribute): ... this. No longer static. Use
3319 get_token_no_padding, require ()s, don't build TREE_LIST
3320 unnecessarily, fix up formatting, adjust diagnostics, call
3321 init_attributes.
3322
d1856d2c 33232014-12-15 Jason Merrill <jason@redhat.com>
3324
3325 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
3326 (-Wsized-deallocation): New.
3327 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
3328 to on in C++14 and up.
3329
4972ed5d 33302014-12-11 Jason Merrill <jason@redhat.com>
3331
7d7fa964 3332 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
3333
4972ed5d 3334 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
3335 we aren't complaining about VLAs.
3336
5ebccf71 33372014-12-06 Marek Polacek <polacek@redhat.com>
3338
3339 PR tree-optimization/64183
3340 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
3341 shift-expression if it is integer_type_node. Use types_compatible_p.
3342
f9e245b2 33432014-11-29 Jakub Jelinek <jakub@redhat.com>
3344
3345 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
3346 last argument from create_tmp_var_raw and create_tmp_var calls.
3347 * cilk.c (gimplify_cilk_spawn): Likewise.
3348 * c-omp.c (c_finish_omp_atomic): Likewise.
3349
d2f60593 33502014-11-28 Marek Polacek <polacek@redhat.com>
3351
3352 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
3353 instead of unsigned_type_node.
3354
fce2dbd1 33552014-11-28 Marek Polacek <polacek@redhat.com>
3356
3357 PR c/63862
3358 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
3359 to op1_utype.
3360 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
3361 expression to unsigned_type_node.
3362
3a4a2292 33632014-11-20 Mark Wielaard <mjw@redhat.com>
3364
3365 PR debug/38757
3366 * c-opts.c (set_std_c89): Set lang_hooks.name.
3367 (set_std_c99): Likewise.
3368 (set_std_c11): Likewise.
3369 (set_std_cxx98): Likewise.
3370 (set_std_cxx11): Likewise.
3371 (set_std_cxx14): Likewise.
3372 (set_std_cxx1z): Likewise.
3373
c61ef207 33742014-11-21 Jakub Jelinek <jakub@redhat.com>
3375
3376 PR target/63764
3377 * c-common.h (convert_vector_to_pointer_for_subscript): Change
3378 return type to bool.
c9ed79de 3379 * c-common.c: Include gimple-expr.h.
c61ef207 3380 (convert_vector_to_pointer_for_subscript): Change return type to
3381 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
3382 and copy it into a TARGET_EXPR and use that instead of *vecp
3383 directly.
3384
1a91d914 33852014-11-19 David Malcolm <dmalcolm@redhat.com>
3386
3387 Merger of git branch "gimple-classes-v2-option-3".
3388 * ChangeLog.gimple-classes: New.
3389 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
3390 from being just a vec<gimple> to a vec<gbind *>.
3391
f8fc8b8e 33922014-11-18 Jakub Jelinek <jakub@redhat.com>
3393
3394 PR sanitizer/63813
3395 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
3396 argument to ptype, set type to TREE_TYPE (ptype). Don't call
3397 get_pointer_alignment for non-pointers. Use ptype, or if it is
3398 reference type, corresponding pointer type, as type of kind
3399 argument.
3400 (ubsan_maybe_instrument_reference,
3401 ubsan_maybe_instrument_member_call): Adjust callers.
3402
8315e35e 34032014-11-15 Marek Polacek <polacek@redhat.com>
3404
3405 PR middle-end/63884
3406 * array-notation-common.c (is_sec_implicit_index_fn): Return false
3407 for NULL fndecl.
3408 (extract_array_notation_exprs): Return for NULL node.
3409
86b9f14b 34102014-11-12 Joseph Myers <joseph@codesourcery.com>
3411
3412 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
3413 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
3414
0c93c8a9 34152014-11-12 Jakub Jelinek <jakub@redhat.com>
3416
3417 PR c/59708
3418 * c-common.c (check_builtin_function_arguments): Handle
3419 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
3420
fdd735a7 34212014-11-10 Andi Kleen <ak@linux.intel.com>
3422
3423 PR c/60804
3424 * c-common.h (check_no_cilk): Declare.
3425 * cilk.c (get_error_location): New function.
3426 (check_no_cilk): Dito.
3427
5cb678b4 34282014-11-10 Andi Kleen <ak@linux.intel.com>
3429
3430 * cilk.c (recognize_spawn): Use expression location
3431 for error message.
3432
0feb4de1 34332014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
3434
3435 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
3436
3aa2fa44 34372014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
3438
3439 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
3440 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
3441 (__cpp_range_based_for, __cpp_initializer_lists,
3442 __cpp_delegating_constructors, __cpp_nsdmi,
3443 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
3444 for C++11; (__cpp_attribute_deprecated): Remove in favor of
3445 __has_cpp_attribute.
3446 * c-lex.c (cb_has_attribute): New callback CPP function;
3447 (init_c_lex): Set has_attribute callback.
3448
7fd22aae 34492014-11-04 Richard Biener <rguenther@suse.de>
3450
3451 * c-common.c (shorten_compare): Do not shorten mixed
3452 DFP and non-DFP compares.
3453
4af203ac 34542014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
3455
3456 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
3457 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
3458 Commentary and rearrangement of tests.
3459 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
3460 Commentary and rearrangement of tests.
3461 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto
3462 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
3463
3754d046 34642014-10-29 Richard Sandiford <richard.sandiford@arm.com>
3465
3466 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
3467 enum from machine_mode.
3468
1140c305 34692014-10-28 Andrew MacLeod <amacleod@redhat.com>
3470
1f78217c 3471 * c-common.c: Adjust include files.
3472 * c-gimplify.c: Ditto.
3473 * cilk.c: Ditto.
3474 * c-pragma.c: Ditto.
3475 * c-ubsan.c: Ditto.
1140c305 3476
94ea8568 34772014-10-27 Andrew MacLeod <amacleod@redhat.com>
3478
3479 * c-gimplify.c: Adjust include files.
3480
32ecf960 34812014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
3482
3483 PR c++/53061
3484 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
3485 c_common_initialize_diagnostics.
3486 * c-common.h: Likewise.
3487
85fecbe2 34882014-10-24 Marek Polacek <polacek@redhat.com>
3489
3490 PR c/56980
3491 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
3492 print "struct"/"union"/"enum" for typedefed names.
3493
e7ec033a 34942014-10-23 Marek Polacek <polacek@redhat.com>
3495
3496 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
3497 in unsigned type.
3498
c2598081 34992014-10-22 Jakub Jelinek <jakub@redhat.com>
3500 Yury Gribov <y.gribov@samsung.com>
3501
3502 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
3503 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
3504 instead of flag_sanitize_recover as bool flag.
3505
acebb7e2 35062014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
3507
3508 * cilk.c: Revert previous change.
3509
6115016c 35102014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
3511
3512 PR c/63307
3513 * cilk.c: Include vec.h.
3514 (struct cilk_decls): New structure.
3515 (wrapper_parm_cb): Split this function to...
3516 (fill_decls_vec): ...this...
3517 (create_parm_list): ...and this.
3518 (compare_decls): New function.
3519 (for_local_cb): Remove.
3520 (wrapper_local_cb): Ditto.
3521 (build_wrapper_type): For now first traverse and fill vector of
3522 declarations then sort it and then deal with sorted vector.
3523 (cilk_outline): Ditto.
3524 (declare_one_free_variable): Ditto.
3525
e610d2b2 35262014-10-17 Marek Polacek <polacek@redhat.com>
3527
3528 * c-opts.c (c_common_post_options): Set warn_implicit_int.
3529 * c.opt (Wimplicit-int): Initialize to -1.
3530
a3020f2f 35312014-10-16 Andrew MacLeod <amacleod@redhat.com>
3532
3533 * c-pragma.c: Adjust include files.
3534 * c-semantics.c: Likewise.
3535
926ddd2c 35362014-10-16 DJ Delorie <dj@redhat.com>
3537
3538 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
3539 multiples of bytes.
3540
b0542e7c 35412014-10-14 Jason Merrill <jason@redhat.com>
3542
3543 PR c++/63455
3544 * c-common.h (CPP_PREPARSED_EXPR): New.
3545 (N_CP_TTYPES): Adjust.
3546
b2601928 35472014-10-15 Marek Polacek <polacek@redhat.com>
3548
3549 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
3550
9f75f026 35512014-10-14 DJ Delorie <dj@redhat.com>
3552
3553 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
3554 types, not just __int128.
3555 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
3556 types, not just __int128.
3557 (cpp_atomic_builtins): Round pointer sizes up.
3558 (type_suffix): Use type precision, not specific types.
3559 * c-common.c (c_common_reswords): Remove __int128 special case.
3560 (c_common_type_for_size): Check for all __intN types, not just
3561 __int128.
3562 (c_common_type_for_mode): Likewise.
3563 (c_common_signed_or_unsigned_type): Likewise.
3564 (c_build_bitfield_integer_type): Likewise.
3565 (c_common_nodes_and_builtins): Likewise.
3566 (keyword_begins_type_specifier): Likewise.
3567 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
3568 __intN variants.
3569
2ef51f0e 35702014-10-12 Trevor Saunders <tsaunders@mozilla.com>
3571
3572 * c-common.c: Use hash_table instead of hashtab.
3573
5b8257e3 35742014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
3575
1f78217c 3576 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
5b8257e3 3577 C++11 section.
3578
5e84569c 35792014-10-03 Marc Glisse <marc.glisse@inria.fr>
3580
3581 PR c++/54427
3582 PR c++/57198
3583 PR c++/58845
3584 * c-common.c (warn_logical_operator): Punt for vectors.
3585
f6751ff2 35862014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
3587
3588 Implement SD-6: SG10 Feature Test Recommendations
3589 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
3590 macros and the __has_header macro.
3591
c33e051d 35922014-09-30 Jason Merrill <jason@redhat.com>
3593
f76a9aa8 3594 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
3595 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
3596 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
3597
717e52f9 3598 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
3599 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
3600
c33e051d 3601 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
3602 * c-common.c (c_common_reswords): Remove __is_convertible_to.
3603
5213d6c9 36042014-09-24 Marek Polacek <polacek@redhat.com>
3605
3606 PR c/61405
3607 PR c/53874
3608 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
3609
6b722052 36102014-09-23 Andi Kleen <ak@linux.intel.com>
3611
3612 * c-common.c (handle_no_reorder_attribute): New function.
3613 (c_common_attribute_table): Add no_reorder attribute.
3614
0cb69d12 36152014-09-22 Joseph Myers <joseph@codesourcery.com>
3616
3617 * c-cppbuiltin.c (c_cpp_builtins): Define
3618 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
3619 modes.
3620
168dfbf0 36212014-09-18 Joseph Myers <joseph@codesourcery.com>
3622
3623 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
3624 for supported floating-point modes.
3625
b83705f4 36262014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
3627
3628 * c.opt (Wpsabi): Use LangEnabledBy.
3629 * c-opts.c (c_common_handle_option): Do not handle here.
3630
d5957f0d 36312014-09-12 Joseph Myers <joseph@codesourcery.com>
3632
3633 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
3634 macros for floating-point modes.
3635
bae6edff 36362014-09-11 Marc Glisse <marc.glisse@inria.fr>
3637
3638 PR target/58757
3639 * c-cppbuiltin.c (builtin_define_float_constants): Correct
3640 __*_DENORM_MIN__ without denormals.
3641
73a69d02 36422014-09-10 Jakub Jelinek <jakub@redhat.com>
3643
3644 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
3645 ubsan_instrument_vla, ubsan_instrument_return): Adjust
3646 ubsan_create_data callers.
3647 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
3648 index is constant or BIT_AND_EXPR with constant mask and is
3649 small enough for the bound.
3650 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
3651 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
3652
7ff8db31 36532014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
3654
3655 * c.opt: Add CppReason to various flags.
3656 (Wdate-time): Re-sort.
3657 * c-common.c: Include c-common.h earlier.
3658 (struct reason_option_codes_t): Delete.
3659 (c_option_controlling_cpp_error): Prefix global type and struct
3660 with cpp_.
3661
bcc1f37e 36622014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
3663
3664 * c.opt (Wnormalized): New.
3665 (Wnormalized=): Use Enum and Reject Negative.
3666 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
3667
b660d3c6 36682014-09-08 Joseph Myers <joseph@codesourcery.com>
3669
3670 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
3671 digits of floating-point modes if -fbuilding-libgcc.
3672
325b8c3c 36732014-09-05 Joseph Myers <joseph@codesourcery.com>
3674
3675 * c-cppbuiltin.c (c_cpp_builtins): Also define
3676 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
3677 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
3678 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
3679 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
3680 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
3681 __LIBGCC_STACK_GROWS_DOWNWARD__,
3682 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
3683 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
3684 __LIBGCC_DWARF_FRAME_REGISTERS__,
3685 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
3686 __LIBGCC_STACK_POINTER_REGNUM__ and
3687 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
3688 (builtin_define_with_value): Handle backslash-escaping in string
3689 macro values.
3690
1e074e77 36912014-09-05 Richard Biener <rguenther@suse.de>
3692
3693 PR middle-end/63148
3694 * c-format.c (check_format_arg): Properly handle
3695 effectively signed POINTER_PLUS_EXPR offset.
3696
04afd878 36972014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
3698
3699 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
3700 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
3701 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
3702 and Init.
3703 * c-opts.c (c_common_handle_option): Do not handle here.
3704 (sanitize_cpp_opts): Likewise.
3705 * c-common.c (struct reason_option_codes_t): Handle
3706 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
3707
a3f448f0 37082014-09-03 Marek Polacek <polacek@redhat.com>
3709
3710 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
3711
40750995 37122014-09-02 Jakub Jelinek <jakub@redhat.com>
3713 Balaji V. Iyer <balaji.v.iyer@intel.com>
3714 Igor Zamyatin <igor.zamyatin@intel.com>
3715
3716 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
3717 * c-common.c (c_common_reswords): Added _Cilk_for.
3718 * c-common.h (enum rid): Added RID_CILK_FOR.
3719 (cilk_for_number_of_iterations): Add declaration.
3720 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
3721 CILK_FOR.
3722 * c-pragma.c (init_pragma): Register "grainsize" pragma.
3723 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
3724
f0fbe519 37252014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
3726
3727 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
3728 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
3729 Wundef): Use CPP, Var and Init.
3730 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
3731
a7d2e480 37322014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
3733
3734 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
3735 * c-opts.c (c_common_handle_option): Do not handle here.
3736
c35e53f1 37372014-08-25 Jason Merrill <jason@redhat.com>
3738
3739 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
3740 -std=c++14 and -std=gnu++14, rather than the reverse.
3741 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
3742 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
3743 * c-common.h (cxx_dialect): Remove cxx1y.
3744
4e454776 37452014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
3746
3747 * c-common.h (enum cxx_dialect): Add cxx14.
3748 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
3749 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
3750 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
3751
af1a80f2 37522014-08-22 Jason Merrill <jason@redhat.com>
3753
3754 * c.opt (std=gnu++17): Fix alias.
3755
dc6229e8 37562014-08-22 Marek Polacek <polacek@redhat.com>
3757
3758 PR c++/62199
3759 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
3760 check for vector types. Drop LHS argument.
3761 * c-common.h (warn_logical_not_parentheses): Adjust.
3762
ba7f7c88 37632014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
3764
3765 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
3766 (Wmultichar): Likewise.
3767 (Wdate-time): Use C-family languages instead of Common. Use CPP
3768 and Var.
3769 * c-opts.c (c_common_handle_option): Do not handle the above
3770 options here.
3771 (sanitize_cpp_opts): Likewise.
3772
399d4f80 37732014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
3774
3775 PR fortran/44054
3776 * c-opts.c: Include tree-diagnostics.h.
3777 (c_diagnostic_finalizer): New.
3778 (c_common_initialize_diagnostics): Use it.
3779
1babed5f 37802014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
3781
3782 PR preprocessor/51303
3783 * c-common.c (struct reason_option_codes_t option_codes):
3784 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
3785
3636964b 37862014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
3787
3788 PR c/60975
3789 PR c/53063
3790 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
3791 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
3792 (c_common_post_options): Call init_global_opts_from_cpp.
3793 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
3794
78bf4156 37952014-08-19 Marek Polacek <polacek@redhat.com>
3796
3797 PR c++/62153
3798 * c-common.c (maybe_warn_bool_compare): New function.
3799 * c-common.h (maybe_warn_bool_compare): Declare.
3800 * c.opt (Wbool-compare): New option.
3801
508ea33a 38022014-08-19 Marek Polacek <polacek@redhat.com>
3803
3804 * c.opt (Wc99-c11-compat): New option.
3805
806fe15e 38062014-08-19 Marek Polacek <polacek@redhat.com>
3807
3808 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
3809 to warn_c90_c99_compat.
3810 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
3811 to -1.
3812
6c867de1 38132014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
3814 Steven Bosscher <steven@gcc.gnu.org>
3815
3816 PR c/52952
3817 * c-format.c: Add extra_arg_loc and format_string_loc to struct
3818 format_check_results.
3819 (check_function_format): Use true and add comment for boolean
3820 argument.
3821 (finish_dollar_format_checking): Use explicit location when warning.
3822 (check_format_info): Likewise.
3823 (check_format_arg): Set extra_arg_loc and format_string_loc.
3824 (check_format_info_main): Use explicit location when warning.
3825 (check_format_types): Pass explicit location.
3826 (format_type_warning): Likewise.
3827
dc8078a3 38282014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
3829
3830 PR fortran/44054
3831 * c-format.c: Handle Fortran flags.
3832
d271ec7e 38332014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
3834
3835 PR other/61962
3836 * array-notation-common.c (find_rank): Added handling for other
3837 types of references.
3838
890c2e2f 38392014-08-10 Marek Polacek <polacek@redhat.com>
3840
3841 PR c/51849
3842 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
3843 * c.opt (Wc90-c99-compat): Add option.
3844
7149db5f 38452014-08-07 Trevor Saunders <tsaunders@mozilla.com>
3846
3847 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
3848
2d2f6a15 38492014-08-03 Marek Polacek <polacek@redhat.com>
3850
3851 * c-common.c (check_case_value): Add location_t parameter. Use it.
3852 (c_add_case_label): Pass loc to check_case_value.
3853
06ecf488 38542014-08-02 Trevor Saunders <tsaunders@mozilla.com>
3855
3856 * cilk.c: Use hash_map instead of pointer_map.
3857
431205b7 38582014-08-02 Trevor Saunders <tsaunders@mozilla.com>
3859
3860 * c-gimplify.c: Use hash_set instead of pointer_set.
3861
3394c80c 38622014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
3863
3864 PR middle-end/61455
3865 * array-notation-common.c (extract_array_notation_exprs): Handling
3866 of DECL_EXPR added.
3867
392dee1e 38682014-08-01 Jakub Jelinek <jakub@redhat.com>
3869
3870 * c-common.h (min_align_of_type): Removed prototype.
3871 * c-common.c (min_align_of_type): Removed.
3872 * c-ubsan.h (ubsan_maybe_instrument_reference,
3873 ubsan_maybe_instrument_member_call): New prototypes.
3874 * c-ubsan.c: Include stor-layout.h and builtins.h.
3875 (ubsan_maybe_instrument_reference_or_call,
3876 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
3877 functions.
3878
f22a2cb7 38792014-07-31 Marc Glisse <marc.glisse@inria.fr>
3880
3881 PR c++/60517
3882 * c.opt (-Wreturn-local-addr): Move to common.opt.
3883
87b0198f 38842014-07-30 Jason Merrill <jason@redhat.com>
3885
3886 PR c++/61659
3887 PR c++/61687
3888 Revert:
3889 * c.opt (-fuse-all-virtuals): New.
3890
74691f46 38912014-07-30 Tom Tromey <tromey@redhat.com>
3892
3893 PR c/59855
3894 * c.opt (Wdesignated-init): New option.
3895 * c-common.c (c_common_attribute_table): Add "designated_init".
3896 (handle_designated_init): New function.
3897
9140d56f 38982014-07-24 Marek Polacek <polacek@redhat.com>
3899
3900 PR c/57653
3901 * c-opts.c (c_finish_options): If -imacros is in effect, return.
3902
a09c5cc2 39032014-07-16 Dodji Seketeli <dodji@redhat.com>
3904
3905 PR preprocessor/60723 - missing system-ness marks for macro tokens
3906 * c-ppoutput.c (struct print::prev_was_system_token): New data
3907 member.
3908 (init_pp_output): Initialize it.
3909 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
3910 (do_line_change): Return a flag saying if a line marker was
3911 emitted or not.
3912 (scan_translation_unit): Detect if the system-ness of the token we
3913 are about to emit is different from the one of the previously
3914 emitted token. If so, emit a line marker. Avoid emitting useless
3915 adjacent line markers. Avoid emitting line markers for tokens
3916 originating from the expansion of built-in macros.
3917 (scan_translation_unit_directives_only): Adjust.
3918
2b25b62f 39192014-07-15 Marek Polacek <polacek@redhat.com>
3920
3921 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
3922 TYPE_MAX_VALUE is NULL.
3923
305d96bc 39242014-07-14 Jakub Jelinek <jakub@redhat.com>
3925
3926 PR middle-end/61294
3927 * c.opt (Wmemset-transposed-args): New warning.
3928
8ea4660d 39292014-07-10 Jason Merrill <jason@redhat.com>
3930
3931 PR c++/61659
3932 PR c++/61687
3933 * c.opt (-fuse-all-virtuals): New.
3934
cd480f3d 39352014-07-09 Richard Biener <rguenther@suse.de>
3936
3937 PR c-family/61741
3938 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
3939 using unsigned arithmetic if overflow does not wrap instead of
3940 if overflow is undefined.
3941
87d59e72 39422014-07-06 Marek Polacek <polacek@redhat.com>
3943
3944 PR c/6940
3945 * c.opt (Wsizeof-array-argument): New option.
3946
d69521d8 39472014-07-03 Jakub Jelinek <jakub@redhat.com>
3948
8204c077 3949 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
d69521d8 3950 comments->count <= 1, as comments->entries might be NULL.
3951
1207866e 39522014-07-01 Marek Polacek <polacek@redhat.com>
3953
3954 * c.opt (Wint-conversion): New option.
3955
7a6bbb76 39562014-07-01 Marek Polacek <polacek@redhat.com>
3957
3958 PR c/58286
3959 * c.opt (Wincompatible-pointer-types): New option.
3960
9d4eeb52 39612014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
3962
3963 PR c++/51400
3964 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
3965 Do not discard TYPE_QUALS of type.
3966
4b53bc0f 39672014-06-26 Jason Merrill <jason@redhat.com>
3968
3969 * c-common.h (enum cxx_dialect): Add cxx1z.
3970 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
3971 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
3972
a8a8d4ea 39732014-06-26 Teresa Johnson <tejohnson@google.com>
3974
3975 * c-common.h (get_dump_info): Declare.
3976 * c-gimplify.c (c_genericize): Use saved dump files.
3977 * c-opts.c (c_common_parse_file): Begin and end dumps
3978 once around parsing invocation.
3979 (get_dump_info): New function.
3980
1f6be080 39812014-06-23 Marek Polacek <polacek@redhat.com>
3982 Andrew MacLeod <amacleod@redhat.com>
3983
3984 PR c/61553
3985 * c-common.c (get_atomic_generic_size): Don't segfault if the
3986 type doesn't have a size.
3987
5ef6b660 39882014-06-20 Marek Polacek <polacek@redhat.com>
3989
3990 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
3991 (ubsan_walk_array_refs_r): New function.
3992 (c_genericize): Instrument array bounds.
3993 * c-ubsan.c: Include "internal-fn.h".
3994 (ubsan_instrument_division): Mark instrumented arrays as having
3995 side effects. Adjust ubsan_type_descriptor call.
3996 (ubsan_instrument_shift): Likewise.
3997 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
3998 (ubsan_instrument_bounds): New function.
3999 (ubsan_array_ref_instrumented_p): New function.
4000 (ubsan_maybe_instrument_array_ref): New function.
4001 * c-ubsan.h (ubsan_instrument_bounds): Declare.
4002 (ubsan_array_ref_instrumented_p): Declare.
4003 (ubsan_maybe_instrument_array_ref): Declare.
4004
40052014-06-20 Hale Wang <hale.wang@arm.com>
3ccd1e6e 4006
4007 PR lto/61123
4008 * c.opt (fshort-enums): Add to LTO.
4009 * c.opt (fshort-wchar): Likewise.
4010
78438f31 40112014-06-16 Marek Polacek <polacek@redhat.com>
4012
4013 PR c/60439
4014 * c.opt (Wswitch-bool): Add Var.
4015
5fddcf34 40162014-06-12 Jakub Jelinek <jakub@redhat.com>
4017
4018 PR middle-end/61486
4019 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
4020 #pragma omp target teams or
4021 #pragma omp {,target }teams distribute simd.
4022
74b777e5 40232014-06-12 Jason Merrill <jason@redhat.com>
4024
4025 * c.opt (Wabi=, fabi-compat-version): New.
4026 * c-opts.c (c_common_handle_option): Handle -Wabi=.
4027 (c_common_post_options): Handle flag_abi_compat_version default.
4028 Disallow -fabi-compat-version=1.
4029 * c-common.h (abi_version_crosses): New.
4030
738a6bda 40312014-06-11 Jan Hubicka <hubicka@ucw.cz>
4032
1f78217c 4033 * c-common.c (handle_section_attribute): Update handling for
738a6bda 4034 section names that are no longer trees.
4035
cf5f881f 40362014-06-10 Jakub Jelinek <jakub@redhat.com>
4037
4038 PR fortran/60928
4039 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
4040 (omp_pragmas): ... back here.
4041
32dc1512 40422014-06-05 Marek Polacek <polacek@redhat.com>
4043
4044 PR c/49706
4045 * c-common.c (warn_logical_not_parentheses): New function.
4046 * c-common.h (warn_logical_not_parentheses): Declare.
4047 * c.opt (Wlogical-not-parentheses): New option.
4048
f61a9bc2 40492014-06-04 Marek Polacek <polacek@redhat.com>
4050
4051 PR c/30020
4052 * c-common.c (check_case_bounds): Add location parameter.
4053 Use it.
4054 (c_add_case_label): Pass loc to check_case_bounds.
4055
c69ec07d 40562014-06-03 Marek Polacek <polacek@redhat.com>
4057
4058 PR c/60439
4059 * c.opt (Wswitch-bool): New option.
4060
3c77ca67 40612014-05-22 Thomas Schwinge <thomas@codesourcery.com>
4062
68a2c870 4063 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
4064 Remove prototypes.
4065 (record_types_used_by_current_var_decl): Move prototype to where
4066 it belongs.
4067
3c77ca67 4068 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
4069 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
4070 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
4071
3ab4693e 40722014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
4073
4074 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
4075 * c-common.c (c_common_nodes_and_builtins): Don't initialize
4076 void_zero_node.
4077 * c-pretty-print.c (pp_c_void_constant): New function.
4078 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
4079 (c_pretty_printer::expression): Handle VOID_CST.
4080 * cilk.c (extract_free_variables): Likewise.
4081 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
4082 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
4083
25a27413 40842014-05-17 Trevor Saunders <tsaunders@mozilla.com>
4085
4086 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
4087 * c-pragma.c (push_alignment): Adjust.
4088 (handle_pragma_push_options): Likewise.
4089
3e5a8b00 40902014-05-09 Marek Polacek <polacek@redhat.com>
4091
4092 PR c/50459
4093 * c-common.c (check_user_alignment): Return -1 if alignment is error
4094 node.
4095 (handle_aligned_attribute): Don't call default_conversion on
4096 FUNCTION_DECLs.
4097 (handle_vector_size_attribute): Likewise.
4098 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
4099 (handle_sentinel_attribute): Call default_conversion and allow even
4100 integral types as an argument.
4101
c2c4ae8d 41022014-05-08 Marek Polacek <polacek@redhat.com>
4103
4104 PR c/61053
4105 * c-common.c (min_align_of_type): New function factored out from...
4106 (c_sizeof_or_alignof_type): ...here.
4107 * c-common.h (min_align_of_type): Declare.
4108
2026249a 41092014-05-08 Marek Polacek <polacek@redhat.com>
4110
4111 PR c/61077
4112 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
4113 parameter type of main.
4114
33c8dcfe 41152014-05-07 DJ Delorie <dj@redhat.com>
4116
4117 * c-cppbuiltin.c (print_bits_of_hex): New.
4118 (builtin_define_type_minmax): Print values using hex so as not to
4119 require a pre-computed list of string values.
4120
960d5a55 41212014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
4122 Mike Stump <mikestump@comcast.net>
4123 Richard Sandiford <rdsandiford@googlemail.com>
4124
4125 * c-ada-spec.c: Include wide-int.h.
4126 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
4127 (dump_generic_ada_node): Use wide-int interfaces.
4128 * c-common.c: Include wide-int-print.h.
4129 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
4130 (pointer_int_sum): Use wide-int interfaces.
4131 (c_common_nodes_and_builtins): Use make_int_cst.
4132 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
4133 (handle_alloc_size_attribute): Use wide-int interfaces.
4134 (get_nonnull_operand): Likewise.
4135 * c-format.c (get_constant): Use tree_fits_uhwi_p.
4136 * c-lex.c: Include wide-int.h.
4137 (narrowest_unsigned_type): Take a widest_int rather than two
4138 HOST_WIDE_INTs.
4139 (narrowest_signed_type): Likewise.
4140 (interpret_integer): Update accordingly. Use wide-int interfaces.
4141 (lex_charconst): Use wide-int interfaces.
4142 * c-pretty-print.c: Include wide-int.h.
4143 (pp_c_integer_constant): Use wide-int interfaces.
4144 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
4145 INT_CST_LT_UNSIGNED.
4146
bbb88b31 41472014-05-06 Richard Biener <rguenther@suse.de>
4148
4149 * c-opts.c (c_common_post_options): For -freestanding,
4150 -fno-hosted and -fno-builtin disable pattern recognition
4151 if not enabled explicitely.
4152
022d4718 41532014-05-02 Marek Polacek <polacek@redhat.com>
4154
4155 * c.opt (Wsizeof-pointer-memaccess): Describe option.
4156
e4ab2ef3 41572014-05-01 Marek Polacek <polacek@redhat.com>
4158
4159 PR c/43245
4160 * c.opt (Wdiscarded-qualifiers): Add.
4161
52cc0072 41622014-04-30 Marek Polacek <polacek@redhat.com>
4163
4164 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
4165 INT_MIN / -1 sanitization only for integer types.
4166
4a026b48 41672014-04-25 Marek Polacek <polacek@redhat.com>
4168
4169 PR c/18079
4170 * c-common.c (handle_noinline_attribute): Warn if the attribute
4171 conflicts with always_inline attribute.
4172 (handle_always_inline_attribute): Warn if the attribute conflicts
4173 with noinline attribute.
4174
90e645fa 41752014-04-25 Marek Polacek <polacek@redhat.com>
4176
4177 PR c/60156
4178 * c-common.c (check_main_parameter_types): Warn about variadic main.
4179
db103ea4 41802014-04-24 Mike Stump <mikestump@comcast.net>
4181
4182 * c.opt (Wshadow-ivar): Default to on.
4183
06511efd 41842014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
4185
4186 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
4187
cdf34fca 41882014-04-23 Marek Polacek <polacek@redhat.com>
4189
4190 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
4191
7311d7c1 41922014-04-22 Jakub Jelinek <jakub@redhat.com>
4193
4194 PR sanitizer/60275
4195 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
4196 if flag_sanitize_undefined_trap_on_error.
4197 (ubsan_instrument_division, ubsan_instrument_shift,
4198 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
4199 if !flag_sanitize_recover.
4200
c1917557 42012014-04-22 Marc Glisse <marc.glisse@inria.fr>
4202
4203 PR libstdc++/43622
4204 * c-common.c (registered_builtin_types): Make non-static.
4205 * c-common.h (registered_builtin_types): Declare.
4206
b2ca6510 42072014-04-14 Richard Biener <rguenther@suse.de>
4208 Marc Glisse <marc.glisse@inria.fr>
4209
4210 PR c/60819
4211 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
4212 apply may-alias the scalar pointer type when applicable.
4213
855372a3 42142014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
4215
4216 PR middle-end/60467
4217 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
4218 as possible argument for Cilk_spawn.
4219
4012a986 42202014-04-11 Tobias Burnus <burnus@net-b.de>
4221
4222 PR c/60194
4223 * c.opt (Wformat-signedness): Add
4224 * c-format.c(check_format_types): Use it.
4225
0d284870 42262014-04-11 Jason Merrill <jason@redhat.com>
4227
4228 PR c++/57926
4229 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
4230 default_conversion for an array argument.
4231
a34c1231 42322014-04-08 Marek Polacek <polacek@redhat.com>
4233
4234 PR sanitizer/60745
4235 * c-ubsan.c: Include asan.h.
4236 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
4237
a35a8e18 42382014-04-03 Nathan Sidwell <nathan@codesourcery.com>
4239
4240 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
4241
b23e42b6 42422014-04-02 Marek Polacek <polacek@redhat.com>
4243
4244 * c-common.h (c_expand_expr): Remove declaration.
4245
5a672e62 42462014-03-28 Jakub Jelinek <jakub@redhat.com>
4247
4248 PR c++/60689
4249 * c-common.c (add_atomic_size_parameter): When creating new
4250 params vector, push the size argument first.
4251
d4d068c0 42522014-03-26 Jakub Jelinek <jakub@redhat.com>
4253
4254 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
4255 ubsan_instrument_vla, ubsan_instrument_return): Adjust
4256 ubsan_create_data callers.
4257
446bdf5f 42582014-03-22 Jakub Jelinek <jakub@redhat.com>
4259
4260 PR debug/60603
4261 * c-opts.c (c_finish_options): Restore cb_file_change call to
4262 <built-in>.
4263
8895f0a3 42642014-03-13 Jakub Jelinek <jakub@redhat.com>
4265
4266 PR middle-end/36282
4267 * c-pragma.c (apply_pragma_weak): Only look at
4268 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
4269 DECL_ASSEMBLER_NAME_SET_P (decl).
4270 (maybe_apply_pending_pragma_weaks): Exit early if
4271 vec_safe_is_empty (pending_weaks) rather than only when
4272 !pending_weaks.
4273 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
4274 set assembler name back to NULL afterwards.
4275
7a5da2cd 42762014-03-11 Jason Merrill <jason@redhat.com>
4277
4278 * c.opt: Add -std=gnu++14.
4279
95093889 42802014-03-11 Ian Bolton <ian.bolton@arm.com>
4281
4282 * c-opts.c (c_common_post_options): Don't override
4283 -ffp-contract=fast if unsafe-math-optimizations is on.
4284
c9a24b37 42852014-03-08 Paulo Matos <paulo@matos-sorge.com>
4286
9b8f3aa1 4287 * c.opt: Enable LTO FE for fshort-double.
c9a24b37 4288
3f6dba6e 42892014-03-07 Jason Merrill <jason@redhat.com>
4290
4291 * c.opt: Add -std=c++14.
4292
3bfdc94f 42932014-03-06 Marek Polacek <polacek@redhat.com>
4294
4295 PR c/60197
4296 * cilk.c (contains_cilk_spawn_stmt): New function.
4297 (contains_cilk_spawn_stmt_walker): Likewise.
4298 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
4299 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
4300
8b3a6a4c 43012014-03-03 Jakub Jelinek <jakub@redhat.com>
4302
4303 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
4304 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
4305 even when flag_preprocess_only.
4306
734ec290 43072014-02-26 Jason Merrill <jason@redhat.com>
4308
4309 PR c++/59231
4310 PR c++/11586
4311 * c-common.c (shorten_compare): Don't check
4312 c_inhibit_evaluation_warnings.
4313
81aec8b8 43142014-02-19 Jakub Jelinek <jakub@redhat.com>
4315
d1081017 4316 PR c/37743
4317 * c-common.c (c_common_nodes_and_builtins): When initializing
4318 c_uint{16,32,64}_type_node, also set corresponding
4319 uint{16,32,64}_type_node to the same value.
4320
81aec8b8 4321 PR c++/60267
4322 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
4323 for PRAGMA_IVDEP if flag_preprocess_only.
4324
312243bb 43252014-02-12 Jakub Jelinek <jakub@redhat.com>
4326
4327 PR c/60101
4328 * c-common.c (merge_tlist): If copy is true, call new_tlist,
4329 if false, add ADD itself, rather than vice versa.
4330 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
4331 copy. For SAVE_EXPR, only call merge_tlist once.
4332
237e78b1 43332014-02-08 Jakub Jelinek <jakub@redhat.com>
4334
4335 PR middle-end/60092
4336 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
4337 and tree_to_uhwi.
4338 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
4339 functions.
4340 (c_common_attribute_table): Add alloc_align and assume_aligned
4341 attributes.
4342
76fdceeb 43432014-02-06 Marek Polacek <polacek@redhat.com>
4344
4345 PR c/60087
4346 * c-common.c (warn_for_sign_compare): Call warning_at with location
4347 instead of warning.
4348
4a4dea42 43492014-02-05 Marek Polacek <polacek@redhat.com>
4350
4351 PR c/53123
4352 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
4353 statement.
4354
ec704957 43552014-02-04 Marek Polacek <polacek@redhat.com>
4356
4357 PR c/60036
4358 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
4359 SAVE_EXPR.
4360
caf62483 43612014-02-03 Marc Glisse <marc.glisse@inria.fr>
4362
4363 PR c++/53017
4364 PR c++/59211
4365 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
4366 handle_vector_size_attribute, handle_nonnull_attribute): Call
4367 default_conversion on the attribute argument.
4368 (handle_nonnull_attribute): Increment the argument number.
4369
ec761d5a 43702014-01-31 Marek Polacek <polacek@redhat.com>
4371
4372 PR c/59963
4373 * c-common.c (add_atomic_size_parameter): Pass vNULL to
4374 build_function_call_vec.
4375 (resolve_overloaded_builtin): Likewise.
4376 * c-common.h (build_function_call_vec): Adjust declaration.
4377
22a75734 43782014-01-30 Marek Polacek <polacek@redhat.com>
4379
4380 PR c/59940
4381 * c-common.h (unsafe_conversion_p): Adjust declaration.
4382 (warnings_for_convert_and_check): Likewise.
4383 (convert_and_check): Likewise.
4384 * c-common.c (unsafe_conversion_p): Add location parameter. Call
4385 expansion_point_location_if_in_system_header on it.
4386 (warnings_for_convert_and_check): Add location parameter. Call
4387 expansion_point_location_if_in_system_header on it. Use it.
4388 (convert_and_check): Add location parameter. Use it.
4389 (conversion_warning): Likewise.
4390 (c_add_case_label): Adjust convert_and_check calls.
4391 (scalar_to_vector): Adjust unsafe_conversion_p calls.
4392
a89e6c15 43932014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
4394
4395 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
4396 flag_cilkplus.
4397 * c-pragma.c (init_pragma): Likewise.
4398 * c.opt: Likewise.
4399
2623625f 44002014-01-23 Marek Polacek <polacek@redhat.com>
4401
4402 PR c/59846
4403 * c-common.c (shorten_compare): Add location_t parameter.
4404 * c-common.h (shorten_binary_op): Adjust declaration.
4405
46da3601 44062014-01-23 Marek Polacek <polacek@redhat.com>
4407
4408 PR c/58346
4409 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
4410 * c-common.h: Declare it.
4411
c9743c6a 44122014-01-20 Eric Botcazou <ebotcazou@adacore.com>
4413
4414 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
4415 * c-ada-spec.c (dump_ads): Likewise.
4416 (cpp_check): Likewise.
4417 (dump_ada_specs): Likewise.
4418
44192014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
36e33c6a 4420
4421 PR c++/49718
4422 * c-common.c (handle_no_instrument_function_attribute): Allow
4423 no_instrument_function attribute in class member
4424 definition/declaration.
4425
1248c663 44262014-01-15 Jakub Jelinek <jakub@redhat.com>
4427
4428 PR c/58943
4429 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
4430 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
4431 being COMPOUND_EXPR.
4432 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
4433 operand a SAVE_EXPR and second MODIFY_EXPR.
4434
6e5c480b 44352014-01-09 Jakub Jelinek <jakub@redhat.com>
4436
4437 PR target/58115
4438 * c-pch.c (c_common_write_pch): Call
4439 prepare_target_option_nodes_for_pch.
4440
3aea1f79 44412014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
4442
4443 Update copyright years
4444
e4f22041 44452014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
4446
4447 * array-notation-common.c, c-cilkplus.c: Use the standard form for
4448 the copyright notice.
4449
7fb0fe24 44502013-12-28 Eric Botcazou <ebotcazou@adacore.com>
4451
4452 * c-ada-spec.c (print_constructor): New function.
4453 (print_destructor): Retrieve the origin of the destructor.
4454 (print_ada_declaration): Revamp handling of constructors/destructors.
4455
92a44a68 44562013-12-23 Stuart Hastings <stuart@apple.com>
468088ac 4457 Bill Maddox <maddox@google.com>
4458 Jason Merrill <jason@redhat.com>
4459
4460 * c.opt: Add -fdeclone-ctor-dtor.
4461 * c-opts.c (c_common_post_options): Default to on iff -Os.
4462
74acc703 44632013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
4464
4465 * c-common.c (c_common_attribute_table): Added "cilk simd function"
4466 attribute.
4467 * c-pragma.h (enum pragma_cilk_clause): Remove.
4468 (enum pragma_omp_clause): Added the following fields:
4469 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
4470 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
4471 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
4472 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
4473 PRAGMA_CILK_CLAUSE_UNIFORM.
4474
8204c077 4475
433e804e 44762013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
4477
4478 * cilk.c (cilk_outline): Made this function non-static.
4479 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
4480 (create_cilk_wrapper): Added a new parameter: a function pointer.
4481 (c_install_body_w_frame_cleanup): Remove
4482 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
4483 * c-common.h (cilk_outline): New prototype.
4484 (gimplify_cilk_spawn): Removed two parameters.
4485 (cilk_install_body_with_frame_cleanup): New prototype.
4486 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
4487 CILK_SPAWN_STMT case.
4488
5bcc7e60 44892013-12-11 Bernd Schmidt <bernds@codesourcery.com>
4490
e66325ea 4491 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
4492
5bcc7e60 4493 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
4494 (int_array_type_node): Remove.
4495 * c-common.c (c_common_nodes_and_builtins): Don't build it.
4496
0b26ec77 44972013-12-05 Marek Polacek <polacek@redhat.com>
4498
4499 PR c/52023
4500 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
4501 [ADJUST_FIELD_ALIGN].
4502
a179a7dc 45032013-12-04 Joseph Myers <joseph@codesourcery.com>
4504
4505 PR c/52023
4506 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
4507 and check field alignment if set.
4508 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
4509 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
4510
8204c077 45112013-12-04 Jakub Jelinek <jakub@redhat.com>
137559b2 4512 Marek Polacek <polacek@redhat.com>
4513
4514 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
4515 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
4516
648fd348 45172013-11-29 H.J. Lu <hongjiu.lu@intel.com>
4518
4519 PR c/59309
4520 * cilk.c (gimplify_cilk_spawn): Properly handle function without
4521 arguments.
4522
253e1cae 45232013-11-29 Jakub Jelinek <jakub@redhat.com>
4524
4525 PR c/59280
4526 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
4527 goto invalid. If it is error_mark_node, don't issue further
4528 diagnostics.
4529
3e398f5b 45302013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
4531
4532 * c.opt (Wopenmp-simd): New.
4533
020bc656 45342013-11-22 Jakub Jelinek <jakub@redhat.com>
4535
4536 * c-ubsan.h (ubsan_instrument_return): New prototype.
4537 * c-ubsan.c (ubsan_instrument_return): New function.
4538
bc61cadb 45392013-11-22 Andrew MacLeod <amacleod@redhat.com>
4540
4541 * c-common.c: Add required include files from gimple.h.
4542 * c-gimplify.c: Likewise
4543 * cilk.c: Likewise
4544
3df42822 45452013-11-22 David Malcolm <dmalcolm@redhat.com>
4546
4547 * c-common.c (unsafe_conversion_p): Remove use of
4548 EXPR_LOC_OR_HERE macro.
4549 (conversion_warning): Likewise.
4550 (warnings_for_convert_and_check): Likewise.
4551 (warn_for_collisions_1): Likewise.
4552 (shorten_compare): Likewise, and remove use of in_system_header
4553 macro, using the location from the former.
4554 * c-lex.c (dump_one_header): Remove use of input_filename macro.
4555 (cb_def_pragma): Remove use of in_system_header macro.
4556 (lex_string): Likewise.
4557 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
4558
8c53c46c 45592013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
4560 Mike Stump <mikestump@comcast.net>
4561 Richard Sandiford <rdsandiford@googlemail.com>
4562
4563 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
4564 instead of TREE_INT_CST_LOW, in cases where there is a protecting
4565 tree_fits_shwi_p or tree_fits_uhwi_p.
4566 (dump_generic_ada_node): Likewise.
4567 * c-format.c (check_format_arg): Likewise.
4568 * c-pretty-print.c (pp_c_integer_constant): Likewise.
4569
5200ef07 45702013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
4571
4572 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
4573
ca9d7d74 45742013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
4575
4576 PR c/53001
4577 * c-common.c (unsafe_conversion_p): Make this function
4578 return an enumeration with more detail.
4579 (conversion_warning): Use the new return type of
4580 unsafe_conversion_p to separately warn either about conversions
4581 that lower floating point number precision or about the other
4582 kinds of conversions.
4583 * c-common.h (enum conversion_safety): New enumeration.
a49621cf 4584 (unsafe_conversion_p): switching return type to
4585 conversion_safety enumeration.
ca9d7d74 4586 * c.opt: Adding new warning -Wfloat-conversion and
4587 enabling it with -Wconversion.
4588
0391a567 45892013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
4590
a49621cf 4591 * c-opts.c: Include plugin.h.
4592 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
0391a567 4593
19b928d9 45942013-11-19 Marek Polacek <polacek@redhat.com>
4595
4596 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
4597 call.
4598 (ubsan_instrument_shift): Likewise.
4599 (ubsan_instrument_vla): Likewise.
4600
aa59f000 46012013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4602
4603 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
4604 cast to unsigned type.
4605
08f817b3 46062013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4607
4608 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
4609 tree_low_cst.
4610 (complete_array_type): Update comment to refer to tree_to_[su]hwi
4611 rather than tree_low_cst.
4612
6a0712d4 46132013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4614
4615 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
4616 tree_to_uhwi throughout.
4617
fcb97e84 46182013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4619
4620 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
4621 tree_low_cst (..., 0) with tree_to_shwi throughout.
4622
cd4547bf 46232013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4624
4625 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
4626 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
4627
35ec552a 46282013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4629
4630 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
4631 host_integerp (..., 0) with tree_fits_shwi_p throughout.
4632
f2697631 46332013-11-15 Aldy Hernandez <aldyh@redhat.com>
4634
4635 * c-cilkplus.c: New file.
4636 * c-common.c (readonly_error): Add location argument.
4637 * c-common.h (readonly_error): Same.
4638 (c_finish_cilk_clauses): Protoize.
4639 (c_check_cilk_loop): Same.
4640 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
4641 Do not fail on error_mark_node.
4642 Abstract increment canonicalization to here...
4643 (c_omp_for_incr_canonicalize_ptr): New.
4644 c-pragma.c (init_pragma): Register "simd" pragma.
4645 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
4646 (enum pragma_cilk_clause): New.
4647
0aa8c34e 46482013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
4649
4650 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
4651 wchar_type and host_integerp checks.
4652
e795d6e1 46532013-11-14 Andrew MacLeod <amacleod@redhat.com>
4654
4655 * c-common.c: Likewise.
4656 * c-gimplify.c: Likewise.
4657 * cilk.c: Likewise.
4658
9ed99284 46592013-11-14 Diego Novillo <dnovillo@google.com>
4660
4661 * c-common.c: Include fold-const.h.
4662 Include stor-layout.h.
4663 Include calls.h.
4664 Include stringpool.h.
4665 Include attribs.h.
4666 Include varasm.h.
4667 Include trans-mem.h.
4668 * c-cppbuiltin.c: Include stor-layout.h.
4669 Include stringpool.h.
4670 * c-format.c: Include stringpool.h.
4671 * c-lex.c: Include stringpool.h.
4672 Include stor-layout.h.
4673 * c-pragma.c: Include stringpool.h.
4674 Include attribs.h.
4675 Include varasm.h.
4676 Include gcc-symtab.h.
4677 * c-pretty-print.c: Include stor-layout.h.
4678 Include attribs.h.
4679 * cilk.c: Include stringpool.h.
4680 Include calls.h.
4681
4fba5eb9 46822013-11-13 Joseph Myers <joseph@codesourcery.com>
4683
4684 * c-common.h (enum rid): Add RID_AUTO_TYPE.
4685 * c-common.c (c_common_reswords): Add __auto_type.
4686 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
4687
a8783bee 46882013-11-12 Andrew MacLeod <amacleod@redhat.com>
4689
e795d6e1 4690 * c-common.c: Include gimplify.h.
4691 * c-gimplify.c: Likewise.
4692 * cilk.c: Likewise.
4693 * c-omp.c: Include gimple-expr.h instead of gimple.h.
4694 * c-ubsan.c: Don't include gimple.h.
a8783bee 4695
d184e0c0 46962013-11-12 Joseph Myers <joseph@codesourcery.com>
4697
4698 * c-common.c (c_common_reswords): Add _Thread_local.
4699
a056826c 47002013-11-09 Joseph Myers <joseph@codesourcery.com>
4701
4702 * c-common.c (atomic_size_supported_p): New function.
4703 (resolve_overloaded_atomic_exchange)
4704 (resolve_overloaded_atomic_compare_exchange)
4705 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
4706 Use it instead of comparing size with a local list of sizes.
4707
b560fabd 47082013-11-07 Andrew MacLeod <amacleod@redhat.com>
4709 Joseph Myers <joseph@codesourcery.com>
4710
4711 * c-common.h (enum rid): Add RID_ATOMIC.
4712 * c-common.c (c_common_reswords): Add _Atomic.
4713 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
4714 (keyword_is_type_qualifier): Accept RID_ATOMIC.
4715 * c-format.c (check_format_types): Check for extra _Atomic
4716 qualifiers in format argument.
4717 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
4718 (pp_c_type_qualifier_list): Mention _Atomic in comment.
4719
5b1a0622 47202013-11-06 Tobias Burnus <burnus@net-b.de>
4721
4722 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
4723
4f8f4cb8 47242013-11-06 Joseph Myers <joseph@codesourcery.com>
4725
4726 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
4727 standards modes.
4728 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
4729 to mean lack of IEEE 754 support.
4730
9148bda3 47312013-11-05 Tobias Burnus <burnus@net-b.de>
4732
4733 * c.opt (-Wdate-time): New option
4734 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
4735
08c5f4d5 47362013-11-05 Joseph Myers <joseph@codesourcery.com>
4737
4738 * c-cppbuiltin.c (cpp_iec_559_value): Test
4739 flag_excess_precision_cmdline not flag_excess_precision.
4740
c630ef93 47412013-11-05 Tobias Burnus <burnus@net-b.de>
4742
4743 * c.opt (fopenmp-simd): New option.
4744 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
4745 (omp_pragmas): ... this new struct.
4746 (c_pp_lookup_pragma): Also walk omp_pragmas.
4747 (init_pragma): Init pragmas for -fopenmp-simd.
4748
7354a89b 47492013-11-04 Marek Polacek <polacek@redhat.com>
4750
4751 PR c++/58979
4752 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
4753
4c866b9b 47542013-11-04 Joseph Myers <joseph@codesourcery.com>
4755
4756 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
4757 New functions.
4758 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
4759
e2a6a333 47602013-11-04 Eric Botcazou <ebotcazou@adacore.com>
4761
4762 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
4763 (dump_ada_specs): Adjust prototype of second callback.
4764 * c-ada-spec.c (cpp_check): New global variable.
4765 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
4766 (print_generic_ada_decl): Likewise.
4767 (has_static_fields): Change return type to bool and add guard.
4768 (has_nontrivial_methods): New predicate.
4769 (is_tagged_type): Change return type to bool.
4770 (separate_class_package): Call has_nontrivial_methods.
4771 (pp_ada_tree_identifier): Minor tweaks.
4772 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
4773 (dump_ada_array_domains): Likewise.
4774 (dump_ada_array_type): Likewise.
4775 (dump_template_types): Remove cpp_check parameter and do not pass it to
4776 dump_generic_ada_node.
4777 (dump_ada_template): Likewise.
4778 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
4779 recursively.
4780 (print_ada_methods): Change return type to integer. Remove cpp_check
4781 parameter and do not pass it down.
4782 (dump_nested_types): Remove cpp_check parameter and do not pass it to
4783 dump_generic_ada_node.
4784 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
4785 accessing methods.
4786 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
4787 down. Use has_nontrivial_methods to recognize C++ classes. Use return
4788 value of print_ada_methods.
4789 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
4790 Set cpp_check to it before invoking dump_ada_nodes.
4791 (dump_ada_specs): Likewise.
4792
2c4c3477 47932013-11-03 Marek Polacek <polacek@redhat.com>
4794
4795 * c-ubsan.c: Don't include hash-table.h.
4796 (ubsan_instrument_vla): New function.
4797 * c-ubsan.h: Declare it.
4798
452659af 47992013-10-31 David Malcolm <dmalcolm@redhat.com>
4800
4801 Automated part of renaming of symtab_node_base to symtab_node.
4802
4803 Patch autogenerated by rename_symtab.py from
4804 https://github.com/davidmalcolm/gcc-refactoring-scripts
4805 revision 58bb219cc090b2f4516a9297d868c245495ee622
4806
4807 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
4808 symtab_node_base to symtab_node.
4809
4d6f7dd4 48102013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
4811
a49621cf 4812 Implement C++14 digit separators.
4d6f7dd4 4813 * c-lex.c (interpret_float): Remove digit separators from scratch string
4814 before building real literal.
4815
06cfe805 48162013-10-30 Jakub Jelinek <jakub@redhat.com>
4817
4818 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
4819
d037099f 48202013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
4821
4822 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
4823 fields.
4824 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
4825 enabled.
4826 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
4827 (insert_cilk_frame): New prototype.
4828 (cilk_init_builtins): Likewise.
4829 (gimplify_cilk_spawn): Likewise.
4830 (c_cilk_install_body_w_frame_cleanup): Likewise.
4831 (cilk_detect_spawn_and_unwrap): Likewise.
4832 (cilk_set_spawn_marker): Likewise.
4833 (build_cilk_sync): Likewise.
4834 (build_cilk_spawn): Likewise.
4835 * cilk.c: New file.
4836
02774f2d 48372013-10-29 David Malcolm <dmalcolm@redhat.com>
4838
4839 Patch autogenerated by refactor_symtab.py from
4840 https://github.com/davidmalcolm/gcc-refactoring-scripts
4841 revision 58bb219cc090b2f4516a9297d868c245495ee622
4842
4843 * c-gimplify.c (c_genericize): Update for conversion of symtab types
4844 to a true class hierarchy.
4845 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
4846
31fe10fd 48472013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
4848
4849 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
4850
b1c06ff9 48512013-10-26 Jeff Law <law@redhat.com>
4852
1f78217c 4853 * c-common.c (c_define_builtins): Remove mudflap support.
4854 * c.opt: Ignore and warn for mudflap options.
b1c06ff9 4855
48a972c8 48562013-10-24 Tobias Burnus <burnus@net-b.de>
4644b593 4857
4858 PR other/33426
4859 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
4860 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
4861
546a04b1 48622013-10-23 Jason Merrill <jason@redhat.com>
4863
4864 * c-format.c (gcc_cxxdiag_char_table): Add %X.
4865
bc7bff74 48662013-10-11 Jakub Jelinek <jakub@redhat.com>
4867
d62c713e 4868 * c-common.h (omp_clause_mask::operator !=): New method.
4869 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
4870 instead of if (mask & something) tests everywhere.
4871
bc7bff74 4872 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
4873 201307 instead of 201107.
4874 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
4875 (c_common_attribute_table): Add "omp declare target" and
4876 "omp declare simd" attributes.
4877 (handle_omp_declare_target_attribute,
4878 handle_omp_declare_simd_attribute): New functions.
4879 * c-omp.c: Include c-pragma.h.
4880 (c_finish_omp_taskgroup): New function.
4881 (c_finish_omp_atomic): Add swapped argument, if true,
4882 build the operation first with rhs, lhs arguments and use NOP_EXPR
4883 build_modify_expr.
4884 (c_finish_omp_for): Add code argument, pass it down to make_code.
4885 (c_omp_split_clauses): New function.
4886 (c_split_parallel_clauses): Removed.
4887 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
4888 c_omp_declare_simd_clauses_to_decls): New functions.
4889 * c-common.h (omp_clause_mask): New type.
4890 (OMP_CLAUSE_MASK_1): Define.
4891 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
4892 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
4893 omp_clause_mask::operator |, omp_clause_mask::operator &,
4894 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
4895 omp_clause_mask::operator ==): New methods.
4896 (enum c_omp_clause_split): New.
4897 (c_finish_omp_taskgroup): New prototype.
4898 (c_finish_omp_atomic): Add swapped argument.
4899 (c_finish_omp_for): Add code argument.
4900 (c_omp_split_clauses): New prototype.
4901 (c_split_parallel_clauses): Removed.
4902 (c_omp_declare_simd_clauses_to_numbers,
4903 c_omp_declare_simd_clauses_to_decls): New prototypes.
4904 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
4905 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
4906 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
4907 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
4908 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
4909 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
4910 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
4911 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
4912 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
4913 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
4914 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
4915 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
4916 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
4917 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
4918 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
4919 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
4920 PRAGMA_OMP_CLAUSE_UNIFORM.
4921
d7dcba40 49222013-10-09 Marc Glisse <marc.glisse@inria.fr>
4923
4924 PR tree-optimization/20318
4925 * c-common.c (handle_returns_nonnull_attribute): New function.
4926 (c_common_attribute_table): Add returns_nonnull.
4927
0b7282f1 49282013-10-03 Marc Glisse <marc.glisse@inria.fr>
4929
4930 PR c++/19476
4931 * c.opt (fcheck-new): Move to common.opt.
4932
51f553af 49332013-09-25 Marek Polacek <polacek@redhat.com>
4934 Jakub Jelinek <jakub@redhat.com>
4935
4936 PR sanitizer/58413
4937 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
4938 an expression if we can prove it is correct.
4939 (ubsan_instrument_division): Likewise. Remove unnecessary
4940 check.
4941
05f893e1 49422013-09-18 Marek Polacek <polacek@redhat.com>
4943
4944 PR sanitizer/58411
4945 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
4946 Declare it.
4947 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
4948
236ce1d1 49492013-09-14 Iain Sandoe <iain@codesourcery.com>
4950
4951 PR target/48094
4952 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
4953 fobjc-gc, freplace-objc-classes): Accept for LTO.
4954
f9f68d35 49552013-09-13 Jacek Caban <jacek@codeweavers.com>
4956
4957 * c-target.def: New hook
4958
ba2f764e 49592013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
4960
4961 PR c++/43452
4962 * c.opt (Wdelete-incomplete): Add.
4963
73437615 49642013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
4965
4966 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
4967 (vector_types_compatible_elements_p): New function.
4968 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
4969 declaration.
4970 (vector_types_compatible_elements_p): Declare.
4971
95af4c75 49722013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
4973
4974 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
4975 a virtual member function.
4976 (pp_simple_type_specifier): Remove.
4977 (pp_c_type_specifier): Likewise.
4978 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
4979 Rename from pp_c_type_specifier. Adjust.
4980 (c_pretty_printer::c_pretty_printer): Do not assign to
4981 simple_type_specifier.
4982
eaab24b9 49832013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
4984
4985 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
4986 member function.
4987 (c_pretty_printer::storage_class_specifier): Likewise.
4988 (c_pretty_printer::initializer): Likewise.
4989 (pp_declaration): Remove.
4990 (pp_declaration_specifiers): Likewise.
4991 (pp_abstract_declarator): Likewise.
4992 (pp_declarator): Likewise.
4993 (pp_type_id): Likewise.
4994 (pp_statement): Likewise.
4995 (pp_constant): Likewise.
4996 (pp_id_expression): Likewise.
4997 (pp_primary_expression): Likewise.
4998 (pp_unary_expression): Likewise.
4999 (pp_multiplicative_expression): Likewise.
5000 (pp_conditional_expression): Likewise.
5001 (pp_assignment_expression): Likewise.
5002 (pp_expression): Likewise.
5003 (pp_c_type_id): Likewise.
5004 (pp_c_storage_class_specifier): Likewise.
5005 * c-pretty-print.c (pp_c_type_cast): Tidy.
5006 (pp_c_pointer): Likewise.
5007 (pp_c_type_specifier): Likewise.
5008 (pp_c_parameter_type_list): Likewise.
5009 (pp_c_function_definition): Likewise.
5010 (pp_c_init_declarator): Likewise.
5011 (pp_c_initializer_list): Likewise.
5012 (pp_c_constructor_elts): Likewise.
5013 (c_pretty_printer::direct_abstract_declarator): Likewise.
5014 (c_pretty_printer::declaration_specifiers): Likewise.
5015 (c_pretty_printer::primary_expression): Likewise.
5016 (c_pretty_printer::postfix_expression): Likewise.
5017 (c_pretty_printer::type_id): Rename from pp_c_type_id.
5018 (c_pretty_printer::storage_class_specifier): Rename from
5019 pp_c_storage_class_specifier.
5020 (c_pretty_printer::initializer): Rename from pp_c_initializer.
5021 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
5022 storage_class_specifier, initializer, offset_list, flags.
5023
9e46467d 50242013-08-30 Marek Polacek <polacek@redhat.com>
5025
5026 * c-ubsan.c: New file.
5027 * c-ubsan.h: New file.
5028
36a8d9b9 50292013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
5030
5031 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
5032 member function.
5033 (c_pretty_printer::declaration_specifiers): Likewise.
5034 (c_pretty_printer::declarator): Likewise.
5035 (c_pretty_printer::abstract_declarator): Likewise.
5036 (c_pretty_printer::direct_abstract_declarator): Likewise.
5037 (c_pretty_printer::direct_declarator): Likewise.
5038 (c_pretty_printer::function_specifier): Likewise.
5039 (pp_declaration): Adjust.
5040 (pp_declaration_specifiers): Likewise.
5041 (pp_abstract_declarator): Likewise.
5042 (pp_direct_declarator): Likewise.
5043 (pp_function_specifier): Likewise.
5044 (pp_direct_abstract_declarator): Remove as unused.
5045 (pp_c_declaration): Remove.
5046 (pp_c_declaration_specifiers): Likewise.
5047 (pp_c_declarator): Likewise.
5048 (pp_c_direct_declarator): Likewise.
5049 (pp_c_function_specifier): Likewise.
5050 (pp_c_direct_abstract_declarator): Likewise.
5051 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
5052 from pp_c_abstract_declarator. Adjust.
5053 (c_pretty_printer::direct_abstract_declarator): Rename from
5054 pp_c_direct_abstract_declarator. Adjust.
5055 (c_pretty_printer::function_specifier): Rename from
5056 pp_c_function_specifier. Adjust.
5057 (c_pretty_printer::declaration_specifiers): Rename from
5058 pp_c_declaration_specifiers. Adjust.
5059 (c_pretty_printer::direct_declarator): Rename from
5060 pp_c_direct_declarator. Adjust.
5061 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
5062 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
5063 (c_pretty_printer::c_pretty_printer): Do not assign to
5064 declaration, declaration_specifiers, declarator,
5065 direct_declarator, direct_abstract_declarator, function_specifier.
5066
30635c2e 50672013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
5068
5069 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
5070 virtual member function.
5071 (c_pretty_printer::multiplicative_expression): Likewise.
5072 (c_pretty_printer::conditional_expression): Likewise.
5073 (c_pretty_printer::assignment_expression): Likewise.
5074 (c_pretty_printer::expression): Likewise.
5075 (pp_unary_expression): Adjust.
5076 (pp_multiplicative_expression): Likewise.
5077 (pp_assignment_expression): Likewise.
5078 (pp_conditional_expression): Likewise.
5079 (pp_expression): Likewise.
5080 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
5081 from pp_c_unary_expression. Adjust.
5082 (c_pretty_printer::multiplicative_expression): Rename from
5083 pp_c_multiplicative_expression. Adjust.
5084 (c_pretty_printer::conditional_expression): Rename from
5085 pp_c_conditional_expression. Adjust.
5086 (c_pretty_printer::assignment_expression): Rename from
5087 pp_c_assignment_expression. Adjust.
5088 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
5089 (c_pretty_printer::c_pretty_printer): Do not assign to
5090 unary_expression, multiplicative_expression,
5091 conditional_expression, expression.
5092
027d08ed 50932013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
5094
5095 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
5096 virtual member function.
5097 (pp_postfix_expression): Adjust.
5098 (pp_c_postfix_expression): Remove.
5099 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
5100 from pp_c_postfix_expression. Adjust.
5101 (c_pretty_printer::c_pretty_printer): Do not assign to
5102 postfix_expression.
5103
f873303a 51042013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
5105
5106 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
5107 virtua member function.
5108 (pp_primary_expression): Adjust.
5109 (pp_c_primary_expression): Remove.
5110 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
5111 from pp_c_primary_expression. Adjust.
5112 (pp_c_initializer_list): Use pp_primary_expression.
5113 (c_pretty_printer::c_pretty_printer): Do not assign to
5114 primary_expression.
5115
08e3e481 51162013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
5117
5118 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
5119 * c-pretty-print.c (M_): Remove.
5120 (c_pretty_printer::translate_string): Define.
5121 (pp_c_type_specifier): Use it.
5122 (pp_c_primary_expression): Likewise.
5123 (pp_c_expression): Likewise.
5124
1fc4a87f 51252013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
5126
5127 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
5128 virtual function.
5129 (pp_c_id_expression): Remove.
5130 (pp_id_expression): Adjust.
5131 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
5132 pp_c_id_expression. Adjust.
5133 (pp_c_postfix_expression): Use pp_id_expression.
5134 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
5135
a6cb161b 51362013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
5137
5138 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
5139 member function.
5140 (pp_constant): Adjust.
5141 (pp_c_constant): Remove.
5142 * c-pretty-print.c (c_pretty_printer::constant): Rename from
5143 pp_c_constant. Adjust.
5144 (pp_c_constant)
5145 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
5146 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
5147
eed6bc21 51482013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
5149
5150 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
5151 (c_pretty_printer::c_pretty_printer): Declare.
5152 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
5153 c_pretty_printer_init. Adjust.
5154 (print_c_tree): Do not call c_pretty_printer_init.
5155 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
5156
df558d2e 51572013-08-09 Arnaud Charlet <charlet@adacore.com>
5158
5159 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
5160
42f9a786 51612013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
5162
5163 PR c++/58080
5164 * c-common.c (pointer_int_sum): Add bool parameter.
5165 * c-common.h (pointer_int_sum): Adjust declaration.
5166
f874ddad 51672013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
5168
5169 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
5170 c_pretty_printer variable.
5171
a94db6b0 51722013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
5173
5174 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
5175 (pp_base): Remove.
5176 (pp_c_base): Likewise. Adjust users.
5177 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
5178 (pp_c_whitespace): Do not call pp_base.
5179 (pp_c_left_paren): Likewise.
5180 (pp_c_right_paren): Likewise.
5181 (pp_c_left_brace): Likewise.
5182 (pp_c_right_brace): Likewise.
5183 (pp_c_left_bracket): Likewise.
5184 (pp_c_right_bracket): Likewise.
5185 (pp_c_dot): Likewise.
5186 (pp_c_ampersand): Likewise.
5187 (pp_c_star): Likewise.
5188 (pp_c_arrow): Likewise.
5189 (pp_c_semicolon): Likewise.
5190 (pp_c_complement): Likewise.
5191 (pp_c_exclamation): Likewise.
5192 (pp_c_direct_declarator): Likewise.
5193 (pp_c_ws_string): Likewise.
5194 (pp_c_identifier): Likewise.
5195 (pp_c_statement): Likewise.
5196 (print_c_tree): Likewise.
5197
1898176c 51982013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
5199
5200 PR c++/58072
5201 * c-common.c (c_parse_error): Catch user-defined literal tokens and
5202 provide useful error strings.
5203
70d60d1d 52042013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
5205
5206 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
5207 printer functions instead of pp_string or operators and punctuators.
5208 (dump_generic_ada_node): Likewise.
5209 * c-pretty-print.c (pp_c_type_specifier): Likewise.
5210 (pp_c_relational_expression): Likewise.
5211 (pp_c_logical_or_expression): Likewise.
5212
dda4f0ec 52132013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
5214
5215 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
5216 functions instead of pp_character.
5217 (pp_ada_tree_identifier): Likewise.
5218 (dump_ada_double_name): Likewise.
5219 (dump_ada_function_declaration): Likewise.
5220 (dump_ada_array_domains): Likewise.
5221 (dump_template_types): Likewise.
5222 (dump_generic_ada_node): Likewise.
5223 (print_ada_declaration): Likewise.
5224 (print_ada_struct_decl): Likewise.
5225 * c-pretty-print.c (pp_c_integer_constant): Likewise.
5226
7aa04c8d 52272013-07-23 Tom Tromey <tromey@redhat.com>
5228
5229 * c-common.h (enum rid) <RID_GENERIC>: New constant.
5230 * c-common.c (c_common_reswords): Add _Generic.
5231
a04e8d62 52322013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
5233
5234 * c-common.c: Fix typos.
5235 * c-common.h: Likewise.
5236
a96c3cc1 52372013-07-13 Lubos Lunak <l.lunak@suse.cz>
5238
5239 PR c++/55203
5240 * c-common.c (c_common_attribute_table): Add warn_unused.
5241 (handle_warn_unused_attribute): New.
5242
da31536d 52432013-07-10 Jakub Jelinek <jakub@redhat.com>
5244
5245 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
5246 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
5247
839f2f70 52482013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
5249
5250 PR c++/57869
5251 * c.opt: Add Wconditionally-supported.
5252
73f353d0 52532013-07-08 Graham Stott <graham.stott@btinternet.com>
5254
1f78217c 5255 * array-notation-common.c (length_mismatch_in_expr_p): Delete
73f353d0 5256 unused variables l_length and l_node.
5257
21ebaa24 52582013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
f5298614 5259
5260 PR c/57821
5261 * c-common.c (complete_array_type): Delay folding first index
5262 like other indices. When folding, check for index overflow.
5263
68ea4406 52642013-06-27 Marc Glisse <marc.glisse@inria.fr>
5265
5266 PR c++/57509
5267 * c-common.h (c_build_vec_perm_expr): New complain argument.
5268 * c-common.c (c_build_vec_perm_expr): Likewise.
5269 Use save_expr also in C++.
5270
60777f69 52712013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
5272
5273 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
5274 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
5275 * c-opts.c (c_common_post_options): Likewise.
5276
839f2f70 52772013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
50acebe0 5278
5279 * array-notation-common.c (length_mismatch_in_expr): Changed the
5280 parameter type's from a dynamic array to a vec_tree. Also removed
5281 the size parameters.
5282 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
5283 the change above.
5284
e9331eab 52852013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
5286
5287 * c-common.h (struct cilkplus_an_parts): New structure.
5288 (struct cilkplus_an_loop_parts): Likewise.
5289 (cilkplus_extract_an_triplets): New prototype.
5290 (fix_sec_implicit_args): Likewise.
5291 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
5292 (fix_sec_implicit_args): Likewise.
60777f69 5293
a9c99fc4 52942013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
5295
5296 * array-notation-common.c (find_inv_trees): Removed an unwanted
5297 typecasting.
5298 * c-common.h (struct inv_list::additional_tcodes): Changed type from
5299 enum rid to enum tree_code.
5300
f2526cce 53012013-06-11 Jan Hubicka <jh@suse.cz>
5302
5303 * c-common.c (handle_alias_ifunc_attribute): Do not set
5304 DECL_EXTERNAL for weakref variables.
5305 * c-pragma.c (handle_pragma_weak): Make sure aliases
5306 are not declared as external.
5307
09970d67 53082013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
5309
5310 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
5311 function from c/c-array-notation.c.
5312 (is_cilkplus_reduce_builtin): Likewise.
5313 (find_rank): Likewise.
5314 (extract_array_notation_exprs): Likewise.
5315 (replace_array_notations): Likewise.
5316 (find_inv_trees): Likewise.
5317 (replace_inv_trees): Likewise.
5318 (contains_array_notation_expr): Likewise.
5319 (find_correct_array_notation_type): Likewise.
5320 * c-common.h (struct inv_list): Moved this struct from the file
5321 c/c-array-notation.c and added a new field called additional tcodes.
5322 (length_mismatch_in_expr_p): New prototype.
5323 (is_cilkplus_reduce_builtin): Likewise.
5324 (find_rank): Likewise.
5325 (extract_array_notation_exprs): Likewise.
5326 (replace_array_notation): Likewise.
5327 (find_inv_trees): Likewise.
5328 (replace_inv_trees): Likewise.
5329 (find_correct_array_notation_type): Likewise.
839f2f70 5330
3c6d4197 53312013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
5332
5333 * c-common.c (c_define_builtins): When cilkplus is enabled, the
5334 function array_notation_init_builtins is called.
5335 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
5336 * c-common.def (ARRAY_NOTATION_REF): New tree.
5337 * c-common.h (build_array_notation_expr): New function declaration.
5338 (build_array_notation_ref): Likewise.
5339 (extract_sec_implicit_index_arg): New extern declaration.
5340 (is_sec_implicit_index_fn): Likewise.
5341 (ARRAY_NOTATION_CHECK): New define.
5342 (ARRAY_NOTATION_ARRAY): Likewise.
5343 (ARRAY_NOTATION_START): Likewise.
5344 (ARRAY_NOTATION_LENGTH): Likewise.
5345 (ARRAY_NOTATION_STRIDE): Likewise.
5346 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
5347 ARRAY_NOTATION_REF.
5348 (pp_c_expression): Likewise.
5349 * c.opt (flag_enable_cilkplus): New flag.
5350 * array-notation-common.c: New file.
5351
8e71dad2 53522013-05-14 Jakub Jelinek <jakub@redhat.com>
5353
5354 PR c++/57274
5355 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
5356
432dd330 53572013-05-10 Marc Glisse <marc.glisse@inria.fr>
5358
5359 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
5360 vectors.
5361
b156ec37 53622013-05-07 Han Shen <shenhan@google.com>
5363
5364 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
5365
1a087624 53662013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
5367
5368 * c-common.c (check_user_alignment): Emit error for negative values.
5369
1638c736 53702013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
5371
5372 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
5373
949dbf93 53742013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
5375
5376 * c-cppbuiltin.c (c_cpp_builtins): Do not define
5377 __GXX_EXPERIMENTAL_CXX1Y__.
5378
9205a6cc 53792013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
a49621cf 5380 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
9205a6cc 5381
5382 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
5383 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
5384 to simply use OPT_Wpointer_arith.
5385 (c_sizeof_or_alignof_type): Likewise.
5386
05d0bce1 53872013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
5388
5389 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
5390
41609f8b 53912013-04-12 Jakub Jelinek <jakub@redhat.com>
5392
5393 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
5394 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
5395 specifiers.
5396
c671dc4f 53972013-04-07 Steven Bosscher <steven@gcc.gnu.org>
5398
5399 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
5400
ba125576 54012013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
5402
5403 * c-common.c (pointer_int_sum): Remove dead code.
5404
9d3fa937 54052013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
5406
5407 PR middle-end/56524
5408 * c-common.c (handle_optimize_attribute): Don't call
5409 save_optabs_if_changed.
5410
5ceebb21 54112013-03-05 Jakub Jelinek <jakub@redhat.com>
5412
5413 PR middle-end/56461
5414 * c-pch.c (pch_init): Free target_validity at the end.
5415
18eeed2b 54162013-03-04 Jakub Jelinek <jakub@redhat.com>
5417
5418 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
5419
a9196da9 54202013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
5421 Jakub Jelinek <jakub@redhat.com>
5422
5423 PR sanitizer/56454
5424 * c-common.c (handle_no_sanitize_address_attribute): New function.
5425 (c_common_attribute_table): Add no_sanitize_address attribute.
5426 (handle_no_address_safety_analysis_attribute): Add
5427 no_sanitize_address attribute, not no_address_safety_analysis
5428 attribute.
5429
15c27dda 54302013-02-18 Aldy Hernandez <aldyh@redhat.com>
08c7d04b 5431
5432 PR target/52555
5433 * c-common.c (handle_optimize_attribute): Call
5434 save_optabs_if_changed.
5435
19426fe1 54362013-02-18 Jakub Jelinek <jakub@redhat.com>
5437 Steven Bosscher <steven@gcc.gnu.org>
5438
5439 PR pch/54117
5440 * c-opts.c (c_common_post_options): If debug info is enabled
5441 and non-dwarf*, refuse to load PCH files and when writing PCH
5442 file warn.
5443
df936998 54442013-02-05 Jakub Jelinek <jakub@redhat.com>
5445
5446 PR middle-end/56167
5447 * c-common.c (handle_error_attribute): Fix condition.
5448
ae0c3984 54492013-01-30 Jakub Jelinek <jakub@redhat.com>
5450
5451 PR c++/55742
5452 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
5453
1c4973d7 54542013-01-18 Jason Merrill <jason@redhat.com>
5455
5456 PR target/54908
5457 * c.opt (-fextern-tls-init): New.
5458 * c-opts.c (c_common_post_options): Handle it.
5459
7c834436 54602013-01-09 Jakub Jelinek <jakub@redhat.com>
5461
5462 PR c/48418
5463 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
5464 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
5465 and is either negative or bigger or equal to type precision
5466 of the first operand.
5467
5abaa10a 54682012-12-03 Marek Polacek <polacek@redhat.com>
5469
5470 PR c/55570
5471 * c-common.c (check_user_alignment): Swap order of tests,
5472 check TREE_CODE first.
5473
324ca377 54742012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
5475
5476 PR c++/52654
5477 * c-common.h (overflow_type): New enum.
5478 (build_userdef_literal): Add overflow_type argument.
5479 (tree_userdef_literal): Add overflow_type.
5480 (USERDEF_LITERAL_OVERFLOW): New access macro.
5481 * c-common.c (build_userdef_literal): Add overflow_type
5482 argument.
5483 * c-lex.c (c_lex_with_flags): Add overflow_type to
5484 build_userdef_literal calls.
5485 (interpret_integer, interpret_float): Add overflow_type argument.
5486
b4c4a429 54872012-11-28 Richard Biener <rguenther@suse.de>
5488
5489 PR c/35634
5490 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
5491 here and use a type with proper overflow behavior for types that would
5492 need to be promoted for the arithmetic.
5493
d413ffdd 54942012-11-23 Jakub Jelinek <jakub@redhat.com>
5495
5496 PR sanitizer/55435
5497 * c-common.c (handle_no_address_safety_analysis_attribute): New
5498 function.
5499 (c_common_attribute_table): Add no_address_safety_analysis.
5500
52bc861d 55012012-11-16 Simon Baldwin <simonb@google.com>
5502
5503 * c.opt: Add f[no-]canonical-system-headers.
5504 * c-opts.c (c_common_handle_option): Handle
5505 OPT_fcanonical_system_headers.
5506
2dd00636 55072012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
5508
5509 PR c++/54413
5510 * c-opts.c (c_common_handle_option): Set new flags.
5511 * c.opt: Describe new flags.
5512
d4701f6c 55132012-11-09 Jason Merrill <jason@redhat.com>
5514
5515 * c.opt (Wabi-tag): New.
5516
72d65da9 55172012-11-09 Andi Kleen <ak@linux.intel.com>
5518
5519 PR 55139
5520 * c-common.c (get_atomic_generic_size): Mask with
a49621cf 5521 MEMMODEL_MASK
72d65da9 5522
77a357e3 55232012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
5524
5525 PR c/53063
5526 * c.opt (Wformat): Make it Alias Wformat=1.
5527 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
5528 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
5529 LangEnabledBy.
5530 (Wformat=): RejectNegative. Use LangEnabledBy.
5531 (Wnonnull): Use LangEnabledBy.
5532 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
5533 * c-format.c (set_Wformat): Delete.
5534 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
a49621cf 5535 (maybe_read_dollar_number): Likewise.
5536 (avoid_dollar_number): Likewise.
5537 (finish_dollar_format_checking): Likewise.
5538 (check_format_info): Likewise.
5539 (check_format_info_main): Likewise.
5540 (check_format_types): Likewise.
5541 (format_type_warning): Likewise.
5542 * c-common.c (int): Likewise.
5543 (check_function_sentinel): Likewise.
5544 * c-common.h (warn_format,set_Wformat): Do not declare here.
77a357e3 5545
45efa6b9 55462012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
5547
5548 PR c/53063
5549 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
5550 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
5551 Use LangEnabledBy.
5552 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
5553 common.opt.
5554 (Wvariadic-macros): Init(1).
5555 * c-opts.c (c_common_handle_option): Do not handle them
5556 explicitly.
5557 (c_common_post_options): Likewise.
5558 (sanitize_cpp_opts): warn_unused_macros is now
5559 cpp_warn_unused_macros.
5560 (push_command_line_include): Likewise.
5561 * c-common.c (warn_unknown_pragmas): Do not define.
5562 * c-common.h (warn_unknown_pragmas): Do not declare.
5563
0e4e775a 55642012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
5565
5566 PR c/51294
5567 * c-common.c (conversion_warning): Handle conditional expressions.
5568
8b447d3f 55692012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
5570
5571 PR c++/54930
5572 * c.opt (Wreturn_local_addr): Define new option.
5573
f4a61754 55742012-10-25 Jason Merrill <jason@redhat.com>
5575
ecb10e6a 5576 * c.opt (Wvirtual-move-assign): New.
5577
f4a61754 5578 * c.opt (Winherited-variadic-ctor): New.
5579
7b463b19 55802012-10-25 Marc Glisse <marc.glisse@inria.fr>
5581
5582 PR c++/54427
5583 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
5584
6adc88f8 55852012-10-23 Joseph Myers <joseph@codesourcery.com>
5586
5587 * c-common.h (pch_cpp_save_state): Declare.
5588 * c-target.def (c_preinclude): New hook.
5589 * c-opts.c (done_preinclude): New.
5590 (push_command_line_include): Handle default preincluded header.
5591 (cb_file_change): Call pch_cpp_save_state when calling
5592 push_command_line_include.
5593 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
5594 (pch_cpp_save_state): New.
5595 (pch_init): Call pch_cpp_save_state conditionally, instead of
5596 calling cpp_save_state.
5597
fa816b0b 55982012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
5599
5600 PR c/53063
5601 PR c/40989
5602 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
5603 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
5604 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
5605 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
5606 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
5607 * c-opts.c (c_common_handle_option): Remove explicit handling from
5608 here.
5609 (c_common_post_options): Likewise.
5610
d214ccee 56112012-10-18 Eric Botcazou <ebotcazou@adacore.com>
5612
5613 * c-ada-spec.c (LOCATION_COL): Delete.
5614 (compare_location): New function.
5615 (compare_node): Use it.
5616 (compare_comment): Likewise.
5617
77b27208 56182012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
5619
5620 PR c/53063
5621 PR c/40989
5622 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
5623 * c-opts.c (c_common_handle_option): Do not set them here. Add
5624 comment.
5625 (c_common_post_options): Likewise.
5626
cc02ca4d 56272012-10-16 Eric Botcazou <ebotcazou@adacore.com>
5628
5629 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
5630 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
5631 Remove POINTER_TYPE handling, add large unsigned handling and use
5632 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
5633
57f872a2 56342012-10-12 Jakub Jelinek <jakub@redhat.com>
5635
5636 PR c/54381
5637 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
5638 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
5639 locs and array of 3 trees instead of just single loc and single
5640 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
5641 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
5642 For *cmp* builtins that take two sources strings report warnings
5643 about first and second source, not about destination and source.
5644
7354ad2e 56452012-10-12 Marc Glisse <marc.glisse@inria.fr>
5646
5647 PR c++/53055
5648 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
5649
1ac7f120 56502012-10-11 Eric Botcazou <ebotcazou@adacore.com>
5651
5652 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
5653 declaring something coming from another file.
5654
1e0cc9e3 56552012-10-10 Arnaud Charlet <charlet@adacore.com>
5656
1ac7f120 5657 PR ada/54845
1e0cc9e3 5658 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
5659
b0e7825e 56602012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
5661
5662 PR c++/54194
5663 * c-common.c (warn_about_parentheses): Add location_t parameter;
5664 use EXPR_LOC_OR_LOC.
5665 * c-common.h: Update declaration.
5666
41ed701a 56672012-10-09 Marc Glisse <marc.glisse@inria.fr>
5668
5669 PR c++/54427
5670 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
5671 more operations. Make error messages optional.
5672 * c-common.h (enum stv_conv): Moved from c-typeck.c.
5673 (scalar_to_vector): Declare.
5674
3740094c 56752012-10-08 Jason Merrill <jason@redhat.com>
5676
5677 * c-common.c (c_common_reswords): Add thread_local.
5678
ffcdbf9c 56792012-10-08 Dodji Seketeli <dodji@redhat.com>
5680
5681 PR c++/53528 C++11 attribute support
5682 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
5683 new functions.
5684 * c-common.c (check_cxx_fundamental_alignment_constraints): New
5685 static function.
5686 (handle_aligned_attribute): In choose strictest alignment
5687 among many. Use new check_cxx_fundamental_alignment_constraints.
5688 (handle_transparent_union_attribute): In c++11 attribute syntax,
5689 don't look through typedefs.
5690
ef34afc1 56912012-10-04 Arnaud Charlet <charlet@adacore.com>
5692
5693 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
5694 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
5695 out of dumpfile.h.
5696
f1ff4562 56972012-09-25 Dehao Chen <dehao@google.com>
5698
5699 PR middle-end/54645
ef34afc1 5700 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
f1ff4562 5701 map when read in the pch.
5702
92a44a68 57032012-09-18 Arnaud Charlet <charlet@adacore.com>
735538a1 5704
5705 * c-ada-spec.c: Style fixes.
5706
92a44a68 57072012-09-18 Thomas Quinot <quinot@adacore.com>
9120cdc8 5708
5709 * c.opt (-fada-spec-parent): Define new command line switch.
5710 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
5711 is specified, generate binding spec as a child of the specified unit.
5712
8eba82c2 57132012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
5714 Manuel López-Ibáñez <manu@gcc.gnu.org>
5715
5716 PR c++/53210
5717 * c.opt ([Winit-self]): Enabled by -Wall in C++.
5718
38682990 57192012-08-23 Arnaud Charlet <charlet@adacore.com>
5720
5721 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
5722 for pointers, and add missing Convention C pragma.
5723 (print_ada_struct_decl): Add missing aliased keyword.
5724 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
5725
f003f5dc 57262012-08-17 Jakub Jelinek <jakub@redhat.com>
5727
5728 * c-common.c (sizeof_pointer_memaccess_warning): New function.
5729 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
5730 * c-opts.c (c_common_handle_option): Enable it for -Wall.
5731 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
5732 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
5733
ec11736b 57342012-08-10 Richard Guenther <rguenther@suse.de>
5735
5736 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
5737
5f7f600e 57382012-08-07 Steven Bosscher <steven@gcc.gnu.org>
5739
5740 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
5741 instead of separate pp_newline and pp_flush.
5742 (print_c_tree): Likewise.
5743
758a38ab 57442012-07-26 Richard Henderson <rth@redhat.com>
5745
5746 * c-common.c (handle_hot_attribute): Allow labels.
5747 (handle_cold_attribute): Likewise.
5748
9ca77b08 57492012-07-20 Jakub Jelinek <jakub@redhat.com>
5750
5751 PR c++/28656
5752 * c-common.c (check_function_nonnull): Handle multiple nonnull
5753 attributes properly.
5754
b9ed1410 57552012-07-16 Steven Bosscher <steven@gcc.gnu.org>
5756
5757 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
5758 * c-ada-spec.c: Likewise.
5759 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
5760
c2a65b90 57612012-07-14 Steven Bosscher <steven@gcc.gnu.org>
5762
5763 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
5764 Remove code conditional on it.
5765
88c5a1d1 57662012-07-11 Steven Bosscher <steven@gcc.gnu.org>
5767
5768 * c-gimplify.c: Do not include basic-block.h.
5769 * c-common.c: Do not include linfuncs.h.
5770
4a020a8c 57712012-07-08 Steven Bosscher <steven@gcc.gnu.org>
5772
5773 * c-common.h: Include tree.h.
5774
c28ddc97 57752012-07-02 Jason Merrill <jason@redhat.com>
5776
5777 PR c++/53524
5778 * c-common.c (get_priority): Call default_conversion.
5779
405ed67f 57802012-07-01 Uros Bizjak <ubizjak@gmail.com>
5781
5782 * c-pch.c (c_common_write_pch): Remove unused variables.
5783
e53d55e7 57842012-06-29 Steven Bosscher <steven@gcc.gnu.org>
5785
5786 * cppspec.c: Moved from gcc/ to here.
5787
3d9c25ec 57882012-06-27 Kai Tietz <ktietz@redhat.com>
5789
5790 PR preprocessor/37215
5791 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
5792
3169c57a 57932012-06-21 Steven Bosscher <steven@gcc.gnu.org>
5794
5795 * c-common.h (c_common_print_pch_checksum): Remove.
5796 * c-pch.c: Do not include output.h.
5797 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
5798 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
5799 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
5800 (struct c_pch_header): Remove.
5801 (get_ident): Update gpch version.
5802 (pch_init): Do not print executable_checksum to asm_out_file.
5803 Do not fail if there is no asm_out_file to read back from. Set
5804 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
5805 (c_common_write_pch): Verify that nothing was written to asm_out_file
5806 since pch_init was called. Do not write a c_pch_header, and do not
5807 copy from asm_out_file to the PCH.
5808 (c_common_read_pch): Do not read a c_pch_header, and do not restore
5809 the content of asm_out_file from the PCH.
5810 (c_common_print_pch_checksum): Remove.
5811 * c-opts.c (c_common_init): Print out executable_checksum directly.
5812
ff6624bc 58132012-06-19 Steven Bosscher <steven@gcc.gnu.org>
5814
5815 * c-target.def (objc_declare_unresolved_class_reference,
5816 objc_declare_class_definition): Add new hooks.
5817
367b1459 58182012-06-19 Steven Bosscher <steven@gcc.gnu.org>
5819
5820 * c-lex.c: Do not include output.h.
5821 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
5822 Remove uses of ASM_OUTPUT_IDENT.
5823
bf0cb017 58242012-06-15 Marc Glisse <marc.glisse@inria.fr>
5825
5826 PR c++/51033
5827 * c-common.h (c_build_vec_perm_expr): Move decl here.
5828 * c-common.c (c_build_vec_perm_expr): Move definition
5829 here.
5830
b37a3600 58312012-06-06 Steven Bosscher <steven@gcc.gnu.org>
5832
5833 * c.opt (fconserve-space): Turn into a no-op.
5834
19931eea 58352012-06-04 Sterling Augustine <saugustine@google.com>
5f9e7dd5 5836
5837 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
5838 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
5839 both the start and end of the function.
5840
dff12c10 58412012-06-04 Steven Bosscher <steven@gcc.gnu.org>
5842
5843 * c-common.c: Do not include output.h.
5844 * c-pragma.c: Likewise.
5845
5f9e7dd5 58462012-06-04 Steven Bosscher <steven@gcc.gnu.org>
5847
5848 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
5849 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
5850 (lang_decl_name): Handle namespace decls.
5851
b5369b7d 58522012-05-31 Steven Bosscher <steven@gcc.gnu.org>
5853
5854 * c-ada-spec.c: Do not include output.h.
5855 * c-semantics.c: Likewise.
5856
8032877c 58572012-05-29 Joseph Myers <joseph@codesourcery.com>
5858
5859 * c-common.c: Fix typo.
5860
7843e4bc 58612012-05-29 Michael Matz <matz@suse.de>
5862
5863 * c-common.h (c_expand_decl): Remove prototype.
5864
8cf857d4 58652012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
5866
5867 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
5868 * c-opts.c (c_common_handle_option): Remove code handling
5869 warn_missing_braces.
5870
8b64dc3c 58712012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
5872
5873 PR c++/25137
5874 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
5875 -Wmissing_braces.
5876
43cbde16 58772012-05-22 Dodji Seketeli <dodji@redhat.com>
5878
5879 PR c++/53322
5880 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
5881
db490cb6 58822012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
5883
5884 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
5885 * c-opts.c (c_common_handle_option): Do not handle explicitly
5886 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
5887
a60f3e81 58882012-05-16 Dodji Seketeli <dodji@redhat.com>
5889
5890 PR preprocessor/7263
5891 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
5892 to cpp_classify_number. For diagnostics, use the precise location
5893 instead of the global input_location.
5894
82e6ef7c 58952012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
5896
cd4797ff 5897 PR c++/11856
82e6ef7c 5898 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
5899
258a168d 59002012-05-14 Bernd Schmidt <bernds@codesourcery.com>
5901
82e6ef7c 5902 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
258a168d 5903
d3b7ee7c 59042012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
5905
5906 PR 53063
5907 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
5908 Wreorder): Use LangEnabledBy.
5909 * c-opts.c (c_common_handle_option): Do not enable them
5910 explicitly. Call lang-specific generated functions.
5911 (c_common_post_options): Do not set them here.
5912
70059cea 59132012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
5914
5915 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
5916 Wmissing-field-initializers,Wmissing-parameter-type,
5917 Wold-style-declaration,Woverride-init): Use EnabledBy.
5918 * c-opts.c (c_common_post_options): Do not set here explicitly.
5919
fbb6fbd8 59202012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
5921
5922 PR 53063
5923 * c-opts.c (c_common_handle_option): Use handle_generated_option
5924 to enable sub-options.
5925
61f69bc9 59262012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
5927
5928 PR c++/53158
5929 * c-common.c (warnings_for_convert_and_check): Use warning_at.
5930
5a1fe2db 59312012-05-10 Richard Guenther <rguenther@suse.de>
5932
5933 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
5934 adjust commentary about TYPE_IS_SIZETYPE types.
5935
d42e7c5a 59362012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
5937
5938 PR c++/53261
5939 * c-common.c (warn_logical_operator): Check that argument of
5940 integer_zerop is not NULL.
5941
686369e8 59422012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
5943
5944 PR c/43772
5945 * c-common.c (warn_logical_operator): Do not warn if either side
5946 is already true or false.
5947
03fe1dc2 59482012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
5949
5950 PR c/51712
5951 * c-common.c (expr_original_type): New.
5952 (shorten_compare): Do not warn for enumeration types.
5953
bba5a206 59542012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
5955
5956 * c.opt (fpermissive): Add Var(flag_permissive).
5957
7059d45d 59582012-04-30 Marc Glisse <marc.glisse@inria.fr>
5959
5960 PR c++/51033
5961 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
5962 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
5963
7edb1062 59642012-04-30 Dodji Seketeli <dodji@redhat.com>
5965
5966 Add -Wvarargs option
5967 * c.opt (Wvarargs): Define new option.
5968
068bea1e 59692012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
5970
5971 * c-common.c (check_function_arguments): Replace
5972 Wmissing-format-attribute with Wsuggest-attribute=format.
5973
b86527d8 59742012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
5975
5976 * c.opt (Wsuggest-attribute=format): New. Alias of
5977 Wmissing-format-attribute.
5978 * c-format.c (decode_format_type): Replace
5979 Wmissing-format-attribute with Wsuggest-attribute=format.
5980 (check_function_format): Likewise.
5981
19931eea 59822012-04-27 Ollie Wild <aaw@google.com>
76d340ac 5983
5984 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
5985 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
5986 * c.opt: Add Wliteral-suffix.
5987
29438999 59882012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
5989
5990 PR c/44774
5991 * c.opt (Wpedantic): New.
5992 (pedantic): Alias Wpedantic.
5993 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
5994 (c_common_post_options): Likewise.
5995 (sanitize_cpp_opts): Likewise.
5996 * c-lex.c (interpret_float): Likewise.
5997 * c-format.c (check_format_types): Likewise.
5998 * c-common.c (pointer_int_sum): Likewise.
5999 (c_sizeof_or_alignof_type): Likewise.
6000 (c_add_case_label): Likewise.
6001 (c_do_switch_warnings): Likewise.
6002 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
6003
4f9d6b8b 60042012-04-15 Jason Merrill <jason@redhat.com>
6005
6006 PR c++/52818
6007 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
6008 (C_STD_NAME): Distinguish between C++98 and C++11.
6009
74bdbe96 60102012-04-11 Eric Botcazou <ebotcazou@adacore.com>
6011
6012 PR target/52624
6013 * c-common.h (uint16_type_node): Rename into...
6014 (c_uint16_type_node): ...this.
6015 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
6016 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
6017
3d177e8c 60182012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
6019
6020 * c-common.c (warn_if_unused_value): Move definition to here.
6021 * c-common.h (warn_if_unused_value): Move declaration to here.
6022
6a9a958f 60232012-03-23 William Bader <williambader@hotmail.com>
6024
6025 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
6026
543efdbe 60272012-03-20 Jason Merrill <jason@redhat.com>
6028
6029 * c-common.h (enum cxx_dialect): Add cxx1y.
6030 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
6031 test.
6032 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
6033 * c-opts.c (c_common_post_options): Likewise.
6034 (set_std_cxx1y): New.
6035 (c_common_handle_option): Call it.
6036 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
6037
62206d34 60382012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
6039
6040 PR c++/14710
6041 * c.opt ([Wuseless-cast]): Add.
6042
fadf62f4 60432012-03-16 Richard Guenther <rguenther@suse.de>
6044
6045 * c-pretty-print.c (pp_c_initializer_list): Adjust.
6046
249faa35 60472012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
6048
6049 PR c++/44783
6050 * c.opt (ftemplate-backtrace-limit) Add.
6051
126b6848 60522012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6053
6054 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
6055 handling.
6056 * c-pragma.c (handle_pragma_extern_prefix): Remove.
6057 (init_pragma): Don't register extern_prefix.
6058
a51edb4c 60592012-03-12 Richard Guenther <rguenther@suse.de>
6060
6061 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
6062 (builtin_type_for_size): Likewise.
6063
0f6a7cb7 60642012-02-13 Jakub Jelinek <jakub@redhat.com>
6065
6066 PR c++/52215
6067 * c-common.c (sync_resolve_params): Don't decide whether to convert
6068 or not based on TYPE_SIZE comparison, convert whenever arg_type
6069 is unsigned INTEGER_TYPE.
6070
0779e32c 60712012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
6072
6073 PR c/52118
6074 * c.opt ([Wunused-local-typedefs]): Fix description.
6075
baec58e1 60762012-01-24 Mike Stump <mikestump@comcast.net>
6077
6078 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
6079 exactly.
6080
c779d8cc 60812012-01-18 Richard Guenther <rguenther@suse.de>
6082
6083 * c-opts.c (c_common_post_options): Reset LTO flags if
6084 we are about to generate a PCH.
6085
ee917d24 60862012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
6087
6088 PR c++/51777
6089 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
6090 use pp_unsigned_wide_integer.
6091
90e2341f 60922012-01-10 Richard Guenther <rguenther@suse.de>
6093
6094 PR middle-end/51806
6095 * c-opts.c (c_common_handle_option): Move -Werror handling
6096 to language independent code.
6097
9ea022ce 60982012-01-05 Richard Guenther <rguenther@suse.de>
6099
6100 PR middle-end/51764
6101 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
6102 from common.opt.
6103
3df19e1b 61042011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
6105
6106 PR c++/51316
6107 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
6108 of array types with an unknown bound.
6109
32074525 61102011-12-20 Joseph Myers <joseph@codesourcery.com>
6111
6112 * c-common.c (flag_isoc99): Update comment to refer to C11.
6113 (flag_isoc1x): Change to flag_isoc11.
6114 * c-common.h (flag_isoc99): Update comment to refer to C11.
6115 (flag_isoc1x): Change to flag_isoc11.
6116 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
6117 C11.
6118 * c-opts.c (set_std_c1x): Change to set_std_c11.
6119 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
6120 Call set_std_c11.
6121 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
6122 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
6123 * c.opt (std=c1x): Change to std=c11. Document as non-draft
6124 standard.
6125 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
6126 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
6127 (std=gnu1x): Make alias of std=gnu11.
6128
fca86134 61292011-12-19 Jason Merrill <jason@redhat.com>
6130
6131 PR c++/51228
6132 * c-common.c (handle_transparent_union_attribute): Check the first
6133 field if the type is complete.
6134
aa4313eb 61352011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
6136
6137 PR libstdc++/51365
6138 * c-common.c (RID_IS_FINAL): Add.
6139 * c-common.h (RID_IS_FINAL): Add.
6140
3f3d5ad4 61412011-11-30 Iain Sandoe <iains@gcc.gnu.org>
6142
6143 * c.opt (fgnu-runtime): Provide full description.
6144 (fnext-runtime): Likewise.
6145 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
6146
c4606d19 61472011-11-28 Andrew MacLeod <amacleod@redhat.com>
6148
6149 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
6150 predefines in one place. Add LOCK_FREE predefines.
6151 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
6152 new func.
6153
1d581089 61542011-11-24 Andrew MacLeod <amacleod@redhat.com>
6155
6156 PR c/51256
19931eea 6157 * c-common.c (get_atomic_generic_size): Check for various error
1d581089 6158 conditions
19931eea 6159 (resolve_overloaded_atomic_exchange,
6160 resolve_overloaded_atomic_compare_exchange,
1d581089 6161 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
6162 error_mark_node for error conditions.
19931eea 6163
6aa221fa 61642011-11-08 Richard Guenther <rguenther@suse.de>
6165
6166 PR middle-end/51010
6167 c-family/
6168
4c0315d0 61692011-11-07 Richard Henderson <rth@redhat.com>
6170 Aldy Hernandez <aldyh@redhat.com>
6171 Torvald Riegel <triegel@redhat.com>
6172
6173 Merged from transactional-memory.
6174
6175 * c-common.c (handle_tm_wrap_attribute,
6176 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
6177 (struct c_common_reswords): Added __transaction* keywords.
6178 (struct c_common_attribute_table): Added transaction* and tm_regparm
6179 attributes.
6180 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
6181 masks.
6182 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
6183 find_tm_attribute): Declare.
6184
920f5a70 61852011-11-07 Jason Merrill <jason@redhat.com>
6186
6187 PR c++/35688
6188 * c-common.c, c-common.h: Revert yesterday's changes.
6189
b4f861b4 61902011-11-06 Jason Merrill <jason@redhat.com>
6191
6192 PR c++/35688
6193 * c-common.c (decl_has_visibility_attr): Split out from...
6194 (c_determine_visibility): ...here.
6195 * c-common.h: Declare it.
6196
83e25171 61972011-11-06 Joseph Myers <joseph@codesourcery.com>
6198
6199 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
6200 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
6201 type.
6202 (check_user_alignment): New. Split out of
6203 handle_aligned_attribute. Disallow integer constants with
6204 noninteger types. Conditionally allow zero.
6205 (handle_aligned_attribute): Use check_user_alignment.
6206 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
6207
1cd6e20d 62082011-11-06 Andrew MacLeod <amacleod@redhat.com>
6209 Richard Henderson <rth@redhat.com>
6210
6211 Merged from cxx-mem-model.
6212
6213 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
19931eea 6214 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
1cd6e20d 6215 parameters that are the same type size.
6216 (get_atomic_generic_size): New. Find size of generic
6217 atomic function parameters and do typechecking.
6218 (add_atomic_size_parameter): New. Insert size into parameter list.
6219 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
6220 either __atomic_exchange_n or external library call.
19931eea 6221 (resolve_overloaded_atomic_compare_exchange): Restructure
1cd6e20d 6222 __atomic_compare_exchange to either _n variant or external library call.
19931eea 6223 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
1cd6e20d 6224 __atomic_load_n or an external library call.
6225 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
6226 __atomic_store_n or an external library call.
6227 (resolve_overloaded_builtin): Handle new __atomic builtins.
6228
7549df0d 62292011-11-04 Eric Botcazou <ebotcazou@adacore.com>
6230
6231 PR c++/50608
6232 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
6233 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
6234 <INDIRECT_REF>: Return the argument.
6235 <ARRAY_REF>: Remove special code for negative offset.
6236 Call fold_build_pointer_plus instead of size_binop.
6237 (fold_offsetof): Remove STOP_REF argument and adjust.
6238 * c-common.h (fold_offsetof_1): Declare.
6239 (fold_offsetof): Remove STOP_REF argument.
6240
7e783eb3 62412011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
6242
6243 PR c++/50810
6244 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
6245 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
6246 Wnarrowing for C++0x and C++98.
6247 * c.opt ([Wnarrowing]): Update.
6248
8fe701f5 62492011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
6250
6251 PR c++/44277
6252 * c.opt: Add Wzero-as-null-pointer-constant.
6253
0d84dc2d 62542011-10-31 Jason Merrill <jason@redhat.com>
6255
67031f52 6256 * c.opt (-fdeduce-init-list): Off by default.
6257
0d84dc2d 6258 PR c++/50920
6259 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
6260 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
6261 and -Wc++11-compat.
6262 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
6263
66f24c41 62642011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
6265
6266 PR c++/30066
6267 * c.opt (fvisibility-inlines-hidden): Description change.
6268
244db24d 62692011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
6270
6271 Implement C++11 user-defined literals.
6272 * c-common.c (build_userdef_literal): New.
6273 * c-common.def: New tree code.
6274 * c-common.h (tree_userdef_literal): New tree struct and accessors.
6275 * c-lex.c (interpret_float): Add suffix parm.
6276 (c_lex_with_flags): Build literal tokens.
6277
235be70f 62782011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
6279
6280 PR c++/50841
6281 Revert:
6282 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
6283
6284 PR c++/50810
6285 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
6286 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
6287 Wnarrowing for C++0x and C++98.
6288 * c.opt ([Wnarrowing]): Update.
6289
4fe0fb1c 62902011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
6291
6292 PR c++/50810
6293 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
6294 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
6295 Wnarrowing for C++0x and C++98.
6296 * c.opt ([Wnarrowing]): Update.
6297
5f7504f9 62982011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
6299
6300 PR c++/45385
6301 * c-common.c (conversion_warning): Remove code looking for
6302 artificial operands.
6303
2a688977 63042011-10-18 Dodji Seketeli <dodji@redhat.com>
6305
6306 PR bootstrap/50760
6307 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
19931eea 6308 !NO_IMPLICIT_EXTERN_C.
2a688977 6309
326e3391 63102011-10-17 Michael Spertus <mike_spertus@symantec.com>
6311
6312 * c-common.c (c_common_reswords): Add __bases,
6313 __direct_bases.
6314 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
6315
63162011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
6317
6318 PR c++/50757
6319 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
6320
62db153a 63212011-10-15 Tom Tromey <tromey@redhat.com>
6322 Dodji Seketeli <dodji@redhat.com>
6323
6324 * c.opt (fdebug-cpp): New option.
6325 * c-opts.c (c_common_handle_option): Handle the option.
6326 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
6327 output stream in parameter. Factorized from ...
6328 (maybe_print_line): ... this. Dump location debug information when
6329 -fdebug-cpp is in effect.
6330 (print_line_1): New static function. Takes an output stream in
6331 parameter. Factorized from ...
6332 (print_line): ... here. Dump location information when -fdebug-cpp
6333 is in effect.
6334 (scan_translation_unit): Dump location information when
6335 -fdebug-cpp is in effect.
6336
ce70f433 63372011-10-15 Tom Tromey <tromey@redhat.com>
6338 Dodji Seketeli <dodji@redhat.com>
6339
6340 * c.opt (ftrack-macro-expansion): New option. Handle it with and
6341 without argument.
6342 * c-opts.c (c_common_handle_option)<case
6343 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
6344 cases. Handle -ftrack-macro-expansion with and without argument.
6345
97bfb9ef 63462011-10-15 Tom Tromey <tromey@redhat.com>
6347 Dodji Seketeli <dodji@redhat.com>
6348
6349 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
6350 (print_line, cb_define, do_line_change): Adjust to avoid touching
6351 the internals of struct line_map. Use the public API instead.
6352 * c-pch.c (c_common_read_pch): Likewise.
6353 * c-lex.c (fe_file_change): Likewise.
6354
326e3391 63552011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
6356
6357 PR c++/17212
6358 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
6359
63602011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
6361
6362 PR c++/33067
6363 * c-pretty-print.c (pp_c_floating_constant): Output
6364 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
6365
b9a16870 63662011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
6367
6368 * c-common.c (def_builtin_1): Delete old interface with two
6369 parallel arrays to hold standard builtin declarations, and replace
6370 it with a function based interface that can support creating
6371 builtins on the fly in the future. Change all uses, and poison
6372 the old names. Make sure 0 is not a legitimate builtin index.
6373 * c-omp.c (c_finish_omp_barrier): Ditto.
6374 (c_finish_omp_taskwait): Ditto.
6375 (c_finish_omp_flush): Ditto.
6376
c7964868 63772011-10-11 Tristan Gingold <gingold@adacore.com>
6378
6379 * c.opt: (fallow-parameterless-variadic-functions): New.
6380
a4e3ffad 63812011-09-08 Dodji Seketeli <dodji@redhat.com>
6382
6383 PR c++/33255 - Support -Wunused-local-typedefs warning
6384 * c-common.h (struct c_language_function::local_typedefs): New
6385 field.
19931eea 6386 (record_locally_defined_typedef, maybe_record_typedef_use)
6387 (maybe_warn_unused_local_typedefs): Declare new functions.
a4e3ffad 6388 * c-common.c (record_locally_defined_typedef)
19931eea 6389 (maybe_record_typedef_use)
6390 (maybe_warn_unused_local_typedefs): Define new functions.
a4e3ffad 6391 * c.opt: Declare new -Wunused-local-typedefs flag.
6392
737a23cc 63932011-09-06 Eric Botcazou <ebotcazou@adacore.com>
6394
6395 PR middle-end/50266
6396 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
6397 computations.
6398
7542c3b4 63992011-09-05 Richard Guenther <rguenther@suse.de>
6400
6401 * c-common.c (complete_array_type): Use ssize_int (-1) instead
6402 of integer_minus_one_node for empty array upper bounds.
6403
1dc92c59 64042011-08-28 Dodji Seketeli <dodji@redhat.com>
6405
6406 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
6407 it's the first time it's being called on this main TU.
6408
2bdf2b6e 64092011-08-24 Richard Guenther <rguenther@suse.de>
6410
6411 PR c/49396
6412 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
6413
64142011-08-22 Gabriel Charette <gchare@google.com>
6ea2c7a3 6415
6416 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
6417 defined in cpp_init_builtins and c_cpp_builtins.
6418
bff4ad11 64192011-08-19 Joseph Myers <joseph@codesourcery.com>
6420
6421 * c-common.c (c_common_reswords): Add __builtin_complex.
6422 * c-common.h (RID_BUILTIN_COMPLEX): New.
6423
985c6e3a 64242011-08-18 Joseph Myers <joseph@codesourcery.com>
6425
6426 * c-common.c (c_common_reswords): Add _Noreturn.
6427 (keyword_is_function_specifier): Handle RID_NORETURN.
6428 * c-common.h (RID_NORETURN): New.
6429
92a44a68 64302011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
7dfa155b 6431
6432 * c-common.c (unsafe_conversion_p): New function. Check if it is
6433 unsafe to convert an expression to the type.
6434 (conversion_warning): Adjust, use unsafe_conversion_p.
6435 * c-common.h (unsafe_conversion_p): New function declaration.
6436
2169f33b 64372011-08-02 Jakub Jelinek <jakub@redhat.com>
6438
6439 * c-common.h (c_finish_omp_atomic): Adjust prototype.
6440 (c_finish_omp_taskyield): New prototype.
6441 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
6442 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
6443 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
6444 or RHS1 have side-effects, evaluate those too in the right spot,
6445 if it is a decl and LHS is also a decl, error out if they
6446 aren't the same.
6447 (c_finish_omp_taskyield): New function.
6448 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
6449 * c-pragma.c (omp_pragmas): Add taskyield.
6450 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
6451 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
6452 PRAGMA_OMP_CLAUSE_MERGEABLE.
6453
ab77850e 64542011-07-25 Dodji Seketeli <dodji@redhat.com>
6455
6456 * c-common.h (set_underlying_type): Remove parm name from
6457 declaration.
6458
6ee97920 64592011-07-25 Romain Geissler <romain.geissler@gmail.com>
6460
6461 * c-pretty-print.h: Search c-common.h in c-family.
19931eea 6462
dc251364 64632011-07-22 Jason Merrill <jason@redhat.com>
6464
1a2a35f0 6465 PR c++/49793
6466 * c.opt (Wnarrowing): New.
6467
27282252 6468 PR c++/30112
6469 * c-common.h: Declare c_linkage_bindings.
6470 * c-pragma.c (handle_pragma_redefine_extname): Use it.
6471
dc251364 6472 PR c++/49813
6473 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
6474 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
6475 as flag_isoc99 for 'restrict'.
6476 (pp_c_specifier_qualifier_list): Likewise for _Complex.
6477
fc501191 64782011-07-21 Ian Lance Taylor <iant@google.com>
6479
6480 PR middle-end/49705
6481 * c-common.c (c_disable_warnings): New static function.
6482 (c_enable_warnings): New static function.
6483 (c_fully_fold_internal): Change local unused_p to bool. Call
6484 c_disable_warnings and c_enable_warnings rather than change
6485 c_inhibit_evaluation_warnings.
6486
07b8f133 64872011-07-20 Jason Merrill <jason@redhat.com>
6488
6489 PR c++/6709 (DR 743)
6490 PR c++/42603 (DR 950)
6491 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
6492 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
6493 (CPP_DECLTYPE): New.
6494 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
6495
2cc66f2a 64962011-07-19 Richard Guenther <rguenther@suse.de>
6497
6498 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
6499 * c-omp.c (c_finish_omp_for): Likewise.
6500
3c802a1e 65012011-07-12 Eric Botcazou <ebotcazou@adacore.com>
6502
6503 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
6504 body on the next line.
6505
98a33d9f 65062011-07-08 Jason Merrill <jason@redhat.com>
6507
3115bda0 6508 PR c++/45437
6509 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
6510
98a33d9f 6511 PR c++/49673
6512 * c-common.c (c_apply_type_quals_to_decl): Don't check
6513 TYPE_NEEDS_CONSTRUCTING.
6514
c38a75b7 65152011-07-06 Richard Guenther <rguenther@suse.de>
6516
6517 * c-common.c (c_common_nodes_and_builtins):
6518 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
6519
e593356b 65202011-07-05 Richard Guenther <rguenther@suse.de>
6521
6522 * c-common.c (c_common_nodes_and_builtins): Build all common
6523 tree nodes first.
6524
fca0886c 65252011-06-27 Jakub Jelinek <jakub@redhat.com>
6526
a68f7a8d 6527 * c-common.h (c_tree_chain_next): New static inline function.
6528
fca0886c 6529 * c-common.c (check_builtin_function_arguments): Handle
6530 BUILT_IN_ASSUME_ALIGNED.
6531
2797f13a 65322011-06-21 Andrew MacLeod <amacleod@redhat.com>
6533
6534 * c-common.c: Add sync_ or SYNC__ to builtin names.
6535 * c-omp.c: Add sync_ or SYNC__ to builtin names.
9cad95b7 6536
65372011-06-20 Pierre Vittet <piervit@pvittet.com>
6538
6539 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
6540 handler.
6541 (gen_pragma_handler): New union.
6542 (internal_pragma_handler): New type.
6543 (c_register_pragma_with_data)
6544 (c_register_pragma_with_expansion_and_data): New functions.
6545
6546 * c-pragma.c (registered_pragmas, c_register_pragma_1)
6547 (c_register_pragma, c_register_pragma_with_expansion)
6548 (c_invoke_pragma_handler): Changed to work with
6549 internal_pragma_handler.
6550 (c_register_pragma_with_data)
6551 (c_register_pragma_with_expansion_and_data): New functions.
6552
218e3e4e 65532011-06-14 Joseph Myers <joseph@codesourcery.com>
6554
6555 * c-common.c: Include common/common-target.h.
6556 (handle_section_attribute): Use
6557 targetm_common.have_named_sections.
6558 * c-cppbuiltin.c: Include common/common-target.h.
6559 (c_cpp_builtins): Use targetm_common.except_unwind_info.
6560
41e53ed2 65612011-06-10 Richard Guenther <rguenther@suse.de>
6562
6563 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
6564 to print a IDENTIFIER_NODE.
6565
a6f06169 65662011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6567 Joseph Myers <joseph@codesourcery.com>
6568
6569 * c.opt (fbuilding-libgcc): New option.
6570 * c-cppbuiltin.c (c_cpp_builtins): Define
6571 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
6572
1ea9269b 65732011-06-07 Jason Merrill <jason@redhat.com>
6574
8ce59854 6575 * c-common.c (max_tinst_depth): Lower default to 900.
6576
1ea9269b 6577 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
6578
1af0124d 65792011-06-07 Richard Guenther <rguenther@suse.de>
6580
6581 * c-common.c (c_common_nodes_and_builtins): Do not set
6582 size_type_node or call set_sizetype.
6583
0e9a4c01 65842011-06-07 Dodji Seketeli <dodji@redhat.com>
6585
6586 PR debug/49130
6587 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
19931eea 6588 type when using pointer comparison to compare types.
0e9a4c01 6589
90b40725 65902011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
6591
6592 * c.opt: Add -Wdelete-non-virtual-dtor.
6593 * c-opts.c (c_common_handle_option): Include it in -Wall.
6594
fc9c9e87 65952011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
6596
6597 PR bootstrap/49190
6598
6599 Revert:
6600 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
6601
6602 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
6603 not tree_common.
6604
d0389adc 66052011-05-27 Jakub Jelinek <jakub@redhat.com>
6606
6607 PR c++/49165
6608 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
6609 C++ don't call c_common_truthvalue_conversion on void type arms.
6610
cacfdc02 66112011-05-27 Nathan Froyd <froydnj@codesourcery.com>
6612
6613 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
6614 (stmt_list_stack): Define.
6615 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
6616 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
6617
027fc6ef 66182011-05-26 Nathan Froyd <froydnj@codesourcery.com>
6619
6620 * c-common.c (warning_candidate_p): Check for BLOCKs.
6621
f21317a1 66222011-05-26 Nathan Froyd <froydnj@codesourcery.com>
6623
6624 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
6625 not tree_common.
6626
789e953d 66272011-05-25 Jakub Jelinek <jakub@redhat.com>
6628
6629 * c-common.c (def_fn_type): Remove extra va_end.
6630
7f506bca 66312011-05-23 Jason Merrill <jason@redhat.com>
6632
6633 PR c++/48106
6634 * c-common.c (c_common_get_narrower): New.
6635 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
6636
774e9d58 66372011-05-23 Nathan Froyd <froydnj@codesourcery.com>
6638
6639 * c-common.h (check_function_arguments): Tweak prototype of
6640 check_function_arguments.
6641 * c-common.c (check_function_arguments): Likewise. Adjust
6642 calls to check_function_nonnull, check_function_format, and
6643 check_function_sentinel.
6644 (check_function_sentinel): Take a FUNCTION_TYPE rather than
6645 separate attributes and typelist arguments. Use
6646 FOREACH_FUNCTION_ARGS to iterate over argument types.
6647
23407dc9 66482011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
6649
6650 * c-common.c (c_common_reswords): Reorder.
6651 * c-common.h (rid): Likewise.
6652
3a939d12 66532011-05-10 Nathan Froyd <froydnj@codesourcery.com>
6654
6655 * c-common.c (def_fn_type): Don't call build_function_type, call
6656 build_function_type_array or build_varargs_function_type_array
6657 instead.
6658 (c_common_nodes_and_builtins): Likewise.
6659
b6e3dd65 66602011-05-05 Nathan Froyd <froydnj@codesourcery.com>
6661
6662 * c-common.c (c_add_case_label): Omit the loc argument to
6663 build_case_label.
6664 * c-common.h (build_case_label): Remove.
6665 * c-semantics.c (build_case_label): Remove.
6666
4232a958 66672011-05-05 Joseph Myers <joseph@codesourcery.com>
6668
6669 * c-objc.h (objc_start_method_definition): Update prototype.
6670 * stub-objc.c (objc_start_method_definition): Add extra parameter.
6671
d0af78c5 66722011-05-04 Nathan Froyd <froydnj@codesourcery.com>
6673
6674 * c-common.c (check_main_parameter_types): Reindent. Don't use
6675 TYPE_ARG_TYPES directly.
6676 (handle_nonnull_attribute): Likewise.
6677 (sync_resolve_params): Likewise.
6678 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
6679 to check_format_string.
6680 (handle_format_attribute): Likewise.
6681 (check_format_string): Take a function type to examine instead of
6682 a type list. Use a function_arg_iterator to step through argument
6683 types.
6684
ceb7b692 66852011-05-04 Richard Guenther <rguenther@suse.de>
6686
6687 * c-common.c (fix_string_type): Use size_int for index type bounds.
6688 (start_fname_decls): Do not pass NULL to build_int_cst.
6689 (c_init_attributes): Likewise.
6690 * c-lex.c (c_lex_with_flags): Likewise.
6691
c66c81be 66922011-04-27 Jason Merrill <jason@redhat.com>
6693
6694 * c-common.c (make_tree_vector_from_list): New.
6695 * c-common.h: Declare it.
6696
16930c72 66972011-04-26 Richard Guenther <rguenther@suse.de>
6698
6699 PR preprocessor/48248
6700 * c-ppoutput.c (maybe_print_line): Always optimize newlines
6701 for output size with -P.
6702
23407dc9 67032011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
6704
6705 * c-common.c (struct c_common_resword): Add __underlying_type.
6706 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
6707
dd045aee 67082011-04-20 Jim Meyering <meyering@redhat.com>
6709
6710 * c-format.c (init_dollar_format_checking): Remove useless
6711 if-before-free.
6712
394dd737 67132011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
6714
6715 * c-objc.h (objc_get_interface_ivars): Removed.
23407dc9 6716 (objc_detect_field_duplicates): New.
394dd737 6717 * stub-objc.c: Likewise.
23407dc9 6718
a758bf7d 67192011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
6720
6721 * stub-objc.c (objc_declare_protocols): Renamed to
6722 objc_declare_protocol.
6723 * c-objc.h: Likewise.
23407dc9 6724
29d7200d 67252011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
6726
6727 * stub-objc.c (objc_declare_class): Updated argument name.
6728
9b88d08d 67292011-04-12 Nathan Froyd <froydnj@codesourcery.com>
6730
6731 * c-common.h (c_common_init_ts): Declare.
6732 * c-common.c (c_common_init_ts): Define.
6733
4185cf58 67342011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
6735
6736 * c-objc.h (objc_build_message_expr): Updated prototype.
6737 * stub-objc.c (objc_build_message_expr): Likewise.
19931eea 6738
5a90471f 67392011-04-12 Martin Jambor <mjambor@suse.cz>
6740
6741 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
6742 of cgraph_node.
6743
783bb57e 67442011-04-11 Richard Guenther <rguenther@suse.de>
6745
6746 * c-common.c (complete_array_type): Build a range type of
6747 proper type.
6748
c33080b9 67492011-04-08 Nathan Froyd <froydnj@codesourcery.com>
6750
6751 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
6752 (handle_type_generic_attribute): Likewise.
6753
f8913d47 67542011-04-07 Jason Merrill <jason@redhat.com>
6755
6756 PR c++/48450
6757 * c-common.c (c_common_truthvalue_conversion): Don't ignore
6758 conversion from C++0x scoped enum.
6759
c94b1d0e 67602011-04-06 Joseph Myers <joseph@codesourcery.com>
6761
6762 * c-target-def.h: New file.
6763 * c-target.def: New file.
6764 * c-target.h: New file.
6765 * c-common.c (targetcm): Don't define here.
6766 * c-common.h (default_handle_c_option): Declare.
6767 * c-format.c: Include c-target.h instead of target.h.
6768 * c-opts.c: Include c-target.h instead of target.h. Explicitly
6769 include tm.h.
6770 (default_handle_c_option): Move from targhooks.c.
6771
acb10f41 67722011-03-29 Jakub Jelinek <jakub@redhat.com>
6773
6774 PR preprocessor/48248
6775 * c-ppoutput.c (print): Add src_file field.
6776 (init_pp_output): Initialize it.
6777 (maybe_print_line): Don't optimize by adding up to 8 newlines
6778 if map->to_file and print.src_file are different file.
6779 (print_line): Update print.src_file.
6780
82715bcd 67812011-03-25 Kai Tietz <ktietz@redhat.com>
6782
6783 * c-ada-spec.c (compare_comment): Use filename_cmp
6784 instead of strcmp for filename.
6785
451c8e2f 67862011-03-25 Jeff Law <law@redhat.com>
6787
1f78217c 6788 * c-common.c (def_fn_type): Add missing va_end.
451c8e2f 6789
3c47771c 67902011-03-25 Jason Merrill <jason@redhat.com>
6791
6792 * c.opt: Add -std=c++03.
6793
97e6200f 67942011-03-22 Eric Botcazou <ebotcazou@adacore.com>
6795
6796 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
6797
92a44a68 67982011-03-17 Kai Tietz <ktietz@redhat.com>
ac86af5d 6799
6800 PR target/12171
ee212425 6801 * c-pretty-print.c (pp_c_specifier_qualifier_list):
6802 Display allowed attributes for function pointer types.
6803 (pp_c_attributes_display): New function to display
6804 attributes having affects_type_identity flag set to true.
6805 * c-pretty-print.h (pp_c_attributes_display): New prototype.
6806
ac86af5d 6807 * c-common.c (c_common_attribute_table):
6808 Add new element.
6809 (c_common_format_attribute_table): Likewise.
6810
914d1151 68112011-03-18 Jason Merrill <jason@redhat.com>
6812
69788bdf 6813 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
6814 * c-common.h: Don't declare it here.
6815 * c-common.c: Or define it here.
6816 * c-opts.c (c_common_handle_option): Or set it here.
6817
914d1151 6818 PR c++/35315
6819 * c-common.c (handle_transparent_union_attribute): Don't
6820 make a duplicate type in C++.
6821
54cf6eed 68222011-03-15 Jason Merrill <jason@redhat.com>
6823
6824 * c-common.c (max_constexpr_depth): New.
6825 * c-common.h: Declare it.
6826 * c-opts.c (c_common_handle_option): Set it.
6827 * c.opt (fconstexpr-depth): New option.
6828
02cb1060 68292011-03-11 Jason Merrill <jason@redhat.com>
6830
9bf1c74e 6831 * c-common.c (attribute_takes_identifier_p): Add missing const.
6832
02cb1060 6833 PR c++/46803
6834 * c-common.c (attribute_takes_identifier_p): Assume that an
6835 unknown attribute takes an identifier.
6836
ecf2703d 68372011-03-07 Nathan Froyd <froydnj@codesourcery.com>
6838
6839 PR c/47786
6840 * c-common.c (c_type_hash): Call list_length instead of iterating
6841 through DECL_CHAIN. Rename 'i' to 'n_elements'.
6842
2b19dfe4 68432011-02-19 Jakub Jelinek <jakub@redhat.com>
6844
6845 PR c/47809
6846 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
6847
29cf2335 68482011-02-17 Iain Sandoe <iains@gcc.gnu.org>
6849
6850 * c.opt (fobjc-abi-version=) New.
6851 (fobjc-nilcheck): New.
6852
fad3f658 68532011-02-03 Nathan Froyd <froydnj@codesourcery.com>
6854
6855 PR c++/46890
6856 * c-common.h (keyword_is_decl_specifier): Declare.
6857 * c-common.c (keyword_is_decl_specifier): Define.
6858 (keyword_is_function_specifier): New function.
6859
a12319b3 68602011-01-26 Jakub Jelinek <jakub@redhat.com>
6861
6862 PR c/47473
6863 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
6864 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
6865 REAL_TYPE.
6866
5c128dc8 68672011-01-26 Arnaud Charlet <charlet@adacore.com>
6868
6869 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
6870
8d67b0c7 68712011-01-26 Jakub Jelinek <jakub@redhat.com>
6872
6873 PR pch/47430
6874 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
6875 after init_c_lex if pch_file is set.
6876
0675168d 68772011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
6878
e8911163 6879 PR c++/43601
0675168d 6880 * c.opt (-fkeep-inline-dllexport): New switch.
6881
0725e25c 68822011-01-12 Richard Guenther <rguenther@suse.de>
6883
6884 PR middle-end/32511
6885 * c-common.c (handle_weak_attribute): Warn instead of error
6886 on declaring an inline function weak.
6887
fdd84b77 68882011-01-05 Tom Tromey <tromey@redhat.com>
6889
6890 * c-common.h (lvalue_error): Update.
6891 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
6892 not error.
6893
e6e73d14 68942010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
19931eea 6895
d67e8485 6896 PR objc/47075
6897 * c-objc.h (objc_finish_message_expr): Added argument to
6898 prototype.
6899
a36cf284 69002010-12-22 Nathan Froyd <froydnj@codesourcery.com>
6901
6902 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
6903 Use prototype_p.
6904
33b3681f 69052010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
6906
6907 * c-objc.h (objc_maybe_warn_exceptions): New.
19931eea 6908 * stub-objc.c (objc_maybe_warn_exceptions): New.
33b3681f 6909
a1f90215 69102010-12-10 Nathan Froyd <froydnj@codesourcery.com>
6911
6912 * c-common.h (readonly_error): Declare.
6913 * c-common.c (readonly_error): Define.
6914
b1bbc8e5 69152010-12-09 Nathan Froyd <froydnj@codesourcery.com>
6916
6917 * c-common.h (invalid_indirection_error): Declare.
6918 * c-common.c (invalid_indirection_error): Define.
6919
b0d55af9 69202010-12-03 Richard Guenther <rguenther@suse.de>
6921
6922 PR c/46745
6923 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
6924 (pp_c_unary_expression): Likewise.
6925 (pp_c_expression): Likewise.
6926
d7489d8d 69272010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
6928
6929 * c-common.h (objc_finish_function): New.
6930 (objc_non_volatilized_type): Removed.
6931 (objc_type_quals_match): Removed.
6932 * stub-objc.c (objc_finish_function): New.
6933 (objc_non_volatilized_type): Removed.
6934 (objc_type_quals_match): Removed.
19931eea 6935
92468061 69362010-11-30 Joseph Myers <joseph@codesourcery.com>
6937
6938 * c-common.h (parse_optimize_options): Declare.
6939 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
6940 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
6941
967958e4 69422010-11-29 Joseph Myers <joseph@codesourcery.com>
6943
6944 * c-opts.c (check_deps_environment_vars): Use getenv instead of
6945 GET_ENVIRONMENT.
6946 * c-pch.c (O_BINARY): Don't define here.
6947 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
6948
b213bf24 69492010-11-25 Joseph Myers <joseph@codesourcery.com>
6950
6951 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
6952 targetm.except_unwind_info.
6953
9faf44d6 69542010-11-23 Joseph Myers <joseph@codesourcery.com>
6955
6956 * c-opts.c (c_common_handle_option): Pass location to
6957 set_struct_debug_option.
6958
79396169 69592010-11-23 Joseph Myers <joseph@codesourcery.com>
6960
6961 * c-common.c (visibility_options): Move from ../opts.c.
6962 * c-common.h (struct visibility_flags, visibility_options):
6963 Declare here.
6964 * c-opts.c (finish_options): Rename to c_finish_options.
6965 (c_common_init): Update call to finish_options.
6966
b4aa4123 69672010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
6968
6969 PR objc/34033
6970 * c-lex.c (lex_string): Check that each string in an Objective-C
6971 string concat sequence starts with either one or zero '@', and
6972 that there are no spurious '@' signs at the end.
6973
3e0e49f2 69742010-11-20 Joseph Myers <joseph@codesourcery.com>
6975
6976 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
6977 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
6978 HANDLE_PRAGMA_VISIBILITY.
6979 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
6980 HANDLE_PRAGMA_VISIBILITY): Don't define.
6981 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
6982
a9ffdd35 69832010-11-20 Nathan Froyd <froydnj@codesourcery.com>
6984
6985 PR c++/16189
6986 PR c++/36888
6987 PR c++/45331
6988 * c-common.h (keyword_begins_type_specifier): Declare.
6989 (keyword_is_storage_class_specifier): Declare.
6990 (keyword_is_type_qualifier): Declare.
6991 * c-common.c (keyword_begins_type_specifier): New function.
6992 (keyword_is_storage_class_specifier): New function.
6993 (keyword_is_type_qualifier): Declare.
6994
93be21c0 69952010-11-19 Joseph Myers <joseph@codesourcery.com>
6996
6997 PR c/46547
6998 * c-common.c (in_late_binary_op): Define.
6999 (c_common_truthvalue_conversion): Check in_late_binary_op before
7000 calling c_save_expr.
7001 * c-common.h (in_late_binary_op): Declare.
7002
d7175aef 70032010-11-19 Joseph Myers <joseph@codesourcery.com>
7004
7005 * c-opts.c (c_common_handle_option): Update calls to
7006 set_struct_debug_option.
7007
c213e196 70082010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
7009
7010 * c-common.h (objc_declare_protocols): Added additional argument.
7011 * stub-objc.c (objc_declare_protocol): Same change.
19931eea 7012
0b5fc5d6 70132010-11-18 Nathan Froyd <froydnj@codesourcery.com>
7014
7015 PR c/33193
7016 * c-common.h (build_real_imag_expr): Declare.
7017 * c-semantics.c (build_real_imag_expr): Define.
7018
b8ba44e7 70192010-11-17 Joseph Myers <joseph@codesourcery.com>
7020
7021 * c-opts.c (c_common_parse_file): Take no arguments.
7022 * c-common.h (c_common_parse_file): Update prototype.
7023
6ef8d12f 70242010-11-16 Jakub Jelinek <jakub@redhat.com>
7025
7026 PR c++/46401
7027 * c-common.c (warning_candidate_p): Don't track non-const calls
7028 or STRING_CSTs.
7029
929d2a90 70302010-11-15 Ian Lance Taylor <iant@google.com>
7031
7032 * c-lex.c (init_c_lex): Set macro debug callbacks if
7033 flag_dump_go_spec is set.
7034
e4a7640a 70352010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
7036
7037 * c-common.h (objc_build_incr_expr_for_property_ref): New.
7038 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
7039
597d2d81 70402010-11-15 Nathan Froyd <froydnj@codesourcery.com>
7041
7042 PR preprocessor/45038
7043 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
7044 dialects.
7045
c123f04d 70462010-11-12 Joseph Myers <joseph@codesourcery.com>
7047
7048 * c-common.h (c_family_lang_mask): Declare.
7049 * c-opts.c (c_family_lang_mask): Make extern.
7050 * c-pragma.c (handle_pragma_diagnostic): Use
7051 control_warning_option.
7052
3c6c0e40 70532010-11-12 Joseph Myers <joseph@codesourcery.com>
7054
7055 * c-common.c (parse_optimize_options): Update call to
7056 decode_options.
7057 * c-common.h (c_common_handle_option): Update prototype.
7058 * c-opts.c (c_common_handle_option): Take location_t parameter and
7059 pass it to other functions.
7060
19ec5c9e 70612010-11-11 Joseph Myers <joseph@codesourcery.com>
7062
7063 * c-opts.c (warning_as_error_callback): Remove.
7064 (c_common_initialize_diagnostics): Don't call
7065 register_warning_as_error_callback.
7066 (c_common_handle_option): Handle -Werror=normalized= here.
7067
bf776685 70682010-11-10 Joseph Myers <joseph@codesourcery.com>
7069
7070 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
7071 in diagnostic.
7072 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
7073 letter.
7074 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
7075 Remove trailing '.' from diagnostics.
7076 * c.opt (Wwrite-strings_: Avoid '`' in help text.
7077
6bd9d862 70782010-11-10 Joseph Myers <joseph@codesourcery.com>
7079
7080 * c-common.c (parse_optimize_options): Pass global_dc to
7081 decode_options.
7082 * c-opts.c (c_common_handle_option): Pass &global_options to
7083 set_Wstrict_aliasing.
7084 * c.opt (v): Don't mark Common or document here.
7085
1f6616ee 70862010-11-06 Iain Sandoe <iains@gcc.gnu.org>
7087
7088 PR target/44981
7089 * c-format.c (format_type): New type gcc_objc_string_format_type.
7090 (valid_stringptr_type_p): New.
7091 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
19931eea 7092 (check_format_string): Pass expected type, use
1f6616ee 7093 valid_stringptr_type_p (), check that the format string types are
7094 consistent with the format specification.
7095 (decode_format_attr): Warn if NSString is used outside objective-c.
7096 (format_types_orig): Add NSString.
7097 (format_name): New.
7098 (format_flags): New.
7099 (check_format_arg): Handle format strings requiring an external parser.
7100 first_target_format_type: New variable.
7101 (handle_format_attribute): Set up first_target_format_type, pass the
7102 expected format arg string type to check_format_string().
7103 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
7104 * stub-objc.c (objc_string_ref_type_p): New.
7105 (objc_check_format_arg): New.
7106
b0d0931f 71072010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
7108
19931eea 7109 Fixed using the Objective-C 2.0 dot-syntax with class names.
b0d0931f 7110 * c-common.h (objc_build_class_component_ref): New.
7111 * stub-objc.c (objc_build_class_component_ref): New.
7112
f26877d5 71132010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
7114
7115 * c.opt (Wproperty-assign-default): New option.
7116
1ef143b6 71172010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
7118
7119 Implemented -fobjc-std=objc1 flag.
7120 * c.opt (fobjc-std=objc1): New option.
7121
8c582e4f 71222010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
7123
7124 Implemented format and noreturn attributes for Objective-C methods.
7125 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
7126 attribute for Objective-C methods.
7127
8637f1db 71282010-10-31 Jason Merrill <jason@redhat.com>
7129
7130 * c-common.c (conversion_warning, warn_for_collisions_1): Use
7131 EXPR_LOC_OR_HERE.
7132
9d9f5bb3 71332010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
7134
7135 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
7136 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
7137 (objc_add_property_declaration): Removed arguments for copies and
7138 ivar.
7139 (objc_build_getter_call): Renamed to
7140 objc_maybe_build_component_ref.
7141 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
7142 (objc_is_property_ref): New.
7143 * c-common.c (c_common_reswords): Removed copies and ivar.
7144 * stub-objc.c (objc_add_property_declaration): Removed arguments
7145 for copies and ivar.
7146 (objc_build_getter_call): Renamed to
7147 objc_maybe_build_component_ref.
7148 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
7149 (objc_is_property_ref): New.
19931eea 7150
56f907a0 71512010-10-29 Arnaud Charlet <charlet@adacore.com>
7152 Matthew Gingell <gingell@adacore.com>
7153
7154 * c-ada-spec.c (separate_class_package): New function.
7155 (pp_ada_tree_identifier): Prefix references to C++ classes with the
7156 name of their enclosing package.
7157 (print_ada_declaration): Use separate_class_package.
7158
b5fa273e 71592010-10-27 Jason Merrill <jason@redhat.com>
7160
5290e253 7161 * c-common.c (c_common_reswords): Add __is_literal_type.
7162 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
7163
b5fa273e 7164 * c-common.c (check_case_value): Remove special C++ code.
7165
7590f0e5 71662010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
7167
7168 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
7169 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
7170 and RID_LAST_PATTR.
7171 (objc_add_property_declaration): Added additional arguments.
7172 (objc_property_attribute_kind): Removed.
7173 (objc_set_property_attr): Removed.
7174 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
7175 copy and nonatomic.
7176 * stub-objc.c (objc_add_property_declaration): Added additional
7177 arguments.
7178 (objc_set_property_attr): Removed.
19931eea 7179
1d894bcf 71802010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
7181
7182 * c-common.h (objc_add_property_variable): Renamed to
7183 objc_add_property_declaration. Added location argument.
7184 * stub-objc.c (objc_add_property_variable): Same change.
8204c077 7185
e23bf1fb 71862010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
7187
7188 * c-common.h (objc_maybe_printable_name): New.
7189 * stub-objc.c (objc_maybe_printable_name): New.
7190
92a44a68 71912010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
7192 Andrew Pinski <pinskia@gmail.com>
93426222 7193
7194 * c-common.h (c_common_mark_addressable_vec): Declare.
7195 * c-common.c (c_common_mark_addressable_vec): New function.
7196
45b2b110 71972010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
7198
7199 * c-common.h (objc_set_method_type): Removed.
7200 (objc_add_method_declaration): Added boolean argument.
7201 (objc_start_method_definition): Same change.
7202 (objc_build_method_signature): Same change.
7203 * stub-objc.c (objc_set_method_type): Removed.
7204 (objc_add_method_declaration): Added boolean argument.
7205 (objc_start_method_definition): Same change.
7206 (objc_build_method_signature): Same change.
7207
64cd9619 72082010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
7209
7210 * c-common.h (finish_file): Removed.
7211 (objc_write_global_declarations): New.
7212 * c-opts.c (c_common_parse_file): Do not call finish_file.
7213 * stub-objc.c (objc_write_global_declarations): New.
19931eea 7214
e1f293c0 72152010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
7216
7217 Implemented parsing @synthesize and @dynamic for
7218 Objective-C/Objective-C++.
7219 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
7220 (objc_add_synthesize_declaration): New.
7221 (objc_add_dynamic_declaration): New.
7222 * c-common.c (c_common_reswords): Add synthesize and dynamic.
7223 * stub-objc.c (objc_add_synthesize_declaration): New.
7224 (objc_add_dynamic_declaration): New.
19931eea 7225
ef97a312 72262010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
7227
7228 PR target/46041
7229 * c-cppbuiltin.c (mode_has_fma): Move function here from
7230 builtins.c. Don't use the fma optab, instead just use the
7231 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
7232 using -save-temps.
7233
69b07042 72342010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
7235
7236 Merge from 'apple/trunk' branch on FSF servers.
ef97a312 7237
92a44a68 7238 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
69b07042 7239
19931eea 7240 Radar 4330422
69b07042 7241 * c-common.h (objc_non_volatilized_type): New declaration
7242 * stub-objc.c (objc_non_volatilized_type): New stub.
7243
f15f2e56 72442010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
7245
69b07042 7246 Merge from 'apple/trunk' branch on FSF servers.
f15f2e56 7247
92a44a68 7248 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
f15f2e56 7249
19931eea 7250 Radar 4133425
f15f2e56 7251 * c-common.h (objc_diagnose_private_ivar): New decl.
ef97a312 7252 * stub-objc.c (objc_diagnose_private_ivar): New stub.
f15f2e56 7253
4a8875ed 72542010-10-17 Iain Sandoe <iains@gcc.gnu.org>
7255
7256 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
7257 * c-common.h (enum rid): Add RID_AT_PACKAGE.
7258 (objc_ivar_visibility_kind): New enum.
7259 (objc_set_visibility): Adjust prototype to use visibility enum.
ef97a312 7260 * stub-objc.c (objc_set_visibility): Adjust stub to use
4a8875ed 7261 visibility enum.
7262
7e0713b1 72632010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
7264
7265 * c-cppbuiltin.c (builtin_define_float_constants): Emit
7266 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
7267 has the appropriate fma builtins.
7268 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
7269
86c110ac 72702010-10-14 Iain Sandoe <iains@gcc.gnu.org>
7271
7e0713b1 7272 merge from FSF apple 'trunk' branch.
92a44a68 7273 2006 Fariborz Jahanian <fjahanian@apple.com>
7e0713b1 7274
86c110ac 7275 Radars 4436866, 4505126, 4506903, 4517826
7276 * c-common.c (c_common_resword): Define @property and its attributes.
7277 * c-common.h: Define property attribute enum entries.
7278 (OBJC_IS_PATTR_KEYWORD): New.
7279 (objc_property_attribute_kind): New enum.
7280 Declare objc_set_property_attr (), objc_add_property_variable (),
7281 objc_build_getter_call () and objc_build_setter_call ().
7282 * stub-objc.c (objc_set_property_attr): New stub.
7283 (objc_add_property_variable): Likewise.
7284 (objc_build_getter_call): Likewise.
7285 (objc_build_setter_call) Likewise.
7e0713b1 7286
40c8d1dd 72872010-10-13 Iain Sandoe <iains@gcc.gnu.org>
7288
7e0713b1 7289 merge from FSF apple 'trunk' branch.
92a44a68 7290 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
40c8d1dd 7291
7292 Radar 3803157 (method attributes)
7293 * c-common.c (handle_deprecated_attribute): Recognize
7294 objc methods as valid declarations.
7295 * c-common.h: Declare objc_method_decl ().
7e0713b1 7296 * stub-objc.c (objc_method_decl): New stub.
40c8d1dd 7297
f3f006ad 72982010-10-08 Joseph Myers <joseph@codesourcery.com>
7299
7300 * c-common.c (parse_optimize_options): Call
7301 decode_cmdline_options_to_array_default_mask before
7302 decode_options. Update arguments to decode_options.
7303 * c-common.h (c_common_init_options_struct): Declare.
7304 * c-opts.c (c_common_init_options_struct): New. Split out from
7305 c_common_init_options.
7306
0a65c3bb 73072010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
7308
7309 Implemented fast enumeration for Objective-C.
7310 * c-common.h (objc_finish_foreach_loop): New.
7311 * stub-objc.c (objc_finish_foreach_loop): New.
7312
24ca3b4e 73132010-10-05 Joseph Myers <joseph@codesourcery.com>
7314
7315 * c-common.h (struct diagnostic_context): Don't declare here.
7316 (c_common_initialize_diagnostics): Declare using
7317 diagnostic_context typedef.
7318 * c-opts.c (c_common_handle_option): Pass global_dc to
7319 handle_generated_option.
7320
f83b64ca 73212010-10-04 Joseph Myers <joseph@codesourcery.com>
7322
7323 * c-opts.c (c_common_handle_option): Pass &global_options_set to
7324 handle_generated_option.
7325
2fdec027 73262010-10-03 Ian Lance Taylor <iant@google.com>
7327
7328 * c.opt (-fplan9-extensions): New option.
7329
41acdfa4 73302010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
7331
7332 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
7333 Remove.
7334 (c_cpp_builtins): Call functions from cppbuiltin.c instead
7335 of duplicating code.
7336
069761fb 73372010-09-30 Iain Sandoe <iains@gcc.gnu.org>
7338
7339 * c-common.c: Add two new entries for @optional
7340 and @required keywords.
7341
7342 merge from FSF 'apple/trunk' branch.
92a44a68 7343 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
069761fb 7344
7345 Radar 4386773
7346 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
7347 objective-c keywords.
7348 (objc_set_method_opt): New declaration.
7349 * stub-objc.c (objc_set_method_opt): New stub.
19931eea 7350
2c5d2e39 73512010-09-30 Joseph Myers <joseph@codesourcery.com>
7352
7353 * c-common.c (handle_optimize_attribute): Pass &global_options to
7354 cl_optimization_save and cl_optimization_restore.
7355 * c-opts.c (c_common_handle_option): Pass &global_options to
7356 handle_generated_option.
7357 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
7358 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
7359 &global_options to cl_optimization_restore.
7360
e5c75ac3 73612010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
7362
7363 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
7364 Objective-C/Objective-C++ keywords.
7365
3511333e 73662010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
e147d6aa 7367
19931eea 7368 Merge from 'apple/trunk' branch on FSF servers.
7369
92a44a68 7370 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
e147d6aa 7371
7372 Radar 4281748
7373 * c-common.h (objc_check_global_decl): New declaration.
7374 * stub-objc.c (objc_check_global_decl): New stub.
7375
5461e683 73762010-09-29 Joseph Myers <joseph@codesourcery.com>
7377
7378 * c.opt: Don't use VarExists.
7379
5ae82d58 73802010-09-29 Joseph Myers <joseph@codesourcery.com>
7381
7382 * c-common.c (c_cpp_error): Update names of diagnostic_context
7383 members.
7384 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
7385 cl_optimization members.
7386 * c-opts.c (warning_as_error_callback, c_common_handle_option,
7387 sanitize_cpp_opts, finish_options): Update names of cpp_options
7388 members.
7389
b27e241e 73902010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
7391
7392 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
7393 (objc_is_reserved_word): Removed.
7394 * c-common.c: Updated comments.
7395 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
7396 objc_is_reserved_word.
7397 * stub-objc.c (objc_is_reserved_word): Removed.
7398
03fc2271 73992010-09-28 Iain Sandoe <iains@gcc.gnu.org>
7400
19931eea 7401 * c-common.h (objc_add_method_declaration): Adjust prototype to
03fc2271 7402 include attributes.
7403 (objc_start_method_definition): Likewise.
7404 (objc_build_keyword_decl): Likewise.
7405 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
7406 (objc_start_method_definition): Likewise.
7407 (objc_build_keyword_decl): Likewise.
7408
a336eb4b 74092010-09-28 Iain Sandoe <iains@gcc.gnu.org>
7410
7411 * c-common.h (objc_start_class_interface): Adjust prototype.
7412 (objc_start_category_interface): Likewise.
7413 (objc_start_protocol): Likewise.
7414 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
7415 (objc_start_class_interface): Likewise.
7416 (objc_start_category_interface): Likewise.
7417
48b14f50 74182010-09-27 Ian Lance Taylor <iant@google.com>
7419
7420 * c-common.c (c_common_attribute_table): Add no_split_stack.
7421 (handle_no_split_stack_attribute): New static function.
7422
4abfc532 74232010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
7424
19931eea 7425 Merge from 'apple/trunk' branch on FSF servers.
4abfc532 7426
92a44a68 7427 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
4abfc532 7428
19931eea 7429 Radar 4229905
4abfc532 7430 * c-common.h (objc_have_common_type): New declaration.
7431 * stub-objc.c (objc_have_common_type): New stub.
7432
7433 2005-06-22 Ziemowit Laski <zlaski@apple.com>
7434
7435 Radar 4154928
7436 * c-common.h (objc_common_type): New prototype.
19931eea 7437 * stub-objc.c (objc_common_type): New stub.
4abfc532 7438
7bd95dfd 74392010-09-24 Jan Hubicka <jh@suse.cz>
7440
7441 * c-common.c (handle_leaf_attribute): New function.
7442 (struct attribute_spec c_common_att): Add leaf.
7443
5789e05b 74442010-09-22 Joseph Myers <joseph@codesourcery.com>
7445
7446 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
7447 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
7448 -dump, -dump=, -imacros, -imacros=, -include, -include=,
7449 -include-barrier, -include-directory, -include-directory=,
7450 -include-directory-after, -include-directory-after=,
7451 -include-prefix, -include-prefix=, -include-with-prefix,
7452 -include-with-prefix=, -include-with-prefix-after,
7453 -include-with-prefix-after=, -include-with-prefix-before,
7454 -include-with-prefix-before=, -no-integrated-cpp,
7455 -no-line-commands, -no-standard-includes, -no-warnings, -output,
7456 -output=, -pedantic, -pedantic-errors, -preprocess,
7457 -print-missing-file-dependencies, -trace-includes, -traditional,
7458 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
7459 -user-dependencies, -verbose, -write-dependencies,
7460 -write-user-dependencies, no-integrated-cpp, traditional): New.
7461
e6fb54ba 74622010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
7463
7464 PR objc/23710
9b60f3b0 7465 * c-common.h (objc_start_method_definition): Return bool instead
7466 of void.
7467 * stub-objc.c (objc_start_method_definition): Return bool instead
7468 of void.
7469
74702010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
7471
7472 PR objc/25965
7473 * c-common.h (objc_get_interface_ivars): New declaration.
7474 * stub-objc.c (objc_get_interface_ivars): New stub.
e6fb54ba 7475
e44b0a1f 74762010-09-15 Ian Lance Taylor <iant@google.com>
7477
7478 * c-common.c (parse_optimize_options): Do not capitalize warning
ebd7c4c1 7479 messages. Remove period at end of warning message.
e44b0a1f 7480
85c0a25c 74812010-09-09 Nathan Sidwell <nathan@codesourcery.com>
7482
7483 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
7484 (handle_alias_attribute): ... here.
7485 (handle_ifunc_attribute): New.
7486
5ba33bf4 74872010-09-06 Mark Mitchell <mark@codesourcery.com>
7488
7489 * c-common.h (do_warn_double_promotion): Declare.
7490 * c-common.c (do_warn_double_promotion): Define.
7491
c920faa3 74922010-09-05 Mark Mitchell <mark@codesourcery.com>
7493
7494 * c.opt (Wdouble-promotion): New.
7495
9604e070 74962010-09-02 Joseph Myers <joseph@codesourcery.com>
7497
7498 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
7499 fvtable-thunks, fxref): Mark no longer supported in help text.
7500
3b0273a1 75012010-09-02 Joseph Myers <joseph@codesourcery.com>
7502
7503 * c.opt (Wimport, fall-virtual, falt-external-templates,
7504 fdefault-inline, fenum-int-equiv, fexternal-templates,
7505 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
7506 fname-mangling-version-, fnew-abi, fnonnull-objects,
7507 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
7508 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
7509 applicable.
7510 (fhandle-exceptions): Mark with Alias and Warn.
7511 * c-opts.c (c_common_handle_option): Don't handle options marked
7512 as ignored.
7513
67089c6b 75142010-09-02 Joseph Myers <joseph@codesourcery.com>
7515
7516 * c.opt (Wcomments, Werror-implicit-function-declaration,
7517 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
7518 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
7519 aliases.
7520 * c-common.c (option_codes): Use OPT_Wcomment instead of
7521 OPT_Wcomments.
7522 * c-opts.c (warning_as_error_callback, c_common_handle_option):
7523 Don't handle options marked as aliases.
7524
2af087f2 75252010-08-25 Richard Guenther <rguenther@suse.de>
7526
7527 * c-common.c (c_common_get_alias_set): Remove special
7528 handling for pointers.
7529
48148244 75302010-08-20 Nathan Froyd <froydnj@codesourcery.com>
7531
7532 * c-common.c: Use FOR_EACH_VEC_ELT.
7533 * c-gimplify.c: Likewise.
7534 * c-pragma.c: Likewise.
7535
89c69892 75362010-08-16 Joseph Myers <joseph@codesourcery.com>
7537
7538 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
7539 RejectDriver.
7540 (MMDX): Change back to MMD. Mark NoDriverArg instead of
7541 RejectDriver.
7542 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
7543 instead of OPT_MDX and OPT_MMDX.
7544
e28aa114 75452010-08-16 Joseph Myers <joseph@codesourcery.com>
7546
7547 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
7548
99b66d21 75492010-08-12 Joseph Myers <joseph@codesourcery.com>
7550
7551 * c.opt (MD, MMD): Change to MDX and MMDX.
7552 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
7553
666f4bf0 75542010-08-11 Joseph Myers <joseph@codesourcery.com>
7555
7556 * c-opts.c (c_common_handle_option): Call handle_generated_option
7557 instead of handle_option.
7558
5ec815f6 75592010-08-08 Nathan Froyd <froydnj@codesourcery.com>
7560
7561 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
7562 (maybe_apply_renaming_pragma): Delete unneeded declarations.
7563
d13143cf 75642010-08-08 Nathan Froyd <froydnj@codesourcery.com>
7565
7566 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
7567 (pending_redefine_extname): Change type to a VEC.
7568 (add_to_renaming_pragma_list): Update for new type of
7569 pending_redefine_extname.
5ec815f6 7570 (maybe_apply_renaming_pragma): Likewise.
d13143cf 7571
2008c983 75722010-08-04 Arnaud Charlet <charlet@adacore.com>
7573
7574 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
7575 visited.
7576 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
7577 decide whether a type has already been declared/seen.
7578 Do not go to the original type.
7579 (dump_nested_types): New parameter forward.
7580 Generate forward declaration if needed and mark type as visited.
7581 (print_ada_declaration): Call dump_nested_types if not already done.
7582 Mark types as visited.
7583
9b091a73 75842010-08-03 Joseph Myers <joseph@codesourcery.com>
7585
7586 * c.opt (-print-pch-checksum): Remove option.
7587 * c-opts.c (c_common_handle_option): Don't handle
7588 OPT_print_pch_checksum.
7589
b78351e5 75902010-07-27 Joseph Myers <joseph@codesourcery.com>
7591
7592 * c-common.h (c_common_handle_option): Update prototype and return
7593 value type.
7594 * c-opts.c (c_common_handle_option): Update prototype and return
7595 value type. Update calls to handle_option and
7596 enable_warning_as_error.
7597
34416a90 75982010-07-27 Jakub Jelinek <jakub@redhat.com>
7599
7600 PR c/45079
7601 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
7602
fecf9011 76032010-07-27 Joseph Myers <joseph@codesourcery.com>
7604
7605 * c-common.h (c_common_missing_argument): Remove.
7606 * c-opts.c (c_common_missing_argument): Remove.
7607 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
7608 idirafter, imacros, include, isysroot, isystem, iquote): Add
7609 MissingArgError.
7610 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
7611
e88d34f6 76122010-07-27 Joseph Myers <joseph@codesourcery.com>
7613
7614 * c-common.h (c_common_option_lang_mask,
7615 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
7616 New.
7617 (c_common_init_options): Update prototype.
7618 * c-opts.c (c_common_option_lang_mask): New.
7619 (c_common_initialize_diagnostics): Split out of
7620 c_common_init_options.
7621 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
7622 New.
7623 (c_common_init_options): Update prototype. Use decoded options in
7624 search for -lang-asm.
7625
1767a056 76262010-07-15 Nathan Froyd <froydnj@codesourcery.com>
7627
7628 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
7629 * c-format.c: Likewise.
7630
0b205f4c 76312010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
7632
7633 * c-common.h: Include diagnostic-core.h. Error if already
7634 included.
7635 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
7636
1c58e3f1 76372010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
7638
1f78217c 7639 * c-common.c (IN_GCC_FRONTEND): Do not undef.
1c58e3f1 7640 Do not include expr.h
7641 (vector_mode_valid_p): Move here.
7642
33cc157c 76432010-06-21 DJ Delorie <dj@redhat.com>
7644
7645 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
7646 allow these pragmas anywhere.
7647
76482010-06-14 Jakub Jelinek <jakub@redhat.com>
7649
7650 PR bootstrap/44509
7651 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
7652 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
7653 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
7654 ggc_strdup instead of xstrdup.
7655
76562010-06-10 Jakub Jelinek <jakub@redhat.com>
7657
7658 * c-cppbuiltin.c: Include cpp-id-data.h.
7659 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
7660 (lazy_hex_fp_value): New function.
7661 (builtin_define_with_hex_fp_value): Provide definitions lazily.
7662
9b40bfbf 76632010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
7664
7665 * c-gimplify.c: Do not include tree-flow.h
7666
202d6e5f 76672010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
7668
7669 PR other/44034
7670 * c-common.c: Rename targetm member:
7671 targetm.enum_va_list -> targetm.enum_va_list_p
7672
d3237426 76732010-06-28 Anatoly Sokolov <aesok@post.ru>
7674
7675 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
7676
596981c8 76772010-06-28 Steven Bosscher <steven@gcc.gnu.org>
7678
7679 * c-cppbuiltin.c: Do not include except.h.
7680
b9bdfa0b 76812010-06-24 Andi Kleen <ak@linux.intel.com>
7682
19931eea 7683 * c-common.c (warn_for_omitted_condop): New.
7684 * c-common.h (warn_for_omitted_condop): Add prototype.
b9bdfa0b 7685
55ad092d 76862010-06-21 Joseph Myers <joseph@codesourcery.com>
7687
7688 * c.opt (lang-objc): Remove.
7689 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
7690
9e7c2572 76912010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
7692
7693 * c-opts.c: Include "tm_p.h".
7694
615ef0bb 76952010-06-20 Joseph Myers <joseph@codesourcery.com>
7696
7697 * c-common.c (parse_optimize_options): Update call to
7698 decode_options.
7699
aef48c9a 77002010-06-18 Nathan Froyd <froydnj@codesourcery.com>
7701
7702 * c-common.c (record_types_used_by_current_var_decl): Adjust for
7703 new type of types_used_by_cur_var_decl.
7704
d74003b4 77052010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
7706
7707 PR bootstrap/44512
7708 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
7709 for C++ standard compliance.
7710
1194d077 77112010-06-16 Jason Merrill <jason@redhat.com>
7712
7713 * c.opt: Add -Wnoexcept.
7714
d473d901 77152010-06-16 Richard Guenther <rguenther@suse.de>
7716
7717 PR c/44555
7718 * c-common.c (c_common_truthvalue_conversion): Remove
7719 premature and wrong optimization concering ADDR_EXPRs.
7720
b62dbfd3 77212010-06-15 Arnaud Charlet <charlet@adacore.com>
7722
7723 * c-ada-spec.c (dump_sloc): Remove column info.
7724 (is_simple_enum): New function.
7725 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
7726 enum types when relevant.
7727
200dd99c 77282010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
7729
19931eea 7730 * c-common.c (conversion_warning): Warn at expression
200dd99c 7731 location.
7732
abf6a617 77332010-06-10 Joseph Myers <joseph@codesourcery.com>
7734
7735 * c-opts.c (c_common_handle_option): Don't handle
7736 OPT_fshow_column.
7737
ba72912a 77382010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
7739
7740 * c-pragma.c (push_alignment): Use typed GC allocation.
7741 (handle_pragma_push_options): Likewise.
7742
7743 * c-common.c (parse_optimize_options): Likewise.
7744
7745 * c-common.h (struct sorted_fields_type): Add variable_size GTY
7746 option.
7747
4aafe913 77482010-06-07 Joseph Myers <joseph@codesourcery.com>
7749
7750 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
7751 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
7752 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
7753 flag_signed_bitfields, warn_strict_null_sentinel,
7754 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
7755 flag_gen_declaration, flag_no_gnu_keywords,
7756 flag_implement_inlines, flag_implicit_templates,
7757 flag_implicit_inline_templates, flag_optional_diags,
7758 flag_elide_constructors, flag_default_inline, flag_rtti,
7759 flag_conserve_space, flag_access_control, flag_check_new,
7760 flag_new_for_scope, flag_weak, flag_working_directory,
7761 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
7762 flag_enforce_eh_specs, flag_threadsafe_statics,
7763 flag_pretty_templates): Remove.
7764 * c-common.h (flag_preprocess_only, flag_nil_receivers,
7765 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
7766 flag_replace_objc_classes, flag_undef, flag_no_builtin,
7767 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
7768 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
7769 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
7770 flag_no_gnu_keywords, flag_implement_inlines,
7771 flag_implicit_templates, flag_implicit_inline_templates,
7772 flag_optional_diags, flag_elide_constructors, flag_default_inline,
7773 flag_rtti, flag_conserve_space, flag_access_control,
7774 flag_check_new, flag_new_for_scope, flag_weak,
7775 flag_working_directory, flag_use_cxa_atexit,
7776 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
7777 flag_threadsafe_statics, flag_pretty_templates,
7778 warn_strict_null_sentinel): Remove.
7779 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
7780 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
7781 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
7782 fimplicit-inline-templates, fimplicit-templates,
7783 flax-vector-conversions, fms-extensions, fnil-receivers,
7784 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
7785 frtti, fshort-double, fshort-enums, fshort-wchar,
7786 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
7787 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
7788 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
7789 gen-decls, undef): Use Var.
7790 (fdefault-inline, foptional-diags): Document as doing nothing.
7791 * c-opts.c (c_common_handle_option): Remove cases for options now
7792 using Var. Mark ignored options as such.
7793
7bedc3a0 77942010-06-05 Steven Bosscher <steven@gcc.gnu.org>
7795
19931eea 7796 * c-common.c: Moved to here from parent directory.
7bedc3a0 7797 * c-common.def: Likewise.
7798 * c-common.h: Likewise.
7799 * c-cppbuiltin.c: Likewise.
7800 * c-dump.c: Likewise.
7801 * c-format.c: Likewise.
7802 * c-format.h : Likewise.
7803 * c-gimplify.c: Likewise.
7804 * c-lex.c: Likewise.
7805 * c-omp.c: Likewise.
7806 * c.opt: Likewise.
7807 * c-opts.c: Likewise.
7808 * c-pch.c: Likewise.
7809 * c-ppoutput.c: Likewise.
7810 * c-pragma.c: Likewise.
7811 * c-pragma.h: Likewise.
7812 * c-pretty-print.c: Likewise.
7813 * c-pretty-print.h: Likewise.
7814 * c-semantics.c: Likewise.
7815 * stub-objc.c: Likewise.
7816
7817 * c-common.c: Include gt-c-family-c-common.h.
7818 * c-pragma.c: Include gt-c-family-c-pragma.h.
7819\f
aad93da1 7820Copyright (C) 2010-2017 Free Software Foundation, Inc.
7bedc3a0 7821
7822Copying and distribution of this file, with or without modification,
7823are permitted in any medium without royalty provided the copyright
7824notice and this notice are preserved.