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