]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c/ChangeLog
update-copyright.py: Add Mentor Graphics Corporation and Yoshinori Sato as external...
[thirdparty/gcc.git] / gcc / c / ChangeLog
CommitLineData
39292e25
EB
12019-12-20 Eric Botcazou <ebotcazou@adacore.com>
2
3 * c-decl.c (collect_source_ref_cb): Delete.
4 (for_each_global_decl): Rename into...
5 (collect_source_refs): ...this. Call collect_source_ref directly.
6 (c_parse_final_cleanups): Always call collect_source_ref on the main
7 input filename.
8
519d7496
JB
92019-12-19 Julian Brown <julian@codesourcery.com>
10 Cesar Philippidis <cesar@codesourcery.com>
11
12 * c-parser.c (c_parser_omp_clause_name): Add parsing of attach and
13 detach clauses.
14 (c_parser_omp_variable_list): Add ALLOW_DEREF optional parameter.
15 Allow deref (->) in variable lists if true.
16 (c_parser_omp_var_list_parens): Add ALLOW_DEREF optional parameter.
17 Pass to c_parser_omp_variable_list.
18 (c_parser_oacc_data_clause): Support attach and detach clauses. Update
19 call to c_parser_omp_variable_list.
20 (c_parser_oacc_all_clauses): Support attach and detach clauses.
21 (OACC_DATA_CLAUSE_MASK, OACC_ENTER_DATA_CLAUSE_MASK,
22 OACC_KERNELS_CLAUSE_MASK, OACC_PARALLEL_CLAUSE_MASK,
23 OACC_SERIAL_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_ATTACH.
24 (OACC_EXIT_DATA_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_DETACH.
25 * c-typeck.c (handle_omp_array_sections_1): Reject subarrays for attach
26 and detach. Support deref.
27 (handle_omp_array_sections): Use GOMP_MAP_ATTACH_DETACH instead of
28 GOMP_MAP_ALWAYS_POINTER for OpenACC.
29 (c_oacc_check_attachments): New function.
30 (c_finish_omp_clauses): Check attach/detach arguments for being
31 pointers using above. Support deref.
32
a6163563
JB
332019-12-19 Julian Brown <julian@codesourcery.com>
34 Maciej W. Rozycki <macro@codesourcery.com>
35 Tobias Burnus <tobias@codesourcery.com>
36 Thomas Schwinge <thomas@codesourcery.com>
37
38 * c-parser.c (c_parser_omp_clause_name): Support no_create.
39 (c_parser_oacc_data_clause): Likewise.
40 (c_parser_oacc_all_clauses): Likewise.
41 (OACC_DATA_CLAUSE_MASK, OACC_KERNELS_CLAUSE_MASK)
42 (OACC_PARALLEL_CLAUSE_MASK, OACC_SERIAL_CLAUSE_MASK): Add
43 PRAGMA_OACC_CLAUSE_NO_CREATE.
44 * c-typeck.c (handle_omp_array_sections): Support
45 GOMP_MAP_NO_ALLOC.
46
d68f5d45
DM
472019-12-09 David Malcolm <dmalcolm@redhat.com>
48
49 * c-objc-common.c (range_label_for_type_mismatch::get_text):
50 Replace label_text ctor calls.
51
4691bf46
JM
522019-12-04 Joseph Myers <joseph@codesourcery.com>
53
54 PR c/36941
55 PR c/88827
56 * c-typeck.c (convert_lvalue_to_rvalue): Call
57 require_complete_type for arguments not of void types.
58 (build_indirect_ref): Do not diagnose dereferencing pointers to
59 incomplete types.
60 * c-tree.h (C_TYPE_ERROR_REPORTED): Remove.
61
85d11957
JM
622019-12-03 Joseph Myers <joseph@codesourcery.com>
63
64 PR c/88704
65 * c-decl.c (store_parm_decls_oldstyle): Diagnose use of [*] in
66 old-style parameter definitions.
67
4569f8b3
SL
682019-12-01 Sandra Loosemore <sandra@codesourcery.com>
69
70 PR target/92499
71
72 * c-decl.c (flexible_array_type_p): Move to common code.
73
65ef05d0
RS
742019-11-30 Richard Sandiford <richard.sandiford@arm.com>
75
76 * c-decl.c (start_decl): Allow initialization of variables whose
77 size is a POLY_INT_CST.
78 (finish_decl): Use verify_type_context to check whether the target
79 allows variables with a particular type to have static or thread-local
80 storage duration. Don't raise a second error if such variables do
81 not have a constant size.
82 (grokdeclarator): Use verify_type_context to check whether the
83 target allows fields or array elements to have a particular type.
84 * c-typeck.c (pointer_diff): Use verify_type_context to test whether
85 the target allows pointer difference for the types involved.
86 (build_unary_op): Likewise for pointer increment and decrement.
87
34b43828
JM
882019-11-29 Joseph Myers <joseph@codesourcery.com>
89
90 * c-parser.c (struct c_parser): Add members raw_tokens and
91 raw_tokens_used.
92 (c_lex_one_token): Add argument raw. Handle lexing raw tokens and
93 using previously-lexed raw tokens.
94 (c_parser_peek_nth_token_raw)
95 (c_parser_check_balanced_raw_token_sequence): New functions.
96 (c_parser_nth_token_starts_std_attributes): Use
97 c_parser_check_balanced_raw_token_sequence for Objective-C.
98
5b8d9367
JM
992019-11-25 Joseph Myers <joseph@codesourcery.com>
100
101 PR c/91985
102 * c-decl.c (finish_declspecs): Use int instead of decimal
103 floating-point types if decimal floating-point not supported.
104
1723e1be
JM
1052019-11-25 Joseph Myers <joseph@codesourcery.com>
106
107 * c-tree.h (struct c_declarator): Use a structure for id member.
108 * c-decl.c (grokdeclarator): Extract attributes from cdk_id
109 declarators at the start, not when handling individual declarators
110 later. Use u.id.id instead of u.id.
111 (grokfield): Use u.id.id instead of u.id.
112 (build_id_declarator): Set u.id.id and u.id.attrs.
113 (finish_declspecs): Handle postfix attributes in case of typedef
114 name or typeof used.
115 * c-parser.c (c_parser_direct_declarator)
116 (c_parser_direct_declarator_inner): Place declarator for
117 attributes inside that for function or array, not outside. Set
118 u.id.attrs for identifiers.
119 (c_parser_parameter_declaration): Use u.id.id instead of u.id.
120 * gimple-parser.c (c_parser_gimple_declaration): Use u.id.id
121 instead of u.id.
122
bdaf8be1
JJ
1232019-11-22 Jakub Jelinek <jakub@redhat.com>
124
125 PR c/90677
126 * c-decl.c (identifier_global_tag): Define.
127
3e00ba47
RB
1282019-11-20 Richard Biener <rguenther@suse.de>
129
130 PR c/92088
131 * c-decl.c (grokdeclarator): Prevent inlining of nested
132 function with VLA arguments.
133
8c5b727a
JM
1342019-11-20 Joseph Myers <joseph@codesourcery.com>
135
136 * c-decl.c (c_warn_type_attributes): New function.
137 (groktypename, grokdeclarator, finish_declspecs): Call
138 c_warn_type_attributes before applying attributes to types.
139 * c-tree.h (c_warn_type_attributes): Declare.
140
192961ff
JM
1412019-11-19 Joseph Myers <joseph@codesourcery.com>
142
143 * c-decl.c (c_warn_unused_attributes): Use pedwarn not warning for
144 standard attributes.
145 * c-parser.c (c_parser_std_attribute): Take argument for_tm. Use
146 pedwarn for unknown standard attributes and return error_mark_node
147 for them.
148
20a38017
MM
1492019-11-18 Matthew Malcomson <matthew.malcomson@arm.com>
150
151 * c-parser.c (c_parser_parse_rtl_body): Always call
152 run_rtl_passes, even if startwith pass is not provided.
153
d5fbe5e0
JM
1542019-11-15 Joseph Myers <joseph@codesourcery.com>
155
156 * c-parser.c (c_parser_std_attribute_specifier): Diagnose
157 duplicate standard attributes.
158
97cc1187
JM
1592019-11-15 Joseph Myers <joseph@codesourcery.com>
160
161 * c-decl.c (std_attribute_table): Add maybe_unused.
162
f8aea5e3
JM
1632019-11-15 Joseph Myers <joseph@codesourcery.com>
164
165 * c-decl.c (std_attribute_table): Add fallthrough.
166 * c-parser.c (c_parser_declaration_or_fndef): Diagnose fallthrough
167 attribute at top level.
168
2cc94aa8
JM
1692019-11-15 Joseph Myers <joseph@codesourcery.com>
170
171 * c-decl.c (std_attribute_table): New.
172 (c_init_decl_processing): Register attributes from
173 std_attribute_table.
174 * c-parser.c (c_parser_attribute_arguments): Add arguments
175 require_string and allow_empty_args. All callers changed.
176 (c_parser_std_attribute): Set require_string argument for
177 "deprecated" attribute.
178
7c5890cc
JM
1792019-11-14 Joseph Myers <joseph@codesourcery.com>
180
181 * c-parser.c (c_parser_postfix_expression)
182 (c_parser_check_literal_zero): Handle CPP_UTF8CHAR.
183 * gimple-parser.c (c_parser_gimple_postfix_expression): Likewise.
184
e8738f4e
RS
1852019-11-14 Richard Sandiford <richard.sandiford@arm.com>
186
187 * c-typeck.c (build_conditional_expr): Use truth_type_for instead
188 of build_same_sized_truth_vector_type.
189 (build_vec_cmp): Likewise.
190
b2417b59
JJ
1912019-11-14 Jakub Jelinek <jakub@redhat.com>
192
bedb7f04
JJ
193 * c-parser.c (c_parser_omp_context_selector): Don't require score
194 argument to fit into shwi, just to be INTEGER_CST. Diagnose
195 negative score.
196
b2417b59
JJ
197 * c-parser.c (c_parser_omp_context_selector): Rename
198 CTX_PROPERTY_IDLIST to CTX_PROPERTY_NAME_LIST, add CTX_PROPERTY_ID.
199 Use CTX_PROPERTY_ID for atomic_default_mem_order, only allow a single
200 identifier in that. For CTX_PROPERTY_NAME_LIST, allow identifiers
201 and string literals.
202
4e03c3a7
JM
2032019-11-14 Joseph Myers <joseph@codesourcery.com>
204
205 * c-tree.h (enum c_typespec_kind): Add ctsk_tagref_attrs and
206 ctsk_tagfirstref_attrs.
207 (struct c_declspecs): Update description of attrs. Add
208 postfix_attrs and non_std_attrs_seen_p. Increase size of
209 typespec_kind bit-field.
210 (c_warn_unused_attributes): New declaration.
211 (parser_xref_tag): Update prototype.
212 * c-decl.c (c_warn_unused_attributes): New function.
213 (shadow_tag_warned): Handle ctsk_tagfirstref_attrs and
214 ctsk_tagref_attrs. Handle attribute declarations.
215 (check_compound_literal_type): Handle ctsk_tagfirstref_attrs.
216 (grokdeclarator): Handle standard attributes.
217 (parser_xref_tag): Add arguments have_std_attrs and attrs. Apply
218 attributes to incomplete type reference.
219 (xref_tag): Update call to parser_xref_tag.
220 (declspecs_add_addrspace, declspecs_add_type)
221 (declspecs_add_scspec, declspecs_add_attrs): Set
222 non_std_attrs_seen_p.
223 (finish_declspecs): Apply postfix standard attributes to type.
224 * c-parser.c (c_token_starts_declspecs)
225 (c_token_starts_declaration, c_parser_next_token_starts_declspecs)
226 (c_parser_next_tokens_start_declaration): Update comments.
227 (c_parser_consume_token, c_parser_consume_pragma): Handle moving
228 parser->tokens[2] to parser->tokens[1].
229 (c_parser_nth_token_starts_std_attributes)
230 (c_parser_std_attribute_specifier_sequence): New functions.
231 (c_parser_declaration_or_fndef): Add arguments have_attrs and
232 attrs. All callers changed. Handle standard attributes.
233 (c_parser_parms_declarator, c_parser_parms_list_declarator)
234 (c_parser_parameter_declaration): Add argument have_gnu_attrs.
235 All callers changed.
236 (c_parser_declspecs): Add arguments start_std_attr_ok and
237 end_std_attr_ok. All callers changed. Handle standard
238 attributes.
239 (c_parser_enum_specifier, c_parser_struct_or_union_specifier)
240 (c_parser_direct_declarator, c_parser_direct_declarator_inner)
241 (c_parser_compound_statement_nostart, c_parser_all_labels)
242 (c_parser_label, c_parser_statement, c_parser_for_statement):
243 Handle standard attributes.
244 * c-parser.h (c_parser_declspecs): Update prototype.
245 * gimple-parser.c (c_parser_gimple_declaration): Update call to
246 c_parser_declspecs.
247
0c29cac4
ML
2482019-11-12 Martin Liska <mliska@suse.cz>
249
250 * gimple-parser.c: Do not include params.h.
251
028d4092
ML
2522019-11-12 Martin Liska <mliska@suse.cz>
253
254 * gimple-parser.c (c_parser_parse_gimple_body): Replace old parameter syntax
255 with the new one, include opts.h if needed. Use SET_OPTION_IF_UNSET
256 macro.
257
62aee289
MR
2582019-11-12 Maciej W. Rozycki <macro@codesourcery.com>
259 Frederik Harwath <frederik@codesourcery.com>
260
261 gcc/c/
262 * c-parser.c (OACC_SERIAL_CLAUSE_MASK): New macro.
263 (c_parser_oacc_kernels_parallel): Rename function to...
264 (c_parser_oacc_compute): ... this. Handle PRAGMA_OACC_SERIAL.
265 (c_parser_omp_construct): Update accordingly.
266
267
7cec9588
JJ
2682019-11-11 Jakub Jelinek <jakub@redhat.com>
269
270 * c-parser.c (c_parser_translation_unit): Diagnose declare target
271 without corresponding end declare target.
272
f486280c
RS
2732019-11-08 Richard Sandiford <richard.sandiford@arm.com>
274
275 * c-convert.c (convert): Only handle vector conversions if one of
276 the types satisfies gnu_vector_type_p or if -flax-vector-conversions
277 allows it.
278 * c-typeck.c (build_array_ref): Only allow vector indexing if the
279 vectors satisfy gnu_vector_type_p.
280 (build_unary_op): Only allow unary operators to be applied to
281 vectors if they satisfy gnu_vector_type_p.
282 (digest_init): Only allow by-element initialization of vectors
283 if they satisfy gnu_vector_type_p.
284 (really_start_incremental_init): Likewise.
285 (push_init_level): Likewise.
286 (pop_init_level): Likewise.
287 (process_init_element): Likewise.
288 (build_binary_op): Only allow binary operators to be applied to
289 vectors if they satisfy gnu_vector_type_p.
290
017c6491
JM
2912019-11-08 Joseph Myers <joseph@codesourcery.com>
292
293 * c-decl.c (grokparms): Convert () in a function definition to
294 (void) for C2x.
295 (store_parm_decls_oldstyle): Pedwarn for C2x.
296 (store_parm_decls): Update comment about () not generating a
297 prototype.
298
c01bd174
JM
2992019-11-07 Joseph Myers <joseph@codesourcery.com>
300
301 * c-parser.c (c_parser_attribute_arguments): New function.
302 Factored out of c_parser_gnu_attribute.
303 (c_parser_gnu_attribute): Use c_parser_attribute_arguments.
304 (c_parser_balanced_token_sequence, c_parser_std_attribute)
305 (c_parser_std_attribute_specifier): New functions.
306 (c_parser_transaction_attributes): Use
307 c_parser_std_attribute_specifier.
308
471c5330
JM
3092019-11-07 Joseph Myers <joseph@codesourcery.com>
310
311 * c-parser.c (c_parser): Remove lex_untranslated_string. Add
312 lex_joined_string and translate_strings_p.
313 (c_lex_one_token): Pass 0 or C_LEX_STRING_NO_JOIN to
314 c_lex_with_flags.
315 (c_parser_string_literal): New function.
316 (c_parser_static_assert_declaration_no_semi): Use
317 c_parser_string_literal. Do not set lex_untranslated_string.
318 (c_parser_asm_string_literal): Use c_parser_string_literal.
319 (c_parser_simple_asm_expr): Do not set lex_untranslated_string.
320 (c_parser_gnu_attributes): Set and restore translate_strings_p
321 instead of lex_untranslated_string.
322 (c_parser_asm_statement): Do not set lex_untranslated_string.
323 (c_parser_asm_operands): Likewise.
324 (c_parser_has_attribute_expression): Set and restore
325 translate_strings_p instead of lex_untranslated_string.
326 (c_parser_postfix_expression): Use c_parser_string_literal.
327 (pragma_lex): Likewise.
328 (c_parser_pragma_pch_preprocess): Set lex_joined_string.
329 (c_parse_file): Set translate_strings_p.
330 * gimple-parser.c (c_parser_gimple_postfix_expression)
331 (c_parser_gimple_or_rtl_pass_list): Use c_parser_string_literal.
332 * c-parser.c (c_parser_string_literal): Declare function.
333
d0c464d2
JJ
3342019-11-02 Jakub Jelinek <jakub@redhat.com>
335
336 * c-parser.c (c_finish_omp_declare_variant): Use
337 omp_get_context_selector instead of c_omp_get_context_selector.
338
ac2cfa6c
RS
3392019-10-29 Richard Sandiford <richard.sandiford@arm.com>
340
341 * c-tree.h (c_simulate_enum_decl): Declare.
342 * c-decl.c (c_simulate_enum_decl): New function.
343 * c-objc-common.h (LANG_HOOKS_SIMULATE_ENUM_DECL): Define to the above.
344
74078538
RS
3452019-10-29 Richard Sandiford <richard.sandiford@arm.com>
346
347 * c-tree.h (c_simulate_builtin_function_decl): Declare.
348 * c-decl.c (c_simulate_builtin_function_decl): New function.
349 * c-objc-common.h (LANG_HOOKS_SIMULATE_BUILTIN_FUNCTION_DECL): Define
350 to the above.
351
ad1539d5
MS
3522019-10-28 Martin Sebor <msebor@redhat.com>
353
354 PR c/66970
355 * c-decl.c (names_builtin_p): Define a new function.
356
cb73e4e7
RB
3572019-10-28 Richard Biener <rguenther@suse.de>
358
359 PR c/92249
360 * gimple-parser.c (c_parser_parse_gimple_body): Make
361 current_bb the entry block initially to easier recover
362 from errors.
363 (c_parser_gimple_compound_statement): Adjust.
364
135df52c
JJ
3652019-10-24 Jakub Jelinek <jakub@redhat.com>
366
367 * c-parser.c (c_finish_omp_declare_variant): Use
368 omp_context_selector_matches instead of
369 c_omp_context_selector_matches.
370 * c-decl.c (c_decl_attributes): Add "omp declare target block"
371 attribute in between declare target and end declare target
372 pragmas.
373
783bfe5e
JM
3742019-10-15 Joseph Myers <joseph@codesourcery.com>
375
376 * c-parser.c (c_parser_attribute_any_word): Rename to
377 c_parser_gnu_attribute_any_word. All callers changed.
378 (c_parser_attribute): Rename to c_parser_gnu_attribute. All
379 callers changed.
380 (c_parser_attributes): Rename to c_parser_gnu_attributes. All
381 callers changed.
382 (c_parser_declaration_or_fndef, c_parser_declspecs)
383 (c_parser_enum_specifier, c_parser_struct_or_union_specifier)
384 (c_parser_struct_declaration, c_parser_declarator)
385 (c_parser_gnu_attribute, c_parser_compound_statement)
386 (c_parser_label, c_parser_statement, c_parser_objc_method_decl)
387 (c_parser_transaction_attributes): Add "gnu-" prefix to names of
388 attribute-related syntax productions.
389
56898e43
RS
3902019-10-14 Richard Sandiford <richard.sandiford@arm.com>
391
392 * c-objc-common.c (useful_aka_type_p): Replace with...
393 (get_aka_type): ...this new function. Given the original type,
394 decide which aka type to print (if any). Only look through typedefs
395 if user_facing_original_type_p.
396 (print_type): Update accordingly.
397
b9424661
JJ
3982019-10-14 Jakub Jelinek <jakub@redhat.com>
399
400 * c-parser.c (c_parser_omp_all_clauses): Change bool NESTED_P argument
401 into int NESTED, if it is 2, diagnose missing commas in between
402 clauses.
403 (c_parser_omp_context_selector): Pass 2 as last argument to
404 c_parser_omp_all_clauses.
405
20de9568
JJ
4062019-10-12 Jakub Jelinek <jakub@redhat.com>
407
408 * c-parser.c (c_parser_omp_context_selector): Improve error recovery.
409 For simd properties, put them directly into TREE_VALUE.
410 (c_finish_omp_declare_variant): Call c_omp_mark_declare_variant.
411 If c_omp_context_selector_matches is 0, don't add attribute, otherwise
412 add "omp declare variant base" attribute rather than
413 "omp declare variant".
414
fe2bc27c
JM
4152019-10-11 Joseph Myers <joseph@codesourcery.com>
416
417 * c-decl.c (declspecs_add_type): Use pedwarn_c11 for DFP types.
418
94e7f906
JJ
4192019-10-10 Jakub Jelinek <jakub@redhat.com>
420
421 * c-parser.c (c_parser_omp_all_clauses): Add NESTED_P argument, if
422 true, terminate processing on closing paren and don't skip to end of
423 pragma line.
424 (c_parser_omp_declare_simd): Handle also declare variant.
425 (omp_construct_selectors, omp_device_selectors,
426 omp_implementation_selectors, omp_user_selectors): New variables.
427 (c_parser_omp_context_selector,
428 c_parser_omp_context_selector_specification,
429 c_finish_omp_declare_variant): New functions.
430 (c_finish_omp_declare_simd): Handle both declare simd and
431 declare variant.
432 (c_parser_omp_declare): Handle declare variant.
433
93313b94
JM
4342019-10-02 Joseph Myers <joseph@codesourcery.com>
435
436 * c-parser.c (c_parser_asm_statement): Handle CPP_SCOPE like two
437 CPP_COLON tokens.
438
55879815
RS
4392019-10-01 Richard Sandiford <richard.sandiford@arm.com>
440
441 * c-objc-common.c (useful_aka_type_p): New function.
442 (print_type): Use it to decide whether an aka type is worth printing.
443
59bc434a
JJ
4442019-09-27 Jakub Jelinek <jakub@redhat.com>
445
446 PR c++/88203
447 * c-parser.c (c_parser_predefined_identifier): New function.
448 (c_parser_postfix_expression): Use it.
449 (c_parser_omp_variable_list): Parse predefined identifiers.
450 * c-typeck.c (c_finish_omp_clauses): Allow predefined variables
451 in shared and firstprivate clauses, even when they are predetermined
452 shared.
453
c6447c20
RS
4542019-09-27 Richard Sandiford <richard.sandiford@arm.com>
455
456 * c-typeck.c (build_function_call_vec): Take the original function
457 decl as an optional final parameter. Pass all built-in calls to
458 check_builtin_function_arguments.
459
522da4c2
EB
4602019-09-20 Eric Botcazou <ebotcazou@adacore.com>
461
462 PR c/91815
463 * c-decl.c (pushdecl): In C detect duplicate declarations across scopes
464 of identifiers in the external scope only for variables and functions.
465
68e2c199
PK
4662019-09-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
467
468 PR c/78736
469 * c-typeck.c (convert_for_assignment): Handle Wenum-conversion.
470
22f8849d
IS
4712019-08-23 Iain Sandoe <iain@sandoe.co.uk>
472
473 PR pch/61250
474 * c-parser.c (c_parse_file): Call c_common_no_more_pch ()
475 after determining that the first token is not
476 PRAGMA_GCC_PCH_PREPROCESS.
477
db376f45
EB
4782019-08-22 Eric Botcazou <ebotcazou@adacore.com>
479
480 * c-parser.c (c_parser_declaration_or_fndef): Set DECL_ARGUMENTS of a
481 FUNCTION_DECL to the right value in the presence of nested declarators.
482
4d732405
RS
4832019-08-13 Richard Sandiford <richard.sandiford@arm.com>
484
485 PR middle-end/91421
486 * c-decl.c (merge_decls): Use copy_decl_built_in_function.
487
cb1180d5
RS
4882019-08-13 Richard Sandiford <richard.sandiford@arm.com>
489
490 PR middle-end/91421
491 * c-decl.c (header_for_builtin_fn): Take a FUNCTION_DECL instead
492 of a built_in_function.
493 (diagnose_mismatched_decls, implicitly_declare): Update accordingly.
494
77eb117f
JJ
4952019-08-10 Jakub Jelinek <jakub@redhat.com>
496
497 * c-parser.c (c_parser_omp_clause_name): Parse device_type.
498 (c_parser_omp_clause_device_type): New function.
499 (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
500 (OMP_DECLARE_TARGET_CLAUSE_MASK): Add PRAGMA_OMP_CLAUSE_DEVICE_TYPE.
501 (c_parser_omp_declare_target): Handle device_type clauses. Remove
502 diagnostics for declare target with clauses nested in clause-less
503 declare target declaration-definition-seq.
504 * c-typeck.c (c_finish_omp_clauses): Handle OMP_CLAUSE_DEVICE_TYPE.
505
2c3b8bad
JJ
5062019-08-09 Jakub Jelinek <jakub@redhat.com>
507
bb522e2e
JJ
508 * c-parser.c (check_no_duplicate_clause): Simplify using
509 omp_find_clause.
510 (c_parser_omp_clause_if): Fix up printing of target {enter,exit} data
511 directive name modifiers.
512 (c_parser_omp_clause_proc_bind): Check for duplicate proc_bind clause.
513
2c3b8bad
JJ
514 PR c/91401
515 * c-parser.c (c_parser_omp_clause_dist_schedule): Fix up typos in the
516 check_no_duplicate_clause call. Comment it out, instead emit a
517 warning for duplicate dist_schedule clauses.
518
99769e7f
RS
5192019-08-08 Richard Sandiford <richard.sandiford@arm.com>
520
521 * c-decl.c (finish_enum): Clear C_TYPE_BEING_DEFINED.
522
8860d270
JJ
5232019-08-08 Jakub Jelinek <jakub@redhat.com>
524
525 * c-typeck.c (c_finish_omp_clauses): For C_ORT_OMP
526 OMP_CLAUSE_USE_DEVICE_* clauses use oacc_reduction_head bitmap
527 instead of generic_head to track duplicates.
528
398e3feb
JJ
5292019-08-07 Jakub Jelinek <jakub@redhat.com>
530
531 * c-parser.c (c_parser_omp_clause_name): Parse use_device_addr clause.
532 (c_parser_omp_clause_use_device_addr): New function.
533 (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR.
534 (OMP_TARGET_DATA_CLAUSE_MASK): Add PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR.
535 (c_parser_omp_target_data): Handle PRAGMA_OMP_CLAUSE_USE_DEVICE_ADDR
536 like PRAGMA_OMP_CLAUSE_USE_DEVICE_PTR, adjust diagnostics about no
537 map or use_device_* clauses.
538 * c-typeck.c (c_finish_omp_clauses): For OMP_CLAUSE_USE_DEVICE_PTR
539 in OpenMP, require pointer type rather than pointer or array type.
540 Handle OMP_CLAUSE_USE_DEVICE_ADDR.
541
a28351e7
JJ
5422019-07-31 Jakub Jelinek <jakub@redhat.com>
543
544 PR c/91192
545 * c-parser.c (c_parser_sizeof_expression): Call set_c_expr_source_range
546 even if finish is UNKNOWN_LOCATION, just use start as finish in that
547 case.
548
6343b6bf
ML
5492019-07-25 Martin Liska <mliska@suse.cz>
550 Dominik Infuhr <dominik.infuehr@theobroma-systems.com>
551
552 PR c++/23383
553 * c-decl.c (merge_decls): Merge OPERATOR_DELETE flag.
554
cb50701e
ML
5552019-07-25 Martin Liska <mliska@suse.cz>
556
557 * c-decl.c (merge_decls): Use new macros
558 (e.g. DECL_SET_LAMBDA_FUNCTION and DECL_LAMBDA_FUNCTION_P).
559
62e3e66f
RB
5602019-07-23 Richard Biener <rguenther@suse.de>
561
562 PR tree-optimization/83518
563 * gimple-parser.c (c_parser_parse_gimple_body): When we have
564 a CFG also rebuild cgraph edges.
565
554a530f
JJ
5662019-07-20 Jakub Jelinek <jakub@redhat.com>
567
568 * c-parser.c (c_parser_omp_clause_name): Handle bind clause.
569 (c_parser_omp_clause_bind): New function.
570 (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_BIND.
571 (OMP_LOOP_CLAUSE_MASK): Define.
572 (c_parser_omp_loop): New function.
573 (c_parser_omp_parallel, c_parser_omp_teams): Handle parsing of
574 loop combined with parallel or teams.
575 (c_parser_omp_construct): Handle PRAGMA_OMP_LOOP.
576 * c-typeck.c (c_finish_omp_clauses): Handle OMP_CLAUSE_BIND.
577
d119bf79
RS
5782019-07-18 Richard Sandiford <richard.sandiford@arm.com>
579
580 PR c/53633
581 * c-decl.c (finish_function): Check targetm.warn_func_return
582 before issuing a -Wreturn-type warning.
583
ab20d992 5842019-07-12 Alexandre Oliva <oliva@adacore.com>
fdc1f343
AO
585
586 * gimple-parser.c (c_parser_gimple_try_stmt): New.
587 (c_parser_compound_statement): Call it.
588
1fdd6f04
JJ
5892019-07-12 Jakub Jelinek <jakub@redhat.com>
590
591 * c-parser.c (c_parser_omp_clause_name): Handle order clause.
592 (c_parser_omp_clause_order): New function.
593 (c_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_ORDER.
594 (OMP_SIMD_CLAUSE_MASK, OMP_FOR_CLAUSE_MASK): Add
595 PRAGMA_OMP_CLAUSE_ORDER.
596 * c-typeck.c (c_finish_omp_clauses): Handle OMP_CLAUSE_ORDER.
597
8389386c
RB
5982019-07-10 Richard Biener <rguenther@suse.de>
599
600 * gimple-parser.c (c_parser_gimple_postfix_expression): Support
601 _Literal (int *) &x for address literals.
602
99b1c316
MS
6032019-07-09 Martin Sebor <msebor@redhat.com>
604
605 PR c++/61339
606 * c-decl.c (xref_tag): Change class-key of PODs to struct and others
607 to class.
608 (field_decl_cmp): Same.
609 * c-parser.c (c_parser_struct_or_union_specifier): Same.
610 * c-tree.h: Same.
611 * gimple-parser.c (c_parser_gimple_compound_statement): Same.
612
6c1dae73
MS
6132019-07-09 Martin Sebor <msebor@redhat.com>
614
615 PR c++/61339
616 * c-decl.c: Change class-key from class to struct and vice versa
617 to match convention and avoid -Wclass-is-pod and -Wstruct-no-pod.
618 * gimple-parser.c: Same.
619
69b5279e
RB
6202019-07-01 Richard Biener <rguenther@suse.de>
621
622 * gimple-parser.c (c_parser_gimple_postfix_expression): Handle
623 _Literal (char *) &"foo" for address literals pointing to
624 STRING_CSTs.
625
ab20d992
JJ
6262019-06-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
627
628 * c-parser.c (c_parse_init): Create keyword for "__intN__" type.
629 * c-decl.c (declspecs_add_type): Don't pedwarn about "__intN" ISO
630 C incompatibility if alternate "__intN__" form is used.
631
1e3d475e
MS
6322019-06-24 Martin Sebor <msebor@redhat.com>
633
634 * c-typeck.c (build_binary_op): Hyphenate floating-point.
635
bf38f7e9
JJ
6362019-06-10 Jakub Jelinek <jakub@redhat.com>
637
638 * c-parser.c (c_parser_pragma): Reject PRAGMA_OMP_SCAN.
639 (c_parser_omp_clause_reduction): Don't sorry_at on inscan reductions.
640 (c_parser_omp_scan_loop_body): New function.
641 (c_parser_omp_for_loop): Call c_parser_omp_scan_loop_body if there are
642 inscan reduction clauses.
643 * c-typeck.c (c_finish_omp_clauses): Reject mixing inscan with
644 non-inscan reductions on the same construct, or inscan reductions with
645 ordered or schedule clauses, or inscan array reductions.
646
65985d78
MS
6472019-06-05 Martin Sebor <msebor@redhat.com>
648
649 PR c/90737
650 * c-typeck.c (c_finish_return): Only consider functions returning
651 pointers as candidates for -Wreturn-local-addr.
652
0ecf545c
MS
6532019-06-05 Martin Sebor <msebor@redhat.com>
654
655 * c-decl.c (start_decl): Adjust quoting and hyphenation
656 in diagnostics.
657 (finish_decl): Same.
658 (finish_enum): Same.
659 (start_function): Same.
660 (declspecs_add_type): Same.
661 * c-parser.c (warn_for_abs): Same.
662 * c-typeck.c (build_binary_op): Same.
663
e03436e7
TS
6642019-05-17 Thomas Schwinge <thomas@codesourcery.com>
665
b48f44bf
TS
666 PR c/89433
667 * c-parser.c (c_finish_oacc_routine): Rework checking if already
668 marked with an OpenACC 'routine' directive.
669
5bf04509
TS
670 PR c/89433
671 * c-parser.c (c_parser_oacc_routine): Normalize order of clauses.
672 (c_finish_oacc_routine): Call oacc_verify_routine_clauses.
673
e03436e7
TS
674 PR c/89433
675 * c-parser.c (c_finish_oacc_routine): Refer to OpenACC 'routine'
676 clauses from "omp declare target" attribute.
677
a9c697b8
MS
6782019-05-16 Martin Sebor <msebor@redhat.com>
679
ab20d992
JJ
680 * c-decl.c (start_decl): Quote keywords, operators, and
681 types in diagnostics.
682 (finish_decl): Same.
683 * c-parser.c (c_parser_asm_statement): Same.
684 (c_parser_conditional_expression): Same.
685 (c_parser_transaction_cancel): Same.
686 * c-typeck.c (c_common_type): Same.
687 (build_conditional_expr): Same.
688 (digest_init): Same.
689 (process_init_element): Same.
690 (build_binary_op): Same.
a9c697b8 691
c4499192
RB
6922019-05-17 Richard Biener <rguenther@suse.de>
693
694 * gimple-parser.c (c_parser_gimple_statement): Handle __VEC_PERM.
695 (c_parser_gimple_unary_expression): Likewise.
696 (c_parser_gimple_parentized_ternary_expression): New function.
697
adfe6e4b
RB
6982019-05-16 Richard Biener <rguenther@suse.de>
699
700 * gimple-parser.c (c_parser_gimple_statement): Handle __BIT_INSERT.
701 (c_parser_gimple_unary_expression): Likewise.
702
186dabf2
RB
7032019-05-15 Richard Biener <rguenther@suse.de>
704
705 * gimple-parser.c (c_parser_gimple_postfix_expression): Handle
706 __BIT_FIELD_REF.
707
1158c5b4
RB
7082019-05-14 Richard Biener <rguenther@suse.de>
709
710 * gimple-parser.c (c_parser_gimple_statement): Remove
711 questionable auto-promotion to VIEW_CONVERT_EXPR.
712 (c_parser_gimple_typespec): Split out from __MEM parsing.
713 (c_parser_gimple_postfix_expression): Handle __VIEW_CONVERT.
714 * tree-pretty-print.c (dump_generic_node): Dump VIEW_CONVERT_EXPR
715 as __VIEW_CONVERT with -gimple.
716
fd4485aa
ML
7172019-05-09 Martin Liska <mliska@suse.cz>
718
719 * gimple-parser.c (c_parser_gimple_statement): Support __MIN and
720 __MAX.
721 (c_parser_gimple_unary_expression): Parse also binary expression
722 __MIN and __MAX.
723 (c_parser_gimple_parentized_binary_expression): New function.
724
d276406a
ML
7252019-05-09 Martin Liska <mliska@suse.cz>
726
727 * gimple-parser.c (struct gimple_parser): Add probability.
728 for gimple_parser_edge.
729 (gimple_parser::push_edge): Add new argument probability.
730 (c_parser_gimple_parse_bb_spec): Parse also probability
731 if present.
732 (c_parser_parse_gimple_body): Set edge probability.
733 (c_parser_gimple_compound_statement): Consume token
734 before calling c_parser_gimple_goto_stmt.
735 Parse BB counts.
736 (c_parser_gimple_statement): Pass new argument.
737 (c_parser_gimple_goto_stmt): Likewise.
738 (c_parser_gimple_if_stmt): Likewise.
739 (c_parser_gimple_or_rtl_pass_list): Parse hot_bb_threshold.
740 * c-parser.c (c_parser_declaration_or_fndef): Pass
741 hot_bb_threshold argument.
742 * c-tree.h (struct c_declspecs): Add hot_bb_threshold
743 field.
744 (c_parser_gimple_parse_bb_spec_edge_probability): New.
745
f179b64e
JJ
7462019-04-26 Jakub Jelinek <jakub@redhat.com>
747
748 PR debug/90197
749 * c-tree.h (c_finish_loop): Add 2 further location_t arguments.
750 * c-parser.c (c_parser_while_statement): Adjust c_finish_loop caller.
751 (c_parser_do_statement): Likewise.
752 (c_parser_for_statement): Likewise. Formatting fixes.
753 * c-typeck.c (c_finish_loop): Add COND_LOCUS and INCR_LOCUS arguments,
754 emit DEBUG_BEGIN_STMTs if needed.
755
e7178413
JJ
7562019-04-19 Jakub Jelinek <jakub@redhat.com>
757
c280b7ee
JJ
758 PR c/89888
759 * c-typeck.c (struct c_switch): Remove outside_range_p member.
760 (c_start_case): Don't clear it.
761 (do_case): Adjust c_add_case_label caller.
762 (c_finish_case): Adjust c_do_switch_warnings caller.
763
e7178413
JJ
764 PR c++/90108
765 * c-decl.c (merge_decls): If remove is main variant and
766 DECL_ORIGINAL_TYPE is some other type, remove a DECL_ORIGINAL_TYPE
767 variant that has newdecl as TYPE_NAME if any.
768
60a2c645
JJ
7692019-04-12 Jakub Jelinek <jakub@redhat.com>
770
771 PR c/89933
772 * c-decl.c (merge_decls): When newdecl's type is its main variant,
773 don't try to remove it from the variant list, but instead assert
774 it has no variants.
775
2a82beaa
RB
7762019-04-01 Richard Biener <rguenther@suse.de>
777
778 PR c/71598
779 * c-tree.h (c_get_alias_set): Declare.
780 * c-objc-common.h (LANG_HOOKS_GET_ALIAS_SET): Use c_get_alias_set.
781 * c-objc-common.c (c_get_alias_set): Treat enumeral types
782 as the underlying integer type.
783
bec1da64
MS
7842019-03-19 Martin Sebor <msebor@redhat.com>
785
786 PR tree-optimization/89688
787 * c-decl.c (finish_decl): Call braced_lists_to_string for more
788 kinds of initializers.
789
855cd9b1
JJ
7902019-03-19 Jakub Jelinek <jakub@redhat.com>
791
792 PR c/89734
793 * c-decl.c (grokdeclarator): Call c_build_qualified_type on function
794 return type even if quals_used is 0. Formatting fixes.
795
baa09dc5
RB
7962019-03-14 Richard Biener <rguenther@suse.de>
797
798 * c-tree.h (enum c_declspec_il): New.
799 (struct c_declspecs): Merge gimple_p and rtl_p into declspec_il
800 enum bitfield.
801 * c-parser.c (c_parser_declaration_or_fndef): Adjust accordingly.
802 Pass start pass and declspec_il to c_parser_parse_gimple_body.
803 (c_parser_declspecs): Adjust.
804 * gimple-parser.c: Include cfg.h, cfghooks.h, cfganal.h, tree-cfg.h,
805 gimple-iterator.h, cfgloop.h, tree-phinodes.h, tree-into-ssa.h
806 and bitmap.h.
807 (struct gimple_parser): New.
808 (gimple_parser::push_edge): New method.
809 (c_parser_gimple_parse_bb_spec): New helper.
810 (c_parser_parse_gimple_body): Get start pass and IL specification.
811 Initialize SSA and CFG.
812 (c_parser_gimple_compound_statement): Handle CFG and SSA build.
813 Build a gimple_parser parsing state and pass it along.
814 (c_parser_gimple_statement): Change intermittend __PHI internal
815 function argument for the edge.
816 (c_parser_gimple_or_rtl_pass_list): Handle ssa, cfg flags.
817 (c_parser_gimple_goto_stmt): Record edges to build.
818 (c_parser_gimple_if_stmt): Likewise.
819 * gimple-parser.h (c_parser_parse_gimple_body): Adjust.
820 (c_parser_gimple_or_rtl_pass_list): Likewise.
821
a3f9f006
ML
8222019-03-11 Martin Liska <mliska@suse.cz>
823
824 * c-decl.c (check_for_loop_decls): Wrap an option name
825 in a string format message and fix GNU coding style.
826 * c-parser.c (c_parser_declspecs): Likewise.
827
1db01ff9
JJ
8282019-03-08 Jakub Jelinek <jakub@redhat.com>
829
830 PR tree-optimization/89550
831 * c-decl.c (finish_function): Only set TREE_NO_WARNING if warning_at
832 returned true.
833 (c_write_global_declarations_1): Only set TREE_NO_WARNING if pedwarn
834 or warning returned true.
835
66dcb747
JJ
8362019-02-28 Jakub Jelinek <jakub@redhat.com>
837
838 PR c/89525
839 * c-typeck.c (convert_arguments): Call inform_declaration only if
840 the previous warning_at call returned true.
841
2263c9f2
TS
8422019-02-22 Thomas Schwinge <thomas@codesourcery.com>
843
844 * c-parser.c (c_parser_oacc_shape_clause): Add loc formal
845 parameter. Adjust all users.
846 (c_parser_oacc_simple_clause): Replace parser with loc formal
847 parameter. Adjust all users.
848
ab20d992 8492019-02-19 Chung-Lin Tang <cltang@codesourcery.com>
19695f4d
CLT
850
851 PR c/87924
852 * c-parser.c (c_parser_oacc_clause_wait): Add representation of wait
853 clause without argument as 'wait (GOMP_ASYNC_NOVAL)', adjust comments.
854
5f88ba10
JJ
8552019-02-15 Jakub Jelinek <jakub@redhat.com>
856
857 PR c/89340
858 * c-decl.c (start_function): Clear TREE_PUBLIC on nested functions
859 before c_decl_attributes rather than after it.
860
cfc30fd1
JJ
8612019-02-06 Jakub Jelinek <jakub@redhat.com>
862
863 PR c/89211
864 * c-parser.c (c_parser_declaration_or_fndef): Don't update
865 DECL_ARGUMENTS of d if it has been defined already. Use a single if
866 instead of 3 nested ifs.
867
fbe83e6b
JM
8682019-02-06 Joseph Myers <joseph@codesourcery.com>
869
870 PR c/88584
871 * c-decl.c (finish_decl): Do not complete array types for arrays
872 with external linkage not at file scope.
873
f461f938
RB
8742019-02-05 Richard Biener <rguenther@suse.de>
875
876 PR c/88606
877 * c-decl.c (finish_struct): Reset TYPE_TRANSPARENT_AGGR on
878 all type variants when not supported.
879
fe509359
JJ
8802019-01-30 Jakub Jelinek <jakub@redhat.com>
881
882 PR c/89061
883 * c-tree.h (C_DECL_COMPOUND_LITERAL_P): Define.
884 * c-decl.c (decl_jump_unsafe): Return false for
885 C_DECL_COMPOUND_LITERAL_P decls.
886 (build_compound_literal): Set C_DECL_COMPOUND_LITERAL_P.
887
6a335b96
JJ
8882019-01-29 Jakub Jelinek <jakub@redhat.com>
889
f4b7e754
JJ
890 PR c/89045
891 * c-decl.c (build_compound_literal): Don't pushdecl if in parameter
892 scope.
893
6a335b96
JJ
894 PR c/86125
895 * c-decl.c (last_fileptr_type): Remove.
896 (last_structptr_types): New variable.
897 (match_builtin_function_types): Compare TYPE_MAIN_VARIANT of
898 {old,new}rettype instead of the types themselves. Assert
899 last_structptr_types array has the same number of elements
900 as builtin_structptr_types array. Use TYPE_MAIN_VARIANT for
901 argument oldtype and newtype. Instead of handling
902 just fileptr_type_node specially, handle all builtin_structptr_types
903 pointer nodes. Formatting fix.
904
d8b5a1a0
MS
9052019-01-24 Martin Sebor <msebor@redhat.com>
906
907 PR c/86125
908 PR c/88886
909 PR middle-end/86308
910 * c-decl.c (match_builtin_function_types): Add arguments.
911 (diagnose_mismatched_decls): Diagnose mismatched declarations
912 of built-ins more strictly.
913
e21c4491
JJ
9142019-01-24 Jakub Jelinek <jakub@redhat.com>
915
916 PR c++/88976
917 * c-typeck.c (c_finish_omp_cancel): Diagnose more than one if
918 on #pragma omp cancel with different modifiers.
919
420183d9
L
9202019-01-18 H.J. Lu <hongjiu.lu@intel.com>
921
922 PR c/51628
923 PR c/88664
924 * c-typeck.c (convert_for_assignment): Upate the
925 warn_for_address_or_pointer_of_packed_member call.
926
17ad43dd
TH
9272019-01-16 Tom Honermann <tom@honermann.net>
928 Jason Merrill <jason@redhat.com>
929
930 * c-typeck.c (digest_init): Revised the error message produced for
931 ill-formed cases of array initialization with a string literal.
932 (error_init): Make variadic.
933
5f07d78a
JJ
9342019-01-12 Jakub Jelinek <jakub@redhat.com>
935
936 * c-typeck.c (convert_for_assignment): Fix a comment typo.
937
c4581bbf
JJ
9382019-01-07 Jakub Jelinek <jakub@redhat.com>
939
940 PR c/88701
941 * c-decl.c (build_compound_literal): If not TREE_STATIC, only pushdecl
942 if current_function_decl is non-NULL.
943
65c5b1eb
JM
9442019-01-07 Joseph Myers <joseph@codesourcery.com>
945
946 PR c/88720
947 PR c/88726
948 * c-decl.c (pop_scope): Use TREE_PUBLIC and b->nested to determine
949 whether a function is nested, not DECL_EXTERNAL. Diagnose inline
950 functions declared but never defined only for external scope, not
951 for other scopes.
952
d8fcab68
JJ
9532019-01-07 Jakub Jelinek <jakub@redhat.com>
954
955 PR c++/85052
956 * c-parser.c (c_parser_postfix_expression): Parse
957 __builtin_convertvector.
958
a5544970
JJ
9592019-01-01 Jakub Jelinek <jakub@redhat.com>
960
961 Update copyright years.
962
da77eace
L
9632018-12-20 H.J. Lu <hongjiu.lu@intel.com>
964
965 PR c/51628
966 * c-typeck.c (convert_for_assignment): Call
967 warn_for_address_or_pointer_of_packed_member.
968
1edf8866
SB
9692018-12-19 Segher Boessenkool <segher@kernel.crashing.org>
970
971 * c-parser.c (c_parser_asm_statement) <RID_CONST, RID_RESTRICT>: Give
972 a more specific error message (instead of just falling through).
973
db4fd626
SB
9742018-12-19 Segher Boessenkool <segher@kernel.crashing.org>
975
976 * c-parser.c (c_parser_asm_statement): Keep track of the location each
977 asm qualifier is first seen; use that to give nicer "duplicate asm
978 qualifier" messages. Delete 'quals" variable, instead pass the
979 "is_volatile_ flag to build_asm_stmt directly.
980 * c-tree.h (build_asm_stmt): Make the first arg bool instead of tree.
981 * c-typeck.c (build_asm_stmt): Ditto; adjust.
982
9c9cfcbb
SB
9832018-12-19 Segher Boessenkool <segher@kernel.crashing.org>
984
985 * c-parser.c (c_parser_asm_statement): Rewrite the loop to work without
986 "done" boolean variable.
987
a14feb3c
DM
9882018-12-19 David Malcolm <dmalcolm@redhat.com>
989
990 PR c++/87504
991 * c-typeck.c (class maybe_range_label_for_tree_type_mismatch):
992 Move from here to gcc-rich-location.h and gcc-rich-location.c.
993 (build_binary_op): Use struct op_location_t and
994 class binary_op_rich_location.
995
6d939173
JJ
9962018-12-11 Jakub Jelinek <jakub@redhat.com>
997
998 PR sanitizer/88426
999 * c-convert.c (convert): Call c_fully_fold before calling
1000 ubsan_instrument_float_cast.
1001
b7055028
SB
10022018-12-08 Segher Boessenkool <segher@kernel.crashing.org>
1003
1004 * c-parser (c_parser_asm_statement) [RID_INLINE]: Delete stray line
1005 setting "quals".
1006
5b76e75f
SB
10072018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
1008
1009 * c-parser.c (c_parser_asm_statement): Detect the inline keyword
1010 after asm. Pass a flag for it to build_asm_expr.
1011 * c-tree.h (build_asm_expr): Update declaration.
1012 * c-typeck.c (build_asm_stmt): Add is_inline parameter. Use it to
1013 set ASM_INLINE_P.
1014
30bd42b9
SB
10152018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
1016
1017 PR inline-asm/55681
1018 * c-parser.c (c_parser_asm_statement): Update grammar. Allow any
1019 combination of volatile and goto, in any order, without repetitions.
1020
9df6c0e4
JB
10212018-12-04 James Norris <jnorris@codesourcery.com>
1022 Cesar Philippidis <cesar@codesourcery.com>
1023 Julian Brown <julian@codesourcery.com>
1024
1025 * c-parser.c (c_parser_oacc_wait_list): Remove dead diagnostic
1026 code.
1027
f44697b7
RB
10282018-11-30 Richard Biener <rguenther@suse.de>
1029
1030 * gimple-parser.c (c_parser_gimple_postfix_expression): Parse
1031 _Literal (type) { ... } as empty aggregate or vector constructor.
1032
550dfbdc
MS
10332018-11-29 Martin Sebor <msebor@redhat.com>
1034
1035 PR c/88091
1036 * c-typeck.c (convert_argument): Add a parameter. Adjust indentation.
1037 (convert_arguments): Add comments. Pass additional argument to
1038 the function above.
1039
673670da
MS
10402018-11-29 Martin Sebor <msebor@redhat.com>
1041
1042 PR c/88172
1043 PR testsuite/88208
1044 * c-decl.c (declspec_add_alignas): Adjust call to check_user_alignment.
1045
db1d09b0
MS
10462018-11-23 Martin Sebor <msebor@redhat.com>
1047
1048 PR testsuite/88098
1049 * c-typeck.c (convert_arguments): Call builtin_decl_explicit instead.
1050 (maybe_warn_builtin_no_proto_arg): Handle short enum to int promotion.
1051
98f08eb8
MS
10522018-11-20 Martin Sebor <msebor@redhat.com>
1053
1054 * c-parser.c (c_parser_has_attribute_expression): New function.
1055 (c_parser_attribute): New function.
1056 (c_parser_attributes): Move code into c_parser_attribute.
1057 (c_parser_unary_expression): Handle RID_HAS_ATTRIBUTE_EXPRESSION.
1058
cd5da983
MS
10592018-11-15 Martin Sebor <msebor@redhat.com>
1060
1061 PR c/83656
1062 * c-decl.c (header_for_builtin_fn): Declare.
1063 (diagnose_mismatched_decls): Diagnose declarations of built-in
1064 functions without a prototype.
1065 * c-typeck.c (maybe_warn_builtin_no_proto_arg): New function.
1066 (convert_argument): Same.
1067 (convert_arguments): Factor code out into convert_argument.
1068 Detect mismatches between built-in formal arguments in calls
1069 to built-in without prototype.
1070 (build_conditional_expr): Same.
1071 (type_or_builtin_type): New function.
1072 (convert_for_assignment): Add argument. Conditionally issue
1073 warnings instead of errors for mismatches.
1074
620e594b
DM
10752018-11-13 David Malcolm <dmalcolm@redhat.com>
1076
1077 * c-decl.c: Replace "source_location" with "location_t".
1078 * c-tree.h: Likewise.
1079 * c-typeck.c: Likewise.
1080 * gimple-parser.c: Likewise.
1081
3179ebae
JJ
10822018-11-09 Jakub Jelinek <jakub@redhat.com>
1083
81a227c6
JJ
1084 * c-parser.c (c_parser_omp_clause_final): Use
1085 c_parser_expr_no_commas, convert_lvalue_to_rvalue,
1086 c_objc_common_truthvalue_conversion, c_fully_fold and parentheses
1087 parsing instead of c_parser_paren_condition.
1088 (c_parser_omp_clause_if): Use c_parser_expr_no_commas,
1089 convert_lvalue_to_rvalue, c_objc_common_truthvalue_conversion and
1090 c_fully_fold instead of c_parser_condition.
1091 (c_parser_omp_clause_num_threads, c_parser_omp_clause_num_tasks,
1092 c_parser_omp_clause_grainsize, c_parser_omp_clause_priority,
1093 c_parser_omp_clause_hint, c_parser_omp_clause_num_teams,
1094 c_parser_omp_clause_thread_limit, c_parser_omp_clause_linear): Use
1095 c_parser_expr_no_commas instead of c_parser_expression.
1096
98c91c56
JJ
1097 * c-parser.c (c_parser_omp_clause_reduction): Call sorry_at on
1098 reduction clause with inscan modifier.
1099
3179ebae
JJ
1100 * c-parser.c (c_parser_omp_requires): Call sorry_at on requires
1101 clauses other than atomic_default_mem_order.
1102
28567c40
JJ
11032018-11-08 Jakub Jelinek <jakub@redhat.com>
1104
1105 * c-parser.c: Include memmode.h.
1106 (c_parser_omp_depobj, c_parser_omp_requires): New functions.
1107 (c_parser_pragma): Handle PRAGMA_OMP_DEPOBJ and PRAGMA_OMP_REQUIRES.
1108 (c_parser_omp_clause_name): Handle nontemporal, in_reduction and
1109 task_reduction clauses.
1110 (c_parser_omp_variable_list): Handle OMP_CLAUSE_{IN,TASK}_REDUCTION.
1111 For OMP_CLAUSE_DEPEND, parse clause operands as either an array
1112 section, or lvalue assignment expression.
1113 (c_parser_omp_clause_if): Handle cancel and simd modifiers.
1114 (c_parser_omp_clause_lastprivate): Parse optional
1115 conditional: modifier.
1116 (c_parser_omp_clause_hint): Require constant integer expression rather
1117 than just integer expression.
1118 (c_parser_omp_clause_defaultmap): Parse new kinds of defaultmap
1119 clause.
1120 (c_parser_omp_clause_reduction): Add IS_OMP and KIND arguments.
1121 Parse reduction modifiers. Pass KIND to c_parser_omp_variable_list.
1122 (c_parser_omp_clause_nontemporal, c_parser_omp_iterators): New
1123 functions.
1124 (c_parser_omp_clause_depend): Parse iterator modifier and handle
1125 iterators. Parse mutexinoutset and depobj kinds.
1126 (c_parser_oacc_all_clauses): Adjust c_parser_omp_clause_reduction
1127 callers.
1128 (c_parser_omp_all_clauses): Likewise. Handle
1129 PRAGMA_OMP_CLAUSE_NONTEMPORAL and
1130 PRAGMA_OMP_CLAUSE_{IN,TASK}_REDUCTION.
1131 (c_parser_omp_atomic): Parse hint and memory order clauses. Handle
1132 default memory order from requires directive if any. Adjust
1133 c_finish_omp_atomic caller.
1134 (c_parser_omp_critical): Allow comma in between (name) and hint clause.
1135 (c_parser_omp_flush): Parse flush with memory-order-clause.
1136 (c_parser_omp_for_loop): Allow NE_EXPR even in
1137 OpenMP loops, adjust c_finish_omp_for caller.
1138 (OMP_SIMD_CLAUSE_MASK): Add if and nontemporal clauses.
1139 (c_parser_omp_master): Add p_name, mask and cclauses arguments.
1140 Allow to be called while parsing combined parallel master.
1141 Parse combined master taskloop{, simd}.
1142 (c_parser_omp_parallel): Parse combined
1143 parallel master{, taskloop{, simd}} constructs.
1144 (OMP_TASK_CLAUSE_MASK): Add in_reduction clause.
1145 (OMP_TASKGROUP_CLAUSE_MASK): Define.
1146 (c_parser_omp_taskgroup): Add LOC argument. Parse taskgroup clauses.
1147 (OMP_TASKWAIT_CLAUSE_MASK): Define.
1148 (c_parser_omp_taskwait): Handle taskwait with depend clauses.
1149 (c_parser_omp_teams): Force a BIND_EXPR with BLOCK
1150 around teams body. Use SET_EXPR_LOCATION.
1151 (c_parser_omp_target_data): Allow target data
1152 with only use_device_ptr clauses.
1153 (c_parser_omp_target): Use SET_EXPR_LOCATION. Set
1154 OMP_REQUIRES_TARGET_USED bit in omp_requires_mask.
1155 (c_parser_omp_requires): New function.
1156 (c_finish_taskloop_clauses): New function.
1157 (OMP_TASKLOOP_CLAUSE_MASK): Add reduction and in_reduction clauses.
1158 (c_parser_omp_taskloop): Use c_finish_taskloop_clauses. Add forward
1159 declaration. Disallow in_reduction clause when combined with parallel
1160 master.
1161 (c_parser_omp_construct): Adjust c_parser_omp_master and
1162 c_parser_omp_taskgroup callers.
1163 * c-typeck.c (c_finish_omp_cancel): Diagnose if clause with modifier
1164 other than cancel.
1165 (handle_omp_array_sections_1): Handle OMP_CLAUSE_{IN,TASK}_REDUCTION
1166 like OMP_CLAUSE_REDUCTION.
1167 (handle_omp_array_sections): Likewise. Call save_expr on array
1168 reductions before calling build_index_type. Handle depend clauses
1169 with iterators.
1170 (struct c_find_omp_var_s): New type.
1171 (c_find_omp_var_r, c_omp_finish_iterators): New functions.
1172 (c_finish_omp_clauses): Don't diagnose nonmonotonic clause
1173 with static, runtime or auto schedule kinds. Call save_expr for whole
1174 array reduction sizes. Diagnose reductions with zero sized elements
1175 or variable length structures. Diagnose nogroup clause used with
1176 reduction clause(s). Handle depend clause with
1177 OMP_CLAUSE_DEPEND_DEPOBJ. Diagnose bit-fields. Require
1178 omp_depend_t type for OMP_CLAUSE_DEPEND_DEPOBJ kinds and
1179 some different type for other kinds. Use build_unary_op with
1180 ADDR_EXPR and build_indirect_ref instead of c_mark_addressable.
1181 Handle depend clauses with iterators. Remove no longer needed special
1182 case that predetermined const qualified vars may be specified in
1183 firstprivate clause. Complain if const qualified vars are mentioned
1184 in data-sharing clauses other than firstprivate or shared. Use
1185 error_at with OMP_CLAUSE_LOCATION (c) as first argument instead of
1186 error. Formatting fix. Handle OMP_CLAUSE_NONTEMPORAL and
1187 OMP_CLAUSE_{IN,TASK}_REDUCTION. Allow any lvalue as
1188 OMP_CLAUSE_DEPEND operand (besides array section), adjust diagnostics.
1189
7e2de6df
DM
11902018-10-29 David Malcolm <dmalcolm@redhat.com>
1191
1192 * c-decl.c (implicit_decl_warning): Update "is there a suggestion"
1193 logic for change to name_hint::operator bool.
1194 (undeclared_variable): Likewise.
1195 * c-parser.c (c_parser_declaration_or_fndef): Likewise.
1196 (c_parser_parameter_declaration): Likewise.
1197
9f936c86
JM
11982018-10-17 Joseph Myers <joseph@codesourcery.com>
1199
1200 * c-errors.c (pedwarn_c11): New function.
1201 * c-parser.c (disable_extension_diagnostics): Save
1202 warn_c11_c2x_compat and set it to 0.
1203 (restore_extension_diagnostics): Restore warn_c11_c2x_compat.
1204 (c_parser_static_assert_declaration_no_semi): Handle
1205 _Static_assert without string constant.
1206 * c-tree.h (pedwarn_c11): New prototype.
1207
033eb567
DM
12082018-10-17 David Malcolm <dmalcolm@redhat.com>
1209
1210 * Make-lang.in (selftest-c): New.
1211 (C_SELFTEST_FLAGS, C_SELFTEST_DEPS, s-selftest-c, selftest-c-gdb)
1212 (selftest-gdb, selftest-c-valgrind, selftest-valgrind): Move here
1213 from gcc/Makefile.in.
1214
0edf3afe
RB
12152018-10-02 Richard Biener <rguenther@suse.de>
1216
1217 * c-decl.c (warn_if_shadowing): Do not test DECL_FROM_INLINE.
1218
8313a764
JM
12192018-09-26 Joseph Myers <joseph@codesourcery.com>
1220
1221 PR c/87390
1222 * c-typeck.c (build_binary_op): Use excess precision for
1223 comparisons of integers and floating-point for C11 and later.
1224
ce6f0888
MJ
12252018-09-26 Martin Jambor <mjambor@suse.cz>
1226
1227 PR c/87347
1228 * c-parser.c (warn_for_abs): Bail out if TYPE_ARG_TYPES is NULL. Fix
ab20d992 1229 comment.
ce6f0888 1230
9c4a4b3c
DM
12312018-09-17 David Malcolm <dmalcolm@redhat.com>
1232
1233 * c-objc-common.c (range_label_for_type_mismatch::get_text):
1234 Update for new param.
1235 * c-typeck.c (maybe_range_label_for_tree_type_mismatch::get_text):
1236 Likewise.
1237
80c6d1f4
MJ
12382018-09-17 Martin Jambor <mjambor@suse.cz>
1239
1240 PR c/63886
1241 * c-parser.c: (warn_for_abs): New function.
1242 (c_parser_postfix_expression_after_primary): Call it.
1243
4a426e36
BE
12442018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
1245
1246 * c-typeck.c (digest_init): Shorten overlength strings.
1247
6d900107
BE
12482018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
1249
1250 * c-decl.c (finish_decl): Call complete_flexible_array_elts.
1251
b5764229
BE
12522018-09-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
1253
1254 * c-decl.c (finish_decl): Call braced_list_to_string here ...
1255 * c-parser.c (c_parser_declaration_or_fndef): ... instead of here.
1256
22eea6b2
AM
12572018-08-30 Alexander Monakov <amonakov@ispras.ru>
1258
1259 * gimple-parser.c (c_parser_gimple_binary_expression): Accept infix
1260 "__MULT_HIGHPART" for MULT_HIGHPART_EXPR.
1261
85204e23
DM
12622018-08-27 David Malcolm <dmalcolm@redhat.com>
1263
1264 PR 87091
1265 * c-decl.c (implicitly_declare): Update call to
1266 maybe_add_include_fixit to suggest overriding the location, as it
1267 is for a note.
1268 * c-objc-common.c (c_tree_printer): Update for conversion of
1269 show_caret_p to a tri-state.
1270
3d78e008
ML
12712018-08-27 Martin Liska <mliska@suse.cz>
1272
1273 * c-decl.c (locate_old_decl): Use new function
92a285c1
ML
1274 fndecl_built_in_p and remove check for FUNCTION_DECL if
1275 possible.
3d78e008
ML
1276 (diagnose_mismatched_decls): Likewise.
1277 (merge_decls): Likewise.
1278 (warn_if_shadowing): Likewise.
1279 (pushdecl): Likewise.
1280 (implicitly_declare): Likewise.
1281 * c-parser.c (c_parser_postfix_expression_after_primary): Likewise.
1282 * c-tree.h (C_DECL_ISNT_PROTOTYPE): Likewise.
1283 * c-typeck.c (build_function_call_vec): Likewise.
1284 (convert_arguments): Likewise.
1285
097f82ec
DM
12862018-08-20 David Malcolm <dmalcolm@redhat.com>
1287
1288 PR other/84889
1289 * c-decl.c (pushtag): Add auto_diagnostic_group instance.
1290 (diagnose_mismatched_decls): Likewise, in various places.
1291 (warn_if_shadowing): Likewise.
1292 (implicit_decl_warning): Likewise.
1293 (implicitly_declare): Likewise.
1294 (undeclared_variable): Likewise.
1295 (declare_label): Likewise.
1296 (grokdeclarator): Likewise.
1297 (start_function): Likewise.
1298 * c-parser.c (c_parser_declaration_or_fndef): Likewise.
1299 (c_parser_parameter_declaration): Likewise.
1300 (c_parser_binary_expression): Likewise.
1301 * c-typeck.c (c_expr_sizeof_expr): Likewise.
1302 (parser_build_binary_op): Likewise.
1303 (build_unary_op): Likewise.
1304 (error_init): Likewise.
1305 (pedwarn_init): Likewise.
1306 (warning_init): Likewise.
1307 (convert_for_assignment): Likewise.
1308
96e6ae57
DM
13092018-08-15 David Malcolm <dmalcolm@redhat.com>
1310
1311 * c-objc-common.c: Include "gcc-rich-location.h".
1312 (c_tree_printer): Move implemenation of '%T' to...
1313 (print_type): ...this new function.
1314 (range_label_for_type_mismatch::get_text): New function.
1315 * c-typeck.c (convert_for_assignment): Add type labels to the rhs
1316 range for the various ic_argpass cases.
1317 (class maybe_range_label_for_tree_type_mismatch): New class.
1318 (build_binary_op): Use it when calling binary_op_error.
1319
0cd020ae 13202018-08-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
ab20d992 1321
0cd020ae
PK
1322 * c-decl.c (start_decl): Do not warn if variables is named as main
1323 and is a local variable.
1324
72733314
IS
13252018-08-15 Iain Sandoe <iain@sandoe.co.uk>
1326
1327 PR c/19315
1328 * c-decl.c (finish_decl): Don't add the 'extern' storage class to
1329 objects of unknown size.
1330
23aa9f7c
MS
13312018-08-13 Martin Sebor <msebor@redhat.com>
1332
1333 PR tree-optimization/71625
1334 * c-parser.c (c_parser_declaration_or_fndef): Call
1335 braced_list_to_string.
1336
e5e7e50d
BH
13372018-08-03 Bogdan Harjoc <harjoc@gmail.com>
1338
1339 PR c/86690
1340 * c-typeck.c (lookup_field): Do not use TYPE_LANG_SPECIFIC after
1341 errors.
1342
8a45b051
MS
13432018-08-01 Martin Sebor <msebor@redhat.com>
1344
1345 PR tree-optimization/86650
1346 * c-objc-common.c (c_tree_printer): Move usage of EXPR_LOCATION (t)
1347 and TREE_BLOCK (t) from within percent_K_format to this callsite.
1348
5922dcb5
JJ
13492018-08-01 Jakub Jelinek <jakub@redhat.com>
1350
1351 PR c/85704
1352 * c-typeck.c (init_field_decl_cmp): New function.
1353 (output_pending_init_elements): Use it for field comparisons
1354 instead of pure bit_position comparisons.
1355
9b452033
JJ
13562018-07-12 Jakub Jelinek <jakub@redhat.com>
1357
1358 * c-decl.c (c_decl_attributes): Don't diagnose vars without mappable
1359 type here, instead add "omp declare target implicit" attribute.
1360 (finish_decl): Diagnose vars without mappable type here.
1361
ab20d992
JJ
13622018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
1363 Thomas Schwinge <thomas@codesourcery.com>
829c6349
CLT
1364 Cesar Philippidis <cesar@codesourcery.com>
1365
1366 * c-parser.c (c_parser_omp_clause_name): Add support for finalize
1367 and if_present. Make present_or_{copy,copyin,copyout,create} aliases
1368 to their non-present_or_* counterparts. Make 'self' an alias to
1369 PRAGMA_OACC_CLAUSE_HOST.
1370 (c_parser_oacc_data_clause): Update GOMP mappings for
1371 PRAGMA_OACC_CLAUSE_{COPY,COPYIN,COPYOUT,CREATE,DELETE}. Remove
1372 PRAGMA_OACC_CLAUSE_{SELF,PRESENT_OR_*}.
1373 (c_parser_oacc_all_clauses): Handle finalize and if_present clauses.
1374 Remove support for present_or_* clauses.
1375 (OACC_KERNELS_CLAUSE_MASK): Remove PRESENT_OR_* clauses.
1376 (OACC_PARALLEL_CLAUSE_MASK): Likewise.
1377 (OACC_DECLARE_CLAUSE_MASK): Likewise.
1378 (OACC_DATA_CLAUSE_MASK): Likewise.
1379 (OACC_ENTER_DATA_CLAUSE_MASK): Remove PRESENT_OR_* clauses.
1380 (OACC_EXIT_DATA_CLAUSE_MASK): Add FINALIZE clause.
1381 (OACC_UPDATE_CLAUSE_MASK): Remove SELF, add IF_PRESENT.
1382 (c_parser_oacc_declare): Remove PRESENT_OR_* clauses.
1383 * c-typeck.c (c_finish_omp_clauses): Handle IF_PRESENT and FINALIZE.
1384
e197e64e
KV
13852018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
1386
1387 * c-typeck.c (build_unary_op): Handle ABSU_EXPR;
1388 * gimple-parser.c (c_parser_gimple_statement): Likewise.
1389 (c_parser_gimple_unary_expression): Likewise.
1390
487f2f61
JJ
13912018-06-15 Jakub Jelinek <jakub@redhat.com>
1392
1393 PR c/86093
1394 * c-typeck.c (pointer_diff): Cast both pointers to unqualified types
1395 before doing POINTER_DIFF_EXPR.
1396
e4d44a37
MP
13972018-06-07 Marek Polacek <polacek@redhat.com>
1398
1399 PR c/85318
1400 * c-decl.c (check_for_loop_decls): Add -Wc90-c99-compat warning about
1401 for loop initial declarations.
1402
b67b9225
DP
14032018-05-30 David Pagan <dave.pagan@oracle.com>
1404
1405 PR c/55976
1406 * c-decl.c (grokdeclarator): Update check for return type warnings.
1407 (start_function): Likewise.
1408 (finish_function): Likewise.
1409 * c-typeck.c (c_finish_return): Update check for return type warnings.
1410 Pass OPT_Wreturn_type to pedwarn when appropriate.
1411
c566cc9f
RS
14122018-05-18 Richard Sandiford <richard.sandiford@linaro.org>
1413
1414 * gimple-parser.c (c_parser_gimple_postfix_expression): Remove
1415 __FMA_EXPR handlng.
1416
e4f81565
RS
14172018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
1418
1419 * gimple-parser.c: Include internal-fn.h.
1420 (c_parser_gimple_statement): Treat a leading CPP_DOT as a call.
1421 (c_parser_gimple_call_internal): New function.
1422 (c_parser_gimple_postfix_expression): Use it to handle CPP_DOT.
1423 Fix typos in comment.
1424
79e7b1fe
JJ
14252018-05-10 Jakub Jelinek <jakub@redhat.com>
1426
1427 PR c++/85662
1428 * c-fold.c (c_fully_fold_internal): Use fold_offsetof rather than
1429 fold_offsetof_1, pass TREE_TYPE (expr) as TYPE to it and drop the
1430 fold_convert_loc.
1431 * c-typeck.c (build_unary_op): Use fold_offsetof rather than
1432 fold_offsetof_1, pass argtype as TYPE to it and drop the
1433 fold_convert_loc.
1434
f7584c81
DP
14352018-05-02 David Pagan <dave.pagan@oracle.com>
1436
1437 PR c/30552
1438 * c-decl.c (old_style_parameter_scope): New function.
1439 * c-parser.c (c_parser_postfix_expression): Check for statement
1440 expressions in old-style function parameter list declarations.
1441 * c-parser.h (old_style_parameter_scope): New extern declaration.
1442
b33a0cb3
JJ
14432018-04-25 Jakub Jelinek <jakub@redhat.com>
1444
1445 PR sanitizer/84307
1446 * c-decl.c (build_compound_literal): Call pushdecl (decl) even when
1447 it is not TREE_STATIC.
1448 * c-typeck.c (c_mark_addressable) <case COMPOUND_LITERAL_EXPR>: Mark
1449 not just the COMPOUND_LITERAL_EXPR node itself addressable, but also
1450 its COMPOUND_LITERAL_EXPR_DECL.
1451
c5c5822a
JM
14522018-03-21 Joseph Myers <joseph@codesourcery.com>
1453
1454 * c-parser.c (c_parser_postfix_expression): For __builtin_tgmath
1455 where all functions return the same _FloatN or _FloatNx type,
1456 treat integer types as _Float64 instead of double.
1457
aa1c9429
JJ
14582018-03-21 Jakub Jelinek <jakub@redhat.com>
1459
1460 PR c/84999
1461 * c-typeck.c (build_binary_op): If c_common_type_for_size fails when
1462 building vector comparison, diagnose it and return error_mark_node.
1463
9bb45a95
JJ
14642018-03-15 Jakub Jelinek <jakub@redhat.com>
1465
1466 PR c/84853
1467 * c-typeck.c (build_binary_op) <case RSHIFT_EXPR, case LSHIFT_EXPR>:
1468 If code1 is INTEGER_TYPE, only allow code0 VECTOR_TYPE if it has
1469 INTEGER_TYPE element type.
1470
ada6bad9
DP
14712018-03-13 David Pagan <dave.pagan@oracle.com>
1472
1473 PR c/46921
1474 * c-typeck.c (output_init_element): Ensure field initializer
1475 expression is always evaluated if there are side effects.
1476
849bbdb9
JJ
14772018-03-06 Jakub Jelinek <jakub@redhat.com>
1478
1479 PR c/84721
1480 * c-parser.c (add_debug_begin_stmt): Don't add DEBUG_BEGIN_STMT if
1481 !building_stmt_list_p ().
1482
d74641bd
RS
14832018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
1484
1485 PR c/84305
1486 * c-decl.c (grokdeclarator): Create an anonymous TYPE_DECL
1487 in PARM and TYPENAME contexts too, but attach it to a BIND_EXPR
1488 and include the BIND_EXPR in the list of things that need to be
1489 pre-evaluated.
1490
0444aa9c
NS
14912018-02-09 Nathan Sidwell <nathan@acm.org>
1492
1493 PR c/84293
1494 * c-typeck.c (build_indirect_ref, build_c_cast): Pass expr location
1495 to strict_aliasing_warning.
1496
7c30b12a
PC
14972018-02-02 Paolo Carlini <paolo.carlini@oracle.com>
1498
1499 * c-typeck.c (really_start_incremental_init, push_init_level,
1500 set_nonincremental_init, output_init_element, process_init_element):
1501 Use DECL_UNNAMED_BIT_FIELD.
1502
2be4dfcb
MP
15032018-01-31 Marek Polacek <polacek@redhat.com>
1504
1505 PR c/81779
1506 * c-parser.c (c_parser_compound_statement_nostart): Call
1507 expansion_point_location_if_in_system_header.
1508
bb9869d5
DM
15092018-01-17 David Malcolm <dmalcolm@redhat.com>
1510
1511 PR c++/83814
1512 * c-fold.c (fold_for_warn): Move from c-common.c, reducing to just
1513 the C part.
1514
b4923738
JJ
15152018-01-13 Jakub Jelinek <jakub@redhat.com>
1516
1517 PR c/83801
1518 * c-tree.h (decl_constant_value_1): Add a bool argument.
1519 * c-typeck.c (decl_constant_value_1): Add IN_INIT argument, allow
1520 returning a CONSTRUCTOR if it is true. Use error_operand_p.
1521 (decl_constant_value): Adjust caller.
1522 * c-fold.c (c_fully_fold_internal): If in_init, pass true to
1523 decl_constant_value_1 as IN_INIT. Otherwise, punt if
1524 decl_constant_value returns initializer that has BLKmode or
1525 array type.
1526 (c_fully_fold_internal) <case COMPONENT_REF>: Fold if !lval.
1527
928686b1
RS
15282018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
1529 Alan Hayward <alan.hayward@arm.com>
1530 David Sherwood <david.sherwood@arm.com>
1531
1532 * c-typeck.c (comptypes_internal, build_binary_op): Handle polynomial
1533 TYPE_VECTOR_SUBPARTS.
1534
85ec4feb
JJ
15352018-01-03 Jakub Jelinek <jakub@redhat.com>
1536
1537 Update copyright years.
1538
913884f7
JJ
15392018-01-01 Jakub Jelinek <jakub@redhat.com>
1540
1541 PR c/83595
1542 * c-parser.c (c_parser_braced_init, c_parser_initelt,
1543 c_parser_conditional_expression, c_parser_cast_expression,
1544 c_parser_sizeof_expression, c_parser_alignof_expression,
1545 c_parser_postfix_expression, c_parser_omp_declare_reduction,
1546 c_parser_transaction_expression): Use set_error () method instead
1547 of setting value member to error_mark_node.
1548
c6cfa2bf
MM
15492017-12-28 Michael Meissner <meissner@linux.vnet.ibm.com>
1550
1551 * c-decl.c (header_for_builtin_fn): Add integer rounding _Float<N>
1552 and _Float<N>X built-in functions.
1553
11d29d63
JJ
15542017-12-22 Jakub Jelinek <jakub@redhat.com>
1555
14ec014e
JJ
1556 PR debug/83550
1557 * c-decl.c (finish_struct): Set DECL_SOURCE_LOCATION on
1558 TYPE_STUB_DECL and call rest_of_type_compilation before processing
1559 incomplete vars rather than after it.
1560
11d29d63
JJ
1561 PR debug/83547
1562 * c-typeck.c (c_finish_stmt_expr): Ignore !TREE_SIDE_EFFECTS as
1563 indicator of ({ }), instead skip all trailing DEBUG_BEGIN_STMTs first,
1564 and consider empty ones if there are no other stmts. For
1565 -Wunused-value walk all statements before the one only followed by
1566 DEBUG_BEGIN_STMTs.
1567
170a8bd6 15682017-12-22 Mike Stump <mikestump@comcast.net>
92a285c1 1569 Eric Botcazou <ebotcazou@adacore.com>
170a8bd6
EB
1570
1571 * c-parser.c (c_parser_while_statement): Add unroll parameter and
1572 build ANNOTATE_EXPR if present. Add 3rd operand to ANNOTATE_EXPR.
1573 (c_parser_do_statement): Likewise.
1574 (c_parser_for_statement): Likewise.
1575 (c_parser_statement_after_labels): Adjust calls to above.
1576 (c_parse_pragma_ivdep): New static function.
1577 (c_parser_pragma_unroll): Likewise.
1578 (c_parser_pragma) <PRAGMA_IVDEP>: Add support for pragma Unroll.
1579 <PRAGMA_UNROLL>: New case.
1580
01512446
JJ
15812017-12-19 Jakub Jelinek <jakub@redhat.com>
1582
1583 * c-typeck.c (comptypes_internal, function_types_compatible_p,
1584 perform_integral_promotions, digest_init): Replace Yoda conditions
1585 with typical order conditions.
1586 * c-decl.c (check_bitfield_type_and_width): Likewise.
1587
c65e18d3
BE
15882017-12-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
1589
1590 * c-typeck.c (c_safe_arg_type_equiv_p,
1591 c_safe_function_type_cast_p): New function.
1592 (build_c_cast): Implement -Wcast-function-type.
1593
b7280579
RB
15942017-12-14 Richard Biener <rguenther@suse.de>
1595
1596 PR c/83415
1597 * c-fold.c (c_fully_fold_internal): Treat VIEW_CONVERT_EXPR
1598 like REALPART_EXPR for the behavior of whether its operand
1599 is an lvalue.
1600
49e6a6c0
MP
16012017-12-12 Marek Polacek <polacek@redhat.com>
1602
1603 PR c/82679
1604 * c-decl.c (grokdeclarator): Check declspecs insted of atomicp.
1605
ab20d992 16062017-12-12 Alexandre Oliva <aoliva@redhat.com>
96a95ac1
AO
1607
1608 * c-objc-common.h (LANG_HOOKS_EMITS_BEGIN_STMT): Redefine as true.
1609 * c-parser.c (add_debug_begin_stmt): New.
1610 (c_parser_declaration_or_fndef): Call it.
1611 (c_parser_compound_statement_nostart): Likewise.
1612 (c_parser_statement_after_labels): Likewise.
1613 * c-typeck (c_finish_stmt_expr): Skip begin stmts markers.
1614
4b2b493f
JM
16152017-12-07 Joseph Myers <joseph@codesourcery.com>
1616
1617 * c-decl.c (build_compound_literal): Add parameter alignas_align
1618 and set alignment of decl if nonzero.
1619 * c-parser.c (c_keyword_starts_typename): Allow RID_ALIGNAS.
1620 (c_parser_declspecs): Allow RID_ALIGNAS to follow a type, like a
1621 qualifier.
1622 (c_parser_struct_declaration): Update syntax comment.
1623 (c_parser_type_name): Add alignas_ok argument and pass it to
1624 c_parser_declspecs.
1625 (c_parser_cast_expression): Pass true to c_parser_type_name and
1626 give error if a cast used an _Alignas specifier.
1627 (c_parser_sizeof_expression): Pass true to c_parser_type_name and
1628 give error if sizeof (type-name) used an _Alignas specifier.
1629 (c_parser_alignof_expression): Pass true to c_parser_type_name and
1630 give error if _Alignof (type-name) used an _Alignas specifier.
1631 (c_parser_postfix_expression_after_paren_type): Check specified
1632 alignment for a compound literal and pass it to
1633 build_compound_literal.
1634 * c-parser.h (c_parser_type_name): Update prototype.
1635 * c-tree.h (build_compound_literal): Update prototype.
1636
5d9ae53d
MS
16372017-12-07 Martin Sebor <msebor@redhat.com>
1638
1639 PR c/81544
1640 * c-decl.c (c_decl_attributes): Look up existing declaration and
1641 pass it to decl_attributes.
1642
c79144f8
DM
16432017-12-06 David Malcolm <dmalcolm@redhat.com>
1644
1645 PR c/83236
1646 * c-decl.c (lookup_name_fuzzy): Don't suggest names that are
1647 reserved for use by the implementation.
1648
613bc14f
DM
16492017-12-06 David Malcolm <dmalcolm@redhat.com>
1650
1651 * c-decl.c: Include "c-family/c-spellcheck.h".
1652
05abad4c
ML
16532017-12-05 Martin Liska <mliska@suse.cz>
1654 Jakub Jelinek <jakub@redhat.com>
1655
1656 * c-typeck.c (pointer_diff): Add new argument and instrument
1657 pointer subtraction.
1658 (build_binary_op): Similar for pointer comparison.
1659
cc6534d4
JJ
16602017-12-01 Jakub Jelinek <jakub@redhat.com>
1661
65791f42
JJ
1662 PR c/79153
1663 * c-parser.c: Include tree-iterator.h.
1664 (c_parser_switch_statement): Emit LABEL_EXPR for the break label
1665 into SWITCH_BODY instead of after it and set SWITCH_BREAK_LABEL_P
1666 on it.
1667
cc6534d4
JJ
1668 PR c/83222
1669 * c-tree.h (decl_constant_value_1): Declare.
1670 * c-typeck.c (decl_constant_value_1): New function.
1671 (decl_constant_value): Use it.
1672 * c-fold.c (c_fully_fold_internal): If in_init, use
1673 decl_constant_value_1 instead of decl_constant_value.
1674
5de73c05
JJ
16752017-11-30 Jakub Jelinek <jakub@redhat.com>
1676
1677 * c-parser.c (c_parser_postfix_expression): Use ; instead of ;;.
1678
058f0b9e
JJ
16792017-11-28 Jakub Jelinek <jakub@redhat.com>
1680
1681 PR sanitizer/81275
1682 * c-typeck.c (c_finish_case): Set SWITCH_ALL_CASES_P if
1683 c_switch_covers_all_cases_p returns true.
1684
5e9d6aa4 16852017-11-28 Julia Koval <julia.koval@intel.com>
92a285c1 1686 Sebastian Peryt <sebastian.peryt@intel.com>
5e9d6aa4
JK
1687
1688 * Make-lang.in (c/c-array-notation.o): Remove.
1689 * c-array-notation.c: Delete.
1690 * c-decl.c: Remove cilkplus condition.
1691 * c-parser.c (c_parser_cilk_simd, c_parser_cilk_for,
1692 c_parser_cilk_verify_simd, c_parser_array_notation,
1693 c_parser_cilk_clause_vectorlength, c_parser_cilk_grainsize,
1694 c_parser_cilk_simd_fn_vector_attrs,
1695 c_finish_cilk_simd_fn_tokens): Delete.
1696 (c_parser_declaration_or_fndef): Remove cilkplus condition.
1697 (c_parser_direct_declarator_inner): Ditto.
1698 (CILK_SIMD_FN_CLAUSE_MASK): Delete.
1699 (c_parser_attributes, c_parser_compound_statement,
1700 c_parser_statement_after_labels, c_parser_if_statement,
1701 c_parser_switch_statement, c_parser_while_statement,
1702 c_parser_do_statement, c_parser_for_statement,
1703 c_parser_unary_expression, c_parser_postfix_expression,
1704 c_parser_postfix_expression_after_primary,
1705 c_parser_pragma, c_parser_omp_clause_name, c_parser_omp_all_clauses,
1706 c_parser_omp_for_loop, c_finish_omp_declare_simd): Remove cilkplus
1707 support.
1708 * c-typeck.c (build_array_ref, build_function_call_vec,
1709 convert_arguments,
1710 lvalue_p, build_compound_expr, c_finish_return, c_finish_if_stmt,
1711 c_finish_loop, build_binary_op): Remove cilkplus support.
1712
9e851845
JJ
17132017-11-28 Jakub Jelinek <jakub@redhat.com>
1714
1715 * c-typeck.c (c_start_case): Build SWITCH_EXPR using build2 instead
1716 of build3.
1717
ab20d992 17182017-11-14 Boris Kolpackov <boris@codesynthesis.com>
8c7dbea9
BK
1719
1720 * Make-lang.in (c.install-plugin): Install backend import library.
1721
41521dee
JJ
17222017-11-23 Jakub Jelinek <jakub@redhat.com>
1723
1724 * c-parser.c (c_parser_omp_declare_simd): Reject declare simd in
1725 pragma_stmt context.
1726
ac9effed
EB
17272017-11-23 Mike Stump <mikestump@comcast.net>
1728 Eric Botcazou <ebotcazou@adacore.com>
1729
1730 * c-parser.c (c_parser_while_statement): Pass 3rd operand to
1731 ANNOTATE_EXPR.
1732 (c_parser_do_statement): Likewise.
1733 (c_parser_for_statement): Likewise.
1734
ce95abc4
DM
17352017-11-22 David Malcolm <dmalcolm@redhat.com>
1736
1737 PR c++/62170
1738 * c-objc-common.c (c_tree_printer): Convert penultimate param from
1739 bool to bool *. Within '%T' handling, if showing an "aka", use
1740 "quoted" param to add appropriate quoting.
1741
974aedcc
MP
17422017-11-22 Marek Polacek <polacek@redhat.com>
1743
1744 PR c++/60336
1745 PR middle-end/67239
1746 PR target/68355
1747 * c-decl.c (grokdeclarator): Set DECL_PADDING_P on unnamed bit-fields.
1748
d4300cc6
DM
17492017-11-21 David Malcolm <dmalcolm@redhat.com>
1750
1751 PR c/83056
1752 * c-decl.c (lookup_name_fuzzy): Don't suggest names that came from
1753 earlier failed lookups.
1754
1af4ebf5
MG
17552017-11-21 Marc Glisse <marc.glisse@inria.fr>
1756
1757 * c-fold.c (c_fully_fold_internal): Handle POINTER_DIFF_EXPR.
1758 * c-typeck.c (pointer_diff): Use POINTER_DIFF_EXPR.
1759
26edace6
DM
17602017-11-20 David Malcolm <dmalcolm@redhat.com>
1761
1762 PR c/81404
1763 * c-decl.c: Include "c-family/known-headers.h".
1764 (get_c_name_hint): Rename to get_stdlib_header_for_name and move
1765 to known-headers.cc.
1766 (class suggest_missing_header): Move to known-header.h.
1767 (lookup_name_fuzzy): Call get_c_stdlib_header_for_name rather
1768 than get_c_name_hint.
1769
b1212255
DM
17702017-11-20 David Malcolm <dmalcolm@redhat.com>
1771
1772 * c-decl.c (get_c_name_hint): New function.
1773 (class suggest_missing_header): New class.
1774 (lookup_name_fuzzy): Call get_c_name_hint and use it to
1775 suggest missing headers to the user.
1776
6c7a259b
DM
17772017-11-20 David Malcolm <dmalcolm@redhat.com>
1778
1779 * c-decl.c: Define INCLUDE_UNIQUE_PTR before including system.h.
1780 Include "c-family/name-hint.h"
1781 (implicit_decl_warning): Convert "hint" from
1782 const char * to name_hint. Pass location to
1783 lookup_name_fuzzy. Suppress any deferred diagnostic if the
1784 warning was not printed.
1785 (undeclared_variable): Likewise for "guessed_id".
1786 (lookup_name_fuzzy): Convert return type from const char *
1787 to name_hint. Add location_t param.
1788 * c-parser.c: Define INCLUDE_UNIQUE_PTR before including system.h.
1789 Include "c-family/name-hint.h"
1790 (c_parser_declaration_or_fndef): Convert "hint" from
1791 const char * to name_hint. Pass location to lookup_name_fuzzy.
1792 (c_parser_parameter_declaration): Likewise.
1793
f9c59f7e
JJ
17942017-11-19 Jakub Jelinek <jakub@redhat.com>
1795
1796 PR c/66618
1797 PR c/69960
1798 * c-parser.c (c_parser_omp_atomic): Pass true as LVAL to c_fully_fold
1799 where needed.
1800 * c-typeck.c (build_unary_op, build_modify_expr, build_asm_expr,
1801 handle_omp_array_sections): Likewise.
1802 (digest_init): Don't call decl_constant_value_for_optimization.
1803 * c-tree.h (decl_constant_value_for_optimization): Removed.
1804 * c-fold.c (c_fold_array_ref): New function.
1805 (c_fully_fold_internal): Add LVAL argument, propagate it through
1806 recursive calls. For VAR_P call decl_constant_value and
1807 unshare if not LVAL and either optimizing or IN_INIT. Remove
1808 decl_constant_value_for_optimization calls. If IN_INIT and not LVAL,
1809 fold ARRAY_REF with STRING_CST and INTEGER_CST operands.
1810 (c_fully_fold): Add LVAL argument, pass it through to
1811 c_fully_fold_internal.
1812 (decl_constant_value_for_optimization): Removed.
1813
3ca0dc60
JM
18142017-11-15 Joseph Myers <joseph@codesourcery.com>
1815
1816 PR c/81156
1817 * c-parser.c (check_tgmath_function): New function.
1818 (enum tgmath_parm_kind): New enum.
1819 (c_parser_postfix_expression): Handle __builtin_tgmath.
1820
64a5912c
DM
18212017-10-31 David Malcolm <dmalcolm@redhat.com>
1822
1823 * c-decl.c (implicit_decl_warning): Update for renaming of
1824 pedwarn_at_rich_loc and warning_at_rich_loc.
1825 (implicitly_declare): Likewise for renaming of inform_at_rich_loc.
1826 (undeclared_variable): Likewise for renaming of error_at_rich_loc.
1827 * c-parser.c (c_parser_declaration_or_fndef): Likewise.
1828 (c_parser_struct_or_union_specifier): Likewise for renaming of
1829 pedwarn_at_rich_loc.
1830 (c_parser_parameter_declaration): Likewise for renaming of
1831 error_at_rich_loc.
1832 * c-typeck.c (build_component_ref): Likewise.
1833 (build_unary_op): Likewise for renaming of inform_at_rich_loc.
1834 (pop_init_level): Likewise for renaming of warning_at_rich_loc.
1835 (set_init_label): Likewise for renaming of error_at_rich_loc.
1836
c1136864
RB
18372017-10-30 Richard Biener <rguenther@suse.de>
1838
1839 * gimple-parser.c (c_parser_gimple_statement): Parse conditional
1840 stmts.
1841
ee5fd23a
MM
18422017-10-27 Michael Meissner <meissner@linux.vnet.ibm.com>
1843
1844 * c-decl.c (header_for_builtin_fn): Add support for copysign, fma,
1845 fmax, fmin, and sqrt _Float<N> and _Float<N>X variants.
1846
1a59ccf2
DM
18472017-10-25 David Malcolm <dmalcolm@redhat.com>
1848
1849 PR c/7356
1850 * c-parser.c (c_parser_declaration_or_fndef): Detect missing
1851 semicolons.
1852
bc1a75dd
JJ
18532017-10-25 Jakub Jelinek <jakub@redhat.com>
1854
1855 PR libstdc++/81706
1856 * c-decl.c (merge_decls): Copy "omp declare simd" attributes from
1857 newdecl to corresponding __builtin_ if any.
1858
ff1ff960
PC
18592017-10-24 Paolo Carlini <paolo.carlini@oracle.com>
1860
1861 PR c++/82466
1862 * c-decl.c (diagnose_mismatched_decls): Use
1863 OPT_Wbuiltin_declaration_mismatch.
1864
62e1c678
DM
18652017-10-12 David Malcolm <dmalcolm@redhat.com>
1866
1867 * c-parser.c (c_parser_require): Add "type_is_unique" param and
1868 use it to guard calls to maybe_suggest_missing_token_insertion.
1869 (c_parser_parms_list_declarator): Override default value of new
1870 "type_is_unique" param to c_parser_require.
1871 (c_parser_asm_statement): Likewise.
1872 * c-parser.h (c_parser_require): Add "type_is_unique" param,
1873 defaulting to true.
1874
a92f6726
NS
18752017-10-11 Nathan Sidwell <nathan@acm.org>
1876
1877 * c-decl.c (grokdeclarator): Check HAS_DECL_ASSEMBLER_NAME_P too.
1878
8e6cdc90
RS
18792017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
1880
1881 * c-parser.c (c_parser_cilk_clause_vectorlength): Use wi::to_wide when
1882 operating on trees as wide_ints.
1883 * c-typeck.c (build_c_cast, c_finish_omp_clauses): Likewise.
1884 (c_tree_equal): Likewise.
1885
8139a48e
DM
18862017-10-04 David Malcolm <dmalcolm@redhat.com>
1887
1888 * c-decl.c (push_parm_decl): Store c_parm's location into the
1889 PARAM_DECL.
1890 (build_c_parm): Add "loc" param and store it within the c_parm.
1891 * c-parser.c (struct c_parser): Add "last_token_location" field.
1892 (c_parser_consume_token): Store location of the token into the
1893 new field.
1894 (c_parser_declaration_or_fndef): Store params into DECL_ARGUMENTS
1895 when handling a FUNCTION_DECL, if it doesn't already have them.
1896 (c_parser_parameter_declaration): Generate a location for the
1897 parameter, and pass it to the call to build_c_parm.
1898 * c-tree.h (struct c_parm): Add field "loc".
1899 (build_c_parm): Add location_t param.
1900 * c-typeck.c (get_fndecl_argument_location): New function.
1901 (inform_for_arg): New function.
1902 (convert_for_assignment): Use inform_for_arg when dealing with
1903 ic_argpass.
1904
2a389958
JJ
19052017-09-29 Jakub Jelinek <jakub@redhat.com>
1906
7d386d45
JJ
1907 * c-decl.c (grokfield): Use SET_DECL_C_BIT_FIELD here if
1908 width is non-NULL.
1909 (finish_struct): Test DECL_C_BIT_FIELD instead of DECL_INITIAL,
1910 don't SET_DECL_C_BIT_FIELD here.
1911
2a389958
JJ
1912 PR c/82340
1913 * c-decl.c (build_compound_literal): Use c_apply_type_quals_to_decl
1914 instead of trying to set just TREE_READONLY manually.
1915
ebc6a85e
TV
19162017-09-16 Tom de Vries <tom@codesourcery.com>
1917
1918 PR c/81875
1919 * c-parser.c (c_parser_omp_for_loop): Fold only operands of cond, not
1920 cond itself.
1921
bb75facd
JM
19222017-09-15 Joseph Myers <joseph@codesourcery.com>
1923
1924 PR c/82071
1925 * c-typeck.c (ep_convert_and_check): Just call convert_and_check
1926 for C11.
1927 (build_conditional_expr): For C11, generate result with excess
1928 precision when one argument is an integer and the other is of a
1929 type using excess precision.
1930
1d933576
BE
19312017-09-15 Bernd Edlinger <bernd.edlinger@hotmail.de>
1932
1933 * c-typeck.c (build_c_cast): Implement -Wcast-align=strict.
1934
267bbb6f
MP
19352017-09-13 Marek Polacek <polacek@redhat.com>
1936
1937 PR c/82167
1938 * c-typeck.c (c_expr_sizeof_expr): Use the type of expr.value rather
1939 than expr.original_type.
1940
6836632e
NS
19412017-09-12 Nathan Sidwell <nathan@acm.org>
1942
1943 * c-decl.c (field_decl_cmp, resort_data, resort_field_decl_cmp,
1944 resort_sorted_fields): Moved from c-family/c-common.c.
1945 * c-lang.h (struct sorted_fields_type): Moved from c-family/c-common.h.
1946
e035be33
JM
19472017-09-01 Joseph Myers <joseph@codesourcery.com>
1948
1949 PR c/82071
1950 * c-typeck.c (build_atomic_assign): Handle argument with excess
1951 precision. Ensure any EXCESS_PRECISION_EXPR is present in
1952 argument passed to build_binary_op and convert_for_assignment but
1953 not for call to c_fully_fold.
1954 (build_modify_expr): Do not remove EXCESS_PRECISION_EXPR early.
1955 Ensure build_binary_op is called with argument with original
1956 semantic type. Avoid calling c_fully_fold with an
1957 EXCESS_PRECISION_EXPR from build_binary_op.
1958
d2e05fcb
JJ
19592017-09-01 Jakub Jelinek <jakub@redhat.com>
1960
1961 PR c/81887
1962 * c-parser.c (c_parser_omp_ordered): Handle -fopenmp-simd.
1963
b397965c
RS
19642017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
1965 Alan Hayward <alan.hayward@arm.com>
1966 David Sherwood <david.sherwood@arm.com>
1967
1968 * c-typeck.c (build_binary_op): Use SCALAR_TYPE_MODE.
1969 (c_common_type): Likewise. Use as_a <scalar_mode> when setting
1970 m1 and m2 to the signed equivalent of a fixed-point
1971 SCALAR_TYPE_MODE.
1972
14e18d71
DM
19732017-08-24 David Malcolm <dmalcolm@redhat.com>
1974
1975 * c-tree.h (c_expr::get_location) Use EXPR_HAS_LOCATION rather
1976 than CAN_HAVE_LOCATION_P when determining whether to use the
1977 location_t value within "value".
1978
7f204c0f
DM
19792017-08-21 David Malcolm <dmalcolm@redhat.com>
1980
1981 * c-parser.c (c_parser_expr_list): Use c_expr::get_location ()
1982 rather than peeking the location of the first token.
1983 * c-tree.h (c_expr::get_location): New method.
1984
2f687306
DM
19852017-08-21 David Malcolm <dmalcolm@redhat.com>
1986
1987 * c-typeck.c (build_function_call_vec): Pass arg_loc to call
1988 to check_function_arguments.
1989
3e7b80d7
MP
19902017-08-18 Marek Polacek <polacek@redhat.com>
1991
1992 * c-parser.c (c_parser_postfix_expression): Remove unused code. Update
1993 commentary.
1994
00aa1fa2
L
19952017-08-18 H.J. Lu <hongjiu.lu@intel.com>
1996
1997 PR c/53037
1998 * c-decl.c (merge_decls): Also merge DECL_WARN_IF_NOT_ALIGN.
1999 (check_bitfield_type_and_width): Don't allow bit-field with
2000 warn_if_not_aligned type.
2001
da67acb9
MS
20022017-08-14 Martin Sebor <msebor@redhat.com>
2003
2004 PR c/81117
2005 * c-objc-common.c (c_objc_common_init): Handle 'G'.
2006
bb85aa74
MP
20072017-08-11 Marek Polacek <polacek@redhat.com>
2008
2009 PR c/81795
2010 * c-decl.c (pushtag): Only print inform if the warning was printed.
2011 (grokdeclarator): Likewise.
2012
32129a17
DM
20132017-08-10 David Malcolm <dmalcolm@redhat.com>
2014
2015 * c-parser.c (c_parser_error): Rename to...
2016 (c_parser_error_richloc): ...this, making static, and adding
2017 "richloc" parameter, passing it to the c_parse_error call,
2018 rather than calling c_parser_set_source_position_from_token.
2019 (c_parser_error): Reintroduce, reimplementing in terms of the
2020 above, converting return type from void to bool.
2021 (class token_pair): New class.
2022 (struct matching_paren_traits): New struct.
2023 (matching_parens): New typedef.
2024 (struct matching_brace_traits): New struct.
2025 (matching_braces): New typedef.
2026 (get_matching_symbol): New function.
2027 (c_parser_require): Add param MATCHING_LOCATION, using it to
2028 highlight matching "opening" tokens for missing "closing" tokens.
2029 (c_parser_skip_until_found): Likewise.
2030 (c_parser_static_assert_declaration_no_semi): Convert explicit
2031 parsing of CPP_OPEN_PAREN and CPP_CLOSE_PAREN to use of
2032 class matching_parens, so that the pertinent open parenthesis is
2033 highlighted when there are problems locating the close
2034 parenthesis.
2035 (c_parser_struct_or_union_specifier): Likewise.
2036 (c_parser_typeof_specifier): Likewise.
2037 (c_parser_alignas_specifier): Likewise.
2038 (c_parser_simple_asm_expr): Likewise.
2039 (c_parser_braced_init): Likewise, for matching_braces.
2040 (c_parser_paren_condition): Likewise, for matching_parens.
2041 (c_parser_switch_statement): Likewise.
2042 (c_parser_for_statement): Likewise.
2043 (c_parser_asm_statement): Likewise.
2044 (c_parser_asm_operands): Likewise.
2045 (c_parser_cast_expression): Likewise.
2046 (c_parser_sizeof_expression): Likewise.
2047 (c_parser_alignof_expression): Likewise.
2048 (c_parser_generic_selection): Likewise.
2049 (c_parser_postfix_expression): Likewise for cases RID_VA_ARG,
2050 RID_OFFSETOF, RID_TYPES_COMPATIBLE_P, RID_AT_SELECTOR,
2051 RID_AT_PROTOCOL, RID_AT_ENCODE, reindenting as necessary.
2052 In case CPP_OPEN_PAREN, pass loc_open_paren to the
2053 c_parser_skip_until_found call.
2054 (c_parser_objc_class_definition): Use class matching_parens as
2055 above.
2056 (c_parser_objc_method_decl): Likewise.
2057 (c_parser_objc_try_catch_finally_statement): Likewise.
2058 (c_parser_objc_synchronized_statement): Likewise.
2059 (c_parser_objc_at_property_declaration): Likewise.
2060 (c_parser_oacc_wait_list): Likewise.
2061 (c_parser_omp_var_list_parens): Likewise.
2062 (c_parser_omp_clause_collapse): Likewise.
2063 (c_parser_omp_clause_default): Likewise.
2064 (c_parser_omp_clause_if): Likewise.
2065 (c_parser_omp_clause_num_threads): Likewise.
2066 (c_parser_omp_clause_num_tasks): Likewise.
2067 (c_parser_omp_clause_grainsize): Likewise.
2068 (c_parser_omp_clause_priority): Likewise.
2069 (c_parser_omp_clause_hint): Likewise.
2070 (c_parser_omp_clause_defaultmap): Likewise.
2071 (c_parser_oacc_single_int_clause): Likewise.
2072 (c_parser_omp_clause_ordered): Likewise.
2073 (c_parser_omp_clause_reduction): Likewise.
2074 (c_parser_omp_clause_schedule): Likewise.
2075 (c_parser_omp_clause_num_teams): Likewise.
2076 (c_parser_omp_clause_thread_limit): Likewise.
2077 (c_parser_omp_clause_aligned): Likewise.
2078 (c_parser_omp_clause_linear): Likewise.
2079 (c_parser_omp_clause_safelen): Likewise.
2080 (c_parser_omp_clause_simdlen): Likewise.
2081 (c_parser_omp_clause_depend): Likewise.
2082 (c_parser_omp_clause_map): Likewise.
2083 (c_parser_omp_clause_device): Likewise.
2084 (c_parser_omp_clause_dist_schedule): Likewise.
2085 (c_parser_omp_clause_proc_bind): Likewise.
2086 (c_parser_omp_clause_uniform): Likewise.
2087 (c_parser_omp_for_loop): Likewise.
2088 (c_parser_cilk_clause_vectorlength): Likewise.
2089 (c_parser_cilk_clause_linear): Likewise.
2090 (c_parser_transaction_expression): Likewise.
2091 * c-parser.h (c_parser_require): Add param matching_location with
2092 default UNKNOWN_LOCATION.
2093 (c_parser_error): Convert return type from void to bool.
2094 (c_parser_skip_until_found): Add param matching_location with
2095 default UNKNOWN_LOCATION.
2096
30af3a2b
MP
20972017-08-09 Marek Polacek <polacek@redhat.com>
2098
2099 * c-decl.c (build_enumerator): Use true/false instead of 1/0.
2100 * c-tree.h (build_external_ref): Update declaration.
2101 * c-typeck.c (build_array_ref): Use true/false instead of 1/0.
2102 (build_external_ref): Change the type of a parameter to bool.
2103 (parser_build_binary_op): Use true/false instead of 1/0.
2104 (pointer_diff): Likewise.
2105 (build_modify_expr): Likewise.
2106 (set_designator): Change the type of a parameter to bool.
2107 (set_init_index): Use true/false instead of 1/0.
2108 (set_init_label): Likewise.
2109 (output_init_element): Change the type of a parameter to bool.
2110 (output_pending_init_elements): Use true/false instead of 1/0.
2111 (process_init_element): Likewise.
2112 (build_binary_op): Change the type of a parameter to bool.
2113
296c53ac
MP
21142017-08-09 Marek Polacek <polacek@redhat.com>
2115
2116 PR c/81233
2117 * c-typeck.c (pedwarn_init): Make the function take a variable list.
2118 Call emit_diagnostic_valist instead of pedwarn.
2119 (convert_for_assignment): Unroll the PEDWARN_FOR_ASSIGNMENT macro.
2120 Print the relevant types in diagnostics.
2121
a32c8316
MP
21222017-08-09 Marek Polacek <polacek@redhat.com>
2123
2124 PR c/81417
2125 * c-array-notation.c (fix_builtin_array_notation_fn): Update calls to
ab20d992 2126 build_conditional_expr.
a32c8316
MP
2127 * c-parser.c (c_parser_conditional_expression): Create locations for
2128 EXP1 and EXP2 from their source ranges. Pass the locations down to
2129 build_conditional_expr.
2130 * c-tree.h (build_conditional_expr): Update declaration.
2131 * c-typeck.c (build_conditional_expr): Add location_t parameters.
2132 For -Wsign-compare, also print the types.
2133
314e6352
ML
21342017-08-08 Martin Liska <mliska@suse.cz>
2135
2136 * c-convert.c: Include header files.
2137 * c-typeck.c: Likewise.
2138
577eec56
ML
21392017-08-07 Martin Liska <mliska@suse.cz>
2140
2141 * c-parser.c (c_parser_attributes): Canonicalize name of an
2142 attribute.
2143
f7b6353a
MP
21442017-08-02 Marek Polacek <polacek@redhat.com>
2145
2146 PR c/81289
2147 * c-parser.c (c_parser_unary_expression): Use set_error.
2148
8a6eab34
MP
2149 PR c/81448
2150 PR c/81306
2151 * c-warn.c (warn_for_multistatement_macros): Prevent bogus
2152 warnings. Avoid walking MACRO_MAP_LOCATIONS.
2153
ab20d992 21542017-07-31 Jan Hubicka <hubicka@ucw.cz>
7fef86d3
JH
2155 Martin Liska <mliska@suse.cz>
2156
2157 * c-typeck.c (c_finish_goto_label): Build gimple predict
f7b6353a 2158 statement.
7fef86d3 2159
f34ebeb2
ML
21602017-07-31 Martin Liska <mliska@suse.cz>
2161
2162 PR sanitize/81530
2163 * c-convert.c (convert): Guard condition with flag_sanitize_p
2164 also with current_function_decl non-null equality.
2165 * c-decl.c (grokdeclarator): Likewise.
2166 * c-typeck.c (build_binary_op): Likewise.
2167
8595f67b
MP
21682017-07-25 Marek Polacek <polacek@redhat.com>
2169
2170 * c-decl.c (grokfield): Remove local variable.
2171
d49718d6
MP
21722017-07-25 Marek Polacek <polacek@redhat.com>
2173
2174 PR c/81364
2175 * c-parser.c (c_parser_else_body): Don't warn about multistatement
2176 macro expansion if the body is in { }.
2177 (c_parser_while_statement): Likewise.
2178 (c_parser_for_statement): Likewise.
2179
ff22eb12
NS
21802017-07-18 Nathan Sidwell <nathan@acm.org>
2181
2182 * c-parser.c (c_parser_array_notation): Use TYPE_{MIN,MAX}_VALUE.
2183
eea77d1f
DM
21842017-07-14 David Malcolm <dmalcolm@redhat.com>
2185
2186 * c-decl.c (implicitly_declare): When suggesting a missing
2187 #include, provide a fix-it hint.
2188
b6f43128
DM
21892017-07-06 David Malcolm <dmalcolm@redhat.com>
2190
2191 * c-lang.c (selftest::run_c_tests): Move body to c_family_tests,
2192 and call that instead.
2193 * c-tree.h (selftest::run_c_tests): New decl.
2194
3e2becc4
MP
21952017-06-26 Marek Polacek <polacek@redhat.com>
2196
2197 PR c/80116
2198 * c-parser.c (c_parser_if_body): Set the location of the
2199 body of the conditional after parsing all the labels. Call
2200 warn_for_multistatement_macros.
2201 (c_parser_else_body): Likewise.
2202 (c_parser_switch_statement): Likewise.
2203 (c_parser_while_statement): Likewise.
2204 (c_parser_for_statement): Likewise.
2205 (c_parser_statement): Add a default argument. Save the location
2206 after labels have been parsed.
2207 (c_parser_c99_block_statement): Likewise.
2208
343ae898
RB
22092017-06-19 Richard Biener <rguenther@suse.de>
2210
2211 * gimple-parser.c (c_parser_gimple_postfix_expression): Handle
2212 negated _Literals to parse _Literal (int) -1.
2213
45b2222a
ML
22142017-06-13 Martin Liska <mliska@suse.cz>
2215
2216 PR sanitize/78204
2217 * c-convert.c (convert): Use sanitize_flags_p.
2218 * c-decl.c (grokdeclarator): Likewise.
2219 * c-typeck.c (convert_for_assignment): Likewise.
2220 (c_finish_return): Likewise.
2221 (build_binary_op): Likewise.
2222
8ab7005b
JJ
22232017-06-08 Jakub Jelinek <jakub@redhat.com>
2224
2225 PR c/81006
2226 * c-typeck.c (handle_omp_array_sections_1): Convert TYPE_MAX_VALUE
2227 to sizetype before size_binop.
2228
363dc72c
JJ
22292017-06-07 Jakub Jelinek <jakub@redhat.com>
2230
2231 * gimple-parser.c (c_parser_parse_gimple_body): Use TDI_gimple instead
2232 of TDI_generic.
2233
dc949728
MP
22342017-06-06 Marek Polacek <polacek@redhat.com>
2235
2236 PR c/79983
2237 * c-decl.c (start_struct): Use the location of TYPE_STUB_DECL of
2238 ref.
2239 (start_enum): Use the location of TYPE_STUB_DECL of enumtype.
2240
40ffd95f
BE
22412017-06-02 Bernd Edlinger <bernd.edlinger@hotmail.de>
2242
2243 * c-parser.c (c_parser_binary_expression): Implement the
2244 -Wsizeof_pointer_div warning.
2245 (c_parser_postfix_expression): Allow SIZEOF_EXPR as expr.original_code
2246 from a parenthesized expression.
2247 (c_parser_expr_list): Use c_last_sizeof_loc.
2248 * c-tree.h (c_last_sizeof_loc): New external.
2249 * c-typeck.c (c_last_sizeof_loc): New variable.
2250 (c_expr_sizeof_expr, c_expr_sizeof_type): Assign c_last_sizeof_loc.
2251
9fc5e7a4
MM
22522017-05-31 Mikhail Maltsev <maltsevm@gmail.com>
2253
2254 PR testsuite/80580
2255 * gimple-parser.c (c_parser_gimple_if_stmt): Check for empty labels.
2256
f012c8ef
DM
22572017-05-30 David Malcolm <dmalcolm@redhat.com>
2258
2259 * c-objc-common.c (c_tree_printer): Gain bool and const char **
2260 parameters.
2261
3cd211af
MS
22622017-05-24 Martin Sebor <msebor@redhat.com>
2263
2264 PR c/80731
2265 * c-fold.c (c_fully_fold_internal): Adjust.
2266 * c-typeck.c (parser_build_unary_op): Adjust.
2267
fd71a9a2
TS
22682017-05-23 Thomas Schwinge <thomas@codesourcery.com>
2269
2270 * c-parser.c (OACC_KERNELS_CLAUSE_MASK): Add
2271 "PRAGMA_OACC_CLAUSE_NUM_GANGS", "PRAGMA_OACC_CLAUSE_NUM_WORKERS",
2272 "VECTOR_LENGTH".
2273
92fa0f9e
MP
22742017-05-23 Marek Polacek <polacek@redhat.com>
2275
2276 * c-parser.c (c_parser_compound_statement_nostart): Remove redundant
2277 quotes.
2278
d11c168a
JJ
22792017-05-22 Jakub Jelinek <jakub@redhat.com>
2280
2281 * c-fold.c (c_fully_fold_internal): Save the c_fully_fold_internal
2282 result for SAVE_EXPR operand and set SAVE_EXPR_FOLDED_P even if
2283 it returned invariant. Call tree_invariant_p unconditionally
2284 afterwards to decide whether to return expr or op0.
2285
58aca9d9
NS
22862017-05-22 Nathan Sidwell <nathan@acm.org>
2287
2288 * c-decl.c (c_parse_final_cleanups): Drop TDI_tu handling.
2289
7fd549d2
TS
22902017-05-19 Thomas Schwinge <thomas@codesourcery.com>
2291
2292 * c-parser.c (c_parser_omp_clause_default): Handle
2293 "OMP_CLAUSE_DEFAULT_PRESENT".
2294
6ecd2339
BE
22952017-05-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
2296
2297 * config-lang.in (gtfiles): Add c-family/c-format.c.
2298
8a57ecff
NS
22992017-05-18 Nathan Sidwell <nathan@acm.org>
2300
2301 * c-decl.c (pushdecl_top_level): Delete unused function.
2302
6574d78e
MP
23032017-05-18 Marek Polacek <polacek@redhat.com>
2304
2305 * c-decl.c (match_builtin_function_types): Use NULL_TREE instead of 0.
2306 (check_earlier_gotos): Likewise.
2307 (define_label): Likewise.
2308 (pending_xref_error): Likewise.
2309 (smallest_type_quals_location): Likewise.
2310 (grokdeclarator): Likewise.
2311 (grokparms): Likewise.
2312 (identifier_global_value): Likewise.
2313 * c-typeck.c (set_nonincremental_init_from_string): Likewise.
2314 (find_init_member): Likewise.
2315
e3455240
MP
23162017-05-18 Marek Polacek <polacek@redhat.com>
2317
2318 * c-decl.c (start_decl): Use false/true instead of 0/1.
2319 (grokdeclarator): Likewise.
2320 (finish_struct): Likewise.
2321 (start_function): Change the return type to bool. Use false/true
2322 instead of 0/1.
2323 (declspecs_add_qual): Use UNKNOWN_LOCATION instead of 0.
2324 * c-tree.h (start_function): Update.
2325 * c-typeck.c (same_translation_unit_p): Change the return type to bool.
2326 (set_designator): Change the return type to bool. Use false/true
2327 instead of 0/1.
2328
3fa8871b
MP
23292017-05-17 Marek Polacek <polacek@redhat.com>
2330
2331 * c-decl.c: Use NULL_TREE instead of 0 where appropriate.
2332 * c-typeck.c: Likewise.
2333
142473df
MP
23342017-05-17 Marek Polacek <polacek@redhat.com>
2335
2336 PR sanitizer/80659
2337 * c-decl.c (build_compound_literal): Set DECL_ARTIFICIAL and
2338 DECL_IGNORED_P even for non-static compound literals.
2339
1a817418
ML
23402017-05-17 Martin Liska <mliska@suse.cz>
2341
2342 * c-decl.c (c_parse_final_cleanups): Introduce dump_flags_t type and
2343 use it instead of int type.
2344
b2fa0a8b
MP
23452017-05-17 Marek Polacek <polacek@redhat.com>
2346
2347 * c-convert.c (convert): Replace c_save_expr with save_expr. Don't
2348 call c_fully_fold.
2349 (convert) <case COMPLEX_TYPE>: Remove special handling of COMPLEX_TYPEs.
ab20d992 2350 * c-decl.c (grokdeclarator): Replace c_save_expr with save_expr.
b2fa0a8b
MP
2351 * c-fold.c (c_fully_fold_internal): Handle SAVE_EXPR.
2352 * c-parser.c (c_parser_declaration_or_fndef): Replace c_save_expr with
2353 save_expr.
2354 (c_parser_conditional_expression): Likewise.
2355 * c-tree.h (SAVE_EXPR_FOLDED_P): Define.
2356 * c-typeck.c (build_modify_expr): Replace c_save_expr with save_expr.
2357 (process_init_element): Likewise.
2358 (build_binary_op): Likewise.
2359 (handle_omp_array_sections_1): Likewise.
2360
1e47f02b
TS
23612017-05-12 Thomas Schwinge <thomas@codesourcery.com>
2362
2363 * c-parser.c (c_parser_omp_clause_num_gangs)
2364 (c_parser_omp_clause_num_workers)
2365 (c_parser_omp_clause_vector_length): Merge functions into...
2366 (c_parser_oacc_single_int_clause): ... this new function. Adjust
2367 all users.
2368
c24e924f
NS
23692017-05-11 Nathan Sidwell <nathan@acm.org>
2370
2371 * gimple-parser.c: Don't #include tree-dump.h.
2372
c587104e
MM
23732017-05-11 Mikhail Maltsev <maltsevm@gmail.com>
2374
2375 PR testsuite/80580
2376 * gimple-parser.c (c_parser_parse_ssa_name): Validate SSA name base.
2377
67ac9a9d
MM
23782017-05-11 Mikhail Maltsev <maltsevm@gmail.com>
2379
2380 PR testsuite/80580
2381 * gimple-parser.c (c_parser_gimple_postfix_expression): Handle
2382 incorrect __MEM syntax.
2383
ac4eb40f
MM
23842017-05-11 Mikhail Maltsev <maltsevm@gmail.com>
2385
2386 PR testsuite/80580
2387 * gimple-parser.c (c_parser_gimple_unary_expression): Check argument
2388 type of unary '*'.
2389
641da50a
NS
23902017-05-09 Nathan Sidwell <nathan@acm.org>
2391
2392 * c-tree.h (pushdecl): Declare.
2393
56d35585
DM
23942017-05-05 David Malcolm <dmalcolm@redhat.com>
2395
2396 * c-decl.c (warn_defaults_to): Replace report_diagnostic
2397 with diagnostic_report_diagnostic.
2398 * c-errors.c (pedwarn_c99): Likewise.
2399 (pedwarn_c90): Likewise.
2400
815d9cc6
XR
24012017-05-01 Xi Ruoyao <ryxi@stu.xidian.edu.cn>
2402
92a285c1 2403 PR c++/80038
815d9cc6
XR
2404 * c-gimplify.c (c_gimplify_expr): Remove calls to
2405 cilk_gimplifY_call_params_in_spawned_fn.
2406
1c4ea66f
DM
24072017-04-25 David Malcolm <dmalcolm@redhat.com>
2408
2409 * c-parser.c (c_parser_struct_or_union_specifier): Add fix-it
2410 hint for removing extra semicolon.
2411
666f7903
JJ
24122017-04-21 Jakub Jelinek <jakub@redhat.com>
2413
2414 PR c/80468
2415 * c-decl.c (finish_declspecs) <case cts_int_n>: If int_n_idx is not
2416 enabled, set specs->type to integer_type_node.
2417
5764ee3c
JW
24182017-04-03 Jonathan Wakely <jwakely@redhat.com>
2419
2420 * c-array-notation.c: Fix typo in comment.
2421
10fa8dfb
MP
24222017-03-29 Marek Polacek <polacek@redhat.com>
2423
2424 PR c/79730
2425 * c-decl.c (finish_decl): Check VAR_P.
2426
a9e4a1a5
JJ
24272017-03-27 Jakub Jelinek <jakub@redhat.com>
2428
2429 PR middle-end/80162
2430 * c-tree.h (c_mark_addressable): Add array_ref_p argument.
2431 * c-typeck.c (c_mark_addressable): Likewise. Look through
2432 VIEW_CONVERT_EXPR unless array_ref_p and VCE is from VECTOR_TYPE
2433 to ARRAY_TYPE.
2434 (build_array_ref): Pass true as array_ref_p to c_mark_addressable.
2435
ee3ff394
MP
24362017-03-23 Marek Polacek <polacek@redhat.com>
2437
2438 * c-tree.h: Remove a C_RID_YYCODE reference.
2439
4d1b8e70
JJ
24402017-03-21 Jakub Jelinek <jakub@redhat.com>
2441
2442 PR c/80097
2443 * c-typeck.c (build_binary_op): Add EXCESS_PRECISION_EXPR only around
2444 optional COMPOUND_EXPR with ubsan instrumentation.
2445
31dc71a8
MP
24462017-03-17 Marek Polacek <polacek@redhat.com>
2447
2448 * c-parser.c: Add C11 references.
2449
d579c385
MP
24502017-03-15 Marek Polacek <polacek@redhat.com>
2451
2452 * c-parser.c (c_parser_enum_specifier): Remove redundant line.
2453
85059a38
MP
24542017-03-11 Marek Polacek <polacek@redhat.com>
2455
2456 * c-decl.c (implicit_decl_warning): Add a comment. Fix formatting.
2457
2f6f187a
DM
24582017-03-10 David Malcolm <dmalcolm@redhat.com>
2459
2460 PR translation/79848
2461 * c-decl.c (declspecs_add_type): Simplify uses of "%<%s%>" to
2462 "%qs".
2463 * c-parser.c (c_parser_oacc_shape_clause): Likewise.
2464
36618428
MP
24652017-03-09 Marek Polacek <polacek@redhat.com>
2466
2467 PR sanitizer/79757
2468 * c-parser.c (c_parser_declaration_or_fndef): Don't sanitize old-style
2469 parameter declarations with initializers.
2470
01e5af5a
JJ
24712017-03-09 Jakub Jelinek <jakub@redhat.com>
2472
2473 PR c/79969
2474 * c-decl.c (start_enum): Adjust DECL_SOURCE_LOCATION of
2475 TYPE_STUB_DECL.
2476
a71dbc63
JJ
24772017-03-07 Jakub Jelinek <jakub@redhat.com>
2478
2479 PR c/79834
2480 * c-parser.c (c_parser_pragma): Use error_at instead of c_parser_error
2481 for "may only be used in compound statements" diagnostics, change it
2482 such that the same translatable string is used for all pragmas. For
2483 PRAGMA_OACC_WAIT use "acc wait" rather than "acc enter data" in the
2484 diagnostics.
2485 (c_parser_omp_cancellation_point, c_parser_omp_target_update,
2486 c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): Change
2487 "may only be used in compound statements" diagnostics, such that the
2488 same translatable string is used for all pragmas.
2489
1ff4bae6
MP
24902017-03-04 Marek Polacek <polacek@redhat.com>
2491
2492 PR c/79847
2493 * c-decl.c (implicit_decl_warning): Add missing space.
2494
7f5a7d78
MP
24952017-03-03 Marek Polacek <polacek@redhat.com>
2496
2497 PR c/79758
2498 * c-decl.c (store_parm_decls_oldstyle): Check if the element of
2499 current_function_prototype_arg_types is error_mark_node. Fix
2500 formatting. Use TREE_VALUE instead of TREE_TYPE.
2501
883c8f06
JJ
25022017-03-03 Jakub Jelinek <jakub@redhat.com>
2503
79c9b7a8
JJ
2504 PR c/79837
2505 * c-parser.c (c_parser_omp_clause_reduction): Don't mention
2506 %<min%> or %<max%> in the diagnostics, instead mention identifier.
2507 (c_parser_omp_declare_reduction): Don't mention %<min%> in the
2508 diagnostics.
2509
883c8f06
JJ
2510 PR c/79836
2511 * c-parser.c (c_parser_generic_selection): Use %<_Generic%>
2512 instead of %<_Generic>.
2513 (c_parser_omp_ordered): Use %<depend%> instead of %<depend>.
2514 (c_parser_omp_target_exit_data): Use %<release%> instead of
2515 %<release>.
2516
324ff1a0
JJ
25172017-02-28 Jakub Jelinek <jakub@redhat.com>
2518
2519 * c-parser.c (c_parser_asm_statement): Use cond ? G_("...") : G_("...")
2520 instead of just cond ? "..." : "...".
2521 (c_parser_oacc_enter_exit_data): Use %s and ternary operator only
2522 for "enter"/"exit" keyword.
2523 (c_finish_oacc_routine): Don't use %s to supply portions of the
2524 message.
2525
4227c9ad
JJ
25262017-02-24 Jakub Jelinek <jakub@redhat.com>
2527
2528 PR c++/79588
2529 * c-parser.c (c_parser_postfix_expression_after_primary): Don't
2530 handle -Wrestrict here.
2531 * c-typeck.c (build_function_call_vec): Adjust
2532 check_function_arguments caller.
2533
5d972e66
RB
25342017-02-23 Richard Biener <rguenther@suse.de>
2535
2536 PR c/79684
2537 * gimple-parser.c (c_parser_gimple_statement): Use set_error
2538 to initialize c_exprs to return.
2539 (c_parser_gimple_binary_expression): Likewise.
2540 (c_parser_gimple_unary_expression): Likewise.
2541 (c_parser_gimple_postfix_expression): Likewise.
2542
61ac5ebe
MP
25432017-02-22 Marek Polacek <polacek@redhat.com>
2544
2545 PR c/79662
2546 * c-typeck.c (convert_arguments): Handle error_mark_node.
2547
41d1b0b1
PK
25482017-02-19 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2549
2550 * gimple-parser.c (c_parser_gimple_postfix_expression): Check return
2551 value of c_parser_parse_ssa_name against error_mark_node and emit
2552 error if ssa name is anonymous and written as default definition.
2553
eab1f169
PK
25542017-02-19 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2555
2556 * gimple-parser.c (c_parser_gimple_postfix_expression): Handle
2557 FMA_EXPR.
2558
bcac0b4d
JJ
25592017-02-16 Jakub Jelinek <jakub@redhat.com>
2560
2561 PR c++/79512
2562 * c-parser.c (c_parser_omp_target): For -fopenmp-simd
2563 ignore #pragma omp target even when not followed by identifier.
2564
1be33173
PK
25652017-02-14 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2566
2567 * gimpler-parser.c (c_parser_gimple_statement): Handle ABS_EXPR.
2568 (c_parser_gimple_unary_expression): Likewise.
2569
aa326bfb
JJ
25702017-02-13 Jakub Jelinek <jakub@redhat.com>
2571
2572 * c-parser.c (c_parser_oacc_declare): Add missing space in
2573 diagnostics.
2574
8a398bc5
PK
25752017-02-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2576
2577 PR c/79478
2578 * gimple-parser.c (c_parser_gimple_postfix_expression): Call
2579 set_c_expr_source_range when parsing ssa-name.
2580
3dcde5ef 25812017-02-10 Prasad Ghangal <prasad.ghangal@gmail.com>
ab20d992 2582 Richard Biener <rguenther@suse.de>
3dcde5ef
PG
2583
2584 * gimple-parser.c (c_parser_gimple_binary_expression): Avoid
2585 building IL when arguments are error_mark_node.
2586 (c_parser_gimple_unary_expression): Likewise.
2587 (c_parser_gimple_if_stmt): Likewise.
2588 (c_parser_gimple_switch_stmt): Likewise.
2589 (c_parser_gimple_return_stmt): Likewise.
2590 (c_parser_parse_ssa_name): When name lookup fails do not build
2591 an SSA name. Use undeclared rather than not declared in error
2592 reporting.
2593
192b048b
MP
25942017-02-09 Marek Polacek <polacek@redhat.com>
2595
2596 PR c/79428
2597 * c-parser.c (c_parser_omp_ordered): Call c_parser_skip_to_pragma_eol
2598 instead of c_parser_skip_until_found.
2599
56f71478
JJ
26002017-02-09 Jakub Jelinek <jakub@redhat.com>
2601
2602 PR c/79431
2603 * c-parser.c (c_parser_omp_declare_target): Don't invoke
2604 symtab_node::get on automatic variables.
2605
02889d23
CLT
26062016-02-09 Nathan Sidwell <nathan@codesourcery.com>
2607 Chung-Lin Tang <cltang@codesourcery.com>
2608
2609 * c-parser.c (c_parser_omp_clause_collapse): Disallow tile.
2610 (c_parser_oacc_clause_tile): Disallow collapse. Fix parsing and
2611 semantic checking.
2612 * c-parser.c (c_parser_omp_for_loop): Accept tiling constructs.
2613
7af4b20d
RB
26142017-02-07 Richard Biener <rguenther@suse.de>
2615
2616 * gimple-parser.c (c_parser_gimple_expr_list): Simplify.
2617 (c_parser_gimple_postfix_expression_after_primary):
2618 Do not use c_build_function_call_vec to avoid folding and promotion.
2619 Simplify.
2620
e5e391d6
MO
26212017-01-25 Maxim Ostapenko <m.ostapenko@samsung.com>
2622
2623 PR lto/79061
2624 * c-decl.c (pop_scope): Pass main_input_filename to
2625 build_translation_unit_decl.
2626
c2e84327
DM
26272017-01-24 David Malcolm <dmalcolm@redhat.com>
2628
2629 * c-parser.c: Include "read-rtl-function.h" and
2630 "run-rtl-passes.h".
2631 (c_parser_declaration_or_fndef): Rename "gimple-pass-list" in
2632 grammar to gimple-or-rtl-pass-list. Add rtl-function-definition
2633 production. Update for renaming of field "gimple_pass" to
2634 "gimple_or_rtl_pass". If __RTL was seen, call
2635 c_parser_parse_rtl_body. Convert a timevar_push/pop pair
2636 to an auto_timevar, to cope with early exit.
2637 (c_parser_declspecs): Update RID_GIMPLE handling for renaming of
2638 field "gimple_pass" to "gimple_or_rtl_pass", and for renaming of
2639 c_parser_gimple_pass_list to c_parser_gimple_or_rtl_pass_list.
2640 Handle RID_RTL.
2641 (c_parser_parse_rtl_body): New function.
2642 * c-tree.h (enum c_declspec_word): Add cdw_rtl.
2643 (struct c_declspecs): Rename field "gimple_pass" to
2644 "gimple_or_rtl_pass". Add field "rtl_p".
2645 * gimple-parser.c (c_parser_gimple_pass_list): Rename to...
2646 (c_parser_gimple_or_rtl_pass_list): ...this, updating accordingly.
2647 * gimple-parser.h (c_parser_gimple_pass_list): Rename to...
2648 (c_parser_gimple_or_rtl_pass_list): ...this.
2649
2ebd93e1
MP
26502017-01-20 Marek Polacek <polacek@redhat.com>
2651
2652 PR c/64279
2653 * c-typeck.c (build_conditional_expr): Warn about duplicated branches.
2654
b1c95bb5
RB
26552017-01-13 Richard Biener <rguenther@suse.de>
2656
2657 * gimple-parser.c (c_parser_gimple_compound_statement): Handle
2658 nops.
2659
25329913
RB
26602017-01-13 Richard Biener <rguenther@suse.de>
2661
2662 * gimple-parser.c (c_parser_gimple_postfix_expression): Parse
2663 _Literal ( type-name ) number.
2664
6bb4ea5c
RB
26652017-01-12 Richard Biener <rguenther@suse.de>
2666
2667 * gimple-parser.c (c_parser_gimple_postfix_expression): Parse
2668 __MEM.
2669
6b5b4e9c
JJ
26702017-01-11 Jakub Jelinek <jakub@redhat.com>
2671
2672 PR c++/72813
2673 * c-decl.c (pop_file_scope): Set flag_syntax_only to 1 after writing
2674 PCH file.
2675
e3252775
RB
26762017-01-11 Richard Biener <rguenther@suse.de>
2677
2678 PR bootstrap/79052
2679 * gimple-parser.c (c_parser_gimple_switch_stmt): Add missing
2680 returns on parse errors.
2681
a9342885
MP
26822017-01-04 Marek Polacek <polacek@redhat.com>
2683
2684 PR c++/64767
2685 * c-parser.c (c_parser_postfix_expression): Mark zero character
2686 constants by setting original_type in c_expr.
2687 * c-typeck.c (parser_build_binary_op): Warn when a pointer is compared
2688 with a zero character constant.
2689 (char_type_p): New function.
2690
5dd9a9d0
DM
26912017-01-04 David Malcolm <dmalcolm@redhat.com>
2692
2693 * c-parser.c (c_parser_declaration_or_fndef): Create a
2694 rich_location at init_loc and parse it to start_init.
2695 (last_init_list_comma): New global.
2696 (c_parser_braced_init): Update last_init_list_comma when parsing
2697 commas. Pass it to pop_init_level. Pass location of closing
2698 brace to pop_init_level.
2699 (c_parser_postfix_expression_after_paren_type): Create a
2700 rich_location at type_loc and parse it to start_init.
2701 (c_parser_omp_declare_reduction): Likewise for loc.
2702 * c-tree.h (start_init): Add rich_location * param.
2703 (pop_init_level): Add location_t param.
2704 * c-typeck.c (struct initializer_stack): Add field
2705 "missing_brace_richloc".
2706 (start_init): Add richloc param, use it to initialize
2707 the stack node's missing_brace_richloc.
2708 (last_init_list_comma): New decl.
2709 (finish_implicit_inits): Pass last_init_list_comma to
2710 pop_init_level.
2711 (push_init_level): When finding missing open braces, add fix-it
2712 hints to the richloc.
2713 (pop_init_level): Add "insert_before" param and pass it
2714 when calling pop_init_level. Add fixits about missing
2715 close braces to any richloc. Use the richloc for the
2716 -Wmissing-braces warning.
2717 (set_designator): Pass last_init_list_comma to pop_init_level.
2718 (process_init_element): Likewise.
2719
cbe34bb5
JJ
27202017-01-01 Jakub Jelinek <jakub@redhat.com>
2721
2722 Update copyright years.
2723
d17680f3
JJ
27242016-12-21 Jakub Jelinek <jakub@redhat.com>
2725
0dba7960
JJ
2726 PR bootstrap/78817
2727 * c-typeck.c (build_function_call_vec): If check_function_arguments
2728 returns true, set TREE_NO_WARNING on CALL_EXPR.
2729
d17680f3
JJ
2730 PR c/77767
2731 * c-decl.c (grokdeclarator): If *expr is non-NULL, append expression
2732 to *expr instead of overwriting it.
2733
aa90531e
RB
27342016-12-20 Richard Biener <rguenther@suse.de>
2735
2736 * gimple-parser.c (c_parser_gimple_compound_statement): Improve
2737 error recovery.
2738 (c_parser_gimple_statement): Only build assigns for non-error
2739 stmts.
2740 (c_parser_gimple_postfix_expression_after): Improve error recovery.
2741
629b3d75
MJ
27422016-12-14 Martin Jambor <mjambor@suse.cz>
2743
2744 * c-parser.c: Include omp-general.h and omp-offload.h instead of
2745 omp-low.h.
2746 (c_finish_oacc_routine): Adjusted call to
2747 get_oacc_fn_attrib, build_oacc_routine_dims and replace_oacc_fn_attrib
2748 to use their new names.
2749 (c_parser_oacc_enter_exit_data): Adjusted call to find_omp_clause to
2750 use its new name.
2751 (c_parser_oacc_update): Likewise.
2752 (c_parser_omp_simd): Likewise.
2753 (c_parser_omp_target_update): Likewise.
2754 * c-typeck.c: Include omp-general.h instead of omp-low.h.
2755 (c_finish_omp_cancel): Adjusted call to find_omp_clause to use its new
2756 name.
2757 (c_finish_omp_cancellation_point): Likewise.
2758 * gimple-parser.c: Do not include omp-low.h
2759
c5af52eb
CP
27602016-12-02 Cesar Philippidis <cesar@codesourcery.com>
2761 James Norris <jnorris@codesourcery.com>
2762
2763 * c-parser.c (c_parser_pragma): Error when PRAGMA_OACC_{ENTER_DATA,
2764 EXIT_DATA,WAIT} are not used in compound statements.
2765 (c_parser_oacc_enter_exit_data): Update diagnostics.
2766
48330c93
BE
27672016-11-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
2768
2769 PR c++/71973
2770 * c-decl.c (diagnose_mismatched_decls): Use
2771 OPT_Wbuiltin_declaration_mismatch here too.
2772
899ca90e 27732016-11-18 Richard Sandiford <richard.sandiford@arm.com>
48330c93
BE
2774 Alan Hayward <alan.hayward@arm.com>
2775 David Sherwood <david.sherwood@arm.com>
899ca90e
RS
2776
2777 * c-decl.c (merge_decls): Use SET_DECL_MODE.
2778 (make_label, finish_struct): Likewise.
2779
1ee62b92 27802016-11-14 Prasad Ghangal <prasad.ghangal@gmail.com>
8e745a17 2781 Richard Biener <rguenther@suse.de>
22b15758 2782
8e745a17
JJ
2783 * Make-lang.in (C_AND_OBJC_OBJS): Add gimple-parser.o.
2784 * config-lang.in (gtfiles): Add c/c-parser.h.
2785 * c-tree.h (enum c_declspec_word): Add cdw_gimple.
2786 (struct c_declspecs): Add gimple_pass member and gimple_p flag.
2787 * c-parser.c (enum c_id_kind, struct c_token,
2788 c_parser_next_token_is, c_parser_next_token_is_not,
2789 c_parser_next_token_is_keyword,
2790 enum c_lookahead_kind, enum c_dtr_syn, enum c_parser_prec):
2791 Split out to ...
2792 * c-parser.h: ... new header.
2793 * c-parser.c: Include c-parser.h and gimple-parser.h.
1ee62b92 2794 (c_parser_peek_token, c_parser_peek_2nd_token,
8e745a17
JJ
2795 c_token_starts_typename, c_parser_next_token_starts_declspecs,
2796 c_parser_next_tokens_start_declaration, c_parser_consume_token,
2797 c_parser_error, c_parser_require, c_parser_skip_until_found,
2798 c_parser_declspecs, c_parser_declarator, c_parser_peek_nth_token,
2799 c_parser_type_name): Export.
2800 (c_parser_tokens_buf): New function.
2801 (c_parser_error): Likewise.
2802 (c_parser_set_error): Likewise.
2803 (c_parser_declspecs): Handle RID_GIMPLE.
1ee62b92
PG
2804 (c_parser_declaration_or_fndef): Parse __GIMPLE marked body
2805 via c_parser_parse_gimple_body.
8e745a17
JJ
2806 * c-parser.h (c_parser_peek_token, c_parser_peek_2nd_token,
2807 c_token_starts_typename, c_parser_next_token_starts_declspecs,
2808 c_parser_next_tokens_start_declaration, c_parser_consume_token,
2809 c_parser_error, c_parser_require, c_parser_skip_until_found,
2810 c_parser_declspecs, c_parser_declarator, c_parser_peek_nth_token,
2811 c_parser_type_name): Declare.
1ee62b92
PG
2812 (struct c_parser): Declare forward.
2813 (c_parser_tokens_buf): Declare.
8e745a17
JJ
2814 (c_parser_error): Likewise.
2815 (c_parser_set_error): Likewise.
2816 * gimple-parser.c: New file.
2817 * gimple-parser.h: Likewise.
1ee62b92 2818
22b15758
UB
28192016-11-13 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2820
2821 PR c/35503
2822 * c-parser.c (c_parser_postfix_expression_after_primary): Call
2823 warn_for_restrict.
2824
84ff4775
LCW
28252016-09-11 Le-Chun Wu <lcwu@google.com>
2826 Mark Wielaard <mjw@redhat.com>
2827
2828 * c-decl.c (warn_if_shadowing): Use the warning code corresponding
2829 to the given -Wshadow= variant.
2830
4d0cdd0c
TP
28312016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
2832
2833 * c-typeck.c: Include memmodel.h.
2834
1202f33e
JJ
28352016-10-13 Jakub Jelinek <jakub@redhat.com>
2836
2837 PR target/77957
2838 * c-objc-common.h (LANG_HOOKS_GETDECLS): Use hook_tree_void_null
2839 instead of lhd_return_null_tree_v.
2840
8a14afd0
BS
28412016-10-07 Bernd Schmidt <bschmidt@redhat.com>
2842
2843 PR c++/69733
2844 * c-decl.c (smallest_type_quals_location): New static function.
2845 (grokdeclarator): Try to find the correct location for an ignored
2846 qualifier.
2847
81fea426
MP
28482016-09-26 Marek Polacek <polacek@redhat.com>
2849
2850 PR c/7652
2851 * c-decl.c (pop_scope): Add gcc_fallthrough.
2852
28532016-09-26 Marek Polacek <polacek@redhat.com>
2854
2855 PR c/7652
2856 * c-parser.c (struct c_token): Add flags field.
2857 (c_lex_one_token): Pass it to c_lex_with_flags.
2858 (c_parser_declaration_or_fndef): Turn __attribute__((fallthrough));
2859 into IFN_FALLTHROUGH.
2860 (c_parser_label): Set FALLTHROUGH_LABEL_P on labels. Handle
2861 attribute fallthrough after a case label or default label.
2862 (c_parser_statement_after_labels): Handle RID_ATTRIBUTE.
2863
9a2300e9
MP
28642016-09-24 Marek Polacek <polacek@redhat.com>
2865
2866 PR c/77490
2867 * c-typeck.c (build_unary_op): Warn about bit not on expressions that
2868 have boolean value. Warn about ++/-- on booleans.
2869
7de76362
JJ
28702016-09-23 Jakub Jelinek <jakub@redhat.com>
2871
2872 * c-parser.c (incomplete_record_decls): Remove unnecessary
2873 = vNULL initialization of file scope vec.
2874
5b73d2ab
MP
28752016-09-16 Marek Polacek <polacek@redhat.com>
2876
2877 * c-typeck.c (lvalue_p): Use true and false instead of 1 and 0.
2878
e51fbec3
MP
28792016-09-14 Marek Polacek <polacek@redhat.com>
2880
2881 * c-array-notation.c (create_cmp_incr): Use false instead of 0.
2882 (fix_array_notation_expr): Likewise.
2883 * c-decl.c (finish_decl): Likewise.
2884 * c-parser.c (c_parser_postfix_expression_after_primary): Likewise.
2885 * c-typeck.c (array_to_pointer_conversion): Use true instead of 1.
2886 (function_to_pointer_conversion): Use false instead of 0.
2887 (convert_lvalue_to_rvalue): Likewise.
2888 (parser_build_unary_op): Likewise.
2889 (build_atomic_assign): Likewise.
2890 (build_unary_op): Change nonconvert parameter type to bool, use
2891 true/false instead of 1/0.
2892 (build_binary_op): Use true instead of 1.
2893
254830ba
DM
28942016-09-13 David Malcolm <dmalcolm@redhat.com>
2895
2896 * c-parser.c (c_parser_declaration_or_fndef): Update for renaming
2897 of add_fixit_insert to add_fixit_insert_before.
2898
4c13ba17
MP
28992016-09-13 Marek Polacek <polacek@redhat.com>
2900
2901 * c-typeck.c (build_unary_op): Rename FLAG parameter to NOCONVERT. Use
2902 it.
2903
54dcdb88
BE
29042016-09-12 Bernd Edlinger <bernd.edlinger@hotmail.de>
2905
2906 PR c++/77496
2907 * c-parser.c (c_parser_conditional_expression): Pass the rightmost
2908 COMPOUND_EXPR to warn_for_omitted_condop.
2909
e5106e27
DM
29102016-09-07 David Malcolm <dmalcolm@redhat.com>
2911
2912 * c-lang.c (LANG_HOOKS_GET_SUBSTRING_LOCATION): Use
2913 c_get_substring_location for this new langhook.
2914
9dc5773f
JJ
29152016-09-02 Jakub Jelinek <jakub@redhat.com>
2916
2917 PR c/65467
2918 * c-parser.c (c_parser_declspecs): Don't sorry about _Atomic if
2919 flag_openmp.
2920 (c_parser_omp_variable_list): Use convert_lvalue_to_rvalue
2921 instead of mark_exp_read on low_bound/length expression.
2922 (c_parser_omp_clause_num_gangs, c_parser_omp_clause_num_threads,
2923 c_parser_omp_clause_num_tasks, c_parser_omp_clause_grainsize,
2924 c_parser_omp_clause_priority, c_parser_omp_clause_hint,
2925 c_parser_omp_clause_num_workers, c_parser_oacc_shape_clause,
2926 c_parser_oacc_clause_tile, c_parser_omp_clause_schedule,
2927 c_parser_omp_clause_vector_length, c_parser_omp_clause_num_teams,
2928 c_parser_omp_clause_thread_limit, c_parser_omp_clause_aligned,
2929 c_parser_omp_clause_linear, c_parser_omp_clause_safelen,
2930 c_parser_omp_clause_simdlen, c_parser_omp_clause_device,
2931 c_parser_omp_clause_dist_schedule): Use convert_lvalue_to_rvalue
2932 instead of mark_expr_read.
2933 (c_parser_omp_declare_reduction): Reject _Atomic qualified types.
2934 * c-objc-common.h (LANG_HOOKS_OMP_CLAUSE_COPY_CTOR,
2935 LANG_HOOKS_OMP_CLAUSE_ASSIGN_OP): Redefine.
2936 * c-tree.h (c_omp_clause_copy_ctor): New prototype.
2937 * c-typeck.c (handle_omp_array_sections_1): Diagnose _Atomic qualified
2938 array section bases outside of depend clause, for depend clause
2939 use convert_lvalue_to_rvalue on the base.
2940 (c_finish_omp_clauses): Reject _Atomic qualified vars in reduction,
2941 linear, aligned, map, to and from clauses.
2942 (c_omp_clause_copy_ctor): New function.
2943
295844f6
MP
29442016-09-01 Marek Polacek <polacek@redhat.com>
2945
2946 PR c/7652
2947 * c-typeck.c (composite_type): Add FALLTHRU comment.
2948
089af25c
DM
29492016-08-31 David Malcolm <dmalcolm@redhat.com>
2950
2951 * c-parser.c (c_parser_declaration_or_fndef): Add trailing space
2952 to the insertion fixits for "struct", "union", and "enum".
2953
f9087798
DM
29542016-08-30 David Malcolm <dmalcolm@redhat.com>
2955
2956 * c-decl.c (implicit_decl_warning): Use add_fixit_replace
2957 rather than add_fixit_misspelled_id.
2958 (undeclared_variable): Likewise.
2959 * c-parser.c (c_parser_declaration_or_fndef): Likewise. Remove
2960 now-redundant "here" params from add_fixit_insert method calls.
2961 (c_parser_parameter_declaration): Likewise.
2962 * c-typeck.c (build_component_ref): Remove now-redundant range
2963 param from add_fixit_replace method calls.
2964
ebef225f
MP
29652016-08-25 Marek Polacek <polacek@redhat.com>
2966
2967 * c-typeck.c (parser_build_binary_op): Pass LHS to
2968 warn_logical_not_parentheses.
2969
fe377a48
MP
29702016-08-25 Marek Polacek <polacek@redhat.com>
2971
2972 PR c/77323
2973 * c-decl.c (declspecs_add_type): Set typespec_word even when __intN
2974 or _FloatN or _FloatNx is not supported.
2975 (finish_declspecs): Set type to integer_type_node when _FloatN or
2976 _FloatNx is not supported.
2977
c65699ef
JM
29782016-08-19 Joseph Myers <joseph@codesourcery.com>
2979
2980 PR c/32187
2981 * c-tree.h (cts_floatn_nx): New enum c_typespec_keyword value.
2982 (struct c_declspecs): Add field floatn_nx_idx.
2983 * c-decl.c (declspecs_add_type, finish_declspecs): Handle _FloatN
2984 and _FloatNx type specifiers.
2985 * c-parser.c (c_keyword_starts_typename, c_token_starts_declspecs)
2986 (c_parser_declspecs, c_parser_attribute_any_word)
2987 (c_parser_objc_selector): Use CASE_RID_FLOATN_NX.
2988 * c-typeck.c (c_common_type): Handle _FloatN and _FloatNx types.
2989 (convert_arguments): Avoid promoting _FloatN and _FloatNx types
2990 narrower than double.
2991
2f1364c2
JJ
29922016-08-12 Jakub Jelinek <jakub@redhat.com>
2993 Martin Liska <mliska@suse.cz>
2994
2995 PR c/67410
2996 * c-typeck.c (set_nonincremental_init_from_string): Use / instead of
2997 % to determine val element to change. Assert that
2998 wchar_bytes * charwidth fits into val array.
2999
191816a3
MP
30002016-08-12 Marek Polacek <polacek@redhat.com>
3001
3002 PR c/7652
3003 * c-parser.c (c_parser_external_declaration): Add FALLTHRU.
3004 (c_parser_postfix_expression): Likewise.
3005 * c-typeck.c (build_unary_op): Adjust fall through comment.
3006 (c_mark_addressable): Likewise.
3007
b95a64bb
JJ
30082016-08-11 Jakub Jelinek <jakub@redhat.com>
3009
3010 PR c/72816
3011 * c-decl.c (grokdeclarator): When adding TYPE_DOMAIN for flexible
3012 array member through typedef, for orig_qual_indirect == 0 clear
3013 orig_qual_type.
3014
895aa8e1
DM
30152016-08-08 David Malcolm <dmalcolm@redhat.com>
3016
3017 PR c/64955
3018 * c-lang.c (LANG_HOOKS_RUN_LANG_SELFTESTS): If CHECKING_P, wire
3019 this up to selftest::run_c_tests.
3020 (selftest::run_c_tests): New function.
3021
0b212d8c
TS
30222016-08-04 Thomas Schwinge <thomas@codesourcery.com>
3023
ae9281fc
TS
3024 * c-parser.c (struct oacc_routine_data): Add error_seen and
3025 fndecl_seen members.
3026 (c_finish_oacc_routine): Use these.
3027 (c_parser_declaration_or_fndef): Adjust.
3028 (c_parser_oacc_routine): Likewise. Support more C language
3029 constructs, and improve diagnostics. Move pragma context
3030 checking...
3031 (c_parser_pragma): ... here.
3032
0b212d8c
TS
3033 * c-parser.c (struct oacc_routine_data): New.
3034 (c_parser_declaration_or_fndef, c_parser_oacc_routine): Use it.
3035 Simplify code.
3036 (c_finish_oacc_routine): Likewise. Don't attach clauses to "omp
3037 declare target" attribute.
3038
76e2c821
JB
30392016-08-01 Jan Beulich <jbeulich@suse.com>
3040
3041 * c-fold.c (c_fully_fold_internal): Also emit shift count
3042 warnings for vector types.
3043 * c-typeck.c (build_binary_op): Likewise.
3044
f618a472
MP
30452016-07-29 Marek Polacek <polacek@redhat.com>
3046
3047 PR c/71742
3048 * c-decl.c (finish_struct): Rephrase an error message.
3049
efd0786f
MP
3050 PR c/71853
3051 * c-parser.c (c_parser_switch_statement): Initialize ce.original_type
3052 to error node for invalid code.
3053
e00dceaf
MP
3054 PR c/71573
3055 * c-decl.c (implicitly_declare): Return decl early not only for
3056 error_mark_nodes, but for anything that is not a FUNCTION_DECL.
3057
673a107a
JJ
30582016-07-29 Jakub Jelinek <jakub@redhat.com>
3059
3060 PR c/71969
3061 * c-decl.c (finish_function): Only set DECL_DISREGARD_INLINE_LIMITS
3062 on GNU extern inline functions.
3063
a5b5c8b6
MP
30642016-07-29 Marek Polacek <polacek@redhat.com>
3065
3066 PR c/71583
3067 * c-parser.c (c_parser_postfix_expression_after_paren_type): Also
3068 check expr.value.
3069
e3fe09c1
UB
30702016-07-22 Uros Bizjak <ubizjak@gmail.com>
3071
3072 * c-typeck.c: Use HOST_WIDE_INT_1 instead of (HOST_WIDE_INT) 1,
3073
7c8f7eaa
DM
30742016-07-20 David Malcolm <dmalcolm@redhat.com>
3075
3076 * c-decl.c (struct edit_distance_traits<cpp_hashnode *>): Move to
3077 spellcheck-tree.h
3078 (best_macro_match): Likewise, converting from a typedef to a
3079 subclass.
3080 (find_closest_macro_cpp_cb): Move to spellcheck-tree.c.
3081 (lookup_name_fuzzy): Update for change of best_macro_match to a
3082 subclass with a ctor that calls cpp_forall_identifiers.
3083
de6a69ee
DM
30842016-07-20 David Malcolm <dmalcolm@redhat.com>
3085
3086 * c-decl.c (implicit_decl_warning): Update for conversion of
3087 return type of lookup_name_fuzzy to const char *.
3088 (undeclared_variable): Likewise.
3089 (lookup_name_fuzzy): Convert return type from tree to
3090 const char *.
3091 * c-parser.c (c_parser_declaration_or_fndef): Update for
3092 conversion of return type of lookup_name_fuzzy to const char *.
3093 (c_parser_parameter_declaration): Likewise.
3094
b1c9c068
CP
30952016-07-15 Cesar Philippidis <cesar@codesourcery.com>
3096
3097 * c-parser.c (c_parser_oacc_declare): Don't scan for
3098 GOMP_MAP_POINTER.
3099 * c-typeck.c (handle_omp_array_sections): Mark data clauses with
3100 GOMP_MAP_FORCE_{PRESENT,TO,FROM,TOFROM} as potentially having
3101 zero-length subarrays.
3102
ddbbcb19
JJ
31032016-07-15 Jakub Jelinek <jakub@redhat.com>
3104
3105 PR c/71858
3106 * c-decl.c (implicit_decl_warning): Use FUZZY_LOOKUP_FUNCTION_NAME
3107 instead of FUZZY_LOOKUP_NAME.
3108 (lookup_name_fuzzy): For FUZZY_LOOKUP_FUNCTION_NAME consider
3109 FUNCTION_DECLs, {VAR,PARM}_DECLs function pointers and macros.
3110
dd36b877
JJ
31112016-07-14 Jakub Jelinek <jakub@redhat.com>
3112
3113 PR c/71858
3114 * c-decl.c (lookup_name_fuzzy): Ignore binding->invisible.
3115
8c681247
TS
31162016-07-12 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
3117
3118 * c-parser.c (c_parser_generic_selection): Make type of variable
3119 auto_vec.
3120 (c_parser_omp_declare_simd): Likewise.
3121
bf4fa671
TS
31222016-07-12 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
3123
3124 * c-decl.c (struct c_struct_parse_info): Change member types
3125 from vec to auto_vec.
3126 (start_struct): Adjust.
3127 (finish_struct): Likewise.
3128
557e8c49
JJ
31292016-07-02 Jakub Jelinek <jakub@redhat.com>
3130
3131 PR c/71719
3132 * c-typeck.c (mark_exp_read): Handle VIEW_CONVERT_EXPR.
3133
54d19c3b
TS
31342016-06-29 Thomas Schwinge <thomas@codesourcery.com>
3135
3136 * c-parser.c (c_parser_pragma) <PRAGMA_OMP_CANCELLATION_POINT>:
3137 Move pragma context checking into...
3138 (c_parser_omp_cancellation_point): ... here, and improve
3139 diagnostic messages.
3140 * c-typeck.c (c_finish_omp_cancel)
3141 (c_finish_omp_cancellation_point): Improve diagnostic messages.
3142
152ef731
JJ
31432016-06-29 Jakub Jelinek <jakub@redhat.com>
3144
3145 PR c/71685
3146 * c-typeck.c (c_build_qualified_type): Don't clear
3147 C_TYPE_INCOMPLETE_VARS for the main variant.
3148
31492016-06-28 Martin Sebor <msebor@redhat.com>
4378d117
MS
3150
3151 PR c/71552
3152 * c-typeck.c (output_init_element): Diagnose incompatible types
3153 before non-constant initializers.
3154
e9ac1f86
JJ
31552016-06-28 Jakub Jelinek <jakub@redhat.com>
3156
3157 * Make-lang.in: Don't cat ../stage_current if it does not exist.
3158
277d7ee0
AK
31592016-06-23 Andi Kleen <ak@linux.intel.com>
3160
3161 * Make-lang.in: Add support for autofdo.
3162
1a4f11c8
DM
31632016-06-22 David Malcolm <dmalcolm@redhat.com>
3164
3165 PR c/70339
3166 * c-decl.c: Include spellcheck-tree.h and gcc-rich-location.h.
3167 (implicit_decl_warning): When issuing warnings for implicit
3168 declarations, attempt to provide a suggestion via
3169 lookup_name_fuzzy.
3170 (undeclared_variable): Likewise when issuing errors.
3171 (lookup_name_in_scope): Likewise.
3172 (struct edit_distance_traits<cpp_hashnode *>): New struct.
3173 (best_macro_match): New typedef.
3174 (find_closest_macro_cpp_cb): New function.
3175 (lookup_name_fuzzy): New function.
3176 * c-parser.c: Include gcc-rich-location.h.
3177 (c_token_starts_typename): Split out case CPP_KEYWORD into...
3178 (c_keyword_starts_typename): ...this new function.
3179 (c_parser_declaration_or_fndef): When issuing errors about
3180 missing "struct" etc, add a fixit. For other kinds of errors,
3181 attempt to provide a suggestion via lookup_name_fuzzy.
3182 (c_parser_parms_declarator): When looking ahead to detect typos in
3183 type names, also reject CPP_KEYWORD.
3184 (c_parser_parameter_declaration): When issuing errors about
3185 unknown type names, attempt to provide a suggestion via
3186 lookup_name_fuzzy.
3187 * c-tree.h (c_keyword_starts_typename): New prototype.
3188
5a578671
JM
31892016-06-20 Joseph Myers <joseph@codesourcery.com>
3190
3191 PR c/71601
3192 * c-typeck.c (build_conditional_expr): Return error_mark_node if
3193 c_common_type returns error_mark_node.
3194
3f8257db 31952016-06-19 Martin Sebor <msebor@redhat.com>
aa0db437
MS
3196
3197 PR c/69507
3198 * c-parser.c (c_parser_alignof_expression): Avoid diagnosing
3199 __alignof__ (expression).
3200
6a3f203c
DM
32012016-06-14 David Malcolm <dmalcolm@redhat.com>
3202
3203 * c-typeck.c: Include spellcheck-tree.h rather than spellcheck.h.
3204
264757fb
DM
32052016-06-14 David Malcolm <dmalcolm@redhat.com>
3206
3207 * c-typeck.c (build_component_ref): Simplify fixit code by
3208 using gcc_rich_location::add_fixit_misspelled_id.
3209 (set_init_label): Likewise.
3210
f7e4f2e3
DM
32112016-06-13 David Malcolm <dmalcolm@redhat.com>
3212
3213 * c-parser.c (c_parser_initelt): Provide location of name for new
3214 location_t param of set_init_label.
3215 * c-tree.h (set_init_label): Add location_t param.
3216 * c-typeck.c (set_init_index): Add "fieldname_loc" location_t
3217 param and use it when issuing error messages about unrecognized
3218 field names. Attempt to provide a fixit hint if appropriate,
3219 otherwise update the error message to provide the type name.
3220
4b1ffdb1
TS
32212016-06-10 Thomas Schwinge <thomas@codesourcery.com>
3222
3223 PR c/71381
3224 * c-parser.c (c_parser_omp_variable_list) <OMP_CLAUSE__CACHE_>:
3225 Loosen checking.
3226
44a845ca
MS
32272016-06-08 Martin Sebor <msebor@redhat.com>
3228 Jakub Jelinek <jakub@redhat.com>
3229
3230 PR c++/70507
3231 PR c/68120
3232 * c-typeck.c (convert_arguments): Don't promote last argument
3233 of BUILT_IN_{ADD,SUB,MUL}_OVERFLOW_P.
3234
92a5f2ba
MP
32352016-06-08 Marek Polacek <polacek@redhat.com>
3236
3237 PR c/71418
3238 * c-decl.c (grokdeclarator): Check TYPE_P.
3239
08203f73
MP
3240 PR c/71426
3241 * c-decl.c (get_parm_info): Don't crash on an assert on invalid
3242 code.
3243
6ffd47b7
DM
32442016-06-07 David Malcolm <dmalcolm@redhat.com>
3245
3246 * c-parser.c (c_parser_postfix_expression): In __builtin_offsetof
3247 and structure element reference, capture the location of the
3248 element name token and pass it to build_component_ref.
3249 (c_parser_postfix_expression_after_primary): Likewise for
3250 structure element dereference.
3251 (c_parser_omp_variable_list): Likewise for
3252 OMP_CLAUSE_{_CACHE, MAP, FROM, TO},
3253 * c-tree.h (build_component_ref): Add location_t param.
3254 * c-typeck.c (build_component_ref): Add location_t param
3255 COMPONENT_LOC. Use it, if available, when issuing hints about
3256 mispelled member names to provide a fixit replacement hint.
3257
1f40cff3
MP
32582016-06-06 Marek Polacek <polacek@redhat.com>
3259
3260 PR c/71362
3261 * c-parser.c (c_parser_direct_declarator): Set location.
3262
5545a907
MP
32632016-06-06 Marek Polacek <polacek@redhat.com>
3264
3265 * c-typeck.c (comptypes_internal): Handle comparisons of
3266 INTEGER_TYPE, FIXED_POINT_TYPE, and REAL_TYPE nodes. Don't check
3267 TYPE_REF_CAN_ALIAS_ALL.
3268
b605f663
CLT
32692016-06-03 Chung-Lin Tang <cltang@codesourcery.com>
3270
3271 * c-typeck.c (c_finish_omp_clauses): Mark OpenACC reduction
3272 arguments as addressable when async clause exists.
3273
00631022
JJ
32742016-05-30 Jakub Jelinek <jakub@redhat.com>
3275
3276 PR c++/71349
3277 * c-parser.c (c_parser_omp_for): Don't disallow nowait clause
3278 when combined with target construct.
3279
7211a097
JJ
32802016-05-26 Jakub Jelinek <jakub@redhat.com>
3281
3282 * c-parser.c (c_parser_omp_clause_schedule): Warn if
3283 OMP_CLAUSE_SCHEDULE_CHUNK_EXPR is known not to be positive.
3284
95efe6b6
MP
32852016-05-25 Marek Polacek <polacek@redhat.com>
3286
3287 PR c/71265
3288 * c-decl.c (c_make_fname_decl): Don't check seen_error.
3289
a23faf7a
MP
3290 PR c/71266
3291 * c-decl.c (store_parm_decls_oldstyle): Skip non-PARM_DECLs.
3292
e46c7770
CP
32932016-05-24 Cesar Philippidis <cesar@codesourcery.com>
3294
3295 * c-parser.c (c_parser_oacc_declare): Add support for
3296 GOMP_MAP_FIRSTPRIVATE_POINTER.
3297 * c-typeck.c (handle_omp_array_sections_1): Replace bool is_omp
3298 argument with enum c_omp_region_type ort.
3299 (handle_omp_array_sections): Likewise. Update call to
3300 handle_omp_array_sections_1.
3301 (c_finish_omp_clauses): Add specific errors and warning messages for
3302 OpenACC. Use firsrtprivate pointers for OpenACC subarrays. Update
3303 call to handle_omp_array_sections.
3304
a04e69c0
TS
33052016-05-24 Thomas Schwinge <thomas@codesourcery.com>
3306
3307 * c-parser.c (c_parser_oacc_routine): Tighten syntax checks.
3308
f17a223d
RB
33092016-05-24 Richard Biener <rguenther@suse.de>
3310
3311 PR middle-end/70434
3312 PR c/69504
3313 * c-typeck.c (build_array_ref): Do not complain about indexing
3314 non-lvalue vectors. Adjust for function name change.
3315
79063edd
MS
33162016-05-20 Martin Sebor <msebor@redhat.com>
3317
3318 PR c/71115
3319 * c-typeck.c (error_init): Use
3320 expansion_point_location_if_in_system_header.
3321 (warning_init): Same.
3322
8a40fef3
DM
33232016-05-19 David Malcolm <dmalcolm@redhat.com>
3324
3325 PR c/71171
3326 * c-parser.c (c_parser_generic_selection): Use c_expr::set_error
3327 in error-handling.
3328 (c_parser_postfix_expression): Likewise.
3329 * c-tree.h (c_expr::set_error): New method.
3330 * c-typeck.c (parser_build_binary_op): In error-handling, ensure
3331 that result's range is initialized.
3332
e9892350
JG
33332016-05-17 James Greenhalgh <james.greenhalgh@arm.com>
3334
3335 * c-typeck.c (parser_build_unary_op): Fix formatting.
3336
8fad45f5
MW
33372016-05-16 Matthew Wahab <matthew.wahab@arm.com>
3338
3339 * c-decl.c (grokdeclarator): Remove errmsg and use of
3340 targetm.invalid_return_type.
3341 (grokparms): Remove errmsg and use of
3342 targetm.invalid_parameter_type.
3343
aa4b467b
JM
33442016-05-13 Joseph Myers <joseph@codesourcery.com>
3345
3346 * c-decl.c (grokdeclarator): For C11, discard qualifiers on
3347 function return type.
3348
4f2e1536
MP
33492016-05-12 Marek Polacek <polacek@redhat.com>
3350
3351 PR c/70756
3352 * c-decl.c (build_compound_literal): Pass LOC down to
3353 c_incomplete_type_error.
3354 * c-tree.h (require_complete_type): Adjust declaration.
3355 (c_incomplete_type_error): Likewise.
3356 * c-typeck.c (require_complete_type): Add location parameter, pass it
3357 down to c_incomplete_type_error.
3358 (c_incomplete_type_error): Add location parameter, pass it down to
3359 error_at.
3360 (build_component_ref): Pass location down to c_incomplete_type_error.
3361 (default_conversion): Pass location down to require_complete_type.
3362 (build_array_ref): Likewise.
3363 (build_function_call_vec): Likewise.
3364 (convert_arguments): Likewise.
3365 (build_unary_op): Likewise.
3366 (build_c_cast): Likewise.
3367 (build_modify_expr): Likewise.
3368 (convert_for_assignment): Likewise.
3369 (c_finish_omp_clauses): Likewise.
3370
d6e83a8d
MM
33712016-05-11 Mikhail Maltsev <maltsevm@gmail.com>
3372
3373 PR c/43651
3374 * c-decl.c (declspecs_add_qual): Warn when -Wduplicate-decl-specifier
3375 is enabled.
3376 * c-errors.c (pedwarn_c90): Return true if warned.
3377 * c-tree.h (pedwarn_c90): Change return type to bool.
3378 (enum c_declspec_word): Add new enumerator cdw_atomic.
3379
5c3a10fb
MP
33802016-05-11 Marek Polacek <polacek@redhat.com>
3381
3382 PR c++/71024
3383 * c-decl.c (diagnose_mismatched_decls): Factor out code to
3384 diagnose_mismatched_attributes and call it.
3385
cf68d92c
MP
33862016-05-10 Marek Polacek <polacek@redhat.com>
3387
3388 PR c/70255
3389 * c-decl.c (diagnose_mismatched_decls): Warn for optimize attribute
3390 on a declaration following the definition.
3391
351f85c5
JJ
33922016-05-05 Jakub Jelinek <jakub@redhat.com>
3393
3394 * c-parser.c (c_parser_switch_statement): Add IF_P argument,
3395 parse it through to c_parser_c99_block_statement.
3396 (c_parser_statement_after_labels): Adjust c_parser_switch_statement
3397 caller.
3398
deef7113
MP
33992016-05-04 Marek Polacek <polacek@redhat.com>
3400
3401 * c-parser.c (c_parser_if_statement): Replace OPT_Wparentheses with
3402 OPT_Wdangling_else.
3403
de55efd5
MP
34042016-05-04 Marek Polacek <polacek@redhat.com>
3405
3406 PR c/48778
3407 * c-typeck.c (build_binary_op): Don't issue -Waddress warnings
3408 for macro expansions.
3409
79ce98bc
MP
34102016-05-03 Marek Polacek <polacek@redhat.com>
3411
3412 PR c/70859
3413 * c-typeck.c (build_function_call_vec): Pass LOC and ARG_LOC down to
3414 check_builtin_function_arguments.
3415
fb2647aa
RB
34162016-05-03 Richard Biener <rguenther@suse.de>
3417
3418 * Make-lang.in (cc1-checksum.c): For stage-final re-use
3419 the checksum from the previous stage.
3420
77886428
CP
34212016-05-02 Cesar Philippidis <cesar@codesourcery.com>
3422
3423 * c-parser.c (c_parser_oacc_all_clauses): Update call to
3424 c_finish_omp_clauses.
3425 (c_parser_omp_all_clauses): Likewise.
3426 (c_parser_oacc_cache): Likewise.
3427 (c_parser_oacc_loop): Likewise.
3428 (omp_split_clauses): Likewise.
3429 (c_parser_omp_declare_target): Likewise.
3430 (c_parser_cilk_all_clauses): Likewise.
3431 (c_parser_cilk_for): Likewise.
3432 * c-typeck.c (c_finish_omp_clauses): Replace bool arguments
3433 is_omp, declare_simd, and is_cilk with enum c_omp_region_type ort.
3434
7176a4a0
MP
34352016-05-02 Marek Polacek <polacek@redhat.com>
3436
3437 PR c/70851
3438 * c-decl.c (grokdeclarator): Diagnose when array's size has an
3439 incomplete type.
3440
e7ff0319
CP
34412016-04-29 Cesar Philippidis <cesar@codesourcery.com>
3442
3443 PR middle-end/70626
3444 * c-parser.c (c_parser_oacc_loop): Don't augment mask with
3445 OACC_LOOP_CLAUSE_MASK.
3446 (c_parser_oacc_kernels_parallel): Update call to
3447 c_oacc_split_loop_clauses.
3448
9f405ce1
AM
34492016-04-28 Andrew MacLeod <amacleod@redhat.com>
3450
3451 * c-array-notation.c (fix_builtin_array_notation_fn): Fix final
3452 argument to build_modify_expr in two cases.
3453
c1e1f433
BS
34542016-04-27 Bernd Schmidt <bschmidt@redhat.com>
3455
3456 * c-parser.c (c_parser_postfix_expression_after_primary): Call
3457 warn_for_memset instead of warning directly here.
3458
2448a956
MP
34592016-04-26 Marek Polacek <polacek@redhat.com>
3460
3461 PR c/67784
3462 * c-parser.c (c_parser_maybe_reclassify_token): New function factored
3463 out of ...
3464 (c_parser_for_statement): ... here.
3465 (c_parser_if_statement): Use it.
3466 (c_parser_switch_statement): Use it.
3467 (c_parser_while_statement): Use it.
3468
b02a5e26
MP
3469 PR c/70791
3470 * c-decl.c (pushdecl): Pass LOCUS down to warning.
3471
477d4906
IV
34722016-04-20 Ilya Verbin <ilya.verbin@intel.com>
3473
3474 PR c++/69363
3475 * c-parser.c (c_parser_cilk_all_clauses): Use c_finish_omp_clauses
3476 instead of c_finish_cilk_clauses.
3477 * c-tree.h (c_finish_omp_clauses): Add new default argument.
3478 * c-typeck.c (c_finish_omp_clauses): Add new argument. Allow
3479 floating-point variables in the linear clause for Cilk Plus.
3480
fe37c7af
MM
34812016-04-18 Michael Matz <matz@suse.de>
3482
3483 * c-decl.c (merge_decls): Use SET_DECL_ALIGN and SET_TYPE_ALIGN.
3484 (grokdeclarator, parser_xref_tag, finish_enum): Use SET_TYPE_ALIGN.
3485
949505a9
MP
34862016-04-15 Marek Polacek <polacek@redhat.com>
3487
3488 PR c/70671
3489 * c-typeck.c (build_unary_op): Pass location down to error and
3490 warning call.
3491
dda1bf61
JJ
34922016-04-15 Jakub Jelinek <jakub@redhat.com>
3493
3494 PR c/70436
3495 * c-parser.c (c_parser_pragma): Add IF_P argument, pass it down
3496 where needed.
3497 (c_parser_external_declaration, c_parser_struct_or_union_specifier,
3498 c_parser_parameter_declaration, c_parser_compound_statement_nostart,
3499 c_parser_objc_class_instance_variables, c_parser_objc_methodprotolist):
3500 Adjust c_parser_pragma callers.
3501 (c_parser_statement_after_labels): Likewise. Adjust c_parser_cilk_for
3502 caller.
3503 (c_parser_omp_structured_block): Add IF_P argument, pass it down to
3504 c_parser_statement.
3505 (c_parser_oacc_data, c_parser_oacc_host_data, c_parser_oacc_loop,
3506 c_parser_oacc_kernels_parallel, c_parser_omp_critical,
3507 c_parser_omp_simd, c_parser_omp_for, c_parser_omp_master,
3508 c_parser_omp_ordered, c_parser_omp_parallel, c_parser_omp_single,
3509 c_parser_omp_task, c_parser_omp_taskgroup, c_parser_omp_distribute,
3510 c_parser_omp_teams, c_parser_omp_target_data, c_parser_omp_target,
3511 c_parser_omp_taskloop, c_parser_omp_construct, c_parser_cilk_grainsize,
3512 c_parser_cilk_simd, c_parser_cilk_for): Add IF_P argument, pass it
3513 down where needed.
3514 (c_parser_omp_for_loop): Likewise. Clear IF_P if nbraces.
3515 (c_parser_omp_sections_scope): Adjust c_parser_omp_structured_block
3516 calls.
3517
99cd9857
MP
35182016-04-13 Marek Polacek <polacek@redhat.com>
3519
3520 PR c/70436
3521 * c-parser.c (c_parser_statement_after_labels): Add IF_P argument and
3522 adjust callers.
3523 (c_parser_statement): Likewise.
3524 (c_parser_c99_block_statement): Likewise.
3525 (c_parser_while_statement): Likewise.
3526 (c_parser_for_statement): Likewise.
3527 (c_parser_if_body): Don't set IF_P here.
3528 (c_parser_if_statement): Add IF_P argument. Set IF_P here. Warn
3529 about dangling else here.
3530 * c-tree.h (c_finish_if_stmt): Adjust declaration.
3531 * c-typeck.c (c_finish_if_stmt): Remove NESTED_IF parameter. Don't
3532 warn about dangling else here.
3533
f13355da
MP
35342016-04-04 Marek Polacek <polacek@redhat.com>
3535
3536 PR c/70307
3537 * c-fold.c (c_fully_fold_internal): Handle VEC_COND_EXPR.
3538
5fde6a45
MP
35392016-03-31 Marek Polacek <polacek@redhat.com>
3540
3541 PR c/70297
3542 * c-decl.c (merge_decls): Also set TYPE_ALIGN and TYPE_USER_ALIGN.
3543
4bbf545b
DM
35442016-03-18 David Malcolm <dmalcolm@redhat.com>
3545
3546 PR c/70281
3547 * c-parser.c (c_parser_postfix_expression): Set the source range
3548 for uses of "__builtin_types_compatible_p".
3549
fcc2b74f
JJ
35502016-03-17 Jakub Jelinek <jakub@redhat.com>
3551
3552 PR c/70280
3553 * c-typeck.c (composite_type): Don't count void_list_node
3554 into len, if the list is terminated by void_list_node, start
3555 with void_list_node instead of NULL for newargs. Stop
3556 at void_list_node.
3557
ab4c578f
MP
35582016-03-16 Marek Polacek <polacek@redhat.com>
3559
3560 PR c/70093
3561 * c-typeck.c (build_function_call_vec): Create a TARGET_EXPR for
3562 nested functions returning VM types.
3563
96b3c82d
CP
35642016-03-09 Cesar Philippidis <cesar@codesourcery.com>
3565
3566 * c-parser.c (c_parser_oacc_loop): Update cclauses and clauses
3567 when calling c_finish_omp_clauses.
3568
29b9828f
BS
35692016-03-04 Bernd Schmidt <bschmidt@redhat.com>
3570
3571 PR c/69824
3572 * c-decl.c (get_parm_info): Don't queue implicit function declarations
3573 for later.
3574
7ff6ca38
MP
35752016-03-04 Marek Polacek <polacek@redhat.com>
3576
3577 PR c/69798
3578 * c-parser.c (c_parser_postfix_expression): Call
3579 c_parser_cast_expression rather than c_parser_postfix_expression.
3580
686e2237
JJ
35812016-03-01 Jakub Jelinek <jakub@redhat.com>
3582
3583 PR c/69796
3584 PR c/69974
3585 * c-parser.c (c_parser_translation_unit): Don't change TREE_TYPE
3586 of incomplete decls to error_mark_node.
3587
0b05329b
MP
35882016-02-24 Marek Polacek <polacek@redhat.com>
3589
3590 PR c/69819
3591 * c-decl.c (finish_decl): Don't update the copy of the type of a
3592 different decl type.
3593
067fbd8b
JJ
35942016-02-23 Jakub Jelinek <jakub@redhat.com>
3595
3596 PR objc/69844
3597 * c-parser.c (c_parser_for_statement): Properly handle ObjC classes
3598 in id_kind reclassification.
3599
bf14eba2
JJ
36002016-02-16 Jakub Jelinek <jakub@redhat.com>
3601
3602 PR c/69835
3603 * c-typeck.c (build_binary_op): Revert 2015-09-09 change.
3604
ba539195
JN
36052016-02-16 James Norris <jnorris@codesourcery.com>
3606
3607 PR c/64748
3608 * c-parser.c (c_parser_oacc_data_clause_deviceptr): Allow parms.
3609
16595a1f
BS
36102016-02-12 Bernd Schmidt <bschmidt@redhat.com>
3611
f48dfe98
BS
3612 * c-decl.c (build_null_declspecs): Zero the entire struct.
3613
16595a1f
BS
3614 PR c/69522
3615 * c-parser.c (c_parser_braced_init): New arg outer_obstack. All
3616 callers changed. If nested_p is true, use it to call
3617 finish_implicit_inits.
3618 * c-tree.h (finish_implicit_inits): Declare.
3619 * c-typeck.c (finish_implicit_inits): New function. Move code
3620 from ...
3621 (push_init_level): ... here.
3622 (set_designator, process_init_element): Call finish_implicit_inits.
3623
66756373
JJ
36242016-02-11 Jakub Jelinek <jakub@redhat.com>
3625
3626 PR c/69768
3627 * c-typeck.c (parser_build_binary_op): Strip nops from integer_zerop
3628 arguments for -Waddress warning.
3629
1066e9b5
JJ
36302016-02-04 Jakub Jelinek <jakub@redhat.com>
3631
3632 PR c/69669
3633 * c-decl.c (finish_enum): When honoring mode attribute,
3634 make sure to use proper TYPE_MIN_VALUE and TYPE_MAX_VALUE.
3635
3a5d2ba4
JJ
36362016-01-29 Jakub Jelinek <jakub@redhat.com>
3637
3638 PR debug/69518
3639 * c-decl.c (finish_struct): Clear C_TYPE_INCOMPLETE_VARS in
3640 all type variants, not just TYPE_MAIN_VARIANT.
3641
cbdd8ae0
JJ
36422016-01-27 Jakub Jelinek <jakub@redhat.com>
3643
3644 PR debug/66869
3645 * c-decl.c (c_write_global_declarations_1): Warn with
3646 warn_unused_function if static prototype without definition
3647 is not C_DECL_USED.
3648
fa74a4bc
MP
36492016-01-27 Marek Polacek <polacek@redhat.com>
3650
3651 PR c/68062
3652 * c-typeck.c (build_binary_op) [EQ_EXPR, GE_EXPR]: Promote operand
3653 to unsigned, if needed. Add -Wsign-compare warning.
3654
13f92e8d
JJ
36552016-01-26 Jakub Jelinek <jakub@redhat.com>
3656
3657 PR tree-optimization/69483
3658 * c-parser.c (c_parser_translation_unit): Use FOR_EACH_VEC_ELT.
3659
cd8e73dc 36602016-01-20 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
d25c7690
PK
3661
3662 PR c/24293
3663 * c-tree.h (incomplete_record_decls): Declare.
3664 * c-parser.c (incomplete_record_decls): Define.
3665 (c_parser_translation_unit): Iterate through incomplete_record_decls and
3666 report error if any decl has zero size.
3667 * c-decl.c (finish_decl): Append static decl with incomplete struct/union
3668 or enum type to incomplete_record_decls.
3669
e6d6ec9e
TV
36702016-01-14 Tom de Vries <tom@codesourcery.com>
3671
3672 PR tree-optimization/68773
3673 * c-parser.c (c_parser_oacc_declare, c_parser_omp_declare_target): Don't
3674 set force_output.
3675
00083992
MP
36762016-01-14 Marek Polacek <polacek@redhat.com>
3677
3678 PR c/69262
3679 * c-decl.c (grokdeclarator): Provide more information for invalid
3680 array declarations.
3681
7443cf13
DM
36822016-01-06 David Malcolm <dmalcolm@redhat.com>
3683
3684 * c-parser.c (c_parser_unary_expression): For dereferences, build
3685 a combined location before calling build_indirect_ref, so that
3686 error reports cover the full range, manually updating the c_expr
3687 src_range.
3688
6b131d5b
MP
36892016-01-06 Marek Polacek <polacek@redhat.com>
3690
3691 PR sanitizer/69099
3692 * c-convert.c (convert) [INTEGER_TYPE]: Drop ARG. Don't pass ARG to
3693 ubsan_instrument_float_cast. Fold EXPR. Use NULL_TREE instead of
3694 NULL.
3695
818ab71a
JJ
36962016-01-04 Jakub Jelinek <jakub@redhat.com>
3697
3698 Update copyright years.
3699
2fe0a208
MP
37002016-01-04 Marek Polacek <polacek@redhat.com>
3701
3702 PR c/68908
3703 * c-typeck.c (build_atomic_assign): Improve commentary. Add
3704 optimization to use __atomic_fetch_* built-in if possible.
3705
c7b48c8a
TS
37062015-12-23 Thomas Schwinge <thomas@codesourcery.com>
3707
3708 * c-parser.c (c_parser_oacc_clause_use_device): Merge function
3709 into...
3710 (c_parser_omp_clause_use_device_ptr): ... this function. Adjust
3711 all users.
3712
fda5652f
MP
37132015-12-22 Marek Polacek <polacek@redhat.com>
3714
3715 PR c/69002
3716 * c-typeck.c (build_component_ref): Warn when acessing elements of
3717 atomic structures or unions.
3718
745e411d
DM
37192015-12-21 David Malcolm <dmalcolm@redhat.com>
3720
3721 * c-typeck.c: Include "gcc-rich-location.h".
3722 (build_binary_op): In the two places that call binary_op_error,
3723 create a gcc_rich_location and populate it with the location of
3724 the binary op and its two operands.
3725
94c40e19
DM
37262015-12-16 David Malcolm <dmalcolm@redhat.com>
3727
3728 * c-parser.c (c_parser_statement_after_labels): When calling
3729 c_finish_return, Use the return expression's location if it has
3730 one, falling back to the location of the first token within it.
3731 * c-typeck.c (c_finish_return): When issuing warnings about
3732 the incorrect presence/absence of a return value, issue a note
3733 showing the declaration of the function.
3734
de67c4c3
DM
37352015-12-16 David Malcolm <dmalcolm@redhat.com>
3736
3737 * c-parser.c (struct c_parser): Expand array "tokens_buf" from 2
3738 to 4.
3739 (c_parser_peek_nth_token): New function.
3740 (c_parser_peek_conflict_marker): New function.
3741 (c_parser_error): Detect conflict markers and report them as such.
3742
a10704e1
DM
37432015-12-16 David Malcolm <dmalcolm@redhat.com>
3744
3745 * c-parser.c (c_parser_postfix_expression): Use EXPR_LOC_OR_LOC
3746 to preserve range information for the primary expression
3747 in the call to c_parser_postfix_expression_after_primary.
3748
8062bca6
DM
37492015-12-16 David Malcolm <dmalcolm@redhat.com>
3750
3751 * c-parser.c (c_parser_static_assert_declaration_no_semi): Use the
3752 expression location, falling back on the first token location,
3753 rather than always using the latter.
3754
d06f8b75
MP
37552015-12-16 Marek Polacek <polacek@redhat.com>
3756
3757 PR c/64637
3758 * c-typeck.c (c_process_expr_stmt): Use location of the expression if
3759 available.
3760
2994fb91
MP
37612015-12-15 Marek Polacek <polacek@redhat.com>
3762
3763 PR c/68907
3764 * c-typeck.c (build_atomic_assign): Set TREE_NO_WARNING on an
3765 artificial decl.
3766
a1b93f8d
DM
37672015-12-08 David Malcolm <dmalcolm@redhat.com>
3768
3769 * c-parser.c (c_parser_alignof_expression): Capture location of
3770 closing parenthesis (if any), or of end of unary expression, and
3771 use it to build a src_range for the expression.
3772
46c6e1e2
DM
37732015-12-08 David Malcolm <dmalcolm@redhat.com>
3774
3775 PR c/68757
3776 * c-parser.c (c_parser_get_builtin_args): Add
3777 "out_close_paren_loc" param, and write back to it.
3778 (c_parser_postfix_expression): Capture the closing
3779 parenthesis location for RID_CHOOSE_EXPR,
3780 RID_BUILTIN_CALL_WITH_STATIC_CHAIN, RID_BUILTIN_COMPLEX,
3781 RID_BUILTIN_SHUFFLE and use it to set the source range
3782 for such expressions; within RID_BUILTIN_COMPLEX set
3783 the underlying location.
3784
66189108
MP
37852015-12-07 Marek Polacek <polacek@redhat.com>
3786
3787 PR c/68668
3788 * c-decl.c (grokdeclarator): If ORIG_QUAL_INDIRECT is indirect, use
3789 TREE_TYPE of ORIG_QUAL_TYPE, otherwise decrement ORIG_QUAL_INDIRECT.
3790
f187980b
EB
37912015-12-04 Eric Botcazou <ebotcazou@adacore.com>
3792
3793 * c-tree.h (c_build_va_arg): Adjust prototype.
3794 * c-parser.c (c_parser_postfix_expression): Adjust call to above.
3795 * c-typeck.c (c_build_va_arg): Rename LOC parameter to LOC2, add LOC1
3796 parameter, adjust throughout and issue an error if EXPR is a component
3797 with reverse storage order.
3798
4250754e
JM
37992015-12-02 Jason Merrill <jason@redhat.com>
3800
3801 * c-fold.c (c_disable_warnings, c_enable_warnings, c_fully_fold)
3802 (c_fully_fold_internal, decl_constant_value_for_optimization):
3803 Move from c-common.c.
3804 * c-tree.h: Declare decl_constant_value_for_optimization.
3805 * Make-lang.in (C_AND_OBJC_OBJS): Add c-fold.o.
3806
e9e32ee6
JM
38072015-12-02 Joseph Myers <joseph@codesourcery.com>
3808
3809 PR c/68162
3810 * c-decl.c (grokdeclarator): Set first_non_attr_kind before
3811 following link from declarator to next declarator. Track original
3812 qualified type and pass it to c_build_qualified_type.
3813 * c-typeck.c (c_build_qualified_type): Add arguments
3814 orig_qual_type and orig_qual_indirect.
3815
ff7a55bf
TS
38162015-12-02 Thomas Schwinge <thomas@codesourcery.com>
3817
3818 * c-parser.c (c_parser_omp_clause_name)
3819 (c_parser_oacc_all_clauses): Alphabetical sorting.
3820
657e4e47
JJ
38212015-12-02 Jakub Jelinek <jakub@redhat.com>
3822
3823 PR c/68533
3824 * c-decl.c (get_parm_info): Use b->locus instead of input_location
3825 for diagnostics.
3826
37d5ad46
JB
38272015-12-01 Julian Brown <julian@codesourcery.com>
3828 Cesar Philippidis <cesar@codesourcery.com>
3829 James Norris <James_Norris@mentor.com>
3830
3831 * c-parser.c (c_parser_omp_clause_name): Add use_device support.
3832 (c_parser_oacc_clause_use_device): New function.
3833 (c_parser_oacc_all_clauses): Add use_device support.
3834 (OACC_HOST_DATA_CLAUSE_MASK): New macro.
3835 (c_parser_oacc_host_data): New function.
3836 (c_parser_omp_construct): Add host_data support.
3837 * c-tree.h (c_finish_oacc_host_data): Add prototype.
3838 * c-typeck.c (c_finish_oacc_host_data): New function.
3839 (c_finish_omp_clauses): Add use_device support.
3840
a4850ce9
JH
38412015-11-29 Jan Hubicka <hubicka@ucw.cz>
3842
3843 PR c/67106
3844 * c-decl.c: Set TYPE_PACKED in variants.
3845
b58d3df2
ML
38462015-11-27 Martin Liska <mliska@suse.cz>
3847
3848 PR c++/68312
3849 * c-array-notation.c (fix_builtin_array_notation_fn):
3850 Use release_vec_vec instead of vec::release.
3851 (build_array_notation_expr): Likewise.
3852 (fix_conditional_array_notations_1): Likewise.
3853 (fix_array_notation_expr): Likewise.
3854 (fix_array_notation_call_expr): Likewise.
3855
aec17bfe
JJ
38562015-11-27 Jakub Jelinek <jakub@redhat.com>
3857
3858 PR c/63326
3859 * c-parser.c (c_parser_compound_statement_nostart): If
3860 last_label is true, use pragma_stmt instead of pragma_compound
3861 as second c_parser_pragma argument.
3862 (c_parser_omp_ordered, c_parser_omp_target_update,
3863 c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): Pass
3864 false as second argument to c_parser_skip_to_pragma_eol after
3865 diagnosing standalone directives used in pragma_stmt context.
3866
688c4de0
IV
38672015-11-24 Ilya Verbin <ilya.verbin@intel.com>
3868
3869 * c-parser.c (c_parser_oacc_declare): Replace "ifdef ENABLE_OFFLOADING"
3870 with "if (ENABLE_OFFLOADING)".
3871
cbd03aee
DM
38722015-11-23 David Malcolm <dmalcolm@redhat.com>
3873
3874 PR objc/68438
3875 * c-parser.c (c_parser_postfix_expression): Set up source ranges
3876 for various Objective-C constructs: Class.name syntax,
3877 @selector(), @protocol(), @encode(), and [] message syntax.
3878
a87a86e1
DM
38792015-11-20 David Malcolm <dmalcolm@redhat.com>
3880
3881 PR 62314
3882 * c-typeck.c (should_suggest_deref_p): New function.
3883 (build_component_ref): Special-case POINTER_TYPE when
3884 generating a "not a structure of union" error message, and
3885 suggest a "->" rather than a ".", providing a fix-it hint.
3886
8ece8dfb
DM
38872015-11-19 David Malcolm <dmalcolm@redhat.com>
3888
3889 * c-typeck.c (lookup_field_fuzzy): Move determination of closest
3890 candidate into a new function, find_closest_identifier.
3891
433068cc
MP
38922015-11-19 Marek Polacek <polacek@redhat.com>
3893
3894 PR c/68412
3895 * c-typeck.c (parser_build_binary_op): Properly handle
3896 C_MAYBE_CONST_EXPR before calling warn_tautological_cmp.
3897
bef08b71
DM
38982015-11-17 David Malcolm <dmalcolm@redhat.com>
3899
3900 * c-parser.c (set_c_expr_source_range): Bulletproof both
3901 overloaded implementations against NULL expr->value.
3902 (c_parser_braced_init): Set src_range for "ret" to a sane pair of
3903 values.
3904 (c_parser_unary_expression): Likewise when handling addresses of
3905 labels.
3906 (c_parser_postfix_expression): Likewise for statement expressions,
3907 for __FUNCTION__, __PRETTY_FUNCTION_ and __func__ keywords, for
3908 __builtin_va_arg, and for __builtin_offset_of.
3909 (c_parser_postfix_expression_after_paren_type): Initialize expr's
3910 src_range using the range of the braced initializer.
3911 (c_parser_transaction_expression): Set src_range for "ret" to a
3912 sane pair of values.
3913
fff77217
KY
39142015-11-16 Kirill Yukhin <kirill.yukhin@intel.com>
3915
3916 * c-parser.c (c_finish_omp_declare_simd): Look for
3917 "simd" attribute as well. Update error message.
3918
1d899da2
TS
39192015-11-14 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
3920
3921 * c-parser.c (c_parser_omp_declare_target): Adjust.
3922
e4606348
JJ
39232015-11-14 Jakub Jelinek <jakub@redhat.com>
3924
3925 * c-typeck.c (c_finish_omp_clauses): Don't mark
3926 GOMP_MAP_FIRSTPRIVATE_POINTER decls addressable.
3927
3e636daf
MP
39282015-11-14 Marek Polacek <polacek@redhat.com>
3929
3930 * c-decl.c: Use RECORD_OR_UNION_TYPE_P throughout.
3931 * c-typeck.c: Likewise.
3932
ebedc9a3
DM
39332015-11-13 David Malcolm <dmalcolm@redhat.com>
3934
3935 * c-decl.c (warn_defaults_to): Pass line_table to
3936 rich_location ctor.
3937 * c-errors.c (pedwarn_c99): Likewise.
3938 (pedwarn_c90): Likewise.
3939 * c-parser.c (set_c_expr_source_range): New functions.
3940 (c_token::get_range): New method.
3941 (c_token::get_finish): New method.
3942 (c_parser_expr_no_commas): Call set_c_expr_source_range on the ret
3943 based on the range from the start of the LHS to the end of the
3944 RHS.
3945 (c_parser_conditional_expression): Likewise, based on the range
3946 from the start of the cond.value to the end of exp2.value.
3947 (c_parser_binary_expression): Call set_c_expr_source_range on
3948 the stack values for TRUTH_ANDIF_EXPR and TRUTH_ORIF_EXPR.
3949 (c_parser_cast_expression): Call set_c_expr_source_range on ret
3950 based on the cast_loc through to the end of the expr.
3951 (c_parser_unary_expression): Likewise, based on the
3952 op_loc through to the end of op.
3953 (c_parser_sizeof_expression) Likewise, based on the start of the
3954 sizeof token through to either the closing paren or the end of
3955 expr.
3956 (c_parser_postfix_expression): Likewise, using the token range,
3957 or from the open paren through to the close paren for
3958 parenthesized expressions.
3959 (c_parser_postfix_expression_after_primary): Likewise, for
3960 various kinds of expression.
3961 * c-tree.h (struct c_expr): Add field "src_range".
3962 (c_expr::get_start): New method.
3963 (c_expr::get_finish): New method.
3964 (set_c_expr_source_range): New decls.
3965 * c-typeck.c (parser_build_unary_op): Call set_c_expr_source_range
3966 on ret for prefix unary ops.
3967 (parser_build_binary_op): Likewise, running from the start of
3968 arg1.value through to the end of arg2.value.
3969
ec8b536f
MP
39702015-11-13 Marek Polacek <polacek@redhat.com>
3971
3972 PR c/68320
3973 * c-parser.c (c_parser_for_statement): Treat unknown tokens as IDs.
3974
277fe616
DM
39752015-11-13 David Malcolm <dmalcolm@redhat.com>
3976
3977 * c-typeck.c: Include spellcheck.h.
3978 (lookup_field_fuzzy_find_candidates): New function.
3979 (lookup_field_fuzzy): New function.
3980 (build_component_ref): If the field was not found, try using
3981 lookup_field_fuzzy and potentially offer a suggestion.
3982
6e232ba4
JN
39832015-11-12 James Norris <jnorris@codesourcery.com>
3984 Joseph Myers <joseph@codesourcery.com>
3985
3986 * c-parser.c (c_parser_pragma): Handle PRAGMA_OACC_DECLARE.
3987 (c_parser_omp_clause_name): Handle 'device_resident' clause.
3988 (c_parser_oacc_data_clause): Handle PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT
3989 and PRAGMA_OMP_CLAUSE_LINK.
3990 (c_parser_oacc_all_clauses): Handle PRAGMA_OACC_CLAUSE_DEVICE_RESIDENT
3991 and PRAGMA_OACC_CLAUSE_LINK.
3992 (OACC_DECLARE_CLAUSE_MASK): New definition.
3993 (c_parser_oacc_declare): New function.
3994
9be4f715
MP
39952015-11-12 Marek Polacek <polacek@redhat.com>
3996
3997 PR c/67784
3998 * c-parser.c (c_parser_for_statement): Reclassify the token in
3999 a correct scope.
4000
e78bede6
MP
40012015-11-11 Marek Polacek <polacek@redhat.com>
4002
4003 PR c/68107
4004 PR c++/68266
4005 * c-decl.c (grokdeclarator): Call valid_array_size_p. Remove code
4006 checking the size of an array.
4007
69f293c9
AM
40082015-11-11 Andrew MacLeod <amacleod@redhat.com>
4009
4010 * c-array-notation.c: Remove unused header files.
4011 * c-aux-info.c: Likewise.
4012 * c-convert.c: Likewise.
4013 * c-decl.c: Likewise.
4014 * c-errors.c: Likewise.
4015 * c-lang.c: Likewise.
4016 * c-objc-common.c: Likewise.
4017 * c-parser.c: Likewise.
4018 * c-typeck.c: Likewise.
4019 * gccspec.c: Likewise.
4020
3a40d81d
NS
40212015-11-09 Thomas Schwinge <thomas@codesourcery.com>
4022 Cesar Philippidis <cesar@codesourcery.com>
4023 James Norris <jnorris@codesourcery.com>
4024 Julian Brown <julian@codesourcery.com>
4025 Nathan Sidwell <nathan@codesourcery.com>
4026
3a40d81d
NS
4027 * c-parser.c (c_parser_declaration_or_fndef): Add OpenACC
4028 routine arg.
4029 (c_parser_declaration_or_fndef): Call c_finish_oacc_routine.
4030 (c_parser_pragma): Parse 'acc routine'.
4031 (OACC_ROUTINE_CLAUSE_MARK): Define.
4032 (c_parser_oacc_routine, (c_finish_oacc_routine): New.
4033
fc402eec
AA
40342015-11-09 Andreas Arnez <arnez@linux.vnet.ibm.com>
4035
4036 PR debug/67192
4037 * c-typeck.c (c_finish_loop): For unconditional loops, set the
4038 location of the backward-goto to the start of the loop body.
4039
f6b0b3db
AA
40402015-11-09 Andreas Arnez <arnez@linux.vnet.ibm.com>
4041
4042 PR debug/67192
4043 * c-parser.c (c_parser_while_statement): Finish the loop before
4044 parsing ahead for misleading indentation.
4045 (c_parser_for_statement): Likewise.
4046
ee45a32d
EB
40472015-11-08 Eric Botcazou <ebotcazou@adacore.com>
4048
4049 * c-decl.c (finish_struct): If the structure has reverse storage
4050 order, rewrite the type of array fields with scalar component. Call
4051 maybe_apply_pragma_scalar_storage_order on entry.
4052 * c-typeck.c (build_unary_op) <ADDR_EXPR>: Remove left-overs. Issue
4053 errors on bit-fields and reverse SSO here and not...
4054 (c_mark_addressable): ...here.
4055 (output_init_element): Adjust call to initializer_constant_valid_p.
4056 (c_build_qualified_type): Propagate TYPE_REVERSE_STORAGE_ORDER.
4057
8a645150
DM
40582015-11-06 David Malcolm <dmalcolm@redhat.com>
4059
4060 * c-decl.c (warn_defaults_to): Update for change in signature
4061 of diagnostic_set_info.
4062 * c-errors.c (pedwarn_c99): Likewise.
4063 (pedwarn_c90): Likewise.
4064 * c-objc-common.c (c_tree_printer): Update for new "caret_p" param
4065 for textinfo::set_location.
4066
7a5e4956
CP
40672015-11-05 Cesar Philippidis <cesar@codesourcery.com>
4068 Thomas Schwinge <thomas@codesourcery.com>
4069 James Norris <jnorris@codesourcery.com>
4070
4071 * c-parser.c (c_parser_omp_clause_name): Add support for
4072 PRAGMA_OACC_CLAUSE_INDEPENDENT and PRAGMA_OACC_CLAUSE_TILE.
4073 (c_parser_omp_clause_default): Add is_oacc argument. Handle
4074 default(none) in OpenACC.
4075 (c_parser_oacc_shape_clause): Allow pointer variables as gang static
4076 arguments.
4077 (c_parser_oacc_clause_tile): New function.
4078 (c_parser_oacc_all_clauses): Add support for OMP_CLAUSE_DEFAULT,
4079 OMP_CLAUSE_INDEPENDENT and OMP_CLAUSE_TILE.
4080 (OACC_LOOP_CLAUSE_MASK): Add PRAGMA_OACC_CLAUSE_{PRIVATE,INDEPENDENT,
4081 TILE}.
4082 (OACC_KERNELS_MASK): Add PRAGMA_OACC_CLAUSE_DEFAULT.
4083 (OACC_PARALLEL_MASK): Add PRAGMA_OACC_CLAUSE_{DEFAULT,PRIVATE,
4084 FIRSTPRIVATE}.
4085 (c_parser_omp_all_clauses): Update call to c_parser_omp_clause_default.
4086 (c_parser_oacc_update): Update the error message for missing clauses.
4087 * c-typeck.c (c_finish_omp_clauses): Add support for OMP_CLAUSE_TILE
4088 and OMP_CLAUSE_INDEPENDENT.
4089
bfcfbfa0
MP
40902015-11-05 Marek Polacek <polacek@redhat.com>
4091
4092 PR c/68090
4093 * c-parser.c (c_parser_postfix_expression_after_paren_type): Don't
4094 deal with pre-evaluation on invalid types.
4095
e01d41e5
JJ
40962015-11-05 Jakub Jelinek <jakub@redhat.com>
4097 Ilya Verbin <ilya.verbin@intel.com>
4098
4099 * c-parser.c: Include context.h and gimple-expr.h.
4100 (c_parser_omp_clause_schedule): Parse schedule modifiers, diagnose
4101 monotonic together with nonmonotonic.
4102 (c_parser_omp_for_loop): Call c_omp_check_loop_iv. Call add_stmt here.
4103 (OMP_DISTRIBUTE_CLAUSE_MASK): Add lastprivate clause.
4104 (c_parser_omp_target_data, c_parser_omp_target_enter_data,
4105 c_parser_omp_target_exit_data): Allow GOMP_MAP_ALWAYS_POINTER.
4106 (c_parser_omp_target): Likewise. Evaluate num_teams and thread_limit
4107 expressions on combined target teams before the target.
4108 (c_parser_omp_declare_target): If decl has "omp declare target" or
4109 "omp declare target link" attribute, and cgraph or varpool node already
4110 exists, then set corresponding flags. Call c_finish_omp_clauses
4111 in the parenthesized extended-list syntax case.
4112 * c-decl.c (c_decl_attributes): Don't diagnose block scope vars inside
4113 declare target.
4114 * c-typeck.c (handle_omp_array_sections_1): Allow non-zero low-bound
4115 on OMP_CLAUSE_REDUCTION array sections.
4116 (handle_omp_array_sections): Encode low-bound into the MEM_REF, either
4117 into the constant offset, or for variable low-bound using
4118 POINTER_PLUS_EXPR. For structure element based array sections use
4119 GOMP_MAP_ALWAYS_POINTER instead of GOMP_MAP_FIRSTPRIVATE_POINTER.
4120 (c_finish_omp_clauses): Drop generic_field_head, structure
4121 elements are now always mapped even as array section bases,
4122 diagnose same var in data sharing and mapping clauses. Diagnose if
4123 linear step on declare simd is neither a constant nor a uniform
4124 parameter. Look through POINTER_PLUS_EXPR for array section
4125 reductions. Diagnose the same var or function appearing multiple
4126 times on the same directive. Fix up wording for the to clause if t
4127 is neither a FUNCTION_DECL nor a VAR_DECL. Diagnose nonmonotonic
4128 modifier on kinds other than dynamic or guided or nonmonotonic
4129 modifier together with ordered clause.
4130
4bf9e5a8
TS
41312015-11-03 Thomas Schwinge <thomas@codesourcery.com>
4132 Chung-Lin Tang <cltang@codesourcery.com>
4133
4134 * c-parser.c (c_parser_omp_construct): Handle PRAGMA_OACC_ATOMIC.
4135
2adfab87
AM
41362015-10-29 Andrew MacLeod <amacleod@redhat.com>
4137
4138 * c-array-notation.c: Reorder #include's and remove duplicates.
4139 * c-aux-info.c: Likewise.
4140 * c-convert.c: Likewise.
4141 * c-decl.c: Likewise.
4142 * c-errors.c: Likewise.
4143 * c-lang.c: Likewise.
4144 * c-objc-common.c: Likewise.
4145 * c-parser.c: Likewise.
4146 * c-typeck.c: Likewise.
4147
e922069e
JW
41482015-10-26 Jim Wilson <jim.wilson@linaro.org>
4149
4150 PR debug/66068
4151 * c-typeck.c (c_build_qualified_type): Clear C_TYPE_INCOMPLETE_VARS
4152 after calling build_qualified_type.
4153
765dd391
CP
41542015-10-27 Cesar Philippidis <cesar@codesourcery.com>
4155 Thomas Schwinge <thomas@codesourcery.com>
4156 James Norris <jnorris@codesourcery.com>
4157 Joseph Myers <joseph@codesourcery.com>
4158 Julian Brown <julian@codesourcery.com>
4159 Bernd Schmidt <bschmidt@redhat.com>
4160
4161 * c-parser.c (c_parser_oacc_shape_clause): New.
4162 (c_parser_oacc_simple_clause): New.
4163 (c_parser_oacc_all_clauses): Add auto, gang, seq, vector, worker.
4164 (OACC_LOOP_CLAUSE_MASK): Add gang, worker, vector, auto, seq.
4165
88bae6f4
TS
41662015-10-27 Thomas Schwinge <thomas@codesourcery.com>
4167 James Norris <jnorris@codesourcery.com>
4168 Cesar Philippidis <cesar@codesourcery.com>
4169
4170 PR c/64765
4171 PR c/64880
4172 * c-parser.c (c_parser_oacc_loop): Add mask, cclauses formal
4173 parameters, and handle these. Adjust all users.
4174 (c_parser_oacc_kernels, c_parser_oacc_parallel): Merge functions
4175 into...
4176 (c_parser_oacc_kernels_parallel): ... this new function. Adjust
4177 all users.
4178 * c-tree.h (c_finish_oacc_parallel, c_finish_oacc_kernels): Don't
4179 declare functions.
4180 (c_finish_omp_construct): Declare function.
4181 * c-typeck.c (c_finish_oacc_parallel, c_finish_oacc_kernels):
4182 Merge functions into...
4183 (c_finish_omp_construct): ... this new function.
4184
a8fc2579
RB
41852015-10-22 Richard Biener <rguenther@suse.de>
4186
4187 * c-typeck.c (c_finish_omp_clauses): Properly convert operands
4188 before folding a MINUS_EXPR.
4189
e9122ef6
MP
41902015-10-21 Marek Polacek <polacek@redhat.com>
4191
4192 PR c/68024
4193 * c-decl.c (start_function): Warn about vararg functions without
4194 a prototype.
4195
9f47c7e5
IE
41962015-10-21 Ilya Enkovich <enkovich.gnu@gmail.com>
4197
4198 * c-typeck.c (build_conditional_expr): Use boolean vector
4199 type for vector comparison.
4200 (build_vec_cmp): New.
4201 (build_binary_op): Use build_vec_cmp for comparison.
4202
fa60eeb9
MP
42032015-10-20 Marek Polacek <polacek@redhat.com>
4204
4205 * c-parser.c (is_cilkplus_vector_p): Don't define here.
4206
2c7020eb
MP
42072015-10-20 Marek Polacek <polacek@redhat.com>
4208
4209 PR c/67964
4210 * c-parser.c (c_parser_attributes): Break out of the loop if the
4211 token after an attribute isn't a comma.
4212
d9a6bd32
JJ
42132015-10-13 Jakub Jelinek <jakub@redhat.com>
4214 Aldy Hernandez <aldyh@redhat.com>
4215
4216 * c-parser.c (c_parser_pragma): Handle PRAGMA_OMP_ORDERED here.
4217 (c_parser_omp_clause_name): Handle OpenMP 4.5 clauses.
4218 (c_parser_omp_variable_list): Handle structure elements for
4219 map, to and from clauses. Handle array sections in reduction
4220 clause. Formatting fixes.
4221 (c_parser_omp_clause_if): Add IS_OMP argument, handle parsing of
4222 if clause modifiers.
4223 (c_parser_omp_clause_num_tasks, c_parser_omp_clause_grainsize,
4224 c_parser_omp_clause_priority, c_parser_omp_clause_hint,
4225 c_parser_omp_clause_defaultmap, c_parser_omp_clause_use_device_ptr,
4226 c_parser_omp_clause_is_device_ptr): New functions.
4227 (c_parser_omp_clause_ordered): Parse optional parameter.
4228 (c_parser_omp_clause_reduction): Handle array reductions.
4229 (c_parser_omp_clause_schedule): Parse optional simd modifier.
4230 (c_parser_omp_clause_nogroup, c_parser_omp_clause_orderedkind): New
4231 functions.
4232 (c_parser_omp_clause_linear): Parse linear clause modifiers.
4233 (c_parser_omp_clause_depend_sink): New function.
4234 (c_parser_omp_clause_depend): Parse source/sink depend kinds.
4235 (c_parser_omp_clause_map): Parse release/delete map kinds and
4236 optional always modifier.
4237 (c_parser_oacc_all_clauses): Adjust c_parser_omp_clause_if
4238 and c_finish_omp_clauses callers.
4239 (c_parser_omp_all_clauses): Likewise. Parse OpenMP 4.5 clauses.
4240 Parse "to" as OMP_CLAUSE_TO_DECLARE if on declare target directive.
4241 (c_parser_oacc_cache): Adjust c_finish_omp_clauses caller.
4242 (OMP_CRITICAL_CLAUSE_MASK): Define.
4243 (c_parser_omp_critical): Parse critical clauses.
4244 (c_parser_omp_for_loop): Handle doacross loops, adjust
4245 c_finish_omp_for and c_finish_omp_clauses callers.
4246 (OMP_SIMD_CLAUSE_MASK): Add simdlen clause.
4247 (c_parser_omp_simd): Allow ordered clause if it has no parameter.
4248 (OMP_FOR_CLAUSE_MASK): Add linear clause.
4249 (c_parser_omp_for): Disallow ordered clause when combined with
4250 distribute. Disallow linear clause when combined with distribute
4251 and not combined with simd.
4252 (OMP_ORDERED_CLAUSE_MASK, OMP_ORDERED_DEPEND_CLAUSE_MASK): Define.
4253 (c_parser_omp_ordered): Add CONTEXT argument, remove LOC argument,
4254 parse clauses and if depend clause is found, don't parse a body.
4255 (c_parser_omp_parallel): Disallow copyin clause on target parallel.
4256 Allow target parallel without for after it.
4257 (OMP_TASK_CLAUSE_MASK): Add priority clause.
4258 (OMP_TARGET_DATA_CLAUSE_MASK): Add use_device_ptr clause.
4259 (c_parser_omp_target_data): Diagnose no map clauses or clauses with
4260 invalid kinds.
4261 (OMP_TARGET_UPDATE_CLAUSE_MASK): Add depend and nowait clauses.
4262 (OMP_TARGET_ENTER_DATA_CLAUSE_MASK,
4263 OMP_TARGET_EXIT_DATA_CLAUSE_MASK): Define.
4264 (c_parser_omp_target_enter_data, c_parser_omp_target_exit_data): New
4265 functions.
4266 (OMP_TARGET_CLAUSE_MASK): Add depend, nowait, private, firstprivate,
4267 defaultmap and is_device_ptr clauses.
4268 (c_parser_omp_target): Parse target parallel and target simd. Set
4269 OMP_TARGET_COMBINED on combined constructs. Parse target enter data
4270 and target exit data. Diagnose invalid map kinds.
4271 (OMP_DECLARE_TARGET_CLAUSE_MASK): Define.
4272 (c_parser_omp_declare_target): Parse OpenMP 4.5 forms of this
4273 construct.
4274 (c_parser_omp_declare_reduction): Use STRIP_NOPS when checking for
4275 &omp_priv.
4276 (OMP_TASKLOOP_CLAUSE_MASK): Define.
4277 (c_parser_omp_taskloop): New function.
4278 (c_parser_omp_construct): Don't handle PRAGMA_OMP_ORDERED here,
4279 handle PRAGMA_OMP_TASKLOOP.
4280 (c_parser_cilk_for): Adjust c_finish_omp_clauses callers.
4281 * c-tree.h (c_finish_omp_clauses): Add two new arguments.
4282 * c-typeck.c (handle_omp_array_sections_1): Fix comment typo.
4283 Add IS_OMP argument, handle structure element bases, diagnose
4284 bitfields, pass IS_OMP recursively, diagnose known zero length
4285 array sections in depend clauses, handle array sections in reduction
4286 clause, diagnose negative length even for pointers.
4287 (handle_omp_array_sections): Add IS_OMP argument, use auto_vec for
4288 types, pass IS_OMP down to handle_omp_array_sections_1, handle
4289 array sections in reduction clause, set
4290 OMP_CLAUSE_MAP_MAYBE_ZERO_LENGTH_ARRAY_SECTION if map could be zero
4291 length array section, use GOMP_MAP_FIRSTPRIVATE_POINTER for IS_OMP.
4292 (c_finish_omp_clauses): Add IS_OMP and DECLARE_SIMD arguments.
4293 Handle new OpenMP 4.5 clauses and new restrictions for the old ones.
4294
21ba0cea
MP
42952015-10-06 Marek Polacek <polacek@redhat.com>
4296
4297 * c-parser.c (c_parser_statement_after_labels): Use
4298 protected_set_expr_location.
4299 (c_parser_omp_clause_num_gangs): Likewise.
4300 (c_parser_omp_clause_num_threads): Likewise.
4301 (c_parser_omp_clause_num_workers): Likewise.
4302 (c_parser_omp_clause_vector_length): Likewise.
4303 (c_parser_omp_clause_num_teams): Likewise.
4304 (c_parser_omp_clause_thread_limit): Likewise.
4305 * c-typeck.c (build_c_cast): Likewise.
4306 (c_cast_expr): Likewise.
4307
624d31fe
RS
43082015-10-05 Richard Sandiford <richard.sandiford@arm.com>
4309
4310 * c-typeck.c (c_tree_equal): Use real_equal instead of
4311 REAL_VALUES_EQUAL.
4312
b8fd7909
JM
43132015-10-04 Jason Merrill <jason@redhat.com>
4314
4315 * c-parser.c (c_lex_one_token): Handle @synchronized.
4316 * c-decl.c (match_builtin_function_types): A declaration of a built-in
4317 can change whether the function is transaction_safe.
4318
1c7485af
MP
43192015-10-02 Marek Polacek <polacek@redhat.com>
4320
4321 PR c/67730
4322 * c-typeck.c (convert_for_assignment): Use the expansion point
4323 location throughout.
4324
3e3b8d63
MP
43252015-10-02 Marek Polacek <polacek@redhat.com>
4326
4327 PR c/64249
4328 * c-parser.c (c_parser_statement_after_labels): Add CHAIN parameter
4329 and pass it down to c_parser_if_statement.
4330 (c_parser_else_body): Add CHAIN parameter and pass it down to
4331 c_parser_statement_after_labels.
4332 (c_parser_if_statement): Add CHAIN parameter. Add code to warn about
4333 duplicated if-else-if conditions.
4334
aabef2de
MP
43352015-10-01 Marek Polacek <polacek@redhat.com>
4336
4337 * c-typeck.c (convert_for_assignment): Improve commentary.
4338
de8ddd5f
MP
43392015-09-30 Marek Polacek <polacek@redhat.com>
4340
4341 PR c/67730
4342 * c-typeck.c (c_finish_return): Use the expansion point location for
4343 certain "return with value" warnings.
4344
c4914de6
MLI
43452015-09-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
4346
4347 * c-parser.c (pragma_lex): Add loc argument.
4348
0e36f5c7
MP
43492015-09-15 Marek Polacek <polacek@redhat.com>
4350
4351 PR c/67580
4352 * c-decl.c (tag_exists_p): New function.
4353 * c-parser.c (c_parser_declaration_or_fndef): Give a hint when
4354 struct/union/enum keywords are missing.
4355 * c-tree.h (tag_exists_p): Declare.
4356
2f3bb934
MP
43572015-09-15 Marek Polacek <polacek@redhat.com>
4358
4359 * c-decl.c (lookup_label): Return NULL_TREE instead of 0.
4360 (lookup_tag): Change the type of THISLEVEL_ONLY to bool.
4361 Return NULL_TREE instead of 0.
4362 (lookup_name): Return NULL_TREE instead of 0.
4363 (lookup_name_in_scope): Likewise.
4364 (shadow_tag_warned): Use true instead of 1 and NULL_TREE instead of 0.
4365 (parser_xref_tag): Use false instead of 0.
4366 (start_struct): Use true instead of 1.
4367 (start_enum): Use true instead of 1 and NULL_TREE instead of 0.
4368
aa256c4a
MP
43692015-09-14 Marek Polacek <polacek@redhat.com>
4370
4371 * c-typeck.c (set_nonincremental_init_from_string): Use
4372 HOST_WIDE_INT_M1U when shifting a negative value.
4373
dbb68221
MW
43742015-09-09 Mark Wielaard <mjw@redhat.com>
4375
4376 * c-typeck.c (build_binary_op): Check and warn when nonnull arg
4377 parm against NULL.
4378
a8a098ac
JJ
43792015-09-10 Jakub Jelinek <jakub@redhat.com>
4380
4381 PR c/67502
4382 * c-parser.c (c_parser_omp_for_loop): Emit DECL_EXPR stmts
4383 into OMP_FOR_PRE_BODY rather than before the loop.
4384
f4b189d5
JJ
43852015-09-09 Jakub Jelinek <jakub@redhat.com>
4386
0bb99c11
JJ
4387 PR c/67501
4388 * c-parser.c (c_parser_oacc_all_clauses,
4389 c_parser_omp_all_clauses): Remove invalid clause from
4390 list of clauses even if parser->error is set.
4391
fce5e5e3
JJ
4392 PR c/67500
4393 * c-parser.c (c_parser_omp_clause_aligned,
4394 c_parser_omp_clause_safelen, c_parser_omp_clause_simdlen): Fix up
4395 test for errors.
4396 * c-decl.c (temp_pop_parm_decls): Allow b->decl equal to
4397 error_mark_node.
4398
f4b189d5
JJ
4399 PR c/67495
4400 * c-parser.c (c_parser_omp_atomic): Use c_parser_cast_expression
4401 instead of c_parser_unary_expression. If the result is !lvalue_p,
4402 wrap the result of c_fully_fold into NON_LVALUE_EXPR.
4403
b2aaf235
MP
44042015-09-04 Marek Polacek <polacek@redhat.com>
4405
4406 PR sanitizer/67279
4407 * c-typeck.c (build_binary_op): Don't instrument static initializers.
4408
1807ffc1
MS
44092015-09-03 Martin Sebor <msebor@redhat.com>
4410
4411 PR c/66516
8b652e65
JJ
4412 * c-typeck.c (convert_arguments, parser_build_unary_op,
4413 build_conditional_expr, c_cast_expr, convert_for_assignment,
4414 build_binary_op, _objc_common_truthvalue_conversion): Call
1807ffc1
MS
4415 reject_gcc_builtin.
4416 (c_decl_implicit): Define.
4417
d04ff417
MP
44182015-09-02 Marek Polacek <polacek@redhat.com>
4419
4420 PR c/67432
4421 * c-parser.c (c_parser_enum_specifier): Give a better error for
4422 an empty enum.
4423
a79683d5
TS
44242015-08-18 Trevor Saunders <tbsaunde@tbsaunde.org>
4425
4426 * c-aux-info.c, c-parser.c, c-tree.h: Remove useless typedefs.
4427
191a6b94
MP
44282015-08-12 Marek Polacek <polacek@redhat.com>
4429
4430 * c-decl.c (grokdeclarator): Call error_at instead of error and pass
4431 LOC to it.
4432
420a9d9b
MP
44332015-08-03 Marek Polacek <polacek@redhat.com>
4434
4435 PR c/67088
4436 * c-decl.c (check_bitfield_type_and_width): Add location parameter.
4437 Use it.
4438 (grokdeclarator): Pass LOC down to check_bitfield_type_and_width.
4439
992118a1
PP
44402015-08-02 Patrick Palka <ppalka@gcc.gnu.org>
4441
4442 * c-parser.c (c_parser_if_body): Take token_indent_info
4443 argument. Call warn_for_misleading_indentation even when the
4444 body is a semicolon. Extract token_indent_infos corresponding
4445 to the guard, body and next tokens. Adjust call to
4446 warn_for_misleading_indentation accordingly.
4447 (c_parser_else_body): Likewise.
4448 (c_parser_if_statement): Likewise.
4449 (c_parser_while_statement): Likewise.
4450 (c_parser_for_statement): Likewise.
4451
46308474
LFSM
44522015-07-28 Luis Felipe Strano Moraes <luis.strano@gmail.com>
4453 Manuel López-Ibáñez <manu@gcc.gnu.org>
4454
4455 * c-decl.c (get_parm_info): Remove static var. Update warning
4456 message.
4457
05b28fd6
MP
44582015-07-27 Marek Polacek <polacek@redhat.com>
4459
4460 PR c++/66555
4461 PR c/54979
4462 * c-typeck.c (parser_build_binary_op): Call warn_tautological_cmp.
4463
451b5e48
MP
44642015-07-20 Marek Polacek <polacek@redhat.com>
4465
4466 PR c++/55095
4467 * c-typeck.c (digest_init): Pass OPT_Wpedantic to pedwarn_init.
4468 (build_binary_op): Warn about left shift overflows.
4469
1916bcb5
AM
44702015-07-09 Andrew MacLeod <amacleod@redhat.com>
4471
4472 * c-array-notation.c: Adjust includes for flags.h changes.
4473 * c-objc-common.c: Likewise.
4474
c7131fb2
AM
44752015-07-07 Andrew MacLeod <amacleod@redhat.com>
4476
4477 * c-array-notation.c: Adjust includes.
4478 * c-aux-info.c: Likewise.
4479 * c-convert.c: Likewise.
4480 * c-decl.c: Likewise.
4481 * c-errors.c: Likewise.
4482 * c-lang.c: Likewise.
4483 * c-objc-common.c: Likewise.
4484 * c-parser.c: Likewise.
4485 * c-typeck.c: Likewise.
4486
da2e71c9
MLI
44872015-06-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
4488
4489 PR fortran/66605
4490 * c-decl.c (finish_function): Call do_warn_unused_parameter.
4491
b155cfd9
MP
44922015-06-29 Marek Polacek <polacek@redhat.com>
4493
4494 PR c/66322
4495 * c-typeck.c (struct c_switch): Add BOOL_COND_P and OUTSIDE_RANGE_P.
4496 (c_start_case): Set BOOL_COND_P and OUTSIDE_RANGE_P. Don't warn
4497 about -Wswitch-bool here.
4498 (do_case): Update c_add_case_label call.
4499 (c_finish_case): Update c_do_switch_warnings call.
4500
31521951
MP
45012015-06-27 Marek Polacek <polacek@redhat.com>
4502
4503 * c-typeck.c: Use VECTOR_TYPE_P throughout.
4504
22d03525
MP
45052015-06-26 Marek Polacek <polacek@redhat.com>
4506
4507 * c-array-notation.c (fix_builtin_array_notation_fn): Use
4508 INDIRECT_REF_P.
4509 * c-typeck.c (array_to_pointer_conversion): Likewise.
4510 (build_unary_op): Likewise.
4511 (c_finish_return): Likewise.
4512
f0889939
AM
45132015-06-25 Andrew MacLeod <amacleod@redhat.com>
4514
4515 * c-decl.c: Remove ipa-ref.h and plugin-api.h from include list.
4516 * c-parser.c: Likewise.
4517
8d67ee55
RS
45182015-06-25 Richard Sandiford <richard.sandiford@arm.com>
4519
4520 * c-decl.c (detect_field_duplicates_hash): Use nofree_ptr_hash
4521 instead of pointer_hash.
4522 (detect_field_duplicates): Likewise.
4523
0ae9bd27
MP
45242015-06-25 Marek Polacek <polacek@redhat.com>
4525
4526 * c-array-notation.c: Use VAR_P throughout.
4527 * c-decl.c: Likewise.
4528 * c-objc-common.c: Likewise.
4529 * c-parser.c: Likewise.
4530 * c-typeck.c: Likewise.
4531
62f9079a
MP
45322015-06-25 Marek Polacek <polacek@redhat.com>
4533
4534 * c-decl.c: Use is_global_var throughout.
4535 * c-parser.c: Likewise.
4536 * c-typeck.c: Likewise.
4537
abb226c9
AM
45382015-06-17 Andrew MacLeod <amacleod@redhat.com>
4539
4540 * c-array-notation.c: Do not include input.h, line-map.h or is-a.h.
4541 * c-aux-info.c: Likewise.
4542 * c-convert.c: Likewise.
4543 * c-decl.c: Likewise.
4544 * c-errors.c: Likewise.
4545 * c-lang.c: Likewise.
4546 * c-objc-common.c: Likewise.
4547 * c-parser.c: Likewise.
4548 * c-typeck.c: Likewise.
4549
8cbababc
JH
45502015-06-11 Jan Hubicka <hubicka@ucw.cz>
4551
4552 PR middle-end/66325
4553 * c-decl.c (start_enum): Set TYPE_PACKED consistently among type
4554 variants.
4555
a0349665
PMR
45562015-06-11 Pierre-Marie de Rodat <derodat@adacore.com>
4557
4558 * c-decl.c (pop_scope): Register the main translation unit
4559 through the new debug hook.
4560
13fdf2e2
AM
45612015-06-08 Andrew MacLeod <amacleod@redhat.com>
4562
4563 * c-array-notation.c : Adjust include files.
4564 * c-aux-info.c : Likewise.
4565 * c-convert.c : Likewise.
4566 * c-decl.c : Likewise.
4567 * c-errors.c : Likewise.
4568 * c-lang.c : Likewise.
4569 * c-lang.h : Likewise.
4570 * c-objc-common.c : Likewise.
4571 * c-parser.c : Likewise.
4572 * c-typeck.c : Likewise.
4573
d7438551
AH
45742015-06-05 Aldy Hernandez <aldyh@redhat.com>
4575
4576 * c-decl.c (finish_struct): Save C_TYPE_INCOMPLETE_VARS and
4577 immediately clobber it.
4578 (c_write_global_declarations_1): Remove call to
4579 check_global_declaration_1.
4580 (c_write_global_declarations_2): Remove.
4581 (c_write_final_cleanups): Rename from c_write_global_declarations.
4582 Remove call to finalize_compilation_unit.
4583 Remove calls to debugging hooks.
4584 * c-objc-common.c: Adjust comment for c_warn_unused_global_decl.
4585 * c-objc-common.h: Remove LANG_HOOKS_WRITE_GLOBALS.
4586 * c-tree.h: Remove c_write_global_declarations.
4587
ecb9f223
AM
45882015-06-04 Andrew MacLeod <amacleod@redhat.com>
4589
4590 * c-array-notation.c: Adjust includes for restructured coretypes.h.
4591 * c-aux-info.c: Likewise.
4592 * c-convert.c: Likewise.
4593 * c-decl.c: Likewise.
4594 * c-errors.c: Likewise.
4595 * c-lang.c: Likewise.
4596 * c-objc-common.c: Likewise.
4597 * c-parser.c: Likewise.
4598 * c-typeck.c: Likewise.
4599
9482b620
MP
46002015-06-04 Marek Polacek <polacek@redhat.com>
4601
4602 PR c/66341
4603 * c-typeck.c (build_c_cast): Wrap VALUE into NON_LVALUE_EXPR if
4604 it is a lvalue.
4605
bc51ace3
PK
46062015-06-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4607
4608 * c-decl.c (warn_cxx_compat_finish_struct): New parameters code, record_loc.
4609 Warn for empty struct.
4610 (finish_struct): Pass TREE_CODE(t) and loc to warn_cxx_compat_finish_struct.
4611
ea5b45b6
AT
46122015-06-02 Andres Tiraboschi <andres.tiraboschi@tallertechnologies.com>
4613
4614 * c-decl.c (start_function): Call plugin before parsing.
4615 (finish_function): Call plugin after parsing.
4616
c2d47482
PK
46172015-06-02 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4618
4619 PR c/49551
4620 * c-decl.c (merge_decls): Merge DECL_COMMON.
4621
a95492ab
JW
46222015-05-22 Jim Wilson <jim.wilson@linaro.org>
4623
4624 * Make-lang.in (check_gcc_pallelize): Define.
4625
fd5c817a
MP
46262015-05-22 Marek Polacek <polacek@redhat.com>
4627
4628 PR c/47043
4629 * c-parser.c (c_parser_enum_specifier): Parse and apply enumerator
4630 attributes.
4631
c7b70a3c
MP
46322015-05-21 Marek Polacek <polacek@redhat.com>
4633
4634 * c-typeck.c (inform_declaration): Use DECL_IS_BUILTIN instead of
4635 DECL_BUILT_IN.
4636
21b634ae
MP
46372015-05-20 Marek Polacek <polacek@redhat.com>
4638
4639 * c-decl.c: Use VAR_OR_FUNCTION_DECL_P throughout.
4640 * c-typeck.c: Likewise.
4641
296a8c2f
MP
46422015-05-19 Marek Polacek <polacek@redhat.com>
4643
4644 * c-typeck.c (start_init): Use AGGREGATE_TYPE_P.
4645
41b37d5e
JJ
46462015-05-19 Jakub Jelinek <jakub@redhat.com>
4647
4648 PR middle-end/66199
4649 * c-parser.c (c_parser_omp_for_loop): Don't add
4650 OMP_CLAUSE_SHARED to OMP_PARALLEL_CLAUSES when moving
4651 OMP_CLAUSE_LASTPRIVATE clause to OMP_FOR_CLAUSES.
4652 (c_parser_omp_teams): Set OMP_TEAMS_COMBINED for combined
4653 constructs.
4654
fab27f52
MM
46552015-05-19 Mikhail Maltsev <maltsevm@gmail.com>
4656
4657 * c-typeck.c (build_array_ref): Use std::swap instead of explicit
296a8c2f 4658 swaps.
fab27f52 4659
40de31cf
MLI
46602015-05-16 Manuel López-Ibáñez <manu@gcc.gnu.org>
4661
4662 PR fortran/44054
4663 * c-objc-common.c (c_tree_printer): Replace locus pointer with
4664 accessor function.
4665
3aa3c9fc
MP
46662015-05-14 Marek Polacek <polacek@redhat.com>
4667
4668 PR c/66066
4669 PR c/66127
4670 * c-typeck.c (digest_init): Call pedwarn_init with OPT_Wpedantic
4671 rather than with 0.
4672
c3388e62
DM
46732015-05-12 David Malcolm <dmalcolm@redhat.com>
4674
4675 * c-parser.c (c_parser_if_body): Add param "if_loc", use it
4676 to add a call to warn_for_misleading_indentation.
4677 (c_parser_else_body): Likewise, adding param "else_loc".
4678 (c_parser_if_statement): Check for misleading indentation.
4679 (c_parser_while_statement): Likewise.
4680 (c_parser_for_statement): Likewise.
4681
755e528f
MP
46822015-05-08 Marek Polacek <polacek@redhat.com>
4683
4684 PR c/64918
4685 * c-typeck.c (add_pending_init): Use OPT_Woverride_init_side_effects.
4686 (output_init_element): Likewise.
4687
0173bd2a
MP
46882015-05-07 Marek Polacek <polacek@redhat.com>
4689
4690 PR c/65179
4691 * c-typeck.c (build_binary_op): Warn when left shifting a negative
4692 value.
4693
9babc352
MP
46942015-04-30 Marek Polacek <polacek@redhat.com>
4695
4696 * c-typeck.c (set_init_label): Call error_at instead of error and
4697 pass LOC to it.
4698
ac9f18db
MP
4699 * c-typeck.c (c_incomplete_type_error): Refactor to use %qT. Print
4700 the type of a decl.
4701
ec3fba51
MP
4702 * c-typeck.c (c_build_va_arg): Clarify the error message.
4703
b811915d
TS
47042015-04-29 Thomas Schwinge <thomas@codesourcery.com>
4705
4706 * c-parser.c (c_parser_oacc_enter_exit_data): Use
4707 OMP_STANDALONE_CLAUSES.
4708
f3075008
MP
47092015-04-28 Marek Polacek <polacek@redhat.com>
4710
4711 * c-parser.c (c_parser_binary_expression): Remove duplicate line.
4712
4e81b788
MP
47132015-04-28 Marek Polacek <polacek@redhat.com>
4714
4715 PR c/65901
4716 * c-typeck.c (c_build_va_arg): Require TYPE be a complete type.
4717
6c1db78e
MP
47182015-04-25 Marek Polacek <polacek@redhat.com>
4719
4720 PR c/52085
4721 * c-decl.c (finish_enum): Copy over TYPE_ALIGN. Also check for "mode"
4722 attribute.
4723
5c4abbb8
MP
47242015-04-23 Marek Polacek <polacek@redhat.com>
4725
4726 PR c/65345
4727 * c-decl.c (set_labels_context_r): New function.
4728 (store_parm_decls): Call it via walk_tree_without_duplicates.
4729 * c-typeck.c (convert_lvalue_to_rvalue): Use create_tmp_var_raw
4730 instead of create_tmp_var. Build TARGET_EXPR instead of
4731 COMPOUND_EXPR.
4732 (build_atomic_assign): Use create_tmp_var_raw instead of
4733 create_tmp_var. Build TARGET_EXPRs instead of MODIFY_EXPR.
4734
06aca1d5
IV
47352015-04-20 Ilya Verbin <ilya.verbin@intel.com>
4736
4737 * c-parser.c (c_parser_oacc_enter_exit_data): Remove excess semicolon.
4738 (c_parser_omp_target_update): Add missed %> to error_at ().
4739
8fba1830
BRF
47402015-04-10 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
4741
4742 PR target/55143
4743 * c-decl.c (c_default_pointer_mode): Remove definition.
4744 * c-tree.h (c_default_pointer_mode): Remove declaration.
4745
62021f64
TB
47462015-03-27 Tobias Burnus <burnus@net-b.de>
4747
4748 PR c/65586
4749 * c-parser.c (c_parser_skip_to_pragma_eol): Optionally, don't
4750 error out.
4751 (c_parser_omp_for, c_parser_omp_parallel, c_parser_omp_distribute,
4752 c_parser_omp_teams, c_parser_omp_target, c_parser_omp_declare):
4753 Update calls to not error for skipped omp pragmas with -fopenmp-simd.
4754
9b65e171
JJ
47552015-03-19 Jakub Jelinek <jakub@redhat.com>
4756
4757 * c-decl.c (c_decl_attributes): Also add "omp declare target"
4758 attribute for DECL_EXTERNAL VAR_DECLs.
4759
17958621
JJ
47602015-03-11 Jakub Jelinek <jakub@redhat.com>
4761
4762 * c-parser.c (c_parse_init): Don't call xstrdup on get_identifier
4763 argument.
4764
7ccb1a11
JJ
47652015-03-10 Jakub Jelinek <jakub@redhat.com>
4766
4767 PR c/65120
4768 * c-typeck.c (parser_build_binary_op): Check for tcc_comparison
4769 before preparing arguments to warn_logical_not_parentheses.
4770
01177669
JJ
47712015-03-09 Jakub Jelinek <jakub@redhat.com>
4772
4773 PR c/65120
4774 * c-typeck.c (parser_build_binary_op): Don't warn for
4775 !!x == y or !b == y where b is _Bool.
4776
802ac282
MP
47772015-03-09 Marek Polacek <polacek@redhat.com>
4778
4779 * c-convert.c (convert): Make use of do_ubsan_in_current_function.
4780 * c-decl.c (grokdeclarator): Likewise.
4781 * c-typeck.c (build_binary_op): Likewise.
4782
e5165b60
MP
47832015-02-27 Marek Polacek <polacek@redhat.com>
4784
4785 PR c/65228
4786 * c-decl.c (start_decl): Return NULL_TREE if decl is an error node.
4787
065d214c
MP
47882015-02-14 Marek Polacek <polacek@redhat.com>
4789
4790 PR c/64768
4791 * c-decl.c (grokdeclarator): Set the range of a flexible array member
4792 declared through a typedef name.
4793
e5d9235b
MP
47942015-02-13 Marek Polacek <polacek@redhat.com>
4795
4796 PR c/65050
4797 * c-decl.c (grokdeclarator): Print also the type when giving
4798 the error message about array's incomplete element type.
4799
fa01ffcc
JJ
48002015-02-11 Jakub Jelinek <jakub@redhat.com>
4801
4802 PR c/64824
4803 * c-parser.c (c_parser_binary_expression): Fix OpenMP stack[sp].prec
4804 check in the POP macro.
4805
c3e38a03
MP
48062015-02-09 Marek Polacek <polacek@redhat.com>
4807
4808 PR c/64856
4809 * c-typeck.c (process_init_element): Don't always wrap
4810 COMPOUND_LITERAL_EXPR in a SAVE_EXPR in C99 mode when
4811 initializing a range of elements.
4812
4886ec8e
JJ
48132015-02-04 Jakub Jelinek <jakub@redhat.com>
4814
4815 PR c/64824
4816 PR c/64868
4817 * c-parser.c (c_parser_omp_atomic): Handle RDIV_EXPR.
4818
c3e38a03 48192015-02-02 Bruno Loff <bruno.loff@gmail.com>
a4bb6959
BL
4820
4821 * c-parser.c (c_parser_declspecs): Call invoke_plugin_callbacks after
4822 processing enum declaration.
4823
7b33f0c8
MP
48242015-01-29 Marek Polacek <polacek@redhat.com>
4825
4826 PR c/64709
4827 * c-typeck.c (pop_init_level): If constructor_elements has
4828 exactly one element with integer_zerop value, set constructor_zeroinit
4829 to 1. Remove braces around warning_init call.
4830
dea63e49
JJ
48312015-01-27 Jakub Jelinek <jakub@redhat.com>
4832
4833 PR c/64766
4834 * c-typeck.c (store_init_value): Don't overwrite DECL_INITIAL
4835 of FUNCTION_DECLs with error_mark_node.
4836
d38f7dce
JJ
48372015-01-26 Jakub Jelinek <jakub@redhat.com>
4838
4839 PR c/64778
4840 * c-typeck.c (convert_arguments): Return -1 if there are
4841 error_args, even if we've diagnosed too many arguments.
4842
cbf5d0e7
RB
48432015-01-21 Richard Biener <rguenther@suse.de>
4844
4845 PR middle-end/64313
4846 * c-decl.c (merge_decls): Call set_builtin_decl_declared_p
4847 for builtins the user declared correctly.
4848
41dbbb37
TS
48492015-01-15 Thomas Schwinge <thomas@codesourcery.com>
4850 Bernd Schmidt <bernds@codesourcery.com>
4851 Cesar Philippidis <cesar@codesourcery.com>
4852 James Norris <jnorris@codesourcery.com>
4853 Jakub Jelinek <jakub@redhat.com>
4854 Ilmir Usmanov <i.usmanov@samsung.com>
4855
4856 * c-parser.c: Include "gomp-constants.h".
4857 (c_parser_omp_clause_map): Use enum gomp_map_kind instead of enum
4858 omp_clause_map_kind. Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.
4859 Use OMP_CLAUSE_SET_MAP_KIND.
4860 (c_parser_pragma): Handle PRAGMA_OACC_ENTER_DATA,
4861 PRAGMA_OACC_EXIT_DATA, PRAGMA_OACC_UPDATE.
4862 (c_parser_omp_construct): Handle PRAGMA_OACC_CACHE,
4863 PRAGMA_OACC_DATA, PRAGMA_OACC_KERNELS, PRAGMA_OACC_LOOP,
4864 PRAGMA_OACC_PARALLEL, PRAGMA_OACC_WAIT.
4865 (c_parser_omp_clause_name): Handle "auto", "async", "copy",
4866 "copyout", "create", "delete", "deviceptr", "gang", "host",
4867 "num_gangs", "num_workers", "present", "present_or_copy", "pcopy",
4868 "present_or_copyin", "pcopyin", "present_or_copyout", "pcopyout",
4869 "present_or_create", "pcreate", "seq", "self", "vector",
4870 "vector_length", "wait", "worker".
4871 (OACC_DATA_CLAUSE_MASK, OACC_KERNELS_CLAUSE_MASK)
4872 (OACC_ENTER_DATA_CLAUSE_MASK, OACC_EXIT_DATA_CLAUSE_MASK)
4873 (OACC_LOOP_CLAUSE_MASK, OACC_PARALLEL_CLAUSE_MASK)
4874 (OACC_UPDATE_CLAUSE_MASK, OACC_WAIT_CLAUSE_MASK): New macros.
4875 (c_parser_omp_variable_list): Handle OMP_CLAUSE__CACHE_.
4876 (c_parser_oacc_wait_list, c_parser_oacc_data_clause)
4877 (c_parser_oacc_data_clause_deviceptr)
4878 (c_parser_omp_clause_num_gangs, c_parser_omp_clause_num_workers)
4879 (c_parser_oacc_clause_async, c_parser_oacc_clause_wait)
4880 (c_parser_omp_clause_vector_length, c_parser_oacc_all_clauses)
4881 (c_parser_oacc_cache, c_parser_oacc_data, c_parser_oacc_kernels)
4882 (c_parser_oacc_enter_exit_data, c_parser_oacc_loop)
4883 (c_parser_oacc_parallel, c_parser_oacc_update)
4884 (c_parser_oacc_wait): New functions.
4885 * c-tree.h (c_finish_oacc_parallel, c_finish_oacc_kernels)
4886 (c_finish_oacc_data): New prototypes.
4887 * c-typeck.c: Include "gomp-constants.h".
4888 (handle_omp_array_sections): Handle GOMP_MAP_FORCE_DEVICEPTR. Use
4889 GOMP_MAP_* instead of OMP_CLAUSE_MAP_*. Use
4890 OMP_CLAUSE_SET_MAP_KIND.
4891 (c_finish_oacc_parallel, c_finish_oacc_kernels)
4892 (c_finish_oacc_data): New functions.
4893 (c_finish_omp_clauses): Handle OMP_CLAUSE__CACHE_,
4894 OMP_CLAUSE_NUM_GANGS, OMP_CLAUSE_NUM_WORKERS,
4895 OMP_CLAUSE_VECTOR_LENGTH, OMP_CLAUSE_ASYNC, OMP_CLAUSE_WAIT,
4896 OMP_CLAUSE_AUTO, OMP_CLAUSE_SEQ, OMP_CLAUSE_GANG,
4897 OMP_CLAUSE_WORKER, OMP_CLAUSE_VECTOR, and OMP_CLAUSE_MAP's
4898 GOMP_MAP_FORCE_DEVICEPTR.
4899
adfac8df
JJ
49002015-01-09 Michael Collison <michael.collison@linaro.org>
4901
4902 * c-array-notation.c: Include hash-set.h, machmode.h,
4903 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4904 fold-const.h, wide-int.h, and inchash.h due to flattening of tree.h.
4905 * c-aux-info.c: Ditto.
4906 * c-convert.c: Ditto.
4907 * c-decl.c: Ditto.
4908 * c-errors.c: Ditto.
4909 * c-lang.c: Dittoxs.
4910 * c-objc-common.c: Ditto.
4911 * c-parser.c: Ditto.
4912 * c-typeck.c: Include hash-set.h, machmode.h,
4913 vec.h, double-int.h, input.h, alias.h, symtab.h, options.h
4914 fold-const.h, wide-int.h, inchash.h, real.h and
4915 fixed-value.h due to flattening of tree.h.
4916
2cc901dc
MP
49172015-01-07 Marek Polacek <polacek@redhat.com>
4918
4919 PR c/64417
4920 * c-typeck.c (process_init_element): Disallow initialization of
4921 a flexible array member with a string constant if the structure
4922 is in an array.
4923
5624e564
JJ
49242015-01-05 Jakub Jelinek <jakub@redhat.com>
4925
e5341100
JJ
4926 PR sanitizer/64344
4927 * c-typeck.c (convert_for_assignment, c_finish_return): For
4928 -fsanitize=float-cast-overflow casts from REAL_TYPE to integer/enum
4929 types also set in_late_binary_op around convert call.
4930 * c-convert.c (convert): For -fsanitize=float-cast-overflow REAL_TYPE
4931 to integral type casts, if not in_late_binary_op, pass c_fully_fold
4932 result on expr as last argument to ubsan_instrument_float_cast,
4933 if in_late_binary_op, don't use c_save_expr but save_expr.
4934
5624e564
JJ
4935 Update copyright years.
4936
5bd012f8
MP
49372015-01-05 Marek Polacek <polacek@redhat.com>
4938
4939 PR c/64423
4940 * c-typeck.c (build_array_ref): Pass loc down to
4941 warn_array_subscript_with_type_char.
4942
3f8257db 49432014-12-20 Martin Uecker <uecker@eecs.berkeley.edu>
768952be
MU
4944
4945 * c-typeck.c: New behavious for pointers to arrays with qualifiers
8e745a17 4946 (common-pointer-type): For pointers to arrays take qualifiers from
768952be 4947 element type.
8e745a17 4948 (build_conditional_expr): Add warnings for lost qualifiers.
768952be 4949 (comp-target-types): Allow pointers to arrays with different qualifiers.
8e745a17 4950 (convert-for-assignment): Adapt warnings for discarded qualifiers. Add
768952be 4951 WARNING_FOR_QUALIFIERS macro and rename WARN_FOR_QUALIFIERS
8e745a17 4952 to PEDWARN_FOR_QUALIFIERS.
768952be 4953
8f94a8c4
JJ
49542014-12-17 Jakub Jelinek <jakub@redhat.com>
4955
4956 PR sanitizer/64289
4957 * c-convert.c: Include ubsan.h.
4958 (convert): For real -> integral casts and
4959 -fsanitize=float-cast-overflow don't call convert_to_integer, but
4960 instead instrument the float cast directly.
4961
b731b390
JJ
49622014-11-29 Jakub Jelinek <jakub@redhat.com>
4963
4964 * c-typeck.c (convert_lvalue_to_rvalue, build_atomic_assign,
4965 c_finish_stmt_expr): Remove NULL last argument from
4966 create_tmp_var_raw and create_tmp_var calls.
4967 * c-array-notation.c (fix_builtin_array_notation_fn,
4968 build_array_notation_expr, fix_conditional_array_notations_1,
4969 fix_array_notation_expr, fix_array_notation_call_expr): Likewise.
4970
541e35a6
MP
49712014-11-28 Marek Polacek <polacek@redhat.com>
4972
4973 PR c/63862
4974 * c-typeck.c (build_binary_op) <RSHIFT_EXPR, LSHIFT_EXPR>: Don't
4975 convert the right operand to integer type.
4976
b286be94
MP
49772014-11-25 Marek Polacek <polacek@redhat.com>
4978
4979 PR c/63877
4980 * c-decl.c (start_function): Disable -Wmissing-declarations warning
4981 for inline functions.
4982
aa7da51a
JJ
49832014-11-21 Jakub Jelinek <jakub@redhat.com>
4984
4985 PR target/63764
4986 * c-typeck.c (build_array_ref): Adjust
4987 convert_vector_to_pointer_for_subscript caller. If it returns true,
4988 call non_lvalue_loc on the result.
4989
d876207f
RB
49902014-11-11 Richard Biener <rguenther@suse.de>
4991
4992 * c-decl.c (c_init_decl_processing): Do not set pedantic_lvalues
4993 to true.
4994
e5e44252
AK
49952014-11-10 Andi Kleen <ak@linux.intel.com>
4996
4997 PR c/60804
4998 * c-parser.c (c_parser_statement_after_labels): Call
4999 check_no_cilk.
5000 (c_parser_if_statement): Dito.
5001 (c_parser_switch_statement): Dito.
5002 (c_parser_while_statement): Dito.
5003 (c_parser_do_statement): Dito.
5004 (c_parser_for_statement): Dito.
5005 * c-typeck.c (c_finish_loop): Dito.
5006
13c21655
PC
50072014-11-10 Paolo Carlini <paolo.carlini@oracle.com>
5008
5009 * c-typeck.c (build_binary_op): Use OPT_Wshift_count_negative and
5010 OPT_Wshift_count_overflow in the warnings.
5011
2d51fcef
MP
50122014-10-30 Marek Polacek <polacek@redhat.com>
5013
5014 * c-objc-common.c (c_tree_printer) <case 'T'>: For a typedef name,
5015 print the stripped version as well, if they're not the same.
5016
ef4bddc2
RS
50172014-10-29 Richard Sandiford <richard.sandiford@arm.com>
5018
5019 * c-decl.c, c-tree.h, c-typeck.c: Remove redundant enum from
5020 machine_mode.
5021
c582198b
AM
50222014-10-28 Andrew MacLeod <amacleod@redhat.com>
5023
5024 * c-decl.c: Adjust include files.
5025 * c-parser.c: Ditto.
5026
ddc8de03
PM
50272014-10-27 Phil Muldoon <pmuldoon@redhat.com>
5028 Tom Tromey <tromey@redhat.com>
5029
5030 * c-tree.h (enum c_oracle_request): New.
5031 (c_binding_oracle_function): New typedef.
5032 (c_binding_oracle, c_pushtag, c_bind): Declare.
5033 * c-decl.c (c_binding_oracle): New global.
5034 (I_SYMBOL_CHECKED): New macro.
5035 (i_symbol_binding): New function.
5036 (I_SYMBOL_BINDING, I_SYMBOL_DECL): Redefine.
5037 (I_TAG_CHECKED): New macro.
5038 (i_tag_binding): New function.
5039 (I_TAG_BINDING, I_TAG_DECL): Redefine.
5040 (I_LABEL_CHECKED): New macro.
5041 (i_label_binding): New function.
5042 (I_LABEL_BINDING, I_LABEL_DECL): Redefine.
5043 (c_print_identifier): Save and restore c_binding_oracle.
5044 (c_pushtag, c_bind): New functions.
5045
60393bbc
AM
50462014-10-27 Andrew MacLeod <amacleod@redhat.com>
5047
5048 * c-typeck.c: Adjust include files.
5049
d723bb7c
MLI
50502014-10-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
5051
5052 PR c++/53061
5053 * c-objc-common.c (c_objc_common_init): Do not do diagnostics
5054 initialization here...
5055 (c_initialize_diagnostics): ... but here. Set defaults after
5056 building pretty-printer.
5057
1bc5a451
MP
50582014-10-23 Marek Polacek <polacek@redhat.com>
5059
5060 PR c/63626
5061 * c-decl.c (pop_scope): Don't print warning in external_scope.
5062
4435bb92
MP
50632014-10-19 Marek Polacek <polacek@redhat.com>
5064
5065 PR c/63567
5066 * c-typeck.c (output_init_element): Allow initializing objects with
5067 static storage duration with compound literals even in C99 and add
5068 pedwarn for it.
5069
7278465e
MP
50702014-10-17 Marek Polacek <polacek@redhat.com>
5071
5072 PR c/63567
5073 * c-typeck.c (digest_init): Allow initializing objects with static
5074 storage duration with compound literals even in C99 and add pedwarn
5075 for it.
5076
d9b7be2e
MP
50772014-10-17 Marek Polacek <polacek@redhat.com>
5078
5079 PR c/63543
5080 * c-tree.h (C_TYPE_ERROR_REPORTED): Define.
5081 * c-typeck.c (build_indirect_ref): Don't print the "dereferencing..."
5082 error multiple times. Print the type.
5083
f406ae1f
MP
50842014-10-17 Marek Polacek <polacek@redhat.com>
5085
5086 PR c/63549
5087 * c-typeck.c (build_array_ref): Bail if the index in an incomplete
5088 type.
5089
92574c7c
MP
50902014-10-17 Marek Polacek <polacek@redhat.com>
5091
5092 * c-decl.c (grokdeclarator): Use OPT_Wimplicit_int unconditionally.
5093 (start_function): Use OPT_Wimplicit_int instead of 0.
5094 (store_parm_decls_oldstyle): Likewise.
5095
1bc4a978
MT
50962014-10-17 Alan Modra <amodra@gmail.com>
5097
5098 PR middle-end/61848
5099 * c-decl.c (merge_decls): Don't merge section name or tls model
5100 to newdecl symtab node, instead merge to olddecl. Override
5101 existing olddecl section name. Set tls_model for all thread-local
5102 vars, not just OMP thread-private ones. Remove incorrect comment.
5103
83685514
AM
51042014-10-16 Andrew MacLeod <amacleod@redhat.com>
5105
5106 * c-decl.c: Adjust include files.
5107
78a7c317
DD
51082014-10-14 DJ Delorie <dj@redhat.com>
5109
5110 * c-parser.c (c_parse_init): Add RID entries for each __intN.
5111 (c_token_starts_typename): Check all __intN, not just __int128.
5112 (c_token_starts_declspecs): Likewise.
5113 (c_parser_declspecs): Likewise.
5114 (c_parser_attribute_any_word): Likewise.
5115 (c_parser_objc_selector): Likewise.
5116 * c-tree.h (c_typespec_keyword): cts_int128 -> cts_int_n.
5117 (struct c_declspecs): Add int_n_idx field to record *which* __intN
5118 is specified.
5119 * c-decl.c (declspecs_add_type): Check for all __intN, not just
5120 __int128.
5121 (finish_declspecs): Likewise.
5122
74d98c1e
AB
51232014-10-13 Anthony Brandon <anthony.brandon@gmail.com>
5124
8e745a17 5125 * c-parser.c (c_parser_all_labels): New function to replace
74d98c1e 5126 the duplicate code.
8e745a17 5127 (c_parser_statement): Call the new function.
74d98c1e 5128
84937de2
MP
51292014-10-09 Marek Polacek <polacek@redhat.com>
5130
5131 PR c/63480
5132 * c-typeck.c (pop_init_level): Don't warn about initializing
5133 with { }.
5134
0382aaa0
MP
51352014-10-07 Marek Polacek <polacek@redhat.com>
5136
5137 PR c/59717
5138 * c-decl.c (header_for_builtin_fn): New function.
5139 (implicitly_declare): Suggest which header to include.
5140
7a0ca710
MP
51412014-10-07 Marek Polacek <polacek@redhat.com>
5142
5143 * c-convert.c (convert): Use error_operand_p.
5144 * c-typeck.c (require_complete_type): Likewise.
5145 (really_atomic_lvalue): Likewise.
5146 (digest_init): Likewise.
5147 (handle_omp_array_sections_1): Likewise.
5148
6bc8a126
MP
51492014-10-03 Marek Polacek <polacek@redhat.com>
5150
5151 PR c/63453
5152 * c-decl.c (pop_scope): Don't warn about "inline function declared
5153 but never defined" for functions marked with gnu_inline attribute.
5154
d90c0a59
JJ
51552014-09-25 Jakub Jelinek <jakub@redhat.com>
5156
5157 PR c++/63249
5158 * c-parser.c (c_parser_omp_variable_list): Call mark_exp_read
5159 on low_bound and length.
5160
083e891e
MP
51612014-09-24 Marek Polacek <polacek@redhat.com>
5162
5163 PR c/61405
5164 PR c/53874
5165 * c-parser.c: Don't define CPP_KEYWORD.
5166 (c_parser_switch_statement): Pass original type to c_finish_case.
5167 * c-tree.h (c_finish_case): Update declaration.
5168 * c-typeck.c (c_finish_case): Add TYPE parameter. Pass it
5169 conditionally to c_do_switch_warnings.
5170
8d95fe25
MP
51712014-09-03 Marek Polacek <polacek@redhat.com>
5172
5173 PR c/62024
5174 * c-parser.c (c_parser_static_assert_declaration_no_semi): Strip no-op
5175 conversions.
5176
9a771876
JJ
51772014-09-02 Jakub Jelinek <jakub@redhat.com>
5178 Balaji V. Iyer <balaji.v.iyer@intel.com>
5179 Igor Zamyatin <igor.zamyatin@intel.com>
5180
5181 * c-parser.c (c_parser_cilk_for): New function.
5182 (c_parser_cilk_grainsize): Likewise.
5183 (c_get_temp_regvar): Likewise.
5184 (c_parser_statement_after_labels): Added RID_CILK_FOR case.
5185 (c_parser_pragma): Added PRAGMA_CILK_GRAINSIZE case.
5186 (c_parser_omp_for_loop): Added CILK_FOR and CILK_SIMD checks.
5187 * c-typeck.c (c_finish_omp_clauses): Added OMP_CLAUSE__CILK_FOR_COUNT_
5188 case.
5189
b7679d96
CG
51902014-08-27 Chen Gang <gang.chen.5i5j@gmail.com>
5191
5192 * c-aux-info.c (gen_type): Resize 'buff' from 10 to 23 bytes,
5193 with using HOST_WIDE_INT without truncation to 'int'
5194
59ea0364
MP
51952014-08-22 Marek Polacek <polacek@redhat.com>
5196
5197 PR c++/62199
5198 * c-typeck.c (parser_build_binary_op): Adjust call to
5199 warn_logical_not_parentheses.
5200
671a475e
IZ
52012014-08-22 Igor Zamyatin <igor.zamyatin@intel.com>
5202
5203 PR other/62008
5204 * c-parser.c (c_parser_array_notation): Check for correct
5205 type of an array added.
5206
04159acf
MP
52072014-08-19 Marek Polacek <polacek@redhat.com>
5208
5209 PR c++/62153
5210 * c-typeck.c (build_binary_op): If either operand of a comparison
5211 is a boolean expression, call maybe_warn_bool_compare.
5212
c77935ee
PP
52132014-08-19 Patrick Palka <ppalka@gcc.gnu.org>
5214
5215 PR c/45584
5216 * c-typeck.c (build_c_cast): Do a conversion even when the
5217 TYPE_MAIN_VARIANTs are the same.
5218
35aff4fb
MP
52192014-08-19 Marek Polacek <polacek@redhat.com>
5220
5221 * c-decl.c (diagnose_mismatched_decls): Unconditionally call
5222 pedwarn_c99 instead of pedwarn.
5223 (grokfield): Likewise.
5224 (warn_defaults_to): New function.
5225 (grokdeclarator): Call warn_defaults_to instead of pedwarn_c99.
5226 Unconditionally call pedwarn_c99 instead of pedwarn.
5227 (start_function): Call warn_defaults_to instead of pedwarn_c99.
5228 (declspecs_add_scspec): Call pedwarn_c99 instead of pedwarn, don't
5229 check flag_isoc11 before.
5230 * c-errors.c (pedwarn_c99): Change the return type to bool.
5231 Handle -Wc99-c11-compat.
5232 * c-parser.c (disable_extension_diagnostics): Handle
5233 warn_c99_c11_compat.
5234 (restore_extension_diagnostics): Likewise.
5235 (c_parser_static_assert_declaration_no_semi): Call pedwarn_c99
5236 instead of pedwarn, don't check flag_isoc11 before.
5237 (c_parser_declspecs): Likewise.
5238 (c_parser_alignas_specifier): Likewise.
5239 (c_parser_alignof_expression): Likewise.
5240 (c_parser_generic_selection): Likewise.
5241 * c-tree.h (pedwarn_c99): Update declaration.
5242 * c-typeck.c (c_finish_return): Call pedwarn or warning_at instead
5243 of pedwarn_c99.
5244
177cce46
MP
52452014-08-19 Marek Polacek <polacek@redhat.com>
5246
5247 * c-decl.c (warn_variable_length_array): Pass OPT_Wvla unconditionally
5248 to pedwarn_c90.
5249 * c-errors.c: Include "opts.h".
5250 (pedwarn_c90): Rewrite to handle -Wno-c90-c99-compat better.
5251 * c-parser.c (disable_extension_diagnostics): Handle negative value
5252 of warn_c90_c99_compat, too.
5253 (restore_extension_diagnostics): Likewise.
5254 (c_parser_compound_statement_nostart): Pass
5255 OPT_Wdeclaration_after_statement unconditionally to pedwarn_c90.
5256
6dc99c33
MP
52572014-08-12 Marek Polacek <polacek@redhat.com>
5258
5259 * c-parser.c (c_parser_postfix_expression) <case RID_FUNCTION_NAME>:
5260 Add pedwarn.
5261 (c_parser_postfix_expression) <case RID_PRETTY_FUNCTION_NAME>:
5262 Likewise.
5263 (c_parser_postfix_expression) <case RID_C99_FUNCTION_NAME>: Likewise.
5264
3f8257db 52652014-08-10 Marek Polacek <polacek@redhat.com>
f3bede71
MP
5266
5267 PR c/51849
5268 * c-decl.c (build_array_declarator): Remove check for !flag_isoc99.
5269 Call pedwarn_c90 instead of pedwarn.
5270 (check_bitfield_type_and_width): Likewise.
5271 (declspecs_add_qual): Likewise.
5272 (declspecs_add_type): Likewise.
5273 (warn_variable_length_array): Unify function for -pedantic and -Wvla.
5274 Adjust to only call pedwarn_c90.
5275 (grokdeclarator): Remove pedantic && !flag_isoc99 check. Call
5276 pedwarn_c90 instead of pedwarn.
5277 * c-errors.c (pedwarn_c90): Handle -Wc90-c99-compat.
5278 * c-parser.c (disable_extension_diagnostics): Handle
5279 warn_c90_c99_compat.
5280 (restore_extension_diagnostics): Likewise.
5281 (c_parser_enum_specifier): Remove check for !flag_isoc99. Call
5282 pedwarn_c90 instead of pedwarn.
5283 (c_parser_initelt): Likewise.
5284 (c_parser_postfix_expression): Likewise.
5285 (c_parser_postfix_expression_after_paren_type): Likewise.
5286 (c_parser_compound_statement_nostart): Remove check for !flag_isoc99.
5287 * c-tree.h: Fix formatting.
5288 * c-typeck.c (build_array_ref): Remove check for !flag_isoc99. Call
5289 pedwarn_c90 instead of pedwarn.
5290
9f25a338
TS
52912014-08-07 Trevor Saunders <tsaunders@mozilla.com>
5292
5293 * c-typeck.c: Remove include of pointer-set.h.
5294
044331a8
MP
52952014-08-07 Marek Polacek <polacek@redhat.com>
5296
5297 * c-typeck.c (pointer_diff): Remove P - (P + CST) optimization.
5298
b787e7a2
TS
52992014-08-02 Trevor Saunders <tsaunders@mozilla.com>
5300
5301 * c-typeck.c: Use hash_map instead of pointer_map.
5302
6e2830c3
TS
53032014-08-02 Trevor Saunders <tsaunders@mozilla.com>
5304
5305 * c-decl.c: Use hash_set instead of pointer_set.
5306
a7ee52fb
IZ
53072014-08-01 Igor Zamyatin <igor.zamyatin@intel.com>
5308
5309 PR middle-end/61455
5310 * c-array-notation.c (expand_array_notations): Handling
5311 of DECL_EXPR added.
5312
b4dfdc11
MG
53132014-07-31 Marc Glisse <marc.glisse@inria.fr>
5314
5315 PR c++/60517
5316 * c-typeck.c (c_finish_return): Return 0 instead of the address of
5317 a local variable.
5318
976d5a22
TT
53192014-07-30 Tom Tromey <tromey@redhat.com>
5320
5321 * c-typeck.c (struct constructor_stack) <designator_depth>: New
5322 field.
5323 (really_start_incremental_init, push_init_level): Initialize
5324 designator_depth.
5325 (pop_init_level): Set global designator_depth.
5326 (process_init_element): Check for designated_init attribute.
5327
30281de2
MP
53282014-07-20 Marek Polacek <polacek@redhat.com>
5329
5330 PR c/61852
5331 * c-decl.c (implicit_decl_warning): Add location_t parameter. Use it.
5332 (implicitly_declare): Pass location to implicit_decl_warning.
5333
b108f48f
JJ
53342014-07-14 Jakub Jelinek <jakub@redhat.com>
5335
5336 PR middle-end/61294
5337 * c-parser.c (c_parser_expr_list): Add new argument literal_zero_mask.
5338 If non-NULL, call c_parser_check_literal_zero.
5339 (c_parser_check_literal_zero): New function.
5340 (c_parser_postfix_expression_after_primary): Adjust
5341 c_parser_expr_list caller, handle -Wmemset-transposed-args.
5342
773ec47f
MP
53432014-07-06 Marek Polacek <polacek@redhat.com>
5344
5345 PR c/6940
5346 * c-decl.c (grokdeclarator): Set C_ARRAY_PARAMETER.
5347 * c-tree.h (C_ARRAY_PARAMETER): Define.
5348 * c-typeck.c (c_expr_sizeof_expr): Warn when using sizeof on an array
5349 function parameter.
5350
22e1cf1c 53512014-07-02 Jan Hubicka <hubicka@ucw.cz>
3f8257db 5352 Chen Gang <gang.chen.5i5j@gmail.com>
22e1cf1c
JH
5353
5354 * c-decl.c (duplicate_decls): CLear DECL_STRUCT_FUNCTION before
5355 releasing symbol.
5356
52ec0ea3
MP
53572014-07-01 Marek Polacek <polacek@redhat.com>
5358
5359 * c-typeck.c (convert_for_assignment): Pass OPT_Wint_conversion
5360 instead of 0 to WARN_FOR_ASSIGNMENT.
5361
d5c3d343
MP
53622014-07-01 Marek Polacek <polacek@redhat.com>
5363
5364 PR c/58286
5365 * c-typeck.c (convert_for_assignment): Pass
5366 OPT_Wincompatible_pointer_types instead of 0 to WARN_FOR_ASSIGNMENT.
5367
6a7253a4
MP
53682014-06-30 Marek Polacek <polacek@redhat.com>
5369
5370 * c-decl.c (grokdeclarator): Don't instrument VLAs if the function
5371 has no_sanitize_undefined attribute.
5372
5e88a8f4
IZ
53732014-06-30 Igor Zamyatin <igor.zamyatin@intel.com>
5374
5375 PR middle-end/57541
5376 * c-array-notation.c (fix_builtin_array_notation_fn):
5377 Check for 0 arguments in builtin call. Check that bultin argument is
5378 correct.
5379 * c-parser.c (c_parser_array_notation): Check for incorrect initial
5380 index.
5381
9698b078
SH
53822014-06-27 Sebastian Huber <sebastian.huber@embedded-brains.de>
5383
5384 * c-parser.c (c_parser_declaration_or_fndef): Discard all type
5385 qualifiers in __auto_type for atomic types.
5386 (c_parser_typeof_specifier): Discard all type qualifiers in
5387 __typeof__ for atomic types.
5388
6e07c515
MP
53892014-06-25 Marek Polacek <polacek@redhat.com>
5390
5391 PR c/61162
5392 * c-parser.c (c_parser_statement_after_labels): Pass the location of
5393 the return expression to c_finish_return.
5394
da6f124d
JJ
53952014-06-25 Jakub Jelinek <jakub@redhat.com>
5396
5397 * c-typeck.c (c_finish_omp_clauses): Make sure
5398 OMP_CLAUSE_LINEAR_STEP has correct type.
5399
c203e8a7
TS
54002014-06-24 Trevor Saunders <tsaunders@mozilla.com>
5401
5402 * c-decl.c: Adjust.
5403
56ad0e38
JJ
54042014-06-24 Jakub Jelinek <jakub@redhat.com>
5405
5406 * c-parser.c (c_parser_omp_for_loop): For
5407 #pragma omp parallel for simd move lastprivate clause from parallel
5408 to for rather than simd.
5409
47c2554f
MP
54102014-06-23 Marek Polacek <polacek@redhat.com>
5411
5412 * c-typeck.c (parser_build_binary_op): Don't call
5413 warn_logical_not_parentheses if the RHS is TRUTH_NOT_EXPR.
5414
56363ffd
JH
54152014-06-15 Jan Hubicka <hubicka@ucw.cz>
5416
5417 * c-parser.c (c_parser_omp_threadprivate): Likewise.
5418 * c-decl.c (merge_decls): Likewise.
5419
d7ff7ae5
MP
54202014-06-09 Marek Polacek <polacek@redhat.com>
5421
5422 PR c/36446
5423 * c-typeck.c (error_init): Call inform instead of error_at.
5424 (pedwarn_init): Call inform instead of pedwarn.
5425 (warning_init): Call inform instead of warning_at.
5426
24d047a3
JH
54272014-06-07 Jan Hubicka <hubicka@ucw.cz>
5428
5429 * c-decl.c (merge_decls): Use set_decl_section_name.
5430 (duplicate_decls): Remove node if it exists.
5431
9bac5cbb
G
54322014-06-05 S. Gilles <sgilles@terpmail.umd.edu>
5433
5434 PR c/53119
5435 * c-typeck.c (push_init_level, process_init_element,
5436 pop_init_level): Correct check for zero initialization, move
5437 missing brace warning to respect zero initialization.
5438
8ffcdea8
MP
54392014-06-05 Marek Polacek <polacek@redhat.com>
5440
5441 PR c/56724
5442 * c-typeck.c (convert_for_assignment): Use expr_loc for ic_argpass.
5443
742938c9
MP
54442014-06-05 Marek Polacek <polacek@redhat.com>
5445
5446 PR c/49706
5447 * c-typeck.c (parser_build_binary_op): Warn when logical not is used
ab20d992 5448 on the left hand side operand of a comparison.
742938c9 5449
6447c55d
MP
54502014-06-05 Marek Polacek <polacek@redhat.com>
5451
5452 PR c/48062
5453 * c-decl.c (warn_if_shadowing): Call inform instead of warning_at.
5454 Print note only if the warning was printed.
5455
9dc7743c
IZ
54562014-06-04 Igor Zamyatin <igor.zamyatin@intel.com>
5457
5458 PR c/58942
5459 * c-array-notation.c (fix_builtin_array_notation_fn): Handle the case
5460 with a pointer.
5461
fedfecef
MP
54622014-06-03 Marek Polacek <polacek@redhat.com>
5463
5464 PR c/60439
5465 * c-parser.c (c_parser_switch_statement): Pass explicit_cast_p to
5466 c_start_case.
5467 * c-tree.h (c_start_case): Update.
5468 * c-typeck.c (c_start_case): Add new boolean parameter. Warn if
5469 switch condition has boolean value.
5470
9b2b7279
AM
54712014-06-02 Andrew MacLeod <amacleod@redhat.com>
5472
5473 * c-decl.c: Include builtins.h.
5474 * c-parser.c: Likewise.
5475
5c1bc275
MP
54762014-05-27 Marek Polacek <polacek@redhat.com>
5477
5478 PR c/56724
5479 * c-typeck.c (convert_arguments): Get location of a parameter. Change
5480 error and warning calls to error_at and warning_at. Pass location of
5481 a parameter to it. Call warning_at with OPT_Wtraditional_conversion.
5482 (convert_for_assignment): Add parameter to WARN_FOR_ASSIGNMENT and
5483 WARN_FOR_QUALIFIERS. Pass expr_loc to those.
5484
97563bc8
IZ
54852014-05-26 Igor Zamyatin <igor.zamyatin@intel.com>
5486
5487 PR c/61191
5488 * c-array-notation.c (fix_builtin_array_notation_fn): Check invalid
5489 function parameters.
5490
aede2c10
JH
54912014-05-23 Jan Hubicka <hubicka@ucw.cz>
5492
5493 * c-decl.c (merge_decls): Preserve symtab node pointers.
5494 (duplicate_decls): Free new decl.
5495
edbba2ce
TS
54962014-05-23 Thomas Schwinge <thomas@codesourcery.com>
5497
f3316c6d
TS
5498 * c-typeck.c (c_finish_omp_clauses): Remove duplicated variable
5499 initialization.
5500
edbba2ce
TS
5501 * c-parser.c (c_parser_omp_target): Return bool values.
5502
68c81f24
TS
55032014-05-22 Thomas Schwinge <thomas@codesourcery.com>
5504
5505 * c-parser.c (c_parser_omp_clause_thread_limit): Rename
5506 num_teams_loc variable to num_thread_limit_loc.
5507
632f2871
RS
55082014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
5509
5510 * c-array-notation.c (expand_array_notations): Use void_node
5511 instead of void_zero_node.
5512
766090c2
TS
55132014-05-17 Trevor Saunders <tsaunders@mozilla.com>
5514
5515 * c-decl.c (finish_struct): Adjust.
5516 (finish_enum): Likewise.
5517 (bind): Adjust.
5518 (record_inline_static): Likewise.
5519 (push_scope): Likewise.
5520 (make_label): Likewise.
5521 (lookup_label_for_goto): Likewise.
5522 (finish_struct): Likewise.
5523 (finish_enum): Likewise.
5524 (store_parm_decls): Likewise.
5525 (c_push_function_context): Likewise.
5526 * c-lang.h: Remove usage of variable_size gty attribute.
5527 * c-parser.c (c_parse_init): Adjust.
5528 (c_parse_file): Likewise.
5529
2b107f6b
MP
55302014-05-13 Marek Polacek <polacek@redhat.com>
5531
5532 PR c/61162
5533 * c-typeck.c (convert_for_assignment): Pass location to
5534 WARN_FOR_ASSIGNMENT instead of input_location.
5535
d033409e
MP
55362014-05-10 Marek Polacek <polacek@redhat.com>
5537
5538 * c-parser.c (c_parser_declaration_or_fndef): Pass init_loc to
5539 maybe_warn_string_init.
5540 (c_parser_postfix_expression_after_paren_type): Pass type_loc to
5541 maybe_warn_string_init.
5542 * c-tree.h (maybe_warn_string_init): Update declaration.
5543 * c-typeck.c (maybe_warn_string_init): Add location parameter.
5544 Call pedwarn_init with loc instead of with input_location.
5545 (digest_init): Pass init_loc to maybe_warn_string_init.
5546 (pop_init_level): Call pedwarn_init with loc instead of with
5547 input_location.
5548 (set_init_index): Likewise.
5549 (process_init_element): Likewise.
5550
ea58ef42
MP
55512014-05-09 Marek Polacek <polacek@redhat.com>
5552
5553 PR c/61096
5554 * c-parser.c (c_parser_braced_init): Pass brace_loc to push_init_level.
5555 (c_parser_initelt): Pass location to set_init_label. Pass array index
5556 location to set_init_index.
5557 * c-tree.h (push_init_level): Update declaration.
5558 (pop_init_level): Likewise.
5559 (set_init_index): Likewise.
5560 (set_init_label): Likewise.
5561 * c-typeck.c (error_init): Add location parameter. Call error_at
5562 instead of error.
5563 (digest_init): Pass init_loc to error_init.
5564 (really_start_incremental_init):
5565 (push_init_level): Add location parameter. Pass loc to pop_init_level
5566 and error_init.
5567 (pop_init_level): Likewise.
5568 (set_designator): Add location parameter. Pass loc to pop_init_level,
5569 push_init_level, and error_init.
5570 (set_init_index): Add location parameter. Pass loc to error_init and
5571 set_designator.
5572 (set_init_label): Likewise.
5573 (output_init_element): Pass loc to error_init.
5574 (process_init_element): Pass loc to error_init, pop_init_level,
5575 pedwarn_init, and push_init_level.
5576
661a0813
MP
55772014-05-09 Marek Polacek <polacek@redhat.com>
5578
5579 PR c/50459
5580 * c-parser.c (c_parser_attributes): Parse the arguments as an
5581 expression-list if the attribute takes identifier.
5582
2793eeab
MP
55832014-05-08 Marek Polacek <polacek@redhat.com>
5584
5585 PR c/61053
5586 * c-decl.c (grokdeclarator): Use min_align_of_type instead of
5587 TYPE_ALIGN_UNIT.
5588
f827930a
MP
55892014-05-08 Marek Polacek <polacek@redhat.com>
5590
5591 PR c/61077
5592 * c-decl.c (start_function): Warn for _Atomic-qualified return type
5593 of main.
5594
1d60af08
KZ
55952014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
5596 Mike Stump <mikestump@comcast.net>
5597 Richard Sandiford <rdsandiford@googlemail.com>
5598
5599 * c-decl.c (check_bitfield_type_and_width): Use TYPE_SIGN.
5600 (finish_enum): Use wide-int interfaces.
5601 * c-parser.c (c_parser_cilk_clause_vectorlength): Likewise.
5602 * c-typeck.c (build_c_cast): Likewise.
5603 (set_nonincremental_init_from_string): Likewise.
5604 (c_tree_equal): Likewise.
5605
a0e24419
MP
56062014-05-02 Marek Polacek <polacek@redhat.com>
5607
5608 PR c/25801
5609 * c-typeck.c (c_size_in_bytes): Update comment. Don't call error.
5610 Return size_one_node when the type is not complete.
5611 (pointer_diff): Remove comment.
5612 (build_unary_op): Improve error messages.
5613
19fc9faa
MP
56142014-05-02 Marek Polacek <polacek@redhat.com>
5615
5616 * c-typeck.c (c_finish_return): Separate warning_at calls.
5617
63bc4e87
MP
56182014-05-02 Marek Polacek <polacek@redhat.com>
5619
5620 * c-tree.h (error_init): Remove declaration.
5621 (pedwarn_init): Likewise.
5622 * c-typeck.c (error_init): Make static and move above.
5623 (pedwarn_init): Likewise.
5624 (warning_init): Move above.
5625 (maybe_warn_string_init): Likewise.
5626
4bd2511b
JL
56272014-05-01 Jeff Law <law@redhat.com>
5628
5629 Revert:
5630
5631 2014-04-24 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
5632 * c-parser.c (c_parser_sizeof_expression): Reorganize slightly to
5633 avoid goto.
5634
6a358dcb
MP
56352014-05-02 Marek Polacek <polacek@redhat.com>
5636
5637 PR c/60784
5638 * c-typeck.c (push_init_level): Set constructor_designated to
5639 p->designated for structures.
5640
ae5ebda4
MP
56412014-05-01 Marek Polacek <polacek@redhat.com>
5642
5643 PR c/60915
5644 * c-parser.c (c_parser_declaration_or_fndef): Give better error if
5645 function-definition has an attribute after the declarator.
5646
96b40f8d
MP
56472014-05-01 Marek Polacek <polacek@redhat.com>
5648
5649 PR c/60257
5650 * c-typeck.c (warning_init): Add location_t parameter. Call
5651 warning_at instead of warning.
5652 (push_init_level): Pass input_location to warning_init.
5653 (add_pending_init): Add location_t parameter. Pass loc to
5654 warning_init.
5655 (set_nonincremental_init): Pass input_location to add_pending_init.
5656 (set_nonincremental_init_from_string): Likewise.
5657 (output_init_element): Pass loc to warning_init and to
5658 add_pending_init.
5659
32e00768
MP
56602014-05-01 Marek Polacek <polacek@redhat.com>
5661
5662 PR c/43395
5663 * c-typeck.c (c_finish_return): Distinguish between label and variable
5664 when warning about returning local address.
5665
c9379ce2
MP
56662014-05-01 Marek Polacek <polacek@redhat.com>
5667
5668 PR c/29467
5669 * c-decl.c (declspecs_add_type): Pedwarn if boolean types are used
5670 in C89 mode.
5671
d00887e8
MP
56722014-05-01 Marek Polacek <polacek@redhat.com>
5673
5674 PR c/43245
5675 * c-typeck.c (convert_for_assignment): Pass OPT_Wdiscarded_qualifiers
5676 instead of 0 to WARN_FOR_QUALIFIERS.
5677
5436fa2e
MP
56782014-05-01 Marek Polacek <polacek@redhat.com>
5679
5680 PR c/56989
5681 * c-typeck.c (default_conversion): Use better location for
5682 error call.
5683
f8ed5150
MP
56842014-04-30 Marek Polacek <polacek@redhat.com>
5685
5686 * c-typeck.c (build_binary_op): Call ubsan_instrument_division
5687 also when SANITIZE_FLOAT_DIVIDE is on.
5688
8337d1db
MP
56892014-04-30 Marek Polacek <polacek@redhat.com>
5690
5691 PR c/60139
5692 * c-typeck.c (output_init_element): Pass OPT_Wpedantic to pedwarn
5693 and pedwarn_init. Use loc insted of input_location.
5694
c4bdc42f
MP
56952014-04-30 Marek Polacek <polacek@redhat.com>
5696
5697 PR c/60351
5698 * c-typeck.c (build_binary_op): Use location when warning about
5699 shift count.
5700
45484dcf
MP
57012014-04-25 Marek Polacek <polacek@redhat.com>
5702
5703 PR c/18079
5704 * c-decl.c (diagnose_mismatched_decls): Warn for mismatched
5705 always_inline/noinline and hot/cold attributes.
5706
34cf811f
MP
57072014-04-25 Marek Polacek <polacek@redhat.com>
5708
5709 PR c/60114
5710 * c-parser.c (c_parser_initelt): Pass input_location to
5711 process_init_element.
5712 (c_parser_initval): Pass loc to process_init_element.
5713 * c-tree.h (process_init_element): Adjust declaration.
5714 * c-typeck.c (push_init_level): Pass input_location to
5715 process_init_element.
5716 (pop_init_level): Likewise.
5717 (set_designator): Likewise.
5718 (output_init_element): Add location_t parameter. Pass loc to
5719 digest_init.
5720 (output_pending_init_elements): Pass input_location to
5721 output_init_element.
5722 (process_init_element): Add location_t parameter. Pass loc to
5723 output_init_element.
5724
42056eac
JJ
57252014-04-24 Jakub Jelinek <jakub@redhat.com>
5726
5727 * c-parser.c (c_parser_omp_atomic): Allow seq_cst before
5728 atomic-clause, allow comma in between atomic-clause and
5729 seq_cst.
5730
e162a134
JJ
57312014-04-22 Jakub Jelinek <jakub@redhat.com>
5732
5733 PR c/59073
5734 * c-parser.c (c_parser_omp_parallel): If c_parser_omp_for
5735 fails, don't set OM_PARALLEL_COMBINED and return NULL.
5736
2f6babac
IZ
57372014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
5738
5739 PR middle-end/60469
5740 * c-array-notation.c (fix_builtin_array_notation_fn): Use
5741 create_tmp_var instead build_decl for creating temps.
5742 (build_array_notation_expr): Likewise.
5743 (fix_conditional_array_notations_1): Likewise.
5744 (fix_array_notation_expr): Likewise.
5745 (fix_array_notation_call_expr): Likewise.
5746
8edbfaa6
JJ
57472014-03-28 Jakub Jelinek <jakub@redhat.com>
5748
5749 PR c++/60689
5750 * c-tree.h (c_build_function_call_vec): New prototype.
5751 * c-typeck.c (build_function_call_vec): Don't call
5752 resolve_overloaded_builtin here.
5753 (c_build_function_call_vec): New wrapper function around
5754 build_function_call_vec. Call resolve_overloaded_builtin here.
5755 (convert_lvalue_to_rvalue, build_function_call, build_atomic_assign):
5756 Call c_build_function_call_vec instead of build_function_call_vec.
5757 * c-parser.c (c_parser_postfix_expression_after_primary): Likewise.
5758 * c-decl.c (finish_decl): Likewise.
5759
7485aeea
MLI
57602014-03-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
5761
5762 PR c/55383
5763 * c-typeck.c: Use correct format string in cast-qual warning
5764
b17a8b07
TS
57652014-03-07 Thomas Schwinge <thomas@codesourcery.com>
5766
5767 * c-decl.c (c_decl_attributes): Use
5768 lang_hooks.types.omp_mappable_type.
5769 * c-typeck.c (c_finish_omp_clauses): Likewise.
5770
3af9c5e9
MP
57712014-03-06 Marek Polacek <polacek@redhat.com>
5772
5773 PR c/60197
5774 * c-typeck.c (c_finish_return): Call contains_cilk_spawn_stmt instead
5775 of checking tree code.
5776
1c9f5f33
PK
57772014-02-19 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
5778
5779 * c-parser.c (c_parser_declspecs): Replace call to error by error_at.
5780 (c_parser_parameter_declaration): Likewise.
5781
cc28fc7f
MP
57822014-02-19 Marek Polacek <polacek@redhat.com>
5783
5784 PR c/60195
5785 * c-typeck.c (convert_lvalue_to_rvalue): Set TREE_NO_WARNING on tmp.
5786 Call mark_exp_read on exp.value.
5787 (build_atomic_assign): Set TREE_NO_WARNING on val and old. Set
5788 TREE_ADDRESSABLE on old instead of val.
5789 (emit_side_effect_warnings): Warn only if RHS has !TREE_NO_WARNING.
5790
b581c05c
PK
57912014-02-07 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
5792
5793 * c-parser.c (c_parser_get_builtin_args): Replace calls to
5794 C_EXPR_APPEND by vec_safe_push.
5795 * c-tree.h (C_EXPR_APPEND): Remove.
5796
81e5eca8
MP
57972014-01-31 Marek Polacek <polacek@redhat.com>
5798
5799 PR c/59963
5800 * c-typeck.c (convert_lvalue_to_rvalue): Pass vNULL to
5801 build_function_call_vec.
5802 (build_function_call): Likewise.
5803 (build_atomic_assign): Likewise.
5804 (build_function_call_vec): Add arg_loc parameter. Use it.
5805 (convert_arguments): Likewise.
5806 (convert_for_assignment): Rename rhs_loc to expr_loc.
5807 * c-parser.c (c_parser_attributes): Pass NULL to c_parser_expr_list.
5808 (c_parser_objc_keywordexpr): Likewise.
5809 (c_parser_postfix_expression_after_primary): Call
5810 build_function_call_vec with expr_loc rather than op_loc.
5811 Call c_parser_expr_list to fill arg_loc. Pass arg_loc to
5812 build_function_call_vec.
5813 (c_parser_expr_list): Add locations parameter. Fill it with locations
5814 of function arguments.
5815 * c-decl.c (finish_decl): Pass vNULL to build_function_call_vec.
5816
68fca595
MP
58172014-01-30 Marek Polacek <polacek@redhat.com>
5818
5819 PR c/59940
5820 * c-typeck.c (build_function_call_vec): Use loc parameter.
5821 (convert_arguments): Add location parameter. Use it.
5822 (ep_convert_and_check): Likewise.
5823 (build_atomic_assign): Adjust convert_for_assignment call.
5824 (build_modify_expr): Likewise.
5825 (digest_init): Likewise.
5826 (c_finish_return): Likewise.
5827 (build_conditional_expr): Adjust ep_convert_and_check calls.
5828 (convert_for_assignment): Add rhs_loc parameter. Use it.
5829 (build_binary_op): Adjust convert_and_check and ep_convert_and_check
5830 calls.
5831
fa337f3a
RB
58322014-01-30 Richard Biener <rguenther@suse.de>
5833
5834 PR c/59905
5835 * c-typeck.c (build_function_call_vec): Do not replace calls
5836 to a function via an incompatible type with a runtime abort.
5837
b72271b9
BI
58382014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
5839
5840 * c-parser.c (c_parser_declaration_or_fndef): Replaced
5841 flag_enable_cilkplus with flag_cilkplus.
5842 (c_parser_direct_declarator_inner): Likewise.
5843 (c_parser_attribute_any_word): Likewise.
5844 (c_parser_attributes): Likewise.
5845 (c_parser_compound_statement): Likewise.
5846 (c_parser_statement_after_labels): Likewise.
5847 (c_parser_if_statement): Likewise.
5848 (c_parser_switch_statement): Likewise.
5849 (c_parser_do_statement): Likewise.
5850 (c_parser_for_statement): Likewise.
5851 (c_parser_unary_expression): Likewise.
5852 (c_parser_postfix_expression): Likewise.
5853 (c_parser_postfix_expression_after_primary): Likewise.
5854 (c_parser_postfix_expression_after_primary): Likewise.
5855 (c_parser_omp_clause_name): Likewise.
5856 (c_finish_omp_declare_simd): Likewise.
5857 (c_parser_cilk_verify_simd): Likewise.
5858 * c-typeck.c (build_array_ref): Likewise.
5859 (build_function_call_vec): Likewise.
5860 (convert_arguments): Likewise.
5861 (build_compound_expr): Likewise.
5862 (c_finish_return): Likewise.
5863 (c_finish_if_stmt): Likewise.
5864 (c_finish_loop): Likewise.
5865 (build_binary_op): Likewise.
5866
393e8e8b
MP
58672014-01-23 Marek Polacek <polacek@redhat.com>
5868
5869 PR c/59846
5870 * c-typeck.c (parser_build_binary_op): Use location instead of
5871 input_location.
5872 (build_binary_op): Pass location to shorten_compare.
5873
f04dda30
MP
58742014-01-23 Marek Polacek <polacek@redhat.com>
5875
5876 PR c/58346
5877 * c-typeck.c (pointer_diff): Give an error on arithmetic on pointer to
5878 an empty aggregate.
5879
789eadcd
MP
58802014-01-23 Marek Polacek <polacek@redhat.com>
5881
5882 PR c/59871
5883 * c-typeck.c (build_compound_expr): Warn even for right-hand operand
5884 of a comma expression.
5885 (emit_side_effect_warnings): Likewise.
5886
40f14e9f
BI
58872014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com>
5888
5889 PR c/59825
5890 * c-array-notation.c (expand_array_notation_exprs): Rewrote this
5891 function to use walk_tree and moved a lot of its functionality to
5892 expand_array_notations.
5893 (expand_array_notations): New function.
5894
74558dd9
BI
58952014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com>
5896
5897 * c-parser.c (c_finish_omp_declare_simd): Made "cilk simd function"
5898 attribute an attribute without value.
5899
652fea39
JJ
59002014-01-23 Jakub Jelinek <jakub@redhat.com>
5901
5902 PR middle-end/58809
5903 * c-typeck.c (c_finish_omp_clause): Reject MIN_EXPR, MAX_EXPR,
5904 BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR on COMPLEX_TYPEs.
5905
f34f1c87
MP
59062014-01-22 Marek Polacek <polacek@redhat.com>
5907
5908 PR c/59891
5909 * c-typeck.c (build_conditional_expr): Call c_fully_fold instead
5910 of remove_c_maybe_const_expr on op1 and op2.
5911
241f845a
JJ
59122014-01-15 Jakub Jelinek <jakub@redhat.com>
5913
5914 PR c/58943
5915 * c-typeck.c (build_modify_expr): For lhs op= rhs, if rhs has side
5916 effects, preevaluate rhs using SAVE_EXPR first.
5917
9a74f20c
BI
59182014-01-09 Balaji V. Iyer <balaji.v.iyer@intel.com>
5919
5920 PR c++/59631
5921 * c-parser.c (c_parser_postfix_expression): Replaced consecutive if
5922 statements with if-elseif statements.
5923
96066ce1
MP
59242014-01-06 Marek Polacek <polacek@redhat.com>
5925
5926 PR c/57773
5927 * c-decl.c (check_bitfield_type_and_width): Warn for implementation
5928 defined bit-field types only in ISO C.
5929
23a5b65a
RS
59302014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
5931
5932 Update copyright years
5933
f9030485
RS
59342014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
5935
5936 * c-array-notation.c: Use the standard form for the copyright notice.
5937
41958c28
BI
59382013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
5939
5940 * c-parser.c (struct c_parser::cilk_simd_fn_tokens): Added new field.
5941 (c_parser_declaration_or_fndef): Added a check if cilk_simd_fn_tokens
5942 field in parser is not empty. If not-empty, call the function
5943 c_parser_finish_omp_declare_simd.
5944 (c_parser_cilk_clause_vectorlength): Modified function to be shared
5945 between SIMD-enabled functions and #pragma simd. Added new parameter.
5946 (c_parser_cilk_all_clauses): Modified the usage of the function
5947 c_parser_cilk_clause_vectorlength as mentioned above.
5948 (c_parser_cilk_simd_fn_vector_attrs): New function.
5949 (c_finish_cilk_simd_fn_tokens): Likewise.
5950 (is_cilkplus_vector_p): Likewise.
5951 (c_parser_omp_clause_name): Added checking for "vectorlength,"
5952 "nomask," and "mask" strings in clause name.
5953 (c_parser_omp_all_clauses): Added 3 new case statements:
5954 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_MASK and
5955 PRAGMA_CILK_CLAUSE_NOMASK.
5956 (c_parser_attributes): Added a cilk_simd_fn_tokens parameter. Added a
5957 check for vector attribute and if so call the function
5958 c_parser_cilk_simd_fn_vector_attrs. Also, when Cilk plus is enabled,
5959 called the function c_finish_cilk_simd_fn_tokens.
5960 (c_finish_omp_declare_simd): Added a check if cilk_simd_fn_tokens in
5961 parser field is non-empty. If so, parse them as you would parse
5962 the omp declare simd pragma.
5963 (c_parser_omp_clause_linear): Added a new bool parm. is_cilk_simd_fn.
5964 Added a check when step is a parameter and flag it as error.
5965 (CILK_SIMD_FN_CLAUSE_MASK): New #define.
5966 (c_parser_cilk_clause_name): Changed pragma_cilk_clause to
5967 pragma_omp_clause.
5968
cef0fd0e
TS
59692013-12-17 Thomas Schwinge <thomas@codesourcery.com>
5970
5971 * c-parser.c (c_parser_omp_parallel): Fix description.
5972
12893402
BI
59732013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
5974
5975 * c-objc-common.h (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Remove.
5976 (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise.
5977 (LANG_HOOKS_CILKPLUS_CILKPLUS_GIMPLIFY_SPAWN): Likewise.
5978 * c-typeck.c (cilk_install_body_with_frame_cleanup): New function.
5979
296674db
JM
59802013-12-04 Joseph Myers <joseph@codesourcery.com>
5981
5982 PR c/52023
5983 * c-parser.c (c_parser_alignas_specifier): Use
5984 c_sizeof_or_alignof_type instead of c_alignof.
5985 (c_parser_alignof_expression): Likewise, with min_alignof
5986 parameter depending on alignof spelling used.
5987
edd28054
MP
59882013-12-04 Marek Polacek <polacek@redhat.com>
5989
5990 PR c/54113
5991 * c-decl.c (start_function): Don't warn for missing prototype for
5992 inline functions.
5993
da0fc454
MP
59942013-12-03 Marek Polacek <polacek@redhat.com>
5995
5996 PR c/59351
5997 * c-decl.c (build_compound_literal): Allow compound literals with
5998 empty initial value.
5999
4c2ecab0
JM
60002013-12-02 Joseph Myers <joseph@codesourcery.com>
6001
6002 PR c/58235
6003 * c-typeck.c (build_modify_expr): Diagnose assignment to
6004 expression with array type.
6005
340baef7
JM
60062013-11-29 Joseph Myers <joseph@codesourcery.com>
6007
6008 PR c/42262
6009 * c-typeck.c (process_init_element): Do not treat a string as
6010 initializing a whole array when used with a designator for an
6011 individual element.
6012
6763b9f7
JM
60132013-11-29 Joseph Myers <joseph@codesourcery.com>
6014
6015 PR c/57574
6016 * c-decl.c (merge_decls): Clear DECL_EXTERNAL for a definition of
6017 an inline function following a static declaration.
6018
e7bd1de1
JJ
60192013-11-28 Jakub Jelinek <jakub@redhat.com>
6020
6021 PR c/59310
6022 * c-parser.c (c_parser_omp_target): Copy "#pragma omp target"
6023 to p_name before calling c_parser_omp_teams instead of after.
6024 (c_parser_cilk_simd): Remove wrong ATTRIBUTE_UNUSED from parser
6025 argument. Remove unused p_name variable.
6026
0136f8f0
AH
60272013-11-27 Aldy Hernandez <aldyh@redhat.com>
6028 Jakub Jelinek <jakub@redhat.com>
6029
6030 * c-decl.c (c_builtin_function_ext_scope): Avoid binding if
6031 external_scope is NULL.
6032
241b71bb
TV
60332013-11-27 Tom de Vries <tom@codesourcery.com>
6034 Marc Glisse <marc.glisse@inria.fr>
6035
6036 PR c++/59032
6037 * c-typeck.c (build_unary_op): Allow vector increment and decrement.
6038
2fb9a547
AM
60392013-11-22 Andrew MacLeod <amacleod@redhat.com>
6040
6041 * c-typeck.c: Add required include files from gimple.h.
6042
8400e75e
DM
60432013-11-22 David Malcolm <dmalcolm@redhat.com>
6044
6045 * c-decl.c (define_label, shadow_tag_warned)
6046 (check_bitfield_type_and_width, grokdeclarator, grokparms,
6047 store_parm_decls_newstyle, store_parm_decls_oldstyle)
6048 (declspecs_add_type): Remove use of in_system_header macro.
6049 * c-parser.c (c_parser_unary_expression): Likewise.
6050 * c-typeck.c (store_init_value, process_init_element)
6051 (c_start_case): Likewise.
6052
6053 * c-decl.c (build_enumerator): Remove use of EXPR_LOC_OR_HERE
6054 macro.
6055
6056 * c-parser.c (c_parser_set_source_position_from_token): Remove
6057 reference to in_system_header from comment.
6058
386b1f1f
RS
60592013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6060
6061 * c-decl.c (grokdeclarator): Update comment to refer to
6062 tree_to_[su]hwi rather than tree_low_cst.
6063
ae7e9ddd
RS
60642013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6065
6066 * c-decl.c, c-typeck.c: Replace tree_low_cst (..., 1) with
6067 tree_to_uhwi throughout.
6068
9439e9a1
RS
60692013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6070
6071 * c-parser.c: Replace tree_low_cst (..., 0) with tree_to_shwi
6072 throughout.
6073
9541ffee
RS
60742013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
6075
6076 * c-parser.c: Replace host_integerp (..., 0) with tree_fits_shwi_p
6077 throughout.
6078
c02065fc
AH
60792013-11-15 Aldy Hernandez <aldyh@redhat.com>
6080
6081 * c-parser.c (c_parser_cilk_simd): New.
6082 (c_parser_cilk_verify_simd): New.
6083 (c_parser_pragma): Add case for PRAGMA_CILK_SIMD.
6084 (c_parser_omp_for_loop): Add case for NE_EXPR.
6085 Set c_break_label for CILK_SIMD.
6086 (c_parser_cilk_clause_vectorlength): New.
6087 (c_parser_cilk_clause_linear): New.
6088 (c_parser_cilk_clause_name): New.
6089 (c_parser_cilk_all_clauses): New.
6090 * c-typeck.c (build_unary_op): Pass location argument to
6091 readonly_error.
6092 (build_modify_expr): Same.
6093 (build_asm_expr): Same.
6094 (c_finish_bc_stmt): Error on break/continue in loops.
6095
18f429e2
AM
60962013-11-14 Andrew MacLeod <amacleod@redhat.com>
6097
6098 * c-typeck.c: Include only gimplify.h and gimple.h as needed.
6099
d8a2d370
DN
61002013-11-14 Diego Novillo <dnovillo@google.com>
6101
6102 * c-decl.c: Include print-tree.h.
6103 Include stor-layout.h.
6104 Include varasm.h.
6105 Include attribs.h.
6106 Include stringpool.h.
6107 * c-lang.c: Include fold-const.h.
6108 * c-parser.c: Include stringpool.h.
6109 Include attribs.h.
6110 Include stor-layout.h.
6111 Include varasm.h.
6112 Include trans-mem.h.
6113 * c-typeck.c: Include stor-layout.h.
6114 Include trans-mem.h.
6115 Include varasm.h.
6116 Include stmt.h.
6117
38b7bc7f
JM
61182013-11-13 Joseph Myers <joseph@codesourcery.com>
6119
6120 * c-tree.h (c_typespec_keyword): Add cts_auto_type.
6121 * c-decl.c (declspecs_add_type, finish_declspecs): Handle
6122 __auto_type.
6123 * c-parser.c (c_token_starts_typename, c_token_starts_declspecs)
6124 (c_parser_attribute_any_word, c_parser_objc_selector): Handle
6125 RID_AUTO_TYPE.
6126 (c_parser_declspecs): Take argument AUTO_TYPE_OK.
6127 (c_parser_declaration_or_fndef, c_parser_struct_declaration)
6128 (c_parser_declarator, c_parser_direct_declarator_inner)
6129 (c_parser_parameter_declaration, c_parser_type_name): All callers
6130 changed.
6131 (c_parser_declaration_or_fndef): Handle declarations with type
6132 determined from the initializer.
6133
45b0be94
AM
61342013-11-12 Andrew MacLeod <amacleod@redhat.com>
6135
18f429e2 6136 * c-typeck.c: Include gimplify.h.
45b0be94 6137
582d9b50
JM
61382013-11-12 Joseph Myers <joseph@codesourcery.com>
6139
6140 * c-tree.h (struct c_declspecs): Add thread_gnu_p field.
6141 * c-parser.c (c_parser_declspecs): Mention _Thread_local in
6142 comment.
6143 * c-decl.c (shadow_tag_warned, grokdeclarator): Mention __thread
6144 or _Thread_local as appropriate in diagnostics.
6145 (build_null_declspecs): Initialize ret->thread_gnu_p.
6146 (declspecs_add_scspec): Handle either __thread or _Thread_local
6147 for RID_THREAD. Diagnose _Thread_local for pre-C11 standards if
6148 pedantic. Do not disallow _Thread_local extern and _Thread_local
6149 static.
6150
267bac10
JM
61512013-11-07 Joseph Myers <joseph@codesourcery.com>
6152 Andrew MacLeod <amacleod@redhat.com>
6153
6154 * c-aux-info.c (gen_type): Handle atomic qualifier.
6155 * c-decl.c (validate_proto_after_old_defn): Do not remove atomic
6156 qualifiers when compating types.
6157 (shadow_tag_warned): Handle atomic_p in declspecs.
6158 (quals_from_declspecs): Likewise.
6159 (start_decl): Use c_type_promotes_to when promoting argument
6160 types.
6161 (grokdeclarator): Handle _Atomic.
6162 (get_parm_info): Diagnose any qualifier on "void" as only
6163 parameter.
6164 (store_parm_decls_oldstyle): Do not remove atomic qualifiers when
6165 comparing types. Use c_type_promotes_to when promoting argument
6166 types.
6167 (finish_function): Use c_type_promotes_to when promoting argument
6168 types.
6169 (build_null_declspecs): Handle atomic_p in declspecs.
6170 (declspecs_add_qual): Handle RID_ATOMIC.
6171 * c-parser.c (c_token_starts_typename, c_token_is_qualifier)
6172 (c_token_starts_declspecs): Handle RID_ATOMIC.
6173 (c_parser_declspecs): Handle atomic type specifiers and
6174 qualifiers.
6175 (c_parser_typeof_specifier): Remove const and _Atomic qualifiers
6176 from types of expressions with atomic type.
6177 (c_parser_direct_declarator_inner): Use convert_lvalue_to_rvalue.
6178 (c_parser_attribute_any_word): Handle RID_ATOMIC.
6179 (c_parser_initializer, c_parser_initelt, c_parser_initval)
6180 (c_parser_statement_after_labels, c_parser_switch_statement)
6181 (c_parser_for_statement, c_parser_expr_no_commas)
6182 (c_parser_conditional_expression, c_parser_binary_expression)
6183 (c_parser_cast_expression, c_parser_unary_expression)
6184 (c_parser_postfix_expression)
6185 (c_parser_postfix_expression_after_primary, c_parser_expression):
6186 Use convert_lvalue_to_rvalue.
6187 (c_parser_expression_conv, c_parser_expr_list): Document
6188 conversion of lvalues to rvalues. Use convert_lvalue_to_rvalue.
6189 (c_parser_objc_synchronized_statement): Use
6190 convert_lvalue_to_rvalue.
6191 (c_parser_objc_selector): Handle RID_ATOMIC.
6192 (c_parser_objc_receiver, c_parser_array_notation): Use
6193 convert_lvalue_to_rvalue.
6194 * c-tree.h (ctsk_typeof): Adjust comment to mention use for
6195 _Atomic (type-name).
6196 (struct c_declspecs): Add atomic_p field.
6197 (convert_lvalue_to_rvalue): Declare.
6198 * c-typeck.c (c_type_promotes_to): Promote atomic types to
6199 corresponding atomic types.
6200 (qualify_type): Don't add _Atomic qualifiers from second argument.
6201 (comp_target_types): Do not allow _Atomic mismatches.
6202 (type_lists_compatible_p): Do not remove atomic qualifiers when
6203 comparing types.
6204 (really_atomic_lvalue, convert_lvalue_to_rvalue)
6205 (build_atomic_assign): New functions.
6206 (build_unary_op): Use build_atomic_assign for atomic increment and
6207 decrement.
6208 (build_conditional_expr): Do not treat _Atomic void as a qualified
6209 version of void.
6210 (build_modify_expr): Use build_atomic_assign for atomic LHS.
6211 (find_anonymous_field_with_type, convert_to_anonymous_field)
6212 (convert_for_assignment): Do not remove atomic qualifiers when
6213 comparing types.
6214 (digest_init): Do not accept initialization of arrays of atomic
6215 elements by string constants.
6216 (build_asm_expr): Use convert_lvalue_to_rvalue.
6217 (build_binary_op): Do not treat _Atomic void as a qualified
6218 version of void.
6219
0c249d4b
DD
62202013-11-06 DJ Delorie <dj@redhat.com>
6221
6222 * c-decl.c (locate_old_decl): If a previous conflicting decl is
6223 both explicit and builtin, print the location of the explicit one.
6224
6d7f7e0a
TB
62252013-11-05 Tobias Burnus <burnus@net-b.de>
6226
6227 * c-parser.c (c_parser_omp_for, c_parser_omp_parallel,
6228 c_parser_omp_distribute, c_parser_omp_teams,
6229 c_parser_omp_target, c_parser_omp_declare): Handle
6230 -fopenmp-simd.
6231
b906f4ca
MP
62322013-11-03 Marek Polacek <polacek@redhat.com>
6233
6234 * c-decl.c (grokdeclarator): Add VLA instrumentation.
6235
ee1d5a02
JJ
62362013-11-01 Jakub Jelinek <jakub@redhat.com>
6237
6238 * c-typeck.c (c_finish_omp_clauses) <case OMP_CLAUSE_UNIFORM>: Go to
6239 check_dup_generic at the end, unless remove is true.
6240 (c_finish_omp_clauses) <case OMP_CLAUSE_REDUCTION>: Add break; after
6241 remove = true;.
6242 (c_finish_omp_clauses) <case OMP_CLAUSE_COPYIN>: Likewise.
6243
5a9785fb
JJ
62442013-10-31 Jakub Jelinek <jakub@redhat.com>
6245
6246 * c-typeck.c (c_finish_omp_clauses): Diagnose aligned clause
6247 with decl that is not pointer nor array.
6248
939b37da
BI
62492013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
6250
6251 * c-decl.c (finish_function): Added a call for insert_cilk_frame when
6252 a spawning function is found.
6253 * c-objc-common.h (LANG_HOOKS_CILKPLUS_GIMPLIFY_SPAWN): New #define.
6254 (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Likewise.
6255 (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise.
6256 * c-parser.c (c_parser_statement_after_labels): Added RID_CILK_SYNC
6257 case.
6258 (c_parser_postfix_expression): Added RID_CILK_SPAWN case.
6259 * c-typeck.c (build_compound_expr): Reject _Cilk_spawn in a comma
6260 expr.
6261 (c_finish_return): Added a check to reject _Cilk_spawn in return
6262 expression.
6263 (build_cilk_spawn): New function.
6264 (build_cilk_sync): Likewise.
6265 * Makefile.in (c-decl.o): Added cilk.h in dependency list.
ab20d992 6266
d4af74d4
TB
62672013-10-27 Tobias Burnus <burnus@net-b.de>
6268
6269 PR other/33426
6270 * c-parser.c (c_parser_while_statement, c_parser_while_statement,
6271 c_parser_pragma): Add GCC ivdep support to 'do' and 'while'.
6272 (c_parser_statement_after_labels): Update calls.
6273
d73749df 62742013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
6275
6276 PR other/33426
6277 * c-parser.c (c_parser_pragma, c_parser_for_statement):
6278 Handle PRAGMA_IVDEP.
6279 (c_parser_statement_after_labels): Update call.
6280
f28aa681
MP
62812013-10-24 Marek Polacek <polacek@redhat.com>
6282
6283 * c-parser.c (c_parser_struct_declaration): Add a comment.
6284 (c_parser_declarator): Don't allow _Alignas here.
6285
0645c1a2
AM
62862013-10-17 Andrew MacLeod <amacleod@redhat.com>
6287
6288 * c-parser.c: Include omp-low.h.
6289 * c-typeck.c: Likewise.
6290
568a31f2
MP
62912013-10-17 Marek Polacek <polacek@redhat.com>
6292
6293 PR c/58267
6294 * c-parser.c (c_parser_declspecs): Add alignspec_ok parameter.
6295 Document syntax of the array-declarator.
6296 (c_parser_declspecs) <RID_ALIGNAS>: Bail out if alignment specs
6297 are not permitted.
6298 (c_parser_declaration_or_fndef): Adjust c_parser_declspecs call.
6299 (c_parser_struct_declaration): Likewise.
6300 (c_parser_declarator): Likewise.
6301 (c_parser_direct_declarator_inner): Likewise.
6302 (c_parser_parameter_declaration): Likewise.
6303 (c_parser_type_name): Likewise.
6304
acf0174b
JJ
63052013-10-11 Jakub Jelinek <jakub@redhat.com>
6306
6307 * c-lang.h (current_omp_declare_target_attribute): New extern
6308 decl.
6309 * c-parser.c: Include c-lang.h.
6310 (struct c_parser): Change tokens to c_token *.
6311 Add tokens_buf field. Change tokens_avail type to unsigned int.
6312 (c_parser_consume_token): If parser->tokens isn't
6313 &parser->tokens_buf[0], increment parser->tokens.
6314 (c_parser_consume_pragma): Likewise.
6315 (enum pragma_context): Add pragma_struct and pragma_param.
6316 (c_parser_external_declaration): Adjust
6317 c_parser_declaration_or_fndef caller.
6318 (c_parser_declaration_or_fndef): Add omp_declare_simd_clauses
6319 argument, if it is non-vNULL vector, call c_finish_omp_declare_simd.
6320 Adjust recursive call.
6321 (c_parser_struct_or_union_specifier): Use pragma_struct instead
6322 of pragma_external.
6323 (c_parser_parameter_declaration): Use pragma_param instead of
6324 pragma_external.
6325 (c_parser_compound_statement_nostart, c_parser_label,
6326 c_parser_for_statement): Adjust
6327 c_parser_declaration_or_fndef callers.
6328 (c_parser_expr_no_commas): Add omp_atomic_lhs argument, pass
6329 it through to c_parser_conditional_expression.
6330 (c_parser_conditional_expression): Add omp_atomic_lhs argument,
6331 pass it through to c_parser_binary_expression. Adjust recursive
6332 call.
6333 (c_parser_binary_expression): Remove prec argument, add
6334 omp_atomic_lhs argument instead. Always start from PREC_NONE, if
6335 omp_atomic_lhs is non-NULL and one of the arguments of toplevel
6336 binop matches it, use build2 instead of parser_build_binary_op.
6337 (c_parser_pragma): Handle PRAGMA_OMP_CANCEL,
6338 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_TARGET,
6339 PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_DECLARE_REDUCTION.
6340 Handle pragma_struct and pragma_param the same as pragma_external.
6341 (c_parser_omp_clause_name): Parse new OpenMP 4.0 clause names.
6342 (c_parser_omp_variable_list): Parse array sections for
6343 OMP_CLAUSE_{DEPEND,MAP,TO,FROM} clauses.
6344 (c_parser_omp_clause_collapse): Fully fold collapse expression.
6345 (c_parser_omp_clause_reduction): Handle user defined reductions.
6346 (c_parser_omp_clause_branch, c_parser_omp_clause_cancelkind,
6347 c_parser_omp_clause_num_teams, c_parser_omp_clause_thread_limit,
6348 c_parser_omp_clause_aligned, c_parser_omp_clause_linear,
6349 c_parser_omp_clause_safelen, c_parser_omp_clause_simdlen,
6350 c_parser_omp_clause_depend, c_parser_omp_clause_map,
6351 c_parser_omp_clause_device, c_parser_omp_clause_dist_schedule,
6352 c_parser_omp_clause_proc_bind, c_parser_omp_clause_to,
6353 c_parser_omp_clause_from, c_parser_omp_clause_uniform): New functions.
6354 (c_parser_omp_all_clauses): Add finish_p argument. Don't call
6355 c_finish_omp_clauses if it is false. Handle new OpenMP 4.0 clauses.
6356 (c_parser_omp_atomic): Parse seq_cst clause, pass true if it is
6357 present to c_finish_omp_atomic. Handle OpenMP 4.0 atomic forms.
6358 (c_parser_omp_for_loop): Add CODE argument, pass it through
6359 to c_finish_omp_for. Change last argument to cclauses,
6360 and adjust uses to grab parallel clauses from the array of all
6361 the split clauses. Adjust c_parser_binary_expression,
6362 c_parser_declaration_or_fndef and c_finish_omp_for callers.
6363 (omp_split_clauses): New function.
6364 (c_parser_omp_simd): New function.
6365 (c_parser_omp_for): Add p_name, mask and cclauses arguments.
6366 Allow the function to be called also when parsing combined constructs,
6367 and call c_parser_omp_simd when parsing for simd.
6368 (c_parser_omp_sections_scope): If section-sequence doesn't start with
6369 #pragma omp section, require exactly one structured-block instead of
6370 sequence of statements.
6371 (c_parser_omp_sections): Add p_name, mask and cclauses arguments.
6372 Allow the function to be called also when parsing combined constructs.
6373 (c_parser_omp_parallel): Add p_name, mask and cclauses arguments.
6374 Allow the function to be called also when parsing combined
6375 constructs.
6376 (c_parser_omp_taskgroup, c_parser_omp_cancel,
6377 c_parser_omp_cancellation_point, c_parser_omp_distribute,
6378 c_parser_omp_teams, c_parser_omp_target_data,
6379 c_parser_omp_target_update, c_parser_omp_target,
6380 c_parser_omp_declare_simd, c_finish_omp_declare_simd,
6381 c_parser_omp_declare_target, c_parser_omp_end_declare_target,
6382 c_parser_omp_declare_reduction, c_parser_omp_declare): New functions.
6383 (c_parser_omp_construct): Add p_name and mask vars. Handle
6384 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_SIMD, PRAGMA_OMP_TASKGROUP,
6385 PRAGMA_OMP_TEAMS. Adjust c_parser_omp_for, c_parser_omp_parallel
6386 and c_parser_omp_sections callers.
6387 (c_parse_file): Initialize tparser.tokens and the_parser->tokens here.
6388 (OMP_FOR_CLAUSE_MASK, OMP_SECTIONS_CLAUSE_MASK,
6389 OMP_SINGLE_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1.
6390 (OMP_PARALLEL_CLAUSE_MASK): Likewise. Add OMP_CLAUSE_PROC_BIND.
6391 (OMP_TASK_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1. Add
6392 OMP_CLAUSE_DEPEND.
6393 (OMP_SIMD_CLAUSE_MASK, OMP_CANCEL_CLAUSE_MASK,
6394 OMP_CANCELLATION_POINT_CLAUSE_MASK, OMP_DISTRIBUTE_CLAUSE_MASK,
6395 OMP_TEAMS_CLAUSE_MASK, OMP_TARGET_DATA_CLAUSE_MASK,
6396 OMP_TARGET_UPDATE_CLAUSE_MASK, OMP_TARGET_CLAUSE_MASK,
6397 OMP_DECLARE_SIMD_CLAUSE_MASK): Define.
6398 * c-typeck.c: Include tree-inline.h.
6399 (c_finish_omp_cancel, c_finish_omp_cancellation_point,
6400 handle_omp_array_sections_1, handle_omp_array_sections,
6401 c_clone_omp_udr, c_find_omp_placeholder_r): New functions.
6402 (c_finish_omp_clauses): Handle new OpenMP 4.0 clauses and
6403 user defined reductions.
6404 (c_tree_equal): New function.
6405 * c-tree.h (temp_store_parm_decls, temp_pop_parm_decls,
6406 c_finish_omp_cancel, c_finish_omp_cancellation_point, c_tree_equal,
6407 c_omp_reduction_id, c_omp_reduction_decl, c_omp_reduction_lookup,
6408 c_check_omp_declare_reduction_r): New prototypes.
6409 * c-decl.c (current_omp_declare_target_attribute): New variable.
6410 (c_decl_attributes): New function.
6411 (start_decl, start_function): Use it instead of decl_attributes.
6412 (temp_store_parm_decls, temp_pop_parm_decls, c_omp_reduction_id,
6413 c_omp_reduction_decl, c_omp_reduction_lookup,
6414 c_check_omp_declare_reduction_r): New functions.
6415
0a6c2227
TT
64162013-09-25 Tom Tromey <tromey@redhat.com>
6417
6418 * Make-lang.in (c/gccspec.o): Remove.
6419 (CFLAGS-c/gccspec.o): New variable.
6420 (cc1-checksum.o, C_TREE_H, c/c-aux-info.o, c/c-convert.o)
6421 (c/c-decl.o, c/c-errors.o, c/c-lang.o, c/c-objc-common.o)
6422 (c/c-parser.o, c/c-typeck.o, c/c-array-notation.o): Remove.
6423
f3bc55f0
TT
64242013-09-25 Tom Tromey <tromey@redhat.com>
6425
6426 * Make-lang.in (c/gccspec.o): Don't use subshell.
6427
a24d975c
MP
64282013-09-18 Marek Polacek <polacek@redhat.com>
6429
6430 PR sanitize/58443
6431 * c-typeck.c (build_binary_op): Properly honor -fsanitize options.
6432 Remove unnecessary check.
6433
ce6923c5
MP
64342013-09-18 Marek Polacek <polacek@redhat.com>
6435
6436 PR sanitizer/58411
6437 * c-typeck.c (build_binary_op): Don't sanitize function if it has the
6438 no_sanitize_undefined attribute.
6439
a1e51df9
KT
64402013-09-13 Kai Tietz <ktietz@redhat.com>
6441
6442 PR target/57848
6443 * c-decl.c (c_builtin_function_ext_scope): Remove
6444 wrong assumption that it is never called on prexisting
6445 symbol.
6446
0af94e6f
JR
64472013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
6448
6449 * c-typeck.c (build_binary_op): Use vector_types_compatible_elements_p.
6450
20059c8b
GDR
64512013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
6452
6453 * c-objc-common.c (c_tree_printer): Tidy.
6454
de5a5fa1
MP
64552013-08-30 Marek Polacek <polacek@redhat.com>
6456
6457 * c-typeck.c (build_binary_op): Add division by zero and shift
6458 instrumentation.
6459
2531a1d9 64602013-08-26 Joern Rennecke <joern.rennecke@embecosm.com>
0fdd4508 6461 Joseph Myers <joseph@codesourcery.com>
2531a1d9 6462
6e2bcc98 6463 PR c/35649
2531a1d9
JR
6464 * c-typeck.c (c_common_type): Prefer double_type_node over
6465 other REAL_TYPE types with the same precision.
6466 (convert_arguments): Likewise.
6467
025311c4
GDR
64682013-08-23 Gabriel Dos Reis <gdr@integrable-solutions.net>
6469
6470 * c-objc-common.c (c_tree_printer): Document the nature of the cast.
6471 (c_initialize_diagnostics): Call a destructor for the early printer.
6472
da6ca2b5
GDR
64732013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
6474
6475 * c-objc-common.c (c_initialize_diagnostics): Simplify C pretty
6476 printer initialization.
6477
318cda85 64782013-08-19 Balaji V. Iyer <balaji.v.iyer@intel.com>
da6ca2b5 6479
318cda85
BI
6480 PR c/57490
6481 * c-array-notation.c (fix_conditional_array_notations_1): Added a
6482 check for truth values.
6483 (expand_array_notation_exprs): Added truth values case. Removed an
6484 unwanted else. Added for-loop to walk through subtrees in default
6485 case.
6486
b066401f
GDR
64872013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
6488
6489 * c-objc-common.c (c_initialize_diagnostics): Don't call pp_base.
6490
fb48aadc
JM
64912013-07-23 Joseph Myers <joseph@codesourcery.com>
6492
6493 * c-parser.c (struct c_generic_association): Fix typo.
6494
433cc7b0
TT
64952013-07-23 Tom Tromey <tromey@redhat.com>
6496 Joseph Myers <joseph@codesourcery.com>
6497
6498 * c-parser.c (struct c_generic_association): New.
6499 (c_generic_association_d): New typedef.
6500 (c_parser_generic_selection): New function.
6501 (c_parser_postfix_expression): Handle RID_GENERIC.
6502
26d40c3d
JM
65032013-07-13 Jason Merrill <jason@redhat.com>
6504
6505 PR c++/57793
6506 * c-decl.c (finish_struct): Check for too-large class.
6507
ecdbd01a 65082013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
6509
6510 PR c/57821
6511 * c-typeck.c (set_init_index): When folding, check for index overflow.
6512
1141ed3f
BI
65132013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
6514
6515 * c-parser.c (c_parser_array_notation): Removed rejection of array
6516 notations in an array of function pointers.
6517
713b46fa
BI
65182013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
6519
6520 * c-array-notation.c (make_triplet_val_inv): New function.
6521 (create_cmp_incr): Likewise.
6522 (create_array_refs): Likewise.
6523 (fix_builtin_array_notation_fn): Replaced all mallocs with tree vec.
6524 Also modularized common parts between functions and called the function.
6525 (build_array_notation_expr): Likewise.
6526 (fix_conditional_array_notations_1): Likewise.
6527 (fix_array_notation_expr): Likewise.
6528 (fix_array_notation_call_expr): Likewise.
6529
92f20202
MP
65302013-06-18 Marek Polacek <polacek@redhat.com>
6531
6532 PR c/57630
6533 * c-decl.c (check_for_loop_decls): Improve diagnostics messages.
6534
73a23b06
BI
65352013-06-12 Balaji V. Iyer <balaji.v.iyer@intel.com>
6536
6537 * c-array-notation.c (build_array_notation_expr): Reject array notation
6538 mismatch between LHS and RHS even inside a call_expr. Also, removed
6539 a couple while statements that were dead code.
6540
00b8517d
BI
65412013-06-10 Balaji V. Iyer <balaji.v.iyer@intel.com>
6542
6543 * c-array-notation.c (fix_builtin_array_notation_fn): Fully folded
6544 excessive precision expressions in function parameters. Also removed
6545 couple unwanted while statements.
6546
1509bdda
BI
65472013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
6548
6549 * c-array-notation.c (expand_array_notation_exprs): Added
6550 ARRAY_NOTATION_REF case.
ab20d992 6551
d60f1706
BI
65522013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
6553
6554 * c-array-notation.c (length_mismatch_in_expr_p): Moved this
6555 function to c-family/array-notation-common.c.
6556 (is_cilkplus_reduce_builtin): Likewise.
6557 (find_rank): Likewise.
6558 (extract_array_notation_exprs): Likewise.
6559 (replace_array_notations): Likewise.
6560 (find_inv_trees): Likewise.
6561 (replace_inv_trees): Likewise.
6562 (contains_array_notation_expr): Likewise.
6563 (find_correct_array_notation_type): Likewise.
6564 (replace_invariant_exprs): Initialized additional_tcodes to NULL.
6565 (struct inv_list): Moved this to c-family/array-notation-common.c.
6566 * c-tree.h (is_cilkplus_builtin_reduce): Remove prototype.
ab20d992 6567
6d6efbb3
BI
65682013-06-05 Balaji V. Iyer <balaji.v.iyer@intel.com>
6569
6570 * c-typeck.c (convert_arguments): Moved checking of builtin cilkplus
6571 reduction functions outside the for-loop. Added a check if the fundecl
6572 is non-NULL. Finally, removed an unwanted if-statement, and made the
6573 body unconditional.
6574
25c22937
BI
65752013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com>
6576
6577 * c-typeck.c (c_finish_if_stmt): Added a check to see if the rank of the
6578 condition of the if-statement matches the rank of else-block and then-
6579 block when array notations are used.
6580 * c-parser.c (c_parser_declaration_or_fndef): Expanded array notation
6581 expression after the entire function body is parsed.
6582 (c_parser_expr_no_commas): Delayed creating array notation expressions
6583 to the end of function parsing.
6584 * c-array-notation.c (fix_conditional_array_notations_1): Expanded the
6585 whole if-statement instead of just the condition.
ab20d992 6586 (expand_array_notation_exprs): Added MODIFY_EXPR case.
25c22937 6587
edd25645
BI
65882013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com>
6589
6590 PR c/57474
6591 * c-array-notation.c (build_array_notation_expr): Initialized rhs_length
6592 array to NULL_TREE if they are unused. Also added a check for the
6593 field to be NULL before its fields are used in future.
ab20d992 6594
065ce7f1
RO
65952013-05-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6596
6597 PR bootstrap/57450
6598 * c-array-notation.c (length_mismatch_in_expr_p): Use absu_hwi.
6599 (build_array_notation_expr): Likewise.
6600
36536d79
BI
66012013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
6602
6603 * c-typeck.c (build_array_ref): Added a check to see if array's
6604 index is greater than one. If true, then emit an error.
6605 (build_function_call_vec): Exclude error reporting and checking
6606 for builtin array-notation functions.
6607 (convert_arguments): Likewise.
6608 (c_finish_return): Added a check for array notations as a return
6609 expression. If true, then emit an error.
6610 (c_finish_loop): Added a check for array notations in a loop
6611 condition. If true then emit an error.
6612 (lvalue_p): Added a ARRAY_NOTATION_REF case.
6613 (build_binary_op): Added a check for array notation expr inside
6614 op1 and op0. If present, we call another function to find correct
6615 type.
6616 * Make-lang.in (C_AND_OBJC_OBJS): Added c-array-notation.o.
6617 * c-parser.c (c_parser_compound_statement): Check if array
6618 notation code is used in tree, if so, then transform them into
6619 appropriate C code.
6620 (c_parser_expr_no_commas): Check if array notation is used in LHS
6621 or RHS, if so, then build array notation expression instead of
6622 regular modify.
6623 (c_parser_postfix_expression_after_primary): Added a check for
6624 colon(s) after square braces, if so then handle it like an array
6625 notation. Also, break up array notations in unary op if found.
6626 (c_parser_direct_declarator_inner): Added a check for array
6627 notation.
6628 (c_parser_compound_statement): Added a check for array notation in
6629 a stmt. If one is present, then expand array notation expr.
6630 (c_parser_if_statement): Likewise.
6631 (c_parser_switch_statement): Added a check for array notations in
6632 a switch statement's condition. If true, then output an error.
6633 (c_parser_while_statement): Similarly, but for a while.
6634 (c_parser_do_statement): Similarly, but for a do-while.
6635 (c_parser_for_statement): Similarly, but for a for-loop.
6636 (c_parser_unary_expression): Check if array notation is used in a
6637 pre-increment or pre-decrement expression. If true, then expand
6638 them.
6639 (c_parser_array_notation): New function.
6640 * c-array-notation.c: New file.
6641 * c-tree.h (is_cilkplus_reduce_builtin): Protoize.
ab20d992 6642
cd192ccc
MS
66432013-05-23 Mike Stump <mikestump@comcast.net>
6644
6645 * c-typeck.c (convert_for_assignment): Handle references to memory
6646 spaces better.
6647
427b248d
JM
66482013-05-16 Jason Merrill <jason@redhat.com>
6649
6650 * Make-lang.in (cc1$(exeext)): Use link mutex.
6651
44d90fe1
PC
66522013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
6653
6654 * c-typeck.c (pointer_diff): Change -Wpointer-arith pedwarns
6655 to simply use OPT_Wpointer_arith.
6656 (build_unary_op): Likewise.
6657
4e7d7b3d
JJ
66582013-04-03 Jakub Jelinek <jakub@redhat.com>
6659
6660 PR c/19449
6661 * c-parser.c (c_parser_get_builtin_args): Add choose_expr_p
6662 argument. If set, or it temporarily for parsing of the first
6663 argument into force_folding_builtin_constant_p.
6664 (c_parser_postfix_expression): Adjust callers.
6665
839b422f
RB
66662013-03-21 Richard Biener <rguenther@suse.de>
6667
6668 * c-objc-common.c (c_tree_printer): Use DECL_HAS_DEBUG_EXPR_P
6669 instead of DECL_DEBUG_EXPR_IS_FROM. Guard properly.
6670
2ee028f1
MP
66712013-02-12 Marek Polacek <polacek@redhat.com>
6672
6673 PR c/44938
6674 * c-parser.c (c_parser_postfix_expression_after_primary): Initialize
6675 origtypes to NULL.
6676
8824edff
JJ
66772013-01-24 Jakub Jelinek <jakub@redhat.com>
6678
6679 PR c/56078
6680 * c-typeck.c (set_nonincremental_init_from_string): If
6681 constructor_max_index is NULL, treat it as if tree_int_cst_lt
6682 returned false.
6683 (process_init_element): Likewise.
6684
eadd3d0d
JJ
66852012-12-20 Jakub Jelinek <jakub@redhat.com>
6686
6687 PR c++/55619
6688 * c-parser.c (c_parser_asm_operands): Remove CONVERT_P
6689 argument, don't call default_function_array_conversion
6690 nor c_fully_fold here.
6691 (c_parser_asm_statement): Adjust callers.
6692 * c-typeck.c (build_asm_expr): Call c_fully_fold on inputs
6693 and outputs here, and call default_function_array_conversion
6694 on inputs that don't need to be addressable.
6695
f8a93a2e
JJ
66962012-12-18 Jakub Jelinek <jakub@redhat.com>
6697
6698 PR c/39464
6699 * c-typeck.c (convert_for_assignment): For -Wpointer-sign
6700 warning require that both c_common_unsigned_type as well as
6701 c_common_signed_type is the same for both mvl and mvr types.
6702
9771b263
DN
67032012-11-16 Diego Novillo <dnovillo@google.com>
6704
6705 Adjust for new vec API (http://gcc.gnu.org/wiki/cxx-conversion/cxx-vec)
6706
6707 * c-common.c: Use new vec API in vec.h.
6708 * c-common.h: Likewise.
6709 * c-gimplify.c: Likewise.
6710 * c-pragma.c: Likewise.
6711 * c-pretty-print.c: Likewise.
6712 * c-pretty-print.h: Likewise.
6713 * c-semantics.c: Likewise.
6714 * c-decl.c: Likewise.
6715 * c-parser.c: Likewise.
6716 * c-tree.h: Likewise.
6717 * c-typeck.c: Likewise.
6718
880661a4
JW
67192012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
6720
6721 PR c++/54930
6722 * c-typeck.c (c_finish_return): Use OPT_Wreturn_local_addr.
6723
077d1abe
MLI
67242012-10-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
6725
6726 PR c/53066
6727 * c-decl.c (warn_if_shadowing): Do not warn if a variable
6728 shadows a function, unless the variable is a function or a
6729 pointer-to-function.
6730
3a785c97
JJ
67312012-10-12 Jakub Jelinek <jakub@redhat.com>
6732
6733 PR c/54381
6734 * c-parser.c (struct c_tree_loc_pair): Removed.
6735 (c_parser_expr_list): Remove struct c_tree_loc_pair * argument,
6736 add location_t * and tree * arguments, fill in array of 3
6737 sizeof_arg trees and corresponding locs.
6738 (c_parser_attributes, c_parser_objc_keywordexpr): Adjust
6739 c_parser_expr_list callers.
6740 (c_parser_postfix_expression_after_primary): Likewise. Pass
6741 array of 3 sizeof_arg trees and locs (corresponding to first
6742 3 arguments) to sizeof_pointer_memaccess_warning.
6743
703c8606
LC
67442012-10-09 Lawrence Crowl <crowl@google.com>
6745
6746 * Make-lang.in (c-decl.o): Add dependence on hash-table.h.
6747 * c-decl.c (detect_field_duplicates_hash): Change to new type-safe
6748 hash table.
6749
5d9de0d0
PC
67502012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
6751
6752 PR c++/54194
6753 * c-typeck.c (parser_build_binary_op): Update warn_about_parentheses
6754 call.
6755
a212e43f
MG
67562012-10-09 Marc Glisse <marc.glisse@inria.fr>
6757
6758 PR c++/54427
6759 * c-typeck.c: Include c-common.h.
6760 (enum stv_conv): Moved to c-common.h.
6761 (scalar_to_vector): Moved to c-common.c.
6762 (build_binary_op): Adapt to scalar_to_vector's new prototype.
6763 * Make-lang.in: c-typeck.c depends on c-common.h.
6764
3b78de56
AC
67652012-10-04 Arnaud Charlet <charlet@adacore.com>
6766
6767 * c-decl.c (c_write_global_declarations): Fix handling of
6768 -fdump-ada-spec*.
6769
78c60e3d
SS
67702012-09-30 Sharad Singhai <singhai@google.com>
6771
6772 * c-decl.c (c_write_global_declarations): Use a different method
6773 to determine if the dump has ben initialized.
6774
9f33203d
JM
67752012-09-14 Joseph Myers <joseph@codesourcery.com>
6776
6777 PR c/54552
6778 * c-typeck.c (c_cast_expr): When casting to a type requiring
6779 C_MAYBE_CONST_EXPR to be created, pass the inner expression to
6780 c_fully_fold first.
6781
a27d595d
JM
67822012-09-14 Joseph Myers <joseph@codesourcery.com>
6783
6784 PR c/54103
6785 * c-typeck.c (build_unary_op): Pass original argument of
6786 TRUTH_NOT_EXPR to c_objc_common_truthvalue_conversion, then remove
6787 any C_MAYBE_CONST_EXPR, if it has integer operands.
6788 (build_binary_op): Pass original arguments of TRUTH_ANDIF_EXPR,
6789 TRUTH_ORIF_EXPR, TRUTH_AND_EXPR, TRUTH_OR_EXPR and TRUTH_XOR_EXPR
6790 to c_objc_common_truthvalue_conversion, then remove any
6791 C_MAYBE_CONST_EXPR, if they have integer operands. Use
6792 c_objc_common_truthvalue_conversion not
6793 c_common_truthvalue_conversion.
6794 (c_objc_common_truthvalue_conversion): Build NE_EXPR directly and
6795 call note_integer_operands for arguments with integer operands
6796 that are not integer constants.
6797
9feb29df
JJ
67982012-09-13 Jakub Jelinek <jakub@redhat.com>
6799
6800 PR c/54559
6801 * c-typeck.c (c_finish_return): Do convert to BOOLEAN_TYPE or
6802 COMPLEX_TYPE with in_late_binary_op set temporarily to true.
6803
d409320c
JJ
68042012-08-31 Jakub Jelinek <jakub@redhat.com>
6805
6806 PR c/54428
6807 * c-convert.c (convert): Don't call fold_convert_loc if
6808 TYPE_MAIN_VARIANT of a COMPLEX_TYPE is the same, unless e
6809 is a COMPLEX_EXPR. Remove TYPE_MAIN_VARIANT check from
6810 COMPLEX_TYPE -> COMPLEX_TYPE conversion.
6811
6265d07c
JJ
68122012-08-24 Jakub Jelinek <jakub@redhat.com>
6813
6814 PR c/54355
6815 * c-decl.c (c_parser_label): Pass true as nested and fix up comments
6816 for nested and empty_ok arguments in the call to
6817 c_parser_declaration_or_fndef.
6818
1a4049e7
JJ
68192012-08-17 Jakub Jelinek <jakub@redhat.com>
6820
6821 * c-tree.h (c_last_sizeof_arg): Declare.
6822 * c-parser.c (struct c_tree_loc_pair): New type.
6823 (c_parser_expr_list): Add sizeof_arg argument. Fill it in if
6824 non-NULL.
6825 (c_parser_attributes, c_parser_objc_keywordexpr): Adjust callers.
6826 (c_parser_postfix_expression_after_primary): Likewise. Call
6827 sizeof_pointer_memaccess_warning if needed.
6828 (sizeof_ptr_memacc_comptypes): New function.
6829 * c-typeck.c (c_last_sizeof_arg): New global variable.
6830 (c_expr_sizeof_expr, c_expr_sizeof_type): Initialize it.
6831
0229aee9
UB
68322012-07-24 Uros Bizjak <ubizjak@gmail.com>
6833
6834 * c-lang.h (lang_decl): Add variable_size GTY option.
6835
7ee2468b
SB
68362012-07-16 Steven Bosscher <steven@gcc.gnu.org>
6837
6838 * c-decl.c: Include dumpfile.h instead of tree-dump.h.
6839 * Make-lang.in: Fix dependencies.
6840
d4a10d0a
SB
68412012-06-29 Steven Bosscher <steven@gcc.gnu.org>
6842
6843 * Make-lang.in: New file, rules migrated from gcc/Makefile.in
6844 and add language Makefile hooks.
6845 * config-lang.in: New file.
6846 * c-config-lang.in: Moved from gcc/config-lang.in to here, and
6847 add the required "normal" config-lang.in rules.
6848 * c-lang.h: Moved from gcc/ to here.
6849 * c-tree.h: Likewise.
6850 * c-objc-common.c: Likewise.
6851 * c-objc-common.h: Likewise.
6852 * c-typeck.c: Likewise.
6853 * c-convert.c: Likewise.
6854 * c-lang.c: Likewise.
6855 * c-aux-info.c: Likewise.
6856 * c-errors.c: Likewise.
6857 * gccspec.c: Likewise.
6858 * c-decl.c: Likewise. Include gt-c-c-decl.h, not gt-c-decl.h.
6859 * c-parser.c: Likewise. Include gt-c-c-parser.h, not gt-c-parser.h.
6860\f
a5544970 6861Copyright (C) 2012-2019 Free Software Foundation, Inc.
d4a10d0a
SB
6862
6863Copying and distribution of this file, with or without modification,
6864are permitted in any medium without royalty provided the copyright
6865notice and this notice are preserved.