]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c/ChangeLog
re PR c++/71075 (Broken diagnostic: 'integer_cst' not supported by 'dump_decl')
[thirdparty/gcc.git] / gcc / c / ChangeLog
CommitLineData
e9892350
JG
12016-05-17 James Greenhalgh <james.greenhalgh@arm.com>
2
3 * c-typeck.c (parser_build_unary_op): Fix formatting.
4
8fad45f5
MW
52016-05-16 Matthew Wahab <matthew.wahab@arm.com>
6
7 * c-decl.c (grokdeclarator): Remove errmsg and use of
8 targetm.invalid_return_type.
9 (grokparms): Remove errmsg and use of
10 targetm.invalid_parameter_type.
11
aa4b467b
JM
122016-05-13 Joseph Myers <joseph@codesourcery.com>
13
14 * c-decl.c (grokdeclarator): For C11, discard qualifiers on
15 function return type.
16
4f2e1536
MP
172016-05-12 Marek Polacek <polacek@redhat.com>
18
19 PR c/70756
20 * c-decl.c (build_compound_literal): Pass LOC down to
21 c_incomplete_type_error.
22 * c-tree.h (require_complete_type): Adjust declaration.
23 (c_incomplete_type_error): Likewise.
24 * c-typeck.c (require_complete_type): Add location parameter, pass it
25 down to c_incomplete_type_error.
26 (c_incomplete_type_error): Add location parameter, pass it down to
27 error_at.
28 (build_component_ref): Pass location down to c_incomplete_type_error.
29 (default_conversion): Pass location down to require_complete_type.
30 (build_array_ref): Likewise.
31 (build_function_call_vec): Likewise.
32 (convert_arguments): Likewise.
33 (build_unary_op): Likewise.
34 (build_c_cast): Likewise.
35 (build_modify_expr): Likewise.
36 (convert_for_assignment): Likewise.
37 (c_finish_omp_clauses): Likewise.
38
d6e83a8d
MM
392016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
40
41 PR c/43651
42 * c-decl.c (declspecs_add_qual): Warn when -Wduplicate-decl-specifier
43 is enabled.
44 * c-errors.c (pedwarn_c90): Return true if warned.
45 * c-tree.h (pedwarn_c90): Change return type to bool.
46 (enum c_declspec_word): Add new enumerator cdw_atomic.
47
5c3a10fb
MP
482016-05-11 Marek Polacek <polacek@redhat.com>
49
50 PR c++/71024
51 * c-decl.c (diagnose_mismatched_decls): Factor out code to
52 diagnose_mismatched_attributes and call it.
53
cf68d92c
MP
542016-05-10 Marek Polacek <polacek@redhat.com>
55
56 PR c/70255
57 * c-decl.c (diagnose_mismatched_decls): Warn for optimize attribute
58 on a declaration following the definition.
59
351f85c5
JJ
602016-05-05 Jakub Jelinek <jakub@redhat.com>
61
62 * c-parser.c (c_parser_switch_statement): Add IF_P argument,
63 parse it through to c_parser_c99_block_statement.
64 (c_parser_statement_after_labels): Adjust c_parser_switch_statement
65 caller.
66
deef7113
MP
672016-05-04 Marek Polacek <polacek@redhat.com>
68
69 * c-parser.c (c_parser_if_statement): Replace OPT_Wparentheses with
70 OPT_Wdangling_else.
71
de55efd5
MP
722016-05-04 Marek Polacek <polacek@redhat.com>
73
74 PR c/48778
75 * c-typeck.c (build_binary_op): Don't issue -Waddress warnings
76 for macro expansions.
77
79ce98bc
MP
782016-05-03 Marek Polacek <polacek@redhat.com>
79
80 PR c/70859
81 * c-typeck.c (build_function_call_vec): Pass LOC and ARG_LOC down to
82 check_builtin_function_arguments.
83
fb2647aa
RB
842016-05-03 Richard Biener <rguenther@suse.de>
85
86 * Make-lang.in (cc1-checksum.c): For stage-final re-use
87 the checksum from the previous stage.
88
77886428
CP
892016-05-02 Cesar Philippidis <cesar@codesourcery.com>
90
91 * c-parser.c (c_parser_oacc_all_clauses): Update call to
92 c_finish_omp_clauses.
93 (c_parser_omp_all_clauses): Likewise.
94 (c_parser_oacc_cache): Likewise.
95 (c_parser_oacc_loop): Likewise.
96 (omp_split_clauses): Likewise.
97 (c_parser_omp_declare_target): Likewise.
98 (c_parser_cilk_all_clauses): Likewise.
99 (c_parser_cilk_for): Likewise.
100 * c-typeck.c (c_finish_omp_clauses): Replace bool arguments
101 is_omp, declare_simd, and is_cilk with enum c_omp_region_type ort.
102
7176a4a0
MP
1032016-05-02 Marek Polacek <polacek@redhat.com>
104
105 PR c/70851
106 * c-decl.c (grokdeclarator): Diagnose when array's size has an
107 incomplete type.
108
e7ff0319
CP
1092016-04-29 Cesar Philippidis <cesar@codesourcery.com>
110
111 PR middle-end/70626
112 * c-parser.c (c_parser_oacc_loop): Don't augment mask with
113 OACC_LOOP_CLAUSE_MASK.
114 (c_parser_oacc_kernels_parallel): Update call to
115 c_oacc_split_loop_clauses.
116
9f405ce1
AM
1172016-04-28 Andrew MacLeod <amacleod@redhat.com>
118
119 * c-array-notation.c (fix_builtin_array_notation_fn): Fix final
120 argument to build_modify_expr in two cases.
121
c1e1f433
BS
1222016-04-27 Bernd Schmidt <bschmidt@redhat.com>
123
124 * c-parser.c (c_parser_postfix_expression_after_primary): Call
125 warn_for_memset instead of warning directly here.
126
2448a956
MP
1272016-04-26 Marek Polacek <polacek@redhat.com>
128
129 PR c/67784
130 * c-parser.c (c_parser_maybe_reclassify_token): New function factored
131 out of ...
132 (c_parser_for_statement): ... here.
133 (c_parser_if_statement): Use it.
134 (c_parser_switch_statement): Use it.
135 (c_parser_while_statement): Use it.
136
b02a5e26
MP
137 PR c/70791
138 * c-decl.c (pushdecl): Pass LOCUS down to warning.
139
477d4906
IV
1402016-04-20 Ilya Verbin <ilya.verbin@intel.com>
141
142 PR c++/69363
143 * c-parser.c (c_parser_cilk_all_clauses): Use c_finish_omp_clauses
144 instead of c_finish_cilk_clauses.
145 * c-tree.h (c_finish_omp_clauses): Add new default argument.
146 * c-typeck.c (c_finish_omp_clauses): Add new argument. Allow
147 floating-point variables in the linear clause for Cilk Plus.
148
fe37c7af
MM
1492016-04-18 Michael Matz <matz@suse.de>
150
151 * c-decl.c (merge_decls): Use SET_DECL_ALIGN and SET_TYPE_ALIGN.
152 (grokdeclarator, parser_xref_tag, finish_enum): Use SET_TYPE_ALIGN.
153
949505a9
MP
1542016-04-15 Marek Polacek <polacek@redhat.com>
155
156 PR c/70671
157 * c-typeck.c (build_unary_op): Pass location down to error and
158 warning call.
159
dda1bf61
JJ
1602016-04-15 Jakub Jelinek <jakub@redhat.com>
161
162 PR c/70436
163 * c-parser.c (c_parser_pragma): Add IF_P argument, pass it down
164 where needed.
165 (c_parser_external_declaration, c_parser_struct_or_union_specifier,
166 c_parser_parameter_declaration, c_parser_compound_statement_nostart,
167 c_parser_objc_class_instance_variables, c_parser_objc_methodprotolist):
168 Adjust c_parser_pragma callers.
169 (c_parser_statement_after_labels): Likewise. Adjust c_parser_cilk_for
170 caller.
171 (c_parser_omp_structured_block): Add IF_P argument, pass it down to
172 c_parser_statement.
173 (c_parser_oacc_data, c_parser_oacc_host_data, c_parser_oacc_loop,
174 c_parser_oacc_kernels_parallel, c_parser_omp_critical,
175 c_parser_omp_simd, c_parser_omp_for, c_parser_omp_master,
176 c_parser_omp_ordered, c_parser_omp_parallel, c_parser_omp_single,
177 c_parser_omp_task, c_parser_omp_taskgroup, c_parser_omp_distribute,
178 c_parser_omp_teams, c_parser_omp_target_data, c_parser_omp_target,
179 c_parser_omp_taskloop, c_parser_omp_construct, c_parser_cilk_grainsize,
180 c_parser_cilk_simd, c_parser_cilk_for): Add IF_P argument, pass it
181 down where needed.
182 (c_parser_omp_for_loop): Likewise. Clear IF_P if nbraces.
183 (c_parser_omp_sections_scope): Adjust c_parser_omp_structured_block
184 calls.
185
99cd9857
MP
1862016-04-13 Marek Polacek <polacek@redhat.com>
187
188 PR c/70436
189 * c-parser.c (c_parser_statement_after_labels): Add IF_P argument and
190 adjust callers.
191 (c_parser_statement): Likewise.
192 (c_parser_c99_block_statement): Likewise.
193 (c_parser_while_statement): Likewise.
194 (c_parser_for_statement): Likewise.
195 (c_parser_if_body): Don't set IF_P here.
196 (c_parser_if_statement): Add IF_P argument. Set IF_P here. Warn
197 about dangling else here.
198 * c-tree.h (c_finish_if_stmt): Adjust declaration.
199 * c-typeck.c (c_finish_if_stmt): Remove NESTED_IF parameter. Don't
200 warn about dangling else here.
201
f13355da
MP
2022016-04-04 Marek Polacek <polacek@redhat.com>
203
204 PR c/70307
205 * c-fold.c (c_fully_fold_internal): Handle VEC_COND_EXPR.
206
5fde6a45
MP
2072016-03-31 Marek Polacek <polacek@redhat.com>
208
209 PR c/70297
210 * c-decl.c (merge_decls): Also set TYPE_ALIGN and TYPE_USER_ALIGN.
211
4bbf545b
DM
2122016-03-18 David Malcolm <dmalcolm@redhat.com>
213
214 PR c/70281
215 * c-parser.c (c_parser_postfix_expression): Set the source range
216 for uses of "__builtin_types_compatible_p".
217
fcc2b74f
JJ
2182016-03-17 Jakub Jelinek <jakub@redhat.com>
219
220 PR c/70280
221 * c-typeck.c (composite_type): Don't count void_list_node
222 into len, if the list is terminated by void_list_node, start
223 with void_list_node instead of NULL for newargs. Stop
224 at void_list_node.
225
ab4c578f
MP
2262016-03-16 Marek Polacek <polacek@redhat.com>
227
228 PR c/70093
229 * c-typeck.c (build_function_call_vec): Create a TARGET_EXPR for
230 nested functions returning VM types.
231
96b3c82d
CP
2322016-03-09 Cesar Philippidis <cesar@codesourcery.com>
233
234 * c-parser.c (c_parser_oacc_loop): Update cclauses and clauses
235 when calling c_finish_omp_clauses.
236
29b9828f
BS
2372016-03-04 Bernd Schmidt <bschmidt@redhat.com>
238
239 PR c/69824
240 * c-decl.c (get_parm_info): Don't queue implicit function declarations
241 for later.
242
7ff6ca38
MP
2432016-03-04 Marek Polacek <polacek@redhat.com>
244
245 PR c/69798
246 * c-parser.c (c_parser_postfix_expression): Call
247 c_parser_cast_expression rather than c_parser_postfix_expression.
248
686e2237
JJ
2492016-03-01 Jakub Jelinek <jakub@redhat.com>
250
251 PR c/69796
252 PR c/69974
253 * c-parser.c (c_parser_translation_unit): Don't change TREE_TYPE
254 of incomplete decls to error_mark_node.
255
0b05329b
MP
2562016-02-24 Marek Polacek <polacek@redhat.com>
257
258 PR c/69819
259 * c-decl.c (finish_decl): Don't update the copy of the type of a
260 different decl type.
261
067fbd8b
JJ
2622016-02-23 Jakub Jelinek <jakub@redhat.com>
263
264 PR objc/69844
265 * c-parser.c (c_parser_for_statement): Properly handle ObjC classes
266 in id_kind reclassification.
267
bf14eba2
JJ
2682016-02-16 Jakub Jelinek <jakub@redhat.com>
269
270 PR c/69835
271 * c-typeck.c (build_binary_op): Revert 2015-09-09 change.
272
ba539195
JN
2732016-02-16 James Norris <jnorris@codesourcery.com>
274
275 PR c/64748
276 * c-parser.c (c_parser_oacc_data_clause_deviceptr): Allow parms.
277
16595a1f
BS
2782016-02-12 Bernd Schmidt <bschmidt@redhat.com>
279
f48dfe98
BS
280 * c-decl.c (build_null_declspecs): Zero the entire struct.
281
16595a1f
BS
282 PR c/69522
283 * c-parser.c (c_parser_braced_init): New arg outer_obstack. All
284 callers changed. If nested_p is true, use it to call
285 finish_implicit_inits.
286 * c-tree.h (finish_implicit_inits): Declare.
287 * c-typeck.c (finish_implicit_inits): New function. Move code
288 from ...
289 (push_init_level): ... here.
290 (set_designator, process_init_element): Call finish_implicit_inits.
291
66756373
JJ
2922016-02-11 Jakub Jelinek <jakub@redhat.com>
293
294 PR c/69768
295 * c-typeck.c (parser_build_binary_op): Strip nops from integer_zerop
296 arguments for -Waddress warning.
297
1066e9b5
JJ
2982016-02-04 Jakub Jelinek <jakub@redhat.com>
299
300 PR c/69669
301 * c-decl.c (finish_enum): When honoring mode attribute,
302 make sure to use proper TYPE_MIN_VALUE and TYPE_MAX_VALUE.
303
3a5d2ba4
JJ
3042016-01-29 Jakub Jelinek <jakub@redhat.com>
305
306 PR debug/69518
307 * c-decl.c (finish_struct): Clear C_TYPE_INCOMPLETE_VARS in
308 all type variants, not just TYPE_MAIN_VARIANT.
309
cbdd8ae0
JJ
3102016-01-27 Jakub Jelinek <jakub@redhat.com>
311
312 PR debug/66869
313 * c-decl.c (c_write_global_declarations_1): Warn with
314 warn_unused_function if static prototype without definition
315 is not C_DECL_USED.
316
fa74a4bc
MP
3172016-01-27 Marek Polacek <polacek@redhat.com>
318
319 PR c/68062
320 * c-typeck.c (build_binary_op) [EQ_EXPR, GE_EXPR]: Promote operand
321 to unsigned, if needed. Add -Wsign-compare warning.
322
13f92e8d
JJ
3232016-01-26 Jakub Jelinek <jakub@redhat.com>
324
325 PR tree-optimization/69483
326 * c-parser.c (c_parser_translation_unit): Use FOR_EACH_VEC_ELT.
327
cd8e73dc 3282016-01-20 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
d25c7690
PK
329
330 PR c/24293
331 * c-tree.h (incomplete_record_decls): Declare.
332 * c-parser.c (incomplete_record_decls): Define.
333 (c_parser_translation_unit): Iterate through incomplete_record_decls and
334 report error if any decl has zero size.
335 * c-decl.c (finish_decl): Append static decl with incomplete struct/union
336 or enum type to incomplete_record_decls.
337
e6d6ec9e
TV
3382016-01-14 Tom de Vries <tom@codesourcery.com>
339
340 PR tree-optimization/68773
341 * c-parser.c (c_parser_oacc_declare, c_parser_omp_declare_target): Don't
342 set force_output.
343
00083992
MP
3442016-01-14 Marek Polacek <polacek@redhat.com>
345
346 PR c/69262
347 * c-decl.c (grokdeclarator): Provide more information for invalid
348 array declarations.
349
7443cf13
DM
3502016-01-06 David Malcolm <dmalcolm@redhat.com>
351
352 * c-parser.c (c_parser_unary_expression): For dereferences, build
353 a combined location before calling build_indirect_ref, so that
354 error reports cover the full range, manually updating the c_expr
355 src_range.
356
6b131d5b
MP
3572016-01-06 Marek Polacek <polacek@redhat.com>
358
359 PR sanitizer/69099
360 * c-convert.c (convert) [INTEGER_TYPE]: Drop ARG. Don't pass ARG to
361 ubsan_instrument_float_cast. Fold EXPR. Use NULL_TREE instead of
362 NULL.
363
818ab71a
JJ
3642016-01-04 Jakub Jelinek <jakub@redhat.com>
365
366 Update copyright years.
367
2fe0a208
MP
3682016-01-04 Marek Polacek <polacek@redhat.com>
369
370 PR c/68908
371 * c-typeck.c (build_atomic_assign): Improve commentary. Add
372 optimization to use __atomic_fetch_* built-in if possible.
373
c7b48c8a
TS
3742015-12-23 Thomas Schwinge <thomas@codesourcery.com>
375
376 * c-parser.c (c_parser_oacc_clause_use_device): Merge function
377 into...
378 (c_parser_omp_clause_use_device_ptr): ... this function. Adjust
379 all users.
380
fda5652f
MP
3812015-12-22 Marek Polacek <polacek@redhat.com>
382
383 PR c/69002
384 * c-typeck.c (build_component_ref): Warn when acessing elements of
385 atomic structures or unions.
386
745e411d
DM
3872015-12-21 David Malcolm <dmalcolm@redhat.com>
388
389 * c-typeck.c: Include "gcc-rich-location.h".
390 (build_binary_op): In the two places that call binary_op_error,
391 create a gcc_rich_location and populate it with the location of
392 the binary op and its two operands.
393
94c40e19
DM
3942015-12-16 David Malcolm <dmalcolm@redhat.com>
395
396 * c-parser.c (c_parser_statement_after_labels): When calling
397 c_finish_return, Use the return expression's location if it has
398 one, falling back to the location of the first token within it.
399 * c-typeck.c (c_finish_return): When issuing warnings about
400 the incorrect presence/absence of a return value, issue a note
401 showing the declaration of the function.
402
de67c4c3
DM
4032015-12-16 David Malcolm <dmalcolm@redhat.com>
404
405 * c-parser.c (struct c_parser): Expand array "tokens_buf" from 2
406 to 4.
407 (c_parser_peek_nth_token): New function.
408 (c_parser_peek_conflict_marker): New function.
409 (c_parser_error): Detect conflict markers and report them as such.
410
a10704e1
DM
4112015-12-16 David Malcolm <dmalcolm@redhat.com>
412
413 * c-parser.c (c_parser_postfix_expression): Use EXPR_LOC_OR_LOC
414 to preserve range information for the primary expression
415 in the call to c_parser_postfix_expression_after_primary.
416
8062bca6
DM
4172015-12-16 David Malcolm <dmalcolm@redhat.com>
418
419 * c-parser.c (c_parser_static_assert_declaration_no_semi): Use the
420 expression location, falling back on the first token location,
421 rather than always using the latter.
422
d06f8b75
MP
4232015-12-16 Marek Polacek <polacek@redhat.com>
424
425 PR c/64637
426 * c-typeck.c (c_process_expr_stmt): Use location of the expression if
427 available.
428
2994fb91
MP
4292015-12-15 Marek Polacek <polacek@redhat.com>
430
431 PR c/68907
432 * c-typeck.c (build_atomic_assign): Set TREE_NO_WARNING on an
433 artificial decl.
434
a1b93f8d
DM
4352015-12-08 David Malcolm <dmalcolm@redhat.com>
436
437 * c-parser.c (c_parser_alignof_expression): Capture location of
438 closing parenthesis (if any), or of end of unary expression, and
439 use it to build a src_range for the expression.
440
46c6e1e2
DM
4412015-12-08 David Malcolm <dmalcolm@redhat.com>
442
443 PR c/68757
444 * c-parser.c (c_parser_get_builtin_args): Add
445 "out_close_paren_loc" param, and write back to it.
446 (c_parser_postfix_expression): Capture the closing
447 parenthesis location for RID_CHOOSE_EXPR,
448 RID_BUILTIN_CALL_WITH_STATIC_CHAIN, RID_BUILTIN_COMPLEX,
449 RID_BUILTIN_SHUFFLE and use it to set the source range
450 for such expressions; within RID_BUILTIN_COMPLEX set
451 the underlying location.
452
66189108
MP
4532015-12-07 Marek Polacek <polacek@redhat.com>
454
455 PR c/68668
456 * c-decl.c (grokdeclarator): If ORIG_QUAL_INDIRECT is indirect, use
457 TREE_TYPE of ORIG_QUAL_TYPE, otherwise decrement ORIG_QUAL_INDIRECT.
458
f187980b
EB
4592015-12-04 Eric Botcazou <ebotcazou@adacore.com>
460
461 * c-tree.h (c_build_va_arg): Adjust prototype.
462 * c-parser.c (c_parser_postfix_expression): Adjust call to above.
463 * c-typeck.c (c_build_va_arg): Rename LOC parameter to LOC2, add LOC1
464 parameter, adjust throughout and issue an error if EXPR is a component
465 with reverse storage order.
466
4250754e
JM
4672015-12-02 Jason Merrill <jason@redhat.com>
468
469 * c-fold.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
470 (c_fully_fold_internal, decl_constant_value_for_optimization):
471 Move from c-common.c.
472 * c-tree.h: Declare decl_constant_value_for_optimization.
473 * Make-lang.in (C_AND_OBJC_OBJS): Add c-fold.o.
474
e9e32ee6
JM
4752015-12-02 Joseph Myers <joseph@codesourcery.com>
476
477 PR c/68162
478 * c-decl.c (grokdeclarator): Set first_non_attr_kind before
479 following link from declarator to next declarator. Track original
480 qualified type and pass it to c_build_qualified_type.
481 * c-typeck.c (c_build_qualified_type): Add arguments
482 orig_qual_type and orig_qual_indirect.
483
ff7a55bf
TS
4842015-12-02 Thomas Schwinge <thomas@codesourcery.com>
485
486 * c-parser.c (c_parser_omp_clause_name)
487 (c_parser_oacc_all_clauses): Alphabetical sorting.
488
657e4e47
JJ
4892015-12-02 Jakub Jelinek <jakub@redhat.com>
490
491 PR c/68533
492 * c-decl.c (get_parm_info): Use b->locus instead of input_location
493 for diagnostics.
494
37d5ad46
JB
4952015-12-01 Julian Brown <julian@codesourcery.com>
496 Cesar Philippidis <cesar@codesourcery.com>
497 James Norris <James_Norris@mentor.com>
498
499 * c-parser.c (c_parser_omp_clause_name): Add use_device support.
500 (c_parser_oacc_clause_use_device): New function.
501 (c_parser_oacc_all_clauses): Add use_device support.
502 (OACC_HOST_DATA_CLAUSE_MASK): New macro.
503 (c_parser_oacc_host_data): New function.
504 (c_parser_omp_construct): Add host_data support.
505 * c-tree.h (c_finish_oacc_host_data): Add prototype.
506 * c-typeck.c (c_finish_oacc_host_data): New function.
507 (c_finish_omp_clauses): Add use_device support.
508
a4850ce9
JH
5092015-11-29 Jan Hubicka <hubicka@ucw.cz>
510
511 PR c/67106
512 * c-decl.c: Set TYPE_PACKED in variants.
513
b58d3df2
ML
5142015-11-27 Martin Liska <mliska@suse.cz>
515
516 PR c++/68312
517 * c-array-notation.c (fix_builtin_array_notation_fn):
518 Use release_vec_vec instead of vec::release.
519 (build_array_notation_expr): Likewise.
520 (fix_conditional_array_notations_1): Likewise.
521 (fix_array_notation_expr): Likewise.
522 (fix_array_notation_call_expr): Likewise.
523
aec17bfe
JJ
5242015-11-27 Jakub Jelinek <jakub@redhat.com>
525
526 PR c/63326
527 * c-parser.c (c_parser_compound_statement_nostart): If
528 last_label is true, use pragma_stmt instead of pragma_compound
529 as second c_parser_pragma argument.
530 (c_parser_omp_ordered, c_parser_omp_target_update,
531 c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): Pass
532 false as second argument to c_parser_skip_to_pragma_eol after
533 diagnosing standalone directives used in pragma_stmt context.
534
688c4de0
IV
5352015-11-24 Ilya Verbin <ilya.verbin@intel.com>
536
537 * c-parser.c (c_parser_oacc_declare): Replace "ifdef ENABLE_OFFLOADING"
538 with "if (ENABLE_OFFLOADING)".
539
cbd03aee
DM
5402015-11-23 David Malcolm <dmalcolm@redhat.com>
541
542 PR objc/68438
543 * c-parser.c (c_parser_postfix_expression): Set up source ranges
544 for various Objective-C constructs: Class.name syntax,
545 @selector(), @protocol(), @encode(), and [] message syntax.
546
a87a86e1
DM
5472015-11-20 David Malcolm <dmalcolm@redhat.com>
548
549 PR 62314
550 * c-typeck.c (should_suggest_deref_p): New function.
551 (build_component_ref): Special-case POINTER_TYPE when
552 generating a "not a structure of union" error message, and
553 suggest a "->" rather than a ".", providing a fix-it hint.
554
8ece8dfb
DM
5552015-11-19 David Malcolm <dmalcolm@redhat.com>
556
557 * c-typeck.c (lookup_field_fuzzy): Move determination of closest
558 candidate into a new function, find_closest_identifier.
559
433068cc
MP
5602015-11-19 Marek Polacek <polacek@redhat.com>
561
562 PR c/68412
563 * c-typeck.c (parser_build_binary_op): Properly handle
564 C_MAYBE_CONST_EXPR before calling warn_tautological_cmp.
565
bef08b71
DM
5662015-11-17 David Malcolm <dmalcolm@redhat.com>
567
568 * c-parser.c (set_c_expr_source_range): Bulletproof both
569 overloaded implementations against NULL expr->value.
570 (c_parser_braced_init): Set src_range for "ret" to a sane pair of
571 values.
572 (c_parser_unary_expression): Likewise when handling addresses of
573 labels.
574 (c_parser_postfix_expression): Likewise for statement expressions,
575 for __FUNCTION__, __PRETTY_FUNCTION_ and __func__ keywords, for
576 __builtin_va_arg, and for __builtin_offset_of.
577 (c_parser_postfix_expression_after_paren_type): Initialize expr's
578 src_range using the range of the braced initializer.
579 (c_parser_transaction_expression): Set src_range for "ret" to a
580 sane pair of values.
581
fff77217
KY
5822015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
583
584 * c-parser.c (c_finish_omp_declare_simd): Look for
585 "simd" attribute as well. Update error message.
586
1d899da2
TS
5872015-11-14 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
588
589 * c-parser.c (c_parser_omp_declare_target): Adjust.
590
e4606348
JJ
5912015-11-14 Jakub Jelinek <jakub@redhat.com>
592
593 * c-typeck.c (c_finish_omp_clauses): Don't mark
594 GOMP_MAP_FIRSTPRIVATE_POINTER decls addressable.
595
3e636daf
MP
5962015-11-14 Marek Polacek <polacek@redhat.com>
597
598 * c-decl.c: Use RECORD_OR_UNION_TYPE_P throughout.
599 * c-typeck.c: Likewise.
600
ebedc9a3
DM
6012015-11-13 David Malcolm <dmalcolm@redhat.com>
602
603 * c-decl.c (warn_defaults_to): Pass line_table to
604 rich_location ctor.
605 * c-errors.c (pedwarn_c99): Likewise.
606 (pedwarn_c90): Likewise.
607 * c-parser.c (set_c_expr_source_range): New functions.
608 (c_token::get_range): New method.
609 (c_token::get_finish): New method.
610 (c_parser_expr_no_commas): Call set_c_expr_source_range on the ret
611 based on the range from the start of the LHS to the end of the
612 RHS.
613 (c_parser_conditional_expression): Likewise, based on the range
614 from the start of the cond.value to the end of exp2.value.
615 (c_parser_binary_expression): Call set_c_expr_source_range on
616 the stack values for TRUTH_ANDIF_EXPR and TRUTH_ORIF_EXPR.
617 (c_parser_cast_expression): Call set_c_expr_source_range on ret
618 based on the cast_loc through to the end of the expr.
619 (c_parser_unary_expression): Likewise, based on the
620 op_loc through to the end of op.
621 (c_parser_sizeof_expression) Likewise, based on the start of the
622 sizeof token through to either the closing paren or the end of
623 expr.
624 (c_parser_postfix_expression): Likewise, using the token range,
625 or from the open paren through to the close paren for
626 parenthesized expressions.
627 (c_parser_postfix_expression_after_primary): Likewise, for
628 various kinds of expression.
629 * c-tree.h (struct c_expr): Add field "src_range".
630 (c_expr::get_start): New method.
631 (c_expr::get_finish): New method.
632 (set_c_expr_source_range): New decls.
633 * c-typeck.c (parser_build_unary_op): Call set_c_expr_source_range
634 on ret for prefix unary ops.
635 (parser_build_binary_op): Likewise, running from the start of
636 arg1.value through to the end of arg2.value.
637
ec8b536f
MP
6382015-11-13 Marek Polacek <polacek@redhat.com>
639
640 PR c/68320
641 * c-parser.c (c_parser_for_statement): Treat unknown tokens as IDs.
642
277fe616
DM
6432015-11-13 David Malcolm <dmalcolm@redhat.com>
644
645 * c-typeck.c: Include spellcheck.h.
646 (lookup_field_fuzzy_find_candidates): New function.
647 (lookup_field_fuzzy): New function.
648 (build_component_ref): If the field was not found, try using
649 lookup_field_fuzzy and potentially offer a suggestion.
650
6e232ba4
JN
6512015-11-12 James Norris <jnorris@codesourcery.com>
652 Joseph Myers <joseph@codesourcery.com>
653
654 * c-parser.c (c_parser_pragma): Handle PRAGMA_OACC_DECLARE.
655 (c_parser_omp_clause_name): Handle 'device_resident' clause.
656 (c_parser_oacc_data_clause): Handle PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT
657 and PRAGMA_OMP_CLAUSE_LINK.
658 (c_parser_oacc_all_clauses): Handle PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT
659 and PRAGMA_OACC_CLAUSE_LINK.
660 (OACC_DECLARE_CLAUSE_MASK): New definition.
661 (c_parser_oacc_declare): New function.
662
9be4f715
MP
6632015-11-12 Marek Polacek <polacek@redhat.com>
664
665 PR c/67784
666 * c-parser.c (c_parser_for_statement): Reclassify the token in
667 a correct scope.
668
e78bede6
MP
6692015-11-11 Marek Polacek <polacek@redhat.com>
670
671 PR c/68107
672 PR c++/68266
673 * c-decl.c (grokdeclarator): Call valid_array_size_p. Remove code
674 checking the size of an array.
675
69f293c9
AM
6762015-11-11 Andrew MacLeod <amacleod@redhat.com>
677
678 * c-array-notation.c: Remove unused header files.
679 * c-aux-info.c: Likewise.
680 * c-convert.c: Likewise.
681 * c-decl.c: Likewise.
682 * c-errors.c: Likewise.
683 * c-lang.c: Likewise.
684 * c-objc-common.c: Likewise.
685 * c-parser.c: Likewise.
686 * c-typeck.c: Likewise.
687 * gccspec.c: Likewise.
688
3a40d81d
NS
6892015-11-09 Thomas Schwinge <thomas@codesourcery.com>
690 Cesar Philippidis <cesar@codesourcery.com>
691 James Norris <jnorris@codesourcery.com>
692 Julian Brown <julian@codesourcery.com>
693 Nathan Sidwell <nathan@codesourcery.com>
694
695 c/
696 * c-parser.c (c_parser_declaration_or_fndef): Add OpenACC
697 routine arg.
698 (c_parser_declaration_or_fndef): Call c_finish_oacc_routine.
699 (c_parser_pragma): Parse 'acc routine'.
700 (OACC_ROUTINE_CLAUSE_MARK): Define.
701 (c_parser_oacc_routine, (c_finish_oacc_routine): New.
702
fc402eec
AA
7032015-11-09 Andreas Arnez <arnez@linux.vnet.ibm.com>
704
705 PR debug/67192
706 * c-typeck.c (c_finish_loop): For unconditional loops, set the
707 location of the backward-goto to the start of the loop body.
708
f6b0b3db
AA
7092015-11-09 Andreas Arnez <arnez@linux.vnet.ibm.com>
710
711 PR debug/67192
712 * c-parser.c (c_parser_while_statement): Finish the loop before
713 parsing ahead for misleading indentation.
714 (c_parser_for_statement): Likewise.
715
ee45a32d
EB
7162015-11-08 Eric Botcazou <ebotcazou@adacore.com>
717
718 * c-decl.c (finish_struct): If the structure has reverse storage
719 order, rewrite the type of array fields with scalar component. Call
720 maybe_apply_pragma_scalar_storage_order on entry.
721 * c-typeck.c (build_unary_op) <ADDR_EXPR>: Remove left-overs. Issue
722 errors on bit-fields and reverse SSO here and not...
723 (c_mark_addressable): ...here.
724 (output_init_element): Adjust call to initializer_constant_valid_p.
725 (c_build_qualified_type): Propagate TYPE_REVERSE_STORAGE_ORDER.
726
8a645150
DM
7272015-11-06 David Malcolm <dmalcolm@redhat.com>
728
729 * c-decl.c (warn_defaults_to): Update for change in signature
730 of diagnostic_set_info.
731 * c-errors.c (pedwarn_c99): Likewise.
732 (pedwarn_c90): Likewise.
733 * c-objc-common.c (c_tree_printer): Update for new "caret_p" param
734 for textinfo::set_location.
735
7a5e4956
CP
7362015-11-05 Cesar Philippidis <cesar@codesourcery.com>
737 Thomas Schwinge <thomas@codesourcery.com>
738 James Norris <jnorris@codesourcery.com>
739
740 * c-parser.c (c_parser_omp_clause_name): Add support for
741 PRAGMA_OACC_CLAUSE_INDEPENDENT and PRAGMA_OACC_CLAUSE_TILE.
742 (c_parser_omp_clause_default): Add is_oacc argument. Handle
743 default(none) in OpenACC.
744 (c_parser_oacc_shape_clause): Allow pointer variables as gang static
745 arguments.
746 (c_parser_oacc_clause_tile): New function.
747 (c_parser_oacc_all_clauses): Add support for OMP_CLAUSE_DEFAULT,
748 OMP_CLAUSE_INDEPENDENT and OMP_CLAUSE_TILE.
749 (OACC_LOOP_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_{PRIVATE,INDEPENDENT,
750 TILE}.
751 (OACC_KERNELS_MASK): Add PRAGMA_OACC_CLAUSE_DEFAULT.
752 (OACC_PARALLEL_MASK): Add PRAGMA_OACC_CLAUSE_{DEFAULT,PRIVATE,
753 FIRSTPRIVATE}.
754 (c_parser_omp_all_clauses): Update call to c_parser_omp_clause_default.
755 (c_parser_oacc_update): Update the error message for missing clauses.
756 * c-typeck.c (c_finish_omp_clauses): Add support for OMP_CLAUSE_TILE
757 and OMP_CLAUSE_INDEPENDENT.
758
bfcfbfa0
MP
7592015-11-05 Marek Polacek <polacek@redhat.com>
760
761 PR c/68090
762 * c-parser.c (c_parser_postfix_expression_after_paren_type): Don't
763 deal with pre-evaluation on invalid types.
764
e01d41e5
JJ
7652015-11-05 Jakub Jelinek <jakub@redhat.com>
766 Ilya Verbin <ilya.verbin@intel.com>
767
768 * c-parser.c: Include context.h and gimple-expr.h.
769 (c_parser_omp_clause_schedule): Parse schedule modifiers, diagnose
770 monotonic together with nonmonotonic.
771 (c_parser_omp_for_loop): Call c_omp_check_loop_iv. Call add_stmt here.
772 (OMP_DISTRIBUTE_CLAUSE_MASK): Add lastprivate clause.
773 (c_parser_omp_target_data, c_parser_omp_target_enter_data,
774 c_parser_omp_target_exit_data): Allow GOMP_MAP_ALWAYS_POINTER.
775 (c_parser_omp_target): Likewise. Evaluate num_teams and thread_limit
776 expressions on combined target teams before the target.
777 (c_parser_omp_declare_target): If decl has "omp declare target" or
778 "omp declare target link" attribute, and cgraph or varpool node already
779 exists, then set corresponding flags. Call c_finish_omp_clauses
780 in the parenthesized extended-list syntax case.
781 * c-decl.c (c_decl_attributes): Don't diagnose block scope vars inside
782 declare target.
783 * c-typeck.c (handle_omp_array_sections_1): Allow non-zero low-bound
784 on OMP_CLAUSE_REDUCTION array sections.
785 (handle_omp_array_sections): Encode low-bound into the MEM_REF, either
786 into the constant offset, or for variable low-bound using
787 POINTER_PLUS_EXPR. For structure element based array sections use
788 GOMP_MAP_ALWAYS_POINTER instead of GOMP_MAP_FIRSTPRIVATE_POINTER.
789 (c_finish_omp_clauses): Drop generic_field_head, structure
790 elements are now always mapped even as array section bases,
791 diagnose same var in data sharing and mapping clauses. Diagnose if
792 linear step on declare simd is neither a constant nor a uniform
793 parameter. Look through POINTER_PLUS_EXPR for array section
794 reductions. Diagnose the same var or function appearing multiple
795 times on the same directive. Fix up wording for the to clause if t
796 is neither a FUNCTION_DECL nor a VAR_DECL. Diagnose nonmonotonic
797 modifier on kinds other than dynamic or guided or nonmonotonic
798 modifier together with ordered clause.
799
4bf9e5a8
TS
8002015-11-03 Thomas Schwinge <thomas@codesourcery.com>
801 Chung-Lin Tang <cltang@codesourcery.com>
802
803 * c-parser.c (c_parser_omp_construct): Handle PRAGMA_OACC_ATOMIC.
804
2adfab87
AM
8052015-10-29 Andrew MacLeod <amacleod@redhat.com>
806
807 * c-array-notation.c: Reorder #include's and remove duplicates.
808 * c-aux-info.c: Likewise.
809 * c-convert.c: Likewise.
810 * c-decl.c: Likewise.
811 * c-errors.c: Likewise.
812 * c-lang.c: Likewise.
813 * c-objc-common.c: Likewise.
814 * c-parser.c: Likewise.
815 * c-typeck.c: Likewise.
816
e922069e
JW
8172015-10-26 Jim Wilson <jim.wilson@linaro.org>
818
819 PR debug/66068
820 * c-typeck.c (c_build_qualified_type): Clear C_TYPE_INCOMPLETE_VARS
821 after calling build_qualified_type.
822
765dd391
CP
8232015-10-27 Cesar Philippidis <cesar@codesourcery.com>
824 Thomas Schwinge <thomas@codesourcery.com>
825 James Norris <jnorris@codesourcery.com>
826 Joseph Myers <joseph@codesourcery.com>
827 Julian Brown <julian@codesourcery.com>
828 Bernd Schmidt <bschmidt@redhat.com>
829
830 * c-parser.c (c_parser_oacc_shape_clause): New.
831 (c_parser_oacc_simple_clause): New.
832 (c_parser_oacc_all_clauses): Add auto, gang, seq, vector, worker.
833 (OACC_LOOP_CLAUSE_MASK): Add gang, worker, vector, auto, seq.
834
88bae6f4
TS
8352015-10-27 Thomas Schwinge <thomas@codesourcery.com>
836 James Norris <jnorris@codesourcery.com>
837 Cesar Philippidis <cesar@codesourcery.com>
838
839 PR c/64765
840 PR c/64880
841 * c-parser.c (c_parser_oacc_loop): Add mask, cclauses formal
842 parameters, and handle these. Adjust all users.
843 (c_parser_oacc_kernels, c_parser_oacc_parallel): Merge functions
844 into...
845 (c_parser_oacc_kernels_parallel): ... this new function. Adjust
846 all users.
847 * c-tree.h (c_finish_oacc_parallel, c_finish_oacc_kernels): Don't
848 declare functions.
849 (c_finish_omp_construct): Declare function.
850 * c-typeck.c (c_finish_oacc_parallel, c_finish_oacc_kernels):
851 Merge functions into...
852 (c_finish_omp_construct): ... this new function.
853
a8fc2579
RB
8542015-10-22 Richard Biener <rguenther@suse.de>
855
856 * c-typeck.c (c_finish_omp_clauses): Properly convert operands
857 before folding a MINUS_EXPR.
858
e9122ef6
MP
8592015-10-21 Marek Polacek <polacek@redhat.com>
860
861 PR c/68024
862 * c-decl.c (start_function): Warn about vararg functions without
863 a prototype.
864
9f47c7e5
IE
8652015-10-21 Ilya Enkovich <enkovich.gnu@gmail.com>
866
867 * c-typeck.c (build_conditional_expr): Use boolean vector
868 type for vector comparison.
869 (build_vec_cmp): New.
870 (build_binary_op): Use build_vec_cmp for comparison.
871
fa60eeb9
MP
8722015-10-20 Marek Polacek <polacek@redhat.com>
873
874 * c-parser.c (is_cilkplus_vector_p): Don't define here.
875
2c7020eb
MP
8762015-10-20 Marek Polacek <polacek@redhat.com>
877
878 PR c/67964
879 * c-parser.c (c_parser_attributes): Break out of the loop if the
880 token after an attribute isn't a comma.
881
d9a6bd32
JJ
8822015-10-13 Jakub Jelinek <jakub@redhat.com>
883 Aldy Hernandez <aldyh@redhat.com>
884
885 * c-parser.c (c_parser_pragma): Handle PRAGMA_OMP_ORDERED here.
886 (c_parser_omp_clause_name): Handle OpenMP 4.5 clauses.
887 (c_parser_omp_variable_list): Handle structure elements for
888 map, to and from clauses. Handle array sections in reduction
889 clause. Formatting fixes.
890 (c_parser_omp_clause_if): Add IS_OMP argument, handle parsing of
891 if clause modifiers.
892 (c_parser_omp_clause_num_tasks, c_parser_omp_clause_grainsize,
893 c_parser_omp_clause_priority, c_parser_omp_clause_hint,
894 c_parser_omp_clause_defaultmap, c_parser_omp_clause_use_device_ptr,
895 c_parser_omp_clause_is_device_ptr): New functions.
896 (c_parser_omp_clause_ordered): Parse optional parameter.
897 (c_parser_omp_clause_reduction): Handle array reductions.
898 (c_parser_omp_clause_schedule): Parse optional simd modifier.
899 (c_parser_omp_clause_nogroup, c_parser_omp_clause_orderedkind): New
900 functions.
901 (c_parser_omp_clause_linear): Parse linear clause modifiers.
902 (c_parser_omp_clause_depend_sink): New function.
903 (c_parser_omp_clause_depend): Parse source/sink depend kinds.
904 (c_parser_omp_clause_map): Parse release/delete map kinds and
905 optional always modifier.
906 (c_parser_oacc_all_clauses): Adjust c_parser_omp_clause_if
907 and c_finish_omp_clauses callers.
908 (c_parser_omp_all_clauses): Likewise. Parse OpenMP 4.5 clauses.
909 Parse "to" as OMP_CLAUSE_TO_DECLARE if on declare target directive.
910 (c_parser_oacc_cache): Adjust c_finish_omp_clauses caller.
911 (OMP_CRITICAL_CLAUSE_MASK): Define.
912 (c_parser_omp_critical): Parse critical clauses.
913 (c_parser_omp_for_loop): Handle doacross loops, adjust
914 c_finish_omp_for and c_finish_omp_clauses callers.
915 (OMP_SIMD_CLAUSE_MASK): Add simdlen clause.
916 (c_parser_omp_simd): Allow ordered clause if it has no parameter.
917 (OMP_FOR_CLAUSE_MASK): Add linear clause.
918 (c_parser_omp_for): Disallow ordered clause when combined with
919 distribute. Disallow linear clause when combined with distribute
920 and not combined with simd.
921 (OMP_ORDERED_CLAUSE_MASK, OMP_ORDERED_DEPEND_CLAUSE_MASK): Define.
922 (c_parser_omp_ordered): Add CONTEXT argument, remove LOC argument,
923 parse clauses and if depend clause is found, don't parse a body.
924 (c_parser_omp_parallel): Disallow copyin clause on target parallel.
925 Allow target parallel without for after it.
926 (OMP_TASK_CLAUSE_MASK): Add priority clause.
927 (OMP_TARGET_DATA_CLAUSE_MASK): Add use_device_ptr clause.
928 (c_parser_omp_target_data): Diagnose no map clauses or clauses with
929 invalid kinds.
930 (OMP_TARGET_UPDATE_CLAUSE_MASK): Add depend and nowait clauses.
931 (OMP_TARGET_ENTER_DATA_CLAUSE_MASK,
932 OMP_TARGET_EXIT_DATA_CLAUSE_MASK): Define.
933 (c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): New
934 functions.
935 (OMP_TARGET_CLAUSE_MASK): Add depend, nowait, private, firstprivate,
936 defaultmap and is_device_ptr clauses.
937 (c_parser_omp_target): Parse target parallel and target simd. Set
938 OMP_TARGET_COMBINED on combined constructs. Parse target enter data
939 and target exit data. Diagnose invalid map kinds.
940 (OMP_DECLARE_TARGET_CLAUSE_MASK): Define.
941 (c_parser_omp_declare_target): Parse OpenMP 4.5 forms of this
942 construct.
943 (c_parser_omp_declare_reduction): Use STRIP_NOPS when checking for
944 &omp_priv.
945 (OMP_TASKLOOP_CLAUSE_MASK): Define.
946 (c_parser_omp_taskloop): New function.
947 (c_parser_omp_construct): Don't handle PRAGMA_OMP_ORDERED here,
948 handle PRAGMA_OMP_TASKLOOP.
949 (c_parser_cilk_for): Adjust c_finish_omp_clauses callers.
950 * c-tree.h (c_finish_omp_clauses): Add two new arguments.
951 * c-typeck.c (handle_omp_array_sections_1): Fix comment typo.
952 Add IS_OMP argument, handle structure element bases, diagnose
953 bitfields, pass IS_OMP recursively, diagnose known zero length
954 array sections in depend clauses, handle array sections in reduction
955 clause, diagnose negative length even for pointers.
956 (handle_omp_array_sections): Add IS_OMP argument, use auto_vec for
957 types, pass IS_OMP down to handle_omp_array_sections_1, handle
958 array sections in reduction clause, set
959 OMP_CLAUSE_MAP_MAYBE_ZERO_LENGTH_ARRAY_SECTION if map could be zero
960 length array section, use GOMP_MAP_FIRSTPRIVATE_POINTER for IS_OMP.
961 (c_finish_omp_clauses): Add IS_OMP and DECLARE_SIMD arguments.
962 Handle new OpenMP 4.5 clauses and new restrictions for the old ones.
963
21ba0cea
MP
9642015-10-06 Marek Polacek <polacek@redhat.com>
965
966 * c-parser.c (c_parser_statement_after_labels): Use
967 protected_set_expr_location.
968 (c_parser_omp_clause_num_gangs): Likewise.
969 (c_parser_omp_clause_num_threads): Likewise.
970 (c_parser_omp_clause_num_workers): Likewise.
971 (c_parser_omp_clause_vector_length): Likewise.
972 (c_parser_omp_clause_num_teams): Likewise.
973 (c_parser_omp_clause_thread_limit): Likewise.
974 * c-typeck.c (build_c_cast): Likewise.
975 (c_cast_expr): Likewise.
976
624d31fe
RS
9772015-10-05 Richard Sandiford <richard.sandiford@arm.com>
978
979 * c-typeck.c (c_tree_equal): Use real_equal instead of
980 REAL_VALUES_EQUAL.
981
b8fd7909
JM
9822015-10-04 Jason Merrill <jason@redhat.com>
983
984 * c-parser.c (c_lex_one_token): Handle @synchronized.
985 * c-decl.c (match_builtin_function_types): A declaration of a built-in
986 can change whether the function is transaction_safe.
987
1c7485af
MP
9882015-10-02 Marek Polacek <polacek@redhat.com>
989
990 PR c/67730
991 * c-typeck.c (convert_for_assignment): Use the expansion point
992 location throughout.
993
3e3b8d63
MP
9942015-10-02 Marek Polacek <polacek@redhat.com>
995
996 PR c/64249
997 * c-parser.c (c_parser_statement_after_labels): Add CHAIN parameter
998 and pass it down to c_parser_if_statement.
999 (c_parser_else_body): Add CHAIN parameter and pass it down to
1000 c_parser_statement_after_labels.
1001 (c_parser_if_statement): Add CHAIN parameter. Add code to warn about
1002 duplicated if-else-if conditions.
1003
aabef2de
MP
10042015-10-01 Marek Polacek <polacek@redhat.com>
1005
1006 * c-typeck.c (convert_for_assignment): Improve commentary.
1007
de8ddd5f
MP
10082015-09-30 Marek Polacek <polacek@redhat.com>
1009
1010 PR c/67730
1011 * c-typeck.c (c_finish_return): Use the expansion point location for
1012 certain "return with value" warnings.
1013
c4914de6
MLI
10142015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
1015
1016 * c-parser.c (pragma_lex): Add loc argument.
1017
0e36f5c7
MP
10182015-09-15 Marek Polacek <polacek@redhat.com>
1019
1020 PR c/67580
1021 * c-decl.c (tag_exists_p): New function.
1022 * c-parser.c (c_parser_declaration_or_fndef): Give a hint when
1023 struct/union/enum keywords are missing.
1024 * c-tree.h (tag_exists_p): Declare.
1025
2f3bb934
MP
10262015-09-15 Marek Polacek <polacek@redhat.com>
1027
1028 * c-decl.c (lookup_label): Return NULL_TREE instead of 0.
1029 (lookup_tag): Change the type of THISLEVEL_ONLY to bool.
1030 Return NULL_TREE instead of 0.
1031 (lookup_name): Return NULL_TREE instead of 0.
1032 (lookup_name_in_scope): Likewise.
1033 (shadow_tag_warned): Use true instead of 1 and NULL_TREE instead of 0.
1034 (parser_xref_tag): Use false instead of 0.
1035 (start_struct): Use true instead of 1.
1036 (start_enum): Use true instead of 1 and NULL_TREE instead of 0.
1037
aa256c4a
MP
10382015-09-14 Marek Polacek <polacek@redhat.com>
1039
1040 * c-typeck.c (set_nonincremental_init_from_string): Use
1041 HOST_WIDE_INT_M1U when shifting a negative value.
1042
dbb68221
MW
10432015-09-09 Mark Wielaard <mjw@redhat.com>
1044
1045 * c-typeck.c (build_binary_op): Check and warn when nonnull arg
1046 parm against NULL.
1047
a8a098ac
JJ
10482015-09-10 Jakub Jelinek <jakub@redhat.com>
1049
1050 PR c/67502
1051 * c-parser.c (c_parser_omp_for_loop): Emit DECL_EXPR stmts
1052 into OMP_FOR_PRE_BODY rather than before the loop.
1053
f4b189d5
JJ
10542015-09-09 Jakub Jelinek <jakub@redhat.com>
1055
0bb99c11
JJ
1056 PR c/67501
1057 * c-parser.c (c_parser_oacc_all_clauses,
1058 c_parser_omp_all_clauses): Remove invalid clause from
1059 list of clauses even if parser->error is set.
1060
fce5e5e3
JJ
1061 PR c/67500
1062 * c-parser.c (c_parser_omp_clause_aligned,
1063 c_parser_omp_clause_safelen, c_parser_omp_clause_simdlen): Fix up
1064 test for errors.
1065 * c-decl.c (temp_pop_parm_decls): Allow b->decl equal to
1066 error_mark_node.
1067
f4b189d5
JJ
1068 PR c/67495
1069 * c-parser.c (c_parser_omp_atomic): Use c_parser_cast_expression
1070 instead of c_parser_unary_expression. If the result is !lvalue_p,
1071 wrap the result of c_fully_fold into NON_LVALUE_EXPR.
1072
b2aaf235
MP
10732015-09-04 Marek Polacek <polacek@redhat.com>
1074
1075 PR sanitizer/67279
1076 * c-typeck.c (build_binary_op): Don't instrument static initializers.
1077
1807ffc1
MS
10782015-09-03 Martin Sebor <msebor@redhat.com>
1079
1080 PR c/66516
8b652e65
JJ
1081 * c-typeck.c (convert_arguments, parser_build_unary_op,
1082 build_conditional_expr, c_cast_expr, convert_for_assignment,
1083 build_binary_op, _objc_common_truthvalue_conversion): Call
1807ffc1
MS
1084 reject_gcc_builtin.
1085 (c_decl_implicit): Define.
1086
d04ff417
MP
10872015-09-02 Marek Polacek <polacek@redhat.com>
1088
1089 PR c/67432
1090 * c-parser.c (c_parser_enum_specifier): Give a better error for
1091 an empty enum.
1092
a79683d5
TS
10932015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
1094
1095 * c-aux-info.c, c-parser.c, c-tree.h: Remove useless typedefs.
1096
191a6b94
MP
10972015-08-12 Marek Polacek <polacek@redhat.com>
1098
1099 * c-decl.c (grokdeclarator): Call error_at instead of error and pass
1100 LOC to it.
1101
420a9d9b
MP
11022015-08-03 Marek Polacek <polacek@redhat.com>
1103
1104 PR c/67088
1105 * c-decl.c (check_bitfield_type_and_width): Add location parameter.
1106 Use it.
1107 (grokdeclarator): Pass LOC down to check_bitfield_type_and_width.
1108
992118a1
PP
11092015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
1110
1111 * c-parser.c (c_parser_if_body): Take token_indent_info
1112 argument. Call warn_for_misleading_indentation even when the
1113 body is a semicolon. Extract token_indent_infos corresponding
1114 to the guard, body and next tokens. Adjust call to
1115 warn_for_misleading_indentation accordingly.
1116 (c_parser_else_body): Likewise.
1117 (c_parser_if_statement): Likewise.
1118 (c_parser_while_statement): Likewise.
1119 (c_parser_for_statement): Likewise.
1120
46308474
LFSM
11212015-07-28 Luis Felipe Strano Moraes <luis.strano@gmail.com>
1122 Manuel López-Ibáñez <manu@gcc.gnu.org>
1123
1124 * c-decl.c (get_parm_info): Remove static var. Update warning
1125 message.
1126
05b28fd6
MP
11272015-07-27 Marek Polacek <polacek@redhat.com>
1128
1129 PR c++/66555
1130 PR c/54979
1131 * c-typeck.c (parser_build_binary_op): Call warn_tautological_cmp.
1132
451b5e48
MP
11332015-07-20 Marek Polacek <polacek@redhat.com>
1134
1135 PR c++/55095
1136 * c-typeck.c (digest_init): Pass OPT_Wpedantic to pedwarn_init.
1137 (build_binary_op): Warn about left shift overflows.
1138
1916bcb5
AM
11392015-07-09 Andrew MacLeod <amacleod@redhat.com>
1140
1141 * c-array-notation.c: Adjust includes for flags.h changes.
1142 * c-objc-common.c: Likewise.
1143
c7131fb2
AM
11442015-07-07 Andrew MacLeod <amacleod@redhat.com>
1145
1146 * c-array-notation.c: Adjust includes.
1147 * c-aux-info.c: Likewise.
1148 * c-convert.c: Likewise.
1149 * c-decl.c: Likewise.
1150 * c-errors.c: Likewise.
1151 * c-lang.c: Likewise.
1152 * c-objc-common.c: Likewise.
1153 * c-parser.c: Likewise.
1154 * c-typeck.c: Likewise.
1155
da2e71c9
MLI
11562015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
1157
1158 PR fortran/66605
1159 * c-decl.c (finish_function): Call do_warn_unused_parameter.
1160
b155cfd9
MP
11612015-06-29 Marek Polacek <polacek@redhat.com>
1162
1163 PR c/66322
1164 * c-typeck.c (struct c_switch): Add BOOL_COND_P and OUTSIDE_RANGE_P.
1165 (c_start_case): Set BOOL_COND_P and OUTSIDE_RANGE_P. Don't warn
1166 about -Wswitch-bool here.
1167 (do_case): Update c_add_case_label call.
1168 (c_finish_case): Update c_do_switch_warnings call.
1169
31521951
MP
11702015-06-27 Marek Polacek <polacek@redhat.com>
1171
1172 * c-typeck.c: Use VECTOR_TYPE_P throughout.
1173
22d03525
MP
11742015-06-26 Marek Polacek <polacek@redhat.com>
1175
1176 * c-array-notation.c (fix_builtin_array_notation_fn): Use
1177 INDIRECT_REF_P.
1178 * c-typeck.c (array_to_pointer_conversion): Likewise.
1179 (build_unary_op): Likewise.
1180 (c_finish_return): Likewise.
1181
f0889939
AM
11822015-06-25 Andrew MacLeod <amacleod@redhat.com>
1183
1184 * c-decl.c: Remove ipa-ref.h and plugin-api.h from include list.
1185 * c-parser.c: Likewise.
1186
8d67ee55
RS
11872015-06-25 Richard Sandiford <richard.sandiford@arm.com>
1188
1189 * c-decl.c (detect_field_duplicates_hash): Use nofree_ptr_hash
1190 instead of pointer_hash.
1191 (detect_field_duplicates): Likewise.
1192
0ae9bd27
MP
11932015-06-25 Marek Polacek <polacek@redhat.com>
1194
1195 * c-array-notation.c: Use VAR_P throughout.
1196 * c-decl.c: Likewise.
1197 * c-objc-common.c: Likewise.
1198 * c-parser.c: Likewise.
1199 * c-typeck.c: Likewise.
1200
62f9079a
MP
12012015-06-25 Marek Polacek <polacek@redhat.com>
1202
1203 * c-decl.c: Use is_global_var throughout.
1204 * c-parser.c: Likewise.
1205 * c-typeck.c: Likewise.
1206
abb226c9
AM
12072015-06-17 Andrew MacLeod <amacleod@redhat.com>
1208
1209 * c-array-notation.c: Do not include input.h, line-map.h or is-a.h.
1210 * c-aux-info.c: Likewise.
1211 * c-convert.c: Likewise.
1212 * c-decl.c: Likewise.
1213 * c-errors.c: Likewise.
1214 * c-lang.c: Likewise.
1215 * c-objc-common.c: Likewise.
1216 * c-parser.c: Likewise.
1217 * c-typeck.c: Likewise.
1218
8cbababc
JH
12192015-06-11 Jan Hubicka <hubicka@ucw.cz>
1220
1221 PR middle-end/66325
1222 * c-decl.c (start_enum): Set TYPE_PACKED consistently among type
1223 variants.
1224
a0349665
PMR
12252015-06-11 Pierre-Marie de Rodat <derodat@adacore.com>
1226
1227 * c-decl.c (pop_scope): Register the main translation unit
1228 through the new debug hook.
1229
13fdf2e2
AM
12302015-06-08 Andrew MacLeod <amacleod@redhat.com>
1231
1232 * c-array-notation.c : Adjust include files.
1233 * c-aux-info.c : Likewise.
1234 * c-convert.c : Likewise.
1235 * c-decl.c : Likewise.
1236 * c-errors.c : Likewise.
1237 * c-lang.c : Likewise.
1238 * c-lang.h : Likewise.
1239 * c-objc-common.c : Likewise.
1240 * c-parser.c : Likewise.
1241 * c-typeck.c : Likewise.
1242
d7438551
AH
12432015-06-05 Aldy Hernandez <aldyh@redhat.com>
1244
1245 * c-decl.c (finish_struct): Save C_TYPE_INCOMPLETE_VARS and
1246 immediately clobber it.
1247 (c_write_global_declarations_1): Remove call to
1248 check_global_declaration_1.
1249 (c_write_global_declarations_2): Remove.
1250 (c_write_final_cleanups): Rename from c_write_global_declarations.
1251 Remove call to finalize_compilation_unit.
1252 Remove calls to debugging hooks.
1253 * c-objc-common.c: Adjust comment for c_warn_unused_global_decl.
1254 * c-objc-common.h: Remove LANG_HOOKS_WRITE_GLOBALS.
1255 * c-tree.h: Remove c_write_global_declarations.
1256
ecb9f223
AM
12572015-06-04 Andrew MacLeod <amacleod@redhat.com>
1258
1259 * c-array-notation.c: Adjust includes for restructured coretypes.h.
1260 * c-aux-info.c: Likewise.
1261 * c-convert.c: Likewise.
1262 * c-decl.c: Likewise.
1263 * c-errors.c: Likewise.
1264 * c-lang.c: Likewise.
1265 * c-objc-common.c: Likewise.
1266 * c-parser.c: Likewise.
1267 * c-typeck.c: Likewise.
1268
9482b620
MP
12692015-06-04 Marek Polacek <polacek@redhat.com>
1270
1271 PR c/66341
1272 * c-typeck.c (build_c_cast): Wrap VALUE into NON_LVALUE_EXPR if
1273 it is a lvalue.
1274
bc51ace3
PK
12752015-06-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1276
1277 * c-decl.c (warn_cxx_compat_finish_struct): New parameters code, record_loc.
1278 Warn for empty struct.
1279 (finish_struct): Pass TREE_CODE(t) and loc to warn_cxx_compat_finish_struct.
1280
ea5b45b6
AT
12812015-06-02 Andres Tiraboschi <andres.tiraboschi@tallertechnologies.com>
1282
1283 * c-decl.c (start_function): Call plugin before parsing.
1284 (finish_function): Call plugin after parsing.
1285
c2d47482
PK
12862015-06-02 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
1287
1288 PR c/49551
1289 * c-decl.c (merge_decls): Merge DECL_COMMON.
1290
a95492ab
JW
12912015-05-22 Jim Wilson <jim.wilson@linaro.org>
1292
1293 * Make-lang.in (check_gcc_pallelize): Define.
1294
fd5c817a
MP
12952015-05-22 Marek Polacek <polacek@redhat.com>
1296
1297 PR c/47043
1298 * c-parser.c (c_parser_enum_specifier): Parse and apply enumerator
1299 attributes.
1300
c7b70a3c
MP
13012015-05-21 Marek Polacek <polacek@redhat.com>
1302
1303 * c-typeck.c (inform_declaration): Use DECL_IS_BUILTIN instead of
1304 DECL_BUILT_IN.
1305
21b634ae
MP
13062015-05-20 Marek Polacek <polacek@redhat.com>
1307
1308 * c-decl.c: Use VAR_OR_FUNCTION_DECL_P throughout.
1309 * c-typeck.c: Likewise.
1310
296a8c2f
MP
13112015-05-19 Marek Polacek <polacek@redhat.com>
1312
1313 * c-typeck.c (start_init): Use AGGREGATE_TYPE_P.
1314
41b37d5e
JJ
13152015-05-19 Jakub Jelinek <jakub@redhat.com>
1316
1317 PR middle-end/66199
1318 * c-parser.c (c_parser_omp_for_loop): Don't add
1319 OMP_CLAUSE_SHARED to OMP_PARALLEL_CLAUSES when moving
1320 OMP_CLAUSE_LASTPRIVATE clause to OMP_FOR_CLAUSES.
1321 (c_parser_omp_teams): Set OMP_TEAMS_COMBINED for combined
1322 constructs.
1323
fab27f52
MM
13242015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
1325
1326 * c-typeck.c (build_array_ref): Use std::swap instead of explicit
296a8c2f 1327 swaps.
fab27f52 1328
40de31cf
MLI
13292015-05-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
1330
1331 PR fortran/44054
1332 * c-objc-common.c (c_tree_printer): Replace locus pointer with
1333 accessor function.
1334
3aa3c9fc
MP
13352015-05-14 Marek Polacek <polacek@redhat.com>
1336
1337 PR c/66066
1338 PR c/66127
1339 * c-typeck.c (digest_init): Call pedwarn_init with OPT_Wpedantic
1340 rather than with 0.
1341
c3388e62
DM
13422015-05-12 David Malcolm <dmalcolm@redhat.com>
1343
1344 * c-parser.c (c_parser_if_body): Add param "if_loc", use it
1345 to add a call to warn_for_misleading_indentation.
1346 (c_parser_else_body): Likewise, adding param "else_loc".
1347 (c_parser_if_statement): Check for misleading indentation.
1348 (c_parser_while_statement): Likewise.
1349 (c_parser_for_statement): Likewise.
1350
755e528f
MP
13512015-05-08 Marek Polacek <polacek@redhat.com>
1352
1353 PR c/64918
1354 * c-typeck.c (add_pending_init): Use OPT_Woverride_init_side_effects.
1355 (output_init_element): Likewise.
1356
0173bd2a
MP
13572015-05-07 Marek Polacek <polacek@redhat.com>
1358
1359 PR c/65179
1360 * c-typeck.c (build_binary_op): Warn when left shifting a negative
1361 value.
1362
9babc352
MP
13632015-04-30 Marek Polacek <polacek@redhat.com>
1364
1365 * c-typeck.c (set_init_label): Call error_at instead of error and
1366 pass LOC to it.
1367
ac9f18db
MP
1368 * c-typeck.c (c_incomplete_type_error): Refactor to use %qT. Print
1369 the type of a decl.
1370
ec3fba51
MP
1371 * c-typeck.c (c_build_va_arg): Clarify the error message.
1372
b811915d
TS
13732015-04-29 Thomas Schwinge <thomas@codesourcery.com>
1374
1375 * c-parser.c (c_parser_oacc_enter_exit_data): Use
1376 OMP_STANDALONE_CLAUSES.
1377
f3075008
MP
13782015-04-28 Marek Polacek <polacek@redhat.com>
1379
1380 * c-parser.c (c_parser_binary_expression): Remove duplicate line.
1381
4e81b788
MP
13822015-04-28 Marek Polacek <polacek@redhat.com>
1383
1384 PR c/65901
1385 * c-typeck.c (c_build_va_arg): Require TYPE be a complete type.
1386
6c1db78e
MP
13872015-04-25 Marek Polacek <polacek@redhat.com>
1388
1389 PR c/52085
1390 * c-decl.c (finish_enum): Copy over TYPE_ALIGN. Also check for "mode"
1391 attribute.
1392
5c4abbb8
MP
13932015-04-23 Marek Polacek <polacek@redhat.com>
1394
1395 PR c/65345
1396 * c-decl.c (set_labels_context_r): New function.
1397 (store_parm_decls): Call it via walk_tree_without_duplicates.
1398 * c-typeck.c (convert_lvalue_to_rvalue): Use create_tmp_var_raw
1399 instead of create_tmp_var. Build TARGET_EXPR instead of
1400 COMPOUND_EXPR.
1401 (build_atomic_assign): Use create_tmp_var_raw instead of
1402 create_tmp_var. Build TARGET_EXPRs instead of MODIFY_EXPR.
1403
06aca1d5
IV
14042015-04-20 Ilya Verbin <ilya.verbin@intel.com>
1405
1406 * c-parser.c (c_parser_oacc_enter_exit_data): Remove excess semicolon.
1407 (c_parser_omp_target_update): Add missed %> to error_at ().
1408
8fba1830
BRF
14092015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
1410
1411 PR target/55143
1412 * c-decl.c (c_default_pointer_mode): Remove definition.
1413 * c-tree.h (c_default_pointer_mode): Remove declaration.
1414
62021f64
TB
14152015-03-27 Tobias Burnus <burnus@net-b.de>
1416
1417 PR c/65586
1418 * c-parser.c (c_parser_skip_to_pragma_eol): Optionally, don't
1419 error out.
1420 (c_parser_omp_for, c_parser_omp_parallel, c_parser_omp_distribute,
1421 c_parser_omp_teams, c_parser_omp_target, c_parser_omp_declare):
1422 Update calls to not error for skipped omp pragmas with -fopenmp-simd.
1423
9b65e171
JJ
14242015-03-19 Jakub Jelinek <jakub@redhat.com>
1425
1426 * c-decl.c (c_decl_attributes): Also add "omp declare target"
1427 attribute for DECL_EXTERNAL VAR_DECLs.
1428
17958621
JJ
14292015-03-11 Jakub Jelinek <jakub@redhat.com>
1430
1431 * c-parser.c (c_parse_init): Don't call xstrdup on get_identifier
1432 argument.
1433
7ccb1a11
JJ
14342015-03-10 Jakub Jelinek <jakub@redhat.com>
1435
1436 PR c/65120
1437 * c-typeck.c (parser_build_binary_op): Check for tcc_comparison
1438 before preparing arguments to warn_logical_not_parentheses.
1439
01177669
JJ
14402015-03-09 Jakub Jelinek <jakub@redhat.com>
1441
1442 PR c/65120
1443 * c-typeck.c (parser_build_binary_op): Don't warn for
1444 !!x == y or !b == y where b is _Bool.
1445
802ac282
MP
14462015-03-09 Marek Polacek <polacek@redhat.com>
1447
1448 * c-convert.c (convert): Make use of do_ubsan_in_current_function.
1449 * c-decl.c (grokdeclarator): Likewise.
1450 * c-typeck.c (build_binary_op): Likewise.
1451
e5165b60
MP
14522015-02-27 Marek Polacek <polacek@redhat.com>
1453
1454 PR c/65228
1455 * c-decl.c (start_decl): Return NULL_TREE if decl is an error node.
1456
065d214c
MP
14572015-02-14 Marek Polacek <polacek@redhat.com>
1458
1459 PR c/64768
1460 * c-decl.c (grokdeclarator): Set the range of a flexible array member
1461 declared through a typedef name.
1462
e5d9235b
MP
14632015-02-13 Marek Polacek <polacek@redhat.com>
1464
1465 PR c/65050
1466 * c-decl.c (grokdeclarator): Print also the type when giving
1467 the error message about array's incomplete element type.
1468
fa01ffcc
JJ
14692015-02-11 Jakub Jelinek <jakub@redhat.com>
1470
1471 PR c/64824
1472 * c-parser.c (c_parser_binary_expression): Fix OpenMP stack[sp].prec
1473 check in the POP macro.
1474
c3e38a03
MP
14752015-02-09 Marek Polacek <polacek@redhat.com>
1476
1477 PR c/64856
1478 * c-typeck.c (process_init_element): Don't always wrap
1479 COMPOUND_LITERAL_EXPR in a SAVE_EXPR in C99 mode when
1480 initializing a range of elements.
1481
4886ec8e
JJ
14822015-02-04 Jakub Jelinek <jakub@redhat.com>
1483
1484 PR c/64824
1485 PR c/64868
1486 * c-parser.c (c_parser_omp_atomic): Handle RDIV_EXPR.
1487
c3e38a03 14882015-02-02 Bruno Loff <bruno.loff@gmail.com>
a4bb6959
BL
1489
1490 * c-parser.c (c_parser_declspecs): Call invoke_plugin_callbacks after
1491 processing enum declaration.
1492
7b33f0c8
MP
14932015-01-29 Marek Polacek <polacek@redhat.com>
1494
1495 PR c/64709
1496 * c-typeck.c (pop_init_level): If constructor_elements has
1497 exactly one element with integer_zerop value, set constructor_zeroinit
1498 to 1. Remove braces around warning_init call.
1499
dea63e49
JJ
15002015-01-27 Jakub Jelinek <jakub@redhat.com>
1501
1502 PR c/64766
1503 * c-typeck.c (store_init_value): Don't overwrite DECL_INITIAL
1504 of FUNCTION_DECLs with error_mark_node.
1505
d38f7dce
JJ
15062015-01-26 Jakub Jelinek <jakub@redhat.com>
1507
1508 PR c/64778
1509 * c-typeck.c (convert_arguments): Return -1 if there are
1510 error_args, even if we've diagnosed too many arguments.
1511
cbf5d0e7
RB
15122015-01-21 Richard Biener <rguenther@suse.de>
1513
1514 PR middle-end/64313
1515 * c-decl.c (merge_decls): Call set_builtin_decl_declared_p
1516 for builtins the user declared correctly.
1517
41dbbb37
TS
15182015-01-15 Thomas Schwinge <thomas@codesourcery.com>
1519 Bernd Schmidt <bernds@codesourcery.com>
1520 Cesar Philippidis <cesar@codesourcery.com>
1521 James Norris <jnorris@codesourcery.com>
1522 Jakub Jelinek <jakub@redhat.com>
1523 Ilmir Usmanov <i.usmanov@samsung.com>
1524
1525 * c-parser.c: Include "gomp-constants.h".
1526 (c_parser_omp_clause_map): Use enum gomp_map_kind instead of enum
1527 omp_clause_map_kind. Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.
1528 Use OMP_CLAUSE_SET_MAP_KIND.
1529 (c_parser_pragma): Handle PRAGMA_OACC_ENTER_DATA,
1530 PRAGMA_OACC_EXIT_DATA, PRAGMA_OACC_UPDATE.
1531 (c_parser_omp_construct): Handle PRAGMA_OACC_CACHE,
1532 PRAGMA_OACC_DATA, PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP,
1533 PRAGMA_OACC_PARALLEL, PRAGMA_OACC_WAIT.
1534 (c_parser_omp_clause_name): Handle "auto", "async", "copy",
1535 "copyout", "create", "delete", "deviceptr", "gang", "host",
1536 "num_gangs", "num_workers", "present", "present_or_copy", "pcopy",
1537 "present_or_copyin", "pcopyin", "present_or_copyout", "pcopyout",
1538 "present_or_create", "pcreate", "seq", "self", "vector",
1539 "vector_length", "wait", "worker".
1540 (OACC_DATA_CLAUSE_MASK, OACC_KERNELS_CLAUSE_MASK)
1541 (OACC_ENTER_DATA_CLAUSE_MASK, OACC_EXIT_DATA_CLAUSE_MASK)
1542 (OACC_LOOP_CLAUSE_MASK, OACC_PARALLEL_CLAUSE_MASK)
1543 (OACC_UPDATE_CLAUSE_MASK, OACC_WAIT_CLAUSE_MASK): New macros.
1544 (c_parser_omp_variable_list): Handle OMP_CLAUSE__CACHE_.
1545 (c_parser_oacc_wait_list, c_parser_oacc_data_clause)
1546 (c_parser_oacc_data_clause_deviceptr)
1547 (c_parser_omp_clause_num_gangs, c_parser_omp_clause_num_workers)
1548 (c_parser_oacc_clause_async, c_parser_oacc_clause_wait)
1549 (c_parser_omp_clause_vector_length, c_parser_oacc_all_clauses)
1550 (c_parser_oacc_cache, c_parser_oacc_data, c_parser_oacc_kernels)
1551 (c_parser_oacc_enter_exit_data, c_parser_oacc_loop)
1552 (c_parser_oacc_parallel, c_parser_oacc_update)
1553 (c_parser_oacc_wait): New functions.
1554 * c-tree.h (c_finish_oacc_parallel, c_finish_oacc_kernels)
1555 (c_finish_oacc_data): New prototypes.
1556 * c-typeck.c: Include "gomp-constants.h".
1557 (handle_omp_array_sections): Handle GOMP_MAP_FORCE_DEVICEPTR. Use
1558 GOMP_MAP_* instead of OMP_CLAUSE_MAP_*. Use
1559 OMP_CLAUSE_SET_MAP_KIND.
1560 (c_finish_oacc_parallel, c_finish_oacc_kernels)
1561 (c_finish_oacc_data): New functions.
1562 (c_finish_omp_clauses): Handle OMP_CLAUSE__CACHE_,
1563 OMP_CLAUSE_NUM_GANGS, OMP_CLAUSE_NUM_WORKERS,
1564 OMP_CLAUSE_VECTOR_LENGTH, OMP_CLAUSE_ASYNC, OMP_CLAUSE_WAIT,
1565 OMP_CLAUSE_AUTO, OMP_CLAUSE_SEQ, OMP_CLAUSE_GANG,
1566 OMP_CLAUSE_WORKER, OMP_CLAUSE_VECTOR, and OMP_CLAUSE_MAP's
1567 GOMP_MAP_FORCE_DEVICEPTR.
1568
adfac8df
JJ
15692015-01-09 Michael Collison <michael.collison@linaro.org>
1570
1571 * c-array-notation.c: Include hash-set.h, machmode.h,
1572 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
1573 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
1574 * c-aux-info.c: Ditto.
1575 * c-convert.c: Ditto.
1576 * c-decl.c: Ditto.
1577 * c-errors.c: Ditto.
1578 * c-lang.c: Dittoxs.
1579 * c-objc-common.c: Ditto.
1580 * c-parser.c: Ditto.
1581 * c-typeck.c: Include hash-set.h, machmode.h,
1582 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
1583 fold-const.h, wide-int.h, inchash.h, real.h and
1584 fixed-value.h due to flattening of tree.h.
1585
2cc901dc
MP
15862015-01-07 Marek Polacek <polacek@redhat.com>
1587
1588 PR c/64417
1589 * c-typeck.c (process_init_element): Disallow initialization of
1590 a flexible array member with a string constant if the structure
1591 is in an array.
1592
5624e564
JJ
15932015-01-05 Jakub Jelinek <jakub@redhat.com>
1594
e5341100
JJ
1595 PR sanitizer/64344
1596 * c-typeck.c (convert_for_assignment, c_finish_return): For
1597 -fsanitize=float-cast-overflow casts from REAL_TYPE to integer/enum
1598 types also set in_late_binary_op around convert call.
1599 * c-convert.c (convert): For -fsanitize=float-cast-overflow REAL_TYPE
1600 to integral type casts, if not in_late_binary_op, pass c_fully_fold
1601 result on expr as last argument to ubsan_instrument_float_cast,
1602 if in_late_binary_op, don't use c_save_expr but save_expr.
1603
5624e564
JJ
1604 Update copyright years.
1605
5bd012f8
MP
16062015-01-05 Marek Polacek <polacek@redhat.com>
1607
1608 PR c/64423
1609 * c-typeck.c (build_array_ref): Pass loc down to
1610 warn_array_subscript_with_type_char.
1611
768952be
MU
16122014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
1613
1614 * c-typeck.c: New behavious for pointers to arrays with qualifiers
1615 (common-pointer-type): For pointers to arrays take qualifiers from
1616 element type.
1617 (build_conditional_expr): Add warnings for lost qualifiers.
1618 (comp-target-types): Allow pointers to arrays with different qualifiers.
1619 (convert-for-assignment): Adapt warnings for discarded qualifiers. Add
1620 WARNING_FOR_QUALIFIERS macro and rename WARN_FOR_QUALIFIERS
1621 to PEDWARN_FOR_QUALIFIERS.
1622
8f94a8c4
JJ
16232014-12-17 Jakub Jelinek <jakub@redhat.com>
1624
1625 PR sanitizer/64289
1626 * c-convert.c: Include ubsan.h.
1627 (convert): For real -> integral casts and
1628 -fsanitize=float-cast-overflow don't call convert_to_integer, but
1629 instead instrument the float cast directly.
1630
b731b390
JJ
16312014-11-29 Jakub Jelinek <jakub@redhat.com>
1632
1633 * c-typeck.c (convert_lvalue_to_rvalue, build_atomic_assign,
1634 c_finish_stmt_expr): Remove NULL last argument from
1635 create_tmp_var_raw and create_tmp_var calls.
1636 * c-array-notation.c (fix_builtin_array_notation_fn,
1637 build_array_notation_expr, fix_conditional_array_notations_1,
1638 fix_array_notation_expr, fix_array_notation_call_expr): Likewise.
1639
541e35a6
MP
16402014-11-28 Marek Polacek <polacek@redhat.com>
1641
1642 PR c/63862
1643 * c-typeck.c (build_binary_op) <RSHIFT_EXPR, LSHIFT_EXPR>: Don't
1644 convert the right operand to integer type.
1645
b286be94
MP
16462014-11-25 Marek Polacek <polacek@redhat.com>
1647
1648 PR c/63877
1649 * c-decl.c (start_function): Disable -Wmissing-declarations warning
1650 for inline functions.
1651
aa7da51a
JJ
16522014-11-21 Jakub Jelinek <jakub@redhat.com>
1653
1654 PR target/63764
1655 * c-typeck.c (build_array_ref): Adjust
1656 convert_vector_to_pointer_for_subscript caller. If it returns true,
1657 call non_lvalue_loc on the result.
1658
d876207f
RB
16592014-11-11 Richard Biener <rguenther@suse.de>
1660
1661 * c-decl.c (c_init_decl_processing): Do not set pedantic_lvalues
1662 to true.
1663
e5e44252
AK
16642014-11-10 Andi Kleen <ak@linux.intel.com>
1665
1666 PR c/60804
1667 * c-parser.c (c_parser_statement_after_labels): Call
1668 check_no_cilk.
1669 (c_parser_if_statement): Dito.
1670 (c_parser_switch_statement): Dito.
1671 (c_parser_while_statement): Dito.
1672 (c_parser_do_statement): Dito.
1673 (c_parser_for_statement): Dito.
1674 * c-typeck.c (c_finish_loop): Dito.
1675
13c21655
PC
16762014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
1677
1678 * c-typeck.c (build_binary_op): Use OPT_Wshift_count_negative and
1679 OPT_Wshift_count_overflow in the warnings.
1680
2d51fcef
MP
16812014-10-30 Marek Polacek <polacek@redhat.com>
1682
1683 * c-objc-common.c (c_tree_printer) <case 'T'>: For a typedef name,
1684 print the stripped version as well, if they're not the same.
1685
ef4bddc2
RS
16862014-10-29 Richard Sandiford <richard.sandiford@arm.com>
1687
1688 * c-decl.c, c-tree.h, c-typeck.c: Remove redundant enum from
1689 machine_mode.
1690
c582198b
AM
16912014-10-28 Andrew MacLeod <amacleod@redhat.com>
1692
1693 * c-decl.c: Adjust include files.
1694 * c-parser.c: Ditto.
1695
ddc8de03
PM
16962014-10-27 Phil Muldoon <pmuldoon@redhat.com>
1697 Tom Tromey <tromey@redhat.com>
1698
1699 * c-tree.h (enum c_oracle_request): New.
1700 (c_binding_oracle_function): New typedef.
1701 (c_binding_oracle, c_pushtag, c_bind): Declare.
1702 * c-decl.c (c_binding_oracle): New global.
1703 (I_SYMBOL_CHECKED): New macro.
1704 (i_symbol_binding): New function.
1705 (I_SYMBOL_BINDING, I_SYMBOL_DECL): Redefine.
1706 (I_TAG_CHECKED): New macro.
1707 (i_tag_binding): New function.
1708 (I_TAG_BINDING, I_TAG_DECL): Redefine.
1709 (I_LABEL_CHECKED): New macro.
1710 (i_label_binding): New function.
1711 (I_LABEL_BINDING, I_LABEL_DECL): Redefine.
1712 (c_print_identifier): Save and restore c_binding_oracle.
1713 (c_pushtag, c_bind): New functions.
1714
60393bbc
AM
17152014-10-27 Andrew MacLeod <amacleod@redhat.com>
1716
1717 * c-typeck.c: Adjust include files.
1718
d723bb7c
MLI
17192014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
1720
1721 PR c++/53061
1722 * c-objc-common.c (c_objc_common_init): Do not do diagnostics
1723 initialization here...
1724 (c_initialize_diagnostics): ... but here. Set defaults after
1725 building pretty-printer.
1726
1bc5a451
MP
17272014-10-23 Marek Polacek <polacek@redhat.com>
1728
1729 PR c/63626
1730 * c-decl.c (pop_scope): Don't print warning in external_scope.
1731
4435bb92
MP
17322014-10-19 Marek Polacek <polacek@redhat.com>
1733
1734 PR c/63567
1735 * c-typeck.c (output_init_element): Allow initializing objects with
1736 static storage duration with compound literals even in C99 and add
1737 pedwarn for it.
1738
7278465e
MP
17392014-10-17 Marek Polacek <polacek@redhat.com>
1740
1741 PR c/63567
1742 * c-typeck.c (digest_init): Allow initializing objects with static
1743 storage duration with compound literals even in C99 and add pedwarn
1744 for it.
1745
d9b7be2e
MP
17462014-10-17 Marek Polacek <polacek@redhat.com>
1747
1748 PR c/63543
1749 * c-tree.h (C_TYPE_ERROR_REPORTED): Define.
1750 * c-typeck.c (build_indirect_ref): Don't print the "dereferencing..."
1751 error multiple times. Print the type.
1752
f406ae1f
MP
17532014-10-17 Marek Polacek <polacek@redhat.com>
1754
1755 PR c/63549
1756 * c-typeck.c (build_array_ref): Bail if the index in an incomplete
1757 type.
1758
92574c7c
MP
17592014-10-17 Marek Polacek <polacek@redhat.com>
1760
1761 * c-decl.c (grokdeclarator): Use OPT_Wimplicit_int unconditionally.
1762 (start_function): Use OPT_Wimplicit_int instead of 0.
1763 (store_parm_decls_oldstyle): Likewise.
1764
1bc4a978
MT
17652014-10-17 Alan Modra <amodra@gmail.com>
1766
1767 PR middle-end/61848
1768 * c-decl.c (merge_decls): Don't merge section name or tls model
1769 to newdecl symtab node, instead merge to olddecl. Override
1770 existing olddecl section name. Set tls_model for all thread-local
1771 vars, not just OMP thread-private ones. Remove incorrect comment.
1772
83685514
AM
17732014-10-16 Andrew MacLeod <amacleod@redhat.com>
1774
1775 * c-decl.c: Adjust include files.
1776
78a7c317
DD
17772014-10-14 DJ Delorie <dj@redhat.com>
1778
1779 * c-parser.c (c_parse_init): Add RID entries for each __intN.
1780 (c_token_starts_typename): Check all __intN, not just __int128.
1781 (c_token_starts_declspecs): Likewise.
1782 (c_parser_declspecs): Likewise.
1783 (c_parser_attribute_any_word): Likewise.
1784 (c_parser_objc_selector): Likewise.
1785 * c-tree.h (c_typespec_keyword): cts_int128 -> cts_int_n.
1786 (struct c_declspecs): Add int_n_idx field to record *which* __intN
1787 is specified.
1788 * c-decl.c (declspecs_add_type): Check for all __intN, not just
1789 __int128.
1790 (finish_declspecs): Likewise.
1791
74d98c1e
AB
17922014-10-13 Anthony Brandon <anthony.brandon@gmail.com>
1793
1794 * c-parser.c (c_parser_all_labels): New function to replace
1795 the duplicate code.
1796 (c_parser_statement): Call the new function.
1797
84937de2
MP
17982014-10-09 Marek Polacek <polacek@redhat.com>
1799
1800 PR c/63480
1801 * c-typeck.c (pop_init_level): Don't warn about initializing
1802 with { }.
1803
0382aaa0
MP
18042014-10-07 Marek Polacek <polacek@redhat.com>
1805
1806 PR c/59717
1807 * c-decl.c (header_for_builtin_fn): New function.
1808 (implicitly_declare): Suggest which header to include.
1809
7a0ca710
MP
18102014-10-07 Marek Polacek <polacek@redhat.com>
1811
1812 * c-convert.c (convert): Use error_operand_p.
1813 * c-typeck.c (require_complete_type): Likewise.
1814 (really_atomic_lvalue): Likewise.
1815 (digest_init): Likewise.
1816 (handle_omp_array_sections_1): Likewise.
1817
6bc8a126
MP
18182014-10-03 Marek Polacek <polacek@redhat.com>
1819
1820 PR c/63453
1821 * c-decl.c (pop_scope): Don't warn about "inline function declared
1822 but never defined" for functions marked with gnu_inline attribute.
1823
d90c0a59
JJ
18242014-09-25 Jakub Jelinek <jakub@redhat.com>
1825
1826 PR c++/63249
1827 * c-parser.c (c_parser_omp_variable_list): Call mark_exp_read
1828 on low_bound and length.
1829
083e891e
MP
18302014-09-24 Marek Polacek <polacek@redhat.com>
1831
1832 PR c/61405
1833 PR c/53874
1834 * c-parser.c: Don't define CPP_KEYWORD.
1835 (c_parser_switch_statement): Pass original type to c_finish_case.
1836 * c-tree.h (c_finish_case): Update declaration.
1837 * c-typeck.c (c_finish_case): Add TYPE parameter. Pass it
1838 conditionally to c_do_switch_warnings.
1839
8d95fe25
MP
18402014-09-03 Marek Polacek <polacek@redhat.com>
1841
1842 PR c/62024
1843 * c-parser.c (c_parser_static_assert_declaration_no_semi): Strip no-op
1844 conversions.
1845
9a771876
JJ
18462014-09-02 Jakub Jelinek <jakub@redhat.com>
1847 Balaji V. Iyer <balaji.v.iyer@intel.com>
1848 Igor Zamyatin <igor.zamyatin@intel.com>
1849
1850 * c-parser.c (c_parser_cilk_for): New function.
1851 (c_parser_cilk_grainsize): Likewise.
1852 (c_get_temp_regvar): Likewise.
1853 (c_parser_statement_after_labels): Added RID_CILK_FOR case.
1854 (c_parser_pragma): Added PRAGMA_CILK_GRAINSIZE case.
1855 (c_parser_omp_for_loop): Added CILK_FOR and CILK_SIMD checks.
1856 * c-typeck.c (c_finish_omp_clauses): Added OMP_CLAUSE__CILK_FOR_COUNT_
1857 case.
1858
b7679d96
CG
18592014-08-27 Chen Gang <gang.chen.5i5j@gmail.com>
1860
1861 * c-aux-info.c (gen_type): Resize 'buff' from 10 to 23 bytes,
1862 with using HOST_WIDE_INT without truncation to 'int'
1863
59ea0364
MP
18642014-08-22 Marek Polacek <polacek@redhat.com>
1865
1866 PR c++/62199
1867 * c-typeck.c (parser_build_binary_op): Adjust call to
1868 warn_logical_not_parentheses.
1869
671a475e
IZ
18702014-08-22 Igor Zamyatin <igor.zamyatin@intel.com>
1871
1872 PR other/62008
1873 * c-parser.c (c_parser_array_notation): Check for correct
1874 type of an array added.
1875
04159acf
MP
18762014-08-19 Marek Polacek <polacek@redhat.com>
1877
1878 PR c++/62153
1879 * c-typeck.c (build_binary_op): If either operand of a comparison
1880 is a boolean expression, call maybe_warn_bool_compare.
1881
c77935ee
PP
18822014-08-19 Patrick Palka <ppalka@gcc.gnu.org>
1883
1884 PR c/45584
1885 * c-typeck.c (build_c_cast): Do a conversion even when the
1886 TYPE_MAIN_VARIANTs are the same.
1887
35aff4fb
MP
18882014-08-19 Marek Polacek <polacek@redhat.com>
1889
1890 * c-decl.c (diagnose_mismatched_decls): Unconditionally call
1891 pedwarn_c99 instead of pedwarn.
1892 (grokfield): Likewise.
1893 (warn_defaults_to): New function.
1894 (grokdeclarator): Call warn_defaults_to instead of pedwarn_c99.
1895 Unconditionally call pedwarn_c99 instead of pedwarn.
1896 (start_function): Call warn_defaults_to instead of pedwarn_c99.
1897 (declspecs_add_scspec): Call pedwarn_c99 instead of pedwarn, don't
1898 check flag_isoc11 before.
1899 * c-errors.c (pedwarn_c99): Change the return type to bool.
1900 Handle -Wc99-c11-compat.
1901 * c-parser.c (disable_extension_diagnostics): Handle
1902 warn_c99_c11_compat.
1903 (restore_extension_diagnostics): Likewise.
1904 (c_parser_static_assert_declaration_no_semi): Call pedwarn_c99
1905 instead of pedwarn, don't check flag_isoc11 before.
1906 (c_parser_declspecs): Likewise.
1907 (c_parser_alignas_specifier): Likewise.
1908 (c_parser_alignof_expression): Likewise.
1909 (c_parser_generic_selection): Likewise.
1910 * c-tree.h (pedwarn_c99): Update declaration.
1911 * c-typeck.c (c_finish_return): Call pedwarn or warning_at instead
1912 of pedwarn_c99.
1913
177cce46
MP
19142014-08-19 Marek Polacek <polacek@redhat.com>
1915
1916 * c-decl.c (warn_variable_length_array): Pass OPT_Wvla unconditionally
1917 to pedwarn_c90.
1918 * c-errors.c: Include "opts.h".
1919 (pedwarn_c90): Rewrite to handle -Wno-c90-c99-compat better.
1920 * c-parser.c (disable_extension_diagnostics): Handle negative value
1921 of warn_c90_c99_compat, too.
1922 (restore_extension_diagnostics): Likewise.
1923 (c_parser_compound_statement_nostart): Pass
1924 OPT_Wdeclaration_after_statement unconditionally to pedwarn_c90.
1925
6dc99c33
MP
19262014-08-12 Marek Polacek <polacek@redhat.com>
1927
1928 * c-parser.c (c_parser_postfix_expression) <case RID_FUNCTION_NAME>:
1929 Add pedwarn.
1930 (c_parser_postfix_expression) <case RID_PRETTY_FUNCTION_NAME>:
1931 Likewise.
1932 (c_parser_postfix_expression) <case RID_C99_FUNCTION_NAME>: Likewise.
1933
f3bede71
MP
19342014-08-10 Marek Polacek <polacek@redhat.com>
1935
1936 PR c/51849
1937 * c-decl.c (build_array_declarator): Remove check for !flag_isoc99.
1938 Call pedwarn_c90 instead of pedwarn.
1939 (check_bitfield_type_and_width): Likewise.
1940 (declspecs_add_qual): Likewise.
1941 (declspecs_add_type): Likewise.
1942 (warn_variable_length_array): Unify function for -pedantic and -Wvla.
1943 Adjust to only call pedwarn_c90.
1944 (grokdeclarator): Remove pedantic && !flag_isoc99 check. Call
1945 pedwarn_c90 instead of pedwarn.
1946 * c-errors.c (pedwarn_c90): Handle -Wc90-c99-compat.
1947 * c-parser.c (disable_extension_diagnostics): Handle
1948 warn_c90_c99_compat.
1949 (restore_extension_diagnostics): Likewise.
1950 (c_parser_enum_specifier): Remove check for !flag_isoc99. Call
1951 pedwarn_c90 instead of pedwarn.
1952 (c_parser_initelt): Likewise.
1953 (c_parser_postfix_expression): Likewise.
1954 (c_parser_postfix_expression_after_paren_type): Likewise.
1955 (c_parser_compound_statement_nostart): Remove check for !flag_isoc99.
1956 * c-tree.h: Fix formatting.
1957 * c-typeck.c (build_array_ref): Remove check for !flag_isoc99. Call
1958 pedwarn_c90 instead of pedwarn.
1959
9f25a338
TS
19602014-08-07 Trevor Saunders <tsaunders@mozilla.com>
1961
1962 * c-typeck.c: Remove include of pointer-set.h.
1963
044331a8
MP
19642014-08-07 Marek Polacek <polacek@redhat.com>
1965
1966 * c-typeck.c (pointer_diff): Remove P - (P + CST) optimization.
1967
b787e7a2
TS
19682014-08-02 Trevor Saunders <tsaunders@mozilla.com>
1969
1970 * c-typeck.c: Use hash_map instead of pointer_map.
1971
6e2830c3
TS
19722014-08-02 Trevor Saunders <tsaunders@mozilla.com>
1973
1974 * c-decl.c: Use hash_set instead of pointer_set.
1975
a7ee52fb
IZ
19762014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
1977
1978 PR middle-end/61455
1979 * c-array-notation.c (expand_array_notations): Handling
1980 of DECL_EXPR added.
1981
b4dfdc11
MG
19822014-07-31 Marc Glisse <marc.glisse@inria.fr>
1983
1984 PR c++/60517
1985 * c-typeck.c (c_finish_return): Return 0 instead of the address of
1986 a local variable.
1987
976d5a22
TT
19882014-07-30 Tom Tromey <tromey@redhat.com>
1989
1990 * c-typeck.c (struct constructor_stack) <designator_depth>: New
1991 field.
1992 (really_start_incremental_init, push_init_level): Initialize
1993 designator_depth.
1994 (pop_init_level): Set global designator_depth.
1995 (process_init_element): Check for designated_init attribute.
1996
30281de2
MP
19972014-07-20 Marek Polacek <polacek@redhat.com>
1998
1999 PR c/61852
2000 * c-decl.c (implicit_decl_warning): Add location_t parameter. Use it.
2001 (implicitly_declare): Pass location to implicit_decl_warning.
2002
b108f48f
JJ
20032014-07-14 Jakub Jelinek <jakub@redhat.com>
2004
2005 PR middle-end/61294
2006 * c-parser.c (c_parser_expr_list): Add new argument literal_zero_mask.
2007 If non-NULL, call c_parser_check_literal_zero.
2008 (c_parser_check_literal_zero): New function.
2009 (c_parser_postfix_expression_after_primary): Adjust
2010 c_parser_expr_list caller, handle -Wmemset-transposed-args.
2011
773ec47f
MP
20122014-07-06 Marek Polacek <polacek@redhat.com>
2013
2014 PR c/6940
2015 * c-decl.c (grokdeclarator): Set C_ARRAY_PARAMETER.
2016 * c-tree.h (C_ARRAY_PARAMETER): Define.
2017 * c-typeck.c (c_expr_sizeof_expr): Warn when using sizeof on an array
2018 function parameter.
2019
22e1cf1c
JH
20202014-07-02 Jan Hubicka <hubicka@ucw.cz>
2021 Chen Gang <gang.chen.5i5j@gmail.com>
2022
2023 * c-decl.c (duplicate_decls): CLear DECL_STRUCT_FUNCTION before
2024 releasing symbol.
2025
52ec0ea3
MP
20262014-07-01 Marek Polacek <polacek@redhat.com>
2027
2028 * c-typeck.c (convert_for_assignment): Pass OPT_Wint_conversion
2029 instead of 0 to WARN_FOR_ASSIGNMENT.
2030
d5c3d343
MP
20312014-07-01 Marek Polacek <polacek@redhat.com>
2032
2033 PR c/58286
2034 * c-typeck.c (convert_for_assignment): Pass
2035 OPT_Wincompatible_pointer_types instead of 0 to WARN_FOR_ASSIGNMENT.
2036
6a7253a4
MP
20372014-06-30 Marek Polacek <polacek@redhat.com>
2038
2039 * c-decl.c (grokdeclarator): Don't instrument VLAs if the function
2040 has no_sanitize_undefined attribute.
2041
5e88a8f4
IZ
20422014-06-30 Igor Zamyatin <igor.zamyatin@intel.com>
2043
2044 PR middle-end/57541
2045 * c-array-notation.c (fix_builtin_array_notation_fn):
2046 Check for 0 arguments in builtin call. Check that bultin argument is
2047 correct.
2048 * c-parser.c (c_parser_array_notation): Check for incorrect initial
2049 index.
2050
9698b078
SH
20512014-06-27 Sebastian Huber <sebastian.huber@embedded-brains.de>
2052
2053 * c-parser.c (c_parser_declaration_or_fndef): Discard all type
2054 qualifiers in __auto_type for atomic types.
2055 (c_parser_typeof_specifier): Discard all type qualifiers in
2056 __typeof__ for atomic types.
2057
6e07c515
MP
20582014-06-25 Marek Polacek <polacek@redhat.com>
2059
2060 PR c/61162
2061 * c-parser.c (c_parser_statement_after_labels): Pass the location of
2062 the return expression to c_finish_return.
2063
da6f124d
JJ
20642014-06-25 Jakub Jelinek <jakub@redhat.com>
2065
2066 * c-typeck.c (c_finish_omp_clauses): Make sure
2067 OMP_CLAUSE_LINEAR_STEP has correct type.
2068
c203e8a7
TS
20692014-06-24 Trevor Saunders <tsaunders@mozilla.com>
2070
2071 * c-decl.c: Adjust.
2072
56ad0e38
JJ
20732014-06-24 Jakub Jelinek <jakub@redhat.com>
2074
2075 * c-parser.c (c_parser_omp_for_loop): For
2076 #pragma omp parallel for simd move lastprivate clause from parallel
2077 to for rather than simd.
2078
47c2554f
MP
20792014-06-23 Marek Polacek <polacek@redhat.com>
2080
2081 * c-typeck.c (parser_build_binary_op): Don't call
2082 warn_logical_not_parentheses if the RHS is TRUTH_NOT_EXPR.
2083
56363ffd
JH
20842014-06-15 Jan Hubicka <hubicka@ucw.cz>
2085
2086 * c-parser.c (c_parser_omp_threadprivate): Likewise.
2087 * c-decl.c (merge_decls): Likewise.
2088
d7ff7ae5
MP
20892014-06-09 Marek Polacek <polacek@redhat.com>
2090
2091 PR c/36446
2092 * c-typeck.c (error_init): Call inform instead of error_at.
2093 (pedwarn_init): Call inform instead of pedwarn.
2094 (warning_init): Call inform instead of warning_at.
2095
24d047a3
JH
20962014-06-07 Jan Hubicka <hubicka@ucw.cz>
2097
2098 * c-decl.c (merge_decls): Use set_decl_section_name.
2099 (duplicate_decls): Remove node if it exists.
2100
9bac5cbb
G
21012014-06-05 S. Gilles <sgilles@terpmail.umd.edu>
2102
2103 PR c/53119
2104 * c-typeck.c (push_init_level, process_init_element,
2105 pop_init_level): Correct check for zero initialization, move
2106 missing brace warning to respect zero initialization.
2107
8ffcdea8
MP
21082014-06-05 Marek Polacek <polacek@redhat.com>
2109
2110 PR c/56724
2111 * c-typeck.c (convert_for_assignment): Use expr_loc for ic_argpass.
2112
742938c9
MP
21132014-06-05 Marek Polacek <polacek@redhat.com>
2114
2115 PR c/49706
2116 * c-typeck.c (parser_build_binary_op): Warn when logical not is used
2117 on the left hand side operand of a comparison.
2118
6447c55d
MP
21192014-06-05 Marek Polacek <polacek@redhat.com>
2120
2121 PR c/48062
2122 * c-decl.c (warn_if_shadowing): Call inform instead of warning_at.
2123 Print note only if the warning was printed.
2124
9dc7743c
IZ
21252014-06-04 Igor Zamyatin <igor.zamyatin@intel.com>
2126
2127 PR c/58942
2128 * c-array-notation.c (fix_builtin_array_notation_fn): Handle the case
2129 with a pointer.
2130
fedfecef
MP
21312014-06-03 Marek Polacek <polacek@redhat.com>
2132
2133 PR c/60439
2134 * c-parser.c (c_parser_switch_statement): Pass explicit_cast_p to
2135 c_start_case.
2136 * c-tree.h (c_start_case): Update.
2137 * c-typeck.c (c_start_case): Add new boolean parameter. Warn if
2138 switch condition has boolean value.
2139
9b2b7279
AM
21402014-06-02 Andrew MacLeod <amacleod@redhat.com>
2141
2142 * c-decl.c: Include builtins.h.
2143 * c-parser.c: Likewise.
2144
5c1bc275
MP
21452014-05-27 Marek Polacek <polacek@redhat.com>
2146
2147 PR c/56724
2148 * c-typeck.c (convert_arguments): Get location of a parameter. Change
2149 error and warning calls to error_at and warning_at. Pass location of
2150 a parameter to it. Call warning_at with OPT_Wtraditional_conversion.
2151 (convert_for_assignment): Add parameter to WARN_FOR_ASSIGNMENT and
2152 WARN_FOR_QUALIFIERS. Pass expr_loc to those.
2153
97563bc8
IZ
21542014-05-26 Igor Zamyatin <igor.zamyatin@intel.com>
2155
2156 PR c/61191
2157 * c-array-notation.c (fix_builtin_array_notation_fn): Check invalid
2158 function parameters.
2159
aede2c10
JH
21602014-05-23 Jan Hubicka <hubicka@ucw.cz>
2161
2162 * c-decl.c (merge_decls): Preserve symtab node pointers.
2163 (duplicate_decls): Free new decl.
2164
edbba2ce
TS
21652014-05-23 Thomas Schwinge <thomas@codesourcery.com>
2166
f3316c6d
TS
2167 * c-typeck.c (c_finish_omp_clauses): Remove duplicated variable
2168 initialization.
2169
edbba2ce
TS
2170 * c-parser.c (c_parser_omp_target): Return bool values.
2171
68c81f24
TS
21722014-05-22 Thomas Schwinge <thomas@codesourcery.com>
2173
2174 * c-parser.c (c_parser_omp_clause_thread_limit): Rename
2175 num_teams_loc variable to num_thread_limit_loc.
2176
632f2871
RS
21772014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
2178
2179 * c-array-notation.c (expand_array_notations): Use void_node
2180 instead of void_zero_node.
2181
766090c2
TS
21822014-05-17 Trevor Saunders <tsaunders@mozilla.com>
2183
2184 * c-decl.c (finish_struct): Adjust.
2185 (finish_enum): Likewise.
2186 (bind): Adjust.
2187 (record_inline_static): Likewise.
2188 (push_scope): Likewise.
2189 (make_label): Likewise.
2190 (lookup_label_for_goto): Likewise.
2191 (finish_struct): Likewise.
2192 (finish_enum): Likewise.
2193 (store_parm_decls): Likewise.
2194 (c_push_function_context): Likewise.
2195 * c-lang.h: Remove usage of variable_size gty attribute.
2196 * c-parser.c (c_parse_init): Adjust.
2197 (c_parse_file): Likewise.
2198
2b107f6b
MP
21992014-05-13 Marek Polacek <polacek@redhat.com>
2200
2201 PR c/61162
2202 * c-typeck.c (convert_for_assignment): Pass location to
2203 WARN_FOR_ASSIGNMENT instead of input_location.
2204
d033409e
MP
22052014-05-10 Marek Polacek <polacek@redhat.com>
2206
2207 * c-parser.c (c_parser_declaration_or_fndef): Pass init_loc to
2208 maybe_warn_string_init.
2209 (c_parser_postfix_expression_after_paren_type): Pass type_loc to
2210 maybe_warn_string_init.
2211 * c-tree.h (maybe_warn_string_init): Update declaration.
2212 * c-typeck.c (maybe_warn_string_init): Add location parameter.
2213 Call pedwarn_init with loc instead of with input_location.
2214 (digest_init): Pass init_loc to maybe_warn_string_init.
2215 (pop_init_level): Call pedwarn_init with loc instead of with
2216 input_location.
2217 (set_init_index): Likewise.
2218 (process_init_element): Likewise.
2219
ea58ef42
MP
22202014-05-09 Marek Polacek <polacek@redhat.com>
2221
2222 PR c/61096
2223 * c-parser.c (c_parser_braced_init): Pass brace_loc to push_init_level.
2224 (c_parser_initelt): Pass location to set_init_label. Pass array index
2225 location to set_init_index.
2226 * c-tree.h (push_init_level): Update declaration.
2227 (pop_init_level): Likewise.
2228 (set_init_index): Likewise.
2229 (set_init_label): Likewise.
2230 * c-typeck.c (error_init): Add location parameter. Call error_at
2231 instead of error.
2232 (digest_init): Pass init_loc to error_init.
2233 (really_start_incremental_init):
2234 (push_init_level): Add location parameter. Pass loc to pop_init_level
2235 and error_init.
2236 (pop_init_level): Likewise.
2237 (set_designator): Add location parameter. Pass loc to pop_init_level,
2238 push_init_level, and error_init.
2239 (set_init_index): Add location parameter. Pass loc to error_init and
2240 set_designator.
2241 (set_init_label): Likewise.
2242 (output_init_element): Pass loc to error_init.
2243 (process_init_element): Pass loc to error_init, pop_init_level,
2244 pedwarn_init, and push_init_level.
2245
661a0813
MP
22462014-05-09 Marek Polacek <polacek@redhat.com>
2247
2248 PR c/50459
2249 * c-parser.c (c_parser_attributes): Parse the arguments as an
2250 expression-list if the attribute takes identifier.
2251
2793eeab
MP
22522014-05-08 Marek Polacek <polacek@redhat.com>
2253
2254 PR c/61053
2255 * c-decl.c (grokdeclarator): Use min_align_of_type instead of
2256 TYPE_ALIGN_UNIT.
2257
f827930a
MP
22582014-05-08 Marek Polacek <polacek@redhat.com>
2259
2260 PR c/61077
2261 * c-decl.c (start_function): Warn for _Atomic-qualified return type
2262 of main.
2263
1d60af08
KZ
22642014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
2265 Mike Stump <mikestump@comcast.net>
2266 Richard Sandiford <rdsandiford@googlemail.com>
2267
2268 * c-decl.c (check_bitfield_type_and_width): Use TYPE_SIGN.
2269 (finish_enum): Use wide-int interfaces.
2270 * c-parser.c (c_parser_cilk_clause_vectorlength): Likewise.
2271 * c-typeck.c (build_c_cast): Likewise.
2272 (set_nonincremental_init_from_string): Likewise.
2273 (c_tree_equal): Likewise.
2274
a0e24419
MP
22752014-05-02 Marek Polacek <polacek@redhat.com>
2276
2277 PR c/25801
2278 * c-typeck.c (c_size_in_bytes): Update comment. Don't call error.
2279 Return size_one_node when the type is not complete.
2280 (pointer_diff): Remove comment.
2281 (build_unary_op): Improve error messages.
2282
19fc9faa
MP
22832014-05-02 Marek Polacek <polacek@redhat.com>
2284
2285 * c-typeck.c (c_finish_return): Separate warning_at calls.
2286
63bc4e87
MP
22872014-05-02 Marek Polacek <polacek@redhat.com>
2288
2289 * c-tree.h (error_init): Remove declaration.
2290 (pedwarn_init): Likewise.
2291 * c-typeck.c (error_init): Make static and move above.
2292 (pedwarn_init): Likewise.
2293 (warning_init): Move above.
2294 (maybe_warn_string_init): Likewise.
2295
4bd2511b
JL
22962014-05-01 Jeff Law <law@redhat.com>
2297
2298 Revert:
2299
2300 2014-04-24 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
2301 * c-parser.c (c_parser_sizeof_expression): Reorganize slightly to
2302 avoid goto.
2303
6a358dcb
MP
23042014-05-02 Marek Polacek <polacek@redhat.com>
2305
2306 PR c/60784
2307 * c-typeck.c (push_init_level): Set constructor_designated to
2308 p->designated for structures.
2309
ae5ebda4
MP
23102014-05-01 Marek Polacek <polacek@redhat.com>
2311
2312 PR c/60915
2313 * c-parser.c (c_parser_declaration_or_fndef): Give better error if
2314 function-definition has an attribute after the declarator.
2315
96b40f8d
MP
23162014-05-01 Marek Polacek <polacek@redhat.com>
2317
2318 PR c/60257
2319 * c-typeck.c (warning_init): Add location_t parameter. Call
2320 warning_at instead of warning.
2321 (push_init_level): Pass input_location to warning_init.
2322 (add_pending_init): Add location_t parameter. Pass loc to
2323 warning_init.
2324 (set_nonincremental_init): Pass input_location to add_pending_init.
2325 (set_nonincremental_init_from_string): Likewise.
2326 (output_init_element): Pass loc to warning_init and to
2327 add_pending_init.
2328
32e00768
MP
23292014-05-01 Marek Polacek <polacek@redhat.com>
2330
2331 PR c/43395
2332 * c-typeck.c (c_finish_return): Distinguish between label and variable
2333 when warning about returning local address.
2334
c9379ce2
MP
23352014-05-01 Marek Polacek <polacek@redhat.com>
2336
2337 PR c/29467
2338 * c-decl.c (declspecs_add_type): Pedwarn if boolean types are used
2339 in C89 mode.
2340
d00887e8
MP
23412014-05-01 Marek Polacek <polacek@redhat.com>
2342
2343 PR c/43245
2344 * c-typeck.c (convert_for_assignment): Pass OPT_Wdiscarded_qualifiers
2345 instead of 0 to WARN_FOR_QUALIFIERS.
2346
5436fa2e
MP
23472014-05-01 Marek Polacek <polacek@redhat.com>
2348
2349 PR c/56989
2350 * c-typeck.c (default_conversion): Use better location for
2351 error call.
2352
f8ed5150
MP
23532014-04-30 Marek Polacek <polacek@redhat.com>
2354
2355 * c-typeck.c (build_binary_op): Call ubsan_instrument_division
2356 also when SANITIZE_FLOAT_DIVIDE is on.
2357
8337d1db
MP
23582014-04-30 Marek Polacek <polacek@redhat.com>
2359
2360 PR c/60139
2361 * c-typeck.c (output_init_element): Pass OPT_Wpedantic to pedwarn
2362 and pedwarn_init. Use loc insted of input_location.
2363
c4bdc42f
MP
23642014-04-30 Marek Polacek <polacek@redhat.com>
2365
2366 PR c/60351
2367 * c-typeck.c (build_binary_op): Use location when warning about
2368 shift count.
2369
45484dcf
MP
23702014-04-25 Marek Polacek <polacek@redhat.com>
2371
2372 PR c/18079
2373 * c-decl.c (diagnose_mismatched_decls): Warn for mismatched
2374 always_inline/noinline and hot/cold attributes.
2375
34cf811f
MP
23762014-04-25 Marek Polacek <polacek@redhat.com>
2377
2378 PR c/60114
2379 * c-parser.c (c_parser_initelt): Pass input_location to
2380 process_init_element.
2381 (c_parser_initval): Pass loc to process_init_element.
2382 * c-tree.h (process_init_element): Adjust declaration.
2383 * c-typeck.c (push_init_level): Pass input_location to
2384 process_init_element.
2385 (pop_init_level): Likewise.
2386 (set_designator): Likewise.
2387 (output_init_element): Add location_t parameter. Pass loc to
2388 digest_init.
2389 (output_pending_init_elements): Pass input_location to
2390 output_init_element.
2391 (process_init_element): Add location_t parameter. Pass loc to
2392 output_init_element.
2393
42056eac
JJ
23942014-04-24 Jakub Jelinek <jakub@redhat.com>
2395
2396 * c-parser.c (c_parser_omp_atomic): Allow seq_cst before
2397 atomic-clause, allow comma in between atomic-clause and
2398 seq_cst.
2399
e162a134
JJ
24002014-04-22 Jakub Jelinek <jakub@redhat.com>
2401
2402 PR c/59073
2403 * c-parser.c (c_parser_omp_parallel): If c_parser_omp_for
2404 fails, don't set OM_PARALLEL_COMBINED and return NULL.
2405
2f6babac
IZ
24062014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
2407
2408 PR middle-end/60469
2409 * c-array-notation.c (fix_builtin_array_notation_fn): Use
2410 create_tmp_var instead build_decl for creating temps.
2411 (build_array_notation_expr): Likewise.
2412 (fix_conditional_array_notations_1): Likewise.
2413 (fix_array_notation_expr): Likewise.
2414 (fix_array_notation_call_expr): Likewise.
2415
8edbfaa6
JJ
24162014-03-28 Jakub Jelinek <jakub@redhat.com>
2417
2418 PR c++/60689
2419 * c-tree.h (c_build_function_call_vec): New prototype.
2420 * c-typeck.c (build_function_call_vec): Don't call
2421 resolve_overloaded_builtin here.
2422 (c_build_function_call_vec): New wrapper function around
2423 build_function_call_vec. Call resolve_overloaded_builtin here.
2424 (convert_lvalue_to_rvalue, build_function_call, build_atomic_assign):
2425 Call c_build_function_call_vec instead of build_function_call_vec.
2426 * c-parser.c (c_parser_postfix_expression_after_primary): Likewise.
2427 * c-decl.c (finish_decl): Likewise.
2428
7485aeea
MLI
24292014-03-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
2430
2431 PR c/55383
2432 * c-typeck.c: Use correct format string in cast-qual warning
2433
b17a8b07
TS
24342014-03-07 Thomas Schwinge <thomas@codesourcery.com>
2435
2436 * c-decl.c (c_decl_attributes): Use
2437 lang_hooks.types.omp_mappable_type.
2438 * c-typeck.c (c_finish_omp_clauses): Likewise.
2439
3af9c5e9
MP
24402014-03-06 Marek Polacek <polacek@redhat.com>
2441
2442 PR c/60197
2443 * c-typeck.c (c_finish_return): Call contains_cilk_spawn_stmt instead
2444 of checking tree code.
2445
1c9f5f33
PK
24462014-02-19 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
2447
2448 * c-parser.c (c_parser_declspecs): Replace call to error by error_at.
2449 (c_parser_parameter_declaration): Likewise.
2450
cc28fc7f
MP
24512014-02-19 Marek Polacek <polacek@redhat.com>
2452
2453 PR c/60195
2454 * c-typeck.c (convert_lvalue_to_rvalue): Set TREE_NO_WARNING on tmp.
2455 Call mark_exp_read on exp.value.
2456 (build_atomic_assign): Set TREE_NO_WARNING on val and old. Set
2457 TREE_ADDRESSABLE on old instead of val.
2458 (emit_side_effect_warnings): Warn only if RHS has !TREE_NO_WARNING.
2459
b581c05c
PK
24602014-02-07 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
2461
2462 * c-parser.c (c_parser_get_builtin_args): Replace calls to
2463 C_EXPR_APPEND by vec_safe_push.
2464 * c-tree.h (C_EXPR_APPEND): Remove.
2465
81e5eca8
MP
24662014-01-31 Marek Polacek <polacek@redhat.com>
2467
2468 PR c/59963
2469 * c-typeck.c (convert_lvalue_to_rvalue): Pass vNULL to
2470 build_function_call_vec.
2471 (build_function_call): Likewise.
2472 (build_atomic_assign): Likewise.
2473 (build_function_call_vec): Add arg_loc parameter. Use it.
2474 (convert_arguments): Likewise.
2475 (convert_for_assignment): Rename rhs_loc to expr_loc.
2476 * c-parser.c (c_parser_attributes): Pass NULL to c_parser_expr_list.
2477 (c_parser_objc_keywordexpr): Likewise.
2478 (c_parser_postfix_expression_after_primary): Call
2479 build_function_call_vec with expr_loc rather than op_loc.
2480 Call c_parser_expr_list to fill arg_loc. Pass arg_loc to
2481 build_function_call_vec.
2482 (c_parser_expr_list): Add locations parameter. Fill it with locations
2483 of function arguments.
2484 * c-decl.c (finish_decl): Pass vNULL to build_function_call_vec.
2485
68fca595
MP
24862014-01-30 Marek Polacek <polacek@redhat.com>
2487
2488 PR c/59940
2489 * c-typeck.c (build_function_call_vec): Use loc parameter.
2490 (convert_arguments): Add location parameter. Use it.
2491 (ep_convert_and_check): Likewise.
2492 (build_atomic_assign): Adjust convert_for_assignment call.
2493 (build_modify_expr): Likewise.
2494 (digest_init): Likewise.
2495 (c_finish_return): Likewise.
2496 (build_conditional_expr): Adjust ep_convert_and_check calls.
2497 (convert_for_assignment): Add rhs_loc parameter. Use it.
2498 (build_binary_op): Adjust convert_and_check and ep_convert_and_check
2499 calls.
2500
fa337f3a
RB
25012014-01-30 Richard Biener <rguenther@suse.de>
2502
2503 PR c/59905
2504 * c-typeck.c (build_function_call_vec): Do not replace calls
2505 to a function via an incompatible type with a runtime abort.
2506
b72271b9
BI
25072014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
2508
2509 * c-parser.c (c_parser_declaration_or_fndef): Replaced
2510 flag_enable_cilkplus with flag_cilkplus.
2511 (c_parser_direct_declarator_inner): Likewise.
2512 (c_parser_attribute_any_word): Likewise.
2513 (c_parser_attributes): Likewise.
2514 (c_parser_compound_statement): Likewise.
2515 (c_parser_statement_after_labels): Likewise.
2516 (c_parser_if_statement): Likewise.
2517 (c_parser_switch_statement): Likewise.
2518 (c_parser_do_statement): Likewise.
2519 (c_parser_for_statement): Likewise.
2520 (c_parser_unary_expression): Likewise.
2521 (c_parser_postfix_expression): Likewise.
2522 (c_parser_postfix_expression_after_primary): Likewise.
2523 (c_parser_postfix_expression_after_primary): Likewise.
2524 (c_parser_omp_clause_name): Likewise.
2525 (c_finish_omp_declare_simd): Likewise.
2526 (c_parser_cilk_verify_simd): Likewise.
2527 * c-typeck.c (build_array_ref): Likewise.
2528 (build_function_call_vec): Likewise.
2529 (convert_arguments): Likewise.
2530 (build_compound_expr): Likewise.
2531 (c_finish_return): Likewise.
2532 (c_finish_if_stmt): Likewise.
2533 (c_finish_loop): Likewise.
2534 (build_binary_op): Likewise.
2535
393e8e8b
MP
25362014-01-23 Marek Polacek <polacek@redhat.com>
2537
2538 PR c/59846
2539 * c-typeck.c (parser_build_binary_op): Use location instead of
2540 input_location.
2541 (build_binary_op): Pass location to shorten_compare.
2542
f04dda30
MP
25432014-01-23 Marek Polacek <polacek@redhat.com>
2544
2545 PR c/58346
2546 * c-typeck.c (pointer_diff): Give an error on arithmetic on pointer to
2547 an empty aggregate.
2548
789eadcd
MP
25492014-01-23 Marek Polacek <polacek@redhat.com>
2550
2551 PR c/59871
2552 * c-typeck.c (build_compound_expr): Warn even for right-hand operand
2553 of a comma expression.
2554 (emit_side_effect_warnings): Likewise.
2555
40f14e9f
BI
25562014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com>
2557
2558 PR c/59825
2559 * c-array-notation.c (expand_array_notation_exprs): Rewrote this
2560 function to use walk_tree and moved a lot of its functionality to
2561 expand_array_notations.
2562 (expand_array_notations): New function.
2563
74558dd9
BI
25642014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com>
2565
2566 * c-parser.c (c_finish_omp_declare_simd): Made "cilk simd function"
2567 attribute an attribute without value.
2568
652fea39
JJ
25692014-01-23 Jakub Jelinek <jakub@redhat.com>
2570
2571 PR middle-end/58809
2572 * c-typeck.c (c_finish_omp_clause): Reject MIN_EXPR, MAX_EXPR,
2573 BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR on COMPLEX_TYPEs.
2574
f34f1c87
MP
25752014-01-22 Marek Polacek <polacek@redhat.com>
2576
2577 PR c/59891
2578 * c-typeck.c (build_conditional_expr): Call c_fully_fold instead
2579 of remove_c_maybe_const_expr on op1 and op2.
2580
241f845a
JJ
25812014-01-15 Jakub Jelinek <jakub@redhat.com>
2582
2583 PR c/58943
2584 * c-typeck.c (build_modify_expr): For lhs op= rhs, if rhs has side
2585 effects, preevaluate rhs using SAVE_EXPR first.
2586
9a74f20c
BI
25872014-01-09 Balaji V. Iyer <balaji.v.iyer@intel.com>
2588
2589 PR c++/59631
2590 * c-parser.c (c_parser_postfix_expression): Replaced consecutive if
2591 statements with if-elseif statements.
2592
96066ce1
MP
25932014-01-06 Marek Polacek <polacek@redhat.com>
2594
2595 PR c/57773
2596 * c-decl.c (check_bitfield_type_and_width): Warn for implementation
2597 defined bit-field types only in ISO C.
2598
23a5b65a
RS
25992014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
2600
2601 Update copyright years
2602
f9030485
RS
26032014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
2604
2605 * c-array-notation.c: Use the standard form for the copyright notice.
2606
41958c28
BI
26072013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
2608
2609 * c-parser.c (struct c_parser::cilk_simd_fn_tokens): Added new field.
2610 (c_parser_declaration_or_fndef): Added a check if cilk_simd_fn_tokens
2611 field in parser is not empty. If not-empty, call the function
2612 c_parser_finish_omp_declare_simd.
2613 (c_parser_cilk_clause_vectorlength): Modified function to be shared
2614 between SIMD-enabled functions and #pragma simd. Added new parameter.
2615 (c_parser_cilk_all_clauses): Modified the usage of the function
2616 c_parser_cilk_clause_vectorlength as mentioned above.
2617 (c_parser_cilk_simd_fn_vector_attrs): New function.
2618 (c_finish_cilk_simd_fn_tokens): Likewise.
2619 (is_cilkplus_vector_p): Likewise.
2620 (c_parser_omp_clause_name): Added checking for "vectorlength,"
2621 "nomask," and "mask" strings in clause name.
2622 (c_parser_omp_all_clauses): Added 3 new case statements:
2623 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_MASK and
2624 PRAGMA_CILK_CLAUSE_NOMASK.
2625 (c_parser_attributes): Added a cilk_simd_fn_tokens parameter. Added a
2626 check for vector attribute and if so call the function
2627 c_parser_cilk_simd_fn_vector_attrs. Also, when Cilk plus is enabled,
2628 called the function c_finish_cilk_simd_fn_tokens.
2629 (c_finish_omp_declare_simd): Added a check if cilk_simd_fn_tokens in
2630 parser field is non-empty. If so, parse them as you would parse
2631 the omp declare simd pragma.
2632 (c_parser_omp_clause_linear): Added a new bool parm. is_cilk_simd_fn.
2633 Added a check when step is a parameter and flag it as error.
2634 (CILK_SIMD_FN_CLAUSE_MASK): New #define.
2635 (c_parser_cilk_clause_name): Changed pragma_cilk_clause to
2636 pragma_omp_clause.
2637
cef0fd0e
TS
26382013-12-17 Thomas Schwinge <thomas@codesourcery.com>
2639
2640 * c-parser.c (c_parser_omp_parallel): Fix description.
2641
12893402
BI
26422013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
2643
2644 * c-objc-common.h (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Remove.
2645 (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise.
2646 (LANG_HOOKS_CILKPLUS_CILKPLUS_GIMPLIFY_SPAWN): Likewise.
2647 * c-typeck.c (cilk_install_body_with_frame_cleanup): New function.
2648
296674db
JM
26492013-12-04 Joseph Myers <joseph@codesourcery.com>
2650
2651 PR c/52023
2652 * c-parser.c (c_parser_alignas_specifier): Use
2653 c_sizeof_or_alignof_type instead of c_alignof.
2654 (c_parser_alignof_expression): Likewise, with min_alignof
2655 parameter depending on alignof spelling used.
2656
edd28054
MP
26572013-12-04 Marek Polacek <polacek@redhat.com>
2658
2659 PR c/54113
2660 * c-decl.c (start_function): Don't warn for missing prototype for
2661 inline functions.
2662
da0fc454
MP
26632013-12-03 Marek Polacek <polacek@redhat.com>
2664
2665 PR c/59351
2666 * c-decl.c (build_compound_literal): Allow compound literals with
2667 empty initial value.
2668
4c2ecab0
JM
26692013-12-02 Joseph Myers <joseph@codesourcery.com>
2670
2671 PR c/58235
2672 * c-typeck.c (build_modify_expr): Diagnose assignment to
2673 expression with array type.
2674
340baef7
JM
26752013-11-29 Joseph Myers <joseph@codesourcery.com>
2676
2677 PR c/42262
2678 * c-typeck.c (process_init_element): Do not treat a string as
2679 initializing a whole array when used with a designator for an
2680 individual element.
2681
6763b9f7
JM
26822013-11-29 Joseph Myers <joseph@codesourcery.com>
2683
2684 PR c/57574
2685 * c-decl.c (merge_decls): Clear DECL_EXTERNAL for a definition of
2686 an inline function following a static declaration.
2687
e7bd1de1
JJ
26882013-11-28 Jakub Jelinek <jakub@redhat.com>
2689
2690 PR c/59310
2691 * c-parser.c (c_parser_omp_target): Copy "#pragma omp target"
2692 to p_name before calling c_parser_omp_teams instead of after.
2693 (c_parser_cilk_simd): Remove wrong ATTRIBUTE_UNUSED from parser
2694 argument. Remove unused p_name variable.
2695
0136f8f0
AH
26962013-11-27 Aldy Hernandez <aldyh@redhat.com>
2697 Jakub Jelinek <jakub@redhat.com>
2698
2699 * c-decl.c (c_builtin_function_ext_scope): Avoid binding if
2700 external_scope is NULL.
2701
241b71bb
TV
27022013-11-27 Tom de Vries <tom@codesourcery.com>
2703 Marc Glisse <marc.glisse@inria.fr>
2704
2705 PR c++/59032
2706 * c-typeck.c (build_unary_op): Allow vector increment and decrement.
2707
2fb9a547
AM
27082013-11-22 Andrew MacLeod <amacleod@redhat.com>
2709
2710 * c-typeck.c: Add required include files from gimple.h.
2711
8400e75e
DM
27122013-11-22 David Malcolm <dmalcolm@redhat.com>
2713
2714 * c-decl.c (define_label, shadow_tag_warned)
2715 (check_bitfield_type_and_width, grokdeclarator, grokparms,
2716 store_parm_decls_newstyle, store_parm_decls_oldstyle)
2717 (declspecs_add_type): Remove use of in_system_header macro.
2718 * c-parser.c (c_parser_unary_expression): Likewise.
2719 * c-typeck.c (store_init_value, process_init_element)
2720 (c_start_case): Likewise.
2721
2722 * c-decl.c (build_enumerator): Remove use of EXPR_LOC_OR_HERE
2723 macro.
2724
2725 * c-parser.c (c_parser_set_source_position_from_token): Remove
2726 reference to in_system_header from comment.
2727
386b1f1f
RS
27282013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2729
2730 * c-decl.c (grokdeclarator): Update comment to refer to
2731 tree_to_[su]hwi rather than tree_low_cst.
2732
ae7e9ddd
RS
27332013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2734
2735 * c-decl.c, c-typeck.c: Replace tree_low_cst (..., 1) with
2736 tree_to_uhwi throughout.
2737
9439e9a1
RS
27382013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2739
2740 * c-parser.c: Replace tree_low_cst (..., 0) with tree_to_shwi
2741 throughout.
2742
9541ffee
RS
27432013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
2744
2745 * c-parser.c: Replace host_integerp (..., 0) with tree_fits_shwi_p
2746 throughout.
2747
c02065fc
AH
27482013-11-15 Aldy Hernandez <aldyh@redhat.com>
2749
2750 * c-parser.c (c_parser_cilk_simd): New.
2751 (c_parser_cilk_verify_simd): New.
2752 (c_parser_pragma): Add case for PRAGMA_CILK_SIMD.
2753 (c_parser_omp_for_loop): Add case for NE_EXPR.
2754 Set c_break_label for CILK_SIMD.
2755 (c_parser_cilk_clause_vectorlength): New.
2756 (c_parser_cilk_clause_linear): New.
2757 (c_parser_cilk_clause_name): New.
2758 (c_parser_cilk_all_clauses): New.
2759 * c-typeck.c (build_unary_op): Pass location argument to
2760 readonly_error.
2761 (build_modify_expr): Same.
2762 (build_asm_expr): Same.
2763 (c_finish_bc_stmt): Error on break/continue in loops.
2764
18f429e2
AM
27652013-11-14 Andrew MacLeod <amacleod@redhat.com>
2766
2767 * c-typeck.c: Include only gimplify.h and gimple.h as needed.
2768
d8a2d370
DN
27692013-11-14 Diego Novillo <dnovillo@google.com>
2770
2771 * c-decl.c: Include print-tree.h.
2772 Include stor-layout.h.
2773 Include varasm.h.
2774 Include attribs.h.
2775 Include stringpool.h.
2776 * c-lang.c: Include fold-const.h.
2777 * c-parser.c: Include stringpool.h.
2778 Include attribs.h.
2779 Include stor-layout.h.
2780 Include varasm.h.
2781 Include trans-mem.h.
2782 * c-typeck.c: Include stor-layout.h.
2783 Include trans-mem.h.
2784 Include varasm.h.
2785 Include stmt.h.
2786
38b7bc7f
JM
27872013-11-13 Joseph Myers <joseph@codesourcery.com>
2788
2789 * c-tree.h (c_typespec_keyword): Add cts_auto_type.
2790 * c-decl.c (declspecs_add_type, finish_declspecs): Handle
2791 __auto_type.
2792 * c-parser.c (c_token_starts_typename, c_token_starts_declspecs)
2793 (c_parser_attribute_any_word, c_parser_objc_selector): Handle
2794 RID_AUTO_TYPE.
2795 (c_parser_declspecs): Take argument AUTO_TYPE_OK.
2796 (c_parser_declaration_or_fndef, c_parser_struct_declaration)
2797 (c_parser_declarator, c_parser_direct_declarator_inner)
2798 (c_parser_parameter_declaration, c_parser_type_name): All callers
2799 changed.
2800 (c_parser_declaration_or_fndef): Handle declarations with type
2801 determined from the initializer.
2802
45b0be94
AM
28032013-11-12 Andrew MacLeod <amacleod@redhat.com>
2804
18f429e2 2805 * c-typeck.c: Include gimplify.h.
45b0be94 2806
582d9b50
JM
28072013-11-12 Joseph Myers <joseph@codesourcery.com>
2808
2809 * c-tree.h (struct c_declspecs): Add thread_gnu_p field.
2810 * c-parser.c (c_parser_declspecs): Mention _Thread_local in
2811 comment.
2812 * c-decl.c (shadow_tag_warned, grokdeclarator): Mention __thread
2813 or _Thread_local as appropriate in diagnostics.
2814 (build_null_declspecs): Initialize ret->thread_gnu_p.
2815 (declspecs_add_scspec): Handle either __thread or _Thread_local
2816 for RID_THREAD. Diagnose _Thread_local for pre-C11 standards if
2817 pedantic. Do not disallow _Thread_local extern and _Thread_local
2818 static.
2819
267bac10
JM
28202013-11-07 Joseph Myers <joseph@codesourcery.com>
2821 Andrew MacLeod <amacleod@redhat.com>
2822
2823 * c-aux-info.c (gen_type): Handle atomic qualifier.
2824 * c-decl.c (validate_proto_after_old_defn): Do not remove atomic
2825 qualifiers when compating types.
2826 (shadow_tag_warned): Handle atomic_p in declspecs.
2827 (quals_from_declspecs): Likewise.
2828 (start_decl): Use c_type_promotes_to when promoting argument
2829 types.
2830 (grokdeclarator): Handle _Atomic.
2831 (get_parm_info): Diagnose any qualifier on "void" as only
2832 parameter.
2833 (store_parm_decls_oldstyle): Do not remove atomic qualifiers when
2834 comparing types. Use c_type_promotes_to when promoting argument
2835 types.
2836 (finish_function): Use c_type_promotes_to when promoting argument
2837 types.
2838 (build_null_declspecs): Handle atomic_p in declspecs.
2839 (declspecs_add_qual): Handle RID_ATOMIC.
2840 * c-parser.c (c_token_starts_typename, c_token_is_qualifier)
2841 (c_token_starts_declspecs): Handle RID_ATOMIC.
2842 (c_parser_declspecs): Handle atomic type specifiers and
2843 qualifiers.
2844 (c_parser_typeof_specifier): Remove const and _Atomic qualifiers
2845 from types of expressions with atomic type.
2846 (c_parser_direct_declarator_inner): Use convert_lvalue_to_rvalue.
2847 (c_parser_attribute_any_word): Handle RID_ATOMIC.
2848 (c_parser_initializer, c_parser_initelt, c_parser_initval)
2849 (c_parser_statement_after_labels, c_parser_switch_statement)
2850 (c_parser_for_statement, c_parser_expr_no_commas)
2851 (c_parser_conditional_expression, c_parser_binary_expression)
2852 (c_parser_cast_expression, c_parser_unary_expression)
2853 (c_parser_postfix_expression)
2854 (c_parser_postfix_expression_after_primary, c_parser_expression):
2855 Use convert_lvalue_to_rvalue.
2856 (c_parser_expression_conv, c_parser_expr_list): Document
2857 conversion of lvalues to rvalues. Use convert_lvalue_to_rvalue.
2858 (c_parser_objc_synchronized_statement): Use
2859 convert_lvalue_to_rvalue.
2860 (c_parser_objc_selector): Handle RID_ATOMIC.
2861 (c_parser_objc_receiver, c_parser_array_notation): Use
2862 convert_lvalue_to_rvalue.
2863 * c-tree.h (ctsk_typeof): Adjust comment to mention use for
2864 _Atomic (type-name).
2865 (struct c_declspecs): Add atomic_p field.
2866 (convert_lvalue_to_rvalue): Declare.
2867 * c-typeck.c (c_type_promotes_to): Promote atomic types to
2868 corresponding atomic types.
2869 (qualify_type): Don't add _Atomic qualifiers from second argument.
2870 (comp_target_types): Do not allow _Atomic mismatches.
2871 (type_lists_compatible_p): Do not remove atomic qualifiers when
2872 comparing types.
2873 (really_atomic_lvalue, convert_lvalue_to_rvalue)
2874 (build_atomic_assign): New functions.
2875 (build_unary_op): Use build_atomic_assign for atomic increment and
2876 decrement.
2877 (build_conditional_expr): Do not treat _Atomic void as a qualified
2878 version of void.
2879 (build_modify_expr): Use build_atomic_assign for atomic LHS.
2880 (find_anonymous_field_with_type, convert_to_anonymous_field)
2881 (convert_for_assignment): Do not remove atomic qualifiers when
2882 comparing types.
2883 (digest_init): Do not accept initialization of arrays of atomic
2884 elements by string constants.
2885 (build_asm_expr): Use convert_lvalue_to_rvalue.
2886 (build_binary_op): Do not treat _Atomic void as a qualified
2887 version of void.
2888
0c249d4b
DD
28892013-11-06 DJ Delorie <dj@redhat.com>
2890
2891 * c-decl.c (locate_old_decl): If a previous conflicting decl is
2892 both explicit and builtin, print the location of the explicit one.
2893
6d7f7e0a
TB
28942013-11-05 Tobias Burnus <burnus@net-b.de>
2895
2896 * c-parser.c (c_parser_omp_for, c_parser_omp_parallel,
2897 c_parser_omp_distribute, c_parser_omp_teams,
2898 c_parser_omp_target, c_parser_omp_declare): Handle
2899 -fopenmp-simd.
2900
b906f4ca
MP
29012013-11-03 Marek Polacek <polacek@redhat.com>
2902
2903 * c-decl.c (grokdeclarator): Add VLA instrumentation.
2904
ee1d5a02
JJ
29052013-11-01 Jakub Jelinek <jakub@redhat.com>
2906
2907 * c-typeck.c (c_finish_omp_clauses) <case OMP_CLAUSE_UNIFORM>: Go to
2908 check_dup_generic at the end, unless remove is true.
2909 (c_finish_omp_clauses) <case OMP_CLAUSE_REDUCTION>: Add break; after
2910 remove = true;.
2911 (c_finish_omp_clauses) <case OMP_CLAUSE_COPYIN>: Likewise.
2912
5a9785fb
JJ
29132013-10-31 Jakub Jelinek <jakub@redhat.com>
2914
2915 * c-typeck.c (c_finish_omp_clauses): Diagnose aligned clause
2916 with decl that is not pointer nor array.
2917
939b37da
BI
29182013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
2919
2920 * c-decl.c (finish_function): Added a call for insert_cilk_frame when
2921 a spawning function is found.
2922 * c-objc-common.h (LANG_HOOKS_CILKPLUS_GIMPLIFY_SPAWN): New #define.
2923 (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Likewise.
2924 (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise.
2925 * c-parser.c (c_parser_statement_after_labels): Added RID_CILK_SYNC
2926 case.
2927 (c_parser_postfix_expression): Added RID_CILK_SPAWN case.
2928 * c-typeck.c (build_compound_expr): Reject _Cilk_spawn in a comma
2929 expr.
2930 (c_finish_return): Added a check to reject _Cilk_spawn in return
2931 expression.
2932 (build_cilk_spawn): New function.
2933 (build_cilk_sync): Likewise.
2934 * Makefile.in (c-decl.o): Added cilk.h in dependency list.
2935
d4af74d4
TB
29362013-10-27 Tobias Burnus <burnus@net-b.de>
2937
2938 PR other/33426
2939 * c-parser.c (c_parser_while_statement, c_parser_while_statement,
2940 c_parser_pragma): Add GCC ivdep support to 'do' and 'while'.
2941 (c_parser_statement_after_labels): Update calls.
2942
d73749df 29432013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
2944
2945 PR other/33426
2946 * c-parser.c (c_parser_pragma, c_parser_for_statement):
2947 Handle PRAGMA_IVDEP.
2948 (c_parser_statement_after_labels): Update call.
2949
f28aa681
MP
29502013-10-24 Marek Polacek <polacek@redhat.com>
2951
2952 * c-parser.c (c_parser_struct_declaration): Add a comment.
2953 (c_parser_declarator): Don't allow _Alignas here.
2954
0645c1a2
AM
29552013-10-17 Andrew MacLeod <amacleod@redhat.com>
2956
2957 * c-parser.c: Include omp-low.h.
2958 * c-typeck.c: Likewise.
2959
568a31f2
MP
29602013-10-17 Marek Polacek <polacek@redhat.com>
2961
2962 PR c/58267
2963 * c-parser.c (c_parser_declspecs): Add alignspec_ok parameter.
2964 Document syntax of the array-declarator.
2965 (c_parser_declspecs) <RID_ALIGNAS>: Bail out if alignment specs
2966 are not permitted.
2967 (c_parser_declaration_or_fndef): Adjust c_parser_declspecs call.
2968 (c_parser_struct_declaration): Likewise.
2969 (c_parser_declarator): Likewise.
2970 (c_parser_direct_declarator_inner): Likewise.
2971 (c_parser_parameter_declaration): Likewise.
2972 (c_parser_type_name): Likewise.
2973
acf0174b
JJ
29742013-10-11 Jakub Jelinek <jakub@redhat.com>
2975
2976 * c-lang.h (current_omp_declare_target_attribute): New extern
2977 decl.
2978 * c-parser.c: Include c-lang.h.
2979 (struct c_parser): Change tokens to c_token *.
2980 Add tokens_buf field. Change tokens_avail type to unsigned int.
2981 (c_parser_consume_token): If parser->tokens isn't
2982 &parser->tokens_buf[0], increment parser->tokens.
2983 (c_parser_consume_pragma): Likewise.
2984 (enum pragma_context): Add pragma_struct and pragma_param.
2985 (c_parser_external_declaration): Adjust
2986 c_parser_declaration_or_fndef caller.
2987 (c_parser_declaration_or_fndef): Add omp_declare_simd_clauses
2988 argument, if it is non-vNULL vector, call c_finish_omp_declare_simd.
2989 Adjust recursive call.
2990 (c_parser_struct_or_union_specifier): Use pragma_struct instead
2991 of pragma_external.
2992 (c_parser_parameter_declaration): Use pragma_param instead of
2993 pragma_external.
2994 (c_parser_compound_statement_nostart, c_parser_label,
2995 c_parser_for_statement): Adjust
2996 c_parser_declaration_or_fndef callers.
2997 (c_parser_expr_no_commas): Add omp_atomic_lhs argument, pass
2998 it through to c_parser_conditional_expression.
2999 (c_parser_conditional_expression): Add omp_atomic_lhs argument,
3000 pass it through to c_parser_binary_expression. Adjust recursive
3001 call.
3002 (c_parser_binary_expression): Remove prec argument, add
3003 omp_atomic_lhs argument instead. Always start from PREC_NONE, if
3004 omp_atomic_lhs is non-NULL and one of the arguments of toplevel
3005 binop matches it, use build2 instead of parser_build_binary_op.
3006 (c_parser_pragma): Handle PRAGMA_OMP_CANCEL,
3007 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_TARGET,
3008 PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_DECLARE_REDUCTION.
3009 Handle pragma_struct and pragma_param the same as pragma_external.
3010 (c_parser_omp_clause_name): Parse new OpenMP 4.0 clause names.
3011 (c_parser_omp_variable_list): Parse array sections for
3012 OMP_CLAUSE_{DEPEND,MAP,TO,FROM} clauses.
3013 (c_parser_omp_clause_collapse): Fully fold collapse expression.
3014 (c_parser_omp_clause_reduction): Handle user defined reductions.
3015 (c_parser_omp_clause_branch, c_parser_omp_clause_cancelkind,
3016 c_parser_omp_clause_num_teams, c_parser_omp_clause_thread_limit,
3017 c_parser_omp_clause_aligned, c_parser_omp_clause_linear,
3018 c_parser_omp_clause_safelen, c_parser_omp_clause_simdlen,
3019 c_parser_omp_clause_depend, c_parser_omp_clause_map,
3020 c_parser_omp_clause_device, c_parser_omp_clause_dist_schedule,
3021 c_parser_omp_clause_proc_bind, c_parser_omp_clause_to,
3022 c_parser_omp_clause_from, c_parser_omp_clause_uniform): New functions.
3023 (c_parser_omp_all_clauses): Add finish_p argument. Don't call
3024 c_finish_omp_clauses if it is false. Handle new OpenMP 4.0 clauses.
3025 (c_parser_omp_atomic): Parse seq_cst clause, pass true if it is
3026 present to c_finish_omp_atomic. Handle OpenMP 4.0 atomic forms.
3027 (c_parser_omp_for_loop): Add CODE argument, pass it through
3028 to c_finish_omp_for. Change last argument to cclauses,
3029 and adjust uses to grab parallel clauses from the array of all
3030 the split clauses. Adjust c_parser_binary_expression,
3031 c_parser_declaration_or_fndef and c_finish_omp_for callers.
3032 (omp_split_clauses): New function.
3033 (c_parser_omp_simd): New function.
3034 (c_parser_omp_for): Add p_name, mask and cclauses arguments.
3035 Allow the function to be called also when parsing combined constructs,
3036 and call c_parser_omp_simd when parsing for simd.
3037 (c_parser_omp_sections_scope): If section-sequence doesn't start with
3038 #pragma omp section, require exactly one structured-block instead of
3039 sequence of statements.
3040 (c_parser_omp_sections): Add p_name, mask and cclauses arguments.
3041 Allow the function to be called also when parsing combined constructs.
3042 (c_parser_omp_parallel): Add p_name, mask and cclauses arguments.
3043 Allow the function to be called also when parsing combined
3044 constructs.
3045 (c_parser_omp_taskgroup, c_parser_omp_cancel,
3046 c_parser_omp_cancellation_point, c_parser_omp_distribute,
3047 c_parser_omp_teams, c_parser_omp_target_data,
3048 c_parser_omp_target_update, c_parser_omp_target,
3049 c_parser_omp_declare_simd, c_finish_omp_declare_simd,
3050 c_parser_omp_declare_target, c_parser_omp_end_declare_target,
3051 c_parser_omp_declare_reduction, c_parser_omp_declare): New functions.
3052 (c_parser_omp_construct): Add p_name and mask vars. Handle
3053 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_SIMD, PRAGMA_OMP_TASKGROUP,
3054 PRAGMA_OMP_TEAMS. Adjust c_parser_omp_for, c_parser_omp_parallel
3055 and c_parser_omp_sections callers.
3056 (c_parse_file): Initialize tparser.tokens and the_parser->tokens here.
3057 (OMP_FOR_CLAUSE_MASK, OMP_SECTIONS_CLAUSE_MASK,
3058 OMP_SINGLE_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1.
3059 (OMP_PARALLEL_CLAUSE_MASK): Likewise. Add OMP_CLAUSE_PROC_BIND.
3060 (OMP_TASK_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1. Add
3061 OMP_CLAUSE_DEPEND.
3062 (OMP_SIMD_CLAUSE_MASK, OMP_CANCEL_CLAUSE_MASK,
3063 OMP_CANCELLATION_POINT_CLAUSE_MASK, OMP_DISTRIBUTE_CLAUSE_MASK,
3064 OMP_TEAMS_CLAUSE_MASK, OMP_TARGET_DATA_CLAUSE_MASK,
3065 OMP_TARGET_UPDATE_CLAUSE_MASK, OMP_TARGET_CLAUSE_MASK,
3066 OMP_DECLARE_SIMD_CLAUSE_MASK): Define.
3067 * c-typeck.c: Include tree-inline.h.
3068 (c_finish_omp_cancel, c_finish_omp_cancellation_point,
3069 handle_omp_array_sections_1, handle_omp_array_sections,
3070 c_clone_omp_udr, c_find_omp_placeholder_r): New functions.
3071 (c_finish_omp_clauses): Handle new OpenMP 4.0 clauses and
3072 user defined reductions.
3073 (c_tree_equal): New function.
3074 * c-tree.h (temp_store_parm_decls, temp_pop_parm_decls,
3075 c_finish_omp_cancel, c_finish_omp_cancellation_point, c_tree_equal,
3076 c_omp_reduction_id, c_omp_reduction_decl, c_omp_reduction_lookup,
3077 c_check_omp_declare_reduction_r): New prototypes.
3078 * c-decl.c (current_omp_declare_target_attribute): New variable.
3079 (c_decl_attributes): New function.
3080 (start_decl, start_function): Use it instead of decl_attributes.
3081 (temp_store_parm_decls, temp_pop_parm_decls, c_omp_reduction_id,
3082 c_omp_reduction_decl, c_omp_reduction_lookup,
3083 c_check_omp_declare_reduction_r): New functions.
3084
0a6c2227
TT
30852013-09-25 Tom Tromey <tromey@redhat.com>
3086
3087 * Make-lang.in (c/gccspec.o): Remove.
3088 (CFLAGS-c/gccspec.o): New variable.
3089 (cc1-checksum.o, C_TREE_H, c/c-aux-info.o, c/c-convert.o)
3090 (c/c-decl.o, c/c-errors.o, c/c-lang.o, c/c-objc-common.o)
3091 (c/c-parser.o, c/c-typeck.o, c/c-array-notation.o): Remove.
3092
f3bc55f0
TT
30932013-09-25 Tom Tromey <tromey@redhat.com>
3094
3095 * Make-lang.in (c/gccspec.o): Don't use subshell.
3096
a24d975c
MP
30972013-09-18 Marek Polacek <polacek@redhat.com>
3098
3099 PR sanitize/58443
3100 * c-typeck.c (build_binary_op): Properly honor -fsanitize options.
3101 Remove unnecessary check.
3102
ce6923c5
MP
31032013-09-18 Marek Polacek <polacek@redhat.com>
3104
3105 PR sanitizer/58411
3106 * c-typeck.c (build_binary_op): Don't sanitize function if it has the
3107 no_sanitize_undefined attribute.
3108
a1e51df9
KT
31092013-09-13 Kai Tietz <ktietz@redhat.com>
3110
3111 PR target/57848
3112 * c-decl.c (c_builtin_function_ext_scope): Remove
3113 wrong assumption that it is never called on prexisting
3114 symbol.
3115
0af94e6f
JR
31162013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
3117
3118 * c-typeck.c (build_binary_op): Use vector_types_compatible_elements_p.
3119
20059c8b
GDR
31202013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
3121
3122 * c-objc-common.c (c_tree_printer): Tidy.
3123
de5a5fa1
MP
31242013-08-30 Marek Polacek <polacek@redhat.com>
3125
3126 * c-typeck.c (build_binary_op): Add division by zero and shift
3127 instrumentation.
3128
2531a1d9 31292013-08-26 Joern Rennecke <joern.rennecke@embecosm.com>
0fdd4508 3130 Joseph Myers <joseph@codesourcery.com>
2531a1d9 3131
6e2bcc98 3132 PR c/35649
2531a1d9
JR
3133 * c-typeck.c (c_common_type): Prefer double_type_node over
3134 other REAL_TYPE types with the same precision.
3135 (convert_arguments): Likewise.
3136
025311c4
GDR
31372013-08-23 Gabriel Dos Reis <gdr@integrable-solutions.net>
3138
3139 * c-objc-common.c (c_tree_printer): Document the nature of the cast.
3140 (c_initialize_diagnostics): Call a destructor for the early printer.
3141
da6ca2b5
GDR
31422013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
3143
3144 * c-objc-common.c (c_initialize_diagnostics): Simplify C pretty
3145 printer initialization.
3146
318cda85 31472013-08-19 Balaji V. Iyer <balaji.v.iyer@intel.com>
da6ca2b5 3148
318cda85
BI
3149 PR c/57490
3150 * c-array-notation.c (fix_conditional_array_notations_1): Added a
3151 check for truth values.
3152 (expand_array_notation_exprs): Added truth values case. Removed an
3153 unwanted else. Added for-loop to walk through subtrees in default
3154 case.
3155
b066401f
GDR
31562013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
3157
3158 * c-objc-common.c (c_initialize_diagnostics): Don't call pp_base.
3159
fb48aadc
JM
31602013-07-23 Joseph Myers <joseph@codesourcery.com>
3161
3162 * c-parser.c (struct c_generic_association): Fix typo.
3163
433cc7b0
TT
31642013-07-23 Tom Tromey <tromey@redhat.com>
3165 Joseph Myers <joseph@codesourcery.com>
3166
3167 * c-parser.c (struct c_generic_association): New.
3168 (c_generic_association_d): New typedef.
3169 (c_parser_generic_selection): New function.
3170 (c_parser_postfix_expression): Handle RID_GENERIC.
3171
26d40c3d
JM
31722013-07-13 Jason Merrill <jason@redhat.com>
3173
3174 PR c++/57793
3175 * c-decl.c (finish_struct): Check for too-large class.
3176
ecdbd01a 31772013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
3178
3179 PR c/57821
3180 * c-typeck.c (set_init_index): When folding, check for index overflow.
3181
1141ed3f
BI
31822013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
3183
3184 * c-parser.c (c_parser_array_notation): Removed rejection of array
3185 notations in an array of function pointers.
3186
713b46fa
BI
31872013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
3188
3189 * c-array-notation.c (make_triplet_val_inv): New function.
3190 (create_cmp_incr): Likewise.
3191 (create_array_refs): Likewise.
3192 (fix_builtin_array_notation_fn): Replaced all mallocs with tree vec.
3193 Also modularized common parts between functions and called the function.
3194 (build_array_notation_expr): Likewise.
3195 (fix_conditional_array_notations_1): Likewise.
3196 (fix_array_notation_expr): Likewise.
3197 (fix_array_notation_call_expr): Likewise.
3198
92f20202
MP
31992013-06-18 Marek Polacek <polacek@redhat.com>
3200
3201 PR c/57630
3202 * c-decl.c (check_for_loop_decls): Improve diagnostics messages.
3203
73a23b06
BI
32042013-06-12 Balaji V. Iyer <balaji.v.iyer@intel.com>
3205
3206 * c-array-notation.c (build_array_notation_expr): Reject array notation
3207 mismatch between LHS and RHS even inside a call_expr. Also, removed
3208 a couple while statements that were dead code.
3209
00b8517d
BI
32102013-06-10 Balaji V. Iyer <balaji.v.iyer@intel.com>
3211
3212 * c-array-notation.c (fix_builtin_array_notation_fn): Fully folded
3213 excessive precision expressions in function parameters. Also removed
3214 couple unwanted while statements.
3215
1509bdda
BI
32162013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
3217
3218 * c-array-notation.c (expand_array_notation_exprs): Added
3219 ARRAY_NOTATION_REF case.
3220
d60f1706
BI
32212013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
3222
3223 * c-array-notation.c (length_mismatch_in_expr_p): Moved this
3224 function to c-family/array-notation-common.c.
3225 (is_cilkplus_reduce_builtin): Likewise.
3226 (find_rank): Likewise.
3227 (extract_array_notation_exprs): Likewise.
3228 (replace_array_notations): Likewise.
3229 (find_inv_trees): Likewise.
3230 (replace_inv_trees): Likewise.
3231 (contains_array_notation_expr): Likewise.
3232 (find_correct_array_notation_type): Likewise.
3233 (replace_invariant_exprs): Initialized additional_tcodes to NULL.
3234 (struct inv_list): Moved this to c-family/array-notation-common.c.
3235 * c-tree.h (is_cilkplus_builtin_reduce): Remove prototype.
3236
6d6efbb3
BI
32372013-06-05 Balaji V. Iyer <balaji.v.iyer@intel.com>
3238
3239 * c-typeck.c (convert_arguments): Moved checking of builtin cilkplus
3240 reduction functions outside the for-loop. Added a check if the fundecl
3241 is non-NULL. Finally, removed an unwanted if-statement, and made the
3242 body unconditional.
3243
25c22937
BI
32442013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com>
3245
3246 * c-typeck.c (c_finish_if_stmt): Added a check to see if the rank of the
3247 condition of the if-statement matches the rank of else-block and then-
3248 block when array notations are used.
3249 * c-parser.c (c_parser_declaration_or_fndef): Expanded array notation
3250 expression after the entire function body is parsed.
3251 (c_parser_expr_no_commas): Delayed creating array notation expressions
3252 to the end of function parsing.
3253 * c-array-notation.c (fix_conditional_array_notations_1): Expanded the
3254 whole if-statement instead of just the condition.
3255 (expand_array_notation_exprs): Added MODIFY_EXPR case.
3256
edd25645
BI
32572013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com>
3258
3259 PR c/57474
3260 * c-array-notation.c (build_array_notation_expr): Initialized rhs_length
3261 array to NULL_TREE if they are unused. Also added a check for the
3262 field to be NULL before its fields are used in future.
3263
065ce7f1
RO
32642013-05-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3265
3266 PR bootstrap/57450
3267 * c-array-notation.c (length_mismatch_in_expr_p): Use absu_hwi.
3268 (build_array_notation_expr): Likewise.
3269
36536d79
BI
32702013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
3271
3272 * c-typeck.c (build_array_ref): Added a check to see if array's
3273 index is greater than one. If true, then emit an error.
3274 (build_function_call_vec): Exclude error reporting and checking
3275 for builtin array-notation functions.
3276 (convert_arguments): Likewise.
3277 (c_finish_return): Added a check for array notations as a return
3278 expression. If true, then emit an error.
3279 (c_finish_loop): Added a check for array notations in a loop
3280 condition. If true then emit an error.
3281 (lvalue_p): Added a ARRAY_NOTATION_REF case.
3282 (build_binary_op): Added a check for array notation expr inside
3283 op1 and op0. If present, we call another function to find correct
3284 type.
3285 * Make-lang.in (C_AND_OBJC_OBJS): Added c-array-notation.o.
3286 * c-parser.c (c_parser_compound_statement): Check if array
3287 notation code is used in tree, if so, then transform them into
3288 appropriate C code.
3289 (c_parser_expr_no_commas): Check if array notation is used in LHS
3290 or RHS, if so, then build array notation expression instead of
3291 regular modify.
3292 (c_parser_postfix_expression_after_primary): Added a check for
3293 colon(s) after square braces, if so then handle it like an array
3294 notation. Also, break up array notations in unary op if found.
3295 (c_parser_direct_declarator_inner): Added a check for array
3296 notation.
3297 (c_parser_compound_statement): Added a check for array notation in
3298 a stmt. If one is present, then expand array notation expr.
3299 (c_parser_if_statement): Likewise.
3300 (c_parser_switch_statement): Added a check for array notations in
3301 a switch statement's condition. If true, then output an error.
3302 (c_parser_while_statement): Similarly, but for a while.
3303 (c_parser_do_statement): Similarly, but for a do-while.
3304 (c_parser_for_statement): Similarly, but for a for-loop.
3305 (c_parser_unary_expression): Check if array notation is used in a
3306 pre-increment or pre-decrement expression. If true, then expand
3307 them.
3308 (c_parser_array_notation): New function.
3309 * c-array-notation.c: New file.
3310 * c-tree.h (is_cilkplus_reduce_builtin): Protoize.
3311
cd192ccc
MS
33122013-05-23 Mike Stump <mikestump@comcast.net>
3313
3314 * c-typeck.c (convert_for_assignment): Handle references to memory
3315 spaces better.
3316
427b248d
JM
33172013-05-16 Jason Merrill <jason@redhat.com>
3318
3319 * Make-lang.in (cc1$(exeext)): Use link mutex.
3320
44d90fe1
PC
33212013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
3322
3323 * c-typeck.c (pointer_diff): Change -Wpointer-arith pedwarns
3324 to simply use OPT_Wpointer_arith.
3325 (build_unary_op): Likewise.
3326
4e7d7b3d
JJ
33272013-04-03 Jakub Jelinek <jakub@redhat.com>
3328
3329 PR c/19449
3330 * c-parser.c (c_parser_get_builtin_args): Add choose_expr_p
3331 argument. If set, or it temporarily for parsing of the first
3332 argument into force_folding_builtin_constant_p.
3333 (c_parser_postfix_expression): Adjust callers.
3334
839b422f
RB
33352013-03-21 Richard Biener <rguenther@suse.de>
3336
3337 * c-objc-common.c (c_tree_printer): Use DECL_HAS_DEBUG_EXPR_P
3338 instead of DECL_DEBUG_EXPR_IS_FROM. Guard properly.
3339
2ee028f1
MP
33402013-02-12 Marek Polacek <polacek@redhat.com>
3341
3342 PR c/44938
3343 * c-parser.c (c_parser_postfix_expression_after_primary): Initialize
3344 origtypes to NULL.
3345
8824edff
JJ
33462013-01-24 Jakub Jelinek <jakub@redhat.com>
3347
3348 PR c/56078
3349 * c-typeck.c (set_nonincremental_init_from_string): If
3350 constructor_max_index is NULL, treat it as if tree_int_cst_lt
3351 returned false.
3352 (process_init_element): Likewise.
3353
eadd3d0d
JJ
33542012-12-20 Jakub Jelinek <jakub@redhat.com>
3355
3356 PR c++/55619
3357 * c-parser.c (c_parser_asm_operands): Remove CONVERT_P
3358 argument, don't call default_function_array_conversion
3359 nor c_fully_fold here.
3360 (c_parser_asm_statement): Adjust callers.
3361 * c-typeck.c (build_asm_expr): Call c_fully_fold on inputs
3362 and outputs here, and call default_function_array_conversion
3363 on inputs that don't need to be addressable.
3364
f8a93a2e
JJ
33652012-12-18 Jakub Jelinek <jakub@redhat.com>
3366
3367 PR c/39464
3368 * c-typeck.c (convert_for_assignment): For -Wpointer-sign
3369 warning require that both c_common_unsigned_type as well as
3370 c_common_signed_type is the same for both mvl and mvr types.
3371
9771b263
DN
33722012-11-16 Diego Novillo <dnovillo@google.com>
3373
3374 Adjust for new vec API (http://gcc.gnu.org/wiki/cxx-conversion/cxx-vec)
3375
3376 * c-common.c: Use new vec API in vec.h.
3377 * c-common.h: Likewise.
3378 * c-gimplify.c: Likewise.
3379 * c-pragma.c: Likewise.
3380 * c-pretty-print.c: Likewise.
3381 * c-pretty-print.h: Likewise.
3382 * c-semantics.c: Likewise.
3383 * c-decl.c: Likewise.
3384 * c-parser.c: Likewise.
3385 * c-tree.h: Likewise.
3386 * c-typeck.c: Likewise.
3387
880661a4
JW
33882012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
3389
3390 PR c++/54930
3391 * c-typeck.c (c_finish_return): Use OPT_Wreturn_local_addr.
3392
077d1abe
MLI
33932012-10-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
3394
3395 PR c/53066
3396 * c-decl.c (warn_if_shadowing): Do not warn if a variable
3397 shadows a function, unless the variable is a function or a
3398 pointer-to-function.
3399
3a785c97
JJ
34002012-10-12 Jakub Jelinek <jakub@redhat.com>
3401
3402 PR c/54381
3403 * c-parser.c (struct c_tree_loc_pair): Removed.
3404 (c_parser_expr_list): Remove struct c_tree_loc_pair * argument,
3405 add location_t * and tree * arguments, fill in array of 3
3406 sizeof_arg trees and corresponding locs.
3407 (c_parser_attributes, c_parser_objc_keywordexpr): Adjust
3408 c_parser_expr_list callers.
3409 (c_parser_postfix_expression_after_primary): Likewise. Pass
3410 array of 3 sizeof_arg trees and locs (corresponding to first
3411 3 arguments) to sizeof_pointer_memaccess_warning.
3412
703c8606
LC
34132012-10-09 Lawrence Crowl <crowl@google.com>
3414
3415 * Make-lang.in (c-decl.o): Add dependence on hash-table.h.
3416 * c-decl.c (detect_field_duplicates_hash): Change to new type-safe
3417 hash table.
3418
5d9de0d0
PC
34192012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
3420
3421 PR c++/54194
3422 * c-typeck.c (parser_build_binary_op): Update warn_about_parentheses
3423 call.
3424
a212e43f
MG
34252012-10-09 Marc Glisse <marc.glisse@inria.fr>
3426
3427 PR c++/54427
3428 * c-typeck.c: Include c-common.h.
3429 (enum stv_conv): Moved to c-common.h.
3430 (scalar_to_vector): Moved to c-common.c.
3431 (build_binary_op): Adapt to scalar_to_vector's new prototype.
3432 * Make-lang.in: c-typeck.c depends on c-common.h.
3433
3b78de56
AC
34342012-10-04 Arnaud Charlet <charlet@adacore.com>
3435
3436 * c-decl.c (c_write_global_declarations): Fix handling of
3437 -fdump-ada-spec*.
3438
78c60e3d
SS
34392012-09-30 Sharad Singhai <singhai@google.com>
3440
3441 * c-decl.c (c_write_global_declarations): Use a different method
3442 to determine if the dump has ben initialized.
3443
9f33203d
JM
34442012-09-14 Joseph Myers <joseph@codesourcery.com>
3445
3446 PR c/54552
3447 * c-typeck.c (c_cast_expr): When casting to a type requiring
3448 C_MAYBE_CONST_EXPR to be created, pass the inner expression to
3449 c_fully_fold first.
3450
a27d595d
JM
34512012-09-14 Joseph Myers <joseph@codesourcery.com>
3452
3453 PR c/54103
3454 * c-typeck.c (build_unary_op): Pass original argument of
3455 TRUTH_NOT_EXPR to c_objc_common_truthvalue_conversion, then remove
3456 any C_MAYBE_CONST_EXPR, if it has integer operands.
3457 (build_binary_op): Pass original arguments of TRUTH_ANDIF_EXPR,
3458 TRUTH_ORIF_EXPR, TRUTH_AND_EXPR, TRUTH_OR_EXPR and TRUTH_XOR_EXPR
3459 to c_objc_common_truthvalue_conversion, then remove any
3460 C_MAYBE_CONST_EXPR, if they have integer operands. Use
3461 c_objc_common_truthvalue_conversion not
3462 c_common_truthvalue_conversion.
3463 (c_objc_common_truthvalue_conversion): Build NE_EXPR directly and
3464 call note_integer_operands for arguments with integer operands
3465 that are not integer constants.
3466
9feb29df
JJ
34672012-09-13 Jakub Jelinek <jakub@redhat.com>
3468
3469 PR c/54559
3470 * c-typeck.c (c_finish_return): Do convert to BOOLEAN_TYPE or
3471 COMPLEX_TYPE with in_late_binary_op set temporarily to true.
3472
d409320c
JJ
34732012-08-31 Jakub Jelinek <jakub@redhat.com>
3474
3475 PR c/54428
3476 * c-convert.c (convert): Don't call fold_convert_loc if
3477 TYPE_MAIN_VARIANT of a COMPLEX_TYPE is the same, unless e
3478 is a COMPLEX_EXPR. Remove TYPE_MAIN_VARIANT check from
3479 COMPLEX_TYPE -> COMPLEX_TYPE conversion.
3480
6265d07c
JJ
34812012-08-24 Jakub Jelinek <jakub@redhat.com>
3482
3483 PR c/54355
3484 * c-decl.c (c_parser_label): Pass true as nested and fix up comments
3485 for nested and empty_ok arguments in the call to
3486 c_parser_declaration_or_fndef.
3487
1a4049e7
JJ
34882012-08-17 Jakub Jelinek <jakub@redhat.com>
3489
3490 * c-tree.h (c_last_sizeof_arg): Declare.
3491 * c-parser.c (struct c_tree_loc_pair): New type.
3492 (c_parser_expr_list): Add sizeof_arg argument. Fill it in if
3493 non-NULL.
3494 (c_parser_attributes, c_parser_objc_keywordexpr): Adjust callers.
3495 (c_parser_postfix_expression_after_primary): Likewise. Call
3496 sizeof_pointer_memaccess_warning if needed.
3497 (sizeof_ptr_memacc_comptypes): New function.
3498 * c-typeck.c (c_last_sizeof_arg): New global variable.
3499 (c_expr_sizeof_expr, c_expr_sizeof_type): Initialize it.
3500
0229aee9
UB
35012012-07-24 Uros Bizjak <ubizjak@gmail.com>
3502
3503 * c-lang.h (lang_decl): Add variable_size GTY option.
3504
7ee2468b
SB
35052012-07-16 Steven Bosscher <steven@gcc.gnu.org>
3506
3507 * c-decl.c: Include dumpfile.h instead of tree-dump.h.
3508 * Make-lang.in: Fix dependencies.
3509
d4a10d0a
SB
35102012-06-29 Steven Bosscher <steven@gcc.gnu.org>
3511
3512 * Make-lang.in: New file, rules migrated from gcc/Makefile.in
3513 and add language Makefile hooks.
3514 * config-lang.in: New file.
3515 * c-config-lang.in: Moved from gcc/config-lang.in to here, and
3516 add the required "normal" config-lang.in rules.
3517 * c-lang.h: Moved from gcc/ to here.
3518 * c-tree.h: Likewise.
3519 * c-objc-common.c: Likewise.
3520 * c-objc-common.h: Likewise.
3521 * c-typeck.c: Likewise.
3522 * c-convert.c: Likewise.
3523 * c-lang.c: Likewise.
3524 * c-aux-info.c: Likewise.
3525 * c-errors.c: Likewise.
3526 * gccspec.c: Likewise.
3527 * c-decl.c: Likewise. Include gt-c-c-decl.h, not gt-c-decl.h.
3528 * c-parser.c: Likewise. Include gt-c-c-parser.h, not gt-c-parser.h.
3529\f
818ab71a 3530Copyright (C) 2012-2016 Free Software Foundation, Inc.
d4a10d0a
SB
3531
3532Copying and distribution of this file, with or without modification,
3533are permitted in any medium without royalty provided the copyright
3534notice and this notice are preserved.