]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c-family/ChangeLog
* defaults.h (STACK_OLD_CHECK_PROTECT): Adjust for -fno-exceptions.
[thirdparty/gcc.git] / gcc / c-family / ChangeLog
CommitLineData
e4cc057f 12015-09-14 Marek Polacek <polacek@redhat.com>
2
3 * c-opts.c (c_common_post_options): Set C++ standard earlier, before
4 setting various warnings.
5
85f5e2ee 62015-09-14 Marek Polacek <polacek@redhat.com>
7
8 * c-common.c (warn_for_sign_compare): Cast to unsigned when shifting
9 a negative value.
10
1bca8cbd 112015-09-11 Mark Wielaard <mjw@redhat.com>
12
13 PR c/28901
14 * c.opt (Wunused-variable): Option from common.opt.
15 (Wunused-const-variable): New option.
16
ee48893a 172015-09-09 Paolo Carlini <paolo.carlini@oracle.com>
18
19 PR c++/53184
20 * c.opt ([Wsubobject-linkage]): Add.
21
547c6b1f 222015-09-03 Martin Sebor <msebor@redhat.com>
23
24 PR c/66516
25 * c-common.h (c_decl_implicit, reject_gcc_builtin): Declare new
26 functions.
27 * c-common.c (reject_gcc_builtin): Define.
28
7e976b10 292015-09-02 Balaji V. Iyer <balaji.v.iyer@intel.com>
30
31 PR middle-end/60586
32 * c-common.h (cilk_gimplify_call_params_in_spawned_fn): New
33 prototype.
34 * c-gimplify.c (c_gimplify_expr): Added a call to the function
35 cilk_gimplify_call_params_in_spawned_fn.
36 * cilk.c (cilk_gimplify_call_params_in_spawned_fn): New function.
37 (gimplify_cilk_spawn): Removed EXPR_STMT and CLEANUP_POINT_EXPR
38 unwrapping.
39
9e6bcade 402015-08-25 Marek Polacek <polacek@redhat.com>
41
42 PR middle-end/67330
43 * c-common.c (handle_weak_attribute): Don't check whether the
44 visibility can be changed here.
45
af9de21d 462015-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
47
48 * c-lex.c (c_lex_with_flags): Use explicit locations.
49
6dc50383 502015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
51
52 * c-ada-spec.h, c-common.c, c-common.h, c-format.c, c-format.h,
53 c-objc.h, c-ppoutput.c, c-pragma.c, c-pragma.h: Remove useless
54
10902624 552015-08-18 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
56
57 PR middle-end/36757
58 * c-common.c (check_builtin_function_arguments): Add check
59 for BUILT_IN_SIGNBIT argument.
60
a03a71ab 612015-08-18 Paolo Carlini <paolo.carlini@oracle.com>
62
63 PR c++/67160
64 * c-cppbuiltin.c (c_cpp_builtins): Fix __cpp_static_assert value
65 in c++1z mode.
66
22723c26 672015-08-17 Marek Polacek <polacek@redhat.com>
68
69 * c-pretty-print.c (pp_c_cv_qualifiers): Remove code dealing
70 with whitespaces before qualifier names.
71
f4809955 722015-08-12 Marek Polacek <polacek@redhat.com>
73
74 PR c++/55095
75 * c-common.c (maybe_warn_shift_overflow): Properly handle
76 left-shifting 1 into the sign bit.
77
5463f502 782015-08-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
79
80 * c.opt (Wchkp): Use LangEnabledBy instead of EnabledBy.
81
56c12fd4 822015-08-06 Andrew Sutton <andrew.n.sutton@gmail.com>
83 Braden Obrzut <admin@maniacsvault.net>
84 Jason Merrill <jason@redhat.com>
85
86 Add C++ Concepts TS support.
87 * c-common.c (c_common_reswords): Add __is_same_as, concept, requires.
88 * c-common.h (enum rid): Add RID_IS_SAME_AS, RID_CONCEPT, RID_REQUIRES.
89 (D_CXX_CONCEPTS, D_CXX_CONCEPTS_FLAGS): New.
90 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_concepts.
91 * c-opts.c (set_std_cxx1z): Set flag_concepts.
92 * c.opt (fconcepts): New.
93
17afcef6 942015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
95
96 * c-indentation.c (should_warn_for_misleading_indentation):
97 Improve heuristics.
98
f95bfdd4 992015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
100
101 * c-indentation.c (get_visual_column): Add parameter first_nws,
102 use it. Update comment documenting the function.
103 (is_first_nonwhitespace_on_line): Remove.
104 (should_warn_for_misleading_indentation): Replace usage of
105 of is_first_nonwhitespace_on_line with get_visual_column.
106
9255be07 1072015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
108
109 * c-indentation.h (struct token_indent_info): Define.
110 (get_token_indent_info): Define.
111 (warn_for_misleading_information): Declare.
112 * c-common.h (warn_for_misleading_information): Remove.
113 * c-identation.c (warn_for_misleading_indentation):
114 Change declaration to take three token_indent_infos. Adjust
115 accordingly.
116 * c-identation.c (should_warn_for_misleading_indentation):
117 Likewise. Bail out early if the body is a compound statement.
118 (guard_tinfo_to_string): Define.
119
e880695c 1202015-07-30 Jason Merrill <jason@redhat.com>
121
122 * c-pretty-print.c (unary_expression) [INDIRECT_REF]: Don't print
123 '*' for reference decay.
124
f58dd84b 1252015-07-30 Marek Polacek <polacek@redhat.com>
126
127 * c-common.c (warn_tautological_cmp): Bail for float types.
128
d9e4fe27 1292015-07-27 Marek Polacek <polacek@redhat.com>
130
131 PR bootstrap/67030
132 * c-common.c (warn_tautological_cmp): Don't warn for macro expansion.
133
6784a472 1342015-07-27 Marek Polacek <polacek@redhat.com>
135
136 PR c++/66555
137 PR c/54979
138 * c-common.c (find_array_ref_with_const_idx_r): New function.
139 (warn_tautological_cmp): New function.
140 * c-common.h (warn_tautological_cmp): Declare.
141 * c.opt (Wtautological-compare): New option.
142
08034975 1432015-07-23 Marek Polacek <polacek@redhat.com>
144
145 * c-ubsan.c (ubsan_instrument_division): Use unshare_expr throughout.
146 (ubsan_instrument_shift): Likewise.
147
f6f5e49b 1482015-07-23 Marek Polacek <polacek@redhat.com>
149
150 PR sanitizer/66908
151 * c-ubsan.c: Include gimplify.h.
152 (ubsan_instrument_division): Unshare OP0 and OP1.
153 (ubsan_instrument_shift): Likewise.
154
8d669e79 1552015-07-20 Marek Polacek <polacek@redhat.com>
156 Richard Sandiford <richard.sandiford@arm.com>
157
158 PR c++/55095
159 * c-common.c (c_fully_fold_internal): Warn about left shift overflows.
160 Use EXPR_LOC_OR_LOC.
161 (maybe_warn_shift_overflow): New function.
162 * c-common.h (maybe_warn_shift_overflow): Declare.
163 * c-opts.c (c_common_post_options): Set warn_shift_overflow.
164 * c.opt (Wshift-overflow): New option.
165
e16712b1 1662015-07-16 Martin Liska <mliska@suse.cz>
167
168 * c-format.c (static void check_format_info_main): Use
169 object_allocator instead of pool_allocator.
170 (check_format_arg): Likewise.
171 (check_format_info_main): Likewise.
172
e51764ad 1732015-07-15 Andrew MacLeod <amacleod@redhat.com>
174
175 * c-opts.c: Remove multiline #include comment.
176
47ae02b7 1772015-07-12 Aldy Hernandez <aldyh@redhat.com>
178
179 * c-common.c: Fix double word typos.
180
ed2b2eb2 1812015-07-10 Eric Botcazou <ebotcazou@adacore.com>
182
183 * c-ada-spec.h (cpp_operation): Revert latest change.
184 * c-ada-spec.c (print_ada_declaration): Likewise. Skip implicit
185 constructors and destructors.
186
1eacc14a 1872015-07-09 Andrew MacLeod <amacleod@redhat.com>
188
189 * c-common.h: Adjust includes for flags.h changes.
190 * stub-objc.c: Likewise.
47ae02b7 191
0124237f 1922015-07-08 Eric Botcazou <ebotcazou@adacore.com>
193
194 * c-ada-spec.h (cpp_operation): Add IS_CONSTEXPR.
195 * c-ada-spec.c (print_ada_declaration): Skip constexpr constructors.
196
386ef929 1972015-07-08 Jakub Jelinek <jakub@redhat.com>
198
199 * c-omp.c (c_omp_declare_simd_clauses_to_numbers): If all clauses
200 are to be removed, return NULL rather than original clauses list.
201
9ef16211 2022015-07-07 Andrew MacLeod <amacleod@redhat.com>
203
204 * array-notation-common.c: Adjust includes.
205 * c-ada-spec.c: Likewise.
206 * c-cilkplus.c: Likewise.
207 * c-common.h: Likewise.
208 * c-cppbuiltin.c: Likewise.
209 * c-dump.c: Likewise.
210 * c-format.c: Likewise.
211 * c-gimplify.c: Likewise.
212 * c-indentation.c: Likewise.
213 * c-lex.c: Likewise.
214 * c-omp.c: Likewise.
215 * c-opts.c: Likewise.
216 * c-pch.c: Likewise.
217 * c-ppoutput.c: Likewise.
218 * c-pragma.c: Likewise.
219 * c-pretty-print.c: Likewise.
220 * c-semantics.c: Likewise.
221 * c-ubsan.c: Likewise.
222 * cilk.c: Likewise.
223 * stub-objc.c: Likewise.
224
67ede3e4 2252015-07-07 Eric Botcazou <ebotcazou@adacore.com>
226
227 * c-ada-spec.h (cpp_operation): Add IS_MOVE_CONSTRUCTOR.
228 * c-ada-spec.c (print_ada_declaration): Skip move constructors.
229
42af8c2a 2302015-07-01 Jason Merrill <jason@redhat.com>
231
fa769cc5 232 * c-common.h (D_CXX11): Rename from D_CXX0X.
233 (RID_FIRST_CXX11, RID_LAST_CXX11): Rename from *_CXX0X.
234 * c-common.c: Adjust.
235
97e9c847 236 * c-opts.c (c_common_post_options): Default to C++14.
237
42af8c2a 238 * c-opts.c (c_common_post_options): Highest ABI level is now 10.
239
30b1ba42 2402015-06-30 Edward Smith-Rowland <3dw4rd@verizon.net>
241
242 Implement N4197 - Adding u8 character literals
95858835 243 * c-family/c-ada-spec.c (print_ada_macros): Treat CPP_UTF8CHAR like
244 CPP_CHAR.
245 * c-family/c-common.c (c_parse_error): Print CPP_UTF8CHAR and
246 CPP_UTF8CHAR_USERDEF tokens.
247 * c-family/c-lex.c (c_lex_with_flags): Treat CPP_UTF8CHAR_USERDEF
248 and CPP_UTF8CHAR tokens.
249 (lex_charconst): Treat CPP_UTF8CHAR token.
30b1ba42 250
0949f227 2512015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
252
253 PR fortran/66605
254 * c-common.c (do_warn_unused_parameter): Move here.
255 * c-common.h (do_warn_unused_parameter): Declare.
256
be23b16f 2572015-06-29 Marek Polacek <polacek@redhat.com>
258
259 PR c/66322
260 * c-common.c (check_case_bounds): Add bool * parameter. Set
261 OUTSIDE_RANGE_P.
262 (c_add_case_label): Add bool * parameter. Pass it down to
263 check_case_bounds.
264 (c_do_switch_warnings): Add bool parameters. Implement -Wswitch-bool
265 warning here.
266 * c-common.h (c_add_case_label, c_do_switch_warnings): Update
267 declarations.
268
6290f0db 2692015-06-27 Marek Polacek <polacek@redhat.com>
270
271 * c-common.c (check_main_parameter_types): Use VECTOR_TYPE_P
272 or VECTOR_INTEGER_TYPE_P throughout.
273 * c-gimplify.c: Likewise.
274
aa3e402e 2752015-06-26 Marek Polacek <polacek@redhat.com>
276
277 * array-notation-common.c (find_rank): Use INDIRECT_REF_P.
278 * c-common.c (c_fully_fold_internal): Likewise.
279 (c_alignof_expr): Likewise.
280 * c-pretty-print.c (c_pretty_printer::postfix_expression): Likewise.
281 * c-ubsan.c (ubsan_instrument_bounds): Likewise.
282 * cilk.c (create_parm_list): Likewise.
283
4e81b384 2842015-06-26 Marek Polacek <polacek@redhat.com>
285
286 * c-common.c (handle_unused_attribute): Use VAR_OR_FUNCTION_DECL_P.
287
ec2e0095 2882015-06-25 Andrew MacLeod <amacleod@redhat.com>
289
290 * c-common.c: Remove ipa-ref.h and plugin-api.h from include list.
291 * c-gimplify.c: Likewise.
292 * c-pragma.c: Likewise.
293 * c-ubsan.c: Likewise.
294 * cilk.c: Likewise.
295
b594087e 2962015-06-25 Richard Sandiford <richard.sandiford@arm.com>
297
298 * c-common.c (c_type_hasher): Inherit from ggc_ptr_hash rather than
299 ggc_hasher.
300
a3c76fda 3012015-06-25 Andrew MacLeod <amacleod@redhat.com>
302
303 * cilk.c: Move calls.h after tm.h in the include chain.
304
f48c7f4a 3052015-06-25 Marek Polacek <polacek@redhat.com>
306
307 * array-notation-common.c: Use VAR_P throughout.
308 * c-ada-spec.c: Likewise.
309 * c-common.c: Likewise.
310 * c-format.c: Likewise.
311 * c-gimplify.c: Likewise.
312 * c-omp.c: Likewise.
313 * c-pragma.c: Likewise.
314 * c-pretty-print.c: Likewise.
315 * cilk.c: Likewise.
316
ce41e81a 3172015-06-25 Marek Polacek <polacek@redhat.com>
318
319 * cilk.c (extract_free_variables): Use is_global_var.
320
de231ec2 3212015-06-23 Richard Sandiford <richard.sandiford@arm.com>
322
323 * c-common.c: Don't include target-def.h.
324
0200602e 3252015-06-23 Marek Polacek <polacek@redhat.com>
326
327 * c-common.c (warn_logical_operator): Use tree_int_cst_equal
328 when comparing INTEGER_CSTs.
329
99838ed7 3302015-06-22 Pierre-Marie de Rodat <derodat@adacore.com>
331
332 * c-ada-spec.h (cpp_operation): Add HAS_DEPENDENT_TEMPLATE_ARGS.
333 * c-ada-spec.c (collect_ada_nodes): Skip NAMESPACE_DECL
334 (dump_ada_template): Skip partially specialized types.
335
a4f59596 3362015-06-22 Mikhail Maltsev <maltsevm@gmail.com>
337
338 * c-common.c (scalar_to_vector): Use std::swap instead of manually
339 swapping.
340
f2ab3bac 3412015-06-17 Andrew MacLeod <amacleod@redhat.com>
342
343 * array-notation-common.c: Do not include input.h, line-map.h or is-a.h.
344 * c-ada-spec.c: Likewise.
345 * c-cilkplus.c: Likewise.
346 * c-common.c: Likewise.
347 * c-common.h: Likewise.
348 * c-cppbuiltin.c: Likewise.
349 * c-dump.c: Likewise.
350 * c-format.c: Likewise.
351 * c-gimplify.c: Likewise.
352 * c-indentation.c: Likewise.
353 * c-lex.c: Likewise.
354 * c-omp.c: Likewise.
355 * c-opts.c: Likewise.
356 * c-pch.c: Likewise.
357 * c-ppoutput.c: Likewise.
358 * c-pragma.c: Likewise.
359 * c-pretty-print.c: Likewise.
360 * c-semantics.c: Likewise.
361 * c-ubsan.c: Likewise.
362 * cilk.c: Likewise.
363 * stub-objc.c: Likewise.
364
db3d1ffc 3652015-06-13 Patrick Palka <ppalka@gcc.gnu.org>
366
367 PR c++/65168
368 * c-common.c (c_common_truthvalue_conversion): Warn when
369 converting an address of a reference to a truth value.
370
64486212 3712015-06-08 Andrew MacLeod <amacleod@redhat.com>
372
373 * array-notation-common.c : Adjust include files.
374 * c-ada-spec.c : Likewise.
375 * c-cilkplus.c : Likewise.
376 * c-common.c : Likewise.
377 * c-common.h : Likewise.
378 * c-cppbuiltin.c : Likewise.
379 * c-dump.c : Likewise.
380 * c-format.c : Likewise.
381 * c-gimplify.c : Likewise.
382 * c-indentation.c : Likewise.
383 * c-lex.c : Likewise.
384 * c-omp.c : Likewise.
385 * c-opts.c : Likewise.
386 * c-pch.c : Likewise.
387 * c-ppoutput.c : Likewise.
388 * c-pragma.c : Likewise.
389 * c-pretty-print.c : Likewise.
390 * c-semantics.c : Likewise.
391 * c-ubsan.c : Likewise.
392 * cilk.c : Likewise.
393 * stub-objc.c : Likewise.
394
6e84ccad 3952015-06-08 Marek Polacek <polacek@redhat.com>
396
397 PR c/66415
398 * c-format.c (location_from_offset): Return LOC if LINE is null.
399
3a1c9df2 4002015-06-05 Aldy Hernandez <aldyh@redhat.com>
401
402 * c-common.h (c_parse_final_cleanups): New prototype.
403 * c-opts.c (c_common_parse_file): Call c_parse_final_cleanups.
404
f77c0292 4052015-06-04 Andrew MacLeod <amacleod@redhat.com>
406
407 * array-notation-common.c: Adjust includes for restructured coretypes.h.
408 * c-ada-spec.c: Likewise.
409 * c-cilkplus.c: Likewise.
410 * c-common.c: Likewise.
411 * c-common.h: Likewise.
412 * c-cppbuiltin.c: Likewise.
413 * c-dump.c: Likewise.
414 * c-format.c: Likewise.
415 * c-gimplify.c: Likewise.
416 * c-indentation.c: Likewise.
417 * c-lex.c: Likewise.
418 * c-omp.c: Likewise.
419 * c-opts.c: Likewise.
420 * c-pch.c: Likewise.
421 * c-ppoutput.c: Likewise.
422 * c-pragma.c: Likewise.
423 * c-pretty-print.c: Likewise.
424 * c-semantics.c: Likewise.
425 * c-ubsan.c: Likewise.
426 * cilk.c: Likewise.
427 * stub-objc.c: Likewise.
428
7c62dfbb 4292015-06-02 David Malcolm <dmalcolm@redhat.com>
430
431 PR c/66220:
432 * c-indentation.c (should_warn_for_misleading_indentation): Use
433 expand_location rather than expand_location_to_spelling_point.
434 Don't warn if the guarding statement is more indented than the
435 next/body stmts.
436
9af7c176 4372015-06-02 David Malcolm <dmalcolm@redhat.com>
438
439 * c-indentation.c (warn_for_misleading_indentation): Bail out
440 immediately if -Wmisleading-indentation isn't enabled.
441
eebcf436 4422015-06-01 Martin Liska <mliska@suse.cz>
443
444 * c-format.c (check_format_arg):Use new type-based pool allocator.
445 (check_format_info_main) Likewise.
446
b0a23e2f 4472015-05-31 Eric Botcazou <ebotcazou@adacore.com>
448
449 * c-ada-spec.c (is_tagged_type): Test for TYPE_METHODS on main variant.
450 (has_nontrivial_methods): Likewise.
451
63dc1330 4522015-05-25 Marek Polacek <polacek@redhat.com>
453
454 * c-ubsan.c (ubsan_instrument_shift): Use type0.
455
5a4c69dd 4562015-05-22 Marek Polacek <polacek@redhat.com>
457
458 PR c/47043
459 * c-common.c (handle_deprecated_attribute): Allow CONST_DECL.
460
044580bb 4612015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
3764c94e 462
463 * c-cppbuiltin.c (c_cpp_builtins): Use if instead of #if with
464 STACK_GROWS_DOWNWARD.
465
044580bb 4662015-05-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
2b785411 467
468 * c-cppbuiltin.c (c_cpp_builtins): Check the value of
469 STACK_GROWS_DOWNWARD rather than if it is defined.
470
d5a2ddc7 4712015-05-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
472
473 PR c/52952
474 * c-format.c (location_column_from_byte_offset): New.
475 (location_from_offset): New.
476 (struct format_wanted_type): Add offset_loc field.
477 (check_format_info): Move handling of location for extra arguments
478 closer to the point of warning.
479 (check_format_info_main): Pass the result of location_from_offset
480 to warning_at.
481 (format_type_warning): Pass the result of location_from_offset
482 to warning_at.
483
72f8014e 4842015-05-20 Marek Polacek <polacek@redhat.com>
485
486 * c-omp.c (check_omp_for_incr_expr): Use BINARY_CLASS_P.
487
74efe522 4882015-05-20 Marek Polacek <polacek@redhat.com>
489
490 * c-ada-spec.c (dump_sloc): Use DECL_P.
491
b443c459 4922015-05-20 Marek Polacek <polacek@redhat.com>
493
494 * c-pragma.c: Use VAR_OR_FUNCTION_DECL_P throughout.
495 * c-common.c: Likewise.
496
551e34da 4972015-05-19 David Malcolm <dmalcolm@redhat.com>
498
499 * c-common.h (fe_file_change): Strengthen param from
500 const line_map * to const line_map_ordinary *.
501 (pp_file_change): Likewise.
502 * c-lex.c (fe_file_change): Likewise.
503 (cb_define): Use linemap_check_ordinary when invoking
504 SOURCE_LINE.
505 (cb_undef): Likewise.
506 * c-opts.c (c_finish_options): Use linemap_check_ordinary when
507 invoking cb_file_change.
508 (c_finish_options): Likewise.
509 (push_command_line_include): Likewise.
510 (cb_file_change): Strengthen param "new_map" from
511 const line_map * to const line_map_ordinary *.
512 * c-ppoutput.c (cb_define): Likewise for local "map".
513 (pp_file_change): Likewise for param "map" and local "from".
514
dfcf26a5 5152015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
516
517 * c-common.c (shorten_compare): Use std::swap instead of explicit swaps.
518
2e474820 5192015-05-18 Tom de Vries <tom@codesourcery.com>
520
521 * c-common.c (build_va_arg_1): New function.
522 (build_va_arg): Add address operator to va_list operand if necessary.
523
e53013a8 5242015-05-15 Mikhail Maltsev <maltsevm@gmail.com>
525
526 PR c/48956
527 * c-common.c (int_safely_convertible_to_real_p): Define.
528 (unsafe_conversion_p): Check conversions involving complex types.
529 (conversion_warning): Add new warning message for conversions which
530 discard imaginary component.
531 * c-common.h: (enum conversion_safety): Add new enumerator for such
532 conversions.
533
aac24642 5342015-05-14 Marek Polacek <polacek@redhat.com>
535
536 PR c/66066
537 PR c/66127
538 * c-common.c (c_fully_fold): Pass false down to c_fully_fold_internal.
539 (c_fully_fold_internal): Fold C_MAYBE_CONST_EXPRs with
540 C_MAYBE_CONST_EXPR_INT_OPERANDS set. Add FOR_INT_CONST argument and
541 use it. If FOR_INT_CONST, require that all evaluated operands be
542 INTEGER_CSTs.
543
e5f01cba 5442015-05-12 David Malcolm <dmalcolm@redhat.com>
545
546 * c-common.h (warn_for_misleading_indentation): New prototype.
547 * c-indentation.c: New file.
548 * c.opt (Wmisleading-indentation): New option.
549
c37be9ec 5502015-05-12 Tom de Vries <tom@codesourcery.com>
551
552 PR tree-optimization/66010
553 * c-common.c (build_va_arg): Don't mark ap addressable unless necessary.
554
7290114b 5552015-05-09 Jason Merrill <jason@redhat.com>
556
3c665566 557 * c-opts.c (c_common_post_options): Also clear
558 cpp_opts->cpp_warn_cxx11_compat.
559
d875b9d2 560 * c-common.h (enum cxx_dialect): Add cxx_unset.
561 * c-common.c (cxx_dialect): Initialize to cxx_unset.
562 * c-opts.c (c_common_post_options): Set C++ dialect to C++98 if unset.
563
7290114b 564 * c.opt (std=c++14): Remove Undocumented flag and experimental warning.
565 (std=gnu++0x): Mark as Undocumented.
566 (std=gnu++1y): Add deprecated message.
567
1b03cc89 5682015-05-08 Jason Merrill <jason@redhat.com>
569
1c5f7aba 570 * c.opt (Wc++11-compat): Make primary. Rename var warn_cxx11_compat.
571 * c-opts.c: Adjust.
572
1b03cc89 573 * c.opt (Wc++0x-compat): Also set cpp_warn_cxx11_compat.
574
dc5945dc 5752015-05-08 Marek Polacek <polacek@redhat.com>
576
577 PR c/64918
578 * c.opt (Woverride-init-side-effects): New option.
579
cdc64059 5802015-05-07 Marek Polacek <polacek@redhat.com>
581
582 PR c/65179
583 * c-common.c (c_fully_fold_internal): Warn when left shifting a
584 negative value.
585 * c.opt (Wshift-negative-value): New option.
586 * c-opts.c (c_common_post_options): Set warn_shift_negative_value
587 when -Wextra and C99/C++11 mode.
588
8cafe283 5892015-05-07 Marek Polacek <polacek@redhat.com>
590 Martin Uecker <uecker@eecs.berkeley.edu>
591
592 * c-ubsan.c (ubsan_instrument_bounds): Don't skip instrumenting
593 flexible member array-like members if SANITIZE_BOUNDS_STRICT.
594
cb40a6f7 5952015-05-05 Jason Merrill <jason@redhat.com>
596
597 * c.opt (Wterminate): New.
598
14744a16 5992015-04-30 Marek Polacek <polacek@redhat.com>
600
601 * c-common.c (maybe_warn_bool_compare): When comparing with 0/1,
602 require that the non-constant be of a boolean type.
603
9866562d 6042015-04-29 Josh Triplett <josh@joshtriplett.org>
605
8cafe283 606 * c-common.c (handle_section_attribute): Refactor to reduce
607 nesting and distinguish between error cases.
9866562d 608
a720ab1c 6092015-04-29 Marek Polacek <polacek@redhat.com>
610
611 PR c/64610
612 * c-common.c (maybe_warn_bool_compare): Warn when comparing a boolean
613 with 0/1.
614
8c072e52 6152015-04-29 Jakub Jelinek <jakub@redhat.com>
616
617 * c-common.h (omp_clause_mask): Unconditionally define as a class.
618 Use uint64_t instead of unsigned HOST_WIDE_INT and 64 instead of
619 HOST_BITS_PER_WIDE_INT.
620
f7fec1c7 6212015-04-28 Tom de Vries <tom@codesourcery.com>
622
623 PR tree-optimization/65887
624 * c-common.c (build_va_arg): Mark va_arg ap argument as addressable.
625
483b3d26 6262015-04-28 Eric Botcazou <ebotcazou@adacore.com>
8cafe283 627 Pierre-Marie de Rodat <derodat@adacore.com>
483b3d26 628
629 * c-ada-spec.c (in_function): Delete.
630 (dump_generic_ada_node): Do not change in_function and remove the
631 redundant code dealing with it.
632 (print_ada_declaration): Do not change in_function. Use INDENT_INCR.
633 (print_ada_methods): Output the static member functions in a nested
634 package after the regular methods as well as associated renamings.
635
f11bdffb 6362015-04-24 Marek Polacek <polacek@redhat.com>
637
638 PR c/65830
639 * c-common.c (c_fully_fold_internal): Use OPT_Wshift_count_negative
640 and OPT_Wshift_count_overflow.
641
485f6b9c 642 PR c/63357
643 * c-common.c (warn_logical_operator): Warn if the operands have the
644 same expressions.
645
439606a9 6462015-04-24 Marek Polacek <polacek@redhat.com>
647
648 PR c/61534
649 * c-common.c (warn_logical_operator): Bail if either operand comes
650 from a macro expansion.
651
de801c28 6522015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
653
654 PR target/55143
655 * c-common.c (c_default_pointer_mode): Add definition.
656 * c-common.h (c_default_pointer_mode): Add declaration.
657
76738f56 6582015-03-11 Jakub Jelinek <jakub@redhat.com>
659
660 * c-common.c (c_common_nodes_and_builtins): Don't call xstrdup
661 on record_builtin_type argument.
662
16f958b3 6632015-03-10 Jakub Jelinek <jakub@redhat.com>
664
665 PR c/65120
666 * c-common.c (warn_logical_not_parentheses): Don't warn for
667 !x == 0 or !x != 0.
668
9b22f73f 6692015-03-07 Marek Polacek <polacek@redhat.com>
670
671 PR sanitizer/65280
672 * c-ubsan.c (ubsan_instrument_bounds): Check for COMPONENT_REF
673 before trying to figure out whether we have a flexible array member.
674
a864b7d4 6752015-03-06 Eric Botcazou <ebotcazou@adacore.com>
676 Jonathan Wakely <jwakely.gcc@gmail.com>
677
678 * c-ada-spec.c (dump_ada_double_name): Fix pasto.
679
9bf8c90b 6802015-03-05 Eric Botcazou <ebotcazou@adacore.com>
681
682 PR ada/65319
683 * c-ada-spec.c (print_destructor): Remove obsolete code.
684
037ac54f 6852015-03-01 Eric Botcazou <ebotcazou@adacore.com>
686
687 * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX.
688 (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and
689 DECL_TEMPLATE_RESULT emulations.
690 (dump_ada_template)): Add guard for TYPE_METHODS.
691
495cbfb8 6922015-02-27 Marek Polacek <polacek@redhat.com>
693
694 PR c/65040
695 * c.opt (Wformat-signedness): Don't enable by -Wformat=2.
696
688a864e 6972015-02-27 Kai Tietz <ktietz@redhat.com>
698
699 PR c/35330
700 * c-pragma.c (handle_pragma_weak): Do not try to create
701 weak/alias of declarations not being function, or variable
702 declarations.
703
6349b8cc 7042015-02-24 Thomas Schwinge <thomas@codesourcery.com>
705
706 PR libgomp/64625
707 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
708 Remove macros.
709 (DEF_FUNCTION_TYPE_VAR_7, DEF_FUNCTION_TYPE_VAR_11): New macros.
710
3afd5369 7112015-02-16 Marek Polacek <polacek@redhat.com>
712
713 PR c/65066
714 * c-format.c (check_format_types): Handle null param.
715
46173d1b 7162015-02-13 Marek Polacek <polacek@redhat.com>
717
718 PR c/65040
719 * c-format.c (check_format_types): Don't warn about different
720 signedness if the original value is in the range of WANTED_TYPE.
721
1d524ff7 7222015-02-12 Jason Merrill <jason@redhat.com>
723
724 PR c++/64956
725 * c-opts.c (c_common_post_options): Change flag_abi_version from 0
726 to the current highest version.
727 * c-cppbuiltin.c (c_cpp_builtins): Assert that it isn't 0.
728
bbf8fbec 7292015-02-04 Jakub Jelinek <jakub@redhat.com>
730
731 PR c/64824
732 PR c/64868
733 * c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
734 instead of RDIV_EXPR. Use build_binary_op instead of
735 build2_loc.
736
c05be867 7372015-01-30 Joseph Myers <joseph@codesourcery.com>
738
739 * c-opts.c, c-pch.c, cppspec.c: All callers of fatal_error changed
740 to pass input_location as first argument.
741
85977647 7422015-01-23 Tom de Vries <tom@codesourcery.com>
743
744 PR libgomp/64672
745 * c.opt (fopenacc): Mark as LTO option.
746
fa175926 7472015-01-23 Tom de Vries <tom@codesourcery.com>
748
749 PR libgomp/64707
750 * c.opt (fopenmp): Mark as LTO option.
751
20aad5ba 7522015-01-21 Jakub Jelinek <jakub@redhat.com>
753
754 PR c/63307
755 * cilk.c (fill_decls_vec): Only put decls into vector v.
756 (compare_decls): Fix up formatting.
757
7582015-01-21 Igor Zamyatin <igor.zamyatin@intel.com>
759
760 PR c/63307
761 * cilk.c: Include vec.h.
762 (struct cilk_decls): New structure.
763 (wrapper_parm_cb): Split this function to...
764 (fill_decls_vec): ...this...
765 (create_parm_list): ...and this.
766 (compare_decls): New function.
767 (for_local_cb): Remove.
768 (wrapper_local_cb): Ditto.
769 (build_wrapper_type): For now first traverse and fill vector of
770 declarations then sort it and then deal with sorted vector.
771 (cilk_outline): Ditto.
772 (declare_one_free_variable): Ditto.
773
60b77e28 7742015-01-21 Jason Merrill <jason@redhat.com>
775
776 PR c++/64629
777 * c-format.c (check_format_arg): Call decl_constant_value.
778
85fbea97 7792015-01-19 Martin Liska <mliska@suse.cz>
780
781 * c-common.c (handle_noicf_attribute): New function.
782
ca4c3545 7832015-01-15 Thomas Schwinge <thomas@codesourcery.com>
784 Bernd Schmidt <bernds@codesourcery.com>
785 James Norris <jnorris@codesourcery.com>
786 Cesar Philippidis <cesar@codesourcery.com>
787 Ilmir Usmanov <i.usmanov@samsung.com>
788 Jakub Jelinek <jakub@redhat.com>
789
790 * c.opt (fopenacc): New option.
791 * c-cppbuiltin.c (c_cpp_builtins): Conditionally define _OPENACC.
792 * c-common.c (DEF_FUNCTION_TYPE_VAR_8, DEF_FUNCTION_TYPE_VAR_12):
793 New macros.
794 * c-common.h (c_finish_oacc_wait): New prototype.
795 * c-omp.c: Include "omp-low.h" and "gomp-constants.h".
796 (c_finish_oacc_wait): New function.
797 * c-pragma.c (oacc_pragmas): New variable.
798 (c_pp_lookup_pragma, init_pragma): Handle it.
799 * c-pragma.h (enum pragma_kind): Add PRAGMA_OACC_CACHE,
800 PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA, PRAGMA_OACC_EXIT_DATA,
801 PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP, PRAGMA_OACC_PARALLEL,
802 PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
803 (enum pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ASYNC,
804 PRAGMA_OACC_CLAUSE_AUTO, PRAGMA_OACC_CLAUSE_COLLAPSE,
805 PRAGMA_OACC_CLAUSE_COPY, PRAGMA_OACC_CLAUSE_COPYIN,
806 PRAGMA_OACC_CLAUSE_COPYOUT, PRAGMA_OACC_CLAUSE_CREATE,
807 PRAGMA_OACC_CLAUSE_DELETE, PRAGMA_OACC_CLAUSE_DEVICE,
808 PRAGMA_OACC_CLAUSE_DEVICEPTR, PRAGMA_OACC_CLAUSE_FIRSTPRIVATE,
809 PRAGMA_OACC_CLAUSE_GANG, PRAGMA_OACC_CLAUSE_HOST,
810 PRAGMA_OACC_CLAUSE_IF, PRAGMA_OACC_CLAUSE_NUM_GANGS,
811 PRAGMA_OACC_CLAUSE_NUM_WORKERS, PRAGMA_OACC_CLAUSE_PRESENT,
812 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPY,
813 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYIN,
814 PRAGMA_OACC_CLAUSE_PRESENT_OR_COPYOUT,
815 PRAGMA_OACC_CLAUSE_PRESENT_OR_CREATE, PRAGMA_OACC_CLAUSE_PRIVATE,
816 PRAGMA_OACC_CLAUSE_REDUCTION, PRAGMA_OACC_CLAUSE_SELF,
817 PRAGMA_OACC_CLAUSE_SEQ, PRAGMA_OACC_CLAUSE_VECTOR,
818 PRAGMA_OACC_CLAUSE_VECTOR_LENGTH, PRAGMA_OACC_CLAUSE_WAIT,
819 PRAGMA_OACC_CLAUSE_WORKER.
820
947aa916 8212015-01-14 Marcos Diaz <marcos.diaz@tallertechnologies.com>
822
823 * c-cppbuiltin.c (c_cpp_builtins): New cpp define __SSP_EXPLICIT__
824 for the new option fstack-protector_explicit.
825 * c-common.c (c_common_attribute_table): Add stack_protect attribute.
826 (handle_stack_protect_attribute): New function.
827
e4fd7af1 8282015-01-13 Martin Uecker <uecker@eecs.berkeley.edu>
829
830 * c.opt: New option -Warray-bounds=.
831
1f78217c 8322015-01-09 Michael Collison <michael.collison@linaro.org>
833
834 * array-notation-common.c: Include hash-set.h, machmode.h,
835 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
836 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
837 * c-ada-spec.c: Ditto.
838 * c-cilkplus.c: Ditto.
839 * c-common.c: Include input.h due to flattening of tree.h.
840 Define macro GCC_C_COMMON_C.
841 * c-common.h: Flatten tree.h header files into c-common.h.
842 Remove include of tree-core.h.
843 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
844 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
845 fold-const.h, wide-int.h, and inchash.h due to
846 flattening of tree.h.
847 * c-dump.c: Ditto.
848 * c-format.c: Flatten tree.h header files into c-common.h.
849 * c-cppbuiltin.c: Include hash-set.h, machmode.h,
850 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
851 fold-const.h, wide-int.h, and inchash.h due to
852 flattening of tree.h.
853 * c-dump.c: Include hash-set.h, machmode.h,
854 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
855 fold-const.h, wide-int.h, and inchash.h due to
856 flattening of tree.h.
857 * c-format.c: Include hash-set.h, machmode.h,
858 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
859 fold-const.h, wide-int.h, inchash.h and real.h due to
860 flattening of tree.h.
861 * c-gimplify.c: Include hash-set.h, machmode.h,
862 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
863 fold-const.h, wide-int.h, and inchash.h due to
864 flattening of tree.h.
865 * cilk.c: Ditto.
866 * c-lex.c: Ditto.
867 * c-omp.c: Ditto.
868 * c-opts.c: Ditto.
869 * c-pch.c: Ditto.
870 * c-ppoutput.c: Ditto.
871 * c-pragma.c: Ditto.
872 * c-pretty-print.c: Ditto.
873 * c-semantics.c: Ditto.
874 * c-ubsan.c: Ditto.
875 * stub-objc.c: Ditto.
876
411b7663 8772015-01-08 Jason Merrill <jason@redhat.com>
878
879 * c-ubsan.c (ubsan_maybe_instrument_array_ref): Use
880 do_ubsan_in_current_function.
881 (ubsan_maybe_instrument_reference_or_call): Likewise.
882 * c-ubsan.h: Declare it.
883
d1e96383 8842015-01-08 Mike Stump <mikestump@comcast.net>
885
886 * c-common.c (c_common_attribute_table): Add no_sanitize_thread.
887
b57910fa 8882015-01-07 Marek Polacek <polacek@redhat.com>
889
890 PR c/64440
891 * c-common.c (c_fully_fold_internal): Warn for division and modulo
892 if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST and is zero.
893
678a4e3e 8942015-01-05 Trevor Saunders <tsaunders@mozilla.com>
895
896 PR c++/31397
897 * c.opt (Wsuggest-override): New option.
898
d353bf18 8992015-01-05 Jakub Jelinek <jakub@redhat.com>
900
901 Update copyright years.
902
92b63884 9032015-01-05 Marek Polacek <polacek@redhat.com>
904
905 PR c/64423
906 * c-common.c (warn_array_subscript_with_type_char): Add location_t
907 parameter. Use it.
908 * c-common.h (warn_array_subscript_with_type_char): Update
909 declaration.
910
83715bc4 9112014-12-20 Edward Smith-Rowland <3dw4rd@verizon.net>
912
913 * c-cppbuiltin.c (__cpp_sized_deallocation): Uncomment and move macro.
914 Control macro with flag_sized_deallocation.
915
8a8211df 9162014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
917
918 * c.opt (Wdiscarded-array-qualifiers): New option.
919
33058239 9202014-12-19 Jakub Jelinek <jakub@redhat.com>
921
922 PR preprocessor/63831
923 * c-cppbuiltin.c (c_cpp_builtins): Don't define __has_attribute
924 and __has_cpp_attribute here.
925 * c-ppoutput.c (init_pp_output): Set cb->has_attribute to
926 c_common_has_attribute.
927 * c-common.h (c_common_has_attribute): New prototype.
928 * c-lex.c (init_c_lex): Set cb->has_attribute to
929 c_common_has_attribute instead of cb_has_attribute.
930 (get_token_no_padding): New function.
931 (cb_has_attribute): Renamed to ...
932 (c_common_has_attribute): ... this. No longer static. Use
933 get_token_no_padding, require ()s, don't build TREE_LIST
934 unnecessarily, fix up formatting, adjust diagnostics, call
935 init_attributes.
936
d1856d2c 9372014-12-15 Jason Merrill <jason@redhat.com>
938
939 * c.opt (-fsized-deallocation, -Wc++14-compat): New.
940 (-Wsized-deallocation): New.
941 * c-opts.c (c_common_post_options): -fsized-deallocation defaults
942 to on in C++14 and up.
943
4972ed5d 9442014-12-11 Jason Merrill <jason@redhat.com>
945
7d7fa964 946 * c-cppbuiltin.c (c_cpp_builtins): Enable C++14 __cpp_constexpr.
947
4972ed5d 948 * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_runtime_arrays if
949 we aren't complaining about VLAs.
950
5ebccf71 9512014-12-06 Marek Polacek <polacek@redhat.com>
952
953 PR tree-optimization/64183
954 * c-gimplify.c (c_gimplify_expr): Don't convert the RHS of a
955 shift-expression if it is integer_type_node. Use types_compatible_p.
956
f9e245b2 9572014-11-29 Jakub Jelinek <jakub@redhat.com>
958
959 * c-common.c (convert_vector_to_pointer_for_subscript): Remove NULL
960 last argument from create_tmp_var_raw and create_tmp_var calls.
961 * cilk.c (gimplify_cilk_spawn): Likewise.
962 * c-omp.c (c_finish_omp_atomic): Likewise.
963
d2f60593 9642014-11-28 Marek Polacek <polacek@redhat.com>
965
966 * c-ubsan.c (ubsan_instrument_shift): Use op1_utype for MINUS_EXPR
967 instead of unsigned_type_node.
968
fce2dbd1 9692014-11-28 Marek Polacek <polacek@redhat.com>
970
971 PR c/63862
972 * c-ubsan.c (ubsan_instrument_shift): Change the type of a MINUS_EXPR
973 to op1_utype.
974 * c-gimplify.c (c_gimplify_expr): Convert right operand of a shift
975 expression to unsigned_type_node.
976
3a4a2292 9772014-11-20 Mark Wielaard <mjw@redhat.com>
978
979 PR debug/38757
980 * c-opts.c (set_std_c89): Set lang_hooks.name.
981 (set_std_c99): Likewise.
982 (set_std_c11): Likewise.
983 (set_std_cxx98): Likewise.
984 (set_std_cxx11): Likewise.
985 (set_std_cxx14): Likewise.
986 (set_std_cxx1z): Likewise.
987
c61ef207 9882014-11-21 Jakub Jelinek <jakub@redhat.com>
989
990 PR target/63764
991 * c-common.h (convert_vector_to_pointer_for_subscript): Change
992 return type to bool.
c9ed79de 993 * c-common.c: Include gimple-expr.h.
c61ef207 994 (convert_vector_to_pointer_for_subscript): Change return type to
995 bool. If *vecp is not lvalue_p and has VECTOR_TYPE, return true
996 and copy it into a TARGET_EXPR and use that instead of *vecp
997 directly.
998
1a91d914 9992014-11-19 David Malcolm <dmalcolm@redhat.com>
1000
1001 Merger of git branch "gimple-classes-v2-option-3".
1002 * ChangeLog.gimple-classes: New.
1003 * c-gimplify.c (add_block_to_enclosing): Strengthen local "stack"
1004 from being just a vec<gimple> to a vec<gbind *>.
1005
f8fc8b8e 10062014-11-18 Jakub Jelinek <jakub@redhat.com>
1007
1008 PR sanitizer/63813
1009 * c-ubsan.c (ubsan_maybe_instrument_reference_or_call): Change type
1010 argument to ptype, set type to TREE_TYPE (ptype). Don't call
1011 get_pointer_alignment for non-pointers. Use ptype, or if it is
1012 reference type, corresponding pointer type, as type of kind
1013 argument.
1014 (ubsan_maybe_instrument_reference,
1015 ubsan_maybe_instrument_member_call): Adjust callers.
1016
8315e35e 10172014-11-15 Marek Polacek <polacek@redhat.com>
1018
1019 PR middle-end/63884
1020 * array-notation-common.c (is_sec_implicit_index_fn): Return false
1021 for NULL fndecl.
1022 (extract_array_notation_exprs): Return for NULL node.
1023
86b9f14b 10242014-11-12 Joseph Myers <joseph@codesourcery.com>
1025
1026 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Define and
1027 undefine __NO_MATH_ERRNO__ based on changes to -fmath-errno state.
1028
0c93c8a9 10292014-11-12 Jakub Jelinek <jakub@redhat.com>
1030
1031 PR c/59708
1032 * c-common.c (check_builtin_function_arguments): Handle
1033 BUILT_IN_{ADD,SUB,MUL}_OVERFLOW.
1034
fdd735a7 10352014-11-10 Andi Kleen <ak@linux.intel.com>
1036
1037 PR c/60804
1038 * c-common.h (check_no_cilk): Declare.
1039 * cilk.c (get_error_location): New function.
1040 (check_no_cilk): Dito.
1041
5cb678b4 10422014-11-10 Andi Kleen <ak@linux.intel.com>
1043
1044 * cilk.c (recognize_spawn): Use expression location
1045 for error message.
1046
0feb4de1 10472014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
1048
1049 * c.opt ([Wshift-count-negative, Wshift-count-overflow]): Add.
1050
3aa2fa44 10512014-11-10 Edward Smith-Rowland <3dw4rd@verizon.net>
1052
1053 * c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
1054 (__cpp_rtti, __cpp_exceptions): New macros for C++98;
1055 (__cpp_range_based_for, __cpp_initializer_lists,
1056 __cpp_delegating_constructors, __cpp_nsdmi,
1057 __cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
1058 for C++11; (__cpp_attribute_deprecated): Remove in favor of
1059 __has_cpp_attribute.
1060 * c-lex.c (cb_has_attribute): New callback CPP function;
1061 (init_c_lex): Set has_attribute callback.
1062
7fd22aae 10632014-11-04 Richard Biener <rguenther@suse.de>
1064
1065 * c-common.c (shorten_compare): Do not shorten mixed
1066 DFP and non-DFP compares.
1067
4af203ac 10682014-11-01 Edward Smith-Rowland <3dw4rd@verizon.net>
1069
1070 * g++.dg/cpp1y/feat-cxx11.C: Commentary and rearrangement of tests.
1071 * g++.dg/cpp1y/feat-cxx11-neg.C: Add aggregate NSDMI test.
1072 Commentary and rearrangement of tests.
1073 * g++.dg/cpp1y/feat-cxx14.C: Enable aggregate NSDMI test.
1074 Commentary and rearrangement of tests.
1075 * g++.dg/cpp1y/feat-cxx98-neg.C: Ditto
1076 * g++.dg/cpp1y/feat-cxx98.C: Commentary.
1077
3754d046 10782014-10-29 Richard Sandiford <richard.sandiford@arm.com>
1079
1080 * c-common.c, c-common.h, c-cppbuiltin.c, c-lex.c: Remove redundant
1081 enum from machine_mode.
1082
1140c305 10832014-10-28 Andrew MacLeod <amacleod@redhat.com>
1084
1f78217c 1085 * c-common.c: Adjust include files.
1086 * c-gimplify.c: Ditto.
1087 * cilk.c: Ditto.
1088 * c-pragma.c: Ditto.
1089 * c-ubsan.c: Ditto.
1140c305 1090
94ea8568 10912014-10-27 Andrew MacLeod <amacleod@redhat.com>
1092
1093 * c-gimplify.c: Adjust include files.
1094
32ecf960 10952014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
1096
1097 PR c++/53061
1098 * c-opts.c (c_common_diagnostics_set_defaults): Renamed from
1099 c_common_initialize_diagnostics.
1100 * c-common.h: Likewise.
1101
85fecbe2 11022014-10-24 Marek Polacek <polacek@redhat.com>
1103
1104 PR c/56980
1105 * c-pretty-print.c (c_pretty_printer::simple_type_specifier): Don't
1106 print "struct"/"union"/"enum" for typedefed names.
1107
e7ec033a 11082014-10-23 Marek Polacek <polacek@redhat.com>
1109
1110 * c-ubsan.c (ubsan_instrument_shift): Perform the MINUS_EXPR
1111 in unsigned type.
1112
c2598081 11132014-10-22 Jakub Jelinek <jakub@redhat.com>
1114 Yury Gribov <y.gribov@samsung.com>
1115
1116 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
1117 ubsan_instrument_vla): Check bits in flag_sanitize_recover bitmask
1118 instead of flag_sanitize_recover as bool flag.
1119
acebb7e2 11202014-10-21 Kirill Yukhin <kirill.yukhin@intel.com>
1121
1122 * cilk.c: Revert previous change.
1123
6115016c 11242014-10-20 Igor Zamyatin <igor.zamyatin@intel.com>
1125
1126 PR c/63307
1127 * cilk.c: Include vec.h.
1128 (struct cilk_decls): New structure.
1129 (wrapper_parm_cb): Split this function to...
1130 (fill_decls_vec): ...this...
1131 (create_parm_list): ...and this.
1132 (compare_decls): New function.
1133 (for_local_cb): Remove.
1134 (wrapper_local_cb): Ditto.
1135 (build_wrapper_type): For now first traverse and fill vector of
1136 declarations then sort it and then deal with sorted vector.
1137 (cilk_outline): Ditto.
1138 (declare_one_free_variable): Ditto.
1139
e610d2b2 11402014-10-17 Marek Polacek <polacek@redhat.com>
1141
1142 * c-opts.c (c_common_post_options): Set warn_implicit_int.
1143 * c.opt (Wimplicit-int): Initialize to -1.
1144
a3020f2f 11452014-10-16 Andrew MacLeod <amacleod@redhat.com>
1146
1147 * c-pragma.c: Adjust include files.
1148 * c-semantics.c: Likewise.
1149
926ddd2c 11502014-10-16 DJ Delorie <dj@redhat.com>
1151
1152 * c-cppbuiltin.c (cpp_atomic_builtins): Don't assume pointers are
1153 multiples of bytes.
1154
b0542e7c 11552014-10-14 Jason Merrill <jason@redhat.com>
1156
1157 PR c++/63455
1158 * c-common.h (CPP_PREPARSED_EXPR): New.
1159 (N_CP_TTYPES): Adjust.
1160
b2601928 11612014-10-15 Marek Polacek <polacek@redhat.com>
1162
1163 * c-opts.c (c_common_init_options): Make -std=gnu11 the default for C.
1164
9f75f026 11652014-10-14 DJ Delorie <dj@redhat.com>
1166
1167 * c-pretty-print.c (pp_c_integer_constant): Check for all __intN
1168 types, not just __int128.
1169 * c-cppbuiltin.c (c_cpp_builtins): Add builtins for all __intN
1170 types, not just __int128.
1171 (cpp_atomic_builtins): Round pointer sizes up.
1172 (type_suffix): Use type precision, not specific types.
1173 * c-common.c (c_common_reswords): Remove __int128 special case.
1174 (c_common_type_for_size): Check for all __intN types, not just
1175 __int128.
1176 (c_common_type_for_mode): Likewise.
1177 (c_common_signed_or_unsigned_type): Likewise.
1178 (c_build_bitfield_integer_type): Likewise.
1179 (c_common_nodes_and_builtins): Likewise.
1180 (keyword_begins_type_specifier): Likewise.
1181 * c-common.h (rid): Remove RID_INT128 and add RID_INT_N_* for all
1182 __intN variants.
1183
2ef51f0e 11842014-10-12 Trevor Saunders <tsaunders@mozilla.com>
1185
1186 * c-common.c: Use hash_table instead of hashtab.
1187
5b8257e3 11882014-10-06 Edward Smith-Rowland <3dw4rd@verizon.net>
1189
1f78217c 1190 * c-cppbuiltin.c: Move __cpp_attribute_deprecated to the
5b8257e3 1191 C++11 section.
1192
5e84569c 11932014-10-03 Marc Glisse <marc.glisse@inria.fr>
1194
1195 PR c++/54427
1196 PR c++/57198
1197 PR c++/58845
1198 * c-common.c (warn_logical_operator): Punt for vectors.
1199
f6751ff2 12002014-10-01 Edward Smith-Rowland <3dw4rd@verizon.net>
1201
1202 Implement SD-6: SG10 Feature Test Recommendations
1203 * c-cppbuiltin.c (c_cpp_builtins()): Define language feature
1204 macros and the __has_header macro.
1205
c33e051d 12062014-09-30 Jason Merrill <jason@redhat.com>
1207
f76a9aa8 1208 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_ASSIGNABLE and
1209 RID_IS_TRIVIALLY_CONSTRUCTIBLE.
1210 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
1211
717e52f9 1212 * c-common.h (enum rid): Add RID_IS_TRIVIALLY_COPYABLE.
1213 * c-common.c (c_common_reswords): Add __is_trivially_copyable.
1214
c33e051d 1215 * c-common.h (enum rid): Remove RID_IS_CONVERTIBLE_TO.
1216 * c-common.c (c_common_reswords): Remove __is_convertible_to.
1217
5213d6c9 12182014-09-24 Marek Polacek <polacek@redhat.com>
1219
1220 PR c/61405
1221 PR c/53874
1222 * c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
1223
6b722052 12242014-09-23 Andi Kleen <ak@linux.intel.com>
1225
1226 * c-common.c (handle_no_reorder_attribute): New function.
1227 (c_common_attribute_table): Add no_reorder attribute.
1228
0cb69d12 12292014-09-22 Joseph Myers <joseph@codesourcery.com>
1230
1231 * c-cppbuiltin.c (c_cpp_builtins): Define
1232 __LIBGCC_*_EXCESS_PRECISION__ macros for supported floating-point
1233 modes.
1234
168dfbf0 12352014-09-18 Joseph Myers <joseph@codesourcery.com>
1236
1237 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_*_FUNC_EXT__
1238 for supported floating-point modes.
1239
b83705f4 12402014-09-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
1241
1242 * c.opt (Wpsabi): Use LangEnabledBy.
1243 * c-opts.c (c_common_handle_option): Do not handle here.
1244
d5957f0d 12452014-09-12 Joseph Myers <joseph@codesourcery.com>
1246
1247 * c-cppbuiltin.c (c_cpp_builtins): Define __LIBGCC_HAS_%s_MODE__
1248 macros for floating-point modes.
1249
bae6edff 12502014-09-11 Marc Glisse <marc.glisse@inria.fr>
1251
1252 PR target/58757
1253 * c-cppbuiltin.c (builtin_define_float_constants): Correct
1254 __*_DENORM_MIN__ without denormals.
1255
73a69d02 12562014-09-10 Jakub Jelinek <jakub@redhat.com>
1257
1258 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
1259 ubsan_instrument_vla, ubsan_instrument_return): Adjust
1260 ubsan_create_data callers.
1261 (ubsan_instrument_bounds): Don't emit UBSAN_BOUNDS at all if
1262 index is constant or BIT_AND_EXPR with constant mask and is
1263 small enough for the bound.
1264 * c-gimplify.c (ubsan_walk_array_refs_r): For ADDR_EXPR of
1265 ARRAY_REF, make sure the inner ARRAY_REF is not walked again.
1266
7ff8db31 12672014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
1268
1269 * c.opt: Add CppReason to various flags.
1270 (Wdate-time): Re-sort.
1271 * c-common.c: Include c-common.h earlier.
1272 (struct reason_option_codes_t): Delete.
1273 (c_option_controlling_cpp_error): Prefix global type and struct
1274 with cpp_.
1275
bcc1f37e 12762014-09-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
1277
1278 * c.opt (Wnormalized): New.
1279 (Wnormalized=): Use Enum and Reject Negative.
1280 * c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
1281
b660d3c6 12822014-09-08 Joseph Myers <joseph@codesourcery.com>
1283
1284 * c-cppbuiltin.c (c_cpp_builtins): Define macros for mantissa
1285 digits of floating-point modes if -fbuilding-libgcc.
1286
325b8c3c 12872014-09-05 Joseph Myers <joseph@codesourcery.com>
1288
1289 * c-cppbuiltin.c (c_cpp_builtins): Also define
1290 __LIBGCC_EH_TABLES_CAN_BE_READ_ONLY__,
1291 __LIBGCC_EH_FRAME_SECTION_NAME__, __LIBGCC_JCR_SECTION_NAME__,
1292 __LIBGCC_CTORS_SECTION_ASM_OP__, __LIBGCC_DTORS_SECTION_ASM_OP__,
1293 __LIBGCC_TEXT_SECTION_ASM_OP__, __LIBGCC_INIT_SECTION_ASM_OP__,
1294 __LIBGCC_INIT_ARRAY_SECTION_ASM_OP__,
1295 __LIBGCC_STACK_GROWS_DOWNWARD__,
1296 __LIBGCC_DONT_USE_BUILTIN_SETJMP__,
1297 __LIBGCC_DWARF_ALT_FRAME_RETURN_COLUMN__,
1298 __LIBGCC_DWARF_FRAME_REGISTERS__,
1299 __LIBGCC_EH_RETURN_STACKADJ_RTX__, __LIBGCC_JMP_BUF_SIZE__,
1300 __LIBGCC_STACK_POINTER_REGNUM__ and
1301 __LIBGCC_VTABLE_USES_DESCRIPTORS__ for -fbuilding-libgcc.
1302 (builtin_define_with_value): Handle backslash-escaping in string
1303 macro values.
1304
1e074e77 13052014-09-05 Richard Biener <rguenther@suse.de>
1306
1307 PR middle-end/63148
1308 * c-format.c (check_format_arg): Properly handle
1309 effectively signed POINTER_PLUS_EXPR offset.
1310
04afd878 13112014-09-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
1312
1313 * c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
1314 Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
1315 (Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
1316 and Init.
1317 * c-opts.c (c_common_handle_option): Do not handle here.
1318 (sanitize_cpp_opts): Likewise.
1319 * c-common.c (struct reason_option_codes_t): Handle
1320 CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
1321
a3f448f0 13222014-09-03 Marek Polacek <polacek@redhat.com>
1323
1324 * c.opt (Wlogical-not-parentheses): Enable by -Wall.
1325
40750995 13262014-09-02 Jakub Jelinek <jakub@redhat.com>
1327 Balaji V. Iyer <balaji.v.iyer@intel.com>
1328 Igor Zamyatin <igor.zamyatin@intel.com>
1329
1330 * c-cilkplus.c (cilk_for_number_of_iterations): New function.
1331 * c-common.c (c_common_reswords): Added _Cilk_for.
1332 * c-common.h (enum rid): Added RID_CILK_FOR.
1333 (cilk_for_number_of_iterations): Add declaration.
1334 * c-omp.c (c_finish_omp_for): Added checks for CILK_SIMD and
1335 CILK_FOR.
1336 * c-pragma.c (init_pragma): Register "grainsize" pragma.
1337 * c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_GRAINSIZE.
1338
f0fbe519 13392014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
1340
1341 * c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
1342 Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
1343 Wundef): Use CPP, Var and Init.
1344 * c-opts.c (c_common_handle_option): Do not handle the above flags here.
1345
a7d2e480 13462014-08-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
1347
1348 * c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
1349 * c-opts.c (c_common_handle_option): Do not handle here.
1350
c35e53f1 13512014-08-25 Jason Merrill <jason@redhat.com>
1352
1353 * c.opt: Change -std=c++1y and -std=gnu++1y to be aliases for
1354 -std=c++14 and -std=gnu++14, rather than the reverse.
1355 * c-opts.c (c_common_handle_option): Change OPT_std_c__1y and
1356 OPT_std_gnu__1y to OPT_std_c__14 and OPT_std_gnu__14.
1357 * c-common.h (cxx_dialect): Remove cxx1y.
1358
4e454776 13592014-08-23 Edward Smith-Rowland <3dw4rd@verizon.net>
1360
1361 * c-common.h (enum cxx_dialect): Add cxx14.
1362 * c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
1363 * c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
1364 cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
1365
af1a80f2 13662014-08-22 Jason Merrill <jason@redhat.com>
1367
1368 * c.opt (std=gnu++17): Fix alias.
1369
dc6229e8 13702014-08-22 Marek Polacek <polacek@redhat.com>
1371
1372 PR c++/62199
1373 * c-common.c (warn_logical_not_parentheses): Don't check LHS. Don't
1374 check for vector types. Drop LHS argument.
1375 * c-common.h (warn_logical_not_parentheses): Adjust.
1376
ba7f7c88 13772014-08-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
1378
1379 * c.opt (Wcomment): Use CPP, Var and LangEnabledBy.
1380 (Wmultichar): Likewise.
1381 (Wdate-time): Use C-family languages instead of Common. Use CPP
1382 and Var.
1383 * c-opts.c (c_common_handle_option): Do not handle the above
1384 options here.
1385 (sanitize_cpp_opts): Likewise.
1386
399d4f80 13872014-08-21 Manuel López-Ibáñez <manu@gcc.gnu.org>
1388
1389 PR fortran/44054
1390 * c-opts.c: Include tree-diagnostics.h.
1391 (c_diagnostic_finalizer): New.
1392 (c_common_initialize_diagnostics): Use it.
1393
1babed5f 13942014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
1395
1396 PR preprocessor/51303
1397 * c-common.c (struct reason_option_codes_t option_codes):
1398 Add CPP_W_MISSING_INCLUDE_DIRS. Sort alphabetically.
1399
3636964b 14002014-08-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
1401
1402 PR c/60975
1403 PR c/53063
1404 * c.opt (Wvariadic-macros): Use CPP and LangEnabledBy.
1405 * c-opts.c (c_common_handle_option): Call cpp_handle_option_auto.
1406 (c_common_post_options): Call init_global_opts_from_cpp.
1407 (sanitize_cpp_opts): Do not handle Wvariadic-macros here.
1408
78bf4156 14092014-08-19 Marek Polacek <polacek@redhat.com>
1410
1411 PR c++/62153
1412 * c-common.c (maybe_warn_bool_compare): New function.
1413 * c-common.h (maybe_warn_bool_compare): Declare.
1414 * c.opt (Wbool-compare): New option.
1415
508ea33a 14162014-08-19 Marek Polacek <polacek@redhat.com>
1417
1418 * c.opt (Wc99-c11-compat): New option.
1419
806fe15e 14202014-08-19 Marek Polacek <polacek@redhat.com>
1421
1422 * c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
1423 to warn_c90_c99_compat.
1424 * c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
1425 to -1.
1426
6c867de1 14272014-08-19 Manuel López-Ibáñez <manu@gcc.gnu.org>
1428 Steven Bosscher <steven@gcc.gnu.org>
1429
1430 PR c/52952
1431 * c-format.c: Add extra_arg_loc and format_string_loc to struct
1432 format_check_results.
1433 (check_function_format): Use true and add comment for boolean
1434 argument.
1435 (finish_dollar_format_checking): Use explicit location when warning.
1436 (check_format_info): Likewise.
1437 (check_format_arg): Set extra_arg_loc and format_string_loc.
1438 (check_format_info_main): Use explicit location when warning.
1439 (check_format_types): Pass explicit location.
1440 (format_type_warning): Likewise.
1441
dc8078a3 14422014-08-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
1443
1444 PR fortran/44054
1445 * c-format.c: Handle Fortran flags.
1446
d271ec7e 14472014-08-12 Igor Zamyatin <igor.zamyatin@intel.com>
1448
1449 PR other/61962
1450 * array-notation-common.c (find_rank): Added handling for other
1451 types of references.
1452
890c2e2f 14532014-08-10 Marek Polacek <polacek@redhat.com>
1454
1455 PR c/51849
1456 * c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
1457 * c.opt (Wc90-c99-compat): Add option.
1458
7149db5f 14592014-08-07 Trevor Saunders <tsaunders@mozilla.com>
1460
1461 * c-gimplify.c, cilk.c: Remove includes of pointer-set.h.
1462
2d2f6a15 14632014-08-03 Marek Polacek <polacek@redhat.com>
1464
1465 * c-common.c (check_case_value): Add location_t parameter. Use it.
1466 (c_add_case_label): Pass loc to check_case_value.
1467
06ecf488 14682014-08-02 Trevor Saunders <tsaunders@mozilla.com>
1469
1470 * cilk.c: Use hash_map instead of pointer_map.
1471
431205b7 14722014-08-02 Trevor Saunders <tsaunders@mozilla.com>
1473
1474 * c-gimplify.c: Use hash_set instead of pointer_set.
1475
3394c80c 14762014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
1477
1478 PR middle-end/61455
1479 * array-notation-common.c (extract_array_notation_exprs): Handling
1480 of DECL_EXPR added.
1481
392dee1e 14822014-08-01 Jakub Jelinek <jakub@redhat.com>
1483
1484 * c-common.h (min_align_of_type): Removed prototype.
1485 * c-common.c (min_align_of_type): Removed.
1486 * c-ubsan.h (ubsan_maybe_instrument_reference,
1487 ubsan_maybe_instrument_member_call): New prototypes.
1488 * c-ubsan.c: Include stor-layout.h and builtins.h.
1489 (ubsan_maybe_instrument_reference_or_call,
1490 ubsan_maybe_instrument_reference, ubsan_maybe_instrument_call): New
1491 functions.
1492
f22a2cb7 14932014-07-31 Marc Glisse <marc.glisse@inria.fr>
1494
1495 PR c++/60517
1496 * c.opt (-Wreturn-local-addr): Move to common.opt.
1497
87b0198f 14982014-07-30 Jason Merrill <jason@redhat.com>
1499
1500 PR c++/61659
1501 PR c++/61687
1502 Revert:
1503 * c.opt (-fuse-all-virtuals): New.
1504
74691f46 15052014-07-30 Tom Tromey <tromey@redhat.com>
1506
1507 PR c/59855
1508 * c.opt (Wdesignated-init): New option.
1509 * c-common.c (c_common_attribute_table): Add "designated_init".
1510 (handle_designated_init): New function.
1511
9140d56f 15122014-07-24 Marek Polacek <polacek@redhat.com>
1513
1514 PR c/57653
1515 * c-opts.c (c_finish_options): If -imacros is in effect, return.
1516
a09c5cc2 15172014-07-16 Dodji Seketeli <dodji@redhat.com>
1518
1519 PR preprocessor/60723 - missing system-ness marks for macro tokens
1520 * c-ppoutput.c (struct print::prev_was_system_token): New data
1521 member.
1522 (init_pp_output): Initialize it.
1523 (maybe_print_line_1, maybe_print_line, print_line_1, print_line)
1524 (do_line_change): Return a flag saying if a line marker was
1525 emitted or not.
1526 (scan_translation_unit): Detect if the system-ness of the token we
1527 are about to emit is different from the one of the previously
1528 emitted token. If so, emit a line marker. Avoid emitting useless
1529 adjacent line markers. Avoid emitting line markers for tokens
1530 originating from the expansion of built-in macros.
1531 (scan_translation_unit_directives_only): Adjust.
1532
2b25b62f 15332014-07-15 Marek Polacek <polacek@redhat.com>
1534
1535 * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
1536 TYPE_MAX_VALUE is NULL.
1537
305d96bc 15382014-07-14 Jakub Jelinek <jakub@redhat.com>
1539
1540 PR middle-end/61294
1541 * c.opt (Wmemset-transposed-args): New warning.
1542
8ea4660d 15432014-07-10 Jason Merrill <jason@redhat.com>
1544
1545 PR c++/61659
1546 PR c++/61687
1547 * c.opt (-fuse-all-virtuals): New.
1548
cd480f3d 15492014-07-09 Richard Biener <rguenther@suse.de>
1550
1551 PR c-family/61741
1552 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
1553 using unsigned arithmetic if overflow does not wrap instead of
1554 if overflow is undefined.
1555
87d59e72 15562014-07-06 Marek Polacek <polacek@redhat.com>
1557
1558 PR c/6940
1559 * c.opt (Wsizeof-array-argument): New option.
1560
d69521d8 15612014-07-03 Jakub Jelinek <jakub@redhat.com>
1562
1563 * c-ada-spec.c (dump_ada_nodes): Don't call qsort if
1564 comments->count <= 1, as comments->entries might be NULL.
1565
1207866e 15662014-07-01 Marek Polacek <polacek@redhat.com>
1567
1568 * c.opt (Wint-conversion): New option.
1569
7a6bbb76 15702014-07-01 Marek Polacek <polacek@redhat.com>
1571
1572 PR c/58286
1573 * c.opt (Wincompatible-pointer-types): New option.
1574
9d4eeb52 15752014-06-30 Paolo Carlini <paolo.carlini@oracle.com>
1576
1577 PR c++/51400
1578 * c-common.c (handle_noreturn_attribute, handle_const_attribute):
1579 Do not discard TYPE_QUALS of type.
1580
4b53bc0f 15812014-06-26 Jason Merrill <jason@redhat.com>
1582
1583 * c-common.h (enum cxx_dialect): Add cxx1z.
1584 * c.opt (std=c++1z, std=c++17, std=gnu++1z, std=gnu++17): New.
1585 * c-opts.c (c_common_handle_option, set_std_cxx1z): Handle it.
1586
a8a8d4ea 15872014-06-26 Teresa Johnson <tejohnson@google.com>
1588
1589 * c-common.h (get_dump_info): Declare.
1590 * c-gimplify.c (c_genericize): Use saved dump files.
1591 * c-opts.c (c_common_parse_file): Begin and end dumps
1592 once around parsing invocation.
1593 (get_dump_info): New function.
1594
1f6be080 15952014-06-23 Marek Polacek <polacek@redhat.com>
1596 Andrew MacLeod <amacleod@redhat.com>
1597
1598 PR c/61553
1599 * c-common.c (get_atomic_generic_size): Don't segfault if the
1600 type doesn't have a size.
1601
5ef6b660 16022014-06-20 Marek Polacek <polacek@redhat.com>
1603
1604 * c-gimplify.c: Include "c-ubsan.h" and "pointer-set.h".
1605 (ubsan_walk_array_refs_r): New function.
1606 (c_genericize): Instrument array bounds.
1607 * c-ubsan.c: Include "internal-fn.h".
1608 (ubsan_instrument_division): Mark instrumented arrays as having
1609 side effects. Adjust ubsan_type_descriptor call.
1610 (ubsan_instrument_shift): Likewise.
1611 (ubsan_instrument_vla): Adjust ubsan_type_descriptor call.
1612 (ubsan_instrument_bounds): New function.
1613 (ubsan_array_ref_instrumented_p): New function.
1614 (ubsan_maybe_instrument_array_ref): New function.
1615 * c-ubsan.h (ubsan_instrument_bounds): Declare.
1616 (ubsan_array_ref_instrumented_p): Declare.
1617 (ubsan_maybe_instrument_array_ref): Declare.
1618
16192014-06-20 Hale Wang <hale.wang@arm.com>
3ccd1e6e 1620
1621 PR lto/61123
1622 * c.opt (fshort-enums): Add to LTO.
1623 * c.opt (fshort-wchar): Likewise.
1624
78438f31 16252014-06-16 Marek Polacek <polacek@redhat.com>
1626
1627 PR c/60439
1628 * c.opt (Wswitch-bool): Add Var.
1629
5fddcf34 16302014-06-12 Jakub Jelinek <jakub@redhat.com>
1631
1632 PR middle-end/61486
1633 * c-omp.c (c_omp_split_clauses): Don't crash on firstprivate in
1634 #pragma omp target teams or
1635 #pragma omp {,target }teams distribute simd.
1636
74b777e5 16372014-06-12 Jason Merrill <jason@redhat.com>
1638
1639 * c.opt (Wabi=, fabi-compat-version): New.
1640 * c-opts.c (c_common_handle_option): Handle -Wabi=.
1641 (c_common_post_options): Handle flag_abi_compat_version default.
1642 Disallow -fabi-compat-version=1.
1643 * c-common.h (abi_version_crosses): New.
1644
738a6bda 16452014-06-11 Jan Hubicka <hubicka@ucw.cz>
1646
1f78217c 1647 * c-common.c (handle_section_attribute): Update handling for
738a6bda 1648 section names that are no longer trees.
1649
cf5f881f 16502014-06-10 Jakub Jelinek <jakub@redhat.com>
1651
1652 PR fortran/60928
1653 * c-pragma.c (omp_pragmas_simd): Move PRAGMA_OMP_TASK...
1654 (omp_pragmas): ... back here.
1655
32dc1512 16562014-06-05 Marek Polacek <polacek@redhat.com>
1657
1658 PR c/49706
1659 * c-common.c (warn_logical_not_parentheses): New function.
1660 * c-common.h (warn_logical_not_parentheses): Declare.
1661 * c.opt (Wlogical-not-parentheses): New option.
1662
f61a9bc2 16632014-06-04 Marek Polacek <polacek@redhat.com>
1664
1665 PR c/30020
1666 * c-common.c (check_case_bounds): Add location parameter.
1667 Use it.
1668 (c_add_case_label): Pass loc to check_case_bounds.
1669
c69ec07d 16702014-06-03 Marek Polacek <polacek@redhat.com>
1671
1672 PR c/60439
1673 * c.opt (Wswitch-bool): New option.
1674
3c77ca67 16752014-05-22 Thomas Schwinge <thomas@codesourcery.com>
1676
68a2c870 1677 * c-common.h (c_omp_sharing_predetermined, c_omp_remap_decl):
1678 Remove prototypes.
1679 (record_types_used_by_current_var_decl): Move prototype to where
1680 it belongs.
1681
3c77ca67 1682 * c-common.c (DEF_FUNCTION_TYPE_0, DEF_FUNCTION_TYPE_6)
1683 (DEF_FUNCTION_TYPE_7, DEF_FUNCTION_TYPE_8)
1684 (DEF_FUNCTION_TYPE_VAR_5): Cosmetic fixes.
1685
3ab4693e 16862014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
1687
1688 * c-common.h (CTI_VOID_ZERO, void_zero_node): Delete.
1689 * c-common.c (c_common_nodes_and_builtins): Don't initialize
1690 void_zero_node.
1691 * c-pretty-print.c (pp_c_void_constant): New function.
1692 (c_pretty_printer::constant, c_pretty_printer::primary_expression)
1693 (c_pretty_printer::expression): Handle VOID_CST.
1694 * cilk.c (extract_free_variables): Likewise.
1695 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift)
1696 (ubsan_instrument_vla): Use void_node instead of void_zero_node.
1697
25a27413 16982014-05-17 Trevor Saunders <tsaunders@mozilla.com>
1699
1700 * c-common.h (sorted_fields_type): Remove variable_size GTY attribute.
1701 * c-pragma.c (push_alignment): Adjust.
1702 (handle_pragma_push_options): Likewise.
1703
3e5a8b00 17042014-05-09 Marek Polacek <polacek@redhat.com>
1705
1706 PR c/50459
1707 * c-common.c (check_user_alignment): Return -1 if alignment is error
1708 node.
1709 (handle_aligned_attribute): Don't call default_conversion on
1710 FUNCTION_DECLs.
1711 (handle_vector_size_attribute): Likewise.
1712 (handle_tm_wrap_attribute): Handle case when wrap_decl is error node.
1713 (handle_sentinel_attribute): Call default_conversion and allow even
1714 integral types as an argument.
1715
c2c4ae8d 17162014-05-08 Marek Polacek <polacek@redhat.com>
1717
1718 PR c/61053
1719 * c-common.c (min_align_of_type): New function factored out from...
1720 (c_sizeof_or_alignof_type): ...here.
1721 * c-common.h (min_align_of_type): Declare.
1722
2026249a 17232014-05-08 Marek Polacek <polacek@redhat.com>
1724
1725 PR c/61077
1726 * c-common.c (check_main_parameter_types): Warn for _Atomic-qualified
1727 parameter type of main.
1728
33c8dcfe 17292014-05-07 DJ Delorie <dj@redhat.com>
1730
1731 * c-cppbuiltin.c (print_bits_of_hex): New.
1732 (builtin_define_type_minmax): Print values using hex so as not to
1733 require a pre-computed list of string values.
1734
960d5a55 17352014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
1736 Mike Stump <mikestump@comcast.net>
1737 Richard Sandiford <rdsandiford@googlemail.com>
1738
1739 * c-ada-spec.c: Include wide-int.h.
1740 (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Remove.
1741 (dump_generic_ada_node): Use wide-int interfaces.
1742 * c-common.c: Include wide-int-print.h.
1743 (shorten_compare): Use wide-int interfaces and tree_int_cst_lt.
1744 (pointer_int_sum): Use wide-int interfaces.
1745 (c_common_nodes_and_builtins): Use make_int_cst.
1746 (match_case_to_enum_1): Use tree_fits_uhwi_p and tree_fits_shwi_p.
1747 (handle_alloc_size_attribute): Use wide-int interfaces.
1748 (get_nonnull_operand): Likewise.
1749 * c-format.c (get_constant): Use tree_fits_uhwi_p.
1750 * c-lex.c: Include wide-int.h.
1751 (narrowest_unsigned_type): Take a widest_int rather than two
1752 HOST_WIDE_INTs.
1753 (narrowest_signed_type): Likewise.
1754 (interpret_integer): Update accordingly. Use wide-int interfaces.
1755 (lex_charconst): Use wide-int interfaces.
1756 * c-pretty-print.c: Include wide-int.h.
1757 (pp_c_integer_constant): Use wide-int interfaces.
1758 * cilk.c (declare_one_free_variable): Use tree_int_cst_lt instead of
1759 INT_CST_LT_UNSIGNED.
1760
bbb88b31 17612014-05-06 Richard Biener <rguenther@suse.de>
1762
1763 * c-opts.c (c_common_post_options): For -freestanding,
1764 -fno-hosted and -fno-builtin disable pattern recognition
1765 if not enabled explicitely.
1766
022d4718 17672014-05-02 Marek Polacek <polacek@redhat.com>
1768
1769 * c.opt (Wsizeof-pointer-memaccess): Describe option.
1770
e4ab2ef3 17712014-05-01 Marek Polacek <polacek@redhat.com>
1772
1773 PR c/43245
1774 * c.opt (Wdiscarded-qualifiers): Add.
1775
52cc0072 17762014-04-30 Marek Polacek <polacek@redhat.com>
1777
1778 * c-ubsan.c (ubsan_instrument_division): Handle REAL_TYPEs. Perform
1779 INT_MIN / -1 sanitization only for integer types.
1780
4a026b48 17812014-04-25 Marek Polacek <polacek@redhat.com>
1782
1783 PR c/18079
1784 * c-common.c (handle_noinline_attribute): Warn if the attribute
1785 conflicts with always_inline attribute.
1786 (handle_always_inline_attribute): Warn if the attribute conflicts
1787 with noinline attribute.
1788
90e645fa 17892014-04-25 Marek Polacek <polacek@redhat.com>
1790
1791 PR c/60156
1792 * c-common.c (check_main_parameter_types): Warn about variadic main.
1793
db103ea4 17942014-04-24 Mike Stump <mikestump@comcast.net>
1795
1796 * c.opt (Wshadow-ivar): Default to on.
1797
06511efd 17982014-04-24 Dimitris Papavasiliou <dpapavas@gmail.com>
1799
1800 * c.opt (Wshadow-ivar, flocal-ivars, fivar-visibility): Add.
1801
cdf34fca 18022014-04-23 Marek Polacek <polacek@redhat.com>
1803
1804 * c-common.c (handle_tm_wrap_attribute): Tweak error message.
1805
7311d7c1 18062014-04-22 Jakub Jelinek <jakub@redhat.com>
1807
1808 PR sanitizer/60275
1809 * c-ubsan.c (ubsan_instrument_return): Return __builtin_trap ()
1810 if flag_sanitize_undefined_trap_on_error.
1811 (ubsan_instrument_division, ubsan_instrument_shift,
1812 ubsan_instrument_vla): Likewise. Use __ubsan_handle_*_abort ()
1813 if !flag_sanitize_recover.
1814
c1917557 18152014-04-22 Marc Glisse <marc.glisse@inria.fr>
1816
1817 PR libstdc++/43622
1818 * c-common.c (registered_builtin_types): Make non-static.
1819 * c-common.h (registered_builtin_types): Declare.
1820
b2ca6510 18212014-04-14 Richard Biener <rguenther@suse.de>
1822 Marc Glisse <marc.glisse@inria.fr>
1823
1824 PR c/60819
1825 * c-common.c (convert_vector_to_pointer_for_subscript): Properly
1826 apply may-alias the scalar pointer type when applicable.
1827
855372a3 18282014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
1829
1830 PR middle-end/60467
1831 * cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
1832 as possible argument for Cilk_spawn.
1833
4012a986 18342014-04-11 Tobias Burnus <burnus@net-b.de>
1835
1836 PR c/60194
1837 * c.opt (Wformat-signedness): Add
1838 * c-format.c(check_format_types): Use it.
1839
0d284870 18402014-04-11 Jason Merrill <jason@redhat.com>
1841
1842 PR c++/57926
1843 * c-common.c (sync_resolve_size, get_atomic_generic_size): Call
1844 default_conversion for an array argument.
1845
a34c1231 18462014-04-08 Marek Polacek <polacek@redhat.com>
1847
1848 PR sanitizer/60745
1849 * c-ubsan.c: Include asan.h.
1850 (ubsan_instrument_return): Call initialize_sanitizer_builtins.
1851
a35a8e18 18522014-04-03 Nathan Sidwell <nathan@codesourcery.com>
1853
1854 * c.opt (Wnon-virtual-dtor): Auto set when Weffc++.
1855
b23e42b6 18562014-04-02 Marek Polacek <polacek@redhat.com>
1857
1858 * c-common.h (c_expand_expr): Remove declaration.
1859
5a672e62 18602014-03-28 Jakub Jelinek <jakub@redhat.com>
1861
1862 PR c++/60689
1863 * c-common.c (add_atomic_size_parameter): When creating new
1864 params vector, push the size argument first.
1865
d4d068c0 18662014-03-26 Jakub Jelinek <jakub@redhat.com>
1867
1868 * c-ubsan.c (ubsan_instrument_division, ubsan_instrument_shift,
1869 ubsan_instrument_vla, ubsan_instrument_return): Adjust
1870 ubsan_create_data callers.
1871
446bdf5f 18722014-03-22 Jakub Jelinek <jakub@redhat.com>
1873
1874 PR debug/60603
1875 * c-opts.c (c_finish_options): Restore cb_file_change call to
1876 <built-in>.
1877
8895f0a3 18782014-03-13 Jakub Jelinek <jakub@redhat.com>
1879
1880 PR middle-end/36282
1881 * c-pragma.c (apply_pragma_weak): Only look at
1882 TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) if
1883 DECL_ASSEMBLER_NAME_SET_P (decl).
1884 (maybe_apply_pending_pragma_weaks): Exit early if
1885 vec_safe_is_empty (pending_weaks) rather than only when
1886 !pending_weaks.
1887 (maybe_apply_pragma_weak): Likewise. If !DECL_ASSEMBLER_NAME_SET_P,
1888 set assembler name back to NULL afterwards.
1889
7a5da2cd 18902014-03-11 Jason Merrill <jason@redhat.com>
1891
1892 * c.opt: Add -std=gnu++14.
1893
95093889 18942014-03-11 Ian Bolton <ian.bolton@arm.com>
1895
1896 * c-opts.c (c_common_post_options): Don't override
1897 -ffp-contract=fast if unsafe-math-optimizations is on.
1898
c9a24b37 18992014-03-08 Paulo Matos <paulo@matos-sorge.com>
1900
1901 * c.opt: Enable LTO FE for fshort-double.
1902
3f6dba6e 19032014-03-07 Jason Merrill <jason@redhat.com>
1904
1905 * c.opt: Add -std=c++14.
1906
3bfdc94f 19072014-03-06 Marek Polacek <polacek@redhat.com>
1908
1909 PR c/60197
1910 * cilk.c (contains_cilk_spawn_stmt): New function.
1911 (contains_cilk_spawn_stmt_walker): Likewise.
1912 (recognize_spawn): Give error on invalid use of _Cilk_spawn.
1913 * c-common.h (contains_cilk_spawn_stmt): Add declaration.
1914
8b3a6a4c 19152014-03-03 Jakub Jelinek <jakub@redhat.com>
1916
1917 * c-pragma.c (c_pp_lookup_pragma): Handle PRAGMA_CILK_SIMD.
1918 (init_pragma): Call cpp_register_deferred_pragma for PRAGMA_CILK_SIMD
1919 even when flag_preprocess_only.
1920
734ec290 19212014-02-26 Jason Merrill <jason@redhat.com>
1922
1923 PR c++/59231
1924 PR c++/11586
1925 * c-common.c (shorten_compare): Don't check
1926 c_inhibit_evaluation_warnings.
1927
81aec8b8 19282014-02-19 Jakub Jelinek <jakub@redhat.com>
1929
d1081017 1930 PR c/37743
1931 * c-common.c (c_common_nodes_and_builtins): When initializing
1932 c_uint{16,32,64}_type_node, also set corresponding
1933 uint{16,32,64}_type_node to the same value.
1934
81aec8b8 1935 PR c++/60267
1936 * c-pragma.c (init_pragma): Don't call cpp_register_deferred_pragma
1937 for PRAGMA_IVDEP if flag_preprocess_only.
1938
312243bb 19392014-02-12 Jakub Jelinek <jakub@redhat.com>
1940
1941 PR c/60101
1942 * c-common.c (merge_tlist): If copy is true, call new_tlist,
1943 if false, add ADD itself, rather than vice versa.
1944 (verify_tree): For COND_EXPR, don't call merge_tlist with non-zero
1945 copy. For SAVE_EXPR, only call merge_tlist once.
1946
237e78b1 19472014-02-08 Jakub Jelinek <jakub@redhat.com>
1948
1949 PR middle-end/60092
1950 * c-common.c (handle_alloc_size_attribute): Use tree_fits_uhwi_p
1951 and tree_to_uhwi.
1952 (handle_alloc_align_attribute, handle_assume_aligned_attribute): New
1953 functions.
1954 (c_common_attribute_table): Add alloc_align and assume_aligned
1955 attributes.
1956
76fdceeb 19572014-02-06 Marek Polacek <polacek@redhat.com>
1958
1959 PR c/60087
1960 * c-common.c (warn_for_sign_compare): Call warning_at with location
1961 instead of warning.
1962
4a4dea42 19632014-02-05 Marek Polacek <polacek@redhat.com>
1964
1965 PR c/53123
1966 * c-omp.c (c_finish_omp_atomic): Remove unreachable return
1967 statement.
1968
ec704957 19692014-02-04 Marek Polacek <polacek@redhat.com>
1970
1971 PR c/60036
1972 * c-common.c (conversion_warning): Unwrap C_MAYBE_CONST_EXPR and/or
1973 SAVE_EXPR.
1974
caf62483 19752014-02-03 Marc Glisse <marc.glisse@inria.fr>
1976
1977 PR c++/53017
1978 PR c++/59211
1979 * c-common.c (handle_aligned_attribute, handle_alloc_size_attribute,
1980 handle_vector_size_attribute, handle_nonnull_attribute): Call
1981 default_conversion on the attribute argument.
1982 (handle_nonnull_attribute): Increment the argument number.
1983
ec761d5a 19842014-01-31 Marek Polacek <polacek@redhat.com>
1985
1986 PR c/59963
1987 * c-common.c (add_atomic_size_parameter): Pass vNULL to
1988 build_function_call_vec.
1989 (resolve_overloaded_builtin): Likewise.
1990 * c-common.h (build_function_call_vec): Adjust declaration.
1991
22a75734 19922014-01-30 Marek Polacek <polacek@redhat.com>
1993
1994 PR c/59940
1995 * c-common.h (unsafe_conversion_p): Adjust declaration.
1996 (warnings_for_convert_and_check): Likewise.
1997 (convert_and_check): Likewise.
1998 * c-common.c (unsafe_conversion_p): Add location parameter. Call
1999 expansion_point_location_if_in_system_header on it.
2000 (warnings_for_convert_and_check): Add location parameter. Call
2001 expansion_point_location_if_in_system_header on it. Use it.
2002 (convert_and_check): Add location parameter. Use it.
2003 (conversion_warning): Likewise.
2004 (c_add_case_label): Adjust convert_and_check calls.
2005 (scalar_to_vector): Adjust unsafe_conversion_p calls.
2006
a89e6c15 20072014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
2008
2009 * c-common.c (c_define_builtins): Replaced flag_enable_cilkplus with
2010 flag_cilkplus.
2011 * c-pragma.c (init_pragma): Likewise.
2012 * c.opt: Likewise.
2013
2623625f 20142014-01-23 Marek Polacek <polacek@redhat.com>
2015
2016 PR c/59846
2017 * c-common.c (shorten_compare): Add location_t parameter.
2018 * c-common.h (shorten_binary_op): Adjust declaration.
2019
46da3601 20202014-01-23 Marek Polacek <polacek@redhat.com>
2021
2022 PR c/58346
2023 * c-common.c (pointer_to_zero_sized_aggr_p): New function.
2024 * c-common.h: Declare it.
2025
c9743c6a 20262014-01-20 Eric Botcazou <ebotcazou@adacore.com>
2027
2028 * c-ada-spec.h (dump_ada_specs): Revert prototype change.
2029 * c-ada-spec.c (dump_ads): Likewise.
2030 (cpp_check): Likewise.
2031 (dump_ada_specs): Likewise.
2032
20332014-01-15 Laurent Alfonsi <laurent.alfonsi@st.com>
36e33c6a 2034
2035 PR c++/49718
2036 * c-common.c (handle_no_instrument_function_attribute): Allow
2037 no_instrument_function attribute in class member
2038 definition/declaration.
2039
1248c663 20402014-01-15 Jakub Jelinek <jakub@redhat.com>
2041
2042 PR c/58943
2043 * c-omp.c (c_finish_omp_atomic): Set in_late_binary_op around
2044 build_modify_expr with non-NOP_EXPR opcode. Handle return from it
2045 being COMPOUND_EXPR.
2046 (c_finish_omp_for): Handle incr being COMPOUND_EXPR with first
2047 operand a SAVE_EXPR and second MODIFY_EXPR.
2048
6e5c480b 20492014-01-09 Jakub Jelinek <jakub@redhat.com>
2050
2051 PR target/58115
2052 * c-pch.c (c_common_write_pch): Call
2053 prepare_target_option_nodes_for_pch.
2054
3aea1f79 20552014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
2056
2057 Update copyright years
2058
e4f22041 20592014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
2060
2061 * array-notation-common.c, c-cilkplus.c: Use the standard form for
2062 the copyright notice.
2063
7fb0fe24 20642013-12-28 Eric Botcazou <ebotcazou@adacore.com>
2065
2066 * c-ada-spec.c (print_constructor): New function.
2067 (print_destructor): Retrieve the origin of the destructor.
2068 (print_ada_declaration): Revamp handling of constructors/destructors.
2069
468088ac 20702013-12-23 Stuart Hastings <stuart@apple.com>
2071 Bill Maddox <maddox@google.com>
2072 Jason Merrill <jason@redhat.com>
2073
2074 * c.opt: Add -fdeclone-ctor-dtor.
2075 * c-opts.c (c_common_post_options): Default to on iff -Os.
2076
74acc703 20772013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
2078
2079 * c-common.c (c_common_attribute_table): Added "cilk simd function"
2080 attribute.
2081 * c-pragma.h (enum pragma_cilk_clause): Remove.
2082 (enum pragma_omp_clause): Added the following fields:
2083 PRAGMA_CILK_CLAUSE_NOMASK, PRAGMA_CILK_CLAUSE_MASK,
2084 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_NONE,
2085 PRAGMA_CILK_CLAUSE_LINEAR, PRAGMA_CILK_CLAUSE_PRIVATE,
2086 PRAGMA_CILK_CLAUSE_FIRSTPRIVATE, PRAGMA_CILK_CLAUSE_LASTPRIVATE,
2087 PRAGMA_CILK_CLAUSE_UNIFORM.
2088
2089
433e804e 20902013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
2091
2092 * cilk.c (cilk_outline): Made this function non-static.
2093 (gimplify_cilk_spawn): Removed pre_p and post_p arguments.
2094 (create_cilk_wrapper): Added a new parameter: a function pointer.
2095 (c_install_body_w_frame_cleanup): Remove
2096 (extract_free_variables): Added VEC_INIT_EXPR and CONSTRUCTOR case.
2097 * c-common.h (cilk_outline): New prototype.
2098 (gimplify_cilk_spawn): Removed two parameters.
2099 (cilk_install_body_with_frame_cleanup): New prototype.
2100 * c-gimplify.c (c_gimplify_expr): Added MODIFY_EXPR, CALL_EXPR and
2101 CILK_SPAWN_STMT case.
2102
5bcc7e60 21032013-12-11 Bernd Schmidt <bernds@codesourcery.com>
2104
e66325ea 2105 * c-common.c (c_fully_fold_internal): Handle ADDR_SPACE_CONVERT_EXPR.
2106
5bcc7e60 2107 * c-common.h (enum c_tree_index): Remove CTI_INT_ARRAY_TYPE.
2108 (int_array_type_node): Remove.
2109 * c-common.c (c_common_nodes_and_builtins): Don't build it.
2110
0b26ec77 21112013-12-05 Marek Polacek <polacek@redhat.com>
2112
2113 PR c/52023
2114 * c-common.c (c_sizeof_or_alignof_type): Move a declaration into
2115 [ADJUST_FIELD_ALIGN].
2116
a179a7dc 21172013-12-04 Joseph Myers <joseph@codesourcery.com>
2118
2119 PR c/52023
2120 * c-common.c (c_sizeof_or_alignof_type): Add parameter min_alignof
2121 and check field alignment if set.
2122 * c-common.h (c_sizeof_or_alignof_type): Update prototype.
2123 (c_sizeof, c_alignof): Update calls to c_sizeof_or_alignof_type.
2124
137559b2 21252013-12-04 Jakub Jelinek <jakub@redhat.com>
2126 Marek Polacek <polacek@redhat.com>
2127
2128 * c-gimplify.c (c_gimplify_expr): If doing the integer-overflow
2129 sanitization, call unsigned_type_for only when !TYPE_OVERFLOW_WRAPS.
2130
648fd348 21312013-11-29 H.J. Lu <hongjiu.lu@intel.com>
2132
2133 PR c/59309
2134 * cilk.c (gimplify_cilk_spawn): Properly handle function without
2135 arguments.
2136
253e1cae 21372013-11-29 Jakub Jelinek <jakub@redhat.com>
2138
2139 PR c/59280
2140 * c-common.c (get_priority): If TREE_VALUE (args) is IDENTIFIER_NODE,
2141 goto invalid. If it is error_mark_node, don't issue further
2142 diagnostics.
2143
3e398f5b 21442013-11-28 Sergey Ostanevich <sergos.gnu@gmail.com>
2145
2146 * c.opt (Wopenmp-simd): New.
2147
020bc656 21482013-11-22 Jakub Jelinek <jakub@redhat.com>
2149
2150 * c-ubsan.h (ubsan_instrument_return): New prototype.
2151 * c-ubsan.c (ubsan_instrument_return): New function.
2152
bc61cadb 21532013-11-22 Andrew MacLeod <amacleod@redhat.com>
2154
2155 * c-common.c: Add required include files from gimple.h.
2156 * c-gimplify.c: Likewise
2157 * cilk.c: Likewise
2158
3df42822 21592013-11-22 David Malcolm <dmalcolm@redhat.com>
2160
2161 * c-common.c (unsafe_conversion_p): Remove use of
2162 EXPR_LOC_OR_HERE macro.
2163 (conversion_warning): Likewise.
2164 (warnings_for_convert_and_check): Likewise.
2165 (warn_for_collisions_1): Likewise.
2166 (shorten_compare): Likewise, and remove use of in_system_header
2167 macro, using the location from the former.
2168 * c-lex.c (dump_one_header): Remove use of input_filename macro.
2169 (cb_def_pragma): Remove use of in_system_header macro.
2170 (lex_string): Likewise.
2171 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
2172
8c53c46c 21732013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
2174 Mike Stump <mikestump@comcast.net>
2175 Richard Sandiford <rdsandiford@googlemail.com>
2176
2177 * c-ada-spec.c (is_simple_enum): Use tree_to_shwi and tree_to_uhwi
2178 instead of TREE_INT_CST_LOW, in cases where there is a protecting
2179 tree_fits_shwi_p or tree_fits_uhwi_p.
2180 (dump_generic_ada_node): Likewise.
2181 * c-format.c (check_format_arg): Likewise.
2182 * c-pretty-print.c (pp_c_integer_constant): Likewise.
2183
5200ef07 21842013-11-20 Kenneth Zadeck <zadeck@naturalbridge.com>
2185
2186 * c-common.c (check_function_arguments_recurse): Use tree_to_uhwi.
2187
ca9d7d74 21882013-11-19 Joshua J Cogliati <jrincayc@yahoo.com>
2189
2190 PR c/53001
2191 * c-common.c (unsafe_conversion_p): Make this function
2192 return an enumeration with more detail.
2193 (conversion_warning): Use the new return type of
2194 unsafe_conversion_p to separately warn either about conversions
2195 that lower floating point number precision or about the other
2196 kinds of conversions.
2197 * c-common.h (enum conversion_safety): New enumeration.
2198 (unsafe_conversion_p): switching return type to
2199 conversion_safety enumeration.
2200 * c.opt: Adding new warning -Wfloat-conversion and
2201 enabling it with -Wconversion.
2202
0391a567 22032013-11-19 Basile Starynkevitch <basile@starynkevitch.net>
2204
2205 * c-opts.c: Include plugin.h.
2206 (cb_file_change): Invoke plugin event PLUGIN_INCLUDE_FILE.
2207
19b928d9 22082013-11-19 Marek Polacek <polacek@redhat.com>
2209
2210 * c-ubsan.c (ubsan_instrument_division): Adjust ubsan_create_data
2211 call.
2212 (ubsan_instrument_shift): Likewise.
2213 (ubsan_instrument_vla): Likewise.
2214
aa59f000 22152013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2216
2217 * c-common.c (convert_vector_to_pointer_for_subscript): Remove
2218 cast to unsigned type.
2219
08f817b3 22202013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2221
2222 * c-common.c (fold_offsetof_1): Use tree_to_uhwi rather than
2223 tree_low_cst.
2224 (complete_array_type): Update comment to refer to tree_to_[su]hwi
2225 rather than tree_low_cst.
2226
6a0712d4 22272013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2228
2229 * c-common.c, c-cppbuiltin.c: Replace tree_low_cst (..., 1) with
2230 tree_to_uhwi throughout.
2231
fcb97e84 22322013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2233
2234 * c-common.c, c-format.c, c-omp.c, c-pretty-print.c: Replace
2235 tree_low_cst (..., 0) with tree_to_shwi throughout.
2236
cd4547bf 22372013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2238
2239 * c-ada-spec.c, c-common.c, c-pretty-print.c: Replace
2240 host_integerp (..., 1) with tree_fits_uhwi_p throughout.
2241
35ec552a 22422013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2243
2244 * c-ada-spec.c, c-common.c, c-format.c, c-pretty-print.c: Replace
2245 host_integerp (..., 0) with tree_fits_shwi_p throughout.
2246
f2697631 22472013-11-15 Aldy Hernandez <aldyh@redhat.com>
2248
2249 * c-cilkplus.c: New file.
2250 * c-common.c (readonly_error): Add location argument.
2251 * c-common.h (readonly_error): Same.
2252 (c_finish_cilk_clauses): Protoize.
2253 (c_check_cilk_loop): Same.
2254 c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
2255 Do not fail on error_mark_node.
2256 Abstract increment canonicalization to here...
2257 (c_omp_for_incr_canonicalize_ptr): New.
2258 c-pragma.c (init_pragma): Register "simd" pragma.
2259 c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
2260 (enum pragma_cilk_clause): New.
2261
0aa8c34e 22622013-11-15 Richard Sandiford <rdsandiford@googlemail.com>
2263
2264 * c-pretty-print.c (pp_c_character_constant): Remove unnecessary
2265 wchar_type and host_integerp checks.
2266
e795d6e1 22672013-11-14 Andrew MacLeod <amacleod@redhat.com>
2268
2269 * c-common.c: Likewise.
2270 * c-gimplify.c: Likewise.
2271 * cilk.c: Likewise.
2272
9ed99284 22732013-11-14 Diego Novillo <dnovillo@google.com>
2274
2275 * c-common.c: Include fold-const.h.
2276 Include stor-layout.h.
2277 Include calls.h.
2278 Include stringpool.h.
2279 Include attribs.h.
2280 Include varasm.h.
2281 Include trans-mem.h.
2282 * c-cppbuiltin.c: Include stor-layout.h.
2283 Include stringpool.h.
2284 * c-format.c: Include stringpool.h.
2285 * c-lex.c: Include stringpool.h.
2286 Include stor-layout.h.
2287 * c-pragma.c: Include stringpool.h.
2288 Include attribs.h.
2289 Include varasm.h.
2290 Include gcc-symtab.h.
2291 * c-pretty-print.c: Include stor-layout.h.
2292 Include attribs.h.
2293 * cilk.c: Include stringpool.h.
2294 Include calls.h.
2295
4fba5eb9 22962013-11-13 Joseph Myers <joseph@codesourcery.com>
2297
2298 * c-common.h (enum rid): Add RID_AUTO_TYPE.
2299 * c-common.c (c_common_reswords): Add __auto_type.
2300 (keyword_begins_type_specifier): Handle RID_AUTO_TYPE.
2301
a8783bee 23022013-11-12 Andrew MacLeod <amacleod@redhat.com>
2303
e795d6e1 2304 * c-common.c: Include gimplify.h.
2305 * c-gimplify.c: Likewise.
2306 * cilk.c: Likewise.
2307 * c-omp.c: Include gimple-expr.h instead of gimple.h.
2308 * c-ubsan.c: Don't include gimple.h.
a8783bee 2309
d184e0c0 23102013-11-12 Joseph Myers <joseph@codesourcery.com>
2311
2312 * c-common.c (c_common_reswords): Add _Thread_local.
2313
a056826c 23142013-11-09 Joseph Myers <joseph@codesourcery.com>
2315
2316 * c-common.c (atomic_size_supported_p): New function.
2317 (resolve_overloaded_atomic_exchange)
2318 (resolve_overloaded_atomic_compare_exchange)
2319 (resolve_overloaded_atomic_load, resolve_overloaded_atomic_store):
2320 Use it instead of comparing size with a local list of sizes.
2321
b560fabd 23222013-11-07 Andrew MacLeod <amacleod@redhat.com>
2323 Joseph Myers <joseph@codesourcery.com>
2324
2325 * c-common.h (enum rid): Add RID_ATOMIC.
2326 * c-common.c (c_common_reswords): Add _Atomic.
2327 (sync_resolve_params): Use TYPE_MAIN_VARIANT on pointer argument.
2328 (keyword_is_type_qualifier): Accept RID_ATOMIC.
2329 * c-format.c (check_format_types): Check for extra _Atomic
2330 qualifiers in format argument.
2331 * c-pretty-print.c (pp_c_cv_qualifiers): Handle atomic qualifier.
2332 (pp_c_type_qualifier_list): Mention _Atomic in comment.
2333
5b1a0622 23342013-11-06 Tobias Burnus <burnus@net-b.de>
2335
2336 * c-common.c (reason_option_codes_t): Add CPP_W_DATE_TIME.
2337
4f8f4cb8 23382013-11-06 Joseph Myers <joseph@codesourcery.com>
2339
2340 * c-opts.c (c_common_post_options): Set -ffp-contract=off in C
2341 standards modes.
2342 * c-cppbuiltin.c (cpp_iec_559_value): Consider -ffp-contract=fast
2343 to mean lack of IEEE 754 support.
2344
9148bda3 23452013-11-05 Tobias Burnus <burnus@net-b.de>
2346
2347 * c.opt (-Wdate-time): New option
2348 * c-opts.c (sanitize_cpp_opts): Pass on to libcpp.
2349
08c5f4d5 23502013-11-05 Joseph Myers <joseph@codesourcery.com>
2351
2352 * c-cppbuiltin.c (cpp_iec_559_value): Test
2353 flag_excess_precision_cmdline not flag_excess_precision.
2354
c630ef93 23552013-11-05 Tobias Burnus <burnus@net-b.de>
2356
2357 * c.opt (fopenmp-simd): New option.
2358 * c-pragma.c (omp_pragmas): Move pragmas which can contain simd to ...
2359 (omp_pragmas): ... this new struct.
2360 (c_pp_lookup_pragma): Also walk omp_pragmas.
2361 (init_pragma): Init pragmas for -fopenmp-simd.
2362
7354a89b 23632013-11-04 Marek Polacek <polacek@redhat.com>
2364
2365 PR c++/58979
2366 * c-common.c (invalid_indirection_error): Handle RO_ARROW_STAR case.
2367
4c866b9b 23682013-11-04 Joseph Myers <joseph@codesourcery.com>
2369
2370 * c-cppbuiltin.c (cpp_iec_559_value, cpp_iec_559_complex_value):
2371 New functions.
2372 (c_cpp_builtins): Define __GCC_IEC_559 and __GCC_IEC_559_COMPLEX.
2373
e2a6a333 23742013-11-04 Eric Botcazou <ebotcazou@adacore.com>
2375
2376 * c-ada-spec.h (cpp_operation): Add IS_TRIVIAL.
2377 (dump_ada_specs): Adjust prototype of second callback.
2378 * c-ada-spec.c (cpp_check): New global variable.
2379 (dump_ada_nodes): Remove cpp_check parameter and do not pass it down.
2380 (print_generic_ada_decl): Likewise.
2381 (has_static_fields): Change return type to bool and add guard.
2382 (has_nontrivial_methods): New predicate.
2383 (is_tagged_type): Change return type to bool.
2384 (separate_class_package): Call has_nontrivial_methods.
2385 (pp_ada_tree_identifier): Minor tweaks.
2386 (dump_ada_function_declaration): Adjust calls to dump_generic_ada_node.
2387 (dump_ada_array_domains): Likewise.
2388 (dump_ada_array_type): Likewise.
2389 (dump_template_types): Remove cpp_check parameter and do not pass it to
2390 dump_generic_ada_node.
2391 (dump_ada_template): Likewise.
2392 (dump_generic_ada_node): Remove cpp_check parameter and do not pass it
2393 recursively.
2394 (print_ada_methods): Change return type to integer. Remove cpp_check
2395 parameter and do not pass it down.
2396 (dump_nested_types): Remove cpp_check parameter and do not pass it to
2397 dump_generic_ada_node.
2398 (print_ada_declaration): Likewise. Test RECORD_OR_UNION_TYPE_P before
2399 accessing methods.
2400 (print_ada_struct_decl): Remove cpp_check parameter and do not pass it
2401 down. Use has_nontrivial_methods to recognize C++ classes. Use return
2402 value of print_ada_methods.
2403 (dump_ads): Rename cpp_check parameter to check and adjust prototype.
2404 Set cpp_check to it before invoking dump_ada_nodes.
2405 (dump_ada_specs): Likewise.
2406
2c4c3477 24072013-11-03 Marek Polacek <polacek@redhat.com>
2408
2409 * c-ubsan.c: Don't include hash-table.h.
2410 (ubsan_instrument_vla): New function.
2411 * c-ubsan.h: Declare it.
2412
452659af 24132013-10-31 David Malcolm <dmalcolm@redhat.com>
2414
2415 Automated part of renaming of symtab_node_base to symtab_node.
2416
2417 Patch autogenerated by rename_symtab.py from
2418 https://github.com/davidmalcolm/gcc-refactoring-scripts
2419 revision 58bb219cc090b2f4516a9297d868c245495ee622
2420
2421 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename
2422 symtab_node_base to symtab_node.
2423
4d6f7dd4 24242013-10-31 Edward Smith-Rowland <3dw4rd@verizon.net>
2425
2426 Implement C++14 digit separators.
2427 * c-lex.c (interpret_float): Remove digit separators from scratch string
2428 before building real literal.
2429
06cfe805 24302013-10-30 Jakub Jelinek <jakub@redhat.com>
2431
2432 * cilk.c (create_cilk_helper_decl): Use HOST_WIDE_INT_PRINT_DEC.
2433
d037099f 24342013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
2435
2436 * c-common.c (c_common_reswords[]): Added _Cilk_spawn and _Cilk_sync
2437 fields.
2438 (c_define_builtins): Called cilk_init_builtins if Cilk Plus is
2439 enabled.
2440 * c-common.h (enum rid): Added RID_CILK_SPAWN and RID_CILK_SYNC.
2441 (insert_cilk_frame): New prototype.
2442 (cilk_init_builtins): Likewise.
2443 (gimplify_cilk_spawn): Likewise.
2444 (c_cilk_install_body_w_frame_cleanup): Likewise.
2445 (cilk_detect_spawn_and_unwrap): Likewise.
2446 (cilk_set_spawn_marker): Likewise.
2447 (build_cilk_sync): Likewise.
2448 (build_cilk_spawn): Likewise.
2449 * cilk.c: New file.
2450
02774f2d 24512013-10-29 David Malcolm <dmalcolm@redhat.com>
2452
2453 Patch autogenerated by refactor_symtab.py from
2454 https://github.com/davidmalcolm/gcc-refactoring-scripts
2455 revision 58bb219cc090b2f4516a9297d868c245495ee622
2456
2457 * c-gimplify.c (c_genericize): Update for conversion of symtab types
2458 to a true class hierarchy.
2459 * c-pragma.c (maybe_apply_pending_pragma_weaks): Likewise.
2460
31fe10fd 24612013-10-27 Richard Sandiford <rdsandiford@googlemail.com>
2462
2463 * c-lex.c (interpret_integer): Remove call to cpp_num_sign_extend.
2464
b1c06ff9 24652013-10-26 Jeff Law <law@redhat.com>
2466
1f78217c 2467 * c-common.c (c_define_builtins): Remove mudflap support.
2468 * c.opt: Ignore and warn for mudflap options.
b1c06ff9 2469
48a972c8 24702013-10-24 Tobias Burnus <burnus@net-b.de>
4644b593 2471
2472 PR other/33426
2473 * c-pragma.c (init_pragma) Add #pragma ivdep handling.
2474 * c-pragma.h (pragma_kind): Add PRAGMA_IVDEP.
2475
546a04b1 24762013-10-23 Jason Merrill <jason@redhat.com>
2477
2478 * c-format.c (gcc_cxxdiag_char_table): Add %X.
2479
bc7bff74 24802013-10-11 Jakub Jelinek <jakub@redhat.com>
2481
d62c713e 2482 * c-common.h (omp_clause_mask::operator !=): New method.
2483 * c-omp.c (c_omp_split_clauses): Use if ((mask & something) != 0)
2484 instead of if (mask & something) tests everywhere.
2485
bc7bff74 2486 * c-cppbuiltin.c (c_cpp_builtins): Predefine _OPENMP to
2487 201307 instead of 201107.
2488 * c-common.c (DEF_FUNCTION_TYPE_8): Define.
2489 (c_common_attribute_table): Add "omp declare target" and
2490 "omp declare simd" attributes.
2491 (handle_omp_declare_target_attribute,
2492 handle_omp_declare_simd_attribute): New functions.
2493 * c-omp.c: Include c-pragma.h.
2494 (c_finish_omp_taskgroup): New function.
2495 (c_finish_omp_atomic): Add swapped argument, if true,
2496 build the operation first with rhs, lhs arguments and use NOP_EXPR
2497 build_modify_expr.
2498 (c_finish_omp_for): Add code argument, pass it down to make_code.
2499 (c_omp_split_clauses): New function.
2500 (c_split_parallel_clauses): Removed.
2501 (c_omp_declare_simd_clause_cmp, c_omp_declare_simd_clauses_to_numbers,
2502 c_omp_declare_simd_clauses_to_decls): New functions.
2503 * c-common.h (omp_clause_mask): New type.
2504 (OMP_CLAUSE_MASK_1): Define.
2505 (omp_clause_mask::omp_clause_mask, omp_clause_mask::operator &=,
2506 omp_clause_mask::operator |=, omp_clause_mask::operator ~,
2507 omp_clause_mask::operator |, omp_clause_mask::operator &,
2508 omp_clause_mask::operator <<, omp_clause_mask::operator >>,
2509 omp_clause_mask::operator ==): New methods.
2510 (enum c_omp_clause_split): New.
2511 (c_finish_omp_taskgroup): New prototype.
2512 (c_finish_omp_atomic): Add swapped argument.
2513 (c_finish_omp_for): Add code argument.
2514 (c_omp_split_clauses): New prototype.
2515 (c_split_parallel_clauses): Removed.
2516 (c_omp_declare_simd_clauses_to_numbers,
2517 c_omp_declare_simd_clauses_to_decls): New prototypes.
2518 * c-pragma.c (omp_pragmas): Add new OpenMP 4.0 constructs.
2519 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_CANCEL,
2520 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_DECLARE_REDUCTION,
2521 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_SIMD,
2522 PRAGMA_OMP_TARGET, PRAGMA_OMP_TASKGROUP and PRAGMA_OMP_TEAMS.
2523 Remove PRAGMA_OMP_PARALLEL_FOR and PRAGMA_OMP_PARALLEL_SECTIONS.
2524 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_ALIGNED,
2525 PRAGMA_OMP_CLAUSE_DEPEND, PRAGMA_OMP_CLAUSE_DEVICE,
2526 PRAGMA_OMP_CLAUSE_DIST_SCHEDULE, PRAGMA_OMP_CLAUSE_FOR,
2527 PRAGMA_OMP_CLAUSE_FROM, PRAGMA_OMP_CLAUSE_INBRANCH,
2528 PRAGMA_OMP_CLAUSE_LINEAR, PRAGMA_OMP_CLAUSE_MAP,
2529 PRAGMA_OMP_CLAUSE_NOTINBRANCH, PRAGMA_OMP_CLAUSE_NUM_TEAMS,
2530 PRAGMA_OMP_CLAUSE_PARALLEL, PRAGMA_OMP_CLAUSE_PROC_BIND,
2531 PRAGMA_OMP_CLAUSE_SAFELEN, PRAGMA_OMP_CLAUSE_SECTIONS,
2532 PRAGMA_OMP_CLAUSE_SIMDLEN, PRAGMA_OMP_CLAUSE_TASKGROUP,
2533 PRAGMA_OMP_CLAUSE_THREAD_LIMIT, PRAGMA_OMP_CLAUSE_TO and
2534 PRAGMA_OMP_CLAUSE_UNIFORM.
2535
d7dcba40 25362013-10-09 Marc Glisse <marc.glisse@inria.fr>
2537
2538 PR tree-optimization/20318
2539 * c-common.c (handle_returns_nonnull_attribute): New function.
2540 (c_common_attribute_table): Add returns_nonnull.
2541
0b7282f1 25422013-10-03 Marc Glisse <marc.glisse@inria.fr>
2543
2544 PR c++/19476
2545 * c.opt (fcheck-new): Move to common.opt.
2546
51f553af 25472013-09-25 Marek Polacek <polacek@redhat.com>
2548 Jakub Jelinek <jakub@redhat.com>
2549
2550 PR sanitizer/58413
2551 * c-ubsan.c (ubsan_instrument_shift): Don't instrument
2552 an expression if we can prove it is correct.
2553 (ubsan_instrument_division): Likewise. Remove unnecessary
2554 check.
2555
05f893e1 25562013-09-18 Marek Polacek <polacek@redhat.com>
2557
2558 PR sanitizer/58411
2559 * c-common.c (handle_no_sanitize_undefined_attribute): New function.
2560 Declare it.
2561 (struct attribute_spec c_common_att): Add no_sanitize_undefined.
2562
236ce1d1 25632013-09-14 Iain Sandoe <iain@codesourcery.com>
2564
2565 PR target/48094
2566 * c.opt (fgnu-runtime, fnext-runtime, fobjc-abi-version,
2567 fobjc-gc, freplace-objc-classes): Accept for LTO.
2568
f9f68d35 25692013-09-13 Jacek Caban <jacek@codeweavers.com>
2570
2571 * c-target.def: New hook
2572
ba2f764e 25732013-09-09 Paolo Carlini <paolo.carlini@oracle.com>
2574
2575 PR c++/43452
2576 * c.opt (Wdelete-incomplete): Add.
2577
73437615 25782013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
2579
2580 * c-common.c (same_scalar_type_ignoring_signedness): Delete.
2581 (vector_types_compatible_elements_p): New function.
2582 * c-common.h: (same_scalar_type_ignoring_signedness): Delete
2583 declaration.
2584 (vector_types_compatible_elements_p): Declare.
2585
95af4c75 25862013-09-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
2587
2588 * c-pretty-print.h (c_pretty_printer::simple_type_specifier): Now
2589 a virtual member function.
2590 (pp_simple_type_specifier): Remove.
2591 (pp_c_type_specifier): Likewise.
2592 * c-pretty-print.c (c_pretty_printer::simple_type_specifier):
2593 Rename from pp_c_type_specifier. Adjust.
2594 (c_pretty_printer::c_pretty_printer): Do not assign to
2595 simple_type_specifier.
2596
eaab24b9 25972013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
2598
2599 * c-pretty-print.h (c_pretty_printer::type_id): Now a virtual
2600 member function.
2601 (c_pretty_printer::storage_class_specifier): Likewise.
2602 (c_pretty_printer::initializer): Likewise.
2603 (pp_declaration): Remove.
2604 (pp_declaration_specifiers): Likewise.
2605 (pp_abstract_declarator): Likewise.
2606 (pp_declarator): Likewise.
2607 (pp_type_id): Likewise.
2608 (pp_statement): Likewise.
2609 (pp_constant): Likewise.
2610 (pp_id_expression): Likewise.
2611 (pp_primary_expression): Likewise.
2612 (pp_unary_expression): Likewise.
2613 (pp_multiplicative_expression): Likewise.
2614 (pp_conditional_expression): Likewise.
2615 (pp_assignment_expression): Likewise.
2616 (pp_expression): Likewise.
2617 (pp_c_type_id): Likewise.
2618 (pp_c_storage_class_specifier): Likewise.
2619 * c-pretty-print.c (pp_c_type_cast): Tidy.
2620 (pp_c_pointer): Likewise.
2621 (pp_c_type_specifier): Likewise.
2622 (pp_c_parameter_type_list): Likewise.
2623 (pp_c_function_definition): Likewise.
2624 (pp_c_init_declarator): Likewise.
2625 (pp_c_initializer_list): Likewise.
2626 (pp_c_constructor_elts): Likewise.
2627 (c_pretty_printer::direct_abstract_declarator): Likewise.
2628 (c_pretty_printer::declaration_specifiers): Likewise.
2629 (c_pretty_printer::primary_expression): Likewise.
2630 (c_pretty_printer::postfix_expression): Likewise.
2631 (c_pretty_printer::type_id): Rename from pp_c_type_id.
2632 (c_pretty_printer::storage_class_specifier): Rename from
2633 pp_c_storage_class_specifier.
2634 (c_pretty_printer::initializer): Rename from pp_c_initializer.
2635 (c_pretty_printer::c_pretty_printer): Do not assign to type_id,
2636 storage_class_specifier, initializer, offset_list, flags.
2637
9e46467d 26382013-08-30 Marek Polacek <polacek@redhat.com>
2639
2640 * c-ubsan.c: New file.
2641 * c-ubsan.h: New file.
2642
36a8d9b9 26432013-08-30 Gabriel Dos Reis <gdr@integrable-solutions.net>
2644
2645 * c-pretty-print.h (c_pretty_printer::declaration): Now a virtual
2646 member function.
2647 (c_pretty_printer::declaration_specifiers): Likewise.
2648 (c_pretty_printer::declarator): Likewise.
2649 (c_pretty_printer::abstract_declarator): Likewise.
2650 (c_pretty_printer::direct_abstract_declarator): Likewise.
2651 (c_pretty_printer::direct_declarator): Likewise.
2652 (c_pretty_printer::function_specifier): Likewise.
2653 (pp_declaration): Adjust.
2654 (pp_declaration_specifiers): Likewise.
2655 (pp_abstract_declarator): Likewise.
2656 (pp_direct_declarator): Likewise.
2657 (pp_function_specifier): Likewise.
2658 (pp_direct_abstract_declarator): Remove as unused.
2659 (pp_c_declaration): Remove.
2660 (pp_c_declaration_specifiers): Likewise.
2661 (pp_c_declarator): Likewise.
2662 (pp_c_direct_declarator): Likewise.
2663 (pp_c_function_specifier): Likewise.
2664 (pp_c_direct_abstract_declarator): Likewise.
2665 * c-pretty-print.c (c_pretty_printer::abstract_declarator): Rename
2666 from pp_c_abstract_declarator. Adjust.
2667 (c_pretty_printer::direct_abstract_declarator): Rename from
2668 pp_c_direct_abstract_declarator. Adjust.
2669 (c_pretty_printer::function_specifier): Rename from
2670 pp_c_function_specifier. Adjust.
2671 (c_pretty_printer::declaration_specifiers): Rename from
2672 pp_c_declaration_specifiers. Adjust.
2673 (c_pretty_printer::direct_declarator): Rename from
2674 pp_c_direct_declarator. Adjust.
2675 (c_pretty_printer::declarator): Rename from pp_c_declarator. Adjust.
2676 (c_pretty_printer::declaration): Rename from pp_c_declaration. Adjust.
2677 (c_pretty_printer::c_pretty_printer): Do not assign to
2678 declaration, declaration_specifiers, declarator,
2679 direct_declarator, direct_abstract_declarator, function_specifier.
2680
30635c2e 26812013-08-26 Gabriel Dos Reis <gdre@integrable-solutions.net>
2682
2683 * c-pretty-print.h (c_pretty_printer::unary_expression): Now a
2684 virtual member function.
2685 (c_pretty_printer::multiplicative_expression): Likewise.
2686 (c_pretty_printer::conditional_expression): Likewise.
2687 (c_pretty_printer::assignment_expression): Likewise.
2688 (c_pretty_printer::expression): Likewise.
2689 (pp_unary_expression): Adjust.
2690 (pp_multiplicative_expression): Likewise.
2691 (pp_assignment_expression): Likewise.
2692 (pp_conditional_expression): Likewise.
2693 (pp_expression): Likewise.
2694 * c-pretty-print.c (c_pretty_printer::unary_expression): Rename
2695 from pp_c_unary_expression. Adjust.
2696 (c_pretty_printer::multiplicative_expression): Rename from
2697 pp_c_multiplicative_expression. Adjust.
2698 (c_pretty_printer::conditional_expression): Rename from
2699 pp_c_conditional_expression. Adjust.
2700 (c_pretty_printer::assignment_expression): Rename from
2701 pp_c_assignment_expression. Adjust.
2702 (c_pretty_printer::expression): Rename from pp_c_expression. Adjust.
2703 (c_pretty_printer::c_pretty_printer): Do not assign to
2704 unary_expression, multiplicative_expression,
2705 conditional_expression, expression.
2706
027d08ed 27072013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
2708
2709 * c-pretty-print.h (c_pretty_printer::postfix_expression): Now a
2710 virtual member function.
2711 (pp_postfix_expression): Adjust.
2712 (pp_c_postfix_expression): Remove.
2713 * c-pretty-print.c (c_pretty_printer::postfix_expression): Rename
2714 from pp_c_postfix_expression. Adjust.
2715 (c_pretty_printer::c_pretty_printer): Do not assign to
2716 postfix_expression.
2717
f873303a 27182013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
2719
2720 * c-pretty-print.h (c_pretty_printer::primary_expression): Now a
2721 virtua member function.
2722 (pp_primary_expression): Adjust.
2723 (pp_c_primary_expression): Remove.
2724 * c-pretty-print.c (c_pretty_printer::primary_expression): Rename
2725 from pp_c_primary_expression. Adjust.
2726 (pp_c_initializer_list): Use pp_primary_expression.
2727 (c_pretty_printer::c_pretty_printer): Do not assign to
2728 primary_expression.
2729
08e3e481 27302013-08-25 Gabriel Dos Reis <gdr@integrable-solutions.net>
2731
2732 * c-pretty-print.h (c_pretty_printer::translate_string): Declare.
2733 * c-pretty-print.c (M_): Remove.
2734 (c_pretty_printer::translate_string): Define.
2735 (pp_c_type_specifier): Use it.
2736 (pp_c_primary_expression): Likewise.
2737 (pp_c_expression): Likewise.
2738
1fc4a87f 27392013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
2740
2741 * c-pretty-print.h (c_pretty_printer::id_expression): Now a
2742 virtual function.
2743 (pp_c_id_expression): Remove.
2744 (pp_id_expression): Adjust.
2745 * c-pretty-print.c (c_pretty_printer::id_expression): Rename from
2746 pp_c_id_expression. Adjust.
2747 (pp_c_postfix_expression): Use pp_id_expression.
2748 (c_pretty_printer::c_pretty_printer): Do not assign to id_expression.
2749
a6cb161b 27502013-08-24 Gabriel Dos Reis <gdr@integrable-solutions.net>
2751
2752 * c-pretty-print.h (c_pretty_printer::constant): Now a virtual
2753 member function.
2754 (pp_constant): Adjust.
2755 (pp_c_constant): Remove.
2756 * c-pretty-print.c (c_pretty_printer::constant): Rename from
2757 pp_c_constant. Adjust.
2758 (pp_c_constant)
2759 (pp_c_primary_expression): Call pp_constant in lieu of pp_c_constant.
2760 (c_pretty_printer::c_pretty_printer): Remove assignment to constant.
2761
eed6bc21 27622013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
2763
2764 * c-pretty-print.h (pp_c_pretty_printer_init): Remove.
2765 (c_pretty_printer::c_pretty_printer): Declare.
2766 * c-pretty-print.c (pretty_printer::c_pretty_printer): Rename from
2767 c_pretty_printer_init. Adjust.
2768 (print_c_tree): Do not call c_pretty_printer_init.
2769 * c-ada-spec.c (dump_ads): Remove call to pp_construct.
2770
df558d2e 27712013-08-09 Arnaud Charlet <charlet@adacore.com>
2772
2773 * c-ada-spec.c (print_ada_declaration): Prevent accessing null asm name
2774
42f9a786 27752013-08-05 Paolo Carlini <paolo.carlini@oracle.com>
2776
2777 PR c++/58080
2778 * c-common.c (pointer_int_sum): Add bool parameter.
2779 * c-common.h (pointer_int_sum): Adjust declaration.
2780
f874ddad 27812013-08-05 Gabriel Dos Reis <gdr@integrable-solutions.net>
2782
2783 * c-pretty-print.c (print_c_tree): Simplify. Use non-static local
2784 c_pretty_printer variable.
2785
a94db6b0 27862013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
2787
2788 * c-pretty-print.h (c_pretty_printer): Derive from pretty_printer.
2789 (pp_base): Remove.
2790 (pp_c_base): Likewise. Adjust users.
2791 * c-pretty-print.c (pp_c_maybe_whitespace): Adjust.
2792 (pp_c_whitespace): Do not call pp_base.
2793 (pp_c_left_paren): Likewise.
2794 (pp_c_right_paren): Likewise.
2795 (pp_c_left_brace): Likewise.
2796 (pp_c_right_brace): Likewise.
2797 (pp_c_left_bracket): Likewise.
2798 (pp_c_right_bracket): Likewise.
2799 (pp_c_dot): Likewise.
2800 (pp_c_ampersand): Likewise.
2801 (pp_c_star): Likewise.
2802 (pp_c_arrow): Likewise.
2803 (pp_c_semicolon): Likewise.
2804 (pp_c_complement): Likewise.
2805 (pp_c_exclamation): Likewise.
2806 (pp_c_direct_declarator): Likewise.
2807 (pp_c_ws_string): Likewise.
2808 (pp_c_identifier): Likewise.
2809 (pp_c_statement): Likewise.
2810 (print_c_tree): Likewise.
2811
1898176c 28122013-08-04 Ed Smith-Rowland <3dw4rd@verizon.net>
2813
2814 PR c++/58072
2815 * c-common.c (c_parse_error): Catch user-defined literal tokens and
2816 provide useful error strings.
2817
70d60d1d 28182013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
2819
2820 * c-ada-spec.c (pp_ada_tree_identifier): Use specialized pretty
2821 printer functions instead of pp_string or operators and punctuators.
2822 (dump_generic_ada_node): Likewise.
2823 * c-pretty-print.c (pp_c_type_specifier): Likewise.
2824 (pp_c_relational_expression): Likewise.
2825 (pp_c_logical_or_expression): Likewise.
2826
dda4f0ec 28272013-08-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
2828
2829 * c-ada-spec.c (print_ada_macros): Use specialized pretty printer
2830 functions instead of pp_character.
2831 (pp_ada_tree_identifier): Likewise.
2832 (dump_ada_double_name): Likewise.
2833 (dump_ada_function_declaration): Likewise.
2834 (dump_ada_array_domains): Likewise.
2835 (dump_template_types): Likewise.
2836 (dump_generic_ada_node): Likewise.
2837 (print_ada_declaration): Likewise.
2838 (print_ada_struct_decl): Likewise.
2839 * c-pretty-print.c (pp_c_integer_constant): Likewise.
2840
7aa04c8d 28412013-07-23 Tom Tromey <tromey@redhat.com>
2842
2843 * c-common.h (enum rid) <RID_GENERIC>: New constant.
2844 * c-common.c (c_common_reswords): Add _Generic.
2845
a04e8d62 28462013-07-21 OndÅ\99ej Bílka <neleai@seznam.cz>
2847
2848 * c-common.c: Fix typos.
2849 * c-common.h: Likewise.
2850
a96c3cc1 28512013-07-13 Lubos Lunak <l.lunak@suse.cz>
2852
2853 PR c++/55203
2854 * c-common.c (c_common_attribute_table): Add warn_unused.
2855 (handle_warn_unused_attribute): New.
2856
da31536d 28572013-07-10 Jakub Jelinek <jakub@redhat.com>
2858
2859 * c-ppoutput.c (scan_translation_unit): Call account_for_newlines
2860 for all CPP_TOKEN_FLD_STR tokens, not just CPP_COMMENT.
2861
839f2f70 28622013-07-10 Paolo Carlini <paolo.carlini@oracle.com>
2863
2864 PR c++/57869
2865 * c.opt: Add Wconditionally-supported.
2866
73f353d0 28672013-07-08 Graham Stott <graham.stott@btinternet.com>
2868
1f78217c 2869 * array-notation-common.c (length_mismatch_in_expr_p): Delete
73f353d0 2870 unused variables l_length and l_node.
2871
21ebaa24 28722013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
f5298614 2873
2874 PR c/57821
2875 * c-common.c (complete_array_type): Delay folding first index
2876 like other indices. When folding, check for index overflow.
2877
68ea4406 28782013-06-27 Marc Glisse <marc.glisse@inria.fr>
2879
2880 PR c++/57509
2881 * c-common.h (c_build_vec_perm_expr): New complain argument.
2882 * c-common.c (c_build_vec_perm_expr): Likewise.
2883 Use save_expr also in C++.
2884
60777f69 28852013-06-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
2886
2887 * c-common.c (c_common_nodes_and_builtins): Use cxx11 in lieu of cxx0x.
2888 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
2889 * c-opts.c (c_common_post_options): Likewise.
2890
839f2f70 28912013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
50acebe0 2892
2893 * array-notation-common.c (length_mismatch_in_expr): Changed the
2894 parameter type's from a dynamic array to a vec_tree. Also removed
2895 the size parameters.
2896 * c-common.h (length_mismatch_in_expr_p): Fixed prototype's as per
2897 the change above.
2898
e9331eab 28992013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
2900
2901 * c-common.h (struct cilkplus_an_parts): New structure.
2902 (struct cilkplus_an_loop_parts): Likewise.
2903 (cilkplus_extract_an_triplets): New prototype.
2904 (fix_sec_implicit_args): Likewise.
2905 * array-notation-common.c (cilkplus_extract_an_triplets): New function.
2906 (fix_sec_implicit_args): Likewise.
60777f69 2907
a9c99fc4 29082013-06-20 Balaji V. Iyer <balaji.v.iyer@intel.com>
2909
2910 * array-notation-common.c (find_inv_trees): Removed an unwanted
2911 typecasting.
2912 * c-common.h (struct inv_list::additional_tcodes): Changed type from
2913 enum rid to enum tree_code.
2914
f2526cce 29152013-06-11 Jan Hubicka <jh@suse.cz>
2916
2917 * c-common.c (handle_alias_ifunc_attribute): Do not set
2918 DECL_EXTERNAL for weakref variables.
2919 * c-pragma.c (handle_pragma_weak): Make sure aliases
2920 are not declared as external.
2921
09970d67 29222013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
2923
2924 * array-notation-common.c (length_mismatch_in_expr_p): Moved this
2925 function from c/c-array-notation.c.
2926 (is_cilkplus_reduce_builtin): Likewise.
2927 (find_rank): Likewise.
2928 (extract_array_notation_exprs): Likewise.
2929 (replace_array_notations): Likewise.
2930 (find_inv_trees): Likewise.
2931 (replace_inv_trees): Likewise.
2932 (contains_array_notation_expr): Likewise.
2933 (find_correct_array_notation_type): Likewise.
2934 * c-common.h (struct inv_list): Moved this struct from the file
2935 c/c-array-notation.c and added a new field called additional tcodes.
2936 (length_mismatch_in_expr_p): New prototype.
2937 (is_cilkplus_reduce_builtin): Likewise.
2938 (find_rank): Likewise.
2939 (extract_array_notation_exprs): Likewise.
2940 (replace_array_notation): Likewise.
2941 (find_inv_trees): Likewise.
2942 (replace_inv_trees): Likewise.
2943 (find_correct_array_notation_type): Likewise.
839f2f70 2944
3c6d4197 29452013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
2946
2947 * c-common.c (c_define_builtins): When cilkplus is enabled, the
2948 function array_notation_init_builtins is called.
2949 (c_common_init_ts): Added ARRAY_NOTATION_REF as typed.
2950 * c-common.def (ARRAY_NOTATION_REF): New tree.
2951 * c-common.h (build_array_notation_expr): New function declaration.
2952 (build_array_notation_ref): Likewise.
2953 (extract_sec_implicit_index_arg): New extern declaration.
2954 (is_sec_implicit_index_fn): Likewise.
2955 (ARRAY_NOTATION_CHECK): New define.
2956 (ARRAY_NOTATION_ARRAY): Likewise.
2957 (ARRAY_NOTATION_START): Likewise.
2958 (ARRAY_NOTATION_LENGTH): Likewise.
2959 (ARRAY_NOTATION_STRIDE): Likewise.
2960 * c-pretty-print.c (pp_c_postifix_expression): Added a new case for
2961 ARRAY_NOTATION_REF.
2962 (pp_c_expression): Likewise.
2963 * c.opt (flag_enable_cilkplus): New flag.
2964 * array-notation-common.c: New file.
2965
8e71dad2 29662013-05-14 Jakub Jelinek <jakub@redhat.com>
2967
2968 PR c++/57274
2969 * c-common.c (verify_tree): Don't recurse into SIZEOF_EXPR.
2970
432dd330 29712013-05-10 Marc Glisse <marc.glisse@inria.fr>
2972
2973 * c-common.c (vector_types_convertible_p): No TYPE_PRECISION for
2974 vectors.
2975
b156ec37 29762013-05-07 Han Shen <shenhan@google.com>
2977
2978 * c-cppbuiltin.c (c_cpp_builtins): Added "__SSP_STRONG__=3".
2979
1a087624 29802013-04-29 Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
2981
2982 * c-common.c (check_user_alignment): Emit error for negative values.
2983
1638c736 29842013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
2985
2986 * c-opts.c (set_std_cxx11): Use CLK_CXX1Y and CLK_GNUCXX1Y.
2987
949dbf93 29882013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
2989
2990 * c-cppbuiltin.c (c_cpp_builtins): Do not define
2991 __GXX_EXPERIMENTAL_CXX1Y__.
2992
9205a6cc 29932013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
2994 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
2995
2996 * c.opt ([Wpointer-arith]): Enabled by -Wpedantic, as documented.
2997 * c-common.c (pointer_int_sum): Change -Wpointer-arith pedwarns
2998 to simply use OPT_Wpointer_arith.
2999 (c_sizeof_or_alignof_type): Likewise.
3000
05d0bce1 30012013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
3002
3003 * c-cppbuiltin.c (c_cpp_builtins): Define __GXX_EXPERIMENTAL_CXX1Y__.
3004
41609f8b 30052013-04-12 Jakub Jelinek <jakub@redhat.com>
3006
3007 * c-format.c (gcc_diag_char_table, gcc_tdiag_char_table,
3008 gcc_cdiag_char_table, gcc_cxxdiag_char_table): Add %r and %R format
3009 specifiers.
3010
c671dc4f 30112013-04-07 Steven Bosscher <steven@gcc.gnu.org>
3012
3013 * c-pragma.c (add_to_renaming_pragma_list): Fix leading comment.
3014
ba125576 30152013-04-03 Paolo Carlini <paolo.carlini@oracle.com>
3016
3017 * c-common.c (pointer_int_sum): Remove dead code.
3018
9d3fa937 30192013-03-09 Richard Sandiford <rdsandiford@googlemail.com>
3020
3021 PR middle-end/56524
3022 * c-common.c (handle_optimize_attribute): Don't call
3023 save_optabs_if_changed.
3024
5ceebb21 30252013-03-05 Jakub Jelinek <jakub@redhat.com>
3026
3027 PR middle-end/56461
3028 * c-pch.c (pch_init): Free target_validity at the end.
3029
18eeed2b 30302013-03-04 Jakub Jelinek <jakub@redhat.com>
3031
3032 * c-pretty-print.c (pp_c_pretty_printer_init): Clear pp->flags.
3033
a9196da9 30342013-02-28 Konstantin Serebryany <konstantin.s.serebryany@gmail.com>
3035 Jakub Jelinek <jakub@redhat.com>
3036
3037 PR sanitizer/56454
3038 * c-common.c (handle_no_sanitize_address_attribute): New function.
3039 (c_common_attribute_table): Add no_sanitize_address attribute.
3040 (handle_no_address_safety_analysis_attribute): Add
3041 no_sanitize_address attribute, not no_address_safety_analysis
3042 attribute.
3043
15c27dda 30442013-02-18 Aldy Hernandez <aldyh@redhat.com>
08c7d04b 3045
3046 PR target/52555
3047 * c-common.c (handle_optimize_attribute): Call
3048 save_optabs_if_changed.
3049
19426fe1 30502013-02-18 Jakub Jelinek <jakub@redhat.com>
3051 Steven Bosscher <steven@gcc.gnu.org>
3052
3053 PR pch/54117
3054 * c-opts.c (c_common_post_options): If debug info is enabled
3055 and non-dwarf*, refuse to load PCH files and when writing PCH
3056 file warn.
3057
df936998 30582013-02-05 Jakub Jelinek <jakub@redhat.com>
3059
3060 PR middle-end/56167
3061 * c-common.c (handle_error_attribute): Fix condition.
3062
ae0c3984 30632013-01-30 Jakub Jelinek <jakub@redhat.com>
3064
3065 PR c++/55742
3066 * c-common.c (handle_target_attribute): Revert 2012-12-26 change.
3067
1c4973d7 30682013-01-18 Jason Merrill <jason@redhat.com>
3069
3070 PR target/54908
3071 * c.opt (-fextern-tls-init): New.
3072 * c-opts.c (c_common_post_options): Handle it.
3073
7c834436 30742013-01-09 Jakub Jelinek <jakub@redhat.com>
3075
3076 PR c/48418
3077 * c-common.c (c_fully_fold_internal): Warn for LSHIFT_EXPR and
3078 RSHIFT_EXPR, if orig_op1 isn't INTEGER_CST, op1 is INTEGER_CST
3079 and is either negative or bigger or equal to type precision
3080 of the first operand.
3081
5abaa10a 30822012-12-03 Marek Polacek <polacek@redhat.com>
3083
3084 PR c/55570
3085 * c-common.c (check_user_alignment): Swap order of tests,
3086 check TREE_CODE first.
3087
324ca377 30882012-11-29 Ed Smith-Rowland <3dw4rd@verizon.net>
3089
3090 PR c++/52654
3091 * c-common.h (overflow_type): New enum.
3092 (build_userdef_literal): Add overflow_type argument.
3093 (tree_userdef_literal): Add overflow_type.
3094 (USERDEF_LITERAL_OVERFLOW): New access macro.
3095 * c-common.c (build_userdef_literal): Add overflow_type
3096 argument.
3097 * c-lex.c (c_lex_with_flags): Add overflow_type to
3098 build_userdef_literal calls.
3099 (interpret_integer, interpret_float): Add overflow_type argument.
3100
b4c4a429 31012012-11-28 Richard Biener <rguenther@suse.de>
3102
3103 PR c/35634
3104 * c-gimplify.c (c_gimplify_expr): Gimplify self-modify expressions
3105 here and use a type with proper overflow behavior for types that would
3106 need to be promoted for the arithmetic.
3107
d413ffdd 31082012-11-23 Jakub Jelinek <jakub@redhat.com>
3109
3110 PR sanitizer/55435
3111 * c-common.c (handle_no_address_safety_analysis_attribute): New
3112 function.
3113 (c_common_attribute_table): Add no_address_safety_analysis.
3114
52bc861d 31152012-11-16 Simon Baldwin <simonb@google.com>
3116
3117 * c.opt: Add f[no-]canonical-system-headers.
3118 * c-opts.c (c_common_handle_option): Handle
3119 OPT_fcanonical_system_headers.
3120
2dd00636 31212012-11-09 Ed Smith-Rowland <3dw4rd@verizon.net>
3122
3123 PR c++/54413
3124 * c-opts.c (c_common_handle_option): Set new flags.
3125 * c.opt: Describe new flags.
3126
d4701f6c 31272012-11-09 Jason Merrill <jason@redhat.com>
3128
3129 * c.opt (Wabi-tag): New.
3130
72d65da9 31312012-11-09 Andi Kleen <ak@linux.intel.com>
3132
3133 PR 55139
3134 * c-common.c (get_atomic_generic_size): Mask with
3135 MEMMODEL_MASK
3136
77a357e3 31372012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
3138
3139 PR c/53063
3140 * c.opt (Wformat): Make it Alias Wformat=1.
3141 (Wformat-contains-nul,Wformat-extra-args,Wformat-nonliteral,
3142 Wformat-security,Wformat-y2k,Wformat-zero-length): Use
3143 LangEnabledBy.
3144 (Wformat=): RejectNegative. Use LangEnabledBy.
3145 (Wnonnull): Use LangEnabledBy.
3146 * c-opts.c (c_common_handle_option): Do not handle Wformat here.
3147 * c-format.c (set_Wformat): Delete.
3148 (decode_format_attr): Replace OPT_Wformat with OPT_Wformat_.
3149 (maybe_read_dollar_number): Likewise.
3150 (avoid_dollar_number): Likewise.
3151 (finish_dollar_format_checking): Likewise.
3152 (check_format_info): Likewise.
3153 (check_format_info_main): Likewise.
3154 (check_format_types): Likewise.
3155 (format_type_warning): Likewise.
3156 * c-common.c (int): Likewise.
3157 (check_function_sentinel): Likewise.
3158 * c-common.h (warn_format,set_Wformat): Do not declare here.
3159
45efa6b9 31602012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
3161
3162 PR c/53063
3163 * c.opt(Warray-bounds,Wdelete-non-virtual-dtor,Wenum-compare,
3164 Wmain,Woverlength-strings, Wunknown-pragmas,Wunused-macros):
3165 Use LangEnabledBy.
3166 (Wswitch,Wswitch-default,Wswitch-enum): Likewise. Move here from
3167 common.opt.
3168 (Wvariadic-macros): Init(1).
3169 * c-opts.c (c_common_handle_option): Do not handle them
3170 explicitly.
3171 (c_common_post_options): Likewise.
3172 (sanitize_cpp_opts): warn_unused_macros is now
3173 cpp_warn_unused_macros.
3174 (push_command_line_include): Likewise.
3175 * c-common.c (warn_unknown_pragmas): Do not define.
3176 * c-common.h (warn_unknown_pragmas): Do not declare.
3177
0e4e775a 31782012-11-07 Manuel López-Ibáñez <manu@gcc.gnu.org>
3179
3180 PR c/51294
3181 * c-common.c (conversion_warning): Handle conditional expressions.
3182
8b447d3f 31832012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
3184
3185 PR c++/54930
3186 * c.opt (Wreturn_local_addr): Define new option.
3187
f4a61754 31882012-10-25 Jason Merrill <jason@redhat.com>
3189
ecb10e6a 3190 * c.opt (Wvirtual-move-assign): New.
3191
f4a61754 3192 * c.opt (Winherited-variadic-ctor): New.
3193
7b463b19 31942012-10-25 Marc Glisse <marc.glisse@inria.fr>
3195
3196 PR c++/54427
3197 * c-common.c (scalar_to_vector): Handle VEC_COND_EXPR.
3198
6adc88f8 31992012-10-23 Joseph Myers <joseph@codesourcery.com>
3200
3201 * c-common.h (pch_cpp_save_state): Declare.
3202 * c-target.def (c_preinclude): New hook.
3203 * c-opts.c (done_preinclude): New.
3204 (push_command_line_include): Handle default preincluded header.
3205 (cb_file_change): Call pch_cpp_save_state when calling
3206 push_command_line_include.
3207 * c-pch.c (pch_ready_to_save_cpp_state, pch_cpp_state_saved)
3208 (pch_cpp_save_state): New.
3209 (pch_init): Call pch_cpp_save_state conditionally, instead of
3210 calling cpp_save_state.
3211
fa816b0b 32122012-10-20 Manuel López-Ibáñez <manu@gcc.gnu.org>
3213
3214 PR c/53063
3215 PR c/40989
3216 * c.opt (Waddress,Wchar-subscripts,Wsign-conversion,Wimplicit,
3217 Wimplicit-function-declaration,Wimplicit-int,Wsizeof-pointer-memaccess,
3218 Wnarrowing,Wparentheses,Wpointer-sign,Wreturn-type,Wsequence-point,
3219 Wsign-compare,Wuninitialized,Wmaybe-uninitialized,Wunused,
3220 Wvolatile-register-var): Add LangEnabledBy or EnabledBy.
3221 * c-opts.c (c_common_handle_option): Remove explicit handling from
3222 here.
3223 (c_common_post_options): Likewise.
3224
d214ccee 32252012-10-18 Eric Botcazou <ebotcazou@adacore.com>
3226
3227 * c-ada-spec.c (LOCATION_COL): Delete.
3228 (compare_location): New function.
3229 (compare_node): Use it.
3230 (compare_comment): Likewise.
3231
77b27208 32322012-10-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
3233
3234 PR c/53063
3235 PR c/40989
3236 * c.opt (Wstrict-aliasing=,Wstrict-overflow=): Use LangEnabledBy.
3237 * c-opts.c (c_common_handle_option): Do not set them here. Add
3238 comment.
3239 (c_common_post_options): Likewise.
3240
cc02ca4d 32412012-10-16 Eric Botcazou <ebotcazou@adacore.com>
3242
3243 * c-ada-spec.c (ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX): Define.
3244 (dump_generic_ada_node) <INTEGER_CST>: Deal with sizetype specially.
3245 Remove POINTER_TYPE handling, add large unsigned handling and use
3246 ADA_HOST_WIDE_INT_PRINT_DOUBLE_HEX for big numbers.
3247
57f872a2 32482012-10-12 Jakub Jelinek <jakub@redhat.com>
3249
3250 PR c/54381
3251 * c-common.h (sizeof_pointer_memaccess_warning): Adjust prototype.
3252 * c-common.c (sizeof_pointer_memaccess_warning): Take array of 3
3253 locs and array of 3 trees instead of just single loc and single
3254 sizeof_arg tree. Handle __builtin___*_chk builtins too, and
3255 also stpncpy, bcopy, bcmp, bzero, snprintf and vsnprintf builtins.
3256 For *cmp* builtins that take two sources strings report warnings
3257 about first and second source, not about destination and source.
3258
7354ad2e 32592012-10-12 Marc Glisse <marc.glisse@inria.fr>
3260
3261 PR c++/53055
3262 * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
3263
1ac7f120 32642012-10-11 Eric Botcazou <ebotcazou@adacore.com>
3265
3266 * c-ada-spec.c (dump_ada_template): Bail out for template declarations
3267 declaring something coming from another file.
3268
1e0cc9e3 32692012-10-10 Arnaud Charlet <charlet@adacore.com>
3270
1ac7f120 3271 PR ada/54845
1e0cc9e3 3272 * c-ada-spec.c (print_ada_struct_decl): Increase buf size.
3273
b0e7825e 32742012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
3275
3276 PR c++/54194
3277 * c-common.c (warn_about_parentheses): Add location_t parameter;
3278 use EXPR_LOC_OR_LOC.
3279 * c-common.h: Update declaration.
3280
41ed701a 32812012-10-09 Marc Glisse <marc.glisse@inria.fr>
3282
3283 PR c++/54427
3284 * c-common.c (scalar_to_vector): Moved from c-typeck.c. Support
3285 more operations. Make error messages optional.
3286 * c-common.h (enum stv_conv): Moved from c-typeck.c.
3287 (scalar_to_vector): Declare.
3288
3740094c 32892012-10-08 Jason Merrill <jason@redhat.com>
3290
3291 * c-common.c (c_common_reswords): Add thread_local.
3292
ffcdbf9c 32932012-10-08 Dodji Seketeli <dodji@redhat.com>
3294
3295 PR c++/53528 C++11 attribute support
3296 * c-common.h (bitfield_p, cxx_fundamental_alignment_p): Declare
3297 new functions.
3298 * c-common.c (check_cxx_fundamental_alignment_constraints): New
3299 static function.
3300 (handle_aligned_attribute): In choose strictest alignment
3301 among many. Use new check_cxx_fundamental_alignment_constraints.
3302 (handle_transparent_union_attribute): In c++11 attribute syntax,
3303 don't look through typedefs.
3304
ef34afc1 33052012-10-04 Arnaud Charlet <charlet@adacore.com>
3306
3307 * c-ada-spec.c (print_ada_declaration): Remove handling of TDF_RAW.
3308 * c.opt (-fdump-ada-spec, -fdump-ada-spec-slim): Move switch definition
3309 out of dumpfile.h.
3310
f1ff4562 33112012-09-25 Dehao Chen <dehao@google.com>
3312
3313 PR middle-end/54645
ef34afc1 3314 * c-pch.c (c_common_read_pch): Rebuild the location_adhoc_data
f1ff4562 3315 map when read in the pch.
3316
735538a1 33172012-09-18 Arnaud Charlet <charlet@adacore.com>
3318
3319 * c-ada-spec.c: Style fixes.
3320
9120cdc8 33212012-09-18 Thomas Quinot <quinot@adacore.com>
3322
3323 * c.opt (-fada-spec-parent): Define new command line switch.
3324 * c-ada-spec.c (get_ada_package): When -fada-spec-parent
3325 is specified, generate binding spec as a child of the specified unit.
3326
8eba82c2 33272012-09-13 Paolo Carlini <paolo.carlini@oracle.com>
3328 Manuel López-Ibáñez <manu@gcc.gnu.org>
3329
3330 PR c++/53210
3331 * c.opt ([Winit-self]): Enabled by -Wall in C++.
3332
38682990 33332012-08-23 Arnaud Charlet <charlet@adacore.com>
3334
3335 * c-ada-spec.c (dump_generic_ada_node): Fix handling of name_only
3336 for pointers, and add missing Convention C pragma.
3337 (print_ada_struct_decl): Add missing aliased keyword.
3338 (dump_ads): Add pragma Ada_2005 and Style_Checks (Off).
3339
f003f5dc 33402012-08-17 Jakub Jelinek <jakub@redhat.com>
3341
3342 * c-common.c (sizeof_pointer_memaccess_warning): New function.
3343 * c.opt (-Wsizeof-pointer-memaccess): Add new option.
3344 * c-opts.c (c_common_handle_option): Enable it for -Wall.
3345 * c-common.h (sizeof_pointer_memaccess_warning): Add prototype.
3346 * c-common.def (SIZEOF_EXPR): Moved here from cp-tree.def.
3347
ec11736b 33482012-08-10 Richard Guenther <rguenther@suse.de>
3349
3350 * c-pretty-print.c (pp_c_expression): Handle anonymous SSA names.
3351
5f7f600e 33522012-08-07 Steven Bosscher <steven@gcc.gnu.org>
3353
3354 * c-pretty-print.c (pp_c_function_definition): Use pp_newline_and_flush
3355 instead of separate pp_newline and pp_flush.
3356 (print_c_tree): Likewise.
3357
758a38ab 33582012-07-26 Richard Henderson <rth@redhat.com>
3359
3360 * c-common.c (handle_hot_attribute): Allow labels.
3361 (handle_cold_attribute): Likewise.
3362
9ca77b08 33632012-07-20 Jakub Jelinek <jakub@redhat.com>
3364
3365 PR c++/28656
3366 * c-common.c (check_function_nonnull): Handle multiple nonnull
3367 attributes properly.
3368
b9ed1410 33692012-07-16 Steven Bosscher <steven@gcc.gnu.org>
3370
3371 * c-gimplify.c: Include dumpfile.h instead of tree-dump.h.
3372 * c-ada-spec.c: Likewise.
3373 * c-dump.c (dump_stmt): Move to cp/dump.c, the only user.
3374
c2a65b90 33752012-07-14 Steven Bosscher <steven@gcc.gnu.org>
3376
3377 * c-pch.c (CHECK_NO_ASM_OUT_DURING_PCH): Do not define.
3378 Remove code conditional on it.
3379
88c5a1d1 33802012-07-11 Steven Bosscher <steven@gcc.gnu.org>
3381
3382 * c-gimplify.c: Do not include basic-block.h.
3383 * c-common.c: Do not include linfuncs.h.
3384
4a020a8c 33852012-07-08 Steven Bosscher <steven@gcc.gnu.org>
3386
3387 * c-common.h: Include tree.h.
3388
c28ddc97 33892012-07-02 Jason Merrill <jason@redhat.com>
3390
3391 PR c++/53524
3392 * c-common.c (get_priority): Call default_conversion.
3393
405ed67f 33942012-07-01 Uros Bizjak <ubizjak@gmail.com>
3395
3396 * c-pch.c (c_common_write_pch): Remove unused variables.
3397
e53d55e7 33982012-06-29 Steven Bosscher <steven@gcc.gnu.org>
3399
3400 * cppspec.c: Moved from gcc/ to here.
3401
3d9c25ec 34022012-06-27 Kai Tietz <ktietz@redhat.com>
3403
3404 PR preprocessor/37215
3405 * c-ppoutput.c (preprocess_file): Check for nonempty buffer.
3406
3169c57a 34072012-06-21 Steven Bosscher <steven@gcc.gnu.org>
3408
3409 * c-common.h (c_common_print_pch_checksum): Remove.
3410 * c-pch.c: Do not include output.h.
3411 (CHECK_NO_ASM_OUT_DURING_PCH): Define and add FIXME.
3412 (asm_out_file): Define iff CHECK_NO_ASM_OUT_DURING_PCH isdefined.
3413 (asm_file_startpos): Define iff CHECK_NO_ASM_OUT_DURING_PCH is defined.
3414 (struct c_pch_header): Remove.
3415 (get_ident): Update gpch version.
3416 (pch_init): Do not print executable_checksum to asm_out_file.
3417 Do not fail if there is no asm_out_file to read back from. Set
3418 asm_file_startpos only if CHECK_NO_ASM_OUT_DURING_PCH is defined.
3419 (c_common_write_pch): Verify that nothing was written to asm_out_file
3420 since pch_init was called. Do not write a c_pch_header, and do not
3421 copy from asm_out_file to the PCH.
3422 (c_common_read_pch): Do not read a c_pch_header, and do not restore
3423 the content of asm_out_file from the PCH.
3424 (c_common_print_pch_checksum): Remove.
3425 * c-opts.c (c_common_init): Print out executable_checksum directly.
3426
ff6624bc 34272012-06-19 Steven Bosscher <steven@gcc.gnu.org>
3428
3429 * c-target.def (objc_declare_unresolved_class_reference,
3430 objc_declare_class_definition): Add new hooks.
3431
367b1459 34322012-06-19 Steven Bosscher <steven@gcc.gnu.org>
3433
3434 * c-lex.c: Do not include output.h.
3435 (cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
3436 Remove uses of ASM_OUTPUT_IDENT.
3437
bf0cb017 34382012-06-15 Marc Glisse <marc.glisse@inria.fr>
3439
3440 PR c++/51033
3441 * c-common.h (c_build_vec_perm_expr): Move decl here.
3442 * c-common.c (c_build_vec_perm_expr): Move definition
3443 here.
3444
b37a3600 34452012-06-06 Steven Bosscher <steven@gcc.gnu.org>
3446
3447 * c.opt (fconserve-space): Turn into a no-op.
3448
19931eea 34492012-06-04 Sterling Augustine <saugustine@google.com>
5f9e7dd5 3450
3451 * c-pretty-print.h (pp_c_flag_gnu_v3): New enumerator.
3452 * c-pretty-print.c (pp_c_specifier_qualifier_list): Check it at
3453 both the start and end of the function.
3454
dff12c10 34552012-06-04 Steven Bosscher <steven@gcc.gnu.org>
3456
3457 * c-common.c: Do not include output.h.
3458 * c-pragma.c: Likewise.
3459
5f9e7dd5 34602012-06-04 Steven Bosscher <steven@gcc.gnu.org>
3461
3462 * error.c (dump_decl): Check pp_c_flag_gnu_v3.
3463 (decl_as_dwarf_string, lang_decl_dwarf_name): New functions.
3464 (lang_decl_name): Handle namespace decls.
3465
b5369b7d 34662012-05-31 Steven Bosscher <steven@gcc.gnu.org>
3467
3468 * c-ada-spec.c: Do not include output.h.
3469 * c-semantics.c: Likewise.
3470
8032877c 34712012-05-29 Joseph Myers <joseph@codesourcery.com>
3472
3473 * c-common.c: Fix typo.
3474
7843e4bc 34752012-05-29 Michael Matz <matz@suse.de>
3476
3477 * c-common.h (c_expand_decl): Remove prototype.
3478
8cf857d4 34792012-05-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
3480
3481 * c.opt (Wmissing-braces): Use LangEnabledBy(C ObjC,Wall).
3482 * c-opts.c (c_common_handle_option): Remove code handling
3483 warn_missing_braces.
3484
8b64dc3c 34852012-05-28 Paolo Carlini <paolo.carlini@oracle.com>
3486
3487 PR c++/25137
3488 * c-opts.c (c_common_handle_option): For C++ -Wall doesn't enable
3489 -Wmissing_braces.
3490
43cbde16 34912012-05-22 Dodji Seketeli <dodji@redhat.com>
3492
3493 PR c++/53322
3494 * c.opt (Wunused-local-typedefs): Use EnabledBy(Wunused).
3495
db490cb6 34962012-05-17 Manuel López-Ibáñez <manu@gcc.gnu.org>
3497
3498 * c.opt (--pedantic-errors,-pedantic-errors): Do not handle here.
3499 * c-opts.c (c_common_handle_option): Do not handle explicitly
3500 Wreturn-type, Wwrite-strings, warn_ecpp, and -pedantic-errors.
3501
a60f3e81 35022012-05-16 Dodji Seketeli <dodji@redhat.com>
3503
3504 PR preprocessor/7263
3505 * c-lex.c (c_lex_with_flags): Pass a virtual location to the call
3506 to cpp_classify_number. For diagnostics, use the precise location
3507 instead of the global input_location.
3508
82e6ef7c 35092012-05-15 Paolo Carlini <paolo.carlini@oracle.com>
3510
cd4797ff 3511 PR c++/11856
82e6ef7c 3512 * c-common.c (shorten_compare): Check c_inhibit_evaluation_warnings.
3513
258a168d 35142012-05-14 Bernd Schmidt <bernds@codesourcery.com>
3515
82e6ef7c 3516 * c-common.c (DEF_ATTR_STRING): Define and undefine as necessary.
258a168d 3517
d3b7ee7c 35182012-05-14 Manuel López-Ibáñez <manu@gcc.gnu.org>
3519
3520 PR 53063
3521 * c.opt (Wc++0X-compat,Wdelete-non-virtual-dtor,Wjump-misses-init,
3522 Wreorder): Use LangEnabledBy.
3523 * c-opts.c (c_common_handle_option): Do not enable them
3524 explicitly. Call lang-specific generated functions.
3525 (c_common_post_options): Do not set them here.
3526
70059cea 35272012-05-13 Manuel López-Ibáñez <manu@gcc.gnu.org>
3528
3529 * c.opt (Wclobbered,Wempty-body,Wignored-qualifiers,
3530 Wmissing-field-initializers,Wmissing-parameter-type,
3531 Wold-style-declaration,Woverride-init): Use EnabledBy.
3532 * c-opts.c (c_common_post_options): Do not set here explicitly.
3533
fbb6fbd8 35342012-05-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
3535
3536 PR 53063
3537 * c-opts.c (c_common_handle_option): Use handle_generated_option
3538 to enable sub-options.
3539
61f69bc9 35402012-05-10 Paolo Carlini <paolo.carlini@oracle.com>
3541
3542 PR c++/53158
3543 * c-common.c (warnings_for_convert_and_check): Use warning_at.
3544
5a1fe2db 35452012-05-10 Richard Guenther <rguenther@suse.de>
3546
3547 * c-common.c (c_sizeof_or_alignof_type): Remove assert and
3548 adjust commentary about TYPE_IS_SIZETYPE types.
3549
d42e7c5a 35502012-05-09 Manuel López-Ibáñez <manu@gcc.gnu.org>
3551
3552 PR c++/53261
3553 * c-common.c (warn_logical_operator): Check that argument of
3554 integer_zerop is not NULL.
3555
686369e8 35562012-05-05 Manuel López-Ibáñez <manu@gcc.gnu.org>
3557
3558 PR c/43772
3559 * c-common.c (warn_logical_operator): Do not warn if either side
3560 is already true or false.
3561
03fe1dc2 35622012-05-04 Manuel López-Ibáñez <manu@gcc.gnu.org>
3563
3564 PR c/51712
3565 * c-common.c (expr_original_type): New.
3566 (shorten_compare): Do not warn for enumeration types.
3567
bba5a206 35682012-05-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
3569
3570 * c.opt (fpermissive): Add Var(flag_permissive).
3571
7059d45d 35722012-04-30 Marc Glisse <marc.glisse@inria.fr>
3573
3574 PR c++/51033
3575 * c-common.c (convert_vector_to_pointer_for_subscript): New function.
3576 * c-common.h (convert_vector_to_pointer_for_subscript): Declare it.
3577
7edb1062 35782012-04-30 Dodji Seketeli <dodji@redhat.com>
3579
3580 Add -Wvarargs option
3581 * c.opt (Wvarargs): Define new option.
3582
068bea1e 35832012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
3584
3585 * c-common.c (check_function_arguments): Replace
3586 Wmissing-format-attribute with Wsuggest-attribute=format.
3587
b86527d8 35882012-04-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
3589
3590 * c.opt (Wsuggest-attribute=format): New. Alias of
3591 Wmissing-format-attribute.
3592 * c-format.c (decode_format_type): Replace
3593 Wmissing-format-attribute with Wsuggest-attribute=format.
3594 (check_function_format): Likewise.
3595
19931eea 35962012-04-27 Ollie Wild <aaw@google.com>
76d340ac 3597
3598 * c-common.c: Add CPP_W_LITERAL_SUFFIX mapping.
3599 * c-opts.c (c_common_handle_option): Handle OPT_Wliteral_suffix.
3600 * c.opt: Add Wliteral-suffix.
3601
29438999 36022012-04-22 Manuel López-Ibáñez <manu@gcc.gnu.org>
3603
3604 PR c/44774
3605 * c.opt (Wpedantic): New.
3606 (pedantic): Alias Wpedantic.
3607 * c-opts.c (c_common_handle_option): Replace -pedantic with -Wpedantic.
3608 (c_common_post_options): Likewise.
3609 (sanitize_cpp_opts): Likewise.
3610 * c-lex.c (interpret_float): Likewise.
3611 * c-format.c (check_format_types): Likewise.
3612 * c-common.c (pointer_int_sum): Likewise.
3613 (c_sizeof_or_alignof_type): Likewise.
3614 (c_add_case_label): Likewise.
3615 (c_do_switch_warnings): Likewise.
3616 * c-pragma.c (handle_pragma_float_const_decimal64): Likewise.
3617
4f9d6b8b 36182012-04-15 Jason Merrill <jason@redhat.com>
3619
3620 PR c++/52818
3621 * c-format.c (CPLUSPLUS_STD_VER): C++11 inherits from C99.
3622 (C_STD_NAME): Distinguish between C++98 and C++11.
3623
74bdbe96 36242012-04-11 Eric Botcazou <ebotcazou@adacore.com>
3625
3626 PR target/52624
3627 * c-common.h (uint16_type_node): Rename into...
3628 (c_uint16_type_node): ...this.
3629 * c-common.c (c_common_nodes_and_builtins): Adjust for above renaming.
3630 * c-cppbuiltin.c (builtin_define_stdint_macros): Likewise.
3631
3d177e8c 36322012-04-10 Manuel López-Ibáñez <manu@gcc.gnu.org>
3633
3634 * c-common.c (warn_if_unused_value): Move definition to here.
3635 * c-common.h (warn_if_unused_value): Move declaration to here.
3636
6a9a958f 36372012-03-23 William Bader <williambader@hotmail.com>
3638
3639 * c-lex.c (c_lex_with_flags): Avoid declarations after stmts.
3640
543efdbe 36412012-03-20 Jason Merrill <jason@redhat.com>
3642
3643 * c-common.h (enum cxx_dialect): Add cxx1y.
3644 * c-common.c (c_common_nodes_and_builtins): Use >= for cxx_dialect
3645 test.
3646 * c-cppbuiltin.c (c_cpp_builtins): Likewise.
3647 * c-opts.c (c_common_post_options): Likewise.
3648 (set_std_cxx1y): New.
3649 (c_common_handle_option): Call it.
3650 * c.opt (-std=c++1y, -std=gnu++1y): New flags.
3651
62206d34 36522012-03-19 Paolo Carlini <paolo.carlini@oracle.com>
3653
3654 PR c++/14710
3655 * c.opt ([Wuseless-cast]): Add.
3656
fadf62f4 36572012-03-16 Richard Guenther <rguenther@suse.de>
3658
3659 * c-pretty-print.c (pp_c_initializer_list): Adjust.
3660
249faa35 36612012-03-15 Manuel López-Ibáñez <manu@gcc.gnu.org>
3662
3663 PR c++/44783
3664 * c.opt (ftemplate-backtrace-limit) Add.
3665
126b6848 36662012-03-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3667
3668 * c-cppbuiltin.c (c_cpp_builtins): Remove #pragma extern_prefix
3669 handling.
3670 * c-pragma.c (handle_pragma_extern_prefix): Remove.
3671 (init_pragma): Don't register extern_prefix.
3672
a51edb4c 36732012-03-12 Richard Guenther <rguenther@suse.de>
3674
3675 * c-common.c (c_common_get_narrower): Use c_common_type_for_size.
3676 (builtin_type_for_size): Likewise.
3677
0f6a7cb7 36782012-02-13 Jakub Jelinek <jakub@redhat.com>
3679
3680 PR c++/52215
3681 * c-common.c (sync_resolve_params): Don't decide whether to convert
3682 or not based on TYPE_SIZE comparison, convert whenever arg_type
3683 is unsigned INTEGER_TYPE.
3684
0779e32c 36852012-02-06 Paolo Carlini <paolo.carlini@oracle.com>
3686
3687 PR c/52118
3688 * c.opt ([Wunused-local-typedefs]): Fix description.
3689
baec58e1 36902012-01-24 Mike Stump <mikestump@comcast.net>
3691
3692 * c-common.c (c_common_type_for_mode): Match signed/unsigned types
3693 exactly.
3694
c779d8cc 36952012-01-18 Richard Guenther <rguenther@suse.de>
3696
3697 * c-opts.c (c_common_post_options): Reset LTO flags if
3698 we are about to generate a PCH.
3699
ee917d24 37002012-01-17 Paolo Carlini <paolo.carlini@oracle.com>
3701
3702 PR c++/51777
3703 * c-pretty-print.c (pp_c_integer_constant): For unsigned constants
3704 use pp_unsigned_wide_integer.
3705
90e2341f 37062012-01-10 Richard Guenther <rguenther@suse.de>
3707
3708 PR middle-end/51806
3709 * c-opts.c (c_common_handle_option): Move -Werror handling
3710 to language independent code.
3711
9ea022ce 37122012-01-05 Richard Guenther <rguenther@suse.de>
3713
3714 PR middle-end/51764
3715 * c.opt (Wmudflap, fmudflap, fmudflapth, fmudflapir): Move here
3716 from common.opt.
3717
3df19e1b 37182011-12-30 Paolo Carlini <paolo.carlini@oracle.com>
3719
3720 PR c++/51316
3721 * c-common.c (c_sizeof_or_alignof_type): In C++ allow for alignof
3722 of array types with an unknown bound.
3723
32074525 37242011-12-20 Joseph Myers <joseph@codesourcery.com>
3725
3726 * c-common.c (flag_isoc99): Update comment to refer to C11.
3727 (flag_isoc1x): Change to flag_isoc11.
3728 * c-common.h (flag_isoc99): Update comment to refer to C11.
3729 (flag_isoc1x): Change to flag_isoc11.
3730 * c-cppbuiltin.c (cpp_atomic_builtins): Change comment to refer to
3731 C11.
3732 * c-opts.c (set_std_c1x): Change to set_std_c11.
3733 (c_common_handle_option): Handle OPT_std_c11 and OPT_std_gnu11.
3734 Call set_std_c11.
3735 (set_std_c89, set_std_c99, set_std_c11): Use flag_isoc11.
3736 (set_std_c1): Use CLK_STDC11 and CLK_GNUC11.
3737 * c.opt (std=c1x): Change to std=c11. Document as non-draft
3738 standard.
3739 (std=c1x, std=iso9899:2011): Add as aliases of std=c11.
3740 (std=gnu1x): Change to std=gnu11. Refer to non-draft standard.
3741 (std=gnu1x): Make alias of std=gnu11.
3742
fca86134 37432011-12-19 Jason Merrill <jason@redhat.com>
3744
3745 PR c++/51228
3746 * c-common.c (handle_transparent_union_attribute): Check the first
3747 field if the type is complete.
3748
aa4313eb 37492011-12-15 Jonathan Wakely <jwakely.gcc@gmail.com>
3750
3751 PR libstdc++/51365
3752 * c-common.c (RID_IS_FINAL): Add.
3753 * c-common.h (RID_IS_FINAL): Add.
3754
3f3d5ad4 37552011-11-30 Iain Sandoe <iains@gcc.gnu.org>
3756
3757 * c.opt (fgnu-runtime): Provide full description.
3758 (fnext-runtime): Likewise.
3759 * c-opts.c (OPT_fgnu_runtime, OPT_fnext_runtime) Remove.
3760
c4606d19 37612011-11-28 Andrew MacLeod <amacleod@redhat.com>
3762
3763 * c-cpp-builtin.c (cpp_atomic_builtins):New. Emit all atomic
3764 predefines in one place. Add LOCK_FREE predefines.
3765 (c_cpp_builtins): Move Legacy HAVE_SYNC predefines to
3766 new func.
3767
1d581089 37682011-11-24 Andrew MacLeod <amacleod@redhat.com>
3769
3770 PR c/51256
19931eea 3771 * c-common.c (get_atomic_generic_size): Check for various error
1d581089 3772 conditions
19931eea 3773 (resolve_overloaded_atomic_exchange,
3774 resolve_overloaded_atomic_compare_exchange,
1d581089 3775 resolve_overloaded_atomic_load, resolve_overloaded_atomic_store): Return
3776 error_mark_node for error conditions.
19931eea 3777
6aa221fa 37782011-11-08 Richard Guenther <rguenther@suse.de>
3779
3780 PR middle-end/51010
3781 c-family/
3782
4c0315d0 37832011-11-07 Richard Henderson <rth@redhat.com>
3784 Aldy Hernandez <aldyh@redhat.com>
3785 Torvald Riegel <triegel@redhat.com>
3786
3787 Merged from transactional-memory.
3788
3789 * c-common.c (handle_tm_wrap_attribute,
3790 handle_tm_attribute, ignore_attribute, parse_tm_stmt_attr): New.
3791 (struct c_common_reswords): Added __transaction* keywords.
3792 (struct c_common_attribute_table): Added transaction* and tm_regparm
3793 attributes.
3794 * c-common.h: Added RID_TRANSACTION*. Added TM_ATTR* and TM_STMT*
3795 masks.
3796 (parse_tm_stmt_attr, tm_attr_to_mask, tm_mask_to_attr,
3797 find_tm_attribute): Declare.
3798
920f5a70 37992011-11-07 Jason Merrill <jason@redhat.com>
3800
3801 PR c++/35688
3802 * c-common.c, c-common.h: Revert yesterday's changes.
3803
b4f861b4 38042011-11-06 Jason Merrill <jason@redhat.com>
3805
3806 PR c++/35688
3807 * c-common.c (decl_has_visibility_attr): Split out from...
3808 (c_determine_visibility): ...here.
3809 * c-common.h: Declare it.
3810
83e25171 38112011-11-06 Joseph Myers <joseph@codesourcery.com>
3812
3813 * c-common.c (c_common_reswords): Add _Alignas and _Alignof.
3814 (c_sizeof_or_alignof_type): Diagnose alignof applied to a function
3815 type.
3816 (check_user_alignment): New. Split out of
3817 handle_aligned_attribute. Disallow integer constants with
3818 noninteger types. Conditionally allow zero.
3819 (handle_aligned_attribute): Use check_user_alignment.
3820 * c-common.h (RID_ALIGNAS, check_user_alignment): New.
3821
1cd6e20d 38222011-11-06 Andrew MacLeod <amacleod@redhat.com>
3823 Richard Henderson <rth@redhat.com>
3824
3825 Merged from cxx-mem-model.
3826
3827 * c-cppbuiltin.c (c_cpp_builtins): Test both atomic and sync patterns.
19931eea 3828 * c-common.c (sync_resolve_params, sync_resolve_return): Only tweak
1cd6e20d 3829 parameters that are the same type size.
3830 (get_atomic_generic_size): New. Find size of generic
3831 atomic function parameters and do typechecking.
3832 (add_atomic_size_parameter): New. Insert size into parameter list.
3833 (resolve_overloaded_atomic_exchange): Restructure __atomic_exchange to
3834 either __atomic_exchange_n or external library call.
19931eea 3835 (resolve_overloaded_atomic_compare_exchange): Restructure
1cd6e20d 3836 __atomic_compare_exchange to either _n variant or external library call.
19931eea 3837 (resolve_overloaded_atomic_load): Restructure __atomic_load to either
1cd6e20d 3838 __atomic_load_n or an external library call.
3839 (resolve_overloaded_atomic_store): Restructure __atomic_store to either
3840 __atomic_store_n or an external library call.
3841 (resolve_overloaded_builtin): Handle new __atomic builtins.
3842
7549df0d 38432011-11-04 Eric Botcazou <ebotcazou@adacore.com>
3844
3845 PR c++/50608
3846 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Call fold_offsetof_1.
3847 (fold_offsetof_1): Make global. Remove STOP_REF argument and adjust.
3848 <INDIRECT_REF>: Return the argument.
3849 <ARRAY_REF>: Remove special code for negative offset.
3850 Call fold_build_pointer_plus instead of size_binop.
3851 (fold_offsetof): Remove STOP_REF argument and adjust.
3852 * c-common.h (fold_offsetof_1): Declare.
3853 (fold_offsetof): Remove STOP_REF argument.
3854
7e783eb3 38552011-11-02 Paolo Carlini <paolo.carlini@oracle.com>
3856
3857 PR c++/50810
3858 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
3859 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
3860 Wnarrowing for C++0x and C++98.
3861 * c.opt ([Wnarrowing]): Update.
3862
8fe701f5 38632011-11-01 Paolo Carlini <paolo.carlini@oracle.com>
3864
3865 PR c++/44277
3866 * c.opt: Add Wzero-as-null-pointer-constant.
3867
0d84dc2d 38682011-10-31 Jason Merrill <jason@redhat.com>
3869
67031f52 3870 * c.opt (-fdeduce-init-list): Off by default.
3871
0d84dc2d 3872 PR c++/50920
3873 * c-common.h (cxx_dialect): Add cxx11 and cxx03.
3874 * c.opt: Add -std=c++11, -std=gnu++11, -std=gnu++03,
3875 and -Wc++11-compat.
3876 * c-opts.c (set_std_cxx11): Rename from set_std_cxx0x.
3877
66f24c41 38782011-10-27 Roberto Agostino Vitillo <ravitillo@lbl.gov>
3879
3880 PR c++/30066
3881 * c.opt (fvisibility-inlines-hidden): Description change.
3882
244db24d 38832011-10-26 Ed Smith-Rowland <3dw4rd@verizon.net>
3884
3885 Implement C++11 user-defined literals.
3886 * c-common.c (build_userdef_literal): New.
3887 * c-common.def: New tree code.
3888 * c-common.h (tree_userdef_literal): New tree struct and accessors.
3889 * c-lex.c (interpret_float): Add suffix parm.
3890 (c_lex_with_flags): Build literal tokens.
3891
235be70f 38922011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
3893
3894 PR c++/50841
3895 Revert:
3896 2011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
3897
3898 PR c++/50810
3899 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
3900 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
3901 Wnarrowing for C++0x and C++98.
3902 * c.opt ([Wnarrowing]): Update.
3903
4fe0fb1c 39042011-10-23 Paolo Carlini <paolo.carlini@oracle.com>
3905
3906 PR c++/50810
3907 * c-opts.c (c_common_handle_option): Enable -Wnarrowing as part
3908 of -Wall; include -Wnarrowing in -Wc++0x-compat; adjust default
3909 Wnarrowing for C++0x and C++98.
3910 * c.opt ([Wnarrowing]): Update.
3911
5f7504f9 39122011-10-21 Paolo Carlini <paolo.carlini@oracle.com>
3913
3914 PR c++/45385
3915 * c-common.c (conversion_warning): Remove code looking for
3916 artificial operands.
3917
2a688977 39182011-10-18 Dodji Seketeli <dodji@redhat.com>
3919
3920 PR bootstrap/50760
3921 * c-lex.c (fe_file_change): Use LINEMAP_SYSP when
19931eea 3922 !NO_IMPLICIT_EXTERN_C.
2a688977 3923
326e3391 39242011-10-17 Michael Spertus <mike_spertus@symantec.com>
3925
3926 * c-common.c (c_common_reswords): Add __bases,
3927 __direct_bases.
3928 * c-common.h: Add RID_BASES and RID_DIRECT_BASES.
3929
39302011-10-17 Paolo Carlini <paolo.carlini@oracle.com>
3931
3932 PR c++/50757
3933 * c.opt ([Wnonnull]): Add C++ and Objective-C++.
3934
62db153a 39352011-10-15 Tom Tromey <tromey@redhat.com>
3936 Dodji Seketeli <dodji@redhat.com>
3937
3938 * c.opt (fdebug-cpp): New option.
3939 * c-opts.c (c_common_handle_option): Handle the option.
3940 * c-ppoutput.c (maybe_print_line_1): New static function. Takes an
3941 output stream in parameter. Factorized from ...
3942 (maybe_print_line): ... this. Dump location debug information when
3943 -fdebug-cpp is in effect.
3944 (print_line_1): New static function. Takes an output stream in
3945 parameter. Factorized from ...
3946 (print_line): ... here. Dump location information when -fdebug-cpp
3947 is in effect.
3948 (scan_translation_unit): Dump location information when
3949 -fdebug-cpp is in effect.
3950
ce70f433 39512011-10-15 Tom Tromey <tromey@redhat.com>
3952 Dodji Seketeli <dodji@redhat.com>
3953
3954 * c.opt (ftrack-macro-expansion): New option. Handle it with and
3955 without argument.
3956 * c-opts.c (c_common_handle_option)<case
3957 OPT_ftrack_macro_expansion_, case OPT_ftrack_macro_expansion>: New
3958 cases. Handle -ftrack-macro-expansion with and without argument.
3959
97bfb9ef 39602011-10-15 Tom Tromey <tromey@redhat.com>
3961 Dodji Seketeli <dodji@redhat.com>
3962
3963 * c-ppoutput.c (scan_translation_unit, maybe_print_line)
3964 (print_line, cb_define, do_line_change): Adjust to avoid touching
3965 the internals of struct line_map. Use the public API instead.
3966 * c-pch.c (c_common_read_pch): Likewise.
3967 * c-lex.c (fe_file_change): Likewise.
3968
326e3391 39692011-10-14 Paolo Carlini <paolo.carlini@oracle.com>
3970
3971 PR c++/17212
3972 * c.opt ([Wformat-zero-length]): Add C++ and Objective-C++.
3973
39742011-10-11 Paolo Carlini <paolo.carlini@oracle.com>
3975
3976 PR c++/33067
3977 * c-pretty-print.c (pp_c_floating_constant): Output
3978 max_digits10 (in the ISO C++ WG N1822 sense) decimal digits.
3979
b9a16870 39802011-10-11 Michael Meissner <meissner@linux.vnet.ibm.com>
3981
3982 * c-common.c (def_builtin_1): Delete old interface with two
3983 parallel arrays to hold standard builtin declarations, and replace
3984 it with a function based interface that can support creating
3985 builtins on the fly in the future. Change all uses, and poison
3986 the old names. Make sure 0 is not a legitimate builtin index.
3987 * c-omp.c (c_finish_omp_barrier): Ditto.
3988 (c_finish_omp_taskwait): Ditto.
3989 (c_finish_omp_flush): Ditto.
3990
c7964868 39912011-10-11 Tristan Gingold <gingold@adacore.com>
3992
3993 * c.opt: (fallow-parameterless-variadic-functions): New.
3994
a4e3ffad 39952011-09-08 Dodji Seketeli <dodji@redhat.com>
3996
3997 PR c++/33255 - Support -Wunused-local-typedefs warning
3998 * c-common.h (struct c_language_function::local_typedefs): New
3999 field.
19931eea 4000 (record_locally_defined_typedef, maybe_record_typedef_use)
4001 (maybe_warn_unused_local_typedefs): Declare new functions.
a4e3ffad 4002 * c-common.c (record_locally_defined_typedef)
19931eea 4003 (maybe_record_typedef_use)
4004 (maybe_warn_unused_local_typedefs): Define new functions.
a4e3ffad 4005 * c.opt: Declare new -Wunused-local-typedefs flag.
4006
737a23cc 40072011-09-06 Eric Botcazou <ebotcazou@adacore.com>
4008
4009 PR middle-end/50266
4010 * c-common.c (c_fully_fold_internal) <ADDR_EXPR>: Fold offsetof-like
4011 computations.
4012
7542c3b4 40132011-09-05 Richard Guenther <rguenther@suse.de>
4014
4015 * c-common.c (complete_array_type): Use ssize_int (-1) instead
4016 of integer_minus_one_node for empty array upper bounds.
4017
1dc92c59 40182011-08-28 Dodji Seketeli <dodji@redhat.com>
4019
4020 * c-pch.c (c_common_read_pch): Call linemap_add with LC_ENTER as
4021 it's the first time it's being called on this main TU.
4022
2bdf2b6e 40232011-08-24 Richard Guenther <rguenther@suse.de>
4024
4025 PR c/49396
4026 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Fix conditional.
4027
40282011-08-22 Gabriel Charette <gchare@google.com>
6ea2c7a3 4029
4030 * c-opts.c (c_finish_options): Force BUILTINS_LOCATION for tokens
4031 defined in cpp_init_builtins and c_cpp_builtins.
4032
bff4ad11 40332011-08-19 Joseph Myers <joseph@codesourcery.com>
4034
4035 * c-common.c (c_common_reswords): Add __builtin_complex.
4036 * c-common.h (RID_BUILTIN_COMPLEX): New.
4037
985c6e3a 40382011-08-18 Joseph Myers <joseph@codesourcery.com>
4039
4040 * c-common.c (c_common_reswords): Add _Noreturn.
4041 (keyword_is_function_specifier): Handle RID_NORETURN.
4042 * c-common.h (RID_NORETURN): New.
4043
7dfa155b 40442011-08-10 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
4045
4046 * c-common.c (unsafe_conversion_p): New function. Check if it is
4047 unsafe to convert an expression to the type.
4048 (conversion_warning): Adjust, use unsafe_conversion_p.
4049 * c-common.h (unsafe_conversion_p): New function declaration.
4050
2169f33b 40512011-08-02 Jakub Jelinek <jakub@redhat.com>
4052
4053 * c-common.h (c_finish_omp_atomic): Adjust prototype.
4054 (c_finish_omp_taskyield): New prototype.
4055 * c-omp.c (c_finish_omp_atomic): Add OPCODE, V, LHS1 and RHS1
4056 arguments. Handle OMP_ATOMIC_READ, OMP_ATOMIC_CAPTURE_OLD and
4057 OMP_ATOMIC_CAPTURE_NEW in addition to OMP_ATOMIC. If LHS1
4058 or RHS1 have side-effects, evaluate those too in the right spot,
4059 if it is a decl and LHS is also a decl, error out if they
4060 aren't the same.
4061 (c_finish_omp_taskyield): New function.
4062 * c-cppbuiltin.c (c_cpp_builtins): Change _OPENMP to 201107.
4063 * c-pragma.c (omp_pragmas): Add taskyield.
4064 * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_TASKYIELD.
4065 (enum pragma_omp_clause): Add PRAGMA_OMP_CLAUSE_FINAL and
4066 PRAGMA_OMP_CLAUSE_MERGEABLE.
4067
ab77850e 40682011-07-25 Dodji Seketeli <dodji@redhat.com>
4069
4070 * c-common.h (set_underlying_type): Remove parm name from
4071 declaration.
4072
6ee97920 40732011-07-25 Romain Geissler <romain.geissler@gmail.com>
4074
4075 * c-pretty-print.h: Search c-common.h in c-family.
19931eea 4076
dc251364 40772011-07-22 Jason Merrill <jason@redhat.com>
4078
1a2a35f0 4079 PR c++/49793
4080 * c.opt (Wnarrowing): New.
4081
27282252 4082 PR c++/30112
4083 * c-common.h: Declare c_linkage_bindings.
4084 * c-pragma.c (handle_pragma_redefine_extname): Use it.
4085
dc251364 4086 PR c++/49813
4087 * c-opts.c (set_std_cxx0x): Set flag_isoc94 and flag_isoc99.
4088 * c-pretty-print.c (pp_c_cv_qualifiers): Check c_dialect_cxx as well
4089 as flag_isoc99 for 'restrict'.
4090 (pp_c_specifier_qualifier_list): Likewise for _Complex.
4091
fc501191 40922011-07-21 Ian Lance Taylor <iant@google.com>
4093
4094 PR middle-end/49705
4095 * c-common.c (c_disable_warnings): New static function.
4096 (c_enable_warnings): New static function.
4097 (c_fully_fold_internal): Change local unused_p to bool. Call
4098 c_disable_warnings and c_enable_warnings rather than change
4099 c_inhibit_evaluation_warnings.
4100
07b8f133 41012011-07-20 Jason Merrill <jason@redhat.com>
4102
4103 PR c++/6709 (DR 743)
4104 PR c++/42603 (DR 950)
4105 * c-common.h (CPP_KEYWORD, CPP_TEMPLATE_ID): Move from cp/parser.h.
4106 (CPP_NESTED_NAME_SPECIFIER, N_CP_TTYPES): Likewise.
4107 (CPP_DECLTYPE): New.
4108 * c-common.c (c_parse_error): Handle CPP_DECLTYPE.
4109
2cc66f2a 41102011-07-19 Richard Guenther <rguenther@suse.de>
4111
4112 * c-common.c (pointer_int_sum): Use fold_build_pointer_plus.
4113 * c-omp.c (c_finish_omp_for): Likewise.
4114
3c802a1e 41152011-07-12 Eric Botcazou <ebotcazou@adacore.com>
4116
4117 * c-ada-spec.c (dump_nested_types): Put semi-colon after empty loop
4118 body on the next line.
4119
98a33d9f 41202011-07-08 Jason Merrill <jason@redhat.com>
4121
3115bda0 4122 PR c++/45437
4123 * c-omp.c (check_omp_for_incr_expr): Handle preevaluation.
4124
98a33d9f 4125 PR c++/49673
4126 * c-common.c (c_apply_type_quals_to_decl): Don't check
4127 TYPE_NEEDS_CONSTRUCTING.
4128
c38a75b7 41292011-07-06 Richard Guenther <rguenther@suse.de>
4130
4131 * c-common.c (c_common_nodes_and_builtins):
4132 Merge calls to build_common_tree_nodes and build_common_tree_nodes_2.
4133
e593356b 41342011-07-05 Richard Guenther <rguenther@suse.de>
4135
4136 * c-common.c (c_common_nodes_and_builtins): Build all common
4137 tree nodes first.
4138
fca0886c 41392011-06-27 Jakub Jelinek <jakub@redhat.com>
4140
a68f7a8d 4141 * c-common.h (c_tree_chain_next): New static inline function.
4142
fca0886c 4143 * c-common.c (check_builtin_function_arguments): Handle
4144 BUILT_IN_ASSUME_ALIGNED.
4145
2797f13a 41462011-06-21 Andrew MacLeod <amacleod@redhat.com>
4147
4148 * c-common.c: Add sync_ or SYNC__ to builtin names.
4149 * c-omp.c: Add sync_ or SYNC__ to builtin names.
9cad95b7 4150
41512011-06-20 Pierre Vittet <piervit@pvittet.com>
4152
4153 * c-pragma.h (pragma_handler_1arg, pragma_handler_2arg): New
4154 handler.
4155 (gen_pragma_handler): New union.
4156 (internal_pragma_handler): New type.
4157 (c_register_pragma_with_data)
4158 (c_register_pragma_with_expansion_and_data): New functions.
4159
4160 * c-pragma.c (registered_pragmas, c_register_pragma_1)
4161 (c_register_pragma, c_register_pragma_with_expansion)
4162 (c_invoke_pragma_handler): Changed to work with
4163 internal_pragma_handler.
4164 (c_register_pragma_with_data)
4165 (c_register_pragma_with_expansion_and_data): New functions.
4166
218e3e4e 41672011-06-14 Joseph Myers <joseph@codesourcery.com>
4168
4169 * c-common.c: Include common/common-target.h.
4170 (handle_section_attribute): Use
4171 targetm_common.have_named_sections.
4172 * c-cppbuiltin.c: Include common/common-target.h.
4173 (c_cpp_builtins): Use targetm_common.except_unwind_info.
4174
41e53ed2 41752011-06-10 Richard Guenther <rguenther@suse.de>
4176
4177 * c-pretty-print.c (pp_c_type_specifier): Use pp_c_identifier
4178 to print a IDENTIFIER_NODE.
4179
a6f06169 41802011-06-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4181 Joseph Myers <joseph@codesourcery.com>
4182
4183 * c.opt (fbuilding-libgcc): New option.
4184 * c-cppbuiltin.c (c_cpp_builtins): Define
4185 __LIBGCC_TRAMPOLINE_SIZE__ if flag_building_libgcc.
4186
1ea9269b 41872011-06-07 Jason Merrill <jason@redhat.com>
4188
8ce59854 4189 * c-common.c (max_tinst_depth): Lower default to 900.
4190
1ea9269b 4191 * c-format.c (gcc_cxxdiag_char_table): Add 'S' format.
4192
1af0124d 41932011-06-07 Richard Guenther <rguenther@suse.de>
4194
4195 * c-common.c (c_common_nodes_and_builtins): Do not set
4196 size_type_node or call set_sizetype.
4197
0e9a4c01 41982011-06-07 Dodji Seketeli <dodji@redhat.com>
4199
4200 PR debug/49130
4201 * c-pretty-print.c (pp_c_integer_constant): Consider the canonical
19931eea 4202 type when using pointer comparison to compare types.
0e9a4c01 4203
90b40725 42042011-06-02 Jonathan Wakely <jwakely.gcc@gmail.com>
4205
4206 * c.opt: Add -Wdelete-non-virtual-dtor.
4207 * c-opts.c (c_common_handle_option): Include it in -Wall.
4208
fc9c9e87 42092011-05-30 Nathan Froyd <froydnj@gcc.gnu.org>
4210
4211 PR bootstrap/49190
4212
4213 Revert:
4214 2011-05-26 Nathan Froyd <froydnj@codesourcery.com>
4215
4216 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
4217 not tree_common.
4218
d0389adc 42192011-05-27 Jakub Jelinek <jakub@redhat.com>
4220
4221 PR c++/49165
4222 * c-common.c (c_common_truthvalue_conversion) <case COND_EXPR>: For
4223 C++ don't call c_common_truthvalue_conversion on void type arms.
4224
cacfdc02 42252011-05-27 Nathan Froyd <froydnj@codesourcery.com>
4226
4227 * c-common.h (struct stmt_tree_s) [x_cur_stmt_list]: Change to a VEC.
4228 (stmt_list_stack): Define.
4229 (cur_stmt_list): Adjust for new type of x_cur_stmt_list.
4230 * c-semantics.c (push_stmt_list, pop_stmt_list): Likewise.
4231
027fc6ef 42322011-05-26 Nathan Froyd <froydnj@codesourcery.com>
4233
4234 * c-common.c (warning_candidate_p): Check for BLOCKs.
4235
f21317a1 42362011-05-26 Nathan Froyd <froydnj@codesourcery.com>
4237
4238 * c-common.h (struct c_common_identifier): Inherit from tree_typed,
4239 not tree_common.
4240
789e953d 42412011-05-25 Jakub Jelinek <jakub@redhat.com>
4242
4243 * c-common.c (def_fn_type): Remove extra va_end.
4244
7f506bca 42452011-05-23 Jason Merrill <jason@redhat.com>
4246
4247 PR c++/48106
4248 * c-common.c (c_common_get_narrower): New.
4249 (shorten_binary_op, shorten_compare, warn_for_sign_compare): Use it.
4250
774e9d58 42512011-05-23 Nathan Froyd <froydnj@codesourcery.com>
4252
4253 * c-common.h (check_function_arguments): Tweak prototype of
4254 check_function_arguments.
4255 * c-common.c (check_function_arguments): Likewise. Adjust
4256 calls to check_function_nonnull, check_function_format, and
4257 check_function_sentinel.
4258 (check_function_sentinel): Take a FUNCTION_TYPE rather than
4259 separate attributes and typelist arguments. Use
4260 FOREACH_FUNCTION_ARGS to iterate over argument types.
4261
23407dc9 42622011-05-15 Paolo Carlini <paolo.carlini@oracle.com>
4263
4264 * c-common.c (c_common_reswords): Reorder.
4265 * c-common.h (rid): Likewise.
4266
3a939d12 42672011-05-10 Nathan Froyd <froydnj@codesourcery.com>
4268
4269 * c-common.c (def_fn_type): Don't call build_function_type, call
4270 build_function_type_array or build_varargs_function_type_array
4271 instead.
4272 (c_common_nodes_and_builtins): Likewise.
4273
b6e3dd65 42742011-05-05 Nathan Froyd <froydnj@codesourcery.com>
4275
4276 * c-common.c (c_add_case_label): Omit the loc argument to
4277 build_case_label.
4278 * c-common.h (build_case_label): Remove.
4279 * c-semantics.c (build_case_label): Remove.
4280
4232a958 42812011-05-05 Joseph Myers <joseph@codesourcery.com>
4282
4283 * c-objc.h (objc_start_method_definition): Update prototype.
4284 * stub-objc.c (objc_start_method_definition): Add extra parameter.
4285
d0af78c5 42862011-05-04 Nathan Froyd <froydnj@codesourcery.com>
4287
4288 * c-common.c (check_main_parameter_types): Reindent. Don't use
4289 TYPE_ARG_TYPES directly.
4290 (handle_nonnull_attribute): Likewise.
4291 (sync_resolve_params): Likewise.
4292 * c-format.c (handle_format_arg_attribute): Likewise. Adjust call
4293 to check_format_string.
4294 (handle_format_attribute): Likewise.
4295 (check_format_string): Take a function type to examine instead of
4296 a type list. Use a function_arg_iterator to step through argument
4297 types.
4298
ceb7b692 42992011-05-04 Richard Guenther <rguenther@suse.de>
4300
4301 * c-common.c (fix_string_type): Use size_int for index type bounds.
4302 (start_fname_decls): Do not pass NULL to build_int_cst.
4303 (c_init_attributes): Likewise.
4304 * c-lex.c (c_lex_with_flags): Likewise.
4305
c66c81be 43062011-04-27 Jason Merrill <jason@redhat.com>
4307
4308 * c-common.c (make_tree_vector_from_list): New.
4309 * c-common.h: Declare it.
4310
16930c72 43112011-04-26 Richard Guenther <rguenther@suse.de>
4312
4313 PR preprocessor/48248
4314 * c-ppoutput.c (maybe_print_line): Always optimize newlines
4315 for output size with -P.
4316
23407dc9 43172011-04-25 Paolo Carlini <paolo.carlini@oracle.com>
4318
4319 * c-common.c (struct c_common_resword): Add __underlying_type.
4320 * c-common.h (enum rid): Add RID_UNDERLYING_TYPE.
4321
dd045aee 43222011-04-20 Jim Meyering <meyering@redhat.com>
4323
4324 * c-format.c (init_dollar_format_checking): Remove useless
4325 if-before-free.
4326
394dd737 43272011-04-15 Nicola Pero <nicola.pero@meta-innovation.com>
4328
4329 * c-objc.h (objc_get_interface_ivars): Removed.
23407dc9 4330 (objc_detect_field_duplicates): New.
394dd737 4331 * stub-objc.c: Likewise.
23407dc9 4332
a758bf7d 43332011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
4334
4335 * stub-objc.c (objc_declare_protocols): Renamed to
4336 objc_declare_protocol.
4337 * c-objc.h: Likewise.
23407dc9 4338
29d7200d 43392011-04-14 Nicola Pero <nicola.pero@meta-innovation.com>
4340
4341 * stub-objc.c (objc_declare_class): Updated argument name.
4342
9b88d08d 43432011-04-12 Nathan Froyd <froydnj@codesourcery.com>
4344
4345 * c-common.h (c_common_init_ts): Declare.
4346 * c-common.c (c_common_init_ts): Define.
4347
4185cf58 43482011-04-12 Nicola Pero <nicola.pero@meta-innovation.com>
4349
4350 * c-objc.h (objc_build_message_expr): Updated prototype.
4351 * stub-objc.c (objc_build_message_expr): Likewise.
19931eea 4352
5a90471f 43532011-04-12 Martin Jambor <mjambor@suse.cz>
4354
4355 * c-gimplify.c (c_genericize): Call cgraph_get_create_node instead
4356 of cgraph_node.
4357
783bb57e 43582011-04-11 Richard Guenther <rguenther@suse.de>
4359
4360 * c-common.c (complete_array_type): Build a range type of
4361 proper type.
4362
c33080b9 43632011-04-08 Nathan Froyd <froydnj@codesourcery.com>
4364
4365 * c-common.c (handle_sentinel_attribute): Don't use TYPE_ARG_TYPES.
4366 (handle_type_generic_attribute): Likewise.
4367
f8913d47 43682011-04-07 Jason Merrill <jason@redhat.com>
4369
4370 PR c++/48450
4371 * c-common.c (c_common_truthvalue_conversion): Don't ignore
4372 conversion from C++0x scoped enum.
4373
c94b1d0e 43742011-04-06 Joseph Myers <joseph@codesourcery.com>
4375
4376 * c-target-def.h: New file.
4377 * c-target.def: New file.
4378 * c-target.h: New file.
4379 * c-common.c (targetcm): Don't define here.
4380 * c-common.h (default_handle_c_option): Declare.
4381 * c-format.c: Include c-target.h instead of target.h.
4382 * c-opts.c: Include c-target.h instead of target.h. Explicitly
4383 include tm.h.
4384 (default_handle_c_option): Move from targhooks.c.
4385
acb10f41 43862011-03-29 Jakub Jelinek <jakub@redhat.com>
4387
4388 PR preprocessor/48248
4389 * c-ppoutput.c (print): Add src_file field.
4390 (init_pp_output): Initialize it.
4391 (maybe_print_line): Don't optimize by adding up to 8 newlines
4392 if map->to_file and print.src_file are different file.
4393 (print_line): Update print.src_file.
4394
82715bcd 43952011-03-25 Kai Tietz <ktietz@redhat.com>
4396
4397 * c-ada-spec.c (compare_comment): Use filename_cmp
4398 instead of strcmp for filename.
4399
451c8e2f 44002011-03-25 Jeff Law <law@redhat.com>
4401
1f78217c 4402 * c-common.c (def_fn_type): Add missing va_end.
451c8e2f 4403
3c47771c 44042011-03-25 Jason Merrill <jason@redhat.com>
4405
4406 * c.opt: Add -std=c++03.
4407
97e6200f 44082011-03-22 Eric Botcazou <ebotcazou@adacore.com>
4409
4410 * c-ada-spec.c (dump_ada_template): Skip non-class instances.
4411
ac86af5d 44122011-03-17 Kai Tietz
4413
4414 PR target/12171
ee212425 4415 * c-pretty-print.c (pp_c_specifier_qualifier_list):
4416 Display allowed attributes for function pointer types.
4417 (pp_c_attributes_display): New function to display
4418 attributes having affects_type_identity flag set to true.
4419 * c-pretty-print.h (pp_c_attributes_display): New prototype.
4420
ac86af5d 4421 * c-common.c (c_common_attribute_table):
4422 Add new element.
4423 (c_common_format_attribute_table): Likewise.
4424
914d1151 44252011-03-18 Jason Merrill <jason@redhat.com>
4426
69788bdf 4427 * c.opt (fconstexpr-depth): Add Var(max_constexpr_depth).
4428 * c-common.h: Don't declare it here.
4429 * c-common.c: Or define it here.
4430 * c-opts.c (c_common_handle_option): Or set it here.
4431
914d1151 4432 PR c++/35315
4433 * c-common.c (handle_transparent_union_attribute): Don't
4434 make a duplicate type in C++.
4435
54cf6eed 44362011-03-15 Jason Merrill <jason@redhat.com>
4437
4438 * c-common.c (max_constexpr_depth): New.
4439 * c-common.h: Declare it.
4440 * c-opts.c (c_common_handle_option): Set it.
4441 * c.opt (fconstexpr-depth): New option.
4442
02cb1060 44432011-03-11 Jason Merrill <jason@redhat.com>
4444
9bf1c74e 4445 * c-common.c (attribute_takes_identifier_p): Add missing const.
4446
02cb1060 4447 PR c++/46803
4448 * c-common.c (attribute_takes_identifier_p): Assume that an
4449 unknown attribute takes an identifier.
4450
ecf2703d 44512011-03-07 Nathan Froyd <froydnj@codesourcery.com>
4452
4453 PR c/47786
4454 * c-common.c (c_type_hash): Call list_length instead of iterating
4455 through DECL_CHAIN. Rename 'i' to 'n_elements'.
4456
2b19dfe4 44572011-02-19 Jakub Jelinek <jakub@redhat.com>
4458
4459 PR c/47809
4460 * c-common.c (c_fully_fold_internal): Handle VIEW_CONVERT_EXPR.
4461
29cf2335 44622011-02-17 Iain Sandoe <iains@gcc.gnu.org>
4463
4464 * c.opt (fobjc-abi-version=) New.
4465 (fobjc-nilcheck): New.
4466
fad3f658 44672011-02-03 Nathan Froyd <froydnj@codesourcery.com>
4468
4469 PR c++/46890
4470 * c-common.h (keyword_is_decl_specifier): Declare.
4471 * c-common.c (keyword_is_decl_specifier): Define.
4472 (keyword_is_function_specifier): New function.
4473
a12319b3 44742011-01-26 Jakub Jelinek <jakub@redhat.com>
4475
4476 PR c/47473
4477 * c-lex.c (interpret_float): If CPP_N_IMAGINARY, ensure
4478 EXCESS_PRECISION_EXPR is created with COMPLEX_TYPE instead of
4479 REAL_TYPE.
4480
5c128dc8 44812011-01-26 Arnaud Charlet <charlet@adacore.com>
4482
4483 * c-ada-spec.c (dump_generic_ada_node): Avoid dereferencing null type.
4484
8d67b0c7 44852011-01-26 Jakub Jelinek <jakub@redhat.com>
4486
4487 PR pch/47430
4488 * c-opts.c (c_common_post_options): Call c_common_no_more_pch
4489 after init_c_lex if pch_file is set.
4490
0675168d 44912011-01-26 Dave Korn <dave.korn.cygwin@gmail.com>
4492
e8911163 4493 PR c++/43601
0675168d 4494 * c.opt (-fkeep-inline-dllexport): New switch.
4495
0725e25c 44962011-01-12 Richard Guenther <rguenther@suse.de>
4497
4498 PR middle-end/32511
4499 * c-common.c (handle_weak_attribute): Warn instead of error
4500 on declaring an inline function weak.
4501
fdd84b77 45022011-01-05 Tom Tromey <tromey@redhat.com>
4503
4504 * c-common.h (lvalue_error): Update.
4505 * c-common.c (lvalue_error): Add 'loc' argument. Call error_at,
4506 not error.
4507
e6e73d14 45082010-12-29 Nicola Pero <nicola.pero@meta-innovation.com>
19931eea 4509
d67e8485 4510 PR objc/47075
4511 * c-objc.h (objc_finish_message_expr): Added argument to
4512 prototype.
4513
a36cf284 45142010-12-22 Nathan Froyd <froydnj@codesourcery.com>
4515
4516 * c-common.c (handle_nonnull_attribute, handle_sentinel_attribute):
4517 Use prototype_p.
4518
33b3681f 45192010-12-18 Nicola Pero <nicola.pero@meta-innovation.com>
4520
4521 * c-objc.h (objc_maybe_warn_exceptions): New.
19931eea 4522 * stub-objc.c (objc_maybe_warn_exceptions): New.
33b3681f 4523
a1f90215 45242010-12-10 Nathan Froyd <froydnj@codesourcery.com>
4525
4526 * c-common.h (readonly_error): Declare.
4527 * c-common.c (readonly_error): Define.
4528
b1bbc8e5 45292010-12-09 Nathan Froyd <froydnj@codesourcery.com>
4530
4531 * c-common.h (invalid_indirection_error): Declare.
4532 * c-common.c (invalid_indirection_error): Define.
4533
b0d55af9 45342010-12-03 Richard Guenther <rguenther@suse.de>
4535
4536 PR c/46745
4537 * c-pretty-print.c (pp_c_postfix_expression): Handle MEM_REF.
4538 (pp_c_unary_expression): Likewise.
4539 (pp_c_expression): Likewise.
4540
d7489d8d 45412010-11-30 Nicola Pero <nicola.pero@meta-innovation.com>
4542
4543 * c-common.h (objc_finish_function): New.
4544 (objc_non_volatilized_type): Removed.
4545 (objc_type_quals_match): Removed.
4546 * stub-objc.c (objc_finish_function): New.
4547 (objc_non_volatilized_type): Removed.
4548 (objc_type_quals_match): Removed.
19931eea 4549
92468061 45502010-11-30 Joseph Myers <joseph@codesourcery.com>
4551
4552 * c-common.h (parse_optimize_options): Declare.
4553 * c-cppbuiltin.c, c-format.c, c-gimplify.c, c-lex.c, c-omp.c,
4554 c-pch.c, c-pragma.c, c-semantics.c: Don't include toplev.h.
4555
967958e4 45562010-11-29 Joseph Myers <joseph@codesourcery.com>
4557
4558 * c-opts.c (check_deps_environment_vars): Use getenv instead of
4559 GET_ENVIRONMENT.
4560 * c-pch.c (O_BINARY): Don't define here.
4561 * c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
4562
b213bf24 45632010-11-25 Joseph Myers <joseph@codesourcery.com>
4564
4565 * c-cppbuiltin.c (c_cpp_builtins): Pass &global_options to
4566 targetm.except_unwind_info.
4567
9faf44d6 45682010-11-23 Joseph Myers <joseph@codesourcery.com>
4569
4570 * c-opts.c (c_common_handle_option): Pass location to
4571 set_struct_debug_option.
4572
79396169 45732010-11-23 Joseph Myers <joseph@codesourcery.com>
4574
4575 * c-common.c (visibility_options): Move from ../opts.c.
4576 * c-common.h (struct visibility_flags, visibility_options):
4577 Declare here.
4578 * c-opts.c (finish_options): Rename to c_finish_options.
4579 (c_common_init): Update call to finish_options.
4580
b4aa4123 45812010-11-22 Nicola Pero <nicola.pero@meta-innovation.com>
4582
4583 PR objc/34033
4584 * c-lex.c (lex_string): Check that each string in an Objective-C
4585 string concat sequence starts with either one or zero '@', and
4586 that there are no spurious '@' signs at the end.
4587
3e0e49f2 45882010-11-20 Joseph Myers <joseph@codesourcery.com>
4589
4590 * c-pragma.c: Remove conditionals on HANDLE_PRAGMA_PACK,
4591 HANDLE_PRAGMA_PACK_PUSH_POP, HANDLE_PRAGMA_WEAK and
4592 HANDLE_PRAGMA_VISIBILITY.
4593 * c-pragma.h (HANDLE_PRAGMA_WEAK, HANDLE_PRAGMA_PACK,
4594 HANDLE_PRAGMA_VISIBILITY): Don't define.
4595 (HANDLE_SYSV_PRAGMA, HANDLE_PRAGMA_PACK_PUSH_POP): Don't test.
4596
a9ffdd35 45972010-11-20 Nathan Froyd <froydnj@codesourcery.com>
4598
4599 PR c++/16189
4600 PR c++/36888
4601 PR c++/45331
4602 * c-common.h (keyword_begins_type_specifier): Declare.
4603 (keyword_is_storage_class_specifier): Declare.
4604 (keyword_is_type_qualifier): Declare.
4605 * c-common.c (keyword_begins_type_specifier): New function.
4606 (keyword_is_storage_class_specifier): New function.
4607 (keyword_is_type_qualifier): Declare.
4608
93be21c0 46092010-11-19 Joseph Myers <joseph@codesourcery.com>
4610
4611 PR c/46547
4612 * c-common.c (in_late_binary_op): Define.
4613 (c_common_truthvalue_conversion): Check in_late_binary_op before
4614 calling c_save_expr.
4615 * c-common.h (in_late_binary_op): Declare.
4616
d7175aef 46172010-11-19 Joseph Myers <joseph@codesourcery.com>
4618
4619 * c-opts.c (c_common_handle_option): Update calls to
4620 set_struct_debug_option.
4621
c213e196 46222010-11-19 Nicola Pero <nicola.pero@meta-innovation.com>
4623
4624 * c-common.h (objc_declare_protocols): Added additional argument.
4625 * stub-objc.c (objc_declare_protocol): Same change.
19931eea 4626
0b5fc5d6 46272010-11-18 Nathan Froyd <froydnj@codesourcery.com>
4628
4629 PR c/33193
4630 * c-common.h (build_real_imag_expr): Declare.
4631 * c-semantics.c (build_real_imag_expr): Define.
4632
b8ba44e7 46332010-11-17 Joseph Myers <joseph@codesourcery.com>
4634
4635 * c-opts.c (c_common_parse_file): Take no arguments.
4636 * c-common.h (c_common_parse_file): Update prototype.
4637
6ef8d12f 46382010-11-16 Jakub Jelinek <jakub@redhat.com>
4639
4640 PR c++/46401
4641 * c-common.c (warning_candidate_p): Don't track non-const calls
4642 or STRING_CSTs.
4643
929d2a90 46442010-11-15 Ian Lance Taylor <iant@google.com>
4645
4646 * c-lex.c (init_c_lex): Set macro debug callbacks if
4647 flag_dump_go_spec is set.
4648
e4a7640a 46492010-11-15 Nicola Pero <nicola.pero@meta-innovation.com>
4650
4651 * c-common.h (objc_build_incr_expr_for_property_ref): New.
4652 * stub-objc.c (objc_build_incr_expr_for_property_ref): New.
4653
597d2d81 46542010-11-15 Nathan Froyd <froydnj@codesourcery.com>
4655
4656 PR preprocessor/45038
4657 * c-cppbuiltin.c (c_cpp_builtins): Use different format for C++
4658 dialects.
4659
c123f04d 46602010-11-12 Joseph Myers <joseph@codesourcery.com>
4661
4662 * c-common.h (c_family_lang_mask): Declare.
4663 * c-opts.c (c_family_lang_mask): Make extern.
4664 * c-pragma.c (handle_pragma_diagnostic): Use
4665 control_warning_option.
4666
3c6c0e40 46672010-11-12 Joseph Myers <joseph@codesourcery.com>
4668
4669 * c-common.c (parse_optimize_options): Update call to
4670 decode_options.
4671 * c-common.h (c_common_handle_option): Update prototype.
4672 * c-opts.c (c_common_handle_option): Take location_t parameter and
4673 pass it to other functions.
4674
19ec5c9e 46752010-11-11 Joseph Myers <joseph@codesourcery.com>
4676
4677 * c-opts.c (warning_as_error_callback): Remove.
4678 (c_common_initialize_diagnostics): Don't call
4679 register_warning_as_error_callback.
4680 (c_common_handle_option): Handle -Werror=normalized= here.
4681
bf776685 46822010-11-10 Joseph Myers <joseph@codesourcery.com>
4683
4684 * c-common.c (handle_mode_attribute): Use %' and word "signedness"
4685 in diagnostic.
4686 * c-opts.c (c_common_parse_file): Start diagnostics with lowercase
4687 letter.
4688 * c-pragma.c (handle_pragma_target, handle_pragma_optimize):
4689 Remove trailing '.' from diagnostics.
4690 * c.opt (Wwrite-strings_: Avoid '`' in help text.
4691
6bd9d862 46922010-11-10 Joseph Myers <joseph@codesourcery.com>
4693
4694 * c-common.c (parse_optimize_options): Pass global_dc to
4695 decode_options.
4696 * c-opts.c (c_common_handle_option): Pass &global_options to
4697 set_Wstrict_aliasing.
4698 * c.opt (v): Don't mark Common or document here.
4699
1f6616ee 47002010-11-06 Iain Sandoe <iains@gcc.gnu.org>
4701
4702 PR target/44981
4703 * c-format.c (format_type): New type gcc_objc_string_format_type.
4704 (valid_stringptr_type_p): New.
4705 (handle_format_arg_attribute): Use valid_stringptr_type_p ().
19931eea 4706 (check_format_string): Pass expected type, use
1f6616ee 4707 valid_stringptr_type_p (), check that the format string types are
4708 consistent with the format specification.
4709 (decode_format_attr): Warn if NSString is used outside objective-c.
4710 (format_types_orig): Add NSString.
4711 (format_name): New.
4712 (format_flags): New.
4713 (check_format_arg): Handle format strings requiring an external parser.
4714 first_target_format_type: New variable.
4715 (handle_format_attribute): Set up first_target_format_type, pass the
4716 expected format arg string type to check_format_string().
4717 * c-common.h (FMT_FLAG_PARSE_ARG_CONVERT_EXTERNAL): New flag.
4718 * stub-objc.c (objc_string_ref_type_p): New.
4719 (objc_check_format_arg): New.
4720
b0d0931f 47212010-11-04 Nicola Pero <nicola.pero@meta-innovation.com>
4722
19931eea 4723 Fixed using the Objective-C 2.0 dot-syntax with class names.
b0d0931f 4724 * c-common.h (objc_build_class_component_ref): New.
4725 * stub-objc.c (objc_build_class_component_ref): New.
4726
f26877d5 47272010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
4728
4729 * c.opt (Wproperty-assign-default): New option.
4730
1ef143b6 47312010-11-03 Nicola Pero <nicola.pero@meta-innovation.com>
4732
4733 Implemented -fobjc-std=objc1 flag.
4734 * c.opt (fobjc-std=objc1): New option.
4735
8c582e4f 47362010-11-01 Nicola Pero <nicola.pero@meta-innovation.com>
4737
4738 Implemented format and noreturn attributes for Objective-C methods.
4739 * c-common.c (handle_noreturn_attribute): Recognize 'noreturn'
4740 attribute for Objective-C methods.
4741
8637f1db 47422010-10-31 Jason Merrill <jason@redhat.com>
4743
4744 * c-common.c (conversion_warning, warn_for_collisions_1): Use
4745 EXPR_LOC_OR_HERE.
4746
9d9f5bb3 47472010-10-30 Nicola Pero <nicola.pero@meta-innovation.com>
4748
4749 Implemented Objective-C 2.0 @property, @synthesize and @dynamic.
4750 * c-common.h (enum rid): Removed RID_COPIES and RID_IVAR.
4751 (objc_add_property_declaration): Removed arguments for copies and
4752 ivar.
4753 (objc_build_getter_call): Renamed to
4754 objc_maybe_build_component_ref.
4755 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
4756 (objc_is_property_ref): New.
4757 * c-common.c (c_common_reswords): Removed copies and ivar.
4758 * stub-objc.c (objc_add_property_declaration): Removed arguments
4759 for copies and ivar.
4760 (objc_build_getter_call): Renamed to
4761 objc_maybe_build_component_ref.
4762 (objc_build_setter_call): Renamed to objc_maybe_build_modify_expr.
4763 (objc_is_property_ref): New.
19931eea 4764
56f907a0 47652010-10-29 Arnaud Charlet <charlet@adacore.com>
4766 Matthew Gingell <gingell@adacore.com>
4767
4768 * c-ada-spec.c (separate_class_package): New function.
4769 (pp_ada_tree_identifier): Prefix references to C++ classes with the
4770 name of their enclosing package.
4771 (print_ada_declaration): Use separate_class_package.
4772
b5fa273e 47732010-10-27 Jason Merrill <jason@redhat.com>
4774
5290e253 4775 * c-common.c (c_common_reswords): Add __is_literal_type.
4776 * c-common.h (enum rid): Add RID_IS_LITERAL_TYPE.
4777
b5fa273e 4778 * c-common.c (check_case_value): Remove special C++ code.
4779
7590f0e5 47802010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
4781
4782 * c-common.h (enum rid): Added RID_READWRITE, RID_ASSIGN,
4783 RID_RETAIN, RID_COPY and RID_NONATOMIC. Updated RID_FIRST_PATTR
4784 and RID_LAST_PATTR.
4785 (objc_add_property_declaration): Added additional arguments.
4786 (objc_property_attribute_kind): Removed.
4787 (objc_set_property_attr): Removed.
4788 * c-common.c (c_common_reswords): Added readwrite, assign, retain,
4789 copy and nonatomic.
4790 * stub-objc.c (objc_add_property_declaration): Added additional
4791 arguments.
4792 (objc_set_property_attr): Removed.
19931eea 4793
1d894bcf 47942010-10-27 Nicola Pero <nicola.pero@meta-innovation.com>
4795
4796 * c-common.h (objc_add_property_variable): Renamed to
4797 objc_add_property_declaration. Added location argument.
4798 * stub-objc.c (objc_add_property_variable): Same change.
4799
e23bf1fb 48002010-10-23 Nicola Pero <nicola.pero@meta-innovation.com>
4801
4802 * c-common.h (objc_maybe_printable_name): New.
4803 * stub-objc.c (objc_maybe_printable_name): New.
4804
93426222 48052010-10-22 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
4806 Andrew Pinski <pinskia@gmail.com>
4807
4808 * c-common.h (c_common_mark_addressable_vec): Declare.
4809 * c-common.c (c_common_mark_addressable_vec): New function.
4810
45b2b110 48112010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
4812
4813 * c-common.h (objc_set_method_type): Removed.
4814 (objc_add_method_declaration): Added boolean argument.
4815 (objc_start_method_definition): Same change.
4816 (objc_build_method_signature): Same change.
4817 * stub-objc.c (objc_set_method_type): Removed.
4818 (objc_add_method_declaration): Added boolean argument.
4819 (objc_start_method_definition): Same change.
4820 (objc_build_method_signature): Same change.
4821
64cd9619 48222010-10-20 Nicola Pero <nicola.pero@meta-innovation.com>
4823
4824 * c-common.h (finish_file): Removed.
4825 (objc_write_global_declarations): New.
4826 * c-opts.c (c_common_parse_file): Do not call finish_file.
4827 * stub-objc.c (objc_write_global_declarations): New.
19931eea 4828
e1f293c0 48292010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
4830
4831 Implemented parsing @synthesize and @dynamic for
4832 Objective-C/Objective-C++.
4833 * c-common.h (enum rid): Add RID_AT_SYNTHESIZE and RID_AT_DYNAMIC.
4834 (objc_add_synthesize_declaration): New.
4835 (objc_add_dynamic_declaration): New.
4836 * c-common.c (c_common_reswords): Add synthesize and dynamic.
4837 * stub-objc.c (objc_add_synthesize_declaration): New.
4838 (objc_add_dynamic_declaration): New.
19931eea 4839
ef97a312 48402010-10-18 Michael Meissner <meissner@linux.vnet.ibm.com>
4841
4842 PR target/46041
4843 * c-cppbuiltin.c (mode_has_fma): Move function here from
4844 builtins.c. Don't use the fma optab, instead just use the
4845 HAVE_fma* macros, so that __FP_FAST_FMA* will be defined when
4846 using -save-temps.
4847
69b07042 48482010-10-18 Nicola Pero <nicola.pero@meta-innovation.com>
4849
4850 Merge from 'apple/trunk' branch on FSF servers.
ef97a312 4851
69b07042 4852 2005-11-08 Fariborz Jahanian <fjahanian@apple.com>
4853
19931eea 4854 Radar 4330422
69b07042 4855 * c-common.h (objc_non_volatilized_type): New declaration
4856 * stub-objc.c (objc_non_volatilized_type): New stub.
4857
f15f2e56 48582010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
4859
69b07042 4860 Merge from 'apple/trunk' branch on FSF servers.
f15f2e56 4861
4862 2006-03-27 Fariborz Jahanian <fjahanian@apple.com>
4863
19931eea 4864 Radar 4133425
f15f2e56 4865 * c-common.h (objc_diagnose_private_ivar): New decl.
ef97a312 4866 * stub-objc.c (objc_diagnose_private_ivar): New stub.
f15f2e56 4867
4a8875ed 48682010-10-17 Iain Sandoe <iains@gcc.gnu.org>
4869
4870 * c-common.c (c_common_reswords): Add package, RID_AT_PACKAGE.
4871 * c-common.h (enum rid): Add RID_AT_PACKAGE.
4872 (objc_ivar_visibility_kind): New enum.
4873 (objc_set_visibility): Adjust prototype to use visibility enum.
ef97a312 4874 * stub-objc.c (objc_set_visibility): Adjust stub to use
4a8875ed 4875 visibility enum.
4876
7e0713b1 48772010-10-14 Michael Meissner <meissner@linux.vnet.ibm.com>
4878
4879 * c-cppbuiltin.c (builtin_define_float_constants): Emit
4880 __FP_FAST_FMA, __FP_FAST_FMAF, and __FP_FAST_FMAL if the machine
4881 has the appropriate fma builtins.
4882 (c_cpp_builtins): Adjust call to builtin_define_float_constants.
4883
86c110ac 48842010-10-14 Iain Sandoe <iains@gcc.gnu.org>
4885
7e0713b1 4886 merge from FSF apple 'trunk' branch.
86c110ac 4887 2006 Fariborz Jahanian <fjahanian@apple.com>
7e0713b1 4888
86c110ac 4889 Radars 4436866, 4505126, 4506903, 4517826
4890 * c-common.c (c_common_resword): Define @property and its attributes.
4891 * c-common.h: Define property attribute enum entries.
4892 (OBJC_IS_PATTR_KEYWORD): New.
4893 (objc_property_attribute_kind): New enum.
4894 Declare objc_set_property_attr (), objc_add_property_variable (),
4895 objc_build_getter_call () and objc_build_setter_call ().
4896 * stub-objc.c (objc_set_property_attr): New stub.
4897 (objc_add_property_variable): Likewise.
4898 (objc_build_getter_call): Likewise.
4899 (objc_build_setter_call) Likewise.
7e0713b1 4900
40c8d1dd 49012010-10-13 Iain Sandoe <iains@gcc.gnu.org>
4902
7e0713b1 4903 merge from FSF apple 'trunk' branch.
40c8d1dd 4904 2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
4905
4906 Radar 3803157 (method attributes)
4907 * c-common.c (handle_deprecated_attribute): Recognize
4908 objc methods as valid declarations.
4909 * c-common.h: Declare objc_method_decl ().
7e0713b1 4910 * stub-objc.c (objc_method_decl): New stub.
40c8d1dd 4911
f3f006ad 49122010-10-08 Joseph Myers <joseph@codesourcery.com>
4913
4914 * c-common.c (parse_optimize_options): Call
4915 decode_cmdline_options_to_array_default_mask before
4916 decode_options. Update arguments to decode_options.
4917 * c-common.h (c_common_init_options_struct): Declare.
4918 * c-opts.c (c_common_init_options_struct): New. Split out from
4919 c_common_init_options.
4920
0a65c3bb 49212010-10-06 Nicola Pero <nicola.pero@meta-innovation.com>
4922
4923 Implemented fast enumeration for Objective-C.
4924 * c-common.h (objc_finish_foreach_loop): New.
4925 * stub-objc.c (objc_finish_foreach_loop): New.
4926
24ca3b4e 49272010-10-05 Joseph Myers <joseph@codesourcery.com>
4928
4929 * c-common.h (struct diagnostic_context): Don't declare here.
4930 (c_common_initialize_diagnostics): Declare using
4931 diagnostic_context typedef.
4932 * c-opts.c (c_common_handle_option): Pass global_dc to
4933 handle_generated_option.
4934
f83b64ca 49352010-10-04 Joseph Myers <joseph@codesourcery.com>
4936
4937 * c-opts.c (c_common_handle_option): Pass &global_options_set to
4938 handle_generated_option.
4939
2fdec027 49402010-10-03 Ian Lance Taylor <iant@google.com>
4941
4942 * c.opt (-fplan9-extensions): New option.
4943
41acdfa4 49442010-10-03 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
4945
4946 * c-cppbuiltin.c (define__GNUC__, builtin_define_type_precision):
4947 Remove.
4948 (c_cpp_builtins): Call functions from cppbuiltin.c instead
4949 of duplicating code.
4950
069761fb 49512010-09-30 Iain Sandoe <iains@gcc.gnu.org>
4952
4953 * c-common.c: Add two new entries for @optional
4954 and @required keywords.
4955
4956 merge from FSF 'apple/trunk' branch.
4957 2006-01-30 Fariborz Jahanian <fjahanian@apple.com>
4958
4959 Radar 4386773
4960 * c-common.h (RID_AT_OPTIONAL, RID_AT_REQUIRED): Two new
4961 objective-c keywords.
4962 (objc_set_method_opt): New declaration.
4963 * stub-objc.c (objc_set_method_opt): New stub.
19931eea 4964
2c5d2e39 49652010-09-30 Joseph Myers <joseph@codesourcery.com>
4966
4967 * c-common.c (handle_optimize_attribute): Pass &global_options to
4968 cl_optimization_save and cl_optimization_restore.
4969 * c-opts.c (c_common_handle_option): Pass &global_options to
4970 handle_generated_option.
4971 * c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
4972 (handle_pragma_pop_options, handle_pragma_reset_options): Pass
4973 &global_options to cl_optimization_restore.
4974
e5c75ac3 49752010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
4976
4977 * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME
4978 Objective-C/Objective-C++ keywords.
4979
3511333e 49802010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
e147d6aa 4981
19931eea 4982 Merge from 'apple/trunk' branch on FSF servers.
4983
e147d6aa 4984 2005-10-04 Fariborz Jahanian <fjahanian@apple.com>
4985
4986 Radar 4281748
4987 * c-common.h (objc_check_global_decl): New declaration.
4988 * stub-objc.c (objc_check_global_decl): New stub.
4989
5461e683 49902010-09-29 Joseph Myers <joseph@codesourcery.com>
4991
4992 * c.opt: Don't use VarExists.
4993
5ae82d58 49942010-09-29 Joseph Myers <joseph@codesourcery.com>
4995
4996 * c-common.c (c_cpp_error): Update names of diagnostic_context
4997 members.
4998 * c-cppbuiltin.c (c_cpp_builtins_optimize_pragma): Update names of
4999 cl_optimization members.
5000 * c-opts.c (warning_as_error_callback, c_common_handle_option,
5001 sanitize_cpp_opts, finish_options): Update names of cpp_options
5002 members.
5003
b27e241e 50042010-09-29 Nicola Pero <nicola.pero@meta-innovation.com>
5005
5006 * c-common.h (OBJC_IS_CXX_KEYWORD): New macro. Updated comments.
5007 (objc_is_reserved_word): Removed.
5008 * c-common.c: Updated comments.
5009 * c-lex.c (c_lex_with_flags): Use OBJC_IS_CXX_KEYWORD instead of
5010 objc_is_reserved_word.
5011 * stub-objc.c (objc_is_reserved_word): Removed.
5012
03fc2271 50132010-09-28 Iain Sandoe <iains@gcc.gnu.org>
5014
19931eea 5015 * c-common.h (objc_add_method_declaration): Adjust prototype to
03fc2271 5016 include attributes.
5017 (objc_start_method_definition): Likewise.
5018 (objc_build_keyword_decl): Likewise.
5019 * stub-objc.c:(objc_add_method_declaration): Handle attributes.
5020 (objc_start_method_definition): Likewise.
5021 (objc_build_keyword_decl): Likewise.
5022
a336eb4b 50232010-09-28 Iain Sandoe <iains@gcc.gnu.org>
5024
5025 * c-common.h (objc_start_class_interface): Adjust prototype.
5026 (objc_start_category_interface): Likewise.
5027 (objc_start_protocol): Likewise.
5028 * stub-objc.c (objc_start_protocol): Adjust for extra argument.
5029 (objc_start_class_interface): Likewise.
5030 (objc_start_category_interface): Likewise.
5031
48b14f50 50322010-09-27 Ian Lance Taylor <iant@google.com>
5033
5034 * c-common.c (c_common_attribute_table): Add no_split_stack.
5035 (handle_no_split_stack_attribute): New static function.
5036
4abfc532 50372010-09-27 Nicola Pero <nicola.pero@meta-innovation.com>
5038
19931eea 5039 Merge from 'apple/trunk' branch on FSF servers.
4abfc532 5040
5041 2005-12-15 Fariborz Jahanian <fjahanian@apple.com>
5042
19931eea 5043 Radar 4229905
4abfc532 5044 * c-common.h (objc_have_common_type): New declaration.
5045 * stub-objc.c (objc_have_common_type): New stub.
5046
5047 2005-06-22 Ziemowit Laski <zlaski@apple.com>
5048
5049 Radar 4154928
5050 * c-common.h (objc_common_type): New prototype.
19931eea 5051 * stub-objc.c (objc_common_type): New stub.
4abfc532 5052
7bd95dfd 50532010-09-24 Jan Hubicka <jh@suse.cz>
5054
5055 * c-common.c (handle_leaf_attribute): New function.
5056 (struct attribute_spec c_common_att): Add leaf.
5057
5789e05b 50582010-09-22 Joseph Myers <joseph@codesourcery.com>
5059
5060 * c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
5061 -comments-in-macros, -define-macro, -define-macro=, -dependencies,
5062 -dump, -dump=, -imacros, -imacros=, -include, -include=,
5063 -include-barrier, -include-directory, -include-directory=,
5064 -include-directory-after, -include-directory-after=,
5065 -include-prefix, -include-prefix=, -include-with-prefix,
5066 -include-with-prefix=, -include-with-prefix-after,
5067 -include-with-prefix-after=, -include-with-prefix-before,
5068 -include-with-prefix-before=, -no-integrated-cpp,
5069 -no-line-commands, -no-standard-includes, -no-warnings, -output,
5070 -output=, -pedantic, -pedantic-errors, -preprocess,
5071 -print-missing-file-dependencies, -trace-includes, -traditional,
5072 -traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
5073 -user-dependencies, -verbose, -write-dependencies,
5074 -write-user-dependencies, no-integrated-cpp, traditional): New.
5075
e6fb54ba 50762010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
5077
5078 PR objc/23710
9b60f3b0 5079 * c-common.h (objc_start_method_definition): Return bool instead
5080 of void.
5081 * stub-objc.c (objc_start_method_definition): Return bool instead
5082 of void.
5083
50842010-09-21 Nicola Pero <nicola.pero@meta-innovation.com>
5085
5086 PR objc/25965
5087 * c-common.h (objc_get_interface_ivars): New declaration.
5088 * stub-objc.c (objc_get_interface_ivars): New stub.
e6fb54ba 5089
e44b0a1f 50902010-09-15 Ian Lance Taylor <iant@google.com>
5091
5092 * c-common.c (parse_optimize_options): Do not capitalize warning
ebd7c4c1 5093 messages. Remove period at end of warning message.
e44b0a1f 5094
85c0a25c 50952010-09-09 Nathan Sidwell <nathan@codesourcery.com>
5096
5097 * c-common.c (handle_alias_ifunc_attribute): New, broken out of ...
5098 (handle_alias_attribute): ... here.
5099 (handle_ifunc_attribute): New.
5100
5ba33bf4 51012010-09-06 Mark Mitchell <mark@codesourcery.com>
5102
5103 * c-common.h (do_warn_double_promotion): Declare.
5104 * c-common.c (do_warn_double_promotion): Define.
5105
c920faa3 51062010-09-05 Mark Mitchell <mark@codesourcery.com>
5107
5108 * c.opt (Wdouble-promotion): New.
5109
9604e070 51102010-09-02 Joseph Myers <joseph@codesourcery.com>
5111
5112 * c.opt (falt-external-templates, fhuge-objects, fvtable-gc,
5113 fvtable-thunks, fxref): Mark no longer supported in help text.
5114
3b0273a1 51152010-09-02 Joseph Myers <joseph@codesourcery.com>
5116
5117 * c.opt (Wimport, fall-virtual, falt-external-templates,
5118 fdefault-inline, fenum-int-equiv, fexternal-templates,
5119 fguiding-decls, fhonor-std, fhuge-objects, flabels-ok,
5120 fname-mangling-version-, fnew-abi, fnonnull-objects,
5121 foptional-diags, fsquangle, fstrict-prototype, fthis-is-variable,
5122 fvtable-gc, fvtable-thunks, fxref): Mark with Ignore and Warn as
5123 applicable.
5124 (fhandle-exceptions): Mark with Alias and Warn.
5125 * c-opts.c (c_common_handle_option): Don't handle options marked
5126 as ignored.
5127
67089c6b 51282010-09-02 Joseph Myers <joseph@codesourcery.com>
5129
5130 * c.opt (Wcomments, Werror-implicit-function-declaration,
5131 ftemplate-depth-, std=c89, std=c9x, std=gnu89, std=gnu9x,
5132 std=iso9899:1990, std=iso9899:1999, std=iso9899:199x): Mark as
5133 aliases.
5134 * c-common.c (option_codes): Use OPT_Wcomment instead of
5135 OPT_Wcomments.
5136 * c-opts.c (warning_as_error_callback, c_common_handle_option):
5137 Don't handle options marked as aliases.
5138
2af087f2 51392010-08-25 Richard Guenther <rguenther@suse.de>
5140
5141 * c-common.c (c_common_get_alias_set): Remove special
5142 handling for pointers.
5143
48148244 51442010-08-20 Nathan Froyd <froydnj@codesourcery.com>
5145
5146 * c-common.c: Use FOR_EACH_VEC_ELT.
5147 * c-gimplify.c: Likewise.
5148 * c-pragma.c: Likewise.
5149
89c69892 51502010-08-16 Joseph Myers <joseph@codesourcery.com>
5151
5152 * c.opt (MDX): Change back to MD. Mark NoDriverArg instead of
5153 RejectDriver.
5154 (MMDX): Change back to MMD. Mark NoDriverArg instead of
5155 RejectDriver.
5156 * c-opts.c (c_common_handle_option): Use OPT_MD and OPT_MMD
5157 instead of OPT_MDX and OPT_MMDX.
5158
e28aa114 51592010-08-16 Joseph Myers <joseph@codesourcery.com>
5160
5161 * c.opt (MDX, MMDX, lang-asm): Mark RejectDriver.
5162
99b66d21 51632010-08-12 Joseph Myers <joseph@codesourcery.com>
5164
5165 * c.opt (MD, MMD): Change to MDX and MMDX.
5166 * c-opts.c (c_common_handle_option): Use OPT_MMD and OPT_MMDX.
5167
666f4bf0 51682010-08-11 Joseph Myers <joseph@codesourcery.com>
5169
5170 * c-opts.c (c_common_handle_option): Call handle_generated_option
5171 instead of handle_option.
5172
5ec815f6 51732010-08-08 Nathan Froyd <froydnj@codesourcery.com>
5174
5175 * c-pragma.c (add_to_renaming_pragma_list): Fix call to VEC_safe_push.
5176 (maybe_apply_renaming_pragma): Delete unneeded declarations.
5177
d13143cf 51782010-08-08 Nathan Froyd <froydnj@codesourcery.com>
5179
5180 * c-pragma.c (pending_redefinition): Declare. Declare a VEC of it.
5181 (pending_redefine_extname): Change type to a VEC.
5182 (add_to_renaming_pragma_list): Update for new type of
5183 pending_redefine_extname.
5ec815f6 5184 (maybe_apply_renaming_pragma): Likewise.
d13143cf 5185
2008c983 51862010-08-04 Arnaud Charlet <charlet@adacore.com>
5187
5188 * c-ada-spec.c (dump_ada_template): Mark underlying instance type as
5189 visited.
5190 (dump_generic_ada_node): Code clean up. Use TREE_VISITED flag to
5191 decide whether a type has already been declared/seen.
5192 Do not go to the original type.
5193 (dump_nested_types): New parameter forward.
5194 Generate forward declaration if needed and mark type as visited.
5195 (print_ada_declaration): Call dump_nested_types if not already done.
5196 Mark types as visited.
5197
9b091a73 51982010-08-03 Joseph Myers <joseph@codesourcery.com>
5199
5200 * c.opt (-print-pch-checksum): Remove option.
5201 * c-opts.c (c_common_handle_option): Don't handle
5202 OPT_print_pch_checksum.
5203
b78351e5 52042010-07-27 Joseph Myers <joseph@codesourcery.com>
5205
5206 * c-common.h (c_common_handle_option): Update prototype and return
5207 value type.
5208 * c-opts.c (c_common_handle_option): Update prototype and return
5209 value type. Update calls to handle_option and
5210 enable_warning_as_error.
5211
34416a90 52122010-07-27 Jakub Jelinek <jakub@redhat.com>
5213
5214 PR c/45079
5215 * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.
5216
fecf9011 52172010-07-27 Joseph Myers <joseph@codesourcery.com>
5218
5219 * c-common.h (c_common_missing_argument): Remove.
5220 * c-opts.c (c_common_missing_argument): Remove.
5221 * c.opt (A, D, F, I, MD, MMD, MQ, MT, U, fconstant-string-class=,
5222 idirafter, imacros, include, isysroot, isystem, iquote): Add
5223 MissingArgError.
5224 * c-objc-common.h (LANG_HOOKS_MISSING_ARGUMENT): Remove.
5225
e88d34f6 52262010-07-27 Joseph Myers <joseph@codesourcery.com>
5227
5228 * c-common.h (c_common_option_lang_mask,
5229 c_common_initialize_diagnostics, c_common_complain_wrong_lang_p):
5230 New.
5231 (c_common_init_options): Update prototype.
5232 * c-opts.c (c_common_option_lang_mask): New.
5233 (c_common_initialize_diagnostics): Split out of
5234 c_common_init_options.
5235 (accept_all_c_family_options, c_common_complain_wrong_lang_p):
5236 New.
5237 (c_common_init_options): Update prototype. Use decoded options in
5238 search for -lang-asm.
5239
1767a056 52402010-07-15 Nathan Froyd <froydnj@codesourcery.com>
5241
5242 * c-common.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
5243 * c-format.c: Likewise.
5244
0b205f4c 52452010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
5246
5247 * c-common.h: Include diagnostic-core.h. Error if already
5248 included.
5249 * c-semantics.c: Do not define GCC_DIAG_STYLE here.
5250
1c58e3f1 52512010-07-03 Manuel López-Ibáñez <manu@gcc.gnu.org>
5252
1f78217c 5253 * c-common.c (IN_GCC_FRONTEND): Do not undef.
1c58e3f1 5254 Do not include expr.h
5255 (vector_mode_valid_p): Move here.
5256
33cc157c 52572010-06-21 DJ Delorie <dj@redhat.com>
5258
5259 * c-pragma.c (handle_pragma_diagnostic): Add push/pop,
5260 allow these pragmas anywhere.
5261
52622010-06-14 Jakub Jelinek <jakub@redhat.com>
5263
5264 PR bootstrap/44509
5265 * c-cppbuiltin.c: Include gt-c-family-c-cppbuiltin.h.
5266 (lazy_hex_fp_values, lazy_hex_fp_value_count): Add GTY(()) markers.
5267 (lazy_hex_fp_value, builtin_define_with_hex_fp_value): Use
5268 ggc_strdup instead of xstrdup.
5269
52702010-06-10 Jakub Jelinek <jakub@redhat.com>
5271
5272 * c-cppbuiltin.c: Include cpp-id-data.h.
5273 (lazy_hex_fp_values, lazy_hex_fp_value_count): New variables.
5274 (lazy_hex_fp_value): New function.
5275 (builtin_define_with_hex_fp_value): Provide definitions lazily.
5276
9b40bfbf 52772010-06-30 Manuel López-Ibáñez <manu@gcc.gnu.org>
5278
5279 * c-gimplify.c: Do not include tree-flow.h
5280
202d6e5f 52812010-06-29 Joern Rennecke <joern.rennecke@embecosm.com>
5282
5283 PR other/44034
5284 * c-common.c: Rename targetm member:
5285 targetm.enum_va_list -> targetm.enum_va_list_p
5286
d3237426 52872010-06-28 Anatoly Sokolov <aesok@post.ru>
5288
5289 * c-common.c (shorten_compare): Adjust call to force_fit_type_double.
5290
596981c8 52912010-06-28 Steven Bosscher <steven@gcc.gnu.org>
5292
5293 * c-cppbuiltin.c: Do not include except.h.
5294
b9bdfa0b 52952010-06-24 Andi Kleen <ak@linux.intel.com>
5296
19931eea 5297 * c-common.c (warn_for_omitted_condop): New.
5298 * c-common.h (warn_for_omitted_condop): Add prototype.
b9bdfa0b 5299
55ad092d 53002010-06-21 Joseph Myers <joseph@codesourcery.com>
5301
5302 * c.opt (lang-objc): Remove.
5303 * c-opts.c (c_common_handle_option): Don't handle OPT_lang_objc.
5304
9e7c2572 53052010-06-21 Joern Rennecke <joern.rennecke@embecosm.com>
5306
5307 * c-opts.c: Include "tm_p.h".
5308
615ef0bb 53092010-06-20 Joseph Myers <joseph@codesourcery.com>
5310
5311 * c-common.c (parse_optimize_options): Update call to
5312 decode_options.
5313
aef48c9a 53142010-06-18 Nathan Froyd <froydnj@codesourcery.com>
5315
5316 * c-common.c (record_types_used_by_current_var_decl): Adjust for
5317 new type of types_used_by_cur_var_decl.
5318
d74003b4 53192010-06-17 Joern Rennecke <joern.rennecke@embecosm.com>
5320
5321 PR bootstrap/44512
5322 * c-cppbuiltin.c (builtin_define_with_hex_fp_value): Add cast
5323 for C++ standard compliance.
5324
1194d077 53252010-06-16 Jason Merrill <jason@redhat.com>
5326
5327 * c.opt: Add -Wnoexcept.
5328
d473d901 53292010-06-16 Richard Guenther <rguenther@suse.de>
5330
5331 PR c/44555
5332 * c-common.c (c_common_truthvalue_conversion): Remove
5333 premature and wrong optimization concering ADDR_EXPRs.
5334
b62dbfd3 53352010-06-15 Arnaud Charlet <charlet@adacore.com>
5336
5337 * c-ada-spec.c (dump_sloc): Remove column info.
5338 (is_simple_enum): New function.
5339 (dump_generic_ada_node, print_ada_declaration): Map C enum types to Ada
5340 enum types when relevant.
5341
200dd99c 53422010-06-11 Manuel López-Ibáñez <manu@gcc.gnu.org>
5343
19931eea 5344 * c-common.c (conversion_warning): Warn at expression
200dd99c 5345 location.
5346
abf6a617 53472010-06-10 Joseph Myers <joseph@codesourcery.com>
5348
5349 * c-opts.c (c_common_handle_option): Don't handle
5350 OPT_fshow_column.
5351
ba72912a 53522010-06-08 Laurynas Biveinis <laurynas.biveinis@gmail.com>
5353
5354 * c-pragma.c (push_alignment): Use typed GC allocation.
5355 (handle_pragma_push_options): Likewise.
5356
5357 * c-common.c (parse_optimize_options): Likewise.
5358
5359 * c-common.h (struct sorted_fields_type): Add variable_size GTY
5360 option.
5361
4aafe913 53622010-06-07 Joseph Myers <joseph@codesourcery.com>
5363
5364 * c-common.c (flag_preprocess_only, flag_undef, flag_no_builtin,
5365 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
5366 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
5367 flag_signed_bitfields, warn_strict_null_sentinel,
5368 flag_nil_receivers, flag_zero_link, flag_replace_objc_classes,
5369 flag_gen_declaration, flag_no_gnu_keywords,
5370 flag_implement_inlines, flag_implicit_templates,
5371 flag_implicit_inline_templates, flag_optional_diags,
5372 flag_elide_constructors, flag_default_inline, flag_rtti,
5373 flag_conserve_space, flag_access_control, flag_check_new,
5374 flag_new_for_scope, flag_weak, flag_working_directory,
5375 flag_use_cxa_atexit, flag_use_cxa_get_exception_ptr,
5376 flag_enforce_eh_specs, flag_threadsafe_statics,
5377 flag_pretty_templates): Remove.
5378 * c-common.h (flag_preprocess_only, flag_nil_receivers,
5379 flag_objc_exceptions, flag_objc_sjlj_exceptions, flag_zero_link,
5380 flag_replace_objc_classes, flag_undef, flag_no_builtin,
5381 flag_no_nonansi_builtin, flag_short_double, flag_short_wchar,
5382 flag_lax_vector_conversions, flag_ms_extensions, flag_no_asm,
5383 flag_const_strings, flag_signed_bitfields, flag_gen_declaration,
5384 flag_no_gnu_keywords, flag_implement_inlines,
5385 flag_implicit_templates, flag_implicit_inline_templates,
5386 flag_optional_diags, flag_elide_constructors, flag_default_inline,
5387 flag_rtti, flag_conserve_space, flag_access_control,
5388 flag_check_new, flag_new_for_scope, flag_weak,
5389 flag_working_directory, flag_use_cxa_atexit,
5390 flag_use_cxa_get_exception_ptr, flag_enforce_eh_specs,
5391 flag_threadsafe_statics, flag_pretty_templates,
5392 warn_strict_null_sentinel): Remove.
5393 * c.opt (E, Wstrict-null-sentinel, faccess-control, fasm,
5394 fbuiltin, fcheck-new, fconserve-space, felide-constructors,
5395 fenforce-eh-specs, ffor-scope, fgnu-keywords, fimplement-inlines,
5396 fimplicit-inline-templates, fimplicit-templates,
5397 flax-vector-conversions, fms-extensions, fnil-receivers,
5398 fnonansi-builtins, fpretty-templates, freplace-objc-classes,
5399 frtti, fshort-double, fshort-enums, fshort-wchar,
5400 fsigned-bitfields, fsigned-char, fstats, fthreadsafe-statics,
5401 funsigned-bitfields, funsigned-char, fuse-cxa-atexit,
5402 fuse-cxa-get-exception-ptr, fweak, fworking-directory, fzero-link,
5403 gen-decls, undef): Use Var.
5404 (fdefault-inline, foptional-diags): Document as doing nothing.
5405 * c-opts.c (c_common_handle_option): Remove cases for options now
5406 using Var. Mark ignored options as such.
5407
7bedc3a0 54082010-06-05 Steven Bosscher <steven@gcc.gnu.org>
5409
19931eea 5410 * c-common.c: Moved to here from parent directory.
7bedc3a0 5411 * c-common.def: Likewise.
5412 * c-common.h: Likewise.
5413 * c-cppbuiltin.c: Likewise.
5414 * c-dump.c: Likewise.
5415 * c-format.c: Likewise.
5416 * c-format.h : Likewise.
5417 * c-gimplify.c: Likewise.
5418 * c-lex.c: Likewise.
5419 * c-omp.c: Likewise.
5420 * c.opt: Likewise.
5421 * c-opts.c: Likewise.
5422 * c-pch.c: Likewise.
5423 * c-ppoutput.c: Likewise.
5424 * c-pragma.c: Likewise.
5425 * c-pragma.h: Likewise.
5426 * c-pretty-print.c: Likewise.
5427 * c-pretty-print.h: Likewise.
5428 * c-semantics.c: Likewise.
5429 * stub-objc.c: Likewise.
5430
5431 * c-common.c: Include gt-c-family-c-common.h.
5432 * c-pragma.c: Include gt-c-family-c-pragma.h.
5433\f
d353bf18 5434Copyright (C) 2010-2015 Free Software Foundation, Inc.
7bedc3a0 5435
5436Copying and distribution of this file, with or without modification,
5437are permitted in any medium without royalty provided the copyright
5438notice and this notice are preserved.