]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c-family/ChangeLog
builtin-sprintf-warn-1.c: Adjust regex to accept singular form of byte when quantity...
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
CommitLineData
c6147dc4
MP
12016-09-26 Marek Polacek <polacek@redhat.com>
2
3 * c-lex.c (c_common_has_attribute): Handle attribute fallthrough.
4
81fea426
MP
52016-09-26 Marek Polacek <polacek@redhat.com>
6
7 PR c/7652
8 * c-common.c (c_common_attribute_table): Add fallthrough attribute.
9 (handle_fallthrough_attribute): New function.
10 (attribute_fallthrough_p): New function.
11 * c-common.h (attribute_fallthrough_p): Declare.
12
9a2300e9
MP
132016-09-24 Marek Polacek <polacek@redhat.com>
14
15 PR c/77490
16 * c.opt (Wbool-operation): New.
17
a09e9e35
BE
182016-09-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
19
20 * c-common.c (c_common_truthvalue_conversion): Inhibit
21 Wint-in-bool-context warning with from_macro_definition_at.
22 Mention the expression will always evaluate to true.
23
d43b4ccc
MS
242016-09-21 Martin Sebor <msebor@redhat.com>
25
26 PR bootstrap/77676
27 * c.opt (fprintf-return-value): Temporarily initialize to zero
28 to unblock bootstrap failures.
29
2e1c20b1
JJ
302016-09-21 Jakub Jelinek <jakub@redhat.com>
31
32 PR c++/77651
33 * c.opt (Waligned-new=): Add RejectNegative.
34 (faligned-new=): Likewise. Spelling fix - change
35 aligned_new_threshhold to aligned_new_threshold.
36 * c-cppbuiltin.c (c_cpp_builtins): Change aligned_new_threshhold
37 to aligned_new_threshold.
38
88d0c3f0
MS
392016-09-20 Martin Sebor <msebor@redhat.com>
40
41 PR middle-end/49905
42 * c.opt: Add -Wformat-length and -fprintf-return-value.
43
144a96e4
BE
442016-09-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
45
46 PR c++/77434
47 * c.opt (Wint-in-bool-context): New warning.
48 * c-common.c (c_common_truthvalue_conversion): Warn on integer
49 constants in boolean context.
50
63012d9a
JM
512016-09-19 Joseph Myers <joseph@codesourcery.com>
52
53 * c-common.c (max_align_t_align): Also consider alignment of
54 float128_type_node.
55
931388ce
JM
562016-09-15 Jason Merrill <jason@redhat.com>
57
58 * c-common.c (check_cxx_fundamental_alignment_constraints): Check
59 DECL_EXTERNAL.
60
38711381
JM
612016-09-14 Jason Merrill <jason@redhat.com>
62
63 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
64 limit FIELD_DECL, either.
65
e51fbec3
MP
662016-09-14 Marek Polacek <polacek@redhat.com>
67
68 * c-common.c (c_common_truthvalue_conversion): Use false instead of 0.
69 * c-common.h (build_unary_op): Change nonconvert parameter type to bool.
70 * c-omp.c (c_finish_omp_atomic): Use false instead of 0.
71
254830ba
DM
722016-09-13 David Malcolm <dmalcolm@redhat.com>
73
74 * c-common.c (warn_logical_not_parentheses): Replace
75 rich_location::add_fixit_insert calls with add_fixit_insert_before
76 and add_fixit_insert_after, eliminating the "next_loc" calculation.
77
42763690
JM
782016-09-13 Jason Merrill <jason@redhat.com>
79 Tom de Vries <tom@codesourcery.com>
80
81 PR c++/77427
82 * c-common.c (set_underlying_type): Don't treat array as builtin type.
83
9453eee9
JM
842016-09-13 Jason Merrill <jason@redhat.com>
85
86 * c-common.c (check_cxx_fundamental_alignment_constraints): Don't
87 limit types at all.
88
e96809e3
JM
892016-09-12 Jason Merrill <jason@redhat.com>
90
91 * c-common.c (check_cxx_fundamental_alignment_constraints): Fix
92 bit/byte confusion, allow large alignment for types.
93
54dcdb88
BE
942016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
95
96 PR c++/77496
97 * c-common.c (warn_for_omitted_condop): Also warn for boolean data.
98
d1463eb9
DM
992016-09-12 David Malcolm <dmalcolm@redhat.com>
100
101 PR c/72858
102 * c-format.c (argument_parser::check_argument_type): Add params
103 "type_start" and "conversion_char". Use the former to generate
104 offset_to_type_start and pass it and conversion_char to
105 check_format_types.
106 (check_format_info_main): Capture the start of the type
107 information as "type_start", and pass it an format_char
108 to arg_parser.check_argument_type.
109 (check_format_types): Provide an example in the leading comment.
110 Add params "offset_to_type_start" and "conversion_char"; pass
111 them to format_type_warning calls.
112 (test_get_modifier_for_format_len): Likewise.
113 (matching_type_p): New function.
114 (get_format_for_type): Add param "conversion_char" and move
115 implementation into...
116 (get_format_for_type_1): ...new function, called twice.
117 Use new function matching_type_p rather than checking for
118 TYPE_CANONICAL equality.
119 (get_corrected_substring): New function.
120 (format_type_warning): Provide an example in the leading comment.
121 Add params "offset_to_type_start" and "conversion_char". Replace
122 call to get_format_for_type with call to get_corrected_substring
123 and move rejection of hints for widths/precisions there.
124 (assert_format_for_type_streq): Add param "conversion_char".
125 (ASSERT_FORMAT_FOR_TYPE_STREQ): Add param CONVERSION_CHAR.
126 (test_get_format_for_type_printf): Add conversion chars to the
127 tests, adding coverage for various combinations of integer
128 vs double conversions, and for preserving octal and hexadecimal
129 conversions.
130 (test_get_format_for_type_scanf): Add conversion chars to the
131 tests.
132
5b28efbb
TV
1332016-09-10 Tom de Vries <tom@codesourcery.com>
134
135 PR C/71602
136 * c-common.c (build_va_arg): Handle more strict
137 targetm.canonical_va_list_type. Replace first argument type error with
138 assert.
139
3f0177e7
MS
1402016-09-09 Martin Sebor <msebor@redhat.com>
141
142 PR c/77520
143 PR c/77521
144 * c-format.c (argument_parser::find_format_char_info): Use %qc
145 format directive unconditionally.
146
af63ba4b
JM
1472016-09-09 Jason Merrill <jason@redhat.com>
148
149 Implement C++17 new of over-aligned types.
150 * c.opt: Add -faligned-new and -Waligned-new.
151 * c-common.c (max_align_t_align): Split out from...
152 (cxx_fundamental_alignment_p): ...here.
153 * c-common.h: Declare it.
154 * c-cppbuiltin.c (c_cpp_builtins): Handle aligned new.
155
c65248cb
JM
1562016-09-09 Joseph Myers <joseph@codesourcery.com>
157
158 * c-cppbuiltin.c (builtin_define_type_width): New function.
159 (builtin_define_stdint_macros, c_cpp_builtins): Define type width
160 macros.
161
e5106e27
DM
1622016-09-07 David Malcolm <dmalcolm@redhat.com>
163
164 * c-common.c (get_cpp_ttype_from_string_type): Handle being passed
165 a POINTER_TYPE.
166 (substring_loc::get_location): Move to substring-locations.c,
167 keeping implementation as...
168 (c_get_substring_location): New function, from the above, reworked
169 to use accessors rather than member lookup.
170 * c-common.h (class substring_loc): Move to substring-locations.h,
171 replacing with a forward decl.
172 (c_get_substring_location): New decl.
173 * c-format.c: Include "substring-locations.h".
174 (format_warning_va): Move to substring-locations.c.
175 (format_warning_at_substring): Likewise.
176
a42e7952
MS
1772016-09-06 Martin Sebor <msebor@redhat.com>
178
179 PR c/77336
180 * c-format.c (check_function_format): Avoid issuing warnings for
181 functions unless they call format functions with non-constant
182 format strings.
183
b772a565
RB
1842016-09-06 Richard Biener <rguenther@suse.de>
185
186 PR c/77450
187 * c-common.c (c_common_mark_addressable_vec): Handle
188 COMPOUND_LITERAL_EXPR.
189
25ff5dd3
MP
1902016-09-05 Marek Polacek <polacek@redhat.com>
191
192 PR c/77423
193 * c-common.c (bool_promoted_to_int_p): New function.
194 (expr_has_boolean_operands_p): New function.
195 (warn_logical_not_parentheses): Return if expr_has_boolean_operands_p.
196 (maybe_warn_bool_compare): Use bool_promoted_to_int_p.
197
21234eb5
TV
1982016-09-04 Tom de Vries <tom@codesourcery.com>
199
200 revert:
201 2016-08-29 Tom de Vries <tom@codesourcery.com>
202
203 * c-common.c (build_va_arg): Replace first argument type error
204 with assert.
205
9dc5773f
JJ
2062016-09-02 Jakub Jelinek <jakub@redhat.com>
207
208 PR c/65467
209 * c-omp.c (c_finish_omp_atomic): Reject _Atomic qualified expressions.
210 (c_finish_omp_for): Reject _Atomic qualified iterators.
211
2122016-09-01 Martin Sebor <msebor@redhat.com>
3d7b83b6
MS
213
214 * c-ada-spec.c (dump_ada_function_declaration): Increase buffer
215 size to guarantee it fits the output of the formatted function
216 regardless of its arguments.
217
295844f6
MP
2182016-09-01 Marek Polacek <polacek@redhat.com>
219
220 PR c/7652
221 * c-common.c (resolve_overloaded_builtin): Fix formatting. Add
222 FALLTHRU comments.
223
3d06b6f2
MP
2242016-08-29 Marek Polacek <polacek@redhat.com>
225
226 PR c/77292
227 * c-common.c (warn_logical_not_parentheses): Don't warn for
228 a comparison or a logical operator.
229
34cedad5
TV
2302016-08-29 Tom de Vries <tom@codesourcery.com>
231
232 * c-common.c (build_va_arg): Fix type comparison assert.
233
f162d717
TV
2342016-08-29 Tom de Vries <tom@codesourcery.com>
235
236 * c-common.c (build_va_arg): Replace first argument type error
237 with assert.
238
ba9bbd6f
TV
2392016-08-29 Tom de Vries <tom@codesourcery.com>
240
241 PR c/77398
242 * c-common.c (build_va_arg): Add first argument error. Build va_arg
243 with error_mark_node as va_list instead of with illegal va_list.
244
ebef225f
MP
2452016-08-25 Marek Polacek <polacek@redhat.com>
246 David Malcolm <dmalcolm@redhat.com>
247
248 * c-common.c (warn_logical_not_parentheses): Print fixit hints.
249 * c-common.h (warn_logical_not_parentheses): Update declaration.
250
b00e6e75
MP
2512016-08-22 Marek Polacek <polacek@redhat.com>
252
253 PR c++/77321
254 * c-common.c (warn_for_memset): Check type for null.
255
6dc198e3
JM
2562016-08-22 Joseph Myers <joseph@codesourcery.com>
257
258 * c-family/c-cppbuiltin.c (c_cpp_builtins): Check _FloatN and
259 _FloatNx types for suffixes for built-in functions.
260
c65699ef
JM
2612016-08-19 Joseph Myers <joseph@codesourcery.com>
262
263 PR c/32187
264 * c-common.h (RID_FLOAT16, RID_FLOATN_NX_FIRST, RID_FLOAT32)
265 (RID_FLOAT64, RID_FLOAT128, RID_FLOAT32X, RID_FLOAT64X)
266 (RID_FLOAT128X): New enum rid values.
267 (CASE_RID_FLOATN_NX): New macro.
268 * c-common.c (c_common_reswords): Add _FloatN and _FloatNx
269 keywords.
270 (c_common_type_for_mode): Check for _FloatN and _FloatNx and
271 corresponding complex types.
272 (c_common_nodes_and_builtins): For non-C++, register _FloatN and
273 _FloatNx and corresponding complex types.
274 (keyword_begins_type_specifier): Use CASE_RID_FLOATN_NX.
275 * c-cppbuiltin.c (builtin_define_float_constants): Check _FloatN
276 and _FloatNx types for the widest type for determining
277 DECIMAL_DIG. Define __LDBL_DECIMAL_DIG__ as well as
278 __DECIMAL_DIG__ for long double. Handle FMA_SUFFIX being NULL.
279 (c_cpp_builtins): Call builtin_define_float_constants for _FloatN
280 and _FloatNx types.
281 * c-lex.c (interpret_float): Handle _FloatN and _FloatNx
282 constants.
283 * c-pretty-print.c (pp_c_floating_constant): Handle _FloatN and
284 _FloatNx types.
285
cc015f3a
DM
2862016-08-18 David Malcolm <dmalcolm@redhat.com>
287
288 * c-opts.c (c_diagnostic_finalizer): Update for change to
289 diagnostic_show_locus.
290
cb18fd07
DM
2912016-08-18 David Malcolm <dmalcolm@redhat.com>
292
293 * c-common.c: Include "spellcheck.h".
294 (cb_get_suggestion): New function.
295 * c-common.h (cb_get_suggestion): New decl.
296 * c-lex.c (init_c_lex): Initialize cb->get_suggestion to
297 cb_get_suggestion.
298
a76989dc
MP
2992016-08-18 Marek Polacek <polacek@redhat.com>
300
301 PR c/71514
302 * c-common.c (get_atomic_generic_size): Disallow pointer-to-function
303 and pointer-to-VLA.
304
65e736c0
DM
3052016-08-16 David Malcolm <dmalcolm@redhat.com>
306
307 PR c/72857
308 * c-common.c (substring_loc::get_range): Rename to...
309 (substring_loc::get_location): ...this, converting param from a
310 source_range * to a location_t *. Call
311 get_source_location_for_substring rather than
312 get_source_range_for_substring, and pass in m_caret_idx.
313 * c-common.h (substring_loc::substring_loc): Add param "caret_idx".
314 (substring_loc::get_range): Replace with...
315 (substring_loc::get_location): ...this.
316 (substring_loc::set_caret_index): New method.
317 (substring_loc): Add field m_caret_idx.
318 * c-format.c (format_warning_va): Update for above changes.
319 Rename local "substring_loc" to "fmt_substring_loc" to avoid
320 clashing with type name.
321 (format_warning_at_char): Add caret_idx param to substring_loc ctor.
322 (check_argument_type): Likewise.
323 (format_type_warning): Rename param "fmt_loc" to "whole_fmt_loc"
324 Use a copy when emitting warnings, setting the caret index from TYPE.
325
7e1dde14
EB
3262016-08-16 Eric Botcazou <ebotcazou@adacore.com>
327 Arnaud Charlet <charlet@adacore.com>
328
329 * c-ada-spec.c (dump_number): New function.
330 (handle_escape_character): Likewise.
331 (print_ada_macros): Add handling of constant integers and strings.
332
191816a3
MP
3332016-08-12 Marek Polacek <polacek@redhat.com>
334
335 PR c/7652
336 * c-common.c (scalar_to_vector): Adjust fall through comment.
337 * c-opts.c (c_common_handle_option): Likewise.
338 * c-pragma.c (handle_pragma_pack): Add FALLTHRU.
339 * c-pretty-print.c (c_pretty_printer::postfix_expression): Adjust
340 fall through comment.
341 * cilk.c (extract_free_variables): Add FALLTHRU.
342
452df4a4
JM
3432016-08-10 Jason Merrill <jason@redhat.com>
344
345 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_if_constexpr.
346
f3365c12
JM
3472016-08-09 Jason Merrill <jason@redhat.com>
348
349 * c-common.c (c_common_attribute_table): vector_size affects type
350 identity.
351
f0bc3323
MP
3522016-08-09 Marek Polacek <polacek@redhat.com>
353
354 PR c/7652
355 * c-ada-spec.c (dump_generic_ada_node): Add return.
356
98e5a19a
JM
3572016-08-09 Jason Merrill <jason@redhat.com>
358
359 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_constexpr for
360 C++17 constexpr lambdas.
361
895aa8e1
DM
3622016-08-08 David Malcolm <dmalcolm@redhat.com>
363
364 PR c/64955
365 * c-common.h (selftest::c_format_c_tests): New declaration.
366 (selftest::run_c_tests): New declaration.
367 * c-format.c: Include "selftest.h.
368 (format_warning_va): Add param "corrected_substring" and use
369 it to add a replacement fix-it hint.
370 (format_warning_at_substring): Likewise.
371 (format_warning_at_char): Update for new param of
372 format_warning_va.
373 (argument_parser::check_argument_type): Pass "fki" to
374 check_format_types.
375 (check_format_types): Add param "fki" and pass it to
376 format_type_warning.
377 (deref_n_times): New function.
378 (get_modifier_for_format_len): New function.
379 (selftest::test_get_modifier_for_format_len): New function.
380 (get_format_for_type): New function.
381 (format_type_warning): Add param "fki" and use it to attempt
382 to provide hints for argument types when calling
383 format_warning_at_substring.
384 (selftest::get_info): New function.
385 (selftest::assert_format_for_type_streq): New function.
386 (ASSERT_FORMAT_FOR_TYPE_STREQ): New macro.
387 (selftest::test_get_format_for_type_printf): New function.
388 (selftest::test_get_format_for_type_scanf): New function.
389 (selftest::c_format_c_tests): New function.
390
e52ed3fe
DM
3912016-08-08 David Malcolm <dmalcolm@redhat.com>
392
393 PR c/52952
394 * c-format.c: Include "diagnostic.h".
395 (location_column_from_byte_offset): Delete.
396 (location_from_offset): Delete.
397 (format_warning_va): New function.
398 (format_warning_at_substring): New function.
399 (format_warning_at_char): New function.
400 (check_format_arg): Capture location of format_tree and pass to
401 check_format_info_main.
402 (argument_parser): Add fields "start_of_this_format" and
403 "format_string_cst".
404 (flag_chars_t::validate): Add param "format_string_cst". Convert
405 warning_at call using location_from_offset to call to
406 format_warning_at_char.
407 (argument_parser::argument_parser): Add param "format_string_cst_"
408 and use use it to initialize field "format_string_cst".
409 Initialize new field "start_of_this_format".
410 (argument_parser::read_format_flags): Convert warning_at call
411 using location_from_offset to a call to format_warning_at_char.
412 (argument_parser::read_any_format_left_precision): Likewise.
413 (argument_parser::read_any_format_precision): Likewise.
414 (argument_parser::read_any_other_modifier): Likewise.
415 (argument_parser::find_format_char_info): Likewise, in three places.
416 (argument_parser::parse_any_scan_set): Likewise, in one place.
417 (argument_parser::handle_conversions): Likewise, in two places.
418 (argument_parser::check_argument_type): Add param "fmt_param_loc"
419 and use it to make a substring_loc. Pass the latter to
420 check_format_types.
421 (check_format_info_main): Add params "fmt_param_loc" and
422 "format_string_cst". Convert warning_at calls using
423 location_from_offset to calls to format_warning_at_char. Pass the
424 new params to the arg_parser ctor. Pass "format_string_cst" to
425 flag_chars.validate. Pass "fmt_param_loc" to
426 arg_parser.check_argument_type.
427 (check_format_types): Convert first param from a location_t
428 to a const substring_loc & and rename to "fmt_loc". Attempt
429 to extract the range of the relevant parameter and pass it
430 to format_type_warning.
431 (format_type_warning): Convert first param from a location_t
432 to a const substring_loc & and rename to "fmt_loc". Add
433 params "param_range" and "type". Replace calls to warning_at
434 with calls to format_warning_at_substring.
435
1c4d457e
DM
4362016-08-08 David Malcolm <dmalcolm@redhat.com>
437
438 * c-format.c (class flag_chars_t): New class.
439 (struct length_modifier): New struct.
440 (class argument_parser): New class.
441 (flag_chars_t::flag_chars_t): New ctor.
442 (flag_chars_t::has_char_p): New method.
443 (flag_chars_t::add_char): New method.
444 (flag_chars_t::validate): New method.
445 (flag_chars_t::get_alloc_flag): New method.
446 (flag_chars_t::assignment_suppression_p): New method.
447 (argument_parser::argument_parser): New ctor.
448 (argument_parser::read_any_dollar): New method.
449 (argument_parser::read_format_flags): New method.
450 (argument_parser::read_any_format_width): New method.
451 (argument_parser::read_any_format_left_precision): New method.
452 (argument_parser::read_any_format_precision): New method.
453 (argument_parser::handle_alloc_chars): New method.
454 (argument_parser::read_any_length_modifier): New method.
455 (argument_parser::read_any_other_modifier): New method.
456 (argument_parser::find_format_char_info): New method.
457 (argument_parser::validate_flag_pairs): New method.
458 (argument_parser::give_y2k_warnings): New method.
459 (argument_parser::parse_any_scan_set): New method.
460 (argument_parser::handle_conversions): New method.
461 (argument_parser::check_argument_type): New method.
462 (check_format_info_main): Introduce classes argument_parser
463 and flag_chars_t, moving the code within the loop into methods
464 of these classes. Make various locals "const".
465
88fa5555
DM
4662016-08-05 David Malcolm <dmalcolm@redhat.com>
467
468 * c-common.c: Include "substring-locations.h".
469 (get_cpp_ttype_from_string_type): New function.
470 (g_string_concat_db): New global.
471 (substring_loc::get_range): New method.
472 * c-common.h (g_string_concat_db): New declaration.
473 (class substring_loc): New class.
474 * c-lex.c (lex_string): When concatenating strings, capture the
475 locations of all tokens using a new obstack, and record the
476 concatenation locations within g_string_concat_db.
477 * c-opts.c (c_common_init_options): Construct g_string_concat_db
478 on the ggc-heap.
479
78169471
MP
4802016-07-29 Marek Polacek <polacek@redhat.com>
481
638fc14f
MP
482 PR c/71926
483 * c-common.c (c_common_truthvalue_conversion): Use LOCATION for the
484 parentheses warning.
485
78169471
MP
486 PR c/71574
487 * c-common.c (handle_alloc_align_attribute): Also check FUNCTION_DECL.
488
1225d6b1
ML
4892016-07-28 Martin Liska <mliska@suse.cz>
490
491 PR gcov-profile/68025
492 * c-common.c (handle_no_profile_instrument_function_attribute):
493
ec1e2a40
BE
4942016-07-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
495
496 * c-common.c (check_user_alignment): Use LOG2_BITS_PER_UNIT instead of
497 BITS_PER_UNIT_LOG.
498
5ec2cd9f
JM
4992016-07-25 Jason Merrill <jason@redhat.com>
500
501 PR c++/65970
502 * c.opt (fconstexpr-loop-limit): New.
503
9dc5773f 5042016-07-22 Martin Sebor <msebor@redhat.com>
2e6b45af
MS
505
506 PR c++/71675
507 * c-common.c (resolve_overloaded_builtin): Avoid converting
508 __atomic_compare_exchange_n return type to that of what its
509 first argument points to.
510
e3fe09c1
UB
5112016-07-22 Uros Bizjak <ubizjak@gmail.com>
512
513 * c-common.c: Use HOST_WIDE_INT_M1U instead of
514 ~(unsigned HOST_WIDE_INT) 0.
515
bc91c436
ML
5162016-07-22 Martin Liska <mliska@suse.cz>
517
518 PR gcov-profile/69028
519 PR gcov-profile/62047
520 * cilk.c (create_cilk_helper_decl): Set location of a new decl
521 to the current_function_decl.
522
451dcc66
JM
5232016-07-21 Jason Merrill <jason@redhat.com>
524
525 PR c++/65168
526 * c-common.c (c_common_truthvalue_conversion): Check
527 c_inhibit_evaluation_warnings for warning about address of
528 reference.
529
de6a69ee
DM
5302016-07-20 David Malcolm <dmalcolm@redhat.com>
531
532 * c-common.h (lookup_name_fuzzy): Convert return type from tree to
533 const char *.
534
d022c55a
JM
5352016-07-15 Jason Merrill <jason@redhat.com>
536
537 * c-opts.c (c_common_post_options): Update -fabi-version default to 11.
538
ddbbcb19
JJ
5392016-07-15 Jakub Jelinek <jakub@redhat.com>
540
541 PR c/71858
542 * c-common.h (enum lookup_name_fuzzy_kind): Add
543 FUZZY_LOOKUP_FUNCTION_NAME.
544
d0cf395a
JM
5452016-07-08 Jason Merrill <jason@redhat.com>
546
547 P0145: Refining Expression Order for C++.
548 * c.opts (-fargs-in-order): Rename to -fstrong-eval-order.
549 * c-opts.c: Adjust.
550
98d44e93
MT
5512016-07-05 Markus Trippelsdorf <markus@trippelsdorf.de>
552
553 PR c++/71214
554 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_rvalue_references.
555
f9d8d994
TS
5562016-06-29 Thomas Schwinge <thomas@codesourcery.com>
557
558 * c-pragma.h (enum pragma_kind): Rename
559 PRAGMA_OMP_DECLARE_REDUCTION to PRAGMA_OMP_DECLARE. Adjust all
560 users.
561
4aa83879
RB
5622016-06-29 Richard Biener <rguenther@suse.de>
563
564 PR middle-end/71002
565 * c-common.c (c_common_get_alias_set): Remove union type punning case.
566
a25bd9e6
JM
5672016-06-24 Jason Merrill <jason@redhat.com>
568
569 P0145R2: Refining Expression Order for C++.
570 * c-common.c (verify_tree) [COMPOUND_EXPR]: Fix handling on LHS of
571 MODIFY_EXPR.
572
a86451b9
JJ
5732016-06-24 Jakub Jelinek <jakub@redhat.com>
574
575 * c-common.c (check_builtin_function_arguments): Require last
576 argument of BUILT_IN_*_OVERFLOW_P to have INTEGER_TYPE type.
577 Adjust wording of diagnostics for BUILT_IN_*_OVERLFLOW
578 if the last argument is pointer to enumerated or boolean type.
579
1a4f11c8
DM
5802016-06-22 David Malcolm <dmalcolm@redhat.com>
581
582 PR c/70339
583 * c-common.h (enum lookup_name_fuzzy_kind): New enum.
584 (lookup_name_fuzzy): New prototype.
585
fe55692c
JDA
5862016-06-21 John David Anglin <danglin@gcc.gnu.org>
587
588 * c-common.c (get_source_date_epoch): Use int64_t instead of long long.
589
4eb24e01
JM
5902016-06-14 Jason Merrill <jason@redhat.com>
591
592 P0145R2: Refining Expression Order for C++.
593 * c.opt (fargs-in-order): New.
594 * c-opts.c (c_common_post_options): Adjust flag_args_in_order.
595
ef7cf206
JJ
5962016-06-13 Jakub Jelinek <jakub@redhat.com>
597
0dda258b
JJ
598 PR sanitizer/71498
599 * c-gimplify.c (ubsan_walk_array_refs_r): Set *walk_subtrees = 0 on
600 all BIND_EXPRs, and on all BIND_EXPRs recurse also on BIND_EXPR_BODY.
601
ef7cf206
JJ
602 PR preprocessor/71183
603 * c-ppoutput.c (init_pp_output): Set cb->get_source_date_epoch
604 to cb_get_source_date_epoch.
605
50b15873
JJ
6062016-06-10 Jakub Jelinek <jakub@redhat.com>
607
608 PR c/68657
609 * c.opt (Wpsabi): Add Warning flag.
610
4d926e34
MS
6112016-06-10 Martin Sebor <msebor@redhat.com>
612
613 PR c/71392
614 * gcc/c-family/c-common.c (handle_nonnull_attribute): Accept
615 the nonnull attribute in type-generic builtins.
616
e01b4e16
MS
6172016-06-09 Martin Sebor <msebor@redhat.com>
618
619 PR c/70883
620 * c-common.c (builtin_function_validate_nargs): Make text of error
621 message consistent with others like it.
622
44a845ca
MS
6232016-06-08 Martin Sebor <msebor@redhat.com>
624 Jakub Jelinek <jakub@redhat.com>
625
626 PR c++/70507
627 PR c/68120
628 * c-common.c (check_builtin_function_arguments): Handle
629 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
630
a80a7051
RB
6312016-06-08 Richard Biener <rguenther@suse.de>
632
633 * c-common.c (parse_optimize_options): Improve diagnostic messages.
634
bfd67b47
RB
6352016-06-07 Richard Biener <rguenther@suse.de>
636
637 PR c/61564
638 * c-common.c (parse_optimize_options): Only apply CL_OPTIMIZATION
639 options and warn about others.
640
15c98b2e
ES
6412016-06-01 Eduard Sanou <dhole@openmailbox.org>
642
643 * c-common.c (get_source_date_epoch): Rename to
644 cb_get_source_date_epoch.
645 * c-common.c (cb_get_source_date_epoch): Use a single generic erorr
646 message when the parsing fails. Use error_at instead of fatal_error.
647 * c-common.h (get_source_date_epoch): Rename to
648 cb_get_source_date_epoch.
649 * c-common.h (cb_get_source_date_epoch): Prototype.
650 * c-common.h (MAX_SOURCE_DATE_EPOCH): Define.
651 * c-common.h (c_omp_region_type): Remove trailing comma.
652 * c-lex.c (init_c_lex): Set cb->get_source_date_epoch callback.
653 * c-lex.c (c_lex_with_flags): Remove initialization of
654 pfile->source_date_epoch.
655
00631022
JJ
6562016-05-30 Jakub Jelinek <jakub@redhat.com>
657
658 PR c++/71349
659 * c-omp.c (c_omp_split_clauses): Put OMP_CLAUSE_DEPEND to
660 C_OMP_CLAUSE_SPLIT_TARGET. Put OMP_CLAUSE_NOWAIT to
661 C_OMP_CLAUSE_SPLIT_TARGET if combined with target construct,
662 instead of C_OMP_CLAUSE_SPLIT_FOR.
663
f17a223d
RB
6642016-05-24 Richard Biener <rguenther@suse.de>
665
666 PR middle-end/70434
667 PR c/69504
668 * c-common.h (convert_vector_to_pointer_for_subscript): Rename to ...
669 (convert_vector_to_array_for_subscript): ... this.
670 * c-common.c (convert_vector_to_pointer_for_subscript): Use a
671 VIEW_CONVERT_EXPR to an array type. Rename to ...
672 (convert_vector_to_array_for_subscript): ... this.
673
4f2e1536
MP
6742016-05-12 Marek Polacek <polacek@redhat.com>
675
676 PR c/70756
677 * c-common.c (pointer_int_sum): Call size_in_bytes_loc instead of
678 size_in_bytes and pass LOC to it.
679
d6e83a8d
MM
6802016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
681
682 PR c/43651
683 * c.opt (Wduplicate-decl-specifier): New option.
684
5c3a10fb
MP
6852016-05-11 Marek Polacek <polacek@redhat.com>
686
687 PR c++/71024
688 * c-common.c (diagnose_mismatched_attributes): New function.
689 * c-common.h (diagnose_mismatched_attributes): Declare.
690
deef7113
MP
6912016-05-04 Marek Polacek <polacek@redhat.com>
692
693 * c.opt (Wdangling-else): New option.
694
79ce98bc
MP
6952016-05-03 Marek Polacek <polacek@redhat.com>
696
697 PR c/70859
698 * c-common.c (builtin_function_validate_nargs): Add location
699 parameter. Use it.
700 (check_builtin_function_arguments): Add location and arguments
701 parameters. Use them.
702 * c-common.h (check_builtin_function_arguments): Update declaration.
703
381cdae4
RB
7042016-05-03 Richard Biener <rguenther@suse.de>
705
706 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Do not
707 allow call args to gimplify to SSA names.
708
1d793c34
MP
7092016-05-03 Marek Polacek <polacek@redhat.com>
710
711 * c-common.h (enum c_omp_region_type): Remove stray comma.
712
77886428
CP
7132016-05-02 Cesar Philippidis <cesar@codesourcery.com>
714
715 * c-common.h (enum c_omp_region_type): Define.
716
697e0b28
RS
7172016-05-02 Richard Sandiford <richard.sandiford@arm.com>
718
719 * c-common.c (shorten_compare): Use wi::to_wide.
720
e7ff0319
CP
7212016-04-29 Cesar Philippidis <cesar@codesourcery.com>
722
723 PR middle-end/70626
724 * c-common.h (c_oacc_split_loop_clauses): Add boolean argument.
725 * c-omp.c (c_oacc_split_loop_clauses): Use it to duplicate
726 reduction clauses in acc parallel loops.
727
2fff3db8
MP
7282016-04-29 Marek Polacek <polacek@redhat.com>
729
730 PR c/70852
731 * c-common.c (warn_for_memset): Check domain before accessing it.
732
509063eb
DV
7332016-04-29 Dominik Vogt <vogt@linux.vnet.ibm.com>
734
735 PR/69089
736 * c-common.c (handle_aligned_attribute): Allow 0 as an argument to the
737 "aligned" attribute.
738
b632761d
JM
7392016-04-28 Jason Merrill <jason@redhat.com>
740
741 * c-lex.c (c_common_has_attribute): Handle nodiscard.
742
174f6622
ES
7432016-04-28 Eduard Sanou <dhole@openmailbox.org>
744 Matthias Klose <doko@debian.org>
745
746 * c-common.c (get_source_date_epoch): New function, gets the environment
747 variable SOURCE_DATE_EPOCH and parses it as long long with error
748 handling.
749 * c-common.h (get_source_date_epoch): Prototype.
750 * c-lex.c (c_lex_with_flags): set parse_in->source_date_epoch.
751
6bc2bb18
RB
7522015-04-27 Ryan Burn <contact@rnburn.com>
753
754 PR c++/69024
755 PR c++/68997
756 * cilk.c (cilk_ignorable_spawn_rhs_op): Change to external linkage.
757 (cilk_recognize_spawn): Renamed from recognize_spawn and change to
758 external linkage.
759 (cilk_detect_and_unwrap): Corresponding changes.
760 (extract_free_variables): Don't extract free variables from
761 AGGR_INIT_EXPR slot.
762 * c-common.h (cilk_ignorable_spawn_rhs_op): Prototype.
763 (cilk_recognize_spawn): Likewise.
764
c1e1f433
BS
7652016-04-27 Bernd Schmidt <bschmidt@redhat.com>
766
767 * c.opt (Wmemset-elt-size): New option.
768 * c-common.c (warn_for_memset): New function.
769 * c-common.h (warn_for_memset): Declare.
770
d067e05f
JM
7712016-04-25 Jason Merrill <jason@redhat.com>
772
773 * c-common.c (handle_unused_attribute): Accept CONST_DECL.
774 No longer static.
775 * c-common.h: Declare it.
776 * c-lex.c (c_common_has_attribute): Add maybe_unused.
777
9aa36ae5
JM
7782016-04-22 Jason Merrill <jason@redhat.com>
779
780 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_range_based_for.
781
477d4906
IV
7822016-04-20 Ilya Verbin <ilya.verbin@intel.com>
783
784 PR c++/69363
785 * c-cilkplus.c (c_finish_cilk_clauses): Remove function.
786 * c-common.h (c_finish_cilk_clauses): Remove declaration.
787
fe37c7af
MM
7882016-04-18 Michael Matz <matz@suse.de>
789
790 * c-common.c (handle_aligned_attribute): Use SET_TYPE_ALIGN
791 and SET_DECL_ALIGN.
792
23f2660f
EB
7932016-04-17 Eric Botcazou <ebotcazou@adacore.com>
794
795 * c-ada-spec.c (get_underlying_decl): Return the typedef, if any.
796 (dump_generic_ada_node) <POINTER_TYPE>: Clean up handling of access
797 to incomplete types.
798 (dump_nested_type): Remove redundant tests and tidy up.
799 (print_ada_declaration): Also set TREE_VISITED on the declaration of
800 a type which is the typedef of an original type.
801
1e77281b
MP
8022016-04-15 Marek Polacek <polacek@redhat.com>
803
804 PR c/70651
805 * c-common.c (build_va_arg): Change two asserts into errors and return
806 error_mark_node.
807
b3a77f21
MP
8082016-04-13 Marek Polacek <polacek@redhat.com>
809
810 PR c++/70639
811 * c-indentation.c (should_warn_for_misleading_indentation): Bail out
812 for switch statements, too.
813
322b8466
JM
8142016-03-28 Jason Merrill <jason@redhat.com>
815
816 * c-cppbuiltin.c (c_cpp_builtins): Update __cpp_range_based_for.
817
fbdb6baf
MP
8182016-03-23 Marek Polacek <polacek@redhat.com>
819
820 PR c++/69884
821 * c.opt (Wignored-attributes): New option.
822
5c240f4d
DM
8232016-03-22 David Malcolm <dmalcolm@redhat.com>
824
825 PR c/69993
826 * c-indentation.c (warn_for_misleading_indentation): Rewrite the
827 diagnostic text, reversing the order of the warning and note so
828 that they appear in source order.
829
14ba7b28
MP
8302016-03-17 Marek Polacek <polacek@redhat.com>
831
832 PR c/69407
833 * c-common.c (resolve_overloaded_builtin): Set TREE_USED for the fetch
834 operations.
835
08a1cadc
JM
8362016-03-14 Jason Merrill <jason@redhat.com>
837
2aaeea19
JM
838 * c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.
839
08a1cadc
JM
840 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
841
c06d25bb
RB
8422016-03-09 Richard Biener <rguenther@suse.de>
843
844 PR c/70143
845 * c-common.c (strict_aliasing_warning): Add back
846 alias_sets_conflict_p check.
847
80aac5c8
JM
8482016-03-08 Jason Merrill <jason@redhat.com>
849
850 * c-opts.c (set_std_cxx1z): Don't enable concepts.
851
64b23c13
DM
8522016-03-04 David Malcolm <dmalcolm@redhat.com>
853
854 PR c/68187
855 * c-indentation.c (get_visual_column): Move code to determine next
856 tab stop to...
857 (next_tab_stop): ...this new function.
858 (line_contains_hash_if): Delete function.
859 (detect_preprocessor_logic): Delete function.
860 (get_first_nws_vis_column): New function.
861 (detect_intervening_unindent): New function.
862 (should_warn_for_misleading_indentation): Replace call to
863 detect_preprocessor_logic with a call to
864 detect_intervening_unindent.
865
729526f5
DM
8662016-03-04 David Malcolm <dmalcolm@redhat.com>
867
868 PR c/68187
869 * c-indentation.c (should_warn_for_misleading_indentation): When
870 suppressing warnings about cases where the guard and body are on
871 the same column, only use the first non-whitespace column in place
872 of the guard token column when dealing with "else" clauses.
873 When rejecting aligned BODY and NEXT, loosen the requirement
874 from equality with the first non-whitespace of guard to simply
875 that they not be indented relative to it.
876
e9a35493
RB
8772016-03-04 Richard Biener <rguenther@suse.de>
878
879 PR c++/70054
880 * c-common.c (strict_aliasing_warning): Use alias_set_subset_of
881 instead of alias_sets_conflict_p.
882
1be56bc5
MP
8832016-03-01 Marek Polacek <polacek@redhat.com>
884
885 PR c++/69795
886 * c-common.c (reject_gcc_builtin): Check for FUNCTION_DECL rather than
887 any DECL.
888
35886f0b
MS
8892016-02-22 Martin Sebor <msebor@redhat.com>
890
891 PR middle-end/69780
892 * c-common.c (check_builtin_function_arguments): Validate and
893 reject invalid arguments to __builtin_alloca_with_align.
894
4246c8da
MW
8952016-02-20 Mark Wielaard <mjw@redhat.com>
896
897 PR c/28901
898 * c.opt (Wunused-const-variable): Turn into Alias for...
899 (Wunused-const-variable=): New option.
900
268be88c
BE
9012016-02-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
902
903 PR c++/69865
904 * c-opts.c (c_common_post_options): Move call to set_std_cxx14 from
905 here...
906 (c_common_init_options): ...to here.
907 (set_std_cxx98): Initialize flag_isoc94 and flag_isoc99.
908
871b3f47
JJ
9092016-02-19 Jakub Jelinek <jakub@redhat.com>
910
911 PR c++/69826
912 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_GRAINSIZE.
913 (init_pragma): Register PRAGMA_CILK_GRAINSIZE even for
914 flag_preprocess_only.
915
bf14eba2
JJ
9162016-02-16 Jakub Jelinek <jakub@redhat.com>
917
918 PR c/69835
919 * c.opt (Wnonnull-compare): Enable for -Wall.
920
ba6b3795
JJ
9212016-02-15 Jakub Jelinek <jakub@redhat.com>
922
923 PR c++/69797
924 * c-common.c (sync_resolve_size): Diagnose too few arguments
925 even when params is non-NULL empty vector.
926
a011cd92
BS
9272016-02-08 Bernd Schmidt <bschmidt@redhat.com>
928
929 PR target/60410
930 * c.opt (fshort-double): Remove.
931
46cb9332
MS
9322016-02-05 Martin Sebor <msebor@redhat.com>
933
934 PR c++/69662
935 * c.opt (Warning options): Update -Wplacement-new to take
936 an optional argument.
937
e1b81f2b
JJ
9382016-02-01 Jakub Jelinek <jakub@redhat.com>
939
940 PR preprocessor/69543
941 PR c/69558
942 * c-pragma.c (handle_pragma_diagnostic): Pass input_location
943 instead of loc to control_warning_option.
944
b6adbb9f
NS
9452016-02-01 Nathan Sidwell <nathan@codesourcery.com>
946
947 * c.opt (fopenacc-dim=): New option.
948
5d70666e
RB
9492016-01-27 Ryan Burn <contact@rnburn.com>
950
951 PR cilkplus/69267
952 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): Change to use
953 gimplify_arg. Removed superfluous post_p argument.
954 * c-family.h (cilk_gimplify_call_params_in_spawned_fn): Removed
955 superfluous post_p argument.
956 * c-gimplify.c (c_gimplify_expr): Likewise.
957
01e1dea3
DM
9582016-01-26 David Malcolm <dmalcolm@redhat.com>
959
960 PR other/69006
961 * c-opts.c (c_diagnostic_finalizer): Replace invocation of
962 pp_newline_and_flush with pp_flush.
963
9f04a53e
MS
9642016-01-20 Martin Sebor <msebor@redhat.com>
965
966 PR c/69405
967 * c-common.c (sync_resolve_size): Avoid printing diagnostic about
968 an incompatible argument when the argument isn't a valid tree node.
969
7f26f7df
JM
9702016-01-18 Jason Merrill <jason@redhat.com>
971
972 PR c++/68767
973 * c-common.c (check_function_arguments_recurse): Fold the whole
974 COND_EXPR, not just the condition.
975
f62bf092
TV
9762016-01-18 Tom de Vries <tom@codesourcery.com>
977
978 * c-omp.c (c_oacc_split_loop_clauses): Don't copy OMP_CLAUSE_REDUCTION,
979 classify as loop clause.
980
e0a575ff
JJ
9812016-01-15 Jakub Jelinek <jakub@redhat.com>
982
983 PR bootstrap/68271
984 * c-pragma.c (c_register_pragma_1): Adjust comment to note that
985 C++ FE no longer has limit on number of pragmas.
986
9872015-01-14 Ryan Burn <contact@rnburn.com>
b6e3db06
RB
988
989 PR c++/69048
990 * cilk.c (create_cilk_wrapper_body): Call fold_build_cleanup_point_expr
c47eaca6 991 to add missing cleanup point.
b6e3db06 992
c7df95d8
DM
9932016-01-14 David Malcolm <dmalcolm@redhat.com>
994
995 PR c++/68819
996 * c-indentation.c (get_visual_column): Add location_t param.
997 Handle the column number being zero by effectively disabling the
998 warning, with an "inform".
999 (should_warn_for_misleading_indentation): Add location_t argument
1000 for all uses of get_visual_column.
1001
21efdd80
PP
10022016-01-10 Patrick Palka <ppalka@gcc.gnu.org>
1003
1004 PR c++/69029
1005 * c-indentation.c (should_warn_for_misleading_indentation):
1006 Don't warn about do-while statements.
1007
7a127fa7
MS
10082016-01-07 Martin Sebor <msebor@redhat.com>
1009
1010 PR c/68966
1011 * c-common.c (sync_resolve_size): Reject first argument when it's
1012 a pointer to _Bool.
1013
c589e975
DM
10142016-01-05 David Malcolm <dmalcolm@redhat.com>
1015
1016 PR c/69122
1017 * c-indentation.c (get_visual_column): Remove default argument.
1018 (should_warn_for_misleading_indentation): For the multiline case,
1019 update call to get_visual_column for next_stmt_exploc so that it
1020 captures the location of the first non-whitespace character in the
1021 relevant line. Don't issue warnings if there is non-whitespace
1022 before the next statement.
1023
818ab71a
JJ
10242016-01-04 Jakub Jelinek <jakub@redhat.com>
1025
1026 Update copyright years.
1027
745e411d
DM
10282015-12-21 David Malcolm <dmalcolm@redhat.com>
1029
1030 * c-common.c (binary_op_error): Convert first param from
1031 location_t to rich_location * and use it when emitting an error.
1032 * c-common.h (binary_op_error): Convert first param from
1033 location_t to rich_location *.
1034
de67c4c3
DM
10352015-12-16 David Malcolm <dmalcolm@redhat.com>
1036
1037 * c-common.h (conflict_marker_get_final_tok_kind): New prototype.
1038 * c-lex.c (conflict_marker_get_final_tok_kind): New function.
1039
4a38b02b
IV
10402015-12-15 Ilya Verbin <ilya.verbin@intel.com>
1041
1042 * c-common.c (c_common_attribute_table): Handle "omp declare target
1043 link" attribute.
1044
54d62f51
JJ
10452015-12-14 Jakub Jelinek <jakub@redhat.com>
1046
1047 PR c/68833
1048 * c.opt (Wmissing-format-attribute, Wnormalized): Add Warning option.
1049
8d4227c8
TB
10502014-12-12 Tobias Burnus <burnus@net-b.de>
1051
1052 PR fortran/68815
1053 * c-format.c (gcc_gfc_char_table): Add 'q' flag to remaining
1054 specifiers (%d, %i,%u and %c).
1055
f6069ccc
DM
10562015-12-10 David Malcolm <dmalcolm@redhat.com>
1057
1058 * c.opt (Wmisleading-indentation): Add to -Wall for C and C++.
1059
63bbf46d
JJ
10602015-12-08 Jakub Jelinek <jakub@redhat.com>
1061
1062 PR c/48088
1063 PR c/68657
1064 * c.opt (Wfloat-conversion, Wsign-conversion): Add Warning.
1065 * c-pragma.c (handle_pragma_diagnostic): Adjust
1066 control_warning_option caller.
1067
f79520bb
DM
10682015-12-07 David Malcolm <dmalcolm@redhat.com>
1069
1070 * c-common.c (c_cpp_error): Update for change to
1071 rich_location::set_range.
1072
b3d5bc62
JJ
10732015-12-04 Paolo Bonzini <bonzini@gnu.org>
1074
1075 * c-common.c (maybe_warn_shift_overflow): Warn on all overflows if
1076 shifting 1 out of the sign bit.
1077
10782015-12-04 Kirill Yukhin <kirill.yukhin@intel.com>
1079
1080 * c-common.c (c_common_attribute_table[]): Update max arguments
1081 count for "simd" attribute.
1082 (handle_simd_attribute): Parse "notinbranch" and "inbranch" arguments.
1083
6eb4a537
JJ
10842015-12-03 Jakub Jelinek <jakub@redhat.com>
1085
1086 PR preprocessor/57580
1087 * c-ppoutput.c (print): Change printed field to bool.
1088 Move src_file last for smaller padding.
1089 (init_pp_output): Set print.printed to false instead of 0.
1090 (scan_translation_unit): Fix up formatting. Set print.printed
1091 to true after printing something other than newline.
1092 (scan_translation_unit_trad): Set print.printed to true instead of 1.
1093 (maybe_print_line_1): Set print.printed to false instead of 0.
1094 (print_line_1): Likewise.
1095 (do_line_change): Set print.printed to true instead of 1.
1096 (cb_define, dump_queued_macros, cb_include, cb_def_pragma,
1097 dump_macro): Set print.printed to false after printing newline.
1098
4250754e
JM
10992015-12-02 Jason Merrill <jason@redhat.com>
1100
f479b43d
JM
1101 * c-common.c (fold_for_warn): New.
1102 (warn_logical_operator, warn_tautological_cmp)
1103 (check_function_arguments_recurse, maybe_warn_bool_compare): Use it.
1104
4250754e
JM
1105 * c-common.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
1106 (c_fully_fold_internal, decl_constant_value_for_optimization):
1107 Move to c/c-fold.c.
1108 * c-common.h: Don't declare decl_constant_value_for_optimization.
1109
e9e32ee6
JM
11102015-12-02 Joseph Myers <joseph@codesourcery.com>
1111
1112 PR c/68162
1113 * c-common.h (c_build_qualified_type): Add extra default
1114 arguments.
1115
37d5ad46
JB
11162015-12-01 Julian Brown <julian@codesourcery.com>
1117 Cesar Philippidis <cesar@codesourcery.com>
1118 James Norris <James_Norris@mentor.com>
1119
1120 * c-pragma.c (oacc_pragmas): Add PRAGMA_OACC_HOST_DATA.
1121 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_HOST_DATA.
1122 (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_USE_DEVICE.
1123
f07862c7
EB
11242015-11-30 Eric Botcazou <ebotcazou@adacore.com>
1125
1126 * c-ada-spec.c (print_ada_macros): Remove redundant blank line.
1127 (decl_sloc_common): Delete and move bulk of processing to...
1128 (decl_sloc): ...here.
1129 (pp_ada_tree_identifier): Remove reference to QUAL_UNION_TYPE.
1130 (dump_ada_double_name): Remove S parameter and compute the suffix.
1131 (dump_ada_array_type): Add PARENT parameter. Simplify computation of
1132 element type and deal with an anonymous one.
1133 (dump_ada_template): Use RECORD_OR_UNION_TYPE_P macro.
1134 (dump_generic_ada_node): Tweak. Adjust call to dump_ada_array_type
1135 and remove reference to QUAL_UNION_TYPE.
1136 (dump_nested_types): Make 2 passes on the fields and move bulk to...
1137 (dump_nested_type): ...here. New function extracted from above.
1138 Generate a full declaration for anonymous element type of arrays.
1139 (print_ada_declaration): Really skip anonymous declarations. Remove
1140 references to QUAL_UNION_TYPE. Adjust call to dump_ada_array_type.
1141 Clean up processing of declarations of array types and objects.
1142 (print_ada_struct_decl): Remove reference to QUAL_UNION_TYPE.
1143 Remove obsolete code and tidy up.
1144
75c8aac3
JH
11452015-11-29 Jan Hubicka <hubicka@ucw.cz>
1146
1147 PR c/67581
1148 * c-common.c (handle_transparent_union_attribute): Update
1149 also type variants.
1150
b58d3df2
ML
11512015-11-27 Martin Liska <mliska@suse.cz>
1152
1153 PR c++/68312
1154 * array-notation-common.c (cilkplus_extract_an_triplets):
1155 Release vector of vectors.
1156 * cilk.c (gimplify_cilk_spawn): Free allocated memory.
1157
89a01fcf
EB
11582015-11-26 Eric Botcazou <ebotcazou@adacore.com>
1159
1160 PR c++/68527
1161 * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
1162 (print_ada_struct_decl): Likewise.
1163
cc5c5226
IZ
11642015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
1165
1166 PR c++/68001
1167 * c-gimplify.c (c_gimplify_expr): Stop the process if see an error.
1168 * cilk.c (recognize_spawn): Determine location in a more precise
1169 way.
1170
269adb9d
JM
11712015-11-19 Jason Merrill <jason@redhat.com>
1172
1173 * c-common.c (shorten_compare): But look through macros from
1174 system headers.
1175
d0eccfcd
JM
11762015-11-18 Jason Merrill <jason@redhat.com>
1177
1178 * c-common.c (shorten_compare): Don't -Wtype-limits if the
1179 non-constant operand comes from a macro.
1180
3e44547c
JM
11812015-11-17 Jason Merrill <jason@redhat.com>
1182
1183 PR bootstrap/68346
1184 * c-common.c (warn_tautological_cmp): Fold before checking for
1185 constants.
1186
0f62c7a0
MP
11872015-11-16 Marek Polacek <polacek@redhat.com>
1188
1189 PR c++/68362
1190 * c-common.c (check_case_bounds): Fold low and high cases.
1191
a868811e
MP
11922015-11-16 Marek Polacek <polacek@redhat.com>
1193
1194 * c-ada-spec.c (dump_ada_template): Use RECORD_OR_UNION_TYPE_P.
1195 * c-common.c (c_common_get_alias_set): Likewise.
1196 (handle_visibility_attribute): Likewise.
1197
fff77217
KY
11982015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
1199
1200 * c-common.c (handle_simd_attribute): New.
1201 (struct attribute_spec): Add entry for "simd".
1202 (handle_simd_attribute): New.
1203
269e63b7
KT
12042015-11-13 Kai Tietz <ktietz70@googlemail.com>
1205
1206 * c-lex.c (interpret_float): Use fold_convert.
1207
ebedc9a3
DM
12082015-11-13 David Malcolm <dmalcolm@redhat.com>
1209
1210 * c-common.c (c_fully_fold_internal): Capture existing souce_range,
1211 and store it on the result.
1212 * c-opts.c (c_common_init_options): Set
1213 global_dc->colorize_source_p.
1214
6e232ba4
JN
12152015-11-12 James Norris <jnorris@codesourcery.com>
1216 Joseph Myers <joseph@codesourcery.com>
1217
1218 * c-pragma.c (oacc_pragmas): Add entry for declare directive.
1219 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_DECLARE.
1220 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT and
1221 PRAGMA_OACC_CLAUSE_LINK.
1222
e78bede6
MP
12232015-11-11 Marek Polacek <polacek@redhat.com>
1224
1225 PR c/68107
1226 PR c++/68266
1227 * c-common.c (valid_array_size_p): New function.
1228 * c-common.h (valid_array_size_p): Declare.
1229
3f8257db 12302015-11-11 Dominique d'Humieres <dominiq@lps.ens.fr>
4ac93c7c
DH
1231
1232 PR bootstrap/68271
1233 * c-pragma.c (c_register_pragma_1): Update the gcc_assert to 256.
1234
69f293c9
AM
12352015-11-11 Andrew MacLeod <amacleod@redhat.com>
1236
1237 * array-notation-common.c: Remove unused header files.
1238 * c-ada-spec.c: Likewise.
1239 * c-cilkplus.c: Likewise.
1240 * c-common.c: Likewise.
1241 * c-cppbuiltin.c: Likewise.
1242 * c-dump.c: Likewise.
1243 * c-format.c: Likewise.
1244 * c-gimplify.c: Likewise.
1245 * c-indentation.c: Likewise.
1246 * c-lex.c: Likewise.
1247 * c-omp.c: Likewise.
1248 * c-opts.c: Likewise.
1249 * c-pch.c: Likewise.
1250 * c-ppoutput.c: Likewise.
1251 * c-pragma.c: Likewise.
1252 * c-pretty-print.c: Likewise.
1253 * c-semantics.c: Likewise.
1254 * c-ubsan.c: Likewise.
1255 * cilk.c: Likewise.
1256 * stub-objc.c: Likewise.
1257
3a40d81d
NS
12582015-11-09 Thomas Schwinge <thomas@codesourcery.com>
1259 Cesar Philippidis <cesar@codesourcery.com>
1260 James Norris <jnorris@codesourcery.com>
1261 Julian Brown <julian@codesourcery.com>
1262 Nathan Sidwell <nathan@codesourcery.com>
1263
1264 * c-pragma.c (oacc_pragmas): Add "routine".
1265 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ROUTINE.
1266
ee45a32d
EB
12672015-11-08 Eric Botcazou <ebotcazou@adacore.com>
1268
1269 * c-common.c (c_common_attributes): Add scalar_storage_order.
1270 (handle_scalar_storage_order_attribute): New function.
1271 * c-pragma.c (global_sso): New variable.
1272 (maybe_apply_pragma_scalar_storage_order): New function.
1273 (handle_pragma_scalar_storage_order): Likewise.
1274 (init_pragma): Register scalar_storage_order.
1275 * c-pragma.h (maybe_apply_pragma_scalar_storage_order): Declare.
1276 * c.opt (Wscalar-storage-order): New warning.
1277 (fsso-struct=): New option.
1278
eb11eb15
MS
12792015-11-08 Martin Sebor <msebor@redhat.com>
1280
1281 * c.opt (Wplacement-new): Add a period to the end of a sentence.
1282
0aad0198
RS
12832015-11-07 Richard Sandiford <richard.sandiford@arm.com>
1284
1285 * c-common.c: Don't undef DEF_BUILTIN.
1286
8a645150
DM
12872015-11-06 David Malcolm <dmalcolm@redhat.com>
1288
1289 * c-common.c (c_cpp_error): Convert parameter from location_t to
1290 rich_location *. Eliminate the "column_override" parameter and
1291 the call to diagnostic_override_column.
1292 Update the "done_lexing" clause to set range 0
1293 on the rich_location, rather than overwriting a location_t.
1294 * c-common.h (c_cpp_error): Convert parameter from location_t to
1295 rich_location *. Eliminate the "column_override" parameter.
1296
7a5e4956
CP
12972015-11-05 Cesar Philippidis <cesar@codesourcery.com>
1298 Thomas Schwinge <thomas@codesourcery.com>
1299 James Norris <jnorris@codesourcery.com>
1300
1301 * c-omp.c (c_oacc_split_loop_clauses): Make TILE, GANG, WORKER, VECTOR,
1302 AUTO, SEQ, INDEPENDENT and PRIVATE loop clauses. Associate REDUCTION
1303 clauses with parallel and kernels and loops.
1304 * c-pragma.h (enum pragma_omp_clause): Add entries for
1305 PRAGMA_OACC_CLAUSE_{INDEPENDENT,TILE,DEFAULT}.
1306 * pt.c (tsubst_omp_clauses): Add support for OMP_CLAUSE_{NUM_GANGS,
1307 NUM_WORKERS,VECTOR_LENGTH,GANG,WORKER,VECTOR,ASYNC,WAIT,TILE,AUTO,
1308 INDEPENDENT,SEQ}.
1309 (tsubst_expr): Add support for OMP_CLAUSE_{KERNELS,PARALLEL,LOOP}.
1310
e2f5cc96
MS
13112015-11-05 Martin Sebor <msebor@redhat.com>
1312
1313 PR c++/67942
1314 * c.opt (-Wplacement-new): New option.
1315
e01d41e5
JJ
13162015-11-05 Jakub Jelinek <jakub@redhat.com>
1317
1318 * c-common.h (c_finish_omp_atomic): Add TEST argument.
1319 (c_omp_check_loop_iv, c_omp_check_loop_iv_exprs): New prototypes.
1320 * c-omp.c (c_finish_omp_atomic): Add TEST argument. Don't call
1321 save_expr or create_tmp_var* if TEST is true.
1322 (c_finish_omp_for): Store OMP_FOR_ORIG_DECLS always.
1323 Don't call add_stmt here.
1324 (struct c_omp_check_loop_iv_data): New type.
1325 (c_omp_check_loop_iv_r, c_omp_check_loop_iv,
1326 c_omp_check_loop_iv_exprs): New functions.
1327 (c_omp_split_clauses): Adjust for lastprivate being allowed on
1328 distribute.
1329 (c_omp_declare_simd_clauses_to_numbers): Change
1330 OMP_CLAUSE_LINEAR_VARIABLE_STRIDE OMP_CLAUSE_LINEAR_STEP into numbers.
1331 (c_omp_declare_simd_clauses_to_decls): Similarly change those
1332 from numbers to PARM_DECLs.
1333
595278be
MM
13342015-11-04 Mikhail Maltsev <maltsevm@gmail.com>
1335
1336 * c-omp.c (c_omp_split_clauses): Remove conditional compilation. Use
1337 flag_checking.
1338
3f8257db 13392015-11-03 Bernd Schmidt <bschmidt@redhat.com>
c85158de
MS
1340
1341 PR c++-common/67882
b3d5bc62
JJ
1342 * c-common.h (fold_offsetof_1): Add argument.
1343 * c-common.c (fold_offsetof_1): Diagnose more invalid
c85158de
MS
1344 offsetof expressions that reference elements past the end of
1345 an array.
1346
4bf9e5a8
TS
13472015-11-03 Thomas Schwinge <thomas@codesourcery.com>
1348 Chung-Lin Tang <cltang@codesourcery.com>
1349
1350 * c-pragma.c (oacc_pragmas): Add "atomic".
1351 * c-pragma.h (pragma_kind): Add PRAGMA_OACC_ATOMIC.
1352
3b1661a9
ES
13532015-10-30 Evgeny Stupachenko <evstupac@gmail.com>
1354
1355 * c-common.c (handle_target_clones_attribute): New.
1356 (c_common_attribute_table): Add handle_target_clones_attribute.
1357 (handle_always_inline_attribute): Add check on target_clones attribute.
1358 (handle_target_attribute): Ditto.
1359
2adfab87
AM
13602015-10-29 Andrew MacLeod <amacleod@redhat.com>
1361
1362 * array-notation-common.c: Reorder #include's and remove duplicates.
1363 * c-ada-spec.c: Likewise.
1364 * c-cilkplus.c: Likewise.
1365 * c-common.c: Likewise.
1366 * c-cppbuiltin.c: Likewise.
1367 * c-dump.c: Likewise.
1368 * c-format.c: Likewise.
1369 * c-gimplify.c: Likewise.
1370 * c-indentation.c: Likewise.
1371 * c-lex.c: Likewise.
1372 * c-omp.c: Likewise.
1373 * c-opts.c: Likewise.
1374 * c-pch.c: Likewise.
1375 * c-ppoutput.c: Likewise.
1376 * c-pragma.c: Likewise.
1377 * c-pretty-print.c: Likewise.
1378 * c-semantics.c: Likewise.
1379 * c-ubsan.c: Likewise.
1380 * cilk.c: Likewise.
1381 * stub-objc.c: Likewise.
1382
d90ec4f2
JM
13832015-10-28 Jason Merrill <jason@redhat.com>
1384
1385 * c-common.c (pointer_int_sum): Fold the MULT_EXPR.
1386
88bae6f4
TS
13872015-10-27 Thomas Schwinge <thomas@codesourcery.com>
1388 James Norris <jnorris@codesourcery.com>
1389 Cesar Philippidis <cesar@codesourcery.com>
1390
1391 PR c/64765
1392 PR c/64880
1393 * c-common.h (c_oacc_split_loop_clauses): Declare function.
1394 * c-omp.c (c_oacc_split_loop_clauses): New function.
1395
b1726d6c
MS
13962015-10-21 Martin Sebor <msebor@redhat.com>
1397
1398 PR driver/68043
1399 * c.opt: End each sentence that describes an option with a period.
1400
fa60eeb9
MP
14012015-10-20 Marek Polacek <polacek@redhat.com>
1402
1403 * array-notation-common.c (is_cilkplus_vector_p): Define.
1404 * c-common.h (is_cilkplus_vector_p): Declare.
1405
95979049
MP
14062015-10-20 Marek Polacek <polacek@redhat.com>
1407
1408 * c.opt (std=gnu++11): Do not describe as experimental.
1409 (std=gnu++14): Likewise.
1410
2a9fb712
JM
14112015-10-19 Jason Merrill <jason@redhat.com>
1412
1413 * c-cppbuiltin.c (c_cpp_builtins): Define
1414 __cpp_nontype_template_args.
1415
13b380a3
JM
14162015-10-19 Jason Merrill <jason@redhat.com>
1417
1418 * c-cppbuiltin.c (c_cpp_builtins): Define
1419 __cpp_enumerator_attributes, __cpp_fold_expressions,
1420 __cpp_unicode_characters.
1421
d9a6bd32
JJ
14222015-10-13 Jakub Jelinek <jakub@redhat.com>
1423 Aldy Hernandez <aldyh@redhat.com>
1424
1425 * c-common.c (enum c_builtin_type): Define DEF_FUNCTION_TYPE_9,
1426 DEF_FUNCTION_TYPE_10 and DEF_FUNCTION_TYPE_11.
1427 (c_define_builtins): Likewise.
1428 * c-common.h (enum c_omp_clause_split): Add
1429 C_OMP_CLAUSE_SPLIT_TASKLOOP.
1430 (c_finish_omp_critical, c_finish_omp_ordered): Add CLAUSES argument.
1431 (c_finish_omp_for): Add ORIG_DECLV argument.
1432 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP as
1433 201511 instead of 201307.
1434 * c-omp.c (c_finish_omp_critical): Add CLAUSES argument, set
1435 OMP_CRITICAL_CLAUSES to it.
1436 (c_finish_omp_ordered): Add CLAUSES argument, set
1437 OMP_ORDERED_CLAUSES to it.
1438 (c_finish_omp_for): Add ORIG_DECLV argument, set OMP_FOR_ORIG_DECLS
1439 to it if OMP_FOR. Clear DECL_INITIAL on the IVs.
1440 (c_omp_split_clauses): Handle OpenMP 4.5 combined/composite
1441 constructs and new OpenMP 4.5 clauses. Clear
1442 OMP_CLAUSE_SCHEDULE_SIMD if not combined with OMP_SIMD. Add
1443 verification code.
1444 * c-pragma.c (omp_pragmas_simd): Add taskloop.
1445 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKLOOP.
1446 (enum pragma_omp_clause): Add
1447 PRAGMA_OMP_CLAUSE_{DEFAULTMAP,GRAINSIZE,HINT,{IS,USE}_DEVICE_PTR}
1448 and PRAGMA_OMP_CLAUSE_{LINK,NOGROUP,NUM_TASKS,PRIORITY,SIMD,THREADS}.
1449
624d31fe
RS
14502015-10-05 Richard Sandiford <richard.sandiford@arm.com>
1451
1452 * c-lex.c (interpret_float): Use real_equal instead of
1453 REAL_VALUES_EQUAL.
1454
b8fd7909
JM
14552015-10-04 Jason Merrill <jason@redhat.com>
1456
1457 Implement N4514, C++ Extensions for Transactional Memory.
1458 * c-common.c (c_common_reswords): Add C++ TM TS keywords.
1459 (c_common_attribute_table): Add transaction_safe_dynamic.
1460 transaction_safe now affects type identity.
1461 (handle_tm_attribute): Handle transaction_safe_dynamic.
1462 * c-common.h (enum rid): Add RID_ATOMIC_NOEXCEPT,
1463 RID_ATOMIC_CANCEL, RID_SYNCHRONIZED.
1464 (OBJC_IS_CXX_KEYWORD): Add RID_SYNCHRONIZED.
1465 (D_TRANSMEM): New.
1466 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_transactional_memory.
1467 * c-pretty-print.c (pp_c_attributes_display): Don't print
1468 transaction_safe in C++.
1469
12651878
MP
14702015-10-02 Marek Polacek <polacek@redhat.com>
1471
1472 * c.opt (Wduplicated-cond): Don't enable by -Wall anymore.
1473
3e3b8d63
MP
14742015-10-02 Marek Polacek <polacek@redhat.com>
1475
1476 PR c/64249
1477 * c-common.c (warn_duplicated_cond_add_or_warn): New function.
1478 * c-common.h (warn_duplicated_cond_add_or_warn): Declare.
1479 * c.opt (Wduplicated-cond): New option.
1480
0d1a8f75
JM
14812015-10-01 Joseph Myers <joseph@codesourcery.com>
1482
1483 * c.opt (std=c11): Do not describe as experimental.
1484 (std=gnu11): Likewise.
1485 (std=iso9899:2011): Likewise.
1486
3e32ee19
NS
14872015-09-28 Nathan Sidwell <nathan@codesourcery.com>
1488
1489 * c-common.c (DEF_FUNCTION_TYPE_VAR_6): New.
1490 (DEF_FUNCTION_TYPE_VAR_11): Delete.
1491
974348ee
MP
14922015-09-25 Marek Polacek <polacek@redhat.com>
1493
1494 * c-ubsan.c (ubsan_instrument_division): Remove unnecessary code.
1495 (ubsan_instrument_shift): Likewise.
1496
15dbc1a6
MP
14972015-09-25 Marek Polacek <polacek@redhat.com>
1498
1499 PR sanitizer/64906
1500 * c-ubsan.c (ubsan_instrument_division): Also pre-evaluate OP1.
1501
6b95d7cc
PP
15022015-09-24 Patrick Palka <ppalka@gcc.gnu.org>
1503
1504 * c-indentation.c (should_warn_for_misleading_indentation):
1505 Compare next_stmt_vis_column with guard_line_first_nws instead
1506 of with guard_line_vis_column.
1507
c1822f9c
MLI
15082015-09-23 Manuel López-Ibáñez <manu@gcc.gnu.org>
1509
1510 PR c/49654
1511 PR c/49655
1512 * c-pragma.c (handle_pragma_diagnostic): Detect non-warning
1513 options and options not valid for the current language.
1514
d5398058
PP
15152015-09-22 Patrick Palka <ppalka@gcc.gnu.org>
1516
1517 * c-indentation.c (should_warn_for_misleading_indentation):
1518 Float out and consolidate the calls to get_visual_column that
1519 are passed guard_exploc as an argument. Compare
1520 next_stmt_vis_column with guard_line_first_nws instead of with
1521 body_line_first_nws.
1522
6b333269
NS
15232015-09-22 Nathan Sidwell <nathan@codesourcery.com>
1524
1525 * c.opt (Wmultiple-inheritance, Wvirtual-inheritance, Wtemplates,
1526 Wnamespaces): New C++ warnings.
1527
a75f1574
JM
15282015-09-22 Jason Merrill <jason@redhat.com>
1529
1530 * c-common.h (abi_compat_version_crosses): New.
1531 (warn_abi_version): Declare.
1532 * c-common.c: Define it.
1533 * c-opts.c (c_common_post_options): Handle it.
1534 flag_abi_compat_version defaults to 8.
1535
bdaaa8b7
VV
15362015-09-21 Ville Voutilainen <ville.voutilainen@gmail.com>
1537
1538 Complete the implementation of N4230, Nested namespace definition.
1539 * c-cppbuiltin.c: Add __cpp_namespace_attributes and
1540 __cpp_nested_namespace_definitions.
1541
eaa797e8
MLI
15422015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
1543
1544 * c-pragma.c (handle_pragma_diagnostic): Fix wrong return.
1545
c4914de6
MLI
15462015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
1547
1548 * c-pragma.c (handle_pragma_diagnostic): Use explicit location
1549 when warning.
1550 * c-pragma.h (pragma_lex): Add optional loc argument.
1551
fcb87c50
MM
15522015-09-16 Mikhail Maltsev <maltsevm@gmail.com>
1553
1554 * c-format.c (check_format_arg): Adjust to use common block size in all
1555 object pools.
1556
31bdd08a
DM
15572015-09-15 David Malcolm <dmalcolm@redhat.com>
1558
1559 * c-format.c (location_from_offset): Update for change in
1560 signature of location_get_source_line.
1561 * c-indentation.c (get_visual_column): Likewise.
1562 (line_contains_hash_if): Likewise.
1563
aa9f4b4c
MP
15642015-09-14 Marek Polacek <polacek@redhat.com>
1565
1566 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
1567 setting various warnings.
1568
aa256c4a
MP
15692015-09-14 Marek Polacek <polacek@redhat.com>
1570
1571 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
1572 a negative value.
1573
0f876f22
MW
15742015-09-11 Mark Wielaard <mjw@redhat.com>
1575
1576 PR c/28901
1577 * c.opt (Wunused-variable): Option from common.opt.
1578 (Wunused-const-variable): New option.
1579
273aa49e
PC
15802015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
1581
1582 PR c++/53184
1583 * c.opt ([Wsubobject-linkage]): Add.
1584
1807ffc1
MS
15852015-09-03 Martin Sebor <msebor@redhat.com>
1586
1587 PR c/66516
1588 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
1589 functions.
1590 * c-common.c (reject_gcc_builtin): Define.
1591
38942840
BI
15922015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
1593
1594 PR middle-end/60586
1595 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
1596 prototype.
1597 * c-gimplify.c (c_gimplify_expr): Added a call to the function
1598 cilk_gimplify_call_params_in_spawned_fn.
1599 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
1600 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
1601 unwrapping.
1602
c316b5e4
MP
16032015-08-25 Marek Polacek <polacek@redhat.com>
1604
1605 PR middle-end/67330
1606 * c-common.c (handle_weak_attribute): Don't check whether the
1607 visibility can be changed here.
1608
584a7c46
MLI
16092015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
1610
1611 * c-lex.c (c_lex_with_flags): Use explicit locations.
1612
a79683d5
TS
16132015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
1614
1615 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
1616 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
1617
61717a45
FXC
16182015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
1619
1620 PR middle-end/36757
1621 * c-common.c (check_builtin_function_arguments): Add check
1622 for BUILT_IN_SIGNBIT argument.
1623
329524f5
PC
16242015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
1625
1626 PR c++/67160
1627 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
1628 in c++1z mode.
1629
4ee55665
MP
16302015-08-17 Marek Polacek <polacek@redhat.com>
1631
1632 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
1633 with whitespaces before qualifier names.
1634
b893e375
MP
16352015-08-12 Marek Polacek <polacek@redhat.com>
1636
1637 PR c++/55095
1638 * c-common.c (maybe_warn_shift_overflow): Properly handle
1639 left-shifting 1 into the sign bit.
1640
c2d89095
MLI
16412015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
1642
1643 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
1644
971e17ff
AS
16452015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
1646 Braden Obrzut <admin@maniacsvault.net>
1647 Jason Merrill <jason@redhat.com>
1648
1649 Add C++ Concepts TS support.
1650 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
1651 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
1652 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
1653 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
1654 * c-opts.c (set_std_cxx1z): Set flag_concepts.
1655 * c.opt (fconcepts): New.
1656
b3d5bc62
JJ
16572015-08-02 Martin Sebor <msebor@redhat.com>
1658
1659 * c.opt (-Wframe-address): New warning option.
1660
8ebca419
PP
16612015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
1662
1663 * c-indentation.c (should_warn_for_misleading_indentation):
1664 Improve heuristics.
1665
1a1e101f
PP
16662015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
1667
1668 * c-indentation.c (get_visual_column): Add parameter first_nws,
1669 use it. Update comment documenting the function.
1670 (is_first_nonwhitespace_on_line): Remove.
1671 (should_warn_for_misleading_indentation): Replace usage of
1672 of is_first_nonwhitespace_on_line with get_visual_column.
1673
992118a1
PP
16742015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
1675
1676 * c-indentation.h (struct token_indent_info): Define.
1677 (get_token_indent_info): Define.
1678 (warn_for_misleading_information): Declare.
1679 * c-common.h (warn_for_misleading_information): Remove.
1680 * c-identation.c (warn_for_misleading_indentation):
1681 Change declaration to take three token_indent_infos. Adjust
1682 accordingly.
1683 * c-identation.c (should_warn_for_misleading_indentation):
1684 Likewise. Bail out early if the body is a compound statement.
1685 (guard_tinfo_to_string): Define.
1686
e8fa3817
JM
16872015-07-30 Jason Merrill <jason@redhat.com>
1688
1689 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
1690 '*' for reference decay.
1691
173864e8
MP
16922015-07-30 Marek Polacek <polacek@redhat.com>
1693
1694 * c-common.c (warn_tautological_cmp): Bail for float types.
1695
f2afe6dd
MP
16962015-07-27 Marek Polacek <polacek@redhat.com>
1697
1698 PR bootstrap/67030
1699 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
1700
05b28fd6
MP
17012015-07-27 Marek Polacek <polacek@redhat.com>
1702
1703 PR c++/66555
1704 PR c/54979
1705 * c-common.c (find_array_ref_with_const_idx_r): New function.
1706 (warn_tautological_cmp): New function.
1707 * c-common.h (warn_tautological_cmp): Declare.
1708 * c.opt (Wtautological-compare): New option.
1709
5a5062b8
MP
17102015-07-23 Marek Polacek <polacek@redhat.com>
1711
1712 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
1713 (ubsan_instrument_shift): Likewise.
1714
dc891fe7
MP
17152015-07-23 Marek Polacek <polacek@redhat.com>
1716
1717 PR sanitizer/66908
1718 * c-ubsan.c: Include gimplify.h.
1719 (ubsan_instrument_division): Unshare OP0 and OP1.
1720 (ubsan_instrument_shift): Likewise.
1721
451b5e48
MP
17222015-07-20 Marek Polacek <polacek@redhat.com>
1723 Richard Sandiford <richard.sandiford@arm.com>
1724
1725 PR c++/55095
1726 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
1727 Use EXPR_LOC_OR_LOC.
1728 (maybe_warn_shift_overflow): New function.
1729 * c-common.h (maybe_warn_shift_overflow): Declare.
1730 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
1731 * c.opt (Wshift-overflow): New option.
1732
fb0b2914
ML
17332015-07-16 Martin Liska <mliska@suse.cz>
1734
1735 * c-format.c (static void check_format_info_main): Use
1736 object_allocator instead of pool_allocator.
1737 (check_format_arg): Likewise.
1738 (check_format_info_main): Likewise.
1739
903f5c23
AM
17402015-07-15 Andrew MacLeod <amacleod@redhat.com>
1741
1742 * c-opts.c: Remove multiline #include comment.
1743
026c3cfd
AH
17442015-07-12 Aldy Hernandez <aldyh@redhat.com>
1745
1746 * c-common.c: Fix double word typos.
1747
bb49ee66
EB
17482015-07-10 Eric Botcazou <ebotcazou@adacore.com>
1749
1750 * c-ada-spec.h (cpp_operation): Revert latest change.
1751 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
1752 constructors and destructors.
1753
1916bcb5
AM
17542015-07-09 Andrew MacLeod <amacleod@redhat.com>
1755
1756 * c-common.h: Adjust includes for flags.h changes.
1757 * stub-objc.c: Likewise.
026c3cfd 1758
a9dcd529
EB
17592015-07-08 Eric Botcazou <ebotcazou@adacore.com>
1760
1761 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
1762 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
1763
b03b462f
JJ
17642015-07-08 Jakub Jelinek <jakub@redhat.com>
1765
1766 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
1767 are to be removed, return NULL rather than original clauses list.
1768
c7131fb2
AM
17692015-07-07 Andrew MacLeod <amacleod@redhat.com>
1770
1771 * array-notation-common.c: Adjust includes.
1772 * c-ada-spec.c: Likewise.
1773 * c-cilkplus.c: Likewise.
1774 * c-common.h: Likewise.
1775 * c-cppbuiltin.c: Likewise.
1776 * c-dump.c: Likewise.
1777 * c-format.c: Likewise.
1778 * c-gimplify.c: Likewise.
1779 * c-indentation.c: Likewise.
1780 * c-lex.c: Likewise.
1781 * c-omp.c: Likewise.
1782 * c-opts.c: Likewise.
1783 * c-pch.c: Likewise.
1784 * c-ppoutput.c: Likewise.
1785 * c-pragma.c: Likewise.
1786 * c-pretty-print.c: Likewise.
1787 * c-semantics.c: Likewise.
1788 * c-ubsan.c: Likewise.
1789 * cilk.c: Likewise.
1790 * stub-objc.c: Likewise.
1791
2a7fb83f
EB
17922015-07-07 Eric Botcazou <ebotcazou@adacore.com>
1793
1794 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
1795 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
1796
a03c9bf1
JM
17972015-07-01 Jason Merrill <jason@redhat.com>
1798
36a85135
JM
1799 * c-common.h (D_CXX11): Rename from D_CXX0X.
1800 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
1801 * c-common.c: Adjust.
1802
e7fa68d5
JM
1803 * c-opts.c (c_common_post_options): Default to C++14.
1804
a03c9bf1
JM
1805 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
1806
fe95b036
ESR
18072015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
1808
1809 Implement N4197 - Adding u8 character literals
b3d5bc62 1810 * c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
a64be36b 1811 CPP_CHAR.
b3d5bc62 1812 * c-common.c (c_parse_error): Print CPP_UTF8CHAR and
a64be36b 1813 CPP_UTF8CHAR_USERDEF tokens.
b3d5bc62 1814 * c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
a64be36b
EB
1815 and CPP_UTF8CHAR tokens.
1816 (lex_charconst): Treat CPP_UTF8CHAR token.
fe95b036 1817
da2e71c9
MLI
18182015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
1819
1820 PR fortran/66605
1821 * c-common.c (do_warn_unused_parameter): Move here.
1822 * c-common.h (do_warn_unused_parameter): Declare.
1823
b155cfd9
MP
18242015-06-29 Marek Polacek <polacek@redhat.com>
1825
1826 PR c/66322
1827 * c-common.c (check_case_bounds): Add bool * parameter. Set
1828 OUTSIDE_RANGE_P.
1829 (c_add_case_label): Add bool * parameter. Pass it down to
1830 check_case_bounds.
1831 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
1832 warning here.
1833 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
1834 declarations.
1835
31521951
MP
18362015-06-27 Marek Polacek <polacek@redhat.com>
1837
1838 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
1839 or VECTOR_INTEGER_TYPE_P throughout.
1840 * c-gimplify.c: Likewise.
1841
22d03525
MP
18422015-06-26 Marek Polacek <polacek@redhat.com>
1843
1844 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
1845 * c-common.c (c_fully_fold_internal): Likewise.
1846 (c_alignof_expr): Likewise.
1847 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
1848 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
b1726d6c 1849 * cilk.c (create_parm_list): Likewise.
22d03525 1850
af05e6e5
MP
18512015-06-26 Marek Polacek <polacek@redhat.com>
1852
1853 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
1854
f0889939
AM
18552015-06-25 Andrew MacLeod <amacleod@redhat.com>
1856
1857 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
1858 * c-gimplify.c: Likewise.
1859 * c-pragma.c: Likewise.
1860 * c-ubsan.c: Likewise.
1861 * cilk.c: Likewise.
1862
ca752f39
RS
18632015-06-25 Richard Sandiford <richard.sandiford@arm.com>
1864
1865 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
1866 ggc_hasher.
1867
16a16ec7
AM
18682015-06-25 Andrew MacLeod <amacleod@redhat.com>
1869
1870 * cilk.c: Move calls.h after tm.h in the include chain.
1871
0ae9bd27
MP
18722015-06-25 Marek Polacek <polacek@redhat.com>
1873
1874 * array-notation-common.c: Use VAR_P throughout.
1875 * c-ada-spec.c: Likewise.
1876 * c-common.c: Likewise.
1877 * c-format.c: Likewise.
1878 * c-gimplify.c: Likewise.
1879 * c-omp.c: Likewise.
1880 * c-pragma.c: Likewise.
1881 * c-pretty-print.c: Likewise.
1882 * cilk.c: Likewise.
1883
62f9079a
MP
18842015-06-25 Marek Polacek <polacek@redhat.com>
1885
1886 * cilk.c (extract_free_variables): Use is_global_var.
1887
0fa16060
RS
18882015-06-23 Richard Sandiford <richard.sandiford@arm.com>
1889
1890 * c-common.c: Don't include target-def.h.
1891
a68ae2e1
MP
18922015-06-23 Marek Polacek <polacek@redhat.com>
1893
1894 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
1895 when comparing INTEGER_CSTs.
1896
c6a2f2d9
PMR
18972015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
1898
1899 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
1900 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
1901 (dump_ada_template): Skip partially specialized types.
1902
6b4db501
MM
19032015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
1904
1905 * c-common.c (scalar_to_vector): Use std::swap instead of manually
1906 swapping.
1907
abb226c9
AM
19082015-06-17 Andrew MacLeod <amacleod@redhat.com>
1909
1910 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
1911 * c-ada-spec.c: Likewise.
1912 * c-cilkplus.c: Likewise.
1913 * c-common.c: Likewise.
1914 * c-common.h: Likewise.
1915 * c-cppbuiltin.c: Likewise.
1916 * c-dump.c: Likewise.
1917 * c-format.c: Likewise.
1918 * c-gimplify.c: Likewise.
1919 * c-indentation.c: Likewise.
1920 * c-lex.c: Likewise.
1921 * c-omp.c: Likewise.
1922 * c-opts.c: Likewise.
1923 * c-pch.c: Likewise.
1924 * c-ppoutput.c: Likewise.
1925 * c-pragma.c: Likewise.
1926 * c-pretty-print.c: Likewise.
1927 * c-semantics.c: Likewise.
1928 * c-ubsan.c: Likewise.
1929 * cilk.c: Likewise.
1930 * stub-objc.c: Likewise.
1931
076fecad
PP
19322015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
1933
1934 PR c++/65168
1935 * c-common.c (c_common_truthvalue_conversion): Warn when
1936 converting an address of a reference to a truth value.
1937
13fdf2e2
AM
19382015-06-08 Andrew MacLeod <amacleod@redhat.com>
1939
1940 * array-notation-common.c : Adjust include files.
1941 * c-ada-spec.c : Likewise.
1942 * c-cilkplus.c : Likewise.
1943 * c-common.c : Likewise.
1944 * c-common.h : Likewise.
1945 * c-cppbuiltin.c : Likewise.
1946 * c-dump.c : Likewise.
1947 * c-format.c : Likewise.
1948 * c-gimplify.c : Likewise.
1949 * c-indentation.c : Likewise.
1950 * c-lex.c : Likewise.
1951 * c-omp.c : Likewise.
1952 * c-opts.c : Likewise.
1953 * c-pch.c : Likewise.
1954 * c-ppoutput.c : Likewise.
1955 * c-pragma.c : Likewise.
1956 * c-pretty-print.c : Likewise.
1957 * c-semantics.c : Likewise.
1958 * c-ubsan.c : Likewise.
1959 * cilk.c : Likewise.
1960 * stub-objc.c : Likewise.
1961
a1661b90
MP
19622015-06-08 Marek Polacek <polacek@redhat.com>
1963
1964 PR c/66415
1965 * c-format.c (location_from_offset): Return LOC if LINE is null.
1966
d7438551
AH
19672015-06-05 Aldy Hernandez <aldyh@redhat.com>
1968
1969 * c-common.h (c_parse_final_cleanups): New prototype.
1970 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
1971
b3d5bc62
JJ
19722015-06-04 Sriraman Tallam <tmsriram@google.com>
1973
1974 * c-common.c (noplt): New attribute.
1975 (handle_noplt_attribute): New handler.
1976
ecb9f223
AM
19772015-06-04 Andrew MacLeod <amacleod@redhat.com>
1978
1979 * array-notation-common.c: Adjust includes for restructured coretypes.h.
1980 * c-ada-spec.c: Likewise.
1981 * c-cilkplus.c: Likewise.
1982 * c-common.c: Likewise.
1983 * c-common.h: Likewise.
1984 * c-cppbuiltin.c: Likewise.
1985 * c-dump.c: Likewise.
1986 * c-format.c: Likewise.
1987 * c-gimplify.c: Likewise.
1988 * c-indentation.c: Likewise.
1989 * c-lex.c: Likewise.
1990 * c-omp.c: Likewise.
1991 * c-opts.c: Likewise.
1992 * c-pch.c: Likewise.
1993 * c-ppoutput.c: Likewise.
1994 * c-pragma.c: Likewise.
1995 * c-pretty-print.c: Likewise.
1996 * c-semantics.c: Likewise.
1997 * c-ubsan.c: Likewise.
1998 * cilk.c: Likewise.
1999 * stub-objc.c: Likewise.
2000
6ac48155
DM
20012015-06-02 David Malcolm <dmalcolm@redhat.com>
2002
2003 PR c/66220:
2004 * c-indentation.c (should_warn_for_misleading_indentation): Use
2005 expand_location rather than expand_location_to_spelling_point.
2006 Don't warn if the guarding statement is more indented than the
2007 next/body stmts.
2008
773ce42e
DM
20092015-06-02 David Malcolm <dmalcolm@redhat.com>
2010
2011 * c-indentation.c (warn_for_misleading_indentation): Bail out
2012 immediately if -Wmisleading-indentation isn't enabled.
2013
4fef8379
ML
20142015-06-01 Martin Liska <mliska@suse.cz>
2015
2016 * c-format.c (check_format_arg):Use new type-based pool allocator.
2017 (check_format_info_main) Likewise.
2018
1edfb384
EB
20192015-05-31 Eric Botcazou <ebotcazou@adacore.com>
2020
2021 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
2022 (has_nontrivial_methods): Likewise.
2023
9677ef52
MP
20242015-05-25 Marek Polacek <polacek@redhat.com>
2025
2026 * c-ubsan.c (ubsan_instrument_shift): Use type0.
2027
fd5c817a
MP
20282015-05-22 Marek Polacek <polacek@redhat.com>
2029
2030 PR c/47043
2031 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
2032
a2f45fe6 20332015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
581edfa3
TS
2034
2035 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
2036 STACK_GROWS_DOWNWARD.
2037
a2f45fe6 20382015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
62f9f30b
TS
2039
2040 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
2041 STACK_GROWS_DOWNWARD rather than if it is defined.
2042
0fee2ac2 20432015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
b1726d6c 2044
0fee2ac2
MLI
2045 PR c/52952
2046 * c-format.c (location_column_from_byte_offset): New.
2047 (location_from_offset): New.
2048 (struct format_wanted_type): Add offset_loc field.
2049 (check_format_info): Move handling of location for extra arguments
2050 closer to the point of warning.
2051 (check_format_info_main): Pass the result of location_from_offset
2052 to warning_at.
2053 (format_type_warning): Pass the result of location_from_offset
2054 to warning_at.
2055
cf4ef6f7
MP
20562015-05-20 Marek Polacek <polacek@redhat.com>
2057
2058 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
2059
3a65ee74
MP
20602015-05-20 Marek Polacek <polacek@redhat.com>
2061
2062 * c-ada-spec.c (dump_sloc): Use DECL_P.
2063
21b634ae
MP
20642015-05-20 Marek Polacek <polacek@redhat.com>
2065
2066 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
2067 * c-common.c: Likewise.
2068
0e50b624
DM
20692015-05-19 David Malcolm <dmalcolm@redhat.com>
2070
2071 * c-common.h (fe_file_change): Strengthen param from
2072 const line_map * to const line_map_ordinary *.
2073 (pp_file_change): Likewise.
2074 * c-lex.c (fe_file_change): Likewise.
2075 (cb_define): Use linemap_check_ordinary when invoking
2076 SOURCE_LINE.
2077 (cb_undef): Likewise.
2078 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
2079 invoking cb_file_change.
2080 (c_finish_options): Likewise.
2081 (push_command_line_include): Likewise.
2082 (cb_file_change): Strengthen param "new_map" from
2083 const line_map * to const line_map_ordinary *.
2084 * c-ppoutput.c (cb_define): Likewise for local "map".
2085 (pp_file_change): Likewise for param "map" and local "from".
2086
fab27f52
MM
20872015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
2088
2089 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
2090
2fe1d762
TV
20912015-05-18 Tom de Vries <tom@codesourcery.com>
2092
2093 * c-common.c (build_va_arg_1): New function.
2094 (build_va_arg): Add address operator to va_list operand if necessary.
2095
7a37fa90
MM
20962015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
2097
2098 PR c/48956
2099 * c-common.c (int_safely_convertible_to_real_p): Define.
2100 (unsafe_conversion_p): Check conversions involving complex types.
2101 (conversion_warning): Add new warning message for conversions which
2102 discard imaginary component.
2103 * c-common.h: (enum conversion_safety): Add new enumerator for such
2104 conversions.
2105
3aa3c9fc
MP
21062015-05-14 Marek Polacek <polacek@redhat.com>
2107
2108 PR c/66066
2109 PR c/66127
2110 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
2111 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
2112 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
2113 use it. If FOR_INT_CONST, require that all evaluated operands be
2114 INTEGER_CSTs.
2115
c3388e62
DM
21162015-05-12 David Malcolm <dmalcolm@redhat.com>
2117
2118 * c-common.h (warn_for_misleading_indentation): New prototype.
2119 * c-indentation.c: New file.
2120 * c.opt (Wmisleading-indentation): New option.
2121
c7b38fd5
TV
21222015-05-12 Tom de Vries <tom@codesourcery.com>
2123
2124 PR tree-optimization/66010
2125 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
2126
381bf11e
JM
21272015-05-09 Jason Merrill <jason@redhat.com>
2128
edff0c06
JM
2129 * c-opts.c (c_common_post_options): Also clear
2130 cpp_opts->cpp_warn_cxx11_compat.
2131
129211bc
JM
2132 * c-common.h (enum cxx_dialect): Add cxx_unset.
2133 * c-common.c (cxx_dialect): Initialize to cxx_unset.
2134 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
2135
381bf11e
JM
2136 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
2137 (std=gnu++0x): Mark as Undocumented.
2138 (std=gnu++1y): Add deprecated message.
2139
fe191308
JM
21402015-05-08 Jason Merrill <jason@redhat.com>
2141
765189ff
JM
2142 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
2143 * c-opts.c: Adjust.
2144
fe191308
JM
2145 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
2146
755e528f
MP
21472015-05-08 Marek Polacek <polacek@redhat.com>
2148
2149 PR c/64918
2150 * c.opt (Woverride-init-side-effects): New option.
2151
0173bd2a
MP
21522015-05-07 Marek Polacek <polacek@redhat.com>
2153
2154 PR c/65179
2155 * c-common.c (c_fully_fold_internal): Warn when left shifting a
2156 negative value.
2157 * c.opt (Wshift-negative-value): New option.
2158 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
2159 when -Wextra and C99/C++11 mode.
2160
e0f0d3b9
MP
21612015-05-07 Marek Polacek <polacek@redhat.com>
2162 Martin Uecker <uecker@eecs.berkeley.edu>
2163
2164 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
2165 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
2166
8243e2a9
JM
21672015-05-05 Jason Merrill <jason@redhat.com>
2168
2169 * c.opt (Wterminate): New.
2170
577cd070
MP
21712015-04-30 Marek Polacek <polacek@redhat.com>
2172
2173 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
2174 require that the non-constant be of a boolean type.
2175
0373796b
JT
21762015-04-29 Josh Triplett <josh@joshtriplett.org>
2177
e0f0d3b9
MP
2178 * c-common.c (handle_section_attribute): Refactor to reduce
2179 nesting and distinguish between error cases.
0373796b 2180
716c0ba6
MP
21812015-04-29 Marek Polacek <polacek@redhat.com>
2182
2183 PR c/64610
2184 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
2185 with 0/1.
2186
8848828b
JJ
21872015-04-29 Jakub Jelinek <jakub@redhat.com>
2188
2189 * c-common.h (omp_clause_mask): Unconditionally define as a class.
2190 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
2191 HOST_BITS_PER_WIDE_INT.
2192
ecd0e562
TV
21932015-04-28 Tom de Vries <tom@codesourcery.com>
2194
2195 PR tree-optimization/65887
2196 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
2197
2a877204 21982015-04-28 Eric Botcazou <ebotcazou@adacore.com>
e0f0d3b9 2199 Pierre-Marie de Rodat <derodat@adacore.com>
2a877204
EB
2200
2201 * c-ada-spec.c (in_function): Delete.
2202 (dump_generic_ada_node): Do not change in_function and remove the
2203 redundant code dealing with it.
2204 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
2205 (print_ada_methods): Output the static member functions in a nested
2206 package after the regular methods as well as associated renamings.
2207
4853031e
MP
22082015-04-24 Marek Polacek <polacek@redhat.com>
2209
2210 PR c/65830
2211 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
2212 and OPT_Wshift_count_overflow.
2213
8c2b7f79
MP
2214 PR c/63357
2215 * c-common.c (warn_logical_operator): Warn if the operands have the
2216 same expressions.
2217
b8787813
MP
22182015-04-24 Marek Polacek <polacek@redhat.com>
2219
2220 PR c/61534
2221 * c-common.c (warn_logical_operator): Bail if either operand comes
2222 from a macro expansion.
2223
8fba1830
BRF
22242015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
2225
2226 PR target/55143
2227 * c-common.c (c_default_pointer_mode): Add definition.
2228 * c-common.h (c_default_pointer_mode): Add declaration.
2229
17958621
JJ
22302015-03-11 Jakub Jelinek <jakub@redhat.com>
2231
2232 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
2233 on record_builtin_type argument.
2234
7ccb1a11
JJ
22352015-03-10 Jakub Jelinek <jakub@redhat.com>
2236
2237 PR c/65120
2238 * c-common.c (warn_logical_not_parentheses): Don't warn for
2239 !x == 0 or !x != 0.
2240
04fd785e
MP
22412015-03-07 Marek Polacek <polacek@redhat.com>
2242
2243 PR sanitizer/65280
2244 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
2245 before trying to figure out whether we have a flexible array member.
2246
a4e26206
EB
22472015-03-06 Eric Botcazou <ebotcazou@adacore.com>
2248 Jonathan Wakely <jwakely.gcc@gmail.com>
2249
2250 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
2251
0d2489f4
EB
22522015-03-05 Eric Botcazou <ebotcazou@adacore.com>
2253
2254 PR ada/65319
2255 * c-ada-spec.c (print_destructor): Remove obsolete code.
2256
83ed54d7
EB
22572015-03-01 Eric Botcazou <ebotcazou@adacore.com>
2258
2259 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
2260 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
2261 DECL_TEMPLATE_RESULT emulations.
2262 (dump_ada_template)): Add guard for TYPE_METHODS.
2263
7631f0e2
MP
22642015-02-27 Marek Polacek <polacek@redhat.com>
2265
2266 PR c/65040
2267 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
2268
d1783ae5
KT
22692015-02-27 Kai Tietz <ktietz@redhat.com>
2270
2271 PR c/35330
2272 * c-pragma.c (handle_pragma_weak): Do not try to create
2273 weak/alias of declarations not being function, or variable
2274 declarations.
2275
56a9f6bc
TS
22762015-02-24 Thomas Schwinge <thomas@codesourcery.com>
2277
2278 PR libgomp/64625
2279 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
2280 Remove macros.
2281 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
2282
3d5cb23d
MP
22832015-02-16 Marek Polacek <polacek@redhat.com>
2284
2285 PR c/65066
2286 * c-format.c (check_format_types): Handle null param.
2287
fa008882
MP
22882015-02-13 Marek Polacek <polacek@redhat.com>
2289
2290 PR c/65040
2291 * c-format.c (check_format_types): Don't warn about different
2292 signedness if the original value is in the range of WANTED_TYPE.
2293
785f21af
JM
22942015-02-12 Jason Merrill <jason@redhat.com>
2295
2296 PR c++/64956
2297 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
2298 to the current highest version.
2299 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
2300
4886ec8e
JJ
23012015-02-04 Jakub Jelinek <jakub@redhat.com>
2302
2303 PR c/64824
2304 PR c/64868
2305 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
2306 instead of RDIV_EXPR. Use build_binary_op instead of
2307 build2_loc.
2308
40fecdd6
JM
23092015-01-30 Joseph Myers <joseph@codesourcery.com>
2310
2311 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
2312 to pass input_location as first argument.
2313
a0c88d06
TV
23142015-01-23 Tom de Vries <tom@codesourcery.com>
2315
2316 PR libgomp/64672
2317 * c.opt (fopenacc): Mark as LTO option.
2318
1506ae0e
TV
23192015-01-23 Tom de Vries <tom@codesourcery.com>
2320
2321 PR libgomp/64707
2322 * c.opt (fopenmp): Mark as LTO option.
2323
31be63ab
JJ
23242015-01-21 Jakub Jelinek <jakub@redhat.com>
2325
2326 PR c/63307
b1726d6c 2327 * cilk.c (fill_decls_vec): Only put decls into vector v.
31be63ab
JJ
2328 (compare_decls): Fix up formatting.
2329
23302015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
2331
2332 PR c/63307
2333 * cilk.c: Include vec.h.
2334 (struct cilk_decls): New structure.
2335 (wrapper_parm_cb): Split this function to...
2336 (fill_decls_vec): ...this...
2337 (create_parm_list): ...and this.
2338 (compare_decls): New function.
2339 (for_local_cb): Remove.
2340 (wrapper_local_cb): Ditto.
2341 (build_wrapper_type): For now first traverse and fill vector of
2342 declarations then sort it and then deal with sorted vector.
2343 (cilk_outline): Ditto.
2344 (declare_one_free_variable): Ditto.
2345
6875457f
JM
23462015-01-21 Jason Merrill <jason@redhat.com>
2347
2348 PR c++/64629
2349 * c-format.c (check_format_arg): Call decl_constant_value.
2350
185c9e56
ML
23512015-01-19 Martin Liska <mliska@suse.cz>
2352
2353 * c-common.c (handle_noicf_attribute): New function.
2354
41dbbb37
TS
23552015-01-15 Thomas Schwinge <thomas@codesourcery.com>
2356 Bernd Schmidt <bernds@codesourcery.com>
2357 James Norris <jnorris@codesourcery.com>
2358 Cesar Philippidis <cesar@codesourcery.com>
2359 Ilmir Usmanov <i.usmanov@samsung.com>
2360 Jakub Jelinek <jakub@redhat.com>
2361
2362 * c.opt (fopenacc): New option.
2363 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
2364 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
2365 New macros.
2366 * c-common.h (c_finish_oacc_wait): New prototype.
2367 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
2368 (c_finish_oacc_wait): New function.
2369 * c-pragma.c (oacc_pragmas): New variable.
2370 (c_pp_lookup_pragma, init_pragma): Handle it.
2371 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
2372 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
2373 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
2374 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
2375 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
2376 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
2377 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
2378 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
2379 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
2380 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
2381 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
2382 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
2383 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
2384 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
2385 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
2386 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
2387 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
2388 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
2389 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
2390 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
2391 PRAGMA_OACC_CLAUSE_WORKER.
2392
3f8257db 23932015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
5434dc07
MD
2394
2395 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
2396 for the new option fstack-protector_explicit.
2397 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
2398 (handle_stack_protect_attribute): New function.
2399
3f8257db 24002015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
de1b5c17
MU
2401
2402 * c.opt: New option -Warray-bounds=.
2403
adfac8df
JJ
24042015-01-09 Michael Collison <michael.collison@linaro.org>
2405
2406 * array-notation-common.c: Include hash-set.h, machmode.h,
2407 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2408 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
2409 * c-ada-spec.c: Ditto.
2410 * c-cilkplus.c: Ditto.
2411 * c-common.c: Include input.h due to flattening of tree.h.
2412 Define macro GCC_C_COMMON_C.
2413 * c-common.h: Flatten tree.h header files into c-common.h.
2414 Remove include of tree-core.h.
2415 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
2416 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2417 fold-const.h, wide-int.h, and inchash.h due to
2418 flattening of tree.h.
2419 * c-dump.c: Ditto.
2420 * c-format.c: Flatten tree.h header files into c-common.h.
2421 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
2422 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2423 fold-const.h, wide-int.h, and inchash.h due to
2424 flattening of tree.h.
2425 * c-dump.c: Include hash-set.h, machmode.h,
2426 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2427 fold-const.h, wide-int.h, and inchash.h due to
2428 flattening of tree.h.
2429 * c-format.c: Include hash-set.h, machmode.h,
2430 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2431 fold-const.h, wide-int.h, inchash.h and real.h due to
2432 flattening of tree.h.
2433 * c-gimplify.c: Include hash-set.h, machmode.h,
2434 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
2435 fold-const.h, wide-int.h, and inchash.h due to
2436 flattening of tree.h.
2437 * cilk.c: Ditto.
2438 * c-lex.c: Ditto.
2439 * c-omp.c: Ditto.
2440 * c-opts.c: Ditto.
2441 * c-pch.c: Ditto.
2442 * c-ppoutput.c: Ditto.
2443 * c-pragma.c: Ditto.
2444 * c-pretty-print.c: Ditto.
2445 * c-semantics.c: Ditto.
2446 * c-ubsan.c: Ditto.
2447 * stub-objc.c: Ditto.
2448
f5481fc4
JM
24492015-01-08 Jason Merrill <jason@redhat.com>
2450
2451 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
2452 do_ubsan_in_current_function.
2453 (ubsan_maybe_instrument_reference_or_call): Likewise.
2454 * c-ubsan.h: Declare it.
2455
de35aa66
MS
24562015-01-08 Mike Stump <mikestump@comcast.net>
2457
2458 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
2459
4a9a42ab
MP
24602015-01-07 Marek Polacek <polacek@redhat.com>
2461
2462 PR c/64440
2463 * c-common.c (c_fully_fold_internal): Warn for division and modulo
2464 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
2465
2f42e5de
TS
24662015-01-05 Trevor Saunders <tsaunders@mozilla.com>
2467
2468 PR c++/31397
2469 * c.opt (Wsuggest-override): New option.
2470
5624e564
JJ
24712015-01-05 Jakub Jelinek <jakub@redhat.com>
2472
2473 Update copyright years.
2474
5bd012f8
MP
24752015-01-05 Marek Polacek <polacek@redhat.com>
2476
2477 PR c/64423
2478 * c-common.c (warn_array_subscript_with_type_char): Add location_t
2479 parameter. Use it.
2480 * c-common.h (warn_array_subscript_with_type_char): Update
2481 declaration.
2482
a7fa8d18
ESR
24832014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
2484
2485 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
2486 Control macro with flag_sized_deallocation.
2487
3f8257db 24882014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
768952be
MU
2489
2490 * c.opt (Wdiscarded-array-qualifiers): New option.
2491
1f8d3e84
JJ
24922014-12-19 Jakub Jelinek <jakub@redhat.com>
2493
2494 PR preprocessor/63831
2495 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
2496 and __has_cpp_attribute here.
2497 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
2498 c_common_has_attribute.
2499 * c-common.h (c_common_has_attribute): New prototype.
2500 * c-lex.c (init_c_lex): Set cb->has_attribute to
2501 c_common_has_attribute instead of cb_has_attribute.
2502 (get_token_no_padding): New function.
2503 (cb_has_attribute): Renamed to ...
2504 (c_common_has_attribute): ... this. No longer static. Use
2505 get_token_no_padding, require ()s, don't build TREE_LIST
2506 unnecessarily, fix up formatting, adjust diagnostics, call
2507 init_attributes.
2508
20b06add
JM
25092014-12-15 Jason Merrill <jason@redhat.com>
2510
2511 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
2512 (-Wsized-deallocation): New.
2513 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
2514 to on in C++14 and up.
2515
94a073b2
JM
25162014-12-11 Jason Merrill <jason@redhat.com>
2517
acaa5911
JM
2518 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
2519
94a073b2
JM
2520 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
2521 we aren't complaining about VLAs.
2522
7fb66c15
MP
25232014-12-06 Marek Polacek <polacek@redhat.com>
2524
2525 PR tree-optimization/64183
2526 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
2527 shift-expression if it is integer_type_node. Use types_compatible_p.
2528
b731b390
JJ
25292014-11-29 Jakub Jelinek <jakub@redhat.com>
2530
2531 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
2532 last argument from create_tmp_var_raw and create_tmp_var calls.
2533 * cilk.c (gimplify_cilk_spawn): Likewise.
2534 * c-omp.c (c_finish_omp_atomic): Likewise.
2535
6a4da643
MP
25362014-11-28 Marek Polacek <polacek@redhat.com>
2537
2538 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
2539 instead of unsigned_type_node.
2540
541e35a6
MP
25412014-11-28 Marek Polacek <polacek@redhat.com>
2542
2543 PR c/63862
2544 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
2545 to op1_utype.
2546 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
2547 expression to unsigned_type_node.
2548
dcc97066
MW
25492014-11-20 Mark Wielaard <mjw@redhat.com>
2550
2551 PR debug/38757
2552 * c-opts.c (set_std_c89): Set lang_hooks.name.
2553 (set_std_c99): Likewise.
2554 (set_std_c11): Likewise.
2555 (set_std_cxx98): Likewise.
2556 (set_std_cxx11): Likewise.
2557 (set_std_cxx14): Likewise.
2558 (set_std_cxx1z): Likewise.
2559
aa7da51a
JJ
25602014-11-21 Jakub Jelinek <jakub@redhat.com>
2561
2562 PR target/63764
2563 * c-common.h (convert_vector_to_pointer_for_subscript): Change
2564 return type to bool.
009a3480 2565 * c-common.c: Include gimple-expr.h.
aa7da51a
JJ
2566 (convert_vector_to_pointer_for_subscript): Change return type to
2567 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
2568 and copy it into a TARGET_EXPR and use that instead of *vecp
2569 directly.
2570
538dd0b7
DM
25712014-11-19 David Malcolm <dmalcolm@redhat.com>
2572
2573 Merger of git branch "gimple-classes-v2-option-3".
2574 * ChangeLog.gimple-classes: New.
2575 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
2576 from being just a vec<gimple> to a vec<gbind *>.
2577
c39a5e99
JJ
25782014-11-18 Jakub Jelinek <jakub@redhat.com>
2579
2580 PR sanitizer/63813
2581 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
2582 argument to ptype, set type to TREE_TYPE (ptype). Don't call
2583 get_pointer_alignment for non-pointers. Use ptype, or if it is
2584 reference type, corresponding pointer type, as type of kind
2585 argument.
2586 (ubsan_maybe_instrument_reference,
2587 ubsan_maybe_instrument_member_call): Adjust callers.
2588
8537a4a9
MP
25892014-11-15 Marek Polacek <polacek@redhat.com>
2590
2591 PR middle-end/63884
2592 * array-notation-common.c (is_sec_implicit_index_fn): Return false
2593 for NULL fndecl.
2594 (extract_array_notation_exprs): Return for NULL node.
2595
2079956a
JM
25962014-11-12 Joseph Myers <joseph@codesourcery.com>
2597
2598 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
2599 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
2600
1304953e
JJ
26012014-11-12 Jakub Jelinek <jakub@redhat.com>
2602
2603 PR c/59708
2604 * c-common.c (check_builtin_function_arguments): Handle
2605 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
2606
e5e44252
AK
26072014-11-10 Andi Kleen <ak@linux.intel.com>
2608
2609 PR c/60804
2610 * c-common.h (check_no_cilk): Declare.
2611 * cilk.c (get_error_location): New function.
2612 (check_no_cilk): Dito.
2613
e64b984d
AK
26142014-11-10 Andi Kleen <ak@linux.intel.com>
2615
2616 * cilk.c (recognize_spawn): Use expression location
2617 for error message.
2618
13c21655
PC
26192014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
2620
2621 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
2622
42fd12b1
ESR
26232014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
2624
2625 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
2626 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
2627 (__cpp_range_based_for, __cpp_initializer_lists,
2628 __cpp_delegating_constructors, __cpp_nsdmi,
2629 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
2630 for C++11; (__cpp_attribute_deprecated): Remove in favor of
2631 __has_cpp_attribute.
2632 * c-lex.c (cb_has_attribute): New callback CPP function;
2633 (init_c_lex): Set has_attribute callback.
2634
6f450181
RB
26352014-11-04 Richard Biener <rguenther@suse.de>
2636
2637 * c-common.c (shorten_compare): Do not shorten mixed
2638 DFP and non-DFP compares.
2639
26f0e1d6
ESR
26402014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
2641
2642 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
2643 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
2644 Commentary and rearrangement of tests.
2645 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
2646 Commentary and rearrangement of tests.
2647 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto
2648 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
2649
ef4bddc2
RS
26502014-10-29 Richard Sandiford <richard.sandiford@arm.com>
2651
2652 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
2653 enum from machine_mode.
2654
c582198b
AM
26552014-10-28 Andrew MacLeod <amacleod@redhat.com>
2656
adfac8df
JJ
2657 * c-common.c: Adjust include files.
2658 * c-gimplify.c: Ditto.
2659 * cilk.c: Ditto.
2660 * c-pragma.c: Ditto.
2661 * c-ubsan.c: Ditto.
c582198b 2662
60393bbc
AM
26632014-10-27 Andrew MacLeod <amacleod@redhat.com>
2664
2665 * c-gimplify.c: Adjust include files.
2666
d723bb7c
MLI
26672014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
2668
2669 PR c++/53061
2670 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
2671 c_common_initialize_diagnostics.
2672 * c-common.h: Likewise.
2673
90f3520e
MP
26742014-10-24 Marek Polacek <polacek@redhat.com>
2675
2676 PR c/56980
2677 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
2678 print "struct"/"union"/"enum" for typedefed names.
2679
59d7607a
MP
26802014-10-23 Marek Polacek <polacek@redhat.com>
2681
2682 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
2683 in unsigned type.
2684
d95a2703
JJ
26852014-10-22 Jakub Jelinek <jakub@redhat.com>
2686 Yury Gribov <y.gribov@samsung.com>
2687
2688 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
2689 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
2690 instead of flag_sanitize_recover as bool flag.
2691
8e6ef852
KY
26922014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
2693
2694 * cilk.c: Revert previous change.
2695
948cf550
IZ
26962014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
2697
2698 PR c/63307
2699 * cilk.c: Include vec.h.
2700 (struct cilk_decls): New structure.
2701 (wrapper_parm_cb): Split this function to...
2702 (fill_decls_vec): ...this...
2703 (create_parm_list): ...and this.
2704 (compare_decls): New function.
2705 (for_local_cb): Remove.
2706 (wrapper_local_cb): Ditto.
2707 (build_wrapper_type): For now first traverse and fill vector of
2708 declarations then sort it and then deal with sorted vector.
2709 (cilk_outline): Ditto.
2710 (declare_one_free_variable): Ditto.
2711
92574c7c
MP
27122014-10-17 Marek Polacek <polacek@redhat.com>
2713
2714 * c-opts.c (c_common_post_options): Set warn_implicit_int.
2715 * c.opt (Wimplicit-int): Initialize to -1.
2716
83685514
AM
27172014-10-16 Andrew MacLeod <amacleod@redhat.com>
2718
2719 * c-pragma.c: Adjust include files.
2720 * c-semantics.c: Likewise.
2721
5b8300ea
DD
27222014-10-16 DJ Delorie <dj@redhat.com>
2723
2724 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
2725 multiples of bytes.
2726
5f83e90b
JM
27272014-10-14 Jason Merrill <jason@redhat.com>
2728
2729 PR c++/63455
2730 * c-common.h (CPP_PREPARSED_EXPR): New.
2731 (N_CP_TTYPES): Adjust.
2732
d73326ca
MP
27332014-10-15 Marek Polacek <polacek@redhat.com>
2734
2735 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
2736
78a7c317
DD
27372014-10-14 DJ Delorie <dj@redhat.com>
2738
2739 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
2740 types, not just __int128.
2741 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
2742 types, not just __int128.
2743 (cpp_atomic_builtins): Round pointer sizes up.
2744 (type_suffix): Use type precision, not specific types.
2745 * c-common.c (c_common_reswords): Remove __int128 special case.
2746 (c_common_type_for_size): Check for all __intN types, not just
2747 __int128.
2748 (c_common_type_for_mode): Likewise.
2749 (c_common_signed_or_unsigned_type): Likewise.
2750 (c_build_bitfield_integer_type): Likewise.
2751 (c_common_nodes_and_builtins): Likewise.
2752 (keyword_begins_type_specifier): Likewise.
2753 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
2754 __intN variants.
2755
2a22f99c
TS
27562014-10-12 Trevor Saunders <tsaunders@mozilla.com>
2757
2758 * c-common.c: Use hash_table instead of hashtab.
2759
2a8ef767
ESR
27602014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
2761
adfac8df 2762 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
2a8ef767
ESR
2763 C++11 section.
2764
3c9aabbd
MG
27652014-10-03 Marc Glisse <marc.glisse@inria.fr>
2766
2767 PR c++/54427
2768 PR c++/57198
2769 PR c++/58845
2770 * c-common.c (warn_logical_operator): Punt for vectors.
2771
a15f7cb8
ESR
27722014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
2773
2774 Implement SD-6: SG10 Feature Test Recommendations
2775 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
2776 macros and the __has_header macro.
2777
8d0cf15e
JM
27782014-09-30 Jason Merrill <jason@redhat.com>
2779
dd5d5481
JM
2780 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
2781 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
2782 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
2783
b752325e
JM
2784 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
2785 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
2786
8d0cf15e
JM
2787 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
2788 * c-common.c (c_common_reswords): Remove __is_convertible_to.
2789
083e891e
MP
27902014-09-24 Marek Polacek <polacek@redhat.com>
2791
2792 PR c/61405
2793 PR c/53874
2794 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
2795
7861b648
AK
27962014-09-23 Andi Kleen <ak@linux.intel.com>
2797
2798 * c-common.c (handle_no_reorder_attribute): New function.
2799 (c_common_attribute_table): Add no_reorder attribute.
2800
9a79452d
JM
28012014-09-22 Joseph Myers <joseph@codesourcery.com>
2802
2803 * c-cppbuiltin.c (c_cpp_builtins): Define
2804 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
2805 modes.
2806
dd69f047
JM
28072014-09-18 Joseph Myers <joseph@codesourcery.com>
2808
2809 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
2810 for supported floating-point modes.
2811
737a4826
MLI
28122014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
2813
2814 * c.opt (Wpsabi): Use LangEnabledBy.
2815 * c-opts.c (c_common_handle_option): Do not handle here.
2816
8cc4b7a2
JM
28172014-09-12 Joseph Myers <joseph@codesourcery.com>
2818
2819 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
2820 macros for floating-point modes.
2821
179b5a55
MG
28222014-09-11 Marc Glisse <marc.glisse@inria.fr>
2823
2824 PR target/58757
2825 * c-cppbuiltin.c (builtin_define_float_constants): Correct
2826 __*_DENORM_MIN__ without denormals.
2827
570a11fe
JJ
28282014-09-10 Jakub Jelinek <jakub@redhat.com>
2829
2830 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
2831 ubsan_instrument_vla, ubsan_instrument_return): Adjust
2832 ubsan_create_data callers.
2833 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
2834 index is constant or BIT_AND_EXPR with constant mask and is
2835 small enough for the bound.
2836 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
2837 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
2838
b559c810
MLI
28392014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
2840
2841 * c.opt: Add CppReason to various flags.
2842 (Wdate-time): Re-sort.
2843 * c-common.c: Include c-common.h earlier.
2844 (struct reason_option_codes_t): Delete.
2845 (c_option_controlling_cpp_error): Prefix global type and struct
2846 with cpp_.
2847
1ef33fd4
MLI
28482014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
2849
2850 * c.opt (Wnormalized): New.
2851 (Wnormalized=): Use Enum and Reject Negative.
2852 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
2853
66bb34c0
JM
28542014-09-08 Joseph Myers <joseph@codesourcery.com>
2855
2856 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
2857 digits of floating-point modes if -fbuilding-libgcc.
2858
53d68b9f
JM
28592014-09-05 Joseph Myers <joseph@codesourcery.com>
2860
2861 * c-cppbuiltin.c (c_cpp_builtins): Also define
2862 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
2863 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
2864 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
2865 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
2866 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
2867 __LIBGCC_STACK_GROWS_DOWNWARD__,
2868 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
2869 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
2870 __LIBGCC_DWARF_FRAME_REGISTERS__,
2871 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
2872 __LIBGCC_STACK_POINTER_REGNUM__ and
2873 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
2874 (builtin_define_with_value): Handle backslash-escaping in string
2875 macro values.
2876
f65586dc
RB
28772014-09-05 Richard Biener <rguenther@suse.de>
2878
2879 PR middle-end/63148
2880 * c-format.c (check_format_arg): Properly handle
2881 effectively signed POINTER_PLUS_EXPR offset.
2882
2b71f4a4
MLI
28832014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
2884
2885 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
2886 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
2887 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
2888 and Init.
2889 * c-opts.c (c_common_handle_option): Do not handle here.
2890 (sanitize_cpp_opts): Likewise.
2891 * c-common.c (struct reason_option_codes_t): Handle
2892 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
2893
d2e4feca
MP
28942014-09-03 Marek Polacek <polacek@redhat.com>
2895
2896 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
2897
9a771876
JJ
28982014-09-02 Jakub Jelinek <jakub@redhat.com>
2899 Balaji V. Iyer <balaji.v.iyer@intel.com>
2900 Igor Zamyatin <igor.zamyatin@intel.com>
2901
2902 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
2903 * c-common.c (c_common_reswords): Added _Cilk_for.
2904 * c-common.h (enum rid): Added RID_CILK_FOR.
2905 (cilk_for_number_of_iterations): Add declaration.
2906 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
2907 CILK_FOR.
2908 * c-pragma.c (init_pragma): Register "grainsize" pragma.
2909 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
2910
81b5d104
MLI
29112014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
2912
2913 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
2914 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
2915 Wundef): Use CPP, Var and Init.
2916 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
2917
b753b37b
MLI
29182014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
2919
2920 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
2921 * c-opts.c (c_common_handle_option): Do not handle here.
2922
028aee17
JM
29232014-08-25 Jason Merrill <jason@redhat.com>
2924
2925 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
2926 -std=c++14 and -std=gnu++14, rather than the reverse.
2927 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
2928 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
2929 * c-common.h (cxx_dialect): Remove cxx1y.
2930
e4276ba5
ESR
29312014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
2932
2933 * c-common.h (enum cxx_dialect): Add cxx14.
2934 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
2935 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
2936 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
2937
a545cacd
JM
29382014-08-22 Jason Merrill <jason@redhat.com>
2939
2940 * c.opt (std=gnu++17): Fix alias.
2941
59ea0364
MP
29422014-08-22 Marek Polacek <polacek@redhat.com>
2943
2944 PR c++/62199
2945 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
2946 check for vector types. Drop LHS argument.
2947 * c-common.h (warn_logical_not_parentheses): Adjust.
2948
596e808c
MLI
29492014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
2950
2951 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
2952 (Wmultichar): Likewise.
2953 (Wdate-time): Use C-family languages instead of Common. Use CPP
2954 and Var.
2955 * c-opts.c (c_common_handle_option): Do not handle the above
2956 options here.
2957 (sanitize_cpp_opts): Likewise.
2958
18767f65
MLI
29592014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
2960
2961 PR fortran/44054
2962 * c-opts.c: Include tree-diagnostics.h.
2963 (c_diagnostic_finalizer): New.
2964 (c_common_initialize_diagnostics): Use it.
2965
b4413594
MLI
29662014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
2967
2968 PR preprocessor/51303
2969 * c-common.c (struct reason_option_codes_t option_codes):
2970 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
2971
43f9a13c
MLI
29722014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
2973
2974 PR c/60975
2975 PR c/53063
2976 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
2977 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
2978 (c_common_post_options): Call init_global_opts_from_cpp.
2979 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
2980
04159acf
MP
29812014-08-19 Marek Polacek <polacek@redhat.com>
2982
2983 PR c++/62153
2984 * c-common.c (maybe_warn_bool_compare): New function.
2985 * c-common.h (maybe_warn_bool_compare): Declare.
2986 * c.opt (Wbool-compare): New option.
2987
35aff4fb
MP
29882014-08-19 Marek Polacek <polacek@redhat.com>
2989
2990 * c.opt (Wc99-c11-compat): New option.
2991
177cce46
MP
29922014-08-19 Marek Polacek <polacek@redhat.com>
2993
2994 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
2995 to warn_c90_c99_compat.
2996 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
2997 to -1.
2998
6ae9194f
MLI
29992014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
3000 Steven Bosscher <steven@gcc.gnu.org>
3001
3002 PR c/52952
3003 * c-format.c: Add extra_arg_loc and format_string_loc to struct
3004 format_check_results.
3005 (check_function_format): Use true and add comment for boolean
3006 argument.
3007 (finish_dollar_format_checking): Use explicit location when warning.
3008 (check_format_info): Likewise.
3009 (check_format_arg): Set extra_arg_loc and format_string_loc.
3010 (check_format_info_main): Use explicit location when warning.
3011 (check_format_types): Pass explicit location.
3012 (format_type_warning): Likewise.
3013
8e54f6d3
MLI
30142014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
3015
3016 PR fortran/44054
3017 * c-format.c: Handle Fortran flags.
3018
cd4e76fc
IZ
30192014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
3020
3021 PR other/61962
3022 * array-notation-common.c (find_rank): Added handling for other
3023 types of references.
3024
f3bede71
MP
30252014-08-10 Marek Polacek <polacek@redhat.com>
3026
3027 PR c/51849
3028 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
3029 * c.opt (Wc90-c99-compat): Add option.
3030
9f25a338
TS
30312014-08-07 Trevor Saunders <tsaunders@mozilla.com>
3032
3033 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
3034
62e4eb35
MP
30352014-08-03 Marek Polacek <polacek@redhat.com>
3036
3037 * c-common.c (check_case_value): Add location_t parameter. Use it.
3038 (c_add_case_label): Pass loc to check_case_value.
3039
b787e7a2
TS
30402014-08-02 Trevor Saunders <tsaunders@mozilla.com>
3041
3042 * cilk.c: Use hash_map instead of pointer_map.
3043
6e2830c3
TS
30442014-08-02 Trevor Saunders <tsaunders@mozilla.com>
3045
3046 * c-gimplify.c: Use hash_set instead of pointer_set.
3047
a7ee52fb
IZ
30482014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
3049
3050 PR middle-end/61455
3051 * array-notation-common.c (extract_array_notation_exprs): Handling
3052 of DECL_EXPR added.
3053
944fa280
JJ
30542014-08-01 Jakub Jelinek <jakub@redhat.com>
3055
3056 * c-common.h (min_align_of_type): Removed prototype.
3057 * c-common.c (min_align_of_type): Removed.
3058 * c-ubsan.h (ubsan_maybe_instrument_reference,
3059 ubsan_maybe_instrument_member_call): New prototypes.
3060 * c-ubsan.c: Include stor-layout.h and builtins.h.
3061 (ubsan_maybe_instrument_reference_or_call,
3062 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
3063 functions.
3064
b4dfdc11
MG
30652014-07-31 Marc Glisse <marc.glisse@inria.fr>
3066
3067 PR c++/60517
3068 * c.opt (-Wreturn-local-addr): Move to common.opt.
3069
a41844e5
JM
30702014-07-30 Jason Merrill <jason@redhat.com>
3071
3072 PR c++/61659
3073 PR c++/61687
3074 Revert:
3075 * c.opt (-fuse-all-virtuals): New.
3076
976d5a22
TT
30772014-07-30 Tom Tromey <tromey@redhat.com>
3078
3079 PR c/59855
3080 * c.opt (Wdesignated-init): New option.
3081 * c-common.c (c_common_attribute_table): Add "designated_init".
3082 (handle_designated_init): New function.
3083
cdc94aca
MP
30842014-07-24 Marek Polacek <polacek@redhat.com>
3085
3086 PR c/57653
3087 * c-opts.c (c_finish_options): If -imacros is in effect, return.
3088
f41373b6
DS
30892014-07-16 Dodji Seketeli <dodji@redhat.com>
3090
3091 PR preprocessor/60723 - missing system-ness marks for macro tokens
3092 * c-ppoutput.c (struct print::prev_was_system_token): New data
3093 member.
3094 (init_pp_output): Initialize it.
3095 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
3096 (do_line_change): Return a flag saying if a line marker was
3097 emitted or not.
3098 (scan_translation_unit): Detect if the system-ness of the token we
3099 are about to emit is different from the one of the previously
3100 emitted token. If so, emit a line marker. Avoid emitting useless
3101 adjacent line markers. Avoid emitting line markers for tokens
3102 originating from the expansion of built-in macros.
3103 (scan_translation_unit_directives_only): Adjust.
3104
4d661eaa
MP
31052014-07-15 Marek Polacek <polacek@redhat.com>
3106
3107 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
3108 TYPE_MAX_VALUE is NULL.
3109
b108f48f
JJ
31102014-07-14 Jakub Jelinek <jakub@redhat.com>
3111
3112 PR middle-end/61294
3113 * c.opt (Wmemset-transposed-args): New warning.
3114
c0221884
JM
31152014-07-10 Jason Merrill <jason@redhat.com>
3116
3117 PR c++/61659
3118 PR c++/61687
3119 * c.opt (-fuse-all-virtuals): New.
3120
63dfbb95
RB
31212014-07-09 Richard Biener <rguenther@suse.de>
3122
3123 PR c-family/61741
3124 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
3125 using unsigned arithmetic if overflow does not wrap instead of
3126 if overflow is undefined.
3127
773ec47f
MP
31282014-07-06 Marek Polacek <polacek@redhat.com>
3129
3130 PR c/6940
3131 * c.opt (Wsizeof-array-argument): New option.
3132
00a7ba58
JJ
31332014-07-03 Jakub Jelinek <jakub@redhat.com>
3134
b1726d6c 3135 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
00a7ba58
JJ
3136 comments->count <= 1, as comments->entries might be NULL.
3137
52ec0ea3
MP
31382014-07-01 Marek Polacek <polacek@redhat.com>
3139
3140 * c.opt (Wint-conversion): New option.
3141
d5c3d343
MP
31422014-07-01 Marek Polacek <polacek@redhat.com>
3143
3144 PR c/58286
3145 * c.opt (Wincompatible-pointer-types): New option.
3146
6e7ceb17
PC
31472014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
3148
3149 PR c++/51400
3150 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
3151 Do not discard TYPE_QUALS of type.
3152
da73100b
JM
31532014-06-26 Jason Merrill <jason@redhat.com>
3154
3155 * c-common.h (enum cxx_dialect): Add cxx1z.
3156 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
3157 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
3158
08eedf75
TJ
31592014-06-26 Teresa Johnson <tejohnson@google.com>
3160
3161 * c-common.h (get_dump_info): Declare.
3162 * c-gimplify.c (c_genericize): Use saved dump files.
3163 * c-opts.c (c_common_parse_file): Begin and end dumps
3164 once around parsing invocation.
3165 (get_dump_info): New function.
3166
7b56b2f8
MP
31672014-06-23 Marek Polacek <polacek@redhat.com>
3168 Andrew MacLeod <amacleod@redhat.com>
3169
3170 PR c/61553
3171 * c-common.c (get_atomic_generic_size): Don't segfault if the
3172 type doesn't have a size.
3173
0e37a2f3
MP
31742014-06-20 Marek Polacek <polacek@redhat.com>
3175
3176 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
3177 (ubsan_walk_array_refs_r): New function.
3178 (c_genericize): Instrument array bounds.
3179 * c-ubsan.c: Include "internal-fn.h".
3180 (ubsan_instrument_division): Mark instrumented arrays as having
3181 side effects. Adjust ubsan_type_descriptor call.
3182 (ubsan_instrument_shift): Likewise.
3183 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
3184 (ubsan_instrument_bounds): New function.
3185 (ubsan_array_ref_instrumented_p): New function.
3186 (ubsan_maybe_instrument_array_ref): New function.
3187 * c-ubsan.h (ubsan_instrument_bounds): Declare.
3188 (ubsan_array_ref_instrumented_p): Declare.
3189 (ubsan_maybe_instrument_array_ref): Declare.
3190
31912014-06-20 Hale Wang <hale.wang@arm.com>
dd6fe7d4
HW
3192
3193 PR lto/61123
3194 * c.opt (fshort-enums): Add to LTO.
3195 * c.opt (fshort-wchar): Likewise.
3196
5c3d09f7
MP
31972014-06-16 Marek Polacek <polacek@redhat.com>
3198
3199 PR c/60439
3200 * c.opt (Wswitch-bool): Add Var.
3201
9cf32741
JJ
32022014-06-12 Jakub Jelinek <jakub@redhat.com>
3203
3204 PR middle-end/61486
3205 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
3206 #pragma omp target teams or
3207 #pragma omp {,target }teams distribute simd.
3208
62984918
JM
32092014-06-12 Jason Merrill <jason@redhat.com>
3210
3211 * c.opt (Wabi=, fabi-compat-version): New.
3212 * c-opts.c (c_common_handle_option): Handle -Wabi=.
3213 (c_common_post_options): Handle flag_abi_compat_version default.
3214 Disallow -fabi-compat-version=1.
3215 * c-common.h (abi_version_crosses): New.
3216
f961457f
JH
32172014-06-11 Jan Hubicka <hubicka@ucw.cz>
3218
adfac8df 3219 * c-common.c (handle_section_attribute): Update handling for
f961457f
JH
3220 section names that are no longer trees.
3221
92d28cbb
JJ
32222014-06-10 Jakub Jelinek <jakub@redhat.com>
3223
3224 PR fortran/60928
3225 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
3226 (omp_pragmas): ... back here.
3227
742938c9
MP
32282014-06-05 Marek Polacek <polacek@redhat.com>
3229
3230 PR c/49706
3231 * c-common.c (warn_logical_not_parentheses): New function.
3232 * c-common.h (warn_logical_not_parentheses): Declare.
3233 * c.opt (Wlogical-not-parentheses): New option.
3234
9d548dfb
MP
32352014-06-04 Marek Polacek <polacek@redhat.com>
3236
3237 PR c/30020
3238 * c-common.c (check_case_bounds): Add location parameter.
3239 Use it.
3240 (c_add_case_label): Pass loc to check_case_bounds.
3241
fedfecef
MP
32422014-06-03 Marek Polacek <polacek@redhat.com>
3243
3244 PR c/60439
3245 * c.opt (Wswitch-bool): New option.
3246
f6a7cffc
TS
32472014-05-22 Thomas Schwinge <thomas@codesourcery.com>
3248
040d18b6
TS
3249 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
3250 Remove prototypes.
3251 (record_types_used_by_current_var_decl): Move prototype to where
3252 it belongs.
3253
f6a7cffc
TS
3254 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
3255 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
3256 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
3257
632f2871
RS
32582014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
3259
3260 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
3261 * c-common.c (c_common_nodes_and_builtins): Don't initialize
3262 void_zero_node.
3263 * c-pretty-print.c (pp_c_void_constant): New function.
3264 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
3265 (c_pretty_printer::expression): Handle VOID_CST.
3266 * cilk.c (extract_free_variables): Likewise.
3267 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
3268 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
3269
766090c2
TS
32702014-05-17 Trevor Saunders <tsaunders@mozilla.com>
3271
3272 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
3273 * c-pragma.c (push_alignment): Adjust.
3274 (handle_pragma_push_options): Likewise.
3275
661a0813
MP
32762014-05-09 Marek Polacek <polacek@redhat.com>
3277
3278 PR c/50459
3279 * c-common.c (check_user_alignment): Return -1 if alignment is error
3280 node.
3281 (handle_aligned_attribute): Don't call default_conversion on
3282 FUNCTION_DECLs.
3283 (handle_vector_size_attribute): Likewise.
3284 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
3285 (handle_sentinel_attribute): Call default_conversion and allow even
3286 integral types as an argument.
3287
2793eeab
MP
32882014-05-08 Marek Polacek <polacek@redhat.com>
3289
3290 PR c/61053
3291 * c-common.c (min_align_of_type): New function factored out from...
3292 (c_sizeof_or_alignof_type): ...here.
3293 * c-common.h (min_align_of_type): Declare.
3294
f827930a
MP
32952014-05-08 Marek Polacek <polacek@redhat.com>
3296
3297 PR c/61077
3298 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
3299 parameter type of main.
3300
ca49b74e
DD
33012014-05-07 DJ Delorie <dj@redhat.com>
3302
3303 * c-cppbuiltin.c (print_bits_of_hex): New.
3304 (builtin_define_type_minmax): Print values using hex so as not to
3305 require a pre-computed list of string values.
3306
1d60af08
KZ
33072014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
3308 Mike Stump <mikestump@comcast.net>
3309 Richard Sandiford <rdsandiford@googlemail.com>
3310
3311 * c-ada-spec.c: Include wide-int.h.
3312 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
3313 (dump_generic_ada_node): Use wide-int interfaces.
3314 * c-common.c: Include wide-int-print.h.
3315 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
3316 (pointer_int_sum): Use wide-int interfaces.
3317 (c_common_nodes_and_builtins): Use make_int_cst.
3318 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
3319 (handle_alloc_size_attribute): Use wide-int interfaces.
3320 (get_nonnull_operand): Likewise.
3321 * c-format.c (get_constant): Use tree_fits_uhwi_p.
3322 * c-lex.c: Include wide-int.h.
3323 (narrowest_unsigned_type): Take a widest_int rather than two
3324 HOST_WIDE_INTs.
3325 (narrowest_signed_type): Likewise.
3326 (interpret_integer): Update accordingly. Use wide-int interfaces.
3327 (lex_charconst): Use wide-int interfaces.
3328 * c-pretty-print.c: Include wide-int.h.
3329 (pp_c_integer_constant): Use wide-int interfaces.
3330 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
3331 INT_CST_LT_UNSIGNED.
3332
b15458be
RB
33332014-05-06 Richard Biener <rguenther@suse.de>
3334
3335 * c-opts.c (c_common_post_options): For -freestanding,
3336 -fno-hosted and -fno-builtin disable pattern recognition
3337 if not enabled explicitely.
3338
6577374e
MP
33392014-05-02 Marek Polacek <polacek@redhat.com>
3340
3341 * c.opt (Wsizeof-pointer-memaccess): Describe option.
3342
d00887e8
MP
33432014-05-01 Marek Polacek <polacek@redhat.com>
3344
3345 PR c/43245
3346 * c.opt (Wdiscarded-qualifiers): Add.
3347
f8ed5150
MP
33482014-04-30 Marek Polacek <polacek@redhat.com>
3349
3350 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
3351 INT_MIN / -1 sanitization only for integer types.
3352
45484dcf
MP
33532014-04-25 Marek Polacek <polacek@redhat.com>
3354
3355 PR c/18079
3356 * c-common.c (handle_noinline_attribute): Warn if the attribute
3357 conflicts with always_inline attribute.
3358 (handle_always_inline_attribute): Warn if the attribute conflicts
3359 with noinline attribute.
3360
38e514c0
MP
33612014-04-25 Marek Polacek <polacek@redhat.com>
3362
3363 PR c/60156
3364 * c-common.c (check_main_parameter_types): Warn about variadic main.
3365
44875f92
MS
33662014-04-24 Mike Stump <mikestump@comcast.net>
3367
3368 * c.opt (Wshadow-ivar): Default to on.
3369
dcaaa5a0
DP
33702014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
3371
3372 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
3373
c07d7c02
MP
33742014-04-23 Marek Polacek <polacek@redhat.com>
3375
3376 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
3377
1c33c9b7
JJ
33782014-04-22 Jakub Jelinek <jakub@redhat.com>
3379
3380 PR sanitizer/60275
3381 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
3382 if flag_sanitize_undefined_trap_on_error.
3383 (ubsan_instrument_division, ubsan_instrument_shift,
3384 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
3385 if !flag_sanitize_recover.
3386
793c625f
MG
33872014-04-22 Marc Glisse <marc.glisse@inria.fr>
3388
3389 PR libstdc++/43622
3390 * c-common.c (registered_builtin_types): Make non-static.
3391 * c-common.h (registered_builtin_types): Declare.
3392
b0f1bf36
RB
33932014-04-14 Richard Biener <rguenther@suse.de>
3394 Marc Glisse <marc.glisse@inria.fr>
3395
3396 PR c/60819
3397 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
3398 apply may-alias the scalar pointer type when applicable.
3399
3b07fa4a
IZ
34002014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
3401
3402 PR middle-end/60467
3403 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
3404 as possible argument for Cilk_spawn.
3405
cbbd2b1c
TB
34062014-04-11 Tobias Burnus <burnus@net-b.de>
3407
3408 PR c/60194
3409 * c.opt (Wformat-signedness): Add
3410 * c-format.c(check_format_types): Use it.
3411
6415bd5d
JM
34122014-04-11 Jason Merrill <jason@redhat.com>
3413
3414 PR c++/57926
3415 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
3416 default_conversion for an array argument.
3417
6525783a
MP
34182014-04-08 Marek Polacek <polacek@redhat.com>
3419
3420 PR sanitizer/60745
3421 * c-ubsan.c: Include asan.h.
3422 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
3423
880a467b
NS
34242014-04-03 Nathan Sidwell <nathan@codesourcery.com>
3425
3426 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
3427
7b59ff2d
MP
34282014-04-02 Marek Polacek <polacek@redhat.com>
3429
3430 * c-common.h (c_expand_expr): Remove declaration.
3431
8edbfaa6
JJ
34322014-03-28 Jakub Jelinek <jakub@redhat.com>
3433
3434 PR c++/60689
3435 * c-common.c (add_atomic_size_parameter): When creating new
3436 params vector, push the size argument first.
3437
07d72e1d
JJ
34382014-03-26 Jakub Jelinek <jakub@redhat.com>
3439
3440 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
3441 ubsan_instrument_vla, ubsan_instrument_return): Adjust
3442 ubsan_create_data callers.
3443
b35e0fa0
JJ
34442014-03-22 Jakub Jelinek <jakub@redhat.com>
3445
3446 PR debug/60603
3447 * c-opts.c (c_finish_options): Restore cb_file_change call to
3448 <built-in>.
3449
39a1ebb3
JJ
34502014-03-13 Jakub Jelinek <jakub@redhat.com>
3451
3452 PR middle-end/36282
3453 * c-pragma.c (apply_pragma_weak): Only look at
3454 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
3455 DECL_ASSEMBLER_NAME_SET_P (decl).
3456 (maybe_apply_pending_pragma_weaks): Exit early if
3457 vec_safe_is_empty (pending_weaks) rather than only when
3458 !pending_weaks.
3459 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
3460 set assembler name back to NULL afterwards.
3461
a07f6ed2
JM
34622014-03-11 Jason Merrill <jason@redhat.com>
3463
3464 * c.opt: Add -std=gnu++14.
3465
75b107f5
IB
34662014-03-11 Ian Bolton <ian.bolton@arm.com>
3467
3468 * c-opts.c (c_common_post_options): Don't override
3469 -ffp-contract=fast if unsafe-math-optimizations is on.
3470
f42c637e
PM
34712014-03-08 Paulo Matos <paulo@matos-sorge.com>
3472
3473 * c.opt: Enable LTO FE for fshort-double.
3474
70e24808
JM
34752014-03-07 Jason Merrill <jason@redhat.com>
3476
3477 * c.opt: Add -std=c++14.
3478
3af9c5e9
MP
34792014-03-06 Marek Polacek <polacek@redhat.com>
3480
3481 PR c/60197
3482 * cilk.c (contains_cilk_spawn_stmt): New function.
3483 (contains_cilk_spawn_stmt_walker): Likewise.
3484 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
3485 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
3486
b3bdf019
JJ
34872014-03-03 Jakub Jelinek <jakub@redhat.com>
3488
3489 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
3490 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
3491 even when flag_preprocess_only.
3492
ca7e759d
JM
34932014-02-26 Jason Merrill <jason@redhat.com>
3494
3495 PR c++/59231
3496 PR c++/11586
3497 * c-common.c (shorten_compare): Don't check
3498 c_inhibit_evaluation_warnings.
3499
28e41874
JJ
35002014-02-19 Jakub Jelinek <jakub@redhat.com>
3501
cca615af
JJ
3502 PR c/37743
3503 * c-common.c (c_common_nodes_and_builtins): When initializing
3504 c_uint{16,32,64}_type_node, also set corresponding
3505 uint{16,32,64}_type_node to the same value.
3506
28e41874
JJ
3507 PR c++/60267
3508 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
3509 for PRAGMA_IVDEP if flag_preprocess_only.
3510
c2bf53a1
JJ
35112014-02-12 Jakub Jelinek <jakub@redhat.com>
3512
3513 PR c/60101
3514 * c-common.c (merge_tlist): If copy is true, call new_tlist,
3515 if false, add ADD itself, rather than vice versa.
3516 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
3517 copy. For SAVE_EXPR, only call merge_tlist once.
3518
8fcbce72
JJ
35192014-02-08 Jakub Jelinek <jakub@redhat.com>
3520
3521 PR middle-end/60092
3522 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
3523 and tree_to_uhwi.
3524 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
3525 functions.
3526 (c_common_attribute_table): Add alloc_align and assume_aligned
3527 attributes.
3528
0a756a3f
MP
35292014-02-06 Marek Polacek <polacek@redhat.com>
3530
3531 PR c/60087
3532 * c-common.c (warn_for_sign_compare): Call warning_at with location
3533 instead of warning.
3534
7ec4847a
MP
35352014-02-05 Marek Polacek <polacek@redhat.com>
3536
3537 PR c/53123
3538 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
3539 statement.
3540
66f20604
MP
35412014-02-04 Marek Polacek <polacek@redhat.com>
3542
3543 PR c/60036
3544 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
3545 SAVE_EXPR.
3546
5d77fb19
MG
35472014-02-03 Marc Glisse <marc.glisse@inria.fr>
3548
3549 PR c++/53017
3550 PR c++/59211
3551 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
3552 handle_vector_size_attribute, handle_nonnull_attribute): Call
3553 default_conversion on the attribute argument.
3554 (handle_nonnull_attribute): Increment the argument number.
3555
81e5eca8
MP
35562014-01-31 Marek Polacek <polacek@redhat.com>
3557
3558 PR c/59963
3559 * c-common.c (add_atomic_size_parameter): Pass vNULL to
3560 build_function_call_vec.
3561 (resolve_overloaded_builtin): Likewise.
3562 * c-common.h (build_function_call_vec): Adjust declaration.
3563
68fca595
MP
35642014-01-30 Marek Polacek <polacek@redhat.com>
3565
3566 PR c/59940
3567 * c-common.h (unsafe_conversion_p): Adjust declaration.
3568 (warnings_for_convert_and_check): Likewise.
3569 (convert_and_check): Likewise.
3570 * c-common.c (unsafe_conversion_p): Add location parameter. Call
3571 expansion_point_location_if_in_system_header on it.
3572 (warnings_for_convert_and_check): Add location parameter. Call
3573 expansion_point_location_if_in_system_header on it. Use it.
3574 (convert_and_check): Add location parameter. Use it.
3575 (conversion_warning): Likewise.
3576 (c_add_case_label): Adjust convert_and_check calls.
3577 (scalar_to_vector): Adjust unsafe_conversion_p calls.
3578
b72271b9
BI
35792014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
3580
3581 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
3582 flag_cilkplus.
3583 * c-pragma.c (init_pragma): Likewise.
3584 * c.opt: Likewise.
3585
393e8e8b
MP
35862014-01-23 Marek Polacek <polacek@redhat.com>
3587
3588 PR c/59846
3589 * c-common.c (shorten_compare): Add location_t parameter.
3590 * c-common.h (shorten_binary_op): Adjust declaration.
3591
f04dda30
MP
35922014-01-23 Marek Polacek <polacek@redhat.com>
3593
3594 PR c/58346
3595 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
3596 * c-common.h: Declare it.
3597
621955cb
EB
35982014-01-20 Eric Botcazou <ebotcazou@adacore.com>
3599
3600 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
3601 * c-ada-spec.c (dump_ads): Likewise.
3602 (cpp_check): Likewise.
3603 (dump_ada_specs): Likewise.
3604
36052014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
67bf2939
LA
3606
3607 PR c++/49718
3608 * c-common.c (handle_no_instrument_function_attribute): Allow
3609 no_instrument_function attribute in class member
3610 definition/declaration.
3611
241f845a
JJ
36122014-01-15 Jakub Jelinek <jakub@redhat.com>
3613
3614 PR c/58943
3615 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
3616 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
3617 being COMPOUND_EXPR.
3618 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
3619 operand a SAVE_EXPR and second MODIFY_EXPR.
3620
e83b8e2e
JJ
36212014-01-09 Jakub Jelinek <jakub@redhat.com>
3622
3623 PR target/58115
3624 * c-pch.c (c_common_write_pch): Call
3625 prepare_target_option_nodes_for_pch.
3626
23a5b65a
RS
36272014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
3628
3629 Update copyright years
3630
f9030485
RS
36312014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
3632
3633 * array-notation-common.c, c-cilkplus.c: Use the standard form for
3634 the copyright notice.
3635
f2aa696b
EB
36362013-12-28 Eric Botcazou <ebotcazou@adacore.com>
3637
3638 * c-ada-spec.c (print_constructor): New function.
3639 (print_destructor): Retrieve the origin of the destructor.
3640 (print_ada_declaration): Revamp handling of constructors/destructors.
3641
3f8257db 36422013-12-23 Stuart Hastings <stuart@apple.com>
1f26ac87
JM
3643 Bill Maddox <maddox@google.com>
3644 Jason Merrill <jason@redhat.com>
3645
3646 * c.opt: Add -fdeclone-ctor-dtor.
3647 * c-opts.c (c_common_post_options): Default to on iff -Os.
3648
41958c28
BI
36492013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
3650
3651 * c-common.c (c_common_attribute_table): Added "cilk simd function"
3652 attribute.
3653 * c-pragma.h (enum pragma_cilk_clause): Remove.
3654 (enum pragma_omp_clause): Added the following fields:
3655 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
3656 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
3657 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
3658 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
3659 PRAGMA_CILK_CLAUSE_UNIFORM.
3660
b1726d6c 3661
12893402
BI
36622013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
3663
3664 * cilk.c (cilk_outline): Made this function non-static.
3665 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
3666 (create_cilk_wrapper): Added a new parameter: a function pointer.
3667 (c_install_body_w_frame_cleanup): Remove
3668 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
3669 * c-common.h (cilk_outline): New prototype.
3670 (gimplify_cilk_spawn): Removed two parameters.
3671 (cilk_install_body_with_frame_cleanup): New prototype.
3672 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
3673 CILK_SPAWN_STMT case.
3674
085b42ed
BS
36752013-12-11 Bernd Schmidt <bernds@codesourcery.com>
3676
2ce064c3
BS
3677 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
3678
085b42ed
BS
3679 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
3680 (int_array_type_node): Remove.
3681 * c-common.c (c_common_nodes_and_builtins): Don't build it.
3682
9e36c9ed
MP
36832013-12-05 Marek Polacek <polacek@redhat.com>
3684
3685 PR c/52023
3686 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
3687 [ADJUST_FIELD_ALIGN].
3688
296674db
JM
36892013-12-04 Joseph Myers <joseph@codesourcery.com>
3690
3691 PR c/52023
3692 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
3693 and check field alignment if set.
3694 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
3695 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
3696
b1726d6c 36972013-12-04 Jakub Jelinek <jakub@redhat.com>
31e071ae
MP
3698 Marek Polacek <polacek@redhat.com>
3699
3700 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
3701 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
3702
d7947e19
L
37032013-11-29 H.J. Lu <hongjiu.lu@intel.com>
3704
3705 PR c/59309
3706 * cilk.c (gimplify_cilk_spawn): Properly handle function without
3707 arguments.
3708
fad7652e
JJ
37092013-11-29 Jakub Jelinek <jakub@redhat.com>
3710
3711 PR c/59280
3712 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
3713 goto invalid. If it is error_mark_node, don't issue further
3714 diagnostics.
3715
8b5e1202
SO
37162013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
3717
3718 * c.opt (Wopenmp-simd): New.
3719
0a508bb6
JJ
37202013-11-22 Jakub Jelinek <jakub@redhat.com>
3721
3722 * c-ubsan.h (ubsan_instrument_return): New prototype.
3723 * c-ubsan.c (ubsan_instrument_return): New function.
3724
2fb9a547
AM
37252013-11-22 Andrew MacLeod <amacleod@redhat.com>
3726
3727 * c-common.c: Add required include files from gimple.h.
3728 * c-gimplify.c: Likewise
3729 * cilk.c: Likewise
3730
8400e75e
DM
37312013-11-22 David Malcolm <dmalcolm@redhat.com>
3732
3733 * c-common.c (unsafe_conversion_p): Remove use of
3734 EXPR_LOC_OR_HERE macro.
3735 (conversion_warning): Likewise.
3736 (warnings_for_convert_and_check): Likewise.
3737 (warn_for_collisions_1): Likewise.
3738 (shorten_compare): Likewise, and remove use of in_system_header
3739 macro, using the location from the former.
3740 * c-lex.c (dump_one_header): Remove use of input_filename macro.
3741 (cb_def_pragma): Remove use of in_system_header macro.
3742 (lex_string): Likewise.
3743 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
3744
eb1ce453
KZ
37452013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
3746 Mike Stump <mikestump@comcast.net>
3747 Richard Sandiford <rdsandiford@googlemail.com>
3748
3749 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
3750 instead of TREE_INT_CST_LOW, in cases where there is a protecting
3751 tree_fits_shwi_p or tree_fits_uhwi_p.
3752 (dump_generic_ada_node): Likewise.
3753 * c-format.c (check_format_arg): Likewise.
3754 * c-pretty-print.c (pp_c_integer_constant): Likewise.
3755
6b3b8c27
KZ
37562013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
3757
3758 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
3759
49b0aa18
JC
37602013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
3761
3762 PR c/53001
3763 * c-common.c (unsafe_conversion_p): Make this function
3764 return an enumeration with more detail.
3765 (conversion_warning): Use the new return type of
3766 unsafe_conversion_p to separately warn either about conversions
3767 that lower floating point number precision or about the other
3768 kinds of conversions.
3769 * c-common.h (enum conversion_safety): New enumeration.
3770 (unsafe_conversion_p): switching return type to
3771 conversion_safety enumeration.
3772 * c.opt: Adding new warning -Wfloat-conversion and
3773 enabling it with -Wconversion.
3774
b826515a
BS
37752013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
3776
3777 * c-opts.c: Include plugin.h.
3778 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
3779
b9a55b13
MP
37802013-11-19 Marek Polacek <polacek@redhat.com>
3781
3782 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
3783 call.
3784 (ubsan_instrument_shift): Likewise.
3785 (ubsan_instrument_vla): Likewise.
3786
7d362f6c
RS
37872013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3788
3789 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
3790 cast to unsigned type.
3791
386b1f1f
RS
37922013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3793
3794 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
3795 tree_low_cst.
3796 (complete_array_type): Update comment to refer to tree_to_[su]hwi
3797 rather than tree_low_cst.
3798
ae7e9ddd
RS
37992013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3800
3801 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
3802 tree_to_uhwi throughout.
3803
9439e9a1
RS
38042013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3805
3806 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
3807 tree_low_cst (..., 0) with tree_to_shwi throughout.
3808
cc269bb6
RS
38092013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3810
3811 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
3812 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
3813
9541ffee
RS
38142013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
3815
3816 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
3817 host_integerp (..., 0) with tree_fits_shwi_p throughout.
3818
c02065fc
AH
38192013-11-15 Aldy Hernandez <aldyh@redhat.com>
3820
3821 * c-cilkplus.c: New file.
3822 * c-common.c (readonly_error): Add location argument.
3823 * c-common.h (readonly_error): Same.
3824 (c_finish_cilk_clauses): Protoize.
3825 (c_check_cilk_loop): Same.
3826 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
3827 Do not fail on error_mark_node.
3828 Abstract increment canonicalization to here...
3829 (c_omp_for_incr_canonicalize_ptr): New.
3830 c-pragma.c (init_pragma): Register "simd" pragma.
3831 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
3832 (enum pragma_cilk_clause): New.
3833
9cc65f15
RS
38342013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
3835
3836 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
3837 wchar_type and host_integerp checks.
3838
18f429e2
AM
38392013-11-14 Andrew MacLeod <amacleod@redhat.com>
3840
3841 * c-common.c: Likewise.
3842 * c-gimplify.c: Likewise.
3843 * cilk.c: Likewise.
3844
d8a2d370
DN
38452013-11-14 Diego Novillo <dnovillo@google.com>
3846
3847 * c-common.c: Include fold-const.h.
3848 Include stor-layout.h.
3849 Include calls.h.
3850 Include stringpool.h.
3851 Include attribs.h.
3852 Include varasm.h.
3853 Include trans-mem.h.
3854 * c-cppbuiltin.c: Include stor-layout.h.
3855 Include stringpool.h.
3856 * c-format.c: Include stringpool.h.
3857 * c-lex.c: Include stringpool.h.
3858 Include stor-layout.h.
3859 * c-pragma.c: Include stringpool.h.
3860 Include attribs.h.
3861 Include varasm.h.
3862 Include gcc-symtab.h.
3863 * c-pretty-print.c: Include stor-layout.h.
3864 Include attribs.h.
3865 * cilk.c: Include stringpool.h.
3866 Include calls.h.
3867
38b7bc7f
JM
38682013-11-13 Joseph Myers <joseph@codesourcery.com>
3869
3870 * c-common.h (enum rid): Add RID_AUTO_TYPE.
3871 * c-common.c (c_common_reswords): Add __auto_type.
3872 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
3873
45b0be94
AM
38742013-11-12 Andrew MacLeod <amacleod@redhat.com>
3875
18f429e2
AM
3876 * c-common.c: Include gimplify.h.
3877 * c-gimplify.c: Likewise.
3878 * cilk.c: Likewise.
3879 * c-omp.c: Include gimple-expr.h instead of gimple.h.
3880 * c-ubsan.c: Don't include gimple.h.
45b0be94 3881
582d9b50
JM
38822013-11-12 Joseph Myers <joseph@codesourcery.com>
3883
3884 * c-common.c (c_common_reswords): Add _Thread_local.
3885
6b28e197
JM
38862013-11-09 Joseph Myers <joseph@codesourcery.com>
3887
3888 * c-common.c (atomic_size_supported_p): New function.
3889 (resolve_overloaded_atomic_exchange)
3890 (resolve_overloaded_atomic_compare_exchange)
3891 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
3892 Use it instead of comparing size with a local list of sizes.
3893
267bac10
JM
38942013-11-07 Andrew MacLeod <amacleod@redhat.com>
3895 Joseph Myers <joseph@codesourcery.com>
3896
3897 * c-common.h (enum rid): Add RID_ATOMIC.
3898 * c-common.c (c_common_reswords): Add _Atomic.
3899 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
3900 (keyword_is_type_qualifier): Accept RID_ATOMIC.
3901 * c-format.c (check_format_types): Check for extra _Atomic
3902 qualifiers in format argument.
3903 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
3904 (pp_c_type_qualifier_list): Mention _Atomic in comment.
3905
5157b91e
TB
39062013-11-06 Tobias Burnus <burnus@net-b.de>
3907
3908 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
3909
6dbe0958
JM
39102013-11-06 Joseph Myers <joseph@codesourcery.com>
3911
3912 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
3913 standards modes.
3914 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
3915 to mean lack of IEEE 754 support.
3916
e8ff5196
TB
39172013-11-05 Tobias Burnus <burnus@net-b.de>
3918
3919 * c.opt (-Wdate-time): New option
3920 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
3921
254a0760
JM
39222013-11-05 Joseph Myers <joseph@codesourcery.com>
3923
3924 * c-cppbuiltin.c (cpp_iec_559_value): Test
3925 flag_excess_precision_cmdline not flag_excess_precision.
3926
6d7f7e0a
TB
39272013-11-05 Tobias Burnus <burnus@net-b.de>
3928
3929 * c.opt (fopenmp-simd): New option.
3930 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
3931 (omp_pragmas): ... this new struct.
3932 (c_pp_lookup_pragma): Also walk omp_pragmas.
3933 (init_pragma): Init pragmas for -fopenmp-simd.
3934
55a7f02f
MP
39352013-11-04 Marek Polacek <polacek@redhat.com>
3936
3937 PR c++/58979
3938 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
3939
9193fb05
JM
39402013-11-04 Joseph Myers <joseph@codesourcery.com>
3941
3942 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
3943 New functions.
3944 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
3945
94159ecf
EB
39462013-11-04 Eric Botcazou <ebotcazou@adacore.com>
3947
3948 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
3949 (dump_ada_specs): Adjust prototype of second callback.
3950 * c-ada-spec.c (cpp_check): New global variable.
3951 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
3952 (print_generic_ada_decl): Likewise.
3953 (has_static_fields): Change return type to bool and add guard.
3954 (has_nontrivial_methods): New predicate.
3955 (is_tagged_type): Change return type to bool.
3956 (separate_class_package): Call has_nontrivial_methods.
3957 (pp_ada_tree_identifier): Minor tweaks.
3958 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
3959 (dump_ada_array_domains): Likewise.
3960 (dump_ada_array_type): Likewise.
3961 (dump_template_types): Remove cpp_check parameter and do not pass it to
3962 dump_generic_ada_node.
3963 (dump_ada_template): Likewise.
3964 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
3965 recursively.
3966 (print_ada_methods): Change return type to integer. Remove cpp_check
3967 parameter and do not pass it down.
3968 (dump_nested_types): Remove cpp_check parameter and do not pass it to
3969 dump_generic_ada_node.
3970 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
3971 accessing methods.
3972 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
3973 down. Use has_nontrivial_methods to recognize C++ classes. Use return
3974 value of print_ada_methods.
3975 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
3976 Set cpp_check to it before invoking dump_ada_nodes.
3977 (dump_ada_specs): Likewise.
3978
b906f4ca
MP
39792013-11-03 Marek Polacek <polacek@redhat.com>
3980
3981 * c-ubsan.c: Don't include hash-table.h.
3982 (ubsan_instrument_vla): New function.
3983 * c-ubsan.h: Declare it.
3984
5e20cdc9
DM
39852013-10-31 David Malcolm <dmalcolm@redhat.com>
3986
3987 Automated part of renaming of symtab_node_base to symtab_node.
3988
3989 Patch autogenerated by rename_symtab.py from
3990 https://github.com/davidmalcolm/gcc-refactoring-scripts
3991 revision 58bb219cc090b2f4516a9297d868c245495ee622
3992
3993 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
3994 symtab_node_base to symtab_node.
3995
7057e645
ESR
39962013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
3997
3998 Implement C++14 digit separators.
3999 * c-lex.c (interpret_float): Remove digit separators from scratch string
4000 before building real literal.
4001
193ea7bc
JJ
40022013-10-30 Jakub Jelinek <jakub@redhat.com>
4003
4004 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
4005
939b37da
BI
40062013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
4007
4008 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
4009 fields.
4010 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
4011 enabled.
4012 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
4013 (insert_cilk_frame): New prototype.
4014 (cilk_init_builtins): Likewise.
4015 (gimplify_cilk_spawn): Likewise.
4016 (c_cilk_install_body_w_frame_cleanup): Likewise.
4017 (cilk_detect_spawn_and_unwrap): Likewise.
4018 (cilk_set_spawn_marker): Likewise.
4019 (build_cilk_sync): Likewise.
4020 (build_cilk_spawn): Likewise.
4021 * cilk.c: New file.
4022
67348ccc
DM
40232013-10-29 David Malcolm <dmalcolm@redhat.com>
4024
4025 Patch autogenerated by refactor_symtab.py from
4026 https://github.com/davidmalcolm/gcc-refactoring-scripts
4027 revision 58bb219cc090b2f4516a9297d868c245495ee622
4028
4029 * c-gimplify.c (c_genericize): Update for conversion of symtab types
4030 to a true class hierarchy.
4031 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
4032
d570872d
RS
40332013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
4034
4035 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
4036
98906124
JL
40372013-10-26 Jeff Law <law@redhat.com>
4038
adfac8df
JJ
4039 * c-common.c (c_define_builtins): Remove mudflap support.
4040 * c.opt: Ignore and warn for mudflap options.
98906124 4041
d73749df 40422013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
4043
4044 PR other/33426
4045 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
4046 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
4047
3f04b1bb
JM
40482013-10-23 Jason Merrill <jason@redhat.com>
4049
4050 * c-format.c (gcc_cxxdiag_char_table): Add %X.
4051
acf0174b
JJ
40522013-10-11 Jakub Jelinek <jakub@redhat.com>
4053
acd15a28
JJ
4054 * c-common.h (omp_clause_mask::operator !=): New method.
4055 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
4056 instead of if (mask & something) tests everywhere.
4057
acf0174b
JJ
4058 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
4059 201307 instead of 201107.
4060 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
4061 (c_common_attribute_table): Add "omp declare target" and
4062 "omp declare simd" attributes.
4063 (handle_omp_declare_target_attribute,
4064 handle_omp_declare_simd_attribute): New functions.
4065 * c-omp.c: Include c-pragma.h.
4066 (c_finish_omp_taskgroup): New function.
4067 (c_finish_omp_atomic): Add swapped argument, if true,
4068 build the operation first with rhs, lhs arguments and use NOP_EXPR
4069 build_modify_expr.
4070 (c_finish_omp_for): Add code argument, pass it down to make_code.
4071 (c_omp_split_clauses): New function.
4072 (c_split_parallel_clauses): Removed.
4073 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
4074 c_omp_declare_simd_clauses_to_decls): New functions.
4075 * c-common.h (omp_clause_mask): New type.
4076 (OMP_CLAUSE_MASK_1): Define.
4077 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
4078 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
4079 omp_clause_mask::operator |, omp_clause_mask::operator &,
4080 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
4081 omp_clause_mask::operator ==): New methods.
4082 (enum c_omp_clause_split): New.
4083 (c_finish_omp_taskgroup): New prototype.
4084 (c_finish_omp_atomic): Add swapped argument.
4085 (c_finish_omp_for): Add code argument.
4086 (c_omp_split_clauses): New prototype.
4087 (c_split_parallel_clauses): Removed.
4088 (c_omp_declare_simd_clauses_to_numbers,
4089 c_omp_declare_simd_clauses_to_decls): New prototypes.
4090 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
4091 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
4092 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
4093 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
4094 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
4095 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
4096 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
4097 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
4098 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
4099 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
4100 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
4101 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
4102 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
4103 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
4104 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
4105 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
4106 PRAGMA_OMP_CLAUSE_UNIFORM.
4107
826cacfe
MG
41082013-10-09 Marc Glisse <marc.glisse@inria.fr>
4109
4110 PR tree-optimization/20318
4111 * c-common.c (handle_returns_nonnull_attribute): New function.
4112 (c_common_attribute_table): Add returns_nonnull.
4113
2284b034
MG
41142013-10-03 Marc Glisse <marc.glisse@inria.fr>
4115
4116 PR c++/19476
4117 * c.opt (fcheck-new): Move to common.opt.
4118
b56e9788
MP
41192013-09-25 Marek Polacek <polacek@redhat.com>
4120 Jakub Jelinek <jakub@redhat.com>
4121
4122 PR sanitizer/58413
4123 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
4124 an expression if we can prove it is correct.
4125 (ubsan_instrument_division): Likewise. Remove unnecessary
4126 check.
4127
ce6923c5
MP
41282013-09-18 Marek Polacek <polacek@redhat.com>
4129
4130 PR sanitizer/58411
4131 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
4132 Declare it.
4133 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
4134
fb5610fb
IS
41352013-09-14 Iain Sandoe <iain@codesourcery.com>
4136
4137 PR target/48094
4138 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
4139 fobjc-gc, freplace-objc-classes): Accept for LTO.
4140
88b0e79e
JC
41412013-09-13 Jacek Caban <jacek@codeweavers.com>
4142
4143 * c-target.def: New hook
4144
c9b0866a
PC
41452013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
4146
4147 PR c++/43452
4148 * c.opt (Wdelete-incomplete): Add.
4149
0af94e6f
JR
41502013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
4151
4152 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
4153 (vector_types_compatible_elements_p): New function.
4154 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
4155 declaration.
4156 (vector_types_compatible_elements_p): Declare.
4157
7c26172c
GDR
41582013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
4159
4160 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
4161 a virtual member function.
4162 (pp_simple_type_specifier): Remove.
4163 (pp_c_type_specifier): Likewise.
4164 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
4165 Rename from pp_c_type_specifier. Adjust.
4166 (c_pretty_printer::c_pretty_printer): Do not assign to
4167 simple_type_specifier.
4168
20059c8b
GDR
41692013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
4170
4171 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
4172 member function.
4173 (c_pretty_printer::storage_class_specifier): Likewise.
4174 (c_pretty_printer::initializer): Likewise.
4175 (pp_declaration): Remove.
4176 (pp_declaration_specifiers): Likewise.
4177 (pp_abstract_declarator): Likewise.
4178 (pp_declarator): Likewise.
4179 (pp_type_id): Likewise.
4180 (pp_statement): Likewise.
4181 (pp_constant): Likewise.
4182 (pp_id_expression): Likewise.
4183 (pp_primary_expression): Likewise.
4184 (pp_unary_expression): Likewise.
4185 (pp_multiplicative_expression): Likewise.
4186 (pp_conditional_expression): Likewise.
4187 (pp_assignment_expression): Likewise.
4188 (pp_expression): Likewise.
4189 (pp_c_type_id): Likewise.
4190 (pp_c_storage_class_specifier): Likewise.
4191 * c-pretty-print.c (pp_c_type_cast): Tidy.
4192 (pp_c_pointer): Likewise.
4193 (pp_c_type_specifier): Likewise.
4194 (pp_c_parameter_type_list): Likewise.
4195 (pp_c_function_definition): Likewise.
4196 (pp_c_init_declarator): Likewise.
4197 (pp_c_initializer_list): Likewise.
4198 (pp_c_constructor_elts): Likewise.
4199 (c_pretty_printer::direct_abstract_declarator): Likewise.
4200 (c_pretty_printer::declaration_specifiers): Likewise.
4201 (c_pretty_printer::primary_expression): Likewise.
4202 (c_pretty_printer::postfix_expression): Likewise.
4203 (c_pretty_printer::type_id): Rename from pp_c_type_id.
4204 (c_pretty_printer::storage_class_specifier): Rename from
4205 pp_c_storage_class_specifier.
4206 (c_pretty_printer::initializer): Rename from pp_c_initializer.
4207 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
4208 storage_class_specifier, initializer, offset_list, flags.
4209
de5a5fa1
MP
42102013-08-30 Marek Polacek <polacek@redhat.com>
4211
4212 * c-ubsan.c: New file.
4213 * c-ubsan.h: New file.
4214
8f0e4d72
GDR
42152013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
4216
4217 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
4218 member function.
4219 (c_pretty_printer::declaration_specifiers): Likewise.
4220 (c_pretty_printer::declarator): Likewise.
4221 (c_pretty_printer::abstract_declarator): Likewise.
4222 (c_pretty_printer::direct_abstract_declarator): Likewise.
4223 (c_pretty_printer::direct_declarator): Likewise.
4224 (c_pretty_printer::function_specifier): Likewise.
4225 (pp_declaration): Adjust.
4226 (pp_declaration_specifiers): Likewise.
4227 (pp_abstract_declarator): Likewise.
4228 (pp_direct_declarator): Likewise.
4229 (pp_function_specifier): Likewise.
4230 (pp_direct_abstract_declarator): Remove as unused.
4231 (pp_c_declaration): Remove.
4232 (pp_c_declaration_specifiers): Likewise.
4233 (pp_c_declarator): Likewise.
4234 (pp_c_direct_declarator): Likewise.
4235 (pp_c_function_specifier): Likewise.
4236 (pp_c_direct_abstract_declarator): Likewise.
4237 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
4238 from pp_c_abstract_declarator. Adjust.
4239 (c_pretty_printer::direct_abstract_declarator): Rename from
4240 pp_c_direct_abstract_declarator. Adjust.
4241 (c_pretty_printer::function_specifier): Rename from
4242 pp_c_function_specifier. Adjust.
4243 (c_pretty_printer::declaration_specifiers): Rename from
4244 pp_c_declaration_specifiers. Adjust.
4245 (c_pretty_printer::direct_declarator): Rename from
4246 pp_c_direct_declarator. Adjust.
4247 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
4248 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
4249 (c_pretty_printer::c_pretty_printer): Do not assign to
4250 declaration, declaration_specifiers, declarator,
4251 direct_declarator, direct_abstract_declarator, function_specifier.
4252
00d34d3a
GDR
42532013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
4254
4255 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
4256 virtual member function.
4257 (c_pretty_printer::multiplicative_expression): Likewise.
4258 (c_pretty_printer::conditional_expression): Likewise.
4259 (c_pretty_printer::assignment_expression): Likewise.
4260 (c_pretty_printer::expression): Likewise.
4261 (pp_unary_expression): Adjust.
4262 (pp_multiplicative_expression): Likewise.
4263 (pp_assignment_expression): Likewise.
4264 (pp_conditional_expression): Likewise.
4265 (pp_expression): Likewise.
4266 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
4267 from pp_c_unary_expression. Adjust.
4268 (c_pretty_printer::multiplicative_expression): Rename from
4269 pp_c_multiplicative_expression. Adjust.
4270 (c_pretty_printer::conditional_expression): Rename from
4271 pp_c_conditional_expression. Adjust.
4272 (c_pretty_printer::assignment_expression): Rename from
4273 pp_c_assignment_expression. Adjust.
4274 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
4275 (c_pretty_printer::c_pretty_printer): Do not assign to
4276 unary_expression, multiplicative_expression,
4277 conditional_expression, expression.
4278
fb22178f
GDR
42792013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
4280
4281 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
4282 virtual member function.
4283 (pp_postfix_expression): Adjust.
4284 (pp_c_postfix_expression): Remove.
4285 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
4286 from pp_c_postfix_expression. Adjust.
4287 (c_pretty_printer::c_pretty_printer): Do not assign to
4288 postfix_expression.
4289
7ecc2600
GDR
42902013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
4291
4292 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
4293 virtua member function.
4294 (pp_primary_expression): Adjust.
4295 (pp_c_primary_expression): Remove.
4296 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
4297 from pp_c_primary_expression. Adjust.
4298 (pp_c_initializer_list): Use pp_primary_expression.
4299 (c_pretty_printer::c_pretty_printer): Do not assign to
4300 primary_expression.
4301
0691175f
GDR
43022013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
4303
4304 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
4305 * c-pretty-print.c (M_): Remove.
4306 (c_pretty_printer::translate_string): Define.
4307 (pp_c_type_specifier): Use it.
4308 (pp_c_primary_expression): Likewise.
4309 (pp_c_expression): Likewise.
4310
66dfe4c4
GDR
43112013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
4312
4313 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
4314 virtual function.
4315 (pp_c_id_expression): Remove.
4316 (pp_id_expression): Adjust.
4317 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
4318 pp_c_id_expression. Adjust.
4319 (pp_c_postfix_expression): Use pp_id_expression.
4320 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
4321
ca43e9d5
GDR
43222013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
4323
4324 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
4325 member function.
4326 (pp_constant): Adjust.
4327 (pp_c_constant): Remove.
4328 * c-pretty-print.c (c_pretty_printer::constant): Rename from
4329 pp_c_constant. Adjust.
4330 (pp_c_constant)
4331 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
4332 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
4333
da6ca2b5
GDR
43342013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
4335
4336 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
4337 (c_pretty_printer::c_pretty_printer): Declare.
4338 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
4339 c_pretty_printer_init. Adjust.
4340 (print_c_tree): Do not call c_pretty_printer_init.
4341 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
4342
65a372f4
AC
43432013-08-09 Arnaud Charlet <charlet@adacore.com>
4344
4345 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
4346
fd9b0f32
PC
43472013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
4348
4349 PR c++/58080
4350 * c-common.c (pointer_int_sum): Add bool parameter.
4351 * c-common.h (pointer_int_sum): Adjust declaration.
4352
e0aec1e9
GDR
43532013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
4354
4355 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
4356 c_pretty_printer variable.
4357
b066401f
GDR
43582013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
4359
4360 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
4361 (pp_base): Remove.
4362 (pp_c_base): Likewise. Adjust users.
4363 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
4364 (pp_c_whitespace): Do not call pp_base.
4365 (pp_c_left_paren): Likewise.
4366 (pp_c_right_paren): Likewise.
4367 (pp_c_left_brace): Likewise.
4368 (pp_c_right_brace): Likewise.
4369 (pp_c_left_bracket): Likewise.
4370 (pp_c_right_bracket): Likewise.
4371 (pp_c_dot): Likewise.
4372 (pp_c_ampersand): Likewise.
4373 (pp_c_star): Likewise.
4374 (pp_c_arrow): Likewise.
4375 (pp_c_semicolon): Likewise.
4376 (pp_c_complement): Likewise.
4377 (pp_c_exclamation): Likewise.
4378 (pp_c_direct_declarator): Likewise.
4379 (pp_c_ws_string): Likewise.
4380 (pp_c_identifier): Likewise.
4381 (pp_c_statement): Likewise.
4382 (print_c_tree): Likewise.
4383
65e5a578
ESR
43842013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
4385
4386 PR c++/58072
4387 * c-common.c (c_parse_error): Catch user-defined literal tokens and
4388 provide useful error strings.
4389
137a1a27
GDR
43902013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
4391
4392 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
4393 printer functions instead of pp_string or operators and punctuators.
4394 (dump_generic_ada_node): Likewise.
4395 * c-pretty-print.c (pp_c_type_specifier): Likewise.
4396 (pp_c_relational_expression): Likewise.
4397 (pp_c_logical_or_expression): Likewise.
4398
07838b13
GDR
43992013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
4400
4401 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
4402 functions instead of pp_character.
4403 (pp_ada_tree_identifier): Likewise.
4404 (dump_ada_double_name): Likewise.
4405 (dump_ada_function_declaration): Likewise.
4406 (dump_ada_array_domains): Likewise.
4407 (dump_template_types): Likewise.
4408 (dump_generic_ada_node): Likewise.
4409 (print_ada_declaration): Likewise.
4410 (print_ada_struct_decl): Likewise.
4411 * c-pretty-print.c (pp_c_integer_constant): Likewise.
4412
433cc7b0
TT
44132013-07-23 Tom Tromey <tromey@redhat.com>
4414
4415 * c-common.h (enum rid) <RID_GENERIC>: New constant.
4416 * c-common.c (c_common_reswords): Add _Generic.
4417
688010ba
OB
44182013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
4419
4420 * c-common.c: Fix typos.
4421 * c-common.h: Likewise.
4422
2a99e5e6
LL
44232013-07-13 Lubos Lunak <l.lunak@suse.cz>
4424
4425 PR c++/55203
4426 * c-common.c (c_common_attribute_table): Add warn_unused.
4427 (handle_warn_unused_attribute): New.
4428
c26302d5
JJ
44292013-07-10 Jakub Jelinek <jakub@redhat.com>
4430
4431 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
4432 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
4433
dfeadaa0
PC
44342013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
4435
4436 PR c++/57869
4437 * c.opt: Add Wconditionally-supported.
4438
6a2fa4b2
GS
44392013-07-08 Graham Stott <graham.stott@btinternet.com>
4440
adfac8df 4441 * array-notation-common.c (length_mismatch_in_expr_p): Delete
6a2fa4b2
GS
4442 unused variables l_length and l_node.
4443
ecdbd01a 44442013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
4445
4446 PR c/57821
4447 * c-common.c (complete_array_type): Delay folding first index
4448 like other indices. When folding, check for index overflow.
4449
bedc293e
MG
44502013-06-27 Marc Glisse <marc.glisse@inria.fr>
4451
4452 PR c++/57509
4453 * c-common.h (c_build_vec_perm_expr): New complain argument.
4454 * c-common.c (c_build_vec_perm_expr): Likewise.
4455 Use save_expr also in C++.
4456
604b2bfc
GDR
44572013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
4458
4459 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
4460 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
4461 * c-opts.c (c_common_post_options): Likewise.
4462
dfeadaa0 44632013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
713b46fa
BI
4464
4465 * array-notation-common.c (length_mismatch_in_expr): Changed the
4466 parameter type's from a dynamic array to a vec_tree. Also removed
4467 the size parameters.
4468 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
4469 the change above.
4470
2ce86d2e
BI
44712013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
4472
4473 * c-common.h (struct cilkplus_an_parts): New structure.
4474 (struct cilkplus_an_loop_parts): Likewise.
4475 (cilkplus_extract_an_triplets): New prototype.
4476 (fix_sec_implicit_args): Likewise.
4477 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
4478 (fix_sec_implicit_args): Likewise.
604b2bfc 4479
07a6825b
BI
44802013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
4481
4482 * array-notation-common.c (find_inv_trees): Removed an unwanted
4483 typecasting.
4484 * c-common.h (struct inv_list::additional_tcodes): Changed type from
4485 enum rid to enum tree_code.
4486
08346abd
JH
44872013-06-11 Jan Hubicka <jh@suse.cz>
4488
4489 * c-common.c (handle_alias_ifunc_attribute): Do not set
4490 DECL_EXTERNAL for weakref variables.
4491 * c-pragma.c (handle_pragma_weak): Make sure aliases
4492 are not declared as external.
4493
d60f1706
BI
44942013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
4495
4496 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
4497 function from c/c-array-notation.c.
4498 (is_cilkplus_reduce_builtin): Likewise.
4499 (find_rank): Likewise.
4500 (extract_array_notation_exprs): Likewise.
4501 (replace_array_notations): Likewise.
4502 (find_inv_trees): Likewise.
4503 (replace_inv_trees): Likewise.
4504 (contains_array_notation_expr): Likewise.
4505 (find_correct_array_notation_type): Likewise.
4506 * c-common.h (struct inv_list): Moved this struct from the file
4507 c/c-array-notation.c and added a new field called additional tcodes.
4508 (length_mismatch_in_expr_p): New prototype.
4509 (is_cilkplus_reduce_builtin): Likewise.
4510 (find_rank): Likewise.
4511 (extract_array_notation_exprs): Likewise.
4512 (replace_array_notation): Likewise.
4513 (find_inv_trees): Likewise.
4514 (replace_inv_trees): Likewise.
4515 (find_correct_array_notation_type): Likewise.
dfeadaa0 4516
36536d79
BI
45172013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
4518
4519 * c-common.c (c_define_builtins): When cilkplus is enabled, the
4520 function array_notation_init_builtins is called.
4521 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
4522 * c-common.def (ARRAY_NOTATION_REF): New tree.
4523 * c-common.h (build_array_notation_expr): New function declaration.
4524 (build_array_notation_ref): Likewise.
4525 (extract_sec_implicit_index_arg): New extern declaration.
4526 (is_sec_implicit_index_fn): Likewise.
4527 (ARRAY_NOTATION_CHECK): New define.
4528 (ARRAY_NOTATION_ARRAY): Likewise.
4529 (ARRAY_NOTATION_START): Likewise.
4530 (ARRAY_NOTATION_LENGTH): Likewise.
4531 (ARRAY_NOTATION_STRIDE): Likewise.
4532 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
4533 ARRAY_NOTATION_REF.
4534 (pp_c_expression): Likewise.
4535 * c.opt (flag_enable_cilkplus): New flag.
4536 * array-notation-common.c: New file.
4537
f7716d57
JJ
45382013-05-14 Jakub Jelinek <jakub@redhat.com>
4539
4540 PR c++/57274
4541 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
4542
a5e0cd1d
MG
45432013-05-10 Marc Glisse <marc.glisse@inria.fr>
4544
4545 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
4546 vectors.
4547
f6bc1c4a
HS
45482013-05-07 Han Shen <shenhan@google.com>
4549
4550 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
4551
3f12f6e9
SKS
45522013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
4553
4554 * c-common.c (check_user_alignment): Emit error for negative values.
4555
61949153
PC
45562013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
4557
4558 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
4559
e93e18e9
PC
45602013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
4561
4562 * c-cppbuiltin.c (c_cpp_builtins): Do not define
4563 __GXX_EXPERIMENTAL_CXX1Y__.
4564
44d90fe1
PC
45652013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
4566 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
4567
4568 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
4569 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
4570 to simply use OPT_Wpointer_arith.
4571 (c_sizeof_or_alignof_type): Likewise.
4572
13f39b2e
PC
45732013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
4574
4575 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
4576
4b84d650
JJ
45772013-04-12 Jakub Jelinek <jakub@redhat.com>
4578
4579 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
4580 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
4581 specifiers.
4582
fb037b5d
SB
45832013-04-07 Steven Bosscher <steven@gcc.gnu.org>
4584
4585 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
4586
4e856798
PC
45872013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
4588
4589 * c-common.c (pointer_int_sum): Remove dead code.
4590
4b1baac8
RS
45912013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
4592
4593 PR middle-end/56524
4594 * c-common.c (handle_optimize_attribute): Don't call
4595 save_optabs_if_changed.
4596
0b50e654
JJ
45972013-03-05 Jakub Jelinek <jakub@redhat.com>
4598
4599 PR middle-end/56461
4600 * c-pch.c (pch_init): Free target_validity at the end.
4601
48c41403
JJ
46022013-03-04 Jakub Jelinek <jakub@redhat.com>
4603
4604 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
4605
e664c61c
KS
46062013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
4607 Jakub Jelinek <jakub@redhat.com>
4608
4609 PR sanitizer/56454
4610 * c-common.c (handle_no_sanitize_address_attribute): New function.
4611 (c_common_attribute_table): Add no_sanitize_address attribute.
4612 (handle_no_address_safety_analysis_attribute): Add
4613 no_sanitize_address attribute, not no_address_safety_analysis
4614 attribute.
4615
a475fd3d 46162013-02-18 Aldy Hernandez <aldyh@redhat.com>
135204dd
AH
4617
4618 PR target/52555
4619 * c-common.c (handle_optimize_attribute): Call
4620 save_optabs_if_changed.
4621
f6007d99
JJ
46222013-02-18 Jakub Jelinek <jakub@redhat.com>
4623 Steven Bosscher <steven@gcc.gnu.org>
4624
4625 PR pch/54117
4626 * c-opts.c (c_common_post_options): If debug info is enabled
4627 and non-dwarf*, refuse to load PCH files and when writing PCH
4628 file warn.
4629
cf35e2b1
JJ
46302013-02-05 Jakub Jelinek <jakub@redhat.com>
4631
4632 PR middle-end/56167
4633 * c-common.c (handle_error_attribute): Fix condition.
4634
32887460
JJ
46352013-01-30 Jakub Jelinek <jakub@redhat.com>
4636
4637 PR c++/55742
4638 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
4639
5af057d8
JM
46402013-01-18 Jason Merrill <jason@redhat.com>
4641
4642 PR target/54908
4643 * c.opt (-fextern-tls-init): New.
4644 * c-opts.c (c_common_post_options): Handle it.
4645
cc83c823
JJ
46462013-01-09 Jakub Jelinek <jakub@redhat.com>
4647
4648 PR c/48418
4649 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
4650 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
4651 and is either negative or bigger or equal to type precision
4652 of the first operand.
4653
a859517f
MP
46542012-12-03 Marek Polacek <polacek@redhat.com>
4655
4656 PR c/55570
4657 * c-common.c (check_user_alignment): Swap order of tests,
4658 check TREE_CODE first.
4659
2d7aa578
ESR
46602012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
4661
4662 PR c++/52654
4663 * c-common.h (overflow_type): New enum.
4664 (build_userdef_literal): Add overflow_type argument.
4665 (tree_userdef_literal): Add overflow_type.
4666 (USERDEF_LITERAL_OVERFLOW): New access macro.
4667 * c-common.c (build_userdef_literal): Add overflow_type
4668 argument.
4669 * c-lex.c (c_lex_with_flags): Add overflow_type to
4670 build_userdef_literal calls.
4671 (interpret_integer, interpret_float): Add overflow_type argument.
4672
cc3c4f62
RB
46732012-11-28 Richard Biener <rguenther@suse.de>
4674
4675 PR c/35634
4676 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
4677 here and use a type with proper overflow behavior for types that would
4678 need to be promoted for the arithmetic.
4679
77bc5132
JJ
46802012-11-23 Jakub Jelinek <jakub@redhat.com>
4681
4682 PR sanitizer/55435
4683 * c-common.c (handle_no_address_safety_analysis_attribute): New
4684 function.
4685 (c_common_attribute_table): Add no_address_safety_analysis.
4686
5dc99c46
SB
46872012-11-16 Simon Baldwin <simonb@google.com>
4688
4689 * c.opt: Add f[no-]canonical-system-headers.
4690 * c-opts.c (c_common_handle_option): Handle
4691 OPT_fcanonical_system_headers.
4692
a4a0016d
ESR
46932012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
4694
4695 PR c++/54413
4696 * c-opts.c (c_common_handle_option): Set new flags.
4697 * c.opt: Describe new flags.
4698
7dbb85a7
JM
46992012-11-09 Jason Merrill <jason@redhat.com>
4700
4701 * c.opt (Wabi-tag): New.
4702
ad7bac31
AK
47032012-11-09 Andi Kleen <ak@linux.intel.com>
4704
4705 PR 55139
4706 * c-common.c (get_atomic_generic_size): Mask with
4707 MEMMODEL_MASK
4708
7332899a
MLI
47092012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
4710
4711 PR c/53063
4712 * c.opt (Wformat): Make it Alias Wformat=1.
4713 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
4714 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
4715 LangEnabledBy.
4716 (Wformat=): RejectNegative. Use LangEnabledBy.
4717 (Wnonnull): Use LangEnabledBy.
4718 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
4719 * c-format.c (set_Wformat): Delete.
4720 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
4721 (maybe_read_dollar_number): Likewise.
4722 (avoid_dollar_number): Likewise.
4723 (finish_dollar_format_checking): Likewise.
4724 (check_format_info): Likewise.
4725 (check_format_info_main): Likewise.
4726 (check_format_types): Likewise.
4727 (format_type_warning): Likewise.
4728 * c-common.c (int): Likewise.
4729 (check_function_sentinel): Likewise.
4730 * c-common.h (warn_format,set_Wformat): Do not declare here.
4731
34a180a6
MLI
47322012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
4733
4734 PR c/53063
4735 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
4736 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
4737 Use LangEnabledBy.
4738 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
4739 common.opt.
4740 (Wvariadic-macros): Init(1).
4741 * c-opts.c (c_common_handle_option): Do not handle them
4742 explicitly.
4743 (c_common_post_options): Likewise.
4744 (sanitize_cpp_opts): warn_unused_macros is now
4745 cpp_warn_unused_macros.
4746 (push_command_line_include): Likewise.
4747 * c-common.c (warn_unknown_pragmas): Do not define.
4748 * c-common.h (warn_unknown_pragmas): Do not declare.
4749
3f46d6a5
MLI
47502012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
4751
4752 PR c/51294
4753 * c-common.c (conversion_warning): Handle conditional expressions.
4754
880661a4
JW
47552012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
4756
4757 PR c++/54930
4758 * c.opt (Wreturn_local_addr): Define new option.
4759
4514a96b
JM
47602012-10-25 Jason Merrill <jason@redhat.com>
4761
f14edc1a
JM
4762 * c.opt (Wvirtual-move-assign): New.
4763
4514a96b
JM
4764 * c.opt (Winherited-variadic-ctor): New.
4765
93100c6b
MG
47662012-10-25 Marc Glisse <marc.glisse@inria.fr>
4767
4768 PR c++/54427
4769 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
4770
1efcb8c6
JM
47712012-10-23 Joseph Myers <joseph@codesourcery.com>
4772
4773 * c-common.h (pch_cpp_save_state): Declare.
4774 * c-target.def (c_preinclude): New hook.
4775 * c-opts.c (done_preinclude): New.
4776 (push_command_line_include): Handle default preincluded header.
4777 (cb_file_change): Call pch_cpp_save_state when calling
4778 push_command_line_include.
4779 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
4780 (pch_cpp_save_state): New.
4781 (pch_init): Call pch_cpp_save_state conditionally, instead of
4782 calling cpp_save_state.
4783
4a0ae68e
MLI
47842012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
4785
4786 PR c/53063
4787 PR c/40989
4788 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
4789 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
4790 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
4791 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
4792 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
4793 * c-opts.c (c_common_handle_option): Remove explicit handling from
4794 here.
4795 (c_common_post_options): Likewise.
4796
67e4210b
EB
47972012-10-18 Eric Botcazou <ebotcazou@adacore.com>
4798
4799 * c-ada-spec.c (LOCATION_COL): Delete.
4800 (compare_location): New function.
4801 (compare_node): Use it.
4802 (compare_comment): Likewise.
4803
65d4f2cd
MLI
48042012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
4805
4806 PR c/53063
4807 PR c/40989
4808 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
4809 * c-opts.c (c_common_handle_option): Do not set them here. Add
4810 comment.
4811 (c_common_post_options): Likewise.
4812
909881cb
EB
48132012-10-16 Eric Botcazou <ebotcazou@adacore.com>
4814
4815 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
4816 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
4817 Remove POINTER_TYPE handling, add large unsigned handling and use
4818 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
4819
3a785c97
JJ
48202012-10-12 Jakub Jelinek <jakub@redhat.com>
4821
4822 PR c/54381
4823 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
4824 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
4825 locs and array of 3 trees instead of just single loc and single
4826 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
4827 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
4828 For *cmp* builtins that take two sources strings report warnings
4829 about first and second source, not about destination and source.
4830
5e54f81d
MG
48312012-10-12 Marc Glisse <marc.glisse@inria.fr>
4832
4833 PR c++/53055
4834 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
4835
f5b02f1e
EB
48362012-10-11 Eric Botcazou <ebotcazou@adacore.com>
4837
4838 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
4839 declaring something coming from another file.
4840
b46dbc6c
AC
48412012-10-10 Arnaud Charlet <charlet@adacore.com>
4842
f5b02f1e 4843 PR ada/54845
b46dbc6c
AC
4844 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
4845
5d9de0d0
PC
48462012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
4847
4848 PR c++/54194
4849 * c-common.c (warn_about_parentheses): Add location_t parameter;
4850 use EXPR_LOC_OR_LOC.
4851 * c-common.h: Update declaration.
4852
a212e43f
MG
48532012-10-09 Marc Glisse <marc.glisse@inria.fr>
4854
4855 PR c++/54427
4856 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
4857 more operations. Make error messages optional.
4858 * c-common.h (enum stv_conv): Moved from c-typeck.c.
4859 (scalar_to_vector): Declare.
4860
b1db7f91
JM
48612012-10-08 Jason Merrill <jason@redhat.com>
4862
4863 * c-common.c (c_common_reswords): Add thread_local.
4864
e28d52cf
DS
48652012-10-08 Dodji Seketeli <dodji@redhat.com>
4866
4867 PR c++/53528 C++11 attribute support
4868 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
4869 new functions.
4870 * c-common.c (check_cxx_fundamental_alignment_constraints): New
4871 static function.
4872 (handle_aligned_attribute): In choose strictest alignment
4873 among many. Use new check_cxx_fundamental_alignment_constraints.
4874 (handle_transparent_union_attribute): In c++11 attribute syntax,
4875 don't look through typedefs.
4876
3b78de56
AC
48772012-10-04 Arnaud Charlet <charlet@adacore.com>
4878
4879 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
4880 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
4881 out of dumpfile.h.
4882
6040bb5f
DC
48832012-09-25 Dehao Chen <dehao@google.com>
4884
4885 PR middle-end/54645
3b78de56 4886 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
6040bb5f
DC
4887 map when read in the pch.
4888
3f8257db 48892012-09-18 Arnaud Charlet <charlet@adacore.com>
0b07a57e
AC
4890
4891 * c-ada-spec.c: Style fixes.
4892
3f8257db 48932012-09-18 Thomas Quinot <quinot@adacore.com>
da5182be
TQ
4894
4895 * c.opt (-fada-spec-parent): Define new command line switch.
4896 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
4897 is specified, generate binding spec as a child of the specified unit.
4898
0ccb505d
PC
48992012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
4900 Manuel López-Ibáñez <manu@gcc.gnu.org>
4901
4902 PR c++/53210
4903 * c.opt ([Winit-self]): Enabled by -Wall in C++.
4904
c583af79
AC
49052012-08-23 Arnaud Charlet <charlet@adacore.com>
4906
4907 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
4908 for pointers, and add missing Convention C pragma.
4909 (print_ada_struct_decl): Add missing aliased keyword.
4910 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
4911
1a4049e7
JJ
49122012-08-17 Jakub Jelinek <jakub@redhat.com>
4913
4914 * c-common.c (sizeof_pointer_memaccess_warning): New function.
4915 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
4916 * c-opts.c (c_common_handle_option): Enable it for -Wall.
4917 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
4918 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
4919
70b5e7dc
RG
49202012-08-10 Richard Guenther <rguenther@suse.de>
4921
4922 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
4923
f8923f7e
SB
49242012-08-07 Steven Bosscher <steven@gcc.gnu.org>
4925
4926 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
4927 instead of separate pp_newline and pp_flush.
4928 (print_c_tree): Likewise.
4929
e45abe1f
RH
49302012-07-26 Richard Henderson <rth@redhat.com>
4931
4932 * c-common.c (handle_hot_attribute): Allow labels.
4933 (handle_cold_attribute): Likewise.
4934
332f1d24
JJ
49352012-07-20 Jakub Jelinek <jakub@redhat.com>
4936
4937 PR c++/28656
4938 * c-common.c (check_function_nonnull): Handle multiple nonnull
4939 attributes properly.
4940
7ee2468b
SB
49412012-07-16 Steven Bosscher <steven@gcc.gnu.org>
4942
4943 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
4944 * c-ada-spec.c: Likewise.
4945 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
4946
ee7b28eb
SB
49472012-07-14 Steven Bosscher <steven@gcc.gnu.org>
4948
4949 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
4950 Remove code conditional on it.
4951
6bdf3519
SB
49522012-07-11 Steven Bosscher <steven@gcc.gnu.org>
4953
4954 * c-gimplify.c: Do not include basic-block.h.
4955 * c-common.c: Do not include linfuncs.h.
4956
532aafad
SB
49572012-07-08 Steven Bosscher <steven@gcc.gnu.org>
4958
4959 * c-common.h: Include tree.h.
4960
8d0d1915
JM
49612012-07-02 Jason Merrill <jason@redhat.com>
4962
4963 PR c++/53524
4964 * c-common.c (get_priority): Call default_conversion.
4965
fbc873ad
UB
49662012-07-01 Uros Bizjak <ubizjak@gmail.com>
4967
4968 * c-pch.c (c_common_write_pch): Remove unused variables.
4969
d4a10d0a
SB
49702012-06-29 Steven Bosscher <steven@gcc.gnu.org>
4971
4972 * cppspec.c: Moved from gcc/ to here.
4973
6f3a2e23
KT
49742012-06-27 Kai Tietz <ktietz@redhat.com>
4975
4976 PR preprocessor/37215
4977 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
4978
8ca92d04
SB
49792012-06-21 Steven Bosscher <steven@gcc.gnu.org>
4980
4981 * c-common.h (c_common_print_pch_checksum): Remove.
4982 * c-pch.c: Do not include output.h.
4983 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
4984 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
4985 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
4986 (struct c_pch_header): Remove.
4987 (get_ident): Update gpch version.
4988 (pch_init): Do not print executable_checksum to asm_out_file.
4989 Do not fail if there is no asm_out_file to read back from. Set
4990 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
4991 (c_common_write_pch): Verify that nothing was written to asm_out_file
4992 since pch_init was called. Do not write a c_pch_header, and do not
4993 copy from asm_out_file to the PCH.
4994 (c_common_read_pch): Do not read a c_pch_header, and do not restore
4995 the content of asm_out_file from the PCH.
4996 (c_common_print_pch_checksum): Remove.
4997 * c-opts.c (c_common_init): Print out executable_checksum directly.
4998
70f42967
SB
49992012-06-19 Steven Bosscher <steven@gcc.gnu.org>
5000
5001 * c-target.def (objc_declare_unresolved_class_reference,
5002 objc_declare_class_definition): Add new hooks.
5003
a8781821
SB
50042012-06-19 Steven Bosscher <steven@gcc.gnu.org>
5005
5006 * c-lex.c: Do not include output.h.
5007 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
5008 Remove uses of ASM_OUTPUT_IDENT.
5009
9e1a8dd1
RR
50102012-06-15 Marc Glisse <marc.glisse@inria.fr>
5011
5012 PR c++/51033
5013 * c-common.h (c_build_vec_perm_expr): Move decl here.
5014 * c-common.c (c_build_vec_perm_expr): Move definition
5015 here.
5016
6f07a821
SB
50172012-06-06 Steven Bosscher <steven@gcc.gnu.org>
5018
5019 * c.opt (fconserve-space): Turn into a no-op.
5020
9faeb493 50212012-06-04 Sterling Augustine <saugustine@google.com>
c265f413
SA
5022
5023 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
5024 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
5025 both the start and end of the function.
5026
a4b7d13c
SB
50272012-06-04 Steven Bosscher <steven@gcc.gnu.org>
5028
5029 * c-common.c: Do not include output.h.
5030 * c-pragma.c: Likewise.
5031
c265f413
SA
50322012-06-04 Steven Bosscher <steven@gcc.gnu.org>
5033
5034 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
5035 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
5036 (lang_decl_name): Handle namespace decls.
5037
be7a421e
SB
50382012-05-31 Steven Bosscher <steven@gcc.gnu.org>
5039
5040 * c-ada-spec.c: Do not include output.h.
5041 * c-semantics.c: Likewise.
5042
65de6659
JM
50432012-05-29 Joseph Myers <joseph@codesourcery.com>
5044
5045 * c-common.c: Fix typo.
5046
ca5f4331
MM
50472012-05-29 Michael Matz <matz@suse.de>
5048
5049 * c-common.h (c_expand_decl): Remove prototype.
5050
4f7f7aca
MLI
50512012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
5052
5053 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
5054 * c-opts.c (c_common_handle_option): Remove code handling
5055 warn_missing_braces.
5056
4a792f9b
PC
50572012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
5058
5059 PR c++/25137
5060 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
5061 -Wmissing_braces.
5062
650dc14a
DS
50632012-05-22 Dodji Seketeli <dodji@redhat.com>
5064
5065 PR c++/53322
5066 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
5067
9b095bf1
MLI
50682012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
5069
5070 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
5071 * c-opts.c (c_common_handle_option): Do not handle explicitly
5072 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
5073
0b2c4be5
DS
50742012-05-16 Dodji Seketeli <dodji@redhat.com>
5075
5076 PR preprocessor/7263
5077 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
5078 to cpp_classify_number. For diagnostics, use the precise location
5079 instead of the global input_location.
5080
a1bde5af
PC
50812012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
5082
d02924ef 5083 PR c++/11856
a1bde5af
PC
5084 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
5085
d1ede5f4
BS
50862012-05-14 Bernd Schmidt <bernds@codesourcery.com>
5087
a1bde5af 5088 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
d1ede5f4 5089
f2bc201f
MLI
50902012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
5091
5092 PR 53063
5093 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
5094 Wreorder): Use LangEnabledBy.
5095 * c-opts.c (c_common_handle_option): Do not enable them
5096 explicitly. Call lang-specific generated functions.
5097 (c_common_post_options): Do not set them here.
5098
95744782
MLI
50992012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
5100
5101 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
5102 Wmissing-field-initializers,Wmissing-parameter-type,
5103 Wold-style-declaration,Woverride-init): Use EnabledBy.
5104 * c-opts.c (c_common_post_options): Do not set here explicitly.
5105
7d5a5747
MLI
51062012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
5107
5108 PR 53063
5109 * c-opts.c (c_common_handle_option): Use handle_generated_option
5110 to enable sub-options.
5111
5a3c9cf2
PC
51122012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
5113
5114 PR c++/53158
5115 * c-common.c (warnings_for_convert_and_check): Use warning_at.
5116
3ac8781c
RG
51172012-05-10 Richard Guenther <rguenther@suse.de>
5118
5119 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
5120 adjust commentary about TYPE_IS_SIZETYPE types.
5121
1e537948
MLI
51222012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
5123
5124 PR c++/53261
5125 * c-common.c (warn_logical_operator): Check that argument of
5126 integer_zerop is not NULL.
5127
f2c4a785
MLI
51282012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
5129
5130 PR c/43772
5131 * c-common.c (warn_logical_operator): Do not warn if either side
5132 is already true or false.
5133
50f305ca
MLI
51342012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
5135
5136 PR c/51712
5137 * c-common.c (expr_original_type): New.
5138 (shorten_compare): Do not warn for enumeration types.
5139
0c3641b0
MLI
51402012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
5141
5142 * c.opt (fpermissive): Add Var(flag_permissive).
5143
7edaa4d2
MG
51442012-04-30 Marc Glisse <marc.glisse@inria.fr>
5145
5146 PR c++/51033
5147 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
5148 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
5149
b9c8da34
DS
51502012-04-30 Dodji Seketeli <dodji@redhat.com>
5151
5152 Add -Wvarargs option
5153 * c.opt (Wvarargs): Define new option.
5154
e6c69da0
MLI
51552012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
5156
5157 * c-common.c (check_function_arguments): Replace
5158 Wmissing-format-attribute with Wsuggest-attribute=format.
5159
90137d8f
MLI
51602012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
5161
5162 * c.opt (Wsuggest-attribute=format): New. Alias of
5163 Wmissing-format-attribute.
5164 * c-format.c (decode_format_type): Replace
5165 Wmissing-format-attribute with Wsuggest-attribute=format.
5166 (check_function_format): Likewise.
5167
9faeb493 51682012-04-27 Ollie Wild <aaw@google.com>
7f5f5f98
OW
5169
5170 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
5171 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
5172 * c.opt: Add Wliteral-suffix.
5173
c1771a20
MLI
51742012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
5175
5176 PR c/44774
5177 * c.opt (Wpedantic): New.
5178 (pedantic): Alias Wpedantic.
5179 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
5180 (c_common_post_options): Likewise.
5181 (sanitize_cpp_opts): Likewise.
5182 * c-lex.c (interpret_float): Likewise.
5183 * c-format.c (check_format_types): Likewise.
5184 * c-common.c (pointer_int_sum): Likewise.
5185 (c_sizeof_or_alignof_type): Likewise.
5186 (c_add_case_label): Likewise.
5187 (c_do_switch_warnings): Likewise.
5188 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
5189
04b391c1
JM
51902012-04-15 Jason Merrill <jason@redhat.com>
5191
5192 PR c++/52818
5193 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
5194 (C_STD_NAME): Distinguish between C++98 and C++11.
5195
ac868f29
EB
51962012-04-11 Eric Botcazou <ebotcazou@adacore.com>
5197
5198 PR target/52624
5199 * c-common.h (uint16_type_node): Rename into...
5200 (c_uint16_type_node): ...this.
5201 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
5202 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
5203
fd4116f4
MLI
52042012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
5205
5206 * c-common.c (warn_if_unused_value): Move definition to here.
5207 * c-common.h (warn_if_unused_value): Move declaration to here.
5208
573ac65e
WB
52092012-03-23 William Bader <williambader@hotmail.com>
5210
5211 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
5212
552b8185
JM
52132012-03-20 Jason Merrill <jason@redhat.com>
5214
5215 * c-common.h (enum cxx_dialect): Add cxx1y.
5216 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
5217 test.
5218 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
5219 * c-opts.c (c_common_post_options): Likewise.
5220 (set_std_cxx1y): New.
5221 (c_common_handle_option): Call it.
5222 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
5223
04398fa8
PC
52242012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
5225
5226 PR c++/14710
5227 * c.opt ([Wuseless-cast]): Add.
5228
d2a12ae7
RG
52292012-03-16 Richard Guenther <rguenther@suse.de>
5230
5231 * c-pretty-print.c (pp_c_initializer_list): Adjust.
5232
a12bf402
MLI
52332012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
5234
5235 PR c++/44783
5236 * c.opt (ftemplate-backtrace-limit) Add.
5237
5c30094f
RO
52382012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5239
5240 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
5241 handling.
5242 * c-pragma.c (handle_pragma_extern_prefix): Remove.
5243 (init_pragma): Don't register extern_prefix.
5244
21fa2faf
RG
52452012-03-12 Richard Guenther <rguenther@suse.de>
5246
5247 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
5248 (builtin_type_for_size): Likewise.
5249
e3793c6f
JJ
52502012-02-13 Jakub Jelinek <jakub@redhat.com>
5251
5252 PR c++/52215
5253 * c-common.c (sync_resolve_params): Don't decide whether to convert
5254 or not based on TYPE_SIZE comparison, convert whenever arg_type
5255 is unsigned INTEGER_TYPE.
5256
93286335
PC
52572012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
5258
5259 PR c/52118
5260 * c.opt ([Wunused-local-typedefs]): Fix description.
5261
7a421706
MS
52622012-01-24 Mike Stump <mikestump@comcast.net>
5263
5264 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
5265 exactly.
5266
ba9b1f11
RG
52672012-01-18 Richard Guenther <rguenther@suse.de>
5268
5269 * c-opts.c (c_common_post_options): Reset LTO flags if
5270 we are about to generate a PCH.
5271
465406be
PC
52722012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
5273
5274 PR c++/51777
5275 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
5276 use pp_unsigned_wide_integer.
5277
aee15221
RG
52782012-01-10 Richard Guenther <rguenther@suse.de>
5279
5280 PR middle-end/51806
5281 * c-opts.c (c_common_handle_option): Move -Werror handling
5282 to language independent code.
5283
5720c0dc
RG
52842012-01-05 Richard Guenther <rguenther@suse.de>
5285
5286 PR middle-end/51764
5287 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
5288 from common.opt.
5289
73ac190a
PC
52902011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
5291
5292 PR c++/51316
5293 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
5294 of array types with an unknown bound.
5295
48b0b196
JM
52962011-12-20 Joseph Myers <joseph@codesourcery.com>
5297
5298 * c-common.c (flag_isoc99): Update comment to refer to C11.
5299 (flag_isoc1x): Change to flag_isoc11.
5300 * c-common.h (flag_isoc99): Update comment to refer to C11.
5301 (flag_isoc1x): Change to flag_isoc11.
5302 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
5303 C11.
5304 * c-opts.c (set_std_c1x): Change to set_std_c11.
5305 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
5306 Call set_std_c11.
5307 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
5308 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
5309 * c.opt (std=c1x): Change to std=c11. Document as non-draft
5310 standard.
5311 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
5312 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
5313 (std=gnu1x): Make alias of std=gnu11.
5314
d58d6eb5
JM
53152011-12-19 Jason Merrill <jason@redhat.com>
5316
5317 PR c++/51228
5318 * c-common.c (handle_transparent_union_attribute): Check the first
5319 field if the type is complete.
5320
b3908fcc
JW
53212011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
5322
5323 PR libstdc++/51365
5324 * c-common.c (RID_IS_FINAL): Add.
5325 * c-common.h (RID_IS_FINAL): Add.
5326
fea3ca91
IS
53272011-11-30 Iain Sandoe <iains@gcc.gnu.org>
5328
5329 * c.opt (fgnu-runtime): Provide full description.
5330 (fnext-runtime): Likewise.
5331 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
5332
62bad7cd
AM
53332011-11-28 Andrew MacLeod <amacleod@redhat.com>
5334
5335 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
5336 predefines in one place. Add LOCK_FREE predefines.
5337 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
5338 new func.
5339
c466c4ff
AM
53402011-11-24 Andrew MacLeod <amacleod@redhat.com>
5341
5342 PR c/51256
9faeb493 5343 * c-common.c (get_atomic_generic_size): Check for various error
c466c4ff 5344 conditions
9faeb493
UB
5345 (resolve_overloaded_atomic_exchange,
5346 resolve_overloaded_atomic_compare_exchange,
c466c4ff
AM
5347 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
5348 error_mark_node for error conditions.
9faeb493 5349
a5952633
RG
53502011-11-08 Richard Guenther <rguenther@suse.de>
5351
5352 PR middle-end/51010
5353 c-family/
5354
0a35513e
AH
53552011-11-07 Richard Henderson <rth@redhat.com>
5356 Aldy Hernandez <aldyh@redhat.com>
5357 Torvald Riegel <triegel@redhat.com>
5358
5359 Merged from transactional-memory.
5360
5361 * c-common.c (handle_tm_wrap_attribute,
5362 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
5363 (struct c_common_reswords): Added __transaction* keywords.
5364 (struct c_common_attribute_table): Added transaction* and tm_regparm
5365 attributes.
5366 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
5367 masks.
5368 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
5369 find_tm_attribute): Declare.
5370
6d87092d
JM
53712011-11-07 Jason Merrill <jason@redhat.com>
5372
5373 PR c++/35688
5374 * c-common.c, c-common.h: Revert yesterday's changes.
5375
8e7860a1
JM
53762011-11-06 Jason Merrill <jason@redhat.com>
5377
5378 PR c++/35688
5379 * c-common.c (decl_has_visibility_attr): Split out from...
5380 (c_determine_visibility): ...here.
5381 * c-common.h: Declare it.
5382
d19fa6b5
JM
53832011-11-06 Joseph Myers <joseph@codesourcery.com>
5384
5385 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
5386 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
5387 type.
5388 (check_user_alignment): New. Split out of
5389 handle_aligned_attribute. Disallow integer constants with
5390 noninteger types. Conditionally allow zero.
5391 (handle_aligned_attribute): Use check_user_alignment.
5392 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
5393
86951993
AM
53942011-11-06 Andrew MacLeod <amacleod@redhat.com>
5395 Richard Henderson <rth@redhat.com>
5396
5397 Merged from cxx-mem-model.
5398
5399 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
9faeb493 5400 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
86951993
AM
5401 parameters that are the same type size.
5402 (get_atomic_generic_size): New. Find size of generic
5403 atomic function parameters and do typechecking.
5404 (add_atomic_size_parameter): New. Insert size into parameter list.
5405 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
5406 either __atomic_exchange_n or external library call.
9faeb493 5407 (resolve_overloaded_atomic_compare_exchange): Restructure
86951993 5408 __atomic_compare_exchange to either _n variant or external library call.
9faeb493 5409 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
86951993
AM
5410 __atomic_load_n or an external library call.
5411 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
5412 __atomic_store_n or an external library call.
5413 (resolve_overloaded_builtin): Handle new __atomic builtins.
5414
cf9e9959
EB
54152011-11-04 Eric Botcazou <ebotcazou@adacore.com>
5416
5417 PR c++/50608
5418 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
5419 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
5420 <INDIRECT_REF>: Return the argument.
5421 <ARRAY_REF>: Remove special code for negative offset.
5422 Call fold_build_pointer_plus instead of size_binop.
5423 (fold_offsetof): Remove STOP_REF argument and adjust.
5424 * c-common.h (fold_offsetof_1): Declare.
5425 (fold_offsetof): Remove STOP_REF argument.
5426
25339f10
JM
54272011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
5428
5429 PR c++/50810
5430 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
5431 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
5432 Wnarrowing for C++0x and C++98.
5433 * c.opt ([Wnarrowing]): Update.
5434
89401152
PC
54352011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
5436
5437 PR c++/44277
5438 * c.opt: Add Wzero-as-null-pointer-constant.
5439
97e3ad20
JM
54402011-10-31 Jason Merrill <jason@redhat.com>
5441
15694fdd
JM
5442 * c.opt (-fdeduce-init-list): Off by default.
5443
97e3ad20
JM
5444 PR c++/50920
5445 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
5446 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
5447 and -Wc++11-compat.
5448 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
5449
fb9120e3
RAV
54502011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
5451
5452 PR c++/30066
5453 * c.opt (fvisibility-inlines-hidden): Description change.
5454
3ce4f9e4
ESR
54552011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
5456
5457 Implement C++11 user-defined literals.
5458 * c-common.c (build_userdef_literal): New.
5459 * c-common.def: New tree code.
5460 * c-common.h (tree_userdef_literal): New tree struct and accessors.
5461 * c-lex.c (interpret_float): Add suffix parm.
5462 (c_lex_with_flags): Build literal tokens.
5463
5f53c243
PC
54642011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
5465
5466 PR c++/50841
5467 Revert:
5468 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
5469
5470 PR c++/50810
5471 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
5472 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
5473 Wnarrowing for C++0x and C++98.
5474 * c.opt ([Wnarrowing]): Update.
5475
263734e1
PC
54762011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
5477
5478 PR c++/50810
5479 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
5480 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
5481 Wnarrowing for C++0x and C++98.
5482 * c.opt ([Wnarrowing]): Update.
5483
d2e312d7
PC
54842011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
5485
5486 PR c++/45385
5487 * c-common.c (conversion_warning): Remove code looking for
5488 artificial operands.
5489
d17687f6
DS
54902011-10-18 Dodji Seketeli <dodji@redhat.com>
5491
5492 PR bootstrap/50760
5493 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
9faeb493 5494 !NO_IMPLICIT_EXTERN_C.
d17687f6 5495
fc8396e9
PC
54962011-10-17 Michael Spertus <mike_spertus@symantec.com>
5497
5498 * c-common.c (c_common_reswords): Add __bases,
5499 __direct_bases.
5500 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
5501
55022011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
5503
5504 PR c++/50757
5505 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
5506
847e697a
TT
55072011-10-15 Tom Tromey <tromey@redhat.com>
5508 Dodji Seketeli <dodji@redhat.com>
5509
5510 * c.opt (fdebug-cpp): New option.
5511 * c-opts.c (c_common_handle_option): Handle the option.
5512 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
5513 output stream in parameter. Factorized from ...
5514 (maybe_print_line): ... this. Dump location debug information when
5515 -fdebug-cpp is in effect.
5516 (print_line_1): New static function. Takes an output stream in
5517 parameter. Factorized from ...
5518 (print_line): ... here. Dump location information when -fdebug-cpp
5519 is in effect.
5520 (scan_translation_unit): Dump location information when
5521 -fdebug-cpp is in effect.
5522
92582b75
TT
55232011-10-15 Tom Tromey <tromey@redhat.com>
5524 Dodji Seketeli <dodji@redhat.com>
5525
5526 * c.opt (ftrack-macro-expansion): New option. Handle it with and
5527 without argument.
5528 * c-opts.c (c_common_handle_option)<case
5529 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
5530 cases. Handle -ftrack-macro-expansion with and without argument.
5531
46427374
TT
55322011-10-15 Tom Tromey <tromey@redhat.com>
5533 Dodji Seketeli <dodji@redhat.com>
5534
5535 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
5536 (print_line, cb_define, do_line_change): Adjust to avoid touching
5537 the internals of struct line_map. Use the public API instead.
5538 * c-pch.c (c_common_read_pch): Likewise.
5539 * c-lex.c (fe_file_change): Likewise.
5540
fc8396e9
PC
55412011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
5542
5543 PR c++/17212
5544 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
5545
55462011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
5547
5548 PR c++/33067
5549 * c-pretty-print.c (pp_c_floating_constant): Output
5550 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
5551
e79983f4
MM
55522011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
5553
5554 * c-common.c (def_builtin_1): Delete old interface with two
5555 parallel arrays to hold standard builtin declarations, and replace
5556 it with a function based interface that can support creating
5557 builtins on the fly in the future. Change all uses, and poison
5558 the old names. Make sure 0 is not a legitimate builtin index.
5559 * c-omp.c (c_finish_omp_barrier): Ditto.
5560 (c_finish_omp_taskwait): Ditto.
5561 (c_finish_omp_flush): Ditto.
5562
6637388f
TG
55632011-10-11 Tristan Gingold <gingold@adacore.com>
5564
5565 * c.opt: (fallow-parameterless-variadic-functions): New.
5566
3797cb21
DS
55672011-09-08 Dodji Seketeli <dodji@redhat.com>
5568
5569 PR c++/33255 - Support -Wunused-local-typedefs warning
5570 * c-common.h (struct c_language_function::local_typedefs): New
5571 field.
9faeb493
UB
5572 (record_locally_defined_typedef, maybe_record_typedef_use)
5573 (maybe_warn_unused_local_typedefs): Declare new functions.
3797cb21 5574 * c-common.c (record_locally_defined_typedef)
9faeb493
UB
5575 (maybe_record_typedef_use)
5576 (maybe_warn_unused_local_typedefs): Define new functions.
3797cb21
DS
5577 * c.opt: Declare new -Wunused-local-typedefs flag.
5578
693ddb1b
EB
55792011-09-06 Eric Botcazou <ebotcazou@adacore.com>
5580
5581 PR middle-end/50266
5582 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
5583 computations.
5584
830c740f
RG
55852011-09-05 Richard Guenther <rguenther@suse.de>
5586
5587 * c-common.c (complete_array_type): Use ssize_int (-1) instead
5588 of integer_minus_one_node for empty array upper bounds.
5589
892a371f
DS
55902011-08-28 Dodji Seketeli <dodji@redhat.com>
5591
5592 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
5593 it's the first time it's being called on this main TU.
5594
0e3fdb48
RB
55952011-08-24 Richard Guenther <rguenther@suse.de>
5596
5597 PR c/49396
5598 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
5599
56002011-08-22 Gabriel Charette <gchare@google.com>
e3dfef44
GC
5601
5602 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
5603 defined in cpp_init_builtins and c_cpp_builtins.
5604
d4a83c10
JM
56052011-08-19 Joseph Myers <joseph@codesourcery.com>
5606
5607 * c-common.c (c_common_reswords): Add __builtin_complex.
5608 * c-common.h (RID_BUILTIN_COMPLEX): New.
5609
bbceee64
JM
56102011-08-18 Joseph Myers <joseph@codesourcery.com>
5611
5612 * c-common.c (c_common_reswords): Add _Noreturn.
5613 (keyword_is_function_specifier): Handle RID_NORETURN.
5614 * c-common.h (RID_NORETURN): New.
5615
3f8257db 56162011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
0e3a99ae
AS
5617
5618 * c-common.c (unsafe_conversion_p): New function. Check if it is
5619 unsafe to convert an expression to the type.
5620 (conversion_warning): Adjust, use unsafe_conversion_p.
5621 * c-common.h (unsafe_conversion_p): New function declaration.
5622
20906c66
JJ
56232011-08-02 Jakub Jelinek <jakub@redhat.com>
5624
5625 * c-common.h (c_finish_omp_atomic): Adjust prototype.
5626 (c_finish_omp_taskyield): New prototype.
5627 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
5628 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
5629 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
5630 or RHS1 have side-effects, evaluate those too in the right spot,
5631 if it is a decl and LHS is also a decl, error out if they
5632 aren't the same.
5633 (c_finish_omp_taskyield): New function.
5634 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
5635 * c-pragma.c (omp_pragmas): Add taskyield.
5636 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
5637 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
5638 PRAGMA_OMP_CLAUSE_MERGEABLE.
5639
770e5a2e
DS
56402011-07-25 Dodji Seketeli <dodji@redhat.com>
5641
5642 * c-common.h (set_underlying_type): Remove parm name from
5643 declaration.
5644
1baae426
RG
56452011-07-25 Romain Geissler <romain.geissler@gmail.com>
5646
5647 * c-pretty-print.h: Search c-common.h in c-family.
9faeb493 5648
fcb21722
JM
56492011-07-22 Jason Merrill <jason@redhat.com>
5650
76f86d00
JM
5651 PR c++/49793
5652 * c.opt (Wnarrowing): New.
5653
3a636414
JM
5654 PR c++/30112
5655 * c-common.h: Declare c_linkage_bindings.
5656 * c-pragma.c (handle_pragma_redefine_extname): Use it.
5657
fcb21722
JM
5658 PR c++/49813
5659 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
5660 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
5661 as flag_isoc99 for 'restrict'.
5662 (pp_c_specifier_qualifier_list): Likewise for _Complex.
5663
02614448
ILT
56642011-07-21 Ian Lance Taylor <iant@google.com>
5665
5666 PR middle-end/49705
5667 * c-common.c (c_disable_warnings): New static function.
5668 (c_enable_warnings): New static function.
5669 (c_fully_fold_internal): Change local unused_p to bool. Call
5670 c_disable_warnings and c_enable_warnings rather than change
5671 c_inhibit_evaluation_warnings.
5672
34429675
JM
56732011-07-20 Jason Merrill <jason@redhat.com>
5674
5675 PR c++/6709 (DR 743)
5676 PR c++/42603 (DR 950)
5677 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
5678 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
5679 (CPP_DECLTYPE): New.
5680 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
5681
5d49b6a7
RG
56822011-07-19 Richard Guenther <rguenther@suse.de>
5683
5684 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
5685 * c-omp.c (c_finish_omp_for): Likewise.
5686
e84a58ff
EB
56872011-07-12 Eric Botcazou <ebotcazou@adacore.com>
5688
5689 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
5690 body on the next line.
5691
329af3c7
JM
56922011-07-08 Jason Merrill <jason@redhat.com>
5693
4063e61b
JM
5694 PR c++/45437
5695 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
5696
329af3c7
JM
5697 PR c++/49673
5698 * c-common.c (c_apply_type_quals_to_decl): Don't check
5699 TYPE_NEEDS_CONSTRUCTING.
5700
1a072294
RG
57012011-07-06 Richard Guenther <rguenther@suse.de>
5702
5703 * c-common.c (c_common_nodes_and_builtins):
5704 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
5705
fce5dddd
RG
57062011-07-05 Richard Guenther <rguenther@suse.de>
5707
5708 * c-common.c (c_common_nodes_and_builtins): Build all common
5709 tree nodes first.
5710
45d439ac
JJ
57112011-06-27 Jakub Jelinek <jakub@redhat.com>
5712
56300785
JJ
5713 * c-common.h (c_tree_chain_next): New static inline function.
5714
45d439ac
JJ
5715 * c-common.c (check_builtin_function_arguments): Handle
5716 BUILT_IN_ASSUME_ALIGNED.
5717
e0a8ecf2
AM
57182011-06-21 Andrew MacLeod <amacleod@redhat.com>
5719
5720 * c-common.c: Add sync_ or SYNC__ to builtin names.
5721 * c-omp.c: Add sync_ or SYNC__ to builtin names.
dfb43cd5
PV
5722
57232011-06-20 Pierre Vittet <piervit@pvittet.com>
5724
5725 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
5726 handler.
5727 (gen_pragma_handler): New union.
5728 (internal_pragma_handler): New type.
5729 (c_register_pragma_with_data)
5730 (c_register_pragma_with_expansion_and_data): New functions.
5731
5732 * c-pragma.c (registered_pragmas, c_register_pragma_1)
5733 (c_register_pragma, c_register_pragma_with_expansion)
5734 (c_invoke_pragma_handler): Changed to work with
5735 internal_pragma_handler.
5736 (c_register_pragma_with_data)
5737 (c_register_pragma_with_expansion_and_data): New functions.
5738
677f3fa8
JM
57392011-06-14 Joseph Myers <joseph@codesourcery.com>
5740
5741 * c-common.c: Include common/common-target.h.
5742 (handle_section_attribute): Use
5743 targetm_common.have_named_sections.
5744 * c-cppbuiltin.c: Include common/common-target.h.
5745 (c_cpp_builtins): Use targetm_common.except_unwind_info.
5746
d7fc8c14
RG
57472011-06-10 Richard Guenther <rguenther@suse.de>
5748
5749 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
5750 to print a IDENTIFIER_NODE.
5751
10e48e39
RO
57522011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5753 Joseph Myers <joseph@codesourcery.com>
5754
5755 * c.opt (fbuilding-libgcc): New option.
5756 * c-cppbuiltin.c (c_cpp_builtins): Define
5757 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
5758
6976ae51
JM
57592011-06-07 Jason Merrill <jason@redhat.com>
5760
3ff60975
JM
5761 * c-common.c (max_tinst_depth): Lower default to 900.
5762
6976ae51
JM
5763 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
5764
009db074
RG
57652011-06-07 Richard Guenther <rguenther@suse.de>
5766
5767 * c-common.c (c_common_nodes_and_builtins): Do not set
5768 size_type_node or call set_sizetype.
5769
b4592b92
DS
57702011-06-07 Dodji Seketeli <dodji@redhat.com>
5771
5772 PR debug/49130
5773 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
9faeb493 5774 type when using pointer comparison to compare types.
b4592b92 5775
014ab419
JW
57762011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
5777
5778 * c.opt: Add -Wdelete-non-virtual-dtor.
5779 * c-opts.c (c_common_handle_option): Include it in -Wall.
5780
4f60111f
NF
57812011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
5782
5783 PR bootstrap/49190
5784
5785 Revert:
5786 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
5787
5788 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
5789 not tree_common.
5790
4cc4f2f4
JJ
57912011-05-27 Jakub Jelinek <jakub@redhat.com>
5792
5793 PR c++/49165
5794 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
5795 C++ don't call c_common_truthvalue_conversion on void type arms.
5796
38e01f9e
NF
57972011-05-27 Nathan Froyd <froydnj@codesourcery.com>
5798
5799 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
5800 (stmt_list_stack): Define.
5801 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
5802 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
5803
92e948a8
NF
58042011-05-26 Nathan Froyd <froydnj@codesourcery.com>
5805
5806 * c-common.c (warning_candidate_p): Check for BLOCKs.
5807
a2fc3e63
NF
58082011-05-26 Nathan Froyd <froydnj@codesourcery.com>
5809
5810 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
5811 not tree_common.
5812
0957c029
JJ
58132011-05-25 Jakub Jelinek <jakub@redhat.com>
5814
5815 * c-common.c (def_fn_type): Remove extra va_end.
5816
828fb3ba
JM
58172011-05-23 Jason Merrill <jason@redhat.com>
5818
5819 PR c++/48106
5820 * c-common.c (c_common_get_narrower): New.
5821 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
5822
dde05067
NF
58232011-05-23 Nathan Froyd <froydnj@codesourcery.com>
5824
5825 * c-common.h (check_function_arguments): Tweak prototype of
5826 check_function_arguments.
5827 * c-common.c (check_function_arguments): Likewise. Adjust
5828 calls to check_function_nonnull, check_function_format, and
5829 check_function_sentinel.
5830 (check_function_sentinel): Take a FUNCTION_TYPE rather than
5831 separate attributes and typelist arguments. Use
5832 FOREACH_FUNCTION_ARGS to iterate over argument types.
5833
3c0d13bf
PC
58342011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
5835
5836 * c-common.c (c_common_reswords): Reorder.
5837 * c-common.h (rid): Likewise.
5838
8242dd04
NF
58392011-05-10 Nathan Froyd <froydnj@codesourcery.com>
5840
5841 * c-common.c (def_fn_type): Don't call build_function_type, call
5842 build_function_type_array or build_varargs_function_type_array
5843 instead.
5844 (c_common_nodes_and_builtins): Likewise.
5845
3d528853
NF
58462011-05-05 Nathan Froyd <froydnj@codesourcery.com>
5847
5848 * c-common.c (c_add_case_label): Omit the loc argument to
5849 build_case_label.
5850 * c-common.h (build_case_label): Remove.
5851 * c-semantics.c (build_case_label): Remove.
5852
a04a722b
JM
58532011-05-05 Joseph Myers <joseph@codesourcery.com>
5854
5855 * c-objc.h (objc_start_method_definition): Update prototype.
5856 * stub-objc.c (objc_start_method_definition): Add extra parameter.
5857
e19a18d4
NF
58582011-05-04 Nathan Froyd <froydnj@codesourcery.com>
5859
5860 * c-common.c (check_main_parameter_types): Reindent. Don't use
5861 TYPE_ARG_TYPES directly.
5862 (handle_nonnull_attribute): Likewise.
5863 (sync_resolve_params): Likewise.
5864 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
5865 to check_format_string.
5866 (handle_format_attribute): Likewise.
5867 (check_format_string): Take a function type to examine instead of
5868 a type list. Use a function_arg_iterator to step through argument
5869 types.
5870
c62c040f
RG
58712011-05-04 Richard Guenther <rguenther@suse.de>
5872
5873 * c-common.c (fix_string_type): Use size_int for index type bounds.
5874 (start_fname_decls): Do not pass NULL to build_int_cst.
5875 (c_init_attributes): Likewise.
5876 * c-lex.c (c_lex_with_flags): Likewise.
5877
c12ff9d8
JM
58782011-04-27 Jason Merrill <jason@redhat.com>
5879
5880 * c-common.c (make_tree_vector_from_list): New.
5881 * c-common.h: Declare it.
5882
304dfbe3
RG
58832011-04-26 Richard Guenther <rguenther@suse.de>
5884
5885 PR preprocessor/48248
5886 * c-ppoutput.c (maybe_print_line): Always optimize newlines
5887 for output size with -P.
5888
3c0d13bf
PC
58892011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
5890
5891 * c-common.c (struct c_common_resword): Add __underlying_type.
5892 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
5893
04695783
JM
58942011-04-20 Jim Meyering <meyering@redhat.com>
5895
5896 * c-format.c (init_dollar_format_checking): Remove useless
5897 if-before-free.
5898
0dc33c3c
NP
58992011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
5900
5901 * c-objc.h (objc_get_interface_ivars): Removed.
3c0d13bf 5902 (objc_detect_field_duplicates): New.
0dc33c3c 5903 * stub-objc.c: Likewise.
3c0d13bf 5904
c59633d9
NP
59052011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
5906
5907 * stub-objc.c (objc_declare_protocols): Renamed to
5908 objc_declare_protocol.
5909 * c-objc.h: Likewise.
3c0d13bf 5910
32dabdaf
NP
59112011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
5912
5913 * stub-objc.c (objc_declare_class): Updated argument name.
5914
81f653d6
NF
59152011-04-12 Nathan Froyd <froydnj@codesourcery.com>
5916
5917 * c-common.h (c_common_init_ts): Declare.
5918 * c-common.c (c_common_init_ts): Define.
5919
eb345401
NP
59202011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
5921
5922 * c-objc.h (objc_build_message_expr): Updated prototype.
5923 * stub-objc.c (objc_build_message_expr): Likewise.
9faeb493 5924
a358e188
MJ
59252011-04-12 Martin Jambor <mjambor@suse.cz>
5926
5927 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
5928 of cgraph_node.
5929
e6313a78
RG
59302011-04-11 Richard Guenther <rguenther@suse.de>
5931
5932 * c-common.c (complete_array_type): Build a range type of
5933 proper type.
5934
dcf0c47e
NF
59352011-04-08 Nathan Froyd <froydnj@codesourcery.com>
5936
5937 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
5938 (handle_type_generic_attribute): Likewise.
5939
1ee44b26
JM
59402011-04-07 Jason Merrill <jason@redhat.com>
5941
5942 PR c++/48450
5943 * c-common.c (c_common_truthvalue_conversion): Don't ignore
5944 conversion from C++0x scoped enum.
5945
acce4e77
JM
59462011-04-06 Joseph Myers <joseph@codesourcery.com>
5947
5948 * c-target-def.h: New file.
5949 * c-target.def: New file.
5950 * c-target.h: New file.
5951 * c-common.c (targetcm): Don't define here.
5952 * c-common.h (default_handle_c_option): Declare.
5953 * c-format.c: Include c-target.h instead of target.h.
5954 * c-opts.c: Include c-target.h instead of target.h. Explicitly
5955 include tm.h.
5956 (default_handle_c_option): Move from targhooks.c.
5957
e2eefb55
JJ
59582011-03-29 Jakub Jelinek <jakub@redhat.com>
5959
5960 PR preprocessor/48248
5961 * c-ppoutput.c (print): Add src_file field.
5962 (init_pp_output): Initialize it.
5963 (maybe_print_line): Don't optimize by adding up to 8 newlines
5964 if map->to_file and print.src_file are different file.
5965 (print_line): Update print.src_file.
5966
ba78087b
KT
59672011-03-25 Kai Tietz <ktietz@redhat.com>
5968
5969 * c-ada-spec.c (compare_comment): Use filename_cmp
5970 instead of strcmp for filename.
5971
0edf1bb2
JL
59722011-03-25 Jeff Law <law@redhat.com>
5973
adfac8df 5974 * c-common.c (def_fn_type): Add missing va_end.
0edf1bb2 5975
c7dc8804
JM
59762011-03-25 Jason Merrill <jason@redhat.com>
5977
5978 * c.opt: Add -std=c++03.
5979
d1d879b1
EB
59802011-03-22 Eric Botcazou <ebotcazou@adacore.com>
5981
5982 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
5983
3f8257db 59842011-03-17 Kai Tietz <ktietz@redhat.com>
62d784f7
KT
5985
5986 PR target/12171
5050afdf
KT
5987 * c-pretty-print.c (pp_c_specifier_qualifier_list):
5988 Display allowed attributes for function pointer types.
5989 (pp_c_attributes_display): New function to display
5990 attributes having affects_type_identity flag set to true.
5991 * c-pretty-print.h (pp_c_attributes_display): New prototype.
5992
62d784f7
KT
5993 * c-common.c (c_common_attribute_table):
5994 Add new element.
5995 (c_common_format_attribute_table): Likewise.
5996
82d37118
JM
59972011-03-18 Jason Merrill <jason@redhat.com>
5998
49a000c3
JM
5999 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
6000 * c-common.h: Don't declare it here.
6001 * c-common.c: Or define it here.
6002 * c-opts.c (c_common_handle_option): Or set it here.
6003
82d37118
JM
6004 PR c++/35315
6005 * c-common.c (handle_transparent_union_attribute): Don't
6006 make a duplicate type in C++.
6007
17bc631c
JM
60082011-03-15 Jason Merrill <jason@redhat.com>
6009
6010 * c-common.c (max_constexpr_depth): New.
6011 * c-common.h: Declare it.
6012 * c-opts.c (c_common_handle_option): Set it.
6013 * c.opt (fconstexpr-depth): New option.
6014
1b9b91a6
JM
60152011-03-11 Jason Merrill <jason@redhat.com>
6016
f231b5ff
JM
6017 * c-common.c (attribute_takes_identifier_p): Add missing const.
6018
1b9b91a6
JM
6019 PR c++/46803
6020 * c-common.c (attribute_takes_identifier_p): Assume that an
6021 unknown attribute takes an identifier.
6022
a19e4d44
NF
60232011-03-07 Nathan Froyd <froydnj@codesourcery.com>
6024
6025 PR c/47786
6026 * c-common.c (c_type_hash): Call list_length instead of iterating
6027 through DECL_CHAIN. Rename 'i' to 'n_elements'.
6028
982d62f6
JJ
60292011-02-19 Jakub Jelinek <jakub@redhat.com>
6030
6031 PR c/47809
6032 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
6033
0a256240
NP
60342011-02-17 Iain Sandoe <iains@gcc.gnu.org>
6035
6036 * c.opt (fobjc-abi-version=) New.
6037 (fobjc-nilcheck): New.
6038
ba9e6dd5
NF
60392011-02-03 Nathan Froyd <froydnj@codesourcery.com>
6040
6041 PR c++/46890
6042 * c-common.h (keyword_is_decl_specifier): Declare.
6043 * c-common.c (keyword_is_decl_specifier): Define.
6044 (keyword_is_function_specifier): New function.
6045
7273813a
JJ
60462011-01-26 Jakub Jelinek <jakub@redhat.com>
6047
6048 PR c/47473
6049 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
6050 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
6051 REAL_TYPE.
6052
908ef79b
AC
60532011-01-26 Arnaud Charlet <charlet@adacore.com>
6054
6055 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
6056
237e9384
JJ
60572011-01-26 Jakub Jelinek <jakub@redhat.com>
6058
6059 PR pch/47430
6060 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
6061 after init_c_lex if pch_file is set.
6062
47ea1edf
DK
60632011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
6064
d4dba752 6065 PR c++/43601
47ea1edf
DK
6066 * c.opt (-fkeep-inline-dllexport): New switch.
6067
2aa9c6ae
RG
60682011-01-12 Richard Guenther <rguenther@suse.de>
6069
6070 PR middle-end/32511
6071 * c-common.c (handle_weak_attribute): Warn instead of error
6072 on declaring an inline function weak.
6073
7bd11157
TT
60742011-01-05 Tom Tromey <tromey@redhat.com>
6075
6076 * c-common.h (lvalue_error): Update.
6077 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
6078 not error.
6079
0e66e494 60802010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
9faeb493 6081
b4f588c4
NP
6082 PR objc/47075
6083 * c-objc.h (objc_finish_message_expr): Added argument to
6084 prototype.
6085
f4da8dce
NF
60862010-12-22 Nathan Froyd <froydnj@codesourcery.com>
6087
6088 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
6089 Use prototype_p.
6090
46270f14
NP
60912010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
6092
6093 * c-objc.h (objc_maybe_warn_exceptions): New.
9faeb493 6094 * stub-objc.c (objc_maybe_warn_exceptions): New.
46270f14 6095
4816c593
NF
60962010-12-10 Nathan Froyd <froydnj@codesourcery.com>
6097
6098 * c-common.h (readonly_error): Declare.
6099 * c-common.c (readonly_error): Define.
6100
7a6daeb0
NF
61012010-12-09 Nathan Froyd <froydnj@codesourcery.com>
6102
6103 * c-common.h (invalid_indirection_error): Declare.
6104 * c-common.c (invalid_indirection_error): Define.
6105
892f6119
RG
61062010-12-03 Richard Guenther <rguenther@suse.de>
6107
6108 PR c/46745
6109 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
6110 (pp_c_unary_expression): Likewise.
6111 (pp_c_expression): Likewise.
6112
6c39e757
NP
61132010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
6114
6115 * c-common.h (objc_finish_function): New.
6116 (objc_non_volatilized_type): Removed.
6117 (objc_type_quals_match): Removed.
6118 * stub-objc.c (objc_finish_function): New.
6119 (objc_non_volatilized_type): Removed.
6120 (objc_type_quals_match): Removed.
9faeb493 6121
7c475d11
JM
61222010-11-30 Joseph Myers <joseph@codesourcery.com>
6123
6124 * c-common.h (parse_optimize_options): Declare.
6125 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
6126 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
6127
71f3e391
JM
61282010-11-29 Joseph Myers <joseph@codesourcery.com>
6129
6130 * c-opts.c (check_deps_environment_vars): Use getenv instead of
6131 GET_ENVIRONMENT.
6132 * c-pch.c (O_BINARY): Don't define here.
6133 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
6134
d5fabb58
JM
61352010-11-25 Joseph Myers <joseph@codesourcery.com>
6136
6137 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
6138 targetm.except_unwind_info.
6139
299404a1
JM
61402010-11-23 Joseph Myers <joseph@codesourcery.com>
6141
6142 * c-opts.c (c_common_handle_option): Pass location to
6143 set_struct_debug_option.
6144
c98cd5bf
JM
61452010-11-23 Joseph Myers <joseph@codesourcery.com>
6146
6147 * c-common.c (visibility_options): Move from ../opts.c.
6148 * c-common.h (struct visibility_flags, visibility_options):
6149 Declare here.
6150 * c-opts.c (finish_options): Rename to c_finish_options.
6151 (c_common_init): Update call to finish_options.
6152
a9546771
NP
61532010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
6154
6155 PR objc/34033
6156 * c-lex.c (lex_string): Check that each string in an Objective-C
6157 string concat sequence starts with either one or zero '@', and
6158 that there are no spurious '@' signs at the end.
6159
24a57808
JM
61602010-11-20 Joseph Myers <joseph@codesourcery.com>
6161
6162 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
6163 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
6164 HANDLE_PRAGMA_VISIBILITY.
6165 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
6166 HANDLE_PRAGMA_VISIBILITY): Don't define.
6167 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
6168
a9aa2c3a
NF
61692010-11-20 Nathan Froyd <froydnj@codesourcery.com>
6170
6171 PR c++/16189
6172 PR c++/36888
6173 PR c++/45331
6174 * c-common.h (keyword_begins_type_specifier): Declare.
6175 (keyword_is_storage_class_specifier): Declare.
6176 (keyword_is_type_qualifier): Declare.
6177 * c-common.c (keyword_begins_type_specifier): New function.
6178 (keyword_is_storage_class_specifier): New function.
6179 (keyword_is_type_qualifier): Declare.
6180
5386338c
JM
61812010-11-19 Joseph Myers <joseph@codesourcery.com>
6182
6183 PR c/46547
6184 * c-common.c (in_late_binary_op): Define.
6185 (c_common_truthvalue_conversion): Check in_late_binary_op before
6186 calling c_save_expr.
6187 * c-common.h (in_late_binary_op): Declare.
6188
69ccdddb
JM
61892010-11-19 Joseph Myers <joseph@codesourcery.com>
6190
6191 * c-opts.c (c_common_handle_option): Update calls to
6192 set_struct_debug_option.
6193
6b192a09
NP
61942010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
6195
6196 * c-common.h (objc_declare_protocols): Added additional argument.
6197 * stub-objc.c (objc_declare_protocol): Same change.
9faeb493 6198
fb52b50a
NF
61992010-11-18 Nathan Froyd <froydnj@codesourcery.com>
6200
6201 PR c/33193
6202 * c-common.h (build_real_imag_expr): Declare.
6203 * c-semantics.c (build_real_imag_expr): Define.
6204
b37421c6
JM
62052010-11-17 Joseph Myers <joseph@codesourcery.com>
6206
6207 * c-opts.c (c_common_parse_file): Take no arguments.
6208 * c-common.h (c_common_parse_file): Update prototype.
6209
07078664
JJ
62102010-11-16 Jakub Jelinek <jakub@redhat.com>
6211
6212 PR c++/46401
6213 * c-common.c (warning_candidate_p): Don't track non-const calls
6214 or STRING_CSTs.
6215
c6a13190
ILT
62162010-11-15 Ian Lance Taylor <iant@google.com>
6217
6218 * c-lex.c (init_c_lex): Set macro debug callbacks if
6219 flag_dump_go_spec is set.
6220
925e8657
NP
62212010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
6222
6223 * c-common.h (objc_build_incr_expr_for_property_ref): New.
6224 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
6225
bb0a9581
NF
62262010-11-15 Nathan Froyd <froydnj@codesourcery.com>
6227
6228 PR preprocessor/45038
6229 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
6230 dialects.
6231
c5fa0890
JM
62322010-11-12 Joseph Myers <joseph@codesourcery.com>
6233
6234 * c-common.h (c_family_lang_mask): Declare.
6235 * c-opts.c (c_family_lang_mask): Make extern.
6236 * c-pragma.c (handle_pragma_diagnostic): Use
6237 control_warning_option.
6238
a4d8c676
JM
62392010-11-12 Joseph Myers <joseph@codesourcery.com>
6240
6241 * c-common.c (parse_optimize_options): Update call to
6242 decode_options.
6243 * c-common.h (c_common_handle_option): Update prototype.
6244 * c-opts.c (c_common_handle_option): Take location_t parameter and
6245 pass it to other functions.
6246
f954bd2c
JM
62472010-11-11 Joseph Myers <joseph@codesourcery.com>
6248
6249 * c-opts.c (warning_as_error_callback): Remove.
6250 (c_common_initialize_diagnostics): Don't call
6251 register_warning_as_error_callback.
6252 (c_common_handle_option): Handle -Werror=normalized= here.
6253
d8a07487
JM
62542010-11-10 Joseph Myers <joseph@codesourcery.com>
6255
6256 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
6257 in diagnostic.
6258 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
6259 letter.
6260 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
6261 Remove trailing '.' from diagnostics.
6262 * c.opt (Wwrite-strings_: Avoid '`' in help text.
6263
d5478783
JM
62642010-11-10 Joseph Myers <joseph@codesourcery.com>
6265
6266 * c-common.c (parse_optimize_options): Pass global_dc to
6267 decode_options.
6268 * c-opts.c (c_common_handle_option): Pass &global_options to
6269 set_Wstrict_aliasing.
6270 * c.opt (v): Don't mark Common or document here.
6271
91ebb981
IS
62722010-11-06 Iain Sandoe <iains@gcc.gnu.org>
6273
6274 PR target/44981
6275 * c-format.c (format_type): New type gcc_objc_string_format_type.
6276 (valid_stringptr_type_p): New.
6277 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
9faeb493 6278 (check_format_string): Pass expected type, use
91ebb981
IS
6279 valid_stringptr_type_p (), check that the format string types are
6280 consistent with the format specification.
6281 (decode_format_attr): Warn if NSString is used outside objective-c.
6282 (format_types_orig): Add NSString.
6283 (format_name): New.
6284 (format_flags): New.
6285 (check_format_arg): Handle format strings requiring an external parser.
6286 first_target_format_type: New variable.
6287 (handle_format_attribute): Set up first_target_format_type, pass the
6288 expected format arg string type to check_format_string().
6289 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
6290 * stub-objc.c (objc_string_ref_type_p): New.
6291 (objc_check_format_arg): New.
6292
bede2adc
NP
62932010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
6294
9faeb493 6295 Fixed using the Objective-C 2.0 dot-syntax with class names.
bede2adc
NP
6296 * c-common.h (objc_build_class_component_ref): New.
6297 * stub-objc.c (objc_build_class_component_ref): New.
6298
9a179d01
NP
62992010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
6300
6301 * c.opt (Wproperty-assign-default): New option.
6302
22d8d616
NP
63032010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
6304
6305 Implemented -fobjc-std=objc1 flag.
6306 * c.opt (fobjc-std=objc1): New option.
6307
2debdb4f
NP
63082010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
6309
6310 Implemented format and noreturn attributes for Objective-C methods.
6311 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
6312 attribute for Objective-C methods.
6313
ec52b111
JM
63142010-10-31 Jason Merrill <jason@redhat.com>
6315
6316 * c-common.c (conversion_warning, warn_for_collisions_1): Use
6317 EXPR_LOC_OR_HERE.
6318
46a88c12
NP
63192010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
6320
6321 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
6322 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
6323 (objc_add_property_declaration): Removed arguments for copies and
6324 ivar.
6325 (objc_build_getter_call): Renamed to
6326 objc_maybe_build_component_ref.
6327 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
6328 (objc_is_property_ref): New.
6329 * c-common.c (c_common_reswords): Removed copies and ivar.
6330 * stub-objc.c (objc_add_property_declaration): Removed arguments
6331 for copies and ivar.
6332 (objc_build_getter_call): Renamed to
6333 objc_maybe_build_component_ref.
6334 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
6335 (objc_is_property_ref): New.
9faeb493 6336
1e4bf85b
AC
63372010-10-29 Arnaud Charlet <charlet@adacore.com>
6338 Matthew Gingell <gingell@adacore.com>
6339
6340 * c-ada-spec.c (separate_class_package): New function.
6341 (pp_ada_tree_identifier): Prefix references to C++ classes with the
6342 name of their enclosing package.
6343 (print_ada_declaration): Use separate_class_package.
6344
81f0bab2
JM
63452010-10-27 Jason Merrill <jason@redhat.com>
6346
2b08f2c5
JM
6347 * c-common.c (c_common_reswords): Add __is_literal_type.
6348 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
6349
81f0bab2
JM
6350 * c-common.c (check_case_value): Remove special C++ code.
6351
200290f2
NP
63522010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
6353
6354 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
6355 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
6356 and RID_LAST_PATTR.
6357 (objc_add_property_declaration): Added additional arguments.
6358 (objc_property_attribute_kind): Removed.
6359 (objc_set_property_attr): Removed.
6360 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
6361 copy and nonatomic.
6362 * stub-objc.c (objc_add_property_declaration): Added additional
6363 arguments.
6364 (objc_set_property_attr): Removed.
9faeb493 6365
f614132b
NP
63662010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
6367
6368 * c-common.h (objc_add_property_variable): Renamed to
6369 objc_add_property_declaration. Added location argument.
6370 * stub-objc.c (objc_add_property_variable): Same change.
b1726d6c 6371
b8a18805
NP
63722010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
6373
6374 * c-common.h (objc_maybe_printable_name): New.
6375 * stub-objc.c (objc_maybe_printable_name): New.
6376
3f8257db
JJ
63772010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
6378 Andrew Pinski <pinskia@gmail.com>
30cd1c5d
AS
6379
6380 * c-common.h (c_common_mark_addressable_vec): Declare.
6381 * c-common.c (c_common_mark_addressable_vec): New function.
6382
249a82c4
NP
63832010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
6384
6385 * c-common.h (objc_set_method_type): Removed.
6386 (objc_add_method_declaration): Added boolean argument.
6387 (objc_start_method_definition): Same change.
6388 (objc_build_method_signature): Same change.
6389 * stub-objc.c (objc_set_method_type): Removed.
6390 (objc_add_method_declaration): Added boolean argument.
6391 (objc_start_method_definition): Same change.
6392 (objc_build_method_signature): Same change.
6393
977e30bc
NP
63942010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
6395
6396 * c-common.h (finish_file): Removed.
6397 (objc_write_global_declarations): New.
6398 * c-opts.c (c_common_parse_file): Do not call finish_file.
6399 * stub-objc.c (objc_write_global_declarations): New.
9faeb493 6400
da57d1b9
NP
64012010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
6402
6403 Implemented parsing @synthesize and @dynamic for
6404 Objective-C/Objective-C++.
6405 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
6406 (objc_add_synthesize_declaration): New.
6407 (objc_add_dynamic_declaration): New.
6408 * c-common.c (c_common_reswords): Add synthesize and dynamic.
6409 * stub-objc.c (objc_add_synthesize_declaration): New.
6410 (objc_add_dynamic_declaration): New.
9faeb493 6411
0069111f
MM
64122010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
6413
6414 PR target/46041
6415 * c-cppbuiltin.c (mode_has_fma): Move function here from
6416 builtins.c. Don't use the fma optab, instead just use the
6417 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
6418 using -save-temps.
6419
e426b47b
NP
64202010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
6421
6422 Merge from 'apple/trunk' branch on FSF servers.
0069111f 6423
3f8257db 6424 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
e426b47b 6425
9faeb493 6426 Radar 4330422
e426b47b
NP
6427 * c-common.h (objc_non_volatilized_type): New declaration
6428 * stub-objc.c (objc_non_volatilized_type): New stub.
6429
90fbfdc3
NP
64302010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
6431
e426b47b 6432 Merge from 'apple/trunk' branch on FSF servers.
90fbfdc3 6433
3f8257db 6434 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
90fbfdc3 6435
9faeb493 6436 Radar 4133425
90fbfdc3 6437 * c-common.h (objc_diagnose_private_ivar): New decl.
0069111f 6438 * stub-objc.c (objc_diagnose_private_ivar): New stub.
90fbfdc3 6439
c37d8c30
IS
64402010-10-17 Iain Sandoe <iains@gcc.gnu.org>
6441
6442 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
6443 * c-common.h (enum rid): Add RID_AT_PACKAGE.
6444 (objc_ivar_visibility_kind): New enum.
6445 (objc_set_visibility): Adjust prototype to use visibility enum.
0069111f 6446 * stub-objc.c (objc_set_visibility): Adjust stub to use
c37d8c30
IS
6447 visibility enum.
6448
1b1562a5
MM
64492010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
6450
6451 * c-cppbuiltin.c (builtin_define_float_constants): Emit
6452 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
6453 has the appropriate fma builtins.
6454 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
6455
668ea4b1
IS
64562010-10-14 Iain Sandoe <iains@gcc.gnu.org>
6457
1b1562a5 6458 merge from FSF apple 'trunk' branch.
3f8257db 6459 2006 Fariborz Jahanian <fjahanian@apple.com>
1b1562a5 6460
668ea4b1
IS
6461 Radars 4436866, 4505126, 4506903, 4517826
6462 * c-common.c (c_common_resword): Define @property and its attributes.
6463 * c-common.h: Define property attribute enum entries.
6464 (OBJC_IS_PATTR_KEYWORD): New.
6465 (objc_property_attribute_kind): New enum.
6466 Declare objc_set_property_attr (), objc_add_property_variable (),
6467 objc_build_getter_call () and objc_build_setter_call ().
6468 * stub-objc.c (objc_set_property_attr): New stub.
6469 (objc_add_property_variable): Likewise.
6470 (objc_build_getter_call): Likewise.
6471 (objc_build_setter_call) Likewise.
1b1562a5 6472
a1178b30
IS
64732010-10-13 Iain Sandoe <iains@gcc.gnu.org>
6474
1b1562a5 6475 merge from FSF apple 'trunk' branch.
3f8257db 6476 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
a1178b30
IS
6477
6478 Radar 3803157 (method attributes)
6479 * c-common.c (handle_deprecated_attribute): Recognize
6480 objc methods as valid declarations.
6481 * c-common.h: Declare objc_method_decl ().
1b1562a5 6482 * stub-objc.c (objc_method_decl): New stub.
a1178b30 6483
a75bfaa6
JM
64842010-10-08 Joseph Myers <joseph@codesourcery.com>
6485
6486 * c-common.c (parse_optimize_options): Call
6487 decode_cmdline_options_to_array_default_mask before
6488 decode_options. Update arguments to decode_options.
6489 * c-common.h (c_common_init_options_struct): Declare.
6490 * c-opts.c (c_common_init_options_struct): New. Split out from
6491 c_common_init_options.
6492
f05b9d93
NP
64932010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
6494
6495 Implemented fast enumeration for Objective-C.
6496 * c-common.h (objc_finish_foreach_loop): New.
6497 * stub-objc.c (objc_finish_foreach_loop): New.
6498
1ebe4b4f
JM
64992010-10-05 Joseph Myers <joseph@codesourcery.com>
6500
6501 * c-common.h (struct diagnostic_context): Don't declare here.
6502 (c_common_initialize_diagnostics): Declare using
6503 diagnostic_context typedef.
6504 * c-opts.c (c_common_handle_option): Pass global_dc to
6505 handle_generated_option.
6506
d4d24ba4
JM
65072010-10-04 Joseph Myers <joseph@codesourcery.com>
6508
6509 * c-opts.c (c_common_handle_option): Pass &global_options_set to
6510 handle_generated_option.
6511
478a1c5b
ILT
65122010-10-03 Ian Lance Taylor <iant@google.com>
6513
6514 * c.opt (-fplan9-extensions): New option.
6515
82a1c2fe
FXC
65162010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
6517
6518 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
6519 Remove.
6520 (c_cpp_builtins): Call functions from cppbuiltin.c instead
6521 of duplicating code.
6522
92902b1b
IS
65232010-09-30 Iain Sandoe <iains@gcc.gnu.org>
6524
6525 * c-common.c: Add two new entries for @optional
6526 and @required keywords.
6527
6528 merge from FSF 'apple/trunk' branch.
3f8257db 6529 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
92902b1b
IS
6530
6531 Radar 4386773
6532 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
6533 objective-c keywords.
6534 (objc_set_method_opt): New declaration.
6535 * stub-objc.c (objc_set_method_opt): New stub.
9faeb493 6536
46625112
JM
65372010-09-30 Joseph Myers <joseph@codesourcery.com>
6538
6539 * c-common.c (handle_optimize_attribute): Pass &global_options to
6540 cl_optimization_save and cl_optimization_restore.
6541 * c-opts.c (c_common_handle_option): Pass &global_options to
6542 handle_generated_option.
6543 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
6544 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
6545 &global_options to cl_optimization_restore.
6546
49b91f05
NP
65472010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
6548
6549 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
6550 Objective-C/Objective-C++ keywords.
6551
13ed556f 65522010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
a6341d57 6553
9faeb493
UB
6554 Merge from 'apple/trunk' branch on FSF servers.
6555
3f8257db 6556 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
a6341d57
NP
6557
6558 Radar 4281748
6559 * c-common.h (objc_check_global_decl): New declaration.
6560 * stub-objc.c (objc_check_global_decl): New stub.
6561
f0036cca
JM
65622010-09-29 Joseph Myers <joseph@codesourcery.com>
6563
6564 * c.opt: Don't use VarExists.
6565
e3339d0f
JM
65662010-09-29 Joseph Myers <joseph@codesourcery.com>
6567
6568 * c-common.c (c_cpp_error): Update names of diagnostic_context
6569 members.
6570 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
6571 cl_optimization members.
6572 * c-opts.c (warning_as_error_callback, c_common_handle_option,
6573 sanitize_cpp_opts, finish_options): Update names of cpp_options
6574 members.
6575
1973201f
NP
65762010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
6577
6578 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
6579 (objc_is_reserved_word): Removed.
6580 * c-common.c: Updated comments.
6581 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
6582 objc_is_reserved_word.
6583 * stub-objc.c (objc_is_reserved_word): Removed.
6584
f7e71da5
IS
65852010-09-28 Iain Sandoe <iains@gcc.gnu.org>
6586
9faeb493 6587 * c-common.h (objc_add_method_declaration): Adjust prototype to
f7e71da5
IS
6588 include attributes.
6589 (objc_start_method_definition): Likewise.
6590 (objc_build_keyword_decl): Likewise.
6591 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
6592 (objc_start_method_definition): Likewise.
6593 (objc_build_keyword_decl): Likewise.
6594
c165dca7
IS
65952010-09-28 Iain Sandoe <iains@gcc.gnu.org>
6596
6597 * c-common.h (objc_start_class_interface): Adjust prototype.
6598 (objc_start_category_interface): Likewise.
6599 (objc_start_protocol): Likewise.
6600 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
6601 (objc_start_class_interface): Likewise.
6602 (objc_start_category_interface): Likewise.
6603
7458026b
ILT
66042010-09-27 Ian Lance Taylor <iant@google.com>
6605
6606 * c-common.c (c_common_attribute_table): Add no_split_stack.
6607 (handle_no_split_stack_attribute): New static function.
6608
b581b85b
NP
66092010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
6610
9faeb493 6611 Merge from 'apple/trunk' branch on FSF servers.
b581b85b 6612
3f8257db 6613 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
b581b85b 6614
9faeb493 6615 Radar 4229905
b581b85b
NP
6616 * c-common.h (objc_have_common_type): New declaration.
6617 * stub-objc.c (objc_have_common_type): New stub.
6618
6619 2005-06-22 Ziemowit Laski <zlaski@apple.com>
6620
6621 Radar 4154928
6622 * c-common.h (objc_common_type): New prototype.
9faeb493 6623 * stub-objc.c (objc_common_type): New stub.
b581b85b 6624
46a4da10
JH
66252010-09-24 Jan Hubicka <jh@suse.cz>
6626
6627 * c-common.c (handle_leaf_attribute): New function.
6628 (struct attribute_spec c_common_att): Add leaf.
6629
e200444e
JM
66302010-09-22 Joseph Myers <joseph@codesourcery.com>
6631
6632 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
6633 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
6634 -dump, -dump=, -imacros, -imacros=, -include, -include=,
6635 -include-barrier, -include-directory, -include-directory=,
6636 -include-directory-after, -include-directory-after=,
6637 -include-prefix, -include-prefix=, -include-with-prefix,
6638 -include-with-prefix=, -include-with-prefix-after,
6639 -include-with-prefix-after=, -include-with-prefix-before,
6640 -include-with-prefix-before=, -no-integrated-cpp,
6641 -no-line-commands, -no-standard-includes, -no-warnings, -output,
6642 -output=, -pedantic, -pedantic-errors, -preprocess,
6643 -print-missing-file-dependencies, -trace-includes, -traditional,
6644 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
6645 -user-dependencies, -verbose, -write-dependencies,
6646 -write-user-dependencies, no-integrated-cpp, traditional): New.
6647
29a80ea6
NP
66482010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
6649
6650 PR objc/23710
ac1fc2fc
NP
6651 * c-common.h (objc_start_method_definition): Return bool instead
6652 of void.
6653 * stub-objc.c (objc_start_method_definition): Return bool instead
6654 of void.
6655
66562010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
6657
6658 PR objc/25965
6659 * c-common.h (objc_get_interface_ivars): New declaration.
6660 * stub-objc.c (objc_get_interface_ivars): New stub.
29a80ea6 6661
de621752
ILT
66622010-09-15 Ian Lance Taylor <iant@google.com>
6663
6664 * c-common.c (parse_optimize_options): Do not capitalize warning
06730c5d 6665 messages. Remove period at end of warning message.
de621752 6666
ba885ec5
NS
66672010-09-09 Nathan Sidwell <nathan@codesourcery.com>
6668
6669 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
6670 (handle_alias_attribute): ... here.
6671 (handle_ifunc_attribute): New.
6672
c5ee1358
MM
66732010-09-06 Mark Mitchell <mark@codesourcery.com>
6674
6675 * c-common.h (do_warn_double_promotion): Declare.
6676 * c-common.c (do_warn_double_promotion): Define.
6677
0a0b3574
MM
66782010-09-05 Mark Mitchell <mark@codesourcery.com>
6679
6680 * c.opt (Wdouble-promotion): New.
6681
d1779886
JM
66822010-09-02 Joseph Myers <joseph@codesourcery.com>
6683
6684 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
6685 fvtable-thunks, fxref): Mark no longer supported in help text.
6686
2d2bd949
JM
66872010-09-02 Joseph Myers <joseph@codesourcery.com>
6688
6689 * c.opt (Wimport, fall-virtual, falt-external-templates,
6690 fdefault-inline, fenum-int-equiv, fexternal-templates,
6691 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
6692 fname-mangling-version-, fnew-abi, fnonnull-objects,
6693 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
6694 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
6695 applicable.
6696 (fhandle-exceptions): Mark with Alias and Warn.
6697 * c-opts.c (c_common_handle_option): Don't handle options marked
6698 as ignored.
6699
5de8299c
JM
67002010-09-02 Joseph Myers <joseph@codesourcery.com>
6701
6702 * c.opt (Wcomments, Werror-implicit-function-declaration,
6703 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
6704 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
6705 aliases.
6706 * c-common.c (option_codes): Use OPT_Wcomment instead of
6707 OPT_Wcomments.
6708 * c-opts.c (warning_as_error_callback, c_common_handle_option):
6709 Don't handle options marked as aliases.
6710
0ceb0201
RG
67112010-08-25 Richard Guenther <rguenther@suse.de>
6712
6713 * c-common.c (c_common_get_alias_set): Remove special
6714 handling for pointers.
6715
ac47786e
NF
67162010-08-20 Nathan Froyd <froydnj@codesourcery.com>
6717
6718 * c-common.c: Use FOR_EACH_VEC_ELT.
6719 * c-gimplify.c: Likewise.
6720 * c-pragma.c: Likewise.
6721
c878765b
JM
67222010-08-16 Joseph Myers <joseph@codesourcery.com>
6723
6724 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
6725 RejectDriver.
6726 (MMDX): Change back to MMD. Mark NoDriverArg instead of
6727 RejectDriver.
6728 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
6729 instead of OPT_MDX and OPT_MMDX.
6730
603349bf
JM
67312010-08-16 Joseph Myers <joseph@codesourcery.com>
6732
6733 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
6734
644fa7ac
JM
67352010-08-12 Joseph Myers <joseph@codesourcery.com>
6736
6737 * c.opt (MD, MMD): Change to MDX and MMDX.
6738 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
6739
481e1176
JM
67402010-08-11 Joseph Myers <joseph@codesourcery.com>
6741
6742 * c-opts.c (c_common_handle_option): Call handle_generated_option
6743 instead of handle_option.
6744
ac8dc9f7
NF
67452010-08-08 Nathan Froyd <froydnj@codesourcery.com>
6746
6747 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
6748 (maybe_apply_renaming_pragma): Delete unneeded declarations.
6749
4f8c876d
NF
67502010-08-08 Nathan Froyd <froydnj@codesourcery.com>
6751
6752 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
6753 (pending_redefine_extname): Change type to a VEC.
6754 (add_to_renaming_pragma_list): Update for new type of
6755 pending_redefine_extname.
ac8dc9f7 6756 (maybe_apply_renaming_pragma): Likewise.
4f8c876d 6757
3b0c690e
AC
67582010-08-04 Arnaud Charlet <charlet@adacore.com>
6759
6760 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
6761 visited.
6762 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
6763 decide whether a type has already been declared/seen.
6764 Do not go to the original type.
6765 (dump_nested_types): New parameter forward.
6766 Generate forward declaration if needed and mark type as visited.
6767 (print_ada_declaration): Call dump_nested_types if not already done.
6768 Mark types as visited.
6769
1890bccc
JM
67702010-08-03 Joseph Myers <joseph@codesourcery.com>
6771
6772 * c.opt (-print-pch-checksum): Remove option.
6773 * c-opts.c (c_common_handle_option): Don't handle
6774 OPT_print_pch_checksum.
6775
5f20c657
JM
67762010-07-27 Joseph Myers <joseph@codesourcery.com>
6777
6778 * c-common.h (c_common_handle_option): Update prototype and return
6779 value type.
6780 * c-opts.c (c_common_handle_option): Update prototype and return
6781 value type. Update calls to handle_option and
6782 enable_warning_as_error.
6783
f551f80c
JJ
67842010-07-27 Jakub Jelinek <jakub@redhat.com>
6785
6786 PR c/45079
6787 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
6788
61ff2bdc
JM
67892010-07-27 Joseph Myers <joseph@codesourcery.com>
6790
6791 * c-common.h (c_common_missing_argument): Remove.
6792 * c-opts.c (c_common_missing_argument): Remove.
6793 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
6794 idirafter, imacros, include, isysroot, isystem, iquote): Add
6795 MissingArgError.
6796 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
6797
7a9bf9a4
JM
67982010-07-27 Joseph Myers <joseph@codesourcery.com>
6799
6800 * c-common.h (c_common_option_lang_mask,
6801 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
6802 New.
6803 (c_common_init_options): Update prototype.
6804 * c-opts.c (c_common_option_lang_mask): New.
6805 (c_common_initialize_diagnostics): Split out of
6806 c_common_init_options.
6807 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
6808 New.
6809 (c_common_init_options): Update prototype. Use decoded options in
6810 search for -lang-asm.
6811
910ad8de
NF
68122010-07-15 Nathan Froyd <froydnj@codesourcery.com>
6813
6814 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
6815 * c-format.c: Likewise.
6816
718f9c0f
MLI
68172010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
6818
6819 * c-common.h: Include diagnostic-core.h. Error if already
6820 included.
6821 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
6822
4d451982
MLI
68232010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
6824
adfac8df 6825 * c-common.c (IN_GCC_FRONTEND): Do not undef.
4d451982
MLI
6826 Do not include expr.h
6827 (vector_mode_valid_p): Move here.
6828
119fe915
SB
68292010-06-21 DJ Delorie <dj@redhat.com>
6830
6831 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
6832 allow these pragmas anywhere.
6833
68342010-06-14 Jakub Jelinek <jakub@redhat.com>
6835
6836 PR bootstrap/44509
6837 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
6838 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
6839 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
6840 ggc_strdup instead of xstrdup.
6841
68422010-06-10 Jakub Jelinek <jakub@redhat.com>
6843
6844 * c-cppbuiltin.c: Include cpp-id-data.h.
6845 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
6846 (lazy_hex_fp_value): New function.
6847 (builtin_define_with_hex_fp_value): Provide definitions lazily.
6848
6662d794
MLI
68492010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
6850
6851 * c-gimplify.c: Do not include tree-flow.h
6852
38f8b050
JR
68532010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
6854
6855 PR other/44034
6856 * c-common.c: Rename targetm member:
6857 targetm.enum_va_list -> targetm.enum_va_list_p
6858
9589f23e
AS
68592010-06-28 Anatoly Sokolov <aesok@post.ru>
6860
6861 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
6862
3b06d379
SB
68632010-06-28 Steven Bosscher <steven@gcc.gnu.org>
6864
6865 * c-cppbuiltin.c: Do not include except.h.
6866
d166d4c3
AK
68672010-06-24 Andi Kleen <ak@linux.intel.com>
6868
9faeb493
UB
6869 * c-common.c (warn_for_omitted_condop): New.
6870 * c-common.h (warn_for_omitted_condop): Add prototype.
d166d4c3 6871
70cb8be6
JM
68722010-06-21 Joseph Myers <joseph@codesourcery.com>
6873
6874 * c.opt (lang-objc): Remove.
6875 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
6876
a4c97feb
JR
68772010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
6878
6879 * c-opts.c: Include "tm_p.h".
6880
6e2f1956
JM
68812010-06-20 Joseph Myers <joseph@codesourcery.com>
6882
6883 * c-common.c (parse_optimize_options): Update call to
6884 decode_options.
6885
bc87224e
NF
68862010-06-18 Nathan Froyd <froydnj@codesourcery.com>
6887
6888 * c-common.c (record_types_used_by_current_var_decl): Adjust for
6889 new type of types_used_by_cur_var_decl.
6890
b49cf425
JR
68912010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
6892
6893 PR bootstrap/44512
6894 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
6895 for C++ standard compliance.
6896
59f9c2ed
JM
68972010-06-16 Jason Merrill <jason@redhat.com>
6898
6899 * c.opt: Add -Wnoexcept.
6900
33766b66
RG
69012010-06-16 Richard Guenther <rguenther@suse.de>
6902
6903 PR c/44555
6904 * c-common.c (c_common_truthvalue_conversion): Remove
6905 premature and wrong optimization concering ADDR_EXPRs.
6906
eff7e30c
AC
69072010-06-15 Arnaud Charlet <charlet@adacore.com>
6908
6909 * c-ada-spec.c (dump_sloc): Remove column info.
6910 (is_simple_enum): New function.
6911 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
6912 enum types when relevant.
6913
6312e84d
MLI
69142010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
6915
9faeb493 6916 * c-common.c (conversion_warning): Warn at expression
6312e84d
MLI
6917 location.
6918
1cb42611
JM
69192010-06-10 Joseph Myers <joseph@codesourcery.com>
6920
6921 * c-opts.c (c_common_handle_option): Don't handle
6922 OPT_fshow_column.
6923
a9429e29
LB
69242010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
6925
6926 * c-pragma.c (push_alignment): Use typed GC allocation.
6927 (handle_pragma_push_options): Likewise.
6928
6929 * c-common.c (parse_optimize_options): Likewise.
6930
6931 * c-common.h (struct sorted_fields_type): Add variable_size GTY
6932 option.
6933
5498f011
JM
69342010-06-07 Joseph Myers <joseph@codesourcery.com>
6935
6936 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
6937 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
6938 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
6939 flag_signed_bitfields, warn_strict_null_sentinel,
6940 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
6941 flag_gen_declaration, flag_no_gnu_keywords,
6942 flag_implement_inlines, flag_implicit_templates,
6943 flag_implicit_inline_templates, flag_optional_diags,
6944 flag_elide_constructors, flag_default_inline, flag_rtti,
6945 flag_conserve_space, flag_access_control, flag_check_new,
6946 flag_new_for_scope, flag_weak, flag_working_directory,
6947 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
6948 flag_enforce_eh_specs, flag_threadsafe_statics,
6949 flag_pretty_templates): Remove.
6950 * c-common.h (flag_preprocess_only, flag_nil_receivers,
6951 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
6952 flag_replace_objc_classes, flag_undef, flag_no_builtin,
6953 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
6954 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
6955 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
6956 flag_no_gnu_keywords, flag_implement_inlines,
6957 flag_implicit_templates, flag_implicit_inline_templates,
6958 flag_optional_diags, flag_elide_constructors, flag_default_inline,
6959 flag_rtti, flag_conserve_space, flag_access_control,
6960 flag_check_new, flag_new_for_scope, flag_weak,
6961 flag_working_directory, flag_use_cxa_atexit,
6962 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
6963 flag_threadsafe_statics, flag_pretty_templates,
6964 warn_strict_null_sentinel): Remove.
6965 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
6966 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
6967 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
6968 fimplicit-inline-templates, fimplicit-templates,
6969 flax-vector-conversions, fms-extensions, fnil-receivers,
6970 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
6971 frtti, fshort-double, fshort-enums, fshort-wchar,
6972 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
6973 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
6974 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
6975 gen-decls, undef): Use Var.
6976 (fdefault-inline, foptional-diags): Document as doing nothing.
6977 * c-opts.c (c_common_handle_option): Remove cases for options now
6978 using Var. Mark ignored options as such.
6979
39dabefd
SB
69802010-06-05 Steven Bosscher <steven@gcc.gnu.org>
6981
9faeb493 6982 * c-common.c: Moved to here from parent directory.
39dabefd
SB
6983 * c-common.def: Likewise.
6984 * c-common.h: Likewise.
6985 * c-cppbuiltin.c: Likewise.
6986 * c-dump.c: Likewise.
6987 * c-format.c: Likewise.
6988 * c-format.h : Likewise.
6989 * c-gimplify.c: Likewise.
6990 * c-lex.c: Likewise.
6991 * c-omp.c: Likewise.
6992 * c.opt: Likewise.
6993 * c-opts.c: Likewise.
6994 * c-pch.c: Likewise.
6995 * c-ppoutput.c: Likewise.
6996 * c-pragma.c: Likewise.
6997 * c-pragma.h: Likewise.
6998 * c-pretty-print.c: Likewise.
6999 * c-pretty-print.h: Likewise.
7000 * c-semantics.c: Likewise.
7001 * stub-objc.c: Likewise.
7002
7003 * c-common.c: Include gt-c-family-c-common.h.
7004 * c-pragma.c: Include gt-c-family-c-pragma.h.
7005\f
818ab71a 7006Copyright (C) 2010-2016 Free Software Foundation, Inc.
39dabefd
SB
7007
7008Copying and distribution of this file, with or without modification,
7009are permitted in any medium without royalty provided the copyright
7010notice and this notice are preserved.