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