]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/c-family/ChangeLog
* c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
1 2019-08-21 Eric Botcazou <ebotcazou@adacore.com>
2
3 * c-ada-spec.c (dump_ada_function_declaration): Be prepared for broken
4 function declarations where arguments are missing. Rename variables.
5
6 2019-08-15 Richard Biener <rguenther@suse.de>
7
8 * c-common.c (c_stddef_cpp_builtins): When the GIMPLE FE is
9 enabled, define __SIZETYPE__.
10
11 2019-08-14 Christophe Lyon <christophe.lyon@linaro.org>
12
13 * c-attribs.c (c_common_attribute_table): Add "noinit" entry. Add
14 exclusion with "section" attribute.
15 (attr_noinit_exclusions): New table.
16 (handle_noinit_attribute): New function.
17
18 2019-08-13 Richard Sandiford <richard.sandiford@arm.com>
19
20 PR middle-end/91421
21 * c-common.c (resolve_overloaded_builtin): Use
22 copy_decl_built_in_function.
23
24 2019-08-13 Martin Sebor <msebor@redhat.com>
25
26 PR c/80619
27 * c-format.c (printf_length_specs): Set FMT_LEN_w for "w".
28 (asm_fprintf_length_spec): Same.
29 * c-format.h (format_lengths): Add FMT_LEN_w.
30
31 2019-08-10 Jakub Jelinek <jakub@redhat.com>
32
33 * c-pragma.h (enum pragma_omp_clause): Add
34 PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
35
36 2019-08-07 Jakub Jelinek <jakub@redhat.com>
37
38 * c-pragma.h (enum pragma_omp_clause): Add
39 PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR. Set PRAGMA_OACC_CLAUSE_USE_DEVICE
40 equal to PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR instead of being a separate
41 enumeration value.
42
43 2019-08-05 Marek Polacek <polacek@redhat.com>
44
45 PR c++/91338 - Implement P1161R3: Deprecate a[b,c].
46 * c-opts.c (c_common_post_options): Enable -Wcomma-subscript by
47 default for C++2a, unless -Wno-deprecated.
48 * c.opt (Wcomma-subscript): New warning.
49
50 2019-07-20 Jakub Jelinek <jakub@redhat.com>
51
52 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_LOOP.
53 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_BIND.
54 * c-pragma.c (omp_pragmas_simd): Add PRAGMA_OMP_LOOP entry.
55 * c-common.h (enum c_omp_clause_split): Add C_OMP_CLAUSE_SPLIT_LOOP.
56 * c-omp.c (c_omp_split_clauses): Add support for 4 new combined
57 constructs with the loop construct.
58
59 2019-07-13 Jakub Jelinek <jakub@redhat.com>
60
61 PR c/91149
62 * c-omp.c (c_omp_split_clauses): Fix a pasto in
63 OMP_CLAUSE_REDUCTION_TASK handling.
64
65 2019-07-12 Jakub Jelinek <jakub@redhat.com>
66
67 * c-pragma.h (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ORDER.
68 * c-omp.c (c_omp_split_clauses): Handle splitting of OMP_CLAUSE_ORDER.
69
70 2019-07-09 Martin Sebor <msebor@redhat.com>
71
72 PR c++/61339
73 * c-opts.c (handle_deferred_opts): Change class-key of PODs to struct
74 and others to class.
75 * c-pretty-print.h: Same.
76
77 2019-07-09 Martin Sebor <msebor@redhat.com>
78
79 PR c++/61339
80 * c-format.c (check_argument_type): Change class-key from class to
81 struct and vice versa to match convention and avoid -Wclass-is-pod
82 and -Wstruct-no-pod.
83 * c-pretty-print.h: Same.
84
85 2019-07-03 Martin Liska <mliska@suse.cz>
86
87 * c-common.c (try_to_locate_new_include_insertion_point): Remove
88 dead assignemts.
89
90 2019-07-03 Jakub Jelinek <jakub@redhat.com>
91
92 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_REDUCTION_INSCAN
93 clauses on OMP_FOR rather than OMP_PARALLEL when OMP_FOR is combined
94 with OMP_PARALLEL.
95
96 2019-07-02 qing zhao <qing.zhao@oracle.com>
97
98 PR preprocessor/90581
99 * c-opts.c (c_common_handle_option): Handle -fmax-include-depth.
100 * c.opt: Add new option -fmax-include-depth.
101
102 2019-06-26 Jason Merrill <jason@redhat.com>
103
104 PR c++/55442 - memory-hog with highly recursive constexpr.
105 * c.opt (fconstexpr-loop-limit): New.
106
107 2019-06-25 Jakub Jelinek <jakub@redhat.com>
108
109 PR sanitizer/90954
110 * c-omp.c (c_finish_omp_atomic): Allow tree_invariant_p in addition
111 to SAVE_EXPR in first operand of a COMPOUND_EXPR.
112
113 2019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
114
115 * c-common.c (c_common_nodes_and_builtins): Define
116 alternate "__intN__" name for "__intN" types.
117
118 2019-06-24 Jan Hubicka <jh@suse.cz>
119
120 * c-common.c (braced_lists_to_strings): Check that
121 type is array or integer prior checking string flag.
122
123 2019-06-21 Matthew Beliveau <mbelivea@redhat.com>
124
125 PR c++/90875 - added -Wswitch-outside-range option
126 * c.opt (Wswitch-outside-range): Added new option.
127 * c-warn.c (c_do_switch_warnings): Use OPT_Wswitch-outside-range.
128
129 2019-06-21 Marek Polacek <polacek@redhat.com>
130
131 PR c++/90953 - ICE with -Wmissing-format-attribute.
132 * c-common.c (check_function_arguments_recurse): Use
133 get_attribute_name.
134 (check_missing_format_attribute): Likewise.
135
136 2019-06-19 Marek Polacek <polacek@redhat.com>
137
138 PR c++/60364 - noreturn after first decl not diagnosed.
139 * c-attribs.c (handle_noreturn_attribute): No longer static.
140 * c-common.h (handle_noreturn_attribute, attr_noreturn_exclusions):
141 Declare.
142 * c-format.c (check_function_format): Use get_attribute_name.
143
144 2019-06-19 Martin Sebor <msebor@redhat.com>
145
146 PR translation/90156
147 * c-format.c (function_format_info::format_type): Adjust type.
148 (function_format_info::is_raw): New member.
149 (decode_format_type): Adjust signature. Handle "raw" diag attributes.
150 (decode_format_attr): Adjust call to decode_format_type.
151 Avoid a redundant call to convert_format_name_to_system_name.
152 Avoid abbreviating the word "arguments" in a diagnostic.
153 (format_warning_substr): New function.
154 (avoid_dollar_number): Quote dollar sign in a diagnostic.
155 (finish_dollar_format_checking): Same.
156 (check_format_info): Same.
157 (struct baltoks_t): New.
158 (c_opers, c_keywords, cxx_keywords, badwords, contrs): New arrays.
159 (maybe_diag_unbalanced_tokens, check_tokens, check_plain): New
160 functions.
161 (check_format_info_main): Call check_plain. Use baltoks_t. Call
162 maybe_diag_unbalanced_tokens.
163 (handle_format_attribute): Spell out the word "arguments" in
164 a diagnostic.
165
166 2019-06-11 Matthew Beliveau <mbelivea@redhat.com>
167
168 PR c++/90449 - add -Winaccessible-base option.
169 * c.opt (Winaccessible-base): New option.
170
171 2019-06-10 Jakub Jelinek <jakub@redhat.com>
172
173 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_SCAN.
174 * c-pragma.c (omp_pragmas_simd): Add #pragma omp scan.
175 * c-omp.c (c_omp_split_clauses): Diagnose inscan reductions on
176 combined/composite constructs where it is not allowed. Copy over
177 OMP_CLAUSE_REDUCTION_INSCAN.
178
179 2019-06-05 Martin Sebor <msebor@redhat.com>
180
181 * c-attribs.c (handle_mode_attribute): Adjust quoting and hyphenation.
182 (handle_alias_ifunc_attribute): Same.
183 (handle_copy_attribute): Same.
184 (handle_weakref_attribute): Same.
185 (handle_nonnull_attribute): Same.
186 * c-warn.c (warn_for_sign_compare): Same.
187 (warn_for_restrict): Same.
188 * c.opt: Same.
189
190 2019-06-05 Martin Sebor <msebor@redhat.com>
191
192 * c-pragma.c (handle_pragma_weak): Adjust quoting in a diagnostic.
193 * c.opt (-Wformat-diag): Remove a spurious period.
194
195 2019-05-29 Jakub Jelinek <jakub@redhat.com>
196
197 PR c/90628
198 * c-common.c (check_builtin_function_arguments)
199 <case BUILTIN_*_OVERFLOW>: Diagnose pointer to const qualified integer
200 as last argument.
201
202 2019-05-23 Eric Botcazou <ebotcazou@adacore.com>
203
204 * c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
205
206 2019-05-22 Martin Liska <mliska@suse.cz>
207
208 PR lto/90500
209 * c-attribs.c (handle_copy_attribute): Do not copy
210 target_clones attribute.
211
212 2019-05-21 Eric Botcazou <ebotcazou@adacore.com>
213
214 * c-ada-spec.h (enum cpp_operation): Add IS_ASSIGNMENT_OPERATOR.
215 * c-ada-spec.c (print_assignment_operator): New function.
216 (dump_ada_declaration) <FUNCTION_DECL>: Call it do dump explicit copy
217 assignment operators declared as methods and filter out the others.
218
219 2019-05-17 Thomas Schwinge <thomas@codesourcery.com>
220
221 PR c/89433
222 * c-attribs.c (c_common_attribute_table): Set min_len to -1 for
223 "omp declare target".
224
225 2019-05-16 Martin Sebor <msebor@redhat.com>
226
227 * c-attribs.c (handle_no_sanitize_attribute): Quote identifiers,
228 keywords, operators, and types in diagnostics.
229 (handle_scalar_storage_order_attribute): Same.
230 (handle_mode_attribute): Same.
231 (handle_visibility_attribute): Same.
232 (handle_assume_aligned_attribute): Same.
233 (handle_no_split_stack_attribute): Same.
234 * c-common.c (shorten_compare): Same.
235 (c_common_truthvalue_conversion): Same.
236 (cb_get_source_date_epoch): Same.
237 * c-lex.c (cb_def_pragma): Quote keywords, operators, and types
238 in diagnostics.
239 (interpret_float): Same.
240 * c-omp.c (c_finish_omp_for): Same.
241 * c-opts.c (c_common_post_options): Same.
242 * c-pch.c (c_common_pch_pragma): Same.
243 * c-pragma.c (pop_alignment): Same.
244 (handle_pragma_pack): Same.
245 (apply_pragma_weak): Same.
246 (handle_pragma_weak): Same.
247 (handle_pragma_scalar_storage_order): Same.
248 (handle_pragma_redefine_extname): Same.
249 (add_to_renaming_pragma_list): Same.
250 (maybe_apply_renaming_pragma): Same.
251 (push_visibility): Same.
252 (handle_pragma_visibility): Same.
253 (handle_pragma_optimize): Same.
254 (handle_pragma_message): Same.
255 * c-warn.c (warn_for_omitted_condop): Same.
256 (lvalue_error): Same.
257
258 2019-05-15 Richard Biener <rguenther@suse.de>
259
260 PR c/90474
261 * c-common.c (c_common_mark_addressable_vec): Also mark
262 a COMPOUND_LITERAL_EXPR_DECL addressable similar to
263 c_mark_addressable.
264
265 2019-05-06 Nathan Sidwell <nathan@acm.org>
266
267 * c-opts.c (handle_defered_opts): Rename struct deps to struc mkdeps.
268
269 2019-04-30 Nathan Sidwell <nathan@acm.org>
270
271 * c-common.c (c_common_init_ts): Use MARK_TS_EXP. Mark SIZEOF_EXPR.
272
273 2019-04-30 Martin Liska <mliska@suse.cz>
274
275 * c-pragma.c (handle_pragma_diagnostic): Provide hints
276 for unknown options.
277
278 2019-04-26 Richard Sandiford <richard.sandiford@arm.com>
279
280 * c-warn.c (strict_aliasing_warning): Apply COMPLETE_TYPE_P to
281 the pointer target rather than the pointer itself.
282
283 2019-04-19 Jakub Jelinek <jakub@redhat.com>
284
285 PR c/89888
286 * c-common.h (c_add_case_label): Remove orig_type and outside_range_p
287 arguments.
288 (c_do_switch_warnings): Remove outside_range_p argument.
289 * c-common.c (check_case_bounds): Removed.
290 (c_add_case_label): Remove orig_type and outside_range_p arguments.
291 Don't call check_case_bounds. Fold low_value as well as high_value.
292 * c-warn.c (c_do_switch_warnings): Remove outside_range_p argument.
293 Check for case labels outside of range of original type here and
294 adjust them.
295
296 2019-04-12 Jakub Jelinek <jakub@redhat.com>
297
298 PR translation/90041
299 * c.opt (-fhandle-exceptions): Use %< and %> around option names
300 in the Warn diagnostics.
301
302 PR c/89946
303 * c-attribs.c (handle_patchable_function_entry_attribute): Add
304 function comment. Warn if arguments of the attribute are not positive
305 integer constants.
306
307 2019-04-09 Eric Botcazou <ebotcazou@adacore.com>
308
309 * c-ada-spec.c (print_destructor): Deal with deleting destructors.
310 (dump_ada_declaration) <FUNCTION_DECL>: Likewise.
311
312 2019-04-07 Eric Botcazou <ebotcazou@adacore.com>
313
314 * c-ada-spec.c (is_float128): New predicate extracted from...
315 (dump_ada_node) <COMPLEX_TYPE>: Use it to recognize __cfloat128.
316 <REAL_TYPE>: ...here. Call it.
317
318 2019-04-05 David Malcolm <dmalcolm@redhat.com>
319
320 PR c/89985
321 * c-warn.c (check_address_or_pointer_of_packed_member): Add
322 auto_diagnostic_group. Guard inform calls by result of
323 warning_at call.
324
325 2019-04-05 Marek Polacek <polacek@redhat.com>
326
327 PR c++/89973 - -Waddress-of-packed-member ICE with invalid conversion.
328 * c-warn.c (check_address_or_pointer_of_packed_member): Check the type
329 of RHS.
330
331 2019-04-03 Jason Merrill <jason@redhat.com>
332
333 PR c++/86586 - -fcompare-debug=-Wsign-compare.
334 * c-warn.c (warn_for_sign_compare): Call fold_for_warn.
335
336 2019-04-01 Martin Sebor <msebor@redhat.com>
337
338 PR c/89685
339 * c-attribs.c (handle_copy_attribute): Handle references and
340 non-constant expressions.
341
342 2019-03-22 Jakub Jelinek <jakub@redhat.com>
343
344 PR c++/87481
345 * c.opt (-fconstexpr-ops-limit=): New option.
346
347 2019-03-21 Jakub Jelinek <jakub@redhat.com>
348
349 * c-common.c (per_file_includes_t): Use false as Lazy in hash_set
350 template param.
351
352 2019-03-19 Martin Sebor <msebor@redhat.com>
353
354 PR tree-optimization/89688
355 * c-common.c (braced_list_to_string): Make static.
356 (braced_lists_to_strings): Define new function.
357 * c-common.h (braced_list_to_string): Remove.
358 (braced_lists_to_strings): Declare.
359
360 2019-03-12 Martin Liska <mliska@suse.cz>
361
362 * c-opts.c (c_common_handle_option): Wrap option with %< and %>.
363
364 2019-03-11 Martin Liska <mliska@suse.cz>
365
366 * c-opts.c (c_common_post_options): Wrap apostrophes
367 in gcc internal format with %'.
368
369 2019-03-11 Martin Liska <mliska@suse.cz>
370
371 * c-attribs.c (handle_nocf_check_attribute): Wrap an option name
372 in a string format message and fix GNU coding style.
373 * c-common.c (vector_types_convertible_p): Likewise.
374 (c_build_vec_perm_expr): Likewise.
375 * c-indentation.c (get_visual_column): Likewise.
376 * c-opts.c (c_common_handle_option): Likewise.
377 (c_common_post_options): Likewise.
378 (sanitize_cpp_opts): Likewise.
379 * c-pch.c (c_common_pch_pragma): Likewise.
380 * c-pragma.c (handle_pragma_pack): Likewise.
381
382 2019-03-08 Jakub Jelinek <jakub@redhat.com>
383
384 PR tree-optimization/89550
385 * c-common.c (c_common_truthvalue_conversion): Only set
386 TREE_NO_WARNING if warning_at returned true.
387 * c-warn.c (overflow_warning, warn_logical_operator): Likewise.
388
389 2019-02-25 Sandra Loosemore <sandra@codesourcery.com>
390 Martin Sebor <msebor@gmail.com>
391
392 * c.opt (Wmissing-attributes): Clean up doc string.
393
394 2019-02-25 Jakub Jelinek <jakub@redhat.com>
395
396 PR c/89495
397 * c-format.c (maybe_read_dollar_number): Compute nargnum in
398 HOST_WIDE_INT type to avoid overflows and change overflow_flag
399 checking.
400
401 2019-02-22 Richard Biener <rguenther@suse.de>
402
403 * c-pch.c (no_checksum): Remove.
404 (pch_init): Remove assertion that executable_checksum is not
405 all zero.
406 (c_common_valid_pch): Likewise.
407
408 2019-02-18 Martin Sebor <msebor@redhat.com>
409
410 PR middle-end/89294
411 * c-common.c (invalid_array_size_error): Handle cst_size_not_constant.
412
413 2019-02-16 David Malcolm <dmalcolm@redhat.com>
414
415 PR c++/88680
416 * c-common.c (shorten_compare): Call fold_for_warn on op0 when
417 implementing -Wtype-limits.
418
419 2019-02-11 Martin Sebor <msebor@redhat.com>
420
421 PR c++/87996
422 * c-common.c (invalid_array_size_error): New function.
423 (valid_array_size_p): Call it. Handle size as well as type.
424 * c-common.h (valid_constant_size_p): New function.
425 (enum cst_size_error): New type.
426
427 2019-01-31 David Malcolm <dmalcolm@redhat.com>
428
429 PR c/89122
430 * known-headers.cc (get_stdlib_header_for_name): Add
431 {FLT|DBL|LDBL}_{MAX|MIN} to "hints" array.
432
433 2019-01-31 Jakub Jelinek <jakub@redhat.com>
434
435 PR libstdc++/88170
436 * c-pretty-print.c (pp_c_enumeration_constant): Print always as
437 a C cast in pp_c_flag_gnu_v3 mode.
438
439 2019-01-29 Jakub Jelinek <jakub@redhat.com>
440
441 PR c/86125
442 * c-common.c (c_common_nodes_and_builtins): Build type variants for
443 builtin_structptr_types types even for C.
444
445 2019-01-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
446
447 * c-warn.c (check_address_or_pointer_of_packed_member): Handle the case
448 when rhs is of array type correctly. Fix handling of nested structures.
449 Fix handling of indirect_ref together with nop_expr and/or addr_expr.
450 (check_and_warn_address_or_pointer_of_packed_member): Fix handling of
451 type casts within nested compound expressions.
452
453 2019-01-22 Jakub Jelinek <jakub@redhat.com>
454
455 PR middle-end/88968
456 * c-omp.c (c_finish_omp_atomic): For bitfield atomics, update type
457 variable after using BIT_FIELD_REF.
458
459 2019-01-18 H.J. Lu <hongjiu.lu@intel.com>
460
461 PR c/51628
462 PR c/88664
463 * c-common.h (warn_for_address_or_pointer_of_packed_member):
464 Remove the boolean argument.
465 * c-warn.c (check_address_of_packed_member): Renamed to ...
466 (check_address_or_pointer_of_packed_member): This. Also
467 warn pointer conversion.
468 (check_and_warn_address_of_packed_member): Renamed to ...
469 (check_and_warn_address_or_pointer_of_packed_member): This.
470 Also warn pointer conversion.
471 (warn_for_address_or_pointer_of_packed_member): Remove the
472 boolean argument. Don't check pointer conversion here.
473
474 2019-01-15 Richard Sandiford <richard.sandiford@arm.com>
475
476 PR inline-asm/52813
477 * c.opt (Wdeprecated): Move documentation and variable to common.opt.
478
479 2019-01-14 Jakub Jelinek <jakub@redhat.com>
480
481 * c-cppbuiltin.c (c_cpp_builtin): Define __cpp_guaranteed_copy_elision
482 and __cpp_nontype_template_parameter_auto. Add a comment that
483 __cpp_template_auto is deprecated.
484
485 2019-01-14 Tom Honermann <tom@honermann.net>
486
487 Implement P0482R5, char8_t: A type for UTF-8 characters and strings
488 * c-common.c (c_common_reswords): Add char8_t.
489 (fix_string_type): Use char8_t for the type of u8 string literals.
490 (c_common_get_alias_set): char8_t doesn't alias.
491 (c_common_nodes_and_builtins): Define char8_t as a builtin type in
492 C++.
493 (c_stddef_cpp_builtins): Add __CHAR8_TYPE__.
494 (keyword_begins_type_specifier): Add RID_CHAR8.
495 * c-common.h (rid): Add RID_CHAR8.
496 (c_tree_index): Add CTI_CHAR8_TYPE and CTI_CHAR8_ARRAY_TYPE.
497 Define D_CXX_CHAR8_T and D_CXX_CHAR8_T_FLAGS.
498 Define char8_type_node and char8_array_type_node.
499 * c-cppbuiltin.c (cpp_atomic_builtins): Predefine
500 __GCC_ATOMIC_CHAR8_T_LOCK_FREE.
501 (c_cpp_builtins): Predefine __cpp_char8_t.
502 * c-lex.c (lex_string): Use char8_array_type_node as the type of
503 CPP_UTF8STRING.
504 (lex_charconst): Use char8_type_node as the type of CPP_UTF8CHAR.
505 * c-opts.c: If not otherwise specified, enable -fchar8_t when
506 targeting C++2a.
507 * c.opt: Add the -fchar8_t command line option.
508
509 2019-01-14 Martin Sebor <msebor@redhat.com>
510
511 PR target/88638
512 * c-attribs.c (positional_argument): Call valid_format_string_type_p
513 and issue errors if it fails.
514 * c-common.h (valid_format_string_type_p): Declare.
515 * c-format.c (valid_stringptr_type_p): Rename...
516 (valid_format_string_type_p): ...to this and make extern.
517 (handle_format_arg_attribute): Adjust to new name.
518 (check_format_string): Same.
519
520 2019-01-13 H.J. Lu <hongjiu.lu@intel.com>
521
522 * c-warn.c (warn_for_address_or_pointer_of_packed_member):
523 Replace "may may" with "may" in warning message.
524
525 2019-01-07 Jakub Jelinek <jakub@redhat.com>
526
527 PR c++/85052
528 * c-common.h (enum rid): Add RID_BUILTIN_CONVERTVECTOR.
529 (c_build_vec_convert): Declare.
530 * c-common.c (c_build_vec_convert): New function.
531
532 2019-01-04 Martin Sebor <msebor@redhat.com>
533
534 PR c/88546
535 * c-attribs.c (handle_copy_attribute): Avoid copying attribute leaf.
536 Handle C++ empty throw specification and C11 _Noreturn.
537 (has_attribute): Also handle C11 _Noreturn.
538
539 2019-01-04 Martin Sebor <msebor@redhat.com>
540
541 PR c/88363
542 * c-attribs.c (positional_argument): Also accept enumerated types.
543
544 2019-01-01 Jakub Jelinek <jakub@redhat.com>
545
546 Update copyright years.
547
548 2018-12-20 H.J. Lu <hongjiu.lu@intel.com>
549
550 PR c/51628
551 * c-common.h (warn_for_address_or_pointer_of_packed_member): New.
552 * c-warn.c (check_alignment_of_packed_member): New function.
553 (check_address_of_packed_member): Likewise.
554 (check_and_warn_address_of_packed_member): Likewise.
555 (warn_for_address_or_pointer_of_packed_member): Likewise.
556 * c.opt: Add -Wno-address-of-packed-member.
557
558 2018-12-20 David Malcolm <dmalcolm@redhat.com>
559
560 PR c++/87504
561 * c-warn.c (get_outermost_macro_expansion): New function.
562 (spelled_the_same_p): Use it to unwind the macro expansions, and
563 compare the outermost macro in each nested expansion, rather than
564 the innermost.
565
566 2018-12-19 David Malcolm <dmalcolm@redhat.com>
567
568 PR c++/87504
569 * c-common.h (warn_tautological_cmp): Convert 1st param from
570 location_t to const op_location_t &.
571 * c-warn.c (find_array_ref_with_const_idx_r): Call fold_for_warn
572 when testing for INTEGER_CST.
573 (warn_tautological_bitwise_comparison): Convert 1st param from
574 location_t to const op_location_t &; use it to build a
575 binary_op_rich_location, and use this.
576 (spelled_the_same_p): New function.
577 (warn_tautological_cmp): Convert 1st param from location_t to
578 const op_location_t &. Warn for macro expansions if
579 spelled_the_same_p. Use binary_op_rich_location.
580
581 2018-12-19 David Malcolm <dmalcolm@redhat.com>
582
583 PR c++/43064
584 PR c++/43486
585 * c-common.c (unsafe_conversion_p): Fold any location wrapper.
586 (verify_tree): Handle location wrappers.
587 (c_common_truthvalue_conversion): Strip any location wrapper.
588 Handle CONST_DECL.
589 (fold_offsetof): Strip any location wrapper.
590 (complete_array_type): Likewise for initial_value.
591 (convert_vector_to_array_for_subscript): Call fold_for_warn on the
592 index before checking for INTEGER_CST.
593 * c-pretty-print.c (c_pretty_printer::primary_expression): Don't
594 print parentheses around location wrappers.
595 * c-warn.c (warn_logical_operator): Call fold_for_warn on op_right
596 before checking for INTEGER_CST.
597 (warn_tautological_bitwise_comparison): Call
598 tree_strip_any_location_wrapper on lhs, rhs, and bitop's operand
599 before checking for INTEGER_CST.
600 (readonly_error): Strip any location wrapper.
601 (warn_array_subscript_with_type_char): Strip location wrappers
602 before checking for INTEGER_CST. Use the location of the index if
603 available.
604
605 2018-12-06 Jason Merrill <jason@redhat.com>
606
607 PR c++/88136 - -Wdeprecated-copy false positives
608 * c.opt (Wdeprecated-copy-dtor): New.
609 (Wdeprecated-copy): Move to -Wextra.
610
611 2018-11-29 Martin Sebor <msebor@redhat.com>
612
613 PR c/88172
614 PR testsuite/88208
615 * c-attribs.c (common_handle_aligned_attribute): Silently avoid setting
616 alignments to values less than the target requires.
617 (has_attribute): For attribute aligned consider both the attribute
618 and the alignment bits.
619 * c-common.c (c_init_attributes): Optionally issue a warning for
620 zero alignment.
621
622 2018-11-28 Martin Sebor <msebor@redhat.com>
623
624 PR c/88065
625 PR c/87297
626 * c-warn.c (sizeof_pointer_memaccess_warning): Bail if source
627 or destination is an error.
628
629 2018-11-28 Jakub Jelinek <jakub@redhat.com>
630
631 PR c++/88215
632 * c-ubsan.c: Include langhooks.h.
633 (ubsan_instrument_division): Change gcc_assert that main variants
634 of op0 and op1 types are equal to gcc_checking_assert that the
635 main variants are compatible types.
636
637 2018-11-27 Eric Botcazou <ebotcazou@adacore.com>
638
639 * c-ada-spec.c: Include stringpool.h.
640 (has_static_fields): Return false for incomplete types.
641 (is_tagged_type): Likewise.
642 (has_nontrivial_methods): Likewise.
643 (dump_ada_node) <INTEGER_TYPE>: Deal specifically with __int128.
644 (struct overloaded_name_hash): New structure.
645 (struct overloaded_name_hasher): Likewise.
646 (overloaded_names): New global variable.
647 (init_overloaded_names): New static function.
648 (overloaded_name_p): New predicate.
649 (dump_ada_declaration) <TYPE_DECL>: Tidy up and set TREE_VISITED
650 on the TYPE_STUB_DECL of the original type of a typedef, if any.
651 <FUNCTION_DECL>: Bail out for an unsupported overloaded name.
652 Remove always-true condition and dump forward types.
653 (dump_ada_specs): Delete overloaded_names.
654
655 2018-11-20 Martin Sebor <msebor@redhat.com>
656
657 * c-attribs.c (type_for_vector_size): New function.
658 (type_valid_for_vector_size): Same.
659 (handle_vector_size_attribute): Move code to the functions above
660 and call them.
661 (validate_attribute, has_attribute): New functions.
662 * c-common.h (has_attribute): Declare.
663 (rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
664 * c-common.c (c_common_resword): Same.
665
666 2018-11-16 Jason Merrill <jason@redhat.com>
667
668 * c-lex.c (c_common_has_attribute): Handle likely/unlikely.
669 * c-attribs.c (attr_cold_hot_exclusions): Make public.
670
671 2018-11-16 Jakub Jelinek <jakub@redhat.com>
672
673 PR middle-end/87854
674 * c-common.c (fix_string_type): Reject string literals larger than
675 TYPE_MAX_VALUE (ssizetype) bytes.
676
677 2018-11-15 Martin Sebor <msebor@redhat.com>
678
679 PR c++/87541
680 PR c++/87542
681 * c-attribs.c (positional_argument): New function.
682 (handle_alloc_size_attribute): Use it and simplify.
683 (handle_alloc_align_attribute): Same.
684 (handle_assume_aligned_attribute): Same.
685 (handle_nonnull_attribute): Same.
686 * c-common.c (check_function_arguments): Pass fntype to
687 check_function_format.
688 * c-common.h (check_function_format): Add an argument.
689 (PosArgFlags, positional_argument): Declare new type and function.
690 * c-format.c (decode_format_attr): Add arguments.
691 (check_format_string, get_constant): Same.
692 (convert_format_name_to_system_name): Adjust.
693
694 2018-11-15 David Malcolm <dmalcolm@redhat.com>
695
696 PR other/19165
697 * c-opts.c (c_diagnostic_finalizer): Add diagnostic_t param.
698
699 2018-11-14 Jakub Jelinek <jakub@redhat.com>
700
701 P1236R1 - Signed integers are two's complement
702 * c-warn.c (maybe_warn_shift_overflow): Don't warn for c++2a.
703 * c-ubsan.c (ubsan_instrument_shift): Make signed shifts
704 with in-range second operand well defined for -std=c++2a.
705
706 PR other/88007
707 * c-common.c (parse_optimize_options): Allocate option string from
708 opts_obstack rather than as GC memory. Move the allocation after
709 warning for invalid option.
710
711 2018-11-13 David Malcolm <dmalcolm@redhat.com>
712
713 * c-common.c (c_get_substring_location): Update for renaming of
714 get_source_location_for_substring to get_location_within_string.
715 * c-lex.c: Replace "source_location" with "location_t".
716 * c-opts.c: Likewise.
717 * c-ppoutput.c: Likewise.
718
719 2018-11-13 Martin Sebor <msebor@redhat.com>
720
721 PR middle-end/81824
722 * c-attribs.c (handle_copy_attribute): Exclude inlining attributes.
723 (handle_tls_model_attribute): Improve diagnostics.
724
725 2018-11-12 Jason Merrill <jason@redhat.com>
726
727 * c-cppbuiltin.c (c_cpp_builtins): Define
728 __cpp_impl_destroying_delete.
729
730 * c-cppbuiltin.c (c_cpp_builtins): Change __cpp_explicit_bool to
731 __cpp_conditional_explicit.
732
733 2018-11-09 Martin Sebor <msebor@redhat.com>
734
735 PR middle-end/81824
736 * c-attribs.c (handle_copy_attribute): New function.
737
738 2018-11-09 Martin Sebor <msebor@redhat.com>
739
740 PR c/87795
741 * c-common.c (check_user_alignment): Use MAX_OFILE_ALIGNMENT.
742
743 2018-11-08 Jakub Jelinek <jakub@redhat.com>
744
745 * c-common.h (c_finish_omp_taskgroup): Add CLAUSES argument.
746 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
747 enum omp_memory_order MEMORY_ORDER.
748 (c_finish_omp_flush): Add MO argument.
749 (c_omp_depend_t_p, c_finish_omp_depobj): Declare.
750 (c_finish_omp_for): Add FINAL_P argument.
751 * c-omp.c: Include memmodel.h.
752 (c_finish_omp_taskgroup): Add CLAUSES argument. Set
753 OMP_TASKGROUP_CLAUSES to it.
754 (c_finish_omp_atomic): Replace bool SEQ_CST argument with
755 enum omp_memory_order MEMORY_ORDER. Set OMP_ATOMIC_MEMORY_ORDER
756 instead of OMP_ATOMIC_SEQ_CST.
757 (c_omp_depend_t_p, c_finish_omp_depobj): New functions.
758 (c_finish_omp_flush): Add MO argument, if not MEMMODEL_LAST, emit
759 __atomic_thread_fence call with the given value.
760 (check_omp_for_incr_expr): Formatting fixes.
761 (c_finish_omp_for): Add FINAL_P argument. Allow NE_EXPR
762 even in OpenMP loops, diagnose if NE_EXPR and incr expression
763 is not constant expression 1 or -1. Transform NE_EXPR loops
764 with iterators pointers to VLA into LT_EXPR or GT_EXPR loops.
765 (c_omp_check_loop_iv_r): Look for orig decl of C++ range for
766 loops too.
767 (c_omp_split_clauses): Add support for combined
768 #pragma omp parallel master and
769 #pragma omp {,parallel }master taskloop{, simd} constructs.
770 Handle OMP_CLAUSE_IN_REDUCTION. Handle OMP_CLAUSE_REDUCTION_TASK.
771 Handle OMP_CLAUSE_NONTEMPORAL. Handle splitting OMP_CLAUSE_IF
772 also to OMP_SIMD. Copy OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
773 (c_omp_predetermined_sharing): Don't return
774 OMP_CLAUSE_DEFAULT_SHARED for const qualified decls.
775 * c-pragma.c (omp_pragmas): Add PRAGMA_OMP_DEPOBJ and
776 PRAGMA_OMP_REQUIRES.
777 * c-pragma.h (enum pragma_kind): Likewise.
778 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_NONTEMPORAL
779 and PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
780
781 2018-11-08 David Malcolm <dmalcolm@redhat.com>
782
783 * c-format.c (gcc_dump_printf_char_table): Add entry for %f.
784
785 2018-11-08 David Malcolm <dmalcolm@redhat.com>
786
787 * c-format.c (local_cgraph_node_ptr_node): New variable.
788 (gcc_dump_printf_char_table): Add entry for %C.
789 (get_pointer_to_named_type): New function, taken from the handling
790 code for "gimple *" from...
791 (init_dynamic_diag_info): ...here. Add handling for
792 "cgraph_node *".
793 * c-format.h (T_CGRAPH_NODE): New.
794
795 2018-10-19 Jason Merrill <jason@redhat.com>
796
797 * c-cppbuiltin.c (c_cpp_builtins): Add
798 __cpp_nontype_template_parameter_class.
799
800 2018-10-31 Nathan Sidwell <nathan@acm.org>
801
802 * c-opts.c (c_finish_options): Force command line macro
803 location. Refactor to avoid repeating main debug hook.
804 (push_command_line_include): Clarify comment.
805
806 * c-opts.c (c_finish_options): Adjust cpp_force_token_locations call.
807
808 2018-10-30 Martin Sebor <msebor@redhat.com>
809
810 PR middle-end/87041
811 * c-format.c (check_format_types): Avoid diagnosing null pointer
812 arguments to printf-family of functions.
813
814 2018-10-30 Marek Polacek <polacek@redhat.com>
815
816 Implement P0892R2, explicit(bool).
817 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_explicit_bool.
818
819 2018-10-29 David Malcolm <dmalcolm@redhat.com>
820
821 * name-hint.h (name_hint::take_deferred): New member function.
822
823 2018-10-29 David Malcolm <dmalcolm@redhat.com>
824
825 PR c++/56856
826 * c-common.c (check_function_sentinel): Call fold_for_warn on the
827 argument.
828 (check_function_restrict): Rename param "argarray" to
829 "unfolded_argarray", and make a copy named "argarray", calling
830 fold_for_warn on each argument.
831 (check_function_arguments): Add note about responsibility for
832 folding the arguments.
833
834 2018-10-17 Joseph Myers <joseph@codesourcery.com>
835
836 * c-common.c (flag_isoc2x): New variable.
837 * c-common.h (clk_c): Update comment to reference C2X.
838 (flag_isoc99, flag_isoc11): Update comments to reference future
839 standard versions in general.
840 (flag_isoc2x): Declare.
841 * c-opts.c (set_std_c2x): New function.
842 (c_common_handle_option): Handle -std=c2x and -std=gnu2x.
843 (set_std_c89, set_std_c99, set_std_c11, set_std_c17): Set
844 flag_isoc2x to 0.
845 * c.opt (Wc11-c2x-compat, std=c2x, std=gnu2x): New options.
846
847 2018-10-17 Joseph Myers <joseph@codesourcery.com>
848
849 * c.opt (std=c17, std=c18, std=gnu17, std=gnu18, std=iso9899:2017)
850 (std=iso9899:2018): Document C17 as published in 2018.
851
852 2018-10-12 Christophe Lyon <christophe.lyon@linaro.org>
853
854 PR c++/87364
855 * c-pretty-print.c (c_pretty_printer::constant): Fix typo.
856
857 2018-10-11 Will Wray <wjwray@gmail.com>
858
859 PR c++/87364
860 * c-pretty-print.h (pp_c_type_cast): Prototype.
861 (pp_c_integer_constant): Likewise.
862 * c-pretty-print.c (pp_c_type_cast): No longer static.
863 (pp_c_integer_constant): Likewise.
864 (pp_c_enumeration_constant): Fix loop termination when finding
865 name of constant. No longer returns a value. Call
866 pp_c_integer_constant.
867 (c_pretty_printer::constant): Update for changes to
868 pp_c_enumeration_constant.
869
870 2018-10-11 Jakub Jelinek <jakub@redhat.com>
871
872 * c-lex.c (c_common_has_attribute): Return 201803 instead of 20180312
873 for no_unique_address.
874
875 2018-10-09 David Malcolm <dmalcolm@redhat.com>
876
877 * c-common.c (c_option_controlling_cpp_error): Rename to...
878 (c_option_controlling_cpp_diagnostic): ...this, and convert
879 "reason" from int to enum.
880 (c_cpp_error): Rename to...
881 (c_cpp_diagnostic): ...this, converting level and reason to enums.
882 * c-common.h (c_cpp_error): Rename to...
883 (c_cpp_diagnostic): ...this, converting level and reason to enums.
884 * c-opts.c (c_common_init_options): Update for renaming.
885
886 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
887
888 PR c/87286
889 * c-common.c (vector_types_compatible_elements_p): Use
890 INTEGRAL_TYPE_P instead of checking only for INTEGER_TYPE.
891
892 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
893
894 * c-attribs.c (get_priority): Add a warning flag warn_prio_ctor_dtor
895 to generate constructor destructor priority warning.
896 * c.opt (-Wprio-ctor-dtor): New option.
897
898 2018-10-01 Jason Merrill <jason@redhat.com>
899
900 * c-lex.c (c_common_has_attribute): Add no_unique_address.
901
902 2018-10-01 Eric Botcazou <ebotcazou@adacore.com>
903
904 * c-ada-spec.c (get_underlying_decl): Get to the main type variant.
905 (dump_ada_node): Add const keyword.
906
907 2018-09-25 Martin Liska <mliska@suse.cz>
908
909 * c-common.c (c_common_truthvalue_conversion):
910 Remove Pascal from documentation.
911
912 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
913
914 * c-ada-spec.c: Include diagnostic.h.
915 (dump_ada_declaration) <RECORD_TYPE>: Issue a warning on packed layout.
916
917 2018-09-19 Marek Polacek <polacek@redhat.com>
918
919 * c.opt (Wclass-conversion): New.
920
921 2018-09-17 David Malcolm <dmalcolm@redhat.com>
922
923 * c-format.c (range_label_for_format_type_mismatch::get_text):
924 Update for new param.
925
926 2018-09-17 David Malcolm <dmalcolm@redhat.com>
927
928 * c-format.c (format_warning_at_char): Update for introduction of
929 format_string_diagnostic_t.
930 (format_type_warning): Likewise.
931
932 2018-09-17 Martin Jambor <mjambor@suse.cz>
933
934 PR c/63886
935 * c.opt (Wabsolute-value): New.
936
937 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
938
939 * c-common.c (complete_flexible_array_elts): New helper function.
940 * c-common.h (complete_flexible_array_elts): Declare.
941
942 2018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
943
944 * c-common.c (braced_list_to_string): Remove eval parameter.
945 Add some more checks. Always create zero-terminated STRING_CST.
946 * c-common.h (braced_list_to_string): Adjust prototype.
947
948 2018-08-27 David Malcolm <dmalcolm@redhat.com>
949
950 PR 87091
951 * c-common.c (c_cpp_error): Update for conversion of show_caret_p
952 to a tri-state.
953 (maybe_suggest_missing_token_insertion): Likewise.
954 (maybe_add_include_fixit): Add param "override_location". If set,
955 and source-printing is enabled, then override the rich_location's
956 primary location with that of the insertion point for the fix-it
957 hint, marking it with SHOW_LINES_WITHOUT_RANGE.
958 * c-common.h (extern void maybe_add_include_fixit): Add bool
959 param.
960 * c-format.c (selftest::test_type_mismatch_range_labels): Update
961 for conversion of show_caret_p to a tri-state.
962 * c-warn.c (warn_for_restrict): Likewise.
963 * known-headers.cc
964 (suggest_missing_header::~suggest_missing_header): Update call to
965 maybe_add_include_fixit to suggest overriding the location, as it
966 is for a note.
967
968 2018-08-27 Martin Liska <mliska@suse.cz>
969
970 * c-common.c (check_function_restrict): Use new function
971 fndecl_built_in_p and remove check for FUNCTION_DECL if
972 possible.
973 (check_builtin_function_arguments): Likewise.
974 (reject_gcc_builtin): Likewise.
975 * c-warn.c (sizeof_pointer_memaccess_warning): Likewise.
976
977 2018-08-26 Marek Polacek <polacek@redhat.com>
978
979 PR c++/87029, Implement -Wredundant-move.
980 * c.opt (Wredundant-move): New option.
981
982 2018-08-21 Marek Polacek <polacek@redhat.com>
983
984 PR c++/86981, Implement -Wpessimizing-move.
985 * c.opt (Wpessimizing-move): New option.
986
987 2018-08-20 David Malcolm <dmalcolm@redhat.com>
988
989 PR other/84889
990 * c-attribs.c (common_handle_aligned_attribute): Add
991 auto_diagnostic_group instance.
992 * c-indentation.c (warn_for_misleading_indentation): Likewise.
993 * c-opts.c (c_common_post_options): Likewise.
994 * c-warn.c (warn_logical_not_parentheses): Likewise.
995 (warn_duplicated_cond_add_or_warn): Likewise.
996 (warn_for_multistatement_macros): Likewise.
997
998 2018-08-20 Nathan Sidwell <nathan@acm.org>
999
1000 * c-ada-spec.c (macro_length, dump_ada_macros): Adjust macro parm
1001 access.
1002
1003 2018-08-17 Nathan Sidwell <nathan@acm.org>
1004
1005 * c-cppbuiltin.c (struct lazy_hex_fp_value_struct): Remove macro
1006 field.
1007 (laxy_hex_fp_value_count): Make unsigned.
1008 (lazy_hex_fp_value): Provided with macro & lazy number. Directly
1009 manipulate the macro.
1010 (builtin_defin_with_hex_fp_value): Adjust callback name, use
1011 cpp_define_lazily.
1012
1013 2018-08-17 David Malcolm <dmalcolm@redhat.com>
1014
1015 * c-format.c (enum format_type): Add gcc_dump_printf_format_type.
1016 (gcc_dump_printf_length_specs): New.
1017 (gcc_dump_printf_flag_pairs): New.
1018 (gcc_dump_printf_flag_specs): New.
1019 (gcc_dump_printf_char_table): New.
1020 (format_types_orig): Add entry for "gcc_dump_printf".
1021 (init_dynamic_diag_info): Set up length_char_specs and
1022 conversion_specs for gcc_dump_printf_format_type.
1023 (handle_format_attribute): Handle gcc_dump_printf_format_type.
1024
1025 2018-08-17 Nathan Sidwell <nathan@acm.org>
1026
1027 * c-ada-spec.c (macro_length, dump_ada_macros): Constify.
1028
1029 * c-ada-spec.c: Don't #include "cpp-id-data.h"
1030 * c-cppbuiltin.c: Likewise.
1031
1032 2018-08-17 Martin Liska <mliska@suse.cz>
1033
1034 * c.opt: Remove Warn, Init and Report for options with
1035 Ignore/Deprecated flag. Warning is done automatically for
1036 Deprecated flags.
1037
1038 2018-08-16 David Malcolm <dmalcolm@redhat.com>
1039
1040 PR c++/70693
1041 * c-common.c (selftest::c_family_tests): Call
1042 selftest::c_indentation_c_tests.
1043 * c-common.h (selftest::c_indentation_c_tests): New decl.
1044 * c-indentation.c: Include "selftest.h".
1045 (next_tab_stop): Add "tab_width" param, rather than accessing
1046 cpp_opts.
1047 (get_visual_column): Likewise. Clarify comment. Bulletproof
1048 against reading past the end of the line.
1049 (get_first_nws_vis_column): Add "tab_width" param.
1050 (detect_intervening_unindent): Likewise.
1051 (should_warn_for_misleading_indentation): Read tab width from
1052 cpp_opts and pass around.
1053 (selftest::test_next_tab_stop): New test.
1054 (selftest::assert_get_visual_column_succeeds): New function.
1055 (ASSERT_GET_VISUAL_COLUMN_SUCCEEDS): New macro.
1056 (selftest::assert_get_visual_column_fails): New function.
1057 (ASSERT_GET_VISUAL_COLUMN_FAILS): New macro.
1058 (selftest::test_get_visual_column): New test.
1059 (selftest::c_indentation_c_tests): New function.
1060
1061 2018-08-16 Nathan Sidwell <nathan@acm.org>
1062
1063 * c-ada-spec.c (count_ada_macro): Use cpp_user_macro_p.
1064 (store_ada_macro): Likewise.
1065 * c-ppoutput.c (cb_used_define, dump_macro): Likewise.
1066 * c-spellcheck.cc (should-suggest_as_macro_p): Likewise,
1067
1068 2018-08-15 David Malcolm <dmalcolm@redhat.com>
1069
1070 * c-format.c: Include "selftest-diagnostic.h" and
1071 "gcc-rich-location.h".
1072 (format_warning_at_char): Pass NULL for new label params of
1073 format_warning_va.
1074 (class indirection_suffix): New class.
1075 (class range_label_for_format_type_mismatch): New class.
1076 (format_type_warning): Move logic for generating "*" suffix to
1077 class indirection_suffix. Create "fmt_label" and "param_label"
1078 to show their types, and pass them to the
1079 format_warning_at_substring calls.
1080 (selftest::test_type_mismatch_range_labels): New test.
1081 (selftest::c_format_c_tests): Call it.
1082
1083 2018-08-13 Martin Sebor <msebor@redhat.com>
1084
1085 PR tree-optimization/71625
1086 * c-common.c (braced_list_to_string): New function.
1087 * c-common.h (braced_list_to_string): Declare it.
1088
1089 2018-08-08 Nathan Sidwell <nathan@acm.org>
1090
1091 * c-common.c (try_to_locate_new_include_inertion_point): Use
1092 linemap_included_from_linemap.
1093 * c-lex.c (fe_file_change): Use linemap_included_from.
1094 * c-ppoutput.c (pp_file_change): Likewise.
1095
1096 2018-08-01 Martin Sebor <msebor@redhat.com>
1097
1098 PR tree-optimization/86650
1099 * c-format.c (gcc_tdiag_char_table): Update comment for "%G".
1100 (gcc_cdiag_char_table, gcc_cxxdiag_char_table): Same.
1101 (init_dynamic_diag_info): Update from "gcall *" to "gimple *".
1102 * c-format.h (T89_G): Update to be "gimple *" rather than
1103 "gcall *".
1104 (local_gcall_ptr_node): Rename...
1105 (local_gimple_ptr_node): ...to this.
1106
1107 2018-07-31 David Malcolm <dmalcolm@redhat.com>
1108
1109 * c-format.c (PP_FORMAT_CHAR_TABLE): New macro, based on existing
1110 table entries for gcc_diag_char_table, and the 'Z' entry from
1111 gcc_tdiag_char_table, changing the "chain" entry for 'Z' from
1112 &gcc_tdiag_char_table[0] to &gcc_diag_char_table[0].
1113 (gcc_diag_char_table): Use PP_FORMAT_CHAR_TABLE, implicitly
1114 adding missing "Z" for this table. Remove erroneous "G" and "K"
1115 entries.
1116 (gcc_tdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
1117 (gcc_cdiag_char_table): Use PP_FORMAT_CHAR_TABLE.
1118 (gcc_cxxdiag_char_table): Use PP_FORMAT_CHAR_TABLE. Remove "v".
1119
1120 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
1121
1122 * c-common.c (speculation_safe_resolve_call): New function.
1123 (speculation_safe_resolve_params): New function.
1124 (speculation_safe_resolve_return): New function.
1125 (resolve_overloaded_builtin): Handle __builtin_speculation_safe_value.
1126 * c-cppbuiltin.c (c_cpp_builtins): Add pre-define for
1127 __HAVE_SPECULATION_SAFE_VALUE.
1128
1129 2018-07-20 David Malcolm <dmalcolm@redhat.com>
1130
1131 * c-common.c (c_cpp_error): Remove redundant "line_table"
1132 parameter from call to rich_location::set_range.
1133 (maybe_suggest_missing_token_insertion): Likewise.
1134
1135 2018-07-20 Martin Sebor <msebor@redhat.com>
1136
1137 PR middle-end/82063
1138 * c.opt (-Warray-bounds): Remove redundant -Wall.
1139
1140 2018-07-20 Martin Sebor <msebor@redhat.com>
1141
1142 PR middle-end/82063
1143 * c-common.h (c_common_handle_option): Change function argument
1144 to HOST_WIDE_INT.
1145 * c-opts.c (c_common_init_options): Same.
1146 (c_common_handle_option): Same. Remove special handling of
1147 OPT_Walloca_larger_than_ and OPT_Wvla_larger_than_.
1148 * c.opt (-Walloc-size-larger-than, -Walloca-larger-than): Change
1149 options to take a HOST_WIDE_INT argument and accept a byte-size
1150 suffix. Initialize.
1151 (-Wvla-larger-than): Same.
1152 (-Wno-alloc-size-larger-than, -Wno-alloca-larger-than): New.
1153 (-Wno-vla-larger-than): Same.
1154
1155 2018-07-12 Jakub Jelinek <jakub@redhat.com>
1156
1157 * c-attribs.c (c_common_attribute_table): Add
1158 "omp declare target implicit" attribute.
1159
1160 2018-07-12 Richard Biener <rguenther@suse.de>
1161
1162 PR c/86453
1163 * c-attribs.c (handle_packed_attribute): Do not build a variant
1164 type with TYPE_PACKED, instead ignore the attribute if we may
1165 not apply to the original type.
1166
1167 2018-07-10 Jakub Jelinek <jakub@redhat.com>
1168
1169 PR c++/86443
1170 * c-omp.c (c_omp_check_loop_iv_r, c_omp_check_loop_iv): Allow declv
1171 to contain TREE_LIST for both the original class iterator and the
1172 "last" helper var.
1173
1174 2018-07-07 Eric Botcazou <ebotcazou@adacore.com>
1175
1176 * c-ada-spec.c (to_ada_name): Remove index parameter.
1177 (pp_ada_tree_identifier): Likewise.
1178 (dump_ada_macros): Adjust call to to_ada_name.
1179 (struct overloaded_name_hash): Delete.
1180 (struct overloaded_name_hasher): Likewise.
1181 (overloaded_names): Likewise.
1182 (compute_overloading_index): Likewise.
1183 (dump_ada_decl_name): Do not call compute_overloading_index and
1184 adjust calls to pp_ada_tree_identifier.
1185 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
1186 (dump_ada_import): Add spc parameter and switch to aspect syntax.
1187 (dump_ada_function_declaration): Adjust call to pp_ada_tree_identifier.
1188 (dump_ada_enum_type): Remove type and display_convention parameters.
1189 Adjust calls to pp_ada_tree_identifier.
1190 (dump_ada_node): Likewise and for dump_ada_structure.
1191 (dump_nested_type) <ENUMERAL_TYPE>: Adjust call to dump_ada_enum_type
1192 and tidy up.
1193 <RECORD_TYPE>: Adjust call to dump_ada_structure and switch to aspect
1194 syntax.
1195 (print_constructor): Adjust call to pp_ada_tree_identifier.
1196 (print_destructor): Likewise.
1197 (dump_ada_declaration): Switch to aspect syntax.
1198 (dump_ada_structure): Likewise and tidy up. Replace display_convention
1199 parameter with nested parameter.
1200 (dump_ads): Emit pragma Ada_2012 in lieu of pragma Ada_2005.
1201 (dump_ada_specs): Do not delete overloaded_names table.
1202
1203 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
1204
1205 PR target/86324
1206 * c-attribs.c (handle_mode_attribute): Call translate_mode_attribute
1207 target hook.
1208
1209 2018-07-05 Nathan Sidwell <nathan@acm.org>
1210
1211 * c-lex.c (fe_file_change): Check SYSTEM_IMPLICIT_EXTERN_C not
1212 NO_IMPLICIT_EXTERN_C.
1213
1214 2018-06-28 Martin Liska <mliska@suse.cz>
1215
1216 * cppspec.c: Include opt-suggestions.h.
1217
1218 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
1219 Thomas Schwinge <thomas@codesourcery.com>
1220 Cesar Philippidis <cesar@codesourcery.com>
1221
1222 * c-pragma.h (enum pragma_omp_clause): Add
1223 PRAGMA_OACC_CLAUSE_{FINALIZE,IF_PRESENT}. Remove
1224 PRAGMA_OACC_CLAUSE_PRESENT_OR_{COPY,COPYIN,COPYOUT,CREATE}.
1225
1226 2018-06-20 Jakub Jelinek <jakub@redhat.com>
1227
1228 PR c++/86210
1229 * c-common.c (check_nonnull_arg): Use fold_for_warn. Adjust obsolete
1230 comment.
1231
1232 2018-06-18 Martin Sebor <msebor@redhat.com>
1233
1234 PR middle-end/85602
1235 * c-warn.c (sizeof_pointer_memaccess_warning): Check for attribute
1236 nonstring.
1237
1238 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
1239
1240 * c-common.c (c_common_truthvalue_conversion): Handle ABSU_EXPR.
1241
1242 2018-06-13 Jason Merrill <jason@redhat.com>
1243
1244 * c-opts.c (c_common_post_options): Warn about useless -Wabi.
1245 (c_common_handle_option) [OPT_Wabi_]: Remove flag_abi_compat_version
1246 handling.
1247
1248 PR c++/86094 - wrong code with defaulted move ctor.
1249 * c-opts.c (c_common_post_options): Bump the current ABI version to
1250 13. Set warn_abi_version and flag_abi_compat_version to the current
1251 version rather than 0. Fix defaulting flag_abi_compat_version from
1252 warn_abi_version.
1253
1254 2018-06-12 Martin Sebor <msebor@redhat.com>
1255
1256 PR c/85931
1257 * c-warn.c (sizeof_pointer_memaccess_warning): Avoid warning when
1258 sizeof source and destination yields the same value.
1259
1260 2018-06-12 Martin Liska <mliska@suse.cz>
1261
1262 * c.opt: Make MPX-related options as Deprecated.
1263
1264 2018-06-08 David Malcolm <dmalcolm@redhat.com>
1265
1266 * c-pretty-print.c (c_pretty_printer::statement): Use TDF_NONE
1267 rather than 0.
1268
1269 2018-06-08 Martin Liska <mliska@suse.cz>
1270
1271 * c-attribs.c (handle_bnd_variable_size_attribute): Remove support
1272 for MPX (macros, related functions, fields in cgraph_node, ...).
1273 (handle_bnd_legacy): Likewise.
1274 (handle_bnd_instrument): Likewise.
1275 * c.opt: Likewise.
1276
1277 2018-06-06 Jakub Jelinek <jakub@redhat.com>
1278
1279 PR c++/86068
1280 * c-cppbuiltin.c (c_cpp_builtins): Fix a typo, set
1281 __cpp_transactional_memory to 201500 instead of 210500.
1282
1283 2018-06-06 Jason Merrill <jason@redhat.com>
1284
1285 PR c++/85710 - ICE with -Wmemset-elt-size.
1286 * c-warn.c (warn_for_memset): Don't crash on incomplete element type.
1287
1288 2018-06-01 Jason Merrill <jason@redhat.com>
1289
1290 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_deduction_guides to
1291 201703.
1292
1293 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
1294
1295 * c-ada-spec.c (dump_ada_declaration) <TYPE_DECL>: Generate a forward
1296 declaration for a typedef independently of whether the declaration of
1297 the subtype is generated.
1298
1299 2018-05-31 Martin Sebor <msebor@redhat.com>
1300
1301 PR c/82063
1302 * c.opt (-Wno-alloc-size-larger-than): New option.
1303
1304 2018-04-22 David Pagan <dave.pagan@oracle.com>
1305
1306 PR c/55976
1307 * c-opts.c (c_common_post_options): Set default for warn_return_type
1308 for C++/C++ with ObjC extensions only. For C, makes it possible to
1309 differentiate between default (no option), -Wreturn-type, and
1310 -Wno-return-type.
1311
1312 2018-05-29 Jason Merrill <jason@redhat.com>
1313
1314 * c.opt (Winit-list-lifetime): New flag.
1315
1316 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
1317
1318 * c-lex.c (get_fileinfo): Use splay_tree_compare_strings and
1319 splay_tree_delete_pointers.
1320
1321 2018-05-26 Jakub Jelinek <jakub@redhat.com>
1322
1323 PR bootstrap/85921
1324 * c-warn.c (diagnose_mismatched_attributes): Remove unnecessary
1325 noinline variable to workaround broken kernel headers.
1326
1327 2018-05-18 Jason Merrill <jason@redhat.com>
1328
1329 * c.opt (Wdeprecated-copy): New flag.
1330
1331 2018-05-17 Martin Liska <mliska@suse.cz>
1332
1333 * c-warn.c (overflow_warning): Do not use
1334 space in between 'G_' and '('.
1335
1336 2018-05-09 Jason Merrill <jason@redhat.com>
1337
1338 * c-common.c (valid_array_size_p): Add complain parameter.
1339 * c-common.h: ...which defaults to true.
1340
1341 2018-05-11 Jakub Jelinek <jakub@redhat.com>
1342
1343 PR c/85696
1344 * c-omp.c (c_omp_predetermined_sharing): Return
1345 OMP_CLAUSE_DEFAULT_SHARED for artificial vars with integral type.
1346
1347 2018-05-11 Martin Liska <mliska@suse.cz>
1348
1349 PR sanitizer/85556
1350 * c-attribs.c (handle_no_sanitize_attribute): Iterate all
1351 TREE_LIST values.
1352
1353 2018-05-10 Jakub Jelinek <jakub@redhat.com>
1354
1355 PR c++/85662
1356 * c-common.h (fold_offsetof_1): Removed.
1357 (fold_offsetof): Add TYPE argument defaulted to size_type_node and
1358 CTX argument defaulted to ERROR_MARK.
1359 * c-common.c (fold_offsetof_1): Renamed to ...
1360 (fold_offsetof): ... this. Remove wrapper function. Add TYPE
1361 argument, convert the pointer constant to TYPE and use size_binop
1362 with PLUS_EXPR instead of fold_build_pointer_plus if type is not
1363 a pointer type. Adjust recursive calls.
1364
1365 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
1366
1367 PR c++/85400
1368 * c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
1369
1370 2018-05-07 Nathan Sidwell <nathan@acm.org>
1371
1372 * c.opt (ffor-scope): Remove functionality, issue warning.
1373
1374 2018-05-03 Nathan Sidwell <nathan@acm.org>
1375
1376 * c.opt (ffriend-injection): Remove functionality, issue warning.
1377
1378 2018-05-01 David Malcolm <dmalcolm@redhat.com>
1379
1380 PR c/84258
1381 * c-format.c (struct format_check_results): Add field
1382 "number_non_char".
1383 (check_format_info): Initialize it, and warn if encountered.
1384 (check_format_arg): Distinguish between wide char and
1385 everything else when detecting arrays of non-char.
1386
1387 2018-04-30 David Malcolm <dmalcolm@redhat.com>
1388
1389 * c-format.c (get_corrected_substring): Update for
1390 location_get_source_line returning a char_span. Use a char_span
1391 when handling the prefix of the correction.
1392 * c-indentation.c (get_visual_column): Update for
1393 location_get_source_line returning a char_span.
1394 (get_first_nws_vis_column): Likewise.
1395
1396 2018-03-29 David Malcolm <dmalcolm@redhat.com>
1397
1398 PR c++/84269
1399 * known-headers.cc (get_stdlib_header_for_name): Add various names
1400 from <assert.h>, <string.h>, and <memory.h>; add more names from
1401 <stdio.h>.
1402
1403 2018-03-27 Jakub Jelinek <jakub@redhat.com>
1404
1405 PR c++/85061
1406 * c-common.c (fold_offsetof_1) <case COMPOUND_EXPR>: Assert that
1407 get_base_address of the second operand is a VAR_P, rather than the
1408 operand itself, and use gcc_checking_assert instead of gcc_assert.
1409
1410 2018-03-23 Marek Polacek <polacek@redhat.com>
1411
1412 PR c++/85045
1413 * c-pretty-print.c (c_pretty_printer::multiplicative_expression)
1414 <case RDIV_EXPR>: Tweak condition.
1415
1416 2018-03-20 Eric Botcazou <ebotcazou@adacore.com>
1417
1418 * c-ada-spec.c (pp_ada_tree_identifier): Deal specifically with _Bool.
1419
1420 2018-03-16 Jakub Jelinek <jakub@redhat.com>
1421
1422 PR c/84909
1423 * c-warn.c (conversion_warning): Replace "to to" with "to" in
1424 diagnostics.
1425
1426 PR c/84910
1427 * c-warn.c (diagnose_mismatched_attributes): Remove trailing space from
1428 diagnostics.
1429
1430 2018-03-16 Richard Biener <rguenther@suse.de>
1431
1432 PR c/84873
1433 * c-gimplify.c (c_gimplify_expr): Revert previous change. Instead
1434 unshare the possibly folded expression.
1435
1436 2018-03-15 Richard Biener <rguenther@suse.de>
1437
1438 PR c/84873
1439 * c-gimplify.c (c_gimplify_expr): Do not fold expressions.
1440
1441 2018-03-13 Martin Sebor <msebor@redhat.com>
1442
1443 PR tree-optimization/84725
1444 * c-attribs.c (handle_nonstring_attribute): Allow attribute nonstring
1445 with all three narrow character types, including their qualified forms.
1446
1447 2018-03-12 Martin Sebor <msebor@redhat.com>
1448
1449 PR tree-optimization/83456
1450 * c-common.c (check_function_restrict): Return bool.
1451 Restore checking of bounded built-in functions.
1452 (check_function_arguments): Also return the result
1453 of warn_for_restrict.
1454 * c-common.c (check_function_restrict): Return bool.
1455 * c-warn.c (warn_for_restrict): Return bool.
1456
1457 2018-03-02 Marek Polacek <polacek@redhat.com>
1458
1459 PR c++/84171
1460 * c-warn.c (warn_for_sign_compare): Bail out if any of the operands
1461 is erroneous.
1462
1463 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
1464
1465 * c-attribs.c (c_common_attribute_table): Remove "cilk simd
1466 function".
1467
1468 2018-03-01 Marek Polacek <polacek@redhat.com>
1469
1470 PR c++/84639
1471 * c-attribs.c (common_handle_aligned_attribute): Don't use invalid
1472 alignment in computation.
1473
1474 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
1475
1476 * c-ada-spec.c (dump_ada_node) <NULLPTR_TYPE>: New case.
1477 <REAL_TYPE>: Deal specifically with _Float128/__float128.
1478
1479 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
1480
1481 * c-ada-spec.c (dump_ada_double_name) <ENUMERAL_TYPE>: New case.
1482 (is_char_array): Take a type instead of a declaration.
1483 (dump_ada_array_type): Likewise.
1484 (is_simple_enum): Minor tweak.
1485 (dump_ada_enum_type): New function extracted from...
1486 (dump_ada_node) <ENUMERAL_TYPE>: ...here. Invoke it.
1487 <INTEGER_TYPE>: Remove unreachable code.
1488 <RECORD_TYPE>: Likewise. Minor tweaks.
1489 (dump_nested_type) <ARRAY_TYPE>: Adjust to above changes.
1490 <ENUMERAL_TYPE>: New case.
1491 <RECORD_TYPE>: Factor out common code.
1492 (dump_ada_declaration) <ARRAY_TYPE>: Adjust to above changes.
1493 Minor tweaks. Deal with enumeral types.
1494 (dump_ada_structure): Minor tweaks.
1495
1496 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
1497
1498 * c-ada-spec.c (dump_ada_node) <POINTER_TYPE>: Do not use generic
1499 address for incomplete structures.
1500 (dump_forward_type): Do not bail out for incomplete structures.
1501 (dump_ada_declaration): Do not special-case incomplete structures
1502 for subtypes. Dump them as null records for types.
1503
1504 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
1505
1506 * c-ada-spec.c (dump_ada_import): Use boolean and fix formatting.
1507 (is_char_array): Fix formatting.
1508 (dump_template_types): Likewise.
1509 (dump_generic_ada_node): Rename into...
1510 (dump_ada_node): ...this.
1511 <POINTER_TYPE>: Remove superfluous space. Use generic address for
1512 incomplete structures and not for empty structures. Do not use it
1513 when forward declarations are needed.
1514 (dump_forward_type): New function.
1515 (dump_nested_types): Remove FORWARD parameter. Do not consider
1516 TREE_VISITED and do not generate a forward declaration. Only dump
1517 original nested types for nested declaration.
1518 (dump_nested_type) <POINTER_TYPE>: Call dump_forward_type.
1519 <ARRAY_TYPE>: Likewise if the component type is an anonymous pointer.
1520 <RECORD_TYPE>: Do not consider TREE_VISITED.
1521 (dump_ada_declaration): Use booleans and fix formatting throughout.
1522 <TYPE_DECL>: Skip incomplete structures and not empty structures.
1523 Call dump_forward_type instead of dump_nested_types for a typedef.
1524 Remove superfluous check and adjust call to dump_nested_types.
1525 <POINTER_TYPE>: Call dump_forward_type and fall through.
1526 (dump_ada_struct_decl): Rename into...
1527 (dump_ada_structure): ...this. Do not special-case empty structures.
1528
1529 2018-02-27 Martin Sebor <msebor@redhat.com>
1530
1531 PR c++/83871
1532 * c.opt (-Wmissing-attributes): New option.
1533
1534 2018-02-21 Martin Liska <mliska@suse.cz>
1535
1536 * c.opt (Wcatch-value=): Add IntegerRange.
1537
1538 2018-02-15 Jason Merrill <jason@redhat.com>
1539
1540 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_deduction_guides.
1541
1542 2018-02-09 Nathan Sidwell <nathan@acm.org>
1543
1544 PR c/84293
1545 * c-common.h (strict_aliasing_warning): Drop OTYPE arg, insert LOC
1546 arg.
1547 * c-warn.c (strict_aliasing_warning): Drop OTYPE arg, require LOC
1548 arg. Adjust.
1549
1550 2018-02-09 Martin Sebor <msebor@redhat.com>
1551
1552 PR lto/84212
1553 * c.opt (-Wstringop-overflow, -Warray-bounds): Add LTO.
1554 (-Walloc-size-larger-than, -Wformat-truncation=): Same.
1555 (-Wmaybe-uninitialized, -Wnonnull, -Wrestrict): Same.
1556 (-Wstrict-overflow, -Wsuggest-attribute): Same.
1557 (-Wuninitialized): Same.
1558
1559 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
1560
1561 * c-ada-spec.c (dump_ada_declaration): Do not generate the 'constant'
1562 keyword for components.
1563
1564 2018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
1565
1566 * c-common.h (DECL_UNNAMED_BIT_FIELD): New.
1567
1568 2018-02-02 Julia Koval <julia.koval@intel.com>
1569
1570 * c-common.h (omp_clause_mask): Move to wide_int_bitmask.h.
1571
1572 2018-01-29 Marek Polacek <polacek@redhat.com>
1573
1574 PR c/83966
1575 * c-format.c (check_function_format): Check current_function_decl.
1576
1577 2018-01-27 Jakub Jelinek <jakub@redhat.com>
1578
1579 * c-cppbuiltin.c (c_cpp_builtins): Use ggc_strdup for the fp_suffix
1580 argument.
1581 (LAZY_HEX_FP_VALUES_CNT): Define.
1582 (lazy_hex_fp_values): Allow up to LAZY_HEX_FP_VALUES_CNT lazy hex fp
1583 values rather than just 12.
1584 (builtin_define_with_hex_fp_value): Likewise.
1585
1586 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
1587
1588 PR other/70268
1589 * c.opt (-fmacro-prefix-map): New option.
1590 * c-opts.c (c_common_handle_option): Handle it.
1591 * c-lex.c (init_c_lex): Set remap_filename cpp callback.
1592 * c-ppoutput.c (init_pp_output): Likewise.
1593
1594 2018-01-17 David Malcolm <dmalcolm@redhat.com>
1595
1596 PR c++/83814
1597 * c-common.c (fold_for_warn): Move to c/c-fold.c and cp/expr.c.
1598
1599 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
1600
1601 * c-ada-spec.c (dump_number): Add FLOAT_P parameter.
1602 Skip 'f' and 'F' characters if it is true.
1603 (store_ada_macro): Minor tweak.
1604 (dump_ada_macros) <CPP_COMMENT>: Likewise.
1605 <CPP_WSTRING>: Likewise.
1606 <CPP_STRING>: Output '&' in the buffer if not the first string.
1607 <CPP_NUMBER>: Adjust calls to dump_number.
1608
1609 2018-01-10 David Malcolm <dmalcolm@redhat.com>
1610
1611 PR c++/43486
1612 * c-common.c: Include "selftest.h".
1613 (get_atomic_generic_size): Perform the test for integral type
1614 before the range test for any integer constant, fixing indentation
1615 of braces. Call fold_for_warn before testing for an INTEGER_CST.
1616 (reject_gcc_builtin): Strip any location wrapper from EXPR.
1617 (selftest::test_fold_for_warn): New function.
1618 (selftest::c_common_c_tests): New function.
1619 (selftest::c_family_tests): Call it, and
1620 selftest::c_pretty_print_c_tests.
1621 * c-common.h (selftest::c_pretty_print_c_tests): New decl.
1622 * c-format.c (check_format_arg): Convert VAR_P check to a
1623 fold_for_warn.
1624 * c-pretty-print.c: Include "selftest.h".
1625 (pp_c_cast_expression): Don't print casts for location wrappers.
1626 (selftest::assert_c_pretty_printer_output): New function.
1627 (ASSERT_C_PRETTY_PRINTER_OUTPUT): New macro.
1628 (selftest::test_location_wrappers): New function.
1629 (selftest::c_pretty_print_c_tests): New function.
1630 * c-warn.c (warn_for_memset): Call fold_for_warn on the arguments.
1631
1632 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
1633 Alan Hayward <alan.hayward@arm.com>
1634 David Sherwood <david.sherwood@arm.com>
1635
1636 * c-common.c (c_common_type_for_mode): Handle MODE_VECTOR_BOOL.
1637
1638 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
1639 Alan Hayward <alan.hayward@arm.com>
1640 David Sherwood <david.sherwood@arm.com>
1641
1642 * c-ubsan.c (ubsan_instrument_shift): Treat GET_MODE_BITSIZE
1643 as polynomial.
1644
1645 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
1646 Alan Hayward <alan.hayward@arm.com>
1647 David Sherwood <david.sherwood@arm.com>
1648
1649 * c-common.c (vector_types_convertible_p, c_build_vec_perm_expr)
1650 (convert_vector_to_array_for_subscript): Handle polynomial
1651 TYPE_VECTOR_SUBPARTS.
1652 (c_common_type_for_mode): Check valid_vector_subparts_p.
1653 * c-pretty-print.c (pp_c_initializer_list): Handle polynomial
1654 VECTOR_CST_NELTS.
1655
1656 2018-01-03 Jakub Jelinek <jakub@redhat.com>
1657
1658 Update copyright years.
1659
1660 2017-12-22 Mike Stump <mikestump@comcast.net>
1661 Eric Botcazou <ebotcazou@adacore.com>
1662
1663 * c-pragma.c (init_pragma): Register pragma GCC unroll.
1664 * c-pragma.h (enum pragma_kind): Add PRAGMA_UNROLL.
1665
1666 2017-12-22 Alexandre Oliva <aoliva@redhat.com>
1667
1668 PR debug/83527
1669 PR debug/83419
1670 * c-semantics.c (only_debug_stmts_after_p): New.
1671 (pop_stmt_list): Clear side effects in debug-only stmt list.
1672 Check for single nondebug stmt followed by debug stmts only.
1673
1674 2017-12-21 Alexandre Oliva <aoliva@redhat.com>
1675
1676 PR debug/83419
1677 * c-semantics.c (pop_stmt_list): Propagate side effects from
1678 single nondebug stmt to container list.
1679
1680 2017-12-19 Jakub Jelinek <jakub@redhat.com>
1681
1682 * known-headers.cc (get_stdlib_header_for_name): Replace Yoda
1683 conditions with typical order conditions.
1684
1685 2017-12-18 Marek Polacek <polacek@redhat.com>
1686
1687 * c-warn.c (warn_logical_operator): Return early if -Wlogical-op is
1688 not in effect.
1689
1690 2017-12-17 Martin Sebor <msebor@redhat.com>
1691
1692 * c-attribs.c (common_handle_aligned_attribute): Avoid issuing
1693 an error for attribute warn_if_not_aligned.
1694
1695 2017-12-16 Martin Sebor <msebor@redhat.com>
1696
1697 PR tree-optimization/78918
1698 * c-common.c (check_function_restrict): Avoid checking built-ins.
1699 * c.opt (-Wrestrict): Include in -Wall.
1700
1701 2017-12-15 Jakub Jelinek <jakub@redhat.com>
1702
1703 * c-attribs.c (c_common_attribute_table,
1704 c_common_format_attribute_table): Swap affects_type_identity
1705 and handler fields, adjust comments.
1706
1707 2017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
1708
1709 * c.opt (Wcast-function-type): New warning option.
1710 * c-lex.c (get_fileinfo): Avoid warning.
1711 * c-ppoutput.c (scan_translation_unit_directives_only): Remove cast.
1712
1713 2017-12-14 Qing Zhao <qing.zhao@oracle.com>
1714
1715 PR middle_end/79538
1716 * c-cppbuiltin.c (builtin_define_with_hex_fp_value):
1717 Adjust the size of buf1 and buf2, add a new buf to avoid
1718 format-overflow warning.
1719
1720 2017-12-12 Alexandre Oliva <aoliva@redhat.com>
1721
1722 * c-semantics.c (pop_stmt_list): Move begin stmt marker into
1723 subsequent statement list.
1724
1725 2017-12-07 Martin Sebor <msebor@redhat.com>
1726
1727 PR c/81544
1728 PR c/81566
1729 * c-attribs.c (attr_aligned_exclusions): New array.
1730 (attr_alloc_exclusions, attr_cold_hot_exclusions): Same.
1731 (attr_common_exclusions, attr_const_pure_exclusions): Same.
1732 (attr_gnu_inline_exclusions, attr_inline_exclusions): Same.
1733 (attr_noreturn_exclusions, attr_returns_twice_exclusions): Same.
1734 (attr_warn_unused_result_exclusions): Same.
1735 (handle_hot_attribute, handle_cold_attribute): Simplify.
1736 (handle_const_attribute): Warn on function returning void.
1737 (handle_pure_attribute): Same.
1738 (handle_aligned_attribute): Diagnose conflicting attribute
1739 specifications.
1740 * c-warn.c (diagnose_mismatched_attributes): Simplify.
1741
1742 2017-12-06 David Malcolm <dmalcolm@redhat.com>
1743
1744 PR c/83236
1745 * c-common.c (selftest::c_family_tests): Call
1746 selftest::c_spellcheck_cc_tests.
1747 * c-common.h (selftest::c_spellcheck_cc_tests): New decl.
1748 * c-spellcheck.cc: Include "selftest.h".
1749 (name_reserved_for_implementation_p): New function.
1750 (should_suggest_as_macro_p): New function.
1751 (find_closest_macro_cpp_cb): Move the check for NT_MACRO to
1752 should_suggest_as_macro_p and call it.
1753 (selftest::test_name_reserved_for_implementation_p): New function.
1754 (selftest::c_spellcheck_cc_tests): New function.
1755 * c-spellcheck.h (name_reserved_for_implementation_p): New decl.
1756
1757 2017-12-06 David Malcolm <dmalcolm@redhat.com>
1758
1759 * c-spellcheck.cc: New file, taken from macro-handling code in
1760 spellcheck-tree.c.
1761 * c-spellcheck.h: New file, taken from macro-handling code in
1762 spellcheck-tree.h.
1763
1764 2017-12-01 Jakub Jelinek <jakub@redhat.com>
1765
1766 * c-attribs.c (c_common_attribute_table): Remove "cilk simd function"
1767 attribute.
1768 (handle_simd_attribute): Don't check for "cilk simd function"
1769 attribute. Reindent, formatting changes.
1770
1771 2017-11-30 Julia Koval <julia.koval@intel.com>
1772
1773 * c-common.h (inv_list): Remove.
1774
1775 2017-11-28 Jakub Jelinek <jakub@redhat.com>
1776
1777 PR sanitizer/81275
1778 * c-common.c (c_switch_covers_all_cases_p_1,
1779 c_switch_covers_all_cases_p): New functions.
1780 * c-common.h (c_switch_covers_all_cases_p): Declare.
1781
1782 2017-11-28 Julia Koval <julia.koval@intel.com>
1783 Sebastian Peryt <sebastian.peryt@intel.com>
1784
1785 * array-notation-common.c: Delete.
1786 * c-cilkplus.c: Ditto.
1787 * c-common.c (_Cilk_spawn, _Cilk_sync, _Cilk_for): Remove.
1788 * c-common.def (ARRAY_NOTATION_REF): Remove.
1789 * c-common.h (RID_CILK_SPAWN, build_array_notation_expr,
1790 build_array_notation_ref, C_ORT_CILK, c_check_cilk_loop,
1791 c_validate_cilk_plus_loop, cilkplus_an_parts,
1792 cilk_ignorable_spawn_rhs_op,
1793 cilk_recognize_spawn): Remove.
1794 * c-gimplify.c (CILK_SPAWN_STMT): Remove.
1795 * c-omp.c: Remove CILK_SIMD check.
1796 * c-pragma.c: Ditto.
1797 * c-pragma.h: Remove CILK related pragmas.
1798 * c-pretty-print.c (c_pretty_printer::postfix_expression): Remove
1799 ARRAY_NOTATION_REF condition.
1800 (c_pretty_printer::expression): Ditto.
1801 * c.opt (fcilkplus): Remove.
1802 * cilk.c: Delete.
1803
1804 2017-11-21 Marc Glisse <marc.glisse@inria.fr>
1805
1806 * c-pretty-print.c (pp_c_additive_expression,
1807 c_pretty_printer::expression): Handle POINTER_DIFF_EXPR.
1808
1809 2017-11-21 Jakub Jelinek <jakub@redhat.com>
1810
1811 * c-common.c (get_nonnull_operand): Use tree_to_uhwi.
1812
1813 PR c++/83059
1814 * c-common.c (get_atomic_generic_size): Use TREE_INT_CST_LOW
1815 instead of tree_to_uhwi, formatting fix.
1816
1817 2017-11-20 David Malcolm <dmalcolm@redhat.com>
1818
1819 PR c/81404
1820 * known-headers.cc: New file, based on material from c/c-decl.c.
1821 (suggest_missing_header): Copied as-is.
1822 (get_stdlib_header_for_name): New, based on get_c_name_hint but
1823 heavily edited to add C++ support. Add some knowledge about
1824 <limits.h>, <stdint.h>, and <wchar.h>.
1825 * known-headers.h: Likewise.
1826
1827 2017-11-20 David Malcolm <dmalcolm@redhat.com>
1828
1829 * c-common.h (enum lookup_name_fuzzy_kind): Move to name-hint.h.
1830 (lookup_name_fuzzy): Likewise. Convert return type from
1831 const char * to name_hint. Add location_t param.
1832 * name-hint.h: New header.
1833
1834 2017-11-19 Jakub Jelinek <jakub@redhat.com>
1835
1836 PR c/66618
1837 PR c/69960
1838 * c-common.h (c_fully_fold): Add LVAL argument defaulted to false.
1839
1840 2017-11-16 Joseph Myers <joseph@codesourcery.com>
1841
1842 * c.opt (-std=c17, std=gnu17, -std=iso9899:2017): Refer to 2018
1843 expected publication date of C17.
1844 (-std=c18, -std=gnu18, -std=iso9899:2018): New option aliases.
1845
1846 2017-11-15 Joseph Myers <joseph@codesourcery.com>
1847
1848 PR c/81156
1849 * c-common.c (c_common_reswords): Add __builtin_tgmath.
1850 * c-common.h (enum rid): Add RID_BUILTIN_TGMATH.
1851
1852 2017-11-10 Martin Sebor <msebor@redhat.com>
1853
1854 PR c/81117
1855 * c-common.c (catenate_strings): Use memcpy instead of strncpy.
1856 * c-warn.c (sizeof_pointer_memaccess_warning): Handle arrays.
1857 * c.opt (-Wstringop-truncation): New option.
1858
1859 2017-11-06 Martin Liska <mliska@suse.cz>
1860
1861 PR middle-end/82404
1862 * c-opts.c (c_common_post_options): Set -Wreturn-type for C++
1863 FE.
1864 * c.opt: Set default value of warn_return_type.
1865
1866 2017-10-31 David Malcolm <dmalcolm@redhat.com>
1867
1868 * c-common.c (binary_op_error): Update for renaming of
1869 error_at_rich_loc.
1870 (c_parse_error): Likewise.
1871 * c-warn.c (warn_logical_not_parentheses): Likewise for
1872 renaming of inform_at_rich_loc.
1873 (warn_for_restrict): Likewise for renaming of
1874 warning_at_rich_loc_n.
1875
1876 2017-10-30 Joseph Myers <joseph@codesourcery.com>
1877
1878 * c.opt (std=c17, std=gnu17, std=iso9899:2017): New options.
1879 * c-opts.c (set_std_c17): New function.
1880 (c_common_init_options): Use gnu17 as default C version.
1881 (c_common_handle_option): Handle -std=c17 and -std=gnu17.
1882
1883 2017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
1884
1885 * c-cppbuiltin.c (mode_has_fma): Add support for PowerPC KFmode.
1886 (c_cpp_builtins): If a machine has a fast fma _Float<N> and
1887 _Float<N>X variant, define __FP_FAST_FMA<N> and/or
1888 __FP_FAST_FMA<N>X.
1889
1890 2017-10-23 Marek Polacek <polacek@redhat.com>
1891
1892 PR c/82681
1893 * c-warn.c (warnings_for_convert_and_check): Fix typos.
1894
1895 2017-10-19 Eric Botcazou <ebotcazou@adacore.com>
1896
1897 * c-common.c (check_builtin_function_arguments): Also check arguments
1898 of __builtin_alloca_with_align_and_max.
1899
1900 2017-10-17 David Malcolm <dmalcolm@redhat.com>
1901
1902 * c-format.c (format_warning_at_char): Pass UNKNOWN_LOCATION
1903 rather than NULL to format_warning_va.
1904 (check_format_types): Likewise when calling format_type_warning.
1905 Remove code to extract source_ranges and source_range * in favor
1906 of just a location_t.
1907 (format_type_warning): Convert source_range * param to a
1908 location_t.
1909
1910 2017-10-13 Jakub Jelinek <jakub@redhat.com>
1911
1912 * c-gimplify.c (c_gimplify_expr): Handle [LR]ROTATE_EXPR like
1913 [LR]SHIFT_EXPR.
1914
1915 2017-10-12 David Malcolm <dmalcolm@redhat.com>
1916
1917 * c-common.c (enum missing_token_insertion_kind): New enum.
1918 (get_missing_token_insertion_kind): New function.
1919 (maybe_suggest_missing_token_insertion): New function.
1920 * c-common.h (maybe_suggest_missing_token_insertion): New decl.
1921
1922 2017-10-11 Nathan Sidwell <nathan@acm.org>
1923
1924 * c-opts.c (add_prefixed_path): Change chain to incpath_kind.
1925 (c_common_handle_option): Update incpath_kind names.
1926
1927 2017-10-11 Martin Liska <mliska@suse.cz>
1928
1929 PR sanitizer/82490
1930 * c-attribs.c (handle_no_sanitize_attribute): Report directly
1931 Wattributes warning.
1932
1933 2017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
1934
1935 * c-ada-spec.c (dump_generic_ada_node): Use wi::to_wide when
1936 operating on trees as wide_ints.
1937 * c-common.c (pointer_int_sum): Likewise.
1938 * c-pretty-print.c (pp_c_integer_constant): Likewise.
1939 * c-warn.c (match_case_to_enum_1): Likewise.
1940 (c_do_switch_warnings): Likewise.
1941 (maybe_warn_shift_overflow): Likewise.
1942
1943 2017-10-10 Jakub Jelinek <jakub@redhat.com>
1944
1945 PR c/82437
1946 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_wide
1947 instead of wide_int::from.
1948
1949 2017-10-06 Jakub Jelinek <jakub@redhat.com>
1950
1951 PR c/82437
1952 * c-warn.c (warn_tautological_bitwise_comparison): Instead of
1953 using to_widest use wide_int with the larger of the two precisions.
1954
1955 2017-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
1956
1957 * c-pretty-print.c (pp_c_parameter_type_list): Print ... for variadic
1958 functions.
1959
1960 2017-10-02 Richard Sandiford <richard.sandiford@linaro.org>
1961
1962 * c-warn.c (warn_tautological_bitwise_comparison): Use wi::to_widest
1963 when combining the original unconverted comparison operands.
1964
1965 2017-09-29 Jakub Jelinek <jakub@redhat.com>
1966
1967 * c-attribs.c (handle_noipa_attribute): Don't add "stack_protect"
1968 attribute.
1969
1970 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
1971
1972 * c-ada-spec.c (to_ada_name): Add index parameter.
1973 (pp_ada_tree_identifier): Likewise.
1974 (dump_ada_macros): Adjust call to to_ada_name.
1975 (struct overloaded_name_hash): New type.
1976 (struct overloaded_name_hasher): Likewise.
1977 (overloaded_names): New hash table.
1978 (compute_overloading_index): New function.
1979 (dump_ada_decl_name): Call it and pass the result to
1980 pp_ada_tree_identifier.
1981 (dump_ada_double_name): Adjust calls to pp_ada_tree_identifier.
1982 (dump_ada_function_declaration): Likewise.
1983 (dump_generic_ada_node): Likewise.
1984 (print_constructor): Likewise.
1985 (print_destructor): Likewise.
1986 (dump_ada_specs): Delete overloaded_names table.
1987
1988 2017-09-29 Eric Botcazou <ebotcazou@adacore.com>
1989
1990 * c-ada-spec.c (max_ada_macros): Move around.
1991 (store_ada_macro_index): Likewise.
1992 (source_file): Rename into...
1993 (macro_source_file): ...this.
1994 (count_ada_macro): Move around.
1995 (store_ada_macro): Likewise.
1996 (compare_macro): Likewise.
1997 (print_ada_macros): Merge in...
1998 (dump_ada_macros): ...this.
1999 (source_file_base): Rename into...
2000 (current_source_file): ...this.
2001 (print_comment): Move around.
2002 (dump_ada_nodes): Call dump_ada_declaration directly.
2003 (struct with): Change type of limited field to bool.
2004 (append_withs): Change type of limited_access parameter to bool.
2005 (pp_ada_tree_identifie): Likewise.
2006 (dump_ada_decl_nam): Likewise.
2007 (dump_generic_ada_node): Likewise. Do not print the return type.
2008 (to_ada_name): Change type of space_found parameter to bool.
2009 (dump_ada_function_declaration): Return void and change type of
2010 parameters to bool. Also print the return type for a function.
2011 (print_ada_methods): Rename into...
2012 (dump_ada_methods): ...this.
2013 (print_ada_declaration): Rename into ...
2014 (dump_ada_declaration): ...this. Do not print the return type.
2015 (print_ada_struct_decl): Rename into...
2016 (dump_ada_struct_decl): ...this.
2017
2018 2017-09-29 Jakub Jelinek <jakub@redhat.com>
2019
2020 * c-attribs.c (handle_packed_attribute): Test DECL_C_BIT_FIELD
2021 rather than DECL_INITIAL.
2022 (common_handle_aligned_attribute): Likewise.
2023
2024 2017-09-20 Alexandre Oliva <aoliva@redhat.com>
2025
2026 * c.opt (gen-decls): Add RejectNegative.
2027
2028 2017-09-15 Andrew Sutton <andrew.n.sutton@gmail.com>
2029 Jakub Jelinek <jakub@redhat.com>
2030
2031 Add support for -std=c++2a.
2032 * c-common.h (cxx_dialect): Add cxx2a as a dialect.
2033 * opt.c: Add options for -std=c++2a and -std=gnu++2a.
2034 * c-opts.c (set_std_cxx2a): New.
2035 (c_common_handle_option): Set options when -std=c++2a is enabled.
2036 (c_common_post_options): Adjust comments.
2037 (set_std_cxx14, set_std_cxx17): Likewise.
2038
2039 2017-09-15 Eric Botcazou <ebotcazou@adacore.com>
2040
2041 * c-pragma.c (handle_pragma_scalar_storage_order): Expand on error
2042 message for non-uniform endianness and issue a warning in C++.
2043
2044 2017-09-15 Jakub Jelinek <jakub@redhat.com>
2045
2046 * c.opt (Wc++1z-compat): Change from option to undocumented alias.
2047 (Wc++17-compat): Change from undocumented alias to option.
2048 (Wnoexcept-type): Enable by Wc++17-compat instead of Wc++1z-compat,
2049 change C++1z to C++17 in description.
2050 (std=c++1z, std=gnu++1z): Change from option to undocumented
2051 deprecated alias.
2052 (std=c++17, std=gnu++17): Change from undocumented alias to option.
2053 Adjust description.
2054 * c-common.h (enum cxx_dialect): Rename cxx1z to cxx17.
2055 * c-opts.c (set_std_cxx1z): Rename to ...
2056 (set_std_cxx17): ... this.
2057 (c_common_handle_option): Rename OPT_std_c__1z to OPT_std_c__17
2058 and OPT_std_gnu__1z to OPT_std_gnu__17. Adjust set_std_cxx1z
2059 caller.
2060 (c_common_post_options): Use cxx17 instead of cxx1z. Adjust
2061 comments.
2062
2063 2017-09-12 H.J. Lu <hongjiu.lu@intel.com>
2064
2065 * c-attribs.c (common_handle_aligned_attribute): Don't warn
2066 function alignment if warn_if_not_aligned_p is true.
2067
2068 2017-09-12 Nathan Sidwell <nathan@acm.org>
2069
2070 * c-common.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
2071 resort_sorted_fields): Move to c/c-decl.c.
2072 * c-common.h (field_decl_cmp, resort_sorted_fields): Delete.
2073 (struct sorted_fields_type): Move to c/c-lang.h.
2074
2075 2017-09-09 Jonathan Wakely <jwakely@redhat.com>
2076
2077 PR c++/81852
2078 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_threadsafe_static_init.
2079
2080 2017-09-04 Marek Polacek <polacek@redhat.com>
2081
2082 PR c/81783
2083 * c-warn.c (warn_tautological_bitwise_comparison): New function.
2084 (warn_tautological_cmp): Call it.
2085
2086 2017-09-01 Boris Kolpackov <boris@codesynthesis.com>
2087
2088 * c-opts.c (c_common_finish): Write dependency information even if
2089 there are errors.
2090
2091 2017-09-01 Jakub Jelinek <jakub@redhat.com>
2092
2093 PR c/81887
2094 * c-pragma.c (omp_pragmas): Move "ordered" entry from here to ...
2095 (omp_pragmas_simd): ... here.
2096 * c-omp.c (c_finish_omp_ordered): If clauses isn't simd clause alone,
2097 create new clauses list containing just simd clause.
2098
2099 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
2100 Alan Hayward <alan.hayward@arm.com>
2101 David Sherwood <david.sherwood@arm.com>
2102
2103 * c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
2104 into scalar_mode_supported_p call.
2105 (handle_mode_attribute): Update call to scalar_mode_supported_p.
2106
2107 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
2108 Alan Hayward <alan.hayward@arm.com>
2109 David Sherwood <david.sherwood@arm.com>
2110
2111 * c-common.c (c_common_fixed_point_type_for_size): Use opt_scalar_mode
2112 for the mode iterator.
2113
2114 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
2115 Alan Hayward <alan.hayward@arm.com>
2116 David Sherwood <david.sherwood@arm.com>
2117
2118 * c-lex.c (interpret_fixed): Use SCALAR_TYPE_MODE.
2119 * c-common.c (c_build_vec_perm_expr): Likewise.
2120
2121 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
2122 Alan Hayward <alan.hayward@arm.com>
2123 David Sherwood <david.sherwood@arm.com>
2124
2125 * c-common.c (c_common_type_for_mode): Use as_a <scalar_int_mode>.
2126
2127 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
2128 Alan Hayward <alan.hayward@arm.com>
2129 David Sherwood <david.sherwood@arm.com>
2130
2131 * c-attribs.c (handle_mode_attribute): Check for a scalar_int_mode
2132 before calling targetm.addr_space.valid_pointer_mode.
2133
2134 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
2135 Alan Hayward <alan.hayward@arm.com>
2136 David Sherwood <david.sherwood@arm.com>
2137
2138 * c-cppbuiltin.c (c_cpp_builtins): Use opt_scalar_float_mode.
2139
2140 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
2141 Alan Hayward <alan.hayward@arm.com>
2142 David Sherwood <david.sherwood@arm.com>
2143
2144 * c-common.c (c_common_fixed_point_type_for_size): Use new mode
2145 iterators.
2146 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
2147
2148 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
2149 Alan Hayward <alan.hayward@arm.com>
2150 David Sherwood <david.sherwood@arm.com>
2151
2152 * c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
2153 case statements.
2154
2155 2017-08-29 Martin Liska <mliska@suse.cz>
2156
2157 PR other/39851
2158 * c-common.c (parse_optimize_options): Add argument to function
2159 call.
2160 * c-pragma.c (handle_pragma_diagnostic): Likewise.
2161
2162 2017-08-24 David Malcolm <dmalcolm@redhat.com>
2163
2164 * c-lex.c (interpret_float): Use token location
2165 when building an EXCESS_PRECISION_EXPR.
2166
2167 2017-08-21 David Malcolm <dmalcolm@redhat.com>
2168
2169 * c-common.c (check_function_arguments): Add "arglogs" param; pass
2170 it to check_function_format.
2171 * c-common.h (check_function_arguments): Add vec<location_t> *
2172 param.
2173 (check_function_format): Likewise.
2174 * c-format.c (struct format_check_context): Add field "arglocs".
2175 (check_function_format): Add param "arglocs"; pass it to
2176 check_format_info.
2177 (check_format_info): Add param "arglocs"; use it to initialize
2178 new field of format_ctx.
2179 (check_format_arg): Pass format_ctx->arglocs to new param of
2180 check_format_info_main.
2181 (class argument_parser): New field "arglocs".
2182 (argument_parser::argument_parser): Add "arglocs_" param and use
2183 it to initialize new field.
2184 (argument_parser::check_argument_type): Pass new arglocs field to
2185 check_format_types.
2186 (check_format_info_main): Add param "arglocs", and use it when
2187 constructing arg_parser.
2188 (check_format_types): Add param "arglocs"; use it if non-NULL when
2189 !EXPR_HAS_LOCATION (cur_param) to get at location information.
2190
2191 2017-08-18 H.J. Lu <hongjiu.lu@intel.com>
2192
2193 PR c/53037
2194 * c-attribs.c (handle_warn_if_not_aligned_attribute): New.
2195 (c_common_attribute_table): Add warn_if_not_aligned.
2196 (handle_aligned_attribute): Renamed to ...
2197 (common_handle_aligned_attribute): Remove argument, name, and add
2198 argument, warn_if_not_aligned. Handle warn_if_not_aligned.
2199 (handle_aligned_attribute): New.
2200 * c.opt: Add -Wif-not-aligned and -Wpacked-not-aligned.
2201
2202 2017-08-14 Martin Sebor <msebor@redhat.com>
2203
2204 PR c/81117
2205 * c-attribs.c (c_common_attribute_table): Add nonstring entry.
2206 (handle_nonstring_attribute): New function.
2207
2208 2017-08-14 Martin Sebor <msebor@redhat.com>
2209
2210 PR c/81117
2211 * c-format.h (T89_G): New macro.
2212 * c-format.c (local_gcall_ptr_node): New variable.
2213 (init_dynamic_diag_info): Initialize it.
2214
2215 2017-08-11 Martin Liska <mliska@suse.cz>
2216
2217 * c-opts.c (c_common_post_options): Replace ASM_OUTPUT_DEF with
2218 TARGET_SUPPORTS_ALIASES.
2219
2220 2017-08-10 David Malcolm <dmalcolm@redhat.com>
2221
2222 * c-common.c (c_parse_error): Add rich_location * param, using it
2223 rather implicitly using input_location.
2224 * c-common.h (c_parse_error): Add rich_location * param.
2225
2226 2017-08-09 Marek Polacek <polacek@redhat.com>
2227
2228 * c-common.c (pointer_int_sum): Use true/false instead of 1/0.
2229 (c_common_truthvalue_conversion): Likewise.
2230 * c-omp.c (c_finish_omp_atomic): Likewise.
2231 * c-common.h (build_binary_op): Update declaration.
2232
2233 2017-08-08 Martin Liska <mliska@suse.cz>
2234
2235 * c-ada-spec.c: Include header files.
2236 * c-ubsan.c: Likewise.
2237 * c-warn.c: Likewise.
2238
2239 2017-08-07 Jakub Jelinek <jakub@redhat.com>
2240
2241 PR c/69389
2242 * c-omp.c (c_finish_omp_atomic): Handle atomics on bitfields.
2243
2244 2017-08-07 Eric Botcazou <ebotcazou@adacore.com>
2245
2246 * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL.
2247 (print_ada_methods): Likewise.
2248 (print_ada_declaration): Likewise.
2249
2250 2017-08-07 Martin Liska <mliska@suse.cz>
2251
2252 * array-notation-common.c: Add new includes.
2253 * c-format.c( handle_format_attribute): Canonicalize a format
2254 function name.
2255 * c-lex.c (c_common_has_attribute): Canonicalize name of an
2256 attribute.
2257 * c-pretty-print.c: Add new include.
2258
2259 2017-08-05 Eric Botcazou <ebotcazou@adacore.com>
2260
2261 * c-ada-spec.c (has_static_fields): Look only into variables.
2262 (print_constructor): Add TYPE parameter and use it for the name.
2263 (print_destructor): Likewise.
2264 (print_ada_declaration): Adjust to new constructor/destructor names.
2265 Adjust calls to print_constructor and print_destructor.
2266 (print_ada_struct_decl): Do not test TREE_STATIC on FIELD_DECL.
2267 Look only into variables in the final loop.
2268
2269 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
2270
2271 * c-ada-spec.c (has_static_fields): Look only into fields.
2272 (dump_generic_ada_node): Small tweak.
2273 (dump_nested_types): Look only into fields.
2274 (print_ada_declaration): Look only into methods. Small tweak.
2275 (print_ada_struct_decl): Look only into fields. Use DECL_VIRTUAL_P.
2276
2277 2017-08-01 Eric Botcazou <ebotcazou@adacore.com>
2278
2279 * c-ada-spec.c (print_generic_ada_decl): Pass correctly-typed constant.
2280 (dump_ada_function_declaration): Likewise.
2281 (dump_generic_ada_node): Likewise.
2282 (print_ada_declaration): Add support for const-qualified variables.
2283
2284 2017-07-31 Martin Liska <mliska@suse.cz>
2285
2286 PR sanitize/81530
2287 * c-ubsan.c (ubsan_maybe_instrument_array_ref):
2288 Guard condition with flag_sanitize_p also with current_function_decl
2289 non-null equality.
2290 (ubsan_maybe_instrument_reference_or_call): Likewise.
2291
2292 2017-07-30 Uros Bizjak <ubizjak@gmail.com>
2293
2294 * c-format.c (asm_fprintf_char_table): Add 'z' to format_chars.
2295
2296 2017-07-29 Eric Botcazou <ebotcazou@adacore.com>
2297
2298 * c-ada-spec.c (dump_generic_ada_node): Take into account signedness
2299 for enumeral types.
2300 (print_ada_declaration): Add missing guard for record types.
2301
2302 2017-07-27 Jakub Jelinek <jakub@redhat.com>
2303
2304 PR c/45784
2305 * c-omp.c (c_finish_omp_for): If the condition is wrapped in
2306 rhs of COMPOUND_EXPR(s), skip them and readd their lhs into
2307 new COMPOUND_EXPRs around the rhs of the comparison.
2308
2309 2017-07-27 Marek Polacek <polacek@redhat.com>
2310
2311 PR c/81417
2312 * c-warn.c (warn_for_sign_compare): Tweak the warning message. Print
2313 the types.
2314
2315 2017-07-27 Jakub Jelinek <jakub@redhat.com>
2316
2317 * c-attribs.c (c_common_attribute_table): Add noipa attribute.
2318 (handle_noipa_attribute): New function.
2319
2320 2017-07-07 Torsten Duwe <duwe@suse.de>
2321
2322 * c-attribs.c (c_common_attribute_table): Add entry for
2323 "patchable_function_entry".
2324
2325 2017-07-20 Nathan Sidwell <nathan@acm.org>
2326
2327 Remove TYPE_METHODS.
2328 * c-ada-spec.c (is_tagged_type, has_nontrivial_methods,
2329 dump_ada_template, print_ada_methods,
2330 print_ada_declaration): Member fns are on TYPE_FIELDS.
2331
2332 2017-07-18 Nathan Sidwell <nathan@acm.org>
2333
2334 * c-warn.c (warn_for_memset): Use TYPE_{MIN,MAX}_VALUE.
2335
2336 2017-07-14 David Malcolm <dmalcolm@redhat.com>
2337
2338 * c-common.c (try_to_locate_new_include_insertion_point): New
2339 function.
2340 (per_file_includes_t): New typedef.
2341 (added_includes_t): New typedef.
2342 (added_includes): New variable.
2343 (maybe_add_include_fixit): New function.
2344 * c-common.h (maybe_add_include_fixit): New decl.
2345
2346 2017-07-10 Martin Sebor <msebor@redhat.com>
2347
2348 PR other/81345
2349 * c.opt (-Wstringop-overflow): Set defaults in LangEnabledBy.
2350
2351 2017-07-06 David Malcolm <dmalcolm@redhat.com>
2352
2353 * c-common.c (selftest::c_family_tests): New.
2354 * c-common.h (selftest::run_c_tests): Move decl to c/c-lang.h.
2355 (selftest::c_family_tests): New decl.
2356
2357 2017-07-04 Marek Polacek <polacek@redhat.com>
2358
2359 PR c/81231
2360 * c-common.c (sync_resolve_size): Give error for pointers to incomplete
2361 types.
2362
2363 2017-07-04 Marek Polacek <polacek@redhat.com>
2364
2365 * c-warn.c (warn_if_unused_value): Remove WITH_CLEANUP_EXPR handling.
2366
2367 2017-06-28 Martin Liska <mliska@suse.cz>
2368
2369 PR ipa/81128
2370 * c-attribs.c (handle_alias_ifunc_attribute): Append ifunc alias
2371 to a function declaration.
2372
2373 2017-06-28 Martin Liska <mliska@suse.cz>
2374
2375 PR driver/79659
2376 * c.opt: Add IntegerRange to various options.
2377
2378 2017-06-26 Marek Polacek <polacek@redhat.com>
2379
2380 PR c/80116
2381 * c-common.h (warn_for_multistatement_macros): Declare.
2382 * c-warn.c: Include "c-family/c-indentation.h".
2383 (warn_for_multistatement_macros): New function.
2384 * c.opt (Wmultistatement-macros): New option.
2385 * c-indentation.c (guard_tinfo_to_string): No longer static.
2386 Change the parameter type to "enum rid". Handle RID_SWITCH.
2387 * c-indentation.h (guard_tinfo_to_string): Declare.
2388
2389 2017-06-23 Marc Glisse <marc.glisse@inria.fr>
2390
2391 * c-common.c (c_common_nodes_and_builtins): Use builtin_structptr_types.
2392
2393 2017-06-15 Martin Sebor <msebor@redhat.com>
2394
2395 PR c++/80560
2396 * c.opt (-Wclass-memaccess): New option.
2397
2398 2017-06-14 Boris Kolpackov <boris@codesynthesis.com>
2399
2400 * c-opts.c (c_common_finish): Handle '-' special value to -MF.
2401
2402 2017-06-13 Marek Polacek <polacek@redhat.com>
2403
2404 PR objc/80949
2405 * c-warn.c (do_warn_duplicated_branches): Return if any of the
2406 branches is null.
2407
2408 2017-06-13 Martin Liska <mliska@suse.cz>
2409
2410 PR sanitize/78204
2411 * c-attribs.c (add_no_sanitize_value): New function.
2412 (handle_no_sanitize_attribute): Likewise.
2413 (handle_no_sanitize_address_attribute): Use the function.
2414 (handle_no_sanitize_thread_attribute): New function.
2415 (handle_no_address_safety_analysis_attribute): Use
2416 add_no_sanitize_value.
2417 (handle_no_sanitize_undefined_attribute): Likewise.
2418 * c-common.h: Declare new functions.
2419 * c-ubsan.c (ubsan_instrument_division): Use sanitize_flags_p.
2420 (ubsan_instrument_shift): Likewise.
2421 (ubsan_instrument_bounds): Likewise.
2422 (ubsan_maybe_instrument_array_ref): Likewise.
2423 (ubsan_maybe_instrument_reference_or_call): Likewise.
2424
2425 2017-06-11 Jason Merrill <jason@redhat.com>
2426
2427 * c-ada-spec.c, c-pragma.c: Use id_equal.
2428
2429 2017-06-04 Marek Polacek <polacek@redhat.com>
2430
2431 PR c/80919
2432 * c-format.c (matching_type_p): Return false if any of the types
2433 requires structural equality.
2434
2435 2017-06-02 Martin Sebor <msebor@redhat.com>
2436
2437 PR c/80892
2438 * c-warn.c (conversion_warning): Use -Wconversion for integer
2439 conversion and -Wfloat-conversion for floating one.
2440
2441 2017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
2442
2443 * c.opt (Wsizeof-pointer-div): New warning option.
2444
2445 2017-06-01 Volker Reichelt <v.reichelt@netcologne.de>
2446
2447 * c.opt (Wcatch-value): New shortcut for Wcatch-value=1.
2448 (Wcatch-value=1): Enable by -Wall.
2449
2450 2017-05-30 David Malcolm <dmalcolm@redhat.com>
2451
2452 * c-format.c (gcc_cxxdiag_char_table): Add 'H' and 'I' to
2453 format_chars.
2454 * c.opt (fdiagnostics-show-template-tree): New option.
2455 (felide-type): New option.
2456
2457 2017-05-25 Volker Reichelt <v.reichelt@netcologne.de>
2458
2459 * c.opt (Wcatch-value=): New C++ warning flag.
2460
2461 2017-05-24 Nathan Sidwell <nathan@acm.org>
2462
2463 * c=common.c (field_decl_cmp, resort_field_decl_cmp): Adjust T
2464 const casts to avoid warning.
2465
2466 2017-05-24 Martin Sebor <msebor@redhat.com>
2467
2468 PR c/80731
2469 * c-common.h (unsafe_conversion_p): Add a function argument.
2470 * c-common.c (unsafe_conversion_p): Same.
2471 Add type names and values to diagnostics.
2472 (scalar_to_vector): Adjust.
2473 * c-warn.c (constant_expression_error): Add a function argument.
2474 Add type names and values to diagnostics.
2475 (conversion_warning): Add a function argument.
2476 Add type names and values to diagnostics.
2477 (warnings_for_convert_and_check): Same.
2478
2479 2017-05-19 Jason Merrill <jason@redhat.com>
2480
2481 * c-warn.c (match_case_to_enum_1): Don't warn about enums with no
2482 enumerators.
2483
2484 2017-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
2485
2486 * c-format.c (locus): Move out of function scope,
2487 add GTY attribute.
2488
2489 2017-05-19 Nathan Sidwell <nathan@acm.org>
2490
2491 * c-opts.c (class_dump_file, class_dump_flags): Delete.
2492 (c_common_parse_file): Remove class dump handling.
2493 (get_dump_info): Likewise.
2494
2495 2017-05-19 Richard Biener <rguenther@suse.de>
2496
2497 PR c++/80593
2498 * c-warn.c (strict_aliasing_warning): Do not warn for accesses
2499 to alias-set zero memory.
2500
2501 2017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
2502
2503 * c-format.c (local_tree_type_node): Add GTY attribute.
2504
2505 2017-05-18 Marek Polacek <polacek@redhat.com>
2506
2507 * c-common.c (c_common_type_for_size): Use NULL_TREE instead of 0.
2508 (c_common_fixed_point_type_for_size): Likewise.
2509 (c_common_type_for_mode): Likewise.
2510 (shorten_compare): Likewise.
2511 (c_promoting_integer_type_p): Use false/true instead of 0/1.
2512 * c-pragma.c (maybe_apply_renaming_pragma): Use NULL_TREE instead of 0.
2513
2514 2017-05-18 Marek Polacek <polacek@redhat.com>
2515
2516 * c-common.c (self_promoting_args_p): Change the return type to bool.
2517 Use false/true instead of 0/1.
2518 * c-common.h (self_promoting_args_p): Update.
2519
2520 2017-05-17 Marek Polacek <polacek@redhat.com>
2521
2522 * c-common.c: Use NULL_TREE instead of 0 where appropriate.
2523 * c-warn.c: Likewise.
2524
2525 2017-05-17 Ville Voutilainen <ville.voutilainen@gmail.com>
2526
2527 Implement new C++ intrinsics __is_assignable and __is_constructible.
2528 * c-common.c (__is_assignable, __is_constructible): New.
2529 * c-common.h (RID_IS_ASSIGNABLE, RID_IS_CONSTRUCTIBLE): Likewise.
2530
2531 2017-05-17 Martin Liska <mliska@suse.cz>
2532
2533 * c-common.h: Introduce dump_flags_t type and
2534 use it instead of int type.
2535 * c-gimplify.c (c_genericize): Likewise.
2536 * c-opts.c: Likewise.
2537
2538 2017-05-17 Marek Polacek <polacek@redhat.com>
2539
2540 * c-common.c (c_save_expr): Remove.
2541 (c_common_truthvalue_conversion): Remove a call to c_save_expr.
2542 * c-common.h (c_save_expr): Remove declaration.
2543
2544 2017-05-09 Volker Reichelt <v.reichelt@netcologne.de>
2545
2546 PR c/35441
2547 * c-pretty-print.c (c_pretty_printer::expression): Handle MAX_EXPR,
2548 MIN_EXPR, EXACT_DIV_EXPR, RDIV_EXPR, LROTATE_EXPR, RROTATE_EXPR.
2549 (c_pretty_printer::postfix_expression): Handle MAX_EXPR, MIN_EXPR.
2550 (c_pretty_printer::multiplicative_expression): Handle EXACT_DIV_EXPR,
2551 RDIV_EXPR.
2552 (pp_c_shift_expression): Handle LROTATE_EXPR, RROTATE_EXPR.
2553
2554 2017-05-09 Marek Polacek <polacek@redhat.com>
2555
2556 PR c/80525
2557 * c-warn.c (unwrap_c_maybe_const): New.
2558 (warn_logical_operator): Call it.
2559
2560 2017-05-09 Nathan Sidwell <nathan@acm.org>
2561
2562 * c-common.c (c_register_builtin_type): Use pushdecl lang_hook.
2563 * c-common.h (pushdecl_top_level, pushdecl): Don't declare here.
2564
2565 2017-05-08 Martin Sebor <msebor@redhat.com>
2566
2567 PR translation/80280
2568 * c-format.h (struct format_flag_spec): Add new member.
2569 (T89_T): New macro.
2570 * c-format.c (local_tree_type_node): New global.
2571 (printf_flag_specs, asm_fprintf_flag_spec): Initialize new data.
2572 (gcc_diag_flag_specs, scanf_flag_specs, strftime_flag_specs): Ditto.
2573 (strfmon_flag_specs): Likewise.
2574 (gcc_diag_char_table, gcc_cdiag_char_table): Split up specifiers
2575 with distinct quoting properties.
2576 (gcc_tdiag_char_table, gcc_cxxdiag_char_table): Same.
2577 (flag_chars_t::validate): Add argument and handle bad quoting.
2578 (check_format_info_main): Handle quoting problems.
2579 (init_dynamic_diag_info): Simplify.
2580
2581 2017-05-08 Jason Merrill <jason@redhat.com>
2582
2583 * c-opts.c (c_common_post_options): Update defaults for
2584 flag_abi_version and flag_abi_compat_version.
2585
2586 2017-05-05 David Malcolm <dmalcolm@redhat.com>
2587
2588 * c-common.c (c_cpp_error): Replace report_diagnostic
2589 with diagnostic_report_diagnostic.
2590
2591 2017-05-04 Martin Sebor <msebor@redhat.com>
2592
2593 PR translation/80280
2594 * c-attribs.c (handle_alias_ifunc_attribute): Quote a %D directive.
2595 (handle_weakref_attribute): Same.
2596
2597 2017-05-03 Nathan Sidwell <nathan@acm.org>
2598
2599 Canonicalize canonical type hashing
2600 * c-common.c (complete_array_type): Use type_hash_canon.
2601
2602 2017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
2603
2604 PR c++/80038
2605 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): Remove
2606 prototype.
2607 (cilk_install_body_pedigree_operations): Likewise.
2608 * cilk.c (cilk_set_spawn_marker): Mark functions that should be
2609 detatched.
2610 (cilk_gimplify_call_params_in_spawned_fn): Remove.
2611 (cilk_install_body_pedigree_operations): Likewise.
2612 (gimplify_cilk_spawn): Add EXPR_STMT and CLEANUP_POINT_EXPR
2613 unwrapping.
2614
2615 2017-04-27 Jakub Jelinek <jakub@redhat.com>
2616
2617 PR c++/80534
2618 * c-common.c (complete_array_type): Only hash TYPE_TYPELESS_STORAGE
2619 flag on non-aggregate element types.
2620
2621 2017-04-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
2622
2623 * c-common.c (c_type_hasher, type_hash_table): Remove.
2624 (c_common_get_alias_set): Remove unreachable code.
2625 * c-opts.c (c_common_post_options): Make sure cc1 takes only one file.
2626
2627 2017-04-20 Volker Reichelt <v.reichelt@netcologne.de>
2628
2629 * c.opt (Wextra-semi): New C++ warning flag.
2630
2631 2017-04-20 Jakub Jelinek <jakub@redhat.com>
2632
2633 PR middle-end/80423
2634 * c-common.c (complete_array_type): Preserve TYPE_TYPELESS_STORAGE.
2635
2636 2017-04-18 Jakub Jelinek <jakub@redhat.com>
2637
2638 PR middle-end/79788
2639 PR middle-end/80375
2640 * c-common.c (c_common_type_for_mode): Don't handle
2641 widest_*_literal_type_node here.
2642 c_common_signed_or_unsigned_type): Likewise.
2643 (c_common_nodes_and_builtins): Set widest_*_literal_type_node
2644 to *intTI_type_node or *intDI_type_node depending on whether
2645 TImode is supported by the target or not.
2646
2647 2017-04-10 Martin Liska <mliska@suse.cz>
2648
2649 PR sanitizer/80350
2650 * c-ubsan.c (ubsan_instrument_shift): Evaluate RHS before
2651 doing an UBSAN check.
2652
2653 2017-04-03 Jonathan Wakely <jwakely@redhat.com>
2654
2655 * c-warn.c (do_warn_double_promotion): Fix typo in comment.
2656
2657 2017-03-31 Jakub Jelinek <jakub@redhat.com>
2658
2659 PR c++/79572
2660 * c-ubsan.h (ubsan_maybe_instrument_reference): Change argument to
2661 tree *.
2662 * c-ubsan.c (ubsan_maybe_instrument_reference): Likewise. Handle
2663 not just NOP_EXPR to REFERENCE_TYPE, but also INTEGER_CST with
2664 REFERENCE_TYPE.
2665
2666 2017-03-31 David Malcolm <dmalcolm@redhat.com>
2667
2668 PR documentation/78732
2669 * c.opt (Wendif-labels): Fix description to refer to
2670 #else rather than #elif.
2671
2672 2017-03-31 Jakub Jelinek <jakub@redhat.com>
2673
2674 PR libstdc++/80251
2675 * c-common.h (enum rid): Add RID_IS_AGGREGATE.
2676 * c-common.c (c_common_reswords): Add __is_aggregate trait.
2677
2678 2017-03-27 Jakub Jelinek <jakub@redhat.com>
2679
2680 PR middle-end/80162
2681 * c-common.c (c_common_mark_addressable_vec): Don't set
2682 TREE_ADDRESSABLE on DECL_HARD_REGISTER.
2683
2684 2017-03-21 Martin Sebor <msebor@redhat.com>
2685
2686 PR c++/79548
2687 * c-common.c (set_underlying_type): Mark type used only when
2688 original del is declared unused.
2689
2690 2017-03-10 David Malcolm <dmalcolm@redhat.com>
2691
2692 PR translation/79848
2693 * c-format.c (check_format_string): Simplify uses of "%<%s%>" to
2694 "%qs".
2695
2696 2017-03-10 David Malcolm <dmalcolm@redhat.com>
2697
2698 PR c/79921
2699 * c-indentation.c (warn_for_misleading_indentation): Remove parens
2700 from inform's message, so that xgettext can locate it.
2701
2702 2017-03-09 Marek Polacek <polacek@redhat.com>
2703
2704 PR c++/79962
2705 PR c++/79984
2706 * c-attribs.c (handle_nonnull_attribute): Save the result of default
2707 conversion to the attribute list.
2708
2709 2017-03-09 Martin Liska <mliska@suse.cz>
2710
2711 * c-ada-spec.c (macro_length): Increment value instead of a pointer.
2712
2713 2017-03-03 Jason Merrill <jason@redhat.com>
2714
2715 * c.opt (Wnoexcept-type): New.
2716
2717 2017-03-02 Richard Biener <rguenther@suse.de>
2718
2719 PR c/79756
2720 * c-common.c (c_common_mark_addressable_vec): Look through
2721 C_MAYBE_CONST_EXPR.
2722
2723 2017-02-28 Martin Liska <mliska@suse.cz>
2724
2725 * c.opt: Replace space with tabular for options of <number>
2726 type.
2727
2728 2017-02-28 Martin Liska <mliska@suse.cz>
2729
2730 * c.opt: Fix --help=option -Q for options which are of
2731 an enum type.
2732
2733 2017-02-24 Jakub Jelinek <jakub@redhat.com>
2734
2735 PR c++/79588
2736 * c-common.c (check_function_restrict): New function.
2737 (check_function_arguments): Add FNDECL argument. Call
2738 check_function_restrict if -Wrestrict.
2739 * c-warn.c (warn_for_restrict): Remove ARGS argument, add ARGARRAY
2740 and NARGS. Use auto_vec for ARG_POSITIONS, simplify.
2741 * c-common.h (check_function_arguments): Add FNDECL argument.
2742 (warn_for_restrict): Remove ARGS argument, add ARGARRAY and NARGS.
2743
2744 2017-02-24 Eric Botcazou <ebotcazou@adacore.com>
2745
2746 * c-ada-spec.c (dump_ada_function_declaration): Add comment about the
2747 treatment of parameters with pointer-to-tagged type and tidy up.
2748 (print_ada_methods): Remove the special treatment of C++ static member
2749 functions.
2750
2751 2017-02-22 Martin Liska <mliska@suse.cz>
2752
2753 * c.opt: Replace inequality signs with square brackets
2754 for -Wnornalized.
2755
2756 2017-02-21 Jakub Jelinek <jakub@redhat.com>
2757
2758 PR c++/79641
2759 * c-attribs.c (handle_mode_attribute): Use build_qualified_type to
2760 preserve quals.
2761
2762 2017-02-17 Joseph Myers <joseph@codesourcery.com>
2763
2764 * c-cppbuiltin.c (builtin_define_float_constants): Define
2765 __DECIMAL_DIG__ to the value for long double.
2766
2767 2017-02-15 Marek Polacek <polacek@redhat.com>
2768
2769 PR c/79515
2770 * c-warn.c (do_warn_double_promotion): Don't warn if an invalid
2771 conversion has occured.
2772
2773 2017-01-24 David Malcolm <dmalcolm@redhat.com>
2774
2775 * c-common.c (c_common_reswords): Add "__RTL".
2776 * c-common.h (enum rid): Add RID_RTL.
2777
2778 2017-01-20 Marek Polacek <polacek@redhat.com>
2779
2780 PR c/64279
2781 * c-common.h (do_warn_duplicated_branches_r): Declare.
2782 * c-gimplify.c (c_genericize): Walk the function tree calling
2783 do_warn_duplicated_branches_r.
2784 * c-warn.c (expr_from_macro_expansion_r): New.
2785 (do_warn_duplicated_branches): New.
2786 (do_warn_duplicated_branches_r): New.
2787 * c.opt (Wduplicated-branches): New option.
2788
2789 2017-01-17 David Malcolm <dmalcolm@redhat.com>
2790
2791 PR c++/71497
2792 * c-indentation.c (warn_for_misleading_indentation): Use the past
2793 subjunctive in the note.
2794
2795 2017-01-17 Aldy Hernandez <aldyh@redhat.com>
2796
2797 PR c/79116
2798 * array-notation-common.c (cilkplus_extract_an_triplets): Convert
2799 start type to integer_type.
2800
2801 2017-01-16 Jakub Jelinek <jakub@redhat.com>
2802
2803 PR driver/49726
2804 * c.opt (gen-decls): Add Driver flag.
2805
2806 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
2807
2808 Revert:
2809 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
2810
2811 PR c++/71737
2812 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
2813
2814 2017-01-16 Paolo Carlini <paolo.carlini@oracle.com>
2815
2816 PR c++/71737
2817 * c-common.c (set_underlying_type): Always set DECL_ORIGINAL_TYPE.
2818
2819 2017-01-12 Martin Sebor <msebor@redhat.com>
2820
2821 (-Wformat-overflow): ...to this.
2822
2823 2017-01-11 Martin Sebor <msebor@redhat.com>
2824
2825 PR c/78768
2826 * c.opt (-Walloca-larger-than, -Wformat-length, -Wformat-truncation):
2827 Also enable for LTO.
2828
2829 2017-01-10 Jason Merrill <jason@redhat.com>
2830
2831 Implement P0195R2, C++17 variadic using.
2832 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_variadic_using.
2833
2834 2017-01-09 Jakub Jelinek <jakub@redhat.com>
2835
2836 PR translation/79019
2837 PR translation/79020
2838 * c.opt (Wnormalized=): Fix typo in description.
2839
2840 2017-01-08 Martin Sebor <msebor@redhat.com>
2841
2842 PR middle-end/77708
2843 * c.opt (-Wformat-truncation): New option.
2844
2845 2017-01-06 Alexandre Oliva <aoliva@redhat.com>
2846
2847 * c-pretty-print.c (pp_c_tree_decl_identifier): Convert 16-bit
2848 value to unsigned short to fit in 4 hex digits without
2849 warnings.
2850
2851 2017-01-05 Eric Botcazou <ebotcazou@adacore.com>
2852
2853 * c.opt (fsso-struct): Add 'native' value.
2854
2855 2017-01-05 Martin Liska <mliska@suse.cz>
2856
2857 PR pch/78970
2858 * c-opts.c (c_common_post_options): Reject '-' filename for a precompiled
2859 header.
2860
2861 2017-01-04 Marek Polacek <polacek@redhat.com>
2862
2863 PR c++/64767
2864 * c.opt (Wpointer-compare): New option.
2865
2866 2017-01-04 Jakub Jelinek <jakub@redhat.com>
2867
2868 PR driver/78957
2869 * c.opt (fsso-struct=): Add RejectNegative.
2870
2871 2017-01-01 Jakub Jelinek <jakub@redhat.com>
2872
2873 Update copyright years.
2874
2875 2016-12-29 Martin Liska <mliska@suse.cz>
2876
2877 PR c/78933
2878 * c.opt (strong-eval-order): Add RejectNegative keyword.
2879
2880 2016-12-22 Jason Merrill <jason@redhat.com>
2881
2882 Implement P0522R0, matching of template template arguments.
2883 * c-cppbuiltin.c (c_cpp_builtins): Define
2884 __cpp_template_template_args.
2885
2886 2016-12-21 Jakub Jelinek <jakub@redhat.com>
2887
2888 PR bootstrap/78817
2889 * c-common.c (struct nonnull_arg_ctx): New type.
2890 (check_function_nonnull): Return bool instead of void. Use
2891 nonnull_arg_ctx as context rather than just location_t.
2892 (check_nonnull_arg): Adjust for the new context type, set
2893 warned_p to true if a warning has been diagnosed.
2894 (check_function_arguments): Return bool instead of void.
2895 * c-common.h (check_function_arguments): Adjust prototype.
2896
2897 2016-12-21 Jason Merrill <jason@redhat.com>
2898
2899 * c.opt (-fnew-ttp-matching): New flag.
2900 * c-opts.c (c_common_post_options): Default on if -std=c++1z.
2901
2902 2016-12-14 Martin Jambor <mjambor@suse.cz>
2903
2904 * c-omp.c: Include omp-general.h instead of omp-low.h.
2905 (c_finish_oacc_wait): Adjusted call to find_omp_clause to use its new
2906 name.
2907
2908 2016-12-14 Martin Sebor <msebor@redhat.com>
2909
2910 PR c/17308
2911 * c-common.c (check_nonnull_arg): Disable when optimization
2912 is enabled.
2913
2914 2016-12-12 Marek Polacek <polacek@redhat.com>
2915
2916 PR c++/78647
2917 * c-common.c (attribute_fallthrough_p): Return false for
2918 error_mark_node.
2919
2920 2016-12-08 Martin Sebor <msebor@redhat.com>
2921
2922 PR c/78284
2923 * c.opt (-Walloc-zero, -Walloc-size-larger-than): New options.
2924
2925 2016-12-08 Martin Sebor <msebor@redhat.com>
2926
2927 PR c/78165
2928 * c-pretty-print (pp_c_integer_constant): Avoid formatting type
2929 suffix.
2930
2931 2016-12-07 Martin Sebor <msebor@redhat.com>
2932
2933 PR c/53562
2934 PR middle-end/77784
2935 PR middle-end/78149
2936 PR middle-end/78138
2937 * c.opt (-Wstringop-overflow): New option.
2938
2939 2016-12-02 Maxim Ostapenko <m.ostapenko@samsung.com>
2940
2941 * c-attribs.c (asan odr indicator): New attribute.
2942 (handle_asan_odr_indicator_attribute): New function.
2943
2944 2016-11-26 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2945
2946 * c-common.c (c_common_nodes_and_builtins): Remove initialization of
2947 ptrdiff_type_node;
2948
2949 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
2950
2951 * c-common.c (excess_precision_mode_join): New.
2952 (c_ts18661_flt_eval_method): New.
2953 (c_c11_flt_eval_method): Likewise.
2954 (c_flt_eval_method): Likewise.
2955 * c-common.h (excess_precision_mode_join): New.
2956 (c_flt_eval_method): Likewise.
2957 * c-cppbuiltin.c (c_cpp_flt_eval_method_iec_559): New.
2958 (cpp_iec_559_value): Call it.
2959 (c_cpp_builtins): Modify logic for __LIBGCC_*_EXCESS_PRECISION__,
2960 call c_flt_eval_method to set __FLT_EVAL_METHOD__ and
2961 __FLT_EVAL_METHOD_TS_18661_3__.
2962
2963 2016-11-23 James Greenhalgh <james.greenhalgh@arm.com>
2964
2965 * c-opts.c (c_common_post_options): Add logic to handle the default
2966 case for -fpermitted-flt-eval-methods.
2967
2968 2016-11-23 Paolo Bonzini <bonzini@gnu.org>
2969
2970 * c.opt (Wexpansion-to-defined): New.
2971
2972 2016-11-23 Jakub Jelinek <jakub@redhat.com>
2973
2974 PR target/78451
2975 * c-pragma.c (handle_pragma_target): Don't replace
2976 current_target_pragma, but chainon the new args to the current one.
2977
2978 2016-11-22 Nathan Sidwell <nathan@acm.org>
2979
2980 * array-notation-common.c (cilkplus_extract_an_trplets): Fix
2981 indentation and formatting.
2982
2983 2016-11-21 Martin Sebor <msebor@redhat.com>
2984
2985 * c.opt (-fprintf-return-value): Enable by default.
2986
2987 2016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
2988
2989 PR c++/71973
2990 * c.opt (-Wbuiltin-declaration-mismatch): New warning.
2991 * c-common.c (c_common_nodes_and_builtins): Initialize
2992 const_tm_ptr_type_node.
2993
2994 2016-11-16 Marek Polacek <polacek@redhat.com>
2995
2996 PR c/78285
2997 * c-common.c (c_add_case_label): Turn error_at calls into inform.
2998
2999 2016-11-14 Jakub Jelinek <jakub@redhat.com>
3000
3001 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_structured_bindings.
3002
3003 2016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
3004 Richard Biener <rguenther@suse.de>
3005
3006 * c-common.h (c_common_resword): Add RID_GIMPLE, RID_PHI types.
3007 * c-common.h (enum rid): Add RID_GIMPLE, RID_PHI.
3008 * c.opt (fgimple): New option.
3009
3010 2016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
3011
3012 PR c/35503
3013 * c-common.h (warn_for_restrict): Declare.
3014 * c-warn.c: Include gcc-rich-location.h.
3015 (warn_for_restrict): New function.
3016 * c-format.c (gcc_tdiag_char_table): Add entry for "Z" specifier.
3017 (gcc_cdiag_char_table): Likewise.
3018 (gcc_cxxdiag_char_table): Likewise.
3019 * c.opt (Wrestrict): New option.
3020
3021 2016-11-13 Eric Botcazou <ebotcazou@adacore.com>
3022
3023 * c-ada-spec.c (print_ada_declaration): For typedef declarations, look
3024 for nested types only if the type is a record or union and dump SLOC.
3025
3026 2016-11-09 Jason Merrill <jason@redhat.com>
3027
3028 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_template_auto.
3029
3030 2016-11-09 Jakub Jelinek <jakub@redhat.com>
3031
3032 * c-ubsan.c (ubsan_instrument_shift): Handle split
3033 -fsanitize=shift-base and -fsanitize=shift-exponent.
3034
3035 2016-11-07 Jason Merrill <jason@redhat.com>
3036
3037 * c.opt (Wc++1z-compat): New.
3038 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_noexcept_function_type.
3039
3040 2016-11-07 Martin Liska <mliska@suse.cz>
3041
3042 * c-warn.c (warn_for_unused_label): Save all labels used
3043 in goto or in &label.
3044
3045 2016-11-03 Jason Merrill <jason@redhat.com>
3046
3047 * c-cppbuiltin.c (c_cpp_builtins): Correct
3048 __cpp_inheriting_constructors.
3049
3050 2016-11-01 Jason Merrill <jason@redhat.com>
3051
3052 * c-cppbuiltin.c (c_cpp_builtins): Update
3053 __cpp_inheriting_constructors.
3054
3055 * c.opt (-fnew-inheriting-ctors): New.
3056 * c-opts.c: Default to on for ABI 11+.
3057
3058 2016-10-31 Jakub Jelinek <jakub@redhat.com>
3059
3060 PR c++/77948
3061 * c.opt (fext-numeric-literals): Add Var and Init.
3062 * c-opts.c (c_common_handle_option): Don't clear
3063 cpp_opts->ext_numeric_literals for -std=c++{11,14,1z}.
3064 (c_common_post_options): Clear it here if not set
3065 explicitly.
3066
3067 2016-10-28 Aldy Hernandez <aldyh@redhat.com>
3068
3069 PR debug/77773
3070 * c-pretty-print.c (simple_type_specifier): Do not dereference `t'
3071 if NULL.
3072
3073 2016-10-25 Jakub Jelinek <jakub@redhat.com>
3074
3075 * c-common.h (enum rid): Add RID_BUILTIN_LAUNDER.
3076 * c-common.c (c_common_reswords): Add __builtin_launder.
3077
3078 2016-10-24 Bernd Edlinger <bernd.edlinger@hotmail.de>
3079
3080 * c-common.c (c_common_truthvalue_conversion): Warn for
3081 multiplications in boolean context. Fix the quoting of '<<' and '<'
3082 in the shift warning.
3083
3084 2016-10-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
3085
3086 * c-common.c (c_common_truthvalue_conversion): Fix the comment.
3087
3088 2016-10-20 Jason Merrill <jason@redhat.com>
3089
3090 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_concepts value.
3091
3092 2016-10-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
3093
3094 * c-common.c (c_common_truthvalue_conversion): Warn only for signed
3095 integer shift ops in boolean context.
3096
3097 2016-10-18 Aldy Hernandez <aldyh@redhat.com>
3098
3099 * c.opt (Walloca): New.
3100 (Walloca-larger-than=): New.
3101 (Wvla-larger-than=): New.
3102
3103 2016-10-17 Marek Polacek <polacek@redhat.com>
3104
3105 * c-warn.c (find_array_ref_with_const_idx_r): Remove parameter names.
3106 Return immediately when finding a match.
3107 (warn_tautological_cmp): Remove a boolean variable that is no longer
3108 needed.
3109
3110 2016-10-17 Marek Polacek <polacek@redhat.com>
3111
3112 * c-attribs.c: New file.
3113 * c-common.c: Move attributes handling to c-attribs.c.
3114 (get_nonnull_operand): No longer static.
3115 * c-common.h: Move the declarations from c-attribs.c to its own section.
3116
3117 2016-10-14 Jason Merrill <jason@redhat.com>
3118
3119 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases
3120 and __cpp_deduction_guides.
3121
3122 2016-10-13 Jason Merrill <jason@redhat.com>
3123
3124 * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables.
3125
3126 2016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
3127
3128 * c-cppbuiltin.c: Include memmodel.h.
3129 * c-opts.c: Likewise.
3130 * c-pragma.c: Likewise.
3131 * c-warn.c: Likewise.
3132
3133 2016-10-12 Jakub Jelinek <jakub@redhat.com>
3134
3135 * c.opt (Wextra): Add as C/C++/ObjC/ObjC++ option.
3136 (Wimplicit-fallthrough=): Enable for these languages by -Wextra.
3137 * c-opts.c (sanitize_cpp_opts): Initialize
3138 cpp_opts->cpp_warn_implicit_fallthrough.
3139
3140 2016-10-11 Marek Polacek <polacek@redhat.com>
3141
3142 * c-common.c (warning_candidate_p): Change the return type to bool
3143 and return true/false instead of 1/0.
3144 (vector_mode_valid_p): Likewise.
3145
3146 2016-10-11 Marek Polacek <polacek@redhat.com>
3147
3148 * c-common.c (fold_for_warn): No longer static.
3149 (bool_promoted_to_int_p): Likewise.
3150 (c_common_get_narrower): Likewise.
3151 (constant_expression_warning): Move to c-warn.c.
3152 (constant_expression_error): Likewise.
3153 (overflow_warning): Likewise.
3154 (warn_logical_operator): Likewise.
3155 (find_array_ref_with_const_idx_r): Likewise.
3156 (warn_tautological_cmp): Likewise.
3157 (expr_has_boolean_operands_p): Likewise.
3158 (warn_logical_not_parentheses): Likewise.
3159 (warn_if_unused_value): Likewise.
3160 (strict_aliasing_warning): Likewise.
3161 (sizeof_pointer_memaccess_warning): Likewise.
3162 (check_main_parameter_types): Likewise.
3163 (conversion_warning): Likewise.
3164 (warnings_for_convert_and_check): Likewise.
3165 (match_case_to_enum_1): Likewise.
3166 (match_case_to_enum): Likewise.
3167 (c_do_switch_warnings): Likewise.
3168 (warn_for_omitted_condop): Likewise.
3169 (readonly_error): Likewise.
3170 (lvalue_error): Likewise.
3171 (invalid_indirection_error): Likewise.
3172 (warn_array_subscript_with_type_char): Likewise.
3173 (warn_about_parentheses): Likewise.
3174 (warn_for_unused_label): Likewise.
3175 (warn_for_div_by_zero): Likewise.
3176 (warn_for_memset): Likewise.
3177 (warn_for_sign_compare): Likewise.
3178 (do_warn_double_promotion): Likewise.
3179 (do_warn_unused_parameter): Likewise.
3180 (record_locally_defined_typedef): Likewise.
3181 (maybe_record_typedef_use): Likewise.
3182 (maybe_warn_unused_local_typedefs): Likewise.
3183 (maybe_warn_bool_compare): Likewise.
3184 (maybe_warn_shift_overflow): Likewise.
3185 (warn_duplicated_cond_add_or_warn): Likewise.
3186 (diagnose_mismatched_attributes): Likewise.
3187 * c-common.h: Move the declarations from c-warn.c to its own section.
3188 * c-warn.c: New file.
3189
3190 2016-10-08 Jason Merrill <jason@redhat.com>
3191
3192 * c-common.c (c_common_truthvalue_conversion): Don't distribute
3193 into COND_EXPR in C++.
3194
3195 2016-10-08 Jakub Jelinek <jakub@redhat.com>
3196
3197 * c-lex.c (c_lex_with_flags) <case CPP_COMMENT>: For CPP_COMMENT
3198 token with PREV_FALLTHROUGH, skip all following CPP_PADDING and
3199 CPP_COMMENT tokens and set add_flags to PREV_FALLTHROUGH afterwards.
3200
3201 2016-10-07 Jakub Jelinek <jakub@redhat.com>
3202
3203 Implement LWG2296 helper intrinsic
3204 * c-common.h (enum rid): Add RID_ADDRESSOF.
3205 * c-common.c (c_common_reswords): Add __builtin_addressof.
3206
3207 2016-10-07 Bernd Edlinger <bernd.edlinger@hotmail.de>
3208
3209 PR c++/77700
3210 * c-common.c (c_common_truthvalue_conversion): Warn also for
3211 suspicious enum values in boolean context.
3212
3213 2016-10-06 Jakub Jelinek <jakub@redhat.com>
3214
3215 Implement P0258R2 - helper for C++17
3216 std::has_unique_object_representations trait
3217 * c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
3218 * c-common.c (c_common_reswords): Add
3219 __has_unique_object_representations.
3220
3221 2016-10-05 Jakub Jelinek <jakub@redhat.com>
3222
3223 PR sanitizer/66343
3224 * c-ubsan.c (ubsan_instrument_return): Don't call
3225 initialize_sanitizer_builtins here.
3226
3227 2016-10-05 Bernd Edlinger <bernd.edlinger@hotmail.de>
3228
3229 * c-common.c (c_common_truthvalue_conversion): Warn also for suspicious
3230 conditional expression in boolean context when only one arm is
3231 non-boolean.
3232
3233 2016-10-05 Jakub Jelinek <jakub@redhat.com>
3234
3235 PR sanitizer/77823
3236 * c-ubsan.c (ubsan_instrument_shift): Return NULL_TREE if type0
3237 is not integral.
3238
3239 * c-common.c (c_common_reswords): Update comment for C++11.
3240
3241 2016-10-04 Jason Merrill <jason@redhat.com>
3242
3243 * c-common.c (make_tree_vector_from_ctor): New.
3244 * c-common.h: Declare it.
3245
3246 2016-10-04 Jakub Jelinek <jakub@redhat.com>
3247
3248 * c-cppbuiltin.c (c_cpp_builtins): Don't define
3249 __LIBGCC_JCR_SECTION_NAME__.
3250
3251 2016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
3252
3253 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
3254 left shift in boolean context.
3255
3256 2016-09-29 Jakub Jelinek <jakub@redhat.com>
3257
3258 Implement P0001R1 - C++17 removal of register storage class specifier
3259 * c.opt (Wregister): New warning.
3260 * c-opts.c (c_common_post_options): Enable -Wregister by
3261 default for C++17.
3262
3263 2016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
3264
3265 * c-opts.c (c_common_post_options): Remove special case for
3266 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
3267 in C++.
3268
3269 2016-09-27 Jakub Jelinek <jakub@redhat.com>
3270
3271 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
3272 -std=c++1z.
3273
3274 * c-ada-spec.c (print_ada_declaration): Remove break after return.
3275
3276 2016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
3277
3278 * c-common.c: Include memmodel.h.
3279
3280 2016-09-26 Marek Polacek <polacek@redhat.com>
3281
3282 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
3283
3284 2016-09-26 Marek Polacek <polacek@redhat.com>
3285
3286 PR c/7652
3287 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
3288 (handle_fallthrough_attribute): New function.
3289 (attribute_fallthrough_p): New function.
3290 * c-common.h (attribute_fallthrough_p): Declare.
3291
3292 2016-09-24 Marek Polacek <polacek@redhat.com>
3293
3294 PR c/77490
3295 * c.opt (Wbool-operation): New.
3296
3297 2016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
3298
3299 * c-common.c (c_common_truthvalue_conversion): Inhibit
3300 Wint-in-bool-context warning with from_macro_definition_at.
3301 Mention the expression will always evaluate to true.
3302
3303 2016-09-21 Martin Sebor <msebor@redhat.com>
3304
3305 PR bootstrap/77676
3306 * c.opt (fprintf-return-value): Temporarily initialize to zero
3307 to unblock bootstrap failures.
3308
3309 2016-09-21 Jakub Jelinek <jakub@redhat.com>
3310
3311 PR c++/77651
3312 * c.opt (Waligned-new=): Add RejectNegative.
3313 (faligned-new=): Likewise. Spelling fix - change
3314 aligned_new_threshhold to aligned_new_threshold.
3315 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
3316 to aligned_new_threshold.
3317
3318 2016-09-20 Martin Sebor <msebor@redhat.com>
3319
3320 PR middle-end/49905
3321 * c.opt: Add -Wformat-length and -fprintf-return-value.
3322
3323 2016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
3324
3325 PR c++/77434
3326 * c.opt (Wint-in-bool-context): New warning.
3327 * c-common.c (c_common_truthvalue_conversion): Warn on integer
3328 constants in boolean context.
3329
3330 2016-09-19 Joseph Myers <joseph@codesourcery.com>
3331
3332 * c-common.c (max_align_t_align): Also consider alignment of
3333 float128_type_node.
3334
3335 2016-09-15 Jason Merrill <jason@redhat.com>
3336
3337 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
3338 DECL_EXTERNAL.
3339
3340 2016-09-14 Jason Merrill <jason@redhat.com>
3341
3342 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
3343 limit FIELD_DECL, either.
3344
3345 2016-09-14 Marek Polacek <polacek@redhat.com>
3346
3347 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
3348 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
3349 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
3350
3351 2016-09-13 David Malcolm <dmalcolm@redhat.com>
3352
3353 * c-common.c (warn_logical_not_parentheses): Replace
3354 rich_location::add_fixit_insert calls with add_fixit_insert_before
3355 and add_fixit_insert_after, eliminating the "next_loc" calculation.
3356
3357 2016-09-13 Jason Merrill <jason@redhat.com>
3358 Tom de Vries <tom@codesourcery.com>
3359
3360 PR c++/77427
3361 * c-common.c (set_underlying_type): Don't treat array as builtin type.
3362
3363 2016-09-13 Jason Merrill <jason@redhat.com>
3364
3365 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
3366 limit types at all.
3367
3368 2016-09-12 Jason Merrill <jason@redhat.com>
3369
3370 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
3371 bit/byte confusion, allow large alignment for types.
3372
3373 2016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
3374
3375 PR c++/77496
3376 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
3377
3378 2016-09-12 David Malcolm <dmalcolm@redhat.com>
3379
3380 PR c/72858
3381 * c-format.c (argument_parser::check_argument_type): Add params
3382 "type_start" and "conversion_char". Use the former to generate
3383 offset_to_type_start and pass it and conversion_char to
3384 check_format_types.
3385 (check_format_info_main): Capture the start of the type
3386 information as "type_start", and pass it an format_char
3387 to arg_parser.check_argument_type.
3388 (check_format_types): Provide an example in the leading comment.
3389 Add params "offset_to_type_start" and "conversion_char"; pass
3390 them to format_type_warning calls.
3391 (test_get_modifier_for_format_len): Likewise.
3392 (matching_type_p): New function.
3393 (get_format_for_type): Add param "conversion_char" and move
3394 implementation into...
3395 (get_format_for_type_1): ...new function, called twice.
3396 Use new function matching_type_p rather than checking for
3397 TYPE_CANONICAL equality.
3398 (get_corrected_substring): New function.
3399 (format_type_warning): Provide an example in the leading comment.
3400 Add params "offset_to_type_start" and "conversion_char". Replace
3401 call to get_format_for_type with call to get_corrected_substring
3402 and move rejection of hints for widths/precisions there.
3403 (assert_format_for_type_streq): Add param "conversion_char".
3404 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
3405 (test_get_format_for_type_printf): Add conversion chars to the
3406 tests, adding coverage for various combinations of integer
3407 vs double conversions, and for preserving octal and hexadecimal
3408 conversions.
3409 (test_get_format_for_type_scanf): Add conversion chars to the
3410 tests.
3411
3412 2016-09-10 Tom de Vries <tom@codesourcery.com>
3413
3414 PR C/71602
3415 * c-common.c (build_va_arg): Handle more strict
3416 targetm.canonical_va_list_type. Replace first argument type error with
3417 assert.
3418
3419 2016-09-09 Martin Sebor <msebor@redhat.com>
3420
3421 PR c/77520
3422 PR c/77521
3423 * c-format.c (argument_parser::find_format_char_info): Use %qc
3424 format directive unconditionally.
3425
3426 2016-09-09 Jason Merrill <jason@redhat.com>
3427
3428 Implement C++17 new of over-aligned types.
3429 * c.opt: Add -faligned-new and -Waligned-new.
3430 * c-common.c (max_align_t_align): Split out from...
3431 (cxx_fundamental_alignment_p): ...here.
3432 * c-common.h: Declare it.
3433 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
3434
3435 2016-09-09 Joseph Myers <joseph@codesourcery.com>
3436
3437 * c-cppbuiltin.c (builtin_define_type_width): New function.
3438 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
3439 macros.
3440
3441 2016-09-07 David Malcolm <dmalcolm@redhat.com>
3442
3443 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
3444 a POINTER_TYPE.
3445 (substring_loc::get_location): Move to substring-locations.c,
3446 keeping implementation as...
3447 (c_get_substring_location): New function, from the above, reworked
3448 to use accessors rather than member lookup.
3449 * c-common.h (class substring_loc): Move to substring-locations.h,
3450 replacing with a forward decl.
3451 (c_get_substring_location): New decl.
3452 * c-format.c: Include "substring-locations.h".
3453 (format_warning_va): Move to substring-locations.c.
3454 (format_warning_at_substring): Likewise.
3455
3456 2016-09-06 Martin Sebor <msebor@redhat.com>
3457
3458 PR c/77336
3459 * c-format.c (check_function_format): Avoid issuing warnings for
3460 functions unless they call format functions with non-constant
3461 format strings.
3462
3463 2016-09-06 Richard Biener <rguenther@suse.de>
3464
3465 PR c/77450
3466 * c-common.c (c_common_mark_addressable_vec): Handle
3467 COMPOUND_LITERAL_EXPR.
3468
3469 2016-09-05 Marek Polacek <polacek@redhat.com>
3470
3471 PR c/77423
3472 * c-common.c (bool_promoted_to_int_p): New function.
3473 (expr_has_boolean_operands_p): New function.
3474 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
3475 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
3476
3477 2016-09-04 Tom de Vries <tom@codesourcery.com>
3478
3479 revert:
3480 2016-08-29 Tom de Vries <tom@codesourcery.com>
3481
3482 * c-common.c (build_va_arg): Replace first argument type error
3483 with assert.
3484
3485 2016-09-02 Jakub Jelinek <jakub@redhat.com>
3486
3487 PR c/65467
3488 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
3489 (c_finish_omp_for): Reject _Atomic qualified iterators.
3490
3491 2016-09-01 Martin Sebor <msebor@redhat.com>
3492
3493 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
3494 size to guarantee it fits the output of the formatted function
3495 regardless of its arguments.
3496
3497 2016-09-01 Marek Polacek <polacek@redhat.com>
3498
3499 PR c/7652
3500 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
3501 FALLTHRU comments.
3502
3503 2016-08-29 Marek Polacek <polacek@redhat.com>
3504
3505 PR c/77292
3506 * c-common.c (warn_logical_not_parentheses): Don't warn for
3507 a comparison or a logical operator.
3508
3509 2016-08-29 Tom de Vries <tom@codesourcery.com>
3510
3511 * c-common.c (build_va_arg): Fix type comparison assert.
3512
3513 2016-08-29 Tom de Vries <tom@codesourcery.com>
3514
3515 * c-common.c (build_va_arg): Replace first argument type error
3516 with assert.
3517
3518 2016-08-29 Tom de Vries <tom@codesourcery.com>
3519
3520 PR c/77398
3521 * c-common.c (build_va_arg): Add first argument error. Build va_arg
3522 with error_mark_node as va_list instead of with illegal va_list.
3523
3524 2016-08-25 Marek Polacek <polacek@redhat.com>
3525 David Malcolm <dmalcolm@redhat.com>
3526
3527 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
3528 * c-common.h (warn_logical_not_parentheses): Update declaration.
3529
3530 2016-08-22 Marek Polacek <polacek@redhat.com>
3531
3532 PR c++/77321
3533 * c-common.c (warn_for_memset): Check type for null.
3534
3535 2016-08-22 Joseph Myers <joseph@codesourcery.com>
3536
3537 * c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
3538 _FloatNx types for suffixes for built-in functions.
3539
3540 2016-08-19 Joseph Myers <joseph@codesourcery.com>
3541
3542 PR c/32187
3543 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
3544 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
3545 (RID_FLOAT128X): New enum rid values.
3546 (CASE_RID_FLOATN_NX): New macro.
3547 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
3548 keywords.
3549 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
3550 corresponding complex types.
3551 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
3552 _FloatNx and corresponding complex types.
3553 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
3554 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
3555 and _FloatNx types for the widest type for determining
3556 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
3557 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
3558 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
3559 and _FloatNx types.
3560 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
3561 constants.
3562 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
3563 _FloatNx types.
3564
3565 2016-08-18 David Malcolm <dmalcolm@redhat.com>
3566
3567 * c-opts.c (c_diagnostic_finalizer): Update for change to
3568 diagnostic_show_locus.
3569
3570 2016-08-18 David Malcolm <dmalcolm@redhat.com>
3571
3572 * c-common.c: Include "spellcheck.h".
3573 (cb_get_suggestion): New function.
3574 * c-common.h (cb_get_suggestion): New decl.
3575 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
3576 cb_get_suggestion.
3577
3578 2016-08-18 Marek Polacek <polacek@redhat.com>
3579
3580 PR c/71514
3581 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
3582 and pointer-to-VLA.
3583
3584 2016-08-16 David Malcolm <dmalcolm@redhat.com>
3585
3586 PR c/72857
3587 * c-common.c (substring_loc::get_range): Rename to...
3588 (substring_loc::get_location): ...this, converting param from a
3589 source_range * to a location_t *. Call
3590 get_source_location_for_substring rather than
3591 get_source_range_for_substring, and pass in m_caret_idx.
3592 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
3593 (substring_loc::get_range): Replace with...
3594 (substring_loc::get_location): ...this.
3595 (substring_loc::set_caret_index): New method.
3596 (substring_loc): Add field m_caret_idx.
3597 * c-format.c (format_warning_va): Update for above changes.
3598 Rename local "substring_loc" to "fmt_substring_loc" to avoid
3599 clashing with type name.
3600 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
3601 (check_argument_type): Likewise.
3602 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
3603 Use a copy when emitting warnings, setting the caret index from TYPE.
3604
3605 2016-08-16 Eric Botcazou <ebotcazou@adacore.com>
3606 Arnaud Charlet <charlet@adacore.com>
3607
3608 * c-ada-spec.c (dump_number): New function.
3609 (handle_escape_character): Likewise.
3610 (print_ada_macros): Add handling of constant integers and strings.
3611
3612 2016-08-12 Marek Polacek <polacek@redhat.com>
3613
3614 PR c/7652
3615 * c-common.c (scalar_to_vector): Adjust fall through comment.
3616 * c-opts.c (c_common_handle_option): Likewise.
3617 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
3618 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
3619 fall through comment.
3620 * cilk.c (extract_free_variables): Add FALLTHRU.
3621
3622 2016-08-10 Jason Merrill <jason@redhat.com>
3623
3624 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
3625
3626 2016-08-09 Jason Merrill <jason@redhat.com>
3627
3628 * c-common.c (c_common_attribute_table): vector_size affects type
3629 identity.
3630
3631 2016-08-09 Marek Polacek <polacek@redhat.com>
3632
3633 PR c/7652
3634 * c-ada-spec.c (dump_generic_ada_node): Add return.
3635
3636 2016-08-09 Jason Merrill <jason@redhat.com>
3637
3638 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
3639 C++17 constexpr lambdas.
3640
3641 2016-08-08 David Malcolm <dmalcolm@redhat.com>
3642
3643 PR c/64955
3644 * c-common.h (selftest::c_format_c_tests): New declaration.
3645 (selftest::run_c_tests): New declaration.
3646 * c-format.c: Include "selftest.h.
3647 (format_warning_va): Add param "corrected_substring" and use
3648 it to add a replacement fix-it hint.
3649 (format_warning_at_substring): Likewise.
3650 (format_warning_at_char): Update for new param of
3651 format_warning_va.
3652 (argument_parser::check_argument_type): Pass "fki" to
3653 check_format_types.
3654 (check_format_types): Add param "fki" and pass it to
3655 format_type_warning.
3656 (deref_n_times): New function.
3657 (get_modifier_for_format_len): New function.
3658 (selftest::test_get_modifier_for_format_len): New function.
3659 (get_format_for_type): New function.
3660 (format_type_warning): Add param "fki" and use it to attempt
3661 to provide hints for argument types when calling
3662 format_warning_at_substring.
3663 (selftest::get_info): New function.
3664 (selftest::assert_format_for_type_streq): New function.
3665 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
3666 (selftest::test_get_format_for_type_printf): New function.
3667 (selftest::test_get_format_for_type_scanf): New function.
3668 (selftest::c_format_c_tests): New function.
3669
3670 2016-08-08 David Malcolm <dmalcolm@redhat.com>
3671
3672 PR c/52952
3673 * c-format.c: Include "diagnostic.h".
3674 (location_column_from_byte_offset): Delete.
3675 (location_from_offset): Delete.
3676 (format_warning_va): New function.
3677 (format_warning_at_substring): New function.
3678 (format_warning_at_char): New function.
3679 (check_format_arg): Capture location of format_tree and pass to
3680 check_format_info_main.
3681 (argument_parser): Add fields "start_of_this_format" and
3682 "format_string_cst".
3683 (flag_chars_t::validate): Add param "format_string_cst". Convert
3684 warning_at call using location_from_offset to call to
3685 format_warning_at_char.
3686 (argument_parser::argument_parser): Add param "format_string_cst_"
3687 and use use it to initialize field "format_string_cst".
3688 Initialize new field "start_of_this_format".
3689 (argument_parser::read_format_flags): Convert warning_at call
3690 using location_from_offset to a call to format_warning_at_char.
3691 (argument_parser::read_any_format_left_precision): Likewise.
3692 (argument_parser::read_any_format_precision): Likewise.
3693 (argument_parser::read_any_other_modifier): Likewise.
3694 (argument_parser::find_format_char_info): Likewise, in three places.
3695 (argument_parser::parse_any_scan_set): Likewise, in one place.
3696 (argument_parser::handle_conversions): Likewise, in two places.
3697 (argument_parser::check_argument_type): Add param "fmt_param_loc"
3698 and use it to make a substring_loc. Pass the latter to
3699 check_format_types.
3700 (check_format_info_main): Add params "fmt_param_loc" and
3701 "format_string_cst". Convert warning_at calls using
3702 location_from_offset to calls to format_warning_at_char. Pass the
3703 new params to the arg_parser ctor. Pass "format_string_cst" to
3704 flag_chars.validate. Pass "fmt_param_loc" to
3705 arg_parser.check_argument_type.
3706 (check_format_types): Convert first param from a location_t
3707 to a const substring_loc & and rename to "fmt_loc". Attempt
3708 to extract the range of the relevant parameter and pass it
3709 to format_type_warning.
3710 (format_type_warning): Convert first param from a location_t
3711 to a const substring_loc & and rename to "fmt_loc". Add
3712 params "param_range" and "type". Replace calls to warning_at
3713 with calls to format_warning_at_substring.
3714
3715 2016-08-08 David Malcolm <dmalcolm@redhat.com>
3716
3717 * c-format.c (class flag_chars_t): New class.
3718 (struct length_modifier): New struct.
3719 (class argument_parser): New class.
3720 (flag_chars_t::flag_chars_t): New ctor.
3721 (flag_chars_t::has_char_p): New method.
3722 (flag_chars_t::add_char): New method.
3723 (flag_chars_t::validate): New method.
3724 (flag_chars_t::get_alloc_flag): New method.
3725 (flag_chars_t::assignment_suppression_p): New method.
3726 (argument_parser::argument_parser): New ctor.
3727 (argument_parser::read_any_dollar): New method.
3728 (argument_parser::read_format_flags): New method.
3729 (argument_parser::read_any_format_width): New method.
3730 (argument_parser::read_any_format_left_precision): New method.
3731 (argument_parser::read_any_format_precision): New method.
3732 (argument_parser::handle_alloc_chars): New method.
3733 (argument_parser::read_any_length_modifier): New method.
3734 (argument_parser::read_any_other_modifier): New method.
3735 (argument_parser::find_format_char_info): New method.
3736 (argument_parser::validate_flag_pairs): New method.
3737 (argument_parser::give_y2k_warnings): New method.
3738 (argument_parser::parse_any_scan_set): New method.
3739 (argument_parser::handle_conversions): New method.
3740 (argument_parser::check_argument_type): New method.
3741 (check_format_info_main): Introduce classes argument_parser
3742 and flag_chars_t, moving the code within the loop into methods
3743 of these classes. Make various locals "const".
3744
3745 2016-08-05 David Malcolm <dmalcolm@redhat.com>
3746
3747 * c-common.c: Include "substring-locations.h".
3748 (get_cpp_ttype_from_string_type): New function.
3749 (g_string_concat_db): New global.
3750 (substring_loc::get_range): New method.
3751 * c-common.h (g_string_concat_db): New declaration.
3752 (class substring_loc): New class.
3753 * c-lex.c (lex_string): When concatenating strings, capture the
3754 locations of all tokens using a new obstack, and record the
3755 concatenation locations within g_string_concat_db.
3756 * c-opts.c (c_common_init_options): Construct g_string_concat_db
3757 on the ggc-heap.
3758
3759 2016-07-29 Marek Polacek <polacek@redhat.com>
3760
3761 PR c/71926
3762 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
3763 parentheses warning.
3764
3765 PR c/71574
3766 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
3767
3768 2016-07-28 Martin Liska <mliska@suse.cz>
3769
3770 PR gcov-profile/68025
3771 * c-common.c (handle_no_profile_instrument_function_attribute):
3772
3773 2016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
3774
3775 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
3776 BITS_PER_UNIT_LOG.
3777
3778 2016-07-25 Jason Merrill <jason@redhat.com>
3779
3780 PR c++/65970
3781 * c.opt (fconstexpr-loop-limit): New.
3782
3783 2016-07-22 Martin Sebor <msebor@redhat.com>
3784
3785 PR c++/71675
3786 * c-common.c (resolve_overloaded_builtin): Avoid converting
3787 __atomic_compare_exchange_n return type to that of what its
3788 first argument points to.
3789
3790 2016-07-22 Uros Bizjak <ubizjak@gmail.com>
3791
3792 * c-common.c: Use HOST_WIDE_INT_M1U instead of
3793 ~(unsigned HOST_WIDE_INT) 0.
3794
3795 2016-07-22 Martin Liska <mliska@suse.cz>
3796
3797 PR gcov-profile/69028
3798 PR gcov-profile/62047
3799 * cilk.c (create_cilk_helper_decl): Set location of a new decl
3800 to the current_function_decl.
3801
3802 2016-07-21 Jason Merrill <jason@redhat.com>
3803
3804 PR c++/65168
3805 * c-common.c (c_common_truthvalue_conversion): Check
3806 c_inhibit_evaluation_warnings for warning about address of
3807 reference.
3808
3809 2016-07-20 David Malcolm <dmalcolm@redhat.com>
3810
3811 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
3812 const char *.
3813
3814 2016-07-15 Jason Merrill <jason@redhat.com>
3815
3816 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
3817
3818 2016-07-15 Jakub Jelinek <jakub@redhat.com>
3819
3820 PR c/71858
3821 * c-common.h (enum lookup_name_fuzzy_kind): Add
3822 FUZZY_LOOKUP_FUNCTION_NAME.
3823
3824 2016-07-08 Jason Merrill <jason@redhat.com>
3825
3826 P0145: Refining Expression Order for C++.
3827 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
3828 * c-opts.c: Adjust.
3829
3830 2016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
3831
3832 PR c++/71214
3833 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
3834
3835 2016-06-29 Thomas Schwinge <thomas@codesourcery.com>
3836
3837 * c-pragma.h (enum pragma_kind): Rename
3838 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
3839 users.
3840
3841 2016-06-29 Richard Biener <rguenther@suse.de>
3842
3843 PR middle-end/71002
3844 * c-common.c (c_common_get_alias_set): Remove union type punning case.
3845
3846 2016-06-24 Jason Merrill <jason@redhat.com>
3847
3848 P0145R2: Refining Expression Order for C++.
3849 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
3850 MODIFY_EXPR.
3851
3852 2016-06-24 Jakub Jelinek <jakub@redhat.com>
3853
3854 * c-common.c (check_builtin_function_arguments): Require last
3855 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
3856 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
3857 if the last argument is pointer to enumerated or boolean type.
3858
3859 2016-06-22 David Malcolm <dmalcolm@redhat.com>
3860
3861 PR c/70339
3862 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
3863 (lookup_name_fuzzy): New prototype.
3864
3865 2016-06-21 John David Anglin <danglin@gcc.gnu.org>
3866
3867 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
3868
3869 2016-06-14 Jason Merrill <jason@redhat.com>
3870
3871 P0145R2: Refining Expression Order for C++.
3872 * c.opt (fargs-in-order): New.
3873 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
3874
3875 2016-06-13 Jakub Jelinek <jakub@redhat.com>
3876
3877 PR sanitizer/71498
3878 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
3879 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
3880
3881 PR preprocessor/71183
3882 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
3883 to cb_get_source_date_epoch.
3884
3885 2016-06-10 Jakub Jelinek <jakub@redhat.com>
3886
3887 PR c/68657
3888 * c.opt (Wpsabi): Add Warning flag.
3889
3890 2016-06-10 Martin Sebor <msebor@redhat.com>
3891
3892 PR c/71392
3893 * c-common.c (handle_nonnull_attribute): Accept
3894 the nonnull attribute in type-generic builtins.
3895
3896 2016-06-09 Martin Sebor <msebor@redhat.com>
3897
3898 PR c/70883
3899 * c-common.c (builtin_function_validate_nargs): Make text of error
3900 message consistent with others like it.
3901
3902 2016-06-08 Martin Sebor <msebor@redhat.com>
3903 Jakub Jelinek <jakub@redhat.com>
3904
3905 PR c++/70507
3906 PR c/68120
3907 * c-common.c (check_builtin_function_arguments): Handle
3908 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
3909
3910 2016-06-08 Richard Biener <rguenther@suse.de>
3911
3912 * c-common.c (parse_optimize_options): Improve diagnostic messages.
3913
3914 2016-06-07 Richard Biener <rguenther@suse.de>
3915
3916 PR c/61564
3917 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
3918 options and warn about others.
3919
3920 2016-06-01 Eduard Sanou <dhole@openmailbox.org>
3921
3922 * c-common.c (get_source_date_epoch): Rename to
3923 cb_get_source_date_epoch.
3924 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
3925 message when the parsing fails. Use error_at instead of fatal_error.
3926 * c-common.h (get_source_date_epoch): Rename to
3927 cb_get_source_date_epoch.
3928 * c-common.h (cb_get_source_date_epoch): Prototype.
3929 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
3930 * c-common.h (c_omp_region_type): Remove trailing comma.
3931 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
3932 * c-lex.c (c_lex_with_flags): Remove initialization of
3933 pfile->source_date_epoch.
3934
3935 2016-05-30 Jakub Jelinek <jakub@redhat.com>
3936
3937 PR c++/71349
3938 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
3939 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
3940 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
3941 instead of C_OMP_CLAUSE_SPLIT_FOR.
3942
3943 2016-05-24 Richard Biener <rguenther@suse.de>
3944
3945 PR middle-end/70434
3946 PR c/69504
3947 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
3948 (convert_vector_to_array_for_subscript): ... this.
3949 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
3950 VIEW_CONVERT_EXPR to an array type. Rename to ...
3951 (convert_vector_to_array_for_subscript): ... this.
3952
3953 2016-05-12 Marek Polacek <polacek@redhat.com>
3954
3955 PR c/70756
3956 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
3957 size_in_bytes and pass LOC to it.
3958
3959 2016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
3960
3961 PR c/43651
3962 * c.opt (Wduplicate-decl-specifier): New option.
3963
3964 2016-05-11 Marek Polacek <polacek@redhat.com>
3965
3966 PR c++/71024
3967 * c-common.c (diagnose_mismatched_attributes): New function.
3968 * c-common.h (diagnose_mismatched_attributes): Declare.
3969
3970 2016-05-04 Marek Polacek <polacek@redhat.com>
3971
3972 * c.opt (Wdangling-else): New option.
3973
3974 2016-05-03 Marek Polacek <polacek@redhat.com>
3975
3976 PR c/70859
3977 * c-common.c (builtin_function_validate_nargs): Add location
3978 parameter. Use it.
3979 (check_builtin_function_arguments): Add location and arguments
3980 parameters. Use them.
3981 * c-common.h (check_builtin_function_arguments): Update declaration.
3982
3983 2016-05-03 Richard Biener <rguenther@suse.de>
3984
3985 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
3986 allow call args to gimplify to SSA names.
3987
3988 2016-05-03 Marek Polacek <polacek@redhat.com>
3989
3990 * c-common.h (enum c_omp_region_type): Remove stray comma.
3991
3992 2016-05-02 Cesar Philippidis <cesar@codesourcery.com>
3993
3994 * c-common.h (enum c_omp_region_type): Define.
3995
3996 2016-05-02 Richard Sandiford <richard.sandiford@arm.com>
3997
3998 * c-common.c (shorten_compare): Use wi::to_wide.
3999
4000 2016-04-29 Cesar Philippidis <cesar@codesourcery.com>
4001
4002 PR middle-end/70626
4003 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
4004 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
4005 reduction clauses in acc parallel loops.
4006
4007 2016-04-29 Marek Polacek <polacek@redhat.com>
4008
4009 PR c/70852
4010 * c-common.c (warn_for_memset): Check domain before accessing it.
4011
4012 2016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
4013
4014 PR/69089
4015 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
4016 "aligned" attribute.
4017
4018 2016-04-28 Jason Merrill <jason@redhat.com>
4019
4020 * c-lex.c (c_common_has_attribute): Handle nodiscard.
4021
4022 2016-04-28 Eduard Sanou <dhole@openmailbox.org>
4023 Matthias Klose <doko@debian.org>
4024
4025 * c-common.c (get_source_date_epoch): New function, gets the environment
4026 variable SOURCE_DATE_EPOCH and parses it as long long with error
4027 handling.
4028 * c-common.h (get_source_date_epoch): Prototype.
4029 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
4030
4031 2015-04-27 Ryan Burn <contact@rnburn.com>
4032
4033 PR c++/69024
4034 PR c++/68997
4035 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
4036 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
4037 external linkage.
4038 (cilk_detect_and_unwrap): Corresponding changes.
4039 (extract_free_variables): Don't extract free variables from
4040 AGGR_INIT_EXPR slot.
4041 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
4042 (cilk_recognize_spawn): Likewise.
4043
4044 2016-04-27 Bernd Schmidt <bschmidt@redhat.com>
4045
4046 * c.opt (Wmemset-elt-size): New option.
4047 * c-common.c (warn_for_memset): New function.
4048 * c-common.h (warn_for_memset): Declare.
4049
4050 2016-04-25 Jason Merrill <jason@redhat.com>
4051
4052 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
4053 No longer static.
4054 * c-common.h: Declare it.
4055 * c-lex.c (c_common_has_attribute): Add maybe_unused.
4056
4057 2016-04-22 Jason Merrill <jason@redhat.com>
4058
4059 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
4060
4061 2016-04-20 Ilya Verbin <ilya.verbin@intel.com>
4062
4063 PR c++/69363
4064 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
4065 * c-common.h (c_finish_cilk_clauses): Remove declaration.
4066
4067 2016-04-18 Michael Matz <matz@suse.de>
4068
4069 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
4070 and SET_DECL_ALIGN.
4071
4072 2016-04-17 Eric Botcazou <ebotcazou@adacore.com>
4073
4074 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
4075 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
4076 to incomplete types.
4077 (dump_nested_type): Remove redundant tests and tidy up.
4078 (print_ada_declaration): Also set TREE_VISITED on the declaration of
4079 a type which is the typedef of an original type.
4080
4081 2016-04-15 Marek Polacek <polacek@redhat.com>
4082
4083 PR c/70651
4084 * c-common.c (build_va_arg): Change two asserts into errors and return
4085 error_mark_node.
4086
4087 2016-04-13 Marek Polacek <polacek@redhat.com>
4088
4089 PR c++/70639
4090 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
4091 for switch statements, too.
4092
4093 2016-03-28 Jason Merrill <jason@redhat.com>
4094
4095 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
4096
4097 2016-03-23 Marek Polacek <polacek@redhat.com>
4098
4099 PR c++/69884
4100 * c.opt (Wignored-attributes): New option.
4101
4102 2016-03-22 David Malcolm <dmalcolm@redhat.com>
4103
4104 PR c/69993
4105 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
4106 diagnostic text, reversing the order of the warning and note so
4107 that they appear in source order.
4108
4109 2016-03-17 Marek Polacek <polacek@redhat.com>
4110
4111 PR c/69407
4112 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
4113 operations.
4114
4115 2016-03-14 Jason Merrill <jason@redhat.com>
4116
4117 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
4118
4119 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
4120
4121 2016-03-09 Richard Biener <rguenther@suse.de>
4122
4123 PR c/70143
4124 * c-common.c (strict_aliasing_warning): Add back
4125 alias_sets_conflict_p check.
4126
4127 2016-03-08 Jason Merrill <jason@redhat.com>
4128
4129 * c-opts.c (set_std_cxx1z): Don't enable concepts.
4130
4131 2016-03-04 David Malcolm <dmalcolm@redhat.com>
4132
4133 PR c/68187
4134 * c-indentation.c (get_visual_column): Move code to determine next
4135 tab stop to...
4136 (next_tab_stop): ...this new function.
4137 (line_contains_hash_if): Delete function.
4138 (detect_preprocessor_logic): Delete function.
4139 (get_first_nws_vis_column): New function.
4140 (detect_intervening_unindent): New function.
4141 (should_warn_for_misleading_indentation): Replace call to
4142 detect_preprocessor_logic with a call to
4143 detect_intervening_unindent.
4144
4145 2016-03-04 David Malcolm <dmalcolm@redhat.com>
4146
4147 PR c/68187
4148 * c-indentation.c (should_warn_for_misleading_indentation): When
4149 suppressing warnings about cases where the guard and body are on
4150 the same column, only use the first non-whitespace column in place
4151 of the guard token column when dealing with "else" clauses.
4152 When rejecting aligned BODY and NEXT, loosen the requirement
4153 from equality with the first non-whitespace of guard to simply
4154 that they not be indented relative to it.
4155
4156 2016-03-04 Richard Biener <rguenther@suse.de>
4157
4158 PR c++/70054
4159 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
4160 instead of alias_sets_conflict_p.
4161
4162 2016-03-01 Marek Polacek <polacek@redhat.com>
4163
4164 PR c++/69795
4165 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
4166 any DECL.
4167
4168 2016-02-22 Martin Sebor <msebor@redhat.com>
4169
4170 PR middle-end/69780
4171 * c-common.c (check_builtin_function_arguments): Validate and
4172 reject invalid arguments to __builtin_alloca_with_align.
4173
4174 2016-02-20 Mark Wielaard <mjw@redhat.com>
4175
4176 PR c/28901
4177 * c.opt (Wunused-const-variable): Turn into Alias for...
4178 (Wunused-const-variable=): New option.
4179
4180 2016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
4181
4182 PR c++/69865
4183 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
4184 here...
4185 (c_common_init_options): ...to here.
4186 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
4187
4188 2016-02-19 Jakub Jelinek <jakub@redhat.com>
4189
4190 PR c++/69826
4191 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
4192 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
4193 flag_preprocess_only.
4194
4195 2016-02-16 Jakub Jelinek <jakub@redhat.com>
4196
4197 PR c/69835
4198 * c.opt (Wnonnull-compare): Enable for -Wall.
4199
4200 2016-02-15 Jakub Jelinek <jakub@redhat.com>
4201
4202 PR c++/69797
4203 * c-common.c (sync_resolve_size): Diagnose too few arguments
4204 even when params is non-NULL empty vector.
4205
4206 2016-02-08 Bernd Schmidt <bschmidt@redhat.com>
4207
4208 PR target/60410
4209 * c.opt (fshort-double): Remove.
4210
4211 2016-02-05 Martin Sebor <msebor@redhat.com>
4212
4213 PR c++/69662
4214 * c.opt (Warning options): Update -Wplacement-new to take
4215 an optional argument.
4216
4217 2016-02-01 Jakub Jelinek <jakub@redhat.com>
4218
4219 PR preprocessor/69543
4220 PR c/69558
4221 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
4222 instead of loc to control_warning_option.
4223
4224 2016-02-01 Nathan Sidwell <nathan@codesourcery.com>
4225
4226 * c.opt (fopenacc-dim=): New option.
4227
4228 2016-01-27 Ryan Burn <contact@rnburn.com>
4229
4230 PR cilkplus/69267
4231 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
4232 gimplify_arg. Removed superfluous post_p argument.
4233 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
4234 superfluous post_p argument.
4235 * c-gimplify.c (c_gimplify_expr): Likewise.
4236
4237 2016-01-26 David Malcolm <dmalcolm@redhat.com>
4238
4239 PR other/69006
4240 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
4241 pp_newline_and_flush with pp_flush.
4242
4243 2016-01-20 Martin Sebor <msebor@redhat.com>
4244
4245 PR c/69405
4246 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
4247 an incompatible argument when the argument isn't a valid tree node.
4248
4249 2016-01-18 Jason Merrill <jason@redhat.com>
4250
4251 PR c++/68767
4252 * c-common.c (check_function_arguments_recurse): Fold the whole
4253 COND_EXPR, not just the condition.
4254
4255 2016-01-18 Tom de Vries <tom@codesourcery.com>
4256
4257 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
4258 classify as loop clause.
4259
4260 2016-01-15 Jakub Jelinek <jakub@redhat.com>
4261
4262 PR bootstrap/68271
4263 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
4264 C++ FE no longer has limit on number of pragmas.
4265
4266 2015-01-14 Ryan Burn <contact@rnburn.com>
4267
4268 PR c++/69048
4269 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
4270 to add missing cleanup point.
4271
4272 2016-01-14 David Malcolm <dmalcolm@redhat.com>
4273
4274 PR c++/68819
4275 * c-indentation.c (get_visual_column): Add location_t param.
4276 Handle the column number being zero by effectively disabling the
4277 warning, with an "inform".
4278 (should_warn_for_misleading_indentation): Add location_t argument
4279 for all uses of get_visual_column.
4280
4281 2016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
4282
4283 PR c++/69029
4284 * c-indentation.c (should_warn_for_misleading_indentation):
4285 Don't warn about do-while statements.
4286
4287 2016-01-07 Martin Sebor <msebor@redhat.com>
4288
4289 PR c/68966
4290 * c-common.c (sync_resolve_size): Reject first argument when it's
4291 a pointer to _Bool.
4292
4293 2016-01-05 David Malcolm <dmalcolm@redhat.com>
4294
4295 PR c/69122
4296 * c-indentation.c (get_visual_column): Remove default argument.
4297 (should_warn_for_misleading_indentation): For the multiline case,
4298 update call to get_visual_column for next_stmt_exploc so that it
4299 captures the location of the first non-whitespace character in the
4300 relevant line. Don't issue warnings if there is non-whitespace
4301 before the next statement.
4302
4303 2016-01-04 Jakub Jelinek <jakub@redhat.com>
4304
4305 Update copyright years.
4306
4307 2015-12-21 David Malcolm <dmalcolm@redhat.com>
4308
4309 * c-common.c (binary_op_error): Convert first param from
4310 location_t to rich_location * and use it when emitting an error.
4311 * c-common.h (binary_op_error): Convert first param from
4312 location_t to rich_location *.
4313
4314 2015-12-16 David Malcolm <dmalcolm@redhat.com>
4315
4316 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
4317 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
4318
4319 2015-12-15 Ilya Verbin <ilya.verbin@intel.com>
4320
4321 * c-common.c (c_common_attribute_table): Handle "omp declare target
4322 link" attribute.
4323
4324 2015-12-14 Jakub Jelinek <jakub@redhat.com>
4325
4326 PR c/68833
4327 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
4328
4329 2014-12-12 Tobias Burnus <burnus@net-b.de>
4330
4331 PR fortran/68815
4332 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
4333 specifiers (%d, %i,%u and %c).
4334
4335 2015-12-10 David Malcolm <dmalcolm@redhat.com>
4336
4337 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
4338
4339 2015-12-08 Jakub Jelinek <jakub@redhat.com>
4340
4341 PR c/48088
4342 PR c/68657
4343 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
4344 * c-pragma.c (handle_pragma_diagnostic): Adjust
4345 control_warning_option caller.
4346
4347 2015-12-07 David Malcolm <dmalcolm@redhat.com>
4348
4349 * c-common.c (c_cpp_error): Update for change to
4350 rich_location::set_range.
4351
4352 2015-12-04 Paolo Bonzini <bonzini@gnu.org>
4353
4354 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
4355 shifting 1 out of the sign bit.
4356
4357 2015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
4358
4359 * c-common.c (c_common_attribute_table[]): Update max arguments
4360 count for "simd" attribute.
4361 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
4362
4363 2015-12-03 Jakub Jelinek <jakub@redhat.com>
4364
4365 PR preprocessor/57580
4366 * c-ppoutput.c (print): Change printed field to bool.
4367 Move src_file last for smaller padding.
4368 (init_pp_output): Set print.printed to false instead of 0.
4369 (scan_translation_unit): Fix up formatting. Set print.printed
4370 to true after printing something other than newline.
4371 (scan_translation_unit_trad): Set print.printed to true instead of 1.
4372 (maybe_print_line_1): Set print.printed to false instead of 0.
4373 (print_line_1): Likewise.
4374 (do_line_change): Set print.printed to true instead of 1.
4375 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
4376 dump_macro): Set print.printed to false after printing newline.
4377
4378 2015-12-02 Jason Merrill <jason@redhat.com>
4379
4380 * c-common.c (fold_for_warn): New.
4381 (warn_logical_operator, warn_tautological_cmp)
4382 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
4383
4384 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
4385 (c_fully_fold_internal, decl_constant_value_for_optimization):
4386 Move to c/c-fold.c.
4387 * c-common.h: Don't declare decl_constant_value_for_optimization.
4388
4389 2015-12-02 Joseph Myers <joseph@codesourcery.com>
4390
4391 PR c/68162
4392 * c-common.h (c_build_qualified_type): Add extra default
4393 arguments.
4394
4395 2015-12-01 Julian Brown <julian@codesourcery.com>
4396 Cesar Philippidis <cesar@codesourcery.com>
4397 James Norris <James_Norris@mentor.com>
4398
4399 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
4400 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
4401 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
4402
4403 2015-11-30 Eric Botcazou <ebotcazou@adacore.com>
4404
4405 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
4406 (decl_sloc_common): Delete and move bulk of processing to...
4407 (decl_sloc): ...here.
4408 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
4409 (dump_ada_double_name): Remove S parameter and compute the suffix.
4410 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
4411 element type and deal with an anonymous one.
4412 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
4413 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
4414 and remove reference to QUAL_UNION_TYPE.
4415 (dump_nested_types): Make 2 passes on the fields and move bulk to...
4416 (dump_nested_type): ...here. New function extracted from above.
4417 Generate a full declaration for anonymous element type of arrays.
4418 (print_ada_declaration): Really skip anonymous declarations. Remove
4419 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
4420 Clean up processing of declarations of array types and objects.
4421 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
4422 Remove obsolete code and tidy up.
4423
4424 2015-11-29 Jan Hubicka <hubicka@ucw.cz>
4425
4426 PR c/67581
4427 * c-common.c (handle_transparent_union_attribute): Update
4428 also type variants.
4429
4430 2015-11-27 Martin Liska <mliska@suse.cz>
4431
4432 PR c++/68312
4433 * array-notation-common.c (cilkplus_extract_an_triplets):
4434 Release vector of vectors.
4435 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
4436
4437 2015-11-26 Eric Botcazou <ebotcazou@adacore.com>
4438
4439 PR c++/68527
4440 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
4441 (print_ada_struct_decl): Likewise.
4442
4443 2015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
4444
4445 PR c++/68001
4446 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
4447 * cilk.c (recognize_spawn): Determine location in a more precise
4448 way.
4449
4450 2015-11-19 Jason Merrill <jason@redhat.com>
4451
4452 * c-common.c (shorten_compare): But look through macros from
4453 system headers.
4454
4455 2015-11-18 Jason Merrill <jason@redhat.com>
4456
4457 * c-common.c (shorten_compare): Don't -Wtype-limits if the
4458 non-constant operand comes from a macro.
4459
4460 2015-11-17 Jason Merrill <jason@redhat.com>
4461
4462 PR bootstrap/68346
4463 * c-common.c (warn_tautological_cmp): Fold before checking for
4464 constants.
4465
4466 2015-11-16 Marek Polacek <polacek@redhat.com>
4467
4468 PR c++/68362
4469 * c-common.c (check_case_bounds): Fold low and high cases.
4470
4471 2015-11-16 Marek Polacek <polacek@redhat.com>
4472
4473 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
4474 * c-common.c (c_common_get_alias_set): Likewise.
4475 (handle_visibility_attribute): Likewise.
4476
4477 2015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
4478
4479 * c-common.c (handle_simd_attribute): New.
4480 (struct attribute_spec): Add entry for "simd".
4481 (handle_simd_attribute): New.
4482
4483 2015-11-13 Kai Tietz <ktietz70@googlemail.com>
4484
4485 * c-lex.c (interpret_float): Use fold_convert.
4486
4487 2015-11-13 David Malcolm <dmalcolm@redhat.com>
4488
4489 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
4490 and store it on the result.
4491 * c-opts.c (c_common_init_options): Set
4492 global_dc->colorize_source_p.
4493
4494 2015-11-12 James Norris <jnorris@codesourcery.com>
4495 Joseph Myers <joseph@codesourcery.com>
4496
4497 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
4498 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
4499 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
4500 PRAGMA_OACC_CLAUSE_LINK.
4501
4502 2015-11-11 Marek Polacek <polacek@redhat.com>
4503
4504 PR c/68107
4505 PR c++/68266
4506 * c-common.c (valid_array_size_p): New function.
4507 * c-common.h (valid_array_size_p): Declare.
4508
4509 2015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4510
4511 PR bootstrap/68271
4512 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
4513
4514 2015-11-11 Andrew MacLeod <amacleod@redhat.com>
4515
4516 * array-notation-common.c: Remove unused header files.
4517 * c-ada-spec.c: Likewise.
4518 * c-cilkplus.c: Likewise.
4519 * c-common.c: Likewise.
4520 * c-cppbuiltin.c: Likewise.
4521 * c-dump.c: Likewise.
4522 * c-format.c: Likewise.
4523 * c-gimplify.c: Likewise.
4524 * c-indentation.c: Likewise.
4525 * c-lex.c: Likewise.
4526 * c-omp.c: Likewise.
4527 * c-opts.c: Likewise.
4528 * c-pch.c: Likewise.
4529 * c-ppoutput.c: Likewise.
4530 * c-pragma.c: Likewise.
4531 * c-pretty-print.c: Likewise.
4532 * c-semantics.c: Likewise.
4533 * c-ubsan.c: Likewise.
4534 * cilk.c: Likewise.
4535 * stub-objc.c: Likewise.
4536
4537 2015-11-09 Thomas Schwinge <thomas@codesourcery.com>
4538 Cesar Philippidis <cesar@codesourcery.com>
4539 James Norris <jnorris@codesourcery.com>
4540 Julian Brown <julian@codesourcery.com>
4541 Nathan Sidwell <nathan@codesourcery.com>
4542
4543 * c-pragma.c (oacc_pragmas): Add "routine".
4544 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
4545
4546 2015-11-08 Eric Botcazou <ebotcazou@adacore.com>
4547
4548 * c-common.c (c_common_attributes): Add scalar_storage_order.
4549 (handle_scalar_storage_order_attribute): New function.
4550 * c-pragma.c (global_sso): New variable.
4551 (maybe_apply_pragma_scalar_storage_order): New function.
4552 (handle_pragma_scalar_storage_order): Likewise.
4553 (init_pragma): Register scalar_storage_order.
4554 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
4555 * c.opt (Wscalar-storage-order): New warning.
4556 (fsso-struct=): New option.
4557
4558 2015-11-08 Martin Sebor <msebor@redhat.com>
4559
4560 * c.opt (Wplacement-new): Add a period to the end of a sentence.
4561
4562 2015-11-07 Richard Sandiford <richard.sandiford@arm.com>
4563
4564 * c-common.c: Don't undef DEF_BUILTIN.
4565
4566 2015-11-06 David Malcolm <dmalcolm@redhat.com>
4567
4568 * c-common.c (c_cpp_error): Convert parameter from location_t to
4569 rich_location *. Eliminate the "column_override" parameter and
4570 the call to diagnostic_override_column.
4571 Update the "done_lexing" clause to set range 0
4572 on the rich_location, rather than overwriting a location_t.
4573 * c-common.h (c_cpp_error): Convert parameter from location_t to
4574 rich_location *. Eliminate the "column_override" parameter.
4575
4576 2015-11-05 Cesar Philippidis <cesar@codesourcery.com>
4577 Thomas Schwinge <thomas@codesourcery.com>
4578 James Norris <jnorris@codesourcery.com>
4579
4580 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
4581 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
4582 clauses with parallel and kernels and loops.
4583 * c-pragma.h (enum pragma_omp_clause): Add entries for
4584 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
4585 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
4586 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
4587 INDEPENDENT,SEQ}.
4588 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
4589
4590 2015-11-05 Martin Sebor <msebor@redhat.com>
4591
4592 PR c++/67942
4593 * c.opt (-Wplacement-new): New option.
4594
4595 2015-11-05 Jakub Jelinek <jakub@redhat.com>
4596
4597 * c-common.h (c_finish_omp_atomic): Add TEST argument.
4598 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
4599 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
4600 save_expr or create_tmp_var* if TEST is true.
4601 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
4602 Don't call add_stmt here.
4603 (struct c_omp_check_loop_iv_data): New type.
4604 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
4605 c_omp_check_loop_iv_exprs): New functions.
4606 (c_omp_split_clauses): Adjust for lastprivate being allowed on
4607 distribute.
4608 (c_omp_declare_simd_clauses_to_numbers): Change
4609 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
4610 (c_omp_declare_simd_clauses_to_decls): Similarly change those
4611 from numbers to PARM_DECLs.
4612
4613 2015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
4614
4615 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
4616 flag_checking.
4617
4618 2015-11-03 Bernd Schmidt <bschmidt@redhat.com>
4619
4620 PR c++-common/67882
4621 * c-common.h (fold_offsetof_1): Add argument.
4622 * c-common.c (fold_offsetof_1): Diagnose more invalid
4623 offsetof expressions that reference elements past the end of
4624 an array.
4625
4626 2015-11-03 Thomas Schwinge <thomas@codesourcery.com>
4627 Chung-Lin Tang <cltang@codesourcery.com>
4628
4629 * c-pragma.c (oacc_pragmas): Add "atomic".
4630 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
4631
4632 2015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
4633
4634 * c-common.c (handle_target_clones_attribute): New.
4635 (c_common_attribute_table): Add handle_target_clones_attribute.
4636 (handle_always_inline_attribute): Add check on target_clones attribute.
4637 (handle_target_attribute): Ditto.
4638
4639 2015-10-29 Andrew MacLeod <amacleod@redhat.com>
4640
4641 * array-notation-common.c: Reorder #include's and remove duplicates.
4642 * c-ada-spec.c: Likewise.
4643 * c-cilkplus.c: Likewise.
4644 * c-common.c: Likewise.
4645 * c-cppbuiltin.c: Likewise.
4646 * c-dump.c: Likewise.
4647 * c-format.c: Likewise.
4648 * c-gimplify.c: Likewise.
4649 * c-indentation.c: Likewise.
4650 * c-lex.c: Likewise.
4651 * c-omp.c: Likewise.
4652 * c-opts.c: Likewise.
4653 * c-pch.c: Likewise.
4654 * c-ppoutput.c: Likewise.
4655 * c-pragma.c: Likewise.
4656 * c-pretty-print.c: Likewise.
4657 * c-semantics.c: Likewise.
4658 * c-ubsan.c: Likewise.
4659 * cilk.c: Likewise.
4660 * stub-objc.c: Likewise.
4661
4662 2015-10-28 Jason Merrill <jason@redhat.com>
4663
4664 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
4665
4666 2015-10-27 Thomas Schwinge <thomas@codesourcery.com>
4667 James Norris <jnorris@codesourcery.com>
4668 Cesar Philippidis <cesar@codesourcery.com>
4669
4670 PR c/64765
4671 PR c/64880
4672 * c-common.h (c_oacc_split_loop_clauses): Declare function.
4673 * c-omp.c (c_oacc_split_loop_clauses): New function.
4674
4675 2015-10-21 Martin Sebor <msebor@redhat.com>
4676
4677 PR driver/68043
4678 * c.opt: End each sentence that describes an option with a period.
4679
4680 2015-10-20 Marek Polacek <polacek@redhat.com>
4681
4682 * array-notation-common.c (is_cilkplus_vector_p): Define.
4683 * c-common.h (is_cilkplus_vector_p): Declare.
4684
4685 2015-10-20 Marek Polacek <polacek@redhat.com>
4686
4687 * c.opt (std=gnu++11): Do not describe as experimental.
4688 (std=gnu++14): Likewise.
4689
4690 2015-10-19 Jason Merrill <jason@redhat.com>
4691
4692 * c-cppbuiltin.c (c_cpp_builtins): Define
4693 __cpp_nontype_template_args.
4694
4695 2015-10-19 Jason Merrill <jason@redhat.com>
4696
4697 * c-cppbuiltin.c (c_cpp_builtins): Define
4698 __cpp_enumerator_attributes, __cpp_fold_expressions,
4699 __cpp_unicode_characters.
4700
4701 2015-10-13 Jakub Jelinek <jakub@redhat.com>
4702 Aldy Hernandez <aldyh@redhat.com>
4703
4704 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
4705 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
4706 (c_define_builtins): Likewise.
4707 * c-common.h (enum c_omp_clause_split): Add
4708 C_OMP_CLAUSE_SPLIT_TASKLOOP.
4709 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
4710 (c_finish_omp_for): Add ORIG_DECLV argument.
4711 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
4712 201511 instead of 201307.
4713 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
4714 OMP_CRITICAL_CLAUSES to it.
4715 (c_finish_omp_ordered): Add CLAUSES argument, set
4716 OMP_ORDERED_CLAUSES to it.
4717 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
4718 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
4719 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
4720 constructs and new OpenMP 4.5 clauses. Clear
4721 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
4722 verification code.
4723 * c-pragma.c (omp_pragmas_simd): Add taskloop.
4724 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
4725 (enum pragma_omp_clause): Add
4726 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
4727 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
4728
4729 2015-10-05 Richard Sandiford <richard.sandiford@arm.com>
4730
4731 * c-lex.c (interpret_float): Use real_equal instead of
4732 REAL_VALUES_EQUAL.
4733
4734 2015-10-04 Jason Merrill <jason@redhat.com>
4735
4736 Implement N4514, C++ Extensions for Transactional Memory.
4737 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
4738 (c_common_attribute_table): Add transaction_safe_dynamic.
4739 transaction_safe now affects type identity.
4740 (handle_tm_attribute): Handle transaction_safe_dynamic.
4741 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
4742 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
4743 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
4744 (D_TRANSMEM): New.
4745 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
4746 * c-pretty-print.c (pp_c_attributes_display): Don't print
4747 transaction_safe in C++.
4748
4749 2015-10-02 Marek Polacek <polacek@redhat.com>
4750
4751 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
4752
4753 2015-10-02 Marek Polacek <polacek@redhat.com>
4754
4755 PR c/64249
4756 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
4757 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
4758 * c.opt (Wduplicated-cond): New option.
4759
4760 2015-10-01 Joseph Myers <joseph@codesourcery.com>
4761
4762 * c.opt (std=c11): Do not describe as experimental.
4763 (std=gnu11): Likewise.
4764 (std=iso9899:2011): Likewise.
4765
4766 2015-09-28 Nathan Sidwell <nathan@codesourcery.com>
4767
4768 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
4769 (DEF_FUNCTION_TYPE_VAR_11): Delete.
4770
4771 2015-09-25 Marek Polacek <polacek@redhat.com>
4772
4773 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
4774 (ubsan_instrument_shift): Likewise.
4775
4776 2015-09-25 Marek Polacek <polacek@redhat.com>
4777
4778 PR sanitizer/64906
4779 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
4780
4781 2015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
4782
4783 * c-indentation.c (should_warn_for_misleading_indentation):
4784 Compare next_stmt_vis_column with guard_line_first_nws instead
4785 of with guard_line_vis_column.
4786
4787 2015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
4788
4789 PR c/49654
4790 PR c/49655
4791 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
4792 options and options not valid for the current language.
4793
4794 2015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
4795
4796 * c-indentation.c (should_warn_for_misleading_indentation):
4797 Float out and consolidate the calls to get_visual_column that
4798 are passed guard_exploc as an argument. Compare
4799 next_stmt_vis_column with guard_line_first_nws instead of with
4800 body_line_first_nws.
4801
4802 2015-09-22 Nathan Sidwell <nathan@codesourcery.com>
4803
4804 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
4805 Wnamespaces): New C++ warnings.
4806
4807 2015-09-22 Jason Merrill <jason@redhat.com>
4808
4809 * c-common.h (abi_compat_version_crosses): New.
4810 (warn_abi_version): Declare.
4811 * c-common.c: Define it.
4812 * c-opts.c (c_common_post_options): Handle it.
4813 flag_abi_compat_version defaults to 8.
4814
4815 2015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
4816
4817 Complete the implementation of N4230, Nested namespace definition.
4818 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
4819 __cpp_nested_namespace_definitions.
4820
4821 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
4822
4823 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
4824
4825 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
4826
4827 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
4828 when warning.
4829 * c-pragma.h (pragma_lex): Add optional loc argument.
4830
4831 2015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
4832
4833 * c-format.c (check_format_arg): Adjust to use common block size in all
4834 object pools.
4835
4836 2015-09-15 David Malcolm <dmalcolm@redhat.com>
4837
4838 * c-format.c (location_from_offset): Update for change in
4839 signature of location_get_source_line.
4840 * c-indentation.c (get_visual_column): Likewise.
4841 (line_contains_hash_if): Likewise.
4842
4843 2015-09-14 Marek Polacek <polacek@redhat.com>
4844
4845 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
4846 setting various warnings.
4847
4848 2015-09-14 Marek Polacek <polacek@redhat.com>
4849
4850 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
4851 a negative value.
4852
4853 2015-09-11 Mark Wielaard <mjw@redhat.com>
4854
4855 PR c/28901
4856 * c.opt (Wunused-variable): Option from common.opt.
4857 (Wunused-const-variable): New option.
4858
4859 2015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
4860
4861 PR c++/53184
4862 * c.opt ([Wsubobject-linkage]): Add.
4863
4864 2015-09-03 Martin Sebor <msebor@redhat.com>
4865
4866 PR c/66516
4867 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
4868 functions.
4869 * c-common.c (reject_gcc_builtin): Define.
4870
4871 2015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
4872
4873 PR middle-end/60586
4874 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
4875 prototype.
4876 * c-gimplify.c (c_gimplify_expr): Added a call to the function
4877 cilk_gimplify_call_params_in_spawned_fn.
4878 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
4879 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
4880 unwrapping.
4881
4882 2015-08-25 Marek Polacek <polacek@redhat.com>
4883
4884 PR middle-end/67330
4885 * c-common.c (handle_weak_attribute): Don't check whether the
4886 visibility can be changed here.
4887
4888 2015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
4889
4890 * c-lex.c (c_lex_with_flags): Use explicit locations.
4891
4892 2015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
4893
4894 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
4895 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
4896
4897 2015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
4898
4899 PR middle-end/36757
4900 * c-common.c (check_builtin_function_arguments): Add check
4901 for BUILT_IN_SIGNBIT argument.
4902
4903 2015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
4904
4905 PR c++/67160
4906 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
4907 in c++1z mode.
4908
4909 2015-08-17 Marek Polacek <polacek@redhat.com>
4910
4911 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
4912 with whitespaces before qualifier names.
4913
4914 2015-08-12 Marek Polacek <polacek@redhat.com>
4915
4916 PR c++/55095
4917 * c-common.c (maybe_warn_shift_overflow): Properly handle
4918 left-shifting 1 into the sign bit.
4919
4920 2015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
4921
4922 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
4923
4924 2015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
4925 Braden Obrzut <admin@maniacsvault.net>
4926 Jason Merrill <jason@redhat.com>
4927
4928 Add C++ Concepts TS support.
4929 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
4930 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
4931 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
4932 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
4933 * c-opts.c (set_std_cxx1z): Set flag_concepts.
4934 * c.opt (fconcepts): New.
4935
4936 2015-08-02 Martin Sebor <msebor@redhat.com>
4937
4938 * c.opt (-Wframe-address): New warning option.
4939
4940 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
4941
4942 * c-indentation.c (should_warn_for_misleading_indentation):
4943 Improve heuristics.
4944
4945 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
4946
4947 * c-indentation.c (get_visual_column): Add parameter first_nws,
4948 use it. Update comment documenting the function.
4949 (is_first_nonwhitespace_on_line): Remove.
4950 (should_warn_for_misleading_indentation): Replace usage of
4951 of is_first_nonwhitespace_on_line with get_visual_column.
4952
4953 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
4954
4955 * c-indentation.h (struct token_indent_info): Define.
4956 (get_token_indent_info): Define.
4957 (warn_for_misleading_information): Declare.
4958 * c-common.h (warn_for_misleading_information): Remove.
4959 * c-identation.c (warn_for_misleading_indentation):
4960 Change declaration to take three token_indent_infos. Adjust
4961 accordingly.
4962 * c-identation.c (should_warn_for_misleading_indentation):
4963 Likewise. Bail out early if the body is a compound statement.
4964 (guard_tinfo_to_string): Define.
4965
4966 2015-07-30 Jason Merrill <jason@redhat.com>
4967
4968 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
4969 '*' for reference decay.
4970
4971 2015-07-30 Marek Polacek <polacek@redhat.com>
4972
4973 * c-common.c (warn_tautological_cmp): Bail for float types.
4974
4975 2015-07-27 Marek Polacek <polacek@redhat.com>
4976
4977 PR bootstrap/67030
4978 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
4979
4980 2015-07-27 Marek Polacek <polacek@redhat.com>
4981
4982 PR c++/66555
4983 PR c/54979
4984 * c-common.c (find_array_ref_with_const_idx_r): New function.
4985 (warn_tautological_cmp): New function.
4986 * c-common.h (warn_tautological_cmp): Declare.
4987 * c.opt (Wtautological-compare): New option.
4988
4989 2015-07-23 Marek Polacek <polacek@redhat.com>
4990
4991 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
4992 (ubsan_instrument_shift): Likewise.
4993
4994 2015-07-23 Marek Polacek <polacek@redhat.com>
4995
4996 PR sanitizer/66908
4997 * c-ubsan.c: Include gimplify.h.
4998 (ubsan_instrument_division): Unshare OP0 and OP1.
4999 (ubsan_instrument_shift): Likewise.
5000
5001 2015-07-20 Marek Polacek <polacek@redhat.com>
5002 Richard Sandiford <richard.sandiford@arm.com>
5003
5004 PR c++/55095
5005 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
5006 Use EXPR_LOC_OR_LOC.
5007 (maybe_warn_shift_overflow): New function.
5008 * c-common.h (maybe_warn_shift_overflow): Declare.
5009 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
5010 * c.opt (Wshift-overflow): New option.
5011
5012 2015-07-16 Martin Liska <mliska@suse.cz>
5013
5014 * c-format.c (static void check_format_info_main): Use
5015 object_allocator instead of pool_allocator.
5016 (check_format_arg): Likewise.
5017 (check_format_info_main): Likewise.
5018
5019 2015-07-15 Andrew MacLeod <amacleod@redhat.com>
5020
5021 * c-opts.c: Remove multiline #include comment.
5022
5023 2015-07-12 Aldy Hernandez <aldyh@redhat.com>
5024
5025 * c-common.c: Fix double word typos.
5026
5027 2015-07-10 Eric Botcazou <ebotcazou@adacore.com>
5028
5029 * c-ada-spec.h (cpp_operation): Revert latest change.
5030 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
5031 constructors and destructors.
5032
5033 2015-07-09 Andrew MacLeod <amacleod@redhat.com>
5034
5035 * c-common.h: Adjust includes for flags.h changes.
5036 * stub-objc.c: Likewise.
5037
5038 2015-07-08 Eric Botcazou <ebotcazou@adacore.com>
5039
5040 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
5041 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
5042
5043 2015-07-08 Jakub Jelinek <jakub@redhat.com>
5044
5045 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
5046 are to be removed, return NULL rather than original clauses list.
5047
5048 2015-07-07 Andrew MacLeod <amacleod@redhat.com>
5049
5050 * array-notation-common.c: Adjust includes.
5051 * c-ada-spec.c: Likewise.
5052 * c-cilkplus.c: Likewise.
5053 * c-common.h: Likewise.
5054 * c-cppbuiltin.c: Likewise.
5055 * c-dump.c: Likewise.
5056 * c-format.c: Likewise.
5057 * c-gimplify.c: Likewise.
5058 * c-indentation.c: Likewise.
5059 * c-lex.c: Likewise.
5060 * c-omp.c: Likewise.
5061 * c-opts.c: Likewise.
5062 * c-pch.c: Likewise.
5063 * c-ppoutput.c: Likewise.
5064 * c-pragma.c: Likewise.
5065 * c-pretty-print.c: Likewise.
5066 * c-semantics.c: Likewise.
5067 * c-ubsan.c: Likewise.
5068 * cilk.c: Likewise.
5069 * stub-objc.c: Likewise.
5070
5071 2015-07-07 Eric Botcazou <ebotcazou@adacore.com>
5072
5073 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
5074 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
5075
5076 2015-07-01 Jason Merrill <jason@redhat.com>
5077
5078 * c-common.h (D_CXX11): Rename from D_CXX0X.
5079 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
5080 * c-common.c: Adjust.
5081
5082 * c-opts.c (c_common_post_options): Default to C++14.
5083
5084 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
5085
5086 2015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
5087
5088 Implement N4197 - Adding u8 character literals
5089 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
5090 CPP_CHAR.
5091 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
5092 CPP_UTF8CHAR_USERDEF tokens.
5093 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
5094 and CPP_UTF8CHAR tokens.
5095 (lex_charconst): Treat CPP_UTF8CHAR token.
5096
5097 2015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
5098
5099 PR fortran/66605
5100 * c-common.c (do_warn_unused_parameter): Move here.
5101 * c-common.h (do_warn_unused_parameter): Declare.
5102
5103 2015-06-29 Marek Polacek <polacek@redhat.com>
5104
5105 PR c/66322
5106 * c-common.c (check_case_bounds): Add bool * parameter. Set
5107 OUTSIDE_RANGE_P.
5108 (c_add_case_label): Add bool * parameter. Pass it down to
5109 check_case_bounds.
5110 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
5111 warning here.
5112 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
5113 declarations.
5114
5115 2015-06-27 Marek Polacek <polacek@redhat.com>
5116
5117 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
5118 or VECTOR_INTEGER_TYPE_P throughout.
5119 * c-gimplify.c: Likewise.
5120
5121 2015-06-26 Marek Polacek <polacek@redhat.com>
5122
5123 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
5124 * c-common.c (c_fully_fold_internal): Likewise.
5125 (c_alignof_expr): Likewise.
5126 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
5127 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
5128 * cilk.c (create_parm_list): Likewise.
5129
5130 2015-06-26 Marek Polacek <polacek@redhat.com>
5131
5132 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
5133
5134 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
5135
5136 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
5137 * c-gimplify.c: Likewise.
5138 * c-pragma.c: Likewise.
5139 * c-ubsan.c: Likewise.
5140 * cilk.c: Likewise.
5141
5142 2015-06-25 Richard Sandiford <richard.sandiford@arm.com>
5143
5144 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
5145 ggc_hasher.
5146
5147 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
5148
5149 * cilk.c: Move calls.h after tm.h in the include chain.
5150
5151 2015-06-25 Marek Polacek <polacek@redhat.com>
5152
5153 * array-notation-common.c: Use VAR_P throughout.
5154 * c-ada-spec.c: Likewise.
5155 * c-common.c: Likewise.
5156 * c-format.c: Likewise.
5157 * c-gimplify.c: Likewise.
5158 * c-omp.c: Likewise.
5159 * c-pragma.c: Likewise.
5160 * c-pretty-print.c: Likewise.
5161 * cilk.c: Likewise.
5162
5163 2015-06-25 Marek Polacek <polacek@redhat.com>
5164
5165 * cilk.c (extract_free_variables): Use is_global_var.
5166
5167 2015-06-23 Richard Sandiford <richard.sandiford@arm.com>
5168
5169 * c-common.c: Don't include target-def.h.
5170
5171 2015-06-23 Marek Polacek <polacek@redhat.com>
5172
5173 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
5174 when comparing INTEGER_CSTs.
5175
5176 2015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
5177
5178 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
5179 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
5180 (dump_ada_template): Skip partially specialized types.
5181
5182 2015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
5183
5184 * c-common.c (scalar_to_vector): Use std::swap instead of manually
5185 swapping.
5186
5187 2015-06-17 Andrew MacLeod <amacleod@redhat.com>
5188
5189 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
5190 * c-ada-spec.c: Likewise.
5191 * c-cilkplus.c: Likewise.
5192 * c-common.c: Likewise.
5193 * c-common.h: Likewise.
5194 * c-cppbuiltin.c: Likewise.
5195 * c-dump.c: Likewise.
5196 * c-format.c: Likewise.
5197 * c-gimplify.c: Likewise.
5198 * c-indentation.c: Likewise.
5199 * c-lex.c: Likewise.
5200 * c-omp.c: Likewise.
5201 * c-opts.c: Likewise.
5202 * c-pch.c: Likewise.
5203 * c-ppoutput.c: Likewise.
5204 * c-pragma.c: Likewise.
5205 * c-pretty-print.c: Likewise.
5206 * c-semantics.c: Likewise.
5207 * c-ubsan.c: Likewise.
5208 * cilk.c: Likewise.
5209 * stub-objc.c: Likewise.
5210
5211 2015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
5212
5213 PR c++/65168
5214 * c-common.c (c_common_truthvalue_conversion): Warn when
5215 converting an address of a reference to a truth value.
5216
5217 2015-06-08 Andrew MacLeod <amacleod@redhat.com>
5218
5219 * array-notation-common.c : Adjust include files.
5220 * c-ada-spec.c : Likewise.
5221 * c-cilkplus.c : Likewise.
5222 * c-common.c : Likewise.
5223 * c-common.h : Likewise.
5224 * c-cppbuiltin.c : Likewise.
5225 * c-dump.c : Likewise.
5226 * c-format.c : Likewise.
5227 * c-gimplify.c : Likewise.
5228 * c-indentation.c : Likewise.
5229 * c-lex.c : Likewise.
5230 * c-omp.c : Likewise.
5231 * c-opts.c : Likewise.
5232 * c-pch.c : Likewise.
5233 * c-ppoutput.c : Likewise.
5234 * c-pragma.c : Likewise.
5235 * c-pretty-print.c : Likewise.
5236 * c-semantics.c : Likewise.
5237 * c-ubsan.c : Likewise.
5238 * cilk.c : Likewise.
5239 * stub-objc.c : Likewise.
5240
5241 2015-06-08 Marek Polacek <polacek@redhat.com>
5242
5243 PR c/66415
5244 * c-format.c (location_from_offset): Return LOC if LINE is null.
5245
5246 2015-06-05 Aldy Hernandez <aldyh@redhat.com>
5247
5248 * c-common.h (c_parse_final_cleanups): New prototype.
5249 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
5250
5251 2015-06-04 Sriraman Tallam <tmsriram@google.com>
5252
5253 * c-common.c (noplt): New attribute.
5254 (handle_noplt_attribute): New handler.
5255
5256 2015-06-04 Andrew MacLeod <amacleod@redhat.com>
5257
5258 * array-notation-common.c: Adjust includes for restructured coretypes.h.
5259 * c-ada-spec.c: Likewise.
5260 * c-cilkplus.c: Likewise.
5261 * c-common.c: Likewise.
5262 * c-common.h: Likewise.
5263 * c-cppbuiltin.c: Likewise.
5264 * c-dump.c: Likewise.
5265 * c-format.c: Likewise.
5266 * c-gimplify.c: Likewise.
5267 * c-indentation.c: Likewise.
5268 * c-lex.c: Likewise.
5269 * c-omp.c: Likewise.
5270 * c-opts.c: Likewise.
5271 * c-pch.c: Likewise.
5272 * c-ppoutput.c: Likewise.
5273 * c-pragma.c: Likewise.
5274 * c-pretty-print.c: Likewise.
5275 * c-semantics.c: Likewise.
5276 * c-ubsan.c: Likewise.
5277 * cilk.c: Likewise.
5278 * stub-objc.c: Likewise.
5279
5280 2015-06-02 David Malcolm <dmalcolm@redhat.com>
5281
5282 PR c/66220:
5283 * c-indentation.c (should_warn_for_misleading_indentation): Use
5284 expand_location rather than expand_location_to_spelling_point.
5285 Don't warn if the guarding statement is more indented than the
5286 next/body stmts.
5287
5288 2015-06-02 David Malcolm <dmalcolm@redhat.com>
5289
5290 * c-indentation.c (warn_for_misleading_indentation): Bail out
5291 immediately if -Wmisleading-indentation isn't enabled.
5292
5293 2015-06-01 Martin Liska <mliska@suse.cz>
5294
5295 * c-format.c (check_format_arg):Use new type-based pool allocator.
5296 (check_format_info_main) Likewise.
5297
5298 2015-05-31 Eric Botcazou <ebotcazou@adacore.com>
5299
5300 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
5301 (has_nontrivial_methods): Likewise.
5302
5303 2015-05-25 Marek Polacek <polacek@redhat.com>
5304
5305 * c-ubsan.c (ubsan_instrument_shift): Use type0.
5306
5307 2015-05-22 Marek Polacek <polacek@redhat.com>
5308
5309 PR c/47043
5310 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
5311
5312 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
5313
5314 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
5315 STACK_GROWS_DOWNWARD.
5316
5317 2015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
5318
5319 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
5320 STACK_GROWS_DOWNWARD rather than if it is defined.
5321
5322 2015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
5323
5324 PR c/52952
5325 * c-format.c (location_column_from_byte_offset): New.
5326 (location_from_offset): New.
5327 (struct format_wanted_type): Add offset_loc field.
5328 (check_format_info): Move handling of location for extra arguments
5329 closer to the point of warning.
5330 (check_format_info_main): Pass the result of location_from_offset
5331 to warning_at.
5332 (format_type_warning): Pass the result of location_from_offset
5333 to warning_at.
5334
5335 2015-05-20 Marek Polacek <polacek@redhat.com>
5336
5337 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
5338
5339 2015-05-20 Marek Polacek <polacek@redhat.com>
5340
5341 * c-ada-spec.c (dump_sloc): Use DECL_P.
5342
5343 2015-05-20 Marek Polacek <polacek@redhat.com>
5344
5345 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
5346 * c-common.c: Likewise.
5347
5348 2015-05-19 David Malcolm <dmalcolm@redhat.com>
5349
5350 * c-common.h (fe_file_change): Strengthen param from
5351 const line_map * to const line_map_ordinary *.
5352 (pp_file_change): Likewise.
5353 * c-lex.c (fe_file_change): Likewise.
5354 (cb_define): Use linemap_check_ordinary when invoking
5355 SOURCE_LINE.
5356 (cb_undef): Likewise.
5357 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
5358 invoking cb_file_change.
5359 (c_finish_options): Likewise.
5360 (push_command_line_include): Likewise.
5361 (cb_file_change): Strengthen param "new_map" from
5362 const line_map * to const line_map_ordinary *.
5363 * c-ppoutput.c (cb_define): Likewise for local "map".
5364 (pp_file_change): Likewise for param "map" and local "from".
5365
5366 2015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
5367
5368 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
5369
5370 2015-05-18 Tom de Vries <tom@codesourcery.com>
5371
5372 * c-common.c (build_va_arg_1): New function.
5373 (build_va_arg): Add address operator to va_list operand if necessary.
5374
5375 2015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
5376
5377 PR c/48956
5378 * c-common.c (int_safely_convertible_to_real_p): Define.
5379 (unsafe_conversion_p): Check conversions involving complex types.
5380 (conversion_warning): Add new warning message for conversions which
5381 discard imaginary component.
5382 * c-common.h: (enum conversion_safety): Add new enumerator for such
5383 conversions.
5384
5385 2015-05-14 Marek Polacek <polacek@redhat.com>
5386
5387 PR c/66066
5388 PR c/66127
5389 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
5390 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
5391 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
5392 use it. If FOR_INT_CONST, require that all evaluated operands be
5393 INTEGER_CSTs.
5394
5395 2015-05-12 David Malcolm <dmalcolm@redhat.com>
5396
5397 * c-common.h (warn_for_misleading_indentation): New prototype.
5398 * c-indentation.c: New file.
5399 * c.opt (Wmisleading-indentation): New option.
5400
5401 2015-05-12 Tom de Vries <tom@codesourcery.com>
5402
5403 PR tree-optimization/66010
5404 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
5405
5406 2015-05-09 Jason Merrill <jason@redhat.com>
5407
5408 * c-opts.c (c_common_post_options): Also clear
5409 cpp_opts->cpp_warn_cxx11_compat.
5410
5411 * c-common.h (enum cxx_dialect): Add cxx_unset.
5412 * c-common.c (cxx_dialect): Initialize to cxx_unset.
5413 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
5414
5415 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
5416 (std=gnu++0x): Mark as Undocumented.
5417 (std=gnu++1y): Add deprecated message.
5418
5419 2015-05-08 Jason Merrill <jason@redhat.com>
5420
5421 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
5422 * c-opts.c: Adjust.
5423
5424 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
5425
5426 2015-05-08 Marek Polacek <polacek@redhat.com>
5427
5428 PR c/64918
5429 * c.opt (Woverride-init-side-effects): New option.
5430
5431 2015-05-07 Marek Polacek <polacek@redhat.com>
5432
5433 PR c/65179
5434 * c-common.c (c_fully_fold_internal): Warn when left shifting a
5435 negative value.
5436 * c.opt (Wshift-negative-value): New option.
5437 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
5438 when -Wextra and C99/C++11 mode.
5439
5440 2015-05-07 Marek Polacek <polacek@redhat.com>
5441 Martin Uecker <uecker@eecs.berkeley.edu>
5442
5443 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
5444 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
5445
5446 2015-05-05 Jason Merrill <jason@redhat.com>
5447
5448 * c.opt (Wterminate): New.
5449
5450 2015-04-30 Marek Polacek <polacek@redhat.com>
5451
5452 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
5453 require that the non-constant be of a boolean type.
5454
5455 2015-04-29 Josh Triplett <josh@joshtriplett.org>
5456
5457 * c-common.c (handle_section_attribute): Refactor to reduce
5458 nesting and distinguish between error cases.
5459
5460 2015-04-29 Marek Polacek <polacek@redhat.com>
5461
5462 PR c/64610
5463 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
5464 with 0/1.
5465
5466 2015-04-29 Jakub Jelinek <jakub@redhat.com>
5467
5468 * c-common.h (omp_clause_mask): Unconditionally define as a class.
5469 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
5470 HOST_BITS_PER_WIDE_INT.
5471
5472 2015-04-28 Tom de Vries <tom@codesourcery.com>
5473
5474 PR tree-optimization/65887
5475 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
5476
5477 2015-04-28 Eric Botcazou <ebotcazou@adacore.com>
5478 Pierre-Marie de Rodat <derodat@adacore.com>
5479
5480 * c-ada-spec.c (in_function): Delete.
5481 (dump_generic_ada_node): Do not change in_function and remove the
5482 redundant code dealing with it.
5483 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
5484 (print_ada_methods): Output the static member functions in a nested
5485 package after the regular methods as well as associated renamings.
5486
5487 2015-04-24 Marek Polacek <polacek@redhat.com>
5488
5489 PR c/65830
5490 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
5491 and OPT_Wshift_count_overflow.
5492
5493 PR c/63357
5494 * c-common.c (warn_logical_operator): Warn if the operands have the
5495 same expressions.
5496
5497 2015-04-24 Marek Polacek <polacek@redhat.com>
5498
5499 PR c/61534
5500 * c-common.c (warn_logical_operator): Bail if either operand comes
5501 from a macro expansion.
5502
5503 2015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
5504
5505 PR target/55143
5506 * c-common.c (c_default_pointer_mode): Add definition.
5507 * c-common.h (c_default_pointer_mode): Add declaration.
5508
5509 2015-03-11 Jakub Jelinek <jakub@redhat.com>
5510
5511 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
5512 on record_builtin_type argument.
5513
5514 2015-03-10 Jakub Jelinek <jakub@redhat.com>
5515
5516 PR c/65120
5517 * c-common.c (warn_logical_not_parentheses): Don't warn for
5518 !x == 0 or !x != 0.
5519
5520 2015-03-07 Marek Polacek <polacek@redhat.com>
5521
5522 PR sanitizer/65280
5523 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
5524 before trying to figure out whether we have a flexible array member.
5525
5526 2015-03-06 Eric Botcazou <ebotcazou@adacore.com>
5527 Jonathan Wakely <jwakely.gcc@gmail.com>
5528
5529 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
5530
5531 2015-03-05 Eric Botcazou <ebotcazou@adacore.com>
5532
5533 PR ada/65319
5534 * c-ada-spec.c (print_destructor): Remove obsolete code.
5535
5536 2015-03-01 Eric Botcazou <ebotcazou@adacore.com>
5537
5538 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
5539 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
5540 DECL_TEMPLATE_RESULT emulations.
5541 (dump_ada_template)): Add guard for TYPE_METHODS.
5542
5543 2015-02-27 Marek Polacek <polacek@redhat.com>
5544
5545 PR c/65040
5546 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
5547
5548 2015-02-27 Kai Tietz <ktietz@redhat.com>
5549
5550 PR c/35330
5551 * c-pragma.c (handle_pragma_weak): Do not try to create
5552 weak/alias of declarations not being function, or variable
5553 declarations.
5554
5555 2015-02-24 Thomas Schwinge <thomas@codesourcery.com>
5556
5557 PR libgomp/64625
5558 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
5559 Remove macros.
5560 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
5561
5562 2015-02-16 Marek Polacek <polacek@redhat.com>
5563
5564 PR c/65066
5565 * c-format.c (check_format_types): Handle null param.
5566
5567 2015-02-13 Marek Polacek <polacek@redhat.com>
5568
5569 PR c/65040
5570 * c-format.c (check_format_types): Don't warn about different
5571 signedness if the original value is in the range of WANTED_TYPE.
5572
5573 2015-02-12 Jason Merrill <jason@redhat.com>
5574
5575 PR c++/64956
5576 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
5577 to the current highest version.
5578 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
5579
5580 2015-02-04 Jakub Jelinek <jakub@redhat.com>
5581
5582 PR c/64824
5583 PR c/64868
5584 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
5585 instead of RDIV_EXPR. Use build_binary_op instead of
5586 build2_loc.
5587
5588 2015-01-30 Joseph Myers <joseph@codesourcery.com>
5589
5590 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
5591 to pass input_location as first argument.
5592
5593 2015-01-23 Tom de Vries <tom@codesourcery.com>
5594
5595 PR libgomp/64672
5596 * c.opt (fopenacc): Mark as LTO option.
5597
5598 2015-01-23 Tom de Vries <tom@codesourcery.com>
5599
5600 PR libgomp/64707
5601 * c.opt (fopenmp): Mark as LTO option.
5602
5603 2015-01-21 Jakub Jelinek <jakub@redhat.com>
5604
5605 PR c/63307
5606 * cilk.c (fill_decls_vec): Only put decls into vector v.
5607 (compare_decls): Fix up formatting.
5608
5609 2015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
5610
5611 PR c/63307
5612 * cilk.c: Include vec.h.
5613 (struct cilk_decls): New structure.
5614 (wrapper_parm_cb): Split this function to...
5615 (fill_decls_vec): ...this...
5616 (create_parm_list): ...and this.
5617 (compare_decls): New function.
5618 (for_local_cb): Remove.
5619 (wrapper_local_cb): Ditto.
5620 (build_wrapper_type): For now first traverse and fill vector of
5621 declarations then sort it and then deal with sorted vector.
5622 (cilk_outline): Ditto.
5623 (declare_one_free_variable): Ditto.
5624
5625 2015-01-21 Jason Merrill <jason@redhat.com>
5626
5627 PR c++/64629
5628 * c-format.c (check_format_arg): Call decl_constant_value.
5629
5630 2015-01-19 Martin Liska <mliska@suse.cz>
5631
5632 * c-common.c (handle_noicf_attribute): New function.
5633
5634 2015-01-15 Thomas Schwinge <thomas@codesourcery.com>
5635 Bernd Schmidt <bernds@codesourcery.com>
5636 James Norris <jnorris@codesourcery.com>
5637 Cesar Philippidis <cesar@codesourcery.com>
5638 Ilmir Usmanov <i.usmanov@samsung.com>
5639 Jakub Jelinek <jakub@redhat.com>
5640
5641 * c.opt (fopenacc): New option.
5642 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
5643 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
5644 New macros.
5645 * c-common.h (c_finish_oacc_wait): New prototype.
5646 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
5647 (c_finish_oacc_wait): New function.
5648 * c-pragma.c (oacc_pragmas): New variable.
5649 (c_pp_lookup_pragma, init_pragma): Handle it.
5650 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
5651 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
5652 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
5653 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
5654 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
5655 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
5656 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
5657 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
5658 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
5659 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
5660 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
5661 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
5662 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
5663 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
5664 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
5665 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
5666 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
5667 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
5668 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
5669 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
5670 PRAGMA_OACC_CLAUSE_WORKER.
5671
5672 2015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
5673
5674 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
5675 for the new option fstack-protector_explicit.
5676 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
5677 (handle_stack_protect_attribute): New function.
5678
5679 2015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
5680
5681 * c.opt: New option -Warray-bounds=.
5682
5683 2015-01-09 Michael Collison <michael.collison@linaro.org>
5684
5685 * array-notation-common.c: Include hash-set.h, machmode.h,
5686 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
5687 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
5688 * c-ada-spec.c: Ditto.
5689 * c-cilkplus.c: Ditto.
5690 * c-common.c: Include input.h due to flattening of tree.h.
5691 Define macro GCC_C_COMMON_C.
5692 * c-common.h: Flatten tree.h header files into c-common.h.
5693 Remove include of tree-core.h.
5694 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
5695 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
5696 fold-const.h, wide-int.h, and inchash.h due to
5697 flattening of tree.h.
5698 * c-dump.c: Ditto.
5699 * c-format.c: Flatten tree.h header files into c-common.h.
5700 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
5701 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
5702 fold-const.h, wide-int.h, and inchash.h due to
5703 flattening of tree.h.
5704 * c-dump.c: Include hash-set.h, machmode.h,
5705 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
5706 fold-const.h, wide-int.h, and inchash.h due to
5707 flattening of tree.h.
5708 * c-format.c: Include hash-set.h, machmode.h,
5709 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
5710 fold-const.h, wide-int.h, inchash.h and real.h due to
5711 flattening of tree.h.
5712 * c-gimplify.c: Include hash-set.h, machmode.h,
5713 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
5714 fold-const.h, wide-int.h, and inchash.h due to
5715 flattening of tree.h.
5716 * cilk.c: Ditto.
5717 * c-lex.c: Ditto.
5718 * c-omp.c: Ditto.
5719 * c-opts.c: Ditto.
5720 * c-pch.c: Ditto.
5721 * c-ppoutput.c: Ditto.
5722 * c-pragma.c: Ditto.
5723 * c-pretty-print.c: Ditto.
5724 * c-semantics.c: Ditto.
5725 * c-ubsan.c: Ditto.
5726 * stub-objc.c: Ditto.
5727
5728 2015-01-08 Jason Merrill <jason@redhat.com>
5729
5730 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
5731 do_ubsan_in_current_function.
5732 (ubsan_maybe_instrument_reference_or_call): Likewise.
5733 * c-ubsan.h: Declare it.
5734
5735 2015-01-08 Mike Stump <mikestump@comcast.net>
5736
5737 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
5738
5739 2015-01-07 Marek Polacek <polacek@redhat.com>
5740
5741 PR c/64440
5742 * c-common.c (c_fully_fold_internal): Warn for division and modulo
5743 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
5744
5745 2015-01-05 Trevor Saunders <tsaunders@mozilla.com>
5746
5747 PR c++/31397
5748 * c.opt (Wsuggest-override): New option.
5749
5750 2015-01-05 Jakub Jelinek <jakub@redhat.com>
5751
5752 Update copyright years.
5753
5754 2015-01-05 Marek Polacek <polacek@redhat.com>
5755
5756 PR c/64423
5757 * c-common.c (warn_array_subscript_with_type_char): Add location_t
5758 parameter. Use it.
5759 * c-common.h (warn_array_subscript_with_type_char): Update
5760 declaration.
5761
5762 2014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
5763
5764 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
5765 Control macro with flag_sized_deallocation.
5766
5767 2014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
5768
5769 * c.opt (Wdiscarded-array-qualifiers): New option.
5770
5771 2014-12-19 Jakub Jelinek <jakub@redhat.com>
5772
5773 PR preprocessor/63831
5774 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
5775 and __has_cpp_attribute here.
5776 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
5777 c_common_has_attribute.
5778 * c-common.h (c_common_has_attribute): New prototype.
5779 * c-lex.c (init_c_lex): Set cb->has_attribute to
5780 c_common_has_attribute instead of cb_has_attribute.
5781 (get_token_no_padding): New function.
5782 (cb_has_attribute): Renamed to ...
5783 (c_common_has_attribute): ... this. No longer static. Use
5784 get_token_no_padding, require ()s, don't build TREE_LIST
5785 unnecessarily, fix up formatting, adjust diagnostics, call
5786 init_attributes.
5787
5788 2014-12-15 Jason Merrill <jason@redhat.com>
5789
5790 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
5791 (-Wsized-deallocation): New.
5792 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
5793 to on in C++14 and up.
5794
5795 2014-12-11 Jason Merrill <jason@redhat.com>
5796
5797 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
5798
5799 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
5800 we aren't complaining about VLAs.
5801
5802 2014-12-06 Marek Polacek <polacek@redhat.com>
5803
5804 PR tree-optimization/64183
5805 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
5806 shift-expression if it is integer_type_node. Use types_compatible_p.
5807
5808 2014-11-29 Jakub Jelinek <jakub@redhat.com>
5809
5810 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
5811 last argument from create_tmp_var_raw and create_tmp_var calls.
5812 * cilk.c (gimplify_cilk_spawn): Likewise.
5813 * c-omp.c (c_finish_omp_atomic): Likewise.
5814
5815 2014-11-28 Marek Polacek <polacek@redhat.com>
5816
5817 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
5818 instead of unsigned_type_node.
5819
5820 2014-11-28 Marek Polacek <polacek@redhat.com>
5821
5822 PR c/63862
5823 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
5824 to op1_utype.
5825 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
5826 expression to unsigned_type_node.
5827
5828 2014-11-20 Mark Wielaard <mjw@redhat.com>
5829
5830 PR debug/38757
5831 * c-opts.c (set_std_c89): Set lang_hooks.name.
5832 (set_std_c99): Likewise.
5833 (set_std_c11): Likewise.
5834 (set_std_cxx98): Likewise.
5835 (set_std_cxx11): Likewise.
5836 (set_std_cxx14): Likewise.
5837 (set_std_cxx1z): Likewise.
5838
5839 2014-11-21 Jakub Jelinek <jakub@redhat.com>
5840
5841 PR target/63764
5842 * c-common.h (convert_vector_to_pointer_for_subscript): Change
5843 return type to bool.
5844 * c-common.c: Include gimple-expr.h.
5845 (convert_vector_to_pointer_for_subscript): Change return type to
5846 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
5847 and copy it into a TARGET_EXPR and use that instead of *vecp
5848 directly.
5849
5850 2014-11-19 David Malcolm <dmalcolm@redhat.com>
5851
5852 Merger of git branch "gimple-classes-v2-option-3".
5853 * ChangeLog.gimple-classes: New.
5854 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
5855 from being just a vec<gimple> to a vec<gbind *>.
5856
5857 2014-11-18 Jakub Jelinek <jakub@redhat.com>
5858
5859 PR sanitizer/63813
5860 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
5861 argument to ptype, set type to TREE_TYPE (ptype). Don't call
5862 get_pointer_alignment for non-pointers. Use ptype, or if it is
5863 reference type, corresponding pointer type, as type of kind
5864 argument.
5865 (ubsan_maybe_instrument_reference,
5866 ubsan_maybe_instrument_member_call): Adjust callers.
5867
5868 2014-11-15 Marek Polacek <polacek@redhat.com>
5869
5870 PR middle-end/63884
5871 * array-notation-common.c (is_sec_implicit_index_fn): Return false
5872 for NULL fndecl.
5873 (extract_array_notation_exprs): Return for NULL node.
5874
5875 2014-11-12 Joseph Myers <joseph@codesourcery.com>
5876
5877 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
5878 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
5879
5880 2014-11-12 Jakub Jelinek <jakub@redhat.com>
5881
5882 PR c/59708
5883 * c-common.c (check_builtin_function_arguments): Handle
5884 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
5885
5886 2014-11-10 Andi Kleen <ak@linux.intel.com>
5887
5888 PR c/60804
5889 * c-common.h (check_no_cilk): Declare.
5890 * cilk.c (get_error_location): New function.
5891 (check_no_cilk): Dito.
5892
5893 2014-11-10 Andi Kleen <ak@linux.intel.com>
5894
5895 * cilk.c (recognize_spawn): Use expression location
5896 for error message.
5897
5898 2014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
5899
5900 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
5901
5902 2014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
5903
5904 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
5905 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
5906 (__cpp_range_based_for, __cpp_initializer_lists,
5907 __cpp_delegating_constructors, __cpp_nsdmi,
5908 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
5909 for C++11; (__cpp_attribute_deprecated): Remove in favor of
5910 __has_cpp_attribute.
5911 * c-lex.c (cb_has_attribute): New callback CPP function;
5912 (init_c_lex): Set has_attribute callback.
5913
5914 2014-11-04 Richard Biener <rguenther@suse.de>
5915
5916 * c-common.c (shorten_compare): Do not shorten mixed
5917 DFP and non-DFP compares.
5918
5919 2014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
5920
5921 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
5922 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
5923 Commentary and rearrangement of tests.
5924 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
5925 Commentary and rearrangement of tests.
5926 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
5927 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
5928
5929 2014-10-29 Richard Sandiford <richard.sandiford@arm.com>
5930
5931 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
5932 enum from machine_mode.
5933
5934 2014-10-28 Andrew MacLeod <amacleod@redhat.com>
5935
5936 * c-common.c: Adjust include files.
5937 * c-gimplify.c: Ditto.
5938 * cilk.c: Ditto.
5939 * c-pragma.c: Ditto.
5940 * c-ubsan.c: Ditto.
5941
5942 2014-10-27 Andrew MacLeod <amacleod@redhat.com>
5943
5944 * c-gimplify.c: Adjust include files.
5945
5946 2014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
5947
5948 PR c++/53061
5949 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
5950 c_common_initialize_diagnostics.
5951 * c-common.h: Likewise.
5952
5953 2014-10-24 Marek Polacek <polacek@redhat.com>
5954
5955 PR c/56980
5956 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
5957 print "struct"/"union"/"enum" for typedefed names.
5958
5959 2014-10-23 Marek Polacek <polacek@redhat.com>
5960
5961 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
5962 in unsigned type.
5963
5964 2014-10-22 Jakub Jelinek <jakub@redhat.com>
5965 Yury Gribov <y.gribov@samsung.com>
5966
5967 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
5968 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
5969 instead of flag_sanitize_recover as bool flag.
5970
5971 2014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
5972
5973 * cilk.c: Revert previous change.
5974
5975 2014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
5976
5977 PR c/63307
5978 * cilk.c: Include vec.h.
5979 (struct cilk_decls): New structure.
5980 (wrapper_parm_cb): Split this function to...
5981 (fill_decls_vec): ...this...
5982 (create_parm_list): ...and this.
5983 (compare_decls): New function.
5984 (for_local_cb): Remove.
5985 (wrapper_local_cb): Ditto.
5986 (build_wrapper_type): For now first traverse and fill vector of
5987 declarations then sort it and then deal with sorted vector.
5988 (cilk_outline): Ditto.
5989 (declare_one_free_variable): Ditto.
5990
5991 2014-10-17 Marek Polacek <polacek@redhat.com>
5992
5993 * c-opts.c (c_common_post_options): Set warn_implicit_int.
5994 * c.opt (Wimplicit-int): Initialize to -1.
5995
5996 2014-10-16 Andrew MacLeod <amacleod@redhat.com>
5997
5998 * c-pragma.c: Adjust include files.
5999 * c-semantics.c: Likewise.
6000
6001 2014-10-16 DJ Delorie <dj@redhat.com>
6002
6003 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
6004 multiples of bytes.
6005
6006 2014-10-14 Jason Merrill <jason@redhat.com>
6007
6008 PR c++/63455
6009 * c-common.h (CPP_PREPARSED_EXPR): New.
6010 (N_CP_TTYPES): Adjust.
6011
6012 2014-10-15 Marek Polacek <polacek@redhat.com>
6013
6014 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
6015
6016 2014-10-14 DJ Delorie <dj@redhat.com>
6017
6018 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
6019 types, not just __int128.
6020 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
6021 types, not just __int128.
6022 (cpp_atomic_builtins): Round pointer sizes up.
6023 (type_suffix): Use type precision, not specific types.
6024 * c-common.c (c_common_reswords): Remove __int128 special case.
6025 (c_common_type_for_size): Check for all __intN types, not just
6026 __int128.
6027 (c_common_type_for_mode): Likewise.
6028 (c_common_signed_or_unsigned_type): Likewise.
6029 (c_build_bitfield_integer_type): Likewise.
6030 (c_common_nodes_and_builtins): Likewise.
6031 (keyword_begins_type_specifier): Likewise.
6032 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
6033 __intN variants.
6034
6035 2014-10-12 Trevor Saunders <tsaunders@mozilla.com>
6036
6037 * c-common.c: Use hash_table instead of hashtab.
6038
6039 2014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
6040
6041 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
6042 C++11 section.
6043
6044 2014-10-03 Marc Glisse <marc.glisse@inria.fr>
6045
6046 PR c++/54427
6047 PR c++/57198
6048 PR c++/58845
6049 * c-common.c (warn_logical_operator): Punt for vectors.
6050
6051 2014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
6052
6053 Implement SD-6: SG10 Feature Test Recommendations
6054 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
6055 macros and the __has_header macro.
6056
6057 2014-09-30 Jason Merrill <jason@redhat.com>
6058
6059 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
6060 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
6061 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
6062
6063 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
6064 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
6065
6066 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
6067 * c-common.c (c_common_reswords): Remove __is_convertible_to.
6068
6069 2014-09-24 Marek Polacek <polacek@redhat.com>
6070
6071 PR c/61405
6072 PR c/53874
6073 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
6074
6075 2014-09-23 Andi Kleen <ak@linux.intel.com>
6076
6077 * c-common.c (handle_no_reorder_attribute): New function.
6078 (c_common_attribute_table): Add no_reorder attribute.
6079
6080 2014-09-22 Joseph Myers <joseph@codesourcery.com>
6081
6082 * c-cppbuiltin.c (c_cpp_builtins): Define
6083 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
6084 modes.
6085
6086 2014-09-18 Joseph Myers <joseph@codesourcery.com>
6087
6088 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
6089 for supported floating-point modes.
6090
6091 2014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
6092
6093 * c.opt (Wpsabi): Use LangEnabledBy.
6094 * c-opts.c (c_common_handle_option): Do not handle here.
6095
6096 2014-09-12 Joseph Myers <joseph@codesourcery.com>
6097
6098 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
6099 macros for floating-point modes.
6100
6101 2014-09-11 Marc Glisse <marc.glisse@inria.fr>
6102
6103 PR target/58757
6104 * c-cppbuiltin.c (builtin_define_float_constants): Correct
6105 __*_DENORM_MIN__ without denormals.
6106
6107 2014-09-10 Jakub Jelinek <jakub@redhat.com>
6108
6109 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
6110 ubsan_instrument_vla, ubsan_instrument_return): Adjust
6111 ubsan_create_data callers.
6112 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
6113 index is constant or BIT_AND_EXPR with constant mask and is
6114 small enough for the bound.
6115 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
6116 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
6117
6118 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
6119
6120 * c.opt: Add CppReason to various flags.
6121 (Wdate-time): Re-sort.
6122 * c-common.c: Include c-common.h earlier.
6123 (struct reason_option_codes_t): Delete.
6124 (c_option_controlling_cpp_error): Prefix global type and struct
6125 with cpp_.
6126
6127 2014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
6128
6129 * c.opt (Wnormalized): New.
6130 (Wnormalized=): Use Enum and Reject Negative.
6131 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
6132
6133 2014-09-08 Joseph Myers <joseph@codesourcery.com>
6134
6135 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
6136 digits of floating-point modes if -fbuilding-libgcc.
6137
6138 2014-09-05 Joseph Myers <joseph@codesourcery.com>
6139
6140 * c-cppbuiltin.c (c_cpp_builtins): Also define
6141 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
6142 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
6143 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
6144 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
6145 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
6146 __LIBGCC_STACK_GROWS_DOWNWARD__,
6147 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
6148 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
6149 __LIBGCC_DWARF_FRAME_REGISTERS__,
6150 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
6151 __LIBGCC_STACK_POINTER_REGNUM__ and
6152 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
6153 (builtin_define_with_value): Handle backslash-escaping in string
6154 macro values.
6155
6156 2014-09-05 Richard Biener <rguenther@suse.de>
6157
6158 PR middle-end/63148
6159 * c-format.c (check_format_arg): Properly handle
6160 effectively signed POINTER_PLUS_EXPR offset.
6161
6162 2014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
6163
6164 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
6165 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
6166 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
6167 and Init.
6168 * c-opts.c (c_common_handle_option): Do not handle here.
6169 (sanitize_cpp_opts): Likewise.
6170 * c-common.c (struct reason_option_codes_t): Handle
6171 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
6172
6173 2014-09-03 Marek Polacek <polacek@redhat.com>
6174
6175 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
6176
6177 2014-09-02 Jakub Jelinek <jakub@redhat.com>
6178 Balaji V. Iyer <balaji.v.iyer@intel.com>
6179 Igor Zamyatin <igor.zamyatin@intel.com>
6180
6181 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
6182 * c-common.c (c_common_reswords): Added _Cilk_for.
6183 * c-common.h (enum rid): Added RID_CILK_FOR.
6184 (cilk_for_number_of_iterations): Add declaration.
6185 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
6186 CILK_FOR.
6187 * c-pragma.c (init_pragma): Register "grainsize" pragma.
6188 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
6189
6190 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
6191
6192 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
6193 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
6194 Wundef): Use CPP, Var and Init.
6195 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
6196
6197 2014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
6198
6199 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
6200 * c-opts.c (c_common_handle_option): Do not handle here.
6201
6202 2014-08-25 Jason Merrill <jason@redhat.com>
6203
6204 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
6205 -std=c++14 and -std=gnu++14, rather than the reverse.
6206 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
6207 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
6208 * c-common.h (cxx_dialect): Remove cxx1y.
6209
6210 2014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
6211
6212 * c-common.h (enum cxx_dialect): Add cxx14.
6213 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
6214 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
6215 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
6216
6217 2014-08-22 Jason Merrill <jason@redhat.com>
6218
6219 * c.opt (std=gnu++17): Fix alias.
6220
6221 2014-08-22 Marek Polacek <polacek@redhat.com>
6222
6223 PR c++/62199
6224 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
6225 check for vector types. Drop LHS argument.
6226 * c-common.h (warn_logical_not_parentheses): Adjust.
6227
6228 2014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
6229
6230 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
6231 (Wmultichar): Likewise.
6232 (Wdate-time): Use C-family languages instead of Common. Use CPP
6233 and Var.
6234 * c-opts.c (c_common_handle_option): Do not handle the above
6235 options here.
6236 (sanitize_cpp_opts): Likewise.
6237
6238 2014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
6239
6240 PR fortran/44054
6241 * c-opts.c: Include tree-diagnostics.h.
6242 (c_diagnostic_finalizer): New.
6243 (c_common_initialize_diagnostics): Use it.
6244
6245 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
6246
6247 PR preprocessor/51303
6248 * c-common.c (struct reason_option_codes_t option_codes):
6249 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
6250
6251 2014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
6252
6253 PR c/60975
6254 PR c/53063
6255 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
6256 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
6257 (c_common_post_options): Call init_global_opts_from_cpp.
6258 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
6259
6260 2014-08-19 Marek Polacek <polacek@redhat.com>
6261
6262 PR c++/62153
6263 * c-common.c (maybe_warn_bool_compare): New function.
6264 * c-common.h (maybe_warn_bool_compare): Declare.
6265 * c.opt (Wbool-compare): New option.
6266
6267 2014-08-19 Marek Polacek <polacek@redhat.com>
6268
6269 * c.opt (Wc99-c11-compat): New option.
6270
6271 2014-08-19 Marek Polacek <polacek@redhat.com>
6272
6273 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
6274 to warn_c90_c99_compat.
6275 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
6276 to -1.
6277
6278 2014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
6279 Steven Bosscher <steven@gcc.gnu.org>
6280
6281 PR c/52952
6282 * c-format.c: Add extra_arg_loc and format_string_loc to struct
6283 format_check_results.
6284 (check_function_format): Use true and add comment for boolean
6285 argument.
6286 (finish_dollar_format_checking): Use explicit location when warning.
6287 (check_format_info): Likewise.
6288 (check_format_arg): Set extra_arg_loc and format_string_loc.
6289 (check_format_info_main): Use explicit location when warning.
6290 (check_format_types): Pass explicit location.
6291 (format_type_warning): Likewise.
6292
6293 2014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
6294
6295 PR fortran/44054
6296 * c-format.c: Handle Fortran flags.
6297
6298 2014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
6299
6300 PR other/61962
6301 * array-notation-common.c (find_rank): Added handling for other
6302 types of references.
6303
6304 2014-08-10 Marek Polacek <polacek@redhat.com>
6305
6306 PR c/51849
6307 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
6308 * c.opt (Wc90-c99-compat): Add option.
6309
6310 2014-08-07 Trevor Saunders <tsaunders@mozilla.com>
6311
6312 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
6313
6314 2014-08-03 Marek Polacek <polacek@redhat.com>
6315
6316 * c-common.c (check_case_value): Add location_t parameter. Use it.
6317 (c_add_case_label): Pass loc to check_case_value.
6318
6319 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
6320
6321 * cilk.c: Use hash_map instead of pointer_map.
6322
6323 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
6324
6325 * c-gimplify.c: Use hash_set instead of pointer_set.
6326
6327 2014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
6328
6329 PR middle-end/61455
6330 * array-notation-common.c (extract_array_notation_exprs): Handling
6331 of DECL_EXPR added.
6332
6333 2014-08-01 Jakub Jelinek <jakub@redhat.com>
6334
6335 * c-common.h (min_align_of_type): Removed prototype.
6336 * c-common.c (min_align_of_type): Removed.
6337 * c-ubsan.h (ubsan_maybe_instrument_reference,
6338 ubsan_maybe_instrument_member_call): New prototypes.
6339 * c-ubsan.c: Include stor-layout.h and builtins.h.
6340 (ubsan_maybe_instrument_reference_or_call,
6341 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
6342 functions.
6343
6344 2014-07-31 Marc Glisse <marc.glisse@inria.fr>
6345
6346 PR c++/60517
6347 * c.opt (-Wreturn-local-addr): Move to common.opt.
6348
6349 2014-07-30 Jason Merrill <jason@redhat.com>
6350
6351 PR c++/61659
6352 PR c++/61687
6353 Revert:
6354 * c.opt (-fuse-all-virtuals): New.
6355
6356 2014-07-30 Tom Tromey <tromey@redhat.com>
6357
6358 PR c/59855
6359 * c.opt (Wdesignated-init): New option.
6360 * c-common.c (c_common_attribute_table): Add "designated_init".
6361 (handle_designated_init): New function.
6362
6363 2014-07-24 Marek Polacek <polacek@redhat.com>
6364
6365 PR c/57653
6366 * c-opts.c (c_finish_options): If -imacros is in effect, return.
6367
6368 2014-07-16 Dodji Seketeli <dodji@redhat.com>
6369
6370 PR preprocessor/60723 - missing system-ness marks for macro tokens
6371 * c-ppoutput.c (struct print::prev_was_system_token): New data
6372 member.
6373 (init_pp_output): Initialize it.
6374 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
6375 (do_line_change): Return a flag saying if a line marker was
6376 emitted or not.
6377 (scan_translation_unit): Detect if the system-ness of the token we
6378 are about to emit is different from the one of the previously
6379 emitted token. If so, emit a line marker. Avoid emitting useless
6380 adjacent line markers. Avoid emitting line markers for tokens
6381 originating from the expansion of built-in macros.
6382 (scan_translation_unit_directives_only): Adjust.
6383
6384 2014-07-15 Marek Polacek <polacek@redhat.com>
6385
6386 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
6387 TYPE_MAX_VALUE is NULL.
6388
6389 2014-07-14 Jakub Jelinek <jakub@redhat.com>
6390
6391 PR middle-end/61294
6392 * c.opt (Wmemset-transposed-args): New warning.
6393
6394 2014-07-10 Jason Merrill <jason@redhat.com>
6395
6396 PR c++/61659
6397 PR c++/61687
6398 * c.opt (-fuse-all-virtuals): New.
6399
6400 2014-07-09 Richard Biener <rguenther@suse.de>
6401
6402 PR c-family/61741
6403 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
6404 using unsigned arithmetic if overflow does not wrap instead of
6405 if overflow is undefined.
6406
6407 2014-07-06 Marek Polacek <polacek@redhat.com>
6408
6409 PR c/6940
6410 * c.opt (Wsizeof-array-argument): New option.
6411
6412 2014-07-03 Jakub Jelinek <jakub@redhat.com>
6413
6414 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
6415 comments->count <= 1, as comments->entries might be NULL.
6416
6417 2014-07-01 Marek Polacek <polacek@redhat.com>
6418
6419 * c.opt (Wint-conversion): New option.
6420
6421 2014-07-01 Marek Polacek <polacek@redhat.com>
6422
6423 PR c/58286
6424 * c.opt (Wincompatible-pointer-types): New option.
6425
6426 2014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
6427
6428 PR c++/51400
6429 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
6430 Do not discard TYPE_QUALS of type.
6431
6432 2014-06-26 Jason Merrill <jason@redhat.com>
6433
6434 * c-common.h (enum cxx_dialect): Add cxx1z.
6435 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
6436 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
6437
6438 2014-06-26 Teresa Johnson <tejohnson@google.com>
6439
6440 * c-common.h (get_dump_info): Declare.
6441 * c-gimplify.c (c_genericize): Use saved dump files.
6442 * c-opts.c (c_common_parse_file): Begin and end dumps
6443 once around parsing invocation.
6444 (get_dump_info): New function.
6445
6446 2014-06-23 Marek Polacek <polacek@redhat.com>
6447 Andrew MacLeod <amacleod@redhat.com>
6448
6449 PR c/61553
6450 * c-common.c (get_atomic_generic_size): Don't segfault if the
6451 type doesn't have a size.
6452
6453 2014-06-20 Marek Polacek <polacek@redhat.com>
6454
6455 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
6456 (ubsan_walk_array_refs_r): New function.
6457 (c_genericize): Instrument array bounds.
6458 * c-ubsan.c: Include "internal-fn.h".
6459 (ubsan_instrument_division): Mark instrumented arrays as having
6460 side effects. Adjust ubsan_type_descriptor call.
6461 (ubsan_instrument_shift): Likewise.
6462 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
6463 (ubsan_instrument_bounds): New function.
6464 (ubsan_array_ref_instrumented_p): New function.
6465 (ubsan_maybe_instrument_array_ref): New function.
6466 * c-ubsan.h (ubsan_instrument_bounds): Declare.
6467 (ubsan_array_ref_instrumented_p): Declare.
6468 (ubsan_maybe_instrument_array_ref): Declare.
6469
6470 2014-06-20 Hale Wang <hale.wang@arm.com>
6471
6472 PR lto/61123
6473 * c.opt (fshort-enums): Add to LTO.
6474 * c.opt (fshort-wchar): Likewise.
6475
6476 2014-06-16 Marek Polacek <polacek@redhat.com>
6477
6478 PR c/60439
6479 * c.opt (Wswitch-bool): Add Var.
6480
6481 2014-06-12 Jakub Jelinek <jakub@redhat.com>
6482
6483 PR middle-end/61486
6484 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
6485 #pragma omp target teams or
6486 #pragma omp {,target }teams distribute simd.
6487
6488 2014-06-12 Jason Merrill <jason@redhat.com>
6489
6490 * c.opt (Wabi=, fabi-compat-version): New.
6491 * c-opts.c (c_common_handle_option): Handle -Wabi=.
6492 (c_common_post_options): Handle flag_abi_compat_version default.
6493 Disallow -fabi-compat-version=1.
6494 * c-common.h (abi_version_crosses): New.
6495
6496 2014-06-11 Jan Hubicka <hubicka@ucw.cz>
6497
6498 * c-common.c (handle_section_attribute): Update handling for
6499 section names that are no longer trees.
6500
6501 2014-06-10 Jakub Jelinek <jakub@redhat.com>
6502
6503 PR fortran/60928
6504 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
6505 (omp_pragmas): ... back here.
6506
6507 2014-06-05 Marek Polacek <polacek@redhat.com>
6508
6509 PR c/49706
6510 * c-common.c (warn_logical_not_parentheses): New function.
6511 * c-common.h (warn_logical_not_parentheses): Declare.
6512 * c.opt (Wlogical-not-parentheses): New option.
6513
6514 2014-06-04 Marek Polacek <polacek@redhat.com>
6515
6516 PR c/30020
6517 * c-common.c (check_case_bounds): Add location parameter.
6518 Use it.
6519 (c_add_case_label): Pass loc to check_case_bounds.
6520
6521 2014-06-03 Marek Polacek <polacek@redhat.com>
6522
6523 PR c/60439
6524 * c.opt (Wswitch-bool): New option.
6525
6526 2014-05-22 Thomas Schwinge <thomas@codesourcery.com>
6527
6528 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
6529 Remove prototypes.
6530 (record_types_used_by_current_var_decl): Move prototype to where
6531 it belongs.
6532
6533 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
6534 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
6535 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
6536
6537 2014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
6538
6539 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
6540 * c-common.c (c_common_nodes_and_builtins): Don't initialize
6541 void_zero_node.
6542 * c-pretty-print.c (pp_c_void_constant): New function.
6543 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
6544 (c_pretty_printer::expression): Handle VOID_CST.
6545 * cilk.c (extract_free_variables): Likewise.
6546 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
6547 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
6548
6549 2014-05-17 Trevor Saunders <tsaunders@mozilla.com>
6550
6551 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
6552 * c-pragma.c (push_alignment): Adjust.
6553 (handle_pragma_push_options): Likewise.
6554
6555 2014-05-09 Marek Polacek <polacek@redhat.com>
6556
6557 PR c/50459
6558 * c-common.c (check_user_alignment): Return -1 if alignment is error
6559 node.
6560 (handle_aligned_attribute): Don't call default_conversion on
6561 FUNCTION_DECLs.
6562 (handle_vector_size_attribute): Likewise.
6563 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
6564 (handle_sentinel_attribute): Call default_conversion and allow even
6565 integral types as an argument.
6566
6567 2014-05-08 Marek Polacek <polacek@redhat.com>
6568
6569 PR c/61053
6570 * c-common.c (min_align_of_type): New function factored out from...
6571 (c_sizeof_or_alignof_type): ...here.
6572 * c-common.h (min_align_of_type): Declare.
6573
6574 2014-05-08 Marek Polacek <polacek@redhat.com>
6575
6576 PR c/61077
6577 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
6578 parameter type of main.
6579
6580 2014-05-07 DJ Delorie <dj@redhat.com>
6581
6582 * c-cppbuiltin.c (print_bits_of_hex): New.
6583 (builtin_define_type_minmax): Print values using hex so as not to
6584 require a pre-computed list of string values.
6585
6586 2014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
6587 Mike Stump <mikestump@comcast.net>
6588 Richard Sandiford <rdsandiford@googlemail.com>
6589
6590 * c-ada-spec.c: Include wide-int.h.
6591 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
6592 (dump_generic_ada_node): Use wide-int interfaces.
6593 * c-common.c: Include wide-int-print.h.
6594 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
6595 (pointer_int_sum): Use wide-int interfaces.
6596 (c_common_nodes_and_builtins): Use make_int_cst.
6597 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
6598 (handle_alloc_size_attribute): Use wide-int interfaces.
6599 (get_nonnull_operand): Likewise.
6600 * c-format.c (get_constant): Use tree_fits_uhwi_p.
6601 * c-lex.c: Include wide-int.h.
6602 (narrowest_unsigned_type): Take a widest_int rather than two
6603 HOST_WIDE_INTs.
6604 (narrowest_signed_type): Likewise.
6605 (interpret_integer): Update accordingly. Use wide-int interfaces.
6606 (lex_charconst): Use wide-int interfaces.
6607 * c-pretty-print.c: Include wide-int.h.
6608 (pp_c_integer_constant): Use wide-int interfaces.
6609 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
6610 INT_CST_LT_UNSIGNED.
6611
6612 2014-05-06 Richard Biener <rguenther@suse.de>
6613
6614 * c-opts.c (c_common_post_options): For -freestanding,
6615 -fno-hosted and -fno-builtin disable pattern recognition
6616 if not enabled explicitely.
6617
6618 2014-05-02 Marek Polacek <polacek@redhat.com>
6619
6620 * c.opt (Wsizeof-pointer-memaccess): Describe option.
6621
6622 2014-05-01 Marek Polacek <polacek@redhat.com>
6623
6624 PR c/43245
6625 * c.opt (Wdiscarded-qualifiers): Add.
6626
6627 2014-04-30 Marek Polacek <polacek@redhat.com>
6628
6629 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
6630 INT_MIN / -1 sanitization only for integer types.
6631
6632 2014-04-25 Marek Polacek <polacek@redhat.com>
6633
6634 PR c/18079
6635 * c-common.c (handle_noinline_attribute): Warn if the attribute
6636 conflicts with always_inline attribute.
6637 (handle_always_inline_attribute): Warn if the attribute conflicts
6638 with noinline attribute.
6639
6640 2014-04-25 Marek Polacek <polacek@redhat.com>
6641
6642 PR c/60156
6643 * c-common.c (check_main_parameter_types): Warn about variadic main.
6644
6645 2014-04-24 Mike Stump <mikestump@comcast.net>
6646
6647 * c.opt (Wshadow-ivar): Default to on.
6648
6649 2014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
6650
6651 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
6652
6653 2014-04-23 Marek Polacek <polacek@redhat.com>
6654
6655 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
6656
6657 2014-04-22 Jakub Jelinek <jakub@redhat.com>
6658
6659 PR sanitizer/60275
6660 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
6661 if flag_sanitize_undefined_trap_on_error.
6662 (ubsan_instrument_division, ubsan_instrument_shift,
6663 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
6664 if !flag_sanitize_recover.
6665
6666 2014-04-22 Marc Glisse <marc.glisse@inria.fr>
6667
6668 PR libstdc++/43622
6669 * c-common.c (registered_builtin_types): Make non-static.
6670 * c-common.h (registered_builtin_types): Declare.
6671
6672 2014-04-14 Richard Biener <rguenther@suse.de>
6673 Marc Glisse <marc.glisse@inria.fr>
6674
6675 PR c/60819
6676 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
6677 apply may-alias the scalar pointer type when applicable.
6678
6679 2014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
6680
6681 PR middle-end/60467
6682 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
6683 as possible argument for Cilk_spawn.
6684
6685 2014-04-11 Tobias Burnus <burnus@net-b.de>
6686
6687 PR c/60194
6688 * c.opt (Wformat-signedness): Add
6689 * c-format.c(check_format_types): Use it.
6690
6691 2014-04-11 Jason Merrill <jason@redhat.com>
6692
6693 PR c++/57926
6694 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
6695 default_conversion for an array argument.
6696
6697 2014-04-08 Marek Polacek <polacek@redhat.com>
6698
6699 PR sanitizer/60745
6700 * c-ubsan.c: Include asan.h.
6701 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
6702
6703 2014-04-03 Nathan Sidwell <nathan@codesourcery.com>
6704
6705 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
6706
6707 2014-04-02 Marek Polacek <polacek@redhat.com>
6708
6709 * c-common.h (c_expand_expr): Remove declaration.
6710
6711 2014-03-28 Jakub Jelinek <jakub@redhat.com>
6712
6713 PR c++/60689
6714 * c-common.c (add_atomic_size_parameter): When creating new
6715 params vector, push the size argument first.
6716
6717 2014-03-26 Jakub Jelinek <jakub@redhat.com>
6718
6719 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
6720 ubsan_instrument_vla, ubsan_instrument_return): Adjust
6721 ubsan_create_data callers.
6722
6723 2014-03-22 Jakub Jelinek <jakub@redhat.com>
6724
6725 PR debug/60603
6726 * c-opts.c (c_finish_options): Restore cb_file_change call to
6727 <built-in>.
6728
6729 2014-03-13 Jakub Jelinek <jakub@redhat.com>
6730
6731 PR middle-end/36282
6732 * c-pragma.c (apply_pragma_weak): Only look at
6733 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
6734 DECL_ASSEMBLER_NAME_SET_P (decl).
6735 (maybe_apply_pending_pragma_weaks): Exit early if
6736 vec_safe_is_empty (pending_weaks) rather than only when
6737 !pending_weaks.
6738 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
6739 set assembler name back to NULL afterwards.
6740
6741 2014-03-11 Jason Merrill <jason@redhat.com>
6742
6743 * c.opt: Add -std=gnu++14.
6744
6745 2014-03-11 Ian Bolton <ian.bolton@arm.com>
6746
6747 * c-opts.c (c_common_post_options): Don't override
6748 -ffp-contract=fast if unsafe-math-optimizations is on.
6749
6750 2014-03-08 Paulo Matos <paulo@matos-sorge.com>
6751
6752 * c.opt: Enable LTO FE for fshort-double.
6753
6754 2014-03-07 Jason Merrill <jason@redhat.com>
6755
6756 * c.opt: Add -std=c++14.
6757
6758 2014-03-06 Marek Polacek <polacek@redhat.com>
6759
6760 PR c/60197
6761 * cilk.c (contains_cilk_spawn_stmt): New function.
6762 (contains_cilk_spawn_stmt_walker): Likewise.
6763 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
6764 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
6765
6766 2014-03-03 Jakub Jelinek <jakub@redhat.com>
6767
6768 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
6769 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
6770 even when flag_preprocess_only.
6771
6772 2014-02-26 Jason Merrill <jason@redhat.com>
6773
6774 PR c++/59231
6775 PR c++/11586
6776 * c-common.c (shorten_compare): Don't check
6777 c_inhibit_evaluation_warnings.
6778
6779 2014-02-19 Jakub Jelinek <jakub@redhat.com>
6780
6781 PR c/37743
6782 * c-common.c (c_common_nodes_and_builtins): When initializing
6783 c_uint{16,32,64}_type_node, also set corresponding
6784 uint{16,32,64}_type_node to the same value.
6785
6786 PR c++/60267
6787 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
6788 for PRAGMA_IVDEP if flag_preprocess_only.
6789
6790 2014-02-12 Jakub Jelinek <jakub@redhat.com>
6791
6792 PR c/60101
6793 * c-common.c (merge_tlist): If copy is true, call new_tlist,
6794 if false, add ADD itself, rather than vice versa.
6795 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
6796 copy. For SAVE_EXPR, only call merge_tlist once.
6797
6798 2014-02-08 Jakub Jelinek <jakub@redhat.com>
6799
6800 PR middle-end/60092
6801 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
6802 and tree_to_uhwi.
6803 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
6804 functions.
6805 (c_common_attribute_table): Add alloc_align and assume_aligned
6806 attributes.
6807
6808 2014-02-06 Marek Polacek <polacek@redhat.com>
6809
6810 PR c/60087
6811 * c-common.c (warn_for_sign_compare): Call warning_at with location
6812 instead of warning.
6813
6814 2014-02-05 Marek Polacek <polacek@redhat.com>
6815
6816 PR c/53123
6817 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
6818 statement.
6819
6820 2014-02-04 Marek Polacek <polacek@redhat.com>
6821
6822 PR c/60036
6823 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
6824 SAVE_EXPR.
6825
6826 2014-02-03 Marc Glisse <marc.glisse@inria.fr>
6827
6828 PR c++/53017
6829 PR c++/59211
6830 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
6831 handle_vector_size_attribute, handle_nonnull_attribute): Call
6832 default_conversion on the attribute argument.
6833 (handle_nonnull_attribute): Increment the argument number.
6834
6835 2014-01-31 Marek Polacek <polacek@redhat.com>
6836
6837 PR c/59963
6838 * c-common.c (add_atomic_size_parameter): Pass vNULL to
6839 build_function_call_vec.
6840 (resolve_overloaded_builtin): Likewise.
6841 * c-common.h (build_function_call_vec): Adjust declaration.
6842
6843 2014-01-30 Marek Polacek <polacek@redhat.com>
6844
6845 PR c/59940
6846 * c-common.h (unsafe_conversion_p): Adjust declaration.
6847 (warnings_for_convert_and_check): Likewise.
6848 (convert_and_check): Likewise.
6849 * c-common.c (unsafe_conversion_p): Add location parameter. Call
6850 expansion_point_location_if_in_system_header on it.
6851 (warnings_for_convert_and_check): Add location parameter. Call
6852 expansion_point_location_if_in_system_header on it. Use it.
6853 (convert_and_check): Add location parameter. Use it.
6854 (conversion_warning): Likewise.
6855 (c_add_case_label): Adjust convert_and_check calls.
6856 (scalar_to_vector): Adjust unsafe_conversion_p calls.
6857
6858 2014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
6859
6860 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
6861 flag_cilkplus.
6862 * c-pragma.c (init_pragma): Likewise.
6863 * c.opt: Likewise.
6864
6865 2014-01-23 Marek Polacek <polacek@redhat.com>
6866
6867 PR c/59846
6868 * c-common.c (shorten_compare): Add location_t parameter.
6869 * c-common.h (shorten_binary_op): Adjust declaration.
6870
6871 2014-01-23 Marek Polacek <polacek@redhat.com>
6872
6873 PR c/58346
6874 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
6875 * c-common.h: Declare it.
6876
6877 2014-01-20 Eric Botcazou <ebotcazou@adacore.com>
6878
6879 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
6880 * c-ada-spec.c (dump_ads): Likewise.
6881 (cpp_check): Likewise.
6882 (dump_ada_specs): Likewise.
6883
6884 2014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
6885
6886 PR c++/49718
6887 * c-common.c (handle_no_instrument_function_attribute): Allow
6888 no_instrument_function attribute in class member
6889 definition/declaration.
6890
6891 2014-01-15 Jakub Jelinek <jakub@redhat.com>
6892
6893 PR c/58943
6894 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
6895 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
6896 being COMPOUND_EXPR.
6897 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
6898 operand a SAVE_EXPR and second MODIFY_EXPR.
6899
6900 2014-01-09 Jakub Jelinek <jakub@redhat.com>
6901
6902 PR target/58115
6903 * c-pch.c (c_common_write_pch): Call
6904 prepare_target_option_nodes_for_pch.
6905
6906 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
6907
6908 Update copyright years
6909
6910 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
6911
6912 * array-notation-common.c, c-cilkplus.c: Use the standard form for
6913 the copyright notice.
6914
6915 2013-12-28 Eric Botcazou <ebotcazou@adacore.com>
6916
6917 * c-ada-spec.c (print_constructor): New function.
6918 (print_destructor): Retrieve the origin of the destructor.
6919 (print_ada_declaration): Revamp handling of constructors/destructors.
6920
6921 2013-12-23 Stuart Hastings <stuart@apple.com>
6922 Bill Maddox <maddox@google.com>
6923 Jason Merrill <jason@redhat.com>
6924
6925 * c.opt: Add -fdeclone-ctor-dtor.
6926 * c-opts.c (c_common_post_options): Default to on iff -Os.
6927
6928 2013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
6929
6930 * c-common.c (c_common_attribute_table): Added "cilk simd function"
6931 attribute.
6932 * c-pragma.h (enum pragma_cilk_clause): Remove.
6933 (enum pragma_omp_clause): Added the following fields:
6934 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
6935 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
6936 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
6937 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
6938 PRAGMA_CILK_CLAUSE_UNIFORM.
6939
6940
6941 2013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
6942
6943 * cilk.c (cilk_outline): Made this function non-static.
6944 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
6945 (create_cilk_wrapper): Added a new parameter: a function pointer.
6946 (c_install_body_w_frame_cleanup): Remove
6947 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
6948 * c-common.h (cilk_outline): New prototype.
6949 (gimplify_cilk_spawn): Removed two parameters.
6950 (cilk_install_body_with_frame_cleanup): New prototype.
6951 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
6952 CILK_SPAWN_STMT case.
6953
6954 2013-12-11 Bernd Schmidt <bernds@codesourcery.com>
6955
6956 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
6957
6958 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
6959 (int_array_type_node): Remove.
6960 * c-common.c (c_common_nodes_and_builtins): Don't build it.
6961
6962 2013-12-05 Marek Polacek <polacek@redhat.com>
6963
6964 PR c/52023
6965 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
6966 [ADJUST_FIELD_ALIGN].
6967
6968 2013-12-04 Joseph Myers <joseph@codesourcery.com>
6969
6970 PR c/52023
6971 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
6972 and check field alignment if set.
6973 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
6974 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
6975
6976 2013-12-04 Jakub Jelinek <jakub@redhat.com>
6977 Marek Polacek <polacek@redhat.com>
6978
6979 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
6980 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
6981
6982 2013-11-29 H.J. Lu <hongjiu.lu@intel.com>
6983
6984 PR c/59309
6985 * cilk.c (gimplify_cilk_spawn): Properly handle function without
6986 arguments.
6987
6988 2013-11-29 Jakub Jelinek <jakub@redhat.com>
6989
6990 PR c/59280
6991 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
6992 goto invalid. If it is error_mark_node, don't issue further
6993 diagnostics.
6994
6995 2013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
6996
6997 * c.opt (Wopenmp-simd): New.
6998
6999 2013-11-22 Jakub Jelinek <jakub@redhat.com>
7000
7001 * c-ubsan.h (ubsan_instrument_return): New prototype.
7002 * c-ubsan.c (ubsan_instrument_return): New function.
7003
7004 2013-11-22 Andrew MacLeod <amacleod@redhat.com>
7005
7006 * c-common.c: Add required include files from gimple.h.
7007 * c-gimplify.c: Likewise.
7008 * cilk.c: Likewise.
7009
7010 2013-11-22 David Malcolm <dmalcolm@redhat.com>
7011
7012 * c-common.c (unsafe_conversion_p): Remove use of
7013 EXPR_LOC_OR_HERE macro.
7014 (conversion_warning): Likewise.
7015 (warnings_for_convert_and_check): Likewise.
7016 (warn_for_collisions_1): Likewise.
7017 (shorten_compare): Likewise, and remove use of in_system_header
7018 macro, using the location from the former.
7019 * c-lex.c (dump_one_header): Remove use of input_filename macro.
7020 (cb_def_pragma): Remove use of in_system_header macro.
7021 (lex_string): Likewise.
7022 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
7023
7024 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
7025 Mike Stump <mikestump@comcast.net>
7026 Richard Sandiford <rdsandiford@googlemail.com>
7027
7028 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
7029 instead of TREE_INT_CST_LOW, in cases where there is a protecting
7030 tree_fits_shwi_p or tree_fits_uhwi_p.
7031 (dump_generic_ada_node): Likewise.
7032 * c-format.c (check_format_arg): Likewise.
7033 * c-pretty-print.c (pp_c_integer_constant): Likewise.
7034
7035 2013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
7036
7037 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
7038
7039 2013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
7040
7041 PR c/53001
7042 * c-common.c (unsafe_conversion_p): Make this function
7043 return an enumeration with more detail.
7044 (conversion_warning): Use the new return type of
7045 unsafe_conversion_p to separately warn either about conversions
7046 that lower floating point number precision or about the other
7047 kinds of conversions.
7048 * c-common.h (enum conversion_safety): New enumeration.
7049 (unsafe_conversion_p): switching return type to
7050 conversion_safety enumeration.
7051 * c.opt: Adding new warning -Wfloat-conversion and
7052 enabling it with -Wconversion.
7053
7054 2013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
7055
7056 * c-opts.c: Include plugin.h.
7057 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
7058
7059 2013-11-19 Marek Polacek <polacek@redhat.com>
7060
7061 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
7062 call.
7063 (ubsan_instrument_shift): Likewise.
7064 (ubsan_instrument_vla): Likewise.
7065
7066 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
7067
7068 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
7069 cast to unsigned type.
7070
7071 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
7072
7073 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
7074 tree_low_cst.
7075 (complete_array_type): Update comment to refer to tree_to_[su]hwi
7076 rather than tree_low_cst.
7077
7078 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
7079
7080 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
7081 tree_to_uhwi throughout.
7082
7083 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
7084
7085 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
7086 tree_low_cst (..., 0) with tree_to_shwi throughout.
7087
7088 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
7089
7090 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
7091 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
7092
7093 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
7094
7095 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
7096 host_integerp (..., 0) with tree_fits_shwi_p throughout.
7097
7098 2013-11-15 Aldy Hernandez <aldyh@redhat.com>
7099
7100 * c-cilkplus.c: New file.
7101 * c-common.c (readonly_error): Add location argument.
7102 * c-common.h (readonly_error): Same.
7103 (c_finish_cilk_clauses): Protoize.
7104 (c_check_cilk_loop): Same.
7105 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
7106 Do not fail on error_mark_node.
7107 Abstract increment canonicalization to here...
7108 (c_omp_for_incr_canonicalize_ptr): New.
7109 c-pragma.c (init_pragma): Register "simd" pragma.
7110 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
7111 (enum pragma_cilk_clause): New.
7112
7113 2013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
7114
7115 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
7116 wchar_type and host_integerp checks.
7117
7118 2013-11-14 Andrew MacLeod <amacleod@redhat.com>
7119
7120 * c-common.c: Likewise.
7121 * c-gimplify.c: Likewise.
7122 * cilk.c: Likewise.
7123
7124 2013-11-14 Diego Novillo <dnovillo@google.com>
7125
7126 * c-common.c: Include fold-const.h.
7127 Include stor-layout.h.
7128 Include calls.h.
7129 Include stringpool.h.
7130 Include attribs.h.
7131 Include varasm.h.
7132 Include trans-mem.h.
7133 * c-cppbuiltin.c: Include stor-layout.h.
7134 Include stringpool.h.
7135 * c-format.c: Include stringpool.h.
7136 * c-lex.c: Include stringpool.h.
7137 Include stor-layout.h.
7138 * c-pragma.c: Include stringpool.h.
7139 Include attribs.h.
7140 Include varasm.h.
7141 Include gcc-symtab.h.
7142 * c-pretty-print.c: Include stor-layout.h.
7143 Include attribs.h.
7144 * cilk.c: Include stringpool.h.
7145 Include calls.h.
7146
7147 2013-11-13 Joseph Myers <joseph@codesourcery.com>
7148
7149 * c-common.h (enum rid): Add RID_AUTO_TYPE.
7150 * c-common.c (c_common_reswords): Add __auto_type.
7151 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
7152
7153 2013-11-12 Andrew MacLeod <amacleod@redhat.com>
7154
7155 * c-common.c: Include gimplify.h.
7156 * c-gimplify.c: Likewise.
7157 * cilk.c: Likewise.
7158 * c-omp.c: Include gimple-expr.h instead of gimple.h.
7159 * c-ubsan.c: Don't include gimple.h.
7160
7161 2013-11-12 Joseph Myers <joseph@codesourcery.com>
7162
7163 * c-common.c (c_common_reswords): Add _Thread_local.
7164
7165 2013-11-09 Joseph Myers <joseph@codesourcery.com>
7166
7167 * c-common.c (atomic_size_supported_p): New function.
7168 (resolve_overloaded_atomic_exchange)
7169 (resolve_overloaded_atomic_compare_exchange)
7170 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
7171 Use it instead of comparing size with a local list of sizes.
7172
7173 2013-11-07 Andrew MacLeod <amacleod@redhat.com>
7174 Joseph Myers <joseph@codesourcery.com>
7175
7176 * c-common.h (enum rid): Add RID_ATOMIC.
7177 * c-common.c (c_common_reswords): Add _Atomic.
7178 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
7179 (keyword_is_type_qualifier): Accept RID_ATOMIC.
7180 * c-format.c (check_format_types): Check for extra _Atomic
7181 qualifiers in format argument.
7182 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
7183 (pp_c_type_qualifier_list): Mention _Atomic in comment.
7184
7185 2013-11-06 Tobias Burnus <burnus@net-b.de>
7186
7187 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
7188
7189 2013-11-06 Joseph Myers <joseph@codesourcery.com>
7190
7191 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
7192 standards modes.
7193 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
7194 to mean lack of IEEE 754 support.
7195
7196 2013-11-05 Tobias Burnus <burnus@net-b.de>
7197
7198 * c.opt (-Wdate-time): New option
7199 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
7200
7201 2013-11-05 Joseph Myers <joseph@codesourcery.com>
7202
7203 * c-cppbuiltin.c (cpp_iec_559_value): Test
7204 flag_excess_precision_cmdline not flag_excess_precision.
7205
7206 2013-11-05 Tobias Burnus <burnus@net-b.de>
7207
7208 * c.opt (fopenmp-simd): New option.
7209 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
7210 (omp_pragmas): ... this new struct.
7211 (c_pp_lookup_pragma): Also walk omp_pragmas.
7212 (init_pragma): Init pragmas for -fopenmp-simd.
7213
7214 2013-11-04 Marek Polacek <polacek@redhat.com>
7215
7216 PR c++/58979
7217 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
7218
7219 2013-11-04 Joseph Myers <joseph@codesourcery.com>
7220
7221 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
7222 New functions.
7223 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
7224
7225 2013-11-04 Eric Botcazou <ebotcazou@adacore.com>
7226
7227 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
7228 (dump_ada_specs): Adjust prototype of second callback.
7229 * c-ada-spec.c (cpp_check): New global variable.
7230 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
7231 (print_generic_ada_decl): Likewise.
7232 (has_static_fields): Change return type to bool and add guard.
7233 (has_nontrivial_methods): New predicate.
7234 (is_tagged_type): Change return type to bool.
7235 (separate_class_package): Call has_nontrivial_methods.
7236 (pp_ada_tree_identifier): Minor tweaks.
7237 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
7238 (dump_ada_array_domains): Likewise.
7239 (dump_ada_array_type): Likewise.
7240 (dump_template_types): Remove cpp_check parameter and do not pass it to
7241 dump_generic_ada_node.
7242 (dump_ada_template): Likewise.
7243 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
7244 recursively.
7245 (print_ada_methods): Change return type to integer. Remove cpp_check
7246 parameter and do not pass it down.
7247 (dump_nested_types): Remove cpp_check parameter and do not pass it to
7248 dump_generic_ada_node.
7249 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
7250 accessing methods.
7251 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
7252 down. Use has_nontrivial_methods to recognize C++ classes. Use return
7253 value of print_ada_methods.
7254 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
7255 Set cpp_check to it before invoking dump_ada_nodes.
7256 (dump_ada_specs): Likewise.
7257
7258 2013-11-03 Marek Polacek <polacek@redhat.com>
7259
7260 * c-ubsan.c: Don't include hash-table.h.
7261 (ubsan_instrument_vla): New function.
7262 * c-ubsan.h: Declare it.
7263
7264 2013-10-31 David Malcolm <dmalcolm@redhat.com>
7265
7266 Automated part of renaming of symtab_node_base to symtab_node.
7267
7268 Patch autogenerated by rename_symtab.py from
7269 https://github.com/davidmalcolm/gcc-refactoring-scripts
7270 revision 58bb219cc090b2f4516a9297d868c245495ee622
7271
7272 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
7273 symtab_node_base to symtab_node.
7274
7275 2013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
7276
7277 Implement C++14 digit separators.
7278 * c-lex.c (interpret_float): Remove digit separators from scratch string
7279 before building real literal.
7280
7281 2013-10-30 Jakub Jelinek <jakub@redhat.com>
7282
7283 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
7284
7285 2013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
7286
7287 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
7288 fields.
7289 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
7290 enabled.
7291 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
7292 (insert_cilk_frame): New prototype.
7293 (cilk_init_builtins): Likewise.
7294 (gimplify_cilk_spawn): Likewise.
7295 (c_cilk_install_body_w_frame_cleanup): Likewise.
7296 (cilk_detect_spawn_and_unwrap): Likewise.
7297 (cilk_set_spawn_marker): Likewise.
7298 (build_cilk_sync): Likewise.
7299 (build_cilk_spawn): Likewise.
7300 * cilk.c: New file.
7301
7302 2013-10-29 David Malcolm <dmalcolm@redhat.com>
7303
7304 Patch autogenerated by refactor_symtab.py from
7305 https://github.com/davidmalcolm/gcc-refactoring-scripts
7306 revision 58bb219cc090b2f4516a9297d868c245495ee622
7307
7308 * c-gimplify.c (c_genericize): Update for conversion of symtab types
7309 to a true class hierarchy.
7310 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
7311
7312 2013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
7313
7314 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
7315
7316 2013-10-26 Jeff Law <law@redhat.com>
7317
7318 * c-common.c (c_define_builtins): Remove mudflap support.
7319 * c.opt: Ignore and warn for mudflap options.
7320
7321 2013-10-24 Tobias Burnus <burnus@net-b.de>
7322
7323 PR other/33426
7324 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
7325 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
7326
7327 2013-10-23 Jason Merrill <jason@redhat.com>
7328
7329 * c-format.c (gcc_cxxdiag_char_table): Add %X.
7330
7331 2013-10-11 Jakub Jelinek <jakub@redhat.com>
7332
7333 * c-common.h (omp_clause_mask::operator !=): New method.
7334 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
7335 instead of if (mask & something) tests everywhere.
7336
7337 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
7338 201307 instead of 201107.
7339 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
7340 (c_common_attribute_table): Add "omp declare target" and
7341 "omp declare simd" attributes.
7342 (handle_omp_declare_target_attribute,
7343 handle_omp_declare_simd_attribute): New functions.
7344 * c-omp.c: Include c-pragma.h.
7345 (c_finish_omp_taskgroup): New function.
7346 (c_finish_omp_atomic): Add swapped argument, if true,
7347 build the operation first with rhs, lhs arguments and use NOP_EXPR
7348 build_modify_expr.
7349 (c_finish_omp_for): Add code argument, pass it down to make_code.
7350 (c_omp_split_clauses): New function.
7351 (c_split_parallel_clauses): Removed.
7352 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
7353 c_omp_declare_simd_clauses_to_decls): New functions.
7354 * c-common.h (omp_clause_mask): New type.
7355 (OMP_CLAUSE_MASK_1): Define.
7356 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
7357 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
7358 omp_clause_mask::operator |, omp_clause_mask::operator &,
7359 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
7360 omp_clause_mask::operator ==): New methods.
7361 (enum c_omp_clause_split): New.
7362 (c_finish_omp_taskgroup): New prototype.
7363 (c_finish_omp_atomic): Add swapped argument.
7364 (c_finish_omp_for): Add code argument.
7365 (c_omp_split_clauses): New prototype.
7366 (c_split_parallel_clauses): Removed.
7367 (c_omp_declare_simd_clauses_to_numbers,
7368 c_omp_declare_simd_clauses_to_decls): New prototypes.
7369 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
7370 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
7371 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
7372 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
7373 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
7374 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
7375 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
7376 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
7377 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
7378 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
7379 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
7380 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
7381 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
7382 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
7383 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
7384 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
7385 PRAGMA_OMP_CLAUSE_UNIFORM.
7386
7387 2013-10-09 Marc Glisse <marc.glisse@inria.fr>
7388
7389 PR tree-optimization/20318
7390 * c-common.c (handle_returns_nonnull_attribute): New function.
7391 (c_common_attribute_table): Add returns_nonnull.
7392
7393 2013-10-03 Marc Glisse <marc.glisse@inria.fr>
7394
7395 PR c++/19476
7396 * c.opt (fcheck-new): Move to common.opt.
7397
7398 2013-09-25 Marek Polacek <polacek@redhat.com>
7399 Jakub Jelinek <jakub@redhat.com>
7400
7401 PR sanitizer/58413
7402 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
7403 an expression if we can prove it is correct.
7404 (ubsan_instrument_division): Likewise. Remove unnecessary
7405 check.
7406
7407 2013-09-18 Marek Polacek <polacek@redhat.com>
7408
7409 PR sanitizer/58411
7410 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
7411 Declare it.
7412 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
7413
7414 2013-09-14 Iain Sandoe <iain@codesourcery.com>
7415
7416 PR target/48094
7417 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
7418 fobjc-gc, freplace-objc-classes): Accept for LTO.
7419
7420 2013-09-13 Jacek Caban <jacek@codeweavers.com>
7421
7422 * c-target.def: New hook
7423
7424 2013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
7425
7426 PR c++/43452
7427 * c.opt (Wdelete-incomplete): Add.
7428
7429 2013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
7430
7431 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
7432 (vector_types_compatible_elements_p): New function.
7433 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
7434 declaration.
7435 (vector_types_compatible_elements_p): Declare.
7436
7437 2013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
7438
7439 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
7440 a virtual member function.
7441 (pp_simple_type_specifier): Remove.
7442 (pp_c_type_specifier): Likewise.
7443 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
7444 Rename from pp_c_type_specifier. Adjust.
7445 (c_pretty_printer::c_pretty_printer): Do not assign to
7446 simple_type_specifier.
7447
7448 2013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
7449
7450 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
7451 member function.
7452 (c_pretty_printer::storage_class_specifier): Likewise.
7453 (c_pretty_printer::initializer): Likewise.
7454 (pp_declaration): Remove.
7455 (pp_declaration_specifiers): Likewise.
7456 (pp_abstract_declarator): Likewise.
7457 (pp_declarator): Likewise.
7458 (pp_type_id): Likewise.
7459 (pp_statement): Likewise.
7460 (pp_constant): Likewise.
7461 (pp_id_expression): Likewise.
7462 (pp_primary_expression): Likewise.
7463 (pp_unary_expression): Likewise.
7464 (pp_multiplicative_expression): Likewise.
7465 (pp_conditional_expression): Likewise.
7466 (pp_assignment_expression): Likewise.
7467 (pp_expression): Likewise.
7468 (pp_c_type_id): Likewise.
7469 (pp_c_storage_class_specifier): Likewise.
7470 * c-pretty-print.c (pp_c_type_cast): Tidy.
7471 (pp_c_pointer): Likewise.
7472 (pp_c_type_specifier): Likewise.
7473 (pp_c_parameter_type_list): Likewise.
7474 (pp_c_function_definition): Likewise.
7475 (pp_c_init_declarator): Likewise.
7476 (pp_c_initializer_list): Likewise.
7477 (pp_c_constructor_elts): Likewise.
7478 (c_pretty_printer::direct_abstract_declarator): Likewise.
7479 (c_pretty_printer::declaration_specifiers): Likewise.
7480 (c_pretty_printer::primary_expression): Likewise.
7481 (c_pretty_printer::postfix_expression): Likewise.
7482 (c_pretty_printer::type_id): Rename from pp_c_type_id.
7483 (c_pretty_printer::storage_class_specifier): Rename from
7484 pp_c_storage_class_specifier.
7485 (c_pretty_printer::initializer): Rename from pp_c_initializer.
7486 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
7487 storage_class_specifier, initializer, offset_list, flags.
7488
7489 2013-08-30 Marek Polacek <polacek@redhat.com>
7490
7491 * c-ubsan.c: New file.
7492 * c-ubsan.h: New file.
7493
7494 2013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
7495
7496 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
7497 member function.
7498 (c_pretty_printer::declaration_specifiers): Likewise.
7499 (c_pretty_printer::declarator): Likewise.
7500 (c_pretty_printer::abstract_declarator): Likewise.
7501 (c_pretty_printer::direct_abstract_declarator): Likewise.
7502 (c_pretty_printer::direct_declarator): Likewise.
7503 (c_pretty_printer::function_specifier): Likewise.
7504 (pp_declaration): Adjust.
7505 (pp_declaration_specifiers): Likewise.
7506 (pp_abstract_declarator): Likewise.
7507 (pp_direct_declarator): Likewise.
7508 (pp_function_specifier): Likewise.
7509 (pp_direct_abstract_declarator): Remove as unused.
7510 (pp_c_declaration): Remove.
7511 (pp_c_declaration_specifiers): Likewise.
7512 (pp_c_declarator): Likewise.
7513 (pp_c_direct_declarator): Likewise.
7514 (pp_c_function_specifier): Likewise.
7515 (pp_c_direct_abstract_declarator): Likewise.
7516 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
7517 from pp_c_abstract_declarator. Adjust.
7518 (c_pretty_printer::direct_abstract_declarator): Rename from
7519 pp_c_direct_abstract_declarator. Adjust.
7520 (c_pretty_printer::function_specifier): Rename from
7521 pp_c_function_specifier. Adjust.
7522 (c_pretty_printer::declaration_specifiers): Rename from
7523 pp_c_declaration_specifiers. Adjust.
7524 (c_pretty_printer::direct_declarator): Rename from
7525 pp_c_direct_declarator. Adjust.
7526 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
7527 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
7528 (c_pretty_printer::c_pretty_printer): Do not assign to
7529 declaration, declaration_specifiers, declarator,
7530 direct_declarator, direct_abstract_declarator, function_specifier.
7531
7532 2013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
7533
7534 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
7535 virtual member function.
7536 (c_pretty_printer::multiplicative_expression): Likewise.
7537 (c_pretty_printer::conditional_expression): Likewise.
7538 (c_pretty_printer::assignment_expression): Likewise.
7539 (c_pretty_printer::expression): Likewise.
7540 (pp_unary_expression): Adjust.
7541 (pp_multiplicative_expression): Likewise.
7542 (pp_assignment_expression): Likewise.
7543 (pp_conditional_expression): Likewise.
7544 (pp_expression): Likewise.
7545 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
7546 from pp_c_unary_expression. Adjust.
7547 (c_pretty_printer::multiplicative_expression): Rename from
7548 pp_c_multiplicative_expression. Adjust.
7549 (c_pretty_printer::conditional_expression): Rename from
7550 pp_c_conditional_expression. Adjust.
7551 (c_pretty_printer::assignment_expression): Rename from
7552 pp_c_assignment_expression. Adjust.
7553 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
7554 (c_pretty_printer::c_pretty_printer): Do not assign to
7555 unary_expression, multiplicative_expression,
7556 conditional_expression, expression.
7557
7558 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
7559
7560 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
7561 virtual member function.
7562 (pp_postfix_expression): Adjust.
7563 (pp_c_postfix_expression): Remove.
7564 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
7565 from pp_c_postfix_expression. Adjust.
7566 (c_pretty_printer::c_pretty_printer): Do not assign to
7567 postfix_expression.
7568
7569 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
7570
7571 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
7572 virtua member function.
7573 (pp_primary_expression): Adjust.
7574 (pp_c_primary_expression): Remove.
7575 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
7576 from pp_c_primary_expression. Adjust.
7577 (pp_c_initializer_list): Use pp_primary_expression.
7578 (c_pretty_printer::c_pretty_printer): Do not assign to
7579 primary_expression.
7580
7581 2013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
7582
7583 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
7584 * c-pretty-print.c (M_): Remove.
7585 (c_pretty_printer::translate_string): Define.
7586 (pp_c_type_specifier): Use it.
7587 (pp_c_primary_expression): Likewise.
7588 (pp_c_expression): Likewise.
7589
7590 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
7591
7592 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
7593 virtual function.
7594 (pp_c_id_expression): Remove.
7595 (pp_id_expression): Adjust.
7596 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
7597 pp_c_id_expression. Adjust.
7598 (pp_c_postfix_expression): Use pp_id_expression.
7599 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
7600
7601 2013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
7602
7603 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
7604 member function.
7605 (pp_constant): Adjust.
7606 (pp_c_constant): Remove.
7607 * c-pretty-print.c (c_pretty_printer::constant): Rename from
7608 pp_c_constant. Adjust.
7609 (pp_c_constant)
7610 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
7611 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
7612
7613 2013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
7614
7615 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
7616 (c_pretty_printer::c_pretty_printer): Declare.
7617 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
7618 c_pretty_printer_init. Adjust.
7619 (print_c_tree): Do not call c_pretty_printer_init.
7620 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
7621
7622 2013-08-09 Arnaud Charlet <charlet@adacore.com>
7623
7624 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
7625
7626 2013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
7627
7628 PR c++/58080
7629 * c-common.c (pointer_int_sum): Add bool parameter.
7630 * c-common.h (pointer_int_sum): Adjust declaration.
7631
7632 2013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
7633
7634 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
7635 c_pretty_printer variable.
7636
7637 2013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
7638
7639 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
7640 (pp_base): Remove.
7641 (pp_c_base): Likewise. Adjust users.
7642 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
7643 (pp_c_whitespace): Do not call pp_base.
7644 (pp_c_left_paren): Likewise.
7645 (pp_c_right_paren): Likewise.
7646 (pp_c_left_brace): Likewise.
7647 (pp_c_right_brace): Likewise.
7648 (pp_c_left_bracket): Likewise.
7649 (pp_c_right_bracket): Likewise.
7650 (pp_c_dot): Likewise.
7651 (pp_c_ampersand): Likewise.
7652 (pp_c_star): Likewise.
7653 (pp_c_arrow): Likewise.
7654 (pp_c_semicolon): Likewise.
7655 (pp_c_complement): Likewise.
7656 (pp_c_exclamation): Likewise.
7657 (pp_c_direct_declarator): Likewise.
7658 (pp_c_ws_string): Likewise.
7659 (pp_c_identifier): Likewise.
7660 (pp_c_statement): Likewise.
7661 (print_c_tree): Likewise.
7662
7663 2013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
7664
7665 PR c++/58072
7666 * c-common.c (c_parse_error): Catch user-defined literal tokens and
7667 provide useful error strings.
7668
7669 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
7670
7671 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
7672 printer functions instead of pp_string or operators and punctuators.
7673 (dump_generic_ada_node): Likewise.
7674 * c-pretty-print.c (pp_c_type_specifier): Likewise.
7675 (pp_c_relational_expression): Likewise.
7676 (pp_c_logical_or_expression): Likewise.
7677
7678 2013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
7679
7680 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
7681 functions instead of pp_character.
7682 (pp_ada_tree_identifier): Likewise.
7683 (dump_ada_double_name): Likewise.
7684 (dump_ada_function_declaration): Likewise.
7685 (dump_ada_array_domains): Likewise.
7686 (dump_template_types): Likewise.
7687 (dump_generic_ada_node): Likewise.
7688 (print_ada_declaration): Likewise.
7689 (print_ada_struct_decl): Likewise.
7690 * c-pretty-print.c (pp_c_integer_constant): Likewise.
7691
7692 2013-07-23 Tom Tromey <tromey@redhat.com>
7693
7694 * c-common.h (enum rid) <RID_GENERIC>: New constant.
7695 * c-common.c (c_common_reswords): Add _Generic.
7696
7697 2013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
7698
7699 * c-common.c: Fix typos.
7700 * c-common.h: Likewise.
7701
7702 2013-07-13 Lubos Lunak <l.lunak@suse.cz>
7703
7704 PR c++/55203
7705 * c-common.c (c_common_attribute_table): Add warn_unused.
7706 (handle_warn_unused_attribute): New.
7707
7708 2013-07-10 Jakub Jelinek <jakub@redhat.com>
7709
7710 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
7711 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
7712
7713 2013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
7714
7715 PR c++/57869
7716 * c.opt: Add Wconditionally-supported.
7717
7718 2013-07-08 Graham Stott <graham.stott@btinternet.com>
7719
7720 * array-notation-common.c (length_mismatch_in_expr_p): Delete
7721 unused variables l_length and l_node.
7722
7723 2013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
7724
7725 PR c/57821
7726 * c-common.c (complete_array_type): Delay folding first index
7727 like other indices. When folding, check for index overflow.
7728
7729 2013-06-27 Marc Glisse <marc.glisse@inria.fr>
7730
7731 PR c++/57509
7732 * c-common.h (c_build_vec_perm_expr): New complain argument.
7733 * c-common.c (c_build_vec_perm_expr): Likewise.
7734 Use save_expr also in C++.
7735
7736 2013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
7737
7738 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
7739 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
7740 * c-opts.c (c_common_post_options): Likewise.
7741
7742 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
7743
7744 * array-notation-common.c (length_mismatch_in_expr): Changed the
7745 parameter type's from a dynamic array to a vec_tree. Also removed
7746 the size parameters.
7747 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
7748 the change above.
7749
7750 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
7751
7752 * c-common.h (struct cilkplus_an_parts): New structure.
7753 (struct cilkplus_an_loop_parts): Likewise.
7754 (cilkplus_extract_an_triplets): New prototype.
7755 (fix_sec_implicit_args): Likewise.
7756 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
7757 (fix_sec_implicit_args): Likewise.
7758
7759 2013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
7760
7761 * array-notation-common.c (find_inv_trees): Removed an unwanted
7762 typecasting.
7763 * c-common.h (struct inv_list::additional_tcodes): Changed type from
7764 enum rid to enum tree_code.
7765
7766 2013-06-11 Jan Hubicka <jh@suse.cz>
7767
7768 * c-common.c (handle_alias_ifunc_attribute): Do not set
7769 DECL_EXTERNAL for weakref variables.
7770 * c-pragma.c (handle_pragma_weak): Make sure aliases
7771 are not declared as external.
7772
7773 2013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
7774
7775 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
7776 function from c/c-array-notation.c.
7777 (is_cilkplus_reduce_builtin): Likewise.
7778 (find_rank): Likewise.
7779 (extract_array_notation_exprs): Likewise.
7780 (replace_array_notations): Likewise.
7781 (find_inv_trees): Likewise.
7782 (replace_inv_trees): Likewise.
7783 (contains_array_notation_expr): Likewise.
7784 (find_correct_array_notation_type): Likewise.
7785 * c-common.h (struct inv_list): Moved this struct from the file
7786 c/c-array-notation.c and added a new field called additional tcodes.
7787 (length_mismatch_in_expr_p): New prototype.
7788 (is_cilkplus_reduce_builtin): Likewise.
7789 (find_rank): Likewise.
7790 (extract_array_notation_exprs): Likewise.
7791 (replace_array_notation): Likewise.
7792 (find_inv_trees): Likewise.
7793 (replace_inv_trees): Likewise.
7794 (find_correct_array_notation_type): Likewise.
7795
7796 2013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
7797
7798 * c-common.c (c_define_builtins): When cilkplus is enabled, the
7799 function array_notation_init_builtins is called.
7800 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
7801 * c-common.def (ARRAY_NOTATION_REF): New tree.
7802 * c-common.h (build_array_notation_expr): New function declaration.
7803 (build_array_notation_ref): Likewise.
7804 (extract_sec_implicit_index_arg): New extern declaration.
7805 (is_sec_implicit_index_fn): Likewise.
7806 (ARRAY_NOTATION_CHECK): New define.
7807 (ARRAY_NOTATION_ARRAY): Likewise.
7808 (ARRAY_NOTATION_START): Likewise.
7809 (ARRAY_NOTATION_LENGTH): Likewise.
7810 (ARRAY_NOTATION_STRIDE): Likewise.
7811 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
7812 ARRAY_NOTATION_REF.
7813 (pp_c_expression): Likewise.
7814 * c.opt (flag_enable_cilkplus): New flag.
7815 * array-notation-common.c: New file.
7816
7817 2013-05-14 Jakub Jelinek <jakub@redhat.com>
7818
7819 PR c++/57274
7820 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
7821
7822 2013-05-10 Marc Glisse <marc.glisse@inria.fr>
7823
7824 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
7825 vectors.
7826
7827 2013-05-07 Han Shen <shenhan@google.com>
7828
7829 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
7830
7831 2013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
7832
7833 * c-common.c (check_user_alignment): Emit error for negative values.
7834
7835 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
7836
7837 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
7838
7839 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
7840
7841 * c-cppbuiltin.c (c_cpp_builtins): Do not define
7842 __GXX_EXPERIMENTAL_CXX1Y__.
7843
7844 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
7845 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
7846
7847 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
7848 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
7849 to simply use OPT_Wpointer_arith.
7850 (c_sizeof_or_alignof_type): Likewise.
7851
7852 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
7853
7854 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
7855
7856 2013-04-12 Jakub Jelinek <jakub@redhat.com>
7857
7858 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
7859 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
7860 specifiers.
7861
7862 2013-04-07 Steven Bosscher <steven@gcc.gnu.org>
7863
7864 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
7865
7866 2013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
7867
7868 * c-common.c (pointer_int_sum): Remove dead code.
7869
7870 2013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
7871
7872 PR middle-end/56524
7873 * c-common.c (handle_optimize_attribute): Don't call
7874 save_optabs_if_changed.
7875
7876 2013-03-05 Jakub Jelinek <jakub@redhat.com>
7877
7878 PR middle-end/56461
7879 * c-pch.c (pch_init): Free target_validity at the end.
7880
7881 2013-03-04 Jakub Jelinek <jakub@redhat.com>
7882
7883 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
7884
7885 2013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
7886 Jakub Jelinek <jakub@redhat.com>
7887
7888 PR sanitizer/56454
7889 * c-common.c (handle_no_sanitize_address_attribute): New function.
7890 (c_common_attribute_table): Add no_sanitize_address attribute.
7891 (handle_no_address_safety_analysis_attribute): Add
7892 no_sanitize_address attribute, not no_address_safety_analysis
7893 attribute.
7894
7895 2013-02-18 Aldy Hernandez <aldyh@redhat.com>
7896
7897 PR target/52555
7898 * c-common.c (handle_optimize_attribute): Call
7899 save_optabs_if_changed.
7900
7901 2013-02-18 Jakub Jelinek <jakub@redhat.com>
7902 Steven Bosscher <steven@gcc.gnu.org>
7903
7904 PR pch/54117
7905 * c-opts.c (c_common_post_options): If debug info is enabled
7906 and non-dwarf*, refuse to load PCH files and when writing PCH
7907 file warn.
7908
7909 2013-02-05 Jakub Jelinek <jakub@redhat.com>
7910
7911 PR middle-end/56167
7912 * c-common.c (handle_error_attribute): Fix condition.
7913
7914 2013-01-30 Jakub Jelinek <jakub@redhat.com>
7915
7916 PR c++/55742
7917 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
7918
7919 2013-01-18 Jason Merrill <jason@redhat.com>
7920
7921 PR target/54908
7922 * c.opt (-fextern-tls-init): New.
7923 * c-opts.c (c_common_post_options): Handle it.
7924
7925 2013-01-09 Jakub Jelinek <jakub@redhat.com>
7926
7927 PR c/48418
7928 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
7929 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
7930 and is either negative or bigger or equal to type precision
7931 of the first operand.
7932
7933 2012-12-03 Marek Polacek <polacek@redhat.com>
7934
7935 PR c/55570
7936 * c-common.c (check_user_alignment): Swap order of tests,
7937 check TREE_CODE first.
7938
7939 2012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
7940
7941 PR c++/52654
7942 * c-common.h (overflow_type): New enum.
7943 (build_userdef_literal): Add overflow_type argument.
7944 (tree_userdef_literal): Add overflow_type.
7945 (USERDEF_LITERAL_OVERFLOW): New access macro.
7946 * c-common.c (build_userdef_literal): Add overflow_type
7947 argument.
7948 * c-lex.c (c_lex_with_flags): Add overflow_type to
7949 build_userdef_literal calls.
7950 (interpret_integer, interpret_float): Add overflow_type argument.
7951
7952 2012-11-28 Richard Biener <rguenther@suse.de>
7953
7954 PR c/35634
7955 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
7956 here and use a type with proper overflow behavior for types that would
7957 need to be promoted for the arithmetic.
7958
7959 2012-11-23 Jakub Jelinek <jakub@redhat.com>
7960
7961 PR sanitizer/55435
7962 * c-common.c (handle_no_address_safety_analysis_attribute): New
7963 function.
7964 (c_common_attribute_table): Add no_address_safety_analysis.
7965
7966 2012-11-16 Simon Baldwin <simonb@google.com>
7967
7968 * c.opt: Add f[no-]canonical-system-headers.
7969 * c-opts.c (c_common_handle_option): Handle
7970 OPT_fcanonical_system_headers.
7971
7972 2012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
7973
7974 PR c++/54413
7975 * c-opts.c (c_common_handle_option): Set new flags.
7976 * c.opt: Describe new flags.
7977
7978 2012-11-09 Jason Merrill <jason@redhat.com>
7979
7980 * c.opt (Wabi-tag): New.
7981
7982 2012-11-09 Andi Kleen <ak@linux.intel.com>
7983
7984 PR 55139
7985 * c-common.c (get_atomic_generic_size): Mask with
7986 MEMMODEL_MASK
7987
7988 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
7989
7990 PR c/53063
7991 * c.opt (Wformat): Make it Alias Wformat=1.
7992 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
7993 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
7994 LangEnabledBy.
7995 (Wformat=): RejectNegative. Use LangEnabledBy.
7996 (Wnonnull): Use LangEnabledBy.
7997 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
7998 * c-format.c (set_Wformat): Delete.
7999 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
8000 (maybe_read_dollar_number): Likewise.
8001 (avoid_dollar_number): Likewise.
8002 (finish_dollar_format_checking): Likewise.
8003 (check_format_info): Likewise.
8004 (check_format_info_main): Likewise.
8005 (check_format_types): Likewise.
8006 (format_type_warning): Likewise.
8007 * c-common.c (int): Likewise.
8008 (check_function_sentinel): Likewise.
8009 * c-common.h (warn_format,set_Wformat): Do not declare here.
8010
8011 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
8012
8013 PR c/53063
8014 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
8015 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
8016 Use LangEnabledBy.
8017 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
8018 common.opt.
8019 (Wvariadic-macros): Init(1).
8020 * c-opts.c (c_common_handle_option): Do not handle them
8021 explicitly.
8022 (c_common_post_options): Likewise.
8023 (sanitize_cpp_opts): warn_unused_macros is now
8024 cpp_warn_unused_macros.
8025 (push_command_line_include): Likewise.
8026 * c-common.c (warn_unknown_pragmas): Do not define.
8027 * c-common.h (warn_unknown_pragmas): Do not declare.
8028
8029 2012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
8030
8031 PR c/51294
8032 * c-common.c (conversion_warning): Handle conditional expressions.
8033
8034 2012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
8035
8036 PR c++/54930
8037 * c.opt (Wreturn_local_addr): Define new option.
8038
8039 2012-10-25 Jason Merrill <jason@redhat.com>
8040
8041 * c.opt (Wvirtual-move-assign): New.
8042
8043 * c.opt (Winherited-variadic-ctor): New.
8044
8045 2012-10-25 Marc Glisse <marc.glisse@inria.fr>
8046
8047 PR c++/54427
8048 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
8049
8050 2012-10-23 Joseph Myers <joseph@codesourcery.com>
8051
8052 * c-common.h (pch_cpp_save_state): Declare.
8053 * c-target.def (c_preinclude): New hook.
8054 * c-opts.c (done_preinclude): New.
8055 (push_command_line_include): Handle default preincluded header.
8056 (cb_file_change): Call pch_cpp_save_state when calling
8057 push_command_line_include.
8058 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
8059 (pch_cpp_save_state): New.
8060 (pch_init): Call pch_cpp_save_state conditionally, instead of
8061 calling cpp_save_state.
8062
8063 2012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
8064
8065 PR c/53063
8066 PR c/40989
8067 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
8068 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
8069 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
8070 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
8071 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
8072 * c-opts.c (c_common_handle_option): Remove explicit handling from
8073 here.
8074 (c_common_post_options): Likewise.
8075
8076 2012-10-18 Eric Botcazou <ebotcazou@adacore.com>
8077
8078 * c-ada-spec.c (LOCATION_COL): Delete.
8079 (compare_location): New function.
8080 (compare_node): Use it.
8081 (compare_comment): Likewise.
8082
8083 2012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
8084
8085 PR c/53063
8086 PR c/40989
8087 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
8088 * c-opts.c (c_common_handle_option): Do not set them here. Add
8089 comment.
8090 (c_common_post_options): Likewise.
8091
8092 2012-10-16 Eric Botcazou <ebotcazou@adacore.com>
8093
8094 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
8095 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
8096 Remove POINTER_TYPE handling, add large unsigned handling and use
8097 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
8098
8099 2012-10-12 Jakub Jelinek <jakub@redhat.com>
8100
8101 PR c/54381
8102 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
8103 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
8104 locs and array of 3 trees instead of just single loc and single
8105 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
8106 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
8107 For *cmp* builtins that take two sources strings report warnings
8108 about first and second source, not about destination and source.
8109
8110 2012-10-12 Marc Glisse <marc.glisse@inria.fr>
8111
8112 PR c++/53055
8113 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
8114
8115 2012-10-11 Eric Botcazou <ebotcazou@adacore.com>
8116
8117 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
8118 declaring something coming from another file.
8119
8120 2012-10-10 Arnaud Charlet <charlet@adacore.com>
8121
8122 PR ada/54845
8123 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
8124
8125 2012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
8126
8127 PR c++/54194
8128 * c-common.c (warn_about_parentheses): Add location_t parameter;
8129 use EXPR_LOC_OR_LOC.
8130 * c-common.h: Update declaration.
8131
8132 2012-10-09 Marc Glisse <marc.glisse@inria.fr>
8133
8134 PR c++/54427
8135 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
8136 more operations. Make error messages optional.
8137 * c-common.h (enum stv_conv): Moved from c-typeck.c.
8138 (scalar_to_vector): Declare.
8139
8140 2012-10-08 Jason Merrill <jason@redhat.com>
8141
8142 * c-common.c (c_common_reswords): Add thread_local.
8143
8144 2012-10-08 Dodji Seketeli <dodji@redhat.com>
8145
8146 PR c++/53528 C++11 attribute support
8147 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
8148 new functions.
8149 * c-common.c (check_cxx_fundamental_alignment_constraints): New
8150 static function.
8151 (handle_aligned_attribute): In choose strictest alignment
8152 among many. Use new check_cxx_fundamental_alignment_constraints.
8153 (handle_transparent_union_attribute): In c++11 attribute syntax,
8154 don't look through typedefs.
8155
8156 2012-10-04 Arnaud Charlet <charlet@adacore.com>
8157
8158 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
8159 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
8160 out of dumpfile.h.
8161
8162 2012-09-25 Dehao Chen <dehao@google.com>
8163
8164 PR middle-end/54645
8165 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
8166 map when read in the pch.
8167
8168 2012-09-18 Arnaud Charlet <charlet@adacore.com>
8169
8170 * c-ada-spec.c: Style fixes.
8171
8172 2012-09-18 Thomas Quinot <quinot@adacore.com>
8173
8174 * c.opt (-fada-spec-parent): Define new command line switch.
8175 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
8176 is specified, generate binding spec as a child of the specified unit.
8177
8178 2012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
8179 Manuel López-Ibáñez <manu@gcc.gnu.org>
8180
8181 PR c++/53210
8182 * c.opt ([Winit-self]): Enabled by -Wall in C++.
8183
8184 2012-08-23 Arnaud Charlet <charlet@adacore.com>
8185
8186 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
8187 for pointers, and add missing Convention C pragma.
8188 (print_ada_struct_decl): Add missing aliased keyword.
8189 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
8190
8191 2012-08-17 Jakub Jelinek <jakub@redhat.com>
8192
8193 * c-common.c (sizeof_pointer_memaccess_warning): New function.
8194 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
8195 * c-opts.c (c_common_handle_option): Enable it for -Wall.
8196 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
8197 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
8198
8199 2012-08-10 Richard Guenther <rguenther@suse.de>
8200
8201 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
8202
8203 2012-08-07 Steven Bosscher <steven@gcc.gnu.org>
8204
8205 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
8206 instead of separate pp_newline and pp_flush.
8207 (print_c_tree): Likewise.
8208
8209 2012-07-26 Richard Henderson <rth@redhat.com>
8210
8211 * c-common.c (handle_hot_attribute): Allow labels.
8212 (handle_cold_attribute): Likewise.
8213
8214 2012-07-20 Jakub Jelinek <jakub@redhat.com>
8215
8216 PR c++/28656
8217 * c-common.c (check_function_nonnull): Handle multiple nonnull
8218 attributes properly.
8219
8220 2012-07-16 Steven Bosscher <steven@gcc.gnu.org>
8221
8222 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
8223 * c-ada-spec.c: Likewise.
8224 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
8225
8226 2012-07-14 Steven Bosscher <steven@gcc.gnu.org>
8227
8228 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
8229 Remove code conditional on it.
8230
8231 2012-07-11 Steven Bosscher <steven@gcc.gnu.org>
8232
8233 * c-gimplify.c: Do not include basic-block.h.
8234 * c-common.c: Do not include linfuncs.h.
8235
8236 2012-07-08 Steven Bosscher <steven@gcc.gnu.org>
8237
8238 * c-common.h: Include tree.h.
8239
8240 2012-07-02 Jason Merrill <jason@redhat.com>
8241
8242 PR c++/53524
8243 * c-common.c (get_priority): Call default_conversion.
8244
8245 2012-07-01 Uros Bizjak <ubizjak@gmail.com>
8246
8247 * c-pch.c (c_common_write_pch): Remove unused variables.
8248
8249 2012-06-29 Steven Bosscher <steven@gcc.gnu.org>
8250
8251 * cppspec.c: Moved from gcc/ to here.
8252
8253 2012-06-27 Kai Tietz <ktietz@redhat.com>
8254
8255 PR preprocessor/37215
8256 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
8257
8258 2012-06-21 Steven Bosscher <steven@gcc.gnu.org>
8259
8260 * c-common.h (c_common_print_pch_checksum): Remove.
8261 * c-pch.c: Do not include output.h.
8262 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
8263 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
8264 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
8265 (struct c_pch_header): Remove.
8266 (get_ident): Update gpch version.
8267 (pch_init): Do not print executable_checksum to asm_out_file.
8268 Do not fail if there is no asm_out_file to read back from. Set
8269 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
8270 (c_common_write_pch): Verify that nothing was written to asm_out_file
8271 since pch_init was called. Do not write a c_pch_header, and do not
8272 copy from asm_out_file to the PCH.
8273 (c_common_read_pch): Do not read a c_pch_header, and do not restore
8274 the content of asm_out_file from the PCH.
8275 (c_common_print_pch_checksum): Remove.
8276 * c-opts.c (c_common_init): Print out executable_checksum directly.
8277
8278 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
8279
8280 * c-target.def (objc_declare_unresolved_class_reference,
8281 objc_declare_class_definition): Add new hooks.
8282
8283 2012-06-19 Steven Bosscher <steven@gcc.gnu.org>
8284
8285 * c-lex.c: Do not include output.h.
8286 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
8287 Remove uses of ASM_OUTPUT_IDENT.
8288
8289 2012-06-15 Marc Glisse <marc.glisse@inria.fr>
8290
8291 PR c++/51033
8292 * c-common.h (c_build_vec_perm_expr): Move decl here.
8293 * c-common.c (c_build_vec_perm_expr): Move definition
8294 here.
8295
8296 2012-06-06 Steven Bosscher <steven@gcc.gnu.org>
8297
8298 * c.opt (fconserve-space): Turn into a no-op.
8299
8300 2012-06-04 Sterling Augustine <saugustine@google.com>
8301
8302 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
8303 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
8304 both the start and end of the function.
8305
8306 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
8307
8308 * c-common.c: Do not include output.h.
8309 * c-pragma.c: Likewise.
8310
8311 2012-06-04 Steven Bosscher <steven@gcc.gnu.org>
8312
8313 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
8314 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
8315 (lang_decl_name): Handle namespace decls.
8316
8317 2012-05-31 Steven Bosscher <steven@gcc.gnu.org>
8318
8319 * c-ada-spec.c: Do not include output.h.
8320 * c-semantics.c: Likewise.
8321
8322 2012-05-29 Joseph Myers <joseph@codesourcery.com>
8323
8324 * c-common.c: Fix typo.
8325
8326 2012-05-29 Michael Matz <matz@suse.de>
8327
8328 * c-common.h (c_expand_decl): Remove prototype.
8329
8330 2012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
8331
8332 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
8333 * c-opts.c (c_common_handle_option): Remove code handling
8334 warn_missing_braces.
8335
8336 2012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
8337
8338 PR c++/25137
8339 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
8340 -Wmissing_braces.
8341
8342 2012-05-22 Dodji Seketeli <dodji@redhat.com>
8343
8344 PR c++/53322
8345 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
8346
8347 2012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
8348
8349 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
8350 * c-opts.c (c_common_handle_option): Do not handle explicitly
8351 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
8352
8353 2012-05-16 Dodji Seketeli <dodji@redhat.com>
8354
8355 PR preprocessor/7263
8356 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
8357 to cpp_classify_number. For diagnostics, use the precise location
8358 instead of the global input_location.
8359
8360 2012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
8361
8362 PR c++/11856
8363 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
8364
8365 2012-05-14 Bernd Schmidt <bernds@codesourcery.com>
8366
8367 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
8368
8369 2012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
8370
8371 PR 53063
8372 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
8373 Wreorder): Use LangEnabledBy.
8374 * c-opts.c (c_common_handle_option): Do not enable them
8375 explicitly. Call lang-specific generated functions.
8376 (c_common_post_options): Do not set them here.
8377
8378 2012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
8379
8380 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
8381 Wmissing-field-initializers,Wmissing-parameter-type,
8382 Wold-style-declaration,Woverride-init): Use EnabledBy.
8383 * c-opts.c (c_common_post_options): Do not set here explicitly.
8384
8385 2012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
8386
8387 PR 53063
8388 * c-opts.c (c_common_handle_option): Use handle_generated_option
8389 to enable sub-options.
8390
8391 2012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
8392
8393 PR c++/53158
8394 * c-common.c (warnings_for_convert_and_check): Use warning_at.
8395
8396 2012-05-10 Richard Guenther <rguenther@suse.de>
8397
8398 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
8399 adjust commentary about TYPE_IS_SIZETYPE types.
8400
8401 2012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
8402
8403 PR c++/53261
8404 * c-common.c (warn_logical_operator): Check that argument of
8405 integer_zerop is not NULL.
8406
8407 2012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
8408
8409 PR c/43772
8410 * c-common.c (warn_logical_operator): Do not warn if either side
8411 is already true or false.
8412
8413 2012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
8414
8415 PR c/51712
8416 * c-common.c (expr_original_type): New.
8417 (shorten_compare): Do not warn for enumeration types.
8418
8419 2012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
8420
8421 * c.opt (fpermissive): Add Var(flag_permissive).
8422
8423 2012-04-30 Marc Glisse <marc.glisse@inria.fr>
8424
8425 PR c++/51033
8426 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
8427 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
8428
8429 2012-04-30 Dodji Seketeli <dodji@redhat.com>
8430
8431 Add -Wvarargs option
8432 * c.opt (Wvarargs): Define new option.
8433
8434 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
8435
8436 * c-common.c (check_function_arguments): Replace
8437 Wmissing-format-attribute with Wsuggest-attribute=format.
8438
8439 2012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
8440
8441 * c.opt (Wsuggest-attribute=format): New. Alias of
8442 Wmissing-format-attribute.
8443 * c-format.c (decode_format_type): Replace
8444 Wmissing-format-attribute with Wsuggest-attribute=format.
8445 (check_function_format): Likewise.
8446
8447 2012-04-27 Ollie Wild <aaw@google.com>
8448
8449 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
8450 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
8451 * c.opt: Add Wliteral-suffix.
8452
8453 2012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
8454
8455 PR c/44774
8456 * c.opt (Wpedantic): New.
8457 (pedantic): Alias Wpedantic.
8458 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
8459 (c_common_post_options): Likewise.
8460 (sanitize_cpp_opts): Likewise.
8461 * c-lex.c (interpret_float): Likewise.
8462 * c-format.c (check_format_types): Likewise.
8463 * c-common.c (pointer_int_sum): Likewise.
8464 (c_sizeof_or_alignof_type): Likewise.
8465 (c_add_case_label): Likewise.
8466 (c_do_switch_warnings): Likewise.
8467 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
8468
8469 2012-04-15 Jason Merrill <jason@redhat.com>
8470
8471 PR c++/52818
8472 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
8473 (C_STD_NAME): Distinguish between C++98 and C++11.
8474
8475 2012-04-11 Eric Botcazou <ebotcazou@adacore.com>
8476
8477 PR target/52624
8478 * c-common.h (uint16_type_node): Rename into...
8479 (c_uint16_type_node): ...this.
8480 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
8481 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
8482
8483 2012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
8484
8485 * c-common.c (warn_if_unused_value): Move definition to here.
8486 * c-common.h (warn_if_unused_value): Move declaration to here.
8487
8488 2012-03-23 William Bader <williambader@hotmail.com>
8489
8490 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
8491
8492 2012-03-20 Jason Merrill <jason@redhat.com>
8493
8494 * c-common.h (enum cxx_dialect): Add cxx1y.
8495 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
8496 test.
8497 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
8498 * c-opts.c (c_common_post_options): Likewise.
8499 (set_std_cxx1y): New.
8500 (c_common_handle_option): Call it.
8501 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
8502
8503 2012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
8504
8505 PR c++/14710
8506 * c.opt ([Wuseless-cast]): Add.
8507
8508 2012-03-16 Richard Guenther <rguenther@suse.de>
8509
8510 * c-pretty-print.c (pp_c_initializer_list): Adjust.
8511
8512 2012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
8513
8514 PR c++/44783
8515 * c.opt (ftemplate-backtrace-limit) Add.
8516
8517 2012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8518
8519 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
8520 handling.
8521 * c-pragma.c (handle_pragma_extern_prefix): Remove.
8522 (init_pragma): Don't register extern_prefix.
8523
8524 2012-03-12 Richard Guenther <rguenther@suse.de>
8525
8526 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
8527 (builtin_type_for_size): Likewise.
8528
8529 2012-02-13 Jakub Jelinek <jakub@redhat.com>
8530
8531 PR c++/52215
8532 * c-common.c (sync_resolve_params): Don't decide whether to convert
8533 or not based on TYPE_SIZE comparison, convert whenever arg_type
8534 is unsigned INTEGER_TYPE.
8535
8536 2012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
8537
8538 PR c/52118
8539 * c.opt ([Wunused-local-typedefs]): Fix description.
8540
8541 2012-01-24 Mike Stump <mikestump@comcast.net>
8542
8543 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
8544 exactly.
8545
8546 2012-01-18 Richard Guenther <rguenther@suse.de>
8547
8548 * c-opts.c (c_common_post_options): Reset LTO flags if
8549 we are about to generate a PCH.
8550
8551 2012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
8552
8553 PR c++/51777
8554 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
8555 use pp_unsigned_wide_integer.
8556
8557 2012-01-10 Richard Guenther <rguenther@suse.de>
8558
8559 PR middle-end/51806
8560 * c-opts.c (c_common_handle_option): Move -Werror handling
8561 to language independent code.
8562
8563 2012-01-05 Richard Guenther <rguenther@suse.de>
8564
8565 PR middle-end/51764
8566 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
8567 from common.opt.
8568
8569 2011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
8570
8571 PR c++/51316
8572 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
8573 of array types with an unknown bound.
8574
8575 2011-12-20 Joseph Myers <joseph@codesourcery.com>
8576
8577 * c-common.c (flag_isoc99): Update comment to refer to C11.
8578 (flag_isoc1x): Change to flag_isoc11.
8579 * c-common.h (flag_isoc99): Update comment to refer to C11.
8580 (flag_isoc1x): Change to flag_isoc11.
8581 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
8582 C11.
8583 * c-opts.c (set_std_c1x): Change to set_std_c11.
8584 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
8585 Call set_std_c11.
8586 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
8587 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
8588 * c.opt (std=c1x): Change to std=c11. Document as non-draft
8589 standard.
8590 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
8591 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
8592 (std=gnu1x): Make alias of std=gnu11.
8593
8594 2011-12-19 Jason Merrill <jason@redhat.com>
8595
8596 PR c++/51228
8597 * c-common.c (handle_transparent_union_attribute): Check the first
8598 field if the type is complete.
8599
8600 2011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
8601
8602 PR libstdc++/51365
8603 * c-common.c (RID_IS_FINAL): Add.
8604 * c-common.h (RID_IS_FINAL): Add.
8605
8606 2011-11-30 Iain Sandoe <iains@gcc.gnu.org>
8607
8608 * c.opt (fgnu-runtime): Provide full description.
8609 (fnext-runtime): Likewise.
8610 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
8611
8612 2011-11-28 Andrew MacLeod <amacleod@redhat.com>
8613
8614 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
8615 predefines in one place. Add LOCK_FREE predefines.
8616 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
8617 new func.
8618
8619 2011-11-24 Andrew MacLeod <amacleod@redhat.com>
8620
8621 PR c/51256
8622 * c-common.c (get_atomic_generic_size): Check for various error
8623 conditions
8624 (resolve_overloaded_atomic_exchange,
8625 resolve_overloaded_atomic_compare_exchange,
8626 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
8627 error_mark_node for error conditions.
8628
8629 2011-11-08 Richard Guenther <rguenther@suse.de>
8630
8631 PR middle-end/51010
8632 * c-pretty-print.c (pp_c_expression): Handle SSA_NAMEs.
8633
8634 2011-11-07 Richard Henderson <rth@redhat.com>
8635 Aldy Hernandez <aldyh@redhat.com>
8636 Torvald Riegel <triegel@redhat.com>
8637
8638 Merged from transactional-memory.
8639
8640 * c-common.c (handle_tm_wrap_attribute,
8641 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
8642 (struct c_common_reswords): Added __transaction* keywords.
8643 (struct c_common_attribute_table): Added transaction* and tm_regparm
8644 attributes.
8645 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
8646 masks.
8647 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
8648 find_tm_attribute): Declare.
8649
8650 2011-11-07 Jason Merrill <jason@redhat.com>
8651
8652 PR c++/35688
8653 * c-common.c, c-common.h: Revert yesterday's changes.
8654
8655 2011-11-06 Jason Merrill <jason@redhat.com>
8656
8657 PR c++/35688
8658 * c-common.c (decl_has_visibility_attr): Split out from...
8659 (c_determine_visibility): ...here.
8660 * c-common.h: Declare it.
8661
8662 2011-11-06 Joseph Myers <joseph@codesourcery.com>
8663
8664 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
8665 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
8666 type.
8667 (check_user_alignment): New. Split out of
8668 handle_aligned_attribute. Disallow integer constants with
8669 noninteger types. Conditionally allow zero.
8670 (handle_aligned_attribute): Use check_user_alignment.
8671 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
8672
8673 2011-11-06 Andrew MacLeod <amacleod@redhat.com>
8674 Richard Henderson <rth@redhat.com>
8675
8676 Merged from cxx-mem-model.
8677
8678 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
8679 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
8680 parameters that are the same type size.
8681 (get_atomic_generic_size): New. Find size of generic
8682 atomic function parameters and do typechecking.
8683 (add_atomic_size_parameter): New. Insert size into parameter list.
8684 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
8685 either __atomic_exchange_n or external library call.
8686 (resolve_overloaded_atomic_compare_exchange): Restructure
8687 __atomic_compare_exchange to either _n variant or external library call.
8688 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
8689 __atomic_load_n or an external library call.
8690 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
8691 __atomic_store_n or an external library call.
8692 (resolve_overloaded_builtin): Handle new __atomic builtins.
8693
8694 2011-11-04 Eric Botcazou <ebotcazou@adacore.com>
8695
8696 PR c++/50608
8697 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
8698 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
8699 <INDIRECT_REF>: Return the argument.
8700 <ARRAY_REF>: Remove special code for negative offset.
8701 Call fold_build_pointer_plus instead of size_binop.
8702 (fold_offsetof): Remove STOP_REF argument and adjust.
8703 * c-common.h (fold_offsetof_1): Declare.
8704 (fold_offsetof): Remove STOP_REF argument.
8705
8706 2011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
8707
8708 PR c++/50810
8709 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
8710 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
8711 Wnarrowing for C++0x and C++98.
8712 * c.opt ([Wnarrowing]): Update.
8713
8714 2011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
8715
8716 PR c++/44277
8717 * c.opt: Add Wzero-as-null-pointer-constant.
8718
8719 2011-10-31 Jason Merrill <jason@redhat.com>
8720
8721 * c.opt (-fdeduce-init-list): Off by default.
8722
8723 PR c++/50920
8724 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
8725 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
8726 and -Wc++11-compat.
8727 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
8728
8729 2011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
8730
8731 PR c++/30066
8732 * c.opt (fvisibility-inlines-hidden): Description change.
8733
8734 2011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
8735
8736 Implement C++11 user-defined literals.
8737 * c-common.c (build_userdef_literal): New.
8738 * c-common.def: New tree code.
8739 * c-common.h (tree_userdef_literal): New tree struct and accessors.
8740 * c-lex.c (interpret_float): Add suffix parm.
8741 (c_lex_with_flags): Build literal tokens.
8742
8743 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
8744
8745 PR c++/50841
8746 Revert:
8747 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
8748
8749 PR c++/50810
8750 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
8751 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
8752 Wnarrowing for C++0x and C++98.
8753 * c.opt ([Wnarrowing]): Update.
8754
8755 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
8756
8757 PR c++/50810
8758 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
8759 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
8760 Wnarrowing for C++0x and C++98.
8761 * c.opt ([Wnarrowing]): Update.
8762
8763 2011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
8764
8765 PR c++/45385
8766 * c-common.c (conversion_warning): Remove code looking for
8767 artificial operands.
8768
8769 2011-10-18 Dodji Seketeli <dodji@redhat.com>
8770
8771 PR bootstrap/50760
8772 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
8773 !NO_IMPLICIT_EXTERN_C.
8774
8775 2011-10-17 Michael Spertus <mike_spertus@symantec.com>
8776
8777 * c-common.c (c_common_reswords): Add __bases,
8778 __direct_bases.
8779 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
8780
8781 2011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
8782
8783 PR c++/50757
8784 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
8785
8786 2011-10-15 Tom Tromey <tromey@redhat.com>
8787 Dodji Seketeli <dodji@redhat.com>
8788
8789 * c.opt (fdebug-cpp): New option.
8790 * c-opts.c (c_common_handle_option): Handle the option.
8791 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
8792 output stream in parameter. Factorized from ...
8793 (maybe_print_line): ... this. Dump location debug information when
8794 -fdebug-cpp is in effect.
8795 (print_line_1): New static function. Takes an output stream in
8796 parameter. Factorized from ...
8797 (print_line): ... here. Dump location information when -fdebug-cpp
8798 is in effect.
8799 (scan_translation_unit): Dump location information when
8800 -fdebug-cpp is in effect.
8801
8802 2011-10-15 Tom Tromey <tromey@redhat.com>
8803 Dodji Seketeli <dodji@redhat.com>
8804
8805 * c.opt (ftrack-macro-expansion): New option. Handle it with and
8806 without argument.
8807 * c-opts.c (c_common_handle_option)<case
8808 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
8809 cases. Handle -ftrack-macro-expansion with and without argument.
8810
8811 2011-10-15 Tom Tromey <tromey@redhat.com>
8812 Dodji Seketeli <dodji@redhat.com>
8813
8814 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
8815 (print_line, cb_define, do_line_change): Adjust to avoid touching
8816 the internals of struct line_map. Use the public API instead.
8817 * c-pch.c (c_common_read_pch): Likewise.
8818 * c-lex.c (fe_file_change): Likewise.
8819
8820 2011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
8821
8822 PR c++/17212
8823 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
8824
8825 2011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
8826
8827 PR c++/33067
8828 * c-pretty-print.c (pp_c_floating_constant): Output
8829 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
8830
8831 2011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
8832
8833 * c-common.c (def_builtin_1): Delete old interface with two
8834 parallel arrays to hold standard builtin declarations, and replace
8835 it with a function based interface that can support creating
8836 builtins on the fly in the future. Change all uses, and poison
8837 the old names. Make sure 0 is not a legitimate builtin index.
8838 * c-omp.c (c_finish_omp_barrier): Ditto.
8839 (c_finish_omp_taskwait): Ditto.
8840 (c_finish_omp_flush): Ditto.
8841
8842 2011-10-11 Tristan Gingold <gingold@adacore.com>
8843
8844 * c.opt: (fallow-parameterless-variadic-functions): New.
8845
8846 2011-09-08 Dodji Seketeli <dodji@redhat.com>
8847
8848 PR c++/33255 - Support -Wunused-local-typedefs warning
8849 * c-common.h (struct c_language_function::local_typedefs): New
8850 field.
8851 (record_locally_defined_typedef, maybe_record_typedef_use)
8852 (maybe_warn_unused_local_typedefs): Declare new functions.
8853 * c-common.c (record_locally_defined_typedef)
8854 (maybe_record_typedef_use)
8855 (maybe_warn_unused_local_typedefs): Define new functions.
8856 * c.opt: Declare new -Wunused-local-typedefs flag.
8857
8858 2011-09-06 Eric Botcazou <ebotcazou@adacore.com>
8859
8860 PR middle-end/50266
8861 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
8862 computations.
8863
8864 2011-09-05 Richard Guenther <rguenther@suse.de>
8865
8866 * c-common.c (complete_array_type): Use ssize_int (-1) instead
8867 of integer_minus_one_node for empty array upper bounds.
8868
8869 2011-08-28 Dodji Seketeli <dodji@redhat.com>
8870
8871 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
8872 it's the first time it's being called on this main TU.
8873
8874 2011-08-24 Richard Guenther <rguenther@suse.de>
8875
8876 PR c/49396
8877 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
8878
8879 2011-08-22 Gabriel Charette <gchare@google.com>
8880
8881 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
8882 defined in cpp_init_builtins and c_cpp_builtins.
8883
8884 2011-08-19 Joseph Myers <joseph@codesourcery.com>
8885
8886 * c-common.c (c_common_reswords): Add __builtin_complex.
8887 * c-common.h (RID_BUILTIN_COMPLEX): New.
8888
8889 2011-08-18 Joseph Myers <joseph@codesourcery.com>
8890
8891 * c-common.c (c_common_reswords): Add _Noreturn.
8892 (keyword_is_function_specifier): Handle RID_NORETURN.
8893 * c-common.h (RID_NORETURN): New.
8894
8895 2011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
8896
8897 * c-common.c (unsafe_conversion_p): New function. Check if it is
8898 unsafe to convert an expression to the type.
8899 (conversion_warning): Adjust, use unsafe_conversion_p.
8900 * c-common.h (unsafe_conversion_p): New function declaration.
8901
8902 2011-08-02 Jakub Jelinek <jakub@redhat.com>
8903
8904 * c-common.h (c_finish_omp_atomic): Adjust prototype.
8905 (c_finish_omp_taskyield): New prototype.
8906 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
8907 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
8908 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
8909 or RHS1 have side-effects, evaluate those too in the right spot,
8910 if it is a decl and LHS is also a decl, error out if they
8911 aren't the same.
8912 (c_finish_omp_taskyield): New function.
8913 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
8914 * c-pragma.c (omp_pragmas): Add taskyield.
8915 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
8916 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
8917 PRAGMA_OMP_CLAUSE_MERGEABLE.
8918
8919 2011-07-25 Dodji Seketeli <dodji@redhat.com>
8920
8921 * c-common.h (set_underlying_type): Remove parm name from
8922 declaration.
8923
8924 2011-07-25 Romain Geissler <romain.geissler@gmail.com>
8925
8926 * c-pretty-print.h: Search c-common.h in c-family.
8927
8928 2011-07-22 Jason Merrill <jason@redhat.com>
8929
8930 PR c++/49793
8931 * c.opt (Wnarrowing): New.
8932
8933 PR c++/30112
8934 * c-common.h: Declare c_linkage_bindings.
8935 * c-pragma.c (handle_pragma_redefine_extname): Use it.
8936
8937 PR c++/49813
8938 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
8939 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
8940 as flag_isoc99 for 'restrict'.
8941 (pp_c_specifier_qualifier_list): Likewise for _Complex.
8942
8943 2011-07-21 Ian Lance Taylor <iant@google.com>
8944
8945 PR middle-end/49705
8946 * c-common.c (c_disable_warnings): New static function.
8947 (c_enable_warnings): New static function.
8948 (c_fully_fold_internal): Change local unused_p to bool. Call
8949 c_disable_warnings and c_enable_warnings rather than change
8950 c_inhibit_evaluation_warnings.
8951
8952 2011-07-20 Jason Merrill <jason@redhat.com>
8953
8954 PR c++/6709 (DR 743)
8955 PR c++/42603 (DR 950)
8956 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
8957 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
8958 (CPP_DECLTYPE): New.
8959 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
8960
8961 2011-07-19 Richard Guenther <rguenther@suse.de>
8962
8963 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
8964 * c-omp.c (c_finish_omp_for): Likewise.
8965
8966 2011-07-12 Eric Botcazou <ebotcazou@adacore.com>
8967
8968 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
8969 body on the next line.
8970
8971 2011-07-08 Jason Merrill <jason@redhat.com>
8972
8973 PR c++/45437
8974 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
8975
8976 PR c++/49673
8977 * c-common.c (c_apply_type_quals_to_decl): Don't check
8978 TYPE_NEEDS_CONSTRUCTING.
8979
8980 2011-07-06 Richard Guenther <rguenther@suse.de>
8981
8982 * c-common.c (c_common_nodes_and_builtins):
8983 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
8984
8985 2011-07-05 Richard Guenther <rguenther@suse.de>
8986
8987 * c-common.c (c_common_nodes_and_builtins): Build all common
8988 tree nodes first.
8989
8990 2011-06-27 Jakub Jelinek <jakub@redhat.com>
8991
8992 * c-common.h (c_tree_chain_next): New static inline function.
8993
8994 * c-common.c (check_builtin_function_arguments): Handle
8995 BUILT_IN_ASSUME_ALIGNED.
8996
8997 2011-06-21 Andrew MacLeod <amacleod@redhat.com>
8998
8999 * c-common.c: Add sync_ or SYNC__ to builtin names.
9000 * c-omp.c: Add sync_ or SYNC__ to builtin names.
9001
9002 2011-06-20 Pierre Vittet <piervit@pvittet.com>
9003
9004 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
9005 handler.
9006 (gen_pragma_handler): New union.
9007 (internal_pragma_handler): New type.
9008 (c_register_pragma_with_data)
9009 (c_register_pragma_with_expansion_and_data): New functions.
9010
9011 * c-pragma.c (registered_pragmas, c_register_pragma_1)
9012 (c_register_pragma, c_register_pragma_with_expansion)
9013 (c_invoke_pragma_handler): Changed to work with
9014 internal_pragma_handler.
9015 (c_register_pragma_with_data)
9016 (c_register_pragma_with_expansion_and_data): New functions.
9017
9018 2011-06-14 Joseph Myers <joseph@codesourcery.com>
9019
9020 * c-common.c: Include common/common-target.h.
9021 (handle_section_attribute): Use
9022 targetm_common.have_named_sections.
9023 * c-cppbuiltin.c: Include common/common-target.h.
9024 (c_cpp_builtins): Use targetm_common.except_unwind_info.
9025
9026 2011-06-10 Richard Guenther <rguenther@suse.de>
9027
9028 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
9029 to print a IDENTIFIER_NODE.
9030
9031 2011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9032 Joseph Myers <joseph@codesourcery.com>
9033
9034 * c.opt (fbuilding-libgcc): New option.
9035 * c-cppbuiltin.c (c_cpp_builtins): Define
9036 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
9037
9038 2011-06-07 Jason Merrill <jason@redhat.com>
9039
9040 * c-common.c (max_tinst_depth): Lower default to 900.
9041
9042 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
9043
9044 2011-06-07 Richard Guenther <rguenther@suse.de>
9045
9046 * c-common.c (c_common_nodes_and_builtins): Do not set
9047 size_type_node or call set_sizetype.
9048
9049 2011-06-07 Dodji Seketeli <dodji@redhat.com>
9050
9051 PR debug/49130
9052 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
9053 type when using pointer comparison to compare types.
9054
9055 2011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
9056
9057 * c.opt: Add -Wdelete-non-virtual-dtor.
9058 * c-opts.c (c_common_handle_option): Include it in -Wall.
9059
9060 2011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
9061
9062 PR bootstrap/49190
9063
9064 Revert:
9065 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
9066
9067 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
9068 not tree_common.
9069
9070 2011-05-27 Jakub Jelinek <jakub@redhat.com>
9071
9072 PR c++/49165
9073 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
9074 C++ don't call c_common_truthvalue_conversion on void type arms.
9075
9076 2011-05-27 Nathan Froyd <froydnj@codesourcery.com>
9077
9078 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
9079 (stmt_list_stack): Define.
9080 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
9081 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
9082
9083 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
9084
9085 * c-common.c (warning_candidate_p): Check for BLOCKs.
9086
9087 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
9088
9089 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
9090 not tree_common.
9091
9092 2011-05-25 Jakub Jelinek <jakub@redhat.com>
9093
9094 * c-common.c (def_fn_type): Remove extra va_end.
9095
9096 2011-05-23 Jason Merrill <jason@redhat.com>
9097
9098 PR c++/48106
9099 * c-common.c (c_common_get_narrower): New.
9100 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
9101
9102 2011-05-23 Nathan Froyd <froydnj@codesourcery.com>
9103
9104 * c-common.h (check_function_arguments): Tweak prototype of
9105 check_function_arguments.
9106 * c-common.c (check_function_arguments): Likewise. Adjust
9107 calls to check_function_nonnull, check_function_format, and
9108 check_function_sentinel.
9109 (check_function_sentinel): Take a FUNCTION_TYPE rather than
9110 separate attributes and typelist arguments. Use
9111 FOREACH_FUNCTION_ARGS to iterate over argument types.
9112
9113 2011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
9114
9115 * c-common.c (c_common_reswords): Reorder.
9116 * c-common.h (rid): Likewise.
9117
9118 2011-05-10 Nathan Froyd <froydnj@codesourcery.com>
9119
9120 * c-common.c (def_fn_type): Don't call build_function_type, call
9121 build_function_type_array or build_varargs_function_type_array
9122 instead.
9123 (c_common_nodes_and_builtins): Likewise.
9124
9125 2011-05-05 Nathan Froyd <froydnj@codesourcery.com>
9126
9127 * c-common.c (c_add_case_label): Omit the loc argument to
9128 build_case_label.
9129 * c-common.h (build_case_label): Remove.
9130 * c-semantics.c (build_case_label): Remove.
9131
9132 2011-05-05 Joseph Myers <joseph@codesourcery.com>
9133
9134 * c-objc.h (objc_start_method_definition): Update prototype.
9135 * stub-objc.c (objc_start_method_definition): Add extra parameter.
9136
9137 2011-05-04 Nathan Froyd <froydnj@codesourcery.com>
9138
9139 * c-common.c (check_main_parameter_types): Reindent. Don't use
9140 TYPE_ARG_TYPES directly.
9141 (handle_nonnull_attribute): Likewise.
9142 (sync_resolve_params): Likewise.
9143 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
9144 to check_format_string.
9145 (handle_format_attribute): Likewise.
9146 (check_format_string): Take a function type to examine instead of
9147 a type list. Use a function_arg_iterator to step through argument
9148 types.
9149
9150 2011-05-04 Richard Guenther <rguenther@suse.de>
9151
9152 * c-common.c (fix_string_type): Use size_int for index type bounds.
9153 (start_fname_decls): Do not pass NULL to build_int_cst.
9154 (c_init_attributes): Likewise.
9155 * c-lex.c (c_lex_with_flags): Likewise.
9156
9157 2011-04-27 Jason Merrill <jason@redhat.com>
9158
9159 * c-common.c (make_tree_vector_from_list): New.
9160 * c-common.h: Declare it.
9161
9162 2011-04-26 Richard Guenther <rguenther@suse.de>
9163
9164 PR preprocessor/48248
9165 * c-ppoutput.c (maybe_print_line): Always optimize newlines
9166 for output size with -P.
9167
9168 2011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
9169
9170 * c-common.c (struct c_common_resword): Add __underlying_type.
9171 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
9172
9173 2011-04-20 Jim Meyering <meyering@redhat.com>
9174
9175 * c-format.c (init_dollar_format_checking): Remove useless
9176 if-before-free.
9177
9178 2011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
9179
9180 * c-objc.h (objc_get_interface_ivars): Removed.
9181 (objc_detect_field_duplicates): New.
9182 * stub-objc.c: Likewise.
9183
9184 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
9185
9186 * stub-objc.c (objc_declare_protocols): Renamed to
9187 objc_declare_protocol.
9188 * c-objc.h: Likewise.
9189
9190 2011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
9191
9192 * stub-objc.c (objc_declare_class): Updated argument name.
9193
9194 2011-04-12 Nathan Froyd <froydnj@codesourcery.com>
9195
9196 * c-common.h (c_common_init_ts): Declare.
9197 * c-common.c (c_common_init_ts): Define.
9198
9199 2011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
9200
9201 * c-objc.h (objc_build_message_expr): Updated prototype.
9202 * stub-objc.c (objc_build_message_expr): Likewise.
9203
9204 2011-04-12 Martin Jambor <mjambor@suse.cz>
9205
9206 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
9207 of cgraph_node.
9208
9209 2011-04-11 Richard Guenther <rguenther@suse.de>
9210
9211 * c-common.c (complete_array_type): Build a range type of
9212 proper type.
9213
9214 2011-04-08 Nathan Froyd <froydnj@codesourcery.com>
9215
9216 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
9217 (handle_type_generic_attribute): Likewise.
9218
9219 2011-04-07 Jason Merrill <jason@redhat.com>
9220
9221 PR c++/48450
9222 * c-common.c (c_common_truthvalue_conversion): Don't ignore
9223 conversion from C++0x scoped enum.
9224
9225 2011-04-06 Joseph Myers <joseph@codesourcery.com>
9226
9227 * c-target-def.h: New file.
9228 * c-target.def: New file.
9229 * c-target.h: New file.
9230 * c-common.c (targetcm): Don't define here.
9231 * c-common.h (default_handle_c_option): Declare.
9232 * c-format.c: Include c-target.h instead of target.h.
9233 * c-opts.c: Include c-target.h instead of target.h. Explicitly
9234 include tm.h.
9235 (default_handle_c_option): Move from targhooks.c.
9236
9237 2011-03-29 Jakub Jelinek <jakub@redhat.com>
9238
9239 PR preprocessor/48248
9240 * c-ppoutput.c (print): Add src_file field.
9241 (init_pp_output): Initialize it.
9242 (maybe_print_line): Don't optimize by adding up to 8 newlines
9243 if map->to_file and print.src_file are different file.
9244 (print_line): Update print.src_file.
9245
9246 2011-03-25 Kai Tietz <ktietz@redhat.com>
9247
9248 * c-ada-spec.c (compare_comment): Use filename_cmp
9249 instead of strcmp for filename.
9250
9251 2011-03-25 Jeff Law <law@redhat.com>
9252
9253 * c-common.c (def_fn_type): Add missing va_end.
9254
9255 2011-03-25 Jason Merrill <jason@redhat.com>
9256
9257 * c.opt: Add -std=c++03.
9258
9259 2011-03-22 Eric Botcazou <ebotcazou@adacore.com>
9260
9261 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
9262
9263 2011-03-17 Kai Tietz <ktietz@redhat.com>
9264
9265 PR target/12171
9266 * c-pretty-print.c (pp_c_specifier_qualifier_list):
9267 Display allowed attributes for function pointer types.
9268 (pp_c_attributes_display): New function to display
9269 attributes having affects_type_identity flag set to true.
9270 * c-pretty-print.h (pp_c_attributes_display): New prototype.
9271
9272 * c-common.c (c_common_attribute_table):
9273 Add new element.
9274 (c_common_format_attribute_table): Likewise.
9275
9276 2011-03-18 Jason Merrill <jason@redhat.com>
9277
9278 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
9279 * c-common.h: Don't declare it here.
9280 * c-common.c: Or define it here.
9281 * c-opts.c (c_common_handle_option): Or set it here.
9282
9283 PR c++/35315
9284 * c-common.c (handle_transparent_union_attribute): Don't
9285 make a duplicate type in C++.
9286
9287 2011-03-15 Jason Merrill <jason@redhat.com>
9288
9289 * c-common.c (max_constexpr_depth): New.
9290 * c-common.h: Declare it.
9291 * c-opts.c (c_common_handle_option): Set it.
9292 * c.opt (fconstexpr-depth): New option.
9293
9294 2011-03-11 Jason Merrill <jason@redhat.com>
9295
9296 * c-common.c (attribute_takes_identifier_p): Add missing const.
9297
9298 PR c++/46803
9299 * c-common.c (attribute_takes_identifier_p): Assume that an
9300 unknown attribute takes an identifier.
9301
9302 2011-03-07 Nathan Froyd <froydnj@codesourcery.com>
9303
9304 PR c/47786
9305 * c-common.c (c_type_hash): Call list_length instead of iterating
9306 through DECL_CHAIN. Rename 'i' to 'n_elements'.
9307
9308 2011-02-19 Jakub Jelinek <jakub@redhat.com>
9309
9310 PR c/47809
9311 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
9312
9313 2011-02-17 Iain Sandoe <iains@gcc.gnu.org>
9314
9315 * c.opt (fobjc-abi-version=) New.
9316 (fobjc-nilcheck): New.
9317
9318 2011-02-03 Nathan Froyd <froydnj@codesourcery.com>
9319
9320 PR c++/46890
9321 * c-common.h (keyword_is_decl_specifier): Declare.
9322 * c-common.c (keyword_is_decl_specifier): Define.
9323 (keyword_is_function_specifier): New function.
9324
9325 2011-01-26 Jakub Jelinek <jakub@redhat.com>
9326
9327 PR c/47473
9328 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
9329 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
9330 REAL_TYPE.
9331
9332 2011-01-26 Arnaud Charlet <charlet@adacore.com>
9333
9334 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
9335
9336 2011-01-26 Jakub Jelinek <jakub@redhat.com>
9337
9338 PR pch/47430
9339 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
9340 after init_c_lex if pch_file is set.
9341
9342 2011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
9343
9344 PR c++/43601
9345 * c.opt (-fkeep-inline-dllexport): New switch.
9346
9347 2011-01-12 Richard Guenther <rguenther@suse.de>
9348
9349 PR middle-end/32511
9350 * c-common.c (handle_weak_attribute): Warn instead of error
9351 on declaring an inline function weak.
9352
9353 2011-01-05 Tom Tromey <tromey@redhat.com>
9354
9355 * c-common.h (lvalue_error): Update.
9356 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
9357 not error.
9358
9359 2010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
9360
9361 PR objc/47075
9362 * c-objc.h (objc_finish_message_expr): Added argument to
9363 prototype.
9364
9365 2010-12-22 Nathan Froyd <froydnj@codesourcery.com>
9366
9367 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
9368 Use prototype_p.
9369
9370 2010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
9371
9372 * c-objc.h (objc_maybe_warn_exceptions): New.
9373 * stub-objc.c (objc_maybe_warn_exceptions): New.
9374
9375 2010-12-10 Nathan Froyd <froydnj@codesourcery.com>
9376
9377 * c-common.h (readonly_error): Declare.
9378 * c-common.c (readonly_error): Define.
9379
9380 2010-12-09 Nathan Froyd <froydnj@codesourcery.com>
9381
9382 * c-common.h (invalid_indirection_error): Declare.
9383 * c-common.c (invalid_indirection_error): Define.
9384
9385 2010-12-03 Richard Guenther <rguenther@suse.de>
9386
9387 PR c/46745
9388 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
9389 (pp_c_unary_expression): Likewise.
9390 (pp_c_expression): Likewise.
9391
9392 2010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
9393
9394 * c-common.h (objc_finish_function): New.
9395 (objc_non_volatilized_type): Removed.
9396 (objc_type_quals_match): Removed.
9397 * stub-objc.c (objc_finish_function): New.
9398 (objc_non_volatilized_type): Removed.
9399 (objc_type_quals_match): Removed.
9400
9401 2010-11-30 Joseph Myers <joseph@codesourcery.com>
9402
9403 * c-common.h (parse_optimize_options): Declare.
9404 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
9405 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
9406
9407 2010-11-29 Joseph Myers <joseph@codesourcery.com>
9408
9409 * c-opts.c (check_deps_environment_vars): Use getenv instead of
9410 GET_ENVIRONMENT.
9411 * c-pch.c (O_BINARY): Don't define here.
9412 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
9413
9414 2010-11-25 Joseph Myers <joseph@codesourcery.com>
9415
9416 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
9417 targetm.except_unwind_info.
9418
9419 2010-11-23 Joseph Myers <joseph@codesourcery.com>
9420
9421 * c-opts.c (c_common_handle_option): Pass location to
9422 set_struct_debug_option.
9423
9424 2010-11-23 Joseph Myers <joseph@codesourcery.com>
9425
9426 * c-common.c (visibility_options): Move from ../opts.c.
9427 * c-common.h (struct visibility_flags, visibility_options):
9428 Declare here.
9429 * c-opts.c (finish_options): Rename to c_finish_options.
9430 (c_common_init): Update call to finish_options.
9431
9432 2010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
9433
9434 PR objc/34033
9435 * c-lex.c (lex_string): Check that each string in an Objective-C
9436 string concat sequence starts with either one or zero '@', and
9437 that there are no spurious '@' signs at the end.
9438
9439 2010-11-20 Joseph Myers <joseph@codesourcery.com>
9440
9441 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
9442 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
9443 HANDLE_PRAGMA_VISIBILITY.
9444 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
9445 HANDLE_PRAGMA_VISIBILITY): Don't define.
9446 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
9447
9448 2010-11-20 Nathan Froyd <froydnj@codesourcery.com>
9449
9450 PR c++/16189
9451 PR c++/36888
9452 PR c++/45331
9453 * c-common.h (keyword_begins_type_specifier): Declare.
9454 (keyword_is_storage_class_specifier): Declare.
9455 (keyword_is_type_qualifier): Declare.
9456 * c-common.c (keyword_begins_type_specifier): New function.
9457 (keyword_is_storage_class_specifier): New function.
9458 (keyword_is_type_qualifier): Declare.
9459
9460 2010-11-19 Joseph Myers <joseph@codesourcery.com>
9461
9462 PR c/46547
9463 * c-common.c (in_late_binary_op): Define.
9464 (c_common_truthvalue_conversion): Check in_late_binary_op before
9465 calling c_save_expr.
9466 * c-common.h (in_late_binary_op): Declare.
9467
9468 2010-11-19 Joseph Myers <joseph@codesourcery.com>
9469
9470 * c-opts.c (c_common_handle_option): Update calls to
9471 set_struct_debug_option.
9472
9473 2010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
9474
9475 * c-common.h (objc_declare_protocols): Added additional argument.
9476 * stub-objc.c (objc_declare_protocol): Same change.
9477
9478 2010-11-18 Nathan Froyd <froydnj@codesourcery.com>
9479
9480 PR c/33193
9481 * c-common.h (build_real_imag_expr): Declare.
9482 * c-semantics.c (build_real_imag_expr): Define.
9483
9484 2010-11-17 Joseph Myers <joseph@codesourcery.com>
9485
9486 * c-opts.c (c_common_parse_file): Take no arguments.
9487 * c-common.h (c_common_parse_file): Update prototype.
9488
9489 2010-11-16 Jakub Jelinek <jakub@redhat.com>
9490
9491 PR c++/46401
9492 * c-common.c (warning_candidate_p): Don't track non-const calls
9493 or STRING_CSTs.
9494
9495 2010-11-15 Ian Lance Taylor <iant@google.com>
9496
9497 * c-lex.c (init_c_lex): Set macro debug callbacks if
9498 flag_dump_go_spec is set.
9499
9500 2010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
9501
9502 * c-common.h (objc_build_incr_expr_for_property_ref): New.
9503 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
9504
9505 2010-11-15 Nathan Froyd <froydnj@codesourcery.com>
9506
9507 PR preprocessor/45038
9508 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
9509 dialects.
9510
9511 2010-11-12 Joseph Myers <joseph@codesourcery.com>
9512
9513 * c-common.h (c_family_lang_mask): Declare.
9514 * c-opts.c (c_family_lang_mask): Make extern.
9515 * c-pragma.c (handle_pragma_diagnostic): Use
9516 control_warning_option.
9517
9518 2010-11-12 Joseph Myers <joseph@codesourcery.com>
9519
9520 * c-common.c (parse_optimize_options): Update call to
9521 decode_options.
9522 * c-common.h (c_common_handle_option): Update prototype.
9523 * c-opts.c (c_common_handle_option): Take location_t parameter and
9524 pass it to other functions.
9525
9526 2010-11-11 Joseph Myers <joseph@codesourcery.com>
9527
9528 * c-opts.c (warning_as_error_callback): Remove.
9529 (c_common_initialize_diagnostics): Don't call
9530 register_warning_as_error_callback.
9531 (c_common_handle_option): Handle -Werror=normalized= here.
9532
9533 2010-11-10 Joseph Myers <joseph@codesourcery.com>
9534
9535 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
9536 in diagnostic.
9537 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
9538 letter.
9539 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
9540 Remove trailing '.' from diagnostics.
9541 * c.opt (Wwrite-strings_: Avoid '`' in help text.
9542
9543 2010-11-10 Joseph Myers <joseph@codesourcery.com>
9544
9545 * c-common.c (parse_optimize_options): Pass global_dc to
9546 decode_options.
9547 * c-opts.c (c_common_handle_option): Pass &global_options to
9548 set_Wstrict_aliasing.
9549 * c.opt (v): Don't mark Common or document here.
9550
9551 2010-11-06 Iain Sandoe <iains@gcc.gnu.org>
9552
9553 PR target/44981
9554 * c-format.c (format_type): New type gcc_objc_string_format_type.
9555 (valid_stringptr_type_p): New.
9556 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
9557 (check_format_string): Pass expected type, use
9558 valid_stringptr_type_p (), check that the format string types are
9559 consistent with the format specification.
9560 (decode_format_attr): Warn if NSString is used outside objective-c.
9561 (format_types_orig): Add NSString.
9562 (format_name): New.
9563 (format_flags): New.
9564 (check_format_arg): Handle format strings requiring an external parser.
9565 first_target_format_type: New variable.
9566 (handle_format_attribute): Set up first_target_format_type, pass the
9567 expected format arg string type to check_format_string().
9568 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
9569 * stub-objc.c (objc_string_ref_type_p): New.
9570 (objc_check_format_arg): New.
9571
9572 2010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
9573
9574 Fixed using the Objective-C 2.0 dot-syntax with class names.
9575 * c-common.h (objc_build_class_component_ref): New.
9576 * stub-objc.c (objc_build_class_component_ref): New.
9577
9578 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
9579
9580 * c.opt (Wproperty-assign-default): New option.
9581
9582 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
9583
9584 Implemented -fobjc-std=objc1 flag.
9585 * c.opt (fobjc-std=objc1): New option.
9586
9587 2010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
9588
9589 Implemented format and noreturn attributes for Objective-C methods.
9590 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
9591 attribute for Objective-C methods.
9592
9593 2010-10-31 Jason Merrill <jason@redhat.com>
9594
9595 * c-common.c (conversion_warning, warn_for_collisions_1): Use
9596 EXPR_LOC_OR_HERE.
9597
9598 2010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
9599
9600 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
9601 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
9602 (objc_add_property_declaration): Removed arguments for copies and
9603 ivar.
9604 (objc_build_getter_call): Renamed to
9605 objc_maybe_build_component_ref.
9606 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
9607 (objc_is_property_ref): New.
9608 * c-common.c (c_common_reswords): Removed copies and ivar.
9609 * stub-objc.c (objc_add_property_declaration): Removed arguments
9610 for copies and ivar.
9611 (objc_build_getter_call): Renamed to
9612 objc_maybe_build_component_ref.
9613 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
9614 (objc_is_property_ref): New.
9615
9616 2010-10-29 Arnaud Charlet <charlet@adacore.com>
9617 Matthew Gingell <gingell@adacore.com>
9618
9619 * c-ada-spec.c (separate_class_package): New function.
9620 (pp_ada_tree_identifier): Prefix references to C++ classes with the
9621 name of their enclosing package.
9622 (print_ada_declaration): Use separate_class_package.
9623
9624 2010-10-27 Jason Merrill <jason@redhat.com>
9625
9626 * c-common.c (c_common_reswords): Add __is_literal_type.
9627 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
9628
9629 * c-common.c (check_case_value): Remove special C++ code.
9630
9631 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
9632
9633 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
9634 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
9635 and RID_LAST_PATTR.
9636 (objc_add_property_declaration): Added additional arguments.
9637 (objc_property_attribute_kind): Removed.
9638 (objc_set_property_attr): Removed.
9639 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
9640 copy and nonatomic.
9641 * stub-objc.c (objc_add_property_declaration): Added additional
9642 arguments.
9643 (objc_set_property_attr): Removed.
9644
9645 2010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
9646
9647 * c-common.h (objc_add_property_variable): Renamed to
9648 objc_add_property_declaration. Added location argument.
9649 * stub-objc.c (objc_add_property_variable): Same change.
9650
9651 2010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
9652
9653 * c-common.h (objc_maybe_printable_name): New.
9654 * stub-objc.c (objc_maybe_printable_name): New.
9655
9656 2010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
9657 Andrew Pinski <pinskia@gmail.com>
9658
9659 * c-common.h (c_common_mark_addressable_vec): Declare.
9660 * c-common.c (c_common_mark_addressable_vec): New function.
9661
9662 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
9663
9664 * c-common.h (objc_set_method_type): Removed.
9665 (objc_add_method_declaration): Added boolean argument.
9666 (objc_start_method_definition): Same change.
9667 (objc_build_method_signature): Same change.
9668 * stub-objc.c (objc_set_method_type): Removed.
9669 (objc_add_method_declaration): Added boolean argument.
9670 (objc_start_method_definition): Same change.
9671 (objc_build_method_signature): Same change.
9672
9673 2010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
9674
9675 * c-common.h (finish_file): Removed.
9676 (objc_write_global_declarations): New.
9677 * c-opts.c (c_common_parse_file): Do not call finish_file.
9678 * stub-objc.c (objc_write_global_declarations): New.
9679
9680 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
9681
9682 Implemented parsing @synthesize and @dynamic for
9683 Objective-C/Objective-C++.
9684 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
9685 (objc_add_synthesize_declaration): New.
9686 (objc_add_dynamic_declaration): New.
9687 * c-common.c (c_common_reswords): Add synthesize and dynamic.
9688 * stub-objc.c (objc_add_synthesize_declaration): New.
9689 (objc_add_dynamic_declaration): New.
9690
9691 2010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
9692
9693 PR target/46041
9694 * c-cppbuiltin.c (mode_has_fma): Move function here from
9695 builtins.c. Don't use the fma optab, instead just use the
9696 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
9697 using -save-temps.
9698
9699 2010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
9700
9701 Merge from 'apple/trunk' branch on FSF servers.
9702
9703 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
9704
9705 Radar 4330422
9706 * c-common.h (objc_non_volatilized_type): New declaration
9707 * stub-objc.c (objc_non_volatilized_type): New stub.
9708
9709 2010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
9710
9711 Merge from 'apple/trunk' branch on FSF servers.
9712
9713 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
9714
9715 Radar 4133425
9716 * c-common.h (objc_diagnose_private_ivar): New decl.
9717 * stub-objc.c (objc_diagnose_private_ivar): New stub.
9718
9719 2010-10-17 Iain Sandoe <iains@gcc.gnu.org>
9720
9721 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
9722 * c-common.h (enum rid): Add RID_AT_PACKAGE.
9723 (objc_ivar_visibility_kind): New enum.
9724 (objc_set_visibility): Adjust prototype to use visibility enum.
9725 * stub-objc.c (objc_set_visibility): Adjust stub to use
9726 visibility enum.
9727
9728 2010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
9729
9730 * c-cppbuiltin.c (builtin_define_float_constants): Emit
9731 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
9732 has the appropriate fma builtins.
9733 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
9734
9735 2010-10-14 Iain Sandoe <iains@gcc.gnu.org>
9736
9737 merge from FSF apple 'trunk' branch.
9738 2006 Fariborz Jahanian <fjahanian@apple.com>
9739
9740 Radars 4436866, 4505126, 4506903, 4517826
9741 * c-common.c (c_common_resword): Define @property and its attributes.
9742 * c-common.h: Define property attribute enum entries.
9743 (OBJC_IS_PATTR_KEYWORD): New.
9744 (objc_property_attribute_kind): New enum.
9745 Declare objc_set_property_attr (), objc_add_property_variable (),
9746 objc_build_getter_call () and objc_build_setter_call ().
9747 * stub-objc.c (objc_set_property_attr): New stub.
9748 (objc_add_property_variable): Likewise.
9749 (objc_build_getter_call): Likewise.
9750 (objc_build_setter_call) Likewise.
9751
9752 2010-10-13 Iain Sandoe <iains@gcc.gnu.org>
9753
9754 merge from FSF apple 'trunk' branch.
9755 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
9756
9757 Radar 3803157 (method attributes)
9758 * c-common.c (handle_deprecated_attribute): Recognize
9759 objc methods as valid declarations.
9760 * c-common.h: Declare objc_method_decl ().
9761 * stub-objc.c (objc_method_decl): New stub.
9762
9763 2010-10-08 Joseph Myers <joseph@codesourcery.com>
9764
9765 * c-common.c (parse_optimize_options): Call
9766 decode_cmdline_options_to_array_default_mask before
9767 decode_options. Update arguments to decode_options.
9768 * c-common.h (c_common_init_options_struct): Declare.
9769 * c-opts.c (c_common_init_options_struct): New. Split out from
9770 c_common_init_options.
9771
9772 2010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
9773
9774 Implemented fast enumeration for Objective-C.
9775 * c-common.h (objc_finish_foreach_loop): New.
9776 * stub-objc.c (objc_finish_foreach_loop): New.
9777
9778 2010-10-05 Joseph Myers <joseph@codesourcery.com>
9779
9780 * c-common.h (struct diagnostic_context): Don't declare here.
9781 (c_common_initialize_diagnostics): Declare using
9782 diagnostic_context typedef.
9783 * c-opts.c (c_common_handle_option): Pass global_dc to
9784 handle_generated_option.
9785
9786 2010-10-04 Joseph Myers <joseph@codesourcery.com>
9787
9788 * c-opts.c (c_common_handle_option): Pass &global_options_set to
9789 handle_generated_option.
9790
9791 2010-10-03 Ian Lance Taylor <iant@google.com>
9792
9793 * c.opt (-fplan9-extensions): New option.
9794
9795 2010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
9796
9797 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
9798 Remove.
9799 (c_cpp_builtins): Call functions from cppbuiltin.c instead
9800 of duplicating code.
9801
9802 2010-09-30 Iain Sandoe <iains@gcc.gnu.org>
9803
9804 * c-common.c: Add two new entries for @optional
9805 and @required keywords.
9806
9807 merge from FSF 'apple/trunk' branch.
9808 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
9809
9810 Radar 4386773
9811 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
9812 objective-c keywords.
9813 (objc_set_method_opt): New declaration.
9814 * stub-objc.c (objc_set_method_opt): New stub.
9815
9816 2010-09-30 Joseph Myers <joseph@codesourcery.com>
9817
9818 * c-common.c (handle_optimize_attribute): Pass &global_options to
9819 cl_optimization_save and cl_optimization_restore.
9820 * c-opts.c (c_common_handle_option): Pass &global_options to
9821 handle_generated_option.
9822 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
9823 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
9824 &global_options to cl_optimization_restore.
9825
9826 2010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
9827
9828 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
9829 Objective-C/Objective-C++ keywords.
9830
9831 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
9832
9833 Merge from 'apple/trunk' branch on FSF servers.
9834
9835 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
9836
9837 Radar 4281748
9838 * c-common.h (objc_check_global_decl): New declaration.
9839 * stub-objc.c (objc_check_global_decl): New stub.
9840
9841 2010-09-29 Joseph Myers <joseph@codesourcery.com>
9842
9843 * c.opt: Don't use VarExists.
9844
9845 2010-09-29 Joseph Myers <joseph@codesourcery.com>
9846
9847 * c-common.c (c_cpp_error): Update names of diagnostic_context
9848 members.
9849 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
9850 cl_optimization members.
9851 * c-opts.c (warning_as_error_callback, c_common_handle_option,
9852 sanitize_cpp_opts, finish_options): Update names of cpp_options
9853 members.
9854
9855 2010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
9856
9857 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
9858 (objc_is_reserved_word): Removed.
9859 * c-common.c: Updated comments.
9860 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
9861 objc_is_reserved_word.
9862 * stub-objc.c (objc_is_reserved_word): Removed.
9863
9864 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
9865
9866 * c-common.h (objc_add_method_declaration): Adjust prototype to
9867 include attributes.
9868 (objc_start_method_definition): Likewise.
9869 (objc_build_keyword_decl): Likewise.
9870 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
9871 (objc_start_method_definition): Likewise.
9872 (objc_build_keyword_decl): Likewise.
9873
9874 2010-09-28 Iain Sandoe <iains@gcc.gnu.org>
9875
9876 * c-common.h (objc_start_class_interface): Adjust prototype.
9877 (objc_start_category_interface): Likewise.
9878 (objc_start_protocol): Likewise.
9879 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
9880 (objc_start_class_interface): Likewise.
9881 (objc_start_category_interface): Likewise.
9882
9883 2010-09-27 Ian Lance Taylor <iant@google.com>
9884
9885 * c-common.c (c_common_attribute_table): Add no_split_stack.
9886 (handle_no_split_stack_attribute): New static function.
9887
9888 2010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
9889
9890 Merge from 'apple/trunk' branch on FSF servers.
9891
9892 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
9893
9894 Radar 4229905
9895 * c-common.h (objc_have_common_type): New declaration.
9896 * stub-objc.c (objc_have_common_type): New stub.
9897
9898 2005-06-22 Ziemowit Laski <zlaski@apple.com>
9899
9900 Radar 4154928
9901 * c-common.h (objc_common_type): New prototype.
9902 * stub-objc.c (objc_common_type): New stub.
9903
9904 2010-09-24 Jan Hubicka <jh@suse.cz>
9905
9906 * c-common.c (handle_leaf_attribute): New function.
9907 (struct attribute_spec c_common_att): Add leaf.
9908
9909 2010-09-22 Joseph Myers <joseph@codesourcery.com>
9910
9911 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
9912 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
9913 -dump, -dump=, -imacros, -imacros=, -include, -include=,
9914 -include-barrier, -include-directory, -include-directory=,
9915 -include-directory-after, -include-directory-after=,
9916 -include-prefix, -include-prefix=, -include-with-prefix,
9917 -include-with-prefix=, -include-with-prefix-after,
9918 -include-with-prefix-after=, -include-with-prefix-before,
9919 -include-with-prefix-before=, -no-integrated-cpp,
9920 -no-line-commands, -no-standard-includes, -no-warnings, -output,
9921 -output=, -pedantic, -pedantic-errors, -preprocess,
9922 -print-missing-file-dependencies, -trace-includes, -traditional,
9923 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
9924 -user-dependencies, -verbose, -write-dependencies,
9925 -write-user-dependencies, no-integrated-cpp, traditional): New.
9926
9927 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
9928
9929 PR objc/23710
9930 * c-common.h (objc_start_method_definition): Return bool instead
9931 of void.
9932 * stub-objc.c (objc_start_method_definition): Return bool instead
9933 of void.
9934
9935 2010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
9936
9937 PR objc/25965
9938 * c-common.h (objc_get_interface_ivars): New declaration.
9939 * stub-objc.c (objc_get_interface_ivars): New stub.
9940
9941 2010-09-15 Ian Lance Taylor <iant@google.com>
9942
9943 * c-common.c (parse_optimize_options): Do not capitalize warning
9944 messages. Remove period at end of warning message.
9945
9946 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
9947
9948 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
9949 (handle_alias_attribute): ... here.
9950 (handle_ifunc_attribute): New.
9951
9952 2010-09-06 Mark Mitchell <mark@codesourcery.com>
9953
9954 * c-common.h (do_warn_double_promotion): Declare.
9955 * c-common.c (do_warn_double_promotion): Define.
9956
9957 2010-09-05 Mark Mitchell <mark@codesourcery.com>
9958
9959 * c.opt (Wdouble-promotion): New.
9960
9961 2010-09-02 Joseph Myers <joseph@codesourcery.com>
9962
9963 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
9964 fvtable-thunks, fxref): Mark no longer supported in help text.
9965
9966 2010-09-02 Joseph Myers <joseph@codesourcery.com>
9967
9968 * c.opt (Wimport, fall-virtual, falt-external-templates,
9969 fdefault-inline, fenum-int-equiv, fexternal-templates,
9970 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
9971 fname-mangling-version-, fnew-abi, fnonnull-objects,
9972 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
9973 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
9974 applicable.
9975 (fhandle-exceptions): Mark with Alias and Warn.
9976 * c-opts.c (c_common_handle_option): Don't handle options marked
9977 as ignored.
9978
9979 2010-09-02 Joseph Myers <joseph@codesourcery.com>
9980
9981 * c.opt (Wcomments, Werror-implicit-function-declaration,
9982 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
9983 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
9984 aliases.
9985 * c-common.c (option_codes): Use OPT_Wcomment instead of
9986 OPT_Wcomments.
9987 * c-opts.c (warning_as_error_callback, c_common_handle_option):
9988 Don't handle options marked as aliases.
9989
9990 2010-08-25 Richard Guenther <rguenther@suse.de>
9991
9992 * c-common.c (c_common_get_alias_set): Remove special
9993 handling for pointers.
9994
9995 2010-08-20 Nathan Froyd <froydnj@codesourcery.com>
9996
9997 * c-common.c: Use FOR_EACH_VEC_ELT.
9998 * c-gimplify.c: Likewise.
9999 * c-pragma.c: Likewise.
10000
10001 2010-08-16 Joseph Myers <joseph@codesourcery.com>
10002
10003 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
10004 RejectDriver.
10005 (MMDX): Change back to MMD. Mark NoDriverArg instead of
10006 RejectDriver.
10007 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
10008 instead of OPT_MDX and OPT_MMDX.
10009
10010 2010-08-16 Joseph Myers <joseph@codesourcery.com>
10011
10012 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
10013
10014 2010-08-12 Joseph Myers <joseph@codesourcery.com>
10015
10016 * c.opt (MD, MMD): Change to MDX and MMDX.
10017 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
10018
10019 2010-08-11 Joseph Myers <joseph@codesourcery.com>
10020
10021 * c-opts.c (c_common_handle_option): Call handle_generated_option
10022 instead of handle_option.
10023
10024 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
10025
10026 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
10027 (maybe_apply_renaming_pragma): Delete unneeded declarations.
10028
10029 2010-08-08 Nathan Froyd <froydnj@codesourcery.com>
10030
10031 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
10032 (pending_redefine_extname): Change type to a VEC.
10033 (add_to_renaming_pragma_list): Update for new type of
10034 pending_redefine_extname.
10035 (maybe_apply_renaming_pragma): Likewise.
10036
10037 2010-08-04 Arnaud Charlet <charlet@adacore.com>
10038
10039 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
10040 visited.
10041 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
10042 decide whether a type has already been declared/seen.
10043 Do not go to the original type.
10044 (dump_nested_types): New parameter forward.
10045 Generate forward declaration if needed and mark type as visited.
10046 (print_ada_declaration): Call dump_nested_types if not already done.
10047 Mark types as visited.
10048
10049 2010-08-03 Joseph Myers <joseph@codesourcery.com>
10050
10051 * c.opt (-print-pch-checksum): Remove option.
10052 * c-opts.c (c_common_handle_option): Don't handle
10053 OPT_print_pch_checksum.
10054
10055 2010-07-27 Joseph Myers <joseph@codesourcery.com>
10056
10057 * c-common.h (c_common_handle_option): Update prototype and return
10058 value type.
10059 * c-opts.c (c_common_handle_option): Update prototype and return
10060 value type. Update calls to handle_option and
10061 enable_warning_as_error.
10062
10063 2010-07-27 Jakub Jelinek <jakub@redhat.com>
10064
10065 PR c/45079
10066 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
10067
10068 2010-07-27 Joseph Myers <joseph@codesourcery.com>
10069
10070 * c-common.h (c_common_missing_argument): Remove.
10071 * c-opts.c (c_common_missing_argument): Remove.
10072 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
10073 idirafter, imacros, include, isysroot, isystem, iquote): Add
10074 MissingArgError.
10075 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
10076
10077 2010-07-27 Joseph Myers <joseph@codesourcery.com>
10078
10079 * c-common.h (c_common_option_lang_mask,
10080 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
10081 New.
10082 (c_common_init_options): Update prototype.
10083 * c-opts.c (c_common_option_lang_mask): New.
10084 (c_common_initialize_diagnostics): Split out of
10085 c_common_init_options.
10086 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
10087 New.
10088 (c_common_init_options): Update prototype. Use decoded options in
10089 search for -lang-asm.
10090
10091 2010-07-15 Nathan Froyd <froydnj@codesourcery.com>
10092
10093 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
10094 * c-format.c: Likewise.
10095
10096 2010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
10097
10098 * c-common.h: Include diagnostic-core.h. Error if already
10099 included.
10100 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
10101
10102 2010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
10103
10104 * c-common.c (IN_GCC_FRONTEND): Do not undef.
10105 Do not include expr.h
10106 (vector_mode_valid_p): Move here.
10107
10108 2010-06-21 DJ Delorie <dj@redhat.com>
10109
10110 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
10111 allow these pragmas anywhere.
10112
10113 2010-06-14 Jakub Jelinek <jakub@redhat.com>
10114
10115 PR bootstrap/44509
10116 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
10117 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
10118 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
10119 ggc_strdup instead of xstrdup.
10120
10121 2010-06-10 Jakub Jelinek <jakub@redhat.com>
10122
10123 * c-cppbuiltin.c: Include cpp-id-data.h.
10124 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
10125 (lazy_hex_fp_value): New function.
10126 (builtin_define_with_hex_fp_value): Provide definitions lazily.
10127
10128 2010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
10129
10130 * c-gimplify.c: Do not include tree-flow.h
10131
10132 2010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
10133
10134 PR other/44034
10135 * c-common.c: Rename targetm member:
10136 targetm.enum_va_list -> targetm.enum_va_list_p
10137
10138 2010-06-28 Anatoly Sokolov <aesok@post.ru>
10139
10140 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
10141
10142 2010-06-28 Steven Bosscher <steven@gcc.gnu.org>
10143
10144 * c-cppbuiltin.c: Do not include except.h.
10145
10146 2010-06-24 Andi Kleen <ak@linux.intel.com>
10147
10148 * c-common.c (warn_for_omitted_condop): New.
10149 * c-common.h (warn_for_omitted_condop): Add prototype.
10150
10151 2010-06-21 Joseph Myers <joseph@codesourcery.com>
10152
10153 * c.opt (lang-objc): Remove.
10154 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
10155
10156 2010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
10157
10158 * c-opts.c: Include "tm_p.h".
10159
10160 2010-06-20 Joseph Myers <joseph@codesourcery.com>
10161
10162 * c-common.c (parse_optimize_options): Update call to
10163 decode_options.
10164
10165 2010-06-18 Nathan Froyd <froydnj@codesourcery.com>
10166
10167 * c-common.c (record_types_used_by_current_var_decl): Adjust for
10168 new type of types_used_by_cur_var_decl.
10169
10170 2010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
10171
10172 PR bootstrap/44512
10173 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
10174 for C++ standard compliance.
10175
10176 2010-06-16 Jason Merrill <jason@redhat.com>
10177
10178 * c.opt: Add -Wnoexcept.
10179
10180 2010-06-16 Richard Guenther <rguenther@suse.de>
10181
10182 PR c/44555
10183 * c-common.c (c_common_truthvalue_conversion): Remove
10184 premature and wrong optimization concering ADDR_EXPRs.
10185
10186 2010-06-15 Arnaud Charlet <charlet@adacore.com>
10187
10188 * c-ada-spec.c (dump_sloc): Remove column info.
10189 (is_simple_enum): New function.
10190 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
10191 enum types when relevant.
10192
10193 2010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
10194
10195 * c-common.c (conversion_warning): Warn at expression
10196 location.
10197
10198 2010-06-10 Joseph Myers <joseph@codesourcery.com>
10199
10200 * c-opts.c (c_common_handle_option): Don't handle
10201 OPT_fshow_column.
10202
10203 2010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
10204
10205 * c-pragma.c (push_alignment): Use typed GC allocation.
10206 (handle_pragma_push_options): Likewise.
10207
10208 * c-common.c (parse_optimize_options): Likewise.
10209
10210 * c-common.h (struct sorted_fields_type): Add variable_size GTY
10211 option.
10212
10213 2010-06-07 Joseph Myers <joseph@codesourcery.com>
10214
10215 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
10216 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
10217 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
10218 flag_signed_bitfields, warn_strict_null_sentinel,
10219 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
10220 flag_gen_declaration, flag_no_gnu_keywords,
10221 flag_implement_inlines, flag_implicit_templates,
10222 flag_implicit_inline_templates, flag_optional_diags,
10223 flag_elide_constructors, flag_default_inline, flag_rtti,
10224 flag_conserve_space, flag_access_control, flag_check_new,
10225 flag_new_for_scope, flag_weak, flag_working_directory,
10226 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
10227 flag_enforce_eh_specs, flag_threadsafe_statics,
10228 flag_pretty_templates): Remove.
10229 * c-common.h (flag_preprocess_only, flag_nil_receivers,
10230 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
10231 flag_replace_objc_classes, flag_undef, flag_no_builtin,
10232 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
10233 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
10234 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
10235 flag_no_gnu_keywords, flag_implement_inlines,
10236 flag_implicit_templates, flag_implicit_inline_templates,
10237 flag_optional_diags, flag_elide_constructors, flag_default_inline,
10238 flag_rtti, flag_conserve_space, flag_access_control,
10239 flag_check_new, flag_new_for_scope, flag_weak,
10240 flag_working_directory, flag_use_cxa_atexit,
10241 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
10242 flag_threadsafe_statics, flag_pretty_templates,
10243 warn_strict_null_sentinel): Remove.
10244 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
10245 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
10246 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
10247 fimplicit-inline-templates, fimplicit-templates,
10248 flax-vector-conversions, fms-extensions, fnil-receivers,
10249 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
10250 frtti, fshort-double, fshort-enums, fshort-wchar,
10251 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
10252 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
10253 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
10254 gen-decls, undef): Use Var.
10255 (fdefault-inline, foptional-diags): Document as doing nothing.
10256 * c-opts.c (c_common_handle_option): Remove cases for options now
10257 using Var. Mark ignored options as such.
10258
10259 2010-06-05 Steven Bosscher <steven@gcc.gnu.org>
10260
10261 * c-common.c: Moved to here from parent directory.
10262 * c-common.def: Likewise.
10263 * c-common.h: Likewise.
10264 * c-cppbuiltin.c: Likewise.
10265 * c-dump.c: Likewise.
10266 * c-format.c: Likewise.
10267 * c-format.h : Likewise.
10268 * c-gimplify.c: Likewise.
10269 * c-lex.c: Likewise.
10270 * c-omp.c: Likewise.
10271 * c.opt: Likewise.
10272 * c-opts.c: Likewise.
10273 * c-pch.c: Likewise.
10274 * c-ppoutput.c: Likewise.
10275 * c-pragma.c: Likewise.
10276 * c-pragma.h: Likewise.
10277 * c-pretty-print.c: Likewise.
10278 * c-pretty-print.h: Likewise.
10279 * c-semantics.c: Likewise.
10280 * stub-objc.c: Likewise.
10281
10282 * c-common.c: Include gt-c-family-c-common.h.
10283 * c-pragma.c: Include gt-c-family-c-pragma.h.
10284 \f
10285 Copyright (C) 2010-2019 Free Software Foundation, Inc.
10286
10287 Copying and distribution of this file, with or without modification,
10288 are permitted in any medium without royalty provided the copyright
10289 notice and this notice are preserved.