]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c-family/ChangeLog
i386: Add more naked attribute tests
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
CommitLineData
f4bcd9eb
EB
12017-08-01 Eric Botcazou <ebotcazou@adacore.com>
2
3 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
4 (dump_ada_function_declaration): Likewise.
5 (dump_generic_ada_node): Likewise.
6 (print_ada_declaration): Add support for const-qualified variables.
7
f34ebeb2
ML
82017-07-31 Martin Liska <mliska@suse.cz>
9
10 PR sanitize/81530
11 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
12 Guard condition with flag_sanitize_p also with current_function_decl
13 non-null equality.
14 (ubsan_maybe_instrument_reference_or_call): Likewise.
15
218e5d04
UB
162017-07-30 Uros Bizjak <ubizjak@gmail.com>
17
18 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
19
942047f2
EB
202017-07-29 Eric Botcazou <ebotcazou@adacore.com>
21
22 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
23 for enumeral types.
24 (print_ada_declaration): Add missing guard for record types.
25
a40ff0ae
JJ
262017-07-27 Jakub Jelinek <jakub@redhat.com>
27
28 PR c/45784
29 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
30 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
31 new COMPOUND_EXPRs around the rhs of the comparison.
32
06bd22f6
MP
332017-07-27 Marek Polacek <polacek@redhat.com>
34
35 PR c/81417
36 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
37 the types.
38
036ea399
JJ
392017-07-27 Jakub Jelinek <jakub@redhat.com>
40
41 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
42 (handle_noipa_attribute): New function.
43
417ca011
TD
442017-07-07 Torsten Duwe <duwe@suse.de>
45
46 * c-attribs.c (c_common_attribute_table): Add entry for
47 "patchable_function_entry".
48
5aaa8fb4
NS
492017-07-20 Nathan Sidwell <nathan@acm.org>
50
51 Remove TYPE_METHODS.
52 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
53 dump_ada_template, print_ada_methods,
54 print_ada_declaration): Member fns are on TYPE_FIELDS.
55
ff22eb12
NS
562017-07-18 Nathan Sidwell <nathan@acm.org>
57
58 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
59
eea77d1f
DM
602017-07-14 David Malcolm <dmalcolm@redhat.com>
61
62 * c-common.c (try_to_locate_new_include_insertion_point): New
63 function.
64 (per_file_includes_t): New typedef.
65 (added_includes_t): New typedef.
66 (added_includes): New variable.
67 (maybe_add_include_fixit): New function.
68 * c-common.h (maybe_add_include_fixit): New decl.
69
281ac396
MS
702017-07-10 Martin Sebor <msebor@redhat.com>
71
72 PR other/81345
73 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
74
b6f43128
DM
752017-07-06 David Malcolm <dmalcolm@redhat.com>
76
77 * c-common.c (selftest::c_family_tests): New.
78 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
79 (selftest::c_family_tests): New decl.
80
efbf55b0
MP
812017-07-04 Marek Polacek <polacek@redhat.com>
82
83 PR c/81231
84 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
85 types.
86
6c86bd88
MP
872017-07-04 Marek Polacek <polacek@redhat.com>
88
89 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
90
17a7218b
ML
912017-06-28 Martin Liska <mliska@suse.cz>
92
93 PR ipa/81128
94 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
95 to a function declaration.
96
63010089
ML
972017-06-28 Martin Liska <mliska@suse.cz>
98
99 PR driver/79659
100 * c.opt: Add IntegerRange to various options.
101
3e2becc4
MP
1022017-06-26 Marek Polacek <polacek@redhat.com>
103
104 PR c/80116
105 * c-common.h (warn_for_multistatement_macros): Declare.
106 * c-warn.c: Include "c-family/c-indentation.h".
107 (warn_for_multistatement_macros): New function.
108 * c.opt (Wmultistatement-macros): New option.
109 * c-indentation.c (guard_tinfo_to_string): No longer static.
110 Change the parameter type to "enum rid". Handle RID_SWITCH.
111 * c-indentation.h (guard_tinfo_to_string): Declare.
112
2db9b7cd
MG
1132017-06-23 Marc Glisse <marc.glisse@inria.fr>
114
115 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
116
c3684b7b
MS
1172017-06-15 Martin Sebor <msebor@redhat.com>
118
119 PR c++/80560
120 * c.opt (-Wclass-memaccess): New option.
121
e72c4afd
BK
1222017-06-14 Boris Kolpackov <boris@codesynthesis.com>
123
124 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
125
8a516588
MP
1262017-06-13 Marek Polacek <polacek@redhat.com>
127
128 PR objc/80949
129 * c-warn.c (do_warn_duplicated_branches): Return if any of the
130 branches is null.
131
45b2222a
ML
1322017-06-13 Martin Liska <mliska@suse.cz>
133
134 PR sanitize/78204
135 * c-attribs.c (add_no_sanitize_value): New function.
136 (handle_no_sanitize_attribute): Likewise.
137 (handle_no_sanitize_address_attribute): Use the function.
138 (handle_no_sanitize_thread_attribute): New function.
139 (handle_no_address_safety_analysis_attribute): Use
140 add_no_sanitize_value.
141 (handle_no_sanitize_undefined_attribute): Likewise.
142 * c-common.h: Declare new functions.
143 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
144 (ubsan_instrument_shift): Likewise.
145 (ubsan_instrument_bounds): Likewise.
146 (ubsan_maybe_instrument_array_ref): Likewise.
147 (ubsan_maybe_instrument_reference_or_call): Likewise.
148
a01f151f
JM
1492017-06-11 Jason Merrill <jason@redhat.com>
150
151 * c-ada-spec.c, c-pragma.c: Use id_equal.
152
3de4ac6d
MP
1532017-06-04 Marek Polacek <polacek@redhat.com>
154
155 PR c/80919
156 * c-format.c (matching_type_p): Return false if any of the types
157 requires structural equality.
158
2474f48f
MS
1592017-06-02 Martin Sebor <msebor@redhat.com>
160
161 PR c/80892
162 * c-warn.c (conversion_warning): Use -Wconversion for integer
163 conversion and -Wfloat-conversion for floating one.
164
40ffd95f
BE
1652017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
166
167 * c.opt (Wsizeof-pointer-div): New warning option.
168
3fa4634c
VR
1692017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
170
171 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
172 (Wcatch-value=1): Enable by -Wall.
173
f012c8ef
DM
1742017-05-30 David Malcolm <dmalcolm@redhat.com>
175
176 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
177 format_chars.
178 * c.opt (fdiagnostics-show-template-tree): New option.
179 (felide-type): New option.
180
63dbcd13
VR
1812017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
182
183 * c.opt (Wcatch-value=): New C++ warning flag.
184
be136b5c
NS
1852017-05-24 Nathan Sidwell <nathan@acm.org>
186
187 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
188 const casts to avoid warning.
189
3cd211af
MS
1902017-05-24 Martin Sebor <msebor@redhat.com>
191
192 PR c/80731
193 * c-common.h (unsafe_conversion_p): Add a function argument.
194 * c-common.c (unsafe_conversion_p): Same.
195 Add type names and values to diagnostics.
196 (scalar_to_vector): Adjust.
197 * c-warn.c (constant_expression_error): Add a function argument.
198 Add type names and values to diagnostics.
199 (conversion_warning): Add a function argument.
200 Add type names and values to diagnostics.
201 (warnings_for_convert_and_check): Same.
202
1ff7be5a
JM
2032017-05-19 Jason Merrill <jason@redhat.com>
204
205 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
206 enumerators.
207
ff502317
BE
2082017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
209
210 * c-format.c (locus): Move out of function scope,
211 add GTY attribute.
212
2a8a8d7b
NS
2132017-05-19 Nathan Sidwell <nathan@acm.org>
214
215 * c-opts.c (class_dump_file, class_dump_flags): Delete.
216 (c_common_parse_file): Remove class dump handling.
217 (get_dump_info): Likewise.
218
39aac208
RB
2192017-05-19 Richard Biener <rguenther@suse.de>
220
221 PR c++/80593
222 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
223 to alias-set zero memory.
224
6ecd2339
BE
2252017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
226
227 * c-format.c (local_tree_type_node): Add GTY attribute.
228
6574d78e
MP
2292017-05-18 Marek Polacek <polacek@redhat.com>
230
231 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
232 (c_common_fixed_point_type_for_size): Likewise.
233 (c_common_type_for_mode): Likewise.
234 (shorten_compare): Likewise.
235 (c_promoting_integer_type_p): Use false/true instead of 0/1.
236 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
237
e3455240
MP
2382017-05-18 Marek Polacek <polacek@redhat.com>
239
240 * c-common.c (self_promoting_args_p): Change the return type to bool.
241 Use false/true instead of 0/1.
242 * c-common.h (self_promoting_args_p): Update.
243
3fa8871b
MP
2442017-05-17 Marek Polacek <polacek@redhat.com>
245
246 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
247 * c-warn.c: Likewise.
248
b42cc3ca
VV
2492017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
250
251 Implement new C++ intrinsics __is_assignable and __is_constructible.
252 * c-common.c (__is_assignable, __is_constructible): New.
253 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
254
1a817418
ML
2552017-05-17 Martin Liska <mliska@suse.cz>
256
257 * c-common.h: Introduce dump_flags_t type and
258 use it instead of int type.
259 * c-gimplify.c (c_genericize): Likewise.
260 * c-opts.c: Likewise.
261
b2fa0a8b
MP
2622017-05-17 Marek Polacek <polacek@redhat.com>
263
264 * c-common.c (c_save_expr): Remove.
265 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
266 * c-common.h (c_save_expr): Remove declaration.
267
31c2d57d
VR
2682017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
269
270 PR c/35441
271 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
272 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
273 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
274 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
275 RDIV_EXPR.
276 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
277
684f84de
MP
2782017-05-09 Marek Polacek <polacek@redhat.com>
279
280 PR c/80525
281 * c-warn.c (unwrap_c_maybe_const): New.
282 (warn_logical_operator): Call it.
283
641da50a
NS
2842017-05-09 Nathan Sidwell <nathan@acm.org>
285
286 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
287 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
288
631238ac
MS
2892017-05-08 Martin Sebor <msebor@redhat.com>
290
291 PR translation/80280
292 * c-format.h (struct format_flag_spec): Add new member.
293 (T89_T): New macro.
294 * c-format.c (local_tree_type_node): New global.
295 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
296 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
297 (strfmon_flag_specs): Likewise.
298 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
299 with distinct quoting properties.
300 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
301 (flag_chars_t::validate): Add argument and handle bad quoting.
302 (check_format_info_main): Handle quoting problems.
303 (init_dynamic_diag_info): Simplify.
304
49f0c04c
JM
3052017-05-08 Jason Merrill <jason@redhat.com>
306
307 * c-opts.c (c_common_post_options): Update defaults for
308 flag_abi_version and flag_abi_compat_version.
309
56d35585
DM
3102017-05-05 David Malcolm <dmalcolm@redhat.com>
311
312 * c-common.c (c_cpp_error): Replace report_diagnostic
313 with diagnostic_report_diagnostic.
314
0f2c4a8f
MS
3152017-05-04 Martin Sebor <msebor@redhat.com>
316
317 PR translation/80280
318 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
319 (handle_weakref_attribute): Same.
320
6fe63fb4
NS
3212017-05-03 Nathan Sidwell <nathan@acm.org>
322
323 Canonicalize canonical type hashing
324 * c-common.c (complete_array_type): Use type_hash_canon.
325
815d9cc6
XR
3262017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
327
328 PR c++/80038
329 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
330 prototype.
331 (cilk_install_body_pedigree_operations): Likewise.
332 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
333 detatched.
334 (cilk_gimplify_call_params_in_spawned_fn): Remove.
335 (cilk_install_body_pedigree_operations): Likewise.
336 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
337 unwrapping.
338
f8a36447
JJ
3392017-04-27 Jakub Jelinek <jakub@redhat.com>
340
341 PR c++/80534
342 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
343 flag on non-aggregate element types.
344
7c145456
BE
3452017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
346
347 * c-common.c (c_type_hasher, type_hash_table): Remove.
348 (c_common_get_alias_set): Remove unreachable code.
349 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
350
c3cbcd45
VR
3512017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
352
353 * c.opt (Wextra-semi): New C++ warning flag.
354
8a59d466
JJ
3552017-04-20 Jakub Jelinek <jakub@redhat.com>
356
357 PR middle-end/80423
358 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
359
8487c9a5
JJ
3602017-04-18 Jakub Jelinek <jakub@redhat.com>
361
362 PR middle-end/79788
363 PR middle-end/80375
364 * c-common.c (c_common_type_for_mode): Don't handle
365 widest_*_literal_type_node here.
366 c_common_signed_or_unsigned_type): Likewise.
367 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
368 to *intTI_type_node or *intDI_type_node depending on whether
369 TImode is supported by the target or not.
370
3ee0fb02
ML
3712017-04-10 Martin Liska <mliska@suse.cz>
372
373 PR sanitizer/80350
374 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
375 doing an UBSAN check.
376
5764ee3c
JW
3772017-04-03 Jonathan Wakely <jwakely@redhat.com>
378
379 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
380
6f3af356
JJ
3812017-03-31 Jakub Jelinek <jakub@redhat.com>
382
383 PR c++/79572
384 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
385 tree *.
386 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
387 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
388 REFERENCE_TYPE.
389
f6a7a9d5
DM
3902017-03-31 David Malcolm <dmalcolm@redhat.com>
391
392 PR documentation/78732
393 * c.opt (Wendif-labels): Fix description to refer to
394 #else rather than #elif.
395
af88f557
JJ
3962017-03-31 Jakub Jelinek <jakub@redhat.com>
397
398 PR libstdc++/80251
399 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
400 * c-common.c (c_common_reswords): Add __is_aggregate trait.
401
a9e4a1a5
JJ
4022017-03-27 Jakub Jelinek <jakub@redhat.com>
403
404 PR middle-end/80162
405 * c-common.c (c_common_mark_addressable_vec): Don't set
406 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
407
3f01b620
MS
4082017-03-21 Martin Sebor <msebor@redhat.com>
409
410 PR c++/79548
411 * c-common.c (set_underlying_type): Mark type used only when
412 original del is declared unused.
413
2f6f187a
DM
4142017-03-10 David Malcolm <dmalcolm@redhat.com>
415
416 PR translation/79848
417 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
418 "%qs".
419
a02fa805
DM
4202017-03-10 David Malcolm <dmalcolm@redhat.com>
421
422 PR c/79921
423 * c-indentation.c (warn_for_misleading_indentation): Remove parens
424 from inform's message, so that xgettext can locate it.
425
822a132c
MP
4262017-03-09 Marek Polacek <polacek@redhat.com>
427
428 PR c++/79962
429 PR c++/79984
430 * c-attribs.c (handle_nonnull_attribute): Save the result of default
431 conversion to the attribute list.
432
bba81f1c
ML
4332017-03-09 Martin Liska <mliska@suse.cz>
434
435 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
436
108154ff
JM
4372017-03-03 Jason Merrill <jason@redhat.com>
438
439 * c.opt (Wnoexcept-type): New.
440
eb0e7c34
RB
4412017-03-02 Richard Biener <rguenther@suse.de>
442
443 PR c/79756
444 * c-common.c (c_common_mark_addressable_vec): Look through
445 C_MAYBE_CONST_EXPR.
446
9453ba0a
ML
4472017-02-28 Martin Liska <mliska@suse.cz>
448
449 * c.opt: Replace space with tabular for options of <number>
450 type.
451
6a825afe
ML
4522017-02-28 Martin Liska <mliska@suse.cz>
453
454 * c.opt: Fix --help=option -Q for options which are of
455 an enum type.
456
4227c9ad
JJ
4572017-02-24 Jakub Jelinek <jakub@redhat.com>
458
459 PR c++/79588
460 * c-common.c (check_function_restrict): New function.
461 (check_function_arguments): Add FNDECL argument. Call
462 check_function_restrict if -Wrestrict.
463 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
464 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
465 * c-common.h (check_function_arguments): Add FNDECL argument.
466 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
467
59909673
EB
4682017-02-24 Eric Botcazou <ebotcazou@adacore.com>
469
470 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
471 treatment of parameters with pointer-to-tagged type and tidy up.
472 (print_ada_methods): Remove the special treatment of C++ static member
473 functions.
474
54dcd526
ML
4752017-02-22 Martin Liska <mliska@suse.cz>
476
477 * c.opt: Replace inequality signs with square brackets
478 for -Wnornalized.
479
00bc9de3
JJ
4802017-02-21 Jakub Jelinek <jakub@redhat.com>
481
482 PR c++/79641
483 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
484 preserve quals.
485
97fcf744
JM
4862017-02-17 Joseph Myers <joseph@codesourcery.com>
487
488 * c-cppbuiltin.c (builtin_define_float_constants): Define
489 __DECIMAL_DIG__ to the value for long double.
490
c7545f1c
MP
4912017-02-15 Marek Polacek <polacek@redhat.com>
492
493 PR c/79515
494 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
495 conversion has occured.
496
c2e84327
DM
4972017-01-24 David Malcolm <dmalcolm@redhat.com>
498
499 * c-common.c (c_common_reswords): Add "__RTL".
500 * c-common.h (enum rid): Add RID_RTL.
501
2ebd93e1
MP
5022017-01-20 Marek Polacek <polacek@redhat.com>
503
504 PR c/64279
505 * c-common.h (do_warn_duplicated_branches_r): Declare.
506 * c-gimplify.c (c_genericize): Walk the function tree calling
507 do_warn_duplicated_branches_r.
508 * c-warn.c (expr_from_macro_expansion_r): New.
509 (do_warn_duplicated_branches): New.
510 (do_warn_duplicated_branches_r): New.
511 * c.opt (Wduplicated-branches): New option.
512
0d80ab91
DM
5132017-01-17 David Malcolm <dmalcolm@redhat.com>
514
515 PR c++/71497
516 * c-indentation.c (warn_for_misleading_indentation): Use the past
517 subjunctive in the note.
518
7f991c36
AH
5192017-01-17 Aldy Hernandez <aldyh@redhat.com>
520
521 PR c/79116
522 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
523 start type to integer_type.
524
1c70261c
JJ
5252017-01-16 Jakub Jelinek <jakub@redhat.com>
526
527 PR driver/49726
528 * c.opt (gen-decls): Add Driver flag.
529
1ddca3f3
PC
5302017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
531
532 Revert:
533 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
534
535 PR c++/71737
536 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
537
7d2f3f1d
PC
5382017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
539
540 PR c++/71737
541 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
542
bce6f760
MS
5432017-01-12 Martin Sebor <msebor@redhat.com>
544
545 (-Wformat-overflow): ...to this.
546
bf5fbf46
MS
5472017-01-11 Martin Sebor <msebor@redhat.com>
548
549 PR c/78768
550 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
551 Also enable for LTO.
552
e363df3f
JM
5532017-01-10 Jason Merrill <jason@redhat.com>
554
555 Implement P0195R2, C++17 variadic using.
556 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
557
bd2c6270
JJ
5582017-01-09 Jakub Jelinek <jakub@redhat.com>
559
560 PR translation/79019
561 PR translation/79020
562 * c.opt (Wnormalized=): Fix typo in description.
563
efcc8d38
MS
5642017-01-08 Martin Sebor <msebor@redhat.com>
565
566 PR middle-end/77708
567 * c.opt (-Wformat-truncation): New option.
568
435f3f7a
AO
5692017-01-06 Alexandre Oliva <aoliva@redhat.com>
570
571 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
572 value to unsigned short to fit in 4 hex digits without
573 warnings.
574
4e89adf9
EB
5752017-01-05 Eric Botcazou <ebotcazou@adacore.com>
576
577 * c.opt (fsso-struct): Add 'native' value.
578
cd445b54
ML
5792017-01-05 Martin Liska <mliska@suse.cz>
580
581 PR pch/78970
582 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
583 header.
584
a9342885
MP
5852017-01-04 Marek Polacek <polacek@redhat.com>
586
587 PR c++/64767
588 * c.opt (Wpointer-compare): New option.
589
fc73e60c
JJ
5902017-01-04 Jakub Jelinek <jakub@redhat.com>
591
592 PR driver/78957
593 * c.opt (fsso-struct=): Add RejectNegative.
594
cbe34bb5
JJ
5952017-01-01 Jakub Jelinek <jakub@redhat.com>
596
597 Update copyright years.
598
d4a6c0ea
ML
5992016-12-29 Martin Liska <mliska@suse.cz>
600
601 PR c/78933
602 * c.opt (strong-eval-order): Add RejectNegative keyword.
603
67a5ad7c
JM
6042016-12-22 Jason Merrill <jason@redhat.com>
605
606 Implement P0522R0, matching of template template arguments.
607 * c-cppbuiltin.c (c_cpp_builtins): Define
608 __cpp_template_template_args.
609
0dba7960
JJ
6102016-12-21 Jakub Jelinek <jakub@redhat.com>
611
612 PR bootstrap/78817
613 * c-common.c (struct nonnull_arg_ctx): New type.
614 (check_function_nonnull): Return bool instead of void. Use
615 nonnull_arg_ctx as context rather than just location_t.
616 (check_nonnull_arg): Adjust for the new context type, set
617 warned_p to true if a warning has been diagnosed.
618 (check_function_arguments): Return bool instead of void.
619 * c-common.h (check_function_arguments): Adjust prototype.
620
31bfc9b9
JM
6212016-12-21 Jason Merrill <jason@redhat.com>
622
623 * c.opt (-fnew-ttp-matching): New flag.
624 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
625
629b3d75
MJ
6262016-12-14 Martin Jambor <mjambor@suse.cz>
627
628 * c-omp.c: Include omp-general.h instead of omp-low.h.
629 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
630 name.
631
474da67e
MS
6322016-12-14 Martin Sebor <msebor@redhat.com>
633
634 PR c/17308
635 * c-common.c (check_nonnull_arg): Disable when optimization
636 is enabled.
637
fe366b87
MP
6382016-12-12 Marek Polacek <polacek@redhat.com>
639
640 PR c++/78647
641 * c-common.c (attribute_fallthrough_p): Return false for
642 error_mark_node.
643
8bd9f164
MS
6442016-12-08 Martin Sebor <msebor@redhat.com>
645
646 PR c/78284
647 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
648
060162e0
MS
6492016-12-08 Martin Sebor <msebor@redhat.com>
650
651 PR c/78165
1d0cf89a
MS
652 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
653 suffix.
060162e0 654
ee92e7ba
MS
6552016-12-07 Martin Sebor <msebor@redhat.com>
656
657 PR c/53562
658 PR middle-end/77784
659 PR middle-end/78149
660 PR middle-end/78138
661 * c.opt (-Wstringop-overflow): New option.
662
84b0769e
MO
6632016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
664
665 * c-attribs.c (asan odr indicator): New attribute.
666 (handle_asan_odr_indicator_attribute): New function.
667
7fa6a965
PK
6682016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
669
670 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
671 ptrdiff_type_node;
672
56d8ffc1
JG
6732016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
674
675 * c-common.c (excess_precision_mode_join): New.
676 (c_ts18661_flt_eval_method): New.
677 (c_c11_flt_eval_method): Likewise.
678 (c_flt_eval_method): Likewise.
679 * c-common.h (excess_precision_mode_join): New.
680 (c_flt_eval_method): Likewise.
681 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
682 (cpp_iec_559_value): Call it.
683 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
684 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
685 __FLT_EVAL_METHOD_TS_18661_3__.
686
04f0fcf7
JG
6872016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
688
689 * c-opts.c (c_common_post_options): Add logic to handle the default
690 case for -fpermitted-flt-eval-methods.
691
fb2675cb
PB
6922016-11-23 Paolo Bonzini <bonzini@gnu.org>
693
694 * c.opt (Wexpansion-to-defined): New.
695
ec1c5694
JJ
6962016-11-23 Jakub Jelinek <jakub@redhat.com>
697
698 PR target/78451
699 * c-pragma.c (handle_pragma_target): Don't replace
700 current_target_pragma, but chainon the new args to the current one.
701
730c9e75
NS
7022016-11-22 Nathan Sidwell <nathan@acm.org>
703
704 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
cacd29be 705 indentation and formatting.
730c9e75 706
89990732
MS
7072016-11-21 Martin Sebor <msebor@redhat.com>
708
709 * c.opt (-fprintf-return-value): Enable by default.
710
48330c93
BE
7112016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
712
713 PR c++/71973
714 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
715 * c-common.c (c_common_nodes_and_builtins): Initialize
716 const_tm_ptr_type_node.
717
0d939c95
MP
7182016-11-16 Marek Polacek <polacek@redhat.com>
719
720 PR c/78285
721 * c-common.c (c_add_case_label): Turn error_at calls into inform.
722
8e745a17
JJ
7232016-11-14 Jakub Jelinek <jakub@redhat.com>
724
725 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
726
1ee62b92 7272016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
8e745a17
JJ
728 Richard Biener <rguenther@suse.de>
729
730 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
731 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
732 * c.opt (fgimple): New option.
1ee62b92 733
22b15758
UB
7342016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
735
736 PR c/35503
737 * c-common.h (warn_for_restrict): Declare.
738 * c-warn.c: Include gcc-rich-location.h.
739 (warn_for_restrict): New function.
740 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
741 (gcc_cdiag_char_table): Likewise.
742 (gcc_cxxdiag_char_table): Likewise.
743 * c.opt (Wrestrict): New option.
744
4be719cd
EB
7452016-11-13 Eric Botcazou <ebotcazou@adacore.com>
746
747 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
748 for nested types only if the type is a record or union and dump SLOC.
749
4a826ca6
JM
7502016-11-09 Jason Merrill <jason@redhat.com>
751
752 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
753
2e955d50
JJ
7542016-11-09 Jakub Jelinek <jakub@redhat.com>
755
756 * c-ubsan.c (ubsan_instrument_shift): Handle split
757 -fsanitize=shift-base and -fsanitize=shift-exponent.
758
51dc6603
JM
7592016-11-07 Jason Merrill <jason@redhat.com>
760
761 * c.opt (Wc++1z-compat): New.
762 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
763
6dc4a604
ML
7642016-11-07 Martin Liska <mliska@suse.cz>
765
766 * c-warn.c (warn_for_unused_label): Save all labels used
767 in goto or in &label.
768
b302001e
JM
7692016-11-03 Jason Merrill <jason@redhat.com>
770
771 * c-cppbuiltin.c (c_cpp_builtins): Correct
772 __cpp_inheriting_constructors.
773
31f7f784
JM
7742016-11-01 Jason Merrill <jason@redhat.com>
775
2bc78e3c
JM
776 * c-cppbuiltin.c (c_cpp_builtins): Update
777 __cpp_inheriting_constructors.
778
31f7f784
JM
779 * c.opt (-fnew-inheriting-ctors): New.
780 * c-opts.c: Default to on for ABI 11+.
781
dcb466ec
JJ
7822016-10-31 Jakub Jelinek <jakub@redhat.com>
783
784 PR c++/77948
785 * c.opt (fext-numeric-literals): Add Var and Init.
786 * c-opts.c (c_common_handle_option): Don't clear
787 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
788 (c_common_post_options): Clear it here if not set
789 explicitly.
790
52e1b91e
AH
7912016-10-28 Aldy Hernandez <aldyh@redhat.com>
792
793 PR debug/77773
794 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
795 if NULL.
796
e16f1cc7
JJ
7972016-10-25 Jakub Jelinek <jakub@redhat.com>
798
799 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
800 * c-common.c (c_common_reswords): Add __builtin_launder.
801
f8348061
BE
8022016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
803
804 * c-common.c (c_common_truthvalue_conversion): Warn for
805 multiplications in boolean context. Fix the quoting of '<<' and '<'
806 in the shift warning.
807
eff89e01
BE
8082016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
809
810 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
811
24bc7bf4
JM
8122016-10-20 Jason Merrill <jason@redhat.com>
813
814 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
815
4c712374
BE
8162016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
817
818 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
819 integer shift ops in boolean context.
820
8212016-10-18 Aldy Hernandez <aldyh@redhat.com>
adc577c5
AH
822
823 * c.opt (Walloca): New.
824 (Walloca-larger-than=): New.
825 (Wvla-larger-than=): New.
826
8fa18c06
MP
8272016-10-17 Marek Polacek <polacek@redhat.com>
828
829 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
830 Return immediately when finding a match.
831 (warn_tautological_cmp): Remove a boolean variable that is no longer
832 needed.
833
b12b1915
MP
8342016-10-17 Marek Polacek <polacek@redhat.com>
835
836 * c-attribs.c: New file.
837 * c-common.c: Move attributes handling to c-attribs.c.
838 (get_nonnull_operand): No longer static.
839 * c-common.h: Move the declarations from c-attribs.c to its own section.
840
2045acd9
JM
8412016-10-14 Jason Merrill <jason@redhat.com>
842
843 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
844 and __cpp_deduction_guides.
845
14a2c9aa
JM
8462016-10-13 Jason Merrill <jason@redhat.com>
847
848 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
849
4d0cdd0c
TP
8502016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
851
852 * c-cppbuiltin.c: Include memmodel.h.
853 * c-opts.c: Likewise.
854 * c-pragma.c: Likewise.
855 * c-warn.c: Likewise.
856
70f6d5e1
JJ
8572016-10-12 Jakub Jelinek <jakub@redhat.com>
858
859 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
860 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
861 * c-opts.c (sanitize_cpp_opts): Initialize
862 cpp_opts->cpp_warn_implicit_fallthrough.
863
78f61294
MP
8642016-10-11 Marek Polacek <polacek@redhat.com>
865
866 * c-common.c (warning_candidate_p): Change the return type to bool
867 and return true/false instead of 1/0.
868 (vector_mode_valid_p): Likewise.
869
038b5cc0
MP
8702016-10-11 Marek Polacek <polacek@redhat.com>
871
872 * c-common.c (fold_for_warn): No longer static.
873 (bool_promoted_to_int_p): Likewise.
874 (c_common_get_narrower): Likewise.
875 (constant_expression_warning): Move to c-warn.c.
876 (constant_expression_error): Likewise.
877 (overflow_warning): Likewise.
878 (warn_logical_operator): Likewise.
879 (find_array_ref_with_const_idx_r): Likewise.
880 (warn_tautological_cmp): Likewise.
881 (expr_has_boolean_operands_p): Likewise.
882 (warn_logical_not_parentheses): Likewise.
883 (warn_if_unused_value): Likewise.
884 (strict_aliasing_warning): Likewise.
885 (sizeof_pointer_memaccess_warning): Likewise.
886 (check_main_parameter_types): Likewise.
887 (conversion_warning): Likewise.
888 (warnings_for_convert_and_check): Likewise.
889 (match_case_to_enum_1): Likewise.
890 (match_case_to_enum): Likewise.
891 (c_do_switch_warnings): Likewise.
892 (warn_for_omitted_condop): Likewise.
893 (readonly_error): Likewise.
894 (lvalue_error): Likewise.
895 (invalid_indirection_error): Likewise.
896 (warn_array_subscript_with_type_char): Likewise.
897 (warn_about_parentheses): Likewise.
898 (warn_for_unused_label): Likewise.
899 (warn_for_div_by_zero): Likewise.
900 (warn_for_memset): Likewise.
901 (warn_for_sign_compare): Likewise.
902 (do_warn_double_promotion): Likewise.
903 (do_warn_unused_parameter): Likewise.
904 (record_locally_defined_typedef): Likewise.
905 (maybe_record_typedef_use): Likewise.
906 (maybe_warn_unused_local_typedefs): Likewise.
907 (maybe_warn_bool_compare): Likewise.
908 (maybe_warn_shift_overflow): Likewise.
909 (warn_duplicated_cond_add_or_warn): Likewise.
910 (diagnose_mismatched_attributes): Likewise.
911 * c-common.h: Move the declarations from c-warn.c to its own section.
912 * c-warn.c: New file.
913
627be19f
JM
9142016-10-08 Jason Merrill <jason@redhat.com>
915
916 * c-common.c (c_common_truthvalue_conversion): Don't distribute
917 into COND_EXPR in C++.
918
7bad794a
JJ
9192016-10-08 Jakub Jelinek <jakub@redhat.com>
920
921 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
922 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
923 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
924
be845b04
JJ
9252016-10-07 Jakub Jelinek <jakub@redhat.com>
926
927 Implement LWG2296 helper intrinsic
928 * c-common.h (enum rid): Add RID_ADDRESSOF.
929 * c-common.c (c_common_reswords): Add __builtin_addressof.
930
c09c4992
BE
9312016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
932
933 PR c++/77700
934 * c-common.c (c_common_truthvalue_conversion): Warn also for
935 suspicious enum values in boolean context.
936
342cfb3e
JJ
9372016-10-06 Jakub Jelinek <jakub@redhat.com>
938
939 Implement P0258R2 - helper for C++17
940 std::has_unique_object_representations trait
941 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
942 * c-common.c (c_common_reswords): Add
943 __has_unique_object_representations.
944
2e69f143
JJ
9452016-10-05 Jakub Jelinek <jakub@redhat.com>
946
947 PR sanitizer/66343
948 * c-ubsan.c (ubsan_instrument_return): Don't call
949 initialize_sanitizer_builtins here.
950
700fff34
BE
9512016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
952
953 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
954 conditional expression in boolean context when only one arm is
955 non-boolean.
956
9563bfcd
JJ
9572016-10-05 Jakub Jelinek <jakub@redhat.com>
958
04a32443
JJ
959 PR sanitizer/77823
960 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
961 is not integral.
962
9563bfcd
JJ
963 * c-common.c (c_common_reswords): Update comment for C++11.
964
f1644724
JM
9652016-10-04 Jason Merrill <jason@redhat.com>
966
967 * c-common.c (make_tree_vector_from_ctor): New.
968 * c-common.h: Declare it.
969
5a79befb
JJ
9702016-10-04 Jakub Jelinek <jakub@redhat.com>
971
972 * c-cppbuiltin.c (c_cpp_builtins): Don't define
973 __LIBGCC_JCR_SECTION_NAME__.
974
1633d3b9
BE
9752016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
976
977 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
978 left shift in boolean context.
979
a2c6e7f2
JJ
9802016-09-29 Jakub Jelinek <jakub@redhat.com>
981
982 Implement P0001R1 - C++17 removal of register storage class specifier
983 * c.opt (Wregister): New warning.
984 * c-opts.c (c_common_post_options): Enable -Wregister by
985 default for C++17.
986
75304c87
JG
9872016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
988
989 * c-opts.c (c_common_post_options): Remove special case for
990 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
991 in C++.
992
bbfac6da
JJ
9932016-09-27 Jakub Jelinek <jakub@redhat.com>
994
6e39060a
JJ
995 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
996 -std=c++1z.
997
bbfac6da
JJ
998 * c-ada-spec.c (print_ada_declaration): Remove break after return.
999
e73cf9a2
TP
10002016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
1001
1002 * c-common.c: Include memmodel.h.
1003
c6147dc4
MP
10042016-09-26 Marek Polacek <polacek@redhat.com>
1005
1006 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
1007
81fea426
MP
10082016-09-26 Marek Polacek <polacek@redhat.com>
1009
1010 PR c/7652
1011 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
1012 (handle_fallthrough_attribute): New function.
1013 (attribute_fallthrough_p): New function.
1014 * c-common.h (attribute_fallthrough_p): Declare.
1015
9a2300e9
MP
10162016-09-24 Marek Polacek <polacek@redhat.com>
1017
1018 PR c/77490
1019 * c.opt (Wbool-operation): New.
1020
a09e9e35
BE
10212016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
1022
1023 * c-common.c (c_common_truthvalue_conversion): Inhibit
1024 Wint-in-bool-context warning with from_macro_definition_at.
1025 Mention the expression will always evaluate to true.
1026
d43b4ccc
MS
10272016-09-21 Martin Sebor <msebor@redhat.com>
1028
1029 PR bootstrap/77676
1030 * c.opt (fprintf-return-value): Temporarily initialize to zero
1031 to unblock bootstrap failures.
1032
2e1c20b1
JJ
10332016-09-21 Jakub Jelinek <jakub@redhat.com>
1034
1035 PR c++/77651
1036 * c.opt (Waligned-new=): Add RejectNegative.
1037 (faligned-new=): Likewise. Spelling fix - change
1038 aligned_new_threshhold to aligned_new_threshold.
1039 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
1040 to aligned_new_threshold.
1041
88d0c3f0
MS
10422016-09-20 Martin Sebor <msebor@redhat.com>
1043
1044 PR middle-end/49905
1045 * c.opt: Add -Wformat-length and -fprintf-return-value.
1046
144a96e4
BE
10472016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
1048
1049 PR c++/77434
1050 * c.opt (Wint-in-bool-context): New warning.
1051 * c-common.c (c_common_truthvalue_conversion): Warn on integer
1052 constants in boolean context.
1053
63012d9a
JM
10542016-09-19 Joseph Myers <joseph@codesourcery.com>
1055
1056 * c-common.c (max_align_t_align): Also consider alignment of
1057 float128_type_node.
1058
931388ce
JM
10592016-09-15 Jason Merrill <jason@redhat.com>
1060
1061 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
1062 DECL_EXTERNAL.
1063
38711381
JM
10642016-09-14 Jason Merrill <jason@redhat.com>
1065
1066 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
1067 limit FIELD_DECL, either.
1068
e51fbec3
MP
10692016-09-14 Marek Polacek <polacek@redhat.com>
1070
1071 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
1072 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
1073 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
1074
254830ba
DM
10752016-09-13 David Malcolm <dmalcolm@redhat.com>
1076
1077 * c-common.c (warn_logical_not_parentheses): Replace
1078 rich_location::add_fixit_insert calls with add_fixit_insert_before
1079 and add_fixit_insert_after, eliminating the "next_loc" calculation.
1080
42763690
JM
10812016-09-13 Jason Merrill <jason@redhat.com>
1082 Tom de Vries <tom@codesourcery.com>
1083
1084 PR c++/77427
1085 * c-common.c (set_underlying_type): Don't treat array as builtin type.
1086
9453eee9
JM
10872016-09-13 Jason Merrill <jason@redhat.com>
1088
1089 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
1090 limit types at all.
1091
e96809e3
JM
10922016-09-12 Jason Merrill <jason@redhat.com>
1093
1094 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
1095 bit/byte confusion, allow large alignment for types.
1096
54dcdb88
BE
10972016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
1098
1099 PR c++/77496
1100 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
1101
d1463eb9
DM
11022016-09-12 David Malcolm <dmalcolm@redhat.com>
1103
1104 PR c/72858
1105 * c-format.c (argument_parser::check_argument_type): Add params
1106 "type_start" and "conversion_char". Use the former to generate
1107 offset_to_type_start and pass it and conversion_char to
1108 check_format_types.
1109 (check_format_info_main): Capture the start of the type
1110 information as "type_start", and pass it an format_char
1111 to arg_parser.check_argument_type.
1112 (check_format_types): Provide an example in the leading comment.
1113 Add params "offset_to_type_start" and "conversion_char"; pass
1114 them to format_type_warning calls.
1115 (test_get_modifier_for_format_len): Likewise.
1116 (matching_type_p): New function.
1117 (get_format_for_type): Add param "conversion_char" and move
1118 implementation into...
1119 (get_format_for_type_1): ...new function, called twice.
1120 Use new function matching_type_p rather than checking for
1121 TYPE_CANONICAL equality.
1122 (get_corrected_substring): New function.
1123 (format_type_warning): Provide an example in the leading comment.
1124 Add params "offset_to_type_start" and "conversion_char". Replace
1125 call to get_format_for_type with call to get_corrected_substring
1126 and move rejection of hints for widths/precisions there.
1127 (assert_format_for_type_streq): Add param "conversion_char".
1128 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
1129 (test_get_format_for_type_printf): Add conversion chars to the
1130 tests, adding coverage for various combinations of integer
1131 vs double conversions, and for preserving octal and hexadecimal
1132 conversions.
1133 (test_get_format_for_type_scanf): Add conversion chars to the
1134 tests.
1135
5b28efbb
TV
11362016-09-10 Tom de Vries <tom@codesourcery.com>
1137
1138 PR C/71602
1139 * c-common.c (build_va_arg): Handle more strict
1140 targetm.canonical_va_list_type. Replace first argument type error with
1141 assert.
1142
3f0177e7
MS
11432016-09-09 Martin Sebor <msebor@redhat.com>
1144
1145 PR c/77520
1146 PR c/77521
1147 * c-format.c (argument_parser::find_format_char_info): Use %qc
1148 format directive unconditionally.
1149
af63ba4b
JM
11502016-09-09 Jason Merrill <jason@redhat.com>
1151
1152 Implement C++17 new of over-aligned types.
1153 * c.opt: Add -faligned-new and -Waligned-new.
1154 * c-common.c (max_align_t_align): Split out from...
1155 (cxx_fundamental_alignment_p): ...here.
1156 * c-common.h: Declare it.
1157 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
1158
c65248cb
JM
11592016-09-09 Joseph Myers <joseph@codesourcery.com>
1160
1161 * c-cppbuiltin.c (builtin_define_type_width): New function.
1162 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
1163 macros.
1164
e5106e27
DM
11652016-09-07 David Malcolm <dmalcolm@redhat.com>
1166
1167 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
1168 a POINTER_TYPE.
1169 (substring_loc::get_location): Move to substring-locations.c,
1170 keeping implementation as...
1171 (c_get_substring_location): New function, from the above, reworked
1172 to use accessors rather than member lookup.
1173 * c-common.h (class substring_loc): Move to substring-locations.h,
1174 replacing with a forward decl.
1175 (c_get_substring_location): New decl.
1176 * c-format.c: Include "substring-locations.h".
1177 (format_warning_va): Move to substring-locations.c.
1178 (format_warning_at_substring): Likewise.
1179
a42e7952
MS
11802016-09-06 Martin Sebor <msebor@redhat.com>
1181
1182 PR c/77336
1183 * c-format.c (check_function_format): Avoid issuing warnings for
1184 functions unless they call format functions with non-constant
1185 format strings.
1186
b772a565
RB
11872016-09-06 Richard Biener <rguenther@suse.de>
1188
1189 PR c/77450
1190 * c-common.c (c_common_mark_addressable_vec): Handle
1191 COMPOUND_LITERAL_EXPR.
1192
25ff5dd3
MP
11932016-09-05 Marek Polacek <polacek@redhat.com>
1194
1195 PR c/77423
1196 * c-common.c (bool_promoted_to_int_p): New function.
1197 (expr_has_boolean_operands_p): New function.
1198 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
1199 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
1200
21234eb5
TV
12012016-09-04 Tom de Vries <tom@codesourcery.com>
1202
1203 revert:
1204 2016-08-29 Tom de Vries <tom@codesourcery.com>
1205
1206 * c-common.c (build_va_arg): Replace first argument type error
1207 with assert.
1208
9dc5773f
JJ
12092016-09-02 Jakub Jelinek <jakub@redhat.com>
1210
1211 PR c/65467
1212 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
1213 (c_finish_omp_for): Reject _Atomic qualified iterators.
1214
12152016-09-01 Martin Sebor <msebor@redhat.com>
3d7b83b6
MS
1216
1217 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
1218 size to guarantee it fits the output of the formatted function
1219 regardless of its arguments.
1220
295844f6
MP
12212016-09-01 Marek Polacek <polacek@redhat.com>
1222
1223 PR c/7652
1224 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
1225 FALLTHRU comments.
1226
3d06b6f2
MP
12272016-08-29 Marek Polacek <polacek@redhat.com>
1228
1229 PR c/77292
1230 * c-common.c (warn_logical_not_parentheses): Don't warn for
1231 a comparison or a logical operator.
1232
34cedad5
TV
12332016-08-29 Tom de Vries <tom@codesourcery.com>
1234
1235 * c-common.c (build_va_arg): Fix type comparison assert.
1236
f162d717
TV
12372016-08-29 Tom de Vries <tom@codesourcery.com>
1238
1239 * c-common.c (build_va_arg): Replace first argument type error
1240 with assert.
1241
ba9bbd6f
TV
12422016-08-29 Tom de Vries <tom@codesourcery.com>
1243
1244 PR c/77398
1245 * c-common.c (build_va_arg): Add first argument error. Build va_arg
1246 with error_mark_node as va_list instead of with illegal va_list.
1247
ebef225f
MP
12482016-08-25 Marek Polacek <polacek@redhat.com>
1249 David Malcolm <dmalcolm@redhat.com>
1250
1251 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
1252 * c-common.h (warn_logical_not_parentheses): Update declaration.
1253
b00e6e75
MP
12542016-08-22 Marek Polacek <polacek@redhat.com>
1255
1256 PR c++/77321
1257 * c-common.c (warn_for_memset): Check type for null.
1258
6dc198e3
JM
12592016-08-22 Joseph Myers <joseph@codesourcery.com>
1260
1261 * c-family/c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
1262 _FloatNx types for suffixes for built-in functions.
1263
c65699ef
JM
12642016-08-19 Joseph Myers <joseph@codesourcery.com>
1265
1266 PR c/32187
1267 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
1268 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
1269 (RID_FLOAT128X): New enum rid values.
1270 (CASE_RID_FLOATN_NX): New macro.
1271 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
1272 keywords.
1273 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
1274 corresponding complex types.
1275 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
1276 _FloatNx and corresponding complex types.
1277 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
1278 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
1279 and _FloatNx types for the widest type for determining
1280 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
1281 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
1282 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
1283 and _FloatNx types.
1284 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
1285 constants.
1286 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
1287 _FloatNx types.
1288
cc015f3a
DM
12892016-08-18 David Malcolm <dmalcolm@redhat.com>
1290
1291 * c-opts.c (c_diagnostic_finalizer): Update for change to
1292 diagnostic_show_locus.
1293
cb18fd07
DM
12942016-08-18 David Malcolm <dmalcolm@redhat.com>
1295
1296 * c-common.c: Include "spellcheck.h".
1297 (cb_get_suggestion): New function.
1298 * c-common.h (cb_get_suggestion): New decl.
1299 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
1300 cb_get_suggestion.
1301
a76989dc
MP
13022016-08-18 Marek Polacek <polacek@redhat.com>
1303
1304 PR c/71514
1305 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
1306 and pointer-to-VLA.
1307
65e736c0
DM
13082016-08-16 David Malcolm <dmalcolm@redhat.com>
1309
1310 PR c/72857
1311 * c-common.c (substring_loc::get_range): Rename to...
1312 (substring_loc::get_location): ...this, converting param from a
1313 source_range * to a location_t *. Call
1314 get_source_location_for_substring rather than
1315 get_source_range_for_substring, and pass in m_caret_idx.
1316 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
1317 (substring_loc::get_range): Replace with...
1318 (substring_loc::get_location): ...this.
1319 (substring_loc::set_caret_index): New method.
1320 (substring_loc): Add field m_caret_idx.
1321 * c-format.c (format_warning_va): Update for above changes.
1322 Rename local "substring_loc" to "fmt_substring_loc" to avoid
1323 clashing with type name.
1324 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
1325 (check_argument_type): Likewise.
1326 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
1327 Use a copy when emitting warnings, setting the caret index from TYPE.
1328
7e1dde14 13292016-08-16 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 1330 Arnaud Charlet <charlet@adacore.com>
7e1dde14
EB
1331
1332 * c-ada-spec.c (dump_number): New function.
1333 (handle_escape_character): Likewise.
1334 (print_ada_macros): Add handling of constant integers and strings.
1335
191816a3
MP
13362016-08-12 Marek Polacek <polacek@redhat.com>
1337
1338 PR c/7652
1339 * c-common.c (scalar_to_vector): Adjust fall through comment.
1340 * c-opts.c (c_common_handle_option): Likewise.
1341 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
1342 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
1343 fall through comment.
1344 * cilk.c (extract_free_variables): Add FALLTHRU.
1345
452df4a4
JM
13462016-08-10 Jason Merrill <jason@redhat.com>
1347
1348 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
1349
f3365c12
JM
13502016-08-09 Jason Merrill <jason@redhat.com>
1351
1352 * c-common.c (c_common_attribute_table): vector_size affects type
1353 identity.
1354
f0bc3323
MP
13552016-08-09 Marek Polacek <polacek@redhat.com>
1356
1357 PR c/7652
1358 * c-ada-spec.c (dump_generic_ada_node): Add return.
1359
98e5a19a
JM
13602016-08-09 Jason Merrill <jason@redhat.com>
1361
1362 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
1363 C++17 constexpr lambdas.
1364
895aa8e1
DM
13652016-08-08 David Malcolm <dmalcolm@redhat.com>
1366
1367 PR c/64955
1368 * c-common.h (selftest::c_format_c_tests): New declaration.
1369 (selftest::run_c_tests): New declaration.
1370 * c-format.c: Include "selftest.h.
1371 (format_warning_va): Add param "corrected_substring" and use
1372 it to add a replacement fix-it hint.
1373 (format_warning_at_substring): Likewise.
1374 (format_warning_at_char): Update for new param of
1375 format_warning_va.
1376 (argument_parser::check_argument_type): Pass "fki" to
1377 check_format_types.
1378 (check_format_types): Add param "fki" and pass it to
1379 format_type_warning.
1380 (deref_n_times): New function.
1381 (get_modifier_for_format_len): New function.
1382 (selftest::test_get_modifier_for_format_len): New function.
1383 (get_format_for_type): New function.
1384 (format_type_warning): Add param "fki" and use it to attempt
1385 to provide hints for argument types when calling
1386 format_warning_at_substring.
1387 (selftest::get_info): New function.
1388 (selftest::assert_format_for_type_streq): New function.
1389 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
1390 (selftest::test_get_format_for_type_printf): New function.
1391 (selftest::test_get_format_for_type_scanf): New function.
1392 (selftest::c_format_c_tests): New function.
1393
e52ed3fe
DM
13942016-08-08 David Malcolm <dmalcolm@redhat.com>
1395
1396 PR c/52952
1397 * c-format.c: Include "diagnostic.h".
1398 (location_column_from_byte_offset): Delete.
1399 (location_from_offset): Delete.
1400 (format_warning_va): New function.
1401 (format_warning_at_substring): New function.
1402 (format_warning_at_char): New function.
1403 (check_format_arg): Capture location of format_tree and pass to
1404 check_format_info_main.
1405 (argument_parser): Add fields "start_of_this_format" and
1406 "format_string_cst".
1407 (flag_chars_t::validate): Add param "format_string_cst". Convert
1408 warning_at call using location_from_offset to call to
1409 format_warning_at_char.
1410 (argument_parser::argument_parser): Add param "format_string_cst_"
1411 and use use it to initialize field "format_string_cst".
1412 Initialize new field "start_of_this_format".
1413 (argument_parser::read_format_flags): Convert warning_at call
1414 using location_from_offset to a call to format_warning_at_char.
1415 (argument_parser::read_any_format_left_precision): Likewise.
1416 (argument_parser::read_any_format_precision): Likewise.
1417 (argument_parser::read_any_other_modifier): Likewise.
1418 (argument_parser::find_format_char_info): Likewise, in three places.
1419 (argument_parser::parse_any_scan_set): Likewise, in one place.
1420 (argument_parser::handle_conversions): Likewise, in two places.
1421 (argument_parser::check_argument_type): Add param "fmt_param_loc"
1422 and use it to make a substring_loc. Pass the latter to
1423 check_format_types.
1424 (check_format_info_main): Add params "fmt_param_loc" and
1425 "format_string_cst". Convert warning_at calls using
1426 location_from_offset to calls to format_warning_at_char. Pass the
1427 new params to the arg_parser ctor. Pass "format_string_cst" to
1428 flag_chars.validate. Pass "fmt_param_loc" to
1429 arg_parser.check_argument_type.
1430 (check_format_types): Convert first param from a location_t
1431 to a const substring_loc & and rename to "fmt_loc". Attempt
1432 to extract the range of the relevant parameter and pass it
1433 to format_type_warning.
1434 (format_type_warning): Convert first param from a location_t
1435 to a const substring_loc & and rename to "fmt_loc". Add
1436 params "param_range" and "type". Replace calls to warning_at
1437 with calls to format_warning_at_substring.
1438
1c4d457e
DM
14392016-08-08 David Malcolm <dmalcolm@redhat.com>
1440
1441 * c-format.c (class flag_chars_t): New class.
1442 (struct length_modifier): New struct.
1443 (class argument_parser): New class.
1444 (flag_chars_t::flag_chars_t): New ctor.
1445 (flag_chars_t::has_char_p): New method.
1446 (flag_chars_t::add_char): New method.
1447 (flag_chars_t::validate): New method.
1448 (flag_chars_t::get_alloc_flag): New method.
1449 (flag_chars_t::assignment_suppression_p): New method.
1450 (argument_parser::argument_parser): New ctor.
1451 (argument_parser::read_any_dollar): New method.
1452 (argument_parser::read_format_flags): New method.
1453 (argument_parser::read_any_format_width): New method.
1454 (argument_parser::read_any_format_left_precision): New method.
1455 (argument_parser::read_any_format_precision): New method.
1456 (argument_parser::handle_alloc_chars): New method.
1457 (argument_parser::read_any_length_modifier): New method.
1458 (argument_parser::read_any_other_modifier): New method.
1459 (argument_parser::find_format_char_info): New method.
1460 (argument_parser::validate_flag_pairs): New method.
1461 (argument_parser::give_y2k_warnings): New method.
1462 (argument_parser::parse_any_scan_set): New method.
1463 (argument_parser::handle_conversions): New method.
1464 (argument_parser::check_argument_type): New method.
1465 (check_format_info_main): Introduce classes argument_parser
1466 and flag_chars_t, moving the code within the loop into methods
1467 of these classes. Make various locals "const".
1468
88fa5555
DM
14692016-08-05 David Malcolm <dmalcolm@redhat.com>
1470
1471 * c-common.c: Include "substring-locations.h".
1472 (get_cpp_ttype_from_string_type): New function.
1473 (g_string_concat_db): New global.
1474 (substring_loc::get_range): New method.
1475 * c-common.h (g_string_concat_db): New declaration.
1476 (class substring_loc): New class.
1477 * c-lex.c (lex_string): When concatenating strings, capture the
1478 locations of all tokens using a new obstack, and record the
1479 concatenation locations within g_string_concat_db.
1480 * c-opts.c (c_common_init_options): Construct g_string_concat_db
1481 on the ggc-heap.
1482
78169471
MP
14832016-07-29 Marek Polacek <polacek@redhat.com>
1484
638fc14f
MP
1485 PR c/71926
1486 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
1487 parentheses warning.
1488
78169471
MP
1489 PR c/71574
1490 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
1491
1225d6b1
ML
14922016-07-28 Martin Liska <mliska@suse.cz>
1493
1494 PR gcov-profile/68025
1495 * c-common.c (handle_no_profile_instrument_function_attribute):
1496
ec1e2a40
BE
14972016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
1498
1499 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
1500 BITS_PER_UNIT_LOG.
1501
5ec2cd9f
JM
15022016-07-25 Jason Merrill <jason@redhat.com>
1503
1504 PR c++/65970
1505 * c.opt (fconstexpr-loop-limit): New.
1506
9dc5773f 15072016-07-22 Martin Sebor <msebor@redhat.com>
2e6b45af
MS
1508
1509 PR c++/71675
1510 * c-common.c (resolve_overloaded_builtin): Avoid converting
1511 __atomic_compare_exchange_n return type to that of what its
1512 first argument points to.
1513
e3fe09c1
UB
15142016-07-22 Uros Bizjak <ubizjak@gmail.com>
1515
1516 * c-common.c: Use HOST_WIDE_INT_M1U instead of
1517 ~(unsigned HOST_WIDE_INT) 0.
1518
bc91c436
ML
15192016-07-22 Martin Liska <mliska@suse.cz>
1520
1521 PR gcov-profile/69028
1522 PR gcov-profile/62047
1523 * cilk.c (create_cilk_helper_decl): Set location of a new decl
1524 to the current_function_decl.
1525
451dcc66
JM
15262016-07-21 Jason Merrill <jason@redhat.com>
1527
1528 PR c++/65168
1529 * c-common.c (c_common_truthvalue_conversion): Check
1530 c_inhibit_evaluation_warnings for warning about address of
1531 reference.
1532
de6a69ee
DM
15332016-07-20 David Malcolm <dmalcolm@redhat.com>
1534
1535 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
1536 const char *.
1537
d022c55a
JM
15382016-07-15 Jason Merrill <jason@redhat.com>
1539
1540 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
1541
ddbbcb19
JJ
15422016-07-15 Jakub Jelinek <jakub@redhat.com>
1543
1544 PR c/71858
1545 * c-common.h (enum lookup_name_fuzzy_kind): Add
1546 FUZZY_LOOKUP_FUNCTION_NAME.
1547
d0cf395a
JM
15482016-07-08 Jason Merrill <jason@redhat.com>
1549
1550 P0145: Refining Expression Order for C++.
1551 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
1552 * c-opts.c: Adjust.
1553
98d44e93
MT
15542016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
1555
1556 PR c++/71214
1557 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
1558
f9d8d994
TS
15592016-06-29 Thomas Schwinge <thomas@codesourcery.com>
1560
1561 * c-pragma.h (enum pragma_kind): Rename
1562 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
1563 users.
1564
4aa83879
RB
15652016-06-29 Richard Biener <rguenther@suse.de>
1566
1567 PR middle-end/71002
1568 * c-common.c (c_common_get_alias_set): Remove union type punning case.
1569
a25bd9e6
JM
15702016-06-24 Jason Merrill <jason@redhat.com>
1571
1572 P0145R2: Refining Expression Order for C++.
1573 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
1574 MODIFY_EXPR.
1575
a86451b9
JJ
15762016-06-24 Jakub Jelinek <jakub@redhat.com>
1577
1578 * c-common.c (check_builtin_function_arguments): Require last
1579 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
1580 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
1581 if the last argument is pointer to enumerated or boolean type.
1582
1a4f11c8
DM
15832016-06-22 David Malcolm <dmalcolm@redhat.com>
1584
1585 PR c/70339
1586 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
1587 (lookup_name_fuzzy): New prototype.
1588
fe55692c
JDA
15892016-06-21 John David Anglin <danglin@gcc.gnu.org>
1590
1591 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
1592
4eb24e01
JM
15932016-06-14 Jason Merrill <jason@redhat.com>
1594
1595 P0145R2: Refining Expression Order for C++.
1596 * c.opt (fargs-in-order): New.
1597 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
1598
ef7cf206
JJ
15992016-06-13 Jakub Jelinek <jakub@redhat.com>
1600
0dda258b
JJ
1601 PR sanitizer/71498
1602 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
1603 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
1604
ef7cf206
JJ
1605 PR preprocessor/71183
1606 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
1607 to cb_get_source_date_epoch.
1608
50b15873
JJ
16092016-06-10 Jakub Jelinek <jakub@redhat.com>
1610
1611 PR c/68657
1612 * c.opt (Wpsabi): Add Warning flag.
1613
4d926e34
MS
16142016-06-10 Martin Sebor <msebor@redhat.com>
1615
1616 PR c/71392
1617 * gcc/c-family/c-common.c (handle_nonnull_attribute): Accept
1618 the nonnull attribute in type-generic builtins.
1619
e01b4e16
MS
16202016-06-09 Martin Sebor <msebor@redhat.com>
1621
1622 PR c/70883
1623 * c-common.c (builtin_function_validate_nargs): Make text of error
1624 message consistent with others like it.
1625
44a845ca
MS
16262016-06-08 Martin Sebor <msebor@redhat.com>
1627 Jakub Jelinek <jakub@redhat.com>
1628
1629 PR c++/70507
1630 PR c/68120
1631 * c-common.c (check_builtin_function_arguments): Handle
1632 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
1633
a80a7051
RB
16342016-06-08 Richard Biener <rguenther@suse.de>
1635
1636 * c-common.c (parse_optimize_options): Improve diagnostic messages.
1637
bfd67b47
RB
16382016-06-07 Richard Biener <rguenther@suse.de>
1639
1640 PR c/61564
1641 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
1642 options and warn about others.
1643
15c98b2e
ES
16442016-06-01 Eduard Sanou <dhole@openmailbox.org>
1645
1646 * c-common.c (get_source_date_epoch): Rename to
1647 cb_get_source_date_epoch.
1648 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
1649 message when the parsing fails. Use error_at instead of fatal_error.
1650 * c-common.h (get_source_date_epoch): Rename to
1651 cb_get_source_date_epoch.
1652 * c-common.h (cb_get_source_date_epoch): Prototype.
1653 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
1654 * c-common.h (c_omp_region_type): Remove trailing comma.
1655 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
1656 * c-lex.c (c_lex_with_flags): Remove initialization of
1657 pfile->source_date_epoch.
1658
00631022
JJ
16592016-05-30 Jakub Jelinek <jakub@redhat.com>
1660
1661 PR c++/71349
1662 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
1663 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
1664 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
1665 instead of C_OMP_CLAUSE_SPLIT_FOR.
1666
f17a223d
RB
16672016-05-24 Richard Biener <rguenther@suse.de>
1668
1669 PR middle-end/70434
1670 PR c/69504
1671 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
1672 (convert_vector_to_array_for_subscript): ... this.
1673 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
1674 VIEW_CONVERT_EXPR to an array type. Rename to ...
1675 (convert_vector_to_array_for_subscript): ... this.
1676
4f2e1536
MP
16772016-05-12 Marek Polacek <polacek@redhat.com>
1678
1679 PR c/70756
1680 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
1681 size_in_bytes and pass LOC to it.
1682
d6e83a8d
MM
16832016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
1684
1685 PR c/43651
1686 * c.opt (Wduplicate-decl-specifier): New option.
1687
5c3a10fb
MP
16882016-05-11 Marek Polacek <polacek@redhat.com>
1689
1690 PR c++/71024
1691 * c-common.c (diagnose_mismatched_attributes): New function.
1692 * c-common.h (diagnose_mismatched_attributes): Declare.
1693
deef7113
MP
16942016-05-04 Marek Polacek <polacek@redhat.com>
1695
1696 * c.opt (Wdangling-else): New option.
1697
79ce98bc
MP
16982016-05-03 Marek Polacek <polacek@redhat.com>
1699
1700 PR c/70859
1701 * c-common.c (builtin_function_validate_nargs): Add location
1702 parameter. Use it.
1703 (check_builtin_function_arguments): Add location and arguments
1704 parameters. Use them.
1705 * c-common.h (check_builtin_function_arguments): Update declaration.
1706
381cdae4
RB
17072016-05-03 Richard Biener <rguenther@suse.de>
1708
1709 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
1710 allow call args to gimplify to SSA names.
1711
1d793c34
MP
17122016-05-03 Marek Polacek <polacek@redhat.com>
1713
1714 * c-common.h (enum c_omp_region_type): Remove stray comma.
1715
77886428
CP
17162016-05-02 Cesar Philippidis <cesar@codesourcery.com>
1717
1718 * c-common.h (enum c_omp_region_type): Define.
1719
697e0b28
RS
17202016-05-02 Richard Sandiford <richard.sandiford@arm.com>
1721
1722 * c-common.c (shorten_compare): Use wi::to_wide.
1723
e7ff0319
CP
17242016-04-29 Cesar Philippidis <cesar@codesourcery.com>
1725
1726 PR middle-end/70626
1727 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
1728 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
1729 reduction clauses in acc parallel loops.
1730
2fff3db8
MP
17312016-04-29 Marek Polacek <polacek@redhat.com>
1732
1733 PR c/70852
1734 * c-common.c (warn_for_memset): Check domain before accessing it.
1735
509063eb
DV
17362016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
1737
1738 PR/69089
1739 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
1740 "aligned" attribute.
1741
b632761d
JM
17422016-04-28 Jason Merrill <jason@redhat.com>
1743
1744 * c-lex.c (c_common_has_attribute): Handle nodiscard.
1745
174f6622
ES
17462016-04-28 Eduard Sanou <dhole@openmailbox.org>
1747 Matthias Klose <doko@debian.org>
1748
1749 * c-common.c (get_source_date_epoch): New function, gets the environment
1750 variable SOURCE_DATE_EPOCH and parses it as long long with error
1751 handling.
1752 * c-common.h (get_source_date_epoch): Prototype.
1753 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
1754
6bc2bb18
RB
17552015-04-27 Ryan Burn <contact@rnburn.com>
1756
1757 PR c++/69024
1758 PR c++/68997
1759 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
1760 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
1761 external linkage.
1762 (cilk_detect_and_unwrap): Corresponding changes.
1763 (extract_free_variables): Don't extract free variables from
1764 AGGR_INIT_EXPR slot.
1765 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
1766 (cilk_recognize_spawn): Likewise.
1767
c1e1f433
BS
17682016-04-27 Bernd Schmidt <bschmidt@redhat.com>
1769
1770 * c.opt (Wmemset-elt-size): New option.
1771 * c-common.c (warn_for_memset): New function.
1772 * c-common.h (warn_for_memset): Declare.
1773
d067e05f
JM
17742016-04-25 Jason Merrill <jason@redhat.com>
1775
1776 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
1777 No longer static.
1778 * c-common.h: Declare it.
1779 * c-lex.c (c_common_has_attribute): Add maybe_unused.
1780
9aa36ae5
JM
17812016-04-22 Jason Merrill <jason@redhat.com>
1782
1783 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
1784
477d4906
IV
17852016-04-20 Ilya Verbin <ilya.verbin@intel.com>
1786
1787 PR c++/69363
1788 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
1789 * c-common.h (c_finish_cilk_clauses): Remove declaration.
1790
fe37c7af
MM
17912016-04-18 Michael Matz <matz@suse.de>
1792
1793 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
1794 and SET_DECL_ALIGN.
1795
23f2660f
EB
17962016-04-17 Eric Botcazou <ebotcazou@adacore.com>
1797
1798 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
1799 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
1800 to incomplete types.
1801 (dump_nested_type): Remove redundant tests and tidy up.
1802 (print_ada_declaration): Also set TREE_VISITED on the declaration of
1803 a type which is the typedef of an original type.
1804
1e77281b
MP
18052016-04-15 Marek Polacek <polacek@redhat.com>
1806
1807 PR c/70651
1808 * c-common.c (build_va_arg): Change two asserts into errors and return
1809 error_mark_node.
1810
b3a77f21
MP
18112016-04-13 Marek Polacek <polacek@redhat.com>
1812
1813 PR c++/70639
1814 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
1815 for switch statements, too.
1816
322b8466
JM
18172016-03-28 Jason Merrill <jason@redhat.com>
1818
1819 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
1820
fbdb6baf
MP
18212016-03-23 Marek Polacek <polacek@redhat.com>
1822
1823 PR c++/69884
1824 * c.opt (Wignored-attributes): New option.
1825
5c240f4d
DM
18262016-03-22 David Malcolm <dmalcolm@redhat.com>
1827
1828 PR c/69993
1829 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
1830 diagnostic text, reversing the order of the warning and note so
1831 that they appear in source order.
1832
14ba7b28
MP
18332016-03-17 Marek Polacek <polacek@redhat.com>
1834
1835 PR c/69407
1836 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
1837 operations.
1838
08a1cadc
JM
18392016-03-14 Jason Merrill <jason@redhat.com>
1840
2aaeea19
JM
1841 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
1842
08a1cadc
JM
1843 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
1844
c06d25bb
RB
18452016-03-09 Richard Biener <rguenther@suse.de>
1846
1847 PR c/70143
1848 * c-common.c (strict_aliasing_warning): Add back
1849 alias_sets_conflict_p check.
1850
80aac5c8
JM
18512016-03-08 Jason Merrill <jason@redhat.com>
1852
1853 * c-opts.c (set_std_cxx1z): Don't enable concepts.
1854
64b23c13
DM
18552016-03-04 David Malcolm <dmalcolm@redhat.com>
1856
1857 PR c/68187
1858 * c-indentation.c (get_visual_column): Move code to determine next
1859 tab stop to...
1860 (next_tab_stop): ...this new function.
1861 (line_contains_hash_if): Delete function.
1862 (detect_preprocessor_logic): Delete function.
1863 (get_first_nws_vis_column): New function.
1864 (detect_intervening_unindent): New function.
1865 (should_warn_for_misleading_indentation): Replace call to
1866 detect_preprocessor_logic with a call to
1867 detect_intervening_unindent.
1868
729526f5
DM
18692016-03-04 David Malcolm <dmalcolm@redhat.com>
1870
1871 PR c/68187
1872 * c-indentation.c (should_warn_for_misleading_indentation): When
1873 suppressing warnings about cases where the guard and body are on
1874 the same column, only use the first non-whitespace column in place
1875 of the guard token column when dealing with "else" clauses.
1876 When rejecting aligned BODY and NEXT, loosen the requirement
1877 from equality with the first non-whitespace of guard to simply
1878 that they not be indented relative to it.
1879
e9a35493
RB
18802016-03-04 Richard Biener <rguenther@suse.de>
1881
1882 PR c++/70054
1883 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
1884 instead of alias_sets_conflict_p.
1885
1be56bc5
MP
18862016-03-01 Marek Polacek <polacek@redhat.com>
1887
1888 PR c++/69795
1889 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
1890 any DECL.
1891
35886f0b
MS
18922016-02-22 Martin Sebor <msebor@redhat.com>
1893
1894 PR middle-end/69780
1895 * c-common.c (check_builtin_function_arguments): Validate and
1896 reject invalid arguments to __builtin_alloca_with_align.
1897
4246c8da
MW
18982016-02-20 Mark Wielaard <mjw@redhat.com>
1899
1900 PR c/28901
1901 * c.opt (Wunused-const-variable): Turn into Alias for...
1902 (Wunused-const-variable=): New option.
1903
268be88c
BE
19042016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
1905
1906 PR c++/69865
1907 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
1908 here...
1909 (c_common_init_options): ...to here.
1910 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
1911
871b3f47
JJ
19122016-02-19 Jakub Jelinek <jakub@redhat.com>
1913
1914 PR c++/69826
1915 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
1916 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
1917 flag_preprocess_only.
1918
bf14eba2
JJ
19192016-02-16 Jakub Jelinek <jakub@redhat.com>
1920
1921 PR c/69835
1922 * c.opt (Wnonnull-compare): Enable for -Wall.
1923
ba6b3795
JJ
19242016-02-15 Jakub Jelinek <jakub@redhat.com>
1925
1926 PR c++/69797
1927 * c-common.c (sync_resolve_size): Diagnose too few arguments
1928 even when params is non-NULL empty vector.
1929
a011cd92
BS
19302016-02-08 Bernd Schmidt <bschmidt@redhat.com>
1931
1932 PR target/60410
1933 * c.opt (fshort-double): Remove.
1934
46cb9332
MS
19352016-02-05 Martin Sebor <msebor@redhat.com>
1936
1937 PR c++/69662
1938 * c.opt (Warning options): Update -Wplacement-new to take
1939 an optional argument.
1940
e1b81f2b
JJ
19412016-02-01 Jakub Jelinek <jakub@redhat.com>
1942
1943 PR preprocessor/69543
1944 PR c/69558
1945 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
1946 instead of loc to control_warning_option.
1947
b6adbb9f
NS
19482016-02-01 Nathan Sidwell <nathan@codesourcery.com>
1949
1950 * c.opt (fopenacc-dim=): New option.
1951
5d70666e
RB
19522016-01-27 Ryan Burn <contact@rnburn.com>
1953
1954 PR cilkplus/69267
1955 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
1956 gimplify_arg. Removed superfluous post_p argument.
1957 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
1958 superfluous post_p argument.
1959 * c-gimplify.c (c_gimplify_expr): Likewise.
1960
01e1dea3
DM
19612016-01-26 David Malcolm <dmalcolm@redhat.com>
1962
1963 PR other/69006
1964 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
1965 pp_newline_and_flush with pp_flush.
1966
9f04a53e
MS
19672016-01-20 Martin Sebor <msebor@redhat.com>
1968
1969 PR c/69405
1970 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
1971 an incompatible argument when the argument isn't a valid tree node.
1972
7f26f7df
JM
19732016-01-18 Jason Merrill <jason@redhat.com>
1974
1975 PR c++/68767
1976 * c-common.c (check_function_arguments_recurse): Fold the whole
1977 COND_EXPR, not just the condition.
1978
f62bf092
TV
19792016-01-18 Tom de Vries <tom@codesourcery.com>
1980
1981 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
1982 classify as loop clause.
1983
e0a575ff
JJ
19842016-01-15 Jakub Jelinek <jakub@redhat.com>
1985
1986 PR bootstrap/68271
1987 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
1988 C++ FE no longer has limit on number of pragmas.
1989
19902015-01-14 Ryan Burn <contact@rnburn.com>
b6e3db06
RB
1991
1992 PR c++/69048
1993 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
c47eaca6 1994 to add missing cleanup point.
b6e3db06 1995
c7df95d8
DM
19962016-01-14 David Malcolm <dmalcolm@redhat.com>
1997
1998 PR c++/68819
1999 * c-indentation.c (get_visual_column): Add location_t param.
2000 Handle the column number being zero by effectively disabling the
2001 warning, with an "inform".
2002 (should_warn_for_misleading_indentation): Add location_t argument
2003 for all uses of get_visual_column.
2004
21efdd80
PP
20052016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
2006
2007 PR c++/69029
2008 * c-indentation.c (should_warn_for_misleading_indentation):
2009 Don't warn about do-while statements.
2010
7a127fa7
MS
20112016-01-07 Martin Sebor <msebor@redhat.com>
2012
2013 PR c/68966
2014 * c-common.c (sync_resolve_size): Reject first argument when it's
2015 a pointer to _Bool.
2016
c589e975
DM
20172016-01-05 David Malcolm <dmalcolm@redhat.com>
2018
2019 PR c/69122
2020 * c-indentation.c (get_visual_column): Remove default argument.
2021 (should_warn_for_misleading_indentation): For the multiline case,
2022 update call to get_visual_column for next_stmt_exploc so that it
2023 captures the location of the first non-whitespace character in the
2024 relevant line. Don't issue warnings if there is non-whitespace
2025 before the next statement.
2026
818ab71a
JJ
20272016-01-04 Jakub Jelinek <jakub@redhat.com>
2028
2029 Update copyright years.
2030
745e411d
DM
20312015-12-21 David Malcolm <dmalcolm@redhat.com>
2032
2033 * c-common.c (binary_op_error): Convert first param from
2034 location_t to rich_location * and use it when emitting an error.
2035 * c-common.h (binary_op_error): Convert first param from
2036 location_t to rich_location *.
2037
de67c4c3
DM
20382015-12-16 David Malcolm <dmalcolm@redhat.com>
2039
2040 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
2041 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
2042
4a38b02b
IV
20432015-12-15 Ilya Verbin <ilya.verbin@intel.com>
2044
2045 * c-common.c (c_common_attribute_table): Handle "omp declare target
2046 link" attribute.
2047
54d62f51
JJ
20482015-12-14 Jakub Jelinek <jakub@redhat.com>
2049
2050 PR c/68833
2051 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
2052
8d4227c8
TB
20532014-12-12 Tobias Burnus <burnus@net-b.de>
2054
2055 PR fortran/68815
2056 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
2057 specifiers (%d, %i,%u and %c).
2058
f6069ccc
DM
20592015-12-10 David Malcolm <dmalcolm@redhat.com>
2060
2061 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
2062
63bbf46d
JJ
20632015-12-08 Jakub Jelinek <jakub@redhat.com>
2064
2065 PR c/48088
2066 PR c/68657
2067 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
2068 * c-pragma.c (handle_pragma_diagnostic): Adjust
2069 control_warning_option caller.
2070
f79520bb
DM
20712015-12-07 David Malcolm <dmalcolm@redhat.com>
2072
2073 * c-common.c (c_cpp_error): Update for change to
2074 rich_location::set_range.
2075
b3d5bc62
JJ
20762015-12-04 Paolo Bonzini <bonzini@gnu.org>
2077
2078 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
2079 shifting 1 out of the sign bit.
2080
20812015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
2082
2083 * c-common.c (c_common_attribute_table[]): Update max arguments
2084 count for "simd" attribute.
2085 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
2086
6eb4a537
JJ
20872015-12-03 Jakub Jelinek <jakub@redhat.com>
2088
2089 PR preprocessor/57580
2090 * c-ppoutput.c (print): Change printed field to bool.
2091 Move src_file last for smaller padding.
2092 (init_pp_output): Set print.printed to false instead of 0.
2093 (scan_translation_unit): Fix up formatting. Set print.printed
2094 to true after printing something other than newline.
2095 (scan_translation_unit_trad): Set print.printed to true instead of 1.
2096 (maybe_print_line_1): Set print.printed to false instead of 0.
2097 (print_line_1): Likewise.
2098 (do_line_change): Set print.printed to true instead of 1.
2099 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
2100 dump_macro): Set print.printed to false after printing newline.
2101
4250754e
JM
21022015-12-02 Jason Merrill <jason@redhat.com>
2103
f479b43d
JM
2104 * c-common.c (fold_for_warn): New.
2105 (warn_logical_operator, warn_tautological_cmp)
2106 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
2107
4250754e
JM
2108 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
2109 (c_fully_fold_internal, decl_constant_value_for_optimization):
2110 Move to c/c-fold.c.
2111 * c-common.h: Don't declare decl_constant_value_for_optimization.
2112
e9e32ee6
JM
21132015-12-02 Joseph Myers <joseph@codesourcery.com>
2114
2115 PR c/68162
2116 * c-common.h (c_build_qualified_type): Add extra default
2117 arguments.
2118
37d5ad46
JB
21192015-12-01 Julian Brown <julian@codesourcery.com>
2120 Cesar Philippidis <cesar@codesourcery.com>
2121 James Norris <James_Norris@mentor.com>
2122
2123 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
2124 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
2125 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
2126
f07862c7
EB
21272015-11-30 Eric Botcazou <ebotcazou@adacore.com>
2128
2129 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
2130 (decl_sloc_common): Delete and move bulk of processing to...
2131 (decl_sloc): ...here.
2132 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
2133 (dump_ada_double_name): Remove S parameter and compute the suffix.
2134 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
2135 element type and deal with an anonymous one.
2136 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
2137 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
2138 and remove reference to QUAL_UNION_TYPE.
2139 (dump_nested_types): Make 2 passes on the fields and move bulk to...
2140 (dump_nested_type): ...here. New function extracted from above.
2141 Generate a full declaration for anonymous element type of arrays.
2142 (print_ada_declaration): Really skip anonymous declarations. Remove
2143 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
2144 Clean up processing of declarations of array types and objects.
2145 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
2146 Remove obsolete code and tidy up.
2147
75c8aac3
JH
21482015-11-29 Jan Hubicka <hubicka@ucw.cz>
2149
2150 PR c/67581
2151 * c-common.c (handle_transparent_union_attribute): Update
2152 also type variants.
2153
b58d3df2
ML
21542015-11-27 Martin Liska <mliska@suse.cz>
2155
2156 PR c++/68312
2157 * array-notation-common.c (cilkplus_extract_an_triplets):
2158 Release vector of vectors.
2159 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
2160
89a01fcf
EB
21612015-11-26 Eric Botcazou <ebotcazou@adacore.com>
2162
2163 PR c++/68527
2164 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
2165 (print_ada_struct_decl): Likewise.
2166
cc5c5226
IZ
21672015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
2168
2169 PR c++/68001
2170 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
2171 * cilk.c (recognize_spawn): Determine location in a more precise
2172 way.
2173
269adb9d
JM
21742015-11-19 Jason Merrill <jason@redhat.com>
2175
2176 * c-common.c (shorten_compare): But look through macros from
2177 system headers.
2178
d0eccfcd
JM
21792015-11-18 Jason Merrill <jason@redhat.com>
2180
2181 * c-common.c (shorten_compare): Don't -Wtype-limits if the
2182 non-constant operand comes from a macro.
2183
3e44547c
JM
21842015-11-17 Jason Merrill <jason@redhat.com>
2185
2186 PR bootstrap/68346
2187 * c-common.c (warn_tautological_cmp): Fold before checking for
2188 constants.
2189
0f62c7a0
MP
21902015-11-16 Marek Polacek <polacek@redhat.com>
2191
2192 PR c++/68362
2193 * c-common.c (check_case_bounds): Fold low and high cases.
2194
a868811e
MP
21952015-11-16 Marek Polacek <polacek@redhat.com>
2196
2197 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
2198 * c-common.c (c_common_get_alias_set): Likewise.
2199 (handle_visibility_attribute): Likewise.
2200
fff77217
KY
22012015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
2202
2203 * c-common.c (handle_simd_attribute): New.
2204 (struct attribute_spec): Add entry for "simd".
2205 (handle_simd_attribute): New.
2206
269e63b7
KT
22072015-11-13 Kai Tietz <ktietz70@googlemail.com>
2208
2209 * c-lex.c (interpret_float): Use fold_convert.
2210
ebedc9a3
DM
22112015-11-13 David Malcolm <dmalcolm@redhat.com>
2212
2213 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
2214 and store it on the result.
2215 * c-opts.c (c_common_init_options): Set
2216 global_dc->colorize_source_p.
2217
6e232ba4
JN
22182015-11-12 James Norris <jnorris@codesourcery.com>
2219 Joseph Myers <joseph@codesourcery.com>
2220
2221 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
2222 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
2223 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
2224 PRAGMA_OACC_CLAUSE_LINK.
2225
e78bede6
MP
22262015-11-11 Marek Polacek <polacek@redhat.com>
2227
2228 PR c/68107
2229 PR c++/68266
2230 * c-common.c (valid_array_size_p): New function.
2231 * c-common.h (valid_array_size_p): Declare.
2232
3f8257db 22332015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4ac93c7c
DH
2234
2235 PR bootstrap/68271
2236 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
2237
69f293c9
AM
22382015-11-11 Andrew MacLeod <amacleod@redhat.com>
2239
2240 * array-notation-common.c: Remove unused header files.
2241 * c-ada-spec.c: Likewise.
2242 * c-cilkplus.c: Likewise.
2243 * c-common.c: Likewise.
2244 * c-cppbuiltin.c: Likewise.
2245 * c-dump.c: Likewise.
2246 * c-format.c: Likewise.
2247 * c-gimplify.c: Likewise.
2248 * c-indentation.c: Likewise.
2249 * c-lex.c: Likewise.
2250 * c-omp.c: Likewise.
2251 * c-opts.c: Likewise.
2252 * c-pch.c: Likewise.
2253 * c-ppoutput.c: Likewise.
2254 * c-pragma.c: Likewise.
2255 * c-pretty-print.c: Likewise.
2256 * c-semantics.c: Likewise.
2257 * c-ubsan.c: Likewise.
2258 * cilk.c: Likewise.
2259 * stub-objc.c: Likewise.
2260
3a40d81d
NS
22612015-11-09 Thomas Schwinge <thomas@codesourcery.com>
2262 Cesar Philippidis <cesar@codesourcery.com>
2263 James Norris <jnorris@codesourcery.com>
2264 Julian Brown <julian@codesourcery.com>
2265 Nathan Sidwell <nathan@codesourcery.com>
2266
2267 * c-pragma.c (oacc_pragmas): Add "routine".
2268 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
2269
ee45a32d
EB
22702015-11-08 Eric Botcazou <ebotcazou@adacore.com>
2271
2272 * c-common.c (c_common_attributes): Add scalar_storage_order.
2273 (handle_scalar_storage_order_attribute): New function.
2274 * c-pragma.c (global_sso): New variable.
2275 (maybe_apply_pragma_scalar_storage_order): New function.
2276 (handle_pragma_scalar_storage_order): Likewise.
2277 (init_pragma): Register scalar_storage_order.
2278 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
2279 * c.opt (Wscalar-storage-order): New warning.
2280 (fsso-struct=): New option.
2281
eb11eb15
MS
22822015-11-08 Martin Sebor <msebor@redhat.com>
2283
2284 * c.opt (Wplacement-new): Add a period to the end of a sentence.
2285
0aad0198
RS
22862015-11-07 Richard Sandiford <richard.sandiford@arm.com>
2287
2288 * c-common.c: Don't undef DEF_BUILTIN.
2289
8a645150
DM
22902015-11-06 David Malcolm <dmalcolm@redhat.com>
2291
2292 * c-common.c (c_cpp_error): Convert parameter from location_t to
2293 rich_location *. Eliminate the "column_override" parameter and
2294 the call to diagnostic_override_column.
2295 Update the "done_lexing" clause to set range 0
2296 on the rich_location, rather than overwriting a location_t.
2297 * c-common.h (c_cpp_error): Convert parameter from location_t to
2298 rich_location *. Eliminate the "column_override" parameter.
2299
7a5e4956
CP
23002015-11-05 Cesar Philippidis <cesar@codesourcery.com>
2301 Thomas Schwinge <thomas@codesourcery.com>
2302 James Norris <jnorris@codesourcery.com>
2303
2304 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
2305 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
2306 clauses with parallel and kernels and loops.
2307 * c-pragma.h (enum pragma_omp_clause): Add entries for
2308 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
2309 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
2310 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
2311 INDEPENDENT,SEQ}.
2312 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
2313
e2f5cc96
MS
23142015-11-05 Martin Sebor <msebor@redhat.com>
2315
2316 PR c++/67942
2317 * c.opt (-Wplacement-new): New option.
2318
e01d41e5
JJ
23192015-11-05 Jakub Jelinek <jakub@redhat.com>
2320
2321 * c-common.h (c_finish_omp_atomic): Add TEST argument.
2322 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
2323 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
2324 save_expr or create_tmp_var* if TEST is true.
2325 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
2326 Don't call add_stmt here.
2327 (struct c_omp_check_loop_iv_data): New type.
2328 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
2329 c_omp_check_loop_iv_exprs): New functions.
2330 (c_omp_split_clauses): Adjust for lastprivate being allowed on
2331 distribute.
2332 (c_omp_declare_simd_clauses_to_numbers): Change
2333 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
2334 (c_omp_declare_simd_clauses_to_decls): Similarly change those
2335 from numbers to PARM_DECLs.
2336
595278be
MM
23372015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
2338
2339 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
2340 flag_checking.
2341
3f8257db 23422015-11-03 Bernd Schmidt <bschmidt@redhat.com>
c85158de
MS
2343
2344 PR c++-common/67882
b3d5bc62
JJ
2345 * c-common.h (fold_offsetof_1): Add argument.
2346 * c-common.c (fold_offsetof_1): Diagnose more invalid
c85158de
MS
2347 offsetof expressions that reference elements past the end of
2348 an array.
2349
4bf9e5a8
TS
23502015-11-03 Thomas Schwinge <thomas@codesourcery.com>
2351 Chung-Lin Tang <cltang@codesourcery.com>
2352
2353 * c-pragma.c (oacc_pragmas): Add "atomic".
2354 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
2355
3b1661a9
ES
23562015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
2357
2358 * c-common.c (handle_target_clones_attribute): New.
2359 (c_common_attribute_table): Add handle_target_clones_attribute.
2360 (handle_always_inline_attribute): Add check on target_clones attribute.
2361 (handle_target_attribute): Ditto.
2362
2adfab87
AM
23632015-10-29 Andrew MacLeod <amacleod@redhat.com>
2364
2365 * array-notation-common.c: Reorder #include's and remove duplicates.
2366 * c-ada-spec.c: Likewise.
2367 * c-cilkplus.c: Likewise.
2368 * c-common.c: Likewise.
2369 * c-cppbuiltin.c: Likewise.
2370 * c-dump.c: Likewise.
2371 * c-format.c: Likewise.
2372 * c-gimplify.c: Likewise.
2373 * c-indentation.c: Likewise.
2374 * c-lex.c: Likewise.
2375 * c-omp.c: Likewise.
2376 * c-opts.c: Likewise.
2377 * c-pch.c: Likewise.
2378 * c-ppoutput.c: Likewise.
2379 * c-pragma.c: Likewise.
2380 * c-pretty-print.c: Likewise.
2381 * c-semantics.c: Likewise.
2382 * c-ubsan.c: Likewise.
2383 * cilk.c: Likewise.
2384 * stub-objc.c: Likewise.
2385
d90ec4f2
JM
23862015-10-28 Jason Merrill <jason@redhat.com>
2387
2388 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
2389
88bae6f4
TS
23902015-10-27 Thomas Schwinge <thomas@codesourcery.com>
2391 James Norris <jnorris@codesourcery.com>
2392 Cesar Philippidis <cesar@codesourcery.com>
2393
2394 PR c/64765
2395 PR c/64880
2396 * c-common.h (c_oacc_split_loop_clauses): Declare function.
2397 * c-omp.c (c_oacc_split_loop_clauses): New function.
2398
b1726d6c
MS
23992015-10-21 Martin Sebor <msebor@redhat.com>
2400
2401 PR driver/68043
2402 * c.opt: End each sentence that describes an option with a period.
2403
fa60eeb9
MP
24042015-10-20 Marek Polacek <polacek@redhat.com>
2405
2406 * array-notation-common.c (is_cilkplus_vector_p): Define.
2407 * c-common.h (is_cilkplus_vector_p): Declare.
2408
95979049
MP
24092015-10-20 Marek Polacek <polacek@redhat.com>
2410
2411 * c.opt (std=gnu++11): Do not describe as experimental.
2412 (std=gnu++14): Likewise.
2413
2a9fb712
JM
24142015-10-19 Jason Merrill <jason@redhat.com>
2415
2416 * c-cppbuiltin.c (c_cpp_builtins): Define
2417 __cpp_nontype_template_args.
2418
13b380a3
JM
24192015-10-19 Jason Merrill <jason@redhat.com>
2420
2421 * c-cppbuiltin.c (c_cpp_builtins): Define
2422 __cpp_enumerator_attributes, __cpp_fold_expressions,
2423 __cpp_unicode_characters.
2424
d9a6bd32
JJ
24252015-10-13 Jakub Jelinek <jakub@redhat.com>
2426 Aldy Hernandez <aldyh@redhat.com>
2427
2428 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
2429 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
2430 (c_define_builtins): Likewise.
2431 * c-common.h (enum c_omp_clause_split): Add
2432 C_OMP_CLAUSE_SPLIT_TASKLOOP.
2433 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
2434 (c_finish_omp_for): Add ORIG_DECLV argument.
2435 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
2436 201511 instead of 201307.
2437 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
2438 OMP_CRITICAL_CLAUSES to it.
2439 (c_finish_omp_ordered): Add CLAUSES argument, set
2440 OMP_ORDERED_CLAUSES to it.
2441 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
2442 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
2443 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
2444 constructs and new OpenMP 4.5 clauses. Clear
2445 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
2446 verification code.
2447 * c-pragma.c (omp_pragmas_simd): Add taskloop.
2448 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
2449 (enum pragma_omp_clause): Add
2450 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
2451 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
2452
624d31fe
RS
24532015-10-05 Richard Sandiford <richard.sandiford@arm.com>
2454
2455 * c-lex.c (interpret_float): Use real_equal instead of
2456 REAL_VALUES_EQUAL.
2457
b8fd7909
JM
24582015-10-04 Jason Merrill <jason@redhat.com>
2459
2460 Implement N4514, C++ Extensions for Transactional Memory.
2461 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
2462 (c_common_attribute_table): Add transaction_safe_dynamic.
2463 transaction_safe now affects type identity.
2464 (handle_tm_attribute): Handle transaction_safe_dynamic.
2465 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
2466 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
2467 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
2468 (D_TRANSMEM): New.
2469 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
2470 * c-pretty-print.c (pp_c_attributes_display): Don't print
2471 transaction_safe in C++.
2472
12651878
MP
24732015-10-02 Marek Polacek <polacek@redhat.com>
2474
2475 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
2476
3e3b8d63
MP
24772015-10-02 Marek Polacek <polacek@redhat.com>
2478
2479 PR c/64249
2480 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
2481 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
2482 * c.opt (Wduplicated-cond): New option.
2483
0d1a8f75
JM
24842015-10-01 Joseph Myers <joseph@codesourcery.com>
2485
2486 * c.opt (std=c11): Do not describe as experimental.
2487 (std=gnu11): Likewise.
2488 (std=iso9899:2011): Likewise.
2489
3e32ee19
NS
24902015-09-28 Nathan Sidwell <nathan@codesourcery.com>
2491
2492 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
2493 (DEF_FUNCTION_TYPE_VAR_11): Delete.
2494
974348ee
MP
24952015-09-25 Marek Polacek <polacek@redhat.com>
2496
2497 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
2498 (ubsan_instrument_shift): Likewise.
2499
15dbc1a6
MP
25002015-09-25 Marek Polacek <polacek@redhat.com>
2501
2502 PR sanitizer/64906
2503 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
2504
6b95d7cc
PP
25052015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
2506
2507 * c-indentation.c (should_warn_for_misleading_indentation):
2508 Compare next_stmt_vis_column with guard_line_first_nws instead
2509 of with guard_line_vis_column.
2510
c1822f9c
MLI
25112015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
2512
2513 PR c/49654
2514 PR c/49655
2515 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
2516 options and options not valid for the current language.
2517
d5398058
PP
25182015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
2519
2520 * c-indentation.c (should_warn_for_misleading_indentation):
2521 Float out and consolidate the calls to get_visual_column that
2522 are passed guard_exploc as an argument. Compare
2523 next_stmt_vis_column with guard_line_first_nws instead of with
2524 body_line_first_nws.
2525
6b333269
NS
25262015-09-22 Nathan Sidwell <nathan@codesourcery.com>
2527
2528 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
2529 Wnamespaces): New C++ warnings.
2530
a75f1574
JM
25312015-09-22 Jason Merrill <jason@redhat.com>
2532
2533 * c-common.h (abi_compat_version_crosses): New.
2534 (warn_abi_version): Declare.
2535 * c-common.c: Define it.
2536 * c-opts.c (c_common_post_options): Handle it.
2537 flag_abi_compat_version defaults to 8.
2538
bdaaa8b7
VV
25392015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
2540
2541 Complete the implementation of N4230, Nested namespace definition.
2542 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
2543 __cpp_nested_namespace_definitions.
2544
eaa797e8
MLI
25452015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
2546
2547 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
2548
c4914de6
MLI
25492015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
2550
2551 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
2552 when warning.
2553 * c-pragma.h (pragma_lex): Add optional loc argument.
2554
fcb87c50
MM
25552015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
2556
2557 * c-format.c (check_format_arg): Adjust to use common block size in all
2558 object pools.
2559
31bdd08a
DM
25602015-09-15 David Malcolm <dmalcolm@redhat.com>
2561
2562 * c-format.c (location_from_offset): Update for change in
2563 signature of location_get_source_line.
2564 * c-indentation.c (get_visual_column): Likewise.
2565 (line_contains_hash_if): Likewise.
2566
aa9f4b4c
MP
25672015-09-14 Marek Polacek <polacek@redhat.com>
2568
2569 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
2570 setting various warnings.
2571
aa256c4a
MP
25722015-09-14 Marek Polacek <polacek@redhat.com>
2573
2574 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
2575 a negative value.
2576
0f876f22
MW
25772015-09-11 Mark Wielaard <mjw@redhat.com>
2578
2579 PR c/28901
2580 * c.opt (Wunused-variable): Option from common.opt.
2581 (Wunused-const-variable): New option.
2582
273aa49e
PC
25832015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
2584
2585 PR c++/53184
2586 * c.opt ([Wsubobject-linkage]): Add.
2587
1807ffc1
MS
25882015-09-03 Martin Sebor <msebor@redhat.com>
2589
2590 PR c/66516
2591 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
2592 functions.
2593 * c-common.c (reject_gcc_builtin): Define.
2594
38942840
BI
25952015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
2596
2597 PR middle-end/60586
2598 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
2599 prototype.
2600 * c-gimplify.c (c_gimplify_expr): Added a call to the function
2601 cilk_gimplify_call_params_in_spawned_fn.
2602 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
2603 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
2604 unwrapping.
2605
c316b5e4
MP
26062015-08-25 Marek Polacek <polacek@redhat.com>
2607
2608 PR middle-end/67330
2609 * c-common.c (handle_weak_attribute): Don't check whether the
2610 visibility can be changed here.
2611
584a7c46
MLI
26122015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
2613
2614 * c-lex.c (c_lex_with_flags): Use explicit locations.
2615
a79683d5
TS
26162015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
2617
2618 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
2619 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
2620
61717a45
FXC
26212015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2622
2623 PR middle-end/36757
2624 * c-common.c (check_builtin_function_arguments): Add check
2625 for BUILT_IN_SIGNBIT argument.
2626
329524f5
PC
26272015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
2628
2629 PR c++/67160
2630 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
2631 in c++1z mode.
2632
4ee55665
MP
26332015-08-17 Marek Polacek <polacek@redhat.com>
2634
2635 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
2636 with whitespaces before qualifier names.
2637
b893e375
MP
26382015-08-12 Marek Polacek <polacek@redhat.com>
2639
2640 PR c++/55095
2641 * c-common.c (maybe_warn_shift_overflow): Properly handle
2642 left-shifting 1 into the sign bit.
2643
c2d89095
MLI
26442015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
2645
2646 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
2647
971e17ff
AS
26482015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
2649 Braden Obrzut <admin@maniacsvault.net>
2650 Jason Merrill <jason@redhat.com>
2651
2652 Add C++ Concepts TS support.
2653 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
2654 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
2655 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
2656 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
2657 * c-opts.c (set_std_cxx1z): Set flag_concepts.
2658 * c.opt (fconcepts): New.
2659
b3d5bc62
JJ
26602015-08-02 Martin Sebor <msebor@redhat.com>
2661
2662 * c.opt (-Wframe-address): New warning option.
2663
8ebca419
PP
26642015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
2665
2666 * c-indentation.c (should_warn_for_misleading_indentation):
2667 Improve heuristics.
2668
1a1e101f
PP
26692015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
2670
2671 * c-indentation.c (get_visual_column): Add parameter first_nws,
2672 use it. Update comment documenting the function.
2673 (is_first_nonwhitespace_on_line): Remove.
2674 (should_warn_for_misleading_indentation): Replace usage of
2675 of is_first_nonwhitespace_on_line with get_visual_column.
2676
992118a1
PP
26772015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
2678
2679 * c-indentation.h (struct token_indent_info): Define.
2680 (get_token_indent_info): Define.
2681 (warn_for_misleading_information): Declare.
2682 * c-common.h (warn_for_misleading_information): Remove.
2683 * c-identation.c (warn_for_misleading_indentation):
2684 Change declaration to take three token_indent_infos. Adjust
2685 accordingly.
2686 * c-identation.c (should_warn_for_misleading_indentation):
2687 Likewise. Bail out early if the body is a compound statement.
2688 (guard_tinfo_to_string): Define.
2689
e8fa3817
JM
26902015-07-30 Jason Merrill <jason@redhat.com>
2691
2692 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
2693 '*' for reference decay.
2694
173864e8
MP
26952015-07-30 Marek Polacek <polacek@redhat.com>
2696
2697 * c-common.c (warn_tautological_cmp): Bail for float types.
2698
f2afe6dd
MP
26992015-07-27 Marek Polacek <polacek@redhat.com>
2700
2701 PR bootstrap/67030
2702 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
2703
05b28fd6
MP
27042015-07-27 Marek Polacek <polacek@redhat.com>
2705
2706 PR c++/66555
2707 PR c/54979
2708 * c-common.c (find_array_ref_with_const_idx_r): New function.
2709 (warn_tautological_cmp): New function.
2710 * c-common.h (warn_tautological_cmp): Declare.
2711 * c.opt (Wtautological-compare): New option.
2712
5a5062b8
MP
27132015-07-23 Marek Polacek <polacek@redhat.com>
2714
2715 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
2716 (ubsan_instrument_shift): Likewise.
2717
dc891fe7
MP
27182015-07-23 Marek Polacek <polacek@redhat.com>
2719
2720 PR sanitizer/66908
2721 * c-ubsan.c: Include gimplify.h.
2722 (ubsan_instrument_division): Unshare OP0 and OP1.
2723 (ubsan_instrument_shift): Likewise.
2724
451b5e48
MP
27252015-07-20 Marek Polacek <polacek@redhat.com>
2726 Richard Sandiford <richard.sandiford@arm.com>
2727
2728 PR c++/55095
2729 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
2730 Use EXPR_LOC_OR_LOC.
2731 (maybe_warn_shift_overflow): New function.
2732 * c-common.h (maybe_warn_shift_overflow): Declare.
2733 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
2734 * c.opt (Wshift-overflow): New option.
2735
fb0b2914
ML
27362015-07-16 Martin Liska <mliska@suse.cz>
2737
2738 * c-format.c (static void check_format_info_main): Use
2739 object_allocator instead of pool_allocator.
2740 (check_format_arg): Likewise.
2741 (check_format_info_main): Likewise.
2742
903f5c23
AM
27432015-07-15 Andrew MacLeod <amacleod@redhat.com>
2744
2745 * c-opts.c: Remove multiline #include comment.
2746
026c3cfd
AH
27472015-07-12 Aldy Hernandez <aldyh@redhat.com>
2748
2749 * c-common.c: Fix double word typos.
2750
bb49ee66
EB
27512015-07-10 Eric Botcazou <ebotcazou@adacore.com>
2752
2753 * c-ada-spec.h (cpp_operation): Revert latest change.
2754 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
2755 constructors and destructors.
2756
1916bcb5
AM
27572015-07-09 Andrew MacLeod <amacleod@redhat.com>
2758
2759 * c-common.h: Adjust includes for flags.h changes.
2760 * stub-objc.c: Likewise.
026c3cfd 2761
a9dcd529
EB
27622015-07-08 Eric Botcazou <ebotcazou@adacore.com>
2763
2764 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
2765 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
2766
b03b462f
JJ
27672015-07-08 Jakub Jelinek <jakub@redhat.com>
2768
2769 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
2770 are to be removed, return NULL rather than original clauses list.
2771
c7131fb2
AM
27722015-07-07 Andrew MacLeod <amacleod@redhat.com>
2773
2774 * array-notation-common.c: Adjust includes.
2775 * c-ada-spec.c: Likewise.
2776 * c-cilkplus.c: Likewise.
2777 * c-common.h: Likewise.
2778 * c-cppbuiltin.c: Likewise.
2779 * c-dump.c: Likewise.
2780 * c-format.c: Likewise.
2781 * c-gimplify.c: Likewise.
2782 * c-indentation.c: Likewise.
2783 * c-lex.c: Likewise.
2784 * c-omp.c: Likewise.
2785 * c-opts.c: Likewise.
2786 * c-pch.c: Likewise.
2787 * c-ppoutput.c: Likewise.
2788 * c-pragma.c: Likewise.
2789 * c-pretty-print.c: Likewise.
2790 * c-semantics.c: Likewise.
2791 * c-ubsan.c: Likewise.
2792 * cilk.c: Likewise.
2793 * stub-objc.c: Likewise.
2794
2a7fb83f
EB
27952015-07-07 Eric Botcazou <ebotcazou@adacore.com>
2796
2797 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
2798 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
2799
a03c9bf1
JM
28002015-07-01 Jason Merrill <jason@redhat.com>
2801
36a85135
JM
2802 * c-common.h (D_CXX11): Rename from D_CXX0X.
2803 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
2804 * c-common.c: Adjust.
2805
e7fa68d5
JM
2806 * c-opts.c (c_common_post_options): Default to C++14.
2807
a03c9bf1
JM
2808 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
2809
fe95b036
ESR
28102015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
2811
2812 Implement N4197 - Adding u8 character literals
b3d5bc62 2813 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
a64be36b 2814 CPP_CHAR.
b3d5bc62 2815 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
a64be36b 2816 CPP_UTF8CHAR_USERDEF tokens.
b3d5bc62 2817 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
a64be36b
EB
2818 and CPP_UTF8CHAR tokens.
2819 (lex_charconst): Treat CPP_UTF8CHAR token.
fe95b036 2820
da2e71c9
MLI
28212015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
2822
2823 PR fortran/66605
2824 * c-common.c (do_warn_unused_parameter): Move here.
2825 * c-common.h (do_warn_unused_parameter): Declare.
2826
b155cfd9
MP
28272015-06-29 Marek Polacek <polacek@redhat.com>
2828
2829 PR c/66322
2830 * c-common.c (check_case_bounds): Add bool * parameter. Set
2831 OUTSIDE_RANGE_P.
2832 (c_add_case_label): Add bool * parameter. Pass it down to
2833 check_case_bounds.
2834 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
2835 warning here.
2836 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
2837 declarations.
2838
31521951
MP
28392015-06-27 Marek Polacek <polacek@redhat.com>
2840
2841 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
2842 or VECTOR_INTEGER_TYPE_P throughout.
2843 * c-gimplify.c: Likewise.
2844
22d03525
MP
28452015-06-26 Marek Polacek <polacek@redhat.com>
2846
2847 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
2848 * c-common.c (c_fully_fold_internal): Likewise.
2849 (c_alignof_expr): Likewise.
2850 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
2851 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
b1726d6c 2852 * cilk.c (create_parm_list): Likewise.
22d03525 2853
af05e6e5
MP
28542015-06-26 Marek Polacek <polacek@redhat.com>
2855
2856 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
2857
f0889939
AM
28582015-06-25 Andrew MacLeod <amacleod@redhat.com>
2859
2860 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
2861 * c-gimplify.c: Likewise.
2862 * c-pragma.c: Likewise.
2863 * c-ubsan.c: Likewise.
2864 * cilk.c: Likewise.
2865
ca752f39
RS
28662015-06-25 Richard Sandiford <richard.sandiford@arm.com>
2867
2868 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
2869 ggc_hasher.
2870
16a16ec7
AM
28712015-06-25 Andrew MacLeod <amacleod@redhat.com>
2872
2873 * cilk.c: Move calls.h after tm.h in the include chain.
2874
0ae9bd27
MP
28752015-06-25 Marek Polacek <polacek@redhat.com>
2876
2877 * array-notation-common.c: Use VAR_P throughout.
2878 * c-ada-spec.c: Likewise.
2879 * c-common.c: Likewise.
2880 * c-format.c: Likewise.
2881 * c-gimplify.c: Likewise.
2882 * c-omp.c: Likewise.
2883 * c-pragma.c: Likewise.
2884 * c-pretty-print.c: Likewise.
2885 * cilk.c: Likewise.
2886
62f9079a
MP
28872015-06-25 Marek Polacek <polacek@redhat.com>
2888
2889 * cilk.c (extract_free_variables): Use is_global_var.
2890
0fa16060
RS
28912015-06-23 Richard Sandiford <richard.sandiford@arm.com>
2892
2893 * c-common.c: Don't include target-def.h.
2894
a68ae2e1
MP
28952015-06-23 Marek Polacek <polacek@redhat.com>
2896
2897 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
2898 when comparing INTEGER_CSTs.
2899
c6a2f2d9
PMR
29002015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
2901
2902 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
2903 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
2904 (dump_ada_template): Skip partially specialized types.
2905
6b4db501
MM
29062015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
2907
2908 * c-common.c (scalar_to_vector): Use std::swap instead of manually
2909 swapping.
2910
abb226c9
AM
29112015-06-17 Andrew MacLeod <amacleod@redhat.com>
2912
2913 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
2914 * c-ada-spec.c: Likewise.
2915 * c-cilkplus.c: Likewise.
2916 * c-common.c: Likewise.
2917 * c-common.h: Likewise.
2918 * c-cppbuiltin.c: Likewise.
2919 * c-dump.c: Likewise.
2920 * c-format.c: Likewise.
2921 * c-gimplify.c: Likewise.
2922 * c-indentation.c: Likewise.
2923 * c-lex.c: Likewise.
2924 * c-omp.c: Likewise.
2925 * c-opts.c: Likewise.
2926 * c-pch.c: Likewise.
2927 * c-ppoutput.c: Likewise.
2928 * c-pragma.c: Likewise.
2929 * c-pretty-print.c: Likewise.
2930 * c-semantics.c: Likewise.
2931 * c-ubsan.c: Likewise.
2932 * cilk.c: Likewise.
2933 * stub-objc.c: Likewise.
2934
076fecad
PP
29352015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
2936
2937 PR c++/65168
2938 * c-common.c (c_common_truthvalue_conversion): Warn when
2939 converting an address of a reference to a truth value.
2940
13fdf2e2
AM
29412015-06-08 Andrew MacLeod <amacleod@redhat.com>
2942
2943 * array-notation-common.c : Adjust include files.
2944 * c-ada-spec.c : Likewise.
2945 * c-cilkplus.c : Likewise.
2946 * c-common.c : Likewise.
2947 * c-common.h : Likewise.
2948 * c-cppbuiltin.c : Likewise.
2949 * c-dump.c : Likewise.
2950 * c-format.c : Likewise.
2951 * c-gimplify.c : Likewise.
2952 * c-indentation.c : Likewise.
2953 * c-lex.c : Likewise.
2954 * c-omp.c : Likewise.
2955 * c-opts.c : Likewise.
2956 * c-pch.c : Likewise.
2957 * c-ppoutput.c : Likewise.
2958 * c-pragma.c : Likewise.
2959 * c-pretty-print.c : Likewise.
2960 * c-semantics.c : Likewise.
2961 * c-ubsan.c : Likewise.
2962 * cilk.c : Likewise.
2963 * stub-objc.c : Likewise.
2964
a1661b90
MP
29652015-06-08 Marek Polacek <polacek@redhat.com>
2966
2967 PR c/66415
2968 * c-format.c (location_from_offset): Return LOC if LINE is null.
2969
d7438551
AH
29702015-06-05 Aldy Hernandez <aldyh@redhat.com>
2971
2972 * c-common.h (c_parse_final_cleanups): New prototype.
2973 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
2974
b3d5bc62
JJ
29752015-06-04 Sriraman Tallam <tmsriram@google.com>
2976
2977 * c-common.c (noplt): New attribute.
2978 (handle_noplt_attribute): New handler.
2979
ecb9f223
AM
29802015-06-04 Andrew MacLeod <amacleod@redhat.com>
2981
2982 * array-notation-common.c: Adjust includes for restructured coretypes.h.
2983 * c-ada-spec.c: Likewise.
2984 * c-cilkplus.c: Likewise.
2985 * c-common.c: Likewise.
2986 * c-common.h: Likewise.
2987 * c-cppbuiltin.c: Likewise.
2988 * c-dump.c: Likewise.
2989 * c-format.c: Likewise.
2990 * c-gimplify.c: Likewise.
2991 * c-indentation.c: Likewise.
2992 * c-lex.c: Likewise.
2993 * c-omp.c: Likewise.
2994 * c-opts.c: Likewise.
2995 * c-pch.c: Likewise.
2996 * c-ppoutput.c: Likewise.
2997 * c-pragma.c: Likewise.
2998 * c-pretty-print.c: Likewise.
2999 * c-semantics.c: Likewise.
3000 * c-ubsan.c: Likewise.
3001 * cilk.c: Likewise.
3002 * stub-objc.c: Likewise.
3003
6ac48155
DM
30042015-06-02 David Malcolm <dmalcolm@redhat.com>
3005
3006 PR c/66220:
3007 * c-indentation.c (should_warn_for_misleading_indentation): Use
3008 expand_location rather than expand_location_to_spelling_point.
3009 Don't warn if the guarding statement is more indented than the
3010 next/body stmts.
3011
773ce42e
DM
30122015-06-02 David Malcolm <dmalcolm@redhat.com>
3013
3014 * c-indentation.c (warn_for_misleading_indentation): Bail out
3015 immediately if -Wmisleading-indentation isn't enabled.
3016
4fef8379
ML
30172015-06-01 Martin Liska <mliska@suse.cz>
3018
3019 * c-format.c (check_format_arg):Use new type-based pool allocator.
3020 (check_format_info_main) Likewise.
3021
1edfb384
EB
30222015-05-31 Eric Botcazou <ebotcazou@adacore.com>
3023
3024 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
3025 (has_nontrivial_methods): Likewise.
3026
9677ef52
MP
30272015-05-25 Marek Polacek <polacek@redhat.com>
3028
3029 * c-ubsan.c (ubsan_instrument_shift): Use type0.
3030
fd5c817a
MP
30312015-05-22 Marek Polacek <polacek@redhat.com>
3032
3033 PR c/47043
3034 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
3035
a2f45fe6 30362015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
581edfa3
TS
3037
3038 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
3039 STACK_GROWS_DOWNWARD.
3040
a2f45fe6 30412015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
62f9f30b
TS
3042
3043 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
3044 STACK_GROWS_DOWNWARD rather than if it is defined.
3045
0fee2ac2 30462015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
b1726d6c 3047
0fee2ac2
MLI
3048 PR c/52952
3049 * c-format.c (location_column_from_byte_offset): New.
3050 (location_from_offset): New.
3051 (struct format_wanted_type): Add offset_loc field.
3052 (check_format_info): Move handling of location for extra arguments
3053 closer to the point of warning.
3054 (check_format_info_main): Pass the result of location_from_offset
3055 to warning_at.
3056 (format_type_warning): Pass the result of location_from_offset
3057 to warning_at.
3058
cf4ef6f7
MP
30592015-05-20 Marek Polacek <polacek@redhat.com>
3060
3061 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
3062
3a65ee74
MP
30632015-05-20 Marek Polacek <polacek@redhat.com>
3064
3065 * c-ada-spec.c (dump_sloc): Use DECL_P.
3066
21b634ae
MP
30672015-05-20 Marek Polacek <polacek@redhat.com>
3068
3069 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
3070 * c-common.c: Likewise.
3071
0e50b624
DM
30722015-05-19 David Malcolm <dmalcolm@redhat.com>
3073
3074 * c-common.h (fe_file_change): Strengthen param from
3075 const line_map * to const line_map_ordinary *.
3076 (pp_file_change): Likewise.
3077 * c-lex.c (fe_file_change): Likewise.
3078 (cb_define): Use linemap_check_ordinary when invoking
3079 SOURCE_LINE.
3080 (cb_undef): Likewise.
3081 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
3082 invoking cb_file_change.
3083 (c_finish_options): Likewise.
3084 (push_command_line_include): Likewise.
3085 (cb_file_change): Strengthen param "new_map" from
3086 const line_map * to const line_map_ordinary *.
3087 * c-ppoutput.c (cb_define): Likewise for local "map".
3088 (pp_file_change): Likewise for param "map" and local "from".
3089
fab27f52
MM
30902015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
3091
3092 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
3093
2fe1d762
TV
30942015-05-18 Tom de Vries <tom@codesourcery.com>
3095
3096 * c-common.c (build_va_arg_1): New function.
3097 (build_va_arg): Add address operator to va_list operand if necessary.
3098
7a37fa90
MM
30992015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
3100
3101 PR c/48956
3102 * c-common.c (int_safely_convertible_to_real_p): Define.
3103 (unsafe_conversion_p): Check conversions involving complex types.
3104 (conversion_warning): Add new warning message for conversions which
3105 discard imaginary component.
3106 * c-common.h: (enum conversion_safety): Add new enumerator for such
3107 conversions.
3108
3aa3c9fc
MP
31092015-05-14 Marek Polacek <polacek@redhat.com>
3110
3111 PR c/66066
3112 PR c/66127
3113 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
3114 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
3115 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
3116 use it. If FOR_INT_CONST, require that all evaluated operands be
3117 INTEGER_CSTs.
3118
c3388e62
DM
31192015-05-12 David Malcolm <dmalcolm@redhat.com>
3120
3121 * c-common.h (warn_for_misleading_indentation): New prototype.
3122 * c-indentation.c: New file.
3123 * c.opt (Wmisleading-indentation): New option.
3124
c7b38fd5
TV
31252015-05-12 Tom de Vries <tom@codesourcery.com>
3126
3127 PR tree-optimization/66010
3128 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
3129
381bf11e
JM
31302015-05-09 Jason Merrill <jason@redhat.com>
3131
edff0c06
JM
3132 * c-opts.c (c_common_post_options): Also clear
3133 cpp_opts->cpp_warn_cxx11_compat.
3134
129211bc
JM
3135 * c-common.h (enum cxx_dialect): Add cxx_unset.
3136 * c-common.c (cxx_dialect): Initialize to cxx_unset.
3137 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
3138
381bf11e
JM
3139 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
3140 (std=gnu++0x): Mark as Undocumented.
3141 (std=gnu++1y): Add deprecated message.
3142
fe191308
JM
31432015-05-08 Jason Merrill <jason@redhat.com>
3144
765189ff
JM
3145 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
3146 * c-opts.c: Adjust.
3147
fe191308
JM
3148 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
3149
755e528f
MP
31502015-05-08 Marek Polacek <polacek@redhat.com>
3151
3152 PR c/64918
3153 * c.opt (Woverride-init-side-effects): New option.
3154
0173bd2a
MP
31552015-05-07 Marek Polacek <polacek@redhat.com>
3156
3157 PR c/65179
3158 * c-common.c (c_fully_fold_internal): Warn when left shifting a
3159 negative value.
3160 * c.opt (Wshift-negative-value): New option.
3161 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
3162 when -Wextra and C99/C++11 mode.
3163
e0f0d3b9
MP
31642015-05-07 Marek Polacek <polacek@redhat.com>
3165 Martin Uecker <uecker@eecs.berkeley.edu>
3166
3167 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
3168 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
3169
8243e2a9
JM
31702015-05-05 Jason Merrill <jason@redhat.com>
3171
3172 * c.opt (Wterminate): New.
3173
577cd070
MP
31742015-04-30 Marek Polacek <polacek@redhat.com>
3175
3176 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
3177 require that the non-constant be of a boolean type.
3178
0373796b
JT
31792015-04-29 Josh Triplett <josh@joshtriplett.org>
3180
e0f0d3b9
MP
3181 * c-common.c (handle_section_attribute): Refactor to reduce
3182 nesting and distinguish between error cases.
0373796b 3183
716c0ba6
MP
31842015-04-29 Marek Polacek <polacek@redhat.com>
3185
3186 PR c/64610
3187 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
3188 with 0/1.
3189
8848828b
JJ
31902015-04-29 Jakub Jelinek <jakub@redhat.com>
3191
3192 * c-common.h (omp_clause_mask): Unconditionally define as a class.
3193 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
3194 HOST_BITS_PER_WIDE_INT.
3195
ecd0e562
TV
31962015-04-28 Tom de Vries <tom@codesourcery.com>
3197
3198 PR tree-optimization/65887
3199 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
3200
2a877204 32012015-04-28 Eric Botcazou <ebotcazou@adacore.com>
e0f0d3b9 3202 Pierre-Marie de Rodat <derodat@adacore.com>
2a877204
EB
3203
3204 * c-ada-spec.c (in_function): Delete.
3205 (dump_generic_ada_node): Do not change in_function and remove the
3206 redundant code dealing with it.
3207 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
3208 (print_ada_methods): Output the static member functions in a nested
3209 package after the regular methods as well as associated renamings.
3210
4853031e
MP
32112015-04-24 Marek Polacek <polacek@redhat.com>
3212
3213 PR c/65830
3214 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
3215 and OPT_Wshift_count_overflow.
3216
8c2b7f79
MP
3217 PR c/63357
3218 * c-common.c (warn_logical_operator): Warn if the operands have the
3219 same expressions.
3220
b8787813
MP
32212015-04-24 Marek Polacek <polacek@redhat.com>
3222
3223 PR c/61534
3224 * c-common.c (warn_logical_operator): Bail if either operand comes
3225 from a macro expansion.
3226
8fba1830
BRF
32272015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
3228
3229 PR target/55143
3230 * c-common.c (c_default_pointer_mode): Add definition.
3231 * c-common.h (c_default_pointer_mode): Add declaration.
3232
17958621
JJ
32332015-03-11 Jakub Jelinek <jakub@redhat.com>
3234
3235 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
3236 on record_builtin_type argument.
3237
7ccb1a11
JJ
32382015-03-10 Jakub Jelinek <jakub@redhat.com>
3239
3240 PR c/65120
3241 * c-common.c (warn_logical_not_parentheses): Don't warn for
3242 !x == 0 or !x != 0.
3243
04fd785e
MP
32442015-03-07 Marek Polacek <polacek@redhat.com>
3245
3246 PR sanitizer/65280
3247 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
3248 before trying to figure out whether we have a flexible array member.
3249
a4e26206 32502015-03-06 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 3251 Jonathan Wakely <jwakely.gcc@gmail.com>
a4e26206
EB
3252
3253 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
3254
0d2489f4
EB
32552015-03-05 Eric Botcazou <ebotcazou@adacore.com>
3256
3257 PR ada/65319
3258 * c-ada-spec.c (print_destructor): Remove obsolete code.
3259
83ed54d7
EB
32602015-03-01 Eric Botcazou <ebotcazou@adacore.com>
3261
3262 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
3263 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
3264 DECL_TEMPLATE_RESULT emulations.
3265 (dump_ada_template)): Add guard for TYPE_METHODS.
3266
7631f0e2
MP
32672015-02-27 Marek Polacek <polacek@redhat.com>
3268
3269 PR c/65040
3270 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
3271
d1783ae5
KT
32722015-02-27 Kai Tietz <ktietz@redhat.com>
3273
3274 PR c/35330
3275 * c-pragma.c (handle_pragma_weak): Do not try to create
3276 weak/alias of declarations not being function, or variable
3277 declarations.
3278
56a9f6bc
TS
32792015-02-24 Thomas Schwinge <thomas@codesourcery.com>
3280
3281 PR libgomp/64625
3282 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
3283 Remove macros.
3284 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
3285
3d5cb23d
MP
32862015-02-16 Marek Polacek <polacek@redhat.com>
3287
3288 PR c/65066
3289 * c-format.c (check_format_types): Handle null param.
3290
fa008882
MP
32912015-02-13 Marek Polacek <polacek@redhat.com>
3292
3293 PR c/65040
3294 * c-format.c (check_format_types): Don't warn about different
3295 signedness if the original value is in the range of WANTED_TYPE.
3296
785f21af
JM
32972015-02-12 Jason Merrill <jason@redhat.com>
3298
3299 PR c++/64956
3300 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
3301 to the current highest version.
3302 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
3303
4886ec8e
JJ
33042015-02-04 Jakub Jelinek <jakub@redhat.com>
3305
3306 PR c/64824
3307 PR c/64868
3308 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
3309 instead of RDIV_EXPR. Use build_binary_op instead of
3310 build2_loc.
3311
40fecdd6
JM
33122015-01-30 Joseph Myers <joseph@codesourcery.com>
3313
3314 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
3315 to pass input_location as first argument.
3316
a0c88d06
TV
33172015-01-23 Tom de Vries <tom@codesourcery.com>
3318
3319 PR libgomp/64672
3320 * c.opt (fopenacc): Mark as LTO option.
3321
1506ae0e
TV
33222015-01-23 Tom de Vries <tom@codesourcery.com>
3323
3324 PR libgomp/64707
3325 * c.opt (fopenmp): Mark as LTO option.
3326
31be63ab
JJ
33272015-01-21 Jakub Jelinek <jakub@redhat.com>
3328
3329 PR c/63307
b1726d6c 3330 * cilk.c (fill_decls_vec): Only put decls into vector v.
31be63ab
JJ
3331 (compare_decls): Fix up formatting.
3332
33332015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
3334
3335 PR c/63307
3336 * cilk.c: Include vec.h.
3337 (struct cilk_decls): New structure.
3338 (wrapper_parm_cb): Split this function to...
3339 (fill_decls_vec): ...this...
3340 (create_parm_list): ...and this.
3341 (compare_decls): New function.
3342 (for_local_cb): Remove.
3343 (wrapper_local_cb): Ditto.
3344 (build_wrapper_type): For now first traverse and fill vector of
3345 declarations then sort it and then deal with sorted vector.
3346 (cilk_outline): Ditto.
3347 (declare_one_free_variable): Ditto.
3348
6875457f
JM
33492015-01-21 Jason Merrill <jason@redhat.com>
3350
3351 PR c++/64629
3352 * c-format.c (check_format_arg): Call decl_constant_value.
3353
185c9e56
ML
33542015-01-19 Martin Liska <mliska@suse.cz>
3355
3356 * c-common.c (handle_noicf_attribute): New function.
3357
41dbbb37
TS
33582015-01-15 Thomas Schwinge <thomas@codesourcery.com>
3359 Bernd Schmidt <bernds@codesourcery.com>
3360 James Norris <jnorris@codesourcery.com>
3361 Cesar Philippidis <cesar@codesourcery.com>
3362 Ilmir Usmanov <i.usmanov@samsung.com>
3363 Jakub Jelinek <jakub@redhat.com>
3364
3365 * c.opt (fopenacc): New option.
3366 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
3367 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
3368 New macros.
3369 * c-common.h (c_finish_oacc_wait): New prototype.
3370 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
3371 (c_finish_oacc_wait): New function.
3372 * c-pragma.c (oacc_pragmas): New variable.
3373 (c_pp_lookup_pragma, init_pragma): Handle it.
3374 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
3375 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
3376 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
3377 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
3378 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
3379 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
3380 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
3381 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
3382 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
3383 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
3384 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
3385 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
3386 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
3387 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
3388 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
3389 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
3390 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
3391 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
3392 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
3393 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
3394 PRAGMA_OACC_CLAUSE_WORKER.
3395
3f8257db 33962015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
5434dc07
MD
3397
3398 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
3399 for the new option fstack-protector_explicit.
3400 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
3401 (handle_stack_protect_attribute): New function.
3402
3f8257db 34032015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
de1b5c17
MU
3404
3405 * c.opt: New option -Warray-bounds=.
3406
adfac8df
JJ
34072015-01-09 Michael Collison <michael.collison@linaro.org>
3408
3409 * array-notation-common.c: Include hash-set.h, machmode.h,
3410 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3411 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
3412 * c-ada-spec.c: Ditto.
3413 * c-cilkplus.c: Ditto.
3414 * c-common.c: Include input.h due to flattening of tree.h.
3415 Define macro GCC_C_COMMON_C.
3416 * c-common.h: Flatten tree.h header files into c-common.h.
3417 Remove include of tree-core.h.
3418 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
3419 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3420 fold-const.h, wide-int.h, and inchash.h due to
3421 flattening of tree.h.
3422 * c-dump.c: Ditto.
3423 * c-format.c: Flatten tree.h header files into c-common.h.
3424 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
3425 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3426 fold-const.h, wide-int.h, and inchash.h due to
3427 flattening of tree.h.
3428 * c-dump.c: Include hash-set.h, machmode.h,
3429 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3430 fold-const.h, wide-int.h, and inchash.h due to
3431 flattening of tree.h.
3432 * c-format.c: Include hash-set.h, machmode.h,
3433 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3434 fold-const.h, wide-int.h, inchash.h and real.h due to
3435 flattening of tree.h.
3436 * c-gimplify.c: Include hash-set.h, machmode.h,
3437 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
3438 fold-const.h, wide-int.h, and inchash.h due to
3439 flattening of tree.h.
3440 * cilk.c: Ditto.
3441 * c-lex.c: Ditto.
3442 * c-omp.c: Ditto.
3443 * c-opts.c: Ditto.
3444 * c-pch.c: Ditto.
3445 * c-ppoutput.c: Ditto.
3446 * c-pragma.c: Ditto.
3447 * c-pretty-print.c: Ditto.
3448 * c-semantics.c: Ditto.
3449 * c-ubsan.c: Ditto.
3450 * stub-objc.c: Ditto.
3451
f5481fc4
JM
34522015-01-08 Jason Merrill <jason@redhat.com>
3453
3454 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
3455 do_ubsan_in_current_function.
3456 (ubsan_maybe_instrument_reference_or_call): Likewise.
3457 * c-ubsan.h: Declare it.
3458
de35aa66
MS
34592015-01-08 Mike Stump <mikestump@comcast.net>
3460
3461 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
3462
4a9a42ab
MP
34632015-01-07 Marek Polacek <polacek@redhat.com>
3464
3465 PR c/64440
3466 * c-common.c (c_fully_fold_internal): Warn for division and modulo
3467 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
3468
2f42e5de
TS
34692015-01-05 Trevor Saunders <tsaunders@mozilla.com>
3470
3471 PR c++/31397
3472 * c.opt (Wsuggest-override): New option.
3473
5624e564
JJ
34742015-01-05 Jakub Jelinek <jakub@redhat.com>
3475
3476 Update copyright years.
3477
5bd012f8
MP
34782015-01-05 Marek Polacek <polacek@redhat.com>
3479
3480 PR c/64423
3481 * c-common.c (warn_array_subscript_with_type_char): Add location_t
3482 parameter. Use it.
3483 * c-common.h (warn_array_subscript_with_type_char): Update
3484 declaration.
3485
a7fa8d18
ESR
34862014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
3487
3488 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
3489 Control macro with flag_sized_deallocation.
3490
3f8257db 34912014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
768952be
MU
3492
3493 * c.opt (Wdiscarded-array-qualifiers): New option.
3494
1f8d3e84
JJ
34952014-12-19 Jakub Jelinek <jakub@redhat.com>
3496
3497 PR preprocessor/63831
3498 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
3499 and __has_cpp_attribute here.
3500 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
3501 c_common_has_attribute.
3502 * c-common.h (c_common_has_attribute): New prototype.
3503 * c-lex.c (init_c_lex): Set cb->has_attribute to
3504 c_common_has_attribute instead of cb_has_attribute.
3505 (get_token_no_padding): New function.
3506 (cb_has_attribute): Renamed to ...
3507 (c_common_has_attribute): ... this. No longer static. Use
3508 get_token_no_padding, require ()s, don't build TREE_LIST
3509 unnecessarily, fix up formatting, adjust diagnostics, call
3510 init_attributes.
3511
20b06add
JM
35122014-12-15 Jason Merrill <jason@redhat.com>
3513
3514 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
3515 (-Wsized-deallocation): New.
3516 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
3517 to on in C++14 and up.
3518
94a073b2
JM
35192014-12-11 Jason Merrill <jason@redhat.com>
3520
acaa5911
JM
3521 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
3522
94a073b2
JM
3523 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
3524 we aren't complaining about VLAs.
3525
7fb66c15
MP
35262014-12-06 Marek Polacek <polacek@redhat.com>
3527
3528 PR tree-optimization/64183
3529 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
3530 shift-expression if it is integer_type_node. Use types_compatible_p.
3531
b731b390
JJ
35322014-11-29 Jakub Jelinek <jakub@redhat.com>
3533
3534 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
3535 last argument from create_tmp_var_raw and create_tmp_var calls.
3536 * cilk.c (gimplify_cilk_spawn): Likewise.
3537 * c-omp.c (c_finish_omp_atomic): Likewise.
3538
6a4da643
MP
35392014-11-28 Marek Polacek <polacek@redhat.com>
3540
3541 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
3542 instead of unsigned_type_node.
3543
541e35a6
MP
35442014-11-28 Marek Polacek <polacek@redhat.com>
3545
3546 PR c/63862
3547 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
3548 to op1_utype.
3549 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
3550 expression to unsigned_type_node.
3551
dcc97066
MW
35522014-11-20 Mark Wielaard <mjw@redhat.com>
3553
3554 PR debug/38757
3555 * c-opts.c (set_std_c89): Set lang_hooks.name.
3556 (set_std_c99): Likewise.
3557 (set_std_c11): Likewise.
3558 (set_std_cxx98): Likewise.
3559 (set_std_cxx11): Likewise.
3560 (set_std_cxx14): Likewise.
3561 (set_std_cxx1z): Likewise.
3562
aa7da51a
JJ
35632014-11-21 Jakub Jelinek <jakub@redhat.com>
3564
3565 PR target/63764
3566 * c-common.h (convert_vector_to_pointer_for_subscript): Change
3567 return type to bool.
009a3480 3568 * c-common.c: Include gimple-expr.h.
aa7da51a
JJ
3569 (convert_vector_to_pointer_for_subscript): Change return type to
3570 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
3571 and copy it into a TARGET_EXPR and use that instead of *vecp
3572 directly.
3573
538dd0b7
DM
35742014-11-19 David Malcolm <dmalcolm@redhat.com>
3575
3576 Merger of git branch "gimple-classes-v2-option-3".
3577 * ChangeLog.gimple-classes: New.
3578 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
3579 from being just a vec<gimple> to a vec<gbind *>.
3580
c39a5e99
JJ
35812014-11-18 Jakub Jelinek <jakub@redhat.com>
3582
3583 PR sanitizer/63813
3584 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
3585 argument to ptype, set type to TREE_TYPE (ptype). Don't call
3586 get_pointer_alignment for non-pointers. Use ptype, or if it is
3587 reference type, corresponding pointer type, as type of kind
3588 argument.
3589 (ubsan_maybe_instrument_reference,
3590 ubsan_maybe_instrument_member_call): Adjust callers.
3591
8537a4a9
MP
35922014-11-15 Marek Polacek <polacek@redhat.com>
3593
3594 PR middle-end/63884
3595 * array-notation-common.c (is_sec_implicit_index_fn): Return false
3596 for NULL fndecl.
3597 (extract_array_notation_exprs): Return for NULL node.
3598
2079956a
JM
35992014-11-12 Joseph Myers <joseph@codesourcery.com>
3600
3601 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
3602 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
3603
1304953e
JJ
36042014-11-12 Jakub Jelinek <jakub@redhat.com>
3605
3606 PR c/59708
3607 * c-common.c (check_builtin_function_arguments): Handle
3608 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
3609
e5e44252
AK
36102014-11-10 Andi Kleen <ak@linux.intel.com>
3611
3612 PR c/60804
3613 * c-common.h (check_no_cilk): Declare.
3614 * cilk.c (get_error_location): New function.
3615 (check_no_cilk): Dito.
3616
e64b984d
AK
36172014-11-10 Andi Kleen <ak@linux.intel.com>
3618
3619 * cilk.c (recognize_spawn): Use expression location
3620 for error message.
3621
13c21655
PC
36222014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
3623
3624 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
3625
42fd12b1
ESR
36262014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
3627
3628 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
3629 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
3630 (__cpp_range_based_for, __cpp_initializer_lists,
3631 __cpp_delegating_constructors, __cpp_nsdmi,
3632 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
3633 for C++11; (__cpp_attribute_deprecated): Remove in favor of
3634 __has_cpp_attribute.
3635 * c-lex.c (cb_has_attribute): New callback CPP function;
3636 (init_c_lex): Set has_attribute callback.
3637
6f450181
RB
36382014-11-04 Richard Biener <rguenther@suse.de>
3639
3640 * c-common.c (shorten_compare): Do not shorten mixed
3641 DFP and non-DFP compares.
3642
26f0e1d6
ESR
36432014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
3644
3645 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
3646 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
3647 Commentary and rearrangement of tests.
3648 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
3649 Commentary and rearrangement of tests.
3650 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto
3651 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
3652
ef4bddc2
RS
36532014-10-29 Richard Sandiford <richard.sandiford@arm.com>
3654
3655 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
3656 enum from machine_mode.
3657
c582198b
AM
36582014-10-28 Andrew MacLeod <amacleod@redhat.com>
3659
adfac8df
JJ
3660 * c-common.c: Adjust include files.
3661 * c-gimplify.c: Ditto.
3662 * cilk.c: Ditto.
3663 * c-pragma.c: Ditto.
3664 * c-ubsan.c: Ditto.
c582198b 3665
60393bbc
AM
36662014-10-27 Andrew MacLeod <amacleod@redhat.com>
3667
3668 * c-gimplify.c: Adjust include files.
3669
d723bb7c
MLI
36702014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
3671
3672 PR c++/53061
3673 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
3674 c_common_initialize_diagnostics.
3675 * c-common.h: Likewise.
3676
90f3520e
MP
36772014-10-24 Marek Polacek <polacek@redhat.com>
3678
3679 PR c/56980
3680 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
3681 print "struct"/"union"/"enum" for typedefed names.
3682
59d7607a
MP
36832014-10-23 Marek Polacek <polacek@redhat.com>
3684
3685 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
3686 in unsigned type.
3687
d95a2703
JJ
36882014-10-22 Jakub Jelinek <jakub@redhat.com>
3689 Yury Gribov <y.gribov@samsung.com>
3690
3691 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
3692 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
3693 instead of flag_sanitize_recover as bool flag.
3694
8e6ef852
KY
36952014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
3696
3697 * cilk.c: Revert previous change.
3698
948cf550
IZ
36992014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
3700
3701 PR c/63307
3702 * cilk.c: Include vec.h.
3703 (struct cilk_decls): New structure.
3704 (wrapper_parm_cb): Split this function to...
3705 (fill_decls_vec): ...this...
3706 (create_parm_list): ...and this.
3707 (compare_decls): New function.
3708 (for_local_cb): Remove.
3709 (wrapper_local_cb): Ditto.
3710 (build_wrapper_type): For now first traverse and fill vector of
3711 declarations then sort it and then deal with sorted vector.
3712 (cilk_outline): Ditto.
3713 (declare_one_free_variable): Ditto.
3714
92574c7c
MP
37152014-10-17 Marek Polacek <polacek@redhat.com>
3716
3717 * c-opts.c (c_common_post_options): Set warn_implicit_int.
3718 * c.opt (Wimplicit-int): Initialize to -1.
3719
83685514
AM
37202014-10-16 Andrew MacLeod <amacleod@redhat.com>
3721
3722 * c-pragma.c: Adjust include files.
3723 * c-semantics.c: Likewise.
3724
5b8300ea
DD
37252014-10-16 DJ Delorie <dj@redhat.com>
3726
3727 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
3728 multiples of bytes.
3729
5f83e90b
JM
37302014-10-14 Jason Merrill <jason@redhat.com>
3731
3732 PR c++/63455
3733 * c-common.h (CPP_PREPARSED_EXPR): New.
3734 (N_CP_TTYPES): Adjust.
3735
d73326ca
MP
37362014-10-15 Marek Polacek <polacek@redhat.com>
3737
3738 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
3739
78a7c317
DD
37402014-10-14 DJ Delorie <dj@redhat.com>
3741
3742 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
3743 types, not just __int128.
3744 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
3745 types, not just __int128.
3746 (cpp_atomic_builtins): Round pointer sizes up.
3747 (type_suffix): Use type precision, not specific types.
3748 * c-common.c (c_common_reswords): Remove __int128 special case.
3749 (c_common_type_for_size): Check for all __intN types, not just
3750 __int128.
3751 (c_common_type_for_mode): Likewise.
3752 (c_common_signed_or_unsigned_type): Likewise.
3753 (c_build_bitfield_integer_type): Likewise.
3754 (c_common_nodes_and_builtins): Likewise.
3755 (keyword_begins_type_specifier): Likewise.
3756 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
3757 __intN variants.
3758
2a22f99c
TS
37592014-10-12 Trevor Saunders <tsaunders@mozilla.com>
3760
3761 * c-common.c: Use hash_table instead of hashtab.
3762
2a8ef767
ESR
37632014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
3764
adfac8df 3765 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
2a8ef767
ESR
3766 C++11 section.
3767
3c9aabbd
MG
37682014-10-03 Marc Glisse <marc.glisse@inria.fr>
3769
3770 PR c++/54427
3771 PR c++/57198
3772 PR c++/58845
3773 * c-common.c (warn_logical_operator): Punt for vectors.
3774
a15f7cb8
ESR
37752014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
3776
3777 Implement SD-6: SG10 Feature Test Recommendations
3778 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
3779 macros and the __has_header macro.
3780
8d0cf15e
JM
37812014-09-30 Jason Merrill <jason@redhat.com>
3782
dd5d5481
JM
3783 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
3784 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
3785 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
3786
b752325e
JM
3787 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
3788 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
3789
8d0cf15e
JM
3790 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
3791 * c-common.c (c_common_reswords): Remove __is_convertible_to.
3792
083e891e
MP
37932014-09-24 Marek Polacek <polacek@redhat.com>
3794
3795 PR c/61405
3796 PR c/53874
3797 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
3798
7861b648
AK
37992014-09-23 Andi Kleen <ak@linux.intel.com>
3800
3801 * c-common.c (handle_no_reorder_attribute): New function.
3802 (c_common_attribute_table): Add no_reorder attribute.
3803
9a79452d
JM
38042014-09-22 Joseph Myers <joseph@codesourcery.com>
3805
3806 * c-cppbuiltin.c (c_cpp_builtins): Define
3807 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
3808 modes.
3809
dd69f047
JM
38102014-09-18 Joseph Myers <joseph@codesourcery.com>
3811
3812 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
3813 for supported floating-point modes.
3814
737a4826
MLI
38152014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
3816
3817 * c.opt (Wpsabi): Use LangEnabledBy.
3818 * c-opts.c (c_common_handle_option): Do not handle here.
3819
8cc4b7a2
JM
38202014-09-12 Joseph Myers <joseph@codesourcery.com>
3821
3822 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
3823 macros for floating-point modes.
3824
179b5a55
MG
38252014-09-11 Marc Glisse <marc.glisse@inria.fr>
3826
3827 PR target/58757
3828 * c-cppbuiltin.c (builtin_define_float_constants): Correct
3829 __*_DENORM_MIN__ without denormals.
3830
570a11fe
JJ
38312014-09-10 Jakub Jelinek <jakub@redhat.com>
3832
3833 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
3834 ubsan_instrument_vla, ubsan_instrument_return): Adjust
3835 ubsan_create_data callers.
3836 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
3837 index is constant or BIT_AND_EXPR with constant mask and is
3838 small enough for the bound.
3839 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
3840 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
3841
b559c810
MLI
38422014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
3843
3844 * c.opt: Add CppReason to various flags.
3845 (Wdate-time): Re-sort.
3846 * c-common.c: Include c-common.h earlier.
3847 (struct reason_option_codes_t): Delete.
3848 (c_option_controlling_cpp_error): Prefix global type and struct
3849 with cpp_.
3850
1ef33fd4
MLI
38512014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
3852
3853 * c.opt (Wnormalized): New.
3854 (Wnormalized=): Use Enum and Reject Negative.
3855 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
3856
66bb34c0
JM
38572014-09-08 Joseph Myers <joseph@codesourcery.com>
3858
3859 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
3860 digits of floating-point modes if -fbuilding-libgcc.
3861
53d68b9f
JM
38622014-09-05 Joseph Myers <joseph@codesourcery.com>
3863
3864 * c-cppbuiltin.c (c_cpp_builtins): Also define
3865 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
3866 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
3867 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
3868 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
3869 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
3870 __LIBGCC_STACK_GROWS_DOWNWARD__,
3871 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
3872 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
3873 __LIBGCC_DWARF_FRAME_REGISTERS__,
3874 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
3875 __LIBGCC_STACK_POINTER_REGNUM__ and
3876 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
3877 (builtin_define_with_value): Handle backslash-escaping in string
3878 macro values.
3879
f65586dc
RB
38802014-09-05 Richard Biener <rguenther@suse.de>
3881
3882 PR middle-end/63148
3883 * c-format.c (check_format_arg): Properly handle
3884 effectively signed POINTER_PLUS_EXPR offset.
3885
2b71f4a4
MLI
38862014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
3887
3888 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
3889 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
3890 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
3891 and Init.
3892 * c-opts.c (c_common_handle_option): Do not handle here.
3893 (sanitize_cpp_opts): Likewise.
3894 * c-common.c (struct reason_option_codes_t): Handle
3895 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
3896
d2e4feca
MP
38972014-09-03 Marek Polacek <polacek@redhat.com>
3898
3899 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
3900
9a771876
JJ
39012014-09-02 Jakub Jelinek <jakub@redhat.com>
3902 Balaji V. Iyer <balaji.v.iyer@intel.com>
3903 Igor Zamyatin <igor.zamyatin@intel.com>
3904
3905 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
3906 * c-common.c (c_common_reswords): Added _Cilk_for.
3907 * c-common.h (enum rid): Added RID_CILK_FOR.
3908 (cilk_for_number_of_iterations): Add declaration.
3909 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
3910 CILK_FOR.
3911 * c-pragma.c (init_pragma): Register "grainsize" pragma.
3912 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
3913
81b5d104
MLI
39142014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
3915
3916 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
3917 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
3918 Wundef): Use CPP, Var and Init.
3919 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
3920
b753b37b
MLI
39212014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
3922
3923 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
3924 * c-opts.c (c_common_handle_option): Do not handle here.
3925
028aee17
JM
39262014-08-25 Jason Merrill <jason@redhat.com>
3927
3928 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
3929 -std=c++14 and -std=gnu++14, rather than the reverse.
3930 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
3931 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
3932 * c-common.h (cxx_dialect): Remove cxx1y.
3933
e4276ba5
ESR
39342014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
3935
3936 * c-common.h (enum cxx_dialect): Add cxx14.
3937 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
3938 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
3939 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
3940
a545cacd
JM
39412014-08-22 Jason Merrill <jason@redhat.com>
3942
3943 * c.opt (std=gnu++17): Fix alias.
3944
59ea0364
MP
39452014-08-22 Marek Polacek <polacek@redhat.com>
3946
3947 PR c++/62199
3948 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
3949 check for vector types. Drop LHS argument.
3950 * c-common.h (warn_logical_not_parentheses): Adjust.
3951
596e808c
MLI
39522014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
3953
3954 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
3955 (Wmultichar): Likewise.
3956 (Wdate-time): Use C-family languages instead of Common. Use CPP
3957 and Var.
3958 * c-opts.c (c_common_handle_option): Do not handle the above
3959 options here.
3960 (sanitize_cpp_opts): Likewise.
3961
18767f65
MLI
39622014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
3963
3964 PR fortran/44054
3965 * c-opts.c: Include tree-diagnostics.h.
3966 (c_diagnostic_finalizer): New.
3967 (c_common_initialize_diagnostics): Use it.
3968
b4413594
MLI
39692014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
3970
3971 PR preprocessor/51303
3972 * c-common.c (struct reason_option_codes_t option_codes):
3973 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
3974
43f9a13c
MLI
39752014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
3976
3977 PR c/60975
3978 PR c/53063
3979 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
3980 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
3981 (c_common_post_options): Call init_global_opts_from_cpp.
3982 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
3983
04159acf
MP
39842014-08-19 Marek Polacek <polacek@redhat.com>
3985
3986 PR c++/62153
3987 * c-common.c (maybe_warn_bool_compare): New function.
3988 * c-common.h (maybe_warn_bool_compare): Declare.
3989 * c.opt (Wbool-compare): New option.
3990
35aff4fb
MP
39912014-08-19 Marek Polacek <polacek@redhat.com>
3992
3993 * c.opt (Wc99-c11-compat): New option.
3994
177cce46
MP
39952014-08-19 Marek Polacek <polacek@redhat.com>
3996
3997 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
3998 to warn_c90_c99_compat.
3999 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
4000 to -1.
4001
6ae9194f
MLI
40022014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
4003 Steven Bosscher <steven@gcc.gnu.org>
4004
4005 PR c/52952
4006 * c-format.c: Add extra_arg_loc and format_string_loc to struct
4007 format_check_results.
4008 (check_function_format): Use true and add comment for boolean
4009 argument.
4010 (finish_dollar_format_checking): Use explicit location when warning.
4011 (check_format_info): Likewise.
4012 (check_format_arg): Set extra_arg_loc and format_string_loc.
4013 (check_format_info_main): Use explicit location when warning.
4014 (check_format_types): Pass explicit location.
4015 (format_type_warning): Likewise.
4016
8e54f6d3
MLI
40172014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
4018
4019 PR fortran/44054
4020 * c-format.c: Handle Fortran flags.
4021
cd4e76fc
IZ
40222014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
4023
4024 PR other/61962
4025 * array-notation-common.c (find_rank): Added handling for other
4026 types of references.
4027
f3bede71
MP
40282014-08-10 Marek Polacek <polacek@redhat.com>
4029
4030 PR c/51849
4031 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
4032 * c.opt (Wc90-c99-compat): Add option.
4033
9f25a338
TS
40342014-08-07 Trevor Saunders <tsaunders@mozilla.com>
4035
4036 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
4037
62e4eb35
MP
40382014-08-03 Marek Polacek <polacek@redhat.com>
4039
4040 * c-common.c (check_case_value): Add location_t parameter. Use it.
4041 (c_add_case_label): Pass loc to check_case_value.
4042
b787e7a2
TS
40432014-08-02 Trevor Saunders <tsaunders@mozilla.com>
4044
4045 * cilk.c: Use hash_map instead of pointer_map.
4046
6e2830c3
TS
40472014-08-02 Trevor Saunders <tsaunders@mozilla.com>
4048
4049 * c-gimplify.c: Use hash_set instead of pointer_set.
4050
a7ee52fb
IZ
40512014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
4052
4053 PR middle-end/61455
4054 * array-notation-common.c (extract_array_notation_exprs): Handling
4055 of DECL_EXPR added.
4056
944fa280
JJ
40572014-08-01 Jakub Jelinek <jakub@redhat.com>
4058
4059 * c-common.h (min_align_of_type): Removed prototype.
4060 * c-common.c (min_align_of_type): Removed.
4061 * c-ubsan.h (ubsan_maybe_instrument_reference,
4062 ubsan_maybe_instrument_member_call): New prototypes.
4063 * c-ubsan.c: Include stor-layout.h and builtins.h.
4064 (ubsan_maybe_instrument_reference_or_call,
4065 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
4066 functions.
4067
b4dfdc11
MG
40682014-07-31 Marc Glisse <marc.glisse@inria.fr>
4069
4070 PR c++/60517
4071 * c.opt (-Wreturn-local-addr): Move to common.opt.
4072
a41844e5
JM
40732014-07-30 Jason Merrill <jason@redhat.com>
4074
4075 PR c++/61659
4076 PR c++/61687
4077 Revert:
4078 * c.opt (-fuse-all-virtuals): New.
4079
976d5a22
TT
40802014-07-30 Tom Tromey <tromey@redhat.com>
4081
4082 PR c/59855
4083 * c.opt (Wdesignated-init): New option.
4084 * c-common.c (c_common_attribute_table): Add "designated_init".
4085 (handle_designated_init): New function.
4086
cdc94aca
MP
40872014-07-24 Marek Polacek <polacek@redhat.com>
4088
4089 PR c/57653
4090 * c-opts.c (c_finish_options): If -imacros is in effect, return.
4091
f41373b6
DS
40922014-07-16 Dodji Seketeli <dodji@redhat.com>
4093
4094 PR preprocessor/60723 - missing system-ness marks for macro tokens
4095 * c-ppoutput.c (struct print::prev_was_system_token): New data
4096 member.
4097 (init_pp_output): Initialize it.
4098 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
4099 (do_line_change): Return a flag saying if a line marker was
4100 emitted or not.
4101 (scan_translation_unit): Detect if the system-ness of the token we
4102 are about to emit is different from the one of the previously
4103 emitted token. If so, emit a line marker. Avoid emitting useless
4104 adjacent line markers. Avoid emitting line markers for tokens
4105 originating from the expansion of built-in macros.
4106 (scan_translation_unit_directives_only): Adjust.
4107
4d661eaa
MP
41082014-07-15 Marek Polacek <polacek@redhat.com>
4109
4110 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
4111 TYPE_MAX_VALUE is NULL.
4112
b108f48f
JJ
41132014-07-14 Jakub Jelinek <jakub@redhat.com>
4114
4115 PR middle-end/61294
4116 * c.opt (Wmemset-transposed-args): New warning.
4117
c0221884
JM
41182014-07-10 Jason Merrill <jason@redhat.com>
4119
4120 PR c++/61659
4121 PR c++/61687
4122 * c.opt (-fuse-all-virtuals): New.
4123
63dfbb95
RB
41242014-07-09 Richard Biener <rguenther@suse.de>
4125
4126 PR c-family/61741
4127 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
4128 using unsigned arithmetic if overflow does not wrap instead of
4129 if overflow is undefined.
4130
773ec47f
MP
41312014-07-06 Marek Polacek <polacek@redhat.com>
4132
4133 PR c/6940
4134 * c.opt (Wsizeof-array-argument): New option.
4135
00a7ba58
JJ
41362014-07-03 Jakub Jelinek <jakub@redhat.com>
4137
b1726d6c 4138 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
00a7ba58
JJ
4139 comments->count <= 1, as comments->entries might be NULL.
4140
52ec0ea3
MP
41412014-07-01 Marek Polacek <polacek@redhat.com>
4142
4143 * c.opt (Wint-conversion): New option.
4144
d5c3d343
MP
41452014-07-01 Marek Polacek <polacek@redhat.com>
4146
4147 PR c/58286
4148 * c.opt (Wincompatible-pointer-types): New option.
4149
6e7ceb17
PC
41502014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
4151
4152 PR c++/51400
4153 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
4154 Do not discard TYPE_QUALS of type.
4155
da73100b
JM
41562014-06-26 Jason Merrill <jason@redhat.com>
4157
4158 * c-common.h (enum cxx_dialect): Add cxx1z.
4159 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
4160 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
4161
08eedf75
TJ
41622014-06-26 Teresa Johnson <tejohnson@google.com>
4163
4164 * c-common.h (get_dump_info): Declare.
4165 * c-gimplify.c (c_genericize): Use saved dump files.
4166 * c-opts.c (c_common_parse_file): Begin and end dumps
4167 once around parsing invocation.
4168 (get_dump_info): New function.
4169
7b56b2f8
MP
41702014-06-23 Marek Polacek <polacek@redhat.com>
4171 Andrew MacLeod <amacleod@redhat.com>
4172
4173 PR c/61553
4174 * c-common.c (get_atomic_generic_size): Don't segfault if the
4175 type doesn't have a size.
4176
0e37a2f3
MP
41772014-06-20 Marek Polacek <polacek@redhat.com>
4178
4179 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
4180 (ubsan_walk_array_refs_r): New function.
4181 (c_genericize): Instrument array bounds.
4182 * c-ubsan.c: Include "internal-fn.h".
4183 (ubsan_instrument_division): Mark instrumented arrays as having
4184 side effects. Adjust ubsan_type_descriptor call.
4185 (ubsan_instrument_shift): Likewise.
4186 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
4187 (ubsan_instrument_bounds): New function.
4188 (ubsan_array_ref_instrumented_p): New function.
4189 (ubsan_maybe_instrument_array_ref): New function.
4190 * c-ubsan.h (ubsan_instrument_bounds): Declare.
4191 (ubsan_array_ref_instrumented_p): Declare.
4192 (ubsan_maybe_instrument_array_ref): Declare.
4193
41942014-06-20 Hale Wang <hale.wang@arm.com>
dd6fe7d4
HW
4195
4196 PR lto/61123
4197 * c.opt (fshort-enums): Add to LTO.
4198 * c.opt (fshort-wchar): Likewise.
4199
5c3d09f7
MP
42002014-06-16 Marek Polacek <polacek@redhat.com>
4201
4202 PR c/60439
4203 * c.opt (Wswitch-bool): Add Var.
4204
9cf32741
JJ
42052014-06-12 Jakub Jelinek <jakub@redhat.com>
4206
4207 PR middle-end/61486
4208 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
4209 #pragma omp target teams or
4210 #pragma omp {,target }teams distribute simd.
4211
62984918
JM
42122014-06-12 Jason Merrill <jason@redhat.com>
4213
4214 * c.opt (Wabi=, fabi-compat-version): New.
4215 * c-opts.c (c_common_handle_option): Handle -Wabi=.
4216 (c_common_post_options): Handle flag_abi_compat_version default.
4217 Disallow -fabi-compat-version=1.
4218 * c-common.h (abi_version_crosses): New.
4219
f961457f
JH
42202014-06-11 Jan Hubicka <hubicka@ucw.cz>
4221
adfac8df 4222 * c-common.c (handle_section_attribute): Update handling for
f961457f
JH
4223 section names that are no longer trees.
4224
92d28cbb
JJ
42252014-06-10 Jakub Jelinek <jakub@redhat.com>
4226
4227 PR fortran/60928
4228 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
4229 (omp_pragmas): ... back here.
4230
742938c9
MP
42312014-06-05 Marek Polacek <polacek@redhat.com>
4232
4233 PR c/49706
4234 * c-common.c (warn_logical_not_parentheses): New function.
4235 * c-common.h (warn_logical_not_parentheses): Declare.
4236 * c.opt (Wlogical-not-parentheses): New option.
4237
9d548dfb
MP
42382014-06-04 Marek Polacek <polacek@redhat.com>
4239
4240 PR c/30020
4241 * c-common.c (check_case_bounds): Add location parameter.
4242 Use it.
4243 (c_add_case_label): Pass loc to check_case_bounds.
4244
fedfecef
MP
42452014-06-03 Marek Polacek <polacek@redhat.com>
4246
4247 PR c/60439
4248 * c.opt (Wswitch-bool): New option.
4249
f6a7cffc
TS
42502014-05-22 Thomas Schwinge <thomas@codesourcery.com>
4251
040d18b6
TS
4252 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
4253 Remove prototypes.
4254 (record_types_used_by_current_var_decl): Move prototype to where
4255 it belongs.
4256
f6a7cffc
TS
4257 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
4258 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
4259 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
4260
632f2871
RS
42612014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
4262
4263 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
4264 * c-common.c (c_common_nodes_and_builtins): Don't initialize
4265 void_zero_node.
4266 * c-pretty-print.c (pp_c_void_constant): New function.
4267 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
4268 (c_pretty_printer::expression): Handle VOID_CST.
4269 * cilk.c (extract_free_variables): Likewise.
4270 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
4271 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
4272
766090c2
TS
42732014-05-17 Trevor Saunders <tsaunders@mozilla.com>
4274
4275 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
4276 * c-pragma.c (push_alignment): Adjust.
4277 (handle_pragma_push_options): Likewise.
4278
661a0813
MP
42792014-05-09 Marek Polacek <polacek@redhat.com>
4280
4281 PR c/50459
4282 * c-common.c (check_user_alignment): Return -1 if alignment is error
4283 node.
4284 (handle_aligned_attribute): Don't call default_conversion on
4285 FUNCTION_DECLs.
4286 (handle_vector_size_attribute): Likewise.
4287 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
4288 (handle_sentinel_attribute): Call default_conversion and allow even
4289 integral types as an argument.
4290
2793eeab
MP
42912014-05-08 Marek Polacek <polacek@redhat.com>
4292
4293 PR c/61053
4294 * c-common.c (min_align_of_type): New function factored out from...
4295 (c_sizeof_or_alignof_type): ...here.
4296 * c-common.h (min_align_of_type): Declare.
4297
f827930a
MP
42982014-05-08 Marek Polacek <polacek@redhat.com>
4299
4300 PR c/61077
4301 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
4302 parameter type of main.
4303
ca49b74e
DD
43042014-05-07 DJ Delorie <dj@redhat.com>
4305
4306 * c-cppbuiltin.c (print_bits_of_hex): New.
4307 (builtin_define_type_minmax): Print values using hex so as not to
4308 require a pre-computed list of string values.
4309
1d60af08
KZ
43102014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
4311 Mike Stump <mikestump@comcast.net>
4312 Richard Sandiford <rdsandiford@googlemail.com>
4313
4314 * c-ada-spec.c: Include wide-int.h.
4315 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
4316 (dump_generic_ada_node): Use wide-int interfaces.
4317 * c-common.c: Include wide-int-print.h.
4318 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
4319 (pointer_int_sum): Use wide-int interfaces.
4320 (c_common_nodes_and_builtins): Use make_int_cst.
4321 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
4322 (handle_alloc_size_attribute): Use wide-int interfaces.
4323 (get_nonnull_operand): Likewise.
4324 * c-format.c (get_constant): Use tree_fits_uhwi_p.
4325 * c-lex.c: Include wide-int.h.
4326 (narrowest_unsigned_type): Take a widest_int rather than two
4327 HOST_WIDE_INTs.
4328 (narrowest_signed_type): Likewise.
4329 (interpret_integer): Update accordingly. Use wide-int interfaces.
4330 (lex_charconst): Use wide-int interfaces.
4331 * c-pretty-print.c: Include wide-int.h.
4332 (pp_c_integer_constant): Use wide-int interfaces.
4333 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
4334 INT_CST_LT_UNSIGNED.
4335
b15458be
RB
43362014-05-06 Richard Biener <rguenther@suse.de>
4337
4338 * c-opts.c (c_common_post_options): For -freestanding,
4339 -fno-hosted and -fno-builtin disable pattern recognition
4340 if not enabled explicitely.
4341
6577374e
MP
43422014-05-02 Marek Polacek <polacek@redhat.com>
4343
4344 * c.opt (Wsizeof-pointer-memaccess): Describe option.
4345
d00887e8
MP
43462014-05-01 Marek Polacek <polacek@redhat.com>
4347
4348 PR c/43245
4349 * c.opt (Wdiscarded-qualifiers): Add.
4350
f8ed5150
MP
43512014-04-30 Marek Polacek <polacek@redhat.com>
4352
4353 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
4354 INT_MIN / -1 sanitization only for integer types.
4355
45484dcf
MP
43562014-04-25 Marek Polacek <polacek@redhat.com>
4357
4358 PR c/18079
4359 * c-common.c (handle_noinline_attribute): Warn if the attribute
4360 conflicts with always_inline attribute.
4361 (handle_always_inline_attribute): Warn if the attribute conflicts
4362 with noinline attribute.
4363
38e514c0
MP
43642014-04-25 Marek Polacek <polacek@redhat.com>
4365
4366 PR c/60156
4367 * c-common.c (check_main_parameter_types): Warn about variadic main.
4368
44875f92
MS
43692014-04-24 Mike Stump <mikestump@comcast.net>
4370
4371 * c.opt (Wshadow-ivar): Default to on.
4372
dcaaa5a0
DP
43732014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
4374
4375 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
4376
c07d7c02
MP
43772014-04-23 Marek Polacek <polacek@redhat.com>
4378
4379 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
4380
1c33c9b7
JJ
43812014-04-22 Jakub Jelinek <jakub@redhat.com>
4382
4383 PR sanitizer/60275
4384 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
4385 if flag_sanitize_undefined_trap_on_error.
4386 (ubsan_instrument_division, ubsan_instrument_shift,
4387 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
4388 if !flag_sanitize_recover.
4389
793c625f
MG
43902014-04-22 Marc Glisse <marc.glisse@inria.fr>
4391
4392 PR libstdc++/43622
4393 * c-common.c (registered_builtin_types): Make non-static.
4394 * c-common.h (registered_builtin_types): Declare.
4395
b0f1bf36
RB
43962014-04-14 Richard Biener <rguenther@suse.de>
4397 Marc Glisse <marc.glisse@inria.fr>
4398
4399 PR c/60819
4400 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
4401 apply may-alias the scalar pointer type when applicable.
4402
3b07fa4a
IZ
44032014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
4404
4405 PR middle-end/60467
4406 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
4407 as possible argument for Cilk_spawn.
4408
cbbd2b1c
TB
44092014-04-11 Tobias Burnus <burnus@net-b.de>
4410
4411 PR c/60194
4412 * c.opt (Wformat-signedness): Add
4413 * c-format.c(check_format_types): Use it.
4414
6415bd5d
JM
44152014-04-11 Jason Merrill <jason@redhat.com>
4416
4417 PR c++/57926
4418 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
4419 default_conversion for an array argument.
4420
6525783a
MP
44212014-04-08 Marek Polacek <polacek@redhat.com>
4422
4423 PR sanitizer/60745
4424 * c-ubsan.c: Include asan.h.
4425 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
4426
880a467b
NS
44272014-04-03 Nathan Sidwell <nathan@codesourcery.com>
4428
4429 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
4430
7b59ff2d
MP
44312014-04-02 Marek Polacek <polacek@redhat.com>
4432
4433 * c-common.h (c_expand_expr): Remove declaration.
4434
8edbfaa6
JJ
44352014-03-28 Jakub Jelinek <jakub@redhat.com>
4436
4437 PR c++/60689
4438 * c-common.c (add_atomic_size_parameter): When creating new
4439 params vector, push the size argument first.
4440
07d72e1d
JJ
44412014-03-26 Jakub Jelinek <jakub@redhat.com>
4442
4443 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
4444 ubsan_instrument_vla, ubsan_instrument_return): Adjust
4445 ubsan_create_data callers.
4446
b35e0fa0
JJ
44472014-03-22 Jakub Jelinek <jakub@redhat.com>
4448
4449 PR debug/60603
4450 * c-opts.c (c_finish_options): Restore cb_file_change call to
4451 <built-in>.
4452
39a1ebb3
JJ
44532014-03-13 Jakub Jelinek <jakub@redhat.com>
4454
4455 PR middle-end/36282
4456 * c-pragma.c (apply_pragma_weak): Only look at
4457 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
4458 DECL_ASSEMBLER_NAME_SET_P (decl).
4459 (maybe_apply_pending_pragma_weaks): Exit early if
4460 vec_safe_is_empty (pending_weaks) rather than only when
4461 !pending_weaks.
4462 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
4463 set assembler name back to NULL afterwards.
4464
a07f6ed2
JM
44652014-03-11 Jason Merrill <jason@redhat.com>
4466
4467 * c.opt: Add -std=gnu++14.
4468
75b107f5
IB
44692014-03-11 Ian Bolton <ian.bolton@arm.com>
4470
4471 * c-opts.c (c_common_post_options): Don't override
4472 -ffp-contract=fast if unsafe-math-optimizations is on.
4473
f42c637e
PM
44742014-03-08 Paulo Matos <paulo@matos-sorge.com>
4475
22b15758 4476 * c.opt: Enable LTO FE for fshort-double.
f42c637e 4477
70e24808
JM
44782014-03-07 Jason Merrill <jason@redhat.com>
4479
4480 * c.opt: Add -std=c++14.
4481
3af9c5e9
MP
44822014-03-06 Marek Polacek <polacek@redhat.com>
4483
4484 PR c/60197
4485 * cilk.c (contains_cilk_spawn_stmt): New function.
4486 (contains_cilk_spawn_stmt_walker): Likewise.
4487 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
4488 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
4489
b3bdf019
JJ
44902014-03-03 Jakub Jelinek <jakub@redhat.com>
4491
4492 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
4493 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
4494 even when flag_preprocess_only.
4495
ca7e759d
JM
44962014-02-26 Jason Merrill <jason@redhat.com>
4497
4498 PR c++/59231
4499 PR c++/11586
4500 * c-common.c (shorten_compare): Don't check
4501 c_inhibit_evaluation_warnings.
4502
28e41874
JJ
45032014-02-19 Jakub Jelinek <jakub@redhat.com>
4504
cca615af
JJ
4505 PR c/37743
4506 * c-common.c (c_common_nodes_and_builtins): When initializing
4507 c_uint{16,32,64}_type_node, also set corresponding
4508 uint{16,32,64}_type_node to the same value.
4509
28e41874
JJ
4510 PR c++/60267
4511 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
4512 for PRAGMA_IVDEP if flag_preprocess_only.
4513
c2bf53a1
JJ
45142014-02-12 Jakub Jelinek <jakub@redhat.com>
4515
4516 PR c/60101
4517 * c-common.c (merge_tlist): If copy is true, call new_tlist,
4518 if false, add ADD itself, rather than vice versa.
4519 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
4520 copy. For SAVE_EXPR, only call merge_tlist once.
4521
8fcbce72
JJ
45222014-02-08 Jakub Jelinek <jakub@redhat.com>
4523
4524 PR middle-end/60092
4525 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
4526 and tree_to_uhwi.
4527 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
4528 functions.
4529 (c_common_attribute_table): Add alloc_align and assume_aligned
4530 attributes.
4531
0a756a3f
MP
45322014-02-06 Marek Polacek <polacek@redhat.com>
4533
4534 PR c/60087
4535 * c-common.c (warn_for_sign_compare): Call warning_at with location
4536 instead of warning.
4537
7ec4847a
MP
45382014-02-05 Marek Polacek <polacek@redhat.com>
4539
4540 PR c/53123
4541 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
4542 statement.
4543
66f20604
MP
45442014-02-04 Marek Polacek <polacek@redhat.com>
4545
4546 PR c/60036
4547 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
4548 SAVE_EXPR.
4549
5d77fb19
MG
45502014-02-03 Marc Glisse <marc.glisse@inria.fr>
4551
4552 PR c++/53017
4553 PR c++/59211
4554 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
4555 handle_vector_size_attribute, handle_nonnull_attribute): Call
4556 default_conversion on the attribute argument.
4557 (handle_nonnull_attribute): Increment the argument number.
4558
81e5eca8
MP
45592014-01-31 Marek Polacek <polacek@redhat.com>
4560
4561 PR c/59963
4562 * c-common.c (add_atomic_size_parameter): Pass vNULL to
4563 build_function_call_vec.
4564 (resolve_overloaded_builtin): Likewise.
4565 * c-common.h (build_function_call_vec): Adjust declaration.
4566
68fca595
MP
45672014-01-30 Marek Polacek <polacek@redhat.com>
4568
4569 PR c/59940
4570 * c-common.h (unsafe_conversion_p): Adjust declaration.
4571 (warnings_for_convert_and_check): Likewise.
4572 (convert_and_check): Likewise.
4573 * c-common.c (unsafe_conversion_p): Add location parameter. Call
4574 expansion_point_location_if_in_system_header on it.
4575 (warnings_for_convert_and_check): Add location parameter. Call
4576 expansion_point_location_if_in_system_header on it. Use it.
4577 (convert_and_check): Add location parameter. Use it.
4578 (conversion_warning): Likewise.
4579 (c_add_case_label): Adjust convert_and_check calls.
4580 (scalar_to_vector): Adjust unsafe_conversion_p calls.
4581
b72271b9
BI
45822014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
4583
4584 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
4585 flag_cilkplus.
4586 * c-pragma.c (init_pragma): Likewise.
4587 * c.opt: Likewise.
4588
393e8e8b
MP
45892014-01-23 Marek Polacek <polacek@redhat.com>
4590
4591 PR c/59846
4592 * c-common.c (shorten_compare): Add location_t parameter.
4593 * c-common.h (shorten_binary_op): Adjust declaration.
4594
f04dda30
MP
45952014-01-23 Marek Polacek <polacek@redhat.com>
4596
4597 PR c/58346
4598 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
4599 * c-common.h: Declare it.
4600
621955cb
EB
46012014-01-20 Eric Botcazou <ebotcazou@adacore.com>
4602
4603 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
4604 * c-ada-spec.c (dump_ads): Likewise.
4605 (cpp_check): Likewise.
4606 (dump_ada_specs): Likewise.
4607
46082014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
67bf2939
LA
4609
4610 PR c++/49718
4611 * c-common.c (handle_no_instrument_function_attribute): Allow
4612 no_instrument_function attribute in class member
4613 definition/declaration.
4614
241f845a
JJ
46152014-01-15 Jakub Jelinek <jakub@redhat.com>
4616
4617 PR c/58943
4618 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
4619 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
4620 being COMPOUND_EXPR.
4621 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
4622 operand a SAVE_EXPR and second MODIFY_EXPR.
4623
e83b8e2e
JJ
46242014-01-09 Jakub Jelinek <jakub@redhat.com>
4625
4626 PR target/58115
4627 * c-pch.c (c_common_write_pch): Call
4628 prepare_target_option_nodes_for_pch.
4629
23a5b65a
RS
46302014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
4631
4632 Update copyright years
4633
f9030485
RS
46342014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
4635
4636 * array-notation-common.c, c-cilkplus.c: Use the standard form for
4637 the copyright notice.
4638
f2aa696b
EB
46392013-12-28 Eric Botcazou <ebotcazou@adacore.com>
4640
4641 * c-ada-spec.c (print_constructor): New function.
4642 (print_destructor): Retrieve the origin of the destructor.
4643 (print_ada_declaration): Revamp handling of constructors/destructors.
4644
3f8257db 46452013-12-23 Stuart Hastings <stuart@apple.com>
1f26ac87
JM
4646 Bill Maddox <maddox@google.com>
4647 Jason Merrill <jason@redhat.com>
4648
4649 * c.opt: Add -fdeclone-ctor-dtor.
4650 * c-opts.c (c_common_post_options): Default to on iff -Os.
4651
41958c28
BI
46522013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
4653
4654 * c-common.c (c_common_attribute_table): Added "cilk simd function"
4655 attribute.
4656 * c-pragma.h (enum pragma_cilk_clause): Remove.
4657 (enum pragma_omp_clause): Added the following fields:
4658 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
4659 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
4660 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
4661 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
4662 PRAGMA_CILK_CLAUSE_UNIFORM.
4663
b1726d6c 4664
12893402
BI
46652013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
4666
4667 * cilk.c (cilk_outline): Made this function non-static.
4668 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
4669 (create_cilk_wrapper): Added a new parameter: a function pointer.
4670 (c_install_body_w_frame_cleanup): Remove
4671 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
4672 * c-common.h (cilk_outline): New prototype.
4673 (gimplify_cilk_spawn): Removed two parameters.
4674 (cilk_install_body_with_frame_cleanup): New prototype.
4675 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
4676 CILK_SPAWN_STMT case.
4677
085b42ed
BS
46782013-12-11 Bernd Schmidt <bernds@codesourcery.com>
4679
2ce064c3
BS
4680 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
4681
085b42ed
BS
4682 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
4683 (int_array_type_node): Remove.
4684 * c-common.c (c_common_nodes_and_builtins): Don't build it.
4685
9e36c9ed
MP
46862013-12-05 Marek Polacek <polacek@redhat.com>
4687
4688 PR c/52023
4689 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
4690 [ADJUST_FIELD_ALIGN].
4691
296674db
JM
46922013-12-04 Joseph Myers <joseph@codesourcery.com>
4693
4694 PR c/52023
4695 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
4696 and check field alignment if set.
4697 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
4698 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
4699
b1726d6c 47002013-12-04 Jakub Jelinek <jakub@redhat.com>
31e071ae
MP
4701 Marek Polacek <polacek@redhat.com>
4702
4703 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
4704 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
4705
d7947e19
L
47062013-11-29 H.J. Lu <hongjiu.lu@intel.com>
4707
4708 PR c/59309
4709 * cilk.c (gimplify_cilk_spawn): Properly handle function without
4710 arguments.
4711
fad7652e
JJ
47122013-11-29 Jakub Jelinek <jakub@redhat.com>
4713
4714 PR c/59280
4715 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
4716 goto invalid. If it is error_mark_node, don't issue further
4717 diagnostics.
4718
8b5e1202
SO
47192013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
4720
4721 * c.opt (Wopenmp-simd): New.
4722
0a508bb6
JJ
47232013-11-22 Jakub Jelinek <jakub@redhat.com>
4724
4725 * c-ubsan.h (ubsan_instrument_return): New prototype.
4726 * c-ubsan.c (ubsan_instrument_return): New function.
4727
2fb9a547
AM
47282013-11-22 Andrew MacLeod <amacleod@redhat.com>
4729
4730 * c-common.c: Add required include files from gimple.h.
4731 * c-gimplify.c: Likewise
4732 * cilk.c: Likewise
4733
8400e75e
DM
47342013-11-22 David Malcolm <dmalcolm@redhat.com>
4735
4736 * c-common.c (unsafe_conversion_p): Remove use of
4737 EXPR_LOC_OR_HERE macro.
4738 (conversion_warning): Likewise.
4739 (warnings_for_convert_and_check): Likewise.
4740 (warn_for_collisions_1): Likewise.
4741 (shorten_compare): Likewise, and remove use of in_system_header
4742 macro, using the location from the former.
4743 * c-lex.c (dump_one_header): Remove use of input_filename macro.
4744 (cb_def_pragma): Remove use of in_system_header macro.
4745 (lex_string): Likewise.
4746 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
4747
eb1ce453
KZ
47482013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
4749 Mike Stump <mikestump@comcast.net>
4750 Richard Sandiford <rdsandiford@googlemail.com>
4751
4752 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
4753 instead of TREE_INT_CST_LOW, in cases where there is a protecting
4754 tree_fits_shwi_p or tree_fits_uhwi_p.
4755 (dump_generic_ada_node): Likewise.
4756 * c-format.c (check_format_arg): Likewise.
4757 * c-pretty-print.c (pp_c_integer_constant): Likewise.
4758
6b3b8c27
KZ
47592013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
4760
4761 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
4762
49b0aa18
JC
47632013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
4764
4765 PR c/53001
4766 * c-common.c (unsafe_conversion_p): Make this function
4767 return an enumeration with more detail.
4768 (conversion_warning): Use the new return type of
4769 unsafe_conversion_p to separately warn either about conversions
4770 that lower floating point number precision or about the other
4771 kinds of conversions.
4772 * c-common.h (enum conversion_safety): New enumeration.
8e745a17
JJ
4773 (unsafe_conversion_p): switching return type to
4774 conversion_safety enumeration.
49b0aa18
JC
4775 * c.opt: Adding new warning -Wfloat-conversion and
4776 enabling it with -Wconversion.
4777
b826515a
BS
47782013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
4779
8e745a17
JJ
4780 * c-opts.c: Include plugin.h.
4781 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
b826515a 4782
b9a55b13
MP
47832013-11-19 Marek Polacek <polacek@redhat.com>
4784
4785 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
4786 call.
4787 (ubsan_instrument_shift): Likewise.
4788 (ubsan_instrument_vla): Likewise.
4789
7d362f6c
RS
47902013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4791
4792 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
4793 cast to unsigned type.
4794
386b1f1f
RS
47952013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4796
4797 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
4798 tree_low_cst.
4799 (complete_array_type): Update comment to refer to tree_to_[su]hwi
4800 rather than tree_low_cst.
4801
ae7e9ddd
RS
48022013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4803
4804 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
4805 tree_to_uhwi throughout.
4806
9439e9a1
RS
48072013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4808
4809 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
4810 tree_low_cst (..., 0) with tree_to_shwi throughout.
4811
cc269bb6
RS
48122013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4813
4814 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
4815 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
4816
9541ffee
RS
48172013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
4818
4819 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
4820 host_integerp (..., 0) with tree_fits_shwi_p throughout.
4821
c02065fc
AH
48222013-11-15 Aldy Hernandez <aldyh@redhat.com>
4823
4824 * c-cilkplus.c: New file.
4825 * c-common.c (readonly_error): Add location argument.
4826 * c-common.h (readonly_error): Same.
4827 (c_finish_cilk_clauses): Protoize.
4828 (c_check_cilk_loop): Same.
4829 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
4830 Do not fail on error_mark_node.
4831 Abstract increment canonicalization to here...
4832 (c_omp_for_incr_canonicalize_ptr): New.
4833 c-pragma.c (init_pragma): Register "simd" pragma.
4834 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
4835 (enum pragma_cilk_clause): New.
4836
9cc65f15
RS
48372013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
4838
4839 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
4840 wchar_type and host_integerp checks.
4841
18f429e2
AM
48422013-11-14 Andrew MacLeod <amacleod@redhat.com>
4843
4844 * c-common.c: Likewise.
4845 * c-gimplify.c: Likewise.
4846 * cilk.c: Likewise.
4847
d8a2d370
DN
48482013-11-14 Diego Novillo <dnovillo@google.com>
4849
4850 * c-common.c: Include fold-const.h.
4851 Include stor-layout.h.
4852 Include calls.h.
4853 Include stringpool.h.
4854 Include attribs.h.
4855 Include varasm.h.
4856 Include trans-mem.h.
4857 * c-cppbuiltin.c: Include stor-layout.h.
4858 Include stringpool.h.
4859 * c-format.c: Include stringpool.h.
4860 * c-lex.c: Include stringpool.h.
4861 Include stor-layout.h.
4862 * c-pragma.c: Include stringpool.h.
4863 Include attribs.h.
4864 Include varasm.h.
4865 Include gcc-symtab.h.
4866 * c-pretty-print.c: Include stor-layout.h.
4867 Include attribs.h.
4868 * cilk.c: Include stringpool.h.
4869 Include calls.h.
4870
38b7bc7f
JM
48712013-11-13 Joseph Myers <joseph@codesourcery.com>
4872
4873 * c-common.h (enum rid): Add RID_AUTO_TYPE.
4874 * c-common.c (c_common_reswords): Add __auto_type.
4875 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
4876
45b0be94
AM
48772013-11-12 Andrew MacLeod <amacleod@redhat.com>
4878
18f429e2
AM
4879 * c-common.c: Include gimplify.h.
4880 * c-gimplify.c: Likewise.
4881 * cilk.c: Likewise.
4882 * c-omp.c: Include gimple-expr.h instead of gimple.h.
4883 * c-ubsan.c: Don't include gimple.h.
45b0be94 4884
582d9b50
JM
48852013-11-12 Joseph Myers <joseph@codesourcery.com>
4886
4887 * c-common.c (c_common_reswords): Add _Thread_local.
4888
6b28e197
JM
48892013-11-09 Joseph Myers <joseph@codesourcery.com>
4890
4891 * c-common.c (atomic_size_supported_p): New function.
4892 (resolve_overloaded_atomic_exchange)
4893 (resolve_overloaded_atomic_compare_exchange)
4894 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
4895 Use it instead of comparing size with a local list of sizes.
4896
267bac10
JM
48972013-11-07 Andrew MacLeod <amacleod@redhat.com>
4898 Joseph Myers <joseph@codesourcery.com>
4899
4900 * c-common.h (enum rid): Add RID_ATOMIC.
4901 * c-common.c (c_common_reswords): Add _Atomic.
4902 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
4903 (keyword_is_type_qualifier): Accept RID_ATOMIC.
4904 * c-format.c (check_format_types): Check for extra _Atomic
4905 qualifiers in format argument.
4906 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
4907 (pp_c_type_qualifier_list): Mention _Atomic in comment.
4908
5157b91e
TB
49092013-11-06 Tobias Burnus <burnus@net-b.de>
4910
4911 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
4912
6dbe0958
JM
49132013-11-06 Joseph Myers <joseph@codesourcery.com>
4914
4915 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
4916 standards modes.
4917 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
4918 to mean lack of IEEE 754 support.
4919
e8ff5196
TB
49202013-11-05 Tobias Burnus <burnus@net-b.de>
4921
4922 * c.opt (-Wdate-time): New option
4923 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
4924
254a0760
JM
49252013-11-05 Joseph Myers <joseph@codesourcery.com>
4926
4927 * c-cppbuiltin.c (cpp_iec_559_value): Test
4928 flag_excess_precision_cmdline not flag_excess_precision.
4929
6d7f7e0a
TB
49302013-11-05 Tobias Burnus <burnus@net-b.de>
4931
4932 * c.opt (fopenmp-simd): New option.
4933 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
4934 (omp_pragmas): ... this new struct.
4935 (c_pp_lookup_pragma): Also walk omp_pragmas.
4936 (init_pragma): Init pragmas for -fopenmp-simd.
4937
55a7f02f
MP
49382013-11-04 Marek Polacek <polacek@redhat.com>
4939
4940 PR c++/58979
4941 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
4942
9193fb05
JM
49432013-11-04 Joseph Myers <joseph@codesourcery.com>
4944
4945 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
4946 New functions.
4947 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
4948
94159ecf
EB
49492013-11-04 Eric Botcazou <ebotcazou@adacore.com>
4950
4951 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
4952 (dump_ada_specs): Adjust prototype of second callback.
4953 * c-ada-spec.c (cpp_check): New global variable.
4954 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
4955 (print_generic_ada_decl): Likewise.
4956 (has_static_fields): Change return type to bool and add guard.
4957 (has_nontrivial_methods): New predicate.
4958 (is_tagged_type): Change return type to bool.
4959 (separate_class_package): Call has_nontrivial_methods.
4960 (pp_ada_tree_identifier): Minor tweaks.
4961 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
4962 (dump_ada_array_domains): Likewise.
4963 (dump_ada_array_type): Likewise.
4964 (dump_template_types): Remove cpp_check parameter and do not pass it to
4965 dump_generic_ada_node.
4966 (dump_ada_template): Likewise.
4967 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
4968 recursively.
4969 (print_ada_methods): Change return type to integer. Remove cpp_check
4970 parameter and do not pass it down.
4971 (dump_nested_types): Remove cpp_check parameter and do not pass it to
4972 dump_generic_ada_node.
4973 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
4974 accessing methods.
4975 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
4976 down. Use has_nontrivial_methods to recognize C++ classes. Use return
4977 value of print_ada_methods.
4978 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
4979 Set cpp_check to it before invoking dump_ada_nodes.
4980 (dump_ada_specs): Likewise.
4981
b906f4ca
MP
49822013-11-03 Marek Polacek <polacek@redhat.com>
4983
4984 * c-ubsan.c: Don't include hash-table.h.
4985 (ubsan_instrument_vla): New function.
4986 * c-ubsan.h: Declare it.
4987
5e20cdc9
DM
49882013-10-31 David Malcolm <dmalcolm@redhat.com>
4989
4990 Automated part of renaming of symtab_node_base to symtab_node.
4991
4992 Patch autogenerated by rename_symtab.py from
4993 https://github.com/davidmalcolm/gcc-refactoring-scripts
4994 revision 58bb219cc090b2f4516a9297d868c245495ee622
4995
4996 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
4997 symtab_node_base to symtab_node.
4998
7057e645
ESR
49992013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
5000
8e745a17 5001 Implement C++14 digit separators.
7057e645
ESR
5002 * c-lex.c (interpret_float): Remove digit separators from scratch string
5003 before building real literal.
5004
193ea7bc
JJ
50052013-10-30 Jakub Jelinek <jakub@redhat.com>
5006
5007 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
5008
939b37da
BI
50092013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
5010
5011 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
5012 fields.
5013 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
5014 enabled.
5015 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
5016 (insert_cilk_frame): New prototype.
5017 (cilk_init_builtins): Likewise.
5018 (gimplify_cilk_spawn): Likewise.
5019 (c_cilk_install_body_w_frame_cleanup): Likewise.
5020 (cilk_detect_spawn_and_unwrap): Likewise.
5021 (cilk_set_spawn_marker): Likewise.
5022 (build_cilk_sync): Likewise.
5023 (build_cilk_spawn): Likewise.
5024 * cilk.c: New file.
5025
67348ccc
DM
50262013-10-29 David Malcolm <dmalcolm@redhat.com>
5027
5028 Patch autogenerated by refactor_symtab.py from
5029 https://github.com/davidmalcolm/gcc-refactoring-scripts
5030 revision 58bb219cc090b2f4516a9297d868c245495ee622
5031
5032 * c-gimplify.c (c_genericize): Update for conversion of symtab types
5033 to a true class hierarchy.
5034 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
5035
d570872d
RS
50362013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
5037
5038 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
5039
98906124
JL
50402013-10-26 Jeff Law <law@redhat.com>
5041
adfac8df
JJ
5042 * c-common.c (c_define_builtins): Remove mudflap support.
5043 * c.opt: Ignore and warn for mudflap options.
98906124 5044
d73749df 50452013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
5046
5047 PR other/33426
5048 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
5049 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
5050
3f04b1bb
JM
50512013-10-23 Jason Merrill <jason@redhat.com>
5052
5053 * c-format.c (gcc_cxxdiag_char_table): Add %X.
5054
acf0174b
JJ
50552013-10-11 Jakub Jelinek <jakub@redhat.com>
5056
acd15a28
JJ
5057 * c-common.h (omp_clause_mask::operator !=): New method.
5058 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
5059 instead of if (mask & something) tests everywhere.
5060
acf0174b
JJ
5061 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
5062 201307 instead of 201107.
5063 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
5064 (c_common_attribute_table): Add "omp declare target" and
5065 "omp declare simd" attributes.
5066 (handle_omp_declare_target_attribute,
5067 handle_omp_declare_simd_attribute): New functions.
5068 * c-omp.c: Include c-pragma.h.
5069 (c_finish_omp_taskgroup): New function.
5070 (c_finish_omp_atomic): Add swapped argument, if true,
5071 build the operation first with rhs, lhs arguments and use NOP_EXPR
5072 build_modify_expr.
5073 (c_finish_omp_for): Add code argument, pass it down to make_code.
5074 (c_omp_split_clauses): New function.
5075 (c_split_parallel_clauses): Removed.
5076 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
5077 c_omp_declare_simd_clauses_to_decls): New functions.
5078 * c-common.h (omp_clause_mask): New type.
5079 (OMP_CLAUSE_MASK_1): Define.
5080 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
5081 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
5082 omp_clause_mask::operator |, omp_clause_mask::operator &,
5083 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
5084 omp_clause_mask::operator ==): New methods.
5085 (enum c_omp_clause_split): New.
5086 (c_finish_omp_taskgroup): New prototype.
5087 (c_finish_omp_atomic): Add swapped argument.
5088 (c_finish_omp_for): Add code argument.
5089 (c_omp_split_clauses): New prototype.
5090 (c_split_parallel_clauses): Removed.
5091 (c_omp_declare_simd_clauses_to_numbers,
5092 c_omp_declare_simd_clauses_to_decls): New prototypes.
5093 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
5094 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
5095 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
5096 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
5097 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
5098 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
5099 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
5100 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
5101 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
5102 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
5103 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
5104 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
5105 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
5106 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
5107 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
5108 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
5109 PRAGMA_OMP_CLAUSE_UNIFORM.
5110
826cacfe
MG
51112013-10-09 Marc Glisse <marc.glisse@inria.fr>
5112
5113 PR tree-optimization/20318
5114 * c-common.c (handle_returns_nonnull_attribute): New function.
5115 (c_common_attribute_table): Add returns_nonnull.
5116
2284b034
MG
51172013-10-03 Marc Glisse <marc.glisse@inria.fr>
5118
5119 PR c++/19476
5120 * c.opt (fcheck-new): Move to common.opt.
5121
b56e9788
MP
51222013-09-25 Marek Polacek <polacek@redhat.com>
5123 Jakub Jelinek <jakub@redhat.com>
5124
5125 PR sanitizer/58413
5126 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
5127 an expression if we can prove it is correct.
5128 (ubsan_instrument_division): Likewise. Remove unnecessary
5129 check.
5130
ce6923c5
MP
51312013-09-18 Marek Polacek <polacek@redhat.com>
5132
5133 PR sanitizer/58411
5134 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
5135 Declare it.
5136 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
5137
fb5610fb
IS
51382013-09-14 Iain Sandoe <iain@codesourcery.com>
5139
5140 PR target/48094
5141 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
5142 fobjc-gc, freplace-objc-classes): Accept for LTO.
5143
88b0e79e
JC
51442013-09-13 Jacek Caban <jacek@codeweavers.com>
5145
5146 * c-target.def: New hook
5147
c9b0866a
PC
51482013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
5149
5150 PR c++/43452
5151 * c.opt (Wdelete-incomplete): Add.
5152
0af94e6f
JR
51532013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
5154
5155 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
5156 (vector_types_compatible_elements_p): New function.
5157 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
5158 declaration.
5159 (vector_types_compatible_elements_p): Declare.
5160
7c26172c
GDR
51612013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
5162
5163 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
5164 a virtual member function.
5165 (pp_simple_type_specifier): Remove.
5166 (pp_c_type_specifier): Likewise.
5167 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
5168 Rename from pp_c_type_specifier. Adjust.
5169 (c_pretty_printer::c_pretty_printer): Do not assign to
5170 simple_type_specifier.
5171
20059c8b
GDR
51722013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
5173
5174 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
5175 member function.
5176 (c_pretty_printer::storage_class_specifier): Likewise.
5177 (c_pretty_printer::initializer): Likewise.
5178 (pp_declaration): Remove.
5179 (pp_declaration_specifiers): Likewise.
5180 (pp_abstract_declarator): Likewise.
5181 (pp_declarator): Likewise.
5182 (pp_type_id): Likewise.
5183 (pp_statement): Likewise.
5184 (pp_constant): Likewise.
5185 (pp_id_expression): Likewise.
5186 (pp_primary_expression): Likewise.
5187 (pp_unary_expression): Likewise.
5188 (pp_multiplicative_expression): Likewise.
5189 (pp_conditional_expression): Likewise.
5190 (pp_assignment_expression): Likewise.
5191 (pp_expression): Likewise.
5192 (pp_c_type_id): Likewise.
5193 (pp_c_storage_class_specifier): Likewise.
5194 * c-pretty-print.c (pp_c_type_cast): Tidy.
5195 (pp_c_pointer): Likewise.
5196 (pp_c_type_specifier): Likewise.
5197 (pp_c_parameter_type_list): Likewise.
5198 (pp_c_function_definition): Likewise.
5199 (pp_c_init_declarator): Likewise.
5200 (pp_c_initializer_list): Likewise.
5201 (pp_c_constructor_elts): Likewise.
5202 (c_pretty_printer::direct_abstract_declarator): Likewise.
5203 (c_pretty_printer::declaration_specifiers): Likewise.
5204 (c_pretty_printer::primary_expression): Likewise.
5205 (c_pretty_printer::postfix_expression): Likewise.
5206 (c_pretty_printer::type_id): Rename from pp_c_type_id.
5207 (c_pretty_printer::storage_class_specifier): Rename from
5208 pp_c_storage_class_specifier.
5209 (c_pretty_printer::initializer): Rename from pp_c_initializer.
5210 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
5211 storage_class_specifier, initializer, offset_list, flags.
5212
de5a5fa1
MP
52132013-08-30 Marek Polacek <polacek@redhat.com>
5214
5215 * c-ubsan.c: New file.
5216 * c-ubsan.h: New file.
5217
8f0e4d72
GDR
52182013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
5219
5220 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
5221 member function.
5222 (c_pretty_printer::declaration_specifiers): Likewise.
5223 (c_pretty_printer::declarator): Likewise.
5224 (c_pretty_printer::abstract_declarator): Likewise.
5225 (c_pretty_printer::direct_abstract_declarator): Likewise.
5226 (c_pretty_printer::direct_declarator): Likewise.
5227 (c_pretty_printer::function_specifier): Likewise.
5228 (pp_declaration): Adjust.
5229 (pp_declaration_specifiers): Likewise.
5230 (pp_abstract_declarator): Likewise.
5231 (pp_direct_declarator): Likewise.
5232 (pp_function_specifier): Likewise.
5233 (pp_direct_abstract_declarator): Remove as unused.
5234 (pp_c_declaration): Remove.
5235 (pp_c_declaration_specifiers): Likewise.
5236 (pp_c_declarator): Likewise.
5237 (pp_c_direct_declarator): Likewise.
5238 (pp_c_function_specifier): Likewise.
5239 (pp_c_direct_abstract_declarator): Likewise.
5240 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
5241 from pp_c_abstract_declarator. Adjust.
5242 (c_pretty_printer::direct_abstract_declarator): Rename from
5243 pp_c_direct_abstract_declarator. Adjust.
5244 (c_pretty_printer::function_specifier): Rename from
5245 pp_c_function_specifier. Adjust.
5246 (c_pretty_printer::declaration_specifiers): Rename from
5247 pp_c_declaration_specifiers. Adjust.
5248 (c_pretty_printer::direct_declarator): Rename from
5249 pp_c_direct_declarator. Adjust.
5250 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
5251 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
5252 (c_pretty_printer::c_pretty_printer): Do not assign to
5253 declaration, declaration_specifiers, declarator,
5254 direct_declarator, direct_abstract_declarator, function_specifier.
5255
00d34d3a
GDR
52562013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
5257
5258 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
5259 virtual member function.
5260 (c_pretty_printer::multiplicative_expression): Likewise.
5261 (c_pretty_printer::conditional_expression): Likewise.
5262 (c_pretty_printer::assignment_expression): Likewise.
5263 (c_pretty_printer::expression): Likewise.
5264 (pp_unary_expression): Adjust.
5265 (pp_multiplicative_expression): Likewise.
5266 (pp_assignment_expression): Likewise.
5267 (pp_conditional_expression): Likewise.
5268 (pp_expression): Likewise.
5269 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
5270 from pp_c_unary_expression. Adjust.
5271 (c_pretty_printer::multiplicative_expression): Rename from
5272 pp_c_multiplicative_expression. Adjust.
5273 (c_pretty_printer::conditional_expression): Rename from
5274 pp_c_conditional_expression. Adjust.
5275 (c_pretty_printer::assignment_expression): Rename from
5276 pp_c_assignment_expression. Adjust.
5277 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
5278 (c_pretty_printer::c_pretty_printer): Do not assign to
5279 unary_expression, multiplicative_expression,
5280 conditional_expression, expression.
5281
fb22178f
GDR
52822013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
5283
5284 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
5285 virtual member function.
5286 (pp_postfix_expression): Adjust.
5287 (pp_c_postfix_expression): Remove.
5288 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
5289 from pp_c_postfix_expression. Adjust.
5290 (c_pretty_printer::c_pretty_printer): Do not assign to
5291 postfix_expression.
5292
7ecc2600
GDR
52932013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
5294
5295 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
5296 virtua member function.
5297 (pp_primary_expression): Adjust.
5298 (pp_c_primary_expression): Remove.
5299 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
5300 from pp_c_primary_expression. Adjust.
5301 (pp_c_initializer_list): Use pp_primary_expression.
5302 (c_pretty_printer::c_pretty_printer): Do not assign to
5303 primary_expression.
5304
0691175f
GDR
53052013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
5306
5307 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
5308 * c-pretty-print.c (M_): Remove.
5309 (c_pretty_printer::translate_string): Define.
5310 (pp_c_type_specifier): Use it.
5311 (pp_c_primary_expression): Likewise.
5312 (pp_c_expression): Likewise.
5313
66dfe4c4
GDR
53142013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
5315
5316 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
5317 virtual function.
5318 (pp_c_id_expression): Remove.
5319 (pp_id_expression): Adjust.
5320 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
5321 pp_c_id_expression. Adjust.
5322 (pp_c_postfix_expression): Use pp_id_expression.
5323 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
5324
ca43e9d5
GDR
53252013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
5326
5327 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
5328 member function.
5329 (pp_constant): Adjust.
5330 (pp_c_constant): Remove.
5331 * c-pretty-print.c (c_pretty_printer::constant): Rename from
5332 pp_c_constant. Adjust.
5333 (pp_c_constant)
5334 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
5335 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
5336
da6ca2b5
GDR
53372013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
5338
5339 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
5340 (c_pretty_printer::c_pretty_printer): Declare.
5341 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
5342 c_pretty_printer_init. Adjust.
5343 (print_c_tree): Do not call c_pretty_printer_init.
5344 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
5345
65a372f4
AC
53462013-08-09 Arnaud Charlet <charlet@adacore.com>
5347
5348 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
5349
fd9b0f32
PC
53502013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
5351
5352 PR c++/58080
5353 * c-common.c (pointer_int_sum): Add bool parameter.
5354 * c-common.h (pointer_int_sum): Adjust declaration.
5355
e0aec1e9
GDR
53562013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
5357
5358 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
5359 c_pretty_printer variable.
5360
b066401f
GDR
53612013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
5362
5363 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
5364 (pp_base): Remove.
5365 (pp_c_base): Likewise. Adjust users.
5366 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
5367 (pp_c_whitespace): Do not call pp_base.
5368 (pp_c_left_paren): Likewise.
5369 (pp_c_right_paren): Likewise.
5370 (pp_c_left_brace): Likewise.
5371 (pp_c_right_brace): Likewise.
5372 (pp_c_left_bracket): Likewise.
5373 (pp_c_right_bracket): Likewise.
5374 (pp_c_dot): Likewise.
5375 (pp_c_ampersand): Likewise.
5376 (pp_c_star): Likewise.
5377 (pp_c_arrow): Likewise.
5378 (pp_c_semicolon): Likewise.
5379 (pp_c_complement): Likewise.
5380 (pp_c_exclamation): Likewise.
5381 (pp_c_direct_declarator): Likewise.
5382 (pp_c_ws_string): Likewise.
5383 (pp_c_identifier): Likewise.
5384 (pp_c_statement): Likewise.
5385 (print_c_tree): Likewise.
5386
65e5a578
ESR
53872013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
5388
5389 PR c++/58072
5390 * c-common.c (c_parse_error): Catch user-defined literal tokens and
5391 provide useful error strings.
5392
137a1a27
GDR
53932013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
5394
5395 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
5396 printer functions instead of pp_string or operators and punctuators.
5397 (dump_generic_ada_node): Likewise.
5398 * c-pretty-print.c (pp_c_type_specifier): Likewise.
5399 (pp_c_relational_expression): Likewise.
5400 (pp_c_logical_or_expression): Likewise.
5401
07838b13
GDR
54022013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
5403
5404 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
5405 functions instead of pp_character.
5406 (pp_ada_tree_identifier): Likewise.
5407 (dump_ada_double_name): Likewise.
5408 (dump_ada_function_declaration): Likewise.
5409 (dump_ada_array_domains): Likewise.
5410 (dump_template_types): Likewise.
5411 (dump_generic_ada_node): Likewise.
5412 (print_ada_declaration): Likewise.
5413 (print_ada_struct_decl): Likewise.
5414 * c-pretty-print.c (pp_c_integer_constant): Likewise.
5415
433cc7b0
TT
54162013-07-23 Tom Tromey <tromey@redhat.com>
5417
5418 * c-common.h (enum rid) <RID_GENERIC>: New constant.
5419 * c-common.c (c_common_reswords): Add _Generic.
5420
688010ba
OB
54212013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
5422
5423 * c-common.c: Fix typos.
5424 * c-common.h: Likewise.
5425
2a99e5e6
LL
54262013-07-13 Lubos Lunak <l.lunak@suse.cz>
5427
5428 PR c++/55203
5429 * c-common.c (c_common_attribute_table): Add warn_unused.
5430 (handle_warn_unused_attribute): New.
5431
c26302d5
JJ
54322013-07-10 Jakub Jelinek <jakub@redhat.com>
5433
5434 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
5435 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
5436
dfeadaa0
PC
54372013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
5438
5439 PR c++/57869
5440 * c.opt: Add Wconditionally-supported.
5441
6a2fa4b2
GS
54422013-07-08 Graham Stott <graham.stott@btinternet.com>
5443
adfac8df 5444 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6a2fa4b2
GS
5445 unused variables l_length and l_node.
5446
ecdbd01a 54472013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
5448
5449 PR c/57821
5450 * c-common.c (complete_array_type): Delay folding first index
5451 like other indices. When folding, check for index overflow.
5452
bedc293e
MG
54532013-06-27 Marc Glisse <marc.glisse@inria.fr>
5454
5455 PR c++/57509
5456 * c-common.h (c_build_vec_perm_expr): New complain argument.
5457 * c-common.c (c_build_vec_perm_expr): Likewise.
5458 Use save_expr also in C++.
5459
604b2bfc
GDR
54602013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
5461
5462 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
5463 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
5464 * c-opts.c (c_common_post_options): Likewise.
5465
dfeadaa0 54662013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
713b46fa
BI
5467
5468 * array-notation-common.c (length_mismatch_in_expr): Changed the
5469 parameter type's from a dynamic array to a vec_tree. Also removed
5470 the size parameters.
5471 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
5472 the change above.
5473
2ce86d2e
BI
54742013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
5475
5476 * c-common.h (struct cilkplus_an_parts): New structure.
5477 (struct cilkplus_an_loop_parts): Likewise.
5478 (cilkplus_extract_an_triplets): New prototype.
5479 (fix_sec_implicit_args): Likewise.
5480 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
5481 (fix_sec_implicit_args): Likewise.
604b2bfc 5482
07a6825b
BI
54832013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
5484
5485 * array-notation-common.c (find_inv_trees): Removed an unwanted
5486 typecasting.
5487 * c-common.h (struct inv_list::additional_tcodes): Changed type from
5488 enum rid to enum tree_code.
5489
08346abd
JH
54902013-06-11 Jan Hubicka <jh@suse.cz>
5491
5492 * c-common.c (handle_alias_ifunc_attribute): Do not set
5493 DECL_EXTERNAL for weakref variables.
5494 * c-pragma.c (handle_pragma_weak): Make sure aliases
5495 are not declared as external.
5496
d60f1706
BI
54972013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
5498
5499 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
5500 function from c/c-array-notation.c.
5501 (is_cilkplus_reduce_builtin): Likewise.
5502 (find_rank): Likewise.
5503 (extract_array_notation_exprs): Likewise.
5504 (replace_array_notations): Likewise.
5505 (find_inv_trees): Likewise.
5506 (replace_inv_trees): Likewise.
5507 (contains_array_notation_expr): Likewise.
5508 (find_correct_array_notation_type): Likewise.
5509 * c-common.h (struct inv_list): Moved this struct from the file
5510 c/c-array-notation.c and added a new field called additional tcodes.
5511 (length_mismatch_in_expr_p): New prototype.
5512 (is_cilkplus_reduce_builtin): Likewise.
5513 (find_rank): Likewise.
5514 (extract_array_notation_exprs): Likewise.
5515 (replace_array_notation): Likewise.
5516 (find_inv_trees): Likewise.
5517 (replace_inv_trees): Likewise.
5518 (find_correct_array_notation_type): Likewise.
dfeadaa0 5519
36536d79
BI
55202013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
5521
5522 * c-common.c (c_define_builtins): When cilkplus is enabled, the
5523 function array_notation_init_builtins is called.
5524 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
5525 * c-common.def (ARRAY_NOTATION_REF): New tree.
5526 * c-common.h (build_array_notation_expr): New function declaration.
5527 (build_array_notation_ref): Likewise.
5528 (extract_sec_implicit_index_arg): New extern declaration.
5529 (is_sec_implicit_index_fn): Likewise.
5530 (ARRAY_NOTATION_CHECK): New define.
5531 (ARRAY_NOTATION_ARRAY): Likewise.
5532 (ARRAY_NOTATION_START): Likewise.
5533 (ARRAY_NOTATION_LENGTH): Likewise.
5534 (ARRAY_NOTATION_STRIDE): Likewise.
5535 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
5536 ARRAY_NOTATION_REF.
5537 (pp_c_expression): Likewise.
5538 * c.opt (flag_enable_cilkplus): New flag.
5539 * array-notation-common.c: New file.
5540
f7716d57
JJ
55412013-05-14 Jakub Jelinek <jakub@redhat.com>
5542
5543 PR c++/57274
5544 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
5545
a5e0cd1d
MG
55462013-05-10 Marc Glisse <marc.glisse@inria.fr>
5547
5548 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
5549 vectors.
5550
f6bc1c4a
HS
55512013-05-07 Han Shen <shenhan@google.com>
5552
5553 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
5554
3f12f6e9
SKS
55552013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
5556
5557 * c-common.c (check_user_alignment): Emit error for negative values.
5558
61949153
PC
55592013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
5560
5561 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
5562
e93e18e9
PC
55632013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
5564
5565 * c-cppbuiltin.c (c_cpp_builtins): Do not define
5566 __GXX_EXPERIMENTAL_CXX1Y__.
5567
44d90fe1 55682013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
8e745a17 5569 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
44d90fe1
PC
5570
5571 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
5572 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
5573 to simply use OPT_Wpointer_arith.
5574 (c_sizeof_or_alignof_type): Likewise.
5575
13f39b2e
PC
55762013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
5577
5578 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
5579
4b84d650
JJ
55802013-04-12 Jakub Jelinek <jakub@redhat.com>
5581
5582 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
5583 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
5584 specifiers.
5585
fb037b5d
SB
55862013-04-07 Steven Bosscher <steven@gcc.gnu.org>
5587
5588 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
5589
4e856798
PC
55902013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
5591
5592 * c-common.c (pointer_int_sum): Remove dead code.
5593
4b1baac8
RS
55942013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
5595
5596 PR middle-end/56524
5597 * c-common.c (handle_optimize_attribute): Don't call
5598 save_optabs_if_changed.
5599
0b50e654
JJ
56002013-03-05 Jakub Jelinek <jakub@redhat.com>
5601
5602 PR middle-end/56461
5603 * c-pch.c (pch_init): Free target_validity at the end.
5604
48c41403
JJ
56052013-03-04 Jakub Jelinek <jakub@redhat.com>
5606
5607 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
5608
e664c61c
KS
56092013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
5610 Jakub Jelinek <jakub@redhat.com>
5611
5612 PR sanitizer/56454
5613 * c-common.c (handle_no_sanitize_address_attribute): New function.
5614 (c_common_attribute_table): Add no_sanitize_address attribute.
5615 (handle_no_address_safety_analysis_attribute): Add
5616 no_sanitize_address attribute, not no_address_safety_analysis
5617 attribute.
5618
a475fd3d 56192013-02-18 Aldy Hernandez <aldyh@redhat.com>
135204dd
AH
5620
5621 PR target/52555
5622 * c-common.c (handle_optimize_attribute): Call
5623 save_optabs_if_changed.
5624
f6007d99
JJ
56252013-02-18 Jakub Jelinek <jakub@redhat.com>
5626 Steven Bosscher <steven@gcc.gnu.org>
5627
5628 PR pch/54117
5629 * c-opts.c (c_common_post_options): If debug info is enabled
5630 and non-dwarf*, refuse to load PCH files and when writing PCH
5631 file warn.
5632
cf35e2b1
JJ
56332013-02-05 Jakub Jelinek <jakub@redhat.com>
5634
5635 PR middle-end/56167
5636 * c-common.c (handle_error_attribute): Fix condition.
5637
32887460
JJ
56382013-01-30 Jakub Jelinek <jakub@redhat.com>
5639
5640 PR c++/55742
5641 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
5642
5af057d8
JM
56432013-01-18 Jason Merrill <jason@redhat.com>
5644
5645 PR target/54908
5646 * c.opt (-fextern-tls-init): New.
5647 * c-opts.c (c_common_post_options): Handle it.
5648
cc83c823
JJ
56492013-01-09 Jakub Jelinek <jakub@redhat.com>
5650
5651 PR c/48418
5652 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
5653 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
5654 and is either negative or bigger or equal to type precision
5655 of the first operand.
5656
a859517f
MP
56572012-12-03 Marek Polacek <polacek@redhat.com>
5658
5659 PR c/55570
5660 * c-common.c (check_user_alignment): Swap order of tests,
5661 check TREE_CODE first.
5662
2d7aa578
ESR
56632012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
5664
5665 PR c++/52654
5666 * c-common.h (overflow_type): New enum.
5667 (build_userdef_literal): Add overflow_type argument.
5668 (tree_userdef_literal): Add overflow_type.
5669 (USERDEF_LITERAL_OVERFLOW): New access macro.
5670 * c-common.c (build_userdef_literal): Add overflow_type
5671 argument.
5672 * c-lex.c (c_lex_with_flags): Add overflow_type to
5673 build_userdef_literal calls.
5674 (interpret_integer, interpret_float): Add overflow_type argument.
5675
cc3c4f62
RB
56762012-11-28 Richard Biener <rguenther@suse.de>
5677
5678 PR c/35634
5679 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
5680 here and use a type with proper overflow behavior for types that would
5681 need to be promoted for the arithmetic.
5682
77bc5132
JJ
56832012-11-23 Jakub Jelinek <jakub@redhat.com>
5684
5685 PR sanitizer/55435
5686 * c-common.c (handle_no_address_safety_analysis_attribute): New
5687 function.
5688 (c_common_attribute_table): Add no_address_safety_analysis.
5689
5dc99c46
SB
56902012-11-16 Simon Baldwin <simonb@google.com>
5691
5692 * c.opt: Add f[no-]canonical-system-headers.
5693 * c-opts.c (c_common_handle_option): Handle
5694 OPT_fcanonical_system_headers.
5695
a4a0016d
ESR
56962012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
5697
5698 PR c++/54413
5699 * c-opts.c (c_common_handle_option): Set new flags.
5700 * c.opt: Describe new flags.
5701
7dbb85a7
JM
57022012-11-09 Jason Merrill <jason@redhat.com>
5703
5704 * c.opt (Wabi-tag): New.
5705
ad7bac31
AK
57062012-11-09 Andi Kleen <ak@linux.intel.com>
5707
5708 PR 55139
5709 * c-common.c (get_atomic_generic_size): Mask with
8e745a17 5710 MEMMODEL_MASK
ad7bac31 5711
7332899a
MLI
57122012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
5713
5714 PR c/53063
5715 * c.opt (Wformat): Make it Alias Wformat=1.
5716 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
5717 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
5718 LangEnabledBy.
5719 (Wformat=): RejectNegative. Use LangEnabledBy.
5720 (Wnonnull): Use LangEnabledBy.
5721 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
5722 * c-format.c (set_Wformat): Delete.
5723 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
8e745a17
JJ
5724 (maybe_read_dollar_number): Likewise.
5725 (avoid_dollar_number): Likewise.
5726 (finish_dollar_format_checking): Likewise.
5727 (check_format_info): Likewise.
5728 (check_format_info_main): Likewise.
5729 (check_format_types): Likewise.
5730 (format_type_warning): Likewise.
5731 * c-common.c (int): Likewise.
5732 (check_function_sentinel): Likewise.
5733 * c-common.h (warn_format,set_Wformat): Do not declare here.
7332899a 5734
34a180a6
MLI
57352012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
5736
5737 PR c/53063
5738 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
5739 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
5740 Use LangEnabledBy.
5741 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
5742 common.opt.
5743 (Wvariadic-macros): Init(1).
5744 * c-opts.c (c_common_handle_option): Do not handle them
5745 explicitly.
5746 (c_common_post_options): Likewise.
5747 (sanitize_cpp_opts): warn_unused_macros is now
5748 cpp_warn_unused_macros.
5749 (push_command_line_include): Likewise.
5750 * c-common.c (warn_unknown_pragmas): Do not define.
5751 * c-common.h (warn_unknown_pragmas): Do not declare.
5752
3f46d6a5
MLI
57532012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
5754
5755 PR c/51294
5756 * c-common.c (conversion_warning): Handle conditional expressions.
5757
880661a4
JW
57582012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
5759
5760 PR c++/54930
5761 * c.opt (Wreturn_local_addr): Define new option.
5762
4514a96b
JM
57632012-10-25 Jason Merrill <jason@redhat.com>
5764
f14edc1a
JM
5765 * c.opt (Wvirtual-move-assign): New.
5766
4514a96b
JM
5767 * c.opt (Winherited-variadic-ctor): New.
5768
93100c6b
MG
57692012-10-25 Marc Glisse <marc.glisse@inria.fr>
5770
5771 PR c++/54427
5772 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
5773
1efcb8c6
JM
57742012-10-23 Joseph Myers <joseph@codesourcery.com>
5775
5776 * c-common.h (pch_cpp_save_state): Declare.
5777 * c-target.def (c_preinclude): New hook.
5778 * c-opts.c (done_preinclude): New.
5779 (push_command_line_include): Handle default preincluded header.
5780 (cb_file_change): Call pch_cpp_save_state when calling
5781 push_command_line_include.
5782 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
5783 (pch_cpp_save_state): New.
5784 (pch_init): Call pch_cpp_save_state conditionally, instead of
5785 calling cpp_save_state.
5786
4a0ae68e
MLI
57872012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
5788
5789 PR c/53063
5790 PR c/40989
5791 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
5792 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
5793 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
5794 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
5795 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
5796 * c-opts.c (c_common_handle_option): Remove explicit handling from
5797 here.
5798 (c_common_post_options): Likewise.
5799
67e4210b
EB
58002012-10-18 Eric Botcazou <ebotcazou@adacore.com>
5801
5802 * c-ada-spec.c (LOCATION_COL): Delete.
5803 (compare_location): New function.
5804 (compare_node): Use it.
5805 (compare_comment): Likewise.
5806
65d4f2cd
MLI
58072012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
5808
5809 PR c/53063
5810 PR c/40989
5811 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
5812 * c-opts.c (c_common_handle_option): Do not set them here. Add
5813 comment.
5814 (c_common_post_options): Likewise.
5815
909881cb
EB
58162012-10-16 Eric Botcazou <ebotcazou@adacore.com>
5817
5818 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
5819 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
5820 Remove POINTER_TYPE handling, add large unsigned handling and use
5821 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
5822
3a785c97
JJ
58232012-10-12 Jakub Jelinek <jakub@redhat.com>
5824
5825 PR c/54381
5826 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
5827 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
5828 locs and array of 3 trees instead of just single loc and single
5829 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
5830 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
5831 For *cmp* builtins that take two sources strings report warnings
5832 about first and second source, not about destination and source.
5833
5e54f81d
MG
58342012-10-12 Marc Glisse <marc.glisse@inria.fr>
5835
5836 PR c++/53055
5837 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
5838
f5b02f1e
EB
58392012-10-11 Eric Botcazou <ebotcazou@adacore.com>
5840
5841 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
5842 declaring something coming from another file.
5843
b46dbc6c
AC
58442012-10-10 Arnaud Charlet <charlet@adacore.com>
5845
f5b02f1e 5846 PR ada/54845
b46dbc6c
AC
5847 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
5848
5d9de0d0
PC
58492012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
5850
5851 PR c++/54194
5852 * c-common.c (warn_about_parentheses): Add location_t parameter;
5853 use EXPR_LOC_OR_LOC.
5854 * c-common.h: Update declaration.
5855
a212e43f
MG
58562012-10-09 Marc Glisse <marc.glisse@inria.fr>
5857
5858 PR c++/54427
5859 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
5860 more operations. Make error messages optional.
5861 * c-common.h (enum stv_conv): Moved from c-typeck.c.
5862 (scalar_to_vector): Declare.
5863
b1db7f91
JM
58642012-10-08 Jason Merrill <jason@redhat.com>
5865
5866 * c-common.c (c_common_reswords): Add thread_local.
5867
e28d52cf
DS
58682012-10-08 Dodji Seketeli <dodji@redhat.com>
5869
5870 PR c++/53528 C++11 attribute support
5871 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
5872 new functions.
5873 * c-common.c (check_cxx_fundamental_alignment_constraints): New
5874 static function.
5875 (handle_aligned_attribute): In choose strictest alignment
5876 among many. Use new check_cxx_fundamental_alignment_constraints.
5877 (handle_transparent_union_attribute): In c++11 attribute syntax,
5878 don't look through typedefs.
5879
3b78de56
AC
58802012-10-04 Arnaud Charlet <charlet@adacore.com>
5881
5882 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
5883 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
5884 out of dumpfile.h.
5885
6040bb5f
DC
58862012-09-25 Dehao Chen <dehao@google.com>
5887
5888 PR middle-end/54645
3b78de56 5889 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
6040bb5f
DC
5890 map when read in the pch.
5891
3f8257db 58922012-09-18 Arnaud Charlet <charlet@adacore.com>
0b07a57e
AC
5893
5894 * c-ada-spec.c: Style fixes.
5895
3f8257db 58962012-09-18 Thomas Quinot <quinot@adacore.com>
da5182be
TQ
5897
5898 * c.opt (-fada-spec-parent): Define new command line switch.
5899 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
5900 is specified, generate binding spec as a child of the specified unit.
5901
0ccb505d
PC
59022012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
5903 Manuel López-Ibáñez <manu@gcc.gnu.org>
5904
5905 PR c++/53210
5906 * c.opt ([Winit-self]): Enabled by -Wall in C++.
5907
c583af79
AC
59082012-08-23 Arnaud Charlet <charlet@adacore.com>
5909
5910 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
5911 for pointers, and add missing Convention C pragma.
5912 (print_ada_struct_decl): Add missing aliased keyword.
5913 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
5914
1a4049e7
JJ
59152012-08-17 Jakub Jelinek <jakub@redhat.com>
5916
5917 * c-common.c (sizeof_pointer_memaccess_warning): New function.
5918 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
5919 * c-opts.c (c_common_handle_option): Enable it for -Wall.
5920 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
5921 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
5922
70b5e7dc
RG
59232012-08-10 Richard Guenther <rguenther@suse.de>
5924
5925 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
5926
f8923f7e
SB
59272012-08-07 Steven Bosscher <steven@gcc.gnu.org>
5928
5929 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
5930 instead of separate pp_newline and pp_flush.
5931 (print_c_tree): Likewise.
5932
e45abe1f
RH
59332012-07-26 Richard Henderson <rth@redhat.com>
5934
5935 * c-common.c (handle_hot_attribute): Allow labels.
5936 (handle_cold_attribute): Likewise.
5937
332f1d24
JJ
59382012-07-20 Jakub Jelinek <jakub@redhat.com>
5939
5940 PR c++/28656
5941 * c-common.c (check_function_nonnull): Handle multiple nonnull
5942 attributes properly.
5943
7ee2468b
SB
59442012-07-16 Steven Bosscher <steven@gcc.gnu.org>
5945
5946 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
5947 * c-ada-spec.c: Likewise.
5948 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
5949
ee7b28eb
SB
59502012-07-14 Steven Bosscher <steven@gcc.gnu.org>
5951
5952 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
5953 Remove code conditional on it.
5954
6bdf3519
SB
59552012-07-11 Steven Bosscher <steven@gcc.gnu.org>
5956
5957 * c-gimplify.c: Do not include basic-block.h.
5958 * c-common.c: Do not include linfuncs.h.
5959
532aafad
SB
59602012-07-08 Steven Bosscher <steven@gcc.gnu.org>
5961
5962 * c-common.h: Include tree.h.
5963
8d0d1915
JM
59642012-07-02 Jason Merrill <jason@redhat.com>
5965
5966 PR c++/53524
5967 * c-common.c (get_priority): Call default_conversion.
5968
fbc873ad
UB
59692012-07-01 Uros Bizjak <ubizjak@gmail.com>
5970
5971 * c-pch.c (c_common_write_pch): Remove unused variables.
5972
d4a10d0a
SB
59732012-06-29 Steven Bosscher <steven@gcc.gnu.org>
5974
5975 * cppspec.c: Moved from gcc/ to here.
5976
6f3a2e23
KT
59772012-06-27 Kai Tietz <ktietz@redhat.com>
5978
5979 PR preprocessor/37215
5980 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
5981
8ca92d04
SB
59822012-06-21 Steven Bosscher <steven@gcc.gnu.org>
5983
5984 * c-common.h (c_common_print_pch_checksum): Remove.
5985 * c-pch.c: Do not include output.h.
5986 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
5987 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
5988 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
5989 (struct c_pch_header): Remove.
5990 (get_ident): Update gpch version.
5991 (pch_init): Do not print executable_checksum to asm_out_file.
5992 Do not fail if there is no asm_out_file to read back from. Set
5993 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
5994 (c_common_write_pch): Verify that nothing was written to asm_out_file
5995 since pch_init was called. Do not write a c_pch_header, and do not
5996 copy from asm_out_file to the PCH.
5997 (c_common_read_pch): Do not read a c_pch_header, and do not restore
5998 the content of asm_out_file from the PCH.
5999 (c_common_print_pch_checksum): Remove.
6000 * c-opts.c (c_common_init): Print out executable_checksum directly.
6001
70f42967
SB
60022012-06-19 Steven Bosscher <steven@gcc.gnu.org>
6003
6004 * c-target.def (objc_declare_unresolved_class_reference,
6005 objc_declare_class_definition): Add new hooks.
6006
a8781821
SB
60072012-06-19 Steven Bosscher <steven@gcc.gnu.org>
6008
6009 * c-lex.c: Do not include output.h.
6010 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
6011 Remove uses of ASM_OUTPUT_IDENT.
6012
9e1a8dd1
RR
60132012-06-15 Marc Glisse <marc.glisse@inria.fr>
6014
6015 PR c++/51033
6016 * c-common.h (c_build_vec_perm_expr): Move decl here.
6017 * c-common.c (c_build_vec_perm_expr): Move definition
6018 here.
6019
6f07a821
SB
60202012-06-06 Steven Bosscher <steven@gcc.gnu.org>
6021
6022 * c.opt (fconserve-space): Turn into a no-op.
6023
9faeb493 60242012-06-04 Sterling Augustine <saugustine@google.com>
c265f413
SA
6025
6026 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
6027 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
6028 both the start and end of the function.
6029
a4b7d13c
SB
60302012-06-04 Steven Bosscher <steven@gcc.gnu.org>
6031
6032 * c-common.c: Do not include output.h.
6033 * c-pragma.c: Likewise.
6034
c265f413
SA
60352012-06-04 Steven Bosscher <steven@gcc.gnu.org>
6036
6037 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
6038 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
6039 (lang_decl_name): Handle namespace decls.
6040
be7a421e
SB
60412012-05-31 Steven Bosscher <steven@gcc.gnu.org>
6042
6043 * c-ada-spec.c: Do not include output.h.
6044 * c-semantics.c: Likewise.
6045
65de6659
JM
60462012-05-29 Joseph Myers <joseph@codesourcery.com>
6047
6048 * c-common.c: Fix typo.
6049
ca5f4331
MM
60502012-05-29 Michael Matz <matz@suse.de>
6051
6052 * c-common.h (c_expand_decl): Remove prototype.
6053
4f7f7aca
MLI
60542012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
6055
6056 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
6057 * c-opts.c (c_common_handle_option): Remove code handling
6058 warn_missing_braces.
6059
4a792f9b
PC
60602012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
6061
6062 PR c++/25137
6063 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
6064 -Wmissing_braces.
6065
650dc14a
DS
60662012-05-22 Dodji Seketeli <dodji@redhat.com>
6067
6068 PR c++/53322
6069 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
6070
9b095bf1
MLI
60712012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
6072
6073 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
6074 * c-opts.c (c_common_handle_option): Do not handle explicitly
6075 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
6076
0b2c4be5
DS
60772012-05-16 Dodji Seketeli <dodji@redhat.com>
6078
6079 PR preprocessor/7263
6080 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
6081 to cpp_classify_number. For diagnostics, use the precise location
6082 instead of the global input_location.
6083
a1bde5af
PC
60842012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
6085
d02924ef 6086 PR c++/11856
a1bde5af
PC
6087 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
6088
d1ede5f4
BS
60892012-05-14 Bernd Schmidt <bernds@codesourcery.com>
6090
a1bde5af 6091 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
d1ede5f4 6092
f2bc201f
MLI
60932012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
6094
6095 PR 53063
6096 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
6097 Wreorder): Use LangEnabledBy.
6098 * c-opts.c (c_common_handle_option): Do not enable them
6099 explicitly. Call lang-specific generated functions.
6100 (c_common_post_options): Do not set them here.
6101
95744782
MLI
61022012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
6103
6104 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
6105 Wmissing-field-initializers,Wmissing-parameter-type,
6106 Wold-style-declaration,Woverride-init): Use EnabledBy.
6107 * c-opts.c (c_common_post_options): Do not set here explicitly.
6108
7d5a5747
MLI
61092012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
6110
6111 PR 53063
6112 * c-opts.c (c_common_handle_option): Use handle_generated_option
6113 to enable sub-options.
6114
5a3c9cf2
PC
61152012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
6116
6117 PR c++/53158
6118 * c-common.c (warnings_for_convert_and_check): Use warning_at.
6119
3ac8781c
RG
61202012-05-10 Richard Guenther <rguenther@suse.de>
6121
6122 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
6123 adjust commentary about TYPE_IS_SIZETYPE types.
6124
1e537948
MLI
61252012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
6126
6127 PR c++/53261
6128 * c-common.c (warn_logical_operator): Check that argument of
6129 integer_zerop is not NULL.
6130
f2c4a785
MLI
61312012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
6132
6133 PR c/43772
6134 * c-common.c (warn_logical_operator): Do not warn if either side
6135 is already true or false.
6136
50f305ca
MLI
61372012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
6138
6139 PR c/51712
6140 * c-common.c (expr_original_type): New.
6141 (shorten_compare): Do not warn for enumeration types.
6142
0c3641b0
MLI
61432012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
6144
6145 * c.opt (fpermissive): Add Var(flag_permissive).
6146
7edaa4d2
MG
61472012-04-30 Marc Glisse <marc.glisse@inria.fr>
6148
6149 PR c++/51033
6150 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
6151 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
6152
b9c8da34
DS
61532012-04-30 Dodji Seketeli <dodji@redhat.com>
6154
6155 Add -Wvarargs option
6156 * c.opt (Wvarargs): Define new option.
6157
e6c69da0
MLI
61582012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
6159
6160 * c-common.c (check_function_arguments): Replace
6161 Wmissing-format-attribute with Wsuggest-attribute=format.
6162
90137d8f
MLI
61632012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
6164
6165 * c.opt (Wsuggest-attribute=format): New. Alias of
6166 Wmissing-format-attribute.
6167 * c-format.c (decode_format_type): Replace
6168 Wmissing-format-attribute with Wsuggest-attribute=format.
6169 (check_function_format): Likewise.
6170
9faeb493 61712012-04-27 Ollie Wild <aaw@google.com>
7f5f5f98
OW
6172
6173 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
6174 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
6175 * c.opt: Add Wliteral-suffix.
6176
c1771a20
MLI
61772012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
6178
6179 PR c/44774
6180 * c.opt (Wpedantic): New.
6181 (pedantic): Alias Wpedantic.
6182 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
6183 (c_common_post_options): Likewise.
6184 (sanitize_cpp_opts): Likewise.
6185 * c-lex.c (interpret_float): Likewise.
6186 * c-format.c (check_format_types): Likewise.
6187 * c-common.c (pointer_int_sum): Likewise.
6188 (c_sizeof_or_alignof_type): Likewise.
6189 (c_add_case_label): Likewise.
6190 (c_do_switch_warnings): Likewise.
6191 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
6192
04b391c1
JM
61932012-04-15 Jason Merrill <jason@redhat.com>
6194
6195 PR c++/52818
6196 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
6197 (C_STD_NAME): Distinguish between C++98 and C++11.
6198
ac868f29
EB
61992012-04-11 Eric Botcazou <ebotcazou@adacore.com>
6200
6201 PR target/52624
6202 * c-common.h (uint16_type_node): Rename into...
6203 (c_uint16_type_node): ...this.
6204 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
6205 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
6206
fd4116f4
MLI
62072012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
6208
6209 * c-common.c (warn_if_unused_value): Move definition to here.
6210 * c-common.h (warn_if_unused_value): Move declaration to here.
6211
573ac65e
WB
62122012-03-23 William Bader <williambader@hotmail.com>
6213
6214 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
6215
552b8185
JM
62162012-03-20 Jason Merrill <jason@redhat.com>
6217
6218 * c-common.h (enum cxx_dialect): Add cxx1y.
6219 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
6220 test.
6221 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
6222 * c-opts.c (c_common_post_options): Likewise.
6223 (set_std_cxx1y): New.
6224 (c_common_handle_option): Call it.
6225 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
6226
04398fa8
PC
62272012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
6228
6229 PR c++/14710
6230 * c.opt ([Wuseless-cast]): Add.
6231
d2a12ae7
RG
62322012-03-16 Richard Guenther <rguenther@suse.de>
6233
6234 * c-pretty-print.c (pp_c_initializer_list): Adjust.
6235
a12bf402
MLI
62362012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
6237
6238 PR c++/44783
6239 * c.opt (ftemplate-backtrace-limit) Add.
6240
5c30094f
RO
62412012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6242
6243 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
6244 handling.
6245 * c-pragma.c (handle_pragma_extern_prefix): Remove.
6246 (init_pragma): Don't register extern_prefix.
6247
21fa2faf
RG
62482012-03-12 Richard Guenther <rguenther@suse.de>
6249
6250 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
6251 (builtin_type_for_size): Likewise.
6252
e3793c6f
JJ
62532012-02-13 Jakub Jelinek <jakub@redhat.com>
6254
6255 PR c++/52215
6256 * c-common.c (sync_resolve_params): Don't decide whether to convert
6257 or not based on TYPE_SIZE comparison, convert whenever arg_type
6258 is unsigned INTEGER_TYPE.
6259
93286335
PC
62602012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
6261
6262 PR c/52118
6263 * c.opt ([Wunused-local-typedefs]): Fix description.
6264
7a421706
MS
62652012-01-24 Mike Stump <mikestump@comcast.net>
6266
6267 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
6268 exactly.
6269
ba9b1f11
RG
62702012-01-18 Richard Guenther <rguenther@suse.de>
6271
6272 * c-opts.c (c_common_post_options): Reset LTO flags if
6273 we are about to generate a PCH.
6274
465406be
PC
62752012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
6276
6277 PR c++/51777
6278 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
6279 use pp_unsigned_wide_integer.
6280
aee15221
RG
62812012-01-10 Richard Guenther <rguenther@suse.de>
6282
6283 PR middle-end/51806
6284 * c-opts.c (c_common_handle_option): Move -Werror handling
6285 to language independent code.
6286
5720c0dc
RG
62872012-01-05 Richard Guenther <rguenther@suse.de>
6288
6289 PR middle-end/51764
6290 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
6291 from common.opt.
6292
73ac190a
PC
62932011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
6294
6295 PR c++/51316
6296 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
6297 of array types with an unknown bound.
6298
48b0b196
JM
62992011-12-20 Joseph Myers <joseph@codesourcery.com>
6300
6301 * c-common.c (flag_isoc99): Update comment to refer to C11.
6302 (flag_isoc1x): Change to flag_isoc11.
6303 * c-common.h (flag_isoc99): Update comment to refer to C11.
6304 (flag_isoc1x): Change to flag_isoc11.
6305 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
6306 C11.
6307 * c-opts.c (set_std_c1x): Change to set_std_c11.
6308 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
6309 Call set_std_c11.
6310 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
6311 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
6312 * c.opt (std=c1x): Change to std=c11. Document as non-draft
6313 standard.
6314 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
6315 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
6316 (std=gnu1x): Make alias of std=gnu11.
6317
d58d6eb5
JM
63182011-12-19 Jason Merrill <jason@redhat.com>
6319
6320 PR c++/51228
6321 * c-common.c (handle_transparent_union_attribute): Check the first
6322 field if the type is complete.
6323
b3908fcc
JW
63242011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
6325
6326 PR libstdc++/51365
6327 * c-common.c (RID_IS_FINAL): Add.
6328 * c-common.h (RID_IS_FINAL): Add.
6329
fea3ca91
IS
63302011-11-30 Iain Sandoe <iains@gcc.gnu.org>
6331
6332 * c.opt (fgnu-runtime): Provide full description.
6333 (fnext-runtime): Likewise.
6334 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
6335
62bad7cd
AM
63362011-11-28 Andrew MacLeod <amacleod@redhat.com>
6337
6338 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
6339 predefines in one place. Add LOCK_FREE predefines.
6340 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
6341 new func.
6342
c466c4ff
AM
63432011-11-24 Andrew MacLeod <amacleod@redhat.com>
6344
6345 PR c/51256
9faeb493 6346 * c-common.c (get_atomic_generic_size): Check for various error
c466c4ff 6347 conditions
9faeb493
UB
6348 (resolve_overloaded_atomic_exchange,
6349 resolve_overloaded_atomic_compare_exchange,
c466c4ff
AM
6350 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
6351 error_mark_node for error conditions.
9faeb493 6352
a5952633
RG
63532011-11-08 Richard Guenther <rguenther@suse.de>
6354
6355 PR middle-end/51010
6356 c-family/
6357
0a35513e
AH
63582011-11-07 Richard Henderson <rth@redhat.com>
6359 Aldy Hernandez <aldyh@redhat.com>
6360 Torvald Riegel <triegel@redhat.com>
6361
6362 Merged from transactional-memory.
6363
6364 * c-common.c (handle_tm_wrap_attribute,
6365 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
6366 (struct c_common_reswords): Added __transaction* keywords.
6367 (struct c_common_attribute_table): Added transaction* and tm_regparm
6368 attributes.
6369 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
6370 masks.
6371 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
6372 find_tm_attribute): Declare.
6373
6d87092d
JM
63742011-11-07 Jason Merrill <jason@redhat.com>
6375
6376 PR c++/35688
6377 * c-common.c, c-common.h: Revert yesterday's changes.
6378
8e7860a1
JM
63792011-11-06 Jason Merrill <jason@redhat.com>
6380
6381 PR c++/35688
6382 * c-common.c (decl_has_visibility_attr): Split out from...
6383 (c_determine_visibility): ...here.
6384 * c-common.h: Declare it.
6385
d19fa6b5
JM
63862011-11-06 Joseph Myers <joseph@codesourcery.com>
6387
6388 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
6389 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
6390 type.
6391 (check_user_alignment): New. Split out of
6392 handle_aligned_attribute. Disallow integer constants with
6393 noninteger types. Conditionally allow zero.
6394 (handle_aligned_attribute): Use check_user_alignment.
6395 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
6396
86951993
AM
63972011-11-06 Andrew MacLeod <amacleod@redhat.com>
6398 Richard Henderson <rth@redhat.com>
6399
6400 Merged from cxx-mem-model.
6401
6402 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
9faeb493 6403 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
86951993
AM
6404 parameters that are the same type size.
6405 (get_atomic_generic_size): New. Find size of generic
6406 atomic function parameters and do typechecking.
6407 (add_atomic_size_parameter): New. Insert size into parameter list.
6408 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
6409 either __atomic_exchange_n or external library call.
9faeb493 6410 (resolve_overloaded_atomic_compare_exchange): Restructure
86951993 6411 __atomic_compare_exchange to either _n variant or external library call.
9faeb493 6412 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
86951993
AM
6413 __atomic_load_n or an external library call.
6414 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
6415 __atomic_store_n or an external library call.
6416 (resolve_overloaded_builtin): Handle new __atomic builtins.
6417
cf9e9959
EB
64182011-11-04 Eric Botcazou <ebotcazou@adacore.com>
6419
6420 PR c++/50608
6421 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
6422 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
6423 <INDIRECT_REF>: Return the argument.
6424 <ARRAY_REF>: Remove special code for negative offset.
6425 Call fold_build_pointer_plus instead of size_binop.
6426 (fold_offsetof): Remove STOP_REF argument and adjust.
6427 * c-common.h (fold_offsetof_1): Declare.
6428 (fold_offsetof): Remove STOP_REF argument.
6429
25339f10
JM
64302011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
6431
6432 PR c++/50810
6433 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
6434 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
6435 Wnarrowing for C++0x and C++98.
6436 * c.opt ([Wnarrowing]): Update.
6437
89401152
PC
64382011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
6439
6440 PR c++/44277
6441 * c.opt: Add Wzero-as-null-pointer-constant.
6442
97e3ad20
JM
64432011-10-31 Jason Merrill <jason@redhat.com>
6444
15694fdd
JM
6445 * c.opt (-fdeduce-init-list): Off by default.
6446
97e3ad20
JM
6447 PR c++/50920
6448 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
6449 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
6450 and -Wc++11-compat.
6451 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
6452
fb9120e3
RAV
64532011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
6454
6455 PR c++/30066
6456 * c.opt (fvisibility-inlines-hidden): Description change.
6457
3ce4f9e4
ESR
64582011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
6459
6460 Implement C++11 user-defined literals.
6461 * c-common.c (build_userdef_literal): New.
6462 * c-common.def: New tree code.
6463 * c-common.h (tree_userdef_literal): New tree struct and accessors.
6464 * c-lex.c (interpret_float): Add suffix parm.
6465 (c_lex_with_flags): Build literal tokens.
6466
5f53c243
PC
64672011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
6468
6469 PR c++/50841
6470 Revert:
6471 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
6472
6473 PR c++/50810
6474 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
6475 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
6476 Wnarrowing for C++0x and C++98.
6477 * c.opt ([Wnarrowing]): Update.
6478
263734e1
PC
64792011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
6480
6481 PR c++/50810
6482 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
6483 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
6484 Wnarrowing for C++0x and C++98.
6485 * c.opt ([Wnarrowing]): Update.
6486
d2e312d7
PC
64872011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
6488
6489 PR c++/45385
6490 * c-common.c (conversion_warning): Remove code looking for
6491 artificial operands.
6492
d17687f6
DS
64932011-10-18 Dodji Seketeli <dodji@redhat.com>
6494
6495 PR bootstrap/50760
6496 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
9faeb493 6497 !NO_IMPLICIT_EXTERN_C.
d17687f6 6498
fc8396e9
PC
64992011-10-17 Michael Spertus <mike_spertus@symantec.com>
6500
6501 * c-common.c (c_common_reswords): Add __bases,
6502 __direct_bases.
6503 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
6504
65052011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
6506
6507 PR c++/50757
6508 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
6509
847e697a
TT
65102011-10-15 Tom Tromey <tromey@redhat.com>
6511 Dodji Seketeli <dodji@redhat.com>
6512
6513 * c.opt (fdebug-cpp): New option.
6514 * c-opts.c (c_common_handle_option): Handle the option.
6515 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
6516 output stream in parameter. Factorized from ...
6517 (maybe_print_line): ... this. Dump location debug information when
6518 -fdebug-cpp is in effect.
6519 (print_line_1): New static function. Takes an output stream in
6520 parameter. Factorized from ...
6521 (print_line): ... here. Dump location information when -fdebug-cpp
6522 is in effect.
6523 (scan_translation_unit): Dump location information when
6524 -fdebug-cpp is in effect.
6525
92582b75
TT
65262011-10-15 Tom Tromey <tromey@redhat.com>
6527 Dodji Seketeli <dodji@redhat.com>
6528
6529 * c.opt (ftrack-macro-expansion): New option. Handle it with and
6530 without argument.
6531 * c-opts.c (c_common_handle_option)<case
6532 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
6533 cases. Handle -ftrack-macro-expansion with and without argument.
6534
46427374
TT
65352011-10-15 Tom Tromey <tromey@redhat.com>
6536 Dodji Seketeli <dodji@redhat.com>
6537
6538 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
6539 (print_line, cb_define, do_line_change): Adjust to avoid touching
6540 the internals of struct line_map. Use the public API instead.
6541 * c-pch.c (c_common_read_pch): Likewise.
6542 * c-lex.c (fe_file_change): Likewise.
6543
fc8396e9
PC
65442011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
6545
6546 PR c++/17212
6547 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
6548
65492011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
6550
6551 PR c++/33067
6552 * c-pretty-print.c (pp_c_floating_constant): Output
6553 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
6554
e79983f4
MM
65552011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
6556
6557 * c-common.c (def_builtin_1): Delete old interface with two
6558 parallel arrays to hold standard builtin declarations, and replace
6559 it with a function based interface that can support creating
6560 builtins on the fly in the future. Change all uses, and poison
6561 the old names. Make sure 0 is not a legitimate builtin index.
6562 * c-omp.c (c_finish_omp_barrier): Ditto.
6563 (c_finish_omp_taskwait): Ditto.
6564 (c_finish_omp_flush): Ditto.
6565
6637388f
TG
65662011-10-11 Tristan Gingold <gingold@adacore.com>
6567
6568 * c.opt: (fallow-parameterless-variadic-functions): New.
6569
3797cb21
DS
65702011-09-08 Dodji Seketeli <dodji@redhat.com>
6571
6572 PR c++/33255 - Support -Wunused-local-typedefs warning
6573 * c-common.h (struct c_language_function::local_typedefs): New
6574 field.
9faeb493
UB
6575 (record_locally_defined_typedef, maybe_record_typedef_use)
6576 (maybe_warn_unused_local_typedefs): Declare new functions.
3797cb21 6577 * c-common.c (record_locally_defined_typedef)
9faeb493
UB
6578 (maybe_record_typedef_use)
6579 (maybe_warn_unused_local_typedefs): Define new functions.
3797cb21
DS
6580 * c.opt: Declare new -Wunused-local-typedefs flag.
6581
693ddb1b
EB
65822011-09-06 Eric Botcazou <ebotcazou@adacore.com>
6583
6584 PR middle-end/50266
6585 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
6586 computations.
6587
830c740f
RG
65882011-09-05 Richard Guenther <rguenther@suse.de>
6589
6590 * c-common.c (complete_array_type): Use ssize_int (-1) instead
6591 of integer_minus_one_node for empty array upper bounds.
6592
892a371f
DS
65932011-08-28 Dodji Seketeli <dodji@redhat.com>
6594
6595 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
6596 it's the first time it's being called on this main TU.
6597
0e3fdb48
RB
65982011-08-24 Richard Guenther <rguenther@suse.de>
6599
6600 PR c/49396
6601 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
6602
66032011-08-22 Gabriel Charette <gchare@google.com>
e3dfef44
GC
6604
6605 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
6606 defined in cpp_init_builtins and c_cpp_builtins.
6607
d4a83c10
JM
66082011-08-19 Joseph Myers <joseph@codesourcery.com>
6609
6610 * c-common.c (c_common_reswords): Add __builtin_complex.
6611 * c-common.h (RID_BUILTIN_COMPLEX): New.
6612
bbceee64
JM
66132011-08-18 Joseph Myers <joseph@codesourcery.com>
6614
6615 * c-common.c (c_common_reswords): Add _Noreturn.
6616 (keyword_is_function_specifier): Handle RID_NORETURN.
6617 * c-common.h (RID_NORETURN): New.
6618
3f8257db 66192011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
0e3a99ae
AS
6620
6621 * c-common.c (unsafe_conversion_p): New function. Check if it is
6622 unsafe to convert an expression to the type.
6623 (conversion_warning): Adjust, use unsafe_conversion_p.
6624 * c-common.h (unsafe_conversion_p): New function declaration.
6625
20906c66
JJ
66262011-08-02 Jakub Jelinek <jakub@redhat.com>
6627
6628 * c-common.h (c_finish_omp_atomic): Adjust prototype.
6629 (c_finish_omp_taskyield): New prototype.
6630 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
6631 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
6632 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
6633 or RHS1 have side-effects, evaluate those too in the right spot,
6634 if it is a decl and LHS is also a decl, error out if they
6635 aren't the same.
6636 (c_finish_omp_taskyield): New function.
6637 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
6638 * c-pragma.c (omp_pragmas): Add taskyield.
6639 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
6640 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
6641 PRAGMA_OMP_CLAUSE_MERGEABLE.
6642
770e5a2e
DS
66432011-07-25 Dodji Seketeli <dodji@redhat.com>
6644
6645 * c-common.h (set_underlying_type): Remove parm name from
6646 declaration.
6647
1baae426
RG
66482011-07-25 Romain Geissler <romain.geissler@gmail.com>
6649
6650 * c-pretty-print.h: Search c-common.h in c-family.
9faeb493 6651
fcb21722
JM
66522011-07-22 Jason Merrill <jason@redhat.com>
6653
76f86d00
JM
6654 PR c++/49793
6655 * c.opt (Wnarrowing): New.
6656
3a636414
JM
6657 PR c++/30112
6658 * c-common.h: Declare c_linkage_bindings.
6659 * c-pragma.c (handle_pragma_redefine_extname): Use it.
6660
fcb21722
JM
6661 PR c++/49813
6662 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
6663 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
6664 as flag_isoc99 for 'restrict'.
6665 (pp_c_specifier_qualifier_list): Likewise for _Complex.
6666
02614448
ILT
66672011-07-21 Ian Lance Taylor <iant@google.com>
6668
6669 PR middle-end/49705
6670 * c-common.c (c_disable_warnings): New static function.
6671 (c_enable_warnings): New static function.
6672 (c_fully_fold_internal): Change local unused_p to bool. Call
6673 c_disable_warnings and c_enable_warnings rather than change
6674 c_inhibit_evaluation_warnings.
6675
34429675
JM
66762011-07-20 Jason Merrill <jason@redhat.com>
6677
6678 PR c++/6709 (DR 743)
6679 PR c++/42603 (DR 950)
6680 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
6681 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
6682 (CPP_DECLTYPE): New.
6683 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
6684
5d49b6a7
RG
66852011-07-19 Richard Guenther <rguenther@suse.de>
6686
6687 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
6688 * c-omp.c (c_finish_omp_for): Likewise.
6689
e84a58ff
EB
66902011-07-12 Eric Botcazou <ebotcazou@adacore.com>
6691
6692 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
6693 body on the next line.
6694
329af3c7
JM
66952011-07-08 Jason Merrill <jason@redhat.com>
6696
4063e61b
JM
6697 PR c++/45437
6698 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
6699
329af3c7
JM
6700 PR c++/49673
6701 * c-common.c (c_apply_type_quals_to_decl): Don't check
6702 TYPE_NEEDS_CONSTRUCTING.
6703
1a072294
RG
67042011-07-06 Richard Guenther <rguenther@suse.de>
6705
6706 * c-common.c (c_common_nodes_and_builtins):
6707 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
6708
fce5dddd
RG
67092011-07-05 Richard Guenther <rguenther@suse.de>
6710
6711 * c-common.c (c_common_nodes_and_builtins): Build all common
6712 tree nodes first.
6713
45d439ac
JJ
67142011-06-27 Jakub Jelinek <jakub@redhat.com>
6715
56300785
JJ
6716 * c-common.h (c_tree_chain_next): New static inline function.
6717
45d439ac
JJ
6718 * c-common.c (check_builtin_function_arguments): Handle
6719 BUILT_IN_ASSUME_ALIGNED.
6720
e0a8ecf2
AM
67212011-06-21 Andrew MacLeod <amacleod@redhat.com>
6722
6723 * c-common.c: Add sync_ or SYNC__ to builtin names.
6724 * c-omp.c: Add sync_ or SYNC__ to builtin names.
dfb43cd5
PV
6725
67262011-06-20 Pierre Vittet <piervit@pvittet.com>
6727
6728 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
6729 handler.
6730 (gen_pragma_handler): New union.
6731 (internal_pragma_handler): New type.
6732 (c_register_pragma_with_data)
6733 (c_register_pragma_with_expansion_and_data): New functions.
6734
6735 * c-pragma.c (registered_pragmas, c_register_pragma_1)
6736 (c_register_pragma, c_register_pragma_with_expansion)
6737 (c_invoke_pragma_handler): Changed to work with
6738 internal_pragma_handler.
6739 (c_register_pragma_with_data)
6740 (c_register_pragma_with_expansion_and_data): New functions.
6741
677f3fa8
JM
67422011-06-14 Joseph Myers <joseph@codesourcery.com>
6743
6744 * c-common.c: Include common/common-target.h.
6745 (handle_section_attribute): Use
6746 targetm_common.have_named_sections.
6747 * c-cppbuiltin.c: Include common/common-target.h.
6748 (c_cpp_builtins): Use targetm_common.except_unwind_info.
6749
d7fc8c14
RG
67502011-06-10 Richard Guenther <rguenther@suse.de>
6751
6752 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
6753 to print a IDENTIFIER_NODE.
6754
10e48e39
RO
67552011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6756 Joseph Myers <joseph@codesourcery.com>
6757
6758 * c.opt (fbuilding-libgcc): New option.
6759 * c-cppbuiltin.c (c_cpp_builtins): Define
6760 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
6761
6976ae51
JM
67622011-06-07 Jason Merrill <jason@redhat.com>
6763
3ff60975
JM
6764 * c-common.c (max_tinst_depth): Lower default to 900.
6765
6976ae51
JM
6766 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
6767
009db074
RG
67682011-06-07 Richard Guenther <rguenther@suse.de>
6769
6770 * c-common.c (c_common_nodes_and_builtins): Do not set
6771 size_type_node or call set_sizetype.
6772
b4592b92
DS
67732011-06-07 Dodji Seketeli <dodji@redhat.com>
6774
6775 PR debug/49130
6776 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
9faeb493 6777 type when using pointer comparison to compare types.
b4592b92 6778
014ab419
JW
67792011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
6780
6781 * c.opt: Add -Wdelete-non-virtual-dtor.
6782 * c-opts.c (c_common_handle_option): Include it in -Wall.
6783
4f60111f
NF
67842011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
6785
6786 PR bootstrap/49190
6787
6788 Revert:
6789 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
6790
6791 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
6792 not tree_common.
6793
4cc4f2f4
JJ
67942011-05-27 Jakub Jelinek <jakub@redhat.com>
6795
6796 PR c++/49165
6797 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
6798 C++ don't call c_common_truthvalue_conversion on void type arms.
6799
38e01f9e
NF
68002011-05-27 Nathan Froyd <froydnj@codesourcery.com>
6801
6802 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
6803 (stmt_list_stack): Define.
6804 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
6805 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
6806
92e948a8
NF
68072011-05-26 Nathan Froyd <froydnj@codesourcery.com>
6808
6809 * c-common.c (warning_candidate_p): Check for BLOCKs.
6810
a2fc3e63
NF
68112011-05-26 Nathan Froyd <froydnj@codesourcery.com>
6812
6813 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
6814 not tree_common.
6815
0957c029
JJ
68162011-05-25 Jakub Jelinek <jakub@redhat.com>
6817
6818 * c-common.c (def_fn_type): Remove extra va_end.
6819
828fb3ba
JM
68202011-05-23 Jason Merrill <jason@redhat.com>
6821
6822 PR c++/48106
6823 * c-common.c (c_common_get_narrower): New.
6824 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
6825
dde05067
NF
68262011-05-23 Nathan Froyd <froydnj@codesourcery.com>
6827
6828 * c-common.h (check_function_arguments): Tweak prototype of
6829 check_function_arguments.
6830 * c-common.c (check_function_arguments): Likewise. Adjust
6831 calls to check_function_nonnull, check_function_format, and
6832 check_function_sentinel.
6833 (check_function_sentinel): Take a FUNCTION_TYPE rather than
6834 separate attributes and typelist arguments. Use
6835 FOREACH_FUNCTION_ARGS to iterate over argument types.
6836
3c0d13bf
PC
68372011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
6838
6839 * c-common.c (c_common_reswords): Reorder.
6840 * c-common.h (rid): Likewise.
6841
8242dd04
NF
68422011-05-10 Nathan Froyd <froydnj@codesourcery.com>
6843
6844 * c-common.c (def_fn_type): Don't call build_function_type, call
6845 build_function_type_array or build_varargs_function_type_array
6846 instead.
6847 (c_common_nodes_and_builtins): Likewise.
6848
3d528853
NF
68492011-05-05 Nathan Froyd <froydnj@codesourcery.com>
6850
6851 * c-common.c (c_add_case_label): Omit the loc argument to
6852 build_case_label.
6853 * c-common.h (build_case_label): Remove.
6854 * c-semantics.c (build_case_label): Remove.
6855
a04a722b
JM
68562011-05-05 Joseph Myers <joseph@codesourcery.com>
6857
6858 * c-objc.h (objc_start_method_definition): Update prototype.
6859 * stub-objc.c (objc_start_method_definition): Add extra parameter.
6860
e19a18d4
NF
68612011-05-04 Nathan Froyd <froydnj@codesourcery.com>
6862
6863 * c-common.c (check_main_parameter_types): Reindent. Don't use
6864 TYPE_ARG_TYPES directly.
6865 (handle_nonnull_attribute): Likewise.
6866 (sync_resolve_params): Likewise.
6867 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
6868 to check_format_string.
6869 (handle_format_attribute): Likewise.
6870 (check_format_string): Take a function type to examine instead of
6871 a type list. Use a function_arg_iterator to step through argument
6872 types.
6873
c62c040f
RG
68742011-05-04 Richard Guenther <rguenther@suse.de>
6875
6876 * c-common.c (fix_string_type): Use size_int for index type bounds.
6877 (start_fname_decls): Do not pass NULL to build_int_cst.
6878 (c_init_attributes): Likewise.
6879 * c-lex.c (c_lex_with_flags): Likewise.
6880
c12ff9d8
JM
68812011-04-27 Jason Merrill <jason@redhat.com>
6882
6883 * c-common.c (make_tree_vector_from_list): New.
6884 * c-common.h: Declare it.
6885
304dfbe3
RG
68862011-04-26 Richard Guenther <rguenther@suse.de>
6887
6888 PR preprocessor/48248
6889 * c-ppoutput.c (maybe_print_line): Always optimize newlines
6890 for output size with -P.
6891
3c0d13bf
PC
68922011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
6893
6894 * c-common.c (struct c_common_resword): Add __underlying_type.
6895 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
6896
04695783
JM
68972011-04-20 Jim Meyering <meyering@redhat.com>
6898
6899 * c-format.c (init_dollar_format_checking): Remove useless
6900 if-before-free.
6901
0dc33c3c
NP
69022011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
6903
6904 * c-objc.h (objc_get_interface_ivars): Removed.
3c0d13bf 6905 (objc_detect_field_duplicates): New.
0dc33c3c 6906 * stub-objc.c: Likewise.
3c0d13bf 6907
c59633d9
NP
69082011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
6909
6910 * stub-objc.c (objc_declare_protocols): Renamed to
6911 objc_declare_protocol.
6912 * c-objc.h: Likewise.
3c0d13bf 6913
32dabdaf
NP
69142011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
6915
6916 * stub-objc.c (objc_declare_class): Updated argument name.
6917
81f653d6
NF
69182011-04-12 Nathan Froyd <froydnj@codesourcery.com>
6919
6920 * c-common.h (c_common_init_ts): Declare.
6921 * c-common.c (c_common_init_ts): Define.
6922
eb345401
NP
69232011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
6924
6925 * c-objc.h (objc_build_message_expr): Updated prototype.
6926 * stub-objc.c (objc_build_message_expr): Likewise.
9faeb493 6927
a358e188
MJ
69282011-04-12 Martin Jambor <mjambor@suse.cz>
6929
6930 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
6931 of cgraph_node.
6932
e6313a78
RG
69332011-04-11 Richard Guenther <rguenther@suse.de>
6934
6935 * c-common.c (complete_array_type): Build a range type of
6936 proper type.
6937
dcf0c47e
NF
69382011-04-08 Nathan Froyd <froydnj@codesourcery.com>
6939
6940 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
6941 (handle_type_generic_attribute): Likewise.
6942
1ee44b26
JM
69432011-04-07 Jason Merrill <jason@redhat.com>
6944
6945 PR c++/48450
6946 * c-common.c (c_common_truthvalue_conversion): Don't ignore
6947 conversion from C++0x scoped enum.
6948
acce4e77
JM
69492011-04-06 Joseph Myers <joseph@codesourcery.com>
6950
6951 * c-target-def.h: New file.
6952 * c-target.def: New file.
6953 * c-target.h: New file.
6954 * c-common.c (targetcm): Don't define here.
6955 * c-common.h (default_handle_c_option): Declare.
6956 * c-format.c: Include c-target.h instead of target.h.
6957 * c-opts.c: Include c-target.h instead of target.h. Explicitly
6958 include tm.h.
6959 (default_handle_c_option): Move from targhooks.c.
6960
e2eefb55
JJ
69612011-03-29 Jakub Jelinek <jakub@redhat.com>
6962
6963 PR preprocessor/48248
6964 * c-ppoutput.c (print): Add src_file field.
6965 (init_pp_output): Initialize it.
6966 (maybe_print_line): Don't optimize by adding up to 8 newlines
6967 if map->to_file and print.src_file are different file.
6968 (print_line): Update print.src_file.
6969
ba78087b
KT
69702011-03-25 Kai Tietz <ktietz@redhat.com>
6971
6972 * c-ada-spec.c (compare_comment): Use filename_cmp
6973 instead of strcmp for filename.
6974
0edf1bb2
JL
69752011-03-25 Jeff Law <law@redhat.com>
6976
adfac8df 6977 * c-common.c (def_fn_type): Add missing va_end.
0edf1bb2 6978
c7dc8804
JM
69792011-03-25 Jason Merrill <jason@redhat.com>
6980
6981 * c.opt: Add -std=c++03.
6982
d1d879b1
EB
69832011-03-22 Eric Botcazou <ebotcazou@adacore.com>
6984
6985 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
6986
3f8257db 69872011-03-17 Kai Tietz <ktietz@redhat.com>
62d784f7
KT
6988
6989 PR target/12171
5050afdf
KT
6990 * c-pretty-print.c (pp_c_specifier_qualifier_list):
6991 Display allowed attributes for function pointer types.
6992 (pp_c_attributes_display): New function to display
6993 attributes having affects_type_identity flag set to true.
6994 * c-pretty-print.h (pp_c_attributes_display): New prototype.
6995
62d784f7
KT
6996 * c-common.c (c_common_attribute_table):
6997 Add new element.
6998 (c_common_format_attribute_table): Likewise.
6999
82d37118
JM
70002011-03-18 Jason Merrill <jason@redhat.com>
7001
49a000c3
JM
7002 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
7003 * c-common.h: Don't declare it here.
7004 * c-common.c: Or define it here.
7005 * c-opts.c (c_common_handle_option): Or set it here.
7006
82d37118
JM
7007 PR c++/35315
7008 * c-common.c (handle_transparent_union_attribute): Don't
7009 make a duplicate type in C++.
7010
17bc631c
JM
70112011-03-15 Jason Merrill <jason@redhat.com>
7012
7013 * c-common.c (max_constexpr_depth): New.
7014 * c-common.h: Declare it.
7015 * c-opts.c (c_common_handle_option): Set it.
7016 * c.opt (fconstexpr-depth): New option.
7017
1b9b91a6
JM
70182011-03-11 Jason Merrill <jason@redhat.com>
7019
f231b5ff
JM
7020 * c-common.c (attribute_takes_identifier_p): Add missing const.
7021
1b9b91a6
JM
7022 PR c++/46803
7023 * c-common.c (attribute_takes_identifier_p): Assume that an
7024 unknown attribute takes an identifier.
7025
a19e4d44
NF
70262011-03-07 Nathan Froyd <froydnj@codesourcery.com>
7027
7028 PR c/47786
7029 * c-common.c (c_type_hash): Call list_length instead of iterating
7030 through DECL_CHAIN. Rename 'i' to 'n_elements'.
7031
982d62f6
JJ
70322011-02-19 Jakub Jelinek <jakub@redhat.com>
7033
7034 PR c/47809
7035 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
7036
0a256240
NP
70372011-02-17 Iain Sandoe <iains@gcc.gnu.org>
7038
7039 * c.opt (fobjc-abi-version=) New.
7040 (fobjc-nilcheck): New.
7041
ba9e6dd5
NF
70422011-02-03 Nathan Froyd <froydnj@codesourcery.com>
7043
7044 PR c++/46890
7045 * c-common.h (keyword_is_decl_specifier): Declare.
7046 * c-common.c (keyword_is_decl_specifier): Define.
7047 (keyword_is_function_specifier): New function.
7048
7273813a
JJ
70492011-01-26 Jakub Jelinek <jakub@redhat.com>
7050
7051 PR c/47473
7052 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
7053 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
7054 REAL_TYPE.
7055
908ef79b
AC
70562011-01-26 Arnaud Charlet <charlet@adacore.com>
7057
7058 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
7059
237e9384
JJ
70602011-01-26 Jakub Jelinek <jakub@redhat.com>
7061
7062 PR pch/47430
7063 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
7064 after init_c_lex if pch_file is set.
7065
47ea1edf
DK
70662011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
7067
d4dba752 7068 PR c++/43601
47ea1edf
DK
7069 * c.opt (-fkeep-inline-dllexport): New switch.
7070
2aa9c6ae
RG
70712011-01-12 Richard Guenther <rguenther@suse.de>
7072
7073 PR middle-end/32511
7074 * c-common.c (handle_weak_attribute): Warn instead of error
7075 on declaring an inline function weak.
7076
7bd11157
TT
70772011-01-05 Tom Tromey <tromey@redhat.com>
7078
7079 * c-common.h (lvalue_error): Update.
7080 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
7081 not error.
7082
0e66e494 70832010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
9faeb493 7084
b4f588c4
NP
7085 PR objc/47075
7086 * c-objc.h (objc_finish_message_expr): Added argument to
7087 prototype.
7088
f4da8dce
NF
70892010-12-22 Nathan Froyd <froydnj@codesourcery.com>
7090
7091 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
7092 Use prototype_p.
7093
46270f14
NP
70942010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
7095
7096 * c-objc.h (objc_maybe_warn_exceptions): New.
9faeb493 7097 * stub-objc.c (objc_maybe_warn_exceptions): New.
46270f14 7098
4816c593
NF
70992010-12-10 Nathan Froyd <froydnj@codesourcery.com>
7100
7101 * c-common.h (readonly_error): Declare.
7102 * c-common.c (readonly_error): Define.
7103
7a6daeb0
NF
71042010-12-09 Nathan Froyd <froydnj@codesourcery.com>
7105
7106 * c-common.h (invalid_indirection_error): Declare.
7107 * c-common.c (invalid_indirection_error): Define.
7108
892f6119
RG
71092010-12-03 Richard Guenther <rguenther@suse.de>
7110
7111 PR c/46745
7112 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
7113 (pp_c_unary_expression): Likewise.
7114 (pp_c_expression): Likewise.
7115
6c39e757
NP
71162010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
7117
7118 * c-common.h (objc_finish_function): New.
7119 (objc_non_volatilized_type): Removed.
7120 (objc_type_quals_match): Removed.
7121 * stub-objc.c (objc_finish_function): New.
7122 (objc_non_volatilized_type): Removed.
7123 (objc_type_quals_match): Removed.
9faeb493 7124
7c475d11
JM
71252010-11-30 Joseph Myers <joseph@codesourcery.com>
7126
7127 * c-common.h (parse_optimize_options): Declare.
7128 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
7129 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
7130
71f3e391
JM
71312010-11-29 Joseph Myers <joseph@codesourcery.com>
7132
7133 * c-opts.c (check_deps_environment_vars): Use getenv instead of
7134 GET_ENVIRONMENT.
7135 * c-pch.c (O_BINARY): Don't define here.
7136 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
7137
d5fabb58
JM
71382010-11-25 Joseph Myers <joseph@codesourcery.com>
7139
7140 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
7141 targetm.except_unwind_info.
7142
299404a1
JM
71432010-11-23 Joseph Myers <joseph@codesourcery.com>
7144
7145 * c-opts.c (c_common_handle_option): Pass location to
7146 set_struct_debug_option.
7147
c98cd5bf
JM
71482010-11-23 Joseph Myers <joseph@codesourcery.com>
7149
7150 * c-common.c (visibility_options): Move from ../opts.c.
7151 * c-common.h (struct visibility_flags, visibility_options):
7152 Declare here.
7153 * c-opts.c (finish_options): Rename to c_finish_options.
7154 (c_common_init): Update call to finish_options.
7155
a9546771
NP
71562010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
7157
7158 PR objc/34033
7159 * c-lex.c (lex_string): Check that each string in an Objective-C
7160 string concat sequence starts with either one or zero '@', and
7161 that there are no spurious '@' signs at the end.
7162
24a57808
JM
71632010-11-20 Joseph Myers <joseph@codesourcery.com>
7164
7165 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
7166 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
7167 HANDLE_PRAGMA_VISIBILITY.
7168 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
7169 HANDLE_PRAGMA_VISIBILITY): Don't define.
7170 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
7171
a9aa2c3a
NF
71722010-11-20 Nathan Froyd <froydnj@codesourcery.com>
7173
7174 PR c++/16189
7175 PR c++/36888
7176 PR c++/45331
7177 * c-common.h (keyword_begins_type_specifier): Declare.
7178 (keyword_is_storage_class_specifier): Declare.
7179 (keyword_is_type_qualifier): Declare.
7180 * c-common.c (keyword_begins_type_specifier): New function.
7181 (keyword_is_storage_class_specifier): New function.
7182 (keyword_is_type_qualifier): Declare.
7183
5386338c
JM
71842010-11-19 Joseph Myers <joseph@codesourcery.com>
7185
7186 PR c/46547
7187 * c-common.c (in_late_binary_op): Define.
7188 (c_common_truthvalue_conversion): Check in_late_binary_op before
7189 calling c_save_expr.
7190 * c-common.h (in_late_binary_op): Declare.
7191
69ccdddb
JM
71922010-11-19 Joseph Myers <joseph@codesourcery.com>
7193
7194 * c-opts.c (c_common_handle_option): Update calls to
7195 set_struct_debug_option.
7196
6b192a09
NP
71972010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
7198
7199 * c-common.h (objc_declare_protocols): Added additional argument.
7200 * stub-objc.c (objc_declare_protocol): Same change.
9faeb493 7201
fb52b50a
NF
72022010-11-18 Nathan Froyd <froydnj@codesourcery.com>
7203
7204 PR c/33193
7205 * c-common.h (build_real_imag_expr): Declare.
7206 * c-semantics.c (build_real_imag_expr): Define.
7207
b37421c6
JM
72082010-11-17 Joseph Myers <joseph@codesourcery.com>
7209
7210 * c-opts.c (c_common_parse_file): Take no arguments.
7211 * c-common.h (c_common_parse_file): Update prototype.
7212
07078664
JJ
72132010-11-16 Jakub Jelinek <jakub@redhat.com>
7214
7215 PR c++/46401
7216 * c-common.c (warning_candidate_p): Don't track non-const calls
7217 or STRING_CSTs.
7218
c6a13190
ILT
72192010-11-15 Ian Lance Taylor <iant@google.com>
7220
7221 * c-lex.c (init_c_lex): Set macro debug callbacks if
7222 flag_dump_go_spec is set.
7223
925e8657
NP
72242010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
7225
7226 * c-common.h (objc_build_incr_expr_for_property_ref): New.
7227 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
7228
bb0a9581
NF
72292010-11-15 Nathan Froyd <froydnj@codesourcery.com>
7230
7231 PR preprocessor/45038
7232 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
7233 dialects.
7234
c5fa0890
JM
72352010-11-12 Joseph Myers <joseph@codesourcery.com>
7236
7237 * c-common.h (c_family_lang_mask): Declare.
7238 * c-opts.c (c_family_lang_mask): Make extern.
7239 * c-pragma.c (handle_pragma_diagnostic): Use
7240 control_warning_option.
7241
a4d8c676
JM
72422010-11-12 Joseph Myers <joseph@codesourcery.com>
7243
7244 * c-common.c (parse_optimize_options): Update call to
7245 decode_options.
7246 * c-common.h (c_common_handle_option): Update prototype.
7247 * c-opts.c (c_common_handle_option): Take location_t parameter and
7248 pass it to other functions.
7249
f954bd2c
JM
72502010-11-11 Joseph Myers <joseph@codesourcery.com>
7251
7252 * c-opts.c (warning_as_error_callback): Remove.
7253 (c_common_initialize_diagnostics): Don't call
7254 register_warning_as_error_callback.
7255 (c_common_handle_option): Handle -Werror=normalized= here.
7256
d8a07487
JM
72572010-11-10 Joseph Myers <joseph@codesourcery.com>
7258
7259 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
7260 in diagnostic.
7261 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
7262 letter.
7263 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
7264 Remove trailing '.' from diagnostics.
7265 * c.opt (Wwrite-strings_: Avoid '`' in help text.
7266
d5478783
JM
72672010-11-10 Joseph Myers <joseph@codesourcery.com>
7268
7269 * c-common.c (parse_optimize_options): Pass global_dc to
7270 decode_options.
7271 * c-opts.c (c_common_handle_option): Pass &global_options to
7272 set_Wstrict_aliasing.
7273 * c.opt (v): Don't mark Common or document here.
7274
91ebb981
IS
72752010-11-06 Iain Sandoe <iains@gcc.gnu.org>
7276
7277 PR target/44981
7278 * c-format.c (format_type): New type gcc_objc_string_format_type.
7279 (valid_stringptr_type_p): New.
7280 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
9faeb493 7281 (check_format_string): Pass expected type, use
91ebb981
IS
7282 valid_stringptr_type_p (), check that the format string types are
7283 consistent with the format specification.
7284 (decode_format_attr): Warn if NSString is used outside objective-c.
7285 (format_types_orig): Add NSString.
7286 (format_name): New.
7287 (format_flags): New.
7288 (check_format_arg): Handle format strings requiring an external parser.
7289 first_target_format_type: New variable.
7290 (handle_format_attribute): Set up first_target_format_type, pass the
7291 expected format arg string type to check_format_string().
7292 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
7293 * stub-objc.c (objc_string_ref_type_p): New.
7294 (objc_check_format_arg): New.
7295
bede2adc
NP
72962010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
7297
9faeb493 7298 Fixed using the Objective-C 2.0 dot-syntax with class names.
bede2adc
NP
7299 * c-common.h (objc_build_class_component_ref): New.
7300 * stub-objc.c (objc_build_class_component_ref): New.
7301
9a179d01
NP
73022010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
7303
7304 * c.opt (Wproperty-assign-default): New option.
7305
22d8d616
NP
73062010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
7307
7308 Implemented -fobjc-std=objc1 flag.
7309 * c.opt (fobjc-std=objc1): New option.
7310
2debdb4f
NP
73112010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
7312
7313 Implemented format and noreturn attributes for Objective-C methods.
7314 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
7315 attribute for Objective-C methods.
7316
ec52b111
JM
73172010-10-31 Jason Merrill <jason@redhat.com>
7318
7319 * c-common.c (conversion_warning, warn_for_collisions_1): Use
7320 EXPR_LOC_OR_HERE.
7321
46a88c12
NP
73222010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
7323
7324 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
7325 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
7326 (objc_add_property_declaration): Removed arguments for copies and
7327 ivar.
7328 (objc_build_getter_call): Renamed to
7329 objc_maybe_build_component_ref.
7330 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
7331 (objc_is_property_ref): New.
7332 * c-common.c (c_common_reswords): Removed copies and ivar.
7333 * stub-objc.c (objc_add_property_declaration): Removed arguments
7334 for copies and ivar.
7335 (objc_build_getter_call): Renamed to
7336 objc_maybe_build_component_ref.
7337 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
7338 (objc_is_property_ref): New.
9faeb493 7339
1e4bf85b
AC
73402010-10-29 Arnaud Charlet <charlet@adacore.com>
7341 Matthew Gingell <gingell@adacore.com>
7342
7343 * c-ada-spec.c (separate_class_package): New function.
7344 (pp_ada_tree_identifier): Prefix references to C++ classes with the
7345 name of their enclosing package.
7346 (print_ada_declaration): Use separate_class_package.
7347
81f0bab2
JM
73482010-10-27 Jason Merrill <jason@redhat.com>
7349
2b08f2c5
JM
7350 * c-common.c (c_common_reswords): Add __is_literal_type.
7351 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
7352
81f0bab2
JM
7353 * c-common.c (check_case_value): Remove special C++ code.
7354
200290f2
NP
73552010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
7356
7357 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
7358 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
7359 and RID_LAST_PATTR.
7360 (objc_add_property_declaration): Added additional arguments.
7361 (objc_property_attribute_kind): Removed.
7362 (objc_set_property_attr): Removed.
7363 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
7364 copy and nonatomic.
7365 * stub-objc.c (objc_add_property_declaration): Added additional
7366 arguments.
7367 (objc_set_property_attr): Removed.
9faeb493 7368
f614132b
NP
73692010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
7370
7371 * c-common.h (objc_add_property_variable): Renamed to
7372 objc_add_property_declaration. Added location argument.
7373 * stub-objc.c (objc_add_property_variable): Same change.
b1726d6c 7374
b8a18805
NP
73752010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
7376
7377 * c-common.h (objc_maybe_printable_name): New.
7378 * stub-objc.c (objc_maybe_printable_name): New.
7379
3f8257db
JJ
73802010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
7381 Andrew Pinski <pinskia@gmail.com>
30cd1c5d
AS
7382
7383 * c-common.h (c_common_mark_addressable_vec): Declare.
7384 * c-common.c (c_common_mark_addressable_vec): New function.
7385
249a82c4
NP
73862010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
7387
7388 * c-common.h (objc_set_method_type): Removed.
7389 (objc_add_method_declaration): Added boolean argument.
7390 (objc_start_method_definition): Same change.
7391 (objc_build_method_signature): Same change.
7392 * stub-objc.c (objc_set_method_type): Removed.
7393 (objc_add_method_declaration): Added boolean argument.
7394 (objc_start_method_definition): Same change.
7395 (objc_build_method_signature): Same change.
7396
977e30bc
NP
73972010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
7398
7399 * c-common.h (finish_file): Removed.
7400 (objc_write_global_declarations): New.
7401 * c-opts.c (c_common_parse_file): Do not call finish_file.
7402 * stub-objc.c (objc_write_global_declarations): New.
9faeb493 7403
da57d1b9
NP
74042010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
7405
7406 Implemented parsing @synthesize and @dynamic for
7407 Objective-C/Objective-C++.
7408 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
7409 (objc_add_synthesize_declaration): New.
7410 (objc_add_dynamic_declaration): New.
7411 * c-common.c (c_common_reswords): Add synthesize and dynamic.
7412 * stub-objc.c (objc_add_synthesize_declaration): New.
7413 (objc_add_dynamic_declaration): New.
9faeb493 7414
0069111f
MM
74152010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
7416
7417 PR target/46041
7418 * c-cppbuiltin.c (mode_has_fma): Move function here from
7419 builtins.c. Don't use the fma optab, instead just use the
7420 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
7421 using -save-temps.
7422
e426b47b
NP
74232010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
7424
7425 Merge from 'apple/trunk' branch on FSF servers.
0069111f 7426
3f8257db 7427 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
e426b47b 7428
9faeb493 7429 Radar 4330422
e426b47b
NP
7430 * c-common.h (objc_non_volatilized_type): New declaration
7431 * stub-objc.c (objc_non_volatilized_type): New stub.
7432
90fbfdc3
NP
74332010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
7434
e426b47b 7435 Merge from 'apple/trunk' branch on FSF servers.
90fbfdc3 7436
3f8257db 7437 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
90fbfdc3 7438
9faeb493 7439 Radar 4133425
90fbfdc3 7440 * c-common.h (objc_diagnose_private_ivar): New decl.
0069111f 7441 * stub-objc.c (objc_diagnose_private_ivar): New stub.
90fbfdc3 7442
c37d8c30
IS
74432010-10-17 Iain Sandoe <iains@gcc.gnu.org>
7444
7445 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
7446 * c-common.h (enum rid): Add RID_AT_PACKAGE.
7447 (objc_ivar_visibility_kind): New enum.
7448 (objc_set_visibility): Adjust prototype to use visibility enum.
0069111f 7449 * stub-objc.c (objc_set_visibility): Adjust stub to use
c37d8c30
IS
7450 visibility enum.
7451
1b1562a5
MM
74522010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
7453
7454 * c-cppbuiltin.c (builtin_define_float_constants): Emit
7455 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
7456 has the appropriate fma builtins.
7457 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
7458
668ea4b1
IS
74592010-10-14 Iain Sandoe <iains@gcc.gnu.org>
7460
1b1562a5 7461 merge from FSF apple 'trunk' branch.
3f8257db 7462 2006 Fariborz Jahanian <fjahanian@apple.com>
1b1562a5 7463
668ea4b1
IS
7464 Radars 4436866, 4505126, 4506903, 4517826
7465 * c-common.c (c_common_resword): Define @property and its attributes.
7466 * c-common.h: Define property attribute enum entries.
7467 (OBJC_IS_PATTR_KEYWORD): New.
7468 (objc_property_attribute_kind): New enum.
7469 Declare objc_set_property_attr (), objc_add_property_variable (),
7470 objc_build_getter_call () and objc_build_setter_call ().
7471 * stub-objc.c (objc_set_property_attr): New stub.
7472 (objc_add_property_variable): Likewise.
7473 (objc_build_getter_call): Likewise.
7474 (objc_build_setter_call) Likewise.
1b1562a5 7475
a1178b30
IS
74762010-10-13 Iain Sandoe <iains@gcc.gnu.org>
7477
1b1562a5 7478 merge from FSF apple 'trunk' branch.
3f8257db 7479 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
a1178b30
IS
7480
7481 Radar 3803157 (method attributes)
7482 * c-common.c (handle_deprecated_attribute): Recognize
7483 objc methods as valid declarations.
7484 * c-common.h: Declare objc_method_decl ().
1b1562a5 7485 * stub-objc.c (objc_method_decl): New stub.
a1178b30 7486
a75bfaa6
JM
74872010-10-08 Joseph Myers <joseph@codesourcery.com>
7488
7489 * c-common.c (parse_optimize_options): Call
7490 decode_cmdline_options_to_array_default_mask before
7491 decode_options. Update arguments to decode_options.
7492 * c-common.h (c_common_init_options_struct): Declare.
7493 * c-opts.c (c_common_init_options_struct): New. Split out from
7494 c_common_init_options.
7495
f05b9d93
NP
74962010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
7497
7498 Implemented fast enumeration for Objective-C.
7499 * c-common.h (objc_finish_foreach_loop): New.
7500 * stub-objc.c (objc_finish_foreach_loop): New.
7501
1ebe4b4f
JM
75022010-10-05 Joseph Myers <joseph@codesourcery.com>
7503
7504 * c-common.h (struct diagnostic_context): Don't declare here.
7505 (c_common_initialize_diagnostics): Declare using
7506 diagnostic_context typedef.
7507 * c-opts.c (c_common_handle_option): Pass global_dc to
7508 handle_generated_option.
7509
d4d24ba4
JM
75102010-10-04 Joseph Myers <joseph@codesourcery.com>
7511
7512 * c-opts.c (c_common_handle_option): Pass &global_options_set to
7513 handle_generated_option.
7514
478a1c5b
ILT
75152010-10-03 Ian Lance Taylor <iant@google.com>
7516
7517 * c.opt (-fplan9-extensions): New option.
7518
82a1c2fe
FXC
75192010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
7520
7521 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
7522 Remove.
7523 (c_cpp_builtins): Call functions from cppbuiltin.c instead
7524 of duplicating code.
7525
92902b1b
IS
75262010-09-30 Iain Sandoe <iains@gcc.gnu.org>
7527
7528 * c-common.c: Add two new entries for @optional
7529 and @required keywords.
7530
7531 merge from FSF 'apple/trunk' branch.
3f8257db 7532 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
92902b1b
IS
7533
7534 Radar 4386773
7535 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
7536 objective-c keywords.
7537 (objc_set_method_opt): New declaration.
7538 * stub-objc.c (objc_set_method_opt): New stub.
9faeb493 7539
46625112
JM
75402010-09-30 Joseph Myers <joseph@codesourcery.com>
7541
7542 * c-common.c (handle_optimize_attribute): Pass &global_options to
7543 cl_optimization_save and cl_optimization_restore.
7544 * c-opts.c (c_common_handle_option): Pass &global_options to
7545 handle_generated_option.
7546 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
7547 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
7548 &global_options to cl_optimization_restore.
7549
49b91f05
NP
75502010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
7551
7552 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
7553 Objective-C/Objective-C++ keywords.
7554
13ed556f 75552010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
a6341d57 7556
9faeb493
UB
7557 Merge from 'apple/trunk' branch on FSF servers.
7558
3f8257db 7559 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
a6341d57
NP
7560
7561 Radar 4281748
7562 * c-common.h (objc_check_global_decl): New declaration.
7563 * stub-objc.c (objc_check_global_decl): New stub.
7564
f0036cca
JM
75652010-09-29 Joseph Myers <joseph@codesourcery.com>
7566
7567 * c.opt: Don't use VarExists.
7568
e3339d0f
JM
75692010-09-29 Joseph Myers <joseph@codesourcery.com>
7570
7571 * c-common.c (c_cpp_error): Update names of diagnostic_context
7572 members.
7573 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
7574 cl_optimization members.
7575 * c-opts.c (warning_as_error_callback, c_common_handle_option,
7576 sanitize_cpp_opts, finish_options): Update names of cpp_options
7577 members.
7578
1973201f
NP
75792010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
7580
7581 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
7582 (objc_is_reserved_word): Removed.
7583 * c-common.c: Updated comments.
7584 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
7585 objc_is_reserved_word.
7586 * stub-objc.c (objc_is_reserved_word): Removed.
7587
f7e71da5
IS
75882010-09-28 Iain Sandoe <iains@gcc.gnu.org>
7589
9faeb493 7590 * c-common.h (objc_add_method_declaration): Adjust prototype to
f7e71da5
IS
7591 include attributes.
7592 (objc_start_method_definition): Likewise.
7593 (objc_build_keyword_decl): Likewise.
7594 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
7595 (objc_start_method_definition): Likewise.
7596 (objc_build_keyword_decl): Likewise.
7597
c165dca7
IS
75982010-09-28 Iain Sandoe <iains@gcc.gnu.org>
7599
7600 * c-common.h (objc_start_class_interface): Adjust prototype.
7601 (objc_start_category_interface): Likewise.
7602 (objc_start_protocol): Likewise.
7603 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
7604 (objc_start_class_interface): Likewise.
7605 (objc_start_category_interface): Likewise.
7606
7458026b
ILT
76072010-09-27 Ian Lance Taylor <iant@google.com>
7608
7609 * c-common.c (c_common_attribute_table): Add no_split_stack.
7610 (handle_no_split_stack_attribute): New static function.
7611
b581b85b
NP
76122010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
7613
9faeb493 7614 Merge from 'apple/trunk' branch on FSF servers.
b581b85b 7615
3f8257db 7616 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
b581b85b 7617
9faeb493 7618 Radar 4229905
b581b85b
NP
7619 * c-common.h (objc_have_common_type): New declaration.
7620 * stub-objc.c (objc_have_common_type): New stub.
7621
7622 2005-06-22 Ziemowit Laski <zlaski@apple.com>
7623
7624 Radar 4154928
7625 * c-common.h (objc_common_type): New prototype.
9faeb493 7626 * stub-objc.c (objc_common_type): New stub.
b581b85b 7627
46a4da10
JH
76282010-09-24 Jan Hubicka <jh@suse.cz>
7629
7630 * c-common.c (handle_leaf_attribute): New function.
7631 (struct attribute_spec c_common_att): Add leaf.
7632
e200444e
JM
76332010-09-22 Joseph Myers <joseph@codesourcery.com>
7634
7635 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
7636 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
7637 -dump, -dump=, -imacros, -imacros=, -include, -include=,
7638 -include-barrier, -include-directory, -include-directory=,
7639 -include-directory-after, -include-directory-after=,
7640 -include-prefix, -include-prefix=, -include-with-prefix,
7641 -include-with-prefix=, -include-with-prefix-after,
7642 -include-with-prefix-after=, -include-with-prefix-before,
7643 -include-with-prefix-before=, -no-integrated-cpp,
7644 -no-line-commands, -no-standard-includes, -no-warnings, -output,
7645 -output=, -pedantic, -pedantic-errors, -preprocess,
7646 -print-missing-file-dependencies, -trace-includes, -traditional,
7647 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
7648 -user-dependencies, -verbose, -write-dependencies,
7649 -write-user-dependencies, no-integrated-cpp, traditional): New.
7650
29a80ea6
NP
76512010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
7652
7653 PR objc/23710
ac1fc2fc
NP
7654 * c-common.h (objc_start_method_definition): Return bool instead
7655 of void.
7656 * stub-objc.c (objc_start_method_definition): Return bool instead
7657 of void.
7658
76592010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
7660
7661 PR objc/25965
7662 * c-common.h (objc_get_interface_ivars): New declaration.
7663 * stub-objc.c (objc_get_interface_ivars): New stub.
29a80ea6 7664
de621752
ILT
76652010-09-15 Ian Lance Taylor <iant@google.com>
7666
7667 * c-common.c (parse_optimize_options): Do not capitalize warning
06730c5d 7668 messages. Remove period at end of warning message.
de621752 7669
ba885ec5
NS
76702010-09-09 Nathan Sidwell <nathan@codesourcery.com>
7671
7672 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
7673 (handle_alias_attribute): ... here.
7674 (handle_ifunc_attribute): New.
7675
c5ee1358
MM
76762010-09-06 Mark Mitchell <mark@codesourcery.com>
7677
7678 * c-common.h (do_warn_double_promotion): Declare.
7679 * c-common.c (do_warn_double_promotion): Define.
7680
0a0b3574
MM
76812010-09-05 Mark Mitchell <mark@codesourcery.com>
7682
7683 * c.opt (Wdouble-promotion): New.
7684
d1779886
JM
76852010-09-02 Joseph Myers <joseph@codesourcery.com>
7686
7687 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
7688 fvtable-thunks, fxref): Mark no longer supported in help text.
7689
2d2bd949
JM
76902010-09-02 Joseph Myers <joseph@codesourcery.com>
7691
7692 * c.opt (Wimport, fall-virtual, falt-external-templates,
7693 fdefault-inline, fenum-int-equiv, fexternal-templates,
7694 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
7695 fname-mangling-version-, fnew-abi, fnonnull-objects,
7696 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
7697 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
7698 applicable.
7699 (fhandle-exceptions): Mark with Alias and Warn.
7700 * c-opts.c (c_common_handle_option): Don't handle options marked
7701 as ignored.
7702
5de8299c
JM
77032010-09-02 Joseph Myers <joseph@codesourcery.com>
7704
7705 * c.opt (Wcomments, Werror-implicit-function-declaration,
7706 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
7707 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
7708 aliases.
7709 * c-common.c (option_codes): Use OPT_Wcomment instead of
7710 OPT_Wcomments.
7711 * c-opts.c (warning_as_error_callback, c_common_handle_option):
7712 Don't handle options marked as aliases.
7713
0ceb0201
RG
77142010-08-25 Richard Guenther <rguenther@suse.de>
7715
7716 * c-common.c (c_common_get_alias_set): Remove special
7717 handling for pointers.
7718
ac47786e
NF
77192010-08-20 Nathan Froyd <froydnj@codesourcery.com>
7720
7721 * c-common.c: Use FOR_EACH_VEC_ELT.
7722 * c-gimplify.c: Likewise.
7723 * c-pragma.c: Likewise.
7724
c878765b
JM
77252010-08-16 Joseph Myers <joseph@codesourcery.com>
7726
7727 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
7728 RejectDriver.
7729 (MMDX): Change back to MMD. Mark NoDriverArg instead of
7730 RejectDriver.
7731 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
7732 instead of OPT_MDX and OPT_MMDX.
7733
603349bf
JM
77342010-08-16 Joseph Myers <joseph@codesourcery.com>
7735
7736 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
7737
644fa7ac
JM
77382010-08-12 Joseph Myers <joseph@codesourcery.com>
7739
7740 * c.opt (MD, MMD): Change to MDX and MMDX.
7741 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
7742
481e1176
JM
77432010-08-11 Joseph Myers <joseph@codesourcery.com>
7744
7745 * c-opts.c (c_common_handle_option): Call handle_generated_option
7746 instead of handle_option.
7747
ac8dc9f7
NF
77482010-08-08 Nathan Froyd <froydnj@codesourcery.com>
7749
7750 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
7751 (maybe_apply_renaming_pragma): Delete unneeded declarations.
7752
4f8c876d
NF
77532010-08-08 Nathan Froyd <froydnj@codesourcery.com>
7754
7755 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
7756 (pending_redefine_extname): Change type to a VEC.
7757 (add_to_renaming_pragma_list): Update for new type of
7758 pending_redefine_extname.
ac8dc9f7 7759 (maybe_apply_renaming_pragma): Likewise.
4f8c876d 7760
3b0c690e
AC
77612010-08-04 Arnaud Charlet <charlet@adacore.com>
7762
7763 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
7764 visited.
7765 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
7766 decide whether a type has already been declared/seen.
7767 Do not go to the original type.
7768 (dump_nested_types): New parameter forward.
7769 Generate forward declaration if needed and mark type as visited.
7770 (print_ada_declaration): Call dump_nested_types if not already done.
7771 Mark types as visited.
7772
1890bccc
JM
77732010-08-03 Joseph Myers <joseph@codesourcery.com>
7774
7775 * c.opt (-print-pch-checksum): Remove option.
7776 * c-opts.c (c_common_handle_option): Don't handle
7777 OPT_print_pch_checksum.
7778
5f20c657
JM
77792010-07-27 Joseph Myers <joseph@codesourcery.com>
7780
7781 * c-common.h (c_common_handle_option): Update prototype and return
7782 value type.
7783 * c-opts.c (c_common_handle_option): Update prototype and return
7784 value type. Update calls to handle_option and
7785 enable_warning_as_error.
7786
f551f80c
JJ
77872010-07-27 Jakub Jelinek <jakub@redhat.com>
7788
7789 PR c/45079
7790 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
7791
61ff2bdc
JM
77922010-07-27 Joseph Myers <joseph@codesourcery.com>
7793
7794 * c-common.h (c_common_missing_argument): Remove.
7795 * c-opts.c (c_common_missing_argument): Remove.
7796 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
7797 idirafter, imacros, include, isysroot, isystem, iquote): Add
7798 MissingArgError.
7799 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
7800
7a9bf9a4
JM
78012010-07-27 Joseph Myers <joseph@codesourcery.com>
7802
7803 * c-common.h (c_common_option_lang_mask,
7804 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
7805 New.
7806 (c_common_init_options): Update prototype.
7807 * c-opts.c (c_common_option_lang_mask): New.
7808 (c_common_initialize_diagnostics): Split out of
7809 c_common_init_options.
7810 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
7811 New.
7812 (c_common_init_options): Update prototype. Use decoded options in
7813 search for -lang-asm.
7814
910ad8de
NF
78152010-07-15 Nathan Froyd <froydnj@codesourcery.com>
7816
7817 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
7818 * c-format.c: Likewise.
7819
718f9c0f
MLI
78202010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
7821
7822 * c-common.h: Include diagnostic-core.h. Error if already
7823 included.
7824 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
7825
4d451982
MLI
78262010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
7827
adfac8df 7828 * c-common.c (IN_GCC_FRONTEND): Do not undef.
4d451982
MLI
7829 Do not include expr.h
7830 (vector_mode_valid_p): Move here.
7831
119fe915
SB
78322010-06-21 DJ Delorie <dj@redhat.com>
7833
7834 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
7835 allow these pragmas anywhere.
7836
78372010-06-14 Jakub Jelinek <jakub@redhat.com>
7838
7839 PR bootstrap/44509
7840 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
7841 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
7842 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
7843 ggc_strdup instead of xstrdup.
7844
78452010-06-10 Jakub Jelinek <jakub@redhat.com>
7846
7847 * c-cppbuiltin.c: Include cpp-id-data.h.
7848 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
7849 (lazy_hex_fp_value): New function.
7850 (builtin_define_with_hex_fp_value): Provide definitions lazily.
7851
6662d794
MLI
78522010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
7853
7854 * c-gimplify.c: Do not include tree-flow.h
7855
38f8b050
JR
78562010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
7857
7858 PR other/44034
7859 * c-common.c: Rename targetm member:
7860 targetm.enum_va_list -> targetm.enum_va_list_p
7861
9589f23e
AS
78622010-06-28 Anatoly Sokolov <aesok@post.ru>
7863
7864 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
7865
3b06d379
SB
78662010-06-28 Steven Bosscher <steven@gcc.gnu.org>
7867
7868 * c-cppbuiltin.c: Do not include except.h.
7869
d166d4c3
AK
78702010-06-24 Andi Kleen <ak@linux.intel.com>
7871
9faeb493
UB
7872 * c-common.c (warn_for_omitted_condop): New.
7873 * c-common.h (warn_for_omitted_condop): Add prototype.
d166d4c3 7874
70cb8be6
JM
78752010-06-21 Joseph Myers <joseph@codesourcery.com>
7876
7877 * c.opt (lang-objc): Remove.
7878 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
7879
a4c97feb
JR
78802010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
7881
7882 * c-opts.c: Include "tm_p.h".
7883
6e2f1956
JM
78842010-06-20 Joseph Myers <joseph@codesourcery.com>
7885
7886 * c-common.c (parse_optimize_options): Update call to
7887 decode_options.
7888
bc87224e
NF
78892010-06-18 Nathan Froyd <froydnj@codesourcery.com>
7890
7891 * c-common.c (record_types_used_by_current_var_decl): Adjust for
7892 new type of types_used_by_cur_var_decl.
7893
b49cf425
JR
78942010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
7895
7896 PR bootstrap/44512
7897 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
7898 for C++ standard compliance.
7899
59f9c2ed
JM
79002010-06-16 Jason Merrill <jason@redhat.com>
7901
7902 * c.opt: Add -Wnoexcept.
7903
33766b66
RG
79042010-06-16 Richard Guenther <rguenther@suse.de>
7905
7906 PR c/44555
7907 * c-common.c (c_common_truthvalue_conversion): Remove
7908 premature and wrong optimization concering ADDR_EXPRs.
7909
eff7e30c
AC
79102010-06-15 Arnaud Charlet <charlet@adacore.com>
7911
7912 * c-ada-spec.c (dump_sloc): Remove column info.
7913 (is_simple_enum): New function.
7914 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
7915 enum types when relevant.
7916
6312e84d
MLI
79172010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
7918
9faeb493 7919 * c-common.c (conversion_warning): Warn at expression
6312e84d
MLI
7920 location.
7921
1cb42611
JM
79222010-06-10 Joseph Myers <joseph@codesourcery.com>
7923
7924 * c-opts.c (c_common_handle_option): Don't handle
7925 OPT_fshow_column.
7926
a9429e29
LB
79272010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
7928
7929 * c-pragma.c (push_alignment): Use typed GC allocation.
7930 (handle_pragma_push_options): Likewise.
7931
7932 * c-common.c (parse_optimize_options): Likewise.
7933
7934 * c-common.h (struct sorted_fields_type): Add variable_size GTY
7935 option.
7936
5498f011
JM
79372010-06-07 Joseph Myers <joseph@codesourcery.com>
7938
7939 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
7940 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
7941 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
7942 flag_signed_bitfields, warn_strict_null_sentinel,
7943 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
7944 flag_gen_declaration, flag_no_gnu_keywords,
7945 flag_implement_inlines, flag_implicit_templates,
7946 flag_implicit_inline_templates, flag_optional_diags,
7947 flag_elide_constructors, flag_default_inline, flag_rtti,
7948 flag_conserve_space, flag_access_control, flag_check_new,
7949 flag_new_for_scope, flag_weak, flag_working_directory,
7950 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
7951 flag_enforce_eh_specs, flag_threadsafe_statics,
7952 flag_pretty_templates): Remove.
7953 * c-common.h (flag_preprocess_only, flag_nil_receivers,
7954 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
7955 flag_replace_objc_classes, flag_undef, flag_no_builtin,
7956 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
7957 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
7958 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
7959 flag_no_gnu_keywords, flag_implement_inlines,
7960 flag_implicit_templates, flag_implicit_inline_templates,
7961 flag_optional_diags, flag_elide_constructors, flag_default_inline,
7962 flag_rtti, flag_conserve_space, flag_access_control,
7963 flag_check_new, flag_new_for_scope, flag_weak,
7964 flag_working_directory, flag_use_cxa_atexit,
7965 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
7966 flag_threadsafe_statics, flag_pretty_templates,
7967 warn_strict_null_sentinel): Remove.
7968 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
7969 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
7970 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
7971 fimplicit-inline-templates, fimplicit-templates,
7972 flax-vector-conversions, fms-extensions, fnil-receivers,
7973 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
7974 frtti, fshort-double, fshort-enums, fshort-wchar,
7975 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
7976 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
7977 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
7978 gen-decls, undef): Use Var.
7979 (fdefault-inline, foptional-diags): Document as doing nothing.
7980 * c-opts.c (c_common_handle_option): Remove cases for options now
7981 using Var. Mark ignored options as such.
7982
39dabefd
SB
79832010-06-05 Steven Bosscher <steven@gcc.gnu.org>
7984
9faeb493 7985 * c-common.c: Moved to here from parent directory.
39dabefd
SB
7986 * c-common.def: Likewise.
7987 * c-common.h: Likewise.
7988 * c-cppbuiltin.c: Likewise.
7989 * c-dump.c: Likewise.
7990 * c-format.c: Likewise.
7991 * c-format.h : Likewise.
7992 * c-gimplify.c: Likewise.
7993 * c-lex.c: Likewise.
7994 * c-omp.c: Likewise.
7995 * c.opt: Likewise.
7996 * c-opts.c: Likewise.
7997 * c-pch.c: Likewise.
7998 * c-ppoutput.c: Likewise.
7999 * c-pragma.c: Likewise.
8000 * c-pragma.h: Likewise.
8001 * c-pretty-print.c: Likewise.
8002 * c-pretty-print.h: Likewise.
8003 * c-semantics.c: Likewise.
8004 * stub-objc.c: Likewise.
8005
8006 * c-common.c: Include gt-c-family-c-common.h.
8007 * c-pragma.c: Include gt-c-family-c-pragma.h.
8008\f
cbe34bb5 8009Copyright (C) 2010-2017 Free Software Foundation, Inc.
39dabefd
SB
8010
8011Copying and distribution of this file, with or without modification,
8012are permitted in any medium without royalty provided the copyright
8013notice and this notice are preserved.