re PR c/71426 (gcc ICE on x86_64-linux-gnu in get_parm_info, at c/c-decl.c:7059)
[gcc.git] / gcc / c / ChangeLog
1 2016-06-08 Marek Polacek <polacek@redhat.com>
2
3 PR c/71418
4 * c-decl.c (grokdeclarator): Check TYPE_P.
5
6 PR c/71426
7 * c-decl.c (get_parm_info): Don't crash on an assert on invalid
8 code.
9
10 2016-06-07 David Malcolm <dmalcolm@redhat.com>
11
12 * c-parser.c (c_parser_postfix_expression): In __builtin_offsetof
13 and structure element reference, capture the location of the
14 element name token and pass it to build_component_ref.
15 (c_parser_postfix_expression_after_primary): Likewise for
16 structure element dereference.
17 (c_parser_omp_variable_list): Likewise for
18 OMP_CLAUSE_{_CACHE, MAP, FROM, TO},
19 * c-tree.h (build_component_ref): Add location_t param.
20 * c-typeck.c (build_component_ref): Add location_t param
21 COMPONENT_LOC. Use it, if available, when issuing hints about
22 mispelled member names to provide a fixit replacement hint.
23
24 2016-06-06 Marek Polacek <polacek@redhat.com>
25
26 PR c/71362
27 * c-parser.c (c_parser_direct_declarator): Set location.
28
29 2016-06-06 Marek Polacek <polacek@redhat.com>
30
31 * c-typeck.c (comptypes_internal): Handle comparisons of
32 INTEGER_TYPE, FIXED_POINT_TYPE, and REAL_TYPE nodes. Don't check
33 TYPE_REF_CAN_ALIAS_ALL.
34
35 2016-06-03 Chung-Lin Tang <cltang@codesourcery.com>
36
37 * c-typeck.c (c_finish_omp_clauses): Mark OpenACC reduction
38 arguments as addressable when async clause exists.
39
40 2016-05-30 Jakub Jelinek <jakub@redhat.com>
41
42 PR c++/71349
43 * c-parser.c (c_parser_omp_for): Don't disallow nowait clause
44 when combined with target construct.
45
46 2016-05-26 Jakub Jelinek <jakub@redhat.com>
47
48 * c-parser.c (c_parser_omp_clause_schedule): Warn if
49 OMP_CLAUSE_SCHEDULE_CHUNK_EXPR is known not to be positive.
50
51 2016-05-25 Marek Polacek <polacek@redhat.com>
52
53 PR c/71265
54 * c-decl.c (c_make_fname_decl): Don't check seen_error.
55
56 PR c/71266
57 * c-decl.c (store_parm_decls_oldstyle): Skip non-PARM_DECLs.
58
59 2016-05-24 Cesar Philippidis <cesar@codesourcery.com>
60
61 * c-parser.c (c_parser_oacc_declare): Add support for
62 GOMP_MAP_FIRSTPRIVATE_POINTER.
63 * c-typeck.c (handle_omp_array_sections_1): Replace bool is_omp
64 argument with enum c_omp_region_type ort.
65 (handle_omp_array_sections): Likewise. Update call to
66 handle_omp_array_sections_1.
67 (c_finish_omp_clauses): Add specific errors and warning messages for
68 OpenACC. Use firsrtprivate pointers for OpenACC subarrays. Update
69 call to handle_omp_array_sections.
70
71 2016-05-24 Thomas Schwinge <thomas@codesourcery.com>
72
73 * c-parser.c (c_parser_oacc_routine): Tighten syntax checks.
74
75 2016-05-24 Richard Biener <rguenther@suse.de>
76
77 PR middle-end/70434
78 PR c/69504
79 * c-typeck.c (build_array_ref): Do not complain about indexing
80 non-lvalue vectors. Adjust for function name change.
81
82 2016-05-20 Martin Sebor <msebor@redhat.com>
83
84 PR c/71115
85 * c-typeck.c (error_init): Use
86 expansion_point_location_if_in_system_header.
87 (warning_init): Same.
88
89 2016-05-19 David Malcolm <dmalcolm@redhat.com>
90
91 PR c/71171
92 * c-parser.c (c_parser_generic_selection): Use c_expr::set_error
93 in error-handling.
94 (c_parser_postfix_expression): Likewise.
95 * c-tree.h (c_expr::set_error): New method.
96 * c-typeck.c (parser_build_binary_op): In error-handling, ensure
97 that result's range is initialized.
98
99 2016-05-17 James Greenhalgh <james.greenhalgh@arm.com>
100
101 * c-typeck.c (parser_build_unary_op): Fix formatting.
102
103 2016-05-16 Matthew Wahab <matthew.wahab@arm.com>
104
105 * c-decl.c (grokdeclarator): Remove errmsg and use of
106 targetm.invalid_return_type.
107 (grokparms): Remove errmsg and use of
108 targetm.invalid_parameter_type.
109
110 2016-05-13 Joseph Myers <joseph@codesourcery.com>
111
112 * c-decl.c (grokdeclarator): For C11, discard qualifiers on
113 function return type.
114
115 2016-05-12 Marek Polacek <polacek@redhat.com>
116
117 PR c/70756
118 * c-decl.c (build_compound_literal): Pass LOC down to
119 c_incomplete_type_error.
120 * c-tree.h (require_complete_type): Adjust declaration.
121 (c_incomplete_type_error): Likewise.
122 * c-typeck.c (require_complete_type): Add location parameter, pass it
123 down to c_incomplete_type_error.
124 (c_incomplete_type_error): Add location parameter, pass it down to
125 error_at.
126 (build_component_ref): Pass location down to c_incomplete_type_error.
127 (default_conversion): Pass location down to require_complete_type.
128 (build_array_ref): Likewise.
129 (build_function_call_vec): Likewise.
130 (convert_arguments): Likewise.
131 (build_unary_op): Likewise.
132 (build_c_cast): Likewise.
133 (build_modify_expr): Likewise.
134 (convert_for_assignment): Likewise.
135 (c_finish_omp_clauses): Likewise.
136
137 2016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
138
139 PR c/43651
140 * c-decl.c (declspecs_add_qual): Warn when -Wduplicate-decl-specifier
141 is enabled.
142 * c-errors.c (pedwarn_c90): Return true if warned.
143 * c-tree.h (pedwarn_c90): Change return type to bool.
144 (enum c_declspec_word): Add new enumerator cdw_atomic.
145
146 2016-05-11 Marek Polacek <polacek@redhat.com>
147
148 PR c++/71024
149 * c-decl.c (diagnose_mismatched_decls): Factor out code to
150 diagnose_mismatched_attributes and call it.
151
152 2016-05-10 Marek Polacek <polacek@redhat.com>
153
154 PR c/70255
155 * c-decl.c (diagnose_mismatched_decls): Warn for optimize attribute
156 on a declaration following the definition.
157
158 2016-05-05 Jakub Jelinek <jakub@redhat.com>
159
160 * c-parser.c (c_parser_switch_statement): Add IF_P argument,
161 parse it through to c_parser_c99_block_statement.
162 (c_parser_statement_after_labels): Adjust c_parser_switch_statement
163 caller.
164
165 2016-05-04 Marek Polacek <polacek@redhat.com>
166
167 * c-parser.c (c_parser_if_statement): Replace OPT_Wparentheses with
168 OPT_Wdangling_else.
169
170 2016-05-04 Marek Polacek <polacek@redhat.com>
171
172 PR c/48778
173 * c-typeck.c (build_binary_op): Don't issue -Waddress warnings
174 for macro expansions.
175
176 2016-05-03 Marek Polacek <polacek@redhat.com>
177
178 PR c/70859
179 * c-typeck.c (build_function_call_vec): Pass LOC and ARG_LOC down to
180 check_builtin_function_arguments.
181
182 2016-05-03 Richard Biener <rguenther@suse.de>
183
184 * Make-lang.in (cc1-checksum.c): For stage-final re-use
185 the checksum from the previous stage.
186
187 2016-05-02 Cesar Philippidis <cesar@codesourcery.com>
188
189 * c-parser.c (c_parser_oacc_all_clauses): Update call to
190 c_finish_omp_clauses.
191 (c_parser_omp_all_clauses): Likewise.
192 (c_parser_oacc_cache): Likewise.
193 (c_parser_oacc_loop): Likewise.
194 (omp_split_clauses): Likewise.
195 (c_parser_omp_declare_target): Likewise.
196 (c_parser_cilk_all_clauses): Likewise.
197 (c_parser_cilk_for): Likewise.
198 * c-typeck.c (c_finish_omp_clauses): Replace bool arguments
199 is_omp, declare_simd, and is_cilk with enum c_omp_region_type ort.
200
201 2016-05-02 Marek Polacek <polacek@redhat.com>
202
203 PR c/70851
204 * c-decl.c (grokdeclarator): Diagnose when array's size has an
205 incomplete type.
206
207 2016-04-29 Cesar Philippidis <cesar@codesourcery.com>
208
209 PR middle-end/70626
210 * c-parser.c (c_parser_oacc_loop): Don't augment mask with
211 OACC_LOOP_CLAUSE_MASK.
212 (c_parser_oacc_kernels_parallel): Update call to
213 c_oacc_split_loop_clauses.
214
215 2016-04-28 Andrew MacLeod <amacleod@redhat.com>
216
217 * c-array-notation.c (fix_builtin_array_notation_fn): Fix final
218 argument to build_modify_expr in two cases.
219
220 2016-04-27 Bernd Schmidt <bschmidt@redhat.com>
221
222 * c-parser.c (c_parser_postfix_expression_after_primary): Call
223 warn_for_memset instead of warning directly here.
224
225 2016-04-26 Marek Polacek <polacek@redhat.com>
226
227 PR c/67784
228 * c-parser.c (c_parser_maybe_reclassify_token): New function factored
229 out of ...
230 (c_parser_for_statement): ... here.
231 (c_parser_if_statement): Use it.
232 (c_parser_switch_statement): Use it.
233 (c_parser_while_statement): Use it.
234
235 PR c/70791
236 * c-decl.c (pushdecl): Pass LOCUS down to warning.
237
238 2016-04-20 Ilya Verbin <ilya.verbin@intel.com>
239
240 PR c++/69363
241 * c-parser.c (c_parser_cilk_all_clauses): Use c_finish_omp_clauses
242 instead of c_finish_cilk_clauses.
243 * c-tree.h (c_finish_omp_clauses): Add new default argument.
244 * c-typeck.c (c_finish_omp_clauses): Add new argument. Allow
245 floating-point variables in the linear clause for Cilk Plus.
246
247 2016-04-18 Michael Matz <matz@suse.de>
248
249 * c-decl.c (merge_decls): Use SET_DECL_ALIGN and SET_TYPE_ALIGN.
250 (grokdeclarator, parser_xref_tag, finish_enum): Use SET_TYPE_ALIGN.
251
252 2016-04-15 Marek Polacek <polacek@redhat.com>
253
254 PR c/70671
255 * c-typeck.c (build_unary_op): Pass location down to error and
256 warning call.
257
258 2016-04-15 Jakub Jelinek <jakub@redhat.com>
259
260 PR c/70436
261 * c-parser.c (c_parser_pragma): Add IF_P argument, pass it down
262 where needed.
263 (c_parser_external_declaration, c_parser_struct_or_union_specifier,
264 c_parser_parameter_declaration, c_parser_compound_statement_nostart,
265 c_parser_objc_class_instance_variables, c_parser_objc_methodprotolist):
266 Adjust c_parser_pragma callers.
267 (c_parser_statement_after_labels): Likewise. Adjust c_parser_cilk_for
268 caller.
269 (c_parser_omp_structured_block): Add IF_P argument, pass it down to
270 c_parser_statement.
271 (c_parser_oacc_data, c_parser_oacc_host_data, c_parser_oacc_loop,
272 c_parser_oacc_kernels_parallel, c_parser_omp_critical,
273 c_parser_omp_simd, c_parser_omp_for, c_parser_omp_master,
274 c_parser_omp_ordered, c_parser_omp_parallel, c_parser_omp_single,
275 c_parser_omp_task, c_parser_omp_taskgroup, c_parser_omp_distribute,
276 c_parser_omp_teams, c_parser_omp_target_data, c_parser_omp_target,
277 c_parser_omp_taskloop, c_parser_omp_construct, c_parser_cilk_grainsize,
278 c_parser_cilk_simd, c_parser_cilk_for): Add IF_P argument, pass it
279 down where needed.
280 (c_parser_omp_for_loop): Likewise. Clear IF_P if nbraces.
281 (c_parser_omp_sections_scope): Adjust c_parser_omp_structured_block
282 calls.
283
284 2016-04-13 Marek Polacek <polacek@redhat.com>
285
286 PR c/70436
287 * c-parser.c (c_parser_statement_after_labels): Add IF_P argument and
288 adjust callers.
289 (c_parser_statement): Likewise.
290 (c_parser_c99_block_statement): Likewise.
291 (c_parser_while_statement): Likewise.
292 (c_parser_for_statement): Likewise.
293 (c_parser_if_body): Don't set IF_P here.
294 (c_parser_if_statement): Add IF_P argument. Set IF_P here. Warn
295 about dangling else here.
296 * c-tree.h (c_finish_if_stmt): Adjust declaration.
297 * c-typeck.c (c_finish_if_stmt): Remove NESTED_IF parameter. Don't
298 warn about dangling else here.
299
300 2016-04-04 Marek Polacek <polacek@redhat.com>
301
302 PR c/70307
303 * c-fold.c (c_fully_fold_internal): Handle VEC_COND_EXPR.
304
305 2016-03-31 Marek Polacek <polacek@redhat.com>
306
307 PR c/70297
308 * c-decl.c (merge_decls): Also set TYPE_ALIGN and TYPE_USER_ALIGN.
309
310 2016-03-18 David Malcolm <dmalcolm@redhat.com>
311
312 PR c/70281
313 * c-parser.c (c_parser_postfix_expression): Set the source range
314 for uses of "__builtin_types_compatible_p".
315
316 2016-03-17 Jakub Jelinek <jakub@redhat.com>
317
318 PR c/70280
319 * c-typeck.c (composite_type): Don't count void_list_node
320 into len, if the list is terminated by void_list_node, start
321 with void_list_node instead of NULL for newargs. Stop
322 at void_list_node.
323
324 2016-03-16 Marek Polacek <polacek@redhat.com>
325
326 PR c/70093
327 * c-typeck.c (build_function_call_vec): Create a TARGET_EXPR for
328 nested functions returning VM types.
329
330 2016-03-09 Cesar Philippidis <cesar@codesourcery.com>
331
332 * c-parser.c (c_parser_oacc_loop): Update cclauses and clauses
333 when calling c_finish_omp_clauses.
334
335 2016-03-04 Bernd Schmidt <bschmidt@redhat.com>
336
337 PR c/69824
338 * c-decl.c (get_parm_info): Don't queue implicit function declarations
339 for later.
340
341 2016-03-04 Marek Polacek <polacek@redhat.com>
342
343 PR c/69798
344 * c-parser.c (c_parser_postfix_expression): Call
345 c_parser_cast_expression rather than c_parser_postfix_expression.
346
347 2016-03-01 Jakub Jelinek <jakub@redhat.com>
348
349 PR c/69796
350 PR c/69974
351 * c-parser.c (c_parser_translation_unit): Don't change TREE_TYPE
352 of incomplete decls to error_mark_node.
353
354 2016-02-24 Marek Polacek <polacek@redhat.com>
355
356 PR c/69819
357 * c-decl.c (finish_decl): Don't update the copy of the type of a
358 different decl type.
359
360 2016-02-23 Jakub Jelinek <jakub@redhat.com>
361
362 PR objc/69844
363 * c-parser.c (c_parser_for_statement): Properly handle ObjC classes
364 in id_kind reclassification.
365
366 2016-02-16 Jakub Jelinek <jakub@redhat.com>
367
368 PR c/69835
369 * c-typeck.c (build_binary_op): Revert 2015-09-09 change.
370
371 2016-02-16 James Norris <jnorris@codesourcery.com>
372
373 PR c/64748
374 * c-parser.c (c_parser_oacc_data_clause_deviceptr): Allow parms.
375
376 2016-02-12 Bernd Schmidt <bschmidt@redhat.com>
377
378 * c-decl.c (build_null_declspecs): Zero the entire struct.
379
380 PR c/69522
381 * c-parser.c (c_parser_braced_init): New arg outer_obstack. All
382 callers changed. If nested_p is true, use it to call
383 finish_implicit_inits.
384 * c-tree.h (finish_implicit_inits): Declare.
385 * c-typeck.c (finish_implicit_inits): New function. Move code
386 from ...
387 (push_init_level): ... here.
388 (set_designator, process_init_element): Call finish_implicit_inits.
389
390 2016-02-11 Jakub Jelinek <jakub@redhat.com>
391
392 PR c/69768
393 * c-typeck.c (parser_build_binary_op): Strip nops from integer_zerop
394 arguments for -Waddress warning.
395
396 2016-02-04 Jakub Jelinek <jakub@redhat.com>
397
398 PR c/69669
399 * c-decl.c (finish_enum): When honoring mode attribute,
400 make sure to use proper TYPE_MIN_VALUE and TYPE_MAX_VALUE.
401
402 2016-01-29 Jakub Jelinek <jakub@redhat.com>
403
404 PR debug/69518
405 * c-decl.c (finish_struct): Clear C_TYPE_INCOMPLETE_VARS in
406 all type variants, not just TYPE_MAIN_VARIANT.
407
408 2016-01-27 Jakub Jelinek <jakub@redhat.com>
409
410 PR debug/66869
411 * c-decl.c (c_write_global_declarations_1): Warn with
412 warn_unused_function if static prototype without definition
413 is not C_DECL_USED.
414
415 2016-01-27 Marek Polacek <polacek@redhat.com>
416
417 PR c/68062
418 * c-typeck.c (build_binary_op) [EQ_EXPR, GE_EXPR]: Promote operand
419 to unsigned, if needed. Add -Wsign-compare warning.
420
421 2016-01-26 Jakub Jelinek <jakub@redhat.com>
422
423 PR tree-optimization/69483
424 * c-parser.c (c_parser_translation_unit): Use FOR_EACH_VEC_ELT.
425
426 2016-01-20 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
427
428 PR c/24293
429 * c-tree.h (incomplete_record_decls): Declare.
430 * c-parser.c (incomplete_record_decls): Define.
431 (c_parser_translation_unit): Iterate through incomplete_record_decls and
432 report error if any decl has zero size.
433 * c-decl.c (finish_decl): Append static decl with incomplete struct/union
434 or enum type to incomplete_record_decls.
435
436 2016-01-14 Tom de Vries <tom@codesourcery.com>
437
438 PR tree-optimization/68773
439 * c-parser.c (c_parser_oacc_declare, c_parser_omp_declare_target): Don't
440 set force_output.
441
442 2016-01-14 Marek Polacek <polacek@redhat.com>
443
444 PR c/69262
445 * c-decl.c (grokdeclarator): Provide more information for invalid
446 array declarations.
447
448 2016-01-06 David Malcolm <dmalcolm@redhat.com>
449
450 * c-parser.c (c_parser_unary_expression): For dereferences, build
451 a combined location before calling build_indirect_ref, so that
452 error reports cover the full range, manually updating the c_expr
453 src_range.
454
455 2016-01-06 Marek Polacek <polacek@redhat.com>
456
457 PR sanitizer/69099
458 * c-convert.c (convert) [INTEGER_TYPE]: Drop ARG. Don't pass ARG to
459 ubsan_instrument_float_cast. Fold EXPR. Use NULL_TREE instead of
460 NULL.
461
462 2016-01-04 Jakub Jelinek <jakub@redhat.com>
463
464 Update copyright years.
465
466 2016-01-04 Marek Polacek <polacek@redhat.com>
467
468 PR c/68908
469 * c-typeck.c (build_atomic_assign): Improve commentary. Add
470 optimization to use __atomic_fetch_* built-in if possible.
471
472 2015-12-23 Thomas Schwinge <thomas@codesourcery.com>
473
474 * c-parser.c (c_parser_oacc_clause_use_device): Merge function
475 into...
476 (c_parser_omp_clause_use_device_ptr): ... this function. Adjust
477 all users.
478
479 2015-12-22 Marek Polacek <polacek@redhat.com>
480
481 PR c/69002
482 * c-typeck.c (build_component_ref): Warn when acessing elements of
483 atomic structures or unions.
484
485 2015-12-21 David Malcolm <dmalcolm@redhat.com>
486
487 * c-typeck.c: Include "gcc-rich-location.h".
488 (build_binary_op): In the two places that call binary_op_error,
489 create a gcc_rich_location and populate it with the location of
490 the binary op and its two operands.
491
492 2015-12-16 David Malcolm <dmalcolm@redhat.com>
493
494 * c-parser.c (c_parser_statement_after_labels): When calling
495 c_finish_return, Use the return expression's location if it has
496 one, falling back to the location of the first token within it.
497 * c-typeck.c (c_finish_return): When issuing warnings about
498 the incorrect presence/absence of a return value, issue a note
499 showing the declaration of the function.
500
501 2015-12-16 David Malcolm <dmalcolm@redhat.com>
502
503 * c-parser.c (struct c_parser): Expand array "tokens_buf" from 2
504 to 4.
505 (c_parser_peek_nth_token): New function.
506 (c_parser_peek_conflict_marker): New function.
507 (c_parser_error): Detect conflict markers and report them as such.
508
509 2015-12-16 David Malcolm <dmalcolm@redhat.com>
510
511 * c-parser.c (c_parser_postfix_expression): Use EXPR_LOC_OR_LOC
512 to preserve range information for the primary expression
513 in the call to c_parser_postfix_expression_after_primary.
514
515 2015-12-16 David Malcolm <dmalcolm@redhat.com>
516
517 * c-parser.c (c_parser_static_assert_declaration_no_semi): Use the
518 expression location, falling back on the first token location,
519 rather than always using the latter.
520
521 2015-12-16 Marek Polacek <polacek@redhat.com>
522
523 PR c/64637
524 * c-typeck.c (c_process_expr_stmt): Use location of the expression if
525 available.
526
527 2015-12-15 Marek Polacek <polacek@redhat.com>
528
529 PR c/68907
530 * c-typeck.c (build_atomic_assign): Set TREE_NO_WARNING on an
531 artificial decl.
532
533 2015-12-08 David Malcolm <dmalcolm@redhat.com>
534
535 * c-parser.c (c_parser_alignof_expression): Capture location of
536 closing parenthesis (if any), or of end of unary expression, and
537 use it to build a src_range for the expression.
538
539 2015-12-08 David Malcolm <dmalcolm@redhat.com>
540
541 PR c/68757
542 * c-parser.c (c_parser_get_builtin_args): Add
543 "out_close_paren_loc" param, and write back to it.
544 (c_parser_postfix_expression): Capture the closing
545 parenthesis location for RID_CHOOSE_EXPR,
546 RID_BUILTIN_CALL_WITH_STATIC_CHAIN, RID_BUILTIN_COMPLEX,
547 RID_BUILTIN_SHUFFLE and use it to set the source range
548 for such expressions; within RID_BUILTIN_COMPLEX set
549 the underlying location.
550
551 2015-12-07 Marek Polacek <polacek@redhat.com>
552
553 PR c/68668
554 * c-decl.c (grokdeclarator): If ORIG_QUAL_INDIRECT is indirect, use
555 TREE_TYPE of ORIG_QUAL_TYPE, otherwise decrement ORIG_QUAL_INDIRECT.
556
557 2015-12-04 Eric Botcazou <ebotcazou@adacore.com>
558
559 * c-tree.h (c_build_va_arg): Adjust prototype.
560 * c-parser.c (c_parser_postfix_expression): Adjust call to above.
561 * c-typeck.c (c_build_va_arg): Rename LOC parameter to LOC2, add LOC1
562 parameter, adjust throughout and issue an error if EXPR is a component
563 with reverse storage order.
564
565 2015-12-02 Jason Merrill <jason@redhat.com>
566
567 * c-fold.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
568 (c_fully_fold_internal, decl_constant_value_for_optimization):
569 Move from c-common.c.
570 * c-tree.h: Declare decl_constant_value_for_optimization.
571 * Make-lang.in (C_AND_OBJC_OBJS): Add c-fold.o.
572
573 2015-12-02 Joseph Myers <joseph@codesourcery.com>
574
575 PR c/68162
576 * c-decl.c (grokdeclarator): Set first_non_attr_kind before
577 following link from declarator to next declarator. Track original
578 qualified type and pass it to c_build_qualified_type.
579 * c-typeck.c (c_build_qualified_type): Add arguments
580 orig_qual_type and orig_qual_indirect.
581
582 2015-12-02 Thomas Schwinge <thomas@codesourcery.com>
583
584 * c-parser.c (c_parser_omp_clause_name)
585 (c_parser_oacc_all_clauses): Alphabetical sorting.
586
587 2015-12-02 Jakub Jelinek <jakub@redhat.com>
588
589 PR c/68533
590 * c-decl.c (get_parm_info): Use b->locus instead of input_location
591 for diagnostics.
592
593 2015-12-01 Julian Brown <julian@codesourcery.com>
594 Cesar Philippidis <cesar@codesourcery.com>
595 James Norris <James_Norris@mentor.com>
596
597 * c-parser.c (c_parser_omp_clause_name): Add use_device support.
598 (c_parser_oacc_clause_use_device): New function.
599 (c_parser_oacc_all_clauses): Add use_device support.
600 (OACC_HOST_DATA_CLAUSE_MASK): New macro.
601 (c_parser_oacc_host_data): New function.
602 (c_parser_omp_construct): Add host_data support.
603 * c-tree.h (c_finish_oacc_host_data): Add prototype.
604 * c-typeck.c (c_finish_oacc_host_data): New function.
605 (c_finish_omp_clauses): Add use_device support.
606
607 2015-11-29 Jan Hubicka <hubicka@ucw.cz>
608
609 PR c/67106
610 * c-decl.c: Set TYPE_PACKED in variants.
611
612 2015-11-27 Martin Liska <mliska@suse.cz>
613
614 PR c++/68312
615 * c-array-notation.c (fix_builtin_array_notation_fn):
616 Use release_vec_vec instead of vec::release.
617 (build_array_notation_expr): Likewise.
618 (fix_conditional_array_notations_1): Likewise.
619 (fix_array_notation_expr): Likewise.
620 (fix_array_notation_call_expr): Likewise.
621
622 2015-11-27 Jakub Jelinek <jakub@redhat.com>
623
624 PR c/63326
625 * c-parser.c (c_parser_compound_statement_nostart): If
626 last_label is true, use pragma_stmt instead of pragma_compound
627 as second c_parser_pragma argument.
628 (c_parser_omp_ordered, c_parser_omp_target_update,
629 c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): Pass
630 false as second argument to c_parser_skip_to_pragma_eol after
631 diagnosing standalone directives used in pragma_stmt context.
632
633 2015-11-24 Ilya Verbin <ilya.verbin@intel.com>
634
635 * c-parser.c (c_parser_oacc_declare): Replace "ifdef ENABLE_OFFLOADING"
636 with "if (ENABLE_OFFLOADING)".
637
638 2015-11-23 David Malcolm <dmalcolm@redhat.com>
639
640 PR objc/68438
641 * c-parser.c (c_parser_postfix_expression): Set up source ranges
642 for various Objective-C constructs: Class.name syntax,
643 @selector(), @protocol(), @encode(), and [] message syntax.
644
645 2015-11-20 David Malcolm <dmalcolm@redhat.com>
646
647 PR 62314
648 * c-typeck.c (should_suggest_deref_p): New function.
649 (build_component_ref): Special-case POINTER_TYPE when
650 generating a "not a structure of union" error message, and
651 suggest a "->" rather than a ".", providing a fix-it hint.
652
653 2015-11-19 David Malcolm <dmalcolm@redhat.com>
654
655 * c-typeck.c (lookup_field_fuzzy): Move determination of closest
656 candidate into a new function, find_closest_identifier.
657
658 2015-11-19 Marek Polacek <polacek@redhat.com>
659
660 PR c/68412
661 * c-typeck.c (parser_build_binary_op): Properly handle
662 C_MAYBE_CONST_EXPR before calling warn_tautological_cmp.
663
664 2015-11-17 David Malcolm <dmalcolm@redhat.com>
665
666 * c-parser.c (set_c_expr_source_range): Bulletproof both
667 overloaded implementations against NULL expr->value.
668 (c_parser_braced_init): Set src_range for "ret" to a sane pair of
669 values.
670 (c_parser_unary_expression): Likewise when handling addresses of
671 labels.
672 (c_parser_postfix_expression): Likewise for statement expressions,
673 for __FUNCTION__, __PRETTY_FUNCTION_ and __func__ keywords, for
674 __builtin_va_arg, and for __builtin_offset_of.
675 (c_parser_postfix_expression_after_paren_type): Initialize expr's
676 src_range using the range of the braced initializer.
677 (c_parser_transaction_expression): Set src_range for "ret" to a
678 sane pair of values.
679
680 2015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
681
682 * c-parser.c (c_finish_omp_declare_simd): Look for
683 "simd" attribute as well. Update error message.
684
685 2015-11-14 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
686
687 * c-parser.c (c_parser_omp_declare_target): Adjust.
688
689 2015-11-14 Jakub Jelinek <jakub@redhat.com>
690
691 * c-typeck.c (c_finish_omp_clauses): Don't mark
692 GOMP_MAP_FIRSTPRIVATE_POINTER decls addressable.
693
694 2015-11-14 Marek Polacek <polacek@redhat.com>
695
696 * c-decl.c: Use RECORD_OR_UNION_TYPE_P throughout.
697 * c-typeck.c: Likewise.
698
699 2015-11-13 David Malcolm <dmalcolm@redhat.com>
700
701 * c-decl.c (warn_defaults_to): Pass line_table to
702 rich_location ctor.
703 * c-errors.c (pedwarn_c99): Likewise.
704 (pedwarn_c90): Likewise.
705 * c-parser.c (set_c_expr_source_range): New functions.
706 (c_token::get_range): New method.
707 (c_token::get_finish): New method.
708 (c_parser_expr_no_commas): Call set_c_expr_source_range on the ret
709 based on the range from the start of the LHS to the end of the
710 RHS.
711 (c_parser_conditional_expression): Likewise, based on the range
712 from the start of the cond.value to the end of exp2.value.
713 (c_parser_binary_expression): Call set_c_expr_source_range on
714 the stack values for TRUTH_ANDIF_EXPR and TRUTH_ORIF_EXPR.
715 (c_parser_cast_expression): Call set_c_expr_source_range on ret
716 based on the cast_loc through to the end of the expr.
717 (c_parser_unary_expression): Likewise, based on the
718 op_loc through to the end of op.
719 (c_parser_sizeof_expression) Likewise, based on the start of the
720 sizeof token through to either the closing paren or the end of
721 expr.
722 (c_parser_postfix_expression): Likewise, using the token range,
723 or from the open paren through to the close paren for
724 parenthesized expressions.
725 (c_parser_postfix_expression_after_primary): Likewise, for
726 various kinds of expression.
727 * c-tree.h (struct c_expr): Add field "src_range".
728 (c_expr::get_start): New method.
729 (c_expr::get_finish): New method.
730 (set_c_expr_source_range): New decls.
731 * c-typeck.c (parser_build_unary_op): Call set_c_expr_source_range
732 on ret for prefix unary ops.
733 (parser_build_binary_op): Likewise, running from the start of
734 arg1.value through to the end of arg2.value.
735
736 2015-11-13 Marek Polacek <polacek@redhat.com>
737
738 PR c/68320
739 * c-parser.c (c_parser_for_statement): Treat unknown tokens as IDs.
740
741 2015-11-13 David Malcolm <dmalcolm@redhat.com>
742
743 * c-typeck.c: Include spellcheck.h.
744 (lookup_field_fuzzy_find_candidates): New function.
745 (lookup_field_fuzzy): New function.
746 (build_component_ref): If the field was not found, try using
747 lookup_field_fuzzy and potentially offer a suggestion.
748
749 2015-11-12 James Norris <jnorris@codesourcery.com>
750 Joseph Myers <joseph@codesourcery.com>
751
752 * c-parser.c (c_parser_pragma): Handle PRAGMA_OACC_DECLARE.
753 (c_parser_omp_clause_name): Handle 'device_resident' clause.
754 (c_parser_oacc_data_clause): Handle PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT
755 and PRAGMA_OMP_CLAUSE_LINK.
756 (c_parser_oacc_all_clauses): Handle PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT
757 and PRAGMA_OACC_CLAUSE_LINK.
758 (OACC_DECLARE_CLAUSE_MASK): New definition.
759 (c_parser_oacc_declare): New function.
760
761 2015-11-12 Marek Polacek <polacek@redhat.com>
762
763 PR c/67784
764 * c-parser.c (c_parser_for_statement): Reclassify the token in
765 a correct scope.
766
767 2015-11-11 Marek Polacek <polacek@redhat.com>
768
769 PR c/68107
770 PR c++/68266
771 * c-decl.c (grokdeclarator): Call valid_array_size_p. Remove code
772 checking the size of an array.
773
774 2015-11-11 Andrew MacLeod <amacleod@redhat.com>
775
776 * c-array-notation.c: Remove unused header files.
777 * c-aux-info.c: Likewise.
778 * c-convert.c: Likewise.
779 * c-decl.c: Likewise.
780 * c-errors.c: Likewise.
781 * c-lang.c: Likewise.
782 * c-objc-common.c: Likewise.
783 * c-parser.c: Likewise.
784 * c-typeck.c: Likewise.
785 * gccspec.c: Likewise.
786
787 2015-11-09 Thomas Schwinge <thomas@codesourcery.com>
788 Cesar Philippidis <cesar@codesourcery.com>
789 James Norris <jnorris@codesourcery.com>
790 Julian Brown <julian@codesourcery.com>
791 Nathan Sidwell <nathan@codesourcery.com>
792
793 c/
794 * c-parser.c (c_parser_declaration_or_fndef): Add OpenACC
795 routine arg.
796 (c_parser_declaration_or_fndef): Call c_finish_oacc_routine.
797 (c_parser_pragma): Parse 'acc routine'.
798 (OACC_ROUTINE_CLAUSE_MARK): Define.
799 (c_parser_oacc_routine, (c_finish_oacc_routine): New.
800
801 2015-11-09 Andreas Arnez <arnez@linux.vnet.ibm.com>
802
803 PR debug/67192
804 * c-typeck.c (c_finish_loop): For unconditional loops, set the
805 location of the backward-goto to the start of the loop body.
806
807 2015-11-09 Andreas Arnez <arnez@linux.vnet.ibm.com>
808
809 PR debug/67192
810 * c-parser.c (c_parser_while_statement): Finish the loop before
811 parsing ahead for misleading indentation.
812 (c_parser_for_statement): Likewise.
813
814 2015-11-08 Eric Botcazou <ebotcazou@adacore.com>
815
816 * c-decl.c (finish_struct): If the structure has reverse storage
817 order, rewrite the type of array fields with scalar component. Call
818 maybe_apply_pragma_scalar_storage_order on entry.
819 * c-typeck.c (build_unary_op) <ADDR_EXPR>: Remove left-overs. Issue
820 errors on bit-fields and reverse SSO here and not...
821 (c_mark_addressable): ...here.
822 (output_init_element): Adjust call to initializer_constant_valid_p.
823 (c_build_qualified_type): Propagate TYPE_REVERSE_STORAGE_ORDER.
824
825 2015-11-06 David Malcolm <dmalcolm@redhat.com>
826
827 * c-decl.c (warn_defaults_to): Update for change in signature
828 of diagnostic_set_info.
829 * c-errors.c (pedwarn_c99): Likewise.
830 (pedwarn_c90): Likewise.
831 * c-objc-common.c (c_tree_printer): Update for new "caret_p" param
832 for textinfo::set_location.
833
834 2015-11-05 Cesar Philippidis <cesar@codesourcery.com>
835 Thomas Schwinge <thomas@codesourcery.com>
836 James Norris <jnorris@codesourcery.com>
837
838 * c-parser.c (c_parser_omp_clause_name): Add support for
839 PRAGMA_OACC_CLAUSE_INDEPENDENT and PRAGMA_OACC_CLAUSE_TILE.
840 (c_parser_omp_clause_default): Add is_oacc argument. Handle
841 default(none) in OpenACC.
842 (c_parser_oacc_shape_clause): Allow pointer variables as gang static
843 arguments.
844 (c_parser_oacc_clause_tile): New function.
845 (c_parser_oacc_all_clauses): Add support for OMP_CLAUSE_DEFAULT,
846 OMP_CLAUSE_INDEPENDENT and OMP_CLAUSE_TILE.
847 (OACC_LOOP_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_{PRIVATE,INDEPENDENT,
848 TILE}.
849 (OACC_KERNELS_MASK): Add PRAGMA_OACC_CLAUSE_DEFAULT.
850 (OACC_PARALLEL_MASK): Add PRAGMA_OACC_CLAUSE_{DEFAULT,PRIVATE,
851 FIRSTPRIVATE}.
852 (c_parser_omp_all_clauses): Update call to c_parser_omp_clause_default.
853 (c_parser_oacc_update): Update the error message for missing clauses.
854 * c-typeck.c (c_finish_omp_clauses): Add support for OMP_CLAUSE_TILE
855 and OMP_CLAUSE_INDEPENDENT.
856
857 2015-11-05 Marek Polacek <polacek@redhat.com>
858
859 PR c/68090
860 * c-parser.c (c_parser_postfix_expression_after_paren_type): Don't
861 deal with pre-evaluation on invalid types.
862
863 2015-11-05 Jakub Jelinek <jakub@redhat.com>
864 Ilya Verbin <ilya.verbin@intel.com>
865
866 * c-parser.c: Include context.h and gimple-expr.h.
867 (c_parser_omp_clause_schedule): Parse schedule modifiers, diagnose
868 monotonic together with nonmonotonic.
869 (c_parser_omp_for_loop): Call c_omp_check_loop_iv. Call add_stmt here.
870 (OMP_DISTRIBUTE_CLAUSE_MASK): Add lastprivate clause.
871 (c_parser_omp_target_data, c_parser_omp_target_enter_data,
872 c_parser_omp_target_exit_data): Allow GOMP_MAP_ALWAYS_POINTER.
873 (c_parser_omp_target): Likewise. Evaluate num_teams and thread_limit
874 expressions on combined target teams before the target.
875 (c_parser_omp_declare_target): If decl has "omp declare target" or
876 "omp declare target link" attribute, and cgraph or varpool node already
877 exists, then set corresponding flags. Call c_finish_omp_clauses
878 in the parenthesized extended-list syntax case.
879 * c-decl.c (c_decl_attributes): Don't diagnose block scope vars inside
880 declare target.
881 * c-typeck.c (handle_omp_array_sections_1): Allow non-zero low-bound
882 on OMP_CLAUSE_REDUCTION array sections.
883 (handle_omp_array_sections): Encode low-bound into the MEM_REF, either
884 into the constant offset, or for variable low-bound using
885 POINTER_PLUS_EXPR. For structure element based array sections use
886 GOMP_MAP_ALWAYS_POINTER instead of GOMP_MAP_FIRSTPRIVATE_POINTER.
887 (c_finish_omp_clauses): Drop generic_field_head, structure
888 elements are now always mapped even as array section bases,
889 diagnose same var in data sharing and mapping clauses. Diagnose if
890 linear step on declare simd is neither a constant nor a uniform
891 parameter. Look through POINTER_PLUS_EXPR for array section
892 reductions. Diagnose the same var or function appearing multiple
893 times on the same directive. Fix up wording for the to clause if t
894 is neither a FUNCTION_DECL nor a VAR_DECL. Diagnose nonmonotonic
895 modifier on kinds other than dynamic or guided or nonmonotonic
896 modifier together with ordered clause.
897
898 2015-11-03 Thomas Schwinge <thomas@codesourcery.com>
899 Chung-Lin Tang <cltang@codesourcery.com>
900
901 * c-parser.c (c_parser_omp_construct): Handle PRAGMA_OACC_ATOMIC.
902
903 2015-10-29 Andrew MacLeod <amacleod@redhat.com>
904
905 * c-array-notation.c: Reorder #include's and remove duplicates.
906 * c-aux-info.c: Likewise.
907 * c-convert.c: Likewise.
908 * c-decl.c: Likewise.
909 * c-errors.c: Likewise.
910 * c-lang.c: Likewise.
911 * c-objc-common.c: Likewise.
912 * c-parser.c: Likewise.
913 * c-typeck.c: Likewise.
914
915 2015-10-26 Jim Wilson <jim.wilson@linaro.org>
916
917 PR debug/66068
918 * c-typeck.c (c_build_qualified_type): Clear C_TYPE_INCOMPLETE_VARS
919 after calling build_qualified_type.
920
921 2015-10-27 Cesar Philippidis <cesar@codesourcery.com>
922 Thomas Schwinge <thomas@codesourcery.com>
923 James Norris <jnorris@codesourcery.com>
924 Joseph Myers <joseph@codesourcery.com>
925 Julian Brown <julian@codesourcery.com>
926 Bernd Schmidt <bschmidt@redhat.com>
927
928 * c-parser.c (c_parser_oacc_shape_clause): New.
929 (c_parser_oacc_simple_clause): New.
930 (c_parser_oacc_all_clauses): Add auto, gang, seq, vector, worker.
931 (OACC_LOOP_CLAUSE_MASK): Add gang, worker, vector, auto, seq.
932
933 2015-10-27 Thomas Schwinge <thomas@codesourcery.com>
934 James Norris <jnorris@codesourcery.com>
935 Cesar Philippidis <cesar@codesourcery.com>
936
937 PR c/64765
938 PR c/64880
939 * c-parser.c (c_parser_oacc_loop): Add mask, cclauses formal
940 parameters, and handle these. Adjust all users.
941 (c_parser_oacc_kernels, c_parser_oacc_parallel): Merge functions
942 into...
943 (c_parser_oacc_kernels_parallel): ... this new function. Adjust
944 all users.
945 * c-tree.h (c_finish_oacc_parallel, c_finish_oacc_kernels): Don't
946 declare functions.
947 (c_finish_omp_construct): Declare function.
948 * c-typeck.c (c_finish_oacc_parallel, c_finish_oacc_kernels):
949 Merge functions into...
950 (c_finish_omp_construct): ... this new function.
951
952 2015-10-22 Richard Biener <rguenther@suse.de>
953
954 * c-typeck.c (c_finish_omp_clauses): Properly convert operands
955 before folding a MINUS_EXPR.
956
957 2015-10-21 Marek Polacek <polacek@redhat.com>
958
959 PR c/68024
960 * c-decl.c (start_function): Warn about vararg functions without
961 a prototype.
962
963 2015-10-21 Ilya Enkovich <enkovich.gnu@gmail.com>
964
965 * c-typeck.c (build_conditional_expr): Use boolean vector
966 type for vector comparison.
967 (build_vec_cmp): New.
968 (build_binary_op): Use build_vec_cmp for comparison.
969
970 2015-10-20 Marek Polacek <polacek@redhat.com>
971
972 * c-parser.c (is_cilkplus_vector_p): Don't define here.
973
974 2015-10-20 Marek Polacek <polacek@redhat.com>
975
976 PR c/67964
977 * c-parser.c (c_parser_attributes): Break out of the loop if the
978 token after an attribute isn't a comma.
979
980 2015-10-13 Jakub Jelinek <jakub@redhat.com>
981 Aldy Hernandez <aldyh@redhat.com>
982
983 * c-parser.c (c_parser_pragma): Handle PRAGMA_OMP_ORDERED here.
984 (c_parser_omp_clause_name): Handle OpenMP 4.5 clauses.
985 (c_parser_omp_variable_list): Handle structure elements for
986 map, to and from clauses. Handle array sections in reduction
987 clause. Formatting fixes.
988 (c_parser_omp_clause_if): Add IS_OMP argument, handle parsing of
989 if clause modifiers.
990 (c_parser_omp_clause_num_tasks, c_parser_omp_clause_grainsize,
991 c_parser_omp_clause_priority, c_parser_omp_clause_hint,
992 c_parser_omp_clause_defaultmap, c_parser_omp_clause_use_device_ptr,
993 c_parser_omp_clause_is_device_ptr): New functions.
994 (c_parser_omp_clause_ordered): Parse optional parameter.
995 (c_parser_omp_clause_reduction): Handle array reductions.
996 (c_parser_omp_clause_schedule): Parse optional simd modifier.
997 (c_parser_omp_clause_nogroup, c_parser_omp_clause_orderedkind): New
998 functions.
999 (c_parser_omp_clause_linear): Parse linear clause modifiers.
1000 (c_parser_omp_clause_depend_sink): New function.
1001 (c_parser_omp_clause_depend): Parse source/sink depend kinds.
1002 (c_parser_omp_clause_map): Parse release/delete map kinds and
1003 optional always modifier.
1004 (c_parser_oacc_all_clauses): Adjust c_parser_omp_clause_if
1005 and c_finish_omp_clauses callers.
1006 (c_parser_omp_all_clauses): Likewise. Parse OpenMP 4.5 clauses.
1007 Parse "to" as OMP_CLAUSE_TO_DECLARE if on declare target directive.
1008 (c_parser_oacc_cache): Adjust c_finish_omp_clauses caller.
1009 (OMP_CRITICAL_CLAUSE_MASK): Define.
1010 (c_parser_omp_critical): Parse critical clauses.
1011 (c_parser_omp_for_loop): Handle doacross loops, adjust
1012 c_finish_omp_for and c_finish_omp_clauses callers.
1013 (OMP_SIMD_CLAUSE_MASK): Add simdlen clause.
1014 (c_parser_omp_simd): Allow ordered clause if it has no parameter.
1015 (OMP_FOR_CLAUSE_MASK): Add linear clause.
1016 (c_parser_omp_for): Disallow ordered clause when combined with
1017 distribute. Disallow linear clause when combined with distribute
1018 and not combined with simd.
1019 (OMP_ORDERED_CLAUSE_MASK, OMP_ORDERED_DEPEND_CLAUSE_MASK): Define.
1020 (c_parser_omp_ordered): Add CONTEXT argument, remove LOC argument,
1021 parse clauses and if depend clause is found, don't parse a body.
1022 (c_parser_omp_parallel): Disallow copyin clause on target parallel.
1023 Allow target parallel without for after it.
1024 (OMP_TASK_CLAUSE_MASK): Add priority clause.
1025 (OMP_TARGET_DATA_CLAUSE_MASK): Add use_device_ptr clause.
1026 (c_parser_omp_target_data): Diagnose no map clauses or clauses with
1027 invalid kinds.
1028 (OMP_TARGET_UPDATE_CLAUSE_MASK): Add depend and nowait clauses.
1029 (OMP_TARGET_ENTER_DATA_CLAUSE_MASK,
1030 OMP_TARGET_EXIT_DATA_CLAUSE_MASK): Define.
1031 (c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): New
1032 functions.
1033 (OMP_TARGET_CLAUSE_MASK): Add depend, nowait, private, firstprivate,
1034 defaultmap and is_device_ptr clauses.
1035 (c_parser_omp_target): Parse target parallel and target simd. Set
1036 OMP_TARGET_COMBINED on combined constructs. Parse target enter data
1037 and target exit data. Diagnose invalid map kinds.
1038 (OMP_DECLARE_TARGET_CLAUSE_MASK): Define.
1039 (c_parser_omp_declare_target): Parse OpenMP 4.5 forms of this
1040 construct.
1041 (c_parser_omp_declare_reduction): Use STRIP_NOPS when checking for
1042 &omp_priv.
1043 (OMP_TASKLOOP_CLAUSE_MASK): Define.
1044 (c_parser_omp_taskloop): New function.
1045 (c_parser_omp_construct): Don't handle PRAGMA_OMP_ORDERED here,
1046 handle PRAGMA_OMP_TASKLOOP.
1047 (c_parser_cilk_for): Adjust c_finish_omp_clauses callers.
1048 * c-tree.h (c_finish_omp_clauses): Add two new arguments.
1049 * c-typeck.c (handle_omp_array_sections_1): Fix comment typo.
1050 Add IS_OMP argument, handle structure element bases, diagnose
1051 bitfields, pass IS_OMP recursively, diagnose known zero length
1052 array sections in depend clauses, handle array sections in reduction
1053 clause, diagnose negative length even for pointers.
1054 (handle_omp_array_sections): Add IS_OMP argument, use auto_vec for
1055 types, pass IS_OMP down to handle_omp_array_sections_1, handle
1056 array sections in reduction clause, set
1057 OMP_CLAUSE_MAP_MAYBE_ZERO_LENGTH_ARRAY_SECTION if map could be zero
1058 length array section, use GOMP_MAP_FIRSTPRIVATE_POINTER for IS_OMP.
1059 (c_finish_omp_clauses): Add IS_OMP and DECLARE_SIMD arguments.
1060 Handle new OpenMP 4.5 clauses and new restrictions for the old ones.
1061
1062 2015-10-06 Marek Polacek <polacek@redhat.com>
1063
1064 * c-parser.c (c_parser_statement_after_labels): Use
1065 protected_set_expr_location.
1066 (c_parser_omp_clause_num_gangs): Likewise.
1067 (c_parser_omp_clause_num_threads): Likewise.
1068 (c_parser_omp_clause_num_workers): Likewise.
1069 (c_parser_omp_clause_vector_length): Likewise.
1070 (c_parser_omp_clause_num_teams): Likewise.
1071 (c_parser_omp_clause_thread_limit): Likewise.
1072 * c-typeck.c (build_c_cast): Likewise.
1073 (c_cast_expr): Likewise.
1074
1075 2015-10-05 Richard Sandiford <richard.sandiford@arm.com>
1076
1077 * c-typeck.c (c_tree_equal): Use real_equal instead of
1078 REAL_VALUES_EQUAL.
1079
1080 2015-10-04 Jason Merrill <jason@redhat.com>
1081
1082 * c-parser.c (c_lex_one_token): Handle @synchronized.
1083 * c-decl.c (match_builtin_function_types): A declaration of a built-in
1084 can change whether the function is transaction_safe.
1085
1086 2015-10-02 Marek Polacek <polacek@redhat.com>
1087
1088 PR c/67730
1089 * c-typeck.c (convert_for_assignment): Use the expansion point
1090 location throughout.
1091
1092 2015-10-02 Marek Polacek <polacek@redhat.com>
1093
1094 PR c/64249
1095 * c-parser.c (c_parser_statement_after_labels): Add CHAIN parameter
1096 and pass it down to c_parser_if_statement.
1097 (c_parser_else_body): Add CHAIN parameter and pass it down to
1098 c_parser_statement_after_labels.
1099 (c_parser_if_statement): Add CHAIN parameter. Add code to warn about
1100 duplicated if-else-if conditions.
1101
1102 2015-10-01 Marek Polacek <polacek@redhat.com>
1103
1104 * c-typeck.c (convert_for_assignment): Improve commentary.
1105
1106 2015-09-30 Marek Polacek <polacek@redhat.com>
1107
1108 PR c/67730
1109 * c-typeck.c (c_finish_return): Use the expansion point location for
1110 certain "return with value" warnings.
1111
1112 2015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
1113
1114 * c-parser.c (pragma_lex): Add loc argument.
1115
1116 2015-09-15 Marek Polacek <polacek@redhat.com>
1117
1118 PR c/67580
1119 * c-decl.c (tag_exists_p): New function.
1120 * c-parser.c (c_parser_declaration_or_fndef): Give a hint when
1121 struct/union/enum keywords are missing.
1122 * c-tree.h (tag_exists_p): Declare.
1123
1124 2015-09-15 Marek Polacek <polacek@redhat.com>
1125
1126 * c-decl.c (lookup_label): Return NULL_TREE instead of 0.
1127 (lookup_tag): Change the type of THISLEVEL_ONLY to bool.
1128 Return NULL_TREE instead of 0.
1129 (lookup_name): Return NULL_TREE instead of 0.
1130 (lookup_name_in_scope): Likewise.
1131 (shadow_tag_warned): Use true instead of 1 and NULL_TREE instead of 0.
1132 (parser_xref_tag): Use false instead of 0.
1133 (start_struct): Use true instead of 1.
1134 (start_enum): Use true instead of 1 and NULL_TREE instead of 0.
1135
1136 2015-09-14 Marek Polacek <polacek@redhat.com>
1137
1138 * c-typeck.c (set_nonincremental_init_from_string): Use
1139 HOST_WIDE_INT_M1U when shifting a negative value.
1140
1141 2015-09-09 Mark Wielaard <mjw@redhat.com>
1142
1143 * c-typeck.c (build_binary_op): Check and warn when nonnull arg
1144 parm against NULL.
1145
1146 2015-09-10 Jakub Jelinek <jakub@redhat.com>
1147
1148 PR c/67502
1149 * c-parser.c (c_parser_omp_for_loop): Emit DECL_EXPR stmts
1150 into OMP_FOR_PRE_BODY rather than before the loop.
1151
1152 2015-09-09 Jakub Jelinek <jakub@redhat.com>
1153
1154 PR c/67501
1155 * c-parser.c (c_parser_oacc_all_clauses,
1156 c_parser_omp_all_clauses): Remove invalid clause from
1157 list of clauses even if parser->error is set.
1158
1159 PR c/67500
1160 * c-parser.c (c_parser_omp_clause_aligned,
1161 c_parser_omp_clause_safelen, c_parser_omp_clause_simdlen): Fix up
1162 test for errors.
1163 * c-decl.c (temp_pop_parm_decls): Allow b->decl equal to
1164 error_mark_node.
1165
1166 PR c/67495
1167 * c-parser.c (c_parser_omp_atomic): Use c_parser_cast_expression
1168 instead of c_parser_unary_expression. If the result is !lvalue_p,
1169 wrap the result of c_fully_fold into NON_LVALUE_EXPR.
1170
1171 2015-09-04 Marek Polacek <polacek@redhat.com>
1172
1173 PR sanitizer/67279
1174 * c-typeck.c (build_binary_op): Don't instrument static initializers.
1175
1176 2015-09-03 Martin Sebor <msebor@redhat.com>
1177
1178 PR c/66516
1179 * c-typeck.c (convert_arguments, parser_build_unary_op,
1180 build_conditional_expr, c_cast_expr, convert_for_assignment,
1181 build_binary_op, _objc_common_truthvalue_conversion): Call
1182 reject_gcc_builtin.
1183 (c_decl_implicit): Define.
1184
1185 2015-09-02 Marek Polacek <polacek@redhat.com>
1186
1187 PR c/67432
1188 * c-parser.c (c_parser_enum_specifier): Give a better error for
1189 an empty enum.
1190
1191 2015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
1192
1193 * c-aux-info.c, c-parser.c, c-tree.h: Remove useless typedefs.
1194
1195 2015-08-12 Marek Polacek <polacek@redhat.com>
1196
1197 * c-decl.c (grokdeclarator): Call error_at instead of error and pass
1198 LOC to it.
1199
1200 2015-08-03 Marek Polacek <polacek@redhat.com>
1201
1202 PR c/67088
1203 * c-decl.c (check_bitfield_type_and_width): Add location parameter.
1204 Use it.
1205 (grokdeclarator): Pass LOC down to check_bitfield_type_and_width.
1206
1207 2015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
1208
1209 * c-parser.c (c_parser_if_body): Take token_indent_info
1210 argument. Call warn_for_misleading_indentation even when the
1211 body is a semicolon. Extract token_indent_infos corresponding
1212 to the guard, body and next tokens. Adjust call to
1213 warn_for_misleading_indentation accordingly.
1214 (c_parser_else_body): Likewise.
1215 (c_parser_if_statement): Likewise.
1216 (c_parser_while_statement): Likewise.
1217 (c_parser_for_statement): Likewise.
1218
1219 2015-07-28 Luis Felipe Strano Moraes <luis.strano@gmail.com>
1220 Manuel López-Ibáñez <manu@gcc.gnu.org>
1221
1222 * c-decl.c (get_parm_info): Remove static var. Update warning
1223 message.
1224
1225 2015-07-27 Marek Polacek <polacek@redhat.com>
1226
1227 PR c++/66555
1228 PR c/54979
1229 * c-typeck.c (parser_build_binary_op): Call warn_tautological_cmp.
1230
1231 2015-07-20 Marek Polacek <polacek@redhat.com>
1232
1233 PR c++/55095
1234 * c-typeck.c (digest_init): Pass OPT_Wpedantic to pedwarn_init.
1235 (build_binary_op): Warn about left shift overflows.
1236
1237 2015-07-09 Andrew MacLeod <amacleod@redhat.com>
1238
1239 * c-array-notation.c: Adjust includes for flags.h changes.
1240 * c-objc-common.c: Likewise.
1241
1242 2015-07-07 Andrew MacLeod <amacleod@redhat.com>
1243
1244 * c-array-notation.c: Adjust includes.
1245 * c-aux-info.c: Likewise.
1246 * c-convert.c: Likewise.
1247 * c-decl.c: Likewise.
1248 * c-errors.c: Likewise.
1249 * c-lang.c: Likewise.
1250 * c-objc-common.c: Likewise.
1251 * c-parser.c: Likewise.
1252 * c-typeck.c: Likewise.
1253
1254 2015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
1255
1256 PR fortran/66605
1257 * c-decl.c (finish_function): Call do_warn_unused_parameter.
1258
1259 2015-06-29 Marek Polacek <polacek@redhat.com>
1260
1261 PR c/66322
1262 * c-typeck.c (struct c_switch): Add BOOL_COND_P and OUTSIDE_RANGE_P.
1263 (c_start_case): Set BOOL_COND_P and OUTSIDE_RANGE_P. Don't warn
1264 about -Wswitch-bool here.
1265 (do_case): Update c_add_case_label call.
1266 (c_finish_case): Update c_do_switch_warnings call.
1267
1268 2015-06-27 Marek Polacek <polacek@redhat.com>
1269
1270 * c-typeck.c: Use VECTOR_TYPE_P throughout.
1271
1272 2015-06-26 Marek Polacek <polacek@redhat.com>
1273
1274 * c-array-notation.c (fix_builtin_array_notation_fn): Use
1275 INDIRECT_REF_P.
1276 * c-typeck.c (array_to_pointer_conversion): Likewise.
1277 (build_unary_op): Likewise.
1278 (c_finish_return): Likewise.
1279
1280 2015-06-25 Andrew MacLeod <amacleod@redhat.com>
1281
1282 * c-decl.c: Remove ipa-ref.h and plugin-api.h from include list.
1283 * c-parser.c: Likewise.
1284
1285 2015-06-25 Richard Sandiford <richard.sandiford@arm.com>
1286
1287 * c-decl.c (detect_field_duplicates_hash): Use nofree_ptr_hash
1288 instead of pointer_hash.
1289 (detect_field_duplicates): Likewise.
1290
1291 2015-06-25 Marek Polacek <polacek@redhat.com>
1292
1293 * c-array-notation.c: Use VAR_P throughout.
1294 * c-decl.c: Likewise.
1295 * c-objc-common.c: Likewise.
1296 * c-parser.c: Likewise.
1297 * c-typeck.c: Likewise.
1298
1299 2015-06-25 Marek Polacek <polacek@redhat.com>
1300
1301 * c-decl.c: Use is_global_var throughout.
1302 * c-parser.c: Likewise.
1303 * c-typeck.c: Likewise.
1304
1305 2015-06-17 Andrew MacLeod <amacleod@redhat.com>
1306
1307 * c-array-notation.c: Do not include input.h, line-map.h or is-a.h.
1308 * c-aux-info.c: Likewise.
1309 * c-convert.c: Likewise.
1310 * c-decl.c: Likewise.
1311 * c-errors.c: Likewise.
1312 * c-lang.c: Likewise.
1313 * c-objc-common.c: Likewise.
1314 * c-parser.c: Likewise.
1315 * c-typeck.c: Likewise.
1316
1317 2015-06-11 Jan Hubicka <hubicka@ucw.cz>
1318
1319 PR middle-end/66325
1320 * c-decl.c (start_enum): Set TYPE_PACKED consistently among type
1321 variants.
1322
1323 2015-06-11 Pierre-Marie de Rodat <derodat@adacore.com>
1324
1325 * c-decl.c (pop_scope): Register the main translation unit
1326 through the new debug hook.
1327
1328 2015-06-08 Andrew MacLeod <amacleod@redhat.com>
1329
1330 * c-array-notation.c : Adjust include files.
1331 * c-aux-info.c : Likewise.
1332 * c-convert.c : Likewise.
1333 * c-decl.c : Likewise.
1334 * c-errors.c : Likewise.
1335 * c-lang.c : Likewise.
1336 * c-lang.h : Likewise.
1337 * c-objc-common.c : Likewise.
1338 * c-parser.c : Likewise.
1339 * c-typeck.c : Likewise.
1340
1341 2015-06-05 Aldy Hernandez <aldyh@redhat.com>
1342
1343 * c-decl.c (finish_struct): Save C_TYPE_INCOMPLETE_VARS and
1344 immediately clobber it.
1345 (c_write_global_declarations_1): Remove call to
1346 check_global_declaration_1.
1347 (c_write_global_declarations_2): Remove.
1348 (c_write_final_cleanups): Rename from c_write_global_declarations.
1349 Remove call to finalize_compilation_unit.
1350 Remove calls to debugging hooks.
1351 * c-objc-common.c: Adjust comment for c_warn_unused_global_decl.
1352 * c-objc-common.h: Remove LANG_HOOKS_WRITE_GLOBALS.
1353 * c-tree.h: Remove c_write_global_declarations.
1354
1355 2015-06-04 Andrew MacLeod <amacleod@redhat.com>
1356
1357 * c-array-notation.c: Adjust includes for restructured coretypes.h.
1358 * c-aux-info.c: Likewise.
1359 * c-convert.c: Likewise.
1360 * c-decl.c: Likewise.
1361 * c-errors.c: Likewise.
1362 * c-lang.c: Likewise.
1363 * c-objc-common.c: Likewise.
1364 * c-parser.c: Likewise.
1365 * c-typeck.c: Likewise.
1366
1367 2015-06-04 Marek Polacek <polacek@redhat.com>
1368
1369 PR c/66341
1370 * c-typeck.c (build_c_cast): Wrap VALUE into NON_LVALUE_EXPR if
1371 it is a lvalue.
1372
1373 2015-06-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1374
1375 * c-decl.c (warn_cxx_compat_finish_struct): New parameters code, record_loc.
1376 Warn for empty struct.
1377 (finish_struct): Pass TREE_CODE(t) and loc to warn_cxx_compat_finish_struct.
1378
1379 2015-06-02 Andres Tiraboschi <andres.tiraboschi@tallertechnologies.com>
1380
1381 * c-decl.c (start_function): Call plugin before parsing.
1382 (finish_function): Call plugin after parsing.
1383
1384 2015-06-02 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1385
1386 PR c/49551
1387 * c-decl.c (merge_decls): Merge DECL_COMMON.
1388
1389 2015-05-22 Jim Wilson <jim.wilson@linaro.org>
1390
1391 * Make-lang.in (check_gcc_pallelize): Define.
1392
1393 2015-05-22 Marek Polacek <polacek@redhat.com>
1394
1395 PR c/47043
1396 * c-parser.c (c_parser_enum_specifier): Parse and apply enumerator
1397 attributes.
1398
1399 2015-05-21 Marek Polacek <polacek@redhat.com>
1400
1401 * c-typeck.c (inform_declaration): Use DECL_IS_BUILTIN instead of
1402 DECL_BUILT_IN.
1403
1404 2015-05-20 Marek Polacek <polacek@redhat.com>
1405
1406 * c-decl.c: Use VAR_OR_FUNCTION_DECL_P throughout.
1407 * c-typeck.c: Likewise.
1408
1409 2015-05-19 Marek Polacek <polacek@redhat.com>
1410
1411 * c-typeck.c (start_init): Use AGGREGATE_TYPE_P.
1412
1413 2015-05-19 Jakub Jelinek <jakub@redhat.com>
1414
1415 PR middle-end/66199
1416 * c-parser.c (c_parser_omp_for_loop): Don't add
1417 OMP_CLAUSE_SHARED to OMP_PARALLEL_CLAUSES when moving
1418 OMP_CLAUSE_LASTPRIVATE clause to OMP_FOR_CLAUSES.
1419 (c_parser_omp_teams): Set OMP_TEAMS_COMBINED for combined
1420 constructs.
1421
1422 2015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
1423
1424 * c-typeck.c (build_array_ref): Use std::swap instead of explicit
1425 swaps.
1426
1427 2015-05-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
1428
1429 PR fortran/44054
1430 * c-objc-common.c (c_tree_printer): Replace locus pointer with
1431 accessor function.
1432
1433 2015-05-14 Marek Polacek <polacek@redhat.com>
1434
1435 PR c/66066
1436 PR c/66127
1437 * c-typeck.c (digest_init): Call pedwarn_init with OPT_Wpedantic
1438 rather than with 0.
1439
1440 2015-05-12 David Malcolm <dmalcolm@redhat.com>
1441
1442 * c-parser.c (c_parser_if_body): Add param "if_loc", use it
1443 to add a call to warn_for_misleading_indentation.
1444 (c_parser_else_body): Likewise, adding param "else_loc".
1445 (c_parser_if_statement): Check for misleading indentation.
1446 (c_parser_while_statement): Likewise.
1447 (c_parser_for_statement): Likewise.
1448
1449 2015-05-08 Marek Polacek <polacek@redhat.com>
1450
1451 PR c/64918
1452 * c-typeck.c (add_pending_init): Use OPT_Woverride_init_side_effects.
1453 (output_init_element): Likewise.
1454
1455 2015-05-07 Marek Polacek <polacek@redhat.com>
1456
1457 PR c/65179
1458 * c-typeck.c (build_binary_op): Warn when left shifting a negative
1459 value.
1460
1461 2015-04-30 Marek Polacek <polacek@redhat.com>
1462
1463 * c-typeck.c (set_init_label): Call error_at instead of error and
1464 pass LOC to it.
1465
1466 * c-typeck.c (c_incomplete_type_error): Refactor to use %qT. Print
1467 the type of a decl.
1468
1469 * c-typeck.c (c_build_va_arg): Clarify the error message.
1470
1471 2015-04-29 Thomas Schwinge <thomas@codesourcery.com>
1472
1473 * c-parser.c (c_parser_oacc_enter_exit_data): Use
1474 OMP_STANDALONE_CLAUSES.
1475
1476 2015-04-28 Marek Polacek <polacek@redhat.com>
1477
1478 * c-parser.c (c_parser_binary_expression): Remove duplicate line.
1479
1480 2015-04-28 Marek Polacek <polacek@redhat.com>
1481
1482 PR c/65901
1483 * c-typeck.c (c_build_va_arg): Require TYPE be a complete type.
1484
1485 2015-04-25 Marek Polacek <polacek@redhat.com>
1486
1487 PR c/52085
1488 * c-decl.c (finish_enum): Copy over TYPE_ALIGN. Also check for "mode"
1489 attribute.
1490
1491 2015-04-23 Marek Polacek <polacek@redhat.com>
1492
1493 PR c/65345
1494 * c-decl.c (set_labels_context_r): New function.
1495 (store_parm_decls): Call it via walk_tree_without_duplicates.
1496 * c-typeck.c (convert_lvalue_to_rvalue): Use create_tmp_var_raw
1497 instead of create_tmp_var. Build TARGET_EXPR instead of
1498 COMPOUND_EXPR.
1499 (build_atomic_assign): Use create_tmp_var_raw instead of
1500 create_tmp_var. Build TARGET_EXPRs instead of MODIFY_EXPR.
1501
1502 2015-04-20 Ilya Verbin <ilya.verbin@intel.com>
1503
1504 * c-parser.c (c_parser_oacc_enter_exit_data): Remove excess semicolon.
1505 (c_parser_omp_target_update): Add missed %> to error_at ().
1506
1507 2015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
1508
1509 PR target/55143
1510 * c-decl.c (c_default_pointer_mode): Remove definition.
1511 * c-tree.h (c_default_pointer_mode): Remove declaration.
1512
1513 2015-03-27 Tobias Burnus <burnus@net-b.de>
1514
1515 PR c/65586
1516 * c-parser.c (c_parser_skip_to_pragma_eol): Optionally, don't
1517 error out.
1518 (c_parser_omp_for, c_parser_omp_parallel, c_parser_omp_distribute,
1519 c_parser_omp_teams, c_parser_omp_target, c_parser_omp_declare):
1520 Update calls to not error for skipped omp pragmas with -fopenmp-simd.
1521
1522 2015-03-19 Jakub Jelinek <jakub@redhat.com>
1523
1524 * c-decl.c (c_decl_attributes): Also add "omp declare target"
1525 attribute for DECL_EXTERNAL VAR_DECLs.
1526
1527 2015-03-11 Jakub Jelinek <jakub@redhat.com>
1528
1529 * c-parser.c (c_parse_init): Don't call xstrdup on get_identifier
1530 argument.
1531
1532 2015-03-10 Jakub Jelinek <jakub@redhat.com>
1533
1534 PR c/65120
1535 * c-typeck.c (parser_build_binary_op): Check for tcc_comparison
1536 before preparing arguments to warn_logical_not_parentheses.
1537
1538 2015-03-09 Jakub Jelinek <jakub@redhat.com>
1539
1540 PR c/65120
1541 * c-typeck.c (parser_build_binary_op): Don't warn for
1542 !!x == y or !b == y where b is _Bool.
1543
1544 2015-03-09 Marek Polacek <polacek@redhat.com>
1545
1546 * c-convert.c (convert): Make use of do_ubsan_in_current_function.
1547 * c-decl.c (grokdeclarator): Likewise.
1548 * c-typeck.c (build_binary_op): Likewise.
1549
1550 2015-02-27 Marek Polacek <polacek@redhat.com>
1551
1552 PR c/65228
1553 * c-decl.c (start_decl): Return NULL_TREE if decl is an error node.
1554
1555 2015-02-14 Marek Polacek <polacek@redhat.com>
1556
1557 PR c/64768
1558 * c-decl.c (grokdeclarator): Set the range of a flexible array member
1559 declared through a typedef name.
1560
1561 2015-02-13 Marek Polacek <polacek@redhat.com>
1562
1563 PR c/65050
1564 * c-decl.c (grokdeclarator): Print also the type when giving
1565 the error message about array's incomplete element type.
1566
1567 2015-02-11 Jakub Jelinek <jakub@redhat.com>
1568
1569 PR c/64824
1570 * c-parser.c (c_parser_binary_expression): Fix OpenMP stack[sp].prec
1571 check in the POP macro.
1572
1573 2015-02-09 Marek Polacek <polacek@redhat.com>
1574
1575 PR c/64856
1576 * c-typeck.c (process_init_element): Don't always wrap
1577 COMPOUND_LITERAL_EXPR in a SAVE_EXPR in C99 mode when
1578 initializing a range of elements.
1579
1580 2015-02-04 Jakub Jelinek <jakub@redhat.com>
1581
1582 PR c/64824
1583 PR c/64868
1584 * c-parser.c (c_parser_omp_atomic): Handle RDIV_EXPR.
1585
1586 2015-02-02 Bruno Loff <bruno.loff@gmail.com>
1587
1588 * c-parser.c (c_parser_declspecs): Call invoke_plugin_callbacks after
1589 processing enum declaration.
1590
1591 2015-01-29 Marek Polacek <polacek@redhat.com>
1592
1593 PR c/64709
1594 * c-typeck.c (pop_init_level): If constructor_elements has
1595 exactly one element with integer_zerop value, set constructor_zeroinit
1596 to 1. Remove braces around warning_init call.
1597
1598 2015-01-27 Jakub Jelinek <jakub@redhat.com>
1599
1600 PR c/64766
1601 * c-typeck.c (store_init_value): Don't overwrite DECL_INITIAL
1602 of FUNCTION_DECLs with error_mark_node.
1603
1604 2015-01-26 Jakub Jelinek <jakub@redhat.com>
1605
1606 PR c/64778
1607 * c-typeck.c (convert_arguments): Return -1 if there are
1608 error_args, even if we've diagnosed too many arguments.
1609
1610 2015-01-21 Richard Biener <rguenther@suse.de>
1611
1612 PR middle-end/64313
1613 * c-decl.c (merge_decls): Call set_builtin_decl_declared_p
1614 for builtins the user declared correctly.
1615
1616 2015-01-15 Thomas Schwinge <thomas@codesourcery.com>
1617 Bernd Schmidt <bernds@codesourcery.com>
1618 Cesar Philippidis <cesar@codesourcery.com>
1619 James Norris <jnorris@codesourcery.com>
1620 Jakub Jelinek <jakub@redhat.com>
1621 Ilmir Usmanov <i.usmanov@samsung.com>
1622
1623 * c-parser.c: Include "gomp-constants.h".
1624 (c_parser_omp_clause_map): Use enum gomp_map_kind instead of enum
1625 omp_clause_map_kind. Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.
1626 Use OMP_CLAUSE_SET_MAP_KIND.
1627 (c_parser_pragma): Handle PRAGMA_OACC_ENTER_DATA,
1628 PRAGMA_OACC_EXIT_DATA, PRAGMA_OACC_UPDATE.
1629 (c_parser_omp_construct): Handle PRAGMA_OACC_CACHE,
1630 PRAGMA_OACC_DATA, PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP,
1631 PRAGMA_OACC_PARALLEL, PRAGMA_OACC_WAIT.
1632 (c_parser_omp_clause_name): Handle "auto", "async", "copy",
1633 "copyout", "create", "delete", "deviceptr", "gang", "host",
1634 "num_gangs", "num_workers", "present", "present_or_copy", "pcopy",
1635 "present_or_copyin", "pcopyin", "present_or_copyout", "pcopyout",
1636 "present_or_create", "pcreate", "seq", "self", "vector",
1637 "vector_length", "wait", "worker".
1638 (OACC_DATA_CLAUSE_MASK, OACC_KERNELS_CLAUSE_MASK)
1639 (OACC_ENTER_DATA_CLAUSE_MASK, OACC_EXIT_DATA_CLAUSE_MASK)
1640 (OACC_LOOP_CLAUSE_MASK, OACC_PARALLEL_CLAUSE_MASK)
1641 (OACC_UPDATE_CLAUSE_MASK, OACC_WAIT_CLAUSE_MASK): New macros.
1642 (c_parser_omp_variable_list): Handle OMP_CLAUSE__CACHE_.
1643 (c_parser_oacc_wait_list, c_parser_oacc_data_clause)
1644 (c_parser_oacc_data_clause_deviceptr)
1645 (c_parser_omp_clause_num_gangs, c_parser_omp_clause_num_workers)
1646 (c_parser_oacc_clause_async, c_parser_oacc_clause_wait)
1647 (c_parser_omp_clause_vector_length, c_parser_oacc_all_clauses)
1648 (c_parser_oacc_cache, c_parser_oacc_data, c_parser_oacc_kernels)
1649 (c_parser_oacc_enter_exit_data, c_parser_oacc_loop)
1650 (c_parser_oacc_parallel, c_parser_oacc_update)
1651 (c_parser_oacc_wait): New functions.
1652 * c-tree.h (c_finish_oacc_parallel, c_finish_oacc_kernels)
1653 (c_finish_oacc_data): New prototypes.
1654 * c-typeck.c: Include "gomp-constants.h".
1655 (handle_omp_array_sections): Handle GOMP_MAP_FORCE_DEVICEPTR. Use
1656 GOMP_MAP_* instead of OMP_CLAUSE_MAP_*. Use
1657 OMP_CLAUSE_SET_MAP_KIND.
1658 (c_finish_oacc_parallel, c_finish_oacc_kernels)
1659 (c_finish_oacc_data): New functions.
1660 (c_finish_omp_clauses): Handle OMP_CLAUSE__CACHE_,
1661 OMP_CLAUSE_NUM_GANGS, OMP_CLAUSE_NUM_WORKERS,
1662 OMP_CLAUSE_VECTOR_LENGTH, OMP_CLAUSE_ASYNC, OMP_CLAUSE_WAIT,
1663 OMP_CLAUSE_AUTO, OMP_CLAUSE_SEQ, OMP_CLAUSE_GANG,
1664 OMP_CLAUSE_WORKER, OMP_CLAUSE_VECTOR, and OMP_CLAUSE_MAP's
1665 GOMP_MAP_FORCE_DEVICEPTR.
1666
1667 2015-01-09 Michael Collison <michael.collison@linaro.org>
1668
1669 * c-array-notation.c: Include hash-set.h, machmode.h,
1670 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
1671 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
1672 * c-aux-info.c: Ditto.
1673 * c-convert.c: Ditto.
1674 * c-decl.c: Ditto.
1675 * c-errors.c: Ditto.
1676 * c-lang.c: Dittoxs.
1677 * c-objc-common.c: Ditto.
1678 * c-parser.c: Ditto.
1679 * c-typeck.c: Include hash-set.h, machmode.h,
1680 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
1681 fold-const.h, wide-int.h, inchash.h, real.h and
1682 fixed-value.h due to flattening of tree.h.
1683
1684 2015-01-07 Marek Polacek <polacek@redhat.com>
1685
1686 PR c/64417
1687 * c-typeck.c (process_init_element): Disallow initialization of
1688 a flexible array member with a string constant if the structure
1689 is in an array.
1690
1691 2015-01-05 Jakub Jelinek <jakub@redhat.com>
1692
1693 PR sanitizer/64344
1694 * c-typeck.c (convert_for_assignment, c_finish_return): For
1695 -fsanitize=float-cast-overflow casts from REAL_TYPE to integer/enum
1696 types also set in_late_binary_op around convert call.
1697 * c-convert.c (convert): For -fsanitize=float-cast-overflow REAL_TYPE
1698 to integral type casts, if not in_late_binary_op, pass c_fully_fold
1699 result on expr as last argument to ubsan_instrument_float_cast,
1700 if in_late_binary_op, don't use c_save_expr but save_expr.
1701
1702 Update copyright years.
1703
1704 2015-01-05 Marek Polacek <polacek@redhat.com>
1705
1706 PR c/64423
1707 * c-typeck.c (build_array_ref): Pass loc down to
1708 warn_array_subscript_with_type_char.
1709
1710 2014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
1711
1712 * c-typeck.c: New behavious for pointers to arrays with qualifiers
1713 (common-pointer-type): For pointers to arrays take qualifiers from
1714 element type.
1715 (build_conditional_expr): Add warnings for lost qualifiers.
1716 (comp-target-types): Allow pointers to arrays with different qualifiers.
1717 (convert-for-assignment): Adapt warnings for discarded qualifiers. Add
1718 WARNING_FOR_QUALIFIERS macro and rename WARN_FOR_QUALIFIERS
1719 to PEDWARN_FOR_QUALIFIERS.
1720
1721 2014-12-17 Jakub Jelinek <jakub@redhat.com>
1722
1723 PR sanitizer/64289
1724 * c-convert.c: Include ubsan.h.
1725 (convert): For real -> integral casts and
1726 -fsanitize=float-cast-overflow don't call convert_to_integer, but
1727 instead instrument the float cast directly.
1728
1729 2014-11-29 Jakub Jelinek <jakub@redhat.com>
1730
1731 * c-typeck.c (convert_lvalue_to_rvalue, build_atomic_assign,
1732 c_finish_stmt_expr): Remove NULL last argument from
1733 create_tmp_var_raw and create_tmp_var calls.
1734 * c-array-notation.c (fix_builtin_array_notation_fn,
1735 build_array_notation_expr, fix_conditional_array_notations_1,
1736 fix_array_notation_expr, fix_array_notation_call_expr): Likewise.
1737
1738 2014-11-28 Marek Polacek <polacek@redhat.com>
1739
1740 PR c/63862
1741 * c-typeck.c (build_binary_op) <RSHIFT_EXPR, LSHIFT_EXPR>: Don't
1742 convert the right operand to integer type.
1743
1744 2014-11-25 Marek Polacek <polacek@redhat.com>
1745
1746 PR c/63877
1747 * c-decl.c (start_function): Disable -Wmissing-declarations warning
1748 for inline functions.
1749
1750 2014-11-21 Jakub Jelinek <jakub@redhat.com>
1751
1752 PR target/63764
1753 * c-typeck.c (build_array_ref): Adjust
1754 convert_vector_to_pointer_for_subscript caller. If it returns true,
1755 call non_lvalue_loc on the result.
1756
1757 2014-11-11 Richard Biener <rguenther@suse.de>
1758
1759 * c-decl.c (c_init_decl_processing): Do not set pedantic_lvalues
1760 to true.
1761
1762 2014-11-10 Andi Kleen <ak@linux.intel.com>
1763
1764 PR c/60804
1765 * c-parser.c (c_parser_statement_after_labels): Call
1766 check_no_cilk.
1767 (c_parser_if_statement): Dito.
1768 (c_parser_switch_statement): Dito.
1769 (c_parser_while_statement): Dito.
1770 (c_parser_do_statement): Dito.
1771 (c_parser_for_statement): Dito.
1772 * c-typeck.c (c_finish_loop): Dito.
1773
1774 2014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
1775
1776 * c-typeck.c (build_binary_op): Use OPT_Wshift_count_negative and
1777 OPT_Wshift_count_overflow in the warnings.
1778
1779 2014-10-30 Marek Polacek <polacek@redhat.com>
1780
1781 * c-objc-common.c (c_tree_printer) <case 'T'>: For a typedef name,
1782 print the stripped version as well, if they're not the same.
1783
1784 2014-10-29 Richard Sandiford <richard.sandiford@arm.com>
1785
1786 * c-decl.c, c-tree.h, c-typeck.c: Remove redundant enum from
1787 machine_mode.
1788
1789 2014-10-28 Andrew MacLeod <amacleod@redhat.com>
1790
1791 * c-decl.c: Adjust include files.
1792 * c-parser.c: Ditto.
1793
1794 2014-10-27 Phil Muldoon <pmuldoon@redhat.com>
1795 Tom Tromey <tromey@redhat.com>
1796
1797 * c-tree.h (enum c_oracle_request): New.
1798 (c_binding_oracle_function): New typedef.
1799 (c_binding_oracle, c_pushtag, c_bind): Declare.
1800 * c-decl.c (c_binding_oracle): New global.
1801 (I_SYMBOL_CHECKED): New macro.
1802 (i_symbol_binding): New function.
1803 (I_SYMBOL_BINDING, I_SYMBOL_DECL): Redefine.
1804 (I_TAG_CHECKED): New macro.
1805 (i_tag_binding): New function.
1806 (I_TAG_BINDING, I_TAG_DECL): Redefine.
1807 (I_LABEL_CHECKED): New macro.
1808 (i_label_binding): New function.
1809 (I_LABEL_BINDING, I_LABEL_DECL): Redefine.
1810 (c_print_identifier): Save and restore c_binding_oracle.
1811 (c_pushtag, c_bind): New functions.
1812
1813 2014-10-27 Andrew MacLeod <amacleod@redhat.com>
1814
1815 * c-typeck.c: Adjust include files.
1816
1817 2014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
1818
1819 PR c++/53061
1820 * c-objc-common.c (c_objc_common_init): Do not do diagnostics
1821 initialization here...
1822 (c_initialize_diagnostics): ... but here. Set defaults after
1823 building pretty-printer.
1824
1825 2014-10-23 Marek Polacek <polacek@redhat.com>
1826
1827 PR c/63626
1828 * c-decl.c (pop_scope): Don't print warning in external_scope.
1829
1830 2014-10-19 Marek Polacek <polacek@redhat.com>
1831
1832 PR c/63567
1833 * c-typeck.c (output_init_element): Allow initializing objects with
1834 static storage duration with compound literals even in C99 and add
1835 pedwarn for it.
1836
1837 2014-10-17 Marek Polacek <polacek@redhat.com>
1838
1839 PR c/63567
1840 * c-typeck.c (digest_init): Allow initializing objects with static
1841 storage duration with compound literals even in C99 and add pedwarn
1842 for it.
1843
1844 2014-10-17 Marek Polacek <polacek@redhat.com>
1845
1846 PR c/63543
1847 * c-tree.h (C_TYPE_ERROR_REPORTED): Define.
1848 * c-typeck.c (build_indirect_ref): Don't print the "dereferencing..."
1849 error multiple times. Print the type.
1850
1851 2014-10-17 Marek Polacek <polacek@redhat.com>
1852
1853 PR c/63549
1854 * c-typeck.c (build_array_ref): Bail if the index in an incomplete
1855 type.
1856
1857 2014-10-17 Marek Polacek <polacek@redhat.com>
1858
1859 * c-decl.c (grokdeclarator): Use OPT_Wimplicit_int unconditionally.
1860 (start_function): Use OPT_Wimplicit_int instead of 0.
1861 (store_parm_decls_oldstyle): Likewise.
1862
1863 2014-10-17 Alan Modra <amodra@gmail.com>
1864
1865 PR middle-end/61848
1866 * c-decl.c (merge_decls): Don't merge section name or tls model
1867 to newdecl symtab node, instead merge to olddecl. Override
1868 existing olddecl section name. Set tls_model for all thread-local
1869 vars, not just OMP thread-private ones. Remove incorrect comment.
1870
1871 2014-10-16 Andrew MacLeod <amacleod@redhat.com>
1872
1873 * c-decl.c: Adjust include files.
1874
1875 2014-10-14 DJ Delorie <dj@redhat.com>
1876
1877 * c-parser.c (c_parse_init): Add RID entries for each __intN.
1878 (c_token_starts_typename): Check all __intN, not just __int128.
1879 (c_token_starts_declspecs): Likewise.
1880 (c_parser_declspecs): Likewise.
1881 (c_parser_attribute_any_word): Likewise.
1882 (c_parser_objc_selector): Likewise.
1883 * c-tree.h (c_typespec_keyword): cts_int128 -> cts_int_n.
1884 (struct c_declspecs): Add int_n_idx field to record *which* __intN
1885 is specified.
1886 * c-decl.c (declspecs_add_type): Check for all __intN, not just
1887 __int128.
1888 (finish_declspecs): Likewise.
1889
1890 2014-10-13 Anthony Brandon <anthony.brandon@gmail.com>
1891
1892 * c-parser.c (c_parser_all_labels): New function to replace
1893 the duplicate code.
1894 (c_parser_statement): Call the new function.
1895
1896 2014-10-09 Marek Polacek <polacek@redhat.com>
1897
1898 PR c/63480
1899 * c-typeck.c (pop_init_level): Don't warn about initializing
1900 with { }.
1901
1902 2014-10-07 Marek Polacek <polacek@redhat.com>
1903
1904 PR c/59717
1905 * c-decl.c (header_for_builtin_fn): New function.
1906 (implicitly_declare): Suggest which header to include.
1907
1908 2014-10-07 Marek Polacek <polacek@redhat.com>
1909
1910 * c-convert.c (convert): Use error_operand_p.
1911 * c-typeck.c (require_complete_type): Likewise.
1912 (really_atomic_lvalue): Likewise.
1913 (digest_init): Likewise.
1914 (handle_omp_array_sections_1): Likewise.
1915
1916 2014-10-03 Marek Polacek <polacek@redhat.com>
1917
1918 PR c/63453
1919 * c-decl.c (pop_scope): Don't warn about "inline function declared
1920 but never defined" for functions marked with gnu_inline attribute.
1921
1922 2014-09-25 Jakub Jelinek <jakub@redhat.com>
1923
1924 PR c++/63249
1925 * c-parser.c (c_parser_omp_variable_list): Call mark_exp_read
1926 on low_bound and length.
1927
1928 2014-09-24 Marek Polacek <polacek@redhat.com>
1929
1930 PR c/61405
1931 PR c/53874
1932 * c-parser.c: Don't define CPP_KEYWORD.
1933 (c_parser_switch_statement): Pass original type to c_finish_case.
1934 * c-tree.h (c_finish_case): Update declaration.
1935 * c-typeck.c (c_finish_case): Add TYPE parameter. Pass it
1936 conditionally to c_do_switch_warnings.
1937
1938 2014-09-03 Marek Polacek <polacek@redhat.com>
1939
1940 PR c/62024
1941 * c-parser.c (c_parser_static_assert_declaration_no_semi): Strip no-op
1942 conversions.
1943
1944 2014-09-02 Jakub Jelinek <jakub@redhat.com>
1945 Balaji V. Iyer <balaji.v.iyer@intel.com>
1946 Igor Zamyatin <igor.zamyatin@intel.com>
1947
1948 * c-parser.c (c_parser_cilk_for): New function.
1949 (c_parser_cilk_grainsize): Likewise.
1950 (c_get_temp_regvar): Likewise.
1951 (c_parser_statement_after_labels): Added RID_CILK_FOR case.
1952 (c_parser_pragma): Added PRAGMA_CILK_GRAINSIZE case.
1953 (c_parser_omp_for_loop): Added CILK_FOR and CILK_SIMD checks.
1954 * c-typeck.c (c_finish_omp_clauses): Added OMP_CLAUSE__CILK_FOR_COUNT_
1955 case.
1956
1957 2014-08-27 Chen Gang <gang.chen.5i5j@gmail.com>
1958
1959 * c-aux-info.c (gen_type): Resize 'buff' from 10 to 23 bytes,
1960 with using HOST_WIDE_INT without truncation to 'int'
1961
1962 2014-08-22 Marek Polacek <polacek@redhat.com>
1963
1964 PR c++/62199
1965 * c-typeck.c (parser_build_binary_op): Adjust call to
1966 warn_logical_not_parentheses.
1967
1968 2014-08-22 Igor Zamyatin <igor.zamyatin@intel.com>
1969
1970 PR other/62008
1971 * c-parser.c (c_parser_array_notation): Check for correct
1972 type of an array added.
1973
1974 2014-08-19 Marek Polacek <polacek@redhat.com>
1975
1976 PR c++/62153
1977 * c-typeck.c (build_binary_op): If either operand of a comparison
1978 is a boolean expression, call maybe_warn_bool_compare.
1979
1980 2014-08-19 Patrick Palka <ppalka@gcc.gnu.org>
1981
1982 PR c/45584
1983 * c-typeck.c (build_c_cast): Do a conversion even when the
1984 TYPE_MAIN_VARIANTs are the same.
1985
1986 2014-08-19 Marek Polacek <polacek@redhat.com>
1987
1988 * c-decl.c (diagnose_mismatched_decls): Unconditionally call
1989 pedwarn_c99 instead of pedwarn.
1990 (grokfield): Likewise.
1991 (warn_defaults_to): New function.
1992 (grokdeclarator): Call warn_defaults_to instead of pedwarn_c99.
1993 Unconditionally call pedwarn_c99 instead of pedwarn.
1994 (start_function): Call warn_defaults_to instead of pedwarn_c99.
1995 (declspecs_add_scspec): Call pedwarn_c99 instead of pedwarn, don't
1996 check flag_isoc11 before.
1997 * c-errors.c (pedwarn_c99): Change the return type to bool.
1998 Handle -Wc99-c11-compat.
1999 * c-parser.c (disable_extension_diagnostics): Handle
2000 warn_c99_c11_compat.
2001 (restore_extension_diagnostics): Likewise.
2002 (c_parser_static_assert_declaration_no_semi): Call pedwarn_c99
2003 instead of pedwarn, don't check flag_isoc11 before.
2004 (c_parser_declspecs): Likewise.
2005 (c_parser_alignas_specifier): Likewise.
2006 (c_parser_alignof_expression): Likewise.
2007 (c_parser_generic_selection): Likewise.
2008 * c-tree.h (pedwarn_c99): Update declaration.
2009 * c-typeck.c (c_finish_return): Call pedwarn or warning_at instead
2010 of pedwarn_c99.
2011
2012 2014-08-19 Marek Polacek <polacek@redhat.com>
2013
2014 * c-decl.c (warn_variable_length_array): Pass OPT_Wvla unconditionally
2015 to pedwarn_c90.
2016 * c-errors.c: Include "opts.h".
2017 (pedwarn_c90): Rewrite to handle -Wno-c90-c99-compat better.
2018 * c-parser.c (disable_extension_diagnostics): Handle negative value
2019 of warn_c90_c99_compat, too.
2020 (restore_extension_diagnostics): Likewise.
2021 (c_parser_compound_statement_nostart): Pass
2022 OPT_Wdeclaration_after_statement unconditionally to pedwarn_c90.
2023
2024 2014-08-12 Marek Polacek <polacek@redhat.com>
2025
2026 * c-parser.c (c_parser_postfix_expression) <case RID_FUNCTION_NAME>:
2027 Add pedwarn.
2028 (c_parser_postfix_expression) <case RID_PRETTY_FUNCTION_NAME>:
2029 Likewise.
2030 (c_parser_postfix_expression) <case RID_C99_FUNCTION_NAME>: Likewise.
2031
2032 2014-08-10 Marek Polacek <polacek@redhat.com>
2033
2034 PR c/51849
2035 * c-decl.c (build_array_declarator): Remove check for !flag_isoc99.
2036 Call pedwarn_c90 instead of pedwarn.
2037 (check_bitfield_type_and_width): Likewise.
2038 (declspecs_add_qual): Likewise.
2039 (declspecs_add_type): Likewise.
2040 (warn_variable_length_array): Unify function for -pedantic and -Wvla.
2041 Adjust to only call pedwarn_c90.
2042 (grokdeclarator): Remove pedantic && !flag_isoc99 check. Call
2043 pedwarn_c90 instead of pedwarn.
2044 * c-errors.c (pedwarn_c90): Handle -Wc90-c99-compat.
2045 * c-parser.c (disable_extension_diagnostics): Handle
2046 warn_c90_c99_compat.
2047 (restore_extension_diagnostics): Likewise.
2048 (c_parser_enum_specifier): Remove check for !flag_isoc99. Call
2049 pedwarn_c90 instead of pedwarn.
2050 (c_parser_initelt): Likewise.
2051 (c_parser_postfix_expression): Likewise.
2052 (c_parser_postfix_expression_after_paren_type): Likewise.
2053 (c_parser_compound_statement_nostart): Remove check for !flag_isoc99.
2054 * c-tree.h: Fix formatting.
2055 * c-typeck.c (build_array_ref): Remove check for !flag_isoc99. Call
2056 pedwarn_c90 instead of pedwarn.
2057
2058 2014-08-07 Trevor Saunders <tsaunders@mozilla.com>
2059
2060 * c-typeck.c: Remove include of pointer-set.h.
2061
2062 2014-08-07 Marek Polacek <polacek@redhat.com>
2063
2064 * c-typeck.c (pointer_diff): Remove P - (P + CST) optimization.
2065
2066 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
2067
2068 * c-typeck.c: Use hash_map instead of pointer_map.
2069
2070 2014-08-02 Trevor Saunders <tsaunders@mozilla.com>
2071
2072 * c-decl.c: Use hash_set instead of pointer_set.
2073
2074 2014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
2075
2076 PR middle-end/61455
2077 * c-array-notation.c (expand_array_notations): Handling
2078 of DECL_EXPR added.
2079
2080 2014-07-31 Marc Glisse <marc.glisse@inria.fr>
2081
2082 PR c++/60517
2083 * c-typeck.c (c_finish_return): Return 0 instead of the address of
2084 a local variable.
2085
2086 2014-07-30 Tom Tromey <tromey@redhat.com>
2087
2088 * c-typeck.c (struct constructor_stack) <designator_depth>: New
2089 field.
2090 (really_start_incremental_init, push_init_level): Initialize
2091 designator_depth.
2092 (pop_init_level): Set global designator_depth.
2093 (process_init_element): Check for designated_init attribute.
2094
2095 2014-07-20 Marek Polacek <polacek@redhat.com>
2096
2097 PR c/61852
2098 * c-decl.c (implicit_decl_warning): Add location_t parameter. Use it.
2099 (implicitly_declare): Pass location to implicit_decl_warning.
2100
2101 2014-07-14 Jakub Jelinek <jakub@redhat.com>
2102
2103 PR middle-end/61294
2104 * c-parser.c (c_parser_expr_list): Add new argument literal_zero_mask.
2105 If non-NULL, call c_parser_check_literal_zero.
2106 (c_parser_check_literal_zero): New function.
2107 (c_parser_postfix_expression_after_primary): Adjust
2108 c_parser_expr_list caller, handle -Wmemset-transposed-args.
2109
2110 2014-07-06 Marek Polacek <polacek@redhat.com>
2111
2112 PR c/6940
2113 * c-decl.c (grokdeclarator): Set C_ARRAY_PARAMETER.
2114 * c-tree.h (C_ARRAY_PARAMETER): Define.
2115 * c-typeck.c (c_expr_sizeof_expr): Warn when using sizeof on an array
2116 function parameter.
2117
2118 2014-07-02 Jan Hubicka <hubicka@ucw.cz>
2119 Chen Gang <gang.chen.5i5j@gmail.com>
2120
2121 * c-decl.c (duplicate_decls): CLear DECL_STRUCT_FUNCTION before
2122 releasing symbol.
2123
2124 2014-07-01 Marek Polacek <polacek@redhat.com>
2125
2126 * c-typeck.c (convert_for_assignment): Pass OPT_Wint_conversion
2127 instead of 0 to WARN_FOR_ASSIGNMENT.
2128
2129 2014-07-01 Marek Polacek <polacek@redhat.com>
2130
2131 PR c/58286
2132 * c-typeck.c (convert_for_assignment): Pass
2133 OPT_Wincompatible_pointer_types instead of 0 to WARN_FOR_ASSIGNMENT.
2134
2135 2014-06-30 Marek Polacek <polacek@redhat.com>
2136
2137 * c-decl.c (grokdeclarator): Don't instrument VLAs if the function
2138 has no_sanitize_undefined attribute.
2139
2140 2014-06-30 Igor Zamyatin <igor.zamyatin@intel.com>
2141
2142 PR middle-end/57541
2143 * c-array-notation.c (fix_builtin_array_notation_fn):
2144 Check for 0 arguments in builtin call. Check that bultin argument is
2145 correct.
2146 * c-parser.c (c_parser_array_notation): Check for incorrect initial
2147 index.
2148
2149 2014-06-27 Sebastian Huber <sebastian.huber@embedded-brains.de>
2150
2151 * c-parser.c (c_parser_declaration_or_fndef): Discard all type
2152 qualifiers in __auto_type for atomic types.
2153 (c_parser_typeof_specifier): Discard all type qualifiers in
2154 __typeof__ for atomic types.
2155
2156 2014-06-25 Marek Polacek <polacek@redhat.com>
2157
2158 PR c/61162
2159 * c-parser.c (c_parser_statement_after_labels): Pass the location of
2160 the return expression to c_finish_return.
2161
2162 2014-06-25 Jakub Jelinek <jakub@redhat.com>
2163
2164 * c-typeck.c (c_finish_omp_clauses): Make sure
2165 OMP_CLAUSE_LINEAR_STEP has correct type.
2166
2167 2014-06-24 Trevor Saunders <tsaunders@mozilla.com>
2168
2169 * c-decl.c: Adjust.
2170
2171 2014-06-24 Jakub Jelinek <jakub@redhat.com>
2172
2173 * c-parser.c (c_parser_omp_for_loop): For
2174 #pragma omp parallel for simd move lastprivate clause from parallel
2175 to for rather than simd.
2176
2177 2014-06-23 Marek Polacek <polacek@redhat.com>
2178
2179 * c-typeck.c (parser_build_binary_op): Don't call
2180 warn_logical_not_parentheses if the RHS is TRUTH_NOT_EXPR.
2181
2182 2014-06-15 Jan Hubicka <hubicka@ucw.cz>
2183
2184 * c-parser.c (c_parser_omp_threadprivate): Likewise.
2185 * c-decl.c (merge_decls): Likewise.
2186
2187 2014-06-09 Marek Polacek <polacek@redhat.com>
2188
2189 PR c/36446
2190 * c-typeck.c (error_init): Call inform instead of error_at.
2191 (pedwarn_init): Call inform instead of pedwarn.
2192 (warning_init): Call inform instead of warning_at.
2193
2194 2014-06-07 Jan Hubicka <hubicka@ucw.cz>
2195
2196 * c-decl.c (merge_decls): Use set_decl_section_name.
2197 (duplicate_decls): Remove node if it exists.
2198
2199 2014-06-05 S. Gilles <sgilles@terpmail.umd.edu>
2200
2201 PR c/53119
2202 * c-typeck.c (push_init_level, process_init_element,
2203 pop_init_level): Correct check for zero initialization, move
2204 missing brace warning to respect zero initialization.
2205
2206 2014-06-05 Marek Polacek <polacek@redhat.com>
2207
2208 PR c/56724
2209 * c-typeck.c (convert_for_assignment): Use expr_loc for ic_argpass.
2210
2211 2014-06-05 Marek Polacek <polacek@redhat.com>
2212
2213 PR c/49706
2214 * c-typeck.c (parser_build_binary_op): Warn when logical not is used
2215 on the left hand side operand of a comparison.
2216
2217 2014-06-05 Marek Polacek <polacek@redhat.com>
2218
2219 PR c/48062
2220 * c-decl.c (warn_if_shadowing): Call inform instead of warning_at.
2221 Print note only if the warning was printed.
2222
2223 2014-06-04 Igor Zamyatin <igor.zamyatin@intel.com>
2224
2225 PR c/58942
2226 * c-array-notation.c (fix_builtin_array_notation_fn): Handle the case
2227 with a pointer.
2228
2229 2014-06-03 Marek Polacek <polacek@redhat.com>
2230
2231 PR c/60439
2232 * c-parser.c (c_parser_switch_statement): Pass explicit_cast_p to
2233 c_start_case.
2234 * c-tree.h (c_start_case): Update.
2235 * c-typeck.c (c_start_case): Add new boolean parameter. Warn if
2236 switch condition has boolean value.
2237
2238 2014-06-02 Andrew MacLeod <amacleod@redhat.com>
2239
2240 * c-decl.c: Include builtins.h.
2241 * c-parser.c: Likewise.
2242
2243 2014-05-27 Marek Polacek <polacek@redhat.com>
2244
2245 PR c/56724
2246 * c-typeck.c (convert_arguments): Get location of a parameter. Change
2247 error and warning calls to error_at and warning_at. Pass location of
2248 a parameter to it. Call warning_at with OPT_Wtraditional_conversion.
2249 (convert_for_assignment): Add parameter to WARN_FOR_ASSIGNMENT and
2250 WARN_FOR_QUALIFIERS. Pass expr_loc to those.
2251
2252 2014-05-26 Igor Zamyatin <igor.zamyatin@intel.com>
2253
2254 PR c/61191
2255 * c-array-notation.c (fix_builtin_array_notation_fn): Check invalid
2256 function parameters.
2257
2258 2014-05-23 Jan Hubicka <hubicka@ucw.cz>
2259
2260 * c-decl.c (merge_decls): Preserve symtab node pointers.
2261 (duplicate_decls): Free new decl.
2262
2263 2014-05-23 Thomas Schwinge <thomas@codesourcery.com>
2264
2265 * c-typeck.c (c_finish_omp_clauses): Remove duplicated variable
2266 initialization.
2267
2268 * c-parser.c (c_parser_omp_target): Return bool values.
2269
2270 2014-05-22 Thomas Schwinge <thomas@codesourcery.com>
2271
2272 * c-parser.c (c_parser_omp_clause_thread_limit): Rename
2273 num_teams_loc variable to num_thread_limit_loc.
2274
2275 2014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
2276
2277 * c-array-notation.c (expand_array_notations): Use void_node
2278 instead of void_zero_node.
2279
2280 2014-05-17 Trevor Saunders <tsaunders@mozilla.com>
2281
2282 * c-decl.c (finish_struct): Adjust.
2283 (finish_enum): Likewise.
2284 (bind): Adjust.
2285 (record_inline_static): Likewise.
2286 (push_scope): Likewise.
2287 (make_label): Likewise.
2288 (lookup_label_for_goto): Likewise.
2289 (finish_struct): Likewise.
2290 (finish_enum): Likewise.
2291 (store_parm_decls): Likewise.
2292 (c_push_function_context): Likewise.
2293 * c-lang.h: Remove usage of variable_size gty attribute.
2294 * c-parser.c (c_parse_init): Adjust.
2295 (c_parse_file): Likewise.
2296
2297 2014-05-13 Marek Polacek <polacek@redhat.com>
2298
2299 PR c/61162
2300 * c-typeck.c (convert_for_assignment): Pass location to
2301 WARN_FOR_ASSIGNMENT instead of input_location.
2302
2303 2014-05-10 Marek Polacek <polacek@redhat.com>
2304
2305 * c-parser.c (c_parser_declaration_or_fndef): Pass init_loc to
2306 maybe_warn_string_init.
2307 (c_parser_postfix_expression_after_paren_type): Pass type_loc to
2308 maybe_warn_string_init.
2309 * c-tree.h (maybe_warn_string_init): Update declaration.
2310 * c-typeck.c (maybe_warn_string_init): Add location parameter.
2311 Call pedwarn_init with loc instead of with input_location.
2312 (digest_init): Pass init_loc to maybe_warn_string_init.
2313 (pop_init_level): Call pedwarn_init with loc instead of with
2314 input_location.
2315 (set_init_index): Likewise.
2316 (process_init_element): Likewise.
2317
2318 2014-05-09 Marek Polacek <polacek@redhat.com>
2319
2320 PR c/61096
2321 * c-parser.c (c_parser_braced_init): Pass brace_loc to push_init_level.
2322 (c_parser_initelt): Pass location to set_init_label. Pass array index
2323 location to set_init_index.
2324 * c-tree.h (push_init_level): Update declaration.
2325 (pop_init_level): Likewise.
2326 (set_init_index): Likewise.
2327 (set_init_label): Likewise.
2328 * c-typeck.c (error_init): Add location parameter. Call error_at
2329 instead of error.
2330 (digest_init): Pass init_loc to error_init.
2331 (really_start_incremental_init):
2332 (push_init_level): Add location parameter. Pass loc to pop_init_level
2333 and error_init.
2334 (pop_init_level): Likewise.
2335 (set_designator): Add location parameter. Pass loc to pop_init_level,
2336 push_init_level, and error_init.
2337 (set_init_index): Add location parameter. Pass loc to error_init and
2338 set_designator.
2339 (set_init_label): Likewise.
2340 (output_init_element): Pass loc to error_init.
2341 (process_init_element): Pass loc to error_init, pop_init_level,
2342 pedwarn_init, and push_init_level.
2343
2344 2014-05-09 Marek Polacek <polacek@redhat.com>
2345
2346 PR c/50459
2347 * c-parser.c (c_parser_attributes): Parse the arguments as an
2348 expression-list if the attribute takes identifier.
2349
2350 2014-05-08 Marek Polacek <polacek@redhat.com>
2351
2352 PR c/61053
2353 * c-decl.c (grokdeclarator): Use min_align_of_type instead of
2354 TYPE_ALIGN_UNIT.
2355
2356 2014-05-08 Marek Polacek <polacek@redhat.com>
2357
2358 PR c/61077
2359 * c-decl.c (start_function): Warn for _Atomic-qualified return type
2360 of main.
2361
2362 2014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
2363 Mike Stump <mikestump@comcast.net>
2364 Richard Sandiford <rdsandiford@googlemail.com>
2365
2366 * c-decl.c (check_bitfield_type_and_width): Use TYPE_SIGN.
2367 (finish_enum): Use wide-int interfaces.
2368 * c-parser.c (c_parser_cilk_clause_vectorlength): Likewise.
2369 * c-typeck.c (build_c_cast): Likewise.
2370 (set_nonincremental_init_from_string): Likewise.
2371 (c_tree_equal): Likewise.
2372
2373 2014-05-02 Marek Polacek <polacek@redhat.com>
2374
2375 PR c/25801
2376 * c-typeck.c (c_size_in_bytes): Update comment. Don't call error.
2377 Return size_one_node when the type is not complete.
2378 (pointer_diff): Remove comment.
2379 (build_unary_op): Improve error messages.
2380
2381 2014-05-02 Marek Polacek <polacek@redhat.com>
2382
2383 * c-typeck.c (c_finish_return): Separate warning_at calls.
2384
2385 2014-05-02 Marek Polacek <polacek@redhat.com>
2386
2387 * c-tree.h (error_init): Remove declaration.
2388 (pedwarn_init): Likewise.
2389 * c-typeck.c (error_init): Make static and move above.
2390 (pedwarn_init): Likewise.
2391 (warning_init): Move above.
2392 (maybe_warn_string_init): Likewise.
2393
2394 2014-05-01 Jeff Law <law@redhat.com>
2395
2396 Revert:
2397
2398 2014-04-24 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
2399 * c-parser.c (c_parser_sizeof_expression): Reorganize slightly to
2400 avoid goto.
2401
2402 2014-05-02 Marek Polacek <polacek@redhat.com>
2403
2404 PR c/60784
2405 * c-typeck.c (push_init_level): Set constructor_designated to
2406 p->designated for structures.
2407
2408 2014-05-01 Marek Polacek <polacek@redhat.com>
2409
2410 PR c/60915
2411 * c-parser.c (c_parser_declaration_or_fndef): Give better error if
2412 function-definition has an attribute after the declarator.
2413
2414 2014-05-01 Marek Polacek <polacek@redhat.com>
2415
2416 PR c/60257
2417 * c-typeck.c (warning_init): Add location_t parameter. Call
2418 warning_at instead of warning.
2419 (push_init_level): Pass input_location to warning_init.
2420 (add_pending_init): Add location_t parameter. Pass loc to
2421 warning_init.
2422 (set_nonincremental_init): Pass input_location to add_pending_init.
2423 (set_nonincremental_init_from_string): Likewise.
2424 (output_init_element): Pass loc to warning_init and to
2425 add_pending_init.
2426
2427 2014-05-01 Marek Polacek <polacek@redhat.com>
2428
2429 PR c/43395
2430 * c-typeck.c (c_finish_return): Distinguish between label and variable
2431 when warning about returning local address.
2432
2433 2014-05-01 Marek Polacek <polacek@redhat.com>
2434
2435 PR c/29467
2436 * c-decl.c (declspecs_add_type): Pedwarn if boolean types are used
2437 in C89 mode.
2438
2439 2014-05-01 Marek Polacek <polacek@redhat.com>
2440
2441 PR c/43245
2442 * c-typeck.c (convert_for_assignment): Pass OPT_Wdiscarded_qualifiers
2443 instead of 0 to WARN_FOR_QUALIFIERS.
2444
2445 2014-05-01 Marek Polacek <polacek@redhat.com>
2446
2447 PR c/56989
2448 * c-typeck.c (default_conversion): Use better location for
2449 error call.
2450
2451 2014-04-30 Marek Polacek <polacek@redhat.com>
2452
2453 * c-typeck.c (build_binary_op): Call ubsan_instrument_division
2454 also when SANITIZE_FLOAT_DIVIDE is on.
2455
2456 2014-04-30 Marek Polacek <polacek@redhat.com>
2457
2458 PR c/60139
2459 * c-typeck.c (output_init_element): Pass OPT_Wpedantic to pedwarn
2460 and pedwarn_init. Use loc insted of input_location.
2461
2462 2014-04-30 Marek Polacek <polacek@redhat.com>
2463
2464 PR c/60351
2465 * c-typeck.c (build_binary_op): Use location when warning about
2466 shift count.
2467
2468 2014-04-25 Marek Polacek <polacek@redhat.com>
2469
2470 PR c/18079
2471 * c-decl.c (diagnose_mismatched_decls): Warn for mismatched
2472 always_inline/noinline and hot/cold attributes.
2473
2474 2014-04-25 Marek Polacek <polacek@redhat.com>
2475
2476 PR c/60114
2477 * c-parser.c (c_parser_initelt): Pass input_location to
2478 process_init_element.
2479 (c_parser_initval): Pass loc to process_init_element.
2480 * c-tree.h (process_init_element): Adjust declaration.
2481 * c-typeck.c (push_init_level): Pass input_location to
2482 process_init_element.
2483 (pop_init_level): Likewise.
2484 (set_designator): Likewise.
2485 (output_init_element): Add location_t parameter. Pass loc to
2486 digest_init.
2487 (output_pending_init_elements): Pass input_location to
2488 output_init_element.
2489 (process_init_element): Add location_t parameter. Pass loc to
2490 output_init_element.
2491
2492 2014-04-24 Jakub Jelinek <jakub@redhat.com>
2493
2494 * c-parser.c (c_parser_omp_atomic): Allow seq_cst before
2495 atomic-clause, allow comma in between atomic-clause and
2496 seq_cst.
2497
2498 2014-04-22 Jakub Jelinek <jakub@redhat.com>
2499
2500 PR c/59073
2501 * c-parser.c (c_parser_omp_parallel): If c_parser_omp_for
2502 fails, don't set OM_PARALLEL_COMBINED and return NULL.
2503
2504 2014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
2505
2506 PR middle-end/60469
2507 * c-array-notation.c (fix_builtin_array_notation_fn): Use
2508 create_tmp_var instead build_decl for creating temps.
2509 (build_array_notation_expr): Likewise.
2510 (fix_conditional_array_notations_1): Likewise.
2511 (fix_array_notation_expr): Likewise.
2512 (fix_array_notation_call_expr): Likewise.
2513
2514 2014-03-28 Jakub Jelinek <jakub@redhat.com>
2515
2516 PR c++/60689
2517 * c-tree.h (c_build_function_call_vec): New prototype.
2518 * c-typeck.c (build_function_call_vec): Don't call
2519 resolve_overloaded_builtin here.
2520 (c_build_function_call_vec): New wrapper function around
2521 build_function_call_vec. Call resolve_overloaded_builtin here.
2522 (convert_lvalue_to_rvalue, build_function_call, build_atomic_assign):
2523 Call c_build_function_call_vec instead of build_function_call_vec.
2524 * c-parser.c (c_parser_postfix_expression_after_primary): Likewise.
2525 * c-decl.c (finish_decl): Likewise.
2526
2527 2014-03-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
2528
2529 PR c/55383
2530 * c-typeck.c: Use correct format string in cast-qual warning
2531
2532 2014-03-07 Thomas Schwinge <thomas@codesourcery.com>
2533
2534 * c-decl.c (c_decl_attributes): Use
2535 lang_hooks.types.omp_mappable_type.
2536 * c-typeck.c (c_finish_omp_clauses): Likewise.
2537
2538 2014-03-06 Marek Polacek <polacek@redhat.com>
2539
2540 PR c/60197
2541 * c-typeck.c (c_finish_return): Call contains_cilk_spawn_stmt instead
2542 of checking tree code.
2543
2544 2014-02-19 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
2545
2546 * c-parser.c (c_parser_declspecs): Replace call to error by error_at.
2547 (c_parser_parameter_declaration): Likewise.
2548
2549 2014-02-19 Marek Polacek <polacek@redhat.com>
2550
2551 PR c/60195
2552 * c-typeck.c (convert_lvalue_to_rvalue): Set TREE_NO_WARNING on tmp.
2553 Call mark_exp_read on exp.value.
2554 (build_atomic_assign): Set TREE_NO_WARNING on val and old. Set
2555 TREE_ADDRESSABLE on old instead of val.
2556 (emit_side_effect_warnings): Warn only if RHS has !TREE_NO_WARNING.
2557
2558 2014-02-07 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
2559
2560 * c-parser.c (c_parser_get_builtin_args): Replace calls to
2561 C_EXPR_APPEND by vec_safe_push.
2562 * c-tree.h (C_EXPR_APPEND): Remove.
2563
2564 2014-01-31 Marek Polacek <polacek@redhat.com>
2565
2566 PR c/59963
2567 * c-typeck.c (convert_lvalue_to_rvalue): Pass vNULL to
2568 build_function_call_vec.
2569 (build_function_call): Likewise.
2570 (build_atomic_assign): Likewise.
2571 (build_function_call_vec): Add arg_loc parameter. Use it.
2572 (convert_arguments): Likewise.
2573 (convert_for_assignment): Rename rhs_loc to expr_loc.
2574 * c-parser.c (c_parser_attributes): Pass NULL to c_parser_expr_list.
2575 (c_parser_objc_keywordexpr): Likewise.
2576 (c_parser_postfix_expression_after_primary): Call
2577 build_function_call_vec with expr_loc rather than op_loc.
2578 Call c_parser_expr_list to fill arg_loc. Pass arg_loc to
2579 build_function_call_vec.
2580 (c_parser_expr_list): Add locations parameter. Fill it with locations
2581 of function arguments.
2582 * c-decl.c (finish_decl): Pass vNULL to build_function_call_vec.
2583
2584 2014-01-30 Marek Polacek <polacek@redhat.com>
2585
2586 PR c/59940
2587 * c-typeck.c (build_function_call_vec): Use loc parameter.
2588 (convert_arguments): Add location parameter. Use it.
2589 (ep_convert_and_check): Likewise.
2590 (build_atomic_assign): Adjust convert_for_assignment call.
2591 (build_modify_expr): Likewise.
2592 (digest_init): Likewise.
2593 (c_finish_return): Likewise.
2594 (build_conditional_expr): Adjust ep_convert_and_check calls.
2595 (convert_for_assignment): Add rhs_loc parameter. Use it.
2596 (build_binary_op): Adjust convert_and_check and ep_convert_and_check
2597 calls.
2598
2599 2014-01-30 Richard Biener <rguenther@suse.de>
2600
2601 PR c/59905
2602 * c-typeck.c (build_function_call_vec): Do not replace calls
2603 to a function via an incompatible type with a runtime abort.
2604
2605 2014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
2606
2607 * c-parser.c (c_parser_declaration_or_fndef): Replaced
2608 flag_enable_cilkplus with flag_cilkplus.
2609 (c_parser_direct_declarator_inner): Likewise.
2610 (c_parser_attribute_any_word): Likewise.
2611 (c_parser_attributes): Likewise.
2612 (c_parser_compound_statement): Likewise.
2613 (c_parser_statement_after_labels): Likewise.
2614 (c_parser_if_statement): Likewise.
2615 (c_parser_switch_statement): Likewise.
2616 (c_parser_do_statement): Likewise.
2617 (c_parser_for_statement): Likewise.
2618 (c_parser_unary_expression): Likewise.
2619 (c_parser_postfix_expression): Likewise.
2620 (c_parser_postfix_expression_after_primary): Likewise.
2621 (c_parser_postfix_expression_after_primary): Likewise.
2622 (c_parser_omp_clause_name): Likewise.
2623 (c_finish_omp_declare_simd): Likewise.
2624 (c_parser_cilk_verify_simd): Likewise.
2625 * c-typeck.c (build_array_ref): Likewise.
2626 (build_function_call_vec): Likewise.
2627 (convert_arguments): Likewise.
2628 (build_compound_expr): Likewise.
2629 (c_finish_return): Likewise.
2630 (c_finish_if_stmt): Likewise.
2631 (c_finish_loop): Likewise.
2632 (build_binary_op): Likewise.
2633
2634 2014-01-23 Marek Polacek <polacek@redhat.com>
2635
2636 PR c/59846
2637 * c-typeck.c (parser_build_binary_op): Use location instead of
2638 input_location.
2639 (build_binary_op): Pass location to shorten_compare.
2640
2641 2014-01-23 Marek Polacek <polacek@redhat.com>
2642
2643 PR c/58346
2644 * c-typeck.c (pointer_diff): Give an error on arithmetic on pointer to
2645 an empty aggregate.
2646
2647 2014-01-23 Marek Polacek <polacek@redhat.com>
2648
2649 PR c/59871
2650 * c-typeck.c (build_compound_expr): Warn even for right-hand operand
2651 of a comma expression.
2652 (emit_side_effect_warnings): Likewise.
2653
2654 2014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com>
2655
2656 PR c/59825
2657 * c-array-notation.c (expand_array_notation_exprs): Rewrote this
2658 function to use walk_tree and moved a lot of its functionality to
2659 expand_array_notations.
2660 (expand_array_notations): New function.
2661
2662 2014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com>
2663
2664 * c-parser.c (c_finish_omp_declare_simd): Made "cilk simd function"
2665 attribute an attribute without value.
2666
2667 2014-01-23 Jakub Jelinek <jakub@redhat.com>
2668
2669 PR middle-end/58809
2670 * c-typeck.c (c_finish_omp_clause): Reject MIN_EXPR, MAX_EXPR,
2671 BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR on COMPLEX_TYPEs.
2672
2673 2014-01-22 Marek Polacek <polacek@redhat.com>
2674
2675 PR c/59891
2676 * c-typeck.c (build_conditional_expr): Call c_fully_fold instead
2677 of remove_c_maybe_const_expr on op1 and op2.
2678
2679 2014-01-15 Jakub Jelinek <jakub@redhat.com>
2680
2681 PR c/58943
2682 * c-typeck.c (build_modify_expr): For lhs op= rhs, if rhs has side
2683 effects, preevaluate rhs using SAVE_EXPR first.
2684
2685 2014-01-09 Balaji V. Iyer <balaji.v.iyer@intel.com>
2686
2687 PR c++/59631
2688 * c-parser.c (c_parser_postfix_expression): Replaced consecutive if
2689 statements with if-elseif statements.
2690
2691 2014-01-06 Marek Polacek <polacek@redhat.com>
2692
2693 PR c/57773
2694 * c-decl.c (check_bitfield_type_and_width): Warn for implementation
2695 defined bit-field types only in ISO C.
2696
2697 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
2698
2699 Update copyright years
2700
2701 2014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
2702
2703 * c-array-notation.c: Use the standard form for the copyright notice.
2704
2705 2013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
2706
2707 * c-parser.c (struct c_parser::cilk_simd_fn_tokens): Added new field.
2708 (c_parser_declaration_or_fndef): Added a check if cilk_simd_fn_tokens
2709 field in parser is not empty. If not-empty, call the function
2710 c_parser_finish_omp_declare_simd.
2711 (c_parser_cilk_clause_vectorlength): Modified function to be shared
2712 between SIMD-enabled functions and #pragma simd. Added new parameter.
2713 (c_parser_cilk_all_clauses): Modified the usage of the function
2714 c_parser_cilk_clause_vectorlength as mentioned above.
2715 (c_parser_cilk_simd_fn_vector_attrs): New function.
2716 (c_finish_cilk_simd_fn_tokens): Likewise.
2717 (is_cilkplus_vector_p): Likewise.
2718 (c_parser_omp_clause_name): Added checking for "vectorlength,"
2719 "nomask," and "mask" strings in clause name.
2720 (c_parser_omp_all_clauses): Added 3 new case statements:
2721 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_MASK and
2722 PRAGMA_CILK_CLAUSE_NOMASK.
2723 (c_parser_attributes): Added a cilk_simd_fn_tokens parameter. Added a
2724 check for vector attribute and if so call the function
2725 c_parser_cilk_simd_fn_vector_attrs. Also, when Cilk plus is enabled,
2726 called the function c_finish_cilk_simd_fn_tokens.
2727 (c_finish_omp_declare_simd): Added a check if cilk_simd_fn_tokens in
2728 parser field is non-empty. If so, parse them as you would parse
2729 the omp declare simd pragma.
2730 (c_parser_omp_clause_linear): Added a new bool parm. is_cilk_simd_fn.
2731 Added a check when step is a parameter and flag it as error.
2732 (CILK_SIMD_FN_CLAUSE_MASK): New #define.
2733 (c_parser_cilk_clause_name): Changed pragma_cilk_clause to
2734 pragma_omp_clause.
2735
2736 2013-12-17 Thomas Schwinge <thomas@codesourcery.com>
2737
2738 * c-parser.c (c_parser_omp_parallel): Fix description.
2739
2740 2013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
2741
2742 * c-objc-common.h (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Remove.
2743 (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise.
2744 (LANG_HOOKS_CILKPLUS_CILKPLUS_GIMPLIFY_SPAWN): Likewise.
2745 * c-typeck.c (cilk_install_body_with_frame_cleanup): New function.
2746
2747 2013-12-04 Joseph Myers <joseph@codesourcery.com>
2748
2749 PR c/52023
2750 * c-parser.c (c_parser_alignas_specifier): Use
2751 c_sizeof_or_alignof_type instead of c_alignof.
2752 (c_parser_alignof_expression): Likewise, with min_alignof
2753 parameter depending on alignof spelling used.
2754
2755 2013-12-04 Marek Polacek <polacek@redhat.com>
2756
2757 PR c/54113
2758 * c-decl.c (start_function): Don't warn for missing prototype for
2759 inline functions.
2760
2761 2013-12-03 Marek Polacek <polacek@redhat.com>
2762
2763 PR c/59351
2764 * c-decl.c (build_compound_literal): Allow compound literals with
2765 empty initial value.
2766
2767 2013-12-02 Joseph Myers <joseph@codesourcery.com>
2768
2769 PR c/58235
2770 * c-typeck.c (build_modify_expr): Diagnose assignment to
2771 expression with array type.
2772
2773 2013-11-29 Joseph Myers <joseph@codesourcery.com>
2774
2775 PR c/42262
2776 * c-typeck.c (process_init_element): Do not treat a string as
2777 initializing a whole array when used with a designator for an
2778 individual element.
2779
2780 2013-11-29 Joseph Myers <joseph@codesourcery.com>
2781
2782 PR c/57574
2783 * c-decl.c (merge_decls): Clear DECL_EXTERNAL for a definition of
2784 an inline function following a static declaration.
2785
2786 2013-11-28 Jakub Jelinek <jakub@redhat.com>
2787
2788 PR c/59310
2789 * c-parser.c (c_parser_omp_target): Copy "#pragma omp target"
2790 to p_name before calling c_parser_omp_teams instead of after.
2791 (c_parser_cilk_simd): Remove wrong ATTRIBUTE_UNUSED from parser
2792 argument. Remove unused p_name variable.
2793
2794 2013-11-27 Aldy Hernandez <aldyh@redhat.com>
2795 Jakub Jelinek <jakub@redhat.com>
2796
2797 * c-decl.c (c_builtin_function_ext_scope): Avoid binding if
2798 external_scope is NULL.
2799
2800 2013-11-27 Tom de Vries <tom@codesourcery.com>
2801 Marc Glisse <marc.glisse@inria.fr>
2802
2803 PR c++/59032
2804 * c-typeck.c (build_unary_op): Allow vector increment and decrement.
2805
2806 2013-11-22 Andrew MacLeod <amacleod@redhat.com>
2807
2808 * c-typeck.c: Add required include files from gimple.h.
2809
2810 2013-11-22 David Malcolm <dmalcolm@redhat.com>
2811
2812 * c-decl.c (define_label, shadow_tag_warned)
2813 (check_bitfield_type_and_width, grokdeclarator, grokparms,
2814 store_parm_decls_newstyle, store_parm_decls_oldstyle)
2815 (declspecs_add_type): Remove use of in_system_header macro.
2816 * c-parser.c (c_parser_unary_expression): Likewise.
2817 * c-typeck.c (store_init_value, process_init_element)
2818 (c_start_case): Likewise.
2819
2820 * c-decl.c (build_enumerator): Remove use of EXPR_LOC_OR_HERE
2821 macro.
2822
2823 * c-parser.c (c_parser_set_source_position_from_token): Remove
2824 reference to in_system_header from comment.
2825
2826 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2827
2828 * c-decl.c (grokdeclarator): Update comment to refer to
2829 tree_to_[su]hwi rather than tree_low_cst.
2830
2831 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2832
2833 * c-decl.c, c-typeck.c: Replace tree_low_cst (..., 1) with
2834 tree_to_uhwi throughout.
2835
2836 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2837
2838 * c-parser.c: Replace tree_low_cst (..., 0) with tree_to_shwi
2839 throughout.
2840
2841 2013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2842
2843 * c-parser.c: Replace host_integerp (..., 0) with tree_fits_shwi_p
2844 throughout.
2845
2846 2013-11-15 Aldy Hernandez <aldyh@redhat.com>
2847
2848 * c-parser.c (c_parser_cilk_simd): New.
2849 (c_parser_cilk_verify_simd): New.
2850 (c_parser_pragma): Add case for PRAGMA_CILK_SIMD.
2851 (c_parser_omp_for_loop): Add case for NE_EXPR.
2852 Set c_break_label for CILK_SIMD.
2853 (c_parser_cilk_clause_vectorlength): New.
2854 (c_parser_cilk_clause_linear): New.
2855 (c_parser_cilk_clause_name): New.
2856 (c_parser_cilk_all_clauses): New.
2857 * c-typeck.c (build_unary_op): Pass location argument to
2858 readonly_error.
2859 (build_modify_expr): Same.
2860 (build_asm_expr): Same.
2861 (c_finish_bc_stmt): Error on break/continue in loops.
2862
2863 2013-11-14 Andrew MacLeod <amacleod@redhat.com>
2864
2865 * c-typeck.c: Include only gimplify.h and gimple.h as needed.
2866
2867 2013-11-14 Diego Novillo <dnovillo@google.com>
2868
2869 * c-decl.c: Include print-tree.h.
2870 Include stor-layout.h.
2871 Include varasm.h.
2872 Include attribs.h.
2873 Include stringpool.h.
2874 * c-lang.c: Include fold-const.h.
2875 * c-parser.c: Include stringpool.h.
2876 Include attribs.h.
2877 Include stor-layout.h.
2878 Include varasm.h.
2879 Include trans-mem.h.
2880 * c-typeck.c: Include stor-layout.h.
2881 Include trans-mem.h.
2882 Include varasm.h.
2883 Include stmt.h.
2884
2885 2013-11-13 Joseph Myers <joseph@codesourcery.com>
2886
2887 * c-tree.h (c_typespec_keyword): Add cts_auto_type.
2888 * c-decl.c (declspecs_add_type, finish_declspecs): Handle
2889 __auto_type.
2890 * c-parser.c (c_token_starts_typename, c_token_starts_declspecs)
2891 (c_parser_attribute_any_word, c_parser_objc_selector): Handle
2892 RID_AUTO_TYPE.
2893 (c_parser_declspecs): Take argument AUTO_TYPE_OK.
2894 (c_parser_declaration_or_fndef, c_parser_struct_declaration)
2895 (c_parser_declarator, c_parser_direct_declarator_inner)
2896 (c_parser_parameter_declaration, c_parser_type_name): All callers
2897 changed.
2898 (c_parser_declaration_or_fndef): Handle declarations with type
2899 determined from the initializer.
2900
2901 2013-11-12 Andrew MacLeod <amacleod@redhat.com>
2902
2903 * c-typeck.c: Include gimplify.h.
2904
2905 2013-11-12 Joseph Myers <joseph@codesourcery.com>
2906
2907 * c-tree.h (struct c_declspecs): Add thread_gnu_p field.
2908 * c-parser.c (c_parser_declspecs): Mention _Thread_local in
2909 comment.
2910 * c-decl.c (shadow_tag_warned, grokdeclarator): Mention __thread
2911 or _Thread_local as appropriate in diagnostics.
2912 (build_null_declspecs): Initialize ret->thread_gnu_p.
2913 (declspecs_add_scspec): Handle either __thread or _Thread_local
2914 for RID_THREAD. Diagnose _Thread_local for pre-C11 standards if
2915 pedantic. Do not disallow _Thread_local extern and _Thread_local
2916 static.
2917
2918 2013-11-07 Joseph Myers <joseph@codesourcery.com>
2919 Andrew MacLeod <amacleod@redhat.com>
2920
2921 * c-aux-info.c (gen_type): Handle atomic qualifier.
2922 * c-decl.c (validate_proto_after_old_defn): Do not remove atomic
2923 qualifiers when compating types.
2924 (shadow_tag_warned): Handle atomic_p in declspecs.
2925 (quals_from_declspecs): Likewise.
2926 (start_decl): Use c_type_promotes_to when promoting argument
2927 types.
2928 (grokdeclarator): Handle _Atomic.
2929 (get_parm_info): Diagnose any qualifier on "void" as only
2930 parameter.
2931 (store_parm_decls_oldstyle): Do not remove atomic qualifiers when
2932 comparing types. Use c_type_promotes_to when promoting argument
2933 types.
2934 (finish_function): Use c_type_promotes_to when promoting argument
2935 types.
2936 (build_null_declspecs): Handle atomic_p in declspecs.
2937 (declspecs_add_qual): Handle RID_ATOMIC.
2938 * c-parser.c (c_token_starts_typename, c_token_is_qualifier)
2939 (c_token_starts_declspecs): Handle RID_ATOMIC.
2940 (c_parser_declspecs): Handle atomic type specifiers and
2941 qualifiers.
2942 (c_parser_typeof_specifier): Remove const and _Atomic qualifiers
2943 from types of expressions with atomic type.
2944 (c_parser_direct_declarator_inner): Use convert_lvalue_to_rvalue.
2945 (c_parser_attribute_any_word): Handle RID_ATOMIC.
2946 (c_parser_initializer, c_parser_initelt, c_parser_initval)
2947 (c_parser_statement_after_labels, c_parser_switch_statement)
2948 (c_parser_for_statement, c_parser_expr_no_commas)
2949 (c_parser_conditional_expression, c_parser_binary_expression)
2950 (c_parser_cast_expression, c_parser_unary_expression)
2951 (c_parser_postfix_expression)
2952 (c_parser_postfix_expression_after_primary, c_parser_expression):
2953 Use convert_lvalue_to_rvalue.
2954 (c_parser_expression_conv, c_parser_expr_list): Document
2955 conversion of lvalues to rvalues. Use convert_lvalue_to_rvalue.
2956 (c_parser_objc_synchronized_statement): Use
2957 convert_lvalue_to_rvalue.
2958 (c_parser_objc_selector): Handle RID_ATOMIC.
2959 (c_parser_objc_receiver, c_parser_array_notation): Use
2960 convert_lvalue_to_rvalue.
2961 * c-tree.h (ctsk_typeof): Adjust comment to mention use for
2962 _Atomic (type-name).
2963 (struct c_declspecs): Add atomic_p field.
2964 (convert_lvalue_to_rvalue): Declare.
2965 * c-typeck.c (c_type_promotes_to): Promote atomic types to
2966 corresponding atomic types.
2967 (qualify_type): Don't add _Atomic qualifiers from second argument.
2968 (comp_target_types): Do not allow _Atomic mismatches.
2969 (type_lists_compatible_p): Do not remove atomic qualifiers when
2970 comparing types.
2971 (really_atomic_lvalue, convert_lvalue_to_rvalue)
2972 (build_atomic_assign): New functions.
2973 (build_unary_op): Use build_atomic_assign for atomic increment and
2974 decrement.
2975 (build_conditional_expr): Do not treat _Atomic void as a qualified
2976 version of void.
2977 (build_modify_expr): Use build_atomic_assign for atomic LHS.
2978 (find_anonymous_field_with_type, convert_to_anonymous_field)
2979 (convert_for_assignment): Do not remove atomic qualifiers when
2980 comparing types.
2981 (digest_init): Do not accept initialization of arrays of atomic
2982 elements by string constants.
2983 (build_asm_expr): Use convert_lvalue_to_rvalue.
2984 (build_binary_op): Do not treat _Atomic void as a qualified
2985 version of void.
2986
2987 2013-11-06 DJ Delorie <dj@redhat.com>
2988
2989 * c-decl.c (locate_old_decl): If a previous conflicting decl is
2990 both explicit and builtin, print the location of the explicit one.
2991
2992 2013-11-05 Tobias Burnus <burnus@net-b.de>
2993
2994 * c-parser.c (c_parser_omp_for, c_parser_omp_parallel,
2995 c_parser_omp_distribute, c_parser_omp_teams,
2996 c_parser_omp_target, c_parser_omp_declare): Handle
2997 -fopenmp-simd.
2998
2999 2013-11-03 Marek Polacek <polacek@redhat.com>
3000
3001 * c-decl.c (grokdeclarator): Add VLA instrumentation.
3002
3003 2013-11-01 Jakub Jelinek <jakub@redhat.com>
3004
3005 * c-typeck.c (c_finish_omp_clauses) <case OMP_CLAUSE_UNIFORM>: Go to
3006 check_dup_generic at the end, unless remove is true.
3007 (c_finish_omp_clauses) <case OMP_CLAUSE_REDUCTION>: Add break; after
3008 remove = true;.
3009 (c_finish_omp_clauses) <case OMP_CLAUSE_COPYIN>: Likewise.
3010
3011 2013-10-31 Jakub Jelinek <jakub@redhat.com>
3012
3013 * c-typeck.c (c_finish_omp_clauses): Diagnose aligned clause
3014 with decl that is not pointer nor array.
3015
3016 2013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
3017
3018 * c-decl.c (finish_function): Added a call for insert_cilk_frame when
3019 a spawning function is found.
3020 * c-objc-common.h (LANG_HOOKS_CILKPLUS_GIMPLIFY_SPAWN): New #define.
3021 (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Likewise.
3022 (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise.
3023 * c-parser.c (c_parser_statement_after_labels): Added RID_CILK_SYNC
3024 case.
3025 (c_parser_postfix_expression): Added RID_CILK_SPAWN case.
3026 * c-typeck.c (build_compound_expr): Reject _Cilk_spawn in a comma
3027 expr.
3028 (c_finish_return): Added a check to reject _Cilk_spawn in return
3029 expression.
3030 (build_cilk_spawn): New function.
3031 (build_cilk_sync): Likewise.
3032 * Makefile.in (c-decl.o): Added cilk.h in dependency list.
3033
3034 2013-10-27 Tobias Burnus <burnus@net-b.de>
3035
3036 PR other/33426
3037 * c-parser.c (c_parser_while_statement, c_parser_while_statement,
3038 c_parser_pragma): Add GCC ivdep support to 'do' and 'while'.
3039 (c_parser_statement_after_labels): Update calls.
3040
3041 2013-10-24 Tobias Burnus <burnus@net-b.de>
3042
3043 PR other/33426
3044 * c-parser.c (c_parser_pragma, c_parser_for_statement):
3045 Handle PRAGMA_IVDEP.
3046 (c_parser_statement_after_labels): Update call.
3047
3048 2013-10-24 Marek Polacek <polacek@redhat.com>
3049
3050 * c-parser.c (c_parser_struct_declaration): Add a comment.
3051 (c_parser_declarator): Don't allow _Alignas here.
3052
3053 2013-10-17 Andrew MacLeod <amacleod@redhat.com>
3054
3055 * c-parser.c: Include omp-low.h.
3056 * c-typeck.c: Likewise.
3057
3058 2013-10-17 Marek Polacek <polacek@redhat.com>
3059
3060 PR c/58267
3061 * c-parser.c (c_parser_declspecs): Add alignspec_ok parameter.
3062 Document syntax of the array-declarator.
3063 (c_parser_declspecs) <RID_ALIGNAS>: Bail out if alignment specs
3064 are not permitted.
3065 (c_parser_declaration_or_fndef): Adjust c_parser_declspecs call.
3066 (c_parser_struct_declaration): Likewise.
3067 (c_parser_declarator): Likewise.
3068 (c_parser_direct_declarator_inner): Likewise.
3069 (c_parser_parameter_declaration): Likewise.
3070 (c_parser_type_name): Likewise.
3071
3072 2013-10-11 Jakub Jelinek <jakub@redhat.com>
3073
3074 * c-lang.h (current_omp_declare_target_attribute): New extern
3075 decl.
3076 * c-parser.c: Include c-lang.h.
3077 (struct c_parser): Change tokens to c_token *.
3078 Add tokens_buf field. Change tokens_avail type to unsigned int.
3079 (c_parser_consume_token): If parser->tokens isn't
3080 &parser->tokens_buf[0], increment parser->tokens.
3081 (c_parser_consume_pragma): Likewise.
3082 (enum pragma_context): Add pragma_struct and pragma_param.
3083 (c_parser_external_declaration): Adjust
3084 c_parser_declaration_or_fndef caller.
3085 (c_parser_declaration_or_fndef): Add omp_declare_simd_clauses
3086 argument, if it is non-vNULL vector, call c_finish_omp_declare_simd.
3087 Adjust recursive call.
3088 (c_parser_struct_or_union_specifier): Use pragma_struct instead
3089 of pragma_external.
3090 (c_parser_parameter_declaration): Use pragma_param instead of
3091 pragma_external.
3092 (c_parser_compound_statement_nostart, c_parser_label,
3093 c_parser_for_statement): Adjust
3094 c_parser_declaration_or_fndef callers.
3095 (c_parser_expr_no_commas): Add omp_atomic_lhs argument, pass
3096 it through to c_parser_conditional_expression.
3097 (c_parser_conditional_expression): Add omp_atomic_lhs argument,
3098 pass it through to c_parser_binary_expression. Adjust recursive
3099 call.
3100 (c_parser_binary_expression): Remove prec argument, add
3101 omp_atomic_lhs argument instead. Always start from PREC_NONE, if
3102 omp_atomic_lhs is non-NULL and one of the arguments of toplevel
3103 binop matches it, use build2 instead of parser_build_binary_op.
3104 (c_parser_pragma): Handle PRAGMA_OMP_CANCEL,
3105 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_TARGET,
3106 PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_DECLARE_REDUCTION.
3107 Handle pragma_struct and pragma_param the same as pragma_external.
3108 (c_parser_omp_clause_name): Parse new OpenMP 4.0 clause names.
3109 (c_parser_omp_variable_list): Parse array sections for
3110 OMP_CLAUSE_{DEPEND,MAP,TO,FROM} clauses.
3111 (c_parser_omp_clause_collapse): Fully fold collapse expression.
3112 (c_parser_omp_clause_reduction): Handle user defined reductions.
3113 (c_parser_omp_clause_branch, c_parser_omp_clause_cancelkind,
3114 c_parser_omp_clause_num_teams, c_parser_omp_clause_thread_limit,
3115 c_parser_omp_clause_aligned, c_parser_omp_clause_linear,
3116 c_parser_omp_clause_safelen, c_parser_omp_clause_simdlen,
3117 c_parser_omp_clause_depend, c_parser_omp_clause_map,
3118 c_parser_omp_clause_device, c_parser_omp_clause_dist_schedule,
3119 c_parser_omp_clause_proc_bind, c_parser_omp_clause_to,
3120 c_parser_omp_clause_from, c_parser_omp_clause_uniform): New functions.
3121 (c_parser_omp_all_clauses): Add finish_p argument. Don't call
3122 c_finish_omp_clauses if it is false. Handle new OpenMP 4.0 clauses.
3123 (c_parser_omp_atomic): Parse seq_cst clause, pass true if it is
3124 present to c_finish_omp_atomic. Handle OpenMP 4.0 atomic forms.
3125 (c_parser_omp_for_loop): Add CODE argument, pass it through
3126 to c_finish_omp_for. Change last argument to cclauses,
3127 and adjust uses to grab parallel clauses from the array of all
3128 the split clauses. Adjust c_parser_binary_expression,
3129 c_parser_declaration_or_fndef and c_finish_omp_for callers.
3130 (omp_split_clauses): New function.
3131 (c_parser_omp_simd): New function.
3132 (c_parser_omp_for): Add p_name, mask and cclauses arguments.
3133 Allow the function to be called also when parsing combined constructs,
3134 and call c_parser_omp_simd when parsing for simd.
3135 (c_parser_omp_sections_scope): If section-sequence doesn't start with
3136 #pragma omp section, require exactly one structured-block instead of
3137 sequence of statements.
3138 (c_parser_omp_sections): Add p_name, mask and cclauses arguments.
3139 Allow the function to be called also when parsing combined constructs.
3140 (c_parser_omp_parallel): Add p_name, mask and cclauses arguments.
3141 Allow the function to be called also when parsing combined
3142 constructs.
3143 (c_parser_omp_taskgroup, c_parser_omp_cancel,
3144 c_parser_omp_cancellation_point, c_parser_omp_distribute,
3145 c_parser_omp_teams, c_parser_omp_target_data,
3146 c_parser_omp_target_update, c_parser_omp_target,
3147 c_parser_omp_declare_simd, c_finish_omp_declare_simd,
3148 c_parser_omp_declare_target, c_parser_omp_end_declare_target,
3149 c_parser_omp_declare_reduction, c_parser_omp_declare): New functions.
3150 (c_parser_omp_construct): Add p_name and mask vars. Handle
3151 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_SIMD, PRAGMA_OMP_TASKGROUP,
3152 PRAGMA_OMP_TEAMS. Adjust c_parser_omp_for, c_parser_omp_parallel
3153 and c_parser_omp_sections callers.
3154 (c_parse_file): Initialize tparser.tokens and the_parser->tokens here.
3155 (OMP_FOR_CLAUSE_MASK, OMP_SECTIONS_CLAUSE_MASK,
3156 OMP_SINGLE_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1.
3157 (OMP_PARALLEL_CLAUSE_MASK): Likewise. Add OMP_CLAUSE_PROC_BIND.
3158 (OMP_TASK_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1. Add
3159 OMP_CLAUSE_DEPEND.
3160 (OMP_SIMD_CLAUSE_MASK, OMP_CANCEL_CLAUSE_MASK,
3161 OMP_CANCELLATION_POINT_CLAUSE_MASK, OMP_DISTRIBUTE_CLAUSE_MASK,
3162 OMP_TEAMS_CLAUSE_MASK, OMP_TARGET_DATA_CLAUSE_MASK,
3163 OMP_TARGET_UPDATE_CLAUSE_MASK, OMP_TARGET_CLAUSE_MASK,
3164 OMP_DECLARE_SIMD_CLAUSE_MASK): Define.
3165 * c-typeck.c: Include tree-inline.h.
3166 (c_finish_omp_cancel, c_finish_omp_cancellation_point,
3167 handle_omp_array_sections_1, handle_omp_array_sections,
3168 c_clone_omp_udr, c_find_omp_placeholder_r): New functions.
3169 (c_finish_omp_clauses): Handle new OpenMP 4.0 clauses and
3170 user defined reductions.
3171 (c_tree_equal): New function.
3172 * c-tree.h (temp_store_parm_decls, temp_pop_parm_decls,
3173 c_finish_omp_cancel, c_finish_omp_cancellation_point, c_tree_equal,
3174 c_omp_reduction_id, c_omp_reduction_decl, c_omp_reduction_lookup,
3175 c_check_omp_declare_reduction_r): New prototypes.
3176 * c-decl.c (current_omp_declare_target_attribute): New variable.
3177 (c_decl_attributes): New function.
3178 (start_decl, start_function): Use it instead of decl_attributes.
3179 (temp_store_parm_decls, temp_pop_parm_decls, c_omp_reduction_id,
3180 c_omp_reduction_decl, c_omp_reduction_lookup,
3181 c_check_omp_declare_reduction_r): New functions.
3182
3183 2013-09-25 Tom Tromey <tromey@redhat.com>
3184
3185 * Make-lang.in (c/gccspec.o): Remove.
3186 (CFLAGS-c/gccspec.o): New variable.
3187 (cc1-checksum.o, C_TREE_H, c/c-aux-info.o, c/c-convert.o)
3188 (c/c-decl.o, c/c-errors.o, c/c-lang.o, c/c-objc-common.o)
3189 (c/c-parser.o, c/c-typeck.o, c/c-array-notation.o): Remove.
3190
3191 2013-09-25 Tom Tromey <tromey@redhat.com>
3192
3193 * Make-lang.in (c/gccspec.o): Don't use subshell.
3194
3195 2013-09-18 Marek Polacek <polacek@redhat.com>
3196
3197 PR sanitize/58443
3198 * c-typeck.c (build_binary_op): Properly honor -fsanitize options.
3199 Remove unnecessary check.
3200
3201 2013-09-18 Marek Polacek <polacek@redhat.com>
3202
3203 PR sanitizer/58411
3204 * c-typeck.c (build_binary_op): Don't sanitize function if it has the
3205 no_sanitize_undefined attribute.
3206
3207 2013-09-13 Kai Tietz <ktietz@redhat.com>
3208
3209 PR target/57848
3210 * c-decl.c (c_builtin_function_ext_scope): Remove
3211 wrong assumption that it is never called on prexisting
3212 symbol.
3213
3214 2013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
3215
3216 * c-typeck.c (build_binary_op): Use vector_types_compatible_elements_p.
3217
3218 2013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
3219
3220 * c-objc-common.c (c_tree_printer): Tidy.
3221
3222 2013-08-30 Marek Polacek <polacek@redhat.com>
3223
3224 * c-typeck.c (build_binary_op): Add division by zero and shift
3225 instrumentation.
3226
3227 2013-08-26 Joern Rennecke <joern.rennecke@embecosm.com>
3228 Joseph Myers <joseph@codesourcery.com>
3229
3230 PR c/35649
3231 * c-typeck.c (c_common_type): Prefer double_type_node over
3232 other REAL_TYPE types with the same precision.
3233 (convert_arguments): Likewise.
3234
3235 2013-08-23 Gabriel Dos Reis <gdr@integrable-solutions.net>
3236
3237 * c-objc-common.c (c_tree_printer): Document the nature of the cast.
3238 (c_initialize_diagnostics): Call a destructor for the early printer.
3239
3240 2013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
3241
3242 * c-objc-common.c (c_initialize_diagnostics): Simplify C pretty
3243 printer initialization.
3244
3245 2013-08-19 Balaji V. Iyer <balaji.v.iyer@intel.com>
3246
3247 PR c/57490
3248 * c-array-notation.c (fix_conditional_array_notations_1): Added a
3249 check for truth values.
3250 (expand_array_notation_exprs): Added truth values case. Removed an
3251 unwanted else. Added for-loop to walk through subtrees in default
3252 case.
3253
3254 2013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
3255
3256 * c-objc-common.c (c_initialize_diagnostics): Don't call pp_base.
3257
3258 2013-07-23 Joseph Myers <joseph@codesourcery.com>
3259
3260 * c-parser.c (struct c_generic_association): Fix typo.
3261
3262 2013-07-23 Tom Tromey <tromey@redhat.com>
3263 Joseph Myers <joseph@codesourcery.com>
3264
3265 * c-parser.c (struct c_generic_association): New.
3266 (c_generic_association_d): New typedef.
3267 (c_parser_generic_selection): New function.
3268 (c_parser_postfix_expression): Handle RID_GENERIC.
3269
3270 2013-07-13 Jason Merrill <jason@redhat.com>
3271
3272 PR c++/57793
3273 * c-decl.c (finish_struct): Check for too-large class.
3274
3275 2013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
3276
3277 PR c/57821
3278 * c-typeck.c (set_init_index): When folding, check for index overflow.
3279
3280 2013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
3281
3282 * c-parser.c (c_parser_array_notation): Removed rejection of array
3283 notations in an array of function pointers.
3284
3285 2013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
3286
3287 * c-array-notation.c (make_triplet_val_inv): New function.
3288 (create_cmp_incr): Likewise.
3289 (create_array_refs): Likewise.
3290 (fix_builtin_array_notation_fn): Replaced all mallocs with tree vec.
3291 Also modularized common parts between functions and called the function.
3292 (build_array_notation_expr): Likewise.
3293 (fix_conditional_array_notations_1): Likewise.
3294 (fix_array_notation_expr): Likewise.
3295 (fix_array_notation_call_expr): Likewise.
3296
3297 2013-06-18 Marek Polacek <polacek@redhat.com>
3298
3299 PR c/57630
3300 * c-decl.c (check_for_loop_decls): Improve diagnostics messages.
3301
3302 2013-06-12 Balaji V. Iyer <balaji.v.iyer@intel.com>
3303
3304 * c-array-notation.c (build_array_notation_expr): Reject array notation
3305 mismatch between LHS and RHS even inside a call_expr. Also, removed
3306 a couple while statements that were dead code.
3307
3308 2013-06-10 Balaji V. Iyer <balaji.v.iyer@intel.com>
3309
3310 * c-array-notation.c (fix_builtin_array_notation_fn): Fully folded
3311 excessive precision expressions in function parameters. Also removed
3312 couple unwanted while statements.
3313
3314 2013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
3315
3316 * c-array-notation.c (expand_array_notation_exprs): Added
3317 ARRAY_NOTATION_REF case.
3318
3319 2013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
3320
3321 * c-array-notation.c (length_mismatch_in_expr_p): Moved this
3322 function to c-family/array-notation-common.c.
3323 (is_cilkplus_reduce_builtin): Likewise.
3324 (find_rank): Likewise.
3325 (extract_array_notation_exprs): Likewise.
3326 (replace_array_notations): Likewise.
3327 (find_inv_trees): Likewise.
3328 (replace_inv_trees): Likewise.
3329 (contains_array_notation_expr): Likewise.
3330 (find_correct_array_notation_type): Likewise.
3331 (replace_invariant_exprs): Initialized additional_tcodes to NULL.
3332 (struct inv_list): Moved this to c-family/array-notation-common.c.
3333 * c-tree.h (is_cilkplus_builtin_reduce): Remove prototype.
3334
3335 2013-06-05 Balaji V. Iyer <balaji.v.iyer@intel.com>
3336
3337 * c-typeck.c (convert_arguments): Moved checking of builtin cilkplus
3338 reduction functions outside the for-loop. Added a check if the fundecl
3339 is non-NULL. Finally, removed an unwanted if-statement, and made the
3340 body unconditional.
3341
3342 2013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com>
3343
3344 * c-typeck.c (c_finish_if_stmt): Added a check to see if the rank of the
3345 condition of the if-statement matches the rank of else-block and then-
3346 block when array notations are used.
3347 * c-parser.c (c_parser_declaration_or_fndef): Expanded array notation
3348 expression after the entire function body is parsed.
3349 (c_parser_expr_no_commas): Delayed creating array notation expressions
3350 to the end of function parsing.
3351 * c-array-notation.c (fix_conditional_array_notations_1): Expanded the
3352 whole if-statement instead of just the condition.
3353 (expand_array_notation_exprs): Added MODIFY_EXPR case.
3354
3355 2013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com>
3356
3357 PR c/57474
3358 * c-array-notation.c (build_array_notation_expr): Initialized rhs_length
3359 array to NULL_TREE if they are unused. Also added a check for the
3360 field to be NULL before its fields are used in future.
3361
3362 2013-05-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3363
3364 PR bootstrap/57450
3365 * c-array-notation.c (length_mismatch_in_expr_p): Use absu_hwi.
3366 (build_array_notation_expr): Likewise.
3367
3368 2013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
3369
3370 * c-typeck.c (build_array_ref): Added a check to see if array's
3371 index is greater than one. If true, then emit an error.
3372 (build_function_call_vec): Exclude error reporting and checking
3373 for builtin array-notation functions.
3374 (convert_arguments): Likewise.
3375 (c_finish_return): Added a check for array notations as a return
3376 expression. If true, then emit an error.
3377 (c_finish_loop): Added a check for array notations in a loop
3378 condition. If true then emit an error.
3379 (lvalue_p): Added a ARRAY_NOTATION_REF case.
3380 (build_binary_op): Added a check for array notation expr inside
3381 op1 and op0. If present, we call another function to find correct
3382 type.
3383 * Make-lang.in (C_AND_OBJC_OBJS): Added c-array-notation.o.
3384 * c-parser.c (c_parser_compound_statement): Check if array
3385 notation code is used in tree, if so, then transform them into
3386 appropriate C code.
3387 (c_parser_expr_no_commas): Check if array notation is used in LHS
3388 or RHS, if so, then build array notation expression instead of
3389 regular modify.
3390 (c_parser_postfix_expression_after_primary): Added a check for
3391 colon(s) after square braces, if so then handle it like an array
3392 notation. Also, break up array notations in unary op if found.
3393 (c_parser_direct_declarator_inner): Added a check for array
3394 notation.
3395 (c_parser_compound_statement): Added a check for array notation in
3396 a stmt. If one is present, then expand array notation expr.
3397 (c_parser_if_statement): Likewise.
3398 (c_parser_switch_statement): Added a check for array notations in
3399 a switch statement's condition. If true, then output an error.
3400 (c_parser_while_statement): Similarly, but for a while.
3401 (c_parser_do_statement): Similarly, but for a do-while.
3402 (c_parser_for_statement): Similarly, but for a for-loop.
3403 (c_parser_unary_expression): Check if array notation is used in a
3404 pre-increment or pre-decrement expression. If true, then expand
3405 them.
3406 (c_parser_array_notation): New function.
3407 * c-array-notation.c: New file.
3408 * c-tree.h (is_cilkplus_reduce_builtin): Protoize.
3409
3410 2013-05-23 Mike Stump <mikestump@comcast.net>
3411
3412 * c-typeck.c (convert_for_assignment): Handle references to memory
3413 spaces better.
3414
3415 2013-05-16 Jason Merrill <jason@redhat.com>
3416
3417 * Make-lang.in (cc1$(exeext)): Use link mutex.
3418
3419 2013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
3420
3421 * c-typeck.c (pointer_diff): Change -Wpointer-arith pedwarns
3422 to simply use OPT_Wpointer_arith.
3423 (build_unary_op): Likewise.
3424
3425 2013-04-03 Jakub Jelinek <jakub@redhat.com>
3426
3427 PR c/19449
3428 * c-parser.c (c_parser_get_builtin_args): Add choose_expr_p
3429 argument. If set, or it temporarily for parsing of the first
3430 argument into force_folding_builtin_constant_p.
3431 (c_parser_postfix_expression): Adjust callers.
3432
3433 2013-03-21 Richard Biener <rguenther@suse.de>
3434
3435 * c-objc-common.c (c_tree_printer): Use DECL_HAS_DEBUG_EXPR_P
3436 instead of DECL_DEBUG_EXPR_IS_FROM. Guard properly.
3437
3438 2013-02-12 Marek Polacek <polacek@redhat.com>
3439
3440 PR c/44938
3441 * c-parser.c (c_parser_postfix_expression_after_primary): Initialize
3442 origtypes to NULL.
3443
3444 2013-01-24 Jakub Jelinek <jakub@redhat.com>
3445
3446 PR c/56078
3447 * c-typeck.c (set_nonincremental_init_from_string): If
3448 constructor_max_index is NULL, treat it as if tree_int_cst_lt
3449 returned false.
3450 (process_init_element): Likewise.
3451
3452 2012-12-20 Jakub Jelinek <jakub@redhat.com>
3453
3454 PR c++/55619
3455 * c-parser.c (c_parser_asm_operands): Remove CONVERT_P
3456 argument, don't call default_function_array_conversion
3457 nor c_fully_fold here.
3458 (c_parser_asm_statement): Adjust callers.
3459 * c-typeck.c (build_asm_expr): Call c_fully_fold on inputs
3460 and outputs here, and call default_function_array_conversion
3461 on inputs that don't need to be addressable.
3462
3463 2012-12-18 Jakub Jelinek <jakub@redhat.com>
3464
3465 PR c/39464
3466 * c-typeck.c (convert_for_assignment): For -Wpointer-sign
3467 warning require that both c_common_unsigned_type as well as
3468 c_common_signed_type is the same for both mvl and mvr types.
3469
3470 2012-11-16 Diego Novillo <dnovillo@google.com>
3471
3472 Adjust for new vec API (http://gcc.gnu.org/wiki/cxx-conversion/cxx-vec)
3473
3474 * c-common.c: Use new vec API in vec.h.
3475 * c-common.h: Likewise.
3476 * c-gimplify.c: Likewise.
3477 * c-pragma.c: Likewise.
3478 * c-pretty-print.c: Likewise.
3479 * c-pretty-print.h: Likewise.
3480 * c-semantics.c: Likewise.
3481 * c-decl.c: Likewise.
3482 * c-parser.c: Likewise.
3483 * c-tree.h: Likewise.
3484 * c-typeck.c: Likewise.
3485
3486 2012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
3487
3488 PR c++/54930
3489 * c-typeck.c (c_finish_return): Use OPT_Wreturn_local_addr.
3490
3491 2012-10-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
3492
3493 PR c/53066
3494 * c-decl.c (warn_if_shadowing): Do not warn if a variable
3495 shadows a function, unless the variable is a function or a
3496 pointer-to-function.
3497
3498 2012-10-12 Jakub Jelinek <jakub@redhat.com>
3499
3500 PR c/54381
3501 * c-parser.c (struct c_tree_loc_pair): Removed.
3502 (c_parser_expr_list): Remove struct c_tree_loc_pair * argument,
3503 add location_t * and tree * arguments, fill in array of 3
3504 sizeof_arg trees and corresponding locs.
3505 (c_parser_attributes, c_parser_objc_keywordexpr): Adjust
3506 c_parser_expr_list callers.
3507 (c_parser_postfix_expression_after_primary): Likewise. Pass
3508 array of 3 sizeof_arg trees and locs (corresponding to first
3509 3 arguments) to sizeof_pointer_memaccess_warning.
3510
3511 2012-10-09 Lawrence Crowl <crowl@google.com>
3512
3513 * Make-lang.in (c-decl.o): Add dependence on hash-table.h.
3514 * c-decl.c (detect_field_duplicates_hash): Change to new type-safe
3515 hash table.
3516
3517 2012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
3518
3519 PR c++/54194
3520 * c-typeck.c (parser_build_binary_op): Update warn_about_parentheses
3521 call.
3522
3523 2012-10-09 Marc Glisse <marc.glisse@inria.fr>
3524
3525 PR c++/54427
3526 * c-typeck.c: Include c-common.h.
3527 (enum stv_conv): Moved to c-common.h.
3528 (scalar_to_vector): Moved to c-common.c.
3529 (build_binary_op): Adapt to scalar_to_vector's new prototype.
3530 * Make-lang.in: c-typeck.c depends on c-common.h.
3531
3532 2012-10-04 Arnaud Charlet <charlet@adacore.com>
3533
3534 * c-decl.c (c_write_global_declarations): Fix handling of
3535 -fdump-ada-spec*.
3536
3537 2012-09-30 Sharad Singhai <singhai@google.com>
3538
3539 * c-decl.c (c_write_global_declarations): Use a different method
3540 to determine if the dump has ben initialized.
3541
3542 2012-09-14 Joseph Myers <joseph@codesourcery.com>
3543
3544 PR c/54552
3545 * c-typeck.c (c_cast_expr): When casting to a type requiring
3546 C_MAYBE_CONST_EXPR to be created, pass the inner expression to
3547 c_fully_fold first.
3548
3549 2012-09-14 Joseph Myers <joseph@codesourcery.com>
3550
3551 PR c/54103
3552 * c-typeck.c (build_unary_op): Pass original argument of
3553 TRUTH_NOT_EXPR to c_objc_common_truthvalue_conversion, then remove
3554 any C_MAYBE_CONST_EXPR, if it has integer operands.
3555 (build_binary_op): Pass original arguments of TRUTH_ANDIF_EXPR,
3556 TRUTH_ORIF_EXPR, TRUTH_AND_EXPR, TRUTH_OR_EXPR and TRUTH_XOR_EXPR
3557 to c_objc_common_truthvalue_conversion, then remove any
3558 C_MAYBE_CONST_EXPR, if they have integer operands. Use
3559 c_objc_common_truthvalue_conversion not
3560 c_common_truthvalue_conversion.
3561 (c_objc_common_truthvalue_conversion): Build NE_EXPR directly and
3562 call note_integer_operands for arguments with integer operands
3563 that are not integer constants.
3564
3565 2012-09-13 Jakub Jelinek <jakub@redhat.com>
3566
3567 PR c/54559
3568 * c-typeck.c (c_finish_return): Do convert to BOOLEAN_TYPE or
3569 COMPLEX_TYPE with in_late_binary_op set temporarily to true.
3570
3571 2012-08-31 Jakub Jelinek <jakub@redhat.com>
3572
3573 PR c/54428
3574 * c-convert.c (convert): Don't call fold_convert_loc if
3575 TYPE_MAIN_VARIANT of a COMPLEX_TYPE is the same, unless e
3576 is a COMPLEX_EXPR. Remove TYPE_MAIN_VARIANT check from
3577 COMPLEX_TYPE -> COMPLEX_TYPE conversion.
3578
3579 2012-08-24 Jakub Jelinek <jakub@redhat.com>
3580
3581 PR c/54355
3582 * c-decl.c (c_parser_label): Pass true as nested and fix up comments
3583 for nested and empty_ok arguments in the call to
3584 c_parser_declaration_or_fndef.
3585
3586 2012-08-17 Jakub Jelinek <jakub@redhat.com>
3587
3588 * c-tree.h (c_last_sizeof_arg): Declare.
3589 * c-parser.c (struct c_tree_loc_pair): New type.
3590 (c_parser_expr_list): Add sizeof_arg argument. Fill it in if
3591 non-NULL.
3592 (c_parser_attributes, c_parser_objc_keywordexpr): Adjust callers.
3593 (c_parser_postfix_expression_after_primary): Likewise. Call
3594 sizeof_pointer_memaccess_warning if needed.
3595 (sizeof_ptr_memacc_comptypes): New function.
3596 * c-typeck.c (c_last_sizeof_arg): New global variable.
3597 (c_expr_sizeof_expr, c_expr_sizeof_type): Initialize it.
3598
3599 2012-07-24 Uros Bizjak <ubizjak@gmail.com>
3600
3601 * c-lang.h (lang_decl): Add variable_size GTY option.
3602
3603 2012-07-16 Steven Bosscher <steven@gcc.gnu.org>
3604
3605 * c-decl.c: Include dumpfile.h instead of tree-dump.h.
3606 * Make-lang.in: Fix dependencies.
3607
3608 2012-06-29 Steven Bosscher <steven@gcc.gnu.org>
3609
3610 * Make-lang.in: New file, rules migrated from gcc/Makefile.in
3611 and add language Makefile hooks.
3612 * config-lang.in: New file.
3613 * c-config-lang.in: Moved from gcc/config-lang.in to here, and
3614 add the required "normal" config-lang.in rules.
3615 * c-lang.h: Moved from gcc/ to here.
3616 * c-tree.h: Likewise.
3617 * c-objc-common.c: Likewise.
3618 * c-objc-common.h: Likewise.
3619 * c-typeck.c: Likewise.
3620 * c-convert.c: Likewise.
3621 * c-lang.c: Likewise.
3622 * c-aux-info.c: Likewise.
3623 * c-errors.c: Likewise.
3624 * gccspec.c: Likewise.
3625 * c-decl.c: Likewise. Include gt-c-c-decl.h, not gt-c-decl.h.
3626 * c-parser.c: Likewise. Include gt-c-c-parser.h, not gt-c-parser.h.
3627 \f
3628 Copyright (C) 2012-2016 Free Software Foundation, Inc.
3629
3630 Copying and distribution of this file, with or without modification,
3631 are permitted in any medium without royalty provided the copyright
3632 notice and this notice are preserved.