]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c-family/ChangeLog
Daily bump.
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
CommitLineData
255beb07 12016-10-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
2
3 * c-common.c (c_common_truthvalue_conversion): Warn for suspicious
4 left shift in boolean context.
5
c5d89bae 62016-09-29 Jakub Jelinek <jakub@redhat.com>
7
8 Implement P0001R1 - C++17 removal of register storage class specifier
9 * c.opt (Wregister): New warning.
10 * c-opts.c (c_common_post_options): Enable -Wregister by
11 default for C++17.
12
4267ed07 132016-09-29 James Greenhalgh <james.greenhalgh@arm.com>
14
15 * c-opts.c (c_common_post_options): Remove special case for
16 TARGET_FLT_EVAL_METHOD_NON_DEFAULT with -fexcess-precision=standard
17 in C++.
18
0b72b025 192016-09-27 Jakub Jelinek <jakub@redhat.com>
20
4fd4e9e0 21 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_capture_star_this for
22 -std=c++1z.
23
0b72b025 24 * c-ada-spec.c (print_ada_declaration): Remove break after return.
25
ea36272b 262016-09-26 Thomas Preud'homme <thomas.preudhomme@arm.com>
27
28 * c-common.c: Include memmodel.h.
29
e997bd3a 302016-09-26 Marek Polacek <polacek@redhat.com>
31
32 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
33
3c77f69c 342016-09-26 Marek Polacek <polacek@redhat.com>
35
36 PR c/7652
37 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
38 (handle_fallthrough_attribute): New function.
39 (attribute_fallthrough_p): New function.
40 * c-common.h (attribute_fallthrough_p): Declare.
41
481ce481 422016-09-24 Marek Polacek <polacek@redhat.com>
43
44 PR c/77490
45 * c.opt (Wbool-operation): New.
46
a5fe0b37 472016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
48
49 * c-common.c (c_common_truthvalue_conversion): Inhibit
50 Wint-in-bool-context warning with from_macro_definition_at.
51 Mention the expression will always evaluate to true.
52
90f40f08 532016-09-21 Martin Sebor <msebor@redhat.com>
54
55 PR bootstrap/77676
56 * c.opt (fprintf-return-value): Temporarily initialize to zero
57 to unblock bootstrap failures.
58
98aa0f57 592016-09-21 Jakub Jelinek <jakub@redhat.com>
60
61 PR c++/77651
62 * c.opt (Waligned-new=): Add RejectNegative.
63 (faligned-new=): Likewise. Spelling fix - change
64 aligned_new_threshhold to aligned_new_threshold.
65 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
66 to aligned_new_threshold.
67
b9833bfd 682016-09-20 Martin Sebor <msebor@redhat.com>
69
70 PR middle-end/49905
71 * c.opt: Add -Wformat-length and -fprintf-return-value.
72
bed03df1 732016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
74
75 PR c++/77434
76 * c.opt (Wint-in-bool-context): New warning.
77 * c-common.c (c_common_truthvalue_conversion): Warn on integer
78 constants in boolean context.
79
9b5c49ef 802016-09-19 Joseph Myers <joseph@codesourcery.com>
81
82 * c-common.c (max_align_t_align): Also consider alignment of
83 float128_type_node.
84
cc4b5c58 852016-09-15 Jason Merrill <jason@redhat.com>
86
87 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
88 DECL_EXTERNAL.
89
ef45c4c0 902016-09-14 Jason Merrill <jason@redhat.com>
91
92 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
93 limit FIELD_DECL, either.
94
b99cc6da 952016-09-14 Marek Polacek <polacek@redhat.com>
96
97 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
98 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
99 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
100
68ef907c 1012016-09-13 David Malcolm <dmalcolm@redhat.com>
102
103 * c-common.c (warn_logical_not_parentheses): Replace
104 rich_location::add_fixit_insert calls with add_fixit_insert_before
105 and add_fixit_insert_after, eliminating the "next_loc" calculation.
106
2c24fd5e 1072016-09-13 Jason Merrill <jason@redhat.com>
108 Tom de Vries <tom@codesourcery.com>
109
110 PR c++/77427
111 * c-common.c (set_underlying_type): Don't treat array as builtin type.
112
005248bc 1132016-09-13 Jason Merrill <jason@redhat.com>
114
115 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
116 limit types at all.
117
0c893604 1182016-09-12 Jason Merrill <jason@redhat.com>
119
120 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
121 bit/byte confusion, allow large alignment for types.
122
7a21b590 1232016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
124
125 PR c++/77496
126 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
127
00434032 1282016-09-12 David Malcolm <dmalcolm@redhat.com>
129
130 PR c/72858
131 * c-format.c (argument_parser::check_argument_type): Add params
132 "type_start" and "conversion_char". Use the former to generate
133 offset_to_type_start and pass it and conversion_char to
134 check_format_types.
135 (check_format_info_main): Capture the start of the type
136 information as "type_start", and pass it an format_char
137 to arg_parser.check_argument_type.
138 (check_format_types): Provide an example in the leading comment.
139 Add params "offset_to_type_start" and "conversion_char"; pass
140 them to format_type_warning calls.
141 (test_get_modifier_for_format_len): Likewise.
142 (matching_type_p): New function.
143 (get_format_for_type): Add param "conversion_char" and move
144 implementation into...
145 (get_format_for_type_1): ...new function, called twice.
146 Use new function matching_type_p rather than checking for
147 TYPE_CANONICAL equality.
148 (get_corrected_substring): New function.
149 (format_type_warning): Provide an example in the leading comment.
150 Add params "offset_to_type_start" and "conversion_char". Replace
151 call to get_format_for_type with call to get_corrected_substring
152 and move rejection of hints for widths/precisions there.
153 (assert_format_for_type_streq): Add param "conversion_char".
154 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
155 (test_get_format_for_type_printf): Add conversion chars to the
156 tests, adding coverage for various combinations of integer
157 vs double conversions, and for preserving octal and hexadecimal
158 conversions.
159 (test_get_format_for_type_scanf): Add conversion chars to the
160 tests.
161
3bb45f76 1622016-09-10 Tom de Vries <tom@codesourcery.com>
163
164 PR C/71602
165 * c-common.c (build_va_arg): Handle more strict
166 targetm.canonical_va_list_type. Replace first argument type error with
167 assert.
168
911ea34a 1692016-09-09 Martin Sebor <msebor@redhat.com>
170
171 PR c/77520
172 PR c/77521
173 * c-format.c (argument_parser::find_format_char_info): Use %qc
174 format directive unconditionally.
175
db8ffb40 1762016-09-09 Jason Merrill <jason@redhat.com>
177
178 Implement C++17 new of over-aligned types.
179 * c.opt: Add -faligned-new and -Waligned-new.
180 * c-common.c (max_align_t_align): Split out from...
181 (cxx_fundamental_alignment_p): ...here.
182 * c-common.h: Declare it.
183 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
184
c5eddaf9 1852016-09-09 Joseph Myers <joseph@codesourcery.com>
186
187 * c-cppbuiltin.c (builtin_define_type_width): New function.
188 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
189 macros.
190
3da97ff7 1912016-09-07 David Malcolm <dmalcolm@redhat.com>
192
193 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
194 a POINTER_TYPE.
195 (substring_loc::get_location): Move to substring-locations.c,
196 keeping implementation as...
197 (c_get_substring_location): New function, from the above, reworked
198 to use accessors rather than member lookup.
199 * c-common.h (class substring_loc): Move to substring-locations.h,
200 replacing with a forward decl.
201 (c_get_substring_location): New decl.
202 * c-format.c: Include "substring-locations.h".
203 (format_warning_va): Move to substring-locations.c.
204 (format_warning_at_substring): Likewise.
205
f9b3f702 2062016-09-06 Martin Sebor <msebor@redhat.com>
207
208 PR c/77336
209 * c-format.c (check_function_format): Avoid issuing warnings for
210 functions unless they call format functions with non-constant
211 format strings.
212
4c04bcce 2132016-09-06 Richard Biener <rguenther@suse.de>
214
215 PR c/77450
216 * c-common.c (c_common_mark_addressable_vec): Handle
217 COMPOUND_LITERAL_EXPR.
218
8f8828ba 2192016-09-05 Marek Polacek <polacek@redhat.com>
220
221 PR c/77423
222 * c-common.c (bool_promoted_to_int_p): New function.
223 (expr_has_boolean_operands_p): New function.
224 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
225 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
226
8ff61e58 2272016-09-04 Tom de Vries <tom@codesourcery.com>
228
229 revert:
230 2016-08-29 Tom de Vries <tom@codesourcery.com>
231
232 * c-common.c (build_va_arg): Replace first argument type error
233 with assert.
234
0b80c4b2 2352016-09-02 Jakub Jelinek <jakub@redhat.com>
236
237 PR c/65467
238 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
239 (c_finish_omp_for): Reject _Atomic qualified iterators.
240
2412016-09-01 Martin Sebor <msebor@redhat.com>
b18dea91 242
243 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
244 size to guarantee it fits the output of the formatted function
245 regardless of its arguments.
246
c7afb782 2472016-09-01 Marek Polacek <polacek@redhat.com>
248
249 PR c/7652
250 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
251 FALLTHRU comments.
252
f293b7f2 2532016-08-29 Marek Polacek <polacek@redhat.com>
254
255 PR c/77292
256 * c-common.c (warn_logical_not_parentheses): Don't warn for
257 a comparison or a logical operator.
258
839e4d28 2592016-08-29 Tom de Vries <tom@codesourcery.com>
260
261 * c-common.c (build_va_arg): Fix type comparison assert.
262
0acb92b8 2632016-08-29 Tom de Vries <tom@codesourcery.com>
264
265 * c-common.c (build_va_arg): Replace first argument type error
266 with assert.
267
ea2ec8f6 2682016-08-29 Tom de Vries <tom@codesourcery.com>
269
270 PR c/77398
271 * c-common.c (build_va_arg): Add first argument error. Build va_arg
272 with error_mark_node as va_list instead of with illegal va_list.
273
c4963714 2742016-08-25 Marek Polacek <polacek@redhat.com>
275 David Malcolm <dmalcolm@redhat.com>
276
277 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
278 * c-common.h (warn_logical_not_parentheses): Update declaration.
279
364743f3 2802016-08-22 Marek Polacek <polacek@redhat.com>
281
282 PR c++/77321
283 * c-common.c (warn_for_memset): Check type for null.
284
012f068a 2852016-08-22 Joseph Myers <joseph@codesourcery.com>
286
287 * c-family/c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
288 _FloatNx types for suffixes for built-in functions.
289
82c85aba 2902016-08-19 Joseph Myers <joseph@codesourcery.com>
291
292 PR c/32187
293 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
294 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
295 (RID_FLOAT128X): New enum rid values.
296 (CASE_RID_FLOATN_NX): New macro.
297 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
298 keywords.
299 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
300 corresponding complex types.
301 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
302 _FloatNx and corresponding complex types.
303 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
304 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
305 and _FloatNx types for the widest type for determining
306 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
307 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
308 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
309 and _FloatNx types.
310 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
311 constants.
312 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
313 _FloatNx types.
314
48a7392b 3152016-08-18 David Malcolm <dmalcolm@redhat.com>
316
317 * c-opts.c (c_diagnostic_finalizer): Update for change to
318 diagnostic_show_locus.
319
5c8151fa 3202016-08-18 David Malcolm <dmalcolm@redhat.com>
321
322 * c-common.c: Include "spellcheck.h".
323 (cb_get_suggestion): New function.
324 * c-common.h (cb_get_suggestion): New decl.
325 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
326 cb_get_suggestion.
327
26040f06 3282016-08-18 Marek Polacek <polacek@redhat.com>
329
330 PR c/71514
331 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
332 and pointer-to-VLA.
333
5927e78e 3342016-08-16 David Malcolm <dmalcolm@redhat.com>
335
336 PR c/72857
337 * c-common.c (substring_loc::get_range): Rename to...
338 (substring_loc::get_location): ...this, converting param from a
339 source_range * to a location_t *. Call
340 get_source_location_for_substring rather than
341 get_source_range_for_substring, and pass in m_caret_idx.
342 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
343 (substring_loc::get_range): Replace with...
344 (substring_loc::get_location): ...this.
345 (substring_loc::set_caret_index): New method.
346 (substring_loc): Add field m_caret_idx.
347 * c-format.c (format_warning_va): Update for above changes.
348 Rename local "substring_loc" to "fmt_substring_loc" to avoid
349 clashing with type name.
350 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
351 (check_argument_type): Likewise.
352 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
353 Use a copy when emitting warnings, setting the caret index from TYPE.
354
6ce66d38 3552016-08-16 Eric Botcazou <ebotcazou@adacore.com>
356 Arnaud Charlet <charlet@adacore.com>
357
358 * c-ada-spec.c (dump_number): New function.
359 (handle_escape_character): Likewise.
360 (print_ada_macros): Add handling of constant integers and strings.
361
e3533433 3622016-08-12 Marek Polacek <polacek@redhat.com>
363
364 PR c/7652
365 * c-common.c (scalar_to_vector): Adjust fall through comment.
366 * c-opts.c (c_common_handle_option): Likewise.
367 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
368 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
369 fall through comment.
370 * cilk.c (extract_free_variables): Add FALLTHRU.
371
0f463aec 3722016-08-10 Jason Merrill <jason@redhat.com>
373
374 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
375
80488e20 3762016-08-09 Jason Merrill <jason@redhat.com>
377
378 * c-common.c (c_common_attribute_table): vector_size affects type
379 identity.
380
a319e7f4 3812016-08-09 Marek Polacek <polacek@redhat.com>
382
383 PR c/7652
384 * c-ada-spec.c (dump_generic_ada_node): Add return.
385
33603066 3862016-08-09 Jason Merrill <jason@redhat.com>
387
388 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
389 C++17 constexpr lambdas.
390
7af4d06b 3912016-08-08 David Malcolm <dmalcolm@redhat.com>
392
393 PR c/64955
394 * c-common.h (selftest::c_format_c_tests): New declaration.
395 (selftest::run_c_tests): New declaration.
396 * c-format.c: Include "selftest.h.
397 (format_warning_va): Add param "corrected_substring" and use
398 it to add a replacement fix-it hint.
399 (format_warning_at_substring): Likewise.
400 (format_warning_at_char): Update for new param of
401 format_warning_va.
402 (argument_parser::check_argument_type): Pass "fki" to
403 check_format_types.
404 (check_format_types): Add param "fki" and pass it to
405 format_type_warning.
406 (deref_n_times): New function.
407 (get_modifier_for_format_len): New function.
408 (selftest::test_get_modifier_for_format_len): New function.
409 (get_format_for_type): New function.
410 (format_type_warning): Add param "fki" and use it to attempt
411 to provide hints for argument types when calling
412 format_warning_at_substring.
413 (selftest::get_info): New function.
414 (selftest::assert_format_for_type_streq): New function.
415 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
416 (selftest::test_get_format_for_type_printf): New function.
417 (selftest::test_get_format_for_type_scanf): New function.
418 (selftest::c_format_c_tests): New function.
419
d189b094 4202016-08-08 David Malcolm <dmalcolm@redhat.com>
421
422 PR c/52952
423 * c-format.c: Include "diagnostic.h".
424 (location_column_from_byte_offset): Delete.
425 (location_from_offset): Delete.
426 (format_warning_va): New function.
427 (format_warning_at_substring): New function.
428 (format_warning_at_char): New function.
429 (check_format_arg): Capture location of format_tree and pass to
430 check_format_info_main.
431 (argument_parser): Add fields "start_of_this_format" and
432 "format_string_cst".
433 (flag_chars_t::validate): Add param "format_string_cst". Convert
434 warning_at call using location_from_offset to call to
435 format_warning_at_char.
436 (argument_parser::argument_parser): Add param "format_string_cst_"
437 and use use it to initialize field "format_string_cst".
438 Initialize new field "start_of_this_format".
439 (argument_parser::read_format_flags): Convert warning_at call
440 using location_from_offset to a call to format_warning_at_char.
441 (argument_parser::read_any_format_left_precision): Likewise.
442 (argument_parser::read_any_format_precision): Likewise.
443 (argument_parser::read_any_other_modifier): Likewise.
444 (argument_parser::find_format_char_info): Likewise, in three places.
445 (argument_parser::parse_any_scan_set): Likewise, in one place.
446 (argument_parser::handle_conversions): Likewise, in two places.
447 (argument_parser::check_argument_type): Add param "fmt_param_loc"
448 and use it to make a substring_loc. Pass the latter to
449 check_format_types.
450 (check_format_info_main): Add params "fmt_param_loc" and
451 "format_string_cst". Convert warning_at calls using
452 location_from_offset to calls to format_warning_at_char. Pass the
453 new params to the arg_parser ctor. Pass "format_string_cst" to
454 flag_chars.validate. Pass "fmt_param_loc" to
455 arg_parser.check_argument_type.
456 (check_format_types): Convert first param from a location_t
457 to a const substring_loc & and rename to "fmt_loc". Attempt
458 to extract the range of the relevant parameter and pass it
459 to format_type_warning.
460 (format_type_warning): Convert first param from a location_t
461 to a const substring_loc & and rename to "fmt_loc". Add
462 params "param_range" and "type". Replace calls to warning_at
463 with calls to format_warning_at_substring.
464
0dae5fef 4652016-08-08 David Malcolm <dmalcolm@redhat.com>
466
467 * c-format.c (class flag_chars_t): New class.
468 (struct length_modifier): New struct.
469 (class argument_parser): New class.
470 (flag_chars_t::flag_chars_t): New ctor.
471 (flag_chars_t::has_char_p): New method.
472 (flag_chars_t::add_char): New method.
473 (flag_chars_t::validate): New method.
474 (flag_chars_t::get_alloc_flag): New method.
475 (flag_chars_t::assignment_suppression_p): New method.
476 (argument_parser::argument_parser): New ctor.
477 (argument_parser::read_any_dollar): New method.
478 (argument_parser::read_format_flags): New method.
479 (argument_parser::read_any_format_width): New method.
480 (argument_parser::read_any_format_left_precision): New method.
481 (argument_parser::read_any_format_precision): New method.
482 (argument_parser::handle_alloc_chars): New method.
483 (argument_parser::read_any_length_modifier): New method.
484 (argument_parser::read_any_other_modifier): New method.
485 (argument_parser::find_format_char_info): New method.
486 (argument_parser::validate_flag_pairs): New method.
487 (argument_parser::give_y2k_warnings): New method.
488 (argument_parser::parse_any_scan_set): New method.
489 (argument_parser::handle_conversions): New method.
490 (argument_parser::check_argument_type): New method.
491 (check_format_info_main): Introduce classes argument_parser
492 and flag_chars_t, moving the code within the loop into methods
493 of these classes. Make various locals "const".
494
d4166bdc 4952016-08-05 David Malcolm <dmalcolm@redhat.com>
496
497 * c-common.c: Include "substring-locations.h".
498 (get_cpp_ttype_from_string_type): New function.
499 (g_string_concat_db): New global.
500 (substring_loc::get_range): New method.
501 * c-common.h (g_string_concat_db): New declaration.
502 (class substring_loc): New class.
503 * c-lex.c (lex_string): When concatenating strings, capture the
504 locations of all tokens using a new obstack, and record the
505 concatenation locations within g_string_concat_db.
506 * c-opts.c (c_common_init_options): Construct g_string_concat_db
507 on the ggc-heap.
508
7648c9c7 5092016-07-29 Marek Polacek <polacek@redhat.com>
510
8ae70602 511 PR c/71926
512 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
513 parentheses warning.
514
7648c9c7 515 PR c/71574
516 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
517
595e387a 5182016-07-28 Martin Liska <mliska@suse.cz>
519
520 PR gcov-profile/68025
521 * c-common.c (handle_no_profile_instrument_function_attribute):
522
296103aa 5232016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
524
525 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
526 BITS_PER_UNIT_LOG.
527
21483ab7 5282016-07-25 Jason Merrill <jason@redhat.com>
529
530 PR c++/65970
531 * c.opt (fconstexpr-loop-limit): New.
532
0b80c4b2 5332016-07-22 Martin Sebor <msebor@redhat.com>
efa8e86e 534
535 PR c++/71675
536 * c-common.c (resolve_overloaded_builtin): Avoid converting
537 __atomic_compare_exchange_n return type to that of what its
538 first argument points to.
539
59c1507a 5402016-07-22 Uros Bizjak <ubizjak@gmail.com>
541
542 * c-common.c: Use HOST_WIDE_INT_M1U instead of
543 ~(unsigned HOST_WIDE_INT) 0.
544
45648efe 5452016-07-22 Martin Liska <mliska@suse.cz>
546
547 PR gcov-profile/69028
548 PR gcov-profile/62047
549 * cilk.c (create_cilk_helper_decl): Set location of a new decl
550 to the current_function_decl.
551
0c0f63cb 5522016-07-21 Jason Merrill <jason@redhat.com>
553
554 PR c++/65168
555 * c-common.c (c_common_truthvalue_conversion): Check
556 c_inhibit_evaluation_warnings for warning about address of
557 reference.
558
d208f6e6 5592016-07-20 David Malcolm <dmalcolm@redhat.com>
560
561 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
562 const char *.
563
0238e35e 5642016-07-15 Jason Merrill <jason@redhat.com>
565
566 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
567
0dd7db3b 5682016-07-15 Jakub Jelinek <jakub@redhat.com>
569
570 PR c/71858
571 * c-common.h (enum lookup_name_fuzzy_kind): Add
572 FUZZY_LOOKUP_FUNCTION_NAME.
573
e59cff35 5742016-07-08 Jason Merrill <jason@redhat.com>
575
576 P0145: Refining Expression Order for C++.
577 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
578 * c-opts.c: Adjust.
579
faee03ad 5802016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
581
582 PR c++/71214
583 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
584
a4dd89cb 5852016-06-29 Thomas Schwinge <thomas@codesourcery.com>
586
587 * c-pragma.h (enum pragma_kind): Rename
588 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
589 users.
590
b6a4a0f5 5912016-06-29 Richard Biener <rguenther@suse.de>
592
593 PR middle-end/71002
594 * c-common.c (c_common_get_alias_set): Remove union type punning case.
595
176aa551 5962016-06-24 Jason Merrill <jason@redhat.com>
597
598 P0145R2: Refining Expression Order for C++.
599 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
600 MODIFY_EXPR.
601
77104764 6022016-06-24 Jakub Jelinek <jakub@redhat.com>
603
604 * c-common.c (check_builtin_function_arguments): Require last
605 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
606 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
607 if the last argument is pointer to enumerated or boolean type.
608
8469aece 6092016-06-22 David Malcolm <dmalcolm@redhat.com>
610
611 PR c/70339
612 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
613 (lookup_name_fuzzy): New prototype.
614
bd08c370 6152016-06-21 John David Anglin <danglin@gcc.gnu.org>
616
617 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
618
06c75b9a 6192016-06-14 Jason Merrill <jason@redhat.com>
620
621 P0145R2: Refining Expression Order for C++.
622 * c.opt (fargs-in-order): New.
623 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
624
9720103d 6252016-06-13 Jakub Jelinek <jakub@redhat.com>
626
12cb8367 627 PR sanitizer/71498
628 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
629 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
630
9720103d 631 PR preprocessor/71183
632 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
633 to cb_get_source_date_epoch.
634
8ec29807 6352016-06-10 Jakub Jelinek <jakub@redhat.com>
636
637 PR c/68657
638 * c.opt (Wpsabi): Add Warning flag.
639
1dc4d519 6402016-06-10 Martin Sebor <msebor@redhat.com>
641
642 PR c/71392
643 * gcc/c-family/c-common.c (handle_nonnull_attribute): Accept
644 the nonnull attribute in type-generic builtins.
645
23b101c5 6462016-06-09 Martin Sebor <msebor@redhat.com>
647
648 PR c/70883
649 * c-common.c (builtin_function_validate_nargs): Make text of error
650 message consistent with others like it.
651
732905bb 6522016-06-08 Martin Sebor <msebor@redhat.com>
653 Jakub Jelinek <jakub@redhat.com>
654
655 PR c++/70507
656 PR c/68120
657 * c-common.c (check_builtin_function_arguments): Handle
658 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
659
86a5f91c 6602016-06-08 Richard Biener <rguenther@suse.de>
661
662 * c-common.c (parse_optimize_options): Improve diagnostic messages.
663
b032c4dd 6642016-06-07 Richard Biener <rguenther@suse.de>
665
666 PR c/61564
667 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
668 options and warn about others.
669
dfa5c0d3 6702016-06-01 Eduard Sanou <dhole@openmailbox.org>
671
672 * c-common.c (get_source_date_epoch): Rename to
673 cb_get_source_date_epoch.
674 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
675 message when the parsing fails. Use error_at instead of fatal_error.
676 * c-common.h (get_source_date_epoch): Rename to
677 cb_get_source_date_epoch.
678 * c-common.h (cb_get_source_date_epoch): Prototype.
679 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
680 * c-common.h (c_omp_region_type): Remove trailing comma.
681 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
682 * c-lex.c (c_lex_with_flags): Remove initialization of
683 pfile->source_date_epoch.
684
b6431756 6852016-05-30 Jakub Jelinek <jakub@redhat.com>
686
687 PR c++/71349
688 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
689 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
690 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
691 instead of C_OMP_CLAUSE_SPLIT_FOR.
692
7345b977 6932016-05-24 Richard Biener <rguenther@suse.de>
694
695 PR middle-end/70434
696 PR c/69504
697 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
698 (convert_vector_to_array_for_subscript): ... this.
699 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
700 VIEW_CONVERT_EXPR to an array type. Rename to ...
701 (convert_vector_to_array_for_subscript): ... this.
702
22a3f7bd 7032016-05-12 Marek Polacek <polacek@redhat.com>
704
705 PR c/70756
706 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
707 size_in_bytes and pass LOC to it.
708
54c4d22e 7092016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
710
711 PR c/43651
712 * c.opt (Wduplicate-decl-specifier): New option.
713
7f8012a5 7142016-05-11 Marek Polacek <polacek@redhat.com>
715
716 PR c++/71024
717 * c-common.c (diagnose_mismatched_attributes): New function.
718 * c-common.h (diagnose_mismatched_attributes): Declare.
719
1d52c456 7202016-05-04 Marek Polacek <polacek@redhat.com>
721
722 * c.opt (Wdangling-else): New option.
723
5d4db8ef 7242016-05-03 Marek Polacek <polacek@redhat.com>
725
726 PR c/70859
727 * c-common.c (builtin_function_validate_nargs): Add location
728 parameter. Use it.
729 (check_builtin_function_arguments): Add location and arguments
730 parameters. Use them.
731 * c-common.h (check_builtin_function_arguments): Update declaration.
732
9ae1b28a 7332016-05-03 Richard Biener <rguenther@suse.de>
734
735 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
736 allow call args to gimplify to SSA names.
737
4341e093 7382016-05-03 Marek Polacek <polacek@redhat.com>
739
740 * c-common.h (enum c_omp_region_type): Remove stray comma.
741
b5e88f74 7422016-05-02 Cesar Philippidis <cesar@codesourcery.com>
743
744 * c-common.h (enum c_omp_region_type): Define.
745
ee31dd3d 7462016-05-02 Richard Sandiford <richard.sandiford@arm.com>
747
748 * c-common.c (shorten_compare): Use wi::to_wide.
749
4d0a8bac 7502016-04-29 Cesar Philippidis <cesar@codesourcery.com>
751
752 PR middle-end/70626
753 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
754 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
755 reduction clauses in acc parallel loops.
756
025dd1e0 7572016-04-29 Marek Polacek <polacek@redhat.com>
758
759 PR c/70852
760 * c-common.c (warn_for_memset): Check domain before accessing it.
761
eb16928e 7622016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
763
764 PR/69089
765 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
766 "aligned" attribute.
767
ddd2a3d4 7682016-04-28 Jason Merrill <jason@redhat.com>
769
770 * c-lex.c (c_common_has_attribute): Handle nodiscard.
771
e3e8c48c 7722016-04-28 Eduard Sanou <dhole@openmailbox.org>
773 Matthias Klose <doko@debian.org>
774
775 * c-common.c (get_source_date_epoch): New function, gets the environment
776 variable SOURCE_DATE_EPOCH and parses it as long long with error
777 handling.
778 * c-common.h (get_source_date_epoch): Prototype.
779 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
780
605a4556 7812015-04-27 Ryan Burn <contact@rnburn.com>
782
783 PR c++/69024
784 PR c++/68997
785 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
786 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
787 external linkage.
788 (cilk_detect_and_unwrap): Corresponding changes.
789 (extract_free_variables): Don't extract free variables from
790 AGGR_INIT_EXPR slot.
791 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
792 (cilk_recognize_spawn): Likewise.
793
40385231 7942016-04-27 Bernd Schmidt <bschmidt@redhat.com>
795
796 * c.opt (Wmemset-elt-size): New option.
797 * c-common.c (warn_for_memset): New function.
798 * c-common.h (warn_for_memset): Declare.
799
f5d49c14 8002016-04-25 Jason Merrill <jason@redhat.com>
801
802 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
803 No longer static.
804 * c-common.h: Declare it.
805 * c-lex.c (c_common_has_attribute): Add maybe_unused.
806
9c980ab5 8072016-04-22 Jason Merrill <jason@redhat.com>
808
809 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
810
70574e60 8112016-04-20 Ilya Verbin <ilya.verbin@intel.com>
812
813 PR c++/69363
814 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
815 * c-common.h (c_finish_cilk_clauses): Remove declaration.
816
5d4b30ea 8172016-04-18 Michael Matz <matz@suse.de>
818
819 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
820 and SET_DECL_ALIGN.
821
021ad2f3 8222016-04-17 Eric Botcazou <ebotcazou@adacore.com>
823
824 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
825 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
826 to incomplete types.
827 (dump_nested_type): Remove redundant tests and tidy up.
828 (print_ada_declaration): Also set TREE_VISITED on the declaration of
829 a type which is the typedef of an original type.
830
926f9422 8312016-04-15 Marek Polacek <polacek@redhat.com>
832
833 PR c/70651
834 * c-common.c (build_va_arg): Change two asserts into errors and return
835 error_mark_node.
836
92c53257 8372016-04-13 Marek Polacek <polacek@redhat.com>
838
839 PR c++/70639
840 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
841 for switch statements, too.
842
a3ae889f 8432016-03-28 Jason Merrill <jason@redhat.com>
844
845 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
846
62d2a6dc 8472016-03-23 Marek Polacek <polacek@redhat.com>
848
849 PR c++/69884
850 * c.opt (Wignored-attributes): New option.
851
4baec9f2 8522016-03-22 David Malcolm <dmalcolm@redhat.com>
853
854 PR c/69993
855 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
856 diagnostic text, reversing the order of the warning and note so
857 that they appear in source order.
858
92e7ab1e 8592016-03-17 Marek Polacek <polacek@redhat.com>
860
861 PR c/69407
862 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
863 operations.
864
6f895832 8652016-03-14 Jason Merrill <jason@redhat.com>
866
14c36b14 867 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
868
6f895832 869 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
870
42bb3bfb 8712016-03-09 Richard Biener <rguenther@suse.de>
872
873 PR c/70143
874 * c-common.c (strict_aliasing_warning): Add back
875 alias_sets_conflict_p check.
876
3556aa80 8772016-03-08 Jason Merrill <jason@redhat.com>
878
879 * c-opts.c (set_std_cxx1z): Don't enable concepts.
880
0060768a 8812016-03-04 David Malcolm <dmalcolm@redhat.com>
882
883 PR c/68187
884 * c-indentation.c (get_visual_column): Move code to determine next
885 tab stop to...
886 (next_tab_stop): ...this new function.
887 (line_contains_hash_if): Delete function.
888 (detect_preprocessor_logic): Delete function.
889 (get_first_nws_vis_column): New function.
890 (detect_intervening_unindent): New function.
891 (should_warn_for_misleading_indentation): Replace call to
892 detect_preprocessor_logic with a call to
893 detect_intervening_unindent.
894
74c6fd40 8952016-03-04 David Malcolm <dmalcolm@redhat.com>
896
897 PR c/68187
898 * c-indentation.c (should_warn_for_misleading_indentation): When
899 suppressing warnings about cases where the guard and body are on
900 the same column, only use the first non-whitespace column in place
901 of the guard token column when dealing with "else" clauses.
902 When rejecting aligned BODY and NEXT, loosen the requirement
903 from equality with the first non-whitespace of guard to simply
904 that they not be indented relative to it.
905
e692d332 9062016-03-04 Richard Biener <rguenther@suse.de>
907
908 PR c++/70054
909 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
910 instead of alias_sets_conflict_p.
911
12cc1225 9122016-03-01 Marek Polacek <polacek@redhat.com>
913
914 PR c++/69795
915 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
916 any DECL.
917
8c38d887 9182016-02-22 Martin Sebor <msebor@redhat.com>
919
920 PR middle-end/69780
921 * c-common.c (check_builtin_function_arguments): Validate and
922 reject invalid arguments to __builtin_alloca_with_align.
923
e53f41d5 9242016-02-20 Mark Wielaard <mjw@redhat.com>
925
926 PR c/28901
927 * c.opt (Wunused-const-variable): Turn into Alias for...
928 (Wunused-const-variable=): New option.
929
9cce8384 9302016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
931
932 PR c++/69865
933 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
934 here...
935 (c_common_init_options): ...to here.
936 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
937
563d5cb8 9382016-02-19 Jakub Jelinek <jakub@redhat.com>
939
940 PR c++/69826
941 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
942 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
943 flag_preprocess_only.
944
7675e968 9452016-02-16 Jakub Jelinek <jakub@redhat.com>
946
947 PR c/69835
948 * c.opt (Wnonnull-compare): Enable for -Wall.
949
77454e6e 9502016-02-15 Jakub Jelinek <jakub@redhat.com>
951
952 PR c++/69797
953 * c-common.c (sync_resolve_size): Diagnose too few arguments
954 even when params is non-NULL empty vector.
955
600695e0 9562016-02-08 Bernd Schmidt <bschmidt@redhat.com>
957
958 PR target/60410
959 * c.opt (fshort-double): Remove.
960
a7cc1f94 9612016-02-05 Martin Sebor <msebor@redhat.com>
962
963 PR c++/69662
964 * c.opt (Warning options): Update -Wplacement-new to take
965 an optional argument.
966
6f13b088 9672016-02-01 Jakub Jelinek <jakub@redhat.com>
968
969 PR preprocessor/69543
970 PR c/69558
971 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
972 instead of loc to control_warning_option.
973
948eee2f 9742016-02-01 Nathan Sidwell <nathan@codesourcery.com>
975
976 * c.opt (fopenacc-dim=): New option.
977
5fa82c11 9782016-01-27 Ryan Burn <contact@rnburn.com>
979
980 PR cilkplus/69267
981 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
982 gimplify_arg. Removed superfluous post_p argument.
983 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
984 superfluous post_p argument.
985 * c-gimplify.c (c_gimplify_expr): Likewise.
986
3752e5b1 9872016-01-26 David Malcolm <dmalcolm@redhat.com>
988
989 PR other/69006
990 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
991 pp_newline_and_flush with pp_flush.
992
bbbbe8ab 9932016-01-20 Martin Sebor <msebor@redhat.com>
994
995 PR c/69405
996 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
997 an incompatible argument when the argument isn't a valid tree node.
998
f6dfb86a 9992016-01-18 Jason Merrill <jason@redhat.com>
1000
1001 PR c++/68767
1002 * c-common.c (check_function_arguments_recurse): Fold the whole
1003 COND_EXPR, not just the condition.
1004
f672c103 10052016-01-18 Tom de Vries <tom@codesourcery.com>
1006
1007 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
1008 classify as loop clause.
1009
c8ef893c 10102016-01-15 Jakub Jelinek <jakub@redhat.com>
1011
1012 PR bootstrap/68271
1013 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
1014 C++ FE no longer has limit on number of pragmas.
1015
10162015-01-14 Ryan Burn <contact@rnburn.com>
7d600da5 1017
1018 PR c++/69048
1019 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
580357e7 1020 to add missing cleanup point.
7d600da5 1021
a7ed4583 10222016-01-14 David Malcolm <dmalcolm@redhat.com>
1023
1024 PR c++/68819
1025 * c-indentation.c (get_visual_column): Add location_t param.
1026 Handle the column number being zero by effectively disabling the
1027 warning, with an "inform".
1028 (should_warn_for_misleading_indentation): Add location_t argument
1029 for all uses of get_visual_column.
1030
b933e511 10312016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
1032
1033 PR c++/69029
1034 * c-indentation.c (should_warn_for_misleading_indentation):
1035 Don't warn about do-while statements.
1036
517906ff 10372016-01-07 Martin Sebor <msebor@redhat.com>
1038
1039 PR c/68966
1040 * c-common.c (sync_resolve_size): Reject first argument when it's
1041 a pointer to _Bool.
1042
d42aa619 10432016-01-05 David Malcolm <dmalcolm@redhat.com>
1044
1045 PR c/69122
1046 * c-indentation.c (get_visual_column): Remove default argument.
1047 (should_warn_for_misleading_indentation): For the multiline case,
1048 update call to get_visual_column for next_stmt_exploc so that it
1049 captures the location of the first non-whitespace character in the
1050 relevant line. Don't issue warnings if there is non-whitespace
1051 before the next statement.
1052
f1717362 10532016-01-04 Jakub Jelinek <jakub@redhat.com>
1054
1055 Update copyright years.
1056
c0bf500c 10572015-12-21 David Malcolm <dmalcolm@redhat.com>
1058
1059 * c-common.c (binary_op_error): Convert first param from
1060 location_t to rich_location * and use it when emitting an error.
1061 * c-common.h (binary_op_error): Convert first param from
1062 location_t to rich_location *.
1063
dbd79382 10642015-12-16 David Malcolm <dmalcolm@redhat.com>
1065
1066 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
1067 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
1068
c0998828 10692015-12-15 Ilya Verbin <ilya.verbin@intel.com>
1070
1071 * c-common.c (c_common_attribute_table): Handle "omp declare target
1072 link" attribute.
1073
7ca909c6 10742015-12-14 Jakub Jelinek <jakub@redhat.com>
1075
1076 PR c/68833
1077 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
1078
d9102cbe 10792014-12-12 Tobias Burnus <burnus@net-b.de>
1080
1081 PR fortran/68815
1082 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
1083 specifiers (%d, %i,%u and %c).
1084
a515ebdf 10852015-12-10 David Malcolm <dmalcolm@redhat.com>
1086
1087 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
1088
31ba81bd 10892015-12-08 Jakub Jelinek <jakub@redhat.com>
1090
1091 PR c/48088
1092 PR c/68657
1093 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
1094 * c-pragma.c (handle_pragma_diagnostic): Adjust
1095 control_warning_option caller.
1096
d0f713f4 10972015-12-07 David Malcolm <dmalcolm@redhat.com>
1098
1099 * c-common.c (c_cpp_error): Update for change to
1100 rich_location::set_range.
1101
32d050b5 11022015-12-04 Paolo Bonzini <bonzini@gnu.org>
1103
1104 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
1105 shifting 1 out of the sign bit.
1106
11072015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
1108
1109 * c-common.c (c_common_attribute_table[]): Update max arguments
1110 count for "simd" attribute.
1111 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
1112
6a8fbd7a 11132015-12-03 Jakub Jelinek <jakub@redhat.com>
1114
1115 PR preprocessor/57580
1116 * c-ppoutput.c (print): Change printed field to bool.
1117 Move src_file last for smaller padding.
1118 (init_pp_output): Set print.printed to false instead of 0.
1119 (scan_translation_unit): Fix up formatting. Set print.printed
1120 to true after printing something other than newline.
1121 (scan_translation_unit_trad): Set print.printed to true instead of 1.
1122 (maybe_print_line_1): Set print.printed to false instead of 0.
1123 (print_line_1): Likewise.
1124 (do_line_change): Set print.printed to true instead of 1.
1125 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
1126 dump_macro): Set print.printed to false after printing newline.
1127
da562e32 11282015-12-02 Jason Merrill <jason@redhat.com>
1129
9c691dbd 1130 * c-common.c (fold_for_warn): New.
1131 (warn_logical_operator, warn_tautological_cmp)
1132 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
1133
da562e32 1134 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
1135 (c_fully_fold_internal, decl_constant_value_for_optimization):
1136 Move to c/c-fold.c.
1137 * c-common.h: Don't declare decl_constant_value_for_optimization.
1138
89f16034 11392015-12-02 Joseph Myers <joseph@codesourcery.com>
1140
1141 PR c/68162
1142 * c-common.h (c_build_qualified_type): Add extra default
1143 arguments.
1144
571b3486 11452015-12-01 Julian Brown <julian@codesourcery.com>
1146 Cesar Philippidis <cesar@codesourcery.com>
1147 James Norris <James_Norris@mentor.com>
1148
1149 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
1150 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
1151 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
1152
ed92a461 11532015-11-30 Eric Botcazou <ebotcazou@adacore.com>
1154
1155 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
1156 (decl_sloc_common): Delete and move bulk of processing to...
1157 (decl_sloc): ...here.
1158 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
1159 (dump_ada_double_name): Remove S parameter and compute the suffix.
1160 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
1161 element type and deal with an anonymous one.
1162 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
1163 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
1164 and remove reference to QUAL_UNION_TYPE.
1165 (dump_nested_types): Make 2 passes on the fields and move bulk to...
1166 (dump_nested_type): ...here. New function extracted from above.
1167 Generate a full declaration for anonymous element type of arrays.
1168 (print_ada_declaration): Really skip anonymous declarations. Remove
1169 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
1170 Clean up processing of declarations of array types and objects.
1171 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
1172 Remove obsolete code and tidy up.
1173
c25b3e3f 11742015-11-29 Jan Hubicka <hubicka@ucw.cz>
1175
1176 PR c/67581
1177 * c-common.c (handle_transparent_union_attribute): Update
1178 also type variants.
1179
d4e328e9 11802015-11-27 Martin Liska <mliska@suse.cz>
1181
1182 PR c++/68312
1183 * array-notation-common.c (cilkplus_extract_an_triplets):
1184 Release vector of vectors.
1185 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
1186
f63d9c4e 11872015-11-26 Eric Botcazou <ebotcazou@adacore.com>
1188
1189 PR c++/68527
1190 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
1191 (print_ada_struct_decl): Likewise.
1192
8d63c601 11932015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
1194
1195 PR c++/68001
1196 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
1197 * cilk.c (recognize_spawn): Determine location in a more precise
1198 way.
1199
01f11119 12002015-11-19 Jason Merrill <jason@redhat.com>
1201
1202 * c-common.c (shorten_compare): But look through macros from
1203 system headers.
1204
2d3d3af7 12052015-11-18 Jason Merrill <jason@redhat.com>
1206
1207 * c-common.c (shorten_compare): Don't -Wtype-limits if the
1208 non-constant operand comes from a macro.
1209
7991eeee 12102015-11-17 Jason Merrill <jason@redhat.com>
1211
1212 PR bootstrap/68346
1213 * c-common.c (warn_tautological_cmp): Fold before checking for
1214 constants.
1215
73f67931 12162015-11-16 Marek Polacek <polacek@redhat.com>
1217
1218 PR c++/68362
1219 * c-common.c (check_case_bounds): Fold low and high cases.
1220
8e539fdc 12212015-11-16 Marek Polacek <polacek@redhat.com>
1222
1223 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
1224 * c-common.c (c_common_get_alias_set): Likewise.
1225 (handle_visibility_attribute): Likewise.
1226
c58a4cfd 12272015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
1228
1229 * c-common.c (handle_simd_attribute): New.
1230 (struct attribute_spec): Add entry for "simd".
1231 (handle_simd_attribute): New.
1232
bb036391 12332015-11-13 Kai Tietz <ktietz70@googlemail.com>
1234
1235 * c-lex.c (interpret_float): Use fold_convert.
1236
a96cefb2 12372015-11-13 David Malcolm <dmalcolm@redhat.com>
1238
1239 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
1240 and store it on the result.
1241 * c-opts.c (c_common_init_options): Set
1242 global_dc->colorize_source_p.
1243
2fc5e987 12442015-11-12 James Norris <jnorris@codesourcery.com>
1245 Joseph Myers <joseph@codesourcery.com>
1246
1247 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
1248 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
1249 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
1250 PRAGMA_OACC_CLAUSE_LINK.
1251
81b1b2a8 12522015-11-11 Marek Polacek <polacek@redhat.com>
1253
1254 PR c/68107
1255 PR c++/68266
1256 * c-common.c (valid_array_size_p): New function.
1257 * c-common.h (valid_array_size_p): Declare.
1258
92a44a68 12592015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4f3707ca 1260
1261 PR bootstrap/68271
1262 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
1263
6e803544 12642015-11-11 Andrew MacLeod <amacleod@redhat.com>
1265
1266 * array-notation-common.c: Remove unused header files.
1267 * c-ada-spec.c: Likewise.
1268 * c-cilkplus.c: Likewise.
1269 * c-common.c: Likewise.
1270 * c-cppbuiltin.c: Likewise.
1271 * c-dump.c: Likewise.
1272 * c-format.c: Likewise.
1273 * c-gimplify.c: Likewise.
1274 * c-indentation.c: Likewise.
1275 * c-lex.c: Likewise.
1276 * c-omp.c: Likewise.
1277 * c-opts.c: Likewise.
1278 * c-pch.c: Likewise.
1279 * c-ppoutput.c: Likewise.
1280 * c-pragma.c: Likewise.
1281 * c-pretty-print.c: Likewise.
1282 * c-semantics.c: Likewise.
1283 * c-ubsan.c: Likewise.
1284 * cilk.c: Likewise.
1285 * stub-objc.c: Likewise.
1286
a1b7fe4b 12872015-11-09 Thomas Schwinge <thomas@codesourcery.com>
1288 Cesar Philippidis <cesar@codesourcery.com>
1289 James Norris <jnorris@codesourcery.com>
1290 Julian Brown <julian@codesourcery.com>
1291 Nathan Sidwell <nathan@codesourcery.com>
1292
1293 * c-pragma.c (oacc_pragmas): Add "routine".
1294 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
1295
292237f3 12962015-11-08 Eric Botcazou <ebotcazou@adacore.com>
1297
1298 * c-common.c (c_common_attributes): Add scalar_storage_order.
1299 (handle_scalar_storage_order_attribute): New function.
1300 * c-pragma.c (global_sso): New variable.
1301 (maybe_apply_pragma_scalar_storage_order): New function.
1302 (handle_pragma_scalar_storage_order): Likewise.
1303 (init_pragma): Register scalar_storage_order.
1304 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
1305 * c.opt (Wscalar-storage-order): New warning.
1306 (fsso-struct=): New option.
1307
b4a4c5fa 13082015-11-08 Martin Sebor <msebor@redhat.com>
1309
1310 * c.opt (Wplacement-new): Add a period to the end of a sentence.
1311
ac677063 13122015-11-07 Richard Sandiford <richard.sandiford@arm.com>
1313
1314 * c-common.c: Don't undef DEF_BUILTIN.
1315
f0479000 13162015-11-06 David Malcolm <dmalcolm@redhat.com>
1317
1318 * c-common.c (c_cpp_error): Convert parameter from location_t to
1319 rich_location *. Eliminate the "column_override" parameter and
1320 the call to diagnostic_override_column.
1321 Update the "done_lexing" clause to set range 0
1322 on the rich_location, rather than overwriting a location_t.
1323 * c-common.h (c_cpp_error): Convert parameter from location_t to
1324 rich_location *. Eliminate the "column_override" parameter.
1325
ef014f95 13262015-11-05 Cesar Philippidis <cesar@codesourcery.com>
1327 Thomas Schwinge <thomas@codesourcery.com>
1328 James Norris <jnorris@codesourcery.com>
1329
1330 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
1331 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
1332 clauses with parallel and kernels and loops.
1333 * c-pragma.h (enum pragma_omp_clause): Add entries for
1334 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
1335 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
1336 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
1337 INDEPENDENT,SEQ}.
1338 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
1339
e520488c 13402015-11-05 Martin Sebor <msebor@redhat.com>
1341
1342 PR c++/67942
1343 * c.opt (-Wplacement-new): New option.
1344
9561765e 13452015-11-05 Jakub Jelinek <jakub@redhat.com>
1346
1347 * c-common.h (c_finish_omp_atomic): Add TEST argument.
1348 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
1349 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
1350 save_expr or create_tmp_var* if TEST is true.
1351 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
1352 Don't call add_stmt here.
1353 (struct c_omp_check_loop_iv_data): New type.
1354 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
1355 c_omp_check_loop_iv_exprs): New functions.
1356 (c_omp_split_clauses): Adjust for lastprivate being allowed on
1357 distribute.
1358 (c_omp_declare_simd_clauses_to_numbers): Change
1359 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
1360 (c_omp_declare_simd_clauses_to_decls): Similarly change those
1361 from numbers to PARM_DECLs.
1362
5e8689fb 13632015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
1364
1365 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
1366 flag_checking.
1367
92a44a68 13682015-11-03 Bernd Schmidt <bschmidt@redhat.com>
aeaccb75 1369
1370 PR c++-common/67882
32d050b5 1371 * c-common.h (fold_offsetof_1): Add argument.
1372 * c-common.c (fold_offsetof_1): Diagnose more invalid
aeaccb75 1373 offsetof expressions that reference elements past the end of
1374 an array.
1375
9e10bfb7 13762015-11-03 Thomas Schwinge <thomas@codesourcery.com>
1377 Chung-Lin Tang <cltang@codesourcery.com>
1378
1379 * c-pragma.c (oacc_pragmas): Add "atomic".
1380 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
1381
ab50af2a 13822015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
1383
1384 * c-common.c (handle_target_clones_attribute): New.
1385 (c_common_attribute_table): Add handle_target_clones_attribute.
1386 (handle_always_inline_attribute): Add check on target_clones attribute.
1387 (handle_target_attribute): Ditto.
1388
4cba6f60 13892015-10-29 Andrew MacLeod <amacleod@redhat.com>
1390
1391 * array-notation-common.c: Reorder #include's and remove duplicates.
1392 * c-ada-spec.c: Likewise.
1393 * c-cilkplus.c: Likewise.
1394 * c-common.c: Likewise.
1395 * c-cppbuiltin.c: Likewise.
1396 * c-dump.c: Likewise.
1397 * c-format.c: Likewise.
1398 * c-gimplify.c: Likewise.
1399 * c-indentation.c: Likewise.
1400 * c-lex.c: Likewise.
1401 * c-omp.c: Likewise.
1402 * c-opts.c: Likewise.
1403 * c-pch.c: Likewise.
1404 * c-ppoutput.c: Likewise.
1405 * c-pragma.c: Likewise.
1406 * c-pretty-print.c: Likewise.
1407 * c-semantics.c: Likewise.
1408 * c-ubsan.c: Likewise.
1409 * cilk.c: Likewise.
1410 * stub-objc.c: Likewise.
1411
f576a2e4 14122015-10-28 Jason Merrill <jason@redhat.com>
1413
1414 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
1415
2c4c8725 14162015-10-27 Thomas Schwinge <thomas@codesourcery.com>
1417 James Norris <jnorris@codesourcery.com>
1418 Cesar Philippidis <cesar@codesourcery.com>
1419
1420 PR c/64765
1421 PR c/64880
1422 * c-common.h (c_oacc_split_loop_clauses): Declare function.
1423 * c-omp.c (c_oacc_split_loop_clauses): New function.
1424
8204c077 14252015-10-21 Martin Sebor <msebor@redhat.com>
1426
1427 PR driver/68043
1428 * c.opt: End each sentence that describes an option with a period.
1429
8523243e 14302015-10-20 Marek Polacek <polacek@redhat.com>
1431
1432 * array-notation-common.c (is_cilkplus_vector_p): Define.
1433 * c-common.h (is_cilkplus_vector_p): Declare.
1434
08881cb8 14352015-10-20 Marek Polacek <polacek@redhat.com>
1436
1437 * c.opt (std=gnu++11): Do not describe as experimental.
1438 (std=gnu++14): Likewise.
1439
a36e5e5e 14402015-10-19 Jason Merrill <jason@redhat.com>
1441
1442 * c-cppbuiltin.c (c_cpp_builtins): Define
1443 __cpp_nontype_template_args.
1444
a349de0a 14452015-10-19 Jason Merrill <jason@redhat.com>
1446
1447 * c-cppbuiltin.c (c_cpp_builtins): Define
1448 __cpp_enumerator_attributes, __cpp_fold_expressions,
1449 __cpp_unicode_characters.
1450
43895be5 14512015-10-13 Jakub Jelinek <jakub@redhat.com>
1452 Aldy Hernandez <aldyh@redhat.com>
1453
1454 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
1455 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
1456 (c_define_builtins): Likewise.
1457 * c-common.h (enum c_omp_clause_split): Add
1458 C_OMP_CLAUSE_SPLIT_TASKLOOP.
1459 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
1460 (c_finish_omp_for): Add ORIG_DECLV argument.
1461 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
1462 201511 instead of 201307.
1463 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
1464 OMP_CRITICAL_CLAUSES to it.
1465 (c_finish_omp_ordered): Add CLAUSES argument, set
1466 OMP_ORDERED_CLAUSES to it.
1467 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
1468 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
1469 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
1470 constructs and new OpenMP 4.5 clauses. Clear
1471 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
1472 verification code.
1473 * c-pragma.c (omp_pragmas_simd): Add taskloop.
1474 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
1475 (enum pragma_omp_clause): Add
1476 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
1477 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
1478
20cb53c9 14792015-10-05 Richard Sandiford <richard.sandiford@arm.com>
1480
1481 * c-lex.c (interpret_float): Use real_equal instead of
1482 REAL_VALUES_EQUAL.
1483
6d02e6b2 14842015-10-04 Jason Merrill <jason@redhat.com>
1485
1486 Implement N4514, C++ Extensions for Transactional Memory.
1487 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
1488 (c_common_attribute_table): Add transaction_safe_dynamic.
1489 transaction_safe now affects type identity.
1490 (handle_tm_attribute): Handle transaction_safe_dynamic.
1491 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
1492 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
1493 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
1494 (D_TRANSMEM): New.
1495 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
1496 * c-pretty-print.c (pp_c_attributes_display): Don't print
1497 transaction_safe in C++.
1498
c0999a5d 14992015-10-02 Marek Polacek <polacek@redhat.com>
1500
1501 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
1502
ef17a71a 15032015-10-02 Marek Polacek <polacek@redhat.com>
1504
1505 PR c/64249
1506 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
1507 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
1508 * c.opt (Wduplicated-cond): New option.
1509
05b84e7b 15102015-10-01 Joseph Myers <joseph@codesourcery.com>
1511
1512 * c.opt (std=c11): Do not describe as experimental.
1513 (std=gnu11): Likewise.
1514 (std=iso9899:2011): Likewise.
1515
e561d5e1 15162015-09-28 Nathan Sidwell <nathan@codesourcery.com>
1517
1518 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
1519 (DEF_FUNCTION_TYPE_VAR_11): Delete.
1520
bd4b90d2 15212015-09-25 Marek Polacek <polacek@redhat.com>
1522
1523 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
1524 (ubsan_instrument_shift): Likewise.
1525
ac13b2b2 15262015-09-25 Marek Polacek <polacek@redhat.com>
1527
1528 PR sanitizer/64906
1529 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
1530
a3c82f4c 15312015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
1532
1533 * c-indentation.c (should_warn_for_misleading_indentation):
1534 Compare next_stmt_vis_column with guard_line_first_nws instead
1535 of with guard_line_vis_column.
1536
5eef101d 15372015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
1538
1539 PR c/49654
1540 PR c/49655
1541 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
1542 options and options not valid for the current language.
1543
60897493 15442015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
1545
1546 * c-indentation.c (should_warn_for_misleading_indentation):
1547 Float out and consolidate the calls to get_visual_column that
1548 are passed guard_exploc as an argument. Compare
1549 next_stmt_vis_column with guard_line_first_nws instead of with
1550 body_line_first_nws.
1551
85c93154 15522015-09-22 Nathan Sidwell <nathan@codesourcery.com>
1553
1554 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
1555 Wnamespaces): New C++ warnings.
1556
229a58b1 15572015-09-22 Jason Merrill <jason@redhat.com>
1558
1559 * c-common.h (abi_compat_version_crosses): New.
1560 (warn_abi_version): Declare.
1561 * c-common.c: Define it.
1562 * c-opts.c (c_common_post_options): Handle it.
1563 flag_abi_compat_version defaults to 8.
1564
2d2de569 15652015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
1566
1567 Complete the implementation of N4230, Nested namespace definition.
1568 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
1569 __cpp_nested_namespace_definitions.
1570
2b897e68 15712015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
1572
1573 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
1574
ed536208 15752015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
1576
1577 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
1578 when warning.
1579 * c-pragma.h (pragma_lex): Add optional loc argument.
1580
1dc6c44d 15812015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
1582
1583 * c-format.c (check_format_arg): Adjust to use common block size in all
1584 object pools.
1585
be812248 15862015-09-15 David Malcolm <dmalcolm@redhat.com>
1587
1588 * c-format.c (location_from_offset): Update for change in
1589 signature of location_get_source_line.
1590 * c-indentation.c (get_visual_column): Likewise.
1591 (line_contains_hash_if): Likewise.
1592
e4cc057f 15932015-09-14 Marek Polacek <polacek@redhat.com>
1594
1595 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
1596 setting various warnings.
1597
85f5e2ee 15982015-09-14 Marek Polacek <polacek@redhat.com>
1599
1600 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
1601 a negative value.
1602
1bca8cbd 16032015-09-11 Mark Wielaard <mjw@redhat.com>
1604
1605 PR c/28901
1606 * c.opt (Wunused-variable): Option from common.opt.
1607 (Wunused-const-variable): New option.
1608
ee48893a 16092015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
1610
1611 PR c++/53184
1612 * c.opt ([Wsubobject-linkage]): Add.
1613
547c6b1f 16142015-09-03 Martin Sebor <msebor@redhat.com>
1615
1616 PR c/66516
1617 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
1618 functions.
1619 * c-common.c (reject_gcc_builtin): Define.
1620
7e976b10 16212015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
1622
1623 PR middle-end/60586
1624 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
1625 prototype.
1626 * c-gimplify.c (c_gimplify_expr): Added a call to the function
1627 cilk_gimplify_call_params_in_spawned_fn.
1628 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
1629 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
1630 unwrapping.
1631
9e6bcade 16322015-08-25 Marek Polacek <polacek@redhat.com>
1633
1634 PR middle-end/67330
1635 * c-common.c (handle_weak_attribute): Don't check whether the
1636 visibility can be changed here.
1637
af9de21d 16382015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
1639
1640 * c-lex.c (c_lex_with_flags): Use explicit locations.
1641
6dc50383 16422015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
1643
1644 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
1645 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
1646
10902624 16472015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1648
1649 PR middle-end/36757
1650 * c-common.c (check_builtin_function_arguments): Add check
1651 for BUILT_IN_SIGNBIT argument.
1652
a03a71ab 16532015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
1654
1655 PR c++/67160
1656 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
1657 in c++1z mode.
1658
22723c26 16592015-08-17 Marek Polacek <polacek@redhat.com>
1660
1661 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
1662 with whitespaces before qualifier names.
1663
f4809955 16642015-08-12 Marek Polacek <polacek@redhat.com>
1665
1666 PR c++/55095
1667 * c-common.c (maybe_warn_shift_overflow): Properly handle
1668 left-shifting 1 into the sign bit.
1669
5463f502 16702015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
1671
1672 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
1673
56c12fd4 16742015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
1675 Braden Obrzut <admin@maniacsvault.net>
1676 Jason Merrill <jason@redhat.com>
1677
1678 Add C++ Concepts TS support.
1679 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
1680 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
1681 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
1682 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
1683 * c-opts.c (set_std_cxx1z): Set flag_concepts.
1684 * c.opt (fconcepts): New.
1685
32d050b5 16862015-08-02 Martin Sebor <msebor@redhat.com>
1687
1688 * c.opt (-Wframe-address): New warning option.
1689
17afcef6 16902015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
1691
1692 * c-indentation.c (should_warn_for_misleading_indentation):
1693 Improve heuristics.
1694
f95bfdd4 16952015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
1696
1697 * c-indentation.c (get_visual_column): Add parameter first_nws,
1698 use it. Update comment documenting the function.
1699 (is_first_nonwhitespace_on_line): Remove.
1700 (should_warn_for_misleading_indentation): Replace usage of
1701 of is_first_nonwhitespace_on_line with get_visual_column.
1702
9255be07 17032015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
1704
1705 * c-indentation.h (struct token_indent_info): Define.
1706 (get_token_indent_info): Define.
1707 (warn_for_misleading_information): Declare.
1708 * c-common.h (warn_for_misleading_information): Remove.
1709 * c-identation.c (warn_for_misleading_indentation):
1710 Change declaration to take three token_indent_infos. Adjust
1711 accordingly.
1712 * c-identation.c (should_warn_for_misleading_indentation):
1713 Likewise. Bail out early if the body is a compound statement.
1714 (guard_tinfo_to_string): Define.
1715
e880695c 17162015-07-30 Jason Merrill <jason@redhat.com>
1717
1718 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
1719 '*' for reference decay.
1720
f58dd84b 17212015-07-30 Marek Polacek <polacek@redhat.com>
1722
1723 * c-common.c (warn_tautological_cmp): Bail for float types.
1724
d9e4fe27 17252015-07-27 Marek Polacek <polacek@redhat.com>
1726
1727 PR bootstrap/67030
1728 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
1729
6784a472 17302015-07-27 Marek Polacek <polacek@redhat.com>
1731
1732 PR c++/66555
1733 PR c/54979
1734 * c-common.c (find_array_ref_with_const_idx_r): New function.
1735 (warn_tautological_cmp): New function.
1736 * c-common.h (warn_tautological_cmp): Declare.
1737 * c.opt (Wtautological-compare): New option.
1738
08034975 17392015-07-23 Marek Polacek <polacek@redhat.com>
1740
1741 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
1742 (ubsan_instrument_shift): Likewise.
1743
f6f5e49b 17442015-07-23 Marek Polacek <polacek@redhat.com>
1745
1746 PR sanitizer/66908
1747 * c-ubsan.c: Include gimplify.h.
1748 (ubsan_instrument_division): Unshare OP0 and OP1.
1749 (ubsan_instrument_shift): Likewise.
1750
8d669e79 17512015-07-20 Marek Polacek <polacek@redhat.com>
1752 Richard Sandiford <richard.sandiford@arm.com>
1753
1754 PR c++/55095
1755 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
1756 Use EXPR_LOC_OR_LOC.
1757 (maybe_warn_shift_overflow): New function.
1758 * c-common.h (maybe_warn_shift_overflow): Declare.
1759 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
1760 * c.opt (Wshift-overflow): New option.
1761
e16712b1 17622015-07-16 Martin Liska <mliska@suse.cz>
1763
1764 * c-format.c (static void check_format_info_main): Use
1765 object_allocator instead of pool_allocator.
1766 (check_format_arg): Likewise.
1767 (check_format_info_main): Likewise.
1768
e51764ad 17692015-07-15 Andrew MacLeod <amacleod@redhat.com>
1770
1771 * c-opts.c: Remove multiline #include comment.
1772
47ae02b7 17732015-07-12 Aldy Hernandez <aldyh@redhat.com>
1774
1775 * c-common.c: Fix double word typos.
1776
ed2b2eb2 17772015-07-10 Eric Botcazou <ebotcazou@adacore.com>
1778
1779 * c-ada-spec.h (cpp_operation): Revert latest change.
1780 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
1781 constructors and destructors.
1782
1eacc14a 17832015-07-09 Andrew MacLeod <amacleod@redhat.com>
1784
1785 * c-common.h: Adjust includes for flags.h changes.
1786 * stub-objc.c: Likewise.
47ae02b7 1787
0124237f 17882015-07-08 Eric Botcazou <ebotcazou@adacore.com>
1789
1790 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
1791 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
1792
386ef929 17932015-07-08 Jakub Jelinek <jakub@redhat.com>
1794
1795 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
1796 are to be removed, return NULL rather than original clauses list.
1797
9ef16211 17982015-07-07 Andrew MacLeod <amacleod@redhat.com>
1799
1800 * array-notation-common.c: Adjust includes.
1801 * c-ada-spec.c: Likewise.
1802 * c-cilkplus.c: Likewise.
1803 * c-common.h: Likewise.
1804 * c-cppbuiltin.c: Likewise.
1805 * c-dump.c: Likewise.
1806 * c-format.c: Likewise.
1807 * c-gimplify.c: Likewise.
1808 * c-indentation.c: Likewise.
1809 * c-lex.c: Likewise.
1810 * c-omp.c: Likewise.
1811 * c-opts.c: Likewise.
1812 * c-pch.c: Likewise.
1813 * c-ppoutput.c: Likewise.
1814 * c-pragma.c: Likewise.
1815 * c-pretty-print.c: Likewise.
1816 * c-semantics.c: Likewise.
1817 * c-ubsan.c: Likewise.
1818 * cilk.c: Likewise.
1819 * stub-objc.c: Likewise.
1820
67ede3e4 18212015-07-07 Eric Botcazou <ebotcazou@adacore.com>
1822
1823 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
1824 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
1825
42af8c2a 18262015-07-01 Jason Merrill <jason@redhat.com>
1827
fa769cc5 1828 * c-common.h (D_CXX11): Rename from D_CXX0X.
1829 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
1830 * c-common.c: Adjust.
1831
97e9c847 1832 * c-opts.c (c_common_post_options): Default to C++14.
1833
42af8c2a 1834 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
1835
30b1ba42 18362015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
1837
1838 Implement N4197 - Adding u8 character literals
32d050b5 1839 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
95858835 1840 CPP_CHAR.
32d050b5 1841 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
95858835 1842 CPP_UTF8CHAR_USERDEF tokens.
32d050b5 1843 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
95858835 1844 and CPP_UTF8CHAR tokens.
1845 (lex_charconst): Treat CPP_UTF8CHAR token.
30b1ba42 1846
0949f227 18472015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
1848
1849 PR fortran/66605
1850 * c-common.c (do_warn_unused_parameter): Move here.
1851 * c-common.h (do_warn_unused_parameter): Declare.
1852
be23b16f 18532015-06-29 Marek Polacek <polacek@redhat.com>
1854
1855 PR c/66322
1856 * c-common.c (check_case_bounds): Add bool * parameter. Set
1857 OUTSIDE_RANGE_P.
1858 (c_add_case_label): Add bool * parameter. Pass it down to
1859 check_case_bounds.
1860 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
1861 warning here.
1862 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
1863 declarations.
1864
6290f0db 18652015-06-27 Marek Polacek <polacek@redhat.com>
1866
1867 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
1868 or VECTOR_INTEGER_TYPE_P throughout.
1869 * c-gimplify.c: Likewise.
1870
aa3e402e 18712015-06-26 Marek Polacek <polacek@redhat.com>
1872
1873 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
1874 * c-common.c (c_fully_fold_internal): Likewise.
1875 (c_alignof_expr): Likewise.
1876 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
1877 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
8204c077 1878 * cilk.c (create_parm_list): Likewise.
aa3e402e 1879
4e81b384 18802015-06-26 Marek Polacek <polacek@redhat.com>
1881
1882 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
1883
ec2e0095 18842015-06-25 Andrew MacLeod <amacleod@redhat.com>
1885
1886 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
1887 * c-gimplify.c: Likewise.
1888 * c-pragma.c: Likewise.
1889 * c-ubsan.c: Likewise.
1890 * cilk.c: Likewise.
1891
b594087e 18922015-06-25 Richard Sandiford <richard.sandiford@arm.com>
1893
1894 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
1895 ggc_hasher.
1896
a3c76fda 18972015-06-25 Andrew MacLeod <amacleod@redhat.com>
1898
1899 * cilk.c: Move calls.h after tm.h in the include chain.
1900
f48c7f4a 19012015-06-25 Marek Polacek <polacek@redhat.com>
1902
1903 * array-notation-common.c: Use VAR_P throughout.
1904 * c-ada-spec.c: Likewise.
1905 * c-common.c: Likewise.
1906 * c-format.c: Likewise.
1907 * c-gimplify.c: Likewise.
1908 * c-omp.c: Likewise.
1909 * c-pragma.c: Likewise.
1910 * c-pretty-print.c: Likewise.
1911 * cilk.c: Likewise.
1912
ce41e81a 19132015-06-25 Marek Polacek <polacek@redhat.com>
1914
1915 * cilk.c (extract_free_variables): Use is_global_var.
1916
de231ec2 19172015-06-23 Richard Sandiford <richard.sandiford@arm.com>
1918
1919 * c-common.c: Don't include target-def.h.
1920
0200602e 19212015-06-23 Marek Polacek <polacek@redhat.com>
1922
1923 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
1924 when comparing INTEGER_CSTs.
1925
99838ed7 19262015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
1927
1928 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
1929 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
1930 (dump_ada_template): Skip partially specialized types.
1931
a4f59596 19322015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
1933
1934 * c-common.c (scalar_to_vector): Use std::swap instead of manually
1935 swapping.
1936
f2ab3bac 19372015-06-17 Andrew MacLeod <amacleod@redhat.com>
1938
1939 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
1940 * c-ada-spec.c: Likewise.
1941 * c-cilkplus.c: Likewise.
1942 * c-common.c: Likewise.
1943 * c-common.h: Likewise.
1944 * c-cppbuiltin.c: Likewise.
1945 * c-dump.c: Likewise.
1946 * c-format.c: Likewise.
1947 * c-gimplify.c: Likewise.
1948 * c-indentation.c: Likewise.
1949 * c-lex.c: Likewise.
1950 * c-omp.c: Likewise.
1951 * c-opts.c: Likewise.
1952 * c-pch.c: Likewise.
1953 * c-ppoutput.c: Likewise.
1954 * c-pragma.c: Likewise.
1955 * c-pretty-print.c: Likewise.
1956 * c-semantics.c: Likewise.
1957 * c-ubsan.c: Likewise.
1958 * cilk.c: Likewise.
1959 * stub-objc.c: Likewise.
1960
db3d1ffc 19612015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
1962
1963 PR c++/65168
1964 * c-common.c (c_common_truthvalue_conversion): Warn when
1965 converting an address of a reference to a truth value.
1966
64486212 19672015-06-08 Andrew MacLeod <amacleod@redhat.com>
1968
1969 * array-notation-common.c : Adjust include files.
1970 * c-ada-spec.c : Likewise.
1971 * c-cilkplus.c : Likewise.
1972 * c-common.c : Likewise.
1973 * c-common.h : Likewise.
1974 * c-cppbuiltin.c : Likewise.
1975 * c-dump.c : Likewise.
1976 * c-format.c : Likewise.
1977 * c-gimplify.c : Likewise.
1978 * c-indentation.c : Likewise.
1979 * c-lex.c : Likewise.
1980 * c-omp.c : Likewise.
1981 * c-opts.c : Likewise.
1982 * c-pch.c : Likewise.
1983 * c-ppoutput.c : Likewise.
1984 * c-pragma.c : Likewise.
1985 * c-pretty-print.c : Likewise.
1986 * c-semantics.c : Likewise.
1987 * c-ubsan.c : Likewise.
1988 * cilk.c : Likewise.
1989 * stub-objc.c : Likewise.
1990
6e84ccad 19912015-06-08 Marek Polacek <polacek@redhat.com>
1992
1993 PR c/66415
1994 * c-format.c (location_from_offset): Return LOC if LINE is null.
1995
3a1c9df2 19962015-06-05 Aldy Hernandez <aldyh@redhat.com>
1997
1998 * c-common.h (c_parse_final_cleanups): New prototype.
1999 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
2000
32d050b5 20012015-06-04 Sriraman Tallam <tmsriram@google.com>
2002
2003 * c-common.c (noplt): New attribute.
2004 (handle_noplt_attribute): New handler.
2005
f77c0292 20062015-06-04 Andrew MacLeod <amacleod@redhat.com>
2007
2008 * array-notation-common.c: Adjust includes for restructured coretypes.h.
2009 * c-ada-spec.c: Likewise.
2010 * c-cilkplus.c: Likewise.
2011 * c-common.c: Likewise.
2012 * c-common.h: Likewise.
2013 * c-cppbuiltin.c: Likewise.
2014 * c-dump.c: Likewise.
2015 * c-format.c: Likewise.
2016 * c-gimplify.c: Likewise.
2017 * c-indentation.c: Likewise.
2018 * c-lex.c: Likewise.
2019 * c-omp.c: Likewise.
2020 * c-opts.c: Likewise.
2021 * c-pch.c: Likewise.
2022 * c-ppoutput.c: Likewise.
2023 * c-pragma.c: Likewise.
2024 * c-pretty-print.c: Likewise.
2025 * c-semantics.c: Likewise.
2026 * c-ubsan.c: Likewise.
2027 * cilk.c: Likewise.
2028 * stub-objc.c: Likewise.
2029
7c62dfbb 20302015-06-02 David Malcolm <dmalcolm@redhat.com>
2031
2032 PR c/66220:
2033 * c-indentation.c (should_warn_for_misleading_indentation): Use
2034 expand_location rather than expand_location_to_spelling_point.
2035 Don't warn if the guarding statement is more indented than the
2036 next/body stmts.
2037
9af7c176 20382015-06-02 David Malcolm <dmalcolm@redhat.com>
2039
2040 * c-indentation.c (warn_for_misleading_indentation): Bail out
2041 immediately if -Wmisleading-indentation isn't enabled.
2042
eebcf436 20432015-06-01 Martin Liska <mliska@suse.cz>
2044
2045 * c-format.c (check_format_arg):Use new type-based pool allocator.
2046 (check_format_info_main) Likewise.
2047
b0a23e2f 20482015-05-31 Eric Botcazou <ebotcazou@adacore.com>
2049
2050 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
2051 (has_nontrivial_methods): Likewise.
2052
63dc1330 20532015-05-25 Marek Polacek <polacek@redhat.com>
2054
2055 * c-ubsan.c (ubsan_instrument_shift): Use type0.
2056
5a4c69dd 20572015-05-22 Marek Polacek <polacek@redhat.com>
2058
2059 PR c/47043
2060 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
2061
044580bb 20622015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
3764c94e 2063
2064 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
2065 STACK_GROWS_DOWNWARD.
2066
044580bb 20672015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
2b785411 2068
2069 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
2070 STACK_GROWS_DOWNWARD rather than if it is defined.
2071
d5a2ddc7 20722015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
8204c077 2073
d5a2ddc7 2074 PR c/52952
2075 * c-format.c (location_column_from_byte_offset): New.
2076 (location_from_offset): New.
2077 (struct format_wanted_type): Add offset_loc field.
2078 (check_format_info): Move handling of location for extra arguments
2079 closer to the point of warning.
2080 (check_format_info_main): Pass the result of location_from_offset
2081 to warning_at.
2082 (format_type_warning): Pass the result of location_from_offset
2083 to warning_at.
2084
72f8014e 20852015-05-20 Marek Polacek <polacek@redhat.com>
2086
2087 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
2088
74efe522 20892015-05-20 Marek Polacek <polacek@redhat.com>
2090
2091 * c-ada-spec.c (dump_sloc): Use DECL_P.
2092
b443c459 20932015-05-20 Marek Polacek <polacek@redhat.com>
2094
2095 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
2096 * c-common.c: Likewise.
2097
551e34da 20982015-05-19 David Malcolm <dmalcolm@redhat.com>
2099
2100 * c-common.h (fe_file_change): Strengthen param from
2101 const line_map * to const line_map_ordinary *.
2102 (pp_file_change): Likewise.
2103 * c-lex.c (fe_file_change): Likewise.
2104 (cb_define): Use linemap_check_ordinary when invoking
2105 SOURCE_LINE.
2106 (cb_undef): Likewise.
2107 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
2108 invoking cb_file_change.
2109 (c_finish_options): Likewise.
2110 (push_command_line_include): Likewise.
2111 (cb_file_change): Strengthen param "new_map" from
2112 const line_map * to const line_map_ordinary *.
2113 * c-ppoutput.c (cb_define): Likewise for local "map".
2114 (pp_file_change): Likewise for param "map" and local "from".
2115
dfcf26a5 21162015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
2117
2118 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
2119
2e474820 21202015-05-18 Tom de Vries <tom@codesourcery.com>
2121
2122 * c-common.c (build_va_arg_1): New function.
2123 (build_va_arg): Add address operator to va_list operand if necessary.
2124
e53013a8 21252015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
2126
2127 PR c/48956
2128 * c-common.c (int_safely_convertible_to_real_p): Define.
2129 (unsafe_conversion_p): Check conversions involving complex types.
2130 (conversion_warning): Add new warning message for conversions which
2131 discard imaginary component.
2132 * c-common.h: (enum conversion_safety): Add new enumerator for such
2133 conversions.
2134
aac24642 21352015-05-14 Marek Polacek <polacek@redhat.com>
2136
2137 PR c/66066
2138 PR c/66127
2139 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
2140 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
2141 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
2142 use it. If FOR_INT_CONST, require that all evaluated operands be
2143 INTEGER_CSTs.
2144
e5f01cba 21452015-05-12 David Malcolm <dmalcolm@redhat.com>
2146
2147 * c-common.h (warn_for_misleading_indentation): New prototype.
2148 * c-indentation.c: New file.
2149 * c.opt (Wmisleading-indentation): New option.
2150
c37be9ec 21512015-05-12 Tom de Vries <tom@codesourcery.com>
2152
2153 PR tree-optimization/66010
2154 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
2155
7290114b 21562015-05-09 Jason Merrill <jason@redhat.com>
2157
3c665566 2158 * c-opts.c (c_common_post_options): Also clear
2159 cpp_opts->cpp_warn_cxx11_compat.
2160
d875b9d2 2161 * c-common.h (enum cxx_dialect): Add cxx_unset.
2162 * c-common.c (cxx_dialect): Initialize to cxx_unset.
2163 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
2164
7290114b 2165 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
2166 (std=gnu++0x): Mark as Undocumented.
2167 (std=gnu++1y): Add deprecated message.
2168
1b03cc89 21692015-05-08 Jason Merrill <jason@redhat.com>
2170
1c5f7aba 2171 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
2172 * c-opts.c: Adjust.
2173
1b03cc89 2174 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
2175
dc5945dc 21762015-05-08 Marek Polacek <polacek@redhat.com>
2177
2178 PR c/64918
2179 * c.opt (Woverride-init-side-effects): New option.
2180
cdc64059 21812015-05-07 Marek Polacek <polacek@redhat.com>
2182
2183 PR c/65179
2184 * c-common.c (c_fully_fold_internal): Warn when left shifting a
2185 negative value.
2186 * c.opt (Wshift-negative-value): New option.
2187 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
2188 when -Wextra and C99/C++11 mode.
2189
8cafe283 21902015-05-07 Marek Polacek <polacek@redhat.com>
2191 Martin Uecker <uecker@eecs.berkeley.edu>
2192
2193 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
2194 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
2195
cb40a6f7 21962015-05-05 Jason Merrill <jason@redhat.com>
2197
2198 * c.opt (Wterminate): New.
2199
14744a16 22002015-04-30 Marek Polacek <polacek@redhat.com>
2201
2202 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
2203 require that the non-constant be of a boolean type.
2204
9866562d 22052015-04-29 Josh Triplett <josh@joshtriplett.org>
2206
8cafe283 2207 * c-common.c (handle_section_attribute): Refactor to reduce
2208 nesting and distinguish between error cases.
9866562d 2209
a720ab1c 22102015-04-29 Marek Polacek <polacek@redhat.com>
2211
2212 PR c/64610
2213 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
2214 with 0/1.
2215
8c072e52 22162015-04-29 Jakub Jelinek <jakub@redhat.com>
2217
2218 * c-common.h (omp_clause_mask): Unconditionally define as a class.
2219 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
2220 HOST_BITS_PER_WIDE_INT.
2221
f7fec1c7 22222015-04-28 Tom de Vries <tom@codesourcery.com>
2223
2224 PR tree-optimization/65887
2225 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
2226
483b3d26 22272015-04-28 Eric Botcazou <ebotcazou@adacore.com>
8cafe283 2228 Pierre-Marie de Rodat <derodat@adacore.com>
483b3d26 2229
2230 * c-ada-spec.c (in_function): Delete.
2231 (dump_generic_ada_node): Do not change in_function and remove the
2232 redundant code dealing with it.
2233 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
2234 (print_ada_methods): Output the static member functions in a nested
2235 package after the regular methods as well as associated renamings.
2236
f11bdffb 22372015-04-24 Marek Polacek <polacek@redhat.com>
2238
2239 PR c/65830
2240 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
2241 and OPT_Wshift_count_overflow.
2242
485f6b9c 2243 PR c/63357
2244 * c-common.c (warn_logical_operator): Warn if the operands have the
2245 same expressions.
2246
439606a9 22472015-04-24 Marek Polacek <polacek@redhat.com>
2248
2249 PR c/61534
2250 * c-common.c (warn_logical_operator): Bail if either operand comes
2251 from a macro expansion.
2252
de801c28 22532015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
2254
2255 PR target/55143
2256 * c-common.c (c_default_pointer_mode): Add definition.
2257 * c-common.h (c_default_pointer_mode): Add declaration.
2258
76738f56 22592015-03-11 Jakub Jelinek <jakub@redhat.com>
2260
2261 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
2262 on record_builtin_type argument.
2263
16f958b3 22642015-03-10 Jakub Jelinek <jakub@redhat.com>
2265
2266 PR c/65120
2267 * c-common.c (warn_logical_not_parentheses): Don't warn for
2268 !x == 0 or !x != 0.
2269
9b22f73f 22702015-03-07 Marek Polacek <polacek@redhat.com>
2271
2272 PR sanitizer/65280
2273 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
2274 before trying to figure out whether we have a flexible array member.
2275
a864b7d4 22762015-03-06 Eric Botcazou <ebotcazou@adacore.com>
2277 Jonathan Wakely <jwakely.gcc@gmail.com>
2278
2279 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
2280
9bf8c90b 22812015-03-05 Eric Botcazou <ebotcazou@adacore.com>
2282
2283 PR ada/65319
2284 * c-ada-spec.c (print_destructor): Remove obsolete code.
2285
037ac54f 22862015-03-01 Eric Botcazou <ebotcazou@adacore.com>
2287
2288 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
2289 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
2290 DECL_TEMPLATE_RESULT emulations.
2291 (dump_ada_template)): Add guard for TYPE_METHODS.
2292
495cbfb8 22932015-02-27 Marek Polacek <polacek@redhat.com>
2294
2295 PR c/65040
2296 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
2297
688a864e 22982015-02-27 Kai Tietz <ktietz@redhat.com>
2299
2300 PR c/35330
2301 * c-pragma.c (handle_pragma_weak): Do not try to create
2302 weak/alias of declarations not being function, or variable
2303 declarations.
2304
6349b8cc 23052015-02-24 Thomas Schwinge <thomas@codesourcery.com>
2306
2307 PR libgomp/64625
2308 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
2309 Remove macros.
2310 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
2311
3afd5369 23122015-02-16 Marek Polacek <polacek@redhat.com>
2313
2314 PR c/65066
2315 * c-format.c (check_format_types): Handle null param.
2316
46173d1b 23172015-02-13 Marek Polacek <polacek@redhat.com>
2318
2319 PR c/65040
2320 * c-format.c (check_format_types): Don't warn about different
2321 signedness if the original value is in the range of WANTED_TYPE.
2322
1d524ff7 23232015-02-12 Jason Merrill <jason@redhat.com>
2324
2325 PR c++/64956
2326 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
2327 to the current highest version.
2328 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
2329
bbf8fbec 23302015-02-04 Jakub Jelinek <jakub@redhat.com>
2331
2332 PR c/64824
2333 PR c/64868
2334 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
2335 instead of RDIV_EXPR. Use build_binary_op instead of
2336 build2_loc.
2337
c05be867 23382015-01-30 Joseph Myers <joseph@codesourcery.com>
2339
2340 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
2341 to pass input_location as first argument.
2342
85977647 23432015-01-23 Tom de Vries <tom@codesourcery.com>
2344
2345 PR libgomp/64672
2346 * c.opt (fopenacc): Mark as LTO option.
2347
fa175926 23482015-01-23 Tom de Vries <tom@codesourcery.com>
2349
2350 PR libgomp/64707
2351 * c.opt (fopenmp): Mark as LTO option.
2352
20aad5ba 23532015-01-21 Jakub Jelinek <jakub@redhat.com>
2354
2355 PR c/63307
8204c077 2356 * cilk.c (fill_decls_vec): Only put decls into vector v.
20aad5ba 2357 (compare_decls): Fix up formatting.
2358
23592015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
2360
2361 PR c/63307
2362 * cilk.c: Include vec.h.
2363 (struct cilk_decls): New structure.
2364 (wrapper_parm_cb): Split this function to...
2365 (fill_decls_vec): ...this...
2366 (create_parm_list): ...and this.
2367 (compare_decls): New function.
2368 (for_local_cb): Remove.
2369 (wrapper_local_cb): Ditto.
2370 (build_wrapper_type): For now first traverse and fill vector of
2371 declarations then sort it and then deal with sorted vector.
2372 (cilk_outline): Ditto.
2373 (declare_one_free_variable): Ditto.
2374
60b77e28 23752015-01-21 Jason Merrill <jason@redhat.com>
2376
2377 PR c++/64629
2378 * c-format.c (check_format_arg): Call decl_constant_value.
2379
85fbea97 23802015-01-19 Martin Liska <mliska@suse.cz>
2381
2382 * c-common.c (handle_noicf_attribute): New function.
2383
ca4c3545 23842015-01-15 Thomas Schwinge <thomas@codesourcery.com>
2385 Bernd Schmidt <bernds@codesourcery.com>
2386 James Norris <jnorris@codesourcery.com>
2387 Cesar Philippidis <cesar@codesourcery.com>
2388 Ilmir Usmanov <i.usmanov@samsung.com>
2389 Jakub Jelinek <jakub@redhat.com>
2390
2391 * c.opt (fopenacc): New option.
2392 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
2393 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
2394 New macros.
2395 * c-common.h (c_finish_oacc_wait): New prototype.
2396 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
2397 (c_finish_oacc_wait): New function.
2398 * c-pragma.c (oacc_pragmas): New variable.
2399 (c_pp_lookup_pragma, init_pragma): Handle it.
2400 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
2401 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
2402 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
2403 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
2404 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
2405 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
2406 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
2407 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
2408 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
2409 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
2410 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
2411 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
2412 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
2413 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
2414 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
2415 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
2416 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
2417 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
2418 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
2419 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
2420 PRAGMA_OACC_CLAUSE_WORKER.
2421
92a44a68 24222015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
947aa916 2423
2424 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
2425 for the new option fstack-protector_explicit.
2426 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
2427 (handle_stack_protect_attribute): New function.
2428
92a44a68 24292015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
e4fd7af1 2430
2431 * c.opt: New option -Warray-bounds=.
2432
1f78217c 24332015-01-09 Michael Collison <michael.collison@linaro.org>
2434
2435 * array-notation-common.c: Include hash-set.h, machmode.h,
2436 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2437 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
2438 * c-ada-spec.c: Ditto.
2439 * c-cilkplus.c: Ditto.
2440 * c-common.c: Include input.h due to flattening of tree.h.
2441 Define macro GCC_C_COMMON_C.
2442 * c-common.h: Flatten tree.h header files into c-common.h.
2443 Remove include of tree-core.h.
2444 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
2445 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2446 fold-const.h, wide-int.h, and inchash.h due to
2447 flattening of tree.h.
2448 * c-dump.c: Ditto.
2449 * c-format.c: Flatten tree.h header files into c-common.h.
2450 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
2451 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2452 fold-const.h, wide-int.h, and inchash.h due to
2453 flattening of tree.h.
2454 * c-dump.c: Include hash-set.h, machmode.h,
2455 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2456 fold-const.h, wide-int.h, and inchash.h due to
2457 flattening of tree.h.
2458 * c-format.c: Include hash-set.h, machmode.h,
2459 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2460 fold-const.h, wide-int.h, inchash.h and real.h due to
2461 flattening of tree.h.
2462 * c-gimplify.c: Include hash-set.h, machmode.h,
2463 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2464 fold-const.h, wide-int.h, and inchash.h due to
2465 flattening of tree.h.
2466 * cilk.c: Ditto.
2467 * c-lex.c: Ditto.
2468 * c-omp.c: Ditto.
2469 * c-opts.c: Ditto.
2470 * c-pch.c: Ditto.
2471 * c-ppoutput.c: Ditto.
2472 * c-pragma.c: Ditto.
2473 * c-pretty-print.c: Ditto.
2474 * c-semantics.c: Ditto.
2475 * c-ubsan.c: Ditto.
2476 * stub-objc.c: Ditto.
2477
411b7663 24782015-01-08 Jason Merrill <jason@redhat.com>
2479
2480 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
2481 do_ubsan_in_current_function.
2482 (ubsan_maybe_instrument_reference_or_call): Likewise.
2483 * c-ubsan.h: Declare it.
2484
d1e96383 24852015-01-08 Mike Stump <mikestump@comcast.net>
2486
2487 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
2488
b57910fa 24892015-01-07 Marek Polacek <polacek@redhat.com>
2490
2491 PR c/64440
2492 * c-common.c (c_fully_fold_internal): Warn for division and modulo
2493 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
2494
678a4e3e 24952015-01-05 Trevor Saunders <tsaunders@mozilla.com>
2496
2497 PR c++/31397
2498 * c.opt (Wsuggest-override): New option.
2499
d353bf18 25002015-01-05 Jakub Jelinek <jakub@redhat.com>
2501
2502 Update copyright years.
2503
92b63884 25042015-01-05 Marek Polacek <polacek@redhat.com>
2505
2506 PR c/64423
2507 * c-common.c (warn_array_subscript_with_type_char): Add location_t
2508 parameter. Use it.
2509 * c-common.h (warn_array_subscript_with_type_char): Update
2510 declaration.
2511
83715bc4 25122014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
2513
2514 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
2515 Control macro with flag_sized_deallocation.
2516
92a44a68 25172014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
8a8211df 2518
2519 * c.opt (Wdiscarded-array-qualifiers): New option.
2520
33058239 25212014-12-19 Jakub Jelinek <jakub@redhat.com>
2522
2523 PR preprocessor/63831
2524 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
2525 and __has_cpp_attribute here.
2526 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
2527 c_common_has_attribute.
2528 * c-common.h (c_common_has_attribute): New prototype.
2529 * c-lex.c (init_c_lex): Set cb->has_attribute to
2530 c_common_has_attribute instead of cb_has_attribute.
2531 (get_token_no_padding): New function.
2532 (cb_has_attribute): Renamed to ...
2533 (c_common_has_attribute): ... this. No longer static. Use
2534 get_token_no_padding, require ()s, don't build TREE_LIST
2535 unnecessarily, fix up formatting, adjust diagnostics, call
2536 init_attributes.
2537
d1856d2c 25382014-12-15 Jason Merrill <jason@redhat.com>
2539
2540 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
2541 (-Wsized-deallocation): New.
2542 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
2543 to on in C++14 and up.
2544
4972ed5d 25452014-12-11 Jason Merrill <jason@redhat.com>
2546
7d7fa964 2547 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
2548
4972ed5d 2549 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
2550 we aren't complaining about VLAs.
2551
5ebccf71 25522014-12-06 Marek Polacek <polacek@redhat.com>
2553
2554 PR tree-optimization/64183
2555 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
2556 shift-expression if it is integer_type_node. Use types_compatible_p.
2557
f9e245b2 25582014-11-29 Jakub Jelinek <jakub@redhat.com>
2559
2560 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
2561 last argument from create_tmp_var_raw and create_tmp_var calls.
2562 * cilk.c (gimplify_cilk_spawn): Likewise.
2563 * c-omp.c (c_finish_omp_atomic): Likewise.
2564
d2f60593 25652014-11-28 Marek Polacek <polacek@redhat.com>
2566
2567 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
2568 instead of unsigned_type_node.
2569
fce2dbd1 25702014-11-28 Marek Polacek <polacek@redhat.com>
2571
2572 PR c/63862
2573 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
2574 to op1_utype.
2575 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
2576 expression to unsigned_type_node.
2577
3a4a2292 25782014-11-20 Mark Wielaard <mjw@redhat.com>
2579
2580 PR debug/38757
2581 * c-opts.c (set_std_c89): Set lang_hooks.name.
2582 (set_std_c99): Likewise.
2583 (set_std_c11): Likewise.
2584 (set_std_cxx98): Likewise.
2585 (set_std_cxx11): Likewise.
2586 (set_std_cxx14): Likewise.
2587 (set_std_cxx1z): Likewise.
2588
c61ef207 25892014-11-21 Jakub Jelinek <jakub@redhat.com>
2590
2591 PR target/63764
2592 * c-common.h (convert_vector_to_pointer_for_subscript): Change
2593 return type to bool.
c9ed79de 2594 * c-common.c: Include gimple-expr.h.
c61ef207 2595 (convert_vector_to_pointer_for_subscript): Change return type to
2596 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
2597 and copy it into a TARGET_EXPR and use that instead of *vecp
2598 directly.
2599
1a91d914 26002014-11-19 David Malcolm <dmalcolm@redhat.com>
2601
2602 Merger of git branch "gimple-classes-v2-option-3".
2603 * ChangeLog.gimple-classes: New.
2604 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
2605 from being just a vec<gimple> to a vec<gbind *>.
2606
f8fc8b8e 26072014-11-18 Jakub Jelinek <jakub@redhat.com>
2608
2609 PR sanitizer/63813
2610 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
2611 argument to ptype, set type to TREE_TYPE (ptype). Don't call
2612 get_pointer_alignment for non-pointers. Use ptype, or if it is
2613 reference type, corresponding pointer type, as type of kind
2614 argument.
2615 (ubsan_maybe_instrument_reference,
2616 ubsan_maybe_instrument_member_call): Adjust callers.
2617
8315e35e 26182014-11-15 Marek Polacek <polacek@redhat.com>
2619
2620 PR middle-end/63884
2621 * array-notation-common.c (is_sec_implicit_index_fn): Return false
2622 for NULL fndecl.
2623 (extract_array_notation_exprs): Return for NULL node.
2624
86b9f14b 26252014-11-12 Joseph Myers <joseph@codesourcery.com>
2626
2627 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
2628 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
2629
0c93c8a9 26302014-11-12 Jakub Jelinek <jakub@redhat.com>
2631
2632 PR c/59708
2633 * c-common.c (check_builtin_function_arguments): Handle
2634 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
2635
fdd735a7 26362014-11-10 Andi Kleen <ak@linux.intel.com>
2637
2638 PR c/60804
2639 * c-common.h (check_no_cilk): Declare.
2640 * cilk.c (get_error_location): New function.
2641 (check_no_cilk): Dito.
2642
5cb678b4 26432014-11-10 Andi Kleen <ak@linux.intel.com>
2644
2645 * cilk.c (recognize_spawn): Use expression location
2646 for error message.
2647
0feb4de1 26482014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
2649
2650 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
2651
3aa2fa44 26522014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
2653
2654 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
2655 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
2656 (__cpp_range_based_for, __cpp_initializer_lists,
2657 __cpp_delegating_constructors, __cpp_nsdmi,
2658 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
2659 for C++11; (__cpp_attribute_deprecated): Remove in favor of
2660 __has_cpp_attribute.
2661 * c-lex.c (cb_has_attribute): New callback CPP function;
2662 (init_c_lex): Set has_attribute callback.
2663
7fd22aae 26642014-11-04 Richard Biener <rguenther@suse.de>
2665
2666 * c-common.c (shorten_compare): Do not shorten mixed
2667 DFP and non-DFP compares.
2668
4af203ac 26692014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
2670
2671 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
2672 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
2673 Commentary and rearrangement of tests.
2674 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
2675 Commentary and rearrangement of tests.
2676 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto
2677 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
2678
3754d046 26792014-10-29 Richard Sandiford <richard.sandiford@arm.com>
2680
2681 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
2682 enum from machine_mode.
2683
1140c305 26842014-10-28 Andrew MacLeod <amacleod@redhat.com>
2685
1f78217c 2686 * c-common.c: Adjust include files.
2687 * c-gimplify.c: Ditto.
2688 * cilk.c: Ditto.
2689 * c-pragma.c: Ditto.
2690 * c-ubsan.c: Ditto.
1140c305 2691
94ea8568 26922014-10-27 Andrew MacLeod <amacleod@redhat.com>
2693
2694 * c-gimplify.c: Adjust include files.
2695
32ecf960 26962014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
2697
2698 PR c++/53061
2699 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
2700 c_common_initialize_diagnostics.
2701 * c-common.h: Likewise.
2702
85fecbe2 27032014-10-24 Marek Polacek <polacek@redhat.com>
2704
2705 PR c/56980
2706 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
2707 print "struct"/"union"/"enum" for typedefed names.
2708
e7ec033a 27092014-10-23 Marek Polacek <polacek@redhat.com>
2710
2711 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
2712 in unsigned type.
2713
c2598081 27142014-10-22 Jakub Jelinek <jakub@redhat.com>
2715 Yury Gribov <y.gribov@samsung.com>
2716
2717 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
2718 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
2719 instead of flag_sanitize_recover as bool flag.
2720
acebb7e2 27212014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
2722
2723 * cilk.c: Revert previous change.
2724
6115016c 27252014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
2726
2727 PR c/63307
2728 * cilk.c: Include vec.h.
2729 (struct cilk_decls): New structure.
2730 (wrapper_parm_cb): Split this function to...
2731 (fill_decls_vec): ...this...
2732 (create_parm_list): ...and this.
2733 (compare_decls): New function.
2734 (for_local_cb): Remove.
2735 (wrapper_local_cb): Ditto.
2736 (build_wrapper_type): For now first traverse and fill vector of
2737 declarations then sort it and then deal with sorted vector.
2738 (cilk_outline): Ditto.
2739 (declare_one_free_variable): Ditto.
2740
e610d2b2 27412014-10-17 Marek Polacek <polacek@redhat.com>
2742
2743 * c-opts.c (c_common_post_options): Set warn_implicit_int.
2744 * c.opt (Wimplicit-int): Initialize to -1.
2745
a3020f2f 27462014-10-16 Andrew MacLeod <amacleod@redhat.com>
2747
2748 * c-pragma.c: Adjust include files.
2749 * c-semantics.c: Likewise.
2750
926ddd2c 27512014-10-16 DJ Delorie <dj@redhat.com>
2752
2753 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
2754 multiples of bytes.
2755
b0542e7c 27562014-10-14 Jason Merrill <jason@redhat.com>
2757
2758 PR c++/63455
2759 * c-common.h (CPP_PREPARSED_EXPR): New.
2760 (N_CP_TTYPES): Adjust.
2761
b2601928 27622014-10-15 Marek Polacek <polacek@redhat.com>
2763
2764 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
2765
9f75f026 27662014-10-14 DJ Delorie <dj@redhat.com>
2767
2768 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
2769 types, not just __int128.
2770 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
2771 types, not just __int128.
2772 (cpp_atomic_builtins): Round pointer sizes up.
2773 (type_suffix): Use type precision, not specific types.
2774 * c-common.c (c_common_reswords): Remove __int128 special case.
2775 (c_common_type_for_size): Check for all __intN types, not just
2776 __int128.
2777 (c_common_type_for_mode): Likewise.
2778 (c_common_signed_or_unsigned_type): Likewise.
2779 (c_build_bitfield_integer_type): Likewise.
2780 (c_common_nodes_and_builtins): Likewise.
2781 (keyword_begins_type_specifier): Likewise.
2782 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
2783 __intN variants.
2784
2ef51f0e 27852014-10-12 Trevor Saunders <tsaunders@mozilla.com>
2786
2787 * c-common.c: Use hash_table instead of hashtab.
2788
5b8257e3 27892014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
2790
1f78217c 2791 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
5b8257e3 2792 C++11 section.
2793
5e84569c 27942014-10-03 Marc Glisse <marc.glisse@inria.fr>
2795
2796 PR c++/54427
2797 PR c++/57198
2798 PR c++/58845
2799 * c-common.c (warn_logical_operator): Punt for vectors.
2800
f6751ff2 28012014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
2802
2803 Implement SD-6: SG10 Feature Test Recommendations
2804 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
2805 macros and the __has_header macro.
2806
c33e051d 28072014-09-30 Jason Merrill <jason@redhat.com>
2808
f76a9aa8 2809 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
2810 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
2811 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
2812
717e52f9 2813 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
2814 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
2815
c33e051d 2816 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
2817 * c-common.c (c_common_reswords): Remove __is_convertible_to.
2818
5213d6c9 28192014-09-24 Marek Polacek <polacek@redhat.com>
2820
2821 PR c/61405
2822 PR c/53874
2823 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
2824
6b722052 28252014-09-23 Andi Kleen <ak@linux.intel.com>
2826
2827 * c-common.c (handle_no_reorder_attribute): New function.
2828 (c_common_attribute_table): Add no_reorder attribute.
2829
0cb69d12 28302014-09-22 Joseph Myers <joseph@codesourcery.com>
2831
2832 * c-cppbuiltin.c (c_cpp_builtins): Define
2833 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
2834 modes.
2835
168dfbf0 28362014-09-18 Joseph Myers <joseph@codesourcery.com>
2837
2838 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
2839 for supported floating-point modes.
2840
b83705f4 28412014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
2842
2843 * c.opt (Wpsabi): Use LangEnabledBy.
2844 * c-opts.c (c_common_handle_option): Do not handle here.
2845
d5957f0d 28462014-09-12 Joseph Myers <joseph@codesourcery.com>
2847
2848 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
2849 macros for floating-point modes.
2850
bae6edff 28512014-09-11 Marc Glisse <marc.glisse@inria.fr>
2852
2853 PR target/58757
2854 * c-cppbuiltin.c (builtin_define_float_constants): Correct
2855 __*_DENORM_MIN__ without denormals.
2856
73a69d02 28572014-09-10 Jakub Jelinek <jakub@redhat.com>
2858
2859 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
2860 ubsan_instrument_vla, ubsan_instrument_return): Adjust
2861 ubsan_create_data callers.
2862 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
2863 index is constant or BIT_AND_EXPR with constant mask and is
2864 small enough for the bound.
2865 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
2866 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
2867
7ff8db31 28682014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
2869
2870 * c.opt: Add CppReason to various flags.
2871 (Wdate-time): Re-sort.
2872 * c-common.c: Include c-common.h earlier.
2873 (struct reason_option_codes_t): Delete.
2874 (c_option_controlling_cpp_error): Prefix global type and struct
2875 with cpp_.
2876
bcc1f37e 28772014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
2878
2879 * c.opt (Wnormalized): New.
2880 (Wnormalized=): Use Enum and Reject Negative.
2881 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
2882
b660d3c6 28832014-09-08 Joseph Myers <joseph@codesourcery.com>
2884
2885 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
2886 digits of floating-point modes if -fbuilding-libgcc.
2887
325b8c3c 28882014-09-05 Joseph Myers <joseph@codesourcery.com>
2889
2890 * c-cppbuiltin.c (c_cpp_builtins): Also define
2891 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
2892 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
2893 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
2894 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
2895 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
2896 __LIBGCC_STACK_GROWS_DOWNWARD__,
2897 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
2898 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
2899 __LIBGCC_DWARF_FRAME_REGISTERS__,
2900 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
2901 __LIBGCC_STACK_POINTER_REGNUM__ and
2902 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
2903 (builtin_define_with_value): Handle backslash-escaping in string
2904 macro values.
2905
1e074e77 29062014-09-05 Richard Biener <rguenther@suse.de>
2907
2908 PR middle-end/63148
2909 * c-format.c (check_format_arg): Properly handle
2910 effectively signed POINTER_PLUS_EXPR offset.
2911
04afd878 29122014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
2913
2914 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
2915 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
2916 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
2917 and Init.
2918 * c-opts.c (c_common_handle_option): Do not handle here.
2919 (sanitize_cpp_opts): Likewise.
2920 * c-common.c (struct reason_option_codes_t): Handle
2921 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
2922
a3f448f0 29232014-09-03 Marek Polacek <polacek@redhat.com>
2924
2925 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
2926
40750995 29272014-09-02 Jakub Jelinek <jakub@redhat.com>
2928 Balaji V. Iyer <balaji.v.iyer@intel.com>
2929 Igor Zamyatin <igor.zamyatin@intel.com>
2930
2931 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
2932 * c-common.c (c_common_reswords): Added _Cilk_for.
2933 * c-common.h (enum rid): Added RID_CILK_FOR.
2934 (cilk_for_number_of_iterations): Add declaration.
2935 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
2936 CILK_FOR.
2937 * c-pragma.c (init_pragma): Register "grainsize" pragma.
2938 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
2939
f0fbe519 29402014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
2941
2942 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
2943 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
2944 Wundef): Use CPP, Var and Init.
2945 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
2946
a7d2e480 29472014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
2948
2949 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
2950 * c-opts.c (c_common_handle_option): Do not handle here.
2951
c35e53f1 29522014-08-25 Jason Merrill <jason@redhat.com>
2953
2954 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
2955 -std=c++14 and -std=gnu++14, rather than the reverse.
2956 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
2957 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
2958 * c-common.h (cxx_dialect): Remove cxx1y.
2959
4e454776 29602014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
2961
2962 * c-common.h (enum cxx_dialect): Add cxx14.
2963 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
2964 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
2965 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
2966
af1a80f2 29672014-08-22 Jason Merrill <jason@redhat.com>
2968
2969 * c.opt (std=gnu++17): Fix alias.
2970
dc6229e8 29712014-08-22 Marek Polacek <polacek@redhat.com>
2972
2973 PR c++/62199
2974 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
2975 check for vector types. Drop LHS argument.
2976 * c-common.h (warn_logical_not_parentheses): Adjust.
2977
ba7f7c88 29782014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
2979
2980 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
2981 (Wmultichar): Likewise.
2982 (Wdate-time): Use C-family languages instead of Common. Use CPP
2983 and Var.
2984 * c-opts.c (c_common_handle_option): Do not handle the above
2985 options here.
2986 (sanitize_cpp_opts): Likewise.
2987
399d4f80 29882014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
2989
2990 PR fortran/44054
2991 * c-opts.c: Include tree-diagnostics.h.
2992 (c_diagnostic_finalizer): New.
2993 (c_common_initialize_diagnostics): Use it.
2994
1babed5f 29952014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
2996
2997 PR preprocessor/51303
2998 * c-common.c (struct reason_option_codes_t option_codes):
2999 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
3000
3636964b 30012014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
3002
3003 PR c/60975
3004 PR c/53063
3005 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
3006 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
3007 (c_common_post_options): Call init_global_opts_from_cpp.
3008 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
3009
78bf4156 30102014-08-19 Marek Polacek <polacek@redhat.com>
3011
3012 PR c++/62153
3013 * c-common.c (maybe_warn_bool_compare): New function.
3014 * c-common.h (maybe_warn_bool_compare): Declare.
3015 * c.opt (Wbool-compare): New option.
3016
508ea33a 30172014-08-19 Marek Polacek <polacek@redhat.com>
3018
3019 * c.opt (Wc99-c11-compat): New option.
3020
806fe15e 30212014-08-19 Marek Polacek <polacek@redhat.com>
3022
3023 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
3024 to warn_c90_c99_compat.
3025 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
3026 to -1.
3027
6c867de1 30282014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
3029 Steven Bosscher <steven@gcc.gnu.org>
3030
3031 PR c/52952
3032 * c-format.c: Add extra_arg_loc and format_string_loc to struct
3033 format_check_results.
3034 (check_function_format): Use true and add comment for boolean
3035 argument.
3036 (finish_dollar_format_checking): Use explicit location when warning.
3037 (check_format_info): Likewise.
3038 (check_format_arg): Set extra_arg_loc and format_string_loc.
3039 (check_format_info_main): Use explicit location when warning.
3040 (check_format_types): Pass explicit location.
3041 (format_type_warning): Likewise.
3042
dc8078a3 30432014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
3044
3045 PR fortran/44054
3046 * c-format.c: Handle Fortran flags.
3047
d271ec7e 30482014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
3049
3050 PR other/61962
3051 * array-notation-common.c (find_rank): Added handling for other
3052 types of references.
3053
890c2e2f 30542014-08-10 Marek Polacek <polacek@redhat.com>
3055
3056 PR c/51849
3057 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
3058 * c.opt (Wc90-c99-compat): Add option.
3059
7149db5f 30602014-08-07 Trevor Saunders <tsaunders@mozilla.com>
3061
3062 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
3063
2d2f6a15 30642014-08-03 Marek Polacek <polacek@redhat.com>
3065
3066 * c-common.c (check_case_value): Add location_t parameter. Use it.
3067 (c_add_case_label): Pass loc to check_case_value.
3068
06ecf488 30692014-08-02 Trevor Saunders <tsaunders@mozilla.com>
3070
3071 * cilk.c: Use hash_map instead of pointer_map.
3072
431205b7 30732014-08-02 Trevor Saunders <tsaunders@mozilla.com>
3074
3075 * c-gimplify.c: Use hash_set instead of pointer_set.
3076
3394c80c 30772014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
3078
3079 PR middle-end/61455
3080 * array-notation-common.c (extract_array_notation_exprs): Handling
3081 of DECL_EXPR added.
3082
392dee1e 30832014-08-01 Jakub Jelinek <jakub@redhat.com>
3084
3085 * c-common.h (min_align_of_type): Removed prototype.
3086 * c-common.c (min_align_of_type): Removed.
3087 * c-ubsan.h (ubsan_maybe_instrument_reference,
3088 ubsan_maybe_instrument_member_call): New prototypes.
3089 * c-ubsan.c: Include stor-layout.h and builtins.h.
3090 (ubsan_maybe_instrument_reference_or_call,
3091 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
3092 functions.
3093
f22a2cb7 30942014-07-31 Marc Glisse <marc.glisse@inria.fr>
3095
3096 PR c++/60517
3097 * c.opt (-Wreturn-local-addr): Move to common.opt.
3098
87b0198f 30992014-07-30 Jason Merrill <jason@redhat.com>
3100
3101 PR c++/61659
3102 PR c++/61687
3103 Revert:
3104 * c.opt (-fuse-all-virtuals): New.
3105
74691f46 31062014-07-30 Tom Tromey <tromey@redhat.com>
3107
3108 PR c/59855
3109 * c.opt (Wdesignated-init): New option.
3110 * c-common.c (c_common_attribute_table): Add "designated_init".
3111 (handle_designated_init): New function.
3112
9140d56f 31132014-07-24 Marek Polacek <polacek@redhat.com>
3114
3115 PR c/57653
3116 * c-opts.c (c_finish_options): If -imacros is in effect, return.
3117
a09c5cc2 31182014-07-16 Dodji Seketeli <dodji@redhat.com>
3119
3120 PR preprocessor/60723 - missing system-ness marks for macro tokens
3121 * c-ppoutput.c (struct print::prev_was_system_token): New data
3122 member.
3123 (init_pp_output): Initialize it.
3124 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
3125 (do_line_change): Return a flag saying if a line marker was
3126 emitted or not.
3127 (scan_translation_unit): Detect if the system-ness of the token we
3128 are about to emit is different from the one of the previously
3129 emitted token. If so, emit a line marker. Avoid emitting useless
3130 adjacent line markers. Avoid emitting line markers for tokens
3131 originating from the expansion of built-in macros.
3132 (scan_translation_unit_directives_only): Adjust.
3133
2b25b62f 31342014-07-15 Marek Polacek <polacek@redhat.com>
3135
3136 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
3137 TYPE_MAX_VALUE is NULL.
3138
305d96bc 31392014-07-14 Jakub Jelinek <jakub@redhat.com>
3140
3141 PR middle-end/61294
3142 * c.opt (Wmemset-transposed-args): New warning.
3143
8ea4660d 31442014-07-10 Jason Merrill <jason@redhat.com>
3145
3146 PR c++/61659
3147 PR c++/61687
3148 * c.opt (-fuse-all-virtuals): New.
3149
cd480f3d 31502014-07-09 Richard Biener <rguenther@suse.de>
3151
3152 PR c-family/61741
3153 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
3154 using unsigned arithmetic if overflow does not wrap instead of
3155 if overflow is undefined.
3156
87d59e72 31572014-07-06 Marek Polacek <polacek@redhat.com>
3158
3159 PR c/6940
3160 * c.opt (Wsizeof-array-argument): New option.
3161
d69521d8 31622014-07-03 Jakub Jelinek <jakub@redhat.com>
3163
8204c077 3164 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
d69521d8 3165 comments->count <= 1, as comments->entries might be NULL.
3166
1207866e 31672014-07-01 Marek Polacek <polacek@redhat.com>
3168
3169 * c.opt (Wint-conversion): New option.
3170
7a6bbb76 31712014-07-01 Marek Polacek <polacek@redhat.com>
3172
3173 PR c/58286
3174 * c.opt (Wincompatible-pointer-types): New option.
3175
9d4eeb52 31762014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
3177
3178 PR c++/51400
3179 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
3180 Do not discard TYPE_QUALS of type.
3181
4b53bc0f 31822014-06-26 Jason Merrill <jason@redhat.com>
3183
3184 * c-common.h (enum cxx_dialect): Add cxx1z.
3185 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
3186 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
3187
a8a8d4ea 31882014-06-26 Teresa Johnson <tejohnson@google.com>
3189
3190 * c-common.h (get_dump_info): Declare.
3191 * c-gimplify.c (c_genericize): Use saved dump files.
3192 * c-opts.c (c_common_parse_file): Begin and end dumps
3193 once around parsing invocation.
3194 (get_dump_info): New function.
3195
1f6be080 31962014-06-23 Marek Polacek <polacek@redhat.com>
3197 Andrew MacLeod <amacleod@redhat.com>
3198
3199 PR c/61553
3200 * c-common.c (get_atomic_generic_size): Don't segfault if the
3201 type doesn't have a size.
3202
5ef6b660 32032014-06-20 Marek Polacek <polacek@redhat.com>
3204
3205 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
3206 (ubsan_walk_array_refs_r): New function.
3207 (c_genericize): Instrument array bounds.
3208 * c-ubsan.c: Include "internal-fn.h".
3209 (ubsan_instrument_division): Mark instrumented arrays as having
3210 side effects. Adjust ubsan_type_descriptor call.
3211 (ubsan_instrument_shift): Likewise.
3212 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
3213 (ubsan_instrument_bounds): New function.
3214 (ubsan_array_ref_instrumented_p): New function.
3215 (ubsan_maybe_instrument_array_ref): New function.
3216 * c-ubsan.h (ubsan_instrument_bounds): Declare.
3217 (ubsan_array_ref_instrumented_p): Declare.
3218 (ubsan_maybe_instrument_array_ref): Declare.
3219
32202014-06-20 Hale Wang <hale.wang@arm.com>
3ccd1e6e 3221
3222 PR lto/61123
3223 * c.opt (fshort-enums): Add to LTO.
3224 * c.opt (fshort-wchar): Likewise.
3225
78438f31 32262014-06-16 Marek Polacek <polacek@redhat.com>
3227
3228 PR c/60439
3229 * c.opt (Wswitch-bool): Add Var.
3230
5fddcf34 32312014-06-12 Jakub Jelinek <jakub@redhat.com>
3232
3233 PR middle-end/61486
3234 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
3235 #pragma omp target teams or
3236 #pragma omp {,target }teams distribute simd.
3237
74b777e5 32382014-06-12 Jason Merrill <jason@redhat.com>
3239
3240 * c.opt (Wabi=, fabi-compat-version): New.
3241 * c-opts.c (c_common_handle_option): Handle -Wabi=.
3242 (c_common_post_options): Handle flag_abi_compat_version default.
3243 Disallow -fabi-compat-version=1.
3244 * c-common.h (abi_version_crosses): New.
3245
738a6bda 32462014-06-11 Jan Hubicka <hubicka@ucw.cz>
3247
1f78217c 3248 * c-common.c (handle_section_attribute): Update handling for
738a6bda 3249 section names that are no longer trees.
3250
cf5f881f 32512014-06-10 Jakub Jelinek <jakub@redhat.com>
3252
3253 PR fortran/60928
3254 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
3255 (omp_pragmas): ... back here.
3256
32dc1512 32572014-06-05 Marek Polacek <polacek@redhat.com>
3258
3259 PR c/49706
3260 * c-common.c (warn_logical_not_parentheses): New function.
3261 * c-common.h (warn_logical_not_parentheses): Declare.
3262 * c.opt (Wlogical-not-parentheses): New option.
3263
f61a9bc2 32642014-06-04 Marek Polacek <polacek@redhat.com>
3265
3266 PR c/30020
3267 * c-common.c (check_case_bounds): Add location parameter.
3268 Use it.
3269 (c_add_case_label): Pass loc to check_case_bounds.
3270
c69ec07d 32712014-06-03 Marek Polacek <polacek@redhat.com>
3272
3273 PR c/60439
3274 * c.opt (Wswitch-bool): New option.
3275
3c77ca67 32762014-05-22 Thomas Schwinge <thomas@codesourcery.com>
3277
68a2c870 3278 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
3279 Remove prototypes.
3280 (record_types_used_by_current_var_decl): Move prototype to where
3281 it belongs.
3282
3c77ca67 3283 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
3284 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
3285 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
3286
3ab4693e 32872014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
3288
3289 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
3290 * c-common.c (c_common_nodes_and_builtins): Don't initialize
3291 void_zero_node.
3292 * c-pretty-print.c (pp_c_void_constant): New function.
3293 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
3294 (c_pretty_printer::expression): Handle VOID_CST.
3295 * cilk.c (extract_free_variables): Likewise.
3296 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
3297 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
3298
25a27413 32992014-05-17 Trevor Saunders <tsaunders@mozilla.com>
3300
3301 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
3302 * c-pragma.c (push_alignment): Adjust.
3303 (handle_pragma_push_options): Likewise.
3304
3e5a8b00 33052014-05-09 Marek Polacek <polacek@redhat.com>
3306
3307 PR c/50459
3308 * c-common.c (check_user_alignment): Return -1 if alignment is error
3309 node.
3310 (handle_aligned_attribute): Don't call default_conversion on
3311 FUNCTION_DECLs.
3312 (handle_vector_size_attribute): Likewise.
3313 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
3314 (handle_sentinel_attribute): Call default_conversion and allow even
3315 integral types as an argument.
3316
c2c4ae8d 33172014-05-08 Marek Polacek <polacek@redhat.com>
3318
3319 PR c/61053
3320 * c-common.c (min_align_of_type): New function factored out from...
3321 (c_sizeof_or_alignof_type): ...here.
3322 * c-common.h (min_align_of_type): Declare.
3323
2026249a 33242014-05-08 Marek Polacek <polacek@redhat.com>
3325
3326 PR c/61077
3327 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
3328 parameter type of main.
3329
33c8dcfe 33302014-05-07 DJ Delorie <dj@redhat.com>
3331
3332 * c-cppbuiltin.c (print_bits_of_hex): New.
3333 (builtin_define_type_minmax): Print values using hex so as not to
3334 require a pre-computed list of string values.
3335
960d5a55 33362014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
3337 Mike Stump <mikestump@comcast.net>
3338 Richard Sandiford <rdsandiford@googlemail.com>
3339
3340 * c-ada-spec.c: Include wide-int.h.
3341 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
3342 (dump_generic_ada_node): Use wide-int interfaces.
3343 * c-common.c: Include wide-int-print.h.
3344 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
3345 (pointer_int_sum): Use wide-int interfaces.
3346 (c_common_nodes_and_builtins): Use make_int_cst.
3347 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
3348 (handle_alloc_size_attribute): Use wide-int interfaces.
3349 (get_nonnull_operand): Likewise.
3350 * c-format.c (get_constant): Use tree_fits_uhwi_p.
3351 * c-lex.c: Include wide-int.h.
3352 (narrowest_unsigned_type): Take a widest_int rather than two
3353 HOST_WIDE_INTs.
3354 (narrowest_signed_type): Likewise.
3355 (interpret_integer): Update accordingly. Use wide-int interfaces.
3356 (lex_charconst): Use wide-int interfaces.
3357 * c-pretty-print.c: Include wide-int.h.
3358 (pp_c_integer_constant): Use wide-int interfaces.
3359 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
3360 INT_CST_LT_UNSIGNED.
3361
bbb88b31 33622014-05-06 Richard Biener <rguenther@suse.de>
3363
3364 * c-opts.c (c_common_post_options): For -freestanding,
3365 -fno-hosted and -fno-builtin disable pattern recognition
3366 if not enabled explicitely.
3367
022d4718 33682014-05-02 Marek Polacek <polacek@redhat.com>
3369
3370 * c.opt (Wsizeof-pointer-memaccess): Describe option.
3371
e4ab2ef3 33722014-05-01 Marek Polacek <polacek@redhat.com>
3373
3374 PR c/43245
3375 * c.opt (Wdiscarded-qualifiers): Add.
3376
52cc0072 33772014-04-30 Marek Polacek <polacek@redhat.com>
3378
3379 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
3380 INT_MIN / -1 sanitization only for integer types.
3381
4a026b48 33822014-04-25 Marek Polacek <polacek@redhat.com>
3383
3384 PR c/18079
3385 * c-common.c (handle_noinline_attribute): Warn if the attribute
3386 conflicts with always_inline attribute.
3387 (handle_always_inline_attribute): Warn if the attribute conflicts
3388 with noinline attribute.
3389
90e645fa 33902014-04-25 Marek Polacek <polacek@redhat.com>
3391
3392 PR c/60156
3393 * c-common.c (check_main_parameter_types): Warn about variadic main.
3394
db103ea4 33952014-04-24 Mike Stump <mikestump@comcast.net>
3396
3397 * c.opt (Wshadow-ivar): Default to on.
3398
06511efd 33992014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
3400
3401 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
3402
cdf34fca 34032014-04-23 Marek Polacek <polacek@redhat.com>
3404
3405 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
3406
7311d7c1 34072014-04-22 Jakub Jelinek <jakub@redhat.com>
3408
3409 PR sanitizer/60275
3410 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
3411 if flag_sanitize_undefined_trap_on_error.
3412 (ubsan_instrument_division, ubsan_instrument_shift,
3413 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
3414 if !flag_sanitize_recover.
3415
c1917557 34162014-04-22 Marc Glisse <marc.glisse@inria.fr>
3417
3418 PR libstdc++/43622
3419 * c-common.c (registered_builtin_types): Make non-static.
3420 * c-common.h (registered_builtin_types): Declare.
3421
b2ca6510 34222014-04-14 Richard Biener <rguenther@suse.de>
3423 Marc Glisse <marc.glisse@inria.fr>
3424
3425 PR c/60819
3426 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
3427 apply may-alias the scalar pointer type when applicable.
3428
855372a3 34292014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
3430
3431 PR middle-end/60467
3432 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
3433 as possible argument for Cilk_spawn.
3434
4012a986 34352014-04-11 Tobias Burnus <burnus@net-b.de>
3436
3437 PR c/60194
3438 * c.opt (Wformat-signedness): Add
3439 * c-format.c(check_format_types): Use it.
3440
0d284870 34412014-04-11 Jason Merrill <jason@redhat.com>
3442
3443 PR c++/57926
3444 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
3445 default_conversion for an array argument.
3446
a34c1231 34472014-04-08 Marek Polacek <polacek@redhat.com>
3448
3449 PR sanitizer/60745
3450 * c-ubsan.c: Include asan.h.
3451 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
3452
a35a8e18 34532014-04-03 Nathan Sidwell <nathan@codesourcery.com>
3454
3455 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
3456
b23e42b6 34572014-04-02 Marek Polacek <polacek@redhat.com>
3458
3459 * c-common.h (c_expand_expr): Remove declaration.
3460
5a672e62 34612014-03-28 Jakub Jelinek <jakub@redhat.com>
3462
3463 PR c++/60689
3464 * c-common.c (add_atomic_size_parameter): When creating new
3465 params vector, push the size argument first.
3466
d4d068c0 34672014-03-26 Jakub Jelinek <jakub@redhat.com>
3468
3469 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
3470 ubsan_instrument_vla, ubsan_instrument_return): Adjust
3471 ubsan_create_data callers.
3472
446bdf5f 34732014-03-22 Jakub Jelinek <jakub@redhat.com>
3474
3475 PR debug/60603
3476 * c-opts.c (c_finish_options): Restore cb_file_change call to
3477 <built-in>.
3478
8895f0a3 34792014-03-13 Jakub Jelinek <jakub@redhat.com>
3480
3481 PR middle-end/36282
3482 * c-pragma.c (apply_pragma_weak): Only look at
3483 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
3484 DECL_ASSEMBLER_NAME_SET_P (decl).
3485 (maybe_apply_pending_pragma_weaks): Exit early if
3486 vec_safe_is_empty (pending_weaks) rather than only when
3487 !pending_weaks.
3488 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
3489 set assembler name back to NULL afterwards.
3490
7a5da2cd 34912014-03-11 Jason Merrill <jason@redhat.com>
3492
3493 * c.opt: Add -std=gnu++14.
3494
95093889 34952014-03-11 Ian Bolton <ian.bolton@arm.com>
3496
3497 * c-opts.c (c_common_post_options): Don't override
3498 -ffp-contract=fast if unsafe-math-optimizations is on.
3499
c9a24b37 35002014-03-08 Paulo Matos <paulo@matos-sorge.com>
3501
3502 * c.opt: Enable LTO FE for fshort-double.
3503
3f6dba6e 35042014-03-07 Jason Merrill <jason@redhat.com>
3505
3506 * c.opt: Add -std=c++14.
3507
3bfdc94f 35082014-03-06 Marek Polacek <polacek@redhat.com>
3509
3510 PR c/60197
3511 * cilk.c (contains_cilk_spawn_stmt): New function.
3512 (contains_cilk_spawn_stmt_walker): Likewise.
3513 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
3514 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
3515
8b3a6a4c 35162014-03-03 Jakub Jelinek <jakub@redhat.com>
3517
3518 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
3519 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
3520 even when flag_preprocess_only.
3521
734ec290 35222014-02-26 Jason Merrill <jason@redhat.com>
3523
3524 PR c++/59231
3525 PR c++/11586
3526 * c-common.c (shorten_compare): Don't check
3527 c_inhibit_evaluation_warnings.
3528
81aec8b8 35292014-02-19 Jakub Jelinek <jakub@redhat.com>
3530
d1081017 3531 PR c/37743
3532 * c-common.c (c_common_nodes_and_builtins): When initializing
3533 c_uint{16,32,64}_type_node, also set corresponding
3534 uint{16,32,64}_type_node to the same value.
3535
81aec8b8 3536 PR c++/60267
3537 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
3538 for PRAGMA_IVDEP if flag_preprocess_only.
3539
312243bb 35402014-02-12 Jakub Jelinek <jakub@redhat.com>
3541
3542 PR c/60101
3543 * c-common.c (merge_tlist): If copy is true, call new_tlist,
3544 if false, add ADD itself, rather than vice versa.
3545 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
3546 copy. For SAVE_EXPR, only call merge_tlist once.
3547
237e78b1 35482014-02-08 Jakub Jelinek <jakub@redhat.com>
3549
3550 PR middle-end/60092
3551 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
3552 and tree_to_uhwi.
3553 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
3554 functions.
3555 (c_common_attribute_table): Add alloc_align and assume_aligned
3556 attributes.
3557
76fdceeb 35582014-02-06 Marek Polacek <polacek@redhat.com>
3559
3560 PR c/60087
3561 * c-common.c (warn_for_sign_compare): Call warning_at with location
3562 instead of warning.
3563
4a4dea42 35642014-02-05 Marek Polacek <polacek@redhat.com>
3565
3566 PR c/53123
3567 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
3568 statement.
3569
ec704957 35702014-02-04 Marek Polacek <polacek@redhat.com>
3571
3572 PR c/60036
3573 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
3574 SAVE_EXPR.
3575
caf62483 35762014-02-03 Marc Glisse <marc.glisse@inria.fr>
3577
3578 PR c++/53017
3579 PR c++/59211
3580 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
3581 handle_vector_size_attribute, handle_nonnull_attribute): Call
3582 default_conversion on the attribute argument.
3583 (handle_nonnull_attribute): Increment the argument number.
3584
ec761d5a 35852014-01-31 Marek Polacek <polacek@redhat.com>
3586
3587 PR c/59963
3588 * c-common.c (add_atomic_size_parameter): Pass vNULL to
3589 build_function_call_vec.
3590 (resolve_overloaded_builtin): Likewise.
3591 * c-common.h (build_function_call_vec): Adjust declaration.
3592
22a75734 35932014-01-30 Marek Polacek <polacek@redhat.com>
3594
3595 PR c/59940
3596 * c-common.h (unsafe_conversion_p): Adjust declaration.
3597 (warnings_for_convert_and_check): Likewise.
3598 (convert_and_check): Likewise.
3599 * c-common.c (unsafe_conversion_p): Add location parameter. Call
3600 expansion_point_location_if_in_system_header on it.
3601 (warnings_for_convert_and_check): Add location parameter. Call
3602 expansion_point_location_if_in_system_header on it. Use it.
3603 (convert_and_check): Add location parameter. Use it.
3604 (conversion_warning): Likewise.
3605 (c_add_case_label): Adjust convert_and_check calls.
3606 (scalar_to_vector): Adjust unsafe_conversion_p calls.
3607
a89e6c15 36082014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
3609
3610 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
3611 flag_cilkplus.
3612 * c-pragma.c (init_pragma): Likewise.
3613 * c.opt: Likewise.
3614
2623625f 36152014-01-23 Marek Polacek <polacek@redhat.com>
3616
3617 PR c/59846
3618 * c-common.c (shorten_compare): Add location_t parameter.
3619 * c-common.h (shorten_binary_op): Adjust declaration.
3620
46da3601 36212014-01-23 Marek Polacek <polacek@redhat.com>
3622
3623 PR c/58346
3624 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
3625 * c-common.h: Declare it.
3626
c9743c6a 36272014-01-20 Eric Botcazou <ebotcazou@adacore.com>
3628
3629 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
3630 * c-ada-spec.c (dump_ads): Likewise.
3631 (cpp_check): Likewise.
3632 (dump_ada_specs): Likewise.
3633
36342014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
36e33c6a 3635
3636 PR c++/49718
3637 * c-common.c (handle_no_instrument_function_attribute): Allow
3638 no_instrument_function attribute in class member
3639 definition/declaration.
3640
1248c663 36412014-01-15 Jakub Jelinek <jakub@redhat.com>
3642
3643 PR c/58943
3644 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
3645 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
3646 being COMPOUND_EXPR.
3647 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
3648 operand a SAVE_EXPR and second MODIFY_EXPR.
3649
6e5c480b 36502014-01-09 Jakub Jelinek <jakub@redhat.com>
3651
3652 PR target/58115
3653 * c-pch.c (c_common_write_pch): Call
3654 prepare_target_option_nodes_for_pch.
3655
3aea1f79 36562014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
3657
3658 Update copyright years
3659
e4f22041 36602014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
3661
3662 * array-notation-common.c, c-cilkplus.c: Use the standard form for
3663 the copyright notice.
3664
7fb0fe24 36652013-12-28 Eric Botcazou <ebotcazou@adacore.com>
3666
3667 * c-ada-spec.c (print_constructor): New function.
3668 (print_destructor): Retrieve the origin of the destructor.
3669 (print_ada_declaration): Revamp handling of constructors/destructors.
3670
92a44a68 36712013-12-23 Stuart Hastings <stuart@apple.com>
468088ac 3672 Bill Maddox <maddox@google.com>
3673 Jason Merrill <jason@redhat.com>
3674
3675 * c.opt: Add -fdeclone-ctor-dtor.
3676 * c-opts.c (c_common_post_options): Default to on iff -Os.
3677
74acc703 36782013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
3679
3680 * c-common.c (c_common_attribute_table): Added "cilk simd function"
3681 attribute.
3682 * c-pragma.h (enum pragma_cilk_clause): Remove.
3683 (enum pragma_omp_clause): Added the following fields:
3684 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
3685 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
3686 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
3687 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
3688 PRAGMA_CILK_CLAUSE_UNIFORM.
3689
8204c077 3690
433e804e 36912013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
3692
3693 * cilk.c (cilk_outline): Made this function non-static.
3694 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
3695 (create_cilk_wrapper): Added a new parameter: a function pointer.
3696 (c_install_body_w_frame_cleanup): Remove
3697 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
3698 * c-common.h (cilk_outline): New prototype.
3699 (gimplify_cilk_spawn): Removed two parameters.
3700 (cilk_install_body_with_frame_cleanup): New prototype.
3701 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
3702 CILK_SPAWN_STMT case.
3703
5bcc7e60 37042013-12-11 Bernd Schmidt <bernds@codesourcery.com>
3705
e66325ea 3706 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
3707
5bcc7e60 3708 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
3709 (int_array_type_node): Remove.
3710 * c-common.c (c_common_nodes_and_builtins): Don't build it.
3711
0b26ec77 37122013-12-05 Marek Polacek <polacek@redhat.com>
3713
3714 PR c/52023
3715 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
3716 [ADJUST_FIELD_ALIGN].
3717
a179a7dc 37182013-12-04 Joseph Myers <joseph@codesourcery.com>
3719
3720 PR c/52023
3721 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
3722 and check field alignment if set.
3723 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
3724 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
3725
8204c077 37262013-12-04 Jakub Jelinek <jakub@redhat.com>
137559b2 3727 Marek Polacek <polacek@redhat.com>
3728
3729 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
3730 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
3731
648fd348 37322013-11-29 H.J. Lu <hongjiu.lu@intel.com>
3733
3734 PR c/59309
3735 * cilk.c (gimplify_cilk_spawn): Properly handle function without
3736 arguments.
3737
253e1cae 37382013-11-29 Jakub Jelinek <jakub@redhat.com>
3739
3740 PR c/59280
3741 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
3742 goto invalid. If it is error_mark_node, don't issue further
3743 diagnostics.
3744
3e398f5b 37452013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
3746
3747 * c.opt (Wopenmp-simd): New.
3748
020bc656 37492013-11-22 Jakub Jelinek <jakub@redhat.com>
3750
3751 * c-ubsan.h (ubsan_instrument_return): New prototype.
3752 * c-ubsan.c (ubsan_instrument_return): New function.
3753
bc61cadb 37542013-11-22 Andrew MacLeod <amacleod@redhat.com>
3755
3756 * c-common.c: Add required include files from gimple.h.
3757 * c-gimplify.c: Likewise
3758 * cilk.c: Likewise
3759
3df42822 37602013-11-22 David Malcolm <dmalcolm@redhat.com>
3761
3762 * c-common.c (unsafe_conversion_p): Remove use of
3763 EXPR_LOC_OR_HERE macro.
3764 (conversion_warning): Likewise.
3765 (warnings_for_convert_and_check): Likewise.
3766 (warn_for_collisions_1): Likewise.
3767 (shorten_compare): Likewise, and remove use of in_system_header
3768 macro, using the location from the former.
3769 * c-lex.c (dump_one_header): Remove use of input_filename macro.
3770 (cb_def_pragma): Remove use of in_system_header macro.
3771 (lex_string): Likewise.
3772 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
3773
8c53c46c 37742013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
3775 Mike Stump <mikestump@comcast.net>
3776 Richard Sandiford <rdsandiford@googlemail.com>
3777
3778 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
3779 instead of TREE_INT_CST_LOW, in cases where there is a protecting
3780 tree_fits_shwi_p or tree_fits_uhwi_p.
3781 (dump_generic_ada_node): Likewise.
3782 * c-format.c (check_format_arg): Likewise.
3783 * c-pretty-print.c (pp_c_integer_constant): Likewise.
3784
5200ef07 37852013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
3786
3787 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
3788
ca9d7d74 37892013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
3790
3791 PR c/53001
3792 * c-common.c (unsafe_conversion_p): Make this function
3793 return an enumeration with more detail.
3794 (conversion_warning): Use the new return type of
3795 unsafe_conversion_p to separately warn either about conversions
3796 that lower floating point number precision or about the other
3797 kinds of conversions.
3798 * c-common.h (enum conversion_safety): New enumeration.
3799 (unsafe_conversion_p): switching return type to
3800 conversion_safety enumeration.
3801 * c.opt: Adding new warning -Wfloat-conversion and
3802 enabling it with -Wconversion.
3803
0391a567 38042013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
3805
3806 * c-opts.c: Include plugin.h.
3807 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
3808
19b928d9 38092013-11-19 Marek Polacek <polacek@redhat.com>
3810
3811 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
3812 call.
3813 (ubsan_instrument_shift): Likewise.
3814 (ubsan_instrument_vla): Likewise.
3815
aa59f000 38162013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3817
3818 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
3819 cast to unsigned type.
3820
08f817b3 38212013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3822
3823 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
3824 tree_low_cst.
3825 (complete_array_type): Update comment to refer to tree_to_[su]hwi
3826 rather than tree_low_cst.
3827
6a0712d4 38282013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3829
3830 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
3831 tree_to_uhwi throughout.
3832
fcb97e84 38332013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3834
3835 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
3836 tree_low_cst (..., 0) with tree_to_shwi throughout.
3837
cd4547bf 38382013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3839
3840 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
3841 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
3842
35ec552a 38432013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3844
3845 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
3846 host_integerp (..., 0) with tree_fits_shwi_p throughout.
3847
f2697631 38482013-11-15 Aldy Hernandez <aldyh@redhat.com>
3849
3850 * c-cilkplus.c: New file.
3851 * c-common.c (readonly_error): Add location argument.
3852 * c-common.h (readonly_error): Same.
3853 (c_finish_cilk_clauses): Protoize.
3854 (c_check_cilk_loop): Same.
3855 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
3856 Do not fail on error_mark_node.
3857 Abstract increment canonicalization to here...
3858 (c_omp_for_incr_canonicalize_ptr): New.
3859 c-pragma.c (init_pragma): Register "simd" pragma.
3860 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
3861 (enum pragma_cilk_clause): New.
3862
0aa8c34e 38632013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
3864
3865 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
3866 wchar_type and host_integerp checks.
3867
e795d6e1 38682013-11-14 Andrew MacLeod <amacleod@redhat.com>
3869
3870 * c-common.c: Likewise.
3871 * c-gimplify.c: Likewise.
3872 * cilk.c: Likewise.
3873
9ed99284 38742013-11-14 Diego Novillo <dnovillo@google.com>
3875
3876 * c-common.c: Include fold-const.h.
3877 Include stor-layout.h.
3878 Include calls.h.
3879 Include stringpool.h.
3880 Include attribs.h.
3881 Include varasm.h.
3882 Include trans-mem.h.
3883 * c-cppbuiltin.c: Include stor-layout.h.
3884 Include stringpool.h.
3885 * c-format.c: Include stringpool.h.
3886 * c-lex.c: Include stringpool.h.
3887 Include stor-layout.h.
3888 * c-pragma.c: Include stringpool.h.
3889 Include attribs.h.
3890 Include varasm.h.
3891 Include gcc-symtab.h.
3892 * c-pretty-print.c: Include stor-layout.h.
3893 Include attribs.h.
3894 * cilk.c: Include stringpool.h.
3895 Include calls.h.
3896
4fba5eb9 38972013-11-13 Joseph Myers <joseph@codesourcery.com>
3898
3899 * c-common.h (enum rid): Add RID_AUTO_TYPE.
3900 * c-common.c (c_common_reswords): Add __auto_type.
3901 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
3902
a8783bee 39032013-11-12 Andrew MacLeod <amacleod@redhat.com>
3904
e795d6e1 3905 * c-common.c: Include gimplify.h.
3906 * c-gimplify.c: Likewise.
3907 * cilk.c: Likewise.
3908 * c-omp.c: Include gimple-expr.h instead of gimple.h.
3909 * c-ubsan.c: Don't include gimple.h.
a8783bee 3910
d184e0c0 39112013-11-12 Joseph Myers <joseph@codesourcery.com>
3912
3913 * c-common.c (c_common_reswords): Add _Thread_local.
3914
a056826c 39152013-11-09 Joseph Myers <joseph@codesourcery.com>
3916
3917 * c-common.c (atomic_size_supported_p): New function.
3918 (resolve_overloaded_atomic_exchange)
3919 (resolve_overloaded_atomic_compare_exchange)
3920 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
3921 Use it instead of comparing size with a local list of sizes.
3922
b560fabd 39232013-11-07 Andrew MacLeod <amacleod@redhat.com>
3924 Joseph Myers <joseph@codesourcery.com>
3925
3926 * c-common.h (enum rid): Add RID_ATOMIC.
3927 * c-common.c (c_common_reswords): Add _Atomic.
3928 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
3929 (keyword_is_type_qualifier): Accept RID_ATOMIC.
3930 * c-format.c (check_format_types): Check for extra _Atomic
3931 qualifiers in format argument.
3932 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
3933 (pp_c_type_qualifier_list): Mention _Atomic in comment.
3934
5b1a0622 39352013-11-06 Tobias Burnus <burnus@net-b.de>
3936
3937 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
3938
4f8f4cb8 39392013-11-06 Joseph Myers <joseph@codesourcery.com>
3940
3941 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
3942 standards modes.
3943 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
3944 to mean lack of IEEE 754 support.
3945
9148bda3 39462013-11-05 Tobias Burnus <burnus@net-b.de>
3947
3948 * c.opt (-Wdate-time): New option
3949 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
3950
08c5f4d5 39512013-11-05 Joseph Myers <joseph@codesourcery.com>
3952
3953 * c-cppbuiltin.c (cpp_iec_559_value): Test
3954 flag_excess_precision_cmdline not flag_excess_precision.
3955
c630ef93 39562013-11-05 Tobias Burnus <burnus@net-b.de>
3957
3958 * c.opt (fopenmp-simd): New option.
3959 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
3960 (omp_pragmas): ... this new struct.
3961 (c_pp_lookup_pragma): Also walk omp_pragmas.
3962 (init_pragma): Init pragmas for -fopenmp-simd.
3963
7354a89b 39642013-11-04 Marek Polacek <polacek@redhat.com>
3965
3966 PR c++/58979
3967 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
3968
4c866b9b 39692013-11-04 Joseph Myers <joseph@codesourcery.com>
3970
3971 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
3972 New functions.
3973 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
3974
e2a6a333 39752013-11-04 Eric Botcazou <ebotcazou@adacore.com>
3976
3977 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
3978 (dump_ada_specs): Adjust prototype of second callback.
3979 * c-ada-spec.c (cpp_check): New global variable.
3980 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
3981 (print_generic_ada_decl): Likewise.
3982 (has_static_fields): Change return type to bool and add guard.
3983 (has_nontrivial_methods): New predicate.
3984 (is_tagged_type): Change return type to bool.
3985 (separate_class_package): Call has_nontrivial_methods.
3986 (pp_ada_tree_identifier): Minor tweaks.
3987 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
3988 (dump_ada_array_domains): Likewise.
3989 (dump_ada_array_type): Likewise.
3990 (dump_template_types): Remove cpp_check parameter and do not pass it to
3991 dump_generic_ada_node.
3992 (dump_ada_template): Likewise.
3993 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
3994 recursively.
3995 (print_ada_methods): Change return type to integer. Remove cpp_check
3996 parameter and do not pass it down.
3997 (dump_nested_types): Remove cpp_check parameter and do not pass it to
3998 dump_generic_ada_node.
3999 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
4000 accessing methods.
4001 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
4002 down. Use has_nontrivial_methods to recognize C++ classes. Use return
4003 value of print_ada_methods.
4004 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
4005 Set cpp_check to it before invoking dump_ada_nodes.
4006 (dump_ada_specs): Likewise.
4007
2c4c3477 40082013-11-03 Marek Polacek <polacek@redhat.com>
4009
4010 * c-ubsan.c: Don't include hash-table.h.
4011 (ubsan_instrument_vla): New function.
4012 * c-ubsan.h: Declare it.
4013
452659af 40142013-10-31 David Malcolm <dmalcolm@redhat.com>
4015
4016 Automated part of renaming of symtab_node_base to symtab_node.
4017
4018 Patch autogenerated by rename_symtab.py from
4019 https://github.com/davidmalcolm/gcc-refactoring-scripts
4020 revision 58bb219cc090b2f4516a9297d868c245495ee622
4021
4022 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
4023 symtab_node_base to symtab_node.
4024
4d6f7dd4 40252013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
4026
4027 Implement C++14 digit separators.
4028 * c-lex.c (interpret_float): Remove digit separators from scratch string
4029 before building real literal.
4030
06cfe805 40312013-10-30 Jakub Jelinek <jakub@redhat.com>
4032
4033 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
4034
d037099f 40352013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
4036
4037 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
4038 fields.
4039 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
4040 enabled.
4041 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
4042 (insert_cilk_frame): New prototype.
4043 (cilk_init_builtins): Likewise.
4044 (gimplify_cilk_spawn): Likewise.
4045 (c_cilk_install_body_w_frame_cleanup): Likewise.
4046 (cilk_detect_spawn_and_unwrap): Likewise.
4047 (cilk_set_spawn_marker): Likewise.
4048 (build_cilk_sync): Likewise.
4049 (build_cilk_spawn): Likewise.
4050 * cilk.c: New file.
4051
02774f2d 40522013-10-29 David Malcolm <dmalcolm@redhat.com>
4053
4054 Patch autogenerated by refactor_symtab.py from
4055 https://github.com/davidmalcolm/gcc-refactoring-scripts
4056 revision 58bb219cc090b2f4516a9297d868c245495ee622
4057
4058 * c-gimplify.c (c_genericize): Update for conversion of symtab types
4059 to a true class hierarchy.
4060 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
4061
31fe10fd 40622013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
4063
4064 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
4065
b1c06ff9 40662013-10-26 Jeff Law <law@redhat.com>
4067
1f78217c 4068 * c-common.c (c_define_builtins): Remove mudflap support.
4069 * c.opt: Ignore and warn for mudflap options.
b1c06ff9 4070
48a972c8 40712013-10-24 Tobias Burnus <burnus@net-b.de>
4644b593 4072
4073 PR other/33426
4074 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
4075 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
4076
546a04b1 40772013-10-23 Jason Merrill <jason@redhat.com>
4078
4079 * c-format.c (gcc_cxxdiag_char_table): Add %X.
4080
bc7bff74 40812013-10-11 Jakub Jelinek <jakub@redhat.com>
4082
d62c713e 4083 * c-common.h (omp_clause_mask::operator !=): New method.
4084 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
4085 instead of if (mask & something) tests everywhere.
4086
bc7bff74 4087 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
4088 201307 instead of 201107.
4089 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
4090 (c_common_attribute_table): Add "omp declare target" and
4091 "omp declare simd" attributes.
4092 (handle_omp_declare_target_attribute,
4093 handle_omp_declare_simd_attribute): New functions.
4094 * c-omp.c: Include c-pragma.h.
4095 (c_finish_omp_taskgroup): New function.
4096 (c_finish_omp_atomic): Add swapped argument, if true,
4097 build the operation first with rhs, lhs arguments and use NOP_EXPR
4098 build_modify_expr.
4099 (c_finish_omp_for): Add code argument, pass it down to make_code.
4100 (c_omp_split_clauses): New function.
4101 (c_split_parallel_clauses): Removed.
4102 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
4103 c_omp_declare_simd_clauses_to_decls): New functions.
4104 * c-common.h (omp_clause_mask): New type.
4105 (OMP_CLAUSE_MASK_1): Define.
4106 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
4107 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
4108 omp_clause_mask::operator |, omp_clause_mask::operator &,
4109 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
4110 omp_clause_mask::operator ==): New methods.
4111 (enum c_omp_clause_split): New.
4112 (c_finish_omp_taskgroup): New prototype.
4113 (c_finish_omp_atomic): Add swapped argument.
4114 (c_finish_omp_for): Add code argument.
4115 (c_omp_split_clauses): New prototype.
4116 (c_split_parallel_clauses): Removed.
4117 (c_omp_declare_simd_clauses_to_numbers,
4118 c_omp_declare_simd_clauses_to_decls): New prototypes.
4119 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
4120 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
4121 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
4122 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
4123 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
4124 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
4125 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
4126 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
4127 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
4128 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
4129 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
4130 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
4131 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
4132 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
4133 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
4134 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
4135 PRAGMA_OMP_CLAUSE_UNIFORM.
4136
d7dcba40 41372013-10-09 Marc Glisse <marc.glisse@inria.fr>
4138
4139 PR tree-optimization/20318
4140 * c-common.c (handle_returns_nonnull_attribute): New function.
4141 (c_common_attribute_table): Add returns_nonnull.
4142
0b7282f1 41432013-10-03 Marc Glisse <marc.glisse@inria.fr>
4144
4145 PR c++/19476
4146 * c.opt (fcheck-new): Move to common.opt.
4147
51f553af 41482013-09-25 Marek Polacek <polacek@redhat.com>
4149 Jakub Jelinek <jakub@redhat.com>
4150
4151 PR sanitizer/58413
4152 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
4153 an expression if we can prove it is correct.
4154 (ubsan_instrument_division): Likewise. Remove unnecessary
4155 check.
4156
05f893e1 41572013-09-18 Marek Polacek <polacek@redhat.com>
4158
4159 PR sanitizer/58411
4160 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
4161 Declare it.
4162 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
4163
236ce1d1 41642013-09-14 Iain Sandoe <iain@codesourcery.com>
4165
4166 PR target/48094
4167 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
4168 fobjc-gc, freplace-objc-classes): Accept for LTO.
4169
f9f68d35 41702013-09-13 Jacek Caban <jacek@codeweavers.com>
4171
4172 * c-target.def: New hook
4173
ba2f764e 41742013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
4175
4176 PR c++/43452
4177 * c.opt (Wdelete-incomplete): Add.
4178
73437615 41792013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
4180
4181 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
4182 (vector_types_compatible_elements_p): New function.
4183 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
4184 declaration.
4185 (vector_types_compatible_elements_p): Declare.
4186
95af4c75 41872013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
4188
4189 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
4190 a virtual member function.
4191 (pp_simple_type_specifier): Remove.
4192 (pp_c_type_specifier): Likewise.
4193 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
4194 Rename from pp_c_type_specifier. Adjust.
4195 (c_pretty_printer::c_pretty_printer): Do not assign to
4196 simple_type_specifier.
4197
eaab24b9 41982013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
4199
4200 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
4201 member function.
4202 (c_pretty_printer::storage_class_specifier): Likewise.
4203 (c_pretty_printer::initializer): Likewise.
4204 (pp_declaration): Remove.
4205 (pp_declaration_specifiers): Likewise.
4206 (pp_abstract_declarator): Likewise.
4207 (pp_declarator): Likewise.
4208 (pp_type_id): Likewise.
4209 (pp_statement): Likewise.
4210 (pp_constant): Likewise.
4211 (pp_id_expression): Likewise.
4212 (pp_primary_expression): Likewise.
4213 (pp_unary_expression): Likewise.
4214 (pp_multiplicative_expression): Likewise.
4215 (pp_conditional_expression): Likewise.
4216 (pp_assignment_expression): Likewise.
4217 (pp_expression): Likewise.
4218 (pp_c_type_id): Likewise.
4219 (pp_c_storage_class_specifier): Likewise.
4220 * c-pretty-print.c (pp_c_type_cast): Tidy.
4221 (pp_c_pointer): Likewise.
4222 (pp_c_type_specifier): Likewise.
4223 (pp_c_parameter_type_list): Likewise.
4224 (pp_c_function_definition): Likewise.
4225 (pp_c_init_declarator): Likewise.
4226 (pp_c_initializer_list): Likewise.
4227 (pp_c_constructor_elts): Likewise.
4228 (c_pretty_printer::direct_abstract_declarator): Likewise.
4229 (c_pretty_printer::declaration_specifiers): Likewise.
4230 (c_pretty_printer::primary_expression): Likewise.
4231 (c_pretty_printer::postfix_expression): Likewise.
4232 (c_pretty_printer::type_id): Rename from pp_c_type_id.
4233 (c_pretty_printer::storage_class_specifier): Rename from
4234 pp_c_storage_class_specifier.
4235 (c_pretty_printer::initializer): Rename from pp_c_initializer.
4236 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
4237 storage_class_specifier, initializer, offset_list, flags.
4238
9e46467d 42392013-08-30 Marek Polacek <polacek@redhat.com>
4240
4241 * c-ubsan.c: New file.
4242 * c-ubsan.h: New file.
4243
36a8d9b9 42442013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
4245
4246 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
4247 member function.
4248 (c_pretty_printer::declaration_specifiers): Likewise.
4249 (c_pretty_printer::declarator): Likewise.
4250 (c_pretty_printer::abstract_declarator): Likewise.
4251 (c_pretty_printer::direct_abstract_declarator): Likewise.
4252 (c_pretty_printer::direct_declarator): Likewise.
4253 (c_pretty_printer::function_specifier): Likewise.
4254 (pp_declaration): Adjust.
4255 (pp_declaration_specifiers): Likewise.
4256 (pp_abstract_declarator): Likewise.
4257 (pp_direct_declarator): Likewise.
4258 (pp_function_specifier): Likewise.
4259 (pp_direct_abstract_declarator): Remove as unused.
4260 (pp_c_declaration): Remove.
4261 (pp_c_declaration_specifiers): Likewise.
4262 (pp_c_declarator): Likewise.
4263 (pp_c_direct_declarator): Likewise.
4264 (pp_c_function_specifier): Likewise.
4265 (pp_c_direct_abstract_declarator): Likewise.
4266 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
4267 from pp_c_abstract_declarator. Adjust.
4268 (c_pretty_printer::direct_abstract_declarator): Rename from
4269 pp_c_direct_abstract_declarator. Adjust.
4270 (c_pretty_printer::function_specifier): Rename from
4271 pp_c_function_specifier. Adjust.
4272 (c_pretty_printer::declaration_specifiers): Rename from
4273 pp_c_declaration_specifiers. Adjust.
4274 (c_pretty_printer::direct_declarator): Rename from
4275 pp_c_direct_declarator. Adjust.
4276 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
4277 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
4278 (c_pretty_printer::c_pretty_printer): Do not assign to
4279 declaration, declaration_specifiers, declarator,
4280 direct_declarator, direct_abstract_declarator, function_specifier.
4281
30635c2e 42822013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
4283
4284 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
4285 virtual member function.
4286 (c_pretty_printer::multiplicative_expression): Likewise.
4287 (c_pretty_printer::conditional_expression): Likewise.
4288 (c_pretty_printer::assignment_expression): Likewise.
4289 (c_pretty_printer::expression): Likewise.
4290 (pp_unary_expression): Adjust.
4291 (pp_multiplicative_expression): Likewise.
4292 (pp_assignment_expression): Likewise.
4293 (pp_conditional_expression): Likewise.
4294 (pp_expression): Likewise.
4295 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
4296 from pp_c_unary_expression. Adjust.
4297 (c_pretty_printer::multiplicative_expression): Rename from
4298 pp_c_multiplicative_expression. Adjust.
4299 (c_pretty_printer::conditional_expression): Rename from
4300 pp_c_conditional_expression. Adjust.
4301 (c_pretty_printer::assignment_expression): Rename from
4302 pp_c_assignment_expression. Adjust.
4303 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
4304 (c_pretty_printer::c_pretty_printer): Do not assign to
4305 unary_expression, multiplicative_expression,
4306 conditional_expression, expression.
4307
027d08ed 43082013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
4309
4310 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
4311 virtual member function.
4312 (pp_postfix_expression): Adjust.
4313 (pp_c_postfix_expression): Remove.
4314 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
4315 from pp_c_postfix_expression. Adjust.
4316 (c_pretty_printer::c_pretty_printer): Do not assign to
4317 postfix_expression.
4318
f873303a 43192013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
4320
4321 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
4322 virtua member function.
4323 (pp_primary_expression): Adjust.
4324 (pp_c_primary_expression): Remove.
4325 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
4326 from pp_c_primary_expression. Adjust.
4327 (pp_c_initializer_list): Use pp_primary_expression.
4328 (c_pretty_printer::c_pretty_printer): Do not assign to
4329 primary_expression.
4330
08e3e481 43312013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
4332
4333 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
4334 * c-pretty-print.c (M_): Remove.
4335 (c_pretty_printer::translate_string): Define.
4336 (pp_c_type_specifier): Use it.
4337 (pp_c_primary_expression): Likewise.
4338 (pp_c_expression): Likewise.
4339
1fc4a87f 43402013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
4341
4342 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
4343 virtual function.
4344 (pp_c_id_expression): Remove.
4345 (pp_id_expression): Adjust.
4346 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
4347 pp_c_id_expression. Adjust.
4348 (pp_c_postfix_expression): Use pp_id_expression.
4349 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
4350
a6cb161b 43512013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
4352
4353 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
4354 member function.
4355 (pp_constant): Adjust.
4356 (pp_c_constant): Remove.
4357 * c-pretty-print.c (c_pretty_printer::constant): Rename from
4358 pp_c_constant. Adjust.
4359 (pp_c_constant)
4360 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
4361 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
4362
eed6bc21 43632013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
4364
4365 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
4366 (c_pretty_printer::c_pretty_printer): Declare.
4367 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
4368 c_pretty_printer_init. Adjust.
4369 (print_c_tree): Do not call c_pretty_printer_init.
4370 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
4371
df558d2e 43722013-08-09 Arnaud Charlet <charlet@adacore.com>
4373
4374 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
4375
42f9a786 43762013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
4377
4378 PR c++/58080
4379 * c-common.c (pointer_int_sum): Add bool parameter.
4380 * c-common.h (pointer_int_sum): Adjust declaration.
4381
f874ddad 43822013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
4383
4384 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
4385 c_pretty_printer variable.
4386
a94db6b0 43872013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
4388
4389 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
4390 (pp_base): Remove.
4391 (pp_c_base): Likewise. Adjust users.
4392 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
4393 (pp_c_whitespace): Do not call pp_base.
4394 (pp_c_left_paren): Likewise.
4395 (pp_c_right_paren): Likewise.
4396 (pp_c_left_brace): Likewise.
4397 (pp_c_right_brace): Likewise.
4398 (pp_c_left_bracket): Likewise.
4399 (pp_c_right_bracket): Likewise.
4400 (pp_c_dot): Likewise.
4401 (pp_c_ampersand): Likewise.
4402 (pp_c_star): Likewise.
4403 (pp_c_arrow): Likewise.
4404 (pp_c_semicolon): Likewise.
4405 (pp_c_complement): Likewise.
4406 (pp_c_exclamation): Likewise.
4407 (pp_c_direct_declarator): Likewise.
4408 (pp_c_ws_string): Likewise.
4409 (pp_c_identifier): Likewise.
4410 (pp_c_statement): Likewise.
4411 (print_c_tree): Likewise.
4412
1898176c 44132013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
4414
4415 PR c++/58072
4416 * c-common.c (c_parse_error): Catch user-defined literal tokens and
4417 provide useful error strings.
4418
70d60d1d 44192013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
4420
4421 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
4422 printer functions instead of pp_string or operators and punctuators.
4423 (dump_generic_ada_node): Likewise.
4424 * c-pretty-print.c (pp_c_type_specifier): Likewise.
4425 (pp_c_relational_expression): Likewise.
4426 (pp_c_logical_or_expression): Likewise.
4427
dda4f0ec 44282013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
4429
4430 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
4431 functions instead of pp_character.
4432 (pp_ada_tree_identifier): Likewise.
4433 (dump_ada_double_name): Likewise.
4434 (dump_ada_function_declaration): Likewise.
4435 (dump_ada_array_domains): Likewise.
4436 (dump_template_types): Likewise.
4437 (dump_generic_ada_node): Likewise.
4438 (print_ada_declaration): Likewise.
4439 (print_ada_struct_decl): Likewise.
4440 * c-pretty-print.c (pp_c_integer_constant): Likewise.
4441
7aa04c8d 44422013-07-23 Tom Tromey <tromey@redhat.com>
4443
4444 * c-common.h (enum rid) <RID_GENERIC>: New constant.
4445 * c-common.c (c_common_reswords): Add _Generic.
4446
a04e8d62 44472013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
4448
4449 * c-common.c: Fix typos.
4450 * c-common.h: Likewise.
4451
a96c3cc1 44522013-07-13 Lubos Lunak <l.lunak@suse.cz>
4453
4454 PR c++/55203
4455 * c-common.c (c_common_attribute_table): Add warn_unused.
4456 (handle_warn_unused_attribute): New.
4457
da31536d 44582013-07-10 Jakub Jelinek <jakub@redhat.com>
4459
4460 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
4461 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
4462
839f2f70 44632013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
4464
4465 PR c++/57869
4466 * c.opt: Add Wconditionally-supported.
4467
73f353d0 44682013-07-08 Graham Stott <graham.stott@btinternet.com>
4469
1f78217c 4470 * array-notation-common.c (length_mismatch_in_expr_p): Delete
73f353d0 4471 unused variables l_length and l_node.
4472
21ebaa24 44732013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
f5298614 4474
4475 PR c/57821
4476 * c-common.c (complete_array_type): Delay folding first index
4477 like other indices. When folding, check for index overflow.
4478
68ea4406 44792013-06-27 Marc Glisse <marc.glisse@inria.fr>
4480
4481 PR c++/57509
4482 * c-common.h (c_build_vec_perm_expr): New complain argument.
4483 * c-common.c (c_build_vec_perm_expr): Likewise.
4484 Use save_expr also in C++.
4485
60777f69 44862013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
4487
4488 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
4489 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
4490 * c-opts.c (c_common_post_options): Likewise.
4491
839f2f70 44922013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
50acebe0 4493
4494 * array-notation-common.c (length_mismatch_in_expr): Changed the
4495 parameter type's from a dynamic array to a vec_tree. Also removed
4496 the size parameters.
4497 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
4498 the change above.
4499
e9331eab 45002013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
4501
4502 * c-common.h (struct cilkplus_an_parts): New structure.
4503 (struct cilkplus_an_loop_parts): Likewise.
4504 (cilkplus_extract_an_triplets): New prototype.
4505 (fix_sec_implicit_args): Likewise.
4506 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
4507 (fix_sec_implicit_args): Likewise.
60777f69 4508
a9c99fc4 45092013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
4510
4511 * array-notation-common.c (find_inv_trees): Removed an unwanted
4512 typecasting.
4513 * c-common.h (struct inv_list::additional_tcodes): Changed type from
4514 enum rid to enum tree_code.
4515
f2526cce 45162013-06-11 Jan Hubicka <jh@suse.cz>
4517
4518 * c-common.c (handle_alias_ifunc_attribute): Do not set
4519 DECL_EXTERNAL for weakref variables.
4520 * c-pragma.c (handle_pragma_weak): Make sure aliases
4521 are not declared as external.
4522
09970d67 45232013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
4524
4525 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
4526 function from c/c-array-notation.c.
4527 (is_cilkplus_reduce_builtin): Likewise.
4528 (find_rank): Likewise.
4529 (extract_array_notation_exprs): Likewise.
4530 (replace_array_notations): Likewise.
4531 (find_inv_trees): Likewise.
4532 (replace_inv_trees): Likewise.
4533 (contains_array_notation_expr): Likewise.
4534 (find_correct_array_notation_type): Likewise.
4535 * c-common.h (struct inv_list): Moved this struct from the file
4536 c/c-array-notation.c and added a new field called additional tcodes.
4537 (length_mismatch_in_expr_p): New prototype.
4538 (is_cilkplus_reduce_builtin): Likewise.
4539 (find_rank): Likewise.
4540 (extract_array_notation_exprs): Likewise.
4541 (replace_array_notation): Likewise.
4542 (find_inv_trees): Likewise.
4543 (replace_inv_trees): Likewise.
4544 (find_correct_array_notation_type): Likewise.
839f2f70 4545
3c6d4197 45462013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
4547
4548 * c-common.c (c_define_builtins): When cilkplus is enabled, the
4549 function array_notation_init_builtins is called.
4550 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
4551 * c-common.def (ARRAY_NOTATION_REF): New tree.
4552 * c-common.h (build_array_notation_expr): New function declaration.
4553 (build_array_notation_ref): Likewise.
4554 (extract_sec_implicit_index_arg): New extern declaration.
4555 (is_sec_implicit_index_fn): Likewise.
4556 (ARRAY_NOTATION_CHECK): New define.
4557 (ARRAY_NOTATION_ARRAY): Likewise.
4558 (ARRAY_NOTATION_START): Likewise.
4559 (ARRAY_NOTATION_LENGTH): Likewise.
4560 (ARRAY_NOTATION_STRIDE): Likewise.
4561 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
4562 ARRAY_NOTATION_REF.
4563 (pp_c_expression): Likewise.
4564 * c.opt (flag_enable_cilkplus): New flag.
4565 * array-notation-common.c: New file.
4566
8e71dad2 45672013-05-14 Jakub Jelinek <jakub@redhat.com>
4568
4569 PR c++/57274
4570 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
4571
432dd330 45722013-05-10 Marc Glisse <marc.glisse@inria.fr>
4573
4574 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
4575 vectors.
4576
b156ec37 45772013-05-07 Han Shen <shenhan@google.com>
4578
4579 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
4580
1a087624 45812013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
4582
4583 * c-common.c (check_user_alignment): Emit error for negative values.
4584
1638c736 45852013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
4586
4587 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
4588
949dbf93 45892013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
4590
4591 * c-cppbuiltin.c (c_cpp_builtins): Do not define
4592 __GXX_EXPERIMENTAL_CXX1Y__.
4593
9205a6cc 45942013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
4595 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
4596
4597 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
4598 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
4599 to simply use OPT_Wpointer_arith.
4600 (c_sizeof_or_alignof_type): Likewise.
4601
05d0bce1 46022013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
4603
4604 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
4605
41609f8b 46062013-04-12 Jakub Jelinek <jakub@redhat.com>
4607
4608 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
4609 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
4610 specifiers.
4611
c671dc4f 46122013-04-07 Steven Bosscher <steven@gcc.gnu.org>
4613
4614 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
4615
ba125576 46162013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
4617
4618 * c-common.c (pointer_int_sum): Remove dead code.
4619
9d3fa937 46202013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
4621
4622 PR middle-end/56524
4623 * c-common.c (handle_optimize_attribute): Don't call
4624 save_optabs_if_changed.
4625
5ceebb21 46262013-03-05 Jakub Jelinek <jakub@redhat.com>
4627
4628 PR middle-end/56461
4629 * c-pch.c (pch_init): Free target_validity at the end.
4630
18eeed2b 46312013-03-04 Jakub Jelinek <jakub@redhat.com>
4632
4633 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
4634
a9196da9 46352013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
4636 Jakub Jelinek <jakub@redhat.com>
4637
4638 PR sanitizer/56454
4639 * c-common.c (handle_no_sanitize_address_attribute): New function.
4640 (c_common_attribute_table): Add no_sanitize_address attribute.
4641 (handle_no_address_safety_analysis_attribute): Add
4642 no_sanitize_address attribute, not no_address_safety_analysis
4643 attribute.
4644
15c27dda 46452013-02-18 Aldy Hernandez <aldyh@redhat.com>
08c7d04b 4646
4647 PR target/52555
4648 * c-common.c (handle_optimize_attribute): Call
4649 save_optabs_if_changed.
4650
19426fe1 46512013-02-18 Jakub Jelinek <jakub@redhat.com>
4652 Steven Bosscher <steven@gcc.gnu.org>
4653
4654 PR pch/54117
4655 * c-opts.c (c_common_post_options): If debug info is enabled
4656 and non-dwarf*, refuse to load PCH files and when writing PCH
4657 file warn.
4658
df936998 46592013-02-05 Jakub Jelinek <jakub@redhat.com>
4660
4661 PR middle-end/56167
4662 * c-common.c (handle_error_attribute): Fix condition.
4663
ae0c3984 46642013-01-30 Jakub Jelinek <jakub@redhat.com>
4665
4666 PR c++/55742
4667 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
4668
1c4973d7 46692013-01-18 Jason Merrill <jason@redhat.com>
4670
4671 PR target/54908
4672 * c.opt (-fextern-tls-init): New.
4673 * c-opts.c (c_common_post_options): Handle it.
4674
7c834436 46752013-01-09 Jakub Jelinek <jakub@redhat.com>
4676
4677 PR c/48418
4678 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
4679 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
4680 and is either negative or bigger or equal to type precision
4681 of the first operand.
4682
5abaa10a 46832012-12-03 Marek Polacek <polacek@redhat.com>
4684
4685 PR c/55570
4686 * c-common.c (check_user_alignment): Swap order of tests,
4687 check TREE_CODE first.
4688
324ca377 46892012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
4690
4691 PR c++/52654
4692 * c-common.h (overflow_type): New enum.
4693 (build_userdef_literal): Add overflow_type argument.
4694 (tree_userdef_literal): Add overflow_type.
4695 (USERDEF_LITERAL_OVERFLOW): New access macro.
4696 * c-common.c (build_userdef_literal): Add overflow_type
4697 argument.
4698 * c-lex.c (c_lex_with_flags): Add overflow_type to
4699 build_userdef_literal calls.
4700 (interpret_integer, interpret_float): Add overflow_type argument.
4701
b4c4a429 47022012-11-28 Richard Biener <rguenther@suse.de>
4703
4704 PR c/35634
4705 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
4706 here and use a type with proper overflow behavior for types that would
4707 need to be promoted for the arithmetic.
4708
d413ffdd 47092012-11-23 Jakub Jelinek <jakub@redhat.com>
4710
4711 PR sanitizer/55435
4712 * c-common.c (handle_no_address_safety_analysis_attribute): New
4713 function.
4714 (c_common_attribute_table): Add no_address_safety_analysis.
4715
52bc861d 47162012-11-16 Simon Baldwin <simonb@google.com>
4717
4718 * c.opt: Add f[no-]canonical-system-headers.
4719 * c-opts.c (c_common_handle_option): Handle
4720 OPT_fcanonical_system_headers.
4721
2dd00636 47222012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
4723
4724 PR c++/54413
4725 * c-opts.c (c_common_handle_option): Set new flags.
4726 * c.opt: Describe new flags.
4727
d4701f6c 47282012-11-09 Jason Merrill <jason@redhat.com>
4729
4730 * c.opt (Wabi-tag): New.
4731
72d65da9 47322012-11-09 Andi Kleen <ak@linux.intel.com>
4733
4734 PR 55139
4735 * c-common.c (get_atomic_generic_size): Mask with
4736 MEMMODEL_MASK
4737
77a357e3 47382012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
4739
4740 PR c/53063
4741 * c.opt (Wformat): Make it Alias Wformat=1.
4742 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
4743 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
4744 LangEnabledBy.
4745 (Wformat=): RejectNegative. Use LangEnabledBy.
4746 (Wnonnull): Use LangEnabledBy.
4747 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
4748 * c-format.c (set_Wformat): Delete.
4749 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
4750 (maybe_read_dollar_number): Likewise.
4751 (avoid_dollar_number): Likewise.
4752 (finish_dollar_format_checking): Likewise.
4753 (check_format_info): Likewise.
4754 (check_format_info_main): Likewise.
4755 (check_format_types): Likewise.
4756 (format_type_warning): Likewise.
4757 * c-common.c (int): Likewise.
4758 (check_function_sentinel): Likewise.
4759 * c-common.h (warn_format,set_Wformat): Do not declare here.
4760
45efa6b9 47612012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
4762
4763 PR c/53063
4764 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
4765 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
4766 Use LangEnabledBy.
4767 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
4768 common.opt.
4769 (Wvariadic-macros): Init(1).
4770 * c-opts.c (c_common_handle_option): Do not handle them
4771 explicitly.
4772 (c_common_post_options): Likewise.
4773 (sanitize_cpp_opts): warn_unused_macros is now
4774 cpp_warn_unused_macros.
4775 (push_command_line_include): Likewise.
4776 * c-common.c (warn_unknown_pragmas): Do not define.
4777 * c-common.h (warn_unknown_pragmas): Do not declare.
4778
0e4e775a 47792012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
4780
4781 PR c/51294
4782 * c-common.c (conversion_warning): Handle conditional expressions.
4783
8b447d3f 47842012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
4785
4786 PR c++/54930
4787 * c.opt (Wreturn_local_addr): Define new option.
4788
f4a61754 47892012-10-25 Jason Merrill <jason@redhat.com>
4790
ecb10e6a 4791 * c.opt (Wvirtual-move-assign): New.
4792
f4a61754 4793 * c.opt (Winherited-variadic-ctor): New.
4794
7b463b19 47952012-10-25 Marc Glisse <marc.glisse@inria.fr>
4796
4797 PR c++/54427
4798 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
4799
6adc88f8 48002012-10-23 Joseph Myers <joseph@codesourcery.com>
4801
4802 * c-common.h (pch_cpp_save_state): Declare.
4803 * c-target.def (c_preinclude): New hook.
4804 * c-opts.c (done_preinclude): New.
4805 (push_command_line_include): Handle default preincluded header.
4806 (cb_file_change): Call pch_cpp_save_state when calling
4807 push_command_line_include.
4808 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
4809 (pch_cpp_save_state): New.
4810 (pch_init): Call pch_cpp_save_state conditionally, instead of
4811 calling cpp_save_state.
4812
fa816b0b 48132012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
4814
4815 PR c/53063
4816 PR c/40989
4817 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
4818 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
4819 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
4820 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
4821 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
4822 * c-opts.c (c_common_handle_option): Remove explicit handling from
4823 here.
4824 (c_common_post_options): Likewise.
4825
d214ccee 48262012-10-18 Eric Botcazou <ebotcazou@adacore.com>
4827
4828 * c-ada-spec.c (LOCATION_COL): Delete.
4829 (compare_location): New function.
4830 (compare_node): Use it.
4831 (compare_comment): Likewise.
4832
77b27208 48332012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
4834
4835 PR c/53063
4836 PR c/40989
4837 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
4838 * c-opts.c (c_common_handle_option): Do not set them here. Add
4839 comment.
4840 (c_common_post_options): Likewise.
4841
cc02ca4d 48422012-10-16 Eric Botcazou <ebotcazou@adacore.com>
4843
4844 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
4845 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
4846 Remove POINTER_TYPE handling, add large unsigned handling and use
4847 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
4848
57f872a2 48492012-10-12 Jakub Jelinek <jakub@redhat.com>
4850
4851 PR c/54381
4852 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
4853 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
4854 locs and array of 3 trees instead of just single loc and single
4855 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
4856 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
4857 For *cmp* builtins that take two sources strings report warnings
4858 about first and second source, not about destination and source.
4859
7354ad2e 48602012-10-12 Marc Glisse <marc.glisse@inria.fr>
4861
4862 PR c++/53055
4863 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
4864
1ac7f120 48652012-10-11 Eric Botcazou <ebotcazou@adacore.com>
4866
4867 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
4868 declaring something coming from another file.
4869
1e0cc9e3 48702012-10-10 Arnaud Charlet <charlet@adacore.com>
4871
1ac7f120 4872 PR ada/54845
1e0cc9e3 4873 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
4874
b0e7825e 48752012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
4876
4877 PR c++/54194
4878 * c-common.c (warn_about_parentheses): Add location_t parameter;
4879 use EXPR_LOC_OR_LOC.
4880 * c-common.h: Update declaration.
4881
41ed701a 48822012-10-09 Marc Glisse <marc.glisse@inria.fr>
4883
4884 PR c++/54427
4885 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
4886 more operations. Make error messages optional.
4887 * c-common.h (enum stv_conv): Moved from c-typeck.c.
4888 (scalar_to_vector): Declare.
4889
3740094c 48902012-10-08 Jason Merrill <jason@redhat.com>
4891
4892 * c-common.c (c_common_reswords): Add thread_local.
4893
ffcdbf9c 48942012-10-08 Dodji Seketeli <dodji@redhat.com>
4895
4896 PR c++/53528 C++11 attribute support
4897 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
4898 new functions.
4899 * c-common.c (check_cxx_fundamental_alignment_constraints): New
4900 static function.
4901 (handle_aligned_attribute): In choose strictest alignment
4902 among many. Use new check_cxx_fundamental_alignment_constraints.
4903 (handle_transparent_union_attribute): In c++11 attribute syntax,
4904 don't look through typedefs.
4905
ef34afc1 49062012-10-04 Arnaud Charlet <charlet@adacore.com>
4907
4908 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
4909 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
4910 out of dumpfile.h.
4911
f1ff4562 49122012-09-25 Dehao Chen <dehao@google.com>
4913
4914 PR middle-end/54645
ef34afc1 4915 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
f1ff4562 4916 map when read in the pch.
4917
92a44a68 49182012-09-18 Arnaud Charlet <charlet@adacore.com>
735538a1 4919
4920 * c-ada-spec.c: Style fixes.
4921
92a44a68 49222012-09-18 Thomas Quinot <quinot@adacore.com>
9120cdc8 4923
4924 * c.opt (-fada-spec-parent): Define new command line switch.
4925 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
4926 is specified, generate binding spec as a child of the specified unit.
4927
8eba82c2 49282012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
4929 Manuel López-Ibáñez <manu@gcc.gnu.org>
4930
4931 PR c++/53210
4932 * c.opt ([Winit-self]): Enabled by -Wall in C++.
4933
38682990 49342012-08-23 Arnaud Charlet <charlet@adacore.com>
4935
4936 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
4937 for pointers, and add missing Convention C pragma.
4938 (print_ada_struct_decl): Add missing aliased keyword.
4939 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
4940
f003f5dc 49412012-08-17 Jakub Jelinek <jakub@redhat.com>
4942
4943 * c-common.c (sizeof_pointer_memaccess_warning): New function.
4944 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
4945 * c-opts.c (c_common_handle_option): Enable it for -Wall.
4946 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
4947 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
4948
ec11736b 49492012-08-10 Richard Guenther <rguenther@suse.de>
4950
4951 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
4952
5f7f600e 49532012-08-07 Steven Bosscher <steven@gcc.gnu.org>
4954
4955 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
4956 instead of separate pp_newline and pp_flush.
4957 (print_c_tree): Likewise.
4958
758a38ab 49592012-07-26 Richard Henderson <rth@redhat.com>
4960
4961 * c-common.c (handle_hot_attribute): Allow labels.
4962 (handle_cold_attribute): Likewise.
4963
9ca77b08 49642012-07-20 Jakub Jelinek <jakub@redhat.com>
4965
4966 PR c++/28656
4967 * c-common.c (check_function_nonnull): Handle multiple nonnull
4968 attributes properly.
4969
b9ed1410 49702012-07-16 Steven Bosscher <steven@gcc.gnu.org>
4971
4972 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
4973 * c-ada-spec.c: Likewise.
4974 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
4975
c2a65b90 49762012-07-14 Steven Bosscher <steven@gcc.gnu.org>
4977
4978 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
4979 Remove code conditional on it.
4980
88c5a1d1 49812012-07-11 Steven Bosscher <steven@gcc.gnu.org>
4982
4983 * c-gimplify.c: Do not include basic-block.h.
4984 * c-common.c: Do not include linfuncs.h.
4985
4a020a8c 49862012-07-08 Steven Bosscher <steven@gcc.gnu.org>
4987
4988 * c-common.h: Include tree.h.
4989
c28ddc97 49902012-07-02 Jason Merrill <jason@redhat.com>
4991
4992 PR c++/53524
4993 * c-common.c (get_priority): Call default_conversion.
4994
405ed67f 49952012-07-01 Uros Bizjak <ubizjak@gmail.com>
4996
4997 * c-pch.c (c_common_write_pch): Remove unused variables.
4998
e53d55e7 49992012-06-29 Steven Bosscher <steven@gcc.gnu.org>
5000
5001 * cppspec.c: Moved from gcc/ to here.
5002
3d9c25ec 50032012-06-27 Kai Tietz <ktietz@redhat.com>
5004
5005 PR preprocessor/37215
5006 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
5007
3169c57a 50082012-06-21 Steven Bosscher <steven@gcc.gnu.org>
5009
5010 * c-common.h (c_common_print_pch_checksum): Remove.
5011 * c-pch.c: Do not include output.h.
5012 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
5013 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
5014 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
5015 (struct c_pch_header): Remove.
5016 (get_ident): Update gpch version.
5017 (pch_init): Do not print executable_checksum to asm_out_file.
5018 Do not fail if there is no asm_out_file to read back from. Set
5019 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
5020 (c_common_write_pch): Verify that nothing was written to asm_out_file
5021 since pch_init was called. Do not write a c_pch_header, and do not
5022 copy from asm_out_file to the PCH.
5023 (c_common_read_pch): Do not read a c_pch_header, and do not restore
5024 the content of asm_out_file from the PCH.
5025 (c_common_print_pch_checksum): Remove.
5026 * c-opts.c (c_common_init): Print out executable_checksum directly.
5027
ff6624bc 50282012-06-19 Steven Bosscher <steven@gcc.gnu.org>
5029
5030 * c-target.def (objc_declare_unresolved_class_reference,
5031 objc_declare_class_definition): Add new hooks.
5032
367b1459 50332012-06-19 Steven Bosscher <steven@gcc.gnu.org>
5034
5035 * c-lex.c: Do not include output.h.
5036 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
5037 Remove uses of ASM_OUTPUT_IDENT.
5038
bf0cb017 50392012-06-15 Marc Glisse <marc.glisse@inria.fr>
5040
5041 PR c++/51033
5042 * c-common.h (c_build_vec_perm_expr): Move decl here.
5043 * c-common.c (c_build_vec_perm_expr): Move definition
5044 here.
5045
b37a3600 50462012-06-06 Steven Bosscher <steven@gcc.gnu.org>
5047
5048 * c.opt (fconserve-space): Turn into a no-op.
5049
19931eea 50502012-06-04 Sterling Augustine <saugustine@google.com>
5f9e7dd5 5051
5052 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
5053 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
5054 both the start and end of the function.
5055
dff12c10 50562012-06-04 Steven Bosscher <steven@gcc.gnu.org>
5057
5058 * c-common.c: Do not include output.h.
5059 * c-pragma.c: Likewise.
5060
5f9e7dd5 50612012-06-04 Steven Bosscher <steven@gcc.gnu.org>
5062
5063 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
5064 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
5065 (lang_decl_name): Handle namespace decls.
5066
b5369b7d 50672012-05-31 Steven Bosscher <steven@gcc.gnu.org>
5068
5069 * c-ada-spec.c: Do not include output.h.
5070 * c-semantics.c: Likewise.
5071
8032877c 50722012-05-29 Joseph Myers <joseph@codesourcery.com>
5073
5074 * c-common.c: Fix typo.
5075
7843e4bc 50762012-05-29 Michael Matz <matz@suse.de>
5077
5078 * c-common.h (c_expand_decl): Remove prototype.
5079
8cf857d4 50802012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
5081
5082 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
5083 * c-opts.c (c_common_handle_option): Remove code handling
5084 warn_missing_braces.
5085
8b64dc3c 50862012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
5087
5088 PR c++/25137
5089 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
5090 -Wmissing_braces.
5091
43cbde16 50922012-05-22 Dodji Seketeli <dodji@redhat.com>
5093
5094 PR c++/53322
5095 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
5096
db490cb6 50972012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
5098
5099 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
5100 * c-opts.c (c_common_handle_option): Do not handle explicitly
5101 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
5102
a60f3e81 51032012-05-16 Dodji Seketeli <dodji@redhat.com>
5104
5105 PR preprocessor/7263
5106 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
5107 to cpp_classify_number. For diagnostics, use the precise location
5108 instead of the global input_location.
5109
82e6ef7c 51102012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
5111
cd4797ff 5112 PR c++/11856
82e6ef7c 5113 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
5114
258a168d 51152012-05-14 Bernd Schmidt <bernds@codesourcery.com>
5116
82e6ef7c 5117 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
258a168d 5118
d3b7ee7c 51192012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
5120
5121 PR 53063
5122 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
5123 Wreorder): Use LangEnabledBy.
5124 * c-opts.c (c_common_handle_option): Do not enable them
5125 explicitly. Call lang-specific generated functions.
5126 (c_common_post_options): Do not set them here.
5127
70059cea 51282012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
5129
5130 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
5131 Wmissing-field-initializers,Wmissing-parameter-type,
5132 Wold-style-declaration,Woverride-init): Use EnabledBy.
5133 * c-opts.c (c_common_post_options): Do not set here explicitly.
5134
fbb6fbd8 51352012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
5136
5137 PR 53063
5138 * c-opts.c (c_common_handle_option): Use handle_generated_option
5139 to enable sub-options.
5140
61f69bc9 51412012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
5142
5143 PR c++/53158
5144 * c-common.c (warnings_for_convert_and_check): Use warning_at.
5145
5a1fe2db 51462012-05-10 Richard Guenther <rguenther@suse.de>
5147
5148 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
5149 adjust commentary about TYPE_IS_SIZETYPE types.
5150
d42e7c5a 51512012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
5152
5153 PR c++/53261
5154 * c-common.c (warn_logical_operator): Check that argument of
5155 integer_zerop is not NULL.
5156
686369e8 51572012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
5158
5159 PR c/43772
5160 * c-common.c (warn_logical_operator): Do not warn if either side
5161 is already true or false.
5162
03fe1dc2 51632012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
5164
5165 PR c/51712
5166 * c-common.c (expr_original_type): New.
5167 (shorten_compare): Do not warn for enumeration types.
5168
bba5a206 51692012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
5170
5171 * c.opt (fpermissive): Add Var(flag_permissive).
5172
7059d45d 51732012-04-30 Marc Glisse <marc.glisse@inria.fr>
5174
5175 PR c++/51033
5176 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
5177 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
5178
7edb1062 51792012-04-30 Dodji Seketeli <dodji@redhat.com>
5180
5181 Add -Wvarargs option
5182 * c.opt (Wvarargs): Define new option.
5183
068bea1e 51842012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
5185
5186 * c-common.c (check_function_arguments): Replace
5187 Wmissing-format-attribute with Wsuggest-attribute=format.
5188
b86527d8 51892012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
5190
5191 * c.opt (Wsuggest-attribute=format): New. Alias of
5192 Wmissing-format-attribute.
5193 * c-format.c (decode_format_type): Replace
5194 Wmissing-format-attribute with Wsuggest-attribute=format.
5195 (check_function_format): Likewise.
5196
19931eea 51972012-04-27 Ollie Wild <aaw@google.com>
76d340ac 5198
5199 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
5200 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
5201 * c.opt: Add Wliteral-suffix.
5202
29438999 52032012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
5204
5205 PR c/44774
5206 * c.opt (Wpedantic): New.
5207 (pedantic): Alias Wpedantic.
5208 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
5209 (c_common_post_options): Likewise.
5210 (sanitize_cpp_opts): Likewise.
5211 * c-lex.c (interpret_float): Likewise.
5212 * c-format.c (check_format_types): Likewise.
5213 * c-common.c (pointer_int_sum): Likewise.
5214 (c_sizeof_or_alignof_type): Likewise.
5215 (c_add_case_label): Likewise.
5216 (c_do_switch_warnings): Likewise.
5217 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
5218
4f9d6b8b 52192012-04-15 Jason Merrill <jason@redhat.com>
5220
5221 PR c++/52818
5222 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
5223 (C_STD_NAME): Distinguish between C++98 and C++11.
5224
74bdbe96 52252012-04-11 Eric Botcazou <ebotcazou@adacore.com>
5226
5227 PR target/52624
5228 * c-common.h (uint16_type_node): Rename into...
5229 (c_uint16_type_node): ...this.
5230 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
5231 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
5232
3d177e8c 52332012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
5234
5235 * c-common.c (warn_if_unused_value): Move definition to here.
5236 * c-common.h (warn_if_unused_value): Move declaration to here.
5237
6a9a958f 52382012-03-23 William Bader <williambader@hotmail.com>
5239
5240 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
5241
543efdbe 52422012-03-20 Jason Merrill <jason@redhat.com>
5243
5244 * c-common.h (enum cxx_dialect): Add cxx1y.
5245 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
5246 test.
5247 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
5248 * c-opts.c (c_common_post_options): Likewise.
5249 (set_std_cxx1y): New.
5250 (c_common_handle_option): Call it.
5251 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
5252
62206d34 52532012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
5254
5255 PR c++/14710
5256 * c.opt ([Wuseless-cast]): Add.
5257
fadf62f4 52582012-03-16 Richard Guenther <rguenther@suse.de>
5259
5260 * c-pretty-print.c (pp_c_initializer_list): Adjust.
5261
249faa35 52622012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
5263
5264 PR c++/44783
5265 * c.opt (ftemplate-backtrace-limit) Add.
5266
126b6848 52672012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5268
5269 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
5270 handling.
5271 * c-pragma.c (handle_pragma_extern_prefix): Remove.
5272 (init_pragma): Don't register extern_prefix.
5273
a51edb4c 52742012-03-12 Richard Guenther <rguenther@suse.de>
5275
5276 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
5277 (builtin_type_for_size): Likewise.
5278
0f6a7cb7 52792012-02-13 Jakub Jelinek <jakub@redhat.com>
5280
5281 PR c++/52215
5282 * c-common.c (sync_resolve_params): Don't decide whether to convert
5283 or not based on TYPE_SIZE comparison, convert whenever arg_type
5284 is unsigned INTEGER_TYPE.
5285
0779e32c 52862012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
5287
5288 PR c/52118
5289 * c.opt ([Wunused-local-typedefs]): Fix description.
5290
baec58e1 52912012-01-24 Mike Stump <mikestump@comcast.net>
5292
5293 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
5294 exactly.
5295
c779d8cc 52962012-01-18 Richard Guenther <rguenther@suse.de>
5297
5298 * c-opts.c (c_common_post_options): Reset LTO flags if
5299 we are about to generate a PCH.
5300
ee917d24 53012012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
5302
5303 PR c++/51777
5304 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
5305 use pp_unsigned_wide_integer.
5306
90e2341f 53072012-01-10 Richard Guenther <rguenther@suse.de>
5308
5309 PR middle-end/51806
5310 * c-opts.c (c_common_handle_option): Move -Werror handling
5311 to language independent code.
5312
9ea022ce 53132012-01-05 Richard Guenther <rguenther@suse.de>
5314
5315 PR middle-end/51764
5316 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
5317 from common.opt.
5318
3df19e1b 53192011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
5320
5321 PR c++/51316
5322 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
5323 of array types with an unknown bound.
5324
32074525 53252011-12-20 Joseph Myers <joseph@codesourcery.com>
5326
5327 * c-common.c (flag_isoc99): Update comment to refer to C11.
5328 (flag_isoc1x): Change to flag_isoc11.
5329 * c-common.h (flag_isoc99): Update comment to refer to C11.
5330 (flag_isoc1x): Change to flag_isoc11.
5331 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
5332 C11.
5333 * c-opts.c (set_std_c1x): Change to set_std_c11.
5334 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
5335 Call set_std_c11.
5336 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
5337 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
5338 * c.opt (std=c1x): Change to std=c11. Document as non-draft
5339 standard.
5340 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
5341 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
5342 (std=gnu1x): Make alias of std=gnu11.
5343
fca86134 53442011-12-19 Jason Merrill <jason@redhat.com>
5345
5346 PR c++/51228
5347 * c-common.c (handle_transparent_union_attribute): Check the first
5348 field if the type is complete.
5349
aa4313eb 53502011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
5351
5352 PR libstdc++/51365
5353 * c-common.c (RID_IS_FINAL): Add.
5354 * c-common.h (RID_IS_FINAL): Add.
5355
3f3d5ad4 53562011-11-30 Iain Sandoe <iains@gcc.gnu.org>
5357
5358 * c.opt (fgnu-runtime): Provide full description.
5359 (fnext-runtime): Likewise.
5360 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
5361
c4606d19 53622011-11-28 Andrew MacLeod <amacleod@redhat.com>
5363
5364 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
5365 predefines in one place. Add LOCK_FREE predefines.
5366 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
5367 new func.
5368
1d581089 53692011-11-24 Andrew MacLeod <amacleod@redhat.com>
5370
5371 PR c/51256
19931eea 5372 * c-common.c (get_atomic_generic_size): Check for various error
1d581089 5373 conditions
19931eea 5374 (resolve_overloaded_atomic_exchange,
5375 resolve_overloaded_atomic_compare_exchange,
1d581089 5376 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
5377 error_mark_node for error conditions.
19931eea 5378
6aa221fa 53792011-11-08 Richard Guenther <rguenther@suse.de>
5380
5381 PR middle-end/51010
5382 c-family/
5383
4c0315d0 53842011-11-07 Richard Henderson <rth@redhat.com>
5385 Aldy Hernandez <aldyh@redhat.com>
5386 Torvald Riegel <triegel@redhat.com>
5387
5388 Merged from transactional-memory.
5389
5390 * c-common.c (handle_tm_wrap_attribute,
5391 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
5392 (struct c_common_reswords): Added __transaction* keywords.
5393 (struct c_common_attribute_table): Added transaction* and tm_regparm
5394 attributes.
5395 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
5396 masks.
5397 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
5398 find_tm_attribute): Declare.
5399
920f5a70 54002011-11-07 Jason Merrill <jason@redhat.com>
5401
5402 PR c++/35688
5403 * c-common.c, c-common.h: Revert yesterday's changes.
5404
b4f861b4 54052011-11-06 Jason Merrill <jason@redhat.com>
5406
5407 PR c++/35688
5408 * c-common.c (decl_has_visibility_attr): Split out from...
5409 (c_determine_visibility): ...here.
5410 * c-common.h: Declare it.
5411
83e25171 54122011-11-06 Joseph Myers <joseph@codesourcery.com>
5413
5414 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
5415 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
5416 type.
5417 (check_user_alignment): New. Split out of
5418 handle_aligned_attribute. Disallow integer constants with
5419 noninteger types. Conditionally allow zero.
5420 (handle_aligned_attribute): Use check_user_alignment.
5421 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
5422
1cd6e20d 54232011-11-06 Andrew MacLeod <amacleod@redhat.com>
5424 Richard Henderson <rth@redhat.com>
5425
5426 Merged from cxx-mem-model.
5427
5428 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
19931eea 5429 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
1cd6e20d 5430 parameters that are the same type size.
5431 (get_atomic_generic_size): New. Find size of generic
5432 atomic function parameters and do typechecking.
5433 (add_atomic_size_parameter): New. Insert size into parameter list.
5434 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
5435 either __atomic_exchange_n or external library call.
19931eea 5436 (resolve_overloaded_atomic_compare_exchange): Restructure
1cd6e20d 5437 __atomic_compare_exchange to either _n variant or external library call.
19931eea 5438 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
1cd6e20d 5439 __atomic_load_n or an external library call.
5440 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
5441 __atomic_store_n or an external library call.
5442 (resolve_overloaded_builtin): Handle new __atomic builtins.
5443
7549df0d 54442011-11-04 Eric Botcazou <ebotcazou@adacore.com>
5445
5446 PR c++/50608
5447 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
5448 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
5449 <INDIRECT_REF>: Return the argument.
5450 <ARRAY_REF>: Remove special code for negative offset.
5451 Call fold_build_pointer_plus instead of size_binop.
5452 (fold_offsetof): Remove STOP_REF argument and adjust.
5453 * c-common.h (fold_offsetof_1): Declare.
5454 (fold_offsetof): Remove STOP_REF argument.
5455
7e783eb3 54562011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
5457
5458 PR c++/50810
5459 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
5460 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
5461 Wnarrowing for C++0x and C++98.
5462 * c.opt ([Wnarrowing]): Update.
5463
8fe701f5 54642011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
5465
5466 PR c++/44277
5467 * c.opt: Add Wzero-as-null-pointer-constant.
5468
0d84dc2d 54692011-10-31 Jason Merrill <jason@redhat.com>
5470
67031f52 5471 * c.opt (-fdeduce-init-list): Off by default.
5472
0d84dc2d 5473 PR c++/50920
5474 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
5475 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
5476 and -Wc++11-compat.
5477 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
5478
66f24c41 54792011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
5480
5481 PR c++/30066
5482 * c.opt (fvisibility-inlines-hidden): Description change.
5483
244db24d 54842011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
5485
5486 Implement C++11 user-defined literals.
5487 * c-common.c (build_userdef_literal): New.
5488 * c-common.def: New tree code.
5489 * c-common.h (tree_userdef_literal): New tree struct and accessors.
5490 * c-lex.c (interpret_float): Add suffix parm.
5491 (c_lex_with_flags): Build literal tokens.
5492
235be70f 54932011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
5494
5495 PR c++/50841
5496 Revert:
5497 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
5498
5499 PR c++/50810
5500 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
5501 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
5502 Wnarrowing for C++0x and C++98.
5503 * c.opt ([Wnarrowing]): Update.
5504
4fe0fb1c 55052011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
5506
5507 PR c++/50810
5508 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
5509 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
5510 Wnarrowing for C++0x and C++98.
5511 * c.opt ([Wnarrowing]): Update.
5512
5f7504f9 55132011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
5514
5515 PR c++/45385
5516 * c-common.c (conversion_warning): Remove code looking for
5517 artificial operands.
5518
2a688977 55192011-10-18 Dodji Seketeli <dodji@redhat.com>
5520
5521 PR bootstrap/50760
5522 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
19931eea 5523 !NO_IMPLICIT_EXTERN_C.
2a688977 5524
326e3391 55252011-10-17 Michael Spertus <mike_spertus@symantec.com>
5526
5527 * c-common.c (c_common_reswords): Add __bases,
5528 __direct_bases.
5529 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
5530
55312011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
5532
5533 PR c++/50757
5534 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
5535
62db153a 55362011-10-15 Tom Tromey <tromey@redhat.com>
5537 Dodji Seketeli <dodji@redhat.com>
5538
5539 * c.opt (fdebug-cpp): New option.
5540 * c-opts.c (c_common_handle_option): Handle the option.
5541 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
5542 output stream in parameter. Factorized from ...
5543 (maybe_print_line): ... this. Dump location debug information when
5544 -fdebug-cpp is in effect.
5545 (print_line_1): New static function. Takes an output stream in
5546 parameter. Factorized from ...
5547 (print_line): ... here. Dump location information when -fdebug-cpp
5548 is in effect.
5549 (scan_translation_unit): Dump location information when
5550 -fdebug-cpp is in effect.
5551
ce70f433 55522011-10-15 Tom Tromey <tromey@redhat.com>
5553 Dodji Seketeli <dodji@redhat.com>
5554
5555 * c.opt (ftrack-macro-expansion): New option. Handle it with and
5556 without argument.
5557 * c-opts.c (c_common_handle_option)<case
5558 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
5559 cases. Handle -ftrack-macro-expansion with and without argument.
5560
97bfb9ef 55612011-10-15 Tom Tromey <tromey@redhat.com>
5562 Dodji Seketeli <dodji@redhat.com>
5563
5564 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
5565 (print_line, cb_define, do_line_change): Adjust to avoid touching
5566 the internals of struct line_map. Use the public API instead.
5567 * c-pch.c (c_common_read_pch): Likewise.
5568 * c-lex.c (fe_file_change): Likewise.
5569
326e3391 55702011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
5571
5572 PR c++/17212
5573 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
5574
55752011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
5576
5577 PR c++/33067
5578 * c-pretty-print.c (pp_c_floating_constant): Output
5579 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
5580
b9a16870 55812011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
5582
5583 * c-common.c (def_builtin_1): Delete old interface with two
5584 parallel arrays to hold standard builtin declarations, and replace
5585 it with a function based interface that can support creating
5586 builtins on the fly in the future. Change all uses, and poison
5587 the old names. Make sure 0 is not a legitimate builtin index.
5588 * c-omp.c (c_finish_omp_barrier): Ditto.
5589 (c_finish_omp_taskwait): Ditto.
5590 (c_finish_omp_flush): Ditto.
5591
c7964868 55922011-10-11 Tristan Gingold <gingold@adacore.com>
5593
5594 * c.opt: (fallow-parameterless-variadic-functions): New.
5595
a4e3ffad 55962011-09-08 Dodji Seketeli <dodji@redhat.com>
5597
5598 PR c++/33255 - Support -Wunused-local-typedefs warning
5599 * c-common.h (struct c_language_function::local_typedefs): New
5600 field.
19931eea 5601 (record_locally_defined_typedef, maybe_record_typedef_use)
5602 (maybe_warn_unused_local_typedefs): Declare new functions.
a4e3ffad 5603 * c-common.c (record_locally_defined_typedef)
19931eea 5604 (maybe_record_typedef_use)
5605 (maybe_warn_unused_local_typedefs): Define new functions.
a4e3ffad 5606 * c.opt: Declare new -Wunused-local-typedefs flag.
5607
737a23cc 56082011-09-06 Eric Botcazou <ebotcazou@adacore.com>
5609
5610 PR middle-end/50266
5611 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
5612 computations.
5613
7542c3b4 56142011-09-05 Richard Guenther <rguenther@suse.de>
5615
5616 * c-common.c (complete_array_type): Use ssize_int (-1) instead
5617 of integer_minus_one_node for empty array upper bounds.
5618
1dc92c59 56192011-08-28 Dodji Seketeli <dodji@redhat.com>
5620
5621 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
5622 it's the first time it's being called on this main TU.
5623
2bdf2b6e 56242011-08-24 Richard Guenther <rguenther@suse.de>
5625
5626 PR c/49396
5627 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
5628
56292011-08-22 Gabriel Charette <gchare@google.com>
6ea2c7a3 5630
5631 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
5632 defined in cpp_init_builtins and c_cpp_builtins.
5633
bff4ad11 56342011-08-19 Joseph Myers <joseph@codesourcery.com>
5635
5636 * c-common.c (c_common_reswords): Add __builtin_complex.
5637 * c-common.h (RID_BUILTIN_COMPLEX): New.
5638
985c6e3a 56392011-08-18 Joseph Myers <joseph@codesourcery.com>
5640
5641 * c-common.c (c_common_reswords): Add _Noreturn.
5642 (keyword_is_function_specifier): Handle RID_NORETURN.
5643 * c-common.h (RID_NORETURN): New.
5644
92a44a68 56452011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
7dfa155b 5646
5647 * c-common.c (unsafe_conversion_p): New function. Check if it is
5648 unsafe to convert an expression to the type.
5649 (conversion_warning): Adjust, use unsafe_conversion_p.
5650 * c-common.h (unsafe_conversion_p): New function declaration.
5651
2169f33b 56522011-08-02 Jakub Jelinek <jakub@redhat.com>
5653
5654 * c-common.h (c_finish_omp_atomic): Adjust prototype.
5655 (c_finish_omp_taskyield): New prototype.
5656 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
5657 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
5658 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
5659 or RHS1 have side-effects, evaluate those too in the right spot,
5660 if it is a decl and LHS is also a decl, error out if they
5661 aren't the same.
5662 (c_finish_omp_taskyield): New function.
5663 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
5664 * c-pragma.c (omp_pragmas): Add taskyield.
5665 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
5666 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
5667 PRAGMA_OMP_CLAUSE_MERGEABLE.
5668
ab77850e 56692011-07-25 Dodji Seketeli <dodji@redhat.com>
5670
5671 * c-common.h (set_underlying_type): Remove parm name from
5672 declaration.
5673
6ee97920 56742011-07-25 Romain Geissler <romain.geissler@gmail.com>
5675
5676 * c-pretty-print.h: Search c-common.h in c-family.
19931eea 5677
dc251364 56782011-07-22 Jason Merrill <jason@redhat.com>
5679
1a2a35f0 5680 PR c++/49793
5681 * c.opt (Wnarrowing): New.
5682
27282252 5683 PR c++/30112
5684 * c-common.h: Declare c_linkage_bindings.
5685 * c-pragma.c (handle_pragma_redefine_extname): Use it.
5686
dc251364 5687 PR c++/49813
5688 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
5689 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
5690 as flag_isoc99 for 'restrict'.
5691 (pp_c_specifier_qualifier_list): Likewise for _Complex.
5692
fc501191 56932011-07-21 Ian Lance Taylor <iant@google.com>
5694
5695 PR middle-end/49705
5696 * c-common.c (c_disable_warnings): New static function.
5697 (c_enable_warnings): New static function.
5698 (c_fully_fold_internal): Change local unused_p to bool. Call
5699 c_disable_warnings and c_enable_warnings rather than change
5700 c_inhibit_evaluation_warnings.
5701
07b8f133 57022011-07-20 Jason Merrill <jason@redhat.com>
5703
5704 PR c++/6709 (DR 743)
5705 PR c++/42603 (DR 950)
5706 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
5707 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
5708 (CPP_DECLTYPE): New.
5709 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
5710
2cc66f2a 57112011-07-19 Richard Guenther <rguenther@suse.de>
5712
5713 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
5714 * c-omp.c (c_finish_omp_for): Likewise.
5715
3c802a1e 57162011-07-12 Eric Botcazou <ebotcazou@adacore.com>
5717
5718 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
5719 body on the next line.
5720
98a33d9f 57212011-07-08 Jason Merrill <jason@redhat.com>
5722
3115bda0 5723 PR c++/45437
5724 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
5725
98a33d9f 5726 PR c++/49673
5727 * c-common.c (c_apply_type_quals_to_decl): Don't check
5728 TYPE_NEEDS_CONSTRUCTING.
5729
c38a75b7 57302011-07-06 Richard Guenther <rguenther@suse.de>
5731
5732 * c-common.c (c_common_nodes_and_builtins):
5733 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
5734
e593356b 57352011-07-05 Richard Guenther <rguenther@suse.de>
5736
5737 * c-common.c (c_common_nodes_and_builtins): Build all common
5738 tree nodes first.
5739
fca0886c 57402011-06-27 Jakub Jelinek <jakub@redhat.com>
5741
a68f7a8d 5742 * c-common.h (c_tree_chain_next): New static inline function.
5743
fca0886c 5744 * c-common.c (check_builtin_function_arguments): Handle
5745 BUILT_IN_ASSUME_ALIGNED.
5746
2797f13a 57472011-06-21 Andrew MacLeod <amacleod@redhat.com>
5748
5749 * c-common.c: Add sync_ or SYNC__ to builtin names.
5750 * c-omp.c: Add sync_ or SYNC__ to builtin names.
9cad95b7 5751
57522011-06-20 Pierre Vittet <piervit@pvittet.com>
5753
5754 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
5755 handler.
5756 (gen_pragma_handler): New union.
5757 (internal_pragma_handler): New type.
5758 (c_register_pragma_with_data)
5759 (c_register_pragma_with_expansion_and_data): New functions.
5760
5761 * c-pragma.c (registered_pragmas, c_register_pragma_1)
5762 (c_register_pragma, c_register_pragma_with_expansion)
5763 (c_invoke_pragma_handler): Changed to work with
5764 internal_pragma_handler.
5765 (c_register_pragma_with_data)
5766 (c_register_pragma_with_expansion_and_data): New functions.
5767
218e3e4e 57682011-06-14 Joseph Myers <joseph@codesourcery.com>
5769
5770 * c-common.c: Include common/common-target.h.
5771 (handle_section_attribute): Use
5772 targetm_common.have_named_sections.
5773 * c-cppbuiltin.c: Include common/common-target.h.
5774 (c_cpp_builtins): Use targetm_common.except_unwind_info.
5775
41e53ed2 57762011-06-10 Richard Guenther <rguenther@suse.de>
5777
5778 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
5779 to print a IDENTIFIER_NODE.
5780
a6f06169 57812011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5782 Joseph Myers <joseph@codesourcery.com>
5783
5784 * c.opt (fbuilding-libgcc): New option.
5785 * c-cppbuiltin.c (c_cpp_builtins): Define
5786 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
5787
1ea9269b 57882011-06-07 Jason Merrill <jason@redhat.com>
5789
8ce59854 5790 * c-common.c (max_tinst_depth): Lower default to 900.
5791
1ea9269b 5792 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
5793
1af0124d 57942011-06-07 Richard Guenther <rguenther@suse.de>
5795
5796 * c-common.c (c_common_nodes_and_builtins): Do not set
5797 size_type_node or call set_sizetype.
5798
0e9a4c01 57992011-06-07 Dodji Seketeli <dodji@redhat.com>
5800
5801 PR debug/49130
5802 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
19931eea 5803 type when using pointer comparison to compare types.
0e9a4c01 5804
90b40725 58052011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
5806
5807 * c.opt: Add -Wdelete-non-virtual-dtor.
5808 * c-opts.c (c_common_handle_option): Include it in -Wall.
5809
fc9c9e87 58102011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
5811
5812 PR bootstrap/49190
5813
5814 Revert:
5815 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
5816
5817 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
5818 not tree_common.
5819
d0389adc 58202011-05-27 Jakub Jelinek <jakub@redhat.com>
5821
5822 PR c++/49165
5823 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
5824 C++ don't call c_common_truthvalue_conversion on void type arms.
5825
cacfdc02 58262011-05-27 Nathan Froyd <froydnj@codesourcery.com>
5827
5828 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
5829 (stmt_list_stack): Define.
5830 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
5831 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
5832
027fc6ef 58332011-05-26 Nathan Froyd <froydnj@codesourcery.com>
5834
5835 * c-common.c (warning_candidate_p): Check for BLOCKs.
5836
f21317a1 58372011-05-26 Nathan Froyd <froydnj@codesourcery.com>
5838
5839 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
5840 not tree_common.
5841
789e953d 58422011-05-25 Jakub Jelinek <jakub@redhat.com>
5843
5844 * c-common.c (def_fn_type): Remove extra va_end.
5845
7f506bca 58462011-05-23 Jason Merrill <jason@redhat.com>
5847
5848 PR c++/48106
5849 * c-common.c (c_common_get_narrower): New.
5850 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
5851
774e9d58 58522011-05-23 Nathan Froyd <froydnj@codesourcery.com>
5853
5854 * c-common.h (check_function_arguments): Tweak prototype of
5855 check_function_arguments.
5856 * c-common.c (check_function_arguments): Likewise. Adjust
5857 calls to check_function_nonnull, check_function_format, and
5858 check_function_sentinel.
5859 (check_function_sentinel): Take a FUNCTION_TYPE rather than
5860 separate attributes and typelist arguments. Use
5861 FOREACH_FUNCTION_ARGS to iterate over argument types.
5862
23407dc9 58632011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
5864
5865 * c-common.c (c_common_reswords): Reorder.
5866 * c-common.h (rid): Likewise.
5867
3a939d12 58682011-05-10 Nathan Froyd <froydnj@codesourcery.com>
5869
5870 * c-common.c (def_fn_type): Don't call build_function_type, call
5871 build_function_type_array or build_varargs_function_type_array
5872 instead.
5873 (c_common_nodes_and_builtins): Likewise.
5874
b6e3dd65 58752011-05-05 Nathan Froyd <froydnj@codesourcery.com>
5876
5877 * c-common.c (c_add_case_label): Omit the loc argument to
5878 build_case_label.
5879 * c-common.h (build_case_label): Remove.
5880 * c-semantics.c (build_case_label): Remove.
5881
4232a958 58822011-05-05 Joseph Myers <joseph@codesourcery.com>
5883
5884 * c-objc.h (objc_start_method_definition): Update prototype.
5885 * stub-objc.c (objc_start_method_definition): Add extra parameter.
5886
d0af78c5 58872011-05-04 Nathan Froyd <froydnj@codesourcery.com>
5888
5889 * c-common.c (check_main_parameter_types): Reindent. Don't use
5890 TYPE_ARG_TYPES directly.
5891 (handle_nonnull_attribute): Likewise.
5892 (sync_resolve_params): Likewise.
5893 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
5894 to check_format_string.
5895 (handle_format_attribute): Likewise.
5896 (check_format_string): Take a function type to examine instead of
5897 a type list. Use a function_arg_iterator to step through argument
5898 types.
5899
ceb7b692 59002011-05-04 Richard Guenther <rguenther@suse.de>
5901
5902 * c-common.c (fix_string_type): Use size_int for index type bounds.
5903 (start_fname_decls): Do not pass NULL to build_int_cst.
5904 (c_init_attributes): Likewise.
5905 * c-lex.c (c_lex_with_flags): Likewise.
5906
c66c81be 59072011-04-27 Jason Merrill <jason@redhat.com>
5908
5909 * c-common.c (make_tree_vector_from_list): New.
5910 * c-common.h: Declare it.
5911
16930c72 59122011-04-26 Richard Guenther <rguenther@suse.de>
5913
5914 PR preprocessor/48248
5915 * c-ppoutput.c (maybe_print_line): Always optimize newlines
5916 for output size with -P.
5917
23407dc9 59182011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
5919
5920 * c-common.c (struct c_common_resword): Add __underlying_type.
5921 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
5922
dd045aee 59232011-04-20 Jim Meyering <meyering@redhat.com>
5924
5925 * c-format.c (init_dollar_format_checking): Remove useless
5926 if-before-free.
5927
394dd737 59282011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
5929
5930 * c-objc.h (objc_get_interface_ivars): Removed.
23407dc9 5931 (objc_detect_field_duplicates): New.
394dd737 5932 * stub-objc.c: Likewise.
23407dc9 5933
a758bf7d 59342011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
5935
5936 * stub-objc.c (objc_declare_protocols): Renamed to
5937 objc_declare_protocol.
5938 * c-objc.h: Likewise.
23407dc9 5939
29d7200d 59402011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
5941
5942 * stub-objc.c (objc_declare_class): Updated argument name.
5943
9b88d08d 59442011-04-12 Nathan Froyd <froydnj@codesourcery.com>
5945
5946 * c-common.h (c_common_init_ts): Declare.
5947 * c-common.c (c_common_init_ts): Define.
5948
4185cf58 59492011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
5950
5951 * c-objc.h (objc_build_message_expr): Updated prototype.
5952 * stub-objc.c (objc_build_message_expr): Likewise.
19931eea 5953
5a90471f 59542011-04-12 Martin Jambor <mjambor@suse.cz>
5955
5956 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
5957 of cgraph_node.
5958
783bb57e 59592011-04-11 Richard Guenther <rguenther@suse.de>
5960
5961 * c-common.c (complete_array_type): Build a range type of
5962 proper type.
5963
c33080b9 59642011-04-08 Nathan Froyd <froydnj@codesourcery.com>
5965
5966 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
5967 (handle_type_generic_attribute): Likewise.
5968
f8913d47 59692011-04-07 Jason Merrill <jason@redhat.com>
5970
5971 PR c++/48450
5972 * c-common.c (c_common_truthvalue_conversion): Don't ignore
5973 conversion from C++0x scoped enum.
5974
c94b1d0e 59752011-04-06 Joseph Myers <joseph@codesourcery.com>
5976
5977 * c-target-def.h: New file.
5978 * c-target.def: New file.
5979 * c-target.h: New file.
5980 * c-common.c (targetcm): Don't define here.
5981 * c-common.h (default_handle_c_option): Declare.
5982 * c-format.c: Include c-target.h instead of target.h.
5983 * c-opts.c: Include c-target.h instead of target.h. Explicitly
5984 include tm.h.
5985 (default_handle_c_option): Move from targhooks.c.
5986
acb10f41 59872011-03-29 Jakub Jelinek <jakub@redhat.com>
5988
5989 PR preprocessor/48248
5990 * c-ppoutput.c (print): Add src_file field.
5991 (init_pp_output): Initialize it.
5992 (maybe_print_line): Don't optimize by adding up to 8 newlines
5993 if map->to_file and print.src_file are different file.
5994 (print_line): Update print.src_file.
5995
82715bcd 59962011-03-25 Kai Tietz <ktietz@redhat.com>
5997
5998 * c-ada-spec.c (compare_comment): Use filename_cmp
5999 instead of strcmp for filename.
6000
451c8e2f 60012011-03-25 Jeff Law <law@redhat.com>
6002
1f78217c 6003 * c-common.c (def_fn_type): Add missing va_end.
451c8e2f 6004
3c47771c 60052011-03-25 Jason Merrill <jason@redhat.com>
6006
6007 * c.opt: Add -std=c++03.
6008
97e6200f 60092011-03-22 Eric Botcazou <ebotcazou@adacore.com>
6010
6011 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
6012
92a44a68 60132011-03-17 Kai Tietz <ktietz@redhat.com>
ac86af5d 6014
6015 PR target/12171
ee212425 6016 * c-pretty-print.c (pp_c_specifier_qualifier_list):
6017 Display allowed attributes for function pointer types.
6018 (pp_c_attributes_display): New function to display
6019 attributes having affects_type_identity flag set to true.
6020 * c-pretty-print.h (pp_c_attributes_display): New prototype.
6021
ac86af5d 6022 * c-common.c (c_common_attribute_table):
6023 Add new element.
6024 (c_common_format_attribute_table): Likewise.
6025
914d1151 60262011-03-18 Jason Merrill <jason@redhat.com>
6027
69788bdf 6028 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
6029 * c-common.h: Don't declare it here.
6030 * c-common.c: Or define it here.
6031 * c-opts.c (c_common_handle_option): Or set it here.
6032
914d1151 6033 PR c++/35315
6034 * c-common.c (handle_transparent_union_attribute): Don't
6035 make a duplicate type in C++.
6036
54cf6eed 60372011-03-15 Jason Merrill <jason@redhat.com>
6038
6039 * c-common.c (max_constexpr_depth): New.
6040 * c-common.h: Declare it.
6041 * c-opts.c (c_common_handle_option): Set it.
6042 * c.opt (fconstexpr-depth): New option.
6043
02cb1060 60442011-03-11 Jason Merrill <jason@redhat.com>
6045
9bf1c74e 6046 * c-common.c (attribute_takes_identifier_p): Add missing const.
6047
02cb1060 6048 PR c++/46803
6049 * c-common.c (attribute_takes_identifier_p): Assume that an
6050 unknown attribute takes an identifier.
6051
ecf2703d 60522011-03-07 Nathan Froyd <froydnj@codesourcery.com>
6053
6054 PR c/47786
6055 * c-common.c (c_type_hash): Call list_length instead of iterating
6056 through DECL_CHAIN. Rename 'i' to 'n_elements'.
6057
2b19dfe4 60582011-02-19 Jakub Jelinek <jakub@redhat.com>
6059
6060 PR c/47809
6061 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
6062
29cf2335 60632011-02-17 Iain Sandoe <iains@gcc.gnu.org>
6064
6065 * c.opt (fobjc-abi-version=) New.
6066 (fobjc-nilcheck): New.
6067
fad3f658 60682011-02-03 Nathan Froyd <froydnj@codesourcery.com>
6069
6070 PR c++/46890
6071 * c-common.h (keyword_is_decl_specifier): Declare.
6072 * c-common.c (keyword_is_decl_specifier): Define.
6073 (keyword_is_function_specifier): New function.
6074
a12319b3 60752011-01-26 Jakub Jelinek <jakub@redhat.com>
6076
6077 PR c/47473
6078 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
6079 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
6080 REAL_TYPE.
6081
5c128dc8 60822011-01-26 Arnaud Charlet <charlet@adacore.com>
6083
6084 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
6085
8d67b0c7 60862011-01-26 Jakub Jelinek <jakub@redhat.com>
6087
6088 PR pch/47430
6089 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
6090 after init_c_lex if pch_file is set.
6091
0675168d 60922011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
6093
e8911163 6094 PR c++/43601
0675168d 6095 * c.opt (-fkeep-inline-dllexport): New switch.
6096
0725e25c 60972011-01-12 Richard Guenther <rguenther@suse.de>
6098
6099 PR middle-end/32511
6100 * c-common.c (handle_weak_attribute): Warn instead of error
6101 on declaring an inline function weak.
6102
fdd84b77 61032011-01-05 Tom Tromey <tromey@redhat.com>
6104
6105 * c-common.h (lvalue_error): Update.
6106 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
6107 not error.
6108
e6e73d14 61092010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
19931eea 6110
d67e8485 6111 PR objc/47075
6112 * c-objc.h (objc_finish_message_expr): Added argument to
6113 prototype.
6114
a36cf284 61152010-12-22 Nathan Froyd <froydnj@codesourcery.com>
6116
6117 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
6118 Use prototype_p.
6119
33b3681f 61202010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
6121
6122 * c-objc.h (objc_maybe_warn_exceptions): New.
19931eea 6123 * stub-objc.c (objc_maybe_warn_exceptions): New.
33b3681f 6124
a1f90215 61252010-12-10 Nathan Froyd <froydnj@codesourcery.com>
6126
6127 * c-common.h (readonly_error): Declare.
6128 * c-common.c (readonly_error): Define.
6129
b1bbc8e5 61302010-12-09 Nathan Froyd <froydnj@codesourcery.com>
6131
6132 * c-common.h (invalid_indirection_error): Declare.
6133 * c-common.c (invalid_indirection_error): Define.
6134
b0d55af9 61352010-12-03 Richard Guenther <rguenther@suse.de>
6136
6137 PR c/46745
6138 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
6139 (pp_c_unary_expression): Likewise.
6140 (pp_c_expression): Likewise.
6141
d7489d8d 61422010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
6143
6144 * c-common.h (objc_finish_function): New.
6145 (objc_non_volatilized_type): Removed.
6146 (objc_type_quals_match): Removed.
6147 * stub-objc.c (objc_finish_function): New.
6148 (objc_non_volatilized_type): Removed.
6149 (objc_type_quals_match): Removed.
19931eea 6150
92468061 61512010-11-30 Joseph Myers <joseph@codesourcery.com>
6152
6153 * c-common.h (parse_optimize_options): Declare.
6154 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
6155 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
6156
967958e4 61572010-11-29 Joseph Myers <joseph@codesourcery.com>
6158
6159 * c-opts.c (check_deps_environment_vars): Use getenv instead of
6160 GET_ENVIRONMENT.
6161 * c-pch.c (O_BINARY): Don't define here.
6162 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
6163
b213bf24 61642010-11-25 Joseph Myers <joseph@codesourcery.com>
6165
6166 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
6167 targetm.except_unwind_info.
6168
9faf44d6 61692010-11-23 Joseph Myers <joseph@codesourcery.com>
6170
6171 * c-opts.c (c_common_handle_option): Pass location to
6172 set_struct_debug_option.
6173
79396169 61742010-11-23 Joseph Myers <joseph@codesourcery.com>
6175
6176 * c-common.c (visibility_options): Move from ../opts.c.
6177 * c-common.h (struct visibility_flags, visibility_options):
6178 Declare here.
6179 * c-opts.c (finish_options): Rename to c_finish_options.
6180 (c_common_init): Update call to finish_options.
6181
b4aa4123 61822010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
6183
6184 PR objc/34033
6185 * c-lex.c (lex_string): Check that each string in an Objective-C
6186 string concat sequence starts with either one or zero '@', and
6187 that there are no spurious '@' signs at the end.
6188
3e0e49f2 61892010-11-20 Joseph Myers <joseph@codesourcery.com>
6190
6191 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
6192 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
6193 HANDLE_PRAGMA_VISIBILITY.
6194 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
6195 HANDLE_PRAGMA_VISIBILITY): Don't define.
6196 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
6197
a9ffdd35 61982010-11-20 Nathan Froyd <froydnj@codesourcery.com>
6199
6200 PR c++/16189
6201 PR c++/36888
6202 PR c++/45331
6203 * c-common.h (keyword_begins_type_specifier): Declare.
6204 (keyword_is_storage_class_specifier): Declare.
6205 (keyword_is_type_qualifier): Declare.
6206 * c-common.c (keyword_begins_type_specifier): New function.
6207 (keyword_is_storage_class_specifier): New function.
6208 (keyword_is_type_qualifier): Declare.
6209
93be21c0 62102010-11-19 Joseph Myers <joseph@codesourcery.com>
6211
6212 PR c/46547
6213 * c-common.c (in_late_binary_op): Define.
6214 (c_common_truthvalue_conversion): Check in_late_binary_op before
6215 calling c_save_expr.
6216 * c-common.h (in_late_binary_op): Declare.
6217
d7175aef 62182010-11-19 Joseph Myers <joseph@codesourcery.com>
6219
6220 * c-opts.c (c_common_handle_option): Update calls to
6221 set_struct_debug_option.
6222
c213e196 62232010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
6224
6225 * c-common.h (objc_declare_protocols): Added additional argument.
6226 * stub-objc.c (objc_declare_protocol): Same change.
19931eea 6227
0b5fc5d6 62282010-11-18 Nathan Froyd <froydnj@codesourcery.com>
6229
6230 PR c/33193
6231 * c-common.h (build_real_imag_expr): Declare.
6232 * c-semantics.c (build_real_imag_expr): Define.
6233
b8ba44e7 62342010-11-17 Joseph Myers <joseph@codesourcery.com>
6235
6236 * c-opts.c (c_common_parse_file): Take no arguments.
6237 * c-common.h (c_common_parse_file): Update prototype.
6238
6ef8d12f 62392010-11-16 Jakub Jelinek <jakub@redhat.com>
6240
6241 PR c++/46401
6242 * c-common.c (warning_candidate_p): Don't track non-const calls
6243 or STRING_CSTs.
6244
929d2a90 62452010-11-15 Ian Lance Taylor <iant@google.com>
6246
6247 * c-lex.c (init_c_lex): Set macro debug callbacks if
6248 flag_dump_go_spec is set.
6249
e4a7640a 62502010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
6251
6252 * c-common.h (objc_build_incr_expr_for_property_ref): New.
6253 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
6254
597d2d81 62552010-11-15 Nathan Froyd <froydnj@codesourcery.com>
6256
6257 PR preprocessor/45038
6258 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
6259 dialects.
6260
c123f04d 62612010-11-12 Joseph Myers <joseph@codesourcery.com>
6262
6263 * c-common.h (c_family_lang_mask): Declare.
6264 * c-opts.c (c_family_lang_mask): Make extern.
6265 * c-pragma.c (handle_pragma_diagnostic): Use
6266 control_warning_option.
6267
3c6c0e40 62682010-11-12 Joseph Myers <joseph@codesourcery.com>
6269
6270 * c-common.c (parse_optimize_options): Update call to
6271 decode_options.
6272 * c-common.h (c_common_handle_option): Update prototype.
6273 * c-opts.c (c_common_handle_option): Take location_t parameter and
6274 pass it to other functions.
6275
19ec5c9e 62762010-11-11 Joseph Myers <joseph@codesourcery.com>
6277
6278 * c-opts.c (warning_as_error_callback): Remove.
6279 (c_common_initialize_diagnostics): Don't call
6280 register_warning_as_error_callback.
6281 (c_common_handle_option): Handle -Werror=normalized= here.
6282
bf776685 62832010-11-10 Joseph Myers <joseph@codesourcery.com>
6284
6285 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
6286 in diagnostic.
6287 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
6288 letter.
6289 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
6290 Remove trailing '.' from diagnostics.
6291 * c.opt (Wwrite-strings_: Avoid '`' in help text.
6292
6bd9d862 62932010-11-10 Joseph Myers <joseph@codesourcery.com>
6294
6295 * c-common.c (parse_optimize_options): Pass global_dc to
6296 decode_options.
6297 * c-opts.c (c_common_handle_option): Pass &global_options to
6298 set_Wstrict_aliasing.
6299 * c.opt (v): Don't mark Common or document here.
6300
1f6616ee 63012010-11-06 Iain Sandoe <iains@gcc.gnu.org>
6302
6303 PR target/44981
6304 * c-format.c (format_type): New type gcc_objc_string_format_type.
6305 (valid_stringptr_type_p): New.
6306 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
19931eea 6307 (check_format_string): Pass expected type, use
1f6616ee 6308 valid_stringptr_type_p (), check that the format string types are
6309 consistent with the format specification.
6310 (decode_format_attr): Warn if NSString is used outside objective-c.
6311 (format_types_orig): Add NSString.
6312 (format_name): New.
6313 (format_flags): New.
6314 (check_format_arg): Handle format strings requiring an external parser.
6315 first_target_format_type: New variable.
6316 (handle_format_attribute): Set up first_target_format_type, pass the
6317 expected format arg string type to check_format_string().
6318 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
6319 * stub-objc.c (objc_string_ref_type_p): New.
6320 (objc_check_format_arg): New.
6321
b0d0931f 63222010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
6323
19931eea 6324 Fixed using the Objective-C 2.0 dot-syntax with class names.
b0d0931f 6325 * c-common.h (objc_build_class_component_ref): New.
6326 * stub-objc.c (objc_build_class_component_ref): New.
6327
f26877d5 63282010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
6329
6330 * c.opt (Wproperty-assign-default): New option.
6331
1ef143b6 63322010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
6333
6334 Implemented -fobjc-std=objc1 flag.
6335 * c.opt (fobjc-std=objc1): New option.
6336
8c582e4f 63372010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
6338
6339 Implemented format and noreturn attributes for Objective-C methods.
6340 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
6341 attribute for Objective-C methods.
6342
8637f1db 63432010-10-31 Jason Merrill <jason@redhat.com>
6344
6345 * c-common.c (conversion_warning, warn_for_collisions_1): Use
6346 EXPR_LOC_OR_HERE.
6347
9d9f5bb3 63482010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
6349
6350 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
6351 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
6352 (objc_add_property_declaration): Removed arguments for copies and
6353 ivar.
6354 (objc_build_getter_call): Renamed to
6355 objc_maybe_build_component_ref.
6356 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
6357 (objc_is_property_ref): New.
6358 * c-common.c (c_common_reswords): Removed copies and ivar.
6359 * stub-objc.c (objc_add_property_declaration): Removed arguments
6360 for copies and ivar.
6361 (objc_build_getter_call): Renamed to
6362 objc_maybe_build_component_ref.
6363 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
6364 (objc_is_property_ref): New.
19931eea 6365
56f907a0 63662010-10-29 Arnaud Charlet <charlet@adacore.com>
6367 Matthew Gingell <gingell@adacore.com>
6368
6369 * c-ada-spec.c (separate_class_package): New function.
6370 (pp_ada_tree_identifier): Prefix references to C++ classes with the
6371 name of their enclosing package.
6372 (print_ada_declaration): Use separate_class_package.
6373
b5fa273e 63742010-10-27 Jason Merrill <jason@redhat.com>
6375
5290e253 6376 * c-common.c (c_common_reswords): Add __is_literal_type.
6377 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
6378
b5fa273e 6379 * c-common.c (check_case_value): Remove special C++ code.
6380
7590f0e5 63812010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
6382
6383 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
6384 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
6385 and RID_LAST_PATTR.
6386 (objc_add_property_declaration): Added additional arguments.
6387 (objc_property_attribute_kind): Removed.
6388 (objc_set_property_attr): Removed.
6389 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
6390 copy and nonatomic.
6391 * stub-objc.c (objc_add_property_declaration): Added additional
6392 arguments.
6393 (objc_set_property_attr): Removed.
19931eea 6394
1d894bcf 63952010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
6396
6397 * c-common.h (objc_add_property_variable): Renamed to
6398 objc_add_property_declaration. Added location argument.
6399 * stub-objc.c (objc_add_property_variable): Same change.
8204c077 6400
e23bf1fb 64012010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
6402
6403 * c-common.h (objc_maybe_printable_name): New.
6404 * stub-objc.c (objc_maybe_printable_name): New.
6405
92a44a68 64062010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
6407 Andrew Pinski <pinskia@gmail.com>
93426222 6408
6409 * c-common.h (c_common_mark_addressable_vec): Declare.
6410 * c-common.c (c_common_mark_addressable_vec): New function.
6411
45b2b110 64122010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
6413
6414 * c-common.h (objc_set_method_type): Removed.
6415 (objc_add_method_declaration): Added boolean argument.
6416 (objc_start_method_definition): Same change.
6417 (objc_build_method_signature): Same change.
6418 * stub-objc.c (objc_set_method_type): Removed.
6419 (objc_add_method_declaration): Added boolean argument.
6420 (objc_start_method_definition): Same change.
6421 (objc_build_method_signature): Same change.
6422
64cd9619 64232010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
6424
6425 * c-common.h (finish_file): Removed.
6426 (objc_write_global_declarations): New.
6427 * c-opts.c (c_common_parse_file): Do not call finish_file.
6428 * stub-objc.c (objc_write_global_declarations): New.
19931eea 6429
e1f293c0 64302010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
6431
6432 Implemented parsing @synthesize and @dynamic for
6433 Objective-C/Objective-C++.
6434 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
6435 (objc_add_synthesize_declaration): New.
6436 (objc_add_dynamic_declaration): New.
6437 * c-common.c (c_common_reswords): Add synthesize and dynamic.
6438 * stub-objc.c (objc_add_synthesize_declaration): New.
6439 (objc_add_dynamic_declaration): New.
19931eea 6440
ef97a312 64412010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
6442
6443 PR target/46041
6444 * c-cppbuiltin.c (mode_has_fma): Move function here from
6445 builtins.c. Don't use the fma optab, instead just use the
6446 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
6447 using -save-temps.
6448
69b07042 64492010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
6450
6451 Merge from 'apple/trunk' branch on FSF servers.
ef97a312 6452
92a44a68 6453 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
69b07042 6454
19931eea 6455 Radar 4330422
69b07042 6456 * c-common.h (objc_non_volatilized_type): New declaration
6457 * stub-objc.c (objc_non_volatilized_type): New stub.
6458
f15f2e56 64592010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
6460
69b07042 6461 Merge from 'apple/trunk' branch on FSF servers.
f15f2e56 6462
92a44a68 6463 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
f15f2e56 6464
19931eea 6465 Radar 4133425
f15f2e56 6466 * c-common.h (objc_diagnose_private_ivar): New decl.
ef97a312 6467 * stub-objc.c (objc_diagnose_private_ivar): New stub.
f15f2e56 6468
4a8875ed 64692010-10-17 Iain Sandoe <iains@gcc.gnu.org>
6470
6471 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
6472 * c-common.h (enum rid): Add RID_AT_PACKAGE.
6473 (objc_ivar_visibility_kind): New enum.
6474 (objc_set_visibility): Adjust prototype to use visibility enum.
ef97a312 6475 * stub-objc.c (objc_set_visibility): Adjust stub to use
4a8875ed 6476 visibility enum.
6477
7e0713b1 64782010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
6479
6480 * c-cppbuiltin.c (builtin_define_float_constants): Emit
6481 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
6482 has the appropriate fma builtins.
6483 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
6484
86c110ac 64852010-10-14 Iain Sandoe <iains@gcc.gnu.org>
6486
7e0713b1 6487 merge from FSF apple 'trunk' branch.
92a44a68 6488 2006 Fariborz Jahanian <fjahanian@apple.com>
7e0713b1 6489
86c110ac 6490 Radars 4436866, 4505126, 4506903, 4517826
6491 * c-common.c (c_common_resword): Define @property and its attributes.
6492 * c-common.h: Define property attribute enum entries.
6493 (OBJC_IS_PATTR_KEYWORD): New.
6494 (objc_property_attribute_kind): New enum.
6495 Declare objc_set_property_attr (), objc_add_property_variable (),
6496 objc_build_getter_call () and objc_build_setter_call ().
6497 * stub-objc.c (objc_set_property_attr): New stub.
6498 (objc_add_property_variable): Likewise.
6499 (objc_build_getter_call): Likewise.
6500 (objc_build_setter_call) Likewise.
7e0713b1 6501
40c8d1dd 65022010-10-13 Iain Sandoe <iains@gcc.gnu.org>
6503
7e0713b1 6504 merge from FSF apple 'trunk' branch.
92a44a68 6505 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
40c8d1dd 6506
6507 Radar 3803157 (method attributes)
6508 * c-common.c (handle_deprecated_attribute): Recognize
6509 objc methods as valid declarations.
6510 * c-common.h: Declare objc_method_decl ().
7e0713b1 6511 * stub-objc.c (objc_method_decl): New stub.
40c8d1dd 6512
f3f006ad 65132010-10-08 Joseph Myers <joseph@codesourcery.com>
6514
6515 * c-common.c (parse_optimize_options): Call
6516 decode_cmdline_options_to_array_default_mask before
6517 decode_options. Update arguments to decode_options.
6518 * c-common.h (c_common_init_options_struct): Declare.
6519 * c-opts.c (c_common_init_options_struct): New. Split out from
6520 c_common_init_options.
6521
0a65c3bb 65222010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
6523
6524 Implemented fast enumeration for Objective-C.
6525 * c-common.h (objc_finish_foreach_loop): New.
6526 * stub-objc.c (objc_finish_foreach_loop): New.
6527
24ca3b4e 65282010-10-05 Joseph Myers <joseph@codesourcery.com>
6529
6530 * c-common.h (struct diagnostic_context): Don't declare here.
6531 (c_common_initialize_diagnostics): Declare using
6532 diagnostic_context typedef.
6533 * c-opts.c (c_common_handle_option): Pass global_dc to
6534 handle_generated_option.
6535
f83b64ca 65362010-10-04 Joseph Myers <joseph@codesourcery.com>
6537
6538 * c-opts.c (c_common_handle_option): Pass &global_options_set to
6539 handle_generated_option.
6540
2fdec027 65412010-10-03 Ian Lance Taylor <iant@google.com>
6542
6543 * c.opt (-fplan9-extensions): New option.
6544
41acdfa4 65452010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
6546
6547 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
6548 Remove.
6549 (c_cpp_builtins): Call functions from cppbuiltin.c instead
6550 of duplicating code.
6551
069761fb 65522010-09-30 Iain Sandoe <iains@gcc.gnu.org>
6553
6554 * c-common.c: Add two new entries for @optional
6555 and @required keywords.
6556
6557 merge from FSF 'apple/trunk' branch.
92a44a68 6558 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
069761fb 6559
6560 Radar 4386773
6561 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
6562 objective-c keywords.
6563 (objc_set_method_opt): New declaration.
6564 * stub-objc.c (objc_set_method_opt): New stub.
19931eea 6565
2c5d2e39 65662010-09-30 Joseph Myers <joseph@codesourcery.com>
6567
6568 * c-common.c (handle_optimize_attribute): Pass &global_options to
6569 cl_optimization_save and cl_optimization_restore.
6570 * c-opts.c (c_common_handle_option): Pass &global_options to
6571 handle_generated_option.
6572 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
6573 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
6574 &global_options to cl_optimization_restore.
6575
e5c75ac3 65762010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
6577
6578 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
6579 Objective-C/Objective-C++ keywords.
6580
3511333e 65812010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
e147d6aa 6582
19931eea 6583 Merge from 'apple/trunk' branch on FSF servers.
6584
92a44a68 6585 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
e147d6aa 6586
6587 Radar 4281748
6588 * c-common.h (objc_check_global_decl): New declaration.
6589 * stub-objc.c (objc_check_global_decl): New stub.
6590
5461e683 65912010-09-29 Joseph Myers <joseph@codesourcery.com>
6592
6593 * c.opt: Don't use VarExists.
6594
5ae82d58 65952010-09-29 Joseph Myers <joseph@codesourcery.com>
6596
6597 * c-common.c (c_cpp_error): Update names of diagnostic_context
6598 members.
6599 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
6600 cl_optimization members.
6601 * c-opts.c (warning_as_error_callback, c_common_handle_option,
6602 sanitize_cpp_opts, finish_options): Update names of cpp_options
6603 members.
6604
b27e241e 66052010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
6606
6607 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
6608 (objc_is_reserved_word): Removed.
6609 * c-common.c: Updated comments.
6610 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
6611 objc_is_reserved_word.
6612 * stub-objc.c (objc_is_reserved_word): Removed.
6613
03fc2271 66142010-09-28 Iain Sandoe <iains@gcc.gnu.org>
6615
19931eea 6616 * c-common.h (objc_add_method_declaration): Adjust prototype to
03fc2271 6617 include attributes.
6618 (objc_start_method_definition): Likewise.
6619 (objc_build_keyword_decl): Likewise.
6620 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
6621 (objc_start_method_definition): Likewise.
6622 (objc_build_keyword_decl): Likewise.
6623
a336eb4b 66242010-09-28 Iain Sandoe <iains@gcc.gnu.org>
6625
6626 * c-common.h (objc_start_class_interface): Adjust prototype.
6627 (objc_start_category_interface): Likewise.
6628 (objc_start_protocol): Likewise.
6629 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
6630 (objc_start_class_interface): Likewise.
6631 (objc_start_category_interface): Likewise.
6632
48b14f50 66332010-09-27 Ian Lance Taylor <iant@google.com>
6634
6635 * c-common.c (c_common_attribute_table): Add no_split_stack.
6636 (handle_no_split_stack_attribute): New static function.
6637
4abfc532 66382010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
6639
19931eea 6640 Merge from 'apple/trunk' branch on FSF servers.
4abfc532 6641
92a44a68 6642 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
4abfc532 6643
19931eea 6644 Radar 4229905
4abfc532 6645 * c-common.h (objc_have_common_type): New declaration.
6646 * stub-objc.c (objc_have_common_type): New stub.
6647
6648 2005-06-22 Ziemowit Laski <zlaski@apple.com>
6649
6650 Radar 4154928
6651 * c-common.h (objc_common_type): New prototype.
19931eea 6652 * stub-objc.c (objc_common_type): New stub.
4abfc532 6653
7bd95dfd 66542010-09-24 Jan Hubicka <jh@suse.cz>
6655
6656 * c-common.c (handle_leaf_attribute): New function.
6657 (struct attribute_spec c_common_att): Add leaf.
6658
5789e05b 66592010-09-22 Joseph Myers <joseph@codesourcery.com>
6660
6661 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
6662 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
6663 -dump, -dump=, -imacros, -imacros=, -include, -include=,
6664 -include-barrier, -include-directory, -include-directory=,
6665 -include-directory-after, -include-directory-after=,
6666 -include-prefix, -include-prefix=, -include-with-prefix,
6667 -include-with-prefix=, -include-with-prefix-after,
6668 -include-with-prefix-after=, -include-with-prefix-before,
6669 -include-with-prefix-before=, -no-integrated-cpp,
6670 -no-line-commands, -no-standard-includes, -no-warnings, -output,
6671 -output=, -pedantic, -pedantic-errors, -preprocess,
6672 -print-missing-file-dependencies, -trace-includes, -traditional,
6673 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
6674 -user-dependencies, -verbose, -write-dependencies,
6675 -write-user-dependencies, no-integrated-cpp, traditional): New.
6676
e6fb54ba 66772010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
6678
6679 PR objc/23710
9b60f3b0 6680 * c-common.h (objc_start_method_definition): Return bool instead
6681 of void.
6682 * stub-objc.c (objc_start_method_definition): Return bool instead
6683 of void.
6684
66852010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
6686
6687 PR objc/25965
6688 * c-common.h (objc_get_interface_ivars): New declaration.
6689 * stub-objc.c (objc_get_interface_ivars): New stub.
e6fb54ba 6690
e44b0a1f 66912010-09-15 Ian Lance Taylor <iant@google.com>
6692
6693 * c-common.c (parse_optimize_options): Do not capitalize warning
ebd7c4c1 6694 messages. Remove period at end of warning message.
e44b0a1f 6695
85c0a25c 66962010-09-09 Nathan Sidwell <nathan@codesourcery.com>
6697
6698 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
6699 (handle_alias_attribute): ... here.
6700 (handle_ifunc_attribute): New.
6701
5ba33bf4 67022010-09-06 Mark Mitchell <mark@codesourcery.com>
6703
6704 * c-common.h (do_warn_double_promotion): Declare.
6705 * c-common.c (do_warn_double_promotion): Define.
6706
c920faa3 67072010-09-05 Mark Mitchell <mark@codesourcery.com>
6708
6709 * c.opt (Wdouble-promotion): New.
6710
9604e070 67112010-09-02 Joseph Myers <joseph@codesourcery.com>
6712
6713 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
6714 fvtable-thunks, fxref): Mark no longer supported in help text.
6715
3b0273a1 67162010-09-02 Joseph Myers <joseph@codesourcery.com>
6717
6718 * c.opt (Wimport, fall-virtual, falt-external-templates,
6719 fdefault-inline, fenum-int-equiv, fexternal-templates,
6720 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
6721 fname-mangling-version-, fnew-abi, fnonnull-objects,
6722 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
6723 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
6724 applicable.
6725 (fhandle-exceptions): Mark with Alias and Warn.
6726 * c-opts.c (c_common_handle_option): Don't handle options marked
6727 as ignored.
6728
67089c6b 67292010-09-02 Joseph Myers <joseph@codesourcery.com>
6730
6731 * c.opt (Wcomments, Werror-implicit-function-declaration,
6732 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
6733 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
6734 aliases.
6735 * c-common.c (option_codes): Use OPT_Wcomment instead of
6736 OPT_Wcomments.
6737 * c-opts.c (warning_as_error_callback, c_common_handle_option):
6738 Don't handle options marked as aliases.
6739
2af087f2 67402010-08-25 Richard Guenther <rguenther@suse.de>
6741
6742 * c-common.c (c_common_get_alias_set): Remove special
6743 handling for pointers.
6744
48148244 67452010-08-20 Nathan Froyd <froydnj@codesourcery.com>
6746
6747 * c-common.c: Use FOR_EACH_VEC_ELT.
6748 * c-gimplify.c: Likewise.
6749 * c-pragma.c: Likewise.
6750
89c69892 67512010-08-16 Joseph Myers <joseph@codesourcery.com>
6752
6753 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
6754 RejectDriver.
6755 (MMDX): Change back to MMD. Mark NoDriverArg instead of
6756 RejectDriver.
6757 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
6758 instead of OPT_MDX and OPT_MMDX.
6759
e28aa114 67602010-08-16 Joseph Myers <joseph@codesourcery.com>
6761
6762 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
6763
99b66d21 67642010-08-12 Joseph Myers <joseph@codesourcery.com>
6765
6766 * c.opt (MD, MMD): Change to MDX and MMDX.
6767 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
6768
666f4bf0 67692010-08-11 Joseph Myers <joseph@codesourcery.com>
6770
6771 * c-opts.c (c_common_handle_option): Call handle_generated_option
6772 instead of handle_option.
6773
5ec815f6 67742010-08-08 Nathan Froyd <froydnj@codesourcery.com>
6775
6776 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
6777 (maybe_apply_renaming_pragma): Delete unneeded declarations.
6778
d13143cf 67792010-08-08 Nathan Froyd <froydnj@codesourcery.com>
6780
6781 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
6782 (pending_redefine_extname): Change type to a VEC.
6783 (add_to_renaming_pragma_list): Update for new type of
6784 pending_redefine_extname.
5ec815f6 6785 (maybe_apply_renaming_pragma): Likewise.
d13143cf 6786
2008c983 67872010-08-04 Arnaud Charlet <charlet@adacore.com>
6788
6789 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
6790 visited.
6791 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
6792 decide whether a type has already been declared/seen.
6793 Do not go to the original type.
6794 (dump_nested_types): New parameter forward.
6795 Generate forward declaration if needed and mark type as visited.
6796 (print_ada_declaration): Call dump_nested_types if not already done.
6797 Mark types as visited.
6798
9b091a73 67992010-08-03 Joseph Myers <joseph@codesourcery.com>
6800
6801 * c.opt (-print-pch-checksum): Remove option.
6802 * c-opts.c (c_common_handle_option): Don't handle
6803 OPT_print_pch_checksum.
6804
b78351e5 68052010-07-27 Joseph Myers <joseph@codesourcery.com>
6806
6807 * c-common.h (c_common_handle_option): Update prototype and return
6808 value type.
6809 * c-opts.c (c_common_handle_option): Update prototype and return
6810 value type. Update calls to handle_option and
6811 enable_warning_as_error.
6812
34416a90 68132010-07-27 Jakub Jelinek <jakub@redhat.com>
6814
6815 PR c/45079
6816 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
6817
fecf9011 68182010-07-27 Joseph Myers <joseph@codesourcery.com>
6819
6820 * c-common.h (c_common_missing_argument): Remove.
6821 * c-opts.c (c_common_missing_argument): Remove.
6822 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
6823 idirafter, imacros, include, isysroot, isystem, iquote): Add
6824 MissingArgError.
6825 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
6826
e88d34f6 68272010-07-27 Joseph Myers <joseph@codesourcery.com>
6828
6829 * c-common.h (c_common_option_lang_mask,
6830 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
6831 New.
6832 (c_common_init_options): Update prototype.
6833 * c-opts.c (c_common_option_lang_mask): New.
6834 (c_common_initialize_diagnostics): Split out of
6835 c_common_init_options.
6836 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
6837 New.
6838 (c_common_init_options): Update prototype. Use decoded options in
6839 search for -lang-asm.
6840
1767a056 68412010-07-15 Nathan Froyd <froydnj@codesourcery.com>
6842
6843 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
6844 * c-format.c: Likewise.
6845
0b205f4c 68462010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
6847
6848 * c-common.h: Include diagnostic-core.h. Error if already
6849 included.
6850 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
6851
1c58e3f1 68522010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
6853
1f78217c 6854 * c-common.c (IN_GCC_FRONTEND): Do not undef.
1c58e3f1 6855 Do not include expr.h
6856 (vector_mode_valid_p): Move here.
6857
33cc157c 68582010-06-21 DJ Delorie <dj@redhat.com>
6859
6860 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
6861 allow these pragmas anywhere.
6862
68632010-06-14 Jakub Jelinek <jakub@redhat.com>
6864
6865 PR bootstrap/44509
6866 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
6867 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
6868 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
6869 ggc_strdup instead of xstrdup.
6870
68712010-06-10 Jakub Jelinek <jakub@redhat.com>
6872
6873 * c-cppbuiltin.c: Include cpp-id-data.h.
6874 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
6875 (lazy_hex_fp_value): New function.
6876 (builtin_define_with_hex_fp_value): Provide definitions lazily.
6877
9b40bfbf 68782010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
6879
6880 * c-gimplify.c: Do not include tree-flow.h
6881
202d6e5f 68822010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
6883
6884 PR other/44034
6885 * c-common.c: Rename targetm member:
6886 targetm.enum_va_list -> targetm.enum_va_list_p
6887
d3237426 68882010-06-28 Anatoly Sokolov <aesok@post.ru>
6889
6890 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
6891
596981c8 68922010-06-28 Steven Bosscher <steven@gcc.gnu.org>
6893
6894 * c-cppbuiltin.c: Do not include except.h.
6895
b9bdfa0b 68962010-06-24 Andi Kleen <ak@linux.intel.com>
6897
19931eea 6898 * c-common.c (warn_for_omitted_condop): New.
6899 * c-common.h (warn_for_omitted_condop): Add prototype.
b9bdfa0b 6900
55ad092d 69012010-06-21 Joseph Myers <joseph@codesourcery.com>
6902
6903 * c.opt (lang-objc): Remove.
6904 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
6905
9e7c2572 69062010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
6907
6908 * c-opts.c: Include "tm_p.h".
6909
615ef0bb 69102010-06-20 Joseph Myers <joseph@codesourcery.com>
6911
6912 * c-common.c (parse_optimize_options): Update call to
6913 decode_options.
6914
aef48c9a 69152010-06-18 Nathan Froyd <froydnj@codesourcery.com>
6916
6917 * c-common.c (record_types_used_by_current_var_decl): Adjust for
6918 new type of types_used_by_cur_var_decl.
6919
d74003b4 69202010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
6921
6922 PR bootstrap/44512
6923 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
6924 for C++ standard compliance.
6925
1194d077 69262010-06-16 Jason Merrill <jason@redhat.com>
6927
6928 * c.opt: Add -Wnoexcept.
6929
d473d901 69302010-06-16 Richard Guenther <rguenther@suse.de>
6931
6932 PR c/44555
6933 * c-common.c (c_common_truthvalue_conversion): Remove
6934 premature and wrong optimization concering ADDR_EXPRs.
6935
b62dbfd3 69362010-06-15 Arnaud Charlet <charlet@adacore.com>
6937
6938 * c-ada-spec.c (dump_sloc): Remove column info.
6939 (is_simple_enum): New function.
6940 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
6941 enum types when relevant.
6942
200dd99c 69432010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
6944
19931eea 6945 * c-common.c (conversion_warning): Warn at expression
200dd99c 6946 location.
6947
abf6a617 69482010-06-10 Joseph Myers <joseph@codesourcery.com>
6949
6950 * c-opts.c (c_common_handle_option): Don't handle
6951 OPT_fshow_column.
6952
ba72912a 69532010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
6954
6955 * c-pragma.c (push_alignment): Use typed GC allocation.
6956 (handle_pragma_push_options): Likewise.
6957
6958 * c-common.c (parse_optimize_options): Likewise.
6959
6960 * c-common.h (struct sorted_fields_type): Add variable_size GTY
6961 option.
6962
4aafe913 69632010-06-07 Joseph Myers <joseph@codesourcery.com>
6964
6965 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
6966 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
6967 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
6968 flag_signed_bitfields, warn_strict_null_sentinel,
6969 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
6970 flag_gen_declaration, flag_no_gnu_keywords,
6971 flag_implement_inlines, flag_implicit_templates,
6972 flag_implicit_inline_templates, flag_optional_diags,
6973 flag_elide_constructors, flag_default_inline, flag_rtti,
6974 flag_conserve_space, flag_access_control, flag_check_new,
6975 flag_new_for_scope, flag_weak, flag_working_directory,
6976 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
6977 flag_enforce_eh_specs, flag_threadsafe_statics,
6978 flag_pretty_templates): Remove.
6979 * c-common.h (flag_preprocess_only, flag_nil_receivers,
6980 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
6981 flag_replace_objc_classes, flag_undef, flag_no_builtin,
6982 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
6983 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
6984 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
6985 flag_no_gnu_keywords, flag_implement_inlines,
6986 flag_implicit_templates, flag_implicit_inline_templates,
6987 flag_optional_diags, flag_elide_constructors, flag_default_inline,
6988 flag_rtti, flag_conserve_space, flag_access_control,
6989 flag_check_new, flag_new_for_scope, flag_weak,
6990 flag_working_directory, flag_use_cxa_atexit,
6991 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
6992 flag_threadsafe_statics, flag_pretty_templates,
6993 warn_strict_null_sentinel): Remove.
6994 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
6995 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
6996 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
6997 fimplicit-inline-templates, fimplicit-templates,
6998 flax-vector-conversions, fms-extensions, fnil-receivers,
6999 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
7000 frtti, fshort-double, fshort-enums, fshort-wchar,
7001 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
7002 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
7003 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
7004 gen-decls, undef): Use Var.
7005 (fdefault-inline, foptional-diags): Document as doing nothing.
7006 * c-opts.c (c_common_handle_option): Remove cases for options now
7007 using Var. Mark ignored options as such.
7008
7bedc3a0 70092010-06-05 Steven Bosscher <steven@gcc.gnu.org>
7010
19931eea 7011 * c-common.c: Moved to here from parent directory.
7bedc3a0 7012 * c-common.def: Likewise.
7013 * c-common.h: Likewise.
7014 * c-cppbuiltin.c: Likewise.
7015 * c-dump.c: Likewise.
7016 * c-format.c: Likewise.
7017 * c-format.h : Likewise.
7018 * c-gimplify.c: Likewise.
7019 * c-lex.c: Likewise.
7020 * c-omp.c: Likewise.
7021 * c.opt: Likewise.
7022 * c-opts.c: Likewise.
7023 * c-pch.c: Likewise.
7024 * c-ppoutput.c: Likewise.
7025 * c-pragma.c: Likewise.
7026 * c-pragma.h: Likewise.
7027 * c-pretty-print.c: Likewise.
7028 * c-pretty-print.h: Likewise.
7029 * c-semantics.c: Likewise.
7030 * stub-objc.c: Likewise.
7031
7032 * c-common.c: Include gt-c-family-c-common.h.
7033 * c-pragma.c: Include gt-c-family-c-pragma.h.
7034\f
f1717362 7035Copyright (C) 2010-2016 Free Software Foundation, Inc.
7bedc3a0 7036
7037Copying and distribution of this file, with or without modification,
7038are permitted in any medium without royalty provided the copyright
7039notice and this notice are preserved.