]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c-family/ChangeLog
reflect: fix StructOf hash and string
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
CommitLineData
f8ad043f
JM
12018-06-01 Jason Merrill <jason@redhat.com>
2
3 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
4 201703.
5
abc24d93
EB
62018-06-01 Eric Botcazou <ebotcazou@adacore.com>
7
8 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
9 declaration for a typedef independently of whether the declaration of
10 the subtype is generated.
11
d258f4aa
MS
122018-05-31 Martin Sebor <msebor@redhat.com>
13
14 PR c/82063
15 * c.opt (-Wno-alloc-size-larger-than): New option.
16
b67b9225
DP
172018-04-22 David Pagan <dave.pagan@oracle.com>
18
19 PR c/55976
20 * c-opts.c (c_common_post_options): Set default for warn_return_type
21 for C++/C++ with ObjC extensions only. For C, makes it possible to
22 differentiate between default (no option), -Wreturn-type, and
23 -Wno-return-type.
24
04eb9c55
JM
252018-05-29 Jason Merrill <jason@redhat.com>
26
27 * c.opt (Winit-list-lifetime): New flag.
28
b0c31bc6
BE
292018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
30
31 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
32 splay_tree_delete_pointers.
33
44284983
JJ
342018-05-26 Jakub Jelinek <jakub@redhat.com>
35
36 PR bootstrap/85921
37 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
38 noinline variable to workaround broken kernel headers.
39
b46b715d
JM
402018-05-18 Jason Merrill <jason@redhat.com>
41
42 * c.opt (Wdeprecated-copy): New flag.
43
40659769
ML
442018-05-17 Martin Liska <mliska@suse.cz>
45
46 * c-warn.c (overflow_warning): Do not use
47 space in between 'G_' and '('.
48
403962ea
JM
492018-05-09 Jason Merrill <jason@redhat.com>
50
51 * c-common.c (valid_array_size_p): Add complain parameter.
52 * c-common.h: ...which defaults to true.
53
1c9ee609
JJ
542018-05-11 Jakub Jelinek <jakub@redhat.com>
55
56 PR c/85696
57 * c-omp.c (c_omp_predetermined_sharing): Return
58 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
59
19916065
ML
602018-05-11 Martin Liska <mliska@suse.cz>
61
62 PR sanitizer/85556
63 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
64 TREE_LIST values.
65
79e7b1fe
JJ
662018-05-10 Jakub Jelinek <jakub@redhat.com>
67
68 PR c++/85662
69 * c-common.h (fold_offsetof_1): Removed.
70 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
71 CTX argument defaulted to ERROR_MARK.
72 * c-common.c (fold_offsetof_1): Renamed to ...
73 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
74 argument, convert the pointer constant to TYPE and use size_binop
75 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
76 a pointer type. Adjust recursive calls.
77
86c12f76
EB
782018-05-10 Eric Botcazou <ebotcazou@adacore.com>
79
80 PR c++/85400
81 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
82
ee336e84
NS
832018-05-07 Nathan Sidwell <nathan@acm.org>
84
85 * c.opt (ffor-scope): Remove functionality, issue warning.
86
6c072e21
NS
872018-05-03 Nathan Sidwell <nathan@acm.org>
88
89 * c.opt (ffriend-injection): Remove functionality, issue warning.
90
2cc7d3a7
DM
912018-05-01 David Malcolm <dmalcolm@redhat.com>
92
93 PR c/84258
94 * c-format.c (struct format_check_results): Add field
95 "number_non_char".
96 (check_format_info): Initialize it, and warn if encountered.
97 (check_format_arg): Distinguish between wide char and
98 everything else when detecting arrays of non-char.
99
7761dfbe
DM
1002018-04-30 David Malcolm <dmalcolm@redhat.com>
101
102 * c-format.c (get_corrected_substring): Update for
103 location_get_source_line returning a char_span. Use a char_span
104 when handling the prefix of the correction.
105 * c-indentation.c (get_visual_column): Update for
106 location_get_source_line returning a char_span.
107 (get_first_nws_vis_column): Likewise.
108
62e98ef1
DM
1092018-03-29 David Malcolm <dmalcolm@redhat.com>
110
111 PR c++/84269
112 * known-headers.cc (get_stdlib_header_for_name): Add various names
113 from <assert.h>, <string.h>, and <memory.h>; add more names from
114 <stdio.h>.
115
a7dea617
JJ
1162018-03-27 Jakub Jelinek <jakub@redhat.com>
117
118 PR c++/85061
119 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
120 get_base_address of the second operand is a VAR_P, rather than the
121 operand itself, and use gcc_checking_assert instead of gcc_assert.
122
889a3a30
MP
1232018-03-23 Marek Polacek <polacek@redhat.com>
124
125 PR c++/85045
126 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
127 <case RDIV_EXPR>: Tweak condition.
128
452154b9
EB
1292018-03-20 Eric Botcazou <ebotcazou@adacore.com>
130
131 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
132
63ecb626
JJ
1332018-03-16 Jakub Jelinek <jakub@redhat.com>
134
ce811fc4
JJ
135 PR c/84909
136 * c-warn.c (conversion_warning): Replace "to to" with "to" in
137 diagnostics.
138
63ecb626
JJ
139 PR c/84910
140 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
141 diagnostics.
142
a1295eec
RB
1432018-03-16 Richard Biener <rguenther@suse.de>
144
145 PR c/84873
146 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
147 unshare the possibly folded expression.
148
919674fb
RB
1492018-03-15 Richard Biener <rguenther@suse.de>
150
151 PR c/84873
152 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
153
f99309b2
MS
1542018-03-13 Martin Sebor <msebor@redhat.com>
155
156 PR tree-optimization/84725
157 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
158 with all three narrow character types, including their qualified forms.
159
e9b9fa4c
MS
1602018-03-12 Martin Sebor <msebor@redhat.com>
161
162 PR tree-optimization/83456
163 * gcc/c-family/c-common.c (check_function_restrict): Return bool.
164 Restore checking of bounded built-in functions.
165 (check_function_arguments): Also return the result
166 of warn_for_restrict.
167 * gcc/c-family/c-common.c (check_function_restrict): Return bool.
168 * gcc/c-family/c-warn.c (warn_for_restrict): Return bool.
169
0805d020
MP
1702018-03-02 Marek Polacek <polacek@redhat.com>
171
172 PR c++/84171
173 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
174 is erroneous.
175
ed2a2f08
TS
1762018-03-02 Thomas Schwinge <thomas@codesourcery.com>
177
178 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
179 function".
180
90abdde0
MP
1812018-03-01 Marek Polacek <polacek@redhat.com>
182
183 PR c++/84639
184 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
185 alignment in computation.
186
c6db43fa
EB
1872018-02-28 Eric Botcazou <ebotcazou@adacore.com>
188
189 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
190 <REAL_TYPE>: Deal specifically with _Float128/__float128.
191
9e25c7ed
EB
1922018-02-28 Eric Botcazou <ebotcazou@adacore.com>
193
194 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
195 (is_char_array): Take a type instead of a declaration.
196 (dump_ada_array_type): Likewise.
197 (is_simple_enum): Minor tweak.
198 (dump_ada_enum_type): New function extracted from...
199 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
200 <INTEGER_TYPE>: Remove unreachable code.
201 <RECORD_TYPE>: Likewise. Minor tweaks.
202 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
203 <ENUMERAL_TYPE>: New case.
204 <RECORD_TYPE>: Factor out common code.
205 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
206 Minor tweaks. Deal with enumeral types.
207 (dump_ada_structure): Minor tweaks.
208
09de3550
EB
2092018-02-28 Eric Botcazou <ebotcazou@adacore.com>
210
211 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
212 address for incomplete structures.
213 (dump_forward_type): Do not bail out for incomplete structures.
214 (dump_ada_declaration): Do not special-case incomplete structures
215 for subtypes. Dump them as null records for types.
216
095d8d4b
EB
2172018-02-28 Eric Botcazou <ebotcazou@adacore.com>
218
219 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
220 (is_char_array): Fix formatting.
221 (dump_template_types): Likewise.
222 (dump_generic_ada_node): Rename into...
223 (dump_ada_node): ...this.
224 <POINTER_TYPE>: Remove superfluous space. Use generic address for
225 incomplete structures and not for empty structures. Do not use it
226 when forward declarations are needed.
227 (dump_forward_type): New function.
228 (dump_nested_types): Remove FORWARD parameter. Do not consider
229 TREE_VISITED and do not generate a forward declaration. Only dump
230 original nested types for nested declaration.
231 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
232 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
233 <RECORD_TYPE>: Do not consider TREE_VISITED.
234 (dump_ada_declaration): Use booleans and fix formatting throughout.
235 <TYPE_DECL>: Skip incomplete structures and not empty structures.
236 Call dump_forward_type instead of dump_nested_types for a typedef.
237 Remove superfluous check and adjust call to dump_nested_types.
238 <POINTER_TYPE>: Call dump_forward_type and fall through.
239 (dump_ada_struct_decl): Rename into...
240 (dump_ada_structure): ...this. Do not special-case empty structures.
241
d4cfd486
MS
2422018-02-27 Martin Sebor <msebor@redhat.com>
243
244 PR c++/83871
245 * c.opt (-Wmissing-attributes): New option.
246
b22dbd03
ML
2472018-02-21 Martin Liska <mliska@suse.cz>
248
249 * c.opt (Wcatch-value=): Add IntegerRange.
250
883dfe2a
JM
2512018-02-15 Jason Merrill <jason@redhat.com>
252
253 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
254
0444aa9c
NS
2552018-02-09 Nathan Sidwell <nathan@acm.org>
256
257 PR c/84293
258 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
259 arg.
260 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
261 arg. Adjust.
262
cea71f0a
MS
2632018-02-09 Martin Sebor <msebor@redhat.com>
264
265 PR lto/84212
266 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
267 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
268 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
269 (-Wstrict-overflow, -Wsuggest-attribute): Same.
270 (-Wuninitialized): Same.
271
8c8b7be5
EB
2722018-02-09 Eric Botcazou <ebotcazou@adacore.com>
273
274 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
275 keyword for components.
276
7c30b12a
PC
2772018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
278
279 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
280
eece7fe5
JK
2812018-02-02 Julia Koval <julia.koval@intel.com>
282
283 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
284
7d07a93a
MP
2852018-01-29 Marek Polacek <polacek@redhat.com>
286
287 PR c/83966
288 * c-format.c (check_function_format): Check current_function_decl.
289
53723269
JJ
2902018-01-27 Jakub Jelinek <jakub@redhat.com>
291
292 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
293 argument.
294 (LAZY_HEX_FP_VALUES_CNT): Define.
295 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
296 values rather than just 12.
297 (builtin_define_with_hex_fp_value): Likewise.
298
7365279f
BK
2992018-01-18 Boris Kolpackov <boris@codesynthesis.com>
300
301 PR other/70268
53723269
JJ
302 * c.opt (-fmacro-prefix-map): New option.
303 * c-opts.c (c_common_handle_option): Handle it.
304 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
305 * c-ppoutput.c (init_pp_output): Likewise.
7365279f 306
bb9869d5
DM
3072018-01-17 David Malcolm <dmalcolm@redhat.com>
308
309 PR c++/83814
310 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
311
68dc87c3
EB
3122018-01-10 Eric Botcazou <ebotcazou@adacore.com>
313
314 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
315 Skip 'f' and 'F' characters if it is true.
316 (store_ada_macro): Minor tweak.
317 (dump_ada_macros) <CPP_COMMENT>: Likewise.
318 <CPP_WSTRING>: Likewise.
319 <CPP_STRING>: Output '&' in the buffer if not the first string.
320 <CPP_NUMBER>: Adjust calls to dump_number.
321
9a004410
DM
3222018-01-10 David Malcolm <dmalcolm@redhat.com>
323
324 PR c++/43486
325 * c-common.c: Include "selftest.h".
326 (get_atomic_generic_size): Perform the test for integral type
327 before the range test for any integer constant, fixing indentation
328 of braces. Call fold_for_warn before testing for an INTEGER_CST.
329 (reject_gcc_builtin): Strip any location wrapper from EXPR.
330 (selftest::test_fold_for_warn): New function.
331 (selftest::c_common_c_tests): New function.
332 (selftest::c_family_tests): Call it, and
333 selftest::c_pretty_print_c_tests.
334 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
335 * c-format.c (check_format_arg): Convert VAR_P check to a
336 fold_for_warn.
337 * c-pretty-print.c: Include "selftest.h".
338 (pp_c_cast_expression): Don't print casts for location wrappers.
339 (selftest::assert_c_pretty_printer_output): New function.
340 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
341 (selftest::test_location_wrappers): New function.
342 (selftest::c_pretty_print_c_tests): New function.
343 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
344
5c0caeb3
RS
3452018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
346 Alan Hayward <alan.hayward@arm.com>
347 David Sherwood <david.sherwood@arm.com>
348
349 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
350
73a699ae
RS
3512018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
352 Alan Hayward <alan.hayward@arm.com>
353 David Sherwood <david.sherwood@arm.com>
354
355 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
356 as polynomial.
357
928686b1
RS
3582018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
359 Alan Hayward <alan.hayward@arm.com>
360 David Sherwood <david.sherwood@arm.com>
361
362 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
363 (convert_vector_to_array_for_subscript): Handle polynomial
364 TYPE_VECTOR_SUBPARTS.
365 (c_common_type_for_mode): Check valid_vector_subparts_p.
366 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
367 VECTOR_CST_NELTS.
368
85ec4feb
JJ
3692018-01-03 Jakub Jelinek <jakub@redhat.com>
370
371 Update copyright years.
372
170a8bd6
EB
3732017-12-22 Mike Stump <mikestump@comcast.net>
374 Eric Botcazou <ebotcazou@adacore.com>
375
376 * c-pragma.c (init_pragma): Register pragma GCC unroll.
377 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
378
18408e96
AO
3792017-12-22 Alexandre Oliva <aoliva@redhat.com>
380
381 PR debug/83527
382 PR debug/83419
383 * c-semantics.c (only_debug_stmts_after_p): New.
384 (pop_stmt_list): Clear side effects in debug-only stmt list.
385 Check for single nondebug stmt followed by debug stmts only.
386
c12d20d4
AO
3872017-12-21 Alexandre Oliva <aoliva@redhat.com>
388
389 PR debug/83419
390 * c-semantics.c (pop_stmt_list): Propagate side effects from
391 single nondebug stmt to container list.
392
01512446
JJ
3932017-12-19 Jakub Jelinek <jakub@redhat.com>
394
395 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
396 conditions with typical order conditions.
397
82cfbd01
MP
3982017-12-18 Marek Polacek <polacek@redhat.com>
399
400 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
401 not in effect.
402
99da11ec
MS
4032017-12-17 Martin Sebor <msebor@redhat.com>
404
405 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
406 an error for attribute warn_if_not_aligned.
407
cc8bea0a
MS
4082017-12-16 Martin Sebor <msebor@redhat.com>
409
410 PR tree-optimization/78918
411 * c-common.c (check_function_restrict): Avoid checking built-ins.
412 * c.opt (-Wrestrict): Include in -Wall.
413
4849deb1
JJ
4142017-12-15 Jakub Jelinek <jakub@redhat.com>
415
416 * c-attribs.c (c_common_attribute_table,
417 c_common_format_attribute_table): Swap affects_type_identity
418 and handler fields, adjust comments.
419
c65e18d3
BE
4202017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
421
422 * c.opt (Wcast-function-type): New warning option.
423 * c-lex.c (get_fileinfo): Avoid warning.
424 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
425
2004617a
QZ
4262017-12-14 Qing Zhao <qing.zhao@oracle.com>
427
7365279f 428 PR middle_end/79538
2004617a
QZ
429 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
430 Adjust the size of buf1 and buf2, add a new buf to avoid
431 format-overflow warning.
432
96a95ac1
AO
4332017-12-12 Alexandre Oliva <aoliva@redhat.com>
434
435 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
436 subsequent statement list.
437
5d9ae53d
MS
4382017-12-07 Martin Sebor <msebor@redhat.com>
439
440 PR c/81544
441 PR c/81566
442 * c-attribs.c (attr_aligned_exclusions): New array.
443 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
444 (attr_common_exclusions, attr_const_pure_exclusions): Same.
445 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
446 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
447 (attr_warn_unused_result_exclusions): Same.
448 (handle_hot_attribute, handle_cold_attribute): Simplify.
449 (handle_const_attribute): Warn on function returning void.
450 (handle_pure_attribute): Same.
451 (handle_aligned_attribute): Diagnose conflicting attribute
452 specifications.
453 * c-warn.c (diagnose_mismatched_attributes): Simplify.
454
c79144f8
DM
4552017-12-06 David Malcolm <dmalcolm@redhat.com>
456
457 PR c/83236
458 * c-common.c (selftest::c_family_tests): Call
459 selftest::c_spellcheck_cc_tests.
460 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
461 * c-spellcheck.cc: Include "selftest.h".
462 (name_reserved_for_implementation_p): New function.
463 (should_suggest_as_macro_p): New function.
464 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
465 should_suggest_as_macro_p and call it.
466 (selftest::test_name_reserved_for_implementation_p): New function.
467 (selftest::c_spellcheck_cc_tests): New function.
468 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
469
613bc14f
DM
4702017-12-06 David Malcolm <dmalcolm@redhat.com>
471
472 * c-spellcheck.cc: New file, taken from macro-handling code in
473 spellcheck-tree.c.
474 * c-spellcheck.h: New file, taken from macro-handling code in
475 spellcheck-tree.h.
476
e76c7157
JJ
4772017-12-01 Jakub Jelinek <jakub@redhat.com>
478
479 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
480 attribute.
481 (handle_simd_attribute): Don't check for "cilk simd function"
482 attribute. Reindent, formatting changes.
483
b0da4034
JK
4842017-11-30 Julia Koval <julia.koval@intel.com>
485
486 * c-common.h (inv_list): Remove.
487
058f0b9e
JJ
4882017-11-28 Jakub Jelinek <jakub@redhat.com>
489
490 PR sanitizer/81275
491 * c-common.c (c_switch_covers_all_cases_p_1,
492 c_switch_covers_all_cases_p): New functions.
493 * c-common.h (c_switch_covers_all_cases_p): Declare.
494
5e9d6aa4
JK
4952017-11-28 Julia Koval <julia.koval@intel.com>
496 Sebastian Peryt <sebastian.peryt@intel.com>
497
498 * array-notation-common.c: Delete.
499 * c-cilkplus.c: Ditto.
500 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
501 * c-common.def (ARRAY_NOTATION_REF): Remove.
502 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
503 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
504 c_validate_cilk_plus_loop, cilkplus_an_parts,
505 cilk_ignorable_spawn_rhs_op,
506 cilk_recognize_spawn): Remove.
507 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
508 * c-omp.c: Remove CILK_SIMD check.
509 * c-pragma.c: Ditto.
510 * c-pragma.h: Remove CILK related pragmas.
511 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
512 ARRAY_NOTATION_REF condition.
513 (c_pretty_printer::expression): Ditto.
514 * c.opt (fcilkplus): Remove.
515 * cilk.c: Delete.
516
1af4ebf5
MG
5172017-11-21 Marc Glisse <marc.glisse@inria.fr>
518
519 * c-pretty-print.c (pp_c_additive_expression,
520 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
521
d44ed508
JJ
5222017-11-21 Jakub Jelinek <jakub@redhat.com>
523
7d2f0f9b
JJ
524 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
525
d44ed508
JJ
526 PR c++/83059
527 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
528 instead of tree_to_uhwi, formatting fix.
529
26edace6
DM
5302017-11-20 David Malcolm <dmalcolm@redhat.com>
531
532 PR c/81404
533 * known-headers.cc: New file, based on material from c/c-decl.c.
534 (suggest_missing_header): Copied as-is.
535 (get_stdlib_header_for_name): New, based on get_c_name_hint but
536 heavily edited to add C++ support. Add some knowledge about
537 <limits.h>, <stdint.h>, and <wchar.h>.
538 * known-headers.h: Likewise.
539
6c7a259b
DM
5402017-11-20 David Malcolm <dmalcolm@redhat.com>
541
542 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
543 (lookup_name_fuzzy): Likewise. Convert return type from
544 const char * to name_hint. Add location_t param.
545 * name-hint.h: New header.
546
f9c59f7e
JJ
5472017-11-19 Jakub Jelinek <jakub@redhat.com>
548
549 PR c/66618
550 PR c/69960
551 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
552
1e39313a
JM
5532017-11-16 Joseph Myers <joseph@codesourcery.com>
554
555 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
556 expected publication date of C17.
557 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
558
3ca0dc60
JM
5592017-11-15 Joseph Myers <joseph@codesourcery.com>
560
561 PR c/81156
562 * c-common.c (c_common_reswords): Add __builtin_tgmath.
563 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
564
025d57f0
MS
5652017-11-10 Martin Sebor <msebor@redhat.com>
566
567 PR c/81117
568 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
569 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
570 * c.opt (-Wstringop-truncation): New option.
571
1b6fa695
ML
5722017-11-06 Martin Liska <mliska@suse.cz>
573
574 PR middle-end/82404
575 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
576 FE.
577 * c.opt: Set default value of warn_return_type.
578
64a5912c
DM
5792017-10-31 David Malcolm <dmalcolm@redhat.com>
580
581 * c-common.c (binary_op_error): Update for renaming of
582 error_at_rich_loc.
583 (c_parse_error): Likewise.
584 * c-warn.c (warn_logical_not_parentheses): Likewise for
585 renaming of inform_at_rich_loc.
586 (warn_for_restrict): Likewise for renaming of
587 warning_at_rich_loc_n.
588
c76dc9c3
JM
5892017-10-30 Joseph Myers <joseph@codesourcery.com>
590
591 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
592 * c-opts.c (set_std_c17): New function.
593 (c_common_init_options): Use gnu17 as default C version.
594 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
595
ee5fd23a
MM
5962017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
597
598 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
599 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
600 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
601 __FP_FAST_FMA<N>X.
602
d1047465
MP
6032017-10-23 Marek Polacek <polacek@redhat.com>
604
605 PR c/82681
606 * c-warn.c (warnings_for_convert_and_check): Fix typos.
607
9e878cf1
EB
6082017-10-19 Eric Botcazou <ebotcazou@adacore.com>
609
610 * c-common.c (check_builtin_function_arguments): Also check arguments
611 of __builtin_alloca_with_align_and_max.
612
89b6abbb
DM
6132017-10-17 David Malcolm <dmalcolm@redhat.com>
614
615 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
616 rather than NULL to format_warning_va.
617 (check_format_types): Likewise when calling format_type_warning.
618 Remove code to extract source_ranges and source_range * in favor
619 of just a location_t.
620 (format_type_warning): Convert source_range * param to a
621 location_t.
622
39382c09
JJ
6232017-10-13 Jakub Jelinek <jakub@redhat.com>
624
625 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
626 [LR]SHIFT_EXPR.
627
62e1c678
DM
6282017-10-12 David Malcolm <dmalcolm@redhat.com>
629
630 * c-common.c (enum missing_token_insertion_kind): New enum.
631 (get_missing_token_insertion_kind): New function.
632 (maybe_suggest_missing_token_insertion): New function.
633 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
634
b90c9338
NS
6352017-10-11 Nathan Sidwell <nathan@acm.org>
636
637 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
638 (c_common_handle_option): Update incpath_kind names.
639
3a266bcd
ML
6402017-10-11 Martin Liska <mliska@suse.cz>
641
642 PR sanitizer/82490
643 * c-attribs.c (handle_no_sanitize_attribute): Report directly
644 Wattributes warning.
645
8e6cdc90
RS
6462017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
647
648 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
649 operating on trees as wide_ints.
650 * c-common.c (pointer_int_sum): Likewise.
651 * c-pretty-print.c (pp_c_integer_constant): Likewise.
652 * c-warn.c (match_case_to_enum_1): Likewise.
653 (c_do_switch_warnings): Likewise.
654 (maybe_warn_shift_overflow): Likewise.
655
802b38c9
JJ
6562017-10-10 Jakub Jelinek <jakub@redhat.com>
657
658 PR c/82437
659 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
660 instead of wide_int::from.
661
4e34b338
JJ
6622017-10-06 Jakub Jelinek <jakub@redhat.com>
663
664 PR c/82437
665 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
666 using to_widest use wide_int with the larger of the two precisions.
667
4bc4b2b4
BE
6682017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
669
670 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
671 functions.
672
a1488398
RS
6732017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
674
675 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
676 when combining the original unconverted comparison operands.
677
01c9fb68
JJ
6782017-09-29 Jakub Jelinek <jakub@redhat.com>
679
680 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
681 attribute.
682
6e3e8419
EB
6832017-09-29 Eric Botcazou <ebotcazou@adacore.com>
684
685 * c-ada-spec.c (to_ada_name): Add index parameter.
686 (pp_ada_tree_identifier): Likewise.
687 (dump_ada_macros): Adjust call to to_ada_name.
688 (struct overloaded_name_hash): New type.
689 (struct overloaded_name_hasher): Likewise.
690 (overloaded_names): New hash table.
691 (compute_overloading_index): New function.
692 (dump_ada_decl_name): Call it and pass the result to
693 pp_ada_tree_identifier.
694 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
695 (dump_ada_function_declaration): Likewise.
696 (dump_generic_ada_node): Likewise.
697 (print_constructor): Likewise.
698 (print_destructor): Likewise.
699 (dump_ada_specs): Delete overloaded_names table.
700
79310774
EB
7012017-09-29 Eric Botcazou <ebotcazou@adacore.com>
702
703 * c-ada-spec.c (max_ada_macros): Move around.
704 (store_ada_macro_index): Likewise.
705 (source_file): Rename into...
706 (macro_source_file): ...this.
707 (count_ada_macro): Move around.
708 (store_ada_macro): Likewise.
709 (compare_macro): Likewise.
710 (print_ada_macros): Merge in...
711 (dump_ada_macros): ...this.
712 (source_file_base): Rename into...
713 (current_source_file): ...this.
714 (print_comment): Move around.
715 (dump_ada_nodes): Call dump_ada_declaration directly.
716 (struct with): Change type of limited field to bool.
717 (append_withs): Change type of limited_access parameter to bool.
718 (pp_ada_tree_identifie): Likewise.
719 (dump_ada_decl_nam): Likewise.
720 (dump_generic_ada_node): Likewise. Do not print the return type.
721 (to_ada_name): Change type of space_found parameter to bool.
722 (dump_ada_function_declaration): Return void and change type of
723 parameters to bool. Also print the return type for a function.
724 (print_ada_methods): Rename into...
725 (dump_ada_methods): ...this.
726 (print_ada_declaration): Rename into ...
727 (dump_ada_declaration): ...this. Do not print the return type.
728 (print_ada_struct_decl): Rename into...
729 (dump_ada_struct_decl): ...this.
730
7d386d45
JJ
7312017-09-29 Jakub Jelinek <jakub@redhat.com>
732
733 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
734 rather than DECL_INITIAL.
735 (common_handle_aligned_attribute): Likewise.
736
9ed32e27
AO
7372017-09-20 Alexandre Oliva <aoliva@redhat.com>
738
739 * c.opt (gen-decls): Add RejectNegative.
740
026a79f7
AS
7412017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
742 Jakub Jelinek <jakub@redhat.com>
743
744 Add support for -std=c++2a.
745 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
746 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
747 * c-opts.c (set_std_cxx2a): New.
748 (c_common_handle_option): Set options when -std=c++2a is enabled.
749 (c_common_post_options): Adjust comments.
750 (set_std_cxx14, set_std_cxx17): Likewise.
751
4a8ca690
EB
7522017-09-15 Eric Botcazou <ebotcazou@adacore.com>
753
754 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
755 message for non-uniform endianness and issue a warning in C++.
756
7b936140
JJ
7572017-09-15 Jakub Jelinek <jakub@redhat.com>
758
759 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
760 (Wc++17-compat): Change from undocumented alias to option.
761 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
762 change C++1z to C++17 in description.
763 (std=c++1z, std=gnu++1z): Change from option to undocumented
764 deprecated alias.
765 (std=c++17, std=gnu++17): Change from undocumented alias to option.
766 Adjust description.
767 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
768 * c-opts.c (set_std_cxx1z): Rename to ...
769 (set_std_cxx17): ... this.
770 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
771 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
7365279f 772 caller.
7b936140
JJ
773 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
774 comments.
775
12263f13
L
7762017-09-12 H.J. Lu <hongjiu.lu@intel.com>
777
778 * c-attribs.c (common_handle_aligned_attribute): Don't warn
779 function alignment if warn_if_not_aligned_p is true.
780
6836632e
NS
7812017-09-12 Nathan Sidwell <nathan@acm.org>
782
783 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
784 resort_sorted_fields): Move to c/c-decl.c.
785 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
786 (struct sorted_fields_type): Move to c/c-lang.h.
787
019bf9ad
JW
7882017-09-09 Jonathan Wakely <jwakely@redhat.com>
789
790 PR c++/81852
791 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
792
bc7fe952
MP
7932017-09-04 Marek Polacek <polacek@redhat.com>
794
795 PR c/81783
796 * c-warn.c (warn_tautological_bitwise_comparison): New function.
797 (warn_tautological_cmp): Call it.
798
de7c2c6a
BK
7992017-09-01 Boris Kolpackov <boris@codesynthesis.com>
800
801 * c-opts.c (c_common_finish): Write dependency information even if
802 there are errors.
803
d2e05fcb
JJ
8042017-09-01 Jakub Jelinek <jakub@redhat.com>
805
806 PR c/81887
807 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
808 (omp_pragmas_simd): ... here.
809 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
810 create new clauses list containing just simd clause.
811
18e2a8b8
RS
8122017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
813 Alan Hayward <alan.hayward@arm.com>
814 David Sherwood <david.sherwood@arm.com>
815
816 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
817 into scalar_mode_supported_p call.
818 (handle_mode_attribute): Update call to scalar_mode_supported_p.
819
16d22000
RS
8202017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
821 Alan Hayward <alan.hayward@arm.com>
822 David Sherwood <david.sherwood@arm.com>
823
824 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
825 for the mode iterator.
826
b397965c
RS
8272017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
828 Alan Hayward <alan.hayward@arm.com>
829 David Sherwood <david.sherwood@arm.com>
830
831 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
832 * c-common.c (c_build_vec_perm_expr): Likewise.
833
357b7604
RS
8342017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
835 Alan Hayward <alan.hayward@arm.com>
836 David Sherwood <david.sherwood@arm.com>
837
838 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
839
e05c94ba
RS
8402017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
841 Alan Hayward <alan.hayward@arm.com>
842 David Sherwood <david.sherwood@arm.com>
843
844 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
845 before calling targetm.addr_space.valid_pointer_mode.
846
5c20c4af
RS
8472017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
848 Alan Hayward <alan.hayward@arm.com>
849 David Sherwood <david.sherwood@arm.com>
850
851 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
852
c94843d2
RS
8532017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
854 Alan Hayward <alan.hayward@arm.com>
855 David Sherwood <david.sherwood@arm.com>
856
857 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
858 iterators.
859 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
860
4e10a5a7
RS
8612017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
862 Alan Hayward <alan.hayward@arm.com>
863 David Sherwood <david.sherwood@arm.com>
864
865 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
866 case statements.
867
130fcab0
ML
8682017-08-29 Martin Liska <mliska@suse.cz>
869
870 PR other/39851
871 * c-common.c (parse_optimize_options): Add argument to function
872 call.
873 * c-pragma.c (handle_pragma_diagnostic): Likewise.
874
14e18d71
DM
8752017-08-24 David Malcolm <dmalcolm@redhat.com>
876
877 * c-lex.c (interpret_float): Use token location
878 when building an EXCESS_PRECISION_EXPR.
879
2f687306
DM
8802017-08-21 David Malcolm <dmalcolm@redhat.com>
881
882 * c-common.c (check_function_arguments): Add "arglogs" param; pass
883 it to check_function_format.
884 * c-common.h (check_function_arguments): Add vec<location_t> *
885 param.
886 (check_function_format): Likewise.
887 * c-format.c (struct format_check_context): Add field "arglocs".
888 (check_function_format): Add param "arglocs"; pass it to
889 check_format_info.
890 (check_format_info): Add param "arglocs"; use it to initialize
891 new field of format_ctx.
892 (check_format_arg): Pass format_ctx->arglocs to new param of
893 check_format_info_main.
894 (class argument_parser): New field "arglocs".
895 (argument_parser::argument_parser): Add "arglocs_" param and use
896 it to initialize new field.
897 (argument_parser::check_argument_type): Pass new arglocs field to
898 check_format_types.
899 (check_format_info_main): Add param "arglocs", and use it when
900 constructing arg_parser.
901 (check_format_types): Add param "arglocs"; use it if non-NULL when
902 !EXPR_HAS_LOCATION (cur_param) to get at location information.
903
00aa1fa2
L
9042017-08-18 H.J. Lu <hongjiu.lu@intel.com>
905
906 PR c/53037
907 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
908 (c_common_attribute_table): Add warn_if_not_aligned.
909 (handle_aligned_attribute): Renamed to ...
910 (common_handle_aligned_attribute): Remove argument, name, and add
911 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
912 (handle_aligned_attribute): New.
913 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
914
27be025d
MS
9152017-08-14 Martin Sebor <msebor@redhat.com>
916
917 PR c/81117
918 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
919 (handle_nonstring_attribute): New function.
920
da67acb9
MS
9212017-08-14 Martin Sebor <msebor@redhat.com>
922
923 PR c/81117
924 * c-format.h (T89_G): New macro.
925 * c-format.c (local_gcall_ptr_node): New variable.
926 (init_dynamic_diag_info): Initialize it.
927
a8b522b4
ML
9282017-08-11 Martin Liska <mliska@suse.cz>
929
930 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
931 TARGET_SUPPORTS_ALIASES.
932
32129a17
DM
9332017-08-10 David Malcolm <dmalcolm@redhat.com>
934
935 * c-common.c (c_parse_error): Add rich_location * param, using it
936 rather implicitly using input_location.
937 * c-common.h (c_parse_error): Add rich_location * param.
938
30af3a2b
MP
9392017-08-09 Marek Polacek <polacek@redhat.com>
940
941 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
942 (c_common_truthvalue_conversion): Likewise.
943 * c-omp.c (c_finish_omp_atomic): Likewise.
944 * c-common.h (build_binary_op): Update declaration.
945
314e6352
ML
9462017-08-08 Martin Liska <mliska@suse.cz>
947
948 * c-ada-spec.c: Include header files.
949 * c-ubsan.c: Likewise.
950 * c-warn.c: Likewise.
951
56b5041c
JJ
9522017-08-07 Jakub Jelinek <jakub@redhat.com>
953
954 PR c/69389
955 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
956
db440138
EB
9572017-08-07 Eric Botcazou <ebotcazou@adacore.com>
958
959 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
960 (print_ada_methods): Likewise.
961 (print_ada_declaration): Likewise.
962
577eec56
ML
9632017-08-07 Martin Liska <mliska@suse.cz>
964
965 * array-notation-common.c: Add new includes.
966 * c-format.c( handle_format_attribute): Canonicalize a format
967 function name.
968 * c-lex.c (c_common_has_attribute): Canonicalize name of an
969 attribute.
970 * c-pretty-print.c: Add new include.
971
b854df3c
EB
9722017-08-05 Eric Botcazou <ebotcazou@adacore.com>
973
974 * c-ada-spec.c (has_static_fields): Look only into variables.
975 (print_constructor): Add TYPE parameter and use it for the name.
976 (print_destructor): Likewise.
977 (print_ada_declaration): Adjust to new constructor/destructor names.
978 Adjust calls to print_constructor and print_destructor.
979 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
980 Look only into variables in the final loop.
981
9f2cb25e
EB
9822017-08-01 Eric Botcazou <ebotcazou@adacore.com>
983
984 * c-ada-spec.c (has_static_fields): Look only into fields.
985 (dump_generic_ada_node): Small tweak.
986 (dump_nested_types): Look only into fields.
987 (print_ada_declaration): Look only into methods. Small tweak.
988 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
989
f4bcd9eb
EB
9902017-08-01 Eric Botcazou <ebotcazou@adacore.com>
991
992 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
993 (dump_ada_function_declaration): Likewise.
994 (dump_generic_ada_node): Likewise.
995 (print_ada_declaration): Add support for const-qualified variables.
996
f34ebeb2
ML
9972017-07-31 Martin Liska <mliska@suse.cz>
998
999 PR sanitize/81530
1000 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
1001 Guard condition with flag_sanitize_p also with current_function_decl
1002 non-null equality.
1003 (ubsan_maybe_instrument_reference_or_call): Likewise.
1004
218e5d04
UB
10052017-07-30 Uros Bizjak <ubizjak@gmail.com>
1006
1007 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
1008
942047f2
EB
10092017-07-29 Eric Botcazou <ebotcazou@adacore.com>
1010
1011 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
1012 for enumeral types.
1013 (print_ada_declaration): Add missing guard for record types.
1014
a40ff0ae
JJ
10152017-07-27 Jakub Jelinek <jakub@redhat.com>
1016
1017 PR c/45784
1018 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
1019 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
1020 new COMPOUND_EXPRs around the rhs of the comparison.
1021
06bd22f6
MP
10222017-07-27 Marek Polacek <polacek@redhat.com>
1023
1024 PR c/81417
1025 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
1026 the types.
1027
036ea399
JJ
10282017-07-27 Jakub Jelinek <jakub@redhat.com>
1029
1030 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
1031 (handle_noipa_attribute): New function.
1032
417ca011
TD
10332017-07-07 Torsten Duwe <duwe@suse.de>
1034
1035 * c-attribs.c (c_common_attribute_table): Add entry for
1036 "patchable_function_entry".
1037
5aaa8fb4
NS
10382017-07-20 Nathan Sidwell <nathan@acm.org>
1039
1040 Remove TYPE_METHODS.
1041 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
1042 dump_ada_template, print_ada_methods,
1043 print_ada_declaration): Member fns are on TYPE_FIELDS.
1044
ff22eb12
NS
10452017-07-18 Nathan Sidwell <nathan@acm.org>
1046
1047 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
1048
eea77d1f
DM
10492017-07-14 David Malcolm <dmalcolm@redhat.com>
1050
1051 * c-common.c (try_to_locate_new_include_insertion_point): New
1052 function.
1053 (per_file_includes_t): New typedef.
1054 (added_includes_t): New typedef.
1055 (added_includes): New variable.
1056 (maybe_add_include_fixit): New function.
1057 * c-common.h (maybe_add_include_fixit): New decl.
1058
281ac396
MS
10592017-07-10 Martin Sebor <msebor@redhat.com>
1060
1061 PR other/81345
1062 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
1063
b6f43128
DM
10642017-07-06 David Malcolm <dmalcolm@redhat.com>
1065
1066 * c-common.c (selftest::c_family_tests): New.
1067 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
1068 (selftest::c_family_tests): New decl.
1069
efbf55b0
MP
10702017-07-04 Marek Polacek <polacek@redhat.com>
1071
1072 PR c/81231
1073 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
1074 types.
1075
6c86bd88
MP
10762017-07-04 Marek Polacek <polacek@redhat.com>
1077
1078 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
1079
17a7218b
ML
10802017-06-28 Martin Liska <mliska@suse.cz>
1081
1082 PR ipa/81128
1083 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
1084 to a function declaration.
1085
63010089
ML
10862017-06-28 Martin Liska <mliska@suse.cz>
1087
1088 PR driver/79659
1089 * c.opt: Add IntegerRange to various options.
1090
3e2becc4
MP
10912017-06-26 Marek Polacek <polacek@redhat.com>
1092
1093 PR c/80116
1094 * c-common.h (warn_for_multistatement_macros): Declare.
1095 * c-warn.c: Include "c-family/c-indentation.h".
1096 (warn_for_multistatement_macros): New function.
1097 * c.opt (Wmultistatement-macros): New option.
1098 * c-indentation.c (guard_tinfo_to_string): No longer static.
1099 Change the parameter type to "enum rid". Handle RID_SWITCH.
1100 * c-indentation.h (guard_tinfo_to_string): Declare.
1101
2db9b7cd
MG
11022017-06-23 Marc Glisse <marc.glisse@inria.fr>
1103
1104 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
1105
c3684b7b
MS
11062017-06-15 Martin Sebor <msebor@redhat.com>
1107
1108 PR c++/80560
1109 * c.opt (-Wclass-memaccess): New option.
1110
e72c4afd
BK
11112017-06-14 Boris Kolpackov <boris@codesynthesis.com>
1112
1113 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
1114
8a516588
MP
11152017-06-13 Marek Polacek <polacek@redhat.com>
1116
1117 PR objc/80949
1118 * c-warn.c (do_warn_duplicated_branches): Return if any of the
1119 branches is null.
1120
45b2222a
ML
11212017-06-13 Martin Liska <mliska@suse.cz>
1122
1123 PR sanitize/78204
1124 * c-attribs.c (add_no_sanitize_value): New function.
1125 (handle_no_sanitize_attribute): Likewise.
1126 (handle_no_sanitize_address_attribute): Use the function.
1127 (handle_no_sanitize_thread_attribute): New function.
1128 (handle_no_address_safety_analysis_attribute): Use
1129 add_no_sanitize_value.
1130 (handle_no_sanitize_undefined_attribute): Likewise.
1131 * c-common.h: Declare new functions.
1132 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
1133 (ubsan_instrument_shift): Likewise.
1134 (ubsan_instrument_bounds): Likewise.
1135 (ubsan_maybe_instrument_array_ref): Likewise.
1136 (ubsan_maybe_instrument_reference_or_call): Likewise.
1137
a01f151f
JM
11382017-06-11 Jason Merrill <jason@redhat.com>
1139
1140 * c-ada-spec.c, c-pragma.c: Use id_equal.
1141
3de4ac6d
MP
11422017-06-04 Marek Polacek <polacek@redhat.com>
1143
1144 PR c/80919
1145 * c-format.c (matching_type_p): Return false if any of the types
1146 requires structural equality.
1147
2474f48f
MS
11482017-06-02 Martin Sebor <msebor@redhat.com>
1149
1150 PR c/80892
1151 * c-warn.c (conversion_warning): Use -Wconversion for integer
1152 conversion and -Wfloat-conversion for floating one.
1153
40ffd95f
BE
11542017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
1155
1156 * c.opt (Wsizeof-pointer-div): New warning option.
1157
3fa4634c
VR
11582017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
1159
1160 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
1161 (Wcatch-value=1): Enable by -Wall.
1162
f012c8ef
DM
11632017-05-30 David Malcolm <dmalcolm@redhat.com>
1164
1165 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
1166 format_chars.
1167 * c.opt (fdiagnostics-show-template-tree): New option.
1168 (felide-type): New option.
1169
63dbcd13
VR
11702017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
1171
1172 * c.opt (Wcatch-value=): New C++ warning flag.
1173
be136b5c
NS
11742017-05-24 Nathan Sidwell <nathan@acm.org>
1175
1176 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
1177 const casts to avoid warning.
1178
3cd211af
MS
11792017-05-24 Martin Sebor <msebor@redhat.com>
1180
1181 PR c/80731
1182 * c-common.h (unsafe_conversion_p): Add a function argument.
1183 * c-common.c (unsafe_conversion_p): Same.
1184 Add type names and values to diagnostics.
1185 (scalar_to_vector): Adjust.
1186 * c-warn.c (constant_expression_error): Add a function argument.
1187 Add type names and values to diagnostics.
1188 (conversion_warning): Add a function argument.
1189 Add type names and values to diagnostics.
1190 (warnings_for_convert_and_check): Same.
1191
1ff7be5a
JM
11922017-05-19 Jason Merrill <jason@redhat.com>
1193
1194 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
1195 enumerators.
1196
ff502317
BE
11972017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
1198
1199 * c-format.c (locus): Move out of function scope,
1200 add GTY attribute.
1201
2a8a8d7b
NS
12022017-05-19 Nathan Sidwell <nathan@acm.org>
1203
1204 * c-opts.c (class_dump_file, class_dump_flags): Delete.
1205 (c_common_parse_file): Remove class dump handling.
1206 (get_dump_info): Likewise.
1207
39aac208
RB
12082017-05-19 Richard Biener <rguenther@suse.de>
1209
1210 PR c++/80593
1211 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
1212 to alias-set zero memory.
1213
6ecd2339
BE
12142017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
1215
1216 * c-format.c (local_tree_type_node): Add GTY attribute.
1217
6574d78e
MP
12182017-05-18 Marek Polacek <polacek@redhat.com>
1219
1220 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
1221 (c_common_fixed_point_type_for_size): Likewise.
1222 (c_common_type_for_mode): Likewise.
1223 (shorten_compare): Likewise.
1224 (c_promoting_integer_type_p): Use false/true instead of 0/1.
1225 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
1226
e3455240
MP
12272017-05-18 Marek Polacek <polacek@redhat.com>
1228
1229 * c-common.c (self_promoting_args_p): Change the return type to bool.
1230 Use false/true instead of 0/1.
1231 * c-common.h (self_promoting_args_p): Update.
1232
3fa8871b
MP
12332017-05-17 Marek Polacek <polacek@redhat.com>
1234
1235 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
1236 * c-warn.c: Likewise.
1237
b42cc3ca
VV
12382017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
1239
1240 Implement new C++ intrinsics __is_assignable and __is_constructible.
1241 * c-common.c (__is_assignable, __is_constructible): New.
1242 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
1243
1a817418
ML
12442017-05-17 Martin Liska <mliska@suse.cz>
1245
1246 * c-common.h: Introduce dump_flags_t type and
1247 use it instead of int type.
1248 * c-gimplify.c (c_genericize): Likewise.
1249 * c-opts.c: Likewise.
1250
b2fa0a8b
MP
12512017-05-17 Marek Polacek <polacek@redhat.com>
1252
1253 * c-common.c (c_save_expr): Remove.
1254 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
1255 * c-common.h (c_save_expr): Remove declaration.
1256
31c2d57d
VR
12572017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
1258
1259 PR c/35441
1260 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
1261 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
1262 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
1263 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
1264 RDIV_EXPR.
1265 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
1266
684f84de
MP
12672017-05-09 Marek Polacek <polacek@redhat.com>
1268
1269 PR c/80525
1270 * c-warn.c (unwrap_c_maybe_const): New.
1271 (warn_logical_operator): Call it.
1272
641da50a
NS
12732017-05-09 Nathan Sidwell <nathan@acm.org>
1274
1275 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
1276 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
1277
631238ac
MS
12782017-05-08 Martin Sebor <msebor@redhat.com>
1279
1280 PR translation/80280
1281 * c-format.h (struct format_flag_spec): Add new member.
1282 (T89_T): New macro.
1283 * c-format.c (local_tree_type_node): New global.
1284 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
1285 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
1286 (strfmon_flag_specs): Likewise.
1287 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
1288 with distinct quoting properties.
1289 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
1290 (flag_chars_t::validate): Add argument and handle bad quoting.
1291 (check_format_info_main): Handle quoting problems.
1292 (init_dynamic_diag_info): Simplify.
1293
49f0c04c
JM
12942017-05-08 Jason Merrill <jason@redhat.com>
1295
1296 * c-opts.c (c_common_post_options): Update defaults for
1297 flag_abi_version and flag_abi_compat_version.
1298
56d35585
DM
12992017-05-05 David Malcolm <dmalcolm@redhat.com>
1300
1301 * c-common.c (c_cpp_error): Replace report_diagnostic
1302 with diagnostic_report_diagnostic.
1303
0f2c4a8f
MS
13042017-05-04 Martin Sebor <msebor@redhat.com>
1305
1306 PR translation/80280
1307 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
1308 (handle_weakref_attribute): Same.
1309
6fe63fb4
NS
13102017-05-03 Nathan Sidwell <nathan@acm.org>
1311
1312 Canonicalize canonical type hashing
1313 * c-common.c (complete_array_type): Use type_hash_canon.
1314
815d9cc6
XR
13152017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
1316
1317 PR c++/80038
1318 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
1319 prototype.
1320 (cilk_install_body_pedigree_operations): Likewise.
1321 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
1322 detatched.
1323 (cilk_gimplify_call_params_in_spawned_fn): Remove.
1324 (cilk_install_body_pedigree_operations): Likewise.
1325 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
1326 unwrapping.
1327
f8a36447
JJ
13282017-04-27 Jakub Jelinek <jakub@redhat.com>
1329
1330 PR c++/80534
1331 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
1332 flag on non-aggregate element types.
1333
7c145456
BE
13342017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
1335
1336 * c-common.c (c_type_hasher, type_hash_table): Remove.
1337 (c_common_get_alias_set): Remove unreachable code.
1338 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
1339
c3cbcd45
VR
13402017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
1341
1342 * c.opt (Wextra-semi): New C++ warning flag.
1343
8a59d466
JJ
13442017-04-20 Jakub Jelinek <jakub@redhat.com>
1345
1346 PR middle-end/80423
1347 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
1348
8487c9a5
JJ
13492017-04-18 Jakub Jelinek <jakub@redhat.com>
1350
1351 PR middle-end/79788
1352 PR middle-end/80375
1353 * c-common.c (c_common_type_for_mode): Don't handle
1354 widest_*_literal_type_node here.
1355 c_common_signed_or_unsigned_type): Likewise.
1356 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
1357 to *intTI_type_node or *intDI_type_node depending on whether
1358 TImode is supported by the target or not.
1359
3ee0fb02
ML
13602017-04-10 Martin Liska <mliska@suse.cz>
1361
1362 PR sanitizer/80350
1363 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
1364 doing an UBSAN check.
1365
5764ee3c
JW
13662017-04-03 Jonathan Wakely <jwakely@redhat.com>
1367
1368 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
1369
6f3af356
JJ
13702017-03-31 Jakub Jelinek <jakub@redhat.com>
1371
1372 PR c++/79572
1373 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
1374 tree *.
1375 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
1376 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
1377 REFERENCE_TYPE.
1378
f6a7a9d5
DM
13792017-03-31 David Malcolm <dmalcolm@redhat.com>
1380
1381 PR documentation/78732
1382 * c.opt (Wendif-labels): Fix description to refer to
1383 #else rather than #elif.
1384
af88f557
JJ
13852017-03-31 Jakub Jelinek <jakub@redhat.com>
1386
1387 PR libstdc++/80251
1388 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
1389 * c-common.c (c_common_reswords): Add __is_aggregate trait.
1390
a9e4a1a5
JJ
13912017-03-27 Jakub Jelinek <jakub@redhat.com>
1392
1393 PR middle-end/80162
1394 * c-common.c (c_common_mark_addressable_vec): Don't set
1395 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
1396
3f01b620
MS
13972017-03-21 Martin Sebor <msebor@redhat.com>
1398
1399 PR c++/79548
1400 * c-common.c (set_underlying_type): Mark type used only when
1401 original del is declared unused.
1402
2f6f187a
DM
14032017-03-10 David Malcolm <dmalcolm@redhat.com>
1404
1405 PR translation/79848
1406 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
1407 "%qs".
1408
a02fa805
DM
14092017-03-10 David Malcolm <dmalcolm@redhat.com>
1410
1411 PR c/79921
1412 * c-indentation.c (warn_for_misleading_indentation): Remove parens
1413 from inform's message, so that xgettext can locate it.
1414
822a132c
MP
14152017-03-09 Marek Polacek <polacek@redhat.com>
1416
1417 PR c++/79962
1418 PR c++/79984
1419 * c-attribs.c (handle_nonnull_attribute): Save the result of default
1420 conversion to the attribute list.
1421
bba81f1c
ML
14222017-03-09 Martin Liska <mliska@suse.cz>
1423
1424 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
1425
108154ff
JM
14262017-03-03 Jason Merrill <jason@redhat.com>
1427
1428 * c.opt (Wnoexcept-type): New.
1429
eb0e7c34
RB
14302017-03-02 Richard Biener <rguenther@suse.de>
1431
1432 PR c/79756
1433 * c-common.c (c_common_mark_addressable_vec): Look through
1434 C_MAYBE_CONST_EXPR.
1435
9453ba0a
ML
14362017-02-28 Martin Liska <mliska@suse.cz>
1437
1438 * c.opt: Replace space with tabular for options of <number>
1439 type.
1440
6a825afe
ML
14412017-02-28 Martin Liska <mliska@suse.cz>
1442
1443 * c.opt: Fix --help=option -Q for options which are of
1444 an enum type.
1445
4227c9ad
JJ
14462017-02-24 Jakub Jelinek <jakub@redhat.com>
1447
1448 PR c++/79588
1449 * c-common.c (check_function_restrict): New function.
1450 (check_function_arguments): Add FNDECL argument. Call
1451 check_function_restrict if -Wrestrict.
1452 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
1453 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
1454 * c-common.h (check_function_arguments): Add FNDECL argument.
1455 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
1456
59909673
EB
14572017-02-24 Eric Botcazou <ebotcazou@adacore.com>
1458
1459 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
1460 treatment of parameters with pointer-to-tagged type and tidy up.
1461 (print_ada_methods): Remove the special treatment of C++ static member
1462 functions.
1463
54dcd526
ML
14642017-02-22 Martin Liska <mliska@suse.cz>
1465
1466 * c.opt: Replace inequality signs with square brackets
1467 for -Wnornalized.
1468
00bc9de3
JJ
14692017-02-21 Jakub Jelinek <jakub@redhat.com>
1470
1471 PR c++/79641
1472 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
1473 preserve quals.
1474
97fcf744
JM
14752017-02-17 Joseph Myers <joseph@codesourcery.com>
1476
1477 * c-cppbuiltin.c (builtin_define_float_constants): Define
1478 __DECIMAL_DIG__ to the value for long double.
1479
c7545f1c
MP
14802017-02-15 Marek Polacek <polacek@redhat.com>
1481
1482 PR c/79515
1483 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
1484 conversion has occured.
1485
c2e84327
DM
14862017-01-24 David Malcolm <dmalcolm@redhat.com>
1487
1488 * c-common.c (c_common_reswords): Add "__RTL".
1489 * c-common.h (enum rid): Add RID_RTL.
1490
2ebd93e1
MP
14912017-01-20 Marek Polacek <polacek@redhat.com>
1492
1493 PR c/64279
1494 * c-common.h (do_warn_duplicated_branches_r): Declare.
1495 * c-gimplify.c (c_genericize): Walk the function tree calling
1496 do_warn_duplicated_branches_r.
1497 * c-warn.c (expr_from_macro_expansion_r): New.
1498 (do_warn_duplicated_branches): New.
1499 (do_warn_duplicated_branches_r): New.
1500 * c.opt (Wduplicated-branches): New option.
1501
0d80ab91
DM
15022017-01-17 David Malcolm <dmalcolm@redhat.com>
1503
1504 PR c++/71497
1505 * c-indentation.c (warn_for_misleading_indentation): Use the past
1506 subjunctive in the note.
1507
7f991c36
AH
15082017-01-17 Aldy Hernandez <aldyh@redhat.com>
1509
1510 PR c/79116
1511 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
1512 start type to integer_type.
1513
1c70261c
JJ
15142017-01-16 Jakub Jelinek <jakub@redhat.com>
1515
1516 PR driver/49726
1517 * c.opt (gen-decls): Add Driver flag.
1518
1ddca3f3
PC
15192017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
1520
1521 Revert:
1522 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
1523
1524 PR c++/71737
1525 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
1526
7d2f3f1d
PC
15272017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
1528
1529 PR c++/71737
1530 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
1531
bce6f760
MS
15322017-01-12 Martin Sebor <msebor@redhat.com>
1533
1534 (-Wformat-overflow): ...to this.
1535
bf5fbf46
MS
15362017-01-11 Martin Sebor <msebor@redhat.com>
1537
1538 PR c/78768
1539 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
1540 Also enable for LTO.
1541
e363df3f
JM
15422017-01-10 Jason Merrill <jason@redhat.com>
1543
1544 Implement P0195R2, C++17 variadic using.
1545 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
1546
bd2c6270
JJ
15472017-01-09 Jakub Jelinek <jakub@redhat.com>
1548
1549 PR translation/79019
1550 PR translation/79020
1551 * c.opt (Wnormalized=): Fix typo in description.
1552
efcc8d38
MS
15532017-01-08 Martin Sebor <msebor@redhat.com>
1554
1555 PR middle-end/77708
1556 * c.opt (-Wformat-truncation): New option.
1557
435f3f7a
AO
15582017-01-06 Alexandre Oliva <aoliva@redhat.com>
1559
1560 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
1561 value to unsigned short to fit in 4 hex digits without
1562 warnings.
1563
4e89adf9
EB
15642017-01-05 Eric Botcazou <ebotcazou@adacore.com>
1565
1566 * c.opt (fsso-struct): Add 'native' value.
1567
cd445b54
ML
15682017-01-05 Martin Liska <mliska@suse.cz>
1569
1570 PR pch/78970
1571 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
1572 header.
1573
a9342885
MP
15742017-01-04 Marek Polacek <polacek@redhat.com>
1575
1576 PR c++/64767
1577 * c.opt (Wpointer-compare): New option.
1578
fc73e60c
JJ
15792017-01-04 Jakub Jelinek <jakub@redhat.com>
1580
1581 PR driver/78957
1582 * c.opt (fsso-struct=): Add RejectNegative.
1583
cbe34bb5
JJ
15842017-01-01 Jakub Jelinek <jakub@redhat.com>
1585
1586 Update copyright years.
1587
d4a6c0ea
ML
15882016-12-29 Martin Liska <mliska@suse.cz>
1589
1590 PR c/78933
1591 * c.opt (strong-eval-order): Add RejectNegative keyword.
1592
67a5ad7c
JM
15932016-12-22 Jason Merrill <jason@redhat.com>
1594
1595 Implement P0522R0, matching of template template arguments.
1596 * c-cppbuiltin.c (c_cpp_builtins): Define
1597 __cpp_template_template_args.
1598
0dba7960
JJ
15992016-12-21 Jakub Jelinek <jakub@redhat.com>
1600
1601 PR bootstrap/78817
1602 * c-common.c (struct nonnull_arg_ctx): New type.
1603 (check_function_nonnull): Return bool instead of void. Use
1604 nonnull_arg_ctx as context rather than just location_t.
1605 (check_nonnull_arg): Adjust for the new context type, set
1606 warned_p to true if a warning has been diagnosed.
1607 (check_function_arguments): Return bool instead of void.
1608 * c-common.h (check_function_arguments): Adjust prototype.
1609
31bfc9b9
JM
16102016-12-21 Jason Merrill <jason@redhat.com>
1611
1612 * c.opt (-fnew-ttp-matching): New flag.
1613 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
1614
629b3d75
MJ
16152016-12-14 Martin Jambor <mjambor@suse.cz>
1616
1617 * c-omp.c: Include omp-general.h instead of omp-low.h.
1618 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
1619 name.
1620
474da67e
MS
16212016-12-14 Martin Sebor <msebor@redhat.com>
1622
1623 PR c/17308
1624 * c-common.c (check_nonnull_arg): Disable when optimization
1625 is enabled.
1626
fe366b87
MP
16272016-12-12 Marek Polacek <polacek@redhat.com>
1628
1629 PR c++/78647
1630 * c-common.c (attribute_fallthrough_p): Return false for
1631 error_mark_node.
1632
8bd9f164
MS
16332016-12-08 Martin Sebor <msebor@redhat.com>
1634
1635 PR c/78284
1636 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
1637
060162e0
MS
16382016-12-08 Martin Sebor <msebor@redhat.com>
1639
1640 PR c/78165
1d0cf89a
MS
1641 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
1642 suffix.
060162e0 1643
ee92e7ba
MS
16442016-12-07 Martin Sebor <msebor@redhat.com>
1645
1646 PR c/53562
1647 PR middle-end/77784
1648 PR middle-end/78149
1649 PR middle-end/78138
1650 * c.opt (-Wstringop-overflow): New option.
1651
84b0769e
MO
16522016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
1653
1654 * c-attribs.c (asan odr indicator): New attribute.
1655 (handle_asan_odr_indicator_attribute): New function.
1656
7fa6a965
PK
16572016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1658
1659 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
1660 ptrdiff_type_node;
1661
56d8ffc1
JG
16622016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
1663
1664 * c-common.c (excess_precision_mode_join): New.
1665 (c_ts18661_flt_eval_method): New.
1666 (c_c11_flt_eval_method): Likewise.
1667 (c_flt_eval_method): Likewise.
1668 * c-common.h (excess_precision_mode_join): New.
1669 (c_flt_eval_method): Likewise.
1670 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
1671 (cpp_iec_559_value): Call it.
1672 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
1673 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
1674 __FLT_EVAL_METHOD_TS_18661_3__.
1675
04f0fcf7
JG
16762016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
1677
1678 * c-opts.c (c_common_post_options): Add logic to handle the default
1679 case for -fpermitted-flt-eval-methods.
1680
fb2675cb
PB
16812016-11-23 Paolo Bonzini <bonzini@gnu.org>
1682
1683 * c.opt (Wexpansion-to-defined): New.
1684
ec1c5694
JJ
16852016-11-23 Jakub Jelinek <jakub@redhat.com>
1686
1687 PR target/78451
1688 * c-pragma.c (handle_pragma_target): Don't replace
1689 current_target_pragma, but chainon the new args to the current one.
1690
730c9e75
NS
16912016-11-22 Nathan Sidwell <nathan@acm.org>
1692
1693 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
cacd29be 1694 indentation and formatting.
730c9e75 1695
89990732
MS
16962016-11-21 Martin Sebor <msebor@redhat.com>
1697
1698 * c.opt (-fprintf-return-value): Enable by default.
1699
48330c93
BE
17002016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
1701
1702 PR c++/71973
1703 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
1704 * c-common.c (c_common_nodes_and_builtins): Initialize
1705 const_tm_ptr_type_node.
1706
0d939c95
MP
17072016-11-16 Marek Polacek <polacek@redhat.com>
1708
1709 PR c/78285
1710 * c-common.c (c_add_case_label): Turn error_at calls into inform.
1711
8e745a17
JJ
17122016-11-14 Jakub Jelinek <jakub@redhat.com>
1713
1714 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
1715
1ee62b92 17162016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
8e745a17
JJ
1717 Richard Biener <rguenther@suse.de>
1718
1719 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
1720 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
1721 * c.opt (fgimple): New option.
1ee62b92 1722
22b15758
UB
17232016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1724
1725 PR c/35503
1726 * c-common.h (warn_for_restrict): Declare.
1727 * c-warn.c: Include gcc-rich-location.h.
1728 (warn_for_restrict): New function.
1729 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
1730 (gcc_cdiag_char_table): Likewise.
1731 (gcc_cxxdiag_char_table): Likewise.
1732 * c.opt (Wrestrict): New option.
1733
4be719cd
EB
17342016-11-13 Eric Botcazou <ebotcazou@adacore.com>
1735
1736 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
1737 for nested types only if the type is a record or union and dump SLOC.
1738
4a826ca6
JM
17392016-11-09 Jason Merrill <jason@redhat.com>
1740
1741 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
1742
2e955d50
JJ
17432016-11-09 Jakub Jelinek <jakub@redhat.com>
1744
1745 * c-ubsan.c (ubsan_instrument_shift): Handle split
1746 -fsanitize=shift-base and -fsanitize=shift-exponent.
1747
51dc6603
JM
17482016-11-07 Jason Merrill <jason@redhat.com>
1749
1750 * c.opt (Wc++1z-compat): New.
1751 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
1752
6dc4a604
ML
17532016-11-07 Martin Liska <mliska@suse.cz>
1754
1755 * c-warn.c (warn_for_unused_label): Save all labels used
1756 in goto or in &label.
1757
b302001e
JM
17582016-11-03 Jason Merrill <jason@redhat.com>
1759
1760 * c-cppbuiltin.c (c_cpp_builtins): Correct
1761 __cpp_inheriting_constructors.
1762
31f7f784
JM
17632016-11-01 Jason Merrill <jason@redhat.com>
1764
2bc78e3c
JM
1765 * c-cppbuiltin.c (c_cpp_builtins): Update
1766 __cpp_inheriting_constructors.
1767
31f7f784
JM
1768 * c.opt (-fnew-inheriting-ctors): New.
1769 * c-opts.c: Default to on for ABI 11+.
1770
dcb466ec
JJ
17712016-10-31 Jakub Jelinek <jakub@redhat.com>
1772
1773 PR c++/77948
1774 * c.opt (fext-numeric-literals): Add Var and Init.
1775 * c-opts.c (c_common_handle_option): Don't clear
1776 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
1777 (c_common_post_options): Clear it here if not set
1778 explicitly.
1779
52e1b91e
AH
17802016-10-28 Aldy Hernandez <aldyh@redhat.com>
1781
1782 PR debug/77773
1783 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
1784 if NULL.
1785
e16f1cc7
JJ
17862016-10-25 Jakub Jelinek <jakub@redhat.com>
1787
1788 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
1789 * c-common.c (c_common_reswords): Add __builtin_launder.
1790
f8348061
BE
17912016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
1792
1793 * c-common.c (c_common_truthvalue_conversion): Warn for
1794 multiplications in boolean context. Fix the quoting of '<<' and '<'
1795 in the shift warning.
1796
eff89e01
BE
17972016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
1798
1799 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
1800
24bc7bf4
JM
18012016-10-20 Jason Merrill <jason@redhat.com>
1802
1803 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
1804
4c712374
BE
18052016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
1806
1807 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
1808 integer shift ops in boolean context.
1809
18102016-10-18 Aldy Hernandez <aldyh@redhat.com>
adc577c5
AH
1811
1812 * c.opt (Walloca): New.
1813 (Walloca-larger-than=): New.
1814 (Wvla-larger-than=): New.
1815
8fa18c06
MP
18162016-10-17 Marek Polacek <polacek@redhat.com>
1817
1818 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
1819 Return immediately when finding a match.
1820 (warn_tautological_cmp): Remove a boolean variable that is no longer
1821 needed.
1822
b12b1915
MP
18232016-10-17 Marek Polacek <polacek@redhat.com>
1824
1825 * c-attribs.c: New file.
1826 * c-common.c: Move attributes handling to c-attribs.c.
1827 (get_nonnull_operand): No longer static.
1828 * c-common.h: Move the declarations from c-attribs.c to its own section.
1829
2045acd9
JM
18302016-10-14 Jason Merrill <jason@redhat.com>
1831
1832 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
1833 and __cpp_deduction_guides.
1834
14a2c9aa
JM
18352016-10-13 Jason Merrill <jason@redhat.com>
1836
1837 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
1838
4d0cdd0c
TP
18392016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
1840
1841 * c-cppbuiltin.c: Include memmodel.h.
1842 * c-opts.c: Likewise.
1843 * c-pragma.c: Likewise.
1844 * c-warn.c: Likewise.
1845
70f6d5e1
JJ
18462016-10-12 Jakub Jelinek <jakub@redhat.com>
1847
1848 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
1849 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
1850 * c-opts.c (sanitize_cpp_opts): Initialize
1851 cpp_opts->cpp_warn_implicit_fallthrough.
1852
78f61294
MP
18532016-10-11 Marek Polacek <polacek@redhat.com>
1854
1855 * c-common.c (warning_candidate_p): Change the return type to bool
1856 and return true/false instead of 1/0.
1857 (vector_mode_valid_p): Likewise.
1858
038b5cc0
MP
18592016-10-11 Marek Polacek <polacek@redhat.com>
1860
1861 * c-common.c (fold_for_warn): No longer static.
1862 (bool_promoted_to_int_p): Likewise.
1863 (c_common_get_narrower): Likewise.
1864 (constant_expression_warning): Move to c-warn.c.
1865 (constant_expression_error): Likewise.
1866 (overflow_warning): Likewise.
1867 (warn_logical_operator): Likewise.
1868 (find_array_ref_with_const_idx_r): Likewise.
1869 (warn_tautological_cmp): Likewise.
1870 (expr_has_boolean_operands_p): Likewise.
1871 (warn_logical_not_parentheses): Likewise.
1872 (warn_if_unused_value): Likewise.
1873 (strict_aliasing_warning): Likewise.
1874 (sizeof_pointer_memaccess_warning): Likewise.
1875 (check_main_parameter_types): Likewise.
1876 (conversion_warning): Likewise.
1877 (warnings_for_convert_and_check): Likewise.
1878 (match_case_to_enum_1): Likewise.
1879 (match_case_to_enum): Likewise.
1880 (c_do_switch_warnings): Likewise.
1881 (warn_for_omitted_condop): Likewise.
1882 (readonly_error): Likewise.
1883 (lvalue_error): Likewise.
1884 (invalid_indirection_error): Likewise.
1885 (warn_array_subscript_with_type_char): Likewise.
1886 (warn_about_parentheses): Likewise.
1887 (warn_for_unused_label): Likewise.
1888 (warn_for_div_by_zero): Likewise.
1889 (warn_for_memset): Likewise.
1890 (warn_for_sign_compare): Likewise.
1891 (do_warn_double_promotion): Likewise.
1892 (do_warn_unused_parameter): Likewise.
1893 (record_locally_defined_typedef): Likewise.
1894 (maybe_record_typedef_use): Likewise.
1895 (maybe_warn_unused_local_typedefs): Likewise.
1896 (maybe_warn_bool_compare): Likewise.
1897 (maybe_warn_shift_overflow): Likewise.
1898 (warn_duplicated_cond_add_or_warn): Likewise.
1899 (diagnose_mismatched_attributes): Likewise.
1900 * c-common.h: Move the declarations from c-warn.c to its own section.
1901 * c-warn.c: New file.
1902
627be19f
JM
19032016-10-08 Jason Merrill <jason@redhat.com>
1904
1905 * c-common.c (c_common_truthvalue_conversion): Don't distribute
1906 into COND_EXPR in C++.
1907
7bad794a
JJ
19082016-10-08 Jakub Jelinek <jakub@redhat.com>
1909
1910 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
1911 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
1912 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
1913
be845b04
JJ
19142016-10-07 Jakub Jelinek <jakub@redhat.com>
1915
1916 Implement LWG2296 helper intrinsic
1917 * c-common.h (enum rid): Add RID_ADDRESSOF.
1918 * c-common.c (c_common_reswords): Add __builtin_addressof.
1919
c09c4992
BE
19202016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
1921
1922 PR c++/77700
1923 * c-common.c (c_common_truthvalue_conversion): Warn also for
1924 suspicious enum values in boolean context.
1925
342cfb3e
JJ
19262016-10-06 Jakub Jelinek <jakub@redhat.com>
1927
1928 Implement P0258R2 - helper for C++17
1929 std::has_unique_object_representations trait
1930 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
1931 * c-common.c (c_common_reswords): Add
1932 __has_unique_object_representations.
1933
2e69f143
JJ
19342016-10-05 Jakub Jelinek <jakub@redhat.com>
1935
1936 PR sanitizer/66343
1937 * c-ubsan.c (ubsan_instrument_return): Don't call
1938 initialize_sanitizer_builtins here.
1939
700fff34
BE
19402016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
1941
1942 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
1943 conditional expression in boolean context when only one arm is
1944 non-boolean.
1945
9563bfcd
JJ
19462016-10-05 Jakub Jelinek <jakub@redhat.com>
1947
04a32443
JJ
1948 PR sanitizer/77823
1949 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
1950 is not integral.
1951
9563bfcd
JJ
1952 * c-common.c (c_common_reswords): Update comment for C++11.
1953
f1644724
JM
19542016-10-04 Jason Merrill <jason@redhat.com>
1955
1956 * c-common.c (make_tree_vector_from_ctor): New.
1957 * c-common.h: Declare it.
1958
5a79befb
JJ
19592016-10-04 Jakub Jelinek <jakub@redhat.com>
1960
1961 * c-cppbuiltin.c (c_cpp_builtins): Don't define
1962 __LIBGCC_JCR_SECTION_NAME__.
1963
1633d3b9
BE
19642016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
1965
1966 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
1967 left shift in boolean context.
1968
a2c6e7f2
JJ
19692016-09-29 Jakub Jelinek <jakub@redhat.com>
1970
1971 Implement P0001R1 - C++17 removal of register storage class specifier
1972 * c.opt (Wregister): New warning.
1973 * c-opts.c (c_common_post_options): Enable -Wregister by
1974 default for C++17.
1975
75304c87
JG
19762016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
1977
1978 * c-opts.c (c_common_post_options): Remove special case for
1979 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
1980 in C++.
1981
bbfac6da
JJ
19822016-09-27 Jakub Jelinek <jakub@redhat.com>
1983
6e39060a
JJ
1984 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
1985 -std=c++1z.
1986
bbfac6da
JJ
1987 * c-ada-spec.c (print_ada_declaration): Remove break after return.
1988
e73cf9a2
TP
19892016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
1990
1991 * c-common.c: Include memmodel.h.
1992
c6147dc4
MP
19932016-09-26 Marek Polacek <polacek@redhat.com>
1994
1995 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
1996
81fea426
MP
19972016-09-26 Marek Polacek <polacek@redhat.com>
1998
1999 PR c/7652
2000 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
2001 (handle_fallthrough_attribute): New function.
2002 (attribute_fallthrough_p): New function.
2003 * c-common.h (attribute_fallthrough_p): Declare.
2004
9a2300e9
MP
20052016-09-24 Marek Polacek <polacek@redhat.com>
2006
2007 PR c/77490
2008 * c.opt (Wbool-operation): New.
2009
a09e9e35
BE
20102016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
2011
2012 * c-common.c (c_common_truthvalue_conversion): Inhibit
2013 Wint-in-bool-context warning with from_macro_definition_at.
2014 Mention the expression will always evaluate to true.
2015
d43b4ccc
MS
20162016-09-21 Martin Sebor <msebor@redhat.com>
2017
2018 PR bootstrap/77676
2019 * c.opt (fprintf-return-value): Temporarily initialize to zero
2020 to unblock bootstrap failures.
2021
2e1c20b1
JJ
20222016-09-21 Jakub Jelinek <jakub@redhat.com>
2023
2024 PR c++/77651
2025 * c.opt (Waligned-new=): Add RejectNegative.
2026 (faligned-new=): Likewise. Spelling fix - change
2027 aligned_new_threshhold to aligned_new_threshold.
2028 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
2029 to aligned_new_threshold.
2030
88d0c3f0
MS
20312016-09-20 Martin Sebor <msebor@redhat.com>
2032
2033 PR middle-end/49905
2034 * c.opt: Add -Wformat-length and -fprintf-return-value.
2035
144a96e4
BE
20362016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
2037
2038 PR c++/77434
2039 * c.opt (Wint-in-bool-context): New warning.
2040 * c-common.c (c_common_truthvalue_conversion): Warn on integer
2041 constants in boolean context.
2042
63012d9a
JM
20432016-09-19 Joseph Myers <joseph@codesourcery.com>
2044
2045 * c-common.c (max_align_t_align): Also consider alignment of
2046 float128_type_node.
2047
931388ce
JM
20482016-09-15 Jason Merrill <jason@redhat.com>
2049
2050 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
2051 DECL_EXTERNAL.
2052
38711381
JM
20532016-09-14 Jason Merrill <jason@redhat.com>
2054
2055 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
2056 limit FIELD_DECL, either.
2057
e51fbec3
MP
20582016-09-14 Marek Polacek <polacek@redhat.com>
2059
2060 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
2061 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
2062 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
2063
254830ba
DM
20642016-09-13 David Malcolm <dmalcolm@redhat.com>
2065
2066 * c-common.c (warn_logical_not_parentheses): Replace
2067 rich_location::add_fixit_insert calls with add_fixit_insert_before
2068 and add_fixit_insert_after, eliminating the "next_loc" calculation.
2069
42763690
JM
20702016-09-13 Jason Merrill <jason@redhat.com>
2071 Tom de Vries <tom@codesourcery.com>
2072
2073 PR c++/77427
2074 * c-common.c (set_underlying_type): Don't treat array as builtin type.
2075
9453eee9
JM
20762016-09-13 Jason Merrill <jason@redhat.com>
2077
2078 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
2079 limit types at all.
2080
e96809e3
JM
20812016-09-12 Jason Merrill <jason@redhat.com>
2082
2083 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
2084 bit/byte confusion, allow large alignment for types.
2085
54dcdb88
BE
20862016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
2087
2088 PR c++/77496
2089 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
2090
d1463eb9
DM
20912016-09-12 David Malcolm <dmalcolm@redhat.com>
2092
2093 PR c/72858
2094 * c-format.c (argument_parser::check_argument_type): Add params
2095 "type_start" and "conversion_char". Use the former to generate
2096 offset_to_type_start and pass it and conversion_char to
2097 check_format_types.
2098 (check_format_info_main): Capture the start of the type
2099 information as "type_start", and pass it an format_char
2100 to arg_parser.check_argument_type.
2101 (check_format_types): Provide an example in the leading comment.
2102 Add params "offset_to_type_start" and "conversion_char"; pass
2103 them to format_type_warning calls.
2104 (test_get_modifier_for_format_len): Likewise.
2105 (matching_type_p): New function.
2106 (get_format_for_type): Add param "conversion_char" and move
2107 implementation into...
2108 (get_format_for_type_1): ...new function, called twice.
2109 Use new function matching_type_p rather than checking for
2110 TYPE_CANONICAL equality.
2111 (get_corrected_substring): New function.
2112 (format_type_warning): Provide an example in the leading comment.
2113 Add params "offset_to_type_start" and "conversion_char". Replace
2114 call to get_format_for_type with call to get_corrected_substring
2115 and move rejection of hints for widths/precisions there.
2116 (assert_format_for_type_streq): Add param "conversion_char".
2117 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
2118 (test_get_format_for_type_printf): Add conversion chars to the
2119 tests, adding coverage for various combinations of integer
2120 vs double conversions, and for preserving octal and hexadecimal
2121 conversions.
2122 (test_get_format_for_type_scanf): Add conversion chars to the
2123 tests.
2124
5b28efbb
TV
21252016-09-10 Tom de Vries <tom@codesourcery.com>
2126
2127 PR C/71602
2128 * c-common.c (build_va_arg): Handle more strict
2129 targetm.canonical_va_list_type. Replace first argument type error with
2130 assert.
2131
3f0177e7
MS
21322016-09-09 Martin Sebor <msebor@redhat.com>
2133
2134 PR c/77520
2135 PR c/77521
2136 * c-format.c (argument_parser::find_format_char_info): Use %qc
2137 format directive unconditionally.
2138
af63ba4b
JM
21392016-09-09 Jason Merrill <jason@redhat.com>
2140
2141 Implement C++17 new of over-aligned types.
2142 * c.opt: Add -faligned-new and -Waligned-new.
2143 * c-common.c (max_align_t_align): Split out from...
2144 (cxx_fundamental_alignment_p): ...here.
2145 * c-common.h: Declare it.
2146 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
2147
c65248cb
JM
21482016-09-09 Joseph Myers <joseph@codesourcery.com>
2149
2150 * c-cppbuiltin.c (builtin_define_type_width): New function.
2151 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
2152 macros.
2153
e5106e27
DM
21542016-09-07 David Malcolm <dmalcolm@redhat.com>
2155
2156 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
2157 a POINTER_TYPE.
2158 (substring_loc::get_location): Move to substring-locations.c,
2159 keeping implementation as...
2160 (c_get_substring_location): New function, from the above, reworked
2161 to use accessors rather than member lookup.
2162 * c-common.h (class substring_loc): Move to substring-locations.h,
2163 replacing with a forward decl.
2164 (c_get_substring_location): New decl.
2165 * c-format.c: Include "substring-locations.h".
2166 (format_warning_va): Move to substring-locations.c.
2167 (format_warning_at_substring): Likewise.
2168
a42e7952
MS
21692016-09-06 Martin Sebor <msebor@redhat.com>
2170
2171 PR c/77336
2172 * c-format.c (check_function_format): Avoid issuing warnings for
2173 functions unless they call format functions with non-constant
2174 format strings.
2175
b772a565
RB
21762016-09-06 Richard Biener <rguenther@suse.de>
2177
2178 PR c/77450
2179 * c-common.c (c_common_mark_addressable_vec): Handle
2180 COMPOUND_LITERAL_EXPR.
2181
25ff5dd3
MP
21822016-09-05 Marek Polacek <polacek@redhat.com>
2183
2184 PR c/77423
2185 * c-common.c (bool_promoted_to_int_p): New function.
2186 (expr_has_boolean_operands_p): New function.
2187 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
2188 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
2189
21234eb5
TV
21902016-09-04 Tom de Vries <tom@codesourcery.com>
2191
2192 revert:
2193 2016-08-29 Tom de Vries <tom@codesourcery.com>
2194
2195 * c-common.c (build_va_arg): Replace first argument type error
2196 with assert.
2197
9dc5773f
JJ
21982016-09-02 Jakub Jelinek <jakub@redhat.com>
2199
2200 PR c/65467
2201 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
2202 (c_finish_omp_for): Reject _Atomic qualified iterators.
2203
22042016-09-01 Martin Sebor <msebor@redhat.com>
3d7b83b6
MS
2205
2206 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
2207 size to guarantee it fits the output of the formatted function
2208 regardless of its arguments.
2209
295844f6
MP
22102016-09-01 Marek Polacek <polacek@redhat.com>
2211
2212 PR c/7652
2213 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
2214 FALLTHRU comments.
2215
3d06b6f2
MP
22162016-08-29 Marek Polacek <polacek@redhat.com>
2217
2218 PR c/77292
2219 * c-common.c (warn_logical_not_parentheses): Don't warn for
2220 a comparison or a logical operator.
2221
34cedad5
TV
22222016-08-29 Tom de Vries <tom@codesourcery.com>
2223
2224 * c-common.c (build_va_arg): Fix type comparison assert.
2225
f162d717
TV
22262016-08-29 Tom de Vries <tom@codesourcery.com>
2227
2228 * c-common.c (build_va_arg): Replace first argument type error
2229 with assert.
2230
ba9bbd6f
TV
22312016-08-29 Tom de Vries <tom@codesourcery.com>
2232
2233 PR c/77398
2234 * c-common.c (build_va_arg): Add first argument error. Build va_arg
2235 with error_mark_node as va_list instead of with illegal va_list.
2236
ebef225f
MP
22372016-08-25 Marek Polacek <polacek@redhat.com>
2238 David Malcolm <dmalcolm@redhat.com>
2239
2240 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
2241 * c-common.h (warn_logical_not_parentheses): Update declaration.
2242
b00e6e75
MP
22432016-08-22 Marek Polacek <polacek@redhat.com>
2244
2245 PR c++/77321
2246 * c-common.c (warn_for_memset): Check type for null.
2247
6dc198e3
JM
22482016-08-22 Joseph Myers <joseph@codesourcery.com>
2249
14ec014e 2250 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
6dc198e3
JM
2251 _FloatNx types for suffixes for built-in functions.
2252
c65699ef
JM
22532016-08-19 Joseph Myers <joseph@codesourcery.com>
2254
2255 PR c/32187
2256 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
2257 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
2258 (RID_FLOAT128X): New enum rid values.
2259 (CASE_RID_FLOATN_NX): New macro.
2260 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
2261 keywords.
2262 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
2263 corresponding complex types.
2264 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
2265 _FloatNx and corresponding complex types.
2266 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
2267 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
2268 and _FloatNx types for the widest type for determining
2269 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
2270 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
2271 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
2272 and _FloatNx types.
2273 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
2274 constants.
2275 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
2276 _FloatNx types.
2277
cc015f3a
DM
22782016-08-18 David Malcolm <dmalcolm@redhat.com>
2279
2280 * c-opts.c (c_diagnostic_finalizer): Update for change to
2281 diagnostic_show_locus.
2282
cb18fd07
DM
22832016-08-18 David Malcolm <dmalcolm@redhat.com>
2284
2285 * c-common.c: Include "spellcheck.h".
2286 (cb_get_suggestion): New function.
2287 * c-common.h (cb_get_suggestion): New decl.
2288 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
2289 cb_get_suggestion.
2290
a76989dc
MP
22912016-08-18 Marek Polacek <polacek@redhat.com>
2292
2293 PR c/71514
2294 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
2295 and pointer-to-VLA.
2296
65e736c0
DM
22972016-08-16 David Malcolm <dmalcolm@redhat.com>
2298
2299 PR c/72857
2300 * c-common.c (substring_loc::get_range): Rename to...
2301 (substring_loc::get_location): ...this, converting param from a
2302 source_range * to a location_t *. Call
2303 get_source_location_for_substring rather than
2304 get_source_range_for_substring, and pass in m_caret_idx.
2305 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
2306 (substring_loc::get_range): Replace with...
2307 (substring_loc::get_location): ...this.
2308 (substring_loc::set_caret_index): New method.
2309 (substring_loc): Add field m_caret_idx.
2310 * c-format.c (format_warning_va): Update for above changes.
2311 Rename local "substring_loc" to "fmt_substring_loc" to avoid
2312 clashing with type name.
2313 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
2314 (check_argument_type): Likewise.
2315 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
2316 Use a copy when emitting warnings, setting the caret index from TYPE.
2317
7e1dde14 23182016-08-16 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 2319 Arnaud Charlet <charlet@adacore.com>
7e1dde14
EB
2320
2321 * c-ada-spec.c (dump_number): New function.
2322 (handle_escape_character): Likewise.
2323 (print_ada_macros): Add handling of constant integers and strings.
2324
191816a3
MP
23252016-08-12 Marek Polacek <polacek@redhat.com>
2326
2327 PR c/7652
2328 * c-common.c (scalar_to_vector): Adjust fall through comment.
2329 * c-opts.c (c_common_handle_option): Likewise.
2330 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
2331 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
2332 fall through comment.
2333 * cilk.c (extract_free_variables): Add FALLTHRU.
2334
452df4a4
JM
23352016-08-10 Jason Merrill <jason@redhat.com>
2336
2337 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
2338
f3365c12
JM
23392016-08-09 Jason Merrill <jason@redhat.com>
2340
2341 * c-common.c (c_common_attribute_table): vector_size affects type
2342 identity.
2343
f0bc3323
MP
23442016-08-09 Marek Polacek <polacek@redhat.com>
2345
2346 PR c/7652
2347 * c-ada-spec.c (dump_generic_ada_node): Add return.
2348
98e5a19a
JM
23492016-08-09 Jason Merrill <jason@redhat.com>
2350
2351 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
2352 C++17 constexpr lambdas.
2353
895aa8e1
DM
23542016-08-08 David Malcolm <dmalcolm@redhat.com>
2355
2356 PR c/64955
2357 * c-common.h (selftest::c_format_c_tests): New declaration.
2358 (selftest::run_c_tests): New declaration.
2359 * c-format.c: Include "selftest.h.
2360 (format_warning_va): Add param "corrected_substring" and use
2361 it to add a replacement fix-it hint.
2362 (format_warning_at_substring): Likewise.
2363 (format_warning_at_char): Update for new param of
2364 format_warning_va.
2365 (argument_parser::check_argument_type): Pass "fki" to
2366 check_format_types.
2367 (check_format_types): Add param "fki" and pass it to
2368 format_type_warning.
2369 (deref_n_times): New function.
2370 (get_modifier_for_format_len): New function.
2371 (selftest::test_get_modifier_for_format_len): New function.
2372 (get_format_for_type): New function.
2373 (format_type_warning): Add param "fki" and use it to attempt
2374 to provide hints for argument types when calling
2375 format_warning_at_substring.
2376 (selftest::get_info): New function.
2377 (selftest::assert_format_for_type_streq): New function.
2378 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
2379 (selftest::test_get_format_for_type_printf): New function.
2380 (selftest::test_get_format_for_type_scanf): New function.
2381 (selftest::c_format_c_tests): New function.
2382
e52ed3fe
DM
23832016-08-08 David Malcolm <dmalcolm@redhat.com>
2384
2385 PR c/52952
2386 * c-format.c: Include "diagnostic.h".
2387 (location_column_from_byte_offset): Delete.
2388 (location_from_offset): Delete.
2389 (format_warning_va): New function.
2390 (format_warning_at_substring): New function.
2391 (format_warning_at_char): New function.
2392 (check_format_arg): Capture location of format_tree and pass to
2393 check_format_info_main.
2394 (argument_parser): Add fields "start_of_this_format" and
2395 "format_string_cst".
2396 (flag_chars_t::validate): Add param "format_string_cst". Convert
2397 warning_at call using location_from_offset to call to
2398 format_warning_at_char.
2399 (argument_parser::argument_parser): Add param "format_string_cst_"
2400 and use use it to initialize field "format_string_cst".
2401 Initialize new field "start_of_this_format".
2402 (argument_parser::read_format_flags): Convert warning_at call
2403 using location_from_offset to a call to format_warning_at_char.
2404 (argument_parser::read_any_format_left_precision): Likewise.
2405 (argument_parser::read_any_format_precision): Likewise.
2406 (argument_parser::read_any_other_modifier): Likewise.
2407 (argument_parser::find_format_char_info): Likewise, in three places.
2408 (argument_parser::parse_any_scan_set): Likewise, in one place.
2409 (argument_parser::handle_conversions): Likewise, in two places.
2410 (argument_parser::check_argument_type): Add param "fmt_param_loc"
2411 and use it to make a substring_loc. Pass the latter to
2412 check_format_types.
2413 (check_format_info_main): Add params "fmt_param_loc" and
2414 "format_string_cst". Convert warning_at calls using
2415 location_from_offset to calls to format_warning_at_char. Pass the
2416 new params to the arg_parser ctor. Pass "format_string_cst" to
2417 flag_chars.validate. Pass "fmt_param_loc" to
2418 arg_parser.check_argument_type.
2419 (check_format_types): Convert first param from a location_t
2420 to a const substring_loc & and rename to "fmt_loc". Attempt
2421 to extract the range of the relevant parameter and pass it
2422 to format_type_warning.
2423 (format_type_warning): Convert first param from a location_t
2424 to a const substring_loc & and rename to "fmt_loc". Add
2425 params "param_range" and "type". Replace calls to warning_at
2426 with calls to format_warning_at_substring.
2427
1c4d457e
DM
24282016-08-08 David Malcolm <dmalcolm@redhat.com>
2429
2430 * c-format.c (class flag_chars_t): New class.
2431 (struct length_modifier): New struct.
2432 (class argument_parser): New class.
2433 (flag_chars_t::flag_chars_t): New ctor.
2434 (flag_chars_t::has_char_p): New method.
2435 (flag_chars_t::add_char): New method.
2436 (flag_chars_t::validate): New method.
2437 (flag_chars_t::get_alloc_flag): New method.
2438 (flag_chars_t::assignment_suppression_p): New method.
2439 (argument_parser::argument_parser): New ctor.
2440 (argument_parser::read_any_dollar): New method.
2441 (argument_parser::read_format_flags): New method.
2442 (argument_parser::read_any_format_width): New method.
2443 (argument_parser::read_any_format_left_precision): New method.
2444 (argument_parser::read_any_format_precision): New method.
2445 (argument_parser::handle_alloc_chars): New method.
2446 (argument_parser::read_any_length_modifier): New method.
2447 (argument_parser::read_any_other_modifier): New method.
2448 (argument_parser::find_format_char_info): New method.
2449 (argument_parser::validate_flag_pairs): New method.
2450 (argument_parser::give_y2k_warnings): New method.
2451 (argument_parser::parse_any_scan_set): New method.
2452 (argument_parser::handle_conversions): New method.
2453 (argument_parser::check_argument_type): New method.
2454 (check_format_info_main): Introduce classes argument_parser
2455 and flag_chars_t, moving the code within the loop into methods
2456 of these classes. Make various locals "const".
2457
88fa5555
DM
24582016-08-05 David Malcolm <dmalcolm@redhat.com>
2459
2460 * c-common.c: Include "substring-locations.h".
2461 (get_cpp_ttype_from_string_type): New function.
2462 (g_string_concat_db): New global.
2463 (substring_loc::get_range): New method.
2464 * c-common.h (g_string_concat_db): New declaration.
2465 (class substring_loc): New class.
2466 * c-lex.c (lex_string): When concatenating strings, capture the
2467 locations of all tokens using a new obstack, and record the
2468 concatenation locations within g_string_concat_db.
2469 * c-opts.c (c_common_init_options): Construct g_string_concat_db
2470 on the ggc-heap.
2471
78169471
MP
24722016-07-29 Marek Polacek <polacek@redhat.com>
2473
638fc14f
MP
2474 PR c/71926
2475 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
2476 parentheses warning.
2477
78169471
MP
2478 PR c/71574
2479 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
2480
1225d6b1
ML
24812016-07-28 Martin Liska <mliska@suse.cz>
2482
2483 PR gcov-profile/68025
2484 * c-common.c (handle_no_profile_instrument_function_attribute):
2485
ec1e2a40
BE
24862016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
2487
2488 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
2489 BITS_PER_UNIT_LOG.
2490
5ec2cd9f
JM
24912016-07-25 Jason Merrill <jason@redhat.com>
2492
2493 PR c++/65970
2494 * c.opt (fconstexpr-loop-limit): New.
2495
9dc5773f 24962016-07-22 Martin Sebor <msebor@redhat.com>
2e6b45af
MS
2497
2498 PR c++/71675
2499 * c-common.c (resolve_overloaded_builtin): Avoid converting
2500 __atomic_compare_exchange_n return type to that of what its
2501 first argument points to.
2502
e3fe09c1
UB
25032016-07-22 Uros Bizjak <ubizjak@gmail.com>
2504
2505 * c-common.c: Use HOST_WIDE_INT_M1U instead of
2506 ~(unsigned HOST_WIDE_INT) 0.
2507
bc91c436
ML
25082016-07-22 Martin Liska <mliska@suse.cz>
2509
2510 PR gcov-profile/69028
2511 PR gcov-profile/62047
2512 * cilk.c (create_cilk_helper_decl): Set location of a new decl
2513 to the current_function_decl.
2514
451dcc66
JM
25152016-07-21 Jason Merrill <jason@redhat.com>
2516
2517 PR c++/65168
2518 * c-common.c (c_common_truthvalue_conversion): Check
2519 c_inhibit_evaluation_warnings for warning about address of
2520 reference.
2521
de6a69ee
DM
25222016-07-20 David Malcolm <dmalcolm@redhat.com>
2523
2524 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
2525 const char *.
2526
d022c55a
JM
25272016-07-15 Jason Merrill <jason@redhat.com>
2528
2529 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
2530
ddbbcb19
JJ
25312016-07-15 Jakub Jelinek <jakub@redhat.com>
2532
2533 PR c/71858
2534 * c-common.h (enum lookup_name_fuzzy_kind): Add
2535 FUZZY_LOOKUP_FUNCTION_NAME.
2536
d0cf395a
JM
25372016-07-08 Jason Merrill <jason@redhat.com>
2538
2539 P0145: Refining Expression Order for C++.
2540 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
2541 * c-opts.c: Adjust.
2542
98d44e93
MT
25432016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
2544
2545 PR c++/71214
2546 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
2547
f9d8d994
TS
25482016-06-29 Thomas Schwinge <thomas@codesourcery.com>
2549
2550 * c-pragma.h (enum pragma_kind): Rename
2551 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
2552 users.
2553
4aa83879
RB
25542016-06-29 Richard Biener <rguenther@suse.de>
2555
2556 PR middle-end/71002
2557 * c-common.c (c_common_get_alias_set): Remove union type punning case.
2558
a25bd9e6
JM
25592016-06-24 Jason Merrill <jason@redhat.com>
2560
2561 P0145R2: Refining Expression Order for C++.
2562 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
2563 MODIFY_EXPR.
2564
a86451b9
JJ
25652016-06-24 Jakub Jelinek <jakub@redhat.com>
2566
2567 * c-common.c (check_builtin_function_arguments): Require last
2568 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
2569 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
2570 if the last argument is pointer to enumerated or boolean type.
2571
1a4f11c8
DM
25722016-06-22 David Malcolm <dmalcolm@redhat.com>
2573
2574 PR c/70339
2575 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
2576 (lookup_name_fuzzy): New prototype.
2577
fe55692c
JDA
25782016-06-21 John David Anglin <danglin@gcc.gnu.org>
2579
2580 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
2581
4eb24e01
JM
25822016-06-14 Jason Merrill <jason@redhat.com>
2583
2584 P0145R2: Refining Expression Order for C++.
2585 * c.opt (fargs-in-order): New.
2586 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
2587
ef7cf206
JJ
25882016-06-13 Jakub Jelinek <jakub@redhat.com>
2589
0dda258b
JJ
2590 PR sanitizer/71498
2591 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
2592 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
2593
ef7cf206
JJ
2594 PR preprocessor/71183
2595 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
2596 to cb_get_source_date_epoch.
2597
50b15873
JJ
25982016-06-10 Jakub Jelinek <jakub@redhat.com>
2599
2600 PR c/68657
2601 * c.opt (Wpsabi): Add Warning flag.
2602
4d926e34
MS
26032016-06-10 Martin Sebor <msebor@redhat.com>
2604
2605 PR c/71392
14ec014e 2606 * c-common.c (handle_nonnull_attribute): Accept
4d926e34
MS
2607 the nonnull attribute in type-generic builtins.
2608
e01b4e16
MS
26092016-06-09 Martin Sebor <msebor@redhat.com>
2610
2611 PR c/70883
2612 * c-common.c (builtin_function_validate_nargs): Make text of error
2613 message consistent with others like it.
2614
44a845ca
MS
26152016-06-08 Martin Sebor <msebor@redhat.com>
2616 Jakub Jelinek <jakub@redhat.com>
2617
2618 PR c++/70507
2619 PR c/68120
2620 * c-common.c (check_builtin_function_arguments): Handle
2621 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
2622
a80a7051
RB
26232016-06-08 Richard Biener <rguenther@suse.de>
2624
2625 * c-common.c (parse_optimize_options): Improve diagnostic messages.
2626
bfd67b47
RB
26272016-06-07 Richard Biener <rguenther@suse.de>
2628
2629 PR c/61564
2630 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
2631 options and warn about others.
2632
15c98b2e
ES
26332016-06-01 Eduard Sanou <dhole@openmailbox.org>
2634
2635 * c-common.c (get_source_date_epoch): Rename to
2636 cb_get_source_date_epoch.
2637 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
2638 message when the parsing fails. Use error_at instead of fatal_error.
2639 * c-common.h (get_source_date_epoch): Rename to
2640 cb_get_source_date_epoch.
2641 * c-common.h (cb_get_source_date_epoch): Prototype.
2642 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
2643 * c-common.h (c_omp_region_type): Remove trailing comma.
2644 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
2645 * c-lex.c (c_lex_with_flags): Remove initialization of
2646 pfile->source_date_epoch.
2647
00631022
JJ
26482016-05-30 Jakub Jelinek <jakub@redhat.com>
2649
2650 PR c++/71349
2651 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
2652 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
2653 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
2654 instead of C_OMP_CLAUSE_SPLIT_FOR.
2655
f17a223d
RB
26562016-05-24 Richard Biener <rguenther@suse.de>
2657
2658 PR middle-end/70434
2659 PR c/69504
2660 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
2661 (convert_vector_to_array_for_subscript): ... this.
2662 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
2663 VIEW_CONVERT_EXPR to an array type. Rename to ...
2664 (convert_vector_to_array_for_subscript): ... this.
2665
4f2e1536
MP
26662016-05-12 Marek Polacek <polacek@redhat.com>
2667
2668 PR c/70756
2669 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
2670 size_in_bytes and pass LOC to it.
2671
d6e83a8d
MM
26722016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
2673
2674 PR c/43651
2675 * c.opt (Wduplicate-decl-specifier): New option.
2676
5c3a10fb
MP
26772016-05-11 Marek Polacek <polacek@redhat.com>
2678
2679 PR c++/71024
2680 * c-common.c (diagnose_mismatched_attributes): New function.
2681 * c-common.h (diagnose_mismatched_attributes): Declare.
2682
deef7113
MP
26832016-05-04 Marek Polacek <polacek@redhat.com>
2684
2685 * c.opt (Wdangling-else): New option.
2686
79ce98bc
MP
26872016-05-03 Marek Polacek <polacek@redhat.com>
2688
2689 PR c/70859
2690 * c-common.c (builtin_function_validate_nargs): Add location
2691 parameter. Use it.
2692 (check_builtin_function_arguments): Add location and arguments
2693 parameters. Use them.
2694 * c-common.h (check_builtin_function_arguments): Update declaration.
2695
381cdae4
RB
26962016-05-03 Richard Biener <rguenther@suse.de>
2697
2698 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
2699 allow call args to gimplify to SSA names.
2700
1d793c34
MP
27012016-05-03 Marek Polacek <polacek@redhat.com>
2702
2703 * c-common.h (enum c_omp_region_type): Remove stray comma.
2704
77886428
CP
27052016-05-02 Cesar Philippidis <cesar@codesourcery.com>
2706
2707 * c-common.h (enum c_omp_region_type): Define.
2708
697e0b28
RS
27092016-05-02 Richard Sandiford <richard.sandiford@arm.com>
2710
2711 * c-common.c (shorten_compare): Use wi::to_wide.
2712
e7ff0319
CP
27132016-04-29 Cesar Philippidis <cesar@codesourcery.com>
2714
2715 PR middle-end/70626
2716 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
2717 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
2718 reduction clauses in acc parallel loops.
2719
2fff3db8
MP
27202016-04-29 Marek Polacek <polacek@redhat.com>
2721
2722 PR c/70852
2723 * c-common.c (warn_for_memset): Check domain before accessing it.
2724
509063eb
DV
27252016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
2726
2727 PR/69089
2728 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
2729 "aligned" attribute.
2730
b632761d
JM
27312016-04-28 Jason Merrill <jason@redhat.com>
2732
2733 * c-lex.c (c_common_has_attribute): Handle nodiscard.
2734
174f6622
ES
27352016-04-28 Eduard Sanou <dhole@openmailbox.org>
2736 Matthias Klose <doko@debian.org>
2737
2738 * c-common.c (get_source_date_epoch): New function, gets the environment
7365279f 2739 variable SOURCE_DATE_EPOCH and parses it as long long with error
174f6622
ES
2740 handling.
2741 * c-common.h (get_source_date_epoch): Prototype.
2742 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
2743
6bc2bb18
RB
27442015-04-27 Ryan Burn <contact@rnburn.com>
2745
2746 PR c++/69024
2747 PR c++/68997
2748 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
2749 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
2750 external linkage.
2751 (cilk_detect_and_unwrap): Corresponding changes.
2752 (extract_free_variables): Don't extract free variables from
2753 AGGR_INIT_EXPR slot.
2754 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
2755 (cilk_recognize_spawn): Likewise.
2756
c1e1f433
BS
27572016-04-27 Bernd Schmidt <bschmidt@redhat.com>
2758
2759 * c.opt (Wmemset-elt-size): New option.
2760 * c-common.c (warn_for_memset): New function.
2761 * c-common.h (warn_for_memset): Declare.
2762
d067e05f
JM
27632016-04-25 Jason Merrill <jason@redhat.com>
2764
2765 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
2766 No longer static.
2767 * c-common.h: Declare it.
2768 * c-lex.c (c_common_has_attribute): Add maybe_unused.
2769
9aa36ae5
JM
27702016-04-22 Jason Merrill <jason@redhat.com>
2771
2772 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
2773
477d4906
IV
27742016-04-20 Ilya Verbin <ilya.verbin@intel.com>
2775
2776 PR c++/69363
2777 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
2778 * c-common.h (c_finish_cilk_clauses): Remove declaration.
2779
fe37c7af
MM
27802016-04-18 Michael Matz <matz@suse.de>
2781
2782 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
2783 and SET_DECL_ALIGN.
2784
23f2660f
EB
27852016-04-17 Eric Botcazou <ebotcazou@adacore.com>
2786
2787 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
2788 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
2789 to incomplete types.
2790 (dump_nested_type): Remove redundant tests and tidy up.
2791 (print_ada_declaration): Also set TREE_VISITED on the declaration of
2792 a type which is the typedef of an original type.
2793
1e77281b
MP
27942016-04-15 Marek Polacek <polacek@redhat.com>
2795
2796 PR c/70651
2797 * c-common.c (build_va_arg): Change two asserts into errors and return
2798 error_mark_node.
2799
b3a77f21
MP
28002016-04-13 Marek Polacek <polacek@redhat.com>
2801
2802 PR c++/70639
2803 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
2804 for switch statements, too.
2805
322b8466
JM
28062016-03-28 Jason Merrill <jason@redhat.com>
2807
2808 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
2809
fbdb6baf
MP
28102016-03-23 Marek Polacek <polacek@redhat.com>
2811
2812 PR c++/69884
2813 * c.opt (Wignored-attributes): New option.
2814
5c240f4d
DM
28152016-03-22 David Malcolm <dmalcolm@redhat.com>
2816
2817 PR c/69993
2818 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
2819 diagnostic text, reversing the order of the warning and note so
2820 that they appear in source order.
2821
14ba7b28
MP
28222016-03-17 Marek Polacek <polacek@redhat.com>
2823
2824 PR c/69407
2825 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
2826 operations.
2827
08a1cadc
JM
28282016-03-14 Jason Merrill <jason@redhat.com>
2829
2aaeea19
JM
2830 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
2831
08a1cadc
JM
2832 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
2833
c06d25bb
RB
28342016-03-09 Richard Biener <rguenther@suse.de>
2835
2836 PR c/70143
2837 * c-common.c (strict_aliasing_warning): Add back
2838 alias_sets_conflict_p check.
2839
80aac5c8
JM
28402016-03-08 Jason Merrill <jason@redhat.com>
2841
2842 * c-opts.c (set_std_cxx1z): Don't enable concepts.
2843
64b23c13
DM
28442016-03-04 David Malcolm <dmalcolm@redhat.com>
2845
2846 PR c/68187
2847 * c-indentation.c (get_visual_column): Move code to determine next
2848 tab stop to...
2849 (next_tab_stop): ...this new function.
2850 (line_contains_hash_if): Delete function.
2851 (detect_preprocessor_logic): Delete function.
2852 (get_first_nws_vis_column): New function.
2853 (detect_intervening_unindent): New function.
2854 (should_warn_for_misleading_indentation): Replace call to
2855 detect_preprocessor_logic with a call to
2856 detect_intervening_unindent.
2857
729526f5
DM
28582016-03-04 David Malcolm <dmalcolm@redhat.com>
2859
2860 PR c/68187
2861 * c-indentation.c (should_warn_for_misleading_indentation): When
2862 suppressing warnings about cases where the guard and body are on
2863 the same column, only use the first non-whitespace column in place
2864 of the guard token column when dealing with "else" clauses.
2865 When rejecting aligned BODY and NEXT, loosen the requirement
2866 from equality with the first non-whitespace of guard to simply
2867 that they not be indented relative to it.
2868
e9a35493
RB
28692016-03-04 Richard Biener <rguenther@suse.de>
2870
2871 PR c++/70054
2872 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
2873 instead of alias_sets_conflict_p.
2874
1be56bc5
MP
28752016-03-01 Marek Polacek <polacek@redhat.com>
2876
2877 PR c++/69795
2878 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
2879 any DECL.
2880
35886f0b
MS
28812016-02-22 Martin Sebor <msebor@redhat.com>
2882
2883 PR middle-end/69780
2884 * c-common.c (check_builtin_function_arguments): Validate and
2885 reject invalid arguments to __builtin_alloca_with_align.
2886
4246c8da
MW
28872016-02-20 Mark Wielaard <mjw@redhat.com>
2888
2889 PR c/28901
2890 * c.opt (Wunused-const-variable): Turn into Alias for...
2891 (Wunused-const-variable=): New option.
2892
268be88c
BE
28932016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
2894
2895 PR c++/69865
2896 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
2897 here...
2898 (c_common_init_options): ...to here.
2899 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
2900
871b3f47
JJ
29012016-02-19 Jakub Jelinek <jakub@redhat.com>
2902
2903 PR c++/69826
2904 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
2905 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
2906 flag_preprocess_only.
2907
bf14eba2
JJ
29082016-02-16 Jakub Jelinek <jakub@redhat.com>
2909
2910 PR c/69835
2911 * c.opt (Wnonnull-compare): Enable for -Wall.
2912
ba6b3795
JJ
29132016-02-15 Jakub Jelinek <jakub@redhat.com>
2914
2915 PR c++/69797
2916 * c-common.c (sync_resolve_size): Diagnose too few arguments
2917 even when params is non-NULL empty vector.
2918
a011cd92
BS
29192016-02-08 Bernd Schmidt <bschmidt@redhat.com>
2920
2921 PR target/60410
2922 * c.opt (fshort-double): Remove.
2923
46cb9332
MS
29242016-02-05 Martin Sebor <msebor@redhat.com>
2925
2926 PR c++/69662
2927 * c.opt (Warning options): Update -Wplacement-new to take
2928 an optional argument.
2929
e1b81f2b
JJ
29302016-02-01 Jakub Jelinek <jakub@redhat.com>
2931
2932 PR preprocessor/69543
2933 PR c/69558
2934 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
2935 instead of loc to control_warning_option.
2936
b6adbb9f
NS
29372016-02-01 Nathan Sidwell <nathan@codesourcery.com>
2938
2939 * c.opt (fopenacc-dim=): New option.
2940
5d70666e
RB
29412016-01-27 Ryan Burn <contact@rnburn.com>
2942
2943 PR cilkplus/69267
2944 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
2945 gimplify_arg. Removed superfluous post_p argument.
2946 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
2947 superfluous post_p argument.
2948 * c-gimplify.c (c_gimplify_expr): Likewise.
2949
01e1dea3
DM
29502016-01-26 David Malcolm <dmalcolm@redhat.com>
2951
2952 PR other/69006
2953 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
2954 pp_newline_and_flush with pp_flush.
2955
9f04a53e
MS
29562016-01-20 Martin Sebor <msebor@redhat.com>
2957
2958 PR c/69405
2959 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
2960 an incompatible argument when the argument isn't a valid tree node.
2961
7f26f7df
JM
29622016-01-18 Jason Merrill <jason@redhat.com>
2963
2964 PR c++/68767
2965 * c-common.c (check_function_arguments_recurse): Fold the whole
2966 COND_EXPR, not just the condition.
2967
f62bf092
TV
29682016-01-18 Tom de Vries <tom@codesourcery.com>
2969
2970 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
2971 classify as loop clause.
2972
e0a575ff
JJ
29732016-01-15 Jakub Jelinek <jakub@redhat.com>
2974
2975 PR bootstrap/68271
2976 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
2977 C++ FE no longer has limit on number of pragmas.
2978
29792015-01-14 Ryan Burn <contact@rnburn.com>
b6e3db06
RB
2980
2981 PR c++/69048
2982 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
c47eaca6 2983 to add missing cleanup point.
b6e3db06 2984
c7df95d8
DM
29852016-01-14 David Malcolm <dmalcolm@redhat.com>
2986
2987 PR c++/68819
2988 * c-indentation.c (get_visual_column): Add location_t param.
2989 Handle the column number being zero by effectively disabling the
2990 warning, with an "inform".
2991 (should_warn_for_misleading_indentation): Add location_t argument
2992 for all uses of get_visual_column.
2993
21efdd80
PP
29942016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
2995
2996 PR c++/69029
2997 * c-indentation.c (should_warn_for_misleading_indentation):
2998 Don't warn about do-while statements.
2999
7a127fa7
MS
30002016-01-07 Martin Sebor <msebor@redhat.com>
3001
3002 PR c/68966
3003 * c-common.c (sync_resolve_size): Reject first argument when it's
3004 a pointer to _Bool.
3005
c589e975
DM
30062016-01-05 David Malcolm <dmalcolm@redhat.com>
3007
3008 PR c/69122
3009 * c-indentation.c (get_visual_column): Remove default argument.
3010 (should_warn_for_misleading_indentation): For the multiline case,
3011 update call to get_visual_column for next_stmt_exploc so that it
3012 captures the location of the first non-whitespace character in the
3013 relevant line. Don't issue warnings if there is non-whitespace
3014 before the next statement.
3015
818ab71a
JJ
30162016-01-04 Jakub Jelinek <jakub@redhat.com>
3017
3018 Update copyright years.
3019
745e411d
DM
30202015-12-21 David Malcolm <dmalcolm@redhat.com>
3021
3022 * c-common.c (binary_op_error): Convert first param from
3023 location_t to rich_location * and use it when emitting an error.
3024 * c-common.h (binary_op_error): Convert first param from
3025 location_t to rich_location *.
3026
de67c4c3
DM
30272015-12-16 David Malcolm <dmalcolm@redhat.com>
3028
3029 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
3030 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
3031
4a38b02b
IV
30322015-12-15 Ilya Verbin <ilya.verbin@intel.com>
3033
3034 * c-common.c (c_common_attribute_table): Handle "omp declare target
3035 link" attribute.
3036
54d62f51
JJ
30372015-12-14 Jakub Jelinek <jakub@redhat.com>
3038
3039 PR c/68833
3040 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
3041
8d4227c8
TB
30422014-12-12 Tobias Burnus <burnus@net-b.de>
3043
3044 PR fortran/68815
3045 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
3046 specifiers (%d, %i,%u and %c).
3047
f6069ccc
DM
30482015-12-10 David Malcolm <dmalcolm@redhat.com>
3049
3050 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
3051
63bbf46d
JJ
30522015-12-08 Jakub Jelinek <jakub@redhat.com>
3053
3054 PR c/48088
3055 PR c/68657
3056 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
3057 * c-pragma.c (handle_pragma_diagnostic): Adjust
3058 control_warning_option caller.
3059
f79520bb
DM
30602015-12-07 David Malcolm <dmalcolm@redhat.com>
3061
3062 * c-common.c (c_cpp_error): Update for change to
3063 rich_location::set_range.
3064
b3d5bc62
JJ
30652015-12-04 Paolo Bonzini <bonzini@gnu.org>
3066
3067 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
3068 shifting 1 out of the sign bit.
3069
30702015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
3071
3072 * c-common.c (c_common_attribute_table[]): Update max arguments
3073 count for "simd" attribute.
3074 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
3075
6eb4a537
JJ
30762015-12-03 Jakub Jelinek <jakub@redhat.com>
3077
3078 PR preprocessor/57580
3079 * c-ppoutput.c (print): Change printed field to bool.
3080 Move src_file last for smaller padding.
3081 (init_pp_output): Set print.printed to false instead of 0.
3082 (scan_translation_unit): Fix up formatting. Set print.printed
3083 to true after printing something other than newline.
3084 (scan_translation_unit_trad): Set print.printed to true instead of 1.
3085 (maybe_print_line_1): Set print.printed to false instead of 0.
3086 (print_line_1): Likewise.
3087 (do_line_change): Set print.printed to true instead of 1.
3088 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
3089 dump_macro): Set print.printed to false after printing newline.
3090
4250754e
JM
30912015-12-02 Jason Merrill <jason@redhat.com>
3092
f479b43d
JM
3093 * c-common.c (fold_for_warn): New.
3094 (warn_logical_operator, warn_tautological_cmp)
3095 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
3096
4250754e
JM
3097 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
3098 (c_fully_fold_internal, decl_constant_value_for_optimization):
3099 Move to c/c-fold.c.
3100 * c-common.h: Don't declare decl_constant_value_for_optimization.
3101
e9e32ee6
JM
31022015-12-02 Joseph Myers <joseph@codesourcery.com>
3103
3104 PR c/68162
3105 * c-common.h (c_build_qualified_type): Add extra default
3106 arguments.
3107
37d5ad46
JB
31082015-12-01 Julian Brown <julian@codesourcery.com>
3109 Cesar Philippidis <cesar@codesourcery.com>
3110 James Norris <James_Norris@mentor.com>
3111
3112 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
3113 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
3114 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
3115
f07862c7
EB
31162015-11-30 Eric Botcazou <ebotcazou@adacore.com>
3117
3118 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
3119 (decl_sloc_common): Delete and move bulk of processing to...
3120 (decl_sloc): ...here.
3121 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
3122 (dump_ada_double_name): Remove S parameter and compute the suffix.
3123 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
3124 element type and deal with an anonymous one.
3125 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
3126 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
3127 and remove reference to QUAL_UNION_TYPE.
3128 (dump_nested_types): Make 2 passes on the fields and move bulk to...
3129 (dump_nested_type): ...here. New function extracted from above.
3130 Generate a full declaration for anonymous element type of arrays.
3131 (print_ada_declaration): Really skip anonymous declarations. Remove
3132 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
3133 Clean up processing of declarations of array types and objects.
3134 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
3135 Remove obsolete code and tidy up.
3136
75c8aac3
JH
31372015-11-29 Jan Hubicka <hubicka@ucw.cz>
3138
3139 PR c/67581
3140 * c-common.c (handle_transparent_union_attribute): Update
3141 also type variants.
3142
b58d3df2
ML
31432015-11-27 Martin Liska <mliska@suse.cz>
3144
3145 PR c++/68312
3146 * array-notation-common.c (cilkplus_extract_an_triplets):
3147 Release vector of vectors.
3148 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
3149
89a01fcf
EB
31502015-11-26 Eric Botcazou <ebotcazou@adacore.com>
3151
3152 PR c++/68527
3153 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
3154 (print_ada_struct_decl): Likewise.
3155
cc5c5226
IZ
31562015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
3157
3158 PR c++/68001
3159 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
3160 * cilk.c (recognize_spawn): Determine location in a more precise
3161 way.
3162
269adb9d
JM
31632015-11-19 Jason Merrill <jason@redhat.com>
3164
3165 * c-common.c (shorten_compare): But look through macros from
3166 system headers.
3167
d0eccfcd
JM
31682015-11-18 Jason Merrill <jason@redhat.com>
3169
3170 * c-common.c (shorten_compare): Don't -Wtype-limits if the
3171 non-constant operand comes from a macro.
3172
3e44547c
JM
31732015-11-17 Jason Merrill <jason@redhat.com>
3174
3175 PR bootstrap/68346
3176 * c-common.c (warn_tautological_cmp): Fold before checking for
3177 constants.
3178
0f62c7a0
MP
31792015-11-16 Marek Polacek <polacek@redhat.com>
3180
3181 PR c++/68362
3182 * c-common.c (check_case_bounds): Fold low and high cases.
3183
a868811e
MP
31842015-11-16 Marek Polacek <polacek@redhat.com>
3185
3186 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
3187 * c-common.c (c_common_get_alias_set): Likewise.
3188 (handle_visibility_attribute): Likewise.
3189
fff77217
KY
31902015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
3191
3192 * c-common.c (handle_simd_attribute): New.
3193 (struct attribute_spec): Add entry for "simd".
3194 (handle_simd_attribute): New.
3195
269e63b7
KT
31962015-11-13 Kai Tietz <ktietz70@googlemail.com>
3197
3198 * c-lex.c (interpret_float): Use fold_convert.
3199
ebedc9a3
DM
32002015-11-13 David Malcolm <dmalcolm@redhat.com>
3201
3202 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
3203 and store it on the result.
3204 * c-opts.c (c_common_init_options): Set
3205 global_dc->colorize_source_p.
3206
6e232ba4
JN
32072015-11-12 James Norris <jnorris@codesourcery.com>
3208 Joseph Myers <joseph@codesourcery.com>
3209
7365279f 3210 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
6e232ba4
JN
3211 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
3212 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
3213 PRAGMA_OACC_CLAUSE_LINK.
3214
e78bede6
MP
32152015-11-11 Marek Polacek <polacek@redhat.com>
3216
3217 PR c/68107
3218 PR c++/68266
3219 * c-common.c (valid_array_size_p): New function.
3220 * c-common.h (valid_array_size_p): Declare.
3221
3f8257db 32222015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4ac93c7c
DH
3223
3224 PR bootstrap/68271
3225 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
3226
69f293c9
AM
32272015-11-11 Andrew MacLeod <amacleod@redhat.com>
3228
3229 * array-notation-common.c: Remove unused header files.
3230 * c-ada-spec.c: Likewise.
3231 * c-cilkplus.c: Likewise.
3232 * c-common.c: Likewise.
3233 * c-cppbuiltin.c: Likewise.
3234 * c-dump.c: Likewise.
3235 * c-format.c: Likewise.
3236 * c-gimplify.c: Likewise.
3237 * c-indentation.c: Likewise.
3238 * c-lex.c: Likewise.
3239 * c-omp.c: Likewise.
3240 * c-opts.c: Likewise.
3241 * c-pch.c: Likewise.
3242 * c-ppoutput.c: Likewise.
3243 * c-pragma.c: Likewise.
3244 * c-pretty-print.c: Likewise.
3245 * c-semantics.c: Likewise.
3246 * c-ubsan.c: Likewise.
3247 * cilk.c: Likewise.
3248 * stub-objc.c: Likewise.
3249
3a40d81d
NS
32502015-11-09 Thomas Schwinge <thomas@codesourcery.com>
3251 Cesar Philippidis <cesar@codesourcery.com>
3252 James Norris <jnorris@codesourcery.com>
3253 Julian Brown <julian@codesourcery.com>
3254 Nathan Sidwell <nathan@codesourcery.com>
3255
3256 * c-pragma.c (oacc_pragmas): Add "routine".
3257 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
3258
ee45a32d
EB
32592015-11-08 Eric Botcazou <ebotcazou@adacore.com>
3260
3261 * c-common.c (c_common_attributes): Add scalar_storage_order.
3262 (handle_scalar_storage_order_attribute): New function.
3263 * c-pragma.c (global_sso): New variable.
3264 (maybe_apply_pragma_scalar_storage_order): New function.
3265 (handle_pragma_scalar_storage_order): Likewise.
3266 (init_pragma): Register scalar_storage_order.
3267 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
3268 * c.opt (Wscalar-storage-order): New warning.
3269 (fsso-struct=): New option.
3270
eb11eb15
MS
32712015-11-08 Martin Sebor <msebor@redhat.com>
3272
3273 * c.opt (Wplacement-new): Add a period to the end of a sentence.
3274
0aad0198
RS
32752015-11-07 Richard Sandiford <richard.sandiford@arm.com>
3276
3277 * c-common.c: Don't undef DEF_BUILTIN.
3278
8a645150
DM
32792015-11-06 David Malcolm <dmalcolm@redhat.com>
3280
3281 * c-common.c (c_cpp_error): Convert parameter from location_t to
3282 rich_location *. Eliminate the "column_override" parameter and
3283 the call to diagnostic_override_column.
3284 Update the "done_lexing" clause to set range 0
3285 on the rich_location, rather than overwriting a location_t.
3286 * c-common.h (c_cpp_error): Convert parameter from location_t to
3287 rich_location *. Eliminate the "column_override" parameter.
3288
7a5e4956
CP
32892015-11-05 Cesar Philippidis <cesar@codesourcery.com>
3290 Thomas Schwinge <thomas@codesourcery.com>
3291 James Norris <jnorris@codesourcery.com>
3292
3293 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
3294 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
3295 clauses with parallel and kernels and loops.
3296 * c-pragma.h (enum pragma_omp_clause): Add entries for
3297 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
3298 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
3299 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
3300 INDEPENDENT,SEQ}.
3301 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
3302
e2f5cc96
MS
33032015-11-05 Martin Sebor <msebor@redhat.com>
3304
3305 PR c++/67942
3306 * c.opt (-Wplacement-new): New option.
3307
e01d41e5
JJ
33082015-11-05 Jakub Jelinek <jakub@redhat.com>
3309
3310 * c-common.h (c_finish_omp_atomic): Add TEST argument.
3311 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
3312 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
3313 save_expr or create_tmp_var* if TEST is true.
3314 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
3315 Don't call add_stmt here.
3316 (struct c_omp_check_loop_iv_data): New type.
3317 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
3318 c_omp_check_loop_iv_exprs): New functions.
3319 (c_omp_split_clauses): Adjust for lastprivate being allowed on
3320 distribute.
3321 (c_omp_declare_simd_clauses_to_numbers): Change
3322 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
3323 (c_omp_declare_simd_clauses_to_decls): Similarly change those
3324 from numbers to PARM_DECLs.
3325
595278be
MM
33262015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
3327
3328 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
3329 flag_checking.
3330
3f8257db 33312015-11-03 Bernd Schmidt <bschmidt@redhat.com>
c85158de
MS
3332
3333 PR c++-common/67882
b3d5bc62
JJ
3334 * c-common.h (fold_offsetof_1): Add argument.
3335 * c-common.c (fold_offsetof_1): Diagnose more invalid
c85158de
MS
3336 offsetof expressions that reference elements past the end of
3337 an array.
3338
4bf9e5a8
TS
33392015-11-03 Thomas Schwinge <thomas@codesourcery.com>
3340 Chung-Lin Tang <cltang@codesourcery.com>
3341
3342 * c-pragma.c (oacc_pragmas): Add "atomic".
3343 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
3344
3b1661a9
ES
33452015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
3346
3347 * c-common.c (handle_target_clones_attribute): New.
3348 (c_common_attribute_table): Add handle_target_clones_attribute.
3349 (handle_always_inline_attribute): Add check on target_clones attribute.
3350 (handle_target_attribute): Ditto.
3351
2adfab87
AM
33522015-10-29 Andrew MacLeod <amacleod@redhat.com>
3353
3354 * array-notation-common.c: Reorder #include's and remove duplicates.
3355 * c-ada-spec.c: Likewise.
3356 * c-cilkplus.c: Likewise.
3357 * c-common.c: Likewise.
3358 * c-cppbuiltin.c: Likewise.
3359 * c-dump.c: Likewise.
3360 * c-format.c: Likewise.
3361 * c-gimplify.c: Likewise.
3362 * c-indentation.c: Likewise.
3363 * c-lex.c: Likewise.
3364 * c-omp.c: Likewise.
3365 * c-opts.c: Likewise.
3366 * c-pch.c: Likewise.
3367 * c-ppoutput.c: Likewise.
3368 * c-pragma.c: Likewise.
3369 * c-pretty-print.c: Likewise.
3370 * c-semantics.c: Likewise.
3371 * c-ubsan.c: Likewise.
3372 * cilk.c: Likewise.
3373 * stub-objc.c: Likewise.
3374
d90ec4f2
JM
33752015-10-28 Jason Merrill <jason@redhat.com>
3376
3377 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
3378
88bae6f4
TS
33792015-10-27 Thomas Schwinge <thomas@codesourcery.com>
3380 James Norris <jnorris@codesourcery.com>
3381 Cesar Philippidis <cesar@codesourcery.com>
3382
3383 PR c/64765
3384 PR c/64880
3385 * c-common.h (c_oacc_split_loop_clauses): Declare function.
3386 * c-omp.c (c_oacc_split_loop_clauses): New function.
3387
b1726d6c
MS
33882015-10-21 Martin Sebor <msebor@redhat.com>
3389
3390 PR driver/68043
3391 * c.opt: End each sentence that describes an option with a period.
3392
fa60eeb9
MP
33932015-10-20 Marek Polacek <polacek@redhat.com>
3394
3395 * array-notation-common.c (is_cilkplus_vector_p): Define.
3396 * c-common.h (is_cilkplus_vector_p): Declare.
3397
95979049
MP
33982015-10-20 Marek Polacek <polacek@redhat.com>
3399
3400 * c.opt (std=gnu++11): Do not describe as experimental.
3401 (std=gnu++14): Likewise.
3402
2a9fb712
JM
34032015-10-19 Jason Merrill <jason@redhat.com>
3404
3405 * c-cppbuiltin.c (c_cpp_builtins): Define
3406 __cpp_nontype_template_args.
3407
13b380a3
JM
34082015-10-19 Jason Merrill <jason@redhat.com>
3409
3410 * c-cppbuiltin.c (c_cpp_builtins): Define
3411 __cpp_enumerator_attributes, __cpp_fold_expressions,
3412 __cpp_unicode_characters.
3413
d9a6bd32
JJ
34142015-10-13 Jakub Jelinek <jakub@redhat.com>
3415 Aldy Hernandez <aldyh@redhat.com>
3416
3417 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
3418 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
3419 (c_define_builtins): Likewise.
3420 * c-common.h (enum c_omp_clause_split): Add
3421 C_OMP_CLAUSE_SPLIT_TASKLOOP.
3422 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
3423 (c_finish_omp_for): Add ORIG_DECLV argument.
3424 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
3425 201511 instead of 201307.
3426 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
3427 OMP_CRITICAL_CLAUSES to it.
3428 (c_finish_omp_ordered): Add CLAUSES argument, set
3429 OMP_ORDERED_CLAUSES to it.
3430 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
3431 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
3432 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
3433 constructs and new OpenMP 4.5 clauses. Clear
3434 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
3435 verification code.
3436 * c-pragma.c (omp_pragmas_simd): Add taskloop.
3437 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
3438 (enum pragma_omp_clause): Add
3439 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
3440 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
3441
624d31fe
RS
34422015-10-05 Richard Sandiford <richard.sandiford@arm.com>
3443
3444 * c-lex.c (interpret_float): Use real_equal instead of
3445 REAL_VALUES_EQUAL.
3446
b8fd7909
JM
34472015-10-04 Jason Merrill <jason@redhat.com>
3448
3449 Implement N4514, C++ Extensions for Transactional Memory.
3450 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
3451 (c_common_attribute_table): Add transaction_safe_dynamic.
3452 transaction_safe now affects type identity.
3453 (handle_tm_attribute): Handle transaction_safe_dynamic.
3454 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
3455 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
3456 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
3457 (D_TRANSMEM): New.
3458 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
3459 * c-pretty-print.c (pp_c_attributes_display): Don't print
3460 transaction_safe in C++.
3461
12651878
MP
34622015-10-02 Marek Polacek <polacek@redhat.com>
3463
3464 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
3465
3e3b8d63
MP
34662015-10-02 Marek Polacek <polacek@redhat.com>
3467
3468 PR c/64249
3469 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
3470 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
3471 * c.opt (Wduplicated-cond): New option.
3472
0d1a8f75
JM
34732015-10-01 Joseph Myers <joseph@codesourcery.com>
3474
3475 * c.opt (std=c11): Do not describe as experimental.
3476 (std=gnu11): Likewise.
3477 (std=iso9899:2011): Likewise.
3478
3e32ee19
NS
34792015-09-28 Nathan Sidwell <nathan@codesourcery.com>
3480
3481 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
3482 (DEF_FUNCTION_TYPE_VAR_11): Delete.
3483
974348ee
MP
34842015-09-25 Marek Polacek <polacek@redhat.com>
3485
3486 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
3487 (ubsan_instrument_shift): Likewise.
3488
15dbc1a6
MP
34892015-09-25 Marek Polacek <polacek@redhat.com>
3490
3491 PR sanitizer/64906
3492 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
3493
6b95d7cc
PP
34942015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
3495
3496 * c-indentation.c (should_warn_for_misleading_indentation):
3497 Compare next_stmt_vis_column with guard_line_first_nws instead
3498 of with guard_line_vis_column.
3499
c1822f9c
MLI
35002015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
3501
3502 PR c/49654
3503 PR c/49655
3504 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
3505 options and options not valid for the current language.
3506
d5398058
PP
35072015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
3508
3509 * c-indentation.c (should_warn_for_misleading_indentation):
3510 Float out and consolidate the calls to get_visual_column that
3511 are passed guard_exploc as an argument. Compare
3512 next_stmt_vis_column with guard_line_first_nws instead of with
3513 body_line_first_nws.
3514
6b333269
NS
35152015-09-22 Nathan Sidwell <nathan@codesourcery.com>
3516
3517 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
3518 Wnamespaces): New C++ warnings.
3519
a75f1574
JM
35202015-09-22 Jason Merrill <jason@redhat.com>
3521
3522 * c-common.h (abi_compat_version_crosses): New.
3523 (warn_abi_version): Declare.
3524 * c-common.c: Define it.
3525 * c-opts.c (c_common_post_options): Handle it.
3526 flag_abi_compat_version defaults to 8.
3527
bdaaa8b7
VV
35282015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
3529
3530 Complete the implementation of N4230, Nested namespace definition.
3531 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
3532 __cpp_nested_namespace_definitions.
3533
eaa797e8
MLI
35342015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
3535
3536 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
3537
c4914de6
MLI
35382015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
3539
3540 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
3541 when warning.
3542 * c-pragma.h (pragma_lex): Add optional loc argument.
3543
fcb87c50
MM
35442015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
3545
3546 * c-format.c (check_format_arg): Adjust to use common block size in all
3547 object pools.
3548
31bdd08a
DM
35492015-09-15 David Malcolm <dmalcolm@redhat.com>
3550
3551 * c-format.c (location_from_offset): Update for change in
3552 signature of location_get_source_line.
3553 * c-indentation.c (get_visual_column): Likewise.
3554 (line_contains_hash_if): Likewise.
3555
aa9f4b4c
MP
35562015-09-14 Marek Polacek <polacek@redhat.com>
3557
3558 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
3559 setting various warnings.
3560
aa256c4a
MP
35612015-09-14 Marek Polacek <polacek@redhat.com>
3562
3563 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
3564 a negative value.
3565
0f876f22
MW
35662015-09-11 Mark Wielaard <mjw@redhat.com>
3567
3568 PR c/28901
3569 * c.opt (Wunused-variable): Option from common.opt.
3570 (Wunused-const-variable): New option.
3571
273aa49e
PC
35722015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
3573
3574 PR c++/53184
3575 * c.opt ([Wsubobject-linkage]): Add.
3576
1807ffc1
MS
35772015-09-03 Martin Sebor <msebor@redhat.com>
3578
3579 PR c/66516
3580 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
3581 functions.
3582 * c-common.c (reject_gcc_builtin): Define.
3583
38942840
BI
35842015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
3585
3586 PR middle-end/60586
3587 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
3588 prototype.
3589 * c-gimplify.c (c_gimplify_expr): Added a call to the function
3590 cilk_gimplify_call_params_in_spawned_fn.
3591 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
3592 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
3593 unwrapping.
3594
c316b5e4
MP
35952015-08-25 Marek Polacek <polacek@redhat.com>
3596
3597 PR middle-end/67330
3598 * c-common.c (handle_weak_attribute): Don't check whether the
3599 visibility can be changed here.
3600
584a7c46
MLI
36012015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
3602
3603 * c-lex.c (c_lex_with_flags): Use explicit locations.
3604
a79683d5
TS
36052015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
3606
3607 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
3608 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
3609
61717a45
FXC
36102015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
3611
3612 PR middle-end/36757
3613 * c-common.c (check_builtin_function_arguments): Add check
3614 for BUILT_IN_SIGNBIT argument.
3615
329524f5
PC
36162015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
3617
3618 PR c++/67160
3619 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
3620 in c++1z mode.
3621
4ee55665
MP
36222015-08-17 Marek Polacek <polacek@redhat.com>
3623
3624 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
3625 with whitespaces before qualifier names.
3626
b893e375
MP
36272015-08-12 Marek Polacek <polacek@redhat.com>
3628
3629 PR c++/55095
3630 * c-common.c (maybe_warn_shift_overflow): Properly handle
3631 left-shifting 1 into the sign bit.
3632
c2d89095
MLI
36332015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
3634
3635 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
3636
971e17ff
AS
36372015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
3638 Braden Obrzut <admin@maniacsvault.net>
3639 Jason Merrill <jason@redhat.com>
3640
3641 Add C++ Concepts TS support.
3642 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
3643 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
3644 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
3645 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
3646 * c-opts.c (set_std_cxx1z): Set flag_concepts.
3647 * c.opt (fconcepts): New.
3648
b3d5bc62
JJ
36492015-08-02 Martin Sebor <msebor@redhat.com>
3650
3651 * c.opt (-Wframe-address): New warning option.
3652
8ebca419
PP
36532015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
3654
3655 * c-indentation.c (should_warn_for_misleading_indentation):
3656 Improve heuristics.
3657
1a1e101f
PP
36582015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
3659
3660 * c-indentation.c (get_visual_column): Add parameter first_nws,
3661 use it. Update comment documenting the function.
3662 (is_first_nonwhitespace_on_line): Remove.
3663 (should_warn_for_misleading_indentation): Replace usage of
3664 of is_first_nonwhitespace_on_line with get_visual_column.
3665
992118a1
PP
36662015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
3667
3668 * c-indentation.h (struct token_indent_info): Define.
3669 (get_token_indent_info): Define.
3670 (warn_for_misleading_information): Declare.
3671 * c-common.h (warn_for_misleading_information): Remove.
3672 * c-identation.c (warn_for_misleading_indentation):
3673 Change declaration to take three token_indent_infos. Adjust
3674 accordingly.
3675 * c-identation.c (should_warn_for_misleading_indentation):
3676 Likewise. Bail out early if the body is a compound statement.
3677 (guard_tinfo_to_string): Define.
3678
e8fa3817
JM
36792015-07-30 Jason Merrill <jason@redhat.com>
3680
3681 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
3682 '*' for reference decay.
3683
173864e8
MP
36842015-07-30 Marek Polacek <polacek@redhat.com>
3685
3686 * c-common.c (warn_tautological_cmp): Bail for float types.
3687
f2afe6dd
MP
36882015-07-27 Marek Polacek <polacek@redhat.com>
3689
3690 PR bootstrap/67030
3691 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
3692
05b28fd6
MP
36932015-07-27 Marek Polacek <polacek@redhat.com>
3694
3695 PR c++/66555
3696 PR c/54979
3697 * c-common.c (find_array_ref_with_const_idx_r): New function.
3698 (warn_tautological_cmp): New function.
3699 * c-common.h (warn_tautological_cmp): Declare.
3700 * c.opt (Wtautological-compare): New option.
3701
5a5062b8
MP
37022015-07-23 Marek Polacek <polacek@redhat.com>
3703
3704 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
3705 (ubsan_instrument_shift): Likewise.
3706
dc891fe7
MP
37072015-07-23 Marek Polacek <polacek@redhat.com>
3708
3709 PR sanitizer/66908
3710 * c-ubsan.c: Include gimplify.h.
3711 (ubsan_instrument_division): Unshare OP0 and OP1.
3712 (ubsan_instrument_shift): Likewise.
3713
451b5e48
MP
37142015-07-20 Marek Polacek <polacek@redhat.com>
3715 Richard Sandiford <richard.sandiford@arm.com>
3716
3717 PR c++/55095
3718 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
3719 Use EXPR_LOC_OR_LOC.
3720 (maybe_warn_shift_overflow): New function.
3721 * c-common.h (maybe_warn_shift_overflow): Declare.
3722 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
3723 * c.opt (Wshift-overflow): New option.
3724
fb0b2914
ML
37252015-07-16 Martin Liska <mliska@suse.cz>
3726
3727 * c-format.c (static void check_format_info_main): Use
3728 object_allocator instead of pool_allocator.
3729 (check_format_arg): Likewise.
3730 (check_format_info_main): Likewise.
3731
903f5c23
AM
37322015-07-15 Andrew MacLeod <amacleod@redhat.com>
3733
3734 * c-opts.c: Remove multiline #include comment.
3735
026c3cfd
AH
37362015-07-12 Aldy Hernandez <aldyh@redhat.com>
3737
3738 * c-common.c: Fix double word typos.
3739
bb49ee66
EB
37402015-07-10 Eric Botcazou <ebotcazou@adacore.com>
3741
3742 * c-ada-spec.h (cpp_operation): Revert latest change.
3743 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
3744 constructors and destructors.
3745
1916bcb5
AM
37462015-07-09 Andrew MacLeod <amacleod@redhat.com>
3747
3748 * c-common.h: Adjust includes for flags.h changes.
3749 * stub-objc.c: Likewise.
026c3cfd 3750
a9dcd529
EB
37512015-07-08 Eric Botcazou <ebotcazou@adacore.com>
3752
3753 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
3754 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
3755
b03b462f
JJ
37562015-07-08 Jakub Jelinek <jakub@redhat.com>
3757
3758 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
3759 are to be removed, return NULL rather than original clauses list.
3760
c7131fb2
AM
37612015-07-07 Andrew MacLeod <amacleod@redhat.com>
3762
3763 * array-notation-common.c: Adjust includes.
3764 * c-ada-spec.c: Likewise.
3765 * c-cilkplus.c: Likewise.
3766 * c-common.h: Likewise.
3767 * c-cppbuiltin.c: Likewise.
3768 * c-dump.c: Likewise.
3769 * c-format.c: Likewise.
3770 * c-gimplify.c: Likewise.
3771 * c-indentation.c: Likewise.
3772 * c-lex.c: Likewise.
3773 * c-omp.c: Likewise.
3774 * c-opts.c: Likewise.
3775 * c-pch.c: Likewise.
3776 * c-ppoutput.c: Likewise.
3777 * c-pragma.c: Likewise.
3778 * c-pretty-print.c: Likewise.
3779 * c-semantics.c: Likewise.
3780 * c-ubsan.c: Likewise.
3781 * cilk.c: Likewise.
3782 * stub-objc.c: Likewise.
3783
2a7fb83f
EB
37842015-07-07 Eric Botcazou <ebotcazou@adacore.com>
3785
3786 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
3787 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
3788
a03c9bf1
JM
37892015-07-01 Jason Merrill <jason@redhat.com>
3790
36a85135
JM
3791 * c-common.h (D_CXX11): Rename from D_CXX0X.
3792 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
3793 * c-common.c: Adjust.
3794
e7fa68d5
JM
3795 * c-opts.c (c_common_post_options): Default to C++14.
3796
a03c9bf1
JM
3797 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
3798
fe95b036
ESR
37992015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
3800
3801 Implement N4197 - Adding u8 character literals
b3d5bc62 3802 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
a64be36b 3803 CPP_CHAR.
b3d5bc62 3804 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
a64be36b 3805 CPP_UTF8CHAR_USERDEF tokens.
b3d5bc62 3806 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
a64be36b
EB
3807 and CPP_UTF8CHAR tokens.
3808 (lex_charconst): Treat CPP_UTF8CHAR token.
fe95b036 3809
da2e71c9
MLI
38102015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
3811
3812 PR fortran/66605
3813 * c-common.c (do_warn_unused_parameter): Move here.
3814 * c-common.h (do_warn_unused_parameter): Declare.
3815
b155cfd9
MP
38162015-06-29 Marek Polacek <polacek@redhat.com>
3817
3818 PR c/66322
3819 * c-common.c (check_case_bounds): Add bool * parameter. Set
3820 OUTSIDE_RANGE_P.
3821 (c_add_case_label): Add bool * parameter. Pass it down to
3822 check_case_bounds.
3823 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
3824 warning here.
3825 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
3826 declarations.
3827
31521951
MP
38282015-06-27 Marek Polacek <polacek@redhat.com>
3829
3830 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
3831 or VECTOR_INTEGER_TYPE_P throughout.
3832 * c-gimplify.c: Likewise.
3833
22d03525
MP
38342015-06-26 Marek Polacek <polacek@redhat.com>
3835
3836 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
3837 * c-common.c (c_fully_fold_internal): Likewise.
3838 (c_alignof_expr): Likewise.
3839 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
3840 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
b1726d6c 3841 * cilk.c (create_parm_list): Likewise.
22d03525 3842
af05e6e5
MP
38432015-06-26 Marek Polacek <polacek@redhat.com>
3844
3845 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
3846
f0889939
AM
38472015-06-25 Andrew MacLeod <amacleod@redhat.com>
3848
3849 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
3850 * c-gimplify.c: Likewise.
3851 * c-pragma.c: Likewise.
3852 * c-ubsan.c: Likewise.
3853 * cilk.c: Likewise.
3854
ca752f39
RS
38552015-06-25 Richard Sandiford <richard.sandiford@arm.com>
3856
3857 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
3858 ggc_hasher.
3859
16a16ec7
AM
38602015-06-25 Andrew MacLeod <amacleod@redhat.com>
3861
3862 * cilk.c: Move calls.h after tm.h in the include chain.
3863
0ae9bd27
MP
38642015-06-25 Marek Polacek <polacek@redhat.com>
3865
3866 * array-notation-common.c: Use VAR_P throughout.
3867 * c-ada-spec.c: Likewise.
3868 * c-common.c: Likewise.
3869 * c-format.c: Likewise.
3870 * c-gimplify.c: Likewise.
3871 * c-omp.c: Likewise.
3872 * c-pragma.c: Likewise.
3873 * c-pretty-print.c: Likewise.
3874 * cilk.c: Likewise.
3875
62f9079a
MP
38762015-06-25 Marek Polacek <polacek@redhat.com>
3877
3878 * cilk.c (extract_free_variables): Use is_global_var.
3879
0fa16060
RS
38802015-06-23 Richard Sandiford <richard.sandiford@arm.com>
3881
3882 * c-common.c: Don't include target-def.h.
3883
a68ae2e1
MP
38842015-06-23 Marek Polacek <polacek@redhat.com>
3885
3886 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
3887 when comparing INTEGER_CSTs.
3888
c6a2f2d9
PMR
38892015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
3890
3891 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
3892 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
3893 (dump_ada_template): Skip partially specialized types.
3894
6b4db501
MM
38952015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
3896
3897 * c-common.c (scalar_to_vector): Use std::swap instead of manually
3898 swapping.
3899
abb226c9
AM
39002015-06-17 Andrew MacLeod <amacleod@redhat.com>
3901
3902 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
3903 * c-ada-spec.c: Likewise.
3904 * c-cilkplus.c: Likewise.
3905 * c-common.c: Likewise.
3906 * c-common.h: Likewise.
3907 * c-cppbuiltin.c: Likewise.
3908 * c-dump.c: Likewise.
3909 * c-format.c: Likewise.
3910 * c-gimplify.c: Likewise.
3911 * c-indentation.c: Likewise.
3912 * c-lex.c: Likewise.
3913 * c-omp.c: Likewise.
3914 * c-opts.c: Likewise.
3915 * c-pch.c: Likewise.
3916 * c-ppoutput.c: Likewise.
3917 * c-pragma.c: Likewise.
3918 * c-pretty-print.c: Likewise.
3919 * c-semantics.c: Likewise.
3920 * c-ubsan.c: Likewise.
3921 * cilk.c: Likewise.
3922 * stub-objc.c: Likewise.
3923
076fecad
PP
39242015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
3925
3926 PR c++/65168
3927 * c-common.c (c_common_truthvalue_conversion): Warn when
3928 converting an address of a reference to a truth value.
3929
13fdf2e2
AM
39302015-06-08 Andrew MacLeod <amacleod@redhat.com>
3931
3932 * array-notation-common.c : Adjust include files.
3933 * c-ada-spec.c : Likewise.
3934 * c-cilkplus.c : Likewise.
3935 * c-common.c : Likewise.
3936 * c-common.h : Likewise.
3937 * c-cppbuiltin.c : Likewise.
3938 * c-dump.c : Likewise.
3939 * c-format.c : Likewise.
3940 * c-gimplify.c : Likewise.
3941 * c-indentation.c : Likewise.
3942 * c-lex.c : Likewise.
3943 * c-omp.c : Likewise.
3944 * c-opts.c : Likewise.
3945 * c-pch.c : Likewise.
3946 * c-ppoutput.c : Likewise.
3947 * c-pragma.c : Likewise.
3948 * c-pretty-print.c : Likewise.
3949 * c-semantics.c : Likewise.
3950 * c-ubsan.c : Likewise.
3951 * cilk.c : Likewise.
3952 * stub-objc.c : Likewise.
3953
a1661b90
MP
39542015-06-08 Marek Polacek <polacek@redhat.com>
3955
3956 PR c/66415
3957 * c-format.c (location_from_offset): Return LOC if LINE is null.
3958
d7438551
AH
39592015-06-05 Aldy Hernandez <aldyh@redhat.com>
3960
3961 * c-common.h (c_parse_final_cleanups): New prototype.
3962 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
3963
b3d5bc62
JJ
39642015-06-04 Sriraman Tallam <tmsriram@google.com>
3965
3966 * c-common.c (noplt): New attribute.
3967 (handle_noplt_attribute): New handler.
3968
ecb9f223
AM
39692015-06-04 Andrew MacLeod <amacleod@redhat.com>
3970
3971 * array-notation-common.c: Adjust includes for restructured coretypes.h.
3972 * c-ada-spec.c: Likewise.
3973 * c-cilkplus.c: Likewise.
3974 * c-common.c: Likewise.
3975 * c-common.h: Likewise.
3976 * c-cppbuiltin.c: Likewise.
3977 * c-dump.c: Likewise.
3978 * c-format.c: Likewise.
3979 * c-gimplify.c: Likewise.
3980 * c-indentation.c: Likewise.
3981 * c-lex.c: Likewise.
3982 * c-omp.c: Likewise.
3983 * c-opts.c: Likewise.
3984 * c-pch.c: Likewise.
3985 * c-ppoutput.c: Likewise.
3986 * c-pragma.c: Likewise.
3987 * c-pretty-print.c: Likewise.
3988 * c-semantics.c: Likewise.
3989 * c-ubsan.c: Likewise.
3990 * cilk.c: Likewise.
3991 * stub-objc.c: Likewise.
3992
6ac48155
DM
39932015-06-02 David Malcolm <dmalcolm@redhat.com>
3994
3995 PR c/66220:
3996 * c-indentation.c (should_warn_for_misleading_indentation): Use
3997 expand_location rather than expand_location_to_spelling_point.
3998 Don't warn if the guarding statement is more indented than the
3999 next/body stmts.
4000
773ce42e
DM
40012015-06-02 David Malcolm <dmalcolm@redhat.com>
4002
4003 * c-indentation.c (warn_for_misleading_indentation): Bail out
4004 immediately if -Wmisleading-indentation isn't enabled.
4005
4fef8379
ML
40062015-06-01 Martin Liska <mliska@suse.cz>
4007
4008 * c-format.c (check_format_arg):Use new type-based pool allocator.
4009 (check_format_info_main) Likewise.
4010
1edfb384
EB
40112015-05-31 Eric Botcazou <ebotcazou@adacore.com>
4012
4013 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
4014 (has_nontrivial_methods): Likewise.
4015
9677ef52
MP
40162015-05-25 Marek Polacek <polacek@redhat.com>
4017
4018 * c-ubsan.c (ubsan_instrument_shift): Use type0.
4019
fd5c817a
MP
40202015-05-22 Marek Polacek <polacek@redhat.com>
4021
4022 PR c/47043
4023 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
4024
a2f45fe6 40252015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
581edfa3
TS
4026
4027 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
4028 STACK_GROWS_DOWNWARD.
4029
a2f45fe6 40302015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
62f9f30b
TS
4031
4032 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
4033 STACK_GROWS_DOWNWARD rather than if it is defined.
4034
0fee2ac2 40352015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
b1726d6c 4036
0fee2ac2
MLI
4037 PR c/52952
4038 * c-format.c (location_column_from_byte_offset): New.
4039 (location_from_offset): New.
4040 (struct format_wanted_type): Add offset_loc field.
4041 (check_format_info): Move handling of location for extra arguments
4042 closer to the point of warning.
4043 (check_format_info_main): Pass the result of location_from_offset
4044 to warning_at.
4045 (format_type_warning): Pass the result of location_from_offset
4046 to warning_at.
4047
cf4ef6f7
MP
40482015-05-20 Marek Polacek <polacek@redhat.com>
4049
4050 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
4051
3a65ee74
MP
40522015-05-20 Marek Polacek <polacek@redhat.com>
4053
4054 * c-ada-spec.c (dump_sloc): Use DECL_P.
4055
21b634ae
MP
40562015-05-20 Marek Polacek <polacek@redhat.com>
4057
4058 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
4059 * c-common.c: Likewise.
4060
0e50b624
DM
40612015-05-19 David Malcolm <dmalcolm@redhat.com>
4062
4063 * c-common.h (fe_file_change): Strengthen param from
4064 const line_map * to const line_map_ordinary *.
4065 (pp_file_change): Likewise.
4066 * c-lex.c (fe_file_change): Likewise.
4067 (cb_define): Use linemap_check_ordinary when invoking
4068 SOURCE_LINE.
4069 (cb_undef): Likewise.
4070 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
4071 invoking cb_file_change.
4072 (c_finish_options): Likewise.
4073 (push_command_line_include): Likewise.
4074 (cb_file_change): Strengthen param "new_map" from
4075 const line_map * to const line_map_ordinary *.
4076 * c-ppoutput.c (cb_define): Likewise for local "map".
4077 (pp_file_change): Likewise for param "map" and local "from".
4078
fab27f52
MM
40792015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
4080
4081 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
4082
2fe1d762
TV
40832015-05-18 Tom de Vries <tom@codesourcery.com>
4084
4085 * c-common.c (build_va_arg_1): New function.
4086 (build_va_arg): Add address operator to va_list operand if necessary.
4087
7a37fa90
MM
40882015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
4089
4090 PR c/48956
4091 * c-common.c (int_safely_convertible_to_real_p): Define.
4092 (unsafe_conversion_p): Check conversions involving complex types.
4093 (conversion_warning): Add new warning message for conversions which
4094 discard imaginary component.
4095 * c-common.h: (enum conversion_safety): Add new enumerator for such
4096 conversions.
4097
3aa3c9fc
MP
40982015-05-14 Marek Polacek <polacek@redhat.com>
4099
4100 PR c/66066
4101 PR c/66127
4102 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
4103 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
4104 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
4105 use it. If FOR_INT_CONST, require that all evaluated operands be
4106 INTEGER_CSTs.
4107
c3388e62
DM
41082015-05-12 David Malcolm <dmalcolm@redhat.com>
4109
4110 * c-common.h (warn_for_misleading_indentation): New prototype.
4111 * c-indentation.c: New file.
4112 * c.opt (Wmisleading-indentation): New option.
4113
c7b38fd5
TV
41142015-05-12 Tom de Vries <tom@codesourcery.com>
4115
4116 PR tree-optimization/66010
4117 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
4118
381bf11e
JM
41192015-05-09 Jason Merrill <jason@redhat.com>
4120
edff0c06
JM
4121 * c-opts.c (c_common_post_options): Also clear
4122 cpp_opts->cpp_warn_cxx11_compat.
4123
129211bc
JM
4124 * c-common.h (enum cxx_dialect): Add cxx_unset.
4125 * c-common.c (cxx_dialect): Initialize to cxx_unset.
4126 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
4127
381bf11e
JM
4128 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
4129 (std=gnu++0x): Mark as Undocumented.
4130 (std=gnu++1y): Add deprecated message.
4131
fe191308
JM
41322015-05-08 Jason Merrill <jason@redhat.com>
4133
765189ff
JM
4134 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
4135 * c-opts.c: Adjust.
4136
fe191308
JM
4137 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
4138
755e528f
MP
41392015-05-08 Marek Polacek <polacek@redhat.com>
4140
4141 PR c/64918
4142 * c.opt (Woverride-init-side-effects): New option.
4143
0173bd2a
MP
41442015-05-07 Marek Polacek <polacek@redhat.com>
4145
4146 PR c/65179
4147 * c-common.c (c_fully_fold_internal): Warn when left shifting a
4148 negative value.
4149 * c.opt (Wshift-negative-value): New option.
4150 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
4151 when -Wextra and C99/C++11 mode.
4152
e0f0d3b9
MP
41532015-05-07 Marek Polacek <polacek@redhat.com>
4154 Martin Uecker <uecker@eecs.berkeley.edu>
4155
4156 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
4157 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
4158
8243e2a9
JM
41592015-05-05 Jason Merrill <jason@redhat.com>
4160
4161 * c.opt (Wterminate): New.
4162
577cd070
MP
41632015-04-30 Marek Polacek <polacek@redhat.com>
4164
4165 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
4166 require that the non-constant be of a boolean type.
4167
0373796b
JT
41682015-04-29 Josh Triplett <josh@joshtriplett.org>
4169
e0f0d3b9
MP
4170 * c-common.c (handle_section_attribute): Refactor to reduce
4171 nesting and distinguish between error cases.
0373796b 4172
716c0ba6
MP
41732015-04-29 Marek Polacek <polacek@redhat.com>
4174
4175 PR c/64610
4176 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
4177 with 0/1.
4178
8848828b
JJ
41792015-04-29 Jakub Jelinek <jakub@redhat.com>
4180
4181 * c-common.h (omp_clause_mask): Unconditionally define as a class.
4182 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
4183 HOST_BITS_PER_WIDE_INT.
4184
ecd0e562
TV
41852015-04-28 Tom de Vries <tom@codesourcery.com>
4186
4187 PR tree-optimization/65887
4188 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
4189
2a877204 41902015-04-28 Eric Botcazou <ebotcazou@adacore.com>
e0f0d3b9 4191 Pierre-Marie de Rodat <derodat@adacore.com>
2a877204
EB
4192
4193 * c-ada-spec.c (in_function): Delete.
4194 (dump_generic_ada_node): Do not change in_function and remove the
4195 redundant code dealing with it.
4196 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
4197 (print_ada_methods): Output the static member functions in a nested
4198 package after the regular methods as well as associated renamings.
4199
4853031e
MP
42002015-04-24 Marek Polacek <polacek@redhat.com>
4201
4202 PR c/65830
4203 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
4204 and OPT_Wshift_count_overflow.
4205
8c2b7f79
MP
4206 PR c/63357
4207 * c-common.c (warn_logical_operator): Warn if the operands have the
4208 same expressions.
4209
b8787813
MP
42102015-04-24 Marek Polacek <polacek@redhat.com>
4211
4212 PR c/61534
4213 * c-common.c (warn_logical_operator): Bail if either operand comes
4214 from a macro expansion.
4215
8fba1830
BRF
42162015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
4217
4218 PR target/55143
4219 * c-common.c (c_default_pointer_mode): Add definition.
4220 * c-common.h (c_default_pointer_mode): Add declaration.
4221
17958621
JJ
42222015-03-11 Jakub Jelinek <jakub@redhat.com>
4223
4224 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
4225 on record_builtin_type argument.
4226
7ccb1a11
JJ
42272015-03-10 Jakub Jelinek <jakub@redhat.com>
4228
4229 PR c/65120
4230 * c-common.c (warn_logical_not_parentheses): Don't warn for
4231 !x == 0 or !x != 0.
4232
04fd785e
MP
42332015-03-07 Marek Polacek <polacek@redhat.com>
4234
4235 PR sanitizer/65280
4236 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
4237 before trying to figure out whether we have a flexible array member.
4238
a4e26206 42392015-03-06 Eric Botcazou <ebotcazou@adacore.com>
8e745a17 4240 Jonathan Wakely <jwakely.gcc@gmail.com>
a4e26206
EB
4241
4242 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
4243
0d2489f4
EB
42442015-03-05 Eric Botcazou <ebotcazou@adacore.com>
4245
4246 PR ada/65319
4247 * c-ada-spec.c (print_destructor): Remove obsolete code.
4248
83ed54d7
EB
42492015-03-01 Eric Botcazou <ebotcazou@adacore.com>
4250
4251 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
4252 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
4253 DECL_TEMPLATE_RESULT emulations.
4254 (dump_ada_template)): Add guard for TYPE_METHODS.
4255
7631f0e2
MP
42562015-02-27 Marek Polacek <polacek@redhat.com>
4257
4258 PR c/65040
4259 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
4260
d1783ae5
KT
42612015-02-27 Kai Tietz <ktietz@redhat.com>
4262
4263 PR c/35330
4264 * c-pragma.c (handle_pragma_weak): Do not try to create
4265 weak/alias of declarations not being function, or variable
4266 declarations.
4267
56a9f6bc
TS
42682015-02-24 Thomas Schwinge <thomas@codesourcery.com>
4269
4270 PR libgomp/64625
4271 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
4272 Remove macros.
4273 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
4274
3d5cb23d
MP
42752015-02-16 Marek Polacek <polacek@redhat.com>
4276
4277 PR c/65066
4278 * c-format.c (check_format_types): Handle null param.
4279
fa008882
MP
42802015-02-13 Marek Polacek <polacek@redhat.com>
4281
4282 PR c/65040
4283 * c-format.c (check_format_types): Don't warn about different
4284 signedness if the original value is in the range of WANTED_TYPE.
4285
785f21af
JM
42862015-02-12 Jason Merrill <jason@redhat.com>
4287
4288 PR c++/64956
4289 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
4290 to the current highest version.
4291 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
4292
4886ec8e
JJ
42932015-02-04 Jakub Jelinek <jakub@redhat.com>
4294
4295 PR c/64824
4296 PR c/64868
4297 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
4298 instead of RDIV_EXPR. Use build_binary_op instead of
4299 build2_loc.
4300
40fecdd6
JM
43012015-01-30 Joseph Myers <joseph@codesourcery.com>
4302
4303 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
4304 to pass input_location as first argument.
4305
a0c88d06
TV
43062015-01-23 Tom de Vries <tom@codesourcery.com>
4307
4308 PR libgomp/64672
4309 * c.opt (fopenacc): Mark as LTO option.
4310
1506ae0e
TV
43112015-01-23 Tom de Vries <tom@codesourcery.com>
4312
4313 PR libgomp/64707
4314 * c.opt (fopenmp): Mark as LTO option.
4315
31be63ab
JJ
43162015-01-21 Jakub Jelinek <jakub@redhat.com>
4317
4318 PR c/63307
b1726d6c 4319 * cilk.c (fill_decls_vec): Only put decls into vector v.
31be63ab
JJ
4320 (compare_decls): Fix up formatting.
4321
43222015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
4323
4324 PR c/63307
4325 * cilk.c: Include vec.h.
4326 (struct cilk_decls): New structure.
4327 (wrapper_parm_cb): Split this function to...
4328 (fill_decls_vec): ...this...
4329 (create_parm_list): ...and this.
4330 (compare_decls): New function.
4331 (for_local_cb): Remove.
4332 (wrapper_local_cb): Ditto.
4333 (build_wrapper_type): For now first traverse and fill vector of
4334 declarations then sort it and then deal with sorted vector.
4335 (cilk_outline): Ditto.
4336 (declare_one_free_variable): Ditto.
4337
6875457f
JM
43382015-01-21 Jason Merrill <jason@redhat.com>
4339
4340 PR c++/64629
4341 * c-format.c (check_format_arg): Call decl_constant_value.
4342
185c9e56
ML
43432015-01-19 Martin Liska <mliska@suse.cz>
4344
4345 * c-common.c (handle_noicf_attribute): New function.
4346
41dbbb37
TS
43472015-01-15 Thomas Schwinge <thomas@codesourcery.com>
4348 Bernd Schmidt <bernds@codesourcery.com>
4349 James Norris <jnorris@codesourcery.com>
4350 Cesar Philippidis <cesar@codesourcery.com>
4351 Ilmir Usmanov <i.usmanov@samsung.com>
4352 Jakub Jelinek <jakub@redhat.com>
4353
4354 * c.opt (fopenacc): New option.
4355 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
4356 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
4357 New macros.
4358 * c-common.h (c_finish_oacc_wait): New prototype.
4359 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
4360 (c_finish_oacc_wait): New function.
4361 * c-pragma.c (oacc_pragmas): New variable.
4362 (c_pp_lookup_pragma, init_pragma): Handle it.
4363 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
4364 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
4365 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
4366 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
4367 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
4368 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
4369 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
4370 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
4371 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
4372 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
4373 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
4374 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
4375 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
4376 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
4377 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
4378 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
4379 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
4380 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
4381 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
4382 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
4383 PRAGMA_OACC_CLAUSE_WORKER.
4384
3f8257db 43852015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
5434dc07
MD
4386
4387 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
4388 for the new option fstack-protector_explicit.
4389 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
4390 (handle_stack_protect_attribute): New function.
4391
3f8257db 43922015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
de1b5c17
MU
4393
4394 * c.opt: New option -Warray-bounds=.
4395
adfac8df
JJ
43962015-01-09 Michael Collison <michael.collison@linaro.org>
4397
4398 * array-notation-common.c: Include hash-set.h, machmode.h,
4399 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4400 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
4401 * c-ada-spec.c: Ditto.
4402 * c-cilkplus.c: Ditto.
4403 * c-common.c: Include input.h due to flattening of tree.h.
4404 Define macro GCC_C_COMMON_C.
4405 * c-common.h: Flatten tree.h header files into c-common.h.
4406 Remove include of tree-core.h.
4407 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
4408 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4409 fold-const.h, wide-int.h, and inchash.h due to
4410 flattening of tree.h.
4411 * c-dump.c: Ditto.
4412 * c-format.c: Flatten tree.h header files into c-common.h.
4413 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
4414 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4415 fold-const.h, wide-int.h, and inchash.h due to
4416 flattening of tree.h.
4417 * c-dump.c: Include hash-set.h, machmode.h,
4418 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4419 fold-const.h, wide-int.h, and inchash.h due to
4420 flattening of tree.h.
4421 * c-format.c: Include hash-set.h, machmode.h,
4422 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4423 fold-const.h, wide-int.h, inchash.h and real.h due to
4424 flattening of tree.h.
4425 * c-gimplify.c: Include hash-set.h, machmode.h,
4426 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4427 fold-const.h, wide-int.h, and inchash.h due to
4428 flattening of tree.h.
4429 * cilk.c: Ditto.
4430 * c-lex.c: Ditto.
4431 * c-omp.c: Ditto.
4432 * c-opts.c: Ditto.
4433 * c-pch.c: Ditto.
4434 * c-ppoutput.c: Ditto.
4435 * c-pragma.c: Ditto.
4436 * c-pretty-print.c: Ditto.
4437 * c-semantics.c: Ditto.
4438 * c-ubsan.c: Ditto.
4439 * stub-objc.c: Ditto.
4440
f5481fc4
JM
44412015-01-08 Jason Merrill <jason@redhat.com>
4442
4443 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
4444 do_ubsan_in_current_function.
4445 (ubsan_maybe_instrument_reference_or_call): Likewise.
4446 * c-ubsan.h: Declare it.
4447
de35aa66
MS
44482015-01-08 Mike Stump <mikestump@comcast.net>
4449
4450 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
4451
4a9a42ab
MP
44522015-01-07 Marek Polacek <polacek@redhat.com>
4453
4454 PR c/64440
4455 * c-common.c (c_fully_fold_internal): Warn for division and modulo
4456 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
4457
2f42e5de
TS
44582015-01-05 Trevor Saunders <tsaunders@mozilla.com>
4459
4460 PR c++/31397
4461 * c.opt (Wsuggest-override): New option.
4462
5624e564
JJ
44632015-01-05 Jakub Jelinek <jakub@redhat.com>
4464
4465 Update copyright years.
4466
5bd012f8
MP
44672015-01-05 Marek Polacek <polacek@redhat.com>
4468
4469 PR c/64423
4470 * c-common.c (warn_array_subscript_with_type_char): Add location_t
4471 parameter. Use it.
4472 * c-common.h (warn_array_subscript_with_type_char): Update
4473 declaration.
4474
a7fa8d18
ESR
44752014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
4476
4477 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
4478 Control macro with flag_sized_deallocation.
4479
3f8257db 44802014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
768952be
MU
4481
4482 * c.opt (Wdiscarded-array-qualifiers): New option.
4483
1f8d3e84
JJ
44842014-12-19 Jakub Jelinek <jakub@redhat.com>
4485
4486 PR preprocessor/63831
4487 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
4488 and __has_cpp_attribute here.
4489 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
4490 c_common_has_attribute.
4491 * c-common.h (c_common_has_attribute): New prototype.
4492 * c-lex.c (init_c_lex): Set cb->has_attribute to
4493 c_common_has_attribute instead of cb_has_attribute.
4494 (get_token_no_padding): New function.
4495 (cb_has_attribute): Renamed to ...
4496 (c_common_has_attribute): ... this. No longer static. Use
4497 get_token_no_padding, require ()s, don't build TREE_LIST
4498 unnecessarily, fix up formatting, adjust diagnostics, call
4499 init_attributes.
4500
20b06add
JM
45012014-12-15 Jason Merrill <jason@redhat.com>
4502
4503 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
4504 (-Wsized-deallocation): New.
4505 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
4506 to on in C++14 and up.
4507
94a073b2
JM
45082014-12-11 Jason Merrill <jason@redhat.com>
4509
acaa5911
JM
4510 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
4511
94a073b2
JM
4512 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
4513 we aren't complaining about VLAs.
4514
7fb66c15
MP
45152014-12-06 Marek Polacek <polacek@redhat.com>
4516
4517 PR tree-optimization/64183
4518 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
4519 shift-expression if it is integer_type_node. Use types_compatible_p.
4520
b731b390
JJ
45212014-11-29 Jakub Jelinek <jakub@redhat.com>
4522
4523 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
4524 last argument from create_tmp_var_raw and create_tmp_var calls.
4525 * cilk.c (gimplify_cilk_spawn): Likewise.
4526 * c-omp.c (c_finish_omp_atomic): Likewise.
4527
6a4da643
MP
45282014-11-28 Marek Polacek <polacek@redhat.com>
4529
4530 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
4531 instead of unsigned_type_node.
4532
541e35a6
MP
45332014-11-28 Marek Polacek <polacek@redhat.com>
4534
4535 PR c/63862
4536 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
4537 to op1_utype.
4538 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
4539 expression to unsigned_type_node.
4540
dcc97066
MW
45412014-11-20 Mark Wielaard <mjw@redhat.com>
4542
4543 PR debug/38757
4544 * c-opts.c (set_std_c89): Set lang_hooks.name.
4545 (set_std_c99): Likewise.
4546 (set_std_c11): Likewise.
4547 (set_std_cxx98): Likewise.
4548 (set_std_cxx11): Likewise.
4549 (set_std_cxx14): Likewise.
4550 (set_std_cxx1z): Likewise.
4551
aa7da51a
JJ
45522014-11-21 Jakub Jelinek <jakub@redhat.com>
4553
4554 PR target/63764
4555 * c-common.h (convert_vector_to_pointer_for_subscript): Change
4556 return type to bool.
009a3480 4557 * c-common.c: Include gimple-expr.h.
aa7da51a
JJ
4558 (convert_vector_to_pointer_for_subscript): Change return type to
4559 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
4560 and copy it into a TARGET_EXPR and use that instead of *vecp
4561 directly.
4562
538dd0b7
DM
45632014-11-19 David Malcolm <dmalcolm@redhat.com>
4564
4565 Merger of git branch "gimple-classes-v2-option-3".
4566 * ChangeLog.gimple-classes: New.
4567 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
4568 from being just a vec<gimple> to a vec<gbind *>.
4569
c39a5e99
JJ
45702014-11-18 Jakub Jelinek <jakub@redhat.com>
4571
4572 PR sanitizer/63813
4573 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
4574 argument to ptype, set type to TREE_TYPE (ptype). Don't call
4575 get_pointer_alignment for non-pointers. Use ptype, or if it is
4576 reference type, corresponding pointer type, as type of kind
4577 argument.
4578 (ubsan_maybe_instrument_reference,
4579 ubsan_maybe_instrument_member_call): Adjust callers.
4580
8537a4a9
MP
45812014-11-15 Marek Polacek <polacek@redhat.com>
4582
4583 PR middle-end/63884
4584 * array-notation-common.c (is_sec_implicit_index_fn): Return false
4585 for NULL fndecl.
4586 (extract_array_notation_exprs): Return for NULL node.
4587
2079956a
JM
45882014-11-12 Joseph Myers <joseph@codesourcery.com>
4589
4590 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
4591 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
4592
1304953e
JJ
45932014-11-12 Jakub Jelinek <jakub@redhat.com>
4594
4595 PR c/59708
4596 * c-common.c (check_builtin_function_arguments): Handle
4597 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
4598
e5e44252
AK
45992014-11-10 Andi Kleen <ak@linux.intel.com>
4600
4601 PR c/60804
4602 * c-common.h (check_no_cilk): Declare.
4603 * cilk.c (get_error_location): New function.
4604 (check_no_cilk): Dito.
4605
e64b984d
AK
46062014-11-10 Andi Kleen <ak@linux.intel.com>
4607
4608 * cilk.c (recognize_spawn): Use expression location
4609 for error message.
4610
13c21655
PC
46112014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
4612
4613 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
4614
42fd12b1
ESR
46152014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
4616
4617 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
4618 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
4619 (__cpp_range_based_for, __cpp_initializer_lists,
4620 __cpp_delegating_constructors, __cpp_nsdmi,
4621 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
4622 for C++11; (__cpp_attribute_deprecated): Remove in favor of
4623 __has_cpp_attribute.
4624 * c-lex.c (cb_has_attribute): New callback CPP function;
4625 (init_c_lex): Set has_attribute callback.
4626
6f450181
RB
46272014-11-04 Richard Biener <rguenther@suse.de>
4628
4629 * c-common.c (shorten_compare): Do not shorten mixed
4630 DFP and non-DFP compares.
4631
26f0e1d6
ESR
46322014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
4633
4634 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
4635 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
4636 Commentary and rearrangement of tests.
4637 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
4638 Commentary and rearrangement of tests.
4639 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto
4640 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
4641
ef4bddc2
RS
46422014-10-29 Richard Sandiford <richard.sandiford@arm.com>
4643
4644 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
4645 enum from machine_mode.
4646
c582198b
AM
46472014-10-28 Andrew MacLeod <amacleod@redhat.com>
4648
adfac8df
JJ
4649 * c-common.c: Adjust include files.
4650 * c-gimplify.c: Ditto.
4651 * cilk.c: Ditto.
4652 * c-pragma.c: Ditto.
4653 * c-ubsan.c: Ditto.
c582198b 4654
60393bbc
AM
46552014-10-27 Andrew MacLeod <amacleod@redhat.com>
4656
4657 * c-gimplify.c: Adjust include files.
4658
d723bb7c
MLI
46592014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
4660
4661 PR c++/53061
4662 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
4663 c_common_initialize_diagnostics.
4664 * c-common.h: Likewise.
4665
90f3520e
MP
46662014-10-24 Marek Polacek <polacek@redhat.com>
4667
4668 PR c/56980
4669 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
4670 print "struct"/"union"/"enum" for typedefed names.
4671
59d7607a
MP
46722014-10-23 Marek Polacek <polacek@redhat.com>
4673
4674 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
4675 in unsigned type.
4676
d95a2703
JJ
46772014-10-22 Jakub Jelinek <jakub@redhat.com>
4678 Yury Gribov <y.gribov@samsung.com>
4679
4680 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
4681 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
4682 instead of flag_sanitize_recover as bool flag.
4683
8e6ef852
KY
46842014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
4685
4686 * cilk.c: Revert previous change.
4687
948cf550
IZ
46882014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
4689
4690 PR c/63307
4691 * cilk.c: Include vec.h.
4692 (struct cilk_decls): New structure.
4693 (wrapper_parm_cb): Split this function to...
4694 (fill_decls_vec): ...this...
4695 (create_parm_list): ...and this.
4696 (compare_decls): New function.
4697 (for_local_cb): Remove.
4698 (wrapper_local_cb): Ditto.
4699 (build_wrapper_type): For now first traverse and fill vector of
4700 declarations then sort it and then deal with sorted vector.
4701 (cilk_outline): Ditto.
4702 (declare_one_free_variable): Ditto.
4703
92574c7c
MP
47042014-10-17 Marek Polacek <polacek@redhat.com>
4705
4706 * c-opts.c (c_common_post_options): Set warn_implicit_int.
4707 * c.opt (Wimplicit-int): Initialize to -1.
4708
83685514
AM
47092014-10-16 Andrew MacLeod <amacleod@redhat.com>
4710
4711 * c-pragma.c: Adjust include files.
4712 * c-semantics.c: Likewise.
4713
5b8300ea
DD
47142014-10-16 DJ Delorie <dj@redhat.com>
4715
4716 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
4717 multiples of bytes.
4718
5f83e90b
JM
47192014-10-14 Jason Merrill <jason@redhat.com>
4720
4721 PR c++/63455
4722 * c-common.h (CPP_PREPARSED_EXPR): New.
4723 (N_CP_TTYPES): Adjust.
4724
d73326ca
MP
47252014-10-15 Marek Polacek <polacek@redhat.com>
4726
4727 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
4728
78a7c317
DD
47292014-10-14 DJ Delorie <dj@redhat.com>
4730
4731 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
4732 types, not just __int128.
4733 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
4734 types, not just __int128.
4735 (cpp_atomic_builtins): Round pointer sizes up.
4736 (type_suffix): Use type precision, not specific types.
4737 * c-common.c (c_common_reswords): Remove __int128 special case.
4738 (c_common_type_for_size): Check for all __intN types, not just
4739 __int128.
4740 (c_common_type_for_mode): Likewise.
4741 (c_common_signed_or_unsigned_type): Likewise.
4742 (c_build_bitfield_integer_type): Likewise.
4743 (c_common_nodes_and_builtins): Likewise.
4744 (keyword_begins_type_specifier): Likewise.
4745 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
4746 __intN variants.
4747
2a22f99c
TS
47482014-10-12 Trevor Saunders <tsaunders@mozilla.com>
4749
4750 * c-common.c: Use hash_table instead of hashtab.
4751
2a8ef767
ESR
47522014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
4753
adfac8df 4754 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
2a8ef767
ESR
4755 C++11 section.
4756
3c9aabbd
MG
47572014-10-03 Marc Glisse <marc.glisse@inria.fr>
4758
4759 PR c++/54427
4760 PR c++/57198
4761 PR c++/58845
4762 * c-common.c (warn_logical_operator): Punt for vectors.
4763
a15f7cb8
ESR
47642014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
4765
4766 Implement SD-6: SG10 Feature Test Recommendations
4767 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
4768 macros and the __has_header macro.
4769
8d0cf15e
JM
47702014-09-30 Jason Merrill <jason@redhat.com>
4771
dd5d5481
JM
4772 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
4773 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
4774 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
4775
b752325e
JM
4776 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
4777 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
4778
8d0cf15e
JM
4779 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
4780 * c-common.c (c_common_reswords): Remove __is_convertible_to.
4781
083e891e
MP
47822014-09-24 Marek Polacek <polacek@redhat.com>
4783
4784 PR c/61405
4785 PR c/53874
4786 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
4787
7861b648
AK
47882014-09-23 Andi Kleen <ak@linux.intel.com>
4789
4790 * c-common.c (handle_no_reorder_attribute): New function.
4791 (c_common_attribute_table): Add no_reorder attribute.
4792
9a79452d
JM
47932014-09-22 Joseph Myers <joseph@codesourcery.com>
4794
4795 * c-cppbuiltin.c (c_cpp_builtins): Define
4796 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
4797 modes.
4798
dd69f047
JM
47992014-09-18 Joseph Myers <joseph@codesourcery.com>
4800
4801 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
4802 for supported floating-point modes.
4803
737a4826
MLI
48042014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
4805
4806 * c.opt (Wpsabi): Use LangEnabledBy.
4807 * c-opts.c (c_common_handle_option): Do not handle here.
4808
8cc4b7a2
JM
48092014-09-12 Joseph Myers <joseph@codesourcery.com>
4810
4811 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
4812 macros for floating-point modes.
4813
179b5a55
MG
48142014-09-11 Marc Glisse <marc.glisse@inria.fr>
4815
4816 PR target/58757
4817 * c-cppbuiltin.c (builtin_define_float_constants): Correct
4818 __*_DENORM_MIN__ without denormals.
4819
570a11fe
JJ
48202014-09-10 Jakub Jelinek <jakub@redhat.com>
4821
4822 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
4823 ubsan_instrument_vla, ubsan_instrument_return): Adjust
4824 ubsan_create_data callers.
4825 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
4826 index is constant or BIT_AND_EXPR with constant mask and is
4827 small enough for the bound.
4828 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
4829 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
4830
b559c810
MLI
48312014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
4832
4833 * c.opt: Add CppReason to various flags.
4834 (Wdate-time): Re-sort.
4835 * c-common.c: Include c-common.h earlier.
4836 (struct reason_option_codes_t): Delete.
4837 (c_option_controlling_cpp_error): Prefix global type and struct
4838 with cpp_.
4839
1ef33fd4
MLI
48402014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
4841
4842 * c.opt (Wnormalized): New.
4843 (Wnormalized=): Use Enum and Reject Negative.
4844 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
4845
66bb34c0
JM
48462014-09-08 Joseph Myers <joseph@codesourcery.com>
4847
4848 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
4849 digits of floating-point modes if -fbuilding-libgcc.
4850
53d68b9f
JM
48512014-09-05 Joseph Myers <joseph@codesourcery.com>
4852
4853 * c-cppbuiltin.c (c_cpp_builtins): Also define
4854 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
4855 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
4856 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
4857 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
4858 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
4859 __LIBGCC_STACK_GROWS_DOWNWARD__,
4860 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
4861 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
4862 __LIBGCC_DWARF_FRAME_REGISTERS__,
4863 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
4864 __LIBGCC_STACK_POINTER_REGNUM__ and
4865 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
4866 (builtin_define_with_value): Handle backslash-escaping in string
4867 macro values.
4868
f65586dc
RB
48692014-09-05 Richard Biener <rguenther@suse.de>
4870
4871 PR middle-end/63148
4872 * c-format.c (check_format_arg): Properly handle
4873 effectively signed POINTER_PLUS_EXPR offset.
4874
2b71f4a4
MLI
48752014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
4876
4877 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
4878 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
4879 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
4880 and Init.
4881 * c-opts.c (c_common_handle_option): Do not handle here.
4882 (sanitize_cpp_opts): Likewise.
4883 * c-common.c (struct reason_option_codes_t): Handle
4884 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
4885
d2e4feca
MP
48862014-09-03 Marek Polacek <polacek@redhat.com>
4887
4888 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
4889
9a771876
JJ
48902014-09-02 Jakub Jelinek <jakub@redhat.com>
4891 Balaji V. Iyer <balaji.v.iyer@intel.com>
4892 Igor Zamyatin <igor.zamyatin@intel.com>
4893
4894 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
4895 * c-common.c (c_common_reswords): Added _Cilk_for.
4896 * c-common.h (enum rid): Added RID_CILK_FOR.
4897 (cilk_for_number_of_iterations): Add declaration.
4898 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
4899 CILK_FOR.
4900 * c-pragma.c (init_pragma): Register "grainsize" pragma.
4901 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
4902
81b5d104
MLI
49032014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
4904
4905 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
4906 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
4907 Wundef): Use CPP, Var and Init.
4908 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
4909
b753b37b
MLI
49102014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
4911
4912 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
4913 * c-opts.c (c_common_handle_option): Do not handle here.
4914
028aee17
JM
49152014-08-25 Jason Merrill <jason@redhat.com>
4916
4917 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
4918 -std=c++14 and -std=gnu++14, rather than the reverse.
4919 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
4920 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
4921 * c-common.h (cxx_dialect): Remove cxx1y.
4922
e4276ba5
ESR
49232014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
4924
4925 * c-common.h (enum cxx_dialect): Add cxx14.
4926 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
4927 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
4928 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
4929
a545cacd
JM
49302014-08-22 Jason Merrill <jason@redhat.com>
4931
4932 * c.opt (std=gnu++17): Fix alias.
4933
59ea0364
MP
49342014-08-22 Marek Polacek <polacek@redhat.com>
4935
4936 PR c++/62199
4937 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
4938 check for vector types. Drop LHS argument.
4939 * c-common.h (warn_logical_not_parentheses): Adjust.
4940
596e808c
MLI
49412014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
4942
4943 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
4944 (Wmultichar): Likewise.
4945 (Wdate-time): Use C-family languages instead of Common. Use CPP
4946 and Var.
4947 * c-opts.c (c_common_handle_option): Do not handle the above
4948 options here.
4949 (sanitize_cpp_opts): Likewise.
4950
18767f65
MLI
49512014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
4952
4953 PR fortran/44054
4954 * c-opts.c: Include tree-diagnostics.h.
4955 (c_diagnostic_finalizer): New.
4956 (c_common_initialize_diagnostics): Use it.
4957
b4413594
MLI
49582014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
4959
4960 PR preprocessor/51303
4961 * c-common.c (struct reason_option_codes_t option_codes):
4962 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
4963
43f9a13c
MLI
49642014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
4965
4966 PR c/60975
4967 PR c/53063
4968 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
4969 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
4970 (c_common_post_options): Call init_global_opts_from_cpp.
4971 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
4972
04159acf
MP
49732014-08-19 Marek Polacek <polacek@redhat.com>
4974
4975 PR c++/62153
4976 * c-common.c (maybe_warn_bool_compare): New function.
4977 * c-common.h (maybe_warn_bool_compare): Declare.
4978 * c.opt (Wbool-compare): New option.
4979
35aff4fb
MP
49802014-08-19 Marek Polacek <polacek@redhat.com>
4981
4982 * c.opt (Wc99-c11-compat): New option.
4983
177cce46
MP
49842014-08-19 Marek Polacek <polacek@redhat.com>
4985
4986 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
4987 to warn_c90_c99_compat.
4988 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
4989 to -1.
4990
6ae9194f
MLI
49912014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
4992 Steven Bosscher <steven@gcc.gnu.org>
4993
4994 PR c/52952
4995 * c-format.c: Add extra_arg_loc and format_string_loc to struct
4996 format_check_results.
4997 (check_function_format): Use true and add comment for boolean
4998 argument.
4999 (finish_dollar_format_checking): Use explicit location when warning.
5000 (check_format_info): Likewise.
5001 (check_format_arg): Set extra_arg_loc and format_string_loc.
5002 (check_format_info_main): Use explicit location when warning.
5003 (check_format_types): Pass explicit location.
5004 (format_type_warning): Likewise.
5005
8e54f6d3
MLI
50062014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
5007
5008 PR fortran/44054
5009 * c-format.c: Handle Fortran flags.
5010
cd4e76fc
IZ
50112014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
5012
5013 PR other/61962
5014 * array-notation-common.c (find_rank): Added handling for other
5015 types of references.
5016
f3bede71
MP
50172014-08-10 Marek Polacek <polacek@redhat.com>
5018
5019 PR c/51849
5020 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
5021 * c.opt (Wc90-c99-compat): Add option.
5022
9f25a338
TS
50232014-08-07 Trevor Saunders <tsaunders@mozilla.com>
5024
5025 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
5026
62e4eb35
MP
50272014-08-03 Marek Polacek <polacek@redhat.com>
5028
5029 * c-common.c (check_case_value): Add location_t parameter. Use it.
5030 (c_add_case_label): Pass loc to check_case_value.
5031
b787e7a2
TS
50322014-08-02 Trevor Saunders <tsaunders@mozilla.com>
5033
5034 * cilk.c: Use hash_map instead of pointer_map.
5035
6e2830c3
TS
50362014-08-02 Trevor Saunders <tsaunders@mozilla.com>
5037
5038 * c-gimplify.c: Use hash_set instead of pointer_set.
5039
a7ee52fb
IZ
50402014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
5041
5042 PR middle-end/61455
5043 * array-notation-common.c (extract_array_notation_exprs): Handling
5044 of DECL_EXPR added.
5045
944fa280
JJ
50462014-08-01 Jakub Jelinek <jakub@redhat.com>
5047
5048 * c-common.h (min_align_of_type): Removed prototype.
5049 * c-common.c (min_align_of_type): Removed.
5050 * c-ubsan.h (ubsan_maybe_instrument_reference,
5051 ubsan_maybe_instrument_member_call): New prototypes.
5052 * c-ubsan.c: Include stor-layout.h and builtins.h.
5053 (ubsan_maybe_instrument_reference_or_call,
5054 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
5055 functions.
5056
b4dfdc11
MG
50572014-07-31 Marc Glisse <marc.glisse@inria.fr>
5058
5059 PR c++/60517
5060 * c.opt (-Wreturn-local-addr): Move to common.opt.
5061
a41844e5
JM
50622014-07-30 Jason Merrill <jason@redhat.com>
5063
5064 PR c++/61659
5065 PR c++/61687
5066 Revert:
5067 * c.opt (-fuse-all-virtuals): New.
5068
976d5a22
TT
50692014-07-30 Tom Tromey <tromey@redhat.com>
5070
5071 PR c/59855
5072 * c.opt (Wdesignated-init): New option.
5073 * c-common.c (c_common_attribute_table): Add "designated_init".
5074 (handle_designated_init): New function.
5075
cdc94aca
MP
50762014-07-24 Marek Polacek <polacek@redhat.com>
5077
5078 PR c/57653
5079 * c-opts.c (c_finish_options): If -imacros is in effect, return.
5080
f41373b6
DS
50812014-07-16 Dodji Seketeli <dodji@redhat.com>
5082
5083 PR preprocessor/60723 - missing system-ness marks for macro tokens
5084 * c-ppoutput.c (struct print::prev_was_system_token): New data
5085 member.
5086 (init_pp_output): Initialize it.
5087 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
5088 (do_line_change): Return a flag saying if a line marker was
5089 emitted or not.
5090 (scan_translation_unit): Detect if the system-ness of the token we
5091 are about to emit is different from the one of the previously
5092 emitted token. If so, emit a line marker. Avoid emitting useless
5093 adjacent line markers. Avoid emitting line markers for tokens
5094 originating from the expansion of built-in macros.
5095 (scan_translation_unit_directives_only): Adjust.
5096
4d661eaa
MP
50972014-07-15 Marek Polacek <polacek@redhat.com>
5098
5099 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
5100 TYPE_MAX_VALUE is NULL.
5101
b108f48f
JJ
51022014-07-14 Jakub Jelinek <jakub@redhat.com>
5103
5104 PR middle-end/61294
5105 * c.opt (Wmemset-transposed-args): New warning.
5106
c0221884
JM
51072014-07-10 Jason Merrill <jason@redhat.com>
5108
5109 PR c++/61659
5110 PR c++/61687
5111 * c.opt (-fuse-all-virtuals): New.
5112
63dfbb95
RB
51132014-07-09 Richard Biener <rguenther@suse.de>
5114
5115 PR c-family/61741
5116 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
5117 using unsigned arithmetic if overflow does not wrap instead of
5118 if overflow is undefined.
5119
773ec47f
MP
51202014-07-06 Marek Polacek <polacek@redhat.com>
5121
5122 PR c/6940
5123 * c.opt (Wsizeof-array-argument): New option.
5124
00a7ba58
JJ
51252014-07-03 Jakub Jelinek <jakub@redhat.com>
5126
b1726d6c 5127 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
00a7ba58
JJ
5128 comments->count <= 1, as comments->entries might be NULL.
5129
52ec0ea3
MP
51302014-07-01 Marek Polacek <polacek@redhat.com>
5131
5132 * c.opt (Wint-conversion): New option.
5133
d5c3d343
MP
51342014-07-01 Marek Polacek <polacek@redhat.com>
5135
5136 PR c/58286
5137 * c.opt (Wincompatible-pointer-types): New option.
5138
6e7ceb17
PC
51392014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
5140
5141 PR c++/51400
5142 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
5143 Do not discard TYPE_QUALS of type.
5144
da73100b
JM
51452014-06-26 Jason Merrill <jason@redhat.com>
5146
5147 * c-common.h (enum cxx_dialect): Add cxx1z.
5148 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
5149 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
5150
08eedf75
TJ
51512014-06-26 Teresa Johnson <tejohnson@google.com>
5152
5153 * c-common.h (get_dump_info): Declare.
5154 * c-gimplify.c (c_genericize): Use saved dump files.
5155 * c-opts.c (c_common_parse_file): Begin and end dumps
5156 once around parsing invocation.
5157 (get_dump_info): New function.
5158
7b56b2f8
MP
51592014-06-23 Marek Polacek <polacek@redhat.com>
5160 Andrew MacLeod <amacleod@redhat.com>
5161
5162 PR c/61553
5163 * c-common.c (get_atomic_generic_size): Don't segfault if the
5164 type doesn't have a size.
5165
0e37a2f3
MP
51662014-06-20 Marek Polacek <polacek@redhat.com>
5167
5168 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
5169 (ubsan_walk_array_refs_r): New function.
5170 (c_genericize): Instrument array bounds.
5171 * c-ubsan.c: Include "internal-fn.h".
5172 (ubsan_instrument_division): Mark instrumented arrays as having
5173 side effects. Adjust ubsan_type_descriptor call.
5174 (ubsan_instrument_shift): Likewise.
5175 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
5176 (ubsan_instrument_bounds): New function.
5177 (ubsan_array_ref_instrumented_p): New function.
5178 (ubsan_maybe_instrument_array_ref): New function.
5179 * c-ubsan.h (ubsan_instrument_bounds): Declare.
5180 (ubsan_array_ref_instrumented_p): Declare.
5181 (ubsan_maybe_instrument_array_ref): Declare.
5182
51832014-06-20 Hale Wang <hale.wang@arm.com>
dd6fe7d4
HW
5184
5185 PR lto/61123
5186 * c.opt (fshort-enums): Add to LTO.
5187 * c.opt (fshort-wchar): Likewise.
5188
5c3d09f7
MP
51892014-06-16 Marek Polacek <polacek@redhat.com>
5190
5191 PR c/60439
5192 * c.opt (Wswitch-bool): Add Var.
5193
9cf32741
JJ
51942014-06-12 Jakub Jelinek <jakub@redhat.com>
5195
5196 PR middle-end/61486
5197 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
5198 #pragma omp target teams or
5199 #pragma omp {,target }teams distribute simd.
5200
62984918
JM
52012014-06-12 Jason Merrill <jason@redhat.com>
5202
5203 * c.opt (Wabi=, fabi-compat-version): New.
5204 * c-opts.c (c_common_handle_option): Handle -Wabi=.
5205 (c_common_post_options): Handle flag_abi_compat_version default.
5206 Disallow -fabi-compat-version=1.
5207 * c-common.h (abi_version_crosses): New.
5208
f961457f
JH
52092014-06-11 Jan Hubicka <hubicka@ucw.cz>
5210
adfac8df 5211 * c-common.c (handle_section_attribute): Update handling for
f961457f
JH
5212 section names that are no longer trees.
5213
92d28cbb
JJ
52142014-06-10 Jakub Jelinek <jakub@redhat.com>
5215
5216 PR fortran/60928
5217 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
5218 (omp_pragmas): ... back here.
5219
742938c9
MP
52202014-06-05 Marek Polacek <polacek@redhat.com>
5221
5222 PR c/49706
5223 * c-common.c (warn_logical_not_parentheses): New function.
5224 * c-common.h (warn_logical_not_parentheses): Declare.
5225 * c.opt (Wlogical-not-parentheses): New option.
5226
9d548dfb
MP
52272014-06-04 Marek Polacek <polacek@redhat.com>
5228
5229 PR c/30020
5230 * c-common.c (check_case_bounds): Add location parameter.
5231 Use it.
5232 (c_add_case_label): Pass loc to check_case_bounds.
5233
fedfecef
MP
52342014-06-03 Marek Polacek <polacek@redhat.com>
5235
5236 PR c/60439
5237 * c.opt (Wswitch-bool): New option.
5238
f6a7cffc
TS
52392014-05-22 Thomas Schwinge <thomas@codesourcery.com>
5240
040d18b6
TS
5241 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
5242 Remove prototypes.
5243 (record_types_used_by_current_var_decl): Move prototype to where
5244 it belongs.
5245
f6a7cffc
TS
5246 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
5247 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
5248 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
5249
632f2871
RS
52502014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
5251
5252 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
5253 * c-common.c (c_common_nodes_and_builtins): Don't initialize
5254 void_zero_node.
5255 * c-pretty-print.c (pp_c_void_constant): New function.
5256 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
5257 (c_pretty_printer::expression): Handle VOID_CST.
5258 * cilk.c (extract_free_variables): Likewise.
5259 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
5260 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
5261
766090c2
TS
52622014-05-17 Trevor Saunders <tsaunders@mozilla.com>
5263
5264 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
5265 * c-pragma.c (push_alignment): Adjust.
5266 (handle_pragma_push_options): Likewise.
5267
661a0813
MP
52682014-05-09 Marek Polacek <polacek@redhat.com>
5269
5270 PR c/50459
5271 * c-common.c (check_user_alignment): Return -1 if alignment is error
5272 node.
5273 (handle_aligned_attribute): Don't call default_conversion on
5274 FUNCTION_DECLs.
5275 (handle_vector_size_attribute): Likewise.
5276 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
5277 (handle_sentinel_attribute): Call default_conversion and allow even
5278 integral types as an argument.
5279
2793eeab
MP
52802014-05-08 Marek Polacek <polacek@redhat.com>
5281
5282 PR c/61053
5283 * c-common.c (min_align_of_type): New function factored out from...
5284 (c_sizeof_or_alignof_type): ...here.
5285 * c-common.h (min_align_of_type): Declare.
5286
f827930a
MP
52872014-05-08 Marek Polacek <polacek@redhat.com>
5288
5289 PR c/61077
5290 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
5291 parameter type of main.
5292
ca49b74e
DD
52932014-05-07 DJ Delorie <dj@redhat.com>
5294
5295 * c-cppbuiltin.c (print_bits_of_hex): New.
5296 (builtin_define_type_minmax): Print values using hex so as not to
5297 require a pre-computed list of string values.
5298
1d60af08
KZ
52992014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
5300 Mike Stump <mikestump@comcast.net>
5301 Richard Sandiford <rdsandiford@googlemail.com>
5302
5303 * c-ada-spec.c: Include wide-int.h.
5304 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
5305 (dump_generic_ada_node): Use wide-int interfaces.
5306 * c-common.c: Include wide-int-print.h.
5307 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
5308 (pointer_int_sum): Use wide-int interfaces.
5309 (c_common_nodes_and_builtins): Use make_int_cst.
5310 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
5311 (handle_alloc_size_attribute): Use wide-int interfaces.
5312 (get_nonnull_operand): Likewise.
5313 * c-format.c (get_constant): Use tree_fits_uhwi_p.
5314 * c-lex.c: Include wide-int.h.
5315 (narrowest_unsigned_type): Take a widest_int rather than two
5316 HOST_WIDE_INTs.
5317 (narrowest_signed_type): Likewise.
5318 (interpret_integer): Update accordingly. Use wide-int interfaces.
5319 (lex_charconst): Use wide-int interfaces.
5320 * c-pretty-print.c: Include wide-int.h.
5321 (pp_c_integer_constant): Use wide-int interfaces.
5322 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
5323 INT_CST_LT_UNSIGNED.
5324
b15458be
RB
53252014-05-06 Richard Biener <rguenther@suse.de>
5326
5327 * c-opts.c (c_common_post_options): For -freestanding,
5328 -fno-hosted and -fno-builtin disable pattern recognition
5329 if not enabled explicitely.
5330
6577374e
MP
53312014-05-02 Marek Polacek <polacek@redhat.com>
5332
5333 * c.opt (Wsizeof-pointer-memaccess): Describe option.
5334
d00887e8
MP
53352014-05-01 Marek Polacek <polacek@redhat.com>
5336
5337 PR c/43245
5338 * c.opt (Wdiscarded-qualifiers): Add.
5339
f8ed5150
MP
53402014-04-30 Marek Polacek <polacek@redhat.com>
5341
5342 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
5343 INT_MIN / -1 sanitization only for integer types.
5344
45484dcf
MP
53452014-04-25 Marek Polacek <polacek@redhat.com>
5346
5347 PR c/18079
5348 * c-common.c (handle_noinline_attribute): Warn if the attribute
5349 conflicts with always_inline attribute.
5350 (handle_always_inline_attribute): Warn if the attribute conflicts
5351 with noinline attribute.
5352
38e514c0
MP
53532014-04-25 Marek Polacek <polacek@redhat.com>
5354
5355 PR c/60156
5356 * c-common.c (check_main_parameter_types): Warn about variadic main.
5357
44875f92
MS
53582014-04-24 Mike Stump <mikestump@comcast.net>
5359
5360 * c.opt (Wshadow-ivar): Default to on.
5361
dcaaa5a0
DP
53622014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
5363
5364 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
5365
c07d7c02
MP
53662014-04-23 Marek Polacek <polacek@redhat.com>
5367
5368 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
5369
1c33c9b7
JJ
53702014-04-22 Jakub Jelinek <jakub@redhat.com>
5371
5372 PR sanitizer/60275
5373 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
5374 if flag_sanitize_undefined_trap_on_error.
5375 (ubsan_instrument_division, ubsan_instrument_shift,
5376 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
5377 if !flag_sanitize_recover.
5378
793c625f
MG
53792014-04-22 Marc Glisse <marc.glisse@inria.fr>
5380
5381 PR libstdc++/43622
5382 * c-common.c (registered_builtin_types): Make non-static.
5383 * c-common.h (registered_builtin_types): Declare.
5384
b0f1bf36
RB
53852014-04-14 Richard Biener <rguenther@suse.de>
5386 Marc Glisse <marc.glisse@inria.fr>
5387
5388 PR c/60819
5389 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
5390 apply may-alias the scalar pointer type when applicable.
5391
3b07fa4a
IZ
53922014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
5393
5394 PR middle-end/60467
5395 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
5396 as possible argument for Cilk_spawn.
5397
cbbd2b1c
TB
53982014-04-11 Tobias Burnus <burnus@net-b.de>
5399
5400 PR c/60194
5401 * c.opt (Wformat-signedness): Add
5402 * c-format.c(check_format_types): Use it.
5403
6415bd5d
JM
54042014-04-11 Jason Merrill <jason@redhat.com>
5405
5406 PR c++/57926
5407 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
5408 default_conversion for an array argument.
5409
6525783a
MP
54102014-04-08 Marek Polacek <polacek@redhat.com>
5411
5412 PR sanitizer/60745
5413 * c-ubsan.c: Include asan.h.
5414 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
5415
880a467b
NS
54162014-04-03 Nathan Sidwell <nathan@codesourcery.com>
5417
5418 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
5419
7b59ff2d
MP
54202014-04-02 Marek Polacek <polacek@redhat.com>
5421
5422 * c-common.h (c_expand_expr): Remove declaration.
5423
8edbfaa6
JJ
54242014-03-28 Jakub Jelinek <jakub@redhat.com>
5425
5426 PR c++/60689
5427 * c-common.c (add_atomic_size_parameter): When creating new
5428 params vector, push the size argument first.
5429
07d72e1d
JJ
54302014-03-26 Jakub Jelinek <jakub@redhat.com>
5431
5432 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5433 ubsan_instrument_vla, ubsan_instrument_return): Adjust
5434 ubsan_create_data callers.
5435
b35e0fa0
JJ
54362014-03-22 Jakub Jelinek <jakub@redhat.com>
5437
5438 PR debug/60603
5439 * c-opts.c (c_finish_options): Restore cb_file_change call to
5440 <built-in>.
5441
39a1ebb3
JJ
54422014-03-13 Jakub Jelinek <jakub@redhat.com>
5443
5444 PR middle-end/36282
5445 * c-pragma.c (apply_pragma_weak): Only look at
5446 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
5447 DECL_ASSEMBLER_NAME_SET_P (decl).
5448 (maybe_apply_pending_pragma_weaks): Exit early if
5449 vec_safe_is_empty (pending_weaks) rather than only when
5450 !pending_weaks.
5451 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
5452 set assembler name back to NULL afterwards.
5453
a07f6ed2
JM
54542014-03-11 Jason Merrill <jason@redhat.com>
5455
5456 * c.opt: Add -std=gnu++14.
5457
75b107f5
IB
54582014-03-11 Ian Bolton <ian.bolton@arm.com>
5459
5460 * c-opts.c (c_common_post_options): Don't override
5461 -ffp-contract=fast if unsafe-math-optimizations is on.
5462
f42c637e
PM
54632014-03-08 Paulo Matos <paulo@matos-sorge.com>
5464
22b15758 5465 * c.opt: Enable LTO FE for fshort-double.
f42c637e 5466
70e24808
JM
54672014-03-07 Jason Merrill <jason@redhat.com>
5468
5469 * c.opt: Add -std=c++14.
5470
3af9c5e9
MP
54712014-03-06 Marek Polacek <polacek@redhat.com>
5472
5473 PR c/60197
5474 * cilk.c (contains_cilk_spawn_stmt): New function.
5475 (contains_cilk_spawn_stmt_walker): Likewise.
5476 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
5477 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
5478
b3bdf019
JJ
54792014-03-03 Jakub Jelinek <jakub@redhat.com>
5480
5481 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
5482 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
5483 even when flag_preprocess_only.
5484
ca7e759d
JM
54852014-02-26 Jason Merrill <jason@redhat.com>
5486
5487 PR c++/59231
5488 PR c++/11586
5489 * c-common.c (shorten_compare): Don't check
5490 c_inhibit_evaluation_warnings.
5491
28e41874
JJ
54922014-02-19 Jakub Jelinek <jakub@redhat.com>
5493
cca615af
JJ
5494 PR c/37743
5495 * c-common.c (c_common_nodes_and_builtins): When initializing
5496 c_uint{16,32,64}_type_node, also set corresponding
5497 uint{16,32,64}_type_node to the same value.
5498
28e41874
JJ
5499 PR c++/60267
5500 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
5501 for PRAGMA_IVDEP if flag_preprocess_only.
5502
c2bf53a1
JJ
55032014-02-12 Jakub Jelinek <jakub@redhat.com>
5504
5505 PR c/60101
5506 * c-common.c (merge_tlist): If copy is true, call new_tlist,
5507 if false, add ADD itself, rather than vice versa.
5508 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
5509 copy. For SAVE_EXPR, only call merge_tlist once.
5510
8fcbce72
JJ
55112014-02-08 Jakub Jelinek <jakub@redhat.com>
5512
5513 PR middle-end/60092
5514 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
5515 and tree_to_uhwi.
5516 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
5517 functions.
5518 (c_common_attribute_table): Add alloc_align and assume_aligned
5519 attributes.
5520
0a756a3f
MP
55212014-02-06 Marek Polacek <polacek@redhat.com>
5522
5523 PR c/60087
5524 * c-common.c (warn_for_sign_compare): Call warning_at with location
5525 instead of warning.
5526
7ec4847a
MP
55272014-02-05 Marek Polacek <polacek@redhat.com>
5528
5529 PR c/53123
5530 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
5531 statement.
5532
66f20604
MP
55332014-02-04 Marek Polacek <polacek@redhat.com>
5534
5535 PR c/60036
5536 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
5537 SAVE_EXPR.
5538
5d77fb19
MG
55392014-02-03 Marc Glisse <marc.glisse@inria.fr>
5540
5541 PR c++/53017
5542 PR c++/59211
5543 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
5544 handle_vector_size_attribute, handle_nonnull_attribute): Call
5545 default_conversion on the attribute argument.
5546 (handle_nonnull_attribute): Increment the argument number.
5547
81e5eca8
MP
55482014-01-31 Marek Polacek <polacek@redhat.com>
5549
5550 PR c/59963
5551 * c-common.c (add_atomic_size_parameter): Pass vNULL to
5552 build_function_call_vec.
5553 (resolve_overloaded_builtin): Likewise.
5554 * c-common.h (build_function_call_vec): Adjust declaration.
5555
68fca595
MP
55562014-01-30 Marek Polacek <polacek@redhat.com>
5557
5558 PR c/59940
5559 * c-common.h (unsafe_conversion_p): Adjust declaration.
5560 (warnings_for_convert_and_check): Likewise.
5561 (convert_and_check): Likewise.
5562 * c-common.c (unsafe_conversion_p): Add location parameter. Call
5563 expansion_point_location_if_in_system_header on it.
5564 (warnings_for_convert_and_check): Add location parameter. Call
5565 expansion_point_location_if_in_system_header on it. Use it.
5566 (convert_and_check): Add location parameter. Use it.
5567 (conversion_warning): Likewise.
5568 (c_add_case_label): Adjust convert_and_check calls.
5569 (scalar_to_vector): Adjust unsafe_conversion_p calls.
5570
b72271b9
BI
55712014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
5572
5573 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
5574 flag_cilkplus.
5575 * c-pragma.c (init_pragma): Likewise.
5576 * c.opt: Likewise.
5577
393e8e8b
MP
55782014-01-23 Marek Polacek <polacek@redhat.com>
5579
5580 PR c/59846
5581 * c-common.c (shorten_compare): Add location_t parameter.
5582 * c-common.h (shorten_binary_op): Adjust declaration.
5583
f04dda30
MP
55842014-01-23 Marek Polacek <polacek@redhat.com>
5585
5586 PR c/58346
5587 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
5588 * c-common.h: Declare it.
5589
621955cb
EB
55902014-01-20 Eric Botcazou <ebotcazou@adacore.com>
5591
5592 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
5593 * c-ada-spec.c (dump_ads): Likewise.
5594 (cpp_check): Likewise.
5595 (dump_ada_specs): Likewise.
5596
55972014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
67bf2939
LA
5598
5599 PR c++/49718
5600 * c-common.c (handle_no_instrument_function_attribute): Allow
5601 no_instrument_function attribute in class member
5602 definition/declaration.
5603
241f845a
JJ
56042014-01-15 Jakub Jelinek <jakub@redhat.com>
5605
5606 PR c/58943
5607 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
5608 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
5609 being COMPOUND_EXPR.
5610 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
5611 operand a SAVE_EXPR and second MODIFY_EXPR.
5612
e83b8e2e
JJ
56132014-01-09 Jakub Jelinek <jakub@redhat.com>
5614
5615 PR target/58115
5616 * c-pch.c (c_common_write_pch): Call
5617 prepare_target_option_nodes_for_pch.
5618
23a5b65a
RS
56192014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
5620
5621 Update copyright years
5622
f9030485
RS
56232014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
5624
5625 * array-notation-common.c, c-cilkplus.c: Use the standard form for
5626 the copyright notice.
5627
f2aa696b
EB
56282013-12-28 Eric Botcazou <ebotcazou@adacore.com>
5629
5630 * c-ada-spec.c (print_constructor): New function.
5631 (print_destructor): Retrieve the origin of the destructor.
5632 (print_ada_declaration): Revamp handling of constructors/destructors.
5633
3f8257db 56342013-12-23 Stuart Hastings <stuart@apple.com>
1f26ac87
JM
5635 Bill Maddox <maddox@google.com>
5636 Jason Merrill <jason@redhat.com>
5637
5638 * c.opt: Add -fdeclone-ctor-dtor.
5639 * c-opts.c (c_common_post_options): Default to on iff -Os.
5640
41958c28
BI
56412013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
5642
5643 * c-common.c (c_common_attribute_table): Added "cilk simd function"
5644 attribute.
5645 * c-pragma.h (enum pragma_cilk_clause): Remove.
5646 (enum pragma_omp_clause): Added the following fields:
5647 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
5648 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
5649 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
5650 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
5651 PRAGMA_CILK_CLAUSE_UNIFORM.
5652
b1726d6c 5653
12893402
BI
56542013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
5655
5656 * cilk.c (cilk_outline): Made this function non-static.
5657 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
5658 (create_cilk_wrapper): Added a new parameter: a function pointer.
5659 (c_install_body_w_frame_cleanup): Remove
5660 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
5661 * c-common.h (cilk_outline): New prototype.
5662 (gimplify_cilk_spawn): Removed two parameters.
5663 (cilk_install_body_with_frame_cleanup): New prototype.
5664 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
5665 CILK_SPAWN_STMT case.
5666
085b42ed
BS
56672013-12-11 Bernd Schmidt <bernds@codesourcery.com>
5668
2ce064c3
BS
5669 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
5670
085b42ed
BS
5671 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
5672 (int_array_type_node): Remove.
5673 * c-common.c (c_common_nodes_and_builtins): Don't build it.
5674
9e36c9ed
MP
56752013-12-05 Marek Polacek <polacek@redhat.com>
5676
5677 PR c/52023
5678 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
5679 [ADJUST_FIELD_ALIGN].
5680
296674db
JM
56812013-12-04 Joseph Myers <joseph@codesourcery.com>
5682
5683 PR c/52023
5684 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
5685 and check field alignment if set.
5686 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
5687 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
5688
b1726d6c 56892013-12-04 Jakub Jelinek <jakub@redhat.com>
31e071ae
MP
5690 Marek Polacek <polacek@redhat.com>
5691
5692 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
5693 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
5694
d7947e19
L
56952013-11-29 H.J. Lu <hongjiu.lu@intel.com>
5696
5697 PR c/59309
5698 * cilk.c (gimplify_cilk_spawn): Properly handle function without
5699 arguments.
5700
fad7652e
JJ
57012013-11-29 Jakub Jelinek <jakub@redhat.com>
5702
5703 PR c/59280
5704 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
5705 goto invalid. If it is error_mark_node, don't issue further
5706 diagnostics.
5707
8b5e1202
SO
57082013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
5709
5710 * c.opt (Wopenmp-simd): New.
5711
0a508bb6
JJ
57122013-11-22 Jakub Jelinek <jakub@redhat.com>
5713
5714 * c-ubsan.h (ubsan_instrument_return): New prototype.
5715 * c-ubsan.c (ubsan_instrument_return): New function.
5716
2fb9a547
AM
57172013-11-22 Andrew MacLeod <amacleod@redhat.com>
5718
5719 * c-common.c: Add required include files from gimple.h.
5720 * c-gimplify.c: Likewise
5721 * cilk.c: Likewise
5722
8400e75e
DM
57232013-11-22 David Malcolm <dmalcolm@redhat.com>
5724
5725 * c-common.c (unsafe_conversion_p): Remove use of
5726 EXPR_LOC_OR_HERE macro.
5727 (conversion_warning): Likewise.
5728 (warnings_for_convert_and_check): Likewise.
5729 (warn_for_collisions_1): Likewise.
5730 (shorten_compare): Likewise, and remove use of in_system_header
5731 macro, using the location from the former.
5732 * c-lex.c (dump_one_header): Remove use of input_filename macro.
5733 (cb_def_pragma): Remove use of in_system_header macro.
5734 (lex_string): Likewise.
5735 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
5736
eb1ce453
KZ
57372013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
5738 Mike Stump <mikestump@comcast.net>
5739 Richard Sandiford <rdsandiford@googlemail.com>
5740
5741 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
5742 instead of TREE_INT_CST_LOW, in cases where there is a protecting
5743 tree_fits_shwi_p or tree_fits_uhwi_p.
5744 (dump_generic_ada_node): Likewise.
5745 * c-format.c (check_format_arg): Likewise.
5746 * c-pretty-print.c (pp_c_integer_constant): Likewise.
5747
6b3b8c27
KZ
57482013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
5749
5750 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
5751
49b0aa18
JC
57522013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
5753
5754 PR c/53001
5755 * c-common.c (unsafe_conversion_p): Make this function
5756 return an enumeration with more detail.
5757 (conversion_warning): Use the new return type of
5758 unsafe_conversion_p to separately warn either about conversions
5759 that lower floating point number precision or about the other
5760 kinds of conversions.
5761 * c-common.h (enum conversion_safety): New enumeration.
8e745a17
JJ
5762 (unsafe_conversion_p): switching return type to
5763 conversion_safety enumeration.
49b0aa18
JC
5764 * c.opt: Adding new warning -Wfloat-conversion and
5765 enabling it with -Wconversion.
5766
b826515a
BS
57672013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
5768
8e745a17
JJ
5769 * c-opts.c: Include plugin.h.
5770 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
b826515a 5771
b9a55b13
MP
57722013-11-19 Marek Polacek <polacek@redhat.com>
5773
5774 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
5775 call.
5776 (ubsan_instrument_shift): Likewise.
5777 (ubsan_instrument_vla): Likewise.
5778
7d362f6c
RS
57792013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
5780
5781 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
5782 cast to unsigned type.
5783
386b1f1f
RS
57842013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
5785
5786 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
5787 tree_low_cst.
5788 (complete_array_type): Update comment to refer to tree_to_[su]hwi
5789 rather than tree_low_cst.
5790
ae7e9ddd
RS
57912013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
5792
5793 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
5794 tree_to_uhwi throughout.
5795
9439e9a1
RS
57962013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
5797
5798 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
5799 tree_low_cst (..., 0) with tree_to_shwi throughout.
5800
cc269bb6
RS
58012013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
5802
5803 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
5804 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
5805
9541ffee
RS
58062013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
5807
5808 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
5809 host_integerp (..., 0) with tree_fits_shwi_p throughout.
5810
c02065fc
AH
58112013-11-15 Aldy Hernandez <aldyh@redhat.com>
5812
5813 * c-cilkplus.c: New file.
5814 * c-common.c (readonly_error): Add location argument.
5815 * c-common.h (readonly_error): Same.
5816 (c_finish_cilk_clauses): Protoize.
5817 (c_check_cilk_loop): Same.
5818 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
5819 Do not fail on error_mark_node.
5820 Abstract increment canonicalization to here...
5821 (c_omp_for_incr_canonicalize_ptr): New.
5822 c-pragma.c (init_pragma): Register "simd" pragma.
5823 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
5824 (enum pragma_cilk_clause): New.
5825
9cc65f15
RS
58262013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
5827
5828 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
5829 wchar_type and host_integerp checks.
5830
18f429e2
AM
58312013-11-14 Andrew MacLeod <amacleod@redhat.com>
5832
5833 * c-common.c: Likewise.
5834 * c-gimplify.c: Likewise.
5835 * cilk.c: Likewise.
5836
d8a2d370
DN
58372013-11-14 Diego Novillo <dnovillo@google.com>
5838
5839 * c-common.c: Include fold-const.h.
5840 Include stor-layout.h.
5841 Include calls.h.
5842 Include stringpool.h.
5843 Include attribs.h.
5844 Include varasm.h.
5845 Include trans-mem.h.
5846 * c-cppbuiltin.c: Include stor-layout.h.
5847 Include stringpool.h.
5848 * c-format.c: Include stringpool.h.
5849 * c-lex.c: Include stringpool.h.
5850 Include stor-layout.h.
5851 * c-pragma.c: Include stringpool.h.
5852 Include attribs.h.
5853 Include varasm.h.
5854 Include gcc-symtab.h.
5855 * c-pretty-print.c: Include stor-layout.h.
5856 Include attribs.h.
5857 * cilk.c: Include stringpool.h.
5858 Include calls.h.
5859
38b7bc7f
JM
58602013-11-13 Joseph Myers <joseph@codesourcery.com>
5861
5862 * c-common.h (enum rid): Add RID_AUTO_TYPE.
5863 * c-common.c (c_common_reswords): Add __auto_type.
5864 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
5865
45b0be94
AM
58662013-11-12 Andrew MacLeod <amacleod@redhat.com>
5867
18f429e2
AM
5868 * c-common.c: Include gimplify.h.
5869 * c-gimplify.c: Likewise.
5870 * cilk.c: Likewise.
5871 * c-omp.c: Include gimple-expr.h instead of gimple.h.
5872 * c-ubsan.c: Don't include gimple.h.
45b0be94 5873
582d9b50
JM
58742013-11-12 Joseph Myers <joseph@codesourcery.com>
5875
5876 * c-common.c (c_common_reswords): Add _Thread_local.
5877
6b28e197
JM
58782013-11-09 Joseph Myers <joseph@codesourcery.com>
5879
5880 * c-common.c (atomic_size_supported_p): New function.
5881 (resolve_overloaded_atomic_exchange)
5882 (resolve_overloaded_atomic_compare_exchange)
5883 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
5884 Use it instead of comparing size with a local list of sizes.
5885
267bac10
JM
58862013-11-07 Andrew MacLeod <amacleod@redhat.com>
5887 Joseph Myers <joseph@codesourcery.com>
5888
5889 * c-common.h (enum rid): Add RID_ATOMIC.
5890 * c-common.c (c_common_reswords): Add _Atomic.
5891 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
5892 (keyword_is_type_qualifier): Accept RID_ATOMIC.
5893 * c-format.c (check_format_types): Check for extra _Atomic
5894 qualifiers in format argument.
5895 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
5896 (pp_c_type_qualifier_list): Mention _Atomic in comment.
5897
5157b91e
TB
58982013-11-06 Tobias Burnus <burnus@net-b.de>
5899
5900 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
5901
6dbe0958
JM
59022013-11-06 Joseph Myers <joseph@codesourcery.com>
5903
5904 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
5905 standards modes.
5906 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
5907 to mean lack of IEEE 754 support.
5908
e8ff5196
TB
59092013-11-05 Tobias Burnus <burnus@net-b.de>
5910
5911 * c.opt (-Wdate-time): New option
5912 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
5913
254a0760
JM
59142013-11-05 Joseph Myers <joseph@codesourcery.com>
5915
5916 * c-cppbuiltin.c (cpp_iec_559_value): Test
5917 flag_excess_precision_cmdline not flag_excess_precision.
5918
6d7f7e0a
TB
59192013-11-05 Tobias Burnus <burnus@net-b.de>
5920
5921 * c.opt (fopenmp-simd): New option.
5922 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
5923 (omp_pragmas): ... this new struct.
5924 (c_pp_lookup_pragma): Also walk omp_pragmas.
5925 (init_pragma): Init pragmas for -fopenmp-simd.
5926
55a7f02f
MP
59272013-11-04 Marek Polacek <polacek@redhat.com>
5928
5929 PR c++/58979
5930 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
5931
9193fb05
JM
59322013-11-04 Joseph Myers <joseph@codesourcery.com>
5933
5934 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
5935 New functions.
5936 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
5937
94159ecf
EB
59382013-11-04 Eric Botcazou <ebotcazou@adacore.com>
5939
5940 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
5941 (dump_ada_specs): Adjust prototype of second callback.
5942 * c-ada-spec.c (cpp_check): New global variable.
5943 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
5944 (print_generic_ada_decl): Likewise.
5945 (has_static_fields): Change return type to bool and add guard.
5946 (has_nontrivial_methods): New predicate.
5947 (is_tagged_type): Change return type to bool.
5948 (separate_class_package): Call has_nontrivial_methods.
5949 (pp_ada_tree_identifier): Minor tweaks.
5950 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
5951 (dump_ada_array_domains): Likewise.
5952 (dump_ada_array_type): Likewise.
5953 (dump_template_types): Remove cpp_check parameter and do not pass it to
5954 dump_generic_ada_node.
5955 (dump_ada_template): Likewise.
5956 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
5957 recursively.
5958 (print_ada_methods): Change return type to integer. Remove cpp_check
5959 parameter and do not pass it down.
5960 (dump_nested_types): Remove cpp_check parameter and do not pass it to
5961 dump_generic_ada_node.
5962 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
5963 accessing methods.
5964 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
5965 down. Use has_nontrivial_methods to recognize C++ classes. Use return
5966 value of print_ada_methods.
5967 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
5968 Set cpp_check to it before invoking dump_ada_nodes.
5969 (dump_ada_specs): Likewise.
5970
b906f4ca
MP
59712013-11-03 Marek Polacek <polacek@redhat.com>
5972
5973 * c-ubsan.c: Don't include hash-table.h.
5974 (ubsan_instrument_vla): New function.
5975 * c-ubsan.h: Declare it.
5976
5e20cdc9
DM
59772013-10-31 David Malcolm <dmalcolm@redhat.com>
5978
5979 Automated part of renaming of symtab_node_base to symtab_node.
5980
5981 Patch autogenerated by rename_symtab.py from
5982 https://github.com/davidmalcolm/gcc-refactoring-scripts
5983 revision 58bb219cc090b2f4516a9297d868c245495ee622
5984
5985 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
5986 symtab_node_base to symtab_node.
5987
7057e645
ESR
59882013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
5989
8e745a17 5990 Implement C++14 digit separators.
7057e645
ESR
5991 * c-lex.c (interpret_float): Remove digit separators from scratch string
5992 before building real literal.
5993
193ea7bc
JJ
59942013-10-30 Jakub Jelinek <jakub@redhat.com>
5995
5996 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
5997
939b37da
BI
59982013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
5999
6000 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
6001 fields.
6002 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
6003 enabled.
6004 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
6005 (insert_cilk_frame): New prototype.
6006 (cilk_init_builtins): Likewise.
6007 (gimplify_cilk_spawn): Likewise.
6008 (c_cilk_install_body_w_frame_cleanup): Likewise.
6009 (cilk_detect_spawn_and_unwrap): Likewise.
6010 (cilk_set_spawn_marker): Likewise.
6011 (build_cilk_sync): Likewise.
6012 (build_cilk_spawn): Likewise.
6013 * cilk.c: New file.
6014
67348ccc
DM
60152013-10-29 David Malcolm <dmalcolm@redhat.com>
6016
6017 Patch autogenerated by refactor_symtab.py from
6018 https://github.com/davidmalcolm/gcc-refactoring-scripts
6019 revision 58bb219cc090b2f4516a9297d868c245495ee622
6020
6021 * c-gimplify.c (c_genericize): Update for conversion of symtab types
6022 to a true class hierarchy.
6023 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
6024
d570872d
RS
60252013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
6026
6027 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
6028
98906124
JL
60292013-10-26 Jeff Law <law@redhat.com>
6030
adfac8df
JJ
6031 * c-common.c (c_define_builtins): Remove mudflap support.
6032 * c.opt: Ignore and warn for mudflap options.
98906124 6033
d73749df 60342013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
6035
6036 PR other/33426
6037 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
6038 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
6039
3f04b1bb
JM
60402013-10-23 Jason Merrill <jason@redhat.com>
6041
6042 * c-format.c (gcc_cxxdiag_char_table): Add %X.
6043
acf0174b
JJ
60442013-10-11 Jakub Jelinek <jakub@redhat.com>
6045
acd15a28
JJ
6046 * c-common.h (omp_clause_mask::operator !=): New method.
6047 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
6048 instead of if (mask & something) tests everywhere.
6049
acf0174b
JJ
6050 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
6051 201307 instead of 201107.
6052 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
6053 (c_common_attribute_table): Add "omp declare target" and
6054 "omp declare simd" attributes.
6055 (handle_omp_declare_target_attribute,
6056 handle_omp_declare_simd_attribute): New functions.
6057 * c-omp.c: Include c-pragma.h.
6058 (c_finish_omp_taskgroup): New function.
6059 (c_finish_omp_atomic): Add swapped argument, if true,
6060 build the operation first with rhs, lhs arguments and use NOP_EXPR
6061 build_modify_expr.
6062 (c_finish_omp_for): Add code argument, pass it down to make_code.
6063 (c_omp_split_clauses): New function.
6064 (c_split_parallel_clauses): Removed.
6065 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
6066 c_omp_declare_simd_clauses_to_decls): New functions.
6067 * c-common.h (omp_clause_mask): New type.
6068 (OMP_CLAUSE_MASK_1): Define.
6069 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
6070 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
6071 omp_clause_mask::operator |, omp_clause_mask::operator &,
6072 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
6073 omp_clause_mask::operator ==): New methods.
6074 (enum c_omp_clause_split): New.
6075 (c_finish_omp_taskgroup): New prototype.
6076 (c_finish_omp_atomic): Add swapped argument.
6077 (c_finish_omp_for): Add code argument.
6078 (c_omp_split_clauses): New prototype.
6079 (c_split_parallel_clauses): Removed.
6080 (c_omp_declare_simd_clauses_to_numbers,
6081 c_omp_declare_simd_clauses_to_decls): New prototypes.
6082 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
6083 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
6084 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
6085 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
6086 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
6087 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
6088 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
6089 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
6090 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
6091 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
6092 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
6093 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
6094 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
6095 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
6096 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
6097 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
6098 PRAGMA_OMP_CLAUSE_UNIFORM.
6099
826cacfe
MG
61002013-10-09 Marc Glisse <marc.glisse@inria.fr>
6101
6102 PR tree-optimization/20318
6103 * c-common.c (handle_returns_nonnull_attribute): New function.
6104 (c_common_attribute_table): Add returns_nonnull.
6105
2284b034
MG
61062013-10-03 Marc Glisse <marc.glisse@inria.fr>
6107
6108 PR c++/19476
6109 * c.opt (fcheck-new): Move to common.opt.
6110
b56e9788
MP
61112013-09-25 Marek Polacek <polacek@redhat.com>
6112 Jakub Jelinek <jakub@redhat.com>
6113
6114 PR sanitizer/58413
6115 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
6116 an expression if we can prove it is correct.
6117 (ubsan_instrument_division): Likewise. Remove unnecessary
6118 check.
6119
ce6923c5
MP
61202013-09-18 Marek Polacek <polacek@redhat.com>
6121
6122 PR sanitizer/58411
6123 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
6124 Declare it.
6125 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
6126
fb5610fb
IS
61272013-09-14 Iain Sandoe <iain@codesourcery.com>
6128
6129 PR target/48094
6130 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
6131 fobjc-gc, freplace-objc-classes): Accept for LTO.
6132
88b0e79e
JC
61332013-09-13 Jacek Caban <jacek@codeweavers.com>
6134
6135 * c-target.def: New hook
6136
c9b0866a
PC
61372013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
6138
6139 PR c++/43452
6140 * c.opt (Wdelete-incomplete): Add.
6141
0af94e6f
JR
61422013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
6143
6144 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
6145 (vector_types_compatible_elements_p): New function.
6146 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
6147 declaration.
6148 (vector_types_compatible_elements_p): Declare.
6149
7c26172c
GDR
61502013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
6151
6152 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
6153 a virtual member function.
6154 (pp_simple_type_specifier): Remove.
6155 (pp_c_type_specifier): Likewise.
6156 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
6157 Rename from pp_c_type_specifier. Adjust.
6158 (c_pretty_printer::c_pretty_printer): Do not assign to
6159 simple_type_specifier.
6160
20059c8b
GDR
61612013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6162
6163 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
6164 member function.
6165 (c_pretty_printer::storage_class_specifier): Likewise.
6166 (c_pretty_printer::initializer): Likewise.
6167 (pp_declaration): Remove.
6168 (pp_declaration_specifiers): Likewise.
6169 (pp_abstract_declarator): Likewise.
6170 (pp_declarator): Likewise.
6171 (pp_type_id): Likewise.
6172 (pp_statement): Likewise.
6173 (pp_constant): Likewise.
6174 (pp_id_expression): Likewise.
6175 (pp_primary_expression): Likewise.
6176 (pp_unary_expression): Likewise.
6177 (pp_multiplicative_expression): Likewise.
6178 (pp_conditional_expression): Likewise.
6179 (pp_assignment_expression): Likewise.
6180 (pp_expression): Likewise.
6181 (pp_c_type_id): Likewise.
6182 (pp_c_storage_class_specifier): Likewise.
6183 * c-pretty-print.c (pp_c_type_cast): Tidy.
6184 (pp_c_pointer): Likewise.
6185 (pp_c_type_specifier): Likewise.
6186 (pp_c_parameter_type_list): Likewise.
6187 (pp_c_function_definition): Likewise.
6188 (pp_c_init_declarator): Likewise.
6189 (pp_c_initializer_list): Likewise.
6190 (pp_c_constructor_elts): Likewise.
6191 (c_pretty_printer::direct_abstract_declarator): Likewise.
6192 (c_pretty_printer::declaration_specifiers): Likewise.
6193 (c_pretty_printer::primary_expression): Likewise.
6194 (c_pretty_printer::postfix_expression): Likewise.
6195 (c_pretty_printer::type_id): Rename from pp_c_type_id.
6196 (c_pretty_printer::storage_class_specifier): Rename from
6197 pp_c_storage_class_specifier.
6198 (c_pretty_printer::initializer): Rename from pp_c_initializer.
6199 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
6200 storage_class_specifier, initializer, offset_list, flags.
6201
de5a5fa1
MP
62022013-08-30 Marek Polacek <polacek@redhat.com>
6203
6204 * c-ubsan.c: New file.
6205 * c-ubsan.h: New file.
6206
8f0e4d72
GDR
62072013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
6208
6209 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
6210 member function.
6211 (c_pretty_printer::declaration_specifiers): Likewise.
6212 (c_pretty_printer::declarator): Likewise.
6213 (c_pretty_printer::abstract_declarator): Likewise.
6214 (c_pretty_printer::direct_abstract_declarator): Likewise.
6215 (c_pretty_printer::direct_declarator): Likewise.
6216 (c_pretty_printer::function_specifier): Likewise.
6217 (pp_declaration): Adjust.
6218 (pp_declaration_specifiers): Likewise.
6219 (pp_abstract_declarator): Likewise.
6220 (pp_direct_declarator): Likewise.
6221 (pp_function_specifier): Likewise.
6222 (pp_direct_abstract_declarator): Remove as unused.
6223 (pp_c_declaration): Remove.
6224 (pp_c_declaration_specifiers): Likewise.
6225 (pp_c_declarator): Likewise.
6226 (pp_c_direct_declarator): Likewise.
6227 (pp_c_function_specifier): Likewise.
6228 (pp_c_direct_abstract_declarator): Likewise.
6229 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
6230 from pp_c_abstract_declarator. Adjust.
6231 (c_pretty_printer::direct_abstract_declarator): Rename from
6232 pp_c_direct_abstract_declarator. Adjust.
6233 (c_pretty_printer::function_specifier): Rename from
6234 pp_c_function_specifier. Adjust.
6235 (c_pretty_printer::declaration_specifiers): Rename from
6236 pp_c_declaration_specifiers. Adjust.
6237 (c_pretty_printer::direct_declarator): Rename from
6238 pp_c_direct_declarator. Adjust.
6239 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
6240 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
6241 (c_pretty_printer::c_pretty_printer): Do not assign to
6242 declaration, declaration_specifiers, declarator,
6243 direct_declarator, direct_abstract_declarator, function_specifier.
6244
00d34d3a
GDR
62452013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
6246
6247 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
6248 virtual member function.
6249 (c_pretty_printer::multiplicative_expression): Likewise.
6250 (c_pretty_printer::conditional_expression): Likewise.
6251 (c_pretty_printer::assignment_expression): Likewise.
6252 (c_pretty_printer::expression): Likewise.
6253 (pp_unary_expression): Adjust.
6254 (pp_multiplicative_expression): Likewise.
6255 (pp_assignment_expression): Likewise.
6256 (pp_conditional_expression): Likewise.
6257 (pp_expression): Likewise.
6258 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
6259 from pp_c_unary_expression. Adjust.
6260 (c_pretty_printer::multiplicative_expression): Rename from
6261 pp_c_multiplicative_expression. Adjust.
6262 (c_pretty_printer::conditional_expression): Rename from
6263 pp_c_conditional_expression. Adjust.
6264 (c_pretty_printer::assignment_expression): Rename from
6265 pp_c_assignment_expression. Adjust.
6266 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
6267 (c_pretty_printer::c_pretty_printer): Do not assign to
6268 unary_expression, multiplicative_expression,
6269 conditional_expression, expression.
6270
fb22178f
GDR
62712013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
6272
6273 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
6274 virtual member function.
6275 (pp_postfix_expression): Adjust.
6276 (pp_c_postfix_expression): Remove.
6277 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
6278 from pp_c_postfix_expression. Adjust.
6279 (c_pretty_printer::c_pretty_printer): Do not assign to
6280 postfix_expression.
6281
7ecc2600
GDR
62822013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
6283
6284 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
6285 virtua member function.
6286 (pp_primary_expression): Adjust.
6287 (pp_c_primary_expression): Remove.
6288 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
6289 from pp_c_primary_expression. Adjust.
6290 (pp_c_initializer_list): Use pp_primary_expression.
6291 (c_pretty_printer::c_pretty_printer): Do not assign to
6292 primary_expression.
6293
0691175f
GDR
62942013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
6295
6296 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
6297 * c-pretty-print.c (M_): Remove.
6298 (c_pretty_printer::translate_string): Define.
6299 (pp_c_type_specifier): Use it.
6300 (pp_c_primary_expression): Likewise.
6301 (pp_c_expression): Likewise.
6302
66dfe4c4
GDR
63032013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
6304
6305 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
6306 virtual function.
6307 (pp_c_id_expression): Remove.
6308 (pp_id_expression): Adjust.
6309 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
6310 pp_c_id_expression. Adjust.
6311 (pp_c_postfix_expression): Use pp_id_expression.
6312 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
6313
ca43e9d5
GDR
63142013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
6315
6316 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
6317 member function.
6318 (pp_constant): Adjust.
6319 (pp_c_constant): Remove.
6320 * c-pretty-print.c (c_pretty_printer::constant): Rename from
6321 pp_c_constant. Adjust.
6322 (pp_c_constant)
6323 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
6324 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
6325
da6ca2b5
GDR
63262013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
6327
6328 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
6329 (c_pretty_printer::c_pretty_printer): Declare.
6330 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
6331 c_pretty_printer_init. Adjust.
6332 (print_c_tree): Do not call c_pretty_printer_init.
6333 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
6334
65a372f4
AC
63352013-08-09 Arnaud Charlet <charlet@adacore.com>
6336
6337 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
6338
fd9b0f32
PC
63392013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
6340
6341 PR c++/58080
6342 * c-common.c (pointer_int_sum): Add bool parameter.
6343 * c-common.h (pointer_int_sum): Adjust declaration.
6344
e0aec1e9
GDR
63452013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
6346
6347 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
6348 c_pretty_printer variable.
6349
b066401f
GDR
63502013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
6351
6352 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
6353 (pp_base): Remove.
6354 (pp_c_base): Likewise. Adjust users.
6355 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
6356 (pp_c_whitespace): Do not call pp_base.
6357 (pp_c_left_paren): Likewise.
6358 (pp_c_right_paren): Likewise.
6359 (pp_c_left_brace): Likewise.
6360 (pp_c_right_brace): Likewise.
6361 (pp_c_left_bracket): Likewise.
6362 (pp_c_right_bracket): Likewise.
6363 (pp_c_dot): Likewise.
6364 (pp_c_ampersand): Likewise.
6365 (pp_c_star): Likewise.
6366 (pp_c_arrow): Likewise.
6367 (pp_c_semicolon): Likewise.
6368 (pp_c_complement): Likewise.
6369 (pp_c_exclamation): Likewise.
6370 (pp_c_direct_declarator): Likewise.
6371 (pp_c_ws_string): Likewise.
6372 (pp_c_identifier): Likewise.
6373 (pp_c_statement): Likewise.
6374 (print_c_tree): Likewise.
6375
65e5a578
ESR
63762013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
6377
6378 PR c++/58072
6379 * c-common.c (c_parse_error): Catch user-defined literal tokens and
6380 provide useful error strings.
6381
137a1a27
GDR
63822013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6383
6384 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
6385 printer functions instead of pp_string or operators and punctuators.
6386 (dump_generic_ada_node): Likewise.
6387 * c-pretty-print.c (pp_c_type_specifier): Likewise.
6388 (pp_c_relational_expression): Likewise.
6389 (pp_c_logical_or_expression): Likewise.
6390
07838b13
GDR
63912013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6392
6393 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
6394 functions instead of pp_character.
6395 (pp_ada_tree_identifier): Likewise.
6396 (dump_ada_double_name): Likewise.
6397 (dump_ada_function_declaration): Likewise.
6398 (dump_ada_array_domains): Likewise.
6399 (dump_template_types): Likewise.
6400 (dump_generic_ada_node): Likewise.
6401 (print_ada_declaration): Likewise.
6402 (print_ada_struct_decl): Likewise.
6403 * c-pretty-print.c (pp_c_integer_constant): Likewise.
6404
433cc7b0
TT
64052013-07-23 Tom Tromey <tromey@redhat.com>
6406
6407 * c-common.h (enum rid) <RID_GENERIC>: New constant.
6408 * c-common.c (c_common_reswords): Add _Generic.
6409
688010ba
OB
64102013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
6411
6412 * c-common.c: Fix typos.
6413 * c-common.h: Likewise.
6414
2a99e5e6
LL
64152013-07-13 Lubos Lunak <l.lunak@suse.cz>
6416
6417 PR c++/55203
6418 * c-common.c (c_common_attribute_table): Add warn_unused.
6419 (handle_warn_unused_attribute): New.
6420
c26302d5
JJ
64212013-07-10 Jakub Jelinek <jakub@redhat.com>
6422
6423 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
6424 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
6425
dfeadaa0
PC
64262013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
6427
6428 PR c++/57869
6429 * c.opt: Add Wconditionally-supported.
6430
6a2fa4b2
GS
64312013-07-08 Graham Stott <graham.stott@btinternet.com>
6432
adfac8df 6433 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6a2fa4b2
GS
6434 unused variables l_length and l_node.
6435
ecdbd01a 64362013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
6437
6438 PR c/57821
6439 * c-common.c (complete_array_type): Delay folding first index
6440 like other indices. When folding, check for index overflow.
6441
bedc293e
MG
64422013-06-27 Marc Glisse <marc.glisse@inria.fr>
6443
6444 PR c++/57509
6445 * c-common.h (c_build_vec_perm_expr): New complain argument.
6446 * c-common.c (c_build_vec_perm_expr): Likewise.
6447 Use save_expr also in C++.
6448
604b2bfc
GDR
64492013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
6450
6451 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
6452 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
6453 * c-opts.c (c_common_post_options): Likewise.
6454
dfeadaa0 64552013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
713b46fa
BI
6456
6457 * array-notation-common.c (length_mismatch_in_expr): Changed the
6458 parameter type's from a dynamic array to a vec_tree. Also removed
6459 the size parameters.
6460 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
6461 the change above.
6462
2ce86d2e
BI
64632013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
6464
6465 * c-common.h (struct cilkplus_an_parts): New structure.
6466 (struct cilkplus_an_loop_parts): Likewise.
6467 (cilkplus_extract_an_triplets): New prototype.
6468 (fix_sec_implicit_args): Likewise.
6469 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
6470 (fix_sec_implicit_args): Likewise.
604b2bfc 6471
07a6825b
BI
64722013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
6473
6474 * array-notation-common.c (find_inv_trees): Removed an unwanted
6475 typecasting.
6476 * c-common.h (struct inv_list::additional_tcodes): Changed type from
6477 enum rid to enum tree_code.
6478
08346abd
JH
64792013-06-11 Jan Hubicka <jh@suse.cz>
6480
6481 * c-common.c (handle_alias_ifunc_attribute): Do not set
6482 DECL_EXTERNAL for weakref variables.
6483 * c-pragma.c (handle_pragma_weak): Make sure aliases
6484 are not declared as external.
6485
d60f1706
BI
64862013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
6487
6488 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
6489 function from c/c-array-notation.c.
6490 (is_cilkplus_reduce_builtin): Likewise.
6491 (find_rank): Likewise.
6492 (extract_array_notation_exprs): Likewise.
6493 (replace_array_notations): Likewise.
6494 (find_inv_trees): Likewise.
6495 (replace_inv_trees): Likewise.
6496 (contains_array_notation_expr): Likewise.
6497 (find_correct_array_notation_type): Likewise.
6498 * c-common.h (struct inv_list): Moved this struct from the file
6499 c/c-array-notation.c and added a new field called additional tcodes.
6500 (length_mismatch_in_expr_p): New prototype.
6501 (is_cilkplus_reduce_builtin): Likewise.
6502 (find_rank): Likewise.
6503 (extract_array_notation_exprs): Likewise.
6504 (replace_array_notation): Likewise.
6505 (find_inv_trees): Likewise.
6506 (replace_inv_trees): Likewise.
6507 (find_correct_array_notation_type): Likewise.
dfeadaa0 6508
36536d79
BI
65092013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
6510
6511 * c-common.c (c_define_builtins): When cilkplus is enabled, the
6512 function array_notation_init_builtins is called.
6513 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
6514 * c-common.def (ARRAY_NOTATION_REF): New tree.
6515 * c-common.h (build_array_notation_expr): New function declaration.
6516 (build_array_notation_ref): Likewise.
6517 (extract_sec_implicit_index_arg): New extern declaration.
6518 (is_sec_implicit_index_fn): Likewise.
6519 (ARRAY_NOTATION_CHECK): New define.
6520 (ARRAY_NOTATION_ARRAY): Likewise.
6521 (ARRAY_NOTATION_START): Likewise.
6522 (ARRAY_NOTATION_LENGTH): Likewise.
6523 (ARRAY_NOTATION_STRIDE): Likewise.
6524 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
6525 ARRAY_NOTATION_REF.
6526 (pp_c_expression): Likewise.
6527 * c.opt (flag_enable_cilkplus): New flag.
6528 * array-notation-common.c: New file.
6529
f7716d57
JJ
65302013-05-14 Jakub Jelinek <jakub@redhat.com>
6531
6532 PR c++/57274
6533 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
6534
a5e0cd1d
MG
65352013-05-10 Marc Glisse <marc.glisse@inria.fr>
6536
6537 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
6538 vectors.
6539
f6bc1c4a
HS
65402013-05-07 Han Shen <shenhan@google.com>
6541
6542 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
6543
3f12f6e9
SKS
65442013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
6545
6546 * c-common.c (check_user_alignment): Emit error for negative values.
6547
61949153
PC
65482013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
6549
6550 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
6551
e93e18e9
PC
65522013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
6553
6554 * c-cppbuiltin.c (c_cpp_builtins): Do not define
6555 __GXX_EXPERIMENTAL_CXX1Y__.
6556
44d90fe1 65572013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
8e745a17 6558 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
44d90fe1
PC
6559
6560 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
6561 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
6562 to simply use OPT_Wpointer_arith.
6563 (c_sizeof_or_alignof_type): Likewise.
6564
13f39b2e
PC
65652013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
6566
6567 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
6568
4b84d650
JJ
65692013-04-12 Jakub Jelinek <jakub@redhat.com>
6570
6571 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
6572 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
6573 specifiers.
6574
fb037b5d
SB
65752013-04-07 Steven Bosscher <steven@gcc.gnu.org>
6576
6577 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
6578
4e856798
PC
65792013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
6580
6581 * c-common.c (pointer_int_sum): Remove dead code.
6582
4b1baac8
RS
65832013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
6584
6585 PR middle-end/56524
6586 * c-common.c (handle_optimize_attribute): Don't call
6587 save_optabs_if_changed.
6588
0b50e654
JJ
65892013-03-05 Jakub Jelinek <jakub@redhat.com>
6590
6591 PR middle-end/56461
6592 * c-pch.c (pch_init): Free target_validity at the end.
6593
48c41403
JJ
65942013-03-04 Jakub Jelinek <jakub@redhat.com>
6595
6596 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
6597
e664c61c
KS
65982013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
6599 Jakub Jelinek <jakub@redhat.com>
6600
6601 PR sanitizer/56454
6602 * c-common.c (handle_no_sanitize_address_attribute): New function.
6603 (c_common_attribute_table): Add no_sanitize_address attribute.
6604 (handle_no_address_safety_analysis_attribute): Add
6605 no_sanitize_address attribute, not no_address_safety_analysis
6606 attribute.
6607
a475fd3d 66082013-02-18 Aldy Hernandez <aldyh@redhat.com>
135204dd
AH
6609
6610 PR target/52555
6611 * c-common.c (handle_optimize_attribute): Call
6612 save_optabs_if_changed.
6613
f6007d99
JJ
66142013-02-18 Jakub Jelinek <jakub@redhat.com>
6615 Steven Bosscher <steven@gcc.gnu.org>
6616
6617 PR pch/54117
6618 * c-opts.c (c_common_post_options): If debug info is enabled
6619 and non-dwarf*, refuse to load PCH files and when writing PCH
6620 file warn.
6621
cf35e2b1
JJ
66222013-02-05 Jakub Jelinek <jakub@redhat.com>
6623
6624 PR middle-end/56167
6625 * c-common.c (handle_error_attribute): Fix condition.
6626
32887460
JJ
66272013-01-30 Jakub Jelinek <jakub@redhat.com>
6628
6629 PR c++/55742
6630 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
6631
5af057d8
JM
66322013-01-18 Jason Merrill <jason@redhat.com>
6633
6634 PR target/54908
6635 * c.opt (-fextern-tls-init): New.
6636 * c-opts.c (c_common_post_options): Handle it.
6637
cc83c823
JJ
66382013-01-09 Jakub Jelinek <jakub@redhat.com>
6639
6640 PR c/48418
6641 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
6642 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
6643 and is either negative or bigger or equal to type precision
6644 of the first operand.
6645
a859517f
MP
66462012-12-03 Marek Polacek <polacek@redhat.com>
6647
6648 PR c/55570
6649 * c-common.c (check_user_alignment): Swap order of tests,
6650 check TREE_CODE first.
6651
2d7aa578
ESR
66522012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
6653
6654 PR c++/52654
6655 * c-common.h (overflow_type): New enum.
6656 (build_userdef_literal): Add overflow_type argument.
6657 (tree_userdef_literal): Add overflow_type.
6658 (USERDEF_LITERAL_OVERFLOW): New access macro.
6659 * c-common.c (build_userdef_literal): Add overflow_type
6660 argument.
6661 * c-lex.c (c_lex_with_flags): Add overflow_type to
6662 build_userdef_literal calls.
6663 (interpret_integer, interpret_float): Add overflow_type argument.
6664
cc3c4f62
RB
66652012-11-28 Richard Biener <rguenther@suse.de>
6666
6667 PR c/35634
6668 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
6669 here and use a type with proper overflow behavior for types that would
6670 need to be promoted for the arithmetic.
6671
77bc5132
JJ
66722012-11-23 Jakub Jelinek <jakub@redhat.com>
6673
6674 PR sanitizer/55435
6675 * c-common.c (handle_no_address_safety_analysis_attribute): New
6676 function.
6677 (c_common_attribute_table): Add no_address_safety_analysis.
6678
5dc99c46
SB
66792012-11-16 Simon Baldwin <simonb@google.com>
6680
6681 * c.opt: Add f[no-]canonical-system-headers.
6682 * c-opts.c (c_common_handle_option): Handle
6683 OPT_fcanonical_system_headers.
6684
a4a0016d
ESR
66852012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
6686
6687 PR c++/54413
6688 * c-opts.c (c_common_handle_option): Set new flags.
6689 * c.opt: Describe new flags.
6690
7dbb85a7
JM
66912012-11-09 Jason Merrill <jason@redhat.com>
6692
6693 * c.opt (Wabi-tag): New.
6694
ad7bac31
AK
66952012-11-09 Andi Kleen <ak@linux.intel.com>
6696
6697 PR 55139
6698 * c-common.c (get_atomic_generic_size): Mask with
8e745a17 6699 MEMMODEL_MASK
ad7bac31 6700
7332899a
MLI
67012012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
6702
6703 PR c/53063
6704 * c.opt (Wformat): Make it Alias Wformat=1.
6705 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
6706 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
6707 LangEnabledBy.
6708 (Wformat=): RejectNegative. Use LangEnabledBy.
6709 (Wnonnull): Use LangEnabledBy.
6710 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
6711 * c-format.c (set_Wformat): Delete.
6712 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
8e745a17
JJ
6713 (maybe_read_dollar_number): Likewise.
6714 (avoid_dollar_number): Likewise.
6715 (finish_dollar_format_checking): Likewise.
6716 (check_format_info): Likewise.
6717 (check_format_info_main): Likewise.
6718 (check_format_types): Likewise.
6719 (format_type_warning): Likewise.
6720 * c-common.c (int): Likewise.
6721 (check_function_sentinel): Likewise.
6722 * c-common.h (warn_format,set_Wformat): Do not declare here.
7332899a 6723
34a180a6
MLI
67242012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
6725
6726 PR c/53063
6727 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
6728 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
6729 Use LangEnabledBy.
6730 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
6731 common.opt.
6732 (Wvariadic-macros): Init(1).
6733 * c-opts.c (c_common_handle_option): Do not handle them
6734 explicitly.
6735 (c_common_post_options): Likewise.
6736 (sanitize_cpp_opts): warn_unused_macros is now
6737 cpp_warn_unused_macros.
6738 (push_command_line_include): Likewise.
6739 * c-common.c (warn_unknown_pragmas): Do not define.
6740 * c-common.h (warn_unknown_pragmas): Do not declare.
6741
3f46d6a5
MLI
67422012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
6743
6744 PR c/51294
6745 * c-common.c (conversion_warning): Handle conditional expressions.
6746
880661a4
JW
67472012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
6748
6749 PR c++/54930
6750 * c.opt (Wreturn_local_addr): Define new option.
6751
4514a96b
JM
67522012-10-25 Jason Merrill <jason@redhat.com>
6753
f14edc1a
JM
6754 * c.opt (Wvirtual-move-assign): New.
6755
4514a96b
JM
6756 * c.opt (Winherited-variadic-ctor): New.
6757
93100c6b
MG
67582012-10-25 Marc Glisse <marc.glisse@inria.fr>
6759
6760 PR c++/54427
6761 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
6762
1efcb8c6
JM
67632012-10-23 Joseph Myers <joseph@codesourcery.com>
6764
6765 * c-common.h (pch_cpp_save_state): Declare.
6766 * c-target.def (c_preinclude): New hook.
6767 * c-opts.c (done_preinclude): New.
6768 (push_command_line_include): Handle default preincluded header.
6769 (cb_file_change): Call pch_cpp_save_state when calling
6770 push_command_line_include.
6771 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
6772 (pch_cpp_save_state): New.
6773 (pch_init): Call pch_cpp_save_state conditionally, instead of
6774 calling cpp_save_state.
6775
4a0ae68e
MLI
67762012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
6777
6778 PR c/53063
6779 PR c/40989
6780 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
6781 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
6782 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
6783 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
6784 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
6785 * c-opts.c (c_common_handle_option): Remove explicit handling from
6786 here.
6787 (c_common_post_options): Likewise.
6788
67e4210b
EB
67892012-10-18 Eric Botcazou <ebotcazou@adacore.com>
6790
6791 * c-ada-spec.c (LOCATION_COL): Delete.
6792 (compare_location): New function.
6793 (compare_node): Use it.
6794 (compare_comment): Likewise.
6795
65d4f2cd
MLI
67962012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
6797
6798 PR c/53063
6799 PR c/40989
6800 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
6801 * c-opts.c (c_common_handle_option): Do not set them here. Add
6802 comment.
6803 (c_common_post_options): Likewise.
6804
909881cb
EB
68052012-10-16 Eric Botcazou <ebotcazou@adacore.com>
6806
6807 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
6808 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
6809 Remove POINTER_TYPE handling, add large unsigned handling and use
6810 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
6811
3a785c97
JJ
68122012-10-12 Jakub Jelinek <jakub@redhat.com>
6813
6814 PR c/54381
6815 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
6816 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
6817 locs and array of 3 trees instead of just single loc and single
6818 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
6819 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
6820 For *cmp* builtins that take two sources strings report warnings
6821 about first and second source, not about destination and source.
6822
5e54f81d
MG
68232012-10-12 Marc Glisse <marc.glisse@inria.fr>
6824
6825 PR c++/53055
6826 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
6827
f5b02f1e
EB
68282012-10-11 Eric Botcazou <ebotcazou@adacore.com>
6829
6830 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
6831 declaring something coming from another file.
6832
b46dbc6c
AC
68332012-10-10 Arnaud Charlet <charlet@adacore.com>
6834
f5b02f1e 6835 PR ada/54845
b46dbc6c
AC
6836 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
6837
5d9de0d0
PC
68382012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
6839
6840 PR c++/54194
6841 * c-common.c (warn_about_parentheses): Add location_t parameter;
6842 use EXPR_LOC_OR_LOC.
6843 * c-common.h: Update declaration.
6844
a212e43f
MG
68452012-10-09 Marc Glisse <marc.glisse@inria.fr>
6846
6847 PR c++/54427
6848 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
6849 more operations. Make error messages optional.
6850 * c-common.h (enum stv_conv): Moved from c-typeck.c.
6851 (scalar_to_vector): Declare.
6852
b1db7f91
JM
68532012-10-08 Jason Merrill <jason@redhat.com>
6854
6855 * c-common.c (c_common_reswords): Add thread_local.
6856
e28d52cf
DS
68572012-10-08 Dodji Seketeli <dodji@redhat.com>
6858
6859 PR c++/53528 C++11 attribute support
6860 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
6861 new functions.
6862 * c-common.c (check_cxx_fundamental_alignment_constraints): New
6863 static function.
6864 (handle_aligned_attribute): In choose strictest alignment
6865 among many. Use new check_cxx_fundamental_alignment_constraints.
6866 (handle_transparent_union_attribute): In c++11 attribute syntax,
6867 don't look through typedefs.
6868
3b78de56
AC
68692012-10-04 Arnaud Charlet <charlet@adacore.com>
6870
6871 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
6872 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
6873 out of dumpfile.h.
6874
6040bb5f
DC
68752012-09-25 Dehao Chen <dehao@google.com>
6876
6877 PR middle-end/54645
3b78de56 6878 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
6040bb5f
DC
6879 map when read in the pch.
6880
3f8257db 68812012-09-18 Arnaud Charlet <charlet@adacore.com>
0b07a57e
AC
6882
6883 * c-ada-spec.c: Style fixes.
6884
3f8257db 68852012-09-18 Thomas Quinot <quinot@adacore.com>
da5182be
TQ
6886
6887 * c.opt (-fada-spec-parent): Define new command line switch.
6888 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
6889 is specified, generate binding spec as a child of the specified unit.
6890
0ccb505d
PC
68912012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
6892 Manuel López-Ibáñez <manu@gcc.gnu.org>
6893
6894 PR c++/53210
6895 * c.opt ([Winit-self]): Enabled by -Wall in C++.
6896
c583af79
AC
68972012-08-23 Arnaud Charlet <charlet@adacore.com>
6898
6899 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
6900 for pointers, and add missing Convention C pragma.
6901 (print_ada_struct_decl): Add missing aliased keyword.
6902 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
6903
1a4049e7
JJ
69042012-08-17 Jakub Jelinek <jakub@redhat.com>
6905
6906 * c-common.c (sizeof_pointer_memaccess_warning): New function.
6907 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
6908 * c-opts.c (c_common_handle_option): Enable it for -Wall.
6909 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
6910 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
6911
70b5e7dc
RG
69122012-08-10 Richard Guenther <rguenther@suse.de>
6913
6914 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
6915
f8923f7e
SB
69162012-08-07 Steven Bosscher <steven@gcc.gnu.org>
6917
6918 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
6919 instead of separate pp_newline and pp_flush.
6920 (print_c_tree): Likewise.
6921
e45abe1f
RH
69222012-07-26 Richard Henderson <rth@redhat.com>
6923
6924 * c-common.c (handle_hot_attribute): Allow labels.
6925 (handle_cold_attribute): Likewise.
6926
332f1d24
JJ
69272012-07-20 Jakub Jelinek <jakub@redhat.com>
6928
6929 PR c++/28656
6930 * c-common.c (check_function_nonnull): Handle multiple nonnull
6931 attributes properly.
6932
7ee2468b
SB
69332012-07-16 Steven Bosscher <steven@gcc.gnu.org>
6934
6935 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
6936 * c-ada-spec.c: Likewise.
6937 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
6938
ee7b28eb
SB
69392012-07-14 Steven Bosscher <steven@gcc.gnu.org>
6940
6941 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
6942 Remove code conditional on it.
6943
6bdf3519
SB
69442012-07-11 Steven Bosscher <steven@gcc.gnu.org>
6945
6946 * c-gimplify.c: Do not include basic-block.h.
6947 * c-common.c: Do not include linfuncs.h.
6948
532aafad
SB
69492012-07-08 Steven Bosscher <steven@gcc.gnu.org>
6950
6951 * c-common.h: Include tree.h.
6952
8d0d1915
JM
69532012-07-02 Jason Merrill <jason@redhat.com>
6954
6955 PR c++/53524
6956 * c-common.c (get_priority): Call default_conversion.
6957
fbc873ad
UB
69582012-07-01 Uros Bizjak <ubizjak@gmail.com>
6959
6960 * c-pch.c (c_common_write_pch): Remove unused variables.
6961
d4a10d0a
SB
69622012-06-29 Steven Bosscher <steven@gcc.gnu.org>
6963
6964 * cppspec.c: Moved from gcc/ to here.
6965
6f3a2e23
KT
69662012-06-27 Kai Tietz <ktietz@redhat.com>
6967
6968 PR preprocessor/37215
6969 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
6970
8ca92d04
SB
69712012-06-21 Steven Bosscher <steven@gcc.gnu.org>
6972
6973 * c-common.h (c_common_print_pch_checksum): Remove.
6974 * c-pch.c: Do not include output.h.
6975 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
6976 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
6977 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
6978 (struct c_pch_header): Remove.
6979 (get_ident): Update gpch version.
6980 (pch_init): Do not print executable_checksum to asm_out_file.
6981 Do not fail if there is no asm_out_file to read back from. Set
6982 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
6983 (c_common_write_pch): Verify that nothing was written to asm_out_file
6984 since pch_init was called. Do not write a c_pch_header, and do not
6985 copy from asm_out_file to the PCH.
6986 (c_common_read_pch): Do not read a c_pch_header, and do not restore
6987 the content of asm_out_file from the PCH.
6988 (c_common_print_pch_checksum): Remove.
6989 * c-opts.c (c_common_init): Print out executable_checksum directly.
6990
70f42967
SB
69912012-06-19 Steven Bosscher <steven@gcc.gnu.org>
6992
6993 * c-target.def (objc_declare_unresolved_class_reference,
6994 objc_declare_class_definition): Add new hooks.
6995
a8781821
SB
69962012-06-19 Steven Bosscher <steven@gcc.gnu.org>
6997
6998 * c-lex.c: Do not include output.h.
6999 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
7000 Remove uses of ASM_OUTPUT_IDENT.
7001
9e1a8dd1
RR
70022012-06-15 Marc Glisse <marc.glisse@inria.fr>
7003
7004 PR c++/51033
7005 * c-common.h (c_build_vec_perm_expr): Move decl here.
7006 * c-common.c (c_build_vec_perm_expr): Move definition
7007 here.
7008
6f07a821
SB
70092012-06-06 Steven Bosscher <steven@gcc.gnu.org>
7010
7011 * c.opt (fconserve-space): Turn into a no-op.
7012
9faeb493 70132012-06-04 Sterling Augustine <saugustine@google.com>
c265f413
SA
7014
7015 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
7016 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
7017 both the start and end of the function.
7018
a4b7d13c
SB
70192012-06-04 Steven Bosscher <steven@gcc.gnu.org>
7020
7021 * c-common.c: Do not include output.h.
7022 * c-pragma.c: Likewise.
7023
c265f413
SA
70242012-06-04 Steven Bosscher <steven@gcc.gnu.org>
7025
7026 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
7027 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
7028 (lang_decl_name): Handle namespace decls.
7029
be7a421e
SB
70302012-05-31 Steven Bosscher <steven@gcc.gnu.org>
7031
7032 * c-ada-spec.c: Do not include output.h.
7033 * c-semantics.c: Likewise.
7034
65de6659
JM
70352012-05-29 Joseph Myers <joseph@codesourcery.com>
7036
7037 * c-common.c: Fix typo.
7038
ca5f4331
MM
70392012-05-29 Michael Matz <matz@suse.de>
7040
7041 * c-common.h (c_expand_decl): Remove prototype.
7042
4f7f7aca
MLI
70432012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
7044
7045 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
7046 * c-opts.c (c_common_handle_option): Remove code handling
7047 warn_missing_braces.
7048
4a792f9b
PC
70492012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
7050
7051 PR c++/25137
7052 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
7053 -Wmissing_braces.
7054
650dc14a
DS
70552012-05-22 Dodji Seketeli <dodji@redhat.com>
7056
7057 PR c++/53322
7058 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
7059
9b095bf1
MLI
70602012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
7061
7062 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
7063 * c-opts.c (c_common_handle_option): Do not handle explicitly
7064 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
7065
0b2c4be5
DS
70662012-05-16 Dodji Seketeli <dodji@redhat.com>
7067
7068 PR preprocessor/7263
7069 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
7070 to cpp_classify_number. For diagnostics, use the precise location
7071 instead of the global input_location.
7072
a1bde5af
PC
70732012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
7074
d02924ef 7075 PR c++/11856
a1bde5af
PC
7076 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
7077
d1ede5f4
BS
70782012-05-14 Bernd Schmidt <bernds@codesourcery.com>
7079
a1bde5af 7080 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
d1ede5f4 7081
f2bc201f
MLI
70822012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
7083
7084 PR 53063
7085 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
7086 Wreorder): Use LangEnabledBy.
7087 * c-opts.c (c_common_handle_option): Do not enable them
7088 explicitly. Call lang-specific generated functions.
7089 (c_common_post_options): Do not set them here.
7090
95744782
MLI
70912012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
7092
7093 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
7094 Wmissing-field-initializers,Wmissing-parameter-type,
7095 Wold-style-declaration,Woverride-init): Use EnabledBy.
7096 * c-opts.c (c_common_post_options): Do not set here explicitly.
7097
7d5a5747
MLI
70982012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
7099
7100 PR 53063
7101 * c-opts.c (c_common_handle_option): Use handle_generated_option
7102 to enable sub-options.
7103
5a3c9cf2
PC
71042012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
7105
7106 PR c++/53158
7107 * c-common.c (warnings_for_convert_and_check): Use warning_at.
7108
3ac8781c
RG
71092012-05-10 Richard Guenther <rguenther@suse.de>
7110
7111 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
7112 adjust commentary about TYPE_IS_SIZETYPE types.
7113
1e537948
MLI
71142012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
7115
7116 PR c++/53261
7117 * c-common.c (warn_logical_operator): Check that argument of
7118 integer_zerop is not NULL.
7119
f2c4a785
MLI
71202012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
7121
7122 PR c/43772
7123 * c-common.c (warn_logical_operator): Do not warn if either side
7124 is already true or false.
7125
50f305ca
MLI
71262012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
7127
7128 PR c/51712
7129 * c-common.c (expr_original_type): New.
7130 (shorten_compare): Do not warn for enumeration types.
7131
0c3641b0
MLI
71322012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
7133
7134 * c.opt (fpermissive): Add Var(flag_permissive).
7135
7edaa4d2
MG
71362012-04-30 Marc Glisse <marc.glisse@inria.fr>
7137
7138 PR c++/51033
7139 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
7140 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
7141
b9c8da34
DS
71422012-04-30 Dodji Seketeli <dodji@redhat.com>
7143
7144 Add -Wvarargs option
7145 * c.opt (Wvarargs): Define new option.
7146
e6c69da0
MLI
71472012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
7148
7149 * c-common.c (check_function_arguments): Replace
7150 Wmissing-format-attribute with Wsuggest-attribute=format.
7151
90137d8f
MLI
71522012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
7153
7154 * c.opt (Wsuggest-attribute=format): New. Alias of
7155 Wmissing-format-attribute.
7156 * c-format.c (decode_format_type): Replace
7157 Wmissing-format-attribute with Wsuggest-attribute=format.
7158 (check_function_format): Likewise.
7159
9faeb493 71602012-04-27 Ollie Wild <aaw@google.com>
7f5f5f98
OW
7161
7162 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
7163 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
7164 * c.opt: Add Wliteral-suffix.
7165
c1771a20
MLI
71662012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
7167
7168 PR c/44774
7169 * c.opt (Wpedantic): New.
7170 (pedantic): Alias Wpedantic.
7171 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
7172 (c_common_post_options): Likewise.
7173 (sanitize_cpp_opts): Likewise.
7174 * c-lex.c (interpret_float): Likewise.
7175 * c-format.c (check_format_types): Likewise.
7176 * c-common.c (pointer_int_sum): Likewise.
7177 (c_sizeof_or_alignof_type): Likewise.
7178 (c_add_case_label): Likewise.
7179 (c_do_switch_warnings): Likewise.
7180 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
7181
04b391c1
JM
71822012-04-15 Jason Merrill <jason@redhat.com>
7183
7184 PR c++/52818
7185 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
7186 (C_STD_NAME): Distinguish between C++98 and C++11.
7187
ac868f29
EB
71882012-04-11 Eric Botcazou <ebotcazou@adacore.com>
7189
7190 PR target/52624
7191 * c-common.h (uint16_type_node): Rename into...
7192 (c_uint16_type_node): ...this.
7193 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
7194 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
7195
fd4116f4
MLI
71962012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
7197
7198 * c-common.c (warn_if_unused_value): Move definition to here.
7199 * c-common.h (warn_if_unused_value): Move declaration to here.
7200
573ac65e
WB
72012012-03-23 William Bader <williambader@hotmail.com>
7202
7203 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
7204
552b8185
JM
72052012-03-20 Jason Merrill <jason@redhat.com>
7206
7207 * c-common.h (enum cxx_dialect): Add cxx1y.
7208 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
7209 test.
7210 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
7211 * c-opts.c (c_common_post_options): Likewise.
7212 (set_std_cxx1y): New.
7213 (c_common_handle_option): Call it.
7214 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
7215
04398fa8
PC
72162012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
7217
7218 PR c++/14710
7219 * c.opt ([Wuseless-cast]): Add.
7220
d2a12ae7
RG
72212012-03-16 Richard Guenther <rguenther@suse.de>
7222
7223 * c-pretty-print.c (pp_c_initializer_list): Adjust.
7224
a12bf402
MLI
72252012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
7226
7227 PR c++/44783
7228 * c.opt (ftemplate-backtrace-limit) Add.
7229
5c30094f
RO
72302012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7231
7232 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
7233 handling.
7234 * c-pragma.c (handle_pragma_extern_prefix): Remove.
7235 (init_pragma): Don't register extern_prefix.
7236
21fa2faf
RG
72372012-03-12 Richard Guenther <rguenther@suse.de>
7238
7239 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
7240 (builtin_type_for_size): Likewise.
7241
e3793c6f
JJ
72422012-02-13 Jakub Jelinek <jakub@redhat.com>
7243
7244 PR c++/52215
7245 * c-common.c (sync_resolve_params): Don't decide whether to convert
7246 or not based on TYPE_SIZE comparison, convert whenever arg_type
7247 is unsigned INTEGER_TYPE.
7248
93286335
PC
72492012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
7250
7251 PR c/52118
7252 * c.opt ([Wunused-local-typedefs]): Fix description.
7253
7a421706
MS
72542012-01-24 Mike Stump <mikestump@comcast.net>
7255
7256 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
7257 exactly.
7258
ba9b1f11
RG
72592012-01-18 Richard Guenther <rguenther@suse.de>
7260
7261 * c-opts.c (c_common_post_options): Reset LTO flags if
7262 we are about to generate a PCH.
7263
465406be
PC
72642012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
7265
7266 PR c++/51777
7267 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
7268 use pp_unsigned_wide_integer.
7269
aee15221
RG
72702012-01-10 Richard Guenther <rguenther@suse.de>
7271
7272 PR middle-end/51806
7273 * c-opts.c (c_common_handle_option): Move -Werror handling
7274 to language independent code.
7275
5720c0dc
RG
72762012-01-05 Richard Guenther <rguenther@suse.de>
7277
7278 PR middle-end/51764
7279 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
7280 from common.opt.
7281
73ac190a
PC
72822011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
7283
7284 PR c++/51316
7285 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
7286 of array types with an unknown bound.
7287
48b0b196
JM
72882011-12-20 Joseph Myers <joseph@codesourcery.com>
7289
7290 * c-common.c (flag_isoc99): Update comment to refer to C11.
7291 (flag_isoc1x): Change to flag_isoc11.
7292 * c-common.h (flag_isoc99): Update comment to refer to C11.
7293 (flag_isoc1x): Change to flag_isoc11.
7294 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
7295 C11.
7296 * c-opts.c (set_std_c1x): Change to set_std_c11.
7297 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
7298 Call set_std_c11.
7299 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
7300 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
7301 * c.opt (std=c1x): Change to std=c11. Document as non-draft
7302 standard.
7303 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
7304 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
7305 (std=gnu1x): Make alias of std=gnu11.
7306
d58d6eb5
JM
73072011-12-19 Jason Merrill <jason@redhat.com>
7308
7309 PR c++/51228
7310 * c-common.c (handle_transparent_union_attribute): Check the first
7311 field if the type is complete.
7312
b3908fcc
JW
73132011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
7314
7315 PR libstdc++/51365
7316 * c-common.c (RID_IS_FINAL): Add.
7317 * c-common.h (RID_IS_FINAL): Add.
7318
fea3ca91
IS
73192011-11-30 Iain Sandoe <iains@gcc.gnu.org>
7320
7321 * c.opt (fgnu-runtime): Provide full description.
7322 (fnext-runtime): Likewise.
7323 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
7324
62bad7cd
AM
73252011-11-28 Andrew MacLeod <amacleod@redhat.com>
7326
7327 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
7328 predefines in one place. Add LOCK_FREE predefines.
7329 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
7330 new func.
7331
c466c4ff
AM
73322011-11-24 Andrew MacLeod <amacleod@redhat.com>
7333
7334 PR c/51256
9faeb493 7335 * c-common.c (get_atomic_generic_size): Check for various error
c466c4ff 7336 conditions
9faeb493
UB
7337 (resolve_overloaded_atomic_exchange,
7338 resolve_overloaded_atomic_compare_exchange,
c466c4ff
AM
7339 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
7340 error_mark_node for error conditions.
9faeb493 7341
a5952633
RG
73422011-11-08 Richard Guenther <rguenther@suse.de>
7343
7344 PR middle-end/51010
7345 c-family/
7346
0a35513e
AH
73472011-11-07 Richard Henderson <rth@redhat.com>
7348 Aldy Hernandez <aldyh@redhat.com>
7349 Torvald Riegel <triegel@redhat.com>
7350
7351 Merged from transactional-memory.
7352
7353 * c-common.c (handle_tm_wrap_attribute,
7354 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
7355 (struct c_common_reswords): Added __transaction* keywords.
7356 (struct c_common_attribute_table): Added transaction* and tm_regparm
7357 attributes.
7358 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
7359 masks.
7360 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
7361 find_tm_attribute): Declare.
7362
6d87092d
JM
73632011-11-07 Jason Merrill <jason@redhat.com>
7364
7365 PR c++/35688
7366 * c-common.c, c-common.h: Revert yesterday's changes.
7367
8e7860a1
JM
73682011-11-06 Jason Merrill <jason@redhat.com>
7369
7370 PR c++/35688
7371 * c-common.c (decl_has_visibility_attr): Split out from...
7372 (c_determine_visibility): ...here.
7373 * c-common.h: Declare it.
7374
d19fa6b5
JM
73752011-11-06 Joseph Myers <joseph@codesourcery.com>
7376
7377 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
7378 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
7379 type.
7380 (check_user_alignment): New. Split out of
7381 handle_aligned_attribute. Disallow integer constants with
7382 noninteger types. Conditionally allow zero.
7383 (handle_aligned_attribute): Use check_user_alignment.
7384 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
7385
86951993
AM
73862011-11-06 Andrew MacLeod <amacleod@redhat.com>
7387 Richard Henderson <rth@redhat.com>
7388
7389 Merged from cxx-mem-model.
7390
7391 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
9faeb493 7392 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
86951993
AM
7393 parameters that are the same type size.
7394 (get_atomic_generic_size): New. Find size of generic
7395 atomic function parameters and do typechecking.
7396 (add_atomic_size_parameter): New. Insert size into parameter list.
7397 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
7398 either __atomic_exchange_n or external library call.
9faeb493 7399 (resolve_overloaded_atomic_compare_exchange): Restructure
86951993 7400 __atomic_compare_exchange to either _n variant or external library call.
9faeb493 7401 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
86951993
AM
7402 __atomic_load_n or an external library call.
7403 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
7404 __atomic_store_n or an external library call.
7405 (resolve_overloaded_builtin): Handle new __atomic builtins.
7406
cf9e9959
EB
74072011-11-04 Eric Botcazou <ebotcazou@adacore.com>
7408
7409 PR c++/50608
7410 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
7411 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
7412 <INDIRECT_REF>: Return the argument.
7413 <ARRAY_REF>: Remove special code for negative offset.
7414 Call fold_build_pointer_plus instead of size_binop.
7415 (fold_offsetof): Remove STOP_REF argument and adjust.
7416 * c-common.h (fold_offsetof_1): Declare.
7417 (fold_offsetof): Remove STOP_REF argument.
7418
25339f10
JM
74192011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
7420
7421 PR c++/50810
7422 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7423 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7424 Wnarrowing for C++0x and C++98.
7425 * c.opt ([Wnarrowing]): Update.
7426
89401152
PC
74272011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
7428
7429 PR c++/44277
7430 * c.opt: Add Wzero-as-null-pointer-constant.
7431
97e3ad20
JM
74322011-10-31 Jason Merrill <jason@redhat.com>
7433
15694fdd
JM
7434 * c.opt (-fdeduce-init-list): Off by default.
7435
97e3ad20
JM
7436 PR c++/50920
7437 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
7438 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
7439 and -Wc++11-compat.
7440 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
7441
fb9120e3
RAV
74422011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
7443
7444 PR c++/30066
7445 * c.opt (fvisibility-inlines-hidden): Description change.
7446
3ce4f9e4
ESR
74472011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
7448
7449 Implement C++11 user-defined literals.
7450 * c-common.c (build_userdef_literal): New.
7451 * c-common.def: New tree code.
7452 * c-common.h (tree_userdef_literal): New tree struct and accessors.
7453 * c-lex.c (interpret_float): Add suffix parm.
7454 (c_lex_with_flags): Build literal tokens.
7455
5f53c243
PC
74562011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
7457
7458 PR c++/50841
7459 Revert:
7460 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
7461
7462 PR c++/50810
7463 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7464 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7465 Wnarrowing for C++0x and C++98.
7466 * c.opt ([Wnarrowing]): Update.
7467
263734e1
PC
74682011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
7469
7470 PR c++/50810
7471 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
7472 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
7473 Wnarrowing for C++0x and C++98.
7474 * c.opt ([Wnarrowing]): Update.
7475
d2e312d7
PC
74762011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
7477
7478 PR c++/45385
7479 * c-common.c (conversion_warning): Remove code looking for
7480 artificial operands.
7481
d17687f6
DS
74822011-10-18 Dodji Seketeli <dodji@redhat.com>
7483
7484 PR bootstrap/50760
7485 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
9faeb493 7486 !NO_IMPLICIT_EXTERN_C.
d17687f6 7487
fc8396e9
PC
74882011-10-17 Michael Spertus <mike_spertus@symantec.com>
7489
7490 * c-common.c (c_common_reswords): Add __bases,
7491 __direct_bases.
7492 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
7493
74942011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
7495
7496 PR c++/50757
7497 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
7498
847e697a
TT
74992011-10-15 Tom Tromey <tromey@redhat.com>
7500 Dodji Seketeli <dodji@redhat.com>
7501
7502 * c.opt (fdebug-cpp): New option.
7503 * c-opts.c (c_common_handle_option): Handle the option.
7504 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
7505 output stream in parameter. Factorized from ...
7506 (maybe_print_line): ... this. Dump location debug information when
7507 -fdebug-cpp is in effect.
7508 (print_line_1): New static function. Takes an output stream in
7509 parameter. Factorized from ...
7510 (print_line): ... here. Dump location information when -fdebug-cpp
7511 is in effect.
7512 (scan_translation_unit): Dump location information when
7513 -fdebug-cpp is in effect.
7514
92582b75
TT
75152011-10-15 Tom Tromey <tromey@redhat.com>
7516 Dodji Seketeli <dodji@redhat.com>
7517
7518 * c.opt (ftrack-macro-expansion): New option. Handle it with and
7519 without argument.
7520 * c-opts.c (c_common_handle_option)<case
7521 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
7522 cases. Handle -ftrack-macro-expansion with and without argument.
7523
46427374
TT
75242011-10-15 Tom Tromey <tromey@redhat.com>
7525 Dodji Seketeli <dodji@redhat.com>
7526
7527 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
7528 (print_line, cb_define, do_line_change): Adjust to avoid touching
7529 the internals of struct line_map. Use the public API instead.
7530 * c-pch.c (c_common_read_pch): Likewise.
7531 * c-lex.c (fe_file_change): Likewise.
7532
fc8396e9
PC
75332011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
7534
7535 PR c++/17212
7536 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
7537
75382011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
7539
7540 PR c++/33067
7541 * c-pretty-print.c (pp_c_floating_constant): Output
7542 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
7543
e79983f4
MM
75442011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
7545
7546 * c-common.c (def_builtin_1): Delete old interface with two
7547 parallel arrays to hold standard builtin declarations, and replace
7548 it with a function based interface that can support creating
7549 builtins on the fly in the future. Change all uses, and poison
7550 the old names. Make sure 0 is not a legitimate builtin index.
7551 * c-omp.c (c_finish_omp_barrier): Ditto.
7552 (c_finish_omp_taskwait): Ditto.
7553 (c_finish_omp_flush): Ditto.
7554
6637388f
TG
75552011-10-11 Tristan Gingold <gingold@adacore.com>
7556
7557 * c.opt: (fallow-parameterless-variadic-functions): New.
7558
3797cb21
DS
75592011-09-08 Dodji Seketeli <dodji@redhat.com>
7560
7561 PR c++/33255 - Support -Wunused-local-typedefs warning
7562 * c-common.h (struct c_language_function::local_typedefs): New
7563 field.
9faeb493
UB
7564 (record_locally_defined_typedef, maybe_record_typedef_use)
7565 (maybe_warn_unused_local_typedefs): Declare new functions.
3797cb21 7566 * c-common.c (record_locally_defined_typedef)
9faeb493
UB
7567 (maybe_record_typedef_use)
7568 (maybe_warn_unused_local_typedefs): Define new functions.
3797cb21
DS
7569 * c.opt: Declare new -Wunused-local-typedefs flag.
7570
693ddb1b
EB
75712011-09-06 Eric Botcazou <ebotcazou@adacore.com>
7572
7573 PR middle-end/50266
7574 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
7575 computations.
7576
830c740f
RG
75772011-09-05 Richard Guenther <rguenther@suse.de>
7578
7579 * c-common.c (complete_array_type): Use ssize_int (-1) instead
7580 of integer_minus_one_node for empty array upper bounds.
7581
892a371f
DS
75822011-08-28 Dodji Seketeli <dodji@redhat.com>
7583
7584 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
7585 it's the first time it's being called on this main TU.
7586
0e3fdb48
RB
75872011-08-24 Richard Guenther <rguenther@suse.de>
7588
7589 PR c/49396
7590 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
7591
75922011-08-22 Gabriel Charette <gchare@google.com>
e3dfef44
GC
7593
7594 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
7595 defined in cpp_init_builtins and c_cpp_builtins.
7596
d4a83c10
JM
75972011-08-19 Joseph Myers <joseph@codesourcery.com>
7598
7599 * c-common.c (c_common_reswords): Add __builtin_complex.
7600 * c-common.h (RID_BUILTIN_COMPLEX): New.
7601
bbceee64
JM
76022011-08-18 Joseph Myers <joseph@codesourcery.com>
7603
7604 * c-common.c (c_common_reswords): Add _Noreturn.
7605 (keyword_is_function_specifier): Handle RID_NORETURN.
7606 * c-common.h (RID_NORETURN): New.
7607
3f8257db 76082011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
0e3a99ae
AS
7609
7610 * c-common.c (unsafe_conversion_p): New function. Check if it is
7611 unsafe to convert an expression to the type.
7612 (conversion_warning): Adjust, use unsafe_conversion_p.
7613 * c-common.h (unsafe_conversion_p): New function declaration.
7614
20906c66
JJ
76152011-08-02 Jakub Jelinek <jakub@redhat.com>
7616
7617 * c-common.h (c_finish_omp_atomic): Adjust prototype.
7618 (c_finish_omp_taskyield): New prototype.
7619 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
7620 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
7621 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
7622 or RHS1 have side-effects, evaluate those too in the right spot,
7623 if it is a decl and LHS is also a decl, error out if they
7624 aren't the same.
7625 (c_finish_omp_taskyield): New function.
7626 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
7627 * c-pragma.c (omp_pragmas): Add taskyield.
7628 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
7629 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
7630 PRAGMA_OMP_CLAUSE_MERGEABLE.
7631
770e5a2e
DS
76322011-07-25 Dodji Seketeli <dodji@redhat.com>
7633
7634 * c-common.h (set_underlying_type): Remove parm name from
7635 declaration.
7636
1baae426
RG
76372011-07-25 Romain Geissler <romain.geissler@gmail.com>
7638
7639 * c-pretty-print.h: Search c-common.h in c-family.
9faeb493 7640
fcb21722
JM
76412011-07-22 Jason Merrill <jason@redhat.com>
7642
76f86d00
JM
7643 PR c++/49793
7644 * c.opt (Wnarrowing): New.
7645
3a636414
JM
7646 PR c++/30112
7647 * c-common.h: Declare c_linkage_bindings.
7648 * c-pragma.c (handle_pragma_redefine_extname): Use it.
7649
fcb21722
JM
7650 PR c++/49813
7651 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
7652 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
7653 as flag_isoc99 for 'restrict'.
7654 (pp_c_specifier_qualifier_list): Likewise for _Complex.
7655
02614448
ILT
76562011-07-21 Ian Lance Taylor <iant@google.com>
7657
7658 PR middle-end/49705
7659 * c-common.c (c_disable_warnings): New static function.
7660 (c_enable_warnings): New static function.
7661 (c_fully_fold_internal): Change local unused_p to bool. Call
7662 c_disable_warnings and c_enable_warnings rather than change
7663 c_inhibit_evaluation_warnings.
7664
34429675
JM
76652011-07-20 Jason Merrill <jason@redhat.com>
7666
7667 PR c++/6709 (DR 743)
7668 PR c++/42603 (DR 950)
7669 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
7670 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
7671 (CPP_DECLTYPE): New.
7672 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
7673
5d49b6a7
RG
76742011-07-19 Richard Guenther <rguenther@suse.de>
7675
7676 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
7677 * c-omp.c (c_finish_omp_for): Likewise.
7678
e84a58ff
EB
76792011-07-12 Eric Botcazou <ebotcazou@adacore.com>
7680
7681 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
7682 body on the next line.
7683
329af3c7
JM
76842011-07-08 Jason Merrill <jason@redhat.com>
7685
4063e61b
JM
7686 PR c++/45437
7687 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
7688
329af3c7
JM
7689 PR c++/49673
7690 * c-common.c (c_apply_type_quals_to_decl): Don't check
7691 TYPE_NEEDS_CONSTRUCTING.
7692
1a072294
RG
76932011-07-06 Richard Guenther <rguenther@suse.de>
7694
7695 * c-common.c (c_common_nodes_and_builtins):
7696 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
7697
fce5dddd
RG
76982011-07-05 Richard Guenther <rguenther@suse.de>
7699
7700 * c-common.c (c_common_nodes_and_builtins): Build all common
7701 tree nodes first.
7702
45d439ac
JJ
77032011-06-27 Jakub Jelinek <jakub@redhat.com>
7704
56300785
JJ
7705 * c-common.h (c_tree_chain_next): New static inline function.
7706
45d439ac
JJ
7707 * c-common.c (check_builtin_function_arguments): Handle
7708 BUILT_IN_ASSUME_ALIGNED.
7709
e0a8ecf2
AM
77102011-06-21 Andrew MacLeod <amacleod@redhat.com>
7711
7712 * c-common.c: Add sync_ or SYNC__ to builtin names.
7713 * c-omp.c: Add sync_ or SYNC__ to builtin names.
dfb43cd5
PV
7714
77152011-06-20 Pierre Vittet <piervit@pvittet.com>
7716
7717 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
7718 handler.
7719 (gen_pragma_handler): New union.
7720 (internal_pragma_handler): New type.
7721 (c_register_pragma_with_data)
7722 (c_register_pragma_with_expansion_and_data): New functions.
7723
7724 * c-pragma.c (registered_pragmas, c_register_pragma_1)
7725 (c_register_pragma, c_register_pragma_with_expansion)
7726 (c_invoke_pragma_handler): Changed to work with
7727 internal_pragma_handler.
7728 (c_register_pragma_with_data)
7729 (c_register_pragma_with_expansion_and_data): New functions.
7730
677f3fa8
JM
77312011-06-14 Joseph Myers <joseph@codesourcery.com>
7732
7733 * c-common.c: Include common/common-target.h.
7734 (handle_section_attribute): Use
7735 targetm_common.have_named_sections.
7736 * c-cppbuiltin.c: Include common/common-target.h.
7737 (c_cpp_builtins): Use targetm_common.except_unwind_info.
7738
d7fc8c14
RG
77392011-06-10 Richard Guenther <rguenther@suse.de>
7740
7741 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
7742 to print a IDENTIFIER_NODE.
7743
10e48e39
RO
77442011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7745 Joseph Myers <joseph@codesourcery.com>
7746
7747 * c.opt (fbuilding-libgcc): New option.
7748 * c-cppbuiltin.c (c_cpp_builtins): Define
7749 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
7750
6976ae51
JM
77512011-06-07 Jason Merrill <jason@redhat.com>
7752
3ff60975
JM
7753 * c-common.c (max_tinst_depth): Lower default to 900.
7754
6976ae51
JM
7755 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
7756
009db074
RG
77572011-06-07 Richard Guenther <rguenther@suse.de>
7758
7759 * c-common.c (c_common_nodes_and_builtins): Do not set
7760 size_type_node or call set_sizetype.
7761
b4592b92
DS
77622011-06-07 Dodji Seketeli <dodji@redhat.com>
7763
7764 PR debug/49130
7765 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
9faeb493 7766 type when using pointer comparison to compare types.
b4592b92 7767
014ab419
JW
77682011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
7769
7770 * c.opt: Add -Wdelete-non-virtual-dtor.
7771 * c-opts.c (c_common_handle_option): Include it in -Wall.
7772
4f60111f
NF
77732011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
7774
7775 PR bootstrap/49190
7776
7777 Revert:
7778 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
7779
7780 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
7781 not tree_common.
7782
4cc4f2f4
JJ
77832011-05-27 Jakub Jelinek <jakub@redhat.com>
7784
7785 PR c++/49165
7786 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
7787 C++ don't call c_common_truthvalue_conversion on void type arms.
7788
38e01f9e
NF
77892011-05-27 Nathan Froyd <froydnj@codesourcery.com>
7790
7791 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
7792 (stmt_list_stack): Define.
7793 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
7794 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
7795
92e948a8
NF
77962011-05-26 Nathan Froyd <froydnj@codesourcery.com>
7797
7798 * c-common.c (warning_candidate_p): Check for BLOCKs.
7799
a2fc3e63
NF
78002011-05-26 Nathan Froyd <froydnj@codesourcery.com>
7801
7802 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
7803 not tree_common.
7804
0957c029
JJ
78052011-05-25 Jakub Jelinek <jakub@redhat.com>
7806
7807 * c-common.c (def_fn_type): Remove extra va_end.
7808
828fb3ba
JM
78092011-05-23 Jason Merrill <jason@redhat.com>
7810
7811 PR c++/48106
7812 * c-common.c (c_common_get_narrower): New.
7813 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
7814
dde05067
NF
78152011-05-23 Nathan Froyd <froydnj@codesourcery.com>
7816
7817 * c-common.h (check_function_arguments): Tweak prototype of
7818 check_function_arguments.
7819 * c-common.c (check_function_arguments): Likewise. Adjust
7820 calls to check_function_nonnull, check_function_format, and
7821 check_function_sentinel.
7822 (check_function_sentinel): Take a FUNCTION_TYPE rather than
7823 separate attributes and typelist arguments. Use
7824 FOREACH_FUNCTION_ARGS to iterate over argument types.
7825
3c0d13bf
PC
78262011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
7827
7828 * c-common.c (c_common_reswords): Reorder.
7829 * c-common.h (rid): Likewise.
7830
8242dd04
NF
78312011-05-10 Nathan Froyd <froydnj@codesourcery.com>
7832
7833 * c-common.c (def_fn_type): Don't call build_function_type, call
7834 build_function_type_array or build_varargs_function_type_array
7835 instead.
7836 (c_common_nodes_and_builtins): Likewise.
7837
3d528853
NF
78382011-05-05 Nathan Froyd <froydnj@codesourcery.com>
7839
7840 * c-common.c (c_add_case_label): Omit the loc argument to
7841 build_case_label.
7842 * c-common.h (build_case_label): Remove.
7843 * c-semantics.c (build_case_label): Remove.
7844
a04a722b
JM
78452011-05-05 Joseph Myers <joseph@codesourcery.com>
7846
7847 * c-objc.h (objc_start_method_definition): Update prototype.
7848 * stub-objc.c (objc_start_method_definition): Add extra parameter.
7849
e19a18d4
NF
78502011-05-04 Nathan Froyd <froydnj@codesourcery.com>
7851
7852 * c-common.c (check_main_parameter_types): Reindent. Don't use
7853 TYPE_ARG_TYPES directly.
7854 (handle_nonnull_attribute): Likewise.
7855 (sync_resolve_params): Likewise.
7856 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
7857 to check_format_string.
7858 (handle_format_attribute): Likewise.
7859 (check_format_string): Take a function type to examine instead of
7860 a type list. Use a function_arg_iterator to step through argument
7861 types.
7862
c62c040f
RG
78632011-05-04 Richard Guenther <rguenther@suse.de>
7864
7865 * c-common.c (fix_string_type): Use size_int for index type bounds.
7866 (start_fname_decls): Do not pass NULL to build_int_cst.
7867 (c_init_attributes): Likewise.
7868 * c-lex.c (c_lex_with_flags): Likewise.
7869
c12ff9d8
JM
78702011-04-27 Jason Merrill <jason@redhat.com>
7871
7872 * c-common.c (make_tree_vector_from_list): New.
7873 * c-common.h: Declare it.
7874
304dfbe3
RG
78752011-04-26 Richard Guenther <rguenther@suse.de>
7876
7877 PR preprocessor/48248
7878 * c-ppoutput.c (maybe_print_line): Always optimize newlines
7879 for output size with -P.
7880
3c0d13bf
PC
78812011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
7882
7883 * c-common.c (struct c_common_resword): Add __underlying_type.
7884 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
7885
04695783
JM
78862011-04-20 Jim Meyering <meyering@redhat.com>
7887
7888 * c-format.c (init_dollar_format_checking): Remove useless
7889 if-before-free.
7890
0dc33c3c
NP
78912011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
7892
7893 * c-objc.h (objc_get_interface_ivars): Removed.
3c0d13bf 7894 (objc_detect_field_duplicates): New.
0dc33c3c 7895 * stub-objc.c: Likewise.
3c0d13bf 7896
c59633d9
NP
78972011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
7898
7899 * stub-objc.c (objc_declare_protocols): Renamed to
7900 objc_declare_protocol.
7901 * c-objc.h: Likewise.
3c0d13bf 7902
32dabdaf
NP
79032011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
7904
7905 * stub-objc.c (objc_declare_class): Updated argument name.
7906
81f653d6
NF
79072011-04-12 Nathan Froyd <froydnj@codesourcery.com>
7908
7909 * c-common.h (c_common_init_ts): Declare.
7910 * c-common.c (c_common_init_ts): Define.
7911
eb345401
NP
79122011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
7913
7914 * c-objc.h (objc_build_message_expr): Updated prototype.
7915 * stub-objc.c (objc_build_message_expr): Likewise.
9faeb493 7916
a358e188
MJ
79172011-04-12 Martin Jambor <mjambor@suse.cz>
7918
7919 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
7920 of cgraph_node.
7921
e6313a78
RG
79222011-04-11 Richard Guenther <rguenther@suse.de>
7923
7924 * c-common.c (complete_array_type): Build a range type of
7925 proper type.
7926
dcf0c47e
NF
79272011-04-08 Nathan Froyd <froydnj@codesourcery.com>
7928
7929 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
7930 (handle_type_generic_attribute): Likewise.
7931
1ee44b26
JM
79322011-04-07 Jason Merrill <jason@redhat.com>
7933
7934 PR c++/48450
7935 * c-common.c (c_common_truthvalue_conversion): Don't ignore
7936 conversion from C++0x scoped enum.
7937
acce4e77
JM
79382011-04-06 Joseph Myers <joseph@codesourcery.com>
7939
7940 * c-target-def.h: New file.
7941 * c-target.def: New file.
7942 * c-target.h: New file.
7943 * c-common.c (targetcm): Don't define here.
7944 * c-common.h (default_handle_c_option): Declare.
7945 * c-format.c: Include c-target.h instead of target.h.
7946 * c-opts.c: Include c-target.h instead of target.h. Explicitly
7947 include tm.h.
7948 (default_handle_c_option): Move from targhooks.c.
7949
e2eefb55
JJ
79502011-03-29 Jakub Jelinek <jakub@redhat.com>
7951
7952 PR preprocessor/48248
7953 * c-ppoutput.c (print): Add src_file field.
7954 (init_pp_output): Initialize it.
7955 (maybe_print_line): Don't optimize by adding up to 8 newlines
7956 if map->to_file and print.src_file are different file.
7957 (print_line): Update print.src_file.
7958
ba78087b
KT
79592011-03-25 Kai Tietz <ktietz@redhat.com>
7960
7961 * c-ada-spec.c (compare_comment): Use filename_cmp
7962 instead of strcmp for filename.
7963
0edf1bb2
JL
79642011-03-25 Jeff Law <law@redhat.com>
7965
adfac8df 7966 * c-common.c (def_fn_type): Add missing va_end.
0edf1bb2 7967
c7dc8804
JM
79682011-03-25 Jason Merrill <jason@redhat.com>
7969
7970 * c.opt: Add -std=c++03.
7971
d1d879b1
EB
79722011-03-22 Eric Botcazou <ebotcazou@adacore.com>
7973
7974 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
7975
3f8257db 79762011-03-17 Kai Tietz <ktietz@redhat.com>
62d784f7
KT
7977
7978 PR target/12171
5050afdf
KT
7979 * c-pretty-print.c (pp_c_specifier_qualifier_list):
7980 Display allowed attributes for function pointer types.
7981 (pp_c_attributes_display): New function to display
7982 attributes having affects_type_identity flag set to true.
7983 * c-pretty-print.h (pp_c_attributes_display): New prototype.
7984
62d784f7
KT
7985 * c-common.c (c_common_attribute_table):
7986 Add new element.
7987 (c_common_format_attribute_table): Likewise.
7988
82d37118
JM
79892011-03-18 Jason Merrill <jason@redhat.com>
7990
49a000c3
JM
7991 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
7992 * c-common.h: Don't declare it here.
7993 * c-common.c: Or define it here.
7994 * c-opts.c (c_common_handle_option): Or set it here.
7995
82d37118
JM
7996 PR c++/35315
7997 * c-common.c (handle_transparent_union_attribute): Don't
7998 make a duplicate type in C++.
7999
17bc631c
JM
80002011-03-15 Jason Merrill <jason@redhat.com>
8001
8002 * c-common.c (max_constexpr_depth): New.
8003 * c-common.h: Declare it.
8004 * c-opts.c (c_common_handle_option): Set it.
8005 * c.opt (fconstexpr-depth): New option.
8006
1b9b91a6
JM
80072011-03-11 Jason Merrill <jason@redhat.com>
8008
f231b5ff
JM
8009 * c-common.c (attribute_takes_identifier_p): Add missing const.
8010
1b9b91a6
JM
8011 PR c++/46803
8012 * c-common.c (attribute_takes_identifier_p): Assume that an
8013 unknown attribute takes an identifier.
8014
a19e4d44
NF
80152011-03-07 Nathan Froyd <froydnj@codesourcery.com>
8016
8017 PR c/47786
8018 * c-common.c (c_type_hash): Call list_length instead of iterating
8019 through DECL_CHAIN. Rename 'i' to 'n_elements'.
8020
982d62f6
JJ
80212011-02-19 Jakub Jelinek <jakub@redhat.com>
8022
8023 PR c/47809
8024 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
8025
0a256240
NP
80262011-02-17 Iain Sandoe <iains@gcc.gnu.org>
8027
8028 * c.opt (fobjc-abi-version=) New.
8029 (fobjc-nilcheck): New.
8030
ba9e6dd5
NF
80312011-02-03 Nathan Froyd <froydnj@codesourcery.com>
8032
8033 PR c++/46890
8034 * c-common.h (keyword_is_decl_specifier): Declare.
8035 * c-common.c (keyword_is_decl_specifier): Define.
8036 (keyword_is_function_specifier): New function.
8037
7273813a
JJ
80382011-01-26 Jakub Jelinek <jakub@redhat.com>
8039
8040 PR c/47473
8041 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
8042 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
8043 REAL_TYPE.
8044
908ef79b
AC
80452011-01-26 Arnaud Charlet <charlet@adacore.com>
8046
8047 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
8048
237e9384
JJ
80492011-01-26 Jakub Jelinek <jakub@redhat.com>
8050
8051 PR pch/47430
8052 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
8053 after init_c_lex if pch_file is set.
8054
47ea1edf
DK
80552011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
8056
d4dba752 8057 PR c++/43601
47ea1edf
DK
8058 * c.opt (-fkeep-inline-dllexport): New switch.
8059
2aa9c6ae
RG
80602011-01-12 Richard Guenther <rguenther@suse.de>
8061
8062 PR middle-end/32511
8063 * c-common.c (handle_weak_attribute): Warn instead of error
8064 on declaring an inline function weak.
8065
7bd11157
TT
80662011-01-05 Tom Tromey <tromey@redhat.com>
8067
8068 * c-common.h (lvalue_error): Update.
8069 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
8070 not error.
8071
0e66e494 80722010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
9faeb493 8073
b4f588c4
NP
8074 PR objc/47075
8075 * c-objc.h (objc_finish_message_expr): Added argument to
8076 prototype.
8077
f4da8dce
NF
80782010-12-22 Nathan Froyd <froydnj@codesourcery.com>
8079
8080 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
8081 Use prototype_p.
8082
46270f14
NP
80832010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
8084
8085 * c-objc.h (objc_maybe_warn_exceptions): New.
9faeb493 8086 * stub-objc.c (objc_maybe_warn_exceptions): New.
46270f14 8087
4816c593
NF
80882010-12-10 Nathan Froyd <froydnj@codesourcery.com>
8089
8090 * c-common.h (readonly_error): Declare.
8091 * c-common.c (readonly_error): Define.
8092
7a6daeb0
NF
80932010-12-09 Nathan Froyd <froydnj@codesourcery.com>
8094
8095 * c-common.h (invalid_indirection_error): Declare.
8096 * c-common.c (invalid_indirection_error): Define.
8097
892f6119
RG
80982010-12-03 Richard Guenther <rguenther@suse.de>
8099
8100 PR c/46745
8101 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
8102 (pp_c_unary_expression): Likewise.
8103 (pp_c_expression): Likewise.
8104
6c39e757
NP
81052010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
8106
8107 * c-common.h (objc_finish_function): New.
8108 (objc_non_volatilized_type): Removed.
8109 (objc_type_quals_match): Removed.
8110 * stub-objc.c (objc_finish_function): New.
8111 (objc_non_volatilized_type): Removed.
8112 (objc_type_quals_match): Removed.
9faeb493 8113
7c475d11
JM
81142010-11-30 Joseph Myers <joseph@codesourcery.com>
8115
8116 * c-common.h (parse_optimize_options): Declare.
8117 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
8118 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
8119
71f3e391
JM
81202010-11-29 Joseph Myers <joseph@codesourcery.com>
8121
8122 * c-opts.c (check_deps_environment_vars): Use getenv instead of
8123 GET_ENVIRONMENT.
8124 * c-pch.c (O_BINARY): Don't define here.
8125 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
8126
d5fabb58
JM
81272010-11-25 Joseph Myers <joseph@codesourcery.com>
8128
8129 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
8130 targetm.except_unwind_info.
8131
299404a1
JM
81322010-11-23 Joseph Myers <joseph@codesourcery.com>
8133
8134 * c-opts.c (c_common_handle_option): Pass location to
8135 set_struct_debug_option.
8136
c98cd5bf
JM
81372010-11-23 Joseph Myers <joseph@codesourcery.com>
8138
8139 * c-common.c (visibility_options): Move from ../opts.c.
8140 * c-common.h (struct visibility_flags, visibility_options):
8141 Declare here.
8142 * c-opts.c (finish_options): Rename to c_finish_options.
8143 (c_common_init): Update call to finish_options.
8144
a9546771
NP
81452010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
8146
8147 PR objc/34033
8148 * c-lex.c (lex_string): Check that each string in an Objective-C
8149 string concat sequence starts with either one or zero '@', and
8150 that there are no spurious '@' signs at the end.
8151
24a57808
JM
81522010-11-20 Joseph Myers <joseph@codesourcery.com>
8153
8154 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
8155 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
8156 HANDLE_PRAGMA_VISIBILITY.
8157 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
8158 HANDLE_PRAGMA_VISIBILITY): Don't define.
8159 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
8160
a9aa2c3a
NF
81612010-11-20 Nathan Froyd <froydnj@codesourcery.com>
8162
8163 PR c++/16189
8164 PR c++/36888
8165 PR c++/45331
8166 * c-common.h (keyword_begins_type_specifier): Declare.
8167 (keyword_is_storage_class_specifier): Declare.
8168 (keyword_is_type_qualifier): Declare.
8169 * c-common.c (keyword_begins_type_specifier): New function.
8170 (keyword_is_storage_class_specifier): New function.
8171 (keyword_is_type_qualifier): Declare.
8172
5386338c
JM
81732010-11-19 Joseph Myers <joseph@codesourcery.com>
8174
8175 PR c/46547
8176 * c-common.c (in_late_binary_op): Define.
8177 (c_common_truthvalue_conversion): Check in_late_binary_op before
8178 calling c_save_expr.
8179 * c-common.h (in_late_binary_op): Declare.
8180
69ccdddb
JM
81812010-11-19 Joseph Myers <joseph@codesourcery.com>
8182
8183 * c-opts.c (c_common_handle_option): Update calls to
8184 set_struct_debug_option.
8185
6b192a09
NP
81862010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
8187
8188 * c-common.h (objc_declare_protocols): Added additional argument.
8189 * stub-objc.c (objc_declare_protocol): Same change.
9faeb493 8190
fb52b50a
NF
81912010-11-18 Nathan Froyd <froydnj@codesourcery.com>
8192
8193 PR c/33193
8194 * c-common.h (build_real_imag_expr): Declare.
8195 * c-semantics.c (build_real_imag_expr): Define.
8196
b37421c6
JM
81972010-11-17 Joseph Myers <joseph@codesourcery.com>
8198
8199 * c-opts.c (c_common_parse_file): Take no arguments.
8200 * c-common.h (c_common_parse_file): Update prototype.
8201
07078664
JJ
82022010-11-16 Jakub Jelinek <jakub@redhat.com>
8203
8204 PR c++/46401
8205 * c-common.c (warning_candidate_p): Don't track non-const calls
8206 or STRING_CSTs.
8207
c6a13190
ILT
82082010-11-15 Ian Lance Taylor <iant@google.com>
8209
8210 * c-lex.c (init_c_lex): Set macro debug callbacks if
8211 flag_dump_go_spec is set.
8212
925e8657
NP
82132010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
8214
8215 * c-common.h (objc_build_incr_expr_for_property_ref): New.
8216 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
8217
bb0a9581
NF
82182010-11-15 Nathan Froyd <froydnj@codesourcery.com>
8219
8220 PR preprocessor/45038
8221 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
8222 dialects.
8223
c5fa0890
JM
82242010-11-12 Joseph Myers <joseph@codesourcery.com>
8225
8226 * c-common.h (c_family_lang_mask): Declare.
8227 * c-opts.c (c_family_lang_mask): Make extern.
8228 * c-pragma.c (handle_pragma_diagnostic): Use
8229 control_warning_option.
8230
a4d8c676
JM
82312010-11-12 Joseph Myers <joseph@codesourcery.com>
8232
8233 * c-common.c (parse_optimize_options): Update call to
8234 decode_options.
8235 * c-common.h (c_common_handle_option): Update prototype.
8236 * c-opts.c (c_common_handle_option): Take location_t parameter and
8237 pass it to other functions.
8238
f954bd2c
JM
82392010-11-11 Joseph Myers <joseph@codesourcery.com>
8240
8241 * c-opts.c (warning_as_error_callback): Remove.
8242 (c_common_initialize_diagnostics): Don't call
8243 register_warning_as_error_callback.
8244 (c_common_handle_option): Handle -Werror=normalized= here.
8245
d8a07487
JM
82462010-11-10 Joseph Myers <joseph@codesourcery.com>
8247
8248 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
8249 in diagnostic.
8250 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
8251 letter.
8252 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
8253 Remove trailing '.' from diagnostics.
8254 * c.opt (Wwrite-strings_: Avoid '`' in help text.
8255
d5478783
JM
82562010-11-10 Joseph Myers <joseph@codesourcery.com>
8257
8258 * c-common.c (parse_optimize_options): Pass global_dc to
8259 decode_options.
8260 * c-opts.c (c_common_handle_option): Pass &global_options to
8261 set_Wstrict_aliasing.
8262 * c.opt (v): Don't mark Common or document here.
8263
91ebb981
IS
82642010-11-06 Iain Sandoe <iains@gcc.gnu.org>
8265
8266 PR target/44981
8267 * c-format.c (format_type): New type gcc_objc_string_format_type.
8268 (valid_stringptr_type_p): New.
8269 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
9faeb493 8270 (check_format_string): Pass expected type, use
91ebb981
IS
8271 valid_stringptr_type_p (), check that the format string types are
8272 consistent with the format specification.
8273 (decode_format_attr): Warn if NSString is used outside objective-c.
8274 (format_types_orig): Add NSString.
8275 (format_name): New.
8276 (format_flags): New.
8277 (check_format_arg): Handle format strings requiring an external parser.
8278 first_target_format_type: New variable.
8279 (handle_format_attribute): Set up first_target_format_type, pass the
8280 expected format arg string type to check_format_string().
8281 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
8282 * stub-objc.c (objc_string_ref_type_p): New.
8283 (objc_check_format_arg): New.
8284
bede2adc
NP
82852010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
8286
9faeb493 8287 Fixed using the Objective-C 2.0 dot-syntax with class names.
bede2adc
NP
8288 * c-common.h (objc_build_class_component_ref): New.
8289 * stub-objc.c (objc_build_class_component_ref): New.
8290
9a179d01
NP
82912010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
8292
8293 * c.opt (Wproperty-assign-default): New option.
8294
22d8d616
NP
82952010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
8296
8297 Implemented -fobjc-std=objc1 flag.
8298 * c.opt (fobjc-std=objc1): New option.
8299
2debdb4f
NP
83002010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
8301
8302 Implemented format and noreturn attributes for Objective-C methods.
8303 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
8304 attribute for Objective-C methods.
8305
ec52b111
JM
83062010-10-31 Jason Merrill <jason@redhat.com>
8307
8308 * c-common.c (conversion_warning, warn_for_collisions_1): Use
8309 EXPR_LOC_OR_HERE.
8310
46a88c12
NP
83112010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
8312
8313 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
8314 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
8315 (objc_add_property_declaration): Removed arguments for copies and
8316 ivar.
8317 (objc_build_getter_call): Renamed to
8318 objc_maybe_build_component_ref.
8319 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
8320 (objc_is_property_ref): New.
8321 * c-common.c (c_common_reswords): Removed copies and ivar.
8322 * stub-objc.c (objc_add_property_declaration): Removed arguments
8323 for copies and ivar.
8324 (objc_build_getter_call): Renamed to
8325 objc_maybe_build_component_ref.
8326 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
8327 (objc_is_property_ref): New.
9faeb493 8328
1e4bf85b
AC
83292010-10-29 Arnaud Charlet <charlet@adacore.com>
8330 Matthew Gingell <gingell@adacore.com>
8331
8332 * c-ada-spec.c (separate_class_package): New function.
8333 (pp_ada_tree_identifier): Prefix references to C++ classes with the
8334 name of their enclosing package.
8335 (print_ada_declaration): Use separate_class_package.
8336
81f0bab2
JM
83372010-10-27 Jason Merrill <jason@redhat.com>
8338
2b08f2c5
JM
8339 * c-common.c (c_common_reswords): Add __is_literal_type.
8340 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
8341
81f0bab2
JM
8342 * c-common.c (check_case_value): Remove special C++ code.
8343
200290f2
NP
83442010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
8345
8346 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
8347 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
8348 and RID_LAST_PATTR.
8349 (objc_add_property_declaration): Added additional arguments.
8350 (objc_property_attribute_kind): Removed.
8351 (objc_set_property_attr): Removed.
8352 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
8353 copy and nonatomic.
8354 * stub-objc.c (objc_add_property_declaration): Added additional
8355 arguments.
8356 (objc_set_property_attr): Removed.
9faeb493 8357
f614132b
NP
83582010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
8359
8360 * c-common.h (objc_add_property_variable): Renamed to
8361 objc_add_property_declaration. Added location argument.
8362 * stub-objc.c (objc_add_property_variable): Same change.
b1726d6c 8363
b8a18805
NP
83642010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
8365
8366 * c-common.h (objc_maybe_printable_name): New.
8367 * stub-objc.c (objc_maybe_printable_name): New.
8368
3f8257db
JJ
83692010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
8370 Andrew Pinski <pinskia@gmail.com>
30cd1c5d
AS
8371
8372 * c-common.h (c_common_mark_addressable_vec): Declare.
8373 * c-common.c (c_common_mark_addressable_vec): New function.
8374
249a82c4
NP
83752010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
8376
8377 * c-common.h (objc_set_method_type): Removed.
8378 (objc_add_method_declaration): Added boolean argument.
8379 (objc_start_method_definition): Same change.
8380 (objc_build_method_signature): Same change.
8381 * stub-objc.c (objc_set_method_type): Removed.
8382 (objc_add_method_declaration): Added boolean argument.
8383 (objc_start_method_definition): Same change.
8384 (objc_build_method_signature): Same change.
8385
977e30bc
NP
83862010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
8387
8388 * c-common.h (finish_file): Removed.
8389 (objc_write_global_declarations): New.
8390 * c-opts.c (c_common_parse_file): Do not call finish_file.
8391 * stub-objc.c (objc_write_global_declarations): New.
9faeb493 8392
da57d1b9
NP
83932010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
8394
8395 Implemented parsing @synthesize and @dynamic for
8396 Objective-C/Objective-C++.
8397 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
8398 (objc_add_synthesize_declaration): New.
8399 (objc_add_dynamic_declaration): New.
8400 * c-common.c (c_common_reswords): Add synthesize and dynamic.
8401 * stub-objc.c (objc_add_synthesize_declaration): New.
8402 (objc_add_dynamic_declaration): New.
9faeb493 8403
0069111f
MM
84042010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
8405
8406 PR target/46041
8407 * c-cppbuiltin.c (mode_has_fma): Move function here from
8408 builtins.c. Don't use the fma optab, instead just use the
8409 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
8410 using -save-temps.
8411
e426b47b
NP
84122010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
8413
8414 Merge from 'apple/trunk' branch on FSF servers.
0069111f 8415
3f8257db 8416 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
e426b47b 8417
9faeb493 8418 Radar 4330422
e426b47b
NP
8419 * c-common.h (objc_non_volatilized_type): New declaration
8420 * stub-objc.c (objc_non_volatilized_type): New stub.
8421
90fbfdc3
NP
84222010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
8423
e426b47b 8424 Merge from 'apple/trunk' branch on FSF servers.
90fbfdc3 8425
3f8257db 8426 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
90fbfdc3 8427
9faeb493 8428 Radar 4133425
90fbfdc3 8429 * c-common.h (objc_diagnose_private_ivar): New decl.
0069111f 8430 * stub-objc.c (objc_diagnose_private_ivar): New stub.
90fbfdc3 8431
c37d8c30
IS
84322010-10-17 Iain Sandoe <iains@gcc.gnu.org>
8433
8434 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
8435 * c-common.h (enum rid): Add RID_AT_PACKAGE.
8436 (objc_ivar_visibility_kind): New enum.
8437 (objc_set_visibility): Adjust prototype to use visibility enum.
0069111f 8438 * stub-objc.c (objc_set_visibility): Adjust stub to use
c37d8c30
IS
8439 visibility enum.
8440
1b1562a5
MM
84412010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
8442
8443 * c-cppbuiltin.c (builtin_define_float_constants): Emit
8444 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
8445 has the appropriate fma builtins.
8446 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
8447
668ea4b1
IS
84482010-10-14 Iain Sandoe <iains@gcc.gnu.org>
8449
1b1562a5 8450 merge from FSF apple 'trunk' branch.
3f8257db 8451 2006 Fariborz Jahanian <fjahanian@apple.com>
1b1562a5 8452
668ea4b1
IS
8453 Radars 4436866, 4505126, 4506903, 4517826
8454 * c-common.c (c_common_resword): Define @property and its attributes.
8455 * c-common.h: Define property attribute enum entries.
8456 (OBJC_IS_PATTR_KEYWORD): New.
8457 (objc_property_attribute_kind): New enum.
8458 Declare objc_set_property_attr (), objc_add_property_variable (),
8459 objc_build_getter_call () and objc_build_setter_call ().
8460 * stub-objc.c (objc_set_property_attr): New stub.
8461 (objc_add_property_variable): Likewise.
8462 (objc_build_getter_call): Likewise.
8463 (objc_build_setter_call) Likewise.
1b1562a5 8464
a1178b30
IS
84652010-10-13 Iain Sandoe <iains@gcc.gnu.org>
8466
1b1562a5 8467 merge from FSF apple 'trunk' branch.
3f8257db 8468 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
a1178b30
IS
8469
8470 Radar 3803157 (method attributes)
8471 * c-common.c (handle_deprecated_attribute): Recognize
8472 objc methods as valid declarations.
8473 * c-common.h: Declare objc_method_decl ().
1b1562a5 8474 * stub-objc.c (objc_method_decl): New stub.
a1178b30 8475
a75bfaa6
JM
84762010-10-08 Joseph Myers <joseph@codesourcery.com>
8477
8478 * c-common.c (parse_optimize_options): Call
8479 decode_cmdline_options_to_array_default_mask before
8480 decode_options. Update arguments to decode_options.
8481 * c-common.h (c_common_init_options_struct): Declare.
8482 * c-opts.c (c_common_init_options_struct): New. Split out from
8483 c_common_init_options.
8484
f05b9d93
NP
84852010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
8486
8487 Implemented fast enumeration for Objective-C.
8488 * c-common.h (objc_finish_foreach_loop): New.
8489 * stub-objc.c (objc_finish_foreach_loop): New.
8490
1ebe4b4f
JM
84912010-10-05 Joseph Myers <joseph@codesourcery.com>
8492
8493 * c-common.h (struct diagnostic_context): Don't declare here.
8494 (c_common_initialize_diagnostics): Declare using
8495 diagnostic_context typedef.
8496 * c-opts.c (c_common_handle_option): Pass global_dc to
8497 handle_generated_option.
8498
d4d24ba4
JM
84992010-10-04 Joseph Myers <joseph@codesourcery.com>
8500
8501 * c-opts.c (c_common_handle_option): Pass &global_options_set to
8502 handle_generated_option.
8503
478a1c5b
ILT
85042010-10-03 Ian Lance Taylor <iant@google.com>
8505
8506 * c.opt (-fplan9-extensions): New option.
8507
82a1c2fe
FXC
85082010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
8509
8510 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
8511 Remove.
8512 (c_cpp_builtins): Call functions from cppbuiltin.c instead
8513 of duplicating code.
8514
92902b1b
IS
85152010-09-30 Iain Sandoe <iains@gcc.gnu.org>
8516
8517 * c-common.c: Add two new entries for @optional
8518 and @required keywords.
8519
8520 merge from FSF 'apple/trunk' branch.
3f8257db 8521 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
92902b1b
IS
8522
8523 Radar 4386773
8524 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
8525 objective-c keywords.
8526 (objc_set_method_opt): New declaration.
8527 * stub-objc.c (objc_set_method_opt): New stub.
9faeb493 8528
46625112
JM
85292010-09-30 Joseph Myers <joseph@codesourcery.com>
8530
8531 * c-common.c (handle_optimize_attribute): Pass &global_options to
8532 cl_optimization_save and cl_optimization_restore.
8533 * c-opts.c (c_common_handle_option): Pass &global_options to
8534 handle_generated_option.
8535 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
8536 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
8537 &global_options to cl_optimization_restore.
8538
49b91f05
NP
85392010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
8540
8541 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
8542 Objective-C/Objective-C++ keywords.
8543
13ed556f 85442010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
a6341d57 8545
9faeb493
UB
8546 Merge from 'apple/trunk' branch on FSF servers.
8547
3f8257db 8548 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
a6341d57
NP
8549
8550 Radar 4281748
8551 * c-common.h (objc_check_global_decl): New declaration.
8552 * stub-objc.c (objc_check_global_decl): New stub.
8553
f0036cca
JM
85542010-09-29 Joseph Myers <joseph@codesourcery.com>
8555
8556 * c.opt: Don't use VarExists.
8557
e3339d0f
JM
85582010-09-29 Joseph Myers <joseph@codesourcery.com>
8559
8560 * c-common.c (c_cpp_error): Update names of diagnostic_context
8561 members.
8562 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
8563 cl_optimization members.
8564 * c-opts.c (warning_as_error_callback, c_common_handle_option,
8565 sanitize_cpp_opts, finish_options): Update names of cpp_options
8566 members.
8567
1973201f
NP
85682010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
8569
8570 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
8571 (objc_is_reserved_word): Removed.
8572 * c-common.c: Updated comments.
8573 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
8574 objc_is_reserved_word.
8575 * stub-objc.c (objc_is_reserved_word): Removed.
8576
f7e71da5
IS
85772010-09-28 Iain Sandoe <iains@gcc.gnu.org>
8578
9faeb493 8579 * c-common.h (objc_add_method_declaration): Adjust prototype to
f7e71da5
IS
8580 include attributes.
8581 (objc_start_method_definition): Likewise.
8582 (objc_build_keyword_decl): Likewise.
8583 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
8584 (objc_start_method_definition): Likewise.
8585 (objc_build_keyword_decl): Likewise.
8586
c165dca7
IS
85872010-09-28 Iain Sandoe <iains@gcc.gnu.org>
8588
8589 * c-common.h (objc_start_class_interface): Adjust prototype.
8590 (objc_start_category_interface): Likewise.
8591 (objc_start_protocol): Likewise.
8592 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
8593 (objc_start_class_interface): Likewise.
8594 (objc_start_category_interface): Likewise.
8595
7458026b
ILT
85962010-09-27 Ian Lance Taylor <iant@google.com>
8597
8598 * c-common.c (c_common_attribute_table): Add no_split_stack.
8599 (handle_no_split_stack_attribute): New static function.
8600
b581b85b
NP
86012010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
8602
9faeb493 8603 Merge from 'apple/trunk' branch on FSF servers.
b581b85b 8604
3f8257db 8605 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
b581b85b 8606
9faeb493 8607 Radar 4229905
b581b85b
NP
8608 * c-common.h (objc_have_common_type): New declaration.
8609 * stub-objc.c (objc_have_common_type): New stub.
8610
8611 2005-06-22 Ziemowit Laski <zlaski@apple.com>
8612
8613 Radar 4154928
8614 * c-common.h (objc_common_type): New prototype.
9faeb493 8615 * stub-objc.c (objc_common_type): New stub.
b581b85b 8616
46a4da10
JH
86172010-09-24 Jan Hubicka <jh@suse.cz>
8618
8619 * c-common.c (handle_leaf_attribute): New function.
8620 (struct attribute_spec c_common_att): Add leaf.
8621
e200444e
JM
86222010-09-22 Joseph Myers <joseph@codesourcery.com>
8623
8624 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
8625 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
8626 -dump, -dump=, -imacros, -imacros=, -include, -include=,
8627 -include-barrier, -include-directory, -include-directory=,
8628 -include-directory-after, -include-directory-after=,
8629 -include-prefix, -include-prefix=, -include-with-prefix,
8630 -include-with-prefix=, -include-with-prefix-after,
8631 -include-with-prefix-after=, -include-with-prefix-before,
8632 -include-with-prefix-before=, -no-integrated-cpp,
8633 -no-line-commands, -no-standard-includes, -no-warnings, -output,
8634 -output=, -pedantic, -pedantic-errors, -preprocess,
8635 -print-missing-file-dependencies, -trace-includes, -traditional,
8636 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
8637 -user-dependencies, -verbose, -write-dependencies,
8638 -write-user-dependencies, no-integrated-cpp, traditional): New.
8639
29a80ea6
NP
86402010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
8641
8642 PR objc/23710
ac1fc2fc
NP
8643 * c-common.h (objc_start_method_definition): Return bool instead
8644 of void.
8645 * stub-objc.c (objc_start_method_definition): Return bool instead
8646 of void.
8647
86482010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
8649
8650 PR objc/25965
8651 * c-common.h (objc_get_interface_ivars): New declaration.
8652 * stub-objc.c (objc_get_interface_ivars): New stub.
29a80ea6 8653
de621752
ILT
86542010-09-15 Ian Lance Taylor <iant@google.com>
8655
8656 * c-common.c (parse_optimize_options): Do not capitalize warning
06730c5d 8657 messages. Remove period at end of warning message.
de621752 8658
ba885ec5
NS
86592010-09-09 Nathan Sidwell <nathan@codesourcery.com>
8660
8661 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
8662 (handle_alias_attribute): ... here.
8663 (handle_ifunc_attribute): New.
8664
c5ee1358
MM
86652010-09-06 Mark Mitchell <mark@codesourcery.com>
8666
8667 * c-common.h (do_warn_double_promotion): Declare.
8668 * c-common.c (do_warn_double_promotion): Define.
8669
0a0b3574
MM
86702010-09-05 Mark Mitchell <mark@codesourcery.com>
8671
8672 * c.opt (Wdouble-promotion): New.
8673
d1779886
JM
86742010-09-02 Joseph Myers <joseph@codesourcery.com>
8675
8676 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
8677 fvtable-thunks, fxref): Mark no longer supported in help text.
8678
2d2bd949
JM
86792010-09-02 Joseph Myers <joseph@codesourcery.com>
8680
8681 * c.opt (Wimport, fall-virtual, falt-external-templates,
8682 fdefault-inline, fenum-int-equiv, fexternal-templates,
8683 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
8684 fname-mangling-version-, fnew-abi, fnonnull-objects,
8685 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
8686 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
8687 applicable.
8688 (fhandle-exceptions): Mark with Alias and Warn.
8689 * c-opts.c (c_common_handle_option): Don't handle options marked
8690 as ignored.
8691
5de8299c
JM
86922010-09-02 Joseph Myers <joseph@codesourcery.com>
8693
8694 * c.opt (Wcomments, Werror-implicit-function-declaration,
8695 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
8696 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
8697 aliases.
8698 * c-common.c (option_codes): Use OPT_Wcomment instead of
8699 OPT_Wcomments.
8700 * c-opts.c (warning_as_error_callback, c_common_handle_option):
8701 Don't handle options marked as aliases.
8702
0ceb0201
RG
87032010-08-25 Richard Guenther <rguenther@suse.de>
8704
8705 * c-common.c (c_common_get_alias_set): Remove special
8706 handling for pointers.
8707
ac47786e
NF
87082010-08-20 Nathan Froyd <froydnj@codesourcery.com>
8709
8710 * c-common.c: Use FOR_EACH_VEC_ELT.
8711 * c-gimplify.c: Likewise.
8712 * c-pragma.c: Likewise.
8713
c878765b
JM
87142010-08-16 Joseph Myers <joseph@codesourcery.com>
8715
8716 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
8717 RejectDriver.
8718 (MMDX): Change back to MMD. Mark NoDriverArg instead of
8719 RejectDriver.
8720 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
8721 instead of OPT_MDX and OPT_MMDX.
8722
603349bf
JM
87232010-08-16 Joseph Myers <joseph@codesourcery.com>
8724
8725 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
8726
644fa7ac
JM
87272010-08-12 Joseph Myers <joseph@codesourcery.com>
8728
8729 * c.opt (MD, MMD): Change to MDX and MMDX.
8730 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
8731
481e1176
JM
87322010-08-11 Joseph Myers <joseph@codesourcery.com>
8733
8734 * c-opts.c (c_common_handle_option): Call handle_generated_option
8735 instead of handle_option.
8736
ac8dc9f7
NF
87372010-08-08 Nathan Froyd <froydnj@codesourcery.com>
8738
8739 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
8740 (maybe_apply_renaming_pragma): Delete unneeded declarations.
8741
4f8c876d
NF
87422010-08-08 Nathan Froyd <froydnj@codesourcery.com>
8743
8744 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
8745 (pending_redefine_extname): Change type to a VEC.
8746 (add_to_renaming_pragma_list): Update for new type of
8747 pending_redefine_extname.
ac8dc9f7 8748 (maybe_apply_renaming_pragma): Likewise.
4f8c876d 8749
3b0c690e
AC
87502010-08-04 Arnaud Charlet <charlet@adacore.com>
8751
8752 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
8753 visited.
8754 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
8755 decide whether a type has already been declared/seen.
8756 Do not go to the original type.
8757 (dump_nested_types): New parameter forward.
8758 Generate forward declaration if needed and mark type as visited.
8759 (print_ada_declaration): Call dump_nested_types if not already done.
8760 Mark types as visited.
8761
1890bccc
JM
87622010-08-03 Joseph Myers <joseph@codesourcery.com>
8763
8764 * c.opt (-print-pch-checksum): Remove option.
8765 * c-opts.c (c_common_handle_option): Don't handle
8766 OPT_print_pch_checksum.
8767
5f20c657
JM
87682010-07-27 Joseph Myers <joseph@codesourcery.com>
8769
8770 * c-common.h (c_common_handle_option): Update prototype and return
8771 value type.
8772 * c-opts.c (c_common_handle_option): Update prototype and return
8773 value type. Update calls to handle_option and
8774 enable_warning_as_error.
8775
f551f80c
JJ
87762010-07-27 Jakub Jelinek <jakub@redhat.com>
8777
8778 PR c/45079
8779 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
8780
61ff2bdc
JM
87812010-07-27 Joseph Myers <joseph@codesourcery.com>
8782
8783 * c-common.h (c_common_missing_argument): Remove.
8784 * c-opts.c (c_common_missing_argument): Remove.
8785 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
8786 idirafter, imacros, include, isysroot, isystem, iquote): Add
8787 MissingArgError.
8788 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
8789
7a9bf9a4
JM
87902010-07-27 Joseph Myers <joseph@codesourcery.com>
8791
8792 * c-common.h (c_common_option_lang_mask,
8793 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
8794 New.
8795 (c_common_init_options): Update prototype.
8796 * c-opts.c (c_common_option_lang_mask): New.
8797 (c_common_initialize_diagnostics): Split out of
8798 c_common_init_options.
8799 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
8800 New.
8801 (c_common_init_options): Update prototype. Use decoded options in
8802 search for -lang-asm.
8803
910ad8de
NF
88042010-07-15 Nathan Froyd <froydnj@codesourcery.com>
8805
8806 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
8807 * c-format.c: Likewise.
8808
718f9c0f
MLI
88092010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
8810
8811 * c-common.h: Include diagnostic-core.h. Error if already
8812 included.
8813 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
8814
4d451982
MLI
88152010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
8816
adfac8df 8817 * c-common.c (IN_GCC_FRONTEND): Do not undef.
4d451982
MLI
8818 Do not include expr.h
8819 (vector_mode_valid_p): Move here.
8820
119fe915
SB
88212010-06-21 DJ Delorie <dj@redhat.com>
8822
8823 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
8824 allow these pragmas anywhere.
8825
88262010-06-14 Jakub Jelinek <jakub@redhat.com>
8827
8828 PR bootstrap/44509
8829 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
8830 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
8831 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
8832 ggc_strdup instead of xstrdup.
8833
88342010-06-10 Jakub Jelinek <jakub@redhat.com>
8835
8836 * c-cppbuiltin.c: Include cpp-id-data.h.
8837 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
8838 (lazy_hex_fp_value): New function.
8839 (builtin_define_with_hex_fp_value): Provide definitions lazily.
8840
6662d794
MLI
88412010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
8842
8843 * c-gimplify.c: Do not include tree-flow.h
8844
38f8b050
JR
88452010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
8846
8847 PR other/44034
8848 * c-common.c: Rename targetm member:
8849 targetm.enum_va_list -> targetm.enum_va_list_p
8850
9589f23e
AS
88512010-06-28 Anatoly Sokolov <aesok@post.ru>
8852
8853 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
8854
3b06d379
SB
88552010-06-28 Steven Bosscher <steven@gcc.gnu.org>
8856
8857 * c-cppbuiltin.c: Do not include except.h.
8858
d166d4c3
AK
88592010-06-24 Andi Kleen <ak@linux.intel.com>
8860
9faeb493
UB
8861 * c-common.c (warn_for_omitted_condop): New.
8862 * c-common.h (warn_for_omitted_condop): Add prototype.
d166d4c3 8863
70cb8be6
JM
88642010-06-21 Joseph Myers <joseph@codesourcery.com>
8865
8866 * c.opt (lang-objc): Remove.
8867 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
8868
a4c97feb
JR
88692010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
8870
8871 * c-opts.c: Include "tm_p.h".
8872
6e2f1956
JM
88732010-06-20 Joseph Myers <joseph@codesourcery.com>
8874
8875 * c-common.c (parse_optimize_options): Update call to
8876 decode_options.
8877
bc87224e
NF
88782010-06-18 Nathan Froyd <froydnj@codesourcery.com>
8879
8880 * c-common.c (record_types_used_by_current_var_decl): Adjust for
8881 new type of types_used_by_cur_var_decl.
8882
b49cf425
JR
88832010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
8884
8885 PR bootstrap/44512
8886 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
8887 for C++ standard compliance.
8888
59f9c2ed
JM
88892010-06-16 Jason Merrill <jason@redhat.com>
8890
8891 * c.opt: Add -Wnoexcept.
8892
33766b66
RG
88932010-06-16 Richard Guenther <rguenther@suse.de>
8894
8895 PR c/44555
8896 * c-common.c (c_common_truthvalue_conversion): Remove
8897 premature and wrong optimization concering ADDR_EXPRs.
8898
eff7e30c
AC
88992010-06-15 Arnaud Charlet <charlet@adacore.com>
8900
8901 * c-ada-spec.c (dump_sloc): Remove column info.
8902 (is_simple_enum): New function.
8903 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
8904 enum types when relevant.
8905
6312e84d
MLI
89062010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
8907
9faeb493 8908 * c-common.c (conversion_warning): Warn at expression
6312e84d
MLI
8909 location.
8910
1cb42611
JM
89112010-06-10 Joseph Myers <joseph@codesourcery.com>
8912
8913 * c-opts.c (c_common_handle_option): Don't handle
8914 OPT_fshow_column.
8915
a9429e29
LB
89162010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
8917
8918 * c-pragma.c (push_alignment): Use typed GC allocation.
8919 (handle_pragma_push_options): Likewise.
8920
8921 * c-common.c (parse_optimize_options): Likewise.
8922
8923 * c-common.h (struct sorted_fields_type): Add variable_size GTY
8924 option.
8925
5498f011
JM
89262010-06-07 Joseph Myers <joseph@codesourcery.com>
8927
8928 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
8929 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
8930 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
8931 flag_signed_bitfields, warn_strict_null_sentinel,
8932 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
8933 flag_gen_declaration, flag_no_gnu_keywords,
8934 flag_implement_inlines, flag_implicit_templates,
8935 flag_implicit_inline_templates, flag_optional_diags,
8936 flag_elide_constructors, flag_default_inline, flag_rtti,
8937 flag_conserve_space, flag_access_control, flag_check_new,
8938 flag_new_for_scope, flag_weak, flag_working_directory,
8939 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
8940 flag_enforce_eh_specs, flag_threadsafe_statics,
8941 flag_pretty_templates): Remove.
8942 * c-common.h (flag_preprocess_only, flag_nil_receivers,
8943 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
8944 flag_replace_objc_classes, flag_undef, flag_no_builtin,
8945 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
8946 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
8947 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
8948 flag_no_gnu_keywords, flag_implement_inlines,
8949 flag_implicit_templates, flag_implicit_inline_templates,
8950 flag_optional_diags, flag_elide_constructors, flag_default_inline,
8951 flag_rtti, flag_conserve_space, flag_access_control,
8952 flag_check_new, flag_new_for_scope, flag_weak,
8953 flag_working_directory, flag_use_cxa_atexit,
8954 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
8955 flag_threadsafe_statics, flag_pretty_templates,
8956 warn_strict_null_sentinel): Remove.
8957 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
8958 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
8959 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
8960 fimplicit-inline-templates, fimplicit-templates,
8961 flax-vector-conversions, fms-extensions, fnil-receivers,
8962 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
8963 frtti, fshort-double, fshort-enums, fshort-wchar,
8964 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
8965 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
8966 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
8967 gen-decls, undef): Use Var.
8968 (fdefault-inline, foptional-diags): Document as doing nothing.
8969 * c-opts.c (c_common_handle_option): Remove cases for options now
8970 using Var. Mark ignored options as such.
8971
39dabefd
SB
89722010-06-05 Steven Bosscher <steven@gcc.gnu.org>
8973
9faeb493 8974 * c-common.c: Moved to here from parent directory.
39dabefd
SB
8975 * c-common.def: Likewise.
8976 * c-common.h: Likewise.
8977 * c-cppbuiltin.c: Likewise.
8978 * c-dump.c: Likewise.
8979 * c-format.c: Likewise.
8980 * c-format.h : Likewise.
8981 * c-gimplify.c: Likewise.
8982 * c-lex.c: Likewise.
8983 * c-omp.c: Likewise.
8984 * c.opt: Likewise.
8985 * c-opts.c: Likewise.
8986 * c-pch.c: Likewise.
8987 * c-ppoutput.c: Likewise.
8988 * c-pragma.c: Likewise.
8989 * c-pragma.h: Likewise.
8990 * c-pretty-print.c: Likewise.
8991 * c-pretty-print.h: Likewise.
8992 * c-semantics.c: Likewise.
8993 * stub-objc.c: Likewise.
8994
8995 * c-common.c: Include gt-c-family-c-common.h.
8996 * c-pragma.c: Include gt-c-family-c-pragma.h.
8997\f
85ec4feb 8998Copyright (C) 2010-2018 Free Software Foundation, Inc.
39dabefd
SB
8999
9000Copying and distribution of this file, with or without modification,
9001are permitted in any medium without royalty provided the copyright
9002notice and this notice are preserved.